I can just imagine a situation where threads don't know who's supposed to be doing what with the process heap.

Barring bugs where something scribbles on memory it shouldn't, I have a difficult time believing that threads will suddenly forget they own SVs. It's not as if you have to sweep memory pools with a refcounting system.

If data is in a state where it "should" be garbage collected, then there's nothing to check a ref count of.

Ref counting is how Perl decides to collect data! How do you separate the two things when the former depends on the latter?

When variables die Perl only guarantees that the varname is no longer accessible....

I don't know what it means for a variable to "die". Regardless, if what you said were true--if there were some connection to variable name and liveness--then I don't see how anonymous variables would work.

... not that anything in particular has been done with the SV's behind the scenes.

The ref count is part of the SV structure!


In reply to Re^7: Massive Perl Memory Leak by chromatic
in thread Massive Perl Memory Leak by wagnerc

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.