in reply to Re^5: perl5.10 Devel::Size behaviour changed? (reason for magic)
in thread perl5.10 Devel::Size behaviour changed?
Hm. Pre-5.10, every array that didn't use $#array, wasted 1 pointer.
Post 5.10, every array uses that pointer to point to a 12 or 24-byte block of memory whether it is ever used or not.
And the very act of attempting to check to see if there is any magic attached, causes there to be magic attached.
That makes no sense at all to me.
Now the only way D::S can avoid causing the magic to be attached is to either not bother looking to see if there is any; or to dereference the magic pointer directly...
A microscopic optimisation attempt that causes a macroscopic [sic] pessimisation. Autovivifying magic just because someone wants to know if there is any is...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^7: perl5.10 Devel::Size behaviour changed? (reason for magic)
by ikegami (Patriarch) on Oct 28, 2009 at 18:03 UTC | |
by BrowserUk (Patriarch) on Oct 28, 2009 at 19:29 UTC | |
by ikegami (Patriarch) on Oct 28, 2009 at 19:37 UTC |