mirror of
https://github.com/OpenMathLib/OpenBLAS
synced 2026-05-31 00:45:48 +08:00
Distinguish AppleClang from LLVM on ARM64
This commit is contained in:
9
c_check
9
c_check
@@ -335,7 +335,14 @@ if [ "$architecture" = "arm64" ]; then
|
||||
fi
|
||||
|
||||
no_sme=0
|
||||
is_appleclang=0
|
||||
if [ "$architecture" = "arm64" ]; then
|
||||
if [ "$compiler" = "CLANG" ]; then
|
||||
data=`$compiler_name --version`
|
||||
case "$data" in Apple*)
|
||||
is_appleclang=1
|
||||
esac
|
||||
fi
|
||||
tmpd=$(mktemp -d 2>/dev/null || mktemp -d -t 'OBC')
|
||||
tmpf="$tmpd/a.S"
|
||||
printf ".text \n.global sme_test\n\nsme_test:\nsmstart\nsmstop\nret\n">> "$tmpf"
|
||||
@@ -469,6 +476,7 @@ done
|
||||
[ "$no_avx512bf" -eq 1 ] && printf "NO_AVX512BF16=1\n"
|
||||
[ "$no_avx2" -eq 1 ] && printf "NO_AVX2=1\n"
|
||||
[ "$oldgcc" -eq 1 ] && printf "OLDGCC=1\n"
|
||||
[ "$is_appleclang" -eq 1 ] && printf "APPLECLANG=1\n"
|
||||
exit 0
|
||||
}
|
||||
|
||||
@@ -499,6 +507,7 @@ done
|
||||
[ "$no_avx512bf" -eq 1 ] && printf "NO_AVX512BF16=1\n"
|
||||
[ "$no_avx2" -eq 1 ] && printf "NO_AVX2=1\n"
|
||||
[ "$oldgcc" -eq 1 ] && printf "OLDGCC=1\n"
|
||||
[ "$is_appleclang" -eq 1 ] && printf "APPLECLANG=1\n"
|
||||
[ "$no_lsx" -eq 1 ] && printf "NO_LSX=1\n"
|
||||
[ "$no_lasx" -eq 1 ] && printf "NO_LASX=1\n"
|
||||
} >> "$makefile"
|
||||
|
||||
Reference in New Issue
Block a user