From d6bcf62426a738c12870fb48271ef58d5343f043 Mon Sep 17 00:00:00 2001 From: JinZhou5042 Date: Tue, 19 Nov 2024 12:58:50 -0500 Subject: [PATCH 1/3] init --- taskvine/src/manager/vine_manager.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/taskvine/src/manager/vine_manager.c b/taskvine/src/manager/vine_manager.c index 98f21b475a..075ae775bd 100644 --- a/taskvine/src/manager/vine_manager.c +++ b/taskvine/src/manager/vine_manager.c @@ -1,4 +1,5 @@ /* +/* Copyright (C) 2022- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. @@ -4369,10 +4370,11 @@ static void push_task_to_ready_tasks(struct vine_manager *q, struct vine_task *t { if (t->result == VINE_RESULT_RESOURCE_EXHAUSTION) { /* when a task is resubmitted given resource exhaustion, we - * push it at the head of the list, so it gets to run as soon - * as possible. This avoids the issue in which all 'big' tasks - * fail because the first allocation is too small. */ - priority_queue_push(q->ready_tasks, t, t->priority); + * increment its priority by 1, so it gets to run as soon + * as possible among those with the same priority. This avoids + * the issue in which all 'big' tasks fail because the first + * allocation is too small. */ + priority_queue_push(q->ready_tasks, t, t->priority + 1); } else { priority_queue_push(q->ready_tasks, t, t->priority); } From 61b1b05334b80f8748ff326015660ca6b7898d0b Mon Sep 17 00:00:00 2001 From: JinZhou5042 Date: Tue, 19 Nov 2024 13:01:45 -0500 Subject: [PATCH 2/3] remove blank line --- taskvine/src/manager/vine_manager.c | 1 - 1 file changed, 1 deletion(-) diff --git a/taskvine/src/manager/vine_manager.c b/taskvine/src/manager/vine_manager.c index 075ae775bd..ade374ac2e 100644 --- a/taskvine/src/manager/vine_manager.c +++ b/taskvine/src/manager/vine_manager.c @@ -1,5 +1,4 @@ /* -/* Copyright (C) 2022- The University of Notre Dame This software is distributed under the GNU General Public License. See the file COPYING for details. From 756db43c795a5e3af13810746e627b739c6d3667 Mon Sep 17 00:00:00 2001 From: JinZhou5042 Date: Tue, 19 Nov 2024 13:04:56 -0500 Subject: [PATCH 3/3] lint --- taskvine/src/manager/vine_manager.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/taskvine/src/manager/vine_manager.c b/taskvine/src/manager/vine_manager.c index ade374ac2e..79c226baa4 100644 --- a/taskvine/src/manager/vine_manager.c +++ b/taskvine/src/manager/vine_manager.c @@ -4370,7 +4370,7 @@ static void push_task_to_ready_tasks(struct vine_manager *q, struct vine_task *t if (t->result == VINE_RESULT_RESOURCE_EXHAUSTION) { /* when a task is resubmitted given resource exhaustion, we * increment its priority by 1, so it gets to run as soon - * as possible among those with the same priority. This avoids + * as possible among those with the same priority. This avoids * the issue in which all 'big' tasks fail because the first * allocation is too small. */ priority_queue_push(q->ready_tasks, t, t->priority + 1);