[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Problem with 1.2.4 classfiles.. ?



Hi,

I'm trying to debug a problem where SableVM 1.0.5 crashes while
trying to run soot-1.2.4. The crash is demonstrated by this program:

    public class Bar {
	public static void main(String[] args) {
	    new soot.jimple.internal.JimpleLocalBox(null).setValue(null);
	}
    }

    $ sabelvm Bar
    assertion "_svmf_is_assignable_from (env, instance->vtable->type, _svmf_cast_type_class (method->class_info))" failed: file "instructions_preparation_direct_threaded.c", line 17953

I'm trying to figure out if this is a SableVM problem or a bytecode
problem (SableVM does not verify bytecode).

AbstractValueBox (the superclass of JimpleLocalBox) contains this method:

    public abstract class AbstractValueBox implements ValueBox {
	public void setValue(Value value) {
	    if (canContainValue(value)) {
		...

canContainValue() is not implemented in AbstractValueBox but is specified
by the ValueBox interface implemented by AbstractValueBox.

The bytecode supplied with SableVM uses INVOKEVIRTUAL for this call,
specifying the method as "AbstractValueBox.canContainValue()".

However, shouldn't INVOKEINTERFACE be used instead? Is this a bug in
the compiler used to compile Soot? Or is it just a bug in SableVM?

Thanks,
-Archie

__________________________________________________________________________
Archie Cobbs     *     Packet Design     *     http://www.packetdesign.com