[PATCH] D57511: [DebugInfo] Stop changing labels for parameter DBG_VALUEs

David Stenberg via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 4 06:56:57 PST 2019


dstenb added a comment.

I have divided this into three measurements:

- "before": Without this patch
- "regs": Without this patch, but stop changing the label for values that are described by registers.
- "after": With this patch

As before, I built a clang binary from trunk using `-DCMAKE_BUILD_TYPE=RelWithDebInfo -DLLVM_TARGETS_TO_BUILD=X86`.

Here are the diffs from `llvm-dwarfdump -statistics` when stepping between the variants:

  $ diff -u before.txt regs.txt
  --- before.txt  2019-02-04 15:17:06.985994932 +0100
  +++ regs.txt    2019-02-04 15:14:27.799763830 +0100
  @@ -1,7 +1,7 @@
   {
   "call site entries": 0,
  -"scope bytes covered": 365024733,
  -"scope bytes total": 703739122,
  +"scope bytes covered": 364668389,
  +"scope bytes total": 703739115,
   "format": "ELF64-x86-64",
   "source functions": 330578,
   "total function size": 43819231,
  @@ -9,7 +9,7 @@
   "source variables": 7617628,
   "variables with location": 5251165,
   "version": 1,
  -"file": "clang-before",
  +"file": "clang-regs",
   "inlined functions": 3846999,
   "unique source variables": 1041245
   }



  $ diff -u regs.txt after.txt
  --- regs.txt    2019-02-04 15:14:27.799763830 +0100
  +++ after.txt   2019-02-04 15:19:18.815674181 +0100
  @@ -1,7 +1,7 @@
   {
   "call site entries": 0,
  -"scope bytes covered": 364668389,
  -"scope bytes total": 703739115,
  +"scope bytes covered": 364655966,
  +"scope bytes total": 703739101,
   "format": "ELF64-x86-64",
   "source functions": 330578,
   "total function size": 43819231,
  @@ -9,7 +9,7 @@
   "source variables": 7617628,
   "variables with location": 5251165,
   "version": 1,
  -"file": "clang-regs",
  +"file": "clang-after",
   "inlined functions": 3846999,
   "unique source variables": 1041245
   }



  $ ls clang-* | xargs -n1 stat --format='%s %n' | sort -h
  1313541136 clang-before
  1313541344 clang-regs
  1313541592 clang-after

I'm not very familiar with interpreting llvm-dwarfdump's statistics dump, but I'd thought I would at least post it while I try to understand it.

Are there any more measurements I should do?

I guess that a first step could be to only drop `beginFunction`'s behavior for register-described debug values, as it is for those it misbehaves, and we actively try to place such debug values at the start of the function e.g. in SelectionDAG.


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D57511/new/

https://reviews.llvm.org/D57511





More information about the llvm-commits mailing list