httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rob Hartill <>
Subject Re: ScriptAlias-like extensions for perl etc
Date Fri, 26 Apr 1996 11:15:30 GMT
> Rob Hartill writes:
> > All my CGI is written in perl. As an experiment I changed
> > mod_cgi.c to call the perl binary directly instead of leaving
> > it to sh (I think that's what gets called to determine that perl
> > needs to be called because of the "#!" first line.)

> That's a negative.  exec() [in the kernel that is] looks at the
> file for the magic number ``#!'' and if present parses the line
> for the binary to actually exec.  This is true on all Unix systems.

Hmm. Intersting. I must be confusing it with perl's exec, but the "problem"
has been mentioned before and someone hacked a similar "solution".

> You would need to do some profiling to find out what was going on
> but your change would not affect real performance in any measureable way.

The speedup was small, but it was there over a number of tests, which
alternated between my hack switched on and off.

View raw message