OSDN Git Service
(root)
/
android-x86
/
external-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8c3abee
)
[InstSimplify] Use ICmpInst::isEquality predicate method. NFC
author
Craig Topper
<craig.topper@gmail.com>
Tue, 6 Jun 2017 07:13:04 +0000
(07:13 +0000)
committer
Craig Topper
<craig.topper@gmail.com>
Tue, 6 Jun 2017 07:13:04 +0000
(07:13 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@304770
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Analysis/InstructionSimplify.cpp
patch
|
blob
|
history
diff --git
a/lib/Analysis/InstructionSimplify.cpp
b/lib/Analysis/InstructionSimplify.cpp
index
c19af1b
..
d5b93ca
100644
(file)
--- a/
lib/Analysis/InstructionSimplify.cpp
+++ b/
lib/Analysis/InstructionSimplify.cpp
@@
-3308,7
+3308,7
@@
static Value *SimplifyICmpInst(unsigned Predicate, Value *LHS, Value *RHS,
}
// icmp eq|ne X, Y -> false|true if X != Y
- if (
(Pred == ICmpInst::ICMP_EQ || Pred == ICmpInst::ICMP_NE
) &&
+ if (
ICmpInst::isEquality(Pred
) &&
isKnownNonEqual(LHS, RHS, Q.DL, Q.AC, Q.CxtI, Q.DT)) {
LLVMContext &Ctx = LHS->getType()->getContext();
return Pred == ICmpInst::ICMP_NE ?