summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorÖmer Sinan Ağacan <omeragacan@gmail.com>2018-04-21 19:09:15 +0300
committerÖmer Sinan Ağacan <omeragacan@gmail.com>2018-04-21 19:09:15 +0300
commitea01dafe89c150f073814f0f3a54a36215112ac4 (patch)
tree1010ecc5656a8e5a222e9081f4297cf4042cc6a7
parent98b0c3fd63fd052239259f985df45a4a01192914 (diff)
downloadhaskell-ea01dafe89c150f073814f0f3a54a36215112ac4.tar.gz
rts: Use g0 for &generations[0]
[skip ci]
-rw-r--r--rts/sm/MarkWeak.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/rts/sm/MarkWeak.c b/rts/sm/MarkWeak.c
index 248bf632a2..0153539476 100644
--- a/rts/sm/MarkWeak.c
+++ b/rts/sm/MarkWeak.c
@@ -378,14 +378,13 @@ static void checkWeakPtrSanity(StgWeak *hd, StgWeak *tl)
void collectFreshWeakPtrs()
{
uint32_t i;
- generation *gen = &generations[0];
// move recently allocated weak_ptr_list to the old list as well
for (i = 0; i < n_capabilities; i++) {
Capability *cap = capabilities[i];
if (cap->weak_ptr_list_tl != NULL) {
IF_DEBUG(sanity, checkWeakPtrSanity(cap->weak_ptr_list_hd, cap->weak_ptr_list_tl));
- cap->weak_ptr_list_tl->link = gen->weak_ptr_list;
- gen->weak_ptr_list = cap->weak_ptr_list_hd;
+ cap->weak_ptr_list_tl->link = g0->weak_ptr_list;
+ g0->weak_ptr_list = cap->weak_ptr_list_hd;
cap->weak_ptr_list_tl = NULL;
cap->weak_ptr_list_hd = NULL;
} else {