From: Matthew Dempsky Date: Sun, 27 Aug 2023 21:42:26 +0000 (-0700) Subject: cmd/compile/internal/ssagen: stop canonicalizing symabis X-Git-Tag: go1.22rc1~1046 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=98c26afa8c9c1016d205408e2afaba5824f4d930;p=gostls13.git cmd/compile/internal/ssagen: stop canonicalizing symabis cmd/asm writes canonicalized symabis now. Change-Id: I65cc39ce1671a3c225f14003b336015f0cc33980 Reviewed-on: https://go-review.googlesource.com/c/go/+/523339 Auto-Submit: Matthew Dempsky Reviewed-by: Cherry Mui Run-TryBot: Matthew Dempsky TryBot-Result: Gopher Robot --- diff --git a/src/cmd/compile/internal/ssagen/abi.go b/src/cmd/compile/internal/ssagen/abi.go index a5f1a2db60..f65fe497ec 100644 --- a/src/cmd/compile/internal/ssagen/abi.go +++ b/src/cmd/compile/internal/ssagen/abi.go @@ -41,12 +41,8 @@ func NewSymABIs() *SymABIs { // both to use the full path, which matches compiler-generated linker // symbol names. func (s *SymABIs) canonicalize(linksym string) string { - // If the symbol is already prefixed with "", rewrite it to start - // with LocalPkg.Prefix. - // - // TODO(mdempsky): Have cmd/asm stop writing out symbols like this. if strings.HasPrefix(linksym, `"".`) { - return types.LocalPkg.Prefix + linksym[2:] + panic("non-canonical symbol name: " + linksym) } return linksym }