public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/47626] New: internal compiler error: in print_reg (only for i686, and i486, not x86_64)
@ 2011-02-06 19:30 lappisstudent at hotmail dot com
  2011-02-06 20:23 ` [Bug c++/47626] " lappisstudent at hotmail dot com
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: lappisstudent at hotmail dot com @ 2011-02-06 19:30 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47626

           Summary: internal compiler error: in print_reg (only for i686,
                    and i486, not x86_64)
           Product: gcc
           Version: 4.4.6
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: lappisstudent@hotmail.com


Created attachment 23259
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=23259
minimal code to trigger internal compiler error

Attached code triggers an internal compiler error for these versions of gcc
(when 32-bit build, host, and target supplied to configure)
gcc version 4.4.5 (GCC)
gcc version 4.4.6 20110201 (prerelease) (GCC)
gcc version 4.4.5 (Ubuntu/Linaro 4.4.4-14ubuntu5)
gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5) <==fails for 32-bit, does however
work for x86_64 variants

Attached code does however work on "gcc version 4.5.2 (GCC)".

System type: Ubuntu 10.10 running under virtualbox, ubuntu 10.04 on an atom
N270, and a friends laptop.

cmdline triggering bug: gcc -c -O3 -o main.o main.cc

Error messages:
=====[gcc version 4.4.5 (GCC)]=====
main.cc: In function ‘int main(int, char**)’:
main.cc:41: internal compiler error: in print_reg, at config/i386/i386.c:10678
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.

=====[gcc version 4.4.6 20110201 (prerelease) (GCC)]=====
main.cc: In function ‘int main(int, char**)’:
main.cc:41: internal compiler error: in print_reg, at config/i386/i386.c:10717
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.

=====[gcc version 4.4.5 (Ubuntu/Linaro 4.4.4-14ubuntu5)]=====
main.cc: In function ‘int main(int, char**)’:
main.cc:41: internal compiler error: in print_reg, at config/i386/i386.c:10811
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-4.4/README.Bugs> for instructions.

=====[gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5)]=====
main.cc: In function ‘int main(int, char**)’:
main.cc:41: internal compiler error: in print_reg, at config/i386/i386.c:10673
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-4.4/README.Bugs> for instructions.


Configurations:
=====[gcc version 4.4.5 (GCC)]=====
Using built-in specs.
Target: i686-linux-gnu
Configured with: ./configure --enable-languages=c,c++ --prefix=/usr/local
--program-suffix=-4.4.5_ppl --enable-clocale=gnu --disable-werror
--with-arch-32=i686 --with-tune=generic --enable-checking=release
--build=i686-linux-gnu --host=i686-linux-gnu --target=i686-linux-gnu
Thread model: posix
gcc version 4.4.5 (GCC)

=====[gcc version 4.4.6 20110201 (prerelease) (GCC)]=====
Using built-in specs.
Target: i686-linux-gnu
Configured with: ./configure --enable-languages=c,c++ --prefix=/usr/local
--program-suffix=-4.4-20110201_ppl --enable-clocale=gnu --disable-werror
--with-arch-32=i686 --with-tune=generic --enable-checking=release
--build=i686-linux-gnu --host=i686-linux-gnu --target=i686-linux-gnu
Thread model: posix


=====[gcc version 4.4.5 (Ubuntu/Linaro 4.4.4-14ubuntu5)]=====
Using built-in specs.
Target: i686-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu/Linaro
4.4.4-14ubuntu5' --with-bugurl=file:///usr/share/doc/gcc-4.4/README.Bugs
--enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr
--program-suffix=-4.4 --enable-shared --enable-multiarch
--enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib
--without-included-gettext --enable-threads=posix
--with-gxx-include-dir=/usr/include/c++/4.4 --libdir=/usr/lib --enable-nls
--with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-objc-gc
--enable-targets=all --disable-werror --with-arch-32=i686 --with-tune=generic
--enable-checking=release --build=i686-linux-gnu --host=i686-linux-gnu
--target=i686-linux-gnu
Thread model: posix
gcc version 4.4.5 (Ubuntu/Linaro 4.4.4-14ubuntu5)

=====[gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5)]=====
Using built-in specs.
Target: i486-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu
4.4.3-4ubuntu5' --with-bugurl=file:///usr/share/doc/gcc-4.4/README.Bugs
--enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr
--enable-shared --enable-multiarch --enable-linker-build-id
--with-system-zlib --libexecdir=/usr/lib --without-included-gettext
--enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.4
--program-suffix=-4.4 --enable-nls --enable-clocale=gnu
--enable-libstdcxx-debug --enable-plugin --enable-objc-gc
--enable-targets=all --disable-werror --with-arch-32=i486
--with-tune=generic --enable-checking=release --build=i486-linux-gnu
--host=i486-linux-gnu --target=i486-linux-gnu
Thread model: posix
gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5)


Additional information:
This is probably related to #47596, which was marked as "resolved" since it
worked for a few tested releases (target was i686-w64-mingw32). My code seems
to be reproducible on i686-linux-gnu and i486-linux-gnu targets.

Code compiles without problem when telling compiler it's "c" instead of "c++",
or when not supplying either "-O2" or "-O3". (or when looping fewer times, see
comment in source).

* These packages was installed besides ubuntu 10.10 to build the non-ubuntu gcc
releases and snapshot, and since compiling the attached code worked with my
compilation of gcc 4.5.2, I hope these libraries didn't mess things up too
badly.
libmpfr-dev      3.0.0-2
libmpfr4         3.0.0-2
libgmp3-dev    2:4.3.2+dfsg-1ubuntu1
libgmp3c2      2:4.3.2+dfsg-1ubuntu1
libgmpxx4ldbl  2:4.3.2+dfsg-1ubuntu1
libmpc-dev       0.8.2-1build1
libmpc2          0.8.2-1build1
libcloog-ppl-dev 0.15.9-2
libcloog-ppl0    0.15.9-2
libppl-c2        0.10.2-7ubuntu1
libppl0.10-dev   0.10.2-7ubuntu1
libppl7          0.10.2-7ubuntu1

/Simon Gustafsson


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug c++/47626] internal compiler error: in print_reg (only for i686, and i486, not x86_64)
  2011-02-06 19:30 [Bug c++/47626] New: internal compiler error: in print_reg (only for i686, and i486, not x86_64) lappisstudent at hotmail dot com
@ 2011-02-06 20:23 ` lappisstudent at hotmail dot com
  2011-04-17  9:08 ` [Bug target/47626] " sezeroz at gmail dot com
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: lappisstudent at hotmail dot com @ 2011-02-06 20:23 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47626

--- Comment #1 from Simon Gustafsson <lappisstudent at hotmail dot com> 2011-02-06 20:21:09 UTC ---
Removed my ppl and cloog libraries, and recompiled the 4.4.6 gcc snapshot. I
still get the same internal compiler error, so not dependant on those...


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug target/47626] internal compiler error: in print_reg (only for i686, and i486, not x86_64)
  2011-02-06 19:30 [Bug c++/47626] New: internal compiler error: in print_reg (only for i686, and i486, not x86_64) lappisstudent at hotmail dot com
  2011-02-06 20:23 ` [Bug c++/47626] " lappisstudent at hotmail dot com
