Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 453294 - x11-libs/pixman-0.28.0 USE=iwmmxt - configure: error: IWMMXT intrinsics not detected
Summary: x11-libs/pixman-0.28.0 USE=iwmmxt - configure: error: IWMMXT intrinsics not d...
Status: RESOLVED WORKSFORME
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: ARM Linux
: Normal normal (vote)
Assignee: Matt Turner
URL: https://bugs.freedesktop.org/show_bug...
Whiteboard:
Keywords:
Depends on: 462736
Blocks:
  Show dependency tree
 
Reported: 2013-01-21 07:56 UTC by Alex
Modified: 2015-02-21 21:14 UTC (History)
1 user (show)

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


Attachments
/var/tmp/portage/x11-libs/pixman-0.28.0/work/pixman-0.28.0_build/config.log (config.log,54.23 KB, text/plain)
2013-01-21 08:00 UTC, Alex
Details
iwmmxt-for-4.7.patch (iwmmxt-for-4.7.patch,192.06 KB, patch)
2013-03-08 16:49 UTC, Matt Turner
Details | Diff
gcc-4.8.2. pixman-0.32.4. build.log (build.log,39.27 KB, text/plain)
2014-02-13 12:20 UTC, Alex
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alex 2013-01-21 07:56:31 UTC
I try to compile pixman with the flag iwmmxt.
Added to the package.use line "x11-libs/pixman iwmmxt" and run:
# emerge pixman
Pixman compilation stops with the message:
checking whether to use ARM IWMMXT intrinsics... no
configure: error: IWMMXT intrinsics not detected

But:
hx4700 ~ # cat /proc/cpuinfo
Processor       : XScale-PXA270 rev 7 (v5l)
BogoMIPS        : 623.41
Features        : swp half thumb fastmult edsp iwmmxt
CPU implementer : 0x69
CPU architecture: 5TE
CPU variant     : 0x0
CPU part        : 0x411
CPU revision    : 7

Hardware        : HP iPAQ HX4700
Revision        : 0000
Serial          : 0000000000000000

Reproducible: Always




hx4700 ~ # emerge --info
Portage 2.1.11.31 (default/linux/arm/10.0, gcc-4.5.4, glibc-2.15-r3, 3.5.7-gentoo armv5tel)
=================================================================
System uname: Linux-3.5.7-gentoo-armv5tel-XScale-PXA270_rev_7_-v5l-with-gentoo-2.1
Timestamp of tree: Sun, 30 Dec 2012 00:45:01 +0000
ld GNU ld (GNU Binutils) 2.22
app-shells/bash:          4.2_p37
dev-lang/python:          2.7.3-r2, 3.2.3
dev-util/cmake:           2.8.9
dev-util/pkgconfig:       0.27.1
sys-apps/baselayout:      2.1-r1
sys-apps/openrc:          0.11.8
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.11.6
sys-devel/binutils:       2.22-r1
sys-devel/gcc:            4.5.4
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4-r1
sys-devel/make:           3.82-r4
sys-kernel/linux-headers: 3.6 (virtual/os-headers)
sys-libs/glibc:           2.15-r3
Repositories: gentoo
ACCEPT_KEYWORDS="arm"
ACCEPT_LICENSE="* -@EULA"
CBUILD="armv5te-iwmmxt-linux-gnueabi"
CFLAGS="-O2 -march=iwmmxt -mtune=iwmmxt -pipe"
CHOST="armv5te-iwmmxt-linux-gnueabi"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="${EPREFIX}/etc/gconf /etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -march=iwmmxt -mtune=iwmmxt -pipe"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS="-O2"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="ru_RU.UTF-8"
LC_ALL=""
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X acl arm berkdb bzip2 cli cracklib crypt cxx gdbm gpm iconv iwmmxt modules ncurses nls nptl pam pcre pppd readline session ssl tcpd unicode zlib" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en ru" PHP_TARGETS="php5-3" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_2" RUBY_TARGETS="ruby18 ruby19" USERLAND="GNU" VIDEO_CARDS="fbdev w100 pxafb" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, MAKEOPTS, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 1 Alex 2013-01-21 08:00:55 UTC
Created attachment 336316 [details]
/var/tmp/portage/x11-libs/pixman-0.28.0/work/pixman-0.28.0_build/config.log

This log added from /var/tmp/portage/x11-libs/pixman-0.28.0/work/pixman-0.28.0_build/config.log, because that is specified after the message when compiling.
Comment 2 Jeroen Roovers (RETIRED) gentoo-dev 2013-01-21 12:48:13 UTC
/usr/lib/gcc/armv5te-iwmmxt-linux-gnueabi/4.5.4/include/mmintrin.h:552:39: internal compiler error: in arm_expand_binop_builtin, at config/arm/arm.c:17922
Comment 3 Matt Turner gentoo-dev 2013-01-21 16:30:53 UTC
Hi Alex.

