public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/52054] New: Value-numbering does not enter translated expressions into the hash table
@ 2012-01-30 14:43 rguenth at gcc dot gnu.org
2012-01-30 14:48 ` [Bug tree-optimization/52054] " rguenth at gcc dot gnu.org
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-01-30 14:43 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52054
Bug #: 52054
Summary: Value-numbering does not enter translated expressions
into the hash table
Classification: Unclassified
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Keywords: missed-optimization
Severity: normal
Priority: P3
Component: tree-optimization
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: rguenth@gcc.gnu.org
When VN comes across
foo (struct S * p)
{
struct S s;
int D.1715;
int D.1712;
int D.1711;
<bb 2>:
s = *p_2(D);
D.1711_3 = s.i;
D.1712_4 = p_2(D)->i;
if (D.1711_3 != D.1712_4)
it does not enter p_2(D)->i valued D.1711_3 into the hashtables when
visiting D.1711_3 = s.i but only s.i valued D.1711_3. It either should
insert both or the most translated expression (or even all the exprs
generated inbetween? All but the most translated expressions are
compile-time savers only).
This way it can value-number D.1711_3 and D.1712_4 the same.
struct S { int i; int j; };
int foo (struct S *p)
{
struct S s = *p;
if (s.i != p->i)
return 1;
return 0;
}
see gnat.dg/pack9.ads for an Ada testcase that fails this way w/o SRA.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/52054] Value-numbering does not enter translated expressions into the hash table
2012-01-30 14:43 [Bug tree-optimization/52054] New: Value-numbering does not enter translated expressions into the hash table rguenth at gcc dot gnu.org
@ 2012-01-30 14:48 ` rguenth at gcc dot gnu.org
2012-01-31 14:06 ` rguenth at gcc dot gnu.org
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-01-30 14:48 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52054
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |ASSIGNED
Last reconfirmed| |2012-01-30
AssignedTo|unassigned at gcc dot |rguenth at gcc dot gnu.org
|gnu.org |
Ever Confirmed|0 |1
--- Comment #1 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-01-30 14:36:22 UTC ---
Mine.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/52054] Value-numbering does not enter translated expressions into the hash table
2012-01-30 14:43 [Bug tree-optimization/52054] New: Value-numbering does not enter translated expressions into the hash table rguenth at gcc dot gnu.org
2012-01-30 14:48 ` [Bug tree-optimization/52054] " rguenth at gcc dot gnu.org
@ 2012-01-31 14:06 ` rguenth at gcc dot gnu.org
2012-05-11 9:41 ` rguenth at gcc dot gnu.org
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-01-31 14:06 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52054
--- Comment #2 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-01-31 13:26:56 UTC ---
Created attachment 26533
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=26533
patch
Prototype patch. Passes bootstrap but testing shows some regressions.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/52054] Value-numbering does not enter translated expressions into the hash table
2012-01-30 14:43 [Bug tree-optimization/52054] New: Value-numbering does not enter translated expressions into the hash table rguenth at gcc dot gnu.org
2012-01-30 14:48 ` [Bug tree-optimization/52054] " rguenth at gcc dot gnu.org
2012-01-31 14:06 ` rguenth at gcc dot gnu.org
@ 2012-05-11 9:41 ` rguenth at gcc dot gnu.org
2012-05-11 23:10 ` steven at gcc dot gnu.org
2012-05-12 12:07 ` rguenth at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-05-11 9:41 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52054
--- Comment #3 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-05-11 09:34:40 UTC ---
PR53125 has a testcase where we spend time in redundant store removal in
eliminate() which does vn_reference_lookup with VN_WALK (which it should not
need).
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/52054] Value-numbering does not enter translated expressions into the hash table
2012-01-30 14:43 [Bug tree-optimization/52054] New: Value-numbering does not enter translated expressions into the hash table rguenth at gcc dot gnu.org
` (2 preceding siblings ...)
2012-05-11 9:41 ` rguenth at gcc dot gnu.org
@ 2012-05-11 23:10 ` steven at gcc dot gnu.org
2012-05-12 12:07 ` rguenth at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: steven at gcc dot gnu.org @ 2012-05-11 23:10 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52054
Steven Bosscher <steven at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |steven at gcc dot gnu.org
--- Comment #4 from Steven Bosscher <steven at gcc dot gnu.org> 2012-05-11 23:08:15 UTC ---
(In reply to comment #3)
> PR53125 has a testcase where we spend time in redundant store removal in
> eliminate() which does vn_reference_lookup with VN_WALK (which it should not
> need).
The patch of comment #2 has no influence on the compile time for bug 53125. Is
that expected?
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug tree-optimization/52054] Value-numbering does not enter translated expressions into the hash table
2012-01-30 14:43 [Bug tree-optimization/52054] New: Value-numbering does not enter translated expressions into the hash table rguenth at gcc dot gnu.org
` (3 preceding siblings ...)
2012-05-11 23:10 ` steven at gcc dot gnu.org
@ 2012-05-12 12:07 ` rguenth at gcc dot gnu.org
4 siblings, 0 replies; 6+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-05-12 12:07 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52054
--- Comment #5 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-05-12 11:57:41 UTC ---
(In reply to comment #4)
> (In reply to comment #3)
> > PR53125 has a testcase where we spend time in redundant store removal in
> > eliminate() which does vn_reference_lookup with VN_WALK (which it should not
> > need).
>
> The patch of comment #2 has no influence on the compile time for bug 53125. Is
> that expected?
Yes. You need to change the vn_reference_lookup with VN_WALK in eliminate()
to VN_NOWALK, too (based on the fact that we'd have done that lookup at
value-numbering time already and entered the result, so walking would no longer
be necessary).
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2012-05-12 11:58 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-01-30 14:43 [Bug tree-optimization/52054] New: Value-numbering does not enter translated expressions into the hash table rguenth at gcc dot gnu.org
2012-01-30 14:48 ` [Bug tree-optimization/52054] " rguenth at gcc dot gnu.org
2012-01-31 14:06 ` rguenth at gcc dot gnu.org
2012-05-11 9:41 ` rguenth at gcc dot gnu.org
2012-05-11 23:10 ` steven at gcc dot gnu.org
2012-05-12 12:07 ` rguenth 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).