[MLton-devel] exceptions

Suresh Jagannathan suresh@cs.purdue.edu
Mon, 6 Jan 2003 18:32:13 -0500


Apropos the representation of exceptions in Java, in the Java compiler we 
wrote at NEC, handlers were not kept on the stack at all, but in the code 
stream along with the gc mask below the return address.  Handlers and gc 
masks were always at a fixed offset from return addresses, so when an 
exception was raised it was easy to jump to.  This had the advantage of not 
having to do any work at runtime to push handlers, with slight complication 
to code generation.  I'm not sure if other Java compilers have adopted 
a similar approach, but I recall we were quite pleased with the design.

-- sj


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
MLton-devel mailing list
MLton-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mlton-devel