From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24775 invoked by alias); 24 Jun 2012 14:30:31 -0000 Received: (qmail 24765 invoked by uid 22791); 24 Jun 2012 14:30:29 -0000 X-SWARE-Spam-Status: No, hits=-3.5 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00,TW_CX,TW_DC X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 24 Jun 2012 14:30:16 +0000 From: "br+gcc at waldteufel dot eu" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/53761] New: ICE (only with C++) on incorrect transparent union (first field has floating point type) Date: Sun, 24 Jun 2012 14:30:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Keywords: X-Bugzilla-Severity: minor X-Bugzilla-Who: br+gcc at waldteufel dot eu X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2012-06/txt/msg01585.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53761 Bug #: 53761 Summary: ICE (only with C++) on incorrect transparent union (first field has floating point type) Classification: Unclassified Product: gcc Version: 4.7.1 Status: UNCONFIRMED Severity: minor Priority: P3 Component: c++ AssignedTo: unassigned@gcc.gnu.org ReportedBy: br+gcc@waldteufel.eu While compiling typedef union { double x; } __attribute__(( __transparent_union__ )) example_t; void fail(example_t x) { } int main() { example_t x; fail(x); } as C code results in a warning message (see below for detailed system information) > gcc fail.c fail.c:1:9: warning: union cannot be made transparent [enabled by default] compiling the same code as C++ results in an ICE > g++ -v fail.cc Using built-in specs. COLLECT_GCC=g++ COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/lto-wrapper Target: x86_64-unknown-linux-gnu Configured with: /build/src/gcc-4.7.1/configure --prefix=/usr --libdir=/usr/lib --libexecdir=/usr/lib --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=https://bugs.archlinux.org/ --enable-languages=c,c++,ada,fortran,go,lto,objc,obj-c++ --enable-shared --enable-threads=posix --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-clocale=gnu --disable-libstdcxx-pch --enable-libstdcxx-time --enable-gnu-unique-object --enable-linker-build-id --with-ppl --enable-cloog-backend=isl --enable-lto --enable-gold --enable-ld=default --enable-plugin --with-plugin-ld=ld.gold --with-linker-hash-style=gnu --disable-multilib --disable-libssp --disable-build-with-cxx --disable-build-poststage1-with-cxx --enable-checking=release Thread model: posix gcc version 4.7.1 (GCC) COLLECT_GCC_OPTIONS='-v' '-shared-libgcc' '-mtune=generic' '-march=x86-64' /usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/cc1plus -quiet -v -D_GNU_SOURCE fail.cc -quiet -dumpbase fail.cc -mtune=generic -march=x86-64 -auxbase fail -version -o /tmp/cc6IkFB2.s GNU C++ (GCC) version 4.7.1 (x86_64-unknown-linux-gnu) compiled by GNU C version 4.7.1, GMP version 5.0.5, MPFR version 3.1.0-p10, MPC version 0.9 GGC heuristics: --param ggc-min-expand=97 --param ggc-min-heapsize=126590 ignoring nonexistent directory "/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../x86_64-unknown-linux-gnu/include" #include "..." search starts here: #include <...> search starts here: /usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/x86_64-unknown-linux-gnu /usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/backward /usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/include /usr/local/include /usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/include-fixed /usr/include End of search list. GNU C++ (GCC) version 4.7.1 (x86_64-unknown-linux-gnu) compiled by GNU C version 4.7.1, GMP version 5.0.5, MPFR version 3.1.0-p10, MPC version 0.9 GGC heuristics: --param ggc-min-expand=97 --param ggc-min-heapsize=126590 Compiler executable checksum: ed88b587bcb9a173af71789c9d103676 fail.cc: In function 'int main()': fail.cc:9:11: internal compiler error: in convert_move, at expr.c:325 Please submit a full bug report, with preprocessed source if appropriate. See for instructions.