Chris Wagner wrote: >> I'm not sure. Ending thread on Windows deallocates memory as it said in > MSDN, but I'm not exactly sure how Perl handles >> all this stuff.
> So that could be Windows specific? The application I made was on Solaris. Yes, it could. From the other hand, once I had a script on Linux, that had to iterate an array of ~1000 big records (100M memory total), and replacing "foreach my $obj (@objects)" with "while (my $obj = shift @objects)" and using weak references (Scalar::Util) in these objects actually lead to memory usage decrease on every iteration. But this method doesn't work on Windows, so, I believe, it's up to OS. > I actually thought it was a memory leak in my code. After I found out Perl > couldn't free() memory I gave up on trying to shrink the process size and > implemented a multiprocess system to deal with the memory issue. Well, you may try the script I sent in previous message to check how threads work on Solaris. If they actually free memory on thread completion, it would be good. -- Serguei Trouchelle _______________________________________________ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs