X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FDevel%2FSize.pm;h=65eec3a1642fc0e595c7d0ed3383be9c3abc2658;hb=346993b5264beb181322abbd18c3942f872d01e7;hp=78c290eaf6800036fd025f07449cf1cb7ceb4fe6;hpb=56ae08a82498da14948299d9cda6f01d13d68ecf;p=p5sagit%2FDevel-Size.git diff --git a/lib/Devel/Size.pm b/lib/Devel/Size.pm index 78c290e..65eec3a 100644 --- a/lib/Devel/Size.pm +++ b/lib/Devel/Size.pm @@ -1,23 +1,20 @@ package Devel::Size; use strict; -use vars qw($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS $warn $dangle); +use vars qw($VERSION @ISA @EXPORT_OK %EXPORT_TAGS $warn $dangle); -require 5.008; +require 5.005; require Exporter; require XSLoader; @ISA = qw(Exporter); -# This allows declaration use Devel::Size ':all'; -%EXPORT_TAGS = ( 'all' => [ qw( - size total_size -) ] ); +@EXPORT_OK = qw(size total_size); -@EXPORT_OK = ( @{ $EXPORT_TAGS{'all'} } ); +# This allows declaration use Devel::Size ':all'; +%EXPORT_TAGS = ( 'all' => \@EXPORT_OK ); -@EXPORT = qw( ); -$VERSION = '0.72_50'; +$VERSION = '0.79'; XSLoader::load( __PACKAGE__); @@ -190,7 +187,7 @@ larger. Since version 0.72, Devel::Size uses a new pointer tracking mechanism that consumes far less memory than was previously the case. It does this by using a bit vector where 1 bit represents each 4- or 8-byte aligned pointer -(32- or 64-bit platform dependant) that could exist. Further, it segments +(32- or 64-bit platform dependent) that could exist. Further, it segments that bit vector and only allocates each chunk when an address is seen within that chunk. Since version 0.73, chunks are allocated in blocks of 2**16 bits (ie 8K), accessed via a 256-way tree. The tree is 2 levels deep on a 32 bit