* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
@ 2011-08-24 16:15 ` vmakarov at redhat dot com
2011-08-24 18:10 ` hjl.tools at gmail dot com
` (10 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: vmakarov at redhat dot com @ 2011-08-24 16:15 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
Vladimir Makarov <vmakarov at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |vmakarov at redhat dot com
--- Comment #1 from Vladimir Makarov <vmakarov at redhat dot com> 2011-08-24 16:02:57 UTC ---
Yesterday I sent a patch
http://gcc.gnu.org/ml/gcc-patches/2011-08/msg01954.html which most probably
solved the problem.
Now I have code size 419 (gcc 4.6) vs 411 (gcc as of Aug 24) bytes for the
test.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
2011-08-24 16:15 ` [Bug target/50164] " vmakarov at redhat dot com
@ 2011-08-24 18:10 ` hjl.tools at gmail dot com
2011-08-25 9:36 ` enkovich.gnu at gmail dot com
` (9 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: hjl.tools at gmail dot com @ 2011-08-24 18:10 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
H.J. Lu <hjl.tools at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |4.7.0
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
2011-08-24 16:15 ` [Bug target/50164] " vmakarov at redhat dot com
2011-08-24 18:10 ` hjl.tools at gmail dot com
@ 2011-08-25 9:36 ` enkovich.gnu at gmail dot com
2011-08-25 14:28 ` hjl.tools at gmail dot com
` (8 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: enkovich.gnu at gmail dot com @ 2011-08-25 9:36 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
--- Comment #2 from Ilya Enkovich <enkovich.gnu at gmail dot com> 2011-08-25 09:31:29 UTC ---
(In reply to comment #1)
> Yesterday I sent a patch
> http://gcc.gnu.org/ml/gcc-patches/2011-08/msg01954.html which most probably
> solved the problem.
>
> Now I have code size 419 (gcc 4.6) vs 411 (gcc as of Aug 24) bytes for the
> test.
I tried it but unfortunately it did not solve the regression. We still have xk
on the stack and x1.5 more memory accesses in GCC 4.7 assembly for mentioned
code part. GCC 4.6 produces bigger but faster code.
Problem somehow appears only when -march=atom is used. There is no degradation
if generic arch is used. I compared GCC 4.7 dumps for "-O2 -m32" and "-O2 -m32
-march=atom" and found that RTLs are same before IRA and differ after IRA.
How does -march=atom affects register allocation?
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
` (2 preceding siblings ...)
2011-08-25 9:36 ` enkovich.gnu at gmail dot com
@ 2011-08-25 14:28 ` hjl.tools at gmail dot com
2011-08-26 21:30 ` hjl.tools at gmail dot com
` (7 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: hjl.tools at gmail dot com @ 2011-08-25 14:28 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
--- Comment #3 from H.J. Lu <hjl.tools at gmail dot com> 2011-08-25 13:58:28 UTC ---
(In reply to comment #2)
> (In reply to comment #1)
> > Yesterday I sent a patch
> > http://gcc.gnu.org/ml/gcc-patches/2011-08/msg01954.html which most probably
> > solved the problem.
> >
> > Now I have code size 419 (gcc 4.6) vs 411 (gcc as of Aug 24) bytes for the
> > test.
>
> I tried it but unfortunately it did not solve the regression. We still have xk
> on the stack and x1.5 more memory accesses in GCC 4.7 assembly for mentioned
> code part. GCC 4.6 produces bigger but faster code.
>
Can you find which checkin caused this?
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
` (3 preceding siblings ...)
2011-08-25 14:28 ` hjl.tools at gmail dot com
@ 2011-08-26 21:30 ` hjl.tools at gmail dot com
2011-08-29 7:30 ` enkovich.gnu at gmail dot com
` (6 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: hjl.tools at gmail dot com @ 2011-08-26 21:30 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
H.J. Lu <hjl.tools at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |WAITING
Last reconfirmed| |2011-08-26
Ever Confirmed|0 |1
--- Comment #4 from H.J. Lu <hjl.tools at gmail dot com> 2011-08-26 21:10:07 UTC ---
On Atom with -m32 -O2 -march=atom,
1. GCC 4.6.1:
./4.6 64.16s user 0.01s system 99% cpu 1:04.18 total
2. GCC 4.7.0 20110819:
./0819 69.73s user 0.01s system 99% cpu 1:09.76 total
3. GCC 4.7.0 20110826:
./0826 64.30s user 0.02s system 99% cpu 1:04.33 total
Has this problem been fixed?
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
` (4 preceding siblings ...)
2011-08-26 21:30 ` hjl.tools at gmail dot com
@ 2011-08-29 7:30 ` enkovich.gnu at gmail dot com
2011-08-29 8:04 ` enkovich.gnu at gmail dot com
` (5 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: enkovich.gnu at gmail dot com @ 2011-08-29 7:30 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
Ilya Enkovich <enkovich.gnu at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |RESOLVED
Resolution| |FIXED
--- Comment #5 from Ilya Enkovich <enkovich.gnu at gmail dot com> 2011-08-29 07:01:38 UTC ---
(In reply to comment #4)
> On Atom with -m32 -O2 -march=atom,
>
> 1. GCC 4.6.1:
>
> ./4.6 64.16s user 0.01s system 99% cpu 1:04.18 total
>
> 2. GCC 4.7.0 20110819:
>
> ./0819 69.73s user 0.01s system 99% cpu 1:09.76 total
>
> 3. GCC 4.7.0 20110826:
>
> ./0826 64.30s user 0.02s system 99% cpu 1:04.33 total
>
> Has this problem been fixed?
Confirm. Problem has gone.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
` (5 preceding siblings ...)
2011-08-29 7:30 ` enkovich.gnu at gmail dot com
@ 2011-08-29 8:04 ` enkovich.gnu at gmail dot com
2011-08-30 10:52 ` enkovich.gnu at gmail dot com
` (4 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: enkovich.gnu at gmail dot com @ 2011-08-29 8:04 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
Ilya Enkovich <enkovich.gnu at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|FIXED |
--- Comment #6 from Ilya Enkovich <enkovich.gnu at gmail dot com> 2011-08-29 07:39:09 UTC ---
It appeared problem was fixed in reproducer but was not fixed in original test
case. I'll prepare fixed reproducer.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
` (6 preceding siblings ...)
2011-08-29 8:04 ` enkovich.gnu at gmail dot com
@ 2011-08-30 10:52 ` enkovich.gnu at gmail dot com
2011-08-30 11:30 ` enkovich.gnu at gmail dot com
` (3 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: enkovich.gnu at gmail dot com @ 2011-08-30 10:52 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
Ilya Enkovich <enkovich.gnu at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #25083|0 |1
is obsolete| |
--- Comment #7 from Ilya Enkovich <enkovich.gnu at gmail dot com> 2011-08-30 10:40:50 UTC ---
Created attachment 25138
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=25138
Fixed reproducer
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
` (7 preceding siblings ...)
2011-08-30 10:52 ` enkovich.gnu at gmail dot com
@ 2011-08-30 11:30 ` enkovich.gnu at gmail dot com
2011-10-27 10:04 ` rguenth at gcc dot gnu.org
` (2 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: enkovich.gnu at gmail dot com @ 2011-08-30 11:30 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
--- Comment #8 from Ilya Enkovich <enkovich.gnu at gmail dot com> 2011-08-30 10:50:44 UTC ---
I attached a fixed reproducer. It is closer to the original test and has higher
registers pressure then the previous version. It has the same problem as the
first reproducer.
Reproduced with GCC 4.7.0 20110828 and options "-O2 -m32 -march=atom". Code
becomes faster on both Atom (~10%) and Core (~35%) if I use just "-O2 -m32".
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
` (8 preceding siblings ...)
2011-08-30 11:30 ` enkovich.gnu at gmail dot com
@ 2011-10-27 10:04 ` rguenth at gcc dot gnu.org
2011-10-27 20:29 ` izamyatin at gmail dot com
2011-10-28 10:11 ` enkovich.gnu at gmail dot com
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu.org @ 2011-10-27 10:04 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P1
--- Comment #9 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-10-27 10:01:44 UTC ---
Still needs a proper analysis I suppose.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
` (9 preceding siblings ...)
2011-10-27 10:04 ` rguenth at gcc dot gnu.org
@ 2011-10-27 20:29 ` izamyatin at gmail dot com
2011-10-28 10:11 ` enkovich.gnu at gmail dot com
11 siblings, 0 replies; 13+ messages in thread
From: izamyatin at gmail dot com @ 2011-10-27 20:29 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
Igor Zamyatin <izamyatin at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |izamyatin at gmail dot com
--- Comment #10 from Igor Zamyatin <izamyatin at gmail dot com> 2011-10-27 20:28:47 UTC ---
I see that currently code for reproducer looks good. Surprisingly it happened
after revision 179275 (fix for PR 43864) which seems to be irrelevant here. And
indeed I have another test that shows a problem apparently in IRA or somewhere
near it.
This new problem actually is not about regression so I suggest to close this
tracker and I will open another one once I prepare good test case.
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/50164] [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count
2011-08-23 14:39 [Bug target/50164] New: [IRA, 4.7 Regression] Performance degradation due to increased memory instructions count enkovich.gnu at gmail dot com
` (10 preceding siblings ...)
2011-10-27 20:29 ` izamyatin at gmail dot com
@ 2011-10-28 10:11 ` enkovich.gnu at gmail dot com
11 siblings, 0 replies; 13+ messages in thread
From: enkovich.gnu at gmail dot com @ 2011-10-28 10:11 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50164
Ilya Enkovich <enkovich.gnu at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |RESOLVED
Resolution| |FIXED
--- Comment #11 from Ilya Enkovich <enkovich.gnu at gmail dot com> 2011-10-28 10:10:42 UTC ---
Initially problem was caused by movzbl cost value for Atom. Low cost of movzbl
made IRA keep frequently used byte value on the stack and assign register for
int value. Change cost model resolves the problem and it has been fixed in
revision 179999.
^ permalink raw reply [flat|nested] 13+ messages in thread