somdoron opened PR #13716 from somdoron:array-i8-slice to bytecodealliance:main:
Building a GC array of bytes from the host currently has to go through ArrayRef::new_fixed, which takes a slice of Val (32 bytes each) and writes one element at a time — a big transient allocation plus a per-element decode, with no faster path.
This adds new_from_i8_slice (+ async) and copy_to_i8_slice, which take a slice of u8 and fill/read the element body in a single memcpy, bypassing Val.
somdoron requested pchickey for a review on PR #13716.
somdoron requested wasmtime-core-reviewers for a review on PR #13716.
github-actions[bot] added the label wasmtime:api on PR #13716.
github-actions[bot] added the label wasmtime:ref-types on PR #13716.
github-actions[bot] commented on PR #13716:
Subscribe to Label Action
cc @fitzgen
<details>
This issue or pull request has been labeled: "wasmtime:api", "wasmtime:ref-types"Thus the following users have been cc'd because of the following labels:
- fitzgen: wasmtime:ref-types
To subscribe or unsubscribe from this label, edit the <code>.github/subscribe-to-label.json</code> configuration file.
Learn more.
</details>
fitzgen requested fitzgen for a review on PR #13716.
fitzgen unassigned pchickey from PR #13716 Add memcpy-based i8 array constructor and reader to ArrayRef.
:speech_balloon: fitzgen created PR review comment:
Ditto regarding MIRI
:speech_balloon: fitzgen created PR review comment:
This test doesn't compile+run any Wasm, so I don't think we need to ignore it under MIRI, and in fact seems like a good thing to exercise under MIRI.
:memo: fitzgen submitted PR review:
Thanks! Just two little nitpicks below to address before this merges
somdoron updated PR #13716.
:memo: somdoron submitted PR review.
:speech_balloon: somdoron created PR review comment:
fixed
:memo: somdoron submitted PR review.
:speech_balloon: somdoron created PR review comment:
fixed
:thumbs_up: fitzgen submitted PR review:
Thanks!
fitzgen added PR #13716 Add memcpy-based i8 array constructor and reader to ArrayRef to the merge queue.
:check: fitzgen merged PR #13716.
fitzgen removed PR #13716 Add memcpy-based i8 array constructor and reader to ArrayRef from the merge queue.
Last updated: Jul 29 2026 at 05:03 UTC