Florian Weimer wrote:

http://www-128.ibm.com/developerworks/java/library/j-jtp09275.html - Yummy.

Soot and JCVM already implement this as well, IIRC.  The problems Tim
mentioned are addressed by JCVM by relying on inlining to expose stack
allocation opportunities.
The conclusion reached in the OOPSLA paper referred to (Choi et al 1999) is that stack allocation produced a relatively insignificant speedup, but that locking optimizations for objects that don't escape thread context was significant.

In a heap with a bump-pointer allocator, allocation is cheap. Stack allocation can potentially produce a slow-down by reducing locality in the stack, and complicating the task of scanning the stack.

-- Robin

Reply via email to