From: Pavel Begunkov <asml.silence@gmail.com>
To: Kanchan Joshi <joshi.k@samsung.com>,
Hannes Reinecke <hare@suse.de>,
axboe@kernel.dk, kbusch@kernel.org, hch@lst.de, sagi@grimberg.me,
martin.petersen@oracle.com, brauner@kernel.org,
viro@zeniv.linux.org.uk, jack@suse.cz, jaegeuk@kernel.org,
bcrl@kvack.org, dhowells@redhat.com, bvanassche@acm.org
Cc: linux-nvme@lists.infradead.org, linux-fsdevel@vger.kernel.org,
io-uring@vger.kernel.org, linux-block@vger.kernel.org,
linux-aio@kvack.org, gost.dev@samsung.com, vishak.g@samsung.com,
javier.gonz@samsung.com, Nitesh Shetty <nj.shetty@samsung.com>
Subject: Re: [PATCH v6 3/3] io_uring: enable per-io hinting capability
Date: Thu, 26 Sep 2024 21:09:13 +0100 [thread overview]
Message-ID: <3f4b4b60-d9f7-4dc7-9045-d41a560e2ad3@gmail.com> (raw)
In-Reply-To: <8665404f-604e-ef64-e8d7-2a2e9de60ba7@samsung.com>
On 9/25/24 14:21, Kanchan Joshi wrote:
> On 9/25/2024 5:53 PM, Pavel Begunkov wrote:
>> On 9/25/24 12:09, Kanchan Joshi wrote:
>>> On 9/25/2024 11:27 AM, Hannes Reinecke wrote:
>> ...
>>> As it stands the new struct will introduce
>>>> a hole of 24 bytes after 'hint_type'.
>>>
>>> This gets implicitly padded at this point [1][2], and overall size is
>>> still capped by largest struct (which is of 16 bytes, placed just above
>>> this).
>>
>> For me it's about having hardly usable in the future by anyone else
>> 7 bytes of space or how much that will be. Try to add another field
>> using those bytes and endianess will start messing with you. And 7
>> bytes is not that convenient.
>>
>> I have same problem with how commands were merged while I was not
>> looking. There was no explicit padding, and it split u64 into u32
>> and implicit padding, so no apps can use the space to put a pointer
>> anymore while there was a much better option of using one of existing
>> 4B fields.
>
> How would you prefer it. Explicit padding (7 bytes), hint_type as u16 or
> anything else?
Explicit padding is better than the current version. Ideally,
I'd like the new fields gone (e.g. if it goes in the direction
of per file hints) or prefer to minimise the size and make the
leftover padding reusable, but that depends on what the feature
needs to be extendable.
And what hint types do we expect in the future? Another question,
don't we want an apui that allows to pass multiple hints? Quite
similar to what I asked about "meta" rw, and it might actually
make a lot of sense to combine them into common infra, like what
cmsg is for networking.
meta[] = [ {INTEGRITY, integrity_params},
{write_hint, ...},
...];
Even though an actual impl would need to be a bit more elaborated.
--
Pavel Begunkov
prev parent reply other threads:[~2024-09-26 20:08 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20240924093247epcas5p4807fe5e531a2b7b2d6961d23bc989c80@epcas5p4.samsung.com>
2024-09-24 9:24 ` [PATCH v6 0/3] per-io hints and FDP Kanchan Joshi
[not found] ` <CGME20240924093250epcas5p39259624b9ebabdef15081ea9bd663d41@epcas5p3.samsung.com>
2024-09-24 9:24 ` [PATCH v6 1/3] nvme: enable FDP support Kanchan Joshi
2024-09-24 9:39 ` Christoph Hellwig
2024-09-25 5:48 ` Hannes Reinecke
[not found] ` <CGME20240924093254epcas5p491d7f7cb62dbbf05fe29e0e75d44bff5@epcas5p4.samsung.com>
2024-09-24 9:24 ` [PATCH v6 2/3] block, fs: restore kiocb based write hint processing Kanchan Joshi
2024-09-25 5:49 ` Hannes Reinecke
[not found] ` <CGME20240924093257epcas5p174955ae79ae2d08a886eeb45a6976d53@epcas5p1.samsung.com>
2024-09-24 9:24 ` [PATCH v6 3/3] io_uring: enable per-io hinting capability Kanchan Joshi
2024-09-24 9:40 ` Christoph Hellwig
2024-09-25 5:57 ` Hannes Reinecke
2024-09-25 11:09 ` Kanchan Joshi
2024-09-25 12:23 ` Pavel Begunkov
2024-09-25 13:21 ` Kanchan Joshi
2024-09-26 20:09 ` Pavel Begunkov [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3f4b4b60-d9f7-4dc7-9045-d41a560e2ad3@gmail.com \
--to=asml.silence@gmail.com \
--cc=axboe@kernel.dk \
--cc=bcrl@kvack.org \
--cc=brauner@kernel.org \
--cc=bvanassche@acm.org \
--cc=dhowells@redhat.com \
--cc=gost.dev@samsung.com \
--cc=hare@suse.de \
--cc=hch@lst.de \
--cc=io-uring@vger.kernel.org \
--cc=jack@suse.cz \
--cc=jaegeuk@kernel.org \
--cc=javier.gonz@samsung.com \
--cc=joshi.k@samsung.com \
--cc=kbusch@kernel.org \
--cc=linux-aio@kvack.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-nvme@lists.infradead.org \
--cc=martin.petersen@oracle.com \
--cc=nj.shetty@samsung.com \
--cc=sagi@grimberg.me \
--cc=viro@zeniv.linux.org.uk \
--cc=vishak.g@samsung.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).