Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

internal/fuzz: generated corpus not being run before fuzzing #50972

Closed
katiehockman opened this issue Feb 2, 2022 · 1 comment
Closed

internal/fuzz: generated corpus not being run before fuzzing #50972

katiehockman opened this issue Feb 2, 2022 · 1 comment
Labels
FrozenDueToAge fuzz Issues related to native fuzzing support NeedsFix The path to resolution is known, but the work has not been done. release-blocker
Milestone

Comments

@katiehockman
Copy link
Contributor

It looks like there is a regression with the beta2 where the generated corpus is not being run before fuzzing begins.

This also means that we have a gap in our testing that needs to be fixed as well.

It can be shown with two fuzzing executions back to back:

➜ go test -fuzz=Fuzz
fuzz: elapsed: 0s, gathering baseline coverage: 0/4 completed
fuzz: elapsed: 0s, gathering baseline coverage: 4/4 completed, now fuzzing with 8 workers
fuzz: elapsed: 3s, execs: 353778 (117925/sec), new interesting: 31 (total: 31)
fuzz: elapsed: 6s, execs: 977881 (208033/sec), new interesting: 35 (total: 35)
PASS
ok      example/fuzz    9.176s

35 entries were added to the generated corpus

➜ go test -fuzz=Fuzz
fuzz: elapsed: 0s, gathering baseline coverage: 0/4 completed
fuzz: elapsed: 0s, gathering baseline coverage: 4/4 completed, now fuzzing with 8 workers
fuzz: elapsed: 3s, execs: 452608 (150863/sec), new interesting: 31 (total: 31)
fuzz: elapsed: 6s, execs: 1025174 (190850/sec), new interesting: 35 (total: 35)
fuzz: elapsed: 9s, execs: 1554990 (176613/sec), new interesting: 35 (total: 35)
fuzz: elapsed: 12s, execs: 2087450 (177490/sec), new interesting: 37 (total: 37)
PASS
ok      example/fuzz    12.994s

Note that only 4 entries were run for the baseline coverage, which is the size of the seed corpus. So the generated corpus wasn't run.

@katiehockman katiehockman added NeedsFix The path to resolution is known, but the work has not been done. release-blocker fuzz Issues related to native fuzzing support labels Feb 2, 2022
@katiehockman katiehockman added this to the Go1.18 milestone Feb 2, 2022
@katiehockman katiehockman self-assigned this Feb 2, 2022
@katiehockman
Copy link
Contributor Author

Ah, this is a dupe of Issue #50913 and has been fixed.

@golang golang locked and limited conversation to collaborators Jun 22, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge fuzz Issues related to native fuzzing support NeedsFix The path to resolution is known, but the work has not been done. release-blocker
Projects
Status: No status
Development

No branches or pull requests

2 participants