Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 110173 - [4.0/ICE] mpfr on amd64 with -O2 -ftracer
Summary: [4.0/ICE] mpfr on amd64 with -O2 -ftracer
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Toolchain Maintainers
URL: http://gcc.gnu.org/bugzilla/show_bug....
Whiteboard: 4.0.2-r3
Keywords:
Depends on:
Blocks:
 
Reported: 2005-10-22 12:59 UTC by Jory A. Pratt
Modified: 2005-12-30 12:49 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
preproccessed output (ccrGqvaW.out,68.67 KB, text/plain)
2005-10-22 13:05 UTC, Jory A. Pratt
Details
mpfr-2.2.0_p4.diff (mpfr-2.2.0_p4.diff,576 bytes, text/plain)
2005-10-24 11:38 UTC, Jory A. Pratt
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jory A. Pratt 2005-10-22 12:59:05 UTC
internal compiler error: in extract_insn

Reproducible: Always
Steps to Reproduce:
1. have gcc-4.0.2 installed
2. emerge mpfr
3.

Actual Results:  
 x86_64-pc-linux-gnu-gcc -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1
-DTIME_WITH_SYS_TIME=1 -DHAVE_STDARG=1 -DHAVE_SYS_TIME_H=1 -DHAVE_SETLOCALE=1
-DHAVE_GETTIMEOFDAY=1 -DMPFR_HAVE_FESETROUND=1 -DHAVE_DENORMS=1 -DHAVE_FLOOR=1
-DHAVE_CEIL=1 -DHAVE_LDOUBLE_IEEE_EXT_LITTLE=1 -DHAVE_ALLOCA_H=1 -I. -I. -O2
-march=athlon64 -mtune=athlon64 -fomit-frame-pointer -ftracer
-fprefetch-loop-arrays -pipe -MT pow_ui.lo -MD -MP -MF .deps/pow_ui.Tpo -c
pow_ui.c  -fPIC -DPIC -o .libs/pow_ui.o
pow_ui.c: In function 'mpfr_pow_ui':
pow_ui.c:160: error: unrecognizable insn:
(insn 786 279 281 34 (set (reg:CCZ 17 flags)
        (compare:CCZ (and:DI (reg/v:DI 102 [ n ])
                (const_int 4611686018427387904 [0x4000000000000000]))
            (const_int 0 [0x0]))) -1 (nil)
    (nil))
pow_ui.c:160: internal compiler error: in extract_insn, at recog.c:2020



Portage 2.0.53_rc6 (default-linux/amd64/2005.1, gcc-4.0.2,
glibc-2.3.5.20050722-r0, 2.6.13-gentoo-r4 x86_64)
=================================================================
System uname: 2.6.13-gentoo-r4 x86_64 AMD Sempron(tm) Processor 3200+
Gentoo Base System version 1.12.0_pre9
ccache version 2.4 [enabled]
dev-lang/python:     2.3.5, 2.4.2
sys-apps/sandbox:    1.2.13
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.20
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=athlon64 -mtune=athlon64 -fomit-frame-pointer -ftracer
-fprefetch-loop-arrays -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=athlon64 -mtune=athlon64 -fomit-frame-pointer -ftracer
-fprefetch-loop-arrays -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig candy ccache cvs distlocks sandbox sfperms
strict userpriv usersandbox"
GENTOO_MIRRORS="http://distfiles.gentoo.org
http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LDFLAGS="-Wl,-O1 -Wl,--sort-common"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/home/gentoo"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="amd64 X acpi alsa avi berkdb bitmap-fonts crypt cups dvd dvdr dvdread
emboss encode fam foomaticdb gif gnome gpm gstreamer gtk gtk2 imlib ipv6 java
jpeg lzw lzw-tiff motif mp3 mpeg ncurses nls nptl nptlonly nsplugin ogg opengl
pam pdflib perl pic png python quicktime readline sdl spell ssl tcpd tiff
truetype truetype-fonts type1-fonts udev usb userlocales vorbis xinerama xml2
xpm xv zlib userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, LANG, LC_ALL, LINGUAS, MAKEOPTS
Comment 1 Jory A. Pratt 2005-10-22 13:05:06 UTC
Created attachment 71222 [details]
preproccessed output
Comment 2 SpanKY gentoo-dev 2005-10-22 16:48:43 UTC
not a bug in mpfr

