Skip to content

Commit

Permalink
reactor: update lowres_clock when max_task_backlog is exceeded
Browse files Browse the repository at this point in the history
lowres_clock promises task_quota resolution, but we forgot to update
lowres_clock when first, there's a need to preempt *and* second,
max_task_backlog is exceeded. all tasks that follow until backlog
reduces below max target, will find lowres_clock with "now" time as
of beginning of run_tasks() execution, despite multiple task quotas
may have passed since then.

Signed-off-by: Raphael S. Carvalho <[email protected]>
  • Loading branch information
raphaelsc authored and avikivity committed May 12, 2024
1 parent 42f15a5 commit 5de9d95
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/core/reactor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2701,6 +2701,7 @@ void reactor::run_tasks(task_queue& tq) {
// need_preempt() checks breaking out of loops and .then() calls. See
// #302.
reset_preemption_monitor();
lowres_clock::update();
}
}
}
Expand Down

0 comments on commit 5de9d95

Please sign in to comment.