Duncan Coutts pushed to branch wip/dcoutts/issue-27284 at Glasgow Haskell Compiler / GHC

Commits:

1 changed file:

Changes:

  • rts/sm/NonMovingMark.c
    ... ... @@ -2018,8 +2018,10 @@ bool nonmovingTidyWeaks (struct MarkQueue_ *queue)
    2018 2018
     
    
    2019 2019
             // See Note [Weak pointer processing and the non-moving GC] in
    
    2020 2020
             // MarkWeak.c
    
    2021
    -        bdescr *key_bd = Bdescr((StgPtr) w->key);
    
    2022
    -        bool key_in_nonmoving = HEAP_ALLOCED_GC(w->key) && block_get_flags(key_bd) & BF_NONMOVING;
    
    2021
    +        bool key_in_nonmoving =
    
    2022
    +               HEAP_ALLOCED_GC(w->key) &&
    
    2023
    +               block_get_flags(Bdescr((StgPtr) w->key)) & BF_NONMOVING;
    
    2024
    +
    
    2023 2025
             if (!key_in_nonmoving || nonmovingIsNowAlive(w->key)) {
    
    2024 2026
                 nonmovingMarkLiveWeak(queue, w);
    
    2025 2027
                 did_work = true;