[all-commits] [llvm/llvm-project] d8c6d2: -funique-internal-linkage-names appends a hex md5h...

Sriraman Tallam via All-commits all-commits at lists.llvm.org
Mon Jan 11 11:15:16 PST 2021


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: d8c6d24359f17c55a8966231ef74e8f4b03ad282
      https://github.com/llvm/llvm-project/commit/d8c6d24359f17c55a8966231ef74e8f4b03ad282
  Author: Sriraman Tallam <tmsriram at google.com>
  Date:   2021-01-11 (Mon, 11 Jan 2021)

  Changed paths:
    M clang/test/CodeGen/unique-internal-linkage-names.cpp
    M llvm/lib/Transforms/Utils/UniqueInternalLinkageNames.cpp
    M llvm/test/Transforms/UniqueInternalLinkageNames/unique_symbol_names.ll

  Log Message:
  -----------
  -funique-internal-linkage-names appends a hex md5hash suffix to the symbol name which is not demangler friendly, convert it to decimal.

Please see D93747 for more context which tries to make linkage names of internal
linkage functions to be the uniqueified names. This causes a problem with gdb
because breaking using the demangled function name will not work if the new
uniqueified name cannot be demangled. The problem is the generated suffix which
is a mix of integers and letters which do not demangle. The demangler accepts
either all numbers or all letters. This patch simply converts the hash to decimal.

There is no loss of uniqueness by doing this as the precision is maintained.
The symbol names get longer by a few characters though.

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




More information about the All-commits mailing list