[PATCH] D94470: [LSR] Don't break a critical edge if parent ends with "callbr"
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 12 15:35:15 PST 2021
MaskRay added inline comments.
================
Comment at: llvm/test/Transforms/LoopStrengthReduce/callbr-critical-edge-splitting.ll:9
+
+define dso_local i32 @test1() local_unnamed_addr {
+entry:
----------------
@fhahn
The exiting edge (`%do.body.i.i.rdrand_int.exit.i_crit_edge -> %for.end`) is a critical edge.
`SplitBlockPredecessors` is called with `LoopPreds` being BBs other than `TIBB`.
`SplitBlockPredecessors` asserts if one such BB (`%for.cond`) has an IndirectBr/CallBr terminator.
================
Comment at: llvm/test/Transforms/LoopStrengthReduce/callbr-critical-edge-splitting.ll:23
+
+do.body.i.i.do.body.i.i_crit_edge: ; preds = %do.body.i.i.do.body.i.i_crit_edge, %cond.true.i
+ %pgocount711 = phi i64 [ %0, %do.body.i.i.do.body.i.i_crit_edge ], [ 0, %cond.true.i ]
----------------
Perhaps simplify the BB names. For example `_crit_edge` can be dropped as it is the name introduced by a previous critical edge breaking step.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D94470/new/
https://reviews.llvm.org/D94470
More information about the llvm-commits
mailing list