@ 2011-04-17  9:08 ` sezeroz at gmail dot com
  2014-06-04 11:07 ` it at psika dot cz
  2021-08-05 23:23 ` pinskia at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: sezeroz at gmail dot com @ 2011-04-17  9:08 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47626

Ozkan Sezer <sezeroz at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |sezeroz at gmail dot com

--- Comment #2 from Ozkan Sezer <sezeroz at gmail dot com> 2011-04-17 09:07:34 UTC ---
Possibly related: PR target/47596 (which is incorrectly marked as WORKSFORME at
present...)


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug target/47626] internal compiler error: in print_reg (only for i686, and i486, not x86_64)
  2011-02-06 19:30 [Bug c++/47626] New: internal compiler error: in print_reg (only for i686, and i486, not x86_64) lappisstudent at hotmail dot com
  2011-02-06 20:23 ` [Bug c++/47626] " lappisstudent at hotmail dot com
  2011-04-17  9:08 ` [Bug target/47626] " sezeroz at gmail dot com
@ 2014-06-04 11:07 ` it at psika dot cz
  2021-08-05 23:23 ` pinskia at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: it at psika dot cz @ 2014-06-04 11:07 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47626

Tomas Psika <it at psika dot cz> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |it at psika dot cz

--- Comment #3 from Tomas Psika <it at psika dot cz> ---
Another minimal code using GCC 4.6.3 (gcc47626.cpp) on Gentoo:

#include <cstdlib>

int main() {
    int size = atoi("4");
    return 1;
    double array[size];
}

Does trigger ICE using GCC 4.6.3 without optimization (-O0), no errors using
optimization (-O[1-3]). Newer GCC 4.8.2 does not trigger ICE at all.

# g++-4.6.3 -O0 gcc47626.cpp -o /dev/null && echo "OK"
gcc47626.cpp: In function ‘int main()’:
gcc47626.cpp:7:1: internal compiler error: in print_reg, at
config/i386/i386.c:13694
Please submit a full bug report,
with preprocessed source if appropriate.
See <https://bugs.gentoo.org/> for instructions.
# g++-4.6.3 -O1 gcc47626.cpp -o /dev/null && echo "OK"
OK
# g++-4.8.2 -O0 gcc47626.cpp -o /dev/null && echo "OK"
OK
# g++-4.8.2 -O0 gcc47626.cpp -o /dev/null && echo "OK"
OK
>From gcc-bugs-return-453197-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Jun 04 11:08:18 2014
Return-Path: <gcc-bugs-return-453197-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 7438 invoked by alias); 4 Jun 2014 11:08:17 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 7383 invoked by uid 48); 4 Jun 2014 11:08:13 -0000
From: "cbaylis at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/61411] New: [NEON] ICE in reload_cse_simplify_operands, at postreload.c:411
Date: Wed, 04 Jun 2014 11:08:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: cbaylis at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter cf_gcctarget attachments.created
Message-ID: <bug-61411-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-06/txt/msg00279.txt.bz2
Content-length: 2301

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61411

            Bug ID: 61411
           Summary: [NEON] ICE in reload_cse_simplify_operands, at
                    postreload.c:411
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: cbaylis at gcc dot gnu.org
            Target: aarch64-oe-linux

Created attachment 32890
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=32890&action=edit
Reduced test case

The attached test case results in an ICE when compiled with gcc 4.9

$ aarch64-oe-linux-gcc -O3 -c test.c
test.c: In function ‘vp9_idct16x16_256_add_neon_pass2’:
test.c:126:1: error: insn does not satisfy its constraints:
 }
 ^
(insn 198 110 159 2 (set (reg:V8QI 37 v5 [orig:118 D.16400 ] [118])
        (mem:V8QI (plus:DI (reg/v/f:DI 20 x20 [orig:202 dest ] [202])
                (reg:DI 8 x8 [340])) [2 MEM[(const int64_t *)dest_44]+0 S8
A64]))
/home/cbaylis/tools/tools-aarch64-oe-linux-4.9/lib/gcc/aarch64-oe-linux/4.9.1/include/arm_neon.h:3646
735 {*aarch64_simd_movv8qi}
     (nil))
test.c:126:1: internal compiler error: in reload_cse_simplify_operands, at
postreload.c:411
0x7fc47a _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
        /home/cbaylis/srcarea/gcc/gcc-4_9-branch/gcc/rtl-error.c:109
0x7fc49f _fatal_insn_not_found(rtx_def const*, char const*, int, char const*)
        /home/cbaylis/srcarea/gcc/gcc-4_9-branch/gcc/rtl-error.c:120
0x7bdbd9 reload_cse_simplify_operands
        /home/cbaylis/srcarea/gcc/gcc-4_9-branch/gcc/postreload.c:411
0x7bf69c reload_cse_simplify
        /home/cbaylis/srcarea/gcc/gcc-4_9-branch/gcc/postreload.c:181
0x7bf69c reload_cse_regs_1
        /home/cbaylis/srcarea/gcc/gcc-4_9-branch/gcc/postreload.c:220
0x7bfa8b reload_cse_regs
        /home/cbaylis/srcarea/gcc/gcc-4_9-branch/gcc/postreload.c:68
0x7bfa8b rest_of_handle_postreload
        /home/cbaylis/srcarea/gcc/gcc-4_9-branch/gcc/postreload.c:2332
0x7bfa8b execute
        /home/cbaylis/srcarea/gcc/gcc-4_9-branch/gcc/postreload.c:2368


There is a patch which appears to fix this problem at
https://gcc.gnu.org/ml/gcc-patches/2014-05/msg02397.html
>From gcc-bugs-return-453198-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Jun 04 11:57:13 2014
Return-Path: <gcc-bugs-return-453198-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 4191 invoked by alias); 4 Jun 2014 11:57:12 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 3796 invoked by uid 55); 4 Jun 2014 11:57:07 -0000
From: "rguenth at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/60098] DSE fails to DSE errno settings
Date: Wed, 04 Jun 2014 11:57:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords: missed-optimization
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: rguenth at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: rguenth at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-60098-4-xnz3qstPce@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-60098-4@http.gcc.gnu.org/bugzilla/>
References: <bug-60098-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-06/txt/msg00280.txt.bz2
Content-length: 698

https://gcc.gnu.org/bugzilla/show_bug.cgi?id`098

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
Author: rguenth
Date: Wed Jun  4 11:56:34 2014
New Revision: 211224

