diff options
author | walt <walt> | 2012-08-28 02:43:16 +0000 |
---|---|---|
committer | walt <walt> | 2012-08-28 02:43:16 +0000 |
commit | 55584203a9d02e10166f1cd1db122d09a924f0ab (patch) | |
tree | 6f571386e26cb565c64b438e8e663b554c44bb5b /gas/doc | |
parent | 011df5809ecf0872a74db204dadf2fd643e67c76 (diff) | |
download | binutils-redhat-55584203a9d02e10166f1cd1db122d09a924f0ab.tar.gz |
Add support for constructing pc-relative addresses to the plt, by
adding the necessary assembly operators and relocations.
bfd:
* reloc.c (Add BFD_RELOC_TILEGX_IMM16_X0_HW0_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X1_HW0_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X0_HW1_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X1_HW1_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X0_HW2_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X1_HW2_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X0_HW3_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X1_HW3_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_PLT_PCREL,
BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_PLT_PCREL): new relocations.
* elfxx-tilegx.c (tilegx_elf_howto_table): Handle new relocations.
(tilegx_reloc_map): Ditto.
(reloc_to_create_func): Ditto.
(tilegx_elf_check_relocs): Ditto.
(tilegx_elf_gc_sweep_hook): Ditto.
(tilegx_elf_relocate_section): Ditto.
* libbfd.h: Regenerate.
* bfd-in2.h: Regenerate.
gas:
* tc-tilegx.c (O_hw0_plt): Define operator.
(O_hw1_plt): Ditto.
(O_hw1_last_plt): Ditto.
(O_hw2_last_plt): Ditto.
(md_begin): Handle new operators.
(emit_tilegx_instruction): Ditto.
(md_apply_fix): Ditto.
* doc/c-tilegx.texi: Document new operators.
include/elf:
* tilegx.h (R_TILEGX_IMM16_X0_HW0_PLT_PCREL): New relocation.
(R_TILEGX_IMM16_X1_HW0_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X0_HW1_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X1_HW1_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X0_HW2_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X1_HW2_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X0_HW3_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X1_HW3_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X0_HW0_LAST_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X1_HW0_LAST_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X0_HW1_LAST_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X1_HW1_LAST_PLT_PCREL): Ditto.
(R_TILEGX_IMM16_X0_HW2_LAST_PLT_PCREL ): Ditto.
(R_TILEGX_IMM16_X1_HW2_LAST_PLT_PCREL): Ditto.
Diffstat (limited to 'gas/doc')
-rw-r--r-- | gas/doc/c-tilegx.texi | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/gas/doc/c-tilegx.texi b/gas/doc/c-tilegx.texi index 268cc4f7a5..0d8c038bf1 100644 --- a/gas/doc/c-tilegx.texi +++ b/gas/doc/c-tilegx.texi @@ -242,6 +242,26 @@ called (at latest; depending environment variables). It is only safe to leave the symbol unresolved this way if all references are function calls. +@item hw0_plt + +This modifier is used to load bits 0-15 of the pc-relative address of +a plt entry. + +@item hw1_plt + +This modifier is used to load bits 16-31 of the pc-relative address of +a plt entry. + +@item hw1_last_plt + +This modifier yields the same value as @code{hw1_plt}, but it also +checks that the value does not overflow. + +@item hw2_last_plt + +This modifier is used to load bits 32-47 of the pc-relative address of +a plt entry, and it also checks that the value does not overflow. + @item hw0_tls_gd This modifier is used to load bits 0-15 of the offset of the GOT entry |