1// RUN: %clang_cc1 %s -triple spir-unknown-unknown -finclude-default-header -verify -cl-std=CL1.2 -emit-llvm -o - -O0
2
3void test_negative() {
4    uchar4 ua8, ub8;
5    char4 sa8, sb8;
6    ushort2 ua16, ub16;
7    short2 sa16, sb16;
8    uint ur;
9    int sr;
10    ur = arm_dot(ua8, ub8); // expected-error{{no matching function for call to 'arm_dot'}}
11    // expected-note@opencl-c.h:* {{candidate function not viable}}
12    // expected-note@opencl-c.h:* {{candidate unavailable as it requires OpenCL extension 'cl_arm_integer_dot_product_int8' to be enabled}}
13    sr = arm_dot(sa8, sb8); // expected-error{{no matching function for call to 'arm_dot'}}
14    // expected-note@opencl-c.h:* {{candidate function not viable}}
15    // expected-note@opencl-c.h:* {{candidate unavailable as it requires OpenCL extension 'cl_arm_integer_dot_product_int8' to be enabled}}
16    ur = arm_dot_acc(ua8, ub8, ur); // expected-error{{no matching function for call to 'arm_dot_acc'}}
17    // expected-note@opencl-c.h:* {{candidate function not viable}}
18    // expected-note@opencl-c.h:* {{candidate function not viable}}
19    // expected-note@opencl-c.h:* {{candidate function not viable}}
20    // expected-note@opencl-c.h:* {{candidate unavailable as it requires OpenCL extension 'cl_arm_integer_dot_product_accumulate_int8' to be enabled}}
21    sr = arm_dot_acc(sa8, sb8, sr); // expected-error{{no matching function for call to 'arm_dot_acc'}}
22    // expected-note@opencl-c.h:* {{candidate function not viable}}
23    // expected-note@opencl-c.h:* {{candidate function not viable}}
24    // expected-note@opencl-c.h:* {{candidate function not viable}}
25    // expected-note@opencl-c.h:* {{candidate unavailable as it requires OpenCL extension 'cl_arm_integer_dot_product_accumulate_int8' to be enabled}}
26    ur = arm_dot_acc(ua16, ub16, ur); // expected-error{{no matching function for call to 'arm_dot_acc'}}
27    // expected-note@opencl-c.h:* {{candidate function not viable}}
28    // expected-note@opencl-c.h:* {{candidate function not viable}}
29    // expected-note@opencl-c.h:* {{candidate function not viable}}
30    // expected-note@opencl-c.h:* {{candidate unavailable as it requires OpenCL extension 'cl_arm_integer_dot_product_accumulate_int16' to be enabled}}
31    sr = arm_dot_acc(sa16, sb16, sr); // expected-error{{no matching function for call to 'arm_dot_acc'}}
32    // expected-note@opencl-c.h:* {{candidate function not viable}}
33    // expected-note@opencl-c.h:* {{candidate function not viable}}
34    // expected-note@opencl-c.h:* {{candidate function not viable}}
35    // expected-note@opencl-c.h:* {{candidate unavailable as it requires OpenCL extension 'cl_arm_integer_dot_product_accumulate_int16' to be enabled}}
36    ur = arm_dot_acc_sat(ua8, ub8, ur); // expected-error{{no matching function for call to 'arm_dot_acc_sat'}}
37    // expected-note@opencl-c.h:* {{candidate function not viable}}
38    // expected-note@opencl-c.h:* {{candidate unavailable as it requires OpenCL extension 'cl_arm_integer_dot_product_accumulate_saturate_int8' to be enabled}}
39    sr = arm_dot_acc_sat(sa8, sb8, sr); // expected-error{{no matching function for call to 'arm_dot_acc_sat'}}
40    // expected-note@opencl-c.h:* {{candidate function not viable}}
41    // expected-note@opencl-c.h:* {{candidate unavailable as it requires OpenCL extension 'cl_arm_integer_dot_product_accumulate_saturate_int8' to be enabled}}
42}
43
44