ROSE
0.9.6a
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
arrIndexLabeler.h
Go to the documentation of this file.
1
#ifndef ARR_INDEX_LABELER_H
2
#define ARR_INDEX_LABELER_H
3
4
#include <
sage3.h
>
5
#include <list>
6
7
namespace
arrIndexLabeler {
8
9
// labels the portion of the AST rooted at root with annotations that identify the various portions
10
// the read/write sides of SgAssignOp nodes (if they are)
11
void
addArrayIndexAnnotations
(
SgNode
* root);
12
13
// returns true if the given node is part of an array index expression and false otherwise
14
bool
isArrayIndex
(
SgNode
* n);
15
16
// returns true the given SgPntrArrRefExp node this is a top-level SgPntrArrRefExp that is not part
17
// of a larger SgPntrArrRefExp
18
// (i.e. given a[b[i][j]][k][l], it is either a[b[i][j]][k][l] or b[i][j])
19
bool
isTopArrayRefExp
(
const
SgNode
* n);
20
21
// returns the SgExpression node that contains the name of the array in the given SgPntrArrRefExp or
22
// NULL if the node is not a SgPntrArrRefExp
23
SgExpression
*
getArrayNameExp
(
SgNode
* n);
24
25
// returns the dimensionality of the array reference in the given SgPntrArrRefExp
26
int
getArrayDim
(
SgPntrArrRefExp
* n);
27
28
// returns the list of index expressionf in the given SgPntrArrRefExp
29
std::list<SgExpression*>&
getArrayIndexExprs
(
SgPntrArrRefExp
* n);
30
}
31
#endif
rose-edg4x
src
midend
programAnalysis
genericDataflow
arrIndexLabeler
arrIndexLabeler.h
Generated on Mon May 5 2014 17:28:48 for ROSE by
1.8.4