Skip to content

Commit 0007657

Browse files
committed
Add comment to test and adjust spacing
1 parent 78b358e commit 0007657

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

llvm/test/Transforms/LoopVectorize/reduction-inloop-uf4.ll

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,9 @@ entry:
6666
ret i32 %sum.0.lcssa
6767
}
6868

69-
define i64 @reduction_sum_double(ptr noalias %p, ptr noalias %q) {
70-
; CHECK-LABEL: @reduction_sum_double(
69+
; Check that we correctly unroll two reductions chained together.
70+
define i64 @reduction_sum_chain(ptr noalias %p, ptr noalias %q) {
71+
; CHECK-LABEL: @reduction_sum_chain(
7172
; CHECK-NEXT: entry:
7273
; CHECK-NEXT: br i1 false, label [[SCALAR_PH:%.*]], label [[VECTOR_PH:%.*]]
7374
; CHECK: vector.ph:
@@ -128,6 +129,7 @@ define i64 @reduction_sum_double(ptr noalias %p, ptr noalias %q) {
128129
;
129130
entry:
130131
br label %loop
132+
131133
loop:
132134
%iv = phi i64 [0, %entry], [%iv.next, %loop]
133135
%rdx = phi i64 [0, %entry], [%add2, %loop]
@@ -144,6 +146,7 @@ loop:
144146
%iv.next = add i64 %iv, 1
145147
%done = icmp eq i64 %iv.next, 256
146148
br i1 %done, label %exit, label %loop
149+
147150
exit:
148151
ret i64 %add2
149152
}

0 commit comments

Comments
 (0)