#include <SaberAnnotator.h>
Saber annotation
Definition at line 43 of file SaberAnnotator.h.
◆ SaberAnnotator()
SVF::SaberAnnotator::SaberAnnotator |
( |
ProgSlice * |
slice | ) |
|
|
inline |
◆ ~SaberAnnotator()
virtual SVF::SaberAnnotator::~SaberAnnotator |
( |
| ) |
|
|
inlinevirtual |
◆ annotateFeasibleBranch()
void SaberAnnotator::annotateFeasibleBranch |
( |
const BranchInst * |
brInst, |
|
|
u32_t |
succPos |
|
) |
| |
Annotate branch instruction and its corresponding feasible path
Definition at line 78 of file SaberAnnotator.cpp.
81 assert((succPos == 0 || succPos == 1) &&
"branch instruction should only have two successors");
87 addMDTag(br,br->getCondition(),rawstr.str());
const SVFGNode * getSource() const
root and sink operations
llvm::BranchInst BranchInst
llvm::raw_string_ostream raw_string_ostream
const ProgSlice * _curSlice
void addMDTag(Instruction *inst, std::string str)
Simple add/remove meta data information.
NodeID getId() const
Get ID.
◆ annotateInfeasibleBranch()
void SaberAnnotator::annotateInfeasibleBranch |
( |
const BranchInst * |
brInst, |
|
|
u32_t |
succPos |
|
) |
| |
Annotate branch instruction and its corresponding infeasible path
Definition at line 93 of file SaberAnnotator.cpp.
96 assert((succPos == 0 || succPos == 1) &&
"branch instruction should only have two successors");
102 addMDTag(br,br->getCondition(),rawstr.str());
const SVFGNode * getSource() const
root and sink operations
llvm::BranchInst BranchInst
llvm::raw_string_ostream raw_string_ostream
const char * SB_INFESIBLE
const ProgSlice * _curSlice
void addMDTag(Instruction *inst, std::string str)
Simple add/remove meta data information.
NodeID getId() const
Get ID.
◆ annotateSinks()
void SaberAnnotator::annotateSinks |
( |
| ) |
|
Definition at line 55 of file SaberAnnotator.cpp.
62 const Instruction* sinkinst = ap->getCallSite()->getCallSite();
63 assert(SVFUtil::isa<CallInst>(sinkinst) &&
"not a call instruction?");
64 const CallInst* sink = SVFUtil::cast<CallInst>(sinkinst);
68 addMDTag(const_cast<CallInst*>(sink),sink->getArgOperand(0),rawstr.str());
71 assert(
false &&
"sink node is not a actual parameter?");
const SVFGNode * getSource() const
root and sink operations
llvm::Instruction Instruction
llvm::raw_string_ostream raw_string_ostream
const ProgSlice * _curSlice
void addMDTag(Instruction *inst, std::string str)
Simple add/remove meta data information.
NodeID getId() const
Get ID.
const char * SB_SLICESINK
const SVFGNodeSet & getSinks() const
◆ annotateSource()
void SaberAnnotator::annotateSource |
( |
| ) |
|
Annotation.
Definition at line 38 of file SaberAnnotator.cpp.
45 addMDTag(const_cast<Instruction*>(sourceinst),rawstr.str());
48 assert(
false &&
"instruction of source node not found");
const SVFGNode * getSource() const
root and sink operations
const char * SB_SLICESOURCE
Saber annotations.
const Value * getLLVMValue(const SVFGNode *node) const
Get llvm value from a SVFGNode.
llvm::Instruction Instruction
llvm::raw_string_ostream raw_string_ostream
const ProgSlice * _curSlice
void addMDTag(Instruction *inst, std::string str)
Simple add/remove meta data information.
◆ annotateSwitch()
void SaberAnnotator::annotateSwitch |
( |
SwitchInst * |
switchInst, |
|
|
u32_t |
succPos |
|
) |
| |
Annotate switch instruction and its corresponding feasible path
Definition at line 109 of file SaberAnnotator.cpp.
111 assert(succPos < switchInst->getNumSuccessors() &&
"successor position not correct!");
◆ _curSlice
const ProgSlice* SVF::SaberAnnotator::_curSlice |
|
private |
The documentation for this class was generated from the following files: