Skip to content

refcount: Improve code-gen

Peter Zijlstra lkml 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest9 patches 24 repliesIn review
  2. v1 RFC5 patches 11 repliesSuperseded

Changes since RFC from the cover letter

- more cleanups in scripts/atomic/
- rename atomic_*_ofl() to atomic_*_overflow() (null)
- alternative x86 refcount scheme (Linus)
- fix for refcount_dec_not_one()
- opt __refcount_add_not_zero(.i=1)

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/9atomic: Prepare scripts for macro opsinclude/linux/atomic/atomic-instrumented.h scripts/atomic/atomic-tbl.sh scripts/atomic/atomics.tbl +3 more+177 -922 replies
2/9atomic: Add xchg.tblscripts/atomic/atomic-tbl.sh scripts/atomic/atomics.tbl scripts/atomic/gen-atomic-instrumented.sh +1 more+21 -221 reply
3/9atomic: Introduce atomic_{inc,dec,dec_and_test}_overflow()include/linux/atomic/atomic-arch-fallback.h include/linux/atomic/atomic-instrumented.h include/linux/atomic/atomic-long.h +4 more+189 -34 replies
4/9refcount: Use atomic_*_overflow()include/linux/refcount.h lib/refcount.c+18 -41 reply
5/9atomic,x86: Implement atomic_dec_and_test_overflow()arch/x86/include/asm/atomic.h+23 -01 reply
6/9refcount: Fix refcount_dec_not_one()lib/refcount.c+3 -20 replies
7/9refcount: Prepare for atomic_*_overflow() offsetsinclude/linux/atomic.h include/linux/refcount.h lib/refcount.c+33 -90 replies
8/9atomic,x86: Alternative atomic_*_overflow() schemearch/x86/include/asm/atomic.h+15 -510 replies
9/9refcount: Optimize __refcount_add_not_zero(.i=1)include/linux/refcount.h+1 -10 replies

Reviews trailers per patch

4 of 9 patches have a Reviewed-by or Acked-by.

PatchMark RutlandMarco Elver
SeriesOriginally-by
1/9R-b A-b
2/9R-b
3/9R-b
4/9R-b
5/9
6/9
7/9
8/9
9/9

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/9] refcount: Improve code-gen

Hi,

Now with Linus' favourite refcount scheme on :-)

Changes since RFC:

- more cleanups in scripts/atomic/
- rename atomic_*_ofl() to atomic_*_overflow() (null)
- alternative x86 refcount scheme (Linus)
- fix for refcount_dec_not_one()
- opt __refcount_add_not_zero(.i=1)

Boots x86_64 and builds a kernel.