public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug middle-end/18005] New: ICE in fold-const.c/fold
@ 2004-10-15 5:26 aj at gcc dot gnu dot org
2004-10-15 5:27 ` [Bug middle-end/18005] " aj at gcc dot gnu dot org
` (9 more replies)
0 siblings, 10 replies; 11+ messages in thread
From: aj at gcc dot gnu dot org @ 2004-10-15 5:26 UTC (permalink / raw)
To: gcc-bugs
I get now an ICE compiling glibc. The error is in 20041014 but also in
20041013 and has been introduced during the last 5 days or so (or glibc
has changed in a way to trigger this).
aj@gromit:/cvs/libc/stdlib> /opt/gcc/4.0-devel/libexec/gcc/x86_64-suse-linux-gnu/4.0.0/cc1-fpreprocessed
tst-random.i -quiet -dumpbase tst-random.c -mtune=k8
-auxbase-strip /builds/glibc/4.0/stdlib/tst-random.o -O2 -std=gnu99 -version
-o tst-random.s
GNU C version 4.0.0 20041014 (experimental) (x86_64-suse-linux-gnu)
compiled by GNU C version 4.0.0 20041014 (experimental).
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
tst-random.i: In function 'main':
tst-random.i:2738: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
Running under gdb shows:
(gdb) r -fpreprocessed tst-random.i -quiet -dumpbase tst-random.c -mtune=k8
-auxbase-strip/builds/glibc/4.0/stdlib/tst-random.o -O2 -std=gnu99 -version -o
tst-random.s
GNU C version 4.0.0 20041014 (experimental) (x86_64-suse-linux-gnu)
compiled by GNU C version 4.0.0 20041014 (experimental).
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
Program received signal SIGSEGV, Segmentation fault.
0x00000000005b1b94 in fold (expr=0x2a95b67a50)
at /cvs/gcc/gcc/fold-const.c:6051
6051 STRIP_NOPS (op);
(gdb) bt
#0 0x00000000005b1b94 in fold (expr=0x2a95b67a50)
at /cvs/gcc/gcc/fold-const.c:6051
#1 0x00000000005cb832 in extract_muldiv (t=Variable "t" is not available.
) at /cvs/gcc/gcc/fold-const.c:5313
#2 0x00000000005b4655 in fold (expr=0x2a95b67a00)
at /cvs/gcc/gcc/fold-const.c:7571
#3 0x00000000007bb9d6 in analyze_array_indexes (loop=0xb79850,
access_fns=0xb78268, ref=Variable "ref" is not available.
)
at /cvs/gcc/gcc/tree-data-ref.c:519
#4 0x00000000007becdd in analyze_array (stmt=0x2a95b01d20, ref=0x2a95afabd0,
is_read=0 '\0') at /cvs/gcc/gcc/tree-data-ref.c:596
#5 0x00000000007bf069 in find_data_references_in_loop (loop=0xb79710,
datarefs=0x7fbfffe860) at /cvs/gcc/gcc/tree-data-ref.c:2236
#6 0x00000000004d70b6 in estimate_numbers_of_iterations (loops=0xb56d00)
at /cvs/gcc/gcc/tree-ssa-loop-niter.c:1005
#7 0x00000000004d5615 in tree_ssa_loop_bounds ()
at /cvs/gcc/gcc/tree-ssa-loop.c:308
#8 0x000000000047ca9d in execute_pass_list (pass=0xa8be60)
at /cvs/gcc/gcc/tree-optimize.c:503
#9 0x000000000047cb29 in execute_pass_list (pass=0xa8c100)
at /cvs/gcc/gcc/tree-optimize.c:539
#10 0x000000000047cb29 in execute_pass_list (pass=0xa87540)
at /cvs/gcc/gcc/tree-optimize.c:539
#11 0x000000000047cd6f in tree_rest_of_compilation (fndecl=0x2a95aff380)
at /cvs/gcc/gcc/tree-optimize.c:633
#12 0x000000000041a10b in c_expand_body (fndecl=0x2a95aff380)
at /cvs/gcc/gcc/c-decl.c:6370
#13 0x00000000007ae32e in cgraph_expand_function (node=0x2a95b100e0)
at /cvs/gcc/gcc/cgraphunit.c:1046
#14 0x00000000007b1c14 in cgraph_optimize () at /cvs/gcc/gcc/cgraphunit.c:2728
#15 0x000000000075bb55 in toplev_main (argc=Variable "argc" is not available.
) at /cvs/gcc/gcc/toplev.c:999
#16 0x0000002a9568900d in __libc_start_main () from /lib64/tls/libc.so.6
#17 0x00000000004023ca in _start () at start.S:113
(gdb) p expr
$1 = 0x2a95b67a50
(gdb) pge
(bit_size_type) iD.3284_20 * 1
(gdb) p op
$2 = 0x2a95af53c0
(gdb) pt op
<nop_expr 0x2a95af53c0
type <integer_type 0x2a95896460 bit_size_type public unsigned sizetype TI
size <integer_cst 0x2a958a7150 constant invariant 128>
unit size <integer_cst 0x2a958a7180 constant invariant 16>
align 128 symtab 0 alias set -1 precision 68 min <integer_cst
0x2a958a7900 0> max <integer_cst 0x2a958a7930 0xfffffffffffffffff>>
readonly
arg 0 <ssa_name 0x2a95b26780 nothrow var <var_decl 0x2a95b021c0 i> def_stmt
<ssa_name 0x2a95b26730>
version 20 in-free-list>>
--
Summary: ICE in fold-const.c/fold
Product: gcc
Version: 4.0.0
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: middle-end
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: aj at gcc dot gnu dot org
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: x86_64-linux-gnu
GCC host triplet: x86_64-linux-gnu
GCC target triplet: x86_64-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug middle-end/18005] ICE in fold-const.c/fold
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
@ 2004-10-15 5:27 ` aj at gcc dot gnu dot org
2004-10-15 12:55 ` [Bug middle-end/18005] [4.0 Regression] " pinskia at gcc dot gnu dot org
` (8 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: aj at gcc dot gnu dot org @ 2004-10-15 5:27 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From aj at gcc dot gnu dot org 2004-10-15 05:27 -------
Created an attachment (id=7355)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=7355&action=view)
Preprocessed source file
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug middle-end/18005] [4.0 Regression] ICE in fold-const.c/fold
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
2004-10-15 5:27 ` [Bug middle-end/18005] " aj at gcc dot gnu dot org
@ 2004-10-15 12:55 ` pinskia at gcc dot gnu dot org
2004-10-15 13:26 ` pinskia at gcc dot gnu dot org
` (7 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-10-15 12:55 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-15 12:55 -------
The SSA_NAME lost its type (again).
--
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |ice-on-valid-code
Summary|ICE in fold-const.c/fold |[4.0 Regression] ICE in
| |fold-const.c/fold
Target Milestone|--- |4.0.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug middle-end/18005] [4.0 Regression] ICE in fold-const.c/fold
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
2004-10-15 5:27 ` [Bug middle-end/18005] " aj at gcc dot gnu dot org
2004-10-15 12:55 ` [Bug middle-end/18005] [4.0 Regression] " pinskia at gcc dot gnu dot org
@ 2004-10-15 13:26 ` pinskia at gcc dot gnu dot org
2004-10-16 15:37 ` [Bug middle-end/18005] [4.0 Regression] ICE with simple loop reichelt at gcc dot gnu dot org
` (6 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-10-15 13:26 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-15 13:25 -------
Confirmed, reduced to:
extern int printf (__const char *__restrict __format, ...);
const int nseq = 3;
const int nrnd = 50;
void fail () __attribute__ ((__noreturn__));
long random();
int
main (void)
{
long int rnd[3][nrnd];
char* state[nseq];
int s;
int i;
for (i = 0; i < nrnd; ++i)
for (s = 0; s < nseq; ++s)
if (rnd[s][i] != random ())
fail ();
return 0;
}
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |dberlin at gcc dot gnu dot
| |org, spop at gcc dot gnu dot
| |org
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2004-10-15 13:26:01
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug middle-end/18005] [4.0 Regression] ICE with simple loop
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
` (2 preceding siblings ...)
2004-10-15 13:26 ` pinskia at gcc dot gnu dot org
@ 2004-10-16 15:37 ` reichelt at gcc dot gnu dot org
2004-10-18 22:55 ` [Bug middle-end/18005] [4.0 Regression] ICE with simple loop with VLA pinskia at gcc dot gnu dot org
` (5 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2004-10-16 15:37 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From reichelt at gcc dot gnu dot org 2004-10-16 15:37 -------
Here's an even shorter example. Just compile with "-O".
============================================
const int n = 2;
void foo()
{
int a[1][n], i;
for (i=0; i<2; ++i)
if (a[0][i]) return;
}
============================================
Sebastian, the problem appeared with your patch
http://gcc.gnu.org/ml/gcc-cvs/2004-10/msg00852.html
Could you please have a look?
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |reichelt at gcc dot gnu dot
| |org
GCC build triplet|x86_64-linux-gnu |
GCC host triplet|x86_64-linux-gnu |
GCC target triplet|x86_64-linux-gnu |
Keywords| |monitored
Summary|[4.0 Regression] ICE in |[4.0 Regression] ICE with
|fold-const.c/fold |simple loop
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug middle-end/18005] [4.0 Regression] ICE with simple loop with VLA
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
` (3 preceding siblings ...)
2004-10-16 15:37 ` [Bug middle-end/18005] [4.0 Regression] ICE with simple loop reichelt at gcc dot gnu dot org
@ 2004-10-18 22:55 ` pinskia at gcc dot gnu dot org
2004-10-19 4:14 ` pinskia at gcc dot gnu dot org
` (4 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-10-18 22:55 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-18 22:55 -------
It really has nothing to do with that patch we are losing the TYPE_SIZE of the VLA, why?
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |rth at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug middle-end/18005] [4.0 Regression] ICE with simple loop with VLA
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
` (4 preceding siblings ...)
2004-10-18 22:55 ` [Bug middle-end/18005] [4.0 Regression] ICE with simple loop with VLA pinskia at gcc dot gnu dot org
@ 2004-10-19 4:14 ` pinskia at gcc dot gnu dot org
2004-10-19 10:03 ` sebastian dot pop at cri dot ensmp dot fr
` (3 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-10-19 4:14 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-19 04:14 -------
*** Bug 18052 has been marked as a duplicate of this bug. ***
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |phython at gcc dot gnu dot
| |org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug middle-end/18005] [4.0 Regression] ICE with simple loop with VLA
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
` (5 preceding siblings ...)
2004-10-19 4:14 ` pinskia at gcc dot gnu dot org
@ 2004-10-19 10:03 ` sebastian dot pop at cri dot ensmp dot fr
2004-10-31 17:37 ` phython at gcc dot gnu dot org
` (2 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: sebastian dot pop at cri dot ensmp dot fr @ 2004-10-19 10:03 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From sebastian dot pop at cri dot ensmp dot fr 2004-10-19 10:03 -------
Subject: Re: [4.0 Regression] ICE with simple loop with VLA
Patch is here:
http://gcc.gnu.org/ml/gcc-patches/2004-10/msg01592.html
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug middle-end/18005] [4.0 Regression] ICE with simple loop with VLA
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
` (6 preceding siblings ...)
2004-10-19 10:03 ` sebastian dot pop at cri dot ensmp dot fr
@ 2004-10-31 17:37 ` phython at gcc dot gnu dot org
2004-11-12 0:13 ` cvs-commit at gcc dot gnu dot org
2004-11-12 1:08 ` pinskia at gcc dot gnu dot org
9 siblings, 0 replies; 11+ messages in thread
From: phython at gcc dot gnu dot org @ 2004-10-31 17:37 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From phython at gcc dot gnu dot org 2004-10-31 17:37 -------
*** Bug 18253 has been marked as a duplicate of this bug. ***
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |atmosfear at users dot
| |sourceforge dot net
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug middle-end/18005] [4.0 Regression] ICE with simple loop with VLA
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
` (7 preceding siblings ...)
2004-10-31 17:37 ` phython at gcc dot gnu dot org
@ 2004-11-12 0:13 ` cvs-commit at gcc dot gnu dot org
2004-11-12 1:08 ` pinskia at gcc dot gnu dot org
9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-11-12 0:13 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2004-11-12 00:13 -------
Subject: Bug 18005
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: spop@gcc.gnu.org 2004-11-12 00:13:07
Modified files:
gcc : ChangeLog tree-data-ref.c
Log message:
* tree-data-ref.c (analyze_subscript_affine_affine): Correctly
compute the first overlapping iterations.
PR middle-end/18005
* tree-data-ref.c (estimate_niter_from_size_of_data): Ensure
that arguments of EXACT_DIV_EXPR are INTEGER_CST.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.6291&r2=2.6292
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/tree-data-ref.c.diff?cvsroot=gcc&r1=2.16&r2=2.17
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug middle-end/18005] [4.0 Regression] ICE with simple loop with VLA
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
` (8 preceding siblings ...)
2004-11-12 0:13 ` cvs-commit at gcc dot gnu dot org
@ 2004-11-12 1:08 ` pinskia at gcc dot gnu dot org
9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-11-12 1:08 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-11-12 01:08 -------
Fixed.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18005
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2004-11-12 1:08 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-10-15 5:26 [Bug middle-end/18005] New: ICE in fold-const.c/fold aj at gcc dot gnu dot org
2004-10-15 5:27 ` [Bug middle-end/18005] " aj at gcc dot gnu dot org
2004-10-15 12:55 ` [Bug middle-end/18005] [4.0 Regression] " pinskia at gcc dot gnu dot org
2004-10-15 13:26 ` pinskia at gcc dot gnu dot org
2004-10-16 15:37 ` [Bug middle-end/18005] [4.0 Regression] ICE with simple loop reichelt at gcc dot gnu dot org
2004-10-18 22:55 ` [Bug middle-end/18005] [4.0 Regression] ICE with simple loop with VLA pinskia at gcc dot gnu dot org
2004-10-19 4:14 ` pinskia at gcc dot gnu dot org
2004-10-19 10:03 ` sebastian dot pop at cri dot ensmp dot fr
2004-10-31 17:37 ` phython at gcc dot gnu dot org
2004-11-12 0:13 ` cvs-commit at gcc dot gnu dot org
2004-11-12 1:08 ` pinskia 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).