x86 self-compile

Stephen Weeks MLton@sourcelight.com
Wed, 2 Aug 2000 13:46:58 -0700 (PDT)


> I'm surprised you think the performance hit is coming from register
> allocation (as I presume better liveness analysis is only going
> to benefit allocation).  

The problem is that the register allocator works only on a basic block at a
time.  It therefore has to flush all pseudo registers to there corresponding
memory locations at the end of a basic block.  In the C backend, the pseudo
registers are C automatic variables, and the C register allocator is (we
conjecture) doing a decent job of liveness analysis and is avoiding the
flushes.  From the mods I've already made to propagate liveness info, we have
see that a lot of the regs are dead.  We should know soon how much it buys us.

> I'd have thought that instruction selection
> and general code-generation issues would have dominated.  
> Have you
> guys had a chance to look at the assembly output to eyeball 
> code-generation/instruction selection quality?

I haven't.