Skip to content

Conversation

kripken
Copy link
Member

@kripken kripken commented Oct 7, 2025

Using our interpreter in addition to V8 allows our assertions to also
be checked, potentially finding more issues.

Also, we can run our interpreter on more code (e.g. V8 comparisons
are unreliable if there are NANs, due to V8's nondeterminism
differing from ours).

To make this work, fix execution-results to match fuzz_shell.js's
behavior: First instantiate both modules when running two of
them, and then run their exports (this makes it easy to see if
we error during instantiation).

@kripken kripken requested a review from tlively October 7, 2025 21:19
@kripken
Copy link
Member Author

kripken commented Oct 7, 2025

This must wait to land on fixing the issues this finds. So far I see one with imported tags.

if output == IGNORE:
return

if output.startswith(INSTANTIATE_ERROR):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can probably skip the check below and immediately report a problem, since our interpreter did not trap in instantiation. It also might be worth checking the other direction by running V8 when the interpreter traps in instantiation to make sure V8 also traps in instantiation.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are host errors though which differ between VMs, like limits on array.new size etc.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, but we do handle IGNORE earlier, so you are right: only deterministic things should remain at this point. I simplified it now.

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.

2 participants