Re: how to detect circular reference caused mem leaks on win32

From: Date: Fri, 18 Aug 2000 19:48:13 +0000
Subject: Re: how to detect circular reference caused mem leaks on win32
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-29518@lists.php.net to get a copy of this message
AL>> This leaks are cleaned up at the end of the request only, I╢d call it AL>> long-living (until death). You╢re really sure that I╢ve not to worry End of the request is not nearly death. Also, why it is a problem for you? How many variables do you have so that it affects your performance? If your memory is not enough to allow you executing a request, maybe you should just buy more memory? :) Memory leaks are dangerous because they are accumulationg over time. PHP "leaks" do not accumulate over time, so you shouldn't worry too much about them. AL>> about it in every case? If you could explain when (exactly) these leaks AL>> are created the whole issue would be easier to understand. Where you have circular reference, i.e., your reference graph contains loops. Unless you are so poor on memory that you manually unset variables in the course of the script, you shouldn't really care when variable memory is cleaned - on executor engine shutdown or on memory engine shutdown. Those that are "leaks" are just cleaned on memory engine shutdown. These leaks are not good because in general case they could accumulate, but the circular reference ones are pretty hard to make accumulating (you should really do a lot of short-living circular referenced structures, while unsetting them manually all the time), and I saw no single real case where it could really hurt performance. -- Stanislav Malyshev stas@zend.com +972-3-6139665 ext.106

« previous php.dev (#29518) next »