1 2011-04-20 Jim Meyering <meyering@redhat.com>
3 * lto-plugin.c (free_1, free_2): Remove useless if-before-free.
5 2011-04-05 Richard Guenther <rguenther@suse.de>
8 * lto-plugin.c (claim_file_handler): Do not declare vars in code.
10 2011-02-13 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
12 * Makefile.in: Regenerate.
13 * aclocal.m4: Regenerate.
14 * configure: Regenerate.
16 2011-02-12 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18 * Makefile.am (all-local): Rename from 'all'.
19 * Makefile.in: Regenerate.
21 2011-02-12 Alexandre Oliva <aoliva@redhat.com>
24 * Makefile.am (gcc_build_dir, in_gcc_libs): New.
25 (liblto_plugin_la_LDFLAGS): Add -module.
26 (copy_lto_plugin): Renamed to...
27 ($(in_gcc_libs)): ... this. Add mkinstalldirs. Skip copying
29 * Makefile.in: Rebuild.
31 2011-02-07 Kai Tietz <kai.tietz@onevision.com>
34 * Makefile.am (Wc): New helper for encoding -Wc,.
35 (liblto_plugin_la_LIBADD): Use Wc for libiberty library.
36 (liblto_plugin_la_DEPENDENCIES): Special case pic libiberty.
37 * Makefile.in: Regenerated.
39 2011-02-07 Paolo Bonzini <bonzini@gnu.org>
43 2011-02-07 Kai Tietz <kai.tietz@onevision.com>
46 * Makefile.am (Wl): New helper for encoding -Wl,.
47 (liblto_plugin_la_LIBADD): Use -Wl for libiberty library.
48 * Makefile.in: Regenerated.
50 2011-02-07 Kai Tietz <kai.tietz@onevision.com>
53 * Makefile.am (Wl): New helper for encoding -Wl,.
54 (liblto_plugin_la_LIBADD): Use -Wl for libiberty library.
55 * Makefile.in: Regenerated.
57 2011-01-25 Ian Lance Taylor <iant@google.com>
59 * lto-plugin.c (gold_version): New static variable.
60 (all_symbols_read_handler): Don't check pass_through_items if
61 using gold 1.11 or later.
62 (onload): Set gold_version if we see LDPT_GOLD_VERSION.
64 2011-01-12 Richard Guenther <rguenther@suse.de>
67 * lto-plugin.c (parse_table_entry): Use memcpy to access
70 2010-12-20 Dave Korn <dave.korn.cygwin@gmail.com>
72 * Makefile.am (AM_LIBTOOLFLAGS): Define, adding disable-static tag.
73 * Makefile.in: Regenerate.
75 2010-12-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
79 2010-12-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
81 * Makefile.am (liblto_plugin_la_DEPENDENCIES): Define.
82 (liblto_plugin_la_LIBADD): Use -L../libiberty/pic -liberty.
83 (liblto_plugin_la_LDFLAGS): Use -L../libiberty -liberty.
84 * Makefile.in: Regenerate.
86 2010-12-10 Dave Korn <dave.korn.cygwin@gmail.com>
90 * configure.ac (SYM_STYLE): Don't AC_DEFINE.
91 * lto-plugin.c (sym_style): Don't use it; default to ss_none.
92 * configure: Regenerate.
93 * config.h.in: Likewise.
95 2010-12-06 Dave Korn <dave.korn.cygwin@gmail.com>
99 * configure.ac: Invoke ACX_LT_HOST_FLAGS.
100 * Makefile.am (liblto_plugin_la_LDFLAGS): Use lt_host_flags but
101 override -bindir setting.
102 * aclocal.m4: Regenerate.
103 * configure: Regenerate.
104 * Makefile.in: Regenerate.
106 2010-12-05 Kai Tietz <kai.tietz@onevision.com>
108 * config.h.in: Regenerated.
109 * configure: Regenerated.
110 * configure.ac (AC_CHECK_HEADERS): Replaced by AC_HEADER_SYS_WAIT.
111 * lto-plugin.c (WIFEXITED): Define default.
112 (WEXITSTATUS): Likeiwse.
114 2010-12-01 Kai Tietz <kai.tietz@onevision.com>
116 * config.h.in: Regenerated.
117 * configure: Regenerated.
118 * Makefile.in: Regenerated.
119 * configure.ac (AC_CHECK_HEADERS): Check for sys/wait.h.
120 * lto-plugin.c: Include sys/wait.h conditionally.
121 * aclocal.m4: Regenerated.
123 2010-11-13 Kai Tietz <kai.tietz@onevision.com>
125 * lto-plugin.c (add_output_files): Fix memory leak.
127 2010-11-11 Dave Korn <dave.korn.cygwin@gmail.com>
131 * configure.ac: Add AC_TYPE_INT64_T test.
132 * config.h.in: Regenerate.
133 * configure: Likewise.
134 * lto-plugin.c (debug): Use char not bool.
136 (check_1): Rename from check, and use int not bool for gate argument.
137 (check): Macro wrapper for the above to coerce gate argument into
138 boolean-valued integer in case it has pointer type.
139 (parse_table_entry): Use 0 not false.
140 (claim_file_handler): Avoid use of PRIx64 by splitting 64-bit size
141 into two 32-bit parts and printing as hex ints.
143 2010-11-03 Dave Korn <dave.korn.cygwin@gmail.com>
146 * lto-plugin.c (claim_file_handler): Don't close file descriptor.
148 2010-11-03 Dave Korn <dave.korn.cygwin@gmail.com>
151 * lto-plugin.h: Delete.
152 * lto-plugin-elf.c: Likewise.
153 * lto-plugin-coff.c: Likewise.
154 * configure.ac: Don't use libelf, don't source config.gcc.
155 (LIBELFLIBS): Delete.
157 (LTO_FORMAT): Delete.
158 (SYM_STYLE): Add AC_DEFINE var, set based on $target.
159 (config.h): Add AC_CONFIG_HEADERS directive.
160 * Makefile.am (LIBELFLIBS): Delete.
162 (LTO_FORMAT): Delete.
164 (AM_CPPFLAGS): Use it. Don't use LIBELFINC.
165 (liblto_plugin_la_SOURCES): Don't use LTO_FORMAT, don't include
166 any object-format-specific source file in the link.
167 (liblto_plugin_la_LIBADD): Don't use LIBELFLIBS.
168 * config.h.in: Generate.
169 * configure: Regenerate.
170 * Makefile.in: Likewise.
171 * lto-plugin.c (O_BINARY): Definition moved here from lto-plugin.h.
172 (LTO_SEGMENT_NAME): New definition.
173 (LTO_SECTION_PREFIX): Definition moved here from lto-plugin.h.
174 (LTO_SECTION_PREFIX_LEN): New definition.
175 (struct sym_aux): Struct definition moved here from lto-plugin.h.
176 (struct plugin_symtab): Likewise.
177 (struct plugin_objfile): Likewise.
178 (struct plugin_objfile): New struct def.
179 (enum symbol_style): New enum type.
180 (add_symbols): Make static.
181 (claimed_files): Likewise.
182 (num_claimed_files): Likewise.
183 (sym_style): New global.
184 (check): Make static.
185 (parse_table_entry): Likewise. Respect sym_style when extracting
186 symbol from symtab entry.
187 (translate): Make static.
188 (resolve_conflicts): Likewise.
189 (process_symtab): New function, per-section callback version of
190 old object-format-specific handling from deleted lto-plugin-elf.c.
191 (claim_file_handler): Convert ELF-specific version from deleted
192 lto-plugin-elf.c to simple_object interface and move here.
193 (process_options): Allow new '-sym-style=' option.
194 (onload): Don't call deleted onload_format_checks hook.
196 2010-10-11 Kai Tietz <kai.tietz@onevision.com>
198 * lto-plugin.c (dump_symtab): Correct printf argument type.
199 (finish_conflict_resolution): Initialize resolution.
201 2010-10-08 H.J. Lu <hongjiu.lu@intel.com>
204 * configure.ac: Add AC_CANONICAL_SYSTEM.
205 * configure: Regenerated.
207 2010-10-07 Dave Korn <dave.korn.cygwin@gmail.com>
209 * configure.ac: Source config.gcc to determine lto_binary_reader.
210 (LTO_FORMAT): New AC_SUBST variable inferred from lto_binary_reader.
211 * Makefile.am (LTO_FORMAT): Import.
212 (liblto_plugin_la_SOURCES): Add object format dependent module
213 defined by LTO_FORMAT.
214 (liblto_plugin_la_LIBADD): Allow for both PIC and non-PIC libiberty,
215 and work around libtool warning.
216 * configure: Regenerate.
217 * Makefile.in: Likewise.
218 * lto-plugin.c (struct sym_aux): Move to new lto-plugin.h.
219 (struct sym_aux): Likewise.
220 (struct plugin_symtab): Likewise.
221 (struct plugin_file_info): Likewise.
222 (LTO_SECTION_PREFIX): Likewise.
223 (add_symbols): Make non-static.
224 (claimed_files): Likewise.
225 (num_claimed_files): Likewise.
227 (parse_table_entry): Likewise.
228 (translate): Likewise.
229 (resolve_conflicts): Likewise.
230 (process_symtab): Move to new lto-plugin-elf.c object format dependent
232 (claim_file_handler): Likewise, and make non-static.
233 (onload): Call new onload_format_checks function.
234 * lto-plugin.h: New file.
235 (LTO_SECTION_PREFIX): Move here.
236 (struct sym_aux): Likewise.
237 (struct plugin_symtab): Likewise.
238 (struct plugin_file_info): Likewise.
239 (claim_file_handler): Add new function prototype.
240 (onload_format_checks): Likewise.
241 (check): Declare extern.
242 (translate): Likewise.
243 (parse_table_entry): Likewise.
244 (resolve_conflicts): Likewise.
245 (add_symbols): Likewise.
246 (claimed_files): Likewise.
247 (num_claimed_files): Likewise.
248 * lto-plugin-elf.c (process_symtab): Move here.
249 (claim_file_handler): Likewise, and make non-static.
250 (onload_format_checks): New function factored out from onload.
251 * lto-plugin-coff.c (claim_file_handler): New function stub.
252 (onload_format_checks): Likewise.
254 2010-08-05 Andi Kleen <ak@linux.intel.com>
256 * lto-plugin.c: Include <hashtab.h>
257 (sym_aux): Add next_conflict field to save conflict chains.
258 (plugin_file_info): Add conflicts symtab.
259 (parse_table_entry): Initialize aux->next_conflict.
260 (process_symtab): Increment found.
262 (finish_conflict_resolution): Add.
264 (write_resolution): Remove symbols loop and move into
265 dump_symtab. Call dump_symtab for main symbol and conflicts table.
266 Call free_symtab to free conflicts table.
270 (symbol_strength): Add.
271 (resolve_conflicts): Add.
272 (claim_file_handler): Add n variable. Check return value of
273 process_symtab. Call resolve_conflicts.
275 2010-07-27 Andi Kleen <ak@linux.intel.com>
277 * lto-plugin.c (translate): Remove debug fprintf.
279 2010-07-23 H.J. Lu <hongjiu.lu@intel.com>
282 * lto-plugin.c (translate): Cast to unsigned long.
284 2010-07-23 Andi Kleen <ak@linux.intel.com>
287 * lto-plugin.c (sym_aux): Add.
288 (plugin_symtab): Remove slots. Add aux and id.
289 (parse_table_entry): Change to use aux instead of slots.
290 (LTO_SECTION_PREFIX): Add.
291 (translate): Improve buffer allocation. Change to append
292 symbols to existing out buffer.
293 (get_section): Remove.
294 (process_symtab): Add.
295 (free_2): Free symtab->aux.
296 (write_resolution): Handle aux instead of slots.
297 Print sub id to resolution file.
298 (claim_file_handler): Clear lto_file. Replace get_symtab/translate
299 calls with call to process_symtab.
301 2010-07-22 Richard Guenther <rguenther@suse.de>
303 * Makefile.am: New copy_lto_plugin rule to install the plugin
305 * Makefile.in: Regenerated.
307 2010-05-21 Richard Guenther <rguenther@suse.de>
309 * lto-plugin.c (write_resolution): Do not assert syms is non-NULL.
311 2010-05-07 Richard Guenther <rguenther@suse.de>
313 * lto-plugin.c (free_2): Do not free resolution_file.
314 (write_resolution): Check that we were passed a resolution file.
315 (all_symbols_read_handler): Adjust.
316 (cleanup_handler): Do not remove the resolution file.
317 (process_option): Handle -fresolution=.
319 2010-05-04 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
322 * configure.ac (AM_INIT_AUTOMAKE): Add no-dist.
323 * Makefile.in: Regenerate.
325 2010-04-23 Richard Guenther <rguenther@suse.de>
328 * lto-plugin.c (parse_table_entry): Use xstrdup and xrealloc.
329 (translate): Likewise.
330 (all_symbols_read_handler): Likewise.
331 (claim_file_handler): Likewise.
332 (process_option): Likewise.
333 (add_output_files): Likewise. Remove filename length limit.
335 2010-04-02 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
337 * Makefile.in: Regenerate.
338 * aclocal.m4: Regenerate.
340 2010-03-16 Dmitry Gorbachev <d.g.gorbachev@gmail.com>
343 * lto-plugin.c (cleanup_handler): Delete temporary output files.
345 2010-01-11 Richard Guenther <rguenther@suse.de>
348 * Makefile.am: Disable dependencies.
349 * Makefile.in: Regenerated.
351 2010-01-03 H.J. Lu <hongjiu.lu@intel.com>
354 * lto-plugin.c (exec_lto_wrapper): Output lto-wrapper command
357 2009-12-05 H.J. Lu <hongjiu.lu@intel.com>
360 * configure: Regenerated.
361 * Makefile.in: Likewise.
363 2009-11-19 Rafael Avila de Espindola <espindola@google.com>
366 * lto-plugin.c (claim_file_handler): Print offsets in hex.
368 2009-11-12 Rafael Avila de Espindola <espindola@google.com>
370 * lto-plugin.c (write_resolution): Assume resolution_file is set.
371 Print the symbol name.
372 (all_symbols_read_handler): Create a resolution file.
374 (cleanup_handler): Remove the resolution file.
375 (process_option): Drop the -resolution option.
377 2009-11-05 Rafael Avila de Espindola <espindola@google.com>
379 * lto-plugin.c (temp_obj_dir_name): Remove.
380 (arguments_file_name): New.
381 (free_2): Free arguments_file_name instead of temp_obj_dir_name.
382 (exec_lto_wrapper): Create arguments file with make_temp_file.
383 (cleanup_handler): Don't remove the temporary directory. Remove the
385 (onload): Don't create the temporary directory.
387 2009-11-04 Richard Guenther <rguenther@suse.de>
388 Rafael Avila de Espindola <espindola@google.com>
390 * lto-plugin.c (plugin_file_info): Remove temp field.
391 (cleanup_handler): Don't delete temporary objects.
392 (claim_file_handler): Don't create temporary objects.
394 2009-11-04 Rafael Avila de Espindola <espindola@google.com>
396 * lto-plugin.c (cleanup_handler): Don't cleanup if debugging.
398 2009-10-30 Rafael Avila de Espindola <espindola@google.com>
401 * lto-plugin.c (claim_file_handler): Close files that we created.
403 2009-10-28 Rafael Avila de Espindola <espindola@google.com>
405 * lto-plugin.c (all_symbols_read_handler): Use LDPL_FATAL instead of
408 2009-10-27 Dmitry Gorbachev <d.g.gorbachev@gmail.com>
411 * configure.ac: Call AC_SYS_LARGEFILE before AC_OUTPUT.
412 * configure: Regenerate.
414 2009-10-26 Richard Guenther <rguenther@suse.de>
416 * configure.ac: Use AM_MAINTAINER_MODE.
417 * acinclude.m4: Remove.
418 * configure: Re-generate.
419 * Makefile.in: Likewise.
420 * aclocal.m4: Likewise.
422 2009-10-19 Rafael Avila de Espindola <espindola@google.com>
425 * configure: Regenerate.
426 * configure.ac: Add AC_TYPE_UINT64_T.
428 2009-10-16 Rafael Avila de Espindola <espindola@google.com>
430 * lto-plugin.c (message): New variable.
431 (check): New function.
432 (parse_table_entry, translate, write_resolution,add_output_files,
433 exec_lto_wrapper,claim_file_handler, onload): Use check instead of
435 (cleanup_handler): Use check instead of assert. Remove the arguments
438 2009-10-15 Rafael Avila de Espindola <espindola@google.com>
440 * lto-plugin.c (resolution_file): New.
441 (free_1): Update comment.
442 (free_2): Free resolution_file.
443 (write_resolution): Write resolution to specified file. Use the
444 syms array from the symbol table.
445 (all_symbols_read_handler): Delay call to free_1 past call to
447 (process_option): Add a -resolution option.
449 2009-10-13 Richard Guenther <rguenther@suse.de>
451 * Makefile.am (liblto_plugin_la_LIBADD): Link against the
453 * Makefile.in: Regenerated.
455 2009-10-08 Rafael Avila de Espindola <espindola@google.com>
457 * lto-plugin.c (add_input_library): New.
458 (all_symbols_read_handler): Use add_input_library for items that
460 (process_option): Fit in 80 columns.
461 (onload): Handle LDPT_ADD_INPUT_LIBRARY.
463 2009-10-02 Diego Novillo <dnovillo@google.com>
465 * Makefile.am (AM_CPPFLAGS): Remove -D_LARGEFILE_SOURCE
466 and -D_FILE_OFFSET_BITS=64.
467 * configure.ac: Add AC_SYS_LARGEFILE.
468 * configure: Regenerate.
469 * Makefile.in: Regenerate.
470 * lto-plugin.c: Fix copyright boilerplate.
472 2009-10-02 Diego Novillo <dnovillo@google.com>
474 * Makefile.am (ACLOCAL_AMFLAGS): Define.
475 * aclocal.m4: Regenerate with aclocal-2.64
476 * acinclude.m4: Remove.
477 * Makefile.in: Regenerate with automake-1.11
478 * configure.ac (AC_PREREQ): Update to 2.64.
479 * configure: Regenerate.
481 2009-10-02 Diego Novillo <dnovillo@google.com>
483 * Makefile.am (AM_CPPFLAGS): Remove -D_LARGEFILE_SOURCE
484 and -D_FILE_OFFSET_BITS=64.
485 * configure.ac: Add AC_SYS_LARGEFILE.
486 * configure: Regenerate.
487 * Makefile.in: Regenerate.
488 * lto-plugin.c: Fix copyright boilerplate.
490 2009-10-02 Diego Novillo <dnovillo@google.com>
492 * Makefile.am (ACLOCAL_AMFLAGS): Define.
493 * aclocal.m4: Regenerate with aclocal-2.64
494 * acinclude.m4: Remove.
495 * Makefile.in: Regenerate with automake-1.11
496 * configure.ac (AC_PREREQ): Update to 2.64.
497 * configure: Regenerate.
499 2009-10-02 Rafael Avila de Espindola <espindola@google.com>
501 * Makefile.am (liblto_plugin_la_SOURCES): Remove
502 $(top_srcdir)/../gcc/lto/common.c
503 * Makefile.in: Regenerate.
505 2009-10-01 Rafael Avila de Espindola <espindola@google.com>
507 * lto-plugin.c (pass_through_items): New.
508 (num_pass_through_items): New.
509 (all_symbols_read_handler): Update to use the -pass-through option.
510 (process_option): Replace -libgcc with -pass-through.
512 2009-09-30 Rafael Avila de Espindola <espindola@google.com>
514 * lto-plugin.c (onload): Return a ld_plugin_status. Don't require
515 register_cleanup to be set.
517 2009-09-30 Rafael Avila de Espindola <espindola@google.com>
519 * Makefile.am: Remove all reference to ltosymtab.
520 * Makefile.in: Regenerate.
521 * lto-symtab.c: Remove.
523 2009-05-21 Diego Novillo <dnovillo@google.com>
525 * configure.ac: Remove call to AC_CHECK_GELF.
526 Call AC_ARG_VAR for LIBELFLIBS and LIBELFINC.
527 * acinclude.m4: Do not include ../config/libelf.m4
528 * Makefile.am (LIBELFLIBS): Define.
530 (AM_CPPFLAGS): Add $(LIBELFINC).
531 (ltosymtab_LDADD): Add $(LIBELFLIBS).
532 (liblto_plugin_la_LIBADD): Add $(LIBELFLIBS)
533 * lto-plugin.c: Always include <gelf.h>
534 * lto-symtab.c: Likewise.
535 * configure: Regenerate.
536 * Makefile.in: Regenerate.
538 2009-03-23 Rafael Avila de Espindola <espindola@google.com>
540 * lto-plugin.c (libgcc_filename): New.
541 (all_symbols_read_handler): Pass libgcc to the linker.
542 (all_symbols_read_handler): Parse -libgcc
544 2009-02-05 Rafael Avila de Espindola <espindola@google.com>
546 * Makefile.am (liblto_plugin_la_LIBADD): Link with libiberty.
547 * Makefile.in: Regenerate.
548 * lto-plugin.c (add_output_files): Argument is now a FILE.
549 (exec_lto_wrapper): Use writeargv and pex.
551 2009-02-04 Rafael Avila de Espindola <espindola@google.com>
554 2009-02-04 Rafael Avila de Espindola <espindola@google.com>
555 * lto-plugin.c (exec_lto_wrapper): Use writeargv.
558 2009-02-04 Rafael Avila de Espindola <espindola@google.com>
560 * lto-plugin.c (exec_lto_wrapper): Use writeargv.
562 2009-01-29 Rafael Avila de Espindola <espindola@google.com>
564 * lto-plugin.c: Include libiberty.h.
565 (exec_lto_wrapper, claim_file_handler): Use asprintf instead of
568 2009-01-29 Rafael Avila de Espindola <espindola@google.com>
570 * lto-plugin.c (exec_lto_wrapper): Write argv to a file. Pass that
573 2009-01-28 Rafael Avila de Espindola <espindola@google.com>
575 * lto-plugin.c (plugin_file_info): Remove fd and elf.
576 (parse_table_entry): strdup entry->name and entry->comdat_key.
577 (free_1): Free name and comdat_key. Don't close the file. Don't call
579 (claim_file_handler): Always call elf_end.
581 2008-12-23 Rafael Avila de Espindola <espindola@google.com>
583 * Makefile.am (AM_CPPFLAGS): Add -D_LARGEFILE_SOURCE
584 -D_FILE_OFFSET_BITS=64
585 * Makefile.in: Regenerate
587 2008-12-22 Rafael Avila de Espindola <espindola@google.com>
589 * Makefile.am (gcc_version, target_noncanonical, libexecsubdir): New.
590 (lib_LTLIBRARIES): Rename to libexecsub_LTLIBRARIES.
591 * Makefile.in: Regenerate.
592 * acinclude.m4: Include ../config/acx.m4 and ../lt~obsolete.m4
593 * configure: Regenerate.
594 * configure.ac: Add AC_SUBST(target_noncanonical).
596 2008-12-08 Rafael Avila de Espindola <espindola@google.com>
598 * lto-plugin.c: Include stdbool.h.
599 (debug, nop): Declare as bool.
601 2008-12-08 Rafael Avila de Espindola <espindola@google.com>
603 * lto-plugin.c (nop): New.
604 (use_original_files): New.
605 (all_symbols_read_handler): Call use_original_files if nop is true.
606 (process_option): Parse the -nop option.
608 2008-12-08 Rafael Avila de Espindola <espindola@google.com>
610 * lto-plugin.c (debug): New.
611 (exec_lto_wrapper): Print argv if debug is true.
612 (process_option): Process the -debug command line option.
614 2008-12-03 Rafael Avila de Espindola <espindola@google.com>
616 * lto-plugin.c (process_option): The argument is now a single option,
617 not a space separated list.
619 2008-12-02 Rafael Avila de Espindola <espindola@google.com>
621 * lto-plugin.c: Include sys/types.h and sys/wait.h
622 (output_files, num_output_files, lto_wrapper_argv,
623 lto_wrapper_num_args): New.
624 (free_2): Free output_files.
625 (write_resolution): Disable.
626 (add_output_files): New.
627 (exec_lto_wrapper): New.
628 (all_symbols_read_handler): Run lto-wrapper.
629 (claim_file_handler): Free lto_file.name and call elf_end.
630 (process_option): New.
632 2008-11-26 Rafael Espindola <espindola@google.com>
634 * lto-plugin.c (add_input_file): New.
635 (get_section): Return NULL if get_section fails.
636 (write_resolution): New.
637 (all_symbols_read_handler): Call add_input_file.
638 (claim_file_handler): Unlink the correct file.
639 (onload): Record add_input_file.
641 2008-09-23 Rafael Espindola <espindola@google.com>
643 * Makefile.am (ltosymtab_SOURCES, liblto_plugin_la_SOURCES):
644 Update the location of common.c.
645 * Makefile.in: Regenerate.
646 * common.c: Moved to gcc/lto.
647 * common.h: Moved to gcc/lto.
648 * lto-plugin.c: Update the location of common.h.
649 * lto-symtab.c: Update the location of common.h.
651 2008-09-23 Rafael Espindola <espindola@google.com>
653 * common.c: Include common.h.
654 (lto_kind_str, lto_visibility_str, lto_resolution_str): Use explicit
656 * common.h (lto_kind_str, lto_visibility_str, lto_resolution_str): Use
659 2008-09-23 Rafael Espindola <espindola@google.com>
661 * lto-plugin.c (plugin_file_info): Add temp.
662 (cleanup_handler): Only delete temporary files.
663 (claim_file_handler): Initialize lto_file.temp.
665 2008-09-23 Rafael Espindola <espindola@google.com>
667 * plugin-api.h: Moved to include.
669 2008-09-23 Rafael Espindola <espindola@google.com>
671 * lto-plugin.c (all_symbols_read_handler): Print resolution in a new
674 2008-09-22 Rafael Espindola <espindola@google.com>
676 * plugin-api.h: Copy from binutils' cvs.
678 2008-09-22 Rafael Espindola <espindola@google.com>
680 * lto-symtab.c (get_symbols, add_symbols): Update signature.
681 * plugin-api.h: Copy from binutils' cvs.
683 2008-09-22 Rafael Espindola <espindola@google.com>
685 * common.h (lto_kind_str, lto_visibility_str, lto_resolution_str):
688 2008-09-10 Rafael Espindola <espindola@google.com>
690 * lto-plugin.c (onload): add missing break statements and asserts.
691 * lto-symtab.c (claim_file_handler): Make it static.
692 (all_symbols_read_handler): Make it static.
693 (all_file_handles): Make it static.
694 (num_file_handles): Make it static.
695 (register_claim_file): Make it static.
696 (register_object): Indent properly.
698 2008-09-10 Rafael Avila de Espindola <espindola@google.com>
700 * Makefile.am (ltosymtab_LDADD): Add -lelf.
701 * Makefiel.in: Regenerate.
702 * lto-plugin.c: Include ar.h.
703 (claim_file_handler): Handle file->offset != 0.
704 * lto-symtab.c: Include gelf.h.
705 (all_file_handles): Change type.
706 (register_object): New.
707 (register_file): Add support for archives.
708 (resolve): Update to new type of all_file_handles.
709 (print): Update to new type of all_file_handles.
710 (free_all): Update to new type of all_file_handles.
711 (main): Update to new type of all_file_handles.
713 2008-09-10 Rafael Avila de Espindola <espindola@google.com>
715 * lto-plugin.c (get_string_table): Remove.
716 (get_section): Use elf_strptr instead of get_string_table.
718 2008-09-08 Doug Kwan <dougkwan@google.com>
720 * lto-plugin.c (all_symbols_read_handler): Widen fprintf arguments
721 to 64-bit to fix a 32-bit bootstrap failure due to format warnings.
723 2008-09-08 Rafael Avila de Espindola <espindola@google.com>
725 * Makefile.am (ltosymtab_SOURCES): add common.c.
726 (ltosymtab_CFLAGS): New.
727 (liblto_plugin_la_SOURCES): Add common.c.
728 * Makefile.in: Regenerate.
731 * lto-plugin.c: Include stdio.h, inttypes.h and common.h.
732 (plugin_symtab): New.
733 (plugin_file_info): New.
734 (register_all_symbols_read): New.
736 (claimed_files): New.
737 (num_claimed_files): New.
738 (translate): Don't drop the slot number.
741 (all_symbols_read_handler): New.
742 (claim_file_handler): Record every claimed file.
743 (onload): Handle LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK and
745 * lto-symtab.c: Include stdlib.h, string.h and common.h.
746 (current_file_handle): Remove.
747 (ld_plugin_all_symbols_read_handler): New.
748 (plugin_handle): New.
750 (all_file_handles): New.
751 (num_file_handles): New.
753 (register_all_symbols_read): New.
754 (add_symbols): Don't print the symbols, just record them.
755 (ld_plugin_tv): Add LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK and
757 (load_plugin): Use plugin_handle.
758 (register_file): Add the file handle to all_file_handles.
761 (unload_plugin): New.
763 (main): Call all_symbols_read_handler and free resources.
765 2008-09-03 Rafael Avila de Espindola <espindola@google.com>
767 * Makefile.am (AM_CFLAGS): New.
768 (ltosymtab_LDADD): Remove -lelf. Add -ldl.
769 (lib_LTLIBRARIES): New.
770 (liblto_plugin_la_SOURCES): New.
771 (liblto_plugin_la_LIBADD): New.
772 * Makefile.in: Regenerate.
773 * acinclude.m4: Don't include ../config/acx.m4 and
774 ../config/no-executables.m4.
775 Include ../ltsugar.m4, ../ltoptions.m4, ../ltversion.m4 and
777 * aclocal.m4: Regenerate.
778 * configure: Regenerate.
779 * configure.ac: Use AM_PROG_LIBTOOL.
781 * lto-symtab.c: Rewrite to use the plugin.
784 2008-08-25 Rafael Avila de Espindola <espindola@google.com>
786 * configure: Regenerate.
787 * configure.ac: Use AC_CHECK_GELF.
788 * lto-symtab.c: Include gelf.h.
789 (get_string_table): Use size independent API.
790 (printTable): Use lld to print 64 bit integers.
792 2008-08-22 Rafael Avila de Espindola <espindola@google.com>
794 * lto-symtab.c (parse_table_entry): Assert entry->kind and
795 entry->visibility are valid.
797 2008-07-22 Rafael Avila de Espindola <espindola@google.com>
798 * lto-symtab.c (table_entry): Add comdat.
799 (parse_table_entry): Read comdat.
801 2008-08-21 Rafael Espindola <espindola@google.com>