On 24/02/2021 03:18, Jens Axboe wrote: > On 2/23/21 8:06 PM, Hao Xu wrote: >> 在 2021/2/23 下午8:40, Pavel Begunkov 写道: >>> Instead of using a request itself for overflowed CQE stashing, allocate >>> a separate entry. The disadvantage is that the allocation may fail and >>> it will be accounted as lost (see rings->cq_overflow), so we lose >>> reliability in case of memory pressure. However, it opens a way for for >>> multiple CQEs per an SQE and even generating SQE-less CQEs > >>> Signed-off-by: Pavel Begunkov <asml.silence@xxxxxxxxx> >>> --- >> Hi Pavel, >> Allow me to ask a stupid question, why do we need to support multiple >> CQEs per SQE or even SQE-less CQEs in the future? > > Not a stupid question at all, since it's not something we've done > before. There's been discussion about this in the past, in the presence > of the zero copy IO where we ideally want to post two CQEs for an SQE. > Most recently I've been playing with multishot poll support, where a > POLL_ADD will stay active after triggering. Hence you could be posting > many CQEs for that SQE, over the life time of the request. Yep, in addition should be useful for eBPF requests. -- Pavel Begunkov