Please have a look at this article.

Yes, perlcc exists and can gain you some speed, but what it mainly is is a compiled dispatcher so that the byte-code doesn't have to be generated and parsed. The real work is still done by calling into the code for the perl operators.

Also notice that perl does quite a bit by evaluating code at runtime, so the interpreter is still needed even in compiled programs.

Still, it is true that initial perl load and code compile take a noticeable time if afterward very little running will be going on. This isn't a problem if a piece of code only runs once, but gets painful if it's run very often (e.g. typically seen in CGI). The generally used solution for this is in the perl world is persistent interpreters. For that, look at things like (for CGI) mod_perl, FastCGI and (generally useful) SpeedyCGI

When in your question you referred to apache holding the compiled code, you were probably talking about mod_perl. And since you wanted to apply that generally, SpeedyCGI is probably the answer you were looking for. Notice that there is no real need to have this kind of functionality builtin. These modules demonstrate that you can get the effect purely from what already exists.


In reply to Re: Compiled Perl by thospel
in thread Compiled Perl by mkenney

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.