Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
What exactly is your edge case? Maybe there is a better way to solve your problem, like fixing a particular poorly performing opcode in perl, or a couple XS functions, than taking the most difficult choice.

And what are the resources you can supply for your idea (time, $, PhDs, patents, etc)?

If you are going to do it yourself, just do it. You dont need anyones permission. Perl is open source. Once you have a working prototype with before and after benchmarks, you will start to attract volunteers and corporate users and the rest is history. Not to mention Perl does have hooks for optimizers and "custom" opcodes. You can always JIT an optimizable Perl sub into what perl thinks is XSUB, just change the right fields in the CV struct.

If I were you, I would hire a couple programmers with knowledge in compiler design/HLA/interpreter VMs, select a couple Perl subs no more than 1 screenful each off of CPAN, the selection doesn't need to be random, there can be a bias, but it must have enough ";"s, have the programmers try and see if they can compile the Perl subs from A. Human Perl or, B. Bytecode Perl to one or more popular bytecode interpreters, Web Grade Javascript, LLVM, .NET CIL, Java bytecode, really anything. Measure the benchmarks of the before and after. If its faster, great, publish it, you don't need anyones permission. If its slower, try a different VM target. Your real work is how to convert Perl to something closer to the hardware. Anyone can writing Perl interpreter that targets any other programing language that is Turing complete but speed would be much worse than today. I dont know what perlito's current speed is against perl. Someone should research that.

Maybe the question you really want to ask is, not whether Perl 5 can use LLVM, but what is the future of LLVM by itself?

I will guess the future is excellent, it is OSX's primary compiler. Apple seems to be the primary sponsor and financier of LLVM. It is not going away anytime soon.

update: there are other people who have ideas on JIT to machine code in perl http://www.nntp.perl.org/group/perl.xs/2012/07/msg2709.html

In reply to Re^4: Perl 5 Optimizing Compiler, Part 4: LLVM Backend? by bulk88
in thread Perl 5 Optimizing Compiler, Part 4: LLVM Backend? by Will_the_Chill

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



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2024-04-26 00:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found