Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Parrot, Java, and Harmony

by dragonchild (Archbishop)
on May 17, 2005 at 19:02 UTC ( #457952=perlquestion: print w/replies, xml ) Need Help??
dragonchild has asked for the wisdom of the Perl Monks concerning the following question:

Slashdot had a couple threads about a new OSS implementation of J2SE 5 called Harmony. A common thread in the responses to both root nodes was that implementing a stable and well-performing JVM is a non-trivial task. I don't think anyone's going to disagree.

Enter Parrot. Back in 2001, Leon Brocard was reported as working on a Java bytecode -> Parrot bytecode converter. Presumably, writing a Java->Parrot compiler shouldn't be that hard, given the success of Pugs.

Am I missing something fundamental or is Harmony wasted effort? And, if so, who wants to tell them?


  • In general, if you think something isn't in Perl, try it out, because it usually is. :-)
  • "What is the sound of Perl? Is it not the sound of a wall that people have stopped banging their heads against?"

Replies are listed 'Best First'.
Re: Parrot, Java, and Harmony
by perrin (Chancellor) on May 17, 2005 at 19:08 UTC
    The majority of the work in duplicating Java is in writing the incredibly huge class library. That's probably a bigger project by itself than all of Parrot. There is also a fair amount of stuff that is expected from a JVM these days, in terms of fancy remote debugging and profiling hooks, which may or may not be in Parrot.
        Classpath is very far from being complete.
Re: Parrot, Java, and Harmony
by hardburn (Abbot) on May 17, 2005 at 19:08 UTC

    Java (the language) -> Parrot shouldn't be any more difficult than any other language (certainlly easier than Perl5, and probably Perl6, too). Java Bytecode -> Parrot is iffy. I noticed that Microsoft ships a Java Bytecode -> CLR Bytecode converter with the .NET SDK, but I don't know how well it works.

    Any static language built on Parrot will have the disadvantage that Parrot is meant for dynamic langauges. That's a lot of extra overhead that can be ditched if you're focusing on languages that tend to be static.

    "There is no shame in being self-taught, only in not trying to learn in the first place." -- Atrus, Myst: The Book of D'ni.

Re: Parrot, Java, and Harmony
by radiantmatrix (Parson) on May 17, 2005 at 19:41 UTC

    The advantage to a project like Harmony, at least IMO, is to free an otherwise-acceptable langauge (Java) from the confines of a pretty stupid license granted by a pretty annoying company (Sun).

    The Java standard, you see, is public. However, the reference implementation -- that is, Sun's JDK/JRE -- is only sorta-open. The goal of Harmony is to create a JVM that is free of the PITA license of Sun's JVM, and that could (for example) be packaged alongside Apache or an application.

    The added motivation is that once such a huge task is complete, the OpenSource development model can take opportunities to improve its performance. Also, once the JVM is complete it could very easily be "ported into" projects like Tomcat, where an intimate level of integration could really improve the speed of servlets.

    As far as the Java->Parrot converter, I suspect that's a bit easier, as it could require the extant JVM to be installed (along with the extensive class library) for the conversion process. No need to write all of that JVM code from scratch to do conversion.


    The Eightfold Path: 'use warnings;', 'use strict;', 'use diagnostics;', perltidy, CGI or CGI::Simple, try the CPAN first, big modules and small scripts, test first.

Re: Parrot, Java, and Harmony
by lachoy (Parson) on May 18, 2005 at 02:54 UTC

    Prediction: Perl 6 will have not only a handful of releases but a whole slew of O'Reilly and Apress books before Harmony is usable by anyone other than the hardcore developers for a non-trivial application.

    And don't worry, plenty of people are telling them it's a wasted effort, but I don't think it matters. The BileBlog is always good for a few laughs...

    Chris
    M-x auto-bs-mode

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://457952]
Approved by jfroebe
help
Chatterbox?
usemodperl remembers the hilarious merlyn bot
[usemodperl]: perl is not broken, perl is being broken by the web being broken by https, for the love of banking apps on free wifi at coffee shops or something...
[Veltro]: Wondering, would it be so hard to write a small application that you can access using http which forwards the request over web ussing ssl?
[Veltro]: are there not even tools for that?
[usemodperl]: the breakage is so fresh i guess not, so it's up to us! :-)
[usemodperl]: someone has yet to make that future famous free http to https proxy written in perl and supported by ads, paypal, patreon, etc to make millions of dollars a minute!
[Veltro]: Why would this be fresh, I recon this is stuff that happens all the time (not Perl per se)
[Corion]: usemodperl: I'm sure you could even code that on the command line.

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (9)
As of 2018-06-24 16:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should cpanminus be part of the standard Perl release?



    Results (126 votes). Check out past polls.

    Notices?