compilation on KNL with gcc

Issue #304 resolved
Jonas Thies
created an issue

I get a lot of Errors like this one:

In file included from /opt/rh/devtoolset-6/root/usr/lib/gcc/x86_64-redhat-linux/6.2.1/include/immintrin.h:79:0, from /home/thie_jo/essex/ghost/build/src_unrolled/sell_spmv_avx232_1.c:13: /opt/rh/devtoolset-6/root/usr/lib/gcc/x86_64-redhat-linux/6.2.1/include/fmaintrin.h:47:1: error: inlining failed in call to always_inline ‘_mm256_fmadd_pd’: target specific option mismatch _mm256_fmadd_pd (m256d A, m256d B, m256d __C)

I noticed that no flags like -mfma -mavx ... are set at all, and found a comment online that this may cause this Kind of Errors (you can't use intrinsics without These flags, it seems). I also noticed that on our Haswell System it compiles despite the missing flags.

Compiler: gcc-6.2.1, CentOS on KNL

Comments (6)

  1. Moritz Kreutzer

    The problem is that GCC does not support all used intrinsics for MIC (e.g., "_mm512_i32logather_pd()").

    I could implement a workaround for that, but I think it's not worth it since the Intel compilers should be used for high performance on those architectures anyways... For now I will just disable the intrinsics code on MIC and rely on compiler vectorization. I'm gonna have a look at your Haswell problem next!

  2. Moritz Kreutzer

    Haswell works with -march=native and all used intrinsics seem to be available in the GCC headers. (I misread your above statement and thought you had a problem on Haswell..)

    Pleas resolve the issue if you are okay with disabling the intrinsics kernels if GCC is used.

  3. Jonas Thies reporter

    I don't think there is a Problem on Haswell, maybe that was a misunderstanding. I'm fine with the Workaround that there is no intrinsics code without Intel

  4. Log in to comment