{"abstract":"Old-to-young references are missing and young evacuation loses live objects.","category":"Garbage collector invariants","checks":6,"contract":"Region-based remembered sets. kinds[r] is young, old, humongous or hcont (a continuation region of the humongous object that starts in the nearest preceding humongous region). For each write [slot, value]: null values are ignored; the target region is the region of value, mapped from continuations back to the humongous start; writes within one region and writes whose slot is in a young region are filtered; otherwise the slot's card index (slot // card) is added to the target region's set. Return the remembered sets.","contract_signature":"kinds, region_size, card, writes","evaluation_group":"w2-garbage-collector-invariants-region-remembered-sets","failed_approach":"Filtering on either end still drops old-to-young pointers.","family":"w2-garbage-collector-invariants-region-remembered-sets-young-source-filter","id":"FA-90736","implementations":{"attempt":{"sha256":"b7d12aa9a6d9db3b7eb5e48dec32b4c67f6f8e174dd69846bafd0da65561ecaa","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(kinds, region_size, card, writes):\n    remsets = {}\n    for slot, val in writes:\n        if val is None:\n            continue\n        src, dst = slot // region_size, val // region_size\n        while kinds[dst] == 'hcont':\n            dst -= 1\n        if src == dst:\n            continue\n        if 'young' in (kinds[src], kinds[dst]):\n            continue\n        remsets.setdefault(dst, set()).add(slot // card)\n    return {str(k): sorted(v) for k, v in sorted(remsets.items())}\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncases = [[('regression: old-to-young and old-to-old writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[8, 1040], [2056, 6152], [6452, 7168]]),\n   {'1': [0], '6': [16], '7': [50]}),\n  ('pointer within the same region',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[2056, 2948], [3048, 2056]]),\n   {}),\n  ('neighbouring addresses across a region boundary',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1016, 1040], [3056, 2032]]),\n   {'1': [7, 23]}),\n  ('writes from young regions are filtered',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1032, 0], [7208, 2048], [1032, 7168]]),\n   {}),\n  ('pointer into a humongous continuation',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[8, 5220], [6144, 4104]]),\n   {'3': [0, 48]}),\n  ('null writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[8, None], [6144, None], [2112, 3072]]),\n   {'3': [16]})],\n [('regression: old-to-young and old-to-old writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[16, 1040], [2064, 6152], [6460, 7168]]),\n   {'1': [0], '6': [16], '7': [50]}),\n  ('pointer within the same region',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[2064, 2948], [3048, 2056]]),\n   {}),\n  ('neighbouring addresses across a region boundary',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1016, 1048], [3056, 2032]]),\n   {'1': [7, 23]}),\n  ('writes from young regions are filtered',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1040, 0], [7208, 2048], [1032, 7168]]),\n   {}),\n  ('pointer into a humongous continuation',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[16, 5220], [6144, 4104]]),\n   {'3': [0, 48]}),\n  ('null writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[16, None], [6144, None], [2112, 3072]]),\n   {'3': [16]})],\n [('regression: old-to-young and old-to-old writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[24, 1040], [2072, 6152], [6468, 7168]]),\n   {'1': [0], '6': [16], '7': [50]}),\n  ('pointer within the same region',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[2072, 2948], [3048, 2056]]),\n   {}),\n  ('neighbouring addresses across a region boundary',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1016, 1056], [3056, 2032]]),\n   {'1': [7, 23]}),\n  ('writes from young regions are filtered',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1048, 0], [7208, 2048], [1032, 7168]]),\n   {}),\n  ('pointer into a humongous continuation',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[24, 5220], [6144, 4104]]),\n   {'3': [0, 48]}),\n  ('null writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[24, None], [6144, None], [2112, 3072]]),\n   {'3': [16]})],\n [('regression: old-to-young and old-to-old writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[32, 1040], [2080, 6152], [6476, 7168]]),\n   {'1': [0], '6': [16], '7': [50]}),\n  ('pointer within the same region',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[2080, 2948], [3048, 2056]]),\n   {}),\n  ('neighbouring addresses across a region boundary',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1016, 1064], [3056, 2032]]),\n   {'1': [7, 23]}),\n  ('writes from young regions are filtered',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1056, 0], [7208, 2048], [1032, 7168]]),\n   {}),\n  ('pointer into a humongous continuation',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[32, 5220], [6144, 4104]]),\n   {'3': [0, 48]}),\n  ('null writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[32, None], [6144, None], [2112, 3072]]),\n   {'3': [16]})],\n [('regression: old-to-young and old-to-old writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[40, 1040], [2088, 6152], [6484, 7168]]),\n   {'1': [0], '6': [16], '7': [50]}),\n  ('pointer within the same region',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[2088, 2948], [3048, 2056]]),\n   {}),\n  ('neighbouring addresses across a region boundary',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1016, 1072], [3056, 2032]]),\n   {'1': [7, 23]}),\n  ('writes from young regions are filtered',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1064, 0], [7208, 2048], [1032, 7168]]),\n   {}),\n  ('pointer into a humongous continuation',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[40, 5220], [6144, 4104]]),\n   {'3': [0, 48]}),\n  ('null writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[40, None], [6144, None], [2112, 3072]]),\n   {'3': [16]})]]\nfor label, args, expected in cases[N - 1]:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"broken":{"sha256":"09452973fdb79e1daa2ed5b40fe79979f277c25b4079b4e776a9e78a84524dcf","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(kinds, region_size, card, writes):\n    remsets = {}\n    for slot, val in writes:\n        if val is None:\n            continue\n        src, dst = slot // region_size, val // region_size\n        while kinds[dst] == 'hcont':\n            dst -= 1\n        if src == dst:\n            continue\n        if kinds[dst] == 'young':\n            continue\n        remsets.setdefault(dst, set()).add(slot // card)\n    return {str(k): sorted(v) for k, v in sorted(remsets.items())}\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncases = [[('regression: old-to-young and old-to-old writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[8, 1040], [2056, 6152], [6452, 7168]]),\n   {'1': [0], '6': [16], '7': [50]}),\n  ('pointer within the same region',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[2056, 2948], [3048, 2056]]),\n   {}),\n  ('neighbouring addresses across a region boundary',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1016, 1040], [3056, 2032]]),\n   {'1': [7, 23]}),\n  ('writes from young regions are filtered',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1032, 0], [7208, 2048], [1032, 7168]]),\n   {}),\n  ('pointer into a humongous continuation',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[8, 5220], [6144, 4104]]),\n   {'3': [0, 48]}),\n  ('null writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[8, None], [6144, None], [2112, 3072]]),\n   {'3': [16]})],\n [('regression: old-to-young and old-to-old writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[16, 1040], [2064, 6152], [6460, 7168]]),\n   {'1': [0], '6': [16], '7': [50]}),\n  ('pointer within the same region',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[2064, 2948], [3048, 2056]]),\n   {}),\n  ('neighbouring addresses across a region boundary',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1016, 1048], [3056, 2032]]),\n   {'1': [7, 23]}),\n  ('writes from young regions are filtered',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1040, 0], [7208, 2048], [1032, 7168]]),\n   {}),\n  ('pointer into a humongous continuation',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[16, 5220], [6144, 4104]]),\n   {'3': [0, 48]}),\n  ('null writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[16, None], [6144, None], [2112, 3072]]),\n   {'3': [16]})],\n [('regression: old-to-young and old-to-old writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[24, 1040], [2072, 6152], [6468, 7168]]),\n   {'1': [0], '6': [16], '7': [50]}),\n  ('pointer within the same region',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[2072, 2948], [3048, 2056]]),\n   {}),\n  ('neighbouring addresses across a region boundary',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1016, 1056], [3056, 2032]]),\n   {'1': [7, 23]}),\n  ('writes from young regions are filtered',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1048, 0], [7208, 2048], [1032, 7168]]),\n   {}),\n  ('pointer into a humongous continuation',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[24, 5220], [6144, 4104]]),\n   {'3': [0, 48]}),\n  ('null writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[24, None], [6144, None], [2112, 3072]]),\n   {'3': [16]})],\n [('regression: old-to-young and old-to-old writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[32, 1040], [2080, 6152], [6476, 7168]]),\n   {'1': [0], '6': [16], '7': [50]}),\n  ('pointer within the same region',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[2080, 2948], [3048, 2056]]),\n   {}),\n  ('neighbouring addresses across a region boundary',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1016, 1064], [3056, 2032]]),\n   {'1': [7, 23]}),\n  ('writes from young regions are filtered',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1056, 0], [7208, 2048], [1032, 7168]]),\n   {}),\n  ('pointer into a humongous continuation',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[32, 5220], [6144, 4104]]),\n   {'3': [0, 48]}),\n  ('null writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[32, None], [6144, None], [2112, 3072]]),\n   {'3': [16]})],\n [('regression: old-to-young and old-to-old writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[40, 1040], [2088, 6152], [6484, 7168]]),\n   {'1': [0], '6': [16], '7': [50]}),\n  ('pointer within the same region',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[2088, 2948], [3048, 2056]]),\n   {}),\n  ('neighbouring addresses across a region boundary',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1016, 1072], [3056, 2032]]),\n   {'1': [7, 23]}),\n  ('writes from young regions are filtered',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[1064, 0], [7208, 2048], [1032, 7168]]),\n   {}),\n  ('pointer into a humongous continuation',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[40, 5220], [6144, 4104]]),\n   {'3': [0, 48]}),\n  ('null writes',\n   (['old', 'young', 'old', 'humongous', 'hcont', 'hcont', 'old', 'young'],\n    1024,\n    128,\n    [[40, None], [6144, None], [2112, 3072]]),\n   {'3': [16]})]]\nfor label, args, expected in cases[N - 1]:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"}},"limitations":"A deterministic, bounded teaching model of one garbage-collector mechanism with stipulated rules; it is not a production collector and claims no conformance to any particular runtime. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.","method":"Deterministic executable model with adversarial boundary fixtures.","provenance":{"created_by":"Failure Map","dependencies":"Python standard library","family":"w2-garbage-collector-invariants-region-remembered-sets-young-source-filter","generated_at":"2026-09-29T14:51:29.654666+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Remembered-set filtering decides which cross-region pointers an evacuation will find.","root_cause":"The filter skips writes whose target is young instead of writes from young slots.","sha256":"ef464c3dd98422ff2e9b8b2a8ade63d6d8a36ad4c5d0ca734200abc4e7015b54","title":"Remembered sets: pointers into young regions dropped · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verified":true,"visibility":"public","verification":{"attempt":{"elapsed_ms":36.268,"exit_code":1,"observations":[{"actual":{"6":[16]},"check":"regression: old-to-young and old-to-old writes","expected":{"1":[0],"6":[16],"7":[50]},"passed":false},{"actual":{},"check":"pointer within the same region","expected":{},"passed":true},{"actual":{},"check":"neighbouring addresses across a region boundary","expected":{"1":[7,23]},"passed":false},{"actual":{},"check":"writes from young regions are filtered","expected":{},"passed":true},{"actual":{"3":[0,48]},"check":"pointer into a humongous continuation","expected":{"3":[0,48]},"passed":true},{"actual":{"3":[16]},"check":"null writes","expected":{"3":[16]},"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression: old-to-young and old-to-old writes\", \"actual\": {\"6\": [16]}, \"expected\": {\"1\": [0], \"6\": [16], \"7\": [50]}, \"passed\": false}, {\"check\": \"pointer within the same region\", \"actual\": {}, \"expected\": {}, \"passed\": true}, {\"check\": \"neighbouring addresses across a region boundary\", \"actual\": {}, \"expected\": {\"1\": [7, 23]}, \"passed\": false}, {\"check\": \"writes from young regions are filtered\", \"actual\": {}, \"expected\": {}, \"passed\": true}, {\"check\": \"pointer into a humongous continuation\", \"actual\": {\"3\": [0, 48]}, \"expected\": {\"3\": [0, 48]}, \"passed\": true}, {\"check\": \"null writes\", \"actual\": {\"3\": [16]}, \"expected\": {\"3\": [16]}, \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":39.966,"exit_code":1,"observations":[{"actual":{"6":[16]},"check":"regression: old-to-young and old-to-old writes","expected":{"1":[0],"6":[16],"7":[50]},"passed":false},{"actual":{},"check":"pointer within the same region","expected":{},"passed":true},{"actual":{},"check":"neighbouring addresses across a region boundary","expected":{"1":[7,23]},"passed":false},{"actual":{"0":[8],"2":[56]},"check":"writes from young regions are filtered","expected":{},"passed":false},{"actual":{"3":[0,48]},"check":"pointer into a humongous continuation","expected":{"3":[0,48]},"passed":true},{"actual":{"3":[16]},"check":"null writes","expected":{"3":[16]},"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"regression: old-to-young and old-to-old writes\", \"actual\": {\"6\": [16]}, \"expected\": {\"1\": [0], \"6\": [16], \"7\": [50]}, \"passed\": false}, {\"check\": \"pointer within the same region\", \"actual\": {}, \"expected\": {}, \"passed\": true}, {\"check\": \"neighbouring addresses across a region boundary\", \"actual\": {}, \"expected\": {\"1\": [7, 23]}, \"passed\": false}, {\"check\": \"writes from young regions are filtered\", \"actual\": {\"0\": [8], \"2\": [56]}, \"expected\": {}, \"passed\": false}, {\"check\": \"pointer into a humongous continuation\", \"actual\": {\"3\": [0, 48]}, \"expected\": {\"3\": [0, 48]}, \"passed\": true}, {\"check\": \"null writes\", \"actual\": {\"3\": [16]}, \"expected\": {\"3\": [16]}, \"passed\": true}], \"passed\": false}\n"}},"member_only":{"stages":["fixed"],"fields":["implementations.fixed","verification.fixed","harness","repair"],"note":"The verified repair, its recorded checks, the repair description, and the scoring harness are available to members."}}