lto-dump: Do not print output file
authorMartin Liska <mliska@suse.cz>
Mon, 4 Jul 2022 14:32:51 +0000 (16:32 +0200)
committerMartin Liska <mliska@suse.cz>
Fri, 8 Jul 2022 10:52:47 +0000 (12:52 +0200)
commit95a234f5cbd510e6b8c8e53dd9f1003fddc84c28
tree478f75b38ccddf0bfd1f46f3bac8d7970912c744
parentf7854e2faf7640230062dec3596e71773ca500ed
lto-dump: Do not print output file

Right now the following is printed:

lto-dump
.file "<artificial>"
.ident "GCC: (GNU) 13.0.0 20220707 (experimental)"
.section .note.GNU-stack,"",@progbits

After the patch we print -help and do not emit any assembly output:

lto-dump
Usage: lto-dump [OPTION]... SUB_COMMAND [OPTION]...

LTO dump tool command line options.

  -list [options]           Dump the symbol list.
    -demangle               Dump the demangled output.
    -defined-only           Dump only the defined symbols.
...

gcc/lto/ChangeLog:

* lto-dump.cc (lto_main): Exit in the function
as we don't want any LTO bytecode processing.

gcc/ChangeLog:

* toplev.cc (init_asm_output): Do not init asm_out_file.
gcc/lto/lto-dump.cc
gcc/toplev.cc