summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPavel Chupin <pavel.v.chupin@intel.com>2014-08-04 12:39:43 +0000
committerPavel Chupin <pavel.v.chupin@intel.com>2014-08-04 12:39:43 +0000
commitfd223e168066a5f2fc8cd0a7f246d74cd2eb8bee (patch)
tree64b3c65d33e5749ff078443766351f05807b8326
parentf0df221d761e34e5e8f0067d448c863e71619e08 (diff)
downloadbcm5719-llvm-fd223e168066a5f2fc8cd0a7f246d74cd2eb8bee.tar.gz
bcm5719-llvm-fd223e168066a5f2fc8cd0a7f246d74cd2eb8bee.zip
[x32] Add __int128 support
Summary: Adding __int128 support explicitly for x86_64 because currently it's on only when pointer size >= 64 which is not the case for x32. Test Plan: One of the tests using __int128 is updated Reviewers: atanasyan, chandlerc Subscribers: cfe-commits, rob.khasanov, zinovy.nis, dschuff Differential Revision: http://reviews.llvm.org/D4755 llvm-svn: 214710
-rw-r--r--clang/lib/Basic/Targets.cpp2
-rw-r--r--clang/test/Sema/types.c2
2 files changed, 4 insertions, 0 deletions
diff --git a/clang/lib/Basic/Targets.cpp b/clang/lib/Basic/Targets.cpp
index e8d23a8b78d..034bb07b05b 100644
--- a/clang/lib/Basic/Targets.cpp
+++ b/clang/lib/Basic/Targets.cpp
@@ -3401,6 +3401,8 @@ public:
return CC_C;
}
+ // for x32 we need it here explicitly
+ bool hasInt128Type() const override { return true; }
};
} // end anonymous namespace
diff --git a/clang/test/Sema/types.c b/clang/test/Sema/types.c
index 0450de1c8e9..6a22b20b0ea 100644
--- a/clang/test/Sema/types.c
+++ b/clang/test/Sema/types.c
@@ -1,5 +1,7 @@
// RUN: %clang_cc1 %s -pedantic -verify -triple=x86_64-apple-darwin9
// RUN: %clang_cc1 %s -pedantic -verify -triple=mips64-linux-gnu
+// RUN: %clang_cc1 %s -pedantic -verify -triple=x86_64-unknown-linux
+// RUN: %clang_cc1 %s -pedantic -verify -triple=x86_64-unknown-linux-gnux32
// rdar://6097662
typedef int (*T)[2];
OpenPOWER on IntegriCloud