On Tue, Oct 05, 2010 at 11:11:01AM -0700, mbyovev@windowslive.com wrote:
> It seems like perl 5.10 smart matching (operator ~~) is leaking memory
> when comparing arrays.
> Here is the proof code (linux):
>
> #!/usr/bin/perl
>
> my @a1=(0..10000);
> my @a2=(0..10000);
>
> foreach my $j(0..1000)
> {
> @a1 ~~ @a2;
> #show my memory usage
> system "cat /proc/$$/status | grep VmRSS";
> }
>
> If you run it you will see constant increase of memory used by the process
> on each iteration of foreach loop.
Thanks for the report. This appears to have been fixed sometime between
5.11.0 and 5.11.3 (and thus in 5.12.0 too).
--
Little fly, thy summer's play my thoughtless hand
has terminated with extreme prejudice.
(with apologies to William Blake)
Thread Previous
|
Thread Next