The problem is that gcc's support for iwMMXt intrinsics was broken for a very long time before gcc-4.7. Trying to use them causes an internal compiler error. I'm not sure how to handle this in the ebuild, since gcc-4.7 is masked.

If you'd like, I can help you work around this (you'll have to install gcc-4.7). Also, by default pixman builds iwMMXt code with -march=iwmmxt2 (since that's the processor I was targeting when I wrote it).

You can set EXTRA_ECONF (like is done at the bottom of http://wiki.gentoo.org/wiki/Gold) for pixman to EXTRA_ECONF="--disable-arm-iwmmxt2" and it will only build with iwmmxt(1).
Comment 4 Alex 2013-03-08 11:57:00 UTC
Hi, Matt.
I did:
hx4700 ~ # echo "sys-devel/gcc" >> /etc/portage/package.unmask
hx4700 ~ # echo "sys-devel/gcc ~arm" >> /etc/portage/package.keywords
hx4700 ~ # emerge linux-headers glibc binutils gcc-config gcc
hx4700 ~ # gcc-config -l
 [1] armv5te-iwmmxt-linux-gnueabi-4.5.4 *
 [2] armv5te-iwmmxt-linux-gnueabi-4.7.2
hx4700 ~ # gcc-config 2
hx4700 ~ # gcc-config -l
 [1] armv5te-iwmmxt-linux-gnueabi-4.5.4
 [2] armv5te-iwmmxt-linux-gnueabi-4.7.2 *
hx4700 ~ # echo "x11-libs/pixman pixman.conf" >> /etc/portage/package.env
hx4700 ~ # mkdir /etc/portage/env
hx4700 ~ # echo 'EXTRA_ECONF="--disable-arm-iwmmxt2"' >> /etc/portage/env/pixman.conf
hx4700 ~ # env-update && source /etc/profile
hx4700 ~ # emerge pixman

But the error is repeated, though the configuration is performed:
/var/tmp/portage/x11-libs/pixman-0.28.0/work/pixman-0.28.0/configure --prefix=/usr --build=armv5te-iwmmxt-linux-gnueabi --host=armv5te-iwmmxt-linux-gnueabi --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --disable-dependency-tracking --docdir=/usr/share/doc/pixman-0.28.0 --enable-shared --disable-static --disable-mmx --disable-sse2 --disable-vmx --disable-arm-neon --enable-arm-iwmmxt --disable-gtk --disable-arm-iwmmxt2
Comment 5 Matt Turner gentoo-dev 2013-03-08 16:49:51 UTC
Created attachment 341316 [details, diff]
iwmmxt-for-4.7.patch

Hi Alex,

Sorry -- I was somewhat mistaken. The iwMMXt support patch is in gcc-4.8 and a smaller fix was backported to (unreleased) gcc-4.7.3.

Attached is a patch that should apply to 4.7.2. It is what was committed to 4.8.
Comment 6 Matt Turner gentoo-dev 2013-03-22 21:31:51 UTC
gcc-4.8 is now released (with working iwMMXt support). Marking it as a blocker of this bug.
Comment 7 Matt Turner gentoo-dev 2013-06-22 20:53:58 UTC
I think gcc-4.7.3 (not hard masked) also will compile this code, but I have not tested it myself.
Comment 8 Alex 2014-02-13 12:20:40 UTC
Created attachment 370308 [details]
gcc-4.8.2. pixman-0.32.4. build.log
Comment 9 Alex 2014-02-13 12:24:26 UTC
gcc-4.8.2 compiling pixman with an error in attachment "gcc-4.8.2. pixman-0.32.4. build.log".
Comment 10 Chí-Thanh Christopher Nguyễn gentoo-dev 2014-02-13 12:59:08 UTC
(In reply to Alex from comment #9)
Your error appears not related to this bug report.
Comment 11 Alex 2014-02-13 13:18:01 UTC
(In reply to Chí-Thanh Christopher Nguyễn from comment #10)
Then the bug can be resolved to note, since gcc-4.8.2 initial error does not appear.
Thanks!
Comment 12 Matt Turner gentoo-dev 2014-02-13 17:21:32 UTC
I think that's because it didn't get to build pixman-mmx.c. :(

I had to hack the automake build system to make it work before, so it probably needs a fix-up.
Comment 13 Matt Turner gentoo-dev 2014-03-16 07:28:37 UTC
I just built with iwmmxt enabled using an ARM cross compiler. No problems encountered, so I can't reproduce.

CFLAGS="-O2 -march=armv7-a -mtune=marvell-pj4 -pipe" ./configure --disable-arm-neon --enable-arm-iwmmxt2 --host=armv5tel-unknown-linux-gnueabi --build=x86_64-pc-linux-gnu
Comment 14 Matt Turner gentoo-dev 2015-02-21 21:14:05 UTC
Appropriate versions of gcc are stable on ARM and I couldn't reproduce. Marking as WORKSFORME.