Code Listener  [unstable] git snapshot
Data Structures | Namespaces | Macros | Typedefs | Functions | Variables
pointsto.hh File Reference
#include "config_cl.h"
#include <cl/storage.hh>
#include <cl/cl_msg.hh>
#include <cl/cldebug.hh>

Go to the source code of this file.

Data Structures

class  BuildCtx
 
struct  BuildCtx::plot
 
struct  BuildCtx::debug
 

Namespaces

 CodeStorage
 object model that describes the analyzed code on the input
 
 CodeStorage::PointsTo
 

Macros

#define PT_DEBUG(level,...)
 
#define PT_ERROR(...)   PT_DEBUG(0, "ERROR: " << __VA_ARGS__)
 
#define FICS_PHASE_1   0x01
 
#define FICS_PHASE_2   0x02
 
#define FICS_PHASE_3   0x04
 

Typedefs

typedef std::pair< Node *, Node * > TNodePair
 
typedef std::vector< TNodePair > TNodeJoinTodo
 

Functions

void joinNodesS (BuildCtx &ctx, Graph &ptg, Node *nodeA, Node *nodeB)
 Join two nodes: nodeA = nodeA JOIN nodeB. More...
 
void joinFixPointS (BuildCtx &ctx, Graph &ptg)
 Start the merging of nodes based on ctx.joinTodo information. More...
 
Node * preventEndingS (Node *node)
 allocate and append one (empty) successor for node if it has not other output. More...
 
void appendNodeS (BuildCtx &ctx, Graph &ptg, Node *parent, Node *which)
 Append (even existing) node to other one as a successor. More...
 
Node * nodeAccessS (const CodeStorage::Storage &stor, Graph &ptg, const cl_operand &op, bool *referenced=NULL)
 Find or create node of graph based on whole information provided by some operand. More...
 
Node * appendEmptyS (Node *root)
 Similar to preventEndingS() except that it would fail if the single output already existed. More...
 
const Node * hasOutputS (const Node *node)
 Return non-modifiable output node pointer if the output of 'node' exists. More...
 
Node * getOutputS (Node *node)
 Return modifiable output node pointer if the output of 'node' exists. More...
 
Node * goDownS (Node *start, int steps)
 go 'steps'-times downwards in node's graph. More...
 
void bindItem (Graph &ptg, Node *n, const Item *)
 This is blind function – it does exactly what we want from it. More...
 
bool bindVarList (BuildCtx &ctx, Graph &ptg, Node *target, const TItemList &nl)
 bindVarList is more sophisticated function than 'bindVar'. More...
 
bool follows (const Graph &ptg, const Var *varA, const Var *varB)
 return true if some variable (lhs) follows another one (rhs) More...
 
bool followsGlobal (const CodeStorage::Storage &stor, const Var *lVar, const Var *rVar)
 
bool isPointed (const Graph *ptg, const Var *v)
 return true if given variable 'v' is pointed in given graph 'ptg' More...
 
bool isPointedGlob (const CodeStorage::Storage &stor, const Var *v)
 return true if the given variable 'v' is pointed in any points-to graph More...
 
Node * getNode (Graph &ptg, const Var *v)
 find (or create if doesn't exist!) node for given variable More...
 
Node * getNode (Graph &ptg, const cl_operand &op)
 
Node * getNode (Graph &ptg, const Item *i)
 
Node * nodeFromForeign (Graph &ptg, const Item *i)
 find or create node based on item from foreign graph More...
 
Node * allocNodeForItem (Graph &, const Item *i)
 allocate new node and bind i with this new node More...
 
const Node * existsUid (const Graph &graph, int uid)
 return the node pointer according to passed 'uid' of variable or function. More...
 
const Node * existsVar (const Graph &graph, const Var *v)
 return pointer to node with given variable 'v' More...
 
const Node * existsItem (const Graph &graph, const Item *i)
 
Node * findNode (Graph &, int)
 return pointer to (modifiable) node object according to given variable or node item pointer. More...
 
Node * findNode (Graph &, const Var *)
 
Node * findNode (Graph &, const Item *)
 
void setBlackHole (Graph &, Node *)
 Setup the given node to be black-hole – self-pointed node that eats each other note that is set as its successor. More...
 
void addEdge (Node *from, Node *to)
 Interconnect two given nodes with edge. More...
 
bool existsError (const Storage &stor)
 return true when some problem occurs More...
 
void pointsToAnalyse (Storage &stor, const std::string &conf)
 

Variables

int pt_dbg_level
 

Macro Definition Documentation

#define FICS_PHASE_1   0x01

Definition at line 47 of file pointsto.hh.

Referenced by BuildCtx::BuildCtx().

#define FICS_PHASE_2   0x02

Definition at line 48 of file pointsto.hh.

Referenced by BuildCtx::BuildCtx().

#define FICS_PHASE_3   0x04

Definition at line 49 of file pointsto.hh.

Referenced by BuildCtx::BuildCtx().

#define PT_DEBUG (   level,
  ... 
)
Value:
do { \
if ((level) <= pt_dbg_level) \
CL_DEBUG("PT: " << __VA_ARGS__); \
} while (0)

Definition at line 31 of file pointsto.hh.

#define PT_ERROR (   ...)    PT_DEBUG(0, "ERROR: " << __VA_ARGS__)

Definition at line 37 of file pointsto.hh.

Variable Documentation

int pt_dbg_level