瀏覽代碼

bug fix (if the rw-lock are used): release the rw-lock after sync'ing RAM

Cédric Augonnet 16 年之前
父節點
當前提交
4a96fba2c2
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      src/datawizard/coherency.c

+ 4 - 0
src/datawizard/coherency.c

@@ -371,8 +371,12 @@ void starpu_sync_data_with_mem(data_state *state)
 		pthread_mutex_unlock(&statenode.lock);
 	}
 #else
+	/* NB: fetch_data automatically grabs the RW-lock so it needs to be
+ 	 * released explicitely afterward */
 	ret = fetch_data(state, R);
 	STARPU_ASSERT(!ret);
+
+	release_rw_lock(&state->data_lock);
 #endif
 }