#include <SaberCheckerAPI.h>
Definition at line 44 of file SaberCheckerAPI.h.
◆ TDAPIMap
◆ CHECKER_TYPE
Enumerator |
---|
CK_DUMMY | |
CK_ALLOC | dummy type
|
CK_FREE | memory allocation
|
CK_FOPEN | memory deallocation
|
CK_FCLOSE | File open.
File close
|
Definition at line 48 of file SaberCheckerAPI.h.
49 {
55 };
@ CK_FREE
memory allocation
@ CK_FOPEN
memory deallocation
◆ SaberCheckerAPI()
SVF::SaberCheckerAPI::SaberCheckerAPI |
( |
| ) |
|
|
inlineprivate |
Constructor.
Definition at line 64 of file SaberCheckerAPI.h.
65 {
67 }
void init()
Initialize the map.
◆ getCheckerAPI()
Return a static reference.
Definition at line 89 of file SaberCheckerAPI.h.
90 {
92 {
94 }
96 }
static SaberCheckerAPI * ckAPI
Static reference.
SaberCheckerAPI()
Constructor.
◆ getType()
Get the function type of a function.
Definition at line 76 of file SaberCheckerAPI.h.
77 {
79 {
80 TDAPIMap::const_iterator
it=
tdAPIMap.find(
F->getName());
83 }
85 }
TDAPIMap tdAPIMap
API map, from a string to threadAPI type.
llvm::IRBuilder IRBuilder
◆ init()
void SaberCheckerAPI::init |
( |
| ) |
|
|
private |
Initialize the map.
initialize the map
Definition at line 144 of file SaberCheckerAPI.cpp.
145{
150 {
152 {
153
154
156 {
159 assert(!
"ei_pairs not grouped by type");
160 }
163 }
165 {
168 assert(!
"duplicate name in ei_pairs");
169 }
171 }
172}
static const ei_pair ei_pairs[]
◆ isFClose() [1/2]
Definition at line 140 of file SaberCheckerAPI.h.
141 {
142 return isFClose(cs->getCalledFunction());
143 }
bool isFClose(const SVFFunction *fun) const
Return true if this call is a file close.
◆ isFClose() [2/2]
Return true if this call is a file close.
Definition at line 136 of file SaberCheckerAPI.h.
137 {
139 }
CHECKER_TYPE getType(const SVFFunction *F) const
Get the function type of a function.
◆ isFOpen() [1/2]
Definition at line 128 of file SaberCheckerAPI.h.
129 {
130 return isFOpen(cs->getCalledFunction());
131 }
bool isFOpen(const SVFFunction *fun) const
Return true if this call is a file open.
◆ isFOpen() [2/2]
◆ isMemAlloc() [1/2]
Definition at line 104 of file SaberCheckerAPI.h.
105 {
107 }
bool isMemAlloc(const SVFFunction *fun) const
Return true if this call is a memory allocation.
◆ isMemAlloc() [2/2]
◆ isMemDealloc() [1/2]
Definition at line 116 of file SaberCheckerAPI.h.
117 {
119 }
bool isMemDealloc(const SVFFunction *fun) const
Return true if this call is a memory deallocation.
◆ isMemDealloc() [2/2]
Return true if this call is a memory deallocation.
Definition at line 112 of file SaberCheckerAPI.h.
◆ ckAPI
◆ tdAPIMap
The documentation for this class was generated from the following files: