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

Next merge from LLVM and clang; SIMD issues #4430

Closed
kripken opened this issue Jul 7, 2016 · 3 comments
Closed

Next merge from LLVM and clang; SIMD issues #4430

kripken opened this issue Jul 7, 2016 · 3 comments
Labels

Comments

@kripken
Copy link
Member

kripken commented Jul 7, 2016

In the next-merge branches for llvm and clang there is a merge of upstream from around a week ago. Looks like the newer clang has more warnings and errors than before, and in particular test_ssse3_full fails on

/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_ssse3_full.cpp:24:32: error: argument should be a value from 0 to 255
        Ret_M128i_M128i_Tint(__m128i, _mm_alignr_epi8);
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:385:101: note: expanded from macro 'Ret_M128i_M128i_Tint'
#define Ret_M128i_M128i_Tint(Ret_type, func) const_int8_unroll(Ret_type, Ret_M128i_M128i_Tint_body, func)
                                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:356:14: note: expanded from macro 'const_int8_unroll'
        F(Ret_type, func, -1); \
        ~~~~~~~~~~~~^~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:334:20: note: expanded from macro 'Ret_M128i_M128i_Tint_body'
                                Ret_type ret = func(m1, m2, Tint); \
                                               ^~~~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/fastcomp/cbuild/bin/../lib/clang/3.9.0/include/tmmintrin.h:161:12: note: expanded from macro '_mm_alignr_epi8'
  (__m128i)__builtin_ia32_palignr128((__v16qi)(__m128i)(a), \
           ^
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_ssse3_full.cpp:24:2: error: cannot initialize a variable of type '__m128i' (vector of 2 'long long' values) with an
      rvalue of type 'void'
        Ret_M128i_M128i_Tint(__m128i, _mm_alignr_epi8);
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:385:74: note: expanded from macro 'Ret_M128i_M128i_Tint'
#define Ret_M128i_M128i_Tint(Ret_type, func) const_int8_unroll(Ret_type, Ret_M128i_M128i_Tint_body, func)
                                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:356:2: note: expanded from macro 'const_int8_unroll'
        F(Ret_type, func, -1); \
        ^~~~~~~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:334:14: note: expanded from macro 'Ret_M128i_M128i_Tint_body'
                                Ret_type ret = func(m1, m2, Tint); \
                                         ^     ~~~~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_ssse3_full.cpp:24:32: error: argument should be a value from 0 to 255
        Ret_M128i_M128i_Tint(__m128i, _mm_alignr_epi8);
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:385:101: note: expanded from macro 'Ret_M128i_M128i_Tint'
#define Ret_M128i_M128i_Tint(Ret_type, func) const_int8_unroll(Ret_type, Ret_M128i_M128i_Tint_body, func)
                                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:380:14: note: expanded from macro 'const_int8_unroll'
        F(Ret_type, func, 309);
        ~~~~~~~~~~~~^~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:334:20: note: expanded from macro 'Ret_M128i_M128i_Tint_body'
                                Ret_type ret = func(m1, m2, Tint); \
                                               ^~~~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/fastcomp/cbuild/bin/../lib/clang/3.9.0/include/tmmintrin.h:161:12: note: expanded from macro '_mm_alignr_epi8'
  (__m128i)__builtin_ia32_palignr128((__v16qi)(__m128i)(a), \
           ^
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_ssse3_full.cpp:24:2: error: cannot initialize a variable of type '__m128i' (vector of 2 'long long' values) with an
      rvalue of type 'void'
        Ret_M128i_M128i_Tint(__m128i, _mm_alignr_epi8);
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:385:74: note: expanded from macro 'Ret_M128i_M128i_Tint'
#define Ret_M128i_M128i_Tint(Ret_type, func) const_int8_unroll(Ret_type, Ret_M128i_M128i_Tint_body, func)
                                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:380:2: note: expanded from macro 'const_int8_unroll'
        F(Ret_type, func, 309);
        ^~~~~~~~~~~~~~~~~~~~~~
/media/alon/2f9a30d7-6124-42d9-87c5-3c80cb70ec54/home/alon/Dev/emscripten/tests/test_sse_full.h:334:14: note: expanded from macro 'Ret_M128i_M128i_Tint_body'
                                Ret_type ret = func(m1, m2, Tint); \
                                         ^     ~~~~~~~~~~~~~~~~~~
4 errors generated.
ERROR

cc @juj

@kripken
Copy link
Member Author

kripken commented Jul 7, 2016

Perhaps related, test_sse1_full and test_sse2_full compile but have incorrect output. Perhaps something changed in how clang handles sse stuff?

@kripken
Copy link
Member Author

kripken commented Jul 8, 2016

Note that there were some merge conflicts dealing with atomics (as can be seen in the merge commit). It's possible I did something wrong there.

@juj juj added the SIMD label Jul 11, 2016
@kripken kripken changed the title test_ssse3_full broken on new clang Next merge from LLVM and clang; SIMD issues Jul 11, 2016
juj added a commit that referenced this issue Jul 11, 2016
…uire that arguments to certain SIMD functions are in uint8_t range. Fixes #4430.
@juj
Copy link
Collaborator

juj commented Jul 11, 2016

Pushed above commit to fix what was an easy compile error. There is another issue which is much more complex, wrote it down as #4435. I'll mark this closed in favor of that.

@juj juj closed this as completed Jul 11, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants