Comment 5 for bug 681092

Revision history for this message
Alastair Bridgewater (alastair-bridgewater) wrote :

It occurs to me that the second problem (tail-call with a d-x closure as a parameter) is a non-issue because it's predicated on the existence of a stack-allocated closure object, the cleanup for which would prevent any call being in the tail position.

A bare-minimum KLUDGE for the first problem (lifetime for closure value cell TNs post-tail-call) could be to add all of the "implicit" value cells to the environment-live list for the callee function during ir2tran, though that would depend on the order of conversion of nested tail-calls, which isn't something that I'm comfortable relying on long-term.