LLVM API Documentation
#include "llvm/Analysis/Passes.h"#include "llvm/Module.h"#include "llvm/Pass.h"#include "llvm/Instructions.h"#include "llvm/Constants.h"#include "llvm/DerivedTypes.h"#include "llvm/Analysis/AliasAnalysis.h"#include "llvm/Analysis/CallGraph.h"#include "llvm/Support/Compiler.h"#include "llvm/Support/CommandLine.h"#include "llvm/Support/InstIterator.h"#include "llvm/ADT/Statistic.h"#include "llvm/ADT/SCCIterator.h"#include <set>

Go to the source code of this file.
Defines | |
| #define | DEBUG_TYPE "globalsmodref-aa" |
Functions | |
| STATISTIC (NumNonAddrTakenGlobalVars,"Number of global vars without address taken") | |
| STATISTIC (NumNonAddrTakenFunctions,"Number of functions without address taken") | |
| STATISTIC (NumNoMemFunctions,"Number of functions that do not access memory") | |
| STATISTIC (NumReadMemFunctions,"Number of functions that only read memory") | |
| STATISTIC (NumIndirectGlobalVars,"Number of indirect global objects") | |
| Pass * | llvm::createGlobalsModRefPass () |
Variables | |
| static RegisterPass < GlobalsModRef > | X ("globalsmodref-aa","Simple mod/ref analysis for globals", false, true) |
| static RegisterAnalysisGroup < AliasAnalysis > | Y (X) |
| #define DEBUG_TYPE "globalsmodref-aa" |
Definition at line 17 of file GlobalsModRef.cpp.
| STATISTIC | ( | NumIndirectGlobalVars | , | |
| "Number of indirect global objects" | ||||
| ) |
| STATISTIC | ( | NumReadMemFunctions | , | |
| "Number of functions that only read memory" | ||||
| ) |
| STATISTIC | ( | NumNoMemFunctions | , | |
| "Number of functions that do not access memory" | ||||
| ) |
| STATISTIC | ( | NumNonAddrTakenFunctions | , | |
| "Number of functions without address taken" | ||||
| ) |
| STATISTIC | ( | NumNonAddrTakenGlobalVars | , | |
| "Number of global vars without address taken" | ||||
| ) |
| std::map<Value*, GlobalValue*> AllocsForIndirectGlobals |
AllocsForIndirectGlobals - If an instruction allocates memory for an indirect global, this map indicates which one.
Definition at line 83 of file GlobalsModRef.cpp.
FunctionEffect - Capture whether or not this function reads or writes to ANY memory. If not, we can do a lot of aggressive analysis on it.
Definition at line 65 of file GlobalsModRef.cpp.
| std::map<Function*, FunctionRecord> FunctionInfo |
FunctionInfo - For each function, keep track of what globals are modified or read.
Definition at line 87 of file GlobalsModRef.cpp.
| std::map<GlobalValue*, unsigned> GlobalInfo |
GlobalInfo - Maintain mod/ref info for all of the globals without addresses taken that are read or written (transitively) by this function.
Definition at line 50 of file GlobalsModRef.cpp.
char ID [static] |
Definition at line 90 of file GlobalsModRef.cpp.
| std::set<GlobalValue*> IndirectGlobals |
IndirectGlobals - The memory pointed to by this global is known to be 'owned' by the global.
Definition at line 79 of file GlobalsModRef.cpp.
| bool MayReadAnyGlobal |
MayReadAnyGlobal - May read global variables, but it is not known which.
Definition at line 53 of file GlobalsModRef.cpp.
| std::set<GlobalValue*> NonAddressTakenGlobals |
NonAddressTakenGlobals - The globals that do not have their addresses taken.
Definition at line 75 of file GlobalsModRef.cpp.
RegisterPass<GlobalsModRef> X("globalsmodref-aa","Simple mod/ref analysis for globals", false, true) [static] |
RegisterAnalysisGroup<AliasAnalysis> Y(X) [static] |
This web site is hosted by the Computer Science Department at the University of Illinois at Urbana-Champaign.