tromp / cuckoo

a memory-bound graph-theoretic proof-of-work system
Other
818 stars 173 forks source link

build failing on ARM arch #96

Closed iDoka closed 5 years ago

iDoka commented 5 years ago

I try to build lean31x1 from src/cuckatoo by command make lean31x1

I get:

g++ -march=native -std=c++11 -Wall -Wno-format -Wno-deprecated-declarations -D_POSIX_C_SOURCE=200112L -O3 -DPREFETCH -I.  -pthread -o lean31x1 -DNSIPHASH=1 -DATOMIC -DEDGEBITS=31 lean.cpp ../crypto/blake2b-ref.c
In file included from lean.hpp:11:0,
                 from lean.cpp:4:
../crypto/siphashxN.h:3:50: fatal error: immintrin.h: No such file or directory
 #include <immintrin.h> // for _mm256_* intrinsics
                                                  ^
compilation terminated.

AFAIK (from googling) its Header file for x86 SIMD intrinsics. I possible could you provide optional vanilla code for portability or give some references for siphashxN pure-C implementation?

tromp commented 5 years ago

probably need to escape that include with

#if defined __AVX2__ || defined __SSE2__
#include <immintrin.h> // for _mm256_* intrinsics
#endif

can you see what other issues you run into with that change?

iDoka commented 5 years ago

It seems your workaround helps me

Thanks!