diff options
| author | Ian Lance Taylor <iant@golang.org> | 2025-11-02 13:54:22 -0800 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2025-11-04 16:38:05 -0800 |
| commit | 7347b54727519eecf693e9c10c504dc28611cbbf (patch) | |
| tree | e14a50efa08ed2e21936fc556557498fc4f87360 /src/cmd/internal/objfile/plan9obj.go | |
| parent | 6914dd11c05678e78a50d6bd0c6f6789e00f6d6d (diff) | |
| download | go-7347b54727519eecf693e9c10c504dc28611cbbf.tar.xz | |
cmd/link: don't generate .gosymtab section
Since Go 1.2 the section is always empty.
Also remove the code looking for .gosymtab in cmd/internal/objfile.
For #76038
Change-Id: Icd34c870ed0c6da8001e8d32305f79905ee2b066
Reviewed-on: https://go-review.googlesource.com/c/go/+/717200
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Auto-Submit: Ian Lance Taylor <iant@golang.org>
Commit-Queue: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Michael Pratt <mpratt@google.com>
Diffstat (limited to 'src/cmd/internal/objfile/plan9obj.go')
| -rw-r--r-- | src/cmd/internal/objfile/plan9obj.go | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/cmd/internal/objfile/plan9obj.go b/src/cmd/internal/objfile/plan9obj.go index c91970762c..edd40230ce 100644 --- a/src/cmd/internal/objfile/plan9obj.go +++ b/src/cmd/internal/objfile/plan9obj.go @@ -71,24 +71,17 @@ func (f *plan9File) symbols() ([]Sym, error) { return syms, nil } -func (f *plan9File) pcln() (textStart uint64, symtab, pclntab []byte, err error) { +func (f *plan9File) pcln() (textStart uint64, pclntab []byte, err error) { textStart = f.plan9.LoadAddress + f.plan9.HdrSize if pclntab, err = loadPlan9Table(f.plan9, "runtime.pclntab", "runtime.epclntab"); err != nil { // We didn't find the symbols, so look for the names used in 1.3 and earlier. // TODO: Remove code looking for the old symbols when we no longer care about 1.3. var err2 error if pclntab, err2 = loadPlan9Table(f.plan9, "pclntab", "epclntab"); err2 != nil { - return 0, nil, nil, err + return 0, nil, err } } - if symtab, err = loadPlan9Table(f.plan9, "runtime.symtab", "runtime.esymtab"); err != nil { - // Same as above. - var err2 error - if symtab, err2 = loadPlan9Table(f.plan9, "symtab", "esymtab"); err2 != nil { - return 0, nil, nil, err - } - } - return textStart, symtab, pclntab, nil + return textStart, pclntab, nil } func (f *plan9File) text() (textStart uint64, text []byte, err error) { |
