OSDN Git Service

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