io_uring: improve hardlink code generation
authorPavel Begunkov <asml.silence@gmail.com>
Sun, 11 Apr 2021 00:46:39 +0000 (01:46 +0100)
committerJens Axboe <axboe@kernel.dk>
Mon, 12 Apr 2021 15:33:07 +0000 (09:33 -0600)
commite4335ed33eb54ba00c58557753dc84c0ee762ef1
treec01253afffcaf81fb0eae621e32d0d7e9d88aae9
parent88885f66e8c66311923c16caf1ccb6415ebfef72
io_uring: improve hardlink code generation

req_set_fail_links() condition checking is bulky. Even though it's
always in a slow path, it's inlined and generates lots of extra code,
simplify it be moving HARDLINK checking into helpers killing linked
requests.

          text    data     bss     dec     hex filename
before:  79318   12330       8   91656   16608 ./fs/io_uring.o
after:   79126   12330       8   91464   16548 ./fs/io_uring.o

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/96a9387db658a9d5a44ecbfd57c2a62cb888c9b6.1618101759.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c