Convert indirect calls to direct when possible.
[external/binutils.git] / gold / ChangeLog
1 2016-06-28  Sriraman Tallam  <tmsriram@google.com>
2
3         * x86_64.cc (Lazy_view): New class.
4         (can_convert_mov_to_lea): Templatize function.  Make the function
5         check for appropriate relocation types and use the view parameter
6         to get section contents.
7         (can_convert_callq_to_direct): New function.
8         (Target_x86_64<size>::Scan::global): Refactor.
9         (Target_x86_64<size>::Relocate::relocate): Refactor. Change any indirect
10         call via GOT that can be converted.
11         * testsuite/Makefile.am (x86_64_indirect_call_to_direct.sh): New test.
12         * testsuite/Makefile.in: Regenerate.
13         * testsuite/x86_64_indirect_call_to_direct1.s: New file.
14         * testsuite/x86_64_indirect_jump_to_direct1.s: New file.
15
16 2016-06-28  Igor Kudrin  <ikudrin@accesssoftek.com>
17
18         * aarch64.cc (Target_aarch64::Scan::local): Move the call to got_section
19         from the top level to the places of its use.
20
21 2016-06-28  Igor Kudrin  <ikudrin@accesssoftek.com>
22
23         PR gold/18098
24         * script-c.h (Sort_wildcard): Add SORT_WILDCARD_BY_INIT_PRIORITY.
25         * script-sections.cc (Input_section_sorter::get_init_priority): New method.
26         (Input_section_sorter::operator()): Handle SORT_WILDCARD_BY_INIT_PRIORITY.
27         (Output_section_element_input::print): Likewise.
28         * script.cc (script_keyword_parsecodes): Add entry SORT_BY_INIT_PRIORITY.
29         * yyscript.y (SORT_BY_INIT_PRIORITY): New token.
30         (wildcard_section): Handle SORT_BY_INIT_PRIORITY.
31
32         * testsuite/Makefile.am (script_test_14): New test.
33         * testsuite/Makefile.in: Regenerate.
34         * testsuite/script_test_14.s: New test source file.
35         * testsuite/script_test_14.sh: New test script.
36         * testsuite/script_test_14.t: New test linker script.
37
38 2016-06-28  James Clarke  <jrtc27@jrtc27.com>
39
40         * sparc.cc (Target_sparc::Scan::local): Don't convert R_SPARC_32
41         to R_SPARC_RELATIVE if class is ELFCLASS64.
42         (Target_sparc::Scan::global): Likewise.
43
44 2016-06-23  Cary Coutant  <ccoutant@gmail.com>
45             Igor Kudrin  <ikudrin@accesssoftek.com>
46
47         PR gold/15370
48         * script-sections.cc
49         (Output_section_element_input::set_section_addresses): Keep bin_count
50         separate from input_pattern_count.
51         * testsuite/script_test_12.t: Add another section .x4.
52         * testsuite/script_test_12i.t: Likewise.
53         * testsuite/script_test_12a.c: Likewise.
54         * testsuite/script_test_12b.c: Likewise.
55
56 2016-06-23  Igor Kudrin  <ikudrin@accesssoftek.com>
57
58         * gold-threads.cc (impl_threads::Lock_impl_threads): Fix typos.
59
60 2016-06-22  H.J. Lu  <hongjiu.lu@intel.com>
61
62         PR ld/20283
63         * NEWS: Mention --enable-relro.
64         * configure.ac: Add --enable-relro.
65         (DEFAULT_LD_Z_RELRO): New.  Set by --enable-relro and default
66         to 1.
67         * config.in: Regenerated.
68         * configure: Likewise.
69         * options.h (General_options::relro): Default to
70         DEFAULT_LD_Z_RELRO.
71
72 2016-06-20  Cary Coutant  <ccoutant@gmail.com>
73
74         * NEWS: Add new features in 1.12.
75         * version.cc (version_string): Bump to 1.12.
76
77 2016-06-20  H.J. Lu  <hongjiu.lu@intel.com>
78
79         PR gold/20245
80         * i386.cc (Target_i386::first_plt_entry_offset): Return 0 if
81         plt_ is NULL.
82         (Target_i386::plt_entry_size): Likewise.
83         (Target_x86_64<size>::first_plt_entry_offset): Likewise.
84         (Target_x86_64<size>::plt_entry_size): Likewise.
85
86 2016-06-20  Vladimir Radosavljevic  <Vladimir.Radosavljevic@imgtec.com>
87
88         * mips.cc (Target_mips::Target_mips): Initialize rld_map_.
89         (Target_mips::rld_map_): New data member.
90         (Target_mips::do_finalize_sections): Add support for
91         DT_MIPS_RLD_MAP and DT_MIPS_RLD_MAP_REL dynamic tags,
92         .rld_map section, and __RLD_MAP symbol.
93         (Target_mips::do_dynamic_tag_custom_value): Add support for
94         DT_MIPS_RLD_MAP_REL dynamic tag.
95         * output.cc (Output_data_dynamic::get_entry_offset): New method
96         definition.
97         * output.h (Output_data_dynamic::get_entry_offset): New method
98         declaration.
99
100 2016-06-20  Vladimir Radosavljevic  <Vladimir.Radosavljevic@imgtec.com>
101
102         * mips.cc (Mips_relocate_functions::relpc16): Add unaligned check.
103
104 2016-06-20  Vladimir Radosavljevic  <Vladimir.Radosavljevic@imgtec.com>
105
106         * mips.cc (relocation_needs_la25_stub): Add support for relocs:
107         R_MIPS_PC21_S2 and R_MIPS_PC26_S2.
108         (hi16_reloc): Add support for R_MIPS_PCHI16 relocation.
109         (is_matching_lo16_reloc): Likewise.
110         (lo16_reloc): Add support for R_MIPS_PCLO16 relocation.
111         (Mips_output_data_plt::plt_entry_r6): New static data member for
112         R6 PLT entry.
113         (Target_mips::is_output_r6): New method.
114         (Target_mips::Mips_mach): Add new enum constants.
115         (Mips_relocate_functions::Status): Likewise.
116         (Mips_relocate_functions::pchi16_relocs): New static data member.
117         (Mips_relocate_functions::relpc21): New method.
118         (Mips_relocate_functions::relpc26): Likewise.
119         (Mips_relocate_functions::relpc18): Likewise.
120         (Mips_relocate_functions::relpc19): Likewise.
121         (Mips_relocate_functions::relpchi16): Likewise.
122         (Mips_relocate_functions::do_relpchi16): Likewise.
123         (Mips_relocate_functions::relpclo16): Likewise.
124         (Mips_output_data_plt::do_write): Add support for Mips r6 plt
125         entry.
126         (Target_mips::mips_32bit_flags): Add E_MIPS_ARCH_32R6 support.
127         (Target_mips::elf_mips_mach): Add E_MIPS_ARCH_32R6 and
128         E_MIPS_ARCH_64R6 support.
129         (Target_mips::update_abiflags_isa): Likewise.
130         (mips_get_size_for_reloc): Add support for relocs: R_MIPS_PCHI16,
131         R_MIPS_PCLO16, R_MIPS_PC21_S2, R_MIPS_PC26_S2, R_MIPS_PC18_S3 and
132         R_MIPS_PC19_S2.
133         (Target_mips::Scan::local): Add support for relocs: R_MIPS_PCHI16
134         and R_MIPS_PCLO16.
135         (Target_mips::Scan::global): Add support for relocs:
136         R_MIPS_PC21_S2 and R_MIPS_PC26_S2.
137         (Target_mips::Relocate::relocate): Call functions for resolving
138         Mips32r6 and Mips64r6 relocations, and print error message for
139         STATUS_PCREL_UNALIGNED.
140         (Target_mips::Scan::get_reference_flags): Add support for relocs:
141         R_MIPS_PCHI16, R_MIPS_PCLO16, R_MIPS_PC21_S2, R_MIPS_PC26_S2,
142         R_MIPS_PC18_S3 and R_MIPS_PC19_S2.
143         (Target_mips::elf_mips_mach_name): Add E_MIPS_ARCH_32R6 and
144         E_MIPS_ARCH_64R6 support.
145
146 2016-06-13  H.J. Lu  <hongjiu.lu@intel.com>
147
148         PR gold/20246
149         * testsuite/script_test_2.t: Add .got.plt after .got.
150
151 2016-06-10  Vladimir Radosavljevic  <Vladimir.Radosavljevic@imgtec.com>
152
153         * mips.cc (struct Mips_abiflags): New struct.
154         (Mips_relobj::Mips_relobj): Initialize attributes_section_data_
155         and abiflags_.
156         (Mips_relobj::~Mips_relobj): Delete object pointed by
157         attributes_section_data_.
158         (Mips_relobj::abiflags): New method.
159         (Mips_relobj::attributes_section_data): Likewise.
160         (Mips_relobj::attributes_section_data_): New data member.
161         (Mips_relobj::abiflags_): Likewise.
162         (class Mips_output_section_abiflags): New class.
163         (Target_mips::Target_mips): Initialize attributes_section_data_,
164         abiflags_ and has_abiflags_section_.
165         (Target_mips::do_should_include_section): Don't emit input
166         .MIPS.abiflags sections to output .MIPS.abiflags.
167         (Target_mips::Mips_mach): Add new enum constants.
168         (Target_mips::mips_isa_ext_mach): New method.
169         (Target_mips::mips_isa_ext): Likewise.
170         (Target_mips::update_abiflags_isa): Likewise.
171         (Target_mips::infer_abiflags): Likewise.
172         (Target_mips::create_abiflags): Likewise.
173         (Target_mips::fp_abi_string): Likewise.
174         (Target_mips::select_fp_abi): Likewise.
175         (Target_mips::merge_obj_attributes): Likewise.
176         (Target_mips::merge_obj_abiflags): Likewise.
177         (Target_mips::level_rev): Likewise.
178         (Target_mips::merge_obj_e_flags): Rename from
179         merge_processor_specific_flags. Remove dyn_obj argument,
180         call update_abiflags_isa when needed, compare NaN encodings and
181         compare FP64 state.
182         (Target_mips::add_machine_extensions): Add two machine extensions
183         and fix one.
184         (Target_mips::attributes_section_data_): New data member.
185         (Target_mips::abiflags_): Likewise.
186         (Target_mips::has_abiflags_section_): Likewise.
187         (Mips_relobj::do_read_symbols): Read .gnu.attributes and
188         .MIPS.abiflags sections if they exists.
189         (Target_mips::elf_mips_mach): Add E_MIPS_MACH_5900 and
190         E_MIPS_MACH_OCTEON3 support.
191         (Target_mips::do_adjust_elf_header): Setup EI_ABIVERSION flag.
192         (Target_mips::do_finalize_sections): Merge .gnu.attributes and
193         .MIPS.abiflags sections from input. Create these sections if
194         needed.
195         (Target_mips::elf_mips_mach_name): Add E_MIPS_MACH_5900 and
196         E_MIPS_MACH_OCTEON3 support, and change strings for
197         E_MIPS_MACH_LS2E, E_MIPS_MACH_LS2F and E_MIPS_MACH_LS3A just
198         to match bfd.
199
200 2016-06-10  Vladimir Radosavljevic  <Vladimir.Radosavljevic@imgtec.com>
201
202         * mips.cc (Mips_relobj::Mips_relobj): Initialize
203         has_reginfo_section_.
204         (Mips_relobj::has_reginfo_section_): New data member.
205         (Mips_relobj::has_reginfo_section): New method.
206         (class Mips_output_section_reginfo): Change base class to
207         Output_section_data, and set masks of the output .reginfo section
208         in constructor.
209         (Mips_output_section_reginfo::as_mips_output_section_reginfo):
210         Remove.
211         (Mips_output_section_reginfo::set_masks): Likewise.
212         (Mips_output_section_reginfo::set_final_data_size): Likewise.
213         (Mips_output_section_reginfo::do_print_to_mapfile): New method.
214         (Target_mips::do_make_output_section): Remove.
215         (Mips_relobj::do_read_symbols): Set has_reginfo_section_ to true
216         if the object contains a .reginfo section.
217         (Target_mips::do_finalize_sections): Create a .reginfo output
218         section if needed.
219
220 2016-06-09  Artemiy Volkov  <artemiyv@acm.org>
221
222         * mips.cc (Mips_output_data_got::do_write): Add missing template
223         args via typedef.
224
225 2016-05-30  Marcin Kościelnicki  <koriakin@0x04.net>
226
227         PR/19960
228         * s390.cc (Target_s390::ss_code_st_r14): Removed.
229         (Target_s390::ss_code_l_r14): Removed.
230         (Target_s390::ss_code_ear): Removed.
231         (Target_s390::ss_code_c): Removed.
232         (Target_s390::ss_match_st_r14): New function.
233         (Target_s390::ss_match_l_r14): New function.
234         (Target_s390::ss_match_mcount): Call ss_match_{l,st}_r14 instead
235         of matching code directly.
236         (Target_s390::ss_match_ear): New function.
237         (Target_s390::ss_match_c): New function.
238         (Target_s390::do_calls_non_split): Call ss_match_{ear,c} instead
239         of matching code directly.
240
241 2016-05-19  Cary Coutant  <ccoutant@gmail.com>
242
243         PR gold/19823
244         * copy-relocs.cc (Copy_relocs::make_copy_reloc): Add object
245         parameter; check for protected symbol.
246         * copy-relocs.h (Copy_relocs::make_copy_reloc): Add object parameter.
247         * mips.cc (Mips_copy_relocs): Adjust call to make_copy_reloc.
248         * symtab.cc (Symbol::init_fields): Initialize is_protected_.
249         (Symbol_table::add_from_dynobj): Mark protected symbols.
250         * symtab.h (Symbol::is_protected): New method.
251         (Symbol::set_is_protected): New method.
252         (Symbol::is_protected_): New data member.
253
254         * testsuite/Makefile.am (copy_test_protected): New test.
255         * testsuite/Makefile.in: Regenerate.
256         * testsuite/copy_test.cc (main): Add legal reference to protected
257         symbol.
258         * testsuite/copy_test_v1.cc (main): Likewise.
259         * testsuite/copy_test_2.cc (ip): Add protected symbol.
260         * testsuite/copy_test_protected.cc: New test source file.
261         * testsuite/copy_test_protected.sh: New test script.
262
263 2016-05-19  Vladimir Radosavljevic  <vladimir.radosavljevic@imgtec.com>
264
265         * mips.cc (Mips_got_entry::Mips_got_entry): Remove object argument
266         for global got symbols, and set addend to 0.
267         (Mips_got_entry::hash): Change hash algorithm.
268         (Mips_got_entry::equals): Refactor.
269         (Mips_got_entry::object): Return input object for local got symbols
270         from union d.
271         (Mips_got_entry::addend): Change return of the relocation addend.
272         (Mips_got_entry::addend_): Move from union d.
273         (Mips_got_entry::object_): Move into union d.
274         (class Mips_symbol_hash): New class.
275         (Mips_got_info::Global_got_entry_set): New type.
276         (Mips_got_info::global_got_symbols): Change return type to
277         Global_got_entry_set.
278         (Mips_got_info::global_got_symbols_): Change type to
279         Global_got_entry_set.
280         (Mips_symbol::hash): New method.
281         (Mips_output_data_la25_stub::symbols_): Change type to std::vector.
282         (Mips_output_data_mips_stubs::Mips_stubs_entry_set): New type.
283         (Mips_output_data_mips_stubs::symbols_): Change type to
284         Mips_stubs_entry_set.
285         (Mips_got_info::record_global_got_symbol): Don't pass object
286         argument when creating global got symbol.
287         (Mips_got_info::record_got_entry): Remove find before inserting
288         got entries.
289         (Mips_got_info::add_reloc_only_entries): Change type of iterator
290         to Global_got_entry_set.
291         (Mips_got_info::count_got_symbols): Likewise.
292         (Mips_output_data_la25_stub::create_la25_stub): Use push_back
293         for adding entries to symbols_.
294         (Mips_output_data_la25_stub::do_write): Change type of iterator
295         to std::vector.
296         (Mips_output_data_mips_stubs::set_lazy_stub_offsets): Change type
297         of iterator to Mips_stubs_entry_set.
298         (Mips_output_data_mips_stubs::set_needs_dynsym_value): Likewise.
299         (Mips_output_data_mips_stubs::do_write): Likewise.
300
301 2016-05-06  Han Shen  <shenhan@google.com>
302
303         PR gold/19987.
304
305         * aarch64-reloc.def: New relocation type.
306         * aarch64.cc (AArch64_relocate_functions::Page): Changed to public.
307         (Target_aarch64::Scan::local): Add R_AARCH64_LD64_GOTPAGE_LO15.
308         (Target_aarch64::Scan::global): Add R_AARCH64_LD64_GOTPAGE_LO15.
309         (Target_aarch64::Relocate::relocate): Implement R_AARCH64_LD64_GOTPAGE_LO15.
310
311 2016-04-28  Nick Clifton  <nickc@redhat.com>
312
313         * po/zh_CN.po: Updated Chinese (simplified) translation.
314
315 2016-04-15  H.J. Lu  <hongjiu.lu@intel.com>
316
317         * Makefile.in: Regenerated with automake 1.11.6.
318         * aclocal.m4: Likewise.
319         * testsuite/Makefile.in: Likewise.
320
321 2016-03-30  Cary Coutant  <ccoutant@gmail.com>
322
323         PR gold/16979
324         * symtab.cc (Symbol_table::define_default_version): Check for case
325         where symbols are both in different shared objects.
326
327 2016-03-27  Cary Coutant  <ccoutant@gmail.com>
328
329         PR gold/16111
330         * i386.cc (Target_i386): Add check for fully-resolved symbol for
331         R_386_GOTOFF.
332
333 2016-03-22  Nick Clifton  <nickc@redhat.com>
334
335         * configure: Regenerate.
336
337 2016-03-21  Cary Coutant  <ccoutant@gmail.com>
338
339         PR gold/19842
340         * errors.cc (Errors::undefined_symbol): Add info message when
341         symbol should have been provided by a plugin.
342         * target-reloc.h (issue_undefined_symbol_error): Check for
343         placeholder symbols defined in discarded sections.
344         * testsuite/Makefile.am (plugin_test_9b): New test case.
345         * testsuite/Makefile.in: Regenerate.
346         * testsuite/plugin_test_9b_elf.cc: New test source file.
347         * testsuite/plugin_test_9b_ir.cc: New test source file.
348
349 2016-03-20  Cary Coutant  <ccoutant@gmail.com>
350
351         PR gold/19002
352         * ehframe.cc (Eh_frame::read_fde): Check for dropped functions.
353         * testsuite/Makefile.am (eh_test_2): New test.
354         * testsuite/Makefile.in: Regenerate.
355         * testsuite/eh_test_2.sh: New test script.
356         * testsuite/eh_test_a.cc (bar): Make it comdat.
357         * testsuite/eh_test_b.cc (bar): Add a duplicate copy.
358
359 2016-03-18  Vladimir Radosavljevic  <vladimir.radosavljevic@imgtec.com>
360
361         * mips.cc (Mips_relobj::is_n64_): Remove.
362         (Target_mips::ei_class_): Likewise.
363         (Mips_relobj::is_newabi): Call methods.
364         (Mips_relobj::is_n64): Change checking for N64 ABI.
365         (Target_mips::is_output_n64): Likewise.
366         (Target_mips::merge_processor_specific_flags): Remove ei_class
367         argument, and remove comparing ei_class.
368         (Target_mips::do_adjust_elf_header): Remove setting EI_CLASS field
369         of the ELF header.
370         (Target_mips::do_finalize_sections): Don't pass ei_class argument
371         to merge_processor_specific_flags.
372         (Target_mips::elf_mips_abi_name): Remove ei_class argument, and
373         change checking for N64 ABI.
374
375 2016-03-17  Vladimir Radosavljevic  <vladimir.radosavljevic@imgtec.com>
376
377         * mips.cc (enum Special_relocation_symbol): New enum type.
378         (is_readonly_section): New function.
379         (eh_reloc): Likewise.
380         (Mips_got_entry::is_section_symbol_): New member.
381         (Mips_got_entry::is_section_symbol): New method.
382         (Mips_got_info::record_local_got_symbol): Add is_section_symbol
383         argument.
384         (Mips_relobj::mips_elf_options_section_name): New method.
385         (Mips_output_data_got::record_local_got_symbol): Add
386         is_section_symbol argument, and pass it to
387         Mips_got_info::record_local_got_symbol.
388         (Mips_output_data_got::got_offset): Add addend argument, and pass
389         it to Relobj::local_got_offset.
390         (struct Mips_output_reloc_writer): New type.
391         (class Mips_output_data_reloc): New class.
392         (Mips_output_data_plt::Reloc_section): Change type to
393         Mips_output_data_reloc.
394         (Target_mips::Reloc_section): Likewise.
395         (Mips_reloc_types::get_r_addend): Remove unsigned from return type.
396         (Mips_classify_reloc::get_r_type2): New method.
397         (Mips_classify_reloc::get_r_type3): Likewise.
398         (Mips_classify_reloc::get_r_ssym): Likewise.
399         (Target_mips::Reloca_section): Remove.
400         (Relocate::should_apply_static_reloc): Rename from
401         should_apply_r_mips_32_reloc.
402         (Target_mips::copy_reloc): Replace Reltype parameter with r_type
403         and r_offset.
404         (Mips_relocate_functions::Valtype): New type.
405         (Mips_relocate_functions::Valtype64): New type.
406         (Mips_relocate_functions::check_overflow): New method.
407         (Mips_relocate_functions::mips_reloc_unshuffle): Move to public
408         interface.
409         (Mips_relocate_functions::mips_reloc_shuffle): Likewise.
410         (Mips_relocate_functions::rel16): Add support for resolving
411         relocations for Mips64.
412         (Mips_relocate_functions::rel32): Likewise.
413         (Mips_relocate_functions::reljalr): Likewise.
414         (Mips_relocate_functions::relpc32): Likewise.
415         (Mips_relocate_functions::rel26): Likewise.
416         (Mips_relocate_functions::relpc16): Likewise.
417         (Mips_relocate_functions::relmicromips_pc7_s1): Likewise.
418         (Mips_relocate_functions::relmicromips_pc10_s1): Likewise.
419         (Mips_relocate_functions::relmicromips_pc16_s1): Likewise.
420         (Mips_relocate_functions::do_relhi16): Likewise.
421         (Mips_relocate_functions::do_relgot16_local): Likewise.
422         (Mips_relocate_functions::rello16): Likewise.
423         (Mips_relocate_functions::relgot): Likewise.
424         (Mips_relocate_functions::relgotpage): Likewise.
425         (Mips_relocate_functions::relgotofst): Likewise.
426         (Mips_relocate_functions::relgot_hi16): Likewise.
427         (Mips_relocate_functions::relgot_lo16): Likewise.
428         (Mips_relocate_functions::relgprel): Likewise.
429         (Mips_relocate_functions::relgprel32): Likewise.
430         (Mips_relocate_functions::tlsrelhi16): Likewise.
431         (Mips_relocate_functions::tlsrello16): Likewise.
432         (Mips_relocate_functions::tlsrel32): Likewise.
433         (Mips_relocate_functions::relsub): Likewise.
434         (Mips_relocate_functions::releh): New method.
435         (Mips_relocate_functions::rel64): Likewise.
436         (Mips_got_info::record_local_got_symbol): Add is_section_symbol and
437         pass it to Mips_got_entry.
438         (Mips_got_info::add_local_entries): Pass addend argument
439         to code functions, and for STT_SECTION symbols call
440         add_symbolless_local_addend.
441         (Mips_got_info::add_tls_entries): Pass addend argument to code
442         functions.
443         (Mips_relobj::do_read_symbols): Read gp value that was used to
444         create object.
445         (Mips_output_data_plt::plt_entry): Remove opcode from l[wd]
446         instruction. Opcode for instruction will be selected later.
447         (Target_mips::gc_process_relocs): Add case for SHT_RELA.
448         (Target_mips::scan_relocatable_relocs): Likewise.
449         (Target_mips::emit_relocs_scan): Likewise.
450         (Target_mips::relocate_relocs): Likewise.
451         (Target_mips::do_finalize_sections): Skip objects for merging
452         processor specific flags in which all input sections will be
453         discarded.
454         (mips_get_size_for_reloc): Add case for R_MIPS_EH.
455         (Target_mips::Scan::get_reference_flags): Likewise.
456         (Target_mips::relocate_special_relocatable): Call rel26 method with
457         calculate_only and calculated_value arguments.
458         (Target_mips::Scan::local): Add case for R_MIPS_EH. Don't create a
459         dynamic relocation against a readonly sections, and pass
460         is_section_symbol to Mips_got_info::record_local_got_symbol.
461         (Target_mips::Scan::global): Add case for R_MIPS_EH. Don't create a
462         dynamic relocation against a readonly sections, and pass r_type
463         and r_offset to Target_mips::copy_reloc.
464         (Target_mips::Relocate::relocate): Add support for resolving
465         relocations for Mips64.
466         (Target_mips::mips_info): Add case for Mips64 default dynamic
467         linker name.
468         (Target_selector_mips): Correct emulation names.
469
470 2016-03-17  Vladimir Radosavljevic  <vladimir.radosavljevic@imgtec.com>
471
472         * mips.cc (class Mips_output_data_la25_stub): Add
473         do_print_to_mapfile function.
474
475 2016-03-17  Vladimir Radosavljevic  <vladimir.radosavljevic@imgtec.com>
476
477         * mips.cc (Mips_classify_reloc::put_r_info): Call 32bit version of
478         elf_r_info.
479
480 2016-03-09  H.J. Lu  <hongjiu.lu@intel.com>
481
482         * testsuite/plugin_layout_with_alignment.cc: Renamed to ..
483         * testsuite/plugin_layout_with_alignment.c: This.
484         * testsuite/Makefile.am (plugin_layout_with_alignment.o): Updated.
485         (plugin_layout_with_alignment): Likewise.
486         * testsuite/Makefile.in: Regenerated.
487
488 2016-03-08  Cary Coutant  <ccoutant@gmail.com>
489
490         PR 19751
491         * testsuite/Makefile.am (retain_symbols_file_test): Remove check
492         for constructor.
493         * testsuite/Makefile.in: Regenerate.
494         * testsuite/dynamic_list.sh: Likewise.
495         * testsuite/retain_symbols_file_test.sh: Likewise.
496
497 2016-03-08  Cary Coutant  <ccoutant@gmail.com>
498
499         PR 19751
500         * arm.cc (Reloc_stub::Key::name): Add unused attribute.
501         * dirsearch.cc (Dir_caches::~Dir_caches): Likewise.
502
503 2016-03-08  Cary Coutant  <ccoutant@gmail.com>
504             Vladimir Radosavljevic  <vladimir.radosavljevic@imgtec.com>
505
506         * output.cc (Output_reloc_writer): New type.
507         (Output_data_reloc_base::do_write): Move implementation to template
508         in output.h and replace with invocation of template.
509         * output.h (Output_file): Move to top of file.
510         (Output_reloc::get_symbol_index): Move to public interface.
511         (Output_reloc::get_address): Likewise.
512         (Output_data_reloc_base::do_write_generic): New function template.
513
514 2016-03-04  Cary Coutant  <ccoutant@gmail.com>
515
516         PR gold/19019
517         PR gold/19763
518         * symtab.cc: Instantiate Sized_symbol::init_constant and
519         Sized_symbol::init_undefined.
520
521 2016-03-03  Cary Coutant  <ccoutant@gmail.com>
522
523         PR gold/19019
524         * layout.h (Layout::add_target_specific_dynamic_tag): New function.
525         * layout.cc (Layout::add_target_specific_dynamic_tag): New function.
526         * mips.cc (Target_mips::make_symbol): Adjust function signature.
527         * sparc.cc (Target_sparc::Target_sparc): Initialize register_syms_.
528         (Target_sparc::do_is_defined_by_abi): Remove test for
529         STT_SPARC_REGISTER.
530         (Target_sparc::Register_symbol): New struct type.
531         (Target_sparc::register_syms_): New data member.
532         (Target_sparc<64, true>::sparc_info): Set has_make_symbol to true.
533         (Target_sparc::make_symbol): New function.
534         (Target_sparc::do_finalize_sections): Add register symbols and new
535         dynamic table entries.
536         * symtab.h (Sized_symbol::init_undefined): Add value parameter.
537         (Symbol_table::add_target_global_symbol): New function.
538         (Symbol_table::target_symbols_): New data member.
539         * symtab.cc (Sized_symbol::init_undefined): Add value parameter.
540         (Symbol_table::Symbol_table): Initialize target_symbols_.
541         (Symbol_table::add_from_object): Pass additional parameters to
542         Target::make_symbol.
543         (Symbol_table::define_special_symbol): Likewise.
544         (Symbol_table::add_undefined_symbol_from_command_line): Pass 0 for
545         undefined symbol value.
546         (Symbol_table::set_dynsym_indexes): Process target-specific symbols.
547         (Symbol_table::sized_finalize): Likewise.
548         (Symbol_table::sized_write_globals): Likewise.
549         * target.h (Sized_target::make_symbol): Add name, st_type, object,
550         st_shndx, and value parameters.
551
552 2016-03-03  Rafael Ávila de Espíndola <rafael.espindola@gmail.com>
553
554         * plugin.cc (do_should_include_member): Ignore LDPK_UNDEF and
555         LDPK_WEAKUNDEF symbols.
556
557 2016-03-03  Than McIntosh  <thanm@google.com>
558
559         * plugin.cc (Plugin::load): Include hooks for get_input_section_size
560         and get_input_section_alignment in transfer vector.
561         (get_input_section_alignment): New function.
562         (get_input_section_size): New function.
563         * testsuite/Makefile.am: Add plugin_layout_with_alignment.sh test.
564         * testsuite/Makefile.in: [Regenerate.]
565         * testsuite/plugin_section_alignment.cc: New test file.
566         * testsuite/plugin_layout_with_alignment.cc: New test file.
567         * testsuite/plugin_layout_with_alignment.sh: New test file.
568
569 2016-03-03  Evgenii Stepanov  <eugenis@google.com>
570
571         * plugin.h (Pluginobj::get_symbol_resolution_info): Add version
572         parameter.
573         * plugin.cc (get_symbols_v3): New function.
574         (Plugin::load): Add LDPT_GET_SYMBOLS_V3.
575         (Pluginobj::get_symbol_resolution_info): Return LDPS_NO_SYMS when using
576         new version.
577
578 2016-02-26  Egor Kochetov  <egor.kochetov@intel.com>
579             Cary Coutant  <ccoutant@gmail.com>
580
581         PR gold/19735
582         * ehframe.h (Cie::fde_encoding): New method.
583         * ehframe.cc (Eh_frame::read_fde): Discard FDEs for zero-length
584         address ranges.
585
586 2016-02-15  H.J. Lu  <hongjiu.lu@intel.com>
587
588         * testsuite/Makefile.am (x86_64_mov_to_lea5.o): Pass
589         -mrelax-relocations=yes to $(TEST_AS).
590         (x86_64_mov_to_lea6.o): Likewise.
591         (x86_64_overflow_pc32.o): Remove duplicated target.
592         * testsuite/Makefile.in: Regenerated.
593
594 2016-02-15  Marcin Kościelnicki  <koriakin@0x04.net>
595
596         * s390.cc (Target_s390::match_view_u): New helper method.
597         (Target_s390::do_is_call_to_non_split): New method.
598         (Target_s390::ss_code_st_r14): New const.
599         (Target_s390::ss_code_l_r14): New const.
600         (Target_s390::ss_code_bras_8): New const.
601         (Target_s390::ss_code_l_basr): New const.
602         (Target_s390::ss_code_a_basr): New const.
603         (Target_s390::ss_code_ear): New const.
604         (Target_s390::ss_code_c): New const.
605         (Target_s390::ss_code_larl): New const.
606         (Target_s390::ss_code_brasl): New const.
607         (Target_s390::ss_code_jg): New const.
608         (Target_s390::ss_code_jgl): New const.
609         (Target_s390::ss_match_mcount): New helper method.
610         (Target_s390::ss_match_l): New helper method.
611         (Target_s390::ss_match_ahi): New helper method.
612         (Target_s390::ss_match_alfi): New helper method.
613         (Target_s390::ss_match_cr): New helper method.
614         (Target_s390::do_calls_non_split): New method.
615         * testsuite/Makefile.am: Added new tests.
616         * testsuite/Makefile.in: Regenerate.
617         * testsuite/split_s390.sh: New test.
618         * testsuite/split_s390_1_a1.s: New test.
619         * testsuite/split_s390_1_a2.s: New test.
620         * testsuite/split_s390_1_n1.s: New test.
621         * testsuite/split_s390_1_n2.s: New test.
622         * testsuite/split_s390_1_z1.s: New test.
623         * testsuite/split_s390_1_z2.s: New test.
624         * testsuite/split_s390_1_z3.s: New test.
625         * testsuite/split_s390_1_z4.s: New test.
626         * testsuite/split_s390_2_ns.s: New test.
627         * testsuite/split_s390_2_s.s: New test.
628         * testsuite/split_s390x_1_a1.s: New test.
629         * testsuite/split_s390x_1_a2.s: New test.
630         * testsuite/split_s390x_1_n1.s: New test.
631         * testsuite/split_s390x_1_n2.s: New test.
632         * testsuite/split_s390x_1_z1.s: New test.
633         * testsuite/split_s390x_1_z2.s: New test.
634         * testsuite/split_s390x_1_z3.s: New test.
635         * testsuite/split_s390x_1_z4.s: New test.
636         * testsuite/split_s390x_2_ns.s: New test.
637         * testsuite/split_s390x_2_s.s: New test.
638
639 2016-02-11 Rahul Chaudhry  <rahulchaudhry@google.com>
640
641         * aarch64.cc (Target_aarch64::scan_erratum_843419_span): Remove
642         info message for every erratum 843419 found and fixed.
643
644 2016-02-07  Cary Coutant  <ccoutant@gmail.com>
645
646         PR gold/18695
647         * x86_64.cc (Target_x86_64::Relocate::relocate): Add additional
648         information to relocation overflow errors.
649
650 2016-02-06  Cary Coutant  <ccoutant@gmail.com>
651
652         PR gold/18695
653         * x86_64.cc (X86_64_relocate_functions::pcrela32_check): Fix x32
654         overflow checking when symbol value + addend < 0.
655
656 2016-02-06  Cary Coutant  <ccoutant@gmail.com>
657
658         PR gold/19577
659         * reloc.h (Limits): New class.
660         (Bits::has_overflow32): Use min/max values from Limits.
661         (Bits::has_unsigned_overflow32): Likewise.
662         (Bits::has_signed_unsigned_overflow32): Likewise.
663         (Bits::has_overflow): Likewise.
664         (Bits::has_unsigned_overflow): Likewise.
665         (Bits::has_signed_unsigned_overflow64): Likewise.
666
667 2016-02-06  Cary Coutant  <ccoutant@gmail.com>
668
669         PR gold/19567
670         * reloc.h (Relocate_functions::Overflow_check): Add comments.
671         * x86_64.cc (X86_64_relocate_functions): New class.
672         (Target_x86_64::Relocate::relocate): Use the new class.
673         * testsuite/Makefile.am (x86_64_overflow_pc32): Add -Tdata option.
674         (x32_overflow_pc32): New test case.
675         * testsuite/Makefile.in: Regenerate.
676         * testsuite/x32_overflow_pc32.sh: New script.
677         * testsuite/x86_64_overflow_pc32.s: Remove .space directive.
678
679 2016-02-06  Cary Coutant  <ccoutant@gmail.com>
680
681         PR gold/19577
682         * reloc.h (Bits::has_unsigned_overflow32): Fix static_cast.
683         (Bits::has_unsigned_overflow): Remove unnecessary static_cast.
684
685 2016-02-06  Cary Coutant  <ccoutant@gmail.com>
686
687         PR gold/19577
688         * reloc.h (Bits::has_unsigned_overflow32): Fix unsigned/signed
689         comparison.
690         (Bits::has_unsigned_overflow): Likewise.
691
692 2016-02-06  Marcin Kościelnicki  <koriakin@0x04.net>
693
694         * i386.cc (Target_i386::is_call_to_non_split): Add view and view_size
695         parameters.
696         * reloc.cc (Sized_relobj_file::split_stack_adjust_reltype): Pass view
697         and view_size to is_call_to_non_split.
698         * target.cc (Target::is_call_to_non_split): Add view and view_size
699         parameters.
700         * target.h (class Target): Likewise.
701
702 2016-02-05  Sriraman Tallam  <tmsriram@google.com>
703
704         * icf.cc (get_rel_addend): New function.
705         (get_section_contents):  Move merge section addend computation to a
706         new function.  Ignore negative values for SHT_REL and SHT_RELA addends.
707         Fix bug to not read past the length of the section.
708
709 2016-02-05  Cary Coutant  <ccoutant@gmail.com>
710             Andrew Senkevich  <andrew.senkevich@intel.com>
711
712         PR gold/18695
713         * x86_64.cc (Target_x86_64::Relocate::relocate): Add overflow
714         checking for R_X86_64_32, R_X86_64_32S, R_X86_64_PC32, and
715         R_X86_64_PLT32.
716         * testsuite/Makefile.am (x86_64_overflow_pc32): New test.
717         * testsuite/x86_64_overflow_pc32.sh: New test script.
718         * testsuite/x86_64_overflow_pc32.s: New source file.
719
720 2016-02-05  Cary Coutant  <ccoutant@gmail.com>
721
722         PR gold/18695
723         * reloc.h (Relocate_functions::Address): New typedef.
724         (Relocate_functions::Addendtype): New typedef.
725         (Relocate_functions::Overflow_check): New enum type.
726         (Relocate_functions::Reloc_status): New enum type.
727         (Relocate_functions::check_overflow): New function template.
728         (Relocate_functions::rel): Add check parameter; check for overflow.
729         (Relocate_functions::rel_unaligned): Likewise.
730         (Relocate_functions::rela): Likewise.
731         (Relocate_functions::pcrel): Likewise.
732         (Relocate_functions::pcrel_unaligned): Likewise.
733         (Relocate_functions::pcrela): Likewise.
734         (Relocate_functions::rel8): Adjust parameter types.
735         (Relocate_functions::rela8): Likewise.
736         (Relocate_functions::pcrel8): Likewise.
737         (Relocate_functions::pcrela8): Likewise.
738         (Relocate_functions::rel16): Likewise.
739         (Relocate_functions::rela168): Likewise.
740         (Relocate_functions::pcrel16): Likewise.
741         (Relocate_functions::pcrela16): Likewise.
742         (Relocate_functions::rel32): Likewise.
743         (Relocate_functions::rel32_unaligned): Likewise.
744         (Relocate_functions::rela32): Likewise.
745         (Relocate_functions::pcrel32): Likewise.
746         (Relocate_functions::pcrel32_unaligned): Likewise.
747         (Relocate_functions::pcrela32): Likewise.
748         (Relocate_functions::rel8_check): New function.
749         (Relocate_functions::rela8_check): New function.
750         (Relocate_functions::pcrel8_check): New function.
751         (Relocate_functions::pcrela8_check): New function.
752         (Relocate_functions::rel16_check): New function.
753         (Relocate_functions::rela168_check): New function.
754         (Relocate_functions::pcrel16_check): New function.
755         (Relocate_functions::pcrela16_check): New function.
756         (Relocate_functions::rel32_check): New function.
757         (Relocate_functions::rel32_unaligned_check): New function.
758         (Relocate_functions::rela32_check): New function.
759         (Relocate_functions::pcrel32_check): New function.
760         (Relocate_functions::pcrel32_unaligned_check): New function.
761         (Relocate_functions::pcrela32_check): New function.
762         (Bits::has_unsigned_overflow32): New function.
763         (Bits::has_unsigned_overflow): New function.
764         * testsuite/Makefile.am (overflow_unittest): New test.
765         * testsuite/Makefile.in: Regenerate.
766         * testsuite/overflow_unittest.cc: New source file.
767
768 2016-02-04  Alan Modra  <amodra@gmail.com>
769
770         * powerpc.cc (relocate): Adjust last patch for big-endian.
771
772 2016-02-02  Alan Modra  <amodra@gmail.com>
773
774         * powerpc.cc (relocate): Further restrict ELFv2 entry optimization.
775
776 2016-01-15 Han Shen  <shenhan@google.com>
777
778         PR gold/19472 - need pc-relative stubs.
779
780         * aarch64.cc (Reloc_stub::stub_type_for_reloc): Return PC-relative
781         stub type for DSOs and pie executables.
782
783 2016-01-12  H.J. Lu  <hongjiu.lu@intel.com>
784
785         * i386.cc (Target_i386::Classify_reloc::get_r_addend): Remove
786         'typename'.
787
788 2016-01-12  Cary Coutant  <ccoutant@gmail.com>
789
790         * arm.cc (Target_arm::Classify_reloc::get_r_addend): New method.
791         * i386.cc (Target_i386::Classify_reloc::get_r_addend): New method.
792         * mips.cc (Target_arm::Mips_classify_reloc::get_r_addend): (Both
793         specializations) New method.
794
795 2016-01-11  Cary Coutant  <ccoutant@gmail.com>
796
797         PR gold/19353
798         * aarch64.cc (Target_aarch64::relocate_tls): Don't insist that
799         we have a TLS segment for GD-to-IE optimization.
800         * i386.cc (Target_i386::tls_gd_to_ie): Remove tls_segment parameter.
801         Adjust all calls.
802         (Target_i386::tls_desc_gd_to_ie): Likewise.
803         (Target_i386::relocate_tls): Don't insist that we have a TLS segment
804         for TLSDESC GD-to-IE optimizations.
805         * x86_64.cc (Target_x86_64::tls_gd_to_ie): Remove tls_segment parameter.
806         Adjust all calls.
807         (Target_x86_64::tls_desc_gd_to_ie): Likewise.
808         (Target_x86_64::relocate_tls): Don't insist that we have a TLS segment
809         for TLSDESC GD-to-IE optimizations.
810
811 2016-01-11  Cary Coutant  <ccoutant@gmail.com>
812
813         Refactor gold to enable support for MIPS-64 relocation format.
814
815         * gc.h (get_embedded_addend_size): Remove sh_type parameter.
816         (gc_process_relocs): Remove sh_type template parameter.
817         Use Classify_reloc to access r_sym, r_type, and r_addend fields.
818         * object.h (Sized_relobj_file::split_stack_adjust): Add target
819         parameter.
820         (Sized_relobj_file::split_stack_adjust_reltype): Likewise.
821         * reloc-types.h (Reloc_types::copy_reloc_addend): (SHT_REL and SHT_RELA
822         specializations) Remove.
823         * reloc.cc (Emit_relocs_strategy): Rename and move to target-reloc.h.
824         (Sized_relobj_file::emit_relocs_scan): Call Target::emit_relocs_scan().
825         (Sized_relobj_file::emit_relocs_scan_reltype): Remove.
826         (Sized_relobj_file::split_stack_adjust): Add target parameter.
827         Adjust all callers.
828         (Sized_relobj_file::split_stack_adjust_reltype): Likewise. Call
829         Target::get_r_sym() to get r_sym field from relocations.
830         (Track_relocs::next_symndx): Call Target::get_r_sym().
831         * target-reloc.h (scan_relocs): Remove sh_type template parameter;
832         add Classify_reloc template parameter.  Use for accessing r_sym and
833         r_type.
834         (relocate_section): Likewise.
835         (Default_classify_reloc): New class (renamed and moved from reloc.cc).
836         (Default_scan_relocatable_relocs): Remove sh_type template parameter.
837         (Default_scan_relocatable_relocs::Reltype): New typedef.
838         (Default_scan_relocatable_relocs::reloc_size): New const.
839         (Default_scan_relocatable_relocs::sh_type): New const.
840         (Default_scan_relocatable_relocs::get_r_sym): New method.
841         (Default_scan_relocatable_relocs::get_r_type): New method.
842         (Default_emit_relocs_strategy): New class.
843         (scan_relocatable_relocs): Replace sh_type template parameter with
844         Scan_relocatable_relocs class.  Use it to access r_sym and r_type
845         fields.
846         (relocate_relocs): Replace sh_type template parameter with
847         Classify_reloc class.  Use it to access r_sym and r_type fields.
848         * target.h (Target::is_call_to_non_split): Replace r_type parameter
849         with pointer to relocation. Adjust all callers.
850         (Target::do_is_call_to_non_split): Likewise.
851         (Target::emit_relocs_scan): New virtual method.
852         (Sized_target::get_r_sym): New virtual method.
853         * target.cc (Target::do_is_call_to_non_split): Replace r_type parameter
854         with pointer to relocation.
855
856         * aarch64.cc (Target_aarch64::emit_relocs_scan): New method.
857         (Target_aarch64::Relocatable_size_for_reloc): Remove.
858         (Target_aarch64::gc_process_relocs): Use Default_classify_reloc.
859         (Target_aarch64::scan_relocs): Likewise.
860         (Target_aarch64::relocate_section): Likewise.
861         (Target_aarch64::Relocatable_size_for_reloc::get_size_for_reloc):
862         Remove.
863         (Target_aarch64::scan_relocatable_relocs): Use Default_classify_reloc.
864         (Target_aarch64::relocate_relocs): Use Default_classify_reloc.
865         * arm.cc (Target_arm::Arm_scan_relocatable_relocs): Remove sh_type
866         template parameter.
867         (Target_arm::emit_relocs_scan): New method.
868         (Target_arm::Relocatable_size_for_reloc): Replace with...
869         (Target_arm::Classify_reloc): ...this.
870         (Target_arm::gc_process_relocs): Use Classify_reloc.
871         (Target_arm::scan_relocs): Likewise.
872         (Target_arm::relocate_section): Likewise.
873         (Target_arm::scan_relocatable_relocs): Likewise.
874         (Target_arm::relocate_relocs): Likewise.
875         * i386.cc (Target_i386::emit_relocs_scan): New method.
876         (Target_i386::Relocatable_size_for_reloc): Replace with...
877         (Target_i386::Classify_reloc): ...this.
878         (Target_i386::gc_process_relocs): Use Classify_reloc.
879         (Target_i386::scan_relocs): Likewise.
880         (Target_i386::relocate_section): Likewise.
881         (Target_i386::scan_relocatable_relocs): Likewise.
882         (Target_i386::relocate_relocs): Likewise.
883         * mips.cc (Mips_scan_relocatable_relocs): Remove sh_type template
884         parameter.
885         (Mips_reloc_types): New class template.
886         (Mips_classify_reloc): New class template.
887         (Target_mips::Reltype): New typedef.
888         (Target_mips::Relatype): New typedef.
889         (Target_mips::emit_relocs_scan): New method.
890         (Target_mips::get_r_sym): New method.
891         (Target_mips::Relocatable_size_for_reloc): Replace with
892         Mips_classify_reloc.
893         (Target_mips::copy_reloc): Use Mips_classify_reloc.
894         (Target_mips::gc_process_relocs): Likewise.
895         (Target_mips::scan_relocs): Likewise.
896         (Target_mips::relocate_section): Likewise.
897         (Target_mips::scan_relocatable_relocs): Likewise.
898         (Target_mips::relocate_relocs): Likewise.
899         (mips_get_size_for_reloc): New function, factored out from
900         Relocatable_size_for_reloc::get_size_for_reloc.
901         (Target_mips::Scan::local): Use Mips_classify_reloc.
902         (Target_mips::Scan::global): Likewise.
903         (Target_mips::Relocate::relocate): Likewise.
904         * powerpc.cc (Target_powerpc::emit_relocs_scan): New method.
905         (Target_powerpc::Relocatable_size_for_reloc): Remove.
906         (Target_powerpc::gc_process_relocs): Use Default_classify_reloc.
907         (Target_powerpc::scan_relocs): Likewise.
908         (Target_powerpc::relocate_section): Likewise.
909         (Powerpc_scan_relocatable_reloc): Convert to class template.
910         (Powerpc_scan_relocatable_reloc::Reltype): New typedef.
911         (Powerpc_scan_relocatable_reloc::reloc_size): New const.
912         (Powerpc_scan_relocatable_reloc::sh_type): New const.
913         (Powerpc_scan_relocatable_reloc::get_r_sym): New method.
914         (Powerpc_scan_relocatable_reloc::get_r_type): New method.
915         (Target_powerpc::scan_relocatable_relocs): Use
916         Powerpc_scan_relocatable_reloc.
917         (Target_powerpc::relocate_relocs): Use Default_classify_reloc.
918         * s390.cc (Target_s390::emit_relocs_scan): New method.
919         (Target_s390::Relocatable_size_for_reloc): Remove.
920         (Target_s390::gc_process_relocs): Use Default_classify_reloc.
921         (Target_s390::scan_relocs): Likewise.
922         (Target_s390::relocate_section): Likewise.
923         (Target_s390::Relocatable_size_for_reloc::get_size_for_reloc):
924         Remove.
925         (Target_s390::scan_relocatable_relocs): Use Default_classify_reloc.
926         (Target_s390::relocate_relocs): Use Default_classify_reloc.
927         * sparc.cc (Target_sparc::emit_relocs_scan): New method.
928         (Target_sparc::Relocatable_size_for_reloc): Remove.
929         (Target_sparc::gc_process_relocs): Use Default_classify_reloc.
930         (Target_sparc::scan_relocs): Likewise.
931         (Target_sparc::relocate_section): Likewise.
932         (Target_sparc::Relocatable_size_for_reloc::get_size_for_reloc):
933         Remove.
934         (Target_sparc::scan_relocatable_relocs): Use Default_classify_reloc.
935         (Target_sparc::relocate_relocs): Use Default_classify_reloc.
936         * tilegx.cc (Target_tilegx::emit_relocs_scan): New method.
937         (Target_tilegx::Relocatable_size_for_reloc): Remove.
938         (Target_tilegx::gc_process_relocs): Use Default_classify_reloc.
939         (Target_tilegx::scan_relocs): Likewise.
940         (Target_tilegx::relocate_section): Likewise.
941         (Target_tilegx::Relocatable_size_for_reloc::get_size_for_reloc):
942         Remove.
943         (Target_tilegx::scan_relocatable_relocs): Use Default_classify_reloc.
944         (Target_tilegx::relocate_relocs): Use Default_classify_reloc.
945         * x86_64.cc (Target_x86_64::emit_relocs_scan): New method.
946         (Target_x86_64::Relocatable_size_for_reloc): Remove.
947         (Target_x86_64::gc_process_relocs): Use Default_classify_reloc.
948         (Target_x86_64::scan_relocs): Likewise.
949         (Target_x86_64::relocate_section): Likewise.
950         (Target_x86_64::Relocatable_size_for_reloc::get_size_for_reloc):
951         Remove.
952         (Target_x86_64::scan_relocatable_relocs): Use Default_classify_reloc.
953         (Target_x86_64::relocate_relocs): Use Default_classify_reloc.
954
955         * testsuite/testfile.cc (Target_test::emit_relocs_scan): New method.
956
957 2016-01-01  Alan Modra  <amodra@gmail.com>
958
959         Update year range in copyright notice of all files.
960
961 For older changes see ChangeLog-0815
962 \f
963 Copyright (C) 2016 Free Software Foundation, Inc.
964
965 Copying and distribution of this file, with or without modification,
966 are permitted in any medium without royalty provided the copyright
967 notice and this notice are preserved.
968
969 Local Variables:
970 mode: change-log
971 left-margin: 8
972 fill-column: 74
973 version-control: never
974 End: