diff options
Diffstat (limited to 'llvm/lib/Transforms/IPO/GlobalOpt.cpp')
| -rw-r--r-- | llvm/lib/Transforms/IPO/GlobalOpt.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/IPO/GlobalOpt.cpp b/llvm/lib/Transforms/IPO/GlobalOpt.cpp index dbdea1ecdd7..89850d2e3da 100644 --- a/llvm/lib/Transforms/IPO/GlobalOpt.cpp +++ b/llvm/lib/Transforms/IPO/GlobalOpt.cpp @@ -1155,7 +1155,7 @@ static void ShrinkGlobalToBoolean(GlobalVariable *GV, Constant *OtherVal) { // instead of a select to synthesize the desired value. bool IsOneZero = false; if (ConstantInt *CI = dyn_cast<ConstantInt>(OtherVal)) - IsOneZero = InitVal->isNullValue() && CI->equalsInt(1); + IsOneZero = InitVal->isNullValue() && CI->isOne(); while (!GV->use_empty()) { Instruction *UI = cast<Instruction>(GV->use_back()); |

