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

Threads: synchronize shared VM compilation and location metadata publication #1117

Open

Description

@chrisbbreuer

Observed failure

Hosted CI on d68f804 reports real ThreadSanitizer races in shared VM compilation metadata:

  • tsan-threadfuzz-lifecycle reports seven warnings in publishLazyChunk and closureDefinitionLocation.
  • tsan-parallel-js reports competing lazy-publication writes and reads of Chunk metadata in validateParameterLayout while compilePlainBody initializes that Chunk.

The release store to Function.chunk does not establish publication for callers that read the pointer without acquire semantics. The duplicate per-Function metadata writes and shared template location-cache writes also need an explicit ownership/publication protocol. The parameter-layout cache guard alone does not explain the compiler-versus-reader stacks.

The complete VM, compiler, bytecode and threadfuzz files are unchanged between 5e4f561 and d68f804. This establishes source ancestry, not a claimed executed parent TSan result. The managed-frame candidate in #1116 is not part of the failing hosted commit.

Required result

  • Retain focused cold shared-function/template regressions that execute the conflicting publication paths under instrumented TSan, without suppressions.
  • Publish initialized function/chunk metadata through a consistent acquire/release protocol, with no competing ordinary writes or reads of partial compiler output.
  • Give shared closure-location cache metadata an explicit synchronization or immutable ownership rule.
  • Preserve normal lazy compilation, rejection/fallback behavior, native entry points, collector tracing and shared-realm semantics.
  • Pass the affected canonical lifecycle and parallel-JS TSan gates, relevant units, and measured before/after conformance.

Related: #478, #480, #1113, #1114, #1115, #1116. This blocks qualified engine adoption for stacksjs/the-settlers-iii-remake#244. The weak-cleanup count failures in the lifecycle log remain a separate investigation and are not assumed to have this cause.

Activity

  1. chrisbbreuer commented on Nov 10, 2026

    @chrisbbreuer
    MemberAuthor

    Pushed cd9d7627. Initialized compiled chunks and fallback defining environments now use consistent acquire/release publication. Retained cold four-thread and rejected-closure witnesses pass without TSan suppressions; baseline witnesses had real publication races. Hosted tsan-parallel-js and tsan-threadfuzz both pass on 8002da3. Hosted lifecycle still fails weak cleanup counts, separately tracked in #1118.

    The combined production candidate passed 2,872 full-suite tests with one skip and zero failures/leaks locally. Before/after conformance passes 6,031 cases in both binaries across 39 affected subtrees, with no regressions. Home ABI fixtures pass in Debug, ReleaseSafe and instrumented TSan. Exact commands, source/binary hashes and logs are retained in Verification/settlers-retained-replay/native-growth-audit/managed-frames-integration; final delivery source equivalence is recorded in delivery-qualified-source.json.

    Hosted CI on the pushed head still has real failures in cleanup, threaded OOM, the own-key allocation fixture and benchmark metadata contracts. The validator and fixture follow-ups are being qualified separately. The unchanged full native game consumer still diverges at callback 5,119 despite matching simulation and checkpoint checksums. That independent discrepancy is now #1122. No complete engine release, downstream adoption, native presentation, or full replay acceptance is claimed.

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