Skip to content

BridgeJS: Take ownership of source Uint8Array id in swift_js_init_memory#635

Merged
kateinoigakukun merged 1 commit intomainfrom
yt/remove-cleanups
Feb 16, 2026
Merged

BridgeJS: Take ownership of source Uint8Array id in swift_js_init_memory#635
kateinoigakukun merged 1 commit intomainfrom
yt/remove-cleanups

Conversation

@kateinoigakukun
Copy link
Member

@kateinoigakukun kateinoigakukun commented Feb 15, 2026

This allows us to insert cleanup code for String parameter passing for JS -> Swift.

Verified no noticeable performance difference for String passing from JS to Swift.

Benchmarks (yt/remove-cleanups $=)$ node run.js --baseline=.build/baseline.json --filter "StringRoundtrip/takeString"
Starting benchmark suite with 10 runs per test...
Will compare with baseline: .build/baseline.json

Overall Progress:
Benchmark Runs: [██████████████████████████████] 10/10


==============================
      BENCHMARK SUMMARY
==============================

┌─────────┬──────────────────────────────┬──────────┬──────────┬──────────┬─────────────┬────────┬─────────┐
│ (index) │ Test                         │ Avg (ms) │ Min (ms) │ Max (ms) │ StdDev (ms) │ CV (%) │ Samples │
├─────────┼──────────────────────────────┼──────────┼──────────┼──────────┼─────────────┼────────┼─────────┤
│ 0       │ 'StringRoundtrip/takeString' │ '27.40'  │ '26.53'  │ '29.47'  │ '0.83'      │ '3.03' │ 10      │
└─────────┴──────────────────────────────┴──────────┴──────────┴──────────┴─────────────┴────────┴─────────┘

==============================
   COMPARISON WITH BASELINE
==============================

Test                       | Status   | Baseline (ms)   | Current (ms)    | Change          | Change (%)
--------------------------------------------------------------------------------------------------------
StringRoundtrip/takeString | NEUTRAL  | 27.55           | 27.40           | -0.15 ms        | -0.54%

cursor[bot]

This comment was marked as resolved.

…mory`

This allows us to insert cleanup code for String parameter passing for JS -> Swift.
@kateinoigakukun kateinoigakukun changed the title BridgeJSLink: remove cleanup hooks BridgeJS: Take ownership of source Uint8Array id in swift_js_init_memory Feb 16, 2026
@kateinoigakukun kateinoigakukun merged commit 118db02 into main Feb 16, 2026
22 checks passed
@kateinoigakukun kateinoigakukun deleted the yt/remove-cleanups branch February 16, 2026 02:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant