On 7/19/22 2:58 AM, Yin Fengwei wrote: > Hi Jens, > > On 7/19/2022 10:29 AM, Jens Axboe wrote: >> I'll poke at this tomorrow. > > Just FYI. Another finding (test is based on commit 584b0180f0): > If the code block is put to different function, the fio performance result is > different: I think this turned out to be a little bit of a goose chase. What's happening here is that later kernels defer the file assignment, which means it isn't set if a request is queued with IOSQE_ASYNC. That in turn, for writes, means that we don't hash it on io-wq insertion, and then it doesn't get serialized with other writes to that file. I'll come up with a patch for this that you can test. -- Jens Axboe