[gold] emit assembly listing from gold plugin on LTO stage
authorTeresa Johnson <tejohnson@google.com>
Wed, 2 Jan 2019 23:48:00 +0000 (23:48 +0000)
committerTeresa Johnson <tejohnson@google.com>
Wed, 2 Jan 2019 23:48:00 +0000 (23:48 +0000)
commit0aa09c62cb08c694de485354075239e3f44753bc
treeeb8bf0639484144033cdda869dd8e5da5f2053db
parente59da0ba063b204bdf16cc8cbe0c8de0cc1df699
[gold] emit assembly listing from gold plugin on LTO stage

Summary:
Sometimes it's useful to emit assembly after LTO stage to modify it manually. Emitting precodegen bitcode file (via save-temps plugin option) and then feeding it to llc doesn't always give the same binary as original.
This patch is simpler alternative to https://reviews.llvm.org/D24020.

Patch by Denis Bakhvalov.

Reviewers: mehdi_amini, tejohnson

Reviewed By: tejohnson

Subscribers: MaskRay, inglorion, dexonsmith, llvm-commits

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

llvm-svn: 350276
llvm/test/tools/gold/X86/emit-asm.ll [new file with mode: 0644]
llvm/tools/gold/gold-plugin.cpp