Matt Fowles wrote:

Have we seen that this actually destroys us?  Meaning, if we add the
extra CFG arcs, do we start spilling like mad?  If not, this is much
ado about nothing.

Please first have a look at Dan's recent posting about Evil Sub. Then estimate, how many subs may be called in 14000 basic blocks. For 100 subs only you get ~10000 more edges ...


Second, having this arcs means just that in that range i.e. from the first subroutine to the last, you can't reuse a register around a call.
Question: how many from ~23000 registers might be effected. Please note the currently rather low spill count despite the huge register usage.


I proposed an alternate scheme that has minimal impact on existing
code.

C source code or bytecode? The latter isn't effected at all in my scheme if you just swap the two register ranges (I don't care currently). The impact on C source changes would be low, even JIT works with just s/ctx\.bp/ctp/g


... Right now we guarantee that return continuations restore all
non-volatile registers.  If we extend that guarantee to all
continuations, everything would just work with the caveat that changes
to value registers (as opposed to reference registers) are lost.  This
is not a real loss though because refetch all lexicals already
requires backing store for I and N registers.

You are missing the point. It's not a question of preserving, it's register re-using. And forcing all I and N registers into lexical PMCs totally defeats the optimized usage of these registers.


Matt

leo



Reply via email to