Rhys Weatherley wrote:

The Portable.NET C# compiler, cscc, is very extensive, and is
capable of generating output for multiple bytecode formats (IL
and JVM are currently supported, more or less).

Have a look at imcc, which is our high level assembler. imcc does register allocation and (currently little) optimization. perl6 produces IMCC code. imcc can also run the code or write PBC files.


I'm a bit confused as to how one creates a user-defined class
in Parrot, and makes virtual method calls, accesses fields,
and what-not.

Not yet.


Is there a convention for which registers must be saved
across a call and which can be clobbered?

docs/pdds/pdd03_calling_conventions.pod

... Is the JIT smart enough to optimize
away unnecessary copies?

AFAIK no, optimzation should be done one level up, so all run cores would benefit.


What is the size of the "int" type? Will it always be 32 bit
or is it "whatever is best for the machine"?

It's a Configure option.

And how do
I perform a "sign extend" operation?

We currently have only one INTVAL, it should promote to BIGINT.


Is there some means to store and access auxillary data in
a Parrot bytecode file?  I might need this to store metadata
for supporting C# reflection.

There was some discussion WRT extending the bytecode format not too long ago: s. Subject "RFC: static line number information".


Cheers,

Rhys.
leo

Reply via email to