Bug 55519 - Failed iwmmxt2 compile with .deps error
Summary: Failed iwmmxt2 compile with .deps error
Status: RESOLVED MOVED
Alias: None
Product: pixman
Classification: Unclassified
Component: pixman (show other bugs)
Version: 0.26.x
Hardware: ARM All
: medium normal
Assignee: Søren Sandmann Pedersen
QA Contact: Søren Sandmann Pedersen
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-10-01 22:44 UTC by Daniel Drake
Modified: 2018-06-05 15:28 UTC (History)
4 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Full build log (23.77 KB, text/plain)
2012-10-01 22:44 UTC, Daniel Drake
Details

Description Daniel Drake 2012-10-01 22:44:32 UTC
Created attachment 67955 [details]
Full build log

Compiling pixman-0.26.2 on gcc-4.8 on F18 fails with:


  CC     libpixman_iwmmxt_la-pixman-mmx.lo
pixman-mmx.c:3635:1: fatal error: opening dependency file .deps/libpixman_iwmmxt_la-pixman-mmx.Tpo: No such file or directory
 }
 ^
compilation terminated.
make[3]: *** [libpixman_iwmmxt_la-pixman-mmx.lo] Error 1
Comment 1 Søren Sandmann Pedersen 2012-10-02 22:47:09 UTC
I suspect this is some issue with the build system, and not with pixman itself.
Comment 2 Daniel Drake 2012-10-03 14:34:24 UTC
Note that pixman has some weird build rules for this file which may be contributing.
Comment 3 Søren Sandmann Pedersen 2012-10-11 05:08:36 UTC
Is this reproducible outside of mock? If not, I don't think this can be debugged upstream.
Comment 4 Daniel Drake 2012-10-14 18:32:11 UTC
Yes, same error. I'm looking into the possibility of adding a -mwiwmmxt2 flag to gcc (like -mmmx) that could be included anywhere in the command line, this would allow us to remove the custom build rules.
Comment 5 Matt Turner 2013-01-28 07:09:15 UTC
I can't reproduce with pixman-0.26.2, 0.28.0, or from git. I just ran ./configure from the extracted tarballs and did not rerun autogen.sh.

I do notice in your log:

> + echo 'Patch #1 (iwmmxt2.patch):'
> Patch #1 (iwmmxt2.patch):
> + /usr/bin/patch -s -p1 --fuzz=0
> + /usr/bin/cat /builddir/build/SOURCES/iwmmxt2.patch
> + exit 0

I wonder what this is doing? No patching should be necessary to compile pixman with iwmmxt.

(In reply to comment #4)
> Yes, same error. I'm looking into the possibility of adding a -mwiwmmxt2
> flag to gcc (like -mmmx) that could be included anywhere in the command
> line, this would allow us to remove the custom build rules.

That would be very nice.
Comment 6 Peter 2013-02-21 21:56:02 UTC
We're seeing build errors that may be this on Fedora 19 with gcc 4.8 on ARM

http://arm.koji.fedoraproject.org/koji/taskinfo?taskID=1455953
Comment 7 David Heidelberg (okias) 2013-11-16 22:18:03 UTC
tested on crossdev amd64=> armv5te. Same situation with gcc 4.7 and 4.8.

Disabling iwmmxt use flag (gentoo system) helped.
Comment 8 Matt Turner 2014-03-16 07:28:26 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 9 Siarhei Siamashka 2014-09-21 20:00:08 UTC
(In reply to comment #5)
> (In reply to comment #4)
> > Yes, same error. I'm looking into the possibility of adding a -mwiwmmxt2
> > flag to gcc (like -mmmx) that could be included anywhere in the command
> > line, this would allow us to remove the custom build rules.
> 
> That would be very nice.

Also it would be nice to have some reference for tracking. Maybe a link to gcc bugzilla? We need to be sure that the upstream gcc developers are aware of the problem. Otherwise we may wait essentially forever and nothing is going to happen.
Comment 10 Petr Cvek 2017-12-04 20:47:48 UTC
This bug is still existing in v0.34.0. It occurs with every GCC version I've tried in the last 3 years. The last GCC version is development version 8.0. Pixman code for (at least v1) iwmmxt seems to work. No autovectorization for iwmmxt has been added into GCC since https://bugs.freedesktop.org/show_bug.cgi?id=55519#c4 (--enable-arm-iwmmxt is still relevant)

I think I was able to locate the problem to the relevant configure flags.

Steps to reproduce:

1) have an unmodified source and ./configure from https://www.cairographics.org/releases/

2) have (probably) any GCC capable of ARM+iwmmxt compilation

3) run ./configure for cross compilation with --disable-dependency-tracking and one or both of these flags --enable-arm-iwmmxt --enable-arm-iwmmxt2

4) run make (in single job mode)

5) 
  CC       libpixman_iwmmxt_la-pixman-mmx.lo
pixman-mmx.c:4147:1: fatal error: opening dependency file .deps/libpixman_iwmmxt_la-pixman-mmx.Tpo: No such file or directory
 }
 ^
compilation terminated.
make[2]: *** [Makefile:1123: libpixman_iwmmxt_la-pixman-mmx.lo] Error 1
make[2]: Leaving directory '/mnt/hd/programy/htc/linux_magician/softs/pixman/orig/pixman-0.34.0/pixman'

notice1) Iwmmxt support is autodetected (on valid ARM compiler), so you don't have to put any of --enable-arm-iwmmxt(2) flags, for example this:

./configure --host=arm-unknown-linux-gnueabi --with-sysroot=/root/mobil/htc/linux_magician/kernel_source/_buildroot/buildroot-2017.08.1_armv5te_final/output/staging --disable-arm-iwmmxt2 --disable-dependency-tracking

fails to compile too

notice2) If you manually create pixman/.deps directory and rerun make, the compilation will succeed

notice3) If you run make -j N multiple jobs, the compilation will sometimes work, probably as .deps will be created before libpixman_iwmmxt_la-pixman-mmx.Tpo is requested

notice4) Using --enable-dependency-tracking will create .deps directory, so the compilation will have success

notice5) --disable-dependency-tracking is used by Buildroot by default, so any pixman compilation for PXA27x and higher (which have iwmmxt) will fail there
Comment 11 GitLab Migration User 2018-06-05 15:28:32 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/pixman/pixman/issues/26.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.