downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

Reference Counting Basics> <Built-in web server
[edit] Last updated: Fri, 23 Mar 2012

view this page in

Garbage Collection

Spis treści

This section explains the merits of the new Garbage Collection (also known as GC) mechanism that is part of PHP 5.3.



add a note add a note User Contributed Notes Garbage Collection
neo22s at gmail dot com 30-Oct-2011 11:58
Memory cleanup for long-running scripts.

<?php
gc_enable
(); // Enable Garbage Collector
var_dump(gc_enabled()); // true
var_dump(gc_collect_cycles()); // # of elements cleaned up
gc_disable(); // Disable Garbage Collector
?>

 
show source | credits | stats | sitemap | contact | advertising | mirror sites