OSDN Git Service

Fix minor build system issues in lto-plugin.
[pf3gnuchains/gcc-fork.git] / lto-plugin / ChangeLog
1 2011-02-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2
3         * Makefile.am (all-local): Rename from 'all'.
4         * Makefile.in: Regenerate.
5
6 2011-02-12  Alexandre Oliva  <aoliva@redhat.com>
7
8         PR lto/47225
9         * Makefile.am (gcc_build_dir, in_gcc_libs): New.
10         (liblto_plugin_la_LDFLAGS): Add -module.
11         (copy_lto_plugin): Renamed to...
12         ($(in_gcc_libs)): ... this.  Add mkinstalldirs.  Skip copying
13         of static modules.
14         * Makefile.in: Rebuild.
15
16 2011-02-07  Kai Tietz  <kai.tietz@onevision.com>
17
18         PR lto/47225
19         * Makefile.am (Wc): New helper for encoding -Wc,.
20         (liblto_plugin_la_LIBADD): Use Wc for libiberty library.
21         (liblto_plugin_la_DEPENDENCIES): Special case pic libiberty.
22         * Makefile.in: Regenerated.
23
24 2011-02-07  Paolo Bonzini  <bonzini@gnu.org>
25
26         Revert:
27
28         2011-02-07  Kai Tietz  <kai.tietz@onevision.com>
29
30         PR lto/47225
31         * Makefile.am (Wl): New helper for encoding -Wl,.
32         (liblto_plugin_la_LIBADD): Use -Wl for libiberty library.
33         * Makefile.in: Regenerated.
34
35 2011-02-07  Kai Tietz  <kai.tietz@onevision.com>
36
37         PR lto/47225
38         * Makefile.am (Wl): New helper for encoding -Wl,.
39         (liblto_plugin_la_LIBADD): Use -Wl for libiberty library.
40         * Makefile.in: Regenerated.
41
42 2011-01-25  Ian Lance Taylor  <iant@google.com>
43
44         * lto-plugin.c (gold_version): New static variable.
45         (all_symbols_read_handler): Don't check pass_through_items if
46         using gold 1.11 or later.
47         (onload): Set gold_version if we see LDPT_GOLD_VERSION.
48
49 2011-01-12  Richard Guenther  <rguenther@suse.de>
50
51         PR lto/47264
52         * lto-plugin.c (parse_table_entry): Use memcpy to access
53         unaligned fields.
54
55 2010-12-20  Dave Korn  <dave.korn.cygwin@gmail.com>
56
57         * Makefile.am (AM_LIBTOOLFLAGS): Define, adding disable-static tag.
58         * Makefile.in: Regenerate.
59
60 2010-12-15  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
61
62         Revert last change.
63
64 2010-12-15  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
65
66         * Makefile.am (liblto_plugin_la_DEPENDENCIES): Define.
67         (liblto_plugin_la_LIBADD): Use -L../libiberty/pic -liberty.
68         (liblto_plugin_la_LDFLAGS): Use -L../libiberty -liberty.
69         * Makefile.in: Regenerate.
70
71 2010-12-10  Dave Korn  <dave.korn.cygwin@gmail.com>
72
73         PR middle-end/46674
74         PR lto/43157
75         * configure.ac (SYM_STYLE): Don't AC_DEFINE.
76         * lto-plugin.c (sym_style): Don't use it; default to ss_none.
77         * configure: Regenerate.
78         * config.h.in: Likewise.
79
80 2010-12-06  Dave Korn  <dave.korn.cygwin@gmail.com>
81
82         PR target/40125
83         PR lto/46695
84         * configure.ac: Invoke ACX_LT_HOST_FLAGS.
85         * Makefile.am (liblto_plugin_la_LDFLAGS): Use lt_host_flags but
86         override -bindir setting.
87         * aclocal.m4: Regenerate.
88         * configure: Regenerate.
89         * Makefile.in: Regenerate.
90
91 2010-12-05  Kai Tietz  <kai.tietz@onevision.com>
92
93         * config.h.in: Regenerated.
94         * configure: Regenerated.
95         * configure.ac (AC_CHECK_HEADERS): Replaced by AC_HEADER_SYS_WAIT.
96         * lto-plugin.c (WIFEXITED): Define default.
97         (WEXITSTATUS): Likeiwse.
98
99 2010-12-01  Kai Tietz  <kai.tietz@onevision.com>
100
101         * config.h.in: Regenerated.
102         * configure: Regenerated.
103         * Makefile.in: Regenerated.
104         * configure.ac (AC_CHECK_HEADERS): Check for sys/wait.h.
105         * lto-plugin.c:  Include sys/wait.h conditionally.
106         * aclocal.m4: Regenerated.
107
108 2010-11-13  Kai Tietz  <kai.tietz@onevision.com>
109
110         * lto-plugin.c (add_output_files): Fix memory leak.
111
112 2010-11-11  Dave Korn  <dave.korn.cygwin@gmail.com>
113
114         PR bootstrap/46397
115         PR bootstrap/46362
116         * configure.ac: Add AC_TYPE_INT64_T test.
117         * config.h.in: Regenerate.
118         * configure: Likewise.
119         * lto-plugin.c (debug): Use char not bool.
120         (nop): Likewise.
121         (check_1): Rename from check, and use int not bool for gate argument.
122         (check): Macro wrapper for the above to coerce gate argument into
123         boolean-valued integer in case it has pointer type.
124         (parse_table_entry): Use 0 not false.
125         (claim_file_handler): Avoid use of PRIx64 by splitting 64-bit size
126         into two 32-bit parts and printing as hex ints.
127
128 2010-11-03  Dave Korn  <dave.korn.cygwin@gmail.com>
129
130         PR lto/46291
131         * lto-plugin.c (claim_file_handler): Don't close file descriptor.
132
133 2010-11-03  Dave Korn  <dave.korn.cygwin@gmail.com>
134
135         PR lto/46273
136         * lto-plugin.h: Delete.
137         * lto-plugin-elf.c: Likewise.
138         * lto-plugin-coff.c: Likewise.
139         * configure.ac: Don't use libelf, don't source config.gcc.
140         (LIBELFLIBS): Delete.
141         (LIBELFINC): Delete.
142         (LTO_FORMAT): Delete.
143         (SYM_STYLE): Add AC_DEFINE var, set based on $target.
144         (config.h): Add AC_CONFIG_HEADERS directive.
145         * Makefile.am (LIBELFLIBS): Delete.
146         (LIBELFINC): Delete.
147         (LTO_FORMAT): Delete.
148         (DEFS): Import.
149         (AM_CPPFLAGS): Use it.  Don't use LIBELFINC.
150         (liblto_plugin_la_SOURCES): Don't use LTO_FORMAT, don't include
151         any object-format-specific source file in the link.
152         (liblto_plugin_la_LIBADD): Don't use LIBELFLIBS.
153         * config.h.in: Generate.
154         * configure: Regenerate.
155         * Makefile.in: Likewise.
156         * lto-plugin.c (O_BINARY): Definition moved here from lto-plugin.h.
157         (LTO_SEGMENT_NAME): New definition.
158         (LTO_SECTION_PREFIX): Definition moved here from lto-plugin.h.
159         (LTO_SECTION_PREFIX_LEN): New definition.
160         (struct sym_aux): Struct definition moved here from lto-plugin.h.
161         (struct plugin_symtab): Likewise.
162         (struct plugin_objfile): Likewise.
163         (struct plugin_objfile): New struct def.
164         (enum symbol_style): New enum type.
165         (add_symbols): Make static.
166         (claimed_files): Likewise.
167         (num_claimed_files): Likewise.
168         (sym_style): New global.
169         (check): Make static.
170         (parse_table_entry): Likewise.  Respect sym_style when extracting
171         symbol from symtab entry.
172         (translate): Make static.
173         (resolve_conflicts): Likewise.
174         (process_symtab): New function, per-section callback version of
175         old object-format-specific handling from deleted lto-plugin-elf.c.
176         (claim_file_handler): Convert ELF-specific version from deleted
177         lto-plugin-elf.c to simple_object interface and move here.
178         (process_options): Allow new '-sym-style=' option.
179         (onload): Don't call deleted onload_format_checks hook.
180
181 2010-10-11  Kai Tietz  <kai.tietz@onevision.com>
182
183         * lto-plugin.c (dump_symtab): Correct printf argument type.
184         (finish_conflict_resolution): Initialize resolution.
185
186 2010-10-08  H.J. Lu  <hongjiu.lu@intel.com>
187
188         PR bootstrap/45951
189         * configure.ac: Add AC_CANONICAL_SYSTEM.
190         * configure: Regenerated.
191
192 2010-10-07  Dave Korn  <dave.korn.cygwin@gmail.com>
193
194         * configure.ac: Source config.gcc to determine lto_binary_reader.
195         (LTO_FORMAT): New AC_SUBST variable inferred from lto_binary_reader.
196         * Makefile.am (LTO_FORMAT): Import.
197         (liblto_plugin_la_SOURCES): Add object format dependent module
198         defined by LTO_FORMAT.
199         (liblto_plugin_la_LIBADD): Allow for both PIC and non-PIC libiberty,
200         and work around libtool warning.
201         * configure: Regenerate.
202         * Makefile.in: Likewise.
203         * lto-plugin.c (struct sym_aux): Move to new lto-plugin.h.
204         (struct sym_aux): Likewise.
205         (struct plugin_symtab): Likewise.
206         (struct plugin_file_info): Likewise.
207         (LTO_SECTION_PREFIX): Likewise.
208         (add_symbols):  Make non-static.
209         (claimed_files): Likewise.
210         (num_claimed_files): Likewise.
211         (check): Likewise.
212         (parse_table_entry): Likewise.
213         (translate): Likewise.
214         (resolve_conflicts): Likewise.
215         (process_symtab): Move to new lto-plugin-elf.c object format dependent
216         source file.
217         (claim_file_handler): Likewise, and make non-static.
218         (onload): Call new onload_format_checks function.
219         * lto-plugin.h: New file.
220         (LTO_SECTION_PREFIX): Move here.
221         (struct sym_aux): Likewise.
222         (struct plugin_symtab): Likewise.
223         (struct plugin_file_info): Likewise.
224         (claim_file_handler): Add new function prototype.
225         (onload_format_checks): Likewise.
226         (check): Declare extern.
227         (translate): Likewise.
228         (parse_table_entry): Likewise.
229         (resolve_conflicts): Likewise.
230         (add_symbols):  Likewise.
231         (claimed_files): Likewise.
232         (num_claimed_files): Likewise.
233         * lto-plugin-elf.c (process_symtab): Move here.
234         (claim_file_handler): Likewise, and make non-static.
235         (onload_format_checks): New function factored out from onload.
236         * lto-plugin-coff.c (claim_file_handler): New function stub.
237         (onload_format_checks): Likewise.
238
239 2010-08-05  Andi Kleen  <ak@linux.intel.com>
240
241         * lto-plugin.c: Include <hashtab.h>
242         (sym_aux): Add next_conflict field to save conflict chains.
243         (plugin_file_info): Add conflicts symtab.
244         (parse_table_entry): Initialize aux->next_conflict.
245         (process_symtab): Increment found.
246         (dump_symtab): Add.
247         (finish_conflict_resolution): Add.
248         (free_symtab): Add.
249         (write_resolution): Remove symbols loop and move into
250         dump_symtab. Call dump_symtab for main symbol and conflicts table.
251         Call free_symtab to free conflicts table.
252         (SWAP): Add.
253         (eq_sym): Add.
254         (hash_sym): Add.
255         (symbol_strength): Add.
256         (resolve_conflicts): Add.
257         (claim_file_handler): Add n variable. Check return value of
258         process_symtab. Call resolve_conflicts.
259
260 2010-07-27  Andi Kleen <ak@linux.intel.com>
261
262         * lto-plugin.c (translate): Remove debug fprintf.
263
264 2010-07-23  H.J. Lu  <hongjiu.lu@intel.com>
265
266         PR bootstrap/45042
267         * lto-plugin.c (translate): Cast to unsigned long.
268
269 2010-07-23   Andi Kleen <ak@linux.intel.com>
270
271         PR lto/44992
272         * lto-plugin.c (sym_aux): Add.
273         (plugin_symtab): Remove slots. Add aux and id.
274         (parse_table_entry): Change to use aux instead of slots.
275         (LTO_SECTION_PREFIX): Add.
276         (translate): Improve buffer allocation. Change to append
277         symbols to existing out buffer.
278         (get_section): Remove.
279         (process_symtab): Add.
280         (free_2): Free symtab->aux.
281         (write_resolution): Handle aux instead of slots.
282         Print sub id to resolution file.
283         (claim_file_handler): Clear lto_file. Replace get_symtab/translate
284         calls with call to process_symtab.
285
286 2010-07-22  Richard Guenther  <rguenther@suse.de>
287
288         * Makefile.am: New copy_lto_plugin rule to install the plugin
289         into ../gcc.
290         * Makefile.in: Regenerated.
291
292 2010-05-21  Richard Guenther  <rguenther@suse.de>
293
294         * lto-plugin.c (write_resolution): Do not assert syms is non-NULL.
295
296 2010-05-07  Richard Guenther <rguenther@suse.de>
297
298         * lto-plugin.c (free_2): Do not free resolution_file.
299         (write_resolution): Check that we were passed a resolution file.
300         (all_symbols_read_handler): Adjust.
301         (cleanup_handler): Do not remove the resolution file.
302         (process_option): Handle -fresolution=.
303
304 2010-05-04  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
305
306         PR other/43620
307         * configure.ac (AM_INIT_AUTOMAKE): Add no-dist.
308         * Makefile.in: Regenerate.
309
310 2010-04-23  Richard Guenther  <rguenther@suse.de>
311
312         PR lto/41550
313         * lto-plugin.c (parse_table_entry): Use xstrdup and xrealloc.
314         (translate): Likewise.
315         (all_symbols_read_handler): Likewise.
316         (claim_file_handler): Likewise.
317         (process_option): Likewise.
318         (add_output_files): Likewise.  Remove filename length limit.
319
320 2010-04-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
321
322         * Makefile.in: Regenerate.
323         * aclocal.m4: Regenerate.
324
325 2010-03-16  Dmitry Gorbachev  <d.g.gorbachev@gmail.com>
326
327         PR lto/43336
328         * lto-plugin.c (cleanup_handler): Delete temporary output files.
329
330 2010-01-11  Richard Guenther  <rguenther@suse.de>
331
332         PR lto/41569
333         * Makefile.am: Disable dependencies.
334         * Makefile.in: Regenerated.
335
336 2010-01-03  H.J. Lu  <hongjiu.lu@intel.com>
337
338         PR lto/42520
339         * lto-plugin.c (exec_lto_wrapper): Output lto-wrapper command
340         if -v is passed.
341
342 2009-12-05  H.J. Lu  <hongjiu.lu@intel.com>
343
344         PR bootstrap/42306
345         * configure: Regenerated.
346         * Makefile.in: Likewise.
347
348 2009-11-19  Rafael Avila de Espindola  <espindola@google.com>
349
350         PR bootstrap/42096
351         * lto-plugin.c (claim_file_handler): Print offsets in hex.
352
353 2009-11-12  Rafael Avila de Espindola  <espindola@google.com>
354
355         * lto-plugin.c (write_resolution): Assume resolution_file is set.
356         Print the symbol name.
357         (all_symbols_read_handler): Create a resolution file.
358         Pass it to gcc.
359         (cleanup_handler): Remove the resolution file.
360         (process_option): Drop the -resolution option.
361
362 2009-11-05  Rafael Avila de Espindola  <espindola@google.com>
363
364         * lto-plugin.c (temp_obj_dir_name): Remove.
365         (arguments_file_name): New.
366         (free_2): Free arguments_file_name instead of temp_obj_dir_name.
367         (exec_lto_wrapper):  Create arguments file with make_temp_file.
368         (cleanup_handler): Don't remove the temporary directory. Remove the
369         arguments file.
370         (onload): Don't create the temporary directory.
371
372 2009-11-04  Richard Guenther  <rguenther@suse.de>
373             Rafael Avila de Espindola  <espindola@google.com>
374
375         * lto-plugin.c (plugin_file_info): Remove temp field.
376         (cleanup_handler): Don't delete temporary objects.
377         (claim_file_handler): Don't create temporary objects.
378
379 2009-11-04  Rafael Avila de Espindola  <espindola@google.com>
380
381         * lto-plugin.c (cleanup_handler): Don't cleanup if debugging.
382
383 2009-10-30  Rafael Avila de Espindola  <espindola@google.com>
384
385         PR41871
386         * lto-plugin.c (claim_file_handler): Close files that we created.
387
388 2009-10-28  Rafael Avila de Espindola  <espindola@google.com>
389
390         * lto-plugin.c (all_symbols_read_handler): Use LDPL_FATAL instead of
391         LDPL_ERROR
392
393 2009-10-27  Dmitry Gorbachev  <d.g.gorbachev@gmail.com>
394
395         PR lto/41652
396         * configure.ac: Call AC_SYS_LARGEFILE before AC_OUTPUT.
397         * configure: Regenerate.
398
399 2009-10-26  Richard Guenther  <rguenther@suse.de>
400
401         * configure.ac: Use AM_MAINTAINER_MODE.
402         * acinclude.m4: Remove.
403         * configure: Re-generate.
404         * Makefile.in: Likewise.
405         * aclocal.m4: Likewise.
406
407 2009-10-19  Rafael Avila de Espindola  <espindola@google.com>
408     
409         PR40790
410         * configure: Regenerate.
411         * configure.ac: Add AC_TYPE_UINT64_T.
412
413 2009-10-16  Rafael Avila de Espindola  <espindola@google.com>
414
415         * lto-plugin.c (message): New variable.
416         (check): New function.
417         (parse_table_entry, translate, write_resolution,add_output_files,
418         exec_lto_wrapper,claim_file_handler, onload): Use check instead of
419         assert.
420         (cleanup_handler): Use check instead of assert. Remove the arguments
421         file if it exists.
422
423 2009-10-15  Rafael Avila de Espindola  <espindola@google.com>
424
425         * lto-plugin.c (resolution_file): New.
426         (free_1): Update comment.
427         (free_2): Free resolution_file.
428         (write_resolution): Write resolution to specified file. Use the
429         syms array from the symbol table.
430         (all_symbols_read_handler): Delay call to free_1 past call to
431         write_resolution.
432         (process_option): Add a -resolution option.
433
434 2009-10-13  Richard Guenther  <rguenther@suse.de>
435
436         * Makefile.am (liblto_plugin_la_LIBADD): Link against the
437         correct libiberty.
438         * Makefile.in: Regenerated.
439
440 2009-10-08  Rafael Avila de Espindola  <espindola@google.com>
441
442         * lto-plugin.c (add_input_library): New.
443         (all_symbols_read_handler): Use add_input_library for items that
444         start with -l.
445         (process_option): Fit in 80 columns.
446         (onload): Handle LDPT_ADD_INPUT_LIBRARY.
447
448 2009-10-02  Diego Novillo  <dnovillo@google.com>
449
450         * Makefile.am (AM_CPPFLAGS): Remove -D_LARGEFILE_SOURCE
451         and -D_FILE_OFFSET_BITS=64.
452         * configure.ac: Add AC_SYS_LARGEFILE.
453         * configure: Regenerate.
454         * Makefile.in: Regenerate.
455         * lto-plugin.c: Fix copyright boilerplate.
456
457 2009-10-02  Diego Novillo  <dnovillo@google.com>
458
459         * Makefile.am (ACLOCAL_AMFLAGS): Define.
460         * aclocal.m4: Regenerate with aclocal-2.64
461         * acinclude.m4: Remove.
462         * Makefile.in: Regenerate with automake-1.11
463         * configure.ac (AC_PREREQ): Update to 2.64.
464         * configure: Regenerate.
465
466 2009-10-02  Diego Novillo  <dnovillo@google.com>
467
468         * Makefile.am (AM_CPPFLAGS): Remove -D_LARGEFILE_SOURCE
469         and -D_FILE_OFFSET_BITS=64.
470         * configure.ac: Add AC_SYS_LARGEFILE.
471         * configure: Regenerate.
472         * Makefile.in: Regenerate.
473         * lto-plugin.c: Fix copyright boilerplate.
474
475 2009-10-02  Diego Novillo  <dnovillo@google.com>
476
477         * Makefile.am (ACLOCAL_AMFLAGS): Define.
478         * aclocal.m4: Regenerate with aclocal-2.64
479         * acinclude.m4: Remove.
480         * Makefile.in: Regenerate with automake-1.11
481         * configure.ac (AC_PREREQ): Update to 2.64.
482         * configure: Regenerate.
483
484 2009-10-02  Rafael Avila de Espindola  <espindola@google.com>
485
486         * Makefile.am (liblto_plugin_la_SOURCES): Remove
487         $(top_srcdir)/../gcc/lto/common.c
488         * Makefile.in: Regenerate.
489
490 2009-10-01  Rafael Avila de Espindola  <espindola@google.com>
491
492         * lto-plugin.c (pass_through_items): New.
493         (num_pass_through_items): New.
494         (all_symbols_read_handler): Update to use the -pass-through option.
495         (process_option): Replace -libgcc with -pass-through.
496         
497 2009-09-30  Rafael Avila de Espindola  <espindola@google.com>
498
499         * lto-plugin.c (onload): Return a ld_plugin_status. Don't require
500         register_cleanup to be set.
501
502 2009-09-30  Rafael Avila de Espindola  <espindola@google.com>
503
504         * Makefile.am: Remove all reference to ltosymtab.
505         * Makefile.in: Regenerate.
506         * lto-symtab.c: Remove.
507
508 2009-05-21  Diego Novillo  <dnovillo@google.com>
509
510         * configure.ac: Remove call to AC_CHECK_GELF.
511         Call AC_ARG_VAR for LIBELFLIBS and LIBELFINC.
512         * acinclude.m4: Do not include ../config/libelf.m4
513         * Makefile.am (LIBELFLIBS): Define.
514         (LIBELFINC): Define.
515         (AM_CPPFLAGS): Add $(LIBELFINC).
516         (ltosymtab_LDADD): Add $(LIBELFLIBS).
517         (liblto_plugin_la_LIBADD): Add $(LIBELFLIBS)
518         * lto-plugin.c: Always include <gelf.h>
519         * lto-symtab.c: Likewise.
520         * configure: Regenerate.
521         * Makefile.in: Regenerate.
522
523 2009-03-23  Rafael Avila de Espindola  <espindola@google.com>
524
525         * lto-plugin.c (libgcc_filename): New.
526         (all_symbols_read_handler): Pass libgcc to the linker.
527         (all_symbols_read_handler): Parse -libgcc
528
529 2009-02-05  Rafael Avila de Espindola  <espindola@google.com>
530
531         * Makefile.am (liblto_plugin_la_LIBADD): Link with libiberty.
532         * Makefile.in: Regenerate.
533         * lto-plugin.c (add_output_files): Argument is now a FILE.
534         (exec_lto_wrapper): Use writeargv and pex.
535
536 2009-02-04  Rafael Avila de Espindola  <espindola@google.com>
537
538         Revert:
539         2009-02-04  Rafael Avila de Espindola  <espindola@google.com>
540         * lto-plugin.c (exec_lto_wrapper): Use writeargv.
541
542
543 2009-02-04  Rafael Avila de Espindola  <espindola@google.com>
544
545         * lto-plugin.c (exec_lto_wrapper): Use writeargv.
546
547 2009-01-29  Rafael Avila de Espindola  <espindola@google.com>
548
549         * lto-plugin.c: Include libiberty.h.
550         (exec_lto_wrapper, claim_file_handler): Use asprintf instead of
551         snprintf.
552
553 2009-01-29  Rafael Avila de Espindola  <espindola@google.com>
554
555         * lto-plugin.c (exec_lto_wrapper): Write argv to a file. Pass that
556         file to lto-wrapper.
557
558 2009-01-28  Rafael Avila de Espindola  <espindola@google.com>
559
560         * lto-plugin.c (plugin_file_info): Remove fd and elf.
561         (parse_table_entry): strdup entry->name and entry->comdat_key.
562         (free_1): Free name and comdat_key. Don't close the file. Don't call
563         elf_end.
564         (claim_file_handler): Always call elf_end.
565
566 2008-12-23  Rafael Avila de Espindola  <espindola@google.com>
567
568         * Makefile.am (AM_CPPFLAGS): Add -D_LARGEFILE_SOURCE
569         -D_FILE_OFFSET_BITS=64
570         * Makefile.in: Regenerate
571
572 2008-12-22  Rafael Avila de Espindola  <espindola@google.com>
573
574         * Makefile.am (gcc_version, target_noncanonical, libexecsubdir): New.
575         (lib_LTLIBRARIES): Rename to libexecsub_LTLIBRARIES.
576         * Makefile.in: Regenerate.
577         * acinclude.m4: Include ../config/acx.m4 and ../lt~obsolete.m4
578         * configure: Regenerate.
579         * configure.ac: Add AC_SUBST(target_noncanonical).
580
581 2008-12-08  Rafael Avila de Espindola  <espindola@google.com>
582
583         * lto-plugin.c: Include stdbool.h.
584         (debug, nop): Declare as bool.
585
586 2008-12-08  Rafael Avila de Espindola  <espindola@google.com>
587
588         * lto-plugin.c (nop): New.
589         (use_original_files): New.
590         (all_symbols_read_handler): Call use_original_files if nop is true.
591         (process_option): Parse the -nop option.
592
593 2008-12-08  Rafael Avila de Espindola  <espindola@google.com>
594
595         * lto-plugin.c (debug): New.
596         (exec_lto_wrapper): Print argv if debug is true.
597         (process_option): Process the -debug command line option.
598
599 2008-12-03  Rafael Avila de Espindola  <espindola@google.com>
600
601         * lto-plugin.c (process_option): The argument is now a single option,
602         not a space separated list.
603
604 2008-12-02  Rafael Avila de Espindola  <espindola@google.com>
605
606         * lto-plugin.c: Include sys/types.h and sys/wait.h
607         (output_files, num_output_files, lto_wrapper_argv,
608         lto_wrapper_num_args): New.
609         (free_2): Free output_files.
610         (write_resolution): Disable.
611         (add_output_files): New.
612         (exec_lto_wrapper): New.
613         (all_symbols_read_handler): Run lto-wrapper.
614         (claim_file_handler): Free lto_file.name and call elf_end.
615         (process_option): New.
616
617 2008-11-26  Rafael Espindola  <espindola@google.com>
618
619         * lto-plugin.c (add_input_file): New.
620         (get_section): Return NULL if get_section fails.
621         (write_resolution): New.
622         (all_symbols_read_handler): Call add_input_file.
623         (claim_file_handler): Unlink the correct file.
624         (onload): Record add_input_file.
625
626 2008-09-23 Rafael Espindola  <espindola@google.com>
627
628         * Makefile.am (ltosymtab_SOURCES, liblto_plugin_la_SOURCES):
629         Update the location of common.c.
630         * Makefile.in: Regenerate.
631         * common.c: Moved to gcc/lto.
632         * common.h: Moved to gcc/lto.
633         * lto-plugin.c: Update the location of common.h.
634         * lto-symtab.c: Update the location of common.h.
635
636 2008-09-23 Rafael Espindola  <espindola@google.com>
637
638         * common.c: Include common.h.
639         (lto_kind_str, lto_visibility_str, lto_resolution_str): Use explicit
640         sizes.
641         * common.h (lto_kind_str, lto_visibility_str, lto_resolution_str): Use
642         explicit sizes.
643
644 2008-09-23 Rafael Espindola  <espindola@google.com>
645
646         * lto-plugin.c (plugin_file_info): Add temp.
647         (cleanup_handler): Only delete temporary files.
648         (claim_file_handler): Initialize lto_file.temp.
649
650 2008-09-23  Rafael Espindola  <espindola@google.com>
651
652         * plugin-api.h: Moved to include.
653
654 2008-09-23 Rafael Espindola  <espindola@google.com>
655
656         * lto-plugin.c (all_symbols_read_handler): Print resolution in a new
657         format.
658
659 2008-09-22 Rafael Espindola  <espindola@google.com>
660
661         * plugin-api.h: Copy from binutils' cvs.
662
663 2008-09-22 Rafael Espindola  <espindola@google.com>
664
665         * lto-symtab.c (get_symbols, add_symbols): Update signature.
666         * plugin-api.h: Copy from binutils' cvs.
667
668 2008-09-22 Rafael Espindola  <espindola@google.com>
669
670         * common.h (lto_kind_str, lto_visibility_str, lto_resolution_str):
671         Make extern
672
673 2008-09-10 Rafael Espindola  <espindola@google.com>
674
675         * lto-plugin.c (onload): add missing break statements and asserts.
676         * lto-symtab.c (claim_file_handler): Make it static.
677         (all_symbols_read_handler): Make it static.
678         (all_file_handles): Make it static.
679         (num_file_handles): Make it static.
680         (register_claim_file): Make it static.
681         (register_object): Indent properly.
682
683 2008-09-10  Rafael Avila de Espindola  <espindola@google.com>
684
685         * Makefile.am (ltosymtab_LDADD): Add -lelf.
686         * Makefiel.in: Regenerate.
687         * lto-plugin.c: Include ar.h.
688         (claim_file_handler): Handle file->offset != 0.
689         * lto-symtab.c: Include gelf.h.
690         (all_file_handles): Change type.
691         (register_object): New.
692         (register_file): Add support for archives.
693         (resolve): Update to new type of all_file_handles.
694         (print): Update to new type of all_file_handles.
695         (free_all): Update to new type of all_file_handles.
696         (main): Update to new type of all_file_handles.
697
698 2008-09-10  Rafael Avila de Espindola  <espindola@google.com>
699
700         * lto-plugin.c (get_string_table): Remove.
701         (get_section): Use elf_strptr instead of get_string_table.
702
703 2008-09-08  Doug Kwan  <dougkwan@google.com>
704
705         * lto-plugin.c (all_symbols_read_handler): Widen fprintf arguments
706         to 64-bit to fix a 32-bit bootstrap failure due to format warnings.
707
708 2008-09-08  Rafael Avila de Espindola  <espindola@google.com>
709
710         * Makefile.am (ltosymtab_SOURCES): add common.c.
711         (ltosymtab_CFLAGS): New.
712         (liblto_plugin_la_SOURCES): Add common.c.
713         * Makefile.in: Regenerate.
714         * common.c: New.
715         * common.h: New.
716         * lto-plugin.c: Include stdio.h, inttypes.h and common.h.
717         (plugin_symtab): New.
718         (plugin_file_info): New.
719         (register_all_symbols_read): New.
720         (get_symbols): New.
721         (claimed_files): New.
722         (num_claimed_files): New.
723         (translate): Don't drop the slot number.
724         (free_1): New.
725         (free_2): New.
726         (all_symbols_read_handler): New.
727         (claim_file_handler): Record every claimed file.
728         (onload): Handle LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK and
729         LDPT_GET_SYMBOLS.
730         * lto-symtab.c: Include stdlib.h, string.h and common.h.
731         (current_file_handle): Remove.
732         (ld_plugin_all_symbols_read_handler): New.
733         (plugin_handle): New.
734         (file_handle): New.
735         (all_file_handles): New.
736         (num_file_handles): New.
737         (get_symbols): New.
738         (register_all_symbols_read): New.
739         (add_symbols): Don't print the symbols, just record them.
740         (ld_plugin_tv): Add LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK and
741         LDPT_GET_SYMBOLS.
742         (load_plugin): Use plugin_handle.
743         (register_file): Add the file handle to all_file_handles.
744         (resolve): New.
745         (print): New.
746         (unload_plugin): New.
747         (free_all): New.
748         (main): Call all_symbols_read_handler and free resources.
749
750 2008-09-03  Rafael Avila de Espindola  <espindola@google.com>
751
752         * Makefile.am (AM_CFLAGS): New.
753         (ltosymtab_LDADD): Remove -lelf. Add -ldl.
754         (lib_LTLIBRARIES): New.
755         (liblto_plugin_la_SOURCES): New.
756         (liblto_plugin_la_LIBADD): New.
757         * Makefile.in: Regenerate.
758         * acinclude.m4: Don't include ../config/acx.m4 and
759         ../config/no-executables.m4.
760         Include ../ltsugar.m4, ../ltoptions.m4, ../ltversion.m4 and
761         ../libtool.m4.
762         * aclocal.m4: Regenerate.
763         * configure: Regenerate.
764         * configure.ac: Use AM_PROG_LIBTOOL.
765         * lto-plugin.c: New.
766         * lto-symtab.c: Rewrite to use the plugin.
767         * plugin-api.h: New.
768
769 2008-08-25  Rafael Avila de Espindola  <espindola@google.com>
770
771         * configure: Regenerate.
772         * configure.ac: Use AC_CHECK_GELF.
773         * lto-symtab.c: Include gelf.h.
774         (get_string_table): Use size independent API.
775         (printTable): Use lld to print 64 bit integers.
776
777 2008-08-22  Rafael Avila de Espindola  <espindola@google.com>
778
779         * lto-symtab.c (parse_table_entry): Assert entry->kind and
780         entry->visibility are valid.
781
782 2008-07-22  Rafael Avila de Espindola  <espindola@google.com>
783         * lto-symtab.c (table_entry): Add comdat.
784         (parse_table_entry): Read comdat.
785
786 2008-08-21  Rafael Espindola  <espindola@google.com>
787
788         * Makefile.am: New.
789         * Makefile.in: New.
790         * acinclude.m4: New.
791         * aclocal.m4: New.
792         * configure: New.
793         * configure.ac: New.
794         * lto-symtab.c: New.