public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
@ 2009-10-30 16:47 rguenth at gcc dot gnu dot org
2009-10-30 16:57 ` [Bug tree-optimization/41879] " rguenth at gcc dot gnu dot org
` (11 more replies)
0 siblings, 12 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-10-30 16:47 UTC (permalink / raw)
To: gcc-bugs
The fix for PR41783 causes us to vectorize RESID and PSINV where we only
predictive common the epilogue loop now. This causes mgrid score to drop
by almost 40% on x86_64 and the vectorized code is pretty bad because it
uses unaligned accesses.
--
Summary: [4.5 Regression] 172.mgrid regression, vectorizer
prevents predictive commoning
Product: gcc
Version: 4.5.0
Status: UNCONFIRMED
Keywords: missed-optimization
Severity: normal
Priority: P3
Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: rguenth at gcc dot gnu dot org
OtherBugsDependingO 41783
nThis:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
@ 2009-10-30 16:57 ` rguenth at gcc dot gnu dot org
2009-10-30 17:01 ` rguenth at gcc dot gnu dot org
` (10 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-10-30 16:57 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from rguenth at gcc dot gnu dot org 2009-10-30 16:57 -------
Testcase:
SUBROUTINE PSINV(R,U,C)
PARAMETER (N=64)
REAL*8 U(N,N,N),R(N,N,N),C(0:3)
INTEGER I3, I2, I1
C
DO 600 I3=2,N-1
DO 600 I2=2,N-1
DO 600 I1=2,N-1
600 U(I1,I2,I3)=U(I1,I2,I3)
> +C(0)*( R(I1, I2, I3 ) )
> +C(1)*( R(I1-1,I2, I3 ) + R(I1+1,I2, I3 )
> + R(I1, I2-1,I3 ) + R(I1, I2+1,I3 )
> + R(I1, I2, I3-1) + R(I1, I2, I3+1) )
> +C(2)*( R(I1-1,I2-1,I3 ) + R(I1+1,I2-1,I3 )
> + R(I1-1,I2+1,I3 ) + R(I1+1,I2+1,I3 )
> + R(I1, I2-1,I3-1) + R(I1, I2+1,I3-1)
> + R(I1, I2-1,I3+1) + R(I1, I2+1,I3+1)
> + R(I1-1,I2, I3-1) + R(I1-1,I2, I3+1)
> + R(I1+1,I2, I3-1) + R(I1+1,I2, I3+1) )
> +C(3)*( R(I1-1,I2-1,I3-1) + R(I1+1,I2-1,I3-1)
> + R(I1-1,I2+1,I3-1) + R(I1+1,I2+1,I3-1)
> + R(I1-1,I2-1,I3+1) + R(I1+1,I2-1,I3+1)
> + R(I1-1,I2+1,I3+1) + R(I1+1,I2+1,I3+1) )
C
RETURN
END
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |4.5.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
2009-10-30 16:57 ` [Bug tree-optimization/41879] " rguenth at gcc dot gnu dot org
@ 2009-10-30 17:01 ` rguenth at gcc dot gnu dot org
2009-11-09 13:03 ` rguenth at gcc dot gnu dot org
` (9 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-10-30 17:01 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from rguenth at gcc dot gnu dot org 2009-10-30 17:00 -------
With vectorization enabled I get
Running /home/richard/src/trunk/gcc/testsuite/gcc.dg/tree-ssa/tree-ssa.exp ...
FAIL: gcc.dg/tree-ssa/predcom-1.c scan-tree-dump-times pcom "looparound ref" 1
FAIL: gcc.dg/tree-ssa/predcom-4.c scan-tree-dump-times pcom "Combination" 1
FAIL: gcc.dg/tree-ssa/predcom-4.c scan-tree-dump-times pcom "Unrolling 3
times." 1
that is, all predictive commoning tests run with -O2 only...
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
2009-10-30 16:57 ` [Bug tree-optimization/41879] " rguenth at gcc dot gnu dot org
2009-10-30 17:01 ` rguenth at gcc dot gnu dot org
@ 2009-11-09 13:03 ` rguenth at gcc dot gnu dot org
2009-11-10 10:02 ` irar at il dot ibm dot com
` (8 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-11-09 13:03 UTC (permalink / raw)
To: gcc-bugs
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Priority|P3 |P2
Last reconfirmed|0000-00-00 00:00:00 |2009-11-09 13:03:36
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
` (2 preceding siblings ...)
2009-11-09 13:03 ` rguenth at gcc dot gnu dot org
@ 2009-11-10 10:02 ` irar at il dot ibm dot com
2009-11-11 20:38 ` rguenth at gcc dot gnu dot org
` (7 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: irar at il dot ibm dot com @ 2009-11-10 10:02 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from irar at il dot ibm dot com 2009-11-10 10:02 -------
(In reply to comment #0)
> This causes mgrid score to drop
> by almost 40% on x86_64 and the vectorized code is pretty bad because it
> uses unaligned accesses.
Is the vectorized code worse than the scalar one even without predcom?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
` (3 preceding siblings ...)
2009-11-10 10:02 ` irar at il dot ibm dot com
@ 2009-11-11 20:38 ` rguenth at gcc dot gnu dot org
2009-11-12 7:51 ` irar at il dot ibm dot com
` (6 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-11-11 20:38 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from rguenth at gcc dot gnu dot org 2009-11-11 20:38 -------
I didn't check yet. We'll work on a simple cost-model integration of
predcom.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
` (4 preceding siblings ...)
2009-11-11 20:38 ` rguenth at gcc dot gnu dot org
@ 2009-11-12 7:51 ` irar at il dot ibm dot com
2009-11-12 15:18 ` rguenth at gcc dot gnu dot org
` (5 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: irar at il dot ibm dot com @ 2009-11-12 7:51 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from irar at il dot ibm dot com 2009-11-12 07:51 -------
(In reply to comment #4)
> I didn't check yet. We'll work on a simple cost-model integration of
> predcom.
You mean, vectorizer cost model will take predcom into account?
If the vectorization is not profitable (vs. scalar without predcom), it can be
a matter of vectorizer cost model tuning (looks easier).
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
` (5 preceding siblings ...)
2009-11-12 7:51 ` irar at il dot ibm dot com
@ 2009-11-12 15:18 ` rguenth at gcc dot gnu dot org
2010-01-19 16:20 ` rguenth at gcc dot gnu dot org
` (4 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-11-12 15:18 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from rguenth at gcc dot gnu dot org 2009-11-12 15:17 -------
The idea is to call predcom analysis and hook it into the vectorizer as another
vectorization form for the cost model.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
` (6 preceding siblings ...)
2009-11-12 15:18 ` rguenth at gcc dot gnu dot org
@ 2010-01-19 16:20 ` rguenth at gcc dot gnu dot org
2010-01-20 11:42 ` rguenth at gcc dot gnu dot org
` (3 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-01-19 16:20 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from rguenth at gcc dot gnu dot org 2010-01-19 16:20 -------
Fixed by
Author: matz
Date: Tue Jan 19 16:05:57 2010
New Revision: 156043
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=156043
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
` (7 preceding siblings ...)
2010-01-19 16:20 ` rguenth at gcc dot gnu dot org
@ 2010-01-20 11:42 ` rguenth at gcc dot gnu dot org
2010-01-20 14:43 ` matz at gcc dot gnu dot org
` (2 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-01-20 11:42 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from rguenth at gcc dot gnu dot org 2010-01-20 11:42 -------
mgrid now miscompares on i?86 ...
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
` (8 preceding siblings ...)
2010-01-20 11:42 ` rguenth at gcc dot gnu dot org
@ 2010-01-20 14:43 ` matz at gcc dot gnu dot org
2010-01-20 15:25 ` steven at gcc dot gnu dot org
2010-01-20 15:32 ` rguenther at suse dot de
11 siblings, 0 replies; 13+ messages in thread
From: matz at gcc dot gnu dot org @ 2010-01-20 14:43 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from matz at gcc dot gnu dot org 2010-01-20 14:42 -------
See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35418#c8
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
` (9 preceding siblings ...)
2010-01-20 14:43 ` matz at gcc dot gnu dot org
@ 2010-01-20 15:25 ` steven at gcc dot gnu dot org
2010-01-20 15:32 ` rguenther at suse dot de
11 siblings, 0 replies; 13+ messages in thread
From: steven at gcc dot gnu dot org @ 2010-01-20 15:25 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from steven at gcc dot gnu dot org 2010-01-20 15:25 -------
Is there an alt.src for this from SPEC?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/41879] [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
` (10 preceding siblings ...)
2010-01-20 15:25 ` steven at gcc dot gnu dot org
@ 2010-01-20 15:32 ` rguenther at suse dot de
11 siblings, 0 replies; 13+ messages in thread
From: rguenther at suse dot de @ 2010-01-20 15:32 UTC (permalink / raw)
To: gcc-bugs
------- Comment #11 from rguenther at suse dot de 2010-01-20 15:31 -------
Subject: Re: [4.5 Regression] 172.mgrid
regression, vectorizer prevents predictive commoning
On Wed, 20 Jan 2010, steven at gcc dot gnu dot org wrote:
> ------- Comment #10 from steven at gcc dot gnu dot org 2010-01-20 15:25 -------
> Is there an alt.src for this from SPEC?
I don't think so - SPEC 2000 is no longer officially maintained.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41879
^ permalink raw reply [flat|nested] 13+ messages in thread
end of thread, other threads:[~2010-01-20 15:32 UTC | newest]
Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-10-30 16:47 [Bug tree-optimization/41879] New: [4.5 Regression] 172.mgrid regression, vectorizer prevents predictive commoning rguenth at gcc dot gnu dot org
2009-10-30 16:57 ` [Bug tree-optimization/41879] " rguenth at gcc dot gnu dot org
2009-10-30 17:01 ` rguenth at gcc dot gnu dot org
2009-11-09 13:03 ` rguenth at gcc dot gnu dot org
2009-11-10 10:02 ` irar at il dot ibm dot com
2009-11-11 20:38 ` rguenth at gcc dot gnu dot org
2009-11-12 7:51 ` irar at il dot ibm dot com
2009-11-12 15:18 ` rguenth at gcc dot gnu dot org
2010-01-19 16:20 ` rguenth at gcc dot gnu dot org
2010-01-20 11:42 ` rguenth at gcc dot gnu dot org
2010-01-20 14:43 ` matz at gcc dot gnu dot org
2010-01-20 15:25 ` steven at gcc dot gnu dot org
2010-01-20 15:32 ` rguenther at suse dot de
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).