diff options
author | David Chisnall <csdavec@swan.ac.uk> | 2012-04-09 15:42:15 +0000 |
---|---|---|
committer | David Chisnall <csdavec@swan.ac.uk> | 2012-04-09 15:42:15 +0000 |
commit | 649ee3fec12dcf7167630ff88087ad116e9eefa6 (patch) | |
tree | 2b788913f6a8820107f5e6a76c9653a5b0ca70f9 /lib/Frontend/CompilerInvocation.cpp | |
parent | e2571793ba6fc13e5525b8d7224812f99842a1a4 (diff) |
Add -fobjc-trace to emit a call before and after each Objective-C message send
for hooking in code flow visualisation applications.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154321 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Frontend/CompilerInvocation.cpp')
-rw-r--r-- | lib/Frontend/CompilerInvocation.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Frontend/CompilerInvocation.cpp b/lib/Frontend/CompilerInvocation.cpp index 02947c778c..aae0b48e75 100644 --- a/lib/Frontend/CompilerInvocation.cpp +++ b/lib/Frontend/CompilerInvocation.cpp @@ -249,6 +249,8 @@ static void CodeGenOptsToArgs(const CodeGenOptions &Opts, ToArgsList &Res) { Res.push_back("-mconstructor-aliases"); if (Opts.ObjCAutoRefCountExceptions) Res.push_back("-fobjc-arc-eh"); + if (Opts.ObjCTrace) + Res.push_back("-fobjc-trace"); if (!Opts.DebugPass.empty()) { Res.push_back("-mdebug-pass", Opts.DebugPass); } @@ -1109,6 +1111,7 @@ static bool ParseCodeGenArgs(CodeGenOptions &Opts, ArgList &Args, InputKind IK, Opts.AsmVerbose = Args.hasArg(OPT_masm_verbose); Opts.ObjCAutoRefCountExceptions = Args.hasArg(OPT_fobjc_arc_exceptions); + Opts.ObjCTrace = Args.hasArg(OPT_fobjc_trace); Opts.ObjCRuntimeHasARC = Args.hasArg(OPT_fobjc_runtime_has_arc); Opts.ObjCRuntimeHasTerminate = Args.hasArg(OPT_fobjc_runtime_has_terminate); Opts.CUDAIsDevice = Args.hasArg(OPT_fcuda_is_device); |