|
| 1 | +;=========================== begin_copyright_notice ============================ |
| 2 | +; |
| 3 | +; Copyright (C) 2025 Intel Corporation |
| 4 | +; |
| 5 | +; SPDX-License-Identifier: MIT |
| 6 | +; |
| 7 | +;============================ end_copyright_notice ============================= |
| 8 | + |
| 9 | +; REQUIRES: llvm-14-plus, regkeys |
| 10 | +; RUN: igc_opt --opaque-pointers --igc-pressure-printer -S --disable-output --regkey=RegPressureVerbocity=1 < %s 2>&1 | FileCheck %s |
| 11 | + |
| 12 | +; ------------------------------------------------ |
| 13 | +; WIAnalysis |
| 14 | +; ------------------------------------------------ |
| 15 | + |
| 16 | +; This test checks whether the 'alloca' instruction is correctly identified as non-uniform when non-uniform |
| 17 | +; value stored in it goes through a freeze instruction. |
| 18 | + |
| 19 | +; CHECK: N: {{.*}} %a = alloca i16, align 2 |
| 20 | + |
| 21 | +; Function Attrs: convergent nounwind |
| 22 | +define spir_kernel void @test_uniform(<8 x i32> %r0, <8 x i32> %payloadHeader, i16 %localIdX, i32 %bufferOffset) { |
| 23 | +entry: |
| 24 | + %a = alloca i16 |
| 25 | + %freezed_lid = freeze i16 %localIdX |
| 26 | + store i16 %freezed_lid, i16* %a, align 2 |
| 27 | + ret void |
| 28 | +} |
| 29 | + |
| 30 | +!igc.functions = !{!358} |
| 31 | + |
| 32 | +!358 = !{void (<8 x i32>, <8 x i32>, i32)* @test_uniform, !359} |
| 33 | +!359 = !{!360, !361} |
| 34 | +!360 = !{!"function_type", i32 0} |
| 35 | +!361 = !{!"implicit_arg_desc", !362, !363, !366, !364} |
| 36 | +!362 = !{i32 0} |
| 37 | +!363 = !{i32 1} |
| 38 | +!364 = !{i32 15, !365} |
| 39 | +!365 = !{!"explicit_arg_num", i32 0} |
| 40 | +!366 = !{i32 8} |
0 commit comments