1 // RUN: %clang_cc1 -triple s390x-ibm-linux -emit-llvm -fzvector -o - %s 2>&1 \
4 // Test that the "s390x-visible-vector-ABI" module flag is not emitted.
6 // Use of va_arg with a scalar type.
9 return va_arg(vl
, int);
12 typedef __attribute__((vector_size(16))) int v4i32
;
14 // Declaring unused global function with vector argument and return values;
15 v4i32
globfun(v4i32 Arg
);
17 // Declaring global scalar variable used below.
20 // Declaring extern global scalar variable used below.
21 extern int GlobExtVar
;
23 // Local vector variable used below.
26 // Local function with vector argument and return values;
27 static v4i32
foo(v4i32 Arg
) {
33 v4i32 V
= {1, 2, 3, 4};
34 return foo(V
)[0] + GlobVal
+ GlobExtVar
;
37 // Globally visible vector variable less than 16 bytes in size.
38 typedef __attribute__((vector_size(8))) int v2i32
;
41 // Global function taking narrow vector array and pointer.
42 void bar(v2i32 VArr
[4], v2i32
*Dst
) { *Dst
= VArr
[3]; }
44 // Wide vector parameters via "hidden" pointers.
45 typedef __attribute__((vector_size(32))) int v8i32
;
46 v8i32
bar2(v8i32 Arg
) { return Arg
; }
48 // Same but with a single element struct.
49 struct SingleElStruct
{ v8i32 B
; };
50 struct SingleElStruct
bar3(struct SingleElStruct Arg
) { return Arg
; }
53 //CHECK-NOT: !{i32 2, !"s390x-visible-vector-ABI", i32 1}