Gc_disable will disable the cyclic reference collector, but isn't gc based on the number of reference techniques? does this mean that the garbage collection mechanism is disabled?

Source: Internet
Author: User
If so, how can I manage the PHP memory in the case of gc_disable? If so, how can I manage the PHP memory in the case of gc_disable?

Reply content:

If so, how can I manage the PHP memory in the case of gc_disable?

Cyclic reference countThe collector is only a type of GC and is introduced in versions later than 5.3.

In versions 5.2 and earlier, it is not without gc, but only based onReference countPay attention to the difference between the two terms.

The cyclic reference counting collector may affect the script execution efficiency when many objects or arrays exist. Therefore, when you confirm that your script will not generateLoop referenceYou can callGc_disableForce disable to improve performance, but does not mean the whole garbage collection mechanism is disabled

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.