I have an array in my program that stores a large amount of data.The Devel::Size qw(total_size) package says the array's size is 15.4 GB. However, when I traverse the array in a foreach loop, writing each index to a file, adding in line breaks, the size of the file is only 2.7 GB. I do not believe this to be an issue with the Devel::Size qw(total_size) package, as I run out of memory when running my program, allocating well over 4 GB to it. How is this possible and how can it be resolved?
Thanks in advance.
In reply to Bizarre Array Size Disparity by sunmaz
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |