12 #ifndef RETDEC_BIN2LLVMIR_UTILS_SYMBOLIC_TREE_MATCH_H
13 #define RETDEC_BIN2LLVMIR_UTILS_SYMBOLIC_TREE_MATCH_H
27 template <
typename Pattern>
30 return const_cast<Pattern&
>(p).
match(st);
79 template<
typename LTy,
typename RTy>
86 template<
typename LTy,
typename RTy>
98 template <
typename LHS_t,
typename RHS_t,
bool Commutable = false>
103 llvm::BinaryOperator**
insn =
nullptr;
119 if (
auto* I = llvm::dyn_cast<llvm::BinaryOperator>(st.
value))
121 if ((
L.match(st.
ops[0]) &&
R.match(st.
ops[1]))
122 || (Commutable &&
L.match(st.
ops[1]) &&
R.match(st.
ops[0])))
136 template <
typename LHS,
typename RHS>
140 llvm::BinaryOperator** insn =
nullptr)
145 template <
typename LHS,
typename RHS>
149 llvm::BinaryOperator** insn =
nullptr)
160 template <
typename LHS_t,
typename RHS_t,
unsigned Opcode,
bool Commutable = false>
165 llvm::BinaryOperator**
insn =
nullptr;
167 BinaryOp_match(
const LHS_t &LHS,
const RHS_t &RHS, llvm::BinaryOperator** i =
nullptr) :
181 if (st.
value->getValueID() == llvm::Value::InstructionVal + Opcode)
183 if ((
L.match(st.
ops[0]) &&
R.match(st.
ops[1]))
184 || (Commutable &&
L.match(st.
ops[1]) &&
R.match(st.
ops[0])))
188 *
insn = llvm::cast<llvm::BinaryOperator>(st.
value);
193 if (
auto* ce = llvm::dyn_cast<llvm::ConstantExpr>(st.
value))
195 return ce->getOpcode() == Opcode &&
196 ((
L.match(st.
ops[0]) &&
R.match(st.
ops[1]))
197 || (Commutable &&
L.match(st.
ops[1]) &&
R.match(st.
ops[0])));
210 template <
typename LHS,
typename RHS>
214 llvm::BinaryOperator** add =
nullptr)
219 template <
typename LHS,
typename RHS>
223 llvm::BinaryOperator** fadd =
nullptr)
228 template <
typename LHS,
typename RHS>
232 llvm::BinaryOperator** sub =
nullptr)
237 template <
typename LHS,
typename RHS>
241 llvm::BinaryOperator** fsub =
nullptr)
246 template <
typename LHS,
typename RHS>
250 llvm::BinaryOperator** mul =
nullptr)
255 template <
typename LHS,
typename RHS>
259 llvm::BinaryOperator** fmul =
nullptr)
264 template <
typename LHS,
typename RHS>
268 llvm::BinaryOperator** udiv =
nullptr)
273 template <
typename LHS,
typename RHS>
277 llvm::BinaryOperator** sdiv =
nullptr)
282 template <
typename LHS,
typename RHS>
286 llvm::BinaryOperator** fdiv =
nullptr)
291 template <
typename LHS,
typename RHS>
295 llvm::BinaryOperator** urem =
nullptr)
300 template <
typename LHS,
typename RHS>
304 llvm::BinaryOperator** srem =
nullptr)
309 template <
typename LHS,
typename RHS>
313 llvm::BinaryOperator** frem =
nullptr)
318 template <
typename LHS,
typename RHS>
322 llvm::BinaryOperator** andi =
nullptr)
327 template <
typename LHS,
typename RHS>
331 llvm::BinaryOperator** ori =
nullptr)
336 template <
typename LHS,
typename RHS>
340 llvm::BinaryOperator** xori =
nullptr)
345 template <
typename LHS,
typename RHS>
349 llvm::BinaryOperator** shl =
nullptr)
354 template <
typename LHS,
typename RHS>
358 llvm::BinaryOperator** lshr =
nullptr)
363 template <
typename LHS,
typename RHS>
367 llvm::BinaryOperator** ashr =
nullptr)
378 template <
typename LHS,
typename RHS>
382 llvm::BinaryOperator** add =
nullptr)
387 template <
typename LHS,
typename RHS>
391 llvm::BinaryOperator** mul =
nullptr)
396 template <
typename LHS,
typename RHS>
400 llvm::BinaryOperator** andi =
nullptr)
405 template <
typename LHS,
typename RHS>
409 llvm::BinaryOperator** ori =
nullptr)
414 template <
typename LHS,
typename RHS>
418 llvm::BinaryOperator** xori =
nullptr)
445 if (
auto *O = llvm::dyn_cast<llvm::Operator>(st.
value))
447 if (O->getOpcode() == llvm::Instruction::Xor)
450 return L.match(st.
ops[0]);
452 return L.match(st.
ops[1]);
461 return llvm::isa<llvm::Constant>(V)
462 && llvm::cast<llvm::Constant>(V)->isAllOnesValue();
487 if (
auto *O = llvm::dyn_cast<llvm::Operator>(st.
value))
489 if (O->getOpcode() == llvm::Instruction::Sub)
500 return ((llvm::isa <llvm::ConstantInt>(LHS.
value)
501 && llvm::cast<llvm::ConstantInt>(LHS.
value)->isZero())
502 || llvm::isa<llvm::ConstantAggregateZero>(LHS)) &&
L.match(RHS);
522 typename PredicateTy,
523 bool Commutable =
false>
551 auto *I = llvm::dyn_cast<Class>(st.
value);
557 if ((
L.match(st.
ops[0]) &&
R.match(st.
ops[1]))
558 || (Commutable &&
L.match(st.
ops[1]) &&
R.match(st.
ops[0])))
572 template<
typename LHS,
typename RHS>
574 llvm::CmpInst::Predicate &Pred,
577 llvm::CmpInst** cmp =
nullptr)
582 template<
typename LHS,
typename RHS>
584 llvm::ICmpInst::Predicate &Pred,
587 llvm::ICmpInst** icmp =
nullptr)
592 template<
typename LHS,
typename RHS>
594 llvm::ICmpInst::Predicate &Pred,
597 llvm::ICmpInst** icmp =
nullptr)
602 template<
typename LHS,
typename RHS>
604 llvm::FCmpInst::Predicate &Pred,
607 llvm::FCmpInst** fcmp =
nullptr)
622 typename PredicateTy,
623 bool Commutable =
false>
651 auto *I = llvm::dyn_cast<Class>(st.
value);
661 if ((
L.match(st.
ops[0]) &&
R.match(st.
ops[1]))
662 || (Commutable &&
L.match(st.
ops[1]) &&
R.match(st.
ops[0])))
675 template<
typename LHS,
typename RHS>
677 llvm::CmpInst::Predicate Pred,
680 llvm::CmpInst** cmp =
nullptr)
685 template<
typename LHS,
typename RHS>
687 llvm::ICmpInst::Predicate Pred,
690 llvm::ICmpInst** icmp =
nullptr)
695 template<
typename LHS,
typename RHS>
697 llvm::ICmpInst::Predicate Pred,
700 llvm::ICmpInst** icmp =
nullptr)
705 template<
typename LHS,
typename RHS>
707 llvm::FCmpInst::Predicate Pred,
710 llvm::FCmpInst** fcmp =
nullptr)
724 llvm::LoadInst**
load =
nullptr;
739 if (
auto *LI = llvm::dyn_cast<llvm::LoadInst>(st.
value))
741 if (
Op.match(st.
ops[0]))
756 llvm::LoadInst** l =
nullptr)
767 template <
typename Class>
779 if (
auto*
CV = llvm::dyn_cast<Class>(st.
value))
828 template<
typename Class>
840 template<
typename Class>
845 return llvm::isa<Class>(st.
value);
884 template<
typename Class>
887 return class_match<Class>();
907 if (
auto* CI = llvm::dyn_cast<llvm::ConstantInt>(st.
value))
909 Res = &CI->getValue();
931 const llvm::APFloat*&
Res;
939 if (
auto *CI = llvm::dyn_cast<llvm::ConstantFP>(st.
value))
941 Res = &CI->getValueAPF();
965 if (
const auto* CI = llvm::dyn_cast<llvm::ConstantInt>(st.
value))
967 const llvm::APInt& CIV = CI->getValue();
969 return CIV ==
static_cast<uint64_t
>(Val);
980 template<
int64_t Val>
inline constantint_match<Val>
m_ConstantInt()
982 return constantint_match<Val>();
995 if (
const auto* C = llvm::dyn_cast<llvm::Constant>(st.
value))
997 return C->isNullValue();
1021 if (
auto* C = llvm::dyn_cast<llvm::ConstantInt>(st.
value))
1023 if (!C->isNullValue())
1036 llvm::ConstantInt* CI;
1050 if (
const auto *C = llvm::dyn_cast<llvm::Constant>(st.
value))
1052 return C->isNegativeZeroValue();
1071 if (
const auto *C = llvm::dyn_cast<llvm::Constant>(st.
value))
1073 return C->isZeroValue();
1097 if (
const auto* C = llvm::dyn_cast<llvm::Constant>(st.
value))
1099 return C->isOneValue();
1154 if (
const auto*
CV = llvm::dyn_cast<llvm::ConstantInt>(st.
value))
1156 if (
CV->getValue().ule(UINT64_MAX))
1158 VR =
CV->getZExtValue();
1191 const auto *CI = llvm::dyn_cast<llvm::ConstantInt>(st.
value);
1192 return CI && CI->getValue() ==
Val;
1217 template<
typename ITy>
bool match(ITy *V)
1219 if (
const auto *CFP = llvm::dyn_cast<llvm::ConstantFP>(V))
1220 return CFP->isExactlyValue(
Val);
Definition: hierarchy.h:24
Definition: symbolic_tree.h:43
bool isUnary() const
Definition: symbolic_tree.cpp:676
std::vector< SymbolicTree > ops
Definition: symbolic_tree.h:133
llvm::Value * value
Definition: symbolic_tree.h:131
bool isBinary() const
Definition: symbolic_tree.cpp:681
The frontend-end part of the decompiler.
BinaryOp_match< LHS, RHS, llvm::Instruction::FDiv > m_FDiv(const LHS &L, const RHS &R, llvm::BinaryOperator **fdiv=nullptr)
Definition: symbolic_tree_match.h:283
specific_fpval m_FPOne()
Match a float 1.0.
Definition: symbolic_tree_match.h:1231
BinaryOp_match< LHS, RHS, llvm::Instruction::FRem > m_FRem(const LHS &L, const RHS &R, llvm::BinaryOperator **frem=nullptr)
Definition: symbolic_tree_match.h:310
CmpClass_match< LHS, RHS, llvm::CmpInst, llvm::CmpInst::Predicate > m_Cmp(llvm::CmpInst::Predicate &Pred, const LHS &L, const RHS &R, llvm::CmpInst **cmp=nullptr)
Definition: symbolic_tree_match.h:573
BinaryOp_match< LHS, RHS, llvm::Instruction::Sub > m_Sub(const LHS &L, const RHS &R, llvm::BinaryOperator **sub=nullptr)
Definition: symbolic_tree_match.h:229
BinaryOp_match< LHS, RHS, llvm::Instruction::AShr > m_AShr(const LHS &L, const RHS &R, llvm::BinaryOperator **ashr=nullptr)
Definition: symbolic_tree_match.h:364
BinaryOp_match< LHS, RHS, llvm::Instruction::FSub > m_FSub(const LHS &L, const RHS &R, llvm::BinaryOperator **fsub=nullptr)
Definition: symbolic_tree_match.h:238
specific_fpval m_SpecificFP(double V)
Definition: symbolic_tree_match.h:1225
AnyBinaryOp_match< LHS, RHS, true > m_c_BinOp(const LHS &L, const RHS &R, llvm::BinaryOperator **insn=nullptr)
Definition: symbolic_tree_match.h:146
bind_ty< llvm::ConstantInt > m_ConstantInt(llvm::ConstantInt *&CI)
Definition: symbolic_tree_match.h:803
AnyBinaryOp_match< LHS, RHS > m_BinOp(const LHS &L, const RHS &R, llvm::BinaryOperator **insn=nullptr)
Definition: symbolic_tree_match.h:137
BinaryOp_match< LHS, RHS, llvm::Instruction::FMul > m_FMul(const LHS &L, const RHS &R, llvm::BinaryOperator **fmul=nullptr)
Definition: symbolic_tree_match.h:256
specific_intval m_SpecificInt(uint64_t V)
Definition: symbolic_tree_match.h:1196
BinaryOp_match< LHS, RHS, llvm::Instruction::Xor > m_Xor(const LHS &L, const RHS &R, llvm::BinaryOperator **xori=nullptr)
Definition: symbolic_tree_match.h:337
BinaryOp_match< LHS, RHS, llvm::Instruction::Mul > m_Mul(const LHS &L, const RHS &R, llvm::BinaryOperator **mul=nullptr)
Definition: symbolic_tree_match.h:247
CmpClass_match< LHS, RHS, llvm::FCmpInst, llvm::FCmpInst::Predicate > m_FCmp(llvm::FCmpInst::Predicate &Pred, const LHS &L, const RHS &R, llvm::FCmpInst **fcmp=nullptr)
Definition: symbolic_tree_match.h:603
match_combine_or< LTy, RTy > m_CombineOr(const LTy &L, const RTy &R)
Combine two pattern matchers matching L || R.
Definition: symbolic_tree_match.h:80
BinaryOp_match< LHS, RHS, llvm::Instruction::And > m_And(const LHS &L, const RHS &R, llvm::BinaryOperator **andi=nullptr)
Definition: symbolic_tree_match.h:319
match_not_zero m_not_Zero()
Match an arbitrary non-zero constant integer.
Definition: symbolic_tree_match.h:1034
match_one m_One()
Definition: symbolic_tree_match.h:1105
BinaryOp_match< LHS, RHS, llvm::Instruction::Add, true > m_c_Add(const LHS &L, const RHS &R, llvm::BinaryOperator **add=nullptr)
Definition: symbolic_tree_match.h:379
BinaryOp_match< LHS, RHS, llvm::Instruction::FAdd > m_FAdd(const LHS &L, const RHS &R, llvm::BinaryOperator **fadd=nullptr)
Definition: symbolic_tree_match.h:220
not_match< LHS > m_Not(const LHS &L)
Definition: symbolic_tree_match.h:466
BinaryOp_match< LHS, RHS, llvm::Instruction::Shl > m_Shl(const LHS &L, const RHS &R, llvm::BinaryOperator **shl=nullptr)
Definition: symbolic_tree_match.h:346
class_match< llvm::UndefValue > m_Undef()
Definition: symbolic_tree_match.h:869
match_neg_zero m_NegZero()
Match an arbitrary zero/null constant. This includes zero_initializer for vectors and ConstantPointer...
Definition: symbolic_tree_match.h:1062
bind_ty< llvm::Constant > m_Constant(llvm::Constant *&C)
Definition: symbolic_tree_match.h:808
BinaryOp_match< LHS, RHS, llvm::Instruction::Add > m_Add(const LHS &L, const RHS &R, llvm::BinaryOperator **add=nullptr)
Definition: symbolic_tree_match.h:211
bool match(SymbolicTree &st, const Pattern &p)
Definition: symbolic_tree_match.h:28
bind_ty< llvm::Value > m_Value(llvm::Value *&V)
Definition: symbolic_tree_match.h:788
BinaryOp_match< LHS, RHS, llvm::Instruction::URem > m_URem(const LHS &L, const RHS &R, llvm::BinaryOperator **urem=nullptr)
Definition: symbolic_tree_match.h:292
bind_ty< llvm::Instruction > m_Instruction(llvm::Instruction *&I)
Definition: symbolic_tree_match.h:823
BinaryOp_match< LHS, RHS, llvm::Instruction::SRem > m_SRem(const LHS &L, const RHS &R, llvm::BinaryOperator **srem=nullptr)
Definition: symbolic_tree_match.h:301
BinaryOp_match< LHS, RHS, llvm::Instruction::And, true > m_c_And(const LHS &L, const RHS &R, llvm::BinaryOperator **andi=nullptr)
Definition: symbolic_tree_match.h:397
BinaryOp_match< LHS, RHS, llvm::Instruction::LShr > m_LShr(const LHS &L, const RHS &R, llvm::BinaryOperator **lshr=nullptr)
Definition: symbolic_tree_match.h:355
BinaryOp_match< LHS, RHS, llvm::Instruction::SDiv > m_SDiv(const LHS &L, const RHS &R, llvm::BinaryOperator **sdiv=nullptr)
Definition: symbolic_tree_match.h:274
BinaryOp_match< LHS, RHS, llvm::Instruction::Xor, true > m_c_Xor(const LHS &L, const RHS &R, llvm::BinaryOperator **xori=nullptr)
Definition: symbolic_tree_match.h:415
BinaryOp_match< LHS, RHS, llvm::Instruction::Or > m_Or(const LHS &L, const RHS &R, llvm::BinaryOperator **ori=nullptr)
Definition: symbolic_tree_match.h:328
apfloat_match m_APFloat(const llvm::APFloat *&Res)
Match a ConstantFP, binding the specified pointer to the contained APFloat.
Definition: symbolic_tree_match.h:950
apint_match m_APInt(const llvm::APInt *&Res)
Match a ConstantInt, binding the specified pointer to the contained APInt.
Definition: symbolic_tree_match.h:918
bind_ty< llvm::GlobalVariable > m_GlobalVariable(llvm::GlobalVariable *&G)
Definition: symbolic_tree_match.h:818
neg_match< LHS > m_Neg(const LHS &L)
Match an integer negate.
Definition: symbolic_tree_match.h:507
match_any_zero m_AnyZero()
Match an arbitrary zero/null constant. This includes zero_initializer for vectors and ConstantPointer...
Definition: symbolic_tree_match.h:1082
match_zero m_Zero()
Match an arbitrary zero/null constant. This includes zero_initializer for vectors and ConstantPointer...
Definition: symbolic_tree_match.h:1005
bind_ty< llvm::ConstantFP > m_ConstantFP(llvm::ConstantFP *&C)
Definition: symbolic_tree_match.h:813
match_combine_and< LTy, RTy > m_CombineAnd(const LTy &L, const RTy &R)
Combine two pattern matchers matching L && R.
Definition: symbolic_tree_match.h:87
CmpClass_match< LHS, RHS, llvm::ICmpInst, llvm::ICmpInst::Predicate > m_ICmp(llvm::ICmpInst::Predicate &Pred, const LHS &L, const RHS &R, llvm::ICmpInst **icmp=nullptr)
Definition: symbolic_tree_match.h:583
CmpClass_match< LHS, RHS, llvm::ICmpInst, llvm::ICmpInst::Predicate, true > m_c_ICmp(llvm::ICmpInst::Predicate &Pred, const LHS &L, const RHS &R, llvm::ICmpInst **icmp=nullptr)
Definition: symbolic_tree_match.h:593
BinaryOp_match< LHS, RHS, llvm::Instruction::UDiv > m_UDiv(const LHS &L, const RHS &R, llvm::BinaryOperator **udiv=nullptr)
Definition: symbolic_tree_match.h:265
specificval_ty m_Specific(const llvm::Value *V)
Match if we have a specific specified value.
Definition: symbolic_tree_match.h:1132
LoadClass_match< OpTy > m_Load(const OpTy &Op, llvm::LoadInst **l=nullptr)
Definition: symbolic_tree_match.h:754
BinaryOp_match< LHS, RHS, llvm::Instruction::Mul, true > m_c_Mul(const LHS &L, const RHS &R, llvm::BinaryOperator **mul=nullptr)
Definition: symbolic_tree_match.h:388
BinaryOp_match< LHS, RHS, llvm::Instruction::Or, true > m_c_Or(const LHS &L, const RHS &R, llvm::BinaryOperator **ori=nullptr)
Definition: symbolic_tree_match.h:406
union retdec::pdbparser::_CV CV
Definition: archive_wrapper.h:19
Definition: symbolic_tree_match.h:100
LHS_t L
Definition: symbolic_tree_match.h:101
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:112
llvm::BinaryOperator ** insn
Definition: symbolic_tree_match.h:103
RHS_t R
Definition: symbolic_tree_match.h:102
AnyBinaryOp_match(const LHS_t &LHS, const RHS_t &RHS, llvm::BinaryOperator **i)
Definition: symbolic_tree_match.h:105
Definition: symbolic_tree_match.h:162
BinaryOp_match(const LHS_t &LHS, const RHS_t &RHS, llvm::BinaryOperator **i=nullptr)
Definition: symbolic_tree_match.h:167
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:174
RHS_t R
Definition: symbolic_tree_match.h:164
LHS_t L
Definition: symbolic_tree_match.h:163
llvm::BinaryOperator ** insn
Definition: symbolic_tree_match.h:165
Definition: symbolic_tree_match.h:525
RHS_t R
Definition: symbolic_tree_match.h:528
Class ** cmp
Definition: symbolic_tree_match.h:529
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:544
CmpClass_match(PredicateTy &Pred, const LHS_t &LHS, const RHS_t &RHS, Class **i=nullptr)
Definition: symbolic_tree_match.h:531
LHS_t L
Definition: symbolic_tree_match.h:527
PredicateTy & Predicate
Definition: symbolic_tree_match.h:526
Definition: symbolic_tree_match.h:625
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:644
RHS_t R
Definition: symbolic_tree_match.h:628
PredicateTy Predicate
Definition: symbolic_tree_match.h:626
Class ** cmp
Definition: symbolic_tree_match.h:629
CmpClass_pred_match(PredicateTy Pred, const LHS_t &LHS, const RHS_t &RHS, Class **i=nullptr)
Definition: symbolic_tree_match.h:631
LHS_t L
Definition: symbolic_tree_match.h:627
Definition: symbolic_tree_match.h:722
llvm::LoadInst ** load
Definition: symbolic_tree_match.h:724
LoadClass_match(const Op_t &OpMatch, llvm::LoadInst **l=nullptr)
Definition: symbolic_tree_match.h:726
Op_t Op
Definition: symbolic_tree_match.h:723
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:732
Definition: symbolic_tree_match.h:930
const llvm::APFloat *& Res
Definition: symbolic_tree_match.h:931
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:937
apfloat_match(const llvm::APFloat *&R)
Definition: symbolic_tree_match.h:932
Definition: symbolic_tree_match.h:897
const llvm::APInt *& Res
Definition: symbolic_tree_match.h:898
apint_match(const llvm::APInt *&R)
Definition: symbolic_tree_match.h:900
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:905
Definition: symbolic_tree_match.h:1144
uint64_t & VR
Definition: symbolic_tree_match.h:1145
bind_const_intval_ty(uint64_t &V)
Definition: symbolic_tree_match.h:1147
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:1152
Definition: symbolic_tree_match.h:769
Class *& VR
Definition: symbolic_tree_match.h:770
bind_ty(Class *&v)
Definition: symbolic_tree_match.h:772
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:777
Definition: symbolic_tree_match.h:842
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:843
Definition: symbolic_tree_match.h:962
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:963
Definition: symbolic_tree_match.h:1068
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:1069
Definition: symbolic_tree_match.h:60
RTy R
Definition: symbolic_tree_match.h:62
bool match(SymbolicTree &V)
Definition: symbolic_tree_match.h:69
match_combine_and(const LTy &Left, const RTy &Right)
Definition: symbolic_tree_match.h:64
LTy L
Definition: symbolic_tree_match.h:61
Definition: symbolic_tree_match.h:40
match_combine_or(const LTy &Left, const RTy &Right)
Definition: symbolic_tree_match.h:44
LTy L
Definition: symbolic_tree_match.h:41
bool match(SymbolicTree &V)
Definition: symbolic_tree_match.h:49
RTy R
Definition: symbolic_tree_match.h:42
Definition: symbolic_tree_match.h:1047
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:1048
Definition: symbolic_tree_match.h:1011
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:1019
match_not_zero(llvm::ConstantInt *&ci)
Definition: symbolic_tree_match.h:1014
llvm::ConstantInt *& CI
Definition: symbolic_tree_match.h:1012
Definition: symbolic_tree_match.h:1094
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:1095
Definition: symbolic_tree_match.h:992
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:993
Definition: symbolic_tree_match.h:472
LHS_t L
Definition: symbolic_tree_match.h:473
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:480
bool matchIfNeg(SymbolicTree &LHS, SymbolicTree &RHS)
Definition: symbolic_tree_match.h:498
neg_match(const LHS_t &LHS)
Definition: symbolic_tree_match.h:475
Definition: symbolic_tree_match.h:430
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:438
not_match(const LHS_t &LHS)
Definition: symbolic_tree_match.h:433
LHS_t L
Definition: symbolic_tree_match.h:431
bool isAllOnes(llvm::Value *V)
Definition: symbolic_tree_match.h:459
Match a specified floating point value.
Definition: symbolic_tree_match.h:1209
specific_fpval(double V)
Definition: symbolic_tree_match.h:1212
bool match(ITy *V)
Definition: symbolic_tree_match.h:1217
double Val
Definition: symbolic_tree_match.h:1210
Match a specified integer value.
Definition: symbolic_tree_match.h:1181
specific_intval(uint64_t V)
Definition: symbolic_tree_match.h:1184
uint64_t Val
Definition: symbolic_tree_match.h:1182
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:1189
Definition: symbolic_tree_match.h:1117
bool match(SymbolicTree &st)
Definition: symbolic_tree_match.h:1125
specificval_ty(const llvm::Value *V)
Definition: symbolic_tree_match.h:1120
const llvm::Value * Val
Definition: symbolic_tree_match.h:1118
Construction of symbolic tree from the given node.