]> Cypherpunks repositories - gostls13.git/commit
cmd/internal/objabi: add new R_DWTXTADDR_* relocation types
authorThan McIntosh <thanm@golang.org>
Tue, 26 Nov 2024 22:08:01 +0000 (17:08 -0500)
committerThan McIntosh <thanm@golang.org>
Sat, 22 Feb 2025 21:32:19 +0000 (13:32 -0800)
commit31b800abe6a599f001a545d98437b9d821cef5c2
tree11b75a6a1481b6cbcbc22264bf60dfcfd062232a
parent767e7680ec7ed541ccc2e1f32d04b077f5422d25
cmd/internal/objabi: add new R_DWTXTADDR_* relocation types

Add a set of new relocations to be used when the compiler is writing
debug information using DWARF version 5. No changes in compiler or
linker functionality, this patch just adds the relocations themselves
and some helper functions; uses will appear in a later patch. These
relocations are generated by the compiler when writing a DWARF DIE
attribute of form DW_FORM_addrx, or when writing a .debug_addr index
reference in a SDWARFRANGE or SDWARFLOC section. The target symbol of
the relocation is a function (STEXT symbol); the linker resolves the
relocation by replacing the target of the reloc with an index of a
slot in the .debug_addr section (.debug_addr is new with DWARF5).

Updates #26379.

Change-Id: I43c587d25d0836972dac487d09c8924d77345f4e
Reviewed-on: https://go-review.googlesource.com/c/go/+/633880
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Reviewed-by: David Chase <drchase@google.com>
src/cmd/internal/objabi/reloctype.go
src/cmd/internal/objabi/reloctype_string.go