[Bug libstdc++/57844] New: avr-unknown-elf libstdc++v3 build causes internal compiler error: in extract_insn, at recog.c:2150

2013-07-07 Thread bugzilla.gcc at buszta dot info
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57844

Bug ID: 57844
   Summary: avr-unknown-elf libstdc++v3 build causes internal
compiler error: in extract_insn, at recog.c:2150
   Product: gcc
   Version: 4.8.1
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: libstdc++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: bugzilla.gcc at buszta dot info

Trying to compile GCC 4.8.1 (SVN trunk also applies) toolchain for
avr-unknown-elf target with standard C++ library support.

Configuration options:
../gcc-4.8.1/configure
--prefix=/home/abuszta/Development/avr/gcc-4.8.1-avr-unknown-elf
--target=avr-unknown-elf --disable-__cxa_atexit --disable-nls --disable-threads
--disable-shared --enable-static --with-dwarf2 --with-gmp=/usr/local
--with-mpfr=/usr/local --with-mpc=/usr/local --with-ppl=/usr/local
--enable-libstdcxx --enable-languages=c,c++ --with-newlib
--disable-sjlj-exceptions

Build with:
binutils 2.23.2
gmp 5.0.5
mpc 0.9
mpfr 3.1.2
ppl 0.12.1
newlib 1.20.0

Host GCC:
gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-redhat-linux/4.7.2/lto-wrapper
Target: x86_64-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
--infodir=/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla
--enable-bootstrap --enable-shared --enable-threads=posix
--enable-checking=release --disable-build-with-cxx
--disable-build-poststage1-with-cxx --with-system-zlib --enable-__cxa_atexit
--disable-libunwind-exceptions --enable-gnu-unique-object
--enable-linker-build-id --with-linker-hash-style=gnu
--enable-languages=c,c++,objc,obj-c++,java,fortran,ada,go,lto --enable-plugin
--enable-initfini-array --enable-java-awt=gtk --disable-dssi
--with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre
--enable-libgcj-multifile --enable-java-maintainer-mode
--with-ecj-jar=/usr/share/java/eclipse-ecj.jar --disable-libjava-multilib
--with-ppl --with-cloog --with-tune=generic --with-arch_32=i686
--build=x86_64-redhat-linux
Thread model: posix
gcc version 4.7.2 20120921 (Red Hat 4.7.2-2) (GCC)


Building make all-target-libstdc++-v3 gives error:

