const WasiThread = struct tid: std.atomic.Value(i32) = std.atomic.Value(i32).init(0)Thread ID
memory: []u8Contains all memory which was allocated to bootstrap this thread, including:
allocator: std.mem.AllocatorThe allocator used to allocate the thread's memory, which is also used during join to ensure clean-up.
state: State = State.init(.running)The current state of the thread.
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830 const WasiThread = struct {
/// Thread ID
tid: std.atomic.Value(i32) = std.atomic.Value(i32).init(0),
/// Contains all memory which was allocated to bootstrap this thread, including:
/// - Guard page
/// - Stack
/// - TLS segment
/// - `Instance`
/// All memory is freed upon call to `join`
memory: []u8,
/// The allocator used to allocate the thread's memory,
/// which is also used during `join` to ensure clean-up.
allocator: std.mem.Allocator,
/// The current state of the thread.
state: State = State.init(.running),
}