diff options
| author | Rafael Espindola <rafael.espindola@gmail.com> | 2016-06-30 18:25:11 +0000 |
|---|---|---|
| committer | Rafael Espindola <rafael.espindola@gmail.com> | 2016-06-30 18:25:11 +0000 |
| commit | d86e8bb0ed5aefa6b18ffab88b8d542c95f52052 (patch) | |
| tree | 94535e80931212ff5df25ef80ac53b8fb4bd6033 /llvm/lib/Target/SystemZ | |
| parent | 8b08d2c5c87bbb0cca4ee59987499f73e252068b (diff) | |
| download | bcm5719-llvm-d86e8bb0ed5aefa6b18ffab88b8d542c95f52052.tar.gz bcm5719-llvm-d86e8bb0ed5aefa6b18ffab88b8d542c95f52052.zip | |
Delete MCCodeGenInfo.
MC doesn't really care about CodeGen stuff, so this was just
complicating target initialization.
llvm-svn: 274258
Diffstat (limited to 'llvm/lib/Target/SystemZ')
| -rw-r--r-- | llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCTargetDesc.cpp | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCTargetDesc.cpp b/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCTargetDesc.cpp index 4c7cdbc645d..e16ba9e1531 100644 --- a/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCTargetDesc.cpp +++ b/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCTargetDesc.cpp @@ -10,7 +10,6 @@ #include "SystemZMCTargetDesc.h" #include "InstPrinter/SystemZInstPrinter.h" #include "SystemZMCAsmInfo.h" -#include "llvm/MC/MCCodeGenInfo.h" #include "llvm/MC/MCInstrInfo.h" #include "llvm/MC/MCRegisterInfo.h" #include "llvm/MC/MCStreamer.h" @@ -159,11 +158,8 @@ createSystemZMCSubtargetInfo(const Triple &TT, StringRef CPU, StringRef FS) { return createSystemZMCSubtargetInfoImpl(TT, CPU, FS); } -static MCCodeGenInfo *createSystemZMCCodeGenInfo(const Triple &TT, - Reloc::Model RM, - CodeModel::Model CM, - CodeGenOpt::Level OL) { - MCCodeGenInfo *X = new MCCodeGenInfo(); +static void adjustCodeGenOpts(const Triple &TT, Reloc::Model RM, + CodeModel::Model &CM) { // For SystemZ we define the models as follows: // // Small: BRASL can call any function and will use a stub if necessary. @@ -197,8 +193,6 @@ static MCCodeGenInfo *createSystemZMCCodeGenInfo(const Triple &TT, CM = CodeModel::Small; else if (CM == CodeModel::JITDefault) CM = RM == Reloc::PIC_ ? CodeModel::Small : CodeModel::Medium; - X->initMCCodeGenInfo(RM, CM, OL); - return X; } static MCInstPrinter *createSystemZMCInstPrinter(const Triple &T, @@ -214,9 +208,9 @@ extern "C" void LLVMInitializeSystemZTargetMC() { TargetRegistry::RegisterMCAsmInfo(TheSystemZTarget, createSystemZMCAsmInfo); - // Register the MCCodeGenInfo. - TargetRegistry::RegisterMCCodeGenInfo(TheSystemZTarget, - createSystemZMCCodeGenInfo); + // Register the adjustCodeGenOpts. + TargetRegistry::registerMCAdjustCodeGenOpts(TheSystemZTarget, + adjustCodeGenOpts); // Register the MCCodeEmitter. TargetRegistry::RegisterMCCodeEmitter(TheSystemZTarget, |

