From 4609dbe2228684205d556bf08b7fdfaed201aa7a Mon Sep 17 00:00:00 2001 From: Dale Johannesen Date: Fri, 27 Feb 2009 00:56:35 +0000 Subject: [PATCH] Alignment values for i64 and f64 on ppc64 were wrong, possibly for the reason suggested by the comment. No wonder it didn't work very well. This unblocks bootstrap with assertions on ppc. llvm-svn: 65601 --- llvm/lib/Target/PowerPC/PPCSubtarget.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/llvm/lib/Target/PowerPC/PPCSubtarget.h b/llvm/lib/Target/PowerPC/PPCSubtarget.h index bb29d449507a..d268a7d9b73a 100644 --- a/llvm/lib/Target/PowerPC/PPCSubtarget.h +++ b/llvm/lib/Target/PowerPC/PPCSubtarget.h @@ -108,7 +108,9 @@ public: /// getTargetDataString - Return the pointer size and type alignment /// properties of this subtarget. const char *getTargetDataString() const { - return isPPC64() ? "E-p:64:64-f64:32:64-i64:32:64-f128:64:128" + // Note, the alignment values for f64 and i64 on ppc64 in Darwin + // documentation are wrong; these are correct (i.e. "what gcc does"). + return isPPC64() ? "E-p:64:64-f64:64:64-i64:64:64-f128:64:128" : "E-p:32:32-f64:32:64-i64:32:64-f128:64:128"; }