You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
PR #1233 tests the linear memory host functions from synthetic wasm guest functions. There are a couple issues with these tests that would be nice to address:
They can probably all just reuse a single definition of the test linear memory pattern -- computed once during wasm synthesis and stored into the wasm as a data section -- rather than imperatively rewriting the contents of linear memory when they run. This is partly a speed issue, partly an issue around "it'd be nice to exercise the data section code paths of wasmi", and partly a simplification issue: if you calculate the LM during synthesis it's a little easier to dump out for inspection.
They probably don't need to be macro-generated? This I'm less certain about -- and it might still benefit from something macro-like such as the crossroads crate for factoring -- but I think the variation-between-tests ought not to be much larger than a couple lines each, and I think writing all those short tests in aggregate might not be much more code than this macro code, and would certainly be easier to understand, run individual tests of, etc.
This is a low-priority code-cleanup bug, not anything especially urgent.
The text was updated successfully, but these errors were encountered:
graydon
added
bug
Something isn't working
cleanup
non-observable improvements to the implementation
and removed
bug
Something isn't working
labels
Nov 21, 2023
PR #1233 tests the linear memory host functions from synthetic wasm guest functions. There are a couple issues with these tests that would be nice to address:
crossroads
crate for factoring -- but I think the variation-between-tests ought not to be much larger than a couple lines each, and I think writing all those short tests in aggregate might not be much more code than this macro code, and would certainly be easier to understand, run individual tests of, etc.This is a low-priority code-cleanup bug, not anything especially urgent.
The text was updated successfully, but these errors were encountered: