From 73b8843fa2827a9b3c0dd1995272e72b3b97a146 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Thu, 19 Dec 2013 03:03:04 +0000 Subject: [PATCH] On spacv8 f128 is only aligned to 64 bits. LLVM already got this right. Found on "Figure 3-1: Scalar Types" on http://sparc.com/standards/psABI3rd.pdf. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@197651 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Basic/Targets.cpp | 4 +--- test/CodeGen/target-data.c | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/Basic/Targets.cpp b/lib/Basic/Targets.cpp index 0de37da809..16f536066d 100644 --- a/lib/Basic/Targets.cpp +++ b/lib/Basic/Targets.cpp @@ -4506,9 +4506,7 @@ void SparcTargetInfo::getGCCRegAliases(const GCCRegAlias *&Aliases, class SparcV8TargetInfo : public SparcTargetInfo { public: SparcV8TargetInfo(const llvm::Triple &Triple) : SparcTargetInfo(Triple) { - // FIXME: Support Sparc quad-precision long double? - DescriptionString = "E-p:32:32-" - "i64:64-n32-S64"; + DescriptionString = "E-p:32:32-i64:64-f128:64-n32-S64"; } virtual void getTargetDefines(const LangOptions &Opts, diff --git a/test/CodeGen/target-data.c b/test/CodeGen/target-data.c index 5e05338208..0af4b24278 100644 --- a/test/CodeGen/target-data.c +++ b/test/CodeGen/target-data.c @@ -24,7 +24,7 @@ // RUN: %clang_cc1 -triple sparc-sun-solaris -emit-llvm -o - %s | \ // RUN: FileCheck %s --check-prefix=SPARC-V8 -// SPARC-V8: target datalayout = "E-p:32:32-i64:64-n32-S64" +// SPARC-V8: target datalayout = "E-p:32:32-i64:64-f128:64-n32-S64" // RUN: %clang_cc1 -triple sparcv9-sun-solaris -emit-llvm -o - %s | \ // RUN: FileCheck %s --check-prefix=SPARC-V9 -- 2.40.0