1 2011-10-02 Jan Hubicka <jh@suse.cz>
4 * lto-plugin.c (get_symbols_v2): New variable.
5 (write_resolution): Use V2 API when available.
6 (onload): Handle LDPT_GET_SYMBOLS_V2.
8 2011-09-30 H.J. Lu <hongjiu.lu@intel.com>
9 Andi Kleen <ak@linux.intel.com>
12 * lto-plugin.c (sym_aux): Change id to unsigned long long.
13 (plugin_symtab): Likewise.
14 (dump_symtab): Likewise.
15 (resolve_conflicts): Likewise.
16 (process_symtab): Likewise.
18 2011-08-10 Richard Guenther <rguenther@suse.de>
22 * configure.ac: Use ACX_PROG_CC_WARNING_OPTS to detect -Wall presence.
23 * Makefile.am (AM_CFLAGS): Adjust. Do not build with -Werror.
24 * configure: Regenerate.
25 * Makefile.in: Likewise.
26 * aclocal.m4: Likewise.
28 2011-04-20 Jim Meyering <meyering@redhat.com>
30 * lto-plugin.c (free_1, free_2): Remove useless if-before-free.
32 2011-04-05 Richard Guenther <rguenther@suse.de>
35 * lto-plugin.c (claim_file_handler): Do not declare vars in code.
37 2011-02-13 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
39 * Makefile.in: Regenerate.
40 * aclocal.m4: Regenerate.
41 * configure: Regenerate.
43 2011-02-12 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
45 * Makefile.am (all-local): Rename from 'all'.
46 * Makefile.in: Regenerate.
48 2011-02-12 Alexandre Oliva <aoliva@redhat.com>
51 * Makefile.am (gcc_build_dir, in_gcc_libs): New.
52 (liblto_plugin_la_LDFLAGS): Add -module.
53 (copy_lto_plugin): Renamed to...
54 ($(in_gcc_libs)): ... this. Add mkinstalldirs. Skip copying
56 * Makefile.in: Rebuild.
58 2011-02-07 Kai Tietz <kai.tietz@onevision.com>
61 * Makefile.am (Wc): New helper for encoding -Wc,.
62 (liblto_plugin_la_LIBADD): Use Wc for libiberty library.
63 (liblto_plugin_la_DEPENDENCIES): Special case pic libiberty.
64 * Makefile.in: Regenerated.
66 2011-02-07 Paolo Bonzini <bonzini@gnu.org>
70 2011-02-07 Kai Tietz <kai.tietz@onevision.com>
73 * Makefile.am (Wl): New helper for encoding -Wl,.
74 (liblto_plugin_la_LIBADD): Use -Wl for libiberty library.
75 * Makefile.in: Regenerated.
77 2011-02-07 Kai Tietz <kai.tietz@onevision.com>
80 * Makefile.am (Wl): New helper for encoding -Wl,.
81 (liblto_plugin_la_LIBADD): Use -Wl for libiberty library.
82 * Makefile.in: Regenerated.
84 2011-01-25 Ian Lance Taylor <iant@google.com>
86 * lto-plugin.c (gold_version): New static variable.
87 (all_symbols_read_handler): Don't check pass_through_items if
88 using gold 1.11 or later.
89 (onload): Set gold_version if we see LDPT_GOLD_VERSION.
91 2011-01-12 Richard Guenther <rguenther@suse.de>
94 * lto-plugin.c (parse_table_entry): Use memcpy to access
97 2010-12-20 Dave Korn <dave.korn.cygwin@gmail.com>
99 * Makefile.am (AM_LIBTOOLFLAGS): Define, adding disable-static tag.
100 * Makefile.in: Regenerate.
102 2010-12-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
106 2010-12-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
108 * Makefile.am (liblto_plugin_la_DEPENDENCIES): Define.
109 (liblto_plugin_la_LIBADD): Use -L../libiberty/pic -liberty.
110 (liblto_plugin_la_LDFLAGS): Use -L../libiberty -liberty.
111 * Makefile.in: Regenerate.
113 2010-12-10 Dave Korn <dave.korn.cygwin@gmail.com>
117 * configure.ac (SYM_STYLE): Don't AC_DEFINE.
118 * lto-plugin.c (sym_style): Don't use it; default to ss_none.
119 * configure: Regenerate.
120 * config.h.in: Likewise.
122 2010-12-06 Dave Korn <dave.korn.cygwin@gmail.com>
126 * configure.ac: Invoke ACX_LT_HOST_FLAGS.
127 * Makefile.am (liblto_plugin_la_LDFLAGS): Use lt_host_flags but
128 override -bindir setting.
129 * aclocal.m4: Regenerate.
130 * configure: Regenerate.
131 * Makefile.in: Regenerate.
133 2010-12-05 Kai Tietz <kai.tietz@onevision.com>
135 * config.h.in: Regenerated.
136 * configure: Regenerated.
137 * configure.ac (AC_CHECK_HEADERS): Replaced by AC_HEADER_SYS_WAIT.
138 * lto-plugin.c (WIFEXITED): Define default.
139 (WEXITSTATUS): Likeiwse.
141 2010-12-01 Kai Tietz <kai.tietz@onevision.com>
143 * config.h.in: Regenerated.
144 * configure: Regenerated.
145 * Makefile.in: Regenerated.
146 * configure.ac (AC_CHECK_HEADERS): Check for sys/wait.h.
147 * lto-plugin.c: Include sys/wait.h conditionally.
148 * aclocal.m4: Regenerated.
150 2010-11-13 Kai Tietz <kai.tietz@onevision.com>
152 * lto-plugin.c (add_output_files): Fix memory leak.
154 2010-11-11 Dave Korn <dave.korn.cygwin@gmail.com>
158 * configure.ac: Add AC_TYPE_INT64_T test.
159 * config.h.in: Regenerate.
160 * configure: Likewise.
161 * lto-plugin.c (debug): Use char not bool.
163 (check_1): Rename from check, and use int not bool for gate argument.
164 (check): Macro wrapper for the above to coerce gate argument into
165 boolean-valued integer in case it has pointer type.
166 (parse_table_entry): Use 0 not false.
167 (claim_file_handler): Avoid use of PRIx64 by splitting 64-bit size
168 into two 32-bit parts and printing as hex ints.
170 2010-11-03 Dave Korn <dave.korn.cygwin@gmail.com>
173 * lto-plugin.c (claim_file_handler): Don't close file descriptor.
175 2010-11-03 Dave Korn <dave.korn.cygwin@gmail.com>
178 * lto-plugin.h: Delete.
179 * lto-plugin-elf.c: Likewise.
180 * lto-plugin-coff.c: Likewise.
181 * configure.ac: Don't use libelf, don't source config.gcc.
182 (LIBELFLIBS): Delete.
184 (LTO_FORMAT): Delete.
185 (SYM_STYLE): Add AC_DEFINE var, set based on $target.
186 (config.h): Add AC_CONFIG_HEADERS directive.
187 * Makefile.am (LIBELFLIBS): Delete.
189 (LTO_FORMAT): Delete.
191 (AM_CPPFLAGS): Use it. Don't use LIBELFINC.
192 (liblto_plugin_la_SOURCES): Don't use LTO_FORMAT, don't include
193 any object-format-specific source file in the link.
194 (liblto_plugin_la_LIBADD): Don't use LIBELFLIBS.
195 * config.h.in: Generate.
196 * configure: Regenerate.
197 * Makefile.in: Likewise.
198 * lto-plugin.c (O_BINARY): Definition moved here from lto-plugin.h.
199 (LTO_SEGMENT_NAME): New definition.
200 (LTO_SECTION_PREFIX): Definition moved here from lto-plugin.h.
201 (LTO_SECTION_PREFIX_LEN): New definition.
202 (struct sym_aux): Struct definition moved here from lto-plugin.h.
203 (struct plugin_symtab): Likewise.
204 (struct plugin_objfile): Likewise.
205 (struct plugin_objfile): New struct def.
206 (enum symbol_style): New enum type.
207 (add_symbols): Make static.
208 (claimed_files): Likewise.
209 (num_claimed_files): Likewise.
210 (sym_style): New global.
211 (check): Make static.
212 (parse_table_entry): Likewise. Respect sym_style when extracting
213 symbol from symtab entry.
214 (translate): Make static.
215 (resolve_conflicts): Likewise.
216 (process_symtab): New function, per-section callback version of
217 old object-format-specific handling from deleted lto-plugin-elf.c.
218 (claim_file_handler): Convert ELF-specific version from deleted
219 lto-plugin-elf.c to simple_object interface and move here.
220 (process_options): Allow new '-sym-style=' option.
221 (onload): Don't call deleted onload_format_checks hook.
223 2010-10-11 Kai Tietz <kai.tietz@onevision.com>
225 * lto-plugin.c (dump_symtab): Correct printf argument type.
226 (finish_conflict_resolution): Initialize resolution.
228 2010-10-08 H.J. Lu <hongjiu.lu@intel.com>
231 * configure.ac: Add AC_CANONICAL_SYSTEM.
232 * configure: Regenerated.
234 2010-10-07 Dave Korn <dave.korn.cygwin@gmail.com>
236 * configure.ac: Source config.gcc to determine lto_binary_reader.
237 (LTO_FORMAT): New AC_SUBST variable inferred from lto_binary_reader.
238 * Makefile.am (LTO_FORMAT): Import.
239 (liblto_plugin_la_SOURCES): Add object format dependent module
240 defined by LTO_FORMAT.
241 (liblto_plugin_la_LIBADD): Allow for both PIC and non-PIC libiberty,
242 and work around libtool warning.
243 * configure: Regenerate.
244 * Makefile.in: Likewise.
245 * lto-plugin.c (struct sym_aux): Move to new lto-plugin.h.
246 (struct sym_aux): Likewise.
247 (struct plugin_symtab): Likewise.
248 (struct plugin_file_info): Likewise.
249 (LTO_SECTION_PREFIX): Likewise.
250 (add_symbols): Make non-static.
251 (claimed_files): Likewise.
252 (num_claimed_files): Likewise.
254 (parse_table_entry): Likewise.
255 (translate): Likewise.
256 (resolve_conflicts): Likewise.
257 (process_symtab): Move to new lto-plugin-elf.c object format dependent
259 (claim_file_handler): Likewise, and make non-static.
260 (onload): Call new onload_format_checks function.
261 * lto-plugin.h: New file.
262 (LTO_SECTION_PREFIX): Move here.
263 (struct sym_aux): Likewise.
264 (struct plugin_symtab): Likewise.
265 (struct plugin_file_info): Likewise.
266 (claim_file_handler): Add new function prototype.
267 (onload_format_checks): Likewise.
268 (check): Declare extern.
269 (translate): Likewise.
270 (parse_table_entry): Likewise.
271 (resolve_conflicts): Likewise.
272 (add_symbols): Likewise.
273 (claimed_files): Likewise.
274 (num_claimed_files): Likewise.
275 * lto-plugin-elf.c (process_symtab): Move here.
276 (claim_file_handler): Likewise, and make non-static.
277 (onload_format_checks): New function factored out from onload.
278 * lto-plugin-coff.c (claim_file_handler): New function stub.
279 (onload_format_checks): Likewise.
281 2010-08-05 Andi Kleen <ak@linux.intel.com>
283 * lto-plugin.c: Include <hashtab.h>
284 (sym_aux): Add next_conflict field to save conflict chains.
285 (plugin_file_info): Add conflicts symtab.
286 (parse_table_entry): Initialize aux->next_conflict.
287 (process_symtab): Increment found.
289 (finish_conflict_resolution): Add.
291 (write_resolution): Remove symbols loop and move into
292 dump_symtab. Call dump_symtab for main symbol and conflicts table.
293 Call free_symtab to free conflicts table.
297 (symbol_strength): Add.
298 (resolve_conflicts): Add.
299 (claim_file_handler): Add n variable. Check return value of
300 process_symtab. Call resolve_conflicts.
302 2010-07-27 Andi Kleen <ak@linux.intel.com>
304 * lto-plugin.c (translate): Remove debug fprintf.
306 2010-07-23 H.J. Lu <hongjiu.lu@intel.com>
309 * lto-plugin.c (translate): Cast to unsigned long.
311 2010-07-23 Andi Kleen <ak@linux.intel.com>
314 * lto-plugin.c (sym_aux): Add.
315 (plugin_symtab): Remove slots. Add aux and id.
316 (parse_table_entry): Change to use aux instead of slots.
317 (LTO_SECTION_PREFIX): Add.
318 (translate): Improve buffer allocation. Change to append
319 symbols to existing out buffer.
320 (get_section): Remove.
321 (process_symtab): Add.
322 (free_2): Free symtab->aux.
323 (write_resolution): Handle aux instead of slots.
324 Print sub id to resolution file.
325 (claim_file_handler): Clear lto_file. Replace get_symtab/translate
326 calls with call to process_symtab.
328 2010-07-22 Richard Guenther <rguenther@suse.de>
330 * Makefile.am: New copy_lto_plugin rule to install the plugin
332 * Makefile.in: Regenerated.
334 2010-05-21 Richard Guenther <rguenther@suse.de>
336 * lto-plugin.c (write_resolution): Do not assert syms is non-NULL.
338 2010-05-07 Richard Guenther <rguenther@suse.de>
340 * lto-plugin.c (free_2): Do not free resolution_file.
341 (write_resolution): Check that we were passed a resolution file.
342 (all_symbols_read_handler): Adjust.
343 (cleanup_handler): Do not remove the resolution file.
344 (process_option): Handle -fresolution=.
346 2010-05-04 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
349 * configure.ac (AM_INIT_AUTOMAKE): Add no-dist.
350 * Makefile.in: Regenerate.
352 2010-04-23 Richard Guenther <rguenther@suse.de>
355 * lto-plugin.c (parse_table_entry): Use xstrdup and xrealloc.
356 (translate): Likewise.
357 (all_symbols_read_handler): Likewise.
358 (claim_file_handler): Likewise.
359 (process_option): Likewise.
360 (add_output_files): Likewise. Remove filename length limit.
362 2010-04-02 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
364 * Makefile.in: Regenerate.
365 * aclocal.m4: Regenerate.
367 2010-03-16 Dmitry Gorbachev <d.g.gorbachev@gmail.com>
370 * lto-plugin.c (cleanup_handler): Delete temporary output files.
372 2010-01-11 Richard Guenther <rguenther@suse.de>
375 * Makefile.am: Disable dependencies.
376 * Makefile.in: Regenerated.
378 2010-01-03 H.J. Lu <hongjiu.lu@intel.com>
381 * lto-plugin.c (exec_lto_wrapper): Output lto-wrapper command
384 2009-12-05 H.J. Lu <hongjiu.lu@intel.com>
387 * configure: Regenerated.
388 * Makefile.in: Likewise.
390 2009-11-19 Rafael Avila de Espindola <espindola@google.com>
393 * lto-plugin.c (claim_file_handler): Print offsets in hex.
395 2009-11-12 Rafael Avila de Espindola <espindola@google.com>
397 * lto-plugin.c (write_resolution): Assume resolution_file is set.
398 Print the symbol name.
399 (all_symbols_read_handler): Create a resolution file.
401 (cleanup_handler): Remove the resolution file.
402 (process_option): Drop the -resolution option.
404 2009-11-05 Rafael Avila de Espindola <espindola@google.com>
406 * lto-plugin.c (temp_obj_dir_name): Remove.
407 (arguments_file_name): New.
408 (free_2): Free arguments_file_name instead of temp_obj_dir_name.
409 (exec_lto_wrapper): Create arguments file with make_temp_file.
410 (cleanup_handler): Don't remove the temporary directory. Remove the
412 (onload): Don't create the temporary directory.
414 2009-11-04 Richard Guenther <rguenther@suse.de>
415 Rafael Avila de Espindola <espindola@google.com>
417 * lto-plugin.c (plugin_file_info): Remove temp field.
418 (cleanup_handler): Don't delete temporary objects.
419 (claim_file_handler): Don't create temporary objects.
421 2009-11-04 Rafael Avila de Espindola <espindola@google.com>
423 * lto-plugin.c (cleanup_handler): Don't cleanup if debugging.
425 2009-10-30 Rafael Avila de Espindola <espindola@google.com>
428 * lto-plugin.c (claim_file_handler): Close files that we created.
430 2009-10-28 Rafael Avila de Espindola <espindola@google.com>
432 * lto-plugin.c (all_symbols_read_handler): Use LDPL_FATAL instead of
435 2009-10-27 Dmitry Gorbachev <d.g.gorbachev@gmail.com>
438 * configure.ac: Call AC_SYS_LARGEFILE before AC_OUTPUT.
439 * configure: Regenerate.
441 2009-10-26 Richard Guenther <rguenther@suse.de>
443 * configure.ac: Use AM_MAINTAINER_MODE.
444 * acinclude.m4: Remove.
445 * configure: Re-generate.
446 * Makefile.in: Likewise.
447 * aclocal.m4: Likewise.
449 2009-10-19 Rafael Avila de Espindola <espindola@google.com>
452 * configure: Regenerate.
453 * configure.ac: Add AC_TYPE_UINT64_T.
455 2009-10-16 Rafael Avila de Espindola <espindola@google.com>
457 * lto-plugin.c (message): New variable.
458 (check): New function.
459 (parse_table_entry, translate, write_resolution,add_output_files,
460 exec_lto_wrapper,claim_file_handler, onload): Use check instead of
462 (cleanup_handler): Use check instead of assert. Remove the arguments
465 2009-10-15 Rafael Avila de Espindola <espindola@google.com>
467 * lto-plugin.c (resolution_file): New.
468 (free_1): Update comment.
469 (free_2): Free resolution_file.
470 (write_resolution): Write resolution to specified file. Use the
471 syms array from the symbol table.
472 (all_symbols_read_handler): Delay call to free_1 past call to
474 (process_option): Add a -resolution option.
476 2009-10-13 Richard Guenther <rguenther@suse.de>
478 * Makefile.am (liblto_plugin_la_LIBADD): Link against the
480 * Makefile.in: Regenerated.
482 2009-10-08 Rafael Avila de Espindola <espindola@google.com>
484 * lto-plugin.c (add_input_library): New.
485 (all_symbols_read_handler): Use add_input_library for items that
487 (process_option): Fit in 80 columns.
488 (onload): Handle LDPT_ADD_INPUT_LIBRARY.
490 2009-10-02 Diego Novillo <dnovillo@google.com>
492 * Makefile.am (AM_CPPFLAGS): Remove -D_LARGEFILE_SOURCE
493 and -D_FILE_OFFSET_BITS=64.
494 * configure.ac: Add AC_SYS_LARGEFILE.
495 * configure: Regenerate.
496 * Makefile.in: Regenerate.
497 * lto-plugin.c: Fix copyright boilerplate.
499 2009-10-02 Diego Novillo <dnovillo@google.com>
501 * Makefile.am (ACLOCAL_AMFLAGS): Define.
502 * aclocal.m4: Regenerate with aclocal-2.64
503 * acinclude.m4: Remove.
504 * Makefile.in: Regenerate with automake-1.11
505 * configure.ac (AC_PREREQ): Update to 2.64.
506 * configure: Regenerate.
508 2009-10-02 Diego Novillo <dnovillo@google.com>
510 * Makefile.am (AM_CPPFLAGS): Remove -D_LARGEFILE_SOURCE
511 and -D_FILE_OFFSET_BITS=64.
512 * configure.ac: Add AC_SYS_LARGEFILE.
513 * configure: Regenerate.
514 * Makefile.in: Regenerate.
515 * lto-plugin.c: Fix copyright boilerplate.
517 2009-10-02 Diego Novillo <dnovillo@google.com>
519 * Makefile.am (ACLOCAL_AMFLAGS): Define.
520 * aclocal.m4: Regenerate with aclocal-2.64
521 * acinclude.m4: Remove.
522 * Makefile.in: Regenerate with automake-1.11
523 * configure.ac (AC_PREREQ): Update to 2.64.
524 * configure: Regenerate.
526 2009-10-02 Rafael Avila de Espindola <espindola@google.com>
528 * Makefile.am (liblto_plugin_la_SOURCES): Remove
529 $(top_srcdir)/../gcc/lto/common.c
530 * Makefile.in: Regenerate.
532 2009-10-01 Rafael Avila de Espindola <espindola@google.com>
534 * lto-plugin.c (pass_through_items): New.
535 (num_pass_through_items): New.
536 (all_symbols_read_handler): Update to use the -pass-through option.
537 (process_option): Replace -libgcc with -pass-through.
539 2009-09-30 Rafael Avila de Espindola <espindola@google.com>
541 * lto-plugin.c (onload): Return a ld_plugin_status. Don't require
542 register_cleanup to be set.
544 2009-09-30 Rafael Avila de Espindola <espindola@google.com>
546 * Makefile.am: Remove all reference to ltosymtab.
547 * Makefile.in: Regenerate.
548 * lto-symtab.c: Remove.
550 2009-05-21 Diego Novillo <dnovillo@google.com>
552 * configure.ac: Remove call to AC_CHECK_GELF.
553 Call AC_ARG_VAR for LIBELFLIBS and LIBELFINC.
554 * acinclude.m4: Do not include ../config/libelf.m4
555 * Makefile.am (LIBELFLIBS): Define.
557 (AM_CPPFLAGS): Add $(LIBELFINC).
558 (ltosymtab_LDADD): Add $(LIBELFLIBS).
559 (liblto_plugin_la_LIBADD): Add $(LIBELFLIBS)
560 * lto-plugin.c: Always include <gelf.h>
561 * lto-symtab.c: Likewise.
562 * configure: Regenerate.
563 * Makefile.in: Regenerate.
565 2009-03-23 Rafael Avila de Espindola <espindola@google.com>
567 * lto-plugin.c (libgcc_filename): New.
568 (all_symbols_read_handler): Pass libgcc to the linker.
569 (all_symbols_read_handler): Parse -libgcc
571 2009-02-05 Rafael Avila de Espindola <espindola@google.com>
573 * Makefile.am (liblto_plugin_la_LIBADD): Link with libiberty.
574 * Makefile.in: Regenerate.
575 * lto-plugin.c (add_output_files): Argument is now a FILE.
576 (exec_lto_wrapper): Use writeargv and pex.
578 2009-02-04 Rafael Avila de Espindola <espindola@google.com>
581 2009-02-04 Rafael Avila de Espindola <espindola@google.com>
582 * lto-plugin.c (exec_lto_wrapper): Use writeargv.
585 2009-02-04 Rafael Avila de Espindola <espindola@google.com>
587 * lto-plugin.c (exec_lto_wrapper): Use writeargv.
589 2009-01-29 Rafael Avila de Espindola <espindola@google.com>
591 * lto-plugin.c: Include libiberty.h.
592 (exec_lto_wrapper, claim_file_handler): Use asprintf instead of
595 2009-01-29 Rafael Avila de Espindola <espindola@google.com>
597 * lto-plugin.c (exec_lto_wrapper): Write argv to a file. Pass that
600 2009-01-28 Rafael Avila de Espindola <espindola@google.com>
602 * lto-plugin.c (plugin_file_info): Remove fd and elf.
603 (parse_table_entry): strdup entry->name and entry->comdat_key.
604 (free_1): Free name and comdat_key. Don't close the file. Don't call
606 (claim_file_handler): Always call elf_end.
608 2008-12-23 Rafael Avila de Espindola <espindola@google.com>
610 * Makefile.am (AM_CPPFLAGS): Add -D_LARGEFILE_SOURCE
611 -D_FILE_OFFSET_BITS=64
612 * Makefile.in: Regenerate
614 2008-12-22 Rafael Avila de Espindola <espindola@google.com>
616 * Makefile.am (gcc_version, target_noncanonical, libexecsubdir): New.
617 (lib_LTLIBRARIES): Rename to libexecsub_LTLIBRARIES.
618 * Makefile.in: Regenerate.
619 * acinclude.m4: Include ../config/acx.m4 and ../lt~obsolete.m4
620 * configure: Regenerate.
621 * configure.ac: Add AC_SUBST(target_noncanonical).
623 2008-12-08 Rafael Avila de Espindola <espindola@google.com>
625 * lto-plugin.c: Include stdbool.h.
626 (debug, nop): Declare as bool.
628 2008-12-08 Rafael Avila de Espindola <espindola@google.com>
630 * lto-plugin.c (nop): New.
631 (use_original_files): New.
632 (all_symbols_read_handler): Call use_original_files if nop is true.
633 (process_option): Parse the -nop option.
635 2008-12-08 Rafael Avila de Espindola <espindola@google.com>
637 * lto-plugin.c (debug): New.
638 (exec_lto_wrapper): Print argv if debug is true.
639 (process_option): Process the -debug command line option.
641 2008-12-03 Rafael Avila de Espindola <espindola@google.com>
643 * lto-plugin.c (process_option): The argument is now a single option,
644 not a space separated list.
646 2008-12-02 Rafael Avila de Espindola <espindola@google.com>
648 * lto-plugin.c: Include sys/types.h and sys/wait.h
649 (output_files, num_output_files, lto_wrapper_argv,
650 lto_wrapper_num_args): New.
651 (free_2): Free output_files.
652 (write_resolution): Disable.
653 (add_output_files): New.
654 (exec_lto_wrapper): New.
655 (all_symbols_read_handler): Run lto-wrapper.
656 (claim_file_handler): Free lto_file.name and call elf_end.
657 (process_option): New.
659 2008-11-26 Rafael Espindola <espindola@google.com>
661 * lto-plugin.c (add_input_file): New.
662 (get_section): Return NULL if get_section fails.
663 (write_resolution): New.
664 (all_symbols_read_handler): Call add_input_file.
665 (claim_file_handler): Unlink the correct file.
666 (onload): Record add_input_file.
668 2008-09-23 Rafael Espindola <espindola@google.com>
670 * Makefile.am (ltosymtab_SOURCES, liblto_plugin_la_SOURCES):
671 Update the location of common.c.
672 * Makefile.in: Regenerate.
673 * common.c: Moved to gcc/lto.
674 * common.h: Moved to gcc/lto.
675 * lto-plugin.c: Update the location of common.h.
676 * lto-symtab.c: Update the location of common.h.
678 2008-09-23 Rafael Espindola <espindola@google.com>
680 * common.c: Include common.h.
681 (lto_kind_str, lto_visibility_str, lto_resolution_str): Use explicit
683 * common.h (lto_kind_str, lto_visibility_str, lto_resolution_str): Use
686 2008-09-23 Rafael Espindola <espindola@google.com>
688 * lto-plugin.c (plugin_file_info): Add temp.
689 (cleanup_handler): Only delete temporary files.
690 (claim_file_handler): Initialize lto_file.temp.
692 2008-09-23 Rafael Espindola <espindola@google.com>
694 * plugin-api.h: Moved to include.
696 2008-09-23 Rafael Espindola <espindola@google.com>
698 * lto-plugin.c (all_symbols_read_handler): Print resolution in a new
701 2008-09-22 Rafael Espindola <espindola@google.com>
703 * plugin-api.h: Copy from binutils' cvs.
705 2008-09-22 Rafael Espindola <espindola@google.com>
707 * lto-symtab.c (get_symbols, add_symbols): Update signature.
708 * plugin-api.h: Copy from binutils' cvs.
710 2008-09-22 Rafael Espindola <espindola@google.com>
712 * common.h (lto_kind_str, lto_visibility_str, lto_resolution_str):
715 2008-09-10 Rafael Espindola <espindola@google.com>
717 * lto-plugin.c (onload): add missing break statements and asserts.
718 * lto-symtab.c (claim_file_handler): Make it static.
719 (all_symbols_read_handler): Make it static.
720 (all_file_handles): Make it static.
721 (num_file_handles): Make it static.
722 (register_claim_file): Make it static.
723 (register_object): Indent properly.
725 2008-09-10 Rafael Avila de Espindola <espindola@google.com>
727 * Makefile.am (ltosymtab_LDADD): Add -lelf.
728 * Makefiel.in: Regenerate.
729 * lto-plugin.c: Include ar.h.
730 (claim_file_handler): Handle file->offset != 0.
731 * lto-symtab.c: Include gelf.h.
732 (all_file_handles): Change type.
733 (register_object): New.
734 (register_file): Add support for archives.
735 (resolve): Update to new type of all_file_handles.
736 (print): Update to new type of all_file_handles.
737 (free_all): Update to new type of all_file_handles.
738 (main): Update to new type of all_file_handles.
740 2008-09-10 Rafael Avila de Espindola <espindola@google.com>
742 * lto-plugin.c (get_string_table): Remove.
743 (get_section): Use elf_strptr instead of get_string_table.
745 2008-09-08 Doug Kwan <dougkwan@google.com>
747 * lto-plugin.c (all_symbols_read_handler): Widen fprintf arguments
748 to 64-bit to fix a 32-bit bootstrap failure due to format warnings.
750 2008-09-08 Rafael Avila de Espindola <espindola@google.com>
752 * Makefile.am (ltosymtab_SOURCES): add common.c.
753 (ltosymtab_CFLAGS): New.
754 (liblto_plugin_la_SOURCES): Add common.c.
755 * Makefile.in: Regenerate.
758 * lto-plugin.c: Include stdio.h, inttypes.h and common.h.
759 (plugin_symtab): New.
760 (plugin_file_info): New.
761 (register_all_symbols_read): New.
763 (claimed_files): New.
764 (num_claimed_files): New.
765 (translate): Don't drop the slot number.
768 (all_symbols_read_handler): New.
769 (claim_file_handler): Record every claimed file.
770 (onload): Handle LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK and
772 * lto-symtab.c: Include stdlib.h, string.h and common.h.
773 (current_file_handle): Remove.
774 (ld_plugin_all_symbols_read_handler): New.
775 (plugin_handle): New.
777 (all_file_handles): New.
778 (num_file_handles): New.
780 (register_all_symbols_read): New.
781 (add_symbols): Don't print the symbols, just record them.
782 (ld_plugin_tv): Add LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK and
784 (load_plugin): Use plugin_handle.
785 (register_file): Add the file handle to all_file_handles.
788 (unload_plugin): New.
790 (main): Call all_symbols_read_handler and free resources.
792 2008-09-03 Rafael Avila de Espindola <espindola@google.com>
794 * Makefile.am (AM_CFLAGS): New.
795 (ltosymtab_LDADD): Remove -lelf. Add -ldl.
796 (lib_LTLIBRARIES): New.
797 (liblto_plugin_la_SOURCES): New.
798 (liblto_plugin_la_LIBADD): New.
799 * Makefile.in: Regenerate.
800 * acinclude.m4: Don't include ../config/acx.m4 and
801 ../config/no-executables.m4.
802 Include ../ltsugar.m4, ../ltoptions.m4, ../ltversion.m4 and
804 * aclocal.m4: Regenerate.
805 * configure: Regenerate.
806 * configure.ac: Use AM_PROG_LIBTOOL.
808 * lto-symtab.c: Rewrite to use the plugin.
811 2008-08-25 Rafael Avila de Espindola <espindola@google.com>
813 * configure: Regenerate.
814 * configure.ac: Use AC_CHECK_GELF.
815 * lto-symtab.c: Include gelf.h.
816 (get_string_table): Use size independent API.
817 (printTable): Use lld to print 64 bit integers.
819 2008-08-22 Rafael Avila de Espindola <espindola@google.com>
821 * lto-symtab.c (parse_table_entry): Assert entry->kind and
822 entry->visibility are valid.
824 2008-07-22 Rafael Avila de Espindola <espindola@google.com>
825 * lto-symtab.c (table_entry): Add comdat.
826 (parse_table_entry): Read comdat.
828 2008-08-21 Rafael Espindola <espindola@google.com>