mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
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>
This commit is contained in:
parent
6914dd11c0
commit
7347b54727
15 changed files with 76 additions and 128 deletions
|
|
@ -79,21 +79,16 @@ func (f *machoFile) symbols() ([]Sym, error) {
|
|||
return syms, nil
|
||||
}
|
||||
|
||||
func (f *machoFile) pcln() (textStart uint64, symtab, pclntab []byte, err error) {
|
||||
func (f *machoFile) pcln() (textStart uint64, pclntab []byte, err error) {
|
||||
if sect := f.macho.Section("__text"); sect != nil {
|
||||
textStart = sect.Addr
|
||||
}
|
||||
if sect := f.macho.Section("__gosymtab"); sect != nil {
|
||||
if symtab, err = sect.Data(); err != nil {
|
||||
return 0, nil, nil, err
|
||||
}
|
||||
}
|
||||
if sect := f.macho.Section("__gopclntab"); sect != nil {
|
||||
if pclntab, err = sect.Data(); err != nil {
|
||||
return 0, nil, nil, err
|
||||
return 0, nil, err
|
||||
}
|
||||
}
|
||||
return textStart, symtab, pclntab, nil
|
||||
return textStart, pclntab, nil
|
||||
}
|
||||
|
||||
func (f *machoFile) text() (textStart uint64, text []byte, err error) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue