Bug #75175 [Fbk->NoF]: Opcache_reset() does not clear cache

From: Date: Sun, 05 Nov 2017 04:22:51 +0000
Subject: Bug #75175 [Fbk->NoF]: Opcache_reset() does not clear cache
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-212459@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=75175&edit=1 ID: 75175 Updated by: php-bugs@lists.php.net Reported by: tm8544 at hotmail dot com Summary: Opcache_reset() does not clear cache -Status: Feedback +Status: No Feedback Type: Bug Package: opcache Operating System: Windows 10 x64 PHP Version: 7.2.0RC1 Private report: N New Comment: No feedback was provided. The bug is being suspended because we assume that you are no longer experiencing the problem. If this is not the case and you are able to provide the information that was requested earlier, please do so and change the status of the bug back to "Re-Opened". Thank you. Previous Comments: ------------------------------------------------------------------------ [2017-09-13 10:28:52] ab@php.net Thanks for the report. I'm not sure to understand the issue. The numbers for used_memory are in both cases equal before and after reset. They differ in different PHP versions, but that doesn't tell anything about the opcache_reset() functionality. It only tells that something has changed in other PHP version, which is an implementation detail. Please be more specific. Thanks. ------------------------------------------------------------------------ [2017-09-08 14:56:29] tm8544 at hotmail dot com Description: ------------ After opcache_reset, with version 7.2.0RC1 "used_memory" still occupies much more memory than with version 7.1.9. Opcache runtime configuration stays the same. Expected result shows test script output with PHP 7.1.9, and actual result shows test script output with PHP 7.2.0RC1. Test script: --------------- <html><body><pre><?php echo "Memory Usage before reset:\r\n"; $a = opcache_get_status(); var_dump($a["memory_usage"]); echo "----------------------\r\n"; echo "Reset Opcache\r\n"; $ok = opcache_reset(); var_dump($ok); echo "----------------------\r\n"; echo "Memory Usage after reset:\r\n"; $a = opcache_get_status(); var_dump($a["memory_usage"]); ?></pre></body></html> Expected result: ---------------- Memory Usage before reset: array(4) { ["used_memory"]=> int(701384) ["free_memory"]=> int(133516344) ["wasted_memory"]=> int(0) ["current_wasted_percentage"]=> float(0) } ---------------------- Reset Opcache bool(true) ---------------------- Memory Usage after reset: array(4) { ["used_memory"]=> int(701384) ["free_memory"]=> int(133516344) ["wasted_memory"]=> int(0) ["current_wasted_percentage"]=> float(0) } Actual result: -------------- Memory Usage before reset: array(4) { ["used_memory"]=> int(18272056) ["free_memory"]=> int(115945672) ["wasted_memory"]=> int(0) ["current_wasted_percentage"]=> float(0) } ---------------------- Reset Opcache bool(true) ---------------------- Memory Usage after reset: array(4) { ["used_memory"]=> int(18272056) ["free_memory"]=> int(115945672) ["wasted_memory"]=> int(0) ["current_wasted_percentage"]=> float(0) } ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=75175&edit=1

« previous php.bugs (#212459) next »