Print the start of timing message to stderr and start the timer.
420567
public static void startDoing(String str) {
    System.err.print(str);
    System.err.print(" ... ");
    System.err.flush();
    startTime();
  }
570138
def log(self, msg, error=False):
        """"""
        output = self.stdout
        if error:
            output = self.stderr

        output.write(msg)
        output.write('\n')
38743
def print_time(self, message="Time is now: ", print_frame_info=True):
        
        if print_frame_info:
            frame_info = inspect.getouterframes(inspect.currentframe())[1]
            print(message, (datetime.now() - self.start_time), frame_info)
        else:
            print(message, (datetime.now() - self.start_time))
578241
def print_err(*args, end='\n'):
    
    print(*args, end=end, file=sys.stderr)
    sys.stderr.flush()
84210
def shout(msg, f=sys.stderr):
    ''''''
    print >> f, "{0}: {1}".format(_PROG, msg)
    f.flush()
1363474
def output_before_run(self, run):
        
        # output in terminal
        runSet = run.runSet
        try:
            OutputHandler.print_lock.acquire()

            try:
                runSet.started_runs += 1
            except AttributeError:
                runSet.started_runs = 1

            timeStr = time.strftime("%H:%M:%S", time.localtime()) + "   "
            progressIndicator = " ({0}/{1})".format(runSet.started_runs, len(runSet.runs))
            terminalTitle = TERMINAL_TITLE.format(runSet.full_name + progressIndicator)
            if self.benchmark.num_of_threads == 1:
                util.printOut(terminalTitle + timeStr + self.format_sourcefile_name(run.identifier, runSet), '')
            else:
                util.printOut(terminalTitle + timeStr + "starting   " + self.format_sourcefile_name(run.identifier, runSet))
        finally:
            OutputHandler.print_lock.release()
689603
def err_exit(msg, rc=1):
    
    print(msg, file=sys.stderr)
    sys.exit(rc)
287107
def stderr_avail(self):
        """"""
        data = self.interpreter.stderr_write.empty_queue()
        if data:
            self.write(data, error=True)
            self.flush(error=True)
1170037
def start(self, message):
        
        self._start = time.clock()
        VSGLogger.info("{0:<20} - Started".format(message))
185749
def timeout(seconds, error_message=None):
    """"""

    def decorated(func):
        result = ""

        def _handle_timeout(signum, frame):
            errmsg = error_message or 'Timeout: The action <%s> is timeout!' % func.__name__
            global result
            result = None
            import inspect
            stack_frame = inspect.stack()[4]
            file_name = os.path.basename(stack_frame[1])
            line_no = stack_frame[2]
            method_name = stack_frame[3]
            code_text = ','.join(stack_frame[4])
            stack_info = 'Stack: %s, %s:%s >%s' % (method_name, file_name, line_no, code_text)
            sys.stderr.write(errmsg+'\n')
            sys.stderr.write(stack_info+'\n')
            raise TimeoutError(errmsg)

        @sysx.platform(sysx.UNIX_LIKE, case_false_wraps=func)
        def wrapper(*args, **kwargs):
            global result
            signal.signal(signal.SIGALRM, _handle_timeout)
            signal.alarm(seconds)

            try:
                result = func(*args, **kwargs)
            finally:
                signal.alarm(0)
                return result

        return functools.wraps(func)(wrapper)

    return decorated
1343783
async def stderr(self) -> AsyncGenerator[str, None]:
        """"""
        await self.wait_running()
        async for line in self._subprocess.stderr:  # type: ignore
            yield line
634083
def _print_duration(self):
        ''''''
        duration = int(time.time() - self._start_time)
        self._print(datetime.timedelta(seconds=duration))
110501
def _start(self):
        '''  '''
        self.start = time.time()
        self.result['start'] = str(datetime.datetime.now())
        if not self.pause_type == 'prompt':
            print "(^C-c = continue early, ^C-a = abort)"
485517
def run(self):
        
        stderr = os.path.abspath(os.path.join(self.outdir, self.name + '.log'))

        if self.pipe:
            self.args += ('|', self.pipe, '2>>'+stderr)

        if self.gzip:
            self.args += ('|', 'gzip', '1>', self.gzip)
        else:
            self.args.append('2>>'+stderr)
            self.args.append('1>>'+stderr)

        # Print timestamp to log

        log = open(stderr, 'a')
        log.write("[gloTK] timestamp={}\n".format(utils.timestamp()))

        cmd = ' '.join(map(str, self.args))
        print(cmd)
        log.write(cmd)

        start = time.time()
        save_cwd = os.getcwd()
        try:
            utils.safe_mkdir(self.outdir)
            os.chdir(self.outdir)
            spawn_pid = os.spawnle(os.P_NOWAIT, self.shell, self.shell, '-c', cmd, self.env)
            wait_pid, retcode, rusage = os.wait4(spawn_pid, 0)
            if wait_pid != spawn_pid:
                utils.die("could not wait for process %d: got %d" % (spawn_pid, wait_pid))
            os.chdir(save_cwd)
        except OSError as e:
            utils.info(e)
            utils.die("could not run wrapper for command:\n%s" % cmd)

        elapsed = time.time() - start
        retcode = os.WEXITSTATUS(retcode)

        if (self.return_ok is not None) and (self.return_ok != retcode):
            # Give some context to the non-zero return.
            if os.path.isfile(stderr):
                subprocess.call(['tail', '-3', stderr])
            utils.die("non-zero return (%d) from command:\n%s" % (retcode, cmd))
        log.close()
376387
def stderr_cm(self):
        
        with open(self._get_stderr_log(), 'a+') as fh:
            msg = '### {} ###\n'.format(self._datetime)
            fh.write(msg)
            fh.flush()

            try:
                yield fh
            except Exception as e:
                self._has_error = True
                fh.write(e.message)
                fh.flush()
                raise
275574
def send_stderr(cls, sock, payload):
    """"""
    cls.write_chunk(sock, ChunkType.STDERR, payload)
502976
def stderr(self):
        
        streams = self._payload.get('streams', None)
        return streams[1] if streams is not None and len(streams) >= 2 else ''