From 7c4c43b99666f3e542c9dc9bea21511257446ce5 Mon Sep 17 00:00:00 2001 From: Adrien Bourmault Date: Wed, 23 Jun 2021 10:55:35 +0200 Subject: [PATCH] bugs resolved --- src/scheduler.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/scheduler.c b/src/scheduler.c index aea2f34..fa102b9 100644 --- a/src/scheduler.c +++ b/src/scheduler.c @@ -116,7 +116,7 @@ static void *schedulerMain(void *scheduler) while (!args->pleaseStop && (nPartialCycles / ncpu) <= args->nmaxCycles) { //printLog("Scheduler #%lu online: cycle %d\n", *args->id, ncycles); - // XXX statistics here + // TODO statistics here // Create a new thread if (nworker < ncpu) { @@ -124,10 +124,10 @@ static void *schedulerMain(void *scheduler) workArea = NULL; // Acquiring lock to consistently read the arrowArray - if (acquireNonBlockinArrowgLock(args->arrowArray)) { //XXX does not return 0 + if (acquireNonBlockinArrowgLock(args->arrowArray)) { // Random choice of an arrow electedArrow = - &args->arrowArray->array[rand() % args->arrowArray->size]; // XXX size is 0 + &args->arrowArray->array[rand() % args->arrowArray->size]; // Find a local area workArea = findWorkArea(centersList, electedArrow, args->ruleRadius,