Possible bytecode verifier issues

Ranjit Mathew rmathew4lists@hotmail.com
Fri Feb 28 11:26:00 GMT 2003


> Ranjit Mathew writes:
>  > A MinGW GCJ user seems to be running into bytecode
>  > verification problems with GCJ 3.2 and now GCJ 3.3:
>  >
>  >
http://sourceforge.net/tracker/index.php?func=detail&aid=693547&group_id=2435&atid=102435
>  >
>  > With 3.2, he used to get lots of "bad pc in
>  > exception_table" errors which disappeared with 3.3,
>  > but now he gets "warning: exception handler inside
>  > code that is being protected" warnings.
>  >
>  > Is this is a known issue with GCJ or could it be
>  > that his class bytecodes are really SNAFU-ed?
>
> I have worked on this code.  gcj is almost certainly correct about
> this.

Quite likely. The original submitter ("djobet" on SF) notes that,
as suggested by Tom, when he recompiled with JDK 1.3, the
problem disappeared.

So it's likely a bug with the JDK 1.4 compiler.

Note that at least according to the following document:

    http://java.sun.com/sfaq/verifier.html

(section "Exception Handlers") even if the bytecode fails these
conditions the verifier would not complain about it.

Not that I'm suggesting we do the same - IMHO it's good to
know that one has crappy bytecode on hand. :-)

Ranjit.



More information about the Java mailing list