[llvm] [InstCombine] Expand redundant phi cycle elimination (PR #67968)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 2 07:50:08 PDT 2023
================
@@ -1010,8 +1010,13 @@ static bool PHIsEqualValue(PHINode *PN, Value *NonPhiInVal,
// the value.
for (Value *Op : PN->incoming_values()) {
if (PHINode *OpPN = dyn_cast<PHINode>(Op)) {
- if (!PHIsEqualValue(OpPN, NonPhiInVal, ValueEqualPHIs))
- return false;
+ if (!PHIsEqualValue(OpPN, NonPhiInVal, ValueEqualPHIs)) {
+ if (NonPhiInVal)
+ return false;
+ else {
----------------
nikic wrote:
No else after return.
https://github.com/llvm/llvm-project/pull/67968
More information about the llvm-commits
mailing list