Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation fails with clang due to intrinsics #6

Closed
tmatth opened this issue Jul 24, 2015 · 3 comments
Closed

Compilation fails with clang due to intrinsics #6

tmatth opened this issue Jul 24, 2015 · 3 comments

Comments

@tmatth
Copy link

tmatth commented Jul 24, 2015

Compiler errors with Debian clang version 3.5.2-1 with target: x86_64-pc-linux-gnu

$>CC=clang make
...
In file included from enc/encode_block.c:41:
In file included from enc/write_bits.h:42:
In file included from common/common_block.h:31:
In file included from common/simd.h:132:
In file included from common/simd/v128_intrinsics_x86.h:32:
common/simd/v64_intrinsics_x86.h:110:12: error: argument to '__builtin_ia32_psrldqi128' must be a constant integer
; (__m128i)__builtin_ia32_psrldqi128(__a, (c)*8); }) : b;
           ^                              ~~~~~
common/simd/v64_intrinsics_x86.h:110:12: error: can't convert between vector and non-scalar values ('void' and 'v64' (aka '__m128i'))
  return c ? __extension__ ({
           ^ ~~~~~~~~~~~~~~~~
common/simd/v64_intrinsics_x86.h:504:12: error: argument to '__builtin_ia32_pslldqi128' must be a constant integer
; (__m128i)__builtin_ia32_pslldqi128(__a, (c)*8); });
           ^                              ~~~~~
common/simd/v64_intrinsics_x86.h:504:10: error: returning 'void' from a function with incompatible result type 'v64' (aka '__m128i')
  return __extension__ ({
         ^~~~~~~~~~~~~~~~
common/simd/v64_intrinsics_x86.h:508:12: error: argument to '__builtin_ia32_psrldqi128' must be a constant integer
; (__m128i)__builtin_ia32_psrldqi128(__a, (c + 8)*8); });
           ^                              ~~~~~~~~~
common/simd/v64_intrinsics_x86.h:508:10: error: returning 'void' from a function with incompatible result type 'v64' (aka '__m128i')
  return __extension__ ({
         ^~~~~~~~~~~~~~~~
In file included from enc/encode_block.c:41:
In file included from enc/write_bits.h:42:
In file included from common/common_block.h:31:
In file included from common/simd.h:132:
common/simd/v128_intrinsics_x86.h:89:12: error: argument to '__builtin_ia32_psrldqi128' must be a constant integer
; (__m128i)__builtin_ia32_psrldqi128(__a, (c)*8); }), __extension__ ({
           ^                              ~~~~~
common/simd/v128_intrinsics_x86.h:89:12: error: argument to '__builtin_ia32_pslldqi128' must be a constant integer
; (__m128i)__builtin_ia32_pslldqi128(__a, (16 - c)*8); })) : b;
           ^                              ~~~~~~~~~~
common/simd/v128_intrinsics_x86.h:89:27: error: passing 'void' to parameter of incompatible type '__m128i' (vector of 2 'long long' values)
  return c ? _mm_or_si128(__extension__ ({
                          ^~~~~~~~~~~~~~~~
/usr/include/clang/3.5.2/include/emmintrin.h:817:22: note: passing argument to parameter '__a' here
_mm_or_si128(__m128i __a, __m128i __b)
                     ^
In file included from enc/encode_block.c:41:
In file included from enc/write_bits.h:42:
In file included from common/common_block.h:31:
In file included from common/simd.h:132:
common/simd/v128_intrinsics_x86.h:528:12: error: argument to '__builtin_ia32_pslldqi128' must be a constant integer
; (__m128i)__builtin_ia32_pslldqi128(__a, (c)*8); });
           ^                              ~~~~~
common/simd/v128_intrinsics_x86.h:528:10: error: returning 'void' from a function with incompatible result type 'v128' (aka '__m128i')
  return __extension__ ({
         ^~~~~~~~~~~~~~~~
common/simd/v128_intrinsics_x86.h:532:12: error: argument to '__builtin_ia32_psrldqi128' must be a constant integer
; (__m128i)__builtin_ia32_psrldqi128(__a, (c)*8); });
           ^                              ~~~~~
common/simd/v128_intrinsics_x86.h:532:10: error: returning 'void' from a function with incompatible result type 'v128' (aka '__m128i')
  return __extension__ ({
         ^~~~~~~~~~~~~~~~
1 warning and 13 errors generated.
Makefile:69: recipe for target 'enc/encode_block.o' failed
make: *** [enc/encode_block.o] Error 1
@awakecoding
Copy link

I am experiencing the same issue on OS X

@heubergen
Copy link

+1 mac 10.11

@thdav
Copy link
Contributor

thdav commented Nov 4, 2015

WFM now.

@thdav thdav closed this as completed Nov 4, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants