[all-commits] [llvm/llvm-project] 8710ef: [MC][AMDGPU][llvm-objdump] Synthesized local label...

Tim Renouf via All-commits all-commits at lists.llvm.org
Mon Apr 26 05:57:19 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 8710eff6c3bab333bd270573fc349938b9a69dc0
      https://github.com/llvm/llvm-project/commit/8710eff6c3bab333bd270573fc349938b9a69dc0
  Author: Tim Renouf <tim.renouf at amd.com>
  Date:   2021-04-26 (Mon, 26 Apr 2021)

  Changed paths:
    M llvm/include/llvm/MC/MCDisassembler/MCSymbolizer.h
    M llvm/lib/Target/AMDGPU/Disassembler/AMDGPUDisassembler.cpp
    M llvm/lib/Target/AMDGPU/Disassembler/AMDGPUDisassembler.h
    A llvm/test/tools/llvm-objdump/AMDGPU/elf-disassemble-symbolize-operands.yaml
    M llvm/tools/llvm-objdump/llvm-objdump.cpp

  Log Message:
  -----------
  [MC][AMDGPU][llvm-objdump] Synthesized local labels in disassembly

1. Add an accessor function to MCSymbolizer to retrieve addresses
   referenced by a symbolizable operand, but not resolved to a symbol.
   That way, the caller can synthesize labels at those addresses and
   then retry disassembling the section.

2. Implement that in AMDGPU -- a failed symbol lookup results in the
   address being added to a vector returned by the new function.

3. Use that in llvm-objdump when using MCSymbolizer (which only happens
   on AMDGPU) and SymbolizeOperands is on.

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

Change-Id: I19087c3bbfece64bad5a56ee88bcc9110d83989e




More information about the All-commits mailing list