]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/link: don't include arginfo symbols in symbol table
authorCherry Mui <cherryyz@google.com>
Thu, 6 May 2021 20:16:19 +0000 (16:16 -0400)
committerCherry Mui <cherryyz@google.com>
Fri, 7 May 2021 14:13:18 +0000 (14:13 +0000)
We recently add arginfo symbols for traceback argument metadata.
Like other metadata symbols (GC bitmaps, opendefer info, etc.),
skip arginfo symbols for symbol table as well.

Fixes #45971.

Change-Id: I7a126b75f70ec88e2170e9a274d968762c7bce56
Reviewed-on: https://go-review.googlesource.com/c/go/+/317769
Trust: Cherry Mui <cherryyz@google.com>
Run-TryBot: Cherry Mui <cherryyz@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Than McIntosh <thanm@google.com>
src/cmd/link/internal/ld/symtab.go

index 3b4fda0c89a4ab963bf05975e18d6a06dc82ee95..00f557875a939a0dc1addf0d9319ae64e628b1c0 100644 (file)
@@ -585,7 +585,9 @@ func (ctxt *Link) symtab(pcln *pclntab) []sym.SymKind {
                        strings.HasPrefix(name, "gclocals."),
                        strings.HasPrefix(name, "gclocals·"),
                        ldr.SymType(s) == sym.SGOFUNC && s != symgofunc,
-                       strings.HasSuffix(name, ".opendefer"):
+                       strings.HasSuffix(name, ".opendefer"),
+                       strings.HasSuffix(name, ".arginfo0"),
+                       strings.HasSuffix(name, ".arginfo1"):
                        symGroupType[s] = sym.SGOFUNC
                        ldr.SetAttrNotInSymbolTable(s, true)
                        ldr.SetCarrierSym(s, symgofunc)