develooper Front page | perl.perl6.internals | Postings from October 2002

Re: Perl 6 Summary for last week (JVM->PBC)

Gopal V
October 22, 2002 06:53
Re: Perl 6 Summary for last week (JVM->PBC)
Message ID:
If memory serves me right, Piers Cawley wrote:

/me is a newcomer from DotGNU ... and has missed the mails quoted,
    hence here's what I have ..

>   Regarding JVM - Parrot Compatibility
>     Newcomer Karthik Kumar is interested in writing a tool to convert java
>     ".class" files to parrot ".pbc" files and asked for information on what
>     had been done in this area. 

I had a run-in with JILC (, in which
the entire JVM loading and disassembly was hijacked from my curriculum project
work.... The ILC part is still lacking (the reasons for /me giving up is
simple, those people started :-)

But KK should be able to make use of the code atleast partially ...

>     it's very easy to get the basics working because of the low 
>     number of JVM bytecodes.  

Don't fall into that trap .... /me has made that mistake once ...
In JVM a localvariable can contain any data type , viz ints,floats,
or objects.. It takes a lot of flow analysis to figure out what
type is in a particular localvar.. 

goto jmp1
goto jmp2
pop // or maybe a toString() which clears the stack ?
pop // or a println();

is a valid bytecode formation ... viz, I need to split
this into 2 localvars and track with type information for IL ...
(no, it's not an undecidability problem , but still it's difficult
 which is yet another reason why JILC got left in the wayside)

I'm assuming that parrot will need a similar mapping to store 
to the 'I' and 'F' type registers ?

The difference between insanity and genius is measured by success Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About