Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 225843 - x11-libs/pixman-0.11.4: fonts rendered are really really hardly legible
Summary: x11-libs/pixman-0.11.4: fonts rendered are really really hardly legible
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Highest normal (vote)
Assignee: Gentoo X packagers
URL: https://bugs.freedesktop.org/show_bug...
Whiteboard:
Keywords: Inclusion
Depends on:
Blocks:
 
Reported: 2008-06-11 08:00 UTC by Martin Mokrejš
Modified: 2008-10-29 14:02 UTC (History)
1 user (show)

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


Attachments
Screen part showing wrong rendering (pixman-kde-crapped-fonts.png,3.53 KB, image/png)
2008-06-11 13:48 UTC, Hanno Böck
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Mokrejš 2008-06-11 08:00:25 UTC
I have upgraded to recent pixman and my fonts rendered in xdm login window, but
later on also in opera, seamonkey were not readable. Luckily, not affected were fonts in xterm. I have recompiled freetype, cairo but no luck. In the end I can conclude that the cause is upgrade to pixman-0.11.4. emerge.log does not record (I believe anymore) the previous version being unmerged. Stepping back to 0.10.0 fixes the bug and recompilation of 0.11.4 re-introduces it again.

I tested gcc-4.2.4 and 4.3.1, the bug appears with pixman lib produced by both.

I have the following CPU:

$ cat /proc/cpuinfo 
processor       : 0
vendor_id       : GenuineIntel
cpu family      : 15
model           : 2
model name      : Mobile Intel(R) Pentium(R) 4 - M CPU 1.80GHz
stepping        : 7
cpu MHz         : 1200.000
cache size      : 512 KB
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 2
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe pebs bts sync_rdtsc
bogomips        : 2401.27
clflush size    : 64


And from the compile message I pick some which might be related to identify the cause:

>>> Emerging (1 of 1) x11-libs/pixman-0.11.4 to /
 * pixman-0.11.4.tar.bz2 RMD160 SHA1 SHA256 size ;-) ...                                                                            [ ok ]
 * checking ebuild checksums ;-) ...                                                                                                [ ok ]
 * checking auxfile checksums ;-) ...                                                                                               [ ok ]
 * checking miscfile checksums ;-) ...                                                                                              [ ok ]
 * checking pixman-0.11.4.tar.bz2 ;-) ...                                                                                           [ ok ]
>>> Unpacking source...
>>> Unpacking pixman-0.11.4.tar.bz2 to /var/tmp/portage/x11-libs/pixman-0.11.4/work
 * Running elibtoolize in: pixman-0.11.4
 *   Applying portage-1.5.10.patch ...
 *   Applying sed-1.5.6.patch ...
>>> Source unpacked.
>>> Compiling source in /var/tmp/portage/x11-libs/pixman-0.11.4/work/pixman-0.11.4 ...
 * econf: updating pixman-0.11.4/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating pixman-0.11.4/config.sub with /usr/share/gnuconfig/config.sub
