Mateusz Guzik
887e97745e
fs: track the inode having file locks with a flag in ->i_opflags
...
Opening and closing an inode dirties the ->i_readcount field.
Depending on the alignment of the inode, it may happen to false-share
with other fields loaded both for both operations to various extent.
This notably concerns the ->i_flctx field.
Since most inodes don't have the field populated, this bit can be managed
with a flag in ->i_opflags instead which bypasses the problem.
Here are results I obtained while opening a file read-only in a loop
with 24 cores doing the work on Sapphire Rapids. Utilizing the flag as
opposed to reading ->i_flctx field was toggled at runtime as the benchmark
was running, to make sure both results come from the same alignment.
before: 3233740
after: 3373346 (+4%)
before: 3284313
after: 3518711 (+7%)
before: 3505545
after: 4092806 (+16%)
Or to put it differently, this varies wildly depending on how (un)lucky
you get.
The primary bottleneck before and after is the avoidable lockref trip in
do_dentry_open().
Reviewed-by: Jeff Layton <jlayton@kernel.org >
Signed-off-by: Mateusz Guzik <mjguzik@gmail.com >
Link: https://patch.msgid.link/20251203094837.290654-2-mjguzik@gmail.com
Signed-off-by: Christian Brauner <brauner@kernel.org >
2025-12-15 14:33:38 +01:00
..
2025-12-07 08:29:09 -08:00
2025-07-28 13:43:25 -07:00
2025-10-20 20:22:26 +02:00
2025-12-03 17:24:33 -08:00
2025-12-05 15:52:30 -08:00
2025-10-20 20:22:26 +02:00
2025-12-01 09:02:34 -08:00
2025-12-05 17:01:20 -08:00
2025-12-01 16:13:46 -08:00
2025-12-14 15:24:10 +12:00
2025-10-20 20:22:26 +02:00
2025-12-05 14:36:21 -08:00
2025-10-20 20:22:26 +02:00
2025-12-06 14:01:20 -08:00
2025-12-05 21:29:02 -08:00
2025-11-16 01:35:04 -05:00
2025-11-04 19:10:33 -08:00
2025-12-01 16:13:46 -08:00
2025-12-05 14:36:21 -08:00
2025-10-20 20:22:26 +02:00
2025-12-05 17:01:20 -08:00
2025-12-03 10:00:17 +09:00
2025-06-11 13:44:15 +02:00
2025-10-20 20:22:26 +02:00
2025-12-15 14:33:37 +01:00
2025-12-09 12:06:20 +09:00
2025-12-15 14:33:37 +01:00
2025-10-20 20:22:26 +02:00
2025-12-15 14:33:37 +01:00
2025-12-03 20:28:50 -08:00
2025-12-03 20:08:32 -08:00
2025-12-03 20:08:32 -08:00
2025-12-05 16:30:56 -08:00
2025-12-01 14:18:01 -08:00
2025-12-05 14:36:21 -08:00
2025-12-01 10:26:38 -08:00
2025-12-01 09:02:34 -08:00
2025-11-26 17:05:47 -05:00
2025-10-20 20:22:26 +02:00
2025-12-01 09:02:34 -08:00
2025-12-05 21:29:02 -08:00
2025-12-06 10:57:02 -08:00
2025-12-01 15:22:40 -08:00
2025-12-01 10:26:38 -08:00
2025-12-12 21:52:42 +12:00
2025-08-05 16:45:40 -07:00
2025-12-06 10:57:02 -08:00
2025-12-06 14:01:20 -08:00
2025-12-01 11:58:06 +02:00
2025-12-01 17:32:07 -08:00
2025-12-05 13:52:43 -08:00
2025-12-13 20:55:12 +12:00
2025-12-01 14:18:01 -08:00
2025-10-20 20:22:26 +02:00
2025-12-01 09:02:34 -08:00
2025-12-05 16:16:20 -08:00
2025-12-08 15:32:15 -08:00
2025-12-05 14:36:21 -08:00
2025-10-20 20:22:26 +02:00
2025-10-20 20:22:26 +02:00
2025-10-20 20:22:26 +02:00
2025-12-05 14:36:21 -08:00
2025-12-05 13:52:43 -08:00
2025-10-20 20:22:26 +02:00
2025-12-12 21:59:19 +12:00
2025-10-20 20:22:26 +02:00
2025-11-26 15:16:35 +01:00
2025-11-16 01:35:03 -05:00
2025-12-09 08:50:27 +09:00
2025-10-20 20:22:26 +02:00
2025-10-20 20:22:26 +02:00
2025-09-16 23:59:38 -04:00
2025-09-29 15:55:20 -07:00
2025-12-03 20:19:38 -08:00
2025-12-01 09:02:34 -08:00
2025-11-04 12:36:33 +01:00
2025-11-28 12:42:31 +01:00
2025-11-12 09:38:34 +01:00
2025-12-01 13:45:41 -08:00
2025-07-28 17:11:40 -07:00
2025-11-04 08:33:33 +01:00
2025-12-05 14:36:21 -08:00
2025-09-15 21:17:08 -04:00
2025-12-15 14:33:37 +01:00
2025-12-15 14:33:38 +01:00
2025-12-03 17:24:33 -08:00
2025-07-08 10:25:19 +02:00
2025-12-05 13:52:43 -08:00
2025-12-05 15:25:13 -08:00
2025-07-31 14:57:54 -07:00
2025-10-20 20:22:26 +02:00
2025-11-28 12:42:31 +01:00
2025-11-28 12:42:32 +01:00
2025-12-15 14:33:37 +01:00
2025-11-12 09:38:37 +01:00
2025-11-28 12:42:31 +01:00
2025-11-19 12:17:31 +01:00
2025-10-07 12:48:33 +02:00
2025-12-01 17:32:07 -08:00
2025-09-04 15:20:51 -04:00
2025-11-05 09:51:30 +01:00
2025-11-05 22:51:23 +01:00
2025-12-01 09:20:51 -08:00
2025-08-11 14:52:41 +02:00
2025-11-12 09:38:36 +01:00
2025-12-03 11:14:50 +01:00
2025-12-05 14:36:21 -08:00
2025-09-01 13:08:01 +02:00
2025-10-02 18:18:33 -07:00
2025-09-03 20:49:32 -07:00
2025-12-05 14:36:21 -08:00
2025-12-15 14:33:38 +01:00
2025-11-05 09:51:30 +01:00
2025-11-11 10:01:31 +01:00
2025-09-21 14:22:16 -07:00
2025-12-01 16:13:46 -08:00
2025-12-01 17:32:07 -08:00
2025-12-01 17:32:07 -08:00
2025-12-01 17:32:07 -08:00
2025-12-01 10:17:39 -08:00
2025-12-05 11:15:37 -08:00
2025-09-15 21:26:44 -04:00
2025-09-15 21:26:44 -04:00
2025-11-12 09:38:34 +01:00
2025-05-23 14:20:44 +02:00
2025-08-15 16:11:47 +02:00
2025-05-29 12:31:23 +02:00
2025-11-04 08:28:34 +01:00
2025-11-28 12:42:32 +01:00
2025-12-15 14:33:37 +01:00
2025-06-23 12:17:33 +02:00
2025-09-15 21:17:07 -04:00
2025-12-05 15:52:30 -08:00
2025-12-01 09:20:51 -08:00
2025-11-28 12:42:32 +01:00
2025-12-05 13:52:43 -08:00
2025-12-01 15:34:41 -08:00
2025-11-12 09:38:34 +01:00