Skip to content

Commit cf5c435

Browse files
bokrzesiigcbot
authored andcommitted
[LLVM16] [LITS] Fixing LIT tests of ConstantCoalescing
Porting IGC code to LLVM16 * Fixing LIT test ConstantCoalescing\ldraws-typed-pointers.ll
1 parent e426eb8 commit cf5c435

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

IGC/Compiler/tests/ConstantCoalescing/ldraws-typed-pointers.ll

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
;
77
;============================ end_copyright_notice =============================
88

9-
; RUN: igc_opt %s -S -o - -igc-constant-coalescing -instcombine -dce | FileCheck %s
9+
; RUN: igc_opt %s -S -o - -igc-constant-coalescing -instcombine -dce | FileCheck %s --check-prefixes=CHECK,%LLVM_DEPENDENT_CHECK_PREFIX%
1010

1111
target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f16:16:16-f32:32:32-f64:64:64-f80:128:128-v16:16:16-v24:32:32-v32:32:32-v48:64:64-v64:64:64-v96:128:128-v128:128:128-v192:256:256-v256:256:256-v512:512:512-v1024:1024:1024-a:64:64-f80:128:128-n8:16:32:64"
1212

@@ -91,12 +91,14 @@ exitBB:
9191

9292
; CHECK-LABEL: define <4 x float> @f2
9393
; CHECK: %1 = call <1 x float> @llvm.genx.GenISA.ldrawvector.indexed.v1f32.p2490373i8(i8 addrspace(2490373)* %0, i32 %src, i32 4, i1 false)
94-
; CHECK: %2 = extractelement <1 x float> %1, {{i[0-9]+}} 0
94+
; CHECK-LLVM-14-PLUS: %2 = extractelement <1 x float> %1, {{i[0-9]+}} 0
95+
; CHECK-LLVM-15-PLUS: %2 = extractelement <1 x float> %1, {{i[0-9]+}} 0
9596
; CHECK: br label %storeBB
9697
; CHECK-LABEL: storeBB:
9798
; CHECK: call void @llvm.genx.GenISA.storeraw.indexed.p2490368i8.f32(i8 addrspace(2490373)* %0, i32 %src, float 0.000000e+00, i32 4, i1 false)
9899
; CHECK: br label %exitBB
99100
; CHECK-LABEL: exitBB:
101+
; CHECK-LLVM-16-PLUS: %2 = extractelement <1 x float> %1, {{i[0-9]+}} 0
100102
; CHECK: %3 = add i32 %src, 4
101103
; CHECK: %4 = call <16 x float> @llvm.genx.GenISA.ldrawvector.indexed.v16f32.p2490373i8(i8 addrspace(2490373)* %0, i32 %3, i32 4, i1 false)
102104
; CHECK: %5 = extractelement <16 x float> %4, {{i[0-9]+}} 11
@@ -109,8 +111,8 @@ exitBB:
109111
; CHECK: ret <4 x float> %11
110112

111113

112-
; Function Attrs: argmemonly nounwind readonly
113-
declare float @llvm.genx.GenISA.ldraw.indexed.f32.p2490373i8(i8 addrspace(2490373)*, i32, i32, i1) argmemonly nounwind readonly
114+
; Function Attrs: argmemonly nounwind readonly willreturn
115+
declare float @llvm.genx.GenISA.ldraw.indexed.f32.p2490373i8(i8 addrspace(2490373)*, i32, i32, i1) argmemonly nounwind readonly willreturn
114116

115117
; Function Attrs: argmemonly nounwind writeonly
116118
declare void @llvm.genx.GenISA.storeraw.indexed.p2490368i8.f32(i8 addrspace(2490373)*, i32, float, i32, i1) argmemonly nounwind writeonly

IGC/GenISAIntrinsics/generator/input/Intrinsic_definitions.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6480,6 +6480,7 @@ intrinsics:
64806480
comment: "volatile, must be an immediate"
64816481
attributes:
64826482
- !AttributeID "NoUnwind"
6483+
- !AttributeID "WillReturn"
64836484
memory_effects:
64846485
- !<MemoryRestriction>
64856486
memory_location: !MemoryLocation ArgMem

0 commit comments

Comments
 (0)