Skip to content

Commit

Permalink
CORE: fix n deps overflow in pipelined schedule
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergei-Lebedev committed Dec 3, 2024
1 parent 7f3c2f6 commit 82565c3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
6 changes: 3 additions & 3 deletions src/schedule/ucc_schedule.h
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,9 @@ typedef struct ucc_coll_task {
/* used for lf mt progress queue */
ucc_lf_queue_elem_t lf_elem;
};
uint8_t n_deps;
uint8_t n_deps_satisfied;
uint8_t n_deps_base;
uint32_t n_deps;
uint32_t n_deps_satisfied;
uint32_t n_deps_base;
/* timestamp of the start time: either post or triggered_post */
double start_time;
uint32_t seq_num;
Expand Down
3 changes: 2 additions & 1 deletion src/schedule/ucc_schedule_pipelined.c
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,8 @@ ucc_status_t ucc_dependency_handler(ucc_coll_task_t *parent,
ucc_status_t status;
uint8_t n_deps_satisfied;

n_deps_satisfied = ucc_atomic_fadd8(&task->n_deps_satisfied, 1);
n_deps_satisfied = ucc_atomic_fadd32(&task->n_deps_satisfied, 1);
ucc_assert(task->n_deps_satisfied > n_deps_satisfied);

ucc_trace_req("task %p, n_deps %d, satisfied %d", task, task->n_deps,
n_deps_satisfied);
Expand Down

0 comments on commit 82565c3

Please sign in to comment.