Hi Andreas,
It's a problem with your class file, not a problem with SableVM.
Using Sun's JDK:
$ java -verify BFprogram
Exception in thread "main" java.lang.ClassFormatError: BFprogram (Extra bytes at the end of the class file)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:537)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:251)
at java.net.URLClassLoader.access$100(URLClassLoader.java:55)
at java.net.URLClassLoader$1.run(URLClassLoader.java:194)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
at java.lang.ClassLoader.loadClass(ClassLoader.java:289)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:274)
at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
ooO( lucky me! ) ;-)
Etienne
PS: SableVM has no verifier, yet it does actually enforce some basic
stuctural integrity rules on class files.
Andreas Heck wrote:
> Hello everybody,
>
> I have run into a execution problem with SableVM. When I start the
> program which is appended to this mail on LinuxPPC with SableVM I get
> the following error message:
>
> java.lang.ClassFormatError
>
> When I execute it with kaffe on the same machine or with Sun's jre 1.4.2 on
> Win2K it runs without any problems.
>
> The program is written in jasmin assembly code. Don't wonder about the
> weird code. It's the output of a brainfuck compiler I'm playing around
> with at the moment.
>
>
> Andreas
>
--
Etienne M. Gagnon, Ph.D. http://www.info.uqam.ca/~egagnon/
SableVM: http://www.sablevm.org/
SableCC: http://www.sablecc.org/
|