diff options
-rw-r--r-- | bfd/ChangeLog | 22 | ||||
-rw-r--r-- | bfd/bfd-in2.h | 4 | ||||
-rw-r--r-- | bfd/elf64-aarch64.c | 36 | ||||
-rw-r--r-- | bfd/libbfd.h | 4 | ||||
-rw-r--r-- | bfd/reloc.c | 4 | ||||
-rw-r--r-- | gas/ChangeLog | 8 | ||||
-rw-r--r-- | gas/config/tc-aarch64.c | 6 | ||||
-rw-r--r-- | gas/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gas/testsuite/gas/aarch64/tls.d | 2 | ||||
-rw-r--r-- | gas/testsuite/gas/aarch64/tls.s | 2 | ||||
-rw-r--r-- | include/elf/ChangeLog | 7 | ||||
-rw-r--r-- | include/elf/aarch64.h | 4 |
12 files changed, 73 insertions, 31 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index a29227e..5169996 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,25 @@ +2013-05-28 Yufeng Zhang <yufeng.zhang@arm.com> + + * reloc.c (BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE): Rename to ... + (BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21): ... this. + (BFD_RELOC_AARCH64_TLSDESC_LD64_PREL19): Rename to ... + (BFD_RELOC_AARCH64_TLSDESC_LD_PREL19): ... this. + * bfd-in2.h: Regenerate. + * libbfd.h: Regenerate. + * elf64-aarch64.c (IS_AARCH64_TLSDESC_RELOC): Update to use + the correct names. + (elf64_aarch64_tlsdesc_howto_table): Likewise. + (elf64_aarch64_reloc_map): Likewise. + (aarch64_resolve_relocation): Likewise. + (bfd_elf_aarch64_put_addend): Likewise. + (aarch64_tls_transition_without_check): Likewise. + (aarch64_reloc_got_type): Likewise. + (elf64_aarch64_final_link_relocate): Likewise. + (elf64_aarch64_tls_relax): Likewise. + (elf64_aarch64_relocate_section): Likewise. + (elf64_aarch64_gc_sweep_hook): Likewise. + (elf64_aarch64_check_relocs): Likewise. + 2013-05-26 Mark Wielaard <mjw@redhat.com> * cache.c (BFD_CACHE_MAX_OPEN): Remove define. diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h index 0050f46..a6299a5 100644 --- a/bfd/bfd-in2.h +++ b/bfd/bfd-in2.h @@ -5350,7 +5350,7 @@ of a signed or unsigned address/value. */ BFD_RELOC_AARCH64_TLSDESC_ADD_LO12_NC, /* AArch64 TLS DESC relocation. */ - BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE, + BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21, /* AArch64 TLS DESC relocation. */ BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21, @@ -5362,7 +5362,7 @@ of a signed or unsigned address/value. */ BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC, /* AArch64 TLS DESC relocation. */ - BFD_RELOC_AARCH64_TLSDESC_LD64_PREL19, + BFD_RELOC_AARCH64_TLSDESC_LD_PREL19, /* AArch64 TLS DESC relocation. */ BFD_RELOC_AARCH64_TLSDESC_LDR, diff --git a/bfd/elf64-aarch64.c b/bfd/elf64-aarch64.c index fe9d5b1..68f03fc 100644 --- a/bfd/elf64-aarch64.c +++ b/bfd/elf64-aarch64.c @@ -40,7 +40,7 @@ For TLS descriptors the assembler will present us with code fragments of the form: - adrp x0, :tlsdesc:foo R_AARCH64_TLSDESC_ADR_PAGE(foo) + adrp x0, :tlsdesc:foo R_AARCH64_TLSDESC_ADR_PAGE21(foo) ldr x1, [x0, #:tlsdesc_lo12:foo] R_AARCH64_TLSDESC_LD64_LO12(foo) add x0, x0, #:tlsdesc_lo12:foo R_AARCH64_TLSDESC_ADD_LO12(foo) .tlsdesccall foo @@ -171,9 +171,9 @@ bfd_elf_aarch64_put_addend (bfd *abfd, || IS_AARCH64_TLSDESC_RELOC ((R_TYPE))) #define IS_AARCH64_TLSDESC_RELOC(R_TYPE) \ - ((R_TYPE) == R_AARCH64_TLSDESC_LD64_PREL19 \ + ((R_TYPE) == R_AARCH64_TLSDESC_LD_PREL19 \ || (R_TYPE) == R_AARCH64_TLSDESC_ADR_PREL21 \ - || (R_TYPE) == R_AARCH64_TLSDESC_ADR_PAGE \ + || (R_TYPE) == R_AARCH64_TLSDESC_ADR_PAGE21 \ || (R_TYPE) == R_AARCH64_TLSDESC_ADD_LO12_NC \ || (R_TYPE) == R_AARCH64_TLSDESC_LD64_LO12_NC \ || (R_TYPE) == R_AARCH64_TLSDESC_OFF_G1 \ @@ -1204,7 +1204,7 @@ static reloc_howto_type elf64_aarch64_tls_howto_table[] = static reloc_howto_type elf64_aarch64_tlsdesc_howto_table[] = { - HOWTO (R_AARCH64_TLSDESC_LD64_PREL19, /* type */ + HOWTO (R_AARCH64_TLSDESC_LD_PREL19, /* type */ 2, /* rightshift */ 2, /* size (0 = byte, 1 = short, 2 = long) */ 21, /* bitsize */ @@ -1212,7 +1212,7 @@ static reloc_howto_type elf64_aarch64_tlsdesc_howto_table[] = 0, /* bitpos */ complain_overflow_dont, /* complain_on_overflow */ bfd_elf_generic_reloc, /* special_function */ - "R_AARCH64_TLSDESC_LD64_PREL19", /* name */ + "R_AARCH64_TLSDESC_LD_PREL19", /* name */ FALSE, /* partial_inplace */ 0x1ffffc, /* src_mask */ 0x1ffffc, /* dst_mask */ @@ -1234,7 +1234,7 @@ static reloc_howto_type elf64_aarch64_tlsdesc_howto_table[] = /* Get to the page for the GOT entry for the symbol (G(S) - P) using an ADRP instruction. */ - HOWTO (R_AARCH64_TLSDESC_ADR_PAGE, /* type */ + HOWTO (R_AARCH64_TLSDESC_ADR_PAGE21, /* type */ 12, /* rightshift */ 2, /* size (0 = byte, 1 = short, 2 = long) */ 21, /* bitsize */ @@ -1242,7 +1242,7 @@ static reloc_howto_type elf64_aarch64_tlsdesc_howto_table[] = 0, /* bitpos */ complain_overflow_dont, /* complain_on_overflow */ bfd_elf_generic_reloc, /* special_function */ - "R_AARCH64_TLSDESC_ADR_PAGE", /* name */ + "R_AARCH64_TLSDESC_ADR_PAGE21", /* name */ FALSE, /* partial_inplace */ 0x1fffff, /* src_mask */ 0x1fffff, /* dst_mask */ @@ -1471,9 +1471,9 @@ static const struct elf64_aarch64_reloc_map elf64_aarch64_reloc_map[] = {BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_HI12, R_AARCH64_TLSLE_ADD_TPREL_HI12}, {BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12_NC, R_AARCH64_TLSLE_ADD_TPREL_LO12_NC}, - {BFD_RELOC_AARCH64_TLSDESC_LD64_PREL19, R_AARCH64_TLSDESC_LD64_PREL19}, + {BFD_RELOC_AARCH64_TLSDESC_LD_PREL19, R_AARCH64_TLSDESC_LD_PREL19}, {BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21, R_AARCH64_TLSDESC_ADR_PREL21}, - {BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE, R_AARCH64_TLSDESC_ADR_PAGE}, + {BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21, R_AARCH64_TLSDESC_ADR_PAGE21}, {BFD_RELOC_AARCH64_TLSDESC_ADD_LO12_NC, R_AARCH64_TLSDESC_ADD_LO12_NC}, {BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC, R_AARCH64_TLSDESC_LD64_LO12_NC}, {BFD_RELOC_AARCH64_TLSDESC_OFF_G1, R_AARCH64_TLSDESC_OFF_G1}, @@ -2132,7 +2132,7 @@ aarch64_resolve_relocation (unsigned int r_type, bfd_vma place, bfd_vma value, break; case R_AARCH64_ADR_GOT_PAGE: - case R_AARCH64_TLSDESC_ADR_PAGE: + case R_AARCH64_TLSDESC_ADR_PAGE21: case R_AARCH64_TLSGD_ADR_PAGE21: case R_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21: value = PG (value + addend) - PG (place); @@ -3361,7 +3361,7 @@ bfd_elf_aarch64_put_addend (bfd *abfd, case R_AARCH64_TLSGD_ADR_PAGE21: case R_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21: - case R_AARCH64_TLSDESC_ADR_PAGE: + case R_AARCH64_TLSDESC_ADR_PAGE21: case R_AARCH64_ADR_GOT_PAGE: case R_AARCH64_ADR_PREL_LO21: case R_AARCH64_ADR_PREL_PG_HI21: @@ -3527,7 +3527,7 @@ aarch64_tls_transition_without_check (unsigned int r_type, switch (r_type) { case R_AARCH64_TLSGD_ADR_PAGE21: - case R_AARCH64_TLSDESC_ADR_PAGE: + case R_AARCH64_TLSDESC_ADR_PAGE21: return is_local ? R_AARCH64_TLSLE_MOVW_TPREL_G1 : R_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21; @@ -3567,7 +3567,7 @@ aarch64_reloc_got_type (unsigned int r_type) return GOT_TLS_GD; case R_AARCH64_TLSDESC_ADD_LO12_NC: - case R_AARCH64_TLSDESC_ADR_PAGE: + case R_AARCH64_TLSDESC_ADR_PAGE21: case R_AARCH64_TLSDESC_CALL: case R_AARCH64_TLSDESC_LD64_LO12_NC: return GOT_TLSDESC_GD; @@ -4025,7 +4025,7 @@ elf64_aarch64_final_link_relocate (reloc_howto_type *howto, *unresolved_reloc_p = FALSE; break; - case R_AARCH64_TLSDESC_ADR_PAGE: + case R_AARCH64_TLSDESC_ADR_PAGE21: case R_AARCH64_TLSDESC_LD64_LO12_NC: case R_AARCH64_TLSDESC_ADD_LO12_NC: case R_AARCH64_TLSDESC_ADD: @@ -4079,7 +4079,7 @@ elf64_aarch64_tls_relax (struct elf64_aarch64_link_hash_table *globals, switch (r_type) { case R_AARCH64_TLSGD_ADR_PAGE21: - case R_AARCH64_TLSDESC_ADR_PAGE: + case R_AARCH64_TLSDESC_ADR_PAGE21: if (is_local) { /* GD->LE relaxation: @@ -4515,7 +4515,7 @@ elf64_aarch64_relocate_section (bfd *output_bfd, case R_AARCH64_TLSLE_MOVW_TPREL_G0_NC: break; - case R_AARCH64_TLSDESC_ADR_PAGE: + case R_AARCH64_TLSDESC_ADR_PAGE21: case R_AARCH64_TLSDESC_LD64_LO12_NC: case R_AARCH64_TLSDESC_ADD_LO12_NC: if (! symbol_tlsdesc_got_offset_mark_p (input_bfd, h, r_symndx)) @@ -4903,7 +4903,7 @@ elf64_aarch64_gc_sweep_hook (bfd *abfd, case R_AARCH64_TLSLE_MOVW_TPREL_G1_NC: case R_AARCH64_TLSLE_MOVW_TPREL_G0: case R_AARCH64_TLSLE_MOVW_TPREL_G0_NC: - case R_AARCH64_TLSDESC_ADR_PAGE: + case R_AARCH64_TLSDESC_ADR_PAGE21: case R_AARCH64_TLSDESC_ADD_LO12_NC: case R_AARCH64_TLSDESC_LD64_LO12_NC: if (h != NULL) @@ -5243,7 +5243,7 @@ elf64_aarch64_check_relocs (bfd *abfd, struct bfd_link_info *info, case R_AARCH64_TLSLE_MOVW_TPREL_G1_NC: case R_AARCH64_TLSLE_MOVW_TPREL_G0: case R_AARCH64_TLSLE_MOVW_TPREL_G0_NC: - case R_AARCH64_TLSDESC_ADR_PAGE: + case R_AARCH64_TLSDESC_ADR_PAGE21: case R_AARCH64_TLSDESC_ADD_LO12_NC: case R_AARCH64_TLSDESC_LD64_LO12_NC: { diff --git a/bfd/libbfd.h b/bfd/libbfd.h index 1c4d36f..c0006bf 100644 --- a/bfd/libbfd.h +++ b/bfd/libbfd.h @@ -2554,11 +2554,11 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@", "BFD_RELOC_AARCH64_TLSDESC", "BFD_RELOC_AARCH64_TLSDESC_ADD", "BFD_RELOC_AARCH64_TLSDESC_ADD_LO12_NC", - "BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE", + "BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21", "BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21", "BFD_RELOC_AARCH64_TLSDESC_CALL", "BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC", - "BFD_RELOC_AARCH64_TLSDESC_LD64_PREL19", + "BFD_RELOC_AARCH64_TLSDESC_LD_PREL19", "BFD_RELOC_AARCH64_TLSDESC_LDR", "BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC", "BFD_RELOC_AARCH64_TLSDESC_OFF_G1", diff --git a/bfd/reloc.c b/bfd/reloc.c index 57df51b..d4d98f7 100644 --- a/bfd/reloc.c +++ b/bfd/reloc.c @@ -6275,7 +6275,7 @@ ENUM ENUMDOC AArch64 TLS DESC relocation. ENUM - BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE + BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21 ENUMDOC AArch64 TLS DESC relocation. ENUM @@ -6291,7 +6291,7 @@ ENUM ENUMDOC AArch64 TLS DESC relocation. ENUM - BFD_RELOC_AARCH64_TLSDESC_LD64_PREL19 + BFD_RELOC_AARCH64_TLSDESC_LD_PREL19 ENUMDOC AArch64 TLS DESC relocation. ENUM diff --git a/gas/ChangeLog b/gas/ChangeLog index 6b2a166..b8fa3a5 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,11 @@ +2013-05-28 Yufeng Zhang <yufeng.zhang@arm.com> + + * config/tc-aarch64.c (reloc_table): Update to use + BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21 instead of + BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE. + (md_apply_fix): Likewise. + (aarch64_force_relocation): Likewise. + 2013-05-28 Kyrylo Tkachov <kyrylo.tkachov@arm.com> * config/tc-arm.c (it_fsm_post_encode): Improve diff --git a/gas/config/tc-aarch64.c b/gas/config/tc-aarch64.c index 6af526d..f462dbd 100644 --- a/gas/config/tc-aarch64.c +++ b/gas/config/tc-aarch64.c @@ -2389,7 +2389,7 @@ static struct reloc_table_entry reloc_table[] = { /* Get to the page containing GOT TLS entry for a symbol */ {"tlsdesc", 0, - BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE, + BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21, 0, 0, 0}, @@ -6500,7 +6500,7 @@ md_apply_fix (fixS * fixP, valueT * valP, segT seg) case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC: case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0: case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC: - case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE: + case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21: case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12_NC: case BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC: S_SET_THREAD_LOCAL (fixP->fx_addsy); @@ -6663,7 +6663,7 @@ aarch64_force_relocation (struct fix *fixp) case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC: case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0: case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC: - case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE: + case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21: case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12_NC: case BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC: case BFD_RELOC_AARCH64_ADR_GOT_PAGE: diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog index bbfe39d..6bd45d5 100644 --- a/gas/testsuite/ChangeLog +++ b/gas/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2013-05-28 Yufeng Zhang <yufeng.zhang@arm.com> + + * gas/aarch64/tls.d: Update. + * gas/aarch64/tls.s: Update. + 2013-05-28 Kyrylo Tkachov <kyrylo.tkachov@arm.com> * gas/arm/armv8-a-bad.l: Update expected warning message. diff --git a/gas/testsuite/gas/aarch64/tls.d b/gas/testsuite/gas/aarch64/tls.d index 2934519..9b79c85 100644 --- a/gas/testsuite/gas/aarch64/tls.d +++ b/gas/testsuite/gas/aarch64/tls.d @@ -6,7 +6,7 @@ Disassembly of section \.text: 0000000000000000 <.*>: 0: 90000000 adrp x0, 0 <var> - 0: R_AARCH64_TLSDESC_ADR_PAGE var + 0: R_AARCH64_TLSDESC_ADR_PAGE21 var 4: f9400001 ldr x1, \[x0\] 4: R_AARCH64_TLSDESC_LD64_LO12_NC var 8: 91000000 add x0, x0, #0x0 diff --git a/gas/testsuite/gas/aarch64/tls.s b/gas/testsuite/gas/aarch64/tls.s index 6bf75b4..1c7025a 100644 --- a/gas/testsuite/gas/aarch64/tls.s +++ b/gas/testsuite/gas/aarch64/tls.s @@ -21,7 +21,7 @@ func: - // R_AARCH64_TLSDESC_ADR_PAGE var + // R_AARCH64_TLSDESC_ADR_PAGE21 var adrp x0, :tlsdesc:var // R_AARCH64_TLSDESC_LD64_LO12 var ldr x1, [x0, #:tlsdesc_lo12:var] diff --git a/include/elf/ChangeLog b/include/elf/ChangeLog index 2263307..e7058f7 100644 --- a/include/elf/ChangeLog +++ b/include/elf/ChangeLog @@ -1,3 +1,10 @@ +2013-05-28 Yufeng Zhang <yufeng.zhang@arm.com> + + * aarch64.h (R_AARCH64_TLSDESC_LD64_PREL19): Rename to ... + (R_AARCH64_TLSDESC_LD_PREL19): ... this. + (R_AARCH64_TLSDESC_ADR_PAGE): Rename to ... + (R_AARCH64_TLSDESC_ADR_PAGE21): ... this. + 2013-05-22 H.J. Lu <hongjiu.lu@intel.com> * common.h (EM_INTEL205): New. diff --git a/include/elf/aarch64.h b/include/elf/aarch64.h index e3af444..a7b86c1 100644 --- a/include/elf/aarch64.h +++ b/include/elf/aarch64.h @@ -178,9 +178,9 @@ RELOC_NUMBER (R_AARCH64_TLSLE_ADD_TPREL_LO12_NC, 551) FAKE_RELOC (R_AARCH64_tls_max, 552) FAKE_RELOC (R_AARCH64_tlsdesc_min, 560) -RELOC_NUMBER (R_AARCH64_TLSDESC_LD64_PREL19, 560) +RELOC_NUMBER (R_AARCH64_TLSDESC_LD_PREL19, 560) RELOC_NUMBER (R_AARCH64_TLSDESC_ADR_PREL21, 561) -RELOC_NUMBER (R_AARCH64_TLSDESC_ADR_PAGE, 562) +RELOC_NUMBER (R_AARCH64_TLSDESC_ADR_PAGE21, 562) RELOC_NUMBER (R_AARCH64_TLSDESC_LD64_LO12_NC, 563) RELOC_NUMBER (R_AARCH64_TLSDESC_ADD_LO12_NC, 564) RELOC_NUMBER (R_AARCH64_TLSDESC_OFF_G1, 565) |