[all-commits] [llvm/llvm-project] 0005ef: [DebugInfo][dsymutil] Keep locations for function-...

Ellis Hoag via All-commits all-commits at lists.llvm.org
Tue Dec 14 09:28:36 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 0005efd455c490d72a3c927edf4f9bd293dfbde2
      https://github.com/llvm/llvm-project/commit/0005efd455c490d72a3c927edf4f9bd293dfbde2
  Author: Ellis Hoag <ellishoag at fb.com>
  Date:   2021-12-14 (Tue, 14 Dec 2021)

  Changed paths:
    M llvm/lib/DWARFLinker/DWARFLinker.cpp
    A llvm/test/tools/dsymutil/Inputs/inlined-static-variable/4.o
    M llvm/test/tools/dsymutil/X86/dead-stripped.cpp
    M llvm/test/tools/dsymutil/X86/dummy-debug-map.map
    A llvm/test/tools/dsymutil/X86/inlined-static-variable.cpp

  Log Message:
  -----------
  [DebugInfo][dsymutil] Keep locations for function-local globals

In debug info, we expect variables to have location info if they are used and we don't want location info for functions that are not used. However, if an unused function is inlined, we could have the scenario where a function is not in the final binary but its static variable is in the final binary. Ensure that variables in the final binary have location debug info even if their scope was inlined.

Also add `--implicit-check-not` to a test for clarity.

Reviewed By: JDevlieghere

Differential Revision: https://reviews.llvm.org/D115565




More information about the All-commits mailing list