./configure --prefix=/usr --host=i686-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --prefix=/usr --datadir=/usr/share --build=i686-pc-linux-gnu
...
checking whether to use MMX intrinsics... yes
checking whether to use SSE intrinsics... no
checking whether to use SSE2 intrinsics... yes
checking whether to use VMX/Altivec intrinsics... no
...
make[2]: Entering directory `/var/tmp/portage/x11-libs/pixman-0.11.4/work/pixman-0.11.4/pixman'
/bin/sh ../libtool --tag=CC   --mode=compile i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I..    -DPIXMAN_DISABLE_DEPRECATED -O2 -march=pentium4 -mmmx -msse -msse2 -fomit-frame-pointer -pipe -Wall -fvisibility=hidden -MT libpixman_1_la-pixman-access.lo -MD -MP -MF .deps/libpixman_1_la-pixman-access.Tpo -c -o libpixman_1_la-pixman-access.lo `test -f 'pixman-access.c' || echo './'`pixman-access.c
mkdir .libs
...

Both pixman libs configure scripts decide to use only MMX and SSE2, not SSE.
Maybe that is not a bug with configure at all, a just thought. Definitely, my system does support these cpu flags. I did not have a look but hope the ebuild would filter out -msse3 CFLAGS if I would have had one.
Comment 1 Martin Mokrejš 2008-06-11 08:00:47 UTC
Portage 2.1.5.4 (default-linux/x86/2007.0/desktop, gcc-4.3.1, glibc-2.8_p20080602-r0, 2.6.24.7 i686)
=================================================================
System uname: 2.6.24.7 i686 Mobile Intel(R) Pentium(R) 4 - M CPU 1.80GHz
Timestamp of tree: Tue, 10 Jun 2008 10:15:01 +0000
distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
app-shells/bash:     3.2_p39
dev-java/java-config: 1.3.7, 2.1.6
dev-lang/python:     2.5.2-r4
dev-python/pycrypto: 2.0.1-r6
sys-apps/baselayout: 2.0.0
sys-apps/openrc:     0.2.5
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.62
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.1-r1
sys-devel/binutils:  2.18-r1
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   2.2.4
virtual/os-headers:  2.6.25-r4
ACCEPT_KEYWORDS="x86 ~x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=pentium4 -mmmx -msse -msse2 -fomit-frame-pointer -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /var/bind /var/qmail/alias /var/qmail/control /var/spool/torque /var/vpopmail/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-O2 -march=pentium4 -mmmx -msse -msse2 -fomit-frame-pointer -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks parallel-fetch sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://gentoo.mirror.web4u.cz"
LDFLAGS=""
LINGUAS="en cs cz"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="7zip R X Xaw3d a52 aac aalib ace acl acpi alsa amr amrnb amrwb apache2 audacious audiofile bash-completion bcmath berkdb blas boost bzip2 cairo cblas cddb cdparanoia cdr clamav cli colordiff compress cpio cracklib crypt cscope css ctype cups curl curlwrappers cxx dbus dga dia directfb djbfft dri dts dv dvb dvd dvdr dvdread eds emacs emboss emf enblend encode enscript exif expat fam fame fat fbcon ffmpeg fftw firefox flac flash foomaticdb fortran fpx ftp gcj gd gdbm ggi gif gimp gimpprint glibc-compat20 glibc-omitfp glitz glut gmp gnuplot gnutls gpgme gphoto2 gpm graphviz gs gsl gstreamer gtk gtkhtml hal hdf hdf5 i8x0 icc iconv icu id3 ieee1394 ifc imagemagick imlib inifile innodb isdnlog ithreads jack java javascript jbig jikes jpeg jpeg2k kdtree kerberos lame lapack lcms leim libcaca libedit libwww live lzo lzw mad maildir matroska mhash midi mikmod mime ming mjpeg mmap mmx mng mod_python modperl modplug motif mozilla moznoirc mp2 mp3 mp4 mpeg mpi mpi_njtree mplayer mudflap mule musepack mxdatetime mysql mysqli ncurses netcdf netpbm network nls nntp nptl nptlonly nsplugin ntfs numeric ogg opengl openmp pam pango pcmcia pcntl pcre pdf perl plotutils plugin png pnm postproc postscript ppds pppd procmail pymol python qt3 qt3support qt4 quicktime rar raw readline real recode reflection reiserfs rpm rtc samba sasl scanner scp seamonkey server session sftp sift slp smime sndfile soap sockets spell spl sqlite srt sse sse2 ssl subtitles subversion svg svgz sysfs sysvipc t1lib tcl tcpd tetex theora threads tidy tiff tk transcode truetype unicode urandom usb userlocales uuencode v4l v4l2 vcd vim-syntax vim-with-x vorbis wifi win32codecs wmf wxwindows x264 x86 xanim xcf xfs xft xinetd xml xorg xpm xprint xsl xslt xv xvid xvmc yv12 zip zlib" ALSA_CARDS="intel-8x0m" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config mem_cache mime mime_magic rewrite setenvif speling status unique_id userdir usertrack vhost_alias negotiation" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en cs cz" USERLAND="GNU" VIDEO_CARDS="radeon"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, MAKEOPTS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 2 Hanno Böck gentoo-dev 2008-06-11 13:48:30 UTC
Created attachment 156359 [details]
Screen part showing wrong rendering
Comment 3 Donnie Berkholz (RETIRED) gentoo-dev 2008-06-11 20:02:07 UTC
Hanno already mentioned this on the xorg mailing list. It would also help if you'd file a bug at bugs.freedesktop.org in the xorg product, because we won't be doing the fixing here. Please search for / file a bug and reopen this one once it's resolved upstream.
Comment 4 Martin Mokrejš 2008-06-11 20:33:37 UTC
https://bugs.freedesktop.org/show_bug.cgi?id=16310
Comment 5 Balint Dobai-Pataky 2008-06-13 12:50:01 UTC
same here on amd64
Comment 6 Donnie Berkholz (RETIRED) gentoo-dev 2008-06-16 19:47:46 UTC
I just masked pixman 0.11* till this gets fixed.
Comment 7 Martin Mokrejš 2008-06-27 14:54:09 UTC
--- Comment #4 from Søren Sandmann Pedersen <sandmann@daimi.au.dk>  2008-06-26 09:22:45 PST ---
In pixman-0.11.6, the sse2 fast path code can be disabled at configure time:

   configure --disable-sse2

If someone could test and see if this makes the bug go away, that would be
interesting.

Also interesting would be to know whether the bug depends on font rendering
configuration, in particular whether it happens when the font is set to
something other than subpixel antialiasing.
Comment 8 Doug Goldstein (RETIRED) gentoo-dev 2008-07-02 20:50:31 UTC
(In reply to comment #7)
> --- Comment #4 from Søren Sandmann Pedersen <sandmann@daimi.au.dk>  2008-06-26
> 09:22:45 PST ---
> In pixman-0.11.6, the sse2 fast path code can be disabled at configure time:
> 
>    configure --disable-sse2
> 
> If someone could test and see if this makes the bug go away, that would be
> interesting.
> 
> Also interesting would be to know whether the bug depends on font rendering
> configuration, in particular whether it happens when the font is set to
> something other than subpixel antialiasing.
> 

0.11.6 is in the tree with USE="altivec mmx sse2", so give it a try.
Comment 9 Martin Mokrejš 2008-07-11 21:15:37 UTC
Upstream provided a patch:

--- Comment #7 from Stefan Dirsch 2008-07-11 12:27:05 PST ---
Created an attachment (id=17640)
 --> (http://bugs.freedesktop.org/attachment.cgi?id=17640)
Only fixed in git
Comment 10 Doug Goldstein (RETIRED) gentoo-dev 2008-07-17 20:11:44 UTC
fixed in 0.11.8
Comment 11 Martin Mokrejš 2008-07-18 15:40:33 UTC
>>> Emerging (1 of 1) x11-libs/pixman-0.11.8 to /
>>> Downloading 'http://gentoo.mirror.web4u.cz/distfiles/pixman-0.11.8.tar.bz2'
--2008-07-18 17:23:31--  http://gentoo.mirror.web4u.cz/distfiles/pixman-0.11.8.tar.bz2
Resolving gentoo.mirror.web4u.cz... 81.91.81.13
Connecting to gentoo.mirror.web4u.cz|81.91.81.13|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 360229 (352K) [application/x-bzip]
Saving to: `/usr/portage/distfiles/pixman-0.11.8.tar.bz2'

