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

cmd/compile, cmd/link: use libFuzzer 8-bit instead of extra counters #51318

Closed

Conversation

kyakdan
Copy link
Contributor

@kyakdan kyakdan commented Feb 22, 2022

By using libFuzzer’s 8-bit counters instead of extra counters, the
coverage instrumentation in libFuzzer mode is improved in three ways:
1- 8-bit counters are supported on all platforms, including macOS and
Windows, with all relevant versions of libFuzzer, whereas extra
counters are a Linux-only feature that only recently received
support on Windows.
2- Newly covered blocks are now properly reported as new coverage by
libFuzzer, not only as new features.
3- The NeverZero strategy is used to ensure that coverage counters
never become 0 again after having been positive once. This resolves
issues encountered when fuzzing loops with iteration counts that
are multiples of 256 (e.g., larger powers of two).

@gopherbot
Copy link

This PR (HEAD: fce40f8) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/go/+/387334 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link

Message from Keith Randall:

Patch Set 1:

(6 comments)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

This PR (HEAD: 074c9dd) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/go/+/387334 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link

This PR (HEAD: 28781ec) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/go/+/387334 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link

This PR (HEAD: 3e0442f) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/go/+/387334 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link

Message from Khaled Yakdan:

Patch Set 3:

(6 comments)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Keith Randall:

Patch Set 4:

(8 comments)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Khaled Yakdan:

Patch Set 4:

(5 comments)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

This PR (HEAD: a039aba) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/go/+/387334 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link

Message from Keith Randall:

Patch Set 5: Code-Review+2

(2 comments)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Khaled Yakdan:

Patch Set 5:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

This PR (HEAD: 1d4e1ab) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/go/+/387334 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link

Message from Keith Randall:

Patch Set 6: Run-TryBot+1 Auto-Submit+1 Code-Review+2 Trust+1


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Gopher Robot:

Patch Set 6:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Gopher Robot:

Patch Set 6: TryBot-Result+1

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Keith Randall:

Patch Set 6: Code-Review+1


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Ian Lance Taylor:

Patch Set 6:

(4 comments)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

This PR (HEAD: da6823c) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/go/+/387334 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link

Message from Khaled Yakdan:

Patch Set 6:

(7 comments)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Keith Randall:

Patch Set 7: Run-TryBot+1 Code-Review+2

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Gopher Robot:

Patch Set 7:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Gopher Robot:

Patch Set 7: TryBot-Result+1

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Keith Randall:

Patch Set 7:

(3 comments)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Dmitri Shuralyov:

Patch Set 7: Code-Review+1


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Khaled Yakdan:

Patch Set 7:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

This PR (HEAD: a2410f4) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/go/+/387334 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link

This PR (HEAD: dcc9767) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/go/+/387334 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link

Message from Khaled Yakdan:

Patch Set 8:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Khaled Yakdan:

Patch Set 9:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link

Message from Keith Randall:

Patch Set 9: Code-Review+2

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

By using libFuzzer’s 8-bit counters instead of extra counters, the
coverage instrumentation in libFuzzer mode is improved in three ways:
  1- 8-bit counters are supported on all platforms, including macOS and
     Windows, with all relevant versions of libFuzzer, whereas extra
     counters are a Linux-only feature that only recently received
     support on Windows.
  2- Newly covered blocks are now properly reported as new coverage by
     libFuzzer, not only as new features.
  3- The NeverZero strategy is used to ensure that coverage counters
     never become 0 again after having been positive once. This resolves
     issues encountered when fuzzing loops with iteration counts that
     are multiples of 256 (e.g., larger powers of two).
@gopherbot
Copy link

This PR (HEAD: 9057e4b) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/go/+/387334 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link

Message from Khaled Yakdan:

Patch Set 9:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/387334.
After addressing review feedback, remember to publish your drafts!

gopherbot pushed a commit that referenced this pull request May 20, 2022
By using libFuzzer’s 8-bit counters instead of extra counters, the
coverage instrumentation in libFuzzer mode is improved in three ways:
  1- 8-bit counters are supported on all platforms, including macOS and
     Windows, with all relevant versions of libFuzzer, whereas extra
     counters are a Linux-only feature that only recently received
     support on Windows.
  2- Newly covered blocks are now properly reported as new coverage by
     libFuzzer, not only as new features.
  3- The NeverZero strategy is used to ensure that coverage counters
     never become 0 again after having been positive once. This resolves
     issues encountered when fuzzing loops with iteration counts that
     are multiples of 256 (e.g., larger powers of two).

Change-Id: I9021210d7fbffd07c891ad08750402ee91cb3df5
GitHub-Last-Rev: 9057e4b
GitHub-Pull-Request: #51318
Reviewed-on: https://go-review.googlesource.com/c/go/+/387334
Reviewed-by: Keith Randall <khr@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
@gopherbot
Copy link

This PR is being closed because golang.org/cl/387334 has been merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants