Michael S. Tsirkin
2022-Dec-27 07:05 UTC
[RFC PATCH 2/9] vringh: remove vringh_iov and unite to vringh_kiov
On Tue, Dec 27, 2022 at 02:04:03PM +0800, Jason Wang wrote:> On Tue, Dec 27, 2022 at 10:25 AM Shunsuke Mie <mie at igel.co.jp> wrote: > > > > struct vringh_iov is defined to hold userland addresses. However, to use > > common function, __vring_iov, finally the vringh_iov converts to the > > vringh_kiov with simple cast. It includes compile time check code to make > > sure it can be cast correctly. > > > > To simplify the code, this patch removes the struct vringh_iov and unifies > > APIs to struct vringh_kiov. > > > > Signed-off-by: Shunsuke Mie <mie at igel.co.jp> > > While at this, I wonder if we need to go further, that is, switch to > using an iov iterator instead of a vringh customized one. > > ThanksPossibly, but when doing changes like this one needs to be careful to avoid breaking all the inlining tricks vringh relies on for performance. -- MST
Shunsuke Mie
2022-Dec-27 07:13 UTC
[RFC PATCH 2/9] vringh: remove vringh_iov and unite to vringh_kiov
2022?12?27?(?) 16:05 Michael S. Tsirkin <mst at redhat.com>:> > On Tue, Dec 27, 2022 at 02:04:03PM +0800, Jason Wang wrote: > > On Tue, Dec 27, 2022 at 10:25 AM Shunsuke Mie <mie at igel.co.jp> wrote: > > > > > > struct vringh_iov is defined to hold userland addresses. However, to use > > > common function, __vring_iov, finally the vringh_iov converts to the > > > vringh_kiov with simple cast. It includes compile time check code to make > > > sure it can be cast correctly. > > > > > > To simplify the code, this patch removes the struct vringh_iov and unifies > > > APIs to struct vringh_kiov. > > > > > > Signed-off-by: Shunsuke Mie <mie at igel.co.jp> > > > > While at this, I wonder if we need to go further, that is, switch to > > using an iov iterator instead of a vringh customized one. > > > > Thanks > > Possibly, but when doing changes like this one needs to be careful > to avoid breaking all the inlining tricks vringh relies on for > performance.Definitely, I'm evaluating the performance using vringh_test. I'll add a result of the evaluation. But, If there are other evaluation methods, could you please tell me?> -- > MST >Best, Shunsuke