96 Span<AsyncFiberCommand> commandStorage = {});
108 [[nodiscard]]
bool isOwnerThread()
const;
113 Result runUntilComplete();
114 Result runUntilIdle();
116 Result runOwnerOnce();
117 Result runOwnerNoWait();
118 Result runOwnerUntilComplete();
119 Result runOwnerUntilIdle();
123 Result sleep(TimeMs duration);
134 Result fileReadAt(
const FileDescriptor& file, uint64_t offset, Span<char> buffer,
137 Result fileReadExactAt(
const FileDescriptor& file, uint64_t offset, Span<char> buffer,
141 Result fileWriteAt(
const FileDescriptor& file, uint64_t offset, Span<const char> data,
143 Result fileWriteAll(
const FileDescriptor& file, Span<const char> data,
145 Result fileWriteAllAt(
const FileDescriptor& file, uint64_t offset, Span<const char> data,
156 Span<AsyncFiberCommand> commands;
157 size_t commandHead = 0;
158 size_t commandCount = 0;
162 uint64_t ownerThreadID = 0;
164 Result checkOwnerThread()
const;
165 Result checkFiberContext()
const;
166 void operationStarted();
167 void operationFinished();
168 void lockCommands()
const;
169 void unlockCommands()
const;
171 Result drainCommandQueue();
172 bool hasPendingCommands()
const;
174 uint64_t offset,
bool useOffset);
178 uint64_t offset,
bool useOffset);
180 uint64_t offset,
bool useOffset);
183 Result executeStartCommand(
void* startState);
185 void* startState =
nullptr);
187 Result executeStopCommand(
void* stopState);
Asynchronous I/O (files, sockets, timers, processes, fs events, threads wake-up) (see Async) AsyncEve...
Definition Async.h:1511