Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

pudge (1)

pudge
  (email not shown publicly)
http://pudge.net/
AOL IM: Crimethnk (Add Buddy, Send Message)

I run this joint, see?

Journal of pudge (1)

Tuesday January 13, 2004
03:53 AM

Mac::Carbon Profiling: Panther is Faster

[ #16798 ]

Boy howdy, is it. The system is an iBook G3/600 with 256MB RAM. The first test is with Mac OS X 10.2.8.

$ time perl -MMac::Glue -e 'Mac::Glue->new("Finder")->activate'
real    0m21.445s
user    0m7.100s
sys     0m0.510s
 
$ time perl -MMac::Carbon -e1
real    0m19.885s
user    0m6.810s
sys     0m0.220s

The second is Mac OS X 10.3.2.

$ time perl -MMac::Glue -e 'Mac::Glue->new("Finder")->activate'
real    0m2.067s
user    0m1.430s
sys     0m0.320s
 
$ time perl -MMac::Carbon -e1
real    0m1.300s
user    0m1.130s
sys     0m0.140s

Wow. That's pretty dramatic. More than 10x faster in real, and about 5x faster in user+sys. Why the speedup?

The slowest thing with Mac::Carbon was always in loading the modules on startup, with most of the time spent in dyld. Over 90% of that time in the Mac::Glue test in Mac OS X 10.2.8 was spent in dyld. In the Mac OS X 10.3.2 version it is still over 75%, but, obviously, much less time is spent there.

Before, it was spending over half of its time in link_library_module and add_reference combined, and about 20% in relocate_symbol_pointers/relocate_symbol_pointers_in_library_image. Now, it still spends about 20% in the latter, but the former don't show up at all. And that 20% is a lot less than in the original, since the total time is so much shorter.

I don't know what all that means exactly, but I do know that yeeha, Panther is a lot faster at loading in them shared libraries.

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.