binutils-gdb/ld/testsuite
Kito Cheng fbc95f1e11 RISC-V: Add PT_RISCV_ATTRIBUTES and add it to PHDR.
We added PT_RISCV_ATTRIBUTES to program header to make
.riscv.attribute easier to find in dynamic loader or kernel.

Ref:
https://github.com/riscv/riscv-elf-psabi-doc/pull/71

ChangeLog:

bfd/

	* elfnn-riscv.c(RISCV_ATTRIBUTES_SECTION_NAME): New.
	(riscv_elf_additional_program_headers): Ditto.
	(riscv_elf_modify_segment_map): Ditto.
	(elf_backend_additional_program_headers): Ditto.
	(elf_backend_modify_segment_map): Ditto.
	(elf_backend_obj_attrs_section): Use RISCV_ATTRIBUTES_SECTION_NAME
	rather than string literal.

binutils/

	* readelf.c(get_riscv_segment_type): New.
	(get_segment_type): Handle EM_RISCV.

include/

	* elf/riscv.h (PT_RISCV_ATTRIBUTES): New.
	* testsuite/ld-elf/orphan-region.ld: Discard .riscv.attributes
	section for simplify testcase.
	* testsuite/ld-riscv-elf/attr-phdr.d: New.
	* testsuite/ld-riscv-elf/attr-phdr.s: Ditto.
	* testsuite/ld-riscv-elf/ld-riscv-elf.exp: Add attr-phdr to
	testcase.
2021-07-06 11:34:36 +08:00
..
config ld: Cache and reuse the IR archive file descriptor 2021-07-05 08:51:35 -07:00
ld-aarch64
ld-alpha
ld-arc
ld-arm arm: fix fallout from recent thumb2 detection patch 2021-05-12 11:43:59 +01:00
ld-auto-import
ld-avr
ld-bootstrap
ld-bpf
ld-cdtest
ld-checks
ld-cris
ld-crx
ld-csky
ld-ctf libctf, ld: fix test results for upstream GCC 2021-05-06 09:31:31 +01:00
ld-cygwin
ld-d10v
ld-discard
ld-dynamic
ld-elf RISC-V: Add PT_RISCV_ATTRIBUTES and add it to PHDR. 2021-07-06 11:34:36 +08:00
ld-elfcomm
ld-elfvers
ld-elfvsb
ld-elfweak
ld-fastcall
ld-frv
ld-gc
ld-h8300
ld-i386 x86: Count PLT for GOTOFF relocation against IFUNC symbol 2021-06-19 20:21:04 -07:00
ld-ia64
ld-ifunc
ld-libs
ld-linkonce
ld-m68hc11
ld-m68k
ld-mep
ld-metag
ld-mips-elf
ld-misc
ld-mmix
ld-mn10300
ld-msp430-elf
ld-nds32
ld-nios2
ld-or1k or1k: Support large plt_relocs when generating plt entries 2021-05-06 20:51:25 +09:00
ld-pdp11
ld-pe
ld-pie readelf: report DF_1_PIE as "Position-Independent Executable" 2021-06-15 13:24:57 +09:30
ld-plugin ld: Cache and reuse the IR archive file descriptor 2021-07-05 08:51:35 -07:00
ld-powerpc PowerPC undefweak testcase 2021-05-05 10:35:31 +09:30
ld-pru
ld-riscv-elf RISC-V: Add PT_RISCV_ATTRIBUTES and add it to PHDR. 2021-07-06 11:34:36 +08:00
ld-s12z
ld-s390 Re: section symbols without a name 2021-05-03 12:42:03 +09:30
ld-scripts
ld-selective
ld-sh
ld-shared
ld-size
ld-sparc Fix the creation of archives for Sparc Solaris2 targets by eliminating the support for generic SPARC ELF files. 2021-06-09 11:10:16 +01:00
ld-spu
ld-srec
ld-tic6x
ld-tilegx
ld-tilepro
ld-undefined
ld-unique
ld-v850
ld-vax-elf
ld-visium
ld-vxworks
ld-x86-64 elf: Correct DT_TEXTREL warning in PDE 2021-06-19 16:33:35 -07:00
ld-xc16x
ld-xstormy16
ld-xtensa
ld-z8k
ld-z80
lib Enable linker garbage collection for the PRU target. 2021-05-10 14:00:00 +01:00
ChangeLog-2004
ChangeLog-2005
ChangeLog-2006
ChangeLog-2007
ChangeLog-2008
ChangeLog-2009
ChangeLog-2010
ChangeLog-2011
ChangeLog-2012
ChangeLog-2013
ChangeLog-2014
ChangeLog-2015
ChangeLog-9303