From f262b355593100c6e0fc629b03c76ab0b1e2d915 Mon Sep 17 00:00:00 2001 From: Evan Cheng Date: Wed, 7 Mar 2007 02:36:16 +0000 Subject: [PATCH] Add skipTo to set internal iterator. Useful when pointed to instruction is deleted. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34997 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/CodeGen/RegisterScavenging.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/llvm/CodeGen/RegisterScavenging.h b/include/llvm/CodeGen/RegisterScavenging.h index c99c3eaab40..7fe477998a7 100644 --- a/include/llvm/CodeGen/RegisterScavenging.h +++ b/include/llvm/CodeGen/RegisterScavenging.h @@ -79,6 +79,10 @@ public: while (MBBI != I) backward(); } + /// skipTo - Move the internal MBB iterator but do not update register states. + /// + void skipTo(MachineBasicBlock::iterator I) { MBBI = I; } + /// isReserved - Returns true if a register is reserved. It is never "unused". bool isReserved(unsigned Reg) const { return ReservedRegs[Reg]; }