binutils-gdb/include
Kuan-Lin Chen f1cd8b94e7 RISC-V: Support subtraction of .uleb128.
96d6e190e9

There are some known limitations for now,

* Do not shrink the length of the uleb128 value, even if the value is reduced
after relaxations.  Also reports error if the length grows up.

* The R_RISCV_SET_ULEB128 needs to be paired with and be placed before the
R_RISCV_SUB_ULEB128.

bfd/
	* bfd-in2.h: Regenerated.
	* elfnn-riscv.c (perform_relocation): Perform R_RISCV_SUB_ULEB128 and
	R_RISCV_SET_ULEB128 relocations.  Do not shrink the length of the
	uleb128 value, and report error if the length grows up.  Called the
	generic functions, _bfd_read_unsigned_leb128 and _bfd_write_unsigned_leb128,
	to encode the uleb128 into the section contents.
	(riscv_elf_relocate_section): Make sure that the R_RISCV_SET_ULEB128
	must be paired with and be placed before the R_RISCV_SUB_ULEB128.
	* elfxx-riscv.c (howto_table): Added R_RISCV_SUB_ULEB128 and
	R_RISCV_SET_ULEB128.
	(riscv_reloc_map): Likewise.
	(riscv_elf_ignore_reloc): New function.
	* libbfd.h: Regenerated.
	* reloc.c (BFD_RELOC_RISCV_SET_ULEB128, BFD_RELOC_RISCV_SUB_ULEB128):
	New relocations to support .uleb128 subtraction.
gas/
	* config/tc-riscv.c (md_apply_fix): Added BFD_RELOC_RISCV_SET_ULEB128
	and BFD_RELOC_RISCV_SUB_ULEB128.
	(s_riscv_leb128): Updated to allow uleb128 subtraction.
	(riscv_insert_uleb128_fixes): New function, scan uleb128 subtraction
	expressions and insert fixups for them.
	(riscv_md_finish): Called riscv_insert_uleb128_fixes for all sections.
include/
	* elf/riscv.h ((R_RISCV_SET_ULEB128, (R_RISCV_SUB_ULEB128): Defined.
ld/
	* testsuite/ld-riscv-elf/ld-riscv-elf.exp: Updated.
	* testsuite/ld-riscv-elf/uleb128*: New testcase for uleb128 subtraction.
binutils/
	* testsuite/binutils-all/nm.exp: Updated since RISCV supports .uleb128.
2023-05-19 16:24:10 +08:00
..
aout Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
cgen Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
coff Re: Keeping track of rs6000-coff archive element pointers 2023-04-28 15:19:59 +09:30
elf RISC-V: Support subtraction of .uleb128. 2023-05-19 16:24:10 +08:00
gdb Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
mach-o Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
opcode RISC-V: Support XVentanaCondOps extension 2023-04-26 14:09:34 -06:00
sim sim: info: convert verbose field to a bool 2023-01-18 20:47:55 -05:00
som Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
vms Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
alloca-conf.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
ansidecl.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
bfdlink.h ppc32 and "LOAD segment with RWX permissions" 2023-02-06 23:06:44 +10:30
binary-io.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
bout.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
ChangeLog Add support to readelf for the PT_OPENBSD_MUTABLE segment type. 2023-03-23 15:19:38 +00:00
ChangeLog-0415 binutils ChangeLog rotation 2016-01-01 22:59:17 +10:30
ChangeLog-2016 ChangeLog rotation 2017-01-02 13:55:05 +10:30
ChangeLog-2017 ChangeLog rotation 2018-01-03 17:49:42 +10:30
ChangeLog-2018 ChangeLog rotation 2019-01-01 21:25:40 +10:30
ChangeLog-2019 ChangeLog rotation 2020-01-01 18:12:08 +10:30
ChangeLog-2020 ChangeLog rotation 2021-01-01 10:31:02 +10:30
ChangeLog-9103 Add copyright notices 2012-12-10 12:48:03 +00:00
collectorAPI.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
COPYING
COPYING3
ctf-api.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
ctf.h ctf: fix various dreadful typos in the ctf_archive format comments 2023-01-12 14:40:47 +00:00
demangle.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
diagnostics.h gdbsupport: ignore -Wenum-constexpr-conversion in enum-flags.h 2023-03-06 21:00:52 -05:00
dis-asm.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
dwarf2.def Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
dwarf2.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
dyn-string.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
environ.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
fibheap.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
filenames.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
floatformat.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
fnmatch.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
fopen-bin.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
fopen-same.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
fopen-vms.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
gcc-c-fe.def Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
gcc-c-interface.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
gcc-cp-fe.def Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
gcc-cp-interface.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
gcc-interface.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
getopt.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
hashtab.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
hp-symtab.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
leb128.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
libcollector.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
libfcollector.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
libiberty.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
longlong.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
lto-symtab.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
MAINTAINERS Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
md5.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
oasys.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
objalloc.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
obstack.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
os9k.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
partition.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
plugin-api.h PR29961, plugin-api.h: "Could not detect architecture endianess" 2023-05-17 11:21:43 +09:30
safe-ctype.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
sframe-api.h sframe: fix the defined SFRAME_FRE_TYPE_*_LIMIT constants 2023-01-06 09:30:56 -08:00
sframe.h sframe: correct some typos 2023-04-19 14:37:59 -07:00
sha1.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
simple-object.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
sort.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
splay-tree.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
symcat.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
timeval-utils.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
vtv-change-permission.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
xregex2.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
xregex.h merge from gcc 2011-07-25 17:11:48 +00:00
xtensa-config.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
xtensa-dynconfig.h gcc-4.5 build fixes 2023-05-17 11:21:43 +09:30
xtensa-isa-internal.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30
xtensa-isa.h Update year range in copyright notice of binutils files 2023-01-01 21:50:11 +10:30