This website works better with JavaScript.
Home
Issues
Pull Requests
Milestones
AI流水线
Repositories
Datasets
Forum
实训
竞赛
大数据
AI开发
Register
Sign In
OSchip
/
OpenBLAS
Not watched
Unwatch
Watch all
Watch but not notify
1
Star
0
Fork
0
Code
Releases
66
Wiki
evaluate
Activity
Issues
0
Pull Requests
0
Datasets
Model
Cloudbrain
HPC
Browse Source
Use wait-for-event to not spin in the blas_lock
tags/v0.3.9
Ali Saidi
6 years ago
parent
430ee31e66
commit
0af9991cc9
1 changed files
with
4 additions
and
4 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+4
-4
common_arm64.h
+ 4
- 4
common_arm64.h
View File
@@ -53,16 +53,16 @@ static void __inline blas_lock(volatile BLASULONG *address){
BLASULONG ret;
do {
while (*address) {YIELDING;};
__asm__ __volatile__(
"mov x4, #1 \n\t"
"sevl \n\t"
"1: \n\t"
"wfe \n\t"
"2: \n\t"
"ldaxr x2, [%1] \n\t"
"cbnz x2, 1b \n\t"
"2: \n\t"
"stxr w3, x4, [%1] \n\t"
"cbnz w3,
1
b \n\t"
"cbnz w3,
2
b \n\t"
"mov %0, #0 \n\t"
: "=r"(ret), "=r"(address)
: "1"(address)
Write
Preview
Loading…
Cancel
Save