[PATCH] D26892: [SCCP] Remove (maybe?) wrong code in visitBinaryOperator
Eli Friedman via llvm-commits
llvm-commits at lists.llvm.org
Sat Nov 19 19:00:29 PST 2016
efriedma added inline comments.
================
Comment at: lib/Transforms/Scalar/SCCP.cpp:932
+ if (NonOverdefVal->isUnknown())
return;
----------------
This is okay, I guess, but I don't think it fixes anything.
================
Comment at: lib/Transforms/Scalar/SCCP.cpp:940
+ // X or -1 = -1
+ if (NonOverdefVal->getConstantInt()->isAllOnesValue())
+ return markConstant(IV, &I, NonOverdefVal->getConstant());
----------------
NonOverdefVal isn't guaranteed to be a ConstantInt here.
https://reviews.llvm.org/D26892
More information about the llvm-commits
mailing list