One ppc32-darwin, a i64 inside a structure can have 32 bit alignment.
[oota-llvm.git] / lib / Target / PowerPC / PPCTargetMachine.cpp
index 3d8fa1c195dc7628681b5829f9246bcbd7f0a0de..9e3f14ccaf01313bc7f87c79bd4be23e0ceddc7c 100644 (file)
@@ -47,7 +47,8 @@ static std::string getDataLayoutString(const PPCSubtarget &ST) {
 
   // Note, the alignment values for f64 and i64 on ppc64 in Darwin
   // documentation are wrong; these are correct (i.e. "what gcc does").
-  Ret += "-i64:64";
+  if (ST.isPPC64() || ST.isSVR4ABI())
+    Ret += "-i64:64";
 
   // Set support for 128 floats depending on the ABI.
   if (!ST.isPPC64() || !ST.isSVR4ABI())