1 ; RUN: not llvm-as < %s 2>&1 | FileCheck %s
3 ; CHECK: Calling convention requires void return type
4 ; CHECK-NEXT: i32 ()* @nonvoid_cc_amdgpu_kernel
5 define amdgpu_kernel i32 @nonvoid_cc_amdgpu_kernel() {
9 ; CHECK: Calling convention does not support varargs or perfect forwarding!
10 ; CHECK-NEXT: void (...)* @varargs_amdgpu_kernel
11 define amdgpu_kernel void @varargs_amdgpu_kernel(...) {
15 ; CHECK: Calling convention does not allow sret
16 ; CHECK-NEXT: void (i32*)* @sret_cc_amdgpu_kernel
17 define amdgpu_kernel void @sret_cc_amdgpu_kernel(i32* sret %ptr) {
21 ; CHECK: Calling convention does not support varargs or perfect forwarding!
22 ; CHECK-NEXT: void (...)* @varargs_amdgpu_vs
23 define amdgpu_vs void @varargs_amdgpu_vs(...) {
27 ; CHECK: Calling convention does not support varargs or perfect forwarding!
28 ; CHECK-NEXT: void (...)* @varargs_amdgpu_gs
29 define amdgpu_gs void @varargs_amdgpu_gs(...) {
33 ; CHECK: Calling convention does not support varargs or perfect forwarding!
34 ; CHECK-NEXT: void (...)* @varargs_amdgpu_ps
35 define amdgpu_ps void @varargs_amdgpu_ps(...) {
39 ; CHECK: Calling convention does not support varargs or perfect forwarding!
40 ; CHECK-NEXT: void (...)* @varargs_amdgpu_cs
41 define amdgpu_cs void @varargs_amdgpu_cs(...) {
45 ; CHECK: Calling convention requires void return type
46 ; CHECK-NEXT: i32 ()* @nonvoid_cc_spir_kernel
47 define spir_kernel i32 @nonvoid_cc_spir_kernel() {
51 ; CHECK: Calling convention does not support varargs or perfect forwarding!
52 ; CHECK-NEXT: void (...)* @varargs_spir_kernel
53 define spir_kernel void @varargs_spir_kernel(...) {