-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompile.sh
More file actions
17 lines (15 loc) · 2.5 KB
/
compile.sh
File metadata and controls
17 lines (15 loc) · 2.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/bash
ml icc
a="COMMON-AVX512 MIC-AVX512 CORE-AVX512 CORE-AVX2 CORE-AVX-I AVX SSE4.2 SSE4.1 SSSE3 SSE3 SSE2"
#a=`cat /proc/cpuinfo | grep flags | uniq | cut -d: -f2`
for i in $a
do
icc -qopt-report=2 -qopt-report-phase=vec -D NOALIAS -D ALIGNED -ipo code.cpp -o code6 -x$i
if [ $? -eq 0 ]
then
echo "-------------------------------------------------">&2
echo "Works for $i">&2
time ./code6
echo "-------------------------------------------------">&2
fi
done