Explorar o código

Do not regenerate last iteration of tasks B and C, otherwise they keep the data busy and it can not be unregistered

Samuel Thibault %!s(int64=10) %!d(string=hai) anos
pai
achega
ebd1392925
Modificáronse 1 ficheiros con 5 adicións e 0 borrados
  1. 5 0
      tests/main/subgraph_repeat_regenerate.c

+ 5 - 0
tests/main/subgraph_repeat_regenerate.c

@@ -86,6 +86,11 @@ static void callback_task_D(void *arg STARPU_ATTRIBUTE_UNUSED)
 	else
 	else
 	{
 	{
 		int ret;
 		int ret;
+		if (loop_cnt == niter-1)
+		{
+			taskB.regenerate = 0;
+			taskC.regenerate = 0;
+		}
 		STARPU_PTHREAD_MUTEX_UNLOCK(&mutex);
 		STARPU_PTHREAD_MUTEX_UNLOCK(&mutex);
 		/* Let's go for another iteration */
 		/* Let's go for another iteration */
 		ret = starpu_task_submit(&taskA);
 		ret = starpu_task_submit(&taskA);