From 3bf33075ce98e380fc0ba7aeb5928f1151019887 Mon Sep 17 00:00:00 2001 From: Andrew Trick Date: Fri, 30 Aug 2013 17:58:49 +0000 Subject: Use LiveRangeQuery for instruction-level liveness queries. Remove redundant or bug-prone LiveInterval APIs. llvm-svn: 189685 --- llvm/lib/CodeGen/LiveRangeEdit.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/lib/CodeGen/LiveRangeEdit.cpp') diff --git a/llvm/lib/CodeGen/LiveRangeEdit.cpp b/llvm/lib/CodeGen/LiveRangeEdit.cpp index 86271116f4e..9c374b15019 100644 --- a/llvm/lib/CodeGen/LiveRangeEdit.cpp +++ b/llvm/lib/CodeGen/LiveRangeEdit.cpp @@ -278,7 +278,7 @@ void LiveRangeEdit::eliminateDeadDef(MachineInstr *MI, ToShrinkSet &ToShrink) { // Always shrink COPY uses that probably come from live range splitting. if (MI->readsVirtualRegister(Reg) && (MI->isCopy() || MOI->isDef() || MRI.hasOneNonDBGUse(Reg) || - LI.isKilledAtInstr(Idx))) + LiveRangeQuery(LI, Idx).isKill())) ToShrink.insert(&LI); // Remove defined value. -- cgit v1.2.3