From 9435eda6993944e74419d2f586fdd25635293760 Mon Sep 17 00:00:00 2001 From: Alkis Evlogimenos Date: Sat, 13 Dec 2003 05:26:39 +0000 Subject: [PATCH] Handle explicit physical register defs. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10445 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/LiveIntervalAnalysis.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/CodeGen/LiveIntervalAnalysis.cpp b/lib/CodeGen/LiveIntervalAnalysis.cpp index c9f7b34c0b7..2a31e66851e 100644 --- a/lib/CodeGen/LiveIntervalAnalysis.cpp +++ b/lib/CodeGen/LiveIntervalAnalysis.cpp @@ -286,12 +286,15 @@ void LiveIntervals::computeIntervals() for (int i = instr->getNumOperands() - 1; i >= 0; --i) { MachineOperand& mop = instr->getOperand(i); - if (!mop.isVirtualRegister()) + if (!mop.isRegister()) continue; if (mop.opIsDefOnly() || mop.opIsDefAndUse()) { unsigned reg = mop.getAllocatedRegNum(); - handleVirtualRegisterDef(mbb, mi, reg); + if (reg < MRegisterInfo::FirstVirtualRegister) + handlePhysicalRegisterDef(mbb, mi, reg); + else + handleVirtualRegisterDef(mbb, mi, reg); } } }