[PATCH] D105438: [NFC] Update some fragile tests
Mindong Chen via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 5 19:35:31 PDT 2021
mdchen added inline comments.
================
Comment at: llvm/test/Transforms/LoopVectorize/pr47343-expander-lcssa-after-cfg-update.ll:75
;
+
+
----------------
fhahn wrote:
> remove whitespace?
Thanks, will remove them.
================
Comment at: llvm/test/Transforms/LoopVersioningLICM/loopversioningLICM1.ll:11
;
-; CHECK: for.body3:
-; CHECK-NEXT: %[[induction:.*]] = phi i32 [ %arrayidx7.promoted, %for.body3.ph ], [ %add8, %for.body3 ]
-; CHECK-NEXT: %j.113 = phi i32 [ %j.016, %for.body3.ph ], [ %inc, %for.body3 ]
-; CHECK-NEXT: %idxprom = zext i32 %j.113 to i64
-; CHECK-NEXT: %arrayidx = getelementptr inbounds i32, i32* %var1, i64 %idxprom
-; CHECK-NEXT: store i32 %add, i32* %arrayidx, align 4, !alias.scope !2, !noalias !2
-; CHECK-NEXT: %add8 = add nsw i32 %[[induction]], %add
-; CHECK-NEXT: %inc = add nuw i32 %j.113, 1
-; CHECK-NEXT: %cmp2 = icmp ult i32 %inc, %itr
-; CHECK-NEXT: br i1 %cmp2, label %for.body3, label %for.inc11.loopexit.loopexit7, !llvm.loop !5
+; CHECK: for.body3:
+; CHECK-NEXT: [[ADD89:%.*]] = phi i32 [ [[ARRAYIDX7_PROMOTED:%.*]], [[FOR_BODY3_PH:%.*]] ], [ [[ADD8:%.*]], [[FOR_BODY3:%.*]] ]
----------------
fhahn wrote:
> As we only check a single basic block, it is probably best to keep checking the hard-coded basic block names, because regex matched basic block names are only meaningful if the whole CFG is checked.
>
But for variables that we don't really care about, like bb names here, wouldn't it be better to have them matched by `.*`, with or without names? Otherwise, we may have to manually modify them again for an unrelated change in the future. Also, it may cause some confusion about if the CFG has changed.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105438/new/
https://reviews.llvm.org/D105438
More information about the llvm-commits
mailing list