mirror of
https://github.com/rdmsr/zag.git
synced 2026-10-27 13:58:20 +00:00
ke: detach from queue on thread exit
This commit is contained in:
@@ -285,6 +285,11 @@ pub fn exit() void {
|
|||||||
curtd.lock.acquire_no_ipl();
|
curtd.lock.acquire_no_ipl();
|
||||||
curtd.state.store(.Zombie, .monotonic);
|
curtd.state.store(.Zombie, .monotonic);
|
||||||
|
|
||||||
|
if (curtd.queue) |q| {
|
||||||
|
curtd.queue = null;
|
||||||
|
kep.queue.signal_wait(q);
|
||||||
|
}
|
||||||
|
|
||||||
if (config.warden) {
|
if (config.warden) {
|
||||||
// There is normally a dispatch object -> thread ordering, but here we
|
// There is normally a dispatch object -> thread ordering, but here we
|
||||||
// have a thread -> dispatch object ordering because we insert into a
|
// have a thread -> dispatch object ordering because we insert into a
|
||||||
|
|||||||
Reference in New Issue
Block a user