[kaffe] Kaffe JIT on Alpha

Kevin D. Kissell kevink at mips.com
Sun Apr 20 10:20:02 PDT 2003


I don't have any specific advice, but as I have been working
periodically on getting the MIPS JIT working again, I have
been following this thread with some interest.

Just to remind Kapil, the MIPS JIT, if built from 1.0.7 sources
with a few patches I posted last year, will build, but fails 5 out
of 116 regression tests.  I managed to figure out and fix one 
failure - and yes, I know I owe the group the necessary patch.
The remaining failures do look superficially like some of what
you have described - null pointer exceptions where none should
be possible.  I have generated JIT translation traces and used
gdb to try to isolate them, and they seem to be due to null pointers
in data structures that are otherwise OK, as if the JIT code was
somehow fogetting to commit a non-zero result to memory in
some unusual case(s).  It would not surprise me, given the similarity
between the Alpha and MIPS architectures, if there was some
common underlying problem, something that was assumed by
these RISC ports that changed in the architecture-independent
code somewhere allong the line in ways that don't hurt the x86
port.  The coincidences continue in your report of problems
with the CVS build.  Whereas, as I said, a patched 1.0.7 kaffe
will generate an *almost* functional MIPS JIT, building from
the CVS sources fails in trying to compile the @essential files
under MIPS with JIT enabled.  The error isn't exactly the same,
but it's striking.  Of course, it all could be a coincidence, but it
wouldn't surprise me if there were at least one common underlying
bug.

I'm busy dealing with non-Java, non-kaffe stuff for the next several
weeks, but I'll be watching this with some interest.

Note that Dalibor has been able to get the MIPS JIT under IRIX
from CVS sources past the @essential files build failure by using
Jikes instead of kaffe to build the class libraries.  If you do that,
you should be able to build with --enable-debug, set KAFFE_DEBUG 
to "gdb" (or whatever), install the crippled kaffe, and invoke it with 
--vmdebug JIT,MORE_JIT under the debugger, piping the output
to "tee" to get a trace fule, to get some idea of what's going on...

            Regards,

            Kevin K.

----- Original Message ----- 
From: "Kapil Vaswani" <kapil at csa.iisc.ernet.in>
To: "Dalibor Topic" <robilad at yahoo.com>; "kaffe" <kaffe at kaffe.org>
Sent: Sunday, April 20, 2003 4:44 PM
Subject: Re: [kaffe] Kaffe JIT on Alpha


> Hi Dalibor,
> 
> Thanks for the prompt reply. I am trying to compile the latest kaffe 
> version from CVS configured using "--with-staticlib --with-staticvm 
> --without-x --without-awt --enable-debug --enable-ltdl-convenience" on 
> an alpha osf1. I had to patch external.c (line 269) for the build to go 
> proceed.
> 
> #ifdef HAVE_SNPRINTF
>                                 snprintf (errbuf, errsiz, "%s: not found",
>                                           last_sep==NULL?path:last_sep+1);
> #else
>                                 /* possible buffer overflow problem */
>                                 if(errbuf != 0)
>                                     sprintf (errbuf, "%s: not found",
>                                           last_sep==NULL?path:last_sep+1);
> #endif
> 
> I also had to comment out the use of inet_ntop function in 
> clib/net/NetworkInterface.c, since that function wasnt available either.
> 
> The build however fails while building javalib as follows.
> 
> /bin/ksh ./rebuildLib @essential.files
> Compiling classes from @essential.files using  
> /global/utemp/csakapil/kaffe/kaffe/kaffe/kaffe-bin -verbosegc 
> at.dms.kjc.Main
> Internal error: caught an unexpected exception.
> Please check your CLASSPATH and your installation.
> java/lang/UnsatisfiedLinkError: dlopen: cannot load 
> /global/utemp/csakapil/kaffe/libraries/clib/native/libio.so
> ./rebuildLib[47]: 29887 Resources lost(coredump)
> make[1]: *** [lib/stamp] Error 134
> make[1]: Leaving directory `/global/utemp/csakapil/kaffe/libraries/javalib'
> make: *** [all-recursive] Error 1
> 
> Does this point to something wrong with my configuration??
> 
> Thanks again..
> 
> Kapil
> 
> Dalibor Topic wrote:
> 
> >Hi Kapil,
> >
> >--- Kapil Vaswani <kapil at csa.iisc.ernet.in> wrote:
> >  
> >
> >>Hi,
> >>
> >>I would like to know whether the kaffe v1.0.7 port for alpha on osf1 
> >>supports the JIT. Although I have been able to compile and install kaffe 
> >>    
> >>
> >
> >Kaffe supports a jit on alpha-osf since december 2000.
> >http://www.kaffe.org/pipermail/kaffe/2000-December/026104.html
> >
> >  
> >
> >>with the JIT engine (with a tweak involving an unresolved snprintf in 
> >>external.c, snprintf is not supported on osf), I get the following 
> >>    
> >>
> >
> >Could you try the latest CVS version? If that one doesn't work (anf thr patch
> >makes it build), please post the patch.
> >
> >  
> >
> >>message when kaffe or javac is invoked. I have been able to run the 
> >>interpretor without problems. Any help will be appreciated.
> >>    
> >>
> >
> >  
> >
> >>%>kaffe Test
> >>Internal error: caught an unexpected exception.
> >>Please check your CLASSPATH and your installation.
> >>java/lang/NullPointerException
> >>Abort process (core dumped)
> >>    
> >>
> >
> >If you give the CVS version a try, please take a look at FAQA/FAQ.debugging,
> >and post a stack trace of the exception in question.
> >
> >cheers,
> >dalibor topic
> >
> >__________________________________________________
> >Do you Yahoo!?
> >The New Yahoo! Search - Faster. Easier. Bingo
> >http://search.yahoo.com
> >
> >_______________________________________________
> >kaffe mailing list
> >kaffe at kaffe.org
> >http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
> >
> >  
> >
> 
> 
> 
> _______________________________________________
> kaffe mailing list
> kaffe at kaffe.org
> http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
> 




More information about the kaffe mailing list