Messages in this thread | | | Date | Thu, 9 Dec 2021 09:33:05 +0100 | From | Peter Zijlstra <> | Subject | Re: [RFC][PATCH 3/5] refcount: Improve out-of-line code-gen |
| |
On Wed, Dec 08, 2021 at 07:36:58PM +0100, Peter Zijlstra wrote: > Allow a number of ops to tail-call refcount_warn_saturate() in order > to generate smaller out-of-line code. > > text data bss dec hex filename > 97341 4985 1116 103442 19412 defconfig-build/kernel/events/core.o > 97299 4985 1116 103400 193e8 defconfig-build/kernel/events/core.o >
This patch also makes GCC do worse code-gen on the fast path, so I'll drop it.
For some obscure raisin it causes this:
ring_buffer_put: a950: f0 ff 0f lock decl (%rdi) a953: 7c 20 jl a975 <ring_buffer_put+0x25> a955: 74 01 je a958 <ring_buffer_put+0x8> a957: c3 ret
ring_buffer_put: a940: 53 push %rbx a941: 48 89 fb mov %rdi,%rbx a944: f0 ff 0f lock decl (%rdi) a947: 7c 04 jl a94d <ring_buffer_put+0xd> a949: 74 10 je a95b <ring_buffer_put+0x1b> a94b: 5b pop %rbx a94c: c3 ret
Which is just unacceptible...
| |