Stream: git-wasmtime

Topic: wasmtime / PR #5034 fuzzgen: Always generate reachable bl...


view this post on Zulip Wasmtime GitHub notifications bot (Oct 08 2022 at 20:24):

afonso360 opened PR #5034 from fuzzgen-reachable to main:

:wave: Hey,

This PR alters fuzzgen to always generate reachable blocks. See #5022 for context.

We do this by making sure that whenever we insert terminators at least one of the edges points to the next block.

Another thing this PR does is separate the CFG construction from block terminator insertion.

This fuzzed ok individually, but I'm now also testing with #5020 on top to see if it finds anything else.

cc: @jameysharp

view this post on Zulip Wasmtime GitHub notifications bot (Oct 12 2022 at 00:58):

jameysharp submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 12 2022 at 00:58):

jameysharp created PR review comment:

I believe you can write this as:

        .map(|_| u.choose(options).cloned())

view this post on Zulip Wasmtime GitHub notifications bot (Oct 12 2022 at 00:58):

jameysharp submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 12 2022 at 09:24):

afonso360 updated PR #5034 from fuzzgen-reachable to main.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 12 2022 at 09:27):

afonso360 updated PR #5034 from fuzzgen-reachable to main.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 12 2022 at 18:57):

cfallin submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 12 2022 at 18:57):

cfallin submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 12 2022 at 18:57):

cfallin created PR review comment:

Comment here describing why these checks (brtable targets can't have blockparams)?

view this post on Zulip Wasmtime GitHub notifications bot (Oct 12 2022 at 18:57):

cfallin created PR review comment:

The vec of boxed closures here is a little awkward -- is it forced only because we want to use the Arbitrary::choose() function below to pick out of a list?

I wonder if it would make sense to instead have something like

enum BlockTerminatorKind {
  Return,
  Jump,
  Cond,
  BrTable,
  ...
}

and then match on that and do generation as required (i.e. have a match kind { ... } that evaluates to a BlockTerminator)?

view this post on Zulip Wasmtime GitHub notifications bot (Oct 13 2022 at 11:29):

afonso360 submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 13 2022 at 11:29):

afonso360 created PR review comment:

The vec of boxed closures here is a little awkward -- is it forced only because we want to use the Arbitrary::choose() function below to pick out of a list?

Yeah, exactly.

I wonder if it would make sense to instead have something like and then match on that and do generation as required (i.e. have a match kind { ... } that evaluates to a BlockTerminator)?

Sounds Good :+1:

view this post on Zulip Wasmtime GitHub notifications bot (Oct 15 2022 at 17:28):

afonso360 updated PR #5034 from fuzzgen-reachable to main.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 15 2022 at 17:33):

afonso360 updated PR #5034 from fuzzgen-reachable to main.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 15 2022 at 17:44):

afonso360 updated PR #5034 from fuzzgen-reachable to main.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 17 2022 at 19:51):

cfallin submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Oct 17 2022 at 19:51):

cfallin merged PR #5034.


Last updated: Dec 23 2024 at 13:07 UTC