镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

GC: retain aggregate literal and spread state through reentrant effects #808

Closed

Description

@chrisbbreuer

Parents: #473, #806. Related: #801, #804, #805.

The new actual-moving parameter-literal test fails in forced tree-walker mode at value=[seed,(nativeMovingCheckpoint(),seed)]. evalArrayLit keeps its new array in an unrooted Value, and evaluates appendElement's receiver before the effectful element expression. The existing aggregate helpers also retain raw object-literal targets, computed-key bytes, CopyDataProperties sources/targets and spread iterator/result locals across callbacks. This predates canonical parameter admission; the tree-walker failure proves it is not a VM admission regression.

Scope:

  • Root and reload aggregate literal results and continued source/key/iterator state at observable boundaries in both tiers and native shared helpers.
  • Preserve once-only ToPropertyKey and captured next methods, property/iterator order and exact identity through actual relocation, including abrupt/OOM paths.
  • Audit CopyDataProperties to define own data properties instead of invoking target setters; keep its source descriptor/get order and deletion semantics exact.
  • Retain bounded ownership with no pinning, stale forwarding-pointer recovery, disabled GC, AST fallback or source rewrite. Do not redesign reserved native stack/queue/job/Promise/Worker/Map/Set lifecycle.

Acceptance:

  • Exact moving aggregate and spread controls pass in both tiers with changed object pointers.
  • Iterator/property effects and copied data descriptors match spec, including proxy/getter and abrupt paths.
  • OOM, no-GIL/TSan, full units and relevant conformance are measured, with issue-linked commits and pushed integration reported separately.

Evidence: /Users/chris/.cache/zig-js-parameter.jIiaXW/focused-debug.log, first case moving parameter array (tree_walker), TestUnexpectedResult.

Completed integration (2026-08-28 UTC)

Implementation: f2340f27. The measured local evidence above and in the linked implementation comments remains unchanged.

  • Complete pushed integration: CI 33144524467 at descendant 81978f7b completed successfully: 53 jobs passed, one scheduled-only job skipped, zero failures. This supersedes earlier pending, cancelled, or failed integration reports; those earlier runs are not counted as successful gates.

Closing this implemented issue as completed. Parent-roadmap work and independently tracked follow-ups remain open; this closure does not claim those broader scopes are finished.

Activity

  1. chrisbbreuer commented on Aug 28, 2026

    @chrisbbreuer
    MemberAuthor

    Candidate ownership fixes now pass 28 actual-moving Debug cases across forced tree-walker and required bytecode: array/object construction, spread source getters, iterator-method/next/done/value getters, calls/construction, optional methods, nested patterns, tagged templates, classes and private constructors. The tests assert one moving minor and changed identity addresses rather than treating a nonmoving collection as proof. Added CopyDataProperties controls for own/prototype setters, deleted or newly non-enumerable source keys, and proxy trap order. All 47 paired semantic controls pass; full Debug and unsuppressed TSan/ReleaseSafe validation are underway. Existing native stack/queue/job ownership remains unchanged.

  2. chrisbbreuer commented on Aug 28, 2026

    @chrisbbreuer
    MemberAuthor

    Pushed with canonical parameter admission as f2340f27. Final #806 evidence includes 28 actual-moving aggregate/iterator cases, 47 paired semantic controls, Debug/ReleaseSafe/unsuppressed TSan, existing runtime OOM restoration, 2042 passing full Debug tests (one platform skip, zero failures/leaks), unchanged default object/array/new/optional-chain reports and 700 seed-one fuzz programs with zero failures. CopyDataProperties preserves own data descriptors, live source deletion/enumerability and proxy trap order. #810 tracks deeper Proxy metadata helper operands separately; outer source/target rooting is not claimed to solve those. No stack/queue/job or activation lifecycle redesign. Keeping open pending pushed integration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions