Browse Source

Add a read barrier in the traversing of the buffer list

Needed on systems with weak memory ordering - the inferior, partially working fix from #2544 was already removed in #2551
tags/v0.3.10^2
Martin Kroeker GitHub 5 years ago
parent
commit
f41600e66f
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions
  1. +1
    -0
      driver/others/memory.c

+ 1
- 0
driver/others/memory.c View File

@@ -2741,6 +2741,7 @@ void *blas_memory_alloc(int procpos){
LOCK_COMMAND(&alloc_lock); LOCK_COMMAND(&alloc_lock);
#endif #endif
do { do {
RMB;
#if defined(USE_OPENMP) #if defined(USE_OPENMP)
if (!memory[position].used) { if (!memory[position].used) {
blas_lock(&memory[position].lock); blas_lock(&memory[position].lock);


Loading…
Cancel
Save