Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions quest/m2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ The fork's feature quests folded into the [exporter](/quest/m1/ffi-export.md);
- [Async in the TypeScript translator](/quest/m2/ts-async.md) - moq-net's and kio's async code translates with Rust's lazy futures
- [Shared ownership](/quest/m2/ts-shared.md) - `Arc`/`Rc`/`Weak` keep exact counts, and locks and atomics become plain values
- [Collection keys and element references](/quest/m2/ts-keys.md) - `Arc<str>` and `Option` keys, borrowed lookups, and `&mut` to a value in a collection translate
- [Copy by type](/quest/m2/ts-copy.md) - copying a `Copy` aggregate shares its references instead of deep-copying them
- [Translate char and vec![x]](/quest/m2/ts-char-vec.md) - `char` values and `vec![x]` translate, unblocking moq-net's refused sites
- [Firefox in the TS benchmark](/quest/m2/ts-bench-firefox.md) - SpiderMonkey joins Chrome, Bun, and Node in `just ts bench`
- [Translate moq-net's model to TypeScript](/quest/m2/ts-model.md) - the driver grows from moq-net's codec to its model, for moq to compare against WASM
- [Nightly MSVC and macOS](/quest/m2/uniffi-ci-msvc-macos.md) - the C and C++ fixtures compile nightly with MSVC and Apple Clang, at C++17 and C++20, and without exceptions or RTTI
- [Symlinked paths](/quest/m2/uniffi-symlink-path.md) - the fork builds when a consumer reaches it through a symlink, as on macOS's `/var`
Expand Down
16 changes: 16 additions & 0 deletions quest/m2/ts-bench-firefox.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# [S] Firefox in the TS benchmark

## Goal

`just ts bench` runs every route in Firefox (SpiderMonkey) alongside Chrome, Bun, and
Node, with the same A/A control, in CI and locally.

## Plan

Decided with the maintainer on 2026-10-26: the translator targets browsers, so
browser engines decide speed calls. Chrome (V8) and Bun (JavaScriptCore, as in
Safari) are covered; SpiderMonkey isn't. Node stays as a V8 proxy that's cheap to
run. Drive Firefox through the same harness Chrome uses, and report its numbers in
the bench summary.

Public API: none.
21 changes: 21 additions & 0 deletions quest/m2/ts-char-vec.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# [S] Translate char and vec![x]

## Goal

rust2-ts translates `char` values and `vec![x]` on the pinned nightly, proven by
differential tests against native Rust, which unblocks moq-net's 6 refused `char`
switches and 17 refused `vec![x]` sites.

## Plan

Decided with the maintainer on 2026-10-26, from
[#78](https://github.com/kixelated/rust2/pull/78)'s census.

- **`char`:** a number holding the Unicode scalar value, so it switches, compares,
and orders like Rust's. Conversions keep Rust's rules: `as u8` truncates,
`char::from_u32` rejects surrogates and values past `0x10FFFF`, and formatting
writes UTF-8 or UTF-16 as the target needs.
- **`vec![x]`:** lower the nightly's expansion (`from_elem` or the boxed-slice
route), including `vec![x; n]` with `Clone` semantics for each element.

Public API: the translator's output.
23 changes: 23 additions & 0 deletions quest/m2/ts-copy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# [S] Copy by type

## Goal

Copying a `Copy` aggregate in translated TypeScript copies its values and shares its
references, as Rust does. Today `rt.copy` deep-copies the aggregate, references
included: copying `(&Cell<u8>, u8)` clones the cell, so a write through the copy's
reference changes the clone instead of the original. Differential tests against
native Rust cover tuples, arrays, `Option`, `Result`, and structs holding shared
references to interior-mutable values.

## Plan

Decided with the maintainer on 2026-10-26, from a review finding on
[#78](https://github.com/kixelated/rust2/pull/78). The bug predates #78 and is a
silent miscompile, so either fix it or refuse the shapes it can't copy, with a span.

- Copy by the static type: the lowering knows which fields are references, so it
can emit a shallow copy for those and a value copy for the rest, instead of
one generic `rt.copy`.
- Measure the codec bench before and after; a typed copy should be no slower.

Public API: the translator's output.
1 change: 1 addition & 0 deletions quest/m3/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@ each a measurement that decides whether its follow-up lands.
- [Steadier edit numbers](/quest/m3/bench-edit-noise.md) - moq's edit scenarios compare night to night within a few percent
- [Retrial Cranelift on moq's tests](/quest/m3/cranelift-unwind.md) - waits on upstream: moq's tests pass under Cranelift, so its CI can weigh it again
- [Relink without rebuilding](/quest/m3/relink.md) - measure upstream's skip of dependency-only rebuilds on moq's edits once it reaches nightly
- [Bench only what changed](/quest/m3/bench-rerun.md) - a push reruns the build benchmark only when it changes a bench input since the last benched head
21 changes: 21 additions & 0 deletions quest/m3/bench-rerun.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# [S] Bench only what changed since the last run

## Goal

A push to a PR reruns the build benchmark only when it changes a bench input since
the PR's last benched head. A README, quest, or docs-only push after a benched one
skips every bench job, so it costs no runner time.

## Plan

Decided with the maintainer on 2026-10-26, after
[#74](https://github.com/kixelated/rust2/pull/74)'s README-only push reran every
job, about 2 runner-hours. The `Changed` job in `bench.yml` diffs the whole PR
against its base, so once a PR touches `bench/build`, every push reruns everything.

- Compare against the last head whose bench run succeeded on this PR, when there is
one, and against the base otherwise. Keep the flake-output comparison.
- Keep per-job filtering out: every job shares `run.sh`.
- A failed lookup runs the bench, so it never quietly skips.

Public API: none.