[llvm-commits] [llvm] r56911 - in /llvm/trunk/lib/Target/X86: X86Instr64bit.td X86InstrInfo.td

Evan Cheng evan.cheng at apple.com
Wed Oct 1 11:08:14 PDT 2008


On Oct 1, 2008, at 10:34 AM, Dan Gohman wrote:

> On Oct 1, 2008, at 9:46 AM, Evan Cheng wrote:
>
>> Hmmm. There could be more bugs of the kind. Any instruction that
>> touches a non-allocatable register should not be deleted.
>
> The problem with this approach is EFLAGS. It's non-allocatable,
> but treating it as always live means that DCE doesn't end up
> eliminating almost anything.

Ok.

>
>
>> If your DCE
>> is not checking that, then we need to make sure all instructions that
>> touch esp, etc. should mark these uses.
>
> All the PUSHes and POPs are already marked, as are
> ADJCALLSTACKDOWN, and ADJCALLSTACKUP.
>
> Not all the terminator instructions are marked, but I guess it's
> implicitly assumed that ESP/RSP are always live-out.
> DeadMachineInstructionElim currently assumes that all non-allocatable
> registers are live-out, so it currently doesn't care.

Might as well mark RET etc. as ESP users for consistency sake?

>
>
> Are there others?

Not on x86 as far as I can tell.

Evan

>
>
> Dan
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits




More information about the llvm-commits mailing list