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

runtime/race: implement race detector for ppc64le #23731

Closed
laboger opened this issue Feb 7, 2018 · 8 comments

Comments

Projects
None yet
5 participants
@laboger
Copy link
Contributor

commented Feb 7, 2018

What version of Go are you using (go version)?

Planned for go 1.11

What operating system and processor architecture are you using (go env)?

ppc64le any distro

/cc @dvyukov

@laboger

This comment has been minimized.

Copy link
Contributor Author

commented Feb 7, 2018

@ceseo and I are working on this, we can build golang and get the race tests to pass but now trying to get the LLVM code upstream.

@laboger

This comment has been minimized.

Copy link
Contributor Author

commented Mar 29, 2018

I have the golang changes, still waiting for the latest LLVM code to be submitted upstream so the syso can be built for ppc64le. (TSAN already works on ppc64le with Clang.)

@ceseo

This comment has been minimized.

Copy link
Contributor

commented Apr 16, 2018

@laboger LLVM changes merged into revision 330122.

You can proceed with your changes.

@laboger

This comment has been minimized.

Copy link
Contributor Author

commented Apr 16, 2018

We need to understand how to get the syso file built so it can be added to the runtime/race directory.

@gopherbot

This comment has been minimized.

Copy link

commented Apr 18, 2018

Change https://golang.org/cl/107935 mentions this issue: runtime/race: implement race detector for ppc64le

@gopherbot

This comment has been minimized.

Copy link

commented May 11, 2018

Change https://golang.org/cl/112881 mentions this issue: cmd/racebuild: add linux/ppc64le

gopherbot pushed a commit to golang/build that referenced this issue May 11, 2018

cmd/racebuild: add linux/ppc64le
Updates golang/go#19273.
Updates golang/go#24354.
Updates golang/go#23731.

Change-Id: Iad8870b265e7e3b56b5219d3367ccef70dcc0679
Reviewed-on: https://go-review.googlesource.com/112881
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>

gopherbot pushed a commit that referenced this issue Jun 11, 2018

runtime/race: implement race detector for ppc64le
This adds the support to enable the race detector for ppc64le.

Added runtime/race_ppc64le.s to manage the calls from Go to the
LLVM tsan functions, mostly converting from the Go ABI to the
PPC64 ABI expected by Clang generated code.

Changed racewalk.go to call racefuncenterfp instead of racefuncenter
on ppc64le to allow the caller pc to be obtained in the asm code
before calling the tsan version.

Changed the set up code for racecallbackthunk so it doesn't use
the autogenerated save and restore of the link register since that
sequence uses registers inconsistent with the normal ppc64 ABI.

Made various changes to recognize that race is supported for
ppc64le.

Ensured that tls_g is updated and accessible from race_linux_ppc64le.s
so that the race ctx can be obtained and passed to tsan functions.

This enables the race tests for ppc64le in cmd/dist/test.go and
increases the timeout when running the benchmarks with the -race
option to avoid timing out.

Updates #24354, #23731

Change-Id: Ib97dc7ac313e6313c836dc7d2fb698f9d8fba3ef
Reviewed-on: https://go-review.googlesource.com/107935
Run-TryBot: Lynn Boger <laboger@linux.vnet.ibm.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
@laboger

This comment has been minimized.

Copy link
Contributor Author

commented Jun 20, 2018

This is in.

@laboger laboger closed this Jun 20, 2018

@benesch

This comment has been minimized.

Copy link
Contributor

commented Sep 18, 2018

Should this line from racebuild be uncommented now that this is closed? https://github.com/golang/build/blob/1d8c3548c0bbc477bdf7cb400b72a4cf9c7d362e/cmd/racebuild/racebuild.go#L112

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.