summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/Sparc/SparcRegisterInfo.cpp
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2011-06-24 01:44:41 +0000
committerEvan Cheng <evan.cheng@apple.com>2011-06-24 01:44:41 +0000
commit247533179a3e39f78e9da3c7d25093df2b87371c (patch)
tree2e31c40e1ed74e452b2f1ff59b04e9c97b082408 /llvm/lib/Target/Sparc/SparcRegisterInfo.cpp
parent44c9b3758fda7443a201d71925a5b51b1cf4aaf2 (diff)
downloadbcm5719-llvm-247533179a3e39f78e9da3c7d25093df2b87371c.tar.gz
bcm5719-llvm-247533179a3e39f78e9da3c7d25093df2b87371c.zip
Starting to refactor Target to separate out code that's needed to fully describe
target machine from those that are only needed by codegen. The goal is to sink the essential target description into MC layer so we can start building MC based tools without needing to link in the entire codegen. First step is to refactor TargetRegisterInfo. This patch added a base class MCRegisterInfo which TargetRegisterInfo is derived from. Changed TableGen to separate register description from the rest of the stuff. llvm-svn: 133782
Diffstat (limited to 'llvm/lib/Target/Sparc/SparcRegisterInfo.cpp')
-rw-r--r--llvm/lib/Target/Sparc/SparcRegisterInfo.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Target/Sparc/SparcRegisterInfo.cpp b/llvm/lib/Target/Sparc/SparcRegisterInfo.cpp
index 9fcf028fa60..c63f52e9589 100644
--- a/llvm/lib/Target/Sparc/SparcRegisterInfo.cpp
+++ b/llvm/lib/Target/Sparc/SparcRegisterInfo.cpp
@@ -23,11 +23,14 @@
#include "llvm/Type.h"
#include "llvm/ADT/BitVector.h"
#include "llvm/ADT/STLExtras.h"
+#include "SparcGenRegisterDesc.inc"
+#include "SparcGenRegisterInfo.inc"
using namespace llvm;
SparcRegisterInfo::SparcRegisterInfo(SparcSubtarget &st,
const TargetInstrInfo &tii)
- : SparcGenRegisterInfo(SP::ADJCALLSTACKDOWN, SP::ADJCALLSTACKUP),
+ : SparcGenRegisterInfo(SparcRegDesc, SparcRegInfoDesc,
+ SP::ADJCALLSTACKDOWN, SP::ADJCALLSTACKUP),
Subtarget(st), TII(tii) {
}
@@ -135,6 +138,3 @@ int SparcRegisterInfo::getDwarfRegNum(unsigned RegNum, bool isEH) const {
int SparcRegisterInfo::getLLVMRegNum(unsigned DwarfRegNo, bool isEH) const {
return SparcGenRegisterInfo::getLLVMRegNumFull(DwarfRegNo,0);
}
-
-#include "SparcGenRegisterInfo.inc"
-
OpenPOWER on IntegriCloud