This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Re: java/5794: gcj fails to verify .class file generated by Sun JDK1.4 compiler
Eric Blake wrote:
Sun's argument at the above link is that JLS 17.13 require the
compiler to guarantee that the monitor is exited exactly once. If an
asynchronous IllegalMonitorStateException occurs, Sun would rather
have the thread enter an infinite loop than improperly exit the monitor.
Hm. I'm not convinced that this is the "right" solution, but feel
free to check the patch in. I still would prefer it be checked in as
two separate patches, since it fixes (I beleive) two unrelated problems.
Also, please add a note referencing Sun's bug 4414101 to the ChangeLog.
Perhaps:
* verify.c (verify_jvm_instructions): Don't require that the
exception handler target doesn't overlap the range it's guarding.
JDK 1.4 and gives generate "recursive" handlers; see
http://developer.java.sun.com/developer/bugParade/bugs/4414101.html
for an explanation.
(Normally, I'd prefer such an explanation in the code, not the
ChangeLog, but there isn't any place in the code to attach the note!)
--
--Per Bothner
per@bothner.com http://www.bothner.com/per/