[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [cobalt-users] Raq 2 info
- Subject: Re: [cobalt-users] Raq 2 info
- From: "Dylan Smith" <dyls@xxxxxxx>
- Date: Thu May 24 07:26:11 2001
- List-id: Mailing list for users to share thoughts on Cobalt products. <cobalt-users.list.cobalt.com>
> > > Raq2 is a great machine... it is very fast and VERY stable.
> >
> > Umm, actually it's quite slow. It takes 4-5 seconds for a RaQ2 to start
a
> > Perl CGI script.
>
> Where did you get that figure? I don't see that on mine. I have a simple
CGI
> search on a RaQ2 (http://www.technotrade.com/cgi/search.html) and it's
> almost instantaneous.
There's the key - simple. [0]
I've observed this on two different RaQ2s. The slowness is not the execution
speed of a Perl script - it's the loading speed. (Perl scripts that fork do
the forking fast - I wrote an NNTP server in Perl that runs just fine - it
takes 3 or 4 seconds to start running, but once it's running when a
connection comes in, it forks off a new instance instantly).
The slowness is when a Perl "use" statement is encountered - if you have
four or five "use" statements in your Perl code, the script will take 4 to 5
seconds just to get cranked up. Using apache with mod_perl helps (but with a
complex cgi-script, mod_perl is very slow on the first loading of the
script, subsequent runs are fast). PHP4 is at least an order of magnitude
faster for scripts of the same level of complexity, in my experience.
[0] If you do several 'use' statements in your perl script and it's that
fast, please let me know how you made it run fast. I have found a Perl
script with no use or maybe just one use statement runs fast, even if the
script itself is complex. However, a perl script with nothing but 5 use
statements takes 4 seconds or so to load whether Apache loads it, or whether
you load it from the command line. Try it and see what happens. The same
script on my old K6/2-300 system would load instantly. My old K6/2 system
would also compile C programs much faster than the RaQ2, and it was running
X and a bunch of other stuff that the RaQ2 was not running (with less
available memory, too).