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

fix build break with icpx 2022.1.0 #6

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

fo40225
Copy link

@fo40225 fo40225 commented Oct 18, 2022

$ icpx --version
Intel(R) oneAPI DPC++/C++ Compiler 2022.1.0 (2022.1.0.20220316)
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /opt/intel/oneapi/compiler/2022.1.0/linux/bin-llvm
icpx -c -g -Wall -O3 -Wc++-compat  -DHAVE_KALLOC  -DPARALLEL_CHAINING -DALIGN_AVX -DAPPLY_AVX2  -xCORE-AVX512 -I./ext/TAL/src/LISA-hash -I./ext/TAL/src/dynamic-programming  ksw2_extd2_avx.c -o ksw2_extd2_avx.o
ksw2_extd2_avx.c:376:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:43:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:376:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:52:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:376:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:64:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:449:3: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:43:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:449:3: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:52:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:449:3: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:64:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:490:3: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:43:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:490:3: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:52:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:490:3: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:64:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:654:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:43:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:654:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:52:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:654:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl_512_mm2_fast;
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:64:19: note: expanded from macro '__dp_code_block1_pcl_512_mm2_fast'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:768:33: warning: unused variable 'tmp' [-Wunused-variable]
                    __m512i H1, tmp, t_;
                                ^
ksw2_extd2_avx.c:1150:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl;
                ^~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:953:19: note: expanded from macro '__dp_code_block1_pcl'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:1150:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl;
                ^~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:962:19: note: expanded from macro '__dp_code_block1_pcl'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:1150:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl;
                ^~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:974:19: note: expanded from macro '__dp_code_block1_pcl'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:1215:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl;
                ^~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:953:19: note: expanded from macro '__dp_code_block1_pcl'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:1215:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl;
                ^~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:962:19: note: expanded from macro '__dp_code_block1_pcl'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:1215:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl;
                ^~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:974:19: note: expanded from macro '__dp_code_block1_pcl'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
ksw2_extd2_avx.c:1252:17: error: argument to '__builtin_ia32_shuf_i32x4' must be a constant integer
                __dp_code_block1_pcl;
                ^~~~~~~~~~~~~~~~~~~~
ksw2_extd2_avx.c:953:19: note: expanded from macro '__dp_code_block1_pcl'
        shf512b = _mm512_shuffle_i32x4(shf512a, shf512a, mska);         \
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/intel/oneapi/compiler/2022.1.0/linux/lib/clang/14.0.0/include/avx512fintrin.h:6682:13: note: expanded from macro '_mm512_shuffle_i32x4'
  ((__m512i)__builtin_ia32_shuf_i32x4((__v16si)(__m512i)(A), \
            ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
7 warnings and 20 errors generated.
Makefile:84: recipe for target 'ksw2_extd2_avx.o' failed
make: *** [ksw2_extd2_avx.o] Error 1

@cjw85
Copy link

cjw85 commented Jan 6, 2023

With version 2023.0.0.20221201 I had to also remove the conditional definition of __cpuidex in ksw2_ext2_avx.c, as with the code I received:

ksw2_dispatch.c:17:6: error: definition of builtin function '__cpuidex'
void __cpuidex(int cpuid[4], int func_id, int subfunc_id)

@fo40225
Copy link
Author

fo40225 commented Jan 6, 2023

change

#ifndef _MSC_VER
// adapted from https://github.com/01org/linux-sgx/blob/master/common/inc/internal/linux/cpuid_gnu.h
void __cpuidex(int cpuid[4], int func_id, int subfunc_id)

to

#if !defined(_MSC_VER) && !defined(__INTEL_LLVM_COMPILER)
// adapted from https://github.com/01org/linux-sgx/blob/master/common/inc/internal/linux/cpuid_gnu.h
void __cpuidex(int cpuid[4], int func_id, int subfunc_id)

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

Successfully merging this pull request may close these issues.

2 participants