ID: 40800 User updated by: php at vicaya dot com Reported By: php at vicaya dot com Status: Open -Bug Type: Unknown/Other Function +Bug Type: Reproducible crash Operating System: Linux 64-bit PHP Version: 5.2.1 New Comment:
USE_ZEND_ALLOC=0 php... seems to workaround the limit. Previous Comments: ------------------------------------------------------------------------ [2007-03-14 06:44:29] php at vicaya dot com Description: ------------ According to the documentation: http://us2.php.net/manual/en/ini.core.php "Note that to have no memory limit, set this directive to -1." But the code use more than 4GB virtual memory crashes with "Fatal error: Allowed memory size of -1 bytes exhausted (tried to allocate 605 bytes) in ..." anyway. Reproduce code: --------------- <? count(file("a_10GB_file")) ?> // not production code :) on a machine with enough ram and swap space. Expected result: ---------------- number of lines in "a_10GB_file". Actual result: -------------- "Fatal error: Allowed memory size of -1 bytes exhausted (tried to allocate 605 bytes) in ..." Suspect that memory limit directive is still a 32bit unsigned integer (size_t) and -1 is converted to 4G-1. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=40800&edit=1
