On Mon, Dec 8, 2014 at 1:59 PM, Ian Romanick <i...@freedesktop.org> wrote: > On 12/08/2014 01:56 PM, Matt Turner wrote: >> On Mon, Dec 8, 2014 at 1:54 PM, Ian Romanick <i...@freedesktop.org> wrote: >>>> diff --git a/configure.ac b/configure.ac >>>> index b0df1bb..7dc435a 100644 >>>> --- a/configure.ac >>>> +++ b/configure.ac >>>> @@ -253,8 +253,9 @@ AC_SUBST([VISIBILITY_CXXFLAGS]) >>>> dnl >>>> dnl Optional flags, check for compiler support >>>> dnl >>>> +SSE41_CFLAGS="-msse4.1" >>>> save_CFLAGS="$CFLAGS" >>>> -CFLAGS="-msse4.1 $CFLAGS" >>>> +CFLAGS="$SSE41_CFLAGS $CFLAGS" >>>> AC_COMPILE_IFELSE([AC_LANG_SOURCE([[ >>>> #include <smmintrin.h> >>>> int main () { >>>> @@ -474,6 +475,12 @@ fi >>>> dnl >>>> dnl Arch/platform-specific settings >>>> dnl >>>> +case "$target_cpu" in >>>> + i?86) >>>> + SSE41_CFLAGS="$SSE41_CFLAGS -mstackrealign" >>>> +;; >>>> +esac >>> >>> Should we only add -mstackrealign if SSE41_CFLAGS is not empty? >> >> It looks like it's unconditionally set. > > Right... I'm asking if we should conditionally add it instead. Is there > any harm in doing -mstackrealign when it's not needed?
Ah, I see. Unclear whether -mstackrealign does anything on x86-64. I do see some reports like [1] or [2] where some version of gcc errored out with "error: -mstackrealign not supported in the 64bit mode" or ICE'd so I suspect we shouldn't use it unconditionally. [1] http://tremulous.net/forum/index.php?topic=16205.10;wap2 [2] https://www.mail-archive.com/gcc-bugs@gcc.gnu.org/msg256007.html _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev