Dave Chinner d8d9bbb0ee xfs: reduce the number of atomic when locking a buffer after lookup
Avoid an extra atomic operation in the non-trylock case by only
doing a trylock if the XBF_TRYLOCK flag is set. This follows the
pattern in the IO path with NOWAIT semantics where the
"trylock-fail-lock" path showed 5-10% reduced throughput compared to
just using single lock call when not under NOWAIT conditions. So
make that same change here, too.

See commit 942491c9e6d6 ("xfs: fix AIM7 regression") for details.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
[hch: split from a larger patch]
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
2022-07-14 12:04:38 +10:00
..
2022-05-09 16:21:44 -04:00
2022-05-09 16:21:45 -04:00
2022-05-24 19:55:07 -07:00
2022-06-12 11:05:44 -07:00
2022-05-09 16:21:45 -04:00
2022-05-02 11:23:49 -05:00
2022-06-01 11:54:29 -07:00
2022-05-24 19:55:07 -07:00
2022-06-06 09:53:03 +02:00
2022-05-24 19:55:07 -07:00
2022-05-31 16:52:59 -07:00
2022-06-03 10:34:34 -07:00
2022-05-27 15:49:30 -07:00
2022-05-24 19:55:07 -07:00
2022-05-09 16:21:45 -04:00
2022-05-28 11:27:17 -07:00
2022-05-24 19:55:07 -07:00
2022-05-24 19:55:07 -07:00
2022-06-10 17:28:43 -07:00
2022-05-24 19:55:07 -07:00
\n
2022-05-25 19:29:54 -07:00
2022-06-03 16:57:16 -07:00
2022-05-09 23:12:53 -04:00
2022-05-30 11:19:16 -07:00
2022-05-09 16:21:46 -04:00
2022-05-23 20:24:12 -05:00
2022-05-24 19:55:07 -07:00
2022-05-24 19:55:07 -07:00
2022-05-24 19:55:07 -07:00
2021-11-17 09:26:09 +01:00
2022-03-28 17:29:53 -07:00
2022-05-27 15:49:30 -07:00
2022-05-09 18:20:49 -07:00
2022-06-04 18:52:00 -07:00
2022-04-01 19:35:56 -07:00
2022-06-04 19:07:15 -07:00
2022-04-19 10:19:02 -07:00
2022-05-22 21:03:01 +01:00
2022-04-17 19:49:59 -06:00