URL: http://gcc.gnu.org/viewcvs?rev!1224&root=gcc&view=rev
Log:
2014-06-04  Richard Biener  <rguenther@suse.de>

    PR tree-optimization/60098
    * tree-ssa-dse.c (dse_possible_dead_store_p): Walk until
    we hit a kill.
    (dse_optimize_stmt): Simplify, now that we found a kill
    earlier.

    * gcc.dg/tree-ssa/ssa-dse-15.c: New testcase.

Added:
    trunk/gcc/testsuite/gcc.dg/tree-ssa/ssa-dse-15.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree-ssa-dse.c


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug target/47626] internal compiler error: in print_reg (only for i686, and i486, not x86_64)
  2011-02-06 19:30 [Bug c++/47626] New: internal compiler error: in print_reg (only for i686, and i486, not x86_64) lappisstudent at hotmail dot com
                   ` (2 preceding siblings ...)
  2014-06-04 11:07 ` it at psika dot cz
@ 2021-08-05 23:23 ` pinskia at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-08-05 23:23 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47626

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
           Keywords|                            |ice-on-valid-code
         Resolution|---                         |WORKSFORME

--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Nobody can reproduce this and it has been around for over 6 years so closing as
works for me.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-08-05 23:23 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-02-06 19:30 [Bug c++/47626] New: internal compiler error: in print_reg (only for i686, and i486, not x86_64) lappisstudent at hotmail dot com
2011-02-06 20:23 ` [Bug c++/47626] " lappisstudent at hotmail dot com
2011-04-17  9:08 ` [Bug target/47626] " sezeroz at gmail dot com
2014-06-04 11:07 ` it at psika dot cz
2021-08-05 23:23 ` pinskia 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).