Files
wasmtime/fuzz/fuzz_targets/compile.rs
Sergei Pepyakin 5b8be5f262 Move compilation into Module from Instance. (#822)
* Move compilation into Module from Instance.

* Fix fuzzing

* Use wasmtime::Module in fuzzing crates

Instead of wasmtime_jit.

* Compile eagerly.

* Review fixes.

* Always use the saved name.

* Preserve the former behavior for fuzzing oracle
2020-01-16 16:37:10 -06:00

15 lines
401 B
Rust

#![no_main]
use libfuzzer_sys::fuzz_target;
use wasmtime::Strategy;
use wasmtime_fuzzing::{oracles, with_log_wasm_test_case};
fuzz_target!(|data: &[u8]| {
with_log_wasm_test_case!(data, |data| oracles::compile(data, Strategy::Cranelift));
});
#[cfg(feature = "lightbeam")]
fuzz_target!(|data: &[u8]| {
with_log_wasm_test_case!(data, |data| oracles::compile(data, Strategy::Lightbeam));
});