mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-11-30 04:18:16 +00:00
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. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133782 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -35,12 +35,15 @@
|
||||
#include "llvm/Support/raw_ostream.h"
|
||||
#include "llvm/ADT/BitVector.h"
|
||||
#include "llvm/ADT/STLExtras.h"
|
||||
#include "MipsGenRegisterDesc.inc"
|
||||
#include "MipsGenRegisterInfo.inc"
|
||||
|
||||
using namespace llvm;
|
||||
|
||||
MipsRegisterInfo::MipsRegisterInfo(const MipsSubtarget &ST,
|
||||
const TargetInstrInfo &tii)
|
||||
: MipsGenRegisterInfo(Mips::ADJCALLSTACKDOWN, Mips::ADJCALLSTACKUP),
|
||||
: MipsGenRegisterInfo(MipsRegDesc, MipsRegInfoDesc,
|
||||
Mips::ADJCALLSTACKDOWN, Mips::ADJCALLSTACKUP),
|
||||
Subtarget(ST), TII(tii) {}
|
||||
|
||||
/// getRegisterNumbering - Given the enum value for some register, e.g.
|
||||
@@ -285,5 +288,3 @@ getDwarfRegNum(unsigned RegNum, bool isEH) const {
|
||||
int MipsRegisterInfo::getLLVMRegNum(unsigned DwarfRegNo, bool isEH) const {
|
||||
return MipsGenRegisterInfo::getLLVMRegNumFull(DwarfRegNo,0);
|
||||
}
|
||||
|
||||
#include "MipsGenRegisterInfo.inc"
|
||||
|
||||
Reference in New Issue
Block a user