[lkml]   [2003]   [Apr]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRE: [patch] printk subsystems
    Robert wrote:

    >There is both a qualitative difference and quantitative difference in a
    >lockless algorithm as described versus one that uses locking. Most
    >importantly for Linux, these algorithms in practice have better performance
    Do you have benchmark numbers that compare "lockless" and locking
    algorithms on large MP systems?

    For example, how much faster is one 'lock;cmpxchg' compared to
    'spin_lock();if (x==var) var = y;spin_unlock();'.

    So far I assumed that for spinlock that are only held for a few cycles,
    the cacheline trashing dominates, and not the spinning.
    I've avoided to replace spin_lock+inc+spin_unlock with atomic_inc().
    (Just look at the needed memory barriers: smp_mb__after_clear_bit & friends)

    RCU uses per-cpu queues that are really lockless and avoid the cache
    trashing, that is a real win.


    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2005-03-22 13:34    [W:0.026 / U:119.948 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site