Articles about recycling Cycle 3 recommendations

Source: Internet
Author: User
Traditionally, the reference-count memory mechanism, like the previous PHP, could not handle circular reference memory leaks. However 5.3.0 PHP uses the synchronization algorithm in the article» Reference counting system for synchronization cycle recovery (Concurrent cycle Collection in Reference counted systems) to handle this memory leak problem. The full description of the algorithm is somewhat beyond the scope of this section and will only cover the underlying part. First, we have to establish some basic rules, if a reference count increases, it will continue to be used, of course, it is no longer in the garbage. If the reference count is reduced to zero, the container in which the variable is located is cleared (free). That is, the garbage cycle (garbage cycle) is generated only when the reference count is reduced to a value other than 0. Second, in a garbage cycle, by checking whether the reference count is minus 1, and checking which variable containers have a reference number of zero, to find out which part is garbage. The above is the PHP characteristics of the garbage collection mechanism 2--recovery cycle content, more relevant content please focus on PHP

1. PHP features garbage collection mechanism 2--recovery cycle

Summary: Traditionally, the reference count memory mechanism, like the previous PHP, cannot handle circular reference memory leaks. However 5.3.0 PHP uses the synchronization algorithm in the article» Reference counting system for synchronization cycle recovery (Concurrent cycle Collection in Reference counted systems) to handle this memory leak problem.

2. PHP garbage collection mechanism-recycle cycle

Introduction: PHP features garbage collection mechanism-recycling cycle

3. Recycle period of PHP garbage collection mechanism

Introduction:: This article mainly introduces the garbage collection mechanism of PHP recycling cycle, for the PHP tutorial interested students can refer to.

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.