runtime: add linkname back on `runtime.lastmoduledatap`
Fixes #71672
diff --git a/src/runtime/symtab.go b/src/runtime/symtab.go
index c3bd510..0419fcc 100644
--- a/src/runtime/symtab.go
+++ b/src/runtime/symtab.go
@@ -480,7 +480,13 @@
// the relocated one.
var aixStaticDataBase uintptr // linker symbol
-var firstmoduledata moduledata // linker symbol
+var firstmoduledata moduledata // linker symbol
+
+// Do not remove or change the type signature.
+// See go.dev/issue/67401.
+// See go.dev/issues/71672.
+//
+//go:linkname lastmoduledatap runtime.lastmoduledatap
var lastmoduledatap *moduledata // linker symbol
var modulesSlice *[]*moduledata // see activeModules
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
I spotted some possible problems.
These findings are based on simple heuristics. If a finding appears wrong, briefly reply here saying so. Otherwise, please address any problems and update the GitHub PR. When complete, mark this comment as 'Done' and click the [blue 'Reply' button](https://go.dev/wiki/GerritBot#i-left-a-reply-to-a-comment-in-gerrit-but-no-one-but-me-can-see-it) above.
Possible problems detected:
1. The commit message body is very brief. That can be OK if the change is trivial like correcting spelling or fixing a broken link, but usually the description should provide context for the change and explain what it does in complete sentences.
The commit title and commit message body come from the GitHub PR title and description, and must be edited in the GitHub web interface (not via git). For instructions, see [here](https://go.dev/wiki/GerritBot/#how-does-gerritbot-determine-the-final-commit-message). For guidelines on commit messages for the Go project, see [here](https://go.dev/doc/contribute#commit_messages).
(In general for Gerrit code reviews, the change author is expected to [log in to Gerrit](https://go-review.googlesource.com/login/) with a Gmail or other Google account and then close out each piece of feedback by marking it as 'Done' if implemented as suggested or otherwise reply to each review comment. See the [Review](https://go.dev/doc/contribute#review) section of the Contributing Guide for details.)
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Congratulations on opening your first change. Thank you for your contribution!
Next steps:
A maintainer will review your change and provide feedback. See
https://go.dev/doc/contribute#review for more info and tips to get your
patch through code review.
Most changes in the Go project go through a few rounds of revision. This can be
surprising to people new to the project. The careful, iterative review process
is our way of helping mentor contributors and ensuring that their contributions
have a lasting impact.
During May-July and Nov-Jan the Go project is in a code freeze, during which
little code gets reviewed or merged. If a reviewer responds with a comment like
R=go1.11 or adds a tag like "wait-release", it means that this CL will be
reviewed as part of the next development cycle. See https://go.dev/s/release
for more details.
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
// See go.dev/issue/67401.
This links to https://github.com/golang/go/issues/created_by/67401 which is wrong.(`s,issue,issues,g`)
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
This needs the full "hall of shame" list of packages that need it. See what it used to look like in https://go.dev/cl/609918.
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
This links to https://github.com/golang/go/issues/created_by/67401 which is wrong.(`s,issue,issues,g`)
Acknowledged
This needs the full "hall of shame" list of packages that need it. See what it used to look like in https://go.dev/cl/609918.
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
I spotted some possible problems.
These findings are based on simple heuristics. If a finding appears wrong, briefly reply here saying so. Otherwise, please address any problems and update the GitHub PR. When complete, mark this comment as 'Done' and click the [blue 'Reply' button](https://go.dev/wiki/GerritBot#i-left-a-reply-to-a-comment-in-gerrit-but-no-one-but-me-can-see-it) above.
Possible problems detected:
1. The commit message body is very brief. That can be OK if the change is trivial like correcting spelling or fixing a broken link, but usually the description should provide context for the change and explain what it does in complete sentences.The commit title and commit message body come from the GitHub PR title and description, and must be edited in the GitHub web interface (not via git). For instructions, see [here](https://go.dev/wiki/GerritBot/#how-does-gerritbot-determine-the-final-commit-message). For guidelines on commit messages for the Go project, see [here](https://go.dev/doc/contribute#commit_messages).
(In general for Gerrit code reviews, the change author is expected to [log in to Gerrit](https://go-review.googlesource.com/login/) with a Gmail or other Google account and then close out each piece of feedback by marking it as 'Done' if implemented as suggested or otherwise reply to each review comment. See the [Review](https://go.dev/doc/contribute#review) section of the Contributing Guide for details.)
Acknowledged
Yi DuanThis links to https://github.com/golang/go/issues/created_by/67401 which is wrong.(`s,issue,issues,g`)
Acknowledged
resolved
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
//go:linkname pluginsMu plugin.pluginsMu
We never had a linkname on pluginsMu. Does sonic need this? If so, how did sonic work with 1.23?
//go:linkname morestack_noctxt runtime.morestack_noctxt
The target name is not necessary.
```suggestion
//go:linkname morestack_noctxt
```
//go:linkname lastmoduledatap runtime.lastmoduledatap
```suggestion
//go:linkname lastmoduledatap
```
//go:linkname moduledataverify1 runtime.moduledataverify1
```suggestion
//go:linkname moduledataverify1
```
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
//go:linkname pluginsMu plugin.pluginsMu
We never had a linkname on pluginsMu. Does sonic need this? If so, how did sonic work with 1.23?
It can work before. But we found it may cause data-race when using go/pluing and sonic together recently...That's why we want to use this lock to avoid the concurrently-register-moduledata problem
//go:linkname morestack_noctxt runtime.morestack_noctxt
The target name is not necessary.
```suggestion
//go:linkname morestack_noctxt
```
Acknowledged
//go:linkname lastmoduledatap runtime.lastmoduledatap
Yi Duan```suggestion
//go:linkname lastmoduledatap
```
Acknowledged
//go:linkname moduledataverify1 runtime.moduledataverify1
Yi Duan```suggestion
//go:linkname moduledataverify1
```
Acknowledged
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
//go:linkname pluginsMu plugin.pluginsMu
Yi DuanWe never had a linkname on pluginsMu. Does sonic need this? If so, how did sonic work with 1.23?
It can work before. But we found it may cause data-race when using go/pluing and sonic together recently...That's why we want to use this lock to avoid the concurrently-register-moduledata problem
Done
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
//go:linkname pluginsMu plugin.pluginsMu
Yi DuanWe never had a linkname on pluginsMu. Does sonic need this? If so, how did sonic work with 1.23?
Yi DuanIt can work before. But we found it may cause data-race when using go/pluing and sonic together recently...That's why we want to use this lock to avoid the concurrently-register-moduledata problem
Done
Please open a new issue to discuss this and remove from this CL. Since this is a completely new linkname it is out of scope for this CL, which is just restoring linknames that existed previously.
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
//go:linkname pluginsMu plugin.pluginsMu
Yi DuanWe never had a linkname on pluginsMu. Does sonic need this? If so, how did sonic work with 1.23?
Yi DuanIt can work before. But we found it may cause data-race when using go/pluing and sonic together recently...That's why we want to use this lock to avoid the concurrently-register-moduledata problem
Michael PrattDone
Please open a new issue to discuss this and remove from this CL. Since this is a completely new linkname it is out of scope for this CL, which is just restoring linknames that existed previously.
Acknowledged
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Code-Review | +2 |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Auto-Submit | +1 |
Code-Review | +2 |
Commit-Queue | +1 |
Thanks.
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
9 is the latest approved patch-set.
No files were changed between the latest approved patch-set and the submitted one.
runtime: add some linknames back for `github.com/bytedance/sonic`
Add some linknames back, therefore sonic (github.com/bytedance/sonic) can work correctly.
Fixes #71672
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |