Skip to content
  • Simon Marlow's avatar
    Fix to thread migration · 988ad8ba
    Simon Marlow authored
    Summary:
    If we had 2 threads on the run queue, say [A,B], and B is bound to the
    current Task, then we would fail to migrate any threads.  This fixes it
    so that we would migrate A in that case.
    
    This will help parallelism a bit in programs that have lots of bound
    threads.
    
    Test Plan:
    Test program in #12419, which is actually not a great program but it
    does behave a bit better after this change.
    
    Reviewers: ezyang, niteria, bgamari, austin, erikd
    
    Subscribers: thomie
    
    Differential Revision: https://phabricator.haskell.org/D2430
    
    GHC Trac Issues: #12419
    988ad8ba