On 09/25/2015 01:31 PM, Michael Shell wrote:
I may have found the problem or at least something close to it:

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

( and also:https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59463
   but 59463 seems to have been fixed by gcc 4.9.1)

Try this simple test mentioned in bug 64364:
Create a file foo.cc with the single line:

#include<limits>

then try to compile foo.cc with g++:

g++ -c foo.cc

This will succeed in creating foo.o without error or warning
on a normal system (it worked for me). If it fails, note what
Mikael Pettersson posted in gcc bug 64364:

   "Re-run g++ on the testcase with the -v flag, note the
    command line for cc1plus, run cc1plus from gdb with that
    command line, and show us the faulting instruction and
    what code/function it occurs in."

The problem in bug 64364 may be caused by an incorrect CPU/arch
setting that happened while building gcc - or more specifically
with regard to its support libraries such as gmp.


   Cheers,

   Mike Shell

Your are right!

Doing the above test produced the same error.

package atk:/usr/src/atk> g++ -c -v foo.cc
Using built-in specs.
COLLECT_GCC=g++
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-4.9.2/configure --prefix=/usr --enable-languages=c,c++ --disable-multilib --disable-bootstrap --with-system-zlib
Thread model: posix
gcc version 4.9.2 (GCC)
COLLECT_GCC_OPTIONS='-c' '-v' '-shared-libgcc' '-mtune=generic' '-march=x86-64'
/usr/libexec/gcc/x86_64-unknown-linux-gnu/4.9.2/cc1plus -quiet -v -D_GNU_SOURCE foo.cc -quiet -dumpbase foo.cc -mtune=generic -march=x86-64 -auxbase foo -version -o /tmp/cchOdRfj.s
GNU C++ (GCC) version 4.9.2 (x86_64-unknown-linux-gnu)
    compiled by GNU C version 4.9.2, GMP version 6.0.0, MPFR version 3.1.2-p11, 
MPC version 1.0.2
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
ignoring nonexistent directory 
"/usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.2/../../../../x86_64-unknown-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.2/../../../../include/c++/4.9.2
 
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.2/../../../../include/c++/4.9.2/x86_64-unknown-linux-gnu
 
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.2/../../../../include/c++/4.9.2/backward
 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.2/include
 /usr/local/include
 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.9.2/include-fixed
 /usr/include
End of search list.
GNU C++ (GCC) version 4.9.2 (x86_64-unknown-linux-gnu)
    compiled by GNU C version 4.9.2, GMP version 6.0.0, MPFR version 3.1.2-p11, 
MPC version 1.0.2
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: e0da299be26c1b07aee0bf7bbb0a948d
In file included from foo.cc:1:0:
/usr/include/c++/4.9.2/limits:1558:7: internal compiler error: Illegal 
instruction
       min() _GLIBCXX_USE_NOEXCEPT { return __FLT_MIN__; }
       ^
0x95017f crash_signal
    ../../gcc-4.9.2/gcc/toplev.c:337
0x7fa8f060051f ???
    
/usr/src/glibc/glibc-2.21/signal/../sysdeps/unix/sysv/linux/x86_64/sigaction.c:0
Please submit a full bug report,


Wayne Sallee
wa...@waynesallee.com
--
http://lists.linuxfromscratch.org/listinfo/blfs-support
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page

Reply via email to