Bug 6346 - xorg-server-1.0.1 compile error with CFLAGS="-march=athlon -mno-sse"
Summary: xorg-server-1.0.1 compile error with CFLAGS="-march=athlon -mno-sse"
Status: RESOLVED FIXED
Alias: None
Product: xorg
Classification: Unclassified
Component: Server/General (show other bugs)
Version: 7.0.0
Hardware: x86 (IA32) Linux (All)
: high normal
Assignee: Xorg Project Team
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-03-22 19:57 UTC by Jonathan Adamczewski
Modified: 2006-04-03 12:50 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
The fix - adding #ifdef guards to #include <xmmintrin.h> (306 bytes, patch)
2006-03-22 19:58 UTC, Jonathan Adamczewski
no flags Details | Splinter Review

Description Jonathan Adamczewski 2006-03-22 19:57:17 UTC
[This appears to have been touched upon in relation to bug 5093 - in fact, it is
mentioned in passing in
http://lists.freedesktop.org/archives/xorg/2005-July/008760.html linked from the
other bug.]

Compiling xorg-server for a Duron (Morgan) box, my CFLAGS include -march=athlon
-mno-sse because this processor does not support SSE instructions.  (this is a
shortcoming in gcc's -march option, but that's a problem for another day and
not strictly related to this bug).

The file xorg-server-1.0.1/fb/fbmmx.c contains flawed logic when it comes to
#including SSE intrinsic definitions from xmmintrin.h, and this causes a
compile time error when using -mno-sse.  The use of _mm_shuffle_pi16 and
_MM_SHUFFLE from xmmintrin.h are correctly contained in #ifdef USE_SSE, but the
#include is not.

The patch fixes this behaviour to allow compilation of the package.  I have yet
to test the result, but I see no reason for it to fail.

This is also at https://bugs.gentoo.org/show_bug.cgi?id=127136
Comment 1 Jonathan Adamczewski 2006-03-22 19:58:37 UTC
Created attachment 5013 [details] [review]
The fix - adding #ifdef guards to #include <xmmintrin.h>
Comment 2 Adam Jackson 2006-04-04 05:50:42 UTC
applied to HEAD and stable branch, thanks!


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.