* Question about -fopt-info output (-fopt-info vs. -fopt-info-all)
@ 2017-05-02 21:40 Steve Ellcey
2017-05-03 9:51 ` Richard Biener
0 siblings, 1 reply; 2+ messages in thread
From: Steve Ellcey @ 2017-05-02 21:40 UTC (permalink / raw)
To: gcc
I have a question about -fopt-info. According to the GCC documentation at:
https://gcc.gnu.org/onlinedocs/gccint/Dump-examples.html
| If options is omitted, it defaults to all-all, which means dump all
| available optimization info from all the passes. In the following example,
| all optimization info is output on to stderr.
|
| gcc -O3 -fopt-info
But when I use the '-fopt-info' flag, I get less output about vectorization
than when I use '-fopt-info-all' or '-fopt-info-all-all'.
For example if I compile:
int foo(int *a, int *b, int *c, int n) {
int i;
for (i = 0; i < n; i++)
a[i] = b[i] + c[i];
}
with '-O3 -fopt-info' I get 6 lines of output. '-O3 -fopt-info-all'
or '-O3 -fopt-info-all-all' gives me 453 lines of output.
Is the documentation wrong, the implementation wrong, or my understanding
of what the documentation is saying wrong?
Steve Ellcey
sellcey@cavium.com
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Question about -fopt-info output (-fopt-info vs. -fopt-info-all)
2017-05-02 21:40 Question about -fopt-info output (-fopt-info vs. -fopt-info-all) Steve Ellcey
@ 2017-05-03 9:51 ` Richard Biener
0 siblings, 0 replies; 2+ messages in thread
From: Richard Biener @ 2017-05-03 9:51 UTC (permalink / raw)
To: sellcey; +Cc: GCC Development
On Tue, May 2, 2017 at 11:40 PM, Steve Ellcey <sellcey@cavium.com> wrote:
> I have a question about -fopt-info. According to the GCC documentation at:
>
> https://gcc.gnu.org/onlinedocs/gccint/Dump-examples.html
>
>
> | If options is omitted, it defaults to all-all, which means dump all
> | available optimization info from all the passes. In the following example,
> | all optimization info is output on to stderr.
> |
> | gcc -O3 -fopt-info
>
> But when I use the '-fopt-info' flag, I get less output about vectorization
> than when I use '-fopt-info-all' or '-fopt-info-all-all'.
>
> For example if I compile:
>
> int foo(int *a, int *b, int *c, int n) {
> int i;
> for (i = 0; i < n; i++)
> a[i] = b[i] + c[i];
> }
>
> with '-O3 -fopt-info' I get 6 lines of output. '-O3 -fopt-info-all'
> or '-O3 -fopt-info-all-all' gives me 453 lines of output.
>
> Is the documentation wrong, the implementation wrong, or my understanding
> of what the documentation is saying wrong?
I think this was discussed elsewhere and the documentation does not match
the implementation. I think the behavior is to print optimized locations only
but for all passes (which I believe is ok)
Richard.
> Steve Ellcey
> sellcey@cavium.com
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-05-03 9:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-02 21:40 Question about -fopt-info output (-fopt-info vs. -fopt-info-all) Steve Ellcey
2017-05-03 9:51 ` Richard Biener
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).