nbio: forgot to remove allocator from other impls

This commit is contained in:
laytan
2026-01-17 21:10:53 +01:00
parent 2caee687ed
commit 54abe76f20
3 changed files with 0 additions and 7 deletions

View File

@@ -23,7 +23,6 @@ _Event_Loop :: struct {
unqueued: queue.Queue(^Operation),
// Ready to run callbacks, mainly next tick, some other ops that error outside the kernel.
completed: queue.Queue(^Operation),
allocator: mem.Allocator,
wake: ^Operation,
}
@@ -128,8 +127,6 @@ _Stat :: struct {
@(private="package")
_init :: proc(l: ^Event_Loop, alloc: mem.Allocator) -> (err: General_Error) {
l.allocator = alloc
params := uring.DEFAULT_PARAMS
params.flags += {.SUBMIT_ALL, .COOP_TASKRUN, .SINGLE_ISSUER}

View File

@@ -19,7 +19,6 @@ _FULLY_SUPPORTED :: false
_Event_Loop :: struct {
completed: queue.Queue(^Operation),
timeouts: avl.Tree(^Operation),
allocator: mem.Allocator,
}
_Handle :: uintptr
@@ -69,7 +68,6 @@ _Remove :: struct {}
_Link_Timeout :: struct {}
_init :: proc(l: ^Event_Loop, allocator: mem.Allocator) -> (rerr: General_Error) {
l.allocator = allocator
l.completed.data.allocator = allocator
avl.init_cmp(&l.timeouts, timeouts_cmp, allocator)

View File

@@ -23,7 +23,6 @@ _Event_Loop :: struct {
// We have to keep record of what we currently have in the kqueue, and if we get an operation
// that would be the same (ident, filter) pair we need to bundle the operations under one kevent.
submitted: map[Queue_Identifier]^Operation,
allocator: mem.Allocator,
// Holds all events we want to flush. Flushing is done each tick at which point this is emptied.
pending: sa.Small_Array(QUEUE_SIZE, kq.KEvent),
// Holds what should be in `pending` but didn't fit.
@@ -107,7 +106,6 @@ _Link_Timeout :: struct {}
@(private="package")
_init :: proc(l: ^Event_Loop, allocator: mem.Allocator) -> (rerr: General_Error) {
l.allocator = allocator
l.submitted.allocator = allocator
l.overflow.data.allocator = allocator
l.completed.data.allocator = allocator