Stream: git-wasmtime

Topic: wasmtime / issue #6966 fuzzgen: Add SIMD only mode


view this post on Zulip Wasmtime GitHub notifications bot (Sep 05 2023 at 21:34):

afonso360 opened issue #6966:

:wave: Hey,

Feature

We should add a SIMD only mode to fuzzgen. Where every input generates at least one vector variable or maybe a vector instruction.

Benefit

This would have been really useful when developing the RISC-V SIMD backend since I was only really interested in fuzzing the newer SIMD instructions.

Implementation

An easy way to do this is to check the signature of every function generated by fuzzgen and reject it if it does not contain a vector type.

I think it would be nice to have this as an environment flag so that it would be usable during development.

Alternatives

We don't have to do this, fuzzgen will theoretically reach those inputs eventually. But in my experience it takes quite a while to generate the same coverage as doing this would.

cc: @alexcrichton

view this post on Zulip Wasmtime GitHub notifications bot (Sep 05 2023 at 21:51):

alexcrichton commented on issue #6966:

I think this is a great idea personally since the SIMD implementations have been the source of some of the more subtle bugs. One possible way to implement this is what we've done with the differential target where a Unstructured::ratio can be used to more-or-less bias one way or another. This way some of the input could be used to determine the SIMD-only mode flag if an env var isn't otherwise set. That way I think we'd still get good coverage while not needing a whole new fuzzer ideally


Last updated: Dec 23 2024 at 12:05 UTC