(...)
Making all in c++11
make[8]: Entering directory
`/home/abuszta/Development/avr/gcc-4.8.1-build/avr-unknown-elf/tiny-stack/libstdc++-v3/src/c++11'
/bin/sh ../../libtool --tag CXX --tag disable-shared   --mode=compile
/home/abuszta/Development/avr/gcc-4.8.1-build/./gcc/xgcc -shared-libgcc
-B/home/abuszta/Development/avr/gcc-4.8.1-build/./gcc -nostdinc++
-L/home/abuszta/Development/avr/gcc-4.8.1-build/avr-unknown-elf/tiny-stack/libstdc++-v3/src
-L/home/abuszta/Development/avr/gcc-4.8.1-build/avr-unknown-elf/tiny-stack/libstdc++-v3/src/.libs
-B/home/abuszta/Development/avr/gcc-4.8.1-avr-unknown-elf/avr-unknown-elf/bin/
-B/home/abuszta/Development/avr/gcc-4.8.1-avr-unknown-elf/avr-unknown-elf/lib/
-isystem
/home/abuszta/Development/avr/gcc-4.8.1-avr-unknown-elf/avr-unknown-elf/include
-isystem
/home/abuszta/Development/avr/gcc-4.8.1-avr-unknown-elf/avr-unknown-elf/sys-include
 -msp8 -I/home/abuszta/Development/avr/gcc-4.8.1/libstdc++-v3/../libgcc
-I/home/abuszta/Development/avr/gcc-4.8.1-build/avr-unknown-elf/tiny-stack/libstdc++-v3/include/avr-unknown-elf
-I/home/abuszta/Development/avr/gcc-4.8.1-build/avr-unknown-elf/tiny-stack/libstdc++-v3/include
-I/home/abuszta/Development/avr/gcc-4.8.1/libstdc++-v3/libsupc++  -std=gnu++11 
 -fno-implicit-templates -Wall -Wextra -Wwrite-strings -Wcast-qual -Wabi 
-fdiagnostics-show-location=once   -ffunction-sections -fdata-sections 
-frandom-seed=debug.lo -g -O2  -msp8  -c -o debug.lo
../../../../../../gcc-4.8.1/libstdc++-v3/src/c++11/debug.cc
libtool: compile:  /home/abuszta/Development/avr/gcc-4.8.1-build/./gcc/xgcc
-shared-libgcc -B/home/abuszta/Development/avr/gcc-4.8.1-build/./gcc
-nostdinc++
-L/home/abuszta/Development/avr/gcc-4.8.1-build/avr-unknown-elf/tiny-stack/libstdc++-v3/src
-L/home/abuszta/Development/avr/gcc-4.8.1-build/avr-unknown-elf/tiny-stack/libstdc++-v3/src/.libs
-B/home/abuszta/Development/avr/gcc-4.8.1-avr-unknown-elf/avr-unknown-elf/bin/
-B/home/abuszta/Development/avr/gcc-4.8.1-avr-unknown-elf/avr-unknown-elf/lib/
-isystem
/home/abuszta/Development/avr/gcc-4.8.1-avr-unknown-elf/avr-unknown-elf/include
-isystem
/home/abuszta/Development/avr/gcc-4.8.1-avr-unknown-elf/avr-unknown-elf/sys-include
-msp8 -I/home/abuszta/Development/avr/gcc-4.8.1/libstdc++-v3/../libgcc
-I/home/abuszta/Development/avr/gcc-4.8.1-build/avr-unknown-elf/tiny-stack/libstdc++-v3/include/avr-unknown-elf
-I/home/abuszta/Development/avr/gcc-4.8.1-build/avr-unknown-elf/tiny-stack/libstdc++-v3/include
-I/home/abuszta/Development/avr/gcc-4.8.1/libstdc++-v3/libsupc++ -std=gnu++11
-fno-implicit-templates -Wall -Wextra -Wwrite-strings -Wcast-qual -Wabi
-fdiagnostics-show-location=once -ffunction-sections -fdata-sections
-frandom-seed=debug.lo -g -O2 -ms

[Bug c++/58457] New: ICE when placement new operator is used with using keyword and custom constructor

2013-09-18 Thread bugzilla.gcc at buszta dot info
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58457

Bug ID: 58457
   Summary: ICE when placement new operator is used with using
keyword and custom constructor
   Product: gcc
   Version: 4.8.1
Status: UNCONFIRMED
  Severity: major
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: bugzilla.gcc at buszta dot info

Created attachment 30847
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=30847&action=edit
Preprocessed source

Minimal reproduction code:
struct allocator
{
void operator delete(void*) {}
void* operator new(unsigned int, void*) {}
};

struct type : public allocator
{
type() {}
using allocator::operator new;
using allocator::operator delete;
};

int main()
{
new (0) type;
return 0;
}

Compiler output:
g++ main.cpp   -o main
main.cpp: In function 'int main()':
main.cpp:16:13: internal compiler error: in instantiate_type, at
cp/class.c:7512
 new (0) type;
 ^
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.
Preprocessed source stored into /tmp/cc4KIZ6k.out file, please attach this to
your bugreport.
make: *** [main] Error 1

Compiler version:
$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/i486-linux-gnu/4.8/lto-wrapper
Target: i486-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian 4.8.1-10'
--with-bugurl=file:///usr/share/doc/gcc-4.8/README.Bugs
--enable-languages=c,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr
--program-suffix=-4.8 --enable-shared --enable-linker-build-id
--libexecdir=/usr/lib --without-included-gettext --enable-threads=posix
--with-gxx-include-dir=/usr/include/c++/4.8 --libdir=/usr/lib --enable-nls
--with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug
--enable-libstdcxx-time=yes --enable-gnu-unique-object --enable-plugin
--with-system-zlib --disable-browser-plugin --enable-java-awt=gtk
--enable-gtk-cairo --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-4.8-i386/jre
--enable-java-home --with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-4.8-i386
--with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-4.8-i386
--with-arch-directory=i386 --with-ecj-jar=/usr/share/java/eclipse-ecj.jar
--enable-objc-gc --enable-targets=all --enable-multiarch --with-arch-32=i586
--with-multilib-list=m32,m64,mx32 --with-tune=generic --enable-checking=release
--build=i486-linux-gnu --host=i486-linux-gnu --target=i486-linux-gnu
Thread model: posix
gcc version 4.8.1 (Debian 4.8.1-10)

Non reproducible on older compilers.