Commit 4e32635
io_uring: optimise SQPOLL mm/files grabbing
There are two reasons for this. First is to optimise
io_sq_thread_acquire_mm_files() for non-SQPOLL case, which currently do
too many checks and function calls in the hot path, e.g. in
io_init_req().
The second is to not grab mm/files when there are not needed. As
__io_queue_sqe() issues only one request now, we can reuse
io_sq_thread_acquire_mm_files() instead of unconditional acquire
mm/files.
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>1 parent d3d7298 commit 4e32635
1 file changed
+13
-14
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1145 | 1145 | | |
1146 | 1146 | | |
1147 | 1147 | | |
1148 | | - | |
1149 | | - | |
1150 | | - | |
1151 | 1148 | | |
1152 | 1149 | | |
1153 | 1150 | | |
| |||
1175 | 1172 | | |
1176 | 1173 | | |
1177 | 1174 | | |
1178 | | - | |
1179 | | - | |
1180 | 1175 | | |
1181 | 1176 | | |
1182 | 1177 | | |
1183 | | - | |
1184 | | - | |
1185 | | - | |
1186 | | - | |
1187 | 1178 | | |
1188 | 1179 | | |
1189 | 1180 | | |
| |||
1198 | 1189 | | |
1199 | 1190 | | |
1200 | 1191 | | |
1201 | | - | |
1202 | | - | |
| 1192 | + | |
| 1193 | + | |
1203 | 1194 | | |
1204 | 1195 | | |
1205 | 1196 | | |
| |||
1219 | 1210 | | |
1220 | 1211 | | |
1221 | 1212 | | |
| 1213 | + | |
| 1214 | + | |
| 1215 | + | |
| 1216 | + | |
| 1217 | + | |
| 1218 | + | |
| 1219 | + | |
| 1220 | + | |
| 1221 | + | |
| 1222 | + | |
1222 | 1223 | | |
1223 | 1224 | | |
1224 | 1225 | | |
| |||
2336 | 2337 | | |
2337 | 2338 | | |
2338 | 2339 | | |
2339 | | - | |
2340 | | - | |
2341 | | - | |
| 2340 | + | |
2342 | 2341 | | |
2343 | 2342 | | |
2344 | 2343 | | |
| |||
0 commit comments