1 2010-07-10 Andi Kleen <ak@linux.intel.com>
4 * lto-plugin.c (sym_aux): Add.
5 (plugin_symtab): Remove slots. Add aux and id.
6 (parse_table_entry): Change to use aux instead of slots.
7 (LTO_SECTION_PREFIX): Add.
8 (translate): Improve buffer allocation. Change to append
9 symbols to existing out buffer.
10 (get_section): Remove.
11 (process_symtab): Add.
12 (free_2): Free symtab->aux.
13 (write_resolution): Handle aux instead of slots.
14 Print sub id to resolution file.
15 (claim_file_handler): Clear lto_file. Replace get_symtab/translate
16 calls with call to process_symtab.
18 2010-07-22 Richard Guenther <rguenther@suse.de>
20 * Makefile.am: New copy_lto_plugin rule to install the plugin
22 * Makefile.in: Regenerated.
24 2010-05-21 Richard Guenther <rguenther@suse.de>
26 * lto-plugin.c (write_resolution): Do not assert syms is non-NULL.
28 2010-05-07 Richard Guenther <rguenther@suse.de>
30 * lto-plugin.c (free_2): Do not free resolution_file.
31 (write_resolution): Check that we were passed a resolution file.
32 (all_symbols_read_handler): Adjust.
33 (cleanup_handler): Do not remove the resolution file.
34 (process_option): Handle -fresolution=.
36 2010-05-04 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
39 * configure.ac (AM_INIT_AUTOMAKE): Add no-dist.
40 * Makefile.in: Regenerate.
42 2010-04-23 Richard Guenther <rguenther@suse.de>
45 * lto-plugin.c (parse_table_entry): Use xstrdup and xrealloc.
46 (translate): Likewise.
47 (all_symbols_read_handler): Likewise.
48 (claim_file_handler): Likewise.
49 (process_option): Likewise.
50 (add_output_files): Likewise. Remove filename length limit.
52 2010-04-02 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
54 * Makefile.in: Regenerate.
55 * aclocal.m4: Regenerate.
57 2010-03-16 Dmitry Gorbachev <d.g.gorbachev@gmail.com>
60 * lto-plugin.c (cleanup_handler): Delete temporary output files.
62 2010-01-11 Richard Guenther <rguenther@suse.de>
65 * Makefile.am: Disable dependencies.
66 * Makefile.in: Regenerated.
68 2010-01-03 H.J. Lu <hongjiu.lu@intel.com>
71 * lto-plugin.c (exec_lto_wrapper): Output lto-wrapper command
74 2009-12-05 H.J. Lu <hongjiu.lu@intel.com>
77 * configure: Regenerated.
78 * Makefile.in: Likewise.
80 2009-11-19 Rafael Avila de Espindola <espindola@google.com>
83 * lto-plugin.c (claim_file_handler): Print offsets in hex.
85 2009-11-12 Rafael Avila de Espindola <espindola@google.com>
87 * lto-plugin.c (write_resolution): Assume resolution_file is set.
88 Print the symbol name.
89 (all_symbols_read_handler): Create a resolution file.
91 (cleanup_handler): Remove the resolution file.
92 (process_option): Drop the -resolution option.
94 2009-11-05 Rafael Avila de Espindola <espindola@google.com>
96 * lto-plugin.c (temp_obj_dir_name): Remove.
97 (arguments_file_name): New.
98 (free_2): Free arguments_file_name instead of temp_obj_dir_name.
99 (exec_lto_wrapper): Create arguments file with make_temp_file.
100 (cleanup_handler): Don't remove the temporary directory. Remove the
102 (onload): Don't create the temporary directory.
104 2009-11-04 Richard Guenther <rguenther@suse.de>
105 Rafael Avila de Espindola <espindola@google.com>
107 * lto-plugin.c (plugin_file_info): Remove temp field.
108 (cleanup_handler): Don't delete temporary objects.
109 (claim_file_handler): Don't create temporary objects.
111 2009-11-04 Rafael Avila de Espindola <espindola@google.com>
113 * lto-plugin.c (cleanup_handler): Don't cleanup if debugging.
115 2009-10-30 Rafael Avila de Espindola <espindola@google.com>
118 * lto-plugin.c (claim_file_handler): Close files that we created.
120 2009-10-28 Rafael Avila de Espindola <espindola@google.com>
122 * lto-plugin.c (all_symbols_read_handler): Use LDPL_FATAL instead of
125 2009-10-27 Dmitry Gorbachev <d.g.gorbachev@gmail.com>
128 * configure.ac: Call AC_SYS_LARGEFILE before AC_OUTPUT.
129 * configure: Regenerate.
131 2009-10-26 Richard Guenther <rguenther@suse.de>
133 * configure.ac: Use AM_MAINTAINER_MODE.
134 * acinclude.m4: Remove.
135 * configure: Re-generate.
136 * Makefile.in: Likewise.
137 * aclocal.m4: Likewise.
139 2009-10-19 Rafael Avila de Espindola <espindola@google.com>
142 * configure: Regenerate.
143 * configure.ac: Add AC_TYPE_UINT64_T.
145 2009-10-16 Rafael Avila de Espindola <espindola@google.com>
147 * lto-plugin.c (message): New variable.
148 (check): New function.
149 (parse_table_entry, translate, write_resolution,add_output_files,
150 exec_lto_wrapper,claim_file_handler, onload): Use check instead of
152 (cleanup_handler): Use check instead of assert. Remove the arguments
155 2009-10-15 Rafael Avila de Espindola <espindola@google.com>
157 * lto-plugin.c (resolution_file): New.
158 (free_1): Update comment.
159 (free_2): Free resolution_file.
160 (write_resolution): Write resolution to specified file. Use the
161 syms array from the symbol table.
162 (all_symbols_read_handler): Delay call to free_1 past call to
164 (process_option): Add a -resolution option.
166 2009-10-13 Richard Guenther <rguenther@suse.de>
168 * Makefile.am (liblto_plugin_la_LIBADD): Link against the
170 * Makefile.in: Regenerated.
172 2009-10-08 Rafael Avila de Espindola <espindola@google.com>
174 * lto-plugin.c (add_input_library): New.
175 (all_symbols_read_handler): Use add_input_library for items that
177 (process_option): Fit in 80 columns.
178 (onload): Handle LDPT_ADD_INPUT_LIBRARY.
180 2009-10-02 Diego Novillo <dnovillo@google.com>
182 * Makefile.am (AM_CPPFLAGS): Remove -D_LARGEFILE_SOURCE
183 and -D_FILE_OFFSET_BITS=64.
184 * configure.ac: Add AC_SYS_LARGEFILE.
185 * configure: Regenerate.
186 * Makefile.in: Regenerate.
187 * lto-plugin.c: Fix copyright boilerplate.
189 2009-10-02 Diego Novillo <dnovillo@google.com>
191 * Makefile.am (ACLOCAL_AMFLAGS): Define.
192 * aclocal.m4: Regenerate with aclocal-2.64
193 * acinclude.m4: Remove.
194 * Makefile.in: Regenerate with automake-1.11
195 * configure.ac (AC_PREREQ): Update to 2.64.
196 * configure: Regenerate.
198 2009-10-02 Diego Novillo <dnovillo@google.com>
200 * Makefile.am (AM_CPPFLAGS): Remove -D_LARGEFILE_SOURCE
201 and -D_FILE_OFFSET_BITS=64.
202 * configure.ac: Add AC_SYS_LARGEFILE.
203 * configure: Regenerate.
204 * Makefile.in: Regenerate.
205 * lto-plugin.c: Fix copyright boilerplate.
207 2009-10-02 Diego Novillo <dnovillo@google.com>
209 * Makefile.am (ACLOCAL_AMFLAGS): Define.
210 * aclocal.m4: Regenerate with aclocal-2.64
211 * acinclude.m4: Remove.
212 * Makefile.in: Regenerate with automake-1.11
213 * configure.ac (AC_PREREQ): Update to 2.64.
214 * configure: Regenerate.
216 2009-10-02 Rafael Avila de Espindola <espindola@google.com>
218 * Makefile.am (liblto_plugin_la_SOURCES): Remove
219 $(top_srcdir)/../gcc/lto/common.c
220 * Makefile.in: Regenerate.
222 2009-10-01 Rafael Avila de Espindola <espindola@google.com>
224 * lto-plugin.c (pass_through_items): New.
225 (num_pass_through_items): New.
226 (all_symbols_read_handler): Update to use the -pass-through option.
227 (process_option): Replace -libgcc with -pass-through.
229 2009-09-30 Rafael Avila de Espindola <espindola@google.com>
231 * lto-plugin.c (onload): Return a ld_plugin_status. Don't require
232 register_cleanup to be set.
234 2009-09-30 Rafael Avila de Espindola <espindola@google.com>
236 * Makefile.am: Remove all reference to ltosymtab.
237 * Makefile.in: Regenerate.
238 * lto-symtab.c: Remove.
240 2009-05-21 Diego Novillo <dnovillo@google.com>
242 * configure.ac: Remove call to AC_CHECK_GELF.
243 Call AC_ARG_VAR for LIBELFLIBS and LIBELFINC.
244 * acinclude.m4: Do not include ../config/libelf.m4
245 * Makefile.am (LIBELFLIBS): Define.
247 (AM_CPPFLAGS): Add $(LIBELFINC).
248 (ltosymtab_LDADD): Add $(LIBELFLIBS).
249 (liblto_plugin_la_LIBADD): Add $(LIBELFLIBS)
250 * lto-plugin.c: Always include <gelf.h>
251 * lto-symtab.c: Likewise.
252 * configure: Regenerate.
253 * Makefile.in: Regenerate.
255 2009-03-23 Rafael Avila de Espindola <espindola@google.com>
257 * lto-plugin.c (libgcc_filename): New.
258 (all_symbols_read_handler): Pass libgcc to the linker.
259 (all_symbols_read_handler): Parse -libgcc
261 2009-02-05 Rafael Avila de Espindola <espindola@google.com>
263 * Makefile.am (liblto_plugin_la_LIBADD): Link with libiberty.
264 * Makefile.in: Regenerate.
265 * lto-plugin.c (add_output_files): Argument is now a FILE.
266 (exec_lto_wrapper): Use writeargv and pex.
268 2009-02-04 Rafael Avila de Espindola <espindola@google.com>
271 2009-02-04 Rafael Avila de Espindola <espindola@google.com>
272 * lto-plugin.c (exec_lto_wrapper): Use writeargv.
275 2009-02-04 Rafael Avila de Espindola <espindola@google.com>
277 * lto-plugin.c (exec_lto_wrapper): Use writeargv.
279 2009-01-29 Rafael Avila de Espindola <espindola@google.com>
281 * lto-plugin.c: Include libiberty.h.
282 (exec_lto_wrapper, claim_file_handler): Use asprintf instead of
285 2009-01-29 Rafael Avila de Espindola <espindola@google.com>
287 * lto-plugin.c (exec_lto_wrapper): Write argv to a file. Pass that
290 2009-01-28 Rafael Avila de Espindola <espindola@google.com>
292 * lto-plugin.c (plugin_file_info): Remove fd and elf.
293 (parse_table_entry): strdup entry->name and entry->comdat_key.
294 (free_1): Free name and comdat_key. Don't close the file. Don't call
296 (claim_file_handler): Always call elf_end.
298 2008-12-23 Rafael Avila de Espindola <espindola@google.com>
300 * Makefile.am (AM_CPPFLAGS): Add -D_LARGEFILE_SOURCE
301 -D_FILE_OFFSET_BITS=64
302 * Makefile.in: Regenerate
304 2008-12-22 Rafael Avila de Espindola <espindola@google.com>
306 * Makefile.am (gcc_version, target_noncanonical, libexecsubdir): New.
307 (lib_LTLIBRARIES): Rename to libexecsub_LTLIBRARIES.
308 * Makefile.in: Regenerate.
309 * acinclude.m4: Include ../config/acx.m4 and ../lt~obsolete.m4
310 * configure: Regenerate.
311 * configure.ac: Add AC_SUBST(target_noncanonical).
313 2008-12-08 Rafael Avila de Espindola <espindola@google.com>
315 * lto-plugin.c: Include stdbool.h.
316 (debug, nop): Declare as bool.
318 2008-12-08 Rafael Avila de Espindola <espindola@google.com>
320 * lto-plugin.c (nop): New.
321 (use_original_files): New.
322 (all_symbols_read_handler): Call use_original_files if nop is true.
323 (process_option): Parse the -nop option.
325 2008-12-08 Rafael Avila de Espindola <espindola@google.com>
327 * lto-plugin.c (debug): New.
328 (exec_lto_wrapper): Print argv if debug is true.
329 (process_option): Process the -debug command line option.
331 2008-12-03 Rafael Avila de Espindola <espindola@google.com>
333 * lto-plugin.c (process_option): The argument is now a single option,
334 not a space separated list.
336 2008-12-02 Rafael Avila de Espindola <espindola@google.com>
338 * lto-plugin.c: Include sys/types.h and sys/wait.h
339 (output_files, num_output_files, lto_wrapper_argv,
340 lto_wrapper_num_args): New.
341 (free_2): Free output_files.
342 (write_resolution): Disable.
343 (add_output_files): New.
344 (exec_lto_wrapper): New.
345 (all_symbols_read_handler): Run lto-wrapper.
346 (claim_file_handler): Free lto_file.name and call elf_end.
347 (process_option): New.
349 2008-11-26 Rafael Espindola <espindola@google.com>
351 * lto-plugin.c (add_input_file): New.
352 (get_section): Return NULL if get_section fails.
353 (write_resolution): New.
354 (all_symbols_read_handler): Call add_input_file.
355 (claim_file_handler): Unlink the correct file.
356 (onload): Record add_input_file.
358 2008-09-23 Rafael Espindola <espindola@google.com>
360 * Makefile.am (ltosymtab_SOURCES, liblto_plugin_la_SOURCES):
361 Update the location of common.c.
362 * Makefile.in: Regenerate.
363 * common.c: Moved to gcc/lto.
364 * common.h: Moved to gcc/lto.
365 * lto-plugin.c: Update the location of common.h.
366 * lto-symtab.c: Update the location of common.h.
368 2008-09-23 Rafael Espindola <espindola@google.com>
370 * common.c: Include common.h.
371 (lto_kind_str, lto_visibility_str, lto_resolution_str): Use explicit
373 * common.h (lto_kind_str, lto_visibility_str, lto_resolution_str): Use
376 2008-09-23 Rafael Espindola <espindola@google.com>
378 * lto-plugin.c (plugin_file_info): Add temp.
379 (cleanup_handler): Only delete temporary files.
380 (claim_file_handler): Initialize lto_file.temp.
382 2008-09-23 Rafael Espindola <espindola@google.com>
384 * plugin-api.h: Moved to include.
386 2008-09-23 Rafael Espindola <espindola@google.com>
388 * lto-plugin.c (all_symbols_read_handler): Print resolution in a new
391 2008-09-22 Rafael Espindola <espindola@google.com>
393 * plugin-api.h: Copy from binutils' cvs.
395 2008-09-22 Rafael Espindola <espindola@google.com>
397 * lto-symtab.c (get_symbols, add_symbols): Update signature.
398 * plugin-api.h: Copy from binutils' cvs.
400 2008-09-22 Rafael Espindola <espindola@google.com>
402 * common.h (lto_kind_str, lto_visibility_str, lto_resolution_str):
405 2008-09-10 Rafael Espindola <espindola@google.com>
407 * lto-plugin.c (onload): add missing break statements and asserts.
408 * lto-symtab.c (claim_file_handler): Make it static.
409 (all_symbols_read_handler): Make it static.
410 (all_file_handles): Make it static.
411 (num_file_handles): Make it static.
412 (register_claim_file): Make it static.
413 (register_object): Indent properly.
415 2008-09-10 Rafael Avila de Espindola <espindola@google.com>
417 * Makefile.am (ltosymtab_LDADD): Add -lelf.
418 * Makefiel.in: Regenerate.
419 * lto-plugin.c: Include ar.h.
420 (claim_file_handler): Handle file->offset != 0.
421 * lto-symtab.c: Include gelf.h.
422 (all_file_handles): Change type.
423 (register_object): New.
424 (register_file): Add support for archives.
425 (resolve): Update to new type of all_file_handles.
426 (print): Update to new type of all_file_handles.
427 (free_all): Update to new type of all_file_handles.
428 (main): Update to new type of all_file_handles.
430 2008-09-10 Rafael Avila de Espindola <espindola@google.com>
432 * lto-plugin.c (get_string_table): Remove.
433 (get_section): Use elf_strptr instead of get_string_table.
435 2008-09-08 Doug Kwan <dougkwan@google.com>
437 * lto-plugin.c (all_symbols_read_handler): Widen fprintf arguments
438 to 64-bit to fix a 32-bit bootstrap failure due to format warnings.
440 2008-09-08 Rafael Avila de Espindola <espindola@google.com>
442 * Makefile.am (ltosymtab_SOURCES): add common.c.
443 (ltosymtab_CFLAGS): New.
444 (liblto_plugin_la_SOURCES): Add common.c.
445 * Makefile.in: Regenerate.
448 * lto-plugin.c: Include stdio.h, inttypes.h and common.h.
449 (plugin_symtab): New.
450 (plugin_file_info): New.
451 (register_all_symbols_read): New.
453 (claimed_files): New.
454 (num_claimed_files): New.
455 (translate): Don't drop the slot number.
458 (all_symbols_read_handler): New.
459 (claim_file_handler): Record every claimed file.
460 (onload): Handle LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK and
462 * lto-symtab.c: Include stdlib.h, string.h and common.h.
463 (current_file_handle): Remove.
464 (ld_plugin_all_symbols_read_handler): New.
465 (plugin_handle): New.
467 (all_file_handles): New.
468 (num_file_handles): New.
470 (register_all_symbols_read): New.
471 (add_symbols): Don't print the symbols, just record them.
472 (ld_plugin_tv): Add LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK and
474 (load_plugin): Use plugin_handle.
475 (register_file): Add the file handle to all_file_handles.
478 (unload_plugin): New.
480 (main): Call all_symbols_read_handler and free resources.
482 2008-09-03 Rafael Avila de Espindola <espindola@google.com>
484 * Makefile.am (AM_CFLAGS): New.
485 (ltosymtab_LDADD): Remove -lelf. Add -ldl.
486 (lib_LTLIBRARIES): New.
487 (liblto_plugin_la_SOURCES): New.
488 (liblto_plugin_la_LIBADD): New.
489 * Makefile.in: Regenerate.
490 * acinclude.m4: Don't include ../config/acx.m4 and
491 ../config/no-executables.m4.
492 Include ../ltsugar.m4, ../ltoptions.m4, ../ltversion.m4 and
494 * aclocal.m4: Regenerate.
495 * configure: Regenerate.
496 * configure.ac: Use AM_PROG_LIBTOOL.
498 * lto-symtab.c: Rewrite to use the plugin.
501 2008-08-25 Rafael Avila de Espindola <espindola@google.com>
503 * configure: Regenerate.
504 * configure.ac: Use AC_CHECK_GELF.
505 * lto-symtab.c: Include gelf.h.
506 (get_string_table): Use size independent API.
507 (printTable): Use lld to print 64 bit integers.
509 2008-08-22 Rafael Avila de Espindola <espindola@google.com>
511 * lto-symtab.c (parse_table_entry): Assert entry->kind and
512 entry->visibility are valid.
514 2008-07-22 Rafael Avila de Espindola <espindola@google.com>
515 * lto-symtab.c (table_entry): Add comdat.
516 (parse_table_entry): Read comdat.
518 2008-08-21 Rafael Espindola <espindola@google.com>