[Mesa-dev] [Bug 91806] configure does not test whether assembler supports sse4.1

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Sun Aug 30 01:47:17 PDT 2015


https://bugs.freedesktop.org/show_bug.cgi?id=91806

            Bug ID: 91806
           Summary: configure does not test whether assembler supports
                    sse4.1
           Product: Mesa
           Version: git
          Hardware: Other
                OS: OpenBSD
            Status: NEW
          Severity: normal
          Priority: medium
         Component: Mesa core
          Assignee: mesa-dev at lists.freedesktop.org
          Reporter: jsg at openbsd.org
        QA Contact: mesa-dev at lists.freedesktop.org

The sse4.1 test does not seem to check whether the code can be assembled.
Changing AC_COMPILE_IFELSE to AC_LINK_IFELSE does not seem to change this.

With gcc 4.9 and binutils 2.17 which does not include sse4.1 instructions:

libtool: compile:  /usr/local/bin/egcc -DPACKAGE_NAME=\"Mesa\"
-DPACKAGE_TARNAME=\"mesa\" -DPACKAGE_VERSION=\"11.1.0-devel\"
"-DPACKAGE_STRING=\"Mesa 11.1.0-devel\""
"-DPACKAGE_BUGREPORT=\"https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa\""
-DPACKAGE_URL=\"\" -DPACKAGE=\"mesa\" -DVERSION=\"11.1.0-devel\"
-DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1
-DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1
-DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DLT_OBJDIR=\".libs/\"
-DYYTEXT_POINTER=1 -DHAVE___BUILTIN_BSWAP32=1 -DHAVE___BUILTIN_BSWAP64=1
-DHAVE___BUILTIN_CLZ=1 -DHAVE___BUILTIN_CLZLL=1 -DHAVE___BUILTIN_CTZ=1
-DHAVE___BUILTIN_EXPECT=1 -DHAVE___BUILTIN_FFS=1 -DHAVE___BUILTIN_FFSLL=1
-DHAVE___BUILTIN_POPCOUNT=1 -DHAVE___BUILTIN_POPCOUNTLL=1
-DHAVE___BUILTIN_UNREACHABLE=1 -DHAVE_FUNC_ATTRIBUTE_CONST=1
-DHAVE_FUNC_ATTRIBUTE_FLATTEN=1 -DHAVE_FUNC_ATTRIBUTE_FORMAT=1
-DHAVE_FUNC_ATTRIBUTE_MALLOC=1 -DHAVE_FUNC_ATTRIBUTE_PACKED=1
-DHAVE_FUNC_ATTRIBUTE_PURE=1 -DHAVE_FUNC_ATTRIBUTE_UNUSED=1
-DHAVE_FUNC_ATTRIBUTE_WARN_UNUSED_RESULT=1 -DHAVE_DLADDR=1
-DHAVE_CLOCK_GETTIME=1 -DHAVE_PTHREAD_PRIO_INHERIT=1 -DHAVE_PTHREAD=1
-DHAVE_SHA1_IN_LIBC=1 -DHAVE_LIBEXPAT=1 -I. -D__STDC_LIMIT_MACROS -DUSE_SSE41
-DDEBUG -DUSE_X86_64_ASM -DHAVE_SYS_SYSCTL_H -DHAVE_STRTOF -DHAVE_MKOSTEMP
-DHAVE_DLOPEN -DHAVE_POSIX_MEMALIGN -DHAVE_LIBDRM -DGLX_USE_DRM
-DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DHAVE_ALIAS -DHAVE_MINCORE
-DHAVE_LLVM=0x0305 -DMESA_LLVM_VERSION_PATCH=0 -I../../include -I../../src
-I../../src/glsl -I../../src/glsl -I../../src/glsl/nir -I../../src/glsl/glcpp
-I../../src/mesa -I../../src/mesa -I../../src/mesa/main -I../../src/mesa/main
-I../../src/mapi -I../../src/mapi -I../../src/gallium/include
-I../../src/gallium/auxiliary -I./x86-64 -I./x86-64 -I/usr/local/include
-I/usr/local/include/libelf -I/usr/local/include -D__STDC_CONSTANT_MACROS
-D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -fvisibility=hidden
-Werror=pointer-arith -Werror=vla -msse4.1 -g -O2 -Wall -std=c99
-Werror=implicit-function-declaration -Werror=missing-prototypes
-fno-strict-aliasing -fno-math-errno -fno-trapping-math -fno-builtin-memcmp -MT
main/libmesa_sse41_la-streaming-load-memcpy.lo -MD -MP -MF
main/.deps/libmesa_sse41_la-streaming-load-memcpy.Tpo -c
main/streaming-load-memcpy.c  -fPIC -DPIC -o
main/.libs/libmesa_sse41_la-streaming-load-memcpy.o
/tmp//ccVTPiZC.s: Assembler messages:
/tmp//ccVTPiZC.s:50: Error: no such instruction: `movntdqa (%rcx),%xmm3'
/tmp//ccVTPiZC.s:66: Error: no such instruction: `movntdqa -48(%rcx),%xmm2'
/tmp//ccVTPiZC.s:71: Error: no such instruction: `movntdqa -32(%rcx),%xmm1'
/tmp//ccVTPiZC.s:76: Error: no such instruction: `movntdqa -16(%rcx),%xmm0'
Makefile:2755: recipe for target
'main/libmesa_sse41_la-streaming-load-memcpy.lo' failed

from config.log:

configure:19147: /usr/local/bin/egcc -c -msse4.1 -g -O2 -Wall -std=c99
-Werror=implicit-function-declaration -Werror=missing-prototypes
-fno-strict-aliasing -fno-math-errno -fno-trapping-math -fno-builtin-memcmp
-I/usr/local/include -I/usr/local/include/libelf conftest.c >&5
conftest.c: In function 'main':
conftest.c:46:61: warning: variable 'c' set but not used
[-Wunused-but-set-variable]
     __m128i a = _mm_set1_epi32 (0), b = _mm_set1_epi32 (0), c;
                                                             ^
configure:19147: $? = 0

$ cat t.c                                                                 
#include <smmintrin.h>
int main () {
    __m128i a = _mm_set1_epi32 (0), b = _mm_set1_epi32 (0), c;
    c = _mm_max_epu32(a, b);
    return 0;
}
$ egcc -Wall -msse4.1 t.c 
t.c: In function 'main':
t.c:3:61: warning: variable 'c' set but not used [-Wunused-but-set-variable]
     __m128i a = _mm_set1_epi32 (0), b = _mm_set1_epi32 (0), c;
                                                             ^
/tmp//ccpOR1qO.s: Assembler messages:
/tmp//ccpOR1qO.s:24: Error: no such instruction: `pinsrd $1,%eax,%xmm1'
/tmp//ccpOR1qO.s:27: Error: no such instruction: `pinsrd $1,%eax,%xmm0'
/tmp//ccpOR1qO.s:44: Error: no such instruction: `pinsrd $1,%eax,%xmm1'
/tmp//ccpOR1qO.s:47: Error: no such instruction: `pinsrd $1,%eax,%xmm0'
/tmp//ccpOR1qO.s:58: Error: no such instruction: `pmaxud %xmm1,%xmm0'

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20150830/7183b480/attachment-0001.html>


More information about the mesa-dev mailing list