Class holding static data and functions supporting File I/O. 
\tests Test of the AST File I/O mechanism include:
- 1) writes the AST out to a source file, the first source file, and compiles it
 
- 2) writes out the AST as a binary file
 
- 3) deletes the AST (clears all the memory pools)
 
- 4) reads in the binary file and runs all AST tests
 
- 5) writes the AST out to a source file, the second source file, and compiles it
 
- 6) runs a diff between the first source file and the second source file
 
- 7) Using a new program that just reads the binary AST file, he reads the binary AST file
 
- 8) writes the AST out to a source file, the first source file, and compiles it
 
- 9) runs a diff between the first source file and the third source file 
 
Definition at line 18 of file AST_FILE_IO.h.
 | 
| 
static void  | startUp (SgProject *root) | 
|   | 
| 
static unsigned long  | getSizeOfMemoryPool (const int position) | 
|   | 
| 
static unsigned long  | getSizeOfMemoryPoolUpToAst (AstData *astInPool, const int position) | 
|   | 
| 
static unsigned long  | getAccumulatedPoolSizeOfNewAst (const int position) | 
|   | 
| 
static unsigned long  | getAccumulatedPoolSizeOfAst (AstData *astInPool, const int position) | 
|   | 
| 
static unsigned long  | getPoolSizeOfNewAst (const int sgVariant) | 
|   | 
| 
static unsigned long  | getTotalNumberOfNodesOfAstInMemoryPool () | 
|   | 
| 
static unsigned long  | getTotalNumberOfNodesOfNewAst () | 
|   | 
| 
static bool  | areFreepointersContainingGlobalIndices () | 
|   | 
| 
static unsigned long  | getGlobalIndexFromSgClassPointer (SgNode *pointer) | 
|   | 
| 
static SgNode *  | getSgClassPointerFromGlobalIndex (unsigned long globalIndex) | 
|   | 
| 
static void  | compressAstInMemoryPool () | 
|   | 
| 
static void  | resetValidAstAfterWriting () | 
|   | 
| 
static void  | clearAllMemoryPools () | 
|   | 
| 
static void  | deleteMemoryPools () | 
|   | 
| 
static void  | deleteStaticData () | 
|   | 
| 
static void  | deleteStoredAsts () | 
|   | 
| 
static void  | setStaticDataOfAst (AstData *astInPool) | 
|   | 
| 
static int  | getNumberOfAsts () | 
|   | 
| 
static void  | addNewAst (AstData *newAst) | 
|   | 
| 
static void  | extendMemoryPoolsForRebuildingAST () | 
|   | 
| 
static void  | writeASTToStream (std::ostream &out) | 
|   | 
| 
static void  | writeASTToFile (std::string fileName) | 
|   | 
| 
static std::string  | writeASTToString () | 
|   | 
| 
static SgProject *  | readASTFromStream (std::istream &in) | 
|   | 
| 
static SgProject *  | readASTFromFile (std::string fileName) | 
|   | 
| 
static SgProject *  | readASTFromString (const std::string &s) | 
|   | 
| 
static void  | printFileMaps () | 
|   | 
| 
static void  | printListOfPoolSizes () | 
|   | 
| 
static void  | printListOfPoolSizesOfAst (int index) | 
|   | 
| 
static AstData *  | getAst (int index) | 
|   | 
| 
static AstData *  | getAstWithRoot (SgProject *root) | 
|   | 
| template<class TYPE >  | 
| static void  | registerAttribute () | 
|   | 
| static const std::map< std::string, CONSTRUCTOR > &  | getRegisteredAttributes () | 
|   | 
| 
static void  | reset () | 
|   | 
| 
static void  | display (const std::string &label) | 
|   |