<div dir="ltr">Hello Eliot and all,<div><br></div><div>Recently I watched a video of Eliot introducing Cog (<a href="http://www.youtube.com/watch?v=-ei1bnLHdhA">http://www.youtube.com/watch?v=-ei1bnLHdhA</a> part 1 to 7).</div>

<div><br></div><div>At some point, Eliot says that a better code generator was planned with optimizations such as constant folding and stack to register mapping (I guess it does exist, but as a prototype only). However, it seems that this last optimization (register allocation) is tricky to manage with the debugger: in the Self VM, it seems that the contexts were in read-only in the debugger because they didn&#39;t know if the variable was stored in a register or in the memory.</div>

<div><br></div><div>Now I know that Eliot wouldn&#39;t have planned an optimization that will destroy the debugging power of Squeak. How did you guys plan to add the register allocation without destroying the debugging power of Squeak ? </div>

<div><br></div><div>Did you plan to add something similar to the scope descriptor that they have in the Self VM to allow aggressive optimizations with regular debugging ? Did you plan to annotate the stack frames with meta data and if so, how would you have implemented it ?</div>

<div><br></div><div>Thanks for any answers,</div><div><br></div><div>Clement</div></div>