public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/59967] New: Performance regression from 4.7.x to 4.8.x (loop not unrolled)
@ 2014-01-28 13:12 chbreitkopf at gmail dot com
  2014-01-29 13:49 ` [Bug tree-optimization/59967] [4.8/4.9 Regression] " rguenth at gcc dot gnu.org
                   ` (17 more replies)
  0 siblings, 18 replies; 19+ messages in thread
From: chbreitkopf at gmail dot com @ 2014-01-28 13:12 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 59967
           Summary: Performance regression from 4.7.x to 4.8.x (loop not
                    unrolled)
           Product: gcc
           Version: 4.8.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: chbreitkopf at gmail dot com

Created attachment 31967
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=31967&action=edit
preprocessed source of ray/src/rt/ambient.c

gcc 4.8.x generates 10-15% slower code compared to 4.7.x for Mark Stock's
radiance benchmark (http://markjstock.org/pages/rad_bench.html).

I observed this regression on Linux x86_64, and with different CPUs (Ivy
Bridge, Haswell, AMD Phenom, Kaveri). I had suspected the new register
allocator, but the actual cause is a difference in loop unrolling.

The hotspot is the nested loops with the recursive call at the end of the
sumambient() function. When using -Ofast, gcc 4.7.x will unroll the outer loop,
which results in some optimization possibilities in the inner loop. gcc 4.8.x
does not unroll the outer loop. -funroll-loops does not change the behavior.


^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2024-03-11  6:18 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-01-28 13:12 [Bug c/59967] New: Performance regression from 4.7.x to 4.8.x (loop not unrolled) chbreitkopf at gmail dot com
2014-01-29 13:49 ` [Bug tree-optimization/59967] [4.8/4.9 Regression] " rguenth at gcc dot gnu.org
2014-04-02 23:17 ` hubicka at ucw dot cz
2014-04-03  6:18 ` chbreitkopf at gmail dot com
2014-05-22  9:01 ` [Bug tree-optimization/59967] [4.8/4.9/4.10 " rguenth at gcc dot gnu.org
2014-12-19 13:40 ` [Bug tree-optimization/59967] [4.8/4.9/5 " jakub at gcc dot gnu.org
2015-01-15 14:44 ` rguenth at gcc dot gnu.org
2015-01-15 14:44 ` rguenth at gcc dot gnu.org
2015-03-18 13:17 ` rguenth at gcc dot gnu.org
2015-06-23  8:23 ` [Bug tree-optimization/59967] [4.8/4.9/5/6 " rguenth at gcc dot gnu.org
2015-06-26 20:13 ` [Bug tree-optimization/59967] [4.9/5/6 " jakub at gcc dot gnu.org
2015-06-26 20:36 ` jakub at gcc dot gnu.org
2015-06-30 11:02 ` rguenth at gcc dot gnu.org
2021-05-14  9:47 ` [Bug tree-optimization/59967] [9/10/11/12 " jakub at gcc dot gnu.org
2021-06-01  8:06 ` rguenth at gcc dot gnu.org
2022-05-27  9:35 ` [Bug tree-optimization/59967] [10/11/12/13 " rguenth at gcc dot gnu.org
2022-06-28 10:30 ` jakub at gcc dot gnu.org
2023-07-07 10:30 ` [Bug tree-optimization/59967] [11/12/13/14 " rguenth at gcc dot gnu.org
2024-03-11  6:18 ` pinskia at gcc dot gnu.org

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).