public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/34334] New: [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118
@ 2007-12-04 12:39 rguenth at gcc dot gnu dot org
2007-12-04 12:48 ` [Bug tree-optimization/34334] " rguenth at gcc dot gnu dot org
` (5 more replies)
0 siblings, 6 replies; 7+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2007-12-04 12:39 UTC (permalink / raw)
To: gcc-bugs
With a x86_64 -> ppc64 cross:
./cc1 ~/export/config_file.1.min.i -O2 -o /dev/null -m32 -quiet
/suse/rguenther/export/config_file.1.min.i:16: warning: unnamed struct/union
that defines no instances
/suse/rguenther/export/config_file.1.min.i:16: warning: 'struct stat64'
declared inside parameter list
/suse/rguenther/export/config_file.1.min.i:16: warning: its scope is only this
definition or declaration, which is probably not what you want
/suse/rguenther/export/config_file.1.min.i:17: warning: 'struct stat64'
declared inside parameter list
/suse/rguenther/export/config_file.1.min.i:33: warning: '__transparent_union__'
attribute ignored
/suse/rguenther/export/config_file.1.min.i:103: warning: 'struct addrinfo'
declared inside parameter list
/suse/rguenther/export/config_file.1.min.i: In function
'gftp_config_parse_args':
/suse/rguenther/export/config_file.1.min.i:166: internal compiler error: tree
check: expected ssa_name, have symbol_memory_tag in vuses_compare, at
tree-vn.c:118
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
also ICEs on native ppc.
--
Summary: [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P3
Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: rguenth at gcc dot gnu dot org
GCC target triplet: powerpc-*-*
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34334
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/34334] [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118
2007-12-04 12:39 [Bug tree-optimization/34334] New: [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118 rguenth at gcc dot gnu dot org
@ 2007-12-04 12:48 ` rguenth at gcc dot gnu dot org
2007-12-04 13:15 ` rguenth at gcc dot gnu dot org
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2007-12-04 12:48 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from rguenth at gcc dot gnu dot org 2007-12-04 12:48 -------
Created an attachment (id=14696)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14696&action=view)
reduced testcase
Appearantly the ICE is dependent on UIDs as if you remove an unused type decl
the
ICE disappears.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34334
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/34334] [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118
2007-12-04 12:39 [Bug tree-optimization/34334] New: [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118 rguenth at gcc dot gnu dot org
2007-12-04 12:48 ` [Bug tree-optimization/34334] " rguenth at gcc dot gnu dot org
@ 2007-12-04 13:15 ` rguenth at gcc dot gnu dot org
2007-12-04 14:03 ` rguenth at gcc dot gnu dot org
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2007-12-04 13:15 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from rguenth at gcc dot gnu dot org 2007-12-04 13:15 -------
The difference if I remove the gftp_transfer typedef from the dump after
critical edge splitting is (good vs. bad):
- D.1477_21 = 0B;
- *0B ={v} 0;
+ # VUSE <SMT.32_54, SMT.33_40>
+ D.1481_21 = *dest_19;
+ # SMT.32_41 = VDEF <SMT.32_54>
+ # SMT.33_42 = VDEF <SMT.33_40>
+ *D.1481_21 = 0;
The first real difference is after may_alias recomputation after SRA,
where despite same constraints the points-to solution for dest_1 is
different:
-dest_1, name memory tag: NMT.35, is dereferenced, points-to vars: { SMT.32 }
+dest_1, name memory tag: NMT.35, is dereferenced, points-to vars: { SMT.32
SMT.33 }
The IL shows this in
<bb 8>:
- # SMT.32_48 = PHI <SMT.32_54(3), SMT.32_44(7)>
# argp$0$gpr_30 = PHI <argp$0$gpr_27(3), argp$0$gpr_28(7)>
# argp$0$overflow_arg_area_24 = PHI <argp$0$overflow_arg_area_2(3),
argp$0$overflow_arg_area_4(7)>
- # SMT.33_29 = PHI <SMT.33_55(3), SMT.33_55(7)>
+ # SMT.33_29 = PHI <SMT.33_55(3), SMT.33_40(7)>
# SFT.25_26 = PHI <SFT.25_53(3), SFT.25_25(7)>
# SFT.22_23 = PHI <SFT.22_52(3), SFT.22_22(7)>
# dest_1 = PHI <dest_50(3), dest_19(7)>
numargs_20 = numargs_51 + -1;
- # VUSE <SMT.32_48>
- D.1477_21 = *dest_1;
- # SMT.32_41 = VDEF <SMT.32_48>
+ # VUSE <SMT.32_54, SMT.33_29>
+ D.1481_21 = *dest_1;
+ # SMT.32_41 = VDEF <SMT.32_54>
# SMT.33_42 = VDEF <SMT.33_29>
- *D.1477_21 = 0;
+ *D.1481_21 = 0;
and finally store_ccp in one case optimizes this to
@@ -79,11 +93,8 @@
# SMT.32_44 = VDEF <SMT.32_54>
*dest_19 = 0B;
numargs_20 = numargs_51 + -1;
- # VUSE <SMT.32_44>
- D.1477_21 = *dest_19;
- # SMT.32_41 = VDEF <SMT.32_44>
- # SMT.33_42 = VDEF <SMT.33_55>
- *D.1477_21 = 0;
+ D.1477_21 = 0B;
+ *0B ={v} 0;
if (numargs_20 > 0)
goto <bb 3>;
else
which avoids the ICE in SCCVN which looks like:
#2 0x0000000000abf95e in vuses_compare (pa=0x2ba6ff3a3ba8, pb=0x2ba6ff3a3bb0)
at /space/rguenther/src/svn/trunk/gcc/tree-vn.c:118
118 int sn = SSA_NAME_VERSION (vusea) - SSA_NAME_VERSION (vuseb);
(gdb) print vusea
$1 = (const tree) 0x2ba6ff392e10
(gdb) call debug_generic_expr (vusea)
SMT.32
(gdb) call debug_generic_expr (vuseb)
SMT.33_40
that is, one VUSE isn't in SSA form - but was inserted by PRE:
(gdb) call debug_generic_expr (stmt)
# VUSE <SMT.32, SMT.33_40> { SMT.32 SMT.33 }
storetmp.46_60 = *dest_19
I suppose for some reason virtual operand pruning isn't doing the same
for the inserted stmt as for the original stmt where the operands were
copied from. Indeed, we have the appearant mismatch here (crited):
# SMT.33_40 = VDEF <SMT.33_55>
*dest_19 = 0B;
..
# VUSE <SMT.32_54, SMT.33_40>
D.1481_21 = *dest_19;
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |alias
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34334
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/34334] [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118
2007-12-04 12:39 [Bug tree-optimization/34334] New: [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118 rguenth at gcc dot gnu dot org
2007-12-04 12:48 ` [Bug tree-optimization/34334] " rguenth at gcc dot gnu dot org
2007-12-04 13:15 ` rguenth at gcc dot gnu dot org
@ 2007-12-04 14:03 ` rguenth at gcc dot gnu dot org
2007-12-04 14:45 ` [Bug middle-end/34334] " rguenth at gcc dot gnu dot org
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2007-12-04 14:03 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from rguenth at gcc dot gnu dot org 2007-12-04 14:03 -------
The issue is that the loaded_syms bitmap doesn't agree with the VUSEs:
(gdb) call debug_generic_expr (stmt)
# VUSE <SMT.33_40> { SMT.32 SMT.33 }
storetmp.46_60 = *dest_19
as in create_ssa_artificial_load_stmt we make sure to kill build_vuses, but
not to clear the build_loads bitmap. With that fixed we generate
# VUSE <SMT.33_40> { SMT.33 }
storetmp.46_60 = *dest_19
which looks better, but later still ICEs, because the operand scanner
re-inserts the load of SMT.32.
So one could argue that for the original statement where we copy the
virtual operands from
# SMT.33_40 = VDEF <SMT.33_55> { SMT.33 }
*dest_19 = 0B
that this is missing a VDEF of SMT.32 (the alias sets of both SMT.32 and
*dest_19 are 3).
Note also that even during the first may_alias pass(!) we do not have
flow-sensitive information for dest_19:
NOTE: no flow-sensitive alias info for dest_19 in *dest_19 = 0B;
that is, we only use a fallback SMT here. And the failure mode is exactly
as I have predicted - we add the aliases of SMT.32 (SMT.33), but not SMT.32
itself!
Mine.
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |rguenth at gcc dot gnu dot
|dot org |org
Status|UNCONFIRMED |ASSIGNED
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2007-12-04 14:03:39
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34334
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug middle-end/34334] [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118
2007-12-04 12:39 [Bug tree-optimization/34334] New: [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118 rguenth at gcc dot gnu dot org
` (2 preceding siblings ...)
2007-12-04 14:03 ` rguenth at gcc dot gnu dot org
@ 2007-12-04 14:45 ` rguenth at gcc dot gnu dot org
2007-12-04 17:21 ` rguenth at gcc dot gnu dot org
2007-12-04 17:22 ` rguenth at gcc dot gnu dot org
5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2007-12-04 14:45 UTC (permalink / raw)
To: gcc-bugs
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Component|tree-optimization |middle-end
Target Milestone|--- |4.3.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34334
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug middle-end/34334] [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118
2007-12-04 12:39 [Bug tree-optimization/34334] New: [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118 rguenth at gcc dot gnu dot org
` (3 preceding siblings ...)
2007-12-04 14:45 ` [Bug middle-end/34334] " rguenth at gcc dot gnu dot org
@ 2007-12-04 17:21 ` rguenth at gcc dot gnu dot org
2007-12-04 17:22 ` rguenth at gcc dot gnu dot org
5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2007-12-04 17:21 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from rguenth at gcc dot gnu dot org 2007-12-04 17:20 -------
Subject: Bug 34334
Author: rguenth
Date: Tue Dec 4 17:20:34 2007
New Revision: 130602
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=130602
Log:
2007-12-04 Richard Guenther <rguenther@suse.de>
PR middle-end/34334
PR middle-end/34222
* tree-ssa-operands.c (get_addr_dereference_operands): If we
fall back to using the SMTs aliases, make sure to add virtual
operands for the SMT itself.
(create_ssa_artificial_load_stmt): Fix typo. Make sure to also
clear the loaded and stored symbols bitmaps.
* gcc.c-torture/compile/pr34334.c: New testcase.
* g++.dg/torture/pr34222.C: New testcase.
Added:
trunk/gcc/testsuite/g++.dg/torture/pr34222.C
trunk/gcc/testsuite/gcc.c-torture/compile/pr34334.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-ssa-operands.c
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34334
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug middle-end/34334] [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118
2007-12-04 12:39 [Bug tree-optimization/34334] New: [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118 rguenth at gcc dot gnu dot org
` (4 preceding siblings ...)
2007-12-04 17:21 ` rguenth at gcc dot gnu dot org
@ 2007-12-04 17:22 ` rguenth at gcc dot gnu dot org
5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2007-12-04 17:22 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from rguenth at gcc dot gnu dot org 2007-12-04 17:21 -------
Fixed.
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34334
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2007-12-04 17:22 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-12-04 12:39 [Bug tree-optimization/34334] New: [4.3 Regression] ICE in vuses_compare, at tree-vn.c:118 rguenth at gcc dot gnu dot org
2007-12-04 12:48 ` [Bug tree-optimization/34334] " rguenth at gcc dot gnu dot org
2007-12-04 13:15 ` rguenth at gcc dot gnu dot org
2007-12-04 14:03 ` rguenth at gcc dot gnu dot org
2007-12-04 14:45 ` [Bug middle-end/34334] " rguenth at gcc dot gnu dot org
2007-12-04 17:21 ` rguenth at gcc dot gnu dot org
2007-12-04 17:22 ` rguenth at gcc dot gnu dot 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).