[llvm] LAA: fix logic for MaxTargetVectorWidth (PR #125487)
Ramkumar Ramachandra via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 12 02:52:57 PST 2025
================
@@ -10,38 +10,104 @@ target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128"
; If the dependence distance is not a constant, whether it gets identified as backwards or unknown depends on the minimum distance and the target's vector length.
define void @backward_min_distance_8(ptr %A, i64 %N) {
-; COMMON-LABEL: 'backward_min_distance_8'
-; COMMON-NEXT: loop:
-; COMMON-NEXT: Memory dependences are safe with run-time checks
-; COMMON-NEXT: Dependences:
-; COMMON-NEXT: Run-time memory checks:
-; COMMON-NEXT: Check 0:
-; COMMON-NEXT: Comparing group ([[GRP1:0x[0-9a-f]+]]):
-; COMMON-NEXT: %gep.off.iv = getelementptr inbounds i8, ptr %gep.off, i64 %iv
-; COMMON-NEXT: Against group ([[GRP2:0x[0-9a-f]+]]):
-; COMMON-NEXT: %gep = getelementptr inbounds i8, ptr %A, i64 %iv
-; COMMON-NEXT: Grouped accesses:
-; COMMON-NEXT: Group [[GRP1]]:
-; COMMON-NEXT: (Low: {(1 + %A)<nuw>,+,1}<nuw><%outer.header> High: {(257 + %A),+,1}<nw><%outer.header>)
-; COMMON-NEXT: Member: {{\{\{}}(1 + %A)<nuw>,+,1}<nuw><%outer.header>,+,1}<nuw><%loop>
-; COMMON-NEXT: Group [[GRP2]]:
-; COMMON-NEXT: (Low: %A High: (256 + %A))
-; COMMON-NEXT: Member: {%A,+,1}<nuw><%loop>
-; COMMON-EMPTY:
-; COMMON-NEXT: Non vectorizable stores to invariant address were not found in loop.
-; COMMON-NEXT: SCEV assumptions:
-; COMMON-EMPTY:
-; COMMON-NEXT: Expressions re-written:
-; COMMON-NEXT: outer.header:
-; COMMON-NEXT: Report: loop is not the innermost loop
-; COMMON-NEXT: Dependences:
-; COMMON-NEXT: Run-time memory checks:
-; COMMON-NEXT: Grouped accesses:
-; COMMON-EMPTY:
-; COMMON-NEXT: Non vectorizable stores to invariant address were not found in loop.
-; COMMON-NEXT: SCEV assumptions:
-; COMMON-EMPTY:
-; COMMON-NEXT: Expressions re-written:
+; CHECK-LABEL: 'backward_min_distance_8'
+; CHECK-NEXT: loop:
+; CHECK-NEXT: Memory dependences are safe with run-time checks
+; CHECK-NEXT: Dependences:
+; CHECK-NEXT: Run-time memory checks:
+; CHECK-NEXT: Check 0:
+; CHECK-NEXT: Comparing group ([[GRP1:0x[0-9a-f]+]]):
+; CHECK-NEXT: %gep.off.iv = getelementptr inbounds i8, ptr %gep.off, i64 %iv
+; CHECK-NEXT: Against group ([[GRP2:0x[0-9a-f]+]]):
+; CHECK-NEXT: %gep = getelementptr inbounds i8, ptr %A, i64 %iv
+; CHECK-NEXT: Grouped accesses:
+; CHECK-NEXT: Group [[GRP1]]:
+; CHECK-NEXT: (Low: {(1 + %A)<nuw>,+,1}<nuw><%outer.header> High: {(257 + %A),+,1}<nw><%outer.header>)
+; CHECK-NEXT: Member: {{\{\{}}(1 + %A)<nuw>,+,1}<nuw><%outer.header>,+,1}<nuw><%loop>
+; CHECK-NEXT: Group [[GRP2]]:
+; CHECK-NEXT: (Low: %A High: (256 + %A))
+; CHECK-NEXT: Member: {%A,+,1}<nuw><%loop>
+; CHECK-EMPTY:
+; CHECK-NEXT: Non vectorizable stores to invariant address were not found in loop.
+; CHECK-NEXT: SCEV assumptions:
+; CHECK-EMPTY:
+; CHECK-NEXT: Expressions re-written:
+; CHECK-NEXT: outer.header:
+; CHECK-NEXT: Report: loop is not the innermost loop
+; CHECK-NEXT: Dependences:
+; CHECK-NEXT: Run-time memory checks:
+; CHECK-NEXT: Grouped accesses:
+; CHECK-EMPTY:
+; CHECK-NEXT: Non vectorizable stores to invariant address were not found in loop.
+; CHECK-NEXT: SCEV assumptions:
+; CHECK-EMPTY:
+; CHECK-NEXT: Expressions re-written:
+;
+; VW128-LABEL: 'backward_min_distance_8'
----------------
artagnon wrote:
There seems to be a UTC bug, due to which COMMON lines seem to be conflicting. I've manually put back the COMMON lines in for this test for now.
https://github.com/llvm/llvm-project/pull/125487
More information about the llvm-commits
mailing list