summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCTargetMachine.cpp')
-rw-r--r--llvm/lib/Target/PowerPC/PPCTargetMachine.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
index 5d68f32ccc5..8df1a89308f 100644
--- a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
+++ b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
@@ -120,6 +120,11 @@ static std::string getDataLayoutString(const Triple &T) {
else
Ret += "-f64:32:64";
+ // 128 bit integers are always aligned to 128 bits, but only 64-bit matters,
+ // because __int128 is only supoprted on 64-bit targets.
+ if (is64Bit && T.isOSLinux())
+ Ret += "-i128:128";
+
// PPC64 has 32 and 64 bit registers, PPC32 has only 32 bit ones.
if (is64Bit)
Ret += "-n32:64";
OpenPOWER on IntegriCloud