aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target/CellSPU
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Target/CellSPU')
-rw-r--r--lib/Target/CellSPU/SPUSubtarget.cpp6
-rw-r--r--lib/Target/CellSPU/SPUSubtarget.h9
-rw-r--r--lib/Target/CellSPU/SPUTargetMachine.cpp2
3 files changed, 4 insertions, 13 deletions
diff --git a/lib/Target/CellSPU/SPUSubtarget.cpp b/lib/Target/CellSPU/SPUSubtarget.cpp
index 0a1c2f7..0f18b7f 100644
--- a/lib/Target/CellSPU/SPUSubtarget.cpp
+++ b/lib/Target/CellSPU/SPUSubtarget.cpp
@@ -13,15 +13,11 @@
#include "SPUSubtarget.h"
#include "SPU.h"
-#include "llvm/Module.h"
-#include "llvm/Target/TargetMachine.h"
#include "SPUGenSubtarget.inc"
using namespace llvm;
-SPUSubtarget::SPUSubtarget(const TargetMachine &tm, const Module &M,
- const std::string &FS) :
- TM(tm),
+SPUSubtarget::SPUSubtarget(const std::string &TT, const std::string &FS) :
StackAlignment(16),
ProcDirective(SPU::DEFAULT_PROC),
UseLargeMem(false)
diff --git a/lib/Target/CellSPU/SPUSubtarget.h b/lib/Target/CellSPU/SPUSubtarget.h
index b6a3409..94ac73c 100644
--- a/lib/Target/CellSPU/SPUSubtarget.h
+++ b/lib/Target/CellSPU/SPUSubtarget.h
@@ -20,9 +20,7 @@
#include <string>
namespace llvm {
- class Module;
class GlobalValue;
- class TargetMachine;
namespace SPU {
enum {
@@ -33,8 +31,6 @@ namespace llvm {
class SPUSubtarget : public TargetSubtarget {
protected:
- const TargetMachine &TM;
-
/// stackAlignment - The minimum alignment known to hold of the stack frame
/// on entry to the function and which must be maintained by every function.
unsigned StackAlignment;
@@ -52,10 +48,9 @@ namespace llvm {
public:
/// This constructor initializes the data members to match that
- /// of the specified module.
+ /// of the specified triple.
///
- SPUSubtarget(const TargetMachine &TM, const Module &M,
- const std::string &FS);
+ SPUSubtarget(const std::string &TT, const std::string &FS);
/// ParseSubtargetFeatures - Parses features string setting specified
/// subtarget options. Definition of function is auto generated by tblgen.
diff --git a/lib/Target/CellSPU/SPUTargetMachine.cpp b/lib/Target/CellSPU/SPUTargetMachine.cpp
index 340eb56..16b923b 100644
--- a/lib/Target/CellSPU/SPUTargetMachine.cpp
+++ b/lib/Target/CellSPU/SPUTargetMachine.cpp
@@ -41,7 +41,7 @@ const TargetAsmInfo *SPUTargetMachine::createTargetAsmInfo() const {
SPUTargetMachine::SPUTargetMachine(const Target &T, const Module &M,
const std::string &FS)
: LLVMTargetMachine(T),
- Subtarget(*this, M, FS),
+ Subtarget(M.getTargetTriple(), FS),
DataLayout(Subtarget.getTargetDataString()),
InstrInfo(*this),
FrameInfo(*this),