projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
925e347
)
Implement new Instruction::isRelational method
author
Chris Lattner
<sabre@nondot.org>
Mon, 12 Jan 2004 23:18:25 +0000
(23:18 +0000)
committer
Chris Lattner
<sabre@nondot.org>
Mon, 12 Jan 2004 23:18:25 +0000
(23:18 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10810
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/VMCore/Instruction.cpp
patch
|
blob
|
history
diff --git
a/lib/VMCore/Instruction.cpp
b/lib/VMCore/Instruction.cpp
index 2e22bc3641aea224cfedd4a2ccddbde73703062e..6f2480bdde7b113c5d1ab509fbc106ff14cea087 100644
(file)
--- a/
lib/VMCore/Instruction.cpp
+++ b/
lib/VMCore/Instruction.cpp
@@
-148,6
+148,22
@@
bool Instruction::isCommutative(unsigned op) {
}
}
+/// isRelational - Return true if the instruction is a Set* instruction:
+///
+bool Instruction::isRelational(unsigned op) {
+ switch (op) {
+ case SetEQ:
+ case SetNE:
+ case SetLT:
+ case SetGT:
+ case SetLE:
+ case SetGE:
+ return true;
+ }
+ return false;
+}
+
+
/// isTrappingInstruction - Return true if the instruction may trap.
///