From 923d199a67350e30f4d38856238383a8261cfbbc Mon Sep 17 00:00:00 2001 From: Lang Hames Date: Wed, 15 Feb 2012 23:21:33 +0000 Subject: Make LiveIntervals::handleMove() bundle aware. llvm-svn: 150630 --- llvm/lib/CodeGen/MachineInstr.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'llvm/lib/CodeGen/MachineInstr.cpp') diff --git a/llvm/lib/CodeGen/MachineInstr.cpp b/llvm/lib/CodeGen/MachineInstr.cpp index ff32a66..52a9096 100644 --- a/llvm/lib/CodeGen/MachineInstr.cpp +++ b/llvm/lib/CodeGen/MachineInstr.cpp @@ -900,6 +900,16 @@ bool MachineInstr::isBundled() const { return nextMI != Parent->instr_end() && nextMI->isInsideBundle(); } +MachineInstr* MachineInstr::getBundleStart() { + if (!isInsideBundle()) + return this; + MachineBasicBlock::reverse_instr_iterator MII(this); + --MII; + while (MII->isInsideBundle()) + --MII; + return &*MII; +} + bool MachineInstr::isStackAligningInlineAsm() const { if (isInlineAsm()) { unsigned ExtraInfo = getOperand(InlineAsm::MIOp_ExtraInfo).getImm(); -- cgit v1.1