1 2024-01-04 David Malcolm <dmalcolm@redhat.com>
3 * lang.opt.urls: New file, autogenerated by
4 regenerate-opt-urls.py.
6 2023-12-05 Richard Sandiford <richard.sandiford@arm.com>
8 * lto-lang.cc (lto_gnu_attribute_table): Add extra braces to work
9 around PR 16333 in older compilers.
10 (lto_format_attribute_table): Likewise.
12 2023-12-02 Richard Sandiford <richard.sandiford@arm.com>
14 * lto-lang.cc (lto_format_attribute_table): Change type to
15 scoped_attribute_specs, using...
16 (lto_format_attributes): ...this as the underlying array.
17 (lto_attribute_table): Change to an array of scoped_attribute_specs
19 (lto_gnu_attributes, lto_gnu_attribute_table): ...these new globals
20 for the original array. Include the format attributes.
21 (LANG_HOOKS_COMMON_ATTRIBUTE_TABLE): Delete.
22 (LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE): Delete.
23 (LANG_HOOKS_ATTRIBUTE_TABLE): Define.
25 2023-11-07 Joseph Myers <joseph@codesourcery.com>
27 * lto-lang.cc (flag_isoc2x): Rename to flag_isoc23.
29 2023-09-30 Eugene Rozenfeld <erozen@microsoft.com>
31 * Make-lang.in: Make create_fdas_for_lto1 target not .PHONY
33 2023-09-19 Thomas Schwinge <thomas@codesourcery.com>
34 Pan Li <pan2.li@intel.com>
36 * lto-common.cc (lto_mode_identity_table): Remove.
37 (lto_file_finalize) [!ACCEL_COMPILER]: 'NULL'-intialize
38 'file_data->mode_table'.
39 (lto_fe_init): Don't initialize 'lto_mode_identity_table'.
40 * lto-common.h (lto_mode_identity_table): Remove.
42 2023-07-05 Robin Dapp <rdapp@ventanamicro.com>
43 Juzhe-Zhong <juzhe.zhong@rivai.ai>
45 * lto-lang.cc (lto_type_for_mode): Ditto.
47 2023-07-04 Pan Li <pan2.li@intel.com>
48 Thomas Schwinge <thomas@codesourcery.com>
50 * lto-common.cc (lto_file_finalize) [!ACCEL_COMPILER]: Initialize
51 'file_data->mode_bits'.
53 2023-07-04 Thomas Schwinge <thomas@codesourcery.com>
55 * lto-common.cc (lto_read_decls): Adjust.
57 2023-06-29 Qing Zhao <qing.zhao@oracle.com>
59 * lto-common.cc (compare_tree_sccs_1): Compare bit
60 TYPE_NO_NAMED_ARGS_STDARG_P or TYPE_INCLUDES_FLEXARRAY properly
61 for its corresponding type.
63 2023-06-29 Eugene Rozenfeld <erozen@microsoft.com>
65 * Make-lang.in: Pass correct stage lto when processing
66 profile data collected while building target libraries
68 2023-06-28 Richard Biener <rguenther@suse.de>
70 * lto-common.cc (compare_tree_sccs_1): Use TYPE_PRECISION_RAW.
72 2023-05-18 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
74 * lto-common.cc (lto_maybe_register_decl): Use _P defines from tree.h.
75 * lto-symtab.cc (warn_type_compatibility_p): Ditto.
76 (lto_symtab_resolve_replaceable_p): Ditto.
77 (lto_symtab_merge_decls_1): Ditto.
78 * lto-symtab.h (lto_symtab_prevailing_decl): Ditto.
80 2023-04-28 Eugene Rozenfeld <erozen@microsoft.com>
82 * Make-lang.in: Merge perf data collected when compiling lto1 and runtime libraries
84 2023-03-01 Jakub Jelinek <jakub@redhat.com>
87 * lto-common.cc (lto_fixup_prevailing_type): Don't add t to
88 TYPE_POINTER_TO or TYPE_REFERENCE_TO chain if it has
89 TYPE_ATTRIBUTES or is TYPE_REF_IS_RVALUE.
91 2023-01-13 Richard Biener <rguenther@suse.de>
93 * lto-lang.cc (lto_type_for_mode): Sync with
94 c_common_type_for_mode.
96 2023-01-04 Jan Hubicka <hubicka@ucw.cz>
98 * lto-partition.cc (may_need_named_section_p): Clones with no body
101 2022-12-29 Alexandre Oliva <oliva@adacore.com>
103 * lto-partition.cc (lto_1_to_1_map): Drop NULL partition
106 2022-12-22 Richard Biener <rguenther@suse.de>
108 * lto-common.cc (compare_tree_sccs_1): Compare DECL_NOT_FLEXARRAY.
110 2022-12-21 Jan Hubicka <hubicka@ucw.cz>
112 * lto-common.cc (lto_resolution_read): With incremental linking
113 and whole program ignore turn LDPR_PREVAILING_DEF_IRONLY to
114 LDPR_PREVAILING_DEF_IRONLY_EXP
115 * lto-lang.cc (lto_post_options): Do not clear flag_whole_program
118 2022-11-25 Martin Liska <mliska@suse.cz>
121 * lto.cc (materialize_cgraph): Call timevar_push before
122 materialization starts.
124 2022-10-29 Thomas Schwinge <thomas@codesourcery.com>
126 * lang.opt: Better separate 'LTO' vs. 'LTODump'.
128 2022-10-28 Joseph Myers <joseph@codesourcery.com>
130 * lto-common.cc (compare_tree_sccs_1): Compare
131 TYPE_NO_NAMED_ARGS_STDARG_P.
133 2022-10-28 Martin Liska <mliska@suse.cz>
135 * lto-dump.cc (dump_list): Remove trailing return.
136 (dump_symbol): Likewise.
137 (dump_body): Filter name based on mangled name.
138 (dump_tool_help): Use GIMPLE wording.
139 (lto_main): Update wording.
141 2022-10-27 Martin Liska <mliska@suse.cz>
144 * lto-dump.cc (lto_main): Do not load LTO stream for aliases.
146 2022-09-15 Richard Biener <rguenther@suse.de>
148 * lto-lang.cc (lto_build_c_type_nodes): Do not initialize
151 2022-08-22 Martin Liska <mliska@suse.cz>
154 * lto.cc (wait_for_child): Ask if we are connected to jobserver.
155 (stream_out_partitions): Likewise.
157 2022-08-10 Martin Liska <mliska@suse.cz>
160 * lto.cc (wait_for_child): Decrement nruns once a process
162 (stream_out_partitions): Use job server if active.
163 (do_whole_program_analysis): Likewise.
165 2022-07-08 Martin Liska <mliska@suse.cz>
167 * lto-dump.cc (lto_main): Exit in the function
168 as we don't want any LTO bytecode processing.
170 2022-06-27 David Malcolm <dmalcolm@redhat.com>
172 * lto-dump.cc: Add "final" and "override" to various vfunc
173 implementations, removing redundant "virtual" as appropriate.
175 2022-05-16 Martin Liska <mliska@suse.cz>
177 * lto-common.cc (lto_resolution_read): Use ARRAY_SIZE.
178 * lto-lang.cc (lto_init): Likewise.
180 2022-03-23 Tobias Burnus <tobias@codesourcery.com>
183 * lto-partition.cc (maybe_rewrite_identifier): Use get_identifier
184 for the returned string to be usable as hash key.
185 (validize_symbol_for_target): Hence, use return value directly.
186 (privatize_symbol_name_1): Track maybe_rewrite_identifier renames.
187 * lto.cc (offload_handle_link_vars): Move function up before ...
188 (do_whole_program_analysis): Call it after static renamings.
189 (lto_main): Move call after static renamings.
191 2022-02-04 Richard Biener <rguenther@suse.de>
195 * lto-common.cc (compare_tree_sccs_1): Compare CLOBBER_KIND.
197 2022-02-02 Martin Liska <mliska@suse.cz>
200 * lto-common.cc (read_cgraph_and_symbols): Move resolution
201 checking for number of files later and report a reasonable
203 * lto-object.cc (lto_obj_file_open): Make error fatal.
205 2022-01-17 Martin Liska <mliska@suse.cz>
207 * config-lang.in: Rename .c names to .cc.
208 * lang-specs.h: Likewise.
209 * lto-common.cc (gimple_register_canonical_type_1): Likewise.
210 * lto-common.h: Likewise.
211 * lto-dump.cc (lto_main): Likewise.
212 * lto-lang.cc (handle_fnspec_attribute): Likewise.
213 (lto_getdecls): Likewise.
214 (lto_init): Likewise.
215 * lto.cc (lto_main): Likewise.
218 2022-01-17 Martin Liska <mliska@suse.cz>
220 * common.c: Moved to...
221 * common.cc: ...here.
222 * lto-common.c: Moved to...
223 * lto-common.cc: ...here.
224 * lto-dump.c: Moved to...
225 * lto-dump.cc: ...here.
226 * lto-lang.c: Moved to...
227 * lto-lang.cc: ...here.
228 * lto-object.c: Moved to...
229 * lto-object.cc: ...here.
230 * lto-partition.c: Moved to...
231 * lto-partition.cc: ...here.
232 * lto-symtab.c: Moved to...
233 * lto-symtab.cc: ...here.
237 2021-11-18 Jan Hubicka <hubicka@ucw.cz>
239 * lto-partition.c (promote_symbol): Clear semantic_interposition flag.
241 2021-11-06 Jan Hubicka <hubicka@ucw.cz>
245 * lto-partition.c (must_not_rename): Update comment.
246 (promote_symbol): Set resolution to LDPR_PREVAILING_DEF_IRONLY.
248 2021-10-22 Eric Gallager <egallager@gcc.gnu.org>
251 * Make-lang.in: Add dummy lto.install-dvi target.
253 2021-09-27 Martin Liska <mliska@suse.cz>
255 * lto-lang.c (lto_init_options_struct): Set also
256 x_flag_default_complex_method.
258 2021-09-03 Jakub Jelinek <jakub@redhat.com>
261 * lto-common.c (compare_tree_sccs_1): Also compare
262 DECL_FIELD_CXX_ZERO_WIDTH_BIT_FIELD values.
264 2021-09-02 liuhongt <hongtao.liu@intel.com>
266 * lto-lang.c (lto_type_for_mode): Return float16_type_node
267 when mode == TYPE_MODE (float16_type_node).
269 2021-05-31 Martin Liska <mliska@suse.cz>
271 * lto-common.c (compare_tree_sccs_1): Compare
272 FUNCTION_DECL_DECL_TYPE.
274 2021-05-24 Wang Liushuai <wangliushuai@bytedance.com>
276 * lto-dump.c (get_size): Fix the NPD error about the thunk symbol.
278 2021-04-15 Jan Hubicka <hubicka@ucw.cz>
281 * lto.c (lto_wpa_write_files): Fix handling of clones.
283 2021-04-08 Martin Sebor <msebor@redhat.com>
286 * lto-lang.c (lto_post_options): Correct spelling.
288 2021-02-28 Jakub Jelinek <jakub@redhat.com>
291 * lto-symtab.c (lto_symtab_prevailing_virtual_decl): Fix comment
292 typos - refernced -> referenced and
293 devirtualizaiton -> devirtualization.
295 2020-12-16 Martin Liska <mliska@suse.cz>
297 * lang.opt: Remove usage of Report.
299 2020-11-20 Jakub Jelinek <jakub@redhat.com>
302 * Make-lang.in (lto1.serial, lto2.serial): Change from goals to
304 (.PHONY): Drop lto1.serial, lto2.serial, lto1.prev and lto2.prev.
305 ($(LTO_EXE)): Depend on $(lto1.serial) rather than lto1.serial.
306 ($(LTO_DUMP_EXE)): Depend on $(lto2.serial) rather than lto2.serial.
308 2020-11-18 Jerry Clcanny <a837940593@gmail.com>
310 * lto-symtab.c (lto_symtab_merge_symbols): Fix typos in comment.
312 2020-11-18 Jakub Jelinek <jakub@redhat.com>
314 * Make-lang.in (lto, lto1.serial, lto2.serial): New goals.
315 (.PHONY): Add lto lto1.serial lto1.prev lto2.serial lto2.prev.
316 (lto.all.cross, lto.start.encap): Remove dependencies.
317 ($(LTO_EXE)): Depend on lto1.prev. Call LINK_PROGRESS.
318 ($(LTO_DUMP_EXE)): Depend on lto2.prev. Call LINK_PROGRESS.
320 2020-11-17 Jan Hubicka <jh@suse.cz>
323 * lto-common.c (gimple_register_canonical_type_1): Only
324 register types with TYPE_CXX_ODR_P flag; sanity check that no
325 conflict happens at ltrans time.
327 2020-11-06 Nathan Sidwell <nathan@acm.org>
329 * lto-symtab.c (lto_symtab_merge_decls_1): Rename
330 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
332 2020-10-28 Jakub Jelinek <jakub@redhat.com>
335 * lto-common.c (lto_fixup_prevailing_decls): Don't use
336 LTO_NO_PREVAIL on TREE_LIST's TREE_PURPOSE.
337 * lto-partition.c (lto_balanced_map): Treat declare_variant_alt
338 nodes like definitions.
340 2020-10-23 Jan Hubicka <hubicka@ucw.cz>
342 * lto-partition.c (add_symbol_to_partition_1): Update for new thunk
345 2020-08-27 Martin Liska <mliska@suse.cz>
347 * lto-common.c (lto_file_finalize): Set exact argument of a vector
348 growth function to true.
350 2020-06-03 Jan Hubicka <hubicka@ucw.cz>
352 * lto-common.c (compare_tree_sccs_1): Do not compare TYPE_VALUES.
354 2020-05-22 Jan Hubicka <hubicka@ucw.cz>
356 * lto-common.c (lto_read_decls): Do not skip stray refs.
358 2020-05-20 Jan Hubicka <hubicka@ucw.cz>
360 * lto-common.c (compare_tree_sccs_1): Sanity check that we never
361 read TRANSLATION_UNIT_DECL.
362 (process_dref): Break out from ...
363 (unify_scc): ... here.
364 (process_new_tree): Break out from ...
365 (lto_read_decls): ... here; handle streaming of singleton trees.
366 (print_lto_report_1): Update statistics.
368 2020-05-07 Richard Biener <rguenther@suse.de>
371 * lto-common.c (compare_tree_sccs_1): Compare
372 DECL_NOT_GIMPLE_REG_P.
374 2020-04-29 Jakub Jelinek <jakub@redhat.com>
377 * lto-common.c (compare_tree_sccs_1): Handle DECL_FIELD_ABI_IGNORED.
379 2020-04-17 Martin Liska <mliska@suse.cz>
382 * lto-common.c: Initialize file_data->lto_section_header
383 before lto_mode_identity_table call. It is needed because
384 it decompresses a LTO section.
386 2020-04-08 Martin Liska <mliska@suse.cz>
389 * lto-common.c (compare_tree_sccs_1): Compare also
390 DECL_IS_REPLACEABLE_OPERATOR.
392 2020-03-25 Jakub Jelinek <jakub@redhat.com>
395 * lto-lang.c (lto_set_decl_assembler_name): Use a static ulong
396 counter instead of DECL_UID.
398 2020-03-24 Tobias Burnus <tobias@codesourcery.com>
401 * lto.c (offload_handle_link_vars): Propagate TREE_PUBLIC state.
403 2020-01-29 Tobias Burnus <tobias@codesourcery.com>
405 * lto.c (offload_handle_link_vars): Reduce chance of
406 naming clashes of generated linkptr variable.
408 2020-01-29 Tobias Burnus <tobias@codesourcery.com>
411 * lto.c (offload_handle_link_vars): Cleanup; call
412 build_decl to ensure alignment is set.
414 2020-02-05 Martin Liska <mliska@suse.cz>
417 * lto-dump.c (dump_list_functions): Do not
418 load body for aliases.
419 (dump_body): Likewise here.
421 2020-01-16 Martin Liska <mliska@suse.cz>
423 * lto-partition.c (lto_balanced_map): Remember
424 best_noreorder_pos and then restore to it
427 2020-01-08 Martin Liska <mliska@suse.cz>
429 * lto-partition.c (add_symbol_to_partition_1): Use ::dump_name or
430 ::dump_asm_name instead of (::name or ::asm_name).
431 (lto_balanced_map): Likewise.
432 (promote_symbol): Likewise.
433 (rename_statics): Likewise.
434 * lto.c (lto_wpa_write_files): Likewise.
436 2020-01-08 Martin Liska <mliska@suse.cz>
438 * lto-partition.c (lto_balanced_map): Use symtab_node::dump_name.
440 2020-01-01 Jakub Jelinek <jakub@redhat.com>
442 Update copyright years.
444 2019-12-19 Jan Hubicka <hubicka@ucw.cz>
445 Xi Ruoyao <xry111@mengyan1223.wang>
447 * lto-common.c (read_cgraph_and_symbols): Work around binutils
450 2019-12-07 Jan Hubicka <hubicka@ucw.cz>
452 * lto-partition.c (lto_balanced_map): Fix printing of tp_first_run.
454 2019-12-10 Jan Hubicka <hubicka@ucw.cz>
456 * lto-partition.c (node_cmp): Turn into simple order comparsions.
457 (varpool_node_cmp): Remove.
458 (add_sorted_nodes): Use node_cmp.
459 (lto_balanced_map): Use tp_first_run_node_cmp.
461 2019-11-25 Joseph Myers <joseph@codesourcery.com>
464 * lto-lang.c (lto_type_for_mode): Handle decimal floating-point
465 types being NULL_TREE.
467 2019-11-22 Jan Hubicka <jh@suse.cz>
469 * lto.c (lto_wpa_write_files): Call memory_block_pool::trim.
471 2019-11-14 Martin Liska <mliska@suse.cz>
473 * Make-lang.in: Remove wrong dependency
474 of LTO_DUMP_EXE on LTO_EXE.
476 2019-11-12 Martin Liska <mliska@suse.cz>
478 * lto-common.c: Do not include params.h.
479 * lto-partition.c: Likewise.
482 2019-11-12 Martin Liska <mliska@suse.cz>
484 * lto-partition.c (lto_balanced_map): Replace old parameter syntax
485 with the new one, include opts.h if needed. Use SET_OPTION_IF_UNSET
487 * lto.c (do_whole_program_analysis): Likewise.
489 2019-11-11 Martin Liska <mliska@suse.cz>
491 * Make-lang.in: Relax dependency of lto-dump.o to
492 LTO_OBJS which will allow faster linking (mainly with LTO).
494 2019-11-07 Jan Hubicka <hubicka@ucw.cz>
496 * lto.c (do_whole_program_analysis): Call lto_free_file_name_hash.
498 2019-11-02 Jan Hubicka <hubicka@ucw.cz>
500 * lto-common.c (read_cgraph_and_symbols): Improve -Q reporting.
501 * lto.c (lto_wpa_write_files): Likewise.
503 2019-10-31 Jakub Jelinek <jakub@redhat.com>
506 * lto-lang.c (handle_const_attribute): Don't call fndecl_built_in_p
507 on *node that is not FUNCTION_DECL.
509 2019-10-30 Martin Liska <mliska@suse.cz>
513 * lto-common.c (lto_file_finalize): Use lto_get_summary_section_data.
514 (get_section_data): Add order argument.
516 2019-10-29 Martin Liska <mliska@suse.cz>
518 * lto.c (do_whole_program_analysis): Pass
519 title as dump_memory_report argument.
521 2019-10-29 Martin Liska <mliska@suse.cz>
523 * lto.c (do_whole_program_analysis): Remove argument.
525 2019-10-24 Jan Hubicka <hubicka@ucw.cz>
527 * lto-partition.c (add_symbol_to_partition_1): Update.
528 (undo_parittion): Update.
530 2019-10-23 Jan Hubicka <hubicka@ucw.cz>
532 * lto-common.c (lto_file_finalize): Add order attribute.
533 (lto_create_files_from_ids): Pass order.
534 (lto_file_read): UPdate call of lto_create_files_from_ids.
536 2019-10-12 Jan Hubicka <hubicka@ucw.cz>
538 * lto-common.c (read_cgraph_and_symbols): Grow ggc memory use after
541 2019-10-12 Jan Hubicka <hubicka@ucw.cz>
543 * lto.c (lto_wpa_write_files): Do not update bodies of clones.
545 2019-10-11 Jan Hubicka <hubicka@ucw.cz>
547 * lto.c (lto_wpa_write_files): Call ggc_trim.
549 2019-10-11 Jan Hubicka <hubicka@ucw.cz>
551 * lto.c (lto_wpa_write_files): Prepare all bodies for streaming.
553 2019-10-10 Richard Biener <rguenther@suse.de>
555 * lto-common.c (unify_scc): Do not merge anonymous NAMESPACE_DECLs.
557 2019-10-04 Joseph Myers <joseph@codesourcery.com>
559 * lto-lang.c (flag_isoc2x): New variable.
561 2019-09-18 Richard Biener <rguenther@suse.de>
564 * lto.c (lto_materialize_function): Initialize EH by looking
565 at the function personality and flag_exceptions setting.
567 2019-08-23 Jakub Jelinek <jakub@redhat.com>
570 * lto-lang.c (lto_post_options): Set flag_excess_precision instead of
571 flag_excess_precision_cmdline. Remove comment.
573 2019-08-13 Richard Sandiford <richard.sandiford@arm.com>
576 * lto-common.c (compare_tree_sccs_1): Use DECL_UNCHECKED_FUNCTION_CODE
577 instead of DECL_FUNCTION_CODE.
578 * lto-symtab.c (lto_symtab_merge_p): Likewise.
580 2019-08-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
582 * Make-lang.in (lto.install-common): Remove unnecessary slash
583 between $(DESTDIR) and $(bindir).
585 2019-07-25 Martin Liska <mliska@suse.cz>
587 * lto-common.c (compare_tree_sccs_1): Use new macros
588 (e.g. DECL_SET_LAMBDA_FUNCTION and DECL_LAMBDA_FUNCTION_P).
590 2019-07-22 Giuliano Belinassi <giuliano.belinassi@usp.br>
592 * lang.opt (flag_dump_callgraph): New flag.
593 * lto-dump.c (dump_symtab_graphviz): New function.
594 (dump_tool_help): New option.
595 (lto_main): Handle graphviz dumping.
597 2019-07-18 Jan Hubicka <hubicka@ucw.cz>
599 * lto-common.c (gimple_register_canonical_type_1): Do not look for
600 non-ODR conflicts of types in anonymous namespaces.
601 (unify_scc): Do not merge anonymous namespace types.
603 2019-07-09 Martin Sebor <msebor@redhat.com>
606 * lto-common.c (lto_splay_tree_new): : Change class-key of PODs
607 to struct and others to class.
608 (mentions_vars_p): Same.
609 (register_resolution): Same.
610 (lto_register_var_decl_in_symtab): Same.
611 (lto_register_function_decl_in_symtab): Same.
613 (lto_read_decls): Same.
615 2019-07-09 Martin Sebor <msebor@redhat.com>
618 * lto-dump.c: Change class-key from class to struct and vice versa
619 to match convention and avoid -Wclass-is-pod and -Wstruct-no-pod.
621 2019-07-04 Martin Liska <mliska@suse.cz>
624 * lto-common.c (lto_file_finalize): Use memcpy to set
625 file_data->lto_section_header.
627 2019-07-03 Martin Liska <mliska@suse.cz>
629 * lto-common.c: Read LTO section and verify header.
631 2019-06-27 Jan Hubicka <jh@suse.cz>
633 * lto-common.c (lto_register_canonical_types_for_odr_types):
634 Copy CXX_ODR_P from the main variant.
636 2019-06-27 Jan Hubicka <jh@suse.cz>
638 * lto-common.c: tree-pretty-print.h
639 (type_streaming_finished): New static var.
640 (gimple_register_canonical_type_1): Return updated hash; handle ODR
642 (iterative_hash_canonical_type): Update use of
643 gimple_register_canonical_type_1.
645 2019-06-27 Martin Liska <mliska@suse.cz>
647 * lto-dump.c (struct symbol_entry): Add default dtor.
648 (struct variable_entry): Likewise.
649 (struct function_entry): Likewise.
650 (dump_list_functions): Release memory.
651 (dump_list_variables): Likewise.
653 2019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
655 * lto-lang.c (lto_build_c_type_nodes): Accept "__intN__"
656 format of "__intN" types for SIZE_TYPE.
658 2019-06-24 Jan Hubicka <jh@suse.cz>
660 * lto-common.c (compare_tree_sccs_1): Compare CXX_ODR_P;
661 compare STRING_FLAG only for arrays and integers.
663 2019-06-05 Martin Sebor <msebor@redhat.com>
665 * lto-common.c (lto_file_finalize): Adjust quoting and hyphenation.
667 2019-05-16 Martin Sebor <msebor@redhat.com>
669 * lto-dump.c (lto_main): Same.
670 * lto.c (stream_out): Same.
672 2019-05-10 Martin Liska <mliska@suse.cz>
674 * Make-lang.in: Use program_transform_name for lto-dump.
675 * config-lang.in: Do not mark lto-dump compiler as we don't
676 want to have it installed at
677 lib/gcc/x86_64-pc-linux-gnu/10.0.0/lto-dump.
679 2019-05-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
681 * lto-common.c (lto_file_read): Print section->start as int64_t,
682 section->len as uint64_t.
683 * lto-dump.c (symbol_entry::dump): Print sz as uint64_t.
685 2019-05-06 Martin Liska <mliska@suse.cz>
687 * lto-common.c: Update coding style.
688 * lto.c (materialize_cgraph): Likewise.
690 2019-05-06 Hrishikesh Kulkarni <hrishikeshparag@gmail.com>
691 Martin Liska <mliska@suse.cz>
693 * Make-lang.in: Add lto_dump-related definition.
694 * config-lang.in: Likewise.
695 * lang.opt: Add new language LTODump and options related
697 * lto-common.c (lto_read_decls): Support type statistics dump.
698 (lto_file_read): Likewise for object files.
699 * lto-dump.c: New file.
700 * lto-lang.c (lto_option_lang_mask): Move from ..
701 * lto.c (lto_option_lang_mask): .. here.
702 * lto.h (lto_option_lang_mask): New declaration.
704 2019-05-06 Martin Liska <mliska@suse.cz>
705 Hrishikesh Kulkarni <hrishikeshparag@gmail.com>
707 * Make-lang.in: Add lto-common.o.
708 * config-lang.in: Likewise for gtfiles.
709 * lto-common.c: New file.
710 * lto-common.h: New file.
711 * lto-lang.c: Include lto-common.h.
712 * lto.c: Move most of the functionality
713 into lto-common.c file.
715 2019-04-12 Jan Hubicka <hubicka@ucw.cz>
717 * lto.c (do_stream_out): rename to ...
718 (stream_out): ... this one; move original code to ...
719 (stream_out_partitions_1, stream_out_partitions): ... these new
721 (lto_wpa_write_files): Honnor lto_parallelism
723 2019-03-26 Martin Liska <mliska@suse.cz>
725 * lto-symtab.c (lto_symtab_merge_decls_2): Fix option name
728 2019-03-11 Martin Liska <mliska@suse.cz>
730 * lto-lang.c (lto_post_options): Wrap an option name
731 in a string format message and fix GNU coding style.
732 * lto-symtab.c (lto_symtab_merge_decls_2): Likewise.
734 2019-03-09 Jakub Jelinek <jakub@redhat.com>
737 * lang.opt: Terminate description text with a dot.
739 2019-02-28 Jason Merrill <jason@redhat.com>
741 PR c++/88049 - ICE with undefined destructor and anon namespace.
742 * lto-symtab.c (lto_symtab_prevailing_virtual_decl): Return early
743 for a type in an anonymous namespace.
745 2019-01-09 Sandra Loosemore <sandra@codesourcery.com>
749 * lto-partition.c: Mechanically replace "can not" with "cannot".
750 * lto-symtab.c: Likewise.
753 2019-01-01 Jakub Jelinek <jakub@redhat.com>
755 Update copyright years.
757 2018-12-24 Jan Hubicka <hubicka@ucw.cz>
759 * lto-symtab.c (lto_symtab_merge_decls_2): Do not report ODR violations
760 for method whose basetype was already reported.
762 2018-11-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
764 Minimize clone counter memory usage in LTO.
765 * lto-partition.c (privatize_symbol_name_1): Keep track of
766 non-unique symbol counters in the lto_clone_numbers hash
768 (lto_promote_cross_file_statics): Allocate and free the
769 lto_clone_numbers hash map.
770 (lto_promote_statics_nonwpa): Free the lto_clone_numbers hash
773 2018-11-28 Jan Hubicka <jh@suse.cz>
775 * lto.c (lto_read_decls): Fix handling of INTEGER_CST.
777 2018-11-22 Jan Hubicka <jh@suse.cz>
779 * lto.c (cmp_type_location): Remove.
780 (lto_read_decls): Do not allocate odr_types.
782 2018-11-19 Martin Liska <mliska@suse.cz>
785 * lto-symtab.c (lto_symtab_merge): Transform the
786 condition before r256989.
788 2018-11-16 Martin Liska <mliska@suse.cz>
791 * lto-symtab.c (lto_symtab_merge_symbols_1): Do not call
792 lto_symtab_symbol_p as it does checking of transparent alias.
793 These needs to be also merged in the function.
795 2018-10-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
797 * lto-partition.c (privatize_symbol_name_1): Use
798 clone_function_name_numbered.
800 2018-10-26 Jan Hubicka <jh@suse.cz>
802 * lto-symtab.c (lto_symtab_merge_decls_2): Fix extra space.
804 2018-10-17 David Malcolm <dmalcolm@redhat.com>
806 * Make-lang.in (selftest-lto): New.
808 2018-08-29 Martin Liska <mliska@suse.cz>
811 * lto.c (read_cgraph_and_symbols): Fix thinko, revert
812 to behavior before r263887.
814 2018-08-27 Martin Liska <mliska@suse.cz>
816 * lto-lang.c (handle_const_attribute): Use new function
817 fndecl_built_in_p and remove check for FUNCTION_DECL if
819 * lto-symtab.c (lto_symtab_merge_p): Likewise.
820 (lto_symtab_merge_decls_1): Likewise.
821 (lto_symtab_merge_symbols): Likewise.
822 * lto.c (lto_maybe_register_decl): Likewise.
823 (read_cgraph_and_symbols): Likewise.
825 2018-08-21 Tom de Vries <tdevries@suse.de>
827 * lto.c (lto_main): Call debuginfo_early_start and
828 debuginfo_early_stop.
830 2018-07-20 Martin Sebor <msebor@redhat.com>
833 * lto-lang.c (lto_handle_option): Change function argument
836 2018-07-20 Richard Biener <rguenther@suse.de>
839 * lto.c (unify_scc): Before we throw away an SCC see if we
840 can amend prevailing single-entry SCC with debug refs.
842 2018-07-13 Jan Hubicka <hubicka@ucw.cz>
844 * lto.c (do_stream_out): Add PART parameter; open dump file.
845 (stream_out): Add PART parameter; pass it to do_stream_out.
846 (lto_wpa_write_files): Update call of stream_out.
848 2018-07-04 Martin Liska <mliska@suse.cz>
853 * lto.c (compare_tree_sccs_1): Use cl_optimization_option_eq
856 2018-06-20 Martin Liska <mliska@suse.cz>
858 * lto-symtab.c (lto_symtab_merge_p): Remove not valid
861 2018-06-19 Martin Liska <mliska@suse.cz>
863 * lto-partition.c (add_symbol_to_partition_1): Use symbol_summary::get instead
865 (undo_partition): Likewise.
866 (lto_balanced_map): Likewise.
868 2018-06-19 Martin Liska <mliska@suse.cz>
870 * config-lang.in: Remove stagestuff.
872 2018-06-08 Jan Hubicka <hubicka@ucw.cz>
874 * lto-lang.c (lto_link_dump_id, decl_merge_dump_id, partition_dump_id):
876 (lto_register_dumps): New hook.
877 (LANG_HOOKS_REGISTER_DUMPS): New.
878 * lto-partition.c: Dump into dump_file instead of symtab->dump_file.
879 * lto-symtab.c: Include lto.h; dump into dump_file instead of
881 (lto_symtab_merge_decls): Initialize dump file.
882 * lto.c (read_cgraph_and_symbols): Initialize dump file.
883 (do_whole_program_analysis): Likewise.
885 2018-06-08 Martin Liska <mliska@suse.cz>
887 * lto-partition.c (lto_balanced_map): Use cgraph_node::uid
888 instead of summary_uid.
890 2018-06-08 Martin Liska <mliska@suse.cz>
892 * lto-partition.c (add_symbol_to_partition_1): Use get_create instead
894 (undo_partition): Likewise.
895 (lto_balanced_map): Likewise.
897 2018-06-08 Martin Liska <mliska@suse.cz>
899 * lto-partition.c (add_references_to_partition): Remove support
900 for MPX (macros, related functions, fields in cgraph_node, ...).
901 (add_symbol_to_partition_1): Likewise.
902 (privatize_symbol_name): Likewise.
903 * lto-symtab.c (lto_cgraph_replace_node): Likewise.
905 2018-06-05 Richard Biener <rguenther@suse.de>
907 * lto.c (cmp_type_location): Expand locations only once.
909 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
911 * lang.opt (lto_linker_output): Add nolto-rel.
912 * lto-lang.c (lto_post_options): Handle LTO_LINKER_OUTPUT_REL
913 and LTO_LINKER_OUTPUT_NOLTOREL.
914 (lto_init): Generate lto when doing incremental link.
915 * lto.c (lto_precess_name): Add lto1-inclink.
917 2018-05-18 Jan Hubicka <jh@suse.cz>
920 * lto-partition.c (account_reference_p): Do not account
921 references from aliases; do not account refernces from
922 external initializers.
924 2018-04-30 Jan Hubicka <jh@suse.cz>
926 * lto.c (cmp_partitions_size): Remove.
927 (lto_wpa_write_files): Also output priorities; do not sort partitions.
928 (cmp_partition_order): Move to ...
929 * lto-partition.c (cmp_partition_order): ...
930 (lto_1_to_1_map): Sort partitions.
932 2018-04-20 Jan Hubicka <jh@suse.cz>
934 * lto-partition.c (lto_balanced_map): Fix sanity check.
936 2018-04-19 Jan Hubicka <jh@suse.cz>
938 * lto-partition.c: Include sreal.h
939 (add_symbol_to_partition_1): Use size instead of self_size
941 (account_reference_p): New.
942 (lto_balanced_map): Use 64bit arithmetics for size calculatoins; cleanup;
943 fix accounting errors in boundary size; add debug output; combine cost
944 as cost/size instead of cost/internal; reduce the partitioning error to
945 +- 1/8 of the parttion size.
947 2018-04-19 Martin Liska <mliska@suse.cz>
949 * lto-symtab.c (lto_symtab_resolve_symbols): Do not bail out
950 for multiple PREVAILING_DEF_IRONLY for common symbols.
952 2018-04-18 Martin Liska <mliska@suse.cz>
954 * lto.c (lto_read_decls): Fix GNU coding style and typos.
956 2018-04-18 Martin Liska <mliska@suse.cz>
960 * lto.c (cmp_type_location): New function.
961 (lto_read_decls): First collect all types, then
962 sort them according by location before register_odr_type
965 2018-04-18 Jan Hubicka <jh@suse.cz>
966 Martin Liska <mliska@suse.cz>
969 * lto.c (lto_read_decls): Do not test TYPE_CANONICAL before registering odr
972 2018-04-11 Martin Liska <mliska@suse.cz>
974 * lto-symtab.c (lto_symtab_merge_p): Use attribute_value_equal
977 2018-04-10 Martin Liska <mliska@suse.cz>
980 * lto-symtab.c (lto_symtab_merge_p): Do not check for
981 TREE_VALUES of error attributes.
983 2018-04-10 Richard Biener <rguenther@suse.de>
984 Martin Liska <mliska@suse.cz>
987 * lto-symtab.c (lto_symtab_merge_p): Handle noreturn attribute.
989 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
991 * lto-partition.c (lto_balanced_map): Watch overflow.
993 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
996 * lto.c (unify_scc): Register prevailing trees, not trees to be freed.
997 (read_cgraph_and_symbols): Use
998 symtab_node::output_to_lto_symbol_table_p.
1000 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
1002 * lto.c (register_resolution): Remove forgotten sanity check.
1004 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
1007 * lto.c: Include builtins.h
1008 (register_resolution): Merge resolutions in case trees was
1009 merged across units.
1010 (lto_maybe_register_decl): Break out from ...
1011 (lto_read_decls): ... here.
1012 (unify_scc): Also register decls here.
1013 (read_cgraph_and_symbols): Sanity check that all resolutions was
1016 2018-02-02 Eric Botcazou <ebotcazou@adacore.com>
1019 * lto-symtab.c (warn_type_compatibility_p): Do not recurse into the
1020 component type of array types with non-aliased component.
1022 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
1025 * lto-symtab.c (warn_type_compatibility_p): Silence false positive
1026 for type match warning on arrays of pointers.
1028 2018-01-23 Martin Liska <mliska@suse.cz>
1031 * lto-symtab.c (lto_symtab_merge): Handle and do not warn about
1032 trailing arrays at the end of a struct.
1034 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
1035 Alan Hayward <alan.hayward@arm.com>
1036 David Sherwood <david.sherwood@arm.com>
1038 * lto-lang.c (lto_type_for_mode): Handle MODE_VECTOR_BOOL.
1040 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
1041 Alan Hayward <alan.hayward@arm.com>
1042 David Sherwood <david.sherwood@arm.com>
1044 * lto-lang.c (lto_type_for_mode): Check valid_vector_subparts_p.
1045 * lto.c (hash_canonical_type): Handle polynomial TYPE_VECTOR_SUBPARTS.
1047 2018-01-03 Jakub Jelinek <jakub@redhat.com>
1049 Update copyright years.
1051 2017-12-15 Jakub Jelinek <jakub@redhat.com>
1053 * lto-lang.c (lto_attribute_table, lto_format_attribute_table): Swap
1054 affects_type_identity and handler fields, adjust comments.
1056 2017-12-07 Richard Sandiford <richard.sandiford@arm.com>
1058 * lto.c (compare_tree_sccs_1): Compare the new VECTOR_CST flags.
1060 2017-12-07 Martin Sebor <msebor@redhat.com>
1063 * lto-lang.c (lto_attribute_table): Initialize new member of struct
1066 2017-11-30 Jakub Jelinek <jakub@redhat.com>
1068 * lto.c (create_subid_section_table): Use ; instead of ;;.
1070 2017-11-22 Marek Polacek <polacek@redhat.com>
1075 * lto.c (compare_tree_sccs_1): Compare TYPE_EMPTY_P and DECL_PADDING_P.
1077 2017-11-10 Jan Hubicka <hubicka@ucw.cz>
1079 * lto-partition.c (lto_balanced_map): Use frequency accessor.
1081 2017-10-13 Jan Hubicka <hubicka@ucw.cz>
1083 * lto-lang.c (lto_post_options): Clean shlib flag when not doing PIC.
1085 2017-10-11 Nathan Sidwell <nathan@acm.org>
1087 * lto.c (mentions_vars_p_decl_with_vis): Use
1088 DECL_ASSEMBLER_NAME_RAW.
1089 (lto_fixup_prevailing_decls): Likewise.
1091 2017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
1093 * lto.c (compare_tree_sccs_1): Use wi::to_wide when
1094 operating on trees as wide_ints.
1096 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1097 Alan Hayward <alan.hayward@arm.com>
1098 David Sherwood <david.sherwood@arm.com>
1100 * lto-lang.c (lto_type_for_mode): Use as_a <scalar_int_mode>.
1102 2017-08-21 Richard Biener <rguenther@suse.de>
1104 * lto.c (unify_scc): Truncate DIE reference queue for dropped SCCs.
1105 (lto_read_decls): Process TRANSLATION_UNIT_DECLs. Remove
1106 TYPE_DECL debug processing, register DIE references from
1107 prevailing SCCs with the debug machinery.
1108 (lto_section_with_id): Handle LTO debug sections.
1110 2017-08-16 Nathan Sidwell <nathan@acm.org>
1112 * lto.c (mentions_vars_p_type): Use TYPE_LANG_SLOT_1.
1113 (compare_tree_sccs_1): No need to compare TYPE_BINFO directly.
1114 (lto_fixup_prevailing_decls): Use TYPE_LANG_SLOT_1.
1116 2017-08-08 Tom de Vries <tom@codesourcery.com>
1118 * lto.c: Include attribs.h.
1120 2017-08-08 Martin Liska <mliska@suse.cz>
1122 * lto-lang.c: Include header files.
1123 * lto-symtab.c: Likewise.
1125 2017-08-03 Richard Biener <rguenther@suse.de>
1127 * lto-symtab.h (lto_symtab_prevail_decl): Do not use
1128 DECL_ABSTRACT_ORIGIN as flag we can end up using that. Instead
1129 use DECL_LANG_FLAG_0.
1130 (lto_symtab_prevail_decl): Likewise.
1132 2017-07-07 Torsten Duwe <duwe@suse.de>
1134 * lto-lang.c (lto_attribute_table): Add entry for
1135 "patchable_function_entry".
1137 2017-07-19 Nathan Sidwell <nathan@acm.org>
1139 * lto.c (mentions_vars_p_type): Use TYPE_{MIN,MAX}_VALUE_RAW.
1140 (compare_tree_sccs_1, lto_fixup_prevailing_decls): Likewise.
1142 2017-07-06 Jan Hubicka <hubicka@ucw.cz>
1144 * lto-partition.c (lto_balanced_map): Do not check
1145 flag_toplevel_reorder.
1147 2017-06-23 Marc Glisse <marc.glisse@inria.fr>
1148 * lto-lang.c (lto_init): Use builtin_structptr_types.
1150 2017-06-15 Jan Hubicka <hubicka@ucw.cz>
1151 Thomas Preud'homme <thomas.preudhomme@arm.com>
1154 * lto-symtab.c (lto_symtab_merge_symbols): Drop useless definitions
1155 that resolved externally.
1157 2017-05-23 Jan Hubicka <hubicka@ucw.cz>
1159 * lto.c (do_whole_program_analysis): Replace inline_free_summary
1160 by ipa_free_fn_summary.
1162 2017-05-23 Martin Liska <mliska@suse.cz>
1164 * lto-symtab.c (lto_cgraph_replace_node): Use
1165 symtab_node::dump_{asm_,}name functions.
1166 * lto.c (read_cgraph_and_symbols): Likewise.
1167 (do_whole_program_analysis): Likewise.
1169 2017-05-23 Martin Liska <mliska@suse.cz>
1171 * lto.c (read_cgraph_and_symbols): Use the renamed function.
1172 (do_whole_program_analysis): Use the renamed function.
1174 2017-05-22 Jan Hubicka <hubicka@ucw.cz>
1176 * lto.c: Replace ipa-inline.h by ipa-fnsummary.h
1177 * lto-partition.c: Replace ipa-inline.h by ipa-fnsummary.h
1179 2017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
1182 * lto-lang.c (lto_init): Set in_lto_p earlier.
1184 2017-04-12 Richard Biener <rguenther@suse.de>
1185 Bernd Edlinger <bernd.edlinger@hotmail.de>
1188 * lto.c (compare_tree_sccs_1): Compare TYPE_TYPELESS_STORAGE.
1190 2017-02-14 Martin Liska <mliska@suse.cz>
1192 * lto.c (do_stream_out): Free LTO file filename string.
1194 2017-01-19 David Malcolm <dmalcolm@redhat.com>
1196 * lto-lang.c (builtin_type_for_size): Convert call to
1197 lto_type_for_size to one through the langhook.
1198 (lto_type_for_size): Move to langhooks.c and rename to
1200 (LANG_HOOKS_TYPE_FOR_SIZE): Don't redefine.
1202 2017-01-11 Jakub Jelinek <jakub@redhat.com>
1205 * lto-lang.c (lto_post_options): Force flag_merge_constants = 1
1208 2017-01-09 Jakub Jelinek <jakub@redhat.com>
1210 PR translation/79019
1211 PR translation/79020
1212 * lto-symtab.c (lto_symtab_merge_symbols): Fix comment typo.
1214 2017-01-06 Nathan Sidwell <nathan@acm.org>
1216 * lto-partition.c (promote_symbol): Write to dump file sooner,
1217 include alias promoting too.
1219 * lto-partition.c (lto_balanced_map): Reformat/respell comment.
1220 (may_need_named_section_p): Likewise.
1221 (rename_statics): Likewise.
1222 (lto_promote_cross_file_statics): Likewise.
1224 2017-01-01 Jakub Jelinek <jakub@redhat.com>
1226 Update copyright years.
1228 2016-11-30 Georg-Johann Lay <avr@gjlay.de>
1231 * lto-symtab.c (lto_symtab_merge_decls_2): Don't diagnose type
1232 mismatch if the two types are built-in.
1234 2016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1236 * lto-lang.c (lto_init): Remove initialization of ptrdiff_type_node.
1238 2016-11-23 Richard Biener <rguenther@suse.de>
1241 * lto.c (hash_canonical_type): Ignore zero-sized fields.
1243 2016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
1246 * lto-lang.c (lto_init): Assert const_tm_ptr_type_node is sane.
1248 2016-11-18 Richard Sandiford <richard.sandiford@arm.com>
1249 Alan Hayward <alan.hayward@arm.com>
1250 David Sherwood <david.sherwood@arm.com>
1252 * lto.c (offload_handle_link_vars): Use SET_DECL_MODE.
1254 2016-10-31 Richard Biener <rguenther@suse.de>
1257 * lto.c (do_whole_program_analysis): Bail out after errors
1260 2016-09-21 Kugan Vivekanandarajah <kuganv@linaro.org>
1262 * lto-partition.c: Include tree-vrp.h.
1265 2016-09-20 Richard Biener <rguenther@suse.de>
1267 * lto.c (lto_main): Call early_finish with "<artificial>" as
1270 2016-09-19 Richard Biener <rguenther@suse.de>
1272 * lto.c (lto_main): Invoke early_finish debug hook.
1274 2016-07-25 Richard Biener <rguenther@suse.de>
1276 * lto.c (compare_tree_sccs_1): Remove streamer_handle_as_builtin_p uses.
1277 (unify_scc): Likewise.
1278 (lto_read_decls): Likewise.
1280 2016-06-28 Jakub Jelinek <jakub@redhat.com>
1282 * Make-lang.in: Don't cat ../stage_current if it does not exist.
1284 2016-06-23 Andi Kleen <ak@linux.intel.com>
1286 * Make-lang.in: Add support for autofdo (disabled for now)
1288 2016-06-10 Martin Sebor <msebor@redhat.com>
1291 * lto-lang.c (handle_nonnull_attribute): Accept the nonnull
1292 attribute in type-generic builtins.
1294 2016-05-16 Jan Hubicka <hubicka@ucw.cz>
1296 * lto-partition.c (add_symbol_to_partition_1): Likewise.
1298 2016-05-03 Jan Hubicka <hubicka@ucw.cz>
1300 * lto-symtab.c (lto_cgraph_replace_node): Initialize inline_failed.
1302 2016-04-27 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1304 * lto-partition.h (lto_balanced_map): New parameter.
1305 * lto-partition.c (lto_balanced_map): New parameter
1307 Check if partition size is greater than max_partition_size.
1308 * lto.c (do_whole_program_analysis): Adjust calls to
1309 lto_balanced_map() to pass 2nd argument.
1311 2016-03-17 H.J. Lu <hongjiu.lu@intel.com>
1314 * lto-lang.c (lto_post_options): Set flag_pic to flag_pie for
1317 2016-03-08 Jakub Jelinek <jakub@redhat.com>
1319 * lto-symtab.h (lto_symtab_prevail_decl): Fix spelling
1320 - becuase -> because.
1322 2016-02-15 Tom de Vries <tom@codesourcery.com>
1325 * lto.c (read_cgraph_and_symbols): Call input_offload_tables with
1328 2016-01-27 Martin Liska <mliska@suse.cz>
1330 * lto-partition.c (add_symbol_to_partition_1): Remove usage
1333 2016-01-19 Jan Hubicka <hubicka@ucw.cz>
1336 * lto-symtab.c (lto_symtab_prevailing_virtual_decl): Abstract
1337 decls have no assemblernames.
1339 2016-01-19 Martin Liska <mliska@suse.cz>
1340 Martin Jambor <mjambor@suse.cz>
1342 * lto-partition.c: Include "hsa.h"
1343 (add_symbol_to_partition_1): Put hsa implementations into the
1344 same partition as host implementations.
1346 2016-01-12 Jan Hubicka <hubicka@ucw.cz>
1349 * lto-partition.c (rename_statics): Fix pasto.
1351 2016-01-18 Richard Biener <rguenther@suse.de>
1354 * lto-symtab.c (lto_symtab_merge): Return early for mismatched
1355 function vs. variable.
1357 2016-01-12 Richard Biener <rguenther@suse.de>
1360 * lto-symtab.c (lto_symtab_prevailing_virtual_decl): Properly
1361 merge TREE_ADDRESSABLE and DECL_POSSIBLY_INLINED flags.
1363 2016-01-04 Jakub Jelinek <jakub@redhat.com>
1365 Update copyright years.
1367 2015-12-10 Jan Hubicka <hubicka@ucw.cz>
1370 * lto-symtab.c (lto_symtab_prevailing_virtual_decl): New function.
1371 * lto-symtab.h (lto_symtab_prevailing_virtual_decl): Declare.
1372 (lto_symtab_prevailing_decl): Use it.
1374 2015-12-15 Ilya Verbin <ilya.verbin@intel.com>
1376 * lto.c: Include stringpool.h and fold-const.h.
1377 (offload_handle_link_vars): New static function.
1378 (lto_main): Call offload_handle_link_vars.
1380 2015-12-10 Jan Hubicka <hubicka@ucw.cz>
1382 * lto.c (lto_read_in_decl_state): Unpickle compressed bit.
1384 2015-12-11 Jan Hubicka <hubicka@ucw.cz>
1387 * lto-symtab.c (lto_symtab_merge_p): Avoid merging across different
1388 values of error and warning attributes.
1390 2015-12-08 Jan Hubicka <hubicka@ucw.cz>
1393 * lto.c (lto_fixup_prevailing_decls): Do not check TREE_CHAIN of
1395 (LTO_NO_PREVAIL): Use gcc_checking_assert.
1397 2015-12-08 Jan Hubicka <hubicka@ucw.cz>
1400 * lto-symtab.c (lto_symtab_merge_decls_2): Decl can never be prevailed
1403 2015-12-08 Jan Hubicka <hubicka@ucw.cz>
1406 * lto-symtab.c: Include lto-symtab.h.
1407 (lto_cgraph_replace_node): Do not merge profiles here.
1408 (lto_symtab_merge_p): New function.
1409 (lto_symtab_merge_decls_2): Honor lto_symtab_merge_p.
1410 (lto_symtab_merge_symbols_1): Turn unmerged decls into transparent
1412 (lto_symtab_merge_symbols): Do not clear node->aux; we no longer use it.
1413 (lto_symtab_prevailing_decl): Move to lto-symtab.h; rewrite.
1414 * lto.c: Include lto-symtab.h
1415 * lto-symtab.h: New.
1417 2015-12-08 Jan Hubicka <hubicka@ucw.cz>
1420 * lto-partition.c (add_symbol_to_partition_1): Transparent aliases
1421 are not part of the definition.
1422 (contained_in_symbol): Likewise.
1423 (promote_symbol): When promoting a symbol also promote all transparent
1425 (rename_statics): Weakref needs unique name, too.
1427 2015-12-07 Jan Hubicka <hubicka@ucw.cz>
1430 * lto-partition.c (add_symbol_to_partition_1, contained_in_symbol,
1431 rename_statics, rename_statics): Handle transparent aliases.
1433 2015-12-04 Jan Hubicka <hubicka@ucw.cz>
1435 * lto-symtab.c (lto_cgraph_replace_node): Update code computing
1438 2015-12-01 Jan Hubicka <hubicka@ucw.cz>
1440 * lto.c (compare_tree_sccs_1): Do not compare TYPE_ALIAS_SET.
1442 2015-11-25 Jan Hubicka <jh@suse.cz>
1444 * lto-lang.c (lto_post_options): Process flag_lto_linker_output.
1445 * lang.opt (lto_linker_output): New enum.
1446 (flinker_output): New flag.
1448 2015-11-24 Jan Hubicka <hubicka@ucw.cz>
1450 * lto-symtab.c: Include alias.h
1451 (warn_type_compatibility_p): Replace types_compatible_p checks by
1452 TBAA and size checks; set bit 2 if locations are TBAA incompatible.
1453 (lto_symtab_merge): Compare DECL sizes.
1454 (lto_symtab_merge_decls_2): Warn about TBAA in compatibility.
1456 2015-11-24 Jan Hubicka <hubicka@ucw.cz>
1458 * lto.c (iterative_hash_canonical_type): Recruse for all types
1459 which pass !canonical_type_used_p.
1460 (gimple_register_canonical_type_1): Sanity check we do not compute
1461 canonical type of anything with !canonical_type_used_p.
1462 (gimple_register_canonical_type): Skip all types that are
1463 !canonical_type_used_p
1465 2015-11-24 Jan Hubicka <hubicka@ucw.cz>
1467 * lto.c (unify_scc): Use free_node.
1469 2015-11-21 Jan Hubicka <hubicka@ucw.cz>
1471 * lto.c (iterative_hash_canonical_type): Always recurse for pointers.
1472 (gimple_register_canonical_type_1): Check that pointers do not get
1474 (gimple_register_canonical_type): Do not register pointers.
1476 2015-11-21 Jan Hubicka <hubicka@ucw.cz>
1478 * lto-symtab.c (warn_type_compatibility_p): Do not set ODR mismatch
1479 flag for types that are not ODR; fix loop walking parameters.
1481 2015-11-11 Andrew MacLeod <amacleod@redhat.com>
1483 * lto-lang.c: Remove unused header files.
1484 * lto-object.c: Likewise.
1485 * lto-partition.c: Likewise.
1486 * lto-symtab.c: Likewise.
1489 2015-11-08 Eric Botcazou <ebotcazou@adacore.com>
1491 * lto.c (compare_tree_sccs_1): Deal with TYPE_REVERSE_STORAGE_ORDER.
1493 2015-11-07 Richard Sandiford <richard.sandiford@arm.com>
1495 * lto-lang.c: Don't undef DEF_BUILTIN.
1497 2015-10-29 Andrew MacLeod <amacleod@redhat.com>
1499 * lto-lang.c: Reorder #include's and remove duplicates.
1500 * lto-object.c: Likewise.
1501 * lto-partition.c: Likewise.
1502 * lto-symtab.c: Likewise.
1505 2015-10-27 Mikhail Maltsev <maltsevm@gmail.com>
1507 * lto.c (unify_scc): Use flag_checking and remove ENABLE_CHECKING
1509 (lto_fixup_state): Likewise.
1510 (do_whole_program_analysis): Use
1511 symtab_node::checking_verify_symtab_nodes and remove ENABLE_CHECKING
1514 2015-10-13 Jakub Jelinek <jakub@redhat.com>
1516 * lto-lang.c (DEF_FUNCTION_TYPE_9, DEF_FUNCTION_TYPE_10,
1517 DEF_FUNCTION_TYPE_11): Define.
1519 2015-10-10 Jan Hubicka <hubicka@ucw.cz>
1521 * lto.c (hash_canonical_type): Honor
1522 type_with_interoperable_signedness.
1524 2015-09-28 Nathan Sidwell <nathan@codesourcery.com>
1526 * lto-lang.c (DEF_FUNCTION_TYPE_VAR_6): New.
1527 (DEF_FUNCTION_TYPE_VAR_11): Delete.
1529 2015-08-31 Richard Biener <rguenther@suse.de>
1531 * lto.c (compare_tree_sccs_1): Compare DECL_ABSTRACT_ORIGIN.
1532 * lto-symtab.c (lto_symtab_merge): Merge DECL_POSSIBLY_INLINED flag.
1533 (lto_symtab_prevailing_decl): Do not replace a decl that didn't
1534 participate in merging with something else.
1536 2015-08-31 Richard Biener <rguenther@suse.de>
1538 * lto-symtab.c (lto_symtab_prevailing_decl): Remove redundant
1539 test, do not replace a non-builtin with a builtin.
1540 * lto.c (compare_tree_sccs_1): Do not merge things we stream
1541 as builtins vs. non-builtins.
1543 2015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
1545 * lto.h: Remove useless typedefs.
1547 2015-07-15 Andrew MacLeod <amacleod@redhat.com>
1549 * lto.c: Remove redundant includes.
1551 2015-07-12 Aldy Hernandez <aldyh@redhat.com>
1553 * lto-lang.c: Fix double word typos.
1555 2015-07-10 Andrew MacLeod <amacleod@redhat.com>
1557 * lto.c: Include cfghooks.h rather than predict.h.
1559 2015-07-09 Andrew MacLeod <amacleod@redhat.com>
1561 * lto-lang.c: Adjust includes of target.h, alloc-pool.h and
1563 * lto-object.c: Likewise.
1564 * lto-partition.c: Likewise.
1565 * lto-symtab.c: Likewise.
1567 2015-07-09 Andrew MacLeod <amacleod@redhat.com>
1569 * lto-lang.c: Adjust includes for flags.h changes.
1571 2015-07-07 Andrew MacLeod <amacleod@redhat.com>
1573 * lto-lang.c: Adjust includes.
1574 * lto-object.c: Likewise.
1575 * lto-partition.c: Likewise.
1576 * lto-symtab.c: Likewise.
1579 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
1581 * lto-lang.c: Remove ipa-ref.h and plugin-api.h from include list.
1582 * lto-object.c: Likewise.
1583 * lto-partition.c: Likewise.
1584 * lto-symtab.c: Likewise.
1585 * lto-tree.h: Likewise.
1588 2015-06-25 Richard Sandiford <richard.sandiford@arm.com>
1590 * lto.c (tree_scc_hasher): Inherit from nofree_ptr_hash rather
1591 than typed_noop_remove. Remove redudant typedefs.
1593 2015-06-17 Andrew MacLeod <amacleod@redhat.com>
1595 * lto-lang.c: Do not include input.h, line-map.h or is-a.h.
1596 * lto-object.c: Likewise.
1597 * lto-partition.c: Likewise.
1598 * lto-symtab.c: Likewise.
1601 2015-06-14 Jan Hubicka <hubicka@ucw.cz>
1604 * lto.c (compare_tree_sccs_1): Do not compare TYPE_NO_FORCE_BLK.
1606 2015-06-12 DJ Delorie <dj@redhat.com>
1608 * lto-lang.c (lto_type_for_size): Include intN types.
1609 (lto_type_for_mode): Likewise.
1611 2015-06-08 Jan Hubicka <hubicka@ucw.cz>
1613 * lto.c (hash_canonical_type): Drop hashing of TYPE_STRING_FLAG.
1615 2015-06-08 Andrew MacLeod <amacleod@redhat.com>
1617 * lto-lang.c : Adjust include files.
1618 * lto-object.c : Likewise.
1619 * lto-partition.c : Likewise.
1620 * lto-partition.h : Likewise.
1621 * lto-symtab.c : Likewise.
1625 2015-06-06 Jan Hubicka <hubicka@ucw.cz>
1628 * lto-symtab.c (warn_type_compatibility_p): Fix call of
1629 odr_or_derived_type_p.
1630 (lto_symtab_merge_decls_2): Update call of warn_types_mismatch.
1632 2015-06-08 Jan Hubicka <hubicka@ucw.cz>
1634 * lto.c (hash_canonical_type): Do not hash TREE_CODE of TREE_TYPE of
1637 2015-06-05 Aldy Hernandez <aldyh@redhat.com>
1639 * lto-lang.c (lto_write_globals): Remove.
1640 (LANG_HOOKS_WRITE_GLOBALS): Same.
1642 2015-06-04 Andrew MacLeod <amacleod@redhat.com>
1644 * lto-lang.c: Adjust includes for restructured coretypes.h.
1645 * lto-object.c: Likewise.
1646 * lto-partition.c: Likewise.
1647 * lto-symtab.c: Likewise.
1650 2015-06-04 Jan Hubicka <hubicka@ucw.cz>
1652 * lto.c (hash_canonical_type): Use tree_code_for_canonical_type_merging.
1654 2015-06-03 Jan Hubicka <hubicka@ucw.cz>
1656 * lto.c (iterative_hash_canonical_type,
1657 gimple_register_canonical_type): only hash main variants of types
1659 2015-05-27 Martin Liska <mliska@suse.cz>
1661 * lto-partition.c (new_partition): Reset number of symbols.
1662 (add_symbol_to_partition_1): Increment number of symbols.
1663 (undo_partition): Decrement number of symbols.
1664 (lto_balanced_map): Dump number of symbols and insns that
1665 belong to a partition.
1666 * lto-partition.h (struct ltrans_partition_def): Add symbol counter.
1668 2015-05-22 Jan Hubicka <hubicka@ucw.cz>
1670 * lto.c (hash_canonical_type): Be sure we hash only types that
1672 (gimple_register_canonical_type_1): Do not produce canonical
1673 types for types that do not need alias sets.
1675 2015-05-22 Jan Hubicka <hubicka@ucw.cz>
1677 * lto.c (hash_canonical_type): Drop hashing of METHOD_BASETYPE.
1679 2015-05-19 Jan Hubicka <hubicka@ucw.cz>
1681 * lto.c (gimple_canonical_types_compatible_p): Move to tree.c
1683 2015-05-17 Jan Hubicka <hubicka@ucw.cz>
1685 * lto-symtab.c (warn_type_compatibility_p): Break out from ...;
1686 compare ODR types (if available) and function types.
1687 (lto_symtab_merge): ... here; output ODR violation warnings
1688 and call warn_types_mismatch.
1690 2015-04-29 Jan Hubicka <hubicka@ucw.cz>
1692 * lto.c (lto_fixup_state): Call verify_type.
1694 2015-04-18 Trevor Saunders <tsaunders@mozilla.com>
1696 * lto.c: Adjust for hash_table changes.
1698 2015-03-27 Jan Hubicka <hubicka@ucw.cz>
1700 * lto.c (lto_read_decls): Move code registering odr types out
1701 of TYPE_CANONICAL conditional and also register polymorphic types.
1703 2015-03-26 Jan Hubicka <hubicka@ucw.cz>
1705 * lto-symtab.c (lto_symtab_merge_decls_2): Silence warning on
1706 DECL_ARTIFICAL symbols.
1708 2015-03-26 Jan Hubicka <hubicka@ucw.cz>
1711 * lto.c (unify_scc): Revert location cache when unification
1713 (lto_read_decls): Accept location cache after sucess;
1714 apply location cache before calling debug hooks.
1716 2015-03-10 Jan Hubicka <hubicka@ucw.cz>
1718 * lto.c (read_cgraph_and_symbols): Do not do merging
1721 2015-02-26 Jakub Jelinek <jakub@redhat.com>
1723 * lto.c (lto_mode_identity_table): New variable.
1724 (lto_read_decls): Add mode_table argument to the lto_input_block
1726 (lto_file_finalize): Initialize mode_table.
1727 (lto_init): Initialize lto_mode_identity_table.
1729 2015-02-24 Thomas Schwinge <thomas@codesourcery.com>
1732 * lto-lang.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
1734 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
1736 2015-02-03 Jan Hubicka <hubicka@ucw.cz>
1738 * lto-symtab.c (lto_cgraph_replace_node): Maintain merged flag.
1740 2015-01-30 Joseph Myers <joseph@codesourcery.com>
1742 * lto-object.c, lto-symtab.c, lto.c: All callers of fatal_error
1743 changed to pass input_location as first argument.
1745 2014-12-11 Jan Hubicka <hubicka@ucw.cz>
1747 * lto-symtab.c (lto_varpool_replace_node): Merge TLS models.
1749 2014-12-11 Jan Hubicka <hubicka@ucw.cz>
1751 * lto.c (compare_tree_sccs_1): Add comparsion of
1752 DECL_FUNCTION_SPECIFIC_TARGET
1754 2015-01-15 Thomas Schwinge <thomas@codesourcery.com>
1755 James Norris <jnorris@codesourcery.com>
1757 * lto-lang.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
1759 * lto.c: Include "gomp-constants.h".
1761 2015-01-14 Ilya Verbin <ilya.verbin@intel.com>
1763 * lto-partition.c (lto_promote_cross_file_statics): Remove argument
1764 from select_what_to_stream.
1766 2015-01-09 Bernd Schmidt <bernds@codesourcery.com>
1767 Jakub Jelinek <jakub@redhat.com>
1770 * lto.c (read_cgraph_and_symbols): Set lto_stream_offload_p
1773 2015-01-09 Michael Collison <michael.collison@linaro.org>
1775 * lto.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
1776 input.h, alias.h, symtab.h, options, fold-const.h,
1777 wide-int.h, and inchash.h due to flattening of tree.h.
1778 * lto-lang.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
1779 input.h, alias.h, symtab.h, fold-const.h,
1780 wide-int.h, and inchash.h due to flattening of tree.h.
1781 * lto-object.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
1782 input.h, alias.h, symtab.h, options, fold-const.h,
1783 wide-int.h, and inchash.h due to flattening of tree.h.
1784 * lto-partition.c: Ditto.
1785 * lto-symtab.c: Ditto.
1787 2015-01-05 Jakub Jelinek <jakub@redhat.com>
1789 Update copyright years.
1791 2014-12-22 Martin Liska <mliska@suse.cz>
1793 * lto-partition.c (add_symbol_to_partition_1): New inline_summaries
1795 (undo_partition): Likewise.
1796 (lto_balanced_map): Likewise.
1798 2014-12-22 Martin Liska <mliska@suse.cz>
1800 * lto-partition.c: Include of symbol-summary.h is added.
1801 * lto-symtab.c: Likewise.
1804 2014-12-11 Jan Hubicka <hubicka@ucw.cz>
1807 * lto.c (read_cgraph_and_symbols): Update call of
1808 remove_unreachable_nodes.
1809 (do_whole_program_analysis): Remove call of
1810 symtab->remove_unreachable_nodes
1812 2014-12-08 Trevor Saunders <tsaunders@mozilla.com>
1814 * lto.c (read_cgraph_and_symbols): allocate gimple_canonical_types
1815 htab with malloc instead of ggc.
1817 2014-11-20 Trevor Saunders <tsaunders@mozilla.com>
1819 * lto.c: Replace htab with hash_table.
1821 2014-11-20 Trevor Saunders <tsaunders@mozilla.com>
1823 * lto.c (lto_read_in_decl_state): Adjust.
1824 (lto_fixup_state): Likewise.
1826 2014-11-17 Jan Hubicka <hubicka@ucw.cz>
1828 * lto.c (lto_read_decls): Do not rebuild DECL_FUNCTION_SPECIFIC_TARGET.
1830 2014-11-14 Jan Hubicka <hubicka@ucw.cz>
1832 * lto.c (compare_tree_sccs_1): Compare cl_target_option_eq.
1834 2014-11-13 Ilya Verbin <ilya.verbin@intel.com>
1835 Bernd Schmidt <bernds@codesourcery.com>
1836 Andrey Turetskiy <andrey.turetskiy@intel.com>
1837 Michael Zolotukhin <michael.v.zolotukhin@intel.com>
1839 * lto.c (read_cgraph_and_symbols): Call input_offload_tables.
1841 2014-11-13 Ilya Verbin <ilya.verbin@intel.com>
1842 Ilya Tocar <ilya.tocar@intel.com>
1843 Andrey Turetskiy <andrey.turetskiy@intel.com>
1844 Bernd Schmidt <bernds@codesourcery.com>
1846 * lto-object.c (lto_obj_add_section): Use section_name_prefix instead of
1847 LTO_SECTION_NAME_PREFIX.
1848 * lto-partition.c (lto_promote_cross_file_statics): Call
1849 select_what_to_stream.
1850 * lto.c (lto_section_with_id): Use section_name_prefix instead of
1851 LTO_SECTION_NAME_PREFIX.
1852 (read_cgraph_and_symbols): Read OFFLOAD_SECTION_NAME_PREFIX sections, if
1853 being built as an offload compiler.
1855 2014-10-29 Richard Sandiford <richard.sandiford@arm.com>
1857 * lto-lang.c: Remove redundant enum from machine_mode.
1859 2014-10-28 Andrew MacLeod <amacleod@redhat.com>
1861 * lto.c: Adjust include files.
1862 * lto-lang.c: Ditto.
1863 * lto-object.c: Ditto.
1864 * lto-partition.c: Ditto.
1865 * lto-symtab.c: Ditto.
1867 2014-10-27 Andrew MacLeod <amacleod@redhat.com>
1869 * lto-lang.c: Adjust include files.
1870 * lto-object.c: Ditto.
1871 * lto-partition.c: Ditto.
1872 * lto-symtab.c: Ditto.
1875 2014-10-16 DJ Delorie <dj@redhat.com>
1877 * lto-object.c (lto_obj_begin_section): In the event that pointer
1878 sizes aren't powers of two, choose a more suitable alignment
1879 than (unsigned)(-1).
1881 2014-10-14 DJ Delorie <dj@redhat.com>
1883 * lto-lang.c (lto_build_c_type_nodes): Check intN types for
1885 (lto_init): Initialize all intN types, not just int128.
1887 2014-10-06 Martin Liska <mliska@suse.cz>
1889 * lto.c (stream_out): ARG_UNUSED added for last argument.
1891 2014-09-24 Aldy Hernandez <aldyh@redhat.com>
1893 * lto-symtab.c, lto.c: Rename all instances of DECL_ABSTRACT to
1896 2014-09-23 Andi Kleen <ak@linux.intel.com>
1898 * lto-partition.c (node_cmp): Update comment.
1899 (varpool_node_cmp): Use symtab_node for comparison.
1900 (add_sorted_nodes): New function.
1901 (lto_balanced_map): Change to keep ordered queue
1902 of ordered node. Handle no_reorder attribute.
1904 2014-09-11 Jan Hubicka <hubicka@ucw.cz>
1906 * lto.c (lto_read_decls): Register ODR types.
1908 2014-08-20 Jan Hubicka <hubicka@ucw.cz>
1910 * lto.c (read_cgraph_and_symbols): Fix symtab_remove_unreachable_nodes
1912 (do_whole_program_analysis): Only sanity check that IPA passes cleans up.
1914 2014-08-14 Jan Hubicka <hubicka@ucw.cz>
1916 * lto-symtab.c (lto_varpool_replace_node): Call compare_virtual_tables.
1918 2014-08-14 Richard Biener <rguenther@suse.de>
1921 * lto-lang.c (def_fn_type): Fix error handling wrt va_end.
1923 2014-08-08 Richard Biener <rguenther@suse.de>
1925 * lto.c (lto_read_decls): Adjust for lto_input_block changes.
1927 2014-08-08 Bin Cheng <bin.cheng@arm.com>
1930 * lto-lang.c (lto_init): Switch mis-matched arguments.
1932 2014-08-07 Trevor Saunders <tsaunders@mozilla.com>
1934 * lto-partition.c, lto.c: Use hash_map instead of pointer_map.
1936 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
1938 * lto-partition.c, lto-partition.h: Use hash_set instead of
1941 2014-07-31 Andi Kleen <ak@linux.intel.com>
1943 * lto.c (hash_canonical_type): Use inchash::hash
1944 and use inchash::add_expr.
1945 (iterative_hash_canonical_type): Dito.
1947 2014-07-30 Richard Biener <rguenther@suse.de>
1949 * lto-streamer.h (lto_write_data): New function.
1950 * langhooks.c (lhd_append_data): Do not free block.
1951 * lto-section-out.c (lto_write_data): New function writing
1952 raw data to the current section.
1953 (lto_write_stream): Adjust for langhook semantic change.
1954 (lto_destroy_simple_output_block): Write header directly.
1955 * lto-opts.c (lto_write_options): Write options directly.
1956 * lto-streamer-out.c (produce_asm): Write heaeder directly.
1957 (lto_output_toplevel_asms): Likewise.
1958 (copy_function_or_variable): Copy data directly.
1959 (write_global_references): Output index table directly.
1960 (lto_output_decl_state_refs): Likewise.
1961 (write_symbol): Write data directly.
1962 (produce_symtab): Adjust.
1963 (produce_asm_for_decls): Output header and refs directly.
1965 2014-07-25 Andi Kleen <ak@linux.intel.com>
1967 * lto.c (hash_canonical_type): Call iterative_hstate_expr.
1969 2014-07-25 Andi Kleen <ak@linux.intel.com>
1971 * lto.c (hash_canonical_type): Convert to inchash.
1972 (iterative_hash_canonical_type): Dito.
1974 2014-07-25 Andi Kleen <ak@linux.intel.com>
1976 * lto.c: Include inchash.h
1978 2014-07-14 Jan Hubicka <hubicka@ucw.cz>
1980 * lto.c (mentions_vars_p_decl_non_common): Skip
1982 mentions_vars_p_function): Do DECL_ARGUMENTS.
1983 (lto_fixup_prevailing_decls): Update.
1985 2014-07-12 Jan Hubicka <hubicka@ucw.cz>
1987 * lto.c (read_cgraph_and_symbols): Do not push DECL_INIT_IO
1989 (materialize_cgraph): Do not push GIMPLE_IN timevar.
1991 2014-07-11 Jan Hubicka <hubicka@ucw.cz>
1993 * lto-partition.c (add_references_to_partition): Use
1994 varpool_ctor_useable_for_folding_p.
1995 * lto.c (lto_read_in_decl_state): Update sanity check.
1997 2014-07-01 Martin Liska <mliska@suse.cz>
1999 IPA REF alias refactoring
2000 * lto-partition.c (add_symbol_to_partition_1): Usage of
2001 FOR_EACH_ALIAS added.
2003 2014-06-28 Jan Hubicka <hubicka@ucw.cz>
2006 * lto.c (lto_copy_fields_not_streamed): New function.
2007 (compare_tree_sccs_1): Do not compare fields shared in between type
2009 (lto_read_decls): Fixup types first before inserting into hash.
2011 2014-06-28 Andrew Pinski <apinski@cavium.com>
2013 * lto.c (lto_read_decls): Fix comment in comment.
2015 2014-06-28 Jan Hubicka <hubicka@ucw.cz>
2017 * lto.c (lto_copy_fields_not_streamed): New function.
2018 (compare_tree_sccs_1): Do not compare fields shared in between type
2020 (lto_read_decls): Fixup types first before inserting into hash.
2022 2014-06-25 Martin Liska <mliska@suse.cz>
2024 * lto-partition.c (add_references_to_partition): New IPA REF function
2026 (add_symbol_to_partition_1): Likewise.
2027 (lto_balanced_map): Likewise.
2028 * lto-symtab.c (lto_cgraph_replace_node): Likewise.
2030 2014-06-24 Jan Hubicka <hubicka@ucw.cz>
2032 * lto.c (mentions_vars_p_decl_non_common): Move DECL_VINDEX check to ..
2033 (mentions_vars_p_function): ... here.
2034 (compare_tree_sccs_1): Update VINDEX checks.
2035 (lto_fixup_prevailing_decls): Likewise.
2037 2014-06-24 Trevor Saunders <tsaunders@mozilla.com>
2039 * lto.c (canonical_type_hash_cache): Use hash_map instead of
2042 2014-06-24 Trevor Saunders <tsaunders@mozilla.com>
2046 2014-06-20 Jan Hubicka <hubicka@ucw.cz>
2048 * lto-symtab.c (lto_varpool_replace_node): Report TLS model conflicts.
2050 2014-06-20 Jan Hubicka <hubicka@ucw.cz>
2052 * lto.c (compare_tree_sccs_1): Do not compare priorities.
2054 2014-06-15 Jan Hubicka <hubicka@ucw.cz>
2056 * lto.c (compare_tree_sccs_1): Do not compare DECL_TLS_MODEL.
2058 2014-06-10 Jan Hubicka <hubicka@ucw.cz>
2060 * lto.c (read_cgraph_and_symbols): Remove unreachable symbols.
2061 (do_whole_program_analysis): Use verify_symtab.
2063 2014-06-07 Jan Hubicka <hubicka@ucw.cz>
2065 * lto.c (mentions_vars_p_decl_with_vis, compare_tree_sccs_1,
2066 lto_fixup_prevailing_decls): Skip section names.
2068 2014-06-02 Andrew MacLeod <amacleod@redhat.com>
2070 * lto-symtab.c: Include builtins.h.
2072 2014-05-26 Richard Biener <rguenther@suse.de>
2074 * lto.c (lto_parse_hex): Use int64_t.
2075 (lto_resolution_read): Likewise.
2077 2014-05-23 Jan Hubicka <hubicka@ucw.cz>
2079 * lto.c (read_cgraph_and_symbols): Grow ggc memory after streaming.
2081 2014-05-23 Jan Hubicka <hubicka@ucw.cz>
2083 * lto-symtab.c (lto_symtab_merge_symbols): Update code setting
2085 * lto.c (compare_tree_sccs_1): Do not compare comdat groups.
2087 2014-05-22 Thomas Schwinge <thomas@codesourcery.com>
2089 * lto-lang.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
2090 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
2091 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
2093 2012-05-22 Bernd Schmidt <bernds@codesourcery.com>
2095 * lto-object.c: Include "lto-section-names.h".
2096 (LTO_SEGMENT_NAME): Don't define.
2097 * lto.c: Include "lto-section-names.h".
2099 2014-05-17 Jan Hubicka <hubicka@ucw.cz>
2102 * lto-symtab.c (lto_symtab_merge_decls_1): Do not ICE on undefined externals
2103 mixed with variables.
2105 2014-05-17 Trevor Saunders <tsaunders@mozilla.com>
2107 * lto-tree.h: Don't use variable_size gty attribute.
2108 * lto.c (lto_read_in_decl_state): Adjust.
2109 (create_subid_section_table): Likewise.
2110 (lto_flatten_files): Likewise.
2111 (read_cgraph_and_symbols): Likewise.
2113 2014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
2114 Mike Stump <mikestump@comcast.net>
2115 Richard Sandiford <rdsandiford@googlemail.com>
2117 * lto.c (compare_tree_sccs_1): Use wide-int interfaces.
2118 * lto-lang.c (get_nonnull_operand): Likewise.
2120 2014-04-28 Richard Biener <rguenther@suse.de>
2123 * lto-lang.c: Define flag_isoc11.
2125 2014-04-23 David Malcolm <dmalcolm@redhat.com>
2127 * lto-partition.c (add_references_to_partition): Update for
2128 removal of implicit pointer from the is-a.h API.
2129 (add_symbol_to_partition_1): Likewise.
2130 (contained_in_symbol): Likewise.
2131 (undo_partition): Likewise.
2132 (lto_balanced_map): Likewise.
2133 (promote_symbol): Likewise.
2134 * lto-symtab.c (lto_symtab_merge_symbols_1): Likewise.
2135 (lto_symtab_merge_symbols): Likewise.
2136 * lto.c (lto_wpa_write_files): Likewise.
2138 2014-04-15 Richard Biener <rguenther@suse.de>
2140 * lto.c: Include params.h.
2141 (do_whole_program_analysis): Switch on flag_lto_partition value,
2142 add support for LTO_PARTITION_ONE.
2143 * lto-partition.h (lto_balanced_map): Adjust.
2144 * lto-partition.c (lto_balanced_map): Get number of desired
2145 partitions as argument to support -flto-partition=one.
2147 2014-04-14 Jan Hubicka <hubicka@ucw.cz>
2149 * lto-symtab.c (lto_cgraph_replace_node): Don't re-merge
2152 2014-03-19 Jan Hubicka <hubicka@ucw.cz>
2154 * lto.c: Include ipa-inline.h
2155 (do_whole_program_analysis): Free inline summary after partitioning.
2157 2014-03-19 Richard Biener <rguenther@suse.de>
2160 * lto-tree.h (lang_tree_node): For types use TYPE_NEXT_VARIANT
2161 instead of TREE_CHAIN as chain_next.
2163 2014-03-19 Richard Biener <rguenther@suse.de>
2165 * lto.c (lto_wpa_write_files): Move call to
2166 lto_promote_cross_file_statics ...
2167 (do_whole_program_analysis): ... here, into the partitioning
2168 block. Do not ggc_collect after lto_wpa_write_files but
2169 for a last time before it.
2171 2014-03-19 Jakub Jelinek <jakub@redhat.com>
2174 * lto.c (wait_for_child): Define WCONTINUED if not defined to 0.
2177 2014-03-18 Jakub Jelinek <jakub@redhat.com>
2180 * lto-lang.c (lto_init): Add NAME_TYPE for int128_integer_type_node
2181 and complex_{float,{,long_}double}_type_node.
2183 2014-03-08 Paulo Matos <paulo@matos-sorge.com>
2185 * lto-lang.c (lto_init): Pass flag_short_double to
2186 build_common_tree_nodes.
2188 2014-02-14 Jan Hubicka <hubicka@ucw.cz>
2191 * lto.c (stream_out): Avoid parallel streaming with
2192 -flto=jobserver until we are able to throttle it down
2195 2014-02-14 Jan Hubicka <hubicka@ucw.cz>
2197 * lto-partition.c (add_symbol_to_partition_1,
2198 undo_partition, lto_balanced_map): Aliases have no
2200 (lto_balanced_map): Do not follow refering variables
2201 if they can be optimized out.
2203 2014-02-14 Richard Biener <rguenther@suse.de>
2206 * lto.c (compare_tree_sccs_1): Do not compare
2207 DECL_FUNCTION_SPECIFIC_TARGET.
2208 (lto_read_decls): Re-build DECL_FUNCTION_SPECIFIC_TARGET.
2210 2014-02-12 Richard Biener <rguenther@suse.de>
2213 * lto-lang.c (lto_write_globals): Do not call
2214 wrapup_global_declarations or emit_debug_global_declarations
2215 but emit debug info for non-function scope variables
2218 2014-02-06 Jan Hubicka <hubicka@ucw.cz>
2220 * lto.c (unify_scc): Free CONSTRUCTOR_ELTS.
2222 2014-02-06 Jan Hubicka <hubicka@ucw.cz>
2225 * lto-partition.c (symbol_class): Move to cgraph.h
2226 (get_symbol_class): Move to symtab.c
2227 (add_references_to_partition, add_symbol_to_partition_1,
2228 lto_max_map, lto_1_to_1_map, lto_balanced_map,
2229 lto_promote_cross_file_statics): Update.
2231 2014-02-05 Jan Hubicka <hubicka@ucw.cz>
2233 * lto.c (lto_parallelism): New static var.
2234 (do_stream_out, wait_for_child, stream_out): New static functions.
2235 (lto_wpa_write_files): Add support for parallel streaming.
2236 (do_whole_program_analysis): Set parallelism.
2237 * lang.opt (fwpa): Add parameter.
2238 * lto-lang.c (lto_handle_option): Handle flag_wpa.
2239 (lto_init): Update use of flag_wpa.
2240 * lto-streamer.h (asm_nodes_output): Declare.
2242 2014-02-05 Richard Biener <rguenther@suse.de>
2244 * lto.h (lto_global_var_decls): Remove.
2245 * lto-lang.c (lto_init): Do not allocate lto_global_var_decls.
2246 (lto_write_globals): Do nothing in WPA stage, gather globals from
2247 the varpool here ...
2248 * lto.c (lto_main): ... not here.
2249 (materialize_cgraph): Do not call rest_of_decl_compilation
2250 on the empty lto_global_var_decls vector.
2251 (lto_global_var_decls): Remove.
2253 2014-02-04 Jan Hubicka <hubicka@ucw.cz>
2255 * lto-partition.c (get_symbol_class): Only unforced DECL_ONE_ONLY
2256 needs duplicating, not generic COMDAT.
2258 2014-02-04 Richard Biener <rguenther@suse.de>
2261 * lto.c (mentions_vars_p): Handle NAMELIST_DECL.
2262 (lto_fixup_prevailing_decls): Handle fixing up CONSTRUCTOR values.
2264 2014-02-04 Jan Hubicka <hubicka@ucw.cz>
2268 * lto-symtab.c (lto_cgraph_replace_node, lto_varpool_replace_node):
2269 merge force_output and forced_by_abi flags.
2271 2014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
2273 * lto-lang.c (lto_init): Replaced flag_enable_cilkplus with
2276 2014-01-09 Richard Biener <rguenther@suse.de>
2278 * lto.c (gimple_canonical_types_compatible_p): Fix comment.
2280 2014-01-09 Richard Biener <rguenther@suse.de>
2283 * lto.c (hash_canonical_type): Do not hash TREE_ADDRESSABLE,
2284 TYPE_ALIGN, TYPE_RESTRICT or TYPE_REF_CAN_ALIAS_ALL.
2285 (gimple_canonical_types_compatible_p): Do not compare them either.
2287 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
2289 Update copyright years
2291 2013-12-06 Oleg Endo <olegendo@gcc.gnu.org>
2293 * lto.c: Remove struct tags when referring to class varpool_node.
2294 * lto-partition.c: Likewise.
2295 * lto-symtab.c: Likewise.
2297 2013-11-29 Jakub Jelinek <jakub@redhat.com>
2298 Richard Biener <rguenther@suse.de>
2301 * lto.c (compare_tree_sccs_1): Handle OMP_CLAUSE.
2303 2013-11-29 Jakub Jelinek <jakub@redhat.com>
2306 * lto.c (mentions_vars_p_omp_clause): New function.
2307 (mentions_vars_p): Call it for OMP_CLAUSE. Remove break;
2310 2013-11-22 Andrew MacLeod <amacleod@redhat.com>
2312 * lto.c: Add required include files from gimple.h.
2313 * lto-lang.c: Likewise.
2314 * lto-object.c: Likewise.
2315 * lto-partition.c: Likewise.
2316 * lto-symtab.c: Likewise.
2318 2013-11-18 Trevor Saunders <tsaunders@mozilla.com>
2320 * lto-partition.c lto-symtab.c lto.c Adjust.
2322 2013-11-14 Diego Novillo <dnovillo@google.com>
2324 * lto-lang.c: Include stringpool.h.
2325 Include stor-layout.h.
2326 * lto-partition.c: Include gcc-symtab.h.
2327 * lto.c: Include stor-layout.h.
2329 2013-10-31 David Malcolm <dmalcolm@redhat.com>
2331 Automated part of renaming of symtab_node_base to symtab_node.
2333 Patch autogenerated by rename_symtab.py from
2334 https://github.com/davidmalcolm/gcc-refactoring-scripts
2335 revision 58bb219cc090b2f4516a9297d868c245495ee622
2337 * lto-partition.c (add_symbol_to_partition): Rename
2338 symtab_node_base to symtab_node.
2339 (get_symbol_class): Likewise.
2340 (symbol_partitioned_p): Likewise.
2341 (add_references_to_partition): Likewise.
2342 (add_symbol_to_partition_1): Likewise.
2343 (contained_in_symbol): Likewise.
2344 (add_symbol_to_partition): Likewise.
2345 (lto_1_to_1_map): Likewise.
2346 (lto_max_map): Likewise.
2347 (lto_balanced_map): Likewise.
2348 (privatize_symbol_name): Likewise.
2349 (promote_symbol): Likewise.
2350 (may_need_named_section_p): Likewise.
2351 (rename_statics): Likewise.
2352 (lto_promote_statics_nonwpa): Likewise.
2353 * lto-symtab.c (lto_symtab_merge): Likewise.
2354 (lto_symtab_resolve_replaceable_p): Likewise.
2355 (lto_symtab_symbol_p): Likewise.
2356 (lto_symtab_resolve_can_prevail_p): Likewise.
2357 (lto_symtab_resolve_symbols): Likewise.
2358 (lto_symtab_merge_decls_2): Likewise.
2359 (lto_symtab_merge_decls_1): Likewise.
2360 (lto_symtab_merge_decls): Likewise.
2361 (lto_symtab_merge_symbols_1): Likewise.
2362 (lto_symtab_merge_symbols): Likewise.
2363 (lto_symtab_prevailing_decl): Likewise.
2364 * lto.c (lto_wpa_write_files): Likewise.
2365 (read_cgraph_and_symbols): Likewise.
2366 (do_whole_program_analysis): Likewise.
2368 2013-10-30 David Malcolm <dmalcolm@redhat.com>
2370 * lto-symtab.c (lto_symtab_merge_decls_2): Split symtab_node
2371 declarations onto multiple lines to make things easier for
2373 (lto_symtab_merge_decls_1): Likewise.
2374 (lto_symtab_merge_symbols_1): Likewise.
2376 2013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
2378 * Make-lang.in (lto/lto-lang.o): Added cilk.h in dependency list.
2379 * lto-lang.c (lto_init): Added a call to cilk_init_builtins if Cilk
2382 2013-10-29 David Malcolm <dmalcolm@redhat.com>
2384 Patch autogenerated by refactor_symtab.py from
2385 https://github.com/davidmalcolm/gcc-refactoring-scripts
2386 revision 58bb219cc090b2f4516a9297d868c245495ee622
2388 * lto-partition.c (lto_promote_cross_file_statics): Update for
2389 conversion of symtab types to a true class hierarchy.
2390 (rename_statics): Likewise.
2391 (promote_symbol): Likewise.
2392 (privatize_symbol_name): Likewise.
2393 (lto_balanced_map): Likewise.
2394 (varpool_node_cmp): Likewise.
2395 (node_cmp): Likewise.
2396 (lto_1_to_1_map): Likewise.
2397 (undo_partition): Likewise.
2398 (add_symbol_to_partition): Likewise.
2399 (contained_in_symbol): Likewise.
2400 (add_symbol_to_partition_1): Likewise.
2401 (add_references_to_partition): Likewise.
2402 (symbol_partitioned_p): Likewise.
2403 (get_symbol_class): Likewise.
2404 (lto_max_map): Likewise.
2405 * lto-symtab.c (lto_symtab_prevailing_decl): Likewise.
2406 (lto_symtab_merge_symbols): Likewise.
2407 (lto_symtab_merge_symbols_1): Likewise.
2408 (lto_symtab_merge_decls): Likewise.
2409 (lto_symtab_merge_decls_1): Likewise.
2410 (lto_symtab_merge_decls_2): Likewise.
2411 (lto_symtab_resolve_symbols): Likewise.
2412 (lto_symtab_resolve_can_prevail_p): Likewise.
2413 (lto_symtab_symbol_p): Likewise.
2414 (lto_symtab_resolve_replaceable_p): Likewise.
2415 (lto_symtab_merge): Likewise.
2416 (lto_varpool_replace_node): Likewise.
2417 (lto_cgraph_replace_node): Likewise.
2418 * lto.c (lto_main): Likewise.
2419 (do_whole_program_analysis): Likewise.
2420 (materialize_cgraph): Likewise.
2421 (read_cgraph_and_symbols): Likewise.
2422 (cmp_partitions_order): Likewise.
2423 (lto_materialize_function): Likewise.
2424 (has_analyzed_clone_p): Likewise.
2426 2013-10-29 Andrew MacLeod <amacleod@redhat.com>
2428 * lto-object.c: Add gimple.h to include list.
2429 * lto-partition.c: Likewise.
2431 2013-10-18 Andrew MacLeod <amacleod@redhat.com>
2433 * lto.c: Remove tree-flow.h from include list.
2435 2013-10-15 Richard Biener <rguenther@suse.de>
2437 * lto.c (hash_canonical_type): Split out from ...
2438 (iterative_hash_canonical_type): ... here. Register types
2440 (gimple_canonical_type_hash): Adjust.
2441 (gimple_register_canonical_type_1): Split out from ...
2442 (gimple_register_canonical_type): ... here. Cache computed
2444 (lto_register_canonical_types): Split into two modes,
2445 clearing and computing TYPE_CANONICAL.
2446 (lto_read_decls): Adjust.
2447 (read_cgraph_and_symbols): Do two passes over global trees,
2448 first clearing then computing TYPE_CANONICAL.
2450 2013-10-14 Richard Biener <rguenther@suse.de>
2452 * lto.c (gimple_canonical_types): Move out-of GC space.
2453 (canonical_type_hash_cache): Make a pointer-map.
2454 (num_canonical_type_hash_entries, num_canonical_type_hash_queries):
2456 (iterative_hash_canonical_type): Adjust.
2457 (read_cgraph_and_symbols): Likewise.
2458 (print_lto_report_1): Likewise.
2460 2013-10-14 Richard Biener <rguenther@suse.de>
2462 * lto.c (gimple_types, type_hash_cache, struct type_pair_d,
2463 type_pair_cache, lookup_type_pair, struct sccs, next_dfs_num,
2464 gtc_next_dfs_num, compare_type_names_p, gtc_visit,
2465 gimple_types_compatible_p_1, gimple_types_compatible_p,
2466 visit, iterative_hash_name, struct type_hash_pair,
2467 type_hash_pair_compare, iterative_hash_gimple_type, gimple_type_hash,
2468 gimple_type_eq, gimple_register_type, num_not_merged_types,
2469 num_not_merged_types_in_same_scc, num_not_merged_types_trees,
2470 num_not_merged_types_in_same_scc_trees): Remove old merging code
2472 (lto_read_decls): Do not run old merging code in parallel.
2473 (read_cgraph_and_symbols): Do not init/free old merging
2475 (print_lto_report_1): Do not report differences of old vs. new
2478 2013-10-14 Richard Biener <rguenther@suse.de>
2480 * lto-lang.c (lto_init): Do not re-init canonical types here.
2481 (lto_register_canonical_types): Move to ...
2482 * lto.c (lto_register_canonical_types): ... here.
2483 (gimple_canonical_types, canonical_type_hash_cache,
2484 iterative_hash_canonical_type, gimple_canonical_type_hash,
2485 gimple_canonical_types_compatible_p, gimple_canonical_type_eq,
2486 gimple_register_canonical_type): Add canonical type merging machinery
2487 moved from gimple.c.
2488 (read_cgraph_and_symbols): Init and free canonical type tables
2490 (print_lto_report_1): Report canonical type table stats here.
2492 2013-10-11 Jakub Jelinek <jakub@redhat.com>
2494 * lto-lang.c (DEF_FUNCTION_TYPE_8): Define.
2496 2013-09-25 Tom Tromey <tromey@redhat.com>
2498 * Make-lang.in (LTO_H, LINKER_PLUGIN_API_H, LTO_TREE_H)
2499 (lto/lto-lang.o, lto/lto.o, lto/lto-partition.o)
2500 (lto/lto-object.o): Remove.
2502 2013-09-06 Richard Biener <rguenther@suse.de>
2504 * lto-symtab.c: Move from gcc/
2505 * lto.h: Include vec.h.
2506 (lto_global_var_decls): Declare.
2507 * lto.c (lto_global_var_decls): Move definition here.
2508 * Make-lang.in (LTO_OBJS): Add lto-symtab.o.
2509 (lto-symtab.o): Add.
2510 * config-lang.in (gtfiles): Add lto.h.
2512 2013-08-31 Jan Hubicka <jh@suse.cz>
2514 * lto.c (mentions_vars_p_field_decl, lto_fixup_prevailing_decls):
2515 DECL_FIELD_OFFSET can contain an reference to variable.
2517 2013-08-31 Jan Hubicka <jh@suse.cz>
2519 * lto.c (tree_with_vars): Turn into vector.
2520 (MAYBE_REMEMBER_WITH_VARS): Change to...
2521 (CHECK_VAR): ... this one.
2522 (CHECK_NO_VAR): New macro.
2523 (maybe_remember_with_vars_typed): Turn to ...
2524 (mentions_vars_p_typed): ... this one.
2525 (maybe_remember_with_vars_common): Turn to ...
2526 (mentions_vars_p_comon): ... this one.
2527 (maybe_remember_with_vars_decl_minimal): Turn to ...
2528 (mentions_vars_p_decl_minmal): ... this one.
2529 (maybe_remember_with_vars_decl_common): Turn to ...
2530 (mentions_vars_p_decl_common): ... this one.
2531 (maybe_remember_with_vars_decl_with_vis): Turn to ...
2532 (mentions_vars_p_decl_with_vis): ... this one.
2533 (maybe_remember_with_vars_decl_non_common): Turn to ...
2534 (mentions_vars_p_decl_non_common): ... this one.
2535 (maybe_remember_with_vars_function): Turn to ...
2536 (mentions_vars_p_function): ... this one.
2537 (maybe_remember_with_vars_field_decl): Turn to ...
2538 (mentions_vars_p_field_decl): ... this one.
2539 (maybe_remember_with_vars_type): Turn to ...
2540 (mentions_vars_p_type): ... this one.
2541 (maybe_remember_with_vars_binfo): Turn to ...
2542 (mentions_vars_p_binfo): ... this one.
2543 (maybe_remember_with_vars_constructor): Turn to ...
2544 (mentions_vars_p_constructor): ... this one.
2545 (maybe_remember_with_vars_expr): Turn to ...
2546 (mentions_vars_p_expr): ... this one.
2547 (maybe_remember_with_vars): Turn to ...
2548 (mentions_vars_p): ... this one.
2549 (lto_read_decls): Update.
2550 (LTO_SET_PREVAIL): Do not call function for internal decls.
2551 (lto_fixup_prevailing_decls): Update to match mentions_vars_p;
2552 check that something was updated.
2553 (lto_fixup_state): Do not care about internal decls.
2554 (lto_fixup_decls): Update.
2555 (read_cgraph_and_symbols): Update.
2557 2013-08-29 Jan Hubicka <jh@suse.cz>
2559 * lto.c (read_cgraph_and_symbols): Free decl states.
2561 2013-08-29 Jan Hubicka <jh@suse.cz>
2563 * lto.c (compare_tree_sccs_1): Compare DECL_FINAL_P,
2564 DECL_CXX_CONSTRUCTOR_P, DECL_CXX_DESTRUCTOR_P and
2567 2013-08-28 Jan Hubicka <jh@suse.cz>
2569 * lto.c (compare_tree_sccs_1): Drop DECL_ERROR_ISSUED,
2570 DECL_DEFER_OUTPUT and DECL_IN_TEXT_SECTION.
2571 (unify_scc): Do checking assert.
2573 2013-08-06 Jan Hubicka <jh@suse.cz>
2574 Martin Liska <marxin.liska@gmail.com>
2576 * lto-partition.c (lto_balanced_map): Always base order on
2579 2013-08-06 Jan Hubicka <jh@suse.cz>
2581 * lto.c (lto_materialize_function): Do not read body anymore.
2583 2013-08-02 Jan Hubicka <jh@suse.cz>
2585 * lto.c (lto_materialize_function): Do not push struct function.
2586 * lto-partition.c (get_symbol_class): Handle abstracts correctly.
2587 (may_need_named_section_p): Even abstract origins may need
2590 2013-07-30 David Malcolm <dmalcolm@redhat.com>
2592 * Make-lang.in (lto/lto.o:): Depend on CONTEXT_H and
2595 * lto.c (do_whole_program_analysis): Update for move of
2596 all_regular_ipa_passes from a global to a field of class
2599 2013-07-21 Ondřej BÃÂlka <neleai@seznam.cz>
2601 * lto-partition.c: Fix typos.
2603 2013-06-20 Jan Hubicka <jh@suse.cz>
2605 * lto-partition.c (lto_balanced_map): Fix -fno-toplevel-reorder
2606 partitioning of variables.
2608 2013-06-20 Jan Hubicka <jh@suse.cz>
2610 * lto.c (read_cgraph_and_symbols): Set cgraph state.
2612 2013-06-19 Jan Hubicka <jh@suse.cz>
2614 * lto-partition.c (add_references_to_partition): Use
2617 2013-06-18 Richard Biener <rguenther@suse.de>
2619 * lto.c (lto_register_var_decl_in_symtab): Pass in cache index
2621 (lto_register_function_decl_in_symtab): Likewise.
2622 (cmp_tree): New function.
2623 (unify_scc): Instead of using the streamer cache map from entry
2624 to cache index match up the two maps we have by sorting them.
2625 Adjust calls to lto_register_var_decl_in_symtab and
2626 lto_register_function_decl_in_symtab.
2628 2013-06-17 Richard Biener <rguenther@suse.de>
2630 * Make-lang.in (lto.o): Add $(DATA_STREAMER_H) dependency.
2631 * lto.c: Include data-streamer.h.
2632 (lto_read_in_decl_state): Use streamer_tree_cache_get_tree.
2633 (gimple_type_leader_entry_s, gimple_type_leader,
2634 gimple_lookup_type_leader): Remove.
2635 (gtc_visit): Simplify.
2636 (gimple_types_compatible_p): Likewise.
2637 (gimple_register_type_1): Likewise. Merge into ...
2638 (gimple_register_type): ... this. Keep it as legacy for
2639 statistics purposes for now.
2640 (fixup_integer_cst): Remove.
2641 (LTO_FIXUP_TREE, lto_fixup_types, lto_ft_*): Simplify and
2643 (MAYBE_REMEMBER_WITH_VARS, maybe_remember_with_vars,
2644 maybe_remember_with_vars_*): ... these.
2645 (uniquify_nodes): Remove.
2646 (lto_fixup_prevailing_type): New function.
2647 (struct tree_scc, struct tree_scc_hasher): New type and hasher.
2648 (tree_scc_hash, tree_scc_hash_obstack): New globals.
2649 (num_merged_types, num_prevailing_types, num_not_merged_types,
2650 num_not_merged_types_in_same_scc, total_scc_size, num_sccs_read,
2651 total_scc_size_merged, num_sccs_merged, num_scc_compares,
2652 num_scc_compare_collisions): New global counters.
2653 (compare_tree_sccs_1): New function.
2654 (compare_tree_sccs): Likewise.
2655 (unify_scc): Likewise.
2656 (lto_read_decls): Stream in tree SCCs and unify them on the
2657 way in. Finalize prevailing SCC tree members.
2658 (read_cgraph_and_symbols): Do not initialize or free gimple_type_leader.
2659 Allocate and free tree_scc_hash_obstack and tree_scc_hash, do not bother
2660 to ggc-collect during merging.
2661 (print_lto_report_1): Adjust for new merging code.
2663 2013-06-12 Jan Hubicka <jh@suse.cz>
2665 * lto.c (read_cgraph_and_symbols): Set cgraph into streaming state.
2667 2013-06-12 Jan Hubicka <jh@suse.cz>
2669 * lto.c (register_resolution): Take lto_file_data argument.
2670 (lto_register_var_decl_in_symtab,
2671 lto_register_function_decl_in_symtab): Update.
2672 (read_cgraph_and_symbols): Update resolution_map handling.
2674 2013-06-11 Jan Hubicka <jh@suse.cz>
2676 * lto-partition.c (get_symbol_class): Simplify weakref handling.
2677 (add_symbol_to_partition_1): Likewise.
2678 (contained_in_symbol): Likewise.
2679 (lto_balanced_map): Likewise.
2680 (rename_statics): Drop weakref.
2682 2013-06-05 Richard Biener <rguenther@suse.de>
2684 * lto.c (num_merged_types): New global variable.
2685 (uniquify_nodes): Increase num_merged_types when merging a type.
2686 (print_lto_report_1): Output the number of merged types.
2688 2013-06-01 Jan Hubicka <jh@suse.cz>
2690 * lto.c (read_cgraph_and_symbols): Simplify dumping; Replace
2691 lto_symtab_merge_cgraph_nodes by lto_symtab_merge_symbols.
2692 (do_whole_program_analysis): Update dumping.
2694 2013-05-29 Jan Hubicka <jh@suse.cz>
2696 * lto.c (has_analyzed_clone_p, lto_materialize_function): Update for new symtab
2698 * lto-partition.c (get_symbol_class, lto_balanced_map): Likewise.
2700 2013-05-15 Jan Hubicka <jh@suse.cz>
2702 * lto-partition.c (privatize_symbol_name): Return true when
2703 privatizing happened.
2704 (rename_statics): Do not go into infinite loop when privatizing
2707 2013-05-16 Jason Merrill <jason@redhat.com>
2709 * Make-lang.in ($(LTO_EXE)): Use link mutex.
2711 2013-05-15 Martin Jambor <mjambor@suse.cz>
2713 * lto-partition.c (lto_balanced_map): Print symbol order instead
2716 2013-05-15 Jan Hubicka <jh@suse.cz>
2720 * lto-partition.c (get_symbol_class): Fix weakrefs.
2721 (lto_balanced_map): Fix weakrefs.
2722 (privatize_symbol_name): Remove unnecesary label.
2723 (rename_statics): Handle weakrefs as statics.
2725 2013-05-09 Jan Hubicka <jh@suse.cz>
2726 Richard Biener <rguenther@suse.de>
2728 * lto.c (lto_register_var_decl_in_symtab): Don't do renaming.
2729 (lto_register_var_decl_in_symtab): Likewise.
2730 (lto_main): Promote statics.
2731 * lto-partition.c (privatize_symbol_name): New function.
2732 (promote_symbol): Use it.
2733 (may_need_named_section_p): New predicate.
2734 (rename_statics): New functions.
2735 (lto_promote_cross_file_statics): Simplify; do renaming.
2736 (lto_promote_statics_nonwpa): New function.
2737 * lto-partition.h (lto_promote_statics_nonwpa): New function.
2739 2013-02-08 Richard Biener <rguenther@suse.de>
2742 * lto-lang.c (lto_init): Do not enter a dummy file.
2744 2013-02-07 Uros Bizjak <ubizjak@gmail.com>
2747 * lto.c (lto_resolution_ready): Use %wx instead of
2748 HOST_WIDE_INT_PRINT_HEX_PURE in the argument to internal_error.
2750 2013-02-04 Richard Guenther <rguenther@suse.de>
2753 * lto.c (read_cgraph_and_symbols): Do not call lto_symtab_merge_decls
2754 or lto_fixup_decls at LTRANS time.
2756 2013-01-09 Jan Hubicka <jh@suse.cz>
2759 * lto.c (do_whole_program_analysis): Remove unreachable nodes after IPA.
2761 2012-12-10 H.J. Lu <hongjiu.lu@intel.com>
2764 * lto.c (lto_register_var_decl_in_symtab): Don't record static
2766 (lto_main): Record the global variables if WPA isn't enabled.
2768 2012-11-20 Diego Novillo <dnovillo@google.com>
2769 Jakub Jelinek <jakub@redhat.com>
2771 * lto.c: Replace all vec<T, A>() initializers with vNULL.
2773 2012-11-16 Diego Novillo <dnovillo@google.com>
2775 Adjust for new vec API (http://gcc.gnu.org/wiki/cxx-conversion/cxx-vec)
2777 * lto-lang.c: Use new vec API in vec.h.
2778 * lto-partition.c: Likewise.
2779 * lto-partition.h: Likewise.
2782 2012-10-31 Lawrence Crowl <crowl@google.com>
2784 * lto.c (lto_wpa_write_files): Change symtab checking to a checked
2785 down-cast via dyn_cast.
2786 * lto-partition.c (add_symbol_to_partition_1): Likewise.
2787 (undo_partition): Likewise.
2788 (lto_balanced_map): Likewise.
2789 (get_symbol_class): Likewise and via is_a.
2790 (lto_balanced_map): Change symtab checking to is_a.
2792 2012-10-12 Richard Biener <rguenther@suse.de>
2795 * lto.c (gimple_types_compatible_p_1): Also compare
2797 (iterative_hash_gimple_type): Also hash TYPE_MAIN_VARIANT.
2799 2012-10-09 Tobias Burnus <burnus@net-b.de>
2801 * lto-lang.c (lto_register_builtin_type): Avoid useless
2803 * lto-object.c (lto_obj_file_open, lto_obj_file_open): Free memory.
2805 2012-10-08 Tobias Burnus <burnus@net-b.de>
2807 * lto.c (lto_wpa_write_files, read_cgraph_and_symbols):
2808 Free lto_file struct after closing the file.
2810 2012-10-08 Jan Hubicka <jh@suse.cz>
2812 * lto.c (remember_with_vars): Also fixup INTEGER_CST.
2813 (fixup_integer_cst): New functoin.
2814 (lto_ft_type): Fixup BASETYPE of methods and offsets.
2816 2012-10-07 Jan Hubicka <jh@suse.cz>
2818 * lto.c (read_cgraph_and_symbols): Release type merging hash early;
2819 release input encoders.
2820 * lto-partition.c (new_partition): Update for new lto_symtab_encoder_new.
2822 2012-10-06 Jan Hubicka <jh@suse.cz>
2825 * lto.c (resolution_map): New static var.
2826 (register_resolution): New function.
2827 (lto_register_var_decl_in_symtab): Use it.
2828 (read_cgraph_and_symbols): Copy resolutions into the symtab.
2830 2012-09-20 Martin Jambor <mjambor@suse.cz>
2832 * lto.c (lto_materialize_function): Call push_struct_function and
2835 2012-09-19 Dehao Chen <dehao@google.com>
2837 * lto.c (lto_fixup_prevailing_decls): Remove tree.exp.block field.
2839 2012-09-19 Jan Hubicka <jh@suse.cz>
2841 * lto.c (lto_materialize_function): Update confused comment.
2842 (read_cgraph_and_symbols): Do not free symtab.
2844 2012-09-12 Jan Hubicka <jh@suse.cz>
2846 * lto.c (do_whole_program_analysis): Care timevars, statistics and
2847 AUX pointer cleaning. Add max partitioning.
2848 * lto-partition.c (enum symbol_class): New.
2849 (get_symbol_class): New function.
2850 (symbol_partitioned_p): New function.
2851 (add_references_to_partition): Remove.
2852 (add_aliases_to_partition): Remove.
2853 (add_cgraph_node_to_partition_1): Remove.
2854 (add_cgraph_node_to_partition): Remove.
2855 (add_symbol_to_partition): New function.
2856 (add_symbol_to_partition_1): New function.
2857 (contained_in_symbol): New function.
2858 (partition_cgraph_node_p): Remove.
2859 (partition_varpool_node_p): Remove.
2860 (partition_symbol_p): Remove.
2861 (lto_1_to_1_map): Cleanup.
2863 (lto_balanced_map): Update.
2864 (lto_promote_cross_file_statics): Update.
2865 * lto-partition.h (lto_max_map): Declare.
2866 * timevar.def (TV_WHOPR_PARTITIONING): New timevar.
2868 2012-09-11 Jan Hubicka <jh@suse.cz>
2871 * lto.c (uniquify_nodes): Remove quadratic loop checking if the
2872 type is variant leader.
2874 2012-09-11 Richard Guenther <rguenther@suse.de>
2876 * lto.c (enum gtc_mode): Remove.
2877 (struct type_pair_d): Adjust.
2878 (lookup_type_pair): Likewise.
2879 (gimple_type_leader): Do not mark as deletable.
2880 (gimple_lookup_type_leader): Adjust.
2881 (gtc_visit): Likewise.
2882 (gimple_types_compatible_p_1): Likewise.
2883 (gimple_types_compatible_p): Likewise.
2884 (gimple_type_hash): Likewise.
2885 (gimple_register_type): Likewise.
2886 (read_cgraph_and_symbols): Manage lifetime of tables
2889 2012-09-11 Richard Guenther <rguenther@suse.de>
2891 * lto.c (gimple_types, type_hash_cache, enum gtc_mode,
2892 struct type_pair_d, lookup_type_pair, struct sccs,
2893 next_dfs_num, gtc_next_dfs_num, struct gimple_type_leader_entry_s,
2894 gimple_type_leader, gimple_lookup_type_leader, compare_type_names_p,
2895 gtc_visit, gimple_types_compatible_p_1, gimple_types_compatible_p,
2896 visit, iterative_hash_name, struct type_hash_pair,
2897 type_hash_pair_compare, iterative_hash_gimple_type, gimple_type_hash,
2898 gimple_type_eq, gimple_register_type_1, gimple_register_type):
2899 Move here from gimple.c
2900 (read_cgraph_and_symbols): Free hash tables here.
2901 (print_lto_report_1): New function wrapping print_lto_report.
2902 (do_whole_program_analysis): Call it.
2903 (lto_main): Likewise.
2905 2012-09-10 Jan Hubicka <jh@suse.cz>
2907 * lto-partition.c (partition_symbol_p): Forward declare.
2908 (add_references_to_partition): Reimplement using partition_symbol_p.
2909 (add_aliases_to_partition): Break out from add_references_to_partition;
2910 reimplement using partition_symbol_p.
2911 (add_cgraph_node_to_partition_1): Handle callees using partition_symbol_p;
2913 (add_varpool_node_to_partition): Use add_aliases_to_partition.
2914 (partition_varpool_node_p): Do not special case aliases.
2916 2012-08-12 Jan Hubicka <jh@suse.cz>
2918 * lto.c (lto_wpa_write_files): Do not delete partition encoder;
2919 it is deleted after streaming.
2920 * lto-partition.c (partition_symbol_p): New function.
2921 (promote_var, promote_fn): Remove.
2922 (promote_symbol): New function.
2923 (lto_promote_cross_file_statics): First compute boundaries; rewrite
2924 to lookup the actual boundaries instead of computing them ad-hoc.
2926 2012-08-12 Jan Hubicka <jh@suse.cz>
2928 Replace cgraph_node_set and varpool_node_set by symtab_node_encoder
2930 * lto-partition.h (ltrans_partition_def): Replace cgraph_set and varpool_set
2932 * lto-partition.c (new_partition): Update.
2933 * lto.c (cmp_partitions_order): Update.
2934 (lto_wpa_write_files): Update.
2935 (free_ltrans_partitions): Update.
2936 (add_references_to_partition): Update.
2937 (add_cgraph_node_to_partition_1): Update.
2938 (add_cgraph_node_to_partition): Update.
2939 (add_varpool_node_to_partition): Update.
2940 (undo_partition): Update.
2941 (lto_balanced_map): Update.
2942 (set_referenced_from_other_partition_p, set_reachable_from_other_partition_p,
2943 set_referenced_from_this_partition_p): Update.
2944 (lto_promote_cross_file_statics): Update.
2946 2012-08-12 Jan Hubicka <jh@suse.cz>
2948 * lto-partition.c (set_referenced_from_other_partition_p,
2949 set_reachable_from_other_partition_p, set_referenced_from_this_partition_p):
2951 (lto_promote_cross_file_statics): Use them.
2953 2012-07-24 Jan Hubicka <jh@suse.cz>
2955 * lto.c (read_cgraph_and_symbols): Use input_symtab.
2957 2012-07-24 Uros Bizjak <ubizjak@gmail.com>
2959 * lto-tree.h (lang_decl): Add variable_size GTY option.
2961 2012-07-16 Steven Bosscher <steven@gcc.gnu.org>
2963 * lto.c: Do not include timevar.h.
2964 * Make-lang.in: Fix dependencies.
2966 2012-06-18 Lawrence Crowl <crowl@google.com>
2968 * lto.c (do_whole_program_analysis): Rename use of TV_PHASE_CGRAPH to
2969 TV_PHASE_OPT_GEN. Use new timevar TV_PHASE_STREAM_OUT around the call
2970 to lto_wpa_write_files.
2971 (lto_main): Rename use of TV_PHASE_CGRAPH to TV_PHASE_OPT_GEN. Move
2972 start of TV_PHASE_OPT_GEN to include call to materialize_cgraph. Use
2973 TV_PHASE_SETUP for the call to lto_init. Use new timevar
2974 TV_PHASE_STREAM_IN around the call to read_cgraph_and_symbols.
2975 Turn TV_PHASE_PARSING off then back on again, because LTO is pretending
2976 to be a front end, but is not one.
2978 2012-05-18 Jan Hubicka <jh@suse.cz>
2980 * lto.c (lto_materialize_constructors_and_inits): Remove.
2981 (read_cgraph_and_symbols): Remove handling of alias pairs.
2983 2012-05-17 Jan Hubicka <jh@suse.cz>
2985 * lto-partition.c (add_references_to_partition): Handle external vars.
2986 (partition_varpool_node_p): Likewise.
2987 (lto_promote_cross_file_statics): Do not promote externals.
2989 2012-05-14 Bernd Schmidt <bernds@codesourcery.com>
2991 * lto-lang.c (handle_fnspec_attribute): New static function.
2992 (lto_attribute_table): Add "fn spec".
2993 (DEF_ATTR_STRING): Define and undefine along with the other macros.
2995 2012-05-04 Jan Hubicka <jh@suse.cz>
2997 * lto.c (do_whole_program_analysis): Set timevars correctly.
2998 (lto_main): Likewise.
3000 2012-05-04 Richard Guenther <rguenther@suse.de>
3002 * lang.opt (fwpa): Do not mark as Optimization.
3003 (fltrans): Likewise.
3005 2012-04-30 Jan Hubicka <jh@suse.cz>
3007 * lto.c (lto_main): Use compile ().
3008 * lto-partition.c (partition_cgraph_node_p): Use
3009 symtab_used_from_object_file_p.
3010 (partition_varpool_node_p): Likewise.
3012 2012-04-20 Jan Hubicka <jh@suse.cz>
3014 * lto-partition.c (partition_cgraph_node_p): Use force_output.
3016 2012-04-18 Jan Hubicka <jh@suse.cz>
3018 * lto-partition.c (add_references_to_partition, lto_balanced_map):
3019 Update for new ipa-ref API.
3021 2012-04-16 Jan Hubicka <jh@suse.cz>
3023 * lto.c (read_cgraph_and_symbols): Use FOR_EACH
3024 walkers to walk cgraph and varpool.
3025 (materialize_cgraph): Likewise.
3026 * lto-partition.c (lto_1_to_1_map): Likewise.
3027 (lto_balanced_map): Likewise.
3028 (lto_promote_cross_file_statics): Likewise.
3030 2012-04-14 Jan Hubicka <jh@suse.cz>
3032 * lto.c: Update field referenced for new cgraph/varpool layout.
3033 * lto-partition.c: Likewise.
3035 2012-04-11 Jan Hubicka <jh@suse.cz>
3037 * lto.c: Update copyright; remove params.h, ipa-inline.h
3038 and ipa-utils.h inlines; inline lto-partition.h
3039 (ltrans_partition_def, ltrans_partition, add_cgraph_node_to_partition,
3040 add_varpool_node_to_partition, new_partition, free_ltrans_partitions,
3041 add_references_to_partition, add_cgraph_node_to_partition_1,
3042 add_cgraph_node_to_partition, add_varpool_node_to_partition,
3043 undo_partition, partition_cgraph_node_p, partition_varpool_node_p,
3044 lto_1_to_1_map, node_cmp, varpool_node_cmp, lto_balanced_map,
3045 promote_var, promote_fn, lto_promote_cross_file_statics): move to...
3046 * lto-partition.c: ... here; new file.
3047 * lto-partition.h: New file.
3048 * Make-lang.in (lto.o): Update dependencies.
3049 (lto-partition.o): New.
3051 2012-04-05 Richard Guenther <rguenther@suse.de>
3053 * lto-lang.c (LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION): Remove
3056 2012-03-12 Richard Guenther <rguenther@suse.de>
3058 * lto-lang.c (builtin_type_for_size): Use lto_type_for_size.
3060 2012-03-06 Richard Guenther <rguenther@suse.de>
3063 * lto.c (uniquify_nodes): Merge TYPE_FIELDS of variant types.
3065 2012-02-28 Richard Guenther <rguenther@suse.de>
3068 * lto.c (lto_register_function_decl_in_symtab): Do not register
3069 a reverse renamed decl mapping.
3071 2012-01-06 Jakub Jelinek <jakub@redhat.com>
3074 * lto-lang.c (handle_returns_twice_attribute): New function.
3075 (lto_attribute_table): Add returns_twice attribute.
3077 2011-12-21 Richard Guenther <rguenther@suse.de>
3079 * lto.c (GIMPLE_REGISTER_TYPE): New define.
3080 (LTO_FIXUP_TREE): Use it.
3081 (uniquify_nodes): Mark new non-prevailing types and avoid
3082 calling gimple_register_type on others.
3083 (lto_read_decls): Add comment.
3085 2011-12-13 Eric Botcazou <ebotcazou@adacore.com>
3087 * lto.h (lto_parse_hex): Delete.
3088 * lto.c (lto_read_decls): Use 'int' for offsets.
3089 (lto_parse_hex): Make static and return proper 64-bit host type.
3090 (lto_resolution_read): Use proper 64-bit host type.
3092 2011-12-13 Richard Guenther <rguenther@suse.de>
3095 * lto.c (lto_ft_decl_non_common): When we merged DECL_ORIGINAL_TYPE
3096 with the type of the TYPE_DECL clear DECL_ORIGINAL_TYPE.
3098 2011-12-01 Uros Bizjak <ubizjak@gmail.com>
3100 * lto-lang.c (lto_attribute_table): Handle *tm regparm.
3101 (ignore_attribute): New.
3103 2011-11-21 Aldy Hernandez <aldyh@redhat.com>
3105 * lto-lang.c (lto_attribute_table): Handle transaction_pure.
3106 (handle_transaction_pure_attribute): New.
3108 2011-11-03 Richard Guenther <rguenther@suse.de>
3111 * lto-lang.c (lto_post_options): Do not read file options.
3112 * lto.c (lto_read_all_file_options): Remove.
3113 (lto_init): Call lto_set_in_hooks here.
3115 2011-10-09 Jan Hubicka <jh@suse.cz>
3117 * lto.c (node_cmp, varpool_node_cmp): New functions.
3118 (lto_balanced_map): Honnor -fno-toplevel-reorder of vars&functions.
3119 (cmp_partitions): Rename to ...
3120 (cmp_partitions_size): ... this one.
3121 (cmp_partitions_order): New function.
3122 (lto_wpa_write_files): Sort partitions by order when
3123 -fno-toplevel-reorder is used.
3125 2011-10-09 Andi Kleen <ak@linux.intel.com>
3127 * lto.c (lto_section_read): Call fatal_error on IO or mmap errors.
3129 2011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
3131 * lto-lang.c (def_builtin_1): Delete old interface with two
3132 parallel arrays to hold standard builtin declarations, and replace
3133 it with a function based interface that can support creating
3134 builtins on the fly in the future. Change all uses, and poison
3135 the old names. Make sure 0 is not a legitimate builtin index.
3137 2011-10-02 Andi Kleen <ak@linux.intel.com>
3139 * lto-object.c (lto_obj_add_section_data): Add list.
3140 (lto_obj_add_section): Fill in list.
3141 (ltoobj_build_section_table): Pass through list.
3142 * lto.c (file_data_list): Declare.
3143 (create_subid_section_table): Pass arguments directly.
3144 Fill in list of file_datas.
3146 (lto_create_files_from_ids): Pass in direct arguments.
3147 Don't maintain list.
3148 (lto_file_read): Use explicit section and file data lists.
3149 (lto_read_all_file_options): Pass in section_list.
3150 * lto.h (lto_obj_build_section_table): Add list.
3151 (lto_section_slot): Add next.
3152 (lto_section_list): Declare.
3154 2011-10-02 Jan Hubicka <jh@suse.cz>
3157 * common.c (lto_resolution_str): Add new resolution.
3158 * common.h (lto_resolution_str): Likewise.
3160 2011-09-30 H.J. Lu <hongjiu.lu@intel.com>
3161 Andi Kleen <ak@linux.intel.com>
3164 * lto.c (lto_splay_tree_delete_id): New.
3165 (lto_splay_tree_compare_ids): Likewise.
3166 (lto_splay_tree_lookup): Likewise.
3167 (lto_splay_tree_id_equal_p): Likewise.
3168 (lto_splay_tree_insert): Likewise.
3169 (lto_splay_tree_new): Likewise.
3170 (lto_resolution_read): Change id to unsigned HOST_WIDE_INT.
3171 Use lto_splay_tree_id_equal_p and lto_splay_tree_lookup.
3172 (create_subid_section_table): Use lto_splay_tree_lookup and
3173 lto_splay_tree_insert.
3174 (lto_file_read): Use lto_splay_tree_new.
3176 2011-09-26 Andi Kleen <ak@linux.intel.com>
3178 * lto.c (lto_resolution_read): Remove id dumping.
3179 (lto_section_with_id): Turn id HOST_WIDE_ID.
3180 (create_subid_section_table): Dito.
3182 2011-08-28 Dodji Seketeli <dodji@redhat.com>
3184 * lto-lang.c (lto_init): Likewise. Also, avoid calling
3187 2011-08-11 Martin Jambor <mjambor@suse.cz>
3189 * lto.c (uniquify_nodes): Use main variant's BINFO too.
3191 2011-08-08 Diego Novillo <dnovillo@google.com>
3193 * Make-lang.in (lto/lto.o): Add TREE_STREAMER_H.
3194 * lto.c: Include tree-streamer.h.
3196 2011-07-06 Richard Guenther <rguenther@suse.de>
3198 * lto-lang.c (lto_init):
3199 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
3201 2011-06-11 Jan Hubicka <jh@suse.cz>
3204 * lto.c (lto_1_to_1_map): Don't create empty partitions.
3205 (lto_balanced_map): Likewise.
3207 2011-06-11 Jan Hubicka <jh@suse.cz>
3209 * lto.c (add_cgraph_node_to_partition_1): Break out from ...
3210 (add_cgraph_node_to_partition) ... here; walk aliases.
3211 (lto_1_to_1_map): Remove same body alias code.
3212 (promote_fn): Likewise.
3213 (lto_promote_cross_file_statics): Update comment.
3215 2011-06-07 Diego Novillo <dnovillo@google.com>
3217 * lto.c (uniquify_nodes): Move code to register decls to
3218 the loop that computes canonical types.
3220 2011-06-07 Richard Guenther <rguenther@suse.de>
3222 * lto-lang.c (lto_init): Do not set
3223 size_type_node or call set_sizetype.
3225 2011-06-04 Diego Novillo <dnovillo@google.com>
3227 * lto.c (lto_init): New.
3228 (lto_main): Call it.
3230 2011-06-03 Diego Novillo <dnovillo@google.com>
3232 * lto.c (get_resolution): Move from lto-streamer-in.c.
3233 (lto_register_var_decl_in_symtab): Likewise.
3234 (lto_register_function_decl_in_symtab): Likewise.
3235 (uniquify_nodes): Call lto_register_var_decl and
3236 lto_register_function_decl_in_symtab after reading a new
3237 VAR_DECL or FUNCTION_DECL.
3239 2011-06-01 Richard Guenther <rguenther@suse.de>
3241 * lto-lang.c (lto_register_canonical_types): New function.
3242 (lto_init): Register common nodes with the canonical type machinery.
3243 Do not play tricks with char_type_node.
3245 2011-05-26 Richard Guenther <rguenther@suse.de>
3247 * lto.c (uniquify_nodes): Fix bug in one of the previous changes.
3249 2011-05-25 Nathan Froyd <froydnj@codesourcery.com>
3251 * lto.c (lto_ft_typed): New function.
3252 (lto_ft_common): Call it.
3253 (lto_ft_constructor): Likewise.
3254 (lto_ft_expr): Likewise.
3255 (lto_fixup_prevailing_decls): Check for TS_COMMON before accessing
3258 2011-05-20 Richard Guenther <rguenther@suse.de>
3260 * lto.c (lto_ft_common): Remove pointer-to chain teardown.
3261 (lto_ft_type): Move main-variant and pointer-to chain building ...
3262 (uniquify_nodes): ... here. Compute TYPE_CANONICAL also here,
3263 in a separate final loop.
3265 2011-05-19 Richard Guenther <rguenther@suse.de>
3267 * lto.c (uniquify_nodes): First register all types before
3268 fixing up the tree SCC.
3270 2011-05-11 Jan Hubicka <jh@suse.cz>
3273 * lto.c (do_whole_program_analysis): Do not register cgraph hooks.
3275 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
3277 * lto.c (lto_ft_type): Use TYPE_MINVAL and TYPE_MAXVAL. Adjust
3278 location of binfo field.
3279 (lto_fixup_prevailing_decls): Likewise.
3281 2011-05-10 Nathan Froyd <froydnj@codesourcery.com>
3283 * lto-lang.c (def_fn_type): Don't call build_function_type, call
3284 build_function_type_array or build_varargs_function_type_array
3287 2011-05-07 Eric Botcazou <ebotcazou@adacore.com>
3289 * lto-lang.c (global_bindings_p): Return bool.
3291 2011-05-07 Jan Hubicka <jh@suse.cz>
3293 * lto.c (lto_materialize_function): Use
3294 cgraph_function_with_gimple_body_p.
3295 (add_cgraph_node_to_partition): Do not re-add items to partition;
3297 (add_varpool_node_to_partition): Do not re-add items to partition.
3299 2011-05-03 Jan Hubicka <jh@suse.cz>
3301 * lto.c (free_ltrans_partitions): Fix accidental commit.
3303 2011-05-03 Jan Hubicka <jh@suse.cz>
3305 * lto.c (ltrans_partition_def): Remove GTY annotations.
3306 (ltrans_partitions): Move to heap.
3307 (new_partition): Update.
3308 (free_ltrans_partitions): New function.
3309 (lto_wpa_write_files): Use it.
3311 2011-04-29 Martin Jambor <mjambor@suse.cz>
3313 * lto.c: Include ipa-utils.h.
3314 (lto_balanced_map): Update call to ipa_reverse_postorder.
3315 * Make-lang.in (lto/lto.o): Add IPA_UTILS_H to dependencies.
3317 2011-04-29 Michael Matz <matz@suse.de>
3319 * lto.c (toplevel): Include tree-flow.h.
3320 (lto_read_in_decl_state): Don't merge types here.
3321 (tree_with_vars): New static hash table.
3322 (remember_with_vars): New static functions.
3323 (LTO_FIXUP_TYPE): New macro.
3324 (lto_ft_common, lto_ft_decl_minimal, lto_ft_decl_common,
3325 lto_ft_decl_with_vis, lto_ft_decl_non_common, lto_ft_function,
3326 lto_ft_field_decl, lto_ft_type, lto_ft_binfo, lto_ft_constructor,
3327 lto_ft_expr, lto_fixup_types, uniquify_nodes): New static functions.
3328 (lto_read_decls): Uniquify while reading in trees.
3329 (lto_fixup_data_t, LTO_FIXUP_SUBTREE,
3330 LTO_REGISTER_TYPE_AND_FIXUP_SUBTREE, no_fixup_p, lto_fixup_common,
3331 lto_fixup_decl_minimal, lto_fixup_decl_common, lto_fixup_decl_with_vis,
3332 lto_fixup_decl_non_common, lto_fixup_function, lto_fixup_field_decl,
3333 lto_fixup_type, lto_fixup_binfo, lto_fixup_constructor,
3334 lto_fixup_tree): Remove.
3335 (lto_fixup_state): Remove data argument. Use
3336 lto_symtab_prevailing_decl.
3337 (LTO_SET_PREVAIL, LTO_NO_PREVAIL): New macros.
3338 (lto_fixup_prevailing_decls): New function.
3339 (lto_fixup_state_aux): Argument aux is unused.
3340 (lto_fixup_decls): Don't allocate pointer sets, don't use
3341 lto_fixup_tree, use lto_fixup_prevailing_decls.
3342 (read_cgraph_and_symbols): Allocate and remove tree_with_vars.
3343 * Make-lang.in (lto/lto.o): Depend on $(TREE_FLOW_H).
3345 2011-04-16 Eric Botcazou <ebotcazou@adacore.com>
3347 * lto.c (lto_balanced_map): Fix typos in head comment.
3348 (lto_promote_cross_file_statics): Fix long lines and remove redundant
3351 2011-04-16 Jan Hubicka <jh@suse.cz>
3353 * lto.c (lto_balanced_map): Update.
3355 2011-04-14 Jan Hubicka <jh@suse.cz>
3357 * lto.c: Include ipa-inline.h
3358 (add_cgraph_node_to_partition, undo_partition): Use inline_summary
3360 (ipa_node_duplication_hook): Fix declaration.
3361 * Make-lang.in (lto.o): Update dependencies.
3363 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
3365 * lto-tree.h (union lang_tree_node): Check for TS_COMMON before
3367 * lto.c (lto_fixup_common): Likewise.
3369 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
3371 * lto-lang.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
3372 (handle_type_generic_attribute): Likewise.
3374 2011-04-03 Michael Matz <matz@suse.de>
3376 * lto.c (lto_materialize_function): Don't read and then discard
3377 sections in WPA mode.
3378 (lto_read_in_decl_state): Adjust call to lto_streamer_cache_get.
3380 * lto-lang.c (registered_builtin_fndecls): Remove.
3381 (lto_getdecls): Return NULL_TREE.
3382 (lto_builtin_function): Don't remember in registered_builtin_fndecls.
3384 2011-03-31 Richard Guenther <rguenther@suse.de>
3387 * lto.c (lto_wpa_write_files): Disable assert for non-empty
3388 partitions when checking is not enabled.
3390 2011-03-25 Kai Tietz <ktietz@redhat.com>
3392 * lto.c (lto_resolution_read): Use filename_cmp instead
3394 (lto_read_section_data): Likewise.
3396 2011-03-25 Jeff Law <law@redhat.com>
3398 * lto-lang.c (def_fn_type): Add missing va_end.
3400 2011-03-21 Kai Tietz <ktietz@redhat.com>
3403 * lto-lang.c (lto_attribute_table): Adjust table.
3405 2011-02-18 Jakub Jelinek <jakub@redhat.com>
3408 * Make-lang.in (lto/lto-lang.o): Depend on $(LTO_STREAMER_H) instead
3411 2011-02-18 Richard Guenther <rguenther@suse.de>
3414 * lto-tree.h (lto_global_var_decls): Do not declare here.
3415 * lto-lang.c: Include lto-streamer.h.
3416 * Make-lang.in (lto-lang.o): Adjust dependencies.
3418 2011-02-10 Kai Tietz <kai.tietz@onevision.com>
3421 * lto.c (lto_read_section_data): Free
3422 fd_name in failure case.
3423 For mingw targets don't hash file-descriptor.
3424 (read_cgraph_and_symbols): Close current_lto_file
3427 2011-01-11 Jan Hubicka <jh@suse.cz>
3431 * lto.c (partition_cgraph_node_p, partition_varpool_node_p): Weakrefs
3432 are not partitioned.
3434 2010-12-22 Nathan Froyd <froydnj@codesourcery.com>
3436 * lto-lang.c (handle_nonnull_attribute, handle_sentinel_attribute):
3439 2010-12-06 Richard Guenther <rguenther@suse.de>
3442 * lto-lang.c (lto_init): Give names to basic types.
3444 2010-11-30 Joseph Myers <joseph@codesourcery.com>
3446 * lto-object.c: Don't include toplev.h.
3447 * Make-lang.in (lto/lto-object.o): Don't depend on toplev.h.
3449 2010-11-30 Joseph Myers <joseph@codesourcery.com>
3451 * Make-lang.in (lto/lto-object.o): Depend on toplev.h instead of
3454 2010-11-29 Joseph Myers <joseph@codesourcery.com>
3456 * lto-endian.h: Delete.
3457 * lto-object.c: Don't include "libiberty.h".
3458 (O_BINARY): Don't define.
3459 * lto.c: Don't include "libiberty.h" or <sys/mman.h>.
3460 (O_BINARY): Don't define.
3462 2010-11-23 Richard Guenther <rguenther@suse.de>
3464 * lto.c (read_cgraph_and_symbols): Remove newline from diagnostic.
3466 2010-11-23 Richard Guenther <rguenther@suse.de>
3469 * lto.c (read_cgraph_and_symbols): Bail out after errors.
3471 2010-11-17 Joseph Myers <joseph@codesourcery.com>
3473 * lto.c (lto_main): Take no arguments.
3474 * lto.h (lto_main): Update prototype.
3476 2010-11-16 Ian Lance Taylor <iant@google.com>
3478 * lto-object.c (lto_obj_file_open): Call
3479 simple_object_attributes_merge rather than
3480 simple_object_attributes_compare.
3482 2010-11-12 Joseph Myers <joseph@codesourcery.com>
3484 * Make-lang.in (lto/lto.o): Use $(OPTS_H).
3485 * lto-lang.c (lto_handle_option): Take location_t parameter.
3487 2010-11-10 Joseph Myers <joseph@codesourcery.com>
3489 * lto.c (lto_resolution_read): Start diagnostics with lowercase
3490 letters and remove trailing '.'.
3491 (lto_file_finalize): Start diagnostic with a lowercase letter.
3493 2010-11-02 Ian Lance Taylor <iant@google.com>
3495 * lto-object.c: New file.
3496 * lto-elf.c: Remove file.
3497 * lto-macho.c: Remove file.
3498 * lto-macho.h: Remove file.
3499 * lto-coff.c: Remove file.
3500 * lto-coff.h: Remove file.
3501 * Make-lang.in (LTO_OBJS): Change lto/$(LTO_BINARY_READER).o to
3503 ($(LTO_EXE)): Remove $(LTO_USE_LIBELF)
3504 (lto/lto-objfile.o): New target.
3505 (lto/lto-elf.o, lto/lto-coff.o, lto/lto-macho.o): Remove targets.
3506 (lto/lto.o): Remove $(LIBIBERTY_H).
3508 2010-10-22 Jan Hubicka <jh@suse.cz>
3510 * lto.c (add_cgraph_node_to_partition,
3511 add_varpool_node_to_partition): Add debug info.
3512 (lto_1_to_1_map, lto_balanced_map): Do not re-add already
3514 (do_whole_program_analysis): Set function flags before dumping.
3516 2010-10-22 Richard Guenther <rguenther@suse.de>
3518 * lto.c (lto_fixup_type): Fixup TYPE_CANONICAL again, via
3519 the new gimple_register_canonical_type.
3521 2010-10-20 H.J. Lu <hongjiu.lu@intel.com>
3524 * config-lang.in (boot_language): Set to $enable_lto.
3526 2010-10-18 Jakub Jelinek <jakub@redhat.com>
3529 * Make-lang.in (check-lto): New dummy target.
3531 2010-10-14 Eric Botcazou <ebotcazou@adacore.com>
3533 * lto-elf.c (SHN_XINDEX): Define if not already defined.
3535 2010-10-08 Joseph Myers <joseph@codesourcery.com>
3537 * lto-lang.c (lto_init_options): Change to
3538 lto_init_options_struct. Update parameters.
3539 (LANG_HOOKS_INIT_OPTIONS): Don't define.
3540 (LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
3542 2010-10-06 Jan Hubicka <jh@suse.cz>
3544 * lto.c (lto_balanced_map): Fix accounting of program size.
3546 2010-10-06 Jan Hubicka <jh@suse.cz>
3548 * lto.c (lto_balanced_map): Do not produce empty partitions.
3550 2010-10-06 Andi Kleen <ak@linux.intel.com>
3552 * lto.c (lto_process_name): Add.
3553 (lto_main): Call lto_process_name.
3555 2010-10-06 Jan Hubicka <jh@suse.cz>
3557 * lto.c (partition_cgraph_node_p, partition_varpool_node_p): Handle
3558 COMDATs required by the linker.
3560 2010-10-05 Ian Lance Taylor <iant@google.com>
3562 * lto.c (lto_section_with_id): Make s a const pointer.
3564 2010-10-05 Jan Hubicka <jh@suse.cz>
3566 * lto.c: Include params.h.
3567 (add_cgraph_node_to_partition, add_varpool_node_to_partition): Do
3568 refcounting in aux field.
3569 (undo_partition, partition_cgraph_node_p, partition_varpool_node_p):
3571 (lto_1_to_1_map): Simplify.
3572 (lto_balanced_map): New function.
3573 (do_whole_program_analysis): Chose proper partitioning alg.
3574 * Make-lang.in (lto.o): Add dependency on params.h
3576 2010-10-04 Andi Kleen <ak@linux.intel.com>
3578 * Make-lang.in (lto1): Add + to build rule.
3580 2010-10-03 Andi Kleen <ak@linux.intel.com>
3582 * lto.c (lto_file_finalize): Replace gcc_assert for missing section
3585 2010-09-28 Jan Hubicka <jh@suse.cz>
3587 * lto-lang.c (handle_leaf_attribute): New function.
3588 (lto_attribute_tables): Add leaf.
3590 2010-09-25 Jie Zhang <jie@codesourcery.com>
3592 * lto.c (lto_read_all_file_options): Start a new line after
3593 printing out file names.
3595 2010-09-24 Jan Hubicka <jh@suse.cz>
3597 * lto.c (lto_promote_cross_file_statics): Use const_value_known_p.
3599 2010-09-20 Jan Hubicka <jh@suse.cz>
3601 PR tree-optimize/45605
3602 * lto.c (lto_promote_cross_file_statics): Use const_value_known_p.
3604 2010-09-18 Gerald Pfeifer <gerald@pfeifer.com>
3606 * lto-elf.c (lto_obj_file_open): Also provide filename when
3609 2010-09-17 Jan Hubicka <jh@suse.cz>
3611 * lto.c (lto_promote_cross_file_statics): Use const_value_known.
3613 2010-09-17 Richard Guenther <rguenther@suse.de>
3615 * lang.opt (flag_wpa): Also enable for the driver.
3617 2010-09-16 Jan Hubicka <jh@suse.cz>
3619 * lto.c (lto_materialize_function): Do not tamper with STATIC and
3622 2010-09-15 Laurynas Biveinis <laurynas.biveinis@gmail.com>
3624 * lto-tree.h (struct lang_type): Add variable_size GTY option.
3626 2010-09-08 Jan Hubicka <jh@suse.cz>
3628 * lto.c (real_file_count, real_file_decl_data): New static vars.
3629 (read_cgraph_and_symbols): Use it.
3631 2010-09-08 Richard Guenther <rguenther@suse.de>
3633 * lto.c (read_cgraph_and_symbols): Collect again after each
3636 2010-09-07 Jan Hubicka <jh@suse.cz>
3638 * lto.c (promote_var, promote_fn): Set DECL_VISIBILITY_SPECIFIED.
3640 2010-09-03 Richard Guenther <rguenther@suse.de>
3642 * lto-elf.c (validate_file): Always error if validation fails.
3644 2010-08-20 Jan Hubicka <jh@suse.cz>
3646 * lto.c (lto_1_to_1_map): Be prepared for node to have no file data.
3647 (lto_wpa_write_files): Update comments.
3649 2010-08-20 H.J. Lu <hongjiu.lu@intel.com>
3652 * lto.c (lto_materialize_function): Replace has_analyzed_clone
3653 with has_analyzed_clone_p.
3655 2010-08-20 Jan Hubicka <jh@suse.cz>
3657 * lto.c (has_analyzed_clone_p): New function
3658 (lto_materialize_function): Use callgraph to determine if
3660 (materialize_cgraph): Remove DECL_IS_BUILTIN check.
3662 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
3664 * lto.c: Use FOR_EACH_VEC_ELT.
3666 2010-07-27 Andi Kleen <ak@linux.intel.com>
3668 * Make-lang.in (lto.o): Add dependency to splay-tree.h
3670 2010-07-27 Joseph Myers <joseph@codesourcery.com>
3672 * lto-lang.c (lto_handle_option): Update prototype and return
3673 value type. Remove duplicate assignment to result.
3675 2010-07-27 Joseph Myers <joseph@codesourcery.com>
3677 * lto-lang.c (lto_option_lang_mask, lto_complain_wrong_lang_p):
3679 (lto_init_options): Update prototype.
3680 (LANG_HOOKS_OPTION_LANG_MASK, LANG_HOOKS_COMPLAIN_WRONG_LANG_P):
3683 2010-07-10 Andi Kleen <ak@linux.intel.com>
3686 * lto.c: Include splay-tree.h
3687 (lto_resolution_read): Change to walk file_ids tree and parse
3688 extra file_id in resolution file.
3689 (lto_section_with_id): Add.
3690 (create_subid_section_table): Add.
3692 (lto_create_files_from_ids): Add.
3693 (lto_file_read): Change to handle sub file ids and create list
3694 of file_datas. Add output argument for count.
3695 (get_section_data): Pass file_data to lto_get_section_name.
3696 (lto_flatten_file): Add.
3697 (read_cgraph_and_symbols): Handle linked lists of file_datas.
3699 2010-07-10 Andi Kleen <ak@linux.intel.com>
3701 * lto-coff.c (hash_name, eq_name): Move.
3702 (lto_obj_build_section_table): Call lto_obj_create_section_hash_table.
3703 * lto-elf.c: (hash_name, eq_name): Move.
3704 (lto_obj_build_section_table): Call lto_obj_create_section_hash_table.
3705 * lto-macho.c: (hash_name, eq_name): Move.
3706 (lto_obj_build_section_table): Call lto_obj_create_section_hash_table.
3707 * lto.c: (hash_name, eq_name): Move from lto-*.c
3708 (lto_obj_create_section_hash_table): Add.
3709 (free_with_string): Add.
3711 2010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
3713 * lto-coff.c: Include diagnostic-core.h in every file that
3715 * lto-elf.c: Likewise.
3716 * lto-lang.c: Likewise.
3717 * lto-macho.c: Likewise.
3719 2010-07-07 Jakub Jelinek <jakub@redhat.com>
3721 * lto-elf.c (ELFOSABI_NONE, ELFOSABI_LINUX): Define if not defined.
3722 (validate_file): Allow merging of ELFOSABI_NONE with ELFOSABI_LINUX
3725 2010-07-05 Jan Hubicka <jh@suse.cz>
3727 * lto.c (add_cgraph_node_to_partition): Forward declare; walk also
3728 nodes from same comdat group as well as all comdat functions referenced
3730 (add_varpool_node_to_partition, add_references_to_partition): New
3732 (lto_1_1_map): Skip COMDAT fnctions/variables; use
3733 add_varpool_node_to_partition; clear aux flags when done.
3734 (lto_promote_cross_file_statics): Do not promote stuff that gets
3735 duplicated to each ltrans.
3737 2010-07-04 Jan Hubicka <jh@suse.cz>
3739 * lto.c (read_cgraph_and_symbols): Dump cgraph before merging.
3741 2010-06-13 Richard Guenther <rguenther@suse.de>
3743 * lto.c (lto_fixup_type): Do not register or fixup TYPE_CANONICAL.
3745 2010-06-09 Kai Tietz <kai.tietz@onevision.com>
3747 * lto.c (lto_resolution_read): Pre-initialize local variable r.
3748 * lto-coff.c (coff_write_object_file): Add braces to if.
3750 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
3752 * lto.c (lto_read_in_decl_state): Use typed GC allocation.
3753 (lto_file_read): Likewise.
3754 (new_partition): Likewise.
3755 (read_cgraph_and_symbols): Likewise.
3757 2010-06-07 Joseph Myers <joseph@codesourcery.com>
3759 * lto-lang.c (flag_no_builtin, flag_no_nonansi_builtin): Remove.
3760 (lto_handle_option): Don't set flag_signed_char here.
3762 2010-06-04 Richard Guenther <rguenther@suse.de>
3765 * lto.c (lto_1_to_1_map): Use the proper file_data for
3768 2010-05-30 Jan Hubicka <jh@suse.cz>
3770 * lto.c (promote_var, promote_fn, lto_wpa_write_files): Dump
3771 partitioning decisions.
3773 2010-05-29 Jan Hubicka <jh@suse.cz>
3775 * lto.c (bitmap vector): Remove.
3776 (lto_cgraph_node_sets, lto_varpool_node_sets): Remove.
3777 (ltrans_partition_def): New structure.
3778 (ltrans_partition): New type and VECtor.
3779 (new_partition): New function.
3780 (add_cgraph_node_to_partition): New function.
3781 (lto_1_to_1_map): Reorganize for partitions.
3782 (lto_add_inline_clones): Remove.
3783 (lto_add_all_inlinees): Remove.
3784 (lto_promote_cross_file_statics): Use partitions.
3785 (cmp_partitions): New function.
3786 (lto_wpa_write_files): Do not call lto_add_all_inlinees;
3787 use partitions; output files sorted by size.
3789 2010-05-29 Steven Bosscher <steven@gcc.gnu.org>
3791 * Make-lang.in: Replace vec.h dependency with VEC_H.
3793 2010-05-28 Joseph Myers <joseph@codesourcery.com>
3795 * lto-coff.c (coff_errmsg): Remove.
3796 (lto_coff_begin_section_with_type, lto_obj_append_data): Use %m in
3797 errors instead of coff_errmsg (-1).
3798 * lto-macho.c (mach_o_errmsg): Remove.
3799 (lto_obj_begin_section, lto_obj_append_data): Use %m in errors
3800 instead of mach_o_errmsg (-1).
3801 * lto.c (read_cgraph_and_symbols): Use %m in errors instead of
3804 2010-05-28 Richard Guenther <rguenther@suse.de>
3806 * lto.c (prefix_name_with_star): Removed.
3807 (strip_extension): Likewise.
3808 (get_filename_for_set): Likewise.
3809 (lto_write_ltrans_list): Fold into ...
3810 (lto_wpa_write_files): ... this. Name LTRANS units
3811 by suffixing the ltrans output list filename.
3812 (do_whole_program_analysis): Adjust.
3814 2010-05-27 Joseph Myers <joseph@codesourcery.com>
3816 * lto.c: Include diagnostic-core.h instead of diagnostic.h.
3817 (read_cgraph_and_symbols, lto_main): Use seen_error.
3818 * Make-lang.in (lto/lto.o): Update dependencies.
3820 2010-05-27 Eric Botcazou <ebotcazou@adacore.com>
3823 * lto.h (lto_eh_personality): New prototype.
3824 * lto.c: Include debug.h.
3825 (first_personality_decl): New static variable.
3826 (lto_materialize_function): Set it to DECL_FUNCTION_PERSONALITY of the
3827 first function for which it is non-null.
3828 (lto_eh_personality_decl): New static variable.
3829 (lto_eh_personality): New function.
3830 * lto-lang.c (LANG_HOOKS_EH_PERSONALITY): Redefine to above function.
3831 * Make-lang.in (lto/lto.o): Add dependency on debug.h.
3833 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
3835 * lto-lang.c: Do not include expr.h.
3837 2010-05-24 Richard Guenther <rguenther@suse.de>
3839 * lto-elf.c (lto_obj_build_section_table): Work around
3840 FreeBSD libelf issue.
3842 2010-05-22 Richard Guenther <rguenther@suse.de>
3844 * lto.c (read_cgraph_and_symbols): Do not collect.
3846 2010-05-20 Jan Hubicka <jh@suse.cz>
3848 * lto.c (promote_var, promote_fn): New functions.
3849 (lto_promote_cross_file_statics): Compute correctly boundary including
3850 static initializers of readonly vars.
3852 2010-05-18 Jan Hubicka <jh@suse.cz>
3854 * lto.c (lto_1_to_1_map): Partition non-inline clones.
3855 (lto_promote_cross_file_statics): Deal with non-inline clones.
3857 2010-05-18 Jan Hubicka <jh@suse.cz>
3859 * lto.c (lto_materialize_function): Announce function when
3860 reading body; allocate_struct_function only when reading body;
3861 do not finalize local statics; ggc_collect after reading;
3862 do not mark reachable node.
3863 (materialize_cgraph): Do not announce function.
3865 2010-05-11 Jan Hubicka <jh@suse.cz>
3867 * lto.c (materialize_cgraph): Revert my previous patch.
3869 2010-05-11 Kai Tietz <kai.tietz@onevision.com>
3871 * lto-coff.c (IMAGE_FILE_MACHINE_ADM64): Rename to
3872 IMAGE_FILE_MACHINE_AMD64.
3873 * lto-coff.c (IMAGE_FILE_MACHINE_ADM64): Likewise.
3875 2010-05-11 Jan Hubicka <jh@suse.cz>
3877 * lto.c (lto_fixup_decls): Remove global var decls freeing here.
3878 (materialize_cgraph): Add it here.
3880 2010-05-11 Jan Hubicka <jh@suse.cz>
3882 * lto.c (lto_fixup_decls): Free no longer needed lto_global_var_decls
3885 2010-05-11 Jan Hubicka <jh@suse.cz>
3887 * lto.c (lto_1_to_1_map): Remove some no longer needed checks.
3888 (lto_promote_cross_file_statics): Never promote DECL_EXTERNAL;
3889 use reachable_from_other_partition_p and
3890 referenced_from_other_partition_p test.
3892 2010-05-11 Kai Tietz <kai.tietz@onevision.com>
3894 * lto-coff.c (validate_file): Add x64-coff support.
3895 * lto-coff.h (IMAGE_FILE_MACHINE_ADM64): New.
3896 (COFF_KNOWN_MACHINES): Add IMAGE_FILE_MACHINE_ADM64.
3897 * lto-lang.c (lto_build_c_type_nodes): Add check for
3898 'long long unsigned int' for x64-windows.
3899 (lto_init): Likewise.
3901 2010-05-07 Steven Bosscher <steven@gcc.gnu.org>
3903 * lto.h (struct lto_file_struct): Document offset member.
3904 * lto-endian.h: New file.
3905 * lto-macho.h: New file.
3906 * lto-macho.c: New file.
3907 * Make-lang.in: Add rule for lto-macho.o.
3909 2010-05-07 Richard Guenther <rguenther@suse.de>
3913 * lang.opt (fresolution): Change to ...
3914 (fresolution=): ... this.
3915 * lto-lang.c (lto_handle_option): Adjust.
3917 2010-05-07 Richard Guenther <rguenther@suse.de>
3919 * lto.c (DUMPBASE_SUFFIX): Remove.
3920 (lto_execute_ltrans): Move functionality to lto-wrapper.c.
3922 (lto_write_ltrans_list): ... only output the list of ltrans files.
3923 (lto_maybe_unlink): Remove.
3924 (do_whole_program_analysis): Do not execute LTRANS phase
3927 2010-05-06 H.J. Lu <hongjiu.lu@intel.com>
3929 * lto-lang.c (lto_handle_option): Add argument kind.
3931 2010-05-05 Jan Hubicka <jh@suse.cz>
3933 * lto.c (lto_promote_cross_file_statics): Compute boundary based on
3936 2010-05-05 Jan Hubicka <jh@suse.cz>
3938 * lto.c (lto_1_to_1_map): Partition only needed nodes.
3940 2010-04-30 Jan Hubicka <jh@suse.cz>
3942 * lto.c (get_filename_for_set): Look for cgraph node and if none found,
3944 (lto_wpa_write_files): Write any non-empty partition.
3946 2010-04-30 Jan Hubicka <jh@suse.cz>
3948 * lto.c: Do not attempt to make constant pool references global.
3950 2010-04-28 Jan Hubicka <jh@suse.cz>
3952 * lto.c (lto_read_in_decl_state): Use GGC.
3953 (lto_wpa_write_files): Announce what we are writting.
3954 (all_file_decl_data): New.
3955 (read_cgraph_and_symbols): Use GGC; correct timevars.
3956 (do_whole_program_analysis): Collect.
3957 * Make-lang.in (lto.o): Fix dependency.
3958 * Makefile.in (GTFILES): Add lto-streamer.h.
3959 * varpool.c (varpool_analyze_pending_decls): Use TV_VARPOOL.
3960 (varpool_assemble_pending_decls): Use VAROUT.
3961 * lto-streamer.h (lto_tree_ref_table): Annotate.
3962 (lto_in_decl_state): Annotate.
3963 (lto_file_decl_data): Annotate.
3965 2010-04-28 Jan Hubicka <jh@suse.cz>
3967 * lto.c (lto_varpool_node_sets): New.
3968 (lto_1_to_1_map): Partition varpool too.
3969 (globalize_context_t, globalize_cross_file_statics,
3970 lto_scan_statics_in_ref_table, lto_scan_statics_in_cgraph_node,
3971 lto_scan_statics_in_remaining_global_vars): Remove.
3972 (lto_promote_cross_file_statics): Rewrite.
3973 (get_filename_for_set): Take vset argument.
3974 (lto_wpa_write_files): Pass around vsets.
3976 2010-04-27 Dave Korn <dave.korn.cygwin@gmail.com>
3979 * Make-lang.in (LTO_OBJS): Use LTO_BINARY_READER instead of
3980 hardcoding 'lto-elf.o'.
3981 ($(LTO_EXE)): Use LTO_USE_LIBELF instead of hardcoding '-lelf'.
3983 * lto-coff.h: New file.
3984 * lto-coff.c: Likewise.
3986 2010-04-26 Richard Guenther <rguenther@suse.de>
3988 * lto.c (lto_fixup_type): Deal with non-type TYPE_CONTEXT.
3990 2010-04-26 Dave Korn <dave.korn.cygwin@gmail.com>
3992 * lto.h (lto_elf_file_open): Rename prototype from this ...
3993 (lto_obj_file_open): ... to this.
3994 (lto_elf_file_close): Likewise ...
3995 (lto_obj_file_close): ... and likewise.
3996 (lto_elf_build_section_table): Likewise ...
3997 (lto_obj_build_section_table): ... and likewise.
3998 (lto_elf_begin_section): Likewise ...
3999 (lto_obj_begin_section): ... and likewise.
4000 (lto_elf_append_data): Likewise ...
4001 (lto_obj_append_data): ... and likewise.
4002 (lto_elf_end_section): Likewise ...
4003 (lto_obj_end_section): ... and likewise.
4004 * lto.c (lto_file_read): Update references to the above.
4005 (lto_wpa_write_files): Likewise.
4006 (lto_read_all_file_options): Likewise.
4007 (read_cgraph_and_symbols): Likewise.
4008 * lto-lang.c (LANG_HOOKS_BEGIN_SECTION): Likewise.
4009 (LANG_HOOKS_APPEND_DATA): Likewise.
4010 (LANG_HOOKS_END_SECTION): Likewise.
4011 * lto-elf.c (lto_elf_file_open): Rename from this ...
4012 (lto_obj_file_open): ... to this, updating any references.
4013 (lto_elf_file_close): Likewise ...
4014 (lto_obj_file_close): ... and likewise.
4015 (lto_elf_build_section_table): Likewise ...
4016 (lto_obj_build_section_table): ... and likewise.
4017 (lto_elf_begin_section): Likewise ...
4018 (lto_obj_begin_section): ... and likewise.
4019 (lto_elf_append_data): Likewise ...
4020 (lto_obj_append_data): ... and likewise.
4021 (lto_elf_end_section): Likewise ...
4022 (lto_obj_end_section): ... and likewise.
4024 2010-04-21 Jan Hubicka <jh@suse.cz>
4026 * lto.c (lto_fixup_tree): Do not call wpa fixup.
4027 (materialize_cgraph): Likewise.
4029 2010-04-21 Jan Hubicka <jh@suse.cz>
4031 * lto.c (lto_wpa_write_files): Update.
4032 (read_cgraph_and_symbols): Be more verbose.
4033 (materialize_cgraph): Likewise.
4034 (do_whole_program_analysis): Likewise.
4036 2010-04-21 Jan Hubicka <jh@suse.cz>
4038 * lto.c (globalize_cross_file_statics): When function has address taken,
4039 it needs to be public.
4041 2010-04-20 Jan Hubicka <jh@suse.cz>
4043 * lto.c (lto_add_inline_clones): Do not track inlined_decls.
4044 (lto_add_all_inlinees): Likewise.
4045 (lto_wpa_write_files): Likewise.
4047 2010-04-18 Eric Botcazou <ebotcazou@adacore.com>
4049 * lto-lang.c (lto_init): Remove second argument in call to
4050 build_common_tree_nodes.
4052 2010-04-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4054 * lto-elf.c [!HAVE_ELF_GETSHDRSTRNDX] (elf_getshdrstrndx): New
4057 2010-03-09 Eric Botcazou <ebotcazou@adacore.com>
4060 * lto-elf.c: Define EM_* constants if not already defined.
4062 2010-03-03 Eric Botcazou <ebotcazou@adacore.com>
4064 * lto-elf.c (is_compatible_architecture): New static function.
4065 (DEFINE_VALIDATE_EHDR): Use it to validate the architecture.
4067 2010-02-11 Richard Guenther <rguenther@suse.de>
4070 * lto-elf.c (lto_elf_file_open): Handle file@offset case more
4073 2010-01-11 Andy Hutchinson <hutchinsonandy@gcc.gnu.org>
4075 * lto.c (O_BINARY): Define.
4076 (lto_read_section_data): Open file in binary mode.
4077 * lto-elf.c (O_BINARY): Define.
4078 (lto_elf_file_open): Open file in binary mode.
4080 2010-01-08 Richard Guenther <rguenther@suse.de>
4083 * lto-lang.c (lto_handle_option): Handle -f[un]signed-char.
4084 (lto_init): Do not init char_type_node in a standard way
4085 but according to flag_signed_char.
4087 2010-01-03 H.J. Lu <hongjiu.lu@intel.com>
4090 * lto.c (DUMPBASE_SUFFIX): New.
4091 (lto_execute_ltrans): Append a sequence number to -dumpbase
4094 2010-01-02 H.J. Lu <hongjiu.lu@intel.com>
4097 * lto-elf.c (lto_elf_file_open): Stop if the command line
4098 option file is missing.
4100 2009-12-15 Richard Guenther <rguenther@suse.de>
4102 * lto.c (lto_fixup_field_decl): Fixup DECL_FIELD_OFFSET.
4103 (lto_post_options): Do not disable debuginfo.
4105 2009-12-14 Dmitry Gorbachev <d.g.gorbachev@gmail.com>
4107 * Make-lang.in ($(LTO_EXE)): Use $(LINKER).
4109 2009-12-11 Richard Guenther <rguenther@suse.de>
4112 * lto.c (lto_resolution_read): Properly grow the vector.
4114 2009-12-11 Richard Guenther <rguenther@suse.de>
4117 * lto-lang.c (lto_init_options): Initialize flag_complex_method
4118 to the C99 default. Do not set flag_unit_at_a_time.
4120 2009-11-28 Jakub Jelinek <jakub@redhat.com>
4122 * lto-lang.c (handle_nonnull_attribute): Remove unused attr_arg_num
4125 2009-11-19 Rafael Avila de Espindola <espindola@google.com>
4128 * lto-elf.c (lto_elf_file_open): Use lto_parse_hex.
4129 * lto.c (lto_parse_hex): New.
4130 (lto_resolution_read): Use lto_parse_hex.
4131 * lto.h (lto_parse_hex): New.
4133 2009-11-17 Rafael Avila de Espindola <espindola@google.com>
4135 * lto-elf.c (lto_file_init): Add offset argument.
4136 (lto_elf_file_open): Record the offset.
4137 * lto.c (lto_resolution_read): Change file_name into a lto_file
4138 argument. Check offsets.
4139 (lto_file_read): Update call to lto_resolution_read.
4140 * lto.h (lto_file_struct): Add the offset field.
4142 2009-11-16 Rafael Avila de Espindola <espindola@google.com>
4144 * lto-elf.c (lto_elf_file_open): Use strtoll to parse the offset.
4146 2009-11-14 Jan Hubicka <jh@suse.cz>
4148 * lto.c (read_cgraph_and_symbols): Set also ipa_transforms_to_apply.
4150 2009-11-12 Rafael Avila de Espindola <espindola@google.com>
4152 * lang.opt (fresolution): Renamed from resolution.
4153 * lto-lang.c (lto_handle_option): Handle new option name.
4154 * lto.c (lto_resolution_read): Add more checks. Discard rest of line.
4156 2009-11-04 Richard Guenther <rguenther@suse.de>
4157 Rafael Avila de Espindola <espindola@google.com>
4159 * lto-elf.c (lto_elf_build_section_table): Add the base offset.
4160 (lto_elf_file_open): Handle offsets in arguments name@offest.
4162 2009-10-30 Richard Guenther <rguenther@suse.de>
4165 * lto.c (lto_file_read): Do not set file_data->fd.
4166 (lto_read_section_data): Use a single-entry file-descriptor cache.
4167 Do not check the result of xmalloc.
4168 (free_section_data): Do not use file_data->fd.
4169 (lto_read_all_file_options): Likewise.
4171 2009-10-22 Richard Guenther <rguenther@suse.de>
4173 * lto.c (lto_fixup_jump_functions): Remove.
4174 (lto_fixup_decls): Do not fixup jump functions.
4175 (read_cgraph_and_symbols): Schedule cgraph merging after
4176 summary reading. Schedule type and decl fixup before
4179 2009-10-22 Richard Guenther <rguenther@suse.de>
4181 * lto.c (lto_fixup_data_t): Remove free_list member.
4182 (lto_fixup_tree): Do not insert into free_list.
4183 (free_decl): Remove.
4184 (lto_fixup_decls): Remove free-list handling.
4186 2009-10-22 Jan Hubicka <jh@suse.cz>
4188 * lto.c (lto_fixup_jump_functions): New function.
4189 (lto_fixup_decls): Use it.
4191 2009-10-16 Richard Guenther <rguenther@suse.de>
4194 * lto.c (lto_fixup_tree): Revert last change.
4196 2009-10-14 Richard Guenther <rguenther@suse.de>
4198 * lto.c (lto_fixup_tree): In case the prevailing decl is not
4199 compatible with the one we replace wrap it around a
4202 2009-10-09 Richard Guenther <rguenther@suse.de>
4206 * lto.c (read_cgraph_and_symbols): Do not assert we can open
4208 * lto-elf.c (init_shdr##BITS): Fix i18n problems.
4209 (init_ehdr##BITS): Likewise.
4211 2009-10-08 Joseph Myers <joseph@codesourcery.com>
4213 * lto-elf.c (init_shdr##BITS, lto_elf_begin_section_with_type,
4214 init_ehdr##BITS, lto_elf_file_close): Remove trailing "." from
4216 * lto-lang.c (lto_post_options): Remove trailing "." from
4219 2009-10-08 Richard Guenther <rguenther@suse.de>
4221 * lto.c (read_cgraph_and_symbols): Free the gimple type merging
4224 2009-10-07 Joseph Myers <joseph@codesourcery.com>
4226 * lto.c: Only include <sys/mman.h> if HAVE_MMAP_FILE.
4228 2009-10-07 Jan Hubicka <jh@suse.cz>
4230 * lto.c (read_cgraph_and_symbols): Mark functions neccesary only at
4231 ltrans stage; explain why this is needed and should not.
4233 2009-10-05 Richard Guenther <rguenther@suse.de>
4237 * lto.c (lto_read_decls): Do not register deferred decls.
4238 (read_cgraph_and_symbols): Delay symbol and cgraph merging
4239 until after reading the IPA summaries.
4241 2009-10-02 Rafael Avila de Espindola <espindola@google.com>
4243 * Make-lang.in (lto/lto-lang.o): Don't depend on lto/common.h.
4244 (lto-lang.c): Don't include lto/common.h.
4246 2009-10-02 Rafael Avila de Espindola <espindola@google.com>
4248 * Make-lang.in (LTO_OBJS): Remove lto/common.o.
4249 (lto/common.o): Remove.
4251 * common.h (lto_kind_str): Remove.
4252 (lto_visibility_str): Remove.
4253 (lto_resolution_str): Make it static.
4255 2009-10-01 Diego Novillo <dnovillo@google.com>
4257 * lto.c (lto_read_decls): Add comment.
4258 Call internal_error instead of gcc_assert.
4259 (lto_resolution_read): Likewise.
4260 (lto_add_all_inlinees): Tidy.
4261 * Make-lang.in: Fix copyright boilerplate.
4263 (lto.install-pdf): New.
4264 * lto-tree.h: Fix copyright boilerplate.
4265 * lang-specs.h: Likewise.
4266 Remove ".lto" entry from compilers fragment.
4267 * lto-elf.c: Move inclusion of gelf.h after config.h.
4268 Tidy formatting everywhere.
4269 * lto.h: Fix copyright boilerplate.
4270 Tidy formatting everywhere.
4271 * common.c: Likewise.
4272 * config-lang.in: Likewise.
4273 * common.h: Likewise.
4274 * lto-lang.c: Likewise.
4276 2009-10-01 Richard Guenther <rguenther@suse.de>
4278 * lto.c (lto_read_section_data): Use plain lseek/read.
4280 2009-10-01 Richard Guenther <rguenther@suse.de>
4282 * lto.c (LTO_MMAP_IO): Define if we can mmap files and
4283 use sysconf to query the system page size.
4284 (lto_file_read): Implement fallback using stdio.
4285 (free_section_data): Likewise.
4287 2009-09-29 Diego Novillo <dnovillo@google.com>
4289 * lto-lang.c (lto_init): Really fix call to
4290 build_common_builtin_nodes.
4292 2009-09-29 Diego Novillo <dnovillo@google.com>
4294 * lto-lang.c (lto_init): Fix call to
4295 build_common_builtin_nodes.
4297 2009-09-29 Richard Guenther <rguenther@suse.de>
4300 * lto-elf.c (init_shdr##BITS): Properly specify alignment
4302 (first_data_block): New static variable.
4303 (lto_elf_append_data): Align the first data block in each
4306 2009-09-28 Diego Novillo <dnovillo@google.com>
4308 * lto-lang.c: Tidy. Remove stale FIXME lto markers.
4309 * lto.c (strip_extension): New.
4310 (get_filename_for_set): Call it. Do not call make_cwd_temp_file.
4311 (lto_execute_ltrans): Tidy.
4312 Do not pass -fwpa nor -fltrans-* to LTRANS.
4313 * opts.c: Tidy formatting and remove stale FIXME lto markers.
4314 * tree.c (need_assembler_name_p): Call
4315 lang_hooks.decls.may_need_assembler_name_p if set.
4316 * varasm.c (default_binds_local_p_1): Remove check for
4318 * varpool.c (decide_is_variable_needed): Do not test for
4321 2009-09-22 Richard Guenther <rguenther@suse.de>
4324 * lto.c (lto_execute_ltrans): Perform ltrans phase manually.
4325 * Make-lang.in: Remove ltrans-driver stuff.
4326 * config-lang.in: Likewise.
4327 * lang.opt (fltrans-driver): Remove.
4328 * lto-lang.c (lto_init_options): Remove code initializing
4330 * ltrans-driver: Remove.
4332 2009-09-21 Diego Novillo <dnovillo@google.com>
4334 * lto-lang.c (lto_define_builtins): Remove superfluous
4335 calls to targetm.init_builtins and build_common_builtin_nodes.
4336 (lto_init): Add targetm.arm_eabi_unwinder as parameter to
4337 build_common_builtin_nodes.
4338 * lto.c (lto_materialize_function): Do nothing if NODE is a
4341 2009-09-03 Diego Novillo <dnovillo@google.com>
4343 * lto-elf.c (validate_file): Replace call to
4344 elf_getshstrndx with call to elf_getshdrstrndx.
4346 2009-08-19 Richard Guenther <rguenther@suse.de>
4348 * lto-lang.c (lto_init): Merge char_type_node with the
4349 appropriately signed variant.
4351 2009-08-19 Richard Guenther <rguenther@suse.de>
4354 * lto.c (lto_fixup_common): Re-build the pointer-to chain part one.
4355 (lto_fixup_type): Re-build the pointer-to chain part two.
4357 2009-08-19 Richard Guenther <rguenther@suse.de>
4360 * lto.c (lto_fixup_type): Re-build the type variant chain.
4362 2009-08-19 Richard Guenther <rguenther@suse.de>
4365 * lto.c (lto_fixup_constructor): New function.
4366 (lto_fixup_tree): Replace all types. Properly fixup
4367 constructors and constants.
4369 2009-08-14 Richard Guenther <rguenther@suse.de>
4371 * lto.c (read_cgraph_and_symbols): Exchange TREE_CHAIN use
4372 for DECL_LANG_SPECIFIC.
4374 2009-08-13 Richard Guenther <rguenther@suse.de>
4377 * lto-lang.c (LANG_HOOKS_TYPES_COMPATIBLE_P): Define to NULL.
4379 2009-07-30 Richard Guenther <rguenther@suse.de>
4382 * lto.c (read_cgraph_and_symbols): After fixing up decls choose
4383 the largest decl for output and free TREE_CHAIN for further
4386 2009-07-24 Diego Novillo <dnovillo@google.com>
4388 * Make-lang.in: Add empty lto.install-plugin target.
4390 2009-07-13 Diego Novillo <dnovillo@google.com>
4392 * lto.c (lto_fixup_tree): Handle IMPORTED_DECL.
4394 2009-07-11 Richard Guenther <rguenther@suse.de>
4396 * lto-lang.c (lto_write_globals): Wrapup global decls.
4398 2009-07-10 Richard Guenther <rguenther@suse.de>
4400 * lto-lang.c (lto_init): Allocate one more location to make
4401 BUILTINS_LOCATION correct.
4403 2009-07-09 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
4405 * lto.c (free_section_data): Cast computed_offset to caddr_t.
4407 2009-07-06 Diego Novillo <dnovillo@google.com>
4409 * lto.c (lto_fixup_type): Fixup TYPE_SIZE and
4412 2009-07-06 Diego Novillo <dnovillo@google.com>
4414 * lto.c (preload_common_nodes): Remove.
4415 (lto_read_in_decl_state): Call lto_streamer_cache_get.
4416 (lto_read_decls): Call lto_data_in_create and
4418 (free_decl): Do not call ggc_free.
4419 (lto_main): Call lto_init_reader.
4420 * lto-lang.c (lto_type_for_size): Handle intTI_type_node.
4421 (lto_init): Initialize main_identifier_node if needed.
4422 Make ptrdiff_type_node be integer_type_node.
4424 2009-06-19 Diego Novillo <dnovillo@google.com>
4426 * lto.c: Remove code guarded by #ifdef LTO_STREAM_DEBUGGING.
4427 Remove code guarded by #ifdef GLOBAL_STREAMER_TRACE.
4428 Remove code guarded by #ifdef LOCAL_TRACE.
4430 2009-06-18 Diego Novillo <dnovillo@google.com>
4432 * lto.c: Update license to GPLv3.
4433 * lto-elf.c: Likewise.
4434 * common.c: Likewise.
4435 * lto-lang.c: Likewise.
4436 * lto.h: Remove superfluous include files. Update all
4439 2009-06-17 Diego Novillo <dnovillo@google.com>
4441 * lto.c (read_cgraph_and_symbols): Call input_cgraph.
4443 2009-06-02 Diego Novillo <dnovillo@google.com>
4445 * lto.c (lto_1_to_1_map): Ignore nodes that have not been
4447 (materialize_cgraph): Only materialize nodes that have a
4448 representation on file.
4450 2009-06-01 Diego Novillo <dnovillo@google.com>
4452 * lto-lang.c (lto_handle_option): Hanlde OPT_Wabi.
4454 2009-05-31 Diego Novillo <dnovillo@google.com>
4456 * lto-lang.c (lto_type_for_mode): Handle all the modes
4457 handled in c_common_type_for_mode.
4459 2009-05-21 Diego Novillo <dnovillo@google.com>
4461 * lto-elf.c: Always include <gelf.h>.
4462 * config-lang.in (target_libs): Remove.
4463 (build_by_default): Set to no.
4465 2009-05-15 Diego Novillo <dnovillo@google.com>
4467 * lto.c (lto_materialize_function): Assert that DECL is
4469 (materialize_cgraph): Don't try to materialize builtin
4471 * lto-section-out.c (write_symbol_vec): Do not write
4474 2009-05-13 Diego Novillo <dnovillo@google.com>
4476 * lto-lang.c (LANG_HOOKS_GET_ALIAS_SET): Define.
4478 2009-05-07 Diego Novillo <dnovillo@google.com>
4480 * lto.c (lto_resolution_read): Add type casts for C++ warnings.
4481 (LTO_REGISTER_TYPE_AND_FIXUP_SUBTREE): Define.
4482 (lto_fixup_type): Call it for TYPE_POINTER_TO,
4483 TYPE_REFERENCE_TO, TYPE_CONTEXT and TYPE_CANONICAL.
4484 (lto_fixup_tree): Call gimple_register_type when *TP is a
4486 (lto_main): Call bitmap_obstack_initialize.
4488 2009-04-22 Diego Novillo <dnovillo@google.com>
4490 * lto.c (free_section_data): Tidy.
4491 (lto_1_to_1_map): Tidy.
4492 (lto_add_all_inlinees): Tidy.
4493 (prefix_name_with_star): New.
4494 (get_filename_for_set): New.
4495 (lto_wpa_write_files): Call cgraph_node_set_needs_ltrans_p
4496 to determine what cgraph node sets to write.
4497 Call get_filename_for_set to compute temporary file
4499 (lto_execute_ltrans): Do not execute LTRANS on files with
4500 names that start with '*'.
4501 Move logic to execute LTRANS together so that LTRANS is
4502 invoked only if there are any files to compile.
4503 (do_whole_program_analysis): Only remove output files
4504 that do not start with '*'.
4506 2009-04-06 Diego Novillo <dnovillo@google.com>
4508 * lto-lang.c (lto_post_options): Set flag_excess_precision_cmdline.
4509 * lto.c (read_cgraph_and_symbols): Set cgraph_function_flags_ready.
4510 (lto_add_all_inlinees): Tidy.
4512 2009-03-26 Diego Novillo <dnovillo@google.com>
4514 * lto.c: Include gimple.h.
4515 (lto_read_in_decl_state): Call gimple_register_type for
4516 every type in every stream.
4517 (lto_fixup_common): Call gimple_register_type if T has a
4519 (do_whole_program_analysis): Call print_lto_report.
4520 (lto_main): Call print_lto_report after cgraph_optimize.
4521 * Make-lang.in (lto.o): Add dependency on GIMPLE_H.
4523 2009-03-24 Diego Novillo <dnovillo@google.com>
4525 * Make-lang.in (lto-lang.o): Add dependency on TARGET_H and EXPR_H.
4526 (lto.o): Add dependency on GIMPLE_H.
4528 2009-03-10 Simon Baldwin <simonb@google.com>
4530 * lto.c (lto_read_all_file_options): Close any open file descriptor
4531 contained in file_data before freeing.
4533 2009-02-24 Rafael Avila de Espindola <espindola@google.com>
4535 * lto.c (lto_add_inline_clones): Don't add the master clone. Check
4536 for a decl in the original bitmap, not a node.
4537 (lto_add_all_inlinees): Remove original nodes that are not needed.
4538 (lto_scan_statics_in_cgraph_node): Don't care if the node is the master.
4540 2009-02-24 Diego Novillo <dnovillo@google.com>
4542 * lto.c (lto_materialize_function): Update
4543 lto_stats.num_function_bodies.
4544 (get_section_data): Initialize *LEN to 0.
4545 (lto_1_to_1_map): Update lto_stats.num_cgraph_partitions.
4546 (lto_wpa_write_files): Update lto_stats.num_cgraph_nodes.
4547 Update lto_stats.num_output_files.
4548 (read_cgraph_and_symbols): Update lto_stats.num_input_files.
4549 (materialize_cgraph): Update lto_stats.num_input_cgraph_nodes.
4550 (lto_main): Initialize lto_stats.
4551 If flag_lto_report is set, call print_lto_report.
4553 2009-02-19 Diego Novillo <dnovillo@google.com>
4557 2009-02-19 Rafael Avila de Espindola <espindola@google.com>
4559 * lto.c (lto_add_inline_clones): Don't add the
4560 master clone. Check for a decl in the original
4562 (lto_add_all_inlinees): Remove original nodes
4563 that are not needed.
4564 (lto_scan_statics_in_cgraph_node): Don't care if
4565 the node is the master.
4566 (lto_promote_cross_file_statics): Use a new
4567 context.seen_node_decls for each set
4569 2009-02-19 Rafael Avila de Espindola <espindola@google.com>
4571 * lto.c (lto_add_inline_clones): Don't add the master clone. Check
4572 for a decl in the original bitmap, not a node.
4573 (lto_add_all_inlinees): Remove original nodes that are not needed.
4574 (lto_scan_statics_in_cgraph_node): Don't care if the node is the master.
4575 (lto_promote_cross_file_statics): Use a new context.seen_node_decls
4578 2009-02-18 Diego Novillo <dnovillo@google.com>
4580 * lto.c (lto_wpa_write_files): Use timers TV_WHOPR_WPA
4581 and TV_WHOPR_WPA_IO.
4582 (lto_execute_ltrans): Use timer TV_WHOPR_WPA_LTRANS_EXEC.
4583 (read_cgraph_and_symbols): Use timer TV_IPA_LTO_DECL_IO.
4584 (materialize_cgraph): Use timer TV_IPA_LTO_GIMPLE_IO.
4585 Use timer TV_WHOPR_WPA or TV_WHOPR_LTRANS or TV_LTO
4586 depending on command line flags.
4587 (do_whole_program_analysis): Use timer TV_WHOPR_WPA.
4588 (lto_main): Remove timer uses.
4590 2009-02-18 Rafael Avila de Espindola <espindola@google.com>
4592 * lto.c (lto_materialize_function): Don't set DECL_EXTERN to 0.
4593 (lto_wpa_write_files): Update calls to renamed functions.
4595 2009-02-17 Diego Novillo <dnovillo@google.com>
4598 * lto-lang.c (lto_post_options): Disable -fwhole-program
4599 when running LTRANS.
4601 2009-02-10 Diego Novillo <dnovillo@google.com>
4603 * lto.c (read_cgraph_and_symbols): Fix comment.
4605 2009-02-10 Diego Novillo <dnovillo@google.com>
4607 * lto.c (read_cgraph_and_symbols): Read options from all
4610 2009-02-10 Diego Novillo <dnovillo@google.com>
4612 * lto.c (read_cgraph_and_symbols): Factor out of lto_main.
4613 (materialize_cgraph): Likewise.
4614 (do_whole_program_analysis): Likewise.
4615 (lto_main): Call read_cgraph_and_symbols,
4616 materialize_cgraph and do_whole_program_analysis.
4618 2009-02-10 Simon Baldwin <simonb@google.com>
4620 * lto.c: Include lto-opts.h.
4621 * (lto_main): Clear file options at loop start, read any saved
4622 options from the first file handled, and re-issue options.
4623 * Makefile.in (lto.o): Add dependency on lto-opts.h.
4625 2009-02-02 Diego Novillo <dnovillo@google.com>
4627 * lto.c (lto_main): Stop LTO_TIMER and use
4628 TV_WHOPR_WPA_LTRANS_EXEC when launching LTRANS.
4630 2009-01-30 H.J. Lu <hongjiu.lu@intel.com>
4633 * lto-elf.c (init_shdr##BITS): Set the sh_addralign field
4636 2009-01-29 Ramana Radhakrishnan <ramana.r@gmail.com>
4638 * Make-lang.in (LTO_EXE): Link with all
4639 BACKENDLIBS and not only GMPLIBS
4641 2009-01-28 H.J. Lu <hongjiu.lu@intel.com>
4644 * lto-elf.c: Include gelf.h instead of libelf.h.
4645 (lto_elf_file_close): Replace elfx_update_shstrndx with
4646 gelf_getehdr, elf_getscn, gelf_getshdr, gelf_update_shdr and
4649 2009-01-28 H.J. Lu <hongjiu.lu@intel.com>
4652 * lto-elf.c (DEFINE_INIT_EHDR): Initialize e_version.
4654 2009-01-26 Diego Novillo <dnovillo@google.com>
4656 * lto-lang.c (LANG_HOOKS_TYPES_COMPATIBLE_P): Update.
4658 2009-01-26 Diego Novillo <dnovillo@google.com>
4660 * lto-lang.c (lto_types_compatible_p): Move to gimple.c
4661 and rename into gimple_types_compatible_p.
4663 2009-01-12 Rafael Avila de Espindola <espindola@google.com>
4665 * lto-lang.c (lang_hooks): Remove the const qualifier.
4667 2009-01-06 Diego Novillo <dnovillo@google.com>
4669 * ltrans-driver: Mark 'all' target as phony.
4671 2008-12-31 Diego Novillo <dnovillo@google.com>
4673 * ltrans-driver: Execute a NOP action for target 'all'.
4675 2008-12-19 Diego Novillo <dnovillo@google.com>
4677 * lto.c (lto_1_to_1_map): Tidy.
4679 2008-12-19 Diego Novillo <dnovillo@google.com>
4681 * lto-elf.c (lto_elf_file_open): When FILENAME cannot
4682 be opened, show its name.
4683 * ltrans-driver: If $verbose is set, do not use parallelism.
4685 2008-12-17 Rafael Avila de Espindola <espindola@google.com>
4687 * lto.c (lto_fixup_function): New.
4688 (lto_fixup_tree): Call lto_fixup_function.
4690 2008-12-14 Doug Kwan <dougkwan@google.com>
4692 * lto.c (lto_1_to_1_map): Create a cgraph node set for any global
4693 variables if there is no function.
4695 2008-12-10 Simon Baldwin <simonb@google.com>
4697 * ltrans-driver: Always run make in silent mode, to avoid make's
4698 trace on stdout interfering with lto-wrapper output.
4700 2008-12-10 Doug Kwan <dougkwan@google.com>
4702 * lto.c (lto_add_inline_clones): Do not force master clones of
4703 inlined functions already in SET to be static inline.
4705 2008-12-04 Doug Kwan <dougkwan@google.com>
4707 * lto.c (globalize_context_t): New type to store states in
4708 globalization of cross-file statics.
4709 (globalize_cross_file_statics): New.
4710 (lto_scan_statics_in_ref_table): Walk tree to look for reachable
4711 static decls that need to be fixed up.
4712 (lto_scan_statics_in_cgraph_node): Change call interface to use
4713 a globalize_context_t CONTEXT for all states used.
4714 (lto_scan_statics_in_remaining_global_vars): New.
4715 (lto_promote_cross_file_statics): Use new call interface of
4716 LTO_SCAN_STATICS_IN_CGRAPH_NODE. Handle remaining externally
4717 visible vars in the last set.
4719 2008-12-03 Diego Novillo <dnovillo@google.com>
4721 * lto.c (lto_fixup_tree): Do not emit an error when
4722 PREVAILING throw but T doesn't.
4724 2008-12-02 Doug Kwan <dougkwan@google.com>
4726 * lto.c (lto_scan_statics_in_ref_table): New function factored out
4728 (lto_scan_statics_in_cgraph_node): Handle both file-scope static
4729 variables and functions.
4730 (lto_promote_cross_file_statics): Rename bitmaps to SEEN_DECLS
4731 and GLOBAL_DECLS from SEEN_VARS and GLOBAL_VARS.
4733 2008-11-29 Diego Novillo <dnovillo@google.com>
4735 * lto.c: Include timevar.h.
4736 (lto_materialize_function): Tidy. Add comments.
4737 (lto_wpa_write_files): Tidy.
4738 (lto_execute_ltrans): Tidy.
4739 (lto_main): Add local variable LTO_TIMER. Initialize it
4740 to one of TV_WHOPR_WPA, TV_WHOPR_LTRANS or TV_LTO.
4741 Start and stop the timer.
4743 * Make-lang.in (lto.o): Add dependency on timevar.h.
4744 * ltrans-driver: React to -v and -save-temps.
4745 Use simple heuristic to determine how much parallelism to
4746 use when executing make.
4748 2008-11-12 Doug Kwan <dougkwan@google.com>
4750 * lto.c (lto_bitmap_obstack): Remove var.
4751 (lto_materialize_function): Do nothing instead of marking function
4752 body in file if flag_wpa is true.
4753 (lto_add_all_inlinees): Use bitmap functions in lto-utils.c.
4754 (lto_scan_statics_in_cgraph_node): New function.
4755 (lto_promote_cross_file_statics): Same.
4756 (lto_wpa_write_files): Call lto_promote_cross_file_statics.
4757 Use bitmap functions in lto-utils.c. Remove unsued label OUT.
4758 * Make-lang.in (lto/lto.o): Add lto-utils.h to dependency list.
4760 2008-11-09 Diego Novillo <dnovillo@google.com>
4762 * lto.c (lto_fixup_tree): Change error message locus
4763 information to include location of mismatching
4765 Use TREE_NO_WARNING to avoid repeated messages.
4766 (lto_main): If lto_fixup_decls emitted any errors, exit.
4767 * lto-lang.c: Don't include libfuncs.h and except.h
4768 (lto_init_options): Don't enable exceptions by default.
4769 (lto_eh_runtime_type): Move to lto-function-in.c
4770 (lto_init_eh): Likewise.
4771 (lto_init): Don't call lto_init_eh.
4772 * Make-lang.in (lto-lang.o): Remove dependency on
4773 libfuncs.h and except.h.
4775 2008-10-30 Diego Novillo <dnovillo@google.com>
4777 * lto.c (lto_read_decls): Declare debug_main only if
4778 LTO_STREAM_DEBUGGING is enabled.
4780 2008-10-30 Simon Baldwin <simonb@google.com>
4782 * lto.c (lto_wpa_write_files): Create intermediate files with
4783 make_cwd_temp_file().
4784 (lto_maybe_unlink): New. Delete intermediate WPA files unless
4785 WPA_SAVE_LTRANS is set.
4786 (lto_main): Call lto_maybe_unlink() for intermediate WPA files.
4787 * ltrans-driver: Do not strip directory from output files.
4789 2008-10-29 Doug Kwan <dougkwan@google.com>
4791 * lto.c (free_decl): Call lto_symtab_clear_resolution when freeing
4793 * Make-lang.in (LTO_OBJS): Remove lto/lto-symtab.o
4794 (lto/lto-symtab.o): Remove rule.
4795 * lto-tree.h (struct lang_identifier): Remove LTO specific fields.
4796 (struct lang_decl): Remove RESOLUTION and add DUMMY in struct.
4797 (LANG_IDENTIFIER_CAST, LTO_IDENTIFIER_DECL, LTO_DECL_RESOLUTION):
4799 lto-symtab.c (File): Move up one level.
4800 lto-lang.c (cgraph.h): Remove include.
4801 (input_overwrite_node, input_node, input_edge, input_cgraph_1,
4802 input_cgraph): Move to lto-cgraph.c in gcc directory above.
4803 (LANG_HOOKS_INPUT_CGRAPH): Remove use of macro.
4805 2008-10-24 Rafael Espindola <espindola@google.com>
4807 * lto-function-in.c (get_resolution): Return LDPR_PREEMPTED_IR for
4808 non prevailing weak symbols.
4810 2008-10-24 Rafael Espindola <espindola@google.com>
4812 * lto-lang.c (input_cgraph_1): Iterate over nodes, not cgraph_nodes.
4814 2008-10-24 Rafael Espindola <espindola@google.com>
4816 * lto-lang.c (input_node): Avoid casts from pointers to ints of
4819 2008-10-23 Simon Baldwin <simonb@google.com>
4821 * lto-lang.c (input_node): Save the node reference, rather than the
4822 node pointer, in node->inlined_to.
4823 (input_cgraph_1): Convert node references into node pointers.
4825 2008-10-22 Diego Novillo <dnovillo@google.com>
4826 Rafael Espindola <espindola@google.com>
4828 * lto.c (lto_resolution_read): Tidy.
4829 * lto-symtab.c (lto_symtab_prevailing_decl): Do not
4830 abort if RET is NULL.
4832 2008-10-22 Doug Kwan <dougkwan@google.com>
4834 * lto.c (lto_fixup_tree): Check for NOTHROW conflict only if
4835 exceptions flag is given.
4836 * lto-lang.c: (lto_init_options) Set default exceptions flag.
4837 (lto_init_eh): Remove exceptions flag initialization.
4838 (lto_init): Only call lto_init_eh if exceptions flag is set.
4840 2008-10-21 Diego Novillo <dnovillo@google.com>
4842 * lto.c: Tidy some formatting.
4845 2008-10-21 Simon Baldwin <simonb@google.com>
4847 * lto-symtab.c: (lto_same_type_p): Types cannot be equal if one of
4848 them is NULL (but not the other).
4850 2008-10-17 Diego Novillo <dnovillo@google.com>
4852 * ltrans-driver: Divert output from make to a temporary file.
4853 Show it if the call to make failed.
4855 2008-10-15 Diego Novillo <dnovillo@google.com>
4857 * lto.c (lto_wpa_write_files): Reformat do-while loop.
4858 Do not print TEMP_FILENAME
4859 * ltrans-driver: Call make with -s.
4861 2008-10-15 Diego Novillo <dnovillo@google.com>
4863 * lto-symtab.c (lto_symtab_merge_decl): Do not force
4864 TREE_STATIC on global symbols.
4866 2008-10-14 Ollie Wild <aaw@google.com>
4868 * Make-lang.in (LTRANS_DRIVER_INSTALL_NAME): Remove.
4869 (LTRANS_DRIVER_EXE): Add.
4870 (lto.all.cross): Add LTRANS_DRIVER_EXE.
4871 (lto.all.encap): Add LTRANS_DRIVER_EXE.
4872 (lto.install.common): Remove ltrans-driver.
4873 (lto.mostlyclean): Add LTRANS_DRIVER_EXE.
4874 (LTRANS_DRIVER_EXE): New build rule.
4875 * config-lang.in (compilers): Add ltrans-driver.
4877 2008-10-14 Diego Novillo <dnovillo@google.com>
4879 * Make-lang.in (LTRANS_DRIVER_INSTALL_NAME): Disable transformation
4882 2008-10-13 Ollie Wild <aaw@google.com>
4884 * lang-spec.h (@lto): Replace lto1_options with cc1_options.
4885 * lto.c (lto_execute_ltrans): Add "-fno-wpa -fltrans -xlto" to CFLAGS.
4886 * ltrans-driver (LTRANS_FLAGS): Remove.
4888 2008-10-08 Doug Kwan <dougkwan@google.com>
4890 * lto.c (lto_fixup_tree): Remove ATTRIBUTE_UNUSED from DATA.
4891 Handle new tree codes RECORD_TYPE, UNION_TYPE, QUAL_UNION_TYPE
4892 and TREE_BINFO. Also move code handling FUNCTION_DECL and VAR_DECL
4893 from lto_fixup_state to here.
4894 (lto_fixup_state): Take an lto_fixup_data_t object DATA instead of
4895 just a free-list. Fix up types also. Move decl merging code to
4897 (lto_fixup_state_aux): Change AUX to point to an lto_fixup_data_t
4899 (lto_fixup_decls): Use another pointer set to avoid multiple
4900 walking of nodes except for DECLs to be replaced. Pass an
4901 lto_fixup_data_t object to tree-walker.
4903 2008-10-08 Rafael Espindola <espindola@google.com>
4905 * lto-symtab.c (lto_symtab_set_resolution): New.
4906 (lto_symtab_merge_decl): Use lto_symtab_set_resolution and
4907 lto_symtab_get_resolution.
4908 (lto_symtab_prevailing_decl): Return decl for non public decls.
4909 (lto_symtab_get_resolution): New.
4910 * lto.c (lto_fixup_tree, lto_fixup_state): Remove unecessary checks.
4912 2008-10-06 Rafael Espindola <espindola@google.com>
4914 * lto-lang.c: Include cgraph.h.
4915 (input_overwrite_node, input_node, input_edge, input_cgraph_1,
4916 input_cgraph): Moved from lto-cgraph.c.
4917 (LANG_HOOKS_INPUT_CGRAPH): New.
4919 2008-10-03 Rafael Espindola <espindola@google.com>
4921 * lto.c (lto_fixup_tree, lto_fixup_state): Fix the FIXME.
4923 2008-10-03 Rafael Espindola <espindola@google.com>
4925 * lto-symtab.c (lto_symtab_overwrite_decl): Remove. Remove all calls.
4926 (lto_symtab_merge_decl): Update LTO_IDENTIFIER_DECL the reflect the
4927 prevailing definition. Don't mark TREE_NOTHROW differences.
4928 * lto.c (lto_fixup_tree): New.
4929 (lto_fixup_state): New.
4930 (lto_fixup_state_aux): New.
4932 (lto_fixup_decls): New.
4933 (lto_main): Call lto_fixup_decls.
4935 2008-10-02 Ollie Wild <aaw@google.com>
4937 * lang.opt (fltrans): Moved from common.opt. Remove RejectNegative
4939 (fwpa): Moved from common.opt. Remove RejectNegative and Init.
4940 * lto-lang.c (lto_post_options): Add validation and fixups for
4943 2008-10-02 Rafael Espindola <espindola@google.com>
4945 * lto-symtab.c (lto_symtab_merge_var, lto_symtab_merge_fn,
4946 lto_symtab_merge_decl): Return void.
4947 (lto_symtab_prevailing_decl): New.
4949 2008-09-30 Rafael Espindola <espindola@google.com>
4951 * lto-symtab.c (lto_symtab_compatible): Remove the check for already
4953 (lto_symtab_overwrite_decl): Copy LTO_DECL_RESOLUTION.
4954 (lto_symtab_merge_decl): Store symbol resolution in LTO_DECL_RESOLUTION.
4955 Check for already defined symbols.
4956 * lto-tree.h (lang_decl): Remove dummy and add resolution fields.
4957 (LTO_IDENTIFIER_RESOLUTION): Remove.
4958 (LTO_DECL_RESOLUTION): New.
4960 2008-09-30 Rafael Espindola <espindola@google.com>
4962 * lto.c (lto_read_decls): Use new input_tree signature.
4964 2008-09-26 Doug Kwan <dougkwan@google.com>
4966 * lto.c (lto_main): Call lto_fixup_nothrow_decls to fix up function
4967 bodies affected by exception attribute merging of DECLs.
4968 * lto-symtab.c (lto_symtab_merge_decl): Handle exception attribute
4971 2008-09-25 Rafael Espindola <espindola@google.com>
4973 * Make-lang.in (PLUGIN_API_H, LTO_TREE_H): New.
4974 (lto/lto-lang.o, lto/lto.o, lto/lto-symtab.o) Use LTO_TREE_H.
4975 * lto-symtab.c (lto_symtab_compatible): New.
4976 (lto_symtab_overwrite_decl): New.
4977 (lto_symtab_merge_decl): Refactor to use the above functions
4978 and the resolution from lang_identifier.
4979 * lto-tree.h: Include plugin-api.h.
4980 (lang_identifier): Add resolution.
4981 (LTO_IDENTIFIER_RESOLUTION): New.
4983 2008-09-25 Ollie Wild <aaw@google.com>
4985 * lang.opt (fltrans-output-list=): New option.
4986 * lto.c (lto_execute_ltrans): Output file names to ltrans_output_list.
4988 2008-09-25 Rafael Espindola <espindola@google.com>
4990 * lto.c (lto_resolution_read): Initialize ret;
4992 2008-09-24 Ollie Wild <aaw@google.com>
4994 * lto.c (sys/mman.h): Move include.
4995 (lto_wpa_write_files): Return a list of written files.
4996 (lto_execute_ltrans): New function.
4997 (lto_main): Call lto_execute_ltrans.
4998 (ltrans-driver): New file.
4999 * lto-lang.c (DEFAULT_LTRANS_DRIVER): New macro.
5000 (DEAULT_LTRANS_DRIVER_LEN): New macro.
5001 (lto_init_options): Initialize ltrans_driver.
5002 (lto_handle_option): Fix incorrect default output value.
5003 * lang.opt (fltrans-driver=): New option.
5004 * Make-lang.in (LTRANS_DRIVER_INSTALL_NAME): New variable.
5005 (lto.install-common): Add lto/ltrans-driver.
5007 2008-09-24 Rafael Espindola <espindola@google.com>
5009 * Make-lang.in (LTO_OBJS): Add lto/common.o.
5010 (lto/lto.o): Depend on lto/common.h.
5011 (lto/common.o): New.
5012 * lang.opt (resolution): New.
5013 * lto-lang.c (resolution_file_name): New.
5014 (lto_handle_option): Handle OPT_resolution.
5015 * lto-symtab.c (lto_symtab_merge_decl): Add a resolution argument.
5016 (lto_symtab_merge_var,lto_symtab_merge_fn): Add a resolution argument.
5017 pass it to lto_symtab_merge_decl.
5018 * lto.c: Include common.h.
5019 (lto_read_decls): Add resolutions and resolutions_size arguments.
5020 Initialize data_in.globals_resolution and
5021 data_in.globals_resolution_size.
5022 (index_and_symbol_resolution): New.
5023 (lto_resolution_read): New.
5024 (lto_file_read): Add argument resolution_file.
5026 * lto.h (resolution_file_name): New.
5028 2008-09-23 Rafael Espindola <espindola@google.com>
5030 * common.c: Update description.
5031 * common.h: Update description.
5033 2008-09-23 Rafael Espindola <espindola@google.com>
5035 * common.c: Moved from lto-plugin.
5036 * common.h: Moved from lto-plugin.
5038 2008-09-22 Doug Kwan <dougkwan@google.com>
5040 * lto.c (VEC(bitmap,heap)): Declare.
5041 (lto_materialize_function): Handle WAP mode specially.
5042 (lto_add_inline_clones): New.
5043 (lto_add_all_inlinees): Changle algorithm and to use bitmaps. Also
5044 return a bitmap of inlined decls.
5045 (lto_wpa_write_files): Handle all DECLs brought in by inlining.
5046 (lto_main): Call reset_inline_failed to reset inlining states.
5047 Check call-graph after WPA inlining.
5048 * lto-lang.c (lto_init): Do not clear flag_generate_lto
5051 2008-09-19 Doug Kwan <dougkwan@google.com>
5053 lto.c (lto_main): Remove unsued wrapper code.
5054 lang-specs.h (@lto): Use lto1_options instead of cc1_options.
5056 2008-09-19 Rafael Espindola <espindola@google.com>
5058 * lto-symtab.c: Include lto-tree-in.h.
5059 * lto-tree.h (lto_symtab_merge_var, lto_symtab_merge_fn): Remove.
5060 * lto.h (lto_symtab_merge_var, lto_symtab_merge_fn): Remove
5061 * Make-lang.in (lto/lto-symtab.o): Add lto-tree-in.h.
5063 2008-09-17 Paolo Bonzini <bonzini@gnu.org>
5064 Rafael Avila de Espindola <espindola@google.com>
5066 * lto-lang.c (COMPOUND_LITERAL_EXPR_DECL_STMT,
5067 COMPOUND_LITERAL_EXPR_DECL): Remove.
5068 (emit_local_var): Remove.
5069 (lto_expand_expr): Remove.
5070 (lto_staticp): Remove.
5071 (LANG_HOOKS_EXPAND_EXPR): Remove.
5072 (LANG_HOOKS_STATICP): Remove.
5074 2008-09-11 Diego Novillo <dnovillo@google.com>
5076 * lto-lang.c: Include except.h and libfuncs.h.
5078 (lto_init): Call it.
5079 Set flag_generate_lto to 0.
5080 * Make-lang.in (lto-lang.o): Add dependency on except.h
5083 2008-09-09 Bill Maddox <maddox@google.com>
5085 * lto-lang.c: Include header file expr.h.
5086 (COMPOUND_LITERAL_EXPR_DECL_STMT,
5087 COMPOUND_LITERAL_EXPR_DECL): Copied from c-common.h.
5088 (emit_local_var): Copied from c-semantics.c.
5089 (lto_expand_expr, lto_staticp): Copied from c_expand_expr
5090 and c_staticp in c-common.c.
5091 (LANG_HOOKS_EXPAND_EXPR,LANG_HOOKS_STATICP): Redefined.
5093 2008-09-08 Diego Novillo <dnovillo@google.com>
5095 * lto-lang.c (lto_global_bindings_p): Return 1 during
5098 2008-09-07 Diego Novillo <dnovillo@google.com>
5100 * lto.c: Tidy formatting.
5102 2008-08-04 Bill Maddox <maddox@google.com>
5104 * lto-symtab.c (lto_symtab_merge_decl): Add comment.
5106 2008-09-03 Doug Kwan <dougkwan@google.com>
5108 lto.c (lto_add_all_inlinees): Reset FAILED_REASON of edges to
5109 CIF_OK instead of NULL.
5111 2008-09-02 Diego Novillo <dnovillo@google.com>
5112 Simon Baldwin <simonb@google.com>
5114 * lto-lang.c (lto_type_for_size): Rewrite. Adapt from
5115 c_common_type_for_size.
5116 (lto_type_for_mode): Remove ATTRIBUTE_UNUSED markers.
5117 (lto_init): Call linemap_add.
5118 (signed_and_unsigned_types): Remove.
5120 2008-08-29 Diego Novillo <dnovillo@google.com>
5122 * lto-lang.c (handle_noreturn_attribute): New local function.
5123 (handle_const_attribute): New local function.
5124 (handle_malloc_attribute): New local function.
5125 (handle_pure_attribute): New local function.
5126 (handle_novops_attribute): New local function.
5127 (handle_nonnull_attribute): New local function.
5128 (handle_nothrow_attribute): New local function.
5129 (handle_sentinel_attribute): New local function.
5130 (handle_type_generic_attribute): New local function.
5131 (handle_format_attribute): New local function.
5132 (handle_format_arg_attribute): New local function.
5133 (lto_attribute_table): Declare.
5134 (lto_format_attribute_table): Declare.
5135 (lto_init_attributes): New local function.
5136 (lto_define_builtins): Call it.
5137 Call targetm.init_builtins and build_common_builtin_nodes.
5138 (LANG_HOOKS_COMMON_ATTRIBUTE_TABLE): Define.
5139 (LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE): Define.
5141 2008-08-28 Diego Novillo <dnovillo@google.com>
5143 * Make-lang.in (lto-lang.o): Replace tree-gimple.h with
5145 (lto-symtab.o): Add dependency on $(GIMPLE_H).
5146 * lto-lang.c: Include gimple.h instead of tree-gimple.h.
5147 * lto-symtab.c: Include gimple.h.
5148 * lto-tree.h (chain_next): Replace GENERIC_NEXT with
5151 2008-08-27 Doug Kwan <dougkwan@google.com>
5153 * lto.c (vec.h, bitmap.h, pointer-set.h, ipa-prop.h, ggc.h,
5154 gt-lto-lto.h): New includes.
5155 (lto_materialize_function): Do not read in function body in WPA mode.
5156 Format a line to fit in 80 columns.
5157 (lto_cgraph_node_sets): New garbage collected variable.
5158 (lto_1_to_1_map, lto_add_all_inlinees, lto_wpa_write_files):
5160 (lto_main): Initialize bitmap obstack. Add code to handle WPA mode.
5161 * Make-lang.in (LTO_H): Replace filename lto-section-in.h with
5162 variable LTO_SECTION_IN_H.
5163 (lto/lto.o): Include gt-lto-lto-c.h ggc.h ,VEC_H, BITMAP_H,
5164 pointer-set.h and IPA_PROP_H. Also replace filename lto-section-in.h
5165 with variable LTO_SECTION_IN_H.
5166 * config-lang.in (gtfiles): Add lto/lto.c.
5167 * lto-symtab.c (lto_symtab_merge_decl): Set DECL_CONTEXT of
5168 merged DECL_RESULT correctly.
5170 2008-08-26 Bill Maddox <maddox@google.com>
5172 * lto-lang.c Include tree-gimple.h.
5173 (lto_mark_addressable): Call mark_addressable rather than
5175 (lto_post_options): Suppress debug info generation.
5176 * Make-lang.in: Add dependency of lto-lang.o on tree-gimple.h.
5178 2008-08-25 Bill Maddox <maddox@google.com>
5180 * lto-symtab.c (lto_symtab_merge_decl): Remove a suspect
5181 assertion and leave an explanatory comment in its place.
5183 2008-08-21 Doug Kwan <dougkwan@google.com>
5185 * lto.c (preload_common_nodes): Call lto_get_common_nodes to get a list
5186 of common nodes instead of computing locallly.
5187 (lto_read_in_decl_state): New.
5188 (lto_read_decls): Change code for udpate in struct lto_decl_header.
5189 Read global and per-function in-decl states.
5190 * Make-lang.in (LTO_H): Update dependency.
5192 (lto-symtab.c): Merge (revision 139039)
5193 * lto-symtab.c (lto_symtab_merge_decl): Merge DECL_RESULT.
5195 2008-08-21 Rafael Espindola <espindola@google.com>
5197 * config-lang.in (target_libs): New.
5199 2008-08-20 Bill Maddox <maddox@google.com>
5201 * lto.c (current_lto_file): Remove GTY marker from static
5202 variable. Remove include of file gt-lto-lto.h.
5203 * Make-lang.in: Remove dependency of lto/lto.o on
5205 * lto-elf.c (lto_file_close): Removed.
5206 (lto_elf_file_open): Use XCNEW instead of GGC_CNEW to
5207 allocate lto_elf_file object.
5208 (lto_elf_file_close): Free lto_elf_file object after close.
5209 * lto.h (struct lto_file_struct): Remove GTY marker.
5210 * config-lang.in: Remove lto/lto.h and lto/lto.c from
5213 2008-08-20 Bill Maddox <maddox@google.com>
5215 * lto.c (lto_read_decls): Provide dummy argument to input_tree
5216 to conform to its new signature.
5217 * lto-symtab.c (lto_symtab_merge_decl): Do not invoke ggc_free
5218 on discarded node here, now called in global_vector_fixup.
5220 2008-08-09 Bill Maddox <maddox@google.com>
5222 * lto.c (preload_common_nodes): Verify that fileptr_type_node
5223 has not been set to a front-end-specific value.
5225 2008-08-05 Doug Kwan <dougkwan@google.com>
5227 * Make-lang.in (lto-symtab.o): Add missing dependencies to fix
5230 2008-07-30 Bill Maddox <maddox@google.com>
5232 * lto.c (lto_materialize_function): Call lto_original_decl_name.
5233 Remove obsolete comments.
5234 (lto_read_decls): Remove initialization of deleted field data_in.global.
5236 (lto_main): Remove redundant initialization of section_hash_table.
5237 * lto-elf.c: Removed obsolete comments.
5238 * lto.h: Tidy up comments.
5239 * lto-symtab.c (lto_least_common_multiple): New function.
5240 (lto_symtab_merge_decl): Merge variable alignments in some cases.
5243 2008-07-25 Diego Novillo <dnovillo@google.com>
5244 Bill Maddox <maddox@google.com>
5246 * lto.c: Re-order include files.
5247 Include lto-section-out.h.
5248 (preload_common_nodes): Add debugging output.
5249 Add new local INDEX_TABLE.
5250 Call preload_common_node.
5251 * Make-lang.in (lto.o): Add dependency on lto-section-out.h
5253 2008-07-13 Bill Maddox <maddox@google.com>
5255 * lto.c (lto_read_decls): Cast pointer to const char * to avoid
5256 unwanted scaling during pointer addition.
5258 2008-07-11 Bill Maddox <maddox@google.com>
5259 Diego Novillo <dnovillo@google.com>
5261 * lto.c (lto_read_decls): Fix C++ compatibility warnings.
5262 Make code const-correct.
5263 (lto_file_read): Fix C++ compatibility warnings.
5264 (lto_read_section_data): Fix C++ compatibility warnings.
5265 (lto_get_section_data): Use CONST_CAST to avoid warning when
5266 const pointer passed to free.
5267 * lto-elf.c (lto_elf_build_section_table): Fix C++
5268 compatibility warnings.
5269 (lto_elf_append_data): Fix C++ compatibility warnings. Use CONST_CAST
5270 to avoid warning assigning const pointer to d_buf field of Elf_Data.
5271 (lto_get_current_out_file): Fix C++ compatibility warnings.
5273 2008-07-11 Diego Novillo <dnovillo@google.com>
5275 * Make-lang.in (lto-warn): Define.
5277 2008-07-03 Simon Baldwin <simonb@google.com>
5279 * lto.c (lto_read_decls): Wrapped debug-only data items within #ifdef
5280 LTO_STREAM_DEBUGGING.
5282 2008-06-27 Ollie Wild <aaw@google.com>
5284 * lto-elf.c (lto-section-out.h): New include.
5285 (struct lto_elf_file): Remove bits member. Add scn, shstrtab_stream,
5287 (cached_file_attrs): New static variable.
5288 (lto_elf_get_shdr, lto_elf_free_shdr): Remove elf_file parameter.
5289 Use cached_file_attrs for checking bits.
5290 (lto_elf_build_section_table): Remove elf_file argument from
5291 lto_elf_get_shdr and lto_elf_free_shdr calls.
5292 (DEFINE_INIT_SHDR): New macro.
5293 (init_shdr32, init_shdr64): New functions defined via the
5294 DEFINE_INIT_SHDR macro.
5295 (lto_elf_begin_section_with_type): New function.
5296 (lto_elf_begin_section): New function.
5297 (lto_elf_append_data): New function.
5298 (lto_elf_end_section): New function.
5299 (DEFINE_VALIDATE_EHDR): New macro.
5300 (validate_ehdr32, validate_ehdr64): New functions defined via the
5301 DEFINE_VALIDATE_EHDR macro.
5302 (validate_file): New function.
5303 (DEFINE_INIT_EHDR): New macro.
5304 (init_ehdr32, init_ehdr64): New functions defined via the
5305 DEFINE_INIT_EHDR macro.
5306 (init_ehdr): New function.
5307 (lto_elf_file_open): Add support for writable files. Move some
5308 validation logic to validate_file.
5309 (lto_elf_file_close): Add support for writable files. Write file data
5310 and free data blocks.
5311 (current_out_file): New static variable.
5312 (lto_set_current_out_file): New function.
5313 (lto_get_current_out_file): New function.
5314 * lto.c (lto_main): Add writable argument to lto_elf_file_open calls.
5315 Add temporary initialization for testing ELF serialization.
5316 * lto.h (lto-section-out.h): New include.
5317 (struct lto_file_struct): Slight modification to comment.
5318 (lto_elf_file_open): Add writable parameter.
5319 (lto_elf_begin_section): New function declaration.
5320 (lto_elf_append_data): New function declaration.
5321 (lto_elf_end_section): New function declaration.
5322 (lto_set_current_out_file, lto_get_current_out_file): New function
5324 * lto-lang.c (LANG_HOOKS_BEGIN_SECTION): Set as lto_elf_begin_section.
5325 (LANG_HOOKS_APPEND_DATA): Set as lto_elf_append_data.
5326 (LANG_HOOKS_END_SECTION): Set as lto_elf_end_section.
5327 * Make-lang.in (LTO_H): Add lto-section-out.h.
5329 2008-06-12 Ollie Wild <aaw@google.com>
5331 * lto.h (struct lto_file_vtable_struct): Remove.
5332 (struct lto_file_struct): Remove vtable member.
5333 * lto-elf.c (lto_file_init): Remove vtable argument.
5334 (lto_elf_map_optional_lto_section): Remove.
5335 (lto_elf_unmap_section): Remove.
5336 (lto_elf_file_vtable): Remove.
5337 (lto_elf_file_open): Remove lto_elf_file_vtable argument from
5339 (lto_elf_find_section_data): Remove.
5341 2008-06-11 Ollie Wild <aaw@google.com>
5343 * lto.c (lto_file_read): Add const qualifier to data variable.
5345 2008-06-11 Diego Novillo <dnovillo@google.com>
5347 Merge from lto-streamber sub-branch.
5349 2008-06-04 Ollie Wild <aaw@google.com>
5351 * lto.c: Remove inclusion of dwarf2.h and dwarf2out.h.
5352 * Make-lang.in (lto.o): Remove dependency on dwarf2.h.
5354 2008-05-28 Bill Maddox <maddox@google.com>
5356 Replace the DWARF reader in the LTO front-end.
5358 * lto.c: Include lto-tree-in.h, lto-tags.h.
5359 (enum DWARF2_class, DW_cl_constant, struct
5360 DWARF2_form_data, struct lto_context,
5361 lto_fd_init, lto_info_fd_init,
5362 lto_abbrev_fd_init, lto_info_fd_close,
5363 lto_file_init, lto_file_close,
5364 lto_file_corrupt_error, lto_abi_mismatch_error,
5365 LTO_CHECK_INT_VAL, LTO_READ_TYPE,
5366 lto_read_uleb128, lto_read_sleb128,
5367 lto_read_initial_length, lto_abbrev_read_attrs,
5368 lto_abbrev_read, lto_abbrev_read_lookup,
5369 lto_read_section_offset,
5370 lto_read_comp_unit_header, find_cu_for_offset,
5372 lto_resolve_reference,lto_read_form,
5373 attribute_value_as_int,
5374 make_signed_host_wide_int,
5375 attribute_value_as_constant, lto_cache_hash,
5376 lto_cache_eq, lto_cache_store_DIE,
5377 lto_cache_lookup_DIE, lto_find_integral_type,
5378 lto_find_integral_type_1,
5379 LTO_BEGIN_READ_ATTRS_UNCHECKED,
5380 LTO_BEGIN_READ_ATTRS, LTO_END_READ_ATTRS,
5381 lto_unsupported_attr_error, lto_get_identifier,
5382 lto_read_referenced_type_DIE,
5383 lto_read_compile_unit_DIE,
5384 lto_read_array_type_DIE,
5385 lto_read_structure_union_class_type_DIE,
5386 lto_read_enumerator_DIE,
5387 lto_read_enumeration_type_DIE,
5388 lto_read_only_for_child_DIEs,
5389 lto_read_only_for_child_DIEs,
5390 lto_read_member_DIE, lto_read_abbrev,
5391 lto_read_variable_formal_parameter_constant_DIE,
5392 lto_get_body): Removed.
5393 (preload_common_nodes): New function.
5394 (lto_read_decls): Convert for new global streamer.
5395 (lto_materialze_file_data,
5396 lto_read_subroutine_type_subprogram_die,
5397 lto_read_unspecified_parameters_DIE,
5398 lto_read_typedef_DIE,
5399 lto_read_pointer_reference_type_DIE,
5400 lto_read_subrange_type_DIE,
5401 lto_read_base_type_DIE,
5402 lto_read_const_volatile_restrict_type_DIE,
5403 lto_read_namespace_DIE,
5404 lto_read_unspecified_type_DIE, lto_read_DIE,
5405 lto_read_child_DIEs, lto_collect_child_DIEs):
5407 (lto_info_read, lto_set_cu_context): Removed.
5408 (lto_file_read): Convert for new global streamer.
5409 (lto_resolve_type_ref, lto_read_DIE_at_ptr,
5410 lto_resolve_var_ref, lto_resolve_fn_ref,
5411 lto_resolve_field_ref, lto_resolve_typedecl_ref,
5412 lto_resolve_namespacedecl_ref): Removed.
5413 (lto_file_init, lto_file_close): Moved to lto-elf.c.
5414 * lto-tree.h (lto_symtab_merge_var,
5415 lto_symtab_mergee_fun): Declare here.
5416 * lto-elf.c (lto_file_init, lto_file_close): Moved from lto.c.
5417 (lto_elf_file_open): Removed code to read DWARF debug sections.
5418 * lto.h (lto_context, DWARF2_attr, DWARF2_abbrev,
5419 DWARF2_CompUnit, lto_die_ptr,
5420 lto_die_cache_entry, lto_fd, lto_info_fd,
5421 lto_abbrev_fd): Removed.
5422 (lto_file): Removed debug_info and debug_abbrev fields.
5424 (lto_file_init, lto_file_close,
5425 lto_resolve_type_ref, lto_resolve_var_ref,
5426 lto_resolve_fn_ref, lto_resolve_field_ref,
5427 lto_resolve_typedecl_ref,
5428 lto_resolve_namespacedecl_ref,
5429 lto_get_file_name): Removed declarations.
5430 (lto_symtab_merge_var, lto_symtab_merge_fn):
5431 Declarations moved to lto-tree.h.
5432 * lto-symtab.c (lto_compatible_attributes_p):
5433 Lobotomize this, as it barfs on "Hello, world!".
5434 * lto-section-out.c: Include lto-tree-out.h.
5435 (lto_hash_global_slot_node,
5436 lto_eq_global_slot_node, preload_common_nodes,
5437 write_global_stream, write_global_references):
5439 (produce_asm_for_decls): Convert for new global streamer.
5440 * lto-section-out.h (lto_hash_global_slot_node,
5441 lto_eq_global_slot_node): Declare.
5443 2008-06-07 Kenneth Zadeck <zadeck@naturalbridge.com>
5444 Jan Hubicka <jh@suse.cz>
5446 * lto.c (sys/mman.h, tree-pass.h): New includes.
5447 (lto_materialize_constructors_and_inits,
5448 lto_materialize_function): Keeps length of section.
5449 (lto_materialize_cgraph): Removed.
5450 (lto_read_decls): Initialize fd field.
5451 (lto_file_read): Different return type and removed much code to
5453 (page_mask): New variable.
5454 (lto_read_section_data, get_section_data, free_section_data): New
5456 (lto_main): Now calls pass manager, sets the hooks so that the ipa
5457 passes can get the section data.
5459 2008-05-27 Kenneth Zadeck <zadeck@naturalbridge.com>
5461 * lto.h (lto_read_decls): Made local.
5462 (lto_input_function_body, lto_input_constructors_and_inits,
5463 lto_input_cgraph): Declarations moved to lto-section-in.h.
5464 * lto-section-in.c: Moved to .. .
5465 * lto-cgraph-in.c: Ditto.
5466 * lto-section-in.h: Ditto.
5467 * lto-function-in.c: Ditto.
5468 * lto-lang.c (lto_handle_option): Added ATTRIBUTE_UNUSED to parms.
5469 (lto_insert_block): Removed.
5470 (LANG_HOOKS_INSERT_BLOCK): Removed.
5471 * Make-lang.in (lto-cgraph-in.o, lto-function-in.o,
5472 lto-section-in.o): Rules moved to lto/Makefile.in.
5475 2008-05-16 Ollie Wild <aaw@google.com>
5477 * lto-lang.c (tree-inline.h): Include.
5478 (lto_post_options): New function.
5479 (LANG_HOOKS_POST_OPTIONS): Define.
5480 * lto-cgraph-in.c (overwrite_node): Set node->global.insns.
5481 * lto-function-in.c (input_bb): Set TREE_BLOCK (stmt).
5483 2008-05-13 Diego Novillo <dnovillo@google.com>
5485 * lto-function-in.c (input_ssa_names): Call
5486 make_ssa_name_fn instead of make_ssa_name.
5488 2008-05-12 Diego Novillo <dnovillo@google.com>
5490 * lto-cgraph-in.c (overwrite_node): Update references to
5491 inline summary fields.
5492 * lto-function-in.c (input_expr_operand): Do not handle
5495 2008-05-09 Ollie Wild <aaw@google.com>
5497 * lang.opt: New file.
5498 * lto-lang.c (lto_init_options): New function.
5499 (lto_handle_option): New function.
5500 (lto_init): Move initialization of flag_unit_at_a_time to
5502 (LANG_HOOKS_INIT_OPTIONS): Define.
5503 (LANG_HOOKS_HANDLE_OPTION): Define.
5505 2008-04-29 Ollie Wild <aaw@google.com>
5507 * lto.c (lto_read_namespace_DIE): New function.
5508 (lto_read_DIE): Add lto_read_namespace_DIE callback. Cache
5509 NAMESPACE_DECL DIE's.
5510 (lto_resolve_namespacedecl_ref): New function.
5511 * lto.h (lto_resolve_namespacedecl_ref): New function.
5512 * lto-section-in.c (lto_read_decls): Read namespace declarations.
5513 * lto-section-in.h (struct lto_file_decl_data): Add namespace_decls
5514 and num_namespace_decls.
5515 * lto-function-in.c (input_expr_operand): Add NAMESPACE_DECL case.
5516 * lto-lang.c (lto_init_ts): New function.
5517 (LANG_HOOKS_INIT_TS): Set as lto_init_ts.
5519 2008-04-16 Ollie Wild <aaw@google.com>
5521 * lto-function-in.c (input_type_ref): Updated function description.
5523 2008-04-16 Ollie Wild <aaw@google.com>
5525 * lto-function-in.c (input_type_ref_1): New function.
5526 (input_type_ref): Split into two functions.
5527 (input_function): Add support for type contexts.
5529 2008-04-16 Ollie Wild <aaw@google.com>
5531 * lto.c (lto_materialize_function): Use DECL_ASSEMBLER_NAME to compute
5534 2008-04-16 Ollie Wild <aaw@google.com>
5536 * lto.c (lto_read_compile_unit_DIE): Add DW_LANG_C_plus_plus to the
5537 list of supported languages.
5539 2008-03-25 Kenneth Zadeck <zadeck@naturalbridge.com>
5541 Merge with mainline @133491.
5543 2008-03-05 Kenneth Zadeck <zadeck@naturalbridge.com>
5544 Jan Hubicka <jh@suse.cz>
5546 * lto.c (lto_info_fd_init, lto_info_fd_close): Get rid of
5547 fd->unmaterialized_fndecls.
5548 (lto_get_file_name, lto_materialize_cgraph): New function.
5549 (lto_materialize_constructors_and_inits,
5550 lto_materialize_function): Read info directly from elf file.
5551 (lto_file_read): Made local and initialize dictionary so that
5552 other lto sections can be read without reprocessing the elf file.
5553 (lto_main): Read all functions after all files have been processed
5554 for their types, globals and cgraph.
5555 * Make-lang.in (lto.o, lto-cgraph-in.c, lto-section-in): Changed
5557 * lto-elf.c (lto_elf_file): Removed strtab, symtab fields.
5558 (hash_name, eq_name, lto_elf_build_section_table): New functions.
5559 (lto_elf_read_symtab): Removed function.
5560 (lto_elf_file_open): Removed call to lto_elf_read_symtab.
5561 * lto.h (lto_info_fd_struct): Removed unmaterialized_fndecls.
5562 (lto_file_read): Made local.
5563 (lto_get_file_name, lto_elf_build_section_table,
5566 * lto-section-in.c (lto_read_section_data, lto_get_section_data):
5568 (lto_read_decls): Get the file name.
5569 * lto-cgraph-in.c: New file.
5570 * lto-function-in.c (tag_to_expr): Stops at LTO_tree_last_tag.
5571 (input_expr_operand, lto_read_body): Set lto_debug_context.tag_names.
5572 (input_labels): Fixed latent sizeof issue.
5573 (input_function): Build stmt array to set call sites into cgraph
5575 (lto_read_body): Reset cfun->curr_properties.
5576 * lto_section_in.h (lto_section_slot): New structure.
5577 (section_hash_table.lto_file_decl_data): New field.
5579 2008-02-09 Kenneth Zadeck <zadeck@naturalbridge.com>
5581 * lto.c (lto_read_variable_formal_parameter_const): Remove code to
5582 reconstruct static initializers.
5583 (lto_get_body, lto_materialize_function): Add lto_section_type as
5585 (lto_materialize_constructors_and_inits,
5586 lto_materialize_file_data): New function.
5587 (lto_materialize_function,
5588 lto_read_subroutine_type_subprogram_DIE): Renamed unmap_fn_body to
5589 unmap_section and map_fn_body to map_section.
5590 (lto_set_cu_context): Process functions and static inits
5592 * Make-lang.in (LTO_H, lto/lto-function-in.o,
5593 lto/lto-section-in.o): Update dependencies.
5594 * lto-elf.c (lto_elf_map_optional_lto_section): Add
5595 lto_section_type parameter.
5596 (lto_elf_unmap_fn_body): Renamed to lto_elf_unmap_section.
5597 * lto.h (lto_file_vtable_struct): Removed two of the fields and
5598 renamed the other two so that there is only one map function and
5599 one unmap function and each takes a section type parameter.
5600 (lto_read_function_body): Renamed to lto_input_function_body and
5601 added file_data parameter.
5602 (lto_read_var_init): Removed.
5603 (lto_input_constructors_and_inits): New function.
5604 * lto-section-in.c (lto_read_decls): New function.
5605 * lto-function-in.c (data_in): Moved fields field_decls, fn_decls,
5606 var_decls, type_decls, types to lto_file_decl_data.
5607 (input_type_ref, input_expr_operand, lto_read_body): Get
5608 field_decls, fn_decls, var_decls, type_decls, types from different
5610 (input_globals, input_constructor, lto_read_var_init): Removed.
5611 (input_constructors_or_inits): New function.
5612 (lto_read_function_body, lto_input_constructors_and_inits):
5613 Renamed to lto_input_function_body and takes file_data parameter.
5614 * lto-section-in.h (lto_file_decl_data): New structure.
5616 2008-01-28 Kenneth Zadeck <zadeck@naturalbridge.com>
5618 * lto-function-in.c (input_globals.c): Changed input type to
5619 lto_function_header.
5620 (input_bb): Removed code to deserialize the stmt number.
5621 (input_function): Renumber all stmts after they are input.
5622 (lto_read_body, lto_read_function_body, lto_read_var_init):
5623 Changed to used new header format and enum section_type.
5624 *lto-lang.c (success): Removed.
5626 2008-01-28 Nathan Froyd <froydnj@codesourcery.com>
5628 * lto-elf.c (lto_elf_lookup_sym): Remove unused function.
5629 (lto_elf_free_sym): Likewise.
5631 * lto-elf.c (lto_elf_read_var_init): Remove unused function.
5632 (lto_elf_build_init): Likewise.
5634 2008-01-14 Kenneth Zadeck <zadeck@naturalbridge.com>
5636 * lto-read.c: Renamed to lto-function-in.c.
5637 (input_1_unsigned): Moved to lto-section-in.c and renamed
5638 lto_input_1_unsigned.
5639 (input_uleb128): Moved to lto-section-in.c and renamed
5641 (input_widest_uint_uleb128): Moved to lto-section-in.c and renamed
5642 lto_input_widest_uint_uleb128.
5643 (input_sleb128): Moved to lto-section-in.c and renamed
5645 (input_integer): Moved to lto-section-in.c and renamed
5647 (debug_in_fun): Moved to lto-section-in.c and renamed
5649 (input_block): Moved to lto-section-in.h and renamed
5651 (input_expr_operand): Fixed to allow lists with more than one
5653 * lto-section-in.h: New file.
5654 * lto-section-in.c: New file with changes from above.
5655 * Make-lang.in (lto-read.o): Renamed lto-function-in.c.
5656 (lto-section-in.o): New rule.
5658 2007-12-29 Nathan Froyd <froydnj@codesourcery.com>
5660 * lto-read.c (input_expr_operand): Mark static and external
5661 VAR_DECLs as needed.
5663 2007-12-29 Nathan Froyd <froydnj@codesourcery.com>
5665 * lto-read.c (input_integer): Use the correct shift amount.
5667 2007-12-29 Nathan Froyd <froydnj@codesourcery.com>
5669 * lto-lang.c (lto_pushdecl): Do nothing instead of aborting.
5670 (LANG_HOOKS_NAME): Define.
5672 2007-12-27 Nathan Froyd <froydnj@codesourcery.com>
5674 * lto.c (lto_find_integral_type): Define as a macro. Rename the
5675 original function to...
5676 (lto_find_integral_type_1): ...this. Consult UNSIGNEDP if we
5677 don't have a base type.
5678 (lto_read_enumeration_type_DIE): Examine the values of the
5679 enumeration to determine whether we can use an unsigned type for
5680 the base type of the enumeration.
5682 2007-12-24 Nathan Froyd <froydnj@codesourcery.com>
5684 * lto.c (lto_read_structure_union_class_type_DIE): Set TYPE_MODE
5685 and TYPE_ALIGN on UNION_TYPEs as soon as possible.
5687 2007-12-22 Nathan Froyd <froydnj@codesourcery.com>
5689 * lto-lang.c (lto_types_compatible_p): New function.
5690 (LANG_HOOKS_TYPES_COMPATIBLE_P): Define.
5692 2007-12-22 Nathan Froyd <froydnj@codesourcery.com>
5693 Kenneth Zadeck <zadeck@naturalbridge.com>
5695 * lto-read.c (input_expr_operand): Fixed uninitialize var warning.
5696 (input_local_vars): Read in DECL_INITIAL and context for local
5697 statics that need to be put in unexpanded_vars_list.
5699 2007-12-21 Nathan Froyd <froydnj@codesourcery.com>
5701 * lto-read.c (input_real): Use a separate null-terminated buffer
5702 for calling real_from_string.
5703 (input_expr_operand): If we take the address of a FUNCTION_DECL,
5704 tell cgraph that it's needed.
5706 2007-12-19 Doug Kwan <dougkwan@google.com>
5708 * lto.c (lto_read_base_type_DIE): Handle complex integer types.
5710 2007-12-18 Nathan Froyd <froydnj@codesourcery.com>
5712 * lto.c (lto_read_DIE): Call lto_read_only_for_child_DIEs instead.
5713 (lto_file_read): Reset the members of 'context' every time we read
5714 a toplevel DIE, with special attention to last_param_type.
5716 2007-12-18 Nathan Froyd <froydnj@codesourcery.com>
5718 * lto.c (lto_read_subroutine_type_subprogram_DIE): Initialize
5719 'declaration'. Set the assembler name for non-public functions.
5721 2007-12-17 Kenneth Zadeck <zadeck@naturalbridge.com>
5723 * lto_read.c (data_in.unexpanded_indexes): New array.
5724 (input_local_var): Added code to read in unexpanded_var_list
5725 indexes for variables. Only read in DECL_CHAIN field for
5727 (input_local_vars): Added code to rebuild unexpanded_var_list in
5728 order using unexpanded_indexes.
5729 (input_function): Added code to set DECL_CONTEXT for functions.
5731 2007-12-13 Doug Kwan <dougkwan@google.com>
5733 * lto.c (lto_read_pointer_reference_type_DIE): Handle optional name
5734 in pointer and reference types.
5736 2007-12-13 Nathan Froyd <froydnj@codesourcery.com>
5738 * lto-read.c (input_expr_operand): Use DECL_RESULT when reading a
5741 2007-12-13 Nathan Froyd <froydnj@codesourcery.com>
5743 * lto.c (lto_read_array_type_DIE): Return the cached DIE if we've
5744 already read the DIE.
5745 (lto_get_body): New function, split out from...
5746 (lto_materialize_function): ...here. Call it.
5747 (lto_read_subroutine_type_subprogram_DIE): Call lto_get_body to
5748 determine DECL_EXTERNAL.
5749 * lto-symtab.c (lto_symtab_merge_decl): Merge the DECL_RESULTs of
5750 FUNCTION_DECLs when necessary. Use the type of the actual
5751 function definition if we are unable to easily merge types. Ignore
5752 spurious DECL_MODE mismatches on VAR_DECLs. Merge DECL_MODEs when
5755 2007-12-13 Nathan Froyd <froydnj@codesourcery.com>
5757 * lto-lang.c (LANG_HOOKS_REDUCE_BIT_FIELD_OPERATIONS): Define.
5759 2007-12-12 Bill Maddox <maddox@google.com>
5762 2007-12-07 Bill Maddox <maddox@google.com>
5764 * lto.c (lto_str_fd_init): New function.
5765 (lto_str_fd_close): New function.
5766 (lto_file_init): Call lto_str_fd_init.
5767 (lto_file_close): Call lto_str_fd_close.
5768 (lto_str_read): New function. Read debug string table.
5769 (lto_str_lookup): New function. Get string for debug
5770 string table offset.
5771 (lto_read_form): Recognize DW_FORM_strp.
5772 (lto_file_read): Invoke lto_str_read.
5774 * lto-elf.c (lto_elf_file_open): Read raw section data
5775 for the .debug_str section, if present.
5777 * lto.h (struct lto_str_fd_struct): New struct.
5778 (struct lto_file_struct): Added new field DEBUG_STR
5779 to hold the file descriptor for the debug string table.
5781 2007-12-07 Bill Maddox <maddox@google.com>
5783 * lto.c (lto_str_fd_init): New function.
5784 (lto_str_fd_close): New function.
5785 (lto_file_init): Call lto_str_fd_init.
5786 (lto_file_close): Call lto_str_fd_close.
5787 (lto_str_read): New function. Read debug string table.
5788 (lto_str_lookup): New function. Get string for debug
5789 string table offset.
5790 (lto_read_form): Recognize DW_FORM_strp.
5791 (lto_file_read): Invoke lto_str_read.
5793 * lto-elf.c (lto_elf_file_open): Read raw section data
5794 for the .debug_str section, if present.
5796 * lto.h (struct lto_str_fd_struct): New struct.
5797 (struct lto_file_struct): Added new field DEBUG_STR
5798 to hold the file descriptor for the debug string table.
5800 2007-12-07 Nathan Froyd <froydnj@codesourcery.com>
5802 * lto-read.c (input_cfg): Call init_empty_tree_cfg_for_function.
5803 Grow the basic_block_info and label_to_block_map vectors if
5804 necessary. Read in the block chain.
5806 2007-12-06 Nathan Froyd <froydnj@codesourcery.com>
5808 * lto.c (lto_read_DIE): Set TYPE_ALIAS_SET where necessary.
5810 2007-12-06 Nathan Froyd <froydnj@codesourcery.com>
5812 * lto.c (lto_read_form): Add DW_cl_address for DW_AT_const_value.
5814 2007-12-06 Nathan Froyd <froydnj@codesourcery.com>
5816 * lto-read.c (input_expr_operand): Don't check for MTAGs.
5817 (lto_read_body): Don't declare PROP_alias.
5819 2007-12-06 Nathan Froyd <froydnj@codesourcery.com>
5821 * lto-symtab.c (lto_symtab_merge_decl): Handle FUNCTION_DECLs without
5822 argument type information.
5824 2007-12-03 Nathan Froyd <froydnj@codesourcery.com>
5826 * lto.c (lto_read_variable_formal_parameter_constant_DIE): Set
5827 TREE_THIS_VOLATILE if the associated type is a volatile type.
5828 (lto_materialize_function): Remove call to init_ssa_operands.
5829 * lto-read.c (input_expr_operand): Add SSA_NAME_VAR as a referenced
5830 variable when reading an SSA_NAME. Do the same when reading a
5831 RESULT_DECL, a RETURN_EXPR, or an MTAG.
5832 (input_cfg): Call init_ssa_operands.
5833 (input_ssa_names): Set the default def of an SSA_NAME if necessary.
5834 Move call to init_tree_ssa...
5835 (lto_read_body): ...here. Use push_cfun and pop_cfun. Call
5836 add_referenced_var on any variables referenced from the body of the
5837 function. Inform the rest of the compiler we are in SSA form and
5838 inform later passes about the current properties.
5840 2007-11-30 Nathan Froyd <froydnj@codesourcery.com>
5842 * lto.c (lto_materialize_function): Add FIXME.
5844 2007-11-29 Nathan Froyd <froydnj@codesourcery.com>
5846 * lto-lang.c (enum built_in_attribute): New enum.
5847 (flag_no_builtin, flag_no_nonansi_builtin, flag_isoc94, flag_isoc99,
5848 built_in_attributes): New variables.
5849 (def_builtin_1): New function.
5850 (lto_define_builtins): #define DEF_BUILTIN and include builtins.def.
5852 2007-11-28 Nathan Froyd <froydnj@codesourcery.com>
5854 * lto.c (lto_read_variable_formal_parameter_constant_DIE): Set
5855 DECL_SOURCE_LOCATION for debugging purposes.
5856 (lto_read_member_DIE): Set DECL_SOURCE_LOCATION. If we have read a
5857 bitfield, use the type specified by the DIE for TREE_TYPE and defer
5858 laying out the decl until later.
5859 (lto_read_subroutine_type_subprogram_DIE): Compare the function's
5860 name with DECL_ASSEMBLER_NAME. Set DECL_SOURCE_LOCATION and
5862 * lto-read.c (input_expr_operand): Set TREE_ADDRESSABLE on the
5863 operand of an ADDR_EXPR.
5864 * lto-lang.c (enum lto_builtin_type): New enum.
5865 (builtin_type): New typedef.
5866 (builtin_types, string_type_node, const_string_type_node,
5867 wint_type_node, intmax_type_node, uintmax_type_node,
5868 signed_size_type_node): New variables.
5869 (def_fn_type, builtin_type_for_size, lto_define_builtins,
5870 lto_build_c_type_nodes): New functions.
5871 (lto_init): Initialize builtin types.
5872 (lto_set_decl_assembler_name): Let the target machine mangle the
5873 name if the decl is TREE_PUBLIC, otherwise uniquify it.
5875 2007-11-21 Nathan Froyd <froydnj@codesourcery.com>
5877 * lto.c (lto_read_variable_formal_parameter_constant_DIE): Don't
5878 set TREE_ADDRESSABLE. Do set DECL_COMDAT. Set TREE_READONLY if
5879 the type is a constant type. Set the assembler name and inform
5880 the rest of the compiler about the new decl if the decl is not
5882 (lto_read_subroutine_type_subprogram_DIE): Don't check for equivalency
5883 of DECL_ASSEMBLER_NAME when determining if we have a builtin. Don't
5884 try to read in function bodies for functions that already have bodies.
5885 * lto-symtab.c (lto_same_type_p): Check for unbounded array
5887 (lto_symtab_merge_decl): Don't merge decls that aren't TREE_PUBLIC.
5888 Check for whether we matched a builtin function type before calling
5889 lto_same_type_p on the generated type. Permit cases where the
5890 declaration of an array is unbounded, but the definition is bounded.
5891 Don't combine TREE_PUBLIC flags. Copy over DECL_SIZE and
5892 DECL_SIZE_UNIT if necessary.
5894 2007-11-16 Kenneth Zadeck <zadeck@naturalbridge.com>
5896 * lto-read.c (input_expr_operand): Get types right
5899 2007-11-16 Kenneth Zadeck <zadeck@naturalbridge.com>
5901 * lto-read.c (make_new_block, input_cfg): Properly set
5904 2007-11-16 Nathan Froyd <froydnj@codesourcery.com>
5906 * lto.c (lto_read_array_type_DIE): Handle DIEs with DW_AT_GNU_vector
5907 set properly by building a VECTOR_TYPE instead of an ARRAY_TYPE.
5909 2007-11-16 Nathan Froyd <froydnj@codesourcery.com>
5911 * lto.c (lto_read_base_type_DIE): Use make_bitfield_integer_type to
5912 construct the integer type for bitfields.
5914 2007-11-16 Kenneth Zadeck <zadeck@naturalbridge.com>
5916 * lto-read.c (data_in.current_node_has_loc): Removed.
5917 (input_line_info): Returns true if node needs line set.
5918 (set_line_info): Always sets line if called.
5919 (clear_line_info): Removed reference to current_node_needs_loc.
5920 (input_expr_operand): Keeps track locally if current node needs a loc.
5921 (input_local_var): Added code to handle DECL_INITIAL for
5922 static local vars. Only set loc if necessary.
5924 2007-11-15 Nathan Froyd <froydnj@codesourcery.com>
5926 * lto.c (lto_read_subroutine_type_subprogram_DIE): Fix thinko'd
5929 2007-11-15 Nathan Froyd <froydnj@codesourcery.com>
5931 * lto.c: Include langhooks.h.
5932 (lto_find_integral_type): Rework logic to handle the case where
5933 got_byte_size is true, but the bitsize requested and that of the
5934 base_type doesn't match.
5935 (lto_read_variable_formal_parameter_constant_DIE): Only check for
5936 asm_name if we are creating a VAR_DECL.
5937 (lto_materialize_function): Set DECL_EXTERNAL if we can't find a
5939 (lto_read_subroutine_type_subprogram_DIE): Check for a builtin
5940 function reference and use the builtin's decl if so. Set the
5941 DECL_CONTEXT of the RESULT_DECL for the function.
5942 * lto-lang.c (registered_builtin_fndecls): New variable.
5943 (lto_getdecls): Return it.
5944 (lto_builtin_function): Chain the new decl onto
5945 registered_builtin_fndecls.
5947 2007-11-15 Kenneth Zadeck <zadeck@naturalbridge.com>
5949 * lto-read.c (process_tree_flags, lto_static_init_local):
5950 Renamed to ADD_CLASS_EXPR_FLAG. ADD_CLASS_DECL_FLAG New Macro.
5951 (input_line_info, clear_line_info): Fixed new line number code.
5952 (input_expr_operand): Added type to SWITCH_EXPR.
5953 (lto_read_body): Properly initialized data_in.
5954 Clear line info when leaving.
5956 2007-11-13 Diego Novillo <dnovillo@google.com>
5958 * lto.c (lto_read_variable_formal_parameter_constant_DIE):
5959 Initialize ARTIFICIAL.
5960 (lto_read_subroutine_type_subprogram_DIE): Initialize
5962 * lto-read.c (set_line_info): Remove ; from calls to
5963 LINEMAP_POSITION_FOR_COLUMN.
5965 2007-11-13 Kenneth Zadeck <zadeck@naturalbridge.com>
5967 * lto-read.c (input_type_ref): Renamed from get_type_ref.
5968 (input_expr_operand, input_local_var): Renamed get_type_ref to
5970 (input_expr_operand): Get the types correct for
5971 vector-cst. Get SSA_NAME_DEF_STMT correct for return_exprs.
5973 2007-11-13 Doug Kwan <dougkwan@google.com>
5975 * lto-read.c (input_widest_uint_uleb128): New function.
5976 (input_tree_flags, process_tree_flags, input_line_info,
5977 input_expr_operand, input_local_var, input_phi, input_ssa_names):
5978 Change to use lto_flags_type and BITS_PER_LTO_FLAGS_TYPES instead of
5979 unsigned HOST_WIDE_INT and HOST_BITS_PER_WIDE_INT.
5980 (lto_static_init_local): Add code to assert that lto_flags_type is
5983 2007-11-13 Nathan Froyd <froydnj@codesourcery.com>
5985 * lto.c (lto_read_array_type_DIE): Handle DW_AT_GNU_vector.
5986 (lto_read_subroutine_type_subprogram_DIE): Handle
5987 DW_AT_static_link and DW_AT_specification. Return the
5988 specification if present.
5989 (lto_read_base_type_DIE): Handle DW_ATE_complex_float.
5991 2007-11-13 Nathan Froyd <froydnj@codesourcery.com>
5993 * lto-lang.c: Include target.h.
5994 (registered_builtin_types): New variable.
5995 (lto_type_for_mode): Increase number of modes handled.
5996 (lto_builtin_function): Fix argument list and return the decl.
5997 (lto_register_builtin_type): New function.
5998 (lto_init): Initialize target builtins and language-independent
6000 (LANG_HOOKS_REGISTER_BUILTIN_TYPE): Define.
6002 2007-11-13 Kenneth Zadeck <zadeck@naturalbridge.com>
6004 * lto-read.c (input_expr_operand): Added code to properly handle
6005 index filed. Added new RANGE_EXPR case.
6007 2007-11-11 Kenneth Zadeck <zadeck@naturalbridge.com>
6009 * lto-read.c (ADD_FUNC_FLAG): Deleted macro.
6010 (data_in): Added current_node_has_loc field.
6011 (input_line_info, set_line_info, clear_line_info): Added a support
6012 for USE_MAPPED_LOCATION and not adding line numbers to nodes that
6013 did not have on on the source side.
6014 (input_expr_operand): Make sure that GIMPLE_MODIFY_STMTS get line
6017 2007-11-09 Doug Kwan <dougkwan@google.com>
6019 * lto-read.c (input_expr_operand): Change type of operand 2 of
6020 BIT_FIELD_REF expression to be bitsizetype instead of sizetype.
6022 2007-11-09 Nathan Froyd <froydnj@codesourcery.com>
6024 * lto.c: Include lto-tree.h. Effect small spaces->tabs cleanup.
6025 (lto_read_variable_formal_parameter_constant_DIE): Transfer bits
6026 from a DW_AT_specification or DW_AT_abstract_origin attribute to
6027 the new decl we are creating. Move informing the middle end about
6029 (lto_main): ...here. Inform the middle end about global variables
6030 after we have read in all the input files.
6031 * lto-symtab.c (lto_symtab_merge_decl): We really do need to merge
6032 variables with internal linkage, so delete the check for internal
6033 linkage. Combine TREE_PUBLIC flags.
6035 2007-11-08 Nathan Froyd <froydnj@codesourcery.com>
6037 * lto.c (lto_read_subroutine_type_subprogram_DIE): Handle
6039 * lto-symtab.c (lto_symtab_merge_decl): Handle redefinition of a
6040 builtin specially. Move check for attribute compatibility
6043 2007-11-07 Nathan Froyd <froydnj@codesourcery.com>
6045 * Make-lang.in (lto/lto.o): Depend on gt-lto-lto.h.
6046 * config-lang.in (gtfiles): Add lto.h and lto.c.
6047 * lto-elf.c: Include ggc.h.
6048 (lto_elf_file_open): Allocate elf_file from GC memory.
6049 * lto.c: Include tree-ssa-operands.h and gt-lto-lto.h
6050 (lto_info_fd_init): Allocate the die_cache and unmaterialized_fndecls
6052 (lto_info_fd_close): Free unmaterialized_fndecls from GC memory.
6053 (lto_file_close): Free file from GC memory.
6054 (lto_cache_store_DIE): Allocate the new entry in GC memory.
6055 (lto_read_member_DIE): Fix declaration.
6056 (lto_read_subroutine_type_subprogram_DIE): unmaterialized_fndecls lives
6058 (current_lto_file): New variable.
6060 (DWARF2_attr, DWARF2_abbrev, lto_die_ptr, DWARF2_CompUnit,
6061 lto_die_cache_entry): Move to...
6062 * lto.h: ...here and add GTY markers as appropriate. Delete forward
6063 declarations accordingly.
6064 (struct lto_file_struct): Declare.
6065 (lto_file_vtable): Use it instead of lto_file.
6067 2007-11-06 Alon Dayan <alond@il.ibm.com>
6068 Kenneth Zadeck <zadeck@naturalbridge.com>
6070 * lto-read.c (process_flags, lto_static_init_local):
6071 read flags of VAR_DECL and FUNCTION_DECL of size>1.
6072 change global array num_flags_for_code to flags_length_for_code.
6073 (set_line_info): Make decls work in USE_MAPPED_LOCATION mode.
6075 2007-11-05 Nathan Froyd <froydnj@codesourcery.com>
6077 * lto.c (lto_read_structure_union_class_type_DIE): Use proper record
6078 layout functions to compute information about the newly constructed
6081 2007-11-02 Nathan Froyd <froydnj@codesourcery.com>
6083 * lto-read.c (input_expr_operand): Change the LTO_return_expr1
6084 case to use DECL_RESULT if necessary.
6086 2007-11-01 Kenneth Zadeck <zadeck@naturalbridge.com>
6088 * lto-read.c (input_tree_list): Removed.
6089 (input_tree_flags): Added parameter to force flags no matter what
6091 (input_expr_operand): Added parameter to input_tree_flags.
6092 Added case for IDENTIFIER_NODE and TREE_LIST. Changed ASM to call
6093 input_expr_operand rather than input_tree_lists.
6094 (input_local_var): Use input_expr_operand to read attributes
6095 rather then input_tree_list.
6096 (input_phi, input_ssa_names): Added parameter to input_tree_flags.
6098 2007-10-31 Nathan Froyd <froydnj@codesourcery.com>
6100 * lto.c (lto_read_typedef_DIE): Fix comment typo.
6101 (lto_resolve_typedecl_ref): Fetch the referred-to type and build a fake
6103 * lto-read.c (lto_read_body): Use correct sizes for calculating
6104 type_decls_offset and types_offset.
6106 2007-10-30 Nathan Froyd <froydnj@codesourcery.com>
6108 * lto-tree.h (union lang_tree_node): Change GTY description to chain
6110 * config-lang.in (gtfiles): Add lto-lang.c.
6111 * lto-lang.c: Include gt-lto-lto-lang.h.
6112 * Make-lang.in (lto/lto-lang.o): Add dependency on gt-lto-lto-lang.h
6113 (lto/lto-symtab.o): Depend on LTO_H instead of TREE_H.
6114 (lto/lto-read.o): Likewise.
6116 2007-10-29 Kenneth Zadeck <zadeck@naturalbridge.com>
6118 * lto-read.c (data_in): Added type_decls and current_col fields.
6119 (string_slot): New type to hold canonized file name.
6120 (hash_string_slot_node, eq_string_slot_node, canon_file_name,
6121 input_line_info, set_line_info, clear_line_info): New functions.
6122 (file_name_hash_table): New hash table.
6123 (input_local_var, input_labels, input_local_vars_index,
6124 input_local_var, input_local_vars, input_ssa_names): Reorganized parameters.
6125 (input_uleb128): Changed type of byte var.
6126 (input_expr_operand): Large number of changes to get line numbers
6127 correct. Added TYPE_DECL case.
6128 (input_globals): Added code to get TYPE_DECLs processed.
6129 (input_local_var): Added code to process line numbers and
6130 TREE_CHAIN and DECL_CONTEXT.
6131 (input_function, input_constructor): Added call to
6133 (lto_static_init_local): Added code to get line numbers correct.
6134 (lto_read_body): Added code to get TYPE_DECLS read and to change
6135 parameters to the calls above that had their parms reorganized.
6137 2007-10-29 Nathan Froyd <froydnj@codesourcery.com>
6139 * lto.h (lto_resolve_typedecl_ref): Declare.
6140 * lto.c (lto_resolve_typedecl_ref): New function.
6142 2007-10-29 Mark Mitchell <mark@codesourcery.com>
6143 Nathan Froyd <froydnj@codesourcery.com>
6145 * lto.c (lto_read_subroutine_type_subprogram_DIE): Read the child
6146 DIEs even if we find an abstract origin for this DIE.
6148 2007-10-29 Nathan Froyd <froydnj@codesourcery.com>
6150 * lto.c (lto_read_subroutine_type_subprogram_DIE): Build the
6151 RESULT_DECL slightly earlier. Only remember the decl for later
6152 if we successfully merge declarations.
6154 2007-10-24 Kenneth Zadeck <zadeck@naturalbridge.com>
6156 * lto-read.c (input_expr_operand): Give label_values the proper
6157 context and provide switch statements with a default type.
6159 2007-10-23 Nathan Froyd <froydnj@codesourcery.com>
6161 * lto-read.c (lto_read_body): Move call to init_ssa_operands...
6162 * lto.c (lto_materialize_function): ...to here.
6164 2007-10-22 Nathan Froyd <froydnj@codesourcery.com>
6166 * lto.h (struct lto_info_fd): Add field unmaterialized_fndecls.
6167 * lto.c (lto_info_fd_init): Initialize it.
6168 (lto_info_fd_close): Free it.
6169 (lto_materialize_function): New function.
6170 (lto_read_subroutine_type_subprogram_DIE): Save the result decl on
6171 unmaterialized_fndecls.
6172 (lto_file_read): Read in all the function bodies after we have read
6173 all of the DWARF info.
6174 * lto-read.c (lto_read_body): Call init_ssa_operands if we are
6175 reading a function body.
6177 2007-10-20 Kenneth Zadeck <zadeck@naturalbridge.com>
6179 * lto-read.c (input_tree_flags): Renamed from input_flags to be
6180 semetric with output_tree_flags. Added call to log flags.
6181 (process_tree_flags): Renamed from process_flags. Fixed a lot of
6182 type issues to make everything consistent with flags being
6183 unsigned HOST_WIDE_INTS.
6184 (input_expr_operand): Added call to
6185 recompute_tree_invariant_for_addr_expr.
6186 (input_local_var): Added debugging for tree_chains. Now calls
6188 (input_phi): Made flags unsigned HOST_WIDE_INT.
6189 (input_ssa_names): Now calls input_tree_flags.
6190 (lto_read_body): Now sets cfun.
6191 (lto_read_function_body): Now sets current_function_pointer.
6193 2007-10-19 Nathan Froyd <froydnj@codesourcery.com>
6195 * lto.c (lto_read_variable_formal_parameter_constant_DIE): Check
6196 definitively whether SPECIFICATION or ABSTRACT_ORIGIN exist before
6197 inspecting fields within.
6198 (lto_read_DIE_at_ptr): Delete check for null result; let callers
6199 handle this appropriately.
6201 2007-10-19 Nathan Froyd <froydnj@codesourcery.com>
6203 * lto.c (lto_read_variable_formal_parameter_constant_DIE): Handle
6204 DW_AT_abstract_origin properly. Ensure that we're not dealing with
6205 both DW_AT_abstract_origin and DW_AT_specification.
6206 (lto_read_subroutine_type_subprogram_DIE): Handle
6207 DW_AT_abstract_origin.
6208 (lto_read_DIE): Use lto_read_only_for_child_DIEs for labels.
6209 (lto_read_DIE_at_ptr): Define as static to match declaration.
6210 Lookup the PTR in the cache before reading it from the file.
6211 (lto_resolve_var_ref): Adjust accordingly.
6212 (lto_resolve_fn_ref): Adjust accordingly. Tweak comment.
6213 (lto_resolve_field_ref): Adjust accordingly. Tweak comment.
6215 2007-10-19 Nathan Froyd <froydnj@codesourcery.com>
6217 * lto.c (lto_read_DIE_at_ptr): New function.
6218 (lto_resolve_var_ref): Use it.
6219 (lto_resolve_fn_ref): Use it.
6220 (lto_resolve_field_ref): Use it.
6221 (lto_read_variable_formal_parameter_constant_DIE): Follow
6222 DW_AT_specification and return the associated decl when appropriate.
6224 2007-10-18 Nathan Froyd <froydnj@codesourcery.com>
6226 * lto-lang.c (lto_type_for_mode): Move after lto_type_for_size.
6227 Implement for scalar integer modes.
6228 (lto_init): Initialize size_type_node.
6230 2007-10-18 Kenneth Zadeck <zadeck@naturalbridge.com>
6232 * lto-read.c (input_expr_operand): Remove ssa name asserts.
6233 (input_local_var): Add chaining for params.
6234 (input_ssa_names): Add cfun parameter.
6235 (input_function): Remove unnecessary else.
6237 2007-10-17 Nathan Froyd <froydnj@codesourcery.com>
6239 * lto.c (lto_read_only_for_child_DIEs): Mark die parameter as unused.
6240 (lto_resolve_var_ref): Use proper types.
6241 (lto_resolve_fn_ref): Likewise.
6242 (lto_resolve_field_ref): Likewise.
6244 2007-10-17 Nathan Froyd <froydnj@codesourcery.com>
6246 * lto-read.c (input_expr_operand): Remove case.
6248 2007-10-17 Nathan Froyd <froydnj@codesourcery.com>
6250 * lto.c (lto_read_only_for_child_DIEs): New function.
6251 (lto_read_DIE): Use it for lexical_block and inlined_subroutine DIEs.
6252 * lto-elf.c (lto_elf_map_lto_section): Remove.
6253 (lto_elf_file_vtable): Use lto_elf_map_optional_lto_section instead.
6254 * lto-read.c (input_expr_operand): Assert that we never read a NULL
6255 SSA_NAME. Add missing case for mechanical codes.
6256 (input_cfg): Use basic_block_info_for_function instead of
6259 2007-10-16 Kenneth Zadeck <zadeck@naturalbridge.com>
6261 * lto-read.c (input_sleb128, input_integer): Use proper casts.
6262 (input_list): Renamed input_tree_list and modified to follow same
6263 protocol as lto-function-out.c:output_tree_list.
6264 (input_expr_operand): Make asm operands use input_tree_list.
6265 (input_local_var): Now uses input_tree_list.
6266 (lto_read_body): Change placement for setting context of debug_labels.
6268 2007-10-16 Kenneth Zadeck <zadeck@naturalbridge.com>
6270 * lto-read.c (input_real): Output debugging in proper order.
6271 (input_integer): Compute bit lengths properly.
6272 (input_list): Clean up declaration.
6273 (input_expr_operand): Change calls to input_real to match fix.
6274 Make reading of LTO_bit_field_ref1 match output.
6275 (input_local_var): Make reading of attributes match what is being
6277 (dump_debug_stream): Also print char in hex.
6278 (debug_out_fun): Fix signed unsigned mismatch.
6280 2007-10-10 Nathan Froyd <froydnj@codesourcery.com>
6282 * lto.c (lto_read_form): Handle DW_AT_MIPS_linkage_name and
6283 DW_AT_GNU_vector specially, as they are not contiguous with the
6284 specified set of attribute names. Use class_mask to check for
6285 errors at the end of the function
6286 (lto_resolve_var_ref): Read the DIE if it is not cached.
6287 (lto_resolve_fn_ref): Likewise.
6288 (lto_resolve_field_ref): Likewise.
6290 2007-10-05 Nathan Froyd <froydnj@codesourcery.com>
6292 * lto.c: Include dwarf2out.h.
6293 (lto_cache_store_DIE): Assert that we never change the value.
6294 (LTO_BEGIN_READ_ATTRS): Print an informative error message.
6295 (lto_read_compile_unit_DIE): Handle DW_AT_entry_pc.
6296 (lto_read_array_type_DIE): Don't error on ndims == 0; build a
6297 sensible type instead.
6298 (lto_read_structure_union_class_type_DIE): Store the newly
6299 created type prior to reading the members of the structure to
6300 avoid infinite recursion. Avoid computing types and alignments
6301 for structures whose sizes are unknown.
6302 (lto_read_variable_formal_parameter_const): Handle DW_AT_artificial
6303 and set DECL_ARTIFICIAL accordingly. Ignore DW_AT_abstract_origin,
6304 DW_AT_const_value, and DW_AT_specification.
6305 (lto_read_subroutine_type_subprogram_DIE): Handle DW_AT_declaration.
6306 Return early if we have already constructed the function type.
6307 (lto_read_typedef_DIE): Check to see if the type has been cached
6308 already. Cache the type before reading any children.
6309 (lto_read_const_volatile_restrict_type_DIE): Handle DW_AT_name.
6310 (lto_read_DIE): Unset context->skip_non_parameters around reading
6312 (lto_resolve_fn_ref): Delete trailing whitespace.
6314 2007-09-11 Kenneth Zadeck <zadeck@naturalbridge.com>
6316 * lto-read.c (input_expr_operand): Added type for STRING_CST.
6318 2007-09-10 Nathan Froyd <froydnj@codesourcery.com>
6320 * lto-read.c (lto_read): Set the type of the newly created CALL_EXPR.
6322 2007-09-07 Nathan Froyd <froydnj@codesourcery.com>
6324 * lto-lang.c (signed_and_unsigned_types): New variable.
6325 (lto_type_for_size): Consult signed_and_unsigned_types to find
6326 an approprite type, creating it if necessary.
6327 (lto_set_decl_assembler_name): Add actual method body.
6329 2007-09-06 Jim Blandy <jimb@codesourcery.com>
6331 * lto.c (lto_read_variable_formal_parameter_constant_DIE): If we
6332 can't find a var init for this variable, leave its DECL_INITIAL.
6333 * lto-elf.c (lto_elf_map_optional_lto_section): Renamed from
6334 lto_elf_map_fn_body.
6335 (lto_map_lto_section): New function.
6336 (lto_elf_file_vtable): Use lto_elf_map_lto_section for function
6337 bodies, and lto_elf_map_optional_lto_section for variable
6339 (lto_elf_find_section_data): Quietly return NULL if the section is
6341 (lto_elf_file_open): Check for a NULL from lto_elf_find_section_data.
6343 * lto-elf.c (lto_elf_find_section_data): Remove dead code.
6345 * lto-read.c (lto_read_body): Doc fix.
6347 2007-08-29 Kenneth Zadeck <zadeck@naturalbridge.com>
6349 * lto-read.c (fun_in): Renamed to data_in.
6350 (input_expr_operand, input_local_var, input_string_internal,
6351 input_string, input_real, input_list, get_label_decl,
6352 get_type_ref, input_expr_operand, input_globals, input_labels,
6353 input_local_vars_index, input_local_var, input_local_vars,
6354 input_cfg, input_phi, input_ssa_names, input_bb, ): Renamed fun_in to data_in.
6355 (input_constructor): New function.
6356 (lto_read_function_body): Renamed to lto_read_body and generalized
6357 to handle both functions and constructors.
6358 (lto_read_function_body, lto_read_var_init): New function.
6360 2007-08-28 Kenneth Zadeck <zadeck@naturalbridge.com>
6362 * lto-read.c (input_expr_operand): Assert that there really is a
6364 (input_globals): Removed checks on 0 section.
6366 2007-08-28 Kenneth Zadeck <zadeck@naturalbridge.com>
6368 * lto-read.c (fun_in): Added local_decls_index and
6369 local_decls_index_d.
6370 (input_expr_operand): Changed inputting of PARM_DECLs and VAR_DECLs.
6371 (input_globals): Enabled code to handle FIELD_DECLs.
6372 (input_local_vars_index, input_local_vars): New function.
6373 (input_local_var): Changed to allow locals to be input randomly.
6374 (lto_read_function_body): Added code to input the
6375 local_decls_index and to free various structures.
6377 2007-08-17 Jim Blandy <jimb@codesourcery.com>
6379 * lto.c (lto_read_variable_formal_parameter_constant_DIE): Remove
6380 ATTRIBUTE_UNUSED from 'die' formal.
6382 Use enum LTO_tags where appropriate, instead of 'unsigned int'.
6383 * lto-read.c (input_record_start): Fix return type, type of 'tag'.
6384 (input_list): Fix type of 'tag'.
6385 (input_expr_operand): Fix type of 'tag' argument. Update
6386 declaration. Fix type of 'ctag'. Add default case to switch,
6387 since the type of the switched value is now an enum.
6388 (input_local_vars): Fix type of 'tag'.
6389 (input_bb): Fix type of 'tag' argument.
6390 (input_function): Fix type of 'tag' argument.
6392 2007-08-16 Jim Blandy <jimb@codesourcery.com>
6394 * lto.c (lto_read_member_DIE): Record the tree we create in
6395 fd->die_cache. (Our 'die' argument is no longer unused.)
6396 (lto_resolve_field_ref): New function.
6397 * lto.h (lto_resolve_field_ref): New declaration.
6399 2007-08-15 Jim Blandy <jimb@codesourcery.com>
6401 * lto-read.c (lto_read_var_init): Mark arguments as unused.
6403 2007-08-07 Jim Blandy <jimb@codesourcery.com>
6405 * lto.c (lto_read_form): Complete attr_classes table.
6406 (DWARF2_form_data): Doc fix.
6408 2007-08-05 Mark Mitchell <mark@codesourcery.com>
6410 * lto.h (lto_file_vtable): Remove read_var_init. Add map_var_init
6412 (lto_read_var_init): Declare.
6413 * lto.c (lto_read_variable_formal_parameter_constant_DIE): Use new
6414 interface for reading variable initializers.
6415 * lto-elf.c (lto_elf_read_var_init): Remove.
6416 (lto_elf_file_vtable): Update initializer.
6417 (lto_elf_read_var_init): Add comment about unused-ness.
6418 * lto-read.c (lto_read_var_init): New.
6420 * lto.c (lto_read_form): Add entry for DW_AT_inline.
6422 2007-08-02 Kenneth Zadeck <zadeck@naturalbridge.com>
6424 * lto-read.c (lto_read_function_body): Moved declaration of fn
6427 2007-08-01 Kenneth Zadeck <zadeck@naturalbridge.com>
6429 * lto-read.c (input_uleb128, input_string_internal, input_real,
6430 input_integer, input_record_start, input_list, get_type_ref,
6431 input_flags, input_expr_operand, input_expr_operand,
6432 input_expr_operand, input_local_vars, input_cfg, input_phi,
6433 input_ssa_names, input_bb, input_function): Added semicolons.
6436 2007-07-31 Kenneth Zadeck <zadeck@naturalbridge.com>
6438 * lto-read.c (input_globals): Remove debugging.
6439 (input_function): Set DECL_ARGUMENTS.
6441 2007-07-31 Kenneth Zadeck <zadeck@naturalbridge.com>
6443 * lto-read.c (input_expr_operand): Fixed code for COND_EXEC,
6444 RETURN_EXPR, MODIFY_EXPR and processing of flags.
6445 (input_phi): Made work with operands other than SSA_NAMES and
6446 fixed processing of flags.
6447 (input_ssa_names): Initialize SSA_NAME_DEF_STMT to empty stmt.
6448 (input_flags): New function.
6449 * lto-lang.c (lto_init): Changed state of in_lto_p.
6452 2007-07-24 Mark Mitchell <mark@codesourcery.com>
6454 * lto-tree.h (lto_varargs_cookie): Remove.
6455 * lto.c (lto_context): Add last_parm_type, varargs_p, skip_all,
6456 skip_non_parameters, skip_parameters.
6457 (lto_varargs_cookie): Remove.
6458 (lto_read_variable_formal_parameter_constant_DIE): Keep track of
6460 (lto_read_abbrev): New function.
6461 (lto_read_subroutine_type_subprogram_DIE): Make two passes over
6463 (lto_read_unspecified_parameters_DIE): Set context->varargs_p.
6464 (lto_read_DIE): Use lto_read_abbrev. Honor skip_* flags.
6465 (lto_file_read): Initialize new context fields.
6466 * lto-lang.c (lto_type_for_mode): Return NULL_TREE.
6467 (lto_unsigned_type): Remove.
6468 (lto_signed_type): Likewise.
6469 (lto_signed_or_unsigned_type): Likewise.
6470 (lto_init): Do not create lto_varargs_cookie.
6471 (LANG_HOOKS_UNSIGNED_TYPE): Do not define.
6472 (LANG_HOOKS_SIGNED_TYPE): Likewise.
6473 (LANG_HOOKS_SIGNED_OR_UNSIGNED_TYPE): Likewise.
6475 2007-07-19 Jan Hubicka <jh@suse.cz>
6477 * lto-read.c (lto_read_function_body): Produce empty scope block
6480 2007-07-18 Mark Mitchell <mark@codesourcery.com>
6482 * lto.c (lto_read_variable_formal_parameter_constant_DIE): Do not
6483 process local variables.
6484 (lto_read_subroutine_type_subprogram_DIE): Read child DIEs.
6486 2007-07-13 Kenneth Zadeck <zadeck@naturalbridge.com>
6488 * lto-read.c (input_list, input_expr_operand): Added struct
6490 (init_cfg, finalize_cfg): Removed function.
6491 (input_expr_operand): Added SSA_NAME and GIMPLE_MODIFY_STMT cases.
6492 (input_labels, input_local_vars): Now takes input_block parameter rather than
6494 (input_cfg, input_phi, input_ssa_names): New functions.
6495 (input_bb): Now passes in input_blocks. Does not construct cfg
6496 and processes the list of phi functions.
6497 (input_function): Now builds both the cfg and ssa_names table.
6498 (lto_read_function_body): Processes new header fields to construct
6499 streams for the ssa_names and cfg and their debugging.
6500 * lto-lang.c (lto_init): Set in_lto_p.
6503 2007-06-28 Mark Mitchell <mark@codesourcery.com>
6505 * lto.h (lto_file_vtable): Add read_var_init.
6506 * lto.c (lto_read_variable_formal_parameter_constant_DIE): Read
6508 (lto_main): Remove bogus asserts.
6509 * lto-elf.c (tm.h): Include it.
6510 (libiberty.y): Likewise.
6511 (lto_elf_file): Add strtab and symtab. Rename
6512 string_table_section_index to sec_strtab.
6513 (lto_elf_file_vtable): Add lto_elf_read_var_init.
6514 (lto_elf_get_shdr): New function.
6515 (lto_elf_free_shdr): Likewise.
6516 (lto_elf_find_section_data): Use them.
6517 (lto_elf_read_symtab): New function.
6518 (lto_elf_lookup_sym): Likewise.
6519 (lto_elf_free_sym): Likewise.
6520 (lto_elf_file_open): Tidy. Call lto_elf_read_symtab.
6521 (lto_elf_built_init): New function.
6522 (lto_elf_read_var_init): Likewise.
6523 * Make-lang.in (lto/lto-elf.o): Depend on $(TM_H).
6525 2007-06-26 Kenneth Zadeck <zadeck@naturalbridge.com>
6527 * lto-read (make_new_block): Initialize the stmt_list.
6528 (lto_static_init_local): Add debugging for missing codes.
6530 2007-06-26 Mark Mitchell <mark@codesourcery.com>
6532 * lto.c (lto_read_subroutine_type_subprogram_DIE): Handle
6533 unprototyped functions.
6535 2007-06-23 Mark Mitchell <mark@codesourcery.com>
6537 * lto.c (lto_read_variable_formal_parameter_constant_DIE):
6538 Handle DW_AT_MIPS_linkage_name.
6539 (lto_read_subroutine_type_subprogram): Likewise. Correct
6541 (lto_main): Remove incorrect assertions.
6542 * lto-symbtab.c: Build function types out of TREE_LISTs.
6544 * lto-elf.c (<libelf>): Check for HAVE_LIBELF_H.
6546 * Make-lang.in (LTO_OBJS): Depend on attribs.o.
6548 2007-06-21 Kenneth Zadeck <zadeck@naturalbridge.com>
6550 * lto-tree.h (lang_decl, lang_type, language_function): Added
6551 dummy since ggc does not like empty structs.
6552 * lto-elf.c (libelf.h): Changed to libelf/libelf.h.
6553 * lto-read.c (ADD_CLASS_FLAG, ADD_EXPR_FLAG): Changed
6554 expr->common to expr->base.
6555 (make_new_block): Moved stmt_list to proper place.
6557 2007-03-14 Robert Kennedy <jimbob@google.com>
6559 Eliminate use of lang_hooks.set_decl_assembler_name from LTO
6560 * lto.c (lto_read_subroutine_type_subprogram_DIE) Get DECL
6561 assembler name from DWARF.
6562 * lto-lang.c (lto_set_decl_assembler_name) New function.
6564 2006-09-10 Mark Mitchell <mark@codesourcery.com>
6566 * lto.h (lto_file_vtable): New structure.
6567 (lto_file): Add vtable pointer.
6568 (lto_file_init): Add vtable paramter.
6569 (lto_read_function_body): New function.
6570 (lto_symtab_merge_fn): New function.
6571 * lto.c (lto_file_init): Add vtable parameter.
6572 (lto_read_form): Fill in entries for DW_AT_prototyped,
6574 (lto_read_subroutine_type_subprogram_DIE): New function.
6575 (lto_read_DIE): Fill in entries for DW_TAG_subroutine_type and
6577 * lto-elf.c (lto_elf_vile_vtable): New variable.
6578 (lto_elf_file_open): Pass it to lto_file_init.
6579 (lto_elf_map_fn_body): New function.
6580 (lto_elf_unmap_fn_body): Likewise.
6581 * lto-read.c: New file.
6582 * lto-symtab.c (lto_symtab_merge_fn): New function.
6583 * lto-lang.c (LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION): Define to
6584 tree_rest_of_compilation.
6585 * Make-lang.in (LTO_OBJS): Add lto-read.o
6586 (lto-read.o): New target.
6588 2006-09-03 Mark Mitchell <mark@codesourcery.com>
6590 * lto.c (<inttypes.h>): Don't include it.
6591 (lto_context): Don't typedef it.
6592 (lto_resolve_reference): New function.
6593 (lto_read_form): Use it.
6594 (lto_resolve_type_ref): New function.
6595 (lto_resolve_var_ref): Likewise.
6596 (lto_resolve_fn_ref): Likewise.
6597 * lto.h (<inttypes.h>): Include it.
6598 (lto_context): New type.
6599 (lto_ref): New structure.
6600 (lto_resolve_type_ref): Declare.
6601 (lto_resolve_var_ref): Likewise.
6602 (lto_resolve_fn_ref): Likewise.
6604 2006-08-18 Mark Mitchell <mark@codesourcery.com>
6606 * lang-specs.h: New file.
6608 2006-08-14 Mark Mitchell <mark@codesourcery.com>
6610 * lto.c (lto_info_fd_init): Allocate the DIE cache.
6611 (lto_info_fd_close): Deallocate it.
6612 (lto_die_cache_entry): New structure.
6613 (lto_cache_hash): New function.
6614 (lto_cache_eq): Likewise.
6615 (lto_cache_store_DIE): Likewise.
6616 (lto_cache_lookup_DIE): Likewise.
6617 (lto_read_referenced_type_DIE): Use the cache.
6618 (lto_read_pointer_type_DIE): Robustify.
6619 (lto_read_DIE): Use the cache.
6620 * lto.h (hashtab.h): Include.
6621 (lto_info_fd): Add DIE cache.
6622 * Make-lang.in (LTO_H): New variable.
6623 (lto/lto-lang.o): Use LTO_H.
6624 (lto/lto-elf.o): Likewise.
6625 (lto/lto-symtab.o): Likewise.
6627 2006-07-09 Mark Mitchell <mark@codesourcery.com>
6629 * lto.c (lto_abi_mismatch_error): New function.
6630 (lto_abbrev_read): Initialize num_abbrevs.
6631 (lto_read_form): Specify allowed form classes for
6632 DW_AT_declaration. Adjust for change to lto_set_cu_context.
6633 (lto_read_variable_formal_parameter_constant_DIE): Handle
6634 DW_AT_declaration. Call lto_symtab_merge_var.
6635 (lto_read_pointer_type_DIE): New function.
6636 (lto_read_base_type_DIE): Use build_nonstandard_integer_type. Do
6637 not creat TYPE_DECLs for types that already have them.
6638 (lto_read_DIE): Add lto_read_pointer_type_DIE.
6639 (lto_set_cu_context): Make cu_start point to the header, not the
6641 (lto_file_read): Adjust for change to lto_set_cu_context.
6642 * Make-lang.in (LTO_OBJS): Add lto-symtab.o.
6643 (lto/lto-symtab.o): New rule.
6644 * lto-tree.h (lang_identifier): Add decl field.
6645 (LANG_IDENTIFIER_CAST): New macro.
6646 (LTO_IDENTIFIER_DECL): Likewise.
6647 (lto_symtab_merge_var): Declare.
6648 * lto-symtab.c: New file.
6650 2006-07-02 Daniel Berlin <dberlin@dberlin.org>
6652 * lto.c (lto_context): Add current_cu and info_fd members.
6653 (DWARF2_CompUnit): New structure.
6654 (lto_read_DIE): Take lto_info_fd *.
6655 (lto_read_child_DIEs): Ditto.
6656 (lto_file_corrupt_error): Constify argument.
6657 (lto_set_cu_context): New function
6658 (lto_info_fd_init): Ditto.
6659 (lto_info_fd_close): Ditto.
6660 (lto_file_init): Use lto_info_fd_init.
6661 (lto_file_close): Use lto_info_fd_close.
6662 (lto_read_initial_length): Pass in pointer to header size.
6663 (lto_read_comp_unit_header): Correct cu_length to
6664 real length from beginning of header. Take lto_info_fd * as
6666 (find_cu_for_offset): New function.
6667 (lto_read_form): Change first argument to lto_info_fd *.
6668 Add FORM_CONTEXT argument.
6669 Handle DW_FORM_ref_addr.
6670 (lto_read_tag_DIE): Change first argument to lto_info_fd *.
6671 (LTO_BEGIN_READ_ATTRS_UNCHECKED): Save old context.
6672 Swap contexts if necessary for form.
6673 (LTO_BEGIN_READ_ATTRS): Cast fd to right type for
6674 lto_file_corrupt_error.
6675 (LTO_END_READ_ATTRS): Swap contexts back if it had changed.
6676 (lto_read_referenced_type_DIE): Change first argument to
6677 lto_info_fd *. Access lto_fd fields through base pointer.
6678 (lto_read_compile_unit_DIE): Change first argument to an
6680 (lto_read_variable_formal_parameter_constant_DIE): Ditto.
6681 (lto_read_base_type_DIE): Ditto.
6682 (lto_read_child_DIEs): Ditto.
6683 (lto_read_DIE): Ditto. Change type of function pointer.
6684 (lto_info_read): New function.
6685 (lto_set_cu_context): Ditto.
6686 (lto_file_read): Use lto_info_read, walk resulting CU's
6687 (lto_main): Update for lto_info_fd change.
6688 * lto-elf.c (lto_elf_file_open): Cast lto_info_fd to lto_fd where
6690 * lto.h (DWARF2_CompUnit): New structure.
6691 (lto_info_fd): Ditto.
6692 (lto_file): Change debug_info to be an lto_info_fd.
6694 2006-06-25 Mark Mitchell <mark@codesourcery.com>
6696 * lto.c (toplev.h): Include it.
6697 (dwarf2.h): Likewise.
6700 (cgraph.h): Likewise.
6702 (inttypes.h): Likewise.
6703 (DWARF2_attr): New type.
6704 (DWARF2_abbrev): Likewise.
6705 (DWARF2_class): Likewise.
6706 (DWARF2_form_data): Likewise.
6707 (lto_context): Likewise.
6708 (lto_fd_init): New function.
6709 (lto_abbrev_fd_init): Likewise.
6710 (lto_abbrev_fd_close): Likewise.
6711 (lto_file_init): Use them.
6712 (lto_file_close): New function.
6713 (lto_file_corrupt_error): Likewise.
6714 (LTO_CHECK_INT_VAL): New macro.
6715 (lto_check_size_t_val): New function.
6716 (lto_check_int_val): Likewise.
6717 (LTO_READ_TYPE): New macro.
6718 (lto_read_ubyte): New function.
6719 (lto_read_uhalf): Likewise.
6720 (lto_read_uword): Likewise.
6721 (lto_read_uleb128): Likewise.
6722 (lto_read_initial_length): Likewise.
6723 (lto_abbrev_read_attrs): Likewise.
6724 (lto_abbrev_read): Likewise.
6725 (lto_abbrev_lookup): Likewise.
6726 (lto_read_section_offset): Likewise.
6727 (lto_read_comp_unit_header): Likewise.
6728 (lto_read_form): Likewise.
6729 (LTO_BEGIN_READ_ATTRS_UNCHECKED): New macro.
6730 (LTO_BEGIN_READ_ATTRS): Likewise.
6731 (LTO_END_READ_ATTRS): Likewise.
6732 (lto_unsupported_attr_error): New function.
6733 (lto_get_identifier): Likewise.
6734 (lto_read_referenced_type_DIE): Likewise.
6735 (lto_read_compile_unit_DIE): Likewise.
6736 (lto_read_variable_formal_parameter_constant_DIE): Likewise.
6737 (lto_read_base_type_DIE): Likewise.
6738 (lto_read_DIE): Likewise.
6739 (lto_read_child_DIEs): Likewise.
6740 (lto_file_read): Read DIEs.
6741 (lto_main): Ask middle end to emit entities.
6742 * lto-tree.h (lang_identifier): Inherit from tree_identifier.
6743 * lto-elf.c (lto_elf_file_open): Adjust for interface changes.
6744 (lto_elf_file_close): Likewise.
6745 * lto.h (lto_file): Declare.
6746 (DWARF2_abbrev): Likewise.
6748 (lto_abbrev_fd): Likewise.
6749 (lto_file): Use new types.
6750 (lto_file_close): Declare.
6751 * lto-lang.c (lto_init): Always use unit-at-a-time mode.
6753 2006-06-18 Mark Mitchell <mark@codesourcery.com>
6757 * lto-elf.c: New file.
6758 * lto-lang.c (flags.h): Include it.
6760 (lto_init): New function.
6761 (lto_write_globals): Remove.
6762 (LANG_HOOKS_WRITE_GLOBALS): Define to lhd_do_nothing.
6763 (LANG_HOOKS_INIT): Define.
6764 (LANG_HOOKS_PARSE_FILE): Likewise.
6765 * Make-lang.in (LTO_OBJS): Add lto.o and lto-elf.o.
6766 (LTO_EXE): Link with libelf.
6767 (lto/lto-lang.o): Update dependencies.
6768 (lto/lto.o): New target.
6769 (lto/lto-elf.o): Likewise.
6771 2006-06-12 Mark Mitchell <mark@codesourcery.com>
6773 * config-lang.in: New file.
6774 * Make-lang.in: Likewise.
6775 * lto-tree.h: Likewise.
6776 * lto-lang.c: Likewise.
6778 Copyright (C) 2006-2024 Free Software Foundation, Inc.
6780 Copying and distribution of this file, with or without modification,
6781 are permitted in any medium without royalty provided the copyright
6782 notice and this notice are preserved.