From: bugzilla77 at gmail dot com Operating system: Windows 7 x86/x64 PHP version: 5.5.0alpha4 Package: Date/time related Bug Type: Bug Bug description:microtime(true) undervalued
Description: ------------ This bug is inaugurated in PHP 5.5: microtime(true) is undervalued up to several seconds! The difference increases in time to work the server (after a few days more than 10 seconds). I am watching now test script -5.2 seconds, after Apache restart difference is positive. I am using Apache 2.2 module on Windows 7 x86/x64. Test script: --------------- microtime(true): <?=$mt=microtime(true)?><br/> time(): <?=$t=time()?><br/><br/> microtime(true) - time(): <?=$mt-$t?><br/><br/> difference should be greater than zero and less than one Expected result: ---------------- PHP 5.4: microtime(true) >= time() microtime(true): 1359313026.5983 time(): 1359313026 microtime(true) - time(): 0.59834909439087 difference should be greater than zero and less than one Actual result: -------------- PHP 5.5: microtime(true) < time() microtime(true): 1359312493.8386 time(): 1359312499 microtime(true) - time(): -5.1614379882812 difference should be greater than zero and less than one -- Edit bug report at https://bugs.php.net/bug.php?id=64085&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=64085&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=64085&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=64085&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=64085&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=64085&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=64085&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=64085&r=needscript Try newer version: https://bugs.php.net/fix.php?id=64085&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=64085&r=support Expected behavior: https://bugs.php.net/fix.php?id=64085&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=64085&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=64085&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=64085&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=64085&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=64085&r=dst IIS Stability: https://bugs.php.net/fix.php?id=64085&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=64085&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=64085&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=64085&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=64085&r=mysqlcfg