fix emphemeron-key tracking in a segment with locked objects

original commit: 9d1252b176e972f92030599dae0ce159c9d36c5b
This commit is contained in:
Matthew Flatt 2020-04-01 07:53:07 -06:00
parent ec138ba57c
commit f828cb1eaa
2 changed files with 1 additions and 1 deletions

1
c/gc.c
View File

@ -1524,6 +1524,7 @@ void GCENTRY(ptr tc, IGEN mcg, IGEN tg) {
if (g == static_generation) S_G.number_of_nonstatic_segments -= 1; if (g == static_generation) S_G.number_of_nonstatic_segments -= 1;
si->next = S_G.occupied_segments[s][g]; si->next = S_G.occupied_segments[s][g];
S_G.occupied_segments[s][g] = si; S_G.occupied_segments[s][g] = si;
si->trigger_ephemerons = NULL;
#ifdef PRESERVE_FLONUM_EQ #ifdef PRESERVE_FLONUM_EQ
/* any flonums forwarded won't be reference anymore */ /* any flonums forwarded won't be reference anymore */
si->forwarded_flonums = NULL; si->forwarded_flonums = NULL;

View File

@ -230,7 +230,6 @@ static void initialize_seginfo(seginfo *si, ISPC s, IGEN g) {
si->generation = g; si->generation = g;
si->sorted = 0; si->sorted = 0;
si->min_dirty_byte = 0xff; si->min_dirty_byte = 0xff;
si->trigger_ephemerons = NULL;
for (d = 0; d < cards_per_segment; d += sizeof(ptr)) { for (d = 0; d < cards_per_segment; d += sizeof(ptr)) {
iptr *dp = (iptr *)(si->dirty_bytes + d); iptr *dp = (iptr *)(si->dirty_bytes + d);
/* fill sizeof(iptr) bytes at a time with 0xff */ /* fill sizeof(iptr) bytes at a time with 0xff */