19 May 2004 kristian   » (Master)

Work on my whirl2il thing is progressing:

kris@rainbow-colored-lizard:/tmp$ cat > foo.c
static int get_return_val (void)             
{
        return 23;
}
int main (void)
{
        int i = get_return_val ();
        return i;
}
kris@rainbow-colored-lizard:/tmp$ /source/open64/osprey1.0/targia32_ia64_nodebug/gccfe/gfec foo.c > /dev/null
kris@rainbow-colored-lizard:/tmp$ ~kris/projects/whirl2il/whirl2il foo.B > foo.il
kris@rainbow-colored-lizard:/tmp$ cat foo.il 
.module 'foo.B'
.method public static int32 get_return_val() cil managed {
        ldc.i4 23
        ret
}
.method public static int32 main() cil managed {
        .entrypoint
        .locals init (
                int32 i
        )
        call int32 get_return_val()
        stloc.0
        ldloc.0
        ret
}
kris@rainbow-colored-lizard:/tmp$ ilasm foo.il
Assembling 'foo.il' , no listing file, to exe --> 'foo.exe'
Compilation succeeded
kris@rainbow-colored-lizard:/tmp$ mono foo.exe
kris@rainbow-colored-lizard:/tmp$ echo $?
23

Latest blog entries     Older blog entries

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!