[PATCH] D94934: [llvm] Prevent infinite loop in InstCombine of select statements
Theodore Popp via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 19 01:31:28 PST 2021
tpopp marked an inline comment as done.
tpopp added a comment.
I apologize, but I was not having any luck at creating a test case that wasn't constant folded away.
================
Comment at: llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp:1129
+ };
+ if (IsConstant(CmpRHS) && !IsConstant(CmpLHS))
if (auto *I = dyn_cast<Instruction>(TrueVal))
----------------
xbolva00 wrote:
> llvm patternmatch has m_ImmConstant :) check it
Thank you for the pointer.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D94934/new/
https://reviews.llvm.org/D94934
More information about the llvm-commits
mailing list