Messages in this thread | | | From | Linus Torvalds <> | Date | Tue, 7 Dec 2021 08:03:20 -0800 | Subject | Re: [PATCH] block: switch to atomic_t for request references |
| |
On Tue, Dec 7, 2021 at 1:34 AM Peter Zijlstra <peterz@infradead.org> wrote: > > Now, it could be GCC generates atrociously bad code simply because it > doesn't know it can use the flags from the XADD in which case we can > look at doing an arch asm implementation.
That may help.
This thread started because of alleged performance problems with refcount_t. No numbers, and maybe it was wrong, but they have been seen before, so I wouldn't dismiss the issue.
What I've seen personally is the horrendous "multiple different calls to overflow functions with different arguments", which makes __refcount_add() do stupid things and blow up the code. All for entirely pointless debugging code.
Linus
| |