lkml.org 
[lkml]   [2000]   [Oct]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH] Re: Negative scalability by removal of lock_kernel()?(Was: Strange performance behavior of 2.4.0-test9)
    Andrew Morton wrote:
    > --- linux-2.4.0-test10-pre5/fs/locks.c Tue Oct 24 21:34:13 2000
    > +++ linux-akpm/fs/locks.c Sun Oct 29 02:31:10 2000
    > @@ -125,10 +125,9 @@
    > #include <asm/semaphore.h>
    > #include <asm/uaccess.h>
    >
    > -DECLARE_MUTEX(file_lock_sem);
    > -
    > -#define acquire_fl_sem() down(&file_lock_sem)
    > -#define release_fl_sem() up(&file_lock_sem)
    > +spinlock_t file_lock_lock = SPIN_LOCK_UNLOCKED;
    > +#define acquire_fl_lock() spin_lock(&file_lock_lock);
    > +#define release_fl_lock() spin_unlock(&file_lock_lock);

    It seems like better concurrency could be achieved with reader-writer
    locks. Some of the lock test routines simply scan the list, without
    modifying it.

    --
    Jeff Garzik | "Mind if I drive?" -Sam
    Building 1024 | "Not if you don't mind me clawing at the
    MandrakeSoft | dash and screaming like a cheerleader."
    | -Max
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 12:45    [W:0.020 / U:0.564 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site