-march=pentiumpro failed to compile libstdc++ v3 with optimization

H . J . Lu hjl@valinux.com
Fri Jul 21 13:03:00 GMT 2000


-march=pentiumpro failed to compile libstdc++ v3 with optimization
under glibc 2.2. With -O, I got

/work/build/gnu/bin/gcc-3.0-libstdc++v3/gcc/g++ -B/work/build /gnu/bin/gcc-3.0-libstdc++v3/gcc/ -B/opt/gcc-3.0-v3/i686-pc-linux/bin/ -L/work/build/gnu/bin/gcc-3.0-libstdc++v3/i686-pc-linux/libstdc++ -DHAVE_CONFIG_H -I.  -I/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/src -I.. -nostdinc++ -I/work/gnu/src/gcc-3.0/egcs/libstdc++-v3 -I/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/libio -I/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/config/cpu/i486 -I/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/config/gnu-linux -I/opt/gcc-3.0-v3/include  -pipe -fvtable-thunks -D_GNU_SOURCE -D_GNU_SOURCE -fno-implicit-templates -Wall -Wno-format -W -Wwrite-strings -Winline -Werror -Wno-unknown-pragmas -fdiagnostics-show-location=once-ffunction-sections -fdata-sections -g -fimplicit-templates -c /work/gnu/src/gcc-3.0 /egcs/libstdc++-v3/src/misc-inst.cc -o misc-inst.o -march=pentiumpro -O
/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/bits/basic_ios.tcc: In method `void std::basic_ios<_CharT, 
_Traits>::init (std::basic_streambuf<_CharT, _Traits> *) [with _CharT = char, _T raits = std::char_traits<char>]':
/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/src/misc-inst.cc:88:   instantiated from here
/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/bits/basic_ios.tcc:132: Unrecognizable insn:
(insn 912 911 288 (set (reg/v:SI 61)
        (if_then_else:SI (ne (reg:CCZ 17 flags)
                (const_int 0 [0x0]))
            (mem/u/f:SI (symbol_ref:SI ("_Q23std8ios_base.goodbit")) 0)
            (mem/u/f:SI (symbol_ref:SI ("_Q23std8ios_base.badbit")) 0))) -1
(insn_list 911 (nil))
    (expr_list:REG_DEAD (reg:CCZ 17 flags)
        (nil)))
/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/bits/basic_ios.tcc:132: Internal compiler error in extract_insn,
at recog.c:2048

With -O2, I got

/work/build/gnu/bin/gcc-3.0-libstdc++v3/gcc/g++ -B/work/build /gnu/bin/gcc-3.0-libstdc++v3/gcc/ -B/opt/gcc-3.0-v3/i686-pc-linux/bin/ -L/work/build/gnu/bin/gcc-3.0-libstdc++v3/i686-pc-linux/libstdc++ -DHAVE_CONFIG_H -I.  -I/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/src -I..  -nostdinc++ -I/work/gnu/src/gcc-3.0/egcs/libstdc++-v3 -I/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/libio -I/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/config/cpu/i486 -I/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/config/gnu-linux -I/opt/gcc-3.0-v3/include  -pipe -fvtable-thunks -D_GNU_SOURCE -D_GNU_SOURCE -fno-implicit-templates -Wall -Wno-format -W -Wwrite-strings -Winline -Werror -Wno-unknown-pragmas -fdiagnostics-show-location=once-ffunction-sections -fdata-sections -g -fimplicit-templates -c /work/gnu/src/gcc-3.0 /egcs/libstdc++-v3/src/misc-inst.cc -o misc-inst.o -march=pentiumpro -O2
In file included from
/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/bits/ostream.tcc:364:
/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/bits/basic_ios.h: In instantiation of `std::basic_ostream<_CharT, _Traits>::tellp () [with _CharT = char, _Traits = std::char_traits<char>]':
/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/src/misc-inst.cc:116:   instantiated from here
/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/bits/basic_ios.h:125: Internal error #19991113.
/work/gnu/src/gcc-3.0/egcs/libstdc++-v3/bits/basic_ios.h:125: Internal compiler error in copy_body_r, 
at cp/optimize.c:321

The last one I tried is July 17. It worked with -O2.

Let me know if the preprocessed file is needed.

Thanks.

-- 
H.J. Lu (hjl@gnu.org)


More information about the Gcc-bugs mailing list