Skip to content

[IO] provide memory to store continuation Fiber* by the caller

Reason for this change is that we suspect the dynamic memory allocation in reapCompletions for the return vector to be rather costly.

We know the maximum amount of memory needed to store continuation Fiber* at compile-time because the size of the CQs is fixed. This allows us to pass a buffer big enough to store all possible continuation Fiber* to reapCompletions from the caller preventing the need for the dynamic memory allocation for the returned vector. The caller has to ensure that the memory is free of data races. Currently this is ensured by allocating the buffer on the stack.

Merge request reports

Loading