[all-commits] [llvm/llvm-project] 964ef8: [lld] Support --lto-emit-asm and --plugin-opt=emit...

Hongtao Yu via All-commits all-commits at lists.llvm.org
Mon Apr 27 11:01:05 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 964ef8eecc98a881489c9bdd51db25dc74f301d0
      https://github.com/llvm/llvm-project/commit/964ef8eecc98a881489c9bdd51db25dc74f301d0
  Author: Hongtao Yu <hoy at fb.com>
  Date:   2020-04-27 (Mon, 27 Apr 2020)

  Changed paths:
    M lld/ELF/Config.h
    M lld/ELF/Driver.cpp
    M lld/ELF/LTO.cpp
    M lld/ELF/Options.td
    A lld/test/ELF/lto/emit-asm.ll

  Log Message:
  -----------
  [lld] Support --lto-emit-asm and --plugin-opt=emit-asm

Summary: The switch --plugin-opt=emit-asm can be used with the gold linker to dump the final assembly code generated by LTO in a user-friendly way. Unfortunately it doesn't work with lld. I'm hooking it up with lld. With that switch, lld emits assembly code into the output file (specified by -o) and if there are multiple input files, each of their assembly code will be emitted into a separate file named by suffixing the output file name with a unique number, respectively. The linking then stops after generating those assembly files.

Reviewers: espindola, wenlei, tejohnson, MaskRay, grimar

Reviewed By: tejohnson, MaskRay, grimar

Subscribers: pcc, emaste, inglorion, arichardson, hiraditya, MaskRay, steven_wu, dexonsmith, llvm-commits

Tags: #llvm

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




More information about the All-commits mailing list