[PATCH] D15198: X86InstrInfo::copyPhysReg: workaround reg liveness

JF Bastien via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 3 10:55:22 PST 2015


jfb created this revision.
jfb added reviewers: majnemer, sanjoy.
jfb added a subscriber: llvm-commits.

computeRegisterLiveness and analyzePhysReg are currently getting
confused about liveness in some cases, breaking copyPhysReg's
calculation of whether AX is dead in some cases. Work around this issue
temporarily by assuming that AX is always live.

See detail in: https://llvm.org/bugs/show_bug.cgi?id=25033#c7
And associated bugs PR24535 PR25033 PR24991 PR24992 PR25201.

This workaround makes the code correct but slightly inefficient, but it
seems to confuse the machine instr verifier which now things EAX was
undefined in some cases where it's being conservatively saved /
restored.

http://reviews.llvm.org/D15198

Files:
  lib/Target/X86/X86InstrInfo.cpp
  test/CodeGen/X86/cmpxchg-clobber-flags.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D15198.41782.patch
Type: text/x-patch
Size: 5445 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151203/e008d372/attachment.bin>


More information about the llvm-commits mailing list