summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaOpenCL/extensions.cl
diff options
context:
space:
mode:
authorNeil Hickey <neil.hickey@arm.com>2016-09-19 11:42:14 +0000
committerNeil Hickey <neil.hickey@arm.com>2016-09-19 11:42:14 +0000
commiteb62b17d8f6cd0eebef9563453c61826567d9708 (patch)
tree3173db46d0679f7673774696ae716822128c9b00 /clang/test/SemaOpenCL/extensions.cl
parenta53660e4a3d10aaba01d714a589e8f9b2f20c355 (diff)
downloadbcm5719-llvm-eb62b17d8f6cd0eebef9563453c61826567d9708.tar.gz
bcm5719-llvm-eb62b17d8f6cd0eebef9563453c61826567d9708.zip
Reverting r281714 due to causing an assert when calling builtins that expect a double, from CL
llvm-svn: 281899
Diffstat (limited to 'clang/test/SemaOpenCL/extensions.cl')
-rw-r--r--clang/test/SemaOpenCL/extensions.cl11
1 files changed, 1 insertions, 10 deletions
diff --git a/clang/test/SemaOpenCL/extensions.cl b/clang/test/SemaOpenCL/extensions.cl
index 33ed2ce2e72..31224e0df77 100644
--- a/clang/test/SemaOpenCL/extensions.cl
+++ b/clang/test/SemaOpenCL/extensions.cl
@@ -1,16 +1,13 @@
// RUN: %clang_cc1 %s -triple spir-unknown-unknown -verify -pedantic -fsyntax-only
// RUN: %clang_cc1 %s -triple spir-unknown-unknown -verify -pedantic -fsyntax-only -cl-std=CL1.1
-// RUN: %clang_cc1 %s -triple spir-unknown-unknown -verify -pedantic -fsyntax-only -cl-std=CL1.2 -DFP64
// Test with a target not supporting fp64.
// RUN: %clang_cc1 %s -triple r600-unknown-unknown -target-cpu r600 -verify -pedantic -fsyntax-only -DNOFP64
-#if __OPENCL_C_VERSION__ < 120
void f1(double da) { // expected-error {{type 'double' requires cl_khr_fp64 extension}}
double d; // expected-error {{type 'double' requires cl_khr_fp64 extension}}
(void) 1.0; // expected-warning {{double precision constant requires cl_khr_fp64}}
}
-#endif
#pragma OPENCL EXTENSION cl_khr_fp64 : enable
#ifdef NOFP64
@@ -24,12 +21,8 @@ void f2(void) {
#endif
(void) 1.0;
-#ifdef FP64
-// expected-no-diagnostics
-#endif
-
#ifdef NOFP64
-// expected-warning@-6{{double precision constant requires cl_khr_fp64, casting to single precision}}
+// expected-warning@-2{{double precision constant requires cl_khr_fp64, casting to single precision}}
#endif
}
@@ -38,8 +31,6 @@ void f2(void) {
// expected-warning@-2{{unsupported OpenCL extension 'cl_khr_fp64' - ignoring}}
#endif
-#if __OPENCL_C_VERSION__ < 120
void f3(void) {
double d; // expected-error {{type 'double' requires cl_khr_fp64 extension}}
}
-#endif
OpenPOWER on IntegriCloud