diff --git a/.cargo/config.toml b/.cargo/config.toml index 7cef5a32e2..3f62e06197 100644 --- a/.cargo/config.toml +++ b/.cargo/config.toml @@ -1,10 +1,16 @@ # Supply-chain soak for cargo's own dependency resolution — the same # soak-window rule the npm side applies via minimumReleaseAge / # min-release-age: crate versions younger than the window are skipped by -# the resolver unless already in Cargo.lock. min-publish-age is an -# [unstable] cargo feature, so these keys bite only under a nightly -# toolchain; on perry's stable toolchain they are inert and the automated -# window rides dependabot's cooldown (.github/dependabot.yml) instead. +# the resolver unless already in Cargo.lock. min-publish-age is nightly- +# only, which is why every workflow pins `dtolnay/rust-toolchain`'s +# `toolchain:` input to a dated nightly (external-tools.json's `rust` +# entry) instead of stable — this block is LIVE only on that pin. +# +# TEMPORARY: move to a stable pin once min-publish-age stabilizes — +# targets Rust 1.100.0 (late September 2026), per +# https://github.com/rust-lang/cargo/pull/17335 (open) and +# https://github.com/rust-lang/cargo/issues/17009. Same condition +# socket-wheelhouse's canonical rust-toolchain.toml is waiting on. # Managed by scripts/soak/soak.mts (`npm run soak` / `npm run soak:fix`). [unstable] min-publish-age = true diff --git a/.github/workflows/auto-opt-app-patterns.yml b/.github/workflows/auto-opt-app-patterns.yml index 7d23283db1..3deeebf15a 100644 --- a/.github/workflows/auto-opt-app-patterns.yml +++ b/.github/workflows/auto-opt-app-patterns.yml @@ -138,6 +138,8 @@ jobs: - name: Install Rust toolchain if: steps.relevance.outputs.run == 'true' uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml index 18a8310f2c..cdef58b02c 100644 --- a/.github/workflows/benchmark.yml +++ b/.github/workflows/benchmark.yml @@ -48,6 +48,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Cache cargo @@ -270,6 +272,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Cache cargo @@ -368,6 +372,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Measure clean-build time diff --git a/.github/workflows/container-tests.yml b/.github/workflows/container-tests.yml index 549e9ac2ea..f413a731ca 100644 --- a/.github/workflows/container-tests.yml +++ b/.github/workflows/container-tests.yml @@ -97,6 +97,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Cache cargo registry @@ -171,6 +173,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Cache cargo registry @@ -213,6 +217,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Cache cargo registry @@ -257,6 +263,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Cache cargo registry diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index 3bcdc86df8..a5946af769 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -37,6 +37,7 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable with: + toolchain: 'nightly-2026-08-20' components: llvm-tools-preview - uses: ./.github/actions/setup-llvm22 diff --git a/.github/workflows/eh-transport.yml b/.github/workflows/eh-transport.yml index 557a1242a6..d22a4f704a 100644 --- a/.github/workflows/eh-transport.yml +++ b/.github/workflows/eh-transport.yml @@ -116,6 +116,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Setup Node.js diff --git a/.github/workflows/ext-link.yml b/.github/workflows/ext-link.yml index fb010a828c..e1e4dc7f65 100644 --- a/.github/workflows/ext-link.yml +++ b/.github/workflows/ext-link.yml @@ -114,6 +114,8 @@ jobs: - name: Install Rust toolchain if: steps.scope.outputs.pkgs != '' uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - if: steps.scope.outputs.pkgs != '' uses: ./.github/actions/setup-llvm22 diff --git a/.github/workflows/feature-matrix.yml b/.github/workflows/feature-matrix.yml index 12d53a196e..3d2d718a9b 100644 --- a/.github/workflows/feature-matrix.yml +++ b/.github/workflows/feature-matrix.yml @@ -39,6 +39,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 diff --git a/.github/workflows/gc-moving-witnesses.yml b/.github/workflows/gc-moving-witnesses.yml index f3b4aec393..c65a715886 100644 --- a/.github/workflows/gc-moving-witnesses.yml +++ b/.github/workflows/gc-moving-witnesses.yml @@ -225,6 +225,8 @@ jobs: - name: Install Rust toolchain if: steps.relevance.outputs.run == 'true' uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 diff --git a/.github/workflows/gc-native-roots.yml b/.github/workflows/gc-native-roots.yml index 55e2765f96..2c6206e20f 100644 --- a/.github/workflows/gc-native-roots.yml +++ b/.github/workflows/gc-native-roots.yml @@ -278,6 +278,8 @@ jobs: with: node-version-file: .node-version - uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 with: diff --git a/.github/workflows/gc-parse-churn-gate.yml b/.github/workflows/gc-parse-churn-gate.yml index 252cbf4102..b51afea87f 100644 --- a/.github/workflows/gc-parse-churn-gate.yml +++ b/.github/workflows/gc-parse-churn-gate.yml @@ -182,6 +182,8 @@ jobs: - name: Install Rust toolchain if: steps.relevance.outputs.run == 'true' uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 if: steps.relevance.outputs.run == 'true' diff --git a/.github/workflows/gc-ptr-shape-off-witness.yml b/.github/workflows/gc-ptr-shape-off-witness.yml index 48ca612ec8..36430bd26c 100644 --- a/.github/workflows/gc-ptr-shape-off-witness.yml +++ b/.github/workflows/gc-ptr-shape-off-witness.yml @@ -169,6 +169,8 @@ jobs: - name: Install Rust toolchain if: steps.relevance.outputs.run == 'true' uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 if: steps.relevance.outputs.run == 'true' diff --git a/.github/workflows/gc-ratchet.yml b/.github/workflows/gc-ratchet.yml index c556535e82..51d3610f59 100644 --- a/.github/workflows/gc-ratchet.yml +++ b/.github/workflows/gc-ratchet.yml @@ -179,6 +179,8 @@ jobs: - name: Install Rust toolchain if: steps.relevance.outputs.run == 'true' uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Cache cargo diff --git a/.github/workflows/gc-root-dominance.yml b/.github/workflows/gc-root-dominance.yml index 6c87339ed5..0255c8a2df 100644 --- a/.github/workflows/gc-root-dominance.yml +++ b/.github/workflows/gc-root-dominance.yml @@ -217,6 +217,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 # ★ The dependency-scale corpus needs the dependency. @@ -499,6 +501,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' # This also puts a matched LLVM 22 `opt` on disk and exports # LLVM_SYS_221_PREFIX, which is how the corpus script finds it. The # native corpus is `--trace llvm` output PLUS the production statepoint diff --git a/.github/workflows/next-app-route.yml b/.github/workflows/next-app-route.yml index f8467e8d02..d9d9a57044 100644 --- a/.github/workflows/next-app-route.yml +++ b/.github/workflows/next-app-route.yml @@ -40,6 +40,8 @@ jobs: persist-credentials: false - uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: mozilla-actions/sccache-action@v0.0.11 diff --git a/.github/workflows/node-compat-matrix.yml b/.github/workflows/node-compat-matrix.yml index ead4229ca1..8f04a9e0b8 100644 --- a/.github/workflows/node-compat-matrix.yml +++ b/.github/workflows/node-compat-matrix.yml @@ -62,6 +62,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Start sccache diff --git a/.github/workflows/node-core-subset.yml b/.github/workflows/node-core-subset.yml index 761733d544..df37ec2b77 100644 --- a/.github/workflows/node-core-subset.yml +++ b/.github/workflows/node-core-subset.yml @@ -74,6 +74,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 diff --git a/.github/workflows/node-suite-guard.yml b/.github/workflows/node-suite-guard.yml index 336f65e9d4..26728a8ef1 100644 --- a/.github/workflows/node-suite-guard.yml +++ b/.github/workflows/node-suite-guard.yml @@ -50,6 +50,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Start sccache diff --git a/.github/workflows/npm-package-sweep.yml b/.github/workflows/npm-package-sweep.yml index 6c8766bce1..07b2b75183 100644 --- a/.github/workflows/npm-package-sweep.yml +++ b/.github/workflows/npm-package-sweep.yml @@ -45,6 +45,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 diff --git a/.github/workflows/release-packages.yml b/.github/workflows/release-packages.yml index 1f74aa995c..86aae485dd 100644 --- a/.github/workflows/release-packages.yml +++ b/.github/workflows/release-packages.yml @@ -359,6 +359,7 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable with: + toolchain: 'nightly-2026-08-20' targets: ${{ matrix.target }} # The old-sysroot image carries LLVM 22 under /usr/lib/llvm-22. # Its host-side GTK4 build does not depend on perry-codegen, so avoid @@ -411,22 +412,14 @@ jobs: # the canonical _ios suffix (`libperry_ui_ios.a`); simulator libs use # `_ios_sim` (`libperry_ui_ios_sim.a`) so they don't collide in the # bottle's flat lib dir. library_search.rs's cross-compile branch - # picks the right variant per --target. tier-3 tvOS/visionOS/watchOS - # are still a follow-up (need nightly + -Zbuild-std). + # picks the right variant per --target. tvOS/visionOS/watchOS + # (Rust Tier-3, needed -Zbuild-std) are no longer built here — that + # unstable-cargo-feature build is dropped entirely, independent of + # which channel the toolchain step above pins. - name: Install iOS Rust targets (macOS) if: runner.os == 'macOS' run: rustup target add aarch64-apple-ios aarch64-apple-ios-sim - # Closes #396 / #397 / #398: tvOS, visionOS, and watchOS are Rust Tier-3 - # targets — no prebuilt std, so we install nightly + rust-src and use - # `-Zbuild-std=core,std,panic_abort` below to compile the standard library - # from source for each (device, sim) triple. Stable stays the default - # toolchain; we only invoke nightly explicitly via `cargo +nightly` for - # the Tier-3 cross-builds. - - name: Install Rust nightly + rust-src for Tier-3 Apple targets (macOS) - if: runner.os == 'macOS' - run: rustup toolchain install nightly --component rust-src --profile minimal - - name: Install GTK4 development libraries (Linux glibc) if: runner.os == 'Linux' && !endsWith(matrix.target, '-musl') # libgstreamer1.0-dev added in v0.5.456 — perry-ui-gtk4 pulls in @@ -563,7 +556,8 @@ jobs: # filenames are disambiguated in the staging step — device libs keep # the canonical `_ios` name, simulator libs get a `_sim` variant # suffix so the bottle can ship both side-by-side. tvOS/visionOS/ - # watchOS are Tier-3 (need nightly + -Zbuild-std) and out of scope. + # watchOS (Rust Tier-3, needed -Zbuild-std) are no longer built — + # that unstable-cargo-feature build is dropped entirely. - name: Build iOS cross-compile libraries (macOS) # Only on the arm64 mac job. These iOS/Apple cross-libs are aarch64 and # identical regardless of host, so building them on the x86_64 mac runner @@ -579,74 +573,6 @@ jobs: cargo build --profile dist --target "$triple" -p perry-ui-ios done - # Closes #396 / #397 / #398: cross-compile runtime + stdlib + UI for the - # Tier-3 Apple platforms (tvOS, visionOS, watchOS). Both device and - # simulator triples per platform; nightly + `-Zbuild-std=...` builds std - # from source. Note watchOS device uses the unusual `arm64_32` triple - # (32-bit pointers, 64-bit registers) — the only non-`aarch64-*` device - # triple in this set, so we keep the device/sim pairs explicit instead - # of deriving them. Library filenames are disambiguated in the staging - # step (device → `_.a`, sim → `__sim.a`); library_search.rs's - # `apple_class_lib_name` already maps each `--target` to the correct - # variant (covered by the `handles_other_class_suffixes` unit test). - - name: Build tvOS/visionOS/watchOS cross-compile libraries (macOS) - # arm64 mac job only — same rationale as the iOS step above. - if: runner.os == 'macOS' && matrix.target == 'aarch64-apple-darwin' - run: | - set -e - # Format: "::" - # - # watchOS is back (v0.5.888 dropped it). The drop reason was real but - # narrower than the old note claimed: ring 0.17.14's pointer-size - # assertion fails for `arm64_32-apple-watchos` — 32-bit pointers with - # 64-bit registers. That is ILP32-specific. `aarch64-apple-watchos` is - # LP64 and ring builds for it fine, as does `perry-ui-watchos`, so the - # LP64 device triple and its simulator are restored here. The ILP32 - # `arm64_32` triple stays out until ring is fixed or pinned. - for entry in \ - "tvos:aarch64-apple-tvos:aarch64-apple-tvos-sim" \ - "visionos:aarch64-apple-visionos:aarch64-apple-visionos-sim" \ - "watchos:aarch64-apple-watchos:aarch64-apple-watchos-sim"; do - plat="${entry%%:*}" - rest="${entry#*:}" - dev="${rest%%:*}" - sim="${rest#*:}" - # watchOS and visionOS cannot build `dyn-eval` today, and it is in - # `default`. The feature reaches `psm` three crates down - # (dyn-eval -> perry-parser -> swc_ecma_parser -> stacker -> psm), - # whose Mach-O guard enumerates darwin/macos/ios/tvos and omits - # watchos/visionos — so both fall through to psm's ELF branch and - # emit `.type`/`.size`, which the Mach-O assembler rejects. Nothing - # in Perry is involved. Fix filed upstream as rust-lang/stacker#152; - # DELETE this branch and the feature list when it lands. - # - # The cost is scoped and worth stating: these two platforms ship - # without runtime `new Function` over a string body. Everything else - # in `default` is present — the list below is `default` minus - # `dyn-eval`, nothing more. - runtime_features="" - case "$plat" in - watchos|visionos) - runtime_features="--no-default-features --features full,regex-engine,temporal,url-engine,string-normalize,intl-segmenter,intl-namespace,global-math,global-json,global-reflect,global-atomics,global-url,global-text,global-websocket,global-webcrypto,global-webfetch,proc-ipc,intl-locale,intl-datetime,diagnostics,mod-dgram,mod-http2-constants,keepalive-anchors,alloc-mimalloc" - ;; - esac - for triple in "$dev" "$sim"; do - echo "::group::$plat $triple" - # Runtime first, with the per-platform feature set; stdlib and UI - # keep `default` (neither reaches psm). - cargo +nightly build --profile dist \ - -Z build-std=core,std,panic_abort \ - --target "$triple" \ - $runtime_features \ - -p perry-runtime -p perry-runtime-static - cargo +nightly build --profile dist \ - -Z build-std=core,std,panic_abort \ - --target "$triple" \ - -p perry-stdlib -p perry-stdlib-static "-p" "perry-ui-${plat}" - echo "::endgroup::" - done - done - - name: Build UI library (Linux glibc) if: runner.os == 'Linux' && !endsWith(matrix.target, '-musl') run: cargo build --profile dist --target ${{ matrix.target }} -p perry-ui-gtk4 @@ -785,44 +711,6 @@ jobs: if [ -f "$sim_dir/libperry_ui_ios.a" ]; then cp "$sim_dir/libperry_ui_ios.a" "staging/libperry_ui_ios_sim.a" fi - # Closes #396 / #397 / #398: same pattern as iOS for the Tier-3 - # Apple platforms. Driven from an explicit triple list so the - # device/sim pairs stay visible rather than derived. - # - # watchOS uses `aarch64-apple-watchos`, NOT the ILP32 - # `arm64_32-apple-watchos` an earlier note here assumed. That - # distinction is the whole reason it can ship again: ring 0.17.14's - # pointer-size assertion is ILP32-specific, so the LP64 triple was - # never affected. Keep them in step with the build step above. - for entry in \ - "tvos:aarch64-apple-tvos:aarch64-apple-tvos-sim" \ - "visionos:aarch64-apple-visionos:aarch64-apple-visionos-sim" \ - "watchos:aarch64-apple-watchos:aarch64-apple-watchos-sim"; do - plat="${entry%%:*}" - rest="${entry#*:}" - dev_triple="${rest%%:*}" - sim_triple="${rest#*:}" - dev_dir="target/${dev_triple}/dist" - sim_dir="target/${sim_triple}/dist" - if [ -f "$dev_dir/libperry_runtime.a" ]; then - cp "$dev_dir/libperry_runtime.a" "staging/libperry_runtime_${plat}.a" - fi - if [ -f "$dev_dir/libperry_stdlib.a" ]; then - cp "$dev_dir/libperry_stdlib.a" "staging/libperry_stdlib_${plat}.a" - fi - if [ -f "$dev_dir/libperry_ui_${plat}.a" ]; then - cp "$dev_dir/libperry_ui_${plat}.a" "staging/libperry_ui_${plat}.a" - fi - if [ -f "$sim_dir/libperry_runtime.a" ]; then - cp "$sim_dir/libperry_runtime.a" "staging/libperry_runtime_${plat}_sim.a" - fi - if [ -f "$sim_dir/libperry_stdlib.a" ]; then - cp "$sim_dir/libperry_stdlib.a" "staging/libperry_stdlib_${plat}_sim.a" - fi - if [ -f "$sim_dir/libperry_ui_${plat}.a" ]; then - cp "$sim_dir/libperry_ui_${plat}.a" "staging/libperry_ui_${plat}_sim.a" - fi - done fi cd staging tar czf ../${{ matrix.artifact }}.tar.gz * @@ -1104,8 +992,8 @@ jobs: build-cross: needs: await-tests strategy: - # Each leg is independent; let one Tier-3 failure not cancel the - # other targets so we still ship the bundles that did build. + # Each leg is independent; let one cross-target failure not cancel + # the other targets so we still ship the bundles that did build. fail-fast: false matrix: include: @@ -1114,65 +1002,23 @@ jobs: target: aarch64-apple-darwin ui_crate: perry-ui-macos ui_lib: libperry_ui_macos.a - tier3: false - os: macos-15 target: x86_64-apple-darwin ui_crate: perry-ui-macos ui_lib: libperry_ui_macos.a - tier3: false - os: macos-14 target: aarch64-apple-ios ui_crate: perry-ui-ios ui_lib: libperry_ui_ios.a - tier3: false - os: macos-14 target: aarch64-apple-ios-sim ui_crate: perry-ui-ios ui_lib: libperry_ui_ios.a - tier3: false - # --- Apple, Tier-3 (nightly + build-std) -------------------------- - # tvOS / visionOS / watchOS are Rust Tier-3: no prebuilt std, so we - # install nightly + rust-src and pass `-Zbuild-std=core,std,panic_abort` - # in the build step below. Mirrors the existing `build:` job. - # - # watchOS is restored here on `aarch64-apple-watchos`. The v0.5.888 - # drop was for ring 0.17.14's pointer-size assertion, which is - # specific to the ILP32 `arm64_32-apple-watchos` triple; the LP64 - # triple builds ring and `perry-ui-watchos` fine. `arm64_32` stays - # out until ring is fixed or pinned. - # - # watchOS and visionOS need `dyn-eval` excluded — see the long note - # in `build:` and rust-lang/stacker#152. - - os: macos-14 - target: aarch64-apple-tvos - ui_crate: perry-ui-tvos - ui_lib: libperry_ui_tvos.a - tier3: true - - os: macos-14 - target: aarch64-apple-tvos-sim - ui_crate: perry-ui-tvos - ui_lib: libperry_ui_tvos.a - tier3: true - - os: macos-14 - target: aarch64-apple-visionos - ui_crate: perry-ui-visionos - ui_lib: libperry_ui_visionos.a - tier3: true - - os: macos-14 - target: aarch64-apple-visionos-sim - ui_crate: perry-ui-visionos - ui_lib: libperry_ui_visionos.a - tier3: true - - os: macos-14 - target: aarch64-apple-watchos - ui_crate: perry-ui-watchos - ui_lib: libperry_ui_watchos.a - tier3: true - - os: macos-14 - target: aarch64-apple-watchos-sim - ui_crate: perry-ui-watchos - ui_lib: libperry_ui_watchos.a - tier3: true + # tvOS/visionOS/watchOS (Rust Tier-3, needed -Zbuild-std) are no + # longer built here — that unstable-cargo-feature build is + # dropped entirely, along with the matrix's `tier3` field and its + # two build-step branches; if Tier-3 support returns, re-add both + # rather than reviving a dead flag. # --- Android (NDK on Linux runner) -------------------------------- # perry-ui-android requires the NDK clang++ wrapper and JNI; the # existing test.yml leg already cross-compiles it on ubuntu-24.04, @@ -1182,12 +1028,10 @@ jobs: target: aarch64-linux-android ui_crate: perry-ui-android ui_lib: libperry_ui_android.a - tier3: false - os: ubuntu-24.04 target: x86_64-linux-android ui_crate: perry-ui-android ui_lib: libperry_ui_android.a - tier3: false # --- Windows MSVC (native runner) --------------------------------- # Both native Windows architectures use their matching hosted runner # so Rust, LLVM, MSVC, and the packaged executable all agree. @@ -1195,12 +1039,10 @@ jobs: target: x86_64-pc-windows-msvc ui_crate: perry-ui-windows ui_lib: perry_ui_windows.lib - tier3: false - os: windows-11-arm target: aarch64-pc-windows-msvc ui_crate: perry-ui-windows ui_lib: perry_ui_windows.lib - tier3: false runs-on: ${{ matrix.os }} env: @@ -1211,16 +1053,13 @@ jobs: steps: - uses: actions/checkout@v7 - - name: Install Rust stable + cross target + - name: Install Rust toolchain + cross target uses: dtolnay/rust-toolchain@stable with: + toolchain: 'nightly-2026-08-20' targets: ${{ matrix.target }} - uses: ./.github/actions/setup-llvm22 - - name: Install Rust nightly + rust-src (Tier-3 only) - if: matrix.tier3 - run: rustup toolchain install nightly --component rust-src --profile minimal - # Same cache shape as `build:` so the cross legs share crate compiles # across release cycles. Keyed on (target, Cargo.lock) — first run on a # new target is cold, but every subsequent release-tag reuses the @@ -1301,8 +1140,7 @@ jobs: # ships clang-cl + lib.exe through Visual Studio. # --- Build the three (or two, when UI is N/A) static libs ------------ - - name: Build runtime + stdlib + UI (stable, Tier-2) - if: ${{ !matrix.tier3 }} + - name: Build runtime + stdlib + UI shell: bash run: | set -euo pipefail @@ -1313,34 +1151,6 @@ jobs: # already on windows-latest. Both go through plain `cargo build`. cargo build --profile dist --target ${{ matrix.target }} -p ${{ matrix.ui_crate }} - - name: Build runtime + stdlib + UI (nightly + build-std, Tier-3) - if: matrix.tier3 - shell: bash - run: | - set -euo pipefail - # watchOS and visionOS cannot build `dyn-eval`, which is in `default`: - # it reaches `psm` via perry-parser -> swc_ecma_parser -> stacker, and - # psm's Mach-O guard omits watchos/visionos so both fall through to - # its ELF branch and emit directives the Mach-O assembler rejects. - # Upstream fix: rust-lang/stacker#152 — delete this branch when it - # lands. The list is `default` minus `dyn-eval`, nothing else, so the - # only capability these two lose is runtime `new Function`. - runtime_features="" - case "${{ matrix.target }}" in - *-apple-watchos|*-apple-watchos-sim|*-apple-visionos|*-apple-visionos-sim) - runtime_features="--no-default-features --features full,regex-engine,temporal,url-engine,string-normalize,intl-segmenter,intl-namespace,global-math,global-json,global-reflect,global-atomics,global-url,global-text,global-websocket,global-webcrypto,global-webfetch,proc-ipc,intl-locale,intl-datetime,diagnostics,mod-dgram,mod-http2-constants,keepalive-anchors,alloc-mimalloc" - ;; - esac - cargo +nightly build --profile dist \ - -Z build-std=core,std,panic_abort \ - --target ${{ matrix.target }} \ - $runtime_features \ - -p perry-runtime -p perry-runtime-static - cargo +nightly build --profile dist \ - -Z build-std=core,std,panic_abort \ - --target ${{ matrix.target }} \ - -p perry-stdlib -p perry-stdlib-static -p ${{ matrix.ui_crate }} - # #4856 — defense in depth behind the cache eviction above: a stale # cached runtime archive fails the release here instead of breaking # every consumer executable link on the build workers. @@ -1510,8 +1320,8 @@ jobs: # --------------------------------------------------------------------------- create-release: needs: [preflight, build, build-cross] - # Strict by design: in tag-last mode a red Tier-3 cross leg blocks the tag - # too (nothing is public yet, so "fix or rerun-to-green, then the skipped + # Strict by design: in tag-last mode a red cross leg blocks the tag too + # (nothing is public yet, so "fix or rerun-to-green, then the skipped # downstream jobs rerun via `gh run rerun --failed`" is cheap). if: > !cancelled() && @@ -1571,7 +1381,7 @@ jobs: # cut-release to the one create-release just made. Host archives are a hard # requirement; cross bundles are best-effort on the legacy paths (workers # rebuild from source when a bundle is missing), matching the old per-leg - # upload semantics where a red Tier-3 leg didn't sink the release. + # upload semantics where a red cross leg didn't sink the release. # --------------------------------------------------------------------------- publish-assets: needs: [preflight, build, build-cross, create-release] diff --git a/.github/workflows/security-audit.yml b/.github/workflows/security-audit.yml index 05a4206d8b..8c97262a3e 100644 --- a/.github/workflows/security-audit.yml +++ b/.github/workflows/security-audit.yml @@ -49,6 +49,8 @@ jobs: with: persist-credentials: false - uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 with: @@ -199,6 +201,8 @@ jobs: with: persist-credentials: false - uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 with: diff --git a/.github/workflows/simctl-tests.yml b/.github/workflows/simctl-tests.yml index e4d2510faa..6e586e64ee 100644 --- a/.github/workflows/simctl-tests.yml +++ b/.github/workflows/simctl-tests.yml @@ -33,6 +33,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Install iOS simulator Rust target diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f59a1efbeb..454959388f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -227,6 +227,7 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable with: + toolchain: 'nightly-2026-08-20' components: rustfmt, clippy - uses: ./.github/actions/setup-llvm22 @@ -711,6 +712,7 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable with: + toolchain: 'nightly-2026-08-20' components: clippy - uses: ./.github/actions/setup-llvm22 @@ -796,6 +798,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Install sccache @@ -908,6 +912,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Install sccache @@ -1212,6 +1218,8 @@ jobs: - name: Install Rust toolchain if: steps.scope.outputs.rust_work == 'true' uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 if: steps.scope.outputs.rust_work == 'true' @@ -1392,6 +1400,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Setup Node.js @@ -1495,6 +1505,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Set up ARM64 MSVC environment @@ -1605,6 +1617,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 @@ -1724,6 +1738,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Install sccache @@ -1920,6 +1936,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Install sccache @@ -2092,6 +2110,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Install sccache @@ -2203,6 +2223,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 @@ -2318,6 +2340,8 @@ jobs: - uses: actions/checkout@v7 - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 with: @@ -2479,6 +2503,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 @@ -2869,6 +2895,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 @@ -2931,6 +2959,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 @@ -2998,6 +3028,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 @@ -3052,6 +3084,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 @@ -3203,6 +3237,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - name: Set up MSVC environment (Windows) @@ -3358,6 +3394,8 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 - uses: Swatinem/rust-cache@v2 diff --git a/.github/workflows/tls-budget.yml b/.github/workflows/tls-budget.yml index 6ee339e64b..f52a9bc2c7 100644 --- a/.github/workflows/tls-budget.yml +++ b/.github/workflows/tls-budget.yml @@ -164,6 +164,8 @@ jobs: - name: Install Rust toolchain if: steps.relevance.outputs.run == 'true' uses: dtolnay/rust-toolchain@stable + with: + toolchain: 'nightly-2026-08-20' - uses: ./.github/actions/setup-llvm22 if: steps.relevance.outputs.run == 'true' diff --git a/CLAUDE.md b/CLAUDE.md index 5e23d062ab..40049ccc69 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -172,7 +172,7 @@ Values cross threads via `SerializedValue` deep-copy. Each thread has independen ## Native UI (`perry/ui`) -Declarative TypeScript compiles to AppKit/UIKit calls. Handle-based widget system (1-based i64 handles, NaN-boxed with POINTER_TAG). `--target ios-simulator`/`--target ios`/`--target tvos-simulator`/`--target tvos` for cross-compilation. +Declarative TypeScript compiles to AppKit/UIKit calls. Handle-based widget system (1-based i64 handles, NaN-boxed with POINTER_TAG). `--target ios-simulator`/`--target ios`/`--target tvos-simulator`/`--target tvos` for cross-compilation. **`release-packages.yml` no longer builds or ships tvOS/visionOS/watchOS artifacts**: they're Rust Tier-3 (no prebuilt std, needed `-Z build-std`, still unstable), and that leg is dropped from the release workflow entirely. The compiler itself still supports them: `perry compile --target tvos-simulator` (etc.) auto-rebuilds via `cargo +nightly -Z build-std` using whatever nightly the caller has installed (`crates/perry/src/commands/compile/link/build_and_run.rs`, `crates/perry/src/commands/compile/optimized_libs/driver.rs`), and `test.yml` still exercises that path for tvOS-sim doc-tests. **To add a new widget** — change 4 places: 1. Runtime: `crates/perry-ui-macos/src/widgets/` — create widget, `register_widget(view)` diff --git a/changelog.d/8550-rust-1.98.0-pin.md b/changelog.d/8550-rust-1.98.0-pin.md new file mode 100644 index 0000000000..af9694cf85 --- /dev/null +++ b/changelog.d/8550-rust-1.98.0-pin.md @@ -0,0 +1,3 @@ +Pinned the Rust toolchain to an exact `nightly-2026-08-20` across every CI workflow (was floating on `dtolnay/rust-toolchain@stable`). Nightly, not stable 1.98.0, because `-Zmin-publish-age` -- the cargo dependency-resolution soak feature `.cargo/config.toml` already configures -- is still nightly-only (verified directly: stable 1.98.0 silently ignores the config with a warning; [rust-lang/cargo#17009](https://github.com/rust-lang/cargo/issues/17009) is still open); the pin is recorded via a `soakBypass`-adopted `rust` entry in `external-tools.json`. Dropped the tvOS/visionOS/watchOS Rust Tier-3 build legs from `release-packages.yml` -- the `-Z build-std` those needed is unstable regardless of channel, so the removal is independent of which channel this pin uses. The `perry-ui-tvos`/`perry-ui-visionos`/`perry-ui-watchos` crates remain in the workspace for a manual `-Z build-std` build; CI just no longer builds or ships them. Also applied 1.98.0's newly-stabilized `{f32,f64}::algebraic_*` methods to `perry-runtime`'s `perf_hooks` `Histogram.stddev()`, an internal HdrHistogram statistic where reassociation is safe. + +The newer pinned nightly surfaced two classes of pre-existing issues invisible under the previous floating stable: `Atomic::fetch_update` was renamed to `try_update` (8 call sites fixed), and an expanded unused-import lint now catches a redundant `use super::super::*;` sitting alongside `use super::*;` (33 files fixed). Both were required for the `warnings` CI job to pass under the new pin. diff --git a/crates/perry-codegen/src/lower_call/native_table/node_core/assert.rs b/crates/perry-codegen/src/lower_call/native_table/node_core/assert.rs index 16ee5fdf32..4dfff47220 100644 --- a/crates/perry-codegen/src/lower_call/native_table/node_core/assert.rs +++ b/crates/perry-codegen/src/lower_call/native_table/node_core/assert.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; pub(crate) const NODE_CORE_ASSERT_ROWS: &[NativeModSig] = &[ diff --git a/crates/perry-codegen/src/lower_call/native_table/node_core/dgram_fs_os.rs b/crates/perry-codegen/src/lower_call/native_table/node_core/dgram_fs_os.rs index ad53365f83..c21ed41d2e 100644 --- a/crates/perry-codegen/src/lower_call/native_table/node_core/dgram_fs_os.rs +++ b/crates/perry-codegen/src/lower_call/native_table/node_core/dgram_fs_os.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; pub(crate) const NODE_CORE_DGRAM_FS_OS_ROWS: &[NativeModSig] = &[ diff --git a/crates/perry-codegen/src/lower_call/native_table/node_core/inspector_vm.rs b/crates/perry-codegen/src/lower_call/native_table/node_core/inspector_vm.rs index fe742081dd..c7aac3f5fb 100644 --- a/crates/perry-codegen/src/lower_call/native_table/node_core/inspector_vm.rs +++ b/crates/perry-codegen/src/lower_call/native_table/node_core/inspector_vm.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; pub(crate) const NODE_CORE_INSPECTOR_VM_ROWS: &[NativeModSig] = &[ diff --git a/crates/perry-codegen/src/lower_call/native_table/node_core/module_sea_tls_test.rs b/crates/perry-codegen/src/lower_call/native_table/node_core/module_sea_tls_test.rs index 933bb24c9b..af72ab5d09 100644 --- a/crates/perry-codegen/src/lower_call/native_table/node_core/module_sea_tls_test.rs +++ b/crates/perry-codegen/src/lower_call/native_table/node_core/module_sea_tls_test.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; pub(crate) const NODE_CORE_MODULE_SEA_TLS_TEST_ROWS: &[NativeModSig] = &[ diff --git a/crates/perry-codegen/src/lower_call/native_table/node_core/url_punycode_console.rs b/crates/perry-codegen/src/lower_call/native_table/node_core/url_punycode_console.rs index 14f528f595..1db5622960 100644 --- a/crates/perry-codegen/src/lower_call/native_table/node_core/url_punycode_console.rs +++ b/crates/perry-codegen/src/lower_call/native_table/node_core/url_punycode_console.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; pub(crate) const NODE_CORE_URL_PUNYCODE_CONSOLE_ROWS: &[NativeModSig] = &[ diff --git a/crates/perry-codegen/src/lower_call/native_table/node_core/util_buffer.rs b/crates/perry-codegen/src/lower_call/native_table/node_core/util_buffer.rs index 74f4093a42..2bc34f1653 100644 --- a/crates/perry-codegen/src/lower_call/native_table/node_core/util_buffer.rs +++ b/crates/perry-codegen/src/lower_call/native_table/node_core/util_buffer.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; pub(crate) const NODE_CORE_UTIL_BUFFER_ROWS: &[NativeModSig] = &[ diff --git a/crates/perry-runtime/src/arena/block.rs b/crates/perry-runtime/src/arena/block.rs index 630fb9d1d9..0258036d47 100644 --- a/crates/perry-runtime/src/arena/block.rs +++ b/crates/perry-runtime/src/arena/block.rs @@ -163,7 +163,7 @@ fn block_pool_process_bytes_sub(bytes: usize) { return; } BLOCK_POOL_PROCESS_BYTES - .fetch_update(Ordering::Relaxed, Ordering::Relaxed, |current| { + .try_update(Ordering::Relaxed, Ordering::Relaxed, |current| { current.checked_sub(bytes) }) .unwrap_or_else(|current| { @@ -181,7 +181,7 @@ pub(super) fn block_pool_counter_try_reserve( cap: usize, ) -> bool { counter - .fetch_update(Ordering::Relaxed, Ordering::Relaxed, |current| { + .try_update(Ordering::Relaxed, Ordering::Relaxed, |current| { current.checked_add(size).filter(|&next| next <= cap) }) .is_ok() diff --git a/crates/perry-runtime/src/gc/barrier/mod.rs b/crates/perry-runtime/src/gc/barrier/mod.rs index 243fb325bb..067becd4fa 100644 --- a/crates/perry-runtime/src/gc/barrier/mod.rs +++ b/crates/perry-runtime/src/gc/barrier/mod.rs @@ -775,7 +775,7 @@ pub(super) fn incremental_mark_barrier_disable() { }); if was_active { super::instruments::note_mark_barrier_disarmed(); - let _ = PERRY_INCREMENTAL_MARK_BARRIER_ACTIVE_COUNT.fetch_update( + let _ = PERRY_INCREMENTAL_MARK_BARRIER_ACTIVE_COUNT.try_update( Ordering::SeqCst, Ordering::SeqCst, |count| count.checked_sub(1), @@ -1038,7 +1038,7 @@ pub extern "C" fn js_gc_write_barriers_emitted(active: u32) { if active != 0 { GENERATED_WRITE_BARRIERS_EMITTED.fetch_add(1, Ordering::AcqRel); } else { - let _ = GENERATED_WRITE_BARRIERS_EMITTED.fetch_update( + let _ = GENERATED_WRITE_BARRIERS_EMITTED.try_update( Ordering::AcqRel, Ordering::Acquire, |count| count.checked_sub(1), diff --git a/crates/perry-runtime/src/gc/layout_tables.rs b/crates/perry-runtime/src/gc/layout_tables.rs index d1f5af7760..8a0eb1b551 100644 --- a/crates/perry-runtime/src/gc/layout_tables.rs +++ b/crates/perry-runtime/src/gc/layout_tables.rs @@ -426,7 +426,7 @@ pub static PERRY_PER_OBJECT_LAYOUTS_ANY: std::sync::atomic::AtomicU32 = fn per_object_layouts_global_arm() { use std::sync::atomic::Ordering; PERRY_PER_OBJECT_LAYOUTS_ANY - .fetch_update(Ordering::SeqCst, Ordering::SeqCst, |count| { + .try_update(Ordering::SeqCst, Ordering::SeqCst, |count| { count.checked_add(1) }) .expect("per-object layout thread count overflow"); @@ -443,7 +443,7 @@ fn per_object_layouts_global_disarm_with_hook( ) { use std::sync::atomic::Ordering; armed_threads - .fetch_update(Ordering::SeqCst, Ordering::SeqCst, |count| { + .try_update(Ordering::SeqCst, Ordering::SeqCst, |count| { count.checked_sub(1) }) .expect("per-object layout thread count underflow"); diff --git a/crates/perry-runtime/src/gc/poll_arm.rs b/crates/perry-runtime/src/gc/poll_arm.rs index e9405329b8..7005945621 100644 --- a/crates/perry-runtime/src/gc/poll_arm.rs +++ b/crates/perry-runtime/src/gc/poll_arm.rs @@ -109,7 +109,7 @@ fn arm_counters(armed: &AtomicU32, events: &AtomicU64) { /// See [`disarm_poll`] for why this saturates instead of wrapping. #[inline] fn disarm_counter(armed: &AtomicU32) { - let _ = armed.fetch_update(Ordering::Relaxed, Ordering::Relaxed, |armed| { + let _ = armed.try_update(Ordering::Relaxed, Ordering::Relaxed, |armed| { (armed > 0).then(|| armed - 1) }); } diff --git a/crates/perry-runtime/src/gc/roots/stack_maps.rs b/crates/perry-runtime/src/gc/roots/stack_maps.rs index 942e888406..0fb0bdd46d 100644 --- a/crates/perry-runtime/src/gc/roots/stack_maps.rs +++ b/crates/perry-runtime/src/gc/roots/stack_maps.rs @@ -164,7 +164,7 @@ impl StackMapIndexStore { // is also the minimum loader recency each rebuild must preserve. let generation = self .next_generation - .fetch_update(Ordering::Relaxed, Ordering::Relaxed, |generation| { + .try_update(Ordering::Relaxed, Ordering::Relaxed, |generation| { generation.checked_add(1) }) .unwrap_or_else(|_| panic!("perry: stack-map rebuild generation overflow")) diff --git a/crates/perry-runtime/src/node_stream_constructors/builders.rs b/crates/perry-runtime/src/node_stream_constructors/builders.rs index 503b94e2ba..f5d4f96f18 100644 --- a/crates/perry-runtime/src/node_stream_constructors/builders.rs +++ b/crates/perry-runtime/src/node_stream_constructors/builders.rs @@ -1,7 +1,6 @@ //! node:stream — the `js_node_stream_*_new` / `*_subclass_init` constructors //! and `Readable.from` factory (split out of node_stream_constructors.rs for //! the 2000-line file-size gate, #1987). -use super::super::*; use super::*; use crate::closure::ClosureHeader; use crate::object::{js_object_get_field_by_name_f64, js_object_set_field_by_name, ObjectHeader}; diff --git a/crates/perry-runtime/src/node_stream_constructors/introspection.rs b/crates/perry-runtime/src/node_stream_constructors/introspection.rs index 671a2d2161..5ff0495066 100644 --- a/crates/perry-runtime/src/node_stream_constructors/introspection.rs +++ b/crates/perry-runtime/src/node_stream_constructors/introspection.rs @@ -3,7 +3,6 @@ //! `_isArrayBufferView` type predicates), default-highWaterMark accessors and //! abort-signal wiring (split out of node_stream_constructors.rs for the //! 2000-line file-size gate, #1987). -use super::super::*; use super::*; use crate::closure::{js_closure_alloc, js_closure_set_capture_ptr}; use crate::value::JSValue; diff --git a/crates/perry-runtime/src/node_stream_constructors/pipeline.rs b/crates/perry-runtime/src/node_stream_constructors/pipeline.rs index 5bb157094f..893064dc8a 100644 --- a/crates/perry-runtime/src/node_stream_constructors/pipeline.rs +++ b/crates/perry-runtime/src/node_stream_constructors/pipeline.rs @@ -1,7 +1,6 @@ //! node:stream — `Duplex.from`, `compose`, `finished`, `pipeline` and //! `duplexPair` (split out of node_stream_constructors.rs for the 2000-line //! file-size gate, #1987). -use super::super::*; use super::*; use crate::closure::{ js_closure_alloc, js_closure_get_capture_f64, js_closure_set_capture_f64, ClosureHeader, diff --git a/crates/perry-runtime/src/node_stream_constructors/web_adapter.rs b/crates/perry-runtime/src/node_stream_constructors/web_adapter.rs index cc653bd900..e5f1b6535c 100644 --- a/crates/perry-runtime/src/node_stream_constructors/web_adapter.rs +++ b/crates/perry-runtime/src/node_stream_constructors/web_adapter.rs @@ -1,7 +1,6 @@ //! node:stream — WHATWG Web-stream interop (`Readable.toWeb`/`fromWeb`, the //! adapter pumps, and the fallback stub) split out of //! node_stream_constructors.rs for the 2000-line file-size gate, #1987. -use super::super::*; use super::*; use crate::closure::{ js_closure_alloc, js_closure_get_capture_f64, js_closure_set_capture_f64, ClosureHeader, diff --git a/crates/perry-runtime/src/object/global_this/array_error.rs b/crates/perry-runtime/src/object/global_this/array_error.rs index b95ce57e0f..4409d209bb 100644 --- a/crates/perry-runtime/src/object/global_this/array_error.rs +++ b/crates/perry-runtime/src/object/global_this/array_error.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; pub(crate) fn global_this_rest_array_values(rest: f64) -> Vec { diff --git a/crates/perry-runtime/src/object/global_this/ctor_thunks.rs b/crates/perry-runtime/src/object/global_this/ctor_thunks.rs index 6713de0db7..60430e6619 100644 --- a/crates/perry-runtime/src/object/global_this/ctor_thunks.rs +++ b/crates/perry-runtime/src/object/global_this/ctor_thunks.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; pub(crate) fn normalize_eval_this_body(body: &str) -> Option { diff --git a/crates/perry-runtime/src/object/global_this/fetch_globals.rs b/crates/perry-runtime/src/object/global_this/fetch_globals.rs index 1b3817fd5b..fadf21b9f5 100644 --- a/crates/perry-runtime/src/object/global_this/fetch_globals.rs +++ b/crates/perry-runtime/src/object/global_this/fetch_globals.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; crate::perry_thread_local! { diff --git a/crates/perry-runtime/src/object/global_this/generator.rs b/crates/perry-runtime/src/object/global_this/generator.rs index 9aeb679524..31da8fea3a 100644 --- a/crates/perry-runtime/src/object/global_this/generator.rs +++ b/crates/perry-runtime/src/object/global_this/generator.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; /// Distinguishes plain vs async generator closures for the intrinsic-tower diff --git a/crates/perry-runtime/src/object/global_this/install_static.rs b/crates/perry-runtime/src/object/global_this/install_static.rs index 78019b6189..2c2cf65811 100644 --- a/crates/perry-runtime/src/object/global_this/install_static.rs +++ b/crates/perry-runtime/src/object/global_this/install_static.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; #[no_mangle] diff --git a/crates/perry-runtime/src/object/global_this/math_temporal.rs b/crates/perry-runtime/src/object/global_this/math_temporal.rs index d334f46b88..d6ad2f1072 100644 --- a/crates/perry-runtime/src/object/global_this/math_temporal.rs +++ b/crates/perry-runtime/src/object/global_this/math_temporal.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; // Math.* thunks live in the sibling `builtin_thunks` module (split out of // `global_this`); pull them in directly so `install_math_namespace` resolves diff --git a/crates/perry-runtime/src/object/global_this/populate.rs b/crates/perry-runtime/src/object/global_this/populate.rs index aeb36ef1a0..37fdfb2b48 100644 --- a/crates/perry-runtime/src/object/global_this/populate.rs +++ b/crates/perry-runtime/src/object/global_this/populate.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; /// Populate the freshly-allocated globalThis singleton with built-in diff --git a/crates/perry-runtime/src/object/global_this/proto_methods.rs b/crates/perry-runtime/src/object/global_this/proto_methods.rs index 0cdb8f8b4d..4e09f6adb6 100644 --- a/crates/perry-runtime/src/object/global_this/proto_methods.rs +++ b/crates/perry-runtime/src/object/global_this/proto_methods.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; // Array.prototype thunks live in the sibling `array_error` module (split out of // `global_this`); pull them in directly so the prototype-install tables resolve diff --git a/crates/perry-runtime/src/object/global_this/typed_array.rs b/crates/perry-runtime/src/object/global_this/typed_array.rs index beeb82047d..252bca14b3 100644 --- a/crates/perry-runtime/src/object/global_this/typed_array.rs +++ b/crates/perry-runtime/src/object/global_this/typed_array.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; fn array_buffer_receiver_addr() -> Option { diff --git a/crates/perry-runtime/src/object/native_call_method/collection_methods.rs b/crates/perry-runtime/src/object/native_call_method/collection_methods.rs index 55583c355c..bbfffbde1a 100644 --- a/crates/perry-runtime/src/object/native_call_method/collection_methods.rs +++ b/crates/perry-runtime/src/object/native_call_method/collection_methods.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; /// Whether `method` is a backing-store collection method for a `class … extends diff --git a/crates/perry-runtime/src/object/native_call_method/common_methods.rs b/crates/perry-runtime/src/object/native_call_method/common_methods.rs index c0d1b4b868..a59a065384 100644 --- a/crates/perry-runtime/src/object/native_call_method/common_methods.rs +++ b/crates/perry-runtime/src/object/native_call_method/common_methods.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::object_proto::*; use super::proto_dispatch::*; use super::*; diff --git a/crates/perry-runtime/src/object/native_call_method/disposal.rs b/crates/perry-runtime/src/object/native_call_method/disposal.rs index a391583521..39efdd6a6d 100644 --- a/crates/perry-runtime/src/object/native_call_method/disposal.rs +++ b/crates/perry-runtime/src/object/native_call_method/disposal.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; /// #4795: resolve `obj[Symbol.dispose]` / `obj[Symbol.asyncDispose]` for the diff --git a/crates/perry-runtime/src/object/native_call_method/handle_methods.rs b/crates/perry-runtime/src/object/native_call_method/handle_methods.rs index a73ab195e8..7b4a1e5b9b 100644 --- a/crates/perry-runtime/src/object/native_call_method/handle_methods.rs +++ b/crates/perry-runtime/src/object/native_call_method/handle_methods.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::typed_array::*; use super::*; diff --git a/crates/perry-runtime/src/object/native_call_method/object_proto.rs b/crates/perry-runtime/src/object/native_call_method/object_proto.rs index 02c6cc928c..218df09375 100644 --- a/crates/perry-runtime/src/object/native_call_method/object_proto.rs +++ b/crates/perry-runtime/src/object/native_call_method/object_proto.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; pub(super) unsafe fn object_has_null_proto_flag(object: *const ObjectHeader) -> bool { diff --git a/crates/perry-runtime/src/object/native_call_method/primitive_methods.rs b/crates/perry-runtime/src/object/native_call_method/primitive_methods.rs index 58d4501632..87c2907ed0 100644 --- a/crates/perry-runtime/src/object/native_call_method/primitive_methods.rs +++ b/crates/perry-runtime/src/object/native_call_method/primitive_methods.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::typed_array::*; use super::*; diff --git a/crates/perry-runtime/src/object/native_call_method/proto_dispatch.rs b/crates/perry-runtime/src/object/native_call_method/proto_dispatch.rs index 516f5ba16b..2345646d70 100644 --- a/crates/perry-runtime/src/object/native_call_method/proto_dispatch.rs +++ b/crates/perry-runtime/src/object/native_call_method/proto_dispatch.rs @@ -1,4 +1,3 @@ -use super::super::*; use super::*; /// #3716: a built-in *prototype method* read off its prototype and called *as diff --git a/crates/perry-runtime/src/object/object_ops/accessors.rs b/crates/perry-runtime/src/object/object_ops/accessors.rs index 4bc8ea5480..99eea60469 100644 --- a/crates/perry-runtime/src/object/object_ops/accessors.rs +++ b/crates/perry-runtime/src/object/object_ops/accessors.rs @@ -1,6 +1,5 @@ //! Annex B accessor methods (`__defineGetter__`/`__lookupSetter__` etc.) and //! the raw own-field read `js_object_get_own_field_or_undef`. -use super::super::*; use super::*; // Disambiguate the two in-scope `value_is_callable` globs (object_ops' // `descriptor_helpers` via `super::*` and `object`'s `instanceof` via diff --git a/crates/perry-runtime/src/object/object_ops/define_property.rs b/crates/perry-runtime/src/object/object_ops/define_property.rs index 5ba09e966e..e3d38a03b0 100644 --- a/crates/perry-runtime/src/object/object_ops/define_property.rs +++ b/crates/perry-runtime/src/object/object_ops/define_property.rs @@ -1,5 +1,4 @@ //! `Object.defineProperty` and its class-prototype-method installation helper. -use super::super::*; use super::*; /// #2159 helper: install a `target_cid.method` entry from an diff --git a/crates/perry-runtime/src/object/object_ops/descriptor_helpers.rs b/crates/perry-runtime/src/object/object_ops/descriptor_helpers.rs index 1637dece5a..431aefce77 100644 --- a/crates/perry-runtime/src/object/object_ops/descriptor_helpers.rs +++ b/crates/perry-runtime/src/object/object_ops/descriptor_helpers.rs @@ -1,6 +1,5 @@ //! Descriptor validation + throw helpers backing `Object.defineProperty` / //! `Object.create` / `Object.defineProperties` (moved out of `object_ops.rs`). -use super::super::*; use super::*; /// Throw a `TypeError` with the given UTF-8 message bytes. Used by the /// `Object.defineProperty` / `Object.create` descriptor + invariant validation diff --git a/crates/perry-runtime/src/object/object_ops/from_entries.rs b/crates/perry-runtime/src/object/object_ops/from_entries.rs index 4e242c0deb..577b87f054 100644 --- a/crates/perry-runtime/src/object/object_ops/from_entries.rs +++ b/crates/perry-runtime/src/object/object_ops/from_entries.rs @@ -1,5 +1,4 @@ //! `Object.fromEntries` and its iterable-materialization helpers. -use super::super::*; use super::*; fn throw_from_entries_type_error(message: &[u8]) -> ! { diff --git a/crates/perry-runtime/src/object/object_ops/has_own.rs b/crates/perry-runtime/src/object/object_ops/has_own.rs index 62044704e7..c6125dca3a 100644 --- a/crates/perry-runtime/src/object/object_ops/has_own.rs +++ b/crates/perry-runtime/src/object/object_ops/has_own.rs @@ -1,5 +1,4 @@ //! `Object.is`, `Object.hasOwn`, and `Object.prototype.propertyIsEnumerable`. -use super::super::*; use super::*; /// Object.is(a, b) — SameValue algorithm diff --git a/crates/perry-runtime/src/object/object_ops/keys_array.rs b/crates/perry-runtime/src/object/object_ops/keys_array.rs index f33f875115..c4796d9017 100644 --- a/crates/perry-runtime/src/object/object_ops/keys_array.rs +++ b/crates/perry-runtime/src/object/object_ops/keys_array.rs @@ -1,6 +1,5 @@ //! keys_array maintenance helpers shared by the descriptor-define paths: //! `ensure_key_in_keys_array`, `install_builtin_getter`, `own_key_present`. -use super::super::*; use super::*; /// Ensure a key appears in the object's keys_array. Used by `Object.defineProperty` diff --git a/crates/perry-runtime/src/object/object_ops/prototype.rs b/crates/perry-runtime/src/object/object_ops/prototype.rs index 189bab2b6a..5f463af7f0 100644 --- a/crates/perry-runtime/src/object/object_ops/prototype.rs +++ b/crates/perry-runtime/src/object/object_ops/prototype.rs @@ -1,5 +1,4 @@ //! `Object.create`, `Object.getPrototypeOf`, and the globalThis-builtin lookup. -use super::super::*; use super::*; /// Look up the canonical NaN-boxed value of a built-in constructor / diff --git a/crates/perry-runtime/src/perf_histogram.rs b/crates/perry-runtime/src/perf_histogram.rs index d86a923c6e..0492a61458 100644 --- a/crates/perry-runtime/src/perf_histogram.rs +++ b/crates/perry-runtime/src/perf_histogram.rs @@ -269,8 +269,14 @@ impl Histogram { let mut it = self.iter(); while it.step() { if it.count != 0 { - let dev = self.median_equivalent(it.value) as f64 - mean; - geometric_dev_total += dev * dev * it.count as f64; + // Rust 1.98's algebraic_* float methods let LLVM reassociate + // and vectorize this reduction (Node's own HdrHistogram-based + // stddev is already a bucketed approximation, not a value + // any spec requires bit-exact, so reordering is safe here). + let dev = self.median_equivalent(it.value) as f64; + let dev = dev.algebraic_sub(mean); + let sq = dev.algebraic_mul(dev).algebraic_mul(it.count as f64); + geometric_dev_total = geometric_dev_total.algebraic_add(sq); } } (geometric_dev_total / self.total_count as f64).sqrt() diff --git a/external-tools.json b/external-tools.json index 7795f0eaae..8d8fbe5445 100644 --- a/external-tools.json +++ b/external-tools.json @@ -1,5 +1,24 @@ { "tools": { + "rust": { + "description": "Rust toolchain (rustc + cargo) — pinned exact version for every workflow, instead of floating on whatever `dtolnay/rust-toolchain@stable` resolves to at run time.", + "version": "nightly-2026-08-20", + "release": "rustup-toolchain", + "repository": "github:rust-lang/rust", + "notes": [ + "Pinned via `toolchain:` on every `dtolnay/rust-toolchain@stable` step in .github/workflows/*.yml. Bump by editing tools.rust.version here and re-running the same substitution across every workflow file.", + "Integrity is rustup's own signed-manifest verification, not a second SRI hash — this entry just records the adopted version for the soak gate.", + "Nightly, not stable, because -Zmin-publish-age (.cargo/config.toml) is nightly-only on 1.98.0 — verified directly, not assumed.", + "Transition-to-stable target: Rust 1.100.0, late September 2026, per the min-publish-age stabilization PR (https://github.com/rust-lang/cargo/pull/17335, open) and tracking issue (https://github.com/rust-lang/cargo/issues/17009). Same target as socket-wheelhouse's canonical rust-toolchain.toml.", + "Already carries the algebraic_* float methods used in crates/perry-runtime/src/perf_histogram.rs — stable since 1.98.0, unrelated to the nightly pin above.", + "Adopted 1 day after this nightly's cut, via soakBypass below." + ], + "soakBypass": { + "version": "nightly-2026-08-20", + "published": "2026-08-20", + "removable": "2026-08-27" + } + }, "node": { "description": "Node.js — the pinned oracle for the builtin-module compatibility matrix (scripts/node_compat_matrix.mjs).", "version": "26.5.1",