Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 78165 - libart_lgpl-2.3.16 can fall into an infinite loop when compiled with -ffast-math
Summary: libart_lgpl-2.3.16 can fall into an infinite loop when compiled with -ffast-math
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-01-15 19:30 UTC by Jonathan Briggs
Modified: 2005-04-24 23:51 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Briggs 2005-01-15 19:30:21 UTC
I found that when opening Nautilus to certain directories, Nautilus would freeze up.  I used gdb to discover that it was happening inside the function art_svp_intersector which is in /usr/lib/libart_lgpl_2.so.2.3.16

Further experiments revealed that the problem was fast-math.  Apparently the authors of libart_lgpl expected that if they assigned a value into a floating point variable, it would always exactly equal that value in the future!  Silly authors.  Because of differences between the format of floating point registers and memory storage this is NOT true.

My recommendation:
Fixing to code to run with -ffast-math looks too difficult.  I think filtering the fast-math flag in the libart_lgpl ebuild is the thing to do.

Reproducible: Always
Steps to Reproduce:
1. CFLAGS="-O3 -ffast-math" emerge libart_lgpl
2. Log in to Gnome 2.8.
3. Select the "Amaranth" theme.
4. killall nautilus (if it's running)
5. nautilus --browser
Actual Results:  
Nautilus froze and stopped responding.

Expected Results:  
Rendered pretty SVG icons for my viewing pleasure.

# emerge info
Portage 2.0.51-r12 (default-linux/x86/2004.3, gcc-3.4.3,
glibc-2.3.4.20041102-r0, 2.6.10 i686)
=================================================================
System uname: 2.6.10 i686 AMD Athlon(tm) MP 1900+
Gentoo Base System version 1.6.8
Python:              dev-lang/python-2.2.3-r5,dev-lang/python-2.3.4 [2.3.4 (#1,
Nov 13 2004, 22:08:50)]
ccache version 2.3 [enabled]
dev-lang/python:     2.2.3-r5, 2.3.4
sys-devel/autoconf:  2.59-r6, 2.13
sys-devel/automake:  1.8.5-r2, 1.5, 1.4_p6, 1.6.3, 1.7.9, 1.9.4
sys-devel/binutils:  2.15.92.0.2-r2
sys-devel/libtool:   1.5.10-r2
virtual/os-headers:  2.6.8.1-r2
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-O3 -march=athlon-mp -mfpmath=sse -msse -mmmx -m3dnow
-fomit-frame-pointer -funit-at-a-time -fweb -fprefetch-loop-arrays -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.3/env
/usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/lib/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="-O3 -march=athlon-mp -mfpmath=sse -msse -mmmx -m3dnow
-fomit-frame-pointer -funit-at-a-time -fweb -fprefetch-loop-arrays -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig buildpkg ccache distlocks sandbox sfperms"
GENTOO_MIRRORS="http://csociety-ftp.ecn.purdue.edu/pub/gentoo/
http://gentoo.llarian.net/ http://gentoo.ccccom.com http://128.213.5.34/gentoo/
http://gentoo.osuosl.org/ http://cudlug.cudenver.edu/gentoo/
http://gentoo.mirrors.pair.com/"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/usr/src"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="3dnow 3dnowex X acpi alsa apache2 apm avi berkdb bonobo cdparanoia cdr
crypt cups doc dv dvd dvdr dvdread eds encode esd evo f77 fam flac font-server
foomaticdb fortran gdbm gif glx gnome gphoto2 gpm gstreamer gtk gtk2 gtkhtml
guile hal imagemagick imap imlib ipv6 jack java jce jikes jpeg junit libg++
libwww mad maildir mikmod mmx mng motif mozilla mozsvg mpeg ncurses nls nptl
nptlonly nvidia offensive oggvorbis opengl oss pam pdflib perl physfs pic png
postgres python qt quicktime readline samba scanner sdl slang speex spell sse
ssl svg tcltk tcpd tetex theora tiff truetype truetype-fonts type1-fonts unicode
wmf x86 xml xml2 xmms xprint xv xvid xvmc yv12 zlib"
Unset:  LDFLAGS
Comment 1 foser (RETIRED) gentoo-dev 2005-01-16 15:11:54 UTC
Well, I'm fine with adding the restriction for now, but I think you should still report this problem in more detail upstream.
Comment 2 foser (RETIRED) gentoo-dev 2005-01-16 15:13:34 UTC
what strikes me as odd is that there's probably hundreds of ppl compiling with -ffast-math & using an svg theme, yet we don't get a host of reports about freezing gnome's.
Comment 3 Mike Gardiner (RETIRED) gentoo-dev 2005-04-24 23:51:14 UTC
No response.