[all-commits] [llvm/llvm-project] d73564: [DebugInfo][CodeView] Use <lambda_n> as the displa...

Amy Huang via All-commits all-commits at lists.llvm.org
Thu Jan 28 16:31:02 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: d73564c510036b2d4f5858effdcd23fe54fc1063
      https://github.com/llvm/llvm-project/commit/d73564c510036b2d4f5858effdcd23fe54fc1063
  Author: Amy Huang <akhuang at google.com>
  Date:   2021-01-28 (Thu, 28 Jan 2021)

  Changed paths:
    M clang/include/clang/AST/Mangle.h
    M clang/lib/AST/ItaniumMangle.cpp
    M clang/lib/AST/MicrosoftMangle.cpp
    M clang/lib/CodeGen/CGDebugInfo.cpp
    M clang/test/CodeGenCXX/debug-info-codeview-unnamed.cpp
    M clang/test/CodeGenCXX/debug-info-gline-tables-only-codeview.cpp

  Log Message:
  -----------
  [DebugInfo][CodeView] Use <lambda_n> as the display name for lambdas.

Currently (for codeview) lambdas have a string like `<lambda_0>` in
their mangled name, and don't have any display name. This change uses the
`<lambda_0>` as the display name, which helps distinguish between lambdas
in -gline-tables-only, since there are no linkage names there.
It also changes how we display lambda names; previously we used
`<unnamed-tag>`; now it will show `<lambda_0>`.

I added a function to the mangling context code to create this string;
for Itanium it just returns an empty string.

Bug: https://bugs.llvm.org/show_bug.cgi?id=48432

Reviewed By: rnk

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




More information about the All-commits mailing list