src/Benchmark.php
private function _warmup()
    {
        $warmup = new Test('warmup', function () {
        });

        $this->_overhead = $warmup->runTest($this->_count);

        // One call each method for init (warmup)

        /** @var Test $test */
        foreach ($this->_tests as $test) {
            $test->runTest(1);
        }

        $this->out(
            'PHP Overhead: ' .
            'time=' . Timer::formatMS($this->_overhead['time']) . '; ' .
            'memory=' . FS::format($this->_overhead['memory'], 2) . ';' .
            PHP_EOL
        );
    }
private function _warmup()
    {
        $warmup = new Test('warmup', function () {
        });

        $this->_overhead = $warmup->runTest($this->_count);

        // One call each method for init (warmup)

        /** @var Test $test */
        foreach ($this->_tests as $test) {
            $test->runTest(1);
        }

        $this->out(
            'PHP Overhead: ' .
            'time=' . Timer::formatMS($this->_overhead['time']) . '; ' .
            'memory=' . FS::format($this->_overhead['memory'], 2) . ';' .
            PHP_EOL
        );
    }
private function _warmup ( ) { $ warmup = new Test ( 'warmup' , function ( ) { } ) ; $ this -> _overhead = $ warmup -> runTest ( $ this -> _count ) ; // One call each method for init (warmup) /** @var Test $test */ foreach ( $ this -> _tests as $ test ) { $ test -> runTest ( 1 ) ; } $ this -> out ( 'PHP Overhead: ' . 'time=' . Timer :: formatMS ( $ this -> _overhead [ 'time' ] ) . '; ' . 'memory=' . FS :: format ( $ this -> _overhead [ 'memory' ] , 2 ) . ';' . PHP_EOL ) ; }
Runs an empty test to determine the benchmark overhead and run each test once
Runs an empty test to determine the benchmark overhead and run each test once