cmd/link: separate elf addend size from reloc size
The size of the field may be smaller than the addend, such is the case with R_PPC64_TOC16_HA/LO and similar relocations. Add an extra return value to ldelf.relSize to account for addend size which may be larger than the relocated field, and fix the related ppc64 relocations. Such relocs can be seen in large PIC blobs such as the ppc64le race detector included with golang. Change-Id: I457186fea5d0ec5572b9bbf79bb7fa21a36cc1b0 Reviewed-on: https://go-review.googlesource.com/c/go/+/303990 Run-TryBot: Paul Murphy <murp@ibm.com> Reviewed-by:Cherry Zhang <cherryyz@google.com> Reviewed-by:
Lynn Boger <laboger@linux.vnet.ibm.com> TryBot-Result: Go Bot <gobot@golang.org> Trust: Lynn Boger <laboger@linux.vnet.ibm.com>
Loading
Please sign in to comment