Commit Graph

10 Commits

Author SHA1 Message Date
Andrew Brown
0c7885cc05 fuzz: improve wasm-spec-interpreter documentation, add library path (#4007)
The documentation for the `wasm-spec-interpreter` was not up-to-date,
causing some confusion on non-Ubuntu machines. This change adds the
correct dependencies to install and includes the `libgmp` path for
Fedora by default (i.e., `/lib64`).
2022-04-11 09:07:58 -05:00
Alex Crichton
7b5176baea Upgrade all crates to the Rust 2021 edition (#3991)
* Upgrade all crates to the Rust 2021 edition

I've personally started using the new format strings for things like
`panic!("some message {foo}")` or similar and have been upgrading crates
on a case-by-case basis, but I think it probably makes more sense to go
ahead and blanket upgrade everything so 2021 features are always
available.

* Fix compile of the C API

* Fix a warning

* Fix another warning
2022-04-04 12:27:12 -05:00
Conrad Watt
c8daf0b8db support SIMD fuzzing in reference interpreter (#3980)
* support SIMD fuzzing in reference interpreter

* formatting
2022-03-31 10:07:39 -05:00
Alex Crichton
8aad99ffae Fix allowing an override of LIBGMP_PATHS (#3870)
This seems to have intended to allow overrides but the specific Makefile
syntax used didn't actually allow overrides, so update that to allow env
vars from the outside world to override the variable (needed locally on
AArch64 I'm building on which has a different path to libgmp)
2022-03-02 11:41:59 -06:00
Alex Crichton
f0fa01d552 Pin spec interpreter to a specific revision (#3868)
This commit updates the build script which clones the spec interpreter
for fuzzing to specifically pin at a hardcoded revision. This is
intended at improving reproducibility if we hit any issues while fuzzing
to ensure that the same wasmtime revision is always using the same spec
interpreter revision.
2022-03-02 10:54:05 -06:00
Conrad Watt
98ef18a22a Fuzzing against verified fork of spec interpreter (#3843)
* Revert "Remove spec interpreter fuzz target temporarily (#3399)"

This reverts commit 25d3fa4d7b.

* add support for differential fuzzing against verified OCaml interpreter

* formatting

* comments

* fix missing dep case

* fix build error

* fix unit tests?

* restore previous differential_v8 max_table config

* attempt: add OCaml deps

* fix interpeter github repo

* fix spec repo url

* fix zarith package

* fix unit test
2022-03-01 12:01:46 -06:00
Alex Crichton
25d3fa4d7b Remove spec interpreter fuzz target temporarily (#3399)
This commit removes the `differential_spec` fuzz target for now,
although this removal is intended to be temporary. We have #3251 to
track re-enabling the spec interpreter in a way that it won't time out,
and additionally the spec interpreter is also failing to build with
ocaml on oss-fuzz so that will also need to be investigated when
re-enabling.
2021-09-30 13:09:19 -05:00
Chris Fallin
b2bcdd13ec Spec-interpreter fuzzing: check out fuzzing branch of our mirror. (#3222)
In #3186, we found an issue that requires patching the spec interpreter
for now. Our plan is to have a `fuzzing` branch in our spec-repo mirror
that lets us make these fixes locally before they are upstreamed.
This PR updates the build script for the spec-interpreter wrapper
crate to clone this particular `fuzzing` branch instead of the main
branch.
2021-08-20 12:54:52 -05:00
Andrew Brown
42acb72c54 fuzz: retrieve the WebAssembly spec repository in build.rs
To avoid the large download size of the spec repository mentioned
[here](https://github.com/bytecodealliance/wasmtime/pull/3124#discussion_r684605984),
this change removes it as a submodule and instead clones it shallowly
when the directory is empty (or not present) when `build.rs` is run.
2021-08-10 11:56:07 -07:00
Andrew Brown
a7f592a026 Add a crate to interface with the WebAssembly spec interpreter
The WebAssembly spec interpreter is written in OCaml and the new crate
uses `ocaml-interop` along with a small OCaml wrapper to interpret Wasm
modules in-process. The build process for this crate is currently
Linux-specific: it requires several OCaml packages (e.g. `apt install -y
ocaml-nox ocamlbuild`) as well as `make`, `cp`, and `ar`.
2021-08-10 11:56:07 -07:00