Re: [f2fs-dev] [PATCH v2] f2fs: skip direct I/O iostat context when disabled

Chao Yu via Linux-f2fs-devel <[email protected]>
Newsgroups net.sourceforge.lists.linux-f2fs-devel,org.kernel.vger.linux-kernel
Message-ID <[email protected]>
On 6/16/26 11:06, Wenjie Qi wrote:
> F2FS iostat is optional and is disabled by default.  Direct I/O still
> allocates and binds a bio_iostat_ctx, updates the submit timestamp, and
> replaces bi_end_io for every DIO bio even when sbi->iostat_enable is
> false.
> 
> The byte accounting calls do not need an extra guard because
> f2fs_update_iostat() already checks sbi->iostat_enable.  Only skip the
> DIO bio context setup when iostat is disabled.  If iostat is enabled
> through sysfs before submission, the existing context allocation and
> latency accounting path is still used.
> 
> QEMU benchmark on a 1GiB F2FS virtio-blk image, with iostat_enable=0,
> 4KiB O_DIRECT I/O over a 64MiB file, 50000 iterations per run:
> 
>                          baseline     patched
>   direct_read median    65264.50 ns  55470.95 ns
>   direct_read recheck   65553.75 ns  55470.95 ns
>   direct_write median   68054.62 ns  56309.44 ns
>   direct_write recheck  66873.51 ns  56309.44 ns
> 
> Signed-off-by: Wenjie Qi <[email protected]>

Reviewed-by: Chao Yu <[email protected]>

Thanks,


_______________________________________________
Linux-f2fs-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.