This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/40873] -fwhole-file -fwhole-program: Wrong decls cause too much to be optimized away



------- Comment #5 from dominiq at lps dot ens dot fr  2010-05-15 19:53 -------
A few comments:

(1) adding -flto or -fwhopr solves the linking problem for the polyhedron tests
and the reduced one in comment #1.

(2) the test in comment #4 is different as it shows up for -fwhole-file and is
not solved with -flto or -fwhopr.

(3) I have been puzzled by the results in
http://users.physik.fu-berlin.de/~tburnus/gcc-trunk/benchmark/ for fatigue.f90.
It is due to -fwhole-program:

[macbook] lin/test% gfc -O3 -ffast-math -fwhole-file -flto fatigue.f90
[macbook] lin/test% time a.out
...
9.223u 0.004s 0:09.23 99.8%     0+0k 0+0io 0pf+0w
[macbook] lin/test% gfc -O3 -ffast-math -fwhole-program fatigue.f90
[macbook] lin/test% time a.out
...
6.482u 0.004s 0:06.49 99.8%     0+0k 0+0io 0pf+0w

It would be interesting to understand why and to keep this nice speed up when
fixing this pr.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40873


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]