From 14f870366a93ba0c6311883d900e24339681ba76 Mon Sep 17 00:00:00 2001 From: Ian Levesque Date: Tue, 11 Feb 2020 13:52:45 -0800 Subject: [xray][clang] Always add xray-skip-entry/exit and xray-ignore-loops attrs The function attributes xray-skip-entry, xray-skip-exit, and xray-ignore-loops were only being applied if a function had an xray-instrument attribute, but they should apply if xray is enabled globally too. Differential Revision: https://reviews.llvm.org/D73842 --- clang/lib/Frontend/CompilerInvocation.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'clang/lib/Frontend/CompilerInvocation.cpp') diff --git a/clang/lib/Frontend/CompilerInvocation.cpp b/clang/lib/Frontend/CompilerInvocation.cpp index e57c7ef..ae39066 100644 --- a/clang/lib/Frontend/CompilerInvocation.cpp +++ b/clang/lib/Frontend/CompilerInvocation.cpp @@ -1099,8 +1099,7 @@ static bool ParseCodeGenArgs(CodeGenOptions &Opts, ArgList &Args, InputKind IK, Args.hasArg(OPT_fxray_always_emit_typedevents); Opts.XRayInstructionThreshold = getLastArgIntValue(Args, OPT_fxray_instruction_threshold_EQ, 200, Diags); - Opts.XRayIgnoreLoops = - Args.hasArg(OPT_fxray_ignore_loops, OPT_fno_xray_ignore_loops, false); + Opts.XRayIgnoreLoops = Args.hasArg(OPT_fxray_ignore_loops); auto XRayInstrBundles = Args.getAllArgValues(OPT_fxray_instrumentation_bundle); -- cgit v1.1