public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug other/28230] New: ICE during profiled bootstrap.
@ 2006-07-03 8:40 pluto at agmk dot net
2006-07-03 11:25 ` [Bug other/28230] " pluto at agmk dot net
` (20 more replies)
0 siblings, 21 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-07-03 8:40 UTC (permalink / raw)
To: gcc-bugs
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 3188 bytes --]
/home/users/pluto/rpm/BUILD/trunk/builddir/./gcc/xgcc
-B/home/users/pluto/rpm/BUILD/trunk/builddir/./gcc/
-B/usr/x86_64-pld-linux/bin/ -B/usr/x86_64-pld-linux/lib/
-isystem /usr/x86_64-pld-linux/include
-isystem /usr/x86_64-pld-linux/sys-include
-O2 -O2 -O2 -fno-strict-aliasing -fwrapv -march=x86-64 -pipe
-DIN_GCC -W -Wall -Wwrite-strings -Wstrict-prototypes
-Wmissing-prototypes -Wold-style-definition -isystem ./include
-I. -I. -I../../gcc -I../../gcc/. -I../../gcc/../include
-I../../gcc/../libcpp/include -I../../gcc/../libdecnumber
-I../libdecnumber -g0 -finhibit-size-directive -fno-inline-functions
-fno-exceptions -fno-zero-initialized-in-bss -fno-toplevel-reorder
-fno-omit-frame-pointer -fno-asynchronous-unwind-tables
-c ../../gcc/crtstuff.c -DCRT_BEGIN -o crtbegin.o
../../gcc/crtstuff.c:1: internal compiler error: Segmentation fault
(gdb) set args -fpreprocessed crtstuff.i -quiet -dumpbase crtstuff.i
-mtune=generic -auxbase crtstuff -version -o /tmp/ccenndGf.s
(gdb) r
Starting program: /home/users/pluto/rpm/BUILD/trunk/builddir/gcc/cc1
-fpreprocessed crtstuff.i -quiet -dumpbase crtstuff.i -mtune=generic -auxbase
crtstuff -version -o /tmp/ccenndGf.s
GNU C version 4.2.0 20060702 (experimental) (PLD-Linux) (x86_64-pld-linux)
compiled by GNU C version 4.2.0 20060702 (experimental) (PLD-Linux).
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
Program received signal SIGSEGV, Segmentation fault.
0x000000000091cf26 in lshift_significand ()
(gdb) bt
#0 0x000000000091cf26 in lshift_significand ()
#1 0x000000000091fbb4 in normalize ()
#2 0x0000000000921b6c in real_from_integer ()
#3 0x000000000067f18f in init_emit_once ()
#4 0x000000000098f289 in toplev_main ()
#5 0x00000000004a0c91 in main ()
$ ./xgcc -v
Reading specs from /usr/lib64/gcc/x86_64-pld-linux/4.2.0/specs
Target: x86_64-pld-linux
Configured with: ../configure --prefix=/usr
--with-local-prefix=/usr/local
--libdir=/usr/lib64 --libexecdir=/usr/lib64
--infodir=/usr/share/info --mandir=/usr/share/man
--x-libraries=/usr/lib64 --enable-shared
--enable-threads=posix --enable-languages=c,c++,fortran,objc,obj-c++,java
--enable-c99 --enable-long-long --enable-multilib --enable-nls
--disable-werror --with-gnu-as --with-gnu-ld --with-demangler-in-ld
--with-system-zlib --with-slibdir=/lib64 --without-system-libunwind
--enable-cmath --with-long-double-128
--with-gxx-include-dir=/usr/include/c++/4.2.0 --disable-libstdcxx-pch
--enable-__cxa_atexit --enable-libstdcxx-allocator=new
--disable-libjava-multilib --enable-libgcj --enable-libgcj-multifile
--enable-libgcj-database --enable-gtk-cairo --enable-java-awt=qt,gtk,xlib
--enable-jni --enable-xmlj --enable-alsa --enable-dssi --enable-bootstrap
x86_64-pld-linux
Thread model: posix
gcc version 4.2.0 20060702 (experimental) (PLD-Linux)
--
Summary: ICE during profiled bootstrap.
Product: gcc
Version: 4.2.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: other
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pluto at agmk dot net
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug other/28230] ICE during profiled bootstrap.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
@ 2006-07-03 11:25 ` pluto at agmk dot net
2006-07-04 21:16 ` pluto at agmk dot net
` (19 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-07-03 11:25 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from pluto at agmk dot net 2006-07-03 11:24 -------
without profiling boostrap fails too.
Program received signal SIGSEGV, Segmentation fault.
0x000000000074c419 in lshift_significand (r=0xc97980, a=0xc97980, n=63)
at ../../gcc/real.c:254
254 r->sig[SIGSZ-1-i]
(gdb) p *r
$2 = {cl = 1, decimal = 0, sign = 0, signalling = 0, canonical = 0,
uexp = 1, sig = {0, 1, 9223372036854775808}}
(gdb) p *a
$3 = {cl = 1, decimal = 0, sign = 0, signalling = 0, canonical = 0,
uexp = 1, sig = {0, 1, 9223372036854775808}}
(gdb) bt
#0 0x000000000074c419 in lshift_significand (r=0xc97980, a=0xc97980, n=63)
at ../../gcc/real.c:254
#1 0x000000000074fcbc in real_from_integer (r=0xc97980, mode=DFmode,
low=<value optimized out>, high=1, unsigned_p=<value optimized out>)
at ../../gcc/real.c:2062
#2 0x00000000005ac6e2 in init_emit_once (line_numbers=<value optimized out>)
at ../../gcc/emit-rtl.c:5194
#3 0x000000000079a18b in toplev_main (argc=<value optimized out>,
argv=<value optimized out>) at ../../gcc/toplev.c:1825
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug other/28230] ICE during profiled bootstrap.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
2006-07-03 11:25 ` [Bug other/28230] " pluto at agmk dot net
@ 2006-07-04 21:16 ` pluto at agmk dot net
2006-08-03 20:39 ` [Bug other/28230] ICE during bootstrap (-O2 -fwrapv issue) pluto at agmk dot net
` (18 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-07-04 21:16 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from pluto at agmk dot net 2006-07-04 21:16 -------
works fine with BOOT_CFLAGS="-01" && STAGE1_CFLAGS="-O0".
with BOOT_CFLAGS="-O2" ices as above.
--
pluto at agmk dot net changed:
What |Removed |Added
----------------------------------------------------------------------------
GCC build triplet| |x86-64-linux
GCC host triplet| |x86-64-linux
GCC target triplet| |x86-64-linux
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug other/28230] ICE during bootstrap (-O2 -fwrapv issue)
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
2006-07-03 11:25 ` [Bug other/28230] " pluto at agmk dot net
2006-07-04 21:16 ` pluto at agmk dot net
@ 2006-08-03 20:39 ` pluto at agmk dot net
2006-08-03 20:41 ` pluto at agmk dot net
` (17 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-08-03 20:39 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from pluto at agmk dot net 2006-08-03 20:39 -------
now i'm sure that `-O2 -fwrapv` causes wrong-code in stage2 binaries.
to reproduce this failure try to build gcc with:
STAGE1_CFLAGS="-O1"
BOOT_CFLAGS="-O2 -fwrapv"
$ xgcc -v
Using built-in specs.
Target: x86_64-pld-linux
Configured with: ../configure --prefix=/usr --with-local-prefix=/usr/local
--libdir=/usr/lib64 --libexecdir=/usr/lib64 --infodir=/usr/share/info
--mandir=/usr/share/man --x-libraries=/usr/lib64 --enable-shared
--enable-threads=posix --enable-languages=c --enable-c99
--enable-long-long --enable-multilib --enable-nls --disable-werror
--with-gnu-as --with-gnu-ld --with-demangler-in-ld --with-system-zlib
--with-slibdir=/lib64 --without-system-libunwind --without-x
--with-long-double-128 --enable-bootstrap x86_64-pld-linux
Thread model: posix
gcc version 4.2.0 20060803 (experimental) (PLD-Linux)
--
pluto at agmk dot net changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |wrong-code
Summary|ICE during bootstrap |ICE during bootstrap (-O2 -
|(possible wrong code at - |fwrapv issue)
|O2). |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug other/28230] ICE during bootstrap (-O2 -fwrapv issue)
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (2 preceding siblings ...)
2006-08-03 20:39 ` [Bug other/28230] ICE during bootstrap (-O2 -fwrapv issue) pluto at agmk dot net
@ 2006-08-03 20:41 ` pluto at agmk dot net
2006-08-03 20:42 ` pluto at agmk dot net
` (16 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-08-03 20:41 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from pluto at agmk dot net 2006-08-03 20:41 -------
(In reply to comment #2)
> works fine with BOOT_CFLAGS="-01" && STAGE1_CFLAGS="-O0".
> with BOOT_CFLAGS="-O2" ices as above.
please ignore this comment. i missed note about my common cflags
(-fwrpav -fno-strict-aliasing)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug other/28230] ICE during bootstrap (-O2 -fwrapv issue)
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (3 preceding siblings ...)
2006-08-03 20:41 ` pluto at agmk dot net
@ 2006-08-03 20:42 ` pluto at agmk dot net
2006-09-01 20:11 ` pluto at agmk dot net
` (15 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-08-03 20:42 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from pluto at agmk dot net 2006-08-03 20:42 -------
*** Bug 28272 has been marked as a duplicate of this bug. ***
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug other/28230] ICE during bootstrap (-O2 -fwrapv issue)
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (4 preceding siblings ...)
2006-08-03 20:42 ` pluto at agmk dot net
@ 2006-09-01 20:11 ` pluto at agmk dot net
2006-09-19 13:08 ` [Bug other/28230] -O2 -fwrapv miscompiles gcc, binutils, gzip pluto at agmk dot net
` (14 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-09-01 20:11 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from pluto at agmk dot net 2006-09-01 20:11 -------
I have a smaller testcase.
`-march=x86-64 -O2 -fno-strict-aliasing -fwrapv` generates wrong code
for gas/write.c from binutils-2.17.50.0.3 and assembler fails on every
file with an error message:
/tmp/ccsCHgd4.s: Assembler messages:
/tmp/ccsCHgd4.s:3: Fatal error: Infinite loop encountered whilst attempting
to compute the addresses of symbols in section .text
--
pluto at agmk dot net changed:
What |Removed |Added
----------------------------------------------------------------------------
Known to fail| |4.2.0
Known to work| |4.1.2
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug other/28230] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (5 preceding siblings ...)
2006-09-01 20:11 ` pluto at agmk dot net
@ 2006-09-19 13:08 ` pluto at agmk dot net
2006-09-20 20:44 ` pluto at agmk dot net
` (13 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-09-19 13:08 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from pluto at agmk dot net 2006-09-19 13:08 -------
and one more misscompiled program -> gzip-1.3.5.
this time 4.1.2 with -O2 -fwrapv produces wrong code.
$ dd if=/dev/zero of=foo count=10
$ gzip foo
$ gzip -d foo.gz
$ gzip: foo.gz: invalid compressed data--format violated
--
pluto at agmk dot net changed:
What |Removed |Added
----------------------------------------------------------------------------
Known to fail|4.2.0 |4.2.0 4.1.2
Known to work|4.1.2 |
Summary|ICE during bootstrap / |-O2 -fwrapv miscompiles gcc,
|binutils miscompilation (-O2|binutils, gzip.
|-fwrapv issue) |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug other/28230] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (6 preceding siblings ...)
2006-09-19 13:08 ` [Bug other/28230] -O2 -fwrapv miscompiles gcc, binutils, gzip pluto at agmk dot net
@ 2006-09-20 20:44 ` pluto at agmk dot net
2006-09-20 20:45 ` pluto at agmk dot net
` (12 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-09-20 20:44 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from pluto at agmk dot net 2006-09-20 20:44 -------
(In reply to comment #7)
> and one more misscompiled program -> gzip-1.3.5.
> this time 4.1.2 with -O2 -fwrapv produces wrong code.
>
> $ dd if=/dev/zero of=foo count=10
> $ gzip foo
> $ gzip -d foo.gz
> $ gzip: foo.gz: invalid compressed data--format violated
further investigation shows that only `-O1 -ftree-vrp -fwrapv'
miscompiles the gzip/inflate.o.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug other/28230] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (7 preceding siblings ...)
2006-09-20 20:44 ` pluto at agmk dot net
@ 2006-09-20 20:45 ` pluto at agmk dot net
2006-09-20 23:31 ` pluto at agmk dot net
` (11 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-09-20 20:45 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from pluto at agmk dot net 2006-09-20 20:44 -------
Created an attachment (id=12302)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=12302&action=view)
testcase
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug other/28230] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (8 preceding siblings ...)
2006-09-20 20:45 ` pluto at agmk dot net
@ 2006-09-20 23:31 ` pluto at agmk dot net
2006-09-21 3:31 ` [Bug tree-optimization/28230] [4.2 Regression] " pinskia at gcc dot gnu dot org
` (10 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pluto at agmk dot net @ 2006-09-20 23:31 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from pluto at agmk dot net 2006-09-20 23:31 -------
i have a reduced testcase:
$ cat tmp.c
void foo( unsigned long bb, unsigned short tn, unsigned e, unsigned* w )
{
unsigned n = tn + bb;
do {
e = (e > n) ? e : *w;
n -= (e > n) ? n : e;
if (*w)
*w = 0;
} while ( n );
}
int main()
{
unsigned w = 0;
foo( 0, 0, 0, &w );
return 0;
}
with `-O1 -fwrapv -ftree-vrp' gcc-4.2 produces an infinite loop.
without -ftree-vrp it reaches an exit point. gcc-4.1 works fine
in both cases.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (9 preceding siblings ...)
2006-09-20 23:31 ` pluto at agmk dot net
@ 2006-09-21 3:31 ` pinskia at gcc dot gnu dot org
2006-09-21 3:37 ` pinskia at gcc dot gnu dot org
` (9 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-09-21 3:31 UTC (permalink / raw)
To: gcc-bugs
------- Comment #11 from pinskia at gcc dot gnu dot org 2006-09-21 03:31 -------
Confirmed with the testcase in comment #10.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Component|other |tree-optimization
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2006-09-21 03:31:17
date| |
Summary|-O2 -fwrapv miscompiles gcc,|[4.2 Regression] -O2 -fwrapv
|binutils, gzip. |miscompiles gcc, binutils,
| |gzip.
Target Milestone|--- |4.2.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (10 preceding siblings ...)
2006-09-21 3:31 ` [Bug tree-optimization/28230] [4.2 Regression] " pinskia at gcc dot gnu dot org
@ 2006-09-21 3:37 ` pinskia at gcc dot gnu dot org
2006-09-24 9:58 ` steven at gcc dot gnu dot org
` (8 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-09-21 3:37 UTC (permalink / raw)
To: gcc-bugs
------- Comment #12 from pinskia at gcc dot gnu dot org 2006-09-21 03:37 -------
Actually note here is one for 32bit targets also:
void foo( unsigned long long bb, unsigned short tn, unsigned e, unsigned* w );
void foo( unsigned long long bb, unsigned short tn, unsigned e, unsigned* w )
{
unsigned n = tn + bb;
do {
e = (e > n) ? e : *w;
n -= (e > n) ? n : e;
if (*w)
*w = 0;
} while ( n );
}
int main()
{
unsigned w = 0;
foo( 0, 0, 0, &w );
return 0;
}
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Severity|normal |blocker
GCC build triplet|x86-64-linux |
GCC host triplet|x86-64-linux |
GCC target triplet|x86-64-linux |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (11 preceding siblings ...)
2006-09-21 3:37 ` pinskia at gcc dot gnu dot org
@ 2006-09-24 9:58 ` steven at gcc dot gnu dot org
2006-09-24 10:05 ` steven at gcc dot gnu dot org
` (7 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: steven at gcc dot gnu dot org @ 2006-09-24 9:58 UTC (permalink / raw)
To: gcc-bugs
------- Comment #13 from steven at gcc dot gnu dot org 2006-09-24 09:58 -------
VRP bug.
--
steven at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dnovillo at gcc dot gnu dot
| |org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (12 preceding siblings ...)
2006-09-24 9:58 ` steven at gcc dot gnu dot org
@ 2006-09-24 10:05 ` steven at gcc dot gnu dot org
2006-09-24 10:08 ` steven at gcc dot gnu dot org
` (6 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: steven at gcc dot gnu dot org @ 2006-09-24 10:05 UTC (permalink / raw)
To: gcc-bugs
------- Comment #14 from steven at gcc dot gnu dot org 2006-09-24 10:05 -------
Value ranges after VRP without -fwrapv:
e_1: VARYING
n_2: VARYING
e_3: VARYING
tn_4: VARYING
D.1875_5: [0, 65535] EQUIVALENCES: { } (0 elements)
bb_6: VARYING
D.1876_7: [0, +INF] EQUIVALENCES: { } (0 elements)
n_8: [0, +INF] EQUIVALENCES: { } (0 elements)
e_9: VARYING
e_11: VARYING
e_12: [n_2 + 1, +INF] EQUIVALENCES: { e_1 e_21 } (2 elements)
e_13: [e_3, e_3] EQUIVALENCES: { e_3 } (1 elements)
D.1878_14: [0, +INF] EQUIVALENCES: { } (0 elements)
n_15: [0, +INF] EQUIVALENCES: { } (0 elements)
D.1879_16: VARYING
SMT.5_17: VARYING
SMT.5_18: VARYING
e_21: [n_2 + 1, +INF] EQUIVALENCES: { e_1 } (1 elements)
Value ranges after VRP with -fwrapv:
e_1: VARYING
n_2: [0, 65534] EQUIVALENCES: { } (0 elements)
e_3: VARYING
tn_4: VARYING
D.1875_5: [0, 65535] EQUIVALENCES: { } (0 elements)
bb_6: VARYING
D.1876_7: [0, +INF] EQUIVALENCES: { } (0 elements)
n_8: [0, 65534] EQUIVALENCES: { } (0 elements)
e_9: VARYING
e_11: VARYING
e_12: [1, +INF] EQUIVALENCES: { e_1 e_21 } (2 elements)
e_13: [e_3, e_3] EQUIVALENCES: { e_3 } (1 elements)
D.1878_14: [0, +INF] EQUIVALENCES: { } (0 elements)
n_15: [1, 65534] EQUIVALENCES: { } (0 elements)
D.1879_16: VARYING
SMT.5_17: VARYING
SMT.5_18: VARYING
e_21: [1, +INF] EQUIVALENCES: { e_1 } (1 elements)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (13 preceding siblings ...)
2006-09-24 10:05 ` steven at gcc dot gnu dot org
@ 2006-09-24 10:08 ` steven at gcc dot gnu dot org
2006-09-24 10:11 ` steven at gcc dot gnu dot org
` (5 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: steven at gcc dot gnu dot org @ 2006-09-24 10:08 UTC (permalink / raw)
To: gcc-bugs
------- Comment #15 from steven at gcc dot gnu dot org 2006-09-24 10:08 -------
Significant difference:
n_15: [0, +INF] EQUIVALENCES: { } (0 elements) without -fwrapv
n_15: [1, 65534] EQUIVALENCES: { } (0 elements) with -fwrapv
With -fwrapv this results in:
Folding predicate n_15 != 0 to 1
Folded statement: if (n_15 != 0) goto <L7>; else goto <L6>;
into: if (1) goto <L7>; else goto <L6>;
which is the infinite loop here.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (14 preceding siblings ...)
2006-09-24 10:08 ` steven at gcc dot gnu dot org
@ 2006-09-24 10:11 ` steven at gcc dot gnu dot org
2006-10-01 22:56 ` mmitchel at gcc dot gnu dot org
` (4 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: steven at gcc dot gnu dot org @ 2006-09-24 10:11 UTC (permalink / raw)
To: gcc-bugs
------- Comment #16 from steven at gcc dot gnu dot org 2006-09-24 10:11 -------
Actually looks like SCEV derives the wrong range.
--
steven at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |spop at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (15 preceding siblings ...)
2006-09-24 10:11 ` steven at gcc dot gnu dot org
@ 2006-10-01 22:56 ` mmitchel at gcc dot gnu dot org
2006-10-10 14:33 ` rguenth at gcc dot gnu dot org
` (3 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2006-10-01 22:56 UTC (permalink / raw)
To: gcc-bugs
--
mmitchel at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (16 preceding siblings ...)
2006-10-01 22:56 ` mmitchel at gcc dot gnu dot org
@ 2006-10-10 14:33 ` rguenth at gcc dot gnu dot org
2006-10-11 10:45 ` patchapp at dberlin dot org
` (2 subsequent siblings)
20 siblings, 0 replies; 22+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2006-10-10 14:33 UTC (permalink / raw)
To: gcc-bugs
------- Comment #17 from rguenth at gcc dot gnu dot org 2006-10-10 14:32 -------
No, it's extract_range_from_binary_expr operating on [0, +INF] + [0, 65535] and
blindly using int_const_binop to compute the resulting range...
I believe the following is completely bogus and we cannot ignore overflows
in range arithmetic for wrapv either.
static inline tree
vrp_int_const_binop (enum tree_code code, tree val1, tree val2)
{
tree res;
if (flag_wrapv)
return int_const_binop (code, val1, val2, 0);
--
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|NEW |ASSIGNED
Last reconfirmed|2006-09-21 03:31:17 |2006-10-10 14:32:50
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (17 preceding siblings ...)
2006-10-10 14:33 ` rguenth at gcc dot gnu dot org
@ 2006-10-11 10:45 ` patchapp at dberlin dot org
2006-10-11 16:06 ` rguenth at gcc dot gnu dot org
2006-10-11 16:06 ` rguenth at gcc dot gnu dot org
20 siblings, 0 replies; 22+ messages in thread
From: patchapp at dberlin dot org @ 2006-10-11 10:45 UTC (permalink / raw)
To: gcc-bugs
------- Comment #18 from patchapp at dberlin dot org 2006-10-11 10:45 -------
Subject: Bug number PR28230
A patch for this bug has been added to the patch tracker.
The mailing list url for the patch is
http://gcc.gnu.org/ml/gcc-patches/2006-10/msg00607.html
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (18 preceding siblings ...)
2006-10-11 10:45 ` patchapp at dberlin dot org
@ 2006-10-11 16:06 ` rguenth at gcc dot gnu dot org
2006-10-11 16:06 ` rguenth at gcc dot gnu dot org
20 siblings, 0 replies; 22+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2006-10-11 16:06 UTC (permalink / raw)
To: gcc-bugs
------- Comment #19 from rguenth at gcc dot gnu dot org 2006-10-11 16:05 -------
Subject: Bug 28230
Author: rguenth
Date: Wed Oct 11 16:05:37 2006
New Revision: 117637
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=117637
Log:
2006-10-11 Richard Guenther <rguenther@suse.de>
PR tree-optimization/28230
* tree-vrp.c (vrp_int_const_binop): Move flag_wrapv handling
to the correct place.
* gcc.dg/torture/pr28230.c: New testcase.
Added:
trunk/gcc/testsuite/gcc.dg/torture/pr28230.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-vrp.c
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
* [Bug tree-optimization/28230] [4.2 Regression] -O2 -fwrapv miscompiles gcc, binutils, gzip.
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
` (19 preceding siblings ...)
2006-10-11 16:06 ` rguenth at gcc dot gnu dot org
@ 2006-10-11 16:06 ` rguenth at gcc dot gnu dot org
20 siblings, 0 replies; 22+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2006-10-11 16:06 UTC (permalink / raw)
To: gcc-bugs
------- Comment #20 from rguenth at gcc dot gnu dot org 2006-10-11 16:06 -------
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=28230
^ permalink raw reply [flat|nested] 22+ messages in thread
end of thread, other threads:[~2006-10-11 16:06 UTC | newest]
Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-07-03 8:40 [Bug other/28230] New: ICE during profiled bootstrap pluto at agmk dot net
2006-07-03 11:25 ` [Bug other/28230] " pluto at agmk dot net
2006-07-04 21:16 ` pluto at agmk dot net
2006-08-03 20:39 ` [Bug other/28230] ICE during bootstrap (-O2 -fwrapv issue) pluto at agmk dot net
2006-08-03 20:41 ` pluto at agmk dot net
2006-08-03 20:42 ` pluto at agmk dot net
2006-09-01 20:11 ` pluto at agmk dot net
2006-09-19 13:08 ` [Bug other/28230] -O2 -fwrapv miscompiles gcc, binutils, gzip pluto at agmk dot net
2006-09-20 20:44 ` pluto at agmk dot net
2006-09-20 20:45 ` pluto at agmk dot net
2006-09-20 23:31 ` pluto at agmk dot net
2006-09-21 3:31 ` [Bug tree-optimization/28230] [4.2 Regression] " pinskia at gcc dot gnu dot org
2006-09-21 3:37 ` pinskia at gcc dot gnu dot org
2006-09-24 9:58 ` steven at gcc dot gnu dot org
2006-09-24 10:05 ` steven at gcc dot gnu dot org
2006-09-24 10:08 ` steven at gcc dot gnu dot org
2006-09-24 10:11 ` steven at gcc dot gnu dot org
2006-10-01 22:56 ` mmitchel at gcc dot gnu dot org
2006-10-10 14:33 ` rguenth at gcc dot gnu dot org
2006-10-11 10:45 ` patchapp at dberlin dot org
2006-10-11 16:06 ` rguenth at gcc dot gnu dot org
2006-10-11 16:06 ` 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).