#include <cond_branch_opt.h>
InstructionOptimizer pass (-inst-opt) MUST run before this pass. We need the following transformations to match more patterns:
- xor i1 x, y -> icmp ne i1 x, y
- and i1 x, y -> icmp eq i1 x, y
◆ CondBranchOpt()
retdec::bin2llvmir::CondBranchOpt::CondBranchOpt |
( |
| ) |
|
◆ run()
bool retdec::bin2llvmir::CondBranchOpt::run |
( |
| ) |
|
|
private |
◆ runOnInstruction()
◆ runOnModule()
bool retdec::bin2llvmir::CondBranchOpt::runOnModule |
( |
llvm::Module & |
m | ) |
|
|
overridevirtual |
◆ runOnModuleCustom()
bool retdec::bin2llvmir::CondBranchOpt::runOnModuleCustom |
( |
llvm::Module & |
m, |
|
|
Config * |
c, |
|
|
Abi * |
abi |
|
) |
| |
◆ transformConditionSub()
bool retdec::bin2llvmir::CondBranchOpt::transformConditionSub |
( |
llvm::BranchInst * |
br, |
|
|
llvm::Value * |
testedVal, |
|
|
llvm::Value * |
subVal, |
|
|
llvm::Instruction * |
binOp, |
|
|
llvm::CmpInst::Predicate |
predicate |
|
) |
| |
|
private |
◆ _abi
Abi* retdec::bin2llvmir::CondBranchOpt::_abi = nullptr |
|
private |
◆ _config
Config* retdec::bin2llvmir::CondBranchOpt::_config = nullptr |
|
private |
◆ _module
llvm::Module* retdec::bin2llvmir::CondBranchOpt::_module = nullptr |
|
private |
◆ _toRemove
std::unordered_set<llvm::Value*> retdec::bin2llvmir::CondBranchOpt::_toRemove |
|
private |
◆ ID
char retdec::bin2llvmir::CondBranchOpt::ID = 0 |
|
static |
The documentation for this class was generated from the following files:
- /var/cache/acbs/build/acbs.6bu6osb6/retdec/include/retdec/bin2llvmir/optimizations/cond_branch_opt/cond_branch_opt.h
- /var/cache/acbs/build/acbs.6bu6osb6/retdec/src/bin2llvmir/optimizations/cond_branch_opt/cond_branch_opt.cpp