100%[============================================================================================================================================================================================>] 360,229      555K/s   in 0.6s    

2008-07-18 17:23:32 (555 KB/s) - `/usr/portage/distfiles/pixman-0.11.8.tar.bz2' saved [360229/360229]

 * pixman-0.11.8.tar.bz2 RMD160 SHA1 SHA256 size ;-) ...                                                                                                                                                                        [ ok ]
 * checking ebuild checksums ;-) ...                                                                                                                                                                                            [ ok ]
 * checking auxfile checksums ;-) ...                                                                                                                                                                                           [ ok ]
 * checking miscfile checksums ;-) ...                                                                                                                                                                                          [ ok ]
 * checking pixman-0.11.8.tar.bz2 ;-) ...                                                                                                                                                                                       [ ok ]
>>> Unpacking source...
>>> Unpacking pixman-0.11.8.tar.bz2 to /var/tmp/portage/x11-libs/pixman-0.11.8/work
 * Running elibtoolize in: pixman-0.11.8
 *   Applying portage-1.5.10.patch ...
 *   Applying sed-1.5.6.patch ...
>>> Source unpacked.
>>> Compiling source in /var/tmp/portage/x11-libs/pixman-0.11.8/work/pixman-0.11.8 ...
 * econf: updating pixman-0.11.8/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating pixman-0.11.8/config.sub with /usr/share/gnuconfig/config.sub
./configure --prefix=/usr --host=i686-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --prefix=/usr --datadir=/usr/share --disable-vmx --enable-mmx --enable-sse2 --disable-gtk --build=i686-pc-linux-gnu
...
checking whether to use MMX intrinsics... yes
checking whether to use SSE intrinsics... no
checking whether to use SSE2 intrinsics... yes
configure: error: SSE2 intrinsics not detected

!!! Please attach the following file when seeking support:
!!! /var/tmp/portage/x11-libs/pixman-0.11.8/work/pixman-0.11.8/config.log
 * 
 * ERROR: x11-libs/pixman-0.11.8 failed.
 * Call stack:
 *               ebuild.sh, line   49:  Called src_compile
 *             environment, line 2946:  Called x-modular_src_compile
 *             environment, line 3730:  Called x-modular_src_configure
 *             environment, line 3739:  Called econf '--prefix=/usr' '--datadir=/usr/share' '--disable-vmx' '--enable-mmx' '--enable-sse2' '--disable-gtk'
 *               ebuild.sh, line  526:  Called die
 * The specific snippet of code:
 *                      die "econf failed"
 *  The die message:
 *   econf failed
 * 
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/x11-libs/pixman-0.11.8/temp/build.log'.



config.log says:
configure:19913: checking whether to use SSE intrinsics
configure:19940: i686-pc-linux-gnu-gcc -c -O2 -march=pentium4 -mmmx -msse -msse2 -fomit-frame-pointer -pipe -Wall -fvisibility=hidden -msse -mmmx -Winline --param inline-unit-growth=10000 --param large-function-growth=10000  conft
est.c >&5
conftest.c:6:2: error: #error "Need x86-64 for SSE"
configure:19946: $? = 1
configure: failed program was:
| 
| #if defined(__GNUC__) && (__GNUC__ < 3 || (__GNUC__ == 3 && __GNUC_MINOR__ < 4))
| #error "Need GCC >= 3.4 for SSE intrinsics"
| #endif
| #if !defined(__amd64__) && !defined(__x86_64__)
| #error "Need x86-64 for SSE"
| #endif
| #include <mmintrin.h>
| #include <xmmintrin.h>
| int main () {
|     __m64 v = _mm_cvtsi32_si64 (1);
|     v = _mm_shuffle_pi16 (v, _MM_SHUFFLE(3, 3, 3, 3));
|     return _mm_cvtsi64_si32 (v);
| }
configure:19961: result: no
configure:19991: checking whether to use SSE2 intrinsics
configure:20016: i686-pc-linux-gnu-gcc -c -O2 -march=pentium4 -mmmx -msse -msse2 -fomit-frame-pointer -pipe -Wall -fvisibility=hidden -msse2 -mmmx -msse2 -Winline --param inline-unit-growth=10000 --param large-function-growth=1000
0 --param  max-inline-insns-single=6000  conftest.c >&5
conftest.c: In function 'main':
conftest.c:10: warning: 'a' is used uninitialized in this function
conftest.c:10: warning: 'b' is used uninitialized in this function
configure:20022: $? = 0
configure:20058: result: yes
configure:20061: error: SSE2 intrinsics not detected

Comment 12 Martin Mokrejš 2008-07-18 18:58:10 UTC
--- Comment #11 from Søren Sandmann Pedersen <sandmann@daimi.au.dk>  2008-07-18 11:45:40 PST ---

diff --git a/configure.ac b/configure.ac
index 05e66ae..6dcffb1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -250,7 +250,7 @@ if test $have_sse2_intrinsics = yes ; then
 fi

 AC_MSG_RESULT($have_sse2_intrinsics)
-if test $enable_sse2 = yes && test $have_sse_intrinsics = no ; then
+if test $enable_sse2 = yes && test $have_sse2_intrinsics = no ; then
    AC_MSG_ERROR([SSE2 intrinsics not detected])
 fi

Comment 13 Rémi Cardona (RETIRED) gentoo-dev 2008-10-29 14:02:24 UTC
Newer ebuilds have some logic in place to make sure you don't use sse2 without the correct compiler.

Fixed