Commit | Line | Data |
---|---|---|
009a67a2 CC |
1 | 2008-04-11 Cary Coutant <ccoutant@google.com> |
2 | ||
3 | * i386.cc (Target_i386::got_mod_index_entry): Restore code previously | |
4 | thought unnecessary. | |
5 | * x86_64.cc (Target_x86_64::got_mod_index_entry): Likewise. | |
6 | ||
759b1a24 ILT |
7 | 2008-04-11 Ian Lance Taylor <iant@google.com> |
8 | ||
9 | * output.h (class Output_section_data): Remove inline definition | |
10 | of set_addralign. | |
11 | * output.cc (Output_section_data::set_addralign): New function. | |
12 | ||
c2b45e22 CC |
13 | 2008-04-11 Cary Coutant <ccoutant@google.com> |
14 | ||
15 | Add support for TLS descriptors for i386 and x86_64. | |
16 | * i386.cc (Target_i386::Relocate::tls_desc_gd_to_ie): New function. | |
17 | (Target_i386::Relocate::tls_desc_gd_to_le): New function. | |
18 | (Target_i386::Got_type): Add GOT_TYPE_TLS_NOFFSET and | |
19 | GOT_TYPE_TLS_DESC. | |
20 | (Target_i386::got_mod_index_entry): Remove unnecessary code. | |
21 | (Target_i386::Scan::local): Implement R_386_TLS_GOTDESC and | |
22 | R_386_TLS_DESC_CALL relocations. Fix problem with initial-exec | |
23 | relocations. | |
24 | (Target_i386::Scan::global): Fix problem with GD-to-IE relaxation. | |
25 | Implement R_386_TLS_GOTDESC and R_386_TLS_DESC_CALL relocations; | |
26 | Fix problem with initial-exec relocations. | |
27 | (Target_i386::Relocate::relocate_tls): Likewise. | |
28 | (Target_i386::Relocate::tls_gd_to_ie): Fix problem with GD-to-IE | |
29 | relaxation. | |
30 | * output.cc (Output_data_dynamic::Dynamic_entry::write): Add | |
31 | support for section-plus-offset dynamic table entries. | |
32 | * output.h (Output_data_dynamic::add_section_plus_offset): New function. | |
33 | (Output_data_dynamic::Dynamic_entry): Add support for | |
34 | section-plus-offset dynamic table entries. | |
35 | (Output_data_dynamic::Classification): Likewise. | |
36 | (Output_data_dynamic::classification_): Renamed offset_. | |
37 | * x86_64.cc (Target_x86_64::Relocate::tls_desc_gd_to_ie): New function. | |
38 | (Target_x86_64::Relocate::tls_desc_gd_to_le): New function. | |
39 | (Target_x86_64::make_plt_section): New function. | |
40 | (Target_x86_64::reserve_tlsdesc_entries): New function. | |
41 | (Output_data_plt_x86_64::Output_data_plt_x86_64): Add new parameter. | |
42 | (Output_data_plt_x86_64::reserve_tlsdesc_entry): New function. | |
43 | (Output_data_plt_x86_64::has_tlsdesc_entry): New function. | |
44 | (Output_data_plt_x86_64::get_tlsdesc_got_offset): New function. | |
45 | (Output_data_plt_x86_64::get_tlsdesc_plt_offset): New function. | |
46 | (Output_data_plt_x86_64::tlsdesc_plt_entry): New field. | |
47 | (Output_data_plt_x86_64::set_final_data_size): Move out of line; | |
48 | add extra PLT entry for TLS descriptors. | |
49 | (Output_data_plt_x86_64::got_): New field. | |
50 | (Output_data_plt_x86_64::tlsdesc_got_offset_): New field. | |
51 | (Output_data_plt_x86_64::Output_data_plt_x86_64): Initialize new | |
52 | fields. | |
53 | (Output_data_plt_x86_64::do_write): Write extra PLT entry for TLS | |
54 | descriptors. | |
55 | (Target_x86_64::make_plt_entry): Factor out make_plt_section. | |
56 | (Target_x86_64::got_mod_index_entry): Remove unnecessary code. | |
57 | (Target_x86_64::Scan::local): Implement R_386_TLS_GOTDESC and | |
58 | R_386_TLS_DESC_CALL relocations. | |
59 | (Target_x86_64::Scan::global): Likewise. | |
60 | (Target_x86_64::do_finalize_sections): Add dynamic table entries | |
61 | for TLS descriptors. | |
62 | (Relocate::relocate_tls): Fix problem with GD-to-IE relaxation. | |
63 | Implement R_386_TLS_GOTDESC and R_386_TLS_DESC_CALL relocations. | |
64 | (Target_x86_64::Relocate::tls_gd_to_ie): Fix problem with | |
65 | GD-to-IE relaxation. | |
66 | * configure.ac: Export new conditional variables TLS_GNU2_DIALECT | |
67 | and TLS_DESCRIPTORS. | |
68 | * Makefile.in: Rebuild. | |
69 | * configure: Rebuild. | |
70 | * testsuite/Makefile.am (tls_shared_gd_to_ie_test): New target. | |
71 | (tls_test_shared2.so): New target. | |
72 | (tls_shared_gd_to_ie_test_SOURCES): New variable. | |
73 | (tls_shared_gd_to_ie_test_DEPENDENCIES): New variable. | |
74 | (tls_shared_gd_to_ie_test_LDFLAGS): New variable. | |
75 | (tls_shared_gd_to_ie_test_LDADD): New variable. | |
76 | (tls_shared_gnu2_gd_to_ie_test): New target. | |
77 | (tls_test_gnu2.o, tls_test_file2_gnu2.o, tls_test_gnu2_shared2.so): | |
78 | New targets. | |
79 | (tls_shared_gnu2_gd_to_ie_test_SOURCES): New variable. | |
80 | (ls_shared_gnu2_gd_to_ie_test_DEPENDENCIES): New variable. | |
81 | (tls_shared_gnu2_gd_to_ie_test_LDFLAGS): New variable. | |
82 | (tls_shared_gnu2_gd_to_ie_test_LDADD): New variable. | |
83 | (tls_shared_gnu2_test): New target. | |
84 | (tls_test_gnu2_shared.so): New target. | |
85 | (tls_shared_gnu2_test_SOURCES): New variable. | |
86 | (tls_shared_gnu2_test_DEPENDENCIES): New variable. | |
87 | (tls_shared_gnu2_test_LDFLAGS): New variable. | |
88 | (tls_shared_gnu2_test_LDADD): New variable. | |
89 | * testsuite/Makefile.in: Rebuild. | |
90 | * testsuite/Makefile. | |
91 | ||
83bfb6b7 ILT |
92 | 2008-04-11 Ian Lance Taylor <iant@google.com> |
93 | ||
94 | * testsuite/Makefile.am (justsyms_2r.o): Add dependency on | |
95 | justsyms.t. | |
96 | * testsuite/Makefile.in: Rebuild. | |
97 | ||
98 | * testsuite/script_test_2a.cc (script_test_string_a): Make 8 bytes | |
99 | long. | |
100 | * testsuite/script_test_2.cc (main): Adjust test. | |
101 | ||
706e1f5e ILT |
102 | 2008-04-11 David S. Miller <davem@davemloft.net> |
103 | Ian Lance Taylor <iant@google.com> | |
104 | ||
105 | * options.h (General_options): Add entries for '-Y' and | |
106 | '-relax'. | |
107 | * options.cc (General_options:finalize): If -Y was used, add those | |
108 | entries to the library path instead of the default "/lib" and | |
109 | "/usr/lib". | |
110 | ||
7c98e6bb DM |
111 | 2008-04-11 David S. Miller <davem@davemloft.net> |
112 | ||
113 | * testsuite/justsyms.t: Start at 0x100. | |
114 | * testsuite/justsyms_1.cc: Adjust justsyms_string assertion. | |
83bfb6b7 ILT |
115 | * testsuite/script_test_2b.cc (script_test_string_b): Make 8 bytes |
116 | long. | |
117 | * testsuite/script_test_2.cc: Adjust string and section length | |
118 | checks. | |
7c98e6bb | 119 | |
99a37bfd ILT |
120 | 2008-04-09 Ian Lance Taylor <iant@google.com> |
121 | ||
2cefc357 ILT |
122 | PR gold/5996 |
123 | * script-sections.cc (Sections_element::allocate_to_segment): Add | |
124 | orphan parameter. | |
125 | (Output_section_definition::allocate_to_segment): Likewise. | |
126 | (Orphan_output_section::allocate_to_segment): Likewise. | |
127 | (Script_sections::attach_sections_using_phdrs_clause): Don't | |
128 | propagate non-PT_LOAD segments to orphan sections. | |
129 | * testsuite/Makefile.am (script_test_3.stdout): Generate using | |
130 | readelf rather than objdump. | |
131 | * testsuite/script_test_3.sh: Adjust accordingly. Test that | |
132 | .interp section and PT_INTERP segment are the same size. | |
133 | * testsuite/Makefile.in: Rebuild. | |
134 | ||
99a37bfd ILT |
135 | * symtab.cc (Symbol_table::add_from_dynobj): Only look for weak |
136 | aliases for symbols defined in the same object. | |
137 | * testsuite/Makefile.am (check_PROGRAMS): Add weak_alias_test. | |
138 | (weak_alias_test_SOURCES): New variable. | |
139 | (weak_alias_test_DEPENDENCIES): New variable. | |
140 | (weak_alias_test_LDFLAGS): New variable. | |
141 | (weak_alias_test_LDADD): New variable. | |
142 | (weak_alias_test_1_pic.o, weak_alias_test_1.so): New targets. | |
143 | (weak_alias_test_2_pic.o, weak_alias_test_2.so): New targets. | |
144 | (weak_alias_test_3.o): New target. | |
145 | (weak_alias_test_4_pic.o, weak_alias_test_4.so): New targets. | |
146 | * testsuite/weak_alias_test_main.cc: New file. | |
147 | * testsuite/weak_alias_test_1.cc: New file. | |
148 | * testsuite/weak_alias_test_2.cc: New file. | |
149 | * testsuite/weak_alias_test_3.cc: New file. | |
150 | ||
780e49c5 ILT |
151 | 2008-04-08 Ian Lance Taylor <iant@google.com> |
152 | ||
cdb0b8f5 ILT |
153 | * options.h (class General_options): Add --noinhibit-exec option. |
154 | * main.cc (main): Check --noinhibit-exec. | |
155 | ||
0864d551 ILT |
156 | * options.h (class General_options): Define --wrap as a special |
157 | option. Add wrap_symbols_ field. | |
158 | (General_options::any_wrap_symbols): New function. | |
159 | (General_options::is_wrap_symbol): New function. | |
160 | * options.cc (General_options::parse_wrap): New function. | |
161 | (General_options::General_options): Initialize wrap_symbols_. | |
162 | * symtab.cc (Symbol_table::wrap_symbol): New function. | |
163 | (Symbol_table::add_from_object): Handle --wrap. | |
164 | * symtab.h (class Symbol_table): Declare wrap_symbol. | |
165 | * target.h (Target::wrap_char): New function. | |
166 | (Target::Target_info): Add wrap_char field. | |
167 | * i386.cc (Target_i386::i386_info): Initialize wrap_char. | |
168 | * x86_64.cc (Target_x86_64::x86_64_info): Likewise. | |
169 | * testsuite/testfile.cc (Target_test::test_target_info): | |
170 | Likewise. | |
171 | ||
789aa6de ILT |
172 | * errors.cc (Errors::undefined_symbol): Mention symbol version if |
173 | there is one. | |
174 | ||
2c38906f ILT |
175 | * layout.h (class Layout): Add added_eh_frame_data_ field. |
176 | * layout.cc (Layout::Layout): Initialize new field. | |
177 | (Layout::layout_eh_frame): Don't add eh_frame_data_ to .eh_frame | |
178 | output section until we find a section we merged successfully. | |
179 | * object.cc (Sized_relobj::check_eh_frame_flags): Don't require | |
180 | that the size be non-zero. | |
181 | ||
780e49c5 ILT |
182 | * merge.cc (Object_merge_map::get_output_offset): Remove inline |
183 | qualifier. | |
184 | ||
7fcd0256 ILT |
185 | 2008-04-08 Craig Silverstein <csilvers@google.com> |
186 | ||
187 | * configure.ac: Export new conditional variable HAVE_ZLIB. | |
188 | * testsuite/Makefile.am (flagstest_o_specialfile): Condition | |
189 | on HAVE_ZLIB. | |
190 | (flagstest_o_specialfile_and_compress_debug_sections): Likewise. | |
191 | * configure, Makefile.in, testsuite/Makefile.in: Rebuild. | |
192 | ||
6835af53 ILT |
193 | 2008-04-07 Ian Lance Taylor <iant@google.com> |
194 | ||
e24f324c ILT |
195 | * version.cc (version_string): Set to "1.5". |
196 | ||
a036edd8 ILT |
197 | * x86_64.cc (Target_x86_64::Scan): Change from struct to class. |
198 | Add issued_non_pic_error_ field. Declare check_non_pic. | |
199 | (Target_x86_64::Scan::check_non_pic): New function. | |
200 | (Target_x86_64::Scan::local): Call check_non_pic as appropriate. | |
201 | (Target_x86_64::Scan::global): Likewise. | |
202 | ||
624f8810 ILT |
203 | * output.cc (Output_reloc<SHT_REL>::local_section_offset): Add |
204 | addend parameter. Change caller. Handle merge sections. | |
205 | (Output_reloc<SHT_REL>::symbol_value): Change parameter type from | |
206 | Address to Addend. Don't add in the result of | |
207 | local_section_offset, pass down the addend and use the returned | |
208 | value. | |
209 | * output.h (class Output_reloc<SHT_REL>): Add Addend typedef. | |
210 | Update declarations of local_section_offset and symbol_value. | |
211 | * testsuite/two_file_test_1.cc (t18): New function. | |
212 | * testsuite/two_file_test_2.cc (f18): New function. | |
213 | * testsuite/two_file_test_main.cc (main): Call t18. | |
214 | * testsuite/two_file_test.h (t18, f18): Declare. | |
215 | ||
6835af53 ILT |
216 | * configure.ac: Don't test for objdump, c++filt, or readelf. |
217 | * testsuite/Makefile.am: Remove READELF and OBJDUMP_AND_CPPFILT | |
218 | conditionals. | |
219 | (TEST_READELF): New variable. | |
220 | (TEST_OBJDUMP, TEST_CXXFILT, TEST_STRIP): New variables. | |
221 | (check_PROGRAMS): Add two_file_strip_test. | |
222 | (two_file_strip_test): New target. | |
223 | (check_PROGRAMS): Add two_file_same_shared_strip_test. | |
224 | (two_file_same_shared_strip_test_SOURCES): New variable. | |
225 | (two_file_same_shared_strip_test_DEPENDENCIES): New variable. | |
226 | (two_file_same_shared_strip_test_LDFLAGS): New variable. | |
227 | (two_file_same_shared_strip_test_LDADD): New variable. | |
228 | (two_file_shared_strip.so): New target. | |
229 | (ver_test_2.syms, ver_test_4.syms): Use TEST_READELF. | |
230 | (ver_test_5.syms, ver_test_7.syms): Likewise. | |
231 | (ver_matching_test.stdout): Use TEST_OBJDUMP and TEST_CXXFILT. | |
232 | (strip_test_3.stdout): Use TEST_OBJDUMP. | |
233 | * configure, Makefile.in, testsuite/Makefile.in: Rebuild. | |
234 | ||
86925eef CC |
235 | 2008-04-04 Cary Coutant <ccoutant@google.com> |
236 | ||
237 | * symtab.h (Symbol::is_weak_undefined): New function. | |
238 | (Symbol::is_strong_undefined): New function. | |
239 | (Symbol::is_absolute): New function. | |
240 | (Symbol::needs_plt_entry): Exclude weak undefined symbols. | |
241 | (Symbol::needs_dynamic_reloc): Exclude weak undefined and | |
242 | absolute symbols. | |
243 | * testsuite/Makefile.am (check_PROGRAMS): Add weak_undef_test. | |
244 | (weak_undef_test): New target. | |
245 | * testsuite/Makefile.in: Rebuild. | |
246 | * testsuite/weak_undef_file1.cc: New file. | |
247 | * testsuite/weak_undef_file2.cc: New file. | |
248 | * testsuite/weak_undef_test.cc: New file. | |
249 | ||
126f3ece ILT |
250 | 2008-04-03 Craig Silverstein <csilvers@google.com> |
251 | ||
252 | * compressed_output.h (class Output_compressed_section): Use | |
253 | unsigned buffer. | |
254 | * compressed_output.cc (zlib_compress): Use unsigned buffers, | |
255 | add zlib header. | |
256 | (zlib_compressed_suffix): Removed. | |
257 | (Output_compressed_section::set_final_data_size): Use unsigned | |
258 | buffers. | |
259 | * testsuite/Makefile.am (flagstest_compress_debug_sections): | |
260 | Fix linker invocation. | |
261 | (flagstest_o_specialfile_and_compress_debug_sections): | |
262 | Likewise. | |
263 | * testsuite/Makefile.in: Regenerated. | |
264 | ||
deae2a14 DM |
265 | 2008-04-02 David S. Miller <davem@davemloft.net> |
266 | ||
267 | * dwarf_reader.cc (Sized_dwarf_line_info::read_header_prolog, | |
268 | Sized_dwarf_line_info::process_one_opcode): Use Swap_unaligned. | |
269 | ||
70752818 ILT |
270 | 2008-04-02 Craig Silverstein <csilvers@google.com> |
271 | ||
272 | * TODO: New file. | |
273 | ||
39d0cb0e ILT |
274 | 2008-04-02 Ian Lance Taylor <iant@google.com> |
275 | ||
276 | * fileread.cc (File_read::find_view): Add byteshift and vshifted | |
277 | parameters. Update for new key type to views_. Change all | |
278 | callers. | |
279 | (File_read::read): Adjust for byteshift in returned view. | |
280 | (File_read::add_view): New function, broken out of | |
281 | find_and_make_view. | |
282 | (File_read::make_view): New function, broken out of | |
283 | find_and_make_view. | |
284 | (File_read::find_or_make_view): Add offset and aligned | |
285 | parameters. Rewrite accordingly. Change all callers. | |
286 | (File_read::get_view): Add offset and aligned parameters. Adjust | |
287 | for byteshift in return value. | |
288 | (File_read::get_lasting_view): Likewise. | |
289 | * fileread.h (class File_read): Update declarations. | |
290 | (class File_read::View): Add byteshift_ field. Add byteshift to | |
291 | constructor. Add byteshift method. | |
292 | * archive.h (Archive::clear_uncached_views): New function. | |
293 | (Archive::get_view): Add aligned parameter. Change all callers. | |
294 | * object.h (Object::get_view): Add aligned parameter. Change all | |
295 | callers. | |
296 | (Object::get_lasting_view): Likewise. | |
297 | ||
298 | * fileread.cc (File_read::release): Don't call clear_views if | |
299 | there are multiple objects. | |
300 | * fileread.h (File_read::clear_uncached_views): New function. | |
301 | * archive.cc (Add_archive_symbols::run): Call clear_uncached_views | |
302 | on the archive. | |
303 | ||
a1207466 CC |
304 | 2008-03-31 Cary Coutant <ccoutant@google.com> |
305 | ||
306 | Add thin archive support. | |
307 | * archive.cc (Archive::armagt): New const. | |
308 | (Archive::setup): Remove task parameter and calls to unlock. | |
309 | (Archive::unlock_nested_archives): New function. | |
310 | (Archive::read_header): Add nested_off parameter. Change | |
311 | all callers. | |
312 | (Archive::interpret_header): Likewise. | |
313 | (Archive::include_all_members): Change to handle thin | |
314 | archives. | |
315 | (Archive::include_member): Likewise. | |
316 | * archive.h (Archive::Archive): Add new parameters and | |
317 | initializers. | |
318 | (Archive::armagt): New const. | |
319 | (Archive::setup): Remove task parameter. | |
320 | (Archive::unlock_nested_archives): New function. | |
321 | (Archive::read_header): Add nested_off parameter. | |
322 | (Archive::interpret_header): Likewise. | |
323 | (Archive::Nested_archive_table): New typedef. | |
324 | (Archive::is_thin_archive_): New field. | |
325 | (Archive::nested_archives_): New field. | |
326 | (Archive::options_): New field. | |
327 | (Archive::dirpath_): New field. | |
328 | (Archive::task_): New field. | |
329 | * readsyms.cc (Read_symbols::do_read_symbols): Add check | |
330 | for thin archives. Pass additional parameters to | |
331 | Archive::Archive. Unlock the archive file after calling | |
332 | Archive::setup. | |
333 | ||
479f6503 ILT |
334 | 2008-03-29 Ian Lance Taylor <iant@google.com> |
335 | ||
686c8caf ILT |
336 | * symtab.cc (Symbol_table::do_define_as_constant): Don't force a |
337 | version symbol to be local. | |
338 | * testsuite/ver_test_4.sh: New file. | |
339 | * testsuite/Makefile.am (check_SCRIPTS): Add ver_test_4.sh. | |
340 | (check_DATA): Add ver_test_4.syms. | |
341 | (ver_test_4.syms): New target. | |
342 | * testsuite/Makefile.in: Rebuild. | |
343 | ||
ab794b6b ILT |
344 | * output.cc |
345 | (Output_section::Input_section_sort_entry::has_priority): New | |
346 | function. | |
347 | (Output_section::Input_section_sort_entry::match_file_name): New | |
348 | function. | |
349 | (Output_section::Input_section_sort_entry::match_section_name): | |
350 | Remove. | |
351 | (Output_section::Input_section_sort_entry::match_section_name_prefix): | |
352 | Remove. | |
353 | (Output_section::Input_section_sort_entry::match_section_file): | |
354 | Remove. | |
355 | (Output_section::Input_section_sort_compare::operator()): Rewrite | |
356 | using new Input_section_sort_entry functions. Sort crtbegin and | |
357 | crtend first. Sort sections with no priority before sections with | |
358 | a priority. | |
359 | * testsuite/initpri1.c (d3): Check j != 4. | |
360 | (cd5): New constructor/destructor function. | |
361 | (main): Check j != 2. | |
362 | ||
479f6503 ILT |
363 | * symtab.cc (Symbol_table::add_from_object): If we don't use the |
364 | new symbol when resolving, don't call set_is_default. | |
365 | * testsuite/ver_test_7.cc: New file. | |
366 | * testsuite/ver_test_7.sh: New file. | |
367 | * testsuite/Makefile.am (ver_test_7.so): New target. | |
368 | (ver_test_7.o): New target. | |
369 | (check_SCRIPTS): Add ver_test_7.sh. | |
370 | (check_DATA): Add ver_test_7.syms. | |
371 | (ver_test_7.syms): New target. | |
372 | ||
2fd32231 ILT |
373 | 2008-03-28 Ian Lance Taylor <iant@google.com> |
374 | ||
375 | * layout.cc (Layout::layout): If we see an input section with a | |
376 | name that needs sorting, set the must_sort flag for the output | |
377 | section. | |
378 | (Layout::make_output_section): If the name of the output section | |
379 | indicates that it might require sorting, set the may_sort flag. | |
380 | * output.h (Output_section::may_sort_attached_input_sections): New | |
381 | function. | |
382 | (Output_section::set_may_sort_attached_input_sections): New | |
383 | function. | |
384 | (Output_section::must_sort_attached_input_sections): New | |
385 | function. | |
386 | (Output_section::set_must_sort_attached_input_sections): New | |
387 | function. | |
388 | (class Output_section): Declare Input_section_sort_entry. Define | |
389 | Input_section_sort_compare. Declare | |
390 | sort_attached_input_sections. Add new fields: | |
391 | may_sort_attached_input_sections_, | |
392 | must_sort_attached_input_sections_, | |
393 | attached_input_sections_are_sorted_. | |
394 | * output.cc (Output_section::Output_section): Initialize new | |
395 | fields. | |
396 | (Output_section::add_input_section): Add an entry to | |
397 | input_sections_ if may_sort or must_sort are true. | |
398 | (Output_section::set_final_data_size): Call | |
399 | sort_attached_input_sections if necessary. | |
400 | (Output_section::Input_section_sort_entry): Define new class. | |
401 | (Output_section::Input_section_sort_compare::operator()): New | |
402 | function. | |
403 | (Output_section::sort_attached_input_sections): New function. | |
404 | * configure.ac: Check whether the compiler supports constructor | |
405 | priorities. Define a CONSTRUCTOR_PRIORITY automake conditional. | |
406 | * testsuite/initpri1.c: New file. | |
407 | * testsuite/Makefile.am (check_PROGRAMS): Add initpri1 if | |
408 | CONSTRUCTOR_PRIORITY. | |
409 | (initpri1_SOURCES, initpri1_DEPENDENCIES): New variables. | |
410 | (initpri1_LDFLAGS): New variable. | |
411 | * configure, Makefile.in, testsuite/Makefile.in: Rebuild. | |
412 | ||
18e6b24e ILT |
413 | 2008-03-27 Ian Lance Taylor <iant@google.com> |
414 | ||
49bdd526 ILT |
415 | * common.cc (Sort_commons::operator): Correct sorting algorithm. |
416 | * testsuite/common_test_1.c: New file. | |
417 | * testsuite/Makefile.am (check_PROGRAMS): Add common_test_1. | |
418 | (common_test_1_SOURCES): New variable. | |
419 | (common_test_1_DEPENDENCIES): New variable. | |
420 | (common_test_1_LDFLAGS): New variable. | |
421 | ||
18e6b24e ILT |
422 | * symtab.cc (Symbol_table::add_from_object): Handle saw_undefined_ |
423 | and commons_ correctly when NAME/VERSION does not override | |
424 | NAME/NULL. | |
425 | * testsuite/ver_test_6.c: New file. | |
426 | * testsuite/Makefile.am (check_PROGRAMS): Add ver_test_6 | |
427 | (ver_test_6_SOURCES, ver_test_6_DEPENDENCIES): New variables. | |
428 | (ver_test_6_LDFLAGS, ver_test_6_LDADD): New variables. | |
429 | ||
04bf7072 ILT |
430 | 2008-03-26 Ian Lance Taylor <iant@google.com> |
431 | ||
5871526f ILT |
432 | * symtab.cc (Symbol_table::add_from_relobj): Don't set the version |
433 | of an undefined symbol from a version script. | |
434 | * testsuite/Makefile.am (ver_test_5.so): New target. | |
435 | (ver_test_5.o): New target. | |
436 | (check_SCRIPTS): Add ver_test_5.sh. | |
437 | (check_DATA): Add ver_test_5.syms. | |
438 | (ver_test_5.syms): New target. | |
439 | * testsuite/ver_test_5.cc: New file. | |
440 | * testsuite/ver_test_5.script: New file. | |
441 | * testsuite/ver_test_5.sh: New file. | |
442 | * Makefile.in, testsuite/Makefile.in: Rebuild. | |
443 | ||
04bf7072 ILT |
444 | PR gold/5986 |
445 | Fix problems building gold with gcc 4.3.0. | |
446 | * gold.h (TEMPLATE_ATTRIBUTE_PRINTF_4): Define. | |
447 | (gold_error_at_location, gold_warning_at_location): Use it. | |
448 | * configure.ac: Check whether we can compile and use a template | |
449 | function with a printf attribute. | |
450 | * x86_64.cc (Target_x86_64::do_code_fill): Swap out a 32-bit value | |
451 | when jumping over bytes. | |
452 | * object.cc: Instantiate Object::read_section_data. | |
453 | * debug.h: Include <cstring> | |
454 | * dwarf_reader.cc: Include <algorithm> | |
455 | * main.cc: Include <cstring>. | |
456 | * options.cc: Include <cstring>. | |
457 | * output.cc: Include <cstring>. | |
458 | * script.cc: Include <cstring>. | |
459 | * script.h: Include <string>. | |
460 | * symtab.cc: Include <cstring> and <algorithm>. | |
461 | * target-select.cc: Include <cstring>. | |
462 | * version.cc: Include <string>. | |
463 | * testsuite/testmain.cc: Include <cstdlib>. | |
464 | * configure, config.in: Rebuild. | |
465 | ||
874c5b28 ILT |
466 | 2008-03-25 Ian Lance Taylor <iant@google.com> |
467 | ||
819d6c3a ILT |
468 | * options.cc: Include "../bfd/bfdver.h". |
469 | (options::help): Print bug reporting address. | |
470 | ||
f4b2c6f5 ILT |
471 | * version.cc (print_version): Adjust output for current value of |
472 | BFD_VERSION_STRING. | |
473 | ||
474 | * NEWS: New file. | |
475 | ||
e96caa79 ILT |
476 | * options.cc (options::help): Print list of supported targets. |
477 | * target-select.h: Include <vector>. | |
478 | (class Target_selector): Make machine_, size_, and is_big_endian_ | |
479 | fields const. Add bfd_name_ and instantiated_target_ fields. | |
480 | (Target_selector::Target_selector): Add bfd_name parameter. | |
481 | (Target_selector::recognize): Make non-virtual, call | |
482 | do_recognize. | |
483 | (Target_selector::recognize_by_name): Make non-virtual, call | |
484 | do_recognize_by_name. | |
485 | (Target_selector::supported_names): New function. | |
486 | (Target_selector::bfd_name): New function. | |
487 | (Target_selector::do_instantiate_target): New pure virtual | |
488 | function. | |
489 | (Target_selector::do_recognize): New virtual function. | |
490 | (Target_selector::do_recognize_by_name): New virtual function. | |
491 | (Target_selector::instantiate_target): New private function. | |
492 | (supported_target_names): Declare. | |
493 | * target-select.cc (Target_selector::Target_selector): Update for | |
494 | new parameter and fields. | |
495 | (select_target_by_name): Check that the name matches before | |
496 | calling recognize_by_name. | |
497 | (supported_target_names): New function. | |
498 | * i386.cc (class Target_selector_i386): Update Target_selector | |
499 | constructor call. Remove recognize and recognize_by_name. Add | |
500 | do_instantiate_target. | |
501 | * x86_64.cc (class Target_selector_x86_64): Likewise. | |
502 | * testsuite/testfile.cc (class Target_selector_test): Update for | |
503 | changes to Target_selector. | |
504 | ||
874c5b28 ILT |
505 | * README: Rewrite, with some notes on unsupported features. |
506 | ||
0a65a3a7 CC |
507 | 2008-03-24 Cary Coutant <ccoutant@google.com> |
508 | ||
509 | * i386.cc (Target_i386::Got_type): New enum declaration. | |
510 | (Target_i386::Scan::local): Updated callers of Output_data_got | |
511 | member functions. | |
512 | (Target_i386::Scan::global): Likewise. | |
513 | (Target_i386::Relocate::relocate): Likewise. | |
514 | (Target_i386::Relocate::relocate_tls): Likewise. | |
515 | * object.h (Got_offset_list): New class. | |
516 | (Sized_relobj::local_has_got_offset): Added got_type parameter. | |
517 | (Sized_relobj::local_got_offset): Likewise. | |
518 | (Sized_relobj::set_local_got_offset): Likewise. | |
519 | (Sized_relobj::local_has_tls_got_offset): Removed. | |
520 | (Sized_relobj::local_tls_got_offset): Removed. | |
521 | (Sized_relobj::set_local_tls_got_offset): Removed. | |
522 | (Sized_relobj::Local_got_offsets): Changed to store a list of offsets. | |
523 | * output.cc (Output_data_got::add_global): Added got_type parameter. | |
524 | (Output_data_got::add_global_with_rel): Likewise. | |
525 | (Output_data_got::add_global_with_rela): Likewise. | |
526 | (Output_data_got::add_global_pair_with_rel): New function. | |
527 | (Output_data_got::add_global_pair_with_rela): New function. | |
528 | (Output_data_got::add_local): Added got_type parameter. | |
529 | (Output_data_got::add_local_with_rel): Likewise. | |
530 | (Output_data_got::add_local_with_rela): Likewise. | |
531 | (Output_data_got::add_local_pair_with_rel): New function. | |
532 | (Output_data_got::add_local_pair_with_rela): New function. | |
533 | (Output_data_got::add_global_tls): Removed. | |
534 | (Output_data_got::add_global_tls_with_rel): Removed. | |
535 | (Output_data_got::add_global_tls_with_rela): Removed. | |
536 | (Output_data_got::add_local_tls): Removed. | |
537 | (Output_data_got::add_local_tls_with_rel): Removed. | |
538 | (Output_data_got::add_local_tls_with_rela): Removed. | |
539 | * output.h (Output_data_got::add_global): Added got_type parameter. | |
540 | (Output_data_got::add_global_with_rel): Likewise. | |
541 | (Output_data_got::add_global_with_rela): Likewise. | |
542 | (Output_data_got::add_global_pair_with_rel): New function. | |
543 | (Output_data_got::add_global_pair_with_rela): New function. | |
544 | (Output_data_got::add_local): Added got_type parameter. | |
545 | (Output_data_got::add_local_with_rel): Likewise. | |
546 | (Output_data_got::add_local_with_rela): Likewise. | |
547 | (Output_data_got::add_local_pair_with_rel): New function. | |
548 | (Output_data_got::add_local_pair_with_rela): New function. | |
549 | (Output_data_got::add_global_tls): Removed. | |
550 | (Output_data_got::add_global_tls_with_rel): Removed. | |
551 | (Output_data_got::add_global_tls_with_rela): Removed. | |
552 | (Output_data_got::add_local_tls): Removed. | |
553 | (Output_data_got::add_local_tls_with_rel): Removed. | |
554 | (Output_data_got::add_local_tls_with_rela): Removed. | |
555 | * resolve.cc (Symbol::override_base_with_special): Removed | |
556 | reference to has_got_offset_ field. | |
557 | * symtab.cc (Symbol::init_fields): Replaced initialization | |
558 | of got_offset_ with got_offsets_. Removed initialization | |
559 | of has_got_offset_ | |
53fcba31 | 560 | * symtab.h (Symbol::has_got_offset): Aded got_type parameter. |
0a65a3a7 CC |
561 | (Symbol::got_offset): Likewise. |
562 | (Symbol::set_got_offset): Likewise. | |
563 | (Symbol::has_tls_got_offset): Removed. | |
564 | (Symbol::tls_got_offset): Removed. | |
565 | (Symbol::set_tls_got_offset): Removed. | |
566 | (Symbol::got_offset_): Removed. | |
567 | (Symbol::tls_mod_got_offset_): Removed. | |
568 | (Symbol::tls_pair_got_offset_): Removed. | |
569 | (Symbol::got_offsets_): New field. | |
570 | (Symbol::has_got_offset): Removed. | |
571 | (Symbol::has_tls_mod_got_offset): Removed. | |
572 | (Symbol::has_tls_pair_got_offset): Removed. | |
573 | * x86_64.cc (Target_x86_64::Got_type): New enum declaration. | |
574 | (Target_x86_64::Scan::local): Updated callers of Output_data_got | |
575 | member functions. | |
576 | (Target_x86_64::Scan::global): Likewise. | |
577 | (Target_x86_64::Relocate::relocate): Likewise. | |
578 | (Target_x86_64::Relocate::relocate_tls): Likewise. | |
579 | ||
bd52eafb BE |
580 | 2008-03-25 Ben Elliston <bje@au.ibm.com> |
581 | ||
582 | * yyscript.y: Fix spelling error in comment. | |
583 | ||
8b105e34 ILT |
584 | 2008-03-24 Ian Lance Taylor <iant@google.com> |
585 | ||
8ed814a9 ILT |
586 | * options.h (class General_options): Define build_id option. |
587 | * layout.h (class Layout): Declare write_build_id, create_note, | |
588 | create_build_id. Add build_id_note_ member. | |
589 | * layout.cc: Include <cerrno>, <fcntl.h>, <unistd.h>, | |
590 | "libiberty.h", "md5.h", "sha1.h". | |
591 | (Layout::Layout): Initialize eh_frame_data_, | |
592 | eh_frame_hdr_section_, and build_id_note_. | |
593 | (Layout::finalize): Call create_build_id. | |
594 | (Layout::create_note): New function, broken out of | |
595 | Layout::create_gold_note. | |
596 | (Layout::create_gold_note): Call create_note. | |
597 | (Layout::create_build_id): New function. | |
598 | (Layout::write_build_id): New function. | |
599 | (Close_task_runner::run): Call write_build_id. | |
600 | ||
8b105e34 ILT |
601 | * x86_64.cc: Correct license to GPLv3. |
602 | ||
086a1841 ILT |
603 | 2008-03-23 Ian Lance Taylor <iant@google.com> |
604 | ||
605 | * options.cc: Include "demangle.h". | |
606 | (parse_optional_string): New function. | |
607 | (parse_long_option): Handle takes_optional_argument. | |
608 | (parse_short_option): Update dash_z initializer. Handle | |
609 | takes_optional_argument. | |
610 | (General_options::General_options): Initialize do_demangle_. | |
611 | (General_options::finalize): Set do_demangle_. Handle demangling | |
612 | style. | |
613 | * options.h (parse_optional_string): Declare. | |
614 | (struct One_option): Add optional_arg field. Update constructor. | |
615 | Update call constructor calls. Add takes_optional_argument | |
616 | function. | |
617 | (DEFINE_var): Add optional_arg__ parameter. Change all callers. | |
618 | (DEFINE_optional_string): Define. | |
619 | (General_options::demangle): Change from DEFINE_bool to | |
620 | DEFINE_optional_string. | |
621 | (General_options::no_demangle): New function. | |
622 | (General_options::do_demangle): New function. | |
623 | (General_options::set_do_demangle): New function. | |
624 | (General_options::execstack_status_): Move definition to end of | |
625 | class definition. | |
626 | (General_options::static_): Likewise. | |
627 | (General_options::do_demangle_): New field. | |
628 | * object.cc (big_endian>::get_symbol_location_info): Call | |
629 | Options::do_demangle, not Options::demangle. | |
630 | * symtab.cc (demangle): Likewise. | |
631 | ||
cbb93e63 ILT |
632 | 2008-03-22 Ian Lance Taylor <iant@google.com> |
633 | ||
634 | * gold.h: Include <cstddef> and <sys/types.h> | |
635 | * options.h: Include <cstring>. | |
636 | ||
ec531623 ILT |
637 | 2008-03-21 Ian Lance Taylor <iant@google.com> |
638 | ||
639 | * Added source code to GNU binutils. | |
640 |