Commit 900fce4e authored by Ben Gamari's avatar Ben Gamari 🐢
Browse files

rts: Fix CNF dirtying logic

Previously due to a silly implementation bug CNFs would never have their
dirty flag set, resulting in their being added again and again to the
`mut_list`. Fix this.

Fixes #17297.

(cherry picked from commit ba27fe74)
parent 822a7f4d
......@@ -542,9 +542,9 @@ insertCompactHash (Capability *cap,
StgClosure *p, StgClosure *to)
{
insertHashTable(str->hash, (StgWord)p, (const void*)to);
const StgInfoTable *strinfo = str->header.info;
if (strinfo == &stg_COMPACT_NFDATA_CLEAN_info) {
strinfo = &stg_COMPACT_NFDATA_DIRTY_info;
const StgInfoTable **strinfo = &str->header.info;
if (*strinfo == &stg_COMPACT_NFDATA_CLEAN_info) {
*strinfo = &stg_COMPACT_NFDATA_DIRTY_info;
recordClosureMutated(cap, (StgClosure*)str);
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment