Debian Codegraph @

test/extensions/INTEL/SPV_INTEL_fpga_cluster_attributes/function_attributes.ll

raw
1 ; RUN: llvm-as %s -o %t.bc
2 ; RUN: llvm-spirv --spirv-ext=+SPV_INTEL_fpga_cluster_attributes -spirv-text -o - %t.bc | FileCheck --check-prefix CHECK-SPIRV %s
3 ; RUN: llvm-spirv --spirv-ext=+SPV_INTEL_fpga_cluster_attributes %t.bc -o %t.spv
4 ; spirv-val %t.spv
5 ; RUN: llvm-spirv -r --spirv-ext=+SPV_INTEL_fpga_cluster_attributes %t.spv -o %t.rev.bc
6 ; RUN: llvm-dis %t.rev.bc -o - | FileCheck --check-prefix CHECK-LLVM %s
7
8 target triple = "spir64-unknown-unknown"
9
10 ; CHECK-SPIRV-DAG: Capability FPGAClusterAttributesINTEL
11 ; CHECK-SPIRV-DAG: Capability FPGAClusterAttributesV2INTEL
12 ; CHECK-SPIRV-DAG: Extension "SPV_INTEL_fpga_cluster_attributes"
13 ; CHECK-SPIRV-DAG: Decorate [[#STALLENABLE_DEC:]] StallEnableINTEL
14 ; CHECK-SPIRV-DAG: Decorate [[#STALLFREE_DEC:]] StallFreeINTEL
15 ; CHECK-SPIRV: Function {{[0-9]+}} [[#STALLENABLE_DEC]] {{[0-9]+}} {{[0-9]+}}
16 ; CHECK-SPIRV: Function {{[0-9]+}} [[#STALLFREE_DEC]] {{[0-9]+}} {{[0-9]+}}
17 ; CHECK-LLVM: define spir_func void @test_fpga_stallenable_attr() {{.*}} !stall_enable [[STALL_MD:![0-9]+]]
18 ; CHECK-LLVM: define spir_func void @test_fpga_stallfree_attr() {{.*}} !stall_free [[STALL_MD]]
19 ; CHECK-LLVM: [[STALL_MD]] = !{i32 1}
20
21
22 define spir_func void @test_fpga_stallenable_attr() !stall_enable !0 {
23 entry:
24 ret void
25 }
26
27 define spir_func void @test_fpga_stallfree_attr() !stall_free !1 {
28 entry:
29 ret void
30 }
31
32 !0 = !{ i32 1 }
33 !1 = !{ i32 1 }