浏览代码

Use more fine-grained spinlock. They are not supposed to be held for long anyway

Samuel Thibault 12 年之前
父节点
当前提交
caf8caf013
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      src/common/starpu_spinlock.c

+ 2 - 2
src/common/starpu_spinlock.c

@@ -82,8 +82,8 @@ int _starpu_spin_lock(struct _starpu_spinlock *lock)
 #ifdef STARPU_DEVEL
 #ifdef STARPU_DEVEL
 #warning FIXME: better way to spinlock?
 #warning FIXME: better way to spinlock?
 #endif
 #endif
-		/* Sleep for 10µs */
-		MSG_process_sleep(0.000010);
+		/* Sleep for 1µs */
+		MSG_process_sleep(0.000001);
 	}
 	}
 #else
 #else
 	int ret = pthread_spin_lock(&lock->lock);
 	int ret = pthread_spin_lock(&lock->lock);