Ben Gamari pushed to branch wip/T26053 at Glasgow Haskell Compiler / GHC
WARNING: The push did not contain any new commits, but force pushed to delete the commits and changes below.
Deleted commits:
-
e8084dcc
by Ben Gamari at 2025-07-15T12:59:42-04:00
1 changed file:
Changes:
| ... | ... | @@ -786,18 +786,28 @@ void updateRemembSetPushStack(Capability *cap, StgStack *stack) |
| 786 | 786 | debugTrace(DEBUG_nonmoving_gc, "upd_rem_set: STACK %p", stack->sp);
|
| 787 | 787 | trace_stack(&cap->upd_rem_set.queue, stack);
|
| 788 | 788 | finish_upd_rem_set_mark((StgClosure *) stack);
|
| 789 | - return;
|
|
| 790 | 789 | } else {
|
| 791 | 790 | // The concurrent GC has claimed the right to mark the stack.
|
| 792 | 791 | // Wait until it finishes marking before proceeding with
|
| 793 | 792 | // mutation.
|
| 794 | - while (needs_upd_rem_set_mark((StgClosure *) stack))
|
|
| 793 | + uint64_t iters = 0;
|
|
| 794 | + while (needs_upd_rem_set_mark((StgClosure *) stack)) {
|
|
| 795 | + iters++;
|
|
| 796 | + if (iters > 100000000) {
|
|
| 797 | + bdescr *bd = Bdescr((StgPtr) stack);
|
|
| 798 | + debugBelch("updateRemSetPushStack: stuck: %p\n", stack);
|
|
| 799 | + debugBelch(" bd->flags: %x\n", bd->flags);
|
|
| 800 | + debugBelch(" epoch : %x\n", nonmovingMarkEpoch);
|
|
| 801 | + debugBelch(" marking: %x\n", stack->marking);
|
|
| 802 | + abort();
|
|
| 803 | + }
|
|
| 804 | + |
|
| 795 | 805 | #if defined(PARALLEL_GC)
|
| 796 | 806 | busy_wait_nop(); // TODO: Spinning here is unfortunate
|
| 797 | 807 | #else
|
| 798 | 808 | ;
|
| 799 | 809 | #endif
|
| 800 | - return;
|
|
| 810 | + }
|
|
| 801 | 811 | }
|
| 802 | 812 | }
|
| 803 | 813 | }
|