-
Notifications
You must be signed in to change notification settings - Fork 18k
iter: incorrect race instrumentation is causing false positives in iter.Pull2
#64651
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
Comments
This can be reproduced just by running the iter tests with -race
|
I see some unresolved comments in the original CL that were left unresolved, I wonder if this is related |
@golang/release @rsc Since the iter package will be released with 1.22 I think this fix should be included. |
iter.Pull2
iter.Pull2
Leaving as release blocker for now. |
Change https://go.dev/cl/548895 mentions this issue: |
This only impacts |
Pull2 tests are failing with -race, giving false-positive race conditions due to bad race instrumentation. No tests for this as it should be caught by the race builders. The only reason it was not caught is because it is behind GOEXPERIMENT=rangefunc. Fixes golang#64651 Change-Id: I20554da930b0e19594e0e267f01a1e7a9cbc577a GitHub-Last-Rev: 7c1f192 GitHub-Pull-Request: golang#64653 Reviewed-on: https://go-review.googlesource.com/c/go/+/548895 LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Cherry Mui <[email protected]> Reviewed-by: Michael Knyszek <[email protected]>
Go version
go version devel go1.22-46ea4ab Sat Dec 9 21:48:06 2023 +0000 windows/amd64
What operating system and processor architecture are you using (
go env
)?What did you do?
GOEXPERIMENT=rangefunc gotip test -race ./race_test.go
the
race_test.go
file content:What did you expect to see?
The test run successfully.
What did you see instead?
A data race error:
The text was updated successfully, but these errors were encountered: