Debian Codegraph @

IGC/ocloc_tests/SPIRV-extenstions/SPV_INTEL_cache_controls/kernel_arg.ll

raw
1 ; UNSUPPORTED: system-windows
2 ; REQUIRES: llvm-spirv, regkeys, dg2-supported
3
4 ; RUN: llvm-as %s -o %t.bc
5 ; RUN: llvm-spirv %t.bc --spirv-ext=+SPV_INTEL_cache_controls -o %t.spv
6 ; RUN: ocloc compile -spirv_input -file %t.spv -device dg2 -options " -igc_opts 'ShaderDumpTranslationOnly=1'" 2>&1 | FileCheck %s --check-prefixes=CHECK-LLVM
7
8 target triple = "spir64-unknown-unknown"
9
10 ; CHECK-LLVM: spir_kernel {{.*}} !spirv.ParameterDecorations [[ParamDecID:![0-9]+]]
11 define spir_kernel void @test(i32 addrspace(1)* %dummy, i32 addrspace(1)* %buffer) !spirv.ParameterDecorations !3 {
12 entry:
13 %0 = load i32, i32 addrspace(1)* %buffer, align 4
14 store i32 %0, i32 addrspace(1)* %buffer, align 4
15 ret void
16 }
17
18 !spirv.MemoryModel = !{!0}
19 !spirv.Source = !{!1}
20 !opencl.spir.version = !{!2}
21 !opencl.ocl.version = !{!2}
22
23 !0 = !{i32 2, i32 2}
24 !1 = !{i32 3, i32 102000}
25 !2 = !{i32 1, i32 2}
26 !3 = !{!4, !5}
27 !4 = !{}
28 !5 = !{!6, !7}
29 ; CHECK-LLVM: [[ParamDecID]] = !{!{{[0-9]+}}, [[BufferDecID:![0-9]+]]}
30 ; CHECK-LLVM: [[BufferDecID]] = !{[[StoreDecID:![0-9]+]], [[LoadDecID:![0-9]+]]}
31 ; CHECK-LLVM: [[StoreDecID]] = !{i32 6442, i32 0, i32 0}
32 ; CHECK-LLVM: [[LoadDecID]] = !{i32 6443, i32 0, i32 1}
33 !6 = !{i32 6442, i32 0, i32 0} ; {CacheControlLoadINTEL, CacheLevel=0, Uncached}
34 !7 = !{i32 6443, i32 0, i32 1} ; {CacheControlStoreINTEL, CacheLevel=0, WriteThrough}