public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/57890] gcc 4.8.1 regression: loops become slower
[not found] <bug-57890-4@http.gcc.gnu.org/bugzilla/>
@ 2013-07-12 17:14 ` pinskia at gcc dot gnu.org
2013-07-13 16:39 ` [Bug tree-optimization/57890] " dushistov at mail dot ru
` (4 subsequent siblings)
5 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu.org @ 2013-07-12 17:14 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57890
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |missed-optimization
Component|c++ |target
Severity|major |normal
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
That would mean the expansion for memset is not optimal for the target which
means this is a target issue rather than a C++ front-end or a middle-end issue.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/57890] gcc 4.8.1 regression: loops become slower
[not found] <bug-57890-4@http.gcc.gnu.org/bugzilla/>
2013-07-12 17:14 ` [Bug target/57890] gcc 4.8.1 regression: loops become slower pinskia at gcc dot gnu.org
@ 2013-07-13 16:39 ` dushistov at mail dot ru
2013-07-14 19:46 ` dushistov at mail dot ru
` (3 subsequent siblings)
5 siblings, 0 replies; 6+ messages in thread
From: dushistov at mail dot ru @ 2013-07-13 16:39 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57890
Evgeniy Dushistov <dushistov at mail dot ru> changed:
What |Removed |Added
----------------------------------------------------------------------------
Component|target |tree-optimization
--- Comment #2 from Evgeniy Dushistov <dushistov at mail dot ru> ---
>That would mean the expansion for memset is not optimal for the target which >means this is a target issue rather than a C++ front-end or a middle-end issue.
I disagree. Bisect show that fault commit (Can anybody add him to CC?):
2012-06-05 Richard Guenther <rguenther@suse.de>
PR tree-optimization/53081
* tree-loop-distribution.c (generate_memset_builtin): Handle all
kinds of byte-sized stores.
(classify_partition): Likewise.
(tree_loop_distribution): Adjust seed statements used for
!flag_tree_loop_distribution.
* gcc.dg/tree-ssa/ldist-19.c: New testcase.
* gcc.c-torture/execute/builtins/builtins.exp: Always pass
-fno-tree-loop-distribute-patterns.
Yes, for builtin memset gcc generated bad code, and this a target issue.
But for gcc 4.7 the issue was known
(http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55953), that bultin memset bad for
at least arm, x86 and amd64 ( suppose major CPUs that gcc supports).
Why in gcc 4.8 introduce new code in tree optimization that produce more builin
memset, why not wait untill builtin memset will be fixed?
If look at gcc as the whole thing, this is regression: "+15% CPU time for
simple loop".
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/57890] gcc 4.8.1 regression: loops become slower
[not found] <bug-57890-4@http.gcc.gnu.org/bugzilla/>
2013-07-12 17:14 ` [Bug target/57890] gcc 4.8.1 regression: loops become slower pinskia at gcc dot gnu.org
2013-07-13 16:39 ` [Bug tree-optimization/57890] " dushistov at mail dot ru
@ 2013-07-14 19:46 ` dushistov at mail dot ru
2013-11-09 22:34 ` [Bug target/57890] " pinskia at gcc dot gnu.org
` (2 subsequent siblings)
5 siblings, 0 replies; 6+ messages in thread
From: dushistov at mail dot ru @ 2013-07-14 19:46 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57890
--- Comment #3 from Evgeniy Dushistov <dushistov at mail dot ru> ---
By the way, here is a short summary of running result of compilation test_loop
on my i7 based notebook (the best results):
icc(13.1.3 20130607): 0.228
gcc 4.7 : 0.345
gcc 4.8 : 0.4
clang (3.3) : 0.401
so gcc after 4.8 become as slow as clang
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug target/57890] gcc 4.8.1 regression: loops become slower
[not found] <bug-57890-4@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2013-07-14 19:46 ` dushistov at mail dot ru
@ 2013-11-09 22:34 ` pinskia at gcc dot gnu.org
2013-11-09 23:36 ` pinskia at gcc dot gnu.org
2021-06-08 21:37 ` pinskia at gcc dot gnu.org
5 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu.org @ 2013-11-09 22:34 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57890
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target| |x86_64-*-linux-gnu
Component|tree-optimization |target
--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
There have been some improvements of memset recently for x86_64. Also note on
many other targets doing this transformation is actually a speed up.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug target/57890] gcc 4.8.1 regression: loops become slower
[not found] <bug-57890-4@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2013-11-09 22:34 ` [Bug target/57890] " pinskia at gcc dot gnu.org
@ 2013-11-09 23:36 ` pinskia at gcc dot gnu.org
2021-06-08 21:37 ` pinskia at gcc dot gnu.org
5 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu.org @ 2013-11-09 23:36 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57890
--- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
*** Bug 55953 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug target/57890] gcc 4.8.1 regression: loops become slower
[not found] <bug-57890-4@http.gcc.gnu.org/bugzilla/>
` (4 preceding siblings ...)
2013-11-09 23:36 ` pinskia at gcc dot gnu.org
@ 2021-06-08 21:37 ` pinskia at gcc dot gnu.org
5 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-06-08 21:37 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57890
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |7.0
Resolution|--- |FIXED
Status|UNCONFIRMED |RESOLVED
Known to fail| |4.9.0, 6.1.0
Known to work| |4.7.0, 7.1.0
--- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Fixed in GCC 7.0:
f:
movdqa xmm0, XMMWORD PTR .LC0[rip]
mov DWORD PTR c[rip+96], 808464432
movaps XMMWORD PTR c[rip], xmm0
movaps XMMWORD PTR c[rip+16], xmm0
movaps XMMWORD PTR c[rip+32], xmm0
movaps XMMWORD PTR c[rip+48], xmm0
movaps XMMWORD PTR c[rip+64], xmm0
movaps XMMWORD PTR c[rip+80], xmm0
ret
.LC0:
.quad 3472328296227680304
.quad 3472328296227680304
Where GCC 4.7.0 had produced (which is just as ok):
f:
movdqa xmm0, XMMWORD PTR .LC0[rip]
mov BYTE PTR c[rip+96], 48
mov BYTE PTR c[rip+97], 48
movdqa XMMWORD PTR c[rip], xmm0
mov BYTE PTR c[rip+98], 48
mov BYTE PTR c[rip+99], 48
movdqa XMMWORD PTR c[rip+16], xmm0
movdqa XMMWORD PTR c[rip+32], xmm0
movdqa XMMWORD PTR c[rip+48], xmm0
movdqa XMMWORD PTR c[rip+64], xmm0
movdqa XMMWORD PTR c[rip+80], xmm0
ret
.LC0:
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
.byte 48
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2021-06-08 21:37 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <bug-57890-4@http.gcc.gnu.org/bugzilla/>
2013-07-12 17:14 ` [Bug target/57890] gcc 4.8.1 regression: loops become slower pinskia at gcc dot gnu.org
2013-07-13 16:39 ` [Bug tree-optimization/57890] " dushistov at mail dot ru
2013-07-14 19:46 ` dushistov at mail dot ru
2013-11-09 22:34 ` [Bug target/57890] " pinskia at gcc dot gnu.org
2013-11-09 23:36 ` pinskia at gcc dot gnu.org
2021-06-08 21:37 ` 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).