Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

Re: Re: A more memory efficient storage structure?

by Elian (Parson)
on Dec 31, 2002 at 19:22 UTC ( #223429=note: print w/replies, xml ) Need Help??

in reply to Re: A more memory efficient storage structure?
in thread A more memory efficient storage structure?

Do be aware that Devel::Size does count shared data in part of its size calculation when figuring out how big what you're checking is, but it only counts it once per call, so if the two hashes share some data, and they might, pass them in together for a correct aggregate total. Something like:
print total_size([\%hash1, \%hash2]);
though that'll add in a few dozen bytes for the two refs and the anon array.

Also, don't rule out the possibility that there's a lot of scrap memory hanging around that Perl's not cleaned up after quite yet, or that you've not noticed.

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://223429]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (4)
As of 2023-09-22 12:52 GMT
Find Nodes?
    Voting Booth?

    No recent polls found