'Run function func(*args, **kw), validate statistics,
and display the result on stdout.
Disable garbage collector if asked too.'

def run(self, func, *args, **kw):

    if self.disable_gc:
        try:
            import gc
        except ImportError:
            self.disable_gc = False
    if self.disable_gc:
        gc_enabled = gc.isenabled()
        gc.disable()
    else:
        gc_enabled = False
    stat = self._run(func, args, kw)
    if gc_enabled:
        gc.enable()
    self.validateStat(stat)
    self.displayStat(stat)
