Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create WebAssembly Representer #33

Closed
bushidocodes opened this issue Feb 20, 2022 · 1 comment
Closed

Create WebAssembly Representer #33

bushidocodes opened this issue Feb 20, 2022 · 1 comment

Comments

@bushidocodes
Copy link
Contributor

bushidocodes commented Feb 20, 2022

Initial thoughts:

  • WebAssembly names are essentially "sugar" over an index value.
  • S-Expressions are also "sugar"

There is a wabt tool called wat-desugar that can strip this stuff out.

I suspect that wasm-opcodecnt might also be useful when comparing approaches for similarity. Unique opcodes would likely distinguish approaches to problems.

The wassail tool is also able to generate control flow graphs:
https://github.com/acieroid/wassail

Another approach might be to use wasm-opt passes from binaryen. However, this would likely complicate the code and make it less readable. This also is inherently lossy as it transforms the code for sake of efficiency.
https://github.com/webassembly/binaryen

@bushidocodes
Copy link
Contributor Author

Resolved by #83

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

No branches or pull requests

1 participant