On 1/25/21 4:42 AM, Pavel Begunkov wrote: > struct io_submit_state is quite big (168 bytes) and going to grow. It's > better to not keep it on stack as it is now. Move it to context, it's > always protected by uring_lock, so it's fine to have only one instance > of it. I don't like this one. Unless you have plans to make it much bigger, I think it should stay on the stack. On the stack, the ownership is clear. -- Jens Axboe