Commit 97ed706a authored by Djordje Todorovic's avatar Djordje Todorovic
Browse files

Revert "[DebugInfo] Enable the debug entry values feature by default"

This reverts commit rG9f6ff07f8a39.

Found a test failure on clang-with-thin-lto-ubuntu buildbot.
parent 740bc366
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -63,6 +63,7 @@ CODEGENOPT(ExperimentalNewPassManager, 1, 0) ///< Enables the new, experimental
CODEGENOPT(DebugPassManager, 1, 0) ///< Prints debug information for the new
                                   ///< pass manager.
CODEGENOPT(DisableRedZone    , 1, 0) ///< Set when -mno-red-zone is enabled.
CODEGENOPT(EnableDebugEntryValues, 1, 0) ///< Emit call site parameter dbg info
CODEGENOPT(IndirectTlsSegRefs, 1, 0) ///< Set when -mno-tls-direct-seg-refs
                                     ///< is specified.
CODEGENOPT(DisableTailCalls  , 1, 0) ///< Do not emit tail calls.
+2 −0
Original line number Diff line number Diff line
@@ -390,6 +390,8 @@ def flto_visibility_public_std:
def flto_unit: Flag<["-"], "flto-unit">,
    HelpText<"Emit IR to support LTO unit features (CFI, whole program vtable opt)">;
def fno_lto_unit: Flag<["-"], "fno-lto-unit">;
def femit_debug_entry_values : Flag<["-"], "femit-debug-entry-values">,
    HelpText<"Enables debug info about call site parameter's entry values">;
def fdebug_pass_manager : Flag<["-"], "fdebug-pass-manager">,
    HelpText<"Prints debug information for the new pass manager">;
def fno_debug_pass_manager : Flag<["-"], "fno-debug-pass-manager">,
+1 −0
Original line number Diff line number Diff line
@@ -481,6 +481,7 @@ static void initTargetOptions(llvm::TargetOptions &Options,
  Options.DebuggerTuning = CodeGenOpts.getDebuggerTuning();
  Options.EmitStackSizeSection = CodeGenOpts.StackSizeSection;
  Options.EmitAddrsig = CodeGenOpts.Addrsig;
  Options.EnableDebugEntryValues = CodeGenOpts.EnableDebugEntryValues;
  Options.ForceDwarfFrameSection = CodeGenOpts.ForceDwarfFrameSection;

  Options.MCOptions.SplitDwarfFile = CodeGenOpts.SplitDwarfFile;
+2 −1
Original line number Diff line number Diff line
@@ -4861,7 +4861,8 @@ llvm::DINode::DIFlags CGDebugInfo::getCallSiteRelatedAttrs() const {
      (CGM.getCodeGenOpts().getDebuggerTuning() == llvm::DebuggerKind::LLDB ||
       CGM.getCodeGenOpts().getDebuggerTuning() == llvm::DebuggerKind::GDB);

  if (!SupportsDWARFv4Ext && CGM.getCodeGenOpts().DwarfVersion < 5)
  if (!SupportsDWARFv4Ext && CGM.getCodeGenOpts().DwarfVersion < 5 &&
      !CGM.getCodeGenOpts().EnableDebugEntryValues)
    return llvm::DINode::FlagZero;

  return llvm::DINode::FlagAllCallsDescribed;
+10 −0
Original line number Diff line number Diff line
@@ -792,6 +792,16 @@ static bool ParseCodeGenArgs(CodeGenOptions &Opts, ArgList &Args, InputKind IK,

  Opts.DisableLLVMPasses = Args.hasArg(OPT_disable_llvm_passes);
  Opts.DisableLifetimeMarkers = Args.hasArg(OPT_disable_lifetimemarkers);

  const llvm::Triple::ArchType DebugEntryValueArchs[] = {
      llvm::Triple::x86, llvm::Triple::x86_64, llvm::Triple::aarch64,
      llvm::Triple::arm, llvm::Triple::armeb};

  llvm::Triple T(TargetOpts.Triple);
  if (Opts.OptimizationLevel > 0 && Opts.hasReducedDebugInfo() &&
      llvm::is_contained(DebugEntryValueArchs, T.getArch()))
    Opts.EnableDebugEntryValues = Args.hasArg(OPT_femit_debug_entry_values);

  Opts.DisableO0ImplyOptNone = Args.hasArg(OPT_disable_O0_optnone);
  Opts.DisableRedZone = Args.hasArg(OPT_disable_red_zone);
  Opts.IndirectTlsSegRefs = Args.hasArg(OPT_mno_tls_direct_seg_refs);
Loading