clang API Documentation
#include <ThreadSafetyTIL.h>
Public Types | |
typedef SimpleArray< BasicBlock * > | BlockArray |
typedef BlockArray::iterator | iterator |
typedef BlockArray::const_iterator | const_iterator |
Public Member Functions | |
SCFG (MemRegionRef A, unsigned Nblocks) | |
SCFG (const SCFG &Cfg, BlockArray &&Ba) | |
bool | valid () const |
Return true if this CFG is valid. | |
bool | normal () const |
iterator | begin () |
iterator | end () |
const_iterator | begin () const |
const_iterator | end () const |
const_iterator | cbegin () const |
const_iterator | cend () const |
const BasicBlock * | entry () const |
BasicBlock * | entry () |
const BasicBlock * | exit () const |
BasicBlock * | exit () |
size_t | numBlocks () const |
unsigned | numInstructions () |
void | add (BasicBlock *BB) |
void | setEntry (BasicBlock *BB) |
void | setExit (BasicBlock *BB) |
void | computeNormalForm () |
template<class V > | |
V::R_SExpr | traverse (V &Vs, typename V::R_Ctx Ctx) |
template<class C > | |
C::CType | compare (const SCFG *E, C &Cmp) const |
Static Public Member Functions | |
static bool | classof (const SExpr *E) |
An SCFG is a control-flow graph. It consists of a set of basic blocks, each of which terminates in a branch to another basic block. There is one entry point, and one exit point.
Definition at line 1687 of file ThreadSafetyTIL.h.
Definition at line 1689 of file ThreadSafetyTIL.h.
Definition at line 1691 of file ThreadSafetyTIL.h.
Definition at line 1690 of file ThreadSafetyTIL.h.
clang::threadSafety::til::SCFG::SCFG | ( | MemRegionRef | A, |
unsigned | Nblocks | ||
) | [inline] |
Definition at line 1695 of file ThreadSafetyTIL.h.
clang::threadSafety::til::SCFG::SCFG | ( | const SCFG & | Cfg, |
BlockArray && | Ba | ||
) | [inline] |
Definition at line 1706 of file ThreadSafetyTIL.h.
void clang::threadSafety::til::SCFG::add | ( | BasicBlock * | BB | ) | [inline] |
Definition at line 1743 of file ThreadSafetyTIL.h.
iterator clang::threadSafety::til::SCFG::begin | ( | ) | [inline] |
Definition at line 1720 of file ThreadSafetyTIL.h.
const_iterator clang::threadSafety::til::SCFG::begin | ( | ) | const [inline] |
Definition at line 1723 of file ThreadSafetyTIL.h.
const_iterator clang::threadSafety::til::SCFG::cbegin | ( | ) | const [inline] |
Definition at line 1726 of file ThreadSafetyTIL.h.
const_iterator clang::threadSafety::til::SCFG::cend | ( | ) | const [inline] |
Definition at line 1727 of file ThreadSafetyTIL.h.
static bool clang::threadSafety::til::SCFG::classof | ( | const SExpr * | E | ) | [inline, static] |
Definition at line 1693 of file ThreadSafetyTIL.h.
References clang::threadSafety::til::SExpr::opcode().
C::CType clang::threadSafety::til::SCFG::compare | ( | const SCFG * | E, |
C & | Cmp | ||
) | const [inline] |
Definition at line 1768 of file ThreadSafetyTIL.h.
Definition at line 297 of file ThreadSafetyTIL.cpp.
References clang::threadSafety::til::SExpr::Block, clang::threadSafety::til::computeNodeID(), and clang::threadSafety::til::computeNodeSize().
iterator clang::threadSafety::til::SCFG::end | ( | ) | [inline] |
Definition at line 1721 of file ThreadSafetyTIL.h.
const_iterator clang::threadSafety::til::SCFG::end | ( | ) | const [inline] |
Definition at line 1724 of file ThreadSafetyTIL.h.
const BasicBlock* clang::threadSafety::til::SCFG::entry | ( | ) | const [inline] |
Definition at line 1729 of file ThreadSafetyTIL.h.
BasicBlock* clang::threadSafety::til::SCFG::entry | ( | ) | [inline] |
Definition at line 1730 of file ThreadSafetyTIL.h.
const BasicBlock* clang::threadSafety::til::SCFG::exit | ( | ) | const [inline] |
Definition at line 1731 of file ThreadSafetyTIL.h.
BasicBlock* clang::threadSafety::til::SCFG::exit | ( | ) | [inline] |
Definition at line 1732 of file ThreadSafetyTIL.h.
bool clang::threadSafety::til::SCFG::normal | ( | ) | const [inline] |
Return true if this CFG has been normalized. After normalization, blocks are in topological order, and block and instruction IDs have been assigned.
Definition at line 1718 of file ThreadSafetyTIL.h.
size_t clang::threadSafety::til::SCFG::numBlocks | ( | ) | const [inline] |
Return the number of blocks in the CFG. Block::blockID() will return a number less than numBlocks();
Definition at line 1736 of file ThreadSafetyTIL.h.
unsigned clang::threadSafety::til::SCFG::numInstructions | ( | ) | [inline] |
Return the total number of instructions in the CFG. This is useful for building instruction side-tables; A call to SExpr::id() will return a number less than numInstructions().
Definition at line 1741 of file ThreadSafetyTIL.h.
void clang::threadSafety::til::SCFG::setEntry | ( | BasicBlock * | BB | ) | [inline] |
Definition at line 1750 of file ThreadSafetyTIL.h.
void clang::threadSafety::til::SCFG::setExit | ( | BasicBlock * | BB | ) | [inline] |
Definition at line 1751 of file ThreadSafetyTIL.h.
V::R_SExpr clang::threadSafety::til::SCFG::traverse | ( | V & | Vs, |
typename V::R_Ctx | Ctx | ||
) | [inline] |
Definition at line 1756 of file ThreadSafetyTIL.h.
bool clang::threadSafety::til::SCFG::valid | ( | ) | const [inline] |
Return true if this CFG is valid.
Definition at line 1713 of file ThreadSafetyTIL.h.