limit checks

Matthew Fluet fluet@research.nj.nec.com
Wed, 9 Aug 2000 09:01:38 -0400 (EDT)


> Matthew, would it cause you any trouble if limit checks became a
> MachineOutput.Statement.t and appeared at arbitrary places in the statement list
> instead of being forced to occur at the beginning of a block?

I can't think of any reason.  What I dump for a limit check is not really
different than what's used for an invokeRuntime prim, and they appear
anywhere.

> Actually, this reminds me, since RCPS is gonna know about object sizes and the
> like, it would be nice if we could express limit checks in that IL (an all the
> basic blocks associated with them).  It would be even nicer if the "type system" 
> could check that the limit checks are sufficient.

Interesting.  Doesn't sound too difficult, simply sum up the sizes of all
types associated with an allocation and make sure that's equal to the
limit check size.