git: kernel - Improve spinlock performance

Matthew Dillon dillon at crater.dragonflybsd.org
Sat Mar 17 01:31:39 PDT 2018


commit ae4025a1ef80a757584210f223107dfd989e9506
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date:   Sat Mar 17 01:28:56 2018 -0700

    kernel - Improve spinlock performance
    
    * Primarily improve spinlock performance when transitioning
      from an exclusive to a shared lock by allowing atomic_fetchadd_int()
      to be used instead of atomic_cmpset_int().
    
    * Also clean up a few remaining atomic_cmpset_int() cases that
      can use atomioc_fcmpset_int() instead.
    
    Suggested-by: mjg

Summary of changes:
 sys/kern/kern_spinlock.c | 53 +++++++++++++++++++++++++++++++++++-------------
 1 file changed, 39 insertions(+), 14 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/ae4025a1ef80a757584210f223107dfd989e9506


-- 
DragonFly BSD source repository



More information about the Commits mailing list