+2018-06-18 Mephi <mephi42@gmail.com>
+
+ PR 23297
+ * mach-o-x86-64.c (x86_64_howto_table): Add entry for
+ BFD_RELOC_MACH_O_X86_64_RELOC_TLV.
+ (bfd_mach_o_x86_64_canonicalize_one_reloc): Handle the new reloc.
+ (bfd_mach_o_x86_64_swap_reloc_out): Likewise.
+ * reloc.c (BFD_RELOC_MACH_O_X86_64_TV): New entry.
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+
2018-06-14 Faraz Shahbazker <Faraz.Shahbazker@mips.com>
* elfxx-mips.c (print_mips_ases): Add GINV extension.
/* Same as BFD_RELOC_32_PCREL but with an implicit -4 addend. */
BFD_RELOC_MACH_O_X86_64_PCREL32_4,
+/* Used when referencing a TLV entry. */
+ BFD_RELOC_MACH_O_X86_64_TLV,
+
/* Addend for PAGE or PAGEOFF. */
BFD_RELOC_MACH_O_ARM64_ADDEND,
"BFD_RELOC_MACH_O_X86_64_PCREL32_1",
"BFD_RELOC_MACH_O_X86_64_PCREL32_2",
"BFD_RELOC_MACH_O_X86_64_PCREL32_4",
+ "BFD_RELOC_MACH_O_X86_64_TLV",
"BFD_RELOC_MACH_O_ARM64_ADDEND",
"BFD_RELOC_MACH_O_ARM64_GOT_LOAD_PAGE21",
"BFD_RELOC_MACH_O_ARM64_GOT_LOAD_PAGEOFF12",
complain_overflow_bitfield,
NULL, "BRANCH8",
FALSE, 0xff, 0xff, TRUE),
+ /* 12 */
+ HOWTO(BFD_RELOC_MACH_O_X86_64_TLV, 0, 2, 32, TRUE, 0,
+ complain_overflow_bitfield,
+ NULL, "TLV",
+ FALSE, 0xffffffff, 0xffffffff, TRUE),
};
static bfd_boolean
return TRUE;
}
break;
+ case BFD_MACH_O_X86_64_RELOC_TLV:
+ if (reloc.r_length == 2 && reloc.r_pcrel && reloc.r_extern)
+ {
+ res->howto = &x86_64_howto_table[12];
+ return TRUE;
+ }
+ break;
default:
return FALSE;
}
rinfo->r_pcrel = 1;
rinfo->r_length = 2;
break;
+ case BFD_RELOC_MACH_O_X86_64_TLV:
+ rinfo->r_type = BFD_MACH_O_X86_64_RELOC_TLV;
+ rinfo->r_pcrel = 1;
+ rinfo->r_length = 2;
+ break;
default:
return FALSE;
}
BFD_RELOC_MACH_O_X86_64_PCREL32_4
ENUMDOC
Same as BFD_RELOC_32_PCREL but with an implicit -4 addend.
+ENUM
+ BFD_RELOC_MACH_O_X86_64_TLV
+ENUMDOC
+ Used when referencing a TLV entry.
ENUM