summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-12-16 14:37:00 +0000
committerChris Lattner <sabre@nondot.org>2002-12-16 14:37:00 +0000
commitc63d63a7c7286ee6bfc1ebecd3095b3768d05a5a (patch)
treec8bf6383ca41facece3df2ed9b6414627c82ddef /llvm/lib
parent6ebe95953096971173fdeda9cd3eac7ebbbb2ae2 (diff)
downloadbcm5719-llvm-c63d63a7c7286ee6bfc1ebecd3095b3768d05a5a.tar.gz
bcm5719-llvm-c63d63a7c7286ee6bfc1ebecd3095b3768d05a5a.zip
Rename createSimpleX86RegisterAllocator to createSimpleRegisterAllocator.
Remvoe some dead code llvm-svn: 5070
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/CodeGen/RegAllocSimple.cpp30
1 files changed, 2 insertions, 28 deletions
diff --git a/llvm/lib/CodeGen/RegAllocSimple.cpp b/llvm/lib/CodeGen/RegAllocSimple.cpp
index b299ddd1bf9..9ed6ad98953 100644
--- a/llvm/lib/CodeGen/RegAllocSimple.cpp
+++ b/llvm/lib/CodeGen/RegAllocSimple.cpp
@@ -1,4 +1,4 @@
-//===-- RegAllocSimple.cpp - A simple generic register allocator --- ------===//
+//===-- RegAllocSimple.cpp - A simple generic register allocator ----------===//
//
// This file implements a simple register allocator. *Very* simple.
//
@@ -12,32 +12,6 @@
#include <iostream>
#include <set>
-#if 0
-/// PhysRegClassMap - Construct a mapping of physical register numbers to their
-/// register classes.
-///
-/// NOTE: This class will eventually be pulled out to somewhere shared.
-///
-class PhysRegClassMap {
- std::map<unsigned, const TargetRegisterClass*> PhysReg2RegClassMap;
-public:
- PhysRegClassMap(const MRegisterInfo *RI) {
- for (MRegisterInfo::const_iterator I = RI->regclass_begin(),
- E = RI->regclass_end(); I != E; ++I)
- for (unsigned i=0; i < (*I)->getNumRegs(); ++i)
- PhysReg2RegClassMap[(*I)->getRegister(i)] = *I;
- }
-
- const TargetRegisterClass *operator[](unsigned Reg) {
- assert(PhysReg2RegClassMap[Reg] && "Register is not a known physreg!");
- return PhysReg2RegClassMap[Reg];
- }
-
- const TargetRegisterClass *get(unsigned Reg) { return operator[](Reg); }
-};
-#endif
-
-
namespace {
Statistic<> NumSpilled ("ra-simple", "Number of registers spilled");
Statistic<> NumReloaded("ra-simple", "Number of registers reloaded");
@@ -367,6 +341,6 @@ bool RegAllocSimple::runOnMachineFunction(MachineFunction &Fn) {
return true;
}
-Pass *createSimpleX86RegisterAllocator(TargetMachine &TM) {
+Pass *createSimpleRegisterAllocator(TargetMachine &TM) {
return new RegAllocSimple(TM);
}
OpenPOWER on IntegriCloud