This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] final: Improve output for -dp and -fverbose-asm
- From: Michael Matz <matz at suse dot de>
- To: David Malcolm <dmalcolm at redhat dot com>
- Cc: Martin Sebor <msebor at gmail dot com>, Segher Boessenkool <segher at kernel dot crashing dot org>, gcc-patches at gcc dot gnu dot org
- Date: Mon, 4 Dec 2017 16:49:21 +0100 (CET)
- Subject: Re: [PATCH] final: Improve output for -dp and -fverbose-asm
- Authentication-results: sourceware.org; auth=none
- References: <ac47cf30cab2820e22831de664d8d42964705d88.1511996668.git.segher@kernel.crashing.org> <95ff7e21-ca49-b714-cd17-632a30fffb61@gmail.com> <20171130111644.GY10515@gate.crashing.org> <2393c7a7-60a9-29fd-4d0c-49523734201d@gmail.com> <20171130164425.GB10515@gate.crashing.org> <dbbf5199-96cf-9d25-6711-eaedccf27c18@gmail.com> <alpine.LSU.2.21.1711301755560.25295@wotan.suse.de> <1512063985.27881.50.camel@redhat.com>
Hi,
On Thu, 30 Nov 2017, David Malcolm wrote:
> -fverbose-asm is on the border of compiler-debugging vs end-user usage.
I have yet to see a relevant percentage of end-users who even know what
assembler is. On the gcc.*@ and kernel.* mailing lists, sure. But Joe
Randomapp?
> FWIW an improvement to -fverbose-asm was explicitly mentioned in the
> gcc 7 release notes:
> https://gcc.gnu.org/gcc-7/changes.html
> and I've seen at least some end-users comment favorably on that change;
> this was:
> https://gcc.gnu.org/ml/gcc-patches/2016-08/msg01051.html
> which was originally a "-fasm-show-source" option.
Yes. I think this was actually a disservice to readability of
-fverbose-asm (sorry!) and would have preferred a suboption as well (but
wouldn't have complained if with-sources would be the default). First, it
clutters the asm instructions with intervening non-aligned lines (and
left-hanging even, giving more visual importance to them instead of what
is actually important, which for a switch named verbose-asm seems the asm
to me) and second it has the same problem as debugging scheduled code:
jumping around crazy and stating the same source line multiple times.
(Basically the same reason 'objdump -dS' is similarly ugly, and why the -S
therein is an extra switch).
Luckily -dp still works as expected, so, ... well, I guess I'll live, and
if not there's "grep -v '^#.*:[0-9]\+:'" :)
Ciao,
Michael.