diff options
| author | Aleksandr Nogikh <nogikh@google.com> | 2024-03-22 15:50:47 +0100 |
|---|---|---|
| committer | Aleksandr Nogikh <nogikh@google.com> | 2024-03-25 13:12:00 +0000 |
| commit | 5f4fe4debf19df557608f1b9d61e14c33d5dab82 (patch) | |
| tree | 6fc9b4bb5c2d786e0d0afa0035494903dc05fba8 /pkg/fuzzer/prio_queue.go | |
| parent | f85e28d8a74848f34bdfb105079245c3d38ff9ae (diff) | |
pkg/fuzzer: mix in exec fuzz and exec gen
The fuzzer may become too busy doing potentially very long hint jobs,
while we want it to also keep exploring other parts of the input space.
If there are only smash and hint jobs left, ignore them for 33% of
executions.
Reduce the number of smash iterations:
1) If new coverage is found, we will likely repeat the smash job with a
similar program.
2) We mostly do the same during exec fuzz anyway.
Diffstat (limited to 'pkg/fuzzer/prio_queue.go')
| -rw-r--r-- | pkg/fuzzer/prio_queue.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/pkg/fuzzer/prio_queue.go b/pkg/fuzzer/prio_queue.go index cb35cebf7..c67b6216c 100644 --- a/pkg/fuzzer/prio_queue.go +++ b/pkg/fuzzer/prio_queue.go @@ -19,6 +19,14 @@ func (p priority) greaterThan(other priority) bool { return false } } + for i := len(p); i < len(other); i++ { + if other[i] < 0 { + return true + } + if other[i] > 0 { + return false + } + } return false } |
