Skip to content

Commit

Permalink
save
Browse files Browse the repository at this point in the history
  • Loading branch information
ryoqun committed Sep 15, 2024
1 parent fae5bda commit 256d719
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions unified-scheduler-pool/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1299,7 +1299,7 @@ impl<S: SpawnableScheduler<TH>, TH: TaskHandler> ThreadManager<S, TH> {
};
state_machine.deschedule_task(&executed_task.task);
std::mem::forget(executed_task);
if should_pause {
if should_pause && !session_pausing {
session_pausing = true;
"pausing"
} else {
Expand Down Expand Up @@ -1340,8 +1340,12 @@ impl<S: SpawnableScheduler<TH>, TH: TaskHandler> ThreadManager<S, TH> {
"ending"
},
SchedulingMode::BlockProduction => {
session_pausing = true;
"pausing"
if !session_pausing {
session_pausing = true;
"pausing"
} else {
"close_subch"
}
},
}
}
Expand All @@ -1366,7 +1370,7 @@ impl<S: SpawnableScheduler<TH>, TH: TaskHandler> ThreadManager<S, TH> {
};
state_machine.deschedule_task(&executed_task.task);
std::mem::forget(executed_task);
if should_pause {
if should_pause && !session_pausing {
session_pausing = true;
"pausing"
} else {
Expand Down

0 comments on commit 256d719

Please sign in to comment.