lkml.org 
[lkml]   [1998]   [Dec]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: > Re: Linux threads -- as seen in NT Magazine
    Jamie Lokier writes:
    > On Wed, Dec 16, 1998 at 12:02:33PM +1100, Richard Gooch wrote:
    > > Say spin 5 times, then loop with sched_yield() 5 times, then go to
    > > sleep (block in kernel).
    >
    > Spin just 5 times? Is this with a CPU delay between spins?
    > I'd have thought it wasn't enough if there's no delay.

    No delay. The lock/unlock operations provide more than enough
    delay. You can pack a fair number of normal instructions into a
    spinlock operation.
    If all you're doing is inserting an entry into a list, for example,
    that is an operation that could probably fit into on lock/unlock
    cycle.

    Regards,

    Richard....

    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.rutgers.edu
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 13:46    [W:2.481 / U:0.004 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site