Use mmap and cache the view buffer for get_view
[external/binutils.git] / ld / ChangeLog
1 2015-02-06  H.J. Lu  <hongjiu.lu@intel.com>
2
3         * configure.ac: Add AC_FUNC_MMAP.
4         * config.in: Regenerated.
5         * configure: Likewise.
6         * plugin.c: Include <sys/mman.h>.
7         (MAP_FAILED): New.  Defined if not defined.
8         (PROT_READ): Likewise.
9         (MAP_PRIVATE): Likewise.
10         (view_buffer_t): New.
11         (plugin_input_file_t): Add view_buffer.
12         (get_view): Try mmap and cache the view buffer.
13         (plugin_maybe_claim): Initialize view_buffer.
14
15 2015-02-05  H.J. Lu  <hongjiu.lu@intel.com>
16
17         * plugin.c (release_input_file): Set fd to -1 after closing it.
18         (plugin_maybe_claim): Close fd only if fd != -1.
19
20 2015-02-05  H.J. Lu  <hongjiu.lu@intel.com>
21
22         PR ld/17878
23         * plugin.c: Include <errno.h>.
24         (errno): New.  Declare if needed.
25         (plugin_input_file_t): New.
26         (get_input_file): Implemented.
27         (get_view): Likewise.
28         (release_input_file): Likewise.
29         (add_symbols): Updated.
30         (get_symbols): Likewise.
31         (plugin_maybe_claim): Allocate a plugin_input_file_t.  Close fd
32         only for a bfd_object input.
33
34 2015-02-02  Alan Modra  <amodra@gmail.com>
35
36         * emultempl/ppc64elf.em (toc_section_name): New var.
37         (ppc_after_open): Set it.
38         (ppc_before_allocation): Use it.
39         (gld${EMULATION_NAME}_after_allocation): Here too.
40
41 2015-01-29  H.J. Lu  <hongjiu.lu@intel.com>
42
43         * ldfile.c (ldfile_try_open_bfd): Replace plugin_active_plugins_p()
44         with link_info.lto_plugin_active.
45         * ldlang.c (lang_process): Likewise.
46         * ldmain.c (add_archive_element): Likewise.
47         * plugin.c (plugin_active_plugins_p): Removed.
48         * plugin.h (plugin_active_plugins_p): Likewise.
49
50 2015-01-28  H.J. Lu  <hongjiu.lu@intel.com>
51
52         * plugin.h (plugin_get_ir_dummy_bfd): Removed.  Move comments to
53         ...
54         * plugin.c (plugin_get_ir_dummy_bfd): Here.  Make it static.
55
56 2015-01-28  H.J. Lu  <hongjiu.lu@intel.com>
57
58         PR ld/17878
59         * plugin.c (tv_header_tags(): Add LDPT_GET_VIEW.
60         (get_view): New function.
61         (set_tv_header): Handle LDPT_GET_VIEW.
62         * testplug.c (tag_names): Add LDPT_GET_VIEW.
63         (tv_get_view): New.
64         (dump_tv_tag): Handle LDPT_GET_VIEW.
65         (parse_tv_tag): Likewise.
66
67 2015-01-28  Alan Modra  <amodra@gmail.com>
68
69         * emulparams/elf64ppc.sh (INITIAL_READWRITE_SECTIONS): Define.
70         * emultempl/ppc64elf.em (params): Init new field.
71         (ppc_after_open): New function.
72         (LDEMUL_AFTER_OPEN): Define.
73         * ldlang.c (lang_final): Whitespace fix.
74
75 2015-01-28  James Bowman  <james.bowman@ftdichip.com>
76
77         * Makefile.am: Add FT32 files.
78         * configure.tgt: Handle FT32 target.
79         * emulparams/elf32ft32.sh: New file.
80         * scripttempl/ft32.sc: New file.
81         * Makefile.in: Regenerate.
82
83 2015-01-28  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
84
85         PR 4643
86         * ldexp.c (fold_name): Fold LENGTH only after
87         lang_first_phase_enum.
88         * ldgram.y (memory_spec): Don't evaluate ORIGIN and LENGTH
89         rightaway.
90         * ldlang.h (struct memory_region_struct): Add origin_exp and
91         length_exp fields.
92         * ldlang.c (lang_do_memory_regions): New.
93         (lang_memory_region_lookup): Initialize origin_exp and
94         length_exp fields.
95         (lang_process): Call lang_do_memory_regions.
96
97 2015-01-20  Andrew Burgess  <andrew.burgess@embecosm.com>
98
99         * ldlang.c (print_assignment): Only evaluate the expression for a
100         PROVIDE'd assignment when the destination is being defined.
101         Display a special message for PROVIDE'd symbols that are not being
102         provided.
103
104 2015-01-20  Alan Modra  <amodra@gmail.com>
105
106         * emulparams/elf64ppc.sh (OTHER_SDATA_SECTIONS): Use in place of..
107         (OTHER_BSS_SYMBOLS): ..this.
108         (OTHER_PLT_RELOC_SECTIONS): Don't define.
109         (OTHER_GOT_RELOC_SECTIONS): Add rela.toc1 and rela.tocbss.
110         (OTHER_READWRITE_SECTIONS): Don't define.  Move .toc1 to..
111         (OTHER_RELRO_SECTIONS_2): ..here.
112         * scripttempl/elf.sc: Move SBSS too when DATA_SDATA.
113
114 2015-01-20  Alan Modra  <amodra@gmail.com>
115
116         * emulparams/elf64ppc.sh (BSS_PLT): Don't define.
117         (OTHER_READWRITE_SECTIONS): Move .branch_lt to..
118         (OTHER_RELRO_SECTIONS_2): ..here.
119         (DATA_GOT, SEPARATE_GOTPLT, DATA_SDATA, DATA_PLT,
120         PLT_BEFORE_GOT): Define.
121         * scripttempl/elf.sc: Handle DATA_SDATA and DATA_GOT/DATA_PLT/
122         PLT_BEFORE_GOT combination.
123         (DATA_GOT, SDATA_GOT): Don't define if either is already defined.
124
125 2015-01-20  Alan Modra  <amodra@gmail.com>
126
127         * emulparams/elf64ppc.sh (OTHER_READWRITE_SECTIONS): Move .opd to..
128         (OTHER_RELRO_SECTIONS_2): ..here, new define.
129         * scripttempl/elf.sc: Add OTHER_RELRO_SECTIONS_2.
130
131 2015-01-19  Alan Modra  <amodra@gmail.com>
132
133         PR ld/17615
134         * ldlang.c (lang_process): Run lang_common before lang_gc_sections.
135
136 2015-01-14  Jiong Wang  <jiong.wang@arm.com>
137
138         * ld-arm/elf32-reject.s: New testcase.
139         * ld-arm/elf32-reject.d: Likewise.
140         * ld-arm/elf32-reject-pie.s: Likewise.
141         * ld-arm/elf32-reject-pie.d: Likewise.
142         * ld-arm/arm-elf.exp: Run new testcases.
143         * ld-arm/ifunc-7.s: Delete f2/f4 test items.
144         * ld-arm/ifunc-7.rd: Likewise.
145         * ld-arm/ifunc-7.gd: Likewise.
146         * ld-arm/ifunc-7.dd: Likewise.
147         * ld-arm/ifunc-8.s: Likewise.
148         * ld-arm/ifunc-8.rd: Likewise.
149         * ld-arm/ifunc-8.gd: Likewise.
150         * ld-arm/ifunc-8.dd: Likewise.
151
152 2015-01-01  Alan Modra  <amodra@gmail.com>
153
154         * ldver.c (ldversion): Just print current year.
155
156 2015-01-01  Alan Modra  <amodra@gmail.com>
157
158         Update year range in copyright notice of all files.
159
160 For older changes see ChangeLog-2014
161 \f
162 Copyright (C) 2015 Free Software Foundation, Inc.
163
164 Copying and distribution of this file, with or without modification,
165 are permitted in any medium without royalty provided the copyright
166 notice and this notice are preserved.
167
168 Local Variables:
169 mode: change-log
170 left-margin: 8
171 fill-column: 74
172 version-control: never
173 End: