Home > Backend Development > PHP Tutorial > Why does the result of memory_get_usage() change so much_PHP tutorial

Why does the result of memory_get_usage() change so much_PHP tutorial

WBOY
Release: 2016-07-13 10:52:10
Original
1325 people have browsed it



Question
Why does the result of memory_get_usage() change so much?
Solution
There is a set of programs. I use memory_Get_usage in the footer to output the memory usage. The results vary greatly. Sometimes it is more than 700k, sometimes it is more than 1m, sometimes it is 5M. After restarting apache, everything is normal again

The output page is the same page, and no new data has been added to the database, so I don't understand it.


Netizens’ suggestions:
Since it is memory usage, there is no constant. . . Look at your task manager, which memory remains unchanged?
Netizens’ suggestions:
But how many times the amount of change
Netizens’ suggestions:
[img]http://tx.icain.cn/png/[/img]
Is it always increasing or changing irregularly
Netizens’ suggestions:
As time accumulates, it becomes larger, but it takes a relatively long time, such as a few hours to change.

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/632515.htmlTechArticleQuestion Why does the result of memory_get_usage() change so much? The solution is a set of procedures. I use memory_Get_usage in the footer. Output the memory usage, and the results vary greatly,...
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template