lkml.org 
[lkml]   [2017]   [Aug]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH 1/2] sched/wait: Break up long wake list walk
    On Tue, Aug 22, 2017 at 01:42:13PM -0700, Linus Torvalds wrote:
    > +void wait_on_page_bit_or_yield(struct page *page, int bit_nr)
    > +{
    > + if (PageWaiters(page)) {
    > + yield();
    > + return;
    > + }
    > + wait_on_page_bit(page, bit_nr);
    > +}

    So _the_ problem with yield() is when you hit this with a RT task it
    will busy spin and possibly not allow the task that actually has the
    lock to make progress at all.

    So ideally there'd be a timeout or other limit on the amount of yield().

    This being bit-spinlocks leaves us very short on state to play with
    though :/

    \
     
     \ /
      Last update: 2017-08-22 22:54    [W:3.108 / U:0.364 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site