From: lunter at interia dot pl Operating system: winXP PHP version: 5.3.0RC1 PHP Bug Type: Scripting Engine problem Bug description: is_null() is 4x slower than ===null
Description: ------------ is_null() is 4x slower than ===null Reproduce code: --------------- <? $t=microtime(1); for($z=0;$z<1e7;$z++){ if(is_null(1)){} } print(microtime(1)-$t);print('<br/>'); // --- $t=microtime(1); for($z=0;$z<1e7;$z++){ if(1===null){} } print(microtime(1)-$t);print('<br/>'); ?> Expected result: ---------------- is_null() is faster like ===null Actual result: -------------- is_null() is 4x slower than ===null -- Edit bug report at http://bugs.php.net/?id=47965&edit=1 -- Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=47965&r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=47965&r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=47965&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=47965&r=fixedcvs Fixed in CVS and need be documented: http://bugs.php.net/fix.php?id=47965&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=47965&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=47965&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=47965&r=needscript Try newer version: http://bugs.php.net/fix.php?id=47965&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=47965&r=support Expected behavior: http://bugs.php.net/fix.php?id=47965&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=47965&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=47965&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=47965&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=47965&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=47965&r=dst IIS Stability: http://bugs.php.net/fix.php?id=47965&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=47965&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=47965&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=47965&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=47965&r=mysqlcfg