• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // REQUIRES: aarch64-registered-target
2 // RUN: %clang_cc1 -triple aarch64-linux-gnu -target-feature +neon -fopenmp -x c -std=c11 -emit-llvm %s -o - -femit-all-decls | FileCheck %s
3 
4 // RUN: %clang_cc1 -triple aarch64-linux-gnu -target-feature +sve -fopenmp -x c -std=c11 -emit-llvm %s -o - -femit-all-decls | FileCheck %s --check-prefix=SVE
5 
6 #pragma omp declare simd
7 #pragma omp declare simd simdlen(4) notinbranch
8 double _Complex double_complex(double _Complex);
9 // CHECK:  "_ZGVnM2v_double_complex" "_ZGVnN2v_double_complex" "_ZGVnN4v_double_complex"
10 // CHECK-NOT: double_complex
11 // SVE:   "_ZGVsM4v_double_complex" "_ZGVsMxv_double_complex"
12 // SVE-NOT: double_complex
13 
14 #pragma omp declare simd
15 #pragma omp declare simd simdlen(8) notinbranch
16 float _Complex float_complex(float _Complex);
17 // CHECK:  "_ZGVnM2v_float_complex" "_ZGVnN2v_float_complex" "_ZGVnN8v_float_complex"
18 // CHECK-NOT: float_complex
19 // SVE: "_ZGVsM8v_float_complex" "_ZGVsMxv_float_complex"
20 // SVE-NOT: float_complex
21 
22 static double _Complex *DC;
23 static float _Complex *DF;
call_the_complex_functions()24 void call_the_complex_functions() {
25   double_complex(*DC);
26   float_complex(*DF);
27 }
28