[PATCH] D127960: [InstCombine] Push freeze through recurrence phi
Nuno Lopes via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jun 17 01:03:37 PDT 2022
nlopes added inline comments.
================
Comment at: llvm/lib/Transforms/InstCombine/InstructionCombining.cpp:3803
+ if (StartBB->getFirstInsertionPt() == StartBB->end())
+ return nullptr; // Cannot insert into this block.
+
----------------
aqjune wrote:
> Not sure whether this can happen; when does this condition meet?
I was also wondering about that, but I guess it may happen with malformed BBs (e.g., with just PHIs but no terminator). Unreachable BBs are allowed to be malformed in LLVM IR (which is a bit unfortunate).
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D127960/new/
https://reviews.llvm.org/D127960
More information about the llvm-commits
mailing list