|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2017-09-13 10:28 UTC] ab@php.net
-Status: Open
+Status: Feedback
[2017-09-13 10:28 UTC] ab@php.net
[2017-11-05 04:22 UTC] php-bugs at lists dot php dot net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Dec 15 18:00:01 2025 UTC |
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) }