if you drop the -ftracer and -fprefetch-loop-arrays does it work ?
Comment 3 Jory A. Pratt 2005-10-24 11:38:39 UTC
Created attachment 71347 [details]
mpfr-2.2.0_p4.diff

a small change to filter -ftracer from ebuild resolves bug.
Comment 4 Mark Loeser (RETIRED) gentoo-dev 2005-10-24 11:54:10 UTC
Not exactly my ideal solution.  There are some ICEs still present, possibly from
my patchset.  This might be another one that is triggered by those.
Comment 5 SpanKY gentoo-dev 2005-10-24 12:14:52 UTC
yeah, i'm not really for filtering flags either
Comment 6 Homer Parker (RETIRED) gentoo-dev 2005-10-24 14:32:09 UTC
I tested in a 2005.1 chroot with gcc updated, and packages out of portage, pu
patch from here. With:

CFLAGS="-march=k8 -fomit-frame-pointer -Os -pipe -ftracer"

It compiled fine, Anarchy asked me to test with:

CFLAGS="-O2 -march=athlon64 -mtune=athlon64 -fomit-frame-pointer -ftracer
-fprefetch-loop-arrays -pipe"

That didn't go so well:

ow_ui.c: In function 'mpfr_pow_ui':
pow_ui.c:160: error: unrecognizable insn:
(insn 786 279 281 34 (set (reg:CCZ 17 flags)
        (compare:CCZ (and:DI (reg/v:DI 102 [ n ])
                (const_int 4611686018427387904 [0x4000000000000000]))
            (const_int 0 [0x0]))) -1 (nil)
    (nil))
pow_ui.c:160: internal compiler error: in extract_insn, at recog.c:2020

emerge --info
Portage 2.0.51.22-r3 (default-linux/amd64/2005.1, gcc-4.0.2, glibc-2.3.5-r0,
2.6.13-ck8 x86_64)
=================================================================
System uname: 2.6.13-ck8 x86_64 AMD Athlon(tm) 64 Processor 3400+
Gentoo Base System version 1.6.12
dev-lang/python:     2.3.5
sys-apps/sandbox:    1.2.11
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.5
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.18-r1
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=k8 -fomit-frame-pointer -Os -pipe -ftracer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.4/env
/usr/kde/3.4/share/config /usr/kde/3.4/shutdown /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/lib64/mozilla/defaults/pref /usr/share/config
/usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/
/usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/
/usr/share/texmf/xdvi/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=k8 -fomit-frame-pointer -Os -pipe -ftracer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks sandbox sfperms strict"
GENTOO_MIRRORS="ftp://gentoo.netnitco.net/pub/mirrors/gentoo/source/
ftp://mirrors.tds.net/gentoo ftp://gentoo.ccccom.com"
LC_ALL="en_US.UTF-8"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="amd64 alsa avi berkdb bitmap-fonts crypt cups eds emboss encode foomaticdb
fortran gif gnome gpm gstreamer gtk gtk2 imlib ipv6 jpeg lzw lzw-tiff mp3 mpeg
ncurses nls opengl pam pdflib perl png python qt quicktime readline sdl spell
ssl tcpd tiff truetype-fonts type1-fonts udev usb userlocales xpm xv zlib
userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, LANG, LDFLAGS, LINGUAS
Comment 7 Mark Loeser (RETIRED) gentoo-dev 2005-12-29 23:17:03 UTC
Fixed, will be in the next patchset.
Comment 8 Jory A. Pratt 2005-12-30 12:19:10 UTC
This is far from fixed until it is in the tree!
Comment 9 Mark Loeser (RETIRED) gentoo-dev 2005-12-30 12:49:02 UTC
It will be in the tree when I add the next patchset.  Its fixed.