Implement tp_richcompare for gdb.Block
[binutils-gdb.git] / ld / ChangeLog-2019
blobf29913e9cf924adeb9ffb5f9acb567a780427d14
1 2019-12-26  Alan Modra  <amodra@gmail.com>
3         * ldlang.c (lang_output_section_find_by_flags): Don't use &p->field
4         when p might be NULL.
5         * ldelf.c (output_rel_find, ldelf_place_orphan): Likewise.
6         (insert_os_after, lang_insert_orphan, lookup_name): Likewise.
7         (strip_excluded_output_sections, lang_clear_os_map): Likewise.
8         (lang_check, lang_for_each_input_file): Likewise.
9         (lang_reset_memory_regions, find_replacements_insert_point): Likewise.
10         (find_rescan_insertion, lang_propagate_lma_regions): Likewise.
11         (lang_record_phdrs): Likewise.
12         * emultempl/alphaelf.em (alpha_after_open): Likewise.
13         * emultempl/mmo.em (mmo_place_orphan): Likewise.
14         * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
15         * emultempl/pep.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
16         * emultempl/ppc32elf.em (ppc_after_check_relocs): Likewise.
17         * emultempl/spuelf.em (spu_before_allocation): Likewise.
18         (embedded_spu_file): Likewise.
20 2019-12-19  Alan Modra  <amodra@gmail.com>
22         * testsuite/lib/ld-lib.exp (uses_genelf): Remove moxie.
24 2019-12-18  Anthony Green  <green@moxielogic.com>
26         * emulparams/elf32moxie.sh (TEMPLATE_NAME): Switch to elf template
27         to enable --build-id.
28         * configure.tgt: Don't define targ_extra_ofiles for moxie-*-*.
30 2019-12-18  Alan Modra  <amodra@gmail.com>
32         * pe-dll.c (pe_get32, pe_as32): Avoid signed overflow.
34 2019-12-17  Alan Modra  <amodra@gmail.com>
36         * testsuite/ld-avr/lds-mega.d: Adjust symbols to suit objdump change.
37         * testsuite/ld-avr/lds-tiny.d: Likewise.
38         * testsuite/ld-x86-64/load2.d: Likewise.
39         * testsuite/ld-mips-elf/compact-eh1.s: Give function symbols
40         function type.
41         * testsuite/ld-mips-elf/compact-eh1a.s: Likewise.
42         * testsuite/ld-mips-elf/compact-eh1b.s: Likewise.
43         * testsuite/ld-mips-elf/compact-eh2.s: Likewise.
44         * testsuite/ld-mips-elf/compact-eh3.s: Likewise.
45         * testsuite/ld-mips-elf/compact-eh3a.s: Likewise.
46         * testsuite/ld-mips-elf/eh-frame5.s: Likewise.
47         * testsuite/ld-mips-elf/ehdr_start-new.s: Likewise.
48         * testsuite/ld-mips-elf/ehdr_start-o32.s: Likewise.
49         * testsuite/ld-mips-elf/emit-relocs-1a.s: Likewise.
50         * testsuite/ld-mips-elf/jaloverflow-2.s: Likewise.
51         * testsuite/ld-mips-elf/jaloverflow.s: Likewise.
52         * testsuite/ld-mips-elf/mips16-call-global-1.s: Likewise.
53         * testsuite/ld-mips-elf/mips16-intermix-1.s: Likewise.
54         * testsuite/ld-mips-elf/mips16-pic-1b.s: Likewise.
55         * testsuite/ld-mips-elf/mips16-pic-4c.s: Likewise.
56         * testsuite/ld-mips-elf/no-shared-1-n64.s: Likewise.
57         * testsuite/ld-mips-elf/no-shared-1-o32.s: Likewise.
58         * testsuite/ld-mips-elf/pic-and-nonpic-1b-micromips.s: Likewise.
59         * testsuite/ld-mips-elf/pic-and-nonpic-1b.s: Likewise.
60         * testsuite/ld-mips-elf/pic-and-nonpic-2a.s: Likewise.
61         * testsuite/ld-mips-elf/pic-and-nonpic-3b.s: Likewise.
62         * testsuite/ld-mips-elf/pic-and-nonpic-4b.s: Likewise.
63         * testsuite/ld-mips-elf/pic-and-nonpic-5a.s: Likewise.
64         * testsuite/ld-mips-elf/pic-and-nonpic-6-n32c.s: Likewise.
65         * testsuite/ld-mips-elf/pic-and-nonpic-6-n64c.s: Likewise.
66         * testsuite/ld-mips-elf/pic-and-nonpic-6-o32c.s: Likewise.
67         * testsuite/ld-mips-elf/pie.s: Likewise.
68         * testsuite/ld-mips-elf/relax-jalr.s: Likewise.
69         * testsuite/ld-mips-elf/reloc-1a.s: Likewise.
70         * testsuite/ld-mips-elf/reloc-2a.s: Likewise.
71         * testsuite/ld-mips-elf/reloc-4.s: Likewise.
72         * testsuite/ld-mips-elf/reloc-5.s: Likewise.
73         * testsuite/ld-mips-elf/reloc-6b.s: Likewise.
74         * testsuite/ld-mips-elf/textrel-1.s: Likewise.
75         * testsuite/ld-mips-elf/undefweak-overflow.s: Likewise.
76         * testsuite/ld-mips-elf/undefweak-overflow.d: Adjust.
78 2019-12-17  Alan Modra  <amodra@gmail.com>
80         * testsuite/ld-elf/pr21233-l.sd: Accept OBJECT for type and
81         PRC for section of symbols.
82         * testsuite/ld-elf/pr23591.d: Likewise.
83         * testsuite/ld-elf/provide-hidden-s.nd: Likewise.
84         * testsuite/ld-mips-elf/start.s: Make symbols function type.
85         * testsuite/ld-mips-elf/hash2.d: Adjust.  Don't xfail irix.
87 2019-12-17  Alan Modra  <amodra@gmail.com>
89         * emulparams/tic80coff.sh: Delete file.
90         * scripttempl/tic80coff.sc: Delete file.
91         * configure.tgt: Remove tic80 support.
92         * Makefile.am: Likewise.
93         * Makefile.in: Regenerate.
94         * po/BLD-POTFILES.in: Regenerate.
96 2019-12-12  H.J. Lu  <hongjiu.lu@intel.com>
98         * testsuite/ld-i386/align-branch-1.d: New file.
99         * testsuite/ld-i386/align-branch-1.s: Likewise.
100         * testsuite/ld-x86-64/align-branch-1.d: Likewise.
101         * testsuite/ld-x86-64/align-branch-1.3: Likewise.
102         * testsuite/ld-i386/i386.exp: Run the new test.
103         * testsuite/ld-x86-64/x86-64.exp: Likewise.
105 2019-12-08  Alan Modra  <amodra@gmail.com>
107         * testsuite/ld-elf/eh4.d: Match optional padding DW_CFA_nop in FDEs.
108         * testsuite/ld-elf/eh5.d: Likewise, and extra CIEs emitted on
109         embedded targets.
111 2019-12-06  Alan Modra  <amodra@gmail.com>
113         * testsuite/ld-mips-elf/eh-frame1-n32.d: Pass --eh-frame-hdr to ld.
114         * testsuite/ld-mips-elf/eh-frame1-n64.d: Likewise.
115         * testsuite/ld-mips-elf/eh-frame2-n32.d: Likewise.
116         * testsuite/ld-mips-elf/eh-frame2-n64.d: Likewise.
118 2019-12-05  Alan Modra  <amodra@gmail.com>
120         PR 25244
121         * ldlang.c (lang_print_memory_usage): Correct last patch.
123 2019-12-05  Alan Modra  <amodra@gmail.com>
125         PR 25243
126         * emulparams/armelf.sh (OTHER_READONLY_SECTIONS): Move definition
127         of __exidx_start and __exidx_end into ARM.exidx.
128         * emulparams/armelf_linux_eabi.sh (OTHER_READONLY_SECTIONS): Likewise.
129         * emulparams/armsymbian.sh (OTHER_READONLY_SECTIONS): Similarly.
130         * emulparams/elf32_tic6x_le.sh (OTHER_READONLY_SECTIONS): Similarly.
131         * emulparams/armelf_fuchsia.sh: Source armelf_linux_eabi.sh,
132         just redefining TEXT_START_ADDR.
133         * emulparams/armelf_linux_fdpiceabi.sh: Source armelf_linux_eabi.sh,
134         adding to OTHER_READONLY_SECTIONS.
136 2019-12-05  Alan Modra  <amodra@gmail.com>
138         PR 25244
139         * ldlang.c (lang_print_memory_usage): Don't print percent used
140         when length is zero.
142 2019-11-27  Andrew Burgess  <andrew.burgess@embecosm.com>
144         * testsuite/ld-elf/eh5.d: Accept version 3 DWARF CIE.
146 2019-11-26  Martin Liska  <mliska@suse.cz>
148         * scripttempl/arclinux.sc: Add .text.sorted.* which is sorted
149         by default.
150         * scripttempl/elf.sc: Likewise.
151         * scripttempl/elf64bpf.sc: Likewise.
152         * scripttempl/nds32elf.sc: Likewise.
153         * testsuite/ld-arm/arm-no-rel-plt.ld: Expect .text.sorted.*
154         in the default linker script.
155         * testsuite/ld-arm/fdpic-main.ld: Likewise.
156         * testsuite/ld-arm/fdpic-shared.ld: Likewise.
158 2019-11-25  Alan Modra  <amodra@gmail.com>
160         * ldexp.c (fold_name): Pass section to bfd_octets_per_byte.
161         * ldlang.c (init_opb): Don't call bfd_arch_mach_octets_per_byte
162         unnecessarily.
164 2019-11-25  Christian Eggers  <ceggers@gmx.de>
166         * ldexp.c (fold_name): Provide section parameter to
167         bfd_octets_per_byte.
168         * ldlang (init_opb): New argument s. Set opb_shift to 0 if
169         SEC_ELF_OCTETS for the current section is set.
170         (print_input_section): Pass current section to init_opb.
171         (print_data_statement,print_reloc_statement,
172         print_padding_statement): Likewise.
173         (lang_check_section_addresses): Call init_opb for each
174         section.
175         (lang_size_sections_1,lang_size_sections_1,
176         lang_do_assignments_1): Likewise.
177         (lang_process): Pass NULL to init_opb.
179 2019-11-22  Nick Clifton  <nickc@redhat.com>
181         * ld.texi (Output Section Discarding): Add note indicating that
182         /DISCARD/ed sections ignore ELF section grouping.
184 2019-11-22  Nick Clifton  <nickc@redhat.com>
186         * ldlang.h (LANG_FOR_EACH_INPUT_STATEMENT): Use cast instead of
187         extra check.
189 2019-11-21  Nick Clifton  <nickc@redhat.com>
191         * ldlang.h (LANG_FOR_EACH_INPUT_STATEMENT): Check for an empty
192         file chain before examining the first input statement.
194 2019-11-21  Alan Modra  <amodra@gmail.com>
196         PR 46
197         * scripttempl/pe.sc: Comment on ld -Ur fail.  Wrap .gcc_exc comment.
198         * scripttempl/pep.sc: Likewise.
199         * scripttempl/i386beos.sc: Wrap .gcc_exc comment.
200         * scripttempl/mcorepe.sc: Likewise.
201         * testsuite/ld-cdtest/cdtest.exp (test2): xfail for pe.
203 2019-11-12  Jim Wilson  <jimw@sifive.com>
205         PR 25181
206         * testsuite/ld-riscv-elf/call-relax-0.s: New file.
207         * testsuite/ld-riscv-elf/call-relax-1.s: New file.
208         * testsuite/ld-riscv-elf/call-relax-2.s: New file.
209         * testsuite/ld-riscv-elf/call-relax-3.s: New file.
210         * testsuite/ld-riscv-elf/call-relax.d: New test.
211         * testsuite/ld-riscv-elf/ld-riscv-elf.exp: Run call-relax test.
213 2019-11-08  Alan Modra  <amodra@gmail.com>
215         * emulparams/aarch64elf.sh: Revert 2019-11-05 change.
216         * emulparams/aarch64elf32.sh: Likewise.
217         * emulparams/arcelf.sh: Likewise.
218         * emulparams/armelf.sh: Likewise.
219         * emulparams/armelf_fbsd.sh: Likewise.
220         * emulparams/armelf_nbsd.sh: Likewise.
221         * emulparams/armelf_vxworks.sh: Likewise.
222         * emulparams/armsymbian.sh: Likewise.
223         * emulparams/elf32bfin.sh: Likewise.
224         * emulparams/elf32microblaze.sh: Likewise.
225         * emulparams/score3_elf.sh: Likewise.
226         * emulparams/shelf.sh: Likewise.
227         * emulparams/shelf_nbsd.sh: Likewise.
228         * emulparams/shelf_uclinux.sh: Likewise.
230 2019-11-07  Alan Modra  <amodra@gmail.com>
232         * emulparams/elf32cr16c.sh: Delete.
233         * scripttempl/elf32cr16c.sc: Delete.
234         * Makefile.am,
235         * configure.tgt: Remove cr16c support.
236         * NEWS: Mention removal of cr16c.
237         * Makefile.in,
238         * po/BLD-POTFILES.in: Regenerate.
240 2019-11-07  Alan Modra  <amodra@gmail.com>
242         * configure.tgt: Order targets by cpu.
244 2019-11-07  Alan Modra  <amodra@gmail.com>
246         * testsuite/ld-aarch64/aarch64-elf.exp: Run tests requiring pie
247         or shared library support only when check_shared_lib_support.
248         * testsuite/ld-aarch64/bti-pac-plt-1.d: Likewise.
249         * testsuite/ld-aarch64/bti-pac-plt-2.d: Likewise.
250         * testsuite/ld-aarch64/bti-plt-1.d: Likewise.
251         * testsuite/ld-aarch64/bti-plt-2.d: Likewise.
252         * testsuite/ld-aarch64/bti-plt-3.d: Likewise.
253         * testsuite/ld-aarch64/bti-plt-4.d: Likewise.
254         * testsuite/ld-aarch64/bti-plt-6.d: Likewise.
255         * testsuite/ld-aarch64/bti-plt-7.d: Likewise.
256         * testsuite/ld-aarch64/bti-warn.d: Likewise.
257         * testsuite/ld-aarch64/dt_textrel.d: Likewise.
258         * testsuite/ld-aarch64/emit-relocs-258-dyn-bad.d: Likewise.
259         * testsuite/ld-aarch64/emit-relocs-259-dyn-bad.d: Likewise.
260         * testsuite/ld-aarch64/emit-relocs-264-bad.d: Likewise.
261         * testsuite/ld-aarch64/emit-relocs-266-bad.d: Likewise.
262         * testsuite/ld-aarch64/emit-relocs-268-bad.d: Likewise.
263         * testsuite/ld-aarch64/emit-relocs-269-bad.d: Likewise.
264         * testsuite/ld-aarch64/emit-relocs-515-be.d: Likewise.
265         * testsuite/ld-aarch64/emit-relocs-515.d: Likewise.
266         * testsuite/ld-aarch64/emit-relocs-516-be.d: Likewise.
267         * testsuite/ld-aarch64/emit-relocs-516.d: Likewise.
268         * testsuite/ld-aarch64/farcall-b-plt.d: Likewise.
269         * testsuite/ld-aarch64/farcall-bl-plt.d: Likewise.
270         * testsuite/ld-aarch64/gc-plt-relocs.d: Likewise.
271         * testsuite/ld-aarch64/gc-relocs-257-dyn.d: Likewise.
272         * testsuite/ld-aarch64/ifunc-1-local.d: Likewise.
273         * testsuite/ld-aarch64/ifunc-1.d: Likewise.
274         * testsuite/ld-aarch64/ifunc-12.d: Likewise.
275         * testsuite/ld-aarch64/ifunc-13.d: Likewise.
276         * testsuite/ld-aarch64/ifunc-14a.d: Likewise.
277         * testsuite/ld-aarch64/ifunc-14b.d: Likewise.
278         * testsuite/ld-aarch64/ifunc-14c.d: Likewise.
279         * testsuite/ld-aarch64/ifunc-14d.d: Likewise.
280         * testsuite/ld-aarch64/ifunc-14e.d: Likewise.
281         * testsuite/ld-aarch64/ifunc-14f.d: Likewise.
282         * testsuite/ld-aarch64/ifunc-15.d: Likewise.
283         * testsuite/ld-aarch64/ifunc-16.d: Likewise.
284         * testsuite/ld-aarch64/ifunc-18a.d: Likewise.
285         * testsuite/ld-aarch64/ifunc-18b.d: Likewise.
286         * testsuite/ld-aarch64/ifunc-19a.d: Likewise.
287         * testsuite/ld-aarch64/ifunc-19b.d: Likewise.
288         * testsuite/ld-aarch64/ifunc-2-local.d: Likewise.
289         * testsuite/ld-aarch64/ifunc-2.d: Likewise.
290         * testsuite/ld-aarch64/ifunc-20.d: Likewise.
291         * testsuite/ld-aarch64/ifunc-21.d: Likewise.
292         * testsuite/ld-aarch64/ifunc-3a.d: Likewise.
293         * testsuite/ld-aarch64/ifunc-3b.d: Likewise.
294         * testsuite/ld-aarch64/ifunc-5b-local.d: Likewise.
295         * testsuite/ld-aarch64/ifunc-5b.d: Likewise.
296         * testsuite/ld-aarch64/ifunc-6b.d: Likewise.
297         * testsuite/ld-aarch64/ifunc-7b.d: Likewise.
298         * testsuite/ld-aarch64/ifunc-7c.d: Likewise.
299         * testsuite/ld-aarch64/pac-plt-1.d: Likewise.
300         * testsuite/ld-aarch64/pac-plt-2.d: Likewise.
301         * testsuite/ld-aarch64/pcrel_pic_defined.d: Likewise.
302         * testsuite/ld-aarch64/pcrel_pic_undefined.d: Likewise.
303         * testsuite/ld-aarch64/pie-bind-locally.d: Likewise.
304         * testsuite/ld-aarch64/plt_mapping_symbol.d: Likewise.
305         * testsuite/ld-aarch64/pr20402.d: Likewise.
306         * testsuite/ld-aarch64/pr22764.d: Likewise.
307         * testsuite/ld-aarch64/property-bti-pac1.d: Likewise.
308         * testsuite/ld-aarch64/protected-data.d: Likewise.
309         * testsuite/ld-aarch64/rela-abs-relative-be.d: Likewise.
310         * testsuite/ld-aarch64/rela-abs-relative-opt.d: Likewise.
311         * testsuite/ld-aarch64/rela-abs-relative.d: Likewise.
312         * testsuite/ld-aarch64/relasz.d: Likewise.
313         * testsuite/ld-aarch64/relocs-1027-symbolic-func.d: Likewise.
314         * testsuite/ld-aarch64/tls-desc-ie-ilp32.d: Likewise.
315         * testsuite/ld-aarch64/tls-desc-ie.d: Likewise.
316         * testsuite/ld-aarch64/tls-large-desc-be.d: Likewise.
317         * testsuite/ld-aarch64/tls-large-desc.d: Likewise.
318         * testsuite/ld-aarch64/tls-large-ie-be.d: Likewise.
319         * testsuite/ld-aarch64/tls-large-ie.d: Likewise.
320         * testsuite/ld-aarch64/tls-relax-gdesc-le-now.d: Likewise.
321         * testsuite/ld-aarch64/tls-small-ld.d: Likewise.
322         * testsuite/ld-aarch64/tls-tiny-desc.d: Likewise.
323         * testsuite/ld-aarch64/tls-tiny-gd.d: Likewise.
324         * testsuite/ld-aarch64/tls-tiny-ie.d: Likewise.
325         * testsuite/ld-aarch64/tls-tiny-ld.d: Likewise.
326         * testsuite/ld-aarch64/tlsle-symbol-offset.d: Likewise.
327         * testsuite/ld-aarch64/tlsle.d: Likewise.
328         * testsuite/ld-aarch64/variant_pcs-now.d: Likewise.
329         * testsuite/ld-aarch64/variant_pcs-shared.d: Likewise.
330         * testsuite/ld-arm/arm-elf.exp: Likewise.  Remove --hash-style=sysv
331         from static tests.  Consolidate armelftests_common_* vars into one.
332         * testsuite/ld-arm/gc-hidden-1.d: Require check_shared_lib_support.
333         * testsuite/ld-arm/movw-shared-1.d: Likewise.
334         * testsuite/ld-arm/movw-shared-2.d: Likewise.
335         * testsuite/ld-arm/movw-shared-3.d: Likewise.
336         * testsuite/ld-arm/movw-shared-4.d: Likewise.
337         * testsuite/ld-arm/pie-bind-locally.d: Likewise.
338         * testsuite/ld-arm/protected-data.d: Likewise.
339         * testsuite/ld-arm/rel32-reject-pie.d: Likewise.
340         * testsuite/ld-arm/rel32-reject.d: Likewise.
341         * testsuite/ld-arm/thumb2-bl-undefweak.d: Likewise.
342         * testsuite/ld-arm/thumb2-bl-undefweak1.d: Likewise.
344 2019-11-06  Christian Eggers  <ceggers@gmx.de>
346         * ldlang.c (print_input_section): Shift printed size by opb_shift.
348 2019-11-05  Alan Modra  <amodra@gmail.com>
350         * emulparams/aarch64elf.sh (GENERATE_SHLIB_SCRIPT),
351         (GENERATE_PIE_SCRIPT): Don't set.
352         * emulparams/aarch64elf32.sh (GENERATE_SHLIB_SCRIPT),
353         (GENERATE_PIE_SCRIPT): Don't set.
354         * emulparams/arcelf.sh (GENERATE_SHLIB_SCRIPT): Don't set.
355         * emulparams/armelf.sh (GENERATE_SHLIB_SCRIPT),
356         (GENERATE_PIE_SCRIPT): Don't set.
357         * emulparams/armelf_fbsd.sh (GENERATE_SHLIB_SCRIPT): Set.
358         * emulparams/armelf_nbsd.sh (GENERATE_SHLIB_SCRIPT),
359         (GENERATE_PIE_SCRIPT): Set.
360         * emulparams/armelf_vxworks.sh (GENERATE_SHLIB_SCRIPT): Set.
361         * emulparams/armsymbian.sh (GENERATE_SHLIB_SCRIPT): Set.
362         * emulparams/elf32bfin.sh (GENERATE_SHLIB_SCRIPT): Don't set.
363         * emulparams/elf32microblaze.sh (GENERATE_SHLIB_SCRIPT): Don't set.
364         * emulparams/score3_elf.sh (GENERATE_SHLIB_SCRIPT): Don't set.
365         * emulparams/shelf.sh (GENERATE_SHLIB_SCRIPT): Don't set.
366         * emulparams/shelf_nbsd.sh (GENERATE_SHLIB_SCRIPT),
367         (GENERATE_PIE_SCRIPT): Set.
368         * emulparams/shelf_uclinux.sh (GENERATE_SHLIB_SCRIPT): Set.
370 2019-11-05  Alan Modra  <amodra@gmail.com>
372         * emulparams/elf32bfinfd.sh: Unset EMBEDDED rather assigning as empty.
373         * emulparams/elf32frvfd.sh: Likewise.
374         * emulparams/elf32lm32fd.sh: Likewise.
375         * emulparams/i386lynx.sh: Likewise.
377 2019-10-22  Alan Modra  <amodra@gmail.com>
379         PR 22269
380         * testsuite/ld-elf/pr22269-1.rd: Look for GOT section NONE and
381         RELATIVE relocs.
382         * testsuite/ld-elf/shared.exp (pr22269-1): Give test a better
383         name.  Use -z nocombreloc.
385 2019-10-19  Alan Modra  <amodra@gmail.com>
387         PR ld/25110
388         * testsuite/ld-gc/gc.exp: Adjust LDFLAGS for pr19161 dump test on
389         hppa*-*-linux*.
391 2019-10-17  Nelson Chu  <nelson.chu@sifive.com>
393         * testsuite/ld-riscv-elf/lib-nopic-01b.d: Update the error message.
395         * testsuite/ld-riscv-elf/lib-nopic-01a.s: Create the shared library
396         lib-nopic-01a.so, it will be linked with lib-nopic-01b.s.
397         * testsuite/ld-riscv-elf/lib-nopic-01b.s: Add new test for the
398         unresolved relocation.  Link the non-pic code into a shared library
399         may cause the error.
400         * testsuite/ld-riscv-elf/lib-nopic-01b.d: Likewise.
401         * testsuite/ld-riscv-elf/ld-riscv-elf.exp: Run the new test only when
402         the shared library is supported.
404 2019-10-16  Alan Modra  <amodra@gmail.com>
406         PR 13616
407         * emulparams/elf64lppc.sh (NOP): Don't define.
408         * emulparams/elf64ppc.sh (NOP): Don't define.
409         * ldwrite.c (build_link_order): Use link_info.big_endian.  Move
410         code determining endian to use for data_statement to..
411         * ldemul.c (after_open_default): ..here.  Set link_info.big_endian.
413 2019-10-16  Alan Modra  <amodra@gmail.com>
415         * genscripts.sh: Correct comments.  Remove outdated comment block
416         saying "Generate 5 or 6 script files..".  Remove description of
417         ld options from comment emitted to script files, and order options
418         as per comment block in genscripts.sh saying which scripts are
419         generated.
421 2019-10-14  Alan Modra  <amodra@gmail.com>
423         * ldctor.h (struct set_element): Make next field a union, adding
424         idx field.
425         * ldctor.c (ctor_cmp): Dereference pointer and lose unnecessary
426         const.  Replace final sort on pointer value with final sort on idx.
427         (ldctor_add_set_entry): Adjust next field access.
428         (ldctor_build_sets): Likewise.  Set u.idx field for sort.
430 2019-10-14  Alan Modra  <amodra@gmail.com>
432         * pe-dll.c (reloc_data_type): Add idx field.
433         (reloc_sort): Perform final sort by idx.
434         (generate_reloc): Set idx.
436 2019-10-13  Nick Clifton  <nickc@redhat.com>
438         * NEWS: Delete superflous "Changes in 2.33" comment.
440 2019-10-09  Alan Modra  <amodra@gmail.com>
442         PR 25081
443         * ldlang.c (lang_size_sections_1): Set lma from section vma
444         rather than dot.
446 2019-10-08  Alan Modra  <amodra@gmail.com>
448         * testsuite/ld-powerpc/localgot.s,
449         * testsuite/ld-powerpc/localgot.d: New test.
450         * testsuite/ld-powerpc/powerpc.exp: Run it.
452 2019-10-07  Jozef Lawrynowicz  <jozef.l@mittosystems.com>
454         * testsuite/ld-msp430-elf/attr-gnu-main.s: New test.
455         * testsuite/ld-msp430-elf/attr-gnu-obj.s: New test.
456         * testsuite/ld-msp430-elf/attr-gnu-region-lower-upper.d: New test.
457         * testsuite/ld-msp430-elf/attr-gnu-region-lower.d: New test.
458         * testsuite/ld-msp430-elf/attr-gnu-region-upper.d: New test.
459         * testsuite/ld-msp430-elf/msp430-elf.exp: Run new tests.
461 2019-10-07  Alan Modra  <amodra@gmail.com>
463         * ldmisc.c (vfinfo): Save and restore bfd_error around bfd
464         function calls that might set it.
465         * testsuite/ld-elf/indirect.exp: Don't expect "nonrepresentable
466         section" message.
468 2019-10-07  Alan Modra  <amodra@gmail.com>
470         * testsuite/ld-powerpc/tlsexe.r: Adjust for added TLSMARK symbol.
471         * testsuite/ld-powerpc/tlsexe32.r: Likewise.
472         * testsuite/ld-powerpc/tlsso.r: Likewise.
473         * testsuite/ld-powerpc/tlsso32.r: Likewise.
474         * testsuite/ld-powerpc/tls32no.d,
475         * testsuite/ld-powerpc/tls32no.g: New test files.
476         * testsuite/ld-powerpc/tlsexe32no.d,
477         * testsuite/ld-powerpc/tlsexe32no.g,
478         * testsuite/ld-powerpc/tlsexe32no.r: New test files.
479         * testsuite/ld-powerpc/tlsexeno.d,
480         * testsuite/ld-powerpc/tlsexeno.g,
481         * testsuite/ld-powerpc/tlsexeno.r: New test files.
482         * testsuite/ld-powerpc/tlsexetocno.d,
483         * testsuite/ld-powerpc/tlsexetocno.g: New test files.
484         * testsuite/ld-powerpc/tlsno.d,
485         * testsuite/ld-powerpc/tlsno.g: New test files.
486         * testsuite/ld-powerpc/tlstocno.d,
487         * testsuite/ld-powerpc/tlstocno.g: New test files.
488         * testsuite/ld-powerpc/powerpc.exp: Run new tests.
490 2019-10-07  Alan Modra  <amodra@gmail.com>
492         * testsuite/ld-arm/tls-gdesc-neg.d: Relax target match.
494 2019-10-04  Alan Modra  <amodra@gmail.com>
496         * testsuite/ld-powerpc/tlsso.d: Adjust to suit tlsld_got usage change.
497         * testsuite/ld-powerpc/tlsso.g: Likewise.
498         * testsuite/ld-powerpc/tlsso.r: Likewise.
499         * testsuite/ld-powerpc/tlsso32.d: Likewise.
500         * testsuite/ld-powerpc/tlsso32.g: Likewise.
501         * testsuite/ld-powerpc/tlsso32.r: Likewise.
503 2019-10-04  Szabolcs Nagy  <szabolcs.nagy@arm.com>
505         PR ld/25062
506         * testsuite/ld-arm/arm-elf.exp: Update.
507         * testsuite/ld-arm/tls-gdesc-neg.d: New test.
508         * testsuite/ld-arm/tls-gdesc-neg.s: New test.
510 2019-09-23  Nick Alcock  <nick.alcock@oracle.com>
512         * configure.ac (TESTCTFLIB): Set to the .so or .a, like TESTBFDLIB.
513         * Makefile.am (TESTCTFLIB): Use it.
514         (LIBCTF): Use the .la file.
515         (check-DEJAGNU): Use it.
516         * Makefile.in: Regenerated.
517         * configure: Likewise.
519 2019-09-30  Nick Alcock  <nick.alcock@oracle.com>
521         * ldlang.h: (struct lang_input_statement_struct): Add the_ctf.
522         (struct elf_sym_strtab): Add forward.
523         (struct elf_strtab_hash): Likewise.
524         (ldlang_ctf_apply_strsym): Declare.
525         (ldlang_write_ctf_late): Likewise.
526         * ldemul.h (ldemul_emit_ctf_early): New.
527         (ldemul_examine_strtab_for_ctf): Likewise.
528         (ld_emulation_xfer_type) <emit_ctf_early>: Likewise.
529         (ld_emulation_xfer_type) <examine_strtab_for_ctf>: Likewise.
530         * ldemul.c (ldemul_emit_ctf_early): New.
531         (ldemul_examine_strtab_for_ctf): Likewise.
532         * ldlang.c: Include ctf-api.h.
533         (CTF_COMPRESSION_THRESHOLD): New.
534         (ctf_output): New. Initialized in...
535         (ldlang_open_ctf): ... this new function.  Open all the CTF
536         sections in the input files: mark them non-loaded and empty
537         so as not to copy their contents to the output, but linker-created
538         so the section gets created in the target.
539         (ldlang_merge_ctf): New, merge types via ctf_link_add_ctf and
540         ctf_link.
541         (ldlang_ctf_apply_strsym): New, an examine_strtab callback: wrap
542         ldemul_examine_strtab_for_ctf.
543         (lang_write_ctf): New, write out the CTF section.
544         (ldlang_write_ctf_late): New, late call via bfd's emit_ctf hook.
545         (lang_process): Call ldlang_open_ctf, ldlang_merge_ctf, and
546         lang_write_ctf.
547         * ldmain.c (link_callbacks): Add ldlang_ctf_apply_strsym,
548         ldlang_write_ctf_late.
549         * emultempl/aix.em: Add ctf-api.h.
550         * emultempl/armcoff.em: Likewise.
551         * emultempl/beos.em: Likewise.
552         * emultempl/elf.em: Likewise.
553         * emultempl/generic.em: Likewise.
554         * emultempl/linux.em: Likewise.
555         * emultempl/msp430.em: Likewise.
556         * emultempl/pe.em: Likewise.
557         * emultempl/pep.em: Likewise.
558         * emultempl/ticoff.em: Likewise.
559         * emultempl/vanilla.em: Likewise.
560         * ldcref.c: Likewise.
561         * ldctor.c: Likewise.
562         * ldelf.c: Likewise.
563         * ldelfgen.c: Likewise.
564         * ldemul.c: Likewise.
565         * ldexp.c: Likewise.
566         * ldfile.c: Likewise.
567         * ldgram.c: Likewise.
568         * ldlex.l: Likewise.
569         * ldmain.c: Likewise.
570         * ldmisc.c: Likewise.
571         * ldver.c: Likewise.
572         * ldwrite.c: Likewise.
573         * lexsup.c: Likewise.
574         * mri.c: Likewise.
575         * pe-dll.c: Likewise.
576         * plugin.c: Likewise.
578         * ldelfgen.c (ldelf_emit_ctf_early): New.
579         (ldelf_examine_strtab_for_ctf): tell libctf about the symtab and
580         strtab.
581         (struct ctf_strsym_iter_cb_arg): New, state to do so.
582         (ldelf_ctf_strtab_iter_cb): New: tell libctf about
583         each string in the strtab in turn.
584         (ldelf_ctf_symbols_iter_cb): New, tell libctf
585         about each symbol in the symtab in turn.
586         * ldelfgen.h (struct elf_sym_strtab): Add forward.
587         (struct elf_strtab_hash): Likewise.
588         (struct ctf_file): Likewise.
589         (ldelf_emit_ctf_early): Declare.
590         (ldelf_examine_strtab_for_ctf): Likewise.
591         * emultempl/elf-generic.em (LDEMUL_EMIT_CTF_EARLY): Set it.
592         (LDEMUL_EXAMINE_STRTAB_FOR_CTF): Likewise.
593         * emultempl/aix.em (ld_${EMULATION_NAME}_emulation): Add
594         emit_ctf_early and examine_strtab_for_ctf, NULL by default.
595         * emultempl/armcoff.em (ld_${EMULATION_NAME}_emulation): Likewise.
596         * emultempl/beos.em (ld_${EMULATION_NAME}_emulation): Likewise.
597         * emultempl/elf.em (ld_${EMULATION_NAME}_emulation): Likewise.
598         * emultempl/generic.em (ld_${EMULATION_NAME}_emulation): Likewise.
599         * emultempl/linux.em (ld_${EMULATION_NAME}_emulation): Likewise.
600         * emultempl/msp430.em (ld_${EMULATION_NAME}_emulation): Likewise.
601         * emultempl/pe.em (ld_${EMULATION_NAME}_emulation): Likewise.
602         * emultempl/pep.em (ld_${EMULATION_NAME}_emulation): Likewise.
603         * emultempl/ticoff.em (ld_${EMULATION_NAME}_emulation): Likewise.
604         * emultempl/vanilla.em (ld_vanilla_emulation): Likewise.
606         * Makefile.am: Pull in libctf (and zlib, a transitive requirement
607         for compressed CTF section emission).  Pass it on to DejaGNU.
608         * configure.ac: Add AM_ZLIB.
609         * aclocal.m4: Added zlib.m4.
610         * Makefile.in: Regenerated.
611         * testsuite/ld-bootstrap/bootstrap.exp: Use it when relinking ld.
613 2019-10-02  Alan Modra  <amodra@gmail.com>
615         * ld.texi (-Bsymbolic, -Bsymbolic-functions): Don't mention PIEs.
616         * ld.h (symbolic_enum, dynamic_list_enum),
617         (args_type <symbolic, dynamic_list>): Move to..
618         * lexsup.c (parse_args): ..here, using auto vars opt_symbolic
619         and opt_dynamic_list rather than command_line fields.  Only
620         act on -Bsymbolic and -Bsymbolic-functions for shared library
621         output.  Free dynamic_list.
623 2019-09-26  Alan Modra  <amodra@gmail.com>
625         PR 24262
626         * ld.texi (-plugin): Revert 2019-03-15 change.
628 2019-09-25  Alan Modra  <amodra@gmail.com>
630         * ld.texi (SORT_BY_ALIGNMENT): Reword slightly.
631         (SORT_BY_INIT_PRIORITY): Elucidate.
632         * ldlang.c: Include limits.h.
633         (get_init_priority): Comment.  Change param to a section,
634         return an int.  Sanity check priority digits.  Support sorting
635         more sections with trailing digits.  Return -1 on error.
636         (compare_section): Adjust.
638 2019-09-25  Nick Clifton  <nickc@redhat.com>
640         * emultempl/avrelf.em (_before_allocation): Silence build warning
641         using clang.
643 2019-09-23  H.J. Lu  <hongjiu.lu@intel.com>
645         * testsuite/ld-plugin/pr24406-1.c (main): Correct buffer size
646         to read.
648 2019-09-23  Alan Modra  <amodra@gmail.com>
650         * deffilep.y: Include bfdlink.h.
651         * ldelf.c: Likewise.
652         * ldelfgen.c: Likewise.
653         * ldver.c: Likewise.
654         * mri.c: Likewise.
655         * emultempl/irix.em: Don't include ld.h, ldmain.h, libiberty.h.
656         Comment.
658 2019-09-23  Alan Modra  <amodra@gmail.com>
660         * emultempl/m68kelf.em: Include elf32-m68k.h.
662 2019-09-23  Alan Modra  <amodra@gmail.com>
664         * emultempl/bfin.em: Include elf32-bfin.h.
666 2019-09-23  Alan Modra  <amodra@gmail.com>
668         * emultempl/cr16elf.em: Include elf32-cr16.h.
670 2019-09-23  Alan Modra  <amodra@gmail.com>
672         * emultempl/aix.em: Include xcofflink.h.
674 2019-09-23  Alan Modra  <amodra@gmail.com>
676         * emultempl/armelf.em: Include elf32-arm.h.
677         * emultempl/pe.em: Move func defines later and include coff-arm.h.
679 2019-09-23  Alan Modra  <amodra@gmail.com>
681         * emultempl/aarch64elf.em: Include elfxx-aarch64.h.
683 2019-09-23  Alan Modra  <amodra@gmail.com>
685         * emultempl/ia64elf.em: Include elfxx-ia64.h.
687 2019-09-23  Alan Modra  <amodra@gmail.com>
689         * emultempl/v850elf.em: Include elf32-v850.h.
691 2019-09-23  Alan Modra  <amodra@gmail.com>
693         * emultempl/cskyelf.em: Include elf32-csky.h.
695 2019-09-22  Alan Modra  <amodra@gmail.com>
697         * testsuite/ld-srec/sr3.cc (FOO_MSG_LEN): Set to 4.
699 2019-09-20  Nelson Chu <nelson.chu@sifive.com>
701         * testsuite/ld-riscv-elf/weakref32.s: Add relaxable undef weak code.
702         * testsuite/ld-riscv-elf/weakref64.s: Likewise.
703         * testsuite/ld-riscv-elf/weakref32.d: Updated.
704         * testsuite/ld-riscv-elf/weakref64.d: Updated.
706 2019-09-20  Alan Modra  <amodra@gmail.com>
708         * emultempl/xtensaelf.em (xtensa_get_section_deps): Comment.
709         Use bfd_section_userdata.
710         (xtensa_set_section_deps): Use bfd_set_section_userdata.
711         * ldlang.c (lang_output_section_get): Use bfd_section_userdata.
712         (sort_def_symbol): Likewise, and bfd_set_section_userdata.
713         (init_os): Use bfd_set_section_userdata.
714         (print_all_symbols): Use bfd_section_userdata.
715         * ldlang.h (get_userdata): Delete.
717 2019-09-20  Alan Modra  <amodra@gmail.com>
719         * ldelf.c (ldelf_after_open, ldelf_place_orphan
720         * ldlang.c (walk_wild_file, lang_process): Use bfd_usrdata.
721         (load_symbols, ldlang_add_file): Use bfd_set_usrdata.
722         * ldmain.c (add_archive_element): Use bfd_usrdata.
723         * ldlang.h (bfd_input_just_syms): New inline function.
724         * emultempl/aarch64elf.em (build_section_lists): Use it.
725         * emultempl/mmo.em (mmo_place_orphan): Likewise.
726         * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
727         * emultempl/pep.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
728         * emultempl/ppc64elf.em (build_section_lists): Likewise.
730 2019-09-18  Alan Modra  <amodra@gmail.com>
732         * ldcref.c, * ldctor.c, * ldelf.c, * ldlang.c, * pe-dll.c,
733         * emultempl/aarch64elf.em, * emultempl/aix.em,
734         * emultempl/armcoff.em, * emultempl/armelf.em,
735         * emultempl/cr16elf.em, * emultempl/cskyelf.em,
736         * emultempl/m68hc1xelf.em, * emultempl/m68kelf.em,
737         * emultempl/mipself.em, * emultempl/mmix-elfnmmo.em,
738         * emultempl/mmo.em, * emultempl/msp430.em,
739         * emultempl/nios2elf.em, * emultempl/pe.em, * emultempl/pep.em,
740         * emultempl/ppc64elf.em, * emultempl/xtensaelf.em: Update
741         throughout for bfd section macro and function changes.
743 2019-09-18  Alan Modra  <amodra@gmail.com>
745         * ldcref.c (check_reloc_refs): Update bfd_get_section to
746         bfd_asymbol_section.
748 2019-09-18  Simon Marchi  <simon.marchi@polymtl.ca>
750         * Makefile.in: Re-generate.
751         * configure: Re-generate.
753 2019-09-18  Alan Modra  <amodra@gmail.com>
755         * ldlang.c (stricpy, strcut, name_compare): Constify params.
756         (get_first_input_target): Make return and "target" const.
758 2019-09-18  Alan Modra  <amodra@gmail.com>
760         * emultempl/pe.em (after_open): Use bfd_set_filename.
761         * emultempl/pep.em (after_open): Use bfd_set_filename.
763 2019-09-16  Alan Modra  <amodra@gmail.com>
765         PR 25002
766         * ldelf.c: Include safe-ctype.h.
768 2019-09-16  Phil Blundell  <pb@pbcl.net>
770         * Makefile.in, configure: Regenerated.
772 2019-09-13  Alan Modra  <amodra@gmail.com>
774         * ldlang.c (new_afile): Remove add_to_list parameter.
775         (lang_add_input_file): Update new_afile calls.
776         (lookup_name): Splice input_statement added by new_afile into
777         statement_list after current input_file_chain entry.
778         (lang_process): Update comment.
780 2019-09-12  Alan Modra  <amodra@gmail.com>
782         * ldlang.c (print_input_statement): Do not exclude linker created
783         BFDs.
785 2019-09-12  Alan Modra  <amodra@gmail.com>
787         PR 24981
788         * ldlang.c (lang_process): Remove assertion.  Comment.
790 2019-09-11  Alan Modra  <amodra@gmail.com>
792         * emultempl/elf32.em: Remove "misnamed" comment.  Rename to..
793         * emultempl/elf.em: ..this.
794         * configure.ac (elf_list_options): Adjust TEMPLATE_NAME grep.
795         * emulparams/aarch64cloudabi.sh (TEMPLATE_NAME): Set to elf.
796         * emulparams/aarch64elf.sh: Likewise.
797         * emulparams/aarch64elf32.sh: Likewise.
798         * emulparams/aarch64fbsd.sh: Likewise.
799         * emulparams/aarch64linux.sh: Likewise.
800         * emulparams/aarch64linux32.sh: Likewise.
801         * emulparams/arcelf.sh: Likewise.
802         * emulparams/arcelf_prof.sh: Likewise.
803         * emulparams/arclinux.sh: Likewise.
804         * emulparams/arclinux_prof.sh: Likewise.
805         * emulparams/arcv2elf.sh: Likewise.
806         * emulparams/arcv2elfx.sh: Likewise.
807         * emulparams/armelf.sh: Likewise.
808         * emulparams/armelf_fuchsia.sh: Likewise.
809         * emulparams/armelf_linux.sh: Likewise.
810         * emulparams/armelf_phoenix.sh: Likewise.
811         * emulparams/armnto.sh: Likewise.
812         * emulparams/avr1.sh: Likewise.
813         * emulparams/avr2.sh: Likewise.
814         * emulparams/avr25.sh: Likewise.
815         * emulparams/avr3.sh: Likewise.
816         * emulparams/avr31.sh: Likewise.
817         * emulparams/avr35.sh: Likewise.
818         * emulparams/avr4.sh: Likewise.
819         * emulparams/avr5.sh: Likewise.
820         * emulparams/avr51.sh: Likewise.
821         * emulparams/avr6.sh: Likewise.
822         * emulparams/avrtiny.sh: Likewise.
823         * emulparams/avrxmega1.sh: Likewise.
824         * emulparams/avrxmega2.sh: Likewise.
825         * emulparams/avrxmega3.sh: Likewise.
826         * emulparams/avrxmega4.sh: Likewise.
827         * emulparams/avrxmega5.sh: Likewise.
828         * emulparams/avrxmega6.sh: Likewise.
829         * emulparams/avrxmega7.sh: Likewise.
830         * emulparams/criself.sh: Likewise.
831         * emulparams/crislinux.sh: Likewise.
832         * emulparams/cskyelf.sh: Likewise.
833         * emulparams/d10velf.sh: Likewise.
834         * emulparams/elf32_sparc.sh: Likewise.
835         * emulparams/elf32_spu.sh: Likewise.
836         * emulparams/elf32_tic6x_le.sh: Likewise.
837         * emulparams/elf32_x86_64.sh: Likewise.
838         * emulparams/elf32am33lin.sh: Likewise.
839         * emulparams/elf32bfin.sh: Likewise.
840         * emulparams/elf32bfinfd.sh: Likewise.
841         * emulparams/elf32bmip.sh: Likewise.
842         * emulparams/elf32bmipn32-defs.sh: Likewise.
843         * emulparams/elf32cr16.sh: Likewise.
844         * emulparams/elf32cr16c.sh: Likewise.
845         * emulparams/elf32crx.sh: Likewise.
846         * emulparams/elf32epiphany.sh: Likewise.
847         * emulparams/elf32epiphany_4x4.sh: Likewise.
848         * emulparams/elf32frvfd.sh: Likewise.
849         * emulparams/elf32ip2k.sh: Likewise.
850         * emulparams/elf32lm32.sh: Likewise.
851         * emulparams/elf32lm32fd.sh: Likewise.
852         * emulparams/elf32lriscv-defs.sh: Likewise.
853         * emulparams/elf32m32c.sh: Likewise.
854         * emulparams/elf32mb_linux.sh: Likewise.
855         * emulparams/elf32mbel_linux.sh: Likewise.
856         * emulparams/elf32mcore.sh: Likewise.
857         * emulparams/elf32mep.sh: Likewise.
858         * emulparams/elf32metag.sh: Likewise.
859         * emulparams/elf32microblaze.sh: Likewise.
860         * emulparams/elf32mipswindiss.sh: Likewise.
861         * emulparams/elf32or1k.sh: Likewise.
862         * emulparams/elf32ppccommon.sh: Likewise.
863         * emulparams/elf32rl78.sh: Likewise.
864         * emulparams/elf32rx.sh: Likewise.
865         * emulparams/elf32tilegx.sh: Likewise.
866         * emulparams/elf32tilepro.sh: Likewise.
867         * emulparams/elf32vax.sh: Likewise.
868         * emulparams/elf32visium.sh: Likewise.
869         * emulparams/elf32xc16x.sh: Likewise.
870         * emulparams/elf32xc16xl.sh: Likewise.
871         * emulparams/elf32xc16xs.sh: Likewise.
872         * emulparams/elf32xstormy16.sh: Likewise.
873         * emulparams/elf32xtensa.sh: Likewise.
874         * emulparams/elf64_aix.sh: Likewise.
875         * emulparams/elf64_ia64.sh: Likewise.
876         * emulparams/elf64_s390.sh: Likewise.
877         * emulparams/elf64_sparc.sh: Likewise.
878         * emulparams/elf64alpha.sh: Likewise.
879         * emulparams/elf64bpf.sh: Likewise.
880         * emulparams/elf64hppa.sh: Likewise.
881         * emulparams/elf64mmix.sh: Likewise.
882         * emulparams/elf64rdos.sh: Likewise.
883         * emulparams/elf64tilegx.sh: Likewise.
884         * emulparams/elf_i386.sh: Likewise.
885         * emulparams/elf_i386_be.sh: Likewise.
886         * emulparams/elf_i386_ldso.sh: Likewise.
887         * emulparams/elf_i386_vxworks.sh: Likewise.
888         * emulparams/elf_iamcu.sh: Likewise.
889         * emulparams/elf_k1om.sh: Likewise.
890         * emulparams/elf_l1om.sh: Likewise.
891         * emulparams/elf_s390.sh: Likewise.
892         * emulparams/elf_x86_64.sh: Likewise.
893         * emulparams/h8300elf.sh: Likewise.
894         * emulparams/h8300elf_linux.sh: Likewise.
895         * emulparams/hppa64linux.sh: Likewise.
896         * emulparams/hppaelf.sh: Likewise.
897         * emulparams/hppalinux.sh: Likewise.
898         * emulparams/i386lynx.sh: Likewise.
899         * emulparams/i386moss.sh: Likewise.
900         * emulparams/i386nto.sh: Likewise.
901         * emulparams/m32relf.sh: Likewise.
902         * emulparams/m32relf_linux.sh: Likewise.
903         * emulparams/m68hc11elf.sh: Likewise.
904         * emulparams/m68hc11elfb.sh: Likewise.
905         * emulparams/m68hc12elf.sh: Likewise.
906         * emulparams/m68hc12elfb.sh: Likewise.
907         * emulparams/m68kelf.sh: Likewise.
908         * emulparams/mn10300.sh: Likewise.
909         * emulparams/nds32elf.sh: Likewise.
910         * emulparams/nds32elf16m.sh: Likewise.
911         * emulparams/nds32elf_linux.sh: Likewise.
912         * emulparams/nios2elf.sh: Likewise.
913         * emulparams/nios2linux.sh: Likewise.
914         * emulparams/pruelf.sh: Likewise.
915         * emulparams/score3_elf.sh: Likewise.
916         * emulparams/shelf.sh: Likewise.
917         * emulparams/shelf_nto.sh: Likewise.
918         * emulparams/shelf_vxworks.sh: Likewise.
919         * emulparams/shlelf_linux.sh: Likewise.
920         * emulparams/shlelf_nto.sh: Likewise.
921         * emulparams/v850.sh: Likewise.
922         * emulparams/v850_rh850.sh: Likewise.
923         * ldelf.c: Update comment.
924         * ldelf.h: Likewise.
925         * emultempl/aarch64elf.em: Likewise.
926         * emultempl/alphaelf.em: Likewise.
927         * emultempl/arclinux.em: Likewise.
928         * emultempl/armelf.em: Likewise.
929         * emultempl/avrelf.em: Likewise.
930         * emultempl/bfin.em: Likewise.
931         * emultempl/cr16elf.em: Likewise.
932         * emultempl/crxelf.em: Likewise.
933         * emultempl/cskyelf.em: Likewise.
934         * emultempl/elf-generic.em: Likewise.
935         * emultempl/elf-x86.em: Likewise.
936         * emultempl/epiphanyelf_4x4.em: Likewise.
937         * emultempl/hppaelf.em: Likewise.
938         * emultempl/ia64elf.em: Likewise.
939         * emultempl/m68hc1xelf.em: Likewise.
940         * emultempl/m68kelf.em: Likewise.
941         * emultempl/metagelf.em: Likewise.
942         * emultempl/mmix-elfnmmo.em: Likewise.
943         * emultempl/mmixelf.em: Likewise.
944         * emultempl/mmo.em: Likewise.
945         * emultempl/needrelax.em: Likewise.
946         * emultempl/nios2elf.em: Likewise.
947         * emultempl/ppc32elf.em: Likewise.
948         * emultempl/ppc64elf.em: Likewise.
949         * emultempl/pruelf.em: Likewise.
950         * emultempl/rxelf.em: Likewise.
951         * emultempl/scoreelf.em: Likewise.
952         * emultempl/spuelf.em: Likewise.
953         * emultempl/tic6xdsbt.em: Likewise.
954         * emultempl/v850elf.em: Likewise.
955         * emultempl/vms.em: Likewise.
956         * emultempl/vxworks.em: Likewise.
957         * emultempl/xtensaelf.em: Likewise.
958         * scripttempl/arclinux.sc: Likewise.
959         * scripttempl/armbpabi.sc: Likewise.
960         * scripttempl/elf.sc: Likewise.
961         * scripttempl/elf64bpf.sc: Likewise.
962         * scripttempl/elf64hppa.sc: Likewise.
963         * scripttempl/elf_chaos.sc: Likewise.
964         * scripttempl/elfarc.sc: Likewise.
965         * scripttempl/elfarcv2.sc: Likewise.
966         * scripttempl/elfd10v.sc: Likewise.
967         * scripttempl/elfm68hc11.sc: Likewise.
968         * scripttempl/elfm68hc12.sc: Likewise.
969         * scripttempl/elfm9s12z.sc: Likewise.
970         * scripttempl/elfxgate.sc: Likewise.
971         * scripttempl/elfxtensa.sc: Likewise.
972         * scripttempl/epiphany_4x4.sc: Likewise.
973         * scripttempl/iq2000.sc: Likewise.
974         * scripttempl/mep.sc: Likewise.
975         * scripttempl/nds32elf.sc: Likewise.
976         * scripttempl/v850.sc: Likewise.
977         * scripttempl/v850_rh850.sc: Likewise.
978         * scripttempl/xstormy16.sc: Likewise.
979         * testsuite/ld-arm/arm-dyn.ld: Likewise.
980         * testsuite/ld-arm/arm-lib.ld: Likewise.
981         * testsuite/ld-arm/arm-no-rel-plt.ld: Likewise.
982         * testsuite/ld-arm/fdpic-main.ld: Likewise.
983         * testsuite/ld-arm/fdpic-shared.ld: Likewise.
984         * testsuite/ld-elf/elf.exp: Likewise.
985         * testsuite/ld-elf/orphan-region.d: Likewise.
986         * testsuite/ld-elf/orphan.d: Likewise.
987         * testsuite/ld-elf/pr349.d: Likewise.
988         * testsuite/ld-elf/warn2.d: Likewise.
989         * testsuite/ld-elfvsb/elf-offset.ld: Likewise.
990         * testsuite/ld-mips-elf/mips-dyn.ld: Likewise.
991         * testsuite/ld-mips-elf/mips-lib.ld: Likewise.
992         * testsuite/ld-scripts/dynamic-sections.t: Likewise.
993         * testsuite/ld-shared/elf-offset.ld: Likewise.
994         * configure: Regenerate.
996 2019-09-11  Alan Modra  <amodra@gmail.com>
998         * Makefile.am (ALL_EMUL_EXTRA_OFILES): Add ldelf and ldelfgen.
999         (CFILES, HFILES, EXTRA_ld_new_SOURCES): Likewise.
1000         * configure.tgt: Formatting.
1001         (targ_extra_ofiles): Init to ldelf.o ldelfgen.o, reset to just
1002         ldelfgen.o for generic ELF targets, and empty for non-ELF.
1003         * emultempl/aarch64elf.em (gldaarch64_layout_sections_again): Use
1004         ldelf_map_segments.
1005         (gld${EMULATION_NAME}_after_allocation): Likewise.
1006         (real_func, aarch64_for_each_input_file_wrapper),
1007         (aarch64_lang_for_each_input_file): Delete.
1008         (lang_for_each_input_file): Don't define.
1009         * emultempl/alphaelf.em (alpha_after_parse): Use ldelf_map_segments.
1010         * emultempl/armelf.em (gldarm_layout_sections_again): Likewise.
1011         (gld${EMULATION_NAME}_after_allocation): Likewise.
1012         (real_func, arm_for_each_input_file_wrapper),
1013         (arm_lang_for_each_input_file): Delete.
1014         (lang_for_each_input_file): Don't define.
1015         * emultempl/cr16elf.em (cr16elf_after_parse): Use ldelf_map_segments.
1016         * emultempl/crxelf.em (crxelf_after_parse): Likewise.  Delete
1017         declaration.
1018         * emultempl/cskyelf.em (gldcsky_layout_sections_again): Use
1019         ldelf_map_segments.
1020         (gld${EMULATION_NAME}_after_allocation): Likewise.
1021         (real_func, csky_for_each_input_file_wrapper),
1022         (csky_lang_for_each_input_file): Delete.
1023         (lang_for_each_input_file): Don't define.
1024         * emultempl/genelf.em: Include ldelfgen.h.
1025         (gld${EMULATION_NAME}_before_allocation): Use ldelf_map_segments.
1026         * emultempl/hppaelf.em (hppaelf_after_parse): Likewise.
1027         (hppaelf_layout_sections_again): Likewise.
1028         (gld${EMULATION_NAME}_after_allocation): Likewise.
1029         (real_func, hppa_for_each_input_file_wrapper),
1030         (hppa_lang_for_each_input_file): Delete.
1031         (lang_for_each_input_file): Don't define.
1032         * emultempl/ia64elf.em (ia64elf_after_parse): Use ldelf_map_segments.
1033         * emultempl/m68hc1xelf.em (real_func),
1034         (m68hc11_for_each_input_file_wrapper),
1035         (m68hc11_lang_for_each_input_file): Delete.
1036         (lang_for_each_input_file): Don't define.
1037         * emultempl/metagelf.em (metagelf_layout_sections_again): Use
1038         ldelf_map_segments.
1039         (gld${EMULATION_NAME}_after_allocation): Likewise.
1040         (real_func, metag_for_each_input_file_wrapper),
1041         (metag_lang_for_each_input_file): Delete.
1042         (lang_for_each_input_file): Don't define.
1043         * emultempl/mipself.em (real_func),
1044         (mips_for_each_input_file_wrapper),
1045         (mips_lang_for_each_input_file): Delete.
1046         (lang_for_each_input_file): Don't define.
1047         * emultempl/mmo.em: Don't include elf-bfd.h, do include ldelfgen.h.
1048         (gld${EMULATION_NAME}_after_allocation): Use ldelf_map_segments.
1049         * emultempl/nds32elf.em (nds32_elf_after_parse): Use ldelf_after_parse.
1050         (nds32_elf_after_allocation): Comment fix.
1051         * emultempl/nios2elf.em (nios2elf_layout_sections_again): Use
1052         ldelf_map_segments.
1053         (gld${EMULATION_NAME}_after_allocation): Likewise.
1054         (real_func, nios2_for_each_input_file_wrapper),
1055         (nios2_lang_for_each_input_file): Delete.
1056         (lang_for_each_input_file): Don't define.
1057         * emultempl/ppc32elf.em (gld${EMULATION_NAME}_load_symbols): Delete
1058         declaration.
1059         (ppc_recognized_file): Call ldelf_load_symbols.
1060         * emultempl/ppc64elf.em (ppc_layout_sections_again): Likewise.
1061         (gld${EMULATION_NAME}_after_allocation): Likewise.
1062         (real_func, ppc_for_each_input_file_wrapper),
1063         (ppc_lang_for_each_input_file): Delete.
1064         (lang_for_each_input_file): Don't define.
1065         (gld${EMULATION_NAME}_load_symbols): Don't declare.
1066         (ppc64_recognized_file): Call ldelf_load_symbols.
1067         * emultempl/riscvelf.em (gld${EMULATION_NAME}_after_allocation):
1068         Use ldelf_map_segments.
1069         * emultempl/spuelf.em (spu_place_special_section): Use
1070         ldelf_place_orphan.
1071         * emultempl/tic6xdsbt.em (gld${EMULATION_NAME}_after_allocation):
1072         Use ldelf_map_segments.
1073         * emultempl/vms.em: Include ldelfgen.h.
1074         (gld${EMULATION_NAME}_after_allocation): Use ldelf_map_segments.
1075         * emultempl/elf32.em: Remove unnecessary headers, include ldelf.h
1076         and ldelfgen.h.  Move much of file content to..
1077         * ldelf.c: ..here.  New file.
1078         * ldelf.h: New file.
1079         * emultempl/elf-generic.em: Move gld${EMULATION_NAME}_map_segments..
1080         * ldelfgen.c: ..to here.
1081         * ldelfgen.h: New file.
1082         * ldlang.c (lang_for_each_input_file): Adjust to only call func
1083         on real files.
1084         (lang_for_each_file): Likewise.
1085         * po/SRC-POTFILES.in: Regenerate.
1086         * Makefile.in: Regenerate.
1088 2019-09-11  Alan Modra  <amodra@gmail.com>
1090         * ldmisc.c: Don't #include elf-bfd.h or coff-bfd.h.
1091         (vfinfo): Use bfd_group_name.
1093 2019-09-11  Alan Modra  <amodra@gmail.com>
1095         * plugin.c (asymbol_from_plugin_symbol): Move code handling
1096         ELF common symbols to block handling ELF visibility.  Simplify
1097         visibility setting.
1099 2019-09-09  H.J. Lu  <hongjiu.lu@intel.com>
1101         PR binutils/24887
1102         * testsuite/ld-i386/property-1.r: Adjust for new output format
1103         from readelf.
1104         * testsuite/ld-i386/property-1a.r: Likewise.
1105         * testsuite/ld-i386/property-2.r: Likewise.
1106         * testsuite/ld-i386/property-2a.r: Likewise.
1107         * testsuite/ld-i386/property-3.r: Likewise.
1108         * testsuite/ld-i386/property-3a.r: Likewise.
1109         * testsuite/ld-i386/property-4.r: Likewise.
1110         * testsuite/ld-i386/property-4a.r: Likewise.
1111         * testsuite/ld-i386/property-5.r: Likewise.
1112         * testsuite/ld-i386/property-5a.r: Likewise.
1113         * testsuite/ld-i386/property-6.r: Likewise.
1114         * testsuite/ld-i386/property-7.r: Likewise.
1115         * testsuite/ld-i386/property-7a.r: Likewise.
1116         * testsuite/ld-i386/property-1.r: Likewise.
1117         * testsuite/ld-i386/property-1a.r: Likewise.
1118         * testsuite/ld-i386/property-2.r: Likewise.
1119         * testsuite/ld-i386/property-2a.r: Likewise.
1120         * testsuite/ld-i386/property-3.r: Likewise.
1121         * testsuite/ld-i386/property-3a.r: Likewise.
1122         * testsuite/ld-i386/property-4.r: Likewise.
1123         * testsuite/ld-i386/property-4a.r: Likewise.
1124         * testsuite/ld-i386/property-5.r: Likewise.
1125         * testsuite/ld-i386/property-5a.r: Likewise.
1126         * testsuite/ld-i386/property-6.r: Likewise.
1127         * testsuite/ld-i386/property-7.r: Likewise.
1128         * testsuite/ld-i386/property-7a.r: Likewise.
1130 2019-09-09  Phil Blundell  <pb@pbcl.net>
1132         binutils 2.33 branch created.
1134 2019-09-06  Alan Modra  <amodra@gmail.com>
1136         * emultempl/beos.em (sort_by_file_name): Use appropriate
1137         intermediary variables.
1138         (sort_by_section_name): Likewise.
1140 2019-09-06  Alan Modra  <amodra@gmail.com>
1142         * emultempl/elf32.em (gld${EMULATION_NAME}_search_needed): Constify
1143         variable.
1144         * emultempl/pe.em (gld_${EMULATION_NAME}_after_open): Likewise.
1145         * emultempl/pep.em (gld_${EMULATION_NAME}_after_open): Likewise.
1147 2019-09-05  Eric Botcazou  <ebotcazou@adacore.com>
1149         PR ld/24574
1150         * pe-dll.c (pe_find_data_imports): Replace again the original name of
1151         the undefined symbol with the __imp_ prefixed one after it is resolved.
1153 2019-09-05  Alan Modra  <amodra@gmail.com>
1155         * testsuite/ld-powerpc/pcrelopt.s,
1156         * testsuite/ld-powerpc/pcrelopt.d: Test offset and prefix in
1157         second instruction.
1159 2019-08-29  Alan Modra  <amodra@gmail.com>
1161         PR ld/24406
1162         * plugin.c (get_symbols): Test link_info.wrap_hash before calling
1163         unwrap_hash_lookup.
1165 2019-08-22  Tamar Christina  <tamar.christina@arm.com>
1167         PR ld/24601
1168         * testsuite/ld-aarch64/aarch64-elf.exp (undef-tls, weak-tls): New.
1169         * testsuite/ld-aarch64/undef-tls.d: New test.
1170         * testsuite/ld-aarch64/undef-tls.s: New test.
1171         * testsuite/ld-aarch64/weak-tls.d: New test.
1172         * testsuite/ld-aarch64/weak-tls.s: New test.
1174 2019-08-20  Tamar Christina  <tamar.christina@arm.com>
1176         * testsuite/ld-arm/cortex-a8-fix-b-plt.d: Update Testcase.
1177         * testsuite/ld-arm/cortex-a8-fix-b-rel-arm.d: Likewise.
1178         * testsuite/ld-arm/cortex-a8-fix-bcc-plt.d: Likewise.
1179         * testsuite/ld-arm/farcall-cond-thumb-arm.d: Likewise.
1180         * testsuite/ld-arm/farcall-mixed-app.d: Likewise.
1181         * testsuite/ld-arm/farcall-mixed-app2.d: Likewise.
1182         * testsuite/ld-arm/farcall-mixed-lib-v4t.d: Likewise.
1183         * testsuite/ld-arm/farcall-thumb-arm-pic-veneer.d: Likewise.
1184         * testsuite/ld-arm/farcall-thumb-arm-short.d: Likewise.
1185         * testsuite/ld-arm/farcall-thumb-arm.d: Likewise.
1186         * testsuite/ld-arm/farcall-thumb-thumb-pic-veneer.d: Likewise.
1187         * testsuite/ld-arm/farcall-thumb-thumb.d: Likewise.
1188         * testsuite/ld-arm/fix-arm1176-on.d: Likewise.
1189         * testsuite/ld-arm/ifunc-10.dd: Likewise.
1190         * testsuite/ld-arm/ifunc-2.dd: Likewise.
1191         * testsuite/ld-arm/ifunc-4.dd: Likewise.
1192         * testsuite/ld-arm/ifunc-6.dd: Likewise.
1193         * testsuite/ld-arm/ifunc-8.dd: Likewise.
1194         * testsuite/ld-arm/jump-reloc-veneers-long.d: Likewise.
1195         * testsuite/ld-arm/mixed-app.d: Likewise.
1196         * testsuite/ld-arm/thumb2-b-interwork.d: Likewise.
1197         * testsuite/ld-arm/tls-longplt.d: Likewise.
1198         * testsuite/ld-arm/tls-thumb1.d: Likewise.
1200 2019-08-16  H.J. Lu  <hongjiu.lu@intel.com>
1202         PR ld/24905
1203         * testsuite/ld-x86-64/pr24905-x32.d: New file.
1204         * testsuite/ld-x86-64/pr24905.d: Likewise.
1205         * testsuite/ld-x86-64/pr24905.s: Likewise.
1206         * testsuite/ld-x86-64/pr24905.t: Likewise.
1207         * testsuite/ld-x86-64/x86-64.exp: Run pr24905 and pr24905-x32.
1209 2019-08-16  Christophe Lyon  <christophe.lyon@linaro.org>
1211         * emulparams/armelf.sh (OTHER_SECTIONS): Add support for noinit
1212         section.
1214 2019-08-16  Alan Modra  <amodra@gmail.com>
1216         * emultempl/ppc32elf.em (ppc_before_allocation): Force running
1217         prelim_size_sections before deciding whether branch trampolines
1218         might be needed.
1220 2019-08-15  Jim Wilson  <jimw@sifive.com>
1222         * testsuite/ld-riscv-elf/c-lui-2.d: New.
1223         * testsuite/ld-riscv-elf/c-lui-2.ld: New.
1224         * testsuite/ld-riscv-elf/c-lui-2.s: New.
1225         * testsuite/ld-riscv-elf/ld-riscv-elf.exp: Run the c-lui-2 test.
1227 2019-08-10  Alan Modra  <amodra@gmail.com>
1229         * ldlang.h (enum statement_enum): Sort.
1230         (union lang_statement_union): Sort.
1232 2019-08-10  Alan Modra  <amodra@gmail.com>
1234         * ldlang.h (lang_common_statement_type): Delete.
1235         (lang_object_symbols_statement_type): Delete.
1236         (union lang_statement_union): Remove common_statement and
1237         object_symbols_statement.
1239 2019-08-10  Alan Modra  <amodra@gmail.com>
1241         * ldexp.c (exp_intop, exp_bigintop, exp_relop, exp_binop, exp_trinop),
1242         (exp_unop, exp_nameop, exp_assop, exp_assert): Remove casts of
1243         stat_alloc return value.
1244         * ldlang.c (new_statement, new_afile, sort_def_symbol),
1245         (lang_memory_region_lookup, lang_memory_region_alias),
1246         (ldlang_add_undef, ldlang_add_require_defined, insert_pad),
1247         (lang_add_gc_name, lang_new_phdr): Likewise.
1248         * lexsup.c (set_segment_start): Likewise.
1250 2019-08-10  Alan Modra  <amodra@gmail.com>
1252         * ldlang.h (lang_input_statement_type): Make next
1253         and next_real_file a lang_input_statement_type pointer.
1254         (lang_statement_append): Delete prototype.
1255         (LANG_FOR_EACH_INPUT_STATEMENT): Update for lang_input_statement_type
1256         change.
1257         * ldmain.c (add_archive_element): Likewise.
1258         * ldlang.c: Likewise throughout.
1259         (lang_statement_append): Make static.  Make element and field
1260         void pointers.  Remove casts in calls.
1261         (lang_check): Use a lang_input_statement_type pointer for "file".
1262         (find_rescan_insertion): Similarly for "iter" and return value.
1263         (lang_process): Similarly for "insert", "iter" and "temp".
1264         * emultempl/spuelf.em (embedded_spu_file): Likewise.
1265         * emultempl/aix.em (gld${EMULATION_NAME}_before_allocation): Expand
1266         lang_statment_append call.
1268 2019-08-09  Mihailo Stojanovic  <mihailo.stojanovic@rt-rk.com>
1270         * emulparams/elf32bmip.sh: Add .MIPS.xhash section.
1271         * emulparams/elf32bmipn32-defs.sh: Add .MIPS.xhash section.
1272         * emulparams/elf64bmip-defs.sh: Add .MIPS.xhash section.
1273         * emultempl/mipself.em: Remove mips_after_parse function.
1274         * testsuite/ld-elf/hash.d: Update comment.
1275         * testsuite/ld-mips-elf/hash1.d: New test.
1276         * testsuite/ld-mips-elf/hash1.s: Ditto.
1277         * testsuite/ld-mips-elf/hash1a.d: Remove.
1278         * testsuite/ld-mips-elf/hash1b.d: Ditto.
1279         * testsuite/ld-mips-elf/hash1c.d: Ditto
1280         * testsuite/ld-mips-elf/hash2.d: New test.
1281         * testsuite/ld-mips-elf/mips-elf.exp: New tests.
1282         * testsuite/ld-mips-elf/start.s: New test.
1284 2019-08-08  Nick Clifton  <nickc@redhat.com>
1286         PR 24887
1287         * testsuite/ld-aarch64/bti-plt-2.d: Adjust for new output format
1288         from readelf.
1289         * testsuite/ld-aarch64/bti-plt-4.d: Likewise.
1290         * testsuite/ld-aarch64/bti-plt-6.d: Likewise.
1291         * testsuite/ld-aarch64/bti-plt-7.d: Likewise.
1292         * testsuite/ld-aarch64/bti-warn.d: Likewise.
1293         * testsuite/ld-aarch64/property-bti-pac1.d: Likewise.
1294         * testsuite/ld-aarch64/property-bti-pac2.d: Likewise.
1295         * testsuite/ld-aarch64/property-bti-pac3.d: Likewise.
1296         * testsuite/ld-elf/x86-feature-1a.rd: Likewise.
1297         * testsuite/ld-elf/x86-feature-1b.rd: Likewise.
1298         * testsuite/ld-elf/x86-feature-1c.rd: Likewise.
1299         * testsuite/ld-elf/x86-feature-1d.rd: Likewise.
1300         * testsuite/ld-elf/x86-feature-1e.rd: Likewise.
1301         * testsuite/ld-i386/ibt-plt-2d.d: Likewise.
1302         * testsuite/ld-i386/ibt-plt-3d.d: Likewise.
1303         * testsuite/ld-i386/pr23372a.d: Likewise.
1304         * testsuite/ld-i386/pr23372c.d: Likewise.
1305         * testsuite/ld-i386/pr23486a.d: Likewise.
1306         * testsuite/ld-i386/pr23486b.d: Likewise.
1307         * testsuite/ld-i386/pr23486c.d: Likewise.
1308         * testsuite/ld-i386/pr23486d.d: Likewise.
1309         * testsuite/ld-i386/pr24322a.d: Likewise.
1310         * testsuite/ld-i386/pr24322b.d: Likewise.
1311         * testsuite/ld-i386/property-x86-3.d: Likewise.
1312         * testsuite/ld-i386/property-x86-4a.d: Likewise.
1313         * testsuite/ld-i386/property-x86-5.d: Likewise.
1314         * testsuite/ld-i386/property-x86-cet1.d: Likewise.
1315         * testsuite/ld-i386/property-x86-cet2a.d: Likewise.
1316         * testsuite/ld-i386/property-x86-cet5a.d: Likewise.
1317         * testsuite/ld-i386/property-x86-cet5b.d: Likewise.
1318         * testsuite/ld-i386/property-x86-ibt1a.d: Likewise.
1319         * testsuite/ld-i386/property-x86-ibt1b.d: Likewise.
1320         * testsuite/ld-i386/property-x86-ibt2.d: Likewise.
1321         * testsuite/ld-i386/property-x86-ibt3a.d: Likewise.
1322         * testsuite/ld-i386/property-x86-ibt3b.d: Likewise.
1323         * testsuite/ld-i386/property-x86-ibt4.d: Likewise.
1324         * testsuite/ld-i386/property-x86-ibt5.d: Likewise.
1325         * testsuite/ld-i386/property-x86-shstk1a.d: Likewise.
1326         * testsuite/ld-i386/property-x86-shstk1b.d: Likewise.
1327         * testsuite/ld-i386/property-x86-shstk2.d: Likewise.
1328         * testsuite/ld-i386/property-x86-shstk3a.d: Likewise.
1329         * testsuite/ld-i386/property-x86-shstk3b.d: Likewise.
1330         * testsuite/ld-i386/property-x86-shstk4.d: Likewise.
1331         * testsuite/ld-i386/property-x86-shstk5.d: Likewise.
1332         * testsuite/ld-x86-64/ibt-plt-2d-x32.d: Likewise.
1333         * testsuite/ld-x86-64/ibt-plt-2d.d: Likewise.
1334         * testsuite/ld-x86-64/ibt-plt-3d-x32.d: Likewise.
1335         * testsuite/ld-x86-64/ibt-plt-3d.d: Likewise.
1336         * testsuite/ld-x86-64/pr23372a-x32.d: Likewise.
1337         * testsuite/ld-x86-64/pr23372a.d: Likewise.
1338         * testsuite/ld-x86-64/pr23372c-x32.d: Likewise.
1339         * testsuite/ld-x86-64/pr23372c.d: Likewise.
1340         * testsuite/ld-x86-64/pr23486a-x32.d: Likewise.
1341         * testsuite/ld-x86-64/pr23486a.d: Likewise.
1342         * testsuite/ld-x86-64/pr23486b-x32.d: Likewise.
1343         * testsuite/ld-x86-64/pr23486b.d: Likewise.
1344         * testsuite/ld-x86-64/pr23486c-x32.d: Likewise.
1345         * testsuite/ld-x86-64/pr23486c.d: Likewise.
1346         * testsuite/ld-x86-64/pr23486d-x32.d: Likewise.
1347         * testsuite/ld-x86-64/pr23486d.d: Likewise.
1348         * testsuite/ld-x86-64/pr24322a-x32.d: Likewise.
1349         * testsuite/ld-x86-64/pr24322a.d: Likewise.
1350         * testsuite/ld-x86-64/pr24322b-x32.d: Likewise.
1351         * testsuite/ld-x86-64/pr24322b.d: Likewise.
1352         * testsuite/ld-x86-64/pr24458a-x32.d: Likewise.
1353         * testsuite/ld-x86-64/pr24458a.d: Likewise.
1354         * testsuite/ld-x86-64/pr24458b-x32.d: Likewise.
1355         * testsuite/ld-x86-64/pr24458b.d: Likewise.
1356         * testsuite/ld-x86-64/pr24458c-x32.d: Likewise.
1357         * testsuite/ld-x86-64/pr24458c.d: Likewise.
1358         * testsuite/ld-x86-64/property-1.r: Likewise.
1359         * testsuite/ld-x86-64/property-1a.r: Likewise.
1360         * testsuite/ld-x86-64/property-2.r: Likewise.
1361         * testsuite/ld-x86-64/property-2a.r: Likewise.
1362         * testsuite/ld-x86-64/property-3.r: Likewise.
1363         * testsuite/ld-x86-64/property-3a.r: Likewise.
1364         * testsuite/ld-x86-64/property-4.r: Likewise.
1365         * testsuite/ld-x86-64/property-4a.r: Likewise.
1366         * testsuite/ld-x86-64/property-5.r: Likewise.
1367         * testsuite/ld-x86-64/property-5a.r: Likewise.
1368         * testsuite/ld-x86-64/property-6.r: Likewise.
1369         * testsuite/ld-x86-64/property-7.r: Likewise.
1370         * testsuite/ld-x86-64/property-7a.r: Likewise.
1371         * testsuite/ld-x86-64/property-x86-3-x32.d: Likewise.
1372         * testsuite/ld-x86-64/property-x86-3.d: Likewise.
1373         * testsuite/ld-x86-64/property-x86-4a-x32.d: Likewise.
1374         * testsuite/ld-x86-64/property-x86-4a.d: Likewise.
1375         * testsuite/ld-x86-64/property-x86-5-x32.d: Likewise.
1376         * testsuite/ld-x86-64/property-x86-5.d: Likewise.
1377         * testsuite/ld-x86-64/property-x86-cet1-x32.d: Likewise.
1378         * testsuite/ld-x86-64/property-x86-cet1.d: Likewise.
1379         * testsuite/ld-x86-64/property-x86-cet2a-x32.d: Likewise.
1380         * testsuite/ld-x86-64/property-x86-cet2a.d: Likewise.
1381         * testsuite/ld-x86-64/property-x86-cet5a-x32.d: Likewise.
1382         * testsuite/ld-x86-64/property-x86-cet5a.d: Likewise.
1383         * testsuite/ld-x86-64/property-x86-cet5b-x32.d: Likewise.
1384         * testsuite/ld-x86-64/property-x86-cet5b.d: Likewise.
1385         * testsuite/ld-x86-64/property-x86-ibt1a-x32.d: Likewise.
1386         * testsuite/ld-x86-64/property-x86-ibt1a.d: Likewise.
1387         * testsuite/ld-x86-64/property-x86-ibt1b-x32.d: Likewise.
1388         * testsuite/ld-x86-64/property-x86-ibt1b.d: Likewise.
1389         * testsuite/ld-x86-64/property-x86-ibt2-x32.d: Likewise.
1390         * testsuite/ld-x86-64/property-x86-ibt2.d: Likewise.
1391         * testsuite/ld-x86-64/property-x86-ibt3a-x32.d: Likewise.
1392         * testsuite/ld-x86-64/property-x86-ibt3a.d: Likewise.
1393         * testsuite/ld-x86-64/property-x86-ibt3b-x32.d: Likewise.
1394         * testsuite/ld-x86-64/property-x86-ibt3b.d: Likewise.
1395         * testsuite/ld-x86-64/property-x86-ibt4-x32.d: Likewise.
1396         * testsuite/ld-x86-64/property-x86-ibt4.d: Likewise.
1397         * testsuite/ld-x86-64/property-x86-ibt5-x32.d: Likewise.
1398         * testsuite/ld-x86-64/property-x86-ibt5.d: Likewise.
1399         * testsuite/ld-x86-64/property-x86-shstk1a-x32.d: Likewise.
1400         * testsuite/ld-x86-64/property-x86-shstk1a.d: Likewise.
1401         * testsuite/ld-x86-64/property-x86-shstk1b-x32.d: Likewise.
1402         * testsuite/ld-x86-64/property-x86-shstk1b.d: Likewise.
1403         * testsuite/ld-x86-64/property-x86-shstk2-x32.d: Likewise.
1404         * testsuite/ld-x86-64/property-x86-shstk2.d: Likewise.
1405         * testsuite/ld-x86-64/property-x86-shstk3a-x32.d: Likewise.
1406         * testsuite/ld-x86-64/property-x86-shstk3a.d: Likewise.
1407         * testsuite/ld-x86-64/property-x86-shstk3b-x32.d: Likewise.
1408         * testsuite/ld-x86-64/property-x86-shstk3b.d: Likewise.
1409         * testsuite/ld-x86-64/property-x86-shstk4-x32.d: Likewise.
1410         * testsuite/ld-x86-64/property-x86-shstk4.d: Likewise.
1411         * testsuite/ld-x86-64/property-x86-shstk5-x32.d: Likewise.
1412         * testsuite/ld-x86-64/property-x86-shstk5.d: Likewise.
1414 2019-08-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
1416         * scripttempl/elf64bpf.sc: Adapted from elf.sc.
1417         * emulparams/elf64bpf.sh (SCRIPT_NAME): Use elf64bpf.
1418         (EMBEDDED): Define.
1419         * testsuite/ld-bpf/call-1.d: Do not expect a warning regarding an
1420         undefined entry symbol.
1421         * testsuite/ld-bpf/jump-1.d: Likewise.
1422         * testsuite/ld-undefined/undefined.exp: Do not pass '-e entry' to
1423         ld in BPF targets, and do not expect line number information.
1424         * testsuite/ld-srec/srec.exp (run_srec_test): xfail s-record tests
1425         in BPF targets.
1427 2019-08-06  Alan Modra  <amodra@gmail.com>
1429         PR 24873
1430         * ldlang.c (find_replacements_insert_point): Return "before" flag.
1431         (find_next_input_statement): New function.
1432         (lang_process): When placing recompiled LTO objects before a
1433         claimed archive, place them immediately before in the statement
1434         list.
1436 2019-08-06  Alan Modra  <amodra@gmail.com>
1438         PR 24873
1439         * ldlang.c (plugin_undefs): New static var.
1440         (open_input_bfds <lang_group_statement_enum>): Loop on
1441         plugin_undefs and hitting plugin_insert point.
1442         (lang_process <lto_plugin_active>): Set plugin_undefs.
1444 2019-08-02  Alan Modra  <amodra@gmail.com>
1446         * testsuite/ld-powerpc/tlsie.s: Correct medium model ELF sequence.
1448 2019-08-01  Alan Modra  <amodra@gmail.com>
1450         PR 24806
1451         * ldlang.c (process_insert_statements): Add start of list
1452         parameter.  Use rather than lang_os_list.head.  Process insert
1453         statements inside group statements with a recursive call.
1454         (lang_process): Adjust process_insert_statements call.
1455         * lexsup.c (parse_args): Warn when adding missing --end-group.
1457 2019-08-01  Alan Modra  <amodra@gmail.com>
1459         * ldlang.h (lang_os_list): Rename from lang_output_section_statement.
1460         * ldlang.c: Likewise throughout file.
1461         * emultempl/alphaelf.em: Likewise.
1462         * emultempl/elf32.em: Likewise.
1463         * emultempl/mmo.em: Likewise.
1464         * emultempl/pe.em: Likewise.
1465         * emultempl/pep.em: Likewise.
1466         * emultempl/ppc32elf.em: Likewise.
1467         * emultempl/spuelf.em: Likewise.
1469 2019-07-26  Alan Modra  <amodra@gmail.com>
1471         * testsuite/ld-plugin/lto-3r.d: Accept D for powerpc64 descriptors.
1472         * testsuite/ld-plugin/lto-5r.d: Likewise.
1474 2019-07-24  H.J. Lu  <hongjiu.lu@intel.com>
1476         * testsuite/ld-plugin/lto-3r.d: Restored.  Check foo instead
1477         of __gnu_lto_v.*.
1478         * testsuite/ld-plugin/lto-5r.d: Likewise.
1479         * testsuite/ld-plugin/lto.exp: Run lto-3r and lto-5r tests.
1481 2019-07-24  Claudiu Zissulescu  <claziss@synopsys.com>
1483         * ld-arc/relax-local-pic.d: New test.
1484         * ld-arc/relax-local-pic.s: New file.
1486 2019-07-22  Martin Liska  <mliska@suse.cz>
1488         * testsuite/ld-plugin/lto-3r.d: Remove.
1489         * testsuite/ld-plugin/lto-5r.d: Remove.
1490         * testsuite/ld-plugin/lto.exp: Do not run lto-3r and lto-5r
1491         tests.
1493 2019-07-23  Alan Modra  <amodra@gmail.com>
1495         * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Condition
1496         SHF_GNU_MBIND on osabi.  Set output elf_gnu_osabi_mbind.
1498 2019-07-23  Alan Modra  <amodra@gmail.com>
1500         * testsuite/ld-elf/size-1.d,
1501         * testsuite/ld-elf/size-1.s,
1502         * testsuite/ld-elf/size-1.t: New test.
1503         * testsuite/ld-elf/size-2.d,
1504         * testsuite/ld-elf/size-2.s,
1505         * testsuite/ld-elf/size-2.t: New test.
1506         * testsuite/ld-scripts/size-1.d,
1507         * testsuite/ld-scripts/size-1.s,
1508         * testsuite/ld-scripts/size-1.t,
1509         * testsuite/ld-scripts/size-2.s,
1510         * testsuite/ld-scripts/size-2.d,
1511         * testsuite/ld-scripts/size-2.t,
1512         * testsuite/ld-scripts/size.exp: Delete.
1514 2019-07-22  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
1516         * ld/testsuite/ld-arm/cmse_main_sec_debug.d: Modify regexps to
1517         allow for output from a arm-none-linux-gnueabihf target.
1519 2019-07-20  Alan Modra  <amodra@gmail.com>
1521         PR 24827
1522         * ldlex.l (comment): Check for 0 return from YY_INPUT, not EOF.
1524 2019-07-19  Alan Modra  <amodra@gmail.com>
1526         * testsuite/ld-powerpc/tlsgd.d,
1527         * testsuite/ld-powerpc/tlsgd.s,
1528         * testsuite/ld-powerpc/tlsie.d,
1529         * testsuite/ld-powerpc/tlsie.s,
1530         * testsuite/ld-powerpc/tlsld.d,
1531         * testsuite/ld-powerpc/tlsld.s: New tests.
1532         * testsuite/ld-powerpc/powerpc.exp: Run them.
1534 2019-07-19  Alan Modra  <amodra@gmail.com>
1536         * testsuite/ld-powerpc/tlsldopt.d: Rename from tlsld.d.
1537         * testsuite/ld-powerpc/tlsldopt.s: Rename from tlsld.s.
1538         * testsuite/ld-powerpc/tlsldopt32.d: Rename from tlsld32.d.
1539         * testsuite/ld-powerpc/tlsldopt32.s: Rename from tlsld32.s.
1540         * testsuite/ld-powerpc/powerpc.exp: Update.
1542 2019-07-19  Alan Modra  <amodra@gmail.com>
1544         PR 24819
1545         * testsuite/ld-elf/pr24819.d: xfail for genelf targets.
1547 2019-07-18  H.J. Lu  <hongjiu.lu@intel.com>
1549         PR ld/24819
1550         * emultempl/elf32.em (elf_orphan_compatible): Return FALSE for
1551         member of output section group when doing a relocatable link.
1552         * testsuite/ld-elf/pr24819.d: New file.
1553         * testsuite/ld-elf/pr24819.s: Likewise.
1555 2019-07-13  Alan Modra  <amodra@gmail.com>
1557         * testsuite/ld-powerpc/tlsso.r: Update.
1558         * testsuite/ld-powerpc/tlsso32.g: Update.
1559         * testsuite/ld-powerpc/tlsso32.r: Update.
1560         * testsuite/ld-powerpc/tlstocso.r: Update.
1561         * testsuite/ld-cris/tls-dso-dtpoffd2.d: Update.
1562         * testsuite/ld-cris/tls-dso-dtpoffd4.d: Update.
1563         * testsuite/ld-cris/tls-dso-tpoffgotcomm1.d: Update.
1564         * testsuite/ld-cris/tls-gd-1.d: Update.
1565         * testsuite/ld-cris/tls-gd-1h.d: Update.
1566         * testsuite/ld-cris/tls-gd-2.d: Update.
1567         * testsuite/ld-cris/tls-gd-2h.d: Update.
1568         * testsuite/ld-cris/tls-ie-10.d: Update.
1569         * testsuite/ld-cris/tls-ie-11.d: Update.
1570         * testsuite/ld-cris/tls-ie-8.d: Update.
1571         * testsuite/ld-cris/tls-ie-9.d: Update.
1572         * testsuite/ld-cris/tls-js1.d: Update.
1573         * testsuite/ld-cris/tls-ld-4.d: Update.
1574         * testsuite/ld-cris/tls-ld-5.d: Update.
1575         * testsuite/ld-cris/tls-ld-6.d: Update.
1576         * testsuite/ld-cris/tls-ld-7.d: Update.
1577         * testsuite/ld-cris/tls-ldgd-14.d: Update.
1578         * testsuite/ld-cris/tls-ldgd-15.d: Update.
1579         * testsuite/ld-cris/tls-ldgdx-14.d: Update.
1580         * testsuite/ld-cris/tls-ldgdx-15.d: Update.
1581         * testsuite/ld-cris/tls-local-54.d: Update.
1582         * testsuite/ld-cris/tls-local-60.d: Update.
1583         * testsuite/ld-cris/tls-local-61.d: Update.
1584         * testsuite/ld-cris/tls-local-63.d: Update.
1585         * testsuite/ld-cris/tls-local-64.d: Update.
1586         * testsuite/ld-cris/tls-ok-30.d: Update.
1587         * testsuite/ld-cris/tls-ok-32.d: Update.
1588         * testsuite/ld-cris/tls-ok-34.d: Update.
1589         * testsuite/ld-mips-elf/tls-multi-got-1.got: Update.
1590         * testsuite/ld-mips-elf/tls-multi-got-1.r: Update.
1591         * testsuite/ld-mips-elf/tlsdyn-pie-o32.d: Update.
1592         * testsuite/ld-mips-elf/tlsdyn-pie-o32.got: Update.
1593         * testsuite/ld-mips-elf/tlslib-o32-hidden.got: Update.
1594         * testsuite/ld-mips-elf/tlslib-o32-ver.got: Update.
1595         * testsuite/ld-mips-elf/tlslib-o32.got: Update.
1596         * testsuite/ld-s390/tlspic.rd: Update.
1597         * testsuite/ld-s390/tlspic_64.rd: Update.
1598         * testsuite/ld-sparc/tlssunnopic32.rd: Update.
1599         * testsuite/ld-sparc/tlssunnopic64.rd: Update.
1600         * testsuite/ld-sparc/tlssunpic32.rd: Update.
1601         * testsuite/ld-sparc/tlssunpic64.rd: Update.
1603 2019-07-13  Alan Modra  <amodra@gmail.com>
1605         PR 24786
1606         * ldlang.h (enum section_type): Add first_overlay_section.
1607         * ldlang.c (lang_add_section): Adjust switch statement.
1608         (map_input_to_output_sections): Likewise.
1609         (lang_size_sections_1): Always set last_os for first overlay section.
1610         (lang_leave_overlay): Set sectype to first_overlay_section.
1612 2019-07-08  Alan Modra  <amodra@gmail.com>
1614         * testsuite/ld-powerpc/callstub-1.d: Pass -melf64ppc to ld.
1615         * testsuite/ld-powerpc/callstub-2.d: Likewise.
1617 2019-07-04  Jan Beulich  <jbeulich@suse.com>
1619         * testsuite/ld-elf/group9.s: Correct argument of .type.
1621 2019-07-02  Nick Clifton  <nickc@redhat.com>
1623         PR 24753
1624         * emultempl/aarch64elf.em (_aarch64_add_stub_section): Include the
1625         LINKER_CREATED section flag when creating the stub section.
1627 2019-07-02  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
1629         * testsuite/ld-arm/arm-elf.exp: Add tests.
1630         * testsuite/ld-arm/cmse_main.s: New test.
1631         * testsuite/ld-arm/cmse_main_sec_debug.d: Likewise.
1632         * testsuite/ld-arm/cmse_sec_debug.s: Likewise.
1634 2019-07-01  Nick Clifton  <nickc@redhat.com>
1636         PR 23839
1637         * testsuite/ld-arm/unwind-4.d: Adjust for corrected calculation of
1638         exidx relocs.
1640 2019-06-28  Alan Modra  <amodra@gmail.com>
1642         * testsuite/ld-powerpc/callstub-1.d,
1643         * testsuite/ld-powerpc/callstub-1.s: New test.
1644         * testsuite/ld-powerpc/callstub-2.d,
1645         * testsuite/ld-powerpc/callstub-2.s: New test.
1646         * testsuite/ld-powerpc/powerpc.exp: Run them.
1648 2019-06-25  Jan Beulich  <jbeulich@suse.com>
1650         * plugin.c (get_lto_kind, get_lto_resolution,
1651         get_lto_visibility): Rename "index" to "idx".
1653 2019-06-24  H.J. Lu  <hongjiu.lu@intel.com>
1655         PR ld/24721
1656         * testsuite/ld-x86-64/x86-64.exp: Run PR ld/24721 tests.
1657         * testsuite/ld-x86-64/pr24721-x32.d: New file.
1658         * testsuite/ld-x86-64/pr24721.d: Likewise.
1659         * testsuite/ld-x86-64/pr24721.map: Likewise.
1660         * testsuite/ld-x86-64/pr24721a.s: Likewise.
1661         * testsuite/ld-x86-64/pr24721b.s: Likewise.
1663 2019-06-23  Alan Modra  <amodra@gmail.com>
1665         PR 24704
1666         * testsuite/ld-powerpc/elfv2exe.d: Update.
1667         * testsuite/ld-powerpc/elfv2so.d: Update.
1669 2019-06-14  Szabolcs Nagy  <szabolcs.nagy@arm.com>
1671         * testsuite/ld-aarch64/aarch64-elf.exp: Add emit-relocs-22 and -23.
1672         * testsuite/ld-aarch64/emit-relocs-22.d: New test.
1673         * testsuite/ld-aarch64/emit-relocs-22.s: New test.
1674         * testsuite/ld-aarch64/emit-relocs-23.d: New test.
1675         * testsuite/ld-aarch64/emit-relocs-23.s: New test.
1677 2019-06-14  Alan Modra  <amodra@gmail.com>
1679         * Makefile.in: Regenerate.
1680         * configure: Regenerate.
1682 2019-06-14  Alan Modra  <amodra@gmail.com>
1684         PR 24662
1685         * testsuite/ld-alpha/tlsbin.rd: Update.
1686         * testsuite/ld-alpha/tlsbinr.rd: Update.
1687         * testsuite/ld-alpha/tlspic.rd: Update.
1689 2019-06-07  Maciej W. Rozycki  <macro@wdc.com>
1691         * ld.texi (Options): Also document `-rpath' option restrictions
1692         in the description of the option itself.
1694 2019-06-06  Sudakshina Das  <sudi.das@arm.com>
1696         * testsuite/ld-aarch64/aarch64-elf.exp: Add new tests.
1697         * testsuite/ld-aarch64/property-bti-pac4-a.d: New test.
1698         * testsuite/ld-aarch64/property-bti-pac4-b.d: New test.
1699         * testsuite/ld-aarch64/property-bti-pac4.s: New test.
1701 2019-06-06  Sudakshina Das  <sudi.das@arm.com>
1703         * NEWS: Update options names.
1704         * emultempl/aarch64elf.em (OPTION_FORCE_BTI, OPTION_PAC_PLT): Remove.
1705         (PARSE_AND_LIST_LONGOPTS): Remove force-bti and pac-plt.
1706         (PARSE_AND_LIST_OPTIONS): Update to -z.
1707         (PARSE_AND_LIST_ARGS_CASE_Z_AARCH64): New.
1708         (PARSE_AND_LIST_ARGS_CASE_Z): Add PARSE_AND_LIST_ARGS_CASE_Z_AARCH64.
1709         (PARSE_AND_LIST_ARGS_CASES): Move cases for these options.
1710         * testsuite/ld-aarch64/bti-pac-plt-1.d: Update option.
1711         * testsuite/ld-aarch64/bti-pac-plt-2.d: Likewise.
1712         * testsuite/ld-aarch64/bti-plt-1.d: Likewise.
1713         * testsuite/ld-aarch64/bti-plt-2.d: Likewise.
1714         * testsuite/ld-aarch64/bti-plt-3.d: Likewise.
1715         * testsuite/ld-aarch64/bti-plt-4.d: Likewise.
1716         * testsuite/ld-aarch64/bti-plt-6.d: Likewise.
1717         * testsuite/ld-aarch64/bti-plt-7.d: Likewise.
1718         * testsuite/ld-aarch64/bti-warn.d: Likewise.
1719         * testsuite/ld-aarch64/pac-plt-1.d: Likewise.
1720         * testsuite/ld-aarch64/pac-plt-2.d: Likewise.
1722 2019-05-30  Nick Clifton  <nickc@redhat.com>
1724         PR 24627
1725         * testsuite/ld-elf/ver_def.vd: Update expected output.
1727 2019-05-30  Alan Modra  <amodra@gmail.com>
1729         PR 24596
1730         * emulparams/m9s12zelf.sh (TEMPLATE_NAME): Set to generic.
1731         (EXTRA_EM_FILE): Define to genelf.
1732         * testsuite/lib/ld-lib.exp (uses_genelf): Add s12z.
1734 2019-05-30  Alan Modra  <amodra@gmail.com>
1736         * testsuite/lib/ld-lib.exp (run_ld_link_tests): Support procedure
1737         calls in optional "xfail" args.
1738         (run_ld_link_exec_tests): Likewise.
1739         (is_generic): New.
1740         (uses_genelf): Rename from is_generic_elf.  Delete bogus semicolons.
1741         * testsuite/ld-scripts/align.exp: Rename is_generic_elf call.
1742         * testsuite/ld-elf/elf.exp: Use is_generic and uses_genelf.  Delete
1743         xfail_implib var.
1744         * testsuite/ld-elf/sec64k.exp: Use is_generic.
1745         * testsuite/ld-elf/shared.exp: Likewise.
1746         * testsuite/ld-discard/extern.d: Use is_generic in xfail.
1747         * testsuite/ld-discard/start.d: Likewise.
1748         * testsuite/ld-discard/static.d: Likewise.
1749         * testsuite/ld-elf/attributes.d: Likewise.
1750         * testsuite/ld-elf/group1.d: Likewise.
1751         * testsuite/ld-elf/group3b.d: Likewise.
1752         * testsuite/ld-elf/group8a.d: Likewise.
1753         * testsuite/ld-elf/group8b.d: Likewise.
1754         * testsuite/ld-elf/group9a.d: Likewise.
1755         * testsuite/ld-elf/group9b.d: Likewise.
1756         * testsuite/ld-elf/linkonce2.d: Likewise.
1757         * testsuite/ld-elf/merge2.d: Likewise.
1758         * testsuite/ld-elf/merge3.d: Likewise.
1759         * testsuite/ld-elf/pr12851.d: Likewise.
1760         * testsuite/ld-elf/pr12975.d: Likewise.
1761         * testsuite/ld-elf/pr13177.d: Likewise.
1762         * testsuite/ld-elf/pr13195.d: Likewise.
1763         * testsuite/ld-elf/pr17550c.d: Likewise.
1764         * testsuite/ld-elf/pr17550d.d: Likewise.
1765         * testsuite/ld-elf/pr17615.d: Likewise.
1766         * testsuite/ld-elf/pr21562a.d: Likewise.
1767         * testsuite/ld-elf/pr21562b.d: Likewise.
1768         * testsuite/ld-elf/pr21562c.d: Likewise.
1769         * testsuite/ld-elf/pr21562d.d: Likewise.
1770         * testsuite/ld-elf/pr21562i.d: Likewise.
1771         * testsuite/ld-elf/pr21562j.d: Likewise.
1772         * testsuite/ld-elf/pr21562k.d: Likewise.
1773         * testsuite/ld-elf/pr21562l.d: Likewise.
1774         * testsuite/ld-elf/pr21562m.d: Likewise.
1775         * testsuite/ld-elf/pr21562n.d: Likewise.
1776         * testsuite/ld-elf/pr22677.d: Likewise.
1777         * testsuite/ld-elf/pr22836-1a.d: Likewise.
1778         * testsuite/ld-elf/pr22836-1b.d: Likewise.
1779         * testsuite/ld-elf/warn3.d: Likewise.
1780         * testsuite/ld-elf/warn1.d: Likewise and xfail sparc solaris
1781         targets rather than notarget.
1782         * testsuite/ld-elf/compressed1d.d: Use uses_genelf in xfail.
1783         * testsuite/ld-elf/orphan-10.d: Likewise.
1784         * testsuite/ld-elf/orphan-9.d: Likewise.
1785         * testsuite/ld-elf/orphan-region.d: Likewise.
1786         * testsuite/ld-elf/orphan.d: Likewise.
1787         * testsuite/ld-elf/orphan3.d: Likewise.
1788         * testsuite/ld-elf/pr20528a.d: Likewise.
1789         * testsuite/ld-elf/pr20528b.d: Likewise.
1790         * testsuite/ld-elf/pr23658-1a.d: Likewise.
1791         * testsuite/ld-elf/pr23658-1b.d: Likewise.
1792         * testsuite/ld-elf/pr349.d: Likewise.
1793         * testsuite/ld-elf/warn2.d: Likewise and xfail sparc solaris
1794         targets rather than notarget.
1795         * testsuite/ld-elf/merge.d: Correct ms1-*-* to mt-*-*.
1797 2019-05-28  Faraz Shahbazker  <fshahbazker@wavecomp.com>
1799         * testsuite/ld-mips-elf/undefweak-overflow.s: Remove test case
1800         for pcrel_hi/pcrel_lo.
1801         * testsuite/ld-mips-elf/undefweak-overflow.d: Update to match.
1802         * testsuite/ld-mips-elf/reloc-pcrel-r6.s: New test source.
1803         * testsuite/ld-mips-elf/reloc-pcrel-r6.d: New test linker script.
1804         * testsuite/ld-mips-elf/reloc-pcrel-r6.ld: New test.
1805         * testsuite/ld-mips-elf/mips-elf.exp: Run the new test.
1807 2019-05-28  Alan Modra  <amodra@gmail.com>
1809         PR 24596
1810         * emultempl/pe.em (gld_${EMULATION_NAME}_after_open): Check that
1811         the output is coff before accessing coff tdata.
1812         * emultempl/pep.em (gld_${EMULATION_NAME}_after_open): Likewise.
1814 2019-05-28  Szabolcs Nagy  <szabolcs.nagy@arm.com>
1816         * testsuite/ld-aarch64/variant_pcs-now.d: Use --hash-style=sysv.
1817         * testsuite/ld-aarch64/variant_pcs-shared.d: Likewise.
1819 2019-05-27  Alan Modra  <amodra@gmail.com>
1821         PR 24596
1822         * emultempl/genelf.em (gld${EMULATION_NAME}_after_open): Set
1823         BFS_KEEP on group signature symbol.
1825 2019-04-24  Szabolcs Nagy  <szabolcs.nagy@arm.com>
1827         * testsuite/ld-aarch64/aarch64-elf.exp: Add new tests.
1828         * testsuite/ld-aarch64/variant_pcs-1.s: New asm for tests.
1829         * testsuite/ld-aarch64/variant_pcs-2.s: New asm for tests.
1830         * testsuite/ld-aarch64/variant_pcs-now.d: New test.
1831         * testsuite/ld-aarch64/variant_pcs-r.d: New test.
1832         * testsuite/ld-aarch64/variant_pcs-shared.d: New test.
1833         * testsuite/ld-aarch64/variant_pcs.ld: New linker script for tests.
1835 2019-05-24  Alan Modra  <amodra@gmail.com>
1837         * po/BLD-POTFILES.in: Regenerate.
1839 2019-05-24  Alan Modra  <amodra@gmail.com>
1841         * testsuite/ld-powerpc/notoc2.d,
1842         * testsuite/ld-powerpc/notoc2.s: New test.
1843         * testsuite/ld-powerpc/powerpc.exp: Run it.
1845 2019-05-24  Alan Modra  <amodra@gmail.com>
1847         * testsuite/ld-powerpc/pcrelopt.s,
1848         * testsuite/ld-powerpc/pcrelopt.d,
1849         * testsuite/ld-powerpc/pcrelopt.sec: New test.
1850         * testsuite/ld-powerpc/powerpc.exp: Run it.
1852 2019-05-23  Jose E. Marchesi  <jose.marchesi@oracle.com>
1854         * Makefile.am (ALL_64_EMULATION_SOURCES): Add eelf64bpf.c.
1855         * Makefile.in (prefix): Regenerate.
1856         * configure.tgt (targ_extra_ofiles): Add case for bpf-*-* targets.
1857         * emulparams/elf64bpf.sh: New file.
1858         * testsuite/lib/ld-lib.exp (check_gc_sections_available): Add
1859         bpf-*-* to the list of targets not supporting gc-sections.
1860         * testsuite/ld-bpf/bar.s: New file.
1861         * testsuite/ld-bpf/jump-1.d: Likewise.
1862         * testsuite/ld-bpf/foo.s: Likewise.
1863         * testsuite/ld-bpf/call-1.d: Likewise.
1864         * testsuite/ld-bpf/bpf.exp: Likewise.
1865         * testsuite/ld-bpf/baz.s: Likewise.
1867 2019-05-23  Alan Modra  <amodra@gmail.com>
1869         PR 24576
1870         * ldfile.c (enum script_open_style): New.
1871         (struct script_name_list): New.
1872         (ldfile_open_command_file_1): Take a script_open_style param
1873         rather than booleans.  Adjust callers.  Only fail when -T or
1874         default -T script is invoked twice.
1875         (ldfile_try_open_bfd): Revert last change.
1877 2019-05-22  Julius Werner  <jwerner@chromium.org>
1878             Nick Clifton  <nickc@redhat.com>
1880         PR 24576
1881         * ld/ldfile.c: (ldfile_open_command_file_1): Add new parameter -
1882         is_script.  If true check that the file has not already been
1883         parsed as a linker script.
1884         (ldfile_open_script_file): New function.
1885         (ldfile_try_open_bfd): Use the new function in place of
1886         ldfile_open_command_line.
1887         * ldmain.c (main): Likewise.
1888         * lexsup.c (parse_args): Use the new function for opening linker
1889         scripts with the -T option.
1890         * ldfile.h (ldfile_open_script_file): Add prototype.
1892 2019-05-21  Faraz Shahbazker  <fshahbazker@wavecomp.com>
1894         * testsuite/ld-mips-elf/pic-reloc-5.s: Add tests for
1895         %tprel_hi and %tprel_lo relocations.
1896         * testsuite/ld-mips-elf/pic-reloc-6.s: Likewise.
1897         * testsuite/ld-mips-elf/pic-reloc-5.d: Update accordingly.
1898         * testsuite/ld-mips-elf/pic-reloc-6.d: Likewise.
1899         * testsuite/ld-mips-elf/pic-reloc-tls.ld: New test linker
1900         script file.
1902 2019-05-21  Faraz Shahbazker  <fshahbazker@wavecomp.com>
1904         * testsuite/ld-mips-elf/pic-reloc-5.d: New test.
1905         * testsuite/ld-mips-elf/pic-reloc-6.d: New test.
1906         * testsuite/ld-mips-elf/pic-reloc-7.d: New test.
1907         * testsuite/ld-mips-elf/pic-reloc-5.s: New test source.
1908         * testsuite/ld-mips-elf/pic-reloc-6.s: New test source.
1909         * testsuite/ld-mips-elf/pic-reloc-7.s: New test source.
1910         * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.
1912 2019-05-21  Matthew Fortune  <matthew.fortune@mips.com>
1913             Faraz Shahbazker  <fshahbazker@wavecomp.com>
1915         * emultempl/mipself.em (compact_branches): New static variable.
1916         (mips_create_output_section_statements): Call
1917         _bfd_mips_elf_compact_branches.
1918         (PARSE_AND_LIST_PROLOGUE): Add OPTION_COMPACT_BRANCHES and
1919         OPTION_NO_COMPACT_BRANCHES.
1920         (PARSE_AND_LIST_LONGOPTS): Add compact-branches,
1921         no-compact-branches.
1922         (PARSE_AND_LIST_OPTIONS): Add --compact-branches,
1923         --no-compact-branches.
1924         (PARSE_AND_LIST_ARGS_CASES): Handle the above.
1925         * ld.texinfo: Document --compact-branches, --no-compact-branches.
1926         * testsuite/ld-mips-elf/pic-and-nonpic-1-r6.dd: New test.
1927         * testsuite/ld-mips-elf/pic-and-nonpic-1-r6.nd: New test.
1928         * testsuite/ld-mips-elf/pic-and-nonpic-3a-r6.dd: New test.
1929         * testsuite/ld-mips-elf/pic-and-nonpic-3a-r6.gd: New test.
1930         * testsuite/ld-mips-elf/pic-and-nonpic-1a-r6.s: New test source.
1931         * testsuite/ld-mips-elf/pic-and-nonpic-3a-r6.s: New test source.
1932         * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.
1934 2019-05-21  Andre Vieira  <andre.simoesdiasvieira@arm.com>
1936         * testsuite/ld-arm/arm-elf.exp: Add tests
1937         * testsuite/ld-arm/bfs-0.s: New test.
1938         * testsuite/ld-arm/bfs-1.s: New test.
1939         * testsuite/ld-arm/branch-futures.d: New test.
1941 2019-05-21  Tamar Christina  <tamar.christina@arm.com>
1943         PR ld/24373
1944         * emultempl/aarch64elf.em (PARSE_AND_LIST_LONGOPTS): Add optional args
1945         to flags.
1946         * NEWS: Add changes to flag.
1947         (PARSE_AND_LIST_OPTIONS): Update help descriptions.
1948         (PARSE_AND_LIST_ARGS_CASES): Add new options to parser.
1949         * testsuite/ld-aarch64/aarch64-elf.exp: Add new run_dump_tests.
1950         * testsuite/ld-aarch64/erratum843419-adr.d: New test.
1951         * testsuite/ld-aarch64/erratum843419-adrp.d: New test.
1952         * testsuite/ld-aarch64/erratum843419-far-adr.d: New test.
1953         * testsuite/ld-aarch64/erratum843419-far-full.d: New test.
1954         * testsuite/ld-aarch64/erratum843419-far.s: New test.
1955         * testsuite/ld-aarch64/erratum843419-full.d: New test.
1956         * testsuite/ld-aarch64/erratum843419-near.s: New test.
1957         * testsuite/ld-aarch64/erratum843419-no-args.d: New test.
1959 2019-05-21  Senthil Kumar Selvaraj  <senthilkumar.selvaraj@microchip.com>
1961         PR ld/24571
1962         * ld/testsuite/ld-avr/relax-insn-at-range-boundary.d: New test.
1963         * ld/testsuite/ld-avr/relax-insn-at-range-boundary.s: New test.
1965 2019-05-21  Senthil Kumar Selvaraj  <senthilkumar.selvaraj@microchip.com>
1967         PR ld/24564
1968         * testsuite/ld-avr/wraparound-range-boundary.d: New test.
1969         * testsuite/ld-avr/wraparound-range-boundary.s: New test.
1971 2019-05-20  Faraz Shahbazker  <fshahbazker@wavecomp.com>
1973         PR 14798
1974         * testsuite/ld-mips-elf/reloc-6a.s: Specify .text section for
1975         global code symbols.
1976         * testsuite/ld-mips-elf/reloc-6b.s: Likewise.
1978 2019-05-17  Alan Modra  <amodra@gmail.com>
1980         PR 24567
1981         * plugin.c (plugin_notice): Do not let a common symbol override
1982         a non-common definition in IR.
1984 2019-05-09  Dimitar Dimitrov  <dimitar@dinux.eu>
1986         * scripttempl/pru.sc (__init_array_begin, __init_array_begin):
1987         Rename.
1989 2019-05-08  Pekka Seppänen  <pexu@sourceware.mail.kapsi.fi>
1991         PR 24536
1992         * ldbuildid.c (generate_build_id): Cast return value from
1993         GetProcAddress in order to avoid a compile time warning.
1995 2019-05-06  Alan Modra  <amodra@gmail.com>
1997         * testsuite/ld-undefined/weak-undef.exp: Don't xfail pj.
1999 2019-05-04  Alan Modra  <amodra@gmail.com>
2001         * testsuite/ld-scripts/fill.d: Don't xfail m32c
2002         * testsuite/ld-scripts/fill16.d: Likewise.
2004 2019-05-04  Alan Modra  <amodra@gmail.com>
2006         PR 24511
2007         * testsuite/ld-elf/pr14156a.d: Allow for .init/.fini being a
2008         data section on hppa64.
2009         * testsuite/ld-elf/pr14156b.d: Likewise.
2010         * testsuite/ld-scripts/pr18963.t: Map standard sections to set
2011         output section flags.
2012         * testsuite/ld-scripts/sane1.t: Likewise.
2013         * testsuite/ld-elf/init-fini-arrays.s: Reference __init_array_start
2014         and __fini_array_start.  Define __start et al.
2015         * testsuite/ld-elf/pr24511.d: New test.
2017 2019-04-30  Alan Modra  <amodra@gmail.com>
2019         * testsuite/ld-powerpc/elfv2exe.d: Update.
2020         * testsuite/ld-powerpc/elfv2so.d: Update.
2021         * testsuite/ld-powerpc/tocopt.d: Update.
2022         * testsuite/ld-powerpc/tocopt.s: Update.
2023         * testsuite/ld-powerpc/tocopt5.d: Update.
2024         * testsuite/ld-powerpc/tocopt5.s: Update.
2025         * testsuite/ld-powerpc/tocopt7.d: Update.
2026         * testsuite/ld-powerpc/tocopt7.s: Update.
2027         * testsuite/ld-powerpc/tocopt8.d: Update.
2028         * testsuite/ld-powerpc/tocopt8.s: Update.
2030 2019-04-30  Alan Modra  <amodra@gmail.com>
2032         * ld.texi (How GNU properties are merged): Avoid pod2man error.
2033         Correct example.
2035 2019-04-26  H.J. Lu  <hongjiu.lu@intel.com>
2037         PR ld/24486
2038         * testsuite/ld-plugin/lto.exp: Run PR ld/24486 tests.
2039         * testsuite/ld-plugin/pr24486a.c: New file.
2040         * testsuite/ld-plugin/pr24486b.c: Likewise.
2041         * testsuite/ld-plugin/pr24486c.c: Likewise.
2043 2019-04-26  Nick Clifton  <nickc@redhat.com>
2045         * po/ru.po: Updated Russian translation.
2047 2019-04-26  Christopher Yeleighton  <giecrilj@stegny.2a.pl>
2049         * ld.texi: Properly hyphenate the word "specific".
2051 2019-04-25  H.J. Lu  <hongjiu.lu@intel.com>
2053         PR ld/24406
2054         * ld.texi: Remove LTO warning from --wrap.
2055         * plugin.c (get_symbols): Update resolution for wrapper and
2056         wrapped symbols.
2057         * testsuite/ld-plugin/lto.exp: Run ld/24406 tests.
2058         * testsuite/ld-plugin/pr24406-1.c: New file.
2059         * testsuite/ld-plugin/pr24406-2a.c: Likewise.
2060         * testsuite/ld-plugin/pr24406-2b.c: Likewise.
2062 2019-04-25  Sudakshina Das  <sudi.das@arm.com>
2064         * testsuite/ld-aarch64/bti-pac-plt-1.d: Update.
2065         * testsuite/ld-aarch64/bti-pac-plt-2.d: Update.
2066         * testsuite/ld-aarch64/bti-plt-1.d: Update.
2067         * testsuite/ld-aarch64/bti-plt-3.d: Update.
2068         * testsuite/ld-aarch64/bti-plt-5.d: Update.
2069         * testsuite/ld-aarch64/pac-plt-1.d: Update.
2070         * testsuite/ld-aarch64/pac-plt-2.d: Update.
2072 2019-04-24  Sandra Loosemore  <sandra@codesourcery.com>
2074         * testsuite/config/default.exp: Use [check_compiler_available]
2075         instead of [which $CC].
2076         * testsuite/ld-auto-import/auto-import.exp: Likewise.
2077         * testsuite/ld-cygwin/exe-export.exp: Likewise.
2078         * testsuite/ld-elf/audit.exp: Likewise.
2079         * testsuite/ld-elf/compress.exp: Likewise.
2080         * testsuite/ld-elf/dwarf.exp: Likewise.
2081         * testsuite/ld-elf/elf.exp: Likewise.
2082         * testsuite/ld-elf/indirect.exp: Likewise.
2083         * testsuite/ld-elf/linux-x86.exp: Likewise.
2084         * testsuite/ld-elf/shared.exp: Likewise.
2085         * testsuite/ld-elf/tls.exp: Likewise.
2086         * testsuite/ld-elf/wrap.exp: Likewise.
2087         * testsuite/ld-elfcomm/elfcomm.exp: Likewise.
2088         * testsuite/ld-elfvers/vers.exp: Likewise.
2089         * testsuite/ld-elfvsb/elfvsb.exp: Likewise.
2090         * testsuite/ld-elfweak/elfweak.exp: Likewise.
2091         * testsuite/ld-gc/gc.exp: Likewise.
2092         * testsuite/ld-i386/i386.exp: Likewise.
2093         * testsuite/ld-i386/no-plt.exp: Likewise.
2094         * testsuite/ld-i386/tls.exp: Likewise.
2095         * testsuite/ld-ifunc/ifunc.exp: Likewise.
2096         * testsuite/ld-mn10300/mn10300.exp: Likewise.
2097         * testsuite/ld-pe/pe-compile.exp: Likewise.
2098         * testsuite/ld-pe/pe-run.exp: Likewise.
2099         * testsuite/ld-pe/pe-run2.exp: Likewise.
2100         * testsuite/ld-pie/pie.exp: Likewise.
2101         * testsuite/ld-plugin/lto.exp: Likewise.
2102         * testsuite/ld-plugin/plugin.exp: Likewise.
2103         * testsuite/ld-scripts/crossref.exp: Likewise.
2104         * testsuite/ld-sh/sh.exp: Likewise.
2105         * testsuite/ld-shared/shared.exp: Likewise.
2106         * testsuite/ld-size/size.exp: Likewise.
2107         * testsuite/ld-srec/srec.exp: Likewise.
2108         * testsuite/ld-undefined/undefined.exp: Likewise.
2109         * testsuite/ld-unique/unique.exp: Likewise.
2110         * testsuite/ld-x86-64/mpx.exp: Likewise.
2111         * testsuite/ld-x86-64/no-plt.exp: Likewise.
2112         * testsuite/ld-x86-64/tls.exp: Likewise.
2113         * testsuite/ld-x86-64/x86-64.exp: Likewise.
2114         * testsuite/lib/ld-lib.exp (run_ld_link_exec_tests): Call
2115         check_compiler_available before trying to use the compiler.
2116         (run_cc_link_tests): Likewise.
2117         (check_compiler_available): New.  Use it instead of [which $CC].
2119 2019-04-23  Alan Modra  <amodra@gmail.com>
2121         * Makefile.am (GENDEPDIR): New var, used..
2122         (GENSCRIPTS): ..here.
2123         * Makefile.in: Regenerate.
2124         * genscripts.sh: Test for $DEPDIR set before every use.
2126 2019-04-22  Matthew Fortune  <matthew.fortune@mips.com>
2128         * testsuite/ld-mips-elf/mips-elf-flags.exp: Fix expected ASEs
2129         for M5100.
2131 2019-04-19  Alan Modra  <amodra@gmail.com>
2133         * testsuite/ld-gc/skip-map-discarded.s: Add section attributes.
2134         * testsuite/lib/ld-lib.exp (check_gc_sections_available): Add
2135         s12z to list of targets not supporting --gc-sections.
2137 2019-04-17  H.J. Lu  <hongjiu.lu@intel.com>
2139         * testsuite/ld-i386/i386.exp: Run pr18801a and pr18801b instead
2140         of pr18801.
2141         * testsuite/ld-x86-64/x86-64.exp: Likewise.
2142         * testsuite/ld-i386/pr18801.d: Removed.
2143         * testsuite/ld-x86-64/pr18801.d: Likewise.
2144         * testsuite/ld-i386/pr18801a.d: New file.
2145         * testsuite/ld-i386/pr18801b.d: Likewise.
2146         * testsuite/ld-x86-64/pr18801a.d: Likewise.
2147         * testsuite/ld-x86-64/pr18801b.d: Likewise.
2148         * testsuite/ld-x86-64/pie2.d: Suggest -fPIE instead of -fPIC.
2149         * testsuite/ld-x86-64/pie2.d: Likewise.
2150         * testsuite/ld-x86-64/pr19719.d: Likewise.
2151         * testsuite/ld-x86-64/pr19807-2a.d: Likewise.
2152         * testsuite/ld-x86-64/pr19969.d: Likewise.
2153         * testsuite/ld-x86-64/pr21997-1a.err: Likewise.
2154         * testsuite/ld-x86-64/pr21997-1b.err: Likewise.
2155         * testsuite/ld-x86-64/pr22001-1a.err: Likewise.
2156         * testsuite/ld-x86-64/pr22001-1b.err: Likewise.
2157         * testsuite/ld-x86-64/pr22791-1.err: Likewise.
2159 2019-04-17  H.J. Lu  <hongjiu.lu@intel.com>
2161         PR ld/24458
2162         * testsuite/ld-x86-64/x86-64.exp: Run PR ld/24458 tests.
2163         * testsuite/ld-x86-64/pr24458.s: New file.
2164         * testsuite/ld-x86-64/pr24458a-x32.d: Likewise.
2165         * testsuite/ld-x86-64/pr24458a.d: Likewise.
2166         * testsuite/ld-x86-64/pr24458b-x32.d: Likewise.
2167         * testsuite/ld-x86-64/pr24458b.d: Likewise.
2168         * testsuite/ld-x86-64/pr24458c-x32.d: Likewise.
2169         * testsuite/ld-x86-64/pr24458c.d: Likewise.
2171 2019-04-17  Jozef Lawrynowicz  <jozef.l@mittosystems.com>
2173         * config/tc-msp430.c (msp430_make_init_symbols): Define __crt0_init_bss
2174         symbol when .lower.bss or .either.bss sections exist.
2175         Define __crt0_movedata when .lower.data or .either.data sections exist.
2176         * testsuite/gas/msp430/either-data-bss-sym.d: New test.
2177         * testsuite/gas/msp430/low-data-bss-sym.d: New test.
2178         * testsuite/gas/msp430/either-data-bss-sym.s: New test source.
2179         * testsuite/gas/msp430/low-data-bss-sym.s: New test source.
2180         * testsuite/gas/msp430/msp430.exp: Run new tests.
2181         Enable large code model when running -mdata-region={upper,either}
2182         tests.
2184 2019-04-16  Alan Modra  <amodra@gmail.com>
2186         * testsuite/ld-scripts/pr20302.d: Don't run for ns32k-*-*.
2187         * testsuite/ld-scripts/section-match-1.d: Likewise.
2188         * testsuite/ld-undefined/require-defined.exp: Likewise.
2190 2019-04-15  Faraz Shahbazker  <fshahbazker@wavecomp.com>
2192         * testsuite/ld-gc/gc.exp: Skip print-map-discarded test for non-ELF
2193         targets.
2195 2019-04-15  Sudakshina Das  <sudi.das@arm.com>
2197         * testsuite/ld-arm/bfcsel.s: New.
2198         * testsuite/ld-arm/bfcsel.d: New.
2199         * testsuite/ld-arm/arm-elf.exp: Add above test.
2201 2019-04-15  Sudakshina Das  <sudi.das@arm.com>
2203         * testsuite/ld-arm/bfl.s: New.
2204         * testsuite/ld-arm/bfl.d: New.
2205         * testsuite/ld-arm/arm-elf.exp: Add above test.
2207 2019-04-15  Sudakshina Das  <sudi.das@arm.com>
2209         * testsuite/ld-arm/bf.s: New.
2210         * testsuite/ld-arm/bf.d: New.
2211         * testsuite/ld-arm/arm-elf.exp: Add above test.
2213 2019-04-15  Thomas Preud'homme  <thomas.preudhomme@arm.com>
2215         * testsuite/ld-arm/attr-merge-13.attr: New test.
2216         * testsuite/ld-arm/attr-merge-13a.s: New test.
2217         * testsuite/ld-arm/attr-merge-13b.s: New test.
2219 2019-04-13  Alan Modra  <amodra@gmail.com>
2221         * Makefile.am (GENSCRIPTS): Pass LIB_PATH as a parameter.  Add
2222         DEPDIR parameter.
2223         (ELF_DEPS, ELF_GEN_DEPS, ELF_X86_DEPS): Delete.
2224         (ALL_EMULATION_SOURCES, ALL_64_EMULATION_SOURCES): Depend on
2225         $GEN_DEPENDS.
2226         (e*.c): Delete all dependencies, instead include dependencies
2227         from $DEPDIR/*.Pc.
2228         * Makefile.in: Regenerate.
2229         * configure.ac (source_sh): Define and use function.
2230         * configure: Regenerate.
2231         * emulparams/aarch64cloudabib.sh, * emulparams/aarch64elf32b.sh,
2232         * emulparams/aarch64elfb.sh, * emulparams/aarch64fbsdb.sh,
2233         * emulparams/aarch64linux32b.sh, * emulparams/aarch64linuxb.sh,
2234         * emulparams/arcelf.sh, * emulparams/arcelf_prof.sh,
2235         * emulparams/arclinux.sh, * emulparams/arclinux_nps.sh,
2236         * emulparams/arclinux_prof.sh, * emulparams/arcv2elf.sh,
2237         * emulparams/arcv2elfx.sh, * emulparams/armelf_fbsd.sh,
2238         * emulparams/armelf_linux_eabi.sh,
2239         * emulparams/armelf_linux_fdpiceabi.sh,
2240         * emulparams/armelf_nacl.sh, * emulparams/armelf_nbsd.sh,
2241         * emulparams/armelf_vxworks.sh, * emulparams/armelfb.sh,
2242         * emulparams/armelfb_fbsd.sh, * emulparams/armelfb_fuchsia.sh,
2243         * emulparams/armelfb_linux.sh, * emulparams/armelfb_linux_eabi.sh,
2244         * emulparams/armelfb_linux_fdpiceabi.sh,
2245         * emulparams/armelfb_nacl.sh, * emulparams/armelfb_nbsd.sh,
2246         * emulparams/armsymbian.sh, * emulparams/cskyelf_linux.sh,
2247         * emulparams/elf32_sparc_sol2.sh,
2248         * emulparams/elf32_sparc_vxworks.sh, * emulparams/elf32_tic6x_be.sh,
2249         * emulparams/elf32_tic6x_elf_be.sh,
2250         * emulparams/elf32_tic6x_elf_le.sh,
2251         * emulparams/elf32_tic6x_linux_be.sh,
2252         * emulparams/elf32_tic6x_linux_le.sh,
2253         * emulparams/elf32_x86_64.sh, * emulparams/elf32_x86_64_nacl.sh,
2254         * emulparams/elf32b4300.sh, * emulparams/elf32bfinfd.sh,
2255         * emulparams/elf32bmipn32.sh, * emulparams/elf32bsmip.sh,
2256         * emulparams/elf32btsmip.sh, * emulparams/elf32btsmip_fbsd.sh,
2257         * emulparams/elf32btsmipn32.sh, * emulparams/elf32btsmipn32_fbsd.sh,
2258         * emulparams/elf32ebmip.sh, * emulparams/elf32ebmipvxworks.sh,
2259         * emulparams/elf32elmip.sh, * emulparams/elf32elmipvxworks.sh,
2260         * emulparams/elf32frvfd.sh, * emulparams/elf32l4300.sh,
2261         * emulparams/elf32lm32fd.sh, * emulparams/elf32lmip.sh,
2262         * emulparams/elf32lppc.sh, * emulparams/elf32lppclinux.sh,
2263         * emulparams/elf32lppcnto.sh, * emulparams/elf32lppcsim.sh,
2264         * emulparams/elf32lr5900.sh, * emulparams/elf32lr5900n32.sh,
2265         * emulparams/elf32lriscv.sh, * emulparams/elf32lriscv_ilp32.sh,
2266         * emulparams/elf32lriscv_ilp32f.sh, * emulparams/elf32lsmip.sh,
2267         * emulparams/elf32ltsmip.sh, * emulparams/elf32ltsmip_fbsd.sh,
2268         * emulparams/elf32ltsmipn32.sh, * emulparams/elf32ltsmipn32_fbsd.sh,
2269         * emulparams/elf32microblazeel.sh, * emulparams/elf32or1k_linux.sh,
2270         * emulparams/elf32ppc.sh, * emulparams/elf32ppc_fbsd.sh,
2271         * emulparams/elf32ppccommon.sh, * emulparams/elf32ppclinux.sh,
2272         * emulparams/elf32ppcnto.sh, * emulparams/elf32ppcsim.sh,
2273         * emulparams/elf32ppcvxworks.sh, * emulparams/elf32ppcwindiss.sh,
2274         * emulparams/elf32tilegx_be.sh, * emulparams/elf64_ia64_fbsd.sh,
2275         * emulparams/elf64_sparc_fbsd.sh, * emulparams/elf64_sparc_sol2.sh,
2276         * emulparams/elf64alpha_fbsd.sh, * emulparams/elf64alpha_nbsd.sh,
2277         * emulparams/elf64bmip-defs.sh, * emulparams/elf64bmip.sh,
2278         * emulparams/elf64btsmip.sh, * emulparams/elf64btsmip_fbsd.sh,
2279         * emulparams/elf64lppc.sh, * emulparams/elf64lriscv-defs.sh,
2280         * emulparams/elf64lriscv.sh, * emulparams/elf64lriscv_lp64.sh,
2281         * emulparams/elf64lriscv_lp64f.sh, * emulparams/elf64ltsmip.sh,
2282         * emulparams/elf64ltsmip_fbsd.sh, * emulparams/elf64ppc.sh,
2283         * emulparams/elf64ppc_fbsd.sh, * emulparams/elf64rdos.sh,
2284         * emulparams/elf64tilegx_be.sh, * emulparams/elf_i386.sh,
2285         * emulparams/elf_i386_be.sh, * emulparams/elf_i386_fbsd.sh,
2286         * emulparams/elf_i386_ldso.sh, * emulparams/elf_i386_nacl.sh,
2287         * emulparams/elf_i386_sol2.sh, * emulparams/elf_i386_vxworks.sh,
2288         * emulparams/elf_iamcu.sh, * emulparams/elf_k1om.sh,
2289         * emulparams/elf_k1om_fbsd.sh, * emulparams/elf_l1om.sh,
2290         * emulparams/elf_l1om_fbsd.sh, * emulparams/elf_x86_64.sh,
2291         * emulparams/elf_x86_64_cloudabi.sh,
2292         * emulparams/elf_x86_64_fbsd.sh, * emulparams/elf_x86_64_nacl.sh,
2293         * emulparams/elf_x86_64_sol2.sh, * emulparams/h8300helf.sh,
2294         * emulparams/h8300helf_linux.sh, * emulparams/h8300hnelf.sh,
2295         * emulparams/h8300self.sh, * emulparams/h8300self_linux.sh,
2296         * emulparams/h8300snelf.sh, * emulparams/h8300sxelf.sh,
2297         * emulparams/h8300sxelf_linux.sh, * emulparams/h8300sxnelf.sh,
2298         * emulparams/hppanbsd.sh, * emulparams/hppaobsd.sh,
2299         * emulparams/m32rlelf.sh, * emulparams/m32rlelf_linux.sh,
2300         * emulparams/m68kelfnbsd.sh, * emulparams/mn10300.sh,
2301         * emulparams/msp430X.sh, * emulparams/nds32belf.sh,
2302         * emulparams/nds32belf16m.sh, * emulparams/nds32belf_linux.sh,
2303         * emulparams/pjlelf.sh, * emulparams/ppclynx.sh,
2304         * emulparams/score7_elf.sh, * emulparams/shelf_fd.sh,
2305         * emulparams/shelf_linux.sh, * emulparams/shelf_nbsd.sh,
2306         * emulparams/shelf_uclinux.sh, * emulparams/shelf_vxworks.sh,
2307         * emulparams/shl.sh, * emulparams/shlelf.sh,
2308         * emulparams/shlelf_fd.sh, * emulparams/shlelf_nbsd.sh,
2309         * emulparams/shlelf_vxworks.sh: Use source_sh.
2310         * genscripts.sh: Adjust for changed parameters.  Emit dependencies
2311         for e*.c to .deps/*.Pc.
2312         (source_sh): New function, use it throughout to source scripts.
2313         * genscrba.sh (source_em): Use source_sh.
2315 2019-04-13  Alan Modra  <amodra@gmail.com>
2317         * configure.ac (TDIRS): Build up tdirs in this variable and
2318         AC_SUBST, also using AM_SUBST_NOTMAKE.
2319         * configure: Regenerate.
2320         * Makefile.am (DISTCLEANFILES): Remove tdirs.
2321         * Makefile.in: Regenerate.
2323 2019-04-12  Nick Clifton  <nickc@redhat.com>
2325         PR 24450
2326         * ld.texi (Output Section Attributes): Add ALIGN_WITH_INPUT to
2327         example of section attributes.
2329 2019-04-11  Faraz Shahbazker  <fshahbazker@wavecomp.com>
2331         * NEWS: Mention new option --no-print-map-discarded.
2332         * ld.h (ld_config_type) <print_map_discarded>: New field.
2333         * ldlang.c (lang_map): Conditionally output discarded sections
2334         in map files based on configuration option.
2335         * ldlex.h (option_values) <OPTION_PRINT_MAP_DISCARDED,
2336         OPTION_NO_PRINT_MAP_DISCARDED>: New.
2337         * ldmain.c (main): Enabled print_map_discarded by default.
2338         * lexsup.c (ld_options): Add new command-line options.
2339         (parse_args) <OPTION_NO_PRINT_MAP_DISCARDED,
2340         OPTION_PRINT_MAP_DISCARDED>: New cases.
2341         * ld.texi: Document new options.
2342         * testsuite/ld-gc/gc.exp: Add new test.
2343         * testsuite/ld-gc/skip-map-discarded.s: New file.
2344         * testsuite/ld-gc/skip-map-discarded.d: New file.
2345         * testsuite/ld-gc/skip-map-discarded.map: New file.
2347 2019-04-11  H.J. Lu  <hongjiu.lu@intel.com>
2349         * ld.texi: Document -z cet-report=[none|warning|error].
2350         * emulparams/cet.sh: Add -z cet-report=[none|warning|error].
2351         * testsuite/ld-i386/i386.exp: Run -z cet-report=[warning|error]
2352         tests.
2353         * testsuite/ld-x86-64/x86-64.exp: Likewise.
2354         * testsuite/ld-i386/property-x86-cet1.d: New file.
2355         * testsuite/ld-i386/property-x86-cet2a.d: Likewise.
2356         * testsuite/ld-i386/property-x86-cet2b.d: Likewise.
2357         * testsuite/ld-i386/property-x86-cet3a.d: Likewise.
2358         * testsuite/ld-i386/property-x86-cet3b.d: Likewise.
2359         * testsuite/ld-i386/property-x86-cet4a.d: Likewise.
2360         * testsuite/ld-i386/property-x86-cet4b.d: Likewise.
2361         * testsuite/ld-i386/property-x86-cet5a.d: Likewise.
2362         * testsuite/ld-i386/property-x86-cet5b.d: Likewise.
2363         * testsuite/ld-i386/property-x86-cet6.d: Likewise.
2364         * testsuite/ld-x86-64/property-x86-cet.s: Likewise.
2365         * testsuite/ld-x86-64/property-x86-cet1-x32.d: Likewise.
2366         * testsuite/ld-x86-64/property-x86-cet1.d: Likewise.
2367         * testsuite/ld-x86-64/property-x86-cet2a-x32.d: Likewise.
2368         * testsuite/ld-x86-64/property-x86-cet2a.d: Likewise.
2369         * testsuite/ld-x86-64/property-x86-cet2b-x32.d: Likewise.
2370         * testsuite/ld-x86-64/property-x86-cet2b.d: Likewise.
2371         * testsuite/ld-x86-64/property-x86-cet3a-x32.d: Likewise.
2372         * testsuite/ld-x86-64/property-x86-cet3a.d: Likewise.
2373         * testsuite/ld-x86-64/property-x86-cet3b-x32.d: Likewise.
2374         * testsuite/ld-x86-64/property-x86-cet3b.d: Likewise.
2375         * testsuite/ld-x86-64/property-x86-cet4a-x32.d: Likewise.
2376         * testsuite/ld-x86-64/property-x86-cet4a.d: Likewise.
2377         * testsuite/ld-x86-64/property-x86-cet4b-x32.d: Likewise.
2378         * testsuite/ld-x86-64/property-x86-cet4b.d: Likewise.
2379         * testsuite/ld-x86-64/property-x86-cet5a-x32.d: Likewise.
2380         * testsuite/ld-x86-64/property-x86-cet5a.d: Likewise.
2381         * testsuite/ld-x86-64/property-x86-cet5b-x32.d: Likewise.
2382         * testsuite/ld-x86-64/property-x86-cet5b.d: Likewise.
2383         * testsuite/ld-x86-64/property-x86-cet6-x32.d: Likewise.
2384         * testsuite/ld-x86-64/property-x86-cet6.d: Likewise.
2386 2019-04-11  H.J. Lu  <hongjiu.lu@intel.com>
2388         * testsuite/config/default.exp (STATIC_PIE_LDFLAGS): New.  Set
2389         to "-static-pie" if target compiler supports it.
2390         * testsuite/ld-elf/elf.exp: Run -static-pie tests if
2391         $STATIC_PIE_LDFLAGS isn't empty.
2392         * testsuite/ld-ifunc/ifunc.exp: Likewise.
2394 2019-04-11  Tamar Christina  <tamar.christina@arm.com>
2396         PR ld/24302
2397         * testsuite/ld-aarch64/aarch64-elf.exp: Add new test.
2398         * testsuite/ld-aarch64/tls-relax-gdesc-le-now.d: New test.
2400 2019-04-10  H.J. Lu  <hongjiu.lu@intel.com>
2402         * scripttempl/elf.sc (CREATE_PIC): New.  Set for CREATE_SHLIB or
2403         CREATE_PIE.
2404         (__rel_iplt_start): Don't define for CREATE_PIC.
2405         (__rel_iplt_end): Likewise.
2406         (__rela_iplt_start): Likewise.
2407         (__rela_iplt_end): Likewise.
2409 2019-04-10  Alan Modra  <amodra@gmail.com>
2411         * testsuite/ld-elf/shared.exp: Don't xfail PR ld/20995 for
2412         powerpc-nto.
2414 2019-04-10  Alan Modra  <amodra@gmail.com>
2416         * emultempl/cskyelf.em (csk_elf_before_parse): New function,
2417         setting use_branch_stub false for linux.
2418         (csky_elf_create_output_section_statements): Do emit this
2419         function and all others in the file for linux, plus the branch
2420         option control.  Disable branch stubs when non-ELF.
2422 2019-04-10  Alan Modra  <amodra@gmail.com>
2424         * Makefile.am (eskyelf.c, eskyelf_linux.c): Depend on cskyelf.em.
2425         (ecskyelf_linux.c): Depend on cskyelf.sh.
2426         (eelf32microblazeel.c): Depend on elf32microblaze.sh.
2427         * Makefile.in: Regenerate.
2428         * emulparams/cskyelf.sh: Comment regarding cskelf_linux.sh.
2429         (PAGE_SIZE): Don't define.
2430         * emulparams/cskyelf_linux.sh: Source sckyelf.sh, leaving just
2431         the differing variable defs/undefs.
2432         * emulparams/elf32mcore.sh (PAGE_SIZE): Don't define.
2433         * emulparams/elf32microblaze.sh: Comment re. elf32microblazeel.sh.
2434         (OUTPUT_FORMAT): Use BIG_OUTPUT_FORMAT.
2435         (PAGE_SIZE): Don't define.
2436         * emulparams/elf32microblazeel.sh: Source elf32microblaze.sh,
2437         leaving just the differing OUTPUT_FORMAT.
2439 2019-04-10  Alan Modra  <amodra@gmail.com>
2441         * po/BLD-POTFILES.in: Regenerate.
2443 2019-04-08  H.J. Lu  <hongjiu.lu@intel.com>
2445         * testsuite/ld-elf/shared.exp: XFAIL PR ld/20995 tests for
2446         lynxos and nto targets.
2448 2019-04-08  H.J. Lu  <hongjiu.lu@intel.com>
2450         * Makefile.am (ALL_EMULATION_SOURCES): Remove eelf_i386_chaos.c.
2451         (eelf_i386_chaos.c): Removed.
2452         * Makefile.in: Regenerated.
2453         * configure.tgt: Remove i[3-7]86-*-kaos*.
2454         * emulparams/elf_i386_chaos.sh: Removed.
2456 2019-04-08  H.J. Lu  <hongjiu.lu@intel.com>
2458         * emulparams/elf_i386_be.sh (EXTRA_EM_FILE): New.
2459         * emulparams/i386moss.sh (EXTRA_EM_FILE): Likewise.
2461 2019-04-08  Alan Modra  <amodra@gmail.com>
2463         * emulparams/elf64rdos.sh (EXTRA_EM_FILE): Define.
2464         * emulparams/i386lynx.sh (EXTRA_EM_FILE): Define.
2465         * emulparams/i386nto.sh (EXTRA_EM_FILE): Define.
2467 2019-04-06  H.J. Lu  <hongjiu.lu@intel.com>
2469         * Makefile.am (ELF_X86_DEPS): Add $(srcdir)/emultempl/elf-x86.em.
2470         (eelf_i386_sol2.c): Also depend on
2471         $(srcdir)/emultempl/solaris2-x86.em.
2472         (eelf_x86_64_sol2.c): Likewise.
2473         * Makefile.in: Regenerated.
2474         * emulparams/call_nop.sh: Set x86-specific linker options via
2475         params.
2476         * emulparams/cet.sh: Likewise.
2477         * emulparams/reloc_overflow.sh: Likewise.
2478         * emulparams/elf32_x86_64.sh (EXTRA_EM_FILE): New.  Set to
2479         "elf-x86".
2480         * emulparams/elf_i386.sh: Likewise.
2481         * emulparams/elf_i386_be.sh: Likewise.
2482         * emulparams/elf_i386_chaos.sh: Likewise.
2483         * emulparams/elf_i386_ldso.sh: Likewise.
2484         * emulparams/elf_i386_vxworks.sh: Likewise.
2485         * emulparams/elf_iamcu.sh: Likewise.
2486         * emulparams/elf_k1om.sh: Likewise.
2487         * emulparams/elf_l1om.sh: Likewise.
2488         * emulparams/elf_x86_64.sh: Likewise.
2489         * emulparams/elf_i386_sol2.sh (EXTRA_EM_FILE): Changed to
2490         "solaris2-x86".
2491         * emulparams/elf_x86_64_sol2.sh: Likewise.
2492         * emultempl/elf-x86.em: New file.
2493         * emultempl/solaris2-x86.em: Likewise.
2494         * emultempl/elf32.em (gld${EMULATION_NAME}_before_parse): Don't
2495         set link_info.call_nop_byte.
2497 2019-04-05  Alan Modra  <amodra@gmail.com>
2499         * testsuite/ld-powerpc/tlsexe32.d: Remove trailing spaces.
2500         * testsuite/ld-powerpc/tlsopt5.d: Likewise.
2501         * testsuite/ld-powerpc/tlsopt5_32.d: Likewise.
2503 2019-04-03  Alan Modra  <amodra@gmail.com>
2505         PR 24411
2506         ldlex.l (SYMBOLNAMECHAR1): Don't match '/'.
2507         (<EXPRESSION>"/DISCARD/"): New.
2509 2019-04-03  Alan Modra  <amodra@gmail.com>
2511         * ldlex.l: Formatting.
2512         (CMDFILENAMECHAR, CMDFILENAMECHAR1): Delete.
2513         (FILENAMECHAR1, SYMBOLNAMECHAR1, FILENAMECHAR, WILDCHAR),
2514         (NOCFILENAMECHAR): Remove duplicate chars.  Reorder.
2515         (SYMBOLCHARN): Likewise.  Rename to SYMBOLNAMECHAR.
2516         (<INPUTLIST>"$SYSROOT"..): Delete rule.
2518 2019-03-29  Max Filippov  <jcmvbkbc@gmail.com>
2520         * testsuite/ld-xtensa/relax-undef-weak-pie-export-dynamic.d: New
2521         test definition.
2522         * testsuite/ld-xtensa/xtensa.exp
2523         (relax-undef-weak-pie-export-dynamic): Add new test.
2525 2019-03-26  Martin Liska  <mliska@suse.cz>
2527         * plugin.c (get_symbols): Add lto_kind_str, lto_resolution_str,
2528         lto_visibility_str and use then to inform about plugin-symbols.
2529         * testsuite/ld-plugin/plugin-12.d: Adjust expected pattern.
2531 2019-03-25  Tamar Christina  <tamar.christina@arm.com>
2533         * testsuite/ld-arm/jump-reloc-veneers-cond-long.d: Update disassembly.
2534         * testsuite/ld-arm/jump-reloc-veneers-long.d: Update disassembly.
2536 2019-03-21  Sudakshina Das  <sudi.das@arm.com>
2538         * testsuite/ld-aarch64/aarch64-elf.exp: Add new test.
2539         * testsuite/ld-aarch64/bti-plt-1.s: Add .ifdef for PAC note section.
2540         * testsuite/ld-aarch64/bti-plt-6.d: Update warning.
2541         * testsuite/ld-aarch64/bti-plt-7.d: Likewise.
2542         * testsuite/ld-aarch64/bti-warn.d: New test.
2544 2019-03-21  Alan Modra  <amodra@gmail.com>
2546         * testsuite/ld-elf/fini2.s: Reduce alignment.
2547         * testsuite/ld-elf/fini3.s: Likewise.
2548         * testsuite/ld-elf/finin.s: Likewise.
2549         * testsuite/ld-elf/init2.s: Likewise.
2550         * testsuite/ld-elf/init3.s: Likewise.
2551         * testsuite/ld-elf/initn.s: Likewise.
2552         * testsuite/ld-elf/pr14156a.d: Don't xfail m68hc1*-* or xgate-*.
2553         * testsuite/ld-elf/pr14156b.d: Don't xfail xgate-*.
2555 2019-03-21  Alan Modra  <amodra@gmail.com>
2557         * scripttempl/alpha.sc, * scripttempl/armbpabi.sc,
2558         * scripttempl/crisaout.sc, * scripttempl/elf32cr16.sc,
2559         * scripttempl/elf32crx.sc, * scripttempl/elf32xc16x.sc,
2560         * scripttempl/elf32xc16xl.sc, * scripttempl/elf32xc16xs.sc,
2561         * scripttempl/elf64hppa.sc, * scripttempl/elf_chaos.sc,
2562         * scripttempl/elfarc.sc, * scripttempl/elfarcv2.sc,
2563         * scripttempl/elfd30v.sc, * scripttempl/elfm68hc11.sc,
2564         * scripttempl/elfm68hc12.sc, * scripttempl/elfm9s12z.sc,
2565         * scripttempl/elfmicroblaze.sc, * scripttempl/elfxgate.sc,
2566         * scripttempl/elfxtensa.sc, * scripttempl/epiphany_4x4.sc,
2567         * scripttempl/ft32.sc, * scripttempl/i386beos.sc,
2568         * scripttempl/iq2000.sc, * scripttempl/mcorepe.sc,
2569         * scripttempl/mep.sc, * scripttempl/mips.sc, * scripttempl/moxie.sc,
2570         * scripttempl/pe.sc, * scripttempl/pep.sc, * scripttempl/ppcpe.sc,
2571         * scripttempl/tic4xcoff.sc, * scripttempl/tic80coff.sc,
2572         * scripttempl/v850.sc, * scripttempl/v850_rh850.sc,
2573         * scripttempl/visium.sc, * scripttempl/xstormy16.sc: Add KEEP and
2574         SORT_NONE to .init and .fini wildcards.
2575         * scripttempl/elf32xc16x.sc,
2576         * scripttempl/elf32xc16xl.sc,
2577         * scripttempl/elf32xc16xs.sc: Add .fini wildcard.
2578         * scripttempl/elf_chaos.sc: Add .init output section.
2579         * scripttempl/elfd30v.sc: Remove duplicate .init.
2580         * scripttempl/elfm68hc11.sc, * scripttempl/elfm68hc12.sc,
2581         * scripttempl/elfm9s12z.sc, * scripttempl/elfxgate.sc: Remove
2582         duplicate .init, and add .fini wildcard.
2583         * scripttempl/ppcpe.sc (INIT, FINI): Delete.
2584         * ldlang.c (update_wild_statements): Special case .init and
2585         .fini in the wildcard, not the output section.
2587 2019-03-21  Alan Modra  <amodra@gmail.com>
2589         * emulparams/elf32lm32fd.sh (DYNAMIC_LINK): Undef.
2591 2019-03-21  Alan Modra  <amodra@gmail.com>
2593         * ldlang.c (lang_size_sections_1): Set SEC_KEEP on
2594         create_object_symbols_section.
2595         * testsuite/ld-elf/pr22319.d: Don't xfail dlx.
2597 2019-03-18  Alan Modra  <amodra@gmail.com>
2599         * testsuite/ld-elf/merge.d: Remove csky from xfails, add moxie.
2600         * testsuite/ld-elf/pr21884.d: Remove csky from xfails.
2601         * testsuite/ld-elf/shared.exp: Add csky to list not xfailing pr22374.
2602         * testsuite/ld-unique/pr21529.d: Remove csky from xfails
2604 2019-03-15  Nick Clifton  <nickc@redhat.com>
2606         PR 24262
2607         * ld.texi (-plugin): Correct the path used to locate linker
2608         plugins.
2610 2019-03-13  Sudakshina Das  <sudi.das@arm.com>
2612         * NEWS: Document --pac-plt.
2613         * emultempl/aarch64elf.em (OPTION_PAC_PLT): New.
2614         (PARSE_AND_LIST_LONGOPTS, PARSE_AND_LIST_OPTIONS): Add pac-plt.
2615         (PARSE_AND_LIST_ARGS_CASES): Handle OPTION_PAC_PLT.
2616         * testsuite/ld-aarch64/aarch64-elf.exp: Add the following tests.
2617         * testsuite/ld-aarch64/bti-pac-plt-1.d: New test.
2618         * testsuite/ld-aarch64/bti-pac-plt-2.d: New test.
2619         * testsuite/ld-aarch64/pac-plt-1.d: New test.
2620         * testsuite/ld-aarch64/pac-plt-2.d: New test.
2621         * testsuite/ld-aarch64/bti-plt-1.s: Add .ifndef directive.
2623 2019-03-13  Sudakshina Das  <sudi.das@arm.com>
2624             Szabolcs Nagy  <szabolcs.nagy@arm.com>
2626         * NEWS: Document --force-bti.
2627         * emultempl/aarch64elf.em (plt_type, bti_type, OPTION_FORCE_BTI): New.
2628         (PARSE_AND_LIST_SHORTOPTS, PARSE_AND_LIST_OPTIONS): Add force-bti.
2629         (PARSE_AND_LIST_ARGS_CASES): Handle OPTION_FORCE_BTI.
2630         * testsuite/ld-aarch64/aarch64-elf.exp: Add all the tests below.
2631         * testsuite/ld-aarch64/bti-plt-1.d: New test.
2632         * testsuite/ld-aarch64/bti-plt-1.s: New test.
2633         * testsuite/ld-aarch64/bti-plt-2.d: New test.
2634         * testsuite/ld-aarch64/bti-plt-3.d: New test.
2635         * testsuite/ld-aarch64/bti-plt-4.d: New test.
2636         * testsuite/ld-aarch64/bti-plt-5.d: New test.
2637         * testsuite/ld-aarch64/bti-plt-6.d: New test.
2638         * testsuite/ld-aarch64/bti-plt-7.d: New test.
2639         * testsuite/ld-aarch64/bti-plt-so.s: New test.
2640         * testsuite/ld-aarch64/bti-plt.ld: New test.
2642 2019-03-13  Sudakshina Das  <sudi.das@arm.com>
2644         * NEWS: Document GNU_PROPERTY_AARCH64_FEATURE_1_BTI and
2645         GNU_PROPERTY_AARCH64_FEATURE_1_PAC.
2646         * testsuite/ld-aarch64/aarch64-elf.exp: Add run commands for new tests.
2647         * testsuite/ld-aarch64/property-bti-pac1.d: New test.
2648         * testsuite/ld-aarch64/property-bti-pac1.s: New test.
2649         * testsuite/ld-aarch64/property-bti-pac2.d: New test.
2650         * testsuite/ld-aarch64/property-bti-pac2.s: New test.
2651         * testsuite/ld-aarch64/property-bti-pac3.d: New test.
2653 2019-03-13  H.J. Lu  <hongjiu.lu@intel.com>
2655         PR ld/24322
2656         * testsuite/ld-i386/i386.exp: Run PR ld/24322 tests.
2657         * testsuite/ld-x86-64/x86-64.exp: Likewise.
2658         * testsuite/ld-i386/pr24322a.d: New file.
2659         * testsuite/ld-i386/pr24322b.d: Likewise.
2660         * testsuite/ld-x86-64/pr24322a-x32.d: Likewise.
2661         * testsuite/ld-x86-64/pr24322a.d: Likewise.
2662         * testsuite/ld-x86-64/pr24322b-x32.d: Likewise.
2663         * testsuite/ld-x86-64/pr24322b.d: Likewise.
2664         * testsuite/ld-x86-64/pr24322a.s: Likewise.
2665         * testsuite/ld-x86-64/pr24322b.s: Likewise.
2666         * testsuite/ld-x86-64/pr24322c.s: Likewise.
2668 2019-03-06  Nick Bowler  <nbowler@draconx.ca>
2670         PR 24289
2671         * ldexp.c (fold_name): Allow lookups of the LENGTH and ORIGIN
2672         attributes during the first phase.
2674 2019-03-01  Andreas Krebbel  <krebbel@linux.ibm.com>
2676         This reverts commit 5a12586d44fa8d5dfc74cbca4f2f36a273a16335.
2677         2019-01-14  Maamoun Tarsha  <maamountk@hotmail.com>
2679         PR 20113
2680         * emulparams/elf64_s390.sh (SEPARATE_GOTPLT): Define.
2681         * emulparams/elf_s390.sh (SEPARATE_GOTPLT): Define.
2682         * testsuite/ld-s390/gotreloc_31-1.dd: Update expected output.
2683         * testsuite/ld-s390/tlsbin.dd: Likewise.
2684         * testsuite/ld-s390/tlsbin.rd: Likewise.
2685         * testsuite/ld-s390/tlsbin.sd: Likewise.
2686         * testsuite/ld-s390/tlsbin_64.dd: Likewise.
2687         * testsuite/ld-s390/tlsbin_64.rd: Likewise.
2688         * testsuite/ld-s390/tlsbin_64.sd: Likewise.
2689         * testsuite/ld-s390/tlspic.dd: Likewise.
2690         * testsuite/ld-s390/tlspic.rd: Likewise.
2691         * testsuite/ld-s390/tlspic.sd: Likewise.
2692         * testsuite/ld-s390/tlspic_64.dd: Likewise.
2693         * testsuite/ld-s390/tlspic_64.rd: Likewise.
2694         * testsuite/ld-s390/tlspic_64.sd: Likewise.
2695         * testsuite/ld-s390/s390.exp: Skip s390 tests for tpf targets.
2697 2019-02-27  H.J. Lu  <hongjiu.lu@intel.com>
2699         PR ld/24276
2700         * testsuite/ld-i386/i386.exp: Run PR ld/24276 test.
2701         * testsuite/ld-x86-64/x86-64.exp: Likewise.
2702         * testsuite/ld-i386/pr24276.dso: New file.
2703         * testsuite/ld-i386/pr24276.warn: Likewise.
2704         * testsuite/ld-x86-64/pr24276.dso: Likewise.
2705         * testsuite/ld-x86-64/pr24276.warn: Likewise.
2707 2019-02-20  Eric Tsai  <erictsai@cadence.com>
2709         * testsuite/ld-xtensa/call_overflow.d: New test definition.
2710         * testsuite/ld-xtensa/call_overflow1.s: New test source.
2711         * testsuite/ld-xtensa/call_overflow2.s: New test source.
2712         * testsuite/ld-xtensa/call_overflow3.s: New test source.
2713         * testsuite/ld-xtensa/xtensa.exp: Add call_overflow test.
2715 2019-02-14  Thomas Schwinge  <thomas@codesourcery.com>
2717         * testsuite/ld-elf/elf.exp: Remove Hurd XFAILs.
2719 2019-02-12  Nick Clifton  <nickc@redhat.com>
2721         * po/fr.po: Updated French translation.
2723 2019-02-09  Vineet Gupta  <vgupta@synopsys.com>
2725         * emultempl/arclinux.em: Delete special INIT/FINI handling.
2727 2019-02-07  Nick Clifton  <nickc@redhat.com>
2729         PR 24175
2730         * ld.texi (Options): Add missing word to the description of the
2731         --start-group option.
2733 2019-02-06  Alan Modra  <amodra@gmail.com>
2735         PR ld/24008
2736         * testsuite/ld-scripts/pr24008.d: Pass with extra target
2737         defined symbols.
2739 2019-02-05  H.J. Lu  <hongjiu.lu@intel.com>
2741         PR ld/24151
2742         * testsuite/ld-x86-64/pr24151a-x32.d: New file.
2743         * testsuite/ld-x86-64/pr24151a.d: Likewise.
2744         * testsuite/ld-x86-64/pr24151a.s: Likewise.
2745         * testsuite/ld-x86-64/x86-64.exp: Run pr24151a and pr24151a-x32.
2747 2019-01-31  Alan Modra  <amodra@gmail.com>
2749         * NEWS: Mention -t change.
2750         * ld.texi (--trace/-t): Expand documentation a little.
2752 2019-01-29  H.J. Lu  <hongjiu.lu@intel.com>
2754         PR ld/24008
2755         * testsuite/ld-scripts/defined.exp: Run pr24008.
2756         * testsuite/ld-scripts/pr24008.d: New file.
2757         * testsuite/ld-scripts/pr24008.map: Likewise.
2758         * testsuite/ld-scripts/pr24008.s: Likewise.
2759         * testsuite/ld-scripts/pr24008.t: Likewise.
2761 2019-01-29  Eric Botcazou  <ebotcazou@adacore.com>
2763         * testsuite/ld-ifunc/ifunc.exp: Skip pr23169 on SPARC.
2765 2019-01-28  Alan Modra  <amodra@gmail.com>
2767         PR 24008
2768         * ldexp.h (lang_phase_type): Add lang_fixed_phase_enum.
2769         * ldexp.c (fold_name): Move expld.assign_name check later to
2770         avoid an extra lookup.
2771         (exp_fold_tree_1): When lang_fixed_phase_enum, don't change symbol
2772         values, and don't clear expld.assign_name.
2773         * ldlang.c (lang_map): Set expld.phase to lang_fixed_phase_enum.
2774         (print_assignment): Resolve entire assignment expression.
2775         Don't access symbol u.def unless symbol is defined.
2777 2019-01-25  Nick Clifton  <nickc@redhat.com>
2779         * po/bg.po: Updated Bulgarian translation.
2781 2019-01-23  Sebastian Huber  <sebastian.huber@embedded-brains.de>
2783         * ld.texi (--wrap): Add warning that LTO may make this feature
2784         ineffective.
2786 2019-01-21  Nick Clifton  <nickc@redhat.com>
2788         * po/uk.po: Updated Ukranian translation.
2789         * po/pr_BR.po: Updated Brazilian Portuguese translation.
2791 2019-01-21  Nick Clifton  <nickc@redhat.com>
2793         PR 24108
2794         * testsuite/ld-riscv-elf/attr-merge-arch-failed-01.d: Update
2795         expected error message.
2797 2019-01-19  Nick Clifton  <nickc@redhat.com>
2799         * configure: Regenerate.
2800         * po/ld.pot: Regenerate.
2802 2018-06-24  Nick Clifton  <nickc@redhat.com>
2804         2.32 branch created.
2806 2019-01-16  Kito Cheng  <kito@andestech.com>
2808         * testsuite/ld-elf/orphan-region.d: XFAIL for RISC-V, because add new
2809         section.
2810         * testsuite/ld-riscv-elf/ld-riscv-elf.exp: Add new tests.
2811         * testsuite/ld-riscv-elf/attr-merge-arch-01.d: New test.
2812         * testsuite/ld-riscv-elf/attr-merge-arch-01a.s: Likewise.
2813         * testsuite/ld-riscv-elf/attr-merge-arch-01b.s: Likewise.
2814         * testsuite/ld-riscv-elf/attr-merge-arch-02.d: Likewise.
2815         * testsuite/ld-riscv-elf/attr-merge-arch-02a.s: Likewise.
2816         * testsuite/ld-riscv-elf/attr-merge-arch-02b.s: Likewise.
2817         * testsuite/ld-riscv-elf/attr-merge-arch-03.d: Likewise.
2818         * testsuite/ld-riscv-elf/attr-merge-arch-03a.s: Likewise.
2819         * testsuite/ld-riscv-elf/attr-merge-arch-03b.s: Likewise.
2820         * testsuite/ld-riscv-elf/attr-merge-arch-failed-01.d: Likewise.
2821         * testsuite/ld-riscv-elf/attr-merge-arch-failed-01a.s: Likewise.
2822         * testsuite/ld-riscv-elf/attr-merge-arch-failed-01b.s: Likewise.
2823         * testsuite/ld-riscv-elf/attr-merge-priv-spec-a.s: Likewise.
2824         * testsuite/ld-riscv-elf/attr-merge-priv-spec-b.s: Likewise.
2825         * testsuite/ld-riscv-elf/attr-merge-priv-spec.d: Likewise.
2826         * testsuite/ld-riscv-elf/attr-merge-stack-align-a.s: Likewise.
2827         * testsuite/ld-riscv-elf/attr-merge-stack-align-b.s: Likewise.
2828         * testsuite/ld-riscv-elf/attr-merge-stack-align-failed-a.s: Likewise.
2829         * testsuite/ld-riscv-elf/attr-merge-stack-align-failed-b.s: Likewise.
2830         * testsuite/ld-riscv-elf/attr-merge-stack-align-failed.d: Likewise.
2831         * testsuite/ld-riscv-elf/attr-merge-stack-align.d: Likewise.
2832         * testsuite/ld-riscv-elf/attr-merge-strict-align-01.d: Likewise.
2833         * testsuite/ld-riscv-elf/attr-merge-strict-align-01a.s: Likewise.
2834         * testsuite/ld-riscv-elf/attr-merge-strict-align-01b.s: Likewise.
2835         * testsuite/ld-riscv-elf/attr-merge-strict-align-02.d: Likewise.
2836         * testsuite/ld-riscv-elf/attr-merge-strict-align-02a.s: Likewise.
2837         * testsuite/ld-riscv-elf/attr-merge-strict-align-02b.s: Likewise.
2838         * testsuite/ld-riscv-elf/attr-merge-strict-align-03.d: Likewise.
2839         * testsuite/ld-riscv-elf/attr-merge-strict-align-03a.s: Likewise.
2840         * testsuite/ld-riscv-elf/attr-merge-strict-align-03b.s: Likewise.
2841         * testsuite/ld-riscv-elf/attr-merge-strict-align-04.d: Likewise.
2842         * testsuite/ld-riscv-elf/attr-merge-strict-align-04a.s: Likewise.
2843         * testsuite/ld-riscv-elf/attr-merge-strict-align-04b.s: Likewise.
2844         * testsuite/ld-riscv-elf/attr-merge-strict-align-05.d: Likewise.
2845         * testsuite/ld-riscv-elf/attr-merge-strict-align-05a.s: Likewise.
2846         * testsuite/ld-riscv-elf/attr-merge-strict-align-05b.s: Likewise.
2848 2019-01-14  Maamoun Tarsha  <maamountk@hotmail.com>
2850         PR 20113
2851         * emulparams/elf64_s390.sh (SEPARATE_GOTPLT): Define.
2852         * emulparams/elf_s390.sh (SEPARATE_GOTPLT): Define.
2853         * testsuite/ld-s390/gotreloc_31-1.dd: Update expected output.
2854         * testsuite/ld-s390/tlsbin.dd: Likewise.
2855         * testsuite/ld-s390/tlsbin.rd: Likewise.
2856         * testsuite/ld-s390/tlsbin.sd: Likewise.
2857         * testsuite/ld-s390/tlsbin_64.dd: Likewise.
2858         * testsuite/ld-s390/tlsbin_64.rd: Likewise.
2859         * testsuite/ld-s390/tlsbin_64.sd: Likewise.
2860         * testsuite/ld-s390/tlspic.dd: Likewise.
2861         * testsuite/ld-s390/tlspic.rd: Likewise.
2862         * testsuite/ld-s390/tlspic.sd: Likewise.
2863         * testsuite/ld-s390/tlspic_64.dd: Likewise.
2864         * testsuite/ld-s390/tlspic_64.rd: Likewise.
2865         * testsuite/ld-s390/tlspic_64.sd: Likewise.
2866         * testsuite/ld-s390/s390.exp: Skip s390 tests for tpf targets.
2868 2019-01-14  Sebastian Huber  <sebastian.huber@embedded-brains.de>
2870         * ld.texi (--wrap): Add example to emphasise that only undefined
2871         references are replaced by the linker.
2873 2019-01-09  Nick Clifton  <nickc@redhat.com>
2875         * po/es.po: Updated Spanish translation.
2877 2019-01-09  Andrew Paprocki  <andrew@ishiboo.com>
2879         * configure: Regenerate.
2881 2019-01-08  Alan Modra  <amodra@gmail.com>
2883         * testsuite/ld-elf/sec64k.exp: Use . rather than $objdir in
2884         generated source file names.
2885         * testsuite/ld-m68k/m68k-got.exp: Likewise.
2887 2019-01-01  Alan Modra  <amodra@gmail.com>
2889         Update year range in copyright notice of all files.
2891 For older changes see ChangeLog-2018
2893 Copyright (C) 2019 Free Software Foundation, Inc.
2895 Copying and distribution of this file, with or without modification,
2896 are permitted in any medium without royalty provided the copyright
2897 notice and this notice are preserved.
2899 Local Variables:
2900 mode: change-log
2901 left-margin: 8
2902 fill-column: 74
2903 version-control: never
2904 End: