Purl Gurl wrote:
> A dynometer displays thirty percent of my Mako's horsepower
> is consumed overcoming friction and inertial mass. So,
> it doesn't matter my wheels are square because this
> loss in efficiency because of my square wheels, is
> nothing in comparsion to my overall horsepower lost
> to all these big picture factors.
Your example is exactly backwards. In any real-world situation, CGI.pm
accounts for 10% or less of a script's overall execution time. Trying to
optimize it is like waxing your square-wheeled 'vette in an attempt to
reduce drag.
Keep in mind, I'm not saying to ignore CGI.pm's weaknesses and use it out of
dogma. All I'm saying is, don't try to prematurely optimize it. Profile
your code to find out where the real bottlenecks are. Fix those, and
profile the code again.
Keep repeating the profile/optimize loop until your boss is screaming at you
to quit being a perfectionist and ship the damn code already. In ten years
of coding Perl for a living, I have yet to see CGI.pm make its way to the
top of the bottleneck list before that happens.
If it does happen, some day, that CGI.pm is the biggest bottleneck, then
I'll worry about writing something faster.
> Would you use CGI.pm to generate html code for a "hello world!" script?
If I were interested in writing a contrived, unrealistic example that did
nothing but "prove" a dubious point, I might do that.
> Your logic is less than Vulcan ideal.
Vulcans are fictional. Short deadlines, limited budgets, and greedy suits
are real.
sherm--
--
Cocoa programming in Perl:
http://camelbones.sourceforge.net
Hire me! My resume:
http://www.dot-app.org