src/Drupal/Component/Utility/Timer.php
static public function read($name) {
    if (isset(static::$timers[$name]['start'])) {
      $stop = microtime(TRUE);
      $diff = round(($stop - static::$timers[$name]['start']) * 1000, 2);

      if (isset(static::$timers[$name]['time'])) {
        $diff += static::$timers[$name]['time'];
      }
      return $diff;
    }
    return static::$timers[$name]['time'];
  }
static public function read($name) {
    if (isset(static::$timers[$name]['start'])) {
      $stop = microtime(TRUE);
      $diff = round(($stop - static::$timers[$name]['start']) * 1000, 2);

      if (isset(static::$timers[$name]['time'])) {
        $diff += static::$timers[$name]['time'];
      }
      return $diff;
    }
    return static::$timers[$name]['time'];
  }
static public function read ( $ name ) { if ( isset ( static :: $ timers [ $ name ] [ 'start' ] ) ) { $ stop = microtime ( TRUE ) ; $ diff = round ( ( $ stop - static :: $ timers [ $ name ] [ 'start' ] ) * 1000 , 2 ) ; if ( isset ( static :: $ timers [ $ name ] [ 'time' ] ) ) { $ diff += static :: $ timers [ $ name ] [ 'time' ] ; } return $ diff ; } return static :: $ timers [ $ name ] [ 'time' ] ; }
Reads the current timer value without stopping the timer.

@param string $name
The name of the timer.

@return int
The current timer value in ms.
Reads the current timer value without stopping the timer .