Overflow exception

Matthew Fluet fluet@CS.Cornell.EDU
Fri, 8 Sep 2000 16:54:27 -0400 (EDT)


> Sounds excellent.  Can I lobby MOST strongly for integer ops which detect
> overflow and raise the correct exception.  Please.

What are the real issues with raising overflow on integer operations?  The
exception raising mechanism is uniform, correct:

move to the global variables the arguments for the exception
jump to *(stackBottom + excStack)

Can we dump a global function "raiseOverflow" which does the moves and
jump and then add
jo raiseOverflow
after the appropriate arithmetic instructions?  Or is there something else
subtle that I'm missing?  Will there be other issues because elsewhere the
compiler doesn't assume that arithmetics could raise?