summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/R600/AMDGPUTargetMachine.h
diff options
context:
space:
mode:
authorTom Stellard <thomas.stellard@amd.com>2015-01-28 16:04:26 +0000
committerTom Stellard <thomas.stellard@amd.com>2015-01-28 16:04:26 +0000
commit40ce8af4a5750cb7b35c3bf588b87820a6bb8ce7 (patch)
treeb9119f4ebe3ad7e2774ea3deee6db79bfa87ee8c /llvm/lib/Target/R600/AMDGPUTargetMachine.h
parentd99fb956a3c8554a6701d52e1e78f60c21155011 (diff)
downloadbcm5719-llvm-40ce8af4a5750cb7b35c3bf588b87820a6bb8ce7.tar.gz
bcm5719-llvm-40ce8af4a5750cb7b35c3bf588b87820a6bb8ce7.zip
R600: Move DataLayout to AMDGPUTargetMachine
This is a follow up to r227113. It is now required to use the amdgcn target for SI and newer GPUs. llvm-svn: 227316
Diffstat (limited to 'llvm/lib/Target/R600/AMDGPUTargetMachine.h')
-rw-r--r--llvm/lib/Target/R600/AMDGPUTargetMachine.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/llvm/lib/Target/R600/AMDGPUTargetMachine.h b/llvm/lib/Target/R600/AMDGPUTargetMachine.h
index c3c67f0aee4..8aa97cfd987 100644
--- a/llvm/lib/Target/R600/AMDGPUTargetMachine.h
+++ b/llvm/lib/Target/R600/AMDGPUTargetMachine.h
@@ -29,6 +29,9 @@ namespace llvm {
//===----------------------------------------------------------------------===//
class AMDGPUTargetMachine : public LLVMTargetMachine {
+private:
+ const DataLayout DL;
+
protected:
TargetLoweringObjectFile *TLOF;
AMDGPUSubtarget Subtarget;
@@ -42,7 +45,7 @@ public:
// FIXME: This is currently broken, the DataLayout needs to move to
// the target machine.
const DataLayout *getDataLayout() const override {
- return getSubtargetImpl()->getDataLayout();
+ return &DL;
}
const AMDGPUSubtarget *getSubtargetImpl() const override {
return &Subtarget;
OpenPOWER on IntegriCloud