aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/RegAllocSimple.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-12-15 21:13:12 +0000
committerChris Lattner <sabre@nondot.org>2002-12-15 21:13:12 +0000
commit8233e2fe01b76071a1875d8ffb9252c87ca4675b (patch)
treea8e0a21fcc10fccd677acfae10575220e6d1f23a /lib/CodeGen/RegAllocSimple.cpp
parent15f96db4d91eba096b7eaa36d8f891131412e064 (diff)
Give simple reg allocator a nice Pass Name
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5058 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/RegAllocSimple.cpp')
-rw-r--r--lib/CodeGen/RegAllocSimple.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/CodeGen/RegAllocSimple.cpp b/lib/CodeGen/RegAllocSimple.cpp
index 17b1044c5c..73c193ba5b 100644
--- a/lib/CodeGen/RegAllocSimple.cpp
+++ b/lib/CodeGen/RegAllocSimple.cpp
@@ -80,6 +80,10 @@ namespace {
return runOnMachineFunction(MachineFunction::get(&Fn));
}
+ virtual const char *getPassName() const {
+ return "Simple Register Allocator";
+ }
+
private:
/// runOnMachineFunction - Register allocate the whole function
bool runOnMachineFunction(MachineFunction &Fn);
@@ -328,7 +332,7 @@ void RegAllocSimple::EliminatePHINodes(MachineBasicBlock &MBB) {
saveVirtRegToStack(opBlock, opI, virtualReg, physReg);
} else {
// Allocate a physical register and add a move in the BB
- unsigned opVirtualReg = (unsigned) opVal.getAllocatedRegNum();
+ unsigned opVirtualReg = opVal.getAllocatedRegNum();
unsigned opPhysReg;
opI = moveUseToReg(opBlock, opI, opVirtualReg, physReg);