jeffdaily / parasail

Pairwise Sequence Alignment Library
Other
241 stars 34 forks source link

Parasail on recent M1 Mac? #85

Open pb-cdunn opened 3 years ago

pb-cdunn commented 3 years ago

Have you tried to use parasail on a recent Mac with the M1 processor? I have hit this:

ccache cc -Isubprojects/parasail/contrib/libssw.a.p -Isubprojects/parasail/contrib -I../subprojects/parasail/contrib -Isubprojects/parasail -I../subprojects/parasail -Isubprojects/parasail/src -I../subprojects/parasail/src -Xclang -fcolor-diagnostics -pipe -Wall -Winvalid-pch -Wextra -Wpedantic -std=gnu11 -O3 -MD -MQ subprojects/parasail/contrib/libssw.a.p/ssw_ssw.c.o -MF subprojects/parasail/contrib/libssw.a.p/ssw_ssw.c.o.d -o subprojects/parasail/contrib/libssw.a.p/ssw_ssw.c.o -c ../subprojects/parasail/contrib/ssw/ssw.c
In file included from ../subprojects/parasail/contrib/ssw/ssw.c:41:
In file included from /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/12.0.0/include/emmintrin.h:13:
In file included from /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/12.0.0/include/xmmintrin.h:13:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/12.0.0/include/mmintrin.h:50:12: error: invalid conversion between vector type '__m64' (vector of 1 'long long' value) and integer type 'int' of different size
    return (__m64)__builtin_ia32_vec_init_v2si(__i, 0);
           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Same problem for BWA:

How about utilizing this wrapper?

jeffdaily commented 3 years ago

I do not have a mac so I haven't tested it, no. However, I do have some mac builds as part of travis ci. The stackoverflow question indicates neon should be supported. I do have neon support via the simde library, but the support is based on a very old simde version. There's a PR open to update simde, but I haven't had time to properly review it (#82).

Which build tool are you using on mac? cmake? autotools?

jeffdaily commented 3 years ago

Curious why the configure- or cmake-time check for SSE2 is successful but then later fails to compile. Perhaps if you could share a full output log of your build?

pb-cdunn commented 3 years ago

Which build tool are you using on mac? cmake? autotools?

meson

Curious why the configure- or cmake-time check for SSE2 is successful but then later fails to compile.

We have different meson.build for the parent and subproject.

This might be tricky to solve because whatever you do for parasail, we might also need to do in the parent project. But we might have reasons for not doing that. (Lots of devs here with different opinions.) Anyway, if you get it working on Mac, we might be able to adapt it for use in our other tools.