[kaffe] x86 trampoline brokenness and classloader problem

Godmar Back gback@stanford.edu
Mon, 12 Aug 2002 10:10:31 -0600 (MDT)


 FWIW,

I remember making multiple changes to the ClassNotFound/NoClassDef
stuff to keep compatible with multiple changes Sun did to its
implementation over the years.  So it's not surprising that the
JLS isn't exactly clear on it.  I'd simply go with whatever
behavior the latest Sun JDK shows for a given test case.

	- Godmar

(Btw, Tim's problem with the missing
stack frame sounded familiar, too - I now remember from where:
I encountered that missing stack frame in the gcj work.)

> 
> Hi Tim,
> --- Timothy Stack <stack@cs.utah.edu> wrote:
> 
> > Now, onto the problem that exposed the above
> > problem...  The exception 
> > handling code in classMethod.c:loadClass() doesn't
> > appear to do the 
> > right thing, if a user ClassLoader throws a
> > ClassNotFoundException, it 
> > will just pass this up to the caller.  Shouldn't
> > this be converting the 
> > ClassNotFound to a NoClassDefFoundError and marking
> > the errorInfo.type 
> > with KERR_NO_CLASS_FOUND?  Otherwise, the verifier
> > will fail too quickly 
> > and the jitter will throw a ClassNotFoundException,
> > which is neither a 
> > RuntimeException or Error and shouldn't be thrown
> > willy nilly.
> 
> I haven't found a clear citation about it in the JVM
> spec 2, but the JLS 2 says in $12.2.1:
> 
> If an error occurs during class loading, then an
> instance of one of the following subclasses of class
> LinkageError will be thrown at any point in the
> program that (directly or indirectly) uses the type:
> [snip]
> * NoClassDefFoundError: No definition for a requested
> class or interface could be found by the relevant
> class loader. 
> 
> So this one seems to support your point. Can you come
> up with a test that demonstrates the problem for the
> regression test suite?
> 
> best regards,
> 
> dalibor topic
> 
> __________________________________________________
> Do You Yahoo!?
> HotJobs - Search Thousands of New Jobs
> http://www.hotjobs.com
> 
> _______________________________________________
> kaffe mailing list
> kaffe@kaffe.org
> http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
>