Bug #79514 [NEW]: Memory leaks while including unexistent file
| From: | ferrius7 at gmail dot com | Date: | Thu, 23 Apr 2020 14:55:58 +0000 |
| Subject: | Bug #79514 [NEW]: Memory leaks while including unexistent file | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-226744@lists.php.net to get a copy of this message | ||
From: ferrius7 at gmail dot com
Operating system: Linux
PHP version: 7.4.5
Package: *Directory/Filesystem functions
Bug Type: Bug
Bug description:Memory leaks while including unexistent file
Description:
------------
- in php 7.4.5 with disabled cli (opcache.enable_cli=0) memory leaks
and increasing execution time.
- in php 7.3.15 with disabled cli (opcache.enable_cli=0) everything is
ok.
In case with enabled cli opcache php 7.4 works as expected with no
leaks.
Test script:
---------------
<?php
$i = 0;
while ($i < 100000) {
$checkpoint = ($i % 10000 === 0);
if ($checkpoint) {
$start = hrtime(true);
}
@include __DIR__ . '/unexistentfile';
if ($checkpoint) {
echo "time: " . (int)((hrtime(true) - $start)/1000) . " micro s
$i\n";
echo "alloc mem: " . (memory_get_usage(true) / 1024 / 1024) .
"Mb \n";
}
++$i;
}
Expected result:
----------------
No memory leaks and constant execution time of each iteration
Actual result:
--------------
Memory leaks and increasing execution time
--
Edit bug report at https://bugs.php.net/bug.php?id=79514&edit=1
--
Fix committed: https://bugs.php.net/fix.php?id=79514&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=79514&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=79514&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=79514&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=79514&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=79514&r=support
Expected behavior: https://bugs.php.net/fix.php?id=79514&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=79514&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=79514&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=79514&r=globals
PHP version support discontinued: https://bugs.php.net/fix.php?id=79514&r=phptooold
Daylight Savings: https://bugs.php.net/fix.php?id=79514&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=79514&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=79514&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=79514&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=79514&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=79514&r=mysqlcfg