diff options
author | Nick Lewycky <nicholas@mxc.ca> | 2011-04-08 22:19:52 +0000 |
---|---|---|
committer | Nick Lewycky <nicholas@mxc.ca> | 2011-04-08 22:19:52 +0000 |
commit | 918035f802be7840177f77389d0b70415f84b06f (patch) | |
tree | 9823dececbc41c2cbc36a477b7a5ca691ecc2836 /lib/Transforms/Instrumentation/ProfilingUtils.h | |
parent | 7c90e4662205c14da6a340501316b3059f7fd871 (diff) | |
download | llvm-918035f802be7840177f77389d0b70415f84b06f.tar.gz llvm-918035f802be7840177f77389d0b70415f84b06f.tar.bz2 llvm-918035f802be7840177f77389d0b70415f84b06f.tar.xz |
Add a function for profiling to run at shutdown. Unlike the existing API, this
can be used even when main() isn't present in the Module, but it means that you
don't get to read argv[].
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129163 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Instrumentation/ProfilingUtils.h')
-rw-r--r-- | lib/Transforms/Instrumentation/ProfilingUtils.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Transforms/Instrumentation/ProfilingUtils.h b/lib/Transforms/Instrumentation/ProfilingUtils.h index a76e3576e1..09b22171ff 100644 --- a/lib/Transforms/Instrumentation/ProfilingUtils.h +++ b/lib/Transforms/Instrumentation/ProfilingUtils.h @@ -18,9 +18,10 @@ #define PROFILINGUTILS_H namespace llvm { + class BasicBlock; class Function; class GlobalValue; - class BasicBlock; + class Module; class PointerType; void InsertProfilingInitCall(Function *MainFn, const char *FnName, @@ -29,6 +30,7 @@ namespace llvm { void IncrementCounterInBlock(BasicBlock *BB, unsigned CounterNum, GlobalValue *CounterArray, bool beginning = true); + void InsertProfilingShutdownCall(Function *Callee, Module *Mod); } #endif |