Merge pull request #2765 from martin-frbg/issue2760

Add memory barrier to the PPC blas_lock implementation for Linux
This commit is contained in:
Martin Kroeker 2020-08-11 22:40:17 +02:00 committed by GitHub
commit 4573cb2f43
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -105,6 +105,7 @@ static void INLINE blas_lock(volatile unsigned long *address){
" bne- 1f\n" " bne- 1f\n"
" stwcx. %2,0, %1\n" " stwcx. %2,0, %1\n"
" bne- 0b\n" " bne- 0b\n"
" isync\n"
"1: " "1: "
: "=&r"(ret) : "=&r"(ret)
: "r"(address), "r" (val) : "r"(address), "r" (val)