How I built Mlucas in WSL / Ubuntu 18.04 for multiple processor types
(rename the executable between builds to identify the flavor)
Note these are mostly untested.
basic x86-64, & presumably the best bet for Knight's Corner Xeon Phi:
Code:
gcc -c -O3 -DUSE_THREADS ../src/*.c >& build.log
grep error build.log
gcc -o Mlucas *.o -lm -lpthread -lrt
SSE2 such as Xeon x5650, e5645, E5-26xx
Code:
gcc -c -O3 -DUSE_SSE2 -DUSE_THREADS ../src/*.c >& build.log
grep error build.log
gcc -o Mlucas *.o -lm -lpthread -lrt
FMA3 such as i7-7500U, i7-8750H
Code:
gcc -c -O3 -DUSE_AVX2 -mavx2 -DUSE_THREADS ../src/*.c >& build.log
grep error build.log
gcc -o Mlucas *.o -lm -lpthread -lrt
AVX-512 such as Hydra (Knights Landing MIC) Xeon Phi 7250
Code:
gcc -c -O3 -DUSE_AVX512 -march=knl -DUSE_THREADS ../src/*.c >& build.log
grep error build.log
gcc -o Mlucas *.o -lm -lpthread -lrt
AVX-512 such as i5-1035G1
Code:
gcc -c -O3 -DUSE_AVX512 -march=skylake-avx512 -DUSE_THREADS ../src/*.c >& build.log
grep error build.log
gcc -o Mlucas *.o -lm -lpthread -lrt
The above are for linux multithreaded build/run environments. For Windows single-threaded end use see next post.
https://www.mersenneforum.org/mayer/README.html
Attachments are Mlucas v19 builds intended for Linux and were built on Ubuntu v18.04 running on WSL / Win10 on an i7-8750H.
Top of reference tree:
https://www.mersenneforum.org/showpo...22&postcount=1