php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #33893 $_SERVER['STARTUP_MICRO_TIME']
Submitted: 2005-07-27 23:15 UTC Modified: 2010-12-22 03:43 UTC
From: marcos dot neves at gmail dot com Assigned: johannes (profile)
Status: Closed Package: *General Issues
PHP Version: 5.1.0b3 OS: any
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: marcos dot neves at gmail dot com
New email:
PHP Version: OS:

 

 [2005-07-27 23:15 UTC] marcos dot neves at gmail dot com
Description:
------------
$_SERVER['REQUEST_TIME'] is a very nice feature, But since many scripts runs in less than 0.1 seconds, would be nice exists a $_SERVER['STARTUP_MICRO_TIME'], so would be possible do something like below:

Reproduce code:
---------------
<?
$times['startup'] = $_SERVER['STARTUP_MICRO_TIME']

require_once 'any.php';

$times['require'] = microtime(true);

... // more code

$times['more_code'] = microtime(true);

printTimes($times);

function printTimes($times) {
... // use $_SERVER['REQUEST_MICRO_TIME']
}

?>

Expected result:
----------------
A fine grained time elapse calculation

Actual result:
--------------
not perfect time elapse calculation

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-12-22 03:43 UTC] johannes@php.net
-Status: Open +Status: Closed -Package: Feature/Change Request +Package: *General Issues -Assigned To: +Assigned To: johannes
 [2010-12-22 03:43 UTC] johannes@php.net
In PHP trunk $_SERVER['REQUEST_TIME'] contains microsecond precision.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Mon Jun 02 22:01:27 2025 UTC