mirror of
https://github.com/golang/go.git
synced 2026-04-02 09:20:29 +09:00
cmd/link/internal/loong64: remove the handling of R_CONST and R_GOTOFF from the internal linker
These two relocations are already handled in general code and do not require architecture-specific processing. Change-Id: Ibf29af1a8b45c0ce4c40061524f9f7dda4edfff3 Reviewed-on: https://go-review.googlesource.com/c/go/+/756280 Reviewed-by: Carlos Amedee <carlos@golang.org> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: abner chenc <chenguoqi@loongson.cn> Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
This commit is contained in:
@@ -563,12 +563,6 @@ func archreloc(target *ld.Target, ldr *loader.Loader, syms *ld.ArchSyms, r loade
|
||||
const noExtReloc = 0
|
||||
|
||||
switch r.Type() {
|
||||
case objabi.R_CONST:
|
||||
return r.Add(), noExtReloc, isOk
|
||||
|
||||
case objabi.R_GOTOFF:
|
||||
return ldr.SymValue(r.Sym()) + r.Add() - ldr.SymValue(syms.GOT), noExtReloc, isOk
|
||||
|
||||
case objabi.R_LOONG64_ADDR_HI,
|
||||
objabi.R_LOONG64_ADDR_LO,
|
||||
objabi.R_LOONG64_ADDR64_HI,
|
||||
|
||||
Reference in New Issue
Block a user