OSDN Git Service

2009-10-16 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
[pf3gnuchains/gcc-fork.git] / gcc / ChangeLog
1 2009-10-16  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
2
3         * config/s390/s390.c (s390_z10_optimize_cmp): Skip notes when
4         investigating previous or next insns.
5
6 2009-10-16  Eric Botcazou  <ebotcazou@adacore.com>
7
8         * tree-sra.c (build_ref_for_offset_1): Update comment.
9
10 2009-10-16  Wolfgang Gellerich  <gellerich@de.ibm.com>
11
12         * config/s390/s390.md (atype): Added missing values.
13
14 2009-10-15  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
15
16         PR target/41702
17         * pa.md (casesi): Use sign extended index in call to
18         gen_casesi64p.
19         (casesi64p): Update pattern to reflect above.
20
21 2009-10-15  Steve Ellcey  <sje@cup.hp.com>
22
23         PR rtl-optimization/41697
24         * sel-sched-ir.h (_eligible_successor_edge_p): Check successor count.
25
26 2009-10-15  Michael Meissner  <meissner@linux.vnet.ibm.com>
27
28         PR target/23983
29         * config/rs6000/predicates.md: Update copyright year.
30         * config/rs6000/altivec.md: Ditto.
31         
32         * config/rs6000/t-rs6000 (TM_H): Add rs6000-builtin.def.
33         (MD_INCLUDES): Add a2.md.
34         
35         * config/rs6000/rs6000.c (rs6000_builtin_decls): Change
36         RS6000_BUILTIN_COUNT to MAX_RS6000_BUILTINS.
37         (builtin_classify): New static vector to classify various builtins
38         to get the tree attributes correct.
39         (def_builtin): Set the attributes of builtins based on what the
40         builtin does (i.e. memory operation, floating point, saturation
41         need special attributes, others are pure functions).
42
43         * config/rs6000/rs6000.h (enum rs6000_btc): New enum to classify
44         the builtins.
45         (enum rs6000_builtins): Include rs6000-builtin.def to define the
46         builtins.  Change the end marker to MAX_RS6000_BUILTINS from
47         RS6000_BUILTIN_COUNT.
48         (rs6000_builtin_decls): Change RS6000_BUILTIN_COUNT to
49         MAX_RS6000_BUILTINS.
50
51         * config/rs6000/rs6000-builtin.def: New file that combines the
52         builtin enumeration name and attributes.
53
54 2009-10-15  H.J. Lu  <hongjiu.lu@intel.com>
55
56         * config/i386/linux.h (ASM_SPEC): Add --32.
57
58 2009-10-15  Jakub Jelinek  <jakub@redhat.com>
59
60         * dwarf2out.c (dwarf_tag_name): Handle DW_TAG_rvalue_reference_type
61         and DW_TAG_template_alias.
62         (dwarf_attr_name): Handle DW_AT_main_subprogram,
63         DW_AT_data_bit_offset, DW_AT_const_expr, DW_AT_enum_class,
64         DW_AT_linkage_name, DW_AT_GNU_guarded_by, DW_AT_GNU_pt_guarded_by,
65         DW_AT_GNU_guarded, DW_AT_GNU_pt_guarded, DW_AT_GNU_locks_excluded,
66         DW_AT_GNU_exclusive_locks_required, DW_AT_GNU_shared_locks_required
67         and DW_AT_GNU_odr_signature.
68         (dwarf_form_name): Handle DW_FORM_sec_offset, DW_FORM_exprloc,
69         DW_FORM_flag_present and DW_FORM_ref_sig8.
70         (output_signature): Only print name on the first byte.
71         (output_die): Likewise for dw_val_class_data8.
72
73 2009-10-15  Alexander Monakov  <amonakov@ispras.ru>
74
75         * doc/invoke.texi: Clarify that most optimizations are not enabled
76         without -O.
77
78 2009-10-15  Richard Guenther  <rguenther@suse.de>
79
80         PR lto/41668
81         * gimple.c (compare_type_names_p): Handle anonymous names
82         differently based on new mode argument.
83         (gimple_types_compatible_p): For structs also compare the tags.
84         (iterative_hash_type_name): Rename to ...
85         (iterative_hash_name): ... this.  Hash all names.
86         (iterative_hash_gimple_type): Fix hashing the struct tag of
87         pointer targets.  Hash field decl names.
88
89 2009-10-15  Richard Guenther  <rguenther@suse.de>
90
91         PR lto/41669
92         * gimple.c (gimple_get_alias_set): Avoid recursing on
93         invalid type topology.
94
95 2009-10-15  Andrew Pinski  <andrew_pinski@playstation.sony.com>
96
97         * config/spu/spu.c (get_branch_target): Use extract_asm_operands.
98
99 2009-10-15  Richard Guenther  <rguenther@suse.de>
100
101         * tree.c (free_lang_data_in_decl): Free DECL_FCONTEXT.
102
103 2009-10-15  Jakub Jelinek  <jakub@redhat.com>
104
105         * config/rs6000/option-defaults.h (OPTION_DEFAULT_SPECS): Don't
106         add --with-tune{,-32,-64} configured default for -mtune if explicit
107         -mcpu is used.
108
109 2009-10-14  Daniel Gutson  <dgutson@codesourcery.com>
110
111         * config/arm/neon.md (neon_vshll_n<mode>): Checking Bounds
112         fixed.
113
114 2009-10-14  DJ Delorie  <dj@redhat.com>
115         
116         * config/h8300/h8300.c (F): New.
117         (Fpa): New.
118         (h8300_emit_stack_adjustment): Call them.
119         (push): Likewise.
120         (h8300_push_pop): Likewise.
121         (h8300_expand_prologue): Likewise.
122         * config/h8300/h8300.h (DWARF2_DEBUGGING_INFO): Define.
123         (MUST_USE_SJLJ_EXCEPTIONS): Define.
124         (INCOMING_RETURN_ADDR_RTX): Define.
125         (INCOMING_FRAME_SP_OFFSET): Define.
126         (DWARF_CIE_DATA_ALIGNMENT): Define.
127
128 2009-10-14  Jakub Jelinek  <jakub@redhat.com>
129
130         * stor-layout.c (place_field): Don't emit -Wpadded warnings for
131         fields in builtin structs.
132         (finalize_record_size): Likewise.
133
134 2009-10-14  Richard Guenther  <rguenther@suse.de>
135
136         * gimple.c (gtc_ob): New global.
137         (struct type_pair_d): Replace pointers with type UIDs.
138         (type_pair_hash): Adjust.
139         (type_pair_eq): Likewise.
140         (lookup_type_pair): Likewise.  Allocate from an obstack.
141         (gimple_force_type_merge): Adjust.
142         (gimple_types_compatible_p): Likewise.
143         (free_gimple_type_tables): Free the obstack.
144
145 2009-10-14  Jakub Jelinek  <jakub@redhat.com>
146
147         * tree-parloops.c (separate_decls_in_region_debug_bind): Drop debug
148         stmts setting DEBUG_EXPR_DECLs.
149
150         * cfgexpand.c (expand_debug_expr): Ignore zero-length bitfields.
151         Don't crash if mode1 is VOIDmode.
152
153 2009-09-26  Vladimir Makarov  <vmakarov@redhat.com>
154
155         * params.def (PARAM_IRA_LOOP_RESERVED_REGS): New.
156         * params.h (IRA_LOOP_RESERVED_REGS): New
157         * tree-pass.h (pass_subregs_of_mode_init,
158         pass_subregs_of_mode_finish): Remove.
159         * passes.c (pass_subregs_of_mode_init,
160         pass_subregs_of_mode_finish): Remove.
161         (pass_reginfo_init): Move before loop optimizations.
162         * config/i386/i386.h (STACK_REG_COVER_CLASS): Define.
163         * common.opt (fira-loop-pressure): New.
164         * toplev.h (flag_ira_loop_pressure): New.
165         * rtl.h (init_subregs_of_mode, finish_subregs_of_mode): New
166         externals.
167         * reginfo.c (init_subregs_of_mode, finish_subregs_of_mode):
168         Make external and void type functions.
169         (gate_subregs_of_mode_init, pass_subregs_of_mode_init,
170         pass_subregs_of_mode_finish): Remove.
171         * ira-costs.c (init_costs): Call init_subregs_of_mode.
172         * regmove.c: Include ira.h.
173         (regmove_optimize): Call ira_set_pseudo_classes after IRA based
174         register pressure calculation in loops.
175         * loop-invariant.c: Include REGS_H and ira.h.
176         (struct loop_data): New members max_reg_pressure, regs_ref, and
177         regs_live.
178         (struct invariant): New member orig_regno.
179         (curr_loop): New variable.
180         (find_exits): Initialize regs_ref and regs_live.
181         (create_new_invariant): Initialize orig_regno.
182         (get_cover_class_and_nregs): New.
183         (get_inv_cost): Make aregs_needed an array.  Use regs_needed as an
184         array.  Add code for flag_ira_loop_pressure.
185         (gain_for_invariant): Make new_regs an array.  Add code for
186         flag_ira_loop_pressure.
187         (best_gain_for_invariant): Ditto.
188         (set_move_mark): New parameter gain.  Use it for debugging output.
189         (find_invariants_to_move): Make regs_needed and new_regs an array.
190         Add code for flag_ira_loop_pressure.
191         (move_invariant_reg): Set up orig_regno.
192         (move_invariants): Set up reg classes for pseudos for
193         flag_ira_loop_pressure.
194         (free_loop_data): Clear regs_ref and regs_live.
195         (curr_regs_live, curr_reg_pressure, regs_set, n_regs_set,
196         get_regno_cover_class, change_pressure, mark_regno_live,
197         mark_regno_death, mark_reg_store, mark_reg_clobber,
198         mark_reg_death, mark_ref_regs, calculate_loop_reg_pressure): New.
199         (move_loop_invariants): Calculate pressure.  Initialize curr_loop.
200         * ira.c (ira): Call ira_set_pseudo_classes after IRA based
201         register pressure calculation in loops if new regs were added.
202         Call finish_subregs_of_mode.
203         * opts.c (decode_options): Set up flag_ira_loop_pressure.
204         * Makefile.in (loop-invariant.o): Add ira.h.
205         (regmove.o): Ditto.
206         * doc/invoke.texi (-fira-loop-pressure, ira-loop-reserved-regs):
207         Describe.
208         * doc/tm.texi (STACK_REG_COVER_CLASS): Describe.
209         
210 2009-10-14  Richard Guenther  <rguenther@suse.de>
211
212         * lto-symtab.c (lto_symtab_compatible): Fold in ...
213         (lto_symtab_merge): ... here.  Rewrite both to take the
214         prevailing and a to-be-merged entry and to queue diagnostics
215         properly.
216         (lto_symtab_resolve_replaceable_p): New predicate for
217         symbol resolution.
218         (lto_symtab_resolve_can_prevail_p): Likewise.
219         (lto_symtab_resolve_symbols): Rewrite.  Fold in code that
220         handles merging commons by choosing the largest decl.  Fold
221         in code that gives ODR errors.
222         (lto_symtab_merge_decls_2): Simplify a lot.  Emit queued
223         diagnostics here.
224         (lto_symtab_merge_decls_1): Re-structure.  Deal with the
225         case of no prevailing decl here.  Diagnose mismatches
226         in object types here.  Drop all but the prevailing decls.
227         (lto_symtab_prevailing_decl): Return the single prevailing decl.
228         * lto-streamer-in.c (lto_input_tree_ref): Deal with
229         VIEW_CONVERT_EXPRs in decl slots.  Unshare the tree in this case.
230
231 2009-10-14  Richard Guenther  <rguenther@suse.de>
232
233         PR lto/41521
234         * lto-streamer-in.c (input_bb): Replace debug stmts with
235         nops instead of dropping them.
236
237 2009-10-14  Nick Clifton  <nickc@redhat.com>
238
239         * gcc/doc/extended.texi: Replace the dash character with
240         @minus{} in situations where it is being used as a minus
241         symbol.
242         * gcc/doc/tm.texi: Likewise.
243         * gcc/doc/md.texi: Likewise.
244
245 2009-10-14  Jakub Jelinek  <jakub@redhat.com>
246
247         PR preprocessor/41543
248         * input.h (BUILTINS_LOCATION): Change to 1 from 2.
249         Assert BUILTINS_LOCATION < RESERVED_LOCATION_COUNT.
250         * tree.c: Include intl.h.
251         (expand_location): Handle BUILTINS_LOCATION.
252         * Makefile.in (tree.o): Depend on intl.h.
253
254         PR debug/41695
255         * dwarf2out.c (dwarf2out_var_location): Always clear
256         last_postcall_label when changing last_label.
257
258 2009-10-14  Pascal Obry  <obry@adacore.com>
259
260         * gcc.c (DEFAULT_SWITCH_CURTAILS_COMPILATION): Add -E.
261         (process_command): Handle -E as done with -c and -S.  Do not add
262         the target executable suffix to the output file when -E is used.
263         (main): Adjust error message accordingly.
264
265 2009-10-14  Alexandre Oliva  <aoliva@redhat.com>
266
267         PR debug/41343
268         PR debug/41447
269         PR debug/41264
270         PR debug/41338
271         * tree.c (tree_node_structure_for_code): DEBUG_EXPR_DECL uses
272         decl with rtl.
273         (tree_code_size): Likewise.
274
275 2009-10-13  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
276
277         * builtins.c (fold_builtin_1): Support complex "arc" functions.
278         * real.h (HAVE_mpc_arc): Define.
279
280 2009-10-14  Kaz Kojima  <kkojima@gcc.gnu.org>
281
282         * config/sh/sh.c (TARGET_BUILTIN_DECL): Define.
283         (struct builtin_description): Add fndecl field.
284         (bdesc): Remove const qualifier.  Update initializer.
285         (sh_media_init_builtins): Remove const qualifier for d.  Record
286         the result of add_builtin_function to the fndecl field.
287         (sh_builtin_decl): New.
288         (sh_media_builtin_decl): New.
289
290 2009-10-14  Hans-Peter Nilsson  <hp@axis.com>
291
292         PR target/38948
293         * config/cris/cris.h (SECONDARY_RELOAD_CLASS): Handle reload
294         requests between special registers.
295
296 2009-10-13  Eric Botcazou  <ebotcazou@adacore.com>
297
298         * dwarf2out.c (mem_loc_descriptor): Accept UNGT as well.
299
300 2009-10-13  Richard Henderson  <rth@redhat.com>
301
302         PR tree-optimization/41377
303         * tree-eh.c (unsplit_eh): Propagate degenerate PHIs.
304         (cleanup_empty_eh_merge_phis): New change_region parameter;
305         pass it on to redirect_eh_edge_1.  Update callers.
306         (cleanup_empty_eh_unsplit): Don't require an existing EH label
307         at the destination block.
308
309 2009-10-13  Basile Starynkevitch  <basile@starynkevitch.net>
310
311         * passes.c (register_pass): Replaced gcc_unreachable by
312         fatal_error on failure. Mentions plugins in comments & messages.
313
314 2009-10-13  Jakub Jelinek  <jakub@redhat.com>
315
316         PR target/41693
317         * rtl.h (DEBUG_EXPR_TREE_DECL): Define.
318         * sched-vis.c (print_value): Use it.
319         * cselib.c (cselib_hash_rtx): Likewise.
320         * print-rtl.c (print_rtx): Likewise.
321         * cfgexpand.c (expand_debug_rtx): Likewise.
322         * var-tracking.c (vt_expand_loc_callback): Likewise.
323
324 2009-10-13  Richard Guenther  <rguenther@suse.de>
325
326         PR lto/41565
327         * opts.c (handle_option): Split out code to handle setting
328         the options flag var ...
329         (set_option): ... here.
330         * opts.h (set_option): Declare.
331         * lto-opts.c (register_user_option_p): Include -fexceptions
332         and all position independent code variants.
333         (handle_common_option): Remove.
334         (lto_reissue_options): Use set_option.
335
336 2009-10-13  Martin Jambor  <mjambor@suse.cz>
337
338         PR tree-optimization/41661
339         * ipa-prop.c (compute_complex_pass_through): Allow only operations
340         that are tcc_comparisons or do not change the type in any
341         un-usleless way.
342         * ipa-cp.c (ipcp_lattice_from_jfunc): Request boolean type when
343         folding tcc_comparison operations.
344
345 2009-10-13  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
346
347         * config/s390/s390.c (s390_encode_section_info): Handle BLKmode
348         properly.
349
350 2009-10-12  Alexandre Oliva  <aoliva@redhat.com>
351
352         PR debug/41343
353         PR debug/41447
354         PR debug/41264
355         PR debug/41338
356         * tree.def (DEBUG_EXPR_DECL): New.
357         * rtl.def (DEBUG_EXPR): New.
358         * gengtype.c (adjust_field_rtx_def): Handle it.
359         * tree-ssa.c (propagate_var_def_into_debug_stmts): Rename to...
360         (insert_debug_temp_for_var_def): ... this.  Drop support for
361         moving.  Take iterator for def stmt; insert debug stmt before it.
362         Scan early for use count and kind in debug stmts.
363         (propagate_defs_into_debug_stmts): Rename to...
364         (insert_debug_temps_for_defs): ... this.  Likewise.
365         * tree.h (DEBUG_TEMP_UID): New.
366         * tree.c (next_debug_decl_uid): New.
367         (make_node_stat): Count debug decls separately.
368         (copy_node_stat): Likewise.
369         * cfgexpand.c (expand_debug_expr): Handle DEBUG_EXPR_DECL.
370         * var-tracking.c (dv_is_decl_p): Recognize it.
371         (VALUE_RECURSED_INTO): Apply to DEBUG_EXPRs too.
372         (track_expr_p): Track expanded DEBUG_EXPR_DECLs.
373         (vt_expand_loc_callback): Expand DEBUG_EXPRs.
374         (emit_note_insn_var_location): Don't emit notes for DEBUG_EXPR_DECLs.
375         * cselib.c (rtx_equal_for_cselib_p): Handle DEBUG_EXPR.
376         (cselib_hash_rtx): Likewise.
377         (cselib_expand_value_rtx_1): Use callback for DEBUG_EXPR.
378         * tree-ssa-operands.c (get_expr_operands): Skip DEBUG_EXPR_DECLs in
379         debug bind stmts.
380         * emit-rtl.c (verify_rtx_sharing): Handle DEBUG_EXPR and VALUE.
381         (copy_rtx_if_shared_1, reset_used_flags, set_used_flags): Likewise.
382         * rtl.c (copy_rtx): Likewise.
383         (rtx_equal_p_cb, rtx_equal_p): Handle DEBUG_EXPR.
384         * print-rtl.c (print_rtx): Likewise.
385         * sched-vis.c (print_value): Likewise.
386         (print_insn): Handle DEBUG_EXPR_DECL.
387         * tree-dump.c (dequeue_and_dump): Likewise.
388         * tree-pretty-print.c (dump_decl_name, dump_generic_node): Likewise.
389         * gimple-iterator (gsi_replace): Check for same lhs.
390         (gsi_remove): Insert debug temps.
391         * tree-ssa-loop-im.c (rewrite_reciprocal): Replace with same lhs.
392         (move_computations_stmt): Drop explicit propagation into debug stmts.
393         (rewrite_bittest): Likewise.  Use gsi_remove for propagation.
394         * tree-ssa-reassoc.c (rewrite_expr_tree, linearize_expr): Likewise.
395         * tree-ssa-sink.c (statement_sink_location): Likewise.
396         * tree-ssa-forwprop (forward_propagate_addr_expr): Likewise.
397         * tree-ssanames.c (release_ssa_name): Adjust for rename.
398         * tree-flow.h: Likewise.
399         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Don't mark
400         debug temps without values.
401         (eliminate_unnecessary_stmts): Don't discard just-inserted
402         debug stmts.
403
404 2009-10-12  Hans-Peter Nilsson  <hp@axis.com>
405
406         PR target/26515
407         * config/cris/cris.md (andu): Check that operand 1 is one of the
408         general registers.  Fix typo in head comment.
409
410 2009-10-12  Stefan Dösinger  <stefan@codeweavers.com>
411
412         * config/i386/i386.md (vswapmov): New.
413         * config/i386/i386.c (ix86_handle_fndecl_attribute): New.
414         (ix86_function_ms_hook_prologue): New.
415         (ix86_expand_prologue): Handle ms_hook_prologue attribute.
416         * configure.ac: Test for swap suffix support in as.
417         * configure: Rebuild.
418
419 2009-10-12  Jakub Jelinek  <jakub@redhat.com>
420
421         PR target/41680
422         * config/i386/i386.md (split after *testqi_ext_3_rex64): Only narrow
423         paradoxical subregs to prevent partial register stalls if the inner
424         mode is integer mode.
425
426 2009-10-12  Uros Bizjak  <ubizjak@gmail.com>
427
428         * config/i386/i386.md (*setcc_<mode>_2): Remove insn pattern.
429
430 2009-10-12  Dodji Seketeli  <dodji@redhat.com>
431
432         PR c++/41570
433         * gcc/dwarf2out.c (template_parameter_pack_die,
434         gen_formal_parameter_pack_die): Use add_name_and_src_coords_attributes.
435
436 2009-10-12  Alexandre Oliva  <aoliva@redhat.com>
437
438         PR debug/41616
439         * tree-into-ssa.c (insert_phi_nodes_for): Build debug bind stmts
440         on updates too.
441         (maybe_register_def): Likewise.  Take stmt iterator.
442         (rewrite_update_stmt): Take stmt iterator and pass it on.
443         (rewrite_update_enter_block): Pass stmt iterator.
444
445 2009-10-11  Andrew Pinski  <andrew_pinski@playstation.sony.com>
446
447         * config/spu/spu.c (TARGET_BUILTIN_DECL): Define.
448         (spu_builtin_decl): New function.
449
450 2009-10-12  Uros Bizjak  <ubizjak@gmail.com>
451
452         * config/i386/i386.md (SWIM): New mode iterator.
453         (mov<mode>cc): Macroize expander from mov{qi,hi,si,di}cc patterns
454         using SWIM mode iterator.
455         (x86_mov<mode>cc_0_m1): Macroize insn from x86_mov{si,di}cc_0_m1
456         patterns using SWI48 mode iterator.
457         (*x86_mov<mode>cc_0_m1_se):  Macroize insn from
458         *x86_mov{si,di}cc_0_m1_se patterns using SWI48 mode iterator.
459         (*x86_mov<mode>cc_0_m1_neg): New insn pattern.
460         (*mov<mode>cc_noc): Macroize insn from *mov{hi,si,di}cc_noc
461         patterns using SWI248 mode iterator.
462         * config/i386/i386.c (ix86_expand_int_movcc): Update the call to
463         gen_x86_movdicc_0_m1_rex64 for renamed function
464
465 2009-10-11  Jose Ruiz  <ruiz@adacore.com>
466             Eric Botcazou  <ebotcazou@adacore.com>
467
468         PR target/33743
469         * config/sparc/sol2.h (MD_UNWIND_SUPPORT): Define.
470         * config/sparc/sol2-unwind.h: New file.
471
472 2009-10-11  Olivier Hainque  <hainque@adacore.com>
473             Eric Botcazou  <ebotcazou@adacore.com>
474
475         PR target/33743
476         * config/i386/sol2.h (MD_UNWIND_SUPPORT): Define.
477         * config/i386/sol2-unwind.h: New file.
478
479 2009-10-11  H.J. Lu  <hongjiu.lu@intel.com>
480
481         PR target/41665
482         * config/i386/i386.md (addsi_1_zext): Get the proper second
483         operand for lea.
484
485 2009-10-11  Richard Sandiford  <rdsandiford@googlemail.com>
486
487         * simplify-rtx.c (simplify_replace_rtx): Use rtx_equal_p for
488         all OLD_RTXes, not just REGs.  Use copy_rtx to create the
489         replacement value.
490
491 2009-10-11  Richard Guenther  <rguenther@suse.de>
492
493         * gimple.c (iterative_hash_type_name): Do not handle special
494         anonymous names.
495
496 2009-10-11  Uros Bizjak  <ubizjak@gmail.com>
497
498         * config/i386/i386.md (*setcc_di_1): New insn_and_split pattern.
499         (*setcc_si_1_and): Ditto.
500         (*setcc_si_1_movzbl): Ditto.
501         (*setcc_<mode>_2): Ditto.
502         (*setcc_qi): Rename from *setcc_1.
503         (*setcc_qi_slp): Rename from *setcc_2.
504
505         (*zero_extendqihi2_movzbw_and splitter): Use ix86_expand_clear.
506         (*zero_extendqisi2_movzbw_and splitter): Ditto.
507
508         * config/i386/i386.c (ix86_expand_clear): Remove reload_completed from
509         "if" condition, there is already assert with reload_completed present.
510
511 2009-10-11  Gerald Pfeifer  <gerald@pfeifer.com>
512
513         * plugin.c (try_init_one_plugin): Improve constness of variable err.
514
515 2009-10-10  Gerald Pfeifer  <gerald@pfeifer.com>
516
517         * doc/install.texi (Final install): Refer to
518         http://gcc.gnu.org/bugs/ for bug reporting.
519
520 2009-10-10  Peter Bergner  <bergner@vnet.ibm.com>
521
522         * configure.ac: Add test for dci instruction.
523         * configure: Regenerate.
524         * config.in: Likewise.
525         * config.gcc: Handle --with-cpu=476 and --with-cpu=476fp.
526         * doc/invoke.texi: Add cpu_type 476 and 476fp.
527         (-mmulhw): Add 476 to description.
528         (-mdlmzb): Likewise.
529         * config/rs6000/t-fprules (MULTILIB_MATCHES_FLOAT): Include -mcpu=476.
530         * config/rs6000/rs6000.c (processor_costs): Add ppc476_cost.
531         (processor_target_table): Add 476 and 476fp entries.
532         (rs6000_override_options): Use ppc476_cost for PROCESSOR_PPC476.
533         (rs6000_issue_rate): Add CPU_PPC476.
534         * config/rs6000/rs6000.h (ASM_CPU_476_SPEC): Define.
535         (ASM_CPU_SPEC): Pass %(asm_cpu_476) for -mcpu=476 and -mcpu=476fp.
536         (processor_type): Add PROCESSOR_PPC476.
537         (EXTRA_SPECS): Add asm_cpu_476 string.
538         * config/rs6000/rs6000.md: (define_attr "type"): Add isel attribute.
539         (define_attr "cpu"): Add ppc476.
540         Include 476.md.
541         Update comments for 476.
542         (isel_signed, isel_unsigned): Change to use "isel" type attribute.
543         * config/rs6000/vxworks.h (CPP_SPEC): Handle 464 and 476.
544         Update copyright year.
545         * config/rs6000/476.md: New file.
546         * config/rs6000/40x.md: Add description for "isel" attribute.
547         Update copyright year.
548         * config/rs6000/440.md: Likewise.
549         * config/rs6000/603.md: Likewise.
550         * config/rs6000/6xx.md: Likewise.
551         * config/rs6000/7450.md: Likewise.
552         * config/rs6000/7xx.md: Likewise.
553         * config/rs6000/8540.md: Likewise.
554         * config/rs6000/cell.md: Likewise.
555         * config/rs6000/e300c2c3.md: Likewise.
556         * config/rs6000/e500mc.md: Likewise.
557         * config/rs6000/mpc.md: Likewise.
558         * config/rs6000/power4.md: Likewise.
559         * config/rs6000/power5.md: Likewise.
560         * config/rs6000/power6.md: Likewise.
561         * config/rs6000/power7.md: Likewise.
562         * config/rs6000/rios1.md: Likewise.
563         * config/rs6000/rios2.md: Likewise.
564         * config/rs6000/rs64.md: Likewise.
565
566 2009-10-10  Richard Guenther  <rguenther@suse.de>
567
568         PR tree-optimization/41654
569         * tree-ssa-ifcombine.c (ifcombine_ifandif): Properly canonicalize
570         a cond expr before calling gimple_cond_set_condition_from_tree.
571         (ifcombine_iforif): Likewise.
572
573 2009-10-09  Ian Lance Taylor  <iant@google.com>
574
575         * configure.ac: Use AC_SEARCH_LIBS to find dlopen.
576         * configure: Rebuild.
577
578 2009-10-09  Neil Vachharajani <nvachhar@google.com>
579
580         * doc/cpp.texi (Other Directives): Do not list #ident and #sccs as
581         deprecated.
582
583 2009-10-09  Richard Guenther  <rguenther@suse.de>
584
585         PR lto/41638
586         * target-def.h (TARGET_BUILTIN_DECL): Define.
587         (TARGET_INITIALIZER): Add TARGET_BUILTIN_DECL.
588         * target.h (struct gcc_target): Add builtin_decl target hook.
589         * doc/tm.texi (TARGET_BUILTIN_DECL): Document.
590         * lto-streamer-in.c (lto_get_builtin_tree): Fix handling of
591         target builtins.
592         * lto-streamer-out.c (lto_output_tree_pointers): Use sorry,
593         not gcc_unreachable.
594         (lto_output_builtin_tree): Sorry if the target does not support
595         streaming target builtins.
596         * config/rs6000/rs6000.c (TARGET_BUILTIN_DECL): Define.
597         (rs6000_builtin_decl): New function.
598         * config/i386/i386.c (TARGET_BUILTIN_DECL): Define.
599         (ix86_builtin_decl): New function.
600
601 2009-10-09  Jakub Jelinek  <jakub@redhat.com>
602
603         PR preprocessor/41445
604         * c-ppoutput.c (do_line_change): New function.
605         (cb_line_change): Use it.
606         (scan_translation_unit): Call do_line_change if
607         avoid_paste or PREV_WHITE and token location is on a different line
608         than print.src_line.
609
610         PR debug/40521
611         * dwarf2out.c (dwarf2out_init): Test whether
612         HAVE_GAS_CFI_SECTIONS_DIRECTIVE is non-zero instead of checking
613         it is defined.
614
615         PR rtl-optimization/41646
616         * calls.c (expand_call): For BLKmode types returned in registers
617         avoid likely spilled hard regs in copy_blkmode_from_reg generated
618         insns.
619
620 2009-10-09  Richard Guenther  <rguenther@suse.de>
621
622         PR tree-optimization/41634
623         * tree-ssa-dom.c (remove_local_expressions_from_table): Assert
624         we remove the correct elements.
625         (optimize_stmt): Make sure to update stmt operands before
626         optimizing redundancies.
627
628 2009-10-09  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
629
630         * config/s390/s390.md ("prefetch"): Remove stcmh for prefetching.
631
632 2009-10-09  Richard Guenther  <rguenther@suse.de>
633
634         PR driver/41637
635         * lto-wrapper.c (ltrans_output_file, flto_out, args_name): New
636         globals.
637         (lto_wrapper_exit): New function.
638         (fatal): Use it.
639         (fatal_perror): Likewise.
640         (fork_execute): Use global args_name, do not free it.
641         (run_gcc): Use global ltrans_output_file, flto_out, do not free them.
642         * lto-streamer.h: Remove duplicate prototypes.
643
644 2009-10-09  Richard Guenther  <rguenther@suse.de>
645
646         * cgraph.c (cgraph_create_edge): Check for NULL call_stmt
647         before calling stmt_can_throw_external.
648
649 2009-10-09  Eric Botcazou  <ebotcazou@adacore.com>
650
651         PR tree-optimization/40071
652         * tree-vect-data-refs.c (vect_create_data_ref_ptr): Build a ref-all
653         pointer if the original data reference doesn't conflict with the
654         created vector data reference.  Fix long line.
655
656 2009-10-09  Uros Bizjak  <ubizjak@gmail.com>
657
658         * config/i386/i386.md (any_div): New code iterator.
659         (u): Handle div and udiv.
660         (sgnprefix): Ditto.
661         (<u>divqi3): Macroize insn from {,u}divqi3  using any_div
662         code iterator.
663         (lfloor<MODEF:mode><SWI48:mode>2): Macroize insn from
664         lfloor<mode>{si,di}2 patterns using SWI48 mode iterator.
665         (lceil<MODEF:mode><SWI48:mode>2): Macroize insn from
666         lceil<mode>{si,di}2 patterns using SWI48 mode iterator.
667
668 2009-10-08  Joseph Myers  <joseph@codesourcery.com>
669
670         * gcc.c (main): Remove trailing "." from diagnostics.
671
672 2009-10-08  Cary Coutant  <ccoutant@google.com>
673
674         Add support for debugging with ICF (Identical Code Folding).
675         * calls.c (debug.h): New #include.
676         (emit_call_1): Call virtual_call_token debug hook.
677         * common.opt (-fenable-icf-debug): New option.
678         * dwarf2out.c (dwarf2_debug_hooks): Add entries for new hooks (two
679         locations in the source).
680         (poc_label_num): New variable.
681         (dcall_entry, vcall_entry): New typedefs.
682         (dcall_table, vcall_table): New variables.
683         (struct vcall_insn): New type.
684         (vcall_insn_table): New variable.
685         (DEBUG_DCALL_SECTION, DEBUG_VCALL_SECTION): New macros.
686         (size_of_dcall_table): New function.
687         (output_dcall_table): New function.
688         (size_of_vcall_table): New function.
689         (output_vcall_table): New function.
690         (dwarf2out_direct_call): New function.
691         (vcall_insn_table_hash): New function.
692         (vcall_insn_table_eq): New function.
693         (dwarf2out_virtual_call_token): New function.
694         (dwarf2out_virtual_call): New function.
695         (dwarf2out_init): Allocate new tables and sections.
696         (prune_unused_types): Mark DIEs referenced from direct call table.
697         (dwarf2out_finish): Output direct and virtual call tables.
698         * final.c (final_scan_insn): Call direct_call and virtual_call
699         debug hooks.
700         * debug.h (struct gcc_debug_hooks): Add direct_call,
701         virtual_call_token, virtual_call hooks.
702         (debug_nothing_uid): New function.
703         * debug.c (do_nothing_debug_hooks): Add dummy entries for new hooks.
704         (debug_nothing_uid): New function.
705         * dbxout.c (dbx_debug_hooks): Add dummy entries for new hooks.
706         (xcoff_debug_hooks): Likewise.
707         * sdbout.c (sdb_debug_hooks): Likewise.
708         * vmsdbgout.c (vmsdbg_debug_hooks): Likewise.
709         * doc/invoke.texi (-fenable-icf-debug): New option.
710
711 2009-10-08  Alexandre Oliva  <aoliva@redhat.com>
712
713         PR debug/41353
714         * regmove.c (regmove_backward_pass): Replace src with dst in the
715         debug insn, and check for dst before rather than after.
716
717 2009-10-08  Janis Johnson <janis187@us.ibm.com>
718
719         * config/rs6000/rs6000.c (rs6000_delegitimize_address): Remove.
720         (TARGET_DELEGITIMIZE_ADDRESS): Likewise.
721
722 2009-10-08  Jan Hubicka  <jh@suse.cz>
723
724         PR middle-end/41626
725         * cgraphbuild.c (record_reference): When parameter DATA is NULL,
726         do not mark cgraph nodes as needed.
727         (record_references_in_initializer): Add new only_vars parameter.
728         * cgraph.h (record_references_in_initializer): New parameter.
729         * varasm.c (assemble_variable): Update call.
730         * varpool.c (varpool_analyze_pending_decls): Always look for
731         referenced vars.
732
733 2009-10-08  Anatoly Sokolov  <aesok@post.ru>
734
735         * config/avr/avr.c (last_insn_address) Remove variable.
736         (expand_prologue): Don't initialise last_insn_address variable.
737         (final_prescan_insn): Don't output insn size.
738         * config/avr/avr.opt (msize): Remove switch.
739         * doc/invoke.texi (AVR Options): Remove documentation of -msize
740         switch.
741
742 2009-10-08  Adam Nemet  <anemet@caviumnetworks.com>
743
744         * combine.c (label_tick_ebb_start): Fix comment.
745         (combine_instructions): Set label_tick and label_tick_ebb_start before
746         calling setup_incoming_promotions.  Start them from 1.  Increment
747         label_tick instead of deriving it from the BB index.  Rather than
748         comparing ticks use the block from the previous iteration to decide
749         whether to start a new EBB.  Remove empty lines before function.
750
751 2009-10-08  Michael Matz  <matz@suse.de>
752
753         PR middle-end/41573
754         * builtins.c (fold_builtin_isascii): Use fold_build2.
755         (fold_builtin_isdigit): Ditto.
756         * except.c (duplicate_eh_regions_1): Tolerate NULL labels.
757         * tree-cfg.c (struct rus_data, remove_useless_stmts_warn_notreached,
758         remove_useless_stmts_cond, remove_useless_stmts_tf,
759         remove_useless_stmts_tc, remove_useless_stmts_bind,
760         remove_useless_stmts_goto, remove_useless_stmts_label,
761         remove_useless_stmts_1, remove_useless_stmts,
762         pass_remove_useless_stmts): Remove.
763         * tree-pass.h (pass_remove_useless_stmts): Don't declare.
764         * passes.c (init_optimization_passes): Don't add
765         pass_remove_useless_stmts.
766         * tree-eh.c (lower_eh_constructs_2): Handle empty cleanups.
767         * tree.c (free_lang_data_in_decl): Don't clear DECL_INITIAL of
768         static constants.
769         * lto-symtab.c (lto_symtab_register_decl): Accepts DECL_INITIAL
770         for static constants.
771         * lto-streamer-out.c (output_gimple_stmt): Handle GIMPLE_NOP.
772         * lto-streamer-in.c (input_gimple_stmt): Handle GIMPLE_NOP.
773
774 2009-10-08  Richard Guenther  <rguenther@suse.de>
775
776         * gimple.c (free_gimple_type_tables): New function.
777         * gimple.h (free_gimple_type_tables): Declare.
778
779 2009-10-07  Mark Heffernan  <meheff@google.com>
780
781         * ipa-prop.c (ipa_print_node_params) Only print
782         names of named arguments.
783
784 2009-10-08  Rafael Avila de Espindola  <espindola@google.com>
785
786         * gcc.c (LINK_COMMAND_SPEC): Pass libc with -pass-through if it is
787         being statically linked.
788
789 2009-10-08  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
790
791         * collect2.c (add_lto_object): Only define if OBJECT_FORMAT_NONE.
792
793 2009-10-08  Jan Hubicka  <jh@suse.cz>
794
795         PR bootstrap/41620
796         * ipa.c (cgraph_externally_visible_p,
797         function_and_variable_visibility,
798         whole_program_function_and_variable_visibility): Skip non-finalized
799         nodes.
800
801 2009-10-08  Nick Clifton  <nickc@redhat.com>
802
803         * config/mn10300/mn10300.h (CONSTANT_ADDRESS_P): Do not allow
804         CONST_DOUBLEs.
805
806 2009-10-08  Andreas Tobler  <a.tobler@schweiz.org>
807
808         PR bootstrap/37739
809         * config.host: Use config/x-cflags-O1 for powerpc FreeBSD.
810
811 2009-10-07  Joseph Myers  <joseph@codesourcery.com>
812
813         PR c/41182
814         * c-common.c (c_fully_fold_internal): Strip nops from the result
815         of recursive calls to c_fully_fold_internal.
816         (c_wrap_maybe_const): New.
817         (c_save_expr): Use c_wrap_maybe_const.
818         * c-common.h (c_wrap_maybe_const): Declare.
819         * c-typeck.c (build_conditional_expr, c_finish_stmt_expr,
820         build_binary_op): Use c_wrap_maybe_const.
821
822 2009-10-07  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
823
824         * real.c: Fix comment to reflect actual exponent size.
825
826 2009-10-08  Ben Elliston  <bje@au.ibm.com>
827
828         * config/rs6000/a2.md: Add FSF comment header.
829
830 2009-10-07  Uros Bizjak  <ubizjak@gmail.com>
831
832         * config/i386/i386.md (any_extend): New code iterator.
833         (u, s): New code attributes.
834         (sgnprefix): Ditto.
835         (DWIH): Rewrite as code iterator for SI and DI modes.
836         (DWI): Rewrite as mode attribute.
837         (dwi): New mode attribute.
838         (di): Depend on SI mode and DI mode.
839         (doubleint_general_operand): Remove mode attribute.
840
841         (*lea_1): Macroize insn from *lea_1_rex64 and *lea_1 patterns using
842         DWIH mode iterator.
843
844         (*add<mode>3_doubleword): Use DWIH as the base mode iterator.
845         (*sub<mode>3_doubleword): Ditto.
846
847         (mul<mode>3): Macroize expander from mul{hi,si,di}3 patterns
848         using SWIM248 mode iterator.
849         (*mul<mode>3_1): Macroize insn from mul{si,di}3_1 patterns
850         using SWI48 mode iterator.
851         (<u>mul<mode><dwi>3): Macroize expander from {,u}mul{sidi,diti}3
852         patterns using DWIH mode iterator and any_extend code iterator.
853         (<u>mulqihi3): Macroize expander from {,u}mulqihi3 patterns
854         using any_extend code iterator.
855         (*<u>mul<mode><dwi>3_1): Macroize insn from {,u}mul{sidi,diti}3_1
856         patterns using DWIH mode iterator and any_extend code iterator.
857         (*<u>mulqihi3_1): Macroize insn from {,u}mulqihi3_1 patterns
858         using any_extend code iterator.
859         (<s>mul<mode>3_highpart): Macroize expander from
860         {s,u}mul{si,di}3_highpart patterns using DWIH mode iterator
861         and any_extend code iterator.
862         (*<s>muldi3_highpart_1): Macroize insn from
863         *{s,u}muldi3_highpart_rex64 patterns using any_extend code iterator.
864         (*<s>mulsi3_highpart_1): Macroize insn from *{s,u}mulsi3_highpart_1
865         patterns using any_extend code iterator.
866         (*<s>mulsi3_highpart_zext): Macroize insn from
867         *{s,u}mulsi3_highpart_zext patterns using any_extend code iterator.
868
869 2009-10-07  Jakub Jelinek  <jakub@redhat.com>
870
871         * dwarf2out.c (tree_add_const_value_attribute_for_decl): Don't add
872         DW_AT_const_value if VAR_DIE already has DW_AT_abstract_origin
873         refering to a DIE with DW_AT_const_value.
874
875 2009-10-07  Vladimir Makarov  <vmakarov@redhat.com>
876
877         PR middle-end/22072
878         * ira-lives.c (check_and_make_def_conflict): Process all operands.
879
880 2009-10-06  Jan Hubicka  <jh@suse.cz>
881
882         * cgraph.c (cgraph_node_can_be_local): Handle externally visible nodes
883         correctly.
884
885 2009-10-06  Uros Bizjak  <ubizjak@gmail.com>
886
887         * config/i386/i386.md (*lea_1_rex64, *lea_1, *lea_1_zext,
888         *lea_2_rex64): Move before *add<mode>_1 pattern.
889
890 2009-10-07  Jan Hubicka  <jh@suse.cz>
891
892         * collect2.c (main): Add -fno-whole-program.
893         * gcc.c (set_collect_gcc_options): Do not remove whole program here.
894
895 2009-10-07  Jan Hubicka  <jh@suse.cz>
896
897         * lto-symtab.c (lto_cgraph_replace_node): Assert that inline clones
898         has no address taken.
899         * cgraph.c (cgraph_mark_needed_node): Assert that inline clones are
900         never needed.
901         (cgraph_clone_node): Clear externally_visible flag for clones.
902         * cgraph.h (cgraph_only_called_directly_p,
903         cgraph_can_remove_if_no_direct_calls_p): New predicates.
904         * tree-pass.h (pass_ipa_whole_program_visibility): Declare.
905         * ipa-cp.c (ipcp_cloning_candidate_p): Use new predicate.
906         (ipcp_initialize_node_lattices, ipcp_estimate_growth,
907         ipcp_insert_stage): Likwise.
908         * cgraphunit.c (cgraph_decide_is_function_needed): Do not compute
909         externally_visible flag.
910         (verify_cgraph_node): Verify that inline clones look right.
911         (process_function_and_variable_attributes): Do not set
912         externally_visible flags.
913         (ipa_passes): Avoid executing small_ipa_passes at LTO stage; they've
914         been already run.
915         * lto-cgraph.c (lto_output_node): Assert that inline clones are not
916         boundaries.
917         * ipa-inline.c (cgraph_clone_inlined_nodes): Use new predicates;
918         clear externally_visible when turning into inline clones
919         (cgraph_mark_inline_edge): Use new predicates.
920         (cgraph_estimate_growth): Likewise.
921         (cgraph_decide_inlining): Likewise.
922         * ipa.c (cgraph_postorder): Likewise.
923         (cgraph_remove_unreachable_nodes): Likewise; sanity check
924         that inline clones are not needed.
925         (cgraph_externally_visible_p): New predicate.
926         (function_and_variable_visibility): Add whole_program parameter;
927         always set externally_visible flag; handle COMDAT function
928         privatization.
929         (local_function_and_variable_visibility): New function.
930         (gate_whole_program_function_and_variable_visibility): New function.
931         (whole_program_function_and_variable_visibility): New function.
932         (pass_ipa_whole_program_visibility): New function.
933         * passes.c  (init_optimization_passes): Add whole program visibility
934         pass.
935         (do_per_function_toporder, function_called_by_processed_nodes_p): Do
936         not care about needed/reachable flags.
937         * varpool.c: Include flags.h
938         (decide_is_variable_needed): When doing LTO assume whole-program mode.
939         (varpool_finalize_decl): When we are in LTO read-back, all variables
940         are analyzed.
941         (varpool_analyze_pending_decls): Skip analyzis of analyzed vars.
942
943 2009-10-07  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
944
945         * config/s390/tpf.h (TARGET_DEFAULT): Remove MASK_HARD_FLOAT and
946         add MASK_HARD_DFP.
947
948 2009-10-07  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
949
950         * config.gcc: Don't include the makefile fragments intended for
951         libgcc.
952         * config/s390/fixdfdi.h: File removed.
953         * config/s390/libgcc-glibc.ver: File removed.
954         * config/s390/s390.h: Remove the fixdfdi.h hack.
955         * config/s390/t-crtstuff: File moved to libgcc dir.
956         * config/s390/t-linux: Likewise.
957         * config/s390/t-tpf: libgcc specific parts removed.
958         * config/s390/t-linux64: Likewise.
959
960 2009-10-06  Jerry Quinn  <jlquinn@optonline.net>
961
962         * Makefile.in (lto-wrapper): Use COMPILER and ALL_COMPILERFLAGS.
963         (lto-compress.o): Likewise.
964
965 2009-10-07  Danny Smith  <dannysmith@users.sourceforge.net>
966
967         PR target/41512
968         * config/i386/winnt.c (i386_pe_determine_dllexport_p): Don't propagate
969         dllexport to class members here.
970         (i386_pe_determine_dllimport_p): Only check static class data for
971         definition.
972         (i386_pe_encode_section_info): Don't recheck DECL_DLLIMPORT_P.
973         * config/i386/winnt-cxx.c (i386_pe_type_dllimport_p): Only check
974         functions for vague linkage.
975         (i386_pe_type_dllexport_p): Fix formatting.
976         (maybe_add_dllexport) New function.
977         (i386_pe_adjust_class_at_definition): Use it to propagate dllexport
978         to class members.
979
980 2009-10-07  Ben Elliston  <bje@au.ibm.com>
981
982         * config/rs6000/a2.md: Remove duplicated lines.
983
984 2009-10-07  Ben Elliston  <bje@au.ibm.com>
985
986         * config.gcc (powerpc*-*-*): Handle a2.
987         * config/rs6000/rs6000.md (cpu): Add ppca2.  Include "a2.md".
988         * config/rs6000/a2.md: New file.
989         * config/rs6000/rs6000.opt (mno-update): New.
990         (mupdate): Return to using a mask, not a var.
991         * config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for a2.
992         (enum processor_type): Add PROCESSOR_PPCA2.
993         * config/rs6000/rs6000.c (ppca2_cost): New costs.
994         (rs6000_override_options): Add "a2" to processor_target_table.
995         Update rs6000_always_hint logic.  Correctly set rs6000_cost for a2.
996         * doc/invoke.texi (RS/6000 and PowerPC Options): Document -mcpu=a2.
997
998 2009-10-06  Uros Bizjak  <ubizjak@gmail.com>
999
1000         * config/i386/i386.md (float<SSEMODEI24:mode><X87MODEF:mode>2):
1001         Use explicit gen_truncxfsf2 and gen_truncxfdf2 references to avoid
1002         reference to nonexistent gen_truncxfxf2 function.
1003
1004 2009-10-06  Uros Bizjak  <ubizjak@gmail.com>
1005
1006         * config/i386/i386.md (SWI48, SDWIM, DWI): New mode iterators.
1007         (DWIH, g, di, doubleint_general_operand): New mode attributes.
1008         (general_operand): Handle TI mode.
1009         (add<mode>3): Macroize expander from add{qi,hi,si,di,ti}3 patterns
1010         using SDWIM mode iterator.
1011         (*add<mode>3_doubleword): New insn_and_split pattern.  Macroize
1012         pattern from *add{di,ti}3_1 patterns and corresponding splitters
1013         using DWI mode iterator.
1014         (add<mode>3_carry): Macroize insn from add{qi,hi,si,di}3_carry
1015         patterns using SWI mode iterator.
1016         (*add<mode>3_cc): Macroize insn from add{si,di}3_cc patterns
1017         using SWI48 mode iterator.
1018         (*add<mode>_1): Ditto from add{si,di}_1 patterns.
1019         (*add<mode>_2): Ditto from add{si,di}_2 patterns.
1020         (*add<mode>_3): Ditto from add{si,di}_3 patterns.
1021         (*add<mode>_5): Ditto from add{si,di}_5 patterns.
1022         (sub<mode>3): Macroize expander from sub{qi,hi,si,di,ti}3 patterns
1023         using SDWIM mode iterator.
1024         (*sub<mode>3_doubleword): New insn_and_split pattern.  Macroize
1025         pattern from *sub{di,ti}3_1 patterns and corresponding splitters
1026         using DWI mode iterator.
1027         (sub<mode>3_carry): Macroize insn from sub{qi,hi,si,di}3_carry
1028         patterns using SWI mode iterator.
1029         (*sub<mode>_1): Ditto from from sub{qi,hi,si,di}_1 patterns.
1030         (*sub<mode>_2): Ditto from sub{qi,hi,si,di}_2 patterns.
1031         (*sub<mode>_3): Ditto from sub{qi,hi,si,di}_3 patterns.
1032         (<plusminus_insn>xf3): Macroize expander from addxf3 and subxf3
1033         patterns using plusminus code iterator.
1034         (<plusminus_insn><mode>3): Macroize expander from add<mode>3 and
1035         sub<mode>3 patterns using plusminus code iterator.
1036         * config/i386/i386.c (override_options): Update the call to
1037         gen_subdi_carry_rex64 for renamed function.
1038         (ix86_expand_int_addcc): Update calls to gen_subdi3_carry_rex64
1039         and gen_adddi3_carry_rex64 for renamed functions.  Use indirect
1040         calls to instruction expanders.
1041
1042 2009-10-06  Martin Jambor  <mjambor@suse.cz>
1043
1044         PR bootstrap/41395
1045         * opts.c (decode_options): Run IPA-SRA at -O2.
1046
1047 2009-10-06  Richard Guenther  <rguenther@suse.de>
1048
1049         * lto-symtab.c (lto_symtab_entry_hash): Hash strings, not pointers.
1050
1051 2009-10-06  Tobias Burnus  <burnus@net-b.de>
1052
1053         PR lto/41591
1054         * doc/invoke.texi (-flto,-fwhole-program): Make clear that the
1055         -flto and -fwhole-program flags can be combined.
1056
1057 2009-10-06  Ryan Mansfield  <rmansfield@qnx.com>
1058
1059         PR driver/41217
1060         * gcc.c (process_command): Check that -o argument was specified.
1061
1062 2009-10-06  Jerry Quinn  <jlquinn@optonline.net>
1063
1064         * gimple.c (gimple_type_hash): Use CONST_CAST_TREE to fix compilation.
1065
1066 2009-10-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1067
1068         * c.opt (Wjump-misses-init): Fix typo to enable for ObjC.
1069         * doc/invoke.texi (Warning Options): Annotate allowed languages
1070         for -Wunsuffixed-float-constants.
1071
1072 2009-10-05  Jakub Jelinek  <jakub@redhat.com>
1073
1074         * dwarf2out.c (modified_type_die): Don't add DW_AT_name to
1075         DW_TAG_{const,volatile}_type if its DW_AT_type already has the
1076         same name and isn't the main variant.
1077
1078         PR debug/41558
1079         * dwarf2out.c (loc_by_reference): Removed.
1080         (dw_loc_list_1): New function.
1081         (dw_loc_list): Remove toplev argument, add want_address argument.
1082         Don't look at decl_by_reference_p at all.  Use dw_loc_list_1.
1083         (loc_list_from_tree) <case VAR_DECL>: Pass want_address rather than
1084         want_address == 2 to dw_loc_list.  For successful dw_loc_list
1085         set have_address to 1 only if want_address is not 0.
1086
1087 2009-10-05  Richard Sandiford  <rdsandiford@googlemail.com>
1088
1089         * config/mips/mips-protos.h (mips_trampoline_code_size): Declare.
1090         * config/mips/mips.h (TRAMPOLINE_SIZE): Redefine as the size of
1091         a code block followed by two pointers.
1092         (TRAMPOLINE_ALIGNMENT): Define to 64 for 32-bit targets too.
1093         * config/mips/mips.c (MIPS_LOAD_PTR): New macro.
1094         (MIPS_MOVE): Likewise.
1095         (MIPS_LUI): Likewise.
1096         (MIPS_JR): Likewise.
1097         (MIPS_BAL): Likewise.
1098         (MIPS_NOP): Likewise.
1099         (mips_asm_trampoline_template): Delete.
1100         (mips_trampoline_code_size): New function.
1101         (mips_trampoline_init): Add shorter sequences for all cases
1102         except Pmode == DImoe && !TARGET_USE_PIC_FN_ADDR_REG.
1103         Calculate the opcodes directly, rather than copying from a template.
1104         Only flush the code part of the trampoline.
1105         (TARGET_ASM_TRAMPOLINE_TEMPLATE): Delete.
1106
1107 2009-10-05  Richard Sandiford  <rdsandiford@googlemail.com>
1108
1109         * config/mips/mips.h (DWARF_FRAME_RETURN_COLUMN): Replace
1110         GP_REG_FIRST + 31 with RETURN_ADDR_REGNUM.
1111         (INCOMING_RETURN_ADDR_RTX): Likewise.
1112         (FUNCTION_PROFILER): Likewise.  Replace GP_REG_FIRST + 1
1113         with AT_REGNUM.
1114         * config/mips/sdemtk.h (FUNCTION_PROFILER): Replace GP_REG_FIRST + 31
1115         with RETURN_ADDR_REGNUM.
1116         (MIPS_SAVE_REG_FOR_PROFILING_P): Likewise.
1117         * config/mips/mips.c (mips16_build_call_stub): Replace
1118         GP_REG_FIRST + 31 with RETURN_ADDR_REGNUM, GP_REG_FIRST + 1
1119         with AT_REGNUM and 31 with RETURN_ADDR_REGNUM.
1120         (mips_print_operand_punctuation): Likewise.
1121         (mips_frame_set): Likewise.
1122         (mips16e_output_save_restore): Likewise.
1123         (mips_cfun_might_clobber_call_saved_reg_p): Likewise.
1124         (mips_save_reg_p): Likewise.
1125         (mips_return_addr): Likewise.
1126         (mips_set_return_address): Likewise.
1127         (mips_direct_save_slot_move_p): Likewise.
1128         (mips_output_function_prologue): Likewise.
1129         (mips_restore_reg): Likewise.
1130         (mips_expand_epilogue): Likewise.
1131         (mips_epilogue_uses): Likewise.
1132         * config/mips/mips.md (RETURN_ADD_REGNUM): Define.
1133         (*mov<mode>_ra): Use it instead of a hard-coded 31.
1134         (clear_hazard_<mode>): Likewise.
1135         (call_internal): Likewise.
1136         (call_internal_direct): Likewise.
1137         (call_direct_split): Likewise.
1138         (call_value_internal): Likewise.
1139         (call_value_split): Likewise.
1140         (call_value_internal_direct): Likewise.
1141         (call_value_direct_split): Likewise.
1142         (call_value_multiple_internal): Likewise.
1143         (call_value_multiple_split): Likewise.
1144
1145 2009-10-05  Eric Botcazou  <ebotcazou@adacore.com>
1146             Jakub Jelinek  <jakub@redhat.com>
1147
1148         PR rtl-optimization/41511
1149         * combine.c (record_value_for_reg): Pass explicit values as argument
1150         to get_last_value_validate.
1151         (get_last_value_validate): Document INSN parameter.
1152         For non-readonly MEMs, assume they might have been modified if INSN
1153         was in another basic block.
1154         (get_last_value): Minor reformatting.
1155
1156 2009-10-05  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1157
1158         PR tree-opt/40992
1159         * final.c (asm_str_count): Split out from asm_insn_count.
1160         * rtl.h (asm_str_count): New prototype.
1161         * tree-inline (estimate_num_insns) <case GIMPLE_ASM>: Call
1162         asm_str_count.
1163
1164 2009-10-05  Sriraman Tallam  <tmsriram@google.com>
1165
1166         * doc/plugins.texi: Change plugin_pass to register_pass_info.
1167
1168 2009-10-05  Basile Starynkevitch  <basile@starynkevitch.net>
1169             Rafael Espindola  <espindola@google.com>
1170
1171         * gengtype.c (write_types): Moved call to write_func_for_structure
1172         into seperate loops.
1173
1174 2009-10-05  Richard Guenther  <rguenther@suse.de>
1175
1176         PR lto/41281
1177         * lto-cgraph.c (output_cgraph): Output toplevel asms.
1178         (input_cgraph_1): Input toplevel asms.
1179
1180 2009-10-05  Richard Guenther  <rguenther@suse.de>
1181
1182         PR lto/40902
1183         * lto-symtab.c (lto_compatible_attributes_p): Remove.
1184         (external_aggregate_decl_p): Likewise.
1185         (lto_symtab_compatible): Re-structure.  Remove dead code.
1186         For variables ignore toplevel qualifiers when comparing types.
1187         Issue warnings, not errors for mismatched user-alignment.
1188
1189 2009-10-05  Richard Guenther  <rguenther@suse.de>
1190
1191         PR lto/41552
1192         PR lto/41487
1193         * lto-symtab.c (struct lto_symtab_base_def): Remove.
1194         (struct lto_symtab_identifier_def): Likewise.
1195         (struct lto_symtab_decl_def): Likewise.
1196         (struct lto_symtab_entry_def): New.
1197         (lto_symtab_identifier_t): Rename to ...
1198         (lto_symtab_entry_t): ... this.
1199         (lto_symtab_decls): Remove.
1200         (lto_symtab_base_hash): Rename to ...
1201         (lto_symtab_entry_hash): ... this.
1202         (lto_symtab_base_eq): Rename to ...
1203         (lto_symtab_entry_eq): ... this.
1204         (lto_symtab_base_marked_p): Rename to ...
1205         (lto_symtab_entry_marked_p): ... this.
1206         (lto_symtab_identifier_marked_p): Remove.
1207         (lto_symtab_decl_marked_p): Likewise.
1208         (lto_symtab_maybe_init_hash_tables): Rename to ...
1209         (lto_symtab_maybe_init_hash_table): ... this.
1210         (lto_symtab_set_resolution_and_file_data): Remove.
1211         (lto_symtab_register_decl): New function.
1212         (lto_symtab_get_identifier): Remove.
1213         (lto_symtab_get): New function.
1214         (lto_symtab_get_resolution): Adjust.
1215         (lto_symtab_get_identifier_decl): Remove.
1216         (lto_symtab_set_identifier_decl): Likewise.
1217         (lto_symtab_merge_decl): Rename to ...
1218         (lto_symtab_merge): ... this.  Rewrite.
1219         (lto_symtab_merge_var): Remove.
1220         (lto_symtab_merge_fn): Likewise.
1221         (lto_symtab_prevailing_decl): Adjust.
1222         (lto_cgraph_replace_node): New function.
1223         (lto_symtab_merge_decls_2): Likewise.
1224         (lto_symtab_merge_decls_1): Likewise.
1225         (lto_symtab_fixup_var_decls): Likewise.
1226         (lto_symtab_resolve_symbols): Likewise.
1227         (lto_symtab_merge_decls): Likewise.
1228         (lto_symtab_prevailing_decl): Adjust.
1229         (lto_symtab_get_symtab_def): Remove.
1230         (lto_symtab_get_file_data): Likewise.
1231         (lto_symtab_clear_resolution): Adjust.
1232         (lto_symtab_clear_resolution): Likewise.
1233         * lto-cgraph.c (input_edge): Do not merge cgraph nodes here.
1234         (input_cgraph_1): Likewise.
1235         * lto-streamer-in.c (get_resolution): Do not provide fake
1236         symbol resolutions here.
1237         (deferred_global_decls): Remove.
1238         (lto_register_deferred_decls_in_symtab): Likewise.
1239         (lto_register_var_decl_in_symtab): Change signature, register
1240         variable via lto_symtab_register_decl.
1241         (lto_register_function_decl_in_symtab): Likewise.
1242         (lto_read_tree): Adjust.
1243         * lto-streamer.h (lto_register_deferred_decls_in_symtab): Remove.
1244         (lto_symtab_merge_var): Likewise.
1245         (lto_symtab_merge_fn): Likewise.
1246         (lto_symtab_register_decl): Declare.
1247         (lto_symtab_merge_decls): Likewise.
1248
1249 2009-10-05  Richard Guenther  <rguenther@suse.de>
1250
1251         PR tree-optimization/23821
1252         * tree-vrp.c (vrp_finalize): Do not perform copy propagation.
1253         * tree-ssa-dom.c (cprop_operand): Do not propagate copies into
1254         simple IV increments.
1255
1256 2009-10-05  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
1257
1258         * config/arm/arm.c (arm_override_options): Really initialize
1259         flag_dwarf2_cfi_asm to 0.
1260
1261 2009-10-05  Doug Kwan  <dougkwan@google.com>
1262
1263         PR rtl-optimization/41574
1264         * combine.c (distribute_and_simplify_rtx): Quit if RTX mode is
1265         floating point and we are not doing unsafe math optimizations.
1266
1267 2009-10-03  Simon Baldwin  <simonb@google.com>
1268             Cary Coutant  <ccoutant@google.com>
1269             Rafael Espindola  <espindola@google.com>
1270             Richard Guenther  <rguenther@suse.de>
1271             Jan Hubicka  <jh@suse.cz>
1272             Doug Kwan <dougkwan@google.com>
1273             H.J. Lu  <hongjiu.lu@intel.com>
1274             Bill Maddox  <maddox@google.com>
1275             Ryan Mansfield  <rmansfield@qnx.com>
1276             Diego Novillo  <dnovillo@google.com>
1277             Ollie Wild  <aaw@google.com>
1278             Kenneth Zadeck <zadeck@naturalbridge.com>
1279
1280         * lto-cgraph.c: New file.
1281         * lto-compress.c: New file.
1282         * lto-compress.h: New file.
1283         * lto-opts.c: New file.
1284         * lto-section-in.c: New file.
1285         * lto-section-out.c: New file.
1286         * lto-streamer-in.c: New file.
1287         * lto-streamer-out.c: New file.
1288         * lto-streamer.c: New file.
1289         * lto-streamer.h: New file.
1290         * lto-symtab.c: New file.
1291         * lto-wpa-fixup.c: New file.
1292         * lto-wrapper.c: New file.
1293
1294 2009-10-03  Simon Baldwin  <baldwin@google.com>
1295             Ben Elliston  <bje@au.ibm.com>
1296             Rafael Espindola  <espindola@google.com>
1297             Nathan Froyd  <froydnj@codesourcery.com>
1298             Jan Hubicka  <jh@suse.cz>
1299             Doug Kwan  <dougkwan@google.com>
1300             Diego Novillo  <dnovillo@google.com>
1301             Kenneth Zadeck  <zadeck@naturalbridge.com>
1302
1303         * Makefile.in (enable_lto): New.
1304         (site.exp): If @enable_lto@ is set to 'yes' define ENABLE_LTO.
1305         (LINKER_PLUGIN_API_H): Define.
1306         (LTO_SYMTAB_H): Define.
1307         (LTO_STREAMER_H): Define.
1308         (TREE_VECTORIZER_H): Define.
1309         (INCLUDES): Add LIBELFINC.
1310         (OBJS-common): Add lto-cgraph.o, lto-streamer-in.o,
1311         lto-streamer-out.o, lto-section-in.o, lto-section-out.o, lto-symtab.o,
1312         lto-opts.o, lto-streamer.o, lto-wpa-fixup.o, lto-compress.o.
1313         (MOSTLYCLEANFILES): Add lto-wrapper$(exeext)
1314         (native): Add lto-wrapper$(exeext)
1315         (lto-compress.o, lto-cgraph.o, lto-streamer-in.o,
1316         lto-streamer-out.o, lto-section-in.o, lto-section-out.o,
1317         lto-symtab.o, lto-opts.o, lto-streamer.o, lto-wpa-fixup.o): New rules.
1318         (gimple.o): Add dependency on LTO_HEADER_H and LTO_SECTION_OUT_H.
1319         (varasm.o): Add dependency on tree-iterator.h.
1320         (cgraph.o): Add dependency on cif-code.def.
1321         (ipa-reference.o): Add dependency on LTO_STREAMER_H.
1322         (ipa-pure-const.o): Likewise.
1323         (GTFILES): Add lto-symtab.c.
1324         (install-lto-wrapper): New.
1325         * configure.ac: If 'lto' is in enable_languages, define ENABLE_LTO
1326         and enable_lto.  If LIBELFLIBS is set, define HAVE_libelf.
1327         * config.in: Regenerate.
1328
1329 2009-10-03  Rafael Espindola  <espindola@google.com>
1330             Diego Novillo  <dnovillo@google.com>
1331
1332         * cgraphunit.c (ipa_passes): Prevent lto1 from calling
1333         ipa_write_summaries.
1334         Call execute_ipa_summary_passes for all_regular_ipa_passes and
1335         all_lto_gen_passes.
1336         (cgraph_optimize): Make extern.
1337
1338 2009-10-03  Nathan Froyd  <froydnj@codesourcery.com>
1339             Kenneth Zadeck <zadeck@naturalbridge.com>
1340
1341         * toplev.c (in_lto_p): Declare.
1342         * collect2.c (scan_prog_file): Read all the output when reading
1343         information for LTO.
1344         (enum lto_mode_d): Declare.
1345
1346 2009-10-03  Richard Guenther  <rguenther@suse.de>
1347             Diego Novillo  <dnovillo@google.com>
1348
1349         * gimple.c: Include target.h and alias.h.
1350         (gimple_types): Declare.
1351         (type_hash_cache): Declare.
1352         (gimple_alloc_stat): Make extern.
1353         (gimple_build_eh_must_not_throw): Call
1354         gimple_eh_must_not_throw_set_fndecl.
1355         (struct type_pair_d): Declare.
1356         (type_pair_t): Declare.
1357         (type_pair_hash): New.
1358         (type_pair_eq): New.
1359         (lookup_type_pair): New.
1360         (gimple_force_type_merge): New.
1361         (compare_type_names_p): New.
1362         (compare_field_offset): New.
1363         (gimple_types_compatible_p): New.
1364         (struct sccs): Declare.
1365         (next_dfs_num): Declare.
1366         (iterative_hash_gimple_type): New.
1367         (visit): New.
1368         (iterative_hash_type_name): New.
1369         (iterative_hash_gimple_type): New.
1370         (gimple_type_hash): New.
1371         (gimple_type_eq): New.
1372         (gimple_register_type): New.
1373         (print_gimple_types_stats): New.
1374         (gimple_signed_or_unsigned_type): New.
1375         (gimple_unsigned_type): New.
1376         (gimple_signed_type): New.
1377         (gimple_get_alias_set): New.
1378         (gimple_decl_printable_name): Do not use DMGL_TYPES.
1379         * gimple.h (gimple_alloc, gimple_alloc_stat): Declare.
1380         (gimple_force_type_merge): Declare.
1381         (gimple_types_compatible_p): Declare.
1382         (gimple_register_type): Declare.
1383         (print_gimple_types_stats): Declare.
1384         (gimple_unsigned_type): Declare.
1385         (gimple_signed_type): Declare.
1386         (gimple_get_alias_set): Declare.
1387         (gimple_eh_must_not_throw_set_fndecl): New.
1388
1389 2009-10-03  Jan Hubicka  <jh@suse.cz>
1390             Kenneth Zadeck <zadeck@naturalbridge.com>
1391
1392         * ipa-pure-const.c: Include lto-streamer.h.
1393         (register_hooks): Factor out of ...
1394         (generate_summary): ... here.
1395         (pure_const_write_summary): New.
1396         (pure_const_read_summary): New.
1397         (pass_ipa_pure_const): Add pure_const_write_summary and
1398         pure_const_read_summary.
1399         * ipa-reference.c: Include lto-streamer.h.
1400         (add_new_function): New.
1401         (remove_node_data): New.
1402         (duplicate_node_data): New.
1403         (ipa_init): Guard against multiple calls.
1404         Move hook setup from analyze_function.
1405         (write_node_summary_p): New.
1406         (ipa_reference_write_summary): New.
1407         (ipa_reference_read_summary): New.
1408         (pass_ipa_reference): Add ipa_reference_write_summary and
1409         ipa_reference_read_summary.
1410         * cgraph.h (cgraph_local_info): Add field lto_file_data.
1411         (struct cgraph_edge): Add fields lto_stmt_uid and
1412         call_stmt_cannot_inline_p.
1413         (cgraph_optimize): Declare.
1414         (cgraph_decide_is_function_needed): Declare.
1415         (reset_inline_failed): Declare.
1416         (enum LTO_cgraph_tags): Declare.
1417         (LTO_cgraph_tag_names): Declare.
1418         (LCC_NOT_FOUND): Define.
1419
1420 2009-10-03  Doug Kwan  <dougkwan@google.com>
1421             Rafael Espindola  <espindola@google.com>
1422             Jan Hubicka  <jh@suse.cz>
1423             Diego Novillo  <dnovillo@google.com>
1424             Kenneth Zadeck  <zadeck@naturalbridge.com>
1425
1426         * passes.c (all_regular_ipa_passes): New.
1427         (all_ipa_passes): Rename to all_small_ipa_passes.
1428         (init_optimization_passes): Init all_regular_ipa_passes.
1429         * tree-pass.h (all_regular_ipa_passes): New.
1430         (all_ipa_passes): Rename to all_small_ipa_passes.
1431         * passes.c (all_lto_gen_passes): New.
1432         (init_optimization_passes): Initialize all_lto_gen_passes.
1433         (execute_ipa_summary_passes): Make non-static.
1434         (ipa_write_summaries_1): New.
1435         (ipa_write_summaries_2): New.
1436         (ipa_write_summaries): New.
1437         (ipa_write_summaries_of_cgraph_node_set): New.
1438         (ipa_read_summaries_1): New.
1439         (ipa_read_summaries): New.
1440         (execute_ipa_pass_list): Call cgraph_process_new_functions.
1441         (execute_regular_ipa_pass_list): Remove.
1442         (init_optimization_passes): Schedule
1443         pass_rebuild_cgraph_edges and pass_early_inline outside
1444         of pass_all_early_optimizations.  Document reason.
1445         (pass_ipa_lto_gimple_out, pass_ipa_lto_wpa_fixup,
1446         pass_ipa_lto_finish_out): New pass.
1447         (pass_ipa_summary_passes): Start and stop timers if the pass has them.
1448         (execute_all_ipa_transforms): New.
1449         (execute_one_pass): Don't call execute_one_ipa_transform_pass.
1450         (dump_properties, debug_properties): New.
1451         * tree-optimize.c (gate_all_early_local_passes): Return
1452         false if we are in lto1.
1453         (tree_rest_of_compilation): Call execute_all_ipa_transforms.
1454         * tree-pass.h (execute_all_ipa_transforms): Declare.
1455         (pass_ipa_function_and_variable_visibility): Declare.
1456         (pass_ipa_early_inline): Declare.
1457         (pass_ipa_lto_gimple_out): Declare.
1458         (pass_ipa_lto_wpa_fixup): Declare.
1459         (pass_ipa_lto_finish_out): Declare.
1460         (all_small_ipa_passes, all_regular_ipa_passes,
1461         all_lto_gen_passes): Declare.
1462         (execute_ipa_summary_passes): Declare.
1463         (execute_all_ipa_transforms): Declare.
1464         (ipa_write_summaries): Declare
1465         (ipa_write_summaries_of_cgraph_node_set): Declare.
1466         (ipa_read_summaries): Declare.
1467
1468 2009-10-03  Doug Kwan  <dougkwan@google.com>
1469             Ollie Wild  <aaw@google.com>
1470
1471         * ipa-prop.c (ipa_propagate_indirect_call_infos): Do nothing in WPA.
1472
1473         * collect2.c (LTO_MODE_NONE, LTO_MODE_LTO, LTO_MODE_WPA): New enums.
1474         (lto_mode): New variable.
1475         (maybe_run_lto_and_relink): Handle the -fwpa option.
1476         (main): Handle the -fwpa option.
1477         (maybe_unlink_list): New function.
1478         * gcc.c (link_lto_options): Replace -flto with -fwpa.
1479         * common.opt (flto): New flag.
1480         * toplev.c (flag_generate_lto): Declare.
1481
1482 2009-10-03  Simon Baldwin  <simonb@google.com>
1483
1484         * common.opt (flto-compression-level): New flag.
1485
1486         * opts.c: Include lto-opts.h.
1487         (handle_option): Call lto_register_user_option for each
1488         valid option handled.
1489         (decode_options): Clear registered options before the options
1490         handling loop.
1491
1492 2009-10-03  Cary Coutant  <ccoutant@google.com>
1493
1494         * collect2.c (is_elf): New function.
1495         (scan_prog_file): Require LTO object to be in ELF format.
1496
1497 2009-10-03  Rafael Espindola  <espindola@google.com>
1498
1499         * gcc.c (LINK_COMMAND_SPEC): Use the -pass-through option to pass
1500         libgcc to the linker.
1501
1502         * ipa-cp.c (cgraph_gate_cp): Return false if LTRANS is running.
1503
1504         * collect2.c (maybe_run_lto_and_relink): Execute lto-wrapper.
1505         (collect_execute): Add flags argument. Pass flags to pex_run. Update
1506         all callers.
1507         * collect2.h (collect_execute): Add flags argument.
1508         * tlink.c (tlink_execute): Update call to collect_execute.
1509         * gcc.c (main): Set the COLLECT_LTO_WRAPPER environment variable.
1510         (use_linker_plugin): New.
1511         (use_linker_plugin_spec_function): New.
1512         (LINK_COMMAND_SPEC): Pass plugin options to the linker.
1513         (linker_plugin_file_spec): New.
1514         (lto_wrapper_spec): New.
1515         (lto_gcc_spec): New.
1516         (static_specs): Add linker_plugin_file, lto_wrapper and lto_gcc.
1517         (static_spec_functions): Add use-linker-plugin.
1518         (process_command): Handle -use-linker-plugin.
1519         (main): Use lto_wrapper_spec instead of lto_wrapper. Set
1520         linker_plugin_file_spec and lto_gcc_spec.
1521         (use_linker_plugin_spec_function): New.
1522
1523 2009-10-03  Richard Guenther  <rguenther@suse.de>
1524
1525         PR lto/41547
1526         PR lto/41548
1527         * tree.h (is_lang_specific): Include LANG_TYPE.
1528         * tree.c (find_decls_types_r): Manually add interesting parts
1529         of TYPE_FIELDS.  Walk BINFO_VIRTUALS.  Do not walk TYPE_METHODS.
1530
1531         * gimple.c (type_pair_hash): Make symmetric.
1532         (type_pair_eq): Likewise.
1533         (lookup_type_pair): Increase initial hashtable size.
1534         (gimple_force_type_merge): Rely on type-pair symmetry.
1535         (visit): Remove excessive checking code.
1536         (iterative_hash_type_name): Do not hash TYPE_NAME of anonymous unions.
1537         (gimple_register_type): Remove getenv calls, shrink initial
1538         hashtable size.
1539
1540         PR middle-end/41502
1541         * cgraphunit.c (ipa_passes): Do not remove bodies of extern
1542         inline functions if not generating lto output.
1543
1544         PR lto/41379
1545         * toplev.c (finalize): In WPA mode remove the asm file.
1546
1547 2009-10-03  Doug Kwan  <dougkwan@google.com>
1548
1549         * ipa-inline.c (cgraph_mark_inline): Check
1550         edge->call_stmt_cannot_inline_p instead of calling
1551         gimple_call_cannot_inline_p.
1552         (cgraph_decide_inlining): Do nothing in WPA and LTRANS.
1553         (cgraph_gate_ipa_early_inlining): Return false if in_lto_p is set.
1554         (inline_generate_summary): Do nothing in LTRANS.
1555         * cgraph.c (initialize_inline_failed): Make sure e->call_stmt
1556         exists before calling gimple_call_cannot_inline_p.
1557         (cgraph_create_edge): Set edge->call_stmt_cannot_inline_p.
1558         (cgraph_clone_edge): Add argument STMT_UID.  Modify all callers.
1559         Update new_edge->lto_stmt_uid.
1560         * cgraphbuild.c (reset_inline_failed): New.
1561
1562         * common.opt (fwpa): New flag.
1563         (fltrans): New option.
1564         * gcc.c (gcc_lto_option_t): New type.
1565         (current_lto_option): New variable.
1566         (lto_single_spec_function): Remove and is replaced by ..
1567         (lto_option_spec_function): New function.
1568         (LINK_COMMAND_SPEC): Use link_lto_option spec instead of just
1569         passing the -flto flag.
1570         (cc1_options): Separate non-LTO related parts into ..
1571         (cc1_non_lto_options): Non-LTO related options shared by all FEs.
1572         (lto1_options): New spec for lto FE.
1573         (link_lto_options): New spec for handling LTO flags in linker.
1574         (invoke_lto_single): Re-format to fit in 80 column.  Replace
1575         lto-single with lto-option.
1576         (static_specs): Add cc1_non_lto_options, lto1_options and
1577         link_lto_options.
1578         (static_spec_function): Replace lto-single with lto-option.
1579         (process_command): Handle -flto, -fwpa and -fltran by setting
1580         current_lto_option and not passing it to subprocess unconditionally.
1581
1582 2009-10-03  Bill Maddox  <maddox@google.com>
1583
1584         Add `gcc' driver support for link-time code generation (LTO).
1585
1586         * collect2.c (enum pass): Add new literal PASS_LTOINFO.
1587         (lto_flag, lto_objects, lto_o_file): New variables.
1588         (struct lto_object, struct lto_object_list): New structures.
1589         (collect_exit, handler): Remove LTO temporary output file on exit.
1590         (add_lto_object): New function.
1591         (maybe_run_lto_and_relink): New function. Perform link time code
1592         generation and relinking for object files containing LTO information.
1593         (main): Invoke maybe_run_lto_and_relink().
1594         (dump_argv): New function.  For debugging, currently disabled.
1595         (scan_prog_file): Add LTO information pass.
1596         * gcc.c (LINK_COMMAND_SPEC): Pass `-flto' switch to linker, i.e.,
1597         collect2.
1598         * toplev.c (compile_file): Emit assembler directive to create
1599         the `gnu_lto_v1' marker symbol when compiling with `-flto'.
1600
1601 2009-10-03  Diego Novillo  <dnovillo@google.com>
1602
1603         * c.opt: Add LTO to warn_abi and warn_psabi.
1604
1605         * tree.c (fld_worklist_push): Rename from PUSH.  Convert to static
1606         inline function.  Ignore language-specific nodes.  Update all users.
1607         (find_decls_types_r): Do not traverse the subtrees of
1608         language-specific nodes.  Do not traverse DECL_INITIAL for TYPE_DECLs.
1609         * tree.h (is_lang_specific): New.
1610         * langhooks.h (struct lang_hooks_for_decls): Remove
1611         may_need_assembler_name_p.  Update all users.
1612
1613         * c-common.c (set_builtin_user_assembler_name): Move ...
1614         * builtins.c (set_builtin_user_assembler_name): ... here.
1615         (is_builtin_name): Add comment
1616         (is_builtin_fn): New.
1617         * except.c (output_ttype): Only call
1618         lookup_type_for_runtime if TYPE is not a runtime type.
1619
1620         * passes.c (register_pass): Call position_pass on
1621         all_small_ipa_passes, all_regular_ipa_passes and all_lto_gen_passes.
1622         * timevar.def (TV_IPA_LTO_GIMPLE_IO): Define.
1623         (TV_IPA_LTO_DECL_IO): Define.
1624         (TV_IPA_LTO_CGRAPH_IO): Define.
1625         (TV_LTO): Define.
1626         (TV_WHOPR_WPA): Define.
1627         (TV_WHOPR_WPA_IO): Define.
1628         (TV_WHOPR_LTRANS): Define.
1629         (TV_WHOPR_WPA_FIXUP): Define.
1630         (TV_WHOPR_WPA_LTRANS_EXEC): Define.
1631         * tree-cfg.c (tree_node_can_be_shared): Make extern.
1632         * tree-flow.h (tree_node_can_be_shared): Declare.
1633         * tree-inline.c (tree_can_inline_p): Check that E has a
1634         statement associated with it.
1635         * tree.c (free_lang_data_in_binf): Factor out of ...
1636         (free_lang_data_in_type): ... here.
1637         Call RECORD_OR_UNION_TYPE_P.
1638         (need_assembler_name_p): Ignore DECL if it does not have TREE_PUBLIC
1639         set.  Call lang_hooks.decls.may_need_assembler_name_p if set.
1640         (free_lang_data_in_decl): Do not clear DECL_CONTEXT for CONST_DECLs.
1641         (free_lang_data): Set debug_info_level to DINFO_LEVEL_NONE.  Set
1642         write_symbols to NO_DEBUG.  Set debug_hooks to do_nothing_debug_hooks.
1643         (gate_free_lang_data): Return true if flag_generate_lto is set.
1644         (walk_tree_1): Call RECORD_OR_UNION_TYPE_P.
1645         * c-common.h (set_builtin_user_assembler_name): Move ...
1646         * tree.h (set_builtin_user_assembler_name): ... here.
1647
1648         * common.opt (flto-report): New flag.
1649         * opts.c (complain_wrong_lang): Do not complain if running lto1.
1650         * collect2.c (scan_prog_file): Send the error output of
1651         'nm' to HOST_BIT_BUCKET.
1652
1653 2009-10-03  Ollie Wild  <aaw@google.com>
1654
1655         * langhooks-def.h (lhd_begin_section): New function declaration.
1656         (lhd_write_section): New function declaration.
1657         (lhd_end_section): New function declaration.
1658         (LANG_HOOKS_BEGIN_SECTION): New macro.
1659         (LANG_HOOKS_WRITE_SECTION_DATA): New macro.
1660         (LANG_HOOKS_END_SECTION): New macro.
1661         (LANG_HOOKS_LTO): New macro.
1662         (LANG_HOOKS_INITIALIZER): Add LANG_HOOKS_LTO.
1663         * langhooks.c (output.h): Add include.
1664         (saved_section): New static variable.
1665         (lhd_begin_section): New function.
1666         (lhd_write_section_data): New function.
1667         (lhd_end_section): New function.
1668         * langhooks.h (struct lang_hooks_for_lto): New structure.
1669         (struct lang_hooks): Add member lto.
1670         * Makefile.in (langhooks.o): Add dependency on output.h.
1671
1672         * c-opts.c (c_common_post_options): Handle -flto and -fwhopr.
1673
1674 2009-10-03  Richard Guenther  <rguenther@suse.de>
1675
1676         * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
1677         Handle LTO.
1678
1679 2009-10-03  Simon Baldwin  <simonb@google.com>
1680             Richard Guenther  <rguenther@suse.de>
1681             Janis Johnson  <janis187@us.ibm.com>
1682             Doug Kwan  <dougkwan@google.com>
1683             Diego Novillo  <dnovillo@google.com>
1684             Ramana Radhakrishnan  <ramana.r@gmail.com>
1685             Ollie Wild  <aaw@google.com>
1686
1687         * doc/install.texi: Add documentation for libelf and --enable-lto.
1688         * doc/invoke.texi: Document -fwpa, -flto, -fwhopr, -fltrans,
1689         -flto-report, -flto-compression-level and -use-linker-plugin.
1690         * doc/sourcebuild.texi: Document use of zlib.  Document lto-plugin.
1691         Add section for LTO Testing.
1692
1693 2009-10-02  Cary Coutant  <ccoutant@google.com>
1694
1695         Add support for comdat type sections for DWARF v4.
1696         Merge from dwarf4 branch.
1697
1698         * dwarf2out.c (DWARF_TYPE_SIGNATURE_SIZE): New constant.
1699         (dw_die_ref): Define vector type.
1700         (enum dw_val_class): Add dw_val_class_data8.
1701         (struct dw_val_struct): Add v.val_data8.
1702         (comdat_type_node_ref): New type.
1703         (struct die_struct): Move die_symbol into a union; add new field
1704         die_type_node.  Change all uses.
1705         (comdat_type_node): New type.
1706         (skeleton_chain_node): New type.
1707         (DWARF_COMDAT_TYPE_UNIT_HEADER_SIZE): New constant.
1708         (comdat_type_list): New variable.
1709         (dwarf_tag_name): Add DW_TAG_type_unit.
1710         (dwarf_attr_name): Add DW_AT_signature.
1711         (add_AT_data8): New function.
1712         (replace_child): New function.
1713         (move_all_children): New function.
1714         (print_signature): New function.
1715         (print_die): Print signature information; add dw_val_class_data8.
1716         (attr_checksum): Support dw_val_class_data8.
1717         (CHECKSUM_STRING): Redefine for DWARF-4 to include trailing NULL byte.
1718         (CHECKSUM_SLEB128, CHECKSUM_ULEB128): New macros.
1719         (checksum_sleb128, checksum_uleb128): New functions.
1720         (checksum_die_context): New function.
1721         (loc_checksum_ordered): New function.
1722         (attr_checksum_ordered): New function.
1723         (struct checksum_attributes): New structure.
1724         (collect_checksum_attributes): New function.
1725         (die_checksum_ordered): New function.
1726         (generate_type_signature): New function.
1727         (same_dw_val_p): Add dw_val_class_data8.
1728         (is_symbol_die): Use new is_declaration_die function.
1729         (is_declaration_die): New function.
1730         (should_move_die_to_comdat): New function.
1731         (clone_die): New function.
1732         (clone_tree): New function.
1733         (clone_as_declaration): New function.
1734         (copy_declaration_context): New function.
1735         (generate_skeleton_ancestor_tree): New function.
1736         (generate_skeleton_bottom_up): New function.
1737         (generate_skeleton): New function.
1738         (remove_child_or_replace_with_skeleton): New function.
1739         (break_out_comdat_types): New function.
1740         (struct decl_table_entry): New type.
1741         (htab_decl_hash): New function.
1742         (htab_decl_eq): New function.
1743         (htab_decl_del): New function.
1744         (copy_ancestor_tree): New function.
1745         (copy_decls_walk): New function.
1746         (copy_decls_for_unworthy_types): New function.
1747         (build_abbrev_table): Don't assert on missing die_symbol when doing
1748         comdat type sections.
1749         (size_of_die): Use DW_FORM_sig8 for external references.  Add
1750         dw_val_class_data8.
1751         (unmark_dies): Don't assert for unmarked dies when doing comdat
1752         type sections.
1753         (value_format): Support DW_FORM_sig8 and dw_val_class_data8.
1754         (output_signature): New function.
1755         (output_die): Likewise.
1756         (output_compilation_unit_header): Mark output as DWARF version 3
1757         even if generating DWARF 4.
1758         (output_comdat_type_unit): New function.
1759         (output_line_info): Mark output as DWARF version 3 even if generating
1760         DWARF 4.
1761         (dwarf2out_start_source_file): Don't do eliminate_dwarf2_dups with
1762         DWARF-4.
1763         (dwarf2out_end_source_file): Likewise.
1764         (prune_unused_types_walk_attribs): Don't follow references into
1765         comdat type sections.
1766         (prune_unused_types_mark): When generating type units, do not mark
1767         children of non-defining declarations of types; do mark children of
1768         type entries.
1769         (prune_unused_types): Process comdat type sections.
1770         (htab_ct_hash): New function.
1771         (htab_ct_eq): New function.
1772         (dwarf2out_finish): Move types to comdat sections when using DWARF-4.
1773         Add a pointer to the line table from type unit entries so
1774         DW_AT_decl_file has meaning.
1775         * varasm.c (default_elf_asm_named_section): Use identifier name as
1776         comdat key instead of lang hook.
1777
1778 2009-10-02  Neil Vachharajani  <nvachhar@google.com>
1779
1780         * gcov-io.c (gcov_open): Open files read-only when MODE < 0.
1781
1782 2009-10-02  Uros Bizjak  <ubizjak@gmail.com>
1783
1784         * config/i386/i386.md (SWIM248): New mode iterator.
1785         (divmod<mode>4) Macroize expander from divmoddi4, divmodsi4 and
1786         divmodhi4 patterns using SWIM248 macro.
1787         (*divmod<mode>4): Macroize insn_and_split pattern from
1788         *divmoddi4_cltd_rex64, *divmodsi4_cltd and divmodhi4 insn patterns
1789         and their corresponding splitters usign SWIM248 macro.  Split SImode
1790         insn to generate cltd and DImode insn to generate cqto instead of
1791         move+shift when optimizing for size or TARGET_USE_CLTD is in effect.
1792         (*divmoddi4_nocltd_rex64, *divmodsi4_nocltd): Remove insn patterns.
1793         (*divmod<mode>4_noext): Macroize insn from *divmoddi_noext_rex64 and
1794         *divmodsi_noext patterns using SWIM248 macro.
1795         (udivmod<mode>4): Macroize expander from udivmoddi4, udivmodsi4 and
1796         udivmodhi4 patterns using SWIM248 macro.
1797         (*udivmod<mode>4): Macroize insn_and_split pattern from
1798         *udivmoddi4, udivmodsi4 and udivmodhi4 patterns and their
1799         corresponding splitters using SWIM248 macro.
1800         (*udivmod<mode>4_noext): Macroize insn from *udivmoddi4_noext,
1801         *udivmodsi4_noext and *udivmodhi_noext patterns using SWIM248 macro.
1802
1803 2009-10-02  Eric Botcazou  <ebotcazou@adacore.com>
1804
1805         * stor-layout.c (layout_type) <ARRAY_TYPE>: Make sure that an array
1806         of zero-sized element is zero-sized regardless of its extent.
1807
1808 2009-10-02  Jakub Jelinek  <jakub@redhat.com>
1809
1810         PR debug/40521
1811         * configure.ac (HAVE_GAS_CFI_SECTIONS_DIRECTIVE): New test.
1812         * configure: Regenerated.
1813         * config.in: Regenerated.
1814         * dwarf2out.c (dwarf2out_do_cfi_asm): Return false if
1815         !HAVE_GAS_CFI_SECTIONS_DIRECTIVE and not emitting .eh_frame.
1816         (dwarf2out_init): If HAVE_GAS_CFI_SECTIONS_DIRECTIVE and
1817         not emitting .eh_frame, emit .cfi_sections .debug_frame
1818         directive.
1819
1820         PR debug/41404
1821         PR debug/41353
1822         * cfgexpand.c (expand_debug_expr) <case STRING_CST>: Don't create
1823         CONST_STRING if STRING_CST contains embedded '\0's or doesn't end
1824         with '\0'.
1825         (expand_debug_expr) <case VAR_DECL>: For TREE_STATIC !DECL_EXTERNAL
1826         vars use DECL_RTL with resetting it back to NULL afterwards.
1827         * dwarf2out.c (same_dw_val_p): For dw_val_class_addr compare with
1828         rtx_equal_p instead of asserting it is a SYMBOL_REF.
1829         (value_format): For dw_val_class_addr only use DW_FORM_addr if
1830         the attribute type allows it, otherwise use DW_FORM_dataN.
1831         (mem_loc_descriptor): Handle CONST_STRING.
1832         (add_const_value_attribute): Handle CONST_STRING using add_AT_addr.
1833         Handle MEM with CONST_STRING address using add_AT_string.
1834         (rtl_for_decl_init): Return MEM with CONST_STRING address instead of
1835         CONST_STRING for const arrays initialized with a string literal.
1836         (resolve_one_addr, resolve_addr_in_expr, resolve_addr): New functions.
1837         (dwarf2out_finish): Call resolve_addr.
1838
1839 2009-10-02  Andreas Schwab  <schwab@linux-m68k.org>
1840             Maxim Kuvyrkov  <maxim@codesourcery.com>
1841
1842         * config/m68k/lb1sf68.asm (PICCALL): Use variable sized branch.
1843
1844 2009-10-02  Nick Clifton  <nickc@redhat.com>
1845
1846         * config/mn10300/mn10300.h (USER_LABEL_PREFIX): Define.
1847         (ASM_OUTPUT_LABELREF): Use asm_fprintf and %U.
1848
1849 2009-10-01  Jan Hubicka  <jh@suse.cz>
1850
1851         * cgraph.c (cgraph_clone_node): Add redirect_callers parameter.
1852         (cgraph_create_virtual_clone): Just pass redirect_callers
1853         around.
1854         * cgraph.h (cgraph_clone_node): Update prototype.
1855         * ipa-pure-const.c (self_recursive_p): New function.
1856         (propagate): Use it.
1857         * ipa-inline.c (cgraph_clone_inlined_nodes,
1858         cgraph_decide_recursive_inlining): Update.
1859
1860 2009-10-01  David Daney  <ddaney@caviumnetworks.com>
1861
1862         * gcc/config/mips/mips.c (mips_process_sync_loop) Emit syncw
1863         instructions for TARGET_OCTEON.
1864
1865 2009-10-01  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
1866
1867         * config/arm/arm.c (arm_override_options): Turn off
1868         flag_dwarf2_cfi_asm for AAPCS variants.
1869
1870 2009-10-01  Martin Jambor  <mjambor@suse.cz>
1871
1872         PR middle-end/12392
1873         * tree-sra.c (convert_callers): Do not call
1874         compute_inline_parameters on one caller more than once.
1875
1876 2009-10-01  Nick Clifton  <nickc@redhat.com>
1877
1878         * config/vax/netbsd-elf.h (NETBSD_CC1_AND_CC1PLUS_SPEC): Define as
1879         an empty string if not already defined.
1880
1881 2009-10-01  Martin Jambor  <mjambor@suse.cz>
1882
1883         PR bootstrap/41395
1884         * tree-sra.c (is_va_list_type): New function.
1885         (find_var_candidates): Call is_va_list_type.
1886         (find_param_candidates): Check that the type or the type pointed
1887         to are not va_list types.
1888
1889 2009-10-01  Martin Jambor  <mjambor@suse.cz>
1890
1891         PR c++/41503
1892         * cp/pt.c (function_parameter_expanded_from_pack_p): Return false if
1893         DECL_ARTIFICIAL (param_decl) is true.
1894
1895 2009-09-30  Gabriel Dos Reis  <gdr@cs.tamu.edu>
1896
1897         * tree.h (tree_decl_common::lang_flag_8): New.
1898         * c-common.c (c_common_reswords): Include "constexpr" as C++0x
1899         keyword.
1900         * c-common.h (RID_CONSTEXPR): New.
1901
1902 2009-09-30  Uros Bizjak  <ubizjak@gmail.com>
1903
1904         * config/alpha/alpha.c (alpha_gimplify_va_arg_1):
1905         Use ref-all pointers.
1906         (alpha_gimplify_va_arg): Ditto.
1907
1908 2009-09-30  Jakub Jelinek  <jakub@redhat.com>
1909
1910         PR target/41279
1911         * cfgloopanal.c (num_loop_insns): Don't increment ninsns for each bb
1912         before insn counting loop now that BB_END (bb) is counted.  Ensure
1913         the return value isn't zero.
1914
1915 2009-09-30  Nick Clifton  <nickc@redhat.com>
1916
1917         * config.gcc (sh-symbianelf): Replace definition of extra_objs
1918         with separate definitions of c_target_objs and cxx_target_objs.
1919         * config/sh/t-sh: Add rules to build symbian-cxx.o, symbian-c.o
1920         and symbian-base.o.
1921         * config/sh/sh.c (TARGET_CXX_INPUT_EXPORT_CLASS): Use
1922         sh_symbian_import_export_class.
1923         * config/sh/sh-protos.h: Fix names of exported symbian functions.
1924         * config/sh/symbian.c: Delete, moving code into...
1925         * config/sh/symbian-base.c: ... here
1926         * config/sh/symbian-c.c: ... and here
1927         * config/sh/symbian-cxx.c: ... and here.
1928
1929 2009-09-30  Uros Bizjak  <ubizjak@gmail.com>
1930
1931         PR target/22093
1932         * config/alpha/alpha.md (unaligned_storehi_be): Force operand
1933         of plus RTX into register.
1934
1935 2009-09-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1936
1937         * doc/install.texi: Linguistic and markup fixes.
1938         (Configuration) <--disable-cpp>: Remove description.
1939         <--enable-maintainer-mode>: Autotools files are affected, too.
1940         <--with-sysroot>: Improve description.
1941         (Building): Bump required GNU make version.
1942
1943 2009-09-29  Harsha Jagasia  <harsha.jagasia@amd.com>
1944
1945         * config.gcc (i[34567]86-*-*): Include fma4intrin.h.
1946         (x86_64-*-*): Ditto.
1947
1948         * config/i386/fma4intrin.h: New file, provide common x86 compiler
1949         intrinisics for FMA4.
1950         * config/i386/cpuid.h (bit_FMA4): Define FMA4 bit.
1951         * config/i386/x86intrin.h: Fix typo to SSE4A instead of SSE4a.
1952         Add FMA4 check and fma4intrin.h.
1953         * config/i386/i386-c.c(ix86_target_macros_internal): Check
1954         ISA_FLAG for FMA4.
1955         * config/i386/i386.h(TARGET_FMA4): New macro for FMA4.
1956         * config/i386/i386.md (UNSPEC_FMA4_INTRINSIC): Add new UNSPEC
1957         constant for FMA4 support.
1958         (UNSPEC_FMA4_FMADDSUB): Ditto.
1959         (UNSPEC_FMA4_FMSUBADD): Ditto.
1960         * config/i386/i386.opt (-mfma4): New switch for FMA4 support.
1961         * config/i386/i386-protos.h (ix86_fma4_valid_op_p): Add declaration.
1962         (ix86_expand_fma4_multiple_memory): Ditto.
1963         * config/i386/i386.c (OPTION_MASK_ISA_FMA4_SET): New.
1964         (OPTION_MASK_ISA_FMA4_UNSET): New.
1965         (OPTION_MASK_ISA_SSE4A_UNSET): Change definition to depend on FMA4.
1966         (OPTION_MASK_ISA_AVX_UNSET): Change definition to depend on FMA4.
1967         (ix86_handle_option): Handle -mfma4.
1968         (isa_opts): Handle -mfma4.
1969         (enum pta_flags): Add PTA_FMA4.
1970         (override_options): Add FMA4 support.
1971         (IX86_BUILTIN_VFMADDSS): New for FMA4 intrinsic.
1972         (IX86_BUILTIN_VFMADDSD): Ditto.
1973         (IX86_BUILTIN_VFMADDPS): Ditto.
1974         (IX86_BUILTIN_VFMADDPD): Ditto.
1975         (IX86_BUILTIN_VFMSUBSS): Ditto.
1976         (IX86_BUILTIN_VFMSUBSD): Ditto.
1977         (IX86_BUILTIN_VFMSUBPS): Ditto.
1978         (IX86_BUILTIN_VFMSUBPD): Ditto.
1979         (IX86_BUILTIN_VFMADDSUBPS): Ditto.
1980         (IX86_BUILTIN_VFMADDSUBPD): Ditto.
1981         (IX86_BUILTIN_VFMSUBADDPS): Ditto.
1982         (IX86_BUILTIN_VFMSUBADDPD): Ditto.
1983         (IX86_BUILTIN_VFNMADDSS): Ditto.
1984         (IX86_BUILTIN_VFNMADDSD): Ditto.
1985         (IX86_BUILTIN_VFNMADDPS): Ditto.
1986         (IX86_BUILTIN_VFNMADDPD): Ditto.
1987         (IX86_BUILTIN_VFNMSUBSS): Ditto.
1988         (IX86_BUILTIN_VFNMSUBSD): Ditto.
1989         (IX86_BUILTIN_VFNMSUBPS): Ditto.
1990         (IX86_BUILTIN_VFNMSUBPD): Ditto.
1991         (IX86_BUILTIN_VFMADDPS256): Ditto.
1992         (IX86_BUILTIN_VFMADDPD256): Ditto.
1993         (IX86_BUILTIN_VFMSUBPS256): Ditto.
1994         (IX86_BUILTIN_VFMSUBPD256): Ditto.
1995         (IX86_BUILTIN_VFMADDSUBPS256): Ditto.
1996         (IX86_BUILTIN_VFMADDSUBPD256): Ditto.
1997         (IX86_BUILTIN_VFMSUBADDPS256): Ditto.
1998         (IX86_BUILTIN_VFMSUBADDPD256): Ditto.
1999         (IX86_BUILTIN_VFNMADDPS256): Ditto.
2000         (IX86_BUILTIN_VFNMADDPD256): Ditto.
2001         (IX86_BUILTIN_VFNMSUBPS256): Ditto.
2002         (IX86_BUILTIN_VFNMSUBPD256): Ditto.
2003         (enum multi_arg_type): New enum for describing the various FMA4
2004         intrinsic argument types.
2005         (bdesc_multi_arg): New table for FMA4 intrinsics.
2006         (ix86_init_mmx_sse_builtins): Add FMA4 intrinsic support.
2007         (ix86_expand_multi_arg_builtin): New function for creating FMA4
2008         intrinsics.
2009         (ix86_expand_builtin): Add FMA4 intrinsic support.
2010         (ix86_fma4_valid_op_p): New function to validate FMA4 3 and 4
2011         operand instructions.
2012         (ix86_expand_fma4_multiple_memory): New function to split the
2013         second memory reference from FMA4 instructions.
2014         * config/i386/sse.md (ssemodesuffixf4): New mode attribute for FMA4.
2015         (ssemodesuffixf2s): Ditto.
2016         (fma4_fmadd<mode>4): Add FMA4 floating point multiply/add
2017         instructions.
2018         (fma4_fmsub<mode>4): Ditto.
2019         (fma4_fnmadd<mode>4): Ditto.
2020         (fma4_fnmsub<mode>4): Ditto.
2021         (fma4_vmfmadd<mode>4): Ditto.
2022         (fma4_vmfmsub<mode>4): Ditto.
2023         (fma4_vmfnmadd<mode>4): Ditto.
2024         (fma4_vmfnmsub<mode>4): Ditto.
2025         (fma4_fmadd<mode>4256): Ditto.
2026         (fma4_fmsub<mode>4256): Ditto.
2027         (fma4_fnmadd<mode>4256): Ditto.
2028         (fma4_fnmsub<mode>4256): Ditto.
2029         (fma4_fmaddsubv8sf4): Ditto.
2030         (fma4_fmaddsubv4sf4): Ditto.
2031         (fma4_fmaddsubv4df4): Ditto.
2032         (fma4_fmaddsubv2df4): Ditto.
2033         (fma4_fmsubaddv8sf4): Ditto.
2034         (fma4_fmsubaddv4sf4): Ditto.
2035         (fma4_fmsubaddv4df4): Ditto.
2036         (fma4_fmsubaddv2df4): Ditto.
2037         (fma4i_fmadd<mode>4): Add FMA4 floating point multiply/add
2038         instructions for intrinsics.
2039         (fma4i_fmsub<mode>4): Ditto.
2040         (fma4i_fnmadd<mode>4): Ditto.
2041         (fma4i_fnmsub<mode>4): Ditto.
2042         (fma4i_vmfmadd<mode>4): Ditto.
2043         (fma4i_vmfmsub<mode>4): Ditto.
2044         (fma4i_vmfnmadd<mode>4): Ditto.
2045         (fma4i_vmfnmsub<mode>4): Ditto.
2046         (fma4i_fmadd<mode>4256): Ditto.
2047         (fma4i_fmsub<mode>4256): Ditto.
2048         (fma4i_fnmadd<mode>4256): Ditto.
2049         (fma4i_fnmsub<mode>4256): Ditto.
2050         (fma4i_fmaddsubv8sf4): Ditto.
2051         (fma4i_fmaddsubv4sf4): Ditto.
2052         (fma4i_fmaddsubv4df4): Ditto.
2053         (fma4i_fmaddsubv2df4): Ditto.
2054         (fma4i_fmsubaddv8sf4): Ditto.
2055         (fma4i_fmsubaddv4sf4): Ditto.
2056         (fma4i_fmsubaddv4df4): Ditto.
2057         (fma4i_fmsubaddv2df4): Ditto.
2058
2059         * doc/invoke.texi (-mfma4): Add documentation.
2060         * doc/extend.texi (x86 intrinsics): Add FMA4 intrinsics.
2061
2062 2009-09-29  Richard Henderson  <rth@redhat.com>
2063
2064         * tree-eh.c (unsplit_eh): Do not unsplit if there's already
2065         an edge to the new destination block.
2066
2067 2009-09-29  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
2068
2069         PR target/41393
2070         * pa.c (hppa_profile_hook): Use
2071         make_reg_eh_region_note_nothrow_nononlocal to add REG_EH_REGION note.
2072
2073 2009-09-29  Steve Ellcey  <sje@cup.hp.com>
2074             Alexander Monakov  <amonakov@ispras.ru>
2075
2076         PR target/41365
2077         * config/ia64/predicates.md (not_postinc_destination_operand): New.
2078         (not_postinc_memory_operand): New.
2079         (not_postinc_move_operand): New.
2080         * config/ia64/ia64.md (*cmovdi_internal): Disallow autoincrement.
2081         (*cmovsi_internal): Ditto.
2082
2083 2009-09-29  Pat Haugen  <pthaugen@us.ibm.com>
2084
2085         * config/rs6000/rs6000.c (rs6000_issue_rate): Don't artificially
2086         restrict issue_rate in first pass when scheduling for register
2087         pressure.
2088
2089 2009-09-29  Basile Starynkevitch  <basile@starynkevitch.net>
2090             Rafael Avila de Espindola  <espindola@google.com>
2091
2092         * gengtype.c (plugin_output): New.
2093         (get_output_file_with_visibility): Return plugin_output for plugins.
2094         (main): Parse and use the -P option.
2095         * gty.texi: Update the command line format.
2096
2097 2009-09-29  Jakub Jelinek  <jakub@redhat.com>
2098
2099         PR debug/41438
2100         * dwarf2out.c (const_ok_for_output_1, const_ok_for_output): New
2101         functions.
2102         (mem_loc_descriptor, loc_descriptor, add_const_value_attribute): Bail
2103         out if !const_ok_for_output.
2104
2105         PR debug/41474
2106         * dwarf2out.c (mem_loc_descriptor) <case CONCAT, case CONCATN,
2107         case VAR_LOCATION>: Remove gcc_unreachable ().
2108
2109 2009-09-29  Harsha Jagasia  <harsha.jagasia@amd.com>
2110
2111         * config.gcc (i[34567]86-*-*): Remove mmintrin-common.h.
2112         (x86_64-*-*): Ditto.
2113         * config/i386/smmintrin.h: Move instructions in mmintrin-common.h
2114         back to smmintrin.h.
2115         * config/i386/cpuid.h: (bit_SSE5): Remove SSE5 bit.
2116         * config/i386/x86intrin.h: Remove SSE5.
2117         * config/i386/mmintrin-common.h: Delete file.
2118         * doc/extend.texi (x86 intrinsics): Remove SSE5 flags and builtins.
2119
2120 2009-09-29  Richard Guenther  <rguenther@suse.de>
2121
2122         * alias.c (ao_ref_from_mem): Properly deal with off decl accesses
2123         resulting from stack temporaries on STRICT_ALIGNMENT targets.
2124
2125 2009-09-29  Nick Clifton  <nickc@redhat.com>
2126
2127         * function.c (current_function_name): If there is no current
2128         function just return "<none>".
2129
2130 2009-09-28  Sriraman Tallam  <tmsriram@google.com>
2131
2132         * tree-pass.h (register_pass_info): New structure.
2133         (pass_positioning_ops): Move enum from gcc-plugin.h.
2134         (register_pass): New function.
2135         * gcc-plugin.h (plugin_pass): Delete structure.
2136         (pass_positioning_ops): Delete enum.
2137         * plugin.c (regsiter_pass): Delete function.
2138         (position_pass): Delete function.
2139         (added_pass_nodes): Delete variable.
2140         (prev_added_pass_nodes): Delete variable.
2141         (pass_list_node): Delete structure.
2142         * passes.c (make_pass_instance): New function.
2143         (next_pass_1): Change to call make_pass_instance.
2144         (pass_list_node): Move structure from gcc-plugin.h.
2145         (added_pass_nodes): Move variable from plugin.c.
2146         (prev_added_pass_nodes): Move variable from plugin.c.
2147         (position_pass): New function.
2148         (register_pass): New function.
2149
2150 2009-09-28  Easwaran Raman  <eraman@google.com>
2151
2152         * ifcvt.c (noce_try_abs): Recognize pattern and call
2153         expand_one_cmpl_abs_nojump.
2154         * optabs.c (expand_one_cmpl_abs_nojump): New function.
2155         * optabs.h (expand_one_cmpl_abs_nojump): Declare.
2156
2157 2009-09-28  Ian Lance Taylor  <iant@google.com>
2158
2159         PR middle-end/40500
2160         * c-opts.c (c_common_handle_option): Don't set
2161         warn_jump_misses_init for -Wall.
2162         * doc/invoke.texi (Warning Options): Update documentation.
2163
2164 2009-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2165
2166         * Makefile.in ($(out_object_file)): Depend on
2167         gt-$(basename $(notdir $(out_file))).h.
2168
2169 2009-09-28  Richard Henderson  <rth@redhat.com>
2170
2171         * except.h (struct eh_region_d): Add use_cxa_end_cleanup.
2172         * except.c (gen_eh_region): Set it.
2173         (duplicate_eh_regions_1): Copy it.
2174         * tree-eh.c (lower_resx): Use it to determine which function
2175         to call to resume.
2176
2177         * langhooks.h (struct lang_hooks): Add eh_use_cxa_end_cleanup.
2178         * langhooks-def.h (LANG_HOOKS_EH_USE_CXA_END_CLEANUP): New.
2179         * builtins.def (BUILT_IN_CXA_END_CLEANUP): New.
2180         * tree.c (build_common_builtin_nodes): Remove parameter.  Build
2181         BUILT_IN_CXA_END_CLEANUP if necessary.
2182
2183         * c-common.c (c_define_builtins): Update call to
2184         build_common_builtin_nodes.
2185
2186 2009-09-28  Andrew Pinski  <andrew_pinski@playstation.sony.com>
2187
2188         * spu.c (get_branch_target): Return NULL for ASM_OPERANDS patterns.
2189
2190 2009-09-28  Michael Matz  <matz@suse.de>
2191
2192         * builtins.c (interclass_mathfn_icode): New helper.
2193         (expand_builtin_interclass_mathfn): Use it here, and split folding
2194         into ...
2195         (fold_builtin_interclass_mathfn): ... this new folder.
2196         (build_call_nofold_loc): New static helper.
2197         (build_call_nofold): New wrapper macro for above.
2198         (expand_builtin_int_roundingfn): Use it instead of build_call_expr.
2199         (expand_builtin_pow): Ditto.
2200         (expand_builtin_memset_args): Ditto.
2201         (expand_builtin_printf): Ditto.
2202         (expand_builtin_fprintf): Ditto.
2203         (expand_builtin_sprintf): Ditto.
2204         (expand_builtin_memory_chk): Ditto.
2205         (expand_builtin_mempcpy_args): Ditto and don't call folders.
2206         (expand_builtin_stpcpy): Ditto.
2207         (expand_builtin_strcmp): Ditto.
2208         (expand_builtin_strncmp): Ditto.
2209         (expand_builtin_strcpy): Remove FNDECL and MODE arguments.
2210         (expand_builtin_strcpy_args): Don't call folders.
2211         (expand_builtin_memcmp): Ditto.
2212         (expand_builtin_strncpy): Ditto, and use target.
2213         (expand_builtin_memcpy): Ditto.
2214         (expand_builtin_strstr, expand_builtin_strchr, expand_builtin_strrchr,
2215         expand_builtin_strpbrk, expand_builtin_memmove,
2216         expand_builtin_memmove_args, expand_builtin_bcopy,
2217         expand_builtin_memchr, expand_builtin_strcat, expand_builtin_strncat,
2218         expand_builtin_strspn, expand_builtin_strcspn,
2219         expand_builtin_fputs): Remove these.
2220         (expand_builtin): Don't call the above, change calls to other
2221         expanders that changed prototype.
2222         (fold_builtin_stpcpy): New folder split out from expand_builtin_stpcpy.
2223         (fold_builtin_1 <ISFINITE, ISINF, ISNORMAL>): Call
2224         fold_builtin_interclass_mathfn.
2225         (fold_builtin_2 <STPCPY>): Call fold_builtin_stpcpy.
2226         (fold_builtin_strcat): Add folding split from expand_builtin_strcat.
2227
2228         * fold-const.c (fold_binary_loc <NE_EXPR>): Add !exp != 0 -> !exp.
2229         * passes.c (init_optimization_passes): Move pass_fold_builtins
2230         after last phiopt pass.
2231         * tree-inline.c (fold_marked_statements): When folding builtins
2232         iterate over all instruction potentially generated.
2233         * tree-ssa-ccp.c (gimplify_and_update_call_from_tree): Declare
2234         earlier.
2235         (fold_gimple_call): Use it to always fold calls (into potentially
2236         multiple instructions).
2237         * tree-ssa-dom.c (optimize_stmt): Resolve __builtin_constant_p
2238         calls into zero at this time.
2239         * tree-ssa-propagate.c (substitute_and_fold): Ignore multiple
2240         statements generated by builtin folding.
2241
2242 2009-09-28  Nick Clifton  <nickc@redhat.com>
2243
2244         * config/m32r/m32r.c (m32r_is_insn): Return false for debugging insns.
2245
2246 2009-09-28  Duncan Sands  <baldrick@free.fr>
2247
2248         * gcc-plugin.h (PLUGIN_REGISTER_GGC_CACHES): New event.
2249         * plugin.c (plugin_event_name): Add PLUGIN_REGISTER_GGC_CACHES.
2250         (register_callback): Dispatch it.
2251         (invoke_plugin_callbacks): Incorporate in sanity check.
2252         * ggc.h (ggc_register_cache_tab): Add declaration.
2253         * ggc-common.c (ggc_register_root_tab): Simplify.
2254         (const_ggc_cache_tab_t): New typedef.
2255         (extra_cache_vec): New vector of dynamically added cache tables.
2256         (ggc_register_cache_tab): New function.
2257         (ggc_scan_cache_tab): New function.
2258         (ggc_mark_roots): Simplify dynamic roots.  Handle dynamic caches.
2259         * doc/plugins.texi: Document PLUGIN_REGISTER_GGC_CACHES.
2260
2261 2009-09-27  Richard Henderson  <rth@redhat.com>
2262
2263         * tree-ssa-ccp.c (optimize_stack_restore): Relax the conditions under
2264         which we remove __builtin_stack_restore.
2265
2266 2009-09-27  Bernd Schmidt  <bernd.schmidt@analog.com>
2267
2268         * loop-iv.c (iv_analyze_op): Use function_invariant_p, not CONSTANT_P,
2269         to test for GRD_INVARIANT.
2270         (simple_rhs_p): Anything that's function_invariant_p is fine.
2271
2272 2009-09-27  Rafael Avila de Espindola  <espindola@google.com>
2273
2274         * gengtype.c (main): Use plunge_files instead of plugin_output.
2275
2276 2009-09-27  Basile Starynkevitch  <basile@starynkevitch.net>
2277             Rafael Avila de Espindola  <espindola@google.com>
2278
2279         * gengtype.c (write_root, write_roots): Add a emit_pch argument.
2280         Don't print pch related info if it is false.
2281         (main): Don't print pch info in plugin mode.
2282
2283 2009-09-27  Eric Botcazou  <ebotcazou@adacore.com>
2284
2285         * dwarf2out.c (enum dw_val_class): Replace dw_val_class_long_long
2286         with dw_val_class_const_double.
2287         (struct dw_val_struct): Replace val_long_long with val_double and
2288         adjust for above change.
2289         (output_loc_operands): Likewise.
2290         (add_AT_long_long): Rename into...
2291         (add_AT_double): ...this.
2292         (print_die): Replace dw_val_class_long_long with
2293         dw_val_class_const_double and adjust.
2294         (attr_checksum): Likewise.
2295         (same_dw_val_p): Likewise.
2296         (size_of_die): Likewise.
2297         (value_format): Likewise.
2298         (output_die): Likewise.
2299         (loc_descriptor) <CONST_DOUBLE>: Likewise.
2300         (add_const_value_attribute) <CONST_DOUBLE>: Call add_AT_double
2301         instead of add_AT_long_long.
2302         (add_bound_info) <INTEGER_CST>: Generate the bound as an unsigned
2303         value with the precision of its type.
2304
2305 2009-09-27  Andreas Schwab  <schwab@linux-m68k.org>
2306
2307         PR c/41476
2308         * c-typeck.c (build_conditional_expr): Use the readonly and
2309         volatile flags of the operand types, not of the operands itself.
2310
2311 2009-09-27  Peter O'Gorman  <pogma@thewrittenword.com>
2312
2313         * collect2.c (main): Look for -brtl before adding libraries.
2314
2315 2009-09-27  Jonathan Gray  <jsg@openbsd.org>
2316
2317         * config.gcc: Update OpenBSD targets.
2318         * config/openbsd-stdint.h: New file.
2319         * config/openbsd-libpthread.h: New file.
2320         * config/openbsd.h: Update and break out LIB_SPEC definition.
2321         * config/alpha/openbsd.h: Overhaul to reflect ELF migration.
2322         * config/i386/openbsdelf.h: Correct types.
2323         * config/m68k/openbsd.h: Likewise.
2324         * config/mips/openbsd.h: Likewise.
2325         * config/vax/openbsd.h: Likewise.
2326
2327 2009-09-27  Eric Botcazou  <ebotcazou@adacore.com>
2328
2329         * fold-const.c (maybe_lvalue_p): Return false for M(IN|AX)_EXPR.
2330         (extract_muldiv_1) <MINUS_EXPR>: Swap operands if necessary.
2331         * stor-layout.c (layout_type) <ARRAY_TYPE>: Do not take the maximum
2332         of the length and zero.
2333
2334 2009-09-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2335
2336         * Makefile.in (TOPLEV_H): Use $(INPUT_H) not input.h.
2337         (FLAGS_H): Add options.h $(REAL_H).
2338         (SEL_SCHED_IR_H): Add $(BITMAP_H) vecprim.h $(CFGLOOP_H).
2339         (TREE_VECTORIZER_H): New.
2340         (EBITMAP_H): Renamed from EBIMAP_H.
2341         (c-decl.o, c-objc-common.o, c-pretty-print.o, attribs.o, c-omp.o)
2342         (gtype-desc.o, ggc-common.o, ggc-page.o, ggc-zone.o, langhooks.o)
2343         (tree.o, tree-ssa-structalias.o, tree-ssa-ter.o, tree-ssanames.o)
2344         (tree-phinodes.o, tree-ssa-loop.o, tree-ssa-math-opts.o)
2345         (gimple-low.o, omp-low.o, sese.o, graphite-blocking.o)
2346         (graphite-clast-to-gimple.o, graphite-dependences.o)
2347         (graphite-interchange.o, graphite-poly.o, graphite-scop-detection.o)
2348         (graphite-sese-to-poly.o, tree-vect-loop.o, tree-vect-loop-manip.o)
2349         (tree-vect-patterns.o, tree-vect-slp.o, tree-vect-stmts.o)
2350         (tree-vect-data-refs.o, tree-vectorizer.o, gimple.o, tree-mudflap.o)
2351         (targhooks.o, stmt.o, emit-rtl.o, ipa.o, matrix-reorg.o, ipa-inline.o)
2352         (gcse.o, tree-ssa-ccp.o, df-byte-scan.o, vec.o, caller-save.o)
2353         (ira-build.o, ira-costs.o, ira-color.o, ira-emit.o, ira.o)
2354         (haifa-sched.o, sched-rgn.o, sel-sched.o, sel-sched-dump.o)
2355         (sel-sched-ir.o, final.o, $(out_object_file)): Dependencies
2356         updated and fixed as per above changes and per
2357         check_makefile_deps.sh output.
2358
2359         PR bootstrap/40928
2360         * configure.ac: Use $LIBS for '-ldl', not $LDFLAGS.
2361         * configure: Regenerate.
2362
2363 2009-09-26  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
2364
2365         * doc/install.texi: Update minimum MPC version to 0.7.
2366
2367 2009-09-26  Gerald Pfeifer  <gerald@pfeifer.com>
2368
2369         * doc/install.texi (Binaries): Remove reference to the binary
2370         distribution CD-ROM from the FSF.
2371
2372 2009-09-26  Michael Matz  <matz@suse.de>
2373
2374         PR lto/40758
2375         PR middle-end/41470
2376         * tree-ssa-coalesce.c (coalesce_ssa_name): Add only SSA names
2377         that are mentioned in the body.
2378
2379 2009-09-26  Michael Matz  <matz@suse.de>
2380
2381         PR tree-optimization/41454
2382         * tree-ssa-dom (stmts_to_rescan): Remove variable.
2383         (tree_ssa_dominator_optimize): Don't allocate and free it.
2384         (dom_opt_leave_block): Don't iterate over it.
2385         (eliminate_redundant_computations): Don't return a value.
2386         (cprop_operand, cprop_into_stmt): Ditto.
2387         (optimize_stmt): Don't defer updating stmts.
2388
2389 2009-09-25  Dodji Seketeli  <dodji@redhat.com>
2390
2391         * dwarf2out.c (dwarf_tag_name, gen_generic_params_dies,
2392         generic_parameter_die, template_parameter_pack_die,
2393         gen_formal_parameter_die, gen_subprogram_die): Adjust after
2394         renaming DW_TAG_formal_parameter_pack and
2395         DW_TAG_template_parameter_pack into DW_TAG_GNU_formal_parameter_pack
2396         and DW_TAG_GNU_template_parameter_pack.
2397
2398 2009-09-25  Anatoly Sokolov  <aesok@post.ru>
2399
2400         * config/v850/v850.h (FUNCTION_VALUE): Remove.
2401         * config/v850/v850.c (v850_function_value): New function.
2402         (TARGET_FUNCTION_VALUE): Define.
2403
2404 2009-09-25  Jakub Jelinek  <jakub@redhat.com>
2405
2406         * tree-vect-stmts.c (vectorizable_call): Call
2407         mark_symbols_for_renaming after vect_finish_stmt_generation.
2408
2409         * dwarf2out.c (tls_mem_loc_descriptor): Pass 1 instead of 2
2410         to loc_descriptor_from_tree.
2411         (add_location_or_const_value_attribute): Pass 0 instead of 2
2412         for decl_by_reference_p decls.
2413
2414 2009-09-25  Richard Guenther  <rguenther@suse.de>
2415
2416         PR middle-end/41463
2417         * tree-dfa.c (get_ref_base_and_extent): Fix issue with trailing
2418         arrays again.
2419
2420 2009-09-25  Ben Elliston  <bje@au.ibm.com>
2421
2422         * doc/invoke.texi (RS/6000 and PowerPC Options): Add missing comma
2423         after `power7'.
2424
2425 2009-09-25  Alan Modra  <amodra@bigpond.net.au>
2426
2427         * config/rs6000/rs6000.md (load_toc_v4_PIC_3c): Correct POWER
2428         form of instruction.
2429
2430 2009-09-24  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
2431
2432         PR middle-end/41435
2433         * fold-const.c (const_binop): Handle complex int division.
2434         * tree-complex.c (expand_complex_div_straight,
2435         expand_complex_div_wide): Update comments.
2436
2437 2009-09-24  DJ Delorie  <dj@redhat.com>
2438
2439         PR target/41456
2440         * config/m32c/m32c.h (REG_CLASS_CONTENTS): Add R13.
2441         (reg_class): Likewise.
2442         (REG_CLASS_NAMES): Likewise.
2443         * config/m32c/m32c.c (m32c_reg_class_from_constraint): Likewise.
2444         (m32c_override_options): Disable -fivopts for M32C.
2445
2446 2009-09-24  Michael Meissner  <meissner@linux.vnet.ibm.com>
2447
2448         * config/rs6000/predicates.md (indexed_or_indirect_operand):
2449         Delete VSX load/store with update support.
2450         * config/rs6000/rs6000.c (rs6000_legitimate_address_p): Ditto.
2451         * config/rs6000/vsx.md (vsx_mov<mode>): Ditto.
2452         (vsx_movti): Ditto.
2453         (VSX_U): Delete.
2454         (VSbit): Ditto.
2455         (VStype_load_update): Ditto.
2456         (VStype_store_update): Ditto.
2457         (vsx_load<VSX_U:mode>_update_<P:mptrsize>): Ditto.
2458         (vsx_store<VSX_U:mode>_update_<P:mptrsize>): Ditto.
2459
2460         * config/rs6000/rs6000.h (enum rs6000_builtins): Delete VSX
2461         load/store with update builtins.
2462
2463 2009-09-24  Kai Tietz  <kai.tietz@onevision.com>
2464
2465         * libgcc2.c (L_trampoline): Prototype for getpagesize
2466         and mprotect in WINNT case.
2467
2468 2009-09-24  Anatoly Sokolov  <aesok@post.ru>
2469
2470         * config/rs6000/rs6000.h (FUNCTION_VALUE): Remove macro.
2471         * config/rs6000/rs6000-protos.h (rs6000_function_value): Remove.
2472         * config/rs6000/rs6000.c (rs6000_function_value): Make static, add
2473         'outgoing' argument.
2474         (TARGET_FUNCTION_VALUE): Define.
2475
2476 2009-09-24  Iain Sandoe  <iain.sandoe@sandoe-acoustics.co.uk>
2477
2478         * config/darwin.h (DWARF2_DEBUGGING_INFO): Define as 1.
2479
2480 2009-09-24  Iain Sandoe  <iain.sandoe@sandoe-acoustics.co.uk>
2481
2482         PR bootstrap/41405
2483         * common.opt: Initialize dwarf_strict to -1.
2484         * toplev.c (process_options): Catch unset dwarf_strict
2485         and set to 0 for all targets not overriding.
2486         * config/darwin.c (darwin_override_options): Catch unset
2487         dwarf_strict and override to 1.
2488
2489 2009-09-24  Jeff Law  <law@redhat.com>
2490
2491         * tree-into-ssa.c (rewrite_into_ssa): Free interesting_blocks.
2492
2493 2009-09-24  Richard Guenther  <rguenther@suse.de>
2494
2495         PR tree-optimization/36143
2496         PR tree-optimization/38747
2497         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Only
2498         create VIEW_CONVERT_EXPRs for TBAA compatible accesses.
2499
2500 2009-09-24  Jakub Jelinek  <jakub@redhat.com>
2501
2502         PR bootstrap/41457
2503         * dwarf2out.c (add_const_value_attribute): For HIGH and CONST_FIXED,
2504         return false instead of gcc_unreachable ().  For CONST return the
2505         value returned by recursive call instead of always returning true.
2506         (tree_add_const_value_attribute): Return the value returned by
2507         add_const_value_attribute instead of always returning true if rtl
2508         is non-NULL.
2509
2510 2009-09-23  Justin Seyster  <jrseys@gmail.com>
2511
2512         * Makefile.in (PLUGIN_HEADERS): Include real.h.
2513
2514 2009-09-24  Jakub Jelinek  <jakub@redhat.com>
2515
2516         * cgraphunit.c (cgraph_lower_function): Revert last change.
2517         * targhooks.c (default_static_chain): Use !DECL_STATIC_CHAIN
2518         instead of DECL_NO_STATIC_CHAIN.
2519         * tree-cfg.c (verify_gimple_call): Likewise.
2520         * tree-nested.c (get_chain_decl, get_chain_field,
2521         convert_tramp_reference_op, convert_gimple_call): Likewise.
2522         (convert_all_function_calls): Likewise.  Always set or clear
2523         DECL_STATIC_CHAIN initially, for !n->outer clear it.
2524         (lower_nested_functions): Remove DECL_NO_STATIC_CHAIN checking code.
2525         * c-parser.c (c_parser_declaration_or_fndef): Set DECL_STATIC_CHAIN
2526         if nested.
2527         * print-tree.c (print_node): Handle DECL_STATIC_CHAIN instead of
2528         DECL_NO_STATIC_CHAIN.
2529         * config/i386/i386.c (ix86_static_chain): Use !DECL_STATIC_CHAIN
2530         instead of DECL_NO_STATIC_CHAIN.
2531         (ix86_function_regparm, find_drap_reg): Likewise.  Don't test
2532         decl_function_context.
2533         * varasm.c (initializer_constant_valid_p): Likewise.
2534         * tree.h (DECL_NO_STATIC_CHAIN): Renamed to ...
2535         (DECL_STATIC_CHAIN): ... this.
2536         * config/moxie/moxie.c (moxie_static_chain): Use !DECL_STATIC_CHAIN
2537         instead of DECL_NO_STATIC_CHAIN.
2538
2539 2009-09-23  Basile Starynkevitch  <basile@starynkevitch.net>
2540             Rafael Avila de Espindola  <espindola@google.com>
2541
2542         * gengtype.c (nb_plugin_files): Make it unsigned to match
2543         num_gt_files. Adjust other variables to avoid warnings.
2544         (main): Allocate an all zero lang_bitmap before each plugin file name
2545         to match regular file names.
2546
2547 2009-09-23  Richard Henderson  <rth@redhat.com>
2548
2549         * doc/tm.texi (STATIC_CHAIN, STATIC_CHAIN_INCOMING): Remove.
2550         (TARGET_STATIC_CHAIN): Mention that this hook must be used for
2551         static chain passed in memory.
2552         * system.h (STATIC_CHAIN, STATIC_CHAIN_INCOMING): Poison.
2553         * targhooks.c (default_static_chain): Don't handle STATIC_CHAIN,
2554         STATIC_CHAIN_INCOMING.  Issue a sorry if there's no
2555         STATIC_CHAIN_REGNUM defined.
2556
2557         * config/picochip/picochip-protos.h: s/class/klass/.
2558         * config/picochip/picochip.c (TARGET_STATIC_CHAIN): New.
2559         (picochip_static_chain): New.
2560         * config/picochip/picochip.h (STATIC_CHAIN): Remove.
2561         (STATIC_CHAIN_INCOMING): Remove.
2562
2563         * config/xtensa/xtensa.c (TARGET_STATIC_CHAIN): New.
2564         (xtensa_static_chain): New.
2565         * config/xtensa/xtensa.h (STATIC_CHAIN): Remove.
2566         (STATIC_CHAIN_INCOMING): Remove.
2567
2568 2009-09-23  Anatoly Sokolov  <aesok@post.ru>
2569
2570         * config/pa/pa.h (FUNCTION_VALUE): Remove macro.
2571         * config/pa/pa-protos.h (function_value): Remove.
2572         * config/pa/pa.c (pa_function_value): Rename from function_value.
2573         Make static, add 'outgoing' argument.
2574         (TARGET_FUNCTION_VALUE): Define.
2575
2576 2009-09-23  Anatoly Sokolov  <aesok@post.ru>
2577
2578         * config/avr/avr.c (avr_regs_to_save): Use current_function_is_leaf
2579         instead of cfun->machine->is_leaf.
2580         * config/avr/avr.h (machine_function): Remove is_leaf field.
2581
2582 2009-09-23  Jakub Jelinek  <jakub@redhat.com>
2583
2584         PR debug/41439
2585         * dwarf2out.c (address_of_int_loc_descriptor): Don't emit
2586         DW_OP_piece after DW_OP_stack_value, adjust size calculations
2587         for it, when DW_OP_stack_value and DW_OP_implicit_value has
2588         the same size, prefer DW_OP_stack_value.
2589         (loc_descriptor, loc_list_for_address_of_addr_expr_of_indirect_ref,
2590         loc_list_from_tree): Don't emit DW_OP_piece after DW_OP_stack_value.
2591
2592 2009-09-23  Alexandre Oliva  <aoliva@redhat.com>
2593
2594         PR debug/41353
2595         * var-tracking.c (add_with_sets): Sort MO_VAL_LOC last among uses.
2596
2597 2009-09-23  Alexandre Oliva  <aoliva@redhat.com>
2598
2599         PR debug/41248
2600         * cfgexpand.c (convert_debug_memory_address): New.
2601         (expand_debug_expr): Convert base address and offset to the same
2602         mode.  Use it to convert addresses to other modes.  Accept
2603         ptr_mode addresses.
2604
2605 2009-09-23  Richard Guenther  <rguenther@suse.de>
2606
2607         * alias.c (ao_ref_from_mem): Correct for negative MEM_OFFSET
2608         produced for bigendian targets with promoted subregs.
2609
2610 2009-09-23  Richard Guenther  <rguenther@suse.de>
2611
2612         * value-prof.c (gimple_ic): Purge old EH edges only after building
2613         the new ones.
2614
2615 2009-09-23  Nick Clifton  <nickc@redhat.com>
2616
2617         * config/arc/arc.c (arc_trampoline_init): Fix typo.
2618
2619 2009-09-23  Jakub Jelinek  <jakub@redhat.com>
2620
2621         PR bootstrap/41405
2622         * doc/invoke.texi: Document -gstrict-dwarf and -gno-strict-dwarf.
2623
2624         PR bootstrap/41436
2625         * cgraphunit.c (cgraph_lower_function): Set DECL_NO_STATIC_CHAIN
2626         on non-nested functions.
2627
2628 2009-09-23  Jakub Jelinek  <jakub@redhat.com>
2629             Jan Hubicka  <jh@suse.cz>
2630
2631         * dwarf2out.c (loc_list_plus_const): Only define if
2632         DWARF2_DEBUGGING_INFO.
2633         (address_of_int_loc_descriptor): Likewise.
2634
2635         PR debug/41411
2636         * dwarf2out.c (mem_loc_descriptor): Handle HIGH.
2637
2638 2009-09-23  Uros Bizjak  <ubizjak@gmail.com>
2639
2640         PR c/39779
2641         * c-typeck.c (build_binary_op) <short_shift>: Check that integer
2642         constant is more than zero.
2643
2644 2009-09-23  Alan Modra  <amodra@bigpond.net.au>
2645
2646         PR target/40473
2647         * config/rs6000/rs6000.c (rs6000_output_function_prologue): Don't
2648         call final to emit non-scheduled prologue, instead insert at entry.
2649
2650 2009-09-22  Loren J. Rittle  <ljrittle@acm.org>
2651             Joseph S. Myers  <joseph@codesourcery.com>
2652
2653         * doc/install.texi (*-*-freebsd*): Add proper format codes.
2654
2655 2009-09-22  Basile Starynkevitch  <basile@starynkevitch.net>
2656             Rafael Avila de Espindola  <espindola@google.com>
2657
2658         * gengtype.c (is_file_equal): New function.
2659         (close_output_files): Use is_file_equal. Free of->buf.
2660
2661 2009-09-22  Basile Starynkevitch  <basile@starynkevitch.net>
2662             Rafael Avila de Espindola  <espindola@google.com>
2663
2664         * gengtype.c (write_types, write_local): Add the output_header
2665         argument. Update all callers.
2666
2667 2009-09-22  Dodji Seketeli  <dodji@redhat.com>
2668
2669         * dwarf2out.c (template_parameter_pack_die,
2670         gen_formal_parameter_pack_die ): New functions.
2671         (make_ith_pack_parameter_name): Remove this function.
2672         (dwarf_tag_name): Support printing DW_TAG_template_parameter_pack and
2673         DW_TAG_formal_parameter_pack.
2674         (gen_generic_params_dies): Represent each template parameter pack
2675         by a DW_TAG_template_parameter_pack DIE. Argument pack elements are
2676         represented by usual DW_TAG_template_*_parameter DIEs that are
2677         children of the DW_TAG_template_parameter_pack element DIE.
2678         (generic_parameter_die): This doesn't deal with parameter pack
2679         names anymore. Don't generate DW_AT_name for some DIEs, e.g. children
2680         of parameter pack DIEs.
2681         (gen_formal_parameter_die): Add a flag to not emit DW_AT_name
2682         in certain cases, e.g. for pack elements.
2683         (gen_formal_types_die, gen_decl_die): Adjust usage of
2684         gen_formal_parameter_die.
2685         (gen_subprogram_die): Represent each function parameter pack by a
2686         DW_TAG_formal_parameter_pack DIE. Arguments of of the pack are
2687         represented by usual DW_TAG_formal_parameter DIEs that are children
2688         of the DW_TAG_formal_parameter_pack DIE. Remove references to
2689         ____builtin_va_alist decls as no part of the compiler uses those
2690         anymore.
2691         * langhooks.h (struct lang_hooks_for_decls): Add
2692         function_parm_expanded_from_pack_p, get_generic_function_decl
2693         and function_parameter_pack_p hooks.  Fix comment for
2694         get_innermost_generic_parms hook.
2695         * langhooks-def.h (LANG_HOOKS_FUNCTION_PARAMETER_PACK_P,
2696         LANG_HOOKS_FUNCTION_PARM_EXPANDED_FROM_PACK_P ): Declare new hook
2697         macros and use them to initialize lang_hook.
2698
2699 2009-09-22  Richard Henderson  <rth@redhat.com>
2700
2701         * system.h (TRAMPOLINE_TEMPLATE, INITIALIZE_TRAMPOLINE): Poison.
2702         (TRAMPOLINE_ADJUST_ADDRESS): Poison.
2703         * target-def.h (TARGET_ASM_TRAMPOLINE_TEMPLATE): Don't conditionalize
2704         on TRAMPOLINE_TEMPLATE.
2705         (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Don't conditionalize on
2706         TRAMPOLINE_ADJUST_ADDRESS.
2707         * targhooks.c (default_asm_trampoline_template): Remove.
2708         (default_trampoline_adjust_address): Remove.
2709         (default_trampoline_init): Don't handle INITIALIZE_TRAMPOLINE.
2710         * targhooks.h: Update decls.
2711
2712 2009-09-22  Dave Korn  <dave.korn.cygwin@gmail.com>
2713
2714         * config/i386/cygming.h (TARGET_USE_JCR_SECTION): Enable.
2715         * config/i386/cygwin.h (LIBGCJ_SONAME): Define.
2716         * config/i386/mingw32.h (LIBGCJ_SONAME): Likewise.
2717
2718 2009-09-22  Alexandre Oliva  <aoliva@redhat.com>
2719
2720         PR debug/41295
2721         * reload1.c (reload): Reset debug insns with pseudos without
2722         equivalences.
2723
2724 2009-09-22  Janis Johnson  <janis187@us.ibm.com>
2725
2726         * config/i386/i386.c (ix86_scalar_mode_supported_p): Don't return
2727         unconditional true for decimal float modes.
2728         * config/rs6000/rs6000.c (rs6000_scalar_mode_supported_p): Ditto.
2729         * config/s390/s390.c (s390_scalar_mode_supported_p): Ditto.
2730
2731 2009-09-22  Loren J. Rittle  <ljrittle@acm.org>
2732
2733         * unwind-dw2-fde-glibc.c: Define and use USE_PT_GNU_EH_FRAME.
2734         Enable a new case for __FreeBSD__ >= 7.
2735         * crtstuff.c:  Define USE_PT_GNU_EH_FRAME for __FreeBSD__ >= 7.
2736         * config/t-freebsd: Define LIB2ADDEH and LIB2ADDEHDEP.
2737         * config/freebsd-spec.h: Conditionally define LINK_EH_SPEC
2738         and USE_LD_AS_NEEDED.
2739
2740         * doc/install.texi (*-*-freebsd*): Update target information.
2741
2742 2009-09-22  Richard Guenther  <rguenther@suse.de>
2743
2744         PR middle-end/41395
2745         * tree-dfa.c (get_ref_base_and_extent): Handle trailing
2746         arrays really properly.
2747
2748 2009-09-22  Richard Henderson  <rth@redhat.com>
2749
2750         PR target/41246
2751         * target.h (struct gcc_target): Add asm_out.trampoline_template,
2752         calls.static_chain, calls.trampoline_init,
2753         calls.trampoline_adjust_address.
2754         * target-def.h (TARGET_ASM_TRAMPOLINE_TEMPLATE): New.
2755         (TARGET_STATIC_CHAIN, TARGET_TRAMPOLINE_INIT): New.
2756         (TARGET_TRAMPOLINE_ADJUST_ADDRESS): New.
2757         * builtins.c (expand_builtin_setjmp_receiver): Use
2758         targetm.calls.static_chain; only clobber registers.
2759         (expand_builtin_init_trampoline): Use targetm.calls.trampoline_init;
2760         set up memory attributes properly for the trampoline block.
2761         (expand_builtin_adjust_trampoline): Use
2762         targetm.calls.trampoline_adjust_address.
2763         * calls.c (prepare_call_address): Add fndecl argument.  Use
2764         targetm.calls.static_chain.
2765         * df-scan.c (df_need_static_chain_reg): Remove.
2766         (df_get_entry_block_def_set): Use targetm.calls.static_chain;
2767         consolodate static chain handling.
2768         * doc/tm.texi: Document new hooks.
2769         * emit-rtl.c (static_chain_rtx, static_chain_incoming_rtx): Remove.
2770         (init_emit_regs): Don't initialize them.
2771         * expr.h (prepare_call_address): Update decl.
2772         * final.c (profile_function): Use targetm.calls.static_chain.
2773         * function.c (expand_function_start): Likewise.
2774         * rtl.h (static_chain_rtx, static_chain_incoming_rtx): Remove.
2775         * stmt.c (expand_nl_goto_receiver): Use targetm.calls.static_chain;
2776         only clobber registers.
2777         * targhooks.c (default_static_chain): New.
2778         (default_asm_trampoline_template, default_trampoline_init): New.
2779         (default_trampoline_adjust_address): New.
2780         * targhooks.h: Declare them.
2781         * varasm.c (assemble_trampoline_template): Use
2782         targetm.asm_out.trampoline_template.  Make the memory block const
2783         and set its size.
2784
2785         * config/alpha/alpha.c (alpha_trampoline_init): Rename from
2786         alpha_initialize_trampoline.  Make static.  Merge VMS parameter
2787         differences into the TARGET_ABI_OPEN_VMS code block.
2788         (TARGET_TRAMPOLINE_INIT): New.
2789         * config/alpha/alpha.h (TRAMPOLINE_TEMPLATE): Remove.
2790         (TRAMPOLINE_SECTION, INITIALIZE_TRAMPOLINE): Remove.
2791         * config/alpha/vms.h (TRAMPOLINE_SIZE, TRAMPOLINE_ALIGNMENT): Remove.
2792         (INITIALIZE_TRAMPOLINE): Remove.
2793
2794         * config/arc/arc.h (TRAMPOLINE_ALIGNMENT): New.
2795         (TRAMPOLINE_TEMPLATE): Merge with ...
2796         (INITIALIZE_TRAMPOLINE): ... this and move ...
2797         * config/arc/arc.c (arc_trampoline_init): ... here.
2798         (TARGET_TRAMPOLINE_INIT): New.
2799
2800         * config/arm/arm.c (TARGET_ASM_TRAMPOLINE_TEMPLATE): New.
2801         (TARGET_TRAMPOLINE_INIT, TARGET_TRAMPOLINE_ADJUST_ADDRESS): New.
2802         (arm_asm_trampoline_template): New.
2803         (arm_trampoline_init, arm_trampoline_adjust_address): New.
2804         * config/arm/arm.h (TRAMPOLINE_TEMPLATE, ARM_TRAMPOLINE_TEMPLATE,
2805         THUMB2_TRAMPOLINE_TEMPLATE, THUMB1_TRAMPOLINE_TEMPLATE): Move all
2806         code to arm_asm_trampoline_template.
2807         (TRAMPOLINE_ADJUST_ADDRESS): Move code to
2808         arm_trampoline_adjust_address.
2809         (INITIALIZE_TRAMPOLINE): Move code to arm_trampoline_init;
2810         adjust for target hook parameters.
2811
2812         * config/avr/avr.h (TRAMPOLINE_TEMPLATE, INITIALIZE_TRAMPOLINE):
2813         Remove.
2814
2815         * config/bfin/bfin-protos.h (initialize_trampoline): Remove.
2816         * config/bfin/bfin.c (bfin_asm_trampoline_template): New.
2817         (bfin_trampoline_init): Rename from initialize_trampoline;
2818         make static; update for target hook parameters.
2819         (TARGET_ASM_TRAMPOLINE_TEMPLATE, TARGET_TRAMPOLINE_INIT): New.
2820         * config/bfin/bfin.h (TRAMPOLINE_TEMPLATE): Move code to
2821         bfin_asm_trampoline_template.
2822         (INITIALIZE_TRAMPOLINE): Remove.
2823
2824         * config/cris/cris.c (TARGET_ASM_TRAMPOLINE_TEMPLATE,
2825         TARGET_TRAMPOLINE_INIT, cris_asm_trampoline_template,
2826         cris_trampoline_init): New.
2827         * config/cris/cris.h (TRAMPOLINE_TEMPLATE): Move code to
2828         cris_asm_trampoline_template.
2829         (INITIALIZE_TRAMPOLINE): Move code to cris_trampoline_init;
2830         adjust for target hook parameters.
2831
2832         * config/crx/crx.h (INITIALIZE_TRAMPOLINE): Remove.
2833
2834         * config/fr30/fr30.c (TARGET_ASM_TRAMPOLINE_TEMPLATE,
2835         TARGET_TRAMPOLINE_INIT, fr30_asm_trampoline_template,
2836         fr30_trampoline_init): New.
2837         * config/fr30/fr30.h (TRAMPOLINE_TEMPLATE): Move code to
2838         fr30_asm_trampoline_template.
2839         (INITIALIZE_TRAMPOLINE): Move code to fr30_trampoline_init;
2840         adjust for target hook parameters.
2841
2842         * config/frv/frv.c (TARGET_TRAMPOLINE_INIT): New.
2843         (frv_trampoline_init): Rename from frv_initialize_trampoline;
2844         make static, adjust arguments for TARGET_TRAMPOLINE_INIT hook.
2845         * config/frv/frv.h (INITIALIZE_TRAMPOLINE): Remove.
2846         * config/frv/frv-protos.h (frv_initialize_trampoline): Remove.
2847
2848         * config/h8300/h8300.c (h8300_trampoline_init): New.
2849         (TARGET_TRAMPOLINE_INIT): New.
2850         * config/h8300/h8300.h (INITIALIZE_TRAMPOLINE): Move code
2851         to h8300_trampoline_init and adjust for hook parameters.
2852
2853         * config/ia64/ia64-protos.h (ia64_initialize_trampoline): Remove.
2854         * config/ia64/ia64.c (TARGET_TRAMPOLINE_INIT): New.
2855         (ia64_trampoline_init): Rename from ia64_initialize_trampoline;
2856         make static; adjust for hook parameters.
2857         * config/ia64/ia64.h (INITIALIZE_TRAMPOLINE): Remove.
2858
2859         * config/iq2000/iq2000.c (TARGET_ASM_TRAMPOLINE_TEMPLATE): New.
2860         (TARGET_TRAMPOLINE_INIT): New.
2861         (iq2000_asm_trampoline_template, iq2000_trampoline_init): New.
2862         * config/iq2000/iq2000.h (TRAMPOLINE_TEMPLATE): Move code to
2863         iq2000_asm_trampoline_template.
2864         (INITIALIZE_TRAMPOLINE): Move code to iq2000_trampoline_init.
2865         (TRAMPOLINE_CODE_SIZE): New.
2866         (TRAMPOLINE_SIZE): Use it.
2867         (TRAMPOLINE_ALIGNMENT): Follow Pmode.
2868
2869         * config/m32c/m32c-protos.h (m32c_initialize_trampoline): Remove.
2870         * config/m32c/m32c.c (TARGET_TRAMPOLINE_INIT): New.
2871         (m32c_trampoline_init): Rename from m32c_initialize_trampoline;
2872         adjust for hook parameters.
2873         * config/m32c/m32c.h (INITIALIZE_TRAMPOLINE): Remove.
2874
2875         * config/m32r/m32r.c (TARGET_TRAMPOLINE_INIT): New.
2876         (m32r_trampoline_init): New.
2877         * config/m32r/m32r.h (INITIALIZE_TRAMPOLINE): Move code to
2878         m32r_trampoline_init.
2879
2880         * config/m68hc11/m68hc11.c (TARGET_TRAMPOLINE_INIT): New.
2881         (m68hc11_trampoline_init): Rename from m68hc11_initialize_trampoline;
2882         make static; update for hook parameters.
2883         * config/m68hc11/m68hc11-protos.h: Update.
2884         * config/m68hc11/m68hc11.h (INITIALIZE_TRAMPOLINE): Remove.
2885
2886         * config/mcore/mcore.c (TARGET_ASM_TRAMPOLINE_TEMPLATE): New.
2887         (TARGET_TRAMPOLINE_INIT): New.
2888         (mcore_function_value): Fix typo.
2889         (mcore_asm_trampoline_template, mcore_trampoline_init): New.
2890         * config/mcore/mcore.h (TRAMPOLINE_TEMPLATE): Move code
2891         to mcore_asm_trampoline_template.
2892         (INITIALIZE_TRAMPOLINE): Move code to mcore_trampoline_init.
2893
2894         * config/mep/mep.h (INITIALIZE_TRAMPOLINE): Remove.
2895         * config/mep/mep.c (TARGET_TRAMPOLINE_INIT): New.
2896         (mep_trampoline_init): Rename from mep_init_trampoline; make static;
2897         update for hook parameters.
2898         * config/mep/mep-protos.h (mep_init_trampoline): Remove.
2899
2900         * config/mips/mips.c (TARGET_ASM_TRAMPOLINE_TEMPLATE,
2901         mips_asm_trampoline_template, TARGET_TRAMPOLINE_INIT,
2902         mips_trampoline_init): New.
2903         * config/mips/mips.h (TRAMPOLINE_TEMPLATE): Move code to
2904         mips_asm_trampoline_template.
2905         (INITIALIZE_TRAMPOLINE): Move code to mips_trampoline_init;
2906         update for hook parameters.
2907
2908         * gcc/config/mmix/mmix.c (TARGET_ASM_TRAMPOLINE_TEMPLATE): New.
2909         (TARGET_TRAMPOLINE_INIT): New.
2910         (mmix_trampoline_size): Remove.
2911         (mmix_asm_trampoline_template): Rename from mmix_trampoline_template;
2912         make static.  Remove out-of-date tetra vs octa comment.
2913         (mmix_trampoline_init): Rename from mmix_initialize_trampoline;
2914         make static; update for hook parameters.
2915         * config/mmix/mmix.h (TRAMPOLINE_TEMPLATE): Remove.
2916         (INITIALIZE_TRAMPOLINE): Remove.
2917         (TRAMPOLINE_SIZE): Use a constant instead of mmix_trampoline_size.
2918         (TRAMPOLINE_ALIGNMENT): New.
2919         * gcc/config/mmix/mmix-protos.h: Update.
2920
2921         * config/mn10300/mn10300.c (TARGET_ASM_TRAMPOLINE_TEMPLATE,
2922         mn10300_asm_trampoline_template, TARGET_TRAMPOLINE_INIT,
2923         mn10300_trampoline_init): New.
2924         * config/mn10300/mn10300.h (TRAMPOLINE_TEMPLATE): Move code to
2925         mn10300_asm_trampoline_template.
2926         (INITIALIZE_TRAMPOLINE): Move code to mn10300_trampoline_init.
2927
2928         * config/moxie/moxie.c (moxie_static_chain,
2929         moxie_asm_trampoline_template, moxie_trampoline_init,
2930         TARGET_STATIC_CHAIN, TARGET_ASM_TRAMPOLINE_TEMPLATE,
2931         TARGET_TRAMPOLINE_INIT): New.
2932         * config/moxie/moxie.h (INITIALIZE_TRAMPOLINE): Move code to
2933         moxie_trampoline_init.
2934         (TRAMPOLINE_TEMPLATE): Move code to moxie_asm_trampoline_template.
2935         (STATIC_CHAIN, STATIC_CHAIN_INCOMING): Remove.
2936
2937         * gcc/config/pa/pa.c (TARGET_ASM_TRAMPOLINE_TEMPLATE,
2938         pa_asm_trampoline_template, TARGET_TRAMPOLINE_INIT,
2939         pa_trampoline_init, TARGET_TRAMPOLINE_ADJUST_ADDRESS,
2940         pa_trampoline_adjust_address): New.
2941         * config/pa/pa.h (TRAMPOLINE_TEMPLATE): Move code to
2942         pa_asm_trampoline_template.
2943         (TRAMPOLINE_ALIGNMENT): New.
2944         (TRAMPOLINE_CODE_SIZE): Move to pa.c.
2945         (INITIALIZE_TRAMPOLINE): Move code to pa_trampoline_init;
2946         adjust for hook parameters.
2947         (TRAMPOLINE_ADJUST_ADDRESS): Move code to pa_trampoline_adjust_address.
2948
2949         * config/pdp11/pdp11.c (pdp11_trampoline_init): New.
2950         (TARGET_TRAMPOLINE_INIT): New.
2951         * config/pdp11/pdp11.h (TRAMPOLINE_TEMPLATE): Remove.
2952         (INITIALIZE_TRAMPOLINE): Move code to pdp11_trampoline_init.
2953
2954         * config/picochip/picochip.h (INITIALIZE_TRAMPOLINE): Remove.
2955
2956         * config/rs6000/rs6000-protos.h (rs6000_initialize_trampoline): Remove.
2957         * config/rs6000/rs6000.c (TARGET_TRAMPOLINE_INIT): New.
2958         (rs6000_trampoline_init): Rename from rs6000_initialize_trampoline;
2959         make static; adjust parameters for the hook.
2960         * config/rs6000/rs6000.h (INITIALIZE_TRAMPOLINE): Remove.
2961
2962         * config/s390/s390.c (s390_asm_trampoline_template): Rename from
2963         s390_trampoline_template; make static.
2964         (s390_trampoline_init): Rename from s390_initialize_trampoline;
2965         make static; adjust for target hook.
2966         (TARGET_ASM_TRAMPOLINE_TEMPLATE, TARGET_TRAMPOLINE_INIT): New.
2967         * config/s390/s390-protos.h: Remove trampoline decls.
2968         * config/s390/s390.h (INITIALIZE_TRAMPOLINE): Remove.
2969         (TRAMPOLINE_TEMPLATE): Remove.
2970         (TRAMPOLINE_ALIGNMENT): New.
2971
2972         * config/score/score-protos.h (score_initialize_trampoline): Remove.
2973         * config/score/score.c (TARGET_ASM_TRAMPOLINE_TEMPLATE): New.
2974         (TARGET_TRAMPOLINE_INIT): New.
2975         (score_asm_trampoline_template): New.
2976         (score_trampoline_init): Rename from score_initialize_trampoline;
2977         make static; adjust for hook parameters.
2978         * config/score/score.h (TRAMPOLINE_TEMPLATE): Move code to
2979         score[37]_asm_trampoline_template.
2980         (INITIALIZE_TRAMPOLINE): Remove.
2981         * config/score/score3.c (score3_asm_trampoline_template): New.
2982         (score3_trampoline_init): Rename from score3_initialize_trampoline;
2983         adjust for target hook.
2984         * config/score/score7.c (score7_asm_trampoline_template): New.
2985         (score7_trampoline_init): Rename from score7_initialize_trampoline;
2986         adjust for target hook.
2987         * config/score/score3.h, config/score/score7.h: Update.
2988
2989         * config/sh/sh-protos.h (sh_initialize_trampoline): Remove.
2990         * config/sh/sh.c (TARGET_TRAMPOLINE_INIT): New.
2991         (TARGET_TRAMPOLINE_ADJUST_ADDRESS): New.
2992         (sh_trampoline_init): Rename from sh_initialize_trampoline;
2993         make static; adjust for target hook parameters.
2994         (sh_trampoline_adjust_address): New.
2995         * config/sh/sh.h (INITIALIZE_TRAMPOLINE): New.
2996         (TRAMPOLINE_ADJUST_ADDRESS): Move code to sh_trampoline_adjust_address.
2997
2998         * config/sparc/sparc.c (TARGET_TRAMPOLINE_INIT): New.
2999         (sparc32_initialize_trampoline): Rename from
3000         sparc_initialize_trampoline; make static; replace tramp parameter
3001         with m_tramp and update memory accesses.
3002         (sparc64_initialize_trampoline): Similarly.
3003         (sparc_trampoline_init): New.
3004         * config/sparc/sparc-protos.h: Remove trampoline decls.
3005         * config/sparc/sparc.h (INITIALIZE_TRAMPOLINE): Remove.
3006         * config/sparc/sparc.md (nonlocal_goto): Don't use static_chain_rtx.
3007
3008         * config/spu/spu.c (TARGET_TRAMPOLINE_INIT): New.
3009         (array_to_constant): Make ARR parameter const.
3010         (spu_trampoline_init): Rename from spu_initialize_trampoline;
3011         make static; update for hook parameters.
3012         * config/spu/spu-protos.h: Update decls.
3013         * config/spu/spu.h (INITIALIZE_TRAMPOLINE): Remove.
3014
3015         * config/stormy16/stormy16.c (xstormy16_trampoline_init): Rename
3016         from xstormy16_initialize_trampoline; make static; update for
3017         hook parameters.
3018         (TARGET_TRAMPOLINE_INIT): New.
3019         * config/stormy16/stormy16.h (INITIALIZE_TRAMPOLINE): Remove.
3020
3021         * config/v850/v850.c (TARGET_ASM_TRAMPOLINE_TEMPLATE): New.
3022         (TARGET_TRAMPOLINE_INIT): New.
3023         (v850_can_eliminate): Make static.
3024         (v850_asm_trampoline_template, v850_trampoline_init): New.
3025         * config/v850/v850.h (TRAMPOLINE_TEMPLATE): Move code to
3026         v850_asm_trampoline_template.
3027         (INITIALIZE_TRAMPOLINE): Move code to v850_trampoline_init
3028         and adjust for target hook parameters.
3029
3030         * config/vax/vax.c (TARGET_ASM_TRAMPOLINE_TEMPLATE): New.
3031         (TARGET_TRAMPOLINE_INIT): New.
3032         (vax_asm_trampoline_template, vax_trampoline_init): New.
3033         * config/vax/vax.h (TRAMPOLINE_TEMPLATE): Move code to
3034         vax_asm_trampoline_template.
3035         (INITIALIZE_TRAMPOLINE): Move code to vax_trampoline_init.
3036
3037         * config/xtensa/xtensa.c (TARGET_ASM_TRAMPOLINE_TEMPLATE): New.
3038         (TARGET_TRAMPOLINE_INIT): New.
3039         (xtensa_asm_trampoline_template): Rename from
3040         xtensa_trampoline_template; make static.
3041         (xtensa_trampoline_init): Rename from xtensa_initialize_trampoline;
3042         make static; update for hook parameters.
3043         * config/xtensa/xtensa-protos.h: Remove trampoline decls.
3044         * config/xtensa/xtensa.h (TRAMPOLINE_TEMPLATE): Remove.
3045         (INITIALIZE_TRAMPOLINE): Remove.
3046
3047         * config/i386/i386.c (ix86_function_regparm): Do not issue an
3048         error for nested functions with regparm=3.
3049         (ix86_compute_frame_layout): Adjust frame pointer offset for
3050         ix86_static_chain_on_stack.
3051         (ix86_expand_prologue): Handle ix86_static_chain_on_stack.
3052         (ix86_emit_restore_reg_using_pop): Increment ix86_cfa_state->offset,
3053         don't reset to UNITS_PER_WORD.
3054         (ix86_emit_leave): Adjust ix86_cfa_state.
3055         (ix86_expand_epilogue): Handle ix86_static_chain_on_stack.
3056         (ix86_static_chain): New.
3057         (ix86_trampoline_init): Rename from x86_initialize_trampoline;
3058         make static; update for target hook parameters; use ix86_static_chain.
3059         (TARGET_STATIC_CHAIN, TARGET_TRAMPOLINE_INIT): New.
3060         * config/i386/i386.h (STATIC_CHAIN_REGNUM): Remove.
3061         (INITIALIZE_TRAMPOLINE): Remove.
3062         (TRAMPOLINE_SIZE): Use 24 for 64-bit.
3063         (struct machine_function): Use BOOL_BITFIELD; rearrange bitfields
3064         to the end.  Add static_chain_on_stack.
3065         (ix86_static_chain_on_stack): New.
3066
3067         * config/m68k/m68k.c (TARGET_TRAMPOLINE_INIT): New.
3068         (m68k_output_mi_thunk): Don't use static_chain_rtx.
3069         (m68k_trampoline_init): New.
3070         * config/m68k/m68k.h (INITIALIZE_TRAMPOLINE): Move code to
3071         m68k_trampoline_init and adjust for hook parameters.
3072         * config/m68k/netbsd-elf.h (TRAMPOLINE_TEMPLATE): Remove.
3073         (TRAMPOLINE_SIZE, INITIALIZE_TRAMPOLINE): Remove.
3074
3075 2009-09-22  Jakub Jelinek  <jakub@redhat.com>
3076
3077         * config/rs6000/rs6000.c (bdesc_2arg): Fix CODE_FOR_vector_gt* codes
3078         for __builtin_altivec_vcmpgt{sb,uh,sh,uw}.
3079
3080         * reload1.c (reload): Call wrap_constant when substituting
3081         reg for equiv inside of DEBUG_INSNs.
3082
3083         PR bootstrap/41405
3084         * dwarf2out.c (base_type_die, record_type_tag, gen_subprogram_die,
3085         add_call_src_coords_attributes, add_high_low_attributes,
3086         gen_compile_unit_die, gen_type_die_with_usage force_decl_die,
3087         gen_decl_die, dwarf2out_imported_module_or_decl_1, dwarf2out_finish,
3088         dwarf2out_imported_module_or_decl): Avoid using DWARF3 additions
3089         when -gdwarf-2 -gstrict-dwarf.
3090         (loc_list_from_tree): Likewise.  Avoid using DWARF4 additions when
3091         -gdwarf-[23] -gstrict-dwarf.
3092         (address_of_int_loc_descriptor, loc_descriptor,
3093         loc_list_for_address_of_addr_expr_of_indirect_ref): Avoid using
3094         DWARF4 additions when -gdwarf-[23] -gstrict-dwarf.
3095         * common.opt (gno-strict-dwarf, gstrict-dwarf): New options.
3096
3097 2009-09-22  Richard Guenther  <rguenther@suse.de>
3098
3099         PR tree-optimization/41428
3100         * tree-ssa-ccp.c (ccp_fold_stmt): New function.
3101         (ccp_finalize): Pass it to substitute_and_fold.
3102
3103 2009-09-22  Richard Guenther  <rguenther@suse.de>
3104
3105         * tree-ssa-propagate.h (ssa_prop_fold_stmt_fn): Declare.
3106         (substitute_and_fold): Adjust prototype.
3107         * tree-vrp.c (vrp_evaluate_conditional): Make static.
3108         (simplify_stmt_using_ranges): Likewise.
3109         (fold_predicate_in): Move here from tree-ssa-propagate.c.
3110         (vrp_fold_stmt): New function.
3111         (vrp_finalize): Pass it to substitute_and_fold.
3112         * tree-flow.h (vrp_evaluate_conditional): Remove.
3113         (simplify_stmt_using_ranges): Likewise.
3114         * tree-ssa-ccp.c (ccp_finalize): Adjust call to substitute_and_fold.
3115         * tree-ssa-copy.c (fini_copy_prop): Likewise.
3116         * tree-ssa-propagate.c (struct prop_stats_d): Rename num_pred_folded
3117         member.
3118         (fold_predicate_in): Move to tree-vrp.c.
3119         (substitute_and_fold): Use the callback instead of calling into
3120         tree-vrp.c functions directly.
3121
3122 2009-09-22  Jakub Jelinek  <jakub@redhat.com>
3123
3124         * dwarf2out.c (address_of_int_loc_descriptor): Avoid signed/unsigned
3125         comparison warning on rs6000.
3126
3127         PR middle-end/41429
3128         * tree-cfg.c (remove_useless_stmts_tc): Call gsi_next (gsi) even for
3129         GIMPLE_EH_MUST_NOT_THROW cleanup.
3130         (verify_types_in_gimple_stmt): Handle GIMPLE_EH_MUST_NOT_THROW.
3131
3132 2009-09-22  Jack Howarth  <howarth@bromo.med.uc.edu>
3133
3134         PR middle-end/41260
3135         * gcc/config.gcc: Use darwin9.h and darwin10.h on darwin10 and later.
3136         * gcc/config/darwin10.h: Add file to pass -no_compact_unwind on
3137         LIB_SPEC for darwin10 and later since it always uses the unwinder in
3138         libSystem which is derived from the gcc 4.2.1 unwinder.
3139
3140 2009-09-22  Dave Korn  <dave.korn.cygwin@gmail.com>
3141
3142         PR middle-end/41357
3143         * varasm.c (default_encode_section_info): Copy TLS model into
3144         sym_ref flags regardless of backend support for TLS, for all
3145         model types except TLS_MODEL_EMULATED.
3146
3147 2009-09-22  Dave Korn  <dave.korn.cygwin@gmail.com>
3148
3149         PR bootstrap/41404
3150         * dwarf2out.c (mem_loc_descriptor): Punt on CONST_STRING until
3151         we can handle it correctly.
3152
3153 2009-09-21  Gerald Pfeifer  <gerald@pfeifer.com>
3154
3155         * doc/install.texi (os2): Remove section.
3156
3157 2009-09-21  Gerald Pfeifer  <gerald@pfeifer.com>
3158
3159         * doc/standards.texi (Objective-C): Adjust two URLs.
3160
3161 2009-09-21  Giuseppe Scrivano <gscrivano@gnu.org>
3162
3163         * tree-tailcall.c (process_assignment): Don't check if a
3164         multiplication or an addition are already present.
3165         (find_tail_calls): Combine multiple additions and multiplications.
3166         (adjust_accumulator_values): Emit accumulators.
3167
3168 2009-09-21  Kai Tietz  <kai.tietz@onevision.com>
3169
3170         * config/i386/i386.c (ix86_expand_epilogue): Adjust offset for
3171         xmm register restore.
3172
3173 2009-09-21  Jan Hubicka  <jh@suse.cz>
3174
3175         * dwarf2out.c (decl_loc_table_eq): Allow decl_loc_table to be NULL.
3176         (dwarf2out_abstract_function): NULLify decl_loc_table at begginig and
3177         restore at the end.
3178
3179 2009-09-21  Eric Botcazou  <ebotcazou@adacore.com>
3180
3181         * stor-layout.c (layout_type): Remove obsolete code.
3182
3183 2009-09-20  H.J. Lu  <hongjiu.lu@intel.com>
3184
3185         PR middle-end/41395
3186         * opts.c (decode_options): Don't turn on flag_ipa_sra for opt2.
3187
3188 2009-09-20  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
3189
3190         PR middle-end/30789
3191         * builtins.c (do_mpc_arg2): Accept DO_NONFINITE parameter.
3192         (do_mpc_ckconv): Accept FORCE_CONVERT parameter.
3193         (fold_builtin_2, do_mpc_arg1): Update accordingly.
3194         * fold-const.c (const_binop): Likewise.
3195         * real.h (do_mpc_arg2): Update prototype.
3196
3197 2009-09-20  Jan Hubicka  <jh@suse.cz>
3198
3199         * dwarf2out.c (add_const_value_attribute): Return true if successful.
3200         (add_location_or_const_value_attribute): Rewrite using
3201         loc_list_from_tree.
3202         (tree_add_const_value_attribute): Return true if successful.
3203         (tree_add_const_value_attribute_for_decl): Likewise.
3204
3205         * dwarf2out.c (address_of_int_loc_descriptor): Break out from ...
3206         (loc_descriptor): ... here;
3207         (loc_list_for_address_of_addr_expr_of_indirect_ref): New function.
3208         (cst_pool_loc_descr): Break out from ...; do not reffer constant
3209         pool items that was not marked for output.
3210         (loc_list_from_tree): ... here; handle special cases of ADDR_EXPR;
3211         (loc_list_for_address_of_addr_expr_of_indirect_ref): New function.
3212         (loc_list_for_address_of_addr_expr_of_indirect_ref): New function.
3213         handle ALIGN_INDIRECT_REF, MISALIGNED_INDIRECT_REF, REALPART_EXPR,
3214         IMAGPART_EXPR; handle address of INTEGER_CST; improve handling of
3215         CONSTRUCTOR; handle REAL_CST, STRING_CST, COMPLEX_CST; use
3216         DW_OP_stack_value to get address of items that are not available
3217         as addresses.
3218         (dw_loc_list): Handle single element lists correctly.
3219
3220 2009-09-20  Kai Tietz  <kai.tietz@onevision.com>
3221             Pascal Obry  <obry@adacore.com>
3222
3223         * unwind-dw2-fde.c (classify_object_over_fdes):
3224         Cast the constant 1 to _Unwind_Ptr.
3225         (add_fdes): Likewise.
3226         (linear_search_fdes): Likewise.
3227
3228 2009-09-20  Eric Botcazou  <ebotcazou@adacore.com>
3229
3230         * stor-layout.c (set_sizetype): Avoid useless type copy.
3231
3232 2009-09-20  Richard Sandiford  <rdsandiford@googlemail.com>
3233
3234         * configure.ac (gcc_cv_ld_mips_personality_relaxation): New
3235         feature check.
3236         (HAVE_LD_PERSONALITY_RELAXATION): New macro definition.
3237         * configure, config.in: Regenerate.
3238         * dwarf2asm.c (eh_data_format_name): Handle DW_EH_PE_indirect |
3239         DW_EH_PE_absptr.
3240         * config/mips/mips.h (TARGET_WRITABLE_EH_FRAME): New macro.
3241         (ASM_PREFERRED_EH_DATA_FORMAT): Define.  Use MIPS_EH_INDIRECT
3242         for global data if the output could be used in a shared library.
3243         * config/mips/mips.c (mips_override_options): Set flag_dwarf2_cfi_asm
3244         to 0 if TARGET_WRITABLE_EH_FRAME.
3245
3246 2009-09-20  Paolo Bonzini <bonzini@gnu.org>
3247
3248         PR rtl-optimization/39886
3249         * combine.c (update_cfg_for_uncondjump): Set EDGE_FALLTHRU
3250         just when insn is equal to BB_END (bb).
3251
3252 2009-09-19  Adam Nemet  <anemet@caviumnetworks.com>
3253
3254         * config/mips/mips.opt (mrelax-pic-calls): New option.
3255         * config/mips/mips.c (mips_strip_unspec_address): Move it up in
3256         the file.
3257         (mips_unspec_call): Change "unspec_call" expander into this.
3258         (mips_strip_unspec_call): New function.
3259         (mips_got_load): Call mips_unspec_call instead of
3260         gen_unspec_call<mode>.
3261         (mips16_build_call_stub): Fix comment for fp_code.  Adjust call to
3262         MIPS_CALL.
3263         (mips_cfg_in_reorg): New function.
3264         (mips16_lay_out_constants): Use it to decide whether to call
3265         CFG-aware insn splitting.
3266         (r10k_insert_cache_barriers): Move CFG set-up code from here to
3267         mips_reorg.  Move DF set-up code from here ...
3268         (mips_df_reorg): ... to here.  Call r10k_insert_cache_barriers
3269         from here.
3270         (mips_reorg): Call mips_df_reorg instead of
3271         r10k_insert_cache_barriers.  Move CFG set-up code here from
3272         r10k_insert_cache_barriers.
3273         (mips_call_expr_from_insn): New function.
3274         (mips_pic_call_symbol_from_set): Likewise.
3275         (mips_find_pic_call_symbol): Likewise.
3276         (mips_annotate_pic_call_expr): Likewise.
3277         (mips_get_pic_call_symbol): Likewise.
3278         (mips_annotate_pic_calls): Likewise.
3279         (mips_override_options): Disable -mrelax-pic-calls unless PIC
3280         calls are used.
3281         (mips_set_mips16_mode): Disable -mrelax-pic-calls for MIPS16.
3282         * config/mips/mips-protos.h (mips_get_pic_call_symbol): Declare it.
3283         * config/mips/mips.h (MIPS_CALL): Use it to print the .reloc
3284         directive.
3285         * config/mips/mips.md (UNSPEC_CALL_ATTR): New unspec.
3286         (unspec_call<mode>): Remove it.
3287         (sibcall_internal, sibcall_value_internal,
3288         sibcall_value_multiple_internal, call_internal, call_split,
3289         call_value_internal, call_value_split,
3290         call_value_multiple_internal, call_value_multiple_split): Pass
3291         SIZE_OPNO to MIPS_CALL.
3292         (call_internal_direct, call_direct_split,
3293         call_value_internal_direct, call_value_direct_split): Pass -1 as
3294         SIZE_OPNO to MIPS_CALL.
3295         * configure.ac <mips*-*-*>: Add test for .reloc R_MIPS_JALR.
3296         * configure: Regenerate.
3297         * doc/invoke.texi (Option Summary): Add -mrelax-pic-calls
3298         and -mno-relax-pic-calls.
3299         (MIPS Options): Document -mrelax-pic-calls and -mno-relax-pic-calls.
3300
3301 2009-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3302
3303         PR bootstrap/35619
3304         * Makefile.in (stmp-fixinc): Ensure `include-fixed' is created
3305         in the directory this rule is called from, rather than the
3306         toplevel 'gcc' directory, to fix in-tree build.
3307
3308 2009-09-19  Chris Demetriou  <cgd@google.com>
3309
3310         PR preprocessor/28435:
3311         * c-opts.c (c_common_handle_option): For -MD and -MMD, indicate
3312         to cpplib that the preprocessor output is needed.
3313
3314 2009-09-19  Jakub Jelinek  <jakub@redhat.com>
3315
3316         * config/rs6000/rs6000.md (*save_gpregs_<mode>, *save_fpregs_<mode>,
3317         *restore_gpregs_<mode>, *return_and_restore_gpregs_<mode>,
3318         *return_and_restore_fpregs_<mode>,
3319         *return_and_restore_fpregs_aix_<mode>): Remove 'z' operand modifier.
3320
3321         PR bootstrap/41397
3322         * dwarf2out.c (mem_loc_descriptor) <case SUBREG>: Recurse
3323         instead of assuming it has always a REG inside of it.
3324
3325 2009-09-18  Gerald Pfeifer  <gerald@pfeifer.com>
3326
3327         * config/freebsd.h: Update comment on types.
3328         (WINT_TYPE): Define.
3329
3330 2009-09-18  Jason Merrill  <jason@redhat.com>
3331
3332         * c.opt: Add -fno-deduce-init-list.
3333
3334 2009-09-18  Neil Vachharajani  <nvachhar@google.com>
3335
3336         * value-prof.c (interesting_stringop_to_profile_p): Added output
3337         argument to indicate which parameter is the size parameter.
3338         * value-prof.c (gimple_stringop_fixed_value): Use
3339         INTERESTING_STRINGOP_TO_PROFILE_P to find size argument.
3340         * value-prof.c (gimple_stringops_transform): Update call sites to
3341         INTERESTING_STRINGOP_TO_PROFILE_P to reflect parameter change.
3342
3343 2009-09-18  Uros Bizjak  <ubizjak@gmail.com>
3344
3345         PR target/38288
3346         From David Binderman <dcb314@hotmail.com>:
3347         * gcc/config/i386/i386.c (ix86_function_regparm): Remove useless
3348         local variable f.  Remove stale comments.
3349         (ix86_compute_frame_layout): Remove useless local variable total_size.
3350         Remove #if 0'd code.
3351         (legitimate_address_p): Remove useless local variables
3352         reason_rtx and reason.
3353         (ix86_split_copysign_const): Remove useless local variable op1.
3354         (scale_counter): Remove useless local variable piece_size_mask.
3355
3356 2009-09-18  Jakub Jelinek  <jakub@redhat.com>
3357
3358         * stmt.c (expand_asm_operands): Set REG_ATTRS on the temporary from
3359         output decl.
3360
3361 2009-09-17  Michael Haubenwallner  <michael.haubenwallner@salomon.at>
3362
3363         PR target/40913
3364         * config/pa/t-hpux-shlib: Set soname in libgcc_s.sl.
3365
3366 2009-09-17  Jakub Jelinek  <jakub@redhat.com>
3367
3368         * c-decl.c (finish_struct): Adjust DECL_SOURCE_LOCATION of
3369         TYPE_STUB_DECL.
3370
3371 2009-09-17  Alexandre Oliva  <aoliva@redhat.com>
3372
3373         * dwarf2out.c (loc_descriptor): Emit DW_OP_stack_value and
3374         DW_OP_implicit_value even without dwarf_version 4.
3375
3376 2009-09-17  Jan Hubicka  <jh@suse.cz>
3377
3378         * dwarf2out.c: Include tree-pass.h and gimple.h.
3379         (loc_list_plus_const): New function.
3380         (loc_descriptor_from_tree_1): Rename to ...
3381         (loc_descriptor_from_tree): ... remove original.
3382         (loc_list_from_tree): New function.
3383         (add_AT_location_description): Accept location list.
3384         (tls_mem_loc_descriptor): Update call of loc_descriptor_from_tree.
3385         (concatn_mem_loc_descriptor): Remove.
3386         (mem_loc_descriptor): Handle CONCAT/CONCATN and VAR_LOCATION by
3387         returning NULL.
3388         (secname_for_decl): Move up.
3389         (hidden_reference_p): New function; break out from ...
3390         (loc_by_refernece): ... here; move up.
3391         (dw_loc_list): New function.
3392         (single_element_loc_list): New function.
3393         (single_element_loc_list_p): New function.
3394         (add_loc_descr_to_each): New function.
3395         (add_loc_list): New function.
3396         (loc_descr_from_tree): Make wraper of loc_list_from_tree.
3397         (loc_list_from_tree): Reroganized from loc_descr_from_tree;
3398         add diagnostics why expansion failed.
3399         (add_location_or_const_value_attribute): Support location lists.
3400         (add_bound_info): Likewise.
3401         (descr_info_loc): Update call of loc_descriptor_from_tree.
3402         (gen_variable_die): Work on location lists.
3403         * final.c (pass_final): Add dump file.
3404         * Makefile.in (dwarf2out.o): Add new dependencies.
3405
3406 2009-09-17  Janis Johnson  <janis187@us.ibm.com>
3407
3408         PR c/41049
3409         * real.c decimal_from_integer, decimal_integer_string): New.
3410         (real_from_integer): Use them as special case for decimal float.
3411         * config/dfp-bit.c (_si_to_sd, _usi_to_sd): Use default rounding.
3412         (_di_to_sd, _di_to_dd, _di_to_td, _udi_to_sd, _udi_to_dd, _udi_to_td):
3413         Do not append zero after the decimal point in string to convert.
3414
3415 2009-09-17  Alexander Monakov  <amonakov@ispras.ru>
3416
3417         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
3418         for ARRAY_REFs.  Use array_ref_{low,up}_bound to determine bounds.
3419
3420 2009-09-17  Martin Jambor  <mjambor@suse.cz>
3421
3422         * common.opt (fipa-sra): New switch.
3423         * opts.c (decode_options): Turn flag_ipa_sra on for opt2.
3424         * timevar.def (TV_IPA_SRA): New timevar.
3425         * params.def (ipa-sra-ptr-growth-factor): New parameter.
3426         * doc/invoke.texi: Document -fipa-sra and ipa-sra-ptr-growth-factor.
3427         * tree-sra.c: Include cgraph.c.
3428         (enum sra_mode): Added SRA_MODE_EARLY_IPA.
3429         (struct access): Added fields stmt, grp_maybe_modified, grp_scalar_ptr
3430         and grp_not_necessarilly_dereferenced.
3431         (func_param_count): New variable.
3432         (encountered_apply_args): New variable.
3433         (bb_dereferences): New variable.
3434         (final_bbs): New variable.
3435         (no_accesses_representant): New variable.
3436         (no_accesses_p): New function.
3437         (dump_access): Dump the new fields.
3438         (sra_initialize): Set encountered_apply_args to false.
3439         (get_ssa_base_param): New function.
3440         (mark_parm_dereference): New function.
3441         (create_access): Caring for INIDRECT_REFs and different handling of
3442         varialble length accesses in early IPA SRA.  Store the stmt - a new
3443         parameter - to the new access.
3444         (build_access_from_expr_1): New parameter stmt, passed to
3445         create_access.  Handle INDIRECT_REFs.
3446         (build_access_from_expr): Pass the current statement to
3447         build_access_from_expr_1.
3448         (disqualify_ops_if_throwing_stmt): Trigger only in intraprocedural
3449         passes.
3450         (build_accesses_from_assign): Pass the current statement to
3451         build_access_from_expr_1.  Do not create assign links in IPA-SRA.
3452         (scan_function): Call handle_ssa_defs on phi nodes.  Set bits in
3453         final_bbs when necessary.  Check for calls to __builtin_apply_args.
3454         Fixup EH info if anythng was changed.
3455         (is_unused_scalar_param): New function.
3456         (ptr_parm_has_direct_uses): New function.
3457         (find_param_candidates): New function.
3458         (mark_maybe_modified): New function.
3459         (analyze_modified_params): New function.
3460         (propagate_dereference_distances): New function.
3461         (dump_dereferences_table): New function.
3462         (analyze_caller_dereference_legality): New function.
3463         (unmodified_by_ref_scalar_representative): New function.
3464         (splice_param_accesses): New function.
3465         (decide_one_param_reduction): New function.
3466         (enum ipa_splicing_result): New type.
3467         (splice_all_param_accesses): New function.
3468         (get_param_index): New function.
3469         (turn_representatives_into_adjustments): New function.
3470         (analyze_all_param_acesses): New function.
3471         (get_replaced_param_substitute): New function.
3472         (get_adjustment_for_base): New function.
3473         (replace_removed_params_ssa_names): New function.
3474         (sra_ipa_reset_debug_stmts): New function.
3475         (sra_ipa_modify_expr): New function.
3476         (sra_ipa_modify_assign): New function.
3477         (convert_callers): New function.
3478         (modify_function): New function.
3479         (ipa_sra_preliminary_function_checks): New function.
3480         (ipa_early_sra): New function.
3481         (ipa_early_sra_gate): New function.
3482         (pass_early_ipa_sra): New variable.
3483         * Makefile.in (tree-sra.o): Add cgraph.h to dependencies.
3484
3485 2009-09-17  Michael Matz  <matz@suse.de>
3486
3487         PR middle-end/41347
3488         * tree.c (build_type_attribute_qual_variant): Export.
3489         * tree.h (build_type_attribute_qual_variant): Declare.
3490         * tree-inline.c (remap_type_1): Use it to build variants with
3491         the original qualifiers and attributes.
3492
3493 2009-09-17  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
3494
3495         * cfglayout.c (fixup_reorder_chain): Accept conditional jumps
3496         without a fallthrough edge.
3497
3498 2009-09-16  DJ Delorie  <dj@redhat.com>
3499
3500         * config/m32c/m32c.c (m32c_emit_epilogue): Check for R8C or M16C
3501         chip and ignore the "fast_interrupt" attribute if so.
3502
3503 2009-09-16  Richard Henderson  <rth@redhat.com>
3504
3505         PR middle-end/41360
3506         * cfgbuild.c (find_bb_boundaries): Really re-instate 2009-09-02
3507         barrier fix.
3508
3509 2009-09-16  Richard Henderson  <rth@redhat.com>
3510
3511         PR target/41246
3512         * tree-cfg.c (verify_gimple_call): Validate that gimple_call_chain
3513         is set only if DECL_NO_STATIC_CHAIN is unset.
3514         * tree-nested.c (iter_nestinfo_start, iter_nestinfo_next): New.
3515         (FOR_EACH_NEST_INFO): New.
3516         (walk_all_functions): Use it.
3517         (finalize_nesting_tree): Likewise.
3518         (unnest_nesting_tree): Likewise.
3519         (free_nesting_tree): Use iter_nestinfo_start, iter_nestinfo_next.
3520         (get_chain_decl, get_chain_field): Reset DECL_NO_STATIC_CHAIN.
3521         (convert_gimple_call): Early out if gimple_call_chain already set.
3522         (convert_all_function_calls): Iterate until no new functions
3523         require a static chain.
3524         (finalize_nesting_tree_1): Assert DECL_NO_STATIC_CHAIN is unset
3525         when building a trampoline.  Use dump_function_to_file instead
3526         of dump_function.
3527         (lower_nested_functions): Open dump_file.  Validate that decls
3528         that have DECL_NO_STATIC_CHAIN from the front end don't have that
3529         bit reset by this pass.
3530
3531 2009-09-16  Michael Matz  <matz@suse.de>
3532
3533         PR fortran/41212
3534         * tree.h (struct tree_decl_common): Add decl_restricted_flag,
3535         shorten decl_common_unused.
3536         (DECL_RESTRICTED_P): New accessor.
3537         * tree-ssa-alias.c (ptr_deref_may_alias_decl_p): Use it
3538         to disambiguate marked decls and restrict pointers.
3539
3540 2009-09-16  Richard Henderson  <rth@redhat.com>
3541
3542         PR middle-end/41360
3543         * cfgbuild.c (find_bb_boundaries): Re-instate 2009-09-02 barrier fix.
3544
3545 2009-09-16  Jakub Jelinek  <jakub@redhat.com>
3546
3547         * integrate.c (set_block_abstract_flags): Call
3548         set_decl_abstract_flags also on BLOCK_NONLOCALIZED_VARs.
3549
3550 2009-09-16  Richard Guenther  <rguenther@suse.de>
3551
3552         PR middle-end/34011
3553         * tree-flow-inline.h (may_be_aliased): Compute readonly variables
3554         as non-aliased.
3555
3556 2009-09-16  DJ Delorie  <dj@redhat.com>
3557             Kaz Kojima  <kkojima@gcc.gnu.org>
3558
3559         * config/sh/sh.c (output_stack_adjust): Add new argument frame_p.
3560         (sh_expand_prologue): Update calls to output_stack_adjust.
3561         (sh_expand_epilogue): Likewise.
3562
3563 2009-09-15  Adam Nemet  <anemet@caviumnetworks.com>
3564
3565         PR bootstrap/41349
3566         * reorg.c (redundant_insn): Don't count notes or DEBUG_INSNs when
3567         trying to limit the extent of searches in the insn stream.
3568
3569 2009-09-15  Nathan Froyd  <froydnj@codesourcery.com>
3570             Jakub Jelinek  <jakub@redhat.com>
3571
3572         PR target/41175
3573         PR target/40677
3574         * config/rs6000/rs6000.c (no_global_regs_above): Fix precedence
3575         problem.
3576         (SAVRES_NOINLINE_GPRS_SAVES_LR, SAVRES_NOINLINE_FPRS_SAVES_LR,
3577         SAVRES_NOINLINE_FPRS_DOESNT_RESTORE_LR): New strategy bits.
3578         (rs6000_savres_strategy): Always save FP registers inline if the
3579         target doesn't support hardware double-precision.  Set the above
3580         bits in return value when needed.
3581         (rs6000_savres_routine_sym): Fix computation for cache selector.
3582         Mark the generated symbol as a function.  Rename exitp argument to
3583         lr.  Move code for determining the name of the symbol...
3584         (rs6000_savres_routine_name): ...here.  New function.  Add cases for
3585         getting the names right on AIX and 64-bit Linux.
3586         (savres_routine_name): New variable.
3587         (rs6000_make_savres_rtx): Rename exitp argument to lr.  Don't assert
3588         lr isn't set when savep.  Use r12 resp. r1 instead of r11 depending
3589         on what the target routine uses as a base register.  If savep && lr
3590         describe saving of r0 into memory slot.
3591         (rs6000_emit_prologue): Correct use of call_used_regs.  Fix out of
3592         line calls for AIX ABI.
3593         (rs6000_output_function_prologue): Use rs6000_savres_routine_name to
3594         determine FP save/restore functions.
3595         (rs6000_emit_stack_reset): Handle savres if sp_offset != 0 and
3596         frame_reg_rtx != sp_reg_rtx.  Use gen_add3_insn instead of
3597         gen_addsi3.
3598         (rs6000_emit_epilogue): Adjust computation of restore_lr.
3599         Duplicate restoration of LR and execute the appropriate one
3600         depending on whether GPRs are being restored inline.  Set r11 from
3601         offsetted frame_reg_rtx instead of sp_reg_rtx; if frame_reg_rtx is
3602         r11, adjust sp_offset.  Use gen_add3_insn instead of gen_addsi3.
3603         Fix out of line calls for AIX ABI.
3604         * config/rs6000/rs6000.md (*return_and_restore_fpregs_aix_<mode>):
3605         New insn.
3606         * config/rs6000/spe.md (*save_gpregs_spe): Use explicit match for
3607         register 11.
3608         (*restore_gpregs_spe): Likewise.
3609         (*return_and_restore_gpregs_spe): Likewise.
3610         * config/rs6000/linux64.h (SAVE_FP_SUFFIX, RESTORE_FP_SUFFIX):
3611         Define to empty string unconditionally.
3612         * config/rs6000/sysv4.h (SAVE_FP_SUFFIX, RESTORE_FP_SUFFIX):
3613         Define to empty string unconditionally.
3614         (GP_SAVE_INLINE, FP_SAVE_INLINE): Handle TARGET_64BIT the same as
3615         !TARGET_64BIT.
3616
3617 2009-09-15  Jan Hubicka  <jh@suse.cz>
3618
3619         * doc/invoke.texi (inline-insns-auto): Drop from 60 to 50.
3620         * params.def (inline-insns-auto): Likewise.
3621
3622 2009-09-15  Martin Jambor  <mjambor@suse.cz>
3623
3624         * ipa-inline.c (estimate_function_body_sizes): Dump info about
3625         individual statements only at TDF_DETAILS dump level.  Format
3626         source for 80 characters per line.
3627
3628 2009-09-15  Christian Bruel  <christian.bruel@st.com>
3629
3630         * regrename.c (do_replace): Update REG_DEAD notes.
3631
3632 2009-09-15  Revital Eres  <eres@il.ibm.com>
3633
3634         * doc/tm.texi (TARGET_SUPPORT_VECTOR_MISALIGNMENT): Document.
3635         * targhooks.c (default_builtin_support_vector_misalignment):
3636         New builtin function.
3637         * targhooks.h (default_builtin_support_vector_misalignment):
3638         Declare.
3639         * target.h (builtin_support_vector_misalignment):
3640         New field in struct gcc_target.
3641         * tree-vect-data-refs.c (vect_supportable_dr_alignment): Call
3642         new builtin function.
3643         * target-def.h (TARGET_SUPPORT_VECTOR_MISALIGNMENT):
3644         Define.
3645         * config/rs6000/rs6000.c
3646         (rs6000_builtin_support_vector_misalignment): New function.
3647         (TARGET_SUPPORT_VECTOR_MISALIGNMENT): Define.
3648
3649 2009-09-15  Jie Zhang  <jie.zhang@analog.com>
3650
3651         * config/bfin/bfin.c (length_for_loop): Use NONDEBUG_INSN_P
3652         instead of INSN_P.
3653         (bfin_optimize_loop): Likewise.
3654         (bfin_gen_bundles): Likewise.
3655         (workaround_speculation): Likewise.
3656         (find_load): Return NULL_RTX for debug_insn.
3657
3658 2009-09-15  Uros Bizjak  <ubizjak@gmail.com>
3659
3660         * config/alpha/alpha.md (smaxsf3): Disable for IEEE mode.
3661         (sminsf3): Ditto.
3662
3663 2009-09-14  DJ Delorie  <dj@redhat.com>
3664
3665         * config/mep/mep.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
3666         * config/mep/mep.c (mep_emit_cbranch): Don't use BEQZ/BNEI in
3667         VLIW mode.
3668
3669 2009-09-14  Richard Henderson  <rth@redhat.com>
3670             Jakub Jelinek  <jakub@redhat.com>
3671
3672         * builtins.c (expand_builtin_synchronize): Use gimple_build_asm_vec.
3673         * cfgbuild.c (make_edges): Handle asm goto.
3674         * cfglayout.c (fixup_reorder_chain): Likewise.
3675         * cfgrtl.c (patch_jump_insn): Likewise.
3676         * gimple-pretty-print.c (dump_gimple_asm): Likewise.
3677         * gimple.c (gimple_build_asm_1): Add and use nlabels parameter.
3678         (gimple_build_asm_vec): Add and use labels parameter.
3679         (gimple_build_asm): Remove.
3680         (walk_gimple_asm): Walk labels too.
3681         * gimple.def (GIMPLE_ASM): Update docs.
3682         * gimple.h: Update decls.
3683         (struct gimple_statement_asm): Change nc to use unsigned char;
3684         add nl member.
3685         (gimple_asm_nlabels): New.
3686         (gimple_asm_label_op, gimple_asm_set_label_op): New.
3687         * gimplify.c (gimplify_asm_expr): Copy labels from ASM_EXPR
3688         into gimple_build_asm_vec.
3689         * jump.c (mark_jump_label_asm): New.
3690         (mark_jump_label): Use it.
3691         (redirect_jump_1): Handle asm goto.
3692         (invert_jump_1): Soft fail if X is null.
3693         * recog.c (extract_asm_operands): New.
3694         (asm_noperands): Use it; handle asm labels.
3695         (decode_asm_operands): Use extract_asm_operands.
3696         (asm_operand_ok): Properly handle empty string.
3697         * reg-stack.c (get_asm_operands_in_out): Rename from
3698         get_asm_operand_n_inputs; use extract_asm_operands; return both
3699         inputs and outputs by reference; update all callers.
3700         * rtl.def (ASM_OPERANDS): Add label vector as operand 6.
3701         * rtl.h (ASM_OPERANDS_LABEL_VEC): New.
3702         (ASM_OPERANDS_LABEL_LENGTH, ASM_OPERANDS_LABEL): New.
3703         (ASM_OPERANDS_SOURCE_LOCATION): Renumber.
3704         (extract_asm_operands): Declare.
3705         * stmt.c (expand_asm_operands): Add and use labels parameter.
3706         (check_unique_operand_names): Likewise.
3707         (resolve_asm_operand_names, resolve_operand_name_1): Likewise.
3708         (expand_asm_stmt): Handle asm labels.
3709         * tree-cfg.c (make_gimple_asm_edges): New.
3710         (make_edges): Use it.
3711         (cleanup_dead_labels): Handle asm labels.
3712         (is_ctrl_altering_stmt): Likewise.
3713         (gimple_redirect_edge_and_branch): Likewise.
3714         * tree.def (ASM_EXPR): Add 5th operand.
3715         * tree.h (ASM_LABELS): New.
3716         (resolve_asm_operand_names): Update decl.
3717
3718         * c-parser.c (c_parser_asm_statement): Parse asm goto.
3719         (c_parser_asm_goto_operands): New.
3720         * c-tree.h (build_asm_expr): Update decl.
3721         * c-typeck.c (build_asm_expr): Add and use labels parameter.
3722         * doc/extend.texi: Document asm goto.
3723
3724 2009-09-14  Richard Henderson  <rth@redhat.com>
3725
3726         * except.h: Update declarations.
3727         (struct pointer_map_t): Forward declare.
3728         (ERT_UNKNOWN, ERT_THROW, ERT_CATCH): Remove.
3729         (struct eh_landing_pad_d, eh_landing_pad): New.
3730         (struct eh_catch_d, eh_catch): New.
3731         (struct eh_region_d): Remove next_region_sharing_label, aka,
3732         label, tree_label, landing_pad, post_landing_pad, resume,
3733         may_contain_throw.  Rename region_number to index.  Remove
3734         u.eh_catch, u.eh_throw.  Rename u.eh_try.eh_catch to first_catch.
3735         Add u.must_not_throw, landing_pads, exc_ptr_reg, filter_reg.
3736         (VEC(eh_landing_pad,gc)): New.
3737         (struct eh_status): Remove last_region_number.  Add lp_array,
3738         throw_stmt_table, ttype_data, ehspec_data.
3739         (ehr_next, FOR_ALL_EH_REGION_AT): New.
3740         (FOR_ALL_EH_REGION_FN, FOR_ALL_EH_REGION): New.
3741         * except.c (lang_protect_cleanup_actions): Return tree.
3742         (struct ehl_map_entry): Remove.
3743         (init_eh_for_function): Push zero entries for region and lp_array.
3744         (gen_eh_region): Add to region_array immediately.
3745         (gen_eh_region_catch): Operate on eh_catch objects.
3746         (gen_eh_landing_pad): New.
3747         (get_eh_region_may_contain_throw, get_eh_region_tree_label): Remove.
3748         (get_eh_region_no_tree_label, set_eh_region_tree_label): Remove.
3749         (get_eh_region_from_number, get_eh_region_from_number_fn): New.
3750         (get_eh_landing_pad_from_number_fn): New.
3751         (get_eh_landing_pad_from_number): New.
3752         (get_eh_region_from_lp_number_fn): New.
3753         (get_eh_region_from_lp_number): New.
3754         (expand_resx_stmt, note_eh_region_may_contain_throw): Remove.
3755         (get_exception_pointer, get_exception_filter): Remove.
3756         (collect_eh_region_array, can_be_reached_by_runtime): Remove.
3757         (current_function_has_exception_handlers): Simplify.
3758         (bring_to_root, eh_region_replaceable_by_p): Remove.
3759         (replace_region, hash_type_list, hash_eh_region): Remove.
3760         (eh_regions_equal_p, merge_peers, remove_unreachable_regions): Remove.
3761         (label_to_region_map, num_eh_regions): Remove.
3762         (get_next_region_sharing_label, must_not_throw_labels): Remove.
3763         (find_exception_handler_labels): Remove.
3764         (duplicate_eh_regions_0, find_prev_try): Remove.
3765         (struct duplicate_eh_regions_data): New.
3766         (duplicate_eh_regions_1): Rewrite.
3767         (duplicate_eh_regions): Return a pointer map instead of an
3768         integer offset.
3769         (copy_eh_region_1, copy_eh_region, push_reachable_handler): Remove.
3770         (redirect_eh_edge_to_label): Remove.
3771         (eh_region_outermost): Rewrite using eh_region pointers
3772         instead of integers.
3773         (add_ttypes_entry): Update for ttype_data move to eh_status.
3774         (add_ehspec_entry): Rewrite with VEC instead of varray.
3775         (assign_filter_values): Likewise.  Export.
3776         (build_post_landing_pads, connect_post_landing_pads): Remove.
3777         (dw2_build_landing_pads): Rewrite to use lp_array.
3778         (struct sjlj_lp_info, sjlj_find_directly_reachable_regions): Remove.
3779         (sjlj_assign_call_site_values): Rewrite to use lp_array.
3780         (sjlj_emit_dispatch_table, sjlj_build_landing_pads): Likewise.
3781         (sjlj_mark_call_sites): Update for landing pad numbers.
3782         (finish_eh_generation): Rewrite.
3783         (gate_handle_eh): Do nothing for no eh tree.
3784         (pass_rtl_eh): Move up near finish_eh_generation.
3785         (remove_eh_landing_pad): New.
3786         (remove_eh_handler): Export.
3787         (remove_eh_region, remove_eh_handler_and_replace): Remove.
3788         (for_each_eh_label): Rewrite to use lp_array.
3789         (make_reg_eh_region_note): New.
3790         (make_reg_eh_region_note_nothrow_nononlocal): New.
3791         (insn_could_throw_p): New.
3792         (copy_reg_eh_region_note_forward): New.
3793         (copy_reg_eh_region_note_backward): New.
3794         (check_handled, add_reachable_handler): Remove.
3795         (reachable_next_level, foreach_reachable_handler): Remove.
3796         (arh_to_landing_pad, arh_to_label, reachable_handlers): Remove.
3797         (get_eh_region_and_lp_from_rtx): New.
3798         (get_eh_region_from_rtx): New.
3799         (can_throw_internal_1, can_throw_external_1): Remove.
3800         (can_throw_internal): Use get_eh_region_from_rtx.
3801         (can_throw_external): Use get_eh_region_and_lp_from_rtx.
3802         (insn_nothrow_p, can_nonlocal_goto): New.
3803         (expand_builtin_eh_common, expand_builtin_eh_pointer): New.
3804         (expand_builtin_eh_filter, expand_builtin_eh_copy_values): New.
3805         (add_action_record): Use VEC not varray.
3806         (collect_one_action_chain): Update for eh_region changes.
3807         (convert_to_eh_region_ranges): Make static.  Use VEC not varray.
3808         Use get_eh_region_and_lp_from_rtx.
3809         (gate_convert_to_eh_region_ranges): New.
3810         (pass_convert_to_eh_region_ranges): Use it.
3811         (push_uleb128, push_sleb128): Use VEC not varray.
3812         (output_one_function_exception_table): Likewise.
3813         (dump_eh_tree): Update for eh_region changes.
3814         (verify_eh_tree): Likewise.
3815         (verify_eh_region, default_init_unwind_resume_libfunc): Remove.
3816         * tree-eh.c: Include target.h.
3817         (add_stmt_to_eh_lp_fn): Rename from add_stmt_to_eh_region_fn.
3818         Don't disallow GIMPLE_RESX; adjust argument check.
3819         (add_stmt_to_eh_lp): Rename from add_stmt_to_eh_region.
3820         (record_stmt_eh_region): Update for landing pad numbers;
3821         generate a landing pad if necessary.
3822         (remove_stmt_from_eh_lp): Rename from remove_stmt_from_eh_region.
3823         (remove_stmt_from_eh_lp_fn): Similarly.
3824         (lookup_stmt_eh_lp_fn): Rename from lookup_stmt_eh_region_fn.
3825         Update for lp numbers; don't special case missing throw_stmt_table.
3826         (lookup_expr_eh_lp): Similarly.
3827         (lookup_stmt_eh_lp): Rename from lookup_stmt_eh_region.
3828         (eh_seq, eh_region_may_contain_throw): New.
3829         (struct leh_state): Add ehp_region.
3830         (struct leh_tf_state): Remove eh_label.
3831         (emit_post_landing_pad): New.
3832         (emit_resx, emit_eh_dispatch): New.
3833         (note_eh_region_may_contain_throw): New.
3834         (frob_into_branch_around): Take eh_region not eh label;
3835         emit eh code into eh_seq.
3836         (honor_protect_cleanup_actions): Early exit for no actions.  Don't
3837         handle EXC_PTR_EXPR, FILTER_EXPR.  Use gimple_build_eh_must_not_throw,
3838         lower_eh_must_not_throw.  Emit code to eh_seq.
3839         (lower_try_finally_nofallthru): Emit eh code to eh_seq.
3840         (lower_try_finally_onedest): Likewise.
3841         (lower_try_finally_copy): Likewise.
3842         (lower_try_finally_switch): Likewise.
3843         (lower_try_finally): Initialize ehp_region.
3844         (lower_catch): Update for eh_catch objects.
3845         (lower_eh_filter): Don't handle must_not_throw.
3846         (lower_eh_must_not_throw): New.
3847         (lower_cleanup): Don't set eh_label.
3848         (lower_eh_constructs_2): Resolve eh builtins.
3849         Handle GIMPLE_EH_MUST_NOT_THROW.
3850         (lower_eh_constructs): Initialize eh_region_may_contain_throw.
3851         Add eh_seq to the end of the function body.
3852         (make_eh_dispatch_edges): New.
3853         (make_eh_edge): Remove.
3854         (make_eh_edges): Simplify for landing pads.
3855         (redirect_eh_edge_1): New.
3856         (redirect_eh_edge): Use it.
3857         (redirect_eh_dispatch_edge): New.
3858         (stmt_could_throw_p): Use a switch.  Allow RESX.
3859         (stmt_can_throw_external): Use lookup_stmt_eh_lp.
3860         (stmt_can_throw_internal): Likewise.
3861         (maybe_clean_eh_stmt_fn, maybe_clean_eh_stmt): New.
3862         (maybe_clean_or_replace_eh_stmt): Update for landing pads.
3863         (maybe_duplicate_eh_stmt_fn, maybe_duplicate_eh_stmt): New.
3864         (gate_refactor_eh): New.
3865         (pass_refactor_eh): Use it.
3866         (lower_resx, execute_lower_resx, pass_lower_resx): New.
3867         (lower_eh_dispatch, execute_lower_eh_dispatch): New.
3868         (gate_lower_ehcontrol, pass_lower_eh_dispatch): New.
3869         (remove_unreachable_handlers): Rename from
3870         tree_remove_unreachable_handlers; rewrite for landing pads;
3871         call remove_eh_handler directly.
3872         (remove_unreachable_handlers_no_lp): New.
3873         (unsplit_eh, unsplit_all_eh): New.
3874         (tree_empty_eh_handler_p, all_phis_safe_to_merge): Remove.
3875         (cleanup_empty_eh_merge_phis, cleanup_empty_eh_move_lp): New.
3876         (cleanup_empty_eh_unsplit): New.
3877         (cleanup_empty_eh): Rewrite.
3878         (cleanup_all_empty_eh): New.
3879         (execute_cleanup_eh): Rename from cleanup_eh.  Remove unreachable
3880         handlers first.  Use unsplit_all_eh, cleanup_all_empty_eh.
3881         (gate_cleanup_eh): New.
3882         (pass_cleanup_eh): Use it.
3883         (verify_eh_edges): Move later in file.  Expect one EH edge.
3884         (verify_eh_dispatch_edge): New.
3885
3886         * Makefile.in (FUNCTION_H): Use vecprim.h, not varray.h.
3887         (gtype-desc.o): Add TARGET_H.
3888         (tree.o): Use EXCEPT_H, not except.h.
3889         (cfgbuild.o): Add EXPR_H.
3890         (GTFILES): Add vecprim.h.
3891         * builtins.c (expand_builtin): Handle BUILT_IN_EH_POINTER,
3892         BUILT_IN_EH_FILTER, BUILT_IN_EH_COPY_VALUES.
3893         * builtins.def (BUILT_IN_UNWIND_RESUME, BUILT_IN_EH_POINTER,
3894         BUILT_IN_EH_FILTER, BUILT_IN_EH_COPY_VALUES): New.
3895         * calls.c (emit_call_1): Use make_reg_eh_region_note.
3896         * cfgbuild.c (control_flow_insn_p): Use can_nonlocal_goto; tidy
3897         calls to can_throw_internal.
3898         (rtl_make_eh_edge): Use get_eh_landing_pad_from_rtx.
3899         (make_edges): Don't handle RESX; use can_nonlocal_goto.
3900         * cfgexpand.c (expand_gimple_stmt_1): Don't handle RESX.
3901         (expand_gimple_stmt): Use make_reg_eh_region_note.
3902         (expand_debug_expr): Don't handle EXC_PTR_EXPR and FILTER_EXPR.
3903         (gimple_expand_cfg): Don't call convert_from_eh_region_ranges,
3904         or find_exception_handler_labels.
3905         * cfgrtl.c (rtl_verify_flow_info_1): Don't handle RESX.  Assert
3906         there is exacly one EH edge.  Use can_nonlocal_goto and
3907         can_throw_internal.
3908         * cgraphunit.c (update_call_expr): Use maybe_clean_eh_stmt_fn.
3909         (cgraph_materialize_all_clones): Use maybe_clean_or_replace_eh_stmt.
3910         * combine.c (can_combine_p, try_combine): Use insn_nothrow_p.
3911         * cse.c (count_reg_usage, insn_live_p): Use insn_could_throw_p.
3912         * dce.c (deletable_insn_p_1): Don't test may_trap_p.
3913         (deletable_insn_p): Use insn_nothrow_p; reorder nonjump insn test.
3914         * dse.c (scan_insn): Use insn_could_throw_p.
3915         * emit-rtl.c (try_split): Use copy_reg_eh_region_note_backward.
3916         * expr.c (expand_expr_real): Use make_reg_eh_region_note.
3917         (expand_expr_real_1): Don't handle RESX, EXC_PTR, or FILTER_EXPR.
3918         * fold-const.c (tree_expr_nonnegative_warnv_p): Don't handle
3919         EXC_PTR_EXPR or FILTER_EXPR.
3920         (tree_expr_nonzero_warnv_p): Likewise.
3921         * function.h: Include vecprim.h, not varray.h
3922         (struct rtl_eh): Remove filter, exc_ptr, built_landing_pad members;
3923         move ttype_data and ehspec_data members to struct eh_status; change
3924         action_record_data member to a VEC.
3925         * gcse.c (hash_scan_set): Use can_throw_internal.
3926         * gengtype.c (open_base_files): Add target.h to gtype-desc.c.
3927         * gimple-iterator.c (gsi_replace): Use maybe_clean_or_replace_eh_stmt.
3928         * gimple-low.c (lower_stmt): Handle GIMPLE_EH_MUST_NOT_THROW.
3929         (block_may_fallthru): Don't handle RESX_EXPR.
3930         * gimple-pretty-print.c (dump_gimple_label): Dump EH_LANDING_PAD_NR.
3931         (dump_gimple_eh_must_not_throw, dump_gimple_eh_dispatch): New.
3932         (dump_gimple_stmt): Dump landing pad information with TDF_EH;
3933         handle GIMPLE_EH_MUST_NOT_THROW, GIMPLE_EH_DISPATCH.
3934         * gimple.c (gss_for_code): Handle GIMPLE_EH_MUST_NOT_THROW,
3935         GIMPLE_EH_DISPATCH, GIMPLE_RESX.
3936         (gimple_size): Likewise.
3937         (gimple_build_eh_dispatch, gimple_build_eh_must_not_throw): New.
3938         (gimple_build_resx): Use gimple_build_with_ops.
3939         (DEFTREECODE): Don't handle EXC_PTR_EXPR, FILTER_EXPR.
3940         (is_gimple_val): Likewise.
3941         (is_gimple_stmt): Remove RESX_EXPR.
3942         * gimple.def (GIMPLE_EH_MUST_NOT_THROW, GIMPLE_EH_DISPATCH): New.
3943         (GIMPLE_RESX): Reorder with other EH constructs.
3944         * gimple.h (struct gimple_statement_eh_mnt): New.
3945         (struct gimple_statement_eh_ctrl): Rename from gimple_statement_resx.
3946         (gimple_eh_filter_must_not_throw): Remove.
3947         (gimple_eh_filter_set_must_not_throw): Remove.
3948         (gimple_eh_must_not_throw_fndecl): New.
3949         (gimple_eh_dispatch_region, gimple_eh_dispatch_set_region): New.
3950         (is_gimple_resx): New.
3951         * gimplify.c (gimplify_expr): Don't handle EXC_PTR_EXPR, RESX_EXPR.
3952         Don't copy EH_FILTER_MUST_NOT_THROW.
3953         * gsstruct.def (GSS_EH_MNT, GSS_EHCONTROL): New.
3954         * ipa-inline.c (estimate_function_body_sizes): Don't try to
3955         handle must_not_throw_labels specially.
3956         * ipa-pure-const.c (check_call): Update debug statement for LP.
3957         * ipa-type-escape.c (check_operand): Don't handle EXC_PTR or FILTER.
3958         * ipa-utils.c (get_base_var): Likewise.
3959         * libfunc.h (LTI_unwind_resume, unwind_resume_libfunc): Remove.
3960         * lower-subreg.c (move_eh_region_note): Remove.
3961         (resolve_simple_move): Use copy_reg_eh_region_note_forward.
3962         * omp-low.c (new_omp_context): Update for eh_lp_nr.
3963         (create_task_copyfn): Likewise.
3964         (maybe_catch_exception): Use gimple_build_eh_filter.
3965         * optabs.c (emit_libcall_block): Update test for no-nonlocal-goto
3966         REG_EH_REGION.  Use make_reg_eh_region_note_nothrow_nononlocal.
3967         * passes.c (init_optimization_passes): Add pass_lower_eh_dispatch
3968         and pass_lower_resx.
3969         * print-tree.c (print_node): Dump EH_LANDING_PAD_NR.
3970         * recog.c (peephole2_optimize): Use copy_reg_eh_region_note_backward,
3971         can_throw_internal, can_nonlocal_goto.
3972         * reload1.c (fixup_eh_region_note): Use insn_could_throw_p,
3973         copy_reg_eh_region_note_forward.
3974         (emit_input_reload_insns): Use copy_reg_eh_region_note_forward.
3975         (emit_output_reload_insns): Likewise.
3976         (copy_eh_notes): Remove.
3977         * rtl.def (RESX): Remove.
3978         * rtl.h: Update declarations.
3979         * sese.c (graphite_copy_stmts_from_block): Use maybe_duplicate_eh_stmt.
3980         * tree-cfg.c (make_edges): Handle GIMPLE_EH_DISPATCH.
3981         (update_eh_label): Remove.
3982         (cleanup_dead_labels_eh): New.
3983         (cleanup_deal_labels): Use it instead of update_eh_label.
3984         (gimple_merge_blocks): Update landing pad data structure when
3985         removing a landing pad label.
3986         (remove_useless_stmts_tc): Remove gimple_eh_filter_must_not_throw
3987         test; handle GIMPLE_EH_MUST_NOT_THROW.
3988         (is_ctrl_altering_stmt): Handle GIMPLE_EH_DISPATCH.
3989         (verify_gimple_assign_single): Don't handle EXC_PTR or FILTER_EXPR.
3990         (verify_types_in_gimple_stmt): Handle GIMPLE_EH_DISPATCH.
3991         (verify_stmt): Likewise.  Verify landing pads.
3992         (gimple_redirect_edge_and_branch): Handle GIMPLE_EH_DISPATCH.
3993         (gimple_duplicate_bb): Use maybe_duplicate_eh_stmt.
3994         (struct move_stmt_d): Add eh_map.
3995         (move_stmt_eh_region_nr, move_stmt_eh_region_tree_nr): New.
3996         (move_stmt_r): Remap eh region numbers in builtin calls,
3997         resx and eh_dispatch.
3998         (move_block_to_fn): Remove eh_offset parameter.  Use
3999         maybe_duplicate_eh_stmt_fn.
4000         (find_outermost_region_in_block): Operate on eh_region pointers
4001         instead of region numbers.
4002         (move_sese_region_to_fn): Expect eh_map instead of eh_offset from
4003         duplicate_eh_regions.
4004         * tree-cfgcleanup.c (tree_forwarder_block_p): Move entry block edge
4005         test earlier.  Disallow EH landing pads.
4006         * tree-cfa.c (create_tree_common_ann): Don't set ann->rn.
4007         * tree-flow.h: Update declarations.
4008         (struct tree_ann_common_d): Replace rn with lp_nr.
4009         * tree-inline.c (copy_tree_body_r): Don't handle RESX_EXPR.
4010         (remap_eh_region_nr, remap_eh_region_tree_nr): New.
4011         (remap_gimple_stmt): Remap eh region numbers in builtin calls,
4012         resx and eh_dispatch.
4013         (copy_bb): Use maybe_duplicate_eh_stmt_fn.
4014         (copy_edges_for_bb): Use make_eh_dispatch_edges.
4015         (copy_cfg_body): Expect eh_map instead of eh_region_offset
4016         from duplicate_eh_regions.
4017         (estimate_num_insns): Don't handle EXC_PTR_EXPR or FILTER_EXPR;
4018         update RESX; handle EH_DISPATCH.
4019         (expand_call_inline): Set eh_lp_nr, not eh_region.
4020         (maybe_inline_call_in_expr): Likewise.
4021         * tree-inline.h (struct copy_body_data): Replace eh_region with
4022         eh_lp_nr, eh_region_offset with eh_map.
4023         * tree-optimize.c (execute_fixup_cfg): Use maybe_clean_eh_stmt.
4024         * tree-pass.h (pass_lower_eh_dispatch, pass_lower_resx): New.
4025         * tree-pretty-print.c (dump_generic_node): Don't handle
4026         EXC_PTR_EXPR, FILTER_EXPR, RESX_EXPR.
4027         * tree-sra.c (scan_function): Use maybe_clean_eh_stmt.
4028         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Don't handle
4029         EXC_PTR_EXPR, FILTER_EXPR.
4030         * tree-ssa-operands.c (get_expr_operands): Likewise.
4031         * tree-ssa-propagate.c (valid_gimple_rhs_p): Likewise.
4032         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Likewise.
4033         (ao_ref_init_from_vn_reference): Likewise.
4034         * tree-ssa-sink.c (statement_sink_location): Likewise.
4035         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
4036         (mark_virtual_phi_result_for_renaming): Export.  Tidy.
4037         * tree-ssa-pre.c (get_or_alloc_expr_for): Don't handle
4038         EXC_PTR_EXPR, FILTER_EXPR.
4039         (is_exception_related): Remove.
4040         (compute_avail): Don't call it.
4041         * tree-ssa-structalias.c: Remove VEC definitions for int and unsigned.
4042         * tree.c (find_decls_types_in_eh_region): Update for eh_region changes.
4043         (find_decls_types_in_node): Use FOR_ALL_EH_REGION_FN.
4044         (build_common_builtin_nodes): Add enable_cxa_end_cleanup parameter.
4045         Build EH builtins.
4046         (build_resx): Remove.
4047         * tree.def (EXC_PTR_EXPR, FILTER_EXPR, RESX_EXPR): Remove.
4048         * tree.h: Update declarations.
4049         (EH_FILTER_MUST_NOT_THROW): Remove.
4050         (struct tree_label_decl): Add eh_landing_pad_nr.
4051         (EH_LANDING_PAD_NR): New.
4052         * value-prof.c (gimple_ic): Tidy variable names.  Update for
4053         landing pad numbers.
4054         (gimple_stringop_fixed_value): Tidy variable names.  Assert
4055         that neither call stmt can throw.
4056         * vecprim.h (uchar): New.
4057         (VEC(uchar,heap), VEC(uchar,gc)): New.
4058
4059         * c-common.c (c_define_builtins): Update call to
4060         build_common_builtin_nodes.
4061         * c-parser.c (c_parse_file): Don't call
4062         default_init_unwind_resume_libfunc.
4063
4064 2009-09-14  Richard Sandiford  <rdsandiford@googlemail.com>
4065
4066         * config/mips/mips-protos.h (mips_cfun_has_cprestore_slot_p): Declare.
4067         (mips_cprestore_address_p): Likewise.
4068         (mips_save_gp_to_cprestore_slot): Likewise.
4069         (mips_restore_gp): Rename to...
4070         (mips_restore_gp_from_cprestore_slot): ...this.
4071         (mips_must_initialize_gp_p): Declare.
4072         (mips_emit_save_slot_move): Likewise.
4073         (mips_output_load_label): Return nothing.
4074         (mips_eh_uses): Declare.
4075         * config/mips/mips.h (TARGET_SPLIT_CALLS): Require epilogue_completed.
4076         (TARGET_CPRESTORE_DIRECTIVE): New macro.
4077         (TARGET_ABSOLUTE_JUMPS): Likewise.
4078         (EH_USES): Likewise.
4079         (FIRST_PSEUDO_REGISTER): Update comment.
4080         (MIPS_ABSOLUTE_JUMP): New macro, extracted from...
4081         (MIPS_CALL): ...here.
4082         (REGISTER_NAMES): Add $cprestore.
4083         * config/mips/mips.c (machine_function): Remove has_gp_insn_p.
4084         Add load_label_length, has_inflexible_gp_insn_p,
4085         has_flexible_gp_insn_p, must_initialize_gp_p and
4086         must_restore_gp_when_clobbered_p.
4087         (mips_expand_call): Don't generate split instructions here.
4088         (mips_split_call): Update the call to mips_restore_gp after
4089         the above name change.
4090         (mips16_cfun_returns_in_fpr_p): Move earlier in file.
4091         (mips_find_gp_ref): New function.
4092         (mips_insn_has_inflexible_gp_ref_p): Likewise.
4093         (mips_cfun_has_inflexible_gp_ref_p): Likewise.
4094         (mips_insn_has_flexible_gp_ref_p): Likewise.
4095         (mips_cfun_has_flexible_gp_ref_p): Likewise.
4096         (mips_function_has_gp_insn): Delete.
4097         (mips_global_pointer): Drop the df_regs_ever_live_p check.
4098         Use the new functions above.  Only return INVALID_REGNUM
4099         for TARGET_ABSOLUTE_JUMPS.
4100         (mips_must_initialize_gp_p): New function.
4101         (mips_get_cprestore_base_and_offset): New function, extracted from...
4102         (mips_cprestore_slot): ...here.  Take a bool parameter.
4103         (mips_cfun_has_cprestore_slot_p): New function.
4104         (mips_cprestore_address_p): Likewise.
4105         (mips_save_gp_to_cprestore_slot): Likewise.
4106         (mips_restore_gp): Rename to...
4107         (mips_restore_gp_from_cprestore_slot): ...this.  Assert
4108         epilogue_completed.  Update the call to mips_cprestore_slot.
4109         Test cfun->machine->must_restore_gp_when_clobbered_p.
4110         (mips_direct_save_slot_move_p): New function.
4111         (mips_emit_save_slot_move): Likewise.
4112         (mips_output_cplocal): Test mips_must_initialize_gp_p () instead
4113         of cfun->machine->global_pointer.
4114         (mips_output_function_prologue): Check mips_must_initialize_gp_p ().
4115         (mips_save_reg): Use mips_emit_save_slot_move.
4116         (mips_expand_prologue): Set must_initialize_gp_p.
4117         Use mips_cfun_has_cprestore_slot_p.  Use gen_potential_cprestore
4118         for all cprestore saves.  Emit a use_cprestore instruction after
4119         setting up the cprestore slot.
4120         (mips_restore_reg): Use mips_emit_save_slot_move.
4121         (mips_process_load_label): New function.
4122         (mips_load_label_length): Likewise.
4123         (mips_output_load_label): Don't return asm: output it here instead.
4124         Use mips_process_load_label.
4125         (mips_adjust_insn_length): Adjust the length of branch instructions
4126         that have length MAX_PIC_BRANCH_LENGTH.
4127         (mips_output_conditional_branch): Update the call to
4128         mips_output_load_label.  Assume the branch target is OPERANDS[0]
4129         rather than OPERANDS[1].  Use MIPS_ABSOLUTE_JUMP for absolute jumps.
4130         (mips_output_order_conditional_branch): Swap the meaning of
4131         OPERANDS[0] and OPERANDS[1].
4132         (mips_variable_issue): Don't count ghost instructions.
4133         (mips_expand_ghost_gp_insns): New function.
4134         (mips_reorg): Rerun mips_reorg_process_insns if it returns true.
4135         (mips_output_mi_thunk): Set must_initialize_gp_p.
4136         (mips_eh_uses): New function.
4137         * config/mips/predicates.md (cprestore_save_slot_operand)
4138         (cprestore_load_slot_operand): New predicates.
4139         * config/mips/mips.md (UNSPEC_POTENTIAL_CPRESTORE): New unspec.
4140         (UNSPEC_MOVE_GP): Likewise.
4141         (UNSPEC_CPRESTORE, UNSPEC_RESTORE_GP, UNSPEC_EH_RETURN)
4142         (UNSPEC_CONSTTABLE_INT, UNSPEC_CONSTTABLE_FLOAT): Bump to make room.
4143         (CPRESTORE_SLOT_REGNUM): New register.
4144         (MAX_PIC_BRANCH_LENGTH): New constant.
4145         (jal_macro): Use MIPS_ABSOLUTE_JUMPS.
4146         (length): Use MAX_PIC_BRANCH_LENGTH as a placeholder for PIC long
4147         branches.  Fix commentary.
4148         (loadgp_newabi_<mode>): Change from unspec_volatile to unspec.
4149         Only split if mips_must_initialize_gp_p; expand to nothing otherwise.
4150         Change type to "ghost".
4151         (loadgp_absolute_<mode>): Likewise.
4152         (loadgp_rtp_<mode>): Likewise.
4153         (copygp_mips16): Likewise.
4154         (loadgp_blockage): Remove redundant mode attribute.
4155         (potential_cprestore): New instruction.
4156         (cprestore): Turn into an unspec set.
4157         (use_cprestore): New instruction.
4158         (*branch_fp): Swap operands 0 and 1.  Remove redundant mode attribute.
4159         (*branch_fp_inverted): Likewise.
4160         (*branch_order<mode>): Likewise.
4161         (*branch_order<mode>_inverted): Likewise.
4162         (*branch_equality<mode>): Likewise.
4163         (*branch_equality<mode>_inverted): Likewise.
4164         (*branch_bit<bbv><mode>): Likewise.
4165         (*branch_bit<bbv><mode>_inverted): Likewise.
4166         (*branch_equality<mode>_mips16): Remove redundant mode.
4167         (jump): Turn into a define_expand.
4168         (*jump_absolute): New instruction.
4169         (*jump_pic): Likewise.
4170         (*jump_mips16): Rename previously-unnamed pattern.  Remove
4171         redundant mode attribute.
4172         (restore_gp): Split on epilogue_completed rather than
4173         reload_completed.  Change type to "ghost".
4174         (move_gp<mode>): New instruction.
4175         * config/mips/mips-dsp.md (mips_bposge): Swap operands 0 and 1.
4176         Remove redundant mode attribute.
4177         * config/mips/mips-ps-3d.md (bc1any4t): Likewise.
4178         (bc1any4f, bc1any2t, bc1any2f): Likewise.
4179         (*branch_upper_lower, *branch_upper_lower_inverted): Likewise.
4180
4181 2009-09-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
4182
4183         PR target/41210
4184         * config/rs6000/rs6000.c (rs6000_function_value): V2DF and V2DI
4185         are returned in the same register (vs34 or v2) that Altivec vector
4186         types are returned in.
4187         (rs6000_libcall_value): Ditto.
4188
4189         PR target/41331
4190         * config/rs6000/rs6000.c (rs6000_emit_move): Use gen_add3_insn
4191         instead of explicit addsi3/adddi3 calls.
4192         (rs6000_split_multireg_move): Ditto.
4193         (rs6000_emit_allocate_stack): Ditto.
4194         (rs6000_emit_prologue): Ditto.
4195         (rs6000_output_mi_thunk): Ditto.
4196
4197         * config/rs6000/rs6000.md (bswapdi*): Don't assume the pointer
4198         size is 64 bits if we can use 64-bit registers.
4199
4200 2009-09-14  Bernd Schmidt  <bernd.schmidt@analog.com>
4201
4202         * config/bfin/bfin.c (bfin_longcall_p): Don't use short calls for weak
4203         symbols.
4204
4205         From Jie Zhang <jie.zhang@analog.com>:
4206         * config/bfin/bfin.c (bfin_expand_prologue): Ask do_link to
4207         save FP and RETS with saveall attribute.
4208         (bfin_expand_epilogue): Ask do_unlink to restore FP and RETS
4209         with saveall attribute.
4210
4211         * config/bfin/bfin.c (bfin_expand_builtin,
4212         case BFIN_BUILTIN_MULT_1X32X32): Force constants to registers for the
4213         operands.
4214
4215         From Jie Zhang <jie.zhang@analog.com>:
4216         * config/bfin/bfin.c (bfin_expand_builtin): Initialize icodes
4217         before use in two places.
4218         * config/bfin/bfin.md (AREG): Define mode iterator.
4219         (reload_in, reload_out): Use mode iterator AREG.
4220
4221 2009-09-14  Richard Guenther  <rguenther@suse.de>
4222
4223         PR middle-end/41350
4224         * dwarf2out.c (dwarf2out_begin_prologue): Adjust non-CFI asm
4225         EH personality path.
4226
4227 2009-09-13  Richard Guenther  <rguenther@suse.de>
4228             Rafael Avila de Espindola  <espindola@google.com>
4229
4230         * langhooks-def.h (LANG_HOOKS_EH_RUNTIME_TYPE): Define.
4231         (LANG_HOOKS_EH_PERSONALITY): Likewise.
4232         (LANG_HOOKS_INITIALIZER): Adjust.
4233         (lhd_pass_through_t): Declare.
4234         * langhooks.h (struct lang_hooks): Add eh_runtime_type and
4235         eh_personality.
4236         * langhooks.c (lhd_pass_through_t): New function.
4237         * dwarf2out.c (output_call_frame_info, dwarf2out_do_cfi_startproc,
4238         dwarf2out_begin_prologue): Use personality from current_function_decl.
4239         * expr.h (get_personality_function): Declare.
4240         * expr.c (get_personality_function): New function.
4241         (build_personality_function): Likewise.
4242         * libfuncs.h (libfunc_index): Remove LTI_eh_personality.
4243         (eh_personality_libfunc): Remove.
4244         * optabs.c (build_libfunc_function): New function split out from ...
4245         (init_one_libfunc): ... here.
4246         * tree.h (DECL_FUNCTION_PERSONALITY): New.
4247         (tree_function_decl): Add personality.
4248         (lhd_gcc_personality): Declare.
4249         (build_personality_function): Likewise.
4250         * tree.c (gcc_eh_personality_decl): New.
4251         (lhd_gcc_personality): New function.
4252         * except.h (lang_eh_runtime_type): Remove.
4253         (enum eh_personality_kind): New.
4254         (build_personality_function): Declare.
4255         (function_needs_eh_personality): Declare.
4256         * except.c (lang_eh_runtime_type): Remove.
4257         (function_needs_eh_personality): New function.
4258         (add_type_for_runtime): Call lang_hooks.type_for_runtime instead.
4259         (sjlj_emit_function_enter, output_function_exception_table):
4260         Use personality from current_function_decl.
4261         * tree-eh.c (lower_eh_constructs): Set DECL_FUNCTION_PERSONALITY.
4262         * tree-inline.c (tree_can_inline_p): Do not inline across different
4263         EH personalities.
4264         (expand_call_inline): Likewise.  Adjust the callers EH personality.
4265         (tree_function_versioning): Copy DECL_FUNCTION_PERSONALITY.
4266         * cgraph.c (cgraph_add_new_function): Set DECL_FUNCTION_PERSONALITY.
4267         * Makefile.in (cgraph.o): Add $(EXCEPT_H) dependency.
4268         (c-parser.o): Likewise
4269         * c-tree.h (c_eh_initialized_p): Remove.
4270         (c_maybe_initialize_eh): Likewise.
4271         * c-decl.c (finish_decl): Don't call c_maybe_initialize_eh.
4272         (finish_decl): Don't call c_maybe_initialize_eh.
4273         (c_eh_initialized_p): Remove.
4274         (c_maybe_initialize_eh): Likewise.
4275         * c-parser.c (c_parser_omp_construct): Likewise.
4276         (c_parse_file): Initialize exception handling.
4277
4278 2009-09-13  Kai Tietz  <kai.tietz@onevision.com>
4279
4280         * config.gcc (tm_file): Remove i386/biarch32.h
4281         for i?86-w64-mingw* case.
4282         (i?86-*-mingw* andx86_64-*-mingw*): Add multilib
4283         support.
4284         * config.host: Set for x64 mingw the option
4285         use_long_long_for_widest_fast_int to yes.
4286
4287 2009-09-13  Eric Botcazou  <ebotcazou@adacore.com>
4288
4289         * tree.h (DECL_IGNORED_P): Document further effect for FUNCTION_DECL.
4290         * dbxout.c (dbxout_function_end): Do not test DECL_IGNORED_P.
4291         (dbxout_begin_function): Likewise.
4292         * final.c (dwarf2_debug_info_emitted_p): New predicate.
4293         (final_start_function): Do not emit debug info if DECL_IGNORED_P is
4294         set on the function.
4295         (final_end_function): Likewise.
4296         (final_scan_insn): Likewise.
4297         (rest_of_handle_final): Likewise.
4298         * varasm.c (assemble_start_function): Likewise.
4299         * config/rs6000/xcoff.h (ASM_DECLARE_FUNCTION_NAME): Likewise.
4300
4301 2009-09-12  Jason Merrill  <jason@redhat.com>
4302
4303         * dbgcnt.c (dbg_cnt_process_single_pair): constify.
4304         * opts.c (common_handle_option): constify.
4305
4306 2009-09-12  Gerald Pfeifer  <gerald@pfeifer.com>
4307
4308         * doc/install.texi (avr): Remove obsolete reference site.
4309
4310 2009-09-12  Gerald Pfeifer  <gerald@pfeifer.com>
4311
4312         * doc/install.texi (Binaries): Adjust AIX link.
4313
4314 2009-09-12  Akim Demaille  <demaille@gostai.com>
4315
4316         * doc/invoke.texi (-fstrict-aliasing): Correct two examples.
4317         Use an imperative sentence.
4318
4319 2009-09-11  Richard Henderson  <rth@redhat.com>
4320
4321         * gsstruct.def (DEFGSSTRUCT): Remove printable-name argument; add
4322         structure-name and has-tree-operands arguments; update all entries.
4323         * gimple.def (DEFGSCODE): Replace 3rd argument with GSS_symbol;
4324         update all entries.
4325         * gimple.c (gimple_ops_offset_): Use HAS_TREE_OP argument.
4326         (gsstruct_code_size): New.
4327         (gss_for_code_): New.
4328         (gss_for_code): Remove.
4329         (gimple_size): Rewrite using gsstruct_code_size.
4330         (gimple_statement_structure): Move to gimple.h.
4331         * gimple.h (gimple_ops_offset_, gss_for_code_): Declare.
4332         (gss_for_code, gimple_statement_structure): New.
4333         (gimple_ops): Use new arrays; tidy.
4334
4335 2009-09-11  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
4336
4337         * config/pa/predicates.md (symbolic_operand): Require a CONST symbolic
4338         operand to be a PLUS expression.
4339         * config/pa/pa.c (pa_secondary_reload): Likewise.
4340
4341 2009-09-11  Jakub Jelinek  <jakub@redhat.com>
4342
4343         * combine.c (propagate_for_debug_subst): Call wrap_constant on top.
4344
4345         * print-rtl.c (print_rtx): Use JUMP_LABEL (in_rtx) instead of
4346         XEXP (in_rtx, 8).
4347
4348 2009-09-11  Bernd Schmidt  <bernd.schmidt@analog.com>
4349
4350         From Jie Zhang <jie.zhang@analog.com>:
4351         * doc/extend.texi (node Function Attributes): Document l2
4352         function attribute.
4353         (node Blackfin Variable Attributes): Document l2 variable attributes.
4354
4355 2009-09-11  Loren J. Rittle  <ljrittle@acm.org>
4356
4357         * config.gcc (*-*-freebsd*): Enable default_use_cxa_atexit
4358         to match the system compiler's configuration at inflection point.
4359         Add comment to remark a remaining difference with system compiler.
4360
4361         * configure.ac (*-*-freebsd*): Enable check for __stack_chk_fail.
4362         * configure: Regenerate.
4363
4364 2009-09-11  Bernd Schmidt  <bernd.schmidt@analog.com>
4365
4366         From Jie Zhang <jie.zhang@analog.com>:
4367         * config/bfin/bfin.c (bfin_expand_call): Handle L2 functions.
4368         (bfin_handle_l2_attribute): New.
4369         (bfin_attribute_table): Add l2 attribute.
4370
4371 2009-09-11  Michael Matz  <matz@suse.de>
4372
4373         PR middle-end/41275
4374         * tree-inline.c (remap_decls): Don't put DECL_EXTERNAL decls
4375         on the local_decls list.
4376
4377 2009-09-11  Alexandre Oliva  <aoliva@redhat.com>
4378
4379         PR debug/41276
4380         PR debug/41307
4381         * cselib.c (cselib_expand_value_rtx_cb): Document callback
4382         interface.
4383         (cselib_expand_value_rtx_1): Use callback for SUBREGs.  Adjust
4384         for VALUEs, to implement the documented interface.
4385         * var-tracking.c (vt_expand_loc_callback): Handle SUBREGs.
4386         Adjust for VALUEs and anything else, to implement the
4387         documented interface.
4388
4389 2009-09-10  Nathan Froyd  <froydnj@codesourcery.com>
4390
4391         * config/rs6000/rs6000.h (DATA_ALIGNMENT): Check that we are dealing
4392         with actual SPE/paired vector modes before using 64-bit alignment.
4393         Check that TYPE is a REAL_TYPE for TARGET_E500_DOUBLE.
4394
4395 2009-09-10  DJ Delorie  <dj@redhat.com>
4396
4397         * config/mep/mep.md (eh_epilogue): Defer until after epilogue is
4398         emitted.
4399
4400         * config/mep/mep.h (LEGITIMATE_CONSTANT_P): New.
4401         * config/mep/mep.c (mep_legitimate_constant_p): New.
4402         * config/mep/mep-protos.h: Prototype it.
4403
4404 2009-09-10  Richard Henderson  <rth@redhat.com>
4405
4406         * print-rtl.c (print_rtx): Fix JUMP_LABEL index.
4407
4408 2009-09-10  Jason Merrill  <jason@redhat.com>
4409
4410         * tree.c (chain_index): New fn.
4411         * tree.h: Declare it.
4412
4413 2009-09-10  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
4414
4415         * config/sol2-c.c (cmn_err_length_specs): Initialize
4416         scalar_identity_flag.
4417
4418 2009-09-10  Richard Henderson  <rth@redhat.com>
4419
4420         * tree.h (struct tree_decl_common): Move align member earlier;
4421         move label_decl_uid member ...
4422         (struct tree_label_decl): ... here.
4423         (LABEL_DECL_UID): Update to match.
4424
4425         * tree-cfg.c (dump_function_to_file): Dump eh tree with TDF_EH,
4426         not TDF_DETAILS.
4427
4428         * tree-cfg.c (gimple_redirect_edge_and_branch): Do
4429         gimple_try_redirect_by_replacing_jump test after no-op and EH tests.
4430
4431         * tree-cfg.c (split_edge_bb_loc): Don't disallow placement at
4432         dest_prev if the edge is complex.
4433
4434         * tree-cfg.c (is_ctrl_stmt): Use a switch.
4435
4436         * tree-cfg.c (gimple_can_merge_blocks_p): Move label and
4437         loop latch tests earlier.
4438
4439         * gimple-iterator.c (gimple_find_edge_insert_loc): Insert
4440         before GIMPLE_RETURN, not after its predecessor; insert
4441         before GIMPLE_RESX.
4442
4443         * gimple-iterator.c (gimple_find_edge_insert_loc): Use
4444         gimple_seq_empty_p to test for no PHI nodes.
4445         * tree-cfg.c (split_critical_edges): Likewise.
4446
4447         * c-common.h (c_dialect_cxx, c_dialect_objc): Boolify.
4448
4449 2009-09-10  Hariharan Sandanagobalane  <hariharan@picochip.com>
4450
4451         * final.c (shorten_branches) : Ignore DEBUG_INSN_P instructions
4452         introduced by the VTA branch merge.
4453
4454 2009-09-10  Uros Bizjak  <ubizjak@gmail.com>
4455
4456         * ira-conflicts.c: Use fputs or putc instead of fprintf
4457         where appropriate.
4458         * cfg.c: Ditto.
4459         * toplev.c: Ditto.
4460         * tree-switch-conversion.c: Ditto.
4461
4462 2009-09-10  Hariharan Sandanagobalane  <hariharan@picochip.com>
4463
4464         * config/picochip/picochip.c : Ignore DEBUG_INSN_P instructions
4465         introduced by the VTA branch merge.
4466
4467 2009-09-10  Uros Bizjak  <ubizjak@gmail.com>
4468
4469         Revert:
4470         2009-09-09  Uros Bizjak  <ubizjak@gmail.com>
4471
4472         PR rtl-optimization/39779
4473         * expr.c (convert_modes): Return when mode == oldmode after
4474         CONST_INTs are processed.
4475
4476 2009-09-10  Nick Clifton  <nickc@redhat.com>
4477
4478         * config/mep/mep.c (mep_encode_section_info): Copy weakness
4479         attribute and referring decl when creating renamed symbol.
4480
4481 2009-09-10  Richard Guenther  <rguenther@suse.de>
4482
4483         PR middle-end/41257
4484         * cgraphunit.c (cgraph_emit_thunks): Emit thunks only for
4485         reachable nodes.
4486         (cgraph_finalize_compilation_unit): Compute reachability
4487         before emitting thunks.  Properly process aliases before
4488         possibly removing unreachable nodes.
4489
4490 2009-09-10  Richard Guenther  <rguenther@suse.de>
4491
4492         PR middle-end/41254
4493         * tree.c (struct free_lang_data_d): Add worklist member.
4494         (find_decls_types_r): Push onto the worklist instead of recursing.
4495         Handle TREE_BINFOs properly.
4496         (find_decls_types): New function wrapped around find_decls_types_r
4497         to process the worklist.
4498         (find_decls_types_in_eh_region): Use it.
4499         (find_decls_types_in_node): Likewise.
4500         (find_decls_types_in_var): Likewise.
4501         (free_lang_data_in_cgraph): Likewise.  Free the worklist.
4502         * tree.h (RECORD_OR_UNION_TYPE_P): New.
4503         (AGGREGATE_TYPE_P): Adjust.
4504
4505 2009-09-09  Jason Merrill  <jason@redhat.com>
4506
4507         * configure.ac: Check glibc version even if we have an in-tree
4508         assembler.
4509
4510 2009-09-09  Anthony Green  <green@moxielogic.com>
4511
4512         * config/moxie/moxie.md (*movsi, *movhi, *movqi): Use xor to load
4513         the constant 0 when appropriate.
4514         * config/moxie/constraints.md: Add constraint O.
4515
4516         * config/moxie/moxie.c (moxie_setup_incoming_varargs): Adjust
4517         to pass up to 6 32-bit argument values in registers.
4518         (moxie_function_arg): Ditto.
4519         (moxie_arg_partial_bytes): Ditto.
4520         * config/moxie/moxie.h (FUNCTION_ARG_ADVANCE): Ditto.
4521         (REG_PARM_STACK_SPACE): Ditto.
4522         (FUNCTION_ARG_REGNO_P): Ditto.
4523
4524         * config/moxie/moxie.c (moxie_expand_prologue): Use dec
4525         instruction to allocate stack space.
4526
4527 2009-09-09  Segher Boessenkool  <segher@kernel.crashing.org>
4528
4529         * config/rs6000/rs6000.md (bswapdi2_64bit): Fix
4530         unnecessarily stringent constraints.  Fix address
4531         calculation in the splitters.
4532
4533 2009-09-09  Uros Bizjak  <ubizjak@gmail.com>
4534
4535         PR rtl-optimization/39779
4536         * expr.c (convert_modes): Return when mode == oldmode after
4537         CONST_INTs are processed.
4538
4539 2009-09-09  Kai Tietz  <kai.tietz@onevision.com>
4540
4541         PR/41315
4542         * config/i386.c (ix86_can_use_return_insn_p): Check for padding0, too.
4543         (ix86_expand_prologue): Take frame.padding0 into logic of
4544         to_allocate checks.
4545         (ix86_expand_epilogue): Likewise.
4546
4547 2009-09-09  Jakub Jelinek  <jakub@redhat.com>
4548
4549         * config/t-slibgcc-elf-ver (SHLIB_MAKE_SOLINK, SHLIB_INSTALL_SOLINK):
4550         New variables.
4551         (SHLIB_LINK, SHLIB_INSTALL): Use them.
4552         * config/t-slibgcc-libgcc: New file.
4553         * config.gcc (powerpc*-*-linux*, powerpc*-*-gnu*): Use it.
4554
4555 2009-09-09  Martin Jambor  <mjambor@suse.cz>
4556
4557         PR tree-optimization/41089
4558         * tree-sra.c (find_var_candidates): Do not consider va_lists in
4559         early SRA.
4560
4561 2009-09-09  Richard Henderson  <rth@redhat.com>
4562
4563         * gimple.h (CASE_GIMPLE_OMP): New.
4564         (is_gimple_omp): Use it.
4565         * tree-cfg.c (is_ctrl_altering_stmt): Likewise.
4566         (verify_gimple_debug): Likewise.
4567
4568 2009-09-09  Richard Guenther  <rguenther@suse.de>
4569
4570         PR tree-optimization/41101
4571         * tree-ssa-pre.c (maximal_set): Remove.
4572         (compute_antic_aux): Treat the maximal set as implicitly all ones.
4573         Defer all blocks we didn't visit at least one successor.
4574         (add_to_exp_gen): Do not add to the maximal set.
4575         (make_values_for_phi): Likewise.
4576         (compute_avail): Likewise.
4577         (init_pre): Do not allocate the maximal set.
4578         (execute_pre): Do not dump it.
4579
4580 2009-09-09  Martin Jambor  <mjambor@suse.cz>
4581
4582         * tree-cfg.c (verify_gimple_phi): Check that gimple_phi_result is
4583         an SSA_NAME rather than a is_gimple_variable.
4584
4585 2009-09-09  Richard Guenther  <rguenther@suse.de>
4586
4587         PR middle-end/41317
4588         * tree-ssa-ccp.c (maybe_fold_offset_to_component_ref): Remove
4589         code dealing with plain pointer bases.
4590         (maybe_fold_offset_to_reference): Likewise.
4591         (maybe_fold_stmt_addition): Adjust.
4592
4593 2009-09-09  Richard Guenther  <rguenther@suse.de>
4594
4595         * tree.c (free_lang_data_in_type): Do not free the type variant
4596         chains.
4597         (free_lang_data): Merge char_type_node with its properly signed
4598         variant.
4599         (pass_ipa_free): Collect after freeing language specific data.
4600
4601 2009-09-09  Michael Matz  <matz@suse.de>
4602
4603         PR middle-end/41268
4604         * cfgexpand.c (expand_gimple_stmt_1): Use an int for storing
4605         SUBREG_PROMOTED_UNSIGNED_P, instead of a bool.
4606         * rtl.h (struct rtx, SUBREG_PROMOTED_UNSIGNED_P): Update comments
4607         to reflect reality.
4608
4609 2009-09-08  DJ Delorie  <dj@redhat.com>
4610
4611         * config/mep/mep.c (conversions[]): Add "ml" pattern.
4612
4613 2009-09-04  Jason Merrill  <jason@redhat.com>
4614
4615         * tree.c (tree_find_value): Remove.
4616         * tree.h: Remove prototype.
4617         * varasm.c (assemble_external): Use value_member instead.
4618
4619 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
4620
4621         * toplev.c (process_options): Choose default debugging type when
4622         gtoggle enables debug info and type is unset.
4623
4624 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
4625
4626         PR debug/41276
4627         PR debug/41307
4628         * cselib.c (cselib_expand_value_rtx_1): Don't return copy of
4629         invalid subreg.
4630
4631 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
4632
4633         * configure: Rebuilt with modified libtool.m4.
4634
4635 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
4636
4637         PR debug/41229
4638         PR debug/41291
4639         PR debug/41300
4640         * tree-ssa.c (execute_update_addresses_taken): Update debug insns.
4641
4642 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
4643
4644         * tree-ssa-loop-ivopts.c (get_phi_with_result): Remove.
4645         (remove_statement): Likewise.
4646         (rewrite_use_nonlinear_expr): Adjust.
4647         (remove_unused_ivs): Collect SSA NAMEs to remove and call...
4648         * tree-ssa.c (release_defs_bitset): ... this.  New.
4649         * tree-flow.h (release_defs_bitset): Declare.
4650
4651 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
4652
4653         PR debug/41232
4654         * tree-ssa-phiopt.c (minmax_replacement): Skip debug stmts
4655         in the middle block.
4656
4657 2009-09-08  Kai Tietz  <kai.tietz@onevision.com>
4658
4659         * tree-ssa-reassoc.c (find_operand_rank): Cast pointer
4660         via intptr_t to long type.
4661         (insert_operand_rank): Cast long type via intptr_t to
4662         pointer type.
4663         * genattrtab.c (RTL_HASH): Use intptr_t to cast from
4664         pointer to scalar.
4665         * c-pretty-print.c (pp_c_tree_decl_identifier): Cast
4666         from pointer to unsigned via uintptr_t.
4667
4668         * configure.ac (GCC_STDINT_TYPES): Initialize intptr_t,
4669         uintptr_t, HAVE_INTTYPES_H, HAVE_STDINT_H, HAVE_UINTPTR_T,
4670         and HAVE_INTPTR_T.
4671         * configure: Regenerated.
4672         * config.in: Regenerated
4673         * system.h (stdint.h): Add include.
4674         (inttypes.h): Likewise.
4675         * Makefile.in (aclocal): Add config/stdint.m4.
4676         * aclocal.m4: Regenerated.
4677
4678 2009-09-08  Bernd Schmidt  <bernd.schmidt@analog.com>
4679
4680         * config/bfin/bfin.c (np_check_regno, np_after_branch): New static
4681         variables.
4682         (note_np_check_stores): New function.
4683         (harmless_null_pointer_p): New function.
4684         (trapping_loads_p): New args NP_REG and AFTER_NP_BRANCH.  Callers
4685         changed.  Take into account whether we're in the shadow of a condjump
4686         that tested NP_REG for NULL.
4687         Lose all code that tested for SEQUENCEs.
4688         (workaround_speculation): Avoid inserting NOPs for loads that are
4689         either always executed or a NULL pointer.
4690
4691 2009-09-08  Jan Hubicka  <jh@suse.cz>
4692
4693         * doc/invoke.texi (early-inlining-insns): Reduce from 12 to 8.
4694         * params.def (early-inlining-insns): Likewise.
4695
4696 2009-09-08  Jakub Jelinek  <jakub@redhat.com>
4697
4698         PR rtl-optimization/41239
4699         * sched-int.h (struct deps): Add last_function_call_may_noreturn field.
4700         * sched-rgn.c (deps_join): Join also last_function_call_may_noreturn
4701         lists.
4702         * sched-deps.c (sched_analyze_insn): Prevent moving trapping insns
4703         across calls, as the calls might not always return normally.
4704         (call_may_noreturn_p): New function.
4705         (deps_analyze_insn): Update last_function_call_may_noreturn list.
4706         (init_deps): Initialize it.
4707         (remove_from_deps): Also remove calls from
4708         last_function_call_may_noreturn list.
4709
4710 2009-09-07  Richard Henderson  <rth@redhat.com>
4711
4712         * tree-ssa-sccvn.c (vn_reference_lookup_3): Don't assume there are
4713         more VR->OPERANDS than LHS operands.  Free LHS before returning.
4714
4715 2009-09-07  Bernd Schmidt  <bernd.schmidt@analog.com>
4716
4717         * config/bfin/bfin.md (UNSPEC_VOLATILE_STALL): New constant.
4718         (attr "addrtype"): New member "spreg".
4719         Use it if mem_spfp_address_operand is true for the address.
4720         (attr "type"): New entry "stall".
4721         (cpu_unit "load"): New.
4722         (insn_reservations "load32", "loadp", "loadi"): Add reservation of
4723         "load".
4724         (insn_reservation "loadsp"): New.
4725         (insn_reservation "load_stall1"): New.
4726         (insn_reservation "load_stall3"): New.
4727         (stall): New insn.
4728         * config/bfin/predicates.md (const1_operand, const3_operand): New.
4729         (mem_p_address_operand): Exclude stack and frame pointer based
4730         addresses.
4731         (mem_spfp_address_operand): New; match them here.
4732         * config/bfin/bfin.c (add_sched_insns_for_speculation): New function.
4733         (bfin_reorg): Call it if scheduling insns.
4734         (bfin_gen_bundles): Remove dummy insns created by
4735         add_sched_insns_for_speculation.
4736
4737         From Jie Zhang <jie.zhang@analog.com>:
4738         * config/bfin/bfin-protos.h (enum bfin_cpu_type, bfin_cpu_type,
4739         bfin_si_revision, bfin_workarounds): Move these ...
4740         * config/bfin/bfin.h: ... here.
4741
4742         From Mike Frysinger  <michael.frysinger@analog.com>
4743         * config/bfin/bfin-protos.h (bfin_cpu_type): Add BFIN_CPU_BF542M,
4744         BFIN_CPU_BF544M, BFIN_CPU_BF547M, BFIN_CPU_BF548M, and BFIN_CPU_BF549M.
4745         * config/bfin/bfin.c (bfin_cpus[]): Add 0.3 for bf542m, bf544m,
4746         bf547m, bf548m, and bf549m.
4747         * config/bfin/bfin.h (TARGET_CPU_CPP_BUILTINS): Define __ADSPBF542M__
4748         for BFIN_CPU_BF542M, __ADSPBF544M__ for BFIN_CPU_BF544M,
4749         __ADSPBF547M__ for BFIN_CPU_BF547M, __ADSPBF548M__ for
4750         BFIN_CPU_BF548M, and __ADSPBF549M__ for BFIN_CPU_BF549M.
4751         * config/bfin/t-bfin-elf (MULTILIB_MATCHES): Select bf532-none for
4752         bf542m-none, bf544m-none, bf547m-none, bf548m-none, and bf549m-none.
4753         * config/bfin/t-bfin-linux (MULTILIB_MATCHES): Likewise.
4754         * config/bfin/t-bfin-uclinux (MULTILIB_MATCHES): Likewise.
4755         * doc/invoke.texi (Blackfin Options): Document that -mcpu now accepts
4756         bf542m, bf544m, bf547m, bf548m, and bf549m.
4757
4758         From Jie Zhang <jie.zhang@analog.com>:
4759         * config/bfin/predicates.md (p_register_operand): New predicate.
4760         (dp_register_operand): New predicate.
4761         * config/bfin/bfin-protos.h (WA_05000074): Define.
4762         (ENABLE_WA_05000074): Define.
4763         * config/bfin/bfin.c (bfin_cpus[]): Add WA_05000074 for all cpus.
4764         (bfin_gen_bundles): Put dsp32shiftimm instruction in slot[0].
4765         * config/bfin/bfin.md (define_attr type): Add dsp32shiftimm.
4766         (define_attr addrtype): Allow load/store register to be P register.
4767         (define_attr storereg): New.
4768         (define_cpu_unit anomaly_05000074): New.
4769         (define_insn_reservation dsp32shiftimm): New.
4770         (define_insn_reservation dsp32shiftimm_anomaly_05000074): New.
4771         (define_insn_reservation loadp): Cannot use slot2.
4772         (define_insn_reservation loadsp): Cannot use slot2.
4773         (define_insn_reservation storep): Cannot use slot2. Does not
4774         apply when working around 05000074.
4775         (define_insn_reservation storep_anomaly_05000074): New.
4776         (define_insn_reservation storei): Does not apply when working
4777         around 05000074.
4778         (define_insn_reservation storei_anomaly_05000074): New.
4779         (define_attr length): Add dsp32shiftimm case.
4780         (define_insn movsi_insn32, movsi_insv, ashlsi3_insn, ashrsi3,
4781         ror_one, rol_one, lshrsi3, lshrpdi3, ashrpdi3, movhiv2hi_low,
4782         movhiv2hi_high, composev2hi, packv2hi, movv2hi_hi,
4783         ssashiftv2hi3, ssashifthi3, ssashiftsi3, lshiftv2hi3, lshifthi3):
4784         Set type as dsp32shiftimm for dsp32shiftimm alternatives.
4785
4786 2009-09-07  Martin Jambor  <mjambor@suse.cz>
4787
4788         PR middle-end/41282
4789         * tree-sra.c (create_artificial_child_access): Return NULL if
4790         build_ref_for_offset fails.
4791         (propagate_subacesses_accross_link): Allow build_ref_for_offset
4792         and create_artificial_child_access to fail.
4793
4794 2009-09-06  Dmitry Gorbachev  <d.g.gorbachev@gmail.com>
4795
4796         PR c++/41214
4797         * unwind-dw2.c (uw_init_context_1): Mark noinline.
4798         * config/ia64/unwind-ia64.c (uw_init_context_1): Likewise.
4799         * config/xtensa/unwind-dw2-xtensa.c (uw_init_context_1): Likewise.
4800
4801 2009-09-07  Bernd Schmidt  <bernd.schmidt@analog.com>
4802
4803         * config/bfin/bfin.c (bfin_optimize_loop): When creating a new basic
4804         block, ensure it has an exit edge.  Emit a barrier after a jump.
4805
4806 2009-09-07  Nick Clifton  <nickc@redhat.com>
4807
4808         * gcc.c (this_is_linker_script): New variable.  Like
4809         this_is_library_file but for the %T constructor.
4810         (end_going_arg): If this_is_linker_script is set then locate the
4811         script and insert a --script switch before it
4812         (do_spec_2): Initialise this_is_linker_script.
4813         (do_spec_1): Likewise.  Handle %T construct.
4814         (eval_spec_function): Preserve this_is_linker_script.
4815         * doc/invoke.texi: Document %T construct in spec files.
4816         * config/m32c/m32c.h (LIB_SPEC): Use it.
4817
4818 2009-09-07  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
4819
4820         * rtl.h (PREFETCH_SCHEDULE_BARRIER_P): New macro.
4821         * sched-deps.c (sched_analyze_2): Make prefetches a hard barrier
4822         when volatile flag is set.
4823         * doc/rtl.texi (PREFETCH_SCHEDULE_BARRIER_P): Add documentation pieces.
4824
4825 2009-09-06  Eric Botcazou  <ebotcazou@adacore.com>
4826
4827         PR bootstrap/41241
4828         * combine-stack-adj.c (try_apply_stack_adjustment): Handle stores.
4829         (combine_stack_adjustments_for_block): Allow insns between stack
4830         adjustments and stores with corresponding pre-(dec|inc)rement or
4831         pre-modify operation.
4832
4833 2009-09-06  Jakub Jelinek  <jakub@redhat.com>
4834
4835         PR bootstrap/41241
4836         * combine-stack-adj.c (struct csa_memlist): Rename to...
4837         (struct csa_reflist): ... this.  Rename mem field to ref.
4838         (free_csa_memlist): Rename to...
4839         (free_csa_reflist): ... this.
4840         (record_one_stack_memref): Rename to...
4841         (record_one_stack_ref): ... this.  Handle also REG_P.
4842         (try_apply_stack_adjustment): Handle also REG_P.
4843         (struct record_stack_memrefs_data): Rename to...
4844         (struct record_stack_refs_data): ... this.  Rename memlist field to
4845         reflist.
4846         (record_stack_memrefs): Rename to...
4847         (record_stack_refs): ... this.  For DEBUG_INSNs keep traversing
4848         subexpressions instead of failing when a MEM contains SP references.
4849         For SP itself in DEBUG_INSNs queue it also onto reflist chain.
4850         (combine_stack_adjustments_for_block): Adjust for mem to ref renaming.
4851
4852 2009-09-06  Richard Guenther  <rguenther@suse.de>
4853
4854         PR middle-end/41144
4855         * tree.c (build_array_type): Do not record types marked
4856         with structural equality in the canonical type hashtable.
4857
4858 2009-09-06  Richard Guenther  <rguenther@suse.de>
4859
4860         PR middle-end/41261
4861         * tree-ssa-alias.c (refs_may_alias_p_1): Bail out for function decls.
4862
4863 2009-09-05  Richard Guenther  <rguenther@suse.de>
4864
4865         PR middle-end/41181
4866         * tree-ssa-ccp.c (maybe_fold_stmt_addition): Use the correct type.
4867
4868 2009-09-05  Richard Guenther  <rguenther@suse.de>
4869
4870         PR debug/41273
4871         * tree-ssa-operands.c (get_tmr_operands): Pass through opf_no_vops.
4872
4873 2009-09-05  Richard Guenther  <rguenther@suse.de>
4874
4875         PR middle-end/41271
4876         * tree-ssa.c (useless_type_conversion_p): Drop qualifiers
4877         before comparing function argument types.
4878
4879 2009-09-05  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
4880
4881         PR target/41024
4882         * config/i386/mingw-w64.h (ASM_SPEC): Pass -v instead of -V to
4883         the assembler.
4884
4885 2009-09-04  Uros Bizjak  <ubizjak@gmail.com>
4886
4887         Revert:
4888         2009-08-18  Uros Bizjak  <ubizjak@gmail.com>
4889
4890         * config/alpha/alpha.c (alpha_output_mi_thunk_osf): Allocate insn
4891         locators before emit_insn is called.
4892
4893 2009-09-04  Vladimir Makarov  <vmakarov@redhat.com>
4894
4895         PR bootstrap/41241
4896         * ira.c (update_equiv_reg): Revert my previous patch for the PR.
4897         * reginfo.c (resize_reg_info): Call allocate_reg_info if necessary.
4898         (reginfo_init): Don't call allocate_reg_info.
4899
4900 2009-09-04  Uros Bizjak  <ubizjak@gmail.com>
4901
4902         PR target/41262
4903         * config/alpha/alpha.c (alpha_does_function_need_gp): Use
4904         NONDEBUG_INSN_P instead of INSN_P.
4905
4906 2009-09-04  Alexandre Oliva  <aoliva@redhat.com>
4907
4908         PR debug/41225
4909         * tree-vect-stmts.c (vect_stmt_relevant_p): Skip debug uses.
4910
4911 2009-09-04  Alexandre Oliva  <aoliva@redhat.com>
4912
4913         PR target/41252
4914         * config/arm/vfp.md (*cmpdf_split_vfp): Fix src mode in the second
4915         pattern of the split.
4916
4917 2009-09-04  Alexandre Oliva  <aoliva@redhat.com>
4918
4919         * toplev.c (process_options): Move setter of flag_var_tracking
4920         before other tests that depend on it.  Move down setter of
4921         flag_rename_registers.  Don't enable var-tracking-assignments
4922         by default if selective scheduling is enabled.  Warn if both
4923         are enabled.
4924
4925 2009-09-04  Alexandre Oliva  <aoliva@redhat.com>
4926
4927         * var-tracking.c (dv_is_decl_p): Adjust NULL behavior to match
4928         comment.  Use switch statement to catch overlaps between rtx
4929         and tree codes.  Accept FUNCTION_DECLs in addition to those in...
4930         (IS_DECL_CODE): ... here. Remove.
4931         (check_value_is_not_decl): Remove.
4932         (dv_from_decl, dv_from_value): Check after conversion.
4933
4934 2009-09-04  Richard Guenther  <rguenther@suse.de>
4935
4936         PR middle-end/41257
4937         * (cgraph_finalize_compilation_unit): Move finalizing aliases
4938         after emitting tunks.  Move emitting thunks and ctors from ...
4939         (cgraph_optimize): ... here.  Remove redundant
4940         cgraph_analyze_functions.
4941         * varasm.c (find_decl_and_mark_needed): Remove no longer
4942         necessary check.
4943         (finish_aliases_1): Adjust check for thunk aliases.
4944
4945 2009-09-04  Daniel Gutson  <dgutson@codesourcery.com>
4946
4947         * config/arm/arm.md (ctzsi2): Added braces
4948         to avoid warning that broke booststrap.
4949
4950 2009-09-04  Martin Jambor  <mjambor@suse.cz>
4951
4952         PR tree-optimization/41112
4953         * tree-sra.c (build_ref_for_offset_1): Signal that we cannot
4954         handle variable-bounded arrays.
4955         (expr_with_var_bounded_array_refs_p): New function.
4956         (analyze_access_subtree): Call expr_with_var_bounded_array_refs_p.
4957
4958 2009-09-04  Wolfgang Gellerich  <gellerich@de.ibm.com>
4959
4960         * config/s390/2097.md: Removed two incorrect bypasses.
4961         (z10_fsimpdf): Fixed latency.
4962         (z10_fhex): New insn_reservation.
4963         (z10_floaddf): Fixed latency.
4964         (z10_floadsf): Fixed latency.
4965         (z10_ftrunctf): Fixed latency.
4966         (z10_ftruncdf): Fixed latency.
4967         * config/s390/s390.c (z10_cost): Fixed values.
4968         (s390_adjust_priority): Added z10 path.
4969         * config/s390/s390.md (type): Added fhex.
4970         (*mov<mode>_64dfp): Updated type attribute.
4971         (*mov<mode>_64): Updated type attribute.
4972         (*mov<mode>_31): Updated type attribute.
4973         (*mov<mode>"): Likewise.
4974         * config/s390/2084.md (x_fsimpdf): Updated condition.
4975
4976 2009-09-04  Andreas Krebbel  <krebbel1@de.ibm.com>
4977
4978         * config/s390/s390.md ("*fmadd<mode>", "*fmsub<mode>"): Enable mem
4979         RTXs in the predicate for operand 1.
4980
4981 2009-09-03  Daniel Gutson  <dgutson@codesourcery.com>
4982
4983         * config/arm/arm.md (UNSPEC_RBIT): New constant.
4984         (rbitsi2): New insn.
4985         (ctzsi2): New expand.
4986         * config/arm/arm.h (CTZ_DEFINED_VALUE_AT_ZERO): New macro.
4987
4988 2009-09-03  Martin Jambor  <mjambor@suse.cz>
4989
4990         * tree-sra.c (duplicate_expr_for_different_base): Removed.
4991         (create_artificial_child_access): Use build_ref_for_offset instead
4992         of duplicate_expr_for_different_base.
4993         (propagate_subacesses_accross_link): Likewise.
4994
4995 2009-09-03  Richard Sandiford  <rdsandiford@googlemail.com>
4996
4997         * config/mips/mips.c (USEFUL_INSN_P): Use NONDEBUG_INSN_P instead
4998         of INSN_P.
4999         (mips16e_collect_argument_saves): Skip debug instructions.
5000         (mips_74k_agen_init): Use CALL_P || JUMP_P instead of !NONJUMP_INSN_P.
5001         (mips16_lay_out_constants): Use USEFUL_INSN_P instead of INSN_P.
5002         (r10k_insert_cache_barriers): Likewise.
5003         (mips_reorg_process_insns): Likewise.
5004
5005 2009-09-03  Vladimir Makarov  <vmakarov@redhat.com>
5006
5007         PR bootstrap/41241
5008         * ira.c (update_equiv_reg): Remove check on class likely spill.
5009
5010 2009-09-03  Jakub Jelinek  <jakub@redhat.com>
5011
5012         PR debug/41236
5013         * dwarf2out.c (loc_descriptor): Don't use SUBREG_REG macro on
5014         SIGN_EXTEND or ZERO_EXTEND.  Don't assume there is a REG inside of
5015         it or SUBREG.
5016
5017         PR debug/41238
5018         * function.c (assign_parm_find_stack_rtl): Don't set mem attributes on
5019         the stack slot if it is passed by invisible reference.
5020         * var-tracking.c (vt_add_function_parameters): Handle arguments passed
5021         by invisible reference.
5022
5023 2009-09-03  Bernd Schmidt  <bernd.schmidt@analog.com>
5024
5025         * config/bfin/linux.h (TARGET_SUPPORTS_SYNC_CALLS): Define to 1.
5026         * config/bfin/uclinux.h (TARGET_SUPPORTS_SYNC_CALLS): Define to 1.
5027         * config/bfin/bfin.h (TARGET_SUPPORTS_SYNC_CALLS): Provide default of
5028         0.
5029         * config/bfin/sync.md: New file.
5030         * config/bfin/bfin.md: Include it.
5031         (UNSPEC_ATOMIC): New.
5032         (UNSPEC_ONES): Provide a unique number.
5033
5034         From Jie Zhang <jie.zhang@analog.com>:
5035         * config/bfin/bfin.c (ret_regs): New.
5036         (must_save_fp_p): Don't return true because of frame_pointer_needed.
5037         (must_save_rets_p): New.
5038         (n_regs_saved_by_prologue): Use must_save_rets_p instead of
5039         current_function_is_leaf.
5040         (do_link): Likewise.
5041         (do_unlink): Likewise.
5042         (expand_interrupt_handler_prologue): Use ret_regs array.
5043         (expand_interrupt_handler_epilogue): Use ret_regs array and
5044         pass return register to gen_return_internal.
5045         (bfin_expand_epilogue): Pass return register to
5046         gen_return_internal.
5047         (bfin_expand_call): Explicitly clobber RETS.
5048         * config/bfin/bfin.h (FUNCTION_RETURN_REGISTERS): Define.
5049         * config/bfin/bfin.md (call_symbol_fdpic, call_value_symbol_fdpic,
5050         call_insn_fdpic, call_value_insn_fdpic, call_symbol,
5051         call_value_symbol, call_insn, call_value_insn): Explicitly clobber
5052         RETS.
5053         (return_internal): Take a reg rtx rather than the register number.
5054
5055 2009-09-03  H.J. Lu  <hongjiu.lu@intel.com>
5056
5057         * tree-parloops.c (parallelize_loops): Cast to HOST_WIDE_INT
5058         when comparing against estimated_loop_iterations_int return.
5059
5060 2009-09-03  Richard Guenther  <rguenther@suse.de>
5061
5062         * dwarf2out.c (dwarf2out_do_cfi_asm): Remove check of
5063         eh_personality_libfunc.
5064
5065 2009-09-03  Razya Ladelsky  <razya@il.ibm.com>
5066
5067         * tree-parloops.c (separate_decls_in_region): Add space.
5068
5069 2009-09-03  Razya Ladelsky  <razya@il.ibm.com>
5070
5071         * tree-parloops.c (separate_decls_in_region): Change the condition
5072         checking if there are reductions in the loop.
5073
5074 2009-09-03  Razya Ladelsky  <razya@il.ibm.com>
5075
5076         PR tree-optimization/38275
5077         * tree-parloops.c (parallelize_loops): Replace profitability condition
5078         for expected number of iterations.
5079
5080 2009-09-03  Alexandre Oliva  <aoliva@redhat.com>
5081
5082         * doc/invoke.texi (BUILD_CONFIG): Document --with-build-config.
5083         (bootstrap-debug): Explain conditions in which it becomes default.
5084         (bootstrap-debug-big): Rather than duplicate bootstrap-debug,
5085         make it add to it.
5086
5087 2009-09-03  Namhyung Kim  <namhyung@gmail.com>
5088
5089         * doc/invoke.texi (Optimize Options): Move
5090         -finline-small-functions to the -O2 list.
5091
5092 2009-09-03  Alexandre Oliva  <aoliva@redhat.com>
5093
5094         * toplev.c (process_options): Enable var-tracking-assignments
5095         by default if var-tracking is enabled.
5096
5097 2009-09-02  David Daney  <ddaney@caviumnetworks.com>
5098
5099         * cfgbuild.c (find_bb_boundaries): Split blocks containing a
5100         barrier.
5101         * emit-rtl.c (prev_nonnote_insn_bb): New function.
5102         * rtl.h (prev_nonnote_insn_bb): Declare it.
5103
5104 2009-09-03  Diego Novillo  <dnovillo@google.com>
5105
5106         * cgraph.c (cgraph_node_for_decl): New.
5107         * cgraph.h (cgraph_node_for_decl): Declare.
5108         * tree.c (host_integerp): Return 0 if T is NULL.
5109
5110 2009-09-03  Diego Novillo  <dnovillo@google.com>
5111
5112         * tree.h (struct alias_pair): Move from varasm.c.
5113         (alias_pairs): Likewise.
5114         (TYPE_MAXVAL): Define.
5115         (TYPE_MINVAL): Define.
5116         (iterative_hash_host_wide_int): Declare.
5117         (remove_unreachable_alias_pairs): Declare.
5118         * tree-pass.h (pass_ipa_free_lang_data): Declare.
5119         * diagnostic.c (default_diagnostic_starter): Make extern.
5120         (default_diagnostic_finalizer): Make extern.
5121         * diagnostic.h (default_diagnostic_starter): Declare.
5122         (default_diagnostic_finalizer): Declare.
5123         (default_tree_printer): Declare.
5124         * toplev.c (default_tree_printer): Make extern.
5125
5126 2009-09-03  Richard Guenther  <rguenther@suse.de>
5127             Diego Novillo  <dnovillo@google.com>
5128
5129         * cgraph.c (cgraph_add_new_function): Remove gimplification.
5130         * cgraphunit.c (cgraph_expand_function): Do not emit
5131         associated thunks from here.
5132         (cgraph_emit_thunks): New.
5133         (cgraph_optimize): Call it.
5134         Return if any IPA pass finds an error.
5135         * varasm.c (finish_aliases_1): Ignore errorneous aliases used
5136         by thunks.
5137
5138 2009-09-03  Simon Baldwin  <simonb@google.com>
5139             Rafael Espindola  <espindola@google.com>
5140             Richard Guenther  <rguenther@suse.de>
5141             Doug Kwan  <dougkwan@google.com>
5142             Diego Novillo  <dnovillo@google.com>
5143
5144         * tree.c: Include tree-pass.h, langhooks-def.h,
5145         diagnostic.h, cgraph.h, timevar.h, except.h and debug.h.
5146         (free_lang_data_in_type): New.
5147         (need_assembler_name_p): New.
5148         (free_lang_data_in_block): New.
5149         (free_lang_data_in_decl): New.
5150         (struct free_lang_data_d): New.
5151         (add_tree_to_fld_list): New.
5152         (find_decls_types_r): New.
5153         (get_eh_types_for_runtime): New.
5154         (find_decls_types_in_eh_region): New.
5155         (find_decls_types_in_node): New.
5156         (find_decls_types_in_var): New.
5157         (free_lang_data_in_cgraph): New.
5158         (free_lang_data): New.
5159         (gate_free_lang_data): New.
5160         (pass_ipa_free_lang_data): New.
5161
5162 2009-09-03  Diego Novillo  <dnovillo@google.com>
5163
5164         * timevar.def (TV_IPA_FREE_LANG_DATA): Define.
5165         * langhooks.h (struct lang_hooks): Add field free_lang_data.
5166         (lang_hooks): Remove const qualifier.
5167         * ipa.c (cgraph_remove_unreachable_nodes): Call
5168         remove_unreachable_alias_pairs.
5169         * except.c (add_type_for_runtime): Check if TYPE has
5170         already been converted.
5171         (lookup_type_for_runtime): Likewise.
5172         (check_handled): Handle converted types.
5173         * varasm.c (remove_unreachable_alias_pairs): New.
5174         * gimple.c: Include demangle.h.
5175         (gimple_decl_printable_name): New.
5176         (gimple_fold_obj_type_ref): New.
5177         * gimple.h (gimple_decl_printable_name): Declare.
5178         (gimple_fold_obj_type_ref): Declare.
5179         * passes.c (init_optimization_passes): Add pass
5180         pass_ipa_free_lang_data.
5181         * langhooks-def.h (LANG_HOOKS_FREE_LANG_DATA): Define.
5182         (LANG_HOOKS_INITIALIZER): Add LANG_HOOKS_FREE_LANG_DATA.
5183
5184 2009-09-03  Diego Novillo  <dnovillo@google.com>
5185
5186         * c-lang.c (lang_hooks): Remove const qualifier.
5187
5188 2009-09-02  Loren James Rittle  <ljrittle@acm.org>
5189
5190         * doc/install.texi (*-*-freebsd*): Update target information.
5191
5192 2009-09-02  Anatoly Sokolov  <aesok@post.ru>
5193
5194         * hard-reg-set.h (call_fixed_regs): Remove.
5195         * reginfo.c (call_fixed_regs): Remove.
5196         (init_reg_sets_1): Remove initialization of call_fixed_regs.
5197         (globalize_reg): Don't use call_fixed_regs.
5198         * caller-save.c (init_caller_save): Use call_fixed_reg_set instead of
5199         call_fixed_regs.
5200
5201 2009-09-01  Michael Matz  <matz@suse.de>
5202
5203         * expr.h (emit_storent_insn, expand_expr_real_1,
5204         expand_expr_real_2): Declare.
5205         * expr.c (emit_storent_insn, expand_expr_real_1,
5206         expand_expr_real_2): Export.
5207         (store_expr): Setting and evaluating dont_return_target is useless.
5208         (expand_expr_real_1, <case GOTO_EXPR, RETURN_EXPR, SWITCH_EXPR,
5209         LABEL_EXPR and ASM_EXPR>): Move to gcc_unreachable.
5210         * except.c (expand_resx_expr): Rename to ...
5211         (expand_resx_stmt): ... this.  Rewrite to take gimple statement.
5212         * except.h (expand_resx_stmt): Declare.
5213         * stmt.c: Add include gimple.h
5214         (expand_asm_expr): Rename to ...
5215         (expand_asm_stmt): ... this. Rewrite to take gimple statement.
5216         (expand_case): Rewrite to take gimple statement.
5217         * tree.h (expand_asm_stmt): Declare.
5218         (expand_case): Change prototype.
5219         * Makefile.in (stmt.o): Depend on gimple.h.
5220         * builtins.c (expand_builtin_synchronize): Build gimple asm
5221         statement, not an ASM_EXPR.
5222         * cfgexpand.c (gimple_cond_pred_to_tree, set_expr_location_r,
5223         gimple_to_tree, release_stmt_tree): Remove.
5224         (expand_gimple_cond): Don't call gimple_cond_pred_to_tree or
5225         ggc_free, but hold comparison code and operands separately.
5226         Call jumpif_1 and jumpifnot_1 instead of jumpif and jumpifnot.
5227         (expand_call_stmt, expand_gimple_stmt_1,
5228         expand_gimple_stmt): New helpers.
5229         (expand_gimple_tailcall): Don't call gimple_to_tree, expand_expr_stmt,
5230         release_stmt_tree.  Call expand_gimple_stmt instead.
5231         (expand_gimple_basic_block): Ditto.
5232
5233         * calls.c (emit_call_1): Don't look at EH regions here, make
5234         fntree parameter useless.
5235         (expand_call): New local rettype for TREE_TYPE(exp), use it
5236         throughout.  Remove local p, use addr instead.
5237         Don't look at EH regions here.
5238
5239 2009-09-02  Vladimir Makarov  <vmakarov@redhat.com>
5240
5241         * doc/invoke.texi (-fsched-pressure): Document it.
5242         (-fsched-reg-pressure-heuristic): Remove it.
5243
5244         * reload.c (ira.h): Include.
5245         (find_reloads): Add choosing reload on number of small spilled
5246         classes.
5247
5248         * haifa-sched.c (ira.h): Include.
5249         (sched_pressure_p, sched_regno_cover_class, curr_reg_pressure,
5250         saved_reg_pressure, curr_reg_live, saved_reg_live,
5251         region_ref_regs): New variables.
5252         (sched_init_region_reg_pressure_info, mark_regno_birth_or_death,
5253         initiate_reg_pressure_info, setup_ref_regs,
5254         initiate_bb_reg_pressure_info, save_reg_pressure,
5255         restore_reg_pressure, dying_use_p, print_curr_reg_pressure): New
5256         functions.
5257         (setup_insn_reg_pressure_info): New function.
5258         (rank_for_schedule): Add pressure checking and insn issue time.
5259         Remove comparison of insn reg weights.
5260         (ready_sort): Set insn reg pressure info.
5261         (update_register_pressure, setup_insn_max_reg_pressure,
5262         update_reg_and_insn_max_reg_pressure,
5263         sched_setup_bb_reg_pressure_info): New functions.
5264         (schedule_insn): Add code for printing and updating reg pressure info.
5265         (find_set_reg_weight, find_insn_reg_weight): Remove.
5266         (ok_for_early_queue_removal): Do nothing if pressure_only_p.
5267         (debug_ready_list): Print reg pressure info.
5268         (schedule_block): Ditto.  Check insn issue time.
5269         (sched_init): Set up sched_pressure_p.  Allocate and set up some
5270         reg pressure related info.
5271         (sched_finish): Free some reg pressure related info.
5272         (fix_tick_ready): Make insn always ready if pressure_p.
5273         (init_h_i_d): Don't call find_insn_reg_weight.
5274         (haifa_finish_h_i_d): Free insn reg pressure info.
5275
5276         * ira-int.h (ira_hard_regno_cover_class, ira_reg_class_nregs,
5277         ira_memory_move_cost, ira_class_hard_regs,
5278         ira_class_hard_regs_num, ira_no_alloc_regs,
5279         ira_available_class_regs, ira_reg_class_cover_size,
5280         ira_reg_class_cover, ira_class_translate): Move to ira.h.
5281
5282         * ira-lives.c (single_reg_class): Check mode to find how many
5283         registers are necessary for operand.
5284         (ira_implicitly_set_insn_hard_regs): New.
5285
5286         * common.opt (fsched-pressure): New options.
5287         (fsched-reg-pressure-heuristic): Remove.
5288
5289         * ira.c (setup_eliminable_regset): Rename to
5290         ira_setup_eliminable_regset.  Make it external.
5291         (expand_reg_info): Pass cover class to setup_reg_classes.
5292         (ira): Call resize_reg_info instead of allocate_reg_info.
5293
5294         * sched-deps.c: Include ira.h.
5295         (implicit_reg_pending_clobbers, implicit_reg_pending_uses): New.
5296         (create_insn_reg_use, create_insn_reg_set, setup_insn_reg_uses,
5297         reg_pressure_info, insn_use_p, mark_insn_pseudo_birth,
5298         mark_insn_hard_regno_birth, mark_insn_reg_birth,
5299         mark_pseudo_death, mark_hard_regno_death, mark_reg_death,
5300         mark_insn_reg_store, mark_insn_reg_clobber,
5301         setup_insn_reg_pressure_info): New.
5302         (sched_analyze_1): Update implicit_reg_pending_uses.
5303         (sched_analyze_insn): Find implicit sets, uses, clobbers of regs.
5304         Use them to create dependencies.  Set insn reg uses and pressure
5305         info.  Process reg_pending_uses in one place.
5306         (free_deps): Free implicit sets.
5307         (remove_from_deps): Remove implicit sets if necessary.  Check
5308         implicit sets when clearing reg_last_in_use.
5309         (init_deps_global): Clear implicit_reg_pending_clobbers and
5310         implicit_reg_pending_uses.
5311
5312         * ira.h (ira_hard_regno_cover_class, ira_reg_class_nregs,
5313         ira_memory_move_cost, ira_class_hard_regs,
5314         ira_class_hard_regs_num, ira_no_alloc_regs,
5315         ira_available_class_regs, ira_reg_class_cover_size,
5316         ira_reg_class_cover, ira_class_translate): Move from ira-int.h.
5317         (ira_setup_eliminable_regset, ira_set_pseudo_classes,
5318         ira_implicitly_set_insn_hard_regs): New prototypes.
5319
5320         * ira-costs.c (pseudo_classes_defined_p, allocno_p,
5321         cost_elements_num): New variables.
5322         (allocno_costs, total_costs): Rename to costs and
5323         total_allocno_costs.
5324         (COSTS_OF_ALLOCNO): Rename to COSTS.
5325         (allocno_pref): Rename to pref.
5326         (allocno_pref_buffer): Rename to pref_buffer.
5327         (common_classes): Rename to regno_cover_class.
5328         (COST_INDEX): New.
5329         (record_reg_classes): Set allocno attributes only if allocno_p.
5330         (record_address_regs): Ditto.  Use COST_INDEX instead of ALLOCNO_NUM.
5331         (scan_one_insn): Use COST_INDEX and COSTS instead of ALLOCNO_NUM
5332         and COSTS_OF_ALLOCNO.
5333         (print_costs): Rename to print_allocno_costs.
5334         (print_pseudo_costs): New.
5335         (process_bb_node_for_costs): Split into 2 functions with new
5336         function process_bb_for_costs.  Pass BB to process_bb_for_costs.
5337         (find_allocno_class_costs): Rename to find_costs_and_classes.  Add
5338         new parameter dump_file.  Use cost_elements_num instead of
5339         ira_allocnos_num.  Make one iteration if preferred classes were
5340         already calculated for scheduler.  Make 2 versions of code
5341         depending on allocno_p.
5342         (setup_allocno_cover_class_and_costs): Check allocno_p.  Use
5343         regno_cover_class and COSTS instead of common_classes and
5344         COSTS_OF_ALLOCNO.
5345         (init_costs, finish_costs): New.
5346         (ira_costs): Set up allocno_p and cost_elements_num.  Call
5347         init_costs and finish_costs.
5348         (ira_set_pseudo_classes): New.
5349
5350         * rtl.h (allocate_reg_info): Remove.
5351         (resize_reg_info): Change return type.
5352         (reg_cover_class): New.
5353         (setup_reg_classes): Add new parameter.
5354
5355         * sched-int.h (struct deps_reg): New member implicit_sets.
5356         (sched_pressure_p, sched_regno_cover_class): New external definitions.
5357         (INCREASE_BITS): New macro.
5358         (struct reg_pressure_data, struct reg_use_data): New.
5359         (struct _haifa_insn_data): Remove reg_weight.  Add members
5360         reg_pressure, reg_use_list, reg_set_list, and
5361         reg_pressure_excess_cost_change.
5362         (struct deps): New member implicit_sets.
5363         (pressure_p): New variable.
5364         (COVER_CLASS_BITS, INCREASE_BITS): New macros.
5365         (struct reg_pressure_data, struct reg_use_data): New.
5366         (INSN_REG_WEIGHT): Remove.
5367         (INSN_REG_PRESSURE, INSN_MAX_REG_PRESSURE, INSN_REG_USE_LIST,
5368         INSN_REG_SET_LIST, INSN_REG_PRESSURE_EXCESS_COST_CHANGE): New macros.
5369         (sched_init_region_reg_pressure_info,
5370         sched_setup_bb_reg_pressure_info): New prototypes.
5371
5372         * reginfo.c (struct reg_pref): New member coverclass.
5373         (reg_cover_class): New function.
5374         (reginfo_init, pass_reginfo_init): Move after free_reg_info.
5375         (reg_info_size): New variable.
5376         (allocate_reg_info): Make static.  Setup reg_info_size.
5377         (resize_reg_info): Use reg_info_size.  Return flag of resizing.
5378         (setup_reg_classes): Add a new parameter.  Setup cover class too.
5379
5380         * Makefile.in (reload.o, haifa-sched.o, sched-deps.o): Add ira.h to
5381         the dependencies.
5382
5383         * sched-rgn.c (deps_join): Set up implicit_sets.
5384         (schedule_region): Set up region and basic blocks pressure
5385         relative info.
5386
5387         * passes.c (init_optimization_passes): Move
5388         pass_subregs_of_mode_init before pass_sched.
5389
5390 2009-09-02  Martin Jambor  <mjambor@suse.cz>
5391
5392         * tree-sra.c (struct access): New field grp_hint.
5393         (dump_access): Dump grp_hint.
5394         (sort_and_splice_var_accesses): Set grp_hint if a group is read
5395         multiple times.
5396         (analyze_access_subtree): Only scalarize accesses with grp_hint set or
5397         those which have been specifically read and somehow written to.
5398         (propagate_subacesses_accross_link): Set grp_hint of right child and
5399         also possibly of the left child.
5400
5401 2009-09-02  Jakub Jelinek  <jakub@redhat.com>
5402
5403         * tree-object-size.c (addr_object_size): Always use object_size_type
5404         0 or 2 when determining the pointer pointed object size.
5405
5406 2009-09-02  Richard Guenther  <rguenther@suse.de>
5407
5408         Revert
5409         2009-08-31  Richard Guenther  <rguenther@suse.de>
5410
5411         * builtins.c (fold_builtin_memory_op): Use the alias oracle
5412         to query if the memory regions for memmove overlap.
5413         * tree-ssa-alias.c (ptr_deref_may_alias_decl_p): Relax the
5414         asserts on pointers, instead deal with odd trees.
5415         (ptr_derefs_may_alias_p): Likewise.
5416         (refs_may_alias_p_1): Constructor bases also never alias.
5417
5418 2009-08-01  Christian Bruel  <christian.bruel@st.com>
5419
5420         Revert:
5421         2009-07-31  Christian Bruel  <christian.bruel@st.com>
5422         * gcc/config.gcc (sh*-*-elf): test with_libgloss.
5423
5424 2009-09-01  Alexandre Oliva  <aoliva@redhat.com>
5425
5426         * doc/invoke.texi (-fvar-tracking-assignments): New.
5427         (-fvar-tracking-assignments-toggle): New.
5428         (-fdump-final-insns=file): Mark filename as optional.
5429         (--param min-nondebug-insn-uid): New.
5430         (-gdwarf-@{version}): Mention version 4.
5431         * opts.c (common_handle_option): Accept it.
5432         * tree-vrp.c (find_assert_locations_1): Skip debug stmts.
5433         * regrename.c (regrename_optimize): Drop last.  Don't count debug
5434         insns as uses.  Don't reject change because of debug insn.
5435         (do_replace): Reject DEBUG_INSN as chain starter.  Take base_regno
5436         from the chain starter, and check for inexact matches in DEBUG_INSNS.
5437         (scan_rtx_reg): Accept inexact matches in DEBUG_INSNs.
5438         (build_def_use): Simplify and fix the marking of DEBUG_INSNs.
5439         * sched-ebb.c (schedule_ebbs): Skip boundary debug insns.
5440         * fwprop.c (forward_propagate_and_simplify): ...into debug insns.
5441         * doc/gimple.texi (is_gimple_debug): New.
5442         (gimple_debug_bind_p): New.
5443         (is_gimple_call, gimple_assign_cast_p): End sentence with period.
5444         * doc/install.texi (bootstrap-debug): More details.
5445         (bootstrap-debug-big, bootstrap-debug-lean): Document.
5446         (bootstrap-debug-lib): More details.
5447         (bootstrap-debug-ckovw): Update.
5448         (bootstrap-time): New.
5449         * tree-into-ssa.c (mark_def_sites): Skip debug stmts.
5450         (insert_phi_nodes_for): Insert debug stmts.
5451         (rewrite_stmt): Take iterator.  Insert debug stmts.
5452         (rewrite_enter_block): Adjust.
5453         (maybe_replace_use_in_debug_stmt): New.
5454         (rewrite_update_stmt): Use it.
5455         (mark_use_interesting): Return early for debug stmts.
5456         * tree-ssa-loop-im.c (rewrite_bittest): Propagate DEFs into debug
5457         stmts before replacing stmt.
5458         (move_computations_stmt): Likewise.
5459         * ira-conflicts.c (add_copies): Skip debug insns.
5460         * regstat.c (regstat_init_n_sets_and_refs): Discount debug insns.
5461         (regstat_bb_compute_ri): Skip debug insns.
5462         * tree-ssa-threadupdate.c (redirection_block_p): Skip debug stmts.
5463         * tree-ssa-loop-manip.c (find_uses_to_rename_stmt,
5464         check_loop_closed_ssa_stmt): Skip debug stmts.
5465         * tree-tailcall.c (find_tail_calls): Likewise.
5466         * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): Likewise.
5467         * tree.h (MAY_HAVE_DEBUG_STMTS): New.
5468         (build_var_debug_value_stat): Declare.
5469         (build_var_debug_value): Define.
5470         (target_for_debug_bind): Declare.
5471         * reload.c (find_equiv_reg): Skip debug insns.
5472         * rtlanal.c (reg_used_between_p): Skip debug insns.
5473         (side_effects_p): Likewise.
5474         (canonicalize_condition): Likewise.
5475         * ddg.c (create_ddg_dep_from_intra_loop_link): Check that non-debug
5476         insns never depend on debug insns.
5477         (create_ddg_dep_no_link): Likewise.
5478         (add_cross_iteration_register_deps): Use ANTI_DEP for debug insns.
5479         Don't add inter-loop dependencies for debug insns.
5480         (build_intra_loop_deps): Likewise.
5481         (create_ddg): Count debug insns.
5482         * ddg.h (struct ddg::num_debug): New.
5483         (num_backargs): Pair up with previous int field.
5484         * diagnostic.c (diagnostic_report_diagnostic): Skip notes on
5485         -fcompare-debug-second.
5486         * final.c (get_attr_length_1): Skip debug insns.
5487         (rest_of_clean-state): Don't dump CFA_RESTORE_STATE.
5488         * gcc.c (invoke_as): Call compare-debug-dump-opt.
5489         (driver_self_specs): Map -fdump-final-insns to
5490         -fdump-final-insns=..
5491         (get_local_tick): New.
5492         (compare_debug_dump_opt_spec_function): Test for . argument and
5493         compute output name.  Compute temp output spec without flag name.
5494         Compute -frandom-seed.
5495         (OPT): Undef after use.
5496         * cfgloopanal.c (num_loop_insns): Skip debug insns.
5497         (average_num_loop_insns): Likewise.
5498         * params.h (MIN_NONDEBUG_INSN_UID): New.
5499         * gimple.def (GIMPLE_DEBUG): New.
5500         * ipa-reference.c (scan_stmt_for_static_refs): Skip debug stmts.
5501         * auto-inc-dec.c (merge_in_block): Skip debug insns.
5502         (merge_in_block): Fix whitespace.
5503         * toplev.c (flag_var_tracking): Update comment.
5504         (flag_var_tracking_assignments): New.
5505         (flag_var_tracking_assignments_toggle): New.
5506         (process_options): Don't open final insns dump file if we're not
5507         going to write to it.  Compute defaults for var_tracking.
5508         * df-scan.c (df_insn_rescan_debug_internal): New.
5509         (df_uses_record): Handle debug insns.
5510         * haifa-sched.c (ready): Initialize n_debug.
5511         (contributes_to_priority): Skip debug insns.
5512         (dep_list_size): New.
5513         (priority): Use it.
5514         (rank_for_schedule): Likewise.  Schedule debug insns as soon as
5515         they're ready.  Disregard previous debug insns to make decisions.
5516         (queue_insn): Never queue debug insns.
5517         (ready_add, ready_remove_first, ready_remove): Count debug insns.
5518         (schedule_insn): Don't reject debug insns because of issue rate.
5519         (get_ebb_head_tail, no_real_insns_p): Skip boundary debug insns.
5520         (queue_to_ready): Skip and discount debug insns.
5521         (choose_ready): Let debug insns through.
5522         (schedule_block): Check boundary debug insns.  Discount debug
5523         insns, schedule them early.  Adjust whitespace.
5524         (set_priorities): Check for boundary debug insns.
5525         (add_jump_dependencies): Use dep_list_size.
5526         (prev_non_location_insn): New.
5527         (check_cfg): Use it.
5528         * tree-ssa-loop-ivopts.c (find-interesting_users): Skip debug
5529         stmts.
5530         (remove_unused_ivs): Reset debug stmts.
5531         * modulo-sched.c (const_iteration_count): Skip debug insns.
5532         (res_MII): Discount debug insns.
5533         (loop_single_full_bb_p): Skip debug insns.
5534         (sms_schedule): Likewise.
5535         (sms_schedule_by_order): Likewise.
5536         (ps_has_conflicts): Likewise.
5537         * caller-save.c (refmarker_fn): New.
5538         (save_call_clobbered_regs): Replace regs with saved mem in
5539         debug insns.
5540         (mark_referenced_regs): Take pointer, mark and arg.  Adjust.
5541         Call refmarker_fn mark for hardregnos.
5542         (mark_reg_as_referenced): New.
5543         (replace_reg_with_saved_mem): New.
5544         * ipa-pure-const.c (check_stmt): Skip debug stmts.
5545         * cse.c (cse_insn): Canonicalize debug insns.  Skip them when
5546         searching back.
5547         (cse_extended_basic_block): Skip debug insns.
5548         (count_reg_usage): Likewise.
5549         (is_dead_reg): New, split out of...
5550         (set_live_p): ... here.
5551         (insn_live_p): Use it for debug insns.
5552         * tree-stdarg.c (check_all_va_list_escapes): Skip debug stmts.
5553         (execute_optimize_stdarg): Likewise.
5554         * tree-ssa-dom.c (propagate_rhs_into_lhs): Likewise.
5555         * tree-ssa-propagate.c (substitute_and_fold): Don't regard
5556         changes in debug stmts as changes.
5557         * sel-sched.c (moving_insn_creates_bookkeeping_block_p): New.
5558         (moveup_expr): Don't move across debug insns.  Don't move
5559         debug insn if it would create a bookkeeping block.
5560         (moveup_expr_cached): Don't use cache for debug insns that
5561         are heads of blocks.
5562         (compute_av_set_inside_bb): Skip debug insns.
5563         (sel_rank_for_schedule): Schedule debug insns first.  Remove
5564         dead code.
5565         (block_valid_for_bookkeeping_p); Support lax searches.
5566         (create_block_for_bookkeeping): Adjust block numbers when
5567         encountering debug-only blocks.
5568         (find_place_for_bookkeeping): Deal with debug-only blocks.
5569         (generate_bookkeeping_insn): Accept no place to insert.
5570         (remove_temp_moveop_nops): New argument full_tidying.
5571         (prepare_place_to_insert): Deal with debug insns.
5572         (advance_state_on_fence): Debug insns don't start cycles.
5573         (update_boundaries): Take fence as argument.  Deal with
5574         debug insns.
5575         (schedule_expr_on_boundary): No full_tidying on debug insns.
5576         (fill_insns): Deal with debug insns.
5577         (track_scheduled_insns_and_blocks): Don't count debug insns.
5578         (need_nop_to_preserve_insn_bb): New, split out of...
5579         (remove_insn_from_stream): ... this.
5580         (fur_orig_expr_not_found): Skip debug insns.
5581         * rtl.def (VALUE): Move up.
5582         (DEBUG_INSN): New.
5583         * tree-ssa-sink.c (all_immediate_uses_same_place): Skip debug stmts.
5584         (nearest_common_dominator_of_uses): Take debug_stmts argument.
5585         Set it if debug stmts are found.
5586         (statement_sink_location): Skip debug stmts.  Propagate
5587         moving defs into debug stmts.
5588         * ifcvt.c (first_active_insn): Skip debug insns.
5589         (last_active_insns): Likewise.
5590         (cond_exec_process_insns): Likewise.
5591         (noce_process_if_block): Likewise.
5592         (check_cond_move_block): Likewise.
5593         (cond_move_convert_if_block): Likewise.
5594         (block_jumps_and_fallthru_p): Likewise.
5595         (dead_or_predicable): Likewise.
5596         * dwarf2out.c (debug_str_hash_forced): New.
5597         (find_AT_string): Add comment.
5598         (gen_label_for_indirect_string): New.
5599         (get_debug_string_label): New.
5600         (AT_string_form): Use it.
5601         (mem_loc_descriptor): Handle non-TLS symbols.  Handle MINUS , DIV,
5602         MOD, AND, IOR, XOR, NOT, ABS, NEG, and CONST_STRING.  Accept but
5603         discard COMPARE, IF_THEN_ELSE, ROTATE, ROTATERT, TRUNCATE and
5604         several operations that cannot be represented with DWARF opcodes.
5605         (loc_descriptor): Ignore SIGN_EXTEND and ZERO_EXTEND.  Require
5606         dwarf_version 4 for DW_OP_implicit_value and DW_OP_stack_value.
5607         (dwarf2out_var_location): Take during-call mark into account.
5608         (output_indirect_string): Update comment.  Output if there are
5609         label and references.
5610         (prune_indirect_string): New.
5611         (prune_unused_types): Call it if debug_str_hash_forced.
5612         More in dwarf2out.c, from Jakub Jelinek <jakub@redhat.com>:
5613         (dw_long_long_const): Remove.
5614         (struct dw_val_struct): Change val_long_long type to rtx.
5615         (print_die, attr_checksum, same_dw_val_p, loc_descriptor): Adjust for
5616         val_long_long change to CONST_DOUBLE rtx from a long hi/lo pair.
5617         (output_die): Likewise.  Use HOST_BITS_PER_WIDE_INT size of each
5618         component instead of HOST_BITS_PER_LONG.
5619         (output_loc_operands): Likewise.  For const8* assert
5620         HOST_BITS_PER_WIDE_INT rather than HOST_BITS_PER_LONG is >= 64.
5621         (output_loc_operands_raw): For const8* assert HOST_BITS_PER_WIDE_INT
5622         rather than HOST_BITS_PER_LONG is >= 64.
5623         (add_AT_long_long): Remove val_hi and val_lo arguments, add
5624         val_const_double.
5625         (size_of_die): Use HOST_BITS_PER_WIDE_INT size multiplier instead of
5626         HOST_BITS_PER_LONG for dw_val_class_long_long.
5627         (add_const_value_attribute): Adjust add_AT_long_long caller.  Don't
5628         handle TLS SYMBOL_REFs.  If CONST wraps a constant, tail recurse.
5629         (dwarf_stack_op_name): Handle DW_OP_implicit_value and
5630         DW_OP_stack_value.
5631         (size_of_loc_descr, output_loc_operands, output_loc_operands_raw):
5632         Handle DW_OP_implicit_value.
5633         (extract_int): Move prototype earlier.
5634         (mem_loc_descriptor): For SUBREG punt if inner
5635         mode size is wider than DWARF2_ADDR_SIZE.  Handle SIGN_EXTEND
5636         and ZERO_EXTEND by DW_OP_shl and DW_OP_shr{a,}.  Handle
5637         EQ, NE, GT, GE, LT, LE, GTU, GEU, LTU, LEU, SMIN, SMAX, UMIN,
5638         UMAX, SIGN_EXTRACT, ZERO_EXTRACT.
5639         (loc_descriptor): Compare mode size with DWARF2_ADDR_SIZE
5640         instead of Pmode size.
5641         (loc_descriptor): Add MODE argument.  Handle CONST_INT, CONST_DOUBLE,
5642         CONST_VECTOR, CONST, LABEL_REF and SYMBOL_REF if mode != VOIDmode,
5643         attempt to handle other expressions.  Don't handle TLS SYMBOL_REFs.
5644         (concat_loc_descriptor, concatn_loc_descriptor,
5645         loc_descriptor_from_tree_1): Adjust loc_descriptor callers.
5646         (add_location_or_const_value_attribute): Likewise.  For single
5647         location loc_lists attempt to use add_const_value_attribute
5648         for constant decls.  Add DW_AT_const_value even if
5649         NOTE_VAR_LOCATION is VAR_LOCATION with CONSTANT_P or CONST_STRING
5650         in its expression.
5651         * cfgbuild.c (inside_basic_block_p): Handle debug insns.
5652         (control_flow_insn_p): Likewise.
5653         * tree-parloops.c (eliminate_local_variables_stmt): Handle debug stmt.
5654         (separate_decls_in_region_debug_bind): New.
5655         (separate_decls_in_region): Process debug bind stmts afterwards.
5656         * recog.c (verify_changes): Handle debug insns.
5657         (extract_insn): Likewise.
5658         (peephole2_optimize): Skip debug insns.
5659         * dse.c (scan_insn): Skip debug insns.
5660         * sel-sched-ir.c (return_nop_to_pool): Take full_tidying argument.
5661         Pass it on.
5662         (setup_id_for_insn): Handle debug insns.
5663         (maybe_tidy_empty_bb): Adjust whitespace.
5664         (tidy_control_flow): Skip debug insns.
5665         (sel_remove_insn): Adjust for debug insns.
5666         (sel_estimate_number_of_insns): Skip debug insns.
5667         (create_insn_rtx_from_pattern): Handle debug insns.
5668         (create_copy_of_insn_rtx): Likewise.
5669         * sel-sched-.h (sel_bb_end): Declare.
5670         (sel_bb_empty_or_nop_p): New.
5671         (get_all_loop_exits): Use it.
5672         (_eligible_successor_edge_p): Likewise.
5673         (return_nop_to_pool): Adjust.
5674         * tree-eh.c (tre_empty_eh_handler_p): Skip debug stmts.
5675         * ira-lives.c (process_bb_node_lives): Skip debug insns.
5676         * gimple-pretty-print.c (dump_gimple_debug): New.
5677         (dump_gimple_stmt): Use it.
5678         (dump_bb_header): Skip gimple debug stmts.
5679         * regmove.c (optimize_reg_copy_1): Discount debug insns.
5680         (fixup_match_2): Likewise.
5681         (regmove_backward_pass): Likewise.  Simplify combined
5682         replacement.  Handle debug insns.
5683         * function.c (instantiate_virtual_regs): Handle debug insns.
5684         * function.h (struct emit_status): Add x_cur_debug_insn_uid.
5685         * print-rtl.h: Include cselib.h.
5686         (print_rtx): Print VALUEs.  Split out and recurse for VAR_LOCATIONs.
5687         * df.h (df_inns_rescan_debug_internal): Declare.
5688         * gcse.c (alloc_hash_table): Estimate n_insns.
5689         (cprop_insn): Don't regard debug insns as changes.
5690         (bypass_conditional_jumps): Skip debug insns.
5691         (one_pre_gcse_pass): Adjust.
5692         (one_code_hoisting_pass): Likewise.
5693         (compute_ld_motion_mems): Skip debug insns.
5694         (one_cprop_pass): Adjust.
5695         * tree-if-conv.c (tree_if_convert_stmt): Reset debug stmts.
5696         (if_convertible_stmt_p): Handle debug stmts.
5697         * init-regs.c (initialize_uninitialized_regs): Skip debug insns.
5698         * tree-vect-loop.c (vect_is_simple_reduction): Skip debug stmts.
5699         * ira-build.c (create_bb_allocnos): Skip debug insns.
5700         * tree-flow-inline.h (has_zero_uses): Discount debug stmts.
5701         (has_single_use): Likewise.
5702         (single_imm_use): Likewise.
5703         (num_imm_uses): Likewise.
5704         * tree-ssa-phiopt.c (empty_block_p): Skip debug stmts.
5705         * tree-ssa-coalesce.c (build_ssa_conflict_graph): Skip debug stmts.
5706         (create_outofssa_var_map): Likewise.
5707         * lower-subreg.c (adjust_decomposed_uses): New.
5708         (resolve_debug): New.
5709         (decompose_multiword_subregs): Use it.
5710         * tree-dfa.c (find_referenced_vars): Skip debug stmts.
5711         * emit-rtl.c: Include params.h.
5712         (cur_debug_insn_uid): Define.
5713         (set_new_first_and_last_insn): Set cur_debug_insn_uid too.
5714         (copy_rtx_if_shared_1): Handle debug insns.
5715         (reset_used_flags): Likewise.
5716         (set_used_flags): LIkewise.
5717         (get_max_insn_count): New.
5718         (next_nondebug_insn): New.
5719         (prev_nondebug_insn): New.
5720         (make_debug_insn_raw): New.
5721         (emit_insn_before_noloc): Handle debug insns.
5722         (emit_jump_insn_before_noloc): Likewise.
5723         (emit_call_insn_before_noloc): Likewise.
5724         (emit_debug_insn_before_noloc): New.
5725         (emit_insn_after_noloc): Handle debug insns.
5726         (emit_jump_insn_after_noloc): Likewise.
5727         (emit_call_insn_after_noloc): Likewise.
5728         (emit_debug_insn_after_noloc): Likewise.
5729         (emit_insn_after): Take loc from earlier non-debug insn.
5730         (emit_jump_insn_after): Likewise.
5731         (emit_call_insn_after): Likewise.
5732         (emit_debug_insn_after_setloc): New.
5733         (emit_debug_insn_after): New.
5734         (emit_insn_before): Take loc from later non-debug insn.
5735         (emit_jump_insn_before): Likewise.
5736         (emit_call_insn_before): Likewise.
5737         (emit_debug_insn_before_setloc): New.
5738         (emit_debug_insn_before): New.
5739         (emit_insn): Handle debug insns.
5740         (emit_debug_insn): New.
5741         (emit_jump_insn): Handle debug insns.
5742         (emit_call_insn): Likewise.
5743         (emit): Likewise.
5744         (init_emit): Take min-nondebug-insn-uid into account.
5745         Initialize cur_debug_insn_uid.
5746         (emit_copy_of_insn_after): Handle debug insns.
5747         * cfgexpand.c (gimple_assign_rhs_to_tree): Do not overwrite
5748         location of single rhs in place.
5749         (maybe_dump_rtl_for_gimple_stmt): Dump lineno.
5750         (floor_sdiv_adjust): New.
5751         (cell_sdiv_adjust): New.
5752         (cell_udiv_adjust): New.
5753         (round_sdiv_adjust): New.
5754         (round_udiv_adjust): New.
5755         (wrap_constant): Moved from cselib.
5756         (unwrap_constant): New.
5757         (expand_debug_expr): New.
5758         (expand_debug_locations): New.
5759         (expand_gimple_basic_block): Drop hiding redeclaration.  Expand
5760         debug bind stmts.
5761         (gimple_expand_cfg): Expand debug locations.
5762         * cselib.c: Include tree-pass.h.
5763         (struct expand_value_data): New.
5764         (cselib_record_sets_hook): New.
5765         (PRESERVED_VALUE_P, LONG_TERM_PRESERVED_VALUE_P): New.
5766         (cselib_clear_table): Move, and implemnet in terms of...
5767         (cselib_reset_table_with_next_value): ... this.
5768         (cselib_get_next_unknown_value): New.
5769         (discard_useless_locs): Don't discard preserved values.
5770         (cselib_preserve_value): New.
5771         (cselib_preserved_value_p): New.
5772         (cselib_preserve_definitely): New.
5773         (cselib_clear_preserve): New.
5774         (cselib_preserve_only_values): New.
5775         (new_cselib_val): Take rtx argument.  Dump it in details.
5776         (cselib_lookup_mem): Adjust.
5777         (expand_loc): Take regs_active in struct.  Adjust.  Silence
5778         dumps unless details are requested.
5779         (cselib_expand_value_rtx_cb): New.
5780         (cselib_expand_value_rtx): Rename and reimplment in terms of...
5781         (cselib_expand_value_rtx_1): ... this.  Adjust.  Silence dumps
5782         without details.  Copy more subregs.  Try to resolve values
5783         using a callback.  Wrap constants.
5784         (cselib_subst_to_values): Adjust.
5785         (cselib_log_lookup): New.
5786         (cselib_lookup): Call it.
5787         (cselib_invalidate_regno): Don't count preserved values as useless.
5788         (cselib_invalidate_mem): Likewise.
5789         (cselib_record_set): Likewise.
5790         (struct set): Renamed to cselib_set, moved to cselib.h.
5791         (cselib_record_sets): Adjust.  Call hook.
5792         (cselib_process_insn): Reset table when it would be cleared.
5793         (dump_cselib_val): New.
5794         (dump_cselib_table): New.
5795         * tree-cfgcleanup.c (tree_forwarded_block_p): Skip debug stmts.
5796         (remove_forwarder_block): Support moving debug stmts.
5797         * cselib.h (cselib_record_sets_hook): Declare.
5798         (cselib_expand_callback): New type.
5799         (cselib_expand_value_rtx_cb): Declare.
5800         (cselib_reset_table_with_next_value): Declare.
5801         (cselib_get_next_unknown_value): Declare.
5802         (cselib_preserve_value): Declare.
5803         (cselib_preserved_value_p): Declare.
5804         (cselib_preserve_only_values): Declare.
5805         (dump_cselib_table): Declare.
5806         * cfgcleanup.c (flow_find_cross_jump): Skip debug insns.
5807         (try_crossjump_to_edge): Likewise.
5808         (delete_unreachable_blocks): Remove dominant GIMPLE blocks after
5809         dominated blocks when debug stmts are present.
5810         * simplify-rtx.c (delegitimize_mem_from_attrs): New.
5811         * tree-ssa-live.c (remove_unused_locals): Skip debug stmts.
5812         (set_var_live_on_entry): Likewise.
5813         * loop-invariant.c (find_invariants_bb): Skip debug insns.
5814         * cfglayout.c (curr_location, last_location): Make static.
5815         (set_curr_insn_source_location): Don't avoid bouncing.
5816         (get_curr_insn_source_location): New.
5817         (get_curr_insn_block): New.
5818         (duplicate_insn_chain): Handle debug insns.
5819         * tree-ssa-forwprop.c (forward_propagate_addr_expr): Propagate
5820         into debug stmts.
5821         * common.opt (fcompare-debug): Move to sort order.
5822         (fdump-unnumbered-links): Likewise.
5823         (fvar-tracking-assignments): New.
5824         (fvar-tracking-assignments-toggle): New.
5825         * tree-ssa-dce.c (mark_stmt_necessary): Don't mark blocks
5826         because of debug stmts.
5827         (mark_stmt_if_obviously_necessary): Mark debug stmts.
5828         (eliminate_unnecessary_stmts): Walk dominated blocks before
5829         dominators.
5830         * tree-ssa-ter.c (find_replaceable_in_bb): Skip debug stmts.
5831         * ira.c (memref_used_between_p): Skip debug insns.
5832         (update_equiv_regs): Likewise.
5833         * sched-deps.c (sd_lists_size): Accept empty list.
5834         (sd_init_insn): Mark debug insns.
5835         (sd_finish_insn): Unmark them.
5836         (sd_add_dep): Reject non-debug deps on debug insns.
5837         (fixup_sched_groups): Give debug insns group treatment.
5838         Skip debug insns.
5839         (sched_analyze_reg): Don't mark debug insns for sched before call.
5840         (sched_analyze_2): Handle debug insns.
5841         (sched_analyze_insn): Compute next non-debug insn.  Handle debug
5842         insns.
5843         (deps_analyze_insn): Handle debug insns.
5844         (deps_start_bb): Skip debug insns.
5845         (init_deps): Initialize last_debug_insn.
5846         * tree-ssa.c (target_for_debug_bind): New.
5847         (find_released_ssa_name): New.
5848         (propagate_var_def_into_debug_stmts): New.
5849         (propagate_defs_into_debug_stmts): New.
5850         (verify_ssa): Skip debug bind stmts without values.
5851         (warn_uninialized_vars): Skip debug stmts.
5852         * target-def.h (TARGET_DELEGITIMIZE_ADDRESS): Set default.
5853         * rtl.c (rtx_equal_p_cb): Handle VALUEs.
5854         (rtx_equal_p): Likewise.
5855         * ira-costs.c (scan_one_insn): Skip debug insns.
5856         (process_bb_node_for_hard_reg_moves): Likewise.
5857         * rtl.h (DEBUG_INSN_P): New.
5858         (NONDEBUG_INSN_P): New.
5859         (MAY_HAVE_DEBUG_INSNS): New.
5860         (INSN_P): Accept debug insns.
5861         (RTX_FRAME_RELATED_P): Likewise.
5862         (INSN_DELETED_P): Likewise
5863         (PAT_VAR_LOCATION_DECL): New.
5864         (PAT_VAR_LOCATION_LOC): New.
5865         (PAT_VAR_OCATION_STATUS): New.
5866         (NOTE_VAR_LOCATION_DECL): Reimplement.
5867         (NOTE_VAR_LOCATION_LOC): Likewise.
5868         (NOTE_VAR_LOCATION_STATUS): Likewise.
5869         (INSN_VAR_LOCATION): New.
5870         (INSN_VAR_LOCATION_DECL): New.
5871         (INSN_VAR_LOCATION_LOC): New.
5872         (INSN_VAR_LOCATION_STATUS): New.
5873         (gen_rtx_UNKNOWN_VAR_LOC): New.
5874         (VAR_LOC_UNKNOWN_P): New.
5875         (NOTE_DURING_CALL_P): New.
5876         (SCHED_GROUP_P): Accept debug insns.
5877         (emit_debug_insn_before): Declare.
5878         (emit_debug_insn_before_noloc): Declare.
5879         (emit_debug_insn_beore_setloc): Declare.
5880         (emit_debug_insn_after): Declare.
5881         (emit_debug_insn_after_noloc): Declare.
5882         (emit_debug_insn_after_setloc): Declare.
5883         (emit_debug_insn): Declare.
5884         (make_debug_insn_raw): Declare.
5885         (prev_nondebug_insn): Declare.
5886         (next_nondebug_insn): Declare.
5887         (delegitimize_mem_from_attrs): Declare.
5888         (get_max_insn_count): Declare.
5889         (wrap_constant): Declare.
5890         (unwrap_constant): Declare.
5891         (get_curr_insn_source_location): Declare.
5892         (get_curr_insn_block): Declare.
5893         * tree-inline.c (insert_debug_decl_map): New.
5894         (processing_debug_stmt): New.
5895         (remap_decl): Don't create new mappings in debug stmts.
5896         (remap_gimple_op_r): Don't add references in debug stmts.
5897         (copy_tree_body_r): Likewise.
5898         (remap_gimple_stmt): Handle debug bind stmts.
5899         (copy_bb): Skip debug stmts.
5900         (copy_edges_for_bb): Likewise.
5901         (copy_debug_stmt): New.
5902         (copy_debug_stmts): New.
5903         (copy_body): Copy debug stmts at the end.
5904         (insert_init_debug_bind): New.
5905         (insert_init_stmt): Take id.  Skip and emit debug stmts.
5906         (setup_one_parameter): Remap variable earlier, register debug mapping.
5907         (estimate_num_insns): Skip debug stmts.
5908         (expand_call_inline): Preserve debug_map.
5909         (optimize_inline_calls): Check for no debug_stmts left-overs.
5910         (unsave_expr_now): Preserve debug_map.
5911         (copy_gimple_seq_and_replace_locals): Likewise.
5912         (tree_function_versioning): Check for no debug_stmts left-overs.
5913         Init and destroy debug_map as needed.  Split edges unconditionally.
5914         (build_duplicate_type): Init and destroy debug_map as needed.
5915         * tree-inline.h: Include gimple.h instead of pointer-set.h.
5916         (struct copy_body_data): Add debug_stmts and debug_map.
5917         * sched-int.h (struct ready_list): Add n_debug.
5918         (struct deps): Add last_debug_insn.
5919         (DEBUG_INSN_SCHED_P): New.
5920         (BOUNDARY_DEBUG_INSN_P): New.
5921         (SCHEDULE_DEBUG_INSN_P): New.
5922         (sd_iterator_cond): Accept empty list.
5923         * combine.c (create_log_links): Skip debug insns.
5924         (combine_instructions): Likewise.
5925         (cleanup_auto_inc_dec): New.  From Jakub Jelinek: Make sure the
5926         return value is always unshared.
5927         (struct rtx_subst_pair): New.
5928         (auto_adjust_pair): New.
5929         (propagate_for_debug_subst): New.
5930         (propagate_for_debug): New.
5931         (try_combine): Skip debug insns.  Propagate removed defs into
5932         debug insns.
5933         (next_nonnote_nondebug_insn): New.
5934         (distribute_notes): Use it.  Skip debug insns.
5935         (distribute_links): Skip debug insns.
5936         * tree-outof-ssa.c (set_location_for_edge): Likewise.
5937         * resource.c (mark_target_live_regs): Likewise.
5938         * var-tracking.c: Include cselib.h and target.h.
5939         (enum micro_operation_type): Add MO_VAL_USE, MO_VAL_LOC, and
5940         MO_VAL_SET.
5941         (micro_operation_type_name): New.
5942         (enum emit_note_where): Add EMIT_NOTE_AFTER_CALL_INSN.
5943         (struct micro_operation_def): Update comments.
5944         (decl_or_value): New type.  Use instead of decls.
5945         (struct emit_note_data_def): Add vars.
5946         (struct attrs_def): Use decl_or_value.
5947         (struct variable_tracking_info_def): Add permp, flooded.
5948         (struct location_chain_def): Update comment.
5949         (struct variable_part_def): Use decl_or_value.
5950         (struct variable_def): Make var_part a variable length array.
5951         (valvar_pool): New.
5952         (scratch_regs): New.
5953         (cselib_hook_called): New.
5954         (dv_is_decl_p): New.
5955         (dv_is_value_p): New.
5956         (dv_as_decl): New.
5957         (dv_as_value): New.
5958         (dv_as_opaque): New.
5959         (dv_onepart_p): New.
5960         (dv_pool): New.
5961         (IS_DECL_CODE): New.
5962         (check_value_is_not_decl): New.
5963         (dv_from_decl): New.
5964         (dv_from_value): New.
5965         (dv_htab_hash): New.
5966         (variable_htab_hash): Use it.
5967         (variable_htab_eq): Support values.
5968         (variable_htab_free): Free from the right pool.
5969         (attrs_list_member, attrs_list_insert): Use decl_or_value.
5970         (attrs_list_union): Adjust.
5971         (attrs_list_mpdv_union): New.
5972         (tie_break_pointers): New.
5973         (canon_value_cmp): New.
5974         (unshare_variable): Return possibly-modified slot.
5975         (vars_copy_1): Adjust.
5976         (var_reg_decl_set): Adjust.  Split out of...
5977         (var_reg_set): ... this.
5978         (get_init_value): Adjust.
5979         (var_reg_delete_and_set): Adjust.
5980         (var_reg_delete): Adjust.
5981         (var_regno_delete): Adjust.
5982         (var_mem_decl_set): Split out of...
5983         (var_mem_set): ... this.
5984         (var_mem_delete_and_set): Adjust.
5985         (var_mem_delete): Adjust.
5986         (val_store): New.
5987         (val_reset): New.
5988         (val_resolve): New.
5989         (variable_union): Adjust.  Speed up merge of 1-part vars.
5990         (variable_canonicalize): Use unshared slot.
5991         (VALUED_RECURSED_INTO): New.
5992         (find_loc_in_1pdv): New.
5993         (struct dfset_merge): New.
5994         (insert_into_intersection): New.
5995         (intersect_loc_chains): New.
5996         (loc_cmp): New.
5997         (canonicalize_loc_order_check): New.
5998         (canonicalize_values_mark): New.
5999         (canonicalize_values_star): New.
6000         (variable_merge_over_cur): New.
6001         (variable_merge_over_src): New.
6002         (dataflow_set_merge): New.
6003         (dataflow_set_equiv_regs): New.
6004         (remove_duplicate_values): New.
6005         (struct dfset_post_merge): New.
6006         (variable_post_merge_new_vals): New.
6007         (variable_post_merge_perm_vals): New.
6008         (dataflow_post_merge_adjust): New.
6009         (find_mem_expr_in_1pdv): New.
6010         (dataflow_set_preserve_mem_locs): New.
6011         (dataflow_set_remove_mem_locs): New.
6012         (dataflow_set_clear_at_call): New.
6013         (onepart_variable_different_p): New.
6014         (variable_different_p): Use it.
6015         (dataflow_set_different_1): Adjust.  Make detailed dump more verbose.
6016         (track_expr_p): Add need_rtl parameter.  Don't generate rtl
6017         if not needed.
6018         (track_loc_p): Pass it true.
6019         (struct count_use_info): New.
6020         (find_use_val): New.
6021         (replace_expr_with_values): New.
6022         (log_op_type): New.
6023         (use_type): New, partially split out of...
6024         (count_uses): ... this.  Count new micro-ops.
6025         (count_uses_1): Adjust.
6026         (count_stores): Adjust.
6027         (count_with_sets): New.
6028         (VAL_NEEDS_RESOLUTION): New.
6029         (VAL_HOLDS_TRACK_EXPR): New.
6030         (VAL_EXPR_IS_COPIED): New.
6031         (VAL_EXPR_IS_CLOBBERED): New.
6032         (add_uses): Adjust.  Generate new micro-ops.
6033         (add_uses_1): Adjust.
6034         (add_stores): Generate new micro-ops.
6035         (add_with_sets): New.
6036         (find_src_status): Adjust.
6037         (find_src_set_src): Adjust.
6038         (compute_bb_dataflow): Use dataflow_set_clear_at_call.
6039         Handle new micro-ops.  Canonicalize value equivalances.
6040         (vt_find_locations): Compute total size of hash tables for
6041         dumping.  Perform merge for var-tracking-assignments.  Don't
6042         disregard single-block loops.
6043         (dump_attrs_list): Handle decl_or_value.
6044         (dump_variable): Take variable.  Deal with decl_or_value.
6045         (dump_variable_slot): New.
6046         (dump_vars): Use it.
6047         (dump_dataflow_sets): Adjust.
6048         (set_slot_part): New, extended to support one-part variables
6049         after splitting out of...
6050         (set_variable_part): ... this.
6051         (clobber_slot_part): New, split out of...
6052         (clobber_variable_part): ... this.
6053         (delete_slot_part): New, split out of...
6054         (delete_variable_part): .... this.
6055         (check_wrap_constant): New.
6056         (vt_expand_loc_callback): New.
6057         (vt_expand_loc): New.
6058         (emit_note_insn_var_location): Adjust.  Handle values.  Handle
6059         EMIT_NOTE_AFTER_CALL_INSN.
6060         (emit_notes_for_differences_1): Adjust.  Handle values.
6061         (emit_notes_for_differences_2): Likewise.
6062         (emit_notes_for_differences): Adjust.
6063         (emit_notes_in_bb): Take pointer to set.  Emit AFTER_CALL_INSN notes.
6064         Adjust.  Handle new micro-ops.
6065         (vt_add_function_parameters): Adjust.  Create and bind values.
6066         (vt_initialize): Adjust.  Initialize scratch_regs and
6067         valvar_pool, flooded and perm..  Initialize and use cselib.  Log
6068         operations.  Move some code to count_with_sets and add_with_sets.
6069         (delete_debug_insns): New.
6070         (vt_debug_insns_local): New.
6071         (vt_finalize): Release permp, valvar_pool, scratch_regs.  Finish
6072         cselib.
6073         (var_tracking_main): If var-tracking-assignments is enabled
6074         but var-tracking isn't, delete debug insns and leave.  Likewise
6075         if we exceed limits or fail the stack adjustments tests, and
6076         after all var-tracking processing.
6077         More in var-tracking, from Jakub Jelinek <jakub@redhat.com>:
6078         (dataflow_set): Add traversed_vars.
6079         (value_chain, const_value_chain): New typedefs.
6080         (value_chain_pool, value_chains): New variables.
6081         (value_chain_htab_hash, value_chain_htab_eq, add_value_chain,
6082         add_value_chains, add_cselib_value_chains, remove_value_chain,
6083         remove_value_chains, remove_cselib_value_chains): New functions.
6084         (shared_hash_find_slot_unshare_1, shared_hash_find_slot_1,
6085         shared_hash_find_slot_noinsert_1, shared_hash_find_1): New
6086         static inlines.
6087         (shared_hash_find_slot_unshare, shared_hash_find_slot,
6088         shared_hash_find_slot_noinsert, shared_hash_find): Update.
6089         (dst_can_be_shared): New variable.
6090         (unshare_variable): Unshare set->vars if shared, use shared_hash_*.
6091         Clear dst_can_be_shared.  If set->traversed_vars is non-NULL and
6092         different from set->vars, look up slot again instead of using the
6093         passed in slot.
6094         (dataflow_set_init): Initialize traversed_vars.
6095         (variable_union): Use shared_hash_*.  Use initially NO_INSERT
6096         lookup if set->vars is shared.  Don't keep slot cleared before
6097         calling unshare_variable.  Unshare set->vars if needed.  Adjust
6098         unshare_variable callers.  Clear dst_can_be_shared if needed.
6099         Even ->refcount == 1 vars must be unshared if set->vars is shared
6100         and var needs to be modified.
6101         (dataflow_set_union): Set traversed_vars during canonicalization.
6102         (VALUE_CHANGED, DECL_CHANGED): Define.
6103         (set_dv_changed, dv_changed_p): New static inlines.
6104         (track_expr_p): Clear DECL_CHANGED.
6105         (dump_dataflow_sets): Set it.
6106         (variable_was_changed): Call set_dv_changed.
6107         (emit_note_insn_var_location): Likewise.
6108         (changed_variables_stack): New variable.
6109         (check_changed_vars_1, check_changed_vars_2): New functions.
6110         (emit_notes_for_changes): Do nothing if changed_variables is
6111         empty.  Traverse changed_variables with check_changed_vars_1,
6112         call check_changed_vars_2 on each changed_variables_stack entry.
6113         (emit_notes_in_bb): Add SET argument.  Just clear it at the
6114         beginning, use it instead of local &set, don't destroy it at the end.
6115         (vt_emit_notes): Call dataflow_set_clear early on all
6116         VTI(bb)->out sets, never use them, instead use emit_notes_in_bb
6117         computed set, dataflow_set_clear also VTI(bb)->in when we are
6118         done with the basic block.  Initialize changed_variables_stack,
6119         free it afterwards.  If ENABLE_CHECKING verify that after noting
6120         differences to an empty set value_chains hash table is empty.
6121         (vt_initialize): Initialize value_chains and value_chain_pool.
6122         (vt_finalize): Delete value_chains htab, free value_chain_pool.
6123         (variable_tracking_main): Call dump_dataflow_sets before calling
6124         vt_emit_notes, not after it.
6125         * tree-flow.h (propagate_defs_into_debug_stmts): Declare.
6126         (propagate_var_def_into_debug_stmts): Declare.
6127         * df-problems.c (df_lr_bb_local_compute): Skip debug insns.
6128         (df_set_note): Reject debug insns.
6129         (df_whole_mw_reg_dead_p): Take added_notes_p argument.  Don't
6130         add notes to debug insns.
6131         (df_note_bb_compute): Adjust.  Likewise.
6132         (df_simulate_uses): Skip debug insns.
6133         (df_simulate_initialize_backwards): Likewise.
6134         * reg-stack.c (subst_stack_regs_in_debug_insn): New.
6135         (subst_stack_regs_pat): Reject debug insns.
6136         (convert_regs_1): Handle debug insns.
6137         * Makefile.in (TREE_INLINE_H): Take pointer-set.h from GIMPLE_H.
6138         (print-rtl.o): Depend on cselib.h.
6139         (cselib.o): Depend on TREE_PASS_H.
6140         (var-tracking.o): Depend on cselib.h and TARGET_H.
6141         * sched-rgn.c (rgn_estimate_number_of_insns): Discount debug insns.
6142         (init_ready_list): Skip boundary debug insns.
6143         (add_branch_dependences): Skip debug insns.
6144         (free_block_dependencies): Check for blocks with only debug insns.
6145         (compute_priorities): Likewise.
6146         * gimple.c (gss_for_code): Handle GIMPLE_DEBUG.
6147         (gimple_build_with_ops_stat): Take subcode as unsigned.  Adjust
6148         all callers.
6149         (gimple_build_debug_bind_stat): New.
6150         (empty_body_p): Skip debug stmts.
6151         (gimple_has_side_effects): Likewise.
6152         (gimple_rhs_has_side_effects): Likewise.
6153         * gimple.h (enum gimple_debug_subcode, GIMPLE_DEBUG_BIND): New.
6154         (gimple_build_debug_bind_stat): Declare.
6155         (gimple_build_debug_bind): Define.
6156         (is_gimple_debug): New.
6157         (gimple_debug_bind_p): New.
6158         (gimple_debug_bind_get_var): New.
6159         (gimple_debug_bind_get_value): New.
6160         (gimple_debug_bind_get_value_ptr): New.
6161         (gimple_debug_bind_set_var): New.
6162         (gimple_debug_bind_set_value): New.
6163         (GIMPLE_DEBUG_BIND_NOVALUE): New internal temporary macro.
6164         (gimple_debug_bind_reset_value): New.
6165         (gimple_debug_bind_has_value_p): New.
6166         (gsi_next_nondebug): New.
6167         (gsi_prev_nondebug): New.
6168         (gsi_start_nondebug_bb): New.
6169         (gsi_last_nondebug_bb): New.
6170         * sched-vis.c (print_pattern): Handle VAR_LOCATION.
6171         (print_insn): Handle DEBUG_INSN.
6172         * tree-cfg.c (remove_bb): Walk stmts backwards.  Let loc
6173         of first insn prevail.
6174         (first_stmt): Skip debug stmts.
6175         (first_non_label_stmt): Likewise.
6176         (last_stmt): Likewise.
6177         (has_zero_uses_1): New.
6178         (single_imm_use_1): New.
6179         (verify_gimple_debug): New.
6180         (verify_types_in_gimple_stmt): Handle debug stmts.
6181         (verify_stmt): Likewise.
6182         (debug_loop_num): Skip debug stmts.
6183         (remove_edge_and_dominated_blocks): Remove dominators last.
6184         * tree-ssa-reasssoc.c (rewrite_expr_tree): Propagate into debug stmts.
6185         (linearize_expr): Likewise.
6186         * config/i386/i386.c (ix86_delegitimize_address): Call
6187         default implementation.
6188         * config/ia64/ia64.c (ia64_safe_itanium_class): Handle debug insns.
6189         (group_barrier_needed): Skip debug insns.
6190         (emit_insn_group_barriers): Likewise.
6191         (emit_all_insn_group_barriers): Likewise.
6192         (ia64_variable_issue): Handle debug insns.
6193         (ia64_dfa_new_cycle): Likewise.
6194         (final_emit_insn_group_barriers): Skip debug insns.
6195         (ia64_dwarf2out_def_steady_cfa): Take frame argument.  Don't
6196         def cfa without frame.
6197         (process_set): Likewise.
6198         (process_for_unwind_directive): Pass frame on.
6199         * config/rs6000/rs6000.c (TARGET_DELEGITIMIZE_ADDRESS): Define.
6200         (rs6000_delegitimize_address): New.
6201         (rs6000_debug_adjust_cost): Handle debug insns.
6202         (is_microcoded_insn): Likewise.
6203         (is_cracked_insn): Likewise.
6204         (is_nonpipeline_insn): Likewise.
6205         (insn_must_be_first_in_group): Likewise.
6206         (insn_must_be_last_in_group): Likewise.
6207         (force_new_group): Likewise.
6208         * cfgrtl.c (rtl_split_block): Emit INSN_DELETED note if block
6209         contains only debug insns.
6210         (rtl_merge_blocks): Skip debug insns.
6211         (purge_dead_edges): Likewise.
6212         (rtl_block_ends_with_call_p): Skip debug insns.
6213         * dce.c (deletable_insn_p): Handle VAR_LOCATION.
6214         (mark_reg_dependencies): Skip debug insns.
6215         * params.def (PARAM_MIN_NONDEBUG_INSN_UID): New.
6216         * tree-ssanames.c (release_ssa_name): Propagate def into debug stmts.
6217         * tree-ssa-threadedge.c
6218         (record_temporary_equivalences_from_stmts): Skip debug stmts.
6219         * regcprop.c (replace_oldest_value_addr): Skip debug insns.
6220         (replace_oldest_value_mem): Use ALL_REGS for debug insns.
6221         (copyprop_hardreg_forward_1): Handle debug insns.
6222         * reload1.c (reload): Skip debug insns.  Replace unassigned
6223         pseudos in debug insns with their equivalences.
6224         (eliminate_regs_in_insn): Skip debug insns.
6225         (emit_input_reload_insns): Skip debug insns at first, adjust
6226         them later.
6227         * tree-ssa-operands.c (add_virtual_operand): Reject debug stmts.
6228         (get_indirect_ref_operands): Pass opf_no_vops on.
6229         (get_expr_operands): Likewise.  Skip debug stmts.
6230         (parse_ssa_operands): Scan debug insns with opf_no_vops.
6231
6232 2009-09-01  Richard Henderson  <rth@redhat.com>
6233
6234         * tree-ssa-ccp.c (ccp_initialize): Make sure to simulate
6235         stmt_ends_pp_p statements at least once.
6236         * tree-vrp.c (vrp_initialize): Likewise.
6237         (vrp_visit_stmt): Be prepared for non-interesting stmts.
6238
6239 2009-09-01  Dodji Seketeli  <dodji@redhat.com>
6240
6241         PR bootstrap/41205
6242         Fix AIX bootstrap after PR debug/30161
6243         * dwarf2out.c (make_ith_pack_parameter_name): Don't used strnlen
6244         that is a GNU extension.
6245         (tmpl_value_parm_die_table): Move the definition of this global
6246         outside #ifdef DWARF2_DEBUGGING_INFO region.
6247
6248 2009-09-01  Richard Guenther  <rguenther@suse.de>
6249
6250         * tree.c (tree_expr_size): New function.
6251         * tree.h (tree_expr_size): Declare.
6252         * rtlanal.c (rtx_addr_can_trap_p_1): Adjust comment.
6253         * builtins.c (fold_builtin_memory_op): Use tree_expr_size.
6254         * langhooks.c (lhd_expr_size): Remove.
6255         * langhooks.h (struct lang_hooks): Remove expr_size.
6256         * explow.c (expr_size): Use tree_expr_size.
6257         (int_expr_size): Likewise.
6258         * langhooks-def.h (lhd_expr_size): Remove.
6259         (LANG_HOOKS_EXPR_SIZE): Likewise.
6260         (LANG_HOOKS_INITIALIZER): Adjust.
6261
6262 2009-09-01  Richard Guenther  <rguenther@suse.de>
6263
6264         * tree-flow.h (mark_addressable): Move declaration ...
6265         * tree.h (mark_addressable): ... here.
6266         * stmt.c (expand_asm_operands): Use mark_addressable, not
6267         lang_hooks.mark_addressable.
6268         * langhooks-def.h (LANG_HOOKS_INITIALIZER): Remove
6269         LANG_HOOKS_MARK_ADDRESSABLE.
6270         * langhooks.h (struct lang_hooks): Remove mark_addressable langhook.
6271         * c-objc-common.h (LANG_HOOKS_MARK_ADDRESSABLE): Remove.
6272
6273 2009-08-31  Chris Demetriou  <cgd@google.com>
6274
6275         * config/i386/i386.c (ix86_vectorize_builtin_conversion): Never
6276         vectorize if not TARGET_SSE2.
6277
6278 2009-08-31  DJ Delorie  <dj@redhat.com>
6279
6280         * config/mep/mep.h (FUNCTION_ARG_REGNO_P): Exclude coprocessor
6281         registers if no coprocessor is enabled.
6282
6283 2009-08-31  Dodji Seketeli  <dodji@redhat.com>
6284
6285         PR debug/30161
6286         * cgraph.h (cgraph_get_node): Declare ...
6287         * cgraph.c (cgraph_get_node): ... new function.
6288         * dwarf2out.c (gen_generic_params_dies,
6289         generic_parameter_die, tree_add_const_value_attribute_for_decl,
6290         make_ith_pack_parameter_name,
6291         append_entry_to_tmpl_value_parm_die_table,
6292         gen_remaining_tmpl_value_param_die_attribute): New functions.
6293         (gen_subprogram_die): Generate debug info for template parameters
6294         if debug info level is higher than DINFO_LEVEL_TERSE.
6295         Use tree_add_const_value_attribute_for_decl instead of
6296         tree_add_const_value_attribute.
6297         (gen_const_die): Use tree_add_const_value_attribute_for_decl
6298         instead of tree_add_const_value_attribute.
6299         (gen_struct_or_union_type_die): Generate debug
6300         info for template parameters if debug info level is higher than
6301         DINFO_LEVEL_TERSE.
6302         (tree_add_const_value_attribute): Handle integral and pointer
6303         constants. Update comment.
6304         (dwarf_tag_name): Support DW_TAG_GNU_template_template_param.
6305         (dwarf_attr_name): Support DW_AT_GNU_template_name.
6306         (reference_to_unused): Fix thinko. Remove redundant predicates from
6307         tests.
6308         (tree_add_const_value_attribute): Make this work for constant
6309         expressions only.
6310         tree_add_const_value_attribute_for_decl is to be used for variable
6311         DECLs now.
6312         (add_location_or_const_value_attribute): Use
6313         tree_add_const_value_attribute_for_decl now.
6314         (dwarf2out_finish): Emit the DW_AT_const_value attribute of
6315         DW_TAG_template_value_param DIEs after function DIEs have been
6316         emitted.
6317         * langhooks.h (lang_hooks_for_types): Add
6318         get_argument_pack_elems.
6319         (lang_hooks_for_decls): Add generic_generic_parameter_decl_p.
6320         (lang_hooks): Added get_innermost_generic_parms,
6321         get_innermost_generic_args.
6322         * langhooks-def.h (LANG_HOOKS_GET_INNERMOST_GENERIC_PARMS,
6323         LANG_HOOKS_GET_INNERMOST_GENERIC_ARGS,
6324         LANG_HOOKS_GET_ARGUMENT_PACK_ELEMS,
6325         LANG_HOOKS_GENERIC_GENERIC_PARAMETER_DECL_P): New language hooks.
6326
6327 2009-08-31  DJ Delorie  <dj@redhat.com>
6328
6329         * config/mep/mep.c (machine_function): Add frame_locked flag.  Set
6330         it once we start generating the prologue or epilogue.
6331         (mep_call_saves_register): If the frame is locked, re-use
6332         cached values.
6333         (mep_assign_save_slots): New, broken out from mep_expand_prologue.
6334         (mep_expand_prologue): Call it.
6335         (mep_expand_epilogue): Likewise.
6336         (mep_start_function): Use the same logic as mep_expand_prologue.
6337         (mep_pass_by_reference): Make logic more readable.
6338         (mep_return_in_memory): Zero-sized objects are passed in memory.
6339         (mep_reorg_noframe): Make sure we have accurate REG_DEAD notes.
6340
6341 2009-08-31  Richard Guenther  <rguenther@suse.de>
6342
6343         * builtins.c (fold_builtin_memory_op): Use the alias oracle
6344         to query if the memory regions for memmove overlap.
6345         * tree-ssa-alias.c (ptr_deref_may_alias_decl_p): Relax the
6346         asserts on pointers, instead deal with odd trees.
6347         (ptr_derefs_may_alias_p): Likewise.
6348         (refs_may_alias_p_1): Constructor bases also never alias.
6349
6350 2009-08-31  Gerald Pfeifer  <gerald@pfeifer.com>
6351
6352         * doc/install.texi (Final install): Adjust reference on where to
6353         order printed manuals.
6354
6355 2009-08-30  Olivier Hainque  <hainque@adacore.com>
6356
6357         * dwarf2out.c (switch_to_frame_table_section): Move
6358         definition prior to first use.
6359
6360 2009-08-30  Richard Guenther  <rguenther@suse.de>
6361
6362         PR tree-optimization/41186
6363         * tree-ssa-alias.c (ptr_deref_may_alias_ref_p): Remove.
6364         (ao_ref_init_from_ptr_and_size): New function.
6365         (ref_maybe_used_by_call_p_1): Be more precise tracking
6366         used ranges for builtin functions.
6367         (ref_maybe_used_by_call_p): Adjust.
6368         (call_may_clobber_ref_p_1): Be more precise tracking clobbered
6369         ranges for builtin functions.
6370         * tree-ssa-alias.h (ao_ref_init_from_ptr_and_size): Declare.
6371
6372 2009-08-30  Alan Modra  <amodra@bigpond.net.au>
6373
6374         PR target/41081
6375         * fwprop.c (get_reg_use_in): Delete.
6376         (free_load_extend): New function.
6377         (forward_propagate_subreg): Use it.
6378
6379 2009-08-29  Kaz Kojima  <kkojima@gcc.gnu.org>
6380
6381         * config.gcc (sh*-*-elf): Add superh stuff only for sh*-superh-elf.
6382
6383 2009-08-29  Kai Tietz<kai.tietz@onevision.com>
6384
6385         PR/41184
6386         * config/i386.c (ix86_expand_epilogue): Correct stack adjustment for
6387         padding.
6388
6389 2009-08-29  Douglas B Rupp  <rupp@gnat.com>
6390
6391         * crtstuff.c (__do_global_dtors_aux): Use atexit if no
6392         fini or fini_array section.
6393
6394 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
6395
6396         * graphite-dependences.c (graphite_legal_transform_bb): Call
6397         pbb_remove_duplicate_pdrs.
6398         * graphite-poly.c (can_collapse_pdr): Removed.
6399         (pdr_find_duplicate): Removed.
6400         (can_collapse_pdrs): New.
6401         (pbb_remove_duplicate_pdrs): New.
6402         (new_poly_dr): Do not look for duplicates.
6403         * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
6404         (PBB_PDR_DUPLICATES_REMOVED): New.
6405         (pbb_remove_duplicate_pdrs): Declared.
6406
6407 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
6408
6409         * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
6410         the strides by multiplying by PDR_NB_REFS.
6411         * graphite-poly.c (can_collapse_pdr): New.
6412         (pdr_find_duplicate): New.
6413         (new_poly_dr): Call pdr_find_duplicate.  Collapse duplicate PDRs.
6414         Initialize PDR_NB_REFS.
6415         * graphite-poly.h (struct poly_dr): Add field nb_refs.
6416         (PDR_NB_REFS): New.
6417         (new_poly_dr): Number of subscripts is a graphite_dim_t.
6418
6419 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
6420
6421         PR middle-end/40965
6422         * graphite-poly.c (apply_poly_transforms): Remove legality test before
6423         any transform.
6424
6425 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
6426
6427         * graphite-dependences.c (pddr_original_scattering): Return NULL
6428         for read-read dependence relations.
6429         * graphite-poly.h (enum poly_dr_type): Fix comment.
6430         (pdr_read_p): New.
6431         (pdr_write_p): New.
6432         (pdr_may_write_p): New.
6433
6434 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
6435
6436         * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
6437         (struct poly_dr): Same.
6438         (new_poly_dr): Same.
6439         * graphite-poly.c (new_poly_dr): Same.
6440         * graphite-dependences.c (dot_deps): Disable call to system.
6441
6442 2009-08-28  Cary Coutant  <ccoutant@google.com>
6443
6444         PR debug/41063
6445         * dwarf2out.c (gen_type_die_with_usage): Use proper context for
6446         struct/union/enum types local to a function.
6447
6448 2009-08-28  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
6449             Sebastian Pop  <sebastian.pop@amd.com>
6450
6451         * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
6452         pbb_strip_mine_time_depth.  Changed the implementation so that
6453         transformation is expressed as a transformation on
6454         time (scatttering) dimensions.  Also, ensures that the 2d+1
6455         scheduling format is preserved.
6456         (pbb_strip_mine_profitable_p): Profitability is based on the
6457         iteration number of a given time (scattering) dimension,
6458         and not on a original loop depth dimension.
6459         (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
6460         (pbb_do_strip_mine): Call psct_dynamic_dim.
6461         * graphite-poly.c (pbb_number_of_iterations_at_time): New.
6462         * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
6463         (pbb_nb_dynamic_scattering_transform): New.
6464         (psct_dynamic_dim): New.
6465
6466 2009-08-28  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
6467
6468         * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
6469         * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
6470         * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
6471         * graphite-interchange.c (build_linearized_memory_access): Same.
6472         (memory_stride_in_loop): Same.
6473
6474 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
6475
6476         * graphite-dependences.c (pddr_original_scattering): New.
6477         (graphite_legal_transform_dr): Call pddr_original_scattering.
6478         (dot_deps_1): New.
6479         (dot_deps): New.
6480         * graphite-dependences.h (dot_deps): Declared.
6481         * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
6482         (print_pdr): Print PDR_ID.
6483         * graphite-poly.h (struct poly_dr): Add field id.
6484         (PDR_ID): New.
6485         (pbb_index): New.
6486         * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
6487
6488 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
6489
6490         * graphite-dependences.c (graphite_carried_dependence_level_k): Do
6491         not delete the original dependence relation.
6492
6493 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
6494
6495         * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
6496         (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
6497         (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
6498         (free_poly_ddr): New.
6499         (pddr_is_empty): New.
6500         (dependence_polyhedron_1): Now returns a poly_ddr_p.
6501         (dependence_polyhedron): Same.  Remove useless gcc_assert.
6502         Remove fprintfs.
6503         (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
6504         (graphite_carried_dependence_level_k): Call pddr_is_empty.
6505         * graphite-dependences.h (enum poly_dependence_kind): New.
6506         (poly_dr_pair): Renamed poly_ddr.  Added a field kind.
6507         (PDRP_SOURCE): Renamed PDDR_SOURCE.
6508         (PDRP_SINK): Renamed PDDR_SINK.
6509         (PDRP_DDP): Renamed PDDR_DDP.
6510         (PDDR_KIND): New.
6511         (free_poly_ddr): Declared.
6512         * graphite-poly.c (new_scop): Use the new hash function names.
6513         * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
6514         into original_pddrs.
6515         (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
6516
6517 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
6518
6519         * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
6520         bounds with LT_EXPR to make niter analysis more precise on code
6521         generated by Graphite.
6522
6523 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
6524
6525         * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
6526         (graphite_legal_transform_bb): Same.
6527         (poly_drs_may_alias_p): Same.
6528
6529 2009-08-28  Richard Guenther  <rguenther@suse.de>
6530
6531         * tree.def: Remove note about obsolete TYPE_NONCOPIED_PARTS.
6532
6533 2009-08-28  Jan Beulich  <jbeulich@novell.com>
6534
6535         * config/i386/netware.c: Include langhooks.h.
6536         (i386_nlm_encode_section_info): Simplify.
6537         (netware_override_options): Delete.
6538         * config/i386/netware.h (netware_override_options): Delete
6539         declaration.
6540         (OVERRIDE_OPTIONS): Delete definition.
6541         (SUBTARGET_OVERRIDE_OPTIONS): Define.
6542         (ASM_COMMENT_START): Define.
6543         * config/i386/nwld.h (SUBSUBTARGET_OVERRIDE_OPTIONS): Define.
6544
6545 2009-08-28  Jan Beulich  <jbeulich@novell.com>
6546
6547         * configure.ac: For in-tree ld, do a plain version check to
6548         determine whether comdat groups are supported.
6549         * configure: Regenerate.
6550
6551 2009-08-28  Olivier Hainque  <hainque@adacore.com>
6552
6553         * collect2.c (DO_COLLECT_EXPORT_LIST): New internal macro,
6554         always defined.  Reflect definition or absence of such for
6555         COLLECT_EXPORT_LIST.  Readability helper.
6556         (scanfilter): New enum, to help control what symbols
6557         are to be considered or ignored by scan_prog_file.
6558         (enum pass): Rename as "scanpass", moved together with scanfilter
6559         prior to scan_prog_file's prototype.
6560         (scan_prog_file): Accept and honor scanpass and scanfilter arguments.
6561         Group prototype with the scanpass/scanfilter definitions, factorize
6562         head comments for the several implementations at the prototype.
6563         (main): Reorganize the first pass link control to let AIX
6564         drag only the needed frame tables in executables.  Prevent
6565         frame tables collection during the scan aimed at static ctors.
6566         Pre-link and scan for frame tables later to compensate.
6567         * doc/tm.texi (ASM_OUTPUT_DWARF_TABLE_REF): New macro.
6568         A C statement to issue assembly directives that create a reference
6569         to the given DWARF table identifier label from the current function
6570         section.
6571         * dwarf2out.c (switch_to_eh_frame_section): Add a BACK argument
6572         to differentiate first time section entry.  Only emit a .data
6573         tables start identifier label the first time around.
6574         (switch_to_frame_table_section): New function.  Helper for
6575         output_call_frame_info to switch possibly BACK into the eh_frame
6576         or the debug_frame section depending on FOR_EH.
6577         (output_call_frame_info): Use helper to first enter the proper
6578         frame section.
6579         (output_fde): Use ASM_OUTPUT_DWARF_TABLE_REF when defined to
6580         emit a link to the frame table start label from each function
6581         section.
6582         * config/rs6000/rs6000.c (rs6000_aix_asm_output_dwarf_table_ref):
6583         New function.  Implementation of ASM_OUTPUT_DWARF_TABLE_REF.
6584         * config/rs6000/rs6000-protos.h: Declare it.
6585         * config/rs6000/aix.h (ASM_OUTPUT_DWARF_TABLE_REF): Define.
6586
6587 2009-08-27  Kaz Kojima  <kkojima@gcc.gnu.org>
6588
6589         * config/sh/sh.c (split_branches): Check the result of
6590         next_active_insn.
6591
6592 2009-08-27  Steve Ellcey  <sje@cup.hp.com>
6593
6594         * config/ia64/hpux.h (LIB_SPEC): Add -lrt for when
6595         using -pthread -fopenmp
6596
6597 2009-08-27  Gerald Pfeifer  <gerald@pfeifer.com>
6598
6599         * doc/service.texi (service directory): Update URL.
6600
6601 2009-08-27  Uros Bizjak  <ubizjak@gmail.com>
6602
6603         PR rtl-optimization/40861
6604         * simplify-rtx.c (simplify_subreg): Do not call simplify_gen_subreg to
6605         extract word from a multi-word subreg for negative byte positions.
6606
6607 2009-08-27  Tristan Gingold  <gingold@adacore.com>
6608             Douglas B Rupp  <rupp@gnat.com>
6609
6610         * config/ia64/ia64.c (ia64_attribute_table): Add "common_object" entry.
6611         (SECTION_VMS_OVERLAY): Define.
6612         (ia64_vms_common_object_attribute): Added.  Handle the "common_object"
6613         attribute.
6614         (ia64_vms_elf_asm_named_section): Added.  Generate .section pseudo-op
6615         for common_object.
6616         (ia64_vms_output_aligned_decl_common): Added.  Generate pseudo-op for
6617         common_object declarations.
6618         (ia64_section_type_flags): Set section flag for common_object.
6619         * config/ia64/ia64-protos.h
6620         (ia64_vms_output_aligned_decl_common): Declare.
6621         (ia64_vms_elf_asm_named_section): Declare.
6622
6623 2009-08-27  Michael Matz  <matz@suse.de>
6624
6625         * expr.c (expand_expr_real_2): New function taking exploded
6626         unary or binary expression, split out from ...
6627         (expand_expr_real_1): ... here.  Move over all unary/binary
6628         switch parts to above function, in particular these codes:
6629         PAREN_EXPR, NOP_EXPR, CONVERT_EXPR, POINTER_PLUS_EXPR, PLUS_EXPR,
6630         MINUS_EXPR, MULT_EXPR, TRUNC_DIV_EXPR, FLOOR_DIV_EXPR, CEIL_DIV_EXPR,
6631         ROUND_DIV_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, TRUNC_MOD_EXPR,
6632         FLOOR_MOD_EXPR, CEIL_MOD_EXPR, ROUND_MOD_EXPR, FIXED_CONVERT_EXPR,
6633         FIX_TRUNC_EXPR, FLOAT_EXPR, NEGATE_EXPR, ABS_EXPR, MAX_EXPR, MIN_EXPR,
6634         BIT_NOT_EXPR, TRUTH_AND_EXPR, BIT_AND_EXPR, TRUTH_OR_EXPR,
6635         BIT_IOR_EXPR, TRUTH_XOR_EXPR, BIT_XOR_EXPR, LROTATE_EXPR, RROTATE_EXPR,
6636         LSHIFT_EXPR, RSHIFT_EXPR, LT_EXPR, LE_EXPR, GT_EXPR, GE_EXPR, EQ_EXPR,
6637         NE_EXPR, UNORDERED_EXPR, ORDERED_EXPR, UNLT_EXPR, UNLE_EXPR, UNGT_EXPR,
6638         UNGE_EXPR, UNEQ_EXPR, LTGT_EXPR, TRUTH_NOT_EXPR, COMPLEX_EXPR,
6639         WIDEN_SUM_EXPR, REDUC_MAX_EXPR, REDUC_MIN_EXPR, REDUC_PLUS_EXPR,
6640         VEC_EXTRACT_EVEN_EXPR, VEC_EXTRACT_ODD_EXPR, VEC_INTERLEAVE_HIGH_EXPR,
6641         VEC_INTERLEAVE_LOW_EXPR, VEC_LSHIFT_EXPR, VEC_RSHIFT_EXPR,
6642         VEC_UNPACK_HI_EXPR, VEC_UNPACK_LO_EXPR, VEC_UNPACK_FLOAT_HI_EXPR,
6643         VEC_UNPACK_FLOAT_LO_EXPR, VEC_WIDEN_MULT_HI_EXPR,
6644         VEC_WIDEN_MULT_LO_EXPR, VEC_PACK_TRUNC_EXPR, VEC_PACK_SAT_EXPR,
6645         VEC_PACK_FIX_TRUNC_EXPR.
6646         (<case PAREN_EXPR>): Call set_mem_attributes() with type, not the
6647         full expression.
6648
6649 2009-08-27  Richard Guenther  <rguenther@suse.de>
6650
6651         * gengtype.c (main): Handle uint64_t.
6652         * ipa-utils.c (get_base_var): Indent properly.
6653         * tree-ssa-live.c (debug_scope_block): New function.
6654         * tree-flow.h (debug_scope_block): Declare.
6655         * tree-ssa-copy.c (replace_exp_1): Add vertical space.
6656         * basic-block.h (enum profile_status): Rename to
6657         enum profile_status_d.
6658         (x_profile_status): Adjust type.
6659
6660 2009-08-27  Dodji Seketeli  <dodji@redhat.com>
6661
6662         PR debug/41170
6663         * dwarf2out.c (get_context_die): Declare this static function.
6664         (gen_type_die_with_usage): Make sure a DIE is a generated for
6665         the context of a typedef.
6666
6667 2009-08-26  Anatoly Sokolov  <aesok@post.ru>
6668
6669         * doc/invoke.texi (AVR Options): Remove documentation of -minit-stack
6670         switch.
6671
6672 2009-08-26  Richard Sandiford  <rdsandiford@googlemail.com>
6673
6674         * config/mips/mips-protos.h (mips_output_sync): Declare.
6675         (mips_sync_loop_insns): Likewise.
6676         (mips_output_sync_loop): Replace first two parameters with an rtx.
6677         * config/mips/mips.c (mips_multi_member): New structure.
6678         (mips_multi_members): New variable.
6679         (mips_multi_start): New function.
6680         (mips_multi_add): Likewise.
6681         (mips_multi_add_insn): Likewise.
6682         (mips_multi_add_label): Likewise.
6683         (mips_multi_last_index): Likewise.
6684         (mips_multi_copy_insn): Likewise.
6685         (mips_multi_set_operand): Likewise.
6686         (mips_multi_write): Likewise.
6687         (mips_print_operand_punctuation): Remove '%|' and '%-'.
6688         (mips_init_print_operand_punct): Update accordingly.
6689         (mips_start_ll_sc_sync_block): New function.
6690         (mips_end_ll_sc_sync_block): Likewise.
6691         (mips_output_sync): Likewise.
6692         (mips_sync_insn1_template): Likewise.
6693         (mips_sync_insn2_template): Likewise.
6694         (mips_get_sync_operand): Likewise.
6695         (mips_process_sync_loop): Likewise.
6696         (mips_output_sync_loop): Use mips_process_sync_loop.
6697         (mips_sync_loop_insns): New function.
6698         * config/mips/mips.h (MIPS_COMPARE_AND_SWAP): Delete.
6699         (MIPS_COMPARE_AND_SWAP_12): Likewise.
6700         (MIPS_COMPARE_AND_SWAP_12_ZERO_OP): Likewise.
6701         (MIPS_COMPARE_AND_SWAP_12_NONZERO_OP): Likewise.
6702         (MIPS_SYNC_OP, MIPS_SYNC_OP_12): Likewise.
6703         (MIPS_SYNC_OP_12_AND, MIPS_SYNC_OP_12_XOR): Likewise.
6704         (MIPS_SYNC_OLD_OP_12): Likewise.
6705         (MIPS_SYNC_OLD_OP_12_AND, MIPS_SYNC_OLD_OP_12_XOR): Likewise.
6706         (MIPS_SYNC_NEW_OP_12): Likewise.
6707         (MIPS_SYNC_NEW_OP_12_AND, MIPS_SYNC_NEW_OP_12_XOR): Likewise.
6708         (MIPS_SYNC_OLD_OP, MIPS_SYNC_NEW_OP): Likewise.
6709         (MIPS_SYNC_NAND, MIPS_SYNC_OLD_NAND, MIPS_SYNC_NEW_NAND): Likewise.
6710         (MIPS_SYNC_EXCHANGE, MIPS_SYNC_EXCHANGE_12): Likewise.
6711         (MIPS_SYNC_EXCHANGE_12_ZERO_OP): Likewise.
6712         (MIPS_SYNC_EXCHANGE_12_NONZER_OP): Likewise.
6713         * config/mips/mips.md (sync_mem): New attribute.
6714         (sync_oldval, sync_newval, sync_inclusive_mask): Likewise.
6715         (sync_exclusive_mask, sync_required_oldval): Likewise.
6716         (sync_insn1_op2, sync_insn1, sync_insn2): Likewise.
6717         (sync_release_barrier): Likewise.
6718         (length): Handle sync loops.
6719         (sync): Use mips_output_sync.
6720         * config/mips/sync.md (*memory_barrier): Use mips_output_sync.
6721         (sync_compare_and_swap<mode>): Set the new sync_* attributes
6722         and use mips_output_sync_loop.
6723         (compare_and_swap_12, sync_add<mode>, sync_<optab>_12): Likewise.
6724         (sync_old_<optab>_12, sync_new_<optab>_12, sync_nand_12): Likewise.
6725         (sync_old_nand_12, sync_new_nand_12, sync_sub<mode>): Likewise.
6726         (sync_old_add<mode>, sync_old_sub<mode>): Likewise.
6727         (sync_new_add<mode>, sync_new_sub<mode>): Likewise.
6728         (sync_<optab><mode>, sync_old_<optab><mode>): Likewise.
6729         (sync_new_<optab><mode>, sync_nand<mode>): Likewise.
6730         (sync_old_nand<mode>, sync_new_nand<mode>): Likewise.
6731         (sync_lock_test_and_set<mode>, test_and_set_12): Likewise.
6732
6733 2009-08-26  Richard Guenther  <rguenther@suse.de>
6734
6735         PR middle-end/41163
6736         * gimplify.c (gimplify_addr_expr): Canonicalize ADDR_EXPRs if
6737         the types to not match.
6738         * tree-cfg.c (verify_gimple_assign_single): Adjust ADDR_EXPR
6739         verification.
6740         * tree-ssa.c (useless_type_conversion_p): Conversions to
6741         pointers to unprototyped functions are useless.
6742
6743 2009-08-26  Richard Guenther  <rguenther@suse.de>
6744
6745         * tree-ssa-structalias.c (create_variable_info_for): Remove strange
6746         whole-program condition, prepare to be called for non-globals.
6747         (intra_create_variable_infos): For restrict qualified DECL_BY_REFERENCE
6748         params build a representative with known type and track its fields.
6749
6750 2009-08-26  Uros Bizjak  <ubizjak@gmail.com>
6751
6752         * config/alpha/sync.md: Update comment about unpredictable LL/SC lock
6753         clearing by a taken branch.
6754         (sync_<fetchop_name><mode>): Split when epilogue_completed is set,
6755         effectively after bbro pass.
6756         (sync_nand<mode>): Ditto.
6757         (sync_old_<fetchop_name><mode>): Ditto.
6758         (sync_old_nand<mode>): Ditto.
6759         (sync_new_<fetchop_name><mode>): Dito.
6760         (sync_new_nand<mode>): Ditto.
6761         (sync_compare_and_swap<mode>_1): Ditto.
6762         (*sync_compare_and_swap<mode>): Ditto.
6763         (sync_lock_test_and_set<mode>_1): Ditto.
6764         ("sync_lock_test_and_set<mode>): Ditto.
6765
6766 2009-08-25  Douglas B Rupp  <rupp@gnat.com>
6767
6768         * hwint.h (HOST_LONG_FORMAT): New macro
6769         * bitmap.c, c-decl.c, mips-tfile.c, print-rtl.c, print-tree.c:
6770         Use HOST_PTR_PRINTF.
6771         * system.h (HOST_PTR_PRINTF): Resurrect old macro
6772         * doc/hostconfig.texi (HOST_LONG_FORMAT): Document.
6773         (HOST_PTR_PRINTF): Document.
6774
6775 2009-08-25 Jan Hubicka  <jh@suse.cz>
6776
6777         * config/i386/bmmintrin.h: Replace by #error.
6778
6779         Revert:
6780         Michael Meissner  <michael.meissner@amd.com>
6781         Dwarakanath Rajagopal  <dwarak.rajagopal@amd.com>
6782         Tony Linthicum  <tony.linthicum@amd.com>
6783
6784         * config/i386/i386.h (TARGET_SSE5): New macro for SSE5.
6785         (TARGET_ROUND): New macro for the round/ptest instructions which
6786         are shared between SSE4.1 and SSE5.
6787         (OPTION_MASK_ISA_ROUND): Ditto.
6788         (OPTION_ISA_ROUND): Ditto.
6789         (TARGET_FUSED_MADD): New macro for -mfused-madd swtich.
6790         (TARGET_CPU_CPP_BUILTINS): Add SSE5 support.
6791
6792         * config/i386/i386.opt (-msse5): New switch for SSE5 support.
6793         (-mfused-madd): New switch to give users control over whether the
6794         compiler optimizes to use the multiply/add SSE5 instructions.
6795
6796         * config/i386/i386.c (enum pta_flags): Add PTA_SSE5.
6797         (ix86_handle_option): Turn off 3dnow if -msse5.
6798         (override_options): Add SSE5 support.
6799         (print_operand): %Y prints comparison codes for SSE5 com/pcom
6800         instructions.
6801         (ix86_expand_sse_movcc): Add SSE5 support.
6802         (ix86_expand_sse5_unpack): New function to use pperm to unpack a
6803         vector type to the next largest size.
6804         (ix86_expand_sse5_pack): New function to use pperm to pack a
6805         vector type to the next smallest size.
6806         (IX86_BUILTIN_FMADDSS): New for SSE5 intrinsic.
6807         (IX86_BUILTIN_FMADDSD): Ditto.
6808         (IX86_BUILTIN_FMADDPS): Ditto.
6809         (IX86_BUILTIN_FMADDPD): Ditto.
6810         (IX86_BUILTIN_FMSUBSS): Ditto.
6811         (IX86_BUILTIN_FMSUBSD): Ditto.
6812         (IX86_BUILTIN_FMSUBPS): Ditto.
6813         (IX86_BUILTIN_FMSUBPD): Ditto.
6814         (IX86_BUILTIN_FNMADDSS): Ditto.
6815         (IX86_BUILTIN_FNMADDSD): Ditto.
6816         (IX86_BUILTIN_FNMADDPS): Ditto.
6817         (IX86_BUILTIN_FNMADDPD): Ditto.
6818         (IX86_BUILTIN_FNMSUBSS): Ditto.
6819         (IX86_BUILTIN_FNMSUBSD): Ditto.
6820         (IX86_BUILTIN_FNMSUBPS): Ditto.
6821         (IX86_BUILTIN_FNMSUBPD): Ditto.
6822         (IX86_BUILTIN_PCMOV_V2DI): Ditto.
6823         (IX86_BUILTIN_PCMOV_V4SI): Ditto.
6824         (IX86_BUILTIN_PCMOV_V8HI): Ditto.
6825         (IX86_BUILTIN_PCMOV_V16QI): Ditto.
6826         (IX86_BUILTIN_PCMOV_V4SF): Ditto.
6827         (IX86_BUILTIN_PCMOV_V2DF): Ditto.
6828         (IX86_BUILTIN_PPERM): Ditto.
6829         (IX86_BUILTIN_PERMPS): Ditto.
6830         (IX86_BUILTIN_PERMPD): Ditto.
6831         (IX86_BUILTIN_PMACSSWW): Ditto.
6832         (IX86_BUILTIN_PMACSWW): Ditto.
6833         (IX86_BUILTIN_PMACSSWD): Ditto.
6834         (IX86_BUILTIN_PMACSWD): Ditto.
6835         (IX86_BUILTIN_PMACSSDD): Ditto.
6836         (IX86_BUILTIN_PMACSDD): Ditto.
6837         (IX86_BUILTIN_PMACSSDQL): Ditto.
6838         (IX86_BUILTIN_PMACSSDQH): Ditto.
6839         (IX86_BUILTIN_PMACSDQL): Ditto.
6840         (IX86_BUILTIN_PMACSDQH): Ditto.
6841         (IX86_BUILTIN_PMADCSSWD): Ditto.
6842         (IX86_BUILTIN_PMADCSWD): Ditto.
6843         (IX86_BUILTIN_PHADDBW): Ditto.
6844         (IX86_BUILTIN_PHADDBD): Ditto.
6845         (IX86_BUILTIN_PHADDBQ): Ditto.
6846         (IX86_BUILTIN_PHADDWD): Ditto.
6847         (IX86_BUILTIN_PHADDWQ): Ditto.
6848         (IX86_BUILTIN_PHADDDQ): Ditto.
6849         (IX86_BUILTIN_PHADDUBW): Ditto.
6850         (IX86_BUILTIN_PHADDUBD): Ditto.
6851         (IX86_BUILTIN_PHADDUBQ): Ditto.
6852         (IX86_BUILTIN_PHADDUWD): Ditto.
6853         (IX86_BUILTIN_PHADDUWQ): Ditto.
6854         (IX86_BUILTIN_PHADDUDQ): Ditto.
6855         (IX86_BUILTIN_PHSUBBW): Ditto.
6856         (IX86_BUILTIN_PHSUBWD): Ditto.
6857         (IX86_BUILTIN_PHSUBDQ): Ditto.
6858         (IX86_BUILTIN_PROTB): Ditto.
6859         (IX86_BUILTIN_PROTW): Ditto.
6860         (IX86_BUILTIN_PROTD): Ditto.
6861         (IX86_BUILTIN_PROTQ): Ditto.
6862         (IX86_BUILTIN_PROTB_IMM): Ditto.
6863         (IX86_BUILTIN_PROTW_IMM): Ditto.
6864         (IX86_BUILTIN_PROTD_IMM): Ditto.
6865         (IX86_BUILTIN_PROTQ_IMM): Ditto.
6866         (IX86_BUILTIN_PSHLB): Ditto.
6867         (IX86_BUILTIN_PSHLW): Ditto.
6868         (IX86_BUILTIN_PSHLD): Ditto.
6869         (IX86_BUILTIN_PSHLQ): Ditto.
6870         (IX86_BUILTIN_PSHAB): Ditto.
6871         (IX86_BUILTIN_PSHAW): Ditto.
6872         (IX86_BUILTIN_PSHAD): Ditto.
6873         (IX86_BUILTIN_PSHAQ): Ditto.
6874         (IX86_BUILTIN_FRCZSS): Ditto.
6875         (IX86_BUILTIN_FRCZSD): Ditto.
6876         (IX86_BUILTIN_FRCZPS): Ditto.
6877         (IX86_BUILTIN_FRCZPD): Ditto.
6878         (IX86_BUILTIN_CVTPH2PS): Ditto.
6879         (IX86_BUILTIN_CVTPS2PH): Ditto.
6880         (IX86_BUILTIN_COMEQSS): Ditto.
6881         (IX86_BUILTIN_COMNESS): Ditto.
6882         (IX86_BUILTIN_COMLTSS): Ditto.
6883         (IX86_BUILTIN_COMLESS): Ditto.
6884         (IX86_BUILTIN_COMGTSS): Ditto.
6885         (IX86_BUILTIN_COMGESS): Ditto.
6886         (IX86_BUILTIN_COMUEQSS): Ditto.
6887         (IX86_BUILTIN_COMUNESS): Ditto.
6888         (IX86_BUILTIN_COMULTSS): Ditto.
6889         (IX86_BUILTIN_COMULESS): Ditto.
6890         (IX86_BUILTIN_COMUGTSS): Ditto.
6891         (IX86_BUILTIN_COMUGESS): Ditto.
6892         (IX86_BUILTIN_COMORDSS): Ditto.
6893         (IX86_BUILTIN_COMUNORDSS): Ditto.
6894         (IX86_BUILTIN_COMFALSESS): Ditto.
6895         (IX86_BUILTIN_COMTRUESS): Ditto.
6896         (IX86_BUILTIN_COMEQSD): Ditto.
6897         (IX86_BUILTIN_COMNESD): Ditto.
6898         (IX86_BUILTIN_COMLTSD): Ditto.
6899         (IX86_BUILTIN_COMLESD): Ditto.
6900         (IX86_BUILTIN_COMGTSD): Ditto.
6901         (IX86_BUILTIN_COMGESD): Ditto.
6902         (IX86_BUILTIN_COMUEQSD): Ditto.
6903         (IX86_BUILTIN_COMUNESD): Ditto.
6904         (IX86_BUILTIN_COMULTSD): Ditto.
6905         (IX86_BUILTIN_COMULESD): Ditto.
6906         (IX86_BUILTIN_COMUGTSD): Ditto.
6907         (IX86_BUILTIN_COMUGESD): Ditto.
6908         (IX86_BUILTIN_COMORDSD): Ditto.
6909         (IX86_BUILTIN_COMUNORDSD): Ditto.
6910         (IX86_BUILTIN_COMFALSESD): Ditto.
6911         (IX86_BUILTIN_COMTRUESD): Ditto.
6912         (IX86_BUILTIN_COMEQPS): Ditto.
6913         (IX86_BUILTIN_COMNEPS): Ditto.
6914         (IX86_BUILTIN_COMLTPS): Ditto.
6915         (IX86_BUILTIN_COMLEPS): Ditto.
6916         (IX86_BUILTIN_COMGTPS): Ditto.
6917         (IX86_BUILTIN_COMGEPS): Ditto.
6918         (IX86_BUILTIN_COMUEQPS): Ditto.
6919         (IX86_BUILTIN_COMUNEPS): Ditto.
6920         (IX86_BUILTIN_COMULTPS): Ditto.
6921         (IX86_BUILTIN_COMULEPS): Ditto.
6922         (IX86_BUILTIN_COMUGTPS): Ditto.
6923         (IX86_BUILTIN_COMUGEPS): Ditto.
6924         (IX86_BUILTIN_COMORDPS): Ditto.
6925         (IX86_BUILTIN_COMUNORDPS): Ditto.
6926         (IX86_BUILTIN_COMFALSEPS): Ditto.
6927         (IX86_BUILTIN_COMTRUEPS): Ditto.
6928         (IX86_BUILTIN_COMEQPD): Ditto.
6929         (IX86_BUILTIN_COMNEPD): Ditto.
6930         (IX86_BUILTIN_COMLTPD): Ditto.
6931         (IX86_BUILTIN_COMLEPD): Ditto.
6932         (IX86_BUILTIN_COMGTPD): Ditto.
6933         (IX86_BUILTIN_COMGEPD): Ditto.
6934         (IX86_BUILTIN_COMUEQPD): Ditto.
6935         (IX86_BUILTIN_COMUNEPD): Ditto.
6936         (IX86_BUILTIN_COMULTPD): Ditto.
6937         (IX86_BUILTIN_COMULEPD): Ditto.
6938         (IX86_BUILTIN_COMUGTPD): Ditto.
6939         (IX86_BUILTIN_COMUGEPD): Ditto.
6940         (IX86_BUILTIN_COMORDPD): Ditto.
6941         (IX86_BUILTIN_COMUNORDPD): Ditto.
6942         (IX86_BUILTIN_COMFALSEPD): Ditto.
6943         (IX86_BUILTIN_COMTRUEPD): Ditto.
6944         (IX86_BUILTIN_PCOMEQUB): Ditto.
6945         (IX86_BUILTIN_PCOMNEUB): Ditto.
6946         (IX86_BUILTIN_PCOMLTUB): Ditto.
6947         (IX86_BUILTIN_PCOMLEUB): Ditto.
6948         (IX86_BUILTIN_PCOMGTUB): Ditto.
6949         (IX86_BUILTIN_PCOMGEUB): Ditto.
6950         (IX86_BUILTIN_PCOMFALSEUB): Ditto.
6951         (IX86_BUILTIN_PCOMTRUEUB): Ditto.
6952         (IX86_BUILTIN_PCOMEQUW): Ditto.
6953         (IX86_BUILTIN_PCOMNEUW): Ditto.
6954         (IX86_BUILTIN_PCOMLTUW): Ditto.
6955         (IX86_BUILTIN_PCOMLEUW): Ditto.
6956         (IX86_BUILTIN_PCOMGTUW): Ditto.
6957         (IX86_BUILTIN_PCOMGEUW): Ditto.
6958         (IX86_BUILTIN_PCOMFALSEUW): Ditto.
6959         (IX86_BUILTIN_PCOMTRUEUW): Ditto.
6960         (IX86_BUILTIN_PCOMEQUD): Ditto.
6961         (IX86_BUILTIN_PCOMNEUD): Ditto.
6962         (IX86_BUILTIN_PCOMLTUD): Ditto.
6963         (IX86_BUILTIN_PCOMLEUD): Ditto.
6964         (IX86_BUILTIN_PCOMGTUD): Ditto.
6965         (IX86_BUILTIN_PCOMGEUD): Ditto.
6966         (IX86_BUILTIN_PCOMFALSEUD): Ditto.
6967         (IX86_BUILTIN_PCOMTRUEUD): Ditto.
6968         (IX86_BUILTIN_PCOMEQUQ): Ditto.
6969         (IX86_BUILTIN_PCOMNEUQ): Ditto.
6970         (IX86_BUILTIN_PCOMLTUQ): Ditto.
6971         (IX86_BUILTIN_PCOMLEUQ): Ditto.
6972         (IX86_BUILTIN_PCOMGTUQ): Ditto.
6973         (IX86_BUILTIN_PCOMGEUQ): Ditto.
6974         (IX86_BUILTIN_PCOMFALSEUQ): Ditto.
6975         (IX86_BUILTIN_PCOMTRUEUQ): Ditto.
6976         (IX86_BUILTIN_PCOMEQB): Ditto.
6977         (IX86_BUILTIN_PCOMNEB): Ditto.
6978         (IX86_BUILTIN_PCOMLTB): Ditto.
6979         (IX86_BUILTIN_PCOMLEB): Ditto.
6980         (IX86_BUILTIN_PCOMGTB): Ditto.
6981         (IX86_BUILTIN_PCOMGEB): Ditto.
6982         (IX86_BUILTIN_PCOMFALSEB): Ditto.
6983         (IX86_BUILTIN_PCOMTRUEB): Ditto.
6984         (IX86_BUILTIN_PCOMEQW): Ditto.
6985         (IX86_BUILTIN_PCOMNEW): Ditto.
6986         (IX86_BUILTIN_PCOMLTW): Ditto.
6987         (IX86_BUILTIN_PCOMLEW): Ditto.
6988         (IX86_BUILTIN_PCOMGTW): Ditto.
6989         (IX86_BUILTIN_PCOMGEW): Ditto.
6990         (IX86_BUILTIN_PCOMFALSEW): Ditto.
6991         (IX86_BUILTIN_PCOMTRUEW): Ditto.
6992         (IX86_BUILTIN_PCOMEQD): Ditto.
6993         (IX86_BUILTIN_PCOMNED): Ditto.
6994         (IX86_BUILTIN_PCOMLTD): Ditto.
6995         (IX86_BUILTIN_PCOMLED): Ditto.
6996         (IX86_BUILTIN_PCOMGTD): Ditto.
6997         (IX86_BUILTIN_PCOMGED): Ditto.
6998         (IX86_BUILTIN_PCOMFALSED): Ditto.
6999         (IX86_BUILTIN_PCOMTRUED): Ditto.
7000         (IX86_BUILTIN_PCOMEQQ): Ditto.
7001         (IX86_BUILTIN_PCOMNEQ): Ditto.
7002         (IX86_BUILTIN_PCOMLTQ): Ditto.
7003         (IX86_BUILTIN_PCOMLEQ): Ditto.
7004         (IX86_BUILTIN_PCOMGTQ): Ditto.
7005         (IX86_BUILTIN_PCOMGEQ): Ditto.
7006         (IX86_BUILTIN_PCOMFALSEQ): Ditto.
7007         (IX86_BUILTIN_PCOMTRUEQ): Ditto.
7008         (enum multi_arg_type): New enum for describing the various SSE5
7009         intrinsic argument types.
7010         (bdesc_multi_arg): New table for SSE5 intrinsics.
7011         (ix86_init_mmx_sse_builtins): Add SSE5 intrinsic support.
7012         (ix86_expand_multi_arg_builtin): New function for creating SSE5
7013         intrinsics.
7014         (ix86_expand_builtin): Add SSE5 intrinsic support.
7015         (ix86_sse5_valid_op_p): New function to validate SSE5 3 and 4
7016         operand instructions.
7017         (ix86_expand_sse5_multiple_memory): New function to split the
7018         second memory reference from SSE5 instructions.
7019         (type_has_variadic_args_p): Delete in favor of stdarg_p.
7020         (ix86_return_pops_args): Use stdarg_p to determine if the function
7021         has variable arguments.
7022         (ix86_setup_incoming_varargs): Ditto.
7023         (x86_this_parameter): Ditto.
7024
7025         * config/i386/i386-protos.h (ix86_expand_sse5_unpack): Add
7026         declaration.
7027         (ix86_expand_sse5_pack): Ditto.
7028         (ix86_sse5_valid_op_p): Ditto.
7029         (ix86_expand_sse5_multiple_memory): Ditto.
7030
7031         * config/i386/i386.md (UNSPEC_SSE5_INTRINSIC): Add new UNSPEC
7032         constant for SSE5 support.
7033         (UNSPEC_SSE5_UNSIGNED_CMP): Ditto.
7034         (UNSPEC_SSE5_TRUEFALSE): Ditto.
7035         (UNSPEC_SSE5_PERMUTE): Ditto.
7036         (UNSPEC_SSE5_ASHIFT): Ditto.
7037         (UNSPEC_SSE5_LSHIFT): Ditto.
7038         (UNSPEC_FRCZ): Ditto.
7039         (UNSPEC_CVTPH2PS): Ditto.
7040         (UNSPEC_CVTPS2PH): Ditto.
7041         (PCOM_FALSE): Add new constant for true/false SSE5 comparisons.
7042         (PCOM_TRUE): Ditto.
7043         (COM_FALSE_S): Ditto.
7044         (COM_FALSE_P): Ditto.
7045         (COM_TRUE_S): Ditto.
7046         (COM_TRUE_P): Ditto.
7047         (type attribute): Add ssemuladd, sseiadd1, ssecvt1, sse4arg types.
7048         (unit attribute): Add support for ssemuladd, ssecvt1, sseiadd1 sse4arg
7049         types.
7050         (memory attribute): Ditto.
7051         (sse4_1_round<mode>2): Use TARGET_ROUND instead of TARGET_SSE4_1.
7052         Use SSE4_1_ROUND_* constants instead of hard coded numbers.
7053         (rint<mode>2): Use TARGET_ROUND instead of TARGET_SSE4_1.
7054         (floor<mode>2): Ditto.
7055         (ceil<mode>2): Ditto.
7056         (btrunc<mode>2): Ditto.
7057         (nearbyintdf2): Ditto.
7058         (nearbyintsf2): Ditto.
7059         (sse_setccsf): Disable if SSE5.
7060         (sse_setccdf): Ditto.
7061         (sse5_setcc<mode>): New support for SSE5 conditional move.
7062         (sse5_pcmov_<mode>): Ditto.
7063
7064         * config/i386/sse.md (SSEMODE1248): New mode iterator for SSE5.
7065         (SSEMODEF4): Ditto.
7066         (SSEMODEF2P): Ditto.
7067         (ssemodesuffixf4): New mode attribute for SSE5.
7068         (ssemodesuffixf2s): Ditto.
7069         (ssemodesuffixf2c): Ditto.
7070         (sserotatemax): Ditto.
7071         (ssescalarmode): Ditto.
7072         (sse_maskcmpv4sf3): Disable if SSE5.
7073         (sse_maskcmpv2df3): Ditto.
7074         (sse_vmmaskcmpv4sf3): Ditto.
7075         (sse5_fmadd<mode>4): Add SSE5 floating point multiply/add instructions.
7076         (sse5_vmfmadd<mode>4): Ditto.
7077         (sse5_fmsub<mode>4): Ditto.
7078         (sse5_vmfmsub<mode>4): Ditto.
7079         (sse5_fnmadd<mode>4): Ditto.
7080         (sse5_vmfnmadd<mode>4): Ditto.
7081         (sse5_fnmsub<mode>4): Ditto.
7082         (sse5_vmfnmsub<mode>4): Ditto.
7083         (sse5i_fmadd<mode>4): Ditto.
7084         (sse5i_fmsub<mode>4): Ditto.
7085         (sse5i_fnmadd<mode>4): Ditto.
7086         (sse5i_fnmsub<mode>4): Ditto.
7087         (sse5i_vmfmadd<mode>4): Ditto.
7088         (sse5i_vmfmsub<mode>4): Ditto.
7089         (sse5i_vmfnmadd<mode>4): Ditto.
7090         (sse5i_vmfnmsub<mode>4): Ditto.
7091         (mulv16qi3): Add SSE5 support.
7092         (mulv4si3): Ditto.
7093         (sse5_mulv4si3): New insn for 32-bit multiply support on SSE5.
7094         (sse2_mulv4si3): Disable if SSE5.
7095         (sse4_1_roundpd): Use TARGET_ROUND instead of TARGET_SSE4_1.
7096         (sse4_1_roundps): Ditto.
7097         (sse4_1_roundsd): Ditto.
7098         (sse4_1_roundss): Ditto.
7099         (sse_maskcmpv4sf3): Disable if SSE5 so the SSE5 instruction will
7100         be generated.
7101         (sse_maskcmpsf3): Ditto.
7102         (sse_vmmaskcmpv4sf3): Ditto.
7103         (sse2_maskcmpv2df3): Ditto.
7104         (sse2_maskcmpdf3): Ditto.
7105         (sse2_vmmaskcmpv2df3): Ditto.
7106         (sse2_eq<mode>3): Ditto.
7107         (sse2_gt<mode>3): Ditto.
7108         (sse5_pcmov_<mode>): Add SSE5 support.
7109         (vec_unpacku_hi_v16qi): Ditto.
7110         (vec_unpacks_hi_v16qi): Ditto.
7111         (vec_unpacku_lo_v16qi): Ditto.
7112         (vec_unpacks_lo_v16qi): Ditto.
7113         (vec_unpacku_hi_v8hi): Ditto.
7114         (vec_unpacks_hi_v8hi): Ditto.
7115         (vec_unpacku_lo_v8hi): Ditto.
7116         (vec_unpacks_lo_v8hi): Ditto.
7117         (vec_unpacku_hi_v4si): Ditto.
7118         (vec_unpacks_hi_v4si): Ditto.
7119         (vec_unpacku_lo_v4si): Ditto.
7120         (vec_unpacks_lo_v4si): Ditto.
7121         (sse5_pmacsww): New SSE5 intrinsic insn.
7122         (sse5_pmacssww): Ditto.
7123         (sse5_pmacsdd): Ditto.
7124         (sse5_pmacssdd): Ditto.
7125         (sse5_pmacssdql): Ditto.
7126         (sse5_pmacssdqh): Ditto.
7127         (sse5_pmacsdqh): Ditto.
7128         (sse5_pmacsswd): Ditto.
7129         (sse5_pmacswd): Ditto.
7130         (sse5_pmadcsswd): Ditto.
7131         (sse5_pmadcswd): Ditto.
7132         (sse5_pcmov_<move>): Conditional move support on SSE5.
7133         (sse5_phaddbw): New SSE5 intrinsic insn.
7134         (sse5_phaddbd): Ditto.
7135         (sse5_phaddbq): Ditto.
7136         (sse5_phaddwd): Ditto.
7137         (sse5_phaddwq): Ditto.
7138         (sse5_phadddq): Ditto.
7139         (sse5_phaddubw): Ditto.
7140         (sse5_phaddubd): Ditto.
7141         (sse5_phaddubq): Ditto.
7142         (sse5_phadduwd): Ditto.
7143         (sse5_phadduwq): Ditto.
7144         (sse5_phaddudq): Ditto.
7145         (sse5_phsubbw): Ditto.
7146         (sse5_phsubwd): Ditto.
7147         (sse5_phsubdq): Ditto.
7148         (sse5_pperm): Ditto.
7149         (sse5_pperm_sign_v16qi_v8hi): New insns for pack/unpack with SSE5.
7150         (sse5_pperm_zero_v16qi_v8hi): Ditto.
7151         (sse5_pperm_sign_v8hi_v4si): Ditto.
7152         (sse5_pperm_zero_v8hi_v4si): Ditto.
7153         (sse5_pperm_sign_v4si_v2di): Ditto.
7154         (sse5_pperm_sign_v4si_v2di): Ditto.
7155         (sse5_pperm_pack_v2di_v4si): Ditto.
7156         (sse5_pperm_pack_v4si_v8hi): Ditto.
7157         (sse5_pperm_pack_v8hi_v16qi): Ditto.
7158         (sse5_perm<mode>): New SSE5 intrinsic insn.
7159         (rotl<mode>3): Ditto.
7160         (sse5_rotl<mode>3): Ditto.
7161         (sse5_ashl<mode>3): Ditto.
7162         (sse5_lshl<mode>3): Ditto.
7163         (sse5_frcz<mode>2): Ditto.
7164         (sse5s_frcz<mode>2): Ditto.
7165         (sse5_cvtph2ps): Ditto.
7166         (sse5_cvtps2ph): Ditto.
7167         (sse5_vmmaskcmp<mode>3): Ditto.
7168         (sse5_com_tf<mode>3): Ditto.
7169         (sse5_maskcmp<mode>3): Ditto.
7170         (sse5_maskcmp_uns<mode>3): Ditto.
7171         (sse5_maskcmp_uns2<mode>3): Ditto.
7172         (sse5_pcom_tf<mode>3): Ditto.
7173
7174         * config/i386/predicates.md (sse5_comparison_float_operator):
7175         New predicate to match the comparison operators supported by
7176         the SSE5 com instruction.
7177         (ix86_comparison_int_operator): New predicate to match just the
7178         signed int comparisons.
7179         (ix86_comparison_uns_operator): New predicate to match just the
7180         unsigned int comparisons.
7181
7182         * doc/invoke.texi (-msse5): Add documentation.
7183         (-mfused-madd): Ditto.
7184
7185         * doc/extend.texi (x86 intrinsics): Document new SSE5 intrinsics.
7186
7187         * config.gcc (i[34567]86-*-*): Include bmmintrin.h and
7188         mmintrin-common.h.
7189         (x86_64-*-*): Ditto.
7190
7191         * config/i386/cpuid.h (bit_SSE5): Define SSE5 bit.
7192
7193         * config/i386/bmmintrin.h: New file, provide common x86 compiler
7194         intrinisics for SSE5.
7195
7196         * config/i386/smmintrin.h: Move instructions shared with SSE5 to
7197         mmintrin-common.h.
7198
7199         * config/i386/mmintrin-common.h: New file, to contain common
7200         instructions between SSE4.1 and SSE5.
7201
7202         * config/i386/netware.c (gen_stdcall_or_fastcall_decoration): Use
7203         FOREACH_FUNCTION_ARGS to iterate over the argument list.
7204         (gen_regparm_prefix): Ditto.
7205
7206         * config/i386/winnt.c (gen_stdcall_or_fastcall_suffix): Use
7207         FOREACH_FUNCTION_ARGS to iterate over the argument list.  Use
7208         prototype_p to determine if a function is prototyped.
7209
7210 2009-08-25 Ville Voutilainen <ville.voutilainen@gmail.com>
7211
7212         * c-common.c (c_common_reswords) add the alignof keyword,
7213         with same RID as __alignof and __alignof__
7214
7215 2009-08-25  Anatoly Sokolov  <aesok@post.ru>
7216
7217         * hooks.h (hook_bool_const_int_const_int_true): Declare.
7218         * hooks.c (hook_bool_const_int_const_int_true): New function.
7219         * target.h (struct gcc_target): Add can_eliminate field.
7220         * target-def.h (TARGET_CAN_ELIMINATE): Define.
7221         (TARGET_INITIALIZER): Use TARGET_CAN_ELIMINATE.
7222         * ira.c (setup_eliminable_regset): Use can_eliminate target hook.
7223         * reload1.c (update_eliminables, init_elim_table): (Ditto.).
7224         (elim_table): Revise comment.
7225         * system.h (CAN_ELIMINATE): Poison.
7226         * defaults.h (CAN_ELIMINATE): Remove.
7227         * doc/tm.texi (CAN_ELIMINATE): Revise documentation.
7228
7229         * config/alpha/vms.h (CAN_ELIMINATE): Remove macro.
7230         * config/alpha/alpha.c (TARGET_CAN_ELIMINATE) [TARGET_ABI_OPEN_VMS]:
7231         Define macro.
7232         (alpha_vms_can_eliminate): Declare as static, change return type to
7233         bool.
7234         * config/alpha/alpha-protos.h (alpha_vms_can_eliminate): Remove.
7235
7236         * config/arm/arm.h (CAN_ELIMINATE): Remove macro.
7237         * config/arm/arm.c (TARGET_CAN_ELIMINATE): Define macro.
7238         (arm_can_eliminate): New function.
7239
7240         * config/avr/avr.h (CAN_ELIMINATE): Remove macro.
7241         * config/avr/avr.c (TARGET_CAN_ELIMINATE): Define macro.
7242         (avr_can_eliminate): Declare as static.
7243         * config/avr/avr-protos.h (avr_can_eliminate): Remove.
7244
7245         * config/bfin/bfin.h (CAN_ELIMINATE): Remove macro.
7246         * config/bfin/bfin.c (TARGET_CAN_ELIMINATE): Define macro.
7247         (bfin_can_eliminate): New function.
7248
7249         * config/crx/crx.h (CAN_ELIMINATE): Remove macro.
7250         * config/crx/crx.c (TARGET_CAN_ELIMINATE): Define macro.
7251         (crx_can_eliminate): New function.
7252
7253         * config/fr30/fr30.h (CAN_ELIMINATE): Remove macro.
7254         * config/fr30/fr30.c (TARGET_CAN_ELIMINATE): Define macro.
7255         (fr30_can_eliminate): New function.
7256
7257         * config/frv/frv.h (CAN_ELIMINATE): Remove macro.
7258         * config/frv/frv.c (TARGET_CAN_ELIMINATE): Define macro.
7259         (frv_can_eliminate): New function.
7260
7261         * config/h8300/h8300.h (CAN_ELIMINATE): Remove macro.
7262         * config/h8300/h8300.c (TARGET_CAN_ELIMINATE): Define macro.
7263         (h8300_can_eliminate): New function.
7264
7265         * config/i386/i386.h (CAN_ELIMINATE): Remove macro.
7266         * config/i386/i386.c (TARGET_CAN_ELIMINATE): Define macro.
7267         (i386_can_eliminate): Declare as static, change return type to bool.
7268         * config/i386/i386-protos.h (i386_can_eliminate): Remove.
7269
7270         * config/ia64/ia64.h (CAN_ELIMINATE): Remove macro.
7271         * config/ia64/ia64.c (TARGET_CAN_ELIMINATE): Define macro.
7272         (ia64_can_eliminate): New function.
7273
7274         * config/iq2000/iq2000.h (CAN_ELIMINATE): Remove macro.
7275         * config/iq2000/iq2000.c (TARGET_CAN_ELIMINATE): Define macro.
7276         (iq2000_can_eliminate): New function.
7277
7278         * config/m32r/m32r.h (CAN_ELIMINATE): Remove macro.
7279         * config/m32r/m32r.c (TARGET_CAN_ELIMINATE): Define macro.
7280         (m32r_can_eliminate): New function.
7281
7282         * config/m68hc11/m68hc11.h (CAN_ELIMINATE): Remove macro.
7283         * config/m68hc11/m68hc11.c (TARGET_CAN_ELIMINATE): Define macro.
7284         (m68hc11_can_eliminate): New function.
7285
7286         * config/m68k/m68k.h (CAN_ELIMINATE): Remove macro.
7287         * config/m68k/m68k.c (TARGET_CAN_ELIMINATE): Define macro.
7288         (m68k_can_eliminate): New function.
7289
7290         * config/mep/mep.h (CAN_ELIMINATE): Remove macro.
7291         * config/mep/mep.c (TARGET_CAN_ELIMINATE): Define macro.
7292         (mep_can_eliminate): New function.
7293
7294         * config/mips/mips.h (CAN_ELIMINATE): Remove macro.
7295         * config/mips/mips.c (TARGET_CAN_ELIMINATE): Define macro.
7296         (mips_can_eliminate): New function.
7297
7298         * config/rs6000/rs6000.h (CAN_ELIMINATE): Remove macro.
7299         * config/rs6000/rs6000.c (TARGET_CAN_ELIMINATE): Define macro.
7300         (rs6000_can_eliminate): New function.
7301
7302         * config/s390/s390.h (CAN_ELIMINATE): Remove macro.
7303         * config/s390/s390.c (TARGET_CAN_ELIMINATE): Define macro.
7304         (s390_can_eliminate): Declare as static.
7305         * config/s390/s390-protos.h (sparc_can_eliminate): Remove.
7306
7307         * config/score/score.h (CAN_ELIMINATE): Remove macro.
7308         * config/score/score.c (TARGET_CAN_ELIMINATE): Define macro.
7309         (score_can_eliminate): New function.
7310
7311         * config/sparc/sparc.h (CAN_ELIMINATE): Remove macro.
7312         * config/sparc/sparc.c (TARGET_CAN_ELIMINATE): Define macro.
7313         (sparc_can_eliminate): Declare as static.
7314         * config/sparc/sparc-protos.h (sparc_can_eliminate): Remove.
7315
7316         * config/stormy16/stormy16.h (CAN_ELIMINATE): Remove macro.
7317         * config/stormy16/stormy16.c (TARGET_CAN_ELIMINATE): Define macro.
7318         (xstormy16_can_eliminate): New function.
7319
7320         * config/v850/v850.h (CAN_ELIMINATE): Remove macro.
7321         * config/v850/v850.c (TARGET_CAN_ELIMINATE): Define macro.
7322         (v850_can_eliminate): New function.
7323
7324 2009-08-25  Uros Bizjak  <ubizjak@gmail.com>
7325
7326         * config/alpha/alpha.md (*cmpdf_ieee_ext[123]): Remove.
7327         (*cmpdf_internal): Enable for all ALPHA_FPTM levels.
7328         (*movdfcc_ext[1234]): Disable for IEEE mode.
7329
7330 2009-08-25  Eric Botcazou  <ebotcazou@adacore.com>
7331
7332         * gimplify.c (prepare_gimple_addressable): New static function.
7333         (gimplify_modify_expr_to_memcpy): Invoke it on the RHS before marking
7334         it addressable.
7335         (gimplify_addr_expr): Invoke it similarly on the operand instead of
7336         manually fiddling with it.
7337
7338 2009-08-25  Michael Matz  <matz@suse.de>
7339
7340         * expr.h (jumpifnot_1, jumpif_1, do_jump_1): Declare.
7341         * dojump.c (do_jump_by_parts_greater): Take two operands instead of
7342         full expression.
7343         (do_jump_by_parts_equality, do_compare_and_jump): Ditto.
7344         (jumpifnot_1, jumpif_1): New wrappers for do_jump_1.
7345         (do_jump): Split out code for simple binary comparisons into ...
7346         (do_jump_1): ... this, taking the individual operands and code.
7347         Change callers to helper function above accordingly.
7348         * expr.c (expand_expr_real_1): Use jumpifnot_1 for simple binary
7349         comparisons.
7350
7351 2009-08-25  Michael Matz  <matz@suse.de>
7352
7353         * expr.h (struct separate_ops, sepops): New type for passing
7354         around an exploded simple expression.
7355         * optabs.c (expand_widen_pattern_expr, expand_vec_shift_expr):
7356         Use this structure instead of expression tree.
7357         (get_vcond_icode, expand_vec_cond_expr_p): Don't take whole
7358         expression, only its type.
7359         (expand_vec_cond_expr): Take type and individual operands instead
7360         of full expression.
7361         * optabs.h (expand_widen_pattern_expr, expand_vec_cond_expr,
7362         expand_vec_shift_expr): Change prototype accordingly.
7363         * tree-vect-stmts.c (vectorizable_condition): Change call of
7364         expand_vec_cond_expr_p to pass only type.
7365         * expr.c (do_store_flags): Change prototype and implementation
7366         to take an exploded expression.
7367         (expand_expr_real_1): New local ops initialized with details
7368         of the full expression.  Use it instead of full
7369         expression in calls to do_store_flags, expand_vec_cond_expr,
7370         expand_widen_pattern_expr and expand_vec_shift_expr.
7371
7372 2009-08-25  Michael Matz  <matz@suse.de>
7373
7374         * expr.c (expand_expr_real_1): New local treeop0, treeop1,
7375         treeop2 initialized with first three operands of the full expression.
7376         Substitute all TREE_OPERAND (exp, [012]) calls with them.
7377
7378 2009-08-25  Kai Tietz  <kai.tietz@onevision.com>
7379
7380         * gcc/gthr-win32.h (__UNUSED_PARAM): Define, if not already present.
7381         (__gthread_objc_condition_allocate): Mark arguments as unused.
7382         (__gthread_objc_condition_deallocate): Likewise.
7383         (__gthread_objc_condition_wait): Likewise.
7384         (__gthread_objc_condition_broadcast): Likewise.
7385         (__gthread_objc_condition_signal): Likewise.
7386         (__gthread_objc_thread_detach): Cast via INT_PTR to pointer.
7387         (__gthread_objc_thread_id): Likewise.
7388
7389 2009-08-25  Janus Weil  <janus@gcc.gnu.org>
7390
7391         PR middle-end/41149
7392         * tree-pretty-print.c (print_call_name): Print the correct call name
7393         for procedure pointer components.
7394
7395 2009-08-24  Steve Ellcey  <sje@cup.hp.com>
7396
7397         * config/ia64/ia64.c (ia64_promote_function_mode): Call
7398         default_promote_function_mode when not VMS.
7399
7400 2009-08-24  Olivier Hainque  <hainque@adacore.com>
7401
7402         * convert.c (convert_to_integer): Don't assume an input pointer is
7403         POINTER_SIZE wide.  Fetch from the type instead.
7404
7405 2009-08-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7406
7407         * configure.ac (AC_PREREQ): Bump to 2.64.
7408
7409 2009-08-24  Rafael Avila de Espindola  <espindola@google.com>
7410
7411         * gcc.c (standard_exec_prefix_1,standard_exec_prefix_2): Remove.
7412         (process_command): Don't search standard_exec_prefix_1 and
7413         standard_exec_prefix_2.
7414
7415 2009-08-24  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
7416
7417         * config/arm/arm.c (output_return_instruction): Handle for
7418         unified syntax.
7419
7420 2009-08-24  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
7421
7422         * config/arm/arm.c (arm_select_cc_mode): Handle subreg.
7423
7424 2009-08-24  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
7425
7426         * config/arm/vfp.md (*arm_movdi_vfp): Mark as predicable.
7427         (*arm_movdf_vfp): Likewise.
7428
7429 2009-08-24  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
7430
7431         * config/arm/neon.md (vashl<mode>3): Rename from ashl<mode>3.
7432         (vashr<mode>3): Rename from ashr<mode>3.
7433         (vlshr<mode>3): Rename from lshr<mode>3.
7434
7435 2009-08-24  Kai Tietz  <kai.tietz@onevision.com>
7436
7437         PR/40786
7438         * c-format.c (format_wanted_type): Add new member scalar_identity_flag.
7439         (check_format_info_main): Use scalar_identify_flag.
7440         (check_format_types): Check for scalar size identity if
7441         scalar_identify_flag is set.
7442         (printf_length_specs): Extend by new field.
7443         (asm_fprintf_length_specs): Likewise.
7444         (gcc_diag_length_specs): Likewise.
7445         (scanf_length_specs): Likewise.
7446         (strfmon_length_specs): Likewise.
7447         (gcc_gfc_length_specs): Likewise.
7448         * config/i386/msformat-c.c (ms_printf_length_specs): Likewise.
7449         (ms_printf_flag_specs): Likewise.
7450         * c-format.h (format_length_info): Add new member scalar_identity_flag.
7451
7452 2009-08-23  Uros Bizjak  <ubizjak@gmail.com>
7453
7454         PR target/40718
7455         * config/i386/i386.c (*call_pop_1): Disable for sibling calls.
7456         (*call_value_pop_1): Ditto.
7457         (*sibcall_pop_1): New insn pattern.
7458         (*sibcall_value_pop_1): Ditto.
7459
7460 2009-08-23  Alan Modra  <amodra@bigpond.net.au>
7461
7462         PR target/41081
7463         * config/rs6000/rs6000.md (rotlsi3_64, ashlsi3_64, lshrsi3_64,
7464         ashrsi3_64): New.
7465
7466 2009-08-23  Alan Modra  <amodra@bigpond.net.au>
7467
7468         PR target/41081
7469         * fwprop.c (try_fwprop_subst): Allow multiple sets.
7470         (get_reg_use_in): New function.
7471         (forward_propagate_subreg): Propagate through subreg of zero_extend
7472         or sign_extend.
7473
7474 2009-08-22  Kaz Kojima  <kkojima@gcc.gnu.org>
7475
7476         * config/sh/t-sh (TARGET_LIBGCC2_CFLAGS): Define.
7477         * config/sh/t-netbsd (TARGET_LIBGCC2_CFLAGS): Add -mieee.
7478
7479 2009-08-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7480
7481         * configure.ac: Remove --with-datarootdir, --with-docdir,
7482         --with-htmldir switches.  No need to call AC_SUBST for
7483         datarootdir, docdir, htmldir any more.
7484         * configure: Regenerate.
7485         * doc/install.texi (Configuration): Document --datarootdir,
7486         --docdir, --htmldir, --pdfdir; update documentation for
7487         --infodir, --mandir.
7488         (Prerequisites): Bump Autoconf version to 2.64, Automake to 1.11,
7489         M4 to 1.4.6.
7490
7491         * aclocal.m4: Regenerate.
7492         * config.in: Regenerate.
7493         * configure: Regenerate.
7494
7495 2009-08-21  Douglas B Rupp  <rupp@gnat.com>
7496             Olivier Hainque  <hainque@adacore.com>
7497
7498         * config/ia64/ia64.c: Include libfuncs.h.
7499         (TARGET_PROMOTE_FUNCITON_MODE): Define target macro.
7500         (ia64_expand_call): Use reg 25 on VMS.
7501         (ia64_initialize_trampoline): Fix for VMS ABI.
7502         (ia64_function_arg_offset): Always returns 0 when TARGET_ABI_OPEN_VMS.
7503         (ia64_function_arg): Initialize reg 25 on VMS.
7504         Fix OpenVMS ABI issues for varargs.
7505         For OpenVMS, emit the Argument Information register set in the
7506         incoming/sibcall case as well.
7507         (ia64_arg_type): New function.
7508         (ia64_function_arg_advance): Keep track of cum->words.
7509         Fix OpenVMS ABI issues for varargs.
7510         (ia64_function_value): On VMS, promote mode of non-aggregate types.
7511         (ia64_override_options): Set flag_no_common on VMS.
7512         (ia64_init_builtins): Disable FWRITE builtin.
7513         (ia64_asm_output_external): Call DO_CRTL_NAMES.
7514         (ia64_vms_init_libfuncs): Add decc$ routines.
7515         (ia64_vms_valid_pointer_mode): New function.
7516         (ia64_struct_value_rtx): Allways NULL_RTX on VMS.
7517         (ia64_promote_function_mode): New function
7518         * config/ia64/ia64.h (TARGET_ABI_OPEN_VMS): Define as 0 for default.
7519         (LONG_DOUBLE_TYPE_SIZE): Force to 64 on VMS.
7520         (LIBCGC2_LONG_DOUBLE_TYPE_SIZE): Likewise.
7521         (INIT_CUMULATIVE_ARGS): Add atypes for VMS.
7522         (INIT_CUMULATIVE_INCOMING_ARGS): Likewise.
7523         (ASM_OUTPUT_DEF): Use ISDIGIT instead of isdigit.
7524         Suppress trailing '#' if VALUE is numeric.
7525         * config/ia64/vms.h (PROMOTE_FUNCTION_MODE): Remove, code moved to
7526         ia64_promote_function_mode.
7527         (TARGET_VALID_POINTER_MODE): Define.
7528
7529 2009-08-21  Michael Meissner  <meissner@linux.vnet.ibm.com>
7530
7531         PR target/40671
7532         * config/rs6000/rs6000.c (rs6000_override_options): Use
7533         TARGET_64BIT instead of TARGET_POWERPC64 to set the size of pointers.
7534
7535         PR target/41145
7536         * config/rs6000/rs6000.c (rs6000_handle_altivec_attribute): Fix
7537         reporting of vector + decimal/boolean/complex error.
7538
7539 2009-08-21  Jakub Jelinek  <jakub@redhat.com>
7540
7541         * config/rs6000/rs6000.c (rs6000_init_builtins): Fix type of
7542         __vector double TYPE_DECL.
7543
7544 2009-08-21  Richard Earnshaw  <rearnsha@arm.com>
7545
7546         * arm.h (MACHMODE): New define.  Include insn-modes.h if available.
7547         (CUMULATIVE_ARGS): Use MACHMODE for declaration of aapcs_vfp_mode.
7548         * arm.c (aapcs_vfp_is_call_or_return_candidate): Change base_mode
7549         to pointer to enum machine_mode.  Update all callers as needed.
7550
7551 2009-08-21 Uros Bizjak <ubizjak@gmail.com>
7552
7553         * config/alpha/alpha.md (exception_receiver): Emit alternative
7554         GP load sequence if flag_reorder_blocks_and_partition is set.
7555         (*exception_receiver_2): Also enable when
7556         flag_reorder_blocks_and_partition is set.
7557
7558 2009-08-20  Matt Rice  <ratmice@gmail.com>
7559             Diego Novillo  <dnovillo@google.com>
7560
7561         * Makefile.in (PLUGIN_HEADERS): Include incpath.h and
7562         tree-ssa-sccvn.h.
7563
7564 2009-08-20  Richard Guenther  <rguenther@suse.de>
7565
7566         * c-objc-common.h (LANG_HOOKS_DUP_LANG_SPECIFIC_DECL): Do not define.
7567         * c-tree.h (c_dup_lang_specific_decl): Remove.
7568         (struct lang_decl, struct lang_type): Move definitions ...
7569         * c-lang.h: ... here.  New file.
7570         * c-decl.c: Include c-lang.h.
7571         (c_dup_lang_specific_decl): Remove.
7572         * c-typeck.c: Include c-lang.h.
7573         * Makefile.in (c-decl.o): Add c-lang.h dependency.
7574         (c-typeck.o): Likewise.
7575         * c-config-lang.in (gtfiles): Add c-lang.h.
7576         * gengtype.c (get_output_file_with_visibility): Handle c-lang.h
7577         like c-tree.h.
7578
7579 2009-08-20  Uros Bizjak  <ubizjak@gmail.com>
7580
7581         * config/alpha/alpha.c (alpha_end_function): Do not clear
7582         crtl->emit structure and free insn locators if cfun->is_thunk is true,
7583         this is now handled in generic code.
7584
7585 2009-08-20  Andreas Krebbel  <krebbel1@de.ibm.com>
7586
7587         * config/s390/s390.c (Z10_PREDICT_DISTANCE): New macro.
7588         (s390_z10_fix_long_loop_prediction): New function.
7589         (s390_z10_optimize_cmp): INSN walk moved to callee - s390_reorg.
7590         (s390_reorg): Walk over the INSNs and invoke
7591         s390_z10_fix_long_loop_prediction and s390_z10_optimize_cmp.
7592
7593 2009-08-20  Andreas Krebbel  <krebbel1@de.ibm.com>
7594
7595         * config/s390/s390.md ("*brx_stage1_<GPR:mode>", "*brxg_64bit",
7596         "*brx_64bit", "*brx_31bit"): New patterns.
7597         * config/s390/s390.c ('E'): New output modifier.
7598
7599 2009-08-20  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
7600             Richard Earnshaw  <richard.earnshaw@arm.com>
7601
7602         * config/arm/arm.c (arm_emit_movpair): Handle CONST_INT.
7603         * config/arm/arm.md (*arm_movtas_ze): New pattern for movt.
7604
7605 2009-08-19  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
7606
7607         * pa.md (reload_inhi, reload_outhi, reload_inqi, reload_outqi): New
7608         patterns.
7609         * pa.c (emit_move_sequence): Check if address of operand1 is valid
7610         for mode mode of operand0 when doing secondary reload for SAR.
7611
7612 2009-08-19  Jakub Jelinek  <jakub@redhat.com>
7613
7614         PR middle-end/41123
7615         * expr.c (expand_expr_real_1) <normal_inner_ref>: Handle all kinds
7616         of CONCAT, not just bitpos 0 bitsize size of the whole CONCAT.
7617
7618 2009-08-19  Jason Merrill  <jason@redhat.com>
7619
7620         * doc/invoke.texi (C++ Dialect Options): Note change of minimum
7621         supported template depth in C++0x.
7622
7623 2009-08-19  Jakub Jelinek  <jakub@redhat.com>
7624
7625         * config/rs6000/rs6000.c (rs6000_output_mi_thunk): Don't call
7626         free_after_compilation.
7627         * config/score/score7.c (score7_output_mi_thunk): Likewise.
7628         * config/score/score3.c (score3_output_mi_thunk): Likewise.
7629         * config/ia64/ia64.c (ia64_output_mi_thunk): Likewise.
7630         * config/mips/mips.c (mips_output_mi_thunk): Likewise.
7631         * config/sh/sh.c (sh_output_mi_thunk): Likewise.
7632         * config/m68k/m68k.c (m68k_output_mi_thunk): Likewise.
7633         * config/sparc/sparc.c (sparc_output_mi_thunk): Likewise.
7634
7635 2009-08-19  Ian Lance Taylor  <iant@google.com>
7636
7637         * doc/md.texi (Insn Canonicalizations): Correct canonicalization
7638         of (plus (mult (neg B) C) A).
7639
7640 2009-08-18  Michael Matz  <matz@suse.de>
7641
7642         * omp-low.c (optimize_omp_library_calls): Use types_compatible_p
7643         instead of comparing TYPE_MAIN_VARIANT for equality.
7644         * tree-vect-patterns.c (vect_recog_dot_prod_pattern,
7645         vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern): Ditto.
7646         * tree-vect-loop.c (vect_is_simple_reduction): Ditto.
7647         * gimplify.c (goa_lhs_expr_p): Ditto and use
7648         STRIP_USELESS_TYPE_CONVERSION.
7649
7650 2009-08-18  Michael Matz  <matz@suse.de>
7651
7652         * tree-ssa-structalias.c (create_variable_info_for): Also mark
7653         first field in a struct.
7654         (intra_create_variable_infos): Don't deal with flag_argument_noalias.
7655
7656 2009-08-18  Uros Bizjak  <ubizjak@gmail.com>
7657
7658         * config/alpha/alpha.c (alpha_output_mi_thunk_osf): Allocate insn
7659         locators before emit_insn is called.  Remove assert that
7660         cfun->is_thunk.
7661         (alpha_end_function): Clear crtl->emit structure and free insn
7662         locators if cfun->is_thunk is true.
7663
7664 2009-08-18  Jason Merrill  <jason@redhat.com>
7665
7666         * config/elfos.h (ASM_DECLARE_OBJECT_NAME): Use gnu_unique_object
7667         type if available.
7668         * configure.ac: Test for it.
7669         * configure, config.in: Regenerate.
7670         * doc/install.texi: Document --enable-gnu-unique-object.
7671
7672 2009-08-18  Richard Guenther  <rguenther@suse.de>
7673
7674         PR middle-end/41094
7675         * builtins.c (fold_builtin_pow): Fold pow(pow(x,y),z) to
7676         pow(x,y*z) only if x is nonnegative.
7677
7678 2009-08-18  Jakub Jelinek  <jakub@redhat.com>
7679
7680         * bb-reorder.c (fix_up_fall_thru_edges): Only call invert_jump
7681         on jumps.
7682
7683         PR target/40971
7684         * config/rs6000/rs6000.c (rs6000_legitimize_address): For
7685         [DT][FDI]mode ensure the offset isn't 4/8/12 bytes below 0x8000.
7686
7687 2009-08-17  DJ Delorie  <dj@redhat.com>
7688
7689         * config/m32c/m32c.md (UNS_FSETB, UNS_FREIT): New.
7690         * config/m32c/prologue.md (epilogue_freit): New.
7691         (fset_b): New.
7692         * config/m32c/m32c.c (m32c_function_needs_enter): Add prototype.
7693         (bank_switch_p): Likewise.
7694         (fast_interrupt_p): Likewise.
7695         (interrupt_p): Likewise.
7696         (m32c_conditional_register_usage): Round memregs size up.
7697         (need_to_save): We only need to save $a0 when we use ENTER.
7698         (interrupt_p): Check for fast_interrupt too.
7699         (bank_switch_p): New.
7700         (fast_interrupt_p): New.
7701         (m32c_attribute_table): Add bank_switch and fast_interrupt.
7702         (m32c_emit_prolog): Support bank switching and fast interrupts.
7703         * doc/extend.texi (Function Attributes): Add bank_switch and
7704         fast_interrupt.
7705
7706 2009-08-17  Douglas B Rupp  <rupp@gnat.com>
7707
7708         * config/alpha/alpha.c (vms_valid_pointer_mode): New function.
7709         * config/alpha/vms.h (TARGET_VALID_POINTER_MODE): Define.
7710
7711 2009-08-16  Douglas B Rupp  <rupp@gnat.com>
7712
7713         * doc/invoke.texi (Target options): Add new option list for IA-64/VMS.
7714         (menu): Add IA-64/VMS Options.
7715         (IA-64/VMS Options): Likewise.
7716
7717 2009-08-16  Richard Sandiford  <rdsandiford@googlemail.com>
7718
7719         PR target/38599
7720         * config/mips/mips.md (*lwxs): Use :P for pointer values.
7721
7722 2009-08-16  Richard Sandiford  <rdsandiford@googlemail.com>
7723
7724         * config/mips/mips-protos.h (mips_push_asm_switch): New function.
7725         (mips_pop_asm_switch): Likewise.
7726         * config/mips/mips.c (set_noreorder, set_nomacro, set_noat): Replace
7727         with...
7728         (mips_noreorder, mips_nomacro, mips_noat): ...these new variables.
7729         (mips_push_asm_switch_1, mips_pop_asm_switch_1): New functions.
7730         (mips_push_asm_switch, mips_pop_asm_switch): Likewise.
7731         (mips_print_operand_punctuation): Use them.  Check mips_noreorder
7732         instead of set_noreorder.
7733         (mips_output_function_prologue): Use the new functions.
7734         (mips_output_function_epilogue): Likewise.
7735         (mips_need_noat_wrapper_p): New function, split out from...
7736         (mips_final_prescan_insn, mips_final_postscan_insn): ...here.
7737         Use mips_push_asm_switch and mips_pop_asm_switch.
7738         * config/mips/mips.h (FUNCTION_PROFILER): Use mips_push_asm_switch
7739         and mips_pop_asm_switch.
7740         (ASM_OUTPUT_REG_POP): Likewise.
7741         (DBR_OUTPUT_SEQEND): Remove boilerplate comment.
7742         Use mips_pop_asm_switch.
7743         (mips_asm_switch): New structure.
7744         (set_noreorder, set_nomacro): Replace with...
7745         (mips_noreorder, mips_nomacro, mips_noat): ...these new variables.
7746         * config/mips/mips.md (fix_truncdfsi2_macro): Use mips_nomacro
7747         instead of set_nomacro.
7748         (fix_truncsfsi2_macro): Likewise.
7749         (cprestore): Likewise.
7750         (hazard): Use mips_noreorder instead of set_noreorder.
7751         * config/mips/sdemtk.h (FUNCTION_PROFILER): As for mips.h.
7752
7753 2009-08-16  Uros Bizjak  <ubizjak@gmail.com>
7754
7755         * config/alpha/alpha.c (alpha_end_function): Handle NULL_RTX returned
7756         from prev_active_insn.
7757
7758 2009-08-16  Anatoly Sokolov  <aesok@post.ru>
7759
7760         * config/avr/avr.h (AVR_HAVE_8BIT_SP): New macros.
7761         * config/avr/avr.c (avr_override_options): Initialize
7762         avr_current_arch variable.
7763         (avr_cpu_cpp_builtins): Define __AVR_HAVE_8BIT_SP__ or
7764         __AVR_HAVE_16BIT_SP__ according to the device type.
7765         (expand_prologue, output_movhi): Use AVR_HAVE_8BIT_SP instead of
7766         TARGET_TINY_STACK.
7767         (expand_epilogue): Use correct QI mode frame pointer for tiny stack.
7768         Use AVR_HAVE_8BIT_SP instead of TARGET_TINY_STACK.
7769
7770 2009-08-16  Dodji Seketeli  <dodji@redhat.com>
7771
7772         PR debug/37801
7773         * gcc/dwarf2out.c (gen_inlined_subroutine_die): Concentrate on
7774         generating inlined subroutine die only. We shouldn't be
7775         called for anything else.
7776         (gen_block_die): Don't generate inline subroutine debug info for
7777         abstract blocks.
7778
7779 2009-08-15  Sebastian Pop  <sebastian.pop@amd.com>
7780
7781         * graphite-poly.c (print_pbb): Print PBB index.
7782
7783 2009-08-15  Sebastian Pop  <sebastian.pop@amd.com>
7784
7785         PR middle-end/40981
7786         * graphite-interchange.c (ppl_max_for_le): Moved...
7787         * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
7788         * graphite-ppl.c (ppl_max_for_le): ... here.  Correct the use of
7789         ppl_Pointset_Powerset_C_Polyhedron_maximize.
7790         * graphite-ppl.h (ppl_max_for_le): Declared.
7791
7792 2009-08-14  Olatunji Ruwase <tjruwase@google.com>
7793
7794         * doc/extend.texi (Symbol-Renaming Pragmas): redefine_extname is
7795         supported on all platforms.
7796         * target.h (struct gcc_target): Remove handle_pragma_redefine_extname.
7797         * c-cppbuiltin.c: Remove use of targetm.handle_pragma_redefine_extname.
7798         * c-pragma.c: Likewise.
7799         * target-def.h (TARGET_INITIALIZER): Remove
7800         TARGET_HANDLE_PRAGMA_REDEFINE_EXTNAME.
7801         * config/sol2.h: Remove use of TARGET_HANDLE_PRAGMA_REDEFINE_EXTNAME.
7802
7803 2009-08-14  Douglas B Rupp  <rupp@gnat.com>
7804
7805         * config/ia64/fde-vms.c: New file.
7806         * config/ia64/fde-glibc.c (_Unwind_FindTableEntry): Add dummy arg.
7807         * config/ia64/unwind-ia64.c (UNW_ accessors): Move to unwind-ia64.h
7808         (MD_UNW_COMPATIBLE_PERSONALITY_P): Provide default.
7809         (uw_frame_state_for): Only register a personality routine if it is
7810         known to be compatible with our expectations.
7811         (_Unwind_FindEnclosingFunction, uw_frame_state_for):
7812         Declare unw_table_entry stack variable and
7813         mod all calls to _Unwind_FindTableEntry to add arg.
7814         * config/ia64/unwind-ia64.h (UNW_ accessors): Move here.
7815         (_Unwind_FindTableEntry): Add arg to prototype.
7816
7817 2009-08-14  Eric Botcazou  <ebotcazou@adacore.com>
7818
7819         * config/ia64/unwind-ia64.c (struct _Unwind_Context): Add new
7820         field 'signal_pfs_loc'.
7821         (uw_frame_state_for): Remove duplicate code dealing with leaf
7822         procedures without unwind info.
7823         If in the frame after unwinding through a signal handler, restore
7824         the AR.PFS register instead of the CFM if AR.PFS has not been saved.
7825         * config/ia64/linux-unwind.h (ia64_fallback_frame_state): Do not set
7826         'pfs_loc' to the AR.PFS location in the signal context; instead
7827         set 'signal_pfs_loc'.
7828         Manually generate the unwind info for the AR.PFS register.
7829         (ABI_MARKER_OLD_LINUX_SIGTRAMP, ABI_MARKER_OLD_LINUX_INTERRUPT,
7830         ABI_MARKER_LINUX_SIGTRAMP, ABI_MARKER_LINUX_INTERRUPT): Define.
7831         (ia64_handle_unwabi): Test 'fs->unwabi' against them.
7832         Do not set 'pfs_loc' to the AR.PFS location in the signal context;
7833         instead set 'signal_pfs_loc'.
7834         Remove code preventing the AR.PFS register from being restored
7835         from the signal context.
7836
7837 2009-08-14  Douglas B Rupp  <rupp@gnat.com>
7838             Tristan Gingold  <gingold@adacore.com>
7839
7840         * config.gcc (ia64-hp-*vms*): Insert ia64/t-ia64 in tmake_file.
7841         * config/ia64/t-vms: New file.
7842         * config/ia64/vms64.h: New file.
7843         * config/ia64/vms.h: New file.
7844         * config/ia64/vms-crtinit.asm: New file.
7845         * config/ia64/vms_symvec_libgcc_s.opt: New file.
7846         * config/ia64/vms-unwind.h: New file.
7847
7848 2009-08-14  Uros Bizjak  <ubizjak@gmail.com>
7849
7850         * config/alpha/alpha.c (alpha_emit_conditional_move): Handle
7851         TFmode compares.
7852
7853 2009-08-14  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
7854
7855         PR middle-end/30789
7856         * builtins.c (do_mpc_arg2): Make extern, define for any MPC version.
7857         Move declaration...
7858         * real.h (do_mpc_arg2): ... here.
7859         * fold-const.c (const_binop): Use MPC for complex MULT_EXPR
7860         and RDIV_EXPR.
7861
7862 2009-08-14  Rafael Avila de Espindola  <espindola@google.com>
7863
7864         * final.c (add_debug_prefix_map): Don't use GC memory for
7865         old_prefix and new_prefix.
7866
7867 2009-08-14  Richard Guenther  <rguenther@suse.de>
7868
7869         * ipa-prop.c (compute_complex_pass_through): If we cannot
7870         compute a non-varying offset for IPA_JF_ANCESTOR punt.
7871
7872 2009-08-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
7873
7874         * c-lex.c (c_lex_with_flags): Increase size of local variable
7875         to avoid memory clobber.
7876
7877 2009-08-14  Paolo Bonzini  <bonzini@gnu.org>
7878
7879         PR target/40934
7880         * config/i386/i386.c (ix86_fp_comparison_strategy):
7881         Only enable/disable sahf at function granularity.
7882
7883 2009-08-14  Hans-Peter Nilsson  <hp@axis.com>
7884
7885         PR rtl-optimization/41064
7886         * reload1.c (reload_as_needed): Don't call extract_insn
7887         for known invalid replacements after calling
7888         validate_replace_rtx_group and verify_changes.
7889
7890 2009-08-14  Uros Bizjak  <ubizjak@gmail.com>
7891
7892         PR target/41019
7893         * config/i386/sse.md (SSEMODE124C8): New mode iterator.
7894         (vcond<SSEMODEF2P:mode>): Assert that operation is supported by
7895         ix86_expand_fp_vcond.
7896         (vcond<SSEMODE124C8:mode>): Use SSEMODE124C8 instead of SSEMODE124.
7897         Assert that operation is supported by ix86_expand_int_vcond.
7898         (vcondu<SSEMODE124C8:mode>): Ditto.
7899
7900 2009-08-13  DJ Delorie  <dj@redhat.com>
7901
7902         * config/i386/djgpp-stdint.h: New.
7903         * config.gcc (djgpp): Use it.
7904
7905 2009-08-13  Kaz Kojima  <kkojima@gcc.gnu.org>
7906
7907         * config/sh/sh.c (sh_override_options): When flag_exceptions or
7908         flag_unwind_tables is on, turn flag_reorder_blocks_and_partition off.
7909
7910 2009-08-13  Ghassan Shobaki  <ghassan.shobaki@amd.com>
7911
7912         * tree-ssa-loop-prefetch.c
7913         (prune_ref_by_group_reuse): Enhance probabilistic analysis
7914         for long-stride pruning.
7915         (compute_miss_rate): New function to compute the probability
7916         that two memory references access different cache lines.
7917
7918 2009-08-13  Dave Korn  <dave.korn.cygwin@gmail.com>
7919
7920         * gcc/config/i386/cygwin.h (LINK_SPEC): Add --enable-auto-image-base.
7921
7922 2009-08-13  Richard Guenther  <rguenther@suse.de>
7923
7924         PR middle-end/41047
7925         * tree-ssa-ccp.c (ccp_fold): When folding pointer additions
7926         use the constant pointer type.
7927         * gimplify.c (canonicalize_addr_expr): Canonicalize independent
7928         of CV qualifiers on the target pointer type.
7929         * tree-ssa.c (useless_type_conversion_p): Move incomplete pointer
7930         conversion check before restrict check.
7931
7932 2009-08-12  Kaz Kojima  <kkojima@gcc.gnu.org>
7933
7934         PR target/41029
7935         * config/sh/sh.md (reload_outdf__RnFRm+4): Fix thinko.
7936
7937 2009-08-12  Kaz Kojima  <kkojima@gcc.gnu.org>
7938
7939         * config/sh/sh.c (sh_promote_function_mode): Add ATTRIBUTE_UNUSED.
7940
7941 2009-08-12  Richard Guenther  <rguenther@suse.de>
7942
7943         PR tree-optimization/41011
7944         * ipa-cp.c (ipcp_lattice_from_jfunc): Deal with failing fold
7945         and reference constructing.
7946
7947 2009-08-12  Xinliang David Li  <davidxl@google.com>
7948
7949         PR tree-optimization/41012
7950         * tree-flow.h : New external interface.
7951         * gimple-low.c (check_call_arg): Change to public function.
7952         Remove argument mismatch check in lowering.
7953         * tree-inline.h (tree_can_inline_p): Interface change.
7954         * tree-inline.c (tree_can_inline_p): Fold argument mismatch check
7955         into this function.
7956         * ipa-inline.c (cgraph_decide_inlining_of_small_functions):
7957         Call change to tree_can_inline_p function.
7958         (cgraph_decide_inlining_incrementally): Ditto.
7959
7960 2009-08-12  Richard Sandiford  <rdsandiford@googlemail.com>
7961
7962         PR tree-optimization/41031
7963         * tree-outof-ssa.c (insert_value_copy_on_edge): Use promote_decl_mode
7964         on the partition variable rather than promote_mode on the source
7965         type.  Assert that the partition variable's type has the same
7966         mode as the source value's.
7967
7968 2009-08-12  Paolo Bonzini  <bonzini@gnu.org>
7969
7970         * doc/tm.texi (TARGET_PROMOTE_FUNCTION_MODE): Add documentation
7971         for for_return == 2.
7972         * function.c (assign_parm_setup_reg): Use for_return == 2, improve
7973         comments.
7974         * calls.c (expand_call): Fix typo.
7975         * explow.c (promote_decl_mode): Use for_return == 2 for RESULT_DECL
7976         and PARM_DECL.
7977         * stmt.c (expand_value_return): Use promote_function_mode to copy out
7978         of pseudo.
7979         * targhooks.c (default_promote_function_mode): Handle for_return == 2.
7980         * config/cris/cris.c (cris_promote_function_mode): Likewise.
7981         * config/mmix/mmix.c (mmix_promote_function_mode): Likewise.
7982         * config/pa/pa.c (pa_promote_function_mode): Likewise.
7983
7984 2009-08-12  Andrew Haley  <aph@redhat.com>
7985
7986         * config/arm/arm.c (arm_init_libfuncs): Add __sync_synchronize.
7987
7988 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
7989
7990         PR bootstrap/40103
7991         * graphite.c: Remove pragma GCC diagnostic warning "-Wc++-compat".
7992
7993 2009-08-12  Richard Guenther  <rguenther@suse.de>
7994
7995         * alias.c (get_alias_set): Honor TYPE_STRUCTURAL_EQUALITY_P.
7996         * gimplify.c (gimplify_modify_expr): Do not use
7997         lang_hooks.types_compatible_p.
7998         * tree-ssa.c (useless_type_conversion_p): For aggregates
7999         just return false if the canonical types differ.
8000
8001 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
8002
8003         PR middle-end/40980
8004         * sese.c (convert_for_phi_arg): New.
8005         (add_guard_exit_phis): Use convert_for_phi_arg.
8006
8007 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
8008
8009         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
8010         unknown subscript upper bounds.
8011
8012 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
8013             Pranav Garg  <pranav.garg2107@gmail.com>
8014
8015         * graphite-interchange.c (gather_access_strides): Removed.
8016         (ppl_max_for_le): New.
8017         (build_linearized_memory_access): New.
8018         (memory_stride_in_loop): New.
8019         (pbb_interchange_profitable_p): Reimplemented.
8020         * graphite-ppl.h (ppl_new_id_map): New.
8021         (ppl_interchange): New.
8022
8023 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
8024
8025         * graphite-interchange.c (compute_subscript): Removed.
8026         (compute_array_size_cstr): Removed.
8027         (compute_array_size_poly): Removed.
8028         (compute_array_size): Removed.
8029         (gather_access_strides_poly): Removed.
8030         (gather_access_strides): Empty.
8031
8032 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
8033
8034         * graphite-dependences.c (dependence_polyhedron_1): Replace
8035         pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
8036         (graphite_legal_transform_dr): Same.
8037         (graphite_carried_dependence_level_k): Same.
8038         * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
8039         Initialize PDR_NB_SUBSCRIPTS.
8040         (print_pdr_access_layout): Replace pdr_nb_subscripts with
8041         PDR_NB_SUBSCRIPTS.
8042         * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
8043         (PDR_NB_SUBSCRIPTS): New.
8044         (pdr_nb_subscripts): Removed.
8045         (pdr_dim): Simplified.
8046         * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
8047         with PDR_NB_SUBSCRIPTS.
8048
8049 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
8050
8051         * graphite-interchange.c (compute_array_size): Remove use of
8052         PDR_DATA_CONTAINER.
8053         * graphite-poly.c (new_poly_dr): Remove argument data_container.
8054         Do not initialize PDR_DATA_CONTAINER.
8055         (print_pdr): Do not print PDR_DATA_CONTAINER.
8056         * graphite-poly.h (struct poly_dr): Remove data_container field.
8057         (PDR_DATA_CONTAINER): Removed.
8058         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
8059         PDR_DATA_CONTAINER.
8060         (build_poly_dr): Same.
8061
8062 2009-08-12  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
8063             Sebastian Pop  <sebastian.pop@amd.com>
8064
8065         * graphite-dependences.c (graphite_legal_transform_dr): Work on a
8066         copy of the dependence polyhedron.  Free the temporary objects.
8067         (graphite_carried_dependence_level_k): Free unused objects before
8068         returning.
8069
8070 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
8071
8072         * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
8073         Early return without analyzing the data dependences if no
8074         transform has been done.  Call restore_scattering if the transform
8075         is not legal.
8076         (graphite-interchange.c): Same.
8077         * graphite-poly.c (print_scattering_function): Test for
8078         PBB_TRANSFORMED.
8079         (graphite_read_transforms): Initialize PBB_TRANSFORMED.
8080         (apply_poly_transforms): Do not gcc_assert that
8081         the transform is legal.
8082         (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED and PBB_ORIGINAL.
8083         Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
8084         PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
8085         (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
8086         * graphite-poly.h (struct poly_scattering): New.
8087         (struct poly_bb): Add original, transformed, and saved fields.
8088         Remove transformed_scattering, original_scattering,
8089         nb_local_variables and nb_scattering_transform fields.
8090         (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
8091         (poly_scattering_new): New.
8092         (poly_scattering_free): New.
8093         (poly_scattering_copy): New.
8094         (store_scattering_pbb): New.
8095         (store_scattering): New.
8096         (restore_scattering_pbb): New.
8097         (restore_scattering): New.
8098         * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
8099         Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
8100
8101 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
8102
8103         * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
8104         (print_scop): Same.
8105
8106 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
8107
8108         * Makefile.in (graphite.o): Depends on PREDICT_H.
8109         * graphite.c: Include predict.h.
8110         (graphite_finalize): Call tree_estimate_probability.
8111         * predict.c (predict_loops): Do not call scev_initialize and
8112         scev_finalize.
8113         (tree_estimate_probability_bb): New.
8114         (tree_estimate_probability): Do not initialize loops: move that
8115         code to the driver.  Call tree_estimate_probability_bb.
8116         (tree_estimate_probability_driver): New.
8117         (pass_profile): Use tree_estimate_probability_driver.
8118         * predict.h (tree_estimate_probability): Declared.
8119
8120 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
8121
8122         * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
8123         * graphite-dependences.c (graphite_legal_transform): Add time to
8124         TV_GRAPHITE_DATA_DEPS.
8125         (dependency_between_pbbs_p): Same.
8126         * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
8127
8128 2009-08-12  Andrey Belevantsev  <abel@ispras.ru>
8129
8130         PR rtl-optimization/41033
8131         * alias.c (nonoverlapping_component_refs_p): Punt when strict
8132         aliasing is disabled.
8133
8134 2009-08-11  Adam Nemet  <anemet@caviumnetworks.com>
8135
8136         * config/mips/predicates.md (qi_mask_operand, hi_mask_operand,
8137         si_mask_operand, and_load_operand, low_bitmask_operand,
8138         and_reg_operand, and_operand): New predicates.
8139         * config/mips/constraints.md (Yb, Yh, Yw, Yz): New constraints.
8140         * config/mips/mips.c (and_operands_ok): New function.
8141         * config/mips/mips-protos.h (and_operands_ok): Declare it.
8142         * config/mips/mips.md (move_type): Add ext_ins and logical.
8143         (type): Handle them.
8144         (and<mode>3): Use and_reg_operand as the second operand's predicate.
8145         (*and<mode>3): Add alternatives for lbu, lhu, lwu, <d>ext and
8146         shift_shift.  Remove commutative constraint modifier.
8147         (*and<mode>3_mips16): Add alternatives for lbu, lhu, lwu and
8148         shift_shift.
8149         (*clear_upper32_dext): Remove define_insn_and_split.
8150         (*clear_upper32): Turn this define_insn_and_split ...
8151         (splitter for ANDing register with 0xffff_ffff): .. into this.
8152
8153 2009-08-11  Adam Nemet  <anemet@caviumnetworks.com>
8154
8155         * combine.c (try_widen_shift_mode): Factor out code to check if an
8156         integer constant is a low-order bitmask from here ...
8157         * rtlanal.c (low_bitmask_len): ... to here.
8158         * rtl.h (low_bitmask_len): Declare.
8159
8160 2009-08-11  Uros Bizjak  <ubizjak@gmail.com>
8161
8162         PR target/8603
8163         * config/alpha/alpha.md (addsi3): Remove expander.
8164         (addsi3): Rename from *addsi3_internal insn pattern.
8165         (subsi3): Remove expander.
8166         (subsi3): Rename from *subsi3_internal insn pattern.
8167
8168 2009-08-11  Douglas B Rupp  <rupp@gnat.com>
8169
8170         * config/alpha/alpha.c (alpha_init_builtins): Nullify FWRITE and
8171         FWRITE_UNLOCKED.
8172
8173 2009-08-11  Vasiliy Fofanov  <fofanov@adacore.com>
8174             Eric Botcazou  <botcazou@adacore.com>
8175             Douglas B Rupp  <rupp@gnat.com>
8176
8177         * config/alpha/alpha.c (alpha_return_in_memory): On VMS, ensure
8178         that records that fit in 64 bits are returned by immediate value,
8179         as required by OpenVMS Calling Standard.
8180         (function_value): Adjust for above modification.
8181         (alpha_va_start) <TARGET_ABI_OPEN_VMS>: Use
8182         virtual_incoming_args_rtx as base object, not next_arg.
8183         * config/alpha/vms.h: (DEFAULT_PCC_STRUCT_RETURN): Define as 0.
8184
8185 2009-08-11  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
8186
8187         * reload.c (find_reloads_subreg_address): Check the original
8188         req_equiv_mem address to detect the case where an address is
8189         not valid in the outer mode.
8190
8191 2009-08-11  Richard Guenther  <rguenther@suse.de>
8192
8193         PR bootstrap/40788
8194         * builtins.c (gimplify_va_arg_expr): Do not call SET_EXPR_LOCATION.
8195
8196 2009-08-10  Douglas B Rupp  <rupp@gnat.com>
8197
8198         * config/alpha/vms.h (OPTIMIZATION_OPTIONS): Remove
8199         (OVERRIDE_OPTIONS): Incorporate removed OPTIMIZATION_OPTIONS.
8200
8201 2009-08-10  Olivier Hainque  <hainqueu@adacore.com>
8202             Douglas B Rupp  <rupp@gnat.com>
8203
8204         * config/alpha/alpha.c (alpha_sa_size): Force procedure type to
8205         PT_STACK when frame_pointer_needed on OpenVMS.
8206         (alpha_pv_save_size, alpha_using_fp): Remove.
8207         (alpha_vms_can_eliminate): New function. Support for CAN_ELIMINATE
8208         with proper processing for PT_NULL.
8209         (alpha_vms_initial_elimination_offset): New function. Support for
8210         INITIAL_ELIMINATION_OFFSET with proper processing for PT_NULL.
8211         (alpha_sa_size): Force procedure type to PT_STACK when
8212         frame_pointer_needed on OpenVMS.
8213         * config/alpha/alpha-protos.h (alpha_pv_save_size): Remove prototype.
8214         (alpha_using_fp): Likewise.
8215         (alpha_vms_can_eliminate): Add prototype.
8216         (alpha_vms_initial_elimination_offset): Likewise.
8217         * config/alpha/vms.h (CAN_ELIMINATE, INITIAL_ELIMINATION_OFFSET):
8218         Call alpha_vms_can_eliminate and alpha_vms_initial_elimination_offset.
8219
8220 2009-08-10  Eric Botcazou  <botcazou@adacore.com>
8221             Douglas B Rupp  <rupp@gnat.com>
8222
8223         * config/alpha/alpha.c (common_object_handler): New function.
8224         (vms_attribute_table): Declare a single attribute "common_object".
8225         (vms_output_aligned_decl_common): New global function.
8226         (SECTION_VMS_OVERLAY): Delete.
8227         (SECTION_VMS_GLOBAL): Likewise.
8228         (SECTION_VMS_INITIALIZE): Likewise.
8229         (vms_asm_named_section): Remove support for above flags.
8230         (vms_section_type_flags): Delete.
8231         (TARGET_SECTION_TYPE_FLAGS): Likewise.
8232         * config/alpha/alpha-protos.h (vms_output_aligned_decl_common): New.
8233         * config/alpha/vms.h (ASM_OUTPUT_ALIGNED_COMMON): Delete.
8234         (ASM_OUTPUT_ALIGNED_DECL_COMMON): New macro.
8235
8236 2009-08-10  SUGIOKA Toshinobu  <sugioka@itonet.co.jp>
8237
8238         PR target/41015
8239         * longlong.h [__sh__] (udiv_qrnnd): Add T register to clobber list.
8240         (sub_ddmmss): Likewise.
8241
8242 2009-08-10  Andreas Tobler  <a.tobler@schweiz.org>
8243
8244         PR bootstrap/41018
8245         * config/rs6000/freebsd.h: Define SVR4_ASM_SPEC. Adjust copyright
8246         year.
8247
8248 2009-08-10  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
8249
8250         PR target/37053
8251         * reload1.c (reload_as_needed): Use cancel_changes to completely
8252         undo a failed replacement attempt.
8253
8254 2009-08-10  Richard Guenther  <rguenther@suse.de>
8255
8256         PR middle-end/41006
8257         * tree-ssa.c (useless_type_conversion_p_1): Fold into ...
8258         (useless_type_conversion_p): ... here.  Require pointer targets
8259         to be compatible.
8260
8261 2009-08-10  Dodji Seketeli  <dodji@redhat.com>
8262
8263         PR c++/40866
8264         * tree-inline.c (copy_statement_list): The resulting copy shouldn't
8265         loose the original type of the statement list.
8266
8267 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
8268
8269         * config/alpha/alpha.c: Include libfuncs.h
8270         (avms_asm_output_extern): New function.
8271         (alpha_init_libfuncs): Init some decc libfuncs.
8272         * config/alpha/alpha-protos.h (avms_asm_output_external): Declare.
8273         * config/alpha/vms.h (ASM_OUTPUT_EXTERNAL): Define.
8274         (DO_CRTL_NAMES): Define.
8275         (LIB_SPEC): Remove.
8276         * config/alpha/vms64.h: (POINTERS_EXTEND_UNSIGNED): Remove undef.
8277         (LONG_TYPE_SIZE): Define.
8278         (TARGET_OS_CPP_BUILTINS): Define with __LONG_POINTERS=1
8279         (SUBTARGET_SWITCHES): Define malloc64 switch.
8280         (TARGET_DEFAULT): Default MASK_MALLOC64 set.
8281         (MASK_RETURN_ADDR): Define.
8282         doc/invoke.texi (mmalloc64): Document switch.
8283
8284 2009-08-09  Olivier Hainque  <hainque@adacore.com>
8285             Douglas B Rupp  <rupp@gnat.com>
8286
8287         * config/alpha/alpha.c (struct machine_function): New flag for VMS,
8288         uses_condition_handler.
8289         (alpha_expand_builtin_establish_vms_condition_handler): New expander.
8290         (alpha_expand_builtin_revert_vms_condition_handler): New expander.
8291         (enum alpha_builtin): New ALPHA_BUILTIN_REVERT_VMS_CONDITION_HANDLER
8292         and ALPHA_BUILTIN_ESTABLISH_VMS_CONDITION_HANDLER values.
8293         (code_for_builtin): New insn codes for the new alpha_builtins.
8294         (alpha_init_builtins): Register the new functions as BUILT_IN_MD.
8295         (alpha_sa_size): Account for uses_condition_handler.
8296         (alpha_expand_prologue): Likewise.
8297         (alpha_start_function): Likewise.
8298         (alpha_expand_epilogue): Likewise.
8299         * config/alpha/alpha-protos.h: Prototype the new alpha.c builtin
8300         establish/revert expanders.
8301         * config/alpha/alpha.h (DWARF_FRAME_REGNUM): Define.
8302         * config/alpha/alpha.md (builtin_establish_vms_condition_handler):
8303         New expander, resorting to the alpha.c associated function.
8304         (builtin_revert_vms_condition_handler): Likewise.
8305         * config/alpha/vms-gcc_shell_handler.c: New file. Implements
8306         __gcc_shell_handler, the static VMS condition handler used as
8307         an indirection wrapper to the current dynamically established
8308         handler.
8309         * config/alpha/vms-unwind.h: Complete rewrite.
8310         * config/alpha/t-vms (LIB2FUNCS_EXTRA): Add vms-gcc_shell_handler.c
8311         * config/alpha/vms.h (MD_UNWIND_SUPPORT):
8312
8313 2009-08-09  Eric Botcazou  <botcazou@adacore.com>
8314             Douglas B Rupp  <rupp@gnat.com>
8315
8316         * config/alpha/alpha.c (alpha_links): Add 'target' field.
8317         (alpha_need_linkage): Handle aliases.  Return function symbol.
8318         (alpha_use_linkage): Rename 'linkage' argument to 'func'.
8319         Use ultimate alias target for the linkage name.
8320         * config/alpha/alpha.md (movmemdi): Use the symbol returned
8321         by alpha_need_linkage for the function symbol.
8322         (setmemdi): Likewise.
8323
8324 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
8325
8326         * config/alpha/alpha.c (TARGET_ASM_UNALIGNED_*_OP): Define if on VMS.
8327         * config/alpha/vms.h (OBJECT_FORMAT_ELF): Define.
8328         (ASM_WEAKEN_LABEL): Define.
8329         (CRT_CALL_STATIC_FUNCTION): Define.
8330         (STARTFILE_SPEC): Add crtbegin.o crtbeginS.o.
8331         (ENDFILE_SPEC): Define.
8332         (INIT_SECTION_ASM_OP): Define.
8333         * config/alpha/vms-dwarf2eh.asm (__EH_FRAME_BEGIN__): Remove.
8334         * config/alpha/t-vms (EXTRA_PARTS): Add crtbegin.o crtbeginS.o
8335         crtend.o crtendS.o.
8336         (MULTILIB_OSDIRNAMES): Define.
8337         (shlib_version): Define.
8338         (SHLIB_EXT): Define.
8339         (SHLIB_OBJS): Define.
8340         (SHLIB_NAME): Define.
8341         (SHLIB_MULTILIB): Define.
8342         (SHLIB_INSTALL): Define.
8343         (SHLIB_SYMVEC): Define.
8344         (SHLIB_SYMVECX2): Define.
8345         (SHLIB_LINK): Define.
8346
8347 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
8348
8349         * config/alpha/alpha.c (alpha_initialize_trampoline):
8350         Initialize VMS trampoline IAW ABI for bounded procedure calls.
8351         (alpha_start_function): Emit transfer address on nested functions
8352         for VMS trampoline call.
8353         * config/alpha/t-vms (LIB2FUNCS_EXTRA): Remove vms_tramp.asm
8354         since no longer used.
8355         * config/alpha/vms-tramp.asm: Remove.
8356         * config/alpha/vms.h (TRAMPOLINE_TEMPLATE): Leave undefined
8357         since now only data initialized at runtime.
8358
8359 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
8360
8361         * config/alpha/vms.h (HANDLE_SYSV_PRAGMA): Define.
8362         (LINK_GCC_C_SEQUENCE_SPEC): Define.
8363         (MD_EXEC_PREFIX): Remove, no longer used.
8364         (MD_STARTFILE_PREFIX): Likewise.
8365         (INCLUDE_DEFAULTS): Likewise.
8366         * config/alpha/t-vms:
8367         (vms-dwarf2.o, vms-dwarf2eh.o): Use GCC_FOR_TARGET to compile.
8368
8369 2009-08-09  Richard Guenther  <rguenther@suse.de>
8370
8371         PR tree-optimization/41016
8372         * tree-ssa-ifcombine.c (get_name_for_bit_test): Fix tuplification bug.
8373         (operand_precision): Remove.
8374         (integral_operand_p): Likewise.
8375         (recognize_single_bit_test): Adjust.
8376
8377 2009-08-09  Richard Sandiford  <rdsandiford@googlemail.com>
8378
8379         * c-common.c (c_fully_fold_internal): Issue a warning if a binary
8380         operation overflows.  Likewise non-cast unary arithmetic.
8381         If one arm of a conditional expression is always taken,
8382         inhibit evaluation warnings for the other arm.  Likewise inhibit
8383         evaluation warnings for the second && or || operand if the first
8384         operand is enough to determine the result.
8385         * c-typeck.c (build_conditional_expr): Apply the same inhibition
8386         rules here.
8387         (build_binary_op): Prevent duplicate evaluation warnings.
8388
8389 2009-08-09  Richard Sandiford  <rdsandiford@googlemail.com>
8390
8391         * tree-out-of-ssa.c (insert_value_copy_on_edge): If the source
8392         and destination have different modes, Use promote_mode to
8393         determine the signedness of the conversion.  Assert that the
8394         promoted source mode matches the destination mode.  Don't pass
8395         the destination and destination mode to expand_expr if the source
8396         mode is different.  Simplify conversion logic.
8397
8398 2009-08-09  Ira Rosen  <irar@il.ibm.com>
8399
8400         PR tree-optimization/41008
8401         * tree-vect-loop.c (vect_is_simple_reduction): Get operands
8402         from condition only in case it's a comparison. Adjust checks.
8403
8404 2009-08-09  Bernd Schmidt  <bernd.schmidt@analog.com>
8405
8406         * tree-dfa.c (renumber_gimple_stmt_uids_in_blocks): New function.
8407         * tree-flow.h (renumber_gimple_stmt_uids_in_blocks): Declare it.
8408         * tree-ssa-loop-ivopts.c (comp_cost): Make COST an integer.
8409         (enum iv_position): Add IP_AFTER_USE and IP_BEFORE_USE.
8410         (dump_cand): Handle them.
8411         (struct iv_cand): New members COST_STEP and AINC_USE.
8412         (stmt_after_increment): Likewise.
8413         (stmt_after_inc_pos): Renamed from stmt_after_ip_original_pos.  All
8414         callers changed.  Use gimple_uid comparison instead of scanning.
8415         (add_candidate_1): When looking for identical candidates, take
8416         AINC_USE into account.  Set it for new candidates.
8417         (force_expr_to_var_cost): Cast target_spill_cost to int.
8418         (get_address_cost): New arguments STMT_AFTER_INC and MAY_AUTOINC.
8419         All callers changed.  Check for availability of autoinc addressing
8420         modes, both in general for a given mode, and in the specific use case.
8421         (get_computation_cost_at): New argument CAN_AUTOINC.  All callers
8422         changed.
8423         (get_computation_cost): Likewise.
8424         (autoinc_possible_for_pair, set_autoinc_for_original_candidates,
8425         add_autoinc_candidates): New static functions.
8426         (add_candidate): Call add_autoinc_candidates for candidates based on
8427         a USE_ADDRESS use.
8428         (find_iv_candidates): Call set_autoinc_for_original_candidates.
8429         (determine_use_iv_cost_address): If we have an autoinc candidate at
8430         the matching use, verify autoinc is possible and subtract the cost
8431         of the candidate's step from the cost.
8432         (determine_iv_cost): Record the cost of the increment in the COST_STEP
8433         member of the candidate.
8434         (tree_ssa_iv_optimize_loop): Swap the calls to determine_iv_costs and
8435         determine_use_iv_costs.  Call renumber_gimple_stmt_uids_in_blocks.
8436
8437 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
8438
8439         * config.build (ia64-hp-*vms*): New target.
8440         (alpha64-dec-*vms*,alpha*-dec-*vms*): Fix for config/vms and unify
8441         with ia64-hp-*vms*.
8442         * config.gcc (ia64-hp-*vms*): New target.
8443         (alpha64-dec-*vms*,alpha*-dec-*vms*): Fix for config/vms and unify
8444         with ia64-hp-*vms*.
8445         * config.host (ia64-hp-*vms*): New target.
8446         (alpha64-dec-*vms*,alpha*-dec-*vms*): Fix for config/vms and unify
8447         with ia64-hp-*vms*.
8448
8449 2009-08-08  Richard Guenther  <rguenther@suse.de>
8450
8451         PR tree-optimization/40991
8452         * tree-ssa-pre.c (eliminate): Delay purging EH edges.
8453
8454 2009-08-08  Richard Sandiford  <rdsandiford@googlemail.com>
8455
8456         * combine.c (gen_lowpart_or_truncate): Exclude CONST_INTs from
8457         mode check.  Do truncations in an integer mode.
8458         (force_to_mode): Handle subregs for all mode types.  Only do
8459         arithmetic simplifications on integer modes.
8460
8461 2009-08-07  Richard Guenther  <rguenther@suse.de>
8462
8463         PR tree-optimization/40999
8464         * tree-ssa-ccp.c (get_symbol_constant_value): Handle CONST_DECLs.
8465         (maybe_fold_reference): Lookup constant initializers.
8466         (fold_gimple_assign): Likewise.
8467
8468 2009-08-07  Richard Guenther  <rguenther@suse.de>
8469
8470         * tree-ssa.c (useless_type_conversion_p_1): Only for types
8471         that require structural equality defer to the langhook.
8472
8473 2009-08-07  Martin Jambor  <mjambor@suse.cz>
8474
8475         * ipa-prop.h (enum jump_func_type): New value IPA_JF_ANCESTOR, changed
8476         comments.
8477         (struct ipa_pass_through_data): New type.
8478         (struct ipa_ancestor_jf_data): New type.
8479         (union jump_func_value): Removed field formal_id, added fields
8480         pass_through and ancestor.
8481         (struct ipa_param_call_note): Changed type of formal_id to int from
8482         unsigned.
8483         * ipa-prop.c (ipa_print_node_jump_functions): Print pass through with
8484         operations jump functions and ancestor jump functions.
8485         (compute_complex_pass_through): New function.
8486         (compute_scalar_jump_functions): Call compute_complex_pass_through,
8487         reflect changes in the jump function strucutre.
8488         (update_jump_functions_after_inlining): Ignore complex pass-through
8489         and ancestor jump functions.
8490         * ipa-cp.c (ipcp_lattice_from_jfunc): Added support for ancestor and
8491         polynomial pass-through with operation jump functions.
8492
8493 2009-08-07  Jakub Jelinek  <jakub@redhat.com>
8494
8495         * dwarf2out.c (output_fde): When doing hot/cold partitioning, use
8496         fde->dw_fde_begin as begin label instead of hot/cold label.
8497         Use LLSDAC label instead of LLSDA for second section lsda.
8498         (dwarf2out_do_cfi_startproc): Add SECOND argument.  Use LLSDAC
8499         label instead of LLSDA if it is true.
8500         (dwarf2out_begin_prologue, dwarf2out_switch_text_section): Adjust
8501         callers.
8502         * except.c (add_call_site, dw2_size_of_call_site_table): Add
8503         SECTION argument.  Use it as index into crtl->eh.call_site_record
8504         array.
8505         (dw2_output_call_site_table): Likewise.  Add CS_FORMAT argument,
8506         use it to determine how to print table entries instead of using
8507         #ifdef HAVE_AS_LEB128.  For SECTION > 0 use hot resp. cold
8508         label instead of normal begin label as base.
8509         (sjlj_assign_call_site_values): Adjust add_call_site caller.
8510         (convert_to_eh_region_ranges): When doing hot/cold partitioning,
8511         ensure no EH range spans between sections and that landing pads
8512         are always in the corresponding section.
8513         (sjlj_size_of_call_site_table, sjlj_output_call_site_table): Adjust
8514         for crtl->eh.call_site_record being an array rather than scalar.
8515         (output_one_function_exception_table): New function, copied
8516         from output_function_exception_table.  Adjust
8517         dw2_size_of_call_site_table, dw2_output_call_site_table
8518         callers.  For SECOND section use *C suffixed labels.
8519         (output_function_exception_table): Call
8520         output_one_function_exception_table and, when doing hot/cold
8521         partitioning, also another time for the second section.
8522         * opts.c: Include except.h.
8523         (decode_options): Allow -freorder-blocks-and-partition with
8524         exceptions, unless SJLJ or TARGET_UNWIND_INFO.
8525         * Makefile.in (opts.o): Depend on $(EXCEPT_H).
8526         * function.h (struct rtl_eh): Change call_site_record from
8527         scalar into array of 2 elements.
8528
8529 2009-08-07  Martin Jambor  <mjambor@suse.cz>
8530
8531         * ipa-prop.c (count_formal_params_1): New function.
8532         (ipa_get_vector_of_formal_parms): New function.
8533         (get_vector_of_formal_parm_types): New function.
8534         (ipa_modify_formal_parameters): New function.
8535         (ipa_modify_call_arguments): New function.
8536         (index_in_adjustments_multiple_times_p): New function.
8537         (ipa_combine_adjustments): New function.
8538         (ipa_dump_param_adjustments): New function.
8539         * ipa-prop.h (struct ipa_parm_adjustment): New type.
8540         (ipa_get_vector_of_formal_parms): Declare.
8541         (ipa_modify_formal_parameters): Declare.
8542         (ipa_modify_call_arguments): Declare.
8543         (ipa_combine_adjustments): Declare.
8544         (ipa_dump_param_adjustments): Declare.
8545         (build_ref_for_offset): Declare.
8546         * Makefile.in (tree-sra.o): Add ipa-prop.h to dependencies.
8547         * tree-sra.c: Include ipa-prop.c.
8548         (build_ref_for_offset): Make public.
8549
8550 2009-08-06  Neil Vachharajani  <nvachhar@gmail.com>
8551
8552         * value-prof.c (init_pid_map): Replace xmalloc with XCNEWVEC.
8553
8554 2009-08-06  Thomas Schwinge  <tschwinge@gnu.org>
8555
8556         * gcc/doc/extend.texi (__builtin_extract_return_address)
8557         (__builtin_frob_return_address): Document.
8558
8559 2009-08-06  Paul Brook  <paul@codesourcery.com>
8560
8561         * config/arm/lib1funcs.asm (ARM_DIV_BODY): Add Thumb-2 implementation.
8562         (udivsi3, aeabi_uidivmod, divsi3, aeabi_idivmod): Only use Thumb-1
8563         implementation on ARMv6-M.
8564
8565 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
8566
8567         * doc/extend.texi (pcs): Document new attribute for ARM.
8568
8569 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
8570
8571         * arm.c (pcs_attribute_args): Comment out unsupported attribute
8572         variants.
8573
8574 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
8575
8576         * arm.c (arm_handle_pcs_attribute): Pass the entire name object to
8577         warning ().
8578
8579 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
8580
8581         * arm.c (arm_handle_pcs_attribute): Use %qE in warning.
8582
8583 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
8584
8585         Merge ARM/hard_vfp_branch to trunk.
8586
8587         2009-08-04  Richard Earnshaw  <rearnsha@arm.com>
8588
8589         * arm.c (libcall_eq): New function.
8590         (libcall_hash): New function.
8591         (add_libcall): New function.
8592         (arm_libcall_uses_aapcs_base): New function.
8593         (arm_libcall_value): Use arm_libcall_uses_aapcs_base to check for
8594         libcalls using the base PCS.
8595         (arm_init_cumulative_args): Likewise.
8596
8597         2009-07-20  Joseph Myers  <joseph@codesourcery.com>
8598
8599         * config/arm/arm.c (arm_libcall_value, arm_init_cumulative_args):
8600         Use base ABI for conversion libfuncs between HFmode and SFmode.
8601
8602         2009-05-12  Joseph Myers  <joseph@codesourcery.com>
8603
8604         * config/arm/arm.c (aapcs_vfp_sub_candidate): Use V2SImode and
8605         V4SImode as representatives of all 64-bit and 128-bit vector
8606         types.  Allow vector types without vector modes.
8607         (aapcs_vfp_is_call_or_return_candidate): Handle vector types
8608         without vector modes like BLKmode.
8609         (aapcs_vfp_allocate): Handle TImode for non-TARGET_NEON like
8610         BLKmode.  Avoid unsupported vector modes or TImode moves for
8611         non-TARGET_NEON.
8612         (aapcs_vfp_allocate_return_reg): Likewise.
8613         (arm_vector_mode_supported_p): Only support V2SImode, V4HImode and
8614         V8QImode if TARGET_NEON || TARGET_IWMMXT.
8615
8616         2009-05-12  Joseph Myers  <joseph@codesourcery.com>
8617
8618         * config/arm/arm.c (arm_handle_pcs_attribute): New.
8619         (arm_get_pcs_model): Pass attribute arguments to
8620         arm_pcs_from_attribute.
8621         (arm_init_cumulative_args): Use base AAPCS for conversions from
8622         floating-point types to DImode.
8623         (arm_attribute_table): Add pcs attribute.
8624         (arm_handle_pcs_attribute): New.
8625         * config/arm/bpabi.h (DECLARE_LIBRARY_RENAMES): When renaming
8626         conversions from floating-point types to DImode, also declare them
8627         to use base AAPCS and declare functions they call to use base
8628         AAPCS and their RTABI names.
8629
8630         2009-05-12  Joseph Myers  <joseph@codesourcery.com>
8631
8632         * doc/invoke.texi (-mfloat-abi=@var{name}): Remove statement about
8633         -mfloat-abi=hard not being supported for VFP.
8634
8635         2009-05-11  Kazu Hirata  <kazu@codesourcery.com>
8636
8637         * config/sparc/sparc.c (sparc_emit_float_lib_cmp): Pass a libcall
8638         SYMBOL_REF to hard_libcall_value.
8639
8640         2009-03-05  Joseph Myers  <joseph@codesourcery.com>
8641             Richard Earnshaw  <rearnsha@arm.com>
8642
8643         * config/arm/arm.c (aapcs_layout_arg): Once a co-processor argument
8644         has been put on the stack, all remaining co-processory arguments for
8645         that co-processor also go on the stack.
8646
8647         2009-03-05  Joseph Myers  <joseph@codesourcery.com>
8648
8649         * config/arm/arm.c (arm_return_in_memory): Handle returning
8650         vectors of suitable size in registers also for AAPCS case.
8651
8652         2009-01-13  Richard Earnshaw <rearnsha@arm.com>
8653
8654         * doc/tm.texi (TARGET_LIBCALL_VALUE): Add missing end statement.
8655
8656         2008-12-09  Richard Earnshaw <rearnsha@arm.com>
8657
8658         ARM Hard-VFP calling convention
8659         * target-def.h (TARGET_LIBCALL_VALUE): New hook.
8660         * target.h (gcc_target): Add libcall_value to table of call hooks.
8661         * targhooks.h (default_libcall_value): Default implementation.
8662         * targhooks.c (default_libcall_value): Likewise.
8663         * doc/tm.texi (TARGET_LIBCALL_VALUE): Document it.
8664         * optabs.c (expand_unop): Use it.
8665         * expr.h (hard_libcall_value): Pass the function RTX through.
8666         * calls.c (emit_library_call_value_1): Update call to
8667         hard_libcall_value.
8668         * explow.c (hard_libcall_value): Use new target hook.
8669         * testsuite/lib/target-supports.exp
8670         (check_effective_target_arm_hard_vfp_ok): New hook.
8671         (check_effective_target_arm_neon_ok): Improve test for neon
8672         availability.
8673         * testsuite/gcc.target/arm/eabi1.c: Only run test in base variant.
8674         * config/arm/arm.c: Include cgraph.h
8675         (TARGET_FUNCTION_VALUE): Override default hook.
8676         (arm_pcs_default): New variable.
8677         (arm_override_options): Don't fault hard calling convention with VFP.
8678         Add support for AAPCS variants.
8679         (arm_function_value): Make static.  Handle AAPCS variants.
8680         (arm_libcall_value): New function.
8681         (arm_apply_result_size): Handle VFP registers in results.
8682         (arm_return_in_memory): Rework all AAPCS variants; handle hard-vfp
8683         conventions.
8684         (pcs_attribute_args): New variable.
8685         (arm_pcs_from_attribute): New function.
8686         (arm_get_pcs_model): New function.
8687         (aapcs_vfp_cum_init): New function.
8688         (aapcs_vfp_sub_candidate): New function.
8689         (aapcs_vfp_is_return_candidate): New function.
8690         (aapcs_vfp_is_call_candidate): New function.
8691         (aapcs_vfp_allocate): New function.
8692         (aapcs_vfp_allocate_return_reg): New function.
8693         (aapcs_vfp_advance): New function.
8694         (aapcs_cp_arg_layout): New variable.
8695         (aapcs_select_call_coproc): New function.
8696         (aapcs_select_return_coproc): New function.
8697         (aapcs_allocate_return_reg): New function.
8698         (aapcs_libcall_value): New function.
8699         (aapcs_layout_arg): New function.
8700         (arm_init_cumulative_args): Initialize AAPCS args data.
8701         (arm_function_arg): Handle AAPCS variants using new interface.
8702         (arm_arg_parital_bytes): Likewise.
8703         (arm_function_arg_advance): New function.
8704         (arm_function_ok_for_sibcall): Ensure that sibling calls agree on
8705         calling conventions.
8706         (arm_setup_incoming_varargs): Handle new AAPCS args data.
8707         * arm.h (NUM_VFP_ARG_REGS): Define.
8708         (LIBCALL_VALUE): Update.
8709         (FUNCTION_VALUE): Delete.
8710         (FUNCTION_VALUE_REGNO_P): Add VFP regs.
8711         (arm_pcs): New enum.
8712         (CUMULATIVE_ARGS): New data to support AAPCS argument marshalling.
8713         (FUNCTION_ARG_ADVANCE): Call arm_function_arg_advance.
8714         (FUNCTION_ARG_REGNO_P): Add VFP regs.
8715         * arm-protos.h (arm_function_arg_advance): Add.
8716         (aapcs_libcall_value): Add.
8717         (arm_function_value): Delete.
8718
8719 2009-08-06  Uros Bizjak  <ubizjak@gmail.com>
8720             H.J. Lu  <hongjiu.lu@intel.com>
8721
8722         PR target/40957
8723         * config/i386/i386.c (standard_sse_mode_p): Remove.
8724         (standard_sse_constant_p): Return 2 for integer mode
8725         vector_all_ones_operand when SSE2 is enabled.
8726         (standard_sse_constant_opcode)<case 2>: Always return [v]pcmpeqd.
8727         (ix86_expand_vector_move): Do not check for negative values from
8728         standard_sse_constant_p.
8729
8730 2009-08-06  Richard Guenther  <rguenther@suse.de>
8731
8732         * tree-ssa.c (useless_type_conversion_p_1): Make function and
8733         array type comparisons frontend independent.
8734         * Makefile.in (tree-ssa.o): Add $(TARGET_H) dependency.
8735         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Always fill
8736         out array reference lower bound and element size operands.
8737         (ao_ref_init_from_vn_reference): Properly compute the offset
8738         for ARRAY_RANGE_REF.
8739         (vn_reference_fold_indirect): Fill out array reference lower
8740         bound and element size operands.
8741         * tree-ssa-pre.c (phi_translate_1): Fail if we have to translate
8742         a non gimple valued reference operand which can happen for
8743         array reference lower bound or element size.
8744         (create_component_ref_by_pieces_1): Properly generate the
8745         element size operand for array references.
8746
8747 2009-08-06  Richard Guenther  <rguenther@suse.de>
8748
8749         PR tree-optimization/40964
8750         * tree.c (iterative_hash_host_wide_int): Export.
8751         * tree.h (iterative_hash_host_wide_int): Declare.
8752         * tree-ssa-structalias.c (heapvar_map): New struct.
8753         (heapvar_map_eq): New function.
8754         (heapvar_map_hash): Likewise.
8755         (heapvar_lookup): Adjust.
8756         (heapvar_insert): Likewise.
8757         (make_constraint_from_heapvar): Allow multiple heap variables
8758         per decl at different offsets.
8759         (init_alias_heapvars): Adjust.
8760
8761 2009-08-04  David Daney  <ddaney@caviumnetworks.com>
8762
8763         * config/mips/mips.h (TARGET_SYNC_AFTER_SC): New macro.
8764         * mips_output_sync_loop (mips_output_sync_loop): Only emit
8765         trailing sync if TARGET_SYNC_AFTER_SC.
8766
8767 2009-08-05  David Daney  <ddaney@caviumnetworks.com>
8768
8769         * gcc/config/mips/sync.md (sync_compare_and_swap<mode>,
8770         compare_and_swap_12, sync_add<mode>, sync_<optab>_12,
8771         sync_old_<optab>_12, sync_new_<optab>_12, sync_nand_12,
8772         sync_old_nand_12, sync_new_nand_12, sync_sub<mode>,
8773         sync_old_add<mode>, sync_old_sub<mode>, sync_new_add<mode>,
8774         sync_new_sub<mode>, sync_<optab><mode>, sync_old_<optab><mode>,
8775         sync_new_<optab><mode>, sync_nand<mode>, sync_old_nand<mode>,
8776         sync_new_nand<mode>, sync_lock_test_and_set<mode>,
8777         test_and_set_12): Rewrite calls to mips_output_sync_loop.
8778         * gcc/config/mips/mips-protos.h (mips_output_sync_loop): Make
8779         the prototype declaration match the definition.
8780         * gcc/config/mips/mips.c (mips_output_sync_loop):  Emit sync
8781         instructions explicitly.  Add barrier_before and operands
8782         parameters.
8783         * gcc/config/mips/mips.h (MIPS_COMPARE_AND_SWAP,
8784         MIPS_COMPARE_AND_SWAP_12, MIPS_SYNC_OP, MIPS_SYNC_OP_12,
8785         MIPS_SYNC_OLD_OP_12, MIPS_SYNC_NEW_OP_12, MIPS_SYNC_OLD_OP,
8786         MIPS_SYNC_NEW_OP, MIPS_SYNC_NAND, MIPS_SYNC_OLD_NAND,
8787         MIPS_SYNC_NEW_NAND, MIPS_SYNC_EXCHANGE,
8788         MIPS_SYNC_EXCHANGE_12): Remove sync instructions.
8789
8790 2009-08-05  Andrew Pinski  <pinskia@gmail.com>
8791
8792         * tree-ssa-alias.c: Fix intervals to use [) syntax.
8793
8794 2009-08-05  Uros Bizjak  <ubizjak@gmail.com>
8795             Mikulas Patocka  <mikulas@artax.karlin.mff.cuni.cz>
8796
8797         PR target/40906
8798         * config/i386/i386.c (ix86_split_long_move): Fix push of multi-part
8799         source operand.
8800
8801 2009-08-05  Jakub Jelinek  <jakub@redhat.com>
8802
8803         PR rtl-optimization/40924
8804         * dse.c (canon_address): Before calling cselib_expand_value_rtx
8805         make sure canon_rtx (mem_address) isn't simpler than
8806         canon_rtx (expanded_mem_address).
8807
8808 2009-08-05  Li Feng  <nemokingdom@gmail.com>
8809
8810         * graphite-sese-to-poly.c (build_pbb_drs): Remove build alias set
8811         for each poly_bb_p.
8812         (build_scop_drs): Build alias set for each SCoP.
8813
8814 2009-08-04  Sandra Loosemore  <sandra@codesourcery.com>
8815
8816         * doc/invoke.texi (MIPS Options): Document new 1004K -march options.
8817         * config/mips/mips.c (mips_cpu_info_table): Add 1004K cores.
8818         * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Add pattern for 1004K.
8819         (MIPS_ARCH_FLOAT_SPEC): Likewise.
8820         (BASE_DRIVER_SELF_SPECS): Likewise.
8821
8822 2009-08-04  Andrew Pinski  <pinskia@gmail.com>
8823
8824         * tree-ssa-alias.c: Fix some comment typos.
8825
8826 2009-08-04  Kaz Kojima  <kkojima@gcc.gnu.org>
8827
8828         * config/sh/linux-atomic.asm (ATOMIC_BOOL_COMPARE_AND_SWAP,
8829         ATOMIC_OP_AND_FETCH, ATOMIC_COMBOP_AND_FETCH): Define.
8830
8831 2009-08-03  Janis Johnson  <janis187@us.ibm.com>
8832
8833         PR c/39902
8834         * simplify-rtx.c (simplify_binary_operation_1): Disable
8835         simplifications for decimal float operations.
8836
8837 2009-08-03  Jakub Jelinek  <jakub@redhat.com>
8838
8839         PR middle-end/40943
8840         * tree-ssa.c (warn_uninitialized_var): Even on LHS warn for
8841         operand of INDIRECT_REF.
8842
8843 2009-08-03  Uros Bizjak  <ubizjak@gmail.com>
8844
8845         * config/alpha/alpha.c (alpha_legitimate_constant_p): Reject CONST
8846         constants referencing TLS symbols.
8847
8848 2009-08-03  SUGIOKA Toshinobu  <sugioka@itonet.co.jp>
8849
8850         * config/sh/linux-atomic.asm (ATOMIC_COMPARE_AND_SWAP): Rename
8851         __sync_compare_and_swap_* to __sync_val_compare_and_swap_*.
8852
8853 2009-08-03  Richard Guenther  <rguenther@suse.de>
8854
8855         * tree.c (make_vector_type): Build a main variant first,
8856         get the canonical one and then build the variant.
8857         * tree-ssa.c (useless_type_conversion_p_1): Handle
8858         fixed-point types.
8859         (useless_type_conversion_p): Conversions to pointers to
8860         incomplete record types are useless.
8861
8862 2009-08-03  Richard Guenther  <rguenther@suse.de>
8863
8864         * tree-cfg.c (pass_warn_unused_result): Mark name that no dump
8865         file will be created.
8866         * omp-low.c (pass_diagnose_omp_blocks): Likewise.
8867         * toplev.c (compile_file): Adjust comment.
8868
8869 2009-08-03  Kaz Kojima  <kkojima@gcc.gnu.org>
8870
8871         * config/sh/sh-protos.h (sh_promote_function_mode): Remove.
8872         * config/sh/sh.c (sh_promote_function_mode): Wrap long lines.
8873         (TARGET_PROMOTE_FUNCTION_MODE): Define.
8874         (TARGET_PROMOTE_FUNCTION_ARGS): Remove.
8875         (sh_promote_function_mode): Fix typo.
8876
8877 2009-08-03  Andreas Krebbel  <krebbel1@de.ibm.com>
8878
8879         * explow.c (promote_mode): Mark TYPE and PUNSIGNEDP as possibly unused.
8880
8881 2009-08-02  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
8882
8883         * pa.c (pa_promote_function_mode): Remove ATTRIBUTE_UNUSED from
8884         declaration arguments.
8885
8886 2009-08-02  Uros Bizjak  <ubizjak@gmail.com>
8887
8888         * config/i386/i386.c (ix86_expand_fp_compare): Use const0_rtx instead
8889         of GEN_INT (0x00) and const1_rtx instead of GEN_INT (0x01).
8890         (ix86_split_ashl): Ditto.
8891         (ix86_expand_vector_init_one_nonzero): Ditto.
8892         (ix86_expand_vector_set): Ditto.
8893         (ix86_expand_reduc_v4sf): Ditto.
8894
8895 2009-08-02  Paolo Bonzini  <bonzini@gnu.org>
8896
8897         * explow.c (promote_function_mode): Remove assert.
8898         * config/sh/sh.c (sh_promote_function_mode): Declare.
8899
8900 2009-08-01  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
8901
8902         * config/pa/pa.c (pa_promote_function_mode): Declare.
8903         Change to static.  Fix promote_mode call.
8904
8905         * gthr-dce.h (CONST_CAST2): Define if not defined.
8906         (__gthread_setspecific): Use CONST_CAST2 to fix warning.
8907
8908         * config.gcc (hppa[12]*-*-hpux10*): Add stdint support.
8909
8910 2009-08-01  Paolo Bonzini  <bonzini@gnu.org>
8911
8912         * expr.c (store_constructor): Use promote_decl_mode.  Remove
8913         now write-only variable unsignedp.
8914         (expand_expr_real_1): Use promote_decl_mode.
8915         * expr.h (promote_function_mode, promote_decl_mode): New.
8916         (promote_mode): Remove last argument.
8917         * function.c (assign_temp): Drop last argument of promote_mode.
8918         (assign_parm_find_data_types): Use promote_function_mode.
8919         (assign_parm_setup_reg): Likewise.
8920         (expand_function_end): Use promote_function_mode.
8921         * calls.c (initialize_argument_information): Use promote_function_mode.
8922         (precompute_arguments): Use promote_mode instead of checking if
8923         only PROMOTE_FUNCTION_MODE is defined.
8924         (expand_call): When making sibcall decisions, use promote_function_mode.
8925         Below, remove an if for targetm.calls.promote_function_return and
8926         and use promote_function_mode.
8927         (emit_library_call_value_1): Use promote_function_mode, fix bug
8928         where promote_mode was passed FOR_CALL == 0 for a return value in an
8929         assertion.
8930         * cfgexpand.c (expand_one_register_var): Use promote_decl_mode.
8931         * explow.c (promote_function_mode, promote_decl_mode): New.
8932         (promote_mode): Keep only the FOR_CALL == 0 case.
8933         * combine.c (setup_incoming_promotion): Remove test of
8934         promote_function_args.  Use promote_function_mode.
8935         * stmt.c (expand_value_return): Use promote_decl_mode.
8936         (expand_decl): Use promote_decl_mode.
8937
8938         * expr.c (store_constructor): Use promote_decl_mode.  Remove
8939         now write-only variable unsignedp.
8940         (expand_expr_real_1): Use promote_decl_mode.
8941         * expr.h (promote_function_mode, promote_decl_mode): New.
8942         (promote_mode): Remove last argument.
8943         * function.c (assign_temp): Drop last argument of promote_mode.
8944         (assign_parm_find_data_types): Use promote_function_mode.
8945         (assign_parm_setup_reg): Likewise.
8946         (expand_function_end): Use promote_function_mode.
8947         * calls.c (initialize_argument_information): Use promote_function_mode.
8948         (precompute_arguments): Use promote_mode instead of checking if
8949         only PROMOTE_FUNCTION_MODE is defined.
8950         (expand_call): When making sibcall decisions, use promote_function_mode.
8951         Below, remove an if for targetm.calls.promote_function_return and
8952         and use promote_function_mode.
8953         (emit_library_call_value_1): Use promote_function_mode, fix bug
8954         where promote_mode was passed FOR_CALL == 0 for a return value in an
8955         assertion.
8956         * cfgexpand.c (expand_one_register_var): Use promote_decl_mode.
8957         * explow.c (promote_function_mode, promote_decl_mode): New.
8958         (promote_mode): Keep only the FOR_CALL == 0 case.
8959         * combine.c (setup_incoming_promotion): Remove test of
8960         promote_function_args.  Use promote_function_mode.
8961         * stmt.c (expand_value_return): Use promote_decl_mode.
8962         (expand_decl): Use promote_decl_mode.
8963
8964         * explow.c (promote_function_mode): Just call the target hook.
8965         * targhooks.c (default_promote_function_mode,
8966         default_promote_function_mode_always_promote): New.
8967         * targhooks.h (default_promote_function_mode,
8968         default_promote_function_mode_always_promote): Declare.
8969         * target.h (promote_function_args, promote_function_return): Remove.
8970         (promote_function_mode): New.
8971         * target-def.h (TARGET_PROMOTE_FUNCTION_ARGS,
8972         TARGET_PROMOTE_FUNCTION_RETURN): Remove.
8973         (TARGET_PROMOTE_FUNCTION_MODE): New.
8974         (TARGET_CALLS): Adjust.
8975         * system.h (TARGET_PROMOTE_FUNCTION_ARGS,
8976         TARGET_PROMOTE_FUNCTION_RETURN, PROMOTE_FUNCTION_MODE): Poison.
8977
8978         * config/s390/s390.h (PROMOTE_FUNCTION_MODE): Move...
8979         * config/s390/s390.c (s390_promote_function_mode): ... here,
8980         with pointer handling.
8981         (TARGET_PROMOTE_FUNCTION_MODE): Define.
8982         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
8983
8984         * config/sparc/sparc.h (PROMOTE_FUNCTION_MODE): Move...
8985         * config/sparc/sparc.c (sparc_promote_function_mode): ... here,
8986         with pointer handling.
8987         (TARGET_PROMOTE_FUNCTION_MODE): Define.
8988         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
8989
8990         * config/sh/sh-protos.h (sh_promote_function_mode): New.
8991         * config/sh/sh.c (sh_promote_function_mode): New.
8992         (TARGET_PROMOTE_FUNCTION_MODE): Define.
8993         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
8994
8995         * config/cris/cris.h (PROMOTE_FUNCTION_MODE): Move...
8996         * config/cris/cris.c (cris_promote_function_mode): ... here.
8997         (TARGET_PROMOTE_FUNCTION_MODE): Define.
8998         (TARGET_PROMOTE_FUNCTION_ARGS): Remove.
8999
9000         * config/mmix/mmix.h (PROMOTE_FUNCTION_MODE): Move...
9001         * config/mmix/mmix.c (mmix_promote_function_mode): ... here.
9002         (TARGET_PROMOTE_FUNCTION_MODE): Define.
9003         (TARGET_PROMOTE_FUNCTION_ARGS): Remove.
9004
9005         * config/arm/arm.h (PROMOTE_FUNCTION_MODE): Move...
9006         * config/arm/arm.c (arm_promote_function_mode): ... here, without
9007         complex type handling.
9008         (TARGET_PROMOTE_FUNCTION_MODE): Define.
9009         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
9010
9011         * config/pa/pa.c (pa_promote_function_mode): New.
9012         (TARGET_PROMOTE_FUNCTION_MODE): Define.
9013         (TARGET_PROMOTE_FUNCTION_RETURN): Remove.
9014
9015         * config/alpha/alpha.c (TARGET_PROMOTE_FUNCTION_ARGS,
9016         TARGET_PROMOTE_FUNCTION_RETURN): Remove.
9017         (TARGET_PROMOTE_FUNCTION_MODE): Define equivalently.
9018         * config/xtensa/xtensa.c: Likewise.
9019         * config/stormy16/stormy16.c: Likewise.
9020         * config/iq2000/iq2000.c: Likewise.
9021         * config/rs6000/rs6000.c: Likewise.
9022         * config/picochip/picochip.c: Likewise.
9023         * config/arc/arc.c: Likewise.
9024         * config/mcore/mcore.c: Likewise.
9025         * config/score/score.c: Likewise.
9026         * config/mips/mips.c: Likewise.
9027         * config/bfin/bfin.c: Likewise.
9028         * config/ia64/ia64.c: Likewise (disabled though).
9029
9030         * config/frv/frv.h: Remove pointless remark.
9031
9032         * doc/tm.texi (PROMOTE_FUNCTION_MODE,
9033         TARGET_PROMOTE_FUNCTION_ARGS,
9034         TARGET_PROMOTE_FUNCTION_RETURN): Consolidate into...
9035         (TARGET_PROMOTE_FUNCTION_MODE): ... this.
9036
9037 2009-08-01  Sebastian Pop  <sebastian.pop@amd.com>
9038
9039         * doc/invoke.texi (-fgraphite-force-parallel): Renamed
9040         -floop-parallelize-all.
9041         * toplev.c (process_options): Rename flag_graphite_force_parallel to
9042         flag_loop_parallelize_all.
9043         * tree-ssa-loop.c (gate_graphite_transforms): Same.
9044         * graphite.c (graphite_transform_loops): Same.
9045         * common.opt: Same.
9046         * graphite-poly.c (apply_poly_transforms): Same.
9047
9048 2009-07-31  Richard Earnshaw  <rearnsha@arm.com>
9049
9050         PR tree-optimization/40914
9051         * ipa-prop.c (ipa_get_ptr_load_param): New argument use_delta,
9052         if set, then check the delta field of the PMF record.
9053         (ipa_get_stmt_member_ptr_load_param): Propagate new param use_delta.
9054         (ipa_analyze_call_uses): Handle machines where the vbit for a PMF
9055         call is stored in the delta.
9056
9057 2009-07-31  Adam Nemet  <anemet@caviumnetworks.com>
9058
9059         * config/mips/mips.md (*clear_upper32_dext): New pattern.
9060
9061 2009-07-31  Uros Bizjak  <ubizjak@gmail.com>
9062
9063         * config/i386/bsd.h (ASM_BYTE): New define.
9064         * config/i386/darwin.h (ASM_BYTE): Rename from ASM_BYTE_OP.
9065         * config/i386/att.h (ASM_BYTE): New define. Use ASM_BYTE instead of
9066         .byte.  Use fputs or putc instead of fprintf where appropriate.
9067         * config/i386/i386-interix.h: Use ASM_BYTE instead of .byte.  Use
9068         fputs or putc instead of fprintf where appropriate.
9069         * config/i386/i386elf.h: Ditto.
9070         * config/i386/sysv4.h: Ditto.
9071
9072         * config/i386/i386.c (TARGET_ASM_BYTE_OP): New define.
9073         * config/i386/i386.md (x86_sahf_1): Use ASM_BYTE instead of .byte.
9074         (*tls_global_dynamic_64): Ditto.
9075
9076 2009-07-31  Christian Bruel  <christian.bruel@st.com>
9077
9078         * gcc/config.gcc (sh*-*-elf): test with_libgloss.
9079
9080 2009-07-31  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
9081
9082         * config/arm/arm.c (arm_arm_address_cost): Fix typo.
9083         Remove dead code for MINUS.
9084
9085 2009-07-31  Anthony Green  <green@moxielogic.com>
9086
9087         * config/moxie/moxie.c (moxie_expand_prologue): Use $r5 instead of
9088         $r12 in prologue.
9089         (moxie_expand_epilogue): Ditto for epilogue.
9090         (moxie_setup_incoming_varargs): ABI change.  Use 5 registers for
9091         incoming arguments.
9092         (moxie_function_arg): Ditto.
9093         (moxie_pass_by_reference): Ditto.
9094         (moxie_arg_partial_bytes): Ditto.
9095         * config/moxie/moxie.h (CALL_USED_REGISTERS): Ditto.
9096         (FUNCTION_ARG_ADVANCE) Ditto.
9097         (REG_PARM_STACK_SPACE) Ditto.
9098         (FUNCTION_ARG_REGNO_P) Dito.
9099
9100         * config.gcc: Add moxie linux config support.
9101         * gcc/config/moxie/uclinux.h: New file.
9102
9103 2009-07-31  DJ Delorie  <dj@redhat.com>
9104
9105         * config/sh/sh.md (UNSPECV_SP_SWITCH_B): New.
9106         (UNSPECV_SP_SWITCH_E): New.
9107         (sp_switch_1): Change to an unspec.
9108         (sp_switch_2): Change to an unspec.  Don't use post-inc when we
9109         replace $r15.
9110         * config/sh/sh.c (sh_expand_prologue): Use the constant pool to
9111         reference the new stack's address
9112
9113 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9114
9115         * Makefile.in (OBJS-common): Added dependence on graphite-blocking.o,
9116         graphite-clast-to-gimple.o, graphite-dependences.o,
9117         graphite-interchange.o, graphite-poly.o, graphite-ppl.o,
9118         graphite-scop-detection.o, graphite-sese-to-poly.o, and sese.o.
9119         (graphite-blocking.o,
9120         graphite-clast-to-gimple.o, graphite-dependences.o,
9121         graphite-interchange.o, graphite-poly.o, graphite-ppl.o,
9122         graphite-scop-detection.o, graphite-sese-to-poly.o, and sese.o): New.
9123         * cfgloop.c (alloc_loop): Set loop->can_be_parallel to false.
9124         * cfgloop.h (struct loop): Add can_be_parallel field.
9125         * common.opt (fgraphite-identity): Moved up.
9126         (fgraphite-force-parallel): New flag.
9127         * graphite.c: Rewrite.
9128         * graphite.h: Rewrite.
9129         * passes.c (init_optimization_passes): Schedule a pass of DCE and LIM
9130         after Graphite.
9131         * toplev.c (graphite_out_file): New file descriptor.
9132         (graphite_in_file): New.
9133         (process_options): flag_graphite_force_parallel cannot be used without
9134         Graphite.
9135         * tree-ssa-loop.c: Include toplev.h.
9136         (gate_graphite_transforms): Enable flag_graphite for
9137         flag_graphite_force_parallel.
9138
9139 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9140
9141         * ChangeLog.graphite: New.
9142         * graphite-blocking.c: New.
9143         * graphite-clast-to-gimple.c: New.
9144         * graphite-clast-to-gimple.h: New.
9145         * graphite-dependences.c: New.
9146         * graphite-dependences.h: New.
9147         * graphite-interchange.c: New.
9148         * graphite-poly.c: New.
9149         * graphite-poly.h: New.
9150         * graphite-ppl.c: New.
9151         * graphite-ppl.h: New.
9152         * graphite-scop-detection.c: New.
9153         * graphite-scop-detection.h: New.
9154         * graphite-sese-to-poly.c: New.
9155         * graphite-sese-to-poly.h: New.
9156         * sese.c: New.
9157         * sese.h: New.
9158
9159 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9160
9161         * tree-chrec.c (evolution_function_right_is_integer_cst): New.
9162         * tree-chrec.h (evolution_function_right_is_integer_cst): Declared.
9163
9164 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9165
9166         * tree-chrec.c (operator_is_linear): Handle BIT_NOT_EXPR.
9167         (scev_is_linear_expression): Return false if the evolution is not
9168         affine multivariate.
9169
9170 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9171
9172         * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
9173         * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
9174
9175 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9176
9177         * tree-data-ref.c (debug_data_references): New.
9178         (debug_data_reference): New.
9179         * tree-data-ref.h (debug_data_references): Declared.
9180         (debug_data_reference): Declared.
9181
9182 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9183
9184         * tree-data-ref.c (stmt_simple_memref_p: Removed.
9185         * tree-data-ref.h (scop_p): Removed.
9186         (struct data_reference): Remove field scop.
9187         (DR_SCOP): Removed.
9188         (stmt_simple_memref_p): Removed.
9189
9190 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9191
9192         * cfgloop.h (create_empty_loop_on_edge): Pass an extra argument.
9193         * cfgloopmanip.c (create_empty_loop_on_edge): Leave the loop_latch
9194         basic block empty.
9195
9196 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9197
9198         * doc/invoke.texi (-fgraphite-force-parallel): Documented.
9199
9200 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9201
9202         * doc/invoke.texi (-fgraphite-identity): Documented.
9203
9204 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9205
9206         * tree-scalar-evolution.c: Fix comment.
9207         (instantiate_scev_1): Return unknow from scev instantiation if the
9208         result is not above instantiate_below.
9209
9210 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
9211
9212         * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
9213         static anymore.  Instantiate the symbols that may have been introduced
9214         by chrec_apply.
9215         * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
9216         Declared.
9217
9218 2009-07-30  DJ Delorie  <dj@redhat.com>
9219
9220         * config/mep/mep.c (mep_asm_init_sections): Add section flags and
9221         .vliw directive to VLIW sections.
9222
9223 2009-07-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9224
9225         * Makefile.in (AUTOCONF, ACLOCAL, ACLOCAL_AMFLAGS, aclocal_deps):
9226         New variables.
9227         ($(srcdir)/configure, $(srcdir)/aclocal.m4): New rules.
9228         (AUTOHEADER): New variable.
9229         ($(srcdir)/cstamp-h.in): Use it.
9230
9231 2009-07-30  Michael Meissner  <meissner@linux.vnet.ibm.com>
9232             Pat Haugen  <pthaugen@us.ibm.com>
9233             Revital Eres <ERES@il.ibm.com>
9234
9235         * config/rs6000/vector.md (VEC_F): Add VSX support.
9236         (VEC_A): Ditto.
9237         (VEC_N): Ditto.
9238         (mov<mode>): Ditto.
9239         (vector_load_<mode>): Ditto.
9240         (vector_store_<mode>): Ditto.
9241         (vector GPR move split): Ditto.
9242         (vec_reload_and_plus_<mptrsize>): Ditto.
9243         (vec_reload_and_reg_<mptrsize>): Ditto.
9244         (add<mode>3): Ditto.
9245         (sub<mode>3): Ditto.
9246         (mul<mode>3): Ditto.
9247         (neg<mode>2): Ditto.
9248         (abs<mode>2): Ditto.
9249         (smin<mode>3): Ditto.
9250         (smax<mode>3): Ditto.
9251         (vector_eq<mode>): Ditto.
9252         (vector_gt<mode>): Ditto.
9253         (vector_ge<mode>): Ditto.
9254         (vector_gtu<mode>): Ditto.
9255         (vector_select_<mode>_uns): Ditto.
9256         (vector_eq_<mode>_p): Ditto.
9257         (vector_gt_<mode>_p): Ditto.
9258         (vector_ge_<mode>_p): Ditto.
9259         (vector_gtu_<mode>_p): Ditto.
9260         (cr6_test_for_zero): Ditto.
9261         (cr6_test_for_zero_reverse): Ditto.
9262         (cr6_test_for_lt): Ditto.
9263         (cr6_test_for_lt_reverse): Ditto.
9264         (xor<mode>3): Ditto.
9265         (ior<mode>3): Ditto.
9266         (and<mode>3): Ditto.
9267         (one_cmpl<mode>2): Ditto.
9268         (nor<mode>2): Ditto.
9269         (andc<mode>2): Ditto.
9270         (float<VEC_int<mode>2): Ditto.
9271         (unsigned_float<VEC_int><mode>2): Ditto.
9272         (fix_trunc<mode><VEC_int>2): Ditto.
9273         (fixuns_trunc<mode><VEC_int>2): Ditto.
9274         (vec_init<mode>):
9275         (vec_set<mode>): Ditto.
9276         (vec_extract<mode>): Ditto.
9277         (vec_interleave_highv4sf): Ditto.
9278         (vec_interleave_lowv4sf): Ditto.
9279         (vec_realign_load_<mode>): Ditto.
9280         (vec_shl_<mode>): Ditto.
9281         (vec_shr_<mode>): Ditto.
9282         (div<mode>3): New patterns for VSX.
9283         (vec_interleave_highv2df): Ditto.
9284         (vec_interleave_lowv2df): Ditto.
9285         (vec_pack_trunc_v2df): Ditto.
9286         (vec_pack_sfix_trunc_v2df): Ditto.
9287         (vec_pack_ufix_trunc_v2df): Ditto.
9288         (vec_unpacks_hi_v4sf): Ditto.
9289         (vec_unpacks_lo_v4sf): Ditto.
9290         (vec_unpacks_float_hi_v4si): Ditto.
9291         (vec_unpacks_float_lo_v4si): Ditto.
9292         (vec_unpacku_float_hi_v4si): Ditto.
9293         (vec_unpacku_float_lo_v4si): Ditto.
9294         (movmisalign<mode>): Ditto.
9295         (vector_ceil<mode>2): New patterns for vectorizing math library.
9296         (vector_floor<mode>2): Ditto.
9297         (vector_btrunc<mode>2): Ditto.
9298         (vector_copysign<mode>3): Ditto.
9299
9300         * config/rs6000/predicates.md (easy_vector_constant_msb): New
9301         predicate for setting the high bit in each word, used for copysign.
9302
9303         * config/rs6000/ppc-asm.h (f19): Whitespace.
9304         (f32-f63): Define if VSX.
9305         (v0-v31): Define if Altivec.
9306         (vs0-vs63): Define if VSX.
9307
9308         * config/rs6000/t-rs6000 (MD_INCLUDES): Add power7.md and vsx.md.
9309
9310         * config/rs6000/power7.md: New file, provide tuning parameters for
9311         -mcpu=power7.
9312
9313         * config/rs6000/rs6000-c.c (rs6000_macro_to_expand): Add VSX support.
9314         (rs6000_cpu_cpp_builtins): Ditto.
9315         (altivec_overloaded_builtins): Ditto.
9316         (altivec_resolve_overloaded_builtin): Ditto.
9317
9318         * config/rs6000/rs6000.opt (-mno-vectorize-builtins): Add new
9319         debug switch to disable vectorizing simple math builtin
9320         functions.
9321
9322         * config/rs6000/rs6000.c (rs6000_builtin_vectorized_function):
9323         Vectorize simple math builtin functions.
9324         (TARGET_VECTORIZE_BUILTIN_VECTORIZED_FUNCTION): Define target
9325         hook to vectorize math builtins.
9326         (rs6000_override_options): Enable -mvsx on -mcpu=power7.
9327         (rs6000_builtin_conversion): Add VSX/power7 support.
9328         (rs6000_builtin_vec_perm): Ditto.
9329         (vsplits_constant): Add support for loading up a vector constant
9330         with just the high bit set in each part.
9331         (rs6000_expand_vector_init): Add VSX/power7 support.
9332         (rs6000_expand_vector_set): Ditto.
9333         (rs6000_expand_vector_extract): Ditto.
9334         (rs6000_emit_move): Ditto.
9335         (bdesc_3arg): Ditto.
9336         (bdesc_2arg): Ditto.
9337         (bdesc_1arg): Ditto.
9338         (rs6000_expand_ternop_builtin): Ditto.
9339         (altivec_expand_builtin): Ditto.
9340         (rs6000_expand_unop_builtin): Ditto.
9341         (rs6000_init_builtins): Ditto.
9342         (altivec_init_builtins): Ditto.
9343         (builtin_function_type): Ditto.
9344         (rs6000_common_init_builtins): Ditto.
9345         (rs6000_handle_altivec_attribute); Ditto.
9346         (rs6000_mangle_type): Ditto.
9347         (rs6000_vector_mode_supported_p): Ditto.
9348         (rs6000_mode_dependent_address): Altivec addresses with AND -16
9349         are mode dependent.
9350
9351         * config/rs6000/vsx.md: New file for VSX support.
9352
9353         * config/rs6000/rs6000.h (EASY_VECTOR_MSB): New macro for
9354         identifing values with just the most significant bit set.
9355         (enum rs6000_builtins): Add builtins for VSX.  Add simple math
9356         vectorized builtins.
9357
9358         * config/rs6000/altivec.md (UNSPEC_VRFIP): Delete.
9359         (UNSPEC_VRFIM): Delete.
9360         (splitter for loading up vector with most significant bit): New
9361         splitter for vectorizing copysign.
9362         (altivec_vrfiz): Rename from altivec_fturncv4sf2.  Add support for
9363         vectorizing simple math functions.
9364         (altivec_vrfip): Add support for vectorizing simple math functions.
9365         (altivec_vrfim): Ditto.
9366         (altivec_copysign_v4sf3): New insn for Altivec copysign support.
9367
9368         * config/rs6000/rs6000.md (UNSPEC_BPERM): New constant.
9369         (power7.md, vsx.md): Include for power7 support.
9370         (copysigndf3): Use VSX instructions if -mvsx.
9371         (negdf2_fpr): Ditto.
9372         (absdf2_fpr): Ditto.
9373         (nabsdf2_fpr): Ditto.
9374         (adddf3_fpr): Ditto.
9375         (subdf3_fpr): Ditto.
9376         (muldf3_fpr): Ditto.
9377         (divdf3_fpr): Ditto.
9378         (fix_truncdfdi2_fpr): Ditto.
9379         (cmpdf_internal1): Ditto.
9380         (fred, fred_fpr): Convert into expander/insn to add VSX support.
9381         (btruncdf2, btruncdf2_fpr): Ditto.
9382         (ceildf2, ceildf2_fpr): Ditto.
9383         (floordf2, floordf2_fpr): Ditto.
9384         (floatdidf2, floatdidf2_fpr): Ditto.
9385         (fmadddf4_fpr): Name insn.  Use VSX instructions if -mvsx.
9386         (fmsubdf4_fpr): Ditto.
9387         (fnmadddf4_fpr_1): Ditto.
9388         (fnmadddf4_fpr_2): Ditto.
9389         (fnmsubdf4_fpr_1): Ditto.
9390         (fnmsubdf4_fpr_2): Ditto.
9391         (fixuns_truncdfdi2): Add expander for VSX support.
9392         (fix_truncdfdi2): Ditto.
9393         (fix_truncdfsi2): Ditto.
9394         (ftruncdf2): Ditto.
9395         (btruncsf2): Whitespace.
9396         (movdf_hardfloat32): Add support for VSX registers.
9397         (movdf_softfloat32): Ditto.
9398         (movdf_hardfloat64): Ditto.
9399         (movdf_hardfloat64_mfpgpr): Ditto.
9400         (movdf_softfloat64): Ditto.
9401         (movti splitters): Add check for vector registers supporting
9402         TImode in the future.
9403         (bpermd): Add power7 bpermd instruction.
9404
9405         * config/rs6000/altivec.h (vec_div): Define if VSX.
9406         (vec_mul): Ditto.
9407         (vec_msub): Ditto.
9408         (vec_nmadd): Ditto.
9409         (vec_nearbyint): Ditto.
9410         (vec_rint): Ditto.
9411         (vec_sqrt): Ditto.
9412         (all predicates): Use the generic builtin function, and not the V4SF
9413         specific function so that the predicates will work with VSX's V2DF.
9414         (vec_all_*): Ditto.
9415         (vec_any_*): Ditto.
9416
9417         * doc/extend.texi (PowerPC Altivec/VSX Built-in Functions):
9418         Document new VSX functions and types.
9419
9420         * doc/invoke.texi (PowerPc options): Document -mpopcntd, -mvsx
9421         switches.
9422
9423         * doc/md.texi (PowerPC constraints): Document "wd", "wf", "ws",
9424         "wa", and "j" constraints.  Modify "v" to talk about Altivec
9425         instead of just vector.
9426
9427 2009-07-30  Andrew MacLeod  <amacleod@redhat.com>
9428
9429         PR debug/26475
9430         * tree-into-ssa.c (insert_phi_nodes_for, rewrite_add_phi_arguments): Set
9431         location for phi arguments.
9432         (rewrite_update_phi_arguments): Find locations for reaching defs.
9433         * tree-ssa-threadupdate.c (create_edge_and_update_destination_phis):
9434         Add location to add_phi_arg calls.
9435         * tree-loop-districbution.c (update_phis_for_loop_copy): Add locations.
9436         * tree-ssa-loop-manip.c (create_iv, add_exit_phis_edge,
9437         split_loop_exit_edge, tree_transform_and_unroll_loop): Add locations.
9438         * tree-tailcall.c (add_successor_phi_arg, eliminate_tail_call,
9439         create_tailcall_accumulator, tree_optimize_tail_calls_1): Add locations.
9440         * tree.h (struct phi_arg_d): Add location_t to PHI arguments.
9441         * tree-phinodes.c (make_phi_node): Initialize location.
9442         (resize_phi_node): Initialize location to UNKNOWN_LOCATION.
9443         (add_phi_arg): Add location parameter.
9444         (remove_phi_arg_num): Move location when moving phi argument.
9445         * omp-low.c (expand_parallel_call, expand_omp_for_static_chunk): Set
9446         location.
9447         * tree-vect-loop-manip.c (slpeel_update_phis_for_duplicate_loop,
9448         slpeel_update_phi_nodes_for_guard1,
9449         slpeel_update_phi_nodes_for_guard2,
9450         slpeel_tree_duplicate_loop_to_edge_cfg, set_prologue_iterations,
9451         vect_loop_versioning): Set locations.
9452         * tree-parloops.c (create_phi_for_local_result,
9453         transform_to_exit_first_loop, create_parallel_loop): Add locations.
9454         * gimple-pretty-print.c (dump_gimple_phi): Dump lineno's if present.
9455         * tree-vect-loop.c (get_initial_def_for_induction,
9456         vect_create_epilog_for_reduction, vect_finalize_reduction): Add
9457         locations.
9458         * tree-flow-inline.h (gimple_phi_arg_location): New.  Return locus.
9459         (gimple_phi_arg_location_from_edge): New.  Return locus from an edge.
9460         (gimple_phi_arg_set_location): New.  Set locus.
9461         (gimple_phi_arg_has_location): New.  Check for locus.
9462         (redirect_edge_var_map_location): New.  Return locus from var_map.
9463         * tree-vect-data-refs.c (vect_setup_realignment): Set location.
9464         * tree-ssa-phiopt.c (conditional_replacement): Set locus when
9465         combining PHI arguments.
9466         (cond_store_replacement): Set location.
9467         * cfgexpand.c (gimple_assign_rhs_to_tree): Transfer locus if possible.
9468         * grpahite.c (add_loop_exit_phis, add_guard_exit_phis,
9469         scop_add_exit_phis_edge): Add locations.
9470         * tree-cfgcleanup.c (remove_forwarder_block,
9471         remove_forwarder_block_with_phi): Add locations.
9472         * tree-ssa-pre.c (insert_into_preds_of_block): Add locations.
9473         * tree-predcom.c (initialize_root_vars, initialize_root_vars_lm): Add
9474         locations.
9475         * tree-ssa-dce.c (forward_edge_to_pdom): Add locations.
9476         * tree-ssa.c (redirect_edge_var_map_add, ssa_redirect_edge,
9477         flush_pending_stmts): Add source location.
9478         * lambda-code.c (perfect_nestify): Maintain location stack with argument
9479         stack to preserve locations.
9480         * tree-vect-stmts.c (vectorizable_load): Add location.
9481         * tree-inline.c (copy_phis_for_bb): Copy locus.
9482         (setup_one_parameter): Add call locus to inlined parameter stmts.
9483         (initialize_inlined_parameters): Pass in call location as parameter
9484         assignment locus.
9485         (tree_function_versioning): Pass location to setup_one_parameter.
9486         * tree-ssa-phiprop.c (phiprop_insert_phi): Set locations.
9487         * tree-outof-ssa.c (struct _elim_graph): Add source_location vecs for
9488         copy and edge lists.
9489         (insert_partition_copy_on_edge, insert_value_copy_on_edge,
9490         insert_rtx_to_part_on_edge, insert_part_to_rtx_on_edge): Provide a
9491         locus parameter and override the stmt default if provided.
9492         (new_elim_graph, clear_elim_graph, delete_elim_graph,
9493         elim_graph_add_edge, elim_graph_remove_succ_edge,
9494         FOR_EACH_ELIM_GRAPH_SUCC, FOR_EACH_ELIM_GRAPH_PRED, eliminate_build,
9495         elim_forward, elim_unvisited_predecessor, elim_backward, elim_create,
9496         eliminate_phi):  Add locus info in elimination graph for each edge and
9497         value copy.
9498         (insert_backedge_copies): Copy locus if present.
9499         * tree-flow.h (struct _edge_var_map): Add locus field.
9500         * tree-switch_conversions.c (fix_phi_nodes): Add locations.
9501         * tree-cfg.c (reinstall_phi_args, gimple_make_forwarder_block,
9502         add_phi_args_after_copy_edge, gimple_lv_adjust_loop_header_phi): Add
9503         locations.
9504         * ipa-struct-reorg.c (make_edge_and_fix_phis_of_dest): Add locations.
9505
9506 2009-07-30  Martin Jambor  <mjambor@suse.cz>
9507
9508         PR tree-optimization/40570
9509         * ipa-inline.c (cgraph_decide_inlining): Watch out for dead single
9510         use inlining loops.
9511
9512 2009-07-30  Razya Ladelsky <razya@il.ibm.com>
9513
9514         * ssa-loop-manip.c: Include langhooks.h.
9515         (rewrite_phi_with_iv): New.
9516         (rewrite_all_phi_nodes_with_iv): New.
9517         (canonicalize_loop_ivs): Move here from tree-parloops.c.
9518         Remove reduction_list argument. Use rewrite_all_phi_nodes_with_iv.
9519         * tree-parloops.c (loop_parallel_p): Move out all conditions
9520         except dependency check.
9521         (canonicalize_loop_ivs): Move to tree-ssa-loop-manip.c.
9522         (gen_parallel_loop): Call canonicalize_loop_ivs without
9523         reduction_list argument.
9524         (build_new_reduction): New.
9525         (gather_scalar_reductions): New.
9526         (try_get_loop_niter): New.
9527         (try_create_reduction_list): New.
9528         (parallleize_loops): Change the parallel conditions check.
9529         * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
9530         * Makefile.in (tree-ssa-loop-manip.o): Add langhooks.h dependency.
9531
9532 2009-07-30  Dave Korn  <dave.korn.cygwin@gmail.com>
9533
9534         * opt-functions.awk (opt_args): Allow argument to be enclosed in
9535         curly braces.
9536         * doc/options.texi (Option properties):  Mention new quoting syntax.
9537
9538 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
9539
9540         * config/alpha/alpha.c (alpha_start_function):
9541         Handle VMS_DEBUG_MAIN_POINTER
9542         * config/alpha/vms.h (VMS_DEBUG_MAIN_POINTER): Define new macro.
9543         * doc/invoke.texi: Document -mdebug-main switch.
9544
9545 2009-07-29  Richard Henderson  <rth@redhat.com>
9546
9547         * cgraph.c (cgraph_set_call_stmt_including_clones): Tidy.
9548         (cgraph_create_edge_including_clones): Likewise.
9549         * tree-inline.c (copy_bb): Operate on the correct edges
9550         when updating the callgraph.
9551
9552 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
9553
9554         * config/alpha/vms-cc.c: Deleted.
9555         * config/alpha/vms-ld.c: Deleted.
9556         * config/alpha/t-vms64: Moved to config/vms
9557         * config/alpha/vms-crt0-64.c: Moved to config/vms
9558         * config/alpha/vms-crt0.c: Moved to config/vms
9559         * config/alpha/vms-psxcrt0-64.c: Moved to config/vms
9560         * config/alpha/vms-psxcrt0.c: Moved to config/vms
9561         * config/alpha/xm-vms.h: Moved to config/vms
9562         * config/alpha/x-vms: Moved to config/vms
9563         * config/alpha/t-vms (vcrt0.o, pcrt0.o): Move rules to new file
9564         config/vms/t-vms.
9565         * config/vms/t-vms: Moved here from config/alpha. Alpha specific
9566         parts removed. (STMP_FIXPROTO, STMP_FIXINC, LIMITS_H_TEST): Set.
9567         (version): Set.
9568         * config/vms/t-vms64: Moved here from config/alpha
9569         * config/vms/vms-crt0-64.c: Moved here from config/alpha.
9570         (argc,argv,envp): Enforce 32bit malloc'ing.
9571         * config/vms/vms-psxcrt0-64.c: Likewise.
9572         * config/vms/vms-crt0.c: Moved here from config/alpha.
9573         * config/vms/vms-psxcrt0.c: Likewise.
9574         * config/vms/vms-crtl-64.h: New file.
9575         * config/vms/vms-crtl.h: New file.
9576         * config/vms/vms.opt: New file.
9577         * config/vms/xm-vms64.h: New file.
9578         * config/vms/xm-vms.h: Moved here from config/alpha.
9579         (STANARD_EXEC_PREFIX, STANDARD_STARTFILE_PREFIX, STANDARD_INCLUDE_DIR):
9580         Set.
9581         * config/vms/x-vms: Moved here from config/alpha.
9582         (version, VMS_EXTRA_PARTS): Moved to t-vms.
9583         (vms-ld.o, vms-cc.o): Removed.
9584         (LN, LN_S, USE_COLLECT2, POD2MAN): Set.
9585
9586 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
9587
9588         * dwarf2out.c (add_name_and_src_coords_attributes): Push on the
9589         correct stack (obvious VMS fix).
9590
9591 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
9592
9593         * dwarf2out.c (output_file_names): Output VMS style file name, size,
9594         date, version info if VMS_DEBUGGING_INFO defined.
9595         * vmsdgbout.c (vms_file_stats_name): New functon. VMS style file name,
9596         size, date calculating code moved here.
9597
9598 2009-07-29  Paul Brook  <paul@codesourcery.com>
9599
9600         * config/arm/lib1funcs.asm (clear_cache): Use ARM_FUNC_START and
9601         do_push/do_pop.
9602
9603 2009-07-29  Uros Bizjak  <ubizjak@gmail.com>
9604
9605         PR target/40577
9606         * config/alpha/alpha.c (alpha_expand_unaligned_store): Convert src
9607         to DImode when generating insq_le insn.
9608
9609 2009-07-28  Douglas B Rupp  <rupp@gnat.com>
9610
9611         * dwarf2out.c (DWARF2_INDIRECT_STRING_SUPPORT_MISSING_ON_TARGET):
9612         New macro set for VMS_DEBUGGGING_INFO.
9613         (AT_string_form): Use it.
9614
9615 2009-07-28  DJ Delorie  <dj@redhat.com>
9616
9617         * config/mep/mep.c (vtext_section): New.
9618         (vftext_section): New.
9619         (ftext_section): New.
9620         (mep_select_section): Add support for functions.
9621         (mep_unique_section): Likewise.
9622         (mep_asm_init_sections): Likewise.
9623         (mep_encode_section_info): Remove it from here.
9624
9625         * config/mep/mep.h (USE_SELECT_SECTION_FOR_FUNCTIONS): Define.
9626
9627 2009-07-28  Paolo Bonzini  <bonzinI@gnu.org>
9628
9629         * tree.h (TREE_DEPRECATED): Document it is used for types too.
9630         (TYPE_VECTOR_OPAQUE): Use default_def_flag
9631
9632 2009-07-28  Douglas B Rupp  <rupp@gnat.com>
9633
9634         * dwarf2out.c (output_file_names): Test new macro
9635         DWARF2_DIR_SHOULD_END_WITH_SEPARATOR.
9636         (add_comp_dir_attribute): Likewise.
9637
9638 2009-07-28  Kai Tietz  <kai.tietz@onevision.com>
9639
9640         * config/i386/mingw-w64.h (LINK_SPEC): Add
9641         separating space between commands.
9642
9643 2009-07-28  Jan Hubicka  <jh@suse.cz>
9644
9645         PR tree-optimization/40759
9646         * tree-ssa-dce.c (mark_virtual_phi_result_for_renaming): Mark all uses
9647         for renaming.
9648
9649 2009-07-27  DJ Delorie  <dj@redhat.com>
9650
9651         * config/mep/mep.c (mep_expand_builtin_saveregs): Make sure 64-bit
9652         types are dword-aligned.
9653         (mep_expand_va_start): Likewise.
9654
9655 2009-07-27  Olivier Hainque  <hainque@adacore.com>
9656             Douglas B Rupp  <rupp@gnat.com>
9657
9658         * convert.c (convert_to_pointer): Don't assume the target
9659         pointer type is POINTER_SIZE long. Fetch its precision instead.
9660
9661 2009-07-27  Douglas B Rupp  <rupp@gnat.com>
9662
9663         * system.h (fopen): Undefine if macro.
9664
9665 2009-07-27  Jakub Jelinek  <jakub@redhat.com>
9666
9667         * dwarf2out.c (output_cfi_p): Removed.
9668         (output_cfis): New function.
9669         (output_fde): New function, split from output_call_frame_info.
9670         (output_call_frame_info): Use it.
9671         (dwarf2out_switch_text_section): Use output_cfis.
9672
9673 2009-07-24  Kai Tietz  <kai.tietz@onevision.com>
9674
9675         * config/i386/cygming.h (DWARF2_UNWIND_INFO): Error build when
9676         TARGET_BI_ARCH is specified without enabling SJLJ.
9677         * config/i386/mingw32.h (MD_UNWIND_SUPPORT): Define MD_UNWIND_SUPPORT,
9678         if TARGET_64BIT and TARGET_BI_ARCH aren't defined.
9679
9680 2009-07-26  Mikael Pettersson <mikpe@it.uu.se>
9681
9682         * arm.md (negdi2): Use DImode if forcing a value into a register.
9683
9684 2009-07-26  Ira Rosen  <irar@il.ibm.com>
9685
9686         PR tree-optimization/40801
9687         * tree-vect-stmts.c (vectorizable_call): Get previous copy
9688         of vector operand from the previous copy of vector statement.
9689         Pass the correct definition type value to
9690         vect_get_vec_def_for_stmt_copy().
9691
9692 2009-07-25  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
9693
9694         * collect2.c (scan_libraries): Use CONST_CAST2 to perform char ** to
9695         const char ** conversion.
9696
9697 2009-07-25 David Daney <ddaney@caviumnetworks.com>
9698
9699         * system.h (gcc_assert): Invoke __builtin_unreachable() instead of
9700         fancy_abort() if !ENABLE_ASSERT_CHECKING.
9701         (gcc_unreachable): Invoke __builtin_unreachable() if
9702         !ENABLE_ASSERT_CHECKING.
9703
9704 2009-07-25  David Daney  <ddaney@caviumnetworks.com>
9705
9706         PR rtl-optimization/40445
9707         * emit-rtl.c (next_nonnote_insn_bb): New function.
9708         * rtl.h (next_nonnote_insn_bb): Declare new function.
9709         * cfgcleanup.c (try_optimize_cfg): Don't remove an empty block
9710         with no successors that is the successor of the ENTRY_BLOCK.
9711         Continue from the top after removing an empty fallthrough block.
9712         * cfgrtl.c (get_last_bb_insn): Call next_nonnote_insn_bb instead
9713         of next_nonnote_insn.
9714
9715 2009-07-25  David Daney  <ddaney@caviumnetworks.com>
9716
9717         * cfgcleanup.c (old_insns_match_p): Handle the case of empty blocks.
9718
9719 2009-07-25  Martin Jambor  <mjambor@suse.cz>
9720
9721         * c-common.c (c_common_attribute_table): New element for noclone.
9722         (handle_noclone_attribute): New function. Forward-declare.
9723         * tree-inline.c (tree_versionable_function_p): Check for noclone
9724         attribute.
9725         * doc/extend.texi (Labels as Values): Document need for noclone.
9726         (Function Attributes): Document noclone attribute.
9727
9728 2009-07-25  Jakub Jelinek  <jakub@redhat.com>
9729
9730         PR rtl-optimization/34999
9731         * dwarf2out.c (struct dw_fde_struct): Add dw_fde_switch_cfi
9732         and dw_fde_switched_cold_to_hot fields.
9733         (output_cfi_p): New function.
9734         (output_call_frame_info): If fde->dw_fde_switched_sections,
9735         output 2 FDEs instead of one with corrupted header.
9736         (dwarf2out_do_cfi_startproc): New function.
9737         (dwarf2out_begin_prologue): Use it.  Initialize fde->dw_fde_switch_cfi
9738         and fde->dw_fde_switched_cold_to_hot.
9739         (dwarf2out_switch_text_section): Compute
9740         fde->dw_fde_switched_cold_to_hot.  Switch to new text section here.
9741         If dwarf2out_do_cfi_asm, emit .cfi_endproc before it and call
9742         dwarf2out_do_cfi_startproc plus emit again currently active CFI insns.
9743         Otherwise, compute fde->dw_fde_switch_cfi.
9744
9745 2009-07-24  Cary Coutant  <ccoutant@google.com>
9746
9747         * tree-cfg.c (assign_discriminator): Add explicit parentheses.
9748
9749 2009-07-24  Cary Coutant  <ccoutant@google.com>
9750
9751         * cfghooks.c (split_block): Copy discriminator to new block.
9752         * tree-cfg.c (assign_discriminator): Check location of last
9753         instruction in block as well as first.
9754
9755 2009-07-24  Uros Bizjak  <ubizjak@gmail.com>
9756
9757         * config/i386/linux.c: Use fputs or putc instead of fprintf
9758         where appropriate.
9759         * config/i386/gas.h: Ditto.
9760         * config/i386/x86-64.h: Ditto.
9761         * config/i386/att.h: Ditto.
9762
9763 2009-07-24  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
9764
9765         * expmed.c (emit_store_flag): Use a recursive call to optimize the
9766         xor case.
9767
9768 2009-07-24  Martin Jambor  <mjambor@suse.cz>
9769
9770         * ipa-prop.h (struct ipa_node_params): New flag node_enqued.
9771         (ipa_push_func_to_list_1): Declare.
9772         (ipa_push_func_to_list): New function.
9773
9774         * ipa-prop.c (ipa_push_func_to_list_1): New function.
9775         (ipa_init_func_list): Call ipa_push_func_to_list_1.
9776         (ipa_push_func_to_list): Removed.
9777         (ipa_pop_func_from_list): Clear node_enqueued flag.
9778
9779 2009-07-24  Andreas Krebbel  <krebbel1@de.ibm.com>
9780
9781         * config/s390/s390.c (override_options): Default
9782         max-unrolled-insns to 100 for z10 tuning.
9783
9784 2009-07-24  Tobias Grosser  <grosser@fim.uni-passau.de>
9785
9786         * Makefile.in (TREE_DATA_REF_H, tree-vrp.o, tree-cfg.o, tree-if-conv.o
9787         tree-ssa-loop.o, tree-ssa-loop-niter.o, tree-ssa-loop-ivcanon.o,
9788         tree-ssa-loop-prefetch.o, tree-predcom.o, tree-affine.o,
9789         tree-scalar-evolution.o, tree-data-ref.o, tree-vect-loop.o,
9790         tree-vect-data-refs.o, tree-loop-linear.o, tree-loop-distribution.o
9791         tree-parloops.o, tree-pretty-printer.o, fold-const.o, tree-ssa-dce.o,
9792         lambda-code.o, params.o): Cleanup use of SCEV_H and TREE_DATA_REF_H.
9793
9794 2009-07-24  Kai Tietz  <kai.tietz@onevision.com>
9795
9796         * config/i386/mingw-w64.h (STANDARD_INCLUDE_DIR): Remove and
9797         use default set in mingw32.h header.
9798         * config/i386/mingw32.h (STANDARD_INCLUDE_DIR): Use for 32-bit and
9799         64-bit /mingw/include path.
9800         (STANDARD_STARTFILE_PREFIX_1): Use for 32-bit and 64-bit /mingw/lib
9801         path.
9802
9803 2009-07-23  Neil Vachharajani  <nvachhar@google.com>
9804
9805         PR rtl-optimization/40209
9806         * loop-iv.c (iv_analysis_loop_init): Call df_note_add_problem.
9807
9808 2009-07-23  Uros Bizjak  <ubizjak@gmail.com>
9809
9810         * config/i386/i386.c: Use ASM_LONG instead of .long.  Concatenate
9811         ASM_LONG, LPREFIX, MCOUNT_NAME and PROFILE_COUNT_REGISTER strings
9812         with the rest of string where appropriate.  Use fputs or putc
9813         instead of fprintf where appropriate.
9814
9815 2009-07-22  Michael Meissner  <meissner@linux.vnet.ibm.com>
9816             Pat Haugen  <pthaugen@us.ibm.com>
9817             Revital Eres <ERES@il.ibm.com>
9818
9819         * config/rs6000/vector.md: New file.  Move most of the vector
9820         expander support here from altivec.md to allow for the VSX vector
9821         unit in the future.  Add support for secondary_reload patterns.
9822         Rewrite the patterns for vector comparison, and vector comparison
9823         predicate instructions so that the RTL expresses the desired
9824         behavior, instead of using unspec.
9825
9826         * config/rs6000/constraints.md ("f" constraint): Use
9827         rs6000_constraints to hold the precalculated register class.
9828         ("d" constraint): Ditto.
9829         ("wd" constraint): New constraint for VSX.
9830         ("wf" constraint): Ditto.
9831         ("ws" constraint): Ditto.
9832         ("wa" constraint): Ditto.
9833         ("wZ" constraint): Ditto.
9834         ("j" constraint): Ditto.
9835
9836         * config/rs6000/predicates.md (vsx_register_operand): New
9837         predicate for VSX.
9838         (vfloat_operand): New predicate for vector.md.
9839         (vint_operand): Ditto.
9840         (vlogical_operand): Ditto.
9841         (easy_fp_constant): If VSX, 0.0 is an easy constant.
9842         (easy_vector_constant): Add VSX support.
9843         (altivec_indexed_or_indirect_operand): New predicate for
9844         recognizing Altivec style memory references with AND -16.
9845
9846         * config/rs6000/rs6000.c (rs6000_vector_reload): New static global
9847         for vector secondary reload support.
9848         (rs6000_vector_reg_class): Delete, replacing it with
9849         rs6000_constraints.
9850         (rs6000_vsx_reg_class): Ditto.
9851         (rs6000_constraints): New array to hold the register classes of
9852         each of the register constraints that can vary at runtime.
9853         (builtin_mode_to_type): New static array for builtin function type
9854         creation.
9855         (builtin_hash_table): New static hash table for builtin function
9856         type creation.
9857         (TARGET_SECONDARY_RELOAD): Define target hook.
9858         (TARGET_IRA_COVER_CLASSES): Ditto.
9859         (rs6000_hard_regno_nregs_internal): If -mvsx, floating point
9860         registers are 128 bits if VSX memory reference instructions are used.
9861         (rs6000_hard_regno_mode_ok): For VSX, only check if the VSX memory
9862         unit is being used.
9863         (rs6000_debug_vector_unit): Move into rs6000_debug_reg_global.
9864         (rs6000_debug_reg_global): Move -mdebug=reg statements here.
9865         Print several of the scheduling related parameters.
9866         (rs6000_init_hard_regno_mode_ok): Switch to putting constraints in
9867         rs6000_constraints instead of rs6000_vector_reg_class.  Move
9868         -mdebug=reg code to rs6000_debug_reg_global.  Add support for
9869         -mvsx-align-128 debug switch.  Drop testing float_p if VSX or
9870         Altivec.  Add VSX support.  Setup for secondary reload support on
9871         Altivec/VSX registers.
9872         (rs6000_override_options): Make power7 set the scheduling groups
9873         like the power5.  Add support for new debug switches to override
9874         the scheduling defaults.  Temporarily disable -mcpu=power7 from
9875         setting -mvsx.  Add support for debug switches -malways-hint,
9876         -msched-groups, and -malign-branch-targets.
9877         (rs6000_buitlin_conversion): Add support for returning unsigned
9878         vector conversion functions to fix regressions due to stricter
9879         type checking.
9880         (rs6000_builtin_mul_widen_even): Ditto.
9881         (rs6000_builtin_mul_widen_odd): Ditto.
9882         (rs6000_builtin_vec_perm): Ditto.
9883         (rs6000_vec_const_move): On VSX, use xxlxor to clear register.
9884         (rs6000_expand_vector_init): Initial VSX support for using xxlxor
9885         to zero a register.
9886         (rs6000_emit_move): Fixup invalid const symbol_ref+reg that is
9887         generated upstream.
9888         (bdesc_3arg): Add builtins for unsigned types.  Add builtins for
9889         VSX types for bit operations.  Changes to accomidate vector.md.
9890         (bdesc_2arg): Ditto.
9891         (bdesc_1arg): Ditto.
9892         (struct builtin_description_predicates): Rewrite predicate
9893         handling so that RTL describes the operation, instead of passing
9894         the instruction to be used as a string argument.
9895         (bdesc_altivec_preds): Ditto.
9896         (altivec_expand_predicate_builtin): Ditto.
9897         (altivec_expand_builtin): Ditto.
9898         (rs6000_expand_ternop_builtin): Use a switch instead of an if
9899         statement for vsldoi support.
9900         (altivec_expand_ld_builtin): Change to use new names from vector.md.
9901         (altivec_expand_st_builtin): Ditto.
9902         (paired_expand_builtin): Whitespace changes.
9903         (rs6000_init_builtins): Add V2DF/V2DI types.  Initialize the
9904         builtin_mode_to_type table for secondary reload.  Call
9905         builtin_function_type to build random builtin functions.
9906         (altivec_init_builtins): Change to use builtin_function_type to
9907         create builtin function types dynamically as we need them.
9908         (builtin_hash_function): New support for hashing the tree types
9909         for builtin function as we need it, rather than trying to build
9910         all of the trees that we need.  Add initial preliminary VSX support.
9911         (builtin_function_type): Ditto.
9912         (builtin_function_eq): Ditto.
9913         (builtin_hash_struct): Ditto.
9914         (rs6000_init_builtins): Ditto.
9915         (rs6000_common_init_builtins): Ditto.
9916         (altivec_init_builtins): Ditto.
9917         (rs6000_common_init_builtins): Ditto.
9918         (enum reload_reg_type): New enum for simplifing reg classes.
9919         (rs6000_reload_register_type): Simplify register classes into GPR,
9920         Vector, and other registers.  Altivec and VSX addresses in reload.
9921         (rs6000_secondary_reload_inner): Ditto.
9922         (rs6000_ira_cover_classes): New target hook, that returns the
9923         appropriate cover classes, based on -mvsx being used or not.
9924         (rs6000_secondary_reload_class): Add VSX support.
9925         (get_vec_cmp_insn): Delete, rewrite vector conditionals.
9926         (get_vsel_insn): Ditto.
9927         (rs6000_emit_vector_compare): Rewrite vector conditional support
9928         so that where we can, we use RTL operators, instead of blindly use
9929         UNSPEC.
9930         (rs6000_emit_vector_select): Ditto.
9931         (rs6000_emit_vector_cond_expr): Ditto.
9932         (rs6000_emit_minmax): Directly generate min/max under altivec, vsx.
9933         (create_TOC_reference): Add -mdebug=addr support.
9934         (emit_frame_save): VSX loads/stores need register indexed addressing.
9935
9936         * config/rs6000/rs6000.md: Include vector.md.
9937
9938         * config/rs6000/t-rs6000 (MD_INCLUDES): Add vector.md.
9939
9940         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
9941         support for V2DI, V2DF in logical, permute, select operations.
9942
9943         * config/rs6000/rs6000.opt (-mvsx-scalar-double): Add new debug
9944         switch for vsx/power7.
9945         (-mvsx-scalar-memory): Ditto.
9946         (-mvsx-align-128): Ditto.
9947         (-mallow-movmisalign): Ditto.
9948         (-mallow-df-permute): Ditto.
9949         (-msched-groups): Ditto.
9950         (-malways-hint): Ditto.
9951         (-malign-branch-targets): Ditto.
9952
9953         * config/rs6000/rs6000.h (IRA_COVER_CLASSES): Delete, use target
9954         hook instead.
9955         (IRA_COVER_CLASSES_PRE_VSX): Cover classes if not -mvsx.
9956         (IRA_COVER_CLASSES_VSX): Cover classes if -mvsx.
9957         (rs6000_vector_reg_class): Delete.
9958         (rs6000_vsx_reg_class): Ditto.
9959         (enum rs6000_reg_class_enum): New enum for the constraints that
9960         vary based on target switches.
9961         (rs6000_constraints): New array to hold the register class for all
9962         of the register constraints that vary based on the switches used.
9963         (ALTIVEC_BUILTIN_*_UNS): Add unsigned builtin functions.
9964         (enum rs6000_builtins): Add unsigned varients for the builtin
9965         declarations returned by target hooks for expanding multiplies,
9966         select, and permute operations.  Add VSX builtins.
9967         (enum rs6000_builtin_type_index): Add entries for VSX.
9968         (V2DI_type_node): Ditto.
9969         (V2DF_type_node): Ditto.
9970         (unsigned_V2DI_type_node): Ditto.
9971         (bool_long_type_node): Ditto.
9972         (intDI_type_internal_node): Ditto.
9973         (uintDI_type_internal_node): Ditto.
9974         (double_type_internal_node): Ditto.
9975
9976         * config/rs6000/altivec.md (whole file): Move all expanders to
9977         vector.md from altivec.md.  Rename insn matching functions to be
9978         altivec_foo.
9979         (UNSPEC_VCMP*): Delete, rewrite vector comparisons.
9980         (altivec_vcmp*): Ditto.
9981         (UNSPEC_VPERM_UNS): New, add for unsigned types using vperm.
9982         (VM): New iterator for moves that includes the VSX types.
9983         (altivec_vperm_<mode>): Add VSX types.  Add unsigned types.
9984         (altivec_vperm_<mode>_uns): New, for unsigned types.
9985         (altivec_vsel_*): Rewrite vector comparisons and predicate builtins.
9986         (altivec_eq<mode>): Ditto.
9987         (altivec_gt<mode>): Ditto.
9988         (altivec_gtu<mode>): Ditto.
9989         (altivec_eqv4sf): Ditto.
9990         (altivec_gev4sf): Ditto.
9991         (altivec_gtv4sf): Ditto.
9992         (altivec_vcmpbfp_p): Ditto.
9993
9994 2009-07-23  Richard Earnshaw  <rearnsha@arm.com>
9995
9996         * arm.md (split for ior/xor with shift and zero-extend): Cast op3 to
9997         unsigned HWI.
9998
9999 2009-07-23  Uros Bizjak  <ubizjak@gmail.com>
10000
10001         PR target/40832
10002         * config/i386/i386.c (output_387_ffreep): Rewrite to use
10003         ASM_SHORT instead of .word.
10004         * config/i386/i386.md (*tls_global_dynamic_64): Use ASM_SHORT
10005         instead of .word in asm template.
10006
10007 2009-07-22  Vladimir Makarov  <vmakarov@redhat.com>
10008
10009         PR target/37488
10010         * ira-lives.c (bb_has_abnormal_call_pred): New function.
10011         (process_bb_node_lives): Use it.
10012
10013         * ira.c (setup_cover_and_important_classes): Don't setup
10014         ira_important_class_nums.  Add cover classes to the end of
10015         important classes.
10016         (cover_class_order, comp_reg_classes_func, reorder_important_classes):
10017         New.
10018         (find_reg_class_closure): Use reorder_important_classes.
10019
10020         * config/i386/i386.h (IRA_COVER_CLASSES): Remove.
10021
10022         * config/i386/i386.c (i386_ira_cover_classes): New function.
10023         (TARGET_IRA_COVER_CLASSES): Redefine.
10024
10025         * doc/tm.texi (TARGET_IRA_COVER_CLASSES): Add a comment about
10026         importance of order of cover classes in the array.
10027
10028 2009-07-22  Diego Novillo  <dnovillo@google.com>
10029
10030         * tree-pass.h (TDF_EH): Define.
10031         * gimple-pretty-print.c (dump_gimple_stmt): If FLAGS
10032         contains TDF_EH, print the EH region number holding GS.
10033         * tree-dump.c (dump_options): Add "eh".
10034         * doc/invoke.texi: Document it.
10035
10036 2009-07-22  Doug Kwan  <dougkwan@google.com>
10037
10038         * config/arm/arm.md (subdi3) Copy non-reg values to DImode registers.
10039
10040 2009-07-22  Michael Matz  <matz@suse.de>
10041
10042         PR tree-optimization/35229
10043         PR tree-optimization/39300
10044
10045         * tree-ssa-pre.c (includes): Include tree-scalar-evolution.h.
10046         (inhibit_phi_insertion): New function.
10047         (insert_into_preds_of_block): Call it for REFERENCEs.
10048         (init_pre): Initialize and finalize scalar evolutions.
10049         * Makefile.in (tree-ssa-pre.o): Depend on tree-scalar-evolution.h .
10050
10051 2009-07-22  Uros Bizjak  <ubizjak@gmail.com>
10052
10053         * config/i386/predicates.md (zero_extended_scalar_load_operand):
10054         Use CONST_VECTOR_NUNITS to determine number of elements.
10055
10056 2009-07-22  Andreas Krebbel  <krebbel1@de.ibm.com>
10057
10058         * config/s390/constraints.md (ZQ, ZR, ZS, ZT): New constraints.
10059         (U, W): Constraints are now deprecated and will be removed if we
10060         run out of letters.
10061         * config/s390/s390.md (U, W): Replaced with ZQZR, ZSZT throughout
10062         the file.
10063         ("prefetch"): Add the stcmh instruction for prefetching.
10064         * config/s390/s390.c (s390_symref_operand_p): Function moved. No
10065         changes.
10066         (s390_short_displacement): Return always true if compiling for
10067         machines not providing the long displacement facility.
10068         (s390_mem_constraint): Support the new constraint letter Z.
10069         (s390_check_qrst_address): New function.
10070
10071 2009-07-21  DJ Delorie  <dj@redhat.com>
10072
10073         * config/mep/mep.c (mep_legitimize_arg): Leave control registers
10074         alone too.
10075
10076 2009-07-21  Jason Merrill  <jason@redhat.com>
10077
10078         * c-common.c (max_tinst_depth): Increase default to 1024.
10079
10080 2009-07-21  Uros Bizjak  <ubizjak@gmail.com>
10081
10082         * config/i386/sse.md (vec_unpacku_float_hi_v4si): New expander.
10083         (vec_unpacku_float_lo_v4si): Ditto.
10084
10085 2009-07-21  Uros Bizjak  <ubizjak@gmail.com>
10086
10087         PR target/40811
10088         * config/i386/sse.md (sse2_cvtudq2ps): New expander.
10089         (enum ix86_builtins): Add IX86_BUILTIN_CVTUDQ2PS.
10090         (builtin_description): Add __builtin_ia32_cvtudq2ps.
10091         (ix86_vectorize_builtin_conversion): Handle IX86_BUILTIN_CVTUDQ2PS.
10092
10093 2009-07-21  Jakub Jelinek  <jakub@redhat.com>
10094
10095         PR tree-optimization/40813
10096         * tree-inline.c (copy_bb): Regimplify RHS after last stmt, not before
10097         it.
10098
10099 2009-07-21  Kaz Kojima  <kkojima@gcc.gnu.org>
10100
10101         * config/sh/sh.c (sh_gimplify_va_arg_expr): Wrap the result
10102         with a NOP_EXPR if needed.
10103
10104 2009-07-21  Paul Brook <paul@codesourcery.com>
10105
10106         * tree-vectorizer.c (increase_alignment): Handle nested arrays.
10107         Terminate debug dump with newline.
10108
10109 2009-07-20  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
10110
10111         * pa.c (compute_zdepwi_operands): Limit deposit length to 32 - lsb.
10112         Cast "1" to unsigned HOST_WIDE_INT.
10113         (compute_zdepdi_operands): Limit maximum length to 64 bits.  Limit
10114         deposit length to the maximum length - lsb.  Extend length if
10115         HOST_BITS_PER_WIDE_INT is 32.
10116
10117 2009-07-20  Olatunji Ruwase <tjruwase@google.com>
10118
10119         * cgraph.h (constant_pool_htab): New function.
10120         (constant_descriptor_tree): Move from varasm.c.
10121         * varasm.c (constant_pool_htab): New function.
10122         (constant_descriptor_tree): Move to cgraph.h.
10123
10124 2009-07-20  Olatunji Ruwase  <tjruwase@google.com>
10125
10126         * toplev.c: Invoke FINISH_UNIT callbacks before call to finalize().
10127
10128 2009-07-20  Shujing Zhao  <pearly.zhao@oracle.com>
10129
10130         * Makefile.in (TREE_INLINE_H, tree-inline.o, cgraph.o): Remove
10131         $(VARRAY_H).
10132
10133 2009-07-20  Xinliang David Li  <davidxl@google.com>
10134
10135         * dbgcnt.c (dbg_cnt_set_limit_by_name): Add length check.
10136
10137 2009-07-20  Adam Nemet  <anemet@caviumnetworks.com>
10138
10139         * config/mips/mips.md (move_type): Add arith.
10140         (type): Handle arith.
10141         (zero_extendsidi2): Rename this into ...
10142         (*zero_extendsidi2): ... this.  Don't match if ISA_HAS_EXT_INS.
10143         (zero_extendsidi2): New expander.
10144         (*zero_extendsidi2_dext): New pattern.
10145
10146 2009-07-20  Nick Clifton  <nickc@redhat.com>
10147
10148         * config.gcc (mips64-*-*): Add definition of tm_defines in order
10149         to set MIPS_ABI_DEFAULT.
10150         * config/mips/vr.h (MIPS_ABI_DEFAULT): Remove definition.
10151
10152 2009-07-20  Jakub Jelinek  <jakub@redhat.com>
10153
10154         * tree-object-size.c (addr_object_size): Handle unions with
10155         array in it as last field of structs in __bos (, 1) as __bos (, 0).
10156
10157         PR tree-optimization/40792
10158         * tree.c (build_function_type_skip_args): Remove bogus assert.
10159
10160 2009-07-20  Jan Hubicka  <jh@suse.cz>
10161             Martin Jambor  <mjambor@suse.cz>
10162
10163         * cgraph.h (combined_args_to_skip): New field.
10164         * cgraph.c (cgraph_create_virtual_clone): Properly handle
10165         combined_args_to_skip and args_to_skip.
10166         * tree-inline.c (update_clone_info): New function.
10167         (tree_function_versioning): Call update_clone_info.
10168         * cgraphunit.c: (cgraph_materialize_clone): Dump materialized
10169         functions.
10170         (cgraph_materialize_all_clones): More extensive dumping, working
10171         with combined_args_to_skip rather than args_to_skip.
10172
10173 2009-07-20  Ira Rosen  <irar@il.ibm.com>
10174
10175         * tree-vectorizer.h (vectorizable_condition): Add parameters.
10176         * tree-vect-loop.c (vect_is_simple_reduction): Support COND_EXPR.
10177         (get_initial_def_for_reduction): Likewise.
10178         (vectorizable_reduction): Skip the check of first operand in case
10179         of COND_EXPR. Add check that it is outer loop vectorization if
10180         nested cycle was detected. Call vectorizable_condition() for
10181         COND_EXPR. If reduction epilogue cannot be created do not fail for
10182         nested cycles (if it is not double reduction). Assert that there
10183         is only one type in the loop in case of COND_EXPR. Call
10184         vectorizable_condition() to vectorize COND_EXPR.
10185         * tree-vect-stmts.c (vectorizable_condition): Update comment.
10186         Add parameters. Allow nested cycles if called from
10187         vectorizable_reduction(). Use reduction vector variable if provided.
10188         (vect_analyze_stmt): Call vectorizable_reduction() before
10189         vectorizable_condition().
10190         (vect_transform_stmt): Update call to vectorizable_condition().
10191
10192 2009-07-20  Christian Bruel  <christian.bruel@st.com>
10193
10194         * config/sh/sh.opt (-mfmovd): Resurrect and document.
10195         * doc/invoke.texi (-mfmovd): Likewise.
10196         * config/sh/sh.h (TARGET_FMOVD, MASK_FMOVD): Remove default setting.
10197
10198 2009-07-20  Jan Hubicka  <jh@suse.cz>
10199
10200         * tree-ssa-dce.c (remove_dead_phis): Only look for abnormal PHIs
10201         when handling SSA name.
10202
10203 2009-07-19  Jan Hubicka  <jh@suse.cz>
10204
10205         PR tree-optimization/40676
10206         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Do renaming on all
10207         virtual PHIs in empty BBs.
10208
10209 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
10210
10211         * combine.c (make_compound_operation) <SUBREG>: If force_to_mode
10212         re-expanded the compound use gen_lowpart instead to convert to the
10213         desired mode.
10214
10215 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
10216
10217         * combine.c (try_widen_shift_mode): Add COUNT, OUTER_CODE and
10218         OUTER_CONST arguments.
10219         <LSHIFTRT>: Use them to allow widening if the bits shifted in from
10220         the new wider mode will be masked off.
10221         (simplify_shift_const_1): Adjust calls to try_widen_shift_mode.
10222
10223 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
10224
10225         * combine.c (try_widen_shift_mode) <LSHIFTRT>: Allow widening if the
10226         high-order bits are zero.
10227
10228 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
10229
10230         * combine.c (simplify_shift_const_1): Split code to determine
10231         shift_mode into ...
10232         (try_widen_shift_mode): ... here.  Allow widening for ASHIFTRT if the
10233         new bits shifted in are identical to the old sign bit.
10234
10235 2009-07-18  Richard Guenther  <rguenther@suse.de>
10236
10237         PR c/40787
10238         * gimplify.c (gimplify_call_expr): Reject code using results from
10239         functions returning void.
10240
10241 2009-07-18  Richard Sandiford  <r.sandiford@uk.ibm.com>
10242
10243         * doc/md.texi: Document the new PowerPC "es" constraint.
10244         Document that "m" can include automodified addresses on this target,
10245         and explain how %U must be used.  Extend the "Q" and "Z" documentation
10246         to suggest "es" as well as "m".
10247         * config/rs6000/constraints.md (es): New memory constraint.
10248         (Q, Z): Update strings to match new documentation.
10249
10250 2009-07-18  Richard Sandiford  <r.sandiford@uk.ibm.com>
10251
10252         * config/rs6000/rs6000.c (rs6000_mode_dependent_address): Allow any
10253         offset from virtual_stack_vars_rtx and arg_pointer_rtx.
10254         * config/rs6000/predicates.md (volatile_mem_operand): Use
10255         offsettable_nonstrict_memref_p.
10256         * config/rs6000/rs6000.md (*floatsidf2_internal): Remove split check.
10257         (*floatunssidf2_internal): Likewise.
10258         (*fix_truncdfsi2_internal): Likewise.
10259         (*fix_trunctfsi2_internal): Likewise.
10260
10261 2009-07-17  Anatoly Sokolov  <aesok@post.ru>
10262
10263         * config/avr/avr-devices.c (avr_mcu_t): Add atmega8u2, atmega16u2 and
10264         atmega32u2 devices.
10265         * config/avr/t-avr (MULTILIB_MATCHES): (Ditto.).
10266
10267 2009-07-17  Richard Guenther  <rguenther@suse.de>
10268
10269         PR c/40401
10270         * tree-pass.h (pass_diagnose_omp_blocks): Declare.
10271         (pass_warn_unused_result): Likewise.
10272         (TODO_set_props): Remove.
10273         * omp-low.c (diagnose_omp_structured_block_errors): Change to
10274         run as a pass.
10275         (pass_diagnose_omp_blocks): Define.
10276         * c-decl.c (pop_file_scope): Do not finalize the CU here.
10277         (c_gimple_diagnostics_recursively): Remove.
10278         (finish_function): Do not call it.
10279         (c_write_global_declarations): Continue after errors.
10280         Finalize the CU here.
10281         * c-gimplify.c (c_genericize): Do not gimplify here.
10282         * c-common.c (c_warn_unused_result): Move ...
10283         * tree-cfg.c (do_warn_unused_result): ... here.
10284         (run_warn_unused_result): New function.
10285         (gate_warn_unused_result): New function.
10286         (pass_warn_unused_result): New pass.
10287         * c-common.h (c_warn_unused_result): Remove.
10288         * flags.h (flag_warn_unused_result): Declare.
10289         * c-opts.c (c_common_init_options): Enable flag_warn_unused_result.
10290         * opts.c (flag_warn_unused_result): Initialize to false.
10291         * toplev.c (compile_file): Add comment.
10292         * omp-low.c (create_omp_child_function): Do not register
10293         the function with the frontend.
10294         (diagnose_omp_structured_block_errors): Prepare to be
10295         called as optimization pass.
10296         (gate_diagnose_omp_blocks): New function.
10297         (pass_diagnose_omp_blocks): New pass.
10298         * cgraph.h (cgraph_optimize): Remove.
10299         (cgraph_analyze_function): Likewise.
10300         * cgraph.c (cgraph_add_new_function): Gimplify C++ thunks.
10301         * cgraphunit.c (cgraph_lower_function): Lower nested functions
10302         before their parents here.
10303         (cgraph_finalize_function): Not here.
10304         (cgraph_analyze_function): Gimplify functions here.
10305         (cgraph_finalize_compilation_unit): Continue after errors.
10306         Optimize the callgraph from here.
10307         (cgraph_optimize): Make static.
10308         * langhooks.c (write_global_declarations): Finalize the CU.
10309         * gimplify.c (gimplify_asm_expr): Do not emit ASMs with errors.
10310         (gimplify_function_tree): Assert we gimplify only once.
10311         Set PROP_gimple_any property.
10312         * tree-nested.c (gimplify_all_functions): New function.
10313         (lower_nested_functions): Gimplify all nested functions.
10314         * gimple.h (diagnose_omp_structured_block_errors): Remove.
10315         * passes.c (init_optimization_passes): Add pass_warn_unused_result
10316         and pass_diagnose_omp_blocks after gimplification.  Do not
10317         set TODO_set_props on all_lowering_passes.
10318         (execute_one_pass): Do not handle TODO_set_props.
10319         * Makefile.in (cgraphunit.o): Add $(TREE_DUMP_H) dependency.
10320         (gimplify.o): Add tree-pass.h dependency.
10321         * tree-inline.c (copy_statement_list): Properly copy STATEMENT_LIST.
10322         (copy_tree_body_r): Properly handle TARGET_EXPR like SAVE_EXPR.
10323         (unsave_r): Likewise.
10324         * c-omp.c (c_finish_omp_atomic): Set DECL_CONTEXT on the
10325         temporary variable.
10326
10327 2009-07-17  Sandra Loosemore  <sandra@codesourcery.com>
10328
10329         * doc/service.texi (Service): Restore previously removed link,
10330         which isn't broken after all.
10331
10332 2009-07-17  Richard Guenther  <rguenther@suse.de>
10333
10334         PR tree-optimization/40321
10335         * tree-ssa-pre.c (add_to_exp_gen): Also add names defined by
10336         PHI nodes to the maximal set.
10337         (make_values_for_phi): Add PHI arguments to the maximal set.
10338         (execute_pre): Dump PHI_GEN and the maximal set.
10339
10340 2009-07-17  Jakub Jelinek  <jakub@redhat.com>
10341
10342         PR c++/40780
10343         * gimplify.c (gimplify_conversion): Don't change non-conversions into
10344         VIEW_CONVERT_EXPR.
10345
10346 2009-07-16  Sandra Loosemore  <sandra@codesourcery.com>
10347
10348         * doc/extend.texi (Nested Functions): Replace broken link with
10349         textual reference.
10350         * doc/service.texi (Service): Remove broken link.
10351
10352 2009-07-16  H.J. Lu  <hongjiu.lu@intel.com>
10353
10354         PR bootstrap/40781
10355         * builtins.c (expand_builtin_memcmp): Use loc instead of
10356         EXPR_LOCATION (exp).
10357         (expand_builtin_strncmp): Likewise.
10358
10359 2009-07-17  Aldy Hernandez  <aldyh@redhat.com>
10360             Manuel López-Ibáñez  <manu@gcc.gnu.org>
10361
10362         PR 40435
10363         * tree-complex.c, tree-loop-distribution.c, tree.c, tree.h,
10364         builtins.c, fold-const.c, omp-low.c, cgraphunit.c, tree-ssa-ccp.c,
10365         tree-ssa-dom.c, gimple-low.c, expr.c, tree-ssa-ifcombine.c,
10366         c-decl.c, stor-layout.c, tree-if-conv.c, c-typeck.c, gimplify.c,
10367         calls.c, tree-sra.c, tree-mudflap.c, tree-ssa-copy.c,
10368         tree-ssa-forwprop.c, c-convert.c, c-omp.c, varasm.c,
10369         tree-inline.c, c-common.c, c-common.h, gimple.c,
10370         tree-switch-conversion.c, gimple.h, tree-cfg.c, c-parser.c,
10371         convert.c: Add location argument to fold_{unary,binary,ternary},
10372         fold_build[123], build_call_expr, build_size_arg,
10373         build_fold_addr_expr, build_call_array, non_lvalue, size_diffop,
10374         fold_build1_initializer, fold_build2_initializer,
10375         fold_build3_initializer, fold_build_call_array,
10376         fold_build_call_array_initializer, fold_single_bit_test,
10377         omit_one_operand, omit_two_operands, invert_truthvalue,
10378         fold_truth_not_expr, build_fold_indirect_ref, fold_indirect_ref,
10379         combine_comparisons, fold_builtin_*, fold_call_expr,
10380         build_range_check, maybe_fold_offset_to_address, round_up,
10381         round_down.
10382
10383 2009-07-16  Jason Merrill  <jason@redhat.com>
10384
10385         PR libstdc++/37907
10386         * c-common.c (c_common_reswords): Add __is_standard_layout
10387         and __is_trivial.
10388         * c-common.h (enum rid): Add RID_IS_STD_LAYOUT and RID_IS_TRIVIAL.
10389         * doc/implement-cxx.texi: New.
10390         * doc/gcc.texi: Include it.
10391
10392 2009-07-16  DJ Delorie  <dj@redhat.com>
10393
10394         * config/m32c/m32c.c (m32c_compare_redundant): Avoid removing
10395         compares that may be indirectly affected by previous instructions.
10396
10397 2009-07-16  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
10398
10399         * builtins.c (do_mpc_arg2): New.
10400         (fold_builtin_2): Fold builtin cpow.
10401         * real.h (HAVE_mpc_pow): New.
10402
10403 2009-07-16  Bingfeng Mei  <bmei@broadcom.com>
10404
10405         * modulo-sched.c (sms_schedule): stage_count <= 1 as correct
10406         comparison to skip unprofitable schedule
10407
10408 2009-07-16  Simon Baldwin  <simonb@google.com>
10409
10410         * gcc.c (option_map): New flag -no-canonical-prefixes.
10411         * (display_help): Print help text for new flag.
10412         * (process_command): Move options translation and language specifics
10413         and handle new flag early.  Use it to set a function pointer to a
10414         prefix builder.  Replace make_relative_prefix calls with calls to
10415         the function pointed to.  Ignore new flag in regular options handling.
10416         * doc/invoke.texi (Overall Options): Documented -no-canonical-prefixes.
10417
10418 2009-07-15  DJ Delorie  <dj@redhat.com>
10419
10420         * config/mep/mep.md (sibcall_internal): Change register to avoid
10421         argument registers.
10422         (sibcall_value_internal): Likewise.
10423
10424 2009-07-15  Eric Botcazou  <ebotcazou@adacore.com>
10425
10426         PR rtl-optimization/40710
10427         * resource.c (mark_target_live_regs): Reset DF problem to LR.
10428
10429 2009-07-15  Adam Nemet  <anemet@caviumnetworks.com>
10430
10431         * config/mips/mips.md (*extenddi_truncate<mode>,
10432         *extendsi_truncate<mode>): Change type attribute to move_type
10433         with shift_shift.  Split out code handling exts from here ...
10434         (*extend<GPR:mode>_truncate<SHORT:mode>_exts): ... to this new
10435         pattern.
10436         (*extendhi_truncateqi): Change type attribute to move_type with
10437         shift_shift.  Split out code handling exts from here ...
10438         (*extendhi_truncateqi_exts): ... to this new pattern.
10439
10440 2009-07-15  Uros Bizjak  <ubizjak@gmail.com>
10441
10442         * config/i386/sse.md (copysign<mode>3): Use "and-not" SSE instruction
10443         instead of "and" with inverted sign bit mask value.  Use
10444         "nonimmediate_operand" for operand 1 and operand 2 predicate.
10445         Allocate registers only for operand 4 and operand 5.
10446
10447 2009-07-15  Jakub Jelinek  <jakub@redhat.com>
10448
10449         PR middle-end/40747
10450         * fold-const.c (fold_cond_expr_with_comparison): When folding
10451         < and <= to MIN, make sure the MIN uses the same type as the
10452         comparison's operands.
10453
10454 2009-07-15  Richard Earnshaw  <rearnsha@arm.com>
10455
10456         * arm.md (ior_xor): New code iterator.
10457         (split for ior/xor with shift and zero-extend): New split pattern.
10458         * arm/predicates.md (subreg_lowpart_operator): New special predicate.
10459
10460 2009-07-15  Richard Guenther  <rguenther@suse.de>
10461
10462         * tree-ssa-structalias.c (make_constraint_from_heapvar): Initialize
10463         offset member.
10464
10465 2009-07-15  Richard Guenther  <rguenther@suse.de>
10466
10467         PR middle-end/40753
10468         * alias.c (ao_ref_from_mem): Reject FUNCTION_DECL and LABEL_DECL bases.
10469
10470 2009-07-15  Maxim Kuvyrkov  <maxim@codesourcery.com>
10471
10472         * config/m68k/linux-unwind.h (m68k_fallback_frame_state): Update to
10473         handle 2.6.30 kernel.
10474
10475 2009-07-15  DJ Delorie  <dj@redhat.com>
10476
10477         * config/mep/mep.md (sibcall_internal): Change register to allow
10478         for 24-bit addresses.
10479         (sibcall_value_internal): Likewise.
10480
10481 2009-07-14  Ghassan Shobaki  <ghassan.shobaki@amd.com>
10482
10483         * doc/invoke.texi: Added descriptions of the  scheduling heuristics
10484         that are enabled/disabled by the flags introduced by a previous patch.
10485
10486 2009-07-14  DJ Delorie  <dj@redhat.com>
10487
10488         * config/mep/mep.md (sibcall_internal): Include non-toggling
10489         non-jmp case.
10490         (sibcall_value_internal): Likewise.
10491
10492 2009-07-14  Taras Glek  <tglek@mozilla.com>
10493             Rafael Espindola  <espindola@google.com>
10494
10495         * doc/sourcebuild.texi: Document install-plugin target.
10496         * configure.ac: Added install-plugin target to language makefiles.
10497         * configure: Regenerate.
10498         * Makefile.in: (install-plugin): Install more headers,
10499         depend on lang.install-plugin.
10500
10501 2009-07-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10502
10503         * tree-vrp.c (vrp_evaluate_conditional): Mark strings for
10504         translation.
10505
10506 2009-07-14  DJ Delorie  <dj@redhat.com>
10507
10508         * config/mep/mep.c (mep_vliw_jmp_match): New function.
10509         * config/mep/mep-protos.h (mep_vliw_jmp_match): Prototype it.
10510         * config/mep/mep.md (sibcall_internal): Change test from
10511         mep_vliw_mode_match to mep_vliw_jmp_match.
10512         (sibcall_value_internal): Likewise.
10513
10514 2009-07-14  Uros Bizjak  <ubizjak@gmail.com>
10515
10516         * config/i386/sse.md (copysign<mode>3): New expander.
10517         * config/i386/i386-protos.h (ix86_build_signbit_mask): New prototype.
10518         * config/i386/i386.c (ix86_build_signbit_mask): Make public.
10519         Use ix86_build_const_vector.
10520         (enum ix86_builtins): Add IX86_BUILTIN_CPYSGNPS and
10521         IX86_BUILTIN_CPYSGNPD.
10522         (builtin_description): Add __builtin_ia32_copysignps and
10523         __builtin_ia32_copysignpd.
10524         (ix86_builtin_vectorized_function): Handle BUILT_IN_COPYSIGN
10525         and BUILT_IN_COPYSIGNF.
10526
10527 2009-07-13  Jason Merrill  <jason@redhat.com>
10528
10529         * builtins.c (can_trust_pointer_alignment): New fn.
10530         (get_pointer_alignment): Factor it out from here.
10531         * tree.h: Declare it.
10532
10533 2009-07-14  David Edelsohn  <edelsohn@gnu.org>
10534
10535         * config/rs6000/predicates.md (offsettable_mem_operand): Test
10536         RTX_AUTOINC class.
10537
10538 2009-07-14  Dodji Seketeli  <dodji@redhat.com>
10539
10540         PR debug/40705
10541         PR c++/403057
10542         * dwarf2.out.c (gen_type_die_with_usage): Added comment.
10543
10544 2009-07-14  Richard Guenther  <rguenther@suse.de>
10545             Andrey Belevantsev <abel@ispras.ru>
10546
10547         PR middle-end/40745
10548         * cfgexpand.c (partition_stack_vars): Do not bother to update
10549         alias information when not optimizing.
10550
10551 2009-07-14  Richard Guenther  <rguenther@suse.de>
10552             Andrey Belevantsev <abel@ispras.ru>
10553
10554         * tree-ssa-alias.h (refs_may_alias_p_1): Declare.
10555         (pt_solution_set): Likewise.
10556         * tree-ssa-alias.c (refs_may_alias_p_1): Export.
10557         * tree-ssa-structalias.c (pt_solution_set): New function.
10558         * final.c (rest_of_clean_state): Free SSA data structures.
10559         * print-rtl.c (print_decl_name): Remove.
10560         (print_mem_expr): Implement in terms of print_generic_expr.
10561         * alias.c (ao_ref_from_mem): New function.
10562         (rtx_refs_may_alias_p): Likewise.
10563         (true_dependence): Query alias-export info.
10564         (canon_true_dependence): Likewise.
10565         (write_dependence_p): Likewise.
10566         * tree-dfa.c (get_ref_base_and_extent): For void types leave
10567         size unknown.
10568         * emit-rtl.c (component_ref_for_mem_expr): Remove.
10569         (mem_expr_equal_p): Use operand_equal_p.
10570         (set_mem_attributes_minus_bitpos): Do not use
10571         component_ref_for_mem_expr.
10572         * cfgexpand.c (add_partitioned_vars_to_ptset): New function.
10573         (update_alias_info_with_stack_vars): Likewise.
10574         (partition_stack_vars): Call update_alias_info_with_stack_vars.
10575         * tree-ssa.c (delete_tree_ssa): Do not release SSA names
10576         explicitly nor clear stmt operands.
10577         Free the decl-to-pointer map.
10578         * tree-optimize.c (execute_free_datastructures): Do not free
10579         SSA data structures here.
10580         * tree-flow.h (struct gimple_df): Add decls_to_pointers member.
10581         * Makefile.in (emit-rtl.o): Add pointer-set.h dependency.
10582         (alias.o): Add tree-ssa-alias.h, pointer-set.h and $(TREE_FLOW_H)
10583         dependencies.
10584         (print-rtl.o): Add $(DIAGNOSTIC_H) dependency.
10585
10586 2009-07-13  DJ Delorie  <dj@redhat.com>
10587
10588         * config/mep/mep.h (CC1_SPEC): Tweak parameters to trigger
10589         unrolling at the right iteration count.
10590
10591         * config/mep/mep.c (mep_expand_prologue): Fix frame pointer
10592         calculations.
10593
10594 2009-07-13  Ghassan Shobaki  <ghassan.shobaki@amd.com>
10595
10596         * haifa-sched.c (rank_for_schedule): Introduced flags to
10597         enable/disable individual scheduling heuristics.
10598         * common.opt: Introduced flags to enable/disable individual
10599         heuristics in the scheduler.
10600         * doc/invoke.texi: Introduced flags to enable/disable individual
10601         heuristics in the scheduler.
10602
10603 2009-07-13  Kai Tietz  <kai.tietz@onevision.com>
10604
10605         * config/i386/t-gthr-win32 (LIB2FUNCS_EXTRA): Remove file
10606         config/i386/mingw-tls.c.
10607         * config/i386/mingw-tls.c: Removed.
10608
10609 2009-07-13  Ira Rosen  <irar@il.ibm.com>
10610
10611         * tree-vect-loop.c (get_initial_def_for_reduction): Ensure that the
10612         checks access only relevant statements.
10613         (vectorizable_reduction): Likewise.
10614
10615 2009-07-12  Kai Tietz  <kai.tietz@onevision.com>
10616
10617         * config/i386/cygming.h (TARGET_OS_CPP_BUILTINS): Define _X86_
10618         just for 32-bit case.
10619
10620 2009-07-12  Jan Hubicka  <jh@suse.cz>
10621
10622         PR tree-optimization/40585
10623         * except.c (expand_resx_expr): When there already is resume
10624         instruction, produce linked list.
10625         (build_post_landing_pads): Assert that resume is empty.
10626         (connect_post_landing_pads): Handle resume lists.
10627         (dump_eh_tree): Dump resume list.
10628
10629 2009-07-12  Ira Rosen  <irar@il.ibm.com>
10630
10631         * tree-parloops.c (loop_parallel_p): Call vect_is_simple_reduction
10632         with additional argument.
10633         * tree-vectorizer.h (enum vect_def_type): Add
10634         vect_double_reduction_def.
10635         (vect_is_simple_reduction): Add argument.
10636         * tree-vect-loop.c (vect_determine_vectorization_factor): Fix
10637         indentation.
10638         (vect_analyze_scalar_cycles_1): Detect double reduction. Call
10639         vect_is_simple_reduction with additional argument.
10640         (vect_analyze_loop_operations): Handle exit phi nodes in case of
10641         double reduction.
10642         (reduction_code_for_scalar_code): Handle additional codes by
10643         returning ERROR_MARK for them. Fix comment and indentation.
10644         (vect_is_simple_reduction): Fix comment, add argument to specify
10645         double reduction. Detect double reduction.
10646         (get_initial_def_for_induction): Fix indentation.
10647         (get_initial_def_for_reduction): Fix comment and indentation.
10648         Handle double reduction. Create initial definitions that do not
10649         require adjustment if ADJUSTMENT_DEF is NULL. Handle additional cases.
10650         (vect_create_epilog_for_reduction): Fix comment, add argument to
10651         handle double reduction. Use PLUS_EXPR in case of MINUS_EXPR in
10652         epilogue result extraction. Create double reduction phi node and
10653         replace relevant uses.
10654         (vectorizable_reduction): Call vect_is_simple_reduction with
10655         additional argument. Fix indentation. Update epilogue code treatment
10656         according to the changes in reduction_code_for_scalar_code. Check
10657         for double reduction. Call vect_create_epilog_for_reduction with
10658         additional argument.
10659         * tree-vect-stmts.c (process_use): Handle double reduction, update
10660         documentation.
10661         (vect_mark_stmts_to_be_vectorized): Handle double reduction.
10662         (vect_get_vec_def_for_operand): Likewise.
10663
10664 2009-07-12  Danny Smith  <dansmister@gmail.com>
10665
10666         * config/i386/winnt.c (i386_pe_determine_dllexport_p): Don't
10667         dllexport if !TREE_PUBLIC.
10668         (i386_pe_maybe_record_exported_symbol): Assert TREE_PUBLIC.
10669
10670 2009-07-11  Anatoly Sokolov  <aesok@post.ru>
10671
10672         * config/avr/avr.h (TARGET_CPU_CPP_BUILTINS): Redefine.
10673         (avr_extra_arch_macro) Remove declatation.
10674         * config/avr/avr.c (avr_cpu_cpp_builtins): New function.
10675         (avr_extra_arch_macro) Declare as static.
10676         * config/avr/avr-protos.h (avr_cpu_cpp_builtins): Dclare.
10677
10678 2009-07-11  Jan Hubicka  <jh@suse.cz>
10679
10680         PR middle-end/48388
10681         * except.c (can_be_reached_by_runtime): Test for NULL aka bitmap.
10682
10683 2009-07-11  Jakub Jelinek  <jakub@redhat.com>
10684
10685         PR debug/40713
10686         * dwarf2out.c (dw_fde_struct): Add in_std_section and
10687         cold_in_std_section bits.
10688         (dwarf2out_begin_prologue): Initialize them.
10689         (dwarf2out_finish): Don't emit FDE range into .debug_ranges
10690         if already covered by text_section or cold_text_section range.
10691
10692         PR rtl-optimization/40667
10693         * defaults.h (MINIMUM_ALIGNMENT): Define if not defined.
10694         * doc/tm.texi (MINIMUM_ALIGNMENT): Document it.
10695         * config/i386/i386.h (MINIMUM_ALIGNMENT): Define.
10696         * config/i386/i386.c (ix86_minimum_alignment): New function.
10697         * config/i386/i386-protos.h (ix86_minimum_alignment): New prototype.
10698         * cfgexpand.c (expand_one_var): Use MINIMIM_ALIGNMENT.
10699         * emit-rtl.c (gen_reg_rtx): Likewise.
10700         * function.c (assign_parms): Likewise.  If nominal_type needs
10701         bigger alignment than FUNCTION_ARG_BOUNDARY, use its alignment
10702         rather than passed_type's alignment.
10703
10704         PR target/40668
10705         * function.c (assign_parm_setup_stack): Adjust
10706         MEM_OFFSET (data->stack_parm) if promoted_mode is different
10707         from nominal_mode on big endian.
10708
10709 2009-07-11  Paolo Bonzini  <bonzini@gnu.org>
10710
10711         * expmed.c (emit_store_flag_1): Fix choice of zero vs. sign extension.
10712
10713 2009-07-10  DJ Delorie  <dj@redhat.com>
10714
10715         * config/mep/mep.c (mep_can_inline_p): Correct logic, and simplify.
10716
10717 2009-07-10  Mark Mitchell  <mark@codesourcery.com>
10718
10719         * config/arm/thumb2.md (thumb2_cbz): Correct computation of length
10720         attribute.
10721         (thumb2_cbnz): Likewise.
10722
10723 2009-07-10  David Daney  <ddaney@caviumnetworks.com>
10724
10725         PR target/39079
10726         * config.gcc (supported_defaults): Add synci.
10727         (with_synci): Add validation.
10728         (all_defaults): Add synci.
10729         * config/mips/mips.md (clear_cache): Use TARGET_SYNCI instead of
10730         ISA_HAS_SYNCI.
10731         (synci): Same.
10732         * config/mips/mips.opt (msynci): New option.
10733         * config/mips/mips.c (mips_override_options): Warn on use of
10734         -msynci for targets that do now support it.
10735         * gcc/config/mips/mips.h (OPTION_DEFAULT_SPECS): Add a default for
10736         msynci.
10737         * gcc/doc/invoke.texi (-msynci): Document the new option.
10738         * doc/install.texi (--with-synci): Document the new option.
10739
10740 2009-07-10  Richard Guenther  <rguenther@suse.de>
10741
10742         PR tree-optimization/40496
10743         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Create
10744         the PHI result with a compatible type.
10745
10746 2009-07-10  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10747
10748         PR 25509
10749         PR 40614
10750         * c.opt (Wunused-result): New.
10751         * doc/invoke.texi: Document it.
10752         * c-common.c (c_warn_unused_result): Use it.
10753
10754 2009-07-09  DJ Delorie  <dj@redhat.com>
10755
10756         * targhooks.c (default_target_can_inline_p): Rename from
10757         default_target_option_can_inline_p.
10758         * targhooks.h (default_target_can_inline_p): Likewise.
10759         * target-def.h (TARGET_CAN_INLINE_P): Rename from
10760         TARGET_OPTION_CAN_INLINE_P.
10761         * config/i386/i386.c (TARGET_CAN_INLINE_P): Likewise.
10762         * config/mep/mep.c (TARGET_CAN_INLINE_P): Likewise.
10763         (mep_target_can_inline_p): Rename from
10764         mep_target_option_can_inline_p.
10765
10766         PR target/40626
10767         * config/mep/mep.h (FUNCTION_ARG_REGNO_P): Add coprocessor
10768         registers used to pass vectors.
10769
10770         * config/mep/mep.c (mep_option_can_inline_p): Remove error call.
10771
10772 2009-07-09  Tom Tromey  <tromey@redhat.com>
10773
10774         * unwind-dw2-fde-darwin.c: Include dwarf2.h.
10775         * config/mmix/mmix.c: Include dwarf2.h.
10776         * config/rs6000/darwin-fallback.c: Include dwarf2.h.
10777         * config/xtensa/unwind-dw2-xtensa.c: Include dwarf2.h.
10778         * config/sh/sh.c: Include dwarf2.h.
10779         * config/i386/i386.c: Include dwarf2.h.
10780         * Makefile.in (DWARF2_H): Remove 'elf'.
10781         * except.c: Include dwarf2.h.
10782         * unwind-dw2.c: Include dwarf2.h.
10783         * dwarf2out.c: Include dwarf2.h.
10784         * unwind-dw2-fde-glibc.c: Include dwarf2.h.
10785         * unwind-dw2-fde.c: Include dwarf2.h.
10786         * dwarf2asm.c: Include dwarf2.h.
10787
10788 2009-07-09  Maxim Kuvyrkov  <maxim@codesourcery.com>
10789
10790         * haifa-sched.c (insn_finishes_cycle_p): New static function.
10791         (max_issue): Use it.
10792         * sched-int.h (struct sched_info: insn_finishes_block_p): New
10793         scheduler hook.
10794         * sched-rgn.c (rgn_insn_finishes_block_p): Implement it.
10795         (region_sched_info): Update.
10796         * sched-ebb.c (ebb_sched_info): Update.
10797         * modulo-sched.c (sms_sched_info): Update.
10798         * sel-sched-ir.c (sched_sel_haifa_sched_info): Update.
10799
10800 2009-07-09  Maxim Kuvyrkov  <maxim@codesourcery.com>
10801
10802         * varasm.c (build_constant_desc): Don't share RTL in pool entries.
10803
10804 2009-07-09  Basile Starynkevitch  <basile@starynkevitch.net>
10805
10806         * plugin.c (try_init_one_plugin): passes RTLD_GLOBAL to dlopen.
10807
10808 2009-07-09  Jakub Jelinek  <jakub@redhat.com>
10809
10810         PR middle-end/40692
10811         * fold-const.c (fold_cond_expr_with_comparison): Don't replace
10812         arg1 with arg01 if arg1 is already INTEGER_CST.
10813
10814 2009-07-08  Adam Nemet  <anemet@caviumnetworks.com>
10815
10816         * simplify-rtx.c (simplify_binary_operation_1) <AND>:
10817         Transform (and (truncate)) into (truncate (and)).
10818
10819 2009-07-08  Adam Nemet  <anemet@caviumnetworks.com>
10820
10821         * combine.c (make_extraction): Check TRULY_NOOP_TRUNCATION before
10822         creating LHS paradoxical subregs.  Fix surrounding returns to
10823         use NULL_RTX rather than 0.
10824
10825 2009-07-08  DJ Delorie  <dj@redhat.com>
10826
10827         * config/mep/mep.c: (mep_option_can_inline_p): New.
10828         (TARGET_OPTION_CAN_INLINE_P): Define.
10829
10830 2009-07-08  Mark Wielaard  <mjw@redhat.com>
10831
10832         PR debug/40659
10833         * dwarf2out.c (add_data_member_location_attribute): When we have
10834         only a constant offset don't emit a new location description using
10835         DW_OP_plus_uconst, but just add the constant with add_AT_int, when
10836         dwarf_version > 2.
10837
10838 2009-07-08  Richard Henderson  <rth@redhat.com>
10839
10840         PR target/38900
10841         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Move to i386.c.
10842         (enum reg_class): Add CLOBBERED_REGS.
10843         (REG_CLASS_NAMES, REG_CLASS_CONTENTS): Likewise.
10844         * config/i386/i386.c (ix86_conditional_register_usage): Moved
10845         from CONDITIONAL_REGISTER_USAGE; build CLOBBERED_REGS for 64-bit.
10846         (ix86_function_ok_for_sibcall): Tidy.  Disallow MS->SYSV sibcalls.
10847         (ix86_expand_call): Use sibcall_insn_operand when needed.  Don't
10848         force 64-bit sibcalls into R11.
10849         * config/i386/constraints.md (U): New constraint.
10850         * config/i386/i386.md (sibcall_1, sibcall_value_1): Use it.
10851         (sibcall_1_rex64, sibcall_value_1_rex64): Likewise.
10852         (sibcall_1_rex64_v, sibcall_value_1_rex64_v): Remove.
10853
10854 2009-07-08  Shujing Zhao  <pearly.zhao@oracle.com>
10855
10856         * basic-block.h (dump_regset, debug_regset): Remove duplicate
10857         prototypes.
10858         * c-objc-common.h (c_initialize_diagnostics): Ditto.
10859         * ebitmap.h (dump_ebitmap): Ditto.
10860         * optabs.h (optab_libfunc): Ditto.
10861         * tree.h (tree_expr_nonzero_warnv_p): Ditto.
10862         * tree-flow.h (vect_can_force_dr_alignment_p,
10863         get_vectype_for_scalar_type): Ditto.
10864         (vectorize_loops): Move prototype to ...
10865         * tree-vectorizer.h: ... here. Also, adjust comment.
10866         (vect_set_verbosity_level): Remove duplicate prototype.
10867         * tree-ssa-loop.c: Include tree-vectorizer.h.
10868         * Makefile.in (tree-ssa-loop.o): Depend on tree-vectorizer.h.
10869
10870 2009-07-08  Nick Clifton  <nickc@redhat.com>
10871
10872         * config/i386/unix.h (ASM_COMMENT_START): Add a space after the
10873         forward slash.
10874
10875 2009-07-08  DJ Delorie  <dj@redhat.com>
10876
10877         * config/mep/mep-ivc2.cpu (cpmovtocsar0_C3, cpmovtocsar1_C3,
10878         cpmovtocc_C3, cpmovtocsar0_P0S_P1, cpmovtocsar1_P0S_P1,
10879         cpmovtocc_P0S_P1): Mark volatile.  Note which registers are
10880         written to.
10881         * config/mep/intrinsics.md: Regenerated.
10882         * config/mep/mep.c (mep_interrupt_saved_reg): Save IVC2 control
10883         registers when asm() or calls are detected.
10884
10885 2009-07-08  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10886
10887         PR c++/31246
10888         * gimplify.c (gimplify_expr): Propagate no_warning flag when
10889         gimplifying.
10890         * gimple (gimple_build_call_from_tree): Likewise.
10891         * tree-cfg.c (remove_useless_stmts_warn_notreached): Check
10892         no_warning flag before warning.
10893
10894 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10895
10896         * tree.c (set_expr_locus): Remove.
10897         * tree.h (EXPR_LOCUS,SET_EXPR_LOCUS,set_expr_locus): Remove.
10898         * c-typeck.c (c_finish_stmt_expr):  Replace EXPR_LOCUS by
10899         EXPR_LOCATION.
10900         * gimplify.c (internal_get_tmp_var): Likewise.
10901         (gimplify_call_expr): Likewise.
10902         (gimplify_one_sizepos): Likewise.
10903
10904 2009-07-07  Eric Botcazou  <ebotcazou@adacore.com>
10905
10906         PR debug/40666
10907         * dbxout.c (dbxout_symbol) <PARM_DECL>: Deal with parameters pointing
10908         to variables for debugging purposes.
10909
10910 2009-06-23  Mark Loeser  <mark@halcy0n.com>
10911
10912         PR build/40010
10913         * Makefile.in (gcc.pod): Depend on gcc-vers.texi.
10914
10915 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10916
10917         * pretty-print.c (pp_base_format): Remove %J.
10918         * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
10919         gcc_cxxdiag_char_table): Likewise.
10920         (init_dynamic_diag_info): Likewise.
10921
10922 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10923
10924         * pretty-print.c (pp_base_format): Remove %H.
10925         * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
10926         gcc_cxxdiag_char_table): Likewise.
10927         (init_dynamic_diag_info): Likewise.
10928         * config/mep/mep.c (mep_select_section): Likewise.
10929
10930 2009-07-07  Duncan Sands  <baldrick@free.fr>
10931
10932         * final.c (pass_clean_state): Give the pass a name.
10933         * passes.c (pass_rest_of_compilation): Likewise.
10934         * tree-optimize.c (pass_all_optimizations): Likewise.
10935
10936 2009-07-07  H.J. Lu  <hongjiu.lu@intel.com>
10937
10938         * config/ia64/ia64.c (ia64_handle_model_attribute): Remove
10939         an extra 'decl' for error_at.
10940
10941 2009-07-07  Jakub Jelinek  <jakub@redhat.com>
10942
10943         PR middle-end/40669
10944         * tree-tailcall.c (adjust_return_value_with_ops,
10945         create_tailcall_accumulator): Set DECL_GIMPLE_REG_P on the temporary
10946         if it has complex or vector type.
10947
10948 2009-07-07  Olivier Hainque  <hainque@adacore.com>
10949
10950         * config/alpha/t-osf4 (SHLIB_LINK): Do not hide the dummy weak
10951         pthread symbols.
10952
10953 2009-07-07  Basile Starynkevitch  <basile@starynkevitch.net>
10954
10955         * Makefile.in: added more lists of includes to PLUGIN_HEADERS.
10956
10957 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10958
10959         * cgraphunit.c: Replace %J by an explicit location.  Update all calls.
10960         * c-decl.c: Likewise.
10961         * function.c: Likewise.
10962         * varasm.c: Likewise.
10963         * tree-ssa.c: Likewise.
10964         * c-common.c: Likewise.
10965         * tree-cfg.c: Likewise.
10966         * config/spu/spu.c: Likewise.
10967         * config/ia64/ia64.c: Likewise.
10968         * config/v850/v850.c: Likewise.
10969
10970 2009-07-06  DJ Delorie  <dj@redhat.com>
10971
10972         * config/mep/mep-core.cpu (fsft, ssarb): Mark as VOLATILE.
10973         * config/mep/mep-ivc2.cpu (many): Add VOLATILE to more insns that make
10974         unspecified accesses to control registers.
10975         * config/mep/intrinsics.md: Regenerate.
10976         * config/mep/intrinsics.h: Regenerate.
10977         * config/mep/mep-intrin.h: Regenerate.
10978
10979 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10980
10981         * c-lex.c: Replace %H by an explicit location. Update all calls.
10982         * c-common.c: Likewise.
10983         * c-decl.c: Likewise.
10984         * c-typeck.c: Likewise.
10985         * fold-const.c: Likewise.
10986         * gimplify.c: Likewise.
10987         * stmt.c: Likewise.
10988         * tree-cfg.c: Likewise.
10989         * tree-ssa-loop-niter.c: Likewise.
10990         * tree-vrp.c: Likewise.
10991         * value-prof.c: Likewise.
10992
10993 2009-07-06  Diego Novillo  <dnovillo@google.com>
10994
10995         * tree-dfa.c (dump_variable): Write DECL_INITIAL for VAR
10996         if it has one.  Handle cases where VAR does not have an
10997         annotation or cfun is NULL.
10998
10999 2009-07-06  Diego Novillo  <dnovillo@google.com>
11000
11001         * tree.c: Include debug.h.
11002         (initialize_tree_contains_struct): New.
11003         (init_ttree): Call it.
11004         (tree_node_structure_for_code): Factor out of ...
11005         (tree_node_structure): ... here.
11006         * treestruct.def (TS_PHI_NODE): Remove.
11007         (TS_GIMPLE_STATEMENT): Remove.
11008
11009 2009-07-06  Diego Novillo  <dnovillo@google.com>
11010
11011         * tree-pretty-print.c (dump_generic_node): Protect against NULL op0.
11012         (debug_tree_chain): Handle cycles.
11013
11014 2009-07-06  Nick Clifton  <nickc@redhat.com>
11015             DJ Delorie  <dj@redhat.com>
11016
11017         * config.sh/lib1funcs.h (FMOVD_WORKS): Only define if
11018         __FMOVD_ENABLED__ is defined.
11019         * config/sh/sh.h
11020         (TARGET_FMOVD): Provide a default definition.
11021         (MASK_FMOVD): Likewise.
11022         (TARGET_CPU_CPP_BUILTINS): Define
11023         __FMOVD_ENABLED__ if TARGET_FMOVD is true.
11024         * config/sh/sh.md (movdf_i4): For alternative 0 use either one or
11025         two fmov instructions depending upon whether TARGET_FMOVD is enabled.
11026         (split for DF load from memory into register): Also handle
11027         MEMs which consist of REG+DISP addressing.
11028         (split for DF store from register to memory): Likewise.
11029         (movsf_ie): Always use single fp_mode.
11030         * config/sh/sh.c (sh_override_options): Do not automatically
11031         enable TARGET_MOVD for the SH2A when supporting doubles - leave
11032         that to the -mfmovd command line switch.
11033         (broken_move): Do not restrict fldi test to only the SH4 and SH4A.
11034         (fldi_ok): Always allow.
11035         * config/sh/sh.opt (mfmovd): Remove this switch.
11036         * doc/invoke.texi (-mfmovd): Remove documentation of this switch.
11037
11038 2009-07-06  J"orn Rennecke  <joern.rennecke@arc.com>
11039             Kaz Kojima  <kkojima@gcc.gnu.org>
11040
11041         PR rtl-optimization/30807
11042         * postreload.c (reload_combine): For every new use of REG_SUM,
11043         record the use of BASE.
11044
11045 2009-07-06  Jan Hubicka  <jh@suse.cz>
11046
11047         * params.def: Revert my accidental commit at 2009-06-30.
11048
11049 2009-07-04  Ian Lance Taylor  <iant@google.com>
11050
11051         PR target/40636
11052         * config/i386/msformat-c.c (mingw_format_attributes): Declare as
11053         EXPORTED_CONST.
11054         (mingw_format_attribute_overrides): Likewise.
11055
11056 2009-07-04  Jakub Jelinek  <jakub@redhat.com>
11057
11058         PR debug/40596
11059         * dwarf2out.c (based_loc_descr): For crtl->stack_realign_tried
11060         don't check cfa.reg.  Instead of cfa.indirect use
11061         fde && fde->drap_reg != INVALID_REGNUM test.
11062
11063 2009-07-04  Eric Botcazou  <ebotcazou@adacore.com>
11064
11065         * postreload.c (reload_combine): Replace CONST_REG with INDEX_REG.
11066
11067 2009-07-03  Vladimir Makarov  <vmakarov@redhat.com>
11068
11069         PR target/40587
11070         * ira.c (build_insn_chain): Use DF_LR_OUT instead of df_get_live_out.
11071
11072 2009-07-03  Richard Guenther  <rguenther@suse.de>
11073
11074         PR tree-optimization/40640
11075         * tree-switch-conversion.c (build_arrays): Perform arithmetic
11076         in original type.
11077
11078 2009-07-03  Jan Hubicka  <jh@suse.cz>
11079
11080         * ipa-inline.c (cgraph_decide_inlining_incrementally): When optimizing
11081         for size, reduce amount of inlining.
11082
11083 2009-07-03  Richard Guenther  <rguenther@suse.de>
11084
11085         PR middle-end/34163
11086         * tree-chrec.c (chrec_convert_1): Fold (T2)(t +- x) to (T2)t +- (T2)x
11087         if t +- x is known to not overflow and the conversion widens the
11088         operation.
11089         * Makefile.in (tree-chrec.o): Add $(FLAGS_H) dependency.
11090
11091 2009-07-03  Jan Hubicka  <jh@suse.cz>
11092
11093         * ipa-pure-const.c (analyze): Update loop optimizer init.
11094         * tree-ssa-loop-iv-canon.c (empty_loop_p, remove_empty_loop,
11095         try_remove_empty_loop, remove_empty_loops): Remove.
11096         * tree-ssa-loop.c (tree_ssa_empty_loop, pass_empty_loop): Remove.
11097         * tree-ssa-dce.c (find_obviously_necessary_stmts): Use finiteness info
11098         to mark regular loops as neccesary.
11099         (degenerate_phi_p): New function.
11100         (propagate_necessity, remove_dead_phis): Use it.
11101         (forward_edge_to_pdom): Likewise.
11102         (eliminate_unnecessary_stmts): Take care to remove uses of results of
11103         virtual PHI nodes that became unreachable.
11104         (perform_tree_ssa_dce): Initialize/deinitialize loop optimizer.
11105         * tree-flow.h (remove_empty_loops): Remove.
11106         * passes.c (init_optimization_passes): Remove.
11107
11108 2009-07-03  Uros Bizjak  <ubizjak@gmail.com>
11109
11110         * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Use
11111         can_create_pseudo_p.
11112         (*fix_trunc<mode>_i387_1): Ditto.
11113         (*floathi<mode>2_1): Ditto.
11114         (*float<SSEMODEI24:mode><X87MODEF:mode>2_1): Ditto.
11115         (*fistdi2_1): Ditto.
11116         (*fist<mode>2_1): Ditto.
11117         (frndintxf2_floor): Ditto.
11118         (*fist<mode>2_floor_1): Ditto.
11119         (frndintxf2_ceil): Ditto.
11120         (*fist<mode>2_ceil_1): Ditto.
11121         (frndintxf2_trunc): Ditto.
11122         (frndintxf2_mask_pm): Ditto.
11123         (fxam<mode>2_i387_with_temp): Ditto.
11124         * config/i386/sse.md (mulv16qi3): Ditto.
11125         (*sse2_mulv4si3): Ditto.
11126         (mulv2di3): Ditto.
11127         (sse4_2_pcmpestr): Ditto.
11128         (sse4_2_pcmpistr): Ditto.
11129
11130 2009-07-03  Jan Hubicka  <jh@suse.cz>
11131
11132         * tree-ssa-dce.c (bb_contains_live_stmts): New bitmap.
11133         (mark_stmt_necessary): Set it.
11134         (mark_operand_necessary): Set it.
11135         (mark_control_dependent_edges_necessary): Set it.
11136         (mark_virtual_phi_result_for_renaming): New function.
11137         (get_live_post_dom): New function.
11138         (forward_edge_to_pdom): New function.
11139         (remove_dead_stmt): Fix handling of control dependences.
11140         (tree_dce_init): Init new bitmap.
11141         (tree_dce_done): Free it.
11142
11143 2009-07-02  Richard Guenther  <rguenther@suse.de>
11144
11145         PR bootstrap/40617
11146         * tree-ssa-structalias.c (new_var_info): Initialize
11147         is_restrict_var.
11148
11149 2009-07-02  Jan Hubicka  <jh@suse.cz>
11150
11151         * ipa-pure-const.c (check_op): Use PTA info to see if indirect_ref is
11152         local.
11153
11154 2009-07-02  Paolo Bonzini  <bonzini@gnu.org>
11155
11156         * expmed.c (emit_cstore, emit_store_flag_1): Accept target_mode
11157         instead of recomputing it.  Adjust calls.
11158         (emit_store_flag): Adjust recursive calls.
11159
11160 2009-07-02  Richard Guenther  <rguenther@suse.de>
11161
11162         * tree-ssa-live.c (remove_unused_locals): Do not remove
11163         heap variables.
11164         * tree-ssa-structalias.c (handle_lhs_call): Delay setting
11165         of DECL_EXTERNAL for HEAP variables.
11166         (compute_points_to_sets): Set DECL_EXTERNAL for escaped
11167         HEAP variables.  Do not adjust RESTRICT vars.
11168         (find_what_var_points_to): Nobody cares if something
11169         points to READONLY.
11170
11171 2009-07-02  Ben Elliston  <bje@au.ibm.com>
11172
11173         * unwind-dw2-fde-glibc.c (_Unwind_IteratePhdrCallback): Move
11174         pc_low and pc_high declarations to the top of the function.
11175
11176 2009-07-01  DJ Delorie  <dj@redhat.com>
11177
11178         * config/mep/mep.c (mep_handle_option): Leave IVC2 control
11179         registers as fixed.
11180         (mep_interrupt_saved_reg): Save appropriate IVC2 control registers.
11181         * config/mep/mep-ivc2.cpu: Add VOLATILE to insns that make
11182         unspecified accesses to control registers.
11183         * config/mep/intrinsics.md: Regenerate.
11184         * config/mep/intrinsics.h: Regenerate.
11185         * config/mep/mep-intrin.h: Regenerate.
11186
11187 2009-07-01  Anthony Green  <green@moxielogic.com>
11188
11189         * config/moxie/moxie.c (moxie_expand_prologue): Use dec
11190         instruction when possible.
11191         (moxie_expand_prologue): Ditto.  Also, save an instruction and
11192         some complexity by popping off of $r12 instead of $sp.
11193         * config/moxie/moxie.md (movsi_pop): Don't assume $sp.  Take two
11194         operands.
11195
11196 2009-07-01  Richard Henderson  <rth@redhat.com>
11197
11198         PR bootstrap/40347
11199         * function.c (reposition_prologue_and_epilogue_notes): If epilogue
11200         contained no insns, reposition note before last insn.
11201
11202 2009-07-01  Richard Henderson  <rth@redhat.com>
11203
11204         PR debug/40431
11205         * dwarf2out.c (def_cfa_1): Revert 2009-06-11 change for
11206         DW_CFA_def_cfa_offset and DW_CFA_def_cfa.
11207
11208 2009-07-01  Michael Meissner  <meissner@linux.vnet.ibm.com>
11209
11210         PR bootstrap/40558
11211         * config/rs6000/rs6000.c (print_operand): Undo change that breaks
11212         darwin9 for printing reg addresses with %y.
11213
11214 2009-07-01  Adam Nemet  <anemet@caviumnetworks.com>
11215
11216         * combine.c (force_to_mode): Handle TRUNCATE.  Factor out
11217         truncation from operands in binary operations.
11218
11219 2009-07-01  Adam Nemet  <anemet@caviumnetworks.com>
11220
11221         Revert:
11222         2009-01-11  Adam Nemet  <anemet@caviumnetworks.com>
11223         * expmed.c (store_bit_field_1): Properly truncate the paradoxical
11224         subreg of op0 to the original op0.
11225
11226         * expmed.c (store_bit_field_1): Use a temporary as the destination
11227         instead of a paradoxical subreg when we need to truncate the result.
11228
11229 2009-07-01  DJ Delorie  <dj@redhat.com>
11230
11231         * config/mep/mep-ivc2.cpu (cmov, cmovc, cmovh): Add intrinsic
11232         names to VLIW variants.
11233         (ivc2rm, ivc2crn): Make data type consistent with non-VLIW variants.
11234         * config/mep/intrinsics.md: Regenerate.
11235         * config/mep/intrinsics.h: Regenerate.
11236         * config/mep/mep-intrin.h: Regenerate.
11237
11238 2009-07-01  Jakub Jelinek  <jakub@redhat.com>
11239
11240         PR debug/40462
11241         * jump.c (returnjump_p): Revert last patch.
11242         * dwarf2out.c (dwarf2out_begin_epilogue): Handle SEQUENCEs.
11243
11244 2009-07-01  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
11245
11246         PR target/40575
11247         * pa.md (casesi32p): Use jump table label to determine the offset
11248         of the jump table.
11249         (casesi64p): Likewise.
11250
11251         * pa.c (forward_branch_p): Return bool type.  Use instruction
11252         addresses when available.  Assert that INSN has a jump label.
11253         (pa_adjust_insn_length): Don't call forward_branch_p if INSN doesn't
11254         have a jump label.
11255
11256 2009-07-01  Richard Guenther  <rguenther@suse.de>
11257
11258         PR tree-optimization/19831
11259         * tree-ssa-dce.c (propagate_necessity): Calls to functions
11260         that only act as barriers do not make any previous stores necessary.
11261         * tree-ssa-structalias.c (handle_lhs_call): Delay making
11262         HEAP variables global, do not add a constraint from nonlocal.
11263         (find_func_aliases): Handle escapes through return statements.
11264         (compute_points_to_sets): Make escaped HEAP variables global.
11265
11266 2009-07-01  Paolo Bonzini  <bonzini@gnu.org>
11267
11268         PR bootstrap/40597
11269         * expmed.c (emit_store_flag): Perform a conversion if necessary,
11270         after reducing a DImode cstore to SImode.
11271
11272 2009-07-01  Paolo Bonzini  <bonzini@gnu.org>
11273
11274         * expr.c (expand_expr_real_1): Reinstate fallthrough to
11275         TRUTH_ANDIF_EXPR if do_store_flag returns NULL.
11276
11277 2009-07-01  Maciej W. Rozycki  <macro@linux-mips.org>
11278
11279         * config/vax/vax.h (TARGET_BSD_DIVMOD): New macro.  Set to 1.
11280         * config/vax/linux.h (TARGET_BSD_DIVMOD): New macro.  Redefine the
11281         to 0.
11282         * config/vax/vax.c (vax_init_libfuncs): Only redefine udiv_optab
11283         and umod_optab if TARGET_BSD_DIVMOD.
11284         * config/vax/lib1funcs.asm: New file.
11285         * config/vax/t-linux: New file.
11286         * config.gcc (vax-*-linux*): Set tmake_file to vax/t-linux.
11287
11288 2009-06-30  Jakub Jelinek  <jakub@redhat.com>
11289
11290         PR c++/40566
11291         * convert.c (convert_to_integer) <case COND_EXPR>: Don't convert
11292         to type arguments that have void type.
11293
11294         PR debug/40573
11295         * dwarf2out.c (gen_formal_parameter_die): Call
11296         equate_decl_number_to_die if node is different from origin.
11297
11298 2009-06-30  Anthony Green  <green@moxielogic.com>
11299
11300         Clean up moxie port for --enable-build-with-cxx.
11301         * config/moxie/moxie.c (moxie_function_value): First two
11302         parameters are const_tree, not tree.
11303         * config/moxie/moxie.h (enum reg_class): Rename CC_REG to CC_REGS.
11304         (REG_CLASS_NAMES): Ditto.
11305         (REGNO_REG_CLASS): Ditto.
11306         * config/moxie/moxie-protos.h (moxie_override_options): Declare.
11307         (moxie_function_value): Fix constyness of arguments.
11308
11309 2009-06-30  Eric Botcazou  <ebotcazou@adacore.com>
11310
11311         * cgraphunit.c (cgraph_finalize_compilation_unit): Call
11312         finalize_size_functions before further processing.
11313         * stor-layout.c: Include cgraph.h, tree-inline.h and tree-dump.h.
11314         (variable_size): Call self_referential_size on size expressions
11315         that contain a PLACEHOLDER_EXPR.
11316         (size_functions): New static variable.
11317         (copy_self_referential_tree_r): New static function.
11318         (self_referential_size): Likewise.
11319         (finalize_size_functions): New global function.
11320         * tree.c: Include tree-inline.h.
11321         (push_without_duplicates): New static function.
11322         (find_placeholder_in_expr): New global function.
11323         (substitute_in_expr) <tcc_declaration>: Return the replacement object
11324         on equality.
11325         <tcc_expression>: Likewise.
11326         <tcc_vl_exp>: If the replacement object is a constant, try to inline
11327         the call in the expression.
11328         * tree.h (finalize_size_functions): Declare.
11329         (find_placeholder_in_expr): Likewise.
11330         (FIND_PLACEHOLDER_IN_EXPR): New macro.
11331         (substitute_placeholder_in_expr): Update comment.
11332         * tree-inline.c (remap_decl): Do not unshare trees if do_not_unshare
11333         is true.
11334         (copy_tree_body_r): Likewise.
11335         (copy_tree_body): New static function.
11336         (maybe_inline_call_in_expr): New global function.
11337         * tree-inline.h (struct copy_body_data): Add do_not_unshare field.
11338         (maybe_inline_call_in_expr): Declare.
11339         * Makefile.in (tree.o): Depend on TREE_INLINE_H.
11340         (stor-layout.o): Depend on CGRAPH_H, TREE_INLINE_H, TREE_DUMP_H and
11341         GIMPLE_H.
11342
11343 2009-06-30  Richard Guenther  <rguenther@suse.de>
11344
11345         * tree-ssa-dce.c (mark_all_reaching_defs_necessary_1): Always
11346         continue walking.
11347         (propagate_necessity): Do not mark reaching defs of stores
11348         as necessary.
11349
11350 2009-06-30  Jan Hubicka  <jh@suse.cz>
11351
11352         * cfgloopanal.c (check_irred): Move into ...
11353         (mark_irreducible_loops): ... here; return true if ireducible
11354         loops was found.
11355         * ipa-pure-const.c: Include cfgloop.h and tree-scalar-evolution.h
11356         (analyze_function): Try to prove loop finiteness.
11357         * cfgloop.h (mark_irreducible_loops): Update prototype.
11358         * Makefile.in (ipa-pure-const.o): Add dependency on SCEV and CFGLOOP.
11359
11360 2009-06-30  Basile Starynkevitch  <basile@starynkevitch.net>
11361
11362         * Makefile.in (PLUGIN_HEADERS): added ggc, tree-dump, pretty-print.
11363
11364 2009-06-30  Ira Rosen  <irar@il.ibm.com>
11365
11366         PR tree-optimization/40542
11367         * tree-vect-stmts.c (vect_analyze_stmt): Don't vectorize volatile
11368         types.
11369
11370 2009-06-30  Martin Jambor  <mjambor@suse.cz>
11371
11372         PR tree-optimization/40582
11373         * tree-sra.c (build_ref_for_offset_1): Use types_compatible_p rather
11374         than useless_type_conversion_p.
11375         (generate_subtree_copies): Increment sra_stats.subtree_copies at a
11376         proper place.
11377
11378 2009-06-30  Martin Jambor  <mjambor@suse.cz>
11379
11380         PR middle-end/40554
11381         * tree-sra.c (sra_modify_expr): Add access->offset to start_offset.
11382
11383 2009-06-30  Richard Guenther  <rguenther@suse.de>
11384
11385         * tree-ssa-alias.c (walk_aliased_vdefs_1): Change interface to
11386         use ao_ref references.
11387         (walk_aliased_vdefs): Likewise.
11388         * tree-ssa-alias.h (walk_aliased_vdefs): Adjust prototype.
11389         * tree-ssa-dce.c (struct ref_data): Remove.
11390         (mark_aliased_reaching_defs_necessary_1): Use the ao_ref argument.
11391         (mark_aliased_reaching_defs_necessary): Adjust.
11392         (mark_all_reaching_defs_necessary_1): Likewise.
11393
11394 2009-06-30  Paolo Bonzini  <bonzini@gnu.org>
11395
11396         PR boostrap/40597
11397         * expmed.c (emit_cstore): New name of emit_store_flag_1.
11398         (emit_store_flag_1): Extract from emit_store_flag, adjust
11399         calls to (what now is) emit_cstore.
11400         (emit_store_flag): Call emit_store_flag_1 and also use it
11401         for what used to be recursive calls.
11402
11403 2009-06-30  Wei Guozhi  <carrot@google.com>
11404
11405         PR/40416
11406         * tree-ssa-sink.c (statement_sink_location): Stop sinking expression
11407         if the target bb post dominates from bb.
11408         * config/i386/i386.c (memory_address_length): Check existence of base
11409         register before using it.
11410
11411 2009-06-30  Nick Clifton  <nickc@redhat.com>
11412             DJ Delorie  <dj@redhat.com>
11413
11414         * config.sh/lib1funcs.h (FMOVD_WORKS): Only define if
11415         __FMOVD_ENABLED__ is defined.
11416         * config/sh/sh.h
11417         (TARGET_FMOVD): Provide a default definition.
11418         (MASK_FMOVD): Likewise.
11419         (TARGET_CPU_CPP_BUILTINS): Define
11420         __FMOVD_ENABLED__ if TARGET_FMOVD is true.
11421         * config/sh/sh.md (movdf_i4): For alternative 0 use either one or
11422         two fmov instructions depending upon whether TARGET_FMOVD is
11423         enabled.
11424         (split for DF load from memory into register): Also handle
11425         MEMs which consist of REG+DISP addressing.
11426         (split for DF store from register to memory): Likewise.
11427         * config/sh/sh.opt (mfmovd): Remove this switch.
11428         * doc/invoke.texi (-mfmovd): Remove documentation of this switch.
11429         * config/sh/sh.c (sh_override_options): Do not automatically
11430         enable TARGET_MOVD for the SH2A when supporting doubles - leave
11431         that to the -mfmovd command line switch.
11432
11433         * config/sh/sh.c (broken_move): Do not restrict fldi test to only
11434         the SH4 and SH4A.
11435         (fldi_ok): Always allow.
11436         * config/sh/sh.md (movsf_ie): Always use single fp_mode.
11437
11438 2009-06-29  DJ Delorie  <dj@redhat.com>
11439
11440         * doc/install.texi (mep-x-elf): Correct chip's full name.
11441
11442 2009-06-29  H.J. Lu  <hongjiu.lu@intel.com>
11443
11444         * doc/extend.texi: Fix typo.
11445
11446 2009-06-29  Tom Tromey  <tromey@redhat.com>
11447
11448         * dwarf2.h: Remove.
11449         * Makefile.in (DWARF2_H): New variable.
11450         (except.o): Use it.
11451         (dwarf2out.o): Likewise.
11452         (dwarf2asm.o): Likewise.
11453         * config/i386/t-i386: Use DWARF2_H.
11454         * except.c: Include elf/dwarf2.h.
11455         * unwind-dw2.c: Include elf/dwarf2.h.
11456         * dwarf2out.c: Include elf/dwarf2.h.
11457         (dw_loc_descr_struct) <dw_loc_opc>: Now a bitfield.
11458         <dtprel>: New field.
11459         (dwarf_stack_op_name): Don't handle INTERNAL_DW_OP_tls_addr.
11460         (size_of_loc_descr): Likewise.
11461         (output_loc_operands_raw): Likewise.
11462         (output_loc_operands): Handle new dtprel field.
11463         (loc_checksum): Update.
11464         (loc_descriptor_from_tree_1) <VAR_DDECL>: Set dtprel field.
11465         * unwind-dw2-fde-glibc.c: Include elf/dwarf2.h.
11466         * unwind-dw2-fde.c: Include elf/dwarf2.h.
11467         * dwarf2asm.c: Include elf/dwarf2.h.
11468         * unwind-dw2-fde-darwin.c: Include elf/dwarf2.h.
11469         * config/mmix/mmix.c: Include elf/dwarf2.h.
11470         * config/rs6000/darwin-fallback.c: Include elf/dwarf2.h.
11471         * config/xtensa/unwind-dw2-xtensa.c: Include elf/dwarf2.h.
11472         * config/sh/sh.c: Include elf/dwarf2.h.
11473         * config/i386/i386.c: Include elf/dwarf2.h.
11474
11475 2009-06-29  DJ Delorie  <dj@redhat.com>
11476
11477         * config/mep/mep.h (CPP_SPEC): Remove __cop macro.
11478
11479         * doc/extend.texi: Add MeP attributes and pragmas.
11480         * doc/invoke.text: Add MeP Options.
11481         * doc/contrib.texi: Add MeP contribution.
11482         * doc/md.texi: Add MeP constraints.
11483         * doc/install.texi: Add MeP target.
11484
11485 2009-06-30  Anatoly Sokolov  <aesok@post.ru>
11486
11487         * target.h (struct gcc_target): Add frame_pointer_required field.
11488         * target-def.h (TARGET_FRAME_POINTER_REQUIRED): New.
11489         (TARGET_INITIALIZER): Use TARGET_FRAME_POINTER_REQUIRED.
11490         * ira.c (setup_eliminable_regset): Use frame_pointer_required target
11491         hook.
11492         * reload1.c (update_eliminables): (Ditto.).
11493         * gcc/system.h (FRAME_POINTER_REQUIRED): Poison.
11494         * doc/tm.texi (FRAME_POINTER_REQUIRED): Revise documentation.
11495         (INITIAL_FRAME_POINTER_OFFSET): (Ditto.).
11496
11497         * config/arc/arc.h (FRAME_POINTER_REQUIRED): Remove macro.
11498
11499         * config/arm/arm.h (FRAME_POINTER_REQUIRED): Remove macro.
11500         * config/arm/arm.c (TARGET_FRAME_POINTER_REQUIRED): Define.
11501         (arm_frame_pointer_required): New function.
11502
11503         * config/avr/avr.h (FRAME_POINTER_REQUIRED): Remove macro.
11504         * config/avr/avr.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
11505         (avr_frame_pointer_required_p): Declare as static.
11506         * config/avr/avr-protos.h (avr_frame_pointer_required_p): Remove.
11507
11508         * config/bfin/bfin.h (FRAME_POINTER_REQUIRED): Remove macro.
11509         * config/bfin/bfin.c (TARGET_FRAME_POINTER_REQUIRED): Define.
11510         (bfin_frame_pointer_required): Make as static, change return type
11511         to bool.
11512         * config/bfin/bfin-protos.h (bfin_frame_pointer_required): Remove.
11513
11514         * config/cris/cris.h (FRAME_POINTER_REQUIRED): Remove macro.
11515         * config/cris/cris.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
11516         (cris_frame_pointer_required): New function.
11517
11518         * config/crx/crx.h (FRAME_POINTER_REQUIRED): Remove macro.
11519
11520         * config/fr30/fr30.h (FRAME_POINTER_REQUIRED): Remove macro.
11521         * config/fr30/fr30.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
11522         (fr30_frame_pointer_required): New function.
11523
11524         * config/frv/frv.h (FRAME_POINTER_REQUIRED): Remove macro.
11525         * config/frv/frv.c (TARGET_FRAME_POINTER_REQUIRED): Define.
11526         (frv_frame_pointer_required): Make as static, change return type
11527         to bool.
11528         * config/bfin/bfin-protos.h (frv_frame_pointer_required): Remove.
11529
11530         * config/i386/i386.h (FRAME_POINTER_REQUIRED): Remove macro.
11531         * config/i386/i386.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
11532         (ix86_frame_pointer_required): Make as static, change return type to
11533         bool.
11534         * config/i386/i386-protos.h (ix86_frame_pointer_required): Remove.
11535
11536         * config/m32c/m32c.h (FRAME_POINTER_REQUIRED): Remove macro.
11537         * config/m32c/m32c.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
11538
11539         * config/m32r/m32r.h (FRAME_POINTER_REQUIRED): Remove macro.
11540
11541         * config/mcore/mcore.h (CAN_ELIMINATE): Remove macro.
11542
11543         * config/mep/mep.h (FRAME_POINTER_REQUIRED): Remove macro.
11544
11545         * config/mips/mips.h (FRAME_POINTER_REQUIRED): Remove macro.
11546         * config/mips/mips.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
11547         (mips_frame_pointer_required): Make as static.
11548         * config/mips/mips-protos.h (mips_frame_pointer_required): Remove.
11549
11550         * config/mmix/mmix.h (FRAME_POINTER_REQUIRED): Remove macro.
11551         * config/mmix/mmix.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
11552         (mmix_frame_pointer_required): Mew function.
11553
11554         * config/moxie/moxie.h (FRAME_POINTER_REQUIRED): Remove macro.
11555         * config/moxie/moxie.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
11556
11557         * config/pa/pa.h (FRAME_POINTER_REQUIRED): Remove macro.
11558
11559         * config/score/score.h (FRAME_POINTER_REQUIRED): Remove macro.
11560
11561         * config/sh/sh.h (CAN_ELIMINATE): Remove macro.
11562
11563         * config/sparc/sparc.h (FRAME_POINTER_REQUIRED): Remove macro.
11564         (CAN_ELIMINATE): Redefine.
11565         * config/sparc/sparc.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
11566         (sparc_frame_pointer_required): New function.
11567         (sparc_can_eliminate): New function.
11568         * config/sparc/sparc-protos.h (sparc_can_eliminate): Declare.
11569
11570         * config/vax/vax.h (FRAME_POINTER_REQUIRED): Remove macro.
11571         * config/vax/vax.c (TARGET_FRAME_POINTER_REQUIRED): Define.
11572
11573         * config/xtensa/xtensa.h (FRAME_POINTER_REQUIRED): Remove macro.
11574         * config/xtensa/xtensa.c (TARGET_FRAME_POINTER_REQUIRED): Define.
11575         (xtensa_frame_pointer_required): Make as static, change return type
11576         to bool.
11577         * config/xtensa/xtensa-protos.h (xtensa_frame_pointer_required):
11578         Remove.
11579
11580 2009-06-29  Olatunji Ruwase  <tjruwase@google.com>
11581
11582         * doc/plugins.texi: Document PLUGIN_START_UNIT.
11583         * toplev.c (compile_file): Call PLUGIN_START_UNIT.
11584         * gcc-plugin.h (PLUGIN_START_UNIT): Added new event.
11585         * plugin.c (plugin_event_name): Added PLUGIN_START_UNIT.
11586         (register_callback): Handle PLUGIN_START_UNIT.
11587         (invoke_plugin_callbacks): Handle PLUGIN_START_UNIT.
11588
11589 2009-06-29  Eric Botcazou  <ebotcazou@adacore.com>
11590
11591         * tree.c (process_call_operands): Propagate TREE_READONLY from the
11592         operands.
11593         (PROCESS_ARG): Do not clear TREE_READONLY if CONSTANT_CLASS_P.
11594         (build3_stat): Propagate TREE_READONLY for COND_EXPR.
11595
11596 2009-06-29  Daniel Jacobowitz  <dan@codesourcery.com>
11597
11598         * config/arm/arm.h (REGISTER_MOVE_COST): Increase VFP register
11599         move cost.
11600
11601 2009-06-29  Uros Bizjak  <ubizjak@gmail.com>
11602
11603         * doc/extend.texi (Additional Floating Types): __float128 is also
11604         supported on i386 targets.
11605
11606 2009-06-29  Richard Guenther  <rguenther@suse.de>
11607
11608         PR middle-end/14187
11609         * tree-ssa-alias.h (struct pt_solution): Add vars_contains_restrict
11610         flag.
11611         (pt_solutions_same_restrict_base): Declare.
11612         * tree-ssa-structalias.c (struct variable_info): Add is_restrict_var
11613         flag.
11614         (new_var_info): Initialize is_global_var properly for SSA_NAMEs.
11615         (make_constraint_from, make_copy_constraint): Move earlier.
11616         (make_constraint_from_heapvar): New function.
11617         (make_constraint_from_restrict): Likewise.
11618         (handle_lhs_call): Use it.
11619         (find_func_aliases): Use it to track conversions to restrict
11620         qualified pointers.
11621         (struct fieldoff): Add only_restrict_pointers flag.
11622         (push_fields_onto_fieldstack): Initialize it.
11623         (create_variable_info_for): Track global restrict qualified pointers.
11624         (intra_create_variable_infos): Use make_constraint_from_heapvar.
11625         Track restrict qualified pointer arguments.
11626         (set_uids_in_ptset): Use varinfo is_global_var flag.
11627         (find_what_var_points_to): Set the vars_contains_restrict flag.
11628         Always create the points-to solution for sets including restrict tags.
11629         (pt_solutions_same_restrict_base): New function.
11630         * tree-ssa-alias.c (ptr_derefs_may_alias_p): For two restrict
11631         qualified pointers use pt_solutions_same_restrict_base as
11632         additional source for disambiguation.
11633
11634 2009-06-29  Richard Guenther  <rguenther@suse.de>
11635
11636         PR middle-end/38212
11637         * alias.c (find_base_decl): Remove.
11638         (get_deref_alias_set_1): Remove restrict handling.
11639         * c-common.c (c_apply_type_quals_to_decl): Do not set
11640         DECL_POINTER_ALIAS_SET.
11641         * gimplify.c (find_single_pointer_decl_1): Remove.
11642         (find_single_pointer_decl): Likewise.
11643         (internal_get_tmp_var): Remove restrict handling.
11644         (gimple_regimplify_operands): Likewise.
11645         * omp-low.c (expand_omp_atomic_pipeline): Do not set
11646         DECL_POINTER_ALIAS_SET. Use ref-all pointers.
11647         * print-tree.c (print_node): Do not print DECL_POINTER_ALIAS_SET.
11648         * tree.c (restrict_base_for_decl): Remove.
11649         (init_ttree): Do not allocate it.
11650         (make_node_stat): Do not set DECL_POINTER_ALIAS_SET.  Set
11651         LABEL_DECL_UID for label decls.
11652         (copy_node_stat): Do not copy restrict information.
11653         (decl_restrict_base_lookup): Remove.
11654         (decl_restrict_base_insert): Likewise.
11655         (print_restrict_base_statistics): Likewise.
11656         (dump_tree_statistics): Do not call print_restrict_base_statistics.
11657         * tree.h (DECL_POINTER_ALIAS_SET): Remove.
11658         (DECL_POINTER_ALIAS_SET_KNOWN_P): Likewise.
11659         (struct tree_decl_common): Rename pointer_alias_set to label_decl_uid.
11660         (LABEL_DECL_UID): Adjust.
11661         (DECL_BASED_ON_RESTRICT_P): Remove.
11662         (DECL_GET_RESTRICT_BASE): Likewise.
11663         (SET_DECL_RESTRICT_BASE): Likewise.
11664         (struct tree_decl_with_vis): Remove based_on_restrict_p flag.
11665
11666         * config/i386/i386.c (ix86_gimplify_va_arg): Use ref-all pointers
11667         instead of DECL_POINTER_ALIAS_SET.
11668         * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Likewise.
11669         * config/s390/s390.c (s390_gimplify_va_arg): Likewise.
11670         * config/spu/spu.c (spu_gimplify_va_arg_expr): Likewise.
11671
11672 2009-06-29  Richard Guenther  <rguenther@suse.de>
11673
11674         PR tree-optimization/40579
11675         * tree-vrp.c (vrp_evaluate_conditional): Bail out early if
11676         the IL to simplify has constants that overflowed.
11677
11678 2009-06-28  Uros Bizjak  <ubizjak@gmail.com>
11679
11680         PR tree-optimization/40550
11681         * tree-vect-generic.c (expand_vector_operations_1): Compute in
11682         vector_compute_type only when the size of vector_compute_type is
11683         less than the size of type.
11684
11685 2009-06-28  Eric Botcazou  <ebotcazou@adacore.com>
11686
11687         * fold-const.c (contains_label_1): Fix comments.
11688         (contains_label_p): Do not walk trees multiple time.
11689
11690 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
11691
11692         * config/i386/i386.h (enum ix86_fpcmp_strategy): New.
11693         * config/i386/i386.md (cbranchxf4, cstorexf4, cbranch<MODEF>4,
11694         cstore<MODEF>4, mov<X87MODEF>cc): Change predicate to
11695         ix86_fp_comparison_operator.
11696         (*fp_jcc_1_mixed, *fp_jcc_1_sse, *fp_jcc_1_387, *fp_jcc_2_mixed,
11697         *fp_jcc_2_sse, *fp_jcc_2_387): Delete
11698         (*fp_jcc_3_387, *fp_jcc_4_387, *fp_jcc_5_387, *fp_jcc_6_387,
11699         *fp_jcc_7_387, *fp_jcc_8<MODEF>_387): Eliminate call to
11700         !ix86_use_fcomi_compare, change ix86_fp_jump_nontrivial_p call
11701         to !TARGET_CMOVE, change predicate to ix86_fp_comparison_operator.
11702         (related splits): Change predicate to ix86_fp_comparison_operator.
11703         * config/i386/predicates.md: Use ix86_trivial_fp_comparison_operator
11704         instead of ix86_fp_comparison_codes.
11705         (ix86_trivial_fp_comparison_operator,
11706         ix86_fp_comparison_operator): New.
11707         * config/i386/i386-protos.h (ix86_fp_comparison_strategy): New.
11708         (ix86_expand_compare): Eliminate last two parameters.
11709         (ix86_fp_jump_nontrivial_p): Kill.
11710         * config/i386/i386.c (put_condition_code): Eliminate call to
11711         ix86_fp_comparison_codes and subsequent assertion.
11712         (ix86_fp_comparison_codes): Eliminate.
11713         (ix86_fp_swap_condition): New.
11714         (ix86_fp_comparison_arithmetics_cost, ix86_fp_comparison_fcomi_cost,
11715         ix86_fp_comparison_sahf_cost, ix86_use_fcomi_compare): Consolidate
11716         into ix86_fp_comparison_cost and ix86_fp_comparison_strategy.
11717         (ix86_prepare_fp_compare_args): Use ix86_fp_comparison_strategy
11718         and ix86_fp_swap_condition.
11719         (ix86_expand_fp_compare): Eliminate code for second jump/bypass jump.
11720         Use ix86_fp_comparison_strategy.
11721         (ix86_expand_compare): Likewise.  Eliminate last two arguments.
11722         (ix86_fp_jump_nontrivial_p): Eliminate.
11723         (ix86_expand_branch): Treat SFmode/DFmode/XFmode as simple.  Adjust
11724         call to ix86_expand_compare.
11725         (ix86_split_fp_branch, ix86_expand_setcc,
11726         ix86_expand_carry_flag_compare, ix86_expand_int_movcc,
11727         ix86_expand_fp_movcc): Eliminate code for second jump/bypass jump.
11728
11729 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
11730
11731         * config/arm/arm.c (arm_final_prescan_ins): Eliminate code
11732         related to jump_clobbers.
11733         * config/arm/arm.md (conds): Remove jump_clob case.
11734         (addsi3_cbranch, addsi3_cbranch_scratch, subsi3_cbranch, two
11735         splits): Change comparison_operator to arm_comparison_operator.
11736         (*arm_buneq, *arm_bltgt, *arm_buneq_reversed, *arm_bltgt_reversed):
11737         Eliminate.
11738
11739 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
11740
11741         * dojump.c (do_compare_rtx_and_jump): Try swapping the
11742         condition for floating point modes.
11743         * expmed.c (emit_store_flag_1): Move here a bigger part
11744         of emit_store_flag.
11745         (emit_store_flag): Try swapping the condition for floating point
11746         modes.
11747         * optabs.c (emit_cmp_and_jump_insns): Cope with constant op0 better.
11748
11749 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
11750
11751         * expr.c (expand_expr_real_1): Just use do_store_flag.
11752         (do_store_flag): Drop support for TRUTH_NOT_EXPR.  Use
11753         emit_store_flag_force.
11754         * expmed.c (emit_store_flag_force): Copy here trick
11755         previously in expand_expr_real_1.  Try reversing the comparison.
11756         (emit_store_flag_1): Work if target is NULL.
11757         (emit_store_flag): Work if target is NULL, using the result mode
11758         from the comparison.  Use split_comparison, restructure final part
11759         to simplify conditionals.
11760
11761 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
11762
11763         * builtins.c (expand_errno_check): Use do_compare_rtx_and_jump.
11764         * dojump.c (do_jump): Change handling of floating-point
11765         ops to use just do_compare_and_jump.
11766         (split_comparison): New.
11767         (do_compare_rtx_and_jump): Add here logic coming previously
11768         in do_jump, using split_comparison.
11769
11770 2009-06-27  H.J. Lu  <hongjiu.lu@intel.com>
11771
11772         PR target/40489
11773         * config/ia64/ia64.c (ia64_reorg): Check NULL insn.
11774
11775 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
11776
11777         * tree-ssa-alias.c: Fix unintentional commit.
11778
11779 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
11780
11781         * passes.c (execute_one_pass): Fix unintentional commit.
11782
11783 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
11784
11785         * df-problems.c (df_set_seen, df_unset_seen): Delete.
11786         (df_rd_local_compute, df_md_local_compute): Inline them.
11787
11788         (df_md_scratch): New.
11789         (df_md_alloc, df_md_free): Allocate/free it.
11790         (df_md_local_compute): Only include live registers in init.
11791         (df_md_transfer_function): Prune the in-set computed by
11792         the confluence function, and the gen-set too.
11793
11794 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
11795
11796         PR rtl-optimization/26854
11797         * timevar.def: Remove TV_DF_RU, add TV_DF_MD.
11798         * df-problems.c (df_rd_add_problem): Fix comment.
11799         (df_md_set_bb_info, df_md_free_bb_info, df_md_alloc,
11800         df_md_simulate_artificial_defs_at_top,
11801         df_md_simulate_one_insn, df_md_bb_local_compute_process_def,
11802         df_md_bb_local_compute, df_md_local_compute, df_md_reset,
11803         df_md_transfer_function, df_md_init, df_md_confluence_0,
11804         df_md_confluence_n, df_md_free, df_md_top_dump, df_md_bottom_dump,
11805         problem_MD, df_md_add_problem): New.
11806         * df.h (DF_MD, DF_MD_BB_INFO, struct df_md_bb_info, df_md,
11807         df_md_get_bb_info): New.
11808         (DF_LAST_PROBLEM_PLUS1): Adjust.
11809
11810         * Makefile.in (fwprop.o): Include domwalk.h.
11811         * fwprop.c: Include domwalk.h.
11812         (reg_defs, reg_defs_stack): New.
11813         (bitmap_only_bit_between): Remove.
11814         (process_defs): New.
11815         (process_uses): Use reg_defs and local_md instead of
11816         bitmap_only_bit_between and local_rd.
11817         (single_def_use_enter_block): New, from build_single_def_use_links.
11818         (single_def_use_leave_block): New.
11819         (build_single_def_use_links): Remove code moved to
11820         single_def_use_enter_block, invoke domwalk.
11821         (use_killed_between): Adjust comment.
11822
11823 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
11824
11825         * bitmap.h (bitmap_ior_and_into): New.
11826         * bitmap.c (bitmap_ior_and_into): New.
11827
11828 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
11829
11830         * domwalk.h (struct dom_walk_data): Remove all callbacks except
11831         before_dom_children_before_stmts and after_dom_children_after_stmts.
11832         Rename the two remaining callbacks to just before_dom_children and
11833         after_dom_children. Remove other GIMPLE statement walking bits.
11834         * domwalk.c (walk_dominator_tree): Remove now unsupported features.
11835         * graphite.c: Do not include domwalk.h.
11836         * tree-into-ssa.c (interesting_blocks): New global.
11837         (struct mark_def_sites_global_data): Remove it and names_to_rename.
11838         (mark_def_sites, rewrite_stmt, rewrite_add_phi_arguments,
11839         rewrite_update_stmt, rewrite_update_phi_arguments): Simplify
11840         now that they're not domwalk callbacks.
11841         (rewrite_initialize_block): Rename to...
11842         (rewrite_enter_block): ... this, place after called functions.  Test
11843         interesting_blocks, call rewrite_stmt and rewrite_add_phi_arguments.
11844         (rewrite_finalize_block): Rename to...
11845         (rewrite_leave_block): ... this, place after called functions.
11846         (rewrite_update_init_block): Rename to...
11847         (rewrite_update_enter_block): ... this, place after called functions.
11848         Test interesting_blocks, call rewrite_update_stmt and
11849         rewrite_update_phi_arguments.
11850         (rewrite_update_fini_block): Rename to...
11851         (rewrite_leave_block): ... this, place after called functions.
11852         (rewrite_blocks): Remove last argument, simplify initialization of
11853         walk_data.
11854         (mark_def_sites_initialize_block): Rename to...
11855         (mark_def_sites_block): ... this, call mark_def_sites.
11856         (mark_def_sites_blocks): Remove argument, simplify initialization of
11857         walk_data.
11858         (rewrite_into_ssa): Adjust for interesting_blocks_being a global.
11859         (update_ssa): Likewise.
11860         * tree-ssa-dom.c (optimize_stmt): Simplify now that it's not a domwalk
11861         callback.
11862         (tree_ssa_dominator_optimize): Simplify initialization of walk_data.
11863         (dom_opt_initialize_block): Rename to...
11864         (dom_opt_enter_block): ... this, place after called functions.  Walk
11865         statements here, inline propagate_to_outgoing_edges.
11866         (dom_opt_finalize_block): Rename to...
11867         (dom_opt_leave_block): ... this, place after called functions.
11868         * tree-ssa-dse.c (dse_optimize_stmt): Simplify now that it's not a
11869         domwalk callback.
11870         (dse_enter_block, dse_record_phi): New.
11871         (dse_record_phis): Delete.
11872         (dse_finalize_block): Rename to...
11873         (dse_leave_block): ... this.
11874         (tree_ssa_dse): Simplify initialization of walk_data.
11875         * tree-ssa-loop-im.c (determine_invariantness, move_computations):
11876         Adjust initialization of walk_data.
11877         * tree-ssa-loop-unswitch.c: Do not include domwalk.h.
11878         * tree-ssa-loop-phiopt.c (get_non_trapping):
11879         Adjust initialization of walk_data.
11880         * tree-ssa-loop-threadedge.c: Do not include domwalk.h.
11881         * tree-ssa-uncprop.c (uncprop_into_successor_phis): Simplify now that
11882         it's not a domwalk callback.
11883         (uncprop_initialize_block): Rename to...
11884         (dse_enter_block): ... this, call uncprop_into_successor_phis.
11885         (dse_finalize_block): Rename to...
11886         (dse_leave_block): ... this.
11887         (tree_ssa_uncprop): Simplify initialization of walk_data.
11888         * Makefile.in: Adjust dependencies.
11889
11890 2009-06-27  Richard Earnshaw  <rearnsha@arm.com>
11891
11892         * arm.md (casesi): Fix test for Thumb1.
11893         (thumb1_casesi_internal_pic): Likewise.
11894         (thumb1_casesi_dispatch): Likewise.
11895
11896 2009-06-26  Daniel Gutson  <dgutson@codesourcery.com>
11897
11898         * config/arm/arm-cores.def: Added core cortex-m0.
11899         * config/arm/arm-tune.md: Regenerated.
11900         * doc/invoke.texi: Added entry for cpu ARM Cortex-M0.
11901
11902 2009-06-26  DJ Delorie  <dj@redhat.com>
11903
11904         * config/mep/mep.opt (mfar): Remove -mfar as it doesn't do anything.
11905
11906         * config/mep/mep.c (mep_bundle_insns): Account for the fact that
11907         the scheduler doesn't tag jump insns.
11908
11909 2009-06-26  H.J. Lu  <hongjiu.lu@intel.com>
11910
11911         * c-decl.c (merge_decls): Re-indent.
11912
11913 2009-06-26  Janis Johnson  <janis187@us.ibm.com>
11914
11915         PR c/39902
11916         * tree.c (real_zerop, real_onep, real_twop, real_minus_onep):
11917         Special-case decimal float constants.
11918
11919 2009-06-26  Richard Henderson  <rth@redhat.com>
11920
11921         * function.h (struct function): Add cannot_be_copied_reason,
11922         and cannot_be_copied_set.
11923         * tree-inline.c (has_label_address_in_static_1): Rename from
11924         inline_forbidden_p_2; don't set inline_forbidden_reason here.
11925         (cannot_copy_type_1): Rename from inline_forbidden_p_op; likewise
11926         don't set inline_forbidden_reason.
11927         (copy_forbidden): New function, split out of inline_forbidden_p.
11928         (inline_forbidden_p_stmt): Don't check for nonlocal labels here.
11929         (inline_forbidden_p): Use copy_forbidden.
11930         (tree_versionable_function_p): Likewise.
11931         (inlinable_function_p): Merge into tree_inlinable_function_p.
11932         (tree_function_versioning): Remap cfun->nonlocal_goto_save_area.
11933         * ipa-cp.c (ipcp_versionable_function_p): New function.
11934         (ipcp_cloning_candidate_p): Use it.
11935         (ipcp_node_modifiable_p): Likewise.
11936
11937 2009-06-26  Olatunji Ruwase  <tjruwase@google.com>
11938
11939         * builtins.c (expand_builtin_alloca): Handle builtin alloca
11940         that is marked not to be inlined. Remove flag_mudflap use.
11941         * tree-mudflap.c: Rename mf_xform_derefs to mf_xfrom_statements.
11942         (mf_xform_statements): Mark builtin alloca calls as un-inlineable.
11943
11944 2009-06-26  Steve Ellcey  <sje@cup.hp.com>
11945
11946         PR bootstrap/40338
11947         * config/pa/t-pa-hpux10 (TARGET_LIBGCC2_CFLAGS): Add -frandom-seed.
11948         * config/pa/t-pa-hpux11 (TARGET_LIBGCC2_CFLAGS): Ditto.
11949
11950 2009-06-26  Kai Tietz  <kai.tietz@onevision.com>
11951
11952         * config/i386/mingw-tls.c (__mingwthr_key_dtor): Remove for none
11953         shared libgcc.
11954         (__mingwthr_remove_key_dtor): Likewise.
11955
11956 2009-06-26  Richard Guenther  <rguenther@suse.de>
11957
11958         * tree-ssa-structalias.c (do_ds_constraint): Simplify escape handling.
11959
11960 2009-06-26  Steven Bosscher  <steven@gcc.gnu.org>
11961
11962         PR middle-end/40525
11963         * ifcvt.c (dead_or_predicable): If predicating MERGE_BB fails,
11964         try the non-cond_exec path also.
11965
11966 2009-06-25  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
11967
11968         PR target/40468
11969         * pa.c (branch_to_delay_slot_p, branch_needs_nop_p): New functions.
11970         (output_cbranch): Use new functions.
11971         (output_lbranch, output_bb, output_bvb, output_dbra, output_movb):
11972         Likewise.
11973
11974 2009-06-25  Michael Meissner  <meissner@linux.vnet.ibm.com>
11975             Pat Haugen  <pthaugen@us.ibm.com>
11976             Revital Eres <ERES@il.ibm.com>
11977
11978         * config/rs6000/rs6000.c (print_operand): Correct lossage message
11979         for %c error.  Add %x support to print VSX registers as a unified
11980         register set, instead of separate float and altivec registers.
11981         Switch to use VECTOR_MEM_ALTIVEC_P instead of TARGET_ALTIVEC for
11982         %y case, and add support for VSX pre-modify addresses.
11983         (output_toc): Add assert for CONST containing an integer constant
11984         in the PLUS case.
11985         (rs6000_adjust_cost): Add POWER7 support.
11986         (insn_must_be_first_in_group): Ditto.
11987         (insn_must_be_last_in_group): Ditto.
11988         (rs6000_emit_popcount): Ditto.
11989         (rs6000_vector_mode_supported_p): Ditto.
11990
11991         * config/rs6000/rs6000-protos.h (rs6000_secondary_reload_class):
11992         Change some of the functions called by macros to being called
11993         through a pointer, so debug functions can be inserted if
11994         -mdebug=addr or -mdebug=cost.
11995         (rs6000_preferred_reload_class_ptr): Ditto.
11996         (rs6000_secondary_reload_class_ptr): Ditto.
11997         (rs6000_secondary_memory_needed_ptr): Ditto.
11998         (rs6000_cannot_change_mode_class_ptr): Ditto.
11999         (rs6000_secondary_reload_inner): Ditto.
12000         (rs6000_legitimize_reload_address): Ditto.
12001         (rs6000_legitimize_reload_address_ptr): Ditto.
12002         (rs6000_mode_dependent_address): Ditto.
12003         (rs6000_mode_dependent_address_ptr): Ditto.
12004
12005         * config/rs6000/rs6000.c (reg_offset_addressing_ok_p): New
12006         function to return true if the mode allows reg + integer
12007         addresses.
12008         (virtual_stack_registers_memory_p): New function to return true if
12009         the address refers to a virtual stack register.
12010         (rs6000_legitimate_offset_address_p): Move code to say whether a
12011         mode supports reg+int addressing to reg_offset_addressing_ok_p and
12012         call it.
12013         (rs6000_legitimate_address_p): Add checks for modes that only can
12014         do reg+reg addressing.  Start adding VSX support.
12015         (rs6000_legitimize_reload_address): Ditto.
12016         (rs6000_legitimize_address): Ditto.
12017         (rs6000_debug_legitimate_address_p): New debug functions for
12018         -mdebug=addr and -mdebug=cost.
12019         (rs6000_debug_rtx_costs): Ditto.
12020         (rs6000_debug_address_costs): Ditto.
12021         (rs6000_debug_adjust_cost): Ditto.
12022         (rs6000_debug_legitimize_address): Ditto.
12023         (rs6000_legitimize_reload_address_ptr): Point to call normal
12024         function or debug function.  Make functions called via pointer
12025         static.
12026         (rs6000_mode_dependent_address_ptr): Ditto.
12027         (rs6000_secondary_reload_class_ptr): Ditto.
12028         (rs6000_hard_regno_mode_ok): Add preliminary VSX support.
12029         (rs6000_emit_move): Add -mdebug=addr support.  Change an abort
12030         into a friendlier error.
12031         (rs6000_init_builtins): Add initial VSX support.
12032         (rs6000_adjust_cost): Fix some spacing issues.
12033
12034         * config/rs6000/rs6000.h (enum reg_class): Add VSX_REGS.
12035         (REG_CLASS_NAMES): Ditto.
12036         (REG_CLASS_CONTENTS): Ditto.
12037         (PREFERRED_RELOAD_CLASS): Move from a macro to calling through a
12038         pointer, to add -mdebug=addr support.
12039         (CANNOT_CHANGE_MODE_CLASS): Ditto.
12040         (SECONDARY_RELOAD_CLASS): Call through a pointer to add
12041         -mdebug=addr support.
12042         (LEGITIMIZE_RELOAD_ADDRESS): Ditto.
12043         (GO_IF_MODE_DEPENDENT_ADDRESS): Ditto.
12044         (enum rs6000_builtins): Add RS6000_BUILTIN_BSWAP_HI.
12045
12046         * config/rs6000/rs6000.md (bswaphi*): Add support for swapping
12047         16-bit values.
12048         (bswapsi*): Set attribute types for load/store.  Add combiner
12049         patterns to eliminate zero extend on 64-bit.
12050         (bswapdi*): Add support for swapping 64-bit values.  Use ldbrx and
12051         stdbrx if the hardware supports those instructions.
12052
12053 2009-06-25  Ian Lance Taylor  <iant@google.com>
12054
12055         * doc/invoke.texi (Option Summary): Mention -static-libstdc++.
12056         (Link Options): Document -static-libstdc++.
12057
12058 2009-06-25  Andrew Pinski  <andrew_pinski@playstation.sony.com>
12059
12060         PR target/38731
12061         * config/rs6000/rs6000.c (LOCAL_ALIGNMENT): Redefine to just use
12062         DATA_ALIGNMENT instead.
12063
12064 2009-06-25  Richard Guenther  <rguenther@suse.de>
12065
12066         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Disambiguate
12067         indirect references against the callused/escaped solutions.
12068         (call_may_clobber_ref_p_1): Likewise.
12069
12070 2009-06-25  Martin Jambor  <mjambor@suse.cz>
12071
12072         PR tree-optimization/40493
12073         * tree-sra.c (sra_modify_expr): Correct BIT_FIELD_REF argument numbers.
12074         (enum unscalarized_data_handling): New type.
12075         (handle_unscalarized_data_in_subtree): Return what has been done.
12076         (load_assign_lhs_subreplacements): Handle left flushes differently.
12077         (sra_modify_assign): Use unscalarized_data_handling, simplified
12078         condition determining whether to remove the statement.
12079
12080 2009-06-25  Basile Starynkevitch  <basile@starynkevitch.net>
12081
12082         * doc/plugins.texi (Building GCC plugins): Correct typo in Makefile
12083         excerpt - @ should be doubled for texinfo.
12084
12085 2009-06-24  Ian Lance Taylor  <iant@google.com>
12086
12087         * config/arc/arc.c: Include "df.h".
12088         (arc_attribute_table): Make static.  Move higher in file.
12089         (arc_address_cost): Call SMALL_INT on INTVAL, not rtx.
12090         (output_shift): Initialize n later to avoid warning.
12091         * config/arm/arm.c (arm_attribute_table): Make static.  Move
12092         higher in file.
12093         * config/avr/avr.c (avr_attribute_table): Make static.  Move
12094         higher in file.
12095         (reg_class_tab): Change array type from int to enum reg_class.
12096         (avr_jump_mode): Change GET_MODE to GET_CODE when checking for
12097         LABEL_REF.
12098         (out_tsthi, ashlhi3_out): Don't use AS2 with "or" or "and".
12099         (lshrhi3_out): Likewise.
12100         (class_likely_spilled_p): Change return type to bool.
12101         (avr_rtx_costs): Use local code variable with enum type.
12102         * config/avr/avr.md (movmemhi): Use add_reg_note.
12103         (andhi3, andsi3): Don't use AS2 with "and".
12104         (iorhi3, iorsi3): Don't use AS2 with "or".
12105         * config/avr/avr-protos.h (class_likely_spilled_p): Update declaration.
12106         * config/crx/crx.c: Include "df.h".
12107         (crx_attribute_table): Make static.
12108         * config/m32r/m32r.c: Include "df.h".
12109         (m32r_attribute_table): Make static.  Move higher in file.
12110         (pop): Use add_reg_note.
12111         (block_move_call): Change 0 to LCT_NORMAL in function call.
12112         * config/m32r/m32r.md (movsi_insn): Remove unused local value.
12113         * config/m32r/m32r.h (INITIALIZE_TRAMPOLINE): Likewise.
12114         * config/m32r/m32r-protos.h (m32r_compute_function_type): Always
12115         declare, not just when TREE_CODE is defined.
12116         * config/m68hc11/m68hc11.c: Include "expr.h".
12117         (m68hc11_attribute_table): Make static.  Move higher in file.
12118         (m68hc11_small_indexed_indirect_p): Change 0 to VOIDmode in
12119         function call.
12120         (m68hc11_register_indirect_p): Likewise.
12121         (m68hc11_function_arg_padding): Change return type to enum
12122         direction.
12123         (emit_move_after_reload): Use add_reg_note.
12124         (m68hc11_emit_logical): Change code parameter to enum rtx_code.
12125         (m68hc11_split_logical): Likewise.
12126         (m68hc11_rtx_costs): Add local code_and outer_code variables with
12127         enum type.
12128         * config/m68hc11/predicates.md (reg_or_some_mem_operand): Change 0
12129         to VOIDmode in function call.
12130         * config/m68hc11/m68hc11-protos.h: Don't check TREE_CODE to see if
12131         tree is defined.
12132         (m68hc11_split_logical): Update declaration.
12133         (m68hc11_function_arg_padding): Update declaration.
12134         * config/mcore/mcore.c (regno_reg_class): Change form array of int
12135         to array of enum reg_class.
12136         (mcore_attribute_table): Make static.  Move higher in file.
12137         (mcore_rtx_costs): Add cast to enum type.
12138         * config/mcore/mcore.h (regno_reg_class): Update declaration.
12139         (GO_IF_LEGITIMATE_INDEX): Add cast to avoid warning.
12140         * config/sh/sh.c (sh_attribute_table): Make static.  Move higher
12141         in file.
12142         * config/sh/predicates.md (trapping_target_operand): Rename and to
12143         and_expr.
12144         * config/sparc/sparc.c (sparc_attribute_table): Make static.  Move
12145         higher in file.
12146         * config/spu/spu.c (spu_attribute_table): Make static.  Move
12147         higher in file.
12148         * config/v850/v850.c (v850_attribute_table): Make static.  Move
12149         higher in file.
12150         (v850_rtx_costs): Use local code with enum type.
12151         (expand_epilogue): Add cast.
12152         * config/v850/v850-c.c (ghs_pragma_section): Initialize repeat.
12153
12154 2009-06-23  Takashi YOSHII  <yoshii.takashi@renesas.com>
12155
12156         PR target/40515
12157         * doc/invoke.texi (SH Options): Document -m2a, -m2a-single,
12158         -m2a-single-only and -m2a-nofpu.
12159         * config/sh/sh.opt: Document m2a generates FPU code.
12160
12161 2009-06-24  Anatoly Sokolov  <aesok@post.ru>
12162
12163         * defaults.h (CAN_ELIMINATE): Provide default.
12164         * doc/tm.texi (CAN_ELIMINATE): Revise documentation.
12165         * config/alpha/alpha.h (CAN_ELIMINATE): Delete.
12166         * config/m32c/m32c.h (CAN_ELIMINATE): Delete.
12167         * config/spu/spu.h (CAN_ELIMINATE): Delete.
12168         * config/xtensa/xtensa.h (CAN_ELIMINATE): Delete.
12169         * config/moxie/moxie.h (CAN_ELIMINATE): Delete.
12170         * config/cris/cris.h (CAN_ELIMINATE): Delete.
12171         * config/mn10300/mn10300.h (CAN_ELIMINATE): Delete.
12172         * config/pa/pa64-linux.h (CAN_ELIMINATE): Delete.
12173         * config/mmix/mmix.h (CAN_ELIMINATE): Delete.
12174
12175 2009-06-24  DJ Delorie  <dj@redhat.com>
12176
12177         * mep-ext-cop.cpu: Fix copyright notice.
12178         * mep-default: Fix copyright notice.
12179         * mep-core: Fix copyright notice.
12180         * mep: Fix copyright notice.
12181         * mep-ivc2: Fix copyright notice.
12182         * mep-c5: Fix copyright notice.
12183
12184 2009-06-24  Denis Chertykov  <chertykov@gmail.com>
12185
12186         * doc/contrib.texi (Contributors):
12187
12188 2009-06-24  Andreas Krebbel  <krebbel1@de.ibm.com>
12189
12190         PR middle-end/40501
12191         * tree-ssa-math-opts.c (execute_optimize_bswap): Convert the bswap
12192         src and dst operands if necessary.
12193
12194 2009-06-23  DJ Delorie  <dj@redhat.com>
12195
12196         Add MeP port.
12197         * config.gcc: Add mep support.
12198         * recog.c: Resurrect validate_replace_rtx_subexp().
12199         * recog.h: Likewise.
12200         * config/mep/: Add new port:
12201         * config/mep/constraints.md: New file.
12202         * config/mep/default.h: New file.
12203         * config/mep/intrinsics.h: New file.
12204         * config/mep/intrinsics.md: New file.
12205         * config/mep/ivc2-template.h: New file.
12206         * config/mep/mep-c5.cpu: New file.
12207         * config/mep/mep-core.cpu: New file.
12208         * config/mep/mep-default.cpu: New file.
12209         * config/mep/mep-ext-cop.cpu: New file.
12210         * config/mep/mep-intrin.h: New file.
12211         * config/mep/mep-ivc2.cpu: New file.
12212         * config/mep/mep-lib1.asm: New file.
12213         * config/mep/mep-lib2.c: New file.
12214         * config/mep/mep-pragma.c: New file.
12215         * config/mep/mep-protos.h: New file.
12216         * config/mep/mep-tramp.c: New file.
12217         * config/mep/mep.c: New file.
12218         * config/mep/mep.cpu: New file.
12219         * config/mep/mep.h: New file.
12220         * config/mep/mep.md: New file.
12221         * config/mep/mep.opt: New file.
12222         * config/mep/predicates.md: New file.
12223         * config/mep/t-mep: New file.
12224
12225 2009-06-23  Ian Lance Taylor  <iant@google.com>
12226
12227         * configure.ac: Invoke AC_PROG_CXX.  Separate C specific warnings
12228         from loose_warn into c_loose_warn and from strict_warn into
12229         c_strict_warn.  Set and substitute warn_cxxflags.  Check for
12230         --enable-build-with-cxx.  Set and substitute
12231         ENABLE_BUILD_WITH_CXX.  Set and substitute HOST_LIBS.
12232         * Makefile.in (CXXFLAGS): New variable.
12233         (C_LOOSE_WARN, C_STRICT_WARN): New variables.
12234         (GCC_WARN_CFLAGS): Add $(C_LOOSE_WARN).  Add $(C_STRICT_WARN) if
12235         the default is the same as $(STRICT_WARN).
12236         (GCC_WARN_CXXFLAGS, WARN_CXXFLAGS): New variables.
12237         (CXX): New variable.
12238         (COMPILER): New value if ENABLE_BUILD_WITH_CXX.
12239         (COMPILER_FLAGS, LINKER, LINKER_FLAGS): Likewise.
12240         (ALL_COMPILERFLAGS, ALL_LINKERFLAGS): Likewise.
12241         (HOST_LIBS): New variable.
12242         (GCC_CFLAGS): Add $(C_LOOSE_WARN).
12243         (ALL_CXXFLAGS): New variable.
12244         (LIBS, BACKENDLIBS): Add $(HOST_LIBS).
12245         * doc/install.texi (Configuration): Document
12246         --enable-build-with-cxx, --with-stage1-ldflags,
12247         --with-stage1-libs, --with-boot-ldflags, --with-boot-libs.
12248         * configure: Rebuild.
12249
12250 2009-06-24  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
12251
12252         * config/arm/arm.c (arm_override_options): Fix braces and formatting
12253         from previous commit.
12254
12255 2009-06-23  Ian Lance Taylor  <iant@google.com>
12256
12257         * Makefile.in ($(out_object_file)): Depend upon $(DF_H).
12258
12259 2009-06-23  Ian Lance Taylor  <iant@google.com>
12260
12261         * reload.c (alternative_allows_const_pool_ref): Mark mem parameter
12262         with ATTRIBUTE_UNUSED.
12263
12264 2009-06-23  Michael Meissner  <meissner@linux.vnet.ibm.com>
12265             Pat Haugen  <pthaugen@us.ibm.com>
12266             Revital Eres  <eres@il.ibm.com>
12267
12268         * config.in (HAVE_AS_POPCNTD): Add default definition.
12269         (HAVE_AS_LWSYNC): Ditto.
12270
12271         * configure.ac (gcc_cv_as_powerpc_mfpgpr): Provide real binutils
12272         release number.
12273         (gcc_cv_as_powerpc_cmpb): Ditto.
12274         (gcc_cv_as_powerpc_dfp): Ditto.
12275         (gcc_cv_as_powerpc_vsx): Ditto.
12276         (gcc_cv_as_powerpc_popcntd): Add feature test for assembler
12277         supporting the popcntd/lwsync instructions.
12278         (gcc_cv_as_powerpc_lwsync): Ditto.
12279         * configure: Regenerate.
12280
12281         * config/rs6000/aix53.h (ASM_CPU_SPEC): Add support for
12282         -mcpu=native and -mcpu=power7.
12283         * config/rs6000/aix61.h (ASM_CPU_SPEC): Ditto.
12284
12285         * config/rs6000/linux64.opt (-mprofile-kernel): Move switch to be
12286         a variable instead of a mask to reduce the number of mask bits.
12287         * config/rs6000/sysv4.opt (-mbit-align): Ditto.
12288         (-mbit-word): Ditto.
12289         (-mregnames): Ditto.
12290         * config/rs6000/rs6000.opt (-mupdate): Ditto.
12291         (-mfused-madd): Ditto.
12292
12293         * config/rs6000/rs6000.opt (-mpopcntd): New switch for non-VSX ISA
12294         2.06 instructions.
12295         (-mvsx): New switch for VSX instructions.
12296         (-misel): Move from a variable to a mask to allow it to be set by
12297         -mcpu=.
12298
12299         * config/rs6000/rs6000-protos.h (rs6000_hard_regno_nregs): Change
12300         function declaration to an array declaration.
12301         (rs6000_hard_regno_nregs): New external array declaration.
12302
12303         * config/rs6000/t-rs6000 (MD_INCLUDES): Define, add all of the .md
12304         files included by rs6000.md.
12305
12306         * config/rs6000/linux64.h (SUBSUBTARGET_OVERRIDE_OPTIONS): Use
12307         SET_PROFILE_KERNEL macro to reset the -mprofile-kernel switch.
12308
12309         * config/rs6000/rs6000.c (rs6000_isel): Delete, -misel moved to be
12310         a target mask.
12311         (rs6000_debug_reg): New -mdebug= variables.
12312         (rs6000_debug_addr): Ditto.
12313         (rs6000_debug_cost): Ditto.
12314         (rs6000_pmode): New variable to hold Pmode.
12315         (rs6000_pointer_size): New variable to hold POINTER_SIZE.
12316         (rs6000_class_max_nregs): New array to hold CLASS_MAX_NREGS
12317         calculated at compiler start.
12318         (rs6000_hard_regno_nregs): Change function to an array which holds
12319         HARD_REGNO_NREGS calculated at compiler start.
12320         (rs6000_explicit_options): Delete isel field.
12321         (rs6000_vector_unit): New array to hold which vector unit
12322         supports arithmetic options for a given type.
12323         (rs6000_vector_mem): New array to hold which vector unit supports
12324         memory reference operations for a given type.
12325         (rs6000_vector_align): New array to given the alignment of each
12326         vector type.
12327         (power7_cost): New basic costs for power7.
12328         (SET_PROFILE_KERNEL): New macro for resetting -mprofile-kernel.
12329         (rs6000_hard_regno_nregs_internal): New function, moved from
12330         HARD_REGNO_NREGS, to calculate the number of registers each hard
12331         register takes for each type.
12332         (rs6000_debug_reg_print): New function for -mdebug=reg support.
12333         (rs6000_debug_vector_unit): New array, map rs6000_vector to string.
12334         (+rs6000_init_hard_regno_mode_ok): New function, move calculation
12335         of HARD_REGNO_NREGS, CLASS_MAX_NREGS, REGNO_REG_CLASS, and vector
12336         unit information here so it is calculated once at compiler startup
12337         time.
12338         (rs6000_override_options): Make -misel a target mask.  Add more
12339         power7 target masks.  Setup Pmode and POINTER_SIZE.  Add initial
12340         VSX support.  Add support for -mdebug=reg, -mdebug=addr, and
12341         -mdebug=cost.
12342         (POWERPC_MASKS): Add MASK_POPCNTD, MASK_VSX, and MASK_ISEL.
12343         (rs6000_handle_option): Move -misel from variable to target mask.
12344         (rs6000_builtin_mask_for_load): Add VSX support.
12345         (rs6000_conditional_register_usage): Ditto.
12346         (USE_ALTIVEC_FOR_ARG_P): Ditto.
12347         (function_arg_boundary): Ditto.
12348         (rs6000_expand_builtin): Ditto.
12349         (def_builtin): Make abort message a little friendlier.
12350         (rs6000_emit_int_cmove): Add support for 64-bit isel.
12351
12352         * config/rs6000/rs6000.h (ASM_CPU_POWER7_SPEC): Depend on the
12353         assembler support the popcntd instruction instead of a vsx
12354         instruction to enable power7 support.
12355         (ASM_CPU_SPEC): Add support for -mcpu=native and -mcpu=power7.
12356         (EXTRA_SPECS): Add ASM_CPU_NATIVE_SPEC to allow passing the right
12357         option to the assembler if -mcpu=native.
12358         (ASM_CPU_NATIVE_SPEC): Ditto.
12359         (TARGET_POPCNTD): If assembler doesn't support popcntd, turn off
12360         ISA 2.06 features.
12361         (TARGET_LWSYNC_INSTRUCTION): Define whether it is safe to issue
12362         the lwsync instruction.
12363         (enum processor_type): Add PROCESSOR_POWER7.
12364         (rs6000_debug_reg): New -mdebug= options.
12365         (rs6000_debug_addr): Ditto.
12366         (rs6000_debug_cost): Ditto.
12367         (rs6000_isel): Delete.
12368         (enum rs6000_vector): New enum to say what vector unit we have.
12369         (VECTOR_UNIT_*): New macros to say which vector unit has
12370         arithmetic operations for a given type.
12371         (VECTOR_MEM_*): New macros to say which vector unit has memory
12372         operations for a given type.
12373         (TARGET_LDBRX): Whether the machine supports the ldbrx
12374         instruction.
12375         (TARGET_ISEL): Delete, -misel moved to be a mask.
12376         (TARGET_ISEL64): New macro for 64-bit isel support.
12377         (UNITS_PER_VSX_WORD): New macro.
12378         (POINTER_SIZE): Move to be an external variable, rather than
12379         calculating whether we are generating 32 ot 64-bit code.
12380         (Pmode): Ditto.
12381         (STACK_BOUNDARY): Add VSX support.
12382         (LOCAL_ALIGNMENT): Ditto.
12383         (SLOW_UNALIGNED_ACCESS): Ditto.
12384         (VSX_REGNO_P): New macro for VSX support.
12385         (VFLOAT_REGNO_P): Ditto.
12386         (VINT_REGNO_P): Ditto.
12387         (VLOGICAL_REGNO_P): Ditto.
12388         (VSX_VECTOR_MODE): Ditto.
12389         (VSX_SCALAR_MODE): Ditto.
12390         (VSX_MODE): Ditto.
12391         (VSX_MOVE_MODE): Ditto.
12392         (VSX_REG_CLASS_P): Ditto.
12393         (HARD_REGNO_NREGS): Instead of calling a function, use an array
12394         lookup.
12395         (UNITS_PER_SIMD_WORD): Add VSX support.
12396         (MODES_TIEABLE_P): Ditto.
12397         (STARTING_FRAME_OFFSET): Ditto.
12398         (STACK_DYNAMIC_OFFSET): Ditto.
12399         (EPILOGUE_USES): Ditto.
12400         (REGNO_REG_CLASS): Move to array lookup.
12401         (CLASS_MAX_NREGS): Ditto.
12402         (rs6000_vector_reg_class): Add declaration.
12403         (ADDITIONAL_REGISTER_NAMES): Add VSX names for the registers that
12404         overlap with the floating point and Altivec registers.
12405
12406         * config/rs6000/e500.h (CHECK_E500_OPTIONS): Disallow -mvsx.
12407
12408         * config/rs6000/driver-rs6000.c (asm_names): New static array to
12409         give the appropriate asm switches if -mcpu=native.
12410         (host_detect_local_cpu): Add support for "asm".
12411         (host_detect_local_cpu): Follow GNU code guidelines for name.
12412
12413         * config/rs6000/sysv4.h (SUBTARGET_OVERRIDE_OPTIONS): Move
12414         -mbit-word to a variable instead of being a target mask.
12415
12416         * config/rs6000/sync.md (lwsync): If the assembler supports it,
12417         emit the lwsync instruction instead of emitting the instruction as
12418         an integer constant.
12419
12420         * config/rs6000/spe.md (spe_fixuns_truncdfsi2): Rename from
12421         fixuns_trundfsi2, move expander into rs6000.md.
12422
12423         * config/rs6000/rs6000.md (cpu): Add power7.
12424         (sel, *ptrsize): New mode attributes for 32/64-bit isel.
12425         (logical predicate patterns): Change the single instruction
12426         primitives that set CR0 to be fast_compare instead of compare.
12427         (norsi*): Ditto.
12428         (popcntwsi2): Add support for ISA 2.06 popcount instructions.
12429         (popcntddi2): Ditto.
12430         (popcount<mode>): Ditto.
12431         (floating multiply/add insns): Name the floating point
12432         multiply/add insns.
12433         (isel_signed_<mode>): Add support for -misel on 64-bit systems.
12434         (isel_unsigned_<mode>): Ditto.
12435         (fixuns_trundfsi2): Move expander here from spe.md.
12436         (smindi3): Define if we have -misel on 64-bit systems.
12437         (smaxdi3): Ditto.
12438         (umindi3): Ditto.
12439         (umaxdi3): Ditto.
12440
12441 2009-06-23  Anatoly Sokolov  <aesok@post.ru>
12442
12443         * config.gcc (avr-*-rtems*, avr-*-*): Set extra_gcc_objs and
12444         extra_objs.
12445         * config/avr/avr.c (avr_current_device): New variable.
12446         (avr_arch_types, avr_mcu_types): Move to avr-deveces.c.
12447         (avr_arch, mcu_type_s): Move to avr.h.
12448         * config/avr/avr.h (base_arch_s). Add reserved2, arch_name and
12449         default_data_section_start fields.
12450         (avr_arch): Moved from avr.c.
12451         (mcu_type_s): Moved from avr.c. Add short_sp, data_section_start and
12452         library_name fields.
12453         (avr_current_device, avr_mcu_types, avr_arch_types,
12454         avr_device_to_arch, avr_device_to_data_start,
12455         avr_device_to_startfiles, avr_device_to_devicelib): Declare.
12456         (EXTRA_SPEC_FUNCTIONS): Define.
12457         (LINK_SPEC): Remove device name to '-m ...' and '-Tdata ...' linker
12458         options mapping. Use device_to_arch and device_to_data_start insted.
12459         (STARTFILE_SPEC): Use device_to_startfile instead of crt_binutils.
12460         (CRT_BINUTILS_SPECS, EXTRA_SPECS): Remove.
12461         * config/avr/t-avr (driver-avr.o, avr-devices.o): New rules.
12462         * config/avr/driver-avr.c: New file.
12463         * config/avr/avr-devices.c: New file.
12464
12465 2009-06-23  Jakub Jelinek  <jakub@redhat.com>
12466
12467         * var-tracking.c (unshare_variable): Force initialized to
12468         be VAR_INIT_STATUS_INITIALIZED unless flag_var_tracking_uninit.
12469         (set_variable_part): Likewise.
12470         (struct variable_union_info): Remove pos_src field.
12471         (vui_vec, vui_allocated): New variables.
12472         (variable_union): Pass VAR_INIT_STATUS_UNKNOWN to unshare_variable
12473         unconditionally.  Avoid XCVECNEW/free for every sorting, for dst_l
12474         == 1 use a simpler sorting algorithm.  Compute pos field right
12475         away, don't fill in pos_src.  For dst_l == 2 avoid qsort.
12476         Avoid quadratic comparison if !flag_var_tracking_uninit.
12477         (variable_canonicalize): Pass VAR_INIT_STATUS_UNKNOWN to
12478         unshare_variable unconditionally.
12479         (dataflow_set_different_2): Removed.
12480         (dataflow_set_different): Don't traverse second hash table.
12481         (compute_bb_dataflow): Pass VAR_INIT_STATUS_UNINITIALIZED
12482         unconditionally to var_reg_set or var_mem_set.
12483         (emit_notes_in_bb): Likewise.
12484         (delete_variable_part): Pass VAR_INIT_STATUS_UNKNOWN to
12485         unshare_variable.
12486         (emit_note_insn_var_location): Don't set initialized to
12487         VAR_INIT_STATUS_INITIALIZED early.
12488         (vt_finalize): Free vui_vec if needed, clear vui_vec and
12489         vui_allocated.
12490         * rtl.c (rtx_equal_p): Don't implement on top of rtx_equal_p_cb.
12491
12492         * tree-object-size.c (addr_object_size): Instead of checking
12493         for non-NULL TREE_CHAIN of the FIELD_DECL check that there
12494         are no FIELD_DECLs following it.
12495
12496 2009-06-23  Andreas Krebbel  <krebbel1@de.ibm.com>
12497
12498         * tree-ssa-math-opts.c (find_bswap): Increase the search depth in
12499         order to match bswaps with signed source operands.
12500
12501 2009-06-23  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
12502
12503         * sdbout.c (sdbout_one_type): Fix braces in switch.
12504
12505 2009-06-23  Richard Guenther  <rguenther@suse.de>
12506
12507         * tree-ssa-structalias.c (struct variable_info): Add is_global_var
12508         member.
12509         (var_anything, anything_tree, var_nothing, nothing_tree, var_readonly,
12510         readonly_tree, var_escaped, escaped_tree, var_nonlocal, nonlocal_tree,
12511         var_callused, callused_tree, var_storedanything, storedanything_tree,
12512         var_integer, integer_tree): Remove global variables.
12513         (new_var_info): Do not pass new id, append the new var to the
12514         global variable vector.
12515         (do_ds_constraint): Use is_global_var member of the variable-info.
12516         (new_scalar_tmp_constraint_exp): Adjust.
12517         (create_function_info_for): Likewise.
12518         (create_variable_info_for): Likewise.
12519         (find_what_var_points_to): Remove dead code.
12520         (init_base_vars): Simplify.
12521         (compute_points_to_sets): Adjust.
12522
12523 2009-06-22  Adam Nemet  <anemet@caviumnetworks.com>
12524
12525         * combine.c (try_combine): Dump information about the insns we're
12526         combining.
12527
12528 2009-06-22  Adam Nemet  <anemet@caviumnetworks.com>
12529
12530         * combine.c (combine_simplify_rtx): Remove TRULY_NOOP_TRUNCATION
12531         check when calling force_to_mode on TRUNCATE's operand.
12532
12533 2009-06-22  Ian Lance Taylor  <iant@google.com>
12534
12535         * config/rs6000/rs6000.opt: Move msched-epilog before msched-prolog.
12536
12537 2009-06-22  Steven Bosscher  <steven@gcc.gnu.org>
12538
12539         * config/arm/arm.md (prologue_use): Set length of fake insn to 0.
12540
12541 2009-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12542
12543         * doc/invoke.texi (Link Options): -nodefaultlibs and -nostdlib
12544         override library linkage flags such as -static-libgcc or
12545         -shared-libgcc.
12546
12547 2009-06-22  Maxim Kuvyrkov  <maxim@codesourcery.com>
12548
12549         * config/m68k/m68k-devices.def: Add line for MCF5221x.
12550
12551 2009-06-22  Ian Lance Taylor  <iant@google.com>
12552
12553         * config/linux.opt: Put mglibc ahead of muclibc.
12554
12555         * c-decl.c (diagnose_mismatched_decls): Add -Wc++-compat warning
12556         for duplicate decls.
12557
12558 2009-06-22  Matthias Klose  <doko@ubuntu.com>
12559
12560         * Makefile.in (install-plugin): Remove extra `/' after $(DESTDIR).
12561
12562 2009-06-22  Steven Bosscher  <steven@gcc.gnu.org>
12563
12564         PR objc/28050
12565         * c-parser.c (c_parser_objc_message_args): Return error_mark_node
12566         instead of NULL if a parser error occurs.
12567
12568 2009-06-22  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
12569
12570         * dwarf2out.c (dwarf2_debug_hooks): Initialize
12571         non-DWARF2_DEBUGGING_INFO version.
12572
12573 2009-06-22  Kai Tietz  <kai.tietz@onevision.com>
12574
12575         * config.gcc (i[34567]86-*-mingw*, x86_64-*-mingw*): Add
12576         i386/t-fprules-softfp and soft-fp/t-softfp to tmake_file.
12577
12578         * config/i386/mingw32.h (LIBGCC2_HAS_TF_MODE): Define.
12579         (LIBGCC2_TF_CEXT): Define.
12580         (TF_SIZE): Define.
12581
12582 2009-06-22  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
12583
12584         PR target/40463
12585         * config/arm/linux-eabi.h (CLEAR_INSN_CACHE): Fix definition.
12586
12587 2009-06-22  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
12588
12589         * config/arm/arm.c (arm_override_options): Disable
12590         -mcaller-super-interworking and -mcallee-super-interworking.
12591         * doc/invoke.texi (ARM Options): Document this.
12592
12593 2009-06-22  Nathan Sidwell  <nathan@codesourcery.com>
12594
12595         * config/arm/arm.c (arm_print_operand): Deal with HIGH.
12596         * config/arm/constraints.md (j): New constraint for movw operands.
12597         (N): Remove thumb2 meaning.
12598         * config/arm/arm.md (*arm_movw): Delete.
12599         (*arm_movsi_insn): Use j constraint for movw instead of N constraint.
12600         * config/arm/vfp.md (*arm_movsi_vfp, *thumb2_movsi_vfp): Likewise.
12601         * config/arm/thumb2.md (*thumb2_movsi_insn): Likewise.
12602
12603 2009-06-22  Martin Jambor  <mjambor@suse.cz>
12604
12605         PR tree-optimization/40492
12606         * tree-sra.c (sra_modify_assign): Pass zero offsets to
12607         build_ref_for_offset.
12608
12609 2009-06-22  Shujing Zhao  <pearly.zhao@oracle.com>
12610
12611         * alias.c: Use REG_P, MEM_P, CONST_INT_P, LABEL_P, CALL_P, NOTE_P and
12612         JUMP_TABLE_DATA_P predicates where applicable.
12613         * auto-inc-dec.c: Ditto.
12614         * builtins.c: Ditto.
12615         * caller-save.c: Ditto.
12616         * calls.c: Ditto.
12617         * cfgcleanup.c: Ditto.
12618         * cfglayout.c: Ditto.
12619         * cfgrtl.c: Ditto.
12620         * combine.c: Ditto.
12621         * combine-stack-adj.c: Ditto.
12622         * cse.c: Ditto.
12623         * cselib.c: Ditto.
12624         * dbxout.c: Ditto.
12625         * df-scan.c: Ditto.
12626         * dse.c: Ditto.
12627         * dwarf2asm.c: Ditto.
12628         * dwarf2out.c: Ditto.
12629         * emit-rtl.c: Ditto.
12630         * except.c: Ditto.
12631         * explow.c: Ditto.
12632         * expmed.c: Ditto.
12633         * expr.c: Ditto.
12634         * final.c: Ditto.
12635         * function.c: Ditto.
12636         * fwprop.c: Ditto.
12637         * gcse.c: Ditto.
12638         * genpreds.c: Ditto.
12639         * genrecog.c: Ditto.
12640         * ifcvt.c: Ditto.
12641         * ira-costs.c: Ditto.
12642         * ira-lives.c: Ditto.
12643         * jump.c: Ditto.
12644         * loop-iv.c: Ditto.
12645         * lower-subreg.c: Ditto.
12646         * modulo-sched.c: Ditto.
12647         * optabs.c: Ditto.
12648         * postreload.c: Ditto.
12649         * print-rtl.c: Ditto.
12650         * recog.c: Ditto.
12651         * reginfo.c: Ditto.
12652         * regmove.c: Ditto.
12653         * reload1.c: Ditto.
12654         * reload.c: Ditto.
12655         * reorg.c: Ditto.
12656         * rtlanal.c: Ditto.
12657         * rtl.c: Ditto.
12658         * sched-vis.c: Ditto.
12659         * sdbout.c: Ditto.
12660         * sel-sched-ir.c: Ditto.
12661         * simplify-rtx.c: Ditto.
12662         * targhooks.c: Ditto.
12663         * var-tracking.c: Ditto.
12664         * vmsdbgout.c: Ditto.
12665
12666 2009-06-22  Matthias Klose  <doko@ubuntu.com>
12667
12668         * Makefile.in (install-plugin): Always use DESTDIR.
12669
12670 2009-06-22  Olivier Hainque  <hainque@adacore.com>
12671
12672         * config/pa/pa.c (output_call): Don't optimize post call jumps
12673         into return address adjustments if the call may throw.
12674
12675 2009-06-21  Richard Earnshaw  <rearnsha@arm.com>
12676
12677         * arm.c (thumb1_output_casesi): New function.
12678         * arm.h (CASE_VECTOR_PC_RELATIVE): Thumb-1 code is also relative if
12679         optimizing for size or PIC.
12680         (CASE_VECTOR_SHORTEN_MODE): Handle thumb-1.
12681         * arm.md (UNSPEC_THUMB1_CASESI): New constant.
12682         (casesi): Handle Thumb-1 when optimizing for size or PIC.
12683         (thumb1_casesi_internal_pic): New expand rule.
12684         (thumb1_casesi_dispatch): New pattern.
12685         * aout.h (ASM_OUTPUT_ADDR_DIFF_ELT): Use shortened vectors for
12686         thumb-1 mode.
12687         * coff.h (JUMP_TABLES_IN_TEXT_SECTION): Thumb-1 jump tables are now
12688         in the text seciton when PIC or optimizing for size.
12689         * elf.h (JUMP_TABLES_IN_TEXT_SECTION): Likewise.
12690         * lib1funcs.asm ([__ARM_EABI__]): Add an attribute describing stack
12691         preservation properties of code.
12692         (__gnu_thumb1_case_sqi, __gnu_thumb1_case_uqi): New functions.
12693         (__gnu_thumb1_case_shi, __gnu_thumb1_case_uhi): New functions.
12694         (__gnu_thumb1_case_si): New function.
12695         * t-arm (LIB1ASMSRC): Define here.
12696         (LIB1ASMFUNCS): Add some common functions.
12697         * t-arm-elf (LIB1ASMSRC): Delete.
12698         (LIB1ASMFUNCS): Append to existing set.
12699         * t-pe (LIB1ASMSRC, LIB1ASMFUNCS): Likewise.
12700         * t-strongarm-elf (LIB1ASMSRC, LIB1ASMFUNCS): Likewise.
12701         * t-symbian (LIB1ASMFUNCS): Likewise.
12702         * t-vxworks (LIB1ASMSRC, LIB1ASMFUNCS): Likewise.
12703         * t-wince-pe (LIB1ASMSRC, LIB1ASMFUNCS): Likewise.
12704
12705 2009-06-21  Richard Guenther  <rguenther@suse.de>
12706
12707         PR tree-optimization/38729
12708         * tree-ssa-loop-niter.c (find_loop_niter_by_eval): Restrict
12709         to loops with a single exit if -fno-expensive-optimizations.
12710
12711 2009-06-21  Jakub Jelinek  <jakub@redhat.com>
12712
12713         * var-tracking.c (struct shared_hash_def, shared_hash): New types.
12714         (dataflow_set): Change vars type from htab_t to shared_hash.
12715         (shared_hash_pool, empty_shared_hash): New variables.
12716         (vars_clear): Removed.
12717         (shared_hash_shared, shared_hash_htab, shared_hash_copy,
12718         shared_hash_find_slot_unshare, shared_hash_find_slot,
12719         shared_hash_find_slot_noinsert, shared_hash_find): New
12720         static inlines.
12721         (shared_hash_unshare, shared_hash_destroy): New functions.
12722         (unshare_variable): Unshare set->vars if shared, use
12723         shared_hash_htab.
12724         (vars_copy): Use htab_traverse_noresize instead of htab_traverse.
12725         (get_init_value, find_src_set_src, dump_dataflow_set,
12726         clobber_variable_part, emit_notes_for_differences): Use
12727         shared_hash_htab.
12728         (dataflow_set_init): Remove second argument, set vars to
12729         empty_shared_hash instead of creating a new htab.
12730         (dataflow_set_clear): Call shared_hash_destroy and set vars
12731         to empty_shared_hash instead of calling vars_clear.
12732         (dataflow_set_copy): Don't call vars_copy, instead just share
12733         the src htab with dst.
12734         (variable_union): Use shared_hash_*, use initially NO_INSERT
12735         lookup if set->vars is shared.  Don't keep slot cleared before
12736         calling unshare_variable.  Unshare set->vars if needed.
12737         Even ->refcount == 1 vars must be unshared if set->vars is shared
12738         and var needs to be modified.
12739         (variable_canonicalize): New function.
12740         (dataflow_set_union): If dst->vars is empty, just share src->vars
12741         with dst->vars and traverse with variable_canonicalize to canonicalize
12742         and unshare what is needed.
12743         (dataflow_set_different): If old_set and new_set use the same shared
12744         htab, they aren't different.  If number of htab elements is different,
12745         htabs are different.  Use shared_hash_*.
12746         (dataflow_set_destroy): Call shared_hash_destroy instead of
12747         htab_delete.
12748         (compute_bb_dataflow, emit_notes_in_bb, vt_emit_notes): Don't pass
12749         second argument to dataflow_set_init.
12750         (vt_initialize): Likewise.  Initialize shared_hash_pool and
12751         empty_shared_hash, move bb in/out initialization afterwards.
12752         Use variable_htab_free instead of NULL as changed_variables del hook.
12753         (variable_was_changed): Change type of second argument to pointer to
12754         dataflow_set.  When inserting var into changed_variables, bump
12755         refcount.  Unshare set->vars if set is shared htab and slot needs to
12756         be cleared.
12757         (set_variable_part): Use shared_hash_*, use initially NO_INSERT
12758         lookup if set->vars is shared.  Unshare set->vars if needed.
12759         Even ->refcount == 1 vars must be unshared if set->vars is shared
12760         and var needs to be modified.  Adjust variable_was_changed caller.
12761         (delete_variable_part): Use shared_hash_*.  Even ->refcount == 1
12762         vars must be unshared if set->vars is shared and var needs to be
12763         modified.  Adjust variable_was_changed caller.
12764         (emit_note_insn_var_location): Don't pool_free var.
12765         (emit_notes_for_differences_1): Initialize empty_var->refcount to 0
12766         instead of 1.
12767         (vt_finalize): Call htab_delete on empty_shared_hash->htab and
12768         free_alloc_pool on shared_hash_pool.
12769
12770 2009-06-20  Anthony Green  <green@moxielogic.com>
12771
12772         * config/moxie/sfp-machine.h (__gcc_CMPtype, CMPtype): Define.
12773         * config/moxie/moxie.h (LOAD_EXTEND_OP): Define.
12774
12775 2009-06-20  Richard Guenther  <rguenther@suse.de>
12776
12777         * tree-ssa-structalias.c (find_func_aliases): For memset use
12778         a constraint from NULL if we memset to zero.
12779         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Add builtins
12780         we explicitly handle that do not read from memory.
12781         (call_may_clobber_ref_p_1): Properly handle builtins that may
12782         set errno.
12783
12784 2009-06-20  Richard Guenther  <rguenther@suse.de>
12785
12786         PR tree-optimization/40495
12787         * tree-ssa-structalias.c (get_constraint_exp_for_temp): Remove.
12788         (new_scalar_tmp_constraint_exp): New function.
12789         (process_constraint): Do not create temporary decls.
12790         (process_all_all_constraints): Likewise.
12791         (handle_const_call): Likewise.
12792         (create_function_info_for): Do not set decl.
12793
12794 2009-06-19  Ian Lance Taylor  <iant@google.com>
12795
12796         * config/rs6000/rs6000.c (rs6000_explicit_options): Make static.
12797         (rs6000_attribute_table): Make static; move before use.
12798
12799 2009-06-19  Eric Botcazou  <ebotcazou@adacore.com>
12800
12801         * tree.c (substitute_in_expr) <COMPONENT_REF>: Tweak and reformat.
12802         <tcc_vl_exp>: Call process_call_operands on the new CALL_EXPR.
12803         Propagate the TREE_READONLY flag without overwriting it.
12804         (substitute_placeholder_in_expr) <tcc_vl_exp>: Likewise.
12805         Propagate the TREE_READONLY flag onto the result.
12806         (process_call_operands): Move around.  Use correct constant value.
12807
12808 2009-06-19  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
12809
12810         PR target/40482
12811         * config/arm/arm.c (thumb_shiftable_const): Truncate val to 32 bits.
12812         * config/arm/arm.md: Likewise.
12813
12814 2009-06-19  Ian Lance Taylor  <iant@google.com>
12815
12816         * tree-cfg.c (gimple_redirect_edge_and_branch): Change ERROR_MARK
12817         to GIMPLE_ERROR_MARK.
12818
12819         * c-typeck.c (build_conditional_expr): Add op1_original_type and
12820         op2_original_type parameters.  Warn about using different enum types.
12821         * c-parser.c (c_parser_conditional_expression): Pass original
12822         types to build_conditional_expr.
12823         * c-tree.h (build_conditional_expr): Update declaration.
12824
12825 2009-06-19  Ian Lance Taylor  <iant@google.com>
12826
12827         * config/i386/i386.c (ix86_function_specific_save): Test that
12828         fields match values, rather than testing the values are in a
12829         certain range.
12830
12831 2009-06-19  Richard Guenther  <rguenther@suse.de>
12832
12833         * tree-ssa-alias.c (ptr_deref_may_alias_decl_p): Handle
12834         ADDR_EXPR pointers.
12835         (ptr_derefs_may_alias_p): Likewise.
12836         (ptr_deref_may_alias_ref_p_1): New function.
12837         (ptr_deref_may_alias_ref_p): Likewise.
12838         (ref_maybe_used_by_call_p_1): Handle builtins that are not
12839         covered by looking at the ESCAPED solution.
12840         (call_may_clobber_ref_p_1): Likewise.
12841         * tree-ssa-structalias.c (get_constraint_for_ptr_offset):
12842         Handle NULL_TREE offset.  Do not produce redundant constraints.
12843         (process_all_all_constraints): New helper function.
12844         (do_structure_copy): Use it.
12845         (handle_lhs_call): Likewise.
12846         (find_func_aliases): Handle some builtins with pointer arguments
12847         and/or return values explicitly.
12848
12849 2009-06-19  Ian Lance Taylor  <iant@google.com>
12850
12851         * varasm.c (const_rtx_hash_1): Remove const qualifier from shift.
12852
12853 2009-06-19  Ian Lance Taylor  <iant@google.com>
12854
12855         * rtl.h (SUBREG_PROMOTED_UNSIGNED_P): Add cast to int.
12856
12857 2009-06-19  Ian Lance Taylor  <iant@google.com>
12858
12859         * ggc-page.c (ggc_pch_write_object): Initialize emptyBytes.
12860         * sdbout.c (sdb_debug_hooks): Initialize non-SDB_DEBUGGING_INFO
12861         version.
12862
12863         * c-decl.c (finish_decl): If -Wc++-compat, warn about
12864         uninitialized const.
12865
12866 2009-06-19  Ian Lance Taylor  <iant@google.com>
12867
12868         * dse.c (struct store_info): Rename bitmap field to bmap.  Change
12869         all uses.
12870
12871         * c-decl.c (in_struct, struct_types): Remove.
12872         (struct c_binding): Add in_struct field.
12873         (c_binding_ptr): Define type, along with VEC.
12874         (struct c_struct_parse_info): Define.
12875         (struct_parse_info): New static variable.
12876         (bind): Initialize in_struct field.
12877         (start_struct): Remove enclosing_in_struct and
12878         enclosing_struct_types parameters.  Add
12879         enclosing_struct_parse_info parameter.  Change all callers.  Set
12880         struct_parse_info rather than in_struct and struct_types.
12881         (grokfield): If -Wc++-compat and there is a symbol binding for the
12882         field name, set the in_struct flag and push it on the
12883         struct_parse_info->fields vector.
12884         (warn_cxx_compat_finish_struct): New static function.
12885         (finish_struct): Remove enclosing_in_struct and
12886         enclosing_struct_types parameters.  Add
12887         enclosing_struct_parse_info parameter.  Change all callers.  Don't
12888         set C_TYPE_DEFINED_IN_STRUCT here.  Call
12889         warn_cxx_compat_finish_struct.  Free struct_parse_info and set to
12890         parameter.  Only push on struct_types if warn_cxx_compat.
12891         (finish_enum): Only push on struct_types if warn_cxx_compat.
12892         (declspecs_add_type): Add loc parameter.  Change all callers.
12893         Change all error calls to error_at.  Pass loc, not input_location,
12894         to pedwarn calls.  Warn if -Wc++-compat and a typedef name is
12895         defined in a struct.  If -Wc++-compat and parsing a struct, record
12896         that a typedef name was used.
12897         * c-parser.c (c_parser_declspecs): Get location to pass to
12898         declspecs_add_type.
12899         (c_parser_struct_or_union_specifier): Update calls to start_struct
12900         and finish_struct.
12901         * c-tree.h (struct c_struct_parse_info): Declare.
12902         (finish_struct, start_struct): Update declarations.
12903         (declspecs_add_type): Update declaration.
12904
12905 2009-06-19  Ian Lance Taylor  <iant@google.com>
12906
12907         * c-decl.c (grokdeclarator): If -Wc++-compat, warn about a global
12908         variable with an anonymous type.
12909
12910 2009-06-19  Uros Bizjak  <ubizjak@gmail.com>
12911
12912         * see.c: Remove for real.
12913
12914 2009-06-19  Uros Bizjak  <ubizjak@gmail.com>
12915
12916         * optabs.h (enum optab_index): Add new OTI_significand.
12917         (significand_optab): Define corresponding macro.
12918         * optabs.c (init_optabs): Initialize significand_optab.
12919         * genopinit.c (optabs): Implement significand_optab using
12920         significand?f2 patterns.
12921         * builtins.c (expand_builtin_mathfn): Handle
12922         BUILT_IN_SIGNIFICAND{,F,L}.
12923         (expand_builtin): Expand BUILT_IN_SIGNIFICAND{,F,L} using
12924         expand_builtin_mathfn if flag_unsafe_math_optimizations is set.
12925
12926         * config/i386/i386.md (significandxf2, significand<mode>2): New
12927         expanders to implement significandf, significand and significandl
12928         built-ins as inline x87 intrinsics.
12929
12930 2009-06-18  Anatoly Sokolov  <aesok@post.ru>
12931
12932         * config/avr/avr.c (avr_override_options): Remove setting value of
12933         PARAM_INLINE_CALL_COST.
12934
12935 2009-06-18  Richard Henderson  <rth@redhat.com>
12936
12937         PR 40488
12938         * tree-pass.h (TDF_ASMNAME): New.
12939         * tree-dump.c (dump_options): Add asmname.
12940         * doc/invoke.texi: Document it.
12941
12942         * tree-pretty-print.c (maybe_dump_asm_name): Merge into...
12943         (dump_decl_name): ...here.
12944         (dump_function_name): New flags arg; mind TDF_ASMNAME.
12945         (dump_generic_node): Update dump_function_name calls.
12946         (print_call_name): New flags arg; update all dump calls.
12947         * diagnostic.h (print_call_name): Update.
12948         * gimple-pretty-print.c (dump_gimple_call): Update.
12949
12950 2009-06-18  H.J. Lu  <hongjiu.lu@intel.com>
12951
12952         PR target/40470
12953         * config/i386/i386.h (CLASS_LIKELY_SPILLED_P): Add SSE_FIRST_REG.
12954
12955 2009-06-18  Diego Novillo  <dnovillo@google.com>
12956
12957         * doc/plugins.texi: Document plugin_is_GPL_compatible.
12958         * plugin.c (str_license): Declare.
12959         (try_init_one_plugin): Assert that the symbol
12960         'plugin_is_GPL_compatible' exists.
12961
12962 2009-06-18  Sergei Dyshel  <sergeid@il.ibm.com>
12963
12964         * see.c: Remove.
12965         * Makefile.in (OBJS-common): Remove see.o.
12966         (see.o): Remove.
12967         * common.opt (fsee): Mark as preserved for backward compatibility.
12968         * opts.c (common_handle_option): Add OPT_fsee to the backward
12969         compatibility section.
12970         * passes.c (init_optimization_passes, pass_see): Remove pass.
12971         * timevar.def (TV_SEE): Remove.
12972         * tree-pass.h (pass_see): Remove declaration.
12973         * doc/invoke.texi (-fsee): Remove documentation.
12974
12975 2009-06-18  Martin Jambor  <mjambor@suse.cz>
12976
12977         * tree-sra.c: Include statistics.h
12978         (sra_stats): New variable.
12979         (sra_initialize): Clear sra_stats.
12980         (create_access_replacement): Increment sra_stats.replacements.
12981         (get_access_replacement): Do not return twice.
12982         (analyze_all_variable_accesses): Increment statistics counter by the
12983         number of scalarized aggregates.
12984         (generate_subtree_copies): Increment sra_stats.subtree_copies.
12985         (sra_modify_expr): Increment sra_stats.exprs.
12986         (load_assign_lhs_subreplacements): Increment sra_stats.subreplacements.
12987         (sra_modify_assign): Increment sra_stats.exprs,
12988         sra_stats.separate_lhs_rhs_handling and sra_stats.deleted.
12989         (perform_intra_sra): Update statistics counters.
12990         * Makefile.in (tree-sra.o): Add statistics.h to dependencies.
12991
12992 2009-06-18  Sandra Loosemore  <sandra@codesourcery.com>
12993
12994         * config/arm/arm.c (TARGET_SCALAR_MODE_SUPPORTED_P): Redefine.
12995         (arm_scalar_mode_supported_p): New function.
12996
12997 2009-06-18  Paul Brook  <paul@codesourcery.com>
12998             Sandra Loosemore  <sandra@codesourcery.com>
12999
13000         * config/arm/sfp-machine.h (_FP_NANFRAC_H, _FP_NANSIGN_H): Define.
13001         (__extendhfsf2, __truncsfhf2): Define.
13002         * config/arm/fp16.c: New file.
13003         * config/arm/t-bpabi (LIB2FUNCS_STATIC_EXTRA): Add fp16.c.
13004         * config/arm/t-symbian (LIB2FUNCS_STATIC_EXTRA):  Add fp16.c.
13005
13006 2009-06-18  Sandra Loosemore  <sandra@codesourcery.com>
13007
13008         * doc/extend.texi (Half-Precision): New section.
13009         * doc/invoke.texi (Option Summary): List -mfp16-format.
13010         (ARM Options): List neon-fp16 as -mfpu value.  Document -mfp16-format.
13011         * config/arm/arm.opt (mfp16-format=): New.
13012         * config/arm/arm.c: Include intl.h.
13013         (TARGET_INVALID_PARAMETER_TYPE): Redefine.
13014         (TARGET_INVALID_RETURN_TYPE): Redefine.
13015         (TARGET_PROMOTED_TYPE): Redefine.
13016         (TARGET_CONVERT_TO_TYPE): Redefine.
13017         (arm_fp16_format): Define.
13018         (all_fpus): Add entry for neon-fp16.
13019         (fp_model_for_fpu): Likewise.
13020         (struct fp16_format): Declare.
13021         (all_fp16_formats): Define.
13022         (arm_init_libfuncs): Add entries for HFmode conversions and arithmetic
13023         functions.
13024         (arm_override_options): Set arm_fp16_format. Call sorry for fp16
13025         and no ldrh.
13026         (arm_legitimate_index_p): Treat HFmode like HImode.
13027         (thumb1_legitimate_address_p): Make it recognize HFmode constants.
13028         (coproc_secondary_reload_class): Special-case HFmode.
13029         (arm_print_operand): Add 'z' specifier for vld1.16/vst1.16.
13030         (arm_hard_regno_mode_ok): Allow HFmode values in VFP registers.
13031         (arm_init_fp16_builtins): New.
13032         (arm_init_builtins): Call it.
13033         (arm_invalid_parameter_type): New.
13034         (arm_invalid_return_type): New.
13035         (arm_promoted_type): New.
13036         (arm_convert_to_type).
13037         (arm_file_start): Deal with neon-fp16 as fpu_name.  Emit tag for fp16
13038         format.
13039         (arm_emit_fp16_const): New function.
13040         (arm_mangle_type): Mangle __fp16 as "Dh".
13041         * config/arm/arm.h (TARGET_VFPD32): Make it know about
13042         FPUTYPE_NEON_FP16.
13043         (TARGET_NEON_FP16): New.
13044         (TARGET_NEON): Make it know about FPUTYPE_NEON_FP16.
13045         (enum fputype): Add FPUTYPE_NEON_FP16.
13046         (enum arm_fp16_format_type): Declare.
13047         (arm_fp16_format): Declare.
13048         (LARGEST_EXPONENT_IS_NORMAL): Define.
13049         * config/arm/arm-protos.h (arm_emit_fp16_const): Declare.
13050         * config/arm/arm-modes.def (HFmode): Define.
13051         * config/arm/vfp.md: (*movhf_vfp): New.
13052         (extendhfsf2): New.
13053         (truncsfhf2): New.
13054         * config/arm/arm.md: (fpu): Add neon_fp16.
13055         (floatsihf2, floatdihf2): New.
13056         (fix_trunchfsi2, fix_trunchfdi2): New.
13057         (truncdfhf2): New.
13058         (extendhfdf2): New.
13059         (movhf): New.
13060         (*arm32_movhf): New.
13061         (*thumb1_movhf): New.
13062         (consttable_2): Add check for HFmode constants.
13063         (consttable_4): Handle HFmode constants.
13064
13065 2009-06-18  Uros Bizjak  <ubizjak@gmail.com>
13066
13067         * convert.c (convert_to_integer): Convert (int)logb() into ilogb().
13068
13069 2009-06-17  Olivier Hainque  <hainque@adacore.com>
13070
13071         * collect2.c (main): Use CONST_CAST2 to perform char ** to
13072         const char ** conversion in AIX specific section.
13073
13074 2009-06-17  H.J. Lu  <hongjiu.lu@intel.com>
13075
13076         * config/i386/i386.c (ix86_special_builtin_type): Remove
13077         UINT64_FTYPE_PINT.  Add UINT64_FTYPE_PUNSIGNED.
13078         (bdesc_special_args): Updated.
13079         (ix86_init_mmx_sse_builtins): Likewise.
13080         (ix86_expand_special_args_builtin): Likewise.
13081
13082 2009-06-17  Richard Henderson  <rth@redhat.com>
13083
13084         * tree-pretty-print.c (maybe_dump_asm_name): New.
13085         (dump_decl_name): Use it.
13086         (PRINT_FUNCTION_NAME): Merge into...
13087         (dump_function_name): ... here.  Use maybe_dump_asm_name.
13088
13089 2009-06-17  Cary Coutant  <ccoutant@google.com>
13090
13091         * dbxout.c (dbxout_source_line): Add is_stmt parameter.
13092         Change caller.
13093         * debug.c (struct gcc_debug_hooks): Change placeholder for
13094         source_line hook.
13095         (debug_nothing_int_charstar_int): Replaced by...
13096         (debug_nothing_int_charstar_int_bool): ...this.
13097         * debug.h (struct gcc_debug_hooks): Add is_stmt parameter to
13098         source_line prototype.
13099         (debug_nothing_int_charstar_int): Replaced by...
13100         (debug_nothing_int_charstar_int_bool): ...this.
13101         * defaults.h (SUPPORTS_DISCRIMINATOR): New constant.
13102         * dwarf2out.c (dwarf2out_source_line): Add is_stmt parameter.
13103         Output is_stmt operand when necessary.
13104         * final.c (final_scan_insn): Pass is_stmt to source_line debug hook.
13105         (notice_source_line): Add is_stmt parameter.
13106         * sdbout.c (sdbout_source_line): Add is_stmt parameter.
13107         * vmsdbgout.c (vmsdbgout_source_line): Add is_stmt parameter.
13108         Change callers.
13109         * xcoffout.c (xcoffout_source_line): Add is_stmt parameter.
13110         * xcoffout.h (xcoffout_source_line): Add is_stmt parameter.
13111
13112 2009-06-17  Ian Lance Taylor  <iant@google.com>
13113
13114         * expr.c (struct move_by_pieces_d): Rename from move_by_pieces.
13115         Change all uses.
13116         (struct store_by_pieces_d): Rename from store_by_pieces.  Change
13117         call uses.
13118
13119 2009-06-17  Adam Nemet  <anemet@caviumnetworks.com>
13120
13121         * tree.h (STRIP_NOPS, STRIP_SIGN_NOPS,
13122         STRIP_USELESS_TYPE_CONVERSION): Use tree_strip_nop_conversions,
13123         tree_strip_sign_nop_conversions and
13124         tree_ssa_strip_useless_type_conversions rather than stripping
13125         the operations here.
13126         (tree_strip_nop_conversions, tree_strip_sign_nop_conversions):
13127         Declare them.
13128         * gimple.h (tree_ssa_strip_useless_type_conversions): Declare it.
13129         * tree-ssa.c (tree_ssa_strip_useless_type_conversions): New function.
13130         * tree.c (tree_nop_conversion, tree_sign_nop_conversion,
13131         tree_strip_nop_conversions, tree_strip_sign_nop_conversions): New
13132         functions.
13133
13134 2009-06-17  Michael Eager  <eager@eagercon.com>
13135
13136         * config/rs6000/constraints.md (register_constraint "d"): New.
13137         * config/rs6000/dfp.md (movsd_store, extendsddd2, extendsdtd2,
13138         truncddsd2, *negdd2_fpr, *absdd2_fpr, *nabsdd2_fpr,
13139         *movdd_hardfloat32, *movdd_hardfloat64_mfpgpr, *movdd_hardfloat64,
13140         *negtd2_fp, *abstd2_fpr, *nabstd2_fpr, *movtd_internal, extendddtd2,
13141         trunctddd2, adddd3, addtd3, subdd3, subtd3, muldd3, multd3, divdd3,
13142         divtd3, *cmpdd_internal1, *cmptd_internal1, floatditd2, ftruncdd2,
13143         fixdddi2, ftrunctd2, fixtddi2): replace 'f' constraint with 'd'
13144         * config/rs6000/ppu_intrinsics.h (__mffs, __mtfsf, __mtfsfi, __fabs,
13145         __fnabs, __fmadd, __fmsub, __fnmadd, __fnmsub, __fsel, __frsqrte,
13146         __fsqrt, __fmul, __fmuls, __frsp, __fcfid, __fctid, __fctidz, __fctiw,
13147         __fctiwz): Same.
13148         * config/rs6000/rs6000.md (*extendsfdf2_fpr, *truncdfsf2_fpr,
13149         *fseldfsf4, *negdf2_fpr, *absdf2_fpr, *nabsdf2_fpr, *adddf3_fpr,
13150         *subdf3_fpr, *muldf3_fpr, *divdf3_fpr, recipdf3, fred, sqrtdf2,
13151         *fseldfdf4, *fselsfdf4, *floatsidf2_internal, *floatunssidf2_internal,
13152         *fix_truncdfsi2_internal, fix_truncdfsi2_internal_gfxopt,
13153         fix_truncdfsi2_mfpgpr, fctiwz, btruncdf2, ceildf2, floordf2, rounddf2,
13154         stfiwx, floatdidf2, fix_truncdfdi2, floatdisf2_internal1,
13155         *movdf_hardfloat32, *movdf_hardfloat64_mfpgpr, *movdf_hardfloat64,
13156         *movtf_internal, *extenddftf2_internal, trunctfdf2_internal1,
13157         trunctfdf2_internal2, trunctfsf2_fprs, fix_trunc_helper,
13158         *fix_trunctfsi2_internal, negtf2_internal, *movdi_internal32,
13159         *movdi_mfpgpr, *movdi_internal64, *movdf_update1, *movdf_update2,
13160         *cmpdf_internal1, *cmptf_internal1, *cmptf_internal2): Same.
13161         * doc/md.texi: Describe PowerPC 'd' constraint, update 'f' constraint.
13162
13163 2009-06-16  Ian Lance Taylor  <iant@google.com>
13164
13165         * profile.c (total_num_never_executed): Don't define.
13166         (compute_branch_probabilities): Don't count or print
13167         num_never_executed.
13168         (init_branch_prob): Don't set total_num_never_executed.
13169         (end_branch_prob): Don't print total_num_never_executed.
13170
13171 2009-06-17  David Daney  <ddaney@caviumnetworks.com>
13172
13173         * jump.c (cleanup_barriers): Handle case of no insns before a barrier.
13174
13175 2009-06-17  David Edelsohn  <edelsohn@gnu.org>
13176
13177         * config/rs6000/dfp.md (nabsdd2_fpr): Correct mode.
13178         (nabstd2_fpr): Same.
13179
13180 2009-06-17  Steve Ellcey  <sje@cup.hp.com>
13181
13182         * expr.c (expand_assignment): Change complex type check.
13183
13184 2009-06-17  Basile Starynkevitch  <basile@starynkevitch.net>
13185
13186         * doc/plugins.texi (Building GCC plugins): Added new section.
13187
13188 2009-06-17  Ian Lance Taylor  <iant@google.com>
13189
13190         * c-pch.c (get_ident): Don't set size of templ array.
13191         (pch_init): Don't set size of partial_pch array.
13192
13193         * c-typeck.c (digest_init): If -Wc++-compat, warn about using a
13194         string constant to intialize an array whose size is the length of
13195         the string.
13196
13197 2009-06-17  Richard Guenther  <rguenther@suse.de>
13198
13199         PR tree-optimization/40389
13200         * tree-ssa-structalias.c (handle_rhs_call): Restrict NRV case
13201         to addressable types.
13202         * gimple.c (walk_stmt_load_store_addr_ops): Likewise.
13203
13204 2009-06-17  Richard Guenther  <rguenther@suse.de>
13205
13206         PR middle-end/40460
13207         * tree-chrec.h (build_polynomial_chrec): If we cannot determine
13208         if there is no evolution of left in the loop bail out.
13209         * tree-chrec.c (chrec_fold_multiply_poly_poly): CSE one
13210         chrec_fold_multiply.
13211
13212 2009-06-16  J"orn Rennecke  <joern.rennecke@arc.com>
13213             Janis Johnson  <janis187@us.ibm.com>
13214
13215         PR target/39254
13216         * config/rs6000/rs6000.c (rs6000_emit_move): Don't emit a USE
13217         for the symbol ref of a constant that is the source of a move
13218         - nor for any other not-obvious-label-ref constants.
13219
13220 2009-06-16  Olatunji Ruwase  <tjruwase@google.com>
13221
13222         * plugin.c (position_pass): Skip newly inserted pass during list
13223         traversal to avoid repeated insertion.
13224
13225 2009-06-16  Ian Lance Taylor  <iant@google.com>
13226
13227         * vec.h (VEC_stack_alloc): Define different version if
13228         GATHER_STATISTICS is defined, to accept and ignore MEM_STAT.
13229         (DEF_VEC_ALLOC_FUNC_P_STACK): Remove MEM_STAT_DECL.
13230         (DEF_VEC_ALLOC_FUNC_O_STACK): Likewise.
13231         (DEF_VEC_ALLOC_FUNC_I_STACK): Likewise.
13232
13233 2009-06-16  H.J. Lu  <hongjiu.lu@intel.com>
13234
13235         * config.gcc (extra_headers): Add ia32intrin.h for x86.
13236
13237         * config/i386/i386.c (ix86_builtins): Add IX86_BUILTIN_BSRSI,
13238         IX86_BUILTIN_BSRDI.  IX86_BUILTIN_RDPMC, IX86_BUILTIN_RDTSC.
13239         IX86_BUILTIN_RDTSCP.  IX86_BUILTIN_ROLQI, IX86_BUILTIN_ROLHI,
13240         IX86_BUILTIN_RORQI and IX86_BUILTIN_RORHI.
13241         (ix86_special_builtin_type): Add UINT64_FTYPE_VOID,
13242         UINT64_FTYPE_PINT, INT_FTYPE_INT, UINT64_FTYPE_INT,
13243         INT64_FTYPE_INT64, UINT16_FTYPE_UINT16_INT and UINT8_FTYPE_UINT8_INT.
13244         (bdesc_special_args): Add __builtin_ia32_rdtsc and
13245         __builtin_ia32_rdtscp.
13246         (bdesc_args): Add __builtin_ia32_bsrsi, __builtin_ia32_bsrdi,
13247         __builtin_ia32_rolqi, __builtin_ia32_rolhi, __builtin_ia32_rorqi
13248         and __builtin_ia32_rorhi.
13249         (ix86_init_mmx_sse_builtins): Handle UINT64_FTYPE_VOID,
13250         UINT64_FTYPE_PINT, INT_FTYPE_INT, UINT64_FTYPE_INT,
13251         INT64_FTYPE_INT64, UINT16_FTYPE_UINT16_INT and UINT8_FTYPE_UINT8_INT.
13252         (ix86_expand_args_builtin): Likewise.
13253         (ix86_expand_special_args_builtin): Likewise.
13254
13255         * config/i386/i386.md (UNSPECV_RDTSCP): New.
13256         (UNSPECV_RDTSC): Likewise.
13257         (UNSPECV_RDPMC): Likewise.
13258         (*bsr): Renamed to ...
13259         (bsr): This
13260         (*bsr_rex64): Renamed to ...
13261         (bsr_rex64): This.
13262         (rdpmc): New.
13263         (*rdpmc): Likewise.
13264         (*rdpmc_rex64): Likewise.
13265         (rdtsc): Likewise.
13266         (*rdtsc): Likewise.
13267         (*rdtsc_rex64): Likewise.
13268         (rdtscp): Likewise.
13269         (*rdtscp): Likewise.
13270         (*rdtscp_rex64): Likewise.
13271
13272         * config/i386/ia32intrin.h: New.
13273
13274         * config/i386/x86intrin.h: Include <ia32intrin.h>.
13275
13276 2009-06-16  Ian Lance Taylor  <iant@google.com>
13277
13278         * ira-build.c (copy_info_to_removed_store_destinations):
13279         Initialize parent_a.
13280
13281 2009-06-16  Ian Lance Taylor  <iant@google.com>
13282
13283         * c-decl.c (grokdeclarator): Change size_varies to bool.
13284
13285 2009-06-16  Ian Lance Taylor  <iant@google.com>
13286
13287         * sel-sched.c: Make forward declarations of move_op_hooks and
13288         fur_hooks explicitly extern.
13289
13290 2009-06-16  Ian Lance Taylor  <iant@google.com>
13291
13292         * df-problems.c (df_byte_lr_alloc): Don't set problem_data to itself.
13293         * vec.c (vec_gc_o_reserve_1): Don't set alloc to itself.
13294
13295 2009-06-16  Ian Lance Taylor  <iant@google.com>
13296
13297         * resource.c (mark_referenced_resources): Change
13298         include_delayed_effects parameter to bool.  Change all callers.
13299         (mark_end_of_function_resources): Likewise.
13300         * reorg.c (insn_references_resource_p): Likewise.
13301         (insn_sets_resource_p): Likewise.
13302         * resource.h (mark_referenced_resources): Update declaration.
13303         (mark_end_of_function_resources): Update declaration.
13304
13305 2009-06-16  David Edelsohn  <edelsohn@gnu.org>
13306
13307         * config/rs6000/aix.h (LIBSTDCXX_STATIC): Remove -lstdc++.
13308
13309 2009-06-16  David Edelsohn  <edelsohn@gnu.org>
13310
13311         * doc/install.texi (*-*-aix): Update explanation of XLC bootstrap.
13312         GCC can bootstrap on AIX with GNU Binutils 2.20.
13313
13314 2009-06-16  Ian Lance Taylor  <iant@google.com>
13315
13316         * Makefile.in (tree-vect-stmts.o): Depend upon $(TOPLEV_H).
13317
13318 2009-06-16  Ian Lance Taylor  <iant@google.com>
13319
13320         * toplev.h (floor_log2): If GCC_VERSION >= 3004, declare as static
13321         inline, not extern inline.
13322         (exact_log2): Likewise.
13323         * toplev.c (floor_log2): Only define if GCC_VERSION < 3004. Don't
13324         test CLZ_HWI.
13325         (exact_log2): Likewise, but don't test CTZ_HWI.
13326
13327 2009-06-16  Ian Lance Taylor  <iant@google.com>
13328
13329         * bitmap.c (bitmap_clear): Don't declare as inline.
13330         * gimple.c (gimplify_assign): Likewise.
13331         * tree-ssa-sccvn.c (vn_nary_op_compute_hash): Likewise.
13332         * haifa-sched.c (insn_cost): Don't declare with HAIFA_INLINE.
13333         (sched_scan_info): Remove duplicate definition.
13334
13335 2009-06-16  Ian Lance Taylor  <iant@google.com>
13336
13337         * c-common.c (skip_evaluation): Don't define.
13338         (c_inhibit_evaluation_warnings): Define global variable.
13339         (overflow_warning): Check c_inhibit_evaluation_warnings rather
13340         than skip_evaluation.
13341         (convert_and_check, warn_for_div_by_zero): Likewise.
13342         * c-common.h (skip_evaluation): Don't declare.
13343         (c_inhibit_evaluation_warnings): Declare.
13344         * c-parser.c (c_parser_typeof_specifier): Set
13345         c_inhibit_evaluation_warnings rather than skip_evaluation.
13346         (c_parser_conditional_expression): Likewise.
13347         (c_parser_binary_expression): Likewise.
13348         (c_parser_sizeof_expression): Likewise.
13349         (c_parser_alignof_expression): Likewise.
13350         * c-typeck.c (build_indirect_ref): Check
13351         c_inhibit_evaluation_warnings rather than skip_evaluation.
13352         (build_conditional_expr, build_binary_op): Likewise.
13353
13354 2009-06-16  Richard Guenther  <rguenther@suse.de>
13355
13356         * tree-ssa-alias.c (is_escape_site): Remove.
13357         * tree-ssa-alias.h (enum escape_type): Remove.
13358         (is_escape_site): Likewise.
13359         * tree-ssa-structalias.c (find_func_aliases): Handle escapes
13360         via casts and asms without deferring to is_escape_site.
13361
13362 2009-06-16  Jakub Jelinek  <jakub@redhat.com>
13363
13364         PR middle-end/40446
13365         * expr.c (expand_expr_real_1) <case VIEW_CONVERT_EXPR>: Don't
13366         use gen_lowpart if op0 has complex mode.
13367
13368 2009-06-16  Richard Guenther  <rguenther@suse.de>
13369
13370         * tree-ssa-structalias.c (do_ds_constraint): Stores in global
13371         variables add them to ESCAPED.
13372         (find_func_aliases): Do not make all indirectly stored values escaped.
13373
13374 2009-06-16  Rafael Avila de Espindola  <espindola@google.com>
13375
13376         * config/i386/winnt.c (i386_pe_encode_section_info): Update call to
13377         make_decl_one_only.
13378
13379 2009-06-16  Martin Jambor  <mjambor@suse.cz>
13380
13381         PR tree-optimization/40432
13382         * tree-sra.c (sra_modify_assign): When creating VIEW_CONVERT_EXPR,
13383         check whether we need to force gimple register operand.
13384
13385 2009-06-16  Martin Jambor  <mjambor@suse.cz>
13386
13387         PR tree-optimization/40413
13388         * tree-sra.c (load_assign_lhs_subreplacements): Pass offset to
13389         build_ref_for_offset.
13390         (propagate_subacesses_accross_link): Fix a typo in a comment.
13391
13392 2009-06-16  Ira Rosen  <irar@il.ibm.com>
13393
13394         * tree-parloops.c (loop_parallel_p): Call vect_is_simple_reduction
13395         with additional parameter.
13396         * tree-vectorizer.h (enum vect_def_type): Add new value
13397         vect_nested_cycle.
13398         (enum vect_relevant): Add comments.
13399         (vect_is_simple_reduction): Add new argument.
13400         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Add comments.
13401         Detect nested cycles.
13402         (vect_is_simple_reduction): Update documentation, add an argument to
13403         distinguish inner-loop reduction from nested cycle, detect nested
13404         cycles, fix printings and indentation, don't swap operands in case
13405         of nested cycle.
13406         (get_initial_def_for_reduction): Handle subtraction.
13407         (vect_create_epilog_for_reduction): Add new argument to specify
13408         reduction variable.
13409         (vect_finalize_reduction): Handle subtraction, fix comments.
13410         (vectorizable_reduction): Handle nested cycles. In case of nested
13411         cycle keep track of the reduction variable position. Call
13412         vect_is_simple_reduction with additional parameter. Use original
13413         statement code in reduction epilogue for nested cycle. Call
13414         vect_create_epilog_for_reduction with additional parameter.
13415         * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Assert
13416         inner-loop vectorization.
13417         (vect_recog_widen_sum_pattern): Likewise.
13418         * tree-vect-stmts.c (process_use): Distinguish between nested cycles
13419         and reductions.
13420         (vect_mark_stmts_to_be_vectorized): Likewise.
13421         (vect_get_vec_def_for_operand): Handle nested cycles.
13422
13423 2009-06-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13424
13425         * doc/invoke.texi (Debugging Options): Fix option index entries
13426         for -fdump-statistics, -frandom-seed add entries for
13427         -fdump-tree-original, -fdump-tree-optimized, -frandom-seed.
13428         (FRV Options): Fix entries for -mTLS, -mtls.
13429         (HPPA Options): Fix entries for -mgnu-ld, -mhp-ld.
13430         (i386 and x86-64 Options): Fix entry for -mno-red-zone.
13431         (M68hc1x Options): Fix @itemx for -mnominmax.
13432         (MCore Options): Fix entry for -mno-lsim.
13433         (MMIX Options): Fix entry for -mabi=mmixware.
13434         (PDP-11 Options): Fix entry for -mbcopy-builtin.
13435
13436 2009-06-16  Basile Starynkevitch  <basile@starynkevitch.net>
13437
13438         * doc/plugins.texi (Interacting with the GCC Garbage Collector):
13439         Mention the plugin mode of gengtype.
13440         * doc/gty.texi (Source Files Containing Type Information): Likewise.
13441         * gengtype.c: Updated copyright.
13442         (plugin_files, nb_plugin_files) Added new static variables.
13443         (measure_input_list) Care about plugin_files.
13444         (write_rtx_next): Added early return in plugin mode.
13445         (create_file): Updated copyright year in generated file. Added
13446         asserts.
13447         (oprintf): Added early return if NULL outf.
13448         (get_output_file_with_visibility): Care of plugin_files.
13449         (get_output_file_name): May return null.
13450         (write_local): Added early return.
13451         (put_mangled_filename): Ditto.
13452         (finish_root_table): Added check for base_files.
13453         (write_roots): Care about null when plugins.
13454         (main): Added plugin mode.
13455
13456 2009-06-15  Ian Lance Taylor  <iant@google.com>
13457
13458         * df-problems.c (df_simulate_one_insn_forwards): Fix braces in switch.
13459         * gcov.c (read_count_file): Add braces around variables declared
13460         before label.
13461
13462         * c.opt (Wjump-misses-init): New warning.
13463         * c-opts.c (c_common_handle_option): Set warn_jump_misses_init for
13464         -Wall and -Wc++-compat if not already set.
13465         (c_common_post_options): Clear warn_jump_misses_init if it was not
13466         set.
13467         * c-decl.c (struct c_binding): Change type field to a union with
13468         new label field.  Make it the first field in the struct.  Update
13469         references to type to use u.type instead.
13470         (struct c_spot_bindings): Define.
13471         (struct c_goto_bindings): Define.
13472         (c_goto_bindings_p): Define, along with VECs.
13473         (struct c_label_vars): Define.
13474         (struct c_scope): Add has_label_bindings field.
13475         (bind_label, set_spot_bindings): New static functions.
13476         (decl_jump_unsafe, update_spot_bindings): New static functions.
13477         (update_label_decls): New static function.
13478         (pop_scope): Call update_label_decls.  Don't call c_end_vm_scope.
13479         Update binding u.label field to shadowed field.
13480         (c_binding_start_stmt_expr): New function.
13481         (c_binding_end_stmt_expr): New function.
13482         (pushdecl): Don't call c_begin_vm_scope.
13483         (make_label): Add defining and p_label_vars parameters.  Change
13484         all callers.
13485         (lookup_label): Correct test for whether a label has not yet been
13486         defined.  Call bind_label rather than bind.
13487         (warn_about_goto): New static function.
13488         (lookup_label_for_goto): New function.
13489         (declare_label): Call bind_label rather than bind.
13490         (check_earlier_gotos): New static function.
13491         (define_label): Don't give errors about jumping into statement
13492         expressions or scopes of variably modified types.  Call
13493         set_spot_bindings and check_earlier_gotos.  Call bind_label
13494         instead of bind.  Don't set label_context_stack_se or
13495         label_context_stack_vm.
13496         (c_get_switch_bindings): New function.
13497         (c_release_switch_bindings): New function.
13498         (c_check_switch_jump_warnings): New function.
13499         (start_function): Don't set label_context_stack_se or
13500         label_context_stack_vm.
13501         (finish_function): Likewise.
13502         * c-typeck.c (label_context_stack_se): Don't define.
13503         (label_context_stack_vm): Don't define.
13504         (c_finish_goto_label): Call lookup_label_for_goto rather than
13505         lookup_label.  Don't give errors about jumping into a statement
13506         expression or the scope of a variably modified type.  Don't set
13507         label_context_stack_se or label_context_stack_vm.
13508         (struct c_switch): Remove blocked_stmt_expr and blocked_vm
13509         fields.  Add bindings field.
13510         (c_start_case): Don't set deleted fields.  Set bindings field.
13511         (do_case): Rework order of tests.  Don't check blocked_stmt_expr
13512         or blocked_vm.  Call c_check_switch_jump_warnings.
13513         (c_finish_case): Don't test blocked_stmt_expr field.  Call
13514         c_release_switch_bindings.
13515         (c_begin_stmt_expr): Don't increment blocked_stmt_expr in
13516         c_switch_stack.  Don't walk label_context_stack_se labels.  Don't
13517         set label_context_stack_se.  Call c_bindings_start_stmt_expr.
13518         (c_finish_stmt_expr): Don't decrement blocked_stmt_expr in
13519         c_switch_stack.  Don't walk label_context_stack_se labels.  Don't
13520         set label_context_stack_se.  Call c_bindings_end_stmt_expr.
13521         (c_begin_vm_scope, c_end_vm_scope): Don't define.
13522         * c-tree.h (C_DECL_UNJUMPABLE_STMT_EXPR): Don't define.
13523         (C_DECL_UNDEFINABLE_STMT_EXPR): Don't define.
13524         (C_DECL_UNJUMPABLE_VM): Don't define.
13525         (C_DECL_UNDEFINABLE_VM): Don't define.
13526         (struct c_label_list): Don't define.
13527         (struct c_label_context_se): Don't define.
13528         (struct c_label_context_vm): Don't define.
13529         (struct c_spot_bindings): Declare.
13530         (c_bindings_start_stmt_expr): Declare.
13531         (c_bindings_end_stmt_expr): Declare.
13532         (lookup_label_for_goto): Declare.
13533         (c_get_switch_bindings, c_release_switch_bindings): Declare.
13534         (c_check_switch_jump_warnings): Declare.
13535         (label_context_stack_se, label_context_stack_vm): Don't declare.
13536         (c_finish_goto_label): Update declaration.
13537         (c_begin_vm_scope, c_end_vm_scope): Don't declare.
13538         * doc/invoke.texi (Option Summary): Mention -Wjump-misses-init.
13539         (Warning Options): Document -Wjump-misses-init.
13540
13541 2009-06-15  Jakub Jelinek  <jakub@redhat.com>
13542
13543         * tree-object-size.c (addr_object_size): Fix a pasto in the last
13544         change.
13545
13546 2009-06-15  Rafael Avila de Espindola  <espindola@google.com>
13547
13548         * cgraph.c (cgraph_make_node_local): Use DECL_COMDAT_GROUP.
13549
13550 2009-06-15  Aldy Hernandez  <aldyh@redhat.com>
13551
13552         * except.c (init_eh): Use BUILTINS_LOCATION when calling build_decl.
13553
13554 2009-06-15  Aldy Hernandez  <aldyh@redhat.com>
13555
13556         * tree-eh.c (lower_try_finally_switch): Initialize tf_loc.
13557
13558 2009-06-15  Rafael Avila de Espindola  <espindola@google.com>
13559
13560         * cgraphunit.c (cgraph_function_versioning,save_inline_function_body):
13561         Use DECL_COMDAT_GROUP instead of DECL_ONE_ONLY.
13562         * cgraph.c (cgraph_create_virtual_clone): Use DECL_COMDAT_GROUP.
13563         * config/i386/i386.c (ix86_file_end): Compute DECL_COMDAT_GROUP.
13564         * dwarf2asm.c (dw2_force_const_mem): Update call to
13565         make_decl_one_only.
13566         * langhooks-def.h (lhd_comdat_group, LANG_HOOKS_COMDAT_GROUP): Remove.
13567         (LANG_HOOKS_DECLS): Remove LANG_HOOKS_COMDAT_GROUP.
13568         * langhooks.c (lhd_comdat_group): Remove.
13569         * langhooks.h (lang_hooks_for_decls): Remove comdat_group.
13570         * tree.h (DECL_COMDAT_GROUP): New.
13571         (DECL_ONE_ONLY): Use DECL_COMDAT_GROUP.
13572         (tree_decl_with_vis): Add comdat_group. Remove one_only.
13573         (make_decl_one_only): Change signature.
13574         * varasm.c (get_emutls_init_templ_addr, emutls_decl): Update call to
13575         make_decl_one_only.
13576         (make_decl_one_only): Change signature.
13577         (default_elf_asm_named_section): Use DECL_COMDAT_GROUP.
13578
13579 2009-06-15  Richard Guenther  <rguenther@suse.de>
13580
13581         PR middle-end/40439
13582         * tree.c (widest_int_cst_value): Fix bootstrap on 32bit HWI hosts.
13583
13584 2009-06-14  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
13585
13586         * tree-ssa-math-opts.c: Remove extra divide.
13587
13588 2009-06-14  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
13589
13590         * config/s390/s390.md ("bswap<mode>2"): Only available on z900.
13591
13592 2009-06-14  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
13593
13594         * passes.c: Add bswap pass.
13595         * tree-pass.h: Add pass_optimize_bswap declaration.
13596         * tree-ssa-math-opts.c: Include diagnostics.h for print_gimple_stmt.
13597         Include rtl.h, expr.h and optabs.h for optab_handler check.
13598         (struct symbolic_number, pass_optimize_bswap): New definition.
13599         (do_shift_rotate, verify_symbolic_number_p): New functions.
13600         (find_bswap_1, find_bswap, execute_optimize_bswap): New functions.
13601         (gate_optimize_bswap): New function.
13602         * tree.c (widest_int_cst_value): New function.
13603         * tree.h (widest_int_cst_value): Prototype added.
13604
13605 2009-06-14  Steven Bosscher  <steven@gcc.gnu.org>
13606
13607         * cfgcleanup.c (old_insns_match_p): Remove code to substitute
13608         REG_EQUAL/REG_EQUIV notes.
13609
13610 2009-06-14  Richard Guenther  <rguenther@suse.de>
13611
13612         PR middle-end/40389
13613         * gimple.c (walk_stmt_load_store_addr_ops): The LHS of a call
13614         has its address taken if NRV was applied and it is addressable.
13615         * tree-ssa-structalias.c (get_constraint_for_address_of): New
13616         function split out from ...
13617         (get_constraint_for_1): ... here.
13618         (handle_rhs_call): Use it to mark the return slot escaped if
13619         it is addressable and NRV was applied.
13620
13621 2009-06-13  Aldy Hernandez  <aldyh@redhat.com>
13622
13623         * config/rs6000/rs6000-protos.h (altivec_resolve_overloaded_builtin):
13624         Change first argument type to location_t.
13625         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Same.
13626         Do not set input_location.
13627         Use loc instead of input_location throughout.
13628
13629 2009-06-13  Richard Guenther  <rguenther@suse.de>
13630
13631         PR tree-optimization/40421
13632         * tree-predcom.c (should_unroll_loop_p): Remove.
13633         (tree_predictive_commoning_loop): Use can_unroll_loop_p.
13634
13635 2009-06-13  Michael Meissner  <meissner@linux.vnet.ibm.com>
13636
13637         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
13638         Add location argument.
13639
13640 2009-06-13  Aldy Hernandez  <aldyh@redhat.com>
13641
13642         * config/alpha/alpha.c (alpha_build_builtin_va_list): Pass location to
13643         build_decl.
13644         * config/s390/s390.c (s390_build_builtin_va_list): Same.
13645         (s390_gimplify_va_arg): Pass location to create_artificial_label.
13646         * config/spu/spu-protos.h: Add location to
13647         spu_resolve_overloaded_builtin.
13648         * config/spu/spu.c (spu_build_builtin_va_list): Pass location to
13649         spu_build_builtin_va_list.
13650         * config/spu/spu-c.c (spu_resolve_overloaded_builtin): Add location
13651         argument.  Pass location to build_function_call_vec.
13652         * config/sh/sh.c (sh_build_builtin_va_list): Pass location to
13653         build_decl.
13654         (emit_fpu_switch): Same.
13655         (sh_gimplify_va_arg_expr): Pass location to create_artificial_label.
13656         * config/xtensa/xtensa.c (xtensa_build_builtin_va_list): Pass location
13657         to build_decl and create_artificial_label.
13658         (xtensa_gimplify_va_arg_expr): Same.
13659         * config/stormy16/stormy16.c (xstormy16_build_builtin_va_list): Same.
13660         (xstormy16_gimplify_va_arg_expr): Same.
13661         * config/iq2000/iq2000.c (iq2000_expand_prologue): Same.
13662         * config/arm/arm.c (arm_build_builtin_va_list): Same.
13663         * config/mips/mips.c (mips_build_builtin_va_list): Same.
13664         (mips16_build_function_stub): Same.
13665         (mips16_build_call_stub): Same.
13666
13667 2009-06-13  Richard Earnshaw  <rearnsha@arm.com>
13668
13669         PR target/40327
13670         * arm/constraints.md (Pa, Pb): New constraints.
13671         * arm/arm.md (thumb1_addsi3): Support more complex additions.  Add a
13672         split pattern to deal with them.
13673
13674 2009-06-13  Joerg Sonnenberger  <joerg@britannica.bec.de>
13675
13676         * doc/invoke.texi: Add missing option -Wp,OPTION in list,
13677         fix index entry for -Xpreprocessor.
13678
13679 2009-06-12  Aldy Hernandez  <aldyh@redhat.com>
13680
13681         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
13682         Add location argument to build_decl call.
13683         * config/rs6000/rs6000.c (rs6000_build_builtin_va_list): Same.
13684         (rs6000_init_builtins): Same.
13685         (spe_init_builtins): Same.
13686         (rs6000_gimplify_va_arg): Add location argument to
13687         create_artificial_label call.
13688
13689 2009-06-12  Steven Bosscher  <steven@gcc.gnu.org>
13690
13691         * timevar.def (TV_COMBINE_STACK_ADJUST): New timevar.
13692         * combine-stack-adj.c (pass_stack_adjustments): Use it.
13693         * Makefile.in: Fix GGC dependency for gcse.o.
13694
13695 2009-06-12  Aldy Hernandez  <aldyh@redhat.com>
13696
13697         * tree-pretty-print.c (dump_generic_node): Dump column numbers.
13698         * gimple-pretty-print.c (dump_gimple_stmt): Same.
13699         * gimplify.c (gimplify_modify_expr): Set location for GIMPLE_ASSIGNs
13700         created.
13701         * c-parser.c (c_parser_binary_expression): Use current column while
13702         building binary operations.
13703         * common.opt (fshow-column): Enable by default.
13704         * tree-vrp.c (check_array_ref): Use warning_at.
13705         (check_array_bounds): Use location from call back if expr has no
13706         location.
13707         * tree.h: Add location argument to maybe_fold_*.
13708         * tree-ssa-ccp.c (ccp_fold): Pass location to maybe_fold_*.
13709         (maybe_fold_offset_to_array_ref): Add location argument and use it.
13710         (maybe_fold_offset_to_component_ref): Same.
13711         (maybe_fold_offset_to_reference): Same.
13712         (maybe_fold_offset_to_address): Same.
13713         (maybe_fold_stmt_indirect): Same.
13714         (maybe_fold_stmt_addition): Same.
13715         (fold_stmt_r): Pass location to maybe_fold_*.
13716         (fold_gimple_assign): Same.
13717         * c-tree.h: Add location argument to finish_decl,
13718         default_function_array_conversion, store_init_value.
13719         * c-decl.c (define_label): Use error_at.
13720         (c_make_fname_decl): Pass location to finish_decl.
13721         (finish_decl): New location argument.
13722         (build_compound_literal): Pass location to store_init_value.
13723         (grokdeclarator): Pass location to finish_decl.
13724         (grokfield): Same.
13725         * c-typeck.c (array_to_pointer_conversion): New location argument.
13726         (function_to_pointer_conversion): Same.
13727         (default_function_array_conversion): Same.
13728         (parser_build_unary_op): Pass location to overflow_warning.
13729         (parser_build_binary_op): Same.  Use warning_at.
13730         (build_unary_op): Pass location to array_to_pointer_conversion.
13731         (build_c_cast): Pass location to digest_init.
13732         (build_modify_expr): New location argument.
13733         (convert_for_assignment): Same.
13734         (store_init_value): Same.
13735         (digest_init): Same.
13736         (output_init_element): Pass location to digest_init and
13737         array_to_pointer_conversion.
13738         (c_finish_return): Pass location to convert_for_assignment.
13739         * gimplify.c (gimplify_conversion): Pass location to
13740         maybe_fold_offset_to_address.
13741         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Pass location
13742         to maybe_fold_stmt_addition.
13743         * c-omp.c (c_finish_omp_atomic): Pass new location to
13744         build_modify_expr.
13745         (c_finish_omp_for): Same.
13746         * c-common.c (overflow_warning): New argument.
13747         * c-common.h: New argument to build_modify_expr, overflow_warning.
13748         * c-parser.c (c_parser_declaration_or_fndef): Pass location to
13749         finish_decl.
13750         (c_parser_initializer): Pass location to
13751         default_function_array_conversion.
13752         (c_parser_initelt): Same.
13753         (c_parser_initval): Same.
13754         (c_parser_asm_operands): Same.
13755         (c_parser_expr_no_commas): Same.  Pass location to build_modify_expr.
13756         (c_parser_conditional_expression): Same.
13757         (c_parser_binary_expression): Add location info to stack.  Use it.
13758         (c_parser_unary_expression): Pass location to
13759         default_function_array_conversion, parser_build_unary_op,
13760         build_indirect_ref, c_parser_postfix_expression_after_primary.
13761         (c_parser_postfix_expression_after_primary): New location argument.
13762         Use it.
13763         (c_parser_expression_conv): Pass location to
13764         default_function_array_conversion.
13765         (c_parser_expr_list): Same.
13766         (c_parser_omp_atomic): Same.
13767         (c_parser_omp_for_loop): Same.
13768         * c-tree.h: (struct c_declarator): Add comment to id_loc.
13769         (build_array_declarator): New argument.
13770         * c-decl.c (build_array_declarator): Add location argument.
13771         (grokdeclarator): Set id_loc for cdk_array.
13772         * c-parser.c (c_parser_direct_declarator_inner): Pass location to
13773         build_array_declarator.
13774         * tree.c (build_omp_clause): Add location argument.
13775         * tree.h (OMP_CLAUSE_HAS_LOCATION): New macro.
13776         (OMP_CLAUSE_LOCATION): New macro.
13777         (struct tree_omp_clause): Add location field.
13778         (build_omp_clause): Add argument.
13779         * testsuite/gcc.dg/gomp/for-1.c: Fix column.
13780         * cp/pt.c (tsubst_omp_for_iterator): Pass location to
13781         build_omp_clause.
13782         * cp/parser.c (cp_parser_omp_var_list_no_open): Same.
13783         (cp_parser_omp_clause_collapse): Same.
13784         (cp_parser_omp_clause_default): Same.
13785         (cp_parser_omp_clause_if): Same.
13786         (cp_parser_omp_clause_nowait): Same.
13787         (cp_parser_omp_clause_num_threads): Same.
13788         (cp_parser_omp_clause_ordered): Same.
13789         (cp_parser_omp_clause_schedule): Same.
13790         (cp_parser_omp_clause_untied): Same.
13791         (cp_parser_omp_for_loop): Same.
13792         (cp_parser_omp_parallel): Pass location to c_split_parallel_clauses.
13793         * c-tree.h (c_start_case): Add location argument.
13794         (c_process_expr_stmt): Same.
13795         (c_finish_goto_*): Same.
13796         * tree-parloops.c (initialize_reductions): Pass location to
13797         build_omp_clause.
13798         (create_parallel_loop): Same.
13799         * fortran/trans-openmp.c (gfc_trans_omp_variable_list): Same.
13800         (gfc_trans_omp_reduction_list): Same.
13801         (gfc_trans_omp_clauses): Same.
13802         (gfc_trans_omp_do): Same.
13803         * c-typeck.c (c_finish_goto_label): Same.
13804         (c_finish_goto_ptr): New location argument.
13805         (c_start_case): Same.
13806         (emit_side_effect_warnings): Same.
13807         (c_process_expr_stmt): Same.
13808         (c_finish_stmt_expr): Same.
13809         (c_finish_omp_clauses): Use error_at instead of error.
13810         * gimplify.c (gimplify_adjust_omp_clauses_1): Pass location to
13811         build_omp_clause.
13812         * c-omp.c (c_split_parallel_clauses): New location argument.
13813         * tree-nested.c (convert_nonlocal_reference_stmt): Pass location
13814         to build_omp_clause.
13815         (convert_local_reference_stmt): Same.
13816         (convert_gimple_call): Same.
13817         * c-common.h (c_split_parallel_clauses): New argument.
13818         * c-parser.c (c_parser_statement_after_labels): Pass location to
13819         c_finish_goto_label.
13820         (c_parser_switch_statement): Pass location to c_start_case.
13821         (c_parser_for_statement): Pass location to c_finish_expr_stmt,
13822         and c_process_expr_stmt.
13823         (c_parser_omp_variable_list): Add location argument.
13824         (c_parser_omp_clause_collapse): Pass location to build_omp_clause.
13825         (c_parser_omp_clause_default): Same.
13826         (c_parser_omp_clause_if): Same.
13827         (c_parser_omp_clause_num_threads): Same.
13828         (-c_parser_omp_clause_ordered): Same.
13829         (c_parser_omp_clause_reduction): Pass location to
13830         c_parser_omp_variable_list.
13831         (c_parser_omp_clause_schedule): Pass location to build_omp_clause.
13832         (c_parser_omp_clause_untied): Same.
13833         (c_parser_omp_for_loop): Pass location to c_process_expr_stmt.
13834         (c_parser_omp_parallel): Pass location to c_split_parallel_clauses.
13835
13836         * c-tree.h (check_for_loop_decls, undeclared_variable,
13837         build_component_ref, build_array_ref, build_external_ref,
13838         c_expr_sizeof_expr, c_expr_sizeof_type, parser_build_unary_op,
13839         build_conditional_expr, build_compound_expr, c_cast_expr,
13840         build_c_cast, build_asm_expr, c_end_compound_stmt, c_finish_stmt_expr,
13841         c_finish_return, c_finish_omp_parallel, c_finish_omp_task): New
13842         argument.
13843         * c-semantics.c (build_stmt): Same.
13844         (build_case_label): Same.
13845         * c-decl.c (c_finish_incomplete_decl): Pass location on down.
13846         (undeclared_variable): New argument.
13847         (make_label): Same.
13848         (lookup_label): Pass location on down.
13849         (define_label): Same.
13850         (finish_decl): Same.
13851         (build_compound_literal): Same.
13852         (finish_struct): Same.
13853         (finish_function): Do not set location here.
13854         (check_for_loop_decls): New argument.
13855         * tree.c (save_expr): Set location.
13856         (build_empty_stmt): New argument.
13857         * tree.h (build_empty_stmt): New argument to build_empty_stmt.
13858         (CAN_HAVE_LOCATION_P): Make sure we have a non empty node.
13859         * builtins.c (gimplify_va_arg_expr): Use locations.
13860         (expand_builtin_sync_operation): Same.
13861         * c-typeck.c (build_component_ref): New argument.
13862         (build_array_ref): Same.
13863         (build_external_ref): Same.
13864         (c_expr_sizeof_expr): Same.
13865         (c_expr_sizeof_type): Same.
13866         (parser_build_unary_op): Same.
13867         (build_conditional_expr): Same.
13868         (build_compound_expr): Pass location on down.
13869         (build_compound_expr): New argument.
13870         (build_c_cast): Same.
13871         (c_cast_expr): Same.
13872         (build_asm_expr): Same.
13873         (c_finish_return): Same.
13874         (c_process_expr_stmt): Pass location on down.
13875         (c_finish_stmt_expr): New argument.
13876         (push_clenaup): Same.
13877         (c_finish_omp_parallel): Same.
13878         (c_finish_omp_task): Same.
13879         * gimplify.c (gimplify_call_expr): Pass location on down.
13880         * c-omp.c (c_finish_omp_master): New argument.
13881         (c_finish_omp_critical): Same.
13882         (c_finish_omp_ordered): Same.
13883         (c_finish_omp_barrier): Same.
13884         (-c_finish_omp_taskwait): Same.
13885         (c_finish_omp_atomic): Same.
13886         (c_finish_omp_flush): Same.
13887         * tree-inline.c (copy_tree_body_r): Pass location on down.
13888         (inline_forbidden_p): Remove use of input_location.
13889         * c-gimplify.c (c_build_bind_expr): New argument.
13890         * c-common.c (c_common_truthvalue_conversion): Pass location on down.
13891         (c_sizeof_or_alignof_type): New argument.
13892         (c_alignof_expr): Same.
13893         (build_va_arg): Same.
13894         (c_add_case_label): Same.
13895         * c-common.h (c_sizeof_or_alignof_type, c_alignof_expr,
13896         c_sizeof, c_alignof, build_va_arg, build_stmt, build_case_label,
13897         c_build_bind_expr, objc_build_selector_expr, objc_build_throw_stmt,
13898         c_finish_omp_master, c_finish_omp_critical, c_finish_omp_ordered,
13899         c_finish_omp_barrier, c_finish_omp_atomic, c_finish_omp_flush,
13900         c_finish_omp_taskwait, c_finish_omp_for, c_split_parallel_clauses):
13901         New argument.
13902         * stub-objc.c (objc_build_selector_expr): Same.
13903         (objc_build_throw_stmt): Same.
13904         * c-parser.c (c_parser_declaration_or_fndef): Pass location on down.
13905         (c_parser_initelt): Same.
13906         (c_parser_compound_statement): Same.
13907         (c_parser_compound_statement_nostart): Same.
13908         (c_parser_label): Same.
13909         (c_parser_statement_after_labels): Same.
13910         (c_parser_if_body): Same.
13911         (c_parser_else_body): Same.
13912         (c_parser_if_statement): Same.
13913         (c_parser_switch_statement): Same.
13914         (c_parser_while_statement): Same.
13915         (c_parser_do_statement): Same.
13916         (c_parser_for_statement): Same.
13917         (c_parser_asm_statement): Same.
13918         (c_parser_conditional_expression): Same.
13919         (c_parser_binary_expression): Same.
13920         (c_parser_cast_expression): Same.
13921         (c_parser_unary_expression): Same.
13922         (c_parser_sizeof_expression): Same.
13923         (c_parser_alignof_expression): Same.
13924         (c_parser_postfix_expression): Same.
13925         (c_parser_expression): Same.
13926         (c_parser_objc_receiver): Same.
13927         (c_parser_omp_variable_list): Same.
13928         (c_parser_omp_structured_block): Same.
13929         (c_parser_omp_atomic): New argument.
13930         (c_parser_omp_barrier): Same.
13931         (c_parser_omp_critical): Same.
13932         (c_parser_omp_flush): Pass location on down.
13933         (c_parser_omp_for_loop): New argument.
13934         (c_parser_omp_for): Same.
13935         (c_parser_omp_master): Same.
13936         (c_parser_omp_ordered): Same.
13937         (c_parser_omp_sections_scope): Same.
13938         (c_parser_omp_sections): Same.
13939         (c_parser_omp_parallel): Same.
13940         (c_parser_omp_single): Same.
13941         (c_parser_omp_task): Same.
13942         (c_parser_omp_taskwait): Pass location on down.
13943         (c_parser_omp_construct): Same.
13944         (c_parser_omp_threadprivate): Same.
13945         * dwarf2asm.c, targhooks.c, optabs.c, tree.c, tree.h, target.h,
13946         builtins.c, omp-low.c, cgraphunit.c, tree-call-cdce.c,
13947         tree-ssa-alias.c, gimple-low.c, c-tree.h, expr.c, tree-parloops.c,
13948         c-decl.c, tree-eh.c, langhooks.c, function.c, stor-layout.c,
13949         c-typeck.c, gimplify.c, c-pragma.c, expmed.c, except.c, coverage.c,
13950         emit-rtl.c, cfgexpand.c, tree-mudflap.c, varasm.c, tree-nested.c,
13951         rtl.h, tree-inline.c, tree-profile.c, c-common.c, c-common.h,
13952         tree-switch-conversion.c, tree-cfg.c, ipa-struct-reorg.c, c-parser.c,
13953         config/i386/i386.c, stmt.c:
13954         Add location argument to the following function definitions and/or
13955         function calls: build_decl, objcp_start_struct, objcp_finish_struct,
13956         start_struct, finish_struct, PUSH_FIELD, create_artificial_label,
13957         cp_make_fname_decl, pushtag, implicitly_declare, c_make_fname_decl,
13958         build_compound_literal, parser_xref_tag, resolve_overloaded_builtin,
13959         do_case, c_finish_bc_stmt, build_compound_literal,
13960         build_function_call.
13961         * c-decl.c (build_compound_literal): Add location argument.
13962         Make all diagnostic calls use location.
13963         (start_struct): Same.
13964         (finish_struct): Same.
13965         (start_enum): Same.
13966         (build_enumerator): Same.
13967         (start_function): Same.
13968         (grokdeclarator): Make all diagnostic calls use location.
13969         (store_parm_decls_oldstyle): Same.
13970         * c-typeck.c (build_function_call): Add location argument.
13971         Make all diagnostic calls use location.
13972         (do_case): Same.
13973         (c_finish_bc_stmt): Same.
13974         * tree-nested.c (get_trampoline_type): Add argument.
13975         Pass location to build_decl.
13976         (lookup_tramp_for_decl): Pass location to get_trampoline_type.
13977         * rtl.h (RTL_LOCATION): New.
13978         * c-common.c (c_add_case_label): Add location argument.
13979         Make all diagnostic calls use location.
13980         * c-common.h: Add location argument to make_fname_decl, do_case,
13981         c_add_case_label, build_function_call, resolve_overloaded_builtin.
13982         * c-parser.c (c_parser_enum_specifier): Rename ident_loc to enum_loc.
13983         Set it appropriately for every case.  Pass enum_loc to start_enum
13984         call.  Pass value_loc first to build_enumerator.  Pass enum_loc to
13985         parser_xref_tag.
13986         (c_parser_struct_or_union_specifier): Save location.  Use it for
13987         start_struct, finish_struct, and parser_xref_tag.
13988
13989 2009-06-12  Ian Lance Taylor  <iant@google.com>
13990
13991         * fold-const.c (fold_unary): Rename local variable and to and_expr.
13992
13993         * c-opts.c (c_common_handle_option): For -Wc++-compat set
13994         cpp_opts->warn_cxx_operator_names.
13995
13996 2009-06-12  Andrew Pinski  <andrew_pinski@playstation.sony.com>
13997
13998         PR tree-opt/38865
13999         * tree-ssa-sccvn.c (visit_reference_op_load): If vn_reference_lookup
14000         is returns NULL and OP is a VCE, look through the VCE.
14001
14002 2009-06-12  Ian Lance Taylor  <iant@google.com>
14003
14004         PR bootstrap/40430
14005         * collect2.c (main): Use CONST_CAST2 in code inside #if
14006         LINK_ELIMINATE_DUPLICATE_LDIRECTORIES.
14007
14008 2009-06-12  Joey Ye  <joey.ye@intel.com>
14009
14010         PR middle-end/39146
14011         * cfgexpand.c (get_decl_align_unit): Update
14012         max_used_stack_slot_alignment with align instead of
14013         stack_alignment_needed.
14014
14015         * function.c (assign_stack_local_1): Update
14016         max_used_stack_slot_alignment with alignment_in_bits instead
14017         of stack_alignment_needed.
14018         (locate_and_pad_parm): Don't update max_used_stack_slot_alignment
14019         here.
14020
14021 2009-06-12  Jakub Jelinek  <jakub@redhat.com>
14022
14023         * dwarf2out.c (last_var_location_insn): New variable.
14024         (dwarf2out_end_epilogue): Clear last_var_location_insn.
14025         (dwarf2out_var_location): Don't record anything after last real
14026         insn.  Only change labels if there were any real instructions
14027         in between last note and this one, or if changed sections.
14028
14029 2009-06-11  Richard Henderson  <rth@redhat.com>
14030
14031         * alpha.c (alpha_expand_prologue): Add a REF_CFA_REGISTER
14032         note when storing the frame pointer in a register.
14033         (FRP): Don't redefine to nothing for epilogue.
14034         (alpha_expand_epilogue): Mark register and sp restores.
14035         (unicosmk_gen_dsib): Don't mark weird frame pointer adjust.
14036
14037         * config/alpha/alpha.c (alpha_emit_setcc): Fix test for
14038         when gen_lowpart is needed.
14039
14040 2009-06-11  Richard Henderson  <rth@redhat.com>
14041
14042         * dwarf2out.c (def_cfa_1): Likewise for DW_CFA_cfa_offset.
14043
14044         * dwarf2out.c (need_data_align_sf_opcode): New.
14045         (div_data_align): Move earlier.
14046         (def_cfa_1, reg_save): Use it.
14047
14048 2009-06-11  H.J. Lu  <hongjiu.lu@intel.com>
14049
14050         * config/i386/i386.c (OPTION_MASK_ISA_CRC32_SET): New.
14051         (OPTION_MASK_ISA_CRC32_UNSET): Likewise.
14052         (ix86_handle_option): Handle OPT_mcrc32.
14053         (ix86_target_string): Add -mcrc32.
14054         (bdesc_args): Enable crc32 builtins with OPTION_MASK_ISA_CRC32.
14055
14056         * config/i386/i386.h (TARGET_CRC32): New.
14057
14058         * config/i386/i386.md (sse4_2_crc32<mode>): Also check TARGET_CRC32.
14059         (sse4_2_crc32di): Likewise.
14060
14061         * config/i386/i386.opt (mcrc32): New.
14062
14063         * doc/invoke.texi: Document -mcrc32.
14064
14065 2009-06-11  Richard Henderson  <rth@redhat.com>
14066
14067         * common.opt (gdwarf-): Accept a version number.
14068         * doc/invoke.texi (gdwarf-): Update docs.
14069         * opth-gen.awk: Special case -gdwarf+ to OPT_gdwarfplus.
14070         * opts.c (common_handle_option) [OPT_gdwarf_]: Verify dwarf
14071         version level, and record it.
14072
14073         * dwarf2.h (DW_CIE_VERSION): Remove.
14074         * dwarf2out.c (DWARF_VERSION): Remove.
14075         (add_fde_cfi): Skip DW_CFA_set_loc addition for dwarf3.
14076         (output_call_frame_info): Use CIE version 3 for dwarf3,
14077         or if the return register column is out of range for version 1.
14078         (dwarf_stack_op_name): Add all dwarf3 values.
14079         (DEBUG_PUBTYPES_SECTION): New.
14080         (size_of_die) [dw_val_class_die_ref]: Handle DW_FORM_ref_addr
14081         encoding change for dwarf3.
14082         (output_die) [dw_val_class_die_ref]: Likewise.
14083         (output_compilation_unit_header): Emit correct version for dwarf3.
14084         (output_line_info): Likewise.
14085         (output_pubnames): Update for DWARF_VERSION removal.
14086         (output_aranges): Likewise.
14087         (gen_subprogram_die): Emit DW_OP_call_frame_cfa if emitting dwarf3.
14088         (dwarf2out_init): Don't ifdef DEBUG_PUBTYPES_SECTION.
14089         (dwarf2out_finish): Likewise.
14090
14091 2009-06-11  David Daney  <ddaney@caviumnetworks.com>
14092
14093         * system.h (gcc_assert, gcc_unreachable): Revert accidental commit
14094         in r148403.
14095
14096 2009-06-11  David Daney  <ddaney@caviumnetworks.com>
14097
14098         PR c/39252
14099         * doc/extend.texi ( __builtin_unreachable): Document new builtin.
14100         * builtins.c (expand_builtin_unreachable): New function.
14101         (expand_builtin): Handle BUILT_IN_UNREACHABLE case.
14102         * builtins.def (BUILT_IN_UNREACHABLE): Add new builtin.
14103         * cfgcleanup.c (try_optimize_cfg): Delete empty blocks with no
14104         successors.
14105         * cfgrtl.c (rtl_verify_flow_info): Handle empty blocks when
14106         searching for missing barriers.
14107
14108 2009-06-11  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
14109
14110         * config/darwin.h (LINK_COMMAND_SPEC): Adjust spec to link libcov
14111         when -fprofile-generate* was passed.
14112         * config/darwin9.h (LINK_COMMAND_SPEC): Likewise.
14113
14114 2009-06-11  Anthony Green  <green@moxielogic.com>
14115
14116         * config/moxie/moxie.md: Define length attribute for all instructions.
14117         (rCC): Define.
14118         (*b<cond:code>): Support limited branch ranges for new PC-relative
14119         branch instructions.
14120         * config/moxie/moxie.h (HAS_LONG_UNCOND_BRANCH): Define.
14121
14122 2009-06-11  Jakub Jelinek  <jakub@redhat.com>
14123
14124         * config/i386/i386.c (min_insn_size): Use get_attr_length
14125         for normal insns other than TYPE_MULTI, TYPE_OTHER and TYPE_FCMP.
14126         For __asm return 0.
14127
14128         * config/i386/i386.c (ix86_pad_returns): Use emit_jump_insn_before
14129         instead of emit_insn_before.
14130
14131 2009-06-10  Ian Lance Taylor  <iant@google.com>
14132
14133         PR bootstrap/40408
14134         * graphite.c (add_conditions_to_domain): Change SWITCH_EXPR to
14135         GIMPLE_SWITCH.
14136
14137 2009-06-10  Revital Eres  <eres@il.ibm.com>
14138
14139         * passes.c (init_optimization_passes): Reschedule
14140         predictive-commoning pass before complete unroll pass.
14141
14142 2009-06-10  Martin Jambor  <mjambor@suse.cz>
14143
14144         * cgraph.c (cgraph_node_can_be_local_p): New function.
14145         (cgraph_make_node_local): New function.
14146         * cgraph.h (cgraph_node_can_be_local_p): Declare.
14147         (cgraph_make_node_local): Declare.
14148
14149 2009-06-10  Nathan Froyd  <froydnj@codesourcery.com>
14150
14151         * tree.h (tree_base): Add packed_flag and user_align fields.
14152         Decrease size of spare field.
14153         (TYPE_USER_ALIGN): Use user_align from tree_base.
14154         (DECL_USER_ALIGN): Likewise.
14155         (TYPE_PACKED): Use packed_flag from tree_base.
14156         (DECL_PACKED): Likewise.
14157         (tree_type): Delete packed_flag and user_align fields.  Widen
14158         precision field.  Widen mode field and shuffle fields to align
14159         mode on an 8-bit boundary.
14160         (tree_decl_common): Delete decl_flag_1 and user_align fields.
14161         Renumber decl_flag_* fields.  Fix comments.  Widen
14162         decl_common_unused field.
14163         (DECL_HAS_VALUE_EXPR_P): Adjust for renumbering of decl_flag_* fields.
14164         (DECL_EXTERNAL): Likewise.
14165         (DECL_BIT_FIELD): Likewise.
14166         (DECL_NONADDRESSABLE_P): Likewise.
14167         (TYPE_DECL_SUPRESS_DEBUG): Likewise.
14168         * config/arm/arm-modes.def (XImode): Make it an INT_MODE.
14169
14170 2009-06-10  Ian Lance Taylor  <iant@google.com>
14171
14172         * vec.h (DEF_VEC_ALLOC_I): Use DEF_VEC_NONALLOC_FUNCS_I.
14173         (DEF_VEC_ALLOC_P): Use DEF_VEC_NONALLOC_FUNCS_P.
14174         (DEF_VEC_ALLOC_O): Use DEF_VEC_NONALLOC_FUNCS_O.
14175         (DEF_VEC_ALLOC_FUNC_P): Only define VEC_OP (T,A,alloc).
14176         (DEF_VEC_NONALLOC_FUNCS_P): New macro, broken out of old
14177         DEF_VEC_ALLOC_FUNC_P.
14178         (DEF_VEC_ALLOC_FUNC_O): Only define VEC_OP (T,A,alloc).
14179         (DEF_VEC_NONALLOC_FUNCS_O): New macro, broken out of old
14180         DEF_VEC_ALLOC_FUNC_O.
14181         (DEF_VEC_ALLOC_FUNC_I): Only define VEC_OP (T,A,alloc).
14182         (DEF_VEC_NONALLOC_FUNCS_I): New macro, broken out of old
14183         DEF_VEC_ALLOC_FUNC_I.
14184         (vec_stack_p_reserve, vec_stack_p_reserve_exact): Declare.
14185         (vec_stack_p_reserve_exact_1): Declare.
14186         (vec_stack_o_reserve, vec_stack_o_reserve_exact): Declare.
14187         (vec_stack_free): Declare.
14188         (VEC_stack_alloc): Define.
14189         (DEF_VEC_ALLOC_P_STACK, DEF_VEC_ALLOC_FUNC_P_STACK): Define.
14190         (DEF_VEC_ALLOC_O_STACK, DEF_VEC_ALLOC_FUNC_O_STACK): Define.
14191         (DEF_VEC_ALLOC_I_STACK, DEF_VEC_ALLOC_FUNC_I_STACK): Define.
14192         * vec.c (void_p): New type.  Call DEF_VEC_P and DEF_VEC_ALLOC_P
14193         for void_p.
14194         (stack_vecs): New static variable.
14195         (vec_stack_p_reserve_exact_1): New function.
14196         (vec_stack_o_reserve_1): New static function.
14197         (vec_stack_p_reserve, vec_stack_p_reserve_exact): New functions.
14198         (vec_stack_o_reserve, vec_stack_o_reserve_exact): New functions.
14199         (vec_stack_free): New function.
14200         * df-scan.c (df_ref): Use DEF_VEC_P and DEF_VEC_ALLOC_P_STACK.
14201         (VEC_df_ref_stack_alloc): Define.
14202         (df_mw_hardreg_ptr): New type.  Use DEF_VEC_P and
14203         DEF_VEC_ALLOC_P_STACK.
14204         (VEC_df_mw_hardreg_ptr_stack_alloc): Define.
14205         (struct df_collection_rec): Change _vec fields to VEC.  Remove
14206         _use fields.
14207         (df_free_collection_rec): Adjust for new fields.
14208         (df_insn_rescan): Use new df_collection_rec fields.
14209         (df_notes_rescan, df_canonize_collection_rec): Likewise.
14210         (df_ref_create_structure, df_ref_record): Likewise.
14211         (df_get_conditional_uses, df_get_call_refs): Likewise.
14212         (df_insn_refs_collect, df_bb_refs_collect): Likewise.
14213         (df_bb_refs_record, df_record_entry_block_defs): Likewise.
14214         (df_record_exit_block_uses, df_bb_verify): Likewise.
14215         (df_swap_refs): Change ref_vec parameter to VEC.  Change all callers.
14216         (df_sort_and_compress_refs): Change ref_vec parameter to VEC.
14217         Remove count parameter.  Change return type to void.  Change all
14218         callers.
14219         (df_sort_and_compress_mws): Change mw_vec parameter to VEC.
14220         Remove count parameter.  Change return type to void.  Change all
14221         callers.
14222         (df_install_refs): Change old_vec parameter to VEC.  Remove count
14223         parameter.  Change all callers.
14224         (df_install_mws): Change old_vec parameter to VEC.  Remove count
14225         parameter.  Change all callers.
14226         (df_refs_verify): Change new_rec parameter to VEC.  Change call
14227         callers.
14228         (df_mws_verify): Likewise.
14229
14230 2009-06-10  Alexandre Oliva  <aoliva@redhat.com>
14231
14232         * gcc.c (compare_files): Cast munmap argumento to caddr_t.
14233
14234 2009-06-10  H.J. Lu  <hongjiu.lu@intel.com>
14235
14236         * doc/extend.texi: Add description for __builtin_ia32_crc32di.
14237
14238 2009-06-10  Anthony Green  <green@moxielogic.com>
14239
14240         * config/moxie/crti.asm: New file.
14241         * config/moxie/crtn.asm: New file.
14242         * config/moxie/moxie.c: New file.
14243         * config/moxie/moxie.h: New file.
14244         * config/moxie/sfp-machine.h: New file.
14245         * config/moxie/moxie-protos.h: New file.
14246         * config/moxie/t-moxie: Created.
14247         * config/moxie/t-moxie-softfp: Created.
14248         * config/moxie/moxie.md: Created.
14249         * config/moxie/constraints.md: Created.
14250         * config.gcc: Add moxie support.
14251         * doc/md.texi (Machine Constraints): Add moxie constraints.
14252         * doc/contrib.texi (Contributors): Mention moxie port.
14253         * doc/install.texi (Specific): Mention the moxie port.
14254
14255 2009-06-09  Ian Lance Taylor  <iant@google.com>
14256
14257         * system.h (HAVE_DESIGNATED_INITIALIZERS): Don't define if
14258         compiling with C++.
14259         * optabs.c (optab_table): Only use designated initializers if
14260         HAVE_DESIGNATED_INITIALIZERS is defined.
14261         (convert_optab_table): Likewise.
14262         (init_optabs): Always call init_insn_codes if
14263         HAVE_DESIGNATED_INITIALIZERS is not defined.
14264
14265 2009-06-09  Ian Lance Taylor  <iant@google.com>
14266
14267         * targhooks.c (default_builtin_vectorized_function): Change fn
14268         parameter to unsigned int.
14269         (default_builtin_vectorized_conversion): Change code parameter to
14270         unsigned int.
14271         (default_builtin_reciprocal): Change fn parameter to unsigned int.
14272         * targhooks.h: Update declarations.
14273         * config/rs6000/rs6000.c (rs6000_builtin_conversion): Change code
14274         parameter to unsigned int.
14275
14276         * c-typeck.c (comptypes_check_enum_int): New static function.
14277         (comptypes_internal): Add enum_and_int_p parameter.  Change all
14278         callers.
14279         (comp_target_types): Add location parameter.  Change all callers.
14280         (tagged_types_tu_compatible_p): Add enum_and_int_p parameter.
14281         Change all callers.
14282         (function_types_compatible_p, type_lists_compatible_p): Likewise.
14283         (build_conditional_expr): Add colon_loc parameter.  Change all
14284         callers.
14285         (convert_for_assignment): Add location parameter.  Change all callers.
14286         * c-parser.c (c_parser_conditional_expression): Pass location of
14287         colon to build_conditional_expr.
14288         * c-tree.h (build_conditional_expr): Update declaration.
14289
14290 2009-06-09  Sebastian Pop  <sebastian.pop@amd.com>
14291
14292         * graphite.c: Revert previous patch.
14293
14294 2009-06-09  Sebastian Pop  <sebastian.pop@amd.com>
14295
14296         PR bootstrap/40103
14297         * graphite.c: Remove pragma GCC diagnostic warning "-Wc++-compat".
14298
14299 2009-06-09  Ghassan Shobaki  <ghassan.shobaki@amd.com>
14300
14301         * tree-ssa-loop-prefetch.c
14302         (loop_prefetch_arrays): Fixed a portability problem in printf format
14303         string.
14304
14305 2009-06-09  Martin Jambor  <mjambor@suse.cz>
14306
14307         PR tree-optimization/40351
14308         * tree-sra.c (propagate_subacesses_accross_link): Check that a
14309         refrence to a potential artifical subaccess can be constructed.
14310
14311 2009-06-08  Kaz Kojima  <kkojima@gcc.gnu.org>
14312
14313         * config/sh/sh-protos.h (sh_optimization_options): Declare.
14314         (sh_override_options): Likewise.
14315         * config/sh/sh.c: Include params.h.
14316         (sh_optimization_options): New.
14317         (sh_override_options): Likewise.
14318         * config/sh/sh.c (OPTIMIZATION_OPTIONS): Use sh_optimization_options.
14319         (OVERRIDE_OPTIONS): Use sh_override_options.
14320
14321 2009-06-08  Jakub Jelinek  <jakub@redhat.com>
14322
14323         * dwarf2out.c (emit_cfa_remember): New variable.
14324         (add_fde_cfi): If emit_cfa_remember, recurse to add
14325         DW_CFA_remember_state first.
14326         (dwarf2out_begin_epilogue): Don't add_fde_cfi DW_CFA_remember_state,
14327         instead just set emit_cfa_remember.
14328
14329 2009-06-08  Jan Hubicka  <jh@suse.cz>
14330
14331         PR debug/40126
14332         * dwarf2out.c (dwarf2out_abstract_function): Free decl_loc_table.
14333
14334 2009-06-08  Jan Hubicka  <jh@suse.cz>
14335
14336         PR middle-end/39834
14337         * cgraphunit.c (save_inline_function_body): Do not copy transform
14338         hooks for saved inline bodies.
14339         * ipa-passes.c (do_per_function): Do not add the hoks multiple times
14340         for given function.
14341
14342 2009-06-08  Adam Nemet  <anemet@caviumnetworks.com>
14343
14344         * jump.c (returnjump_p): Handle delayed branches.  Add missing
14345         function comment.
14346
14347 2009-06-08  Jan Hubicka  <jh@suse.cz>
14348
14349         PR middle-end/40102
14350         * cgraph.c (cgraph_create_edge_including_clones): Also asume that the
14351         original node might've been modified.
14352         * tree-inline.c (copy_bb): Do not assume that all clones are the same.
14353
14354 2009-06-08  Jakub Jelinek  <jakub@redhat.com>
14355
14356         * tree-object-size.c (addr_object_size): Add OSI argument.
14357         Handle also INDIRECT_REF with SSA_NAME inside of it as base address.
14358         (compute_builtin_object_size, expr_object_size): Adjust callers.
14359         (plus_stmt_object_size): Call addr_object_size instead of
14360         compute_builtin_object_size.
14361
14362 2009-06-08  Ghassan Shobaki  <ghassan.shobaki@amd.com>
14363             Dwarakanath Rajagopal  <dwarak.rajagopal@amd.com>
14364
14365         * tree-ssa-loop-prefetch.c
14366         (gather_memory_references): Introduced a counter for the number of
14367         memory references.
14368         (anything_to_prefetch_p): Introduced a counter for the number of
14369         prefetches.
14370         (is_loop_prefetching_profitable): New function with a cost model
14371         for prefetching.
14372         (loop_prefetch_arrays): Use the new cost model to determine if
14373         prefetching is profitable.
14374         * params.def (MIN_INSN_TO_PREFETCH_RATIO,
14375         PREFETCH_MIN_INSN_TO_MEM_RATIO): New parameters.
14376         * params.h (MIN_INSN_TO_PREFETCH_RATIO,
14377         PREFETCH_MIN_INSN_TO_MEM_RATIO): New parameters.
14378         * doc/invoke.texi (MIN_INSN_TO_PREFETCT_RATIO,
14379         PREFETCH_MIN_INSN_TO_MEM_RATIO): New parameters.
14380
14381 2009-06-08  Michael Matz  <matz@suse.de>
14382
14383         PR debug/40012
14384         * cfgexpand.c (set_rtl): Store place also in DECL_RTL, if all
14385         partitions use the same.
14386         (expand_one_var): Deal with DECL_RTL sometimes begin set also
14387         for basevars of SSA_NAMEs.
14388         (expand_used_vars): Reset TREE_USED for basevars of SSA_NAMEs,
14389         to not expand them twice.
14390         (gimple_expand_cfg): Clear DECL_RTL for those decls that have
14391         multiple places.
14392
14393 2009-06-08  Alexandre Oliva  <aoliva@redhat.com>
14394
14395         * common.opt (fcompare-debug=, fcompare-debug-second): New.
14396         (fdump-final-insns=, gtoggle): New.
14397         * doc/invoke.texi: Document them.
14398         * final.c (rest_of_clean_state): Dump final insn stream.
14399         * gcc.c (invoke_as): Hook in -fcompare-debug.
14400         (static_spec_functions): Add compare-debug-dump-opt,
14401         compare-debug-self-opt and compare-debug-auxbase-opt.
14402         (compare_debug, compare_debug_second, compare_debug_opt): New.
14403         (switches_debug_check, n_switches_debug_check): New.
14404         (debug_auxbase_opt, debug_check_temp_file): New.
14405         (process_command): Handle -fno-compare-debug, -fcompare-debug and
14406         -fcompare-debug=*.
14407         (do_self_spec): Handle arguments after switches.
14408         (do_spec_1): Add .gk extension to temp file basenames for compare.
14409         (check_live_switch): Take SWITCH_IGNORE into account, and earlier.
14410         (cc1_options): Use it instead of normal auxbase computation for
14411         the second compare-debug compilation.
14412         (compare_files): New.
14413         (main): Set up and implement compare debug mode.
14414         (compare_debug_dump_opt_spec_function): New.
14415         (compare_debug_self_opt_spec_function): New.
14416         (compare_debug_auxbase_opt_spec_function): New.
14417         * toplev.c (process_options): Handle flag_gtoggle,
14418         flag_dump_final_insns.
14419         * coverage.c (coverage_begin_output): Don't overwrite .gcno file
14420         during -fcompare-debug-second compilation.
14421
14422 2009-06-07  Ian Lance Taylor  <iant@google.com>
14423
14424         * dwarf2.h (enum dwarf_location_atom): Add INTERNAL_DW_OP_tls_addr.
14425         * dwarf2out.c (INTERNAL_DW_OP_tls_addr): Don't #define.
14426
14427         * c-common.c (c_do_switch_warnings): Don't exit early for -Wswitch
14428         with no default node.  Change warning with %H to warning_at.
14429         Don't clear warn_switch around case checking.
14430         * doc/invoke.texi (Warning Options): Clarify distinction between
14431         -Wswitch and -Wswitch-enum.
14432
14433 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
14434
14435         * tree-pass.h (TODO_update_ssa_any): Document internal use only.
14436
14437 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
14438
14439         * gbl-ctors.h: Add header guard.
14440
14441 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
14442
14443         * tree-flow.h (make_value_handle, set_value_handle, sort_vuses,
14444         sort_vuses_heap, vn_lookup_or_add, vn_lookup_or_add_with_stmt,
14445         vn_lookup_or_add_with_vuses, vn_add, vn_add_with_vuses,
14446         vn_lookup_with_stmt, vn_lookup, vn_lookup_with_vuses): Remove
14447         prototypes for removed functions.
14448         (expressions_equal_p): Move to ...
14449         * tree-ssa-sccvn.h: ... here and ...
14450         * matrix-reorg.c: ... adjust includes.
14451
14452 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
14453
14454         * ipa-struct-reorg.c (do_reorg_1): Fix whitespace in dump output.
14455
14456 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
14457
14458         * c-decl.c (finish_decl): Use bool for variable was_incomplete.
14459         (finish_function): Remove erroneous whitespace.
14460
14461 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
14462
14463         * tree-cfg.c (gimple_merge_blocks): Commentary typo fix.
14464         (verify_stmts): Print statement who's gimple_bb is set to a wrong BB
14465
14466 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
14467
14468         * errors.c (internal_error): Commentary typo fix.
14469         * gimple-iterator.c (gsi_insert_seq_on_edge): Ditto.
14470         * tree-ssa-pre.c: Ditto.
14471
14472 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
14473
14474         * basic-block.h (ENTRY_BLOCK, EXIT_BLOCK): Document that neither of
14475         them is supposed to hold actual statements.
14476
14477 2009-06-06  Ian Lance Taylor  <iant@google.com>
14478
14479         * doc/extend.texi (Attribute Syntax): Document that C++ labels on
14480         empty statements can now have attributes.
14481
14482 2009-06-05  Shujing Zhao  <pearly.zhao@oracle.com>
14483
14484         * config/mips/mips.c: Use REG_P and CONST_INT_P where applicable.
14485         * config/mips/mips.md: Ditto.
14486
14487 2009-06-05  Nathan Froyd  <froydnj@codesourcery.com>
14488
14489         * config/rs6000/eabi.asm (__eabi_convert): Don't define if
14490         _RELOCATABLE.
14491         (__eabi_uconvert): Likewise.
14492
14493 2009-06-05  Nathan Froyd  <froydnj@codesourcery.com>
14494
14495         * config/rs6000/ppc-asm.h: Protect auto-host.h inclusion and
14496         CFI_* definitions with IN_GCC.
14497
14498 2009-06-05  David Edelsohn  <edelsohn@gnu.org>
14499
14500         * xcoffout.h (xcoffout_source_line): Update prototype.
14501
14502 2009-06-05  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
14503
14504         * builtins.c (do_mpc_ckconv, do_mpc_arg1): Use
14505         mpc_realref/mpc_imagref instead of MPC_RE/MPC_IM.
14506
14507 2009-06-05  Jakub Jelinek  <jakub@redhat.com>
14508
14509         PR middle-end/40340
14510         * tree-ssa-live.c (remove_unused_scope_block_p): Don't prune
14511         inlined_function_outer_scope_p blocks for artificial inlines
14512         even at -g0/-g1.
14513         * tree.c (tree_nonartificial_location): Rewrite using
14514         block_nonartificial_location.
14515
14516 2009-06-05  Revital Eres  <eres@il.ibm.com>
14517             Leehod Baruch  <leehod@il.ibm.com>
14518
14519         * expr.c (expand_assignment): Expand MISALIGNED_INDIRECT_REF.
14520         (expand_expr_real_1): Remove comment.
14521         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment):
14522         Vectorize misaligned access when the target supports it.
14523         (vect_supportable_dr_alignment): Check for unaligned access support.
14524         * tree-vect-stmts.c (vectorizable_store): Generate misaligned store
14525         and remove asset.
14526
14527 2009-06-05  Julian Brown  <julian@codesourcery.com>
14528
14529         * config/arm/ieee754-df.S (cmpdf2): Avoid writing below SP.
14530         * config/arm/ieee754-sf.S (cmpsf2): Likewise.
14531
14532 2009-06-05  Richard Guenther  <rguenther@suse.de>
14533
14534         PR bootstrap/40350
14535         * dwarf2out.c (dwarf2out_begin_function): Mark discriminator
14536         as possibly unused.
14537
14538 2009-06-05  Jakub Jelinek  <jakub@redhat.com>
14539
14540         * config/s390/s390.c (global_not_special_regno_p): New static inline.
14541         (save_gprs): Don't tell unwinder when a global register is saved.
14542         (s390_emit_epilogue): Emit needed epilogue unwind info.
14543
14544 2009-06-05  Alexandre Oliva  <aoliva@redhat.com>
14545
14546         * dwarf2out.c (deferred_asm_name): New.
14547         (add_name_and_src_coords_attributes): Defer creation of
14548         DW_AT_MIPS_linkage_name attribute if DECL_ASSEMBLER_NAME was not
14549         computed yet.
14550         (move_linkage_attr): New.
14551         (dwarf2out_finish): Revisit deferrals and emit attributes at the
14552         right place.
14553
14554 2009-06-05  Alexandre Oliva  <aoliva@redhat.com>
14555
14556         * tree-nested.c (finalize_nesting_tree_1): Declare the
14557         frame_decl in the binding tree.
14558
14559 2009-06-04  Cary Coutant  <ccoutant@google.com>
14560
14561         * basic-block.h (struct basic_block_def): Add discriminator field.
14562         * dbxout.c (dbxout_source_line): Add new parameter.  Change all
14563         callers.
14564         * debug.c (do_nothing_debug_hooks): Add additional entry.
14565         (debug_nothing_int_charstar_int): New function.
14566         * debug.h (struct gcc_debug_hooks): Add parameter to source_line hook.
14567         (debug_nothing_int_charstar_int): New declaration.
14568         * dwarf2out.c (dwarf2out_source_line): Add new parameter.  Write
14569         discriminator value in .loc directive.
14570         * final.c (last_discriminator): New variable.
14571         (discriminator): New variable.
14572         (final_start_function): Initialize above variables, pass current
14573         discriminator to debug hook.
14574         (notice_source_line): Check for discriminator change.
14575         * gimple-pretty-print.c (dump_bb_header): Print discriminator value.
14576         * sdbout.c (sdbout_source_line): New parameter.
14577         * tree-cfg.c (struct locus_discrim_map): New structure type.
14578         (discriminator_per_locus): New hash table.
14579         (build_gimple_cfg): Allocate and free discriminator hash table.
14580         (make_edges): Call assign_discriminator.
14581         (locus_map_hash): New function.
14582         (locus_map_eq): New function.
14583         (next_discriminator_for_locus): New function.
14584         (same_line_p): New function.
14585         (assign_discriminator): New function.
14586         (make_cond_expr_edges): Call assign_discriminator.
14587         (make_gimple_switch_edges): Likewise.
14588         (first_non_label_stmt): New function.
14589         * vmsdbgout.c (vmsdbgout_source_line): Add new parameter.  Change
14590         all callers.
14591         * xcoffout.c (xcoffout_source_line): Add new parameter.
14592
14593         * configure.ac (gcc_cv_as_discriminator): New configury check for
14594         gas support for discriminator.
14595         * configure: Regenerate.
14596         * config.in: Regenerate.
14597
14598 2009-06-04  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
14599
14600         * config/arm/arm.c (thumb2_legitimate_index_p): Initialize
14601         val after checking for integers.
14602
14603 2009-06-04  Uros Bizjak  <ubizjak@gmail.com>
14604
14605         * config/i386/i386.h (X86_64_MS_REGPARM_MAX): Rename from
14606         X64_REGPARM_MAX.
14607         (REGPARM_MAX): Use X86_64_MS_REGPARM_MAX.
14608         (X86_64_MS_SSE_REGPARM_MAX): Rename from X64_SSE_REGPARM_MAX.
14609         (SSE_REGPARM_MAX): Use X86_64_MS_SSE_REGPARM_MAX.
14610         * config/i386/i386.c: Use X86_64_MS_REGPARM_MAX instead of
14611         X64_REGPARM_MAX.  Use X86_64_MS_SSE_REGPARM_MAX instead of
14612         X64_SSE_REGPARM_MAX.
14613         * config/i386/i386.md: Use X86_64_MS_SSE_REGPARM_MAX instead of
14614         X64_SSE_REGPARM_MAX.
14615
14616 2009-06-04  Alexandre Oliva  <aoliva@redhat.com>
14617
14618         * gcc.c (report_times_to_file): New.
14619         (execute): Implement it.
14620         (process_command): Support -time=.
14621         * doc/invoke.texi: Document it.
14622
14623 2009-06-04  Alexandre Oliva  <aoliva@redhat.com>
14624
14625         * tree-ssa-live.c (remove_unused_scope_block_p): Keep variables
14626         that have value exprs.
14627
14628 2009-06-04  Alexandre Oliva  <aoliva@redhat.com>
14629
14630         * dwarf2asm.c (dw2_force_const_mem): Defer creation of
14631         declarations for constants until...
14632         (dw2_output_indirect_constant_1): ... this point.
14633
14634 2009-06-04  Richard Earnshaw  <rearnsha@arm.com>
14635
14636         PR target/10242
14637         * arm.md (arm_addsi3): Don't try to split an add with an
14638         eliminable register until after reload has completed.
14639
14640 2009-06-03  Ian Lance Taylor  <iant@google.com>
14641
14642         * dummy-checksum.c (executable_checksum): Use EXPORTED_CONST.
14643         * genattrtab.c (write_length_unit_log): Likewise.
14644         * genchecksum.c (dosum): Likewise.
14645         * gengtype.c (write_rtx_next): Likewise.
14646         (finish_root_table, write_roots): Likewise.
14647         * gimple.c (gimple_ops_offset_): Likewise.
14648         * tree-nomudflap.c (gt_ggc_r_gt_tree_mudflap_h): Likewise.
14649         * config/arc/arc.c (arc_attribute_table): Likewise.
14650         * config/arm/arm.c (arm_attribute_table): Likewise.
14651         * config/avr/avr.c (avr_attribute_table): Likewise.
14652         * config/crx/crx.c (crx_attribute_table): Likewise.
14653         * config/m32r/m32r.c (m32r_attribute_table): Likewise.
14654         * config/m68hc11/m68hc11.c (m68hc11_attribute_table): Likewise.
14655         * config/mcore/mcore.c (mcore_attribute_table): Likewise.
14656         * config/rs6000/rs6000.c (rs6000_attribute_table): Likewise.
14657         * config/sh/sh.c (sh_attribute_table): Likewise.
14658         * config/sparc/sparc.c (sparc_attribute_table): Likewise.
14659         * config/spu/spu.c (spu_attribute_table): Likewise.
14660         * config/v850/v850.c (v850_attribute_table): Likewise.
14661
14662         * config/alpha/alpha.c (vms_attribute_table): Make static.
14663         * config/bfin/bfin.c (bfin_attribute_table): Likewise.
14664         * config/h8300/h8300.c (h8300_attribute_table): Likewise.
14665         * config/mips/mips.c (mips_attribute_table): Likewise.
14666
14667         * Makefile.in (dummy-checksum.o): Depend upon $(CONFIG_H) and
14668         $(SYSTEM_H).
14669         (cc1-checksum.o): Likewise.
14670
14671 2009-06-03  Steve Ellcey  <sje@cup.hp.com>
14672
14673         * config/ia64/vect.md (*movv2sf_internal): Handle big endian case.
14674
14675 2009-06-03  Jakub Jelinek  <jakub@redhat.com>
14676
14677         * config/rs6000/rs6000.c (rs6000_emit_stack_reset): Return generated
14678         insn if it is changing sp.  Use gen_add3_insn instead of
14679         conditionally gen_addsi3 and gen_adddi3.
14680         (offset_below_red_zone_p): New static inline function.
14681         (rs6000_emit_epilogue): Emit needed epilogue unwind info.
14682         Use gen_add3_insn instead of conditionally gen_addsi3 and gen_adddi3.
14683         * config/rs6000/ppc-asm.h: Include auto-host.h.
14684         (CFI_STARTPROC, CFI_ENDPROC, CFI_DEF_CFA_REGISTER, CFI_OFFSET,
14685         CFI_RESTORE): Define.
14686         * config/rs6000/crtresxgpr.asm: Add unwind info.
14687         * config/rs6000/crtresxfpr.asm: Likewise.
14688         * config/rs6000/crtresgpr.asm: Likewise.
14689         * config/rs6000/crtresfpr.asm: Likewise.
14690         * config/rs6000/crtsavgpr.asm: Likewise.
14691         * config/rs6000/crtsavfpr.asm: Likewise.
14692
14693         * dwarf2out.c (output_cfi_directive): Pass 1 instead of 0 to second
14694         argument of DWARF2_FRAME_REG_OUT macros.
14695
14696 2009-06-03  Julian Brown  <julian@codesourcery.com>
14697
14698         * config/arm/arm.c (arm_hard_regno_mode_ok): Permit values of four
14699         words or less (including TImode) in core registers.
14700
14701 2009-06-03  Richard Guenther  <rguenther@suse.de>
14702
14703         PR middle-end/40328
14704         * fold-const.c (fold_convert): Fold the build COMPLEX_EXPR.
14705
14706 2009-06-03  Andrey Belevantsev  <abel@ispras.ru>
14707
14708         * statistics.c (statistics_counter_event): Do not record event
14709         in pass dump if its number == -1.
14710         (curr_statistics_hash): Add assert that we never get passes
14711         with static number == -1.
14712
14713 2009-06-03  Richard Guenther  <rguenther@suse.de>
14714             Andrey Belevantsev  <abel@ispras.ru>
14715
14716         * cfgexpand.c (discover_nonconstant_array_refs_r): Make only
14717         non-BLKmode arrays addressable.
14718
14719 2009-06-03  Maxim Kuvyrkov  <maxim@codesourcery.com>
14720
14721         * config/m68k/linux.h (HAVE_GAS_BALIGN_AND_P2ALIGN): Move to ...
14722         * config/m68k/m68k.h: ... here.
14723
14724 2009-06-03  Martin Jambor  <mjambor@suse.cz>
14725
14726         PR tree-optimization/40323
14727         * ipa-prop.c (get_ssa_def_if_simple_copy): Break if not single
14728         assignment.
14729
14730 2009-06-03  Richard Guenther  <rguenther@suse.de>
14731
14732         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Use DECL_SIZE
14733         consistently.
14734
14735 2009-06-03  Shujing Zhao  <pearly.zhao@oracle.com>
14736
14737         * config/sh/predicates.md: Use REG_P, MEM_P, CONST_INT_P, LABEL_P,
14738         JUMP_P, CALL_P, NONJUMP_INSN_P, NOTE_P, BARRIER_P and
14739         JUMP_TABLE_DATA_P where applicable.
14740         * config/sh/sh.c: Ditto.
14741         * config/sh/sh.h: Ditto.
14742         * config/sh/sh.md: Ditto.
14743         * config/sh/symbian.c: Ditto.
14744
14745 2009-06-03  Uros Bizjak  <ubizjak@gmail.com>
14746
14747         * config/i386/driver-i386.c (describe_cache): Optimize
14748         concatenation of strings.  Use snprintf instead of sprintf.
14749         (host_detect_local_cpu): Ditto.  Ignore -march and -mtune for native
14750         target when not compiling with GCC.
14751
14752 2009-06-02  Kaz Kojima  <kkojima@gcc.gnu.org>
14753
14754         * config/sh/sh.c: Revert last change.
14755         (sh_expand_epilogue): Emit a blockage insn before the frame
14756         pointer adjustment unconditionally.
14757
14758 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
14759
14760         * config/pa/pa-hpux.h (LINK_SPEC): Remove "%<fwhole-program".
14761         * config/pa/pa-hpux10.h (LINK_SPEC): Likewise.
14762         * config/pa/pa-hpux11.h (LINK_SPEC): Likewise.
14763         * gcc.c (set_collect_gcc_options): Don't add -fwhole-program
14764         to COLLECT_GCC_OPTIONS.
14765
14766 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
14767
14768         * collect2.c (target_system_root): New variable.
14769         (main): Handle --sysroot=.
14770         (ignore_library): Strip the sysroot from the library path.
14771
14772 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
14773
14774         * Makefile.in (COLLECT2_OBJS): Add collect2-aix.o.
14775         (collect2.o): Depend on collect2-aix.h.
14776         (collect2-aix.o): New rule.
14777         * collect2-aix.h: New file.
14778         * collect2-aix.c: Likewise.
14779         * collect2.c: Include collect2-aix.h.  Don't undefine
14780         OBJECT_FORMAT_COFF if CROSS_AIX_SUPPORT is defined.
14781         Guard native includes with #ifndef CROSS_DIRECTORY_STRUCTURE.
14782         Use TARGET_AIX_VERSION instead of _AIX51.
14783         * config/rs6000/aix43.h (TARGET_AIX_VERSION): Define.
14784         * config/rs6000/aix51.h (TARGET_AIX_VERSION): Likewise.
14785         * config/rs6000/aix52.h (TARGET_AIX_VERSION): Likewise.
14786         * config/rs6000/aix53.h (TARGET_AIX_VERSION): Likewise.
14787         * config/rs6000/aix61.h (TARGET_AIX_VERSION): Likewise.
14788
14789 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
14790
14791         * collect2.c (ignore_library): Avoid premature post-increment
14792         and null deference.
14793
14794 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
14795
14796         * Makefile.in (libgcc.mvars): Add TARGET_SYSTEM_ROOT.
14797         * config/rs6000/aix.h (LINK_SYSCALLS_SPEC): Add %R to the
14798         !CROSS_DIRECTORY_STRUCTURE alternative and use it for
14799         CROSS_DIRECTORY_STRUCTURE too.
14800         (LINK_LIBG_SPEC): Likewise.
14801         (LIB_SPEC): Add %R to sysroot paths.
14802         * config/rs6000/aix43.h (CPP_SPEC): Add %R to sysroot paths.
14803         (CPLUSPLUS_CPP_SPEC, LIB_SPEC): Likewise.
14804         * config/rs6000/aix51.h: As for aix43.h.
14805         * config/rs6000/aix52.h: Likewise.
14806         * config/rs6000/aix53.h: Likewise.
14807         * config/rs6000/aix61.h: Likewise.
14808         * config/rs6000/t-aix52 (SHLIB_LINK): Add $(TARGET_SYSTEM_ROOT)
14809         to the beginning of sysroot paths.
14810
14811 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
14812
14813         * print_rtl (print_rtx): Don't print modes in EXPR_LISTs and
14814         INSN_LISTs that are out of the REG_NOTE range.
14815
14816 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
14817
14818         * loop-unroll.c (struct iv_to_split): Add pointer to next.
14819         (struct var_to_expand): Likewise.
14820         (struct opt_info): Add head and tail for linked lists of the above.
14821         (analyze_insn_to_expand_var): Initialize next.
14822         (analyze_iv_to_split_insn): Likewise.
14823         (analyze_insns_in_loop): Create linked lists.
14824         (allocate_basic_variable): Simplify for use without hash table.
14825         (insert_var_expansion_initialization): Likewise, make it type-safer.
14826         (combine_var_copies_in_loop_exit): Likewise.
14827         (apply_opt_in_copies): Walk lists rather than hash tables.
14828         (release_var_copies): Simplified and inlined by hand into...
14829         (free_opt_info): ... this function.
14830
14831 2009-06-02  Richard Guenther  <rguenther@suse.de>
14832
14833         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Use DECL_SIZE
14834         for field decls.
14835
14836 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
14837
14838         * cfgexpand.c (gimple_expand_cfg): Discard the source location
14839         only for builtins that are not overridden.
14840
14841 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
14842
14843         * gengtype.c (adjust_field_rtx_def): Add NOTE_INSN_DELETED_LABEL's
14844         label string.
14845
14846 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
14847
14848         * df-core.c (df_ref_debug): Honor -fdump-noaddr.
14849
14850 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
14851
14852         * combine.c (move_deaths): Compare LUIDs within the same BB only.
14853
14854 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
14855
14856         * common.opt (fdump-unnumbered-links): New.
14857         * doc/invoke.texi (-fdump-unnumbered-links): Document it.
14858         * print-rtl.c (flag_dump_unnumbered_links): New.
14859         (print_rtx): Test it.
14860
14861 2009-06-02  Richard Earnshaw  <rearnsha@arm.com>
14862
14863         * arm.c (arm_get_frame_offsets): Prefer using r3 for padding a
14864         push/pop multiple to 8-byte alignment.
14865
14866 2009-06-01  Jakub Jelinek  <jakub@redhat.com>
14867
14868         * config/i386/i386.c (queued_cfa_restores): New static variable.
14869         (ix86_add_cfa_restore_note, ix86_add_queued_cfa_restore_notes): New
14870         functions.
14871         (pro_epilogue_adjust_stack): Call ix86_add_queued_cfa_restore_notes.
14872         (ix86_emit_restore_reg_using_pop): Add RED_OFFSET argument.
14873         Set RTX_FRAME_RELATED_P immediately after adding a REG_CFA_* note.
14874         Call ix86_add_cfa_restore_note instead of adding REG_CFA_OFFSET
14875         note unconditionally.
14876         (ix86_emit_restore_regs_using_mov): Likewise.
14877         (ix86_emit_restore_sse_regs_using_mov): Likewise.
14878         (ix86_emit_restore_regs_using_pop): Add RED_OFFSET argument, pass
14879         it through to ix86_emit_restore_reg_using_pop.
14880         (ix86_emit_leave): Add RED_OFFSET argument.  Call
14881         ix86_add_queued_cfa_restore_notes.  Call ix86_add_cfa_restore_note
14882         instead of adding REG_CFA_OFFSET note unconditionally.
14883         (ix86_expand_epilogue): Compute RED_OFFSET, pass it down to
14884         the above functions.  Call ix86_add_queued_cfa_restore_notes when
14885         needed.
14886
14887         * dwarf2out.c (dwarf2out_cfi_label): Add FORCE argument, if true,
14888         force output of the label even for dwarf2out_do_cfi_asm.
14889         (add_fde_cfi): If -g2 and above and cfi might change CFA,
14890         force creation of CFI label and chain DW_CFA_set_loc jumping to it
14891         for convert_cfa_to_fb_loc_list.  Adjust other dwarf2out_cfi_label
14892         caller.
14893         (dwarf2out_stack_adjust, dwarf2out_frame_debug,
14894         dwarf2out_begin_epilogue, dwarf2out_frame_debug_restore_state): Adjust
14895         dwarf2out_cfi_label callers.
14896         * tree.h (dwarf2out_cfi_label): Adjust prototype.
14897         * config/arm/arm.c (thumb_pushpop, thumb1_output_function_prologue):
14898         Adjust dwarf2out_cfi_label callers.
14899         * config/vax/vax.c (vax_output_function_prologue): Likewise.
14900
14901         * config/i386/i386.h (struct machine_cfa_state,
14902         struct machine_function): Guard with ifndef USED_FOR_TARGET
14903         instead of not IN_LIBGCC2 and not in IN_TARGET_LIBS.
14904
14905         PR other/40024
14906         * emutls.c (__emutls_get_address): Change arr->size to mean number
14907         of allocated arr->data entries instead of # of slots + 1.
14908
14909         PR middle-end/40316
14910         * recog.c (peep2_reinit_state): New function.
14911         (peephole2_init_state): Use it at the end of a basic block and also
14912         when seeing a RTX_FRAME_RELATED_P insn.
14913
14914 2009-06-01  Steve Ellcey  <sje@cup.hp.com>
14915
14916         * ia64.md (floatdirf2, fix_truncrfdi, floatunsdirf,
14917         fixuns_truncrfdi2): New.
14918         (fix_truncxfdi2_alts, fixuns_truncxfdi2_alts,
14919         *nmaddsf4_alts, *nmadddf4_alts, *nmadddf4_truncsf_alts,
14920         *mulxf3_alts, *mulxf3_truncsf_alts, *mulxf3_truncdf_alts,
14921         *maddxf4_alts, *maddxf4_alts_truncsf, *maddxf4_alts_truncdf,
14922         *nmaddxf4_alts, *nmaddxf4_truncsf_alts, *nmaddxf4_truncdf_alts,
14923         *recip_approx): Remove.
14924         (divsi3 modsi3, udivsi3, umodsi3, divsi3_internal, divdi3,
14925         moddi3, udivdi3, umoddi3, divdi3_internal_lat, divdi3_internal_thr,
14926         divsf3, sqrtsf2, divdf3, sqrtdf2, divxf3, sqrtxf2): Modify and
14927         move to div.md.
14928         * div.md (fix_truncrfdi2_alts, fixuns_truncrfdi2_alt,
14929         setf_exp_rf): New.
14930
14931 2009-06-01  Ian Lance Taylor  <iant@google.com>
14932
14933         * attribs.c (register_attribute): Use CONST_CAST.
14934         * collect2.c (main): Use CONST_CAST2.
14935         (scan_prog_file): Likewise.
14936         * gcc.c (process_command, main): Likewise.
14937         * toplev.c (toplev_main): Likewise.
14938
14939         * c-typeck.c (handle_warn_cast_qual): New static function,
14940         partially broken out of build_c_cast.
14941         (build_c_cast): Call handle_warn_cast_qual.
14942         * doc/invoke.texi (Warning Options): Document new effect of
14943         -Wcast-qual.
14944
14945 2009-06-01  Aldy Hernandez  <aldyh@redhat.com>
14946
14947         * diagnostic.c (diagnostic_build_prefix): Always print columns.
14948         (diagnostic_report_current_module): Print columns.
14949         * common.opt (flag_show_column): Enable by default.
14950
14951 2009-06-01  Luis Machado  <luisgpm@br.ibm.com>
14952
14953         * alias.c (find_base_term): Check for NULL term before returning.
14954
14955 2009-06-01  Maxim Kuvyrkov  <maxim@codesourcery.com>
14956
14957         Revert due to PR40320:
14958         2009-06-01  Maxim Kuvyrkov  <maxim@codesourcery.com>
14959         * calls.c (emit_library_call_value_1): Don't force_operand for move
14960         and push insns.
14961
14962 2009-06-01  Olivier Hainque  <hainque@adacore.com>
14963             Eric Botcazou  <ebotcazou@adacore.com>
14964
14965         * tree.h (CONSTRUCTOR_BITFIELD_P): True if NODE, a FIELD_DECL, is
14966         to be processed as a bitfield for constructor output purposes.
14967         * output.h (initializer_constant_valid_for_bitfield_p): Declare
14968         new function.
14969         * varasm.c (oc_local_state): New type, output_constructor
14970         local state to support communication with helpers.
14971         (oc_outer_state): New type, output_constructor outer state of
14972         relevance in recursive calls.
14973         (output_constructor_array_range): New output_constructor helper,
14974         extracted code for an array range element.
14975         (output_constructor_regular_field): New output_constructor helper,
14976         extracted code for an element that is not a bitfield.
14977         (output_constructor_bitfield): New output_constructor helper,
14978         extracted code for a bitfield element.  Accept an OUTER state
14979         argument for recursive processing.  Recurse on record or array
14980         CONSTRUCTOR values, possibly past noop conversions.
14981         (initializer_constant_valid_for_bitfield_p): New predicate.  Whether
14982         VALUE is a valid constant-valued expression for use in a static
14983         bit-field initializer.
14984         (output_constructor): Rework to use helpers.  Accept and honor an
14985         OUTER state argument for recursive calls.  Return total size.  Be
14986         prepared for nested constructors initializing bitfields.
14987         (output_constant): Feed OUTER in calls to output_constructor.
14988
14989 2009-06-01  Maxim Kuvyrkov  <maxim@codesourcery.com>
14990
14991         * calls.c (emit_library_call_value_1): Don't force_operand for move
14992         and push insns.
14993
14994 2009-06-01  Nick Clifton  <nickc@redhat.com>
14995
14996         * doc/invoke.texi (IA-64 Options): Fix typo.
14997
14998 2009-06-01  Ira Rosen  <irar@il.ibm.com>
14999
15000         PR tree-optimization/39129
15001         * tree-vect-loop-manip.c (conservative_cost_threshold): Change the
15002         printed message.
15003         (vect_do_peeling_for_loop_bound): Use
15004         LOOP_REQUIRES_VERSIONING_FOR_ALIGNMENT and
15005         LOOP_REQUIRES_VERSIONING_FOR_ALIAS macros.
15006         (vect_loop_versioning): Likewise.
15007         (vect_create_cond_for_alias_checks): Fix indentation.
15008         * tree-vectorizer.h (struct _loop_vec_info): Fix indentation of the
15009         macros.
15010         (LOOP_REQUIRES_VERSIONING_FOR_ALIGNMENT): Define.
15011         (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Likewise.
15012         * tree-vect-loop.c (vect_analyze_loop_form): Change "too many BBs" to
15013         "control flow in loop".
15014         (vect_estimate_min_profitable_iters): Use
15015         LOOP_REQUIRES_VERSIONING_FOR_ALIGNMENT and
15016         LOOP_REQUIRES_VERSIONING_FOR_ALIAS macros.
15017         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
15018         (vect_create_data_ref_ptr): Don't mention array dimension in printing.
15019         * tree-vect-stmts.c (vectorizable_store): Replace the check that the
15020         statement belongs to a group of strided accesses with the exact code
15021         check.
15022         (vectorizable_load): Likewise.
15023         * tree-vect-slp.c (vect_analyze_slp_instance): Spell out "basic block".
15024         (vect_slp_analyze_bb, vect_slp_transform_bb): Likewise.
15025
15026 2009-06-01  Gerald Pfeifer  <gerald@pfeifer.com>
15027
15028         * config/freebsd-stdint.h: New file.
15029         * config.gcc (*-*-freebsd): Set use_gcc_stdint=wrap.
15030         Add freebsd-stdint.h to tm_file.
15031
15032 2009-06-01  Richard Earnshaw  <rearnsha@arm.com>
15033
15034         * arm/thumb2.md (thumb2_zero_extendhidi2): New insn and split.
15035         (thumb2_extendhidi2): Likewise.
15036
15037 2009-05-31  Ian Lance Taylor  <iant@google.com>
15038
15039         * regstat.c (regstat_n_sets_and_refs): Remove duplicate definition.
15040
15041 2009-05-31  Ian Lance Taylor  <iant@google.com>
15042
15043         * Makefile.in (except.o): Depend upon gt-except.h, not gt-$(EXCEPT_H).
15044         (ipa-cp.o): Depend upon $(FIBHEAP_H) and $(PARAMS_H).
15045         (ipa-reference.o): Depend upon gt-ipa-reference.h.
15046
15047 2009-05-31  Jason Merrill  <jason@redhat.com>
15048
15049         * tree-pretty-print.c (print_call_name): Take the callee, not the
15050         call itself.  Make non-static.  Use dump_function_name for functions.
15051         (dump_generic_node): Adjust.
15052         * diagnostic.h: Declare print_call_name.
15053         * gimple-pretty-print.c (dump_gimple_call): Use it.
15054
15055 2009-05-31  Kaz Kojima  <kkojima@gcc.gnu.org>
15056
15057         * config/sh/sh.md (ashldi3_std): New define_expand.
15058         (ashldi3): Use it.
15059
15060 2009-05-31  Kaz Kojima  <kkojima@gcc.gnu.org>
15061
15062         PR target/40313
15063         * config/sh/sh.c: Include debug.h.
15064         (sh_expand_epilogue): Emit a blockage insn before the frame
15065         pointer adjustment also when dwarf2out_do_frame returns true.
15066
15067 2009-05-31  Richard Earnshaw  <rearnsha@arm.com>
15068
15069         * arm/thumb2.md (thumb2_extendsidi2): Add a split sub-pattern.
15070         (thumb2_extendqidi2): New pattern.
15071
15072 2009-05-31  Ira Rosen  <irar@il.ibm.com>
15073
15074         * tree-vect-loop-manip.c (slpeel_update_phi_nodes_for_guard1): Don't
15075         mark phis for renaming.
15076         * tree-vectorizer.c (vect_memsyms_to_rename): Remove.
15077         (vectorize_loops): Don't allocate and free vect_memsyms_to_rename.
15078         Call mark_sym_for_renaming.
15079         * tree-vectorizer.h (vect_memsyms_to_rename): Remove.
15080         * tree-vect-loop.c (vect_transform_loop): Remove
15081         vect_memsyms_to_rename initialization and a call to
15082         mark_set_for_renaming.
15083
15084 2009-05-31  Jakub Jelinek  <jakub@redhat.com>
15085
15086         PR middle-end/40304
15087         * config/i386/i386.c (pro_epilogue_adjust_stack): Mark insns
15088         frame related even if !set_cfa && style < 0.
15089
15090 2009-05-30  Kai Tietz  <kai.tietz@onevision.com>
15091
15092         * config/i386/mingw-tls.c: New file.
15093         * config/i386/t-gthr-win32 (LIB2FUNCS_EXTRA): Add mingw-tls.c file.
15094         * gthr-win32.h (MINGW32_SUPPORTS_MT_EH): Define it for targets
15095         defining _WIN32 but not __CYGWIN__.
15096
15097 2009-05-29  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
15098
15099         * configure.ac: Add MPC support.
15100
15101         * config.in, configure: Regenerate.
15102
15103 2009-05-29  Richard Henderson  <rth@redhat.com>
15104
15105         * cfgcleanup.c (try_crossjump_to_edge): Only skip past
15106         NOTE_INSN_BASIC_BLOCK.
15107         * cfglayout.c (duplicate_insn_chain): Copy epilogue insn marks.
15108         Duplicate NOTE_INSN_EPILOGUE_BEG notes.
15109         * cfgrtl.c (can_delete_note_p): Allow NOTE_INSN_EPILOGUE_BEG
15110         to be deleted.
15111         * dwarf2out.c (struct cfa_loc): Change indirect field to bitfield,
15112         add in_use field.
15113         (add_cfi): Disable check redefining cfa away from drap.
15114         (lookup_cfa_1): Add remember argument; handle remember/restore.
15115         (lookup_cfa): Pass remember argument.
15116         (cfa_remember): New.
15117         (compute_barrier_args_size_1): Remove sibcall check.
15118         (dwarf2out_frame_debug_def_cfa): New.
15119         (dwarf2out_frame_debug_adjust_cfa): New.
15120         (dwarf2out_frame_debug_cfa_offset): New.
15121         (dwarf2out_frame_debug_cfa_register): New.
15122         (dwarf2out_frame_debug_cfa_restore): New.
15123         (dwarf2out_frame_debug): Handle REG_CFA_* notes.
15124         (dwarf2out_begin_epilogue): New.
15125         (dwarf2out_frame_debug_restore_state): New.
15126         (dw_cfi_oprnd1_desc): Handle DW_CFA_remember_state,
15127         DW_CFA_restore_state.
15128         (output_cfi_directive): Likewise.
15129         (convert_cfa_to_fb_loc_list): Likewise.
15130         (dw_cfi_oprnd1_desc): Handle DW_CFA_restore.
15131         * dwarf2out.h: Update.
15132         * emit-rtl.c (try_split): Don't split RTX_FRAME_RELATED_P.
15133         (copy_insn_1): Early out for null.
15134         * final.c (final_scan_insn): Call dwarf2out_begin_epilogue
15135         and dwarf2out_frame_debug_restore_state.
15136         * function.c (prologue, epilogue, sibcall_epilogue): Remove.
15137         (prologue_insn_hash, epilogue_insn_hash): New.
15138         (free_after_compilation): Adjust freeing accordingly.
15139         (record_insns): Create hash table if needed; push insns into
15140         hash instead of array.
15141         (maybe_copy_epilogue_insn): New.
15142         (contains): Search hash table instead of array.
15143         (sibcall_epilogue_contains): Remove.
15144         (thread_prologue_and_epilogue_insns): Split eh_return insns
15145         and mark them as epilogues.
15146         (reposition_prologue_and_epilogue_notes): Rewrite epilogue
15147         scanning in terms of basic blocks.
15148         * insn-notes.def (CFA_RESTORE_STATE): New.
15149         * jump.c (returnjump_p_1): Accept EH_RETURN.
15150         (eh_returnjump_p_1, eh_returnjump_p): New.
15151         * reg-notes.def (CFA_DEF_CFA, CFA_ADJUST_CFA, CFA_OFFSET,
15152         CFA_REGISTER, CFA_RESTORE): New.
15153         * rtl.def (EH_RETURN): New.
15154         * rtl.h (eh_returnjump_p, maybe_copy_epilogue_insn): Declare.
15155
15156         * config/bfin/bfin.md (UNSPEC_VOLATILE_EH_RETURN): Remove.
15157         (eh_return_internal): Use eh_return rtx; split w/ epilogue.
15158
15159         * config/i386/i386.c (gen_push): Update cfa state.
15160         (pro_epilogue_adjust_stack): Add set_cfa argument.  When true,
15161         add a CFA_ADJUST_CFA note.
15162         (ix86_dwarf_handle_frame_unspec): Remove.
15163         (ix86_expand_prologue): Update cfa state.
15164         (ix86_emit_restore_reg_using_pop): New.
15165         (ix86_emit_restore_regs_using_pop): New.
15166         (ix86_emit_leave): New.
15167         (ix86_emit_restore_regs_using_mov): Add CFA_RESTORE notes.
15168         (ix86_expand_epilogue): Add notes for unwinding the epilogue.
15169         * config/i386/i386.h (struct machine_cfa_state): New.
15170         (ix86_cfa_state): New.
15171         * config/i386/i386.md (UNSPEC_EH_RETURN): Remove.
15172         (eh_return_internal): Merge from eh_return_<mode>,
15173         use eh_return rtx, split w/ epilogue.
15174
15175 2009-05-29  Ian Lance Taylor  <iant@google.com>
15176
15177         * builtins.c (validate_gimple_arglist): Don't use va_arg with
15178         enum type.
15179         * calls.c (emit_library_call_value_1): Likewise.
15180
15181         * c-typeck.c (c_build_va_arg): New function.
15182         * c-tree.h (c_build_va_arg): Declare.
15183         * c-parser.c (c_parser_postfix_expression): Call c_build_va_arg
15184         instead of build_va_arg.
15185
15186 2009-05-29  Eric Botcazou  <ebotcazou@adacore.com>
15187
15188         * tree-ssa-loop-ivopts.c (strip_offset_1) <MULT_EXPR>: New case.
15189         (force_expr_to_var_cost) <NEGATE_EXPR>: Likewise.
15190         (ptr_difference_cost): Use affine combinations to compute it.
15191         (difference_cost): Likewise.
15192         (get_computation_cost_at): Compute more accurate cost for addresses
15193         if the ratio is a multiplier allowed in addresses.
15194         For non-addresses, consider that an additional offset or symbol is
15195         added only once.
15196
15197 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
15198
15199         * config/i386/i386.c (ix86_decompose_address): Avoid useless
15200         0 displacement.  Add 0 displacement if base is %[er]bp or %r13.
15201
15202         * config/i386/i386.md (prefix_data16, prefix_rep): Set to 0 for
15203         TYPE_SSE{MULADD,4ARG,IADD1,CVT1} by default.
15204         (prefix_rex): For UNIT_MMX don't imply the prefix by default
15205         if MODE_DI.
15206         (prefix_extra): Default to 2 for TYPE_SSE{MULADD,4ARG} and
15207         to 1 for TYPE_SSE{IADD1,CVT1}.
15208         (prefix_vex_imm8): Removed.
15209         (length_vex): Only pass 1 as second argument to
15210         ix86_attr_length_vex_default if prefix_extra is 0.
15211         (modrm): For TYPE_INCDEC only set to 0 if not TARGET_64BIT.
15212         (length): For prefix vex computation use length_immediate
15213         attribute instead of prefix_vex_imm8.
15214         (cmpqi_ext_3_insn, cmpqi_ext_3_insn_rex64,
15215         addqi_ext_1, addqi_ext_1_rex64, *testqi_ext_0, andqi_ext_0,
15216         *andqi_ext_0_cc, *iorqi_ext_0, *xorqi_ext_0, *xorqi_cc_ext_1,
15217         *xorqi_cc_ext_1_rex64): Override modrm attribute to 1.
15218         (extendsidi2_rex64, extendhidi2, extendqidi2, extendhisi2,
15219         *extendhisi2_zext, extendqihi2, extendqisi2, *extendqisi2_zext): Emit
15220         a space in between the operands.
15221         (*anddi_1_rex64, *andsi_1): Likewise.  Override prefix_rex to 1
15222         if one operand is 0xff and the other one si, di, bp or sp.
15223         (*andhi_1): Override prefix_rex to 1 if one operand is 0xff and the
15224         other one si, di, bp or sp.
15225         (*btsq, *btrq, *btcq, *btdi_rex64, *btsi): Add mode attribute.
15226         (*ffssi_1, *ffsdi_1, ctzsi2, ctzdi2): Add
15227         type and mode attributes.
15228         (*bsr, *bsr_rex64, *bsrhi): Add type attribute.
15229         (*cmpfp_i_mixed, *cmpfp_iu_mixed): For TYPE_SSECOMI, clear
15230         prefix_rep attribute and set prefix_data16 attribute iff MODE_DF.
15231         (*cmpfp_i_sse, *cmpfp_iu_sse): Clear prefix_rep attribute and set
15232         prefix_data16 attribute iff MODE_DF.
15233         (*movsi_1): For TYPE_SSEMOV MODE_SI set prefix_data16 attribute.
15234         (fix_trunc<mode>di_sse): Set prefix_rex attribute.
15235         (*adddi_4_rex64, *addsi_4): Use const128_operand instead of
15236         constm128_operand in length_immediate computation.
15237         (*addhi_4): Likewise.  Fix mode attribute to MODE_HI.
15238         (anddi_1_rex64): Use movzbl/movzwl instead of movzbq/movzwq.
15239         (*avx_ashlti3, sse2_ashlti3, *avx_lshrti3, sse2_lshrti3): Set
15240         length_immediate attribute to 1.
15241         (x86_fnstsw_1, x86_fnstcw_1, x86_fldcw_1): Fix length attribute.
15242         (*movdi_1_rex64): Override prefix_rex or prefix_data16 attributes
15243         for certain alternatives.
15244         (*movdf_nointeger, *movdf_integer_rex64, *movdf_integer): Override
15245         prefix_data16 attribute if MODE_V1DF.
15246         (*avx_setcc<mode>, *sse_setcc<mode>, *sse5_setcc<mode>): Set
15247         length_immediate to 1.
15248         (set_got_rex64, set_rip_rex64): Remove length attribute, set
15249         length_address to 4, set mode attribute to MODE_DI.
15250         (set_got_offset_rex64): Likewise.  Set length_immediate to 0.
15251         (fxam<mode>2_i387): Set length attribute to 4.
15252         (*prefetch_sse, *prefetch_sse_rex, *prefetch_3dnow,
15253         *prefetch_3dnow_rex): Override length_address attribute.
15254         (sse4_2_crc32<mode>): Override prefix_data16 and prefix_rex
15255         attributes.
15256         * config/i386/predicates.md (ext_QIreg_nomode_operand): New predicate.
15257         (constm128_operand): Removed.
15258         * config/i386/i386.c (memory_address_length): For
15259         disp && !index && !base in 64-bit mode account for SIB byte if
15260         print_operand_address can't optimize disp32 into disp32(%rip)
15261         and UNSPEC doesn't imply (%rip) addressing.  Add 1 to length
15262         for fs: or gs: segment.
15263         (ix86_attr_length_immediate_default): When checking if shortform
15264         is possible, truncate immediate to the length of the non-shortened
15265         immediate.
15266         (ix86_attr_length_address_default): Ignore MEM_P operands
15267         with X constraint.
15268         (ix86_attr_length_vex_default): Only check for DImode on
15269         GENERAL_REG_P operands.
15270         * config/i386/sse.md (<sse>_comi, <sse>_ucomi): Clear
15271         prefix_rep attribute, set prefix_data16 attribute iff MODE_DF.
15272         (sse_cvttps2pi): Clear prefix_rep attribute.
15273         (sse2_cvttps2dq, *sse2_cvtpd2dq, sse2_cvtps2pd): Clear prefix_data16
15274         attribute.
15275         (*sse2_cvttpd2dq): Don't clear prefix_rep attribute.
15276         (*avx_ashr<mode>3, ashr<mode>3, *avx_lshr<mode>3, lshr<mode>3,
15277         *avx_ashl<mode>3, ashl<mode>3): Set length_immediate attribute to 1
15278         iff operand 2 is const_int_operand.
15279         (*vec_dupv4si, avx_shufpd256_1, *avx_shufpd_<mode>,
15280         sse2_shufpd_<mode>): Set length_immediate attribute to 1.
15281         (sse2_pshufd_1): Likewise.  Set prefix attribute to maybe_vex
15282         instead of vex.
15283         (sse2_pshuflw_1, sse2_pshufhw_1): Set length_immediate to 1 and clear
15284         prefix_data16.
15285         (sse2_unpckhpd, sse2_unpcklpd, sse2_storehpd, *vec_concatv2df): Set
15286         prefix_data16 attribute for movlpd and movhpd instructions.
15287         (sse2_loadhpd, sse2_loadlpd, sse2_movsd): Likewise.  Override
15288         length_immediate for shufpd instruction.
15289         (sse2_movntsi, sse3_lddqu): Clear prefix_data16 attribute.
15290         (avx_cmpp<avxmodesuffixf2c><mode>3,
15291         avx_cmps<ssemodesuffixf2c><mode>3, *avx_maskcmp<mode>3,
15292         <sse>_maskcmp<mode>3, <sse>_vmmaskcmp<mode>3,
15293         avx_shufps256_1, *avx_shufps_<mode>, sse_shufps_<mode>,
15294         *vec_dupv4sf_avx, *vec_dupv4sf): Set length_immediate attribute to 1.
15295         (*avx_cvtsi2ssq, *avx_cvtsi2sdq): Set length_vex attribute to 4.
15296         (sse_cvtsi2ssq, sse2_cvtsi2sdq): Set prefix_rex attribute to 1.
15297         (sse2_cvtpi2pd, sse_loadlps, sse2_storelpd): Override
15298         prefix_data16 attribute for the first alternative to 1.
15299         (*avx_loadlps): Override length_immediate for the first alternative.
15300         (*vec_concatv2sf_avx): Override length_immediate and prefix_extra
15301         attributes for second alternative.
15302         (*vec_concatv2sf_sse4_1): Override length_immediate and
15303         prefix_data16 attributes for second alternative.
15304         (*vec_setv4sf_avx, *avx_insertps, vec_extract_lo_<mode>,
15305         vec_extract_hi_<mode>, vec_extract_lo_v16hi,
15306         vec_extract_hi_v16hi, vec_extract_lo_v32qi,
15307         vec_extract_hi_v32qi): Set prefix_extra and length_immediate to 1.
15308         (*vec_setv4sf_sse4_1, sse4_1_insertps, *sse4_1_extractps): Set
15309         prefix_data16 and length_immediate to 1.
15310         (*avx_mulv2siv2di3, *avx_mulv4si3, sse4_2_gtv2di3): Set prefix_extra
15311         to 1.
15312         (*avx_<code><mode>3, *avx_eq<mode>3, *avx_gt<mode>3): Set
15313         prefix_extra attribute for variants that don't have 0f prefix alone.
15314         (*avx_pinsr<ssevecsize>): Likewise.  Set length_immediate to 1.
15315         (*sse4_1_pinsrb, *sse2_pinsrw, *sse4_1_pinsrd, *sse4_1_pextrb,
15316         *sse4_1_pextrb_memory, *sse2_pextrw, *sse4_1_pextrw_memory,
15317         *sse4_1_pextrd): Set length_immediate to 1.
15318         (*sse4_1_pinsrd): Likewise.  Set prefix_extra to 1.
15319         (*sse4_1_pinsrq, *sse4_1_pextrq): Set prefix_rex and length_immediate
15320         to 1.
15321         (*vec_extractv2di_1_rex64_avx, *vec_extractv2di_1_rex64,
15322         *vec_extractv2di_1_avx, *vec_extractv2di_1_sse2): Override
15323         length_immediate to 1 for second alternative.
15324         (*vec_concatv2si_avx, *vec_concatv2di_rex64_avx): Override
15325         prefix_extra and length_immediate attributes for the first
15326         alternative.
15327         (vec_concatv2si_sse4_1): Override length_immediate to 1 for the
15328         first alternative.
15329         (*vec_concatv2di_rex64_sse4_1): Likewise.  Override prefix_rex
15330         to 1 for the first and third alternative.
15331         (*vec_concatv2di_rex64_sse): Override prefix_rex to 1 for the second
15332         alternative.
15333         (*sse2_maskmovdqu, *sse2_maskmovdqu_rex64): Override length_vex
15334         attribute.
15335         (*sse_sfence, sse2_mfence, sse2_lfence): Override length_address
15336         attribute to 0.
15337         (*avx_phaddwv8hi3, *avx_phadddv4si3, *avx_phaddswv8hi3,
15338         *avx_phsubwv8hi3, *avx_phsubdv4si3, *avx_phsubswv8hi,
15339         *avx_pmaddubsw128, *avx_pmulhrswv8hi3, *avx_pshufbv16qi3,
15340         *avx_psign<mode>3): Set prefix_extra attribute to 1.
15341         (ssse3_phaddwv4hi3, ssse3_phadddv2si3, ssse3_phaddswv4hi3,
15342         ssse3_phsubwv4hi3, ssse3_phsubdv2si3, ssse3_phsubswv4hi3,
15343         ssse3_pmaddubsw, *ssse3_pmulhrswv4hi, ssse3_pshufbv8qi3,
15344         ssse3_psign<mode>3): Override prefix_rex attribute.
15345         (*avx_palignrti): Override prefix_extra and length_immediate to 1.
15346         (ssse3_palignrti): Override length_immediate to 1.
15347         (ssse3_palignrdi): Override length_immediate to 1, override
15348         prefix_rex attribute.
15349         (abs<mode>2): Override prefix_rep to 0, override prefix_rex attribute.
15350         (sse4a_extrqi): Override length_immediate to 2.
15351         (sse4a_insertqi): Likewise.  Override prefix_data16 to 0.
15352         (sse4a_insertq): Override prefix_data16 to 0.
15353         (avx_blendp<avxmodesuffixf2c><avxmodesuffix>,
15354         avx_blendvp<avxmodesuffixf2c><avxmodesuffix>,
15355         avx_dpp<avxmodesuffixf2c><avxmodesuffix>, *avx_mpsadbw,
15356         *avx_pblendvb, *avx_pblendw, avx_roundp<avxmodesuffixf2c>256,
15357         avx_rounds<avxmodesuffixf2c>256): Override prefix_extra
15358         and length_immediate to 1.
15359         (sse4_1_blendp<ssemodesuffixf2c>, sse4_1_dpp<ssemodesuffixf2c>,
15360         sse4_2_pcmpestr, sse4_2_pcmpestri, sse4_2_pcmpestrm,
15361         sse4_2_pcmpestr_cconly, sse4_2_pcmpistr, sse4_2_pcmpistri,
15362         sse4_2_pcmpistrm, sse4_2_pcmpistr_cconly): Override prefix_data16
15363         and length_immediate to 1.
15364         (sse4_1_blendvp<ssemodesuffixf2c>): Override prefix_data16 to 1.
15365         (sse4_1_mpsadbw, sse4_1_pblendw): Override length_immediate to 1.
15366         (*avx_packusdw, avx_vtestp<avxmodesuffixf2c><avxmodesuffix>,
15367         avx_ptest256): Override prefix_extra to 1.
15368         (sse4_1_roundp<ssemodesuffixf2c>, sse4_1_rounds<ssemodesuffixf2c>):
15369         Override prefix_data16 and length_immediate to 1.
15370         (sse5_pperm_zero_v16qi_v8hi, sse5_pperm_sign_v16qi_v8hi,
15371         sse5_pperm_zero_v8hi_v4si, sse5_pperm_sign_v8hi_v4si,
15372         sse5_pperm_zero_v4si_v2di, sse5_pperm_sign_v4si_v2di,
15373         sse5_vrotl<mode>3, sse5_ashl<mode>3, sse5_lshl<mode>3): Override
15374         prefix_data16 to 0 and prefix_extra to 2.
15375         (sse5_rotl<mode>3, sse5_rotr<mode>3): Override length_immediate to 1.
15376         (sse5_frcz<mode>2, sse5_vmfrcz<mode>2): Don't override prefix_extra
15377         attribute.
15378         (*sse5_vmmaskcmp<mode>3, sse5_com_tf<mode>3,
15379         sse5_maskcmp<mode>3, sse5_maskcmp<mode>3, sse5_maskcmp_uns<mode>3):
15380         Override prefix_data16 and prefix_rep to 0, length_immediate to 1
15381         and prefix_extra to 2.
15382         (sse5_maskcmp_uns2<mode>3, sse5_pcom_tf<mode>3): Override
15383         prefix_data16 to 0, length_immediate to 1 and prefix_extra to 2.
15384         (*avx_aesenc, *avx_aesenclast, *avx_aesdec, *avx_aesdeclast,
15385         avx_vpermilvar<mode>3,
15386         avx_vbroadcasts<avxmodesuffixf2c><avxmodesuffix>,
15387         avx_vbroadcastss256, avx_vbroadcastf128_p<avxmodesuffixf2c>256,
15388         avx_maskloadp<avxmodesuffixf2c><avxmodesuffix>,
15389         avx_maskstorep<avxmodesuffixf2c><avxmodesuffix>):
15390         Override prefix_extra to 1.
15391         (aeskeygenassist, pclmulqdq): Override length_immediate to 1.
15392         (*vpclmulqdq, avx_vpermil<mode>, avx_vperm2f128<mode>3,
15393         vec_set_lo_<mode>, vec_set_hi_<mode>, vec_set_lo_v16hi,
15394         vec_set_hi_v16hi, vec_set_lo_v32qi, vec_set_hi_v32qi): Override
15395         prefix_extra and length_immediate to 1.
15396         (*avx_vzeroall, avx_vzeroupper, avx_vzeroupper_rex64): Override
15397         modrm to 0.
15398         (*vec_concat<mode>_avx): Override prefix_extra and length_immediate
15399         to 1 for the first alternative.
15400         * config/i386/mmx.md (*mov<mode>_internal_rex64): Override
15401         prefix_rep, prefix_data16 and/or prefix_rex attributes in certain
15402         cases.
15403         (*mov<mode>_internal_avx, *movv2sf_internal_rex64,
15404         *movv2sf_internal_avx, *movv2sf_internal): Override
15405         prefix_rep attribute for certain alternatives.
15406         (*mov<mode>_internal): Override prefix_rep or prefix_data16
15407         attributes for certain alternatives.
15408         (*movv2sf_internal_rex64_avx): Override prefix_rep and length_vex
15409         attributes for certain alternatives.
15410         (*mmx_addv2sf3, *mmx_subv2sf3, *mmx_mulv2sf3,
15411         *mmx_<code>v2sf3_finite, *mmx_<code>v2sf3, mmx_rcpv2sf2,
15412         mmx_rcpit1v2sf3, mmx_rcpit2v2sf3, mmx_rsqrtv2sf2, mmx_rsqit1v2sf3,
15413         mmx_haddv2sf3, mmx_hsubv2sf3, mmx_addsubv2sf3,
15414         *mmx_eqv2sf3, mmx_gtv2sf3, mmx_gev2sf3, mmx_pf2id, mmx_pf2iw,
15415         mmx_pi2fw, mmx_floatv2si2, mmx_pswapdv2sf2, *mmx_pmulhrwv4hi3,
15416         mmx_pswapdv2si2): Set prefix_extra attribute to 1.
15417         (mmx_ashr<mode>3, mmx_lshr<mode>3, mmx_ashl<mode>3): Set
15418         length_immediate to 1 if operand 2 is const_int_operand.
15419         (*mmx_pinsrw, mmx_pextrw, mmx_pshufw_1, *vec_dupv4hi,
15420         *vec_extractv2si_1): Set length_immediate attribute to 1.
15421         (*mmx_uavgv8qi3): Override prefix_extra attribute to 1 if
15422         using old 3DNOW insn rather than SSE/3DNOW_A.
15423         (mmx_emms, mmx_femms): Clear modrm attribute.
15424
15425 2009-05-29  Martin Jambor  <mjambor@suse.cz>
15426
15427         * tree-sra.c:  New implementation of SRA.
15428
15429         * params.def (PARAM_SRA_MAX_STRUCTURE_SIZE): Removed.
15430         (PARAM_SRA_MAX_STRUCTURE_COUNT): Removed.
15431         (PARAM_SRA_FIELD_STRUCTURE_RATIO): Removed.
15432         * params.h (SRA_MAX_STRUCTURE_SIZE): Removed.
15433         (SRA_MAX_STRUCTURE_COUNT): Removed.
15434         (SRA_FIELD_STRUCTURE_RATIO): Removed.
15435         * doc/invoke.texi (sra-max-structure-size): Removed.
15436         (sra-field-structure-ratio): Removed.
15437
15438 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
15439
15440         PR middle-end/40291
15441         * builtins.c (expand_builtin_memcmp): Convert len to sizetype
15442         before expansion.
15443
15444 2009-05-29  Andrey Belevantsev  <abel@ispras.ru>
15445
15446         PR rtl-optimization/40101
15447         * sel-sched-ir.c (get_seqno_by_preds): Allow returning negative
15448         seqno.  Adjust comment.
15449         * sel-sched.c (find_seqno_for_bookkeeping): Assert that when
15450         inserting bookkeeping before a jump, the jump is not scheduled.
15451         When no positive seqno found, provide a value.  Add comment.
15452
15453 2009-05-29  Richard Guenther  <rguenther@suse.de>
15454
15455         * tree-ssa-alias.c (nonaliasing_component_refs_p): Remove
15456         short-cutting on the first component.
15457
15458 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
15459
15460         PR middle-end/39958
15461         * omp-low.c (scan_omp_1_op): Call remap_type on TREE_TYPE
15462         for trees other than decls/types.
15463
15464 2009-05-29  Richard Guenther  <rguenther@suse.de>
15465
15466         * tree-ssa-operands.c (get_expr_operands): Do not handle
15467         INDIRECT_REFs in the handled-component case.  Remove
15468         unused get_ref_base_and_extent case.
15469         * tree-dfa.c (get_ref_base_and_extent): Avoid calling
15470         tree_low_cst and host_integerp where possible.
15471         * tree-ssa-structalias.c (equiv_class_label_eq): Check hash
15472         codes for equivalence.
15473         * dce.c (find_call_stack_args): Avoid redundant bitmap queries.
15474
15475 2009-05-29  David Billinghurst <billingd@gcc.gnu.org>
15476
15477         * config.gcc: Add i386/t-fprules-softfp and soft-fp/t-softfp
15478         to tmake_file for i[34567]86-*-cygwin*.
15479
15480 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
15481
15482         PR target/40017
15483         * config/rs6000/rs6000-c.c (_Bool_keyword): New variable.
15484         (altivec_categorize_keyword, init_vector_keywords,
15485         rs6000_cpu_cpp_builtins): Define _Bool as conditional macro
15486         similar to bool.
15487
15488 2009-05-29  Kai Tietz  <kai.tietz@onevision.com>
15489
15490         * tree.c (handle_dll_attribute): Check if node is
15491         of kind FUNCTION_DECL for DECL_DECLARED_INLINE_P check.
15492
15493 2009-05-29  Richard Earnshaw  <rearnsha@arm.com>
15494
15495         * config/arm/thumb2.md (thumb2_zero_extendsidi2): Add a split
15496         component.
15497         (thumb2_zero_extendqidi2): Likewise.
15498
15499 2009-05-28  Kaz Kojima  <kkojima@gcc.gnu.org>
15500
15501         * config/sh/sh.c (sh_expand_t_scc): Use gen_xorsi3_movrt
15502         instead of gen_movrt.
15503         * config/sh/sh.md (movrt): Remove.
15504
15505 2009-05-28  Steve Ellcey  <sje@cup.hp.com>
15506
15507         * doc/invoke.texi (IA-64 Options):
15508         Add -msdata, -mfused-madd, -mno-inline-float-divide,
15509         -mno-inline-int-divide, -mno-inline-sqrt, -msched-spec-ldc,
15510         -msched-spec-control-ldc, -msched-prefer-non-data-spec-insns,
15511         -msched-prefer-non-control-spec-insns,
15512         -msched-stop-bits-after-every-cycle,
15513         -msched-count-spec-in-critical-path,
15514         -msel-sched-dont-check-control-spec, -msched-fp-mem-deps-zero-cost
15515         -msched-max-memory-insns-hard-limit, -msched-max-memory-insns.
15516         Remove -mt, -pthread, -msched-ldc, -mno-sched-control-ldc,
15517         and -msched-spec-verbose.
15518
15519 2009-05-28  Joseph Myers  <joseph@codesourcery.com>
15520
15521         * config/arm/lib1funcs.asm (__clear_cache): Define if L_clear_cache.
15522         * config/arm/linux-eabi.h (CLEAR_INSN_CACHE): Define to give an
15523         error if used.
15524         * config/arm/t-linux-eabi (LIB1ASMFUNCS): Add _clear_cache.
15525
15526 2009-05-28  Richard Guenther  <rguenther@suse.de>
15527
15528         * tree-ssa-alias.c (ao_ref_init): New function.
15529         (ao_ref_base): Likewise.
15530         (ao_ref_base_alias_set): Likewise.
15531         (ao_ref_alias_set): Likewise.
15532         (refs_may_alias_p_1): Change signature.
15533         (refs_may_alias_p): Adjust.
15534         (refs_anti_dependent_p): Likewise.
15535         (refs_output_dependent_p): Likewise.
15536         (call_may_clobber_ref_p_1): Change signature.
15537         (call_may_clobber_ref_p): Adjust.
15538         (stmt_may_clobber_ref_p_1): New function split out from ...
15539         (stmt_may_clobber_ref_p): ... here.
15540         (maybe_skip_until): Adjust signature.
15541         (get_continuation_for_phi): Likewise.
15542         (walk_non_aliased_vuses): Likewise.
15543         * tree-ssa-alias.h (struct ao_ref_s): New structure type.
15544         (ao_ref_init): Declare.
15545         (ao_ref_base): Likewise.
15546         (ao_ref_alias_set): Likewise.
15547         (stmt_may_clobber_ref_p_1): Likewise.
15548         (walk_non_aliased_vuses): Adjust.
15549         * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): New function.
15550         (get_ref_from_reference_ops): remove.
15551         (vn_reference_lookup_2): Adjust signature.
15552         (vn_reference_lookup_3): Do not re-build trees.  Handle unions.
15553         (vn_reference_lookup_pieces): Adjust signature, do not re-build trees.
15554         (vn_reference_lookup): Adjust.
15555         (vn_reference_insert): Likewise.
15556         (vn_reference_insert_pieces): Adjust signature.
15557         (visit_reference_op_call): Adjust.
15558         * tree-ssa-pre.c (get_expr_type): Simplify.
15559         (phi_translate_1): Adjust.
15560         (compute_avail): Likewise.
15561         (translate_vuse_through_block): Do not re-build trees.
15562         (value_dies_in_block_x): Likewise.
15563         * tree-ssa-sccvn.h (struct vn_reference_s): Add type and alias-set
15564         fields.
15565         (vn_reference_lookup_pieces): Adjust declaration.
15566         (vn_reference_insert_pieces): Likewise.
15567
15568 2009-05-28  Benjamin Kosnik  <bkoz@redhat.com>
15569
15570         * tree-ssa-copy.c (replace_exp_1): Move op for warning-free use
15571         with checking disabled.
15572
15573 2009-05-28  Dave Korn  <dave.korn.cygwin@gmail.com>
15574
15575         PR target/37216
15576
15577         * configure.ac (HAVE_GAS_ALIGNED_COMM):  Add autoconf test and
15578         macro definition for support of three-operand format aligned
15579         .comm directive in assembler on cygwin/pe/mingw target OS.
15580         * configure:  Regenerate.
15581         * config.h:  Regenerate.
15582
15583         * config/i386/winnt.c (i386_pe_asm_output_aligned_decl_common):  Use
15584         aligned form of .comm directive if -mpe-aligned-commons is in effect.
15585         * config/i386/cygming.opt (-mpe-aligned-commons):  Add new option.
15586
15587         * doc/invoke.texi (-mpe-aligned-commons):  Document new target option.
15588         * doc/tm.texi (ASM_OUTPUT_COMMON):  Document zero size commons.
15589
15590 2009-05-28  Ira Rosen  <irar@il.ibm.com>
15591
15592         PR tree-optimization/40254
15593         * tree-data-ref.c (dr_analyze_innermost): Take POFFSET into account
15594         in analysis of basic blocks.
15595
15596 2009-05-28  Adam Nemet  <anemet@caviumnetworks.com>
15597
15598         PR middle-end/33699
15599         * target.h (struct gcc_target): Fix indentation.  Add const_anchor.
15600         * target-def.h (TARGET_CONST_ANCHOR): New macro.
15601         (TARGET_INITIALIZER): Use it.
15602         * cse.c (CHEAPER): Move it up to the other macros.
15603         (insert): Rename this ...
15604         (insert_with_costs): ... to this.  Add cost parameters.  Update
15605         function comment.
15606         (insert): New function.  Call insert_with_costs.
15607         (compute_const_anchors, insert_const_anchor, insert_const_anchors,
15608         find_reg_offset_for_const, try_const_anchors): New functions.
15609         (cse_insn): Call try_const_anchors.  Adjust cost of src_related
15610         when using a const-anchor.  Call insert_const_anchors.
15611         * config/mips/mips.c (mips_set_mips16_mode): Set targetm.const_anchor.
15612         * doc/tm.texi (Misc): Document TARGET_CONST_ANCHOR.
15613
15614 2009-05-28  Alexandre Oliva  <aoliva@redhat.com>
15615
15616         * tree-inline.c (remap_decls): Enable nonlocalized variables
15617         when not optimizing.
15618
15619 2009-05-28  Alexandre Oliva  <aoliva@redhat.com>
15620
15621         * tree-ssa-live.c (remove_unused_locals): Skip when not optimizing.
15622         Simplify other tests involving optimize.
15623
15624 2009-05-27  Tom Tromey  <tromey@redhat.com>
15625
15626         * unwind-dw2.c (_Unwind_DebugHook): New function.
15627         (uw_install_context): Call _Unwind_DebugHook.
15628
15629 2009-05-27  Tom Tromey  <tromey@redhat.com>
15630
15631         * system.h (CONST_CAST2): Use C++ const_cast when compiled as C++
15632
15633 2009-05-27  Ian Lance Taylor  <iant@google.com>
15634
15635         * Makefile.in (LINKER, LINKER_FLAGS): Define.
15636         (LINKER_FOR_BUILD, BUILD_LINKERFLAGS): Define.
15637         (ALL_LINKERFLAGS): Define.
15638         (xgcc$(exeext)): Change $(COMPILER) to $(LINKER).
15639         (cpp$(exeext), cc1-dummy$(exeext), cc1$(exeext)): Likewise.
15640         (collect2$(exeext), mips-tfile, mips-tdump): Likewise.
15641         (gcov$(exeext), gcov-dump$(exeext)): Likewise.
15642         (build/gen%$(build_exeext)): Change $(COMPILER_FOR_BUILD) to
15643         $(LINKER_FOR_BUILD).
15644         (build/gcov-iov$(build_exeext)): Likewise.
15645
15646 2009-05-27  Julian Brown  <julian@codesourcery.com>
15647
15648         * gcse.c (target.h): Include.
15649         (can_assign_to_reg_without_clobbers_p): Check that the target allows
15650         copy of argument to a pseudo register.
15651
15652 2009-05-27  Diego Novillo  <dnovillo@google.com>
15653
15654         * tree-ssa-live.c (dump_scope_block): Document arguments.
15655         (dump_scope_blocks): Document.
15656         (debug_scope_blocks): New.
15657         * tree-flow.h (debug_scope_blocks): Declare.
15658
15659 2009-05-21  Denis Chertykov  <denisc@overta.ru>
15660
15661         * doc/contrib.texi (Contributors): Add myself to the list.
15662
15663 2009-05-27  Olivier Hainque  <hainque@adacore.com>
15664
15665         * expr.c (target_align): New function.  Alignment the TARGET of an
15666         assignment may be assume to have.
15667         (highest_pow2_factor_for_target): Use it instead of relying on
15668         immediate tree attributes of TARGET, not necessarily honored when
15669         intermediate bitfields are involved.
15670
15671 2009-05-27  H.J. Lu  <hongjiu.lu@intel.com>
15672
15673         PR target/40266
15674         * config/i386/driver-i386.c (host_detect_local_cpu): Support
15675         AVX, SSE4, AES, PCLMUL and POPCNT.
15676
15677 2009-05-27  Diego Novillo  <dnovillo@google.com>
15678
15679         * tree-pretty-print.c (dump_location): New.
15680         (dump_generic_node): Call it.
15681         Factor code to handle BLOCK nodes ...
15682         (dump_block_node): ... here.
15683
15684 2009-05-27  Rafael Avila de Espindola  <espindola@google.com>
15685
15686         * Makefile.in (GCC_PLUGIN_H): New. Replace all uses of gcc-plugin.h
15687         with it.
15688         * doc/plugins.texi: Document that gcc-plugin.h must be the first to be
15689         included.
15690         * gcc-plugin.h: Include config.h and system.h.
15691         (IN_GCC): Define if not defined.
15692
15693 2009-05-27  Hans-Peter Nilsson  <hp@axis.com>
15694
15695         PR middle-end/40249
15696         * Makefile.in (CRTSTUFF_CFLAGS): Replace -fno-inline-functions
15697         with -fno-inline.
15698
15699 2009-05-27  Shujing Zhao  <pearly.zhao@oracle.com>
15700
15701         * config/m32r/m32r.c: Use REG_P, MEM_P and CONST_INT_P where
15702         applicable.
15703         * config/m32r/m32r.h: Ditto.
15704         * config/m32r/m32r.md: Ditto.
15705         * config/m32r/predicates.md: Ditto.
15706
15707 2009-05-27  Alexandre Oliva  <aoliva@redhat.com>
15708
15709         * cgraph.c (dump_cgraph_node): Honor -fdump-noaddr.
15710
15711 2009-05-26  Basile Starynkevitch  <basile@starynkevitch.net>
15712
15713         * doc/plugins.texi
15714         (Loading plugins): typo.
15715         (Plugin callbacks): Documented PLUGIN_INFO, PLUGIN_GGC_START,
15716         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS.
15717         (Interacting with the GCC Garbage Collector): Added new section.
15718         (Giving information about a plugin): Added new section for
15719         PLUGIN_INFO.
15720         * ggc.h (ggc_register_root_tab): Added declaration.
15721         * gcc-plugin.h (PLUGIN_GGC_START, PLUGIN_GGC_MARKING)
15722         (PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS): Added new events.
15723         (register_callback): Improved comment in declaration.
15724         * ggc-common.c (const_ggc_root_tab_t) Added new typedef for vectors.
15725         (extra_root_vec) Added static variable for dynamic roots registration.
15726         (ggc_register_root_tab) Added new routine.
15727         (ggc_mark_roots) Added iteration inside extra_root_vec, and invoke
15728         PLUGIN_GGC_MARKING event.
15729         * ggc-zone.c: Include plugin.h.
15730         (ggc_collect): Invoke PLUGIN_GGC_START & PLUGIN_GGC_END events.
15731         * ggc-page.c: Include plugin.h.
15732         (ggc_collect): Invoke PLUGIN_GGC_START & PLUGIN_GGC_END events.
15733         * plugin.c (plugin_event_name): added names of PLUGIN_GGC_START,
15734         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS
15735         (register_callback): check lack of callbacks for
15736         pseudo-events. Added handling of PLUGIN_REGISTER_GGC_ROOTS,
15737         PLUGIN_GGC_START, PLUGIN_GGC_MARKING, PLUGIN_GGC_END.
15738         (invoke_plugin_callbacks): Handle PLUGIN_GGC_START,
15739         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS.
15740         * Makefile.in (ggc-common.o, ggc-zone.o, ggc-page.o): Added
15741         dependency on plugin.h.
15742         (plugin.o): Added dependency on ggc.h...
15743
15744 2009-05-26  Richard Guenther  <rguenther@suse.de>
15745
15746         PR middle-end/40248
15747         Revert
15748         * expr.c (expand_expr_real_1): Avoid calling do_store_flag
15749         with mismatched comparison modes.
15750
15751         * expr.c (expand_expr_real_1): Expand the operand of a
15752         VIEW_CONVERT_EXPR in its natural mode.
15753
15754 2009-05-26  Ian Lance Taylor  <iant@google.com>
15755
15756         * Makefile.in (COMPILER, COMPILER_FLAGS): Define.
15757         (COMPILER_FOR_BUILD, BUILD_COMPILERFLAGS): Define.
15758         (ALL_COMPILERFLAGS): Define.
15759         (.c.o, xgcc$(exeext), cpp$(exeext)): Use $(COMPILER).
15760         (cc1-dummy$(exeext), cc1$(exeext)): Likewise.
15761         (collect2$(exeext), collect2.o): Likewise.
15762         (c-opts.o, c-cppbuiltin.o, c-pch.o, gcc.o, gccspec.o): Likewise.
15763         (gcc-options.o, version.o, prefix.o, toplev.o): Likewise.
15764         ($(out_object_file), mips-tfile, mips-tdump): Likewise.
15765         (libbackend.o, intl.o, cppdefault.o): Likewise.
15766         (gcov$(exeext), gcov-dump$(exeext)): Likewise.
15767         (build/%.o): Use $(COMPILER_FOR_BUILD).
15768         (build/gen%$(build_exeext)): Likewise.
15769         (build/gcov-iov$(build_exeext)): LIkewise.
15770         * config/t-darwin (darwin.o): Use $(COMPILER).
15771         (darwin-c.o, darwin-f.o, darwin-driver.o): Likewise.
15772         * config/t-sol2 (sol2-c.o): Likewise.
15773         (sol2.o): Likewise.
15774         * config/t-vxworks (vxworks.o): Likewise.
15775         * config/x-darwin (host-darwin.o): Likewise.
15776         * config/x-hpux (host-hpux.o): Likewise.
15777         * config/x-linux (host-linux.o): Likewise.
15778         * config/x-solaris (host-solaris.o): Likewise.
15779         * config/alpha/x-alpha (driver-alpha.o): Likewise.
15780         * config/arm/t-arm (arm-c.o): Likewise.
15781         * config/arm/t-pe (pe.o): Likewise.
15782         * config/arm/t-wince-pe (pe.o): Likewise.
15783         * config/i386/t-cygming (winnt.o): Likewise.
15784         (winnt-cxx.o, winnt-stubs.o, msformat-c.o): Likewise.
15785         * config/i386/t-cygwin (cygwin1.o): Likewise.
15786         (cygwin2.o): Likewise.
15787         * config/i386/t-i386 (i386-c.o): Likewise.
15788         * config/i386/t-interix (winnt.o): Likewise.
15789         * config/i386/t-netware (netware.o): Likewise.
15790         * config/i386/t-nwld (nwld.o): Likewise.
15791         * config/i386/x-darwin (host-i386-darwin.o): Likewise.
15792         * config/i386/x-i386 (driver-i386.o): Likewise.
15793         * config/i386/x-cygwin (host-cygwin.o): Likewise.
15794         * config/i386/x-mingw32 (host-mingw32.o): Likewise.
15795         * config/ia64/t-ia64 (ia64-c.o): Likewise.
15796         * config/m32c/t-m32c (m32c-pragma.o): Likewise.
15797         * config/mips/x-native (driver-native.o): Likewise.
15798         * config/rs6000/t-rs6000 (rs6000-c.o): Likewise.
15799         * config/rs6000/x-darwin (host-ppc-darwin.o): Likewise.
15800         * config/rs6000/x-darwin64 (host-ppc64-darwin.o): Likewise.
15801         * config/rs6000/x-rs6000 (driver-rs6000.o): Likewise.
15802         * config/score/t-score-elf (score7.o): Likewise.
15803         (score3.o): Likewise.
15804         * config/sh/t-sh (sh-c.o): Likewise.
15805         * config/sh/t-symbian (sh-c.o): Likewise.
15806         (symbian.o): Likewise.
15807         * config/spu/t-spu-elf (spu-c.o): Likewise.
15808         * config/v850/t-v850 (v850-c.o): Likewise.
15809         * config/v850/t-v850e (v850-c.o): Likewise.
15810
15811 2009-05-26  Richard Guenther  <rguenther@suse.de>
15812
15813         PR tree-optimization/40122
15814         * tree-ssa-ccp.c (ccp_fold): Fold vector CONSTRUCTORs to
15815         VECTOR_CSTs if possible.
15816         (fold_gimple_assign): Likewise.
15817
15818 2009-05-26  Richard Guenther  <rguenther@suse.de>
15819
15820         PR middle-end/40252
15821         * fold-const.c (fold_binary): Use the correct types for building
15822         rotates.
15823
15824 2009-05-26  Richard Guenther  <rguenther@suse.de>
15825
15826         * tree-vect-data-refs.c (vect_create_data_ref_ptr): Remove
15827         redundant calls to merge_alias_info.
15828         (bump_vector_ptr): Likewise.
15829         * tree-ssa-copy.c (merge_alias_info): Remove.
15830         (replace_exp_1): Remove call to merge_alias_info.
15831         (propagate_tree_value): Likewise.
15832         (fini_copy_prop): Propagate points-to info.
15833         * tree-flow.h (merge_alias_info): Remove.
15834
15835 2009-05-07  Hariharan Sandanagobalane <hariharan@picochip.com>
15836
15837         * config/picochip/picochip.C (PARAM_INLINE_CALL_COST): Remove.
15838
15839 2009-05-25  Jan Hubicka  <jh@suse.cz>
15840
15841         * cgraph.c (dump_cgraph_node): Dump size/time/benefit.
15842         * cgraph.h (struct inline_summary): New filed self_wize,
15843         size_inlining_benefit, self_time and time_inlining_benefit.
15844         (struct cgraph_global_info): Replace insns by time ans size fields.
15845         * ipa-cp (ipcp_cloning_candidate_p): Base estimate on size
15846         (ipcp_estimate_growth, ipcp_insert_stage): Likewise.
15847         (ipcp_update_callgraph): Do not touch function bodies.
15848         * ipa-inline.c: Include except.h
15849         (MAX_TIME): New constant.
15850         (overall_insns): Remove.
15851         (leaf_node_p): New.
15852         (overall_size, max_benefit): New static variables.
15853         (cgraph_estimate_time_after_inlining): New function.
15854         (cgraph_estimate_size_after_inlining): Rewrite using benefits.
15855         (cgraph_clone_inlined_nodes): Update size.
15856         (cgraph_mark_inline_edge): Update size.
15857         (cgraph_estimate_growth): Use size info.
15858         (cgraph_check_inline_limits): Check size.
15859         (cgraph_default_inline_p): Likewise.
15860         (cgraph_edge_badness): Compute badness based on benefit and size cost.
15861         (cgraph_decide_recursive_inlining): Check size.
15862         (cgraph_decide_inlining_of_small_function): Update size; dump sizes
15863         and times.
15864         (cgraph_decide_inlining): Likewise.
15865         (cgraph_decide_inlining_incrementally): Likewise; honor
15866         PARAM_EARLY_INLINING_INSNS.
15867         (likely_eliminated_by_inlining_p): New predicate.
15868         (estimate_function_body_sizes): New function.
15869         (compute_inline_parameters): Use it.
15870         * except.c (must_not_throw_labels): New function.
15871         * except.h (must_not_throw_labels): Declare.
15872         * tree-inline.c (init_inline_once): Kill inlining_weigths
15873         * tree-ssa-structalias.c: Avoid uninitialized warning.
15874         * params.def (PARAM_MAX_INLINE_INSNS_SINGLE): Reduce to 300.
15875         (PARAM_MAX_INLINE_INSNS_AUTO): Reduce to 60.
15876         (PARAM_INLINE_CALL_COST): Remove.
15877         (PARAM_EARLY_INLINING_INSNS): New.
15878
15879 2009-05-25  Richard Guenther  <rguenther@suse.de>
15880
15881         PR tree-optimization/36327
15882         * tree-ssa-alias.c (walk_non_aliased_vuses): Add second walker
15883         callback for reference translation or lookup at the point of may-defs.
15884         * tree-ssa-alias.h (walk_non_aliased_vuses): Adjust prototype.
15885         * tree-ssa-sccvn.c (get_ref_from_reference_ops): Bail out
15886         for union COMPONENT_REFs.
15887         (vn_reference_lookup_3): New callback.  Lookup from memset
15888         and CONSTRUCTOR assignment, translate through struct copies.
15889         (vn_reference_lookup_pieces): Make sure to not free the
15890         passed operands array.  Adjust walk_non_aliased_vuses call.
15891         (vn_reference_lookup): Adjust walk_non_aliased_vuses call,
15892         make sure we do not leak memory.
15893
15894 2009-05-25  Richard Guenther  <rguenther@suse.de>
15895
15896         * tree-ssa-alias.h (dump_points_to_solution): Declare.
15897         * tree-inline.c (expand_call_inline): Reset the escaped and
15898         callused solutions.
15899         * tree-ssa-structalias.c (pass_build_ealias): New.
15900         * tree-pass.h (pass_build_ealias): Declare.
15901         * passes.c (init_optimization_passes): Add PTA during
15902         early optimizations.
15903         * tree-ssa-alias.c (dump_alias_info): Dump the ESCAPED
15904         and CALLUSED solutions.
15905         (dump_points_to_solution): New function, split out from ...
15906         (dump_points_to_info_for): ... here.
15907         * tree-parloops.c (parallelize_loops): Reset the escaped and
15908         callused solutions.
15909
15910 2009-05-25  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
15911
15912         PR bootstrap/40027
15913         * config/i386/i386.c (USE_HIDDEN_LINKONCE): Only define if missing.
15914         * config/i386/sol2.h [!TARGET_GNU_LD] (USE_HIDDEN_LINKONCE): Define.
15915
15916 2009-05-25  Ira Rosen  <irar@il.ibm.com>
15917
15918         PR tree-optimization/40238
15919         * tree-vect-stmts.c (vect_init_vector): Insert initialization
15920         statements after basic block's labels.
15921         * tree-vect-slp.c (vect_slp_transform_bb): Call destroy_bb_vec_info()
15922         to free the allocated memory.
15923
15924 2009-05-24  Kaz Kojima  <kkojima@gcc.gnu.org>
15925
15926         * gcc/config/sh/sh.c (sh_set_return_address): Mark store of
15927         return address with a USE.
15928
15929 2009-05-24  Richard Guenther  <rguenther@suse.de>
15930
15931         PR middle-end/40233
15932         * tree.c (make_vector_type): Build the TYPE_DEBUG_REPRESENTATION_TYPEs
15933         array type from the main variant of the inner type.
15934
15935 2009-05-24  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
15936
15937         * config/vax/vax-protos.h (legitimate_constant_address_p): Change
15938         definition to bool (from int) to un-break build.
15939         (legitimate_constant_p, vax_mode_dependent_address_p): Likewise.
15940
15941 2009-05-24  Paolo Bonzini  <bonzini@gnu.org>
15942
15943         * tree-ssa-operands.h (push_stmt_changes, pop_stmt_changes,
15944         discard_stmt_changes): Delete.
15945         * tree-ssa-operands.c (scb_stack): Delete.
15946         (init_ssa_operands): Do not initialize it.
15947         (fini_ssa_operands): Do not free it.
15948         (push_stmt_changes, pop_stmt_changes, discard_stmt_changes): Delete.
15949
15950         * tree-cfg.c (replace_uses_by): Replace pop_stmt_changes with
15951         update_stmt, remove the others.  Fix comments.
15952         * tree-dfa.c (optimize_stack_restore): Likewise.
15953         * tree-ssa-forwprop.c (forward_propagate_addr_expr): Likewise.
15954         * tree-ssa-loop-ivopts.c (rewrite_use): Likewise.
15955         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Likewise.
15956         * tree-ssa-ccp.c (optimize_stack_restore, execute_fold_all_builtins):
15957         Likewise.
15958         * tree-ssa-propagate.c (substitute_and_fold): Likewise.
15959         * tree-ssa-dom.c (propagate_rhs_into_lhs): Likewise.
15960         (dom_opt_finalize_block): Likewise, adjusting access to
15961         stmts_to_rescan.
15962         (optimize_stmt): Likewise, adjusting access to stmts_to_rescan.
15963         (stmts_to_rescan): Change item type to gimple.
15964         (tree_ssa_dominator_optimize): Change type of stmts_to_rescan.
15965
15966 2009-05-24  Ira Rosen  <irar@il.ibm.com>
15967
15968         * doc/passes.texi (Tree-SSA passes): Document SLP pass.
15969         * tree-pass.h (pass_slp_vectorize): New pass.
15970         * params.h (SLP_MAX_INSNS_IN_BB): Define.
15971         * timevar.def (TV_TREE_SLP_VECTORIZATION): Define.
15972         * tree-vectorizer.c (timevar.h): Include.
15973         (user_vect_verbosity_level): Declare.
15974         (vect_location): Fix comment.
15975         (vect_set_verbosity_level): Update user_vect_verbosity_level
15976         instead of vect_verbosity_level.
15977         (vect_set_dump_settings): Add an argument. Ignore user defined
15978         verbosity if dump flags require higher level of verbosity. Print to
15979         stderr only for loop vectorization.
15980         (vectorize_loops): Update call to vect_set_dump_settings.
15981         (execute_vect_slp): New function.
15982         (gate_vect_slp): Likewise.
15983         (struct gimple_opt_pass pass_slp_vectorize): New.
15984         * tree-vectorizer.h (struct _bb_vec_info): Define along macros to
15985         access its members.
15986         (vec_info_for_bb): New function.
15987         (struct _stmt_vec_info): Add bb_vinfo and a macro for its access.
15988         (VECTORIZATION_ENABLED): New macro.
15989         (SLP_ENABLED, SLP_DISABLED): Likewise.
15990         (vect_is_simple_use): Add bb_vec_info argument.
15991         (new_stmt_vec_info, vect_analyze_data_ref_dependences,
15992         vect_analyze_data_refs_alignment, vect_verify_datarefs_alignment,
15993         vect_analyze_data_ref_accesses, vect_analyze_data_refs,
15994         vect_schedule_slp, vect_analyze_slp): Likewise.
15995         (vect_analyze_stmt): Add slp_tree argument.
15996         (find_bb_location): Declare.
15997         (vect_slp_analyze_bb, vect_slp_transform_bb): Likewise.
15998         * tree-vect-loop.c (new_loop_vec_info): Adjust function calls.
15999         (vect_analyze_loop_operations, vect_analyze_loop,
16000         get_initial_def_for_induction, vect_create_epilog_for_reduction,
16001         vect_finalize_reduction, vectorizable_reduction,
16002         vectorizable_live_operation, vect_transform_loop): Likewise.
16003         * tree-data-ref.c (dr_analyze_innermost): Update comment,
16004         skip evolution analysis if analyzing a basic block.
16005         (dr_analyze_indices): Likewise.
16006         (initialize_data_dependence_relation): Skip the test whether the
16007         object is invariant for basic blocks.
16008         (compute_all_dependences): Skip dependence analysis for data
16009         references in basic blocks.
16010         (find_data_references_in_stmt): Don't fail in case of invariant
16011         access in basic block.
16012         (find_data_references_in_bb): New function.
16013         (find_data_references_in_loop): Move code to
16014         find_data_references_in_bb and add a call to it.
16015         (compute_data_dependences_for_bb): New function.
16016         * tree-data-ref.h (compute_data_dependences_for_bb): Declare.
16017         * tree-vect-data-refs.c (vect_check_interleaving): Adjust to the case
16018         that STEP is 0.
16019         (vect_analyze_data_ref_dependence): Check for interleaving in case of
16020         unknown dependence in basic block and fail in case of dependence in
16021         basic block.
16022         (vect_analyze_data_ref_dependences): Add bb_vinfo argument, get data
16023         dependence instances from either loop or basic block vectorization
16024         info.
16025         (vect_compute_data_ref_alignment): Check if it is loop vectorization
16026         before calling nested_in_vect_loop_p.
16027         (vect_compute_data_refs_alignment): Add bb_vinfo argument, get data
16028         dependence instances from either loop or basic block vectorization
16029         info.
16030         (vect_verify_datarefs_alignment): Likewise.
16031         (vect_enhance_data_refs_alignment): Adjust function calls.
16032         (vect_analyze_data_refs_alignment): Likewise.
16033         (vect_analyze_group_access): Fix printing. Skip different checks if
16034         DR_STEP is 0. Keep strided stores either in loop or basic block
16035         vectorization data structure. Fix indentation.
16036         (vect_analyze_data_ref_access): Fix comments, allow zero step in
16037         basic blocks.
16038         (vect_analyze_data_ref_accesses): Add bb_vinfo argument, get data
16039         dependence instances from either loop or basic block vectorization
16040         info.
16041         (vect_analyze_data_refs): Update comment. Call
16042         compute_data_dependences_for_bb to analyze basic blocks.
16043         (vect_create_addr_base_for_vector_ref): Check for outer loop only in
16044         case of loop vectorization. In case of basic block vectorization use
16045         data-ref itself as a base.
16046         (vect_create_data_ref_ptr): In case of basic block vectorization:
16047         don't advance the pointer, add new statements before the current
16048         statement.  Adjust function calls.
16049         (vect_supportable_dr_alignment): Support only aligned accesses in
16050         basic block vectorization.
16051         * common.opt (ftree-slp-vectorize): New flag.
16052         * tree-vect-patterns.c (widened_name_p): Adjust function calls.
16053         (vect_pattern_recog_1): Likewise.
16054         * tree-vect-stmts.c (process_use): Likewise.
16055         (vect_init_vector): Add new statements in the beginning of the basic
16056         block in case of basic block SLP.
16057         (vect_get_vec_def_for_operand): Adjust function calls.
16058         (vect_finish_stmt_generation): Likewise.
16059         (vectorizable_call): Add assert that it is loop vectorization, adjust
16060         function calls.
16061         (vectorizable_conversion, vectorizable_assignment): Likewise.
16062         (vectorizable_operation): In case of basic block SLP, take
16063         vectorization factor from statement's type and skip the relevance
16064         check. Adjust function calls.
16065         (vectorizable_type_demotion): Add assert that it is loop
16066         vectorization, adjust function calls.
16067         (vectorizable_type_promotion): Likewise.
16068         (vectorizable_store): Check for outer loop only in case of loop
16069         vectorization. Adjust function calls. For basic blocks, skip the
16070         relevance check and don't advance pointers.
16071         (vectorizable_load): Likewise.
16072         (vectorizable_condition): Add assert that it is loop vectorization,
16073         adjust function calls.
16074         (vect_analyze_stmt): Add argument. In case of basic block SLP, check
16075         that it is not reduction, get vector type, call only supported
16076         functions, skip loop specific parts.
16077         (vect_transform_stmt): Check for outer loop only in case of loop
16078         vectorization.
16079         (new_stmt_vec_info): Add new argument and initialize bb_vinfo.
16080         (vect_is_simple_use): Fix comment, add new argument, fix conditions
16081         for external definition.
16082         * passes.c (pass_slp_vectorize): New pass.
16083         * tree-vect-slp.c (find_bb_location): New function.
16084         (vect_get_and_check_slp_defs): Add argument, adjust function calls,
16085         check for patterns only in loops.
16086         (vect_build_slp_tree): Add argument, adjust function calls, fail in
16087         case of multiple types in basic block SLP.
16088         (vect_mark_slp_stmts_relevant): New function.
16089         (vect_supported_load_permutation_p): Fix comment.
16090         (vect_analyze_slp_instance): Add argument. In case of basic block
16091         SLP, take vectorization factor from statement's type, check that
16092         unrolling factor is 1. Adjust function call. Save SLP instance in
16093         either loop or basic block vectorization structure. Return FALSE,
16094         if SLP failed.
16095         (vect_analyze_slp): Add argument. Get strided stores groups from
16096         either loop or basic block vectorization structure. Return FALSE
16097         if basic block SLP failed.
16098         (new_bb_vec_info): New function.
16099         (destroy_bb_vec_info, vect_slp_analyze_node_operations,
16100         vect_slp_analyze_operations, vect_slp_analyze_bb): Likewise.
16101         (vect_schedule_slp): Add argument. Get SLP instances from either
16102         loop or basic block vectorization structure. Set vectorization factor
16103         to be 1 for basic block SLP.
16104         (vect_slp_transform_bb): New function.
16105         * params.def (PARAM_SLP_MAX_INSNS_IN_BB): Define.
16106
16107 2009-05-23  Mark Mitchell  <mark@codesourcery.com>
16108
16109         * final.c (shorten_branches): Do not align labels for jump tables.
16110         (final_scan_insn): Use JUMP_TABLE_DATA_P.
16111
16112 2009-05-23  Eric Botcazou  <ebotcazou@adacore.com>
16113
16114         * doc/passes.texi: Standardize spelling of RTL, Tree and Tree SSA.
16115         Remove outdated reference to flow.c and fix nits.
16116         * doc/gccint.texi: Tweak RTL description.
16117         * doc/rtl.texi: Likewise.
16118
16119 2009-05-23  Denis Chertykov  <chertykov@gmail.com>
16120
16121         * config/avr/avr.c: Change my email address.
16122         * config/avr/avr.h: Likewise.
16123         * config/avr/avr.md: Likewise.
16124         * config/avr/avr-protos.h: Likewise.
16125         * config/avr/libgcc.S: Likewise.
16126
16127 2009-05-22  Trevor Smigiel <Trevor_Smigiel@playstation.sony.com>
16128
16129         * config/spu/spu-protos.h (aligned_mem_p, spu_valid_mov): Remove.
16130         (spu_split_load, spu_split_store): Change return type to int.
16131         (spu_split_convert): Declare.
16132         * config/spu/predicates.md (spu_mem_operand): Remove.
16133         (spu_mov_operand): Update.
16134         (spu_dest_operand, shiftrt_operator, extend_operator): Define.
16135         * config/spu/spu.c (regno_aligned_for_load): Remove.
16136         (reg_aligned_for_addr, spu_expand_load): Define.
16137         (spu_expand_extv): Reimplement and handle MEM.
16138         (spu_expand_insv): Handle MEM.
16139         (spu_sched_reorder): Handle insn's with length 0.
16140         (spu_legitimate_address_p): Reimplement.
16141         (store_with_one_insn_p): Return TRUE for any mode with size
16142         larger than 16 bytes.
16143         (address_needs_split): Define.
16144         (spu_expand_mov): Call spu_split_load and spu_split_store for MEM
16145         operands.
16146         (spu_convert_move): Define.
16147         (spu_split_load): Use spu_expand_load and change all MEM's to TImode.
16148         (spu_split_store): Change all MEM's to TImode.
16149         (spu_init_expanders): Preallocate registers that correspond to
16150         LAST_VIRTUAL_REG+1 and LAST_VIRTUAL_REG+2 and set them with
16151         mark_reg_pointer.
16152         (spu_split_convert): Define.
16153         * config/spu/spu.md (QHSI, QHSDI): New mode iterators.
16154         (_move<mode>, _movdi, _movti): Update predicate and condition.
16155         (load, store): Change to define_split.
16156         (extendqiti2, extendhiti2, extendsiti2, extendditi2): Simplify to
16157         extend<mode>ti2.
16158         (zero_extendqiti2, zero_extendhiti2, <v>lshr<mode>3_imm): Define.
16159         (lshr<mode>3, lshr<mode>3_imm, lshr<mode>3_re): Simplify to one
16160         define_insn_and_split of lshr<mode>3.
16161         (shrqbybi_<mode>, shrqby_<mode>): Simplify to define_expand.
16162         (<v>ashr<mode>3_imm): Define.
16163         (extv, extzv, insv): Allow MEM operands.
16164         (trunc_shr_ti<mode>, trunc_shr_tidi, shl_ext_<mode>ti,
16165         shl_ext_diti, sext_trunc_lshr_tiqisi, zext_trunc_lshr_tiqisi,
16166         sext_trunc_lshr_tihisi, zext_trunc_lshr_tihisi): Define for combine.
16167         (_spu_convert2): Change to define_insn_and_split and remove the
16168         corresponding define_peephole2.
16169         (stack_protect_set, stack_protect_test, stack_protect_test_si):
16170         Change predicates to memory_operand.
16171
16172 2009-05-22  Mark Mitchell  <mark@codesourcery.com>
16173
16174         * config/arm/thumb2.md: Add 16-bit multiply instructions.
16175
16176 2009-05-21  Michael Meissner  <meissner@linux.vnet.ibm.com>
16177
16178         PR tree-optimization/40219
16179         * tree.c (iterative_hash_expr): Make sure the builtin function is
16180         a normal builtin function and not a front end or back end builtin
16181         before indexing into the built_in_decls array.
16182
16183 2009-05-22  Richard Guenther  <rguenther@suse.de>
16184
16185         PR middle-end/38964
16186         * alias.c (write_dependence_p): Do not use TBAA for answering
16187         anti-dependence or output-dependence.
16188         * tree-ssa-structalias.c (set_uids_in_ptset): Remove TBAA pruning code.
16189         (emit_pointer_definition): Remove.
16190         (emit_alias_warning): Likewise.
16191         (find_what_var_points_to): Remove TBAA pruning code.
16192         (find_what_p_points_to): Likewise.  Do not warn about strict-aliasing
16193         violations.
16194         (compute_points_to_sets): Remove code computing the set of
16195         dereferenced pointers.
16196         * tree-data-ref.c (dr_may_alias_p): Properly use the split
16197         oracle for querying anti and output dependencies.
16198         * tree-ssa-alias.c (refs_may_alias_p_1): Add argument specifying
16199         if TBAA may be applied.
16200         (refs_anti_dependent_p): New function.
16201         (refs_output_dependent_p): Likewise.
16202         * tree-ssa-alias.h (refs_anti_dependent_p): Declare.
16203         (refs_output_dependent_p): Likewise.
16204         * doc/tree-ssa.texi (Memory model): New section.
16205         * doc/c-tree.texi (CHANGE_DYNAMIC_TYPE_EXPR): Remove.
16206         * doc/gimple.texi (GIMPLE_CHANGE_DYNAMIC_TYPE): Remove.
16207         * cfgexpand.c (expand_gimple_basic_block): Do not handle
16208         GIMPLE_CHANGE_DYNAMIC_TYPE or CHANGE_DYNAMIC_TYPE_EXPR.
16209         * expr.c (expand_expr_real_1): Likewise.
16210         * gimple-low.c (lower_stmt): Likewise.
16211         * gimple-pretty-print.c (dump_gimple_stmt): Likewise.
16212         (dump_gimple_cdt): Remove.
16213         * gimple.c (gss_for_code): Do not handle GIMPLE_CHANGE_DYNAMIC_TYPE.
16214         (gimple_size): Likewise.
16215         (walk_gimple_op): Likewise.
16216         (is_gimple_stmt): Likewise.
16217         (walk_stmt_load_store_addr_ops): Likewise.
16218         (gimple_build_cdt): Remove.
16219         * gimple.def (GIMPLE_CHANGE_DYNAMIC_TYPE): Remove.
16220         * gimple.h (gimple_cdt_new_type): Remove.
16221         (gimple_cdt_new_type_ptr): Likewise.
16222         (gimple_cdt_set_new_type): Likewise.
16223         (gimple_cdt_location): Likewise.
16224         (gimple_cdt_location_ptr): Likewise.
16225         (gimple_cdt_set_location): Likewise.
16226         * gimplify.c (gimplify_expr): Do not handle CHANGE_DYNAMIC_TYPE_EXPR.
16227         * tree-cfg.c (remove_useless_stmts_1): Do not handle
16228         GIMPLE_CHANGE_DYNAMIC_TYPE.
16229         (verify_types_in_gimple_stmt): Likewise.
16230         * tree-inline.c (estimate_num_insns): Likewise.
16231         (expand_call_inline): Do not copy DECL_NO_TBAA_P.
16232         (copy_decl_to_var): Likewise.
16233         (copy_result_decl_to_var): Likewise.
16234         * tree-pretty-print.c (dump_generic_node): Do not handle
16235         CHANGE_DYNAMIC_TYPE_EXPR.
16236         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
16237         * tree-ssa-operands.c (get_expr_operands): Likewise.
16238         * tree-ssa-structalias.c (struct variable_info): Remove
16239         no_tbaa_pruning member.
16240         (new_var_info): Do not set it based on DECL_NO_TBAA_P.
16241         (unify_nodes): Do not copy it.
16242         (find_func_aliases): Do not handle GIMPLE_CHANGE_DYNAMIC_TYPE.
16243         (dump_solution_for_var): Do not dump no_tbaa_pruning state.
16244         (set_uids_in_ptset): Do not check it.
16245         (find_what_var_points_to): Likewise.
16246         (compute_tbaa_pruning): Remove.
16247         (compute_points_to_sets): Do not call it.
16248         * tree.c (walk_tree_1): Do not handle CHANGE_DYNAMIC_TYPE_EXPR.
16249         * tree.def (CHANGE_DYNAMIC_TYPE_EXPR): Remove.
16250         * tree.h (CHANGE_DYNAMIC_TYPE_NEW_TYPE): Remove.
16251         (CHANGE_DYNAMIC_TYPE_LOCATION): Likewise.
16252         (DECL_NO_TBAA_P): Likewise.
16253         (struct tree_decl_common): Move no_tbaa_flag to unused flags section.
16254         * omp-low.c (copy_var_decl): Do not copy DECL_NO_TBAA_P.
16255         (expand_omp_atomic_pipeline): Do not set it.
16256         * print-tree.c (print_node): Do not dump it.
16257         * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Remove
16258         redundant check.
16259
16260 2009-05-22 Vladimir Makarov <vmakarov@redhat.com>
16261
16262         PR target/39856
16263         * reg-stack.c (subst_stack_regs_pat): Remove gcc_assert for note
16264         for clobber.
16265
16266 2009-05-22  Mark Mitchell  <mark@codesourcery.com>
16267
16268         * tree.c (handle_dll_attribute): Mark dllexport'd inlines as
16269         non-external.
16270
16271 2009-05-22  Ben Elliston  <bje@au.ibm.com>
16272
16273         * Makefile.in (bversion.h, s-bversion): New targets.
16274         (TOPLEV_H): Add bversion.h.
16275         * toplev.h: Include "bversion.h".
16276         (ATTRIBUTE_GCC_DIAG): When building with checking disabled, use
16277         the __format__ attribute only if compiling with the same version
16278         of GCC as the sources (the "build version").
16279
16280 2009-05-22  Ben Elliston  <bje@au.ibm.com>
16281
16282         * c-format.c (handle_format_attribute): Fix comment typo.
16283
16284 2009-05-21  Steve Ellcey  <sje@cup.hp.com>
16285
16286         PR target/37846
16287         * config/ia64/ia64.opt (mfused-madd): New.
16288         * config/ia64/ia64.h (TARGET_DEFAULT): Set MASK_FUSED_MADD.
16289         * config/ia64/hpux.h (TARGET_DEFAULT): Ditto.
16290         * config/ia64/ia64.md (maddsf4, msubsf4, nmaddsf4,
16291         madddf4, madddf4_trunc, msubdf4, msubdf4_trunc, nmadddf4,
16292         nmadddf4_truncsf, maddxf4, maddxf4_truncsf, maddxf4_truncdf,
16293         msubxf4, msubxf4_truncsf msubxf4_truncdf, nmaddxf4,
16294         nmaddxf4_truncsf, nmaddxf4_truncdf): Check TARGET_FUSED_MADD.
16295         * config/ia64/vect.md (addv2sf3, subv2sf3): Force fpma/fpms
16296         instruction if !TARGET_FUSED_MADD.
16297         (fpma, fpms): Remove colon from name.
16298
16299 2009-05-22  Richard Guenther  <rguenther@suse.de>
16300
16301         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Record
16302         TMR_ORIGINAL.  Always either record TMR_SYMBOL or TMR_BASE.
16303         * tree-ssa-pre.c (create_component_ref_by_pieces_1): Handle
16304         TARGET_MEM_REF.
16305         (create_expression_by_pieces): Only convert if necessary.
16306         * gimplify.c (gimplify_expr): Handle TARGET_MEM_REF.
16307         * tree-ssa-loop-im.c (gen_lsm_tmp_name): Handle INTEGER_CST.
16308
16309 2009-05-21  Adam Nemet  <anemet@caviumnetworks.com>
16310
16311         * config/mips/mips.md (*extzv_trunc<mode>_exts): Turn into a
16312         regular pattern from a template and rename it ...
16313         (*extzv_truncsi_exts): ... to this.
16314
16315 2009-05-21  Richard Guenther  <rguenther@suse.de>
16316
16317         * cgraph.h (struct cgraph_node): Remove inline_decl member.
16318         * ipa-inline.c (cgraph_mark_inline_edge): Do not check it.
16319         (cgraph_default_inline_p): Likewise.
16320         (cgraph_decide_inlining_incrementally): Likewise.
16321
16322 2009-05-21  H.J. Lu  <hongjiu.lu@intel.com>
16323             Uros Bizjak  <ubizjak@gmail.com>
16324
16325         * config/i386/cpuid.h (bit_MOVBE): New.
16326
16327         * config/i386/driver-i386.c (host_detect_local_cpu): Check movbe.
16328
16329         * config/i386/i386.c (OPTION_MASK_ISA_MOVBE_SET): New.
16330         (OPTION_MASK_ISA_MOVBE_UNSET): Likewise.
16331         (ix86_handle_option): Handle OPT_mmovbe.
16332         (ix86_target_string): Add -mmovbe.
16333         (pta_flags): Add PTA_MOVBE.
16334         (processor_alias_table): Add PTA_MOVBE to "atom".
16335         (override_options): Handle PTA_MOVBE.
16336
16337         * config/i386/i386.h (TARGET_MOVBE): New.
16338
16339         * config/i386/i386.md (bswapsi2): Check TARGET_MOVBE.
16340         (*bswapsi_movbe): New.
16341         (*bswapdi_movbe): Likewise.
16342         (bswapdi2): Renamed to ...
16343         (*bswapdi_1): This.
16344         (bswapdi2): New expander.
16345
16346         * config/i386/i386.opt (mmovbe): New.
16347
16348         * doc/invoke.texi: Document -mmovbe.
16349
16350 2009-05-21  Taras Glek  <tglek@mozilla.com>
16351
16352         * plugin.c (try_init_one_plugin): Updated to new plugin_init API.
16353         * gcc-plugin.h (plugin_init): Updated signature.
16354         * gcc-plugin.h (plugin_name_args): Moved to this header.
16355         * doc/plugins.texi (plugin_init): Updated documention to reflect
16356         API change.
16357         * doc/plugins.texi (plugin_name_args): Added to documention.
16358
16359 2009-05-21  Mark Mitchell  <mark@codesourcery.com>
16360
16361         * config/arm/neon.md (*mul<mode>3add<mode>_neon): New pattern.
16362         (*mul<mode>3neg<mode>add<mode>_neon): Likewise.
16363
16364 2009-05-21  Shujing Zhao  <pearly.zhao@oracle.com>
16365
16366         * config/i386/i386.c: Use REG_P, MEM_P, CONST_INT_P, LABEL_P and
16367         JUMP_TABLE_DATA_P predicates where applicable.
16368         * config/i386/predicates.md: Ditto.
16369         * config/i386/sse.md: Ditto.
16370
16371 2009-05-21  Jakub Jelinek  <jakub@redhat.com>
16372
16373         * config/i386/i386.md (adddi_4_rex64, addsi_4, addhi_4): For
16374         operand2 -128 override length_immediate attribute to 1.
16375         * config/i386/predicates.md (constm128_operand): New predicate.
16376
16377         * config/i386/i386.c (memory_address_length): Handle %r12
16378         the same as %rsp and %r13 the same as %rbp.  For %rsp and %rbp
16379         also check REGNO.
16380         (ix86_attr_length_address_default): For MODE_SI lea in 64-bit
16381         mode look through optional ZERO_EXTEND and SUBREG.
16382         * config/i386/i386.md (R12_REG): New define_constant.
16383         (prefix_data16): For sse unit set also for MODE_TI insns.
16384         (prefix_rex): For -m32 always return 0.  For TYPE_IMOVX
16385         insns set if operand 1 is ext_QIreg_operand.
16386         (modrm): For TYPE_IMOV clear only if not MODE_DI.  For
16387         TYPE_{ALU{,1},ICMP,TEST} insn clear if there is non-shortened
16388         immediate.
16389         (*movdi_extzv_1, zero_extendhidi2, zero_extendqidi2): Change
16390         mode from MODE_DI to MODE_SI.
16391         (movdi_1_rex64): Override modrm and length_immediate attributes
16392         only for movabs (TYPE_IMOV, alternative 2).
16393         (zero_extendsidi2_rex64): Clear prefix_0f attribute if TYPE_IMOVX.
16394         (*float<SSEMODEI24:mode><MODEF:mode>2_mixed_interunit,
16395         *float<SSEMODEI24:mode><MODEF:mode>2_mixed_nointerunit,
16396         *float<SSEMODEI24:mode><MODEF:mode>2_sse_interunit,
16397         *float<SSEMODEI24:mode><MODEF:mode>2_sse_nointerunit): Set
16398         prefix_rex attribute if DImode.
16399         (*adddi_1_rex64, *adddi_2_rex64, *adddi_3_rex64, *adddi_5_rex64,
16400         *addsi_1, *addsi_1_zext, *addsi_2, *addsi_2_zext, *addsi_3,
16401         *addsi_3_zext, *addsi_5, *addhi_1_lea, *addhi_1, *addhi_2, *addhi_3,
16402         *addhi_5, *addqi_1_lea, *addqi_1): Override length_immediate
16403         attribute to 1 if TYPE_ALU and operand 2 is const128_operand.
16404         (pro_epilogue_adjust_stack_1, pro_epilogue_adjust_stack_rex64):
16405         Likewise.  For TYPE_IMOV clear length_immediate attribute.
16406         (*ashldi3_1_rex64, *ashldi3_cmp_rex64, *ashldi3_cconly_rex64,
16407         *ashlsi3_1, *ashlsi3_1_zext, *ashlsi3_cmp, **ashlsi3_cconly,
16408         *ashlsi3_cmp_zext, *ashlhi3_1_lea, *ashlhi3_1, *ashlhi3_cmp,
16409         *ashlhi3_cconly, *ashlqi3_1_lea, *ashlqi3_1, *ashlqi3_cmp,
16410         *ashlqi3_cconly): Override length_immediate attribute to 0 if TYPE_ALU
16411         or one operand TYPE_ISHIFT.
16412         (*ashrdi3_1_one_bit_rex64, *ashrdi3_one_bit_cmp_rex64,
16413         *ashrdi3_one_bit_cconly_rex64, *ashrsi3_1_one_bit,
16414         *ashrsi3_1_one_bit_zext, *ashrsi3_one_bit_cmp,
16415         *ashrsi3_one_bit_cconly, *ashrsi3_one_bit_cmp_zext,
16416         *ashrhi3_1_one_bit, *ashrhi3_one_bit_cmp, *ashrhi3_one_bit_cconly,
16417         *ashrqi3_1_one_bit, *ashrqi3_1_one_bit_slp, *ashrqi3_one_bit_cmp,
16418         *ashrqi3_one_bit_cconly, *lshrdi3_1_one_bit_rex64,
16419         *lshrdi3_cmp_one_bit_rex64, *lshrdi3_cconly_one_bit_rex64,
16420         *lshrsi3_1_one_bit, *lshrsi3_1_one_bit_zext, *lshrsi3_one_bit_cmp,
16421         *lshrsi3_one_bit_cconly, *lshrsi3_cmp_one_bit_zext,
16422         *lshrhi3_1_one_bit, *lshrhi3_one_bit_cmp, *lshrhi3_one_bit_cconly,
16423         *lshrqi3_1_one_bit, *lshrqi3_1_one_bit_slp, *lshrqi2_one_bit_cmp,
16424         *lshrqi2_one_bit_cconly, *rotlsi3_1_one_bit_rex64, *rotlsi3_1_one_bit,
16425         *rotlsi3_1_one_bit_zext, *rotlhi3_1_one_bit, *rotlqi3_1_one_bit_slp,
16426         *rotlqi3_1_one_bit, *rotrdi3_1_one_bit_rex64, *rotrsi3_1_one_bit,
16427         *rotrsi3_1_one_bit_zext, *rotrhi3_one_bit, *rotrqi3_1_one_bit,
16428         *rotrqi3_1_one_bit_slp): Override length_immediate attribute to 0,
16429         set mode attribute, don't override length attribute.
16430         (*btsq, *btrq, *btcq, *btdi_rex64, *btsi): Set prefix_0f attribute
16431         to 1.
16432         (return_internal_long): Set length attribute to 2 instead of 1.
16433         (*strmovqi_rex_1, *strsetqi_rex_1, *rep_stosqi_rex64,
16434         *cmpstrnqi_nz_rex_1, *cmpstrnqi_rex_1, *strlenqi_rex_1): Clear
16435         prefix_rex attribute.
16436         * config/i386/predicates.md (ext_QIreg_operand, const128_operand):
16437         New predicates.
16438         (memory_displacement_only_operand): Always return 0 for TARGET_64BIT.
16439
16440 2009-05-21  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
16441
16442         * config/arm/thumb2.md (orsi_notsi_si): Fix typo in pattern.
16443
16444 2009-05-20  Ian Lance Taylor  <iant@google.com>
16445
16446         * tree.c (build_tree_list_vec_stat): New function.
16447         (ctor_to_vec): New function.
16448         (build_nt_call_vec): New function.
16449         (build_call_array): Change args to be a const pointer.
16450         (build_call_vec): New function.
16451         * tree.h (build_nt_call_vec): Declare.
16452         (build_tree_list_vec_stat): Declare.
16453         (build_tree_list_vec): Define.
16454         (build_call_array): Update declaration.
16455         (build_call_vec): Declare.
16456         (ctor_to_vec): Declare.
16457         * c-common.c (tree_vector_cache): New static variable.
16458         (make_tree_vector): New function.
16459         (release_tree_vector): New function.
16460         (make_tree_vector_single): New function.
16461         (make_tree_vector_copy): New function.
16462         * c-common.h (tree_vector_cache, make_tree_vector): Declare.
16463         (make_tree_vector_single, make_tree_vector_copy): Declare.
16464         * c-parser.c (cached_expr_list_1, cached_expr_list_2): Remove.
16465         (c_parser_expr_list): Don't manage cache here, instead call
16466         make_tree_vector.
16467         (c_parser_release_expr_list): Remove static function.
16468         (c_parser_vec_to_tree_list): Remove static function.
16469         (c_parser_attributes): Call build_tree_list_vec instead of
16470         c_parser_vec_to_tree_list.  Call release_tree_vector instead of
16471         c_parser_release_expr_list.
16472         (c_parser_postfix_expression_after_primary): Likewise.
16473         (c_parser_objc_keywordexpr): Likewise.
16474
16475 2009-05-20  Sandra Loosemore  <sandra@codesourcery.com>
16476
16477         * doc/tm.texi (Misc): Document TARGET_INVALID_PARAMETER_TYPE,
16478         TARGET_INVALID_RETURN_TYPE, TARGET_PROMOTED_TYPE, and
16479         TARGET_CONVERT_TO_TYPE.
16480         * hooks.c (hook_tree_const_tree_null): Define.
16481         * hooks.h (hook_tree_const_tree_null): Declare.
16482         * target.h (struct gcc_target):  Add invalid_parameter_type,
16483         invalid_return_type, promoted_type, and convert_to_type fields.
16484         * target-def.h: (TARGET_INVALID_PARAMETER_TYPE): Define.
16485         (TARGET_INVALID_RETURN_TYPE): Define.
16486         (TARGET_PROMOTED_TYPE): Define.
16487         (TARGET_CONVERT_TO_TYPE): Define.
16488         (TARGET_INITIALIZER): Update for new fields.
16489         * c-decl.c (grokdeclarator): Check targetm.invalid_return_type.
16490         (grokparms): Check targetm.invalid_parameter_type.
16491         * c-typeck.c (default_conversion): Check targetm.promoted_type.
16492         * c-convert.c (convert): Check targetm.convert_to_type.
16493
16494 2009-05-20  Adam Nemet  <anemet@caviumnetworks.com>
16495
16496         * config/mips/mips.md (*extenddi_truncate<mode>,
16497         *extendsi_truncate<mode>): Emit exts if supported.  Add attribute
16498         defintions.
16499         (*extendhi_truncateqi): New define_insn_and_sptit.
16500
16501 2009-05-20  Jakub Jelinek  <jakub@redhat.com>
16502
16503         PR middle-end/40204
16504         * fold-const.c (fold_binary) <case BIT_AND_EXPR>: Avoid infinite
16505         recursion if build_int_cst_type returns the same INTEGER_CST as arg1.
16506
16507 2009-05-20  Eric Botcazou  <ebotcazou@adacore.com>
16508
16509         * fold-const.c (build_fold_addr_expr_with_type): Take the address of
16510         the operand of VIEW_CONVERT_EXPR.
16511
16512 2009-05-20  H.J. Lu  <hongjiu.lu@intel.com>
16513
16514         * config/i386/driver-i386.c (host_detect_local_cpu): Check
16515         extended family and model for Intel processors.  Support Intel Atom.
16516
16517 2009-05-20  Olivier Hainque  <hainque@adacore.com>
16518
16519         * gstab.h (stab_code_type): Define, to be used instead of the
16520         __stab_debug_code enum, made anonymous.  Add 2009 to the copyright
16521         notice.
16522         * dbxout.c (STAB_CODE_TYPE): Remove #define and replace use
16523         occurrences by stab_code_type.
16524         * mips-tfile.c (STAB_CODE_TYPE): Remove #define, unused.
16525
16526 2009-05-20  Martin Jambor  <mjambor@suse.cz>
16527
16528         * tree-flow.h (insert_edge_copies_seq): Undeclare.
16529         (sra_insert_before): Likewise.
16530         (sra_insert_after): Likewise.
16531         (sra_init_cache): Likewise.
16532         (sra_type_can_be_decomposed_p): Likewise.
16533         * tree-mudflap.c (insert_edge_copies_seq): Copied here from tree-sra.c
16534         * tree-sra.c (sra_type_can_be_decomposed_p): Made static.
16535         (sra_insert_before): Likewise.
16536         (sra_insert_after): Likewise.
16537         (sra_init_cache): Likewise.
16538         (insert_edge_copies_seq): Made static and moved upwards.
16539
16540         * tree-complex.c (extract_component): Added VIEW_CONVERT_EXPR switch
16541         case.
16542
16543         * tree-flow-inline.h (contains_view_convert_expr_p): New function.
16544
16545         * ipa-prop.c (get_ssa_def_if_simple_copy): New function.
16546         (determine_cst_member_ptr): Call get_ssa_def_if_simple_copy to skip
16547         simple copies.
16548
16549 2009-05-20  Richard Guenther  <rguenther@suse.de>
16550
16551         * expr.c (expand_expr_real_1): Avoid calling do_store_flag
16552         with mismatched comparison modes.
16553
16554 2009-05-20  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
16555
16556         * config/arm/arm.md (*arm_iorsi3): Refactored for only ARM.
16557         (peephole ior (reg, int) -> mov, ior): Refactored for only ARM.
16558         * config/arm/thumb2.md (*thumb_andsi_not_shiftsi_si): Allow bic
16559         with shifts for Thumb2.
16560         (orsi_notsi): New for orn.
16561         (*thumb_orsi_notshiftsi_si): Allow orn with shifts.
16562         (*thumb2_iorsi3): Rewrite support for iorsi for Thumb2.
16563         * config/arm/arm.c (const_ok_for_op): Split case for IOR for Thumb2.
16564         (arm_gen_constant): Set can_invert for IOR and Thumb2, Add comments.
16565         Don't invert remainder for IOR.
16566
16567 2009-05-19  Zdenek Dvorak  <ook@ucw.cz>
16568
16569         PR tree-optimization/40087
16570         * tree-ssa-loop-niter.c (number_of_iterations_ne_max,
16571         number_of_iterations_ne): Rename never_infinite argument.
16572         (number_of_iterations_lt_to_ne, number_of_iterations_lt,
16573         number_of_iterations_le): Handle pointer-type ivs when
16574         exit_must_be_taken is false.
16575         (number_of_iterations_cond):  Do not always assume that
16576         exit_must_be_taken if the control variable is a pointer.
16577
16578 2009-05-19  Andrew Pinski  <andrew_pinski@playstation.sony.com>
16579
16580         * c-typeck.c (build_binary_op): Allow % on integal vectors.
16581         * doc/extend.texi (Vector Extension): Document that % is allowed too.
16582
16583 2009-05-19  H.J. Lu  <hongjiu.lu@intel.com>
16584
16585         * config/i386/i386.c (ix86_avoid_jump_mispredicts): Check
16586         ASM_OUTPUT_MAX_SKIP_PAD instead of ASM_OUTPUT_MAX_SKIP_ALIGN.
16587
16588 2009-05-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
16589
16590         PR c/40172
16591         * c.opt (Wlogical-op): Disabled by default.
16592         * c-opt (c_common_post_options): Do not enable Wlogical-op with
16593         Wextra.
16594         * doc/invoke.texi (Wlogical-op): Likewise.
16595
16596 2009-05-19  Eric Botcazou  <ebotcazou@adacore.com>
16597
16598         * tree-scalar-evolution.c (follow_ssa_edge_expr) <NOP_EXPR>: Turn
16599         into CASE_CONVERT.
16600         <PLUS_EXPR>: Strip useless type conversions instead of type nops.
16601         Propagate the type of the first operand.
16602         <ASSERT_EXPR>: Simplify.
16603         (follow_ssa_edge_in_rhs): Use gimple_expr_type to get the type.
16604         Rewrite using the RHS code as discriminant.
16605         <NOP_EXPR>: Turn into CASE_CONVERT.
16606         <PLUS_EXPR>: Propagate the type of the first operand.
16607
16608 2009-05-19  Steve Ellcey  <sje@cup.hp.com>
16609
16610         * config/ia64/ia64-protos.h (ia64_dconst_0_5): New.
16611         (ia64_dconst_0_375): New.
16612         * config/ia64/ia64.c (ia64_override_options): Remove
16613         -minline-sqrt-min-latency warning.
16614         (ia64_dconst_0_5_rtx, ia64_dconst_0_5): New.
16615         (ia64_dconst_0_375_rtx, ia64_dconst_0_375): New
16616         * config/ia64/ia64.md (*sqrt_approx): Remove.
16617         (sqrtsf2): Remove #if 0.
16618         (sqrtsf2_internal_thr): Rewrite and move to div.md.
16619         (sqrtdf): Remove assert.
16620         (sqrtdf2_internal_thr): Rewrite and move to div.md.
16621         (sqrtxf2): Remove #if 0.
16622         (sqrtxf2_internal_thr): Rewrite and move to div.md.
16623         * div.md (sqrt_approx_rf): New.
16624         (sqrtsf2_internal_thr): New implementation.
16625         (sqrtsf2_internal_lat): New.
16626         (sqrtdf2_internal_thr: New implementation.
16627         (sqrtxf2_internal): New implementation.
16628
16629 2009-05-19  Francois-Xavier Coudert  <fxcoudert@gmail.com>
16630             Hans-Peter Nilsson  <hp@axis.com>
16631
16632         * defaults.h (UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE)
16633         (WCHAR_TYPE, MODIFIED_WCHAR_TYPE, PTRDIFF_TYPE, WINT_TYPE)
16634         (INTMAX_TYPE, UINTMAX_TYPE, SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE)
16635         (INT32_TYPE, INT64_TYPE, UINT8_TYPE, UINT16_TYPE, UINT32_TYPE)
16636         (UINT64_TYPE, INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE)
16637         (INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE)
16638         (UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE)
16639         (INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE)
16640         (UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE)
16641         (SIZE_TYPE, PID_TYPE, CHAR16_TYPE, CHAR32_TYPE): Move defaults here...
16642         * c-common.c: ...from here.
16643
16644 2009-05-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
16645
16646         * c-common.c (warn_logical_operator): Remove unnecessary conditionals.
16647
16648 2009-05-19  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
16649
16650         * builtins.c (do_mpc_arg1): Separate MPFR/MPC C rounding types.
16651
16652 2009-05-19  Ben Elliston  <bje@au.ibm.com>
16653
16654         * unwind-dw2-fde.c (fde_unencoded_compare): Replace type punning
16655         assignments with memcpy calls.
16656         (add_fdes): Likewise.
16657         (binary_search_unencoded_fdes): Likewise.
16658         (linear_search_fdes): Eliminate type puns.
16659
16660 2009-05-19  Richard Guenther  <rguenther@suse.de>
16661
16662         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Do
16663         not falsely claim to have propagated into all uses.
16664
16665 2009-05-19  Ben Elliston  <bje@au.ibm.com>
16666
16667         * doc/invoke.texi (C Dialect Options): Update OpenMP specification
16668         version to v3.0.
16669
16670 2009-05-18  Kaz Kojima  <kkojima@gcc.gnu.org>
16671
16672         * config/sh/sh-protos.h (sh_legitimate_address_p): Remove.
16673         * config/sh/sh.c (sh_legitimate_address_p): Make static.
16674         (TARGET_LEGITIMATE_ADDRESS_P): New.
16675         * config/sh/sh.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
16676         * config/sh/sh.md: Clean up references to GO_IF_LEGITIMATE_ADDRESS.
16677
16678 2009-05-18  Dodji Seketeli  <dodji@redhat.com>
16679
16680         PR debug/40109
16681         * dwarf2out.c (gen_type_die_with_usage): Generate the DIE as a
16682         child of the containing namespace's DIE.
16683
16684 2009-05-18  Adam Nemet  <anemet@caviumnetworks.com>
16685
16686         * config/mips/mips.md (*zero_extend<GPR:mode>_trunc<SHORT:mode>,
16687         *zero_extendhi_truncqi):  Move after the zero_extend patterns.
16688         (*extenddi_truncate<mode>, *extendsi_truncate<mode>): Move after the
16689         extend patterns.
16690
16691 2009-05-18  H.J. Lu  <hongjiu.lu@intel.com>
16692
16693         PR target/39942
16694         * config/i386/i386.c (ix86_avoid_jump_misspredicts): Replace
16695         gen_align with gen_pad.
16696         (ix86_reorg): Check ASM_OUTPUT_MAX_SKIP_PAD instead of
16697         #ifdef ASM_OUTPUT_MAX_SKIP_ALIGN.
16698
16699         * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): New.
16700         * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
16701
16702         * config/i386/i386.md (align): Renamed to ...
16703         (pad): This.  Replace ASM_OUTPUT_MAX_SKIP_ALIGN with
16704         ASM_OUTPUT_MAX_SKIP_PAD.
16705
16706 2009-05-18  Andreas Schwab  <schwab@linux-m68k.org>
16707
16708         * config.gcc: Fix variable syntax.
16709
16710         PR target/39531
16711         * config/m68k/m68k.c (output_andsi3): Mask off sign bit copies
16712         before calling exact_log2.
16713         (output_iorsi3): Likewise.
16714         (output_xorsi3): Likewise.
16715
16716 2009-05-18  Kaz Kojima  <kkojima@gcc.gnu.org>
16717
16718         * config/sh/sh.c (expand_cbranchdi4): Use a scratch register
16719         for the none zero constant operand except for EQ and NE
16720         comprisons even when the first operand is R0.
16721
16722 2009-05-18  Andreas Krebbel  <krebbel1@de.ibm.com>
16723
16724         * config/s390/2064.md: Remove trailing whitespaces.
16725         * config/s390/2084.md: Likewise.
16726         * config/s390/constraints.md: Likewise.
16727         * config/s390/fixdfdi.h: Likewise.
16728         * config/s390/libgcc-glibc.ver: Likewise.
16729         * config/s390/s390-modes.def: Likewise.
16730         * config/s390/s390-protos.h: Likewise.
16731         * config/s390/s390.c: Likewise.
16732         * config/s390/s390.h: Likewise.
16733         * config/s390/s390.md: Likewise.
16734         * config/s390/tpf-unwind.h: Likewise.
16735
16736 2009-05-18  Maxim Kuvyrkov  <maxim@codesourcery.com>
16737
16738         * config/m68k/m68k.c (m68k_legitimize_address): Fix typo in signature.
16739
16740 2009-05-18  Maxim Kuvyrkov  <maxim@codesourcery.com>
16741
16742         M68K TLS support.
16743         * configure.ac (m68k-*-*): Check if binutils support TLS.
16744         * configure: Regenerate.
16745         * config/m68k/predicates.md (symbolic_operand): Extend comment.
16746         * config/m68k/constraints.md (Cu): New constraint.
16747         * config/m68k/m68k.md (UNSPEC_GOTOFF): Remove.
16748         (UNSPEC_RELOC16, UNSPEC_RELOC32): New constants.
16749         (movsi): Handle TLS symbols.
16750         (addsi3_5200): Handle XTLS symbols, indent.
16751         * config/m68k/m68k-protos.h (m68k_legitimize_tls_address): Declare.
16752         (m68k_tls_reference_p): Declare.
16753         (m68k_legitimize_address): Declare.
16754         (m68k_unwrap_symbol): Declare.
16755         * config/m68k/m68k.opt (mxtls): New option.
16756         * config/m68k/m68k.c (ggc.h): Include.
16757         (m68k_output_dwarf_dtprel): Implement hook.
16758         (TARGET_HAVE_TLS, TARGET_ASM_OUTPUT_DWARF_DTPREL): Define.
16759         (m68k_expand_prologue): Load GOT pointer when function needs it.
16760         (m68k_illegitimate_symbolic_constant_p): Handle TLS symbols.
16761         (m68k_legitimate_constant_address_p): Same.
16762         (m68k_decompose_address): Handle TLS references.
16763         (m68k_get_gp): New static function.
16764         (enum m68k_reloc): New contants.
16765         (TLS_RELOC_P): New macro.
16766         (m68k_wrap_symbol): New static function.
16767         (m68k_unwrap_symbol): New function.
16768         (m68k_final_prescan_insn_1): New static function.
16769         (m68k_final_prescan_insn): New function.
16770         (m68k_move_to_reg, m68k_wrap_symbol_into_got_ref): New static
16771         functions.
16772         (legitimize_pic_address): Handle TLS references..
16773         (m68k_tls_get_addr, m68k_get_tls_get_addr)
16774         (m68k_libcall_value_in_a0_p)
16775         (m68k_call_tls_get_addr, m68k_read_tp, m68k_get_m68k_read_tp)
16776         (m68k_call_m68k_read_tp): Helper variables and functions for ...
16777         (m68k_legitimize_tls_address): Handle TLS references.
16778         (m68k_tls_symbol_p, m68k_tls_reference_p_1, m68k_tls_reference_p):
16779         New functions.
16780         (m68k_legitimize_address): Handle TLS symbols.
16781         (m68k_get_reloc_decoration): New static function.
16782         (m68k_output_addr_const_extra): Handle UNSPEC_RELOC16 and
16783         UNSPEC_RELOC32.
16784         (m68k_output_dwarf_dtprel): Implement hook.
16785         (print_operand_address): Handle UNSPEC_RELOC16 adn UNSPEC_RELOC32.
16786         (m68k_libcall_value): Return result in A0 instead of D0 when asked by
16787         m68k_call_* routines.
16788         (sched_attr_op_type): Handle TLS symbols.
16789         (gt-m68k.h): Include.
16790         * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Define.
16791         (LEGITIMATE_PIC_OPERAND_P): Support TLS.
16792
16793 2009-05-18  Martin Jambor  <mjambor@suse.cz>
16794
16795         * ipa-prop.c (ipa_check_stmt_modifications): Removed.
16796         (visit_store_addr_for_mod_analysis): New function.
16797         (ipa_detect_param_modifications): Use walk_stmt_load_store_addr_ops.
16798         (determine_cst_member_ptr): Use gimple_assign_single_p.
16799         (ipa_get_stmt_member_ptr_load_param): Use gimple_assign_single_p.
16800         (ipa_analyze_call_uses): Use !gimple_assign_rhs2 rather than number of
16801         operands.  Don't check number of operands of a NOP_EXPR.
16802
16803 2009-05-18  Eric Fisher  <joefoxreal@gmail.com>
16804
16805         * doc/tree-ssa.texi (SSA Operands): Fix a mistake.
16806
16807 2009-05-17  Manuel López-Ibáñez  <manu@gcc.gnu.org>
16808
16809         PR c/40172
16810         * c-common.c (warn_logical_operator): Don't warn if one of
16811         expression isn't always true or false.
16812
16813 2009-05-17  Kai Tietz  <kai.tietz@onevision.com>
16814
16815         * config/i386/biarch32.h: New file.
16816         * config.gcc: Add for target i386-w64-* the biarch32.h to tm_file.
16817
16818 2009-05-17  Adam Nemet  <anemet@caviumnetworks.com>
16819
16820         * config/mips/mips.md (*zero_extend<mode>_trunchi,
16821         *zero_extend<mode>_truncqi): Merge these into ...
16822         (*zero_extend<GPR:mode>_trunc<SHORT:mode>): ... this new pattern.
16823         Name the pattern following this as *zero_extendhi_truncqi.
16824
16825 2009-05-16  Brad Lucier  <lucier@math.purdue.edu>
16826
16827         PR middle-end/39301
16828         * hwint.h: Add macro HOST_WIDEST_INT_PRINT.
16829         * bitmap.c (bitmap_descriptor): Make fields HOST_WIDEST_INT.
16830         (output_info): Make field HOST_WIDEST_INT.
16831         (print_statistics): Use HOST_WIDEST_INT_PRINT.
16832         (dump_bitmat_statistics): Same.
16833
16834 2009-05-16  Francois-Xavier Coudert  <fxcoudert@gmail.com>
16835
16836         * config.gcc (use_gcc_stdint):  Set to wrap.
16837         * config/darwin.h (SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE,
16838         INT32_TYPE, INT64_TYPE, UINT8_TYPE, UINT16_TYPE, UINT32_TYPE,
16839         UINT64_TYPE, INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE,
16840         INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE,
16841         UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE,
16842         INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE,
16843         UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE,
16844         UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE): Define.
16845
16846 2009-05-16  Joseph Myers  <joseph@codesourcery.com>
16847
16848         * config.gcc (mips*-*-*): Support arch_32, arch_64, tune_32 and
16849         tune_64.
16850         * config/mips/mips.h (MIPS_ABI_DEFAULT, MULTILIB_ABI_DEFAULT):
16851         Move definitions earlier.
16852         (OPT_ARCH64, OPT_ARCH32): Define.
16853         (OPTION_DEFAULT_SPECS): Add entries for arch_32, arch_64, tune_32
16854         and tune_64.
16855
16856 2009-05-16  Richard Earnshaw  <rearnsha@arm.com>
16857
16858         PR target/40153
16859         * arm.md (cstoresi_nltu_thumb1): Use a neg of ltu as the pattern name
16860         implies.
16861
16862 2009-05-16  Richard Earnshaw  <rearnsha@arm.com>
16863
16864         * arm.md (movdi2): Copy non-reg values to DImode registers.
16865
16866 2009-05-16  Jakub Jelinek  <jakub@redhat.com>
16867
16868         PR target/39942
16869         * final.c (label_to_max_skip): New function.
16870         (label_to_alignment): Only use LABEL_TO_ALIGNMENT if
16871         CODE_LABEL_NUMBER <= max_labelno.
16872         * output.h (label_to_max_skip): New prototype.
16873         * config/i386/i386.c (ix86_avoid_jump_misspredicts): Renamed to...
16874         (ix86_avoid_jump_mispredicts): ... this.  Don't define if
16875         ASM_OUTPUT_MAX_SKIP_ALIGN isn't defined.  Update comment.
16876         Handle CODE_LABELs with >= 16 byte alignment or with
16877         max_skip == (1 << align) - 1.
16878         (ix86_reorg): Don't call ix86_avoid_jump_mispredicts if
16879         ASM_OUTPUT_MAX_SKIP_ALIGN isn't defined.
16880
16881         PR target/39942
16882         * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Don't emit second
16883         .p2align 3 if MAX_SKIP is smaller than 7.
16884         * config/i386/linux.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
16885
16886 2009-05-15  Ian Lance Taylor  <iant@google.com>
16887
16888         * alias.c (struct alias_set_entry_d): Rename from struct
16889         alias_set_entry.  Change all uses.
16890         * except.c (struct call_site_record_d): Rename from struct
16891         call_site_record.  Change all uses.
16892         * except.h (struct eh_region_d): Rename from struct eh_region.
16893         Change all uses.
16894         * gcse.c (struct hash_table_d): Rename from struct hash_table.
16895         Change all uses.
16896         * graphite.c (struct ivtype_map_elt_d): Rename fromstruct
16897         ivtype_map_elt.  Change all uses.
16898         (struct rename_map_elt_d): Rename fromstruct rename_map_elt.
16899         Change all uses.
16900         (struct ifsese_d): Rename fromstruct ifsese.  Change all uses.
16901         * graphite.h (struct name_tree_d): Rename from struct name_tree.
16902         Change all uses.
16903         (struct sese_d): Rename from struct sese.  Change all uses.
16904         * omega.h (struct eqn_d): Rename from struct eqn.  Change all uses.
16905         (struct omega_pb_d): Rename from struct omega_pb.  Change all uses.
16906         * optabs.h (struct optab_d): Rename from struct optab.  Change all
16907         uses.
16908         (struct convert_optab_d): Rename from struct convert_optab.
16909         Change all uses.
16910         * tree-pass.h (struct ipa_opt_pass_d): Rename fromstruct
16911         ipa_opt_pass.  Change all uses.
16912         * tree-predcom.c (struct dref_d): Rename from struct dref.  Change
16913         all uses.
16914
16915         * c-decl.c (pushtag): If -Wc++-compat, warn if the tag is already
16916         defined as a typedef.
16917         (grokdeclarator): If -Wc++-compat, warn if a typedef is already
16918         defined as a tag.
16919
16920 2009-05-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
16921
16922         PR 16302
16923         * fold-const.c (make_range,build_range_check,merge_ranges): Move
16924         declaration to...
16925         (merge_ranges): Returns bool.
16926         * tree.h (make_range): .. to here.
16927         (build_range_check): Likewise.
16928         (merge_ranges): Likewise. Renamed from merge_ranges.
16929         * c-typeck.c (parser_build_binary_op): Update calls to
16930         warn_logical_operator.
16931         * c-common.c (warn_logical_operator): Add new warning.
16932         * c-common.h (warn_logical_operator): Update declaration.
16933
16934 2009-05-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
16935
16936         * ira-conflicts.c (add_insn_allocno_copies): Fix wrong conditional.
16937
16938 2009-05-15  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
16939
16940         * doc/install.texi: Document MPC requirements, flags etc.
16941
16942         * builtins.c (do_mpc_arg1, fold_builtin_ccos): New.
16943         (fold_builtin_cexp): Ensure we get a complex REAL_TYPE.
16944         Evaluate constant arguments.
16945         (fold_builtin_carg): Ensure we get a complex REAL_TYPE.
16946         (fold_builtin_1): Likewise, also evaluate constant arguments.
16947         Remove superfluous break.
16948         (do_mpc_ckconv): New.
16949         * real.h: Include mpc.h.
16950         * toplev.c (print_version): Output MPC version info if available.
16951
16952 2009-05-15  Sandra Loosemore  <sandra@codesourcery.com>
16953
16954         * fold-const.c (fold_convert_const_real_from_real): Check for overflow.
16955
16956 2009-05-15  H.J. Lu  <hongjiu.lu@intel.com>
16957
16958         * config/i386/i386.c (ix86_reorg): Call optimize_function_for_speed_p
16959         only once.
16960
16961 2009-05-15  Jan Hubicka  <jh@suse.cz>
16962
16963         * doc/invoke.texi (max-early-inliner-iterations): New flag.
16964         * ipa-inline.c (enum inlining_mode): New INLINE_SIZE_NORECURSIVE.
16965         (try_inline): Fix return value.
16966         (cgraph_decide_inlining_incrementally): Honor new value.
16967         (cgraph_early_inlining): Handle indirect inlining.
16968         * params.def (PARAM_EARLY_INLINER_MAX_ITERATIONS): New.
16969
16970 2009-05-15  Jan Hubicka  <jh@suse.cz>
16971
16972         * cgraph.h (struct cgraph_node): Add finalized_by_frotnend flag.
16973         * cgraphunit.c (cgraph_finalize_function): Set it.
16974         (cgraph_expand_function): Use it.
16975
16976 2009-05-15  Sandra Loosemore  <sandra@codesourcery.com>
16977
16978         * real.c (encode_ieee_half): Define.
16979         (decode_ieee_half): Define.
16980         (ieee_half_format): Define.
16981         (arm_half_format): Define.
16982         * real.h (ieee_half_format): Declare.
16983         (arm_half_format): Declare.
16984
16985 2009-05-15  Sandra Loosemore  <sandra@codesourcery.com>
16986
16987         * optabs.c (prepare_float_lib_cmp):  Test that the comparison,
16988         swapped, and reversed optabs exist before trying to use them.
16989
16990 2009-05-15  Paul Brook  <paul@codesourcery.com>
16991             Sandra Loosemore  <sandra@codesourcery.com>
16992
16993         * config/arm/arm.c (neon_vector_mem_operand): Handle element/structure
16994         loads.  Allow PRE_DEC.
16995         (output_move_neon): Handle PRE_DEC.
16996         (arm_print_operand): Add 'A' for neon structure loads.
16997         * config/arm/arm-protos.h (neon_vector_mem_operand): Update prototype.
16998         * config/arm/neon.md (neon_mov): Update comment.
16999         * config/arm/constraints.md (Un, Us): Update neon_vector_mem_operand
17000         calls.
17001         (Um): New constraint.
17002
17003 2009-05-15  Jan Hubicka  <jh@suse.cz>
17004
17005         Revert the following patch until testsuite fallout is fixed:
17006         * cgraph.c (dump_cgraph_node): Dump size/time/benefit.
17007         * cgraph.h (struct inline_summary): New filed self_wize,
17008         size_inlining_benefit, self_time and time_inlining_benefit.
17009         (struct cgraph_global_info): Replace insns by time ans size fields.
17010         * ipa-cp (ipcp_cloning_candidate_p): Base estimate on size
17011         (ipcp_estimate_growth, ipcp_insert_stage): Likewise.
17012         (ipcp_update_callgraph): Do not touch function bodies.
17013         * ipa-inline.c: Include except.h
17014         (MAX_TIME): New constant.
17015         (overall_insns): Remove
17016         (overall_size, max_benefit): New static variables.
17017         (cgraph_estimate_time_after_inlining): New function.
17018         (cgraph_estimate_size_after_inlining): Rewrite using benefits.
17019         (cgraph_clone_inlined_nodes): Update size.
17020         (cgraph_mark_inline_edge): Update size.
17021         (cgraph_estimate_growth): Use size info.
17022         (cgraph_check_inline_limits): Check size.
17023         (cgraph_default_inline_p): Likewise.
17024         (cgraph_edge_badness): Compute badness based on benefit and size cost.
17025         (cgraph_decide_recursive_inlining): Check size.
17026         (cgraph_decide_inlining_of_small_function): Update size; dump sizes
17027         and times.
17028         (cgraph_decide_inlining): Likewise.
17029         (cgraph_decide_inlining_incrementally): Likewise; honor
17030         PARAM_EARLY_INLINING_INSNS.
17031         (likely_eliminated_by_inlining_p): New predicate.
17032         (estimate_function_body_sizes): New function.
17033         (compute_inline_parameters): Use it.
17034         * except.c (must_not_throw_labels): New function.
17035         * except.h (must_not_throw_labels): Declare.
17036         * tree-inline.c (init_inline_once): Kill inlining_weigths
17037         * tree-ssa-structalias.c: Avoid uninitialized warning.
17038         * params.def (PARAM_MAX_INLINE_INSNS_SINGLE): Reduce to 300.
17039         (PARAM_MAX_INLINE_INSNS_AUTO): Reduce to 60.
17040         (PARAM_INLINE_CALL_COST): Remove.
17041         (PARAM_EARLY_INLINING_INSNS): New.
17042
17043 2009-05-15  Richard Guenther  <rguenther@suse.de>
17044
17045         * tree-ssa-pre.c (eliminate): Use TODO_update_ssa_only_virtuals,
17046         not TODO_update_ssa.
17047
17048 2009-05-15  Richard Guenther  <rguenther@suse.de>
17049
17050         PR tree-optimization/39999
17051         * gimple.h (gimple_expr_type): Use the expression type looking
17052         through useless conversions.
17053         * tree-ssa-sccvn.c (vn_nary_op_lookup_stmt): Use gimple_expr_type.
17054         (vn_nary_op_insert_stmt): Likewise.
17055         (simplify_binary_expression): Likewise.
17056
17057 2009-05-15  Richard Guenther  <rguenther@suse.de>
17058
17059         * common.opt (-ftree-forwprop, -ftree-phiprop, -ftree-pta):
17060         New options, enabled by default.
17061         * doc/invoke.texi (-ftree-forwprop, -ftree-phiprop, -ftree-pta):
17062         Document.
17063         * tree-ssa-forwprop.c (gate_forwprop): Use flag_tree_forwprop.
17064         * tree-ssa-phiprop.c (gate_phiprop): Use flag_tree_phiprop.
17065         * tree-ssa-structalias.c (gate_tree_pta): New function.
17066         (pass_build_alias): Use it.
17067
17068 2009-05-15  Joseph Myers  <joseph@codesourcery.com>
17069
17070         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Also
17071         recurse on an invariant address if a conversion from a pointer
17072         type to a wider integer type is involved.
17073
17074 2009-05-15  Jan Hubicka  <jh@suse.cz>
17075
17076         * cgraph.c (dump_cgraph_node): Dump size/time/benefit.
17077         * cgraph.h (struct inline_summary): New filed self_wize,
17078         size_inlining_benefit, self_time and time_inlining_benefit.
17079         (struct cgraph_global_info): Replace insns by time ans size fields.
17080         * ipa-cp (ipcp_cloning_candidate_p): Base estimate on size
17081         (ipcp_estimate_growth, ipcp_insert_stage): Likewise.
17082         (ipcp_update_callgraph): Do not touch function bodies.
17083         * ipa-inline.c: Include except.h
17084         (MAX_TIME): New constant.
17085         (overall_insns): Remove
17086         (overall_size, max_benefit): New static variables.
17087         (cgraph_estimate_time_after_inlining): New function.
17088         (cgraph_estimate_size_after_inlining): Rewrite using benefits.
17089         (cgraph_clone_inlined_nodes): Update size.
17090         (cgraph_mark_inline_edge): Update size.
17091         (cgraph_estimate_growth): Use size info.
17092         (cgraph_check_inline_limits): Check size.
17093         (cgraph_default_inline_p): Likewise.
17094         (cgraph_edge_badness): Compute badness based on benefit and size cost.
17095         (cgraph_decide_recursive_inlining): Check size.
17096         (cgraph_decide_inlining_of_small_function): Update size; dump sizes
17097         and times.
17098         (cgraph_decide_inlining): Likewise.
17099         (cgraph_decide_inlining_incrementally): Likewise; honor
17100         PARAM_EARLY_INLINING_INSNS.
17101         (likely_eliminated_by_inlining_p): New predicate.
17102         (estimate_function_body_sizes): New function.
17103         (compute_inline_parameters): Use it.
17104         * except.c (must_not_throw_labels): New function.
17105         * except.h (must_not_throw_labels): Declare.
17106         * tree-inline.c (init_inline_once): Kill inlining_weigths
17107         * tree-ssa-structalias.c: Avoid uninitialized warning.
17108         * params.def (PARAM_MAX_INLINE_INSNS_SINGLE): Reduce to 300.
17109         (PARAM_MAX_INLINE_INSNS_AUTO): Reduce to 60.
17110         (PARAM_INLINE_CALL_COST): Remove.
17111         (PARAM_EARLY_INLINING_INSNS): New.
17112         doc/invoke.texi (max-inline-insns-auto, early-inlining-insns): Update.
17113         (inline-call-cost): Remove.
17114         (early-inlining-insns): New.
17115
17116 2009-05-15  Eric Botcazou  <ebotcazou@adacore.com>
17117
17118         * dbxout.c (dbxout_range_type): Add LOW and HIGH parameters.  Use them
17119         for bounds.
17120         (print_int_cst_bounds_in_octal_p): Likewise.
17121         (dbxout_type): Adjust calls to above functions.  Be prepared to deal
17122         with subtypes.
17123         * dwarf2out.c (base_type_die): Likewise.
17124         (is_subrange_type): Delete.
17125         (subrange_type_die): Add LOW and HIGH parameters.  Use them for bounds.
17126         (modified_type_die): Call subrange_type_for_debug_p on subtypes.
17127         * fold-const.c (fold_truth_not_expr) <CONVERT_EXPR>: Do not strip it
17128         if the destination type is boolean.
17129         (build_range_check): Do not special-case subtypes.
17130         (fold_sign_changed_comparison): Likewise.
17131         (fold_unary): Likewise.
17132         * langhooks-def.h (LANG_HOOKS_GET_SUBRANGE_BOUNDS): Define.
17133         (LANG_HOOKS_FOR_TYPES_INITIALIZER): Add LANG_HOOKS_GET_SUBRANGE_BOUNDS.
17134         * langhooks.h (lang_hooks_for_types): Add get_subrange_bounds.
17135         * tree.c (subrange_type_for_debug_p): New predicate based on the
17136         former is_subrange_type.
17137         * tree.h (subrange_type_for_debug_p): Declare.
17138         * tree-chrec.c (avoid_arithmetics_in_type_p): Delete.
17139         (convert_affine_scev): Remove call to above function.
17140         (chrec_convert_aggressive): Likewise.
17141         * tree-ssa.c (useless_type_conversion_p_1): Do not specifically return
17142         false for conversions involving subtypes.
17143         * tree-vrp.c (vrp_val_max): Do not special-case subtypes.
17144         (vrp_val_min): Likewise.
17145         (needs_overflow_infinity): Likewise.
17146         (extract_range_from_unary_expr): Likewise.
17147
17148 2009-05-15  Paolo Bonzini  <bonzini@gnu.org>
17149
17150         * config/frv/frv.h: Clean up references to GO_IF_LEGITIMATE_ADDRESS.
17151         * config/frv/frv.c: Likewise.
17152         * config/s390/s390.c: Likewise.
17153         * config/sparc/sparc.h: Likewise.
17154         * config/i386/i386.h: Likewise.
17155         * config/i386/i386.c: Likewise.
17156         * config/crx/crx.c: Likewise.
17157         * config/m68hc11/m68hc11.h: Likewise.
17158         * config/iq2000/iq2000.c: Likewise.
17159         * config/mn10300/mn10300.h: Likewise.
17160         * config/mn10300/mn10300.c: Likewise.
17161         * config/m68k/m68k.c: Likewise.
17162         * config/rs6000/rs6000.c: Likewise.
17163         * config/rs6000/xcoff.h: Likewise.
17164         * config/rs6000/linux64.h: Likewise.
17165         * config/rs6000/sysv4.h: Likewise.
17166         * config/score/score3.c: Likewise.
17167         * config/score/score7.c: Likewise.
17168         * config/score/score.c: Likewise.
17169         * config/arm/arm.md: Likewise.
17170         * config/mips/mips.c: Likewise.
17171         * config/mips/mips.md: Likewise.
17172         * config/bfin/bfin.h: Likewise.
17173         * config/pa/pa.c: Likewise.
17174         * config/pa/constraints.md: Likewise.
17175
17176         * config/pdp11/pdp11-protos.h (legitimate_address_p): Delete.
17177         * config/pdp11/pdp11.c (legitimate_address_p): Delete.
17178         * config/pdp11/pdp11.h: Use memory_address_p instead.
17179
17180 2009-05-14  Ian Lance Taylor  <iant@google.com>
17181
17182         * passes.c (finish_optimization_passes): Change i to int.
17183         * plugin.c (plugins_active_p): Change event to int.
17184         (dump_active_plugins): Likewise.
17185         * reginfo.c (invalid_mode_change_p): Change to to unsigned int.
17186         Add cast.
17187         * tree.c (tree_range_check_failed): Change c to unsigned int.
17188         (omp_clause_range_check_failed): Likewise.
17189         (build_common_builtin_nodes): Change mode to int.  Add cast.
17190         * config/ia64/ia64.c (is_emitted): Change r to unsigned int.
17191         (ia64_hard_regno_rename_ok, ia64_eh_uses): Likewise.
17192
17193         * c-typeck.c (build_unary_op): If -Wc++-compat, warn about using
17194         ++ or -- with a variable of enum type.
17195
17196 2009-05-14  Steven Bosscher  <steven@gcc.gnu.org>
17197
17198         PR driver/40144
17199         * opts.c (common_handle_option): Add OPT_fcse_skip_blocks as a no-op.
17200
17201 2009-05-14  Steven Bosscher  <steven@gcc.gnu.org>
17202
17203         * store-motion.c: Do not include params.h
17204         * Makefile.in: Fix dependencies for various files.
17205
17206 2009-05-14  Steven Bosscher  <steven@gcc.gnu.org>
17207
17208         * auto-inc-dec.c: Fix pass description, remove apparent
17209         accidental duplication.
17210
17211 2009-05-14  H.J. Lu  <hongjiu.lu@intel.com>
17212
17213         PR middle-end/40147
17214         * ipa-utils.h (memory_identifier_string): Moved to ...
17215         * tree.h (memory_identifier_string): Here.  Add GTY(()).
17216
17217 2009-05-14  Paolo Bonzini  <bonzini@gnu.org>
17218
17219         * doc/tm.texi (TARGET_LEGITIMATE_ADDRESS_P): Refer mainly to this
17220         in the former documentation of...
17221         (GO_IF_LEGITIMATE_ADDRESS): ... this.
17222         * ira-conflicts.c (get_dup_num): Use address_operand.
17223         * targhooks.c (default_legitimate_address_p): New.
17224         * targhooks.h (default_legitimate_address_p): New.
17225         * reload.c (strict_memory_address_p) [!GO_IF_LEGITIMATE_ADDRESS]:
17226         Call hook.
17227         * recog.c (memory_address_p) [!GO_IF_LEGITIMATE_ADDRESS]: Call hook.
17228         * target.h (struct target): Add legitimate_address_p.
17229         * target-def.h (TARGET_LEGITIMATE_ADDRESS_P): New.
17230         (TARGET_INITIALIZER): Include it.
17231
17232         * config/alpha/alpha.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17233         * config/alpha/alpha-protos.h (alpha_legitimate_address_p): Remove.
17234         * config/alpha/alpha.c (alpha_legitimate_address_p): Make static.
17235         (TARGET_LEGITIMATE_ADDRESS_P): New.
17236
17237         * config/frv/frv.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17238         (REG_OK_STRICT_P): Delete.
17239         * config/frv/frv-protos.h (frv_legitimate_address_p): Rename to...
17240         (frv_legitimate_address_p_1): ... this.
17241         * config/frv/frv.c (frv_legitimate_address_p): Forward to...
17242         (frv_legitimate_address_p_1): ... the renamed old
17243         frv_legitimate_address_p.
17244         * config/frv/predicates.md: Adjust calls to frv_legitimate_address_p.
17245         (TARGET_LEGITIMATE_ADDRESS_P): New.
17246
17247         * config/s390/s390.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17248         * config/s390/s390-protos.h (legitimate_address_p): Remove.
17249         * config/s390/s390.c (legitimate_address_p): Rename to...
17250         (s390_legitimate_address_p): ... this, make static.
17251         (legitimize_address): Adjust call.
17252         (TARGET_LEGITIMATE_ADDRESS_P): New.
17253         * config/s390/constraints.md ("e"): Call strict_memory_address_p.
17254
17255         * config/m32c/m32c.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17256         * config/m32c/m32c-protos.h (m32c_legitimate_address_p): Remove.
17257         * config/m32c/m32c.c (m32c_legitimate_address_p): Make static.
17258         (TARGET_LEGITIMATE_ADDRESS_P): New.
17259
17260         * config/spu/spu.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17261         * config/spu/spu-protos.h (spu_legitimate_address): Remove.
17262         * config/spu/spu.c (spu_legitimate_address): Rename to...
17263         (spu_legitimate_address_p): ... this, make static.
17264         (TARGET_LEGITIMATE_ADDRESS_P): New.
17265
17266         * config/sparc/sparc.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17267         * config/sparc/sparc-protos.h (legitimate_address_p): Remove.
17268         * config/sparc/sparc.c (legitimate_address_p): Rename to...
17269         (sparc_legitimate_address_p): ... this, make static and return bool.
17270         (legitimize_address): Adjust call.
17271         (TARGET_LEGITIMATE_ADDRESS_P): New.
17272
17273         * config/i386/i386.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17274         * config/i386/i386-protos.h (legitimate_address_p): Remove.
17275         * config/i386/i386.c (legitimate_address_p): Rename to...
17276         (ix86_legitimate_address_p): ... this, make static.
17277         (constant_address_p): Move after it, adjust call.
17278         (TARGET_LEGITIMATE_ADDRESS_P): New.
17279
17280         * config/avr/avr.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17281         * config/avr/avr-protos.h (legitimate_address_p): Remove.
17282         * config/avr/avr.c (legitimate_address_p): Rename to...
17283         (avr_legitimate_address_p): ... this, make static.
17284         (legitimize_address): Adjust call.
17285         (TARGET_LEGITIMATE_ADDRESS_P): New.
17286
17287         * config/crx/crx.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17288         * config/crx/crx-protos.h (crx_legitimate_address_p): Remove.
17289         * config/crx/crx.c (crx_legitimate_address_p): Make static.
17290         (TARGET_LEGITIMATE_ADDRESS_P): New.
17291
17292         * config/xtensa/xtensa.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17293         * config/xtensa/xtensa-protos.h (xtensa_legitimate_address_p): Remove.
17294         * config/xtensa/xtensa.c (xtensa_legitimate_address_p): Make static.
17295         (TARGET_LEGITIMATE_ADDRESS_P): New.
17296
17297         * config/stormy16/stormy16.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17298         * config/stormy16/stormy16-protos.h (xstormy16_legitimate_address_p):
17299         Remove.
17300         * config/stormy16/stormy16.c (xstormy16_legitimate_address_p):
17301         Make static.
17302         (TARGET_LEGITIMATE_ADDRESS_P): New.
17303
17304         * config/m68hc11/m68hc11.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17305         * config/m68hc11/m68hc11-protos.h (m68hc11_go_if_legitimate_address):
17306         Remove.
17307         * config/m68hc11/m68hc11.c (m68hc11_go_if_legitimate_address):
17308         Rename to...
17309         (m68hc11_legitimate_address_p): ... this, make static.
17310         (go_if_legitimate_address_internal): Rename to...
17311         (m68hc11_legitimate_address_p_1): ... this.
17312         (legitimize_address): Adjust call.
17313         (TARGET_LEGITIMATE_ADDRESS_P): New.
17314
17315         * config/iq2000/iq2000.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17316         * config/iq2000/iq2000-protos.h (iq2000_legitimate_address_p): Remove.
17317         * config/iq2000/iq2000.c (iq2000_legitimate_address_p): Make static.
17318         (TARGET_LEGITIMATE_ADDRESS_P): New.
17319
17320         * config/mn10300/mn10300.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17321         * config/mn10300/mn10300-protos.h (legitimate_address_p): Remove.
17322         * config/mn10300/mn10300.c (legitimate_address_p): Rename to...
17323         (mn10300_legitimate_address_p): ... this, make static.
17324         (TARGET_LEGITIMATE_ADDRESS_P): New.
17325
17326         * config/m68k/m68k.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17327         * config/m68k/m68k-protos.h (m68k_legitimate_address_p): Remove.
17328         * config/m68k/m68k.c (m68k_legitimate_address_p): Make static.
17329         (TARGET_LEGITIMATE_ADDRESS_P): New.
17330
17331         * config/rs6000/rs6000.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17332         (REG_OK_STRICT_FLAG, REG_OK_FOR_BASE_P, REG_OK_FOR_INDEX_P): Delete.
17333         (INT_REG_OK_FOR_BASE_P, INT_REG_OK_FOR_INDEX_P): Move above.
17334         * config/rs6000/rs6000.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17335         * config/rs6000/rs6000-protos.h (rs6000_legitimate_address): Remove.
17336         * config/rs6000/rs6000.c (rs6000_legitimate_address): Rename to...
17337         (rs6000_legitimate_address_p): ... this, make static.
17338         (TARGET_LEGITIMATE_ADDRESS_P): New.
17339         (REG_MODE_OK_FOR_BASE_P): Delete.
17340         (rs6000_legitimize_reload_address): Use INT_REG_OK_FOR_BASE_P.
17341
17342         * config/picochip/picochip.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17343         * config/picochip/picochip-protos.h (picochip_legitimate_address_p):
17344         Delete.
17345         * config/picochip/picochip.c (picochip_legitimate_address_p): Make
17346         static, adjust types.
17347         (TARGET_LEGITIMATE_ADDRESS_P): New.
17348
17349         * config/score/score.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17350         * config/score/score.c (score_address_p): Rename to...
17351         (score_legitimate_address_p): ... this.
17352         (TARGET_LEGITIMATE_ADDRESS_P): New.
17353         * config/score/score3.c (score3_address_p): Rename to...
17354         (score3_legitimate_address_p): ... this.
17355         * config/score/score7.c (score7_address_p): Rename to...
17356         (score7_legitimate_address_p): ... this.
17357
17358         * config/arm/arm.h (ARM_GO_IF_LEGITIMATE_ADDRESS,
17359         THUMB2_GO_IF_LEGITIMATE_ADDRESS, THUMB1_GO_IF_LEGITIMATE_ADDRESS,
17360         GO_IF_LEGITIMATE_ADDRESS): Delete.
17361         * config/arm/arm-protos.h (thumb1_legitimate_address_p,
17362         thumb2_legitimate_address_p): Delete.
17363         (arm_legitimate_address_p): Rename to...
17364         (arm_legitimate_address_outer_p): ... this.
17365         * config/arm/constraints.md ("Uq"): Adjust call.
17366         * config/arm/predicates.md (arm_extendqisi_mem_op): Likewise.
17367         * config/arm/arm.c (arm_legitimate_address_p): New, rename old one
17368         to...
17369         (arm_legitimate_address_outer_p): ... this.
17370         (thumb1_legitimate_address_p, thumb2_legitimate_address_p): Make
17371         static.
17372         (TARGET_LEGITIMATE_ADDRESS_P): New.
17373
17374         * config/mips/mips.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17375         * config/mips/mips-protos.h (mips_legitimate_address_p): Remove.
17376         * config/mips/mips.c (mips_legitimate_address_p): ... Make static.
17377         (TARGET_LEGITIMATE_ADDRESS_P): New.
17378
17379         * config/vax/vax.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17380         * config/vax/vax-protos.h (legitimate_address_p): Remove.
17381         * config/vax/vax.c (legitimate_address_p): Rename to...
17382         (vax_legitimate_address_p): ... this, make static.
17383         (TARGET_LEGITIMATE_ADDRESS_P): New.
17384
17385         * config/h8300/h8300.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17386         * config/h8300/h8300-protos.h (h8300_legitimate_address_p): Remove.
17387         * config/h8300/h8300.c (h8300_legitimate_address_p): ... Make static.
17388         (TARGET_LEGITIMATE_ADDRESS_P): New.
17389
17390         * config/mmix/mmix.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17391         * config/mmix/mmix-protos.h (mmix_legitimize_address): Remove.
17392         * config/mmix/mmix.c (mmix_legitimate_address): Rename to...
17393         (mmix_legitimate_address_p): ... this, make static.
17394         (TARGET_LEGITIMATE_ADDRESS_P): New.
17395
17396         * config/bfin/bfin.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
17397         * config/bfin/bfin-protos.h (bfin_legitimate_address_p): Remove.
17398         * config/bfin/bfin.c (bfin_legitimate_address_p): ... Make static.
17399         (TARGET_LEGITIMATE_ADDRESS_P): New.
17400
17401 2009-05-14  Paolo Bonzini  <bonzini@gnu.org>
17402
17403         * config/arm/arm.h (PROMOTE_FUNCTION_MODE): Remove handling
17404         of MODE_COMPLEX_INT.
17405
17406 2009-05-14  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
17407
17408         * config/alpha/alpha.c (alpha_initialize_trampoline): Change 0 to
17409         LCT_NORMAL in function call.
17410         * mips-tdump.c (print_file_desc): Add cast to enum type.
17411         * mips-tfile.c (add_ext_symbol): Add casts to enum types.
17412         (mark_stabs): Add casts to enum types.
17413         (parse_stabs_common): Add casts to enum types.
17414
17415 2009-05-13  Adam Nemet  <anemet@caviumnetworks.com>
17416
17417         * config/mips/mips.c (mips_print_operand) <REG, MEM, default>:
17418         Check for invalid values of LETTER.
17419
17420 2009-05-13  Taras Glek  <tglek@mozilla.com>
17421
17422         * attribs.c (register_attribute): moved out attribute registration
17423         into register_attribute.
17424         * doc/plugins.texi: Documented register_attribute and
17425         PLUGIN_ATTRIBUTES.
17426         * gcc-plugin.h: Added forward decl for register_attribute.
17427         * gcc-plugin.h (plugins_event): Added PLUGIN_ATTRIBUTES.
17428         * plugin.c (register_callback, invoke_plugin_callbacks): Added
17429         PLUGIN_ATTRIBUTES boilerplate.
17430
17431 2009-05-14  Dave Korn  <dave.korn.cygwin@gmail.com>
17432
17433         * config/i386/msformat-c.c (ms_printf_length_specs):  Use enumeration
17434         values even in sentinel and empty entries.
17435         (ms_printf_flag_specs):  Likewise.
17436         (ms_scanf_flag_specs):  Likewise.
17437         (ms_strftime_flag_specs):  Likewise.
17438         (ms_print_char_table):  Likewise.
17439         (ms_scan_char_table):  Likewise.
17440         (ms_time_char_table):  Likewise.
17441
17442 2009-05-13  Doug Kwan  <dougkwan@google.com>
17443
17444         * tree-ssa-sccvn.c (compare_ops): Stabilize qsort.
17445
17446 2009-05-13  Adam Nemet  <anemet@caviumnetworks.com>
17447
17448         * config/mips/mips.md (store): Add attributes for QI and HI.
17449         Update comment.
17450         (truncdisi2, truncdihi2, truncdiqi2): Merge these into ...
17451         (truncdi<mode>2): ... this new pattern.
17452
17453 2009-05-13  Brad Hards  <bradh@kde.org>
17454
17455         * Makefile.in (TEXI_GCCINT_FILES): Add plugins.texi.
17456
17457 2009-05-14  Jakub Jelinek  <jakub@redhat.com>
17458             Ben Elliston <bje@au.ibm.com>
17459
17460         PR middle-end/40035
17461         * dse.c (check_mem_read_rtx): Guard against width == -1.
17462
17463 2009-05-13  Michael Matz  <matz@suse.de>
17464
17465         PR middle-end/39976
17466         * tree-outof-ssa.c (maybe_renumber_stmts_bb): New function.
17467         (trivially_conflicts_p): New function.
17468         (insert_backedge_copies): Use it.
17469
17470 2009-05-13  Janis Johnson  <janis187@us.ibm.com>
17471
17472         * c-pragma.c (enum pragma_switch_t): Prefix constants with PRAGMA_.
17473         (handle_stdc_pragma): Use new enum constant names.
17474         (handle_pragma_float_const_decimal64): Ditto.
17475
17476 2009-05-13  Ian Lance Taylor  <iant@google.com>
17477
17478         * Makefile.in (build/gencheck.o): Depend upon all-tree.def, not
17479         tree.def.
17480
17481 2009-05-13  Nathan Sidwell  <nathan@codesourcery.com>
17482
17483         * config/m68k/t-uclinux (M68K_MLIB_CPU): Check for FL_UCLINUX.
17484         * config/m68k/m68k-devices.def: Add FL_UCLINUX to 68020 and 54455
17485         multilibs.
17486         * config/m68k/m68k.h (FL_UCLINUX): Define.
17487
17488 2009-05-13  Jan Hubicka  <jh@suse.cz>
17489
17490         * options.c (gfc_post_options): -fwhole-program imply -fwhole-file.
17491
17492 2009-05-12  Kaz Kojima  <kkojima@gcc.gnu.org>
17493
17494         * config/sh/sh.h (OVERRIDE_OPTIONS): Clear flag_schedule_insns
17495         unless -fschedule-insns is specified.
17496
17497 2009-05-12  Kaz Kojima  <kkojima@gcc.gnu.org>
17498
17499         PR target/39561
17500         * config/sh/sh.h (OPTIMIZATION_OPTIONS): Don't set
17501         TARGET_EXPAND_CBRANCHDI4.
17502         * config/sh/sh.md (cbranchdi4): Don't check TARGET_EXPAND_CBRANCHDI4.
17503         * config/sh/sh.opt (mexpand-cbranchdi): Remove.
17504         (cmpeqdi): Fix comment.
17505
17506 2009-05-12  Kaz Kojima  <kkojima@gcc.gnu.org>
17507
17508         * config/sh/sh-protos.h (sh_legitimate_index_p): Declare.
17509         (sh_legitimate_address_p): Likewise.
17510         * config/sh/sh.c (sh_legitimate_index_p): New.
17511         (sh_legitimate_address_p): Likewise.
17512         * config/sh/sh.h (REG_OK_FOR_BASE_P): Add STRICT parameter.
17513         (REG_OK_FOR_INDEX_P, SUBREG_OK_FOR_INDEX_P): Likewise.
17514         (MODE_DISP_OK_4, MODE_DISP_OK_8): Remove.
17515         (MAYBE_BASE_REGISTER_RTX_P): New macro.
17516         (MAYBE_INDEX_REGISTER_RTX_P): Likewise.
17517         (BASE_REGISTER_RTX_P): Use MAYBE_BASE_REGISTER_RTX_P.
17518         (INDEX_REGISTER_RTX_P): Use MAYBE_INDEX_REGISTER_RTX_P.
17519         (GO_IF_LEGITIMATE_INDEX): Use sh_legitimate_index_p.
17520         (GO_IF_LEGITIMATE_ADDRESS): Use sh_legitimate_address_p.
17521
17522 2009-05-12  Jan Hubicka  <jh@suse.cz>
17523
17524         * tree-inline.c (estimate_operator_cost): Add operands;
17525         when division happens by constant, it is cheap.
17526         (estimate_num_insns): Loads and stores are not having cost of 0;
17527         EH magic stuff is cheap; when computing runtime cost of switch,
17528         use log2 base of amount of its cases; builtin_expect has cost of 0;
17529         compute cost for moving return value of call.
17530         (init_inline_once): Initialize time_based flags.
17531         * tree-inline.h (eni_weights_d): Add time_based flag.
17532
17533 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
17534
17535         * df-core.c: Update head documentation.
17536
17537 2009-05-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
17538
17539         PR bootstrap/40118
17540         * rs6000.c (rs6000_generate_compare): Use op1b instead of
17541         shadowing exisiting variable op1.
17542
17543 2009-05-12  Uros Bizjak  <ubizjak@gmail.com>
17544
17545         PR target/37179
17546         * config/i386/driver-i386.c (processor_signatures): New enum.
17547         (SIG_GEODE): Move from vendor_signatures to processor_signatures.
17548         (host_detect_local_cpu): For SIG_AMD vendor, check for SIG_GEODE
17549         processor signature to detect geode processor.
17550
17551 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
17552
17553         Revert:
17554
17555         2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
17556
17557         * optabs.c (prepare_cmp_insn): Temporarily disable test that
17558         causes spurious differences between trunk and cond-optab branch.
17559
17560 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
17561
17562         * dojump.c (compare_from_rtx): Delete.
17563         * expmed.c (emit_store_flag): Only try cstore_optab.  Canonicalize
17564         any MODE_CC mode to the cstorecc4 pattern.  Use prepare_operand, fail
17565         if the comparison does not satisfy the predicate; test predicates for
17566         operands 2 and 3 of a cstore pattern.  Don't try cstore optab
17567         further if one existing pattern fails.
17568         * expr.h (compare_from_rtx): Delete.
17569         (prepare_operand): Declare it.
17570         * optabs.c: Change "lib call" to "libcall" throughout.
17571         (bcc_gen_fctn, setcc_gen_code, trap_rtx,
17572         HAVE_conditional_trap, emit_cmp_insn): Delete.
17573         (can_compare_p): Delete cmp_optab case.
17574         (prepare_float_lib_cmp): Return an rtx and a machine mode.
17575         Accept other parameters by value.
17576         (prepare_operand): Make non-static.
17577         (prepare_cmp_insn): Return an rtx and a machine mode.  Accept
17578         other parameters by value.  Try to widen operands here based on
17579         an optab_methods argument and looking at cbranch_optab.
17580         (emit_cmp_and_jump_insn_1): Accept test and mode, remove widening
17581         loop.  Use cbranch_optab directly.
17582         (emit_cmp_and_jump_insns): Fix comment.  Adjust call to
17583         prepare_cmp_insn and emit_cmp_and_jump_insn_1, remove obsolete
17584         assertion.
17585         (emit_conditional_move, emit_conditional_add): Inline what's needed
17586         of compare_from_rtx, using new prepare_cmp_insn for the rest.
17587         (init_optabs): Init cmp_optab with UNKNOWN, cbranch_optab
17588         with COMPARE.  Move cmov_optab and cstore_optab above
17589         with cbranch_optab, move cmp_optab down with ucmp_optab,
17590         remove tst_otpab.  Do not initialize trap_rtx.
17591         (gen_cond_trap): Do it here.  Use ctrap_optab.  Test predicate
17592         for trap code.  Do not check HAVE_conditional_trap.  Use
17593         prepare_cmp_insn.  Accept no predicate for operand 3.
17594         * optabs.h (OTI_cmp): Mark as used only for libcalls.
17595         (OTI_ctrap, ctrap_optab): New.
17596         (tst_optab): Delete.
17597         (bcc_gen_fctn, setcc_gen_code, emit_cmp_insn): Delete.
17598         * ifcvt.c (find_if_header): Replace HAVE_conditional_trap
17599         with lookup of ctrap_optab.
17600         * genopinit.c (cmp_optab, tst_optab, bcc_gen_fctn, setcc_gen_code):
17601         Delete.
17602         (ctrap_optab): New.
17603
17604         * combine.c (combine_simplify_rtx, simplify_set): Do not
17605         special case comparing against zero for cc0 machines.
17606         * simplify-rtx.c (simplify_binary_operation_1): Never remove
17607         COMPARE on cc0 machines.
17608         (simplify_relational_operation): Return a new expression when
17609         a COMPARE could be removed.
17610         * final.c (final_scan_insn): Compare cc_status values
17611         against LHS of a (compare FOO (const_int 0)) cc0 source.
17612         Also check if cc_status.value is the full compare.
17613
17614         * doc/md.texi (bCC, sCC, tstMM, cmpMM): Delete.
17615         (cstoreMM4): Document.
17616         (conditional_trap): Document ctrapMM4 instead.
17617         (sync_compare_and_swapMM): Refer to cbranchcc4.
17618         (Dependent Patterns): Eliminate obsolete information referring to
17619         the old jump optimization phase.
17620         (Canonicalization): Include cbranchcc4 case, omit canonicalization
17621         of compares with 0 on cc0 machines.
17622         (Jump Patterns): Refer to MODE_CC jump patterns preferably,
17623         avoiding references to cc0.  Remove text about storing operands
17624         in cmpMM.
17625         * doc/tm.texi (Condition Codes): Include blurb on different
17626         condition code representations, separate into subsections for
17627         CC0, MODE_CC and conditional execution.
17628
17629         * config/alpha/alpha-protos.h (alpha_emit_conditional_branch,
17630         alpha_emit_setcc): Accept operands and a machine mode.
17631         * config/alpha/alpha.c (alpha_emit_conditional_branch):
17632         Get code/op0/op1 from operands, use machine mode argument
17633         instead of alpha_compare.fp_p.  Emit the branch here.
17634         (alpha_emit_setcc): Likewise, and return boolean.
17635         (alpha_emit_conditional_move): Likewise.  Assert that
17636         cmp_op_mode == cmp_mode, and simplify accordingly.
17637         * config/alpha/alpha.h (struct alpha_compare, alpha_compare): Delete.
17638         * config/alpha/alpha.md (cmpdf, cmptf, cmpdi, bCC, sCC): Delete.
17639         (cbranchdf4, cbranchtf4, cbranchdi4, cstoredf4, cstoretf4,cstoredi4):
17640         Delete.
17641         (stack probe test): Use cbranchdi4.
17642         * config/alpha/predicates.md (alpha_cbranch_operator): New.
17643
17644         * config/arc/arc.c (gen_compare_reg): Do not emit cmp.
17645         * config/arc/arc.h (movsicc, movsfcc): Use it.
17646         (movdicc, *movdicc_insn, movdfcc, *movdfcc_insn): Remove.
17647         (cbranchsi4, cstoresi4): New.
17648         (cmpsi, bCC and sCC expanders): Remove.
17649
17650         * config/arm/arm.c (arm_compare_op0, arm_compare_op1): Delete.
17651         * config/arm/arm.h (arm_compare_op0, arm_compare_op1): Delete.
17652         * config/arm/predicates.md (arm_comparison_operator): Only include
17653         floating-point operators if there is a hardware floating-point unit.
17654         * config/arm/arm.md (cbranchsi4, cstoresi4): Enable for TARGET_32BIT,
17655         deferring to cbranch_cc and cstore_cc respectively.
17656         (cbranchsf4, cbranchdf4, cbranchdi4, cstoresf4, cstoredf4, cstoredi4,
17657         cbranch_cc, cstore_cc): New.
17658         (movsicc, movsfcc, movdfcc): Do not use arm_compare_op0 and
17659         arm_compare_op1.
17660         (bCC, sCC, cmpsi, cmpsf, cmpdf, cmpdi): Delete.
17661
17662         * config/avr/avr-protos.h (out_tstsi, out_tsthi): Adjust prototype.
17663         * config/avr/avr.c (out_tstsi, out_tsthi): Get the tested operand
17664         as an argument.
17665         (adjust_insn_length): Adjust calls.
17666         (avr_reorg): Handle (compare (foo) (const_int 0)).
17667         * config/avr/avr.md (tstqi, tsthi, tstsi): Remove.
17668         (*negated_tstqi, *negated_tsthi, *negated_tstsi): Unmacroize.
17669         (*reversed_tsthi, *reversed_tstsi): Add a scratch for simplicity.
17670         (cmpqi, cmphi, cmpsi): Prepend asterisk, fuse tst[qhs]i here.
17671         (bCC): Remove.
17672         (cbranchqi4, cbranchhi4, cbranchsi4): New.
17673         (tst -> sbrc/sbrs peephole2, cpse peephole): Wrap RHS with COMPARE.
17674
17675         * config/bfin/bfin.md (cmpbi, cmpsi, bCC, sCC): Delete.
17676         (cbranchsi4, cstorebi4, cstoresi4): New.
17677         (movbisi): This insn is duplicate, split it to zero_extend.
17678         * config/bfin/bfin.c (bfin_compare_op0, bfin_compare_op1): Delete
17679         (bfin_gen_compare): Do not use them.  Emit VOIDmode SET, not BImode.
17680         (bfin_optimize_loop): Use cbranch expander.
17681         * config/bfin/bfin.h (bfin_compare_op0, bfin_compare_op1): Delete.
17682         * config/bfin/predicates.md (bfin_cbranch_operator): Rename to...
17683         (bfin_bimode_comparison_operator): ... this.
17684         (bfin_direct_comparison_operator): New.
17685
17686         * config/cris/cris.c (cris_normal_notice_update_cc): Look
17687         inside (compare FOO (const_int 0)).
17688         (cris_rtx_costs): Handle ZERO_EXTRACT.
17689         * config/cris/cris.md (tstdi, tst<mode>, cmpdi): Delete.
17690         (*tstdi_non_v32): Fold in *cmpdi_non_v32.
17691         (*tstdi_v32): Delete.
17692         (*cmpdi_non_v32): Add M alternative for operand 1.
17693         (cmpsi, cmp<mode>): Make private.
17694         (*tstsi, *tst<mode>_cmp, *tst<mode>_non_cmp, *btst): Wrap LHS
17695         with COMPARE.
17696         (cbranch<mode>4, cbranchdi4, cstore<mode>4): New.
17697
17698         * config/crx/crx.md (cstore<mode>4, cbranchcc4): New.
17699         (cmp<mode>, bCOND_internal, b<code>, s<code>): Delete.
17700         (cbranch<mode>4, sCOND_internal): Use ordered_comparison_operator.
17701         (cc_reg_operand): New.
17702         (any_cond): Delete.
17703         * config/crx/crx.c (crx_compare_op0, crx_compare_op1,
17704         crx_expand_compare, crx_expand_branch, crx_expand_scond): Delete.
17705         * config/crx/crx.h (crx_compare_op0, crx_compare_op1): Delete.
17706         * config/crx/crx-protos.h (crx_expand_compare, crx_expand_branch,
17707         crx_expand_scond): Delete.
17708
17709         * config/fr30/fr30.md (cmp<mode>, bCC): Delete.
17710         (cbranchsi4): New.
17711         * config/fr30/fr30.c (fr30_compare_op0, fr30_compare_op1): Delete
17712         * config/fr30/fr30.h (fr30_compare_op0, fr30_compare_op1): Delete.
17713
17714         * config/frv/frv.md (cbranchsi4, cbranchsf4, cbranchdf4,
17715         cstoresi4, cstoresf4, cstoredf4): New.
17716         (cmpdi, cmpsi, cmpsf, cmpdf, bCC, sCC): Remove.
17717         * config/frv/frv-protos.h (frv_emit_cbranch, frv_emit_scc):
17718         Receive the entire operands array.
17719         * config/frv/frv.h (frv_compare_op0, frv_compare_op1): Delete.
17720         * config/frv/frv.c (frv_compare_op0, frv_compare_op1): Delete.
17721         * config/frv/frv-protos.h (frv_emit_cbranch, frv_emit_scc):
17722         Get test/op0/op1 from the operands array.
17723         (frv_emit_cond_move): Get test/op0/op1 from the test_rtx.
17724
17725         * config/h8300/h8300-protos.h (h8300_expand_branch): Accept operands.
17726         (h8300_expand_store): New.
17727         * config/h8300/h8300.c (h8300_rtx_costs): Handle (compare FOO
17728         (const_int 0)).
17729         (h8300_expand_branch): Emit compare here.  Adjust for new arguments.
17730         (h8300_expand_store): New.
17731         * config/h8300/h8300.md (btst combine patterns): Wrap with COMPARE
17732         or do not try to produce (set (cc0) REG).
17733         (peepholes): Wrap arguments with COMPARE.  Add a peephole to
17734         change a compare into a move to a scratch register.  Disable some
17735         peepholes when comparing with zero.
17736         (tstsi, tsthi, tstsi, cmpqi): Make private.
17737         (cmphi): Delete.
17738         (bCC, sCC): Delete.
17739         (cbranchqi4, cbranchhi4, cbranchsi4, cstoreqi4, cstorehi4,
17740         cstoresi4): New.
17741
17742         * config/i386/i386.c (ix86_expand_int_movcc, ix86_expand_int_addcc,
17743         ix86_expand_fp_movcc): Set ix86_compare_op0 and ix86_compare_op1.
17744         (ix86_emit_i387_log1p): Use gen_cbranchxf4.
17745         (ix86_emit_i387_log1p): Use cbranchxf2.
17746         (ix86_expand_setcc): Return void.
17747         * config/i386/i386-protos.h (ix86_expand_setcc): Return void.
17748         * config/i386/i386.md (cmpti, cmpdi, cmpsi, cmphi, cmpqi, cmpxf,
17749         cmp<MODEF>, cmpcc): Remove.
17750         (cbranchti4, cbranchdi4, cbranchsi4, cbranchhi4, cbranchqi4,
17751         cbranchxf4, cbranch<MODEF>4, cbranchcc4, cstoredi4, cstoresi4,
17752         cstorehi4, cstoreqi4, cstorexf4, cstore<MODEF>4, cstorecc): New.
17753         (sCC and bCC expanders): Remove.
17754         (stack_protect_test): Use cbranchcc4.
17755
17756         * config/ia64/ia64-protos.h (ia64_compare_op0, ia64_compare_op1):
17757         Delete.
17758         (ia64_expand_compare): Accept three rtx by reference and return void.
17759         * config/ia64/ia64.c (ia64_compare_op0, ia64_compare_op1): Delete.
17760         (ia64_expand_compare): Replace op0/op1 with *op0/*op1.  Get code
17761         from *expr.  Update *expr with the BImode comparison to do.
17762         * config/ia64/ia64.md (cmpbi, cmpsi, cmpdi, cmpsf, cmpdf, cmpxf,
17763         cmptf, bCC, sCC, conditional_trap): Delete.
17764         (cbranchbi4, cbranchsi4, cbranchdi4, cbranchsf4, cbranchdf4,
17765         cbranchxf4, cbranchtf4, cstorebi4, cstoresi4, cstoredi4, cstoresf4,
17766         cstoredf4, cstorexf4, cstoretf4, ctrapbi4, ctrapsi4, ctrapdi4,
17767         ctrapsf4, ctrapdf4, ctrapxf4, ctraptf4): New.
17768         * config/ia64/predicates.md (ia64_cbranch_operator): New.
17769
17770         * config/iq2000/iq2000-protos.h (gen_conditional_branch): Change
17771         type of last argument.
17772         * config/iq2000/iq2000.c (branch_cmp, branch_type): Remove.
17773         (gen_conditional_branch): Get code/cmp0/cmp1 from operands,
17774         use machine mode argument instead of branch_type.  Remove dead
17775         code for floating-point comparisons.
17776         * config/iq2000/iq2000.h (branch_cmp, branch_type): Remove.
17777         * config/iq2000/iq2000.md (cmpsi, cmpdi, cmpsf, cmpdf, tstsi, bCC):
17778         Remove.
17779         (cbranchsi4, cstoresi4): New.
17780         * config/iq2000/predicates.md (reg_or_const_operand): New.
17781
17782         * config/m32c/m32c.md (cbranch splitter): Use match_op_dup.
17783         * config/m32c/m32c.md (any_cond, gl_cond): Delete.
17784         (b<code>_op): Rewrite to...
17785         (bcc_op): ... this, using match_operator.
17786         (s<code>_op): Rewrite to...
17787         (scc_op): ... this, using match_operator.
17788         (s<code>_24_op): Rewrite to...
17789         (scc_op_24): ... this, using match_operator.
17790         (s<code>_<mode>): Rewrite to...
17791         (cstore<mode>4): ... this, using match_operator.
17792         (s<code>_<mode>_24): Rewrite to...
17793         (cstore<mode>4_24): ... this, using match_operator.
17794         * config/m32c/m32c-protos.h (m32c_cmp_flg_0, m32c_pend_compare,
17795         m32c_unpend_compare, m32c_expand_scc): Delete.
17796         * config/m32c/m32c.c (compare_op0, compare_op1, m32c_cmp_flg_0,
17797         m32c_pend_compare, m32c_unpend_compare, m32c_expand_scc): Delete.
17798         (m32c_expand_movcc): Change NE to EQ if necessary.
17799         (m32c_init_libfuncs): Modify cstore optab instead of setcc_gen_code.
17800
17801         * config/m32r/m32r-protos.h (gen_cond_store): New.
17802         * config/m32r/m32r.c (m32r_compare_op0, m32r_compare_op1): Delete.
17803         (gen_cond_store): New, from sCC patterns.
17804         (m32r_expand_block_move): Use cbranchsi4.
17805         * config/m32r/m32r.h (m32r_compare_op0, m32r_compare_op1): Delete.
17806         * config/m32r/m32r.md (cmpsi, bCC, sCC): Delete.
17807         (cbranchsi4, cstoresi4): New.
17808
17809         * config/m68hc11/m68hc11.c (m68hc11_compare_op0, m68hc11_compare_op1):
17810         Delete.
17811         (m68hc11_rtx_costs_1, m68hc11_rtx_costs): Handle ZERO_EXTRACT.
17812         (m68hc11_notice_update_cc): Look into a compare with 0.
17813         * config/m68hc11/m68hc11.h (m68hc11_compare_op0, m68hc11_compare_op1):
17814         Delete.
17815         * config/m68hc11/m68hc11.md (tstsi, tsthi, tstqi, cmpsi,
17816         cmphi, cmpqi, bCC): Delete.
17817         (cbranchsi4, cbranchhi4, cbranchqi4): New.
17818         (tstqi_1, tstqi_z_used, tstqi_1, bitcmpqi, bitcmpqi_z_used,
17819         bitcmpqi_12, bitcmphi, various splits and peephole2s): Wrap cc0<-reg
17820         sets with COMPARE.
17821
17822         * config/m68k/predicates.md (m68k_cstore_comparison_operator,
17823         const0_operand, const1_operand, m68k_subword_comparison_operand): New.
17824         * config/m68k/constraints.md (H): New.
17825         * config/m68k/m68k.md (tstdi): Remove define_expand, use name for
17826         the define_insn below.
17827         (tstsi, tsthi, tst<FP:mode>, cmphi, cmpqi, cmp<FP:mode>): Delete.
17828         (*tstsi_internal_68020_cf, *tstsi_internal, *tsthi_internal,
17829         *tstqi_internal, tst<mode>_6881, tst<mode>_cf, many unnamed
17830         patterns): Wrap RHS with COMPARE.
17831         (tst<FP>_68881, tst<FP>_cf): Use const0_operand.
17832         (*cmpdi_internal): Name this pattern.
17833         (cmpdi): Change to define_insn.
17834         (cbranchdi4, cstoredi4, cbranchsi4, cstoresi4, cbranchhi4, cstorehi4,
17835         cbranchqi4, cstoreqi4, cbranch<FP:mode>4, cstore<FP:mode>4): New.
17836         (scc0_di, scc0_di_5200, scc_di): Use the ordered_comparison_operator
17837         predicate.
17838         (seq, sne, sgt, sgtu, slt, sltu, sge, sgeu, sle, sleu, sordered,
17839         sunordered, suneq, sunge, sungt, sunle, sunlt, sltgt): Delete
17840         (conditional_trap): Change to...
17841         (ctrapdi4, ctrapsi4, ctraphi4, ctrapqi4): ... these.
17842         (*conditional_trap): Use the ordered_comparison_operator and
17843         const1_operand predicates.
17844         * config/m68k/m68k.c (m68k_last_compare_had_fp_operands): Delete.
17845         (m68k_expand_prologue): Use ctrapsi4 instead of cmpsi+conditional_trap.
17846         (m68k_rtx_costs): Look for ZERO_EXTRACT in a COMPARE.
17847         * config/m68k/m68k.h (m68k_last_compare_had_fp_operands): Delete.
17848
17849         * config/mcore/mcore-protos.h (arch_compare_op0, arch_compare_op1,
17850         mcore_modify_comparison, mcore_gen_compare_reg): Remove.
17851         (mcore_gen_compare): New.
17852         * config/mcore/mcore.c (arch_compare_op0, arch_compare_op1): Delete.
17853         (mcore_modify_comparison, mcore_gen_compare_reg): Fold into...
17854         (mcore_gen_compare): ... this.
17855         * config/mcore/mcore.md (cmpsi, bCC, sCC): Remove.
17856         (cbranchsi4, cstoresi4): New, using mcore_gen_compare.
17857         (stack probe pattern): Use cbranchsi4.
17858
17859         * config/mips/predicates.md (mips_cstore_operator): New.
17860         * config/mips/mips-ps-3d.md (movv2sfcc): Do not use cmp_operands.
17861         * config/mips/mips.md (any_cond): Delete.
17862         (conditional_trap): Rename to ctrap<GPR:mode>4.  Adjust predicates,
17863         always succeed.
17864         (fixuns_truncdfsi2, fixuns_truncdfdi2, fixuns_truncsfsi2,
17865         fixuns_truncsfdi2): Use cbranch patterns.
17866         (cmp<GPR:mode>, cmp<SCALARF:mode>): Delete.
17867         (b<code>): Change to cbranch<GPR:mode>4 and cbranch<SCALARF:mode>4.
17868         Adjust call to mips_expand_conditional_branch.
17869         (seq, sne, slt<u>, sle<u>, sgt<u>, sge<u>): Change to
17870         cstore<GPR:mode>4.
17871         * config/mips/mips-protos.h (mips_expand_conditional_branch,
17872         mips_expand_scc, mips_expand_conditional_trap): Adjust prototypes.
17873         * config/mips/mips.c (cmp_operands): Delete.
17874         (mips_emit_compare): Get comparison operands from *op0/*op1.
17875         (mips_expand_scc): Get code/op0/op1/target from operands.  Assert
17876         that it succeeds.  Use op0/op1 instead of cmp_operands.
17877         (mips_expand_conditional_branch, mips_expand_conditional_move,
17878         mips_expand_conditional_trap): Likewise.
17879         (mips_block_move_loop): Use cbranch patterns.
17880         * config/mips/mips.h (cmp_operands): Delete.
17881
17882         * config/mmix/mmix.c (mmix_valid_comparison): Delete.
17883         (mmix_gen_compare_reg): Just return a register in the right CC mode.
17884         * config/mmix/mmix.h (mmix_compare_op0, mmix_compare_op1): New.
17885         * config/mmix/mmix.md (cmpdi, cmpdf): Remove.
17886         (*cmpcc_folded): Rename to...
17887         (*cmpdi_folded): this.
17888         (*cmpcc): Rename to...
17889         (*cmps): ... this.
17890         (movdfcc, movdicc): Adjust for new semantics of mmix_gen_compare_reg.
17891         (bCC): Remove.
17892         (cbranchdi4): New.
17893         (cbranchdf4): New.  Handle invalid comparisons here.
17894         * config/mmix/predicates.md (float_comparison_operator): New.
17895
17896         * config/mn10300/mn10300.c (mn10300_rtx_costs): Consider 0 and
17897         zero_extract to be cheap in (compare (zero_extract) (const_int 0).
17898         * config/mn10300/mn10300.md (tst): Delete.
17899         (*tst_extqisi_am33, *tst_extqisi, *tst_exthisi_am33, *tst_exthisi):
17900         Name these patterns and wrap RHS in a compare.
17901         (*cmpsi): Make this pattern private.  Include tst.
17902         (*cmpsf): Make this pattern private.
17903         (and and zero_extract cc0 set): Wrap RHS in a COMPARE.
17904         (compare with zero peepholes): Likewise.
17905         (bCC): Remove.
17906         (cbranchsi4, cbranchsf4): New.
17907         (casesi): Use cbranchsi4.
17908
17909         * config/pa/pa.c (hppa_compare_op0, hppa_compare_op1,
17910         hppa_branch_type): Delete.
17911         (return_addr_rtx): Use cbranchsi4.
17912         (emit_bcond_fp): Accept all operands.  Replace CODE with NE.
17913         Emit CCFPmode comparison here.
17914         (gen_cmp_fp): Delete, now part of emit_bcond_fp.
17915         * config/pa/pa.h (enum cmp_type, hppa_compare_op0, hppa_compare_op1,
17916         hppa_branch_type): Delete.
17917         * config/pa/pa.md (cmpdi, cmpsi, cmpsf, cmpdf, sCC, bCC): Delete.
17918         (movsicc, movdicc): Remove references to hppa_compare_op0,
17919         hppa_compare_op1 and compare_from_rtx.
17920         (cbranchdi4, cbranchsi4, cbranchsf4, cbranchdf4, cstoresi4): New.
17921         (casesi): Use cbranchsi4.
17922
17923         * config/pdp11/pdp11-protos.h (output_jump): Change prototype.
17924         * config/pdp11/pdp11.c (output_jump): Embed opcodes here.
17925         * config/pdp11/pdp11.md (register_or_const0_operand): New.
17926         (cmpdf, cmphi, cmpqi): Make private.  Add tst alternatives.
17927         (cmpsi, tstsi, tstdf, tsthi, tstqi): Delete.
17928         (bCC): Delete.
17929         (cbranchdf4, cbranchhi4, cbranchqi4): New.
17930         (*branch, *branch_inverted): New.
17931
17932         * config/picochip/picochip.md (cbranchhi4): Use
17933         ordered_comparison_operator.
17934         (cmphi, bCC): Remove.
17935
17936         * config/rs6000/predicates.md (rs6000_cbranch_operator): New.
17937         (trap_comparison_operator): Delete.
17938         * config/rs6000/rs6000-protos.h (rs6000_emit_sCOND,
17939         rs6000_emit_cbranch): Accept mode and operands.
17940         * config/rs6000/rs6000.c (rs6000_compare_op0, rs6000_compare_op1,
17941         rs6000_compare_fp_p): Delete.
17942         (rs6000_generate_compare): Accept mode and comparison.  Extract code
17943         and op0/op1 from there.  Replace references to rs6000_compare_op0
17944         and rs6000_compare_op1.
17945         (rs6000_emit_sCOND): Adjust call to rs6000_generate_compare and
17946         extract result from passed operands.
17947         (rs6000_emit_cbranch): Adjust call to rs6000_generate_compare and
17948         extract loc from passed operands.
17949         (rs6000_emit_cmove): Likewise.
17950         * config/rs6000/rs6000.h (rs6000_compare_op0, rs6000_compare_op1,
17951         rs6000_compare_fp_p): Delete.
17952         * config/rs6000/rs6000.md (cmp<GPR>, cmp<FP>, bCC, sCC): Delete.
17953         (cbranch<GPR>4, cbranch<FP>4): New.
17954         (cstore<mode>4): New.  Consolidate here all choices about when to use
17955         portable or specialized sCC sequences.
17956         (stack_protect_test): Use cbranchsi4.
17957         (conditional_trap): Replace with ctrap<GPR>4.
17958         (conditional trap insn): Replace trap_comparison_operator with
17959         ordered_comparison_operator.
17960
17961         * config/s390/s390.c (s390_compare_op0, s390_compare_op1): Delete.
17962         (s390_emit_prologue): Use ctrap.
17963         * config/s390/s390.h (s390_compare_op0, s390_compare_op1): Delete.
17964         * config/s390/predicates.md (s390_eqne_operator, s390_scond_operator):
17965         New predicates replacing...
17966         * config/s390/s390.md (COMPARE, SCOND): ... these iterators.
17967         (cmp<GPR>, cmp<FP>, cmpcc): Delete.
17968         (trunc patterns): Use emit_cmp_and_jump_insns instead of cmp/branch.
17969         (add<mode>cc): Do not use s390_compare_op0/op1.
17970         (s<code>): Change to...
17971         (cstore<mode>4): ... this. Do not use s390_compare_op0/op1.
17972         (seq): Change to...
17973         (cstorecc4): ... this.  Handle EQ or NE equally.
17974         (*sne): Un-privatize for use in cstorecc4.
17975         (b<code>): Change to...
17976         (cbranch<GPR>4, cbranch<FP>4, cbranchcc4): ... these.
17977         (conditional_trap): Replace with...
17978         (ctrap<GPR>4, ctrap<FP>4): ... these.
17979         (stack_protect): Use cbranchcc4.
17980
17981         * config/score/score-conv.h (cmp_op0, cmp_op1): Delete.
17982         * config/score/score-protos.h (score_gen_cmp): Delete.
17983         * config/score/score.c (cmp_op0, cmp_op1, score_gen_cmp): Delete.
17984         (score_block_move-loop): Use cbranchsi4.
17985         * config/score/score.md (cbranchsi4): New.
17986         (cmpsi, bCC): Delete.
17987         * config/score/score3.c (cmp_op0, cmp_op1, score3_gen_cmp): Delete.
17988         (score3_movsicc): Use ops[1] operands instead of cmp_op0/cmp_op1.
17989         * config/score/score7.c (cmp_op0, cmp_op1, score7_gen_cmp): Delete.
17990         (score7_movsicc): Use ops[1] operands instead of cmp_op0/cmp_op1.
17991         * config/score/score3.h (score3_gen_cmp): Delete.
17992         * config/score/score7.h (score7_gen_cmp): Delete.
17993
17994         * config/sh/sh-protos.h (prepare_scc_operands): Rename to...
17995         (sh_emit_scc_to_t): ... this.  Return void.
17996         (from_compare): Rename to...
17997         (sh_emit_compare_and_branch): ... this.
17998         (sh_emit_compare_and_set): New.
17999         (sh_expand_t_scc): Accept operands.
18000         * config/sh/predicates.md (sh_float_comparison_operator): New.
18001         * config/sh/sh.c (sh_compare_op0, sh_compare_op1): Delete.
18002         (prepare_scc_operands): Rename to...
18003         (sh_emit_scc_to_t): ... this.  Return void.  Get op0/op1 from
18004         arguments.
18005         (sh_emit_cheap_store_flag): New.
18006         (sh_emit_set_t_insn): New.
18007         (from_compare): Rename to...
18008         (sh_emit_compare_and_branch): ... this.  Accept mode.  Rewrite
18009         handling of TARGET_SH2E floating point to avoid recursive call.
18010         Generate branch here.
18011         (sh_emit_compare_and_set): New.
18012         (sh_expand_t_scc): Get op0/op1 from arguments.
18013         (sh_emit_cheap_store_flag): New.
18014         * config/sh/sh.md (cbranchdi4, cbranchsi4): Include -mno-cbranchdi
18015         cases.
18016         (cbranchdi4_i): Use an "I08" constraint instead of an "i" constraint.
18017         (cmpsi, cmpdi, cmpsf, cmpdf): Delete.
18018         (movsicc, movdicc): Do nothing when it recreated operands from
18019         sh_compare_*. Use sh_emit_cheap_store_flag.  Adjust call to
18020         prepare_scc_operands (now sh_emit_scc_to_t).
18021         (udivdi3): Use cstoresi4.
18022         (beq_media, bne_media, bge_media, bgtu_media, bgeu_media, beq,
18023         bne, bgt, blt, ble, bge, bgtu, bltu, bgeu, bleu, bunordered): Delete.
18024         (cbranchint4_media, cbranchfp4_media): New.
18025         (casesi): Use cbranchdi4.
18026         (seq, slt, sle, sgt, sge, sgtu, sltu, sgeu, sne, sleu, sunordered):
18027         Delete.
18028         (cstore4_media, cstoresi4, cstoredi4, cstoresf4, cstoredf4): New.
18029         (movnegt): Remove second operand.
18030         (cbranchsf4, cbranchdf4): New.
18031         (stack_protect): Use cbranchdi4/cbranchsi4.
18032
18033         * config/sparc/sparc.c (sparc_compare_op0, sparc_compare_op1): Delete.
18034         (gen_compare_reg): Accept comparison, extract part of it to...
18035         (gen_compare_reg_1): ... this.
18036         (gen_compare_operator): Delete.
18037         (gen_v9_scc): Accept separate destination, comparison code and arms.
18038         Do not use sparc_compare_op0/sparc_compare_op1.
18039         (emit_scc_insn, emit_conditional_branch_insn): New.
18040         (emit_v9_brxx): Make static.  Remove useless assertion.
18041         (sparc_emit_float_lib_cmp): Return RTL instead of calling
18042         emit_cmp_insn.
18043         (sparc_expand_compare_and_swap_12): Use gen_compare_reg_1+cbranchcc4.
18044         * config/sparc/sparc-protos.h (gen_compare_reg,
18045         sparc_emit_float_lib_cmp): Adjust prototype.
18046         (emit_scc_insn, emit_conditional_branch_insn): New.
18047         (gen_v9_scc, emit_v9_brxx_insn, gen_compare_operator): Delete.
18048         * config/sparc/sparc.h (sparc_compare_op0, sparc_compare_op1): Delete.
18049         * config/sparc/sparc.md (P, I, F, V32, V32I, V64, V64I): Move all
18050         iterators to the top.
18051         (cmpsi, cmpdi, cmpsf, cmpdf, cmptf, seqsi_special_extend,
18052         snesi_special_extend, sCC, bCC, seqdi_special_trunc,
18053         snedi_special_trunc): Delete.
18054         (seqdi_special, snedi_special): Use expansion of seqdi_special_trunc
18055         and snedi_special_trunc.
18056         (cstoresi4, cstoredi4, cstore<F:mode>4, cbranchcc4, cbranchsi4,
18057         cbranchdi4, cbranch<F:mode>4): New.
18058         (mov<I:mode>cc, mov<F:mode>cc): Handle sparc_emit_float_lib_cmp
18059         here.  Use gen_compare_reg instead of gen_compare_operator.
18060         (conditional_trap): Replace with...
18061         (ctrapsi4, ctrapdi4): ... this.
18062         (stack_protect_test): Use cbranchcc4.
18063
18064         * config/spu/spu-protos.h (spu_emit_branch_or_set): Change second
18065         argument to rtx.
18066         * config/spu/spu.c (spu_compare_op0, spu_compare_op1): Remove.
18067         (spu_emit_branch_or_set): Get code/op0/op1 from second argument.
18068         Change spu_compare_op0/op1 to op0/op1 throughout.  Get target
18069         from operands[0] or operands[3] depending on is_set.
18070         * config/spu/spu.h (spu_compare_op0, spu_compare_op1): Remove.
18071         * config/spu/spu.md (cmp<mode:VQHSI>, cmp<mode:DTI>, cmp<mode:VSF>,
18072         cmpdf, bCC), sCC: Remove.
18073         (cbranch<mode:VQHSI>4, cbranch<mode:DTI>, cbranch<mode:VSF>4,
18074         cbranchdf4, cstore<mode:VQHSI>4, cstore<mode:DTI>, cstore<mode:VSF>4,
18075         cstoredf4): New.
18076         (mov<mode>cc): Accept ordered_comparison_operator, adjust call to
18077         spu_emit_branch_or_set.
18078
18079         * config/stormy16/stormy16-protos.h (xstormy16_emit_cbranch):
18080         Add two arguments.
18081         * config/stormy16/stormy16.h (xstormy16_compare_op0,
18082         xstormy16_compare_op1): Delete.
18083         * config/stormy16/stormy16.c (xstormy16_compare_op0,
18084         xstormy16_compare_op1): Delete.
18085         (xstormy16_emit_cbranch): Get op0/op1 from the new arguments.
18086         Adjust calls.
18087         * config/stormy16/stormy16.md (cbranchsi4, cbranchhi4): New.
18088         (cmphi, cmpsi, bCC): Remove.
18089
18090         * config/v850/v850.md (tstsi, cmpsi): Fold into...
18091         (*cmpsi): ... this one.
18092         (cbranchsi4, cstoresi4): New.
18093         (bCC expanders): Delete.
18094         (sCC insns): Fold into...
18095         (*setcc): ... this one.
18096         (casesi): Do not use gen_cmpsi and gen_bgtu.
18097         (various splits): Wrap "naked" RHS of a cc0 set with COMPARE.
18098         (movsicc): Simplify.
18099         * config/v850/v850.c (v850_rtx_costs): Handle ZERO_EXTRACT in COMPARE.
18100
18101         * config/vax/vax-protos.h (cond_name): New.
18102         (vax_output_conditional_branch): Remove.
18103         * config/vax/vax.c (cond_name): New.
18104         (vax_output_conditional_branch): Remove.
18105         * config/vax/vax.h (PRINT_OPERAND): Dispatch %c to cond_name.
18106         * config/vax/vax.md (tst<VAXint>, tst<VAXfp>): Remove.
18107         (cmp<VAXint>, cmp<VAXfp>): Privatize.  Add constraints for tst.
18108         (bit<VAXint>): Wrap source with (compare).
18109         (b<code> and following unnamed pattern): Rename to *branch and
18110         *branch_reversed.  Change macroization to match_operator.
18111         (cbranch<VAXint>4, cbranch<VAXfp>4): New.
18112
18113         * config/xtensa/predicates.md (xtensa_cstoresi_operator): New.
18114         * config/xtensa/xtensa-protos.h (xtensa_expand_conditional_branch):
18115         Change last argument to machine_mode.
18116         (xtensa_expand_scc): Add machine_mode argument.
18117         * config/xtensa/xtensa.c (branch_cmp, branch_type): Remove.
18118         (gen_conditional_move, xtensa_expand_conditional_branch,
18119         xtensa_expand_scc, xtensa_expand_conditional_move): Use mode
18120         instead of branch_type, fetch cmp0/cmp1/test_code from operands[].
18121         Adjust operand numbers.
18122         * config/xtensa/xtensa.h (enum cmp_type, branch_cmp, branch_type):
18123         Delete.
18124         * config/xtensa/xtensa.md (any_cond, any_scc): Delete.
18125         (cmpsi, cmpsf, b<code>, s<code>): Delete.
18126         (cbranchsi4, cbranchsf4, cstoresi4, cstoresf4): New.
18127
18128 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
18129
18130         * optabs.c (prepare_cmp_insn): Temporarily disable test that
18131         causes spurious differences between trunk and cond-optab branch.
18132
18133 2009-05-12  Alexandre Oliva  <aoliva@redhat.com>
18134
18135         PR target/37137
18136         * doc/install.texi (STAGE1_TFLAGS, BUILD_CONFIG): Document.
18137
18138 2009-05-12  Alexandre Oliva  <aoliva@redhat.com>
18139
18140         * tree.c (iterative_hash_pointer): Delete.
18141         (iterative_hash_expr): Short-circuit handling of NULL pointer.
18142         Hash UIDs and versions of SSA names.  Don't special-case built-in
18143         function declarations.
18144
18145 2009-05-11  Ian Lance Taylor  <iant@google.com>
18146
18147         PR bootstrap/40103
18148         * graphite.c: Force -Wc++-compat to only be a warning before
18149         #including "cloog/cloog.h".
18150
18151 2009-05-11  Martin Jambor  <mjambor@suse.cz>
18152
18153         * ipa-cp.c (ipcp_cloning_candidate_p): Add missing return false.
18154
18155 2009-05-11  Jan Hubicka  <jh@suse.cz>
18156
18157         * tree-ssa-loop-ivcanon.c: Include target.h
18158         (struct loop_size): new structure.
18159         (constant_after_peeling): New predicate.
18160         (tree_estimate_loop_size): New function.
18161         (estimated_unrolled_size): Rewrite for new estimates.
18162         (try_unroll_loop_completely): Use new estimates.
18163         * Makefile.in (tree-ssa-loop-ivcanon.o): Add dependenc on target.h
18164
18165 2009-05-11  Andrew Pinski  <andrew_pinski@playstation.sony.com>
18166
18167         * config/spu/spu-c.c (spu_categorize_keyword): Update for recent
18168         libcpp interface change.
18169         (spu_macro_to_expand): Likewise.
18170
18171 2009-05-11  Paolo Bonzini  <bonzini@gnu.org>
18172
18173         PR tree-optimization/40026
18174         * gimplify.c (gimplify_init_constructor): Change initial conditional
18175         to assertion.  Rewrite TREE_OPERAND (*expr_p, 1) after
18176         optimize_compound_literals_in_ctor.
18177
18178 2009-05-11  Nathan Sidwell  <nathan@codesourcery.com>
18179
18180         * config/m68k/m68k-devices.def (52274, 52277, 5301x, 5225x, 51xx):
18181         New devices.
18182         * doc/invoke.texi (M680x0 Options): Document new coldfire cpus.
18183
18184 2009-05-11  H.J. Lu  <hongjiu.lu@intel.com>
18185
18186         * tree-vect-data-refs.c (vect_analyze_group_access): Use
18187         HOST_WIDE_INT for gap.
18188
18189 2009-05-11  Ira Rosen  <irar@il.ibm.com>
18190
18191         PR tree-optimization/40074
18192         * tree-vect-data-refs.c (vect_analyze_group_access): Take gaps into
18193         account in group size and step comparison.
18194
18195 2009-05-11  Richard Guenther  <rguenther@suse.de>
18196
18197         * passes.c (init_optimization_passes): Strip now incorrect comment.
18198         (execute_function_todo): Do not set PROP_alias.
18199         * tree-pass.h (PROP_alias): Remove.
18200         * tree-ssa-structalias.c (pass_build_alias): Do not provide PROP_alias.
18201         * tree-if-conv.c (pass_if_conversion): Do not require PROP_alias.
18202         * tree-nrv.c (pass_return_slot): Likewise.
18203         * tree-object-size.c (pass_object_sizes): Likewise.
18204         * tree-ssa-dom.c (pass_dominator): Likewise.
18205         (pass_phi_only_cprop): Likewise.
18206         * tree-ssa-dse.c (pass_dse): Likewise.
18207         * tree-ssa-phiopt.c (pass_phiopt): Likewise.
18208         (pass_cselim): Likewise.
18209         * tree-ssa-pre.c (pass_pre): Likewise.
18210         (pass_fre): Likewise.
18211         * tree-ssa-reassoc.c (pass_reassoc): Likewise.
18212         * tree-ssa-sink.c (pass_sink_code): Likewise.
18213         * tree-stdarg.c (pass_stdarg): Likewise.
18214         * tree-tailcall.c (pass_tail_calls): Likewise.
18215         * tree-vrp.c (pass_vrp): Likewise.
18216
18217 2009-05-10  Ian Lance Taylor  <iant@google.com>
18218
18219         * basic-block.h (enum profile_status): Break out of struct
18220         control_flow_graph.
18221         * cgraph.h (struct inline_summary): Break out of struct
18222         cgraph_local_info.
18223         * cgraphunit.c (enum cgraph_order_sort_kind): New enum, broken out
18224         of struct cgraph_order_sort.
18225         * combine.c (enum undo_kind): New enum, broken out of struct undo.
18226         * cse.c (struct branch_path): Break out of struct
18227         cse_basic_block_data.
18228         * except.h (enum eh_region_type): Break out of struct eh_region.
18229         * gcc.c (enum add_del): Break out of struct modify_target.
18230         * genrecog.c (enum decision_type): Break out of struct decision_test.
18231         * ggc-page.c (struct ggc_pch_ondisk): Break out of struct
18232         ggc_pch_data.
18233         * matrix-reorg.c (struct free_info): Break out of struct matrix_info.
18234         * regmove.c (enum match_use): New enum, broken out of struct match.
18235         * sched-int.h (enum post_call_group): New enum, broken out of
18236         struct deps.
18237         (struct deps_reg): Break out of struct deps.
18238         * target.h (struct asm_int_op): Break out of struct gcc_target.
18239         * tree-eh.c (struct goto_queue_node): Break out of struct
18240         leh_tf_state.
18241         * tree-inline.h (enum copy_body_cge_which): Break out of
18242         copy_body_data.
18243         * tree-pass.h (enum opt_pass_type): Break out of struct opt_pass.
18244
18245         * c-decl.c (in_struct, struct_types): New static variables.
18246         (pushtag): Add loc parameter.  Change all callers.
18247         (lookup_tag): Add ploc parameter.  Change all callers.
18248         (check_compound_literal_type): New function.
18249         (parser_xref_tag): Add loc parameter.  Change all callers.  If
18250         -Wc++-compat, warn about struct/union/enum types defined within a
18251         struct or union.
18252         (start_struct): Add enclosing_in_struct, enclosing_struct_types,
18253         and loc parameters.  Change all callers.  Change error calls to
18254         error_at, using loc.  For a redefinition, if the location of the
18255         original definition is known, report it.  Set in_struct and
18256         struct_types.  If -Wc++-compat warn if in sizeof, typeof, or alignof.
18257         (finish_struct): Add new parameters enclosing_in_struct and
18258         enclosing_struct_types.  Change all callers.  Set
18259         C_TYPE_DEFINED_IN_STRUCT for all struct/union/enum types defined
18260         in the struct.  If in a struct, add this struct to struct_types.
18261         (start_enum): Add loc parameter.  Change all callers.  Use
18262         error_at for errors, using loc.  For a redefinition, if the
18263         location of the original definition is known, report it.  If in a
18264         struct, add this enum type to struct_types.  If -Wc++-compat warn
18265         if in sizeof, typeof, or alignof.
18266         * c-parser.c (disable_extension_diagnostics): Disable -Wc++-compat.
18267         (enable_extension_diagnostics): Reenable -Wc++-compat if appropriate.
18268         (c_parser_enum_specifier): Get enum location for start_enum.
18269         (c_parser_struct_or_union_specifier): Get struct location for
18270         start_struct.  Save in_struct and struct_types status between
18271         start_struct and finish_struct.
18272         (c_parser_cast_expression): Get location of cast.
18273         (c_parser_alignof_expression): Get location of type.
18274         (c_parser_postfix_expression): Likewise.
18275         (c_parser_postfix_expression_after_paren_type): Add type_loc
18276         parameter.  Change all callers.  Call check_compound_literal_type.
18277         Use type_loc for error about variable size type.
18278         * c-typeck.c (build_external_ref): If -Wc++-compat, warn about a use
18279         of an enum constant from an enum type defined in a struct or union.
18280         (c_cast_expr): Add loc parameter.  Change all callers.  If
18281         -Wc++-compat, warn about defining a type in a cast.
18282         * c-tree.h (C_TYPE_DEFINED_IN_STRUCT): Define.
18283         (start_enum, start_struct, finish_struct): Update declarations.
18284         (parser_xref_tag, c_cast_expr): Update declarations.
18285         (check_compound_literal_type): Declare.
18286
18287 2009-05-11  Ben Elliston  <bje@au.ibm.com>
18288
18289         * config/rs6000/rs6000-c.c (altivec_categorize_keyword): Update
18290         for recent libcpp interface change.
18291         (rs6000_macro_to_expand): Likewise.
18292
18293 2009-05-10  Michael Matz  <matz@suse.de>
18294
18295         PR target/40031
18296         * config/arm/arm.c (require_pic_register): Emit on entry edge,
18297         not at entry of function.
18298
18299 2009-05-10  Richard Guenther  <rguenther@suse.de>
18300
18301         PR tree-optimization/40081
18302         Revert
18303         * tree-sra.c (instantiate_element): Instantiate scalar replacements
18304         using the main variant of the element type.  Do not fiddle with
18305         TREE_THIS_VOLATILE or TREE_SIDE_EFFECTS.
18306
18307         * tree-sra.c (sra_type_can_be_decomposed_p): Do not decompose
18308         structs with volatile fields.
18309
18310 2009-05-10  Jan Hubicka  <jh@suse.cz>
18311
18312         * tree-inline.c (delete_unreachable_blocks_update_callgraph): Declare.
18313         (estimate_move_cost): Assert that it does not get called for
18314         VOID_TYPE_P.
18315         (estimate_num_insns): Skip VOID types in argument handling.
18316         (optimize_inline_calls): Delete unreachable blocks and verify that
18317         callgraph is valid.
18318
18319 2009-05-10  Jan Hubicka  <jh@suse.cz>
18320
18321         * cgraphbuild.c (record_reference): Use cgraph_mark_address_taken_node.
18322         * cgraph.c (cgraph_mark_address_taken_node): New function.
18323         (dump_cgraph_node): Dump new flag.
18324         * cgraph.h (struct cgraph_node): Add address_taken.
18325         (cgraph_mark_address_taken_node): New function.
18326         * ipa.c (cgraph_postorder): Prioritize functions with address taken
18327         since new direct calls can be born.
18328
18329 2009-05-10  Joseph Myers  <joseph@codesourcery.com>
18330
18331         * c-lex.c (c_lex_with_flags): Expect cpp_hashnode in
18332         tok->val.node.node.
18333
18334 2009-05-10  Jan Hubicka  <jh@suse.cz>
18335
18336         PR middle-end/40084
18337         * cgraph.c (cgraph_update_edges_for_call_stmt_node): Take old_call
18338         argument; rewrite.
18339         (cgraph_update_edges_for_call_stmt): Take old_decl argument.
18340         * cgraph.h (cgraph_update_edges_for_call_stmt): Update prototype.
18341         * tree-inline.c (copy_bb): Set frequency correctly.
18342         (fold_marked_statements): Update call to
18343         cgraph_update_edges_for_call_stmt.
18344
18345 2009-05-10  Joseph Myers  <joseph@codesourcery.com>
18346
18347         * config/arc/arc.c (arc_handle_interrupt_attribute): Use %qE for
18348         identifiers in diagnostics.
18349         * config/arm/arm.c (arm_handle_fndecl_attribute,
18350         arm_handle_isr_attribute): Likewise.
18351         * config/avr/avr.c (avr_handle_progmem_attribute,
18352         avr_handle_fndecl_attribute, avr_handle_fntype_attribute): Likewise.
18353         * config/bfin/bfin.c (handle_int_attribute,
18354         bfin_handle_longcall_attribute, bfin_handle_l1_text_attribute,
18355         bfin_handle_l1_data_attribute, bfin_handle_longcall_attribute,
18356         bfin_handle_l1_text_attribute, bfin_handle_l1_data_attribute):
18357         Likewise.
18358         * config/darwin.c (darwin_handle_kext_attribute,
18359         darwin_handle_weak_import_attribute): Likewise.
18360         * config/h8300/h8300.c (h8300_handle_fndecl_attribute,
18361         h8300_handle_eightbit_data_attribute,
18362         h8300_handle_tiny_data_attribute): Likewise.
18363         * config/i386/i386.c (ix86_handle_cconv_attribute,
18364         ix86_handle_abi_attribute, ix86_handle_struct_attribute): Likewise.
18365         * config/i386/winnt.c (ix86_handle_shared_attribute,
18366         ix86_handle_selectany_attribute): Likewise.
18367         * config/ia64/ia64.c (ia64_handle_model_attribute): Likewise.
18368         * config/m32c/m32c.c (function_vector_handler): Likewise.
18369         * config/m68hc11/m68hc11.c (m68hc11_handle_page0_attribute,
18370         m68hc11_handle_fntype_attribute): Likewise.
18371         * config/m68k/m68k.c (m68k_handle_fndecl_attribute): Likewise.
18372         * config/mcore/mcore.c (mcore_handle_naked_attribute): Likewise.
18373         * config/mips/mips.c (mips_insert_attributes,
18374         mips_merge_decl_attributes, mips_expand_builtin): Likewise.
18375         * config/rs6000/rs6000.c (rs6000_handle_longcall_attribute,
18376         rs6000_handle_struct_attribute): Likewise.
18377         * config/sh/sh.c (sh_insert_attributes,
18378         sh_handle_resbank_handler_attribute,
18379         sh_handle_interrupt_handler_attribute,
18380         sh2a_handle_function_vector_handler_attribute,
18381         sh_handle_sp_switch_attribute, sh_handle_trap_exit_attribute):
18382         Likewise.
18383         * config/sh/symbian.c (sh_symbian_mark_dllimport): Likewise.
18384         * config/spu/spu.c (spu_handle_fndecl_attribute,
18385         spu_handle_vector_attribute): Likewise.
18386         * config/stormy16/stormy16.c
18387         (xstormy16_handle_interrupt_attribute): Likewise.
18388         * config/v850/v850-c.c (ghs_pragma_section): Likewise.
18389         * config/v850/v850.c (v850_handle_interrupt_attribute): Likewise.
18390
18391 2009-05-10  Joseph Myers  <joseph@codesourcery.com>
18392
18393         * pretty-print.h (struct pretty_print_info): Add translate_identifiers.
18394         (pp_translate_identifiers): New.
18395         (pp_identifier): Only conditionally translate identifier to locale
18396         character set.
18397         * pretty-print.c (pp_construct): Set pp_translate_identifiers.
18398         (pp_base_tree_identifier): Only conditionally translate identifier
18399         to locale character set.
18400         * c-pretty-print.c (M_): Define.
18401         (pp_c_type_specifier, pp_c_primary_expression): Mark English
18402         fragments for conditional translation with M_.
18403         * tree-pretty-print.c (maybe_init_pretty_print): Disable
18404         identifier translation.
18405
18406 2009-05-10  Richard Guenther  <rguenther@suse.de>
18407
18408         PR tree-optimization/40081
18409         * tree-sra.c (instantiate_element): Instantiate scalar replacements
18410         using the main variant of the element type.  Do not fiddle with
18411         TREE_THIS_VOLATILE or TREE_SIDE_EFFECTS.
18412
18413 2009-05-09  Jan Hubicka  <jh@suse.cz>
18414
18415         PR middle-end/40080
18416         * cgraphunit.c (cgraph_materialize_all_clones): Do not redirect
18417         indirect calls; verify cgraph afterwards.
18418
18419 2009-05-09  Jan Hubicka  <jh@suse.cz>
18420
18421         PR bootstrap/40082
18422         * ipa.c (update_inlined_to_pointer): New function.
18423         (cgraph_remove_unreachable_nodes): Use it.
18424
18425 2009-05-09  Jan Hubicka  <jh@suse.cz>
18426
18427         * tree-eh.c (struct leh_state): Remove prev_try.
18428         (lower_try_finally, lower_catch, lower_eh_filter, lower_cleanup): Do
18429         not track prev_try.
18430         * except.c (gen_eh_region_cleanup, duplicate_eh_regions,
18431         copy_eh_region_1, copy_eh_region, redirect_eh_edge_to_label,
18432         remove_eh_handler_and_replace, foreach_reachable_handler,
18433         verify_eh_region, verify_eh_tree): Remove tracking of prev_try pointer.
18434         * except.h (struct eh_region): Remove eh_region_u_cleanup.
18435         (gen_eh_region_cleanup): Update prototype.
18436
18437 2009-05-09  Jan Hubicka  <jh@suse.cz>
18438
18439         PR middle-end/40043
18440         * except.c (copy_eh_region): Always set prev_try.
18441         (redirect_eh_edge_to_label): Find outer try.
18442         (foreach_reachable_handler): When looking for prev try
18443         handle case where previous try is not going to be taken.
18444
18445 2009-05-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
18446
18447         PR tree-optimization/40049
18448         * tree-vect-stmts.c (vectorizable_operation): If the machine has
18449         only vector/vector shifts, convert the type of the constant to the
18450         appropriate type to avoid building incorrect trees, which
18451         eventually have problems with garbage collection.
18452
18453 2009-05-08  Joseph Myers  <joseph@codesourcery.com>
18454
18455         * fold-const.c (fold_binary): Do not fold multiplication by 1 or
18456         -1 for complex floating-point types if honoring signed zeros.
18457
18458 2009-05-08  Jan Hubicka  <jh@suse.cz>
18459
18460         * cgraphbuild.c (compute_call_stmt_bb_frequency): Accept function
18461         argument; handle correctly when profile is absent.
18462         (build_cgraph_edges): Update.
18463         (rebuild_cgraph_edges): Update.
18464         * cgraph.c: Do not include varray.h.
18465         (cgraph_set_call_stmt_including_clones): New function.
18466         (cgraph_create_edge_including_clones): Likewise
18467         (cgraph_update_edges_for_call_stmt_node): New static cfunction.
18468         (cgraph_update_edges_for_call_stmt): Handle clones.
18469         (cgraph_remove_node): Handle clone tree.
18470         (cgraph_remove_node_and_inline_clones): New function.
18471         (dump_cgraph_node): Dump clone tree.
18472         (cgraph_clone_node): Handle clone tree.
18473         (clone_function_name): Bring here from tree-inline.c.
18474         (cgraph_create_virtual_clone): New function.
18475         * cgraph.h (ipa_replace_map): Move here from ipa.h.
18476         (cgraph_clone_info): New function.
18477         (strut cgraph_node): Add clone_info and new clone tree pointers.
18478         (cgraph_remove_node_and_inline_clones,
18479         cgraph_set_call_stmt_including_clones,
18480         cgraph_create_edge_including_clones,
18481         cgraph_create_virtual_clone): Declare.
18482         (cgraph_function_versioning): Use VEC argument.
18483         (compute_call_stmt_bb_frequency): Update prototype.
18484         (cgraph_materialize_all_clones): New function.
18485         * ipa-cp.c (ipcp_update_cloned_node): Remove.
18486         (ipcp_create_replace_map): Update to VECtors.
18487         (ipcp_update_callgraph): Use virtual clones.
18488         (ipcp_update_bb_counts, ipcp_update_edges_counts): Remove.
18489         (ipcp_update_profiling): Do not update local profiling.
18490         (ipcp_insert_stage): Use VECtors and virtual clones.
18491         * cgraphunit.c (verify_cgraph_node): Verify clone tree.
18492         (clone_of_p): New function.
18493         (cgraph_preserve_function_body_p): Use clone tree.
18494         (cgraph_optimize): Materialize clones.
18495         (cgraph_function_versioning): Update for VECtors.
18496         (save_inline_function_body): Use clone tree.
18497         (cgraph_materialize_clone): New function.
18498         (cgraph_materialize_all_clones): Likewise.
18499         * ipa-inline.c (cgraph_default_inline_p): Use analyzed flags.
18500         * ipa.c: Include gimple.h.
18501         (cgraph_remove_unreachable_nodes): Use clone tree.
18502         * ipa-prop.c (ipa_note_param_call): Update call to
18503         compute_call_stmt_bb_frequencycall.
18504         * ipa-prop.h (ipa_replace_map): Move to cgraph.h.
18505         * tree-inline.c: Do not include varray.h or gt-tree-inline.h.
18506         (copy_bb): Handle updating of clone tree; add new edge when new call
18507         appears.
18508         (expand_call_inline): Be strict about every call having edge.
18509         (clone_fn_id_num, clone_function_name): Move to cgraph.c.
18510         (delete_unreachable_blocks_update_callgraph): New function.
18511         (tree_function_versioning): Use VECtors; always remove unreachable
18512         blocks and fold conditionals.
18513         * tree-inline.h: Do not include varray.h.
18514         (tree_function_versioning): Remove.
18515         * Makefile.in (GTFILES): Remove tree-inline.c
18516         * passes.c (do_per_function): Do only functions having body.
18517         * ipa-struct-reorg.c (do_reorg_1, collect_data_accesses): Handle clone
18518         tree.
18519
18520 2009-05-08  H.J. Lu  <hongjiu.lu@intel.com>
18521             Andrew Morrow  <acm@google.com>
18522
18523         PR c/36892
18524         * c-common.c (c_common_attribute_table): Permit deprecated
18525         attribute to take an optional argument.
18526         (handle_deprecated_attribute): If the optional argument to
18527         __attribute__((deprecated)) is not a string ignore the attribute
18528         and emit a warning.
18529
18530         * c-decl.c (grokdeclarator): Updated warn_deprecated_use call.
18531         * c-typeck.c (build_component_ref): Likewise.
18532         (build_external_ref): Likewise.
18533
18534         * toplev.c (warn_deprecated_use): Add an attribute argument.
18535         Emit the message associated with __attribute__((deprecated)).
18536
18537         * toplev.h (warn_deprecated_use): Updated.
18538
18539         * doc/extend.texi: Document new optional parameter to
18540         __attribute__((deprecated))
18541
18542 2009-05-08  Michael Eager <eager@eagercon.com>
18543
18544         * config/rs6000/rs6000.md (*movdf_softfloat32): replace
18545         !TARGET_DOUBLE_FLOAT with TARGET_SINGLE_FLOAT.
18546
18547 2009-05-08  Richard Guenther  <rguenther@suse.de>
18548
18549         PR tree-optimization/40062
18550         * tree-scalar-evolution.c (follow_ssa_edge_in_condition_phi):
18551         Avoid exponential behavior.
18552
18553 2009-05-08  Paolo Bonzini  <bonzini@gnu.org>
18554
18555         PR rtl-optimization/33928
18556         PR 26854
18557         * fwprop.c (use_def_ref, get_def_for_use, bitmap_only_bit_bitween,
18558         process_uses, build_single_def_use_links): New.
18559         (update_df): Update use_def_ref.
18560         (forward_propagate_into): Use get_def_for_use instead of use-def
18561         chains.
18562         (fwprop_init): Call build_single_def_use_links and let it initialize
18563         dataflow.
18564         (fwprop_done): Free use_def_ref.
18565         (fwprop_addr): Eliminate duplicate call to df_set_flags.
18566         * df-problems.c (df_rd_simulate_artificial_defs_at_top,
18567         df_rd_simulate_one_insn): New.
18568         (df_rd_bb_local_compute_process_def): Update head comment.
18569         (df_chain_create_bb): Use the new RD simulation functions.
18570         * df.h (df_rd_simulate_artificial_defs_at_top,
18571         df_rd_simulate_one_insn): New.
18572         * opts.c (decode_options): Enable fwprop at -O1.
18573         * doc/invoke.texi (-fforward-propagate): Document this.
18574
18575 2009-05-08  Joseph Myers  <joseph@codesourcery.com>
18576
18577         PR c/24581
18578         * c-typeck.c (build_binary_op): Handle arithmetic between one real
18579         and one complex operand specially.
18580         * tree-complex.c (some_nonzerop): Do not identify a real value as
18581         zero if flag_signed_zeros.
18582
18583 2009-05-08  Paolo Bonzini  <bonzini@gnu.org>
18584
18585         PR rtl-optimization/33928
18586         * loop-invariant.c (record_use): Fix && vs. || mishap.
18587
18588 2009-05-08  Paolo Bonzini  <bonzini@gnu.org>
18589
18590         PR rtl-optimization/33928
18591         * loop-invariant.c (struct use): Add addr_use_p.
18592         (struct def): Add n_addr_uses.
18593         (struct invariant): Add cheap_address.
18594         (create_new_invariant): Set cheap_address.
18595         (record_use): Accept df_ref.  Set addr_use_p and update n_addr_uses.
18596         (record_uses): Pass df_ref to record_use.
18597         (get_inv_cost): Do not add inv->cost to comp_cost for cheap addresses
18598         used only as such.
18599
18600 2009-05-08  Kaz Kojima  <kkojima@gcc.gnu.org>
18601
18602         * config/sh/sh.c: Do not include c-pragma.h.
18603
18604 2009-05-07  Andrew Pinski  <andrew_pinski@playstation.sony.com>
18605
18606         * config/spu/spu.c: Remove include of c-common.h.
18607
18608 2009-05-07  Janis Johnson  <janis187@us.ibm.com>
18609
18610         PR c/39037
18611         * c-common.h (mark_valid_location_for_stdc_pragma,
18612         valid_location_for_stdc_pragma_p, set_float_const_decimal64,
18613         clear_float_const_decimal64, float_const_decimal64_p): New.
18614         * c.opt (Wunsuffixed-float-constants): New.
18615         * c-lex.c (interpret_float): Use pragma FLOAT_CONST_DECIMAL64 for
18616         unsuffixed float constant, handle new warning.
18617         * c-cppbuiltin.c (c_cpp_builtins): Use cast for double constants.
18618         * c-decl.c (c_scope): New flag float_const_decimal64.
18619         (set_float_const_decimal64, clear_float_const_decimal64,
18620         float_const_decimal64_p): New.
18621         (push_scope): Set new flag.
18622         * c-parser.c (c_parser_translation_unit): Mark when it's valid
18623         to use STDC pragmas.
18624         (c_parser_external_declaration): Ditto.
18625         (c_parser_compound_statement_nostart): Ditto.
18626         * c-pragma.c (valid_location_for_stdc_pragma,
18627         mark_valid_location_for_stdc_pragma,
18628         valid_location_for_stdc_pragma_p, handle_stdc_pragma,
18629         handle_pragma_float_const_decimal64): New.
18630         (init_pragma): Register new pragma FLOAT_CONST_DECIMAL64.
18631         * cp/semantics.c (valid_location_for_stdc_pragma_p,
18632         set_float_const_decimal64, clear_float_const_decimal64,
18633         float_const_decimal64_p): New dummy functions.
18634         * doc/extend.texi (Decimal Float): Remove statement that the
18635         pragma, and suffix for double constants, are not supported.
18636         * doc/invoke.texi (Warning Options): List new option.
18637         (-Wunsuffixed-float-constants): New.
18638
18639 2009-05-08  Steven Bosscher  <steven@gcc.gnu.org>
18640
18641         * config/i386/i386.c: Do not include c-common.h.
18642
18643 2009-05-07  Mark Heffernan  <meheff@google.com>
18644
18645         * doc/invoke.texi (Debugging Options): Document change of debugging
18646         dump location.
18647         * opts.c (decode_options): Make dump_base_name relative to
18648         aux_base_name directory.
18649
18650 2009-05-07  Hariharan Sandanagobalane <hariharan@picochip.com>
18651
18652         * config/picochip/picochip.h (NO_DOLLAR_IN_LABEL): Added.
18653         * config/picochip/libgccExtras/divmod15.asm : Removed redefiniton.
18654
18655 2009-05-07  Rafael Avila de Espindola  <espindola@google.com>
18656
18657         * Makefile.in (install-plugin): Simplify a bit.
18658
18659 2009-05-07  Paolo Bonzini  <bonzini@gnu.org>
18660
18661         * Makefile.in (OBJS-common): Add regcprop.o.
18662         (regcprop.o): New.
18663         * timevar.def (TV_CPROP_REGISTERS): New.
18664         * regrename.c (regrename_optimize): Return 0.
18665         (rest_of_handle_regrename): Delete.
18666         (pass_rename_registers): Point to regrename_optimize.
18667         (struct value_data_entry, struct value_data,
18668         kill_value_one_regno, kill_value_regno, kill_value,
18669         set_value_regno, init_value_data, kill_clobbered_value,
18670         kill_set_value, kill_autoinc_value, copy_value,
18671         mode_change_ok, maybe_mode_change, find_oldest_value_reg,
18672         replace_oldest_value_reg, replace_oldest_value_addr,
18673         replace_oldest_value_mem, copyprop_hardreg_forward_1,
18674         debug_value_data, validate_value_data): Move...
18675         * regcprop.c: ... here.
18676         (rest_of_handle_cprop): Delete.
18677         (pass_cprop_hardreg): Point to copyprop_hardreg_forward.
18678
18679 2009-05-07  Jakub Jelinek  <jakub@redhat.com>
18680
18681         PR middle-end/40057
18682         * dojump.c (prefer_and_bit_test): Use immed_double_const instead of
18683         GEN_INT for 1 << bitnum.
18684         (do_jump) <case BIT_AND_EXPR>: Use build_int_cst_wide_type instead of
18685         build_int_cst_type.
18686
18687 2009-05-07  Uros Bizjak  <ubizjak@gmail.com>
18688
18689         * doc/md.texi (Standard Pattern Names For Generation) [sync_nand]:
18690         Remove wrong description of "nand" operation.
18691
18692 2009-05-06  Richard Guenther  <rguenther@suse.de>
18693             Adam Nemet  <anemet@caviumnetworks.com>
18694
18695         * gimple.def (GIMPLE_ASSIGN): Fix incorrect information in the
18696         comment.  Add that if LHS is not a gimple register, then RHS1 has
18697         to be a single object (GIMPLE_SINGLE_RHS).
18698
18699 2009-05-06  Adam Nemet  <anemet@caviumnetworks.com>
18700
18701         * expr.c (get_def_for_expr): Move it up in the file.
18702         (store_field): When expanding a bit-field store, look at the
18703         defining gimple stmt for the masking conversion.
18704
18705 2009-05-06  Janis Johnson  <janis187@us.ibm.com>
18706
18707         PR middle-end/39986
18708         * dfp.c (encode_decimal32, decode_decimal32, encode_decimal64,
18709         decode_decimal64, encode_decimal128, decode_decimal128): Avoid
18710         32-bit memcpy into long.
18711
18712 2009-05-06  Jakub Jelinek  <jakub@redhat.com>
18713
18714         * dwarf2out.c (new_reg_loc_descr): Don't ever create DW_OP_regX.
18715         (one_reg_loc_descriptor): Create DW_OP_regX here instead of calling
18716         new_reg_loc_descr.
18717         (loc_by_reference): If loc is DW_OP_regX, change it into DW_OP_bregX 0
18718         instead of appending DW_OP_deref*.
18719
18720 2009-05-06  Michael Matz  <matz@suse.de>
18721
18722         PR middle-end/40021
18723         * cfgexpand.c (maybe_cleanup_end_of_block): New static function.
18724         (expand_gimple_cond): Use it to cleanup CFG and superfluous jumps.
18725
18726 2009-05-06  Rafael Avila de Espindola  <espindola@google.com>
18727
18728         * Makefile.in (install-plugin): Fix srcdir handling.
18729
18730 2009-05-06  Andrey Belevantsev  <abel@ispras.ru>
18731
18732         * tree-ssa.c (execute_update_address_taken): Handle TARGET_MEM_REF
18733         when processing for not_regs_needed bitmap.
18734         * gimple.c (walk_stmt_load_store_addr_ops): When visiting address,
18735         handle TARGET_MEM_REF in lhs.  Check TMR_BASE for NULL while
18736         handling it for rhs.
18737
18738 2009-05-06  H.J. Lu  <hongjiu.lu@intel.com>
18739
18740         * config/i386/i386.md (unnamed inc/dec peephole): Use
18741         optimize_insn_for_size_p instead of optimize_size.
18742         * config/i386/predicates.md (incdec_operand): Likewise.
18743         (aligned_operand): Likewise.
18744         * config/i386/sse.md (divv8sf3): Likewise.
18745         (sqrtv8sf2): Likewise.
18746
18747 2009-05-06  H.J. Lu  <hongjiu.lu@intel.com>
18748
18749         * config/i386/i386.c (ix86_build_signbit_mask): Make it static.
18750
18751         * config/i386/i386-protos.h (ix86_build_signbit_mask): Removed.
18752
18753 2009-05-06  H.J. Lu  <hongjiu.lu@intel.com>
18754
18755         * config/i386/i386.md (*avx_<code><mode>3_finite): Replace
18756         ssemodesuffixf2c with avxmodesuffixf2c.
18757
18758 2009-05-06  Joseph Myers  <joseph@codesourcery.com>
18759
18760         PR c/40032
18761         * c-decl.c (grokdeclarator): Handle incomplete type of unnamed field.
18762
18763 2009-05-05  Jakub Jelinek  <jakub@redhat.com>
18764
18765         * tree.h: Remove DECL_BY_REFERENCE from private_flag comment.
18766         (struct tree_base): Adjust spacing for 8 bit boundaries.
18767         (struct tree_decl_common): Add decl_by_reference_flag bit.
18768         (DECL_BY_REFERENCE): Adjust.
18769         * print-tree.c (print_node): For VAR_DECL, PARM_DECL or RESULT_DECL,
18770         print DECL_BY_REFERENCE bit.
18771         * dbxout.c (DECL_ACCESSIBILITY_CHAR): Revert last change.
18772         * dwarf2out.c (loc_by_reference, gen_decl_die): Check
18773         DECL_BY_REFERENCE for all VAR_DECLs, not just non-static ones.
18774         (gen_variable_die): Likewise.  Check TREE_PRIVATE/TREE_PROTECTED
18775         unconditionally.
18776
18777         PR middle-end/39666
18778         * gimplify.c (gimplify_switch_expr): If case labels cover the whole
18779         range of the type, but default label is missing, add it with one
18780         of the existing labels instead of adding a new label for it.
18781
18782 2009-05-05  Joseph Myers  <joseph@codesourcery.com>
18783
18784         * dwarf.h: Remove.
18785
18786 2009-05-05  Rafael Avila de Espindola  <espindola@google.com>
18787
18788         * Makefile.in (enable_plugin, plugin_includedir): New.
18789         (install): Depend on install-plugin.
18790         (PLUGIN_HEADERS): New.
18791         (install-plugin): New.
18792         * config.gcc: Add vxworks-dummy.h to tm_file for x86 and x86-64.
18793
18794 2009-05-05  Richard Guenther  <rguenther@suse.de>
18795
18796         PR tree-optimization/40022
18797         * tree-ssa-phiprop.c (struct phiprop_d): Exchange vop_stmt for
18798         the only vuse.
18799         (phivn_valid_p): Fix tuplification error, simplify.
18800         (phiprop_insert_phi): Add dumps.
18801         (propagate_with_phi): Simplify.
18802
18803 2009-05-05  Richard Guenther  <rguenther@suse.de>
18804
18805         PR middle-end/40023
18806         * builtins.c (gimplify_va_arg_expr): Properly build the address.
18807
18808 2009-05-05  Shujing Zhao  <pearly.zhao@oracle.com>
18809
18810         * tree.h (strip_float_extensions): Remove duplicate declaration.
18811         (build_low_bits_mask, debug_fold_checksum, expand_function_end,
18812         expand_function_start, stack_protect_prologue, stack_protect_epilogue,
18813         block_ultimate_origin): Rearrange the declarations line to match the
18814         comment that indicates the .c file which the functions are defined.
18815         (dwarf2out_*, set_decl_rtl): Add comment.
18816         (get_base_address): Adjust comment.
18817         (change_decl_assembler_name, maybe_fold_*, build_addr): Rearrange the
18818         declarations line and add comment.
18819         (is_builtin_name): Add blank after function name, for clarity.
18820
18821 2009-05-04  Joseph Myers  <joseph@codesourcery.com>
18822
18823         * attribs.c (decl_attributes): Use %qE for identifiers in
18824         diagnostics.
18825         * cgraphunit.c (verify_cgraph_node): Translate function names to
18826         locale character set in diagnostics.
18827         * coverage.c (get_coverage_counts): Use %qE for identifiers in
18828         diagnostics.
18829         * doc/invoke.texi (-finstrument-functions-exclude-function-list):
18830         Document that functions are named in UTF-8.
18831         * expr.c (expand_expr_real_1): Translate function names to locale
18832         character set in diagnostics.
18833         * gimplify.c (omp_notice_variable, omp_is_private,
18834         gimplify_scan_omp_clauses): Use %qE for identifiers in
18835         diagnostics.
18836         * langhooks.c (lhd_print_error_function): Translate function names
18837         to locale character set.
18838         * langhooks.h (decl_printable_name): Document that return value is
18839         in internal character set.
18840         * stmt.c: Include pretty-print.h
18841         (tree_conflicts_with_clobbers_p): Use %qE for identifiers in
18842         diagnostics.
18843         (resolve_operand_name_1): Translate named operand name to locale
18844         character set.
18845         * stor-layout.c (finalize_record_size): Use %qE for identifiers in
18846         diagnostics.
18847         * toplev.c (announce_function): Translate function names to locale
18848         character set.
18849         (warn_deprecated_use): Use %qE for identifiers in diagnostics.
18850         (default_tree_printer): Use pp_identifier or translate identifiers
18851         to locale character set.  Mark "<anonymous>" for translation.
18852         * tree-mudflap.c (mx_register_decls, mudflap_finish_file): Use %qE
18853         for identifiers in diagnostics.
18854         * tree.c (handle_dll_attribute): Use %qE for identifiers in
18855         diagnostics.
18856         * varasm.c (output_constructor): Use %qE for identifiers in
18857         diagnostics.
18858
18859 2009-05-04  Rafael Avila de Espindola  <espindola@google.com>
18860
18861         * configure.ac: use ` ` instead of $()
18862         * configure: Regenerate.
18863
18864 2009-05-05  Ben Elliston  <bje@au.ibm.com>
18865
18866         * config/pa/linux-atomic.c: Eliminate conditional include of
18867         errno.h on non-LP64 systems to simplify build requirements.
18868
18869 2009-05-04  Joseph Myers  <joseph@codesourcery.com>
18870
18871         * c-common.c (handle_mode_attribute): Use %qE for identifiers in
18872         diagnostics.
18873         * c-decl.c (check_bitfield_type_and_width): Make orig_name a tree
18874         and pass value to identifier_to_locale.
18875         (warn_variable_length_array): Make name a tree.
18876         (grokdeclarator): Separate diagnostic texts for named and unnamed
18877         declarators.  Use %qE for named declarators.
18878         * c-parser.c (c_lex_one_token): Use %qE for identifiers in
18879         diagnostics.
18880         * c-pragma.c (pop_alignment, handle_pragma_pack): Use %qE for
18881         identifiers in diagnostics.
18882         * c-typeck.c (push_member_name, start_init): Pass identifiers to
18883         identifier_to_locale.  Mark "anonymous" strings for translation.
18884
18885 2009-05-04  Michael Eager <eager@eagercon.com>
18886
18887         * config/rs6000/rs6000.c (rs6000_legitimate_address): Allow
18888         address for DImode/DFmode only if double-precision FP regs.
18889
18890 2009-05-04  Michael Eager <eager@eagercon.com>
18891
18892         * config/rs6000/rs6000.c (rs6000_libcall_value): Add
18893         TARGET_SINGLE_FLOAT check.
18894
18895 2009-05-04  Michael Eager <eager@eagercon.com>
18896
18897         * config/rs6000/xilinx.h: Add CPP_SPEC for -mxilinx-fpu options.
18898
18899 2009-05-04  Michael Eager <eager@eagercon.com>
18900
18901         * gcc/config.gcc: (powerpc-xilinx-eabi*): Add tm t-xilinx
18902         * config/rs6000/t-xilinx: New
18903
18904 2009-05-04  Paolo Bonzini  <bonzini@gnu.org>
18905
18906         * doc/tm.texi (LEGITIMIZE_ADDRESS): Revise documentation.
18907         * gcc/defaults.h (LEGITIMIZE_ADDRESS): Delete.
18908         * gcc/explow.c (memory_address): Use target hook.
18909         * gcc/targhooks.c (default_legitimize_address): New.
18910         * gcc/targhooks.h (default_legitimize_address): New.
18911         * gcc/target.h (legitimize_address): New.
18912         * gcc/target-def.h (TARGET_LEGITIMIZE_ADDRESS): New.
18913         (TARGET_INITIALIZER): Include it.
18914         * gcc/system.h (LEGITIMIZE_ADDRESS): Poison.
18915
18916         * config/bfin/bfin-protos.h (legitimize_address): Remove.
18917         * config/bfin/bfin.c (legitimize_address): Remove.
18918         * config/bfin/bfin.h (LEGITIMIZE_ADDRESS): Remove.
18919         * config/m68hc11/m68hc11-protos.h (m68hc11_legitimize_address):
18920         Remove.
18921         * config/m68hc11/m68hc11.c (m68hc11_legitimize_address): Remove.
18922         * config/m68hc11/m68hc11.h (LEGITIMIZE_ADDRESS): Remove.
18923
18924         * gcc/config/arm/arm.h (LEGITIMIZE_ADDRESS, ARM_LEGITIMIZE_ADDRESS,
18925         THUMB_LEGITIMIZE_ADDRESS, THUMB2_LEGITIMIZE_ADDRESS): Delete.
18926         * gcc/config/s390/s390.h (LEGITIMIZE_ADDRESS): Delete.
18927         * gcc/config/m32c/m32c.h (LEGITIMIZE_ADDRESS): Delete.
18928         * gcc/config/sparc/sparc.h (LEGITIMIZE_ADDRESS): Delete.
18929         * gcc/config/m32r/m32r.h (LEGITIMIZE_ADDRESS): Delete.
18930         * gcc/config/i386/i386.h (LEGITIMIZE_ADDRESS): Delete.
18931         * gcc/config/sh/sh.h (LEGITIMIZE_ADDRESS): Delete.
18932         * gcc/config/avr/avr.h (LEGITIMIZE_ADDRESS): Delete.
18933         * gcc/config/m68hc11/m68hc11.h (LEGITIMIZE_ADDRESS): Delete.
18934         * gcc/config/iq2000/iq2000.h (LEGITIMIZE_ADDRESS): Delete.
18935         * gcc/config/mn10300/mn10300.h (LEGITIMIZE_ADDRESS): Delete.
18936         * gcc/config/m68k/m68k.h (LEGITIMIZE_ADDRESS): Delete.
18937         * gcc/config/score/score.h (LEGITIMIZE_ADDRESS): Delete.
18938         * gcc/config/pa/pa.h (LEGITIMIZE_ADDRESS): Delete.
18939         * gcc/config/mips/mips.h (LEGITIMIZE_ADDRESS): Delete.
18940         * gcc/config/alpha/alpha.h (LEGITIMIZE_ADDRESS): Delete.
18941         * gcc/config/frv/frv.h (LEGITIMIZE_ADDRESS): Delete.
18942         * gcc/config/spu/spu.h (LEGITIMIZE_ADDRESS): Delete.
18943         * gcc/config/xtensa/xtensa.h (LEGITIMIZE_ADDRESS): Delete.
18944         * gcc/config/cris/cris.h (LEGITIMIZE_ADDRESS): Delete.
18945         * gcc/config/rs6000/rs6000.h (LEGITIMIZE_ADDRESS): Delete.
18946         * gcc/config/picochip/picochip.h (LEGITIMIZE_ADDRESS): Delete.
18947
18948         * gcc/config/s390/s390-protos.h (legitimize_address): Delete.
18949         * gcc/config/m32c/m32c-protos.h (m32c_legitimize_address): Delete.
18950         * gcc/config/sparc/sparc-protos.h (legitimize_address): Delete.
18951         * gcc/config/i386/i386-protos.h (legitimize_address): Delete.
18952         * gcc/config/avr/avr-protos.h (legitimize_address): Delete.
18953         * gcc/config/mn10300/mn10300-protos.h (legitimize_address): Delete.
18954         * gcc/config/score/score-protos.h (score_legitimize_address): Delete.
18955         * gcc/config/arm/arm-protos.h (arm_legitimize_address,
18956         (thumb_legitimize_address): Delete.
18957         * gcc/config/pa/pa-protos.h (hppa_legitimize_address): Delete.
18958         * gcc/config/mips/mips-protos.h (mips_legitimize_address): Delete.
18959         * gcc/config/alpha/alpha-protos.h (alpha_legitimize_address): Delete.
18960         * gcc/config/frv/frv-protos.h (frv_legitimize_address): Delete.
18961         * gcc/config/spu/spu-protos.h (spu_legitimize_address): Delete.
18962         * gcc/config/xtensa/xtensa-protos.h (xtensa_legitimize_address):
18963         Delete.
18964         * gcc/config/rs6000/rs6000-protos.h (rs6000_legitimize_address):
18965         Delete.
18966
18967         * config/arm/arm.c (arm_legitimize_address): Maybe call Thumb version.
18968         * config/m32c/m32c.c (m32c_legitimize_address): Standardize.
18969         * config/m32r/m32r.c (m32r_legitimize_address): New.
18970         * config/m68k/m68k.c (m68k_legitimize_address): New.
18971         * config/score/score.c (score_legitimize_address): Standardize.
18972         * config/score/score3.c (score3_legitimize_address): Standardize.
18973         * config/score/score3.h (score3_legitimize_address): Adjust.
18974         * config/score/score7.c (score7_legitimize_address): Standardize.
18975         * config/score/score7.h (score7_legitimize_address): Adjust.
18976         * config/sh/sh.c (sh_legitimize_address): New.
18977         * config/iq2000/iq2000.c (iq2000_legitimize_address): New.
18978
18979         * gcc/config/s390/s390.c (legitimize_address): Rename to...
18980         (s390_legitimize_address): ... this.
18981         * gcc/config/sparc/sparc.c (legitimize_address): Rename to...
18982         (sparc_legitimize_address): ... this.
18983         * gcc/config/i386/i386.c (legitimize_address): Rename to...
18984         (ix86_legitimize_address): ... this.
18985         * gcc/config/avr/avr.c (legitimize_address): Rename to...
18986         (avr_legitimize_address): ... this.
18987         * gcc/config/mn10300/mn10300.c (legitimize_address): Rename to...
18988         (mn10300_legitimize_address): ... this.
18989         * config/alpha/alpha.c (alpha_legitimize_address): Wrap...
18990         (alpha_legitimize_address_1): ... the old alpha_legitimize_address.
18991         (alpha_expand_mov): Adjust call.
18992
18993         * config/frv/frv.c (frv_legitimize_address): Return x on failure.
18994         * config/spu/spu.c (spu_legitimize_address): Likewise.
18995         * config/xtensa/xtensa.c (xtensa_legitimize_address): Likewise.
18996         * config/rs6000/rs6000.c (rs6000_legitimize_address): Likewise.
18997
18998 2009-05-04  Joseph Myers  <joseph@codesourcery.com>
18999
19000         * intl.c (locale_encoding, locale_utf8): New.
19001         (gcc_init_libintl): Initialize locale_encoding and locale_utf8.
19002         * intl.h (locale_encoding, locale_utf8): Declare.
19003         * pretty-print.c: Include ggc.h.  Include iconv.h if HAVE_ICONV.
19004         (pp_base_tree_identifier, decode_utf8_char, identifier_to_locale):
19005         New.
19006         * pretty-print.h (pp_identifier): Call identifier_to_locale on ID
19007         argument.
19008         (pp_tree_identifier): Define to call pp_base_tree_identifier.
19009         (pp_base_tree_identifier): Declare as function.
19010         (identifier_to_locale): Declare.
19011         * Makefile.in (pretty-print.o): Update dependencies.
19012         * varasm.c (finish_aliases_1): Use %qE for identifiers in diagnostics.
19013
19014 2009-05-04  Richard Guenther  <rguenther@suse.de>
19015
19016         PR middle-end/40015
19017         * builtins.c (fold_builtin_memory_op): Do not decay to element
19018         type if the size matches the whole array.
19019
19020 2009-05-04  Kazu Hirata  <kazu@codesourcery.com>
19021
19022         * expmed.c (synth_mult): When trying out a shift, pass the result
19023         of a signed shift.
19024
19025 2009-05-04  Kazu Hirata  <kazu@codesourcery.com>
19026
19027         * expmed.c (shiftsub_cost): Rename to shiftsub0_cost.
19028         (shiftsub1_cost): New.
19029         (init_expmed): Compute shiftsub1_cost.
19030         (synth_mult): Optimize multiplications by constants of the form
19031         -(2^^m-1) for some constant positive integer m.
19032
19033 2009-05-03  Richard Guenther  <rguenther@suse.de>
19034
19035         PR c/39983
19036         * c-typeck.c (array_to_pointer_conversion): Do not built
19037         ADDR_EXPRs of arrays of pointer-to-element type.
19038         * c-gimplify.c (c_gimplify_expr): Revert change fixing
19039         up wrong ADDR_EXPRs after-the-fact.
19040         * c-common.c (strict_aliasing_warning): Strip pointer
19041         conversions for obtaining the original type.
19042         * builtins.c (fold_builtin_memset): Handle array types.
19043         (fold_builtin_memory_op): Handle folded POINTER_PLUS_EXPRs
19044         and array types
19045
19046 2009-05-03  Richard Guenther  <rguenther@suse.de>
19047
19048         PR middle-end/23329
19049         * tree-ssa.c (useless_type_conversion_p_1): Use get_deref_alias_set.
19050         Do not lose casts from array types with unknown extent to array
19051         types with known extent.
19052         * tree-ssa-copy.c (may_propagate_copy): Remove hack checking for
19053         alias set compatibility.
19054
19055 2009-05-03  Manuel López-Ibáñez  <manu@gcc.gnu.org>
19056
19057         * flags.h (extra_warnings): Delete.
19058         * toplev.c (process_options): Handle Wuninitialized here.
19059         * opts.c (extra_warnings): Delete.
19060         (set_Wextra): Delete.
19061         (common_handle_option): -Wextra can be handled automatically.
19062         * c-opts.c (c_common_handle_option): Delete obsolete code.
19063         (c_common_post_options): Simplify comment.
19064         * common.opt (W): Add Var.
19065         (Wextra): Add Var.
19066         (Wuninitialized): Initialize to -1.
19067
19068 2009-05-03  Adam Nemet  <anemet@caviumnetworks.com>
19069             Richard Guenther  <rguenther@suse.de>
19070
19071         * expr.c (get_def_for_expr): New function.
19072         (expand_expr_real_1) <PLUS_EXPR, MINUS_EXPR>: Adjust to work with
19073         SSA rather than trees.
19074         <MULT_EXPR>: Likewise.  Use subexp0 and subexp1 instead of
19075         TREE_OPERAND (exp, 0) and TREE_OPERAND (exp, 1).
19076
19077 2009-05-03  Joseph Myers  <joseph@codesourcery.com>
19078
19079         * c-common.c (reswords): Add _Imaginary.
19080         * c-common.c (enum rid): Add RID_IMAGINARY.
19081
19082 2009-05-03  Paolo Bonzini  <bonzini@gnu.org>
19083
19084         * tree.h (TYPE_VECTOR_OPAQUE): Fix documentation.
19085         Patch by Richard Guenther.
19086
19087 2009-05-03  Anatoly Sokolov  <aesok@post.ru>
19088
19089         * defaults.h (FRAME_POINTER_REQUIRED): Provide default.
19090         * doc/tm.texi (FRAME_POINTER_REQUIRED): Revise documentation.
19091         * config/alpha/alpha.h (FRAME_POINTER_REQUIRED): Delete.
19092         * config/s390/s390.h (FRAME_POINTER_REQUIRED): Delete.
19093         * config/spu/spu.h (FRAME_POINTER_REQUIRED): Delete.
19094         * config/sh/sh.h (FRAME_POINTER_REQUIRED): Delete.
19095         * config/pdp11/pdp11.h (FRAME_POINTER_REQUIRED): Delete.
19096         * config/stormy16/stormy16.h (FRAME_POINTER_REQUIRED): Delete.
19097         * config/m68hc11/m68hc11.h (FRAME_POINTER_REQUIRED): Delete.
19098         * config/iq2000/iq2000.h (FRAME_POINTER_REQUIRED): Delete.
19099         * config/mn10300/mn10300.h (FRAME_POINTER_REQUIRED): Delete.
19100         * config/ia64/ia64.h (FRAME_POINTER_REQUIRED): Delete.
19101         * config/m68k/m68k.h (FRAME_POINTER_REQUIRED): Delete.
19102         * config/rs6000/rs6000.h (FRAME_POINTER_REQUIRED): Delete.
19103         * config/picochip/picochip.h (FRAME_POINTER_REQUIRED): Delete.
19104         * config/mcore/mcore.h (FRAME_POINTER_REQUIRED): Delete.
19105         * config/h8300/h8300.h (FRAME_POINTER_REQUIRED): Delete.
19106         * config/v850/v850.h (FRAME_POINTER_REQUIRED): Delete.
19107
19108 2009-05-02  Richard Guenther  <rguenther@suse.de>
19109
19110         PR tree-optimization/39940
19111         * tree-ssa-pre.c (eliminate): Make sure we may propagate before
19112         doing so.
19113
19114 2009-05-02  Richard Guenther  <rguenther@suse.de>
19115
19116         PR middle-end/40001
19117         * tree-ssa.c (execute_update_addresses_taken): Properly check
19118         if we can mark a variable DECL_GIMPLE_REG_P.
19119         * gimple.c (is_gimple_reg): Re-order check for DECL_GIMPLE_REG_P
19120         back to the end of the function.
19121         (is_gimple_reg_type): Remove complex type special casing.
19122         * gimplify.c (gimplify_bind_expr): Do not set DECL_GIMPLE_REG_P
19123         if not optimizing.
19124
19125 2009-05-02  Ben Elliston  <bje@au.ibm.com>
19126
19127         * doc/collect2.texi (Collect2): Document search path behaviour
19128         when configured with --with-ld.
19129
19130 2009-05-02  Jan Hubicka  <jh@suse.cz>
19131
19132         * tree-ssa-coalesce.c (coalesce_cost): Do not take ciritical
19133         parameter; update callers.
19134         (coalesce_cost_edge): EH edges are costier because they needs
19135         splitting even if not critical and even more costier when there are
19136         multiple EH predecestors.
19137
19138 2009-05-02  Jan Hubicka  <jh@suse.cz>
19139
19140         * except.c (remove_eh_handler_and_replace): Handle updating after
19141         removing TRY blocks.
19142
19143 2009-05-02  Eric Botcazou  <ebotcazou@adacore.com>
19144
19145         * store-motion.c (compute_store_table): Add ENABLE_CHECKING guard.
19146
19147 2009-05-02  Steven Bosscher  <steven@gcc.gnu.org>
19148
19149         * varasm.c: Do not include c-pragma.h.
19150         * attribs.c: Do not incude c-common.h.
19151
19152 2009-05-01  Michael Matz  <matz@suse.de>
19153
19154         * calls.c (initialize_argument_information): Handle SSA names like
19155         decls with a non MEM_P DECL_RTL.
19156
19157 2009-05-01  Steven Bosscher  <steven@gcc.gnu.org>
19158
19159         * ipa-reference.c: Do not include c-common.h, include splay-tree.h.
19160         * ipa-utils.c: Likewise.
19161         * ipa-type-escape.c: Likewise.
19162         * cgraphunit.c Do not include c-common.h.
19163         * ipa-pure-const.c: Likewise.
19164         * tree-if-conv.c: Likewise.
19165         * matrix-reorg.c: Do not include c-common.h and c-tree.h.
19166         * ipa-struct-reorg.c: Likewise.
19167         * tree-nomudflap.c: Likewise.
19168         * tree-ssa-structalias.c: Likewise.
19169
19170 2009-05-01  Steven Bosscher  <steven@gcc.gnu.org>
19171
19172         * store-motion.c: Many cleanups to make this pass a first-class
19173         citizen instead of an appendix to gcse load motion.  Add TODO list
19174         to make this pass faster/cleaner/better.
19175
19176         (struct ls_expr): Post gcse.c-split cleanups.
19177         Rename to st_expr.  Rename "loads" field to "antic_stores".  Rename
19178         "stores" field to "avail_stores".
19179         (pre_ldst_mems): Rename to store_motion_mems.
19180         (pre_ldst_table): Rename to store_motion_mems_table.
19181         (pre_ldst_expr_hash): Rename to pre_st_expr_hash, update users.
19182         (pre_ldst_expr_eq): Rename to pre_st_expr_eq, update users.
19183         (ldst_entry): Rename to st_expr_entry, update users.
19184         (free_ldst_entry): Rename to free_st_expr_entry, update users.
19185         (free_ldst_mems): Rename to free_store_motion_mems, update users.
19186         (enumerate_ldsts): Rename to enumerate_store_motion_mems,
19187         update caller.
19188         (first_ls_expr): Rename to first_st_expr, update users.
19189         (next_ls_expr): Rename to next_st_expr, update users.
19190         (print_ldst_list): Rename to print_store_motion_mems.  Print names of
19191         fields properly for store motion instead of names inherited from load
19192         motion in gcse.c.
19193         (ANTIC_STORE_LIST, AVAIL_STORE_LIST): Remove.
19194         (LAST_AVAIL_CHECK_FAILURE): Explain what this is.  Undefine when we
19195         are done with it.
19196
19197         (ae_kill): Rename to st_kill, update users.
19198         (ae_gen): Rename to st_avloc, update users.
19199         (transp): Rename to st_transp, update users.
19200         (pre_insert_map): Rename to st_insert_map, update users.
19201         (pre_delete_map): Rename to st_delete_map, update users.
19202         (insert_store, build_store_vectors, free_store_memory,
19203         one_store_motion_pass): Update for abovementioned changes.
19204
19205         (gcse_subst_count, gcse_create_count): Remove.
19206         (one_store_motion_pass): New statistics counters "n_stores_deleted"
19207         and "n_stores_created", local variables.
19208
19209         (extract_mentioned_regs, extract_mentioned_regs_1): Rewrite to
19210         use for_each_rtx.
19211
19212         (regvec, compute_store_table_current_insn): Remove.
19213         (reg_set_info, reg_clear_last_set): Remove.
19214         (compute_store_table): Use DF caches instead of local dataflow
19215         solvers.
19216
19217 2009-05-01  Joseph Myers  <joseph@codesourcery.com>
19218
19219         * c-objc-common.c (c_tree_printer): Print identifiers with
19220         pp_identifier, not pp_string.  Mark "({anonymous})" for
19221         translation.
19222         * c-pretty-print.c (pp_c_ws_string): New.
19223         (pp_c_cv_qualifier, pp_c_type_specifier,
19224         pp_c_specifier_qualifier_list, pp_c_parameter_type_list,
19225         pp_c_storage_class_specifier, pp_c_function_specifier,
19226         pp_c_attributes, pp_c_bool_constant, pp_c_constant,
19227         pp_c_primary_expression, pp_c_postfix_expression,
19228         pp_c_unary_expression, pp_c_shift_expression,
19229         pp_c_relational_expression, pp_c_equality_expression,
19230         pp_c_logical_and_expression, pp_c_logical_or_expression): Mostly
19231         use pp_string and pp_c_ws_string in place of pp_identifier and
19232         pp_c_identifier for non-identifiers.  Mark English strings for
19233         translation.
19234         * c-pretty-print.h (pp_c_ws_string): Declare.
19235
19236 2009-04-30  Paul Pluzhnikov  <ppluzhnikov@google.com>
19237             Roland McGrath <roland@redhat.com>
19238
19239         * configure.ac (HAVE_LD_BUILDID): New check for ld --build-id support.
19240         (ENABLE_LD_BUILDID): New configuration option.
19241         * gcc.c [HAVE_LD_BUILDID and ENABLE_LD_BUILDID]
19242         (LINK_BUILDID_SPEC): New macro.
19243         (init_spec): If defined, prepend it between LINK_EH_SPEC and
19244         link_spec.
19245         * doc/install.texi: Document --enable-linker-build-id option.
19246         * configure: Rebuild.
19247         * config.in: Rebuild.
19248
19249 2009-04-30  Adam Nemet  <anemet@caviumnetworks.com>
19250
19251         * config/mips/mips.h (FRAME_GROWS_DOWNWARD,
19252         MIPS_GP_SAVE_AREA_SIZE): Define new macros.
19253         (STARTING_FRAME_OFFSET): Return 0 if FRAME_GROWS_DOWNWARD.  Use
19254         MIPS_GP_SAVE_AREA_SIZE.
19255         * config/mips/mips.c (struct mips_frame_info): Update comment
19256         before arg_pointer_offset and hard_frame_pointer_offset.
19257         (mips_compute_frame_info): Update diagram before function: to
19258         correctly use stack_pointer_rtx for fp_sp_offset and gp_sp_offset, to
19259         indicate the position of frame_pointer_rtx with -fstack-protector and
19260         to show args_size.  Don't allocate cprestore area for leaf functions
19261         if FRAME_GROWS_DOWNWARD.  Use MIPS_GP_SAVE_AREA_SIZE to set
19262         cprestore_size.
19263         (mips_initial_elimination_offset): Update for FRAME_GROWS_DOWNWARD.
19264
19265 2009-04-30  Michael Matz  <matz@suse.de>
19266
19267         PR tree-optimization/39955
19268         * config/rs6000/rs6000.c (rs6000_check_sdmode): Also check SSA_NAMEs.
19269
19270 2009-04-30  Dave Korn  <dave.korn.cygwin@gmail.com>
19271
19272         * ira.c (setup_cover_and_important_classes):  Use safe macro
19273         REG_CLASS_FOR_CONSTRAINT instead of calling regclass_for_constraint
19274         directly.
19275         * genpreds.c (write_tm_preds_h):  Output suitable definition of
19276         REG_CLASS_FOR_CONSTRAINT.
19277
19278 2009-04-30  Rafael Avila de Espindola  <espindola@google.com>
19279
19280         * alloc-pool.c (alloc_pool_descriptor): Use an insert_opion value
19281         instead of an int.
19282         * bitmap.c (bitmap_descriptor): Likewise.
19283         * ggc-common.c (loc_descriptor): Likewise.
19284         * varray.c (varray_descriptor): Likewise.
19285         * vec.c (vec_descriptor): Likewise.
19286
19287 2009-04-30  Eric Botcazou  <ebotcazou@adacore.com>
19288
19289         * Makefile.in (dce.o): Add $(EXCEPT_H).
19290         * dce.c: Include except.h and delete redundant vector definitions.
19291         (deletable_insn_p): Return false for non-call insns that can throw
19292         if DF is running.
19293
19294 2009-04-30  Steven Bosscher  <steven@gcc.gnu.org>
19295
19296         * gcse.c (ae_gen): Remove.
19297         (can_assign_to_reg_p): Rename to can_assign_to_reg_without_clobbers_p
19298         and make non-static function to make it available in store-motion.c.
19299         Update call sites with search-and-replace.
19300         (enumerate_ldsts, reg_set_info, reg_clear_last_set, store_ops_ok,
19301         extract_mentioned_regs, extract_mentioned_regs_helper,
19302         find_moveable_store, compute_store_table, load_kills_store, find_loads,
19303         store_killed_in_insn, store_killed_after, store_killed_before,
19304         build_store_vectors, insert_insn_start_basic_block, insert-store,
19305         remove_reachable_equiv_notes, replace_store_insn, delete_store,
19306         free_store_memory, one_store_motion_pass, gate_rtl_store_motion,
19307         execute_rtl_store_motion, pass_rtl_store_motion): Move to...
19308         * store-motion.c: ...new file.  Also copy data structures from gcse.c
19309         and clean up to remove parts not used by store motion.
19310         * rtl.h (can_assign_to_reg_without_clobbers_p): Add prototype.
19311         * Makefile.in (store-motion.o): New rule. Add to OBJS-common.
19312
19313 2009-04-30  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
19314
19315         PR target/38571
19316         * config/arm/arm.h (FUNCTION_BOUNDARY): Set to 16 for thumb
19317         when optimizing for size.
19318
19319 2009-04-30  Hans-Peter Nilsson  <hp@axis.com>
19320
19321         * gcse.c (gcse_constant_p): Fix typo in last change.
19322
19323 2009-04-30  Rafael Avila de Espindola  <espindola@google.com>
19324
19325         * plugin.c: Include plugin-version.h only if ENABLE_PLUGIN is defined.
19326
19327 2009-04-30  Andreas Krebbel  <krebbel1@de.ibm.com>
19328
19329         * gcse.c (gcse_constant_p): Make sure the constant is sharable.
19330
19331 2009-04-29  James E. Wilson  <wilson@codesourcery.com>
19332
19333         * config/mips/mips.c (mips_add_offset): Use gen_int_mode for
19334         CONST_HIGH_PART result.
19335
19336 2009-04-29  Anatoly Sokolov  <aesok@post.ru>
19337
19338         * config/avr/avr.c (initial_elimination_offset): Rename to
19339         avr_initial_elimination_offset.
19340         (frame_pointer_required_p): Rename to avr_frame_pointer_required_p,
19341         change return type to bool.
19342         (avr_can_eliminate): New function.
19343         * config/avr/avr.h (CAN_ELIMINATE): Use avr_can_eliminate.
19344         (FRAME_POINTER_REQUIRED): Use avr_frame_pointer_required_p.
19345         (INITIAL_ELIMINATION_OFFSET): Use avr_initial_elimination_offset.
19346         * config/avr/avr-protos.h (initial_elimination_offset): Rename to
19347         avr_initial_elimination_offset.
19348         (frame_pointer_required_p): Rename to avr_frame_pointer_required_p.
19349         (avr_initial_elimination_offset): Define.
19350
19351 2009-04-29  Eric Botcazou  <ebotcazou@adacore.com>
19352             Steven Bosscher  <steven@gcc.gnu.org>
19353
19354         PR rtl-optimization/39938
19355         * Makefile.in (cfgrtl.o): Add $(INSN_ATTR_H).
19356         * cfgrtl.c: Include insn-attr.h.
19357         (rest_of_pass_free_cfg): New function.
19358         (pass_free_cfg): Use rest_of_pass_free_cfg as execute function.
19359         * resource.c (init_resource_info): Remove call to df_analyze.
19360
19361 2009-04-29  Richard Guenther  <rguenther@suse.de>
19362
19363         PR target/39943
19364         * config/i386/i386.c (ix86_vectorize_builtin_conversion): Only
19365         allow conversion to signed integers.
19366
19367 2009-04-29  Richard Guenther  <rguenther@suse.de>
19368
19369         * tree-cfg.c (verify_gimple_assign_binary): Allow vector
19370         shifts of floating point vectors if the shift amount is
19371         a constant multiple of the element size.
19372
19373 2009-04-29  Andreas Krebbel  <krebbel1@de.ibm.com>
19374             Michael Matz  <matz@suse.de>
19375
19376         PR middle-end/39927
19377         PR bootstrap/39929
19378         * tree-outof-ssa.c (emit_partition_copy): New function.
19379         (insert_partition_copy_on_edge, insert_rtx_to_part_on_edge,
19380         insert_part_to_rtx_on_edge): Perform the partition base var
19381         copy using emit_partition_copy.
19382         (insert_value_copy_on_edge): Convert constants to the right mode.
19383         (insert_rtx_to_part_on_edge): Add UNSIGNEDSRCP parameter.
19384         (elim_create): Pass the sign of the src to insert_rtx_to_part_on_edge.
19385
19386 2009-04-29  Bernd Schmidt  <bernd.schmidt@analog.com>
19387
19388         * config/bfin/bfin.c (bfin_optimize_loop): If we need a scratch reg,
19389         scan backwards to try to find a constant to initialize it.
19390
19391         * config/bfin/bfin.c (bfin_optimize_loop): When looking for the last
19392         insn before the loop_end instruction, don't look past labels.
19393
19394 2009-04-29  Richard Guenther  <rguenther@suse.de>
19395
19396         PR middle-end/39937
19397         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Do not
19398         loose type conversions.
19399         (forward_propagate_addr_expr): Fix tuplification bug.  Remove
19400         stmts only if there are no uses of its definition.
19401
19402 2009-04-29  Bernd Schmidt  <bernd.schmidt@analog.com>
19403
19404         * config/bfin/bfin.h (splitting_loops): Declare.
19405         * config/bfin/bfin-protos.h (WA_05000257, WA_05000283, WA_05000315):
19406         Reorder bit definitions to be ascending.
19407         (WA_LOAD_LCREGS, ENABLE_WA_LOAD_LCREGS): New macros.
19408         * config/bfin/bfin.c (splitting_loops): New variable.
19409         (bfin_cpus): Add WA_LOAD_LCREGS as needed.
19410         (struct loop_info): Remove members INIT and LOOP_INIT.
19411         (bfin_optimize_loop): Don't set them.  Reorder the code that generates
19412         the LSETUP sequence.  Allow LC to be loaded from any register, but
19413         also add a case to push/pop a PREG scratch if ENABLE_WA_LOAD_LCREGS.
19414         (bfin_reorg_loops): When done, split all BB_ENDs with splitting_loops
19415         set to 1.
19416         * config/bfin/bfin.md (loop_end splitter): Use splitting_loops instead
19417         of reload_completed.
19418
19419         From Jie Zhang:
19420         * config/bfin/bfin.md (movsi_insn): Refine constraints.
19421
19422 2009-04-29  Rafael Avila de Espindola  <espindola@google.com>
19423
19424         * Makefile.in (PLUGIN_VERSION_H): New.
19425         (OBJS-common): Remove plugin-version.o.
19426         (plugin.o): Depend on (PLUGIN_VERSION_H).
19427         (plugin-version.o): Remove.
19428         * configure: Regenerate
19429         * configure.ac: Create plugin-version.h.
19430         * gcc-plugin.h (plugin_gcc_version): Remove.
19431         (plugin_default_version_check): Change signature.
19432         * plugin-version.c: Remove.
19433         * plugin.c: Include plugin-version.h.
19434         (str_plugin_gcc_version_name): Remove.
19435         (try_init_one_plugin): Pass gcc version to plugin_init.
19436         (plugin_default_version_check): Both gcc and plugin versions are now
19437         arguments.
19438
19439 2009-04-29  Bernd Schmidt  <bernd.schmidt@analog.com>
19440
19441         * config/bfin/bfin.c (bfin_optimize_loop): Unify handling of
19442         problematic last insns.  Test for TYPE_CALL rather than CALL_P.
19443         Remove special case testing for last insn of inner loops. Don't fail
19444         if the loop ends with a jump, emit an extra nop instead.
19445
19446         * config/bfin/bfin.c (bfin_register_move_cost): Test for subsets of
19447         DREGS rather than comparing directly.  Remove code that tries to
19448         account for latencies.
19449
19450 2009-04-29  Richard Guenther  <rguenther@suse.de>
19451
19452         PR tree-optimization/39941
19453         * tree-ssa-pre.c (eliminate): Schedule update-ssa after
19454         eliminating an indirect call.
19455
19456 2009-04-29  Richard Guenther  <rguenther@suse.de>
19457
19458         * tree-cfg.c (verify_types_in_gimple_reference): Add require_lvalue
19459         parameter.  Allow invariants as base if !require_lvalue.
19460         (verify_gimple_assign_single): Adjust.
19461
19462 2009-04-29  Bernd Schmidt  <bernd.schmidt@analog.com>
19463
19464         * config/bfin/bfin.md (sp_or_sm, spm_string, spm_name): New macro.
19465         (ss<spm_name>hi3, ss<spm_name>hi3_parts, ss<spm_name>hi3_low_parts,
19466         ss<spm_name_hi3_high_parts): New patterns, replacing ssaddhi3,
19467         ssubhi3, ssaddhi3_parts and sssubhi3_parts.
19468         (flag_mulhi3_parts): Produce a HImode output rather than trying to set
19469         a VEC_SELECT.
19470         * config/bfin/bfin.c (bfin_expand_builtin,
19471         case BFIN_BUILTIN_CPLX_SQU): Adjust accordingly.
19472
19473 2009-04-28  Richard Guenther  <rguenther@suse.de>
19474
19475         * tree-vect-loop.c (get_initial_def_for_induction): Use
19476         correct types for pointer increment.
19477
19478 2009-04-29  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
19479
19480         * toplev.c (print_version): Update GMP version string calculation.
19481
19482 2009-04-28  Eric Botcazou  <ebotcazou@adacore.com>
19483
19484         PR rtl-optimization/39938
19485         * resource.c (init_resource_info): Add call to df_analyze.
19486
19487 2009-04-28  Uros Bizjak  <ubizjak@gmail.com>
19488
19489         * config/alpha/alpha.md (usegp): Cast the result of
19490         alpha_find_lo_sum_using_gp to enum attr_usegp.
19491         * config/alpha/alpha.c (override_options): Remove end-of-structure
19492         marker element from cpu_table.  Use array size of cpu_table to handle
19493         -mcpu and -mtune options.
19494         (tls_symbolic_operand_type): Change 0 to TLS_MODEL_NONE.
19495
19496 2009-04-28  Joseph Myers  <joseph@codesourcery.com>
19497
19498         * config.gcc (powerpc*-*-* | rs6000-*-*): Add
19499         rs6000/option-defaults.h to tm_file.  Support cpu_32, cpu_64,
19500         tune_32 and tune_64.
19501         * doc/install.texi (--with-cpu-32, --with-cpu-64): Document
19502         support on PowerPC.
19503         * config/rs6000/rs6000.h (OPTION_DEFAULT_SPECS): Move to ...
19504         * config/rs6000/option-defaults.h: ... here.  New file.
19505         (OPT_64, OPT_32): Define.
19506         (MASK_64BIT): Define to 0 if not already defined.
19507         (OPT_ARCH64, OPT_ARCH32): Define.
19508         (OPTION_DEFAULT_SPECS): Add entries for cpu_32, cpu_64, tune_32
19509         and tune_64.
19510
19511 2009-04-28  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
19512
19513         * config/arm/arm.c (arm_override_options): Emit error on using
19514         fpa with AAPCS.
19515
19516 2009-04-28  Uros Bizjak  <ubizjak@gmail.com>
19517
19518         PR rtl-optimization/39914
19519         * ira-conflicts.c (ira_build_conflicts): Prohibit call used
19520         registers for allocnos created from user-defined variables only
19521         when not optimizing.
19522
19523 2009-04-28  Richard Guenther  <rguenther@suse.de>
19524
19525         PR middle-end/39937
19526         * fold-const.c (fold_binary): Use distribute_real_division only
19527         on float types.
19528
19529 2009-04-28  Steve Ellcey  <sje@cup.hp.com>
19530
19531         * config.gcc (hppa*64*-*-hpux11*): Set use_gcc_stdint and
19532         add hpux-stdint.h to tm_file.
19533         (hppa[12]*-*-hpux11*): Ditto.
19534         (ia64*-*-hpux*): Ditto.
19535         * config/hpux-stdint.h: New.
19536         * config/ia64/hpux.h (TARGET_OS_CPP_BUILTINS): Set
19537         __STDC_EXT__ for all compiles.
19538         * config/pa/pa-hpux.h: Ditto.
19539         * config/pa/pa-hpux10.h: Ditto.
19540         * config/pa/pa-hpux11.h: Ditto.
19541
19542 2009-04-28  Catherine Moore  <clm@codesourcery.com>
19543
19544         * debug.h (set_name): Add comment.
19545
19546 2009-04-28  Andrew Pinski  <pinskia@gmail.com>
19547
19548         PR target/39929
19549         * config/darwin.c (machopic_gen_offset): Check
19550         currently_expanding_to_rtl if current_ir_type returns IR_GIMPLE.
19551         * config/arm/arm.c (require_pic_register): Likewise.
19552
19553 2009-04-28  Paolo Bonzini  <bonzini@gnu.org>
19554
19555         * config/m32c/m32c.c (TARGET_PROMOTE_FUNCTION_RETURN,
19556         m32c_promote_function_return, TARGET_PROMOTE_PROTOTYPES,
19557         m32c_promote_prototypes): Delete.
19558
19559 2009-04-28  Michael Matz  <matz@suse.de>
19560
19561         PR middle-end/39922
19562         * tree-outof-ssa.c (insert_value_copy_on_edge): Don't convert
19563         constants.
19564
19565 2009-04-28  Richard Guenther  <rguenther@suse.de>
19566
19567         * tree-vect-stmts.c (vect_get_vec_def_for_operand): Fix type error.
19568
19569 2009-04-28  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
19570
19571         * config/arm/arm-cores.def: Add support for arm1156t2f-s.
19572         * doc/invoke.texi (ARM Options): Document support for arm1156t2f-s.
19573         * config/arm/arm-tune.md: Regenerate.
19574
19575 2009-04-28  Alexander Monakov  <amonakov@ispras.ru>
19576
19577         * sel-sched-ir.c (maybe_tidy_empty_bb): Do not attempt to delete a
19578         block if there are complex incoming edges.
19579         (sel_merge_blocks): Remove useless assert.
19580         (sel_redirect_edge_and_branch): Check that edge was redirected.
19581         * sel-sched-ir.h (_eligible_successor_edge_p): Remove assert.
19582         (sel_find_rgns): Delete declaration.
19583         * sel-sched.c (purge_empty_blocks): Attempt to remove first block of
19584         the region when it is not a preheader.
19585
19586 2009-04-28  Uros Bizjak  <ubizjak@gmail.com>
19587
19588         PR c/39323
19589         * config/alpha/elf.h (MAX_OFILE_ALIGNMENT): Sync with elfos.h
19590
19591 2009-04-28  Richard Guenther  <rguenther@suse.de>
19592
19593         * tree.h (SSA_NAME_VALUE): Remove.
19594         (struct tree_ssa_name): Remove value_handle member.
19595         * tree-vrp.c (execute_vrp): Initialize/free the value-handle
19596         array for jump threading.
19597         * tree-ssa-propagate.c (ssa_prop_init): Do not initialize
19598         SSA_NAME_VALUEs.
19599         * print-tree.c (print_node): Do not dump SSA_NAME_VALUEs.
19600         * tree-flow.h (threadedge_initialize_values): Declare.
19601         (threadedge_finalize_values): Likewise.
19602         * tree-ssa-threadedge.c (ssa_name_values): New global variable.
19603         (SSA_NAME_VALUE): Define.
19604         (threadedge_initialize_values): New function.
19605         (threadedge_finalize_values): Likewise.
19606         * tree-ssa-dom.c (ssa_name_values): New global variable.
19607         (SSA_NAME_VALUE): Define.
19608         (tree_ssa_dominator_optimize): Initialize/free the value-handle array.
19609
19610 2009-04-28  Ira Rosen  <irar@il.ibm.com>
19611
19612         * tree-vect-loop-manip.c (vect_create_cond_for_alias_checks):
19613         Use REPORT_VECTORIZED_LOCATIONS instead
19614         REPORT_VECTORIZED_LOOPS.
19615         * tree-vectorizer.c (vect_verbosity_level): Make static.
19616         (vect_loop_location): Rename to vect_location.
19617         (vect_set_verbosity_level): Update comment.
19618         (vect_set_dump_settings): Use REPORT_VECTORIZED_LOCATIONS
19619         and vect_location.
19620         (vectorize_loops): Fix comment. Use REPORT_VECTORIZED_LOCATIONS
19621         and vect_location. Use REPORT_UNVECTORIZED_LOCATIONS
19622         instead REPORT_UNVECTORIZED_LOOPS.
19623         * tree-vectorizer.h (enum vect_def_type): Rename vect_invariant_def
19624         and vect_loop_def to vect_external_def and vect_internal_def.
19625         (enum verbosity_levels): Rename REPORT_VECTORIZED_LOOPS
19626         and REPORT_UNVECTORIZED_LOOPS to REPORT_VECTORIZED_LOCATIONS and
19627         REPORT_UNVECTORIZED_LOCATIONS.
19628         (enum vect_relevant): Update comment. Rename vect_unused_in_loop
19629         and vect_used_in_loop and to vect_unused_in_scope and
19630         vect_used_in_scope.
19631         (STMT_VINFO_RELEVANT_P): Use vect_unused_in_scope.
19632         (vect_verbosity_level): Remove declaration.
19633         (vect_analyze_operations): Likewise.
19634         (vect_analyze_stmt): Declare.
19635         * tree-vect-loop.c (vect_determine_vectorization_factor): Use
19636         REPORT_UNVECTORIZED_LOCATIONS.
19637         (vect_get_loop_niters): Fix indentation.
19638         (vect_analyze_loop_form): Use REPORT_UNVECTORIZED_LOCATIONS.
19639         (vect_analyze_loop_operations): New function.
19640         (vect_analyze_loop): Call vect_analyze_loop_operations instead of
19641         vect_analyze_operations.
19642         (vect_is_simple_reduction): Use new names.
19643         (vectorizable_live_operation, vect_transform_loop): Likewise.
19644         * tree-vect-data-refs.c (vect_check_interleaving): Add a return value
19645         to specify whether the data references can be a part of interleaving
19646         chain.
19647         (vect_analyze_data_ref_dependence): Use new names.
19648         (vect_analyze_data_refs_alignment, vect_analyze_data_refs): Likewise.
19649         (vect_create_addr_base_for_vector_ref): Remove redundant code.
19650         * tree-vect-patterns.c (widened_name_p): Use new names.
19651         (vect_recog_dot_prod_pattern): Likewise.
19652         * tree-vect-stmts.c (vect_stmt_relevant_p): Use new names.
19653         (process_use, vect_mark_stmts_to_be_vectorized,
19654         vect_model_simple_cost, vect_model_store_cost,
19655         vect_get_vec_def_for_operand, vect_get_vec_def_for_stmt_copy,
19656         vectorizable_call, vectorizable_conversion, vectorizable_assignment,
19657         vectorizable_operation, vectorizable_type_demotion,
19658         vectorizable_type_promotion, vectorizable_store, vectorizable_load,
19659         vectorizable_condition): Likewise.
19660         (vect_analyze_operations): Split into vect_analyze_loop_operations
19661         and ...
19662         (vect_analyze_stmt): ... new function.
19663         (new_stmt_vec_info): Use new names.
19664         (vect_is_simple_use): Use new names and fix comment.
19665         * tree-vect-slp.c (vect_get_and_check_slp_defs): Use new names.
19666         (vect_build_slp_tree, vect_analyze_slp, vect_schedule_slp): Likewise.
19667
19668 2009-04-28  Uros Bizjak  <ubizjak@gmail.com>
19669
19670         PR target/39911
19671         * config/i386/i386.c (print_operand) ['Z']: Handle floating point
19672         and integer modes for x87 operands.  Do not ICE for unsupported size,
19673         generate error instead.  Generate error for unsupported operand types.
19674         ['z']: Do not handle HImode memory operands specially.  Warning
19675         for floating-point operands.  Fallthru to 'Z' for unsupported operand
19676         types.  Do not ICE for unsupported size, generate error instead.
19677         (output_387_binary_op): Use %Z to output operands.
19678         (output_fp_compare): Ditto.
19679         (output_387_reg_move): Ditto.
19680
19681 2009-04-28  Ben Elliston  <bje@au.ibm.com>
19682
19683         PR c++/35652
19684         Revert:
19685
19686         2009-03-27  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
19687
19688         * builtins.c (c_strlen): Do not warn here.
19689         * c-typeck.c (build_binary_op): Adjust calls to pointer_int_sum.
19690         * c-common.c (pointer_int_sum): Take an explicit location.
19691         Warn about offsets out of bounds.
19692         * c-common.h (pointer_int_sum): Adjust declaration.
19693
19694 2009-04-27  Ian Lance Taylor  <iant@google.com>
19695
19696         * collect2.c (is_ctor_dtor): Change type of ret field in struct
19697         names to symkind.
19698         * dce.c (run_fast_df_dce): Change type of old_flags to int.
19699         * df-core.c (df_set_flags): Change return type to int.  Change
19700         type of old_flags to int.
19701         (df_clear_flags): Likewise.
19702         * df-scan.c (df_def_record_1): Change 0 to VOIDmode.
19703         (df_get_conditional_uses): Likewise.
19704         * df.h (df_set_flags, df_clear_flags): Update declarations.
19705         * dwarf2out.c (struct indirect_string_node): Change type of form
19706         field to enum dwarf_form.
19707         (AT_string_form): Change return type to enum dwarf_form.
19708         * fixed-value.c (fixed_compare): Add cast to enum type.
19709         * fwprop.c (update_df): Change 0 to VOIDmode.
19710         * gensupport.c: Change 0 to UNKNOWN.
19711         * gimple.h (gimple_cond_code): Add cast to enum type.
19712         * haifa-sched.c (reemit_notes): Add cast to enum type.
19713         * hooks.c (hook_int_void_no_regs): Remove function.
19714         * hooks.h (hook_int_void_no_regs): Remove declaration.
19715         * optabs.c (expand_widen_pattern_expr): Change 0 to VOIDmode.
19716         * predict.c (combine_predictions_for_insn): Add casts to enum type.
19717         * real.c (real_arithmetic): Add cast to enum type.
19718         (real_compare): Likewise.
19719         * target.h (struct gcc_target): Change return type of
19720         branch_target_register_class to enum reg_class.
19721         * target-def.h (TARGET_BRANCH_TARGET_REGISTER_CLASS): Define as
19722         default_branch_target_register_class.
19723         * targhooks.c (default_branch_target_register_class): New function.
19724         * targhooks.h (default_branch_target_register_class): Declare.
19725         * tree-data-ref.c (print_direction_vector): Add cast to enum type.
19726         * tree-vect-data-refs.c (vect_supportable_dr_alignment): Remove
19727         cast to int.
19728         * tree-vect-loop.c (vect_create_epilog_for_reduction): Change 0 to
19729         ERROR_MARK.
19730         * tree-vect-slp.c (vect_build_slp_tree): Change 0 to
19731         vect_uninitialized_def.  Change 0 to ERROR_MARK.
19732         * tree-vect-stmts.c (supportable_widening_operation): Don't
19733         initialize icode1 and icode2.
19734         * tree-vectorizer.h (enum vect_def_type): Add vect_uninitialized_def.
19735         * config/sol2-c.c (cmn_err_length_specs): Change 0 to FMT_LEN_none
19736         and to STD_C89.
19737         (cmn_err_flag_specs): Change 0 to STD_C89.
19738         (cmn_err_char_table): Likewise.
19739         * config/arm/arm.c (get_arm_condition_code): Change type of code
19740         to enum arm_cond_code.
19741         (IWMMXT_BUILTIN): Change 0 to UNKNOWN.
19742         (IWMMXT_BUILTIN2): Likewise.
19743         (neon_builtin_type_bits): Don't define typedef.
19744         (neon_builtin_datum): Change type of bits field to int.
19745         (arm_expand_neon_args): Add cast to enum type.
19746         * config/ia64/ia64.c (tls_symbolic_operand_type): Change 0 to
19747         TLS_MODEL_NONE.
19748         * config/i386/i386.c (bdesc_multi_arg): Change 0 to UNKNOWN.  Add
19749         casts to enum type.
19750         * config/mips/mips.c (LOONGSON_BUILTIN_ALIAS): Change 0 to
19751         MIPS_FP_COND_f.
19752         * config/mips/mips.md (jal_macro): Return enum constant.
19753         (single_insn): Likewise.
19754         * config/rs6000/rs6000.c (bdesc_altivec_preds): Change 0 to
19755         CODE_FOR_nothing.
19756         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
19757         casts to enum type.
19758         * config/s390/s390.c (s390_tune_flags): Change type to int.
19759         (s390_arch_flags): Likewise.
19760         (s390_handle_arch_option): Change flags field of struct pta to int.
19761         * config/s390/s390.h (s390_tune_flags): Update declaration.
19762         (s390_arch_flags): Likewise.
19763         * config/sh/sh.c (prepare_move_operands): Compare
19764         tls_symbolic_operand result with enum constant.
19765         (sh_reorg): Change PUT_MODE to PUT_REG_NOTE_KIND.
19766         (sh_expand_prologue): Add cast to enum type.
19767         (sh_expand_epilogue): Likewise.
19768         (tls_symbolic_operand): Change return type to enum tls_model.
19769         (fpscr_set_from_mem): Add cast to enum type.
19770         (legitimize_pic_address): Compare tls_symbolic_operand result with
19771         enum constant.
19772         (sh_target_reg_class): Change return type to enum reg_class.
19773         * config/sh/sh.h (OVERRIDE_OPTIONS): Change CPU_xxx to
19774         PROCESSOR_xxx.
19775         * config/sh/sh-protos.h (tls_symbolic_operand): Update declaration.
19776         * config/sparc/sparc.c (sparc_override_options): Add cast to enum type.
19777         * config/sparc/sparc.md (empty_delay_slot): Return enum constant.
19778         (pic, calls_alloca, calls_eh_return, leaf_function): Likewise.
19779         (delayed_branch, tls_call_delay): Likewise.
19780         (eligible_for_sibcall_delay): Likewise.
19781         (eligible_for_return_delay): Likewise.
19782         * config/spu/spu.c (expand_builtin_args): Add cast to enum type.
19783         (spu_expand_builtin_1): Likewise.
19784
19785         * c-typeck.c (convert_for_assignment): Issue -Wc++-compat warnings
19786         for all types of conversions.
19787         (output_init_element): Issue -Wc++-compat warning if needed when
19788         initializing a bitfield with enum type.
19789         * c-parser.c (c_parser_expression): Set original_type to
19790         original_type of right hand operand of comma operator.
19791
19792 2009-04-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
19793
19794         * doc/c-tree.texi (Types, Functions, Expression trees): Fix
19795         grammar nits.
19796         * doc/cfg.texi (Maintaining the CFG, Liveness information): Likewise.
19797         * doc/cpp.texi (Standard Predefined Macros)
19798         (Implementation-defined behavior): Likewise.
19799         * doc/extend.texi (Function Attributes, Type Attributes): Likewise.
19800         * doc/gimple.texi (GIMPLE Exception Handling)
19801         (@code{GIMPLE_ASSIGN}): Likewise.
19802         * doc/install.texi (Prerequisites, Configuration, Specific): Likewise.
19803         * doc/invoke.texi (Warning Options, Optimize Options)
19804         (AVR Options, Darwin Options): Likewise.
19805         (Optimize Options): Reformulate -fwhole-program description.
19806         * doc/loop.texi (Lambda): Likewise.
19807         * doc/md.texi (Output Template, Define Constraints)
19808         (Standard Names, Insn Splitting): Likewise.
19809         * doc/options.texi (Option properties): Likewise.
19810         * doc/passes.texi (Tree-SSA passes): Likewise.
19811         * doc/rtl.texi (Side Effects, Assembler, Insns): Likewise.
19812         * doc/tm.texi (Register Classes, Old Constraints, Scalar Return)
19813         (File Names and DBX): Likewise.
19814         * doc/trouble.texi (Incompatibilities): Likewise.
19815
19816 2009-04-27  Trevor Smigiel  <trevor_smigiel@playstation.sony.com>
19817
19818         * spu.c (spu_machine_dependent_reorg): Make sure branch label on hint
19819         instruction is correct.
19820
19821 2009-04-27  Trevor Smigiel  <trevor_smigiel@playstation.sony.com>
19822
19823         Allow non-constant arguments to conversion intrinsics.
19824         * spu-protos.h (exp2_immediate_p, spu_gen_exp2): Declare.
19825         * predicates.md (spu_inv_exp2_operand, spu_exp2_operand): New.
19826         * spu.c (print_operand): Handle 'v' and 'w'.
19827         (exp2_immediate_p, spu_gen_exp2): Define.
19828         * spu-builtins.def (spu_convts, spu_convtu, spu_convtf_0,
19829         spu_convtf_1): Update parameter descriptions.
19830         * spu-builtins.md (spu_csflt, spu_cuflt, spu_cflts, spu_cfltu): Update.
19831         * constraints.md ('v', 'w'): New.
19832         * spu.md (UNSPEC_CSFLT, UNSPEC_CFLTS, UNSPEC_CUFLT, UNSPEC_CFLTU):
19833         Remove.
19834         (i2f, I2F): New define_mode_attr.
19835         (floatsisf2, floatv4siv4sf2, fix_truncsfsi2, fix_truncv4sfv4si2,
19836         floatunssisf2, floatunsv4siv4sf2, fixuns_truncsfsi2,
19837         fixuns_truncv4sfv4si2):  Update to use mode attribute.
19838         (float<mode><i2f>2_mul, float<mode><i2f>2_div,
19839         fix_trunc<mode><f2i>2_mul, floatuns<mode><i2f>2_mul,
19840         floatuns<mode><i2f>2_div, fixuns_trunc<mode><f2i>2_mul): New
19841         patterns for combine.
19842
19843 2009-04-27  Steven Bosscher  <steven@gcc.gnu.org>
19844
19845         * dbgcnt.def (cprop1, cprop2, gcse, jump_bypass): Remove
19846         (cprop, hoist, pre, store_motion): New debug counters.
19847         * tree-pass.h (pass_tracer): Move to list of gimple passes, it
19848         is not an RTL pass anymore.
19849         (pass_profiling): Remove extern decl for pass removed in 2005.
19850         (pass_gcse, pass_jump_bypass): Remove.
19851         * final.c (rest_of_clean_state): Set flag_rerun_cse_after_global_opts
19852         to 0 for clean state.
19853         * toplev.h (flag_rerun_cse_after_global_opts): Add extern declaration.
19854         * cse.c (gate_handle_cse_after_global_opts,
19855         rest_of_handle_cse_after_global_opts): New functions.
19856         (pass_cse_after_global_opts): New pass, does local CSE.
19857         * timevar.def (TV_GCSE, TV_CPROP1, TV_CPROP2, TV_BYPASS): Remove.
19858         (TV_CPROP): New timevar.
19859         * gcse.c (flag_rerun_cse_after_global_opts): New global variable.
19860         (run_jump_opt_after_gcse, max_gcse_regno): Remove global vars.
19861         (gcse_main, recompute_all_luids): Remove.
19862         (compute_hash_table_work): Call max_reg_num instead of reading
19863         max_gcse_regno.
19864         (cprop_jump): Don't set run_jump_opt_after_gcse.
19865         (constprop_register): Always allow to alter jumps.
19866         (cprop_insn): Likewise.
19867         (do_local_cprop): Likewise.
19868         (local_cprop_pass): Likewise.  Return non-zero if something changed.
19869         (cprop): Remove function, fold interesting bits into one_cprop_pass.
19870         (find_implicit_sets): Add note about missed optimization opportunity.
19871         (one_cprop_pass): Rewrite to be "the" CPROP pass, called from the
19872         pass_rtl_cprop execute function.
19873         Don't bother tracking the pass number, each pass gets its own dumpfile
19874         now anyway.
19875         Always allow to alter jumpsand bypass jumps.
19876         (bypass_block): Don't ignore regno >= max_gcse_regno, find_bypass_set
19877         will just find no suitable set.
19878         (pre_edge_insert): Fix dumping, this function is for PRE only.
19879         (one_pre_gcse_pass): Rewrite to be "the" PRE pass, called from the
19880         pass_rtl_pre execute function.
19881         (hoist_code): Return non-zero if something changed.  Keep track of
19882         substitutions and insertions for statistics gathering similar to PRE.
19883         (one_code_hoisting_pass): Rewrite to be "the" code hoisting pass,
19884         called from the pass_rtl_hoist execute function.  Show pass statistics.
19885         (compute_store_table): Use max_reg_num directly instead of using the
19886         formerly global max_gcse_regno.
19887         (build_store_vectors): Likewise.
19888         (replace_store_insn): Fix dumping.
19889         (store_motion): Rename to ...
19890         (one_store_motion_pass): ... this.  Rewrite to be "the" STORE_MOTION
19891         pass, called from the pass_rtl_store_motion execute function.  Keep
19892         track of substitutions and insertions for statistics gathering similar
19893         to PRE.
19894         (bypass_jumps): Remove, fold interesting bits into ...
19895         (one_cprop_pass): ... this.  Rewrite to be "the" CPROP pass, called
19896         from the pass_rtl_cprop execute function.
19897         (gate_handle_jump_bypass, rest_of_handle_jump_bypass,
19898         pass_jump_bypass): Remove.
19899         (gate_handle_gcse, rest_of_handle_gcse): Remove.
19900         (gate_rtl_cprop, execute_rtl_cprop, pass_rtl_cprop): New.
19901         (gate_rtl_pre, execute_rtl_pre, pass_rtl_pre): New.
19902         (gate_rtl_hoist, execute_rtl_hoist, pass_rtl_hoist): New.
19903         (gate_rtl_store_motion, execute_rtl_store_motion,
19904         pass_rtl_store_motion): New.
19905         * common.opt: Remove flag_cse_skip_blocks, adjust documentation to
19906         make it clear that -fcse-skip-blocks is a no-op for backward compat.
19907         * passes.c (init_optimization_passes): Remove pass_gcse and
19908         pass_jump_bypass.  Schedule cprop, pre, hoist, cprop, store_motion,
19909         and cse_after_global_opts in place of pass_gcse.  Schedule cprop
19910         instead of pass_jump_bypass.
19911
19912 2009-04-27  Richard Guenther  <rguenther@suse.de>
19913
19914         PR middle-end/39928
19915         * gimplify.c (gimplify_expr): If we are required to create
19916         a temporary make sure it ends up as register.
19917
19918 2009-04-27  H.J. Lu  <hongjiu.lu@intel.com>
19919
19920         PR target/39903
19921         * config/i386/i386.c (construct_container): Don't call
19922         gen_reg_or_parallel with BLKmode on X86_64_SSE_CLASS,
19923         X86_64_SSESF_CLASS and X86_64_SSEDF_CLASS.
19924
19925 2009-04-27  Michael Matz  <matz@suse.de>
19926
19927         * ssaexpand.h (struct ssaexpand): Member 'values' is a bitmap.
19928         (get_gimple_for_ssa_name): Adjust, lookup using SSA_NAME_DEF_STMT.
19929         * tree-ssa-live.h: (find_replaceable_exprs): Return a bitmap.
19930         (dump_replaceable_exprs): Take a bitmap.
19931         * cfgexpand.c (gimple_cond_pred_to_tree): Handle bitmap instead of
19932         array.
19933         (expand_gimple_basic_block): Likewise.
19934         * tree-ssa-ter.c (struct temp_expr_table_d): Make
19935         replaceable_expressions member a bitmap.
19936         (free_temp_expr_table): Pass back and deal with bitmap, not gimple*.
19937         (mark_replaceable): Likewise.
19938         (find_replaceable_in_bb, dump_replaceable_exprs): Likewise.
19939         * tree-outof-ssa.c (remove_ssa_form): 'values' is a bitmap.
19940
19941 2009-04-27  Richard Guenther  <rguenther@suse.de>
19942
19943         * tree-cfg.c (remove_useless_stmts): Verify stmts afterwards.
19944         (verify_stmts): Dispatch to gimple/type verification code.
19945         * tree-inline.c (remap_gimple_op_r): Work around C++ FE
19946         issue with call argument types.
19947
19948 2009-04-27  Michael Matz  <matz@suse.de>
19949
19950         * tree-into-ssa.c (regs_to_rename, mem_syms_to_rename): Remove.
19951         (init_update_ssa, delete_update_ssa, update_ssa): Remove references
19952         to above.
19953
19954 2009-04-27  Richard Sandiford  <rdsandiford@googlemail.com>
19955             Eric Botcazou  <ebotcazou@adacore.com>
19956
19957         * resource.c (find_basic_block): Use BLOCK_FOR_INSN to look up
19958         a label's basic block.
19959         (mark_target_live_regs): Tidy and rework obsolete comments.
19960         Change back DF problem to LIVE.  If a label starts a basic block,
19961         assume that all registers that used to be live then still are.
19962         (init_resource_info): If a label starts a basic block, set its
19963         BLOCK_FOR_INSN accordingly.
19964         (fini_resource_info): Undo the setting of BLOCK_FOR_INSN.
19965
19966 2009-04-27  Richard Guenther  <rguenther@suse.de>
19967
19968         * tree-flow-inline.h (function_ann): Remove.
19969         (get_function_ann): Likewise.
19970         * tree-dfa.c (create_function_ann): Remove.
19971         * tree-flow.h (struct static_var_ann_d): Remove.
19972         (struct function_ann_d): Likewise.
19973         (union tree_ann_d): Remove fdecl member.
19974         (function_ann_t): Remove.
19975         (function_ann, get_function_ann, create_function_ann): Remove
19976         declarations.
19977
19978 2009-04-27  Uros Bizjak  <ubizjak@gmail.com>
19979
19980         * config/alpha/alpha.c (code_for_builtin): Declare as enum insn_code.
19981
19982 2009-04-27  Jan Hubicka  <jh@suse.cz>
19983
19984         * ipa-pure-const.c (struct funct_state_d): New fields
19985         state_previously_known, looping_previously_known; remove
19986         state_set_in_source.
19987         (analyze_function): Use new fields.
19988         (propagate): Avoid assumption that state_set_in_source imply
19989         nonlooping.
19990
19991         * tree-ssa-loop-niter.c (finite_loop_p): New function.
19992         * tree-ssa-loop-ivcanon.c (empty_loop_p): Use it.
19993         * cfgloop.h (finite_loop_p): Declare.
19994
19995 2009-04-26  Michael Matz  <matz@suse.de>
19996
19997         * tree-flow.h (tree_ann_common_d): Remove aux and value_handle members.
19998
19999 2009-04-26  Michael Matz  <matz@suse.de>
20000
20001         * tree-pass.h (pass_del_ssa, pass_mark_used_blocks,
20002         pass_free_cfg_annotations, pass_free_datastructures): Remove decls.
20003         * gimple-low.c (mark_blocks_with_used_vars, mark_used_blocks,
20004         pass_mark_used_blocks): Remove.
20005         * tree-optimize.c (pass_free_datastructures,
20006         execute_free_cfg_annotations, pass_free_cfg_annotations): Remove.
20007         * passes.c (init_optimization_passes): Don't call
20008         pass_mark_used_blocks, remove dead code.
20009
20010 2009-04-26  H.J. Lu  <hongjiu.lu@intel.com>
20011
20012         * tree-outof-ssa.c (rewrite_trees): Add ATTRIBUTE_UNUSED.
20013         * tree-ssa-live.h (register_ssa_partition): Likewise.
20014
20015 2009-04-26  Michael Matz  <matz@suse.de>
20016
20017         Expand from SSA.
20018         * builtins.c (fold_builtin_next_arg): Handle SSA names.
20019         * tree-ssa-copyrename.c (rename_ssa_copies): Use ssa_name() directly.
20020         * tree-ssa-coalesce.c (create_outofssa_var_map): Mark only useful
20021         SSA names.
20022         (compare_pairs): Swap cost comparison.
20023         (coalesce_ssa_name): Don't use change_partition_var.
20024         * tree-nrv.c (struct nrv_data): Add modified member.
20025         (finalize_nrv_r): Set it.
20026         (tree_nrv): Use it to update statements.
20027         (pass_nrv): Require PROP_ssa.
20028         * tree-mudflap.c (mf_decl_cache_locals,
20029         mf_build_check_statement_for): Use make_rename_temp.
20030         (pass_mudflap_2): Require PROP_ssa, run ssa update at finish.
20031         * alias.c (find_base_decl): Handle SSA names.
20032         * emit-rtl (set_reg_attrs_for_parm): Make non-static.
20033         (component_ref_for_mem_expr): Don't leak SSA names into RTL.
20034         * rtl.h (set_reg_attrs_for_parm): Declare.
20035         * tree-optimize.c (pass_cleanup_cfg_post_optimizing): Rename
20036         to "optimized", remove unused locals at finish.
20037         (execute_free_datastructures): Make global, call
20038         delete_tree_cfg_annotations.
20039         (execute_free_cfg_annotations): Don't call
20040         delete_tree_cfg_annotations.
20041
20042         * ssaexpand.h: New file.
20043         * expr.c (toplevel): Include ssaexpand.h.
20044         (expand_assignment): Handle SSA names the same as register variables.
20045         (expand_expr_real_1): Expand SSA names.
20046         * cfgexpand.c (toplevel): Include ssaexpand.h.
20047         (SA): New global variable.
20048         (gimple_cond_pred_to_tree): Fold TERed comparisons into predicates.
20049         (SSAVAR): New macro.
20050         (set_rtl): New helper function.
20051         (add_stack_var): Deal with SSA names, use set_rtl.
20052         (expand_one_stack_var_at): Likewise.
20053         (expand_one_stack_var): Deal with SSA names.
20054         (stack_var_size_cmp): Use code (SSA_NAME / DECL) as tie breaker
20055         before unique numbers.
20056         (expand_stack_vars): Use set_rtl.
20057         (expand_one_var): Accept SSA names, add asserts for them, feed them
20058         to above subroutines.
20059         (expand_used_vars): Expand all partitions (without default defs),
20060         then only the local decls (ignoring those expanded already).
20061         (expand_gimple_cond): Remove edges when jumpif() expands an
20062         unconditional jump.
20063         (expand_gimple_basic_block): Don't clear EDGE_EXECUTABLE here,
20064         or remove abnormal edges.  Ignore insns setting the LHS of a TERed
20065         SSA name.
20066         (gimple_expand_cfg): Call into rewrite_out_of_ssa, initialize
20067         members of SA; deal with PARM_DECL partitions here; expand
20068         all PHI nodes, free tree datastructures and SA.  Commit instructions
20069         on edges, clear EDGE_EXECUTABLE and remove abnormal edges here.
20070         (pass_expand): Require and destroy PROP_ssa, verify SSA form, flow
20071         info and statements at start, collect garbage at finish.
20072         * tree-ssa-live.h (struct _var_map): Remove partition_to_var member.
20073         (VAR_ANN_PARTITION) Remove.
20074         (change_partition_var): Don't declare.
20075         (partition_to_var): Always return SSA names.
20076         (var_to_partition): Only accept SSA names.
20077         (register_ssa_partition): Only check argument.
20078         * tree-ssa-live.c (init_var_map): Don't allocate partition_to_var
20079         member.
20080         (delete_var_map): Don't free it.
20081         (var_union): Only accept SSA names, simplify.
20082         (partition_view_init): Mark only useful SSA names as used.
20083         (partition_view_fini): Only deal with SSA names.
20084         (change_partition_var): Remove.
20085         (dump_var_map): Use ssa_name instead of partition_to_var member.
20086         * tree-ssa.c (delete_tree_ssa): Don't remove PHI nodes on RTL
20087         basic blocks.
20088         * tree-outof-ssa.c (toplevel): Include ssaexpand.h and expr.h.
20089         (struct _elim_graph): New member const_dests; nodes member vector of
20090         ints.
20091         (set_location_for_edge): New static helper.
20092         (create_temp): Remove.
20093         (insert_partition_copy_on_edge, insert_part_to_rtx_on_edge,
20094         insert_value_copy_on_edge, insert_rtx_to_part_on_edge): New functions.
20095         (new_elim_graph): Allocate const_dests member.
20096         (clean_elim_graph): Truncate const_dests member.
20097         (delete_elim_graph): Free const_dests member.
20098         (elim_graph_size): Adapt to new type of nodes member.
20099         (elim_graph_add_node): Likewise.
20100         (eliminate_name): Likewise.
20101         (eliminate_build): Don't take basic block argument, deal only with
20102         partition numbers, not variables.
20103         (get_temp_reg): New static helper.
20104         (elim_create): Use it, deal with RTL temporaries instead of trees.
20105         (eliminate_phi): Adjust all calls to new signature.
20106         (assign_vars, replace_use_variable, replace_def_variable): Remove.
20107         (rewrite_trees): Only do checking.
20108         (edge_leader, stmt_list, leader_has_match, leader_match): Remove.
20109         (same_stmt_list_p, identical_copies_p, identical_stmt_lists_p,
20110         init_analyze_edges_for_bb, fini_analyze_edges_for_bb,
20111         contains_tree_r, MAX_STMTS_IN_LATCH,
20112         process_single_block_loop_latch, analyze_edges_for_bb,
20113         perform_edge_inserts): Remove.
20114         (expand_phi_nodes): New global function.
20115         (remove_ssa_form): Take ssaexpand parameter.  Don't call removed
20116         functions, initialize new parameter, remember partitions having a
20117         default def.
20118         (finish_out_of_ssa): New global function.
20119         (rewrite_out_of_ssa): Make global.  Adjust call to remove_ssa_form,
20120         don't reset in_ssa_p here, don't disable TER when mudflap.
20121         (pass_del_ssa): Remove.
20122         * tree-flow.h (struct var_ann_d): Remove out_of_ssa_tag and
20123         partition members.
20124         (execute_free_datastructures): Declare.
20125         * Makefile.in (SSAEXPAND_H): New variable.
20126         (tree-outof-ssa.o, expr.o, cfgexpand.o): Depend on SSAEXPAND_H.
20127         * basic-block.h (commit_one_edge_insertion): Declare.
20128         * passes.c (init_optimization_passes): Move pass_nrv and
20129         pass_mudflap2 before pass_cleanup_cfg_post_optimizing, remove
20130         pass_del_ssa, pass_free_datastructures, pass_free_cfg_annotations.
20131         * cfgrtl.c (commit_one_edge_insertion): Make global, don't declare.
20132         (redirect_branch_edge): Deal with super block when expanding, split
20133         out jump patching itself into ...
20134         (patch_jump_insn): ... here, new static helper.
20135
20136 2009-04-26  Michael Matz  <matz@suse.de>
20137
20138         * tree-ssa-copyrename.c (rename_ssa_copies): Don't iterate
20139         beyond num_ssa_names.
20140         * tree-ssa-ter.c (free_temp_expr_table): Likewise.
20141         * tree-ssa-coalesce.c (create_outofssa_var_map): Likewise.
20142
20143 2009-04-26  Jakub Jelinek  <jakub@redhat.com>
20144
20145         PR inline-asm/39543
20146         * fwprop.c (forward_propagate_asm): New function.
20147         (forward_propagate_and_simplify): Propagate also into __asm, if it
20148         doesn't increase the number of referenced registers.
20149
20150         PR c/39889
20151         * stmt.c (warn_if_unused_value): Look through NON_LVALUE_EXPR.
20152
20153 2009-04-26  Jakub Jelinek  <jakub@redhat.com>
20154
20155         * tree-nested.c (get_nonlocal_vla_type): If not optimizing, call
20156         note_nonlocal_vla_type for nonlocal VLAs.
20157         (note_nonlocal_vla_type, note_nonlocal_block_vlas,
20158         contains_remapped_vars, remap_vla_decls): New functions.
20159         (convert_nonlocal_reference_stmt): If not optimizing, call
20160         note_nonlocal_block_vlas on GIMPLE_BIND block vars.
20161         (nesting_copy_decl): Return {VAR,PARM,RESULT}_DECL unmodified
20162         if it wasn't found in var_map.
20163         (finalize_nesting_tree_1): Call remap_vla_decls.  If outermost
20164         GIMPLE_BIND doesn't have gimple_bind_block, chain debug_var_chain
20165         to BLOCK_VARS (DECL_INITIAL (root->context)) instead of calling
20166         declare_vars.
20167         * gimplify.c (nonlocal_vlas): New variable.
20168         (gimplify_var_or_parm_decl): Add debug VAR_DECLs for non-local
20169         referenced VLAs.
20170         (gimplify_body): Create and destroy nonlocal_vlas.
20171
20172         * dwarf2out.c (loc_descr_plus_const): New function.
20173         (build_cfa_aligned_loc, tls_mem_loc_descriptor,
20174         mem_loc_descriptor, loc_descriptor_from_tree_1,
20175         descr_info_loc, gen_variable_die): Use it.
20176
20177         * tree.h (DECL_BY_REFERENCE): Note that it is also valid for
20178         !TREE_STATIC VAR_DECLs.
20179         * dwarf2out.c (loc_by_reference, gen_decl_die): Handle
20180         DECL_BY_REFERENCE on !TREE_STATIC VAR_DECLs.
20181         (gen_variable_die): Likewise.  Don't look at TREE_PRIVATE if
20182         DECL_BY_REFERENCE is valid.
20183         * dbxout.c (DECL_ACCESSIBILITY_CHAR): Don't look at TREE_PRIVATE
20184         for PARM_DECLs, RESULT_DECLs or !TREE_STATIC VAR_DECLs.
20185         * tree-nested.c (get_nonlocal_debug_decl, get_local_debug_decl):
20186         Copy DECL_BY_REFERENCE.
20187         (struct nesting_copy_body_data): New type.
20188         (nesting_copy_decl): New function.
20189         (finalize_nesting_tree_1): Remap types of debug_var_chain variables,
20190         if they have variable length.
20191
20192 2009-04-26  Michael Matz  <matz@suse.de>
20193
20194         * tree-sra.c (sra_build_assignment): Don't use into_ssa mode,
20195         mark new temporaries for renaming.
20196
20197 2009-04-26  Joseph Myers  <joseph@codesourcery.com>
20198
20199         PR c/39581
20200         * c-decl.c (global_bindings_p): Return negative value.
20201         (c_variable_size): New.  Based on variable_size from
20202         stor-layout.c.
20203         (grokdeclarator): Call c_variable_size not variable_size.
20204
20205 2009-04-26  Uros Bizjak  <ubizjak@gmail.com>
20206
20207         * config/i386/i386.c (print_operand) ['z']: Fix typo.
20208
20209 2009-04-26  Kai Tietz  <kai.tietz@onevision.com>
20210
20211         * config/i386/mingw-w64.h (STANDARD_INCLUDE_DIR):
20212         Redefine it to just use mingw/include.
20213         (ASM_SPEC): Rules for -m32 and -m64.
20214         (LINK_SPEC): Use Likewise.
20215         (SPEC_32): New define.
20216         (SPEC_64): Likewise.
20217         (SUB_LINK_SPEC): Likewise.
20218         (MULTILIB_DEFAULTS): New define.
20219         * config/i386/t-mingw-w64 (MULTILIB_OPTIONS):
20220         Add multilib options.
20221         (MULTILIB_DIRNAMES): Likewise.
20222         (MULTILIB_OSDIRNAMES): Likewise.
20223         (LIBGCC): Likewise.
20224         (INSTALL_LIBGCC): Likewise.
20225
20226 2009-04-26  Joseph Myers  <joseph@codesourcery.com>
20227
20228         PR c/39556
20229         * c-tree.h (enum c_inline_static_type): New.
20230         (record_inline_static): Declare.
20231         * c-decl.c (struct c_inline_static, c_inline_statics,
20232         record_inline_static, check_inline_statics): New.
20233         (pop_file_scope): Call check_inline_statics.
20234         (start_decl): Call record_inline_static instead of pedwarning
20235         directly for static in inline function.
20236         * c-typeck.c (build_external_ref): Call record_inline_static
20237         instead of pedwarning directly for static referenced in inline
20238         function.
20239
20240 2009-04-26  Steven Bosscher  <steven@gcc.gnu.org>
20241
20242         * df-scan.c (df_insn_rescan): Salvage insn's LUID if the insn is
20243         not new but only being rescanned.
20244         * gcse.c (uid_cuid, max_uid, INSN_CUID, max_cuid, struct reg_set,
20245         reg_set_table, REG_SET_TABLE_SLOP, reg_set_in_block,
20246         alloc_reg_set_mem, free_reg_set_mem, record_one_set,
20247         record_set_info, compute_set, grealloc): Remove.
20248         (recompute_all_luids): New function.
20249         (gcse_main): Don't compute sets, and don't do related memory
20250         allocations/free-ing.  If something changed before the end of the
20251         pass, update LUIDs using recompute_all_luids.
20252         (alloc_gcse_mem): Don't compute LUIDs.  Don't allocate reg_set memory.
20253         (free_gcse_mem): Don't free it either.
20254         (oprs_unchanged_p, load_killed_in_block, record_last_reg_set_info):
20255         Use the df insn LUIDs.
20256         (load_killed_in_block): Likewise.
20257         (compute_hash_table_work): Don't compute reg_set_in_block.
20258         (compute_transp): Use DF_REG_DEF_CHAINs.
20259         (local_cprop_pass): Don't use compute_sets and related functions.
20260         (one_cprop_pass, pre_gcse, one_pre_gcse_pass, one_code_hoisting_pass):
20261         Use get_max_uid() instead of max_cuid.
20262         (insert_insn_end_basic_block, pre_insert_copy_insn,
20263         update_ld_motion_stores): Don't try to
20264         keep reg_set tables up to date.
20265         (pre_insert_copies): Use df insn LUIDs.
20266         (sbitmap pre_redundant_insns): Replace with uses of INSN_DELETED_P.
20267         (reg_set_info): Don't use extra bitmap argument.
20268         (compute_store_table): Don't compute reg_set_in_block.  Use DF scan
20269         information to compute regs_set_in_block.
20270         (free_store_memory, store_motion): Don't nullify reg_set_in_block.
20271         (bypass_jumps): Don't use compute_sets and friends.
20272
20273 2009-04-26  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
20274
20275         PR testsuite/39710
20276         * opts.c (undocumented_msg): Do not leave blank even with
20277         ENABLE_CHECKING.
20278
20279 2009-04-25  Joseph Myers  <joseph@codesourcery.com>
20280
20281         * c-decl.c (build_enumerator): Allow values folding to integer
20282         constants but not integer constant expressions with a pedwarn if
20283         pedantic.
20284
20285 2009-04-25  Joseph Myers  <joseph@codesourcery.com>
20286
20287         PR c/39582
20288         * c-typeck.c (c_expr_sizeof_type): Create a C_MAYBE_CONST_EXPR
20289         with non-null C_MAYBE_CONST_EXPR_PRE if size of a variable-length
20290         type is an integer constant.
20291
20292 2009-04-25  Uros Bizjak  <ubizjak@gmail.com>
20293
20294         PR target/39897
20295         * config/i386/i386.c (print_operand) ['z']: Revert handling of
20296         HImode operands.
20297
20298 2009-04-25  Joseph Myers  <joseph@codesourcery.com>
20299
20300         PR c/39564
20301         * c-decl.c (grokdeclarator): Diagnose declarations of functions
20302         with variably modified return type and no storage class
20303         specifiers, except for the case of nested functions.  Distinguish
20304         extern declarations of functions with variably modified return
20305         types from those of objects with variably modified types.
20306
20307 2009-04-25  Jan Hubicka  <jh@suse.cz>
20308
20309         * tree.c (list_equal_p): New function.
20310         * tree.h (list_equal_p): Declare.
20311         * coretypes.h (edge_def, edge, const_edge, basic_block_def
20312         basic_block_def, basic_block, const_basic_block): New.
20313         * tree-eh.c (make_eh_edge): EH edges are not abnormal.
20314         (redirect_eh_edge): New function.
20315         (make_eh_edge_update_phi): EH edges are not abnormal.
20316         * except.c: Include tree-flow.h.
20317         (list_match): New function.
20318         (eh_region_replaceable_by_p): New function.
20319         (replace_region): New function.
20320         (hash_type_list): New function.
20321         (hash_eh_region): New function.
20322         (eh_regions_equal_p): New function.
20323         (merge_peers): New function.
20324         (remove_unreachable_regions): Verify EH tree when checking;
20325         merge peers.
20326         (copy_eh_region_1): New function.
20327         (copy_eh_region): New function.
20328         (push_reachable_handler): New function.
20329         (build_post_landing_pads, dw2_build_landing_pads): Be ready for
20330         regions without label but with live RESX.
20331         * except.h (redirect_eh_edge_to_label): New.
20332         * tree-flow.h (redirect_eh_edge): New.
20333         * coretypes.h (edge_def, edge, const_edge, basic_block_def
20334         basic_block_def, basic_block, const_basic_block): Remove.
20335         * Makefile.in (except.o): Add dependency on tree-flow.h
20336         * tree-cfg.c (gimple_redirect_edge_and_branch): Handle EH edges.
20337         * basic-block.h (edge, const_edge, basic_block, const_basic_block):
20338         Remove.
20339
20340 2009-04-25  Eric Botcazou  <ebotcazou@adacore.com>
20341
20342         PR bootstrap/39645
20343         * config/sparc/sparc.c (sparc_gimplify_va_arg): Set TREE_ADDRESSABLE
20344         on the destination of memcpy.
20345
20346 2009-04-25  Paolo Bonzini  <bonzini@gnu.org>
20347
20348         * doc/tm.texi (REGNO_OK_FOR_BASE_P, REGNO_MODE_OK_FOR_BASE_P,
20349         REGNO_MODE_OK_FOR_REG_BASE_P, REGNO_MODE_CODE_OK_FOR_BASE_P,
20350         REGNO_OK_FOR_INDEX_P): Mention strict/nonstrict difference.
20351
20352 2009-04-25  Jan Hubicka  <jh@suse.cz>
20353
20354         * tree-eh.c (tree_remove_unreachable_handlers): Handle shared labels.
20355         (tree_empty_eh_handler_p): Allow non-EH predecestors; allow region
20356         to be reached by different label than left.
20357         (update_eh_edges): Update comment; remove edge_to_remove if possible
20358         and return true if suceeded.
20359         (cleanup_empty_eh): Accept sharing map; handle shared regions.
20360         (cleanup_eh): Compute sharing map.
20361         * except.c (remove_eh_handler_and_replace): Add argument if we should
20362         update regions.
20363         (remove_unreachable_regions): Update for label sharing.
20364         (label_to_region_map): Likewise.
20365         (get_next_region_sharing_label): New function.
20366         (remove_eh_handler_and_replace): Add update_catch_try parameter; update
20367         prev_try pointers.
20368         (remove_eh_handler): Update.
20369         (remove_eh_region_and_replace_by_outer_of): New function.
20370         * except.h (struct eh_region): Add next_region_sharing_label.
20371         (remove_eh_region_and_replace_by_outer_of,
20372         get_next_region_sharing_label): Declare.
20373         * tree-cfgcleanup.c (tree_forwarder_block_p): Simplify.
20374
20375 2009-04-25  Jan Hubicka  <jh@suse.cz>
20376
20377         * tree-cfg.c (split_critical_edges): Split also edges where we can't
20378         insert code even if they are not critical.
20379
20380 2009-04-25  Jan Hubicka  <jh@suse.cz>
20381
20382         * tree-cfg.c (gimple_can_merge_blocks_p): EH edges are unmergable.
20383         (gimple_can_remove_branch_p): EH edges won't remove branch by
20384         redirection.
20385         * tree-inline.c (update_ssa_across_abnormal_edges): Do handle
20386         updating of non-abnormal EH edges.
20387         * tree-cfg.c (gimple_can_merge_blocks_p): EH edges are unmergable.
20388         (gimple_can_remove_branch_p): EH edges are unremovable by redirection.
20389         (split_critical_edges): Split also edges where emitting code on them
20390         will lead to splitting later.
20391
20392 2009-04-25  Uros Bizjak  <ubizjak@gmail.com>
20393             H.J. Lu  <hongjiu.lu@intel.com>
20394
20395         PR target/39590
20396         * configure.ac (HAVE_AS_IX86_FILDQ): On x86 targets check whether
20397         the configured assembler supports fildq and fistpq mnemonics.
20398         (HAVE_AS_IX86_FILDS): Rename from HAVE_GAS_FILDS_FISTS.
20399         * configure: Regenerated.
20400         * config.in: Ditto.
20401
20402         * config/i386/i386.c (print_operand): Handle 'Z'.
20403         ['z']: Remove handling of special fild/fist suffixes.
20404         (output_fix_trunc): Use '%Z' to output suffix of fist{,p,tp} insn.
20405         * config/i386/i386.md (*floathi<mode>2_i387): Use '%Z' to output
20406         suffix of fild insn.
20407         (*floatsi<mode>2_vector_mixed): Ditto.
20408         (*float<SSEMODEI24:mode><MODEF:mode>2_mixed_interunit): Ditto.
20409         (*float<SSEMODEI24:mode><MODEF:mode>2_mixed_nointerunit): Ditto.
20410         (*float<SSEMODEI24:mode><X87MODEF:mode>2_i387_with_temp): Ditto.
20411         (*float<SSEMODEI24:mode><X87MODEF:mode>2_i387): Ditto.
20412         * config/i386/gas.h (GAS_MNEMONICS): Remove.
20413
20414 2009-04-25  Ben Elliston  <bje@au.ibm.com>
20415
20416         * genrecog.c (validate_pattern): Do not warn for VOIDmode CALLs as
20417         the source of a set operation.
20418
20419 2009-04-25  Anatoly Sokolov  <aesok@post.ru>
20420
20421         * target.h (struct gcc_target): Add case_values_threshold field.
20422         * target-def.h (TARGET_CASE_VALUES_THRESHOLD): New.
20423         (TARGET_INITIALIZER): Use TARGET_CASE_VALUES_THRESHOLD.
20424         * targhooks.c (default_case_values_threshold): New function.
20425         * targhooks.h (default_case_values_threshold): Declare function.
20426         * stmt.c (expand_case): Use case_values_threshold target hook.
20427         * expr.h (case_values_threshold): Remove declartation.
20428         * expr.c (case_values_threshold): Remove function.
20429         * doc/tm.texi (CASE_VALUES_THRESHOLD): Revise documentation.
20430
20431         * config/avr/avr.h (CASE_VALUES_THRESHOLD): Remove macro.
20432         * config/avr/avr.c (TARGET_CASE_VALUES_THRESHOLD): Define macro.
20433         (avr_case_values_threshold): Declare as static.
20434         * config/avr/avr-protos.h (avr_case_values_threshold): Remove.
20435
20436         * config/avr/mn10300.h (CASE_VALUES_THRESHOLD): Remove macro.
20437         * config/avr/mn10300.c (TARGET_CASE_VALUES_THRESHOLD): Define macro.
20438         (mn10300_case_values_threshold): New function.
20439
20440 2009-04-24  H.J. Lu  <hongjiu.lu@intel.com>
20441
20442         * ira.c (setup_cover_and_important_classes): Add enum cast.
20443
20444 2009-04-24  Vladimir Makarov  <vmakarov@redhat.com>
20445
20446         * genpreds.c (write_enum_constraint_num): Output definition of
20447         CONSTRAINT_NUM_DEFINED_P macro.
20448         * ira.c (setup_cover_and_important_classes): Use
20449         CONSTRAINT_NUM_DEFINED_P instead of CONSTRAINT__LIMIT in #ifdef.
20450
20451 2009-04-24  DJ Delorie  <dj@redhat.com>
20452
20453         * config/sh/sh.h (LIBGCC2_DOUBLE_TYPE_SIZE): Test
20454         __SH2A_SINGLE_ONLY__ also.
20455
20456 2009-04-24  Steve Ellcey  <sje@cup.hp.com>
20457
20458         * config/ia64/ia64.md (movfs_internal): Allow flt constants.
20459         (movdf_internal): Ditto.
20460         * config/ia64/ia64.c (ia64_legitimate_constant_p): Allow
20461         SFmode and DFmode constants.
20462         (ia64_print_operand): Add 'G' format for printing
20463         floating point constants.
20464
20465 2009-04-24  Richard Guenther  <rguenther@suse.de>
20466
20467         * tree-vrp.c (extract_range_from_binary_expr): Handle overflow
20468         from unsigned additions.
20469
20470 2009-04-24  Joseph Myers  <joseph@codesourcery.com>
20471
20472         * c-typeck.c (set_init_index): Allow array designators that are
20473         not integer constant expressions with a pedwarn if pedantic.
20474
20475 2009-04-24  Bernd Schmidt  <bernd.schmidt@analog.com>
20476
20477         * simplify-rtx.c (simplify_binary_operation_1, case AND): Result is
20478         zero if no overlap in nonzero bits between the operands.
20479
20480 2009-04-24  Ian Lance Taylor  <iant@google.com>
20481
20482         * combine.c (record_value_for_reg): Change 0 to VOIDmode, twice.
20483         (record_dead_and_set_regs): Likewise.
20484         * df.h (struct df_mw_hardreg): Change flags field to int.
20485         (struct df_base_ref): Likewise.
20486         (struct df): Change changeable_flags field to int.
20487         * df-scan.c (df_defs_record): Change clobber_flags to int.
20488         * dwarf2.h (enum dwarf_tag): Make lo_user and hi_user values enum
20489         constants rather than #define macros.
20490         (enum dwarf_attribute, enum dwarf_location_atom): Likewise.
20491         (enum dwarf_type, enum dwarf_endianity_encoding): Likewise.
20492         (enum dwarf_calling_convention): Likewise.
20493         (enum dwarf_line_number_x_ops): Likewise.
20494         (enum dwarf_call_frame_info): Likewise.
20495         (enum dwarf_source_language): Likewise.
20496         * dwarf2out.c (int_loc_descriptor): Add cast to enum type.
20497         (add_calling_convention_attribute): Likewise.
20498         * fold-const.c (fold_undefer_overflow_warnings): Add cast to enum type.
20499         (combine_comparisons): Change compcode to int.  Add cast to enum type.
20500         * genrecog.c (maybe_both_true_2): Change c to int.
20501         (write_switch): Likewise.  Add cast to enum type.
20502         * gimplify.c (gimplify_omp_for): Handle return values from
20503         gimplify_expr using MIN rather than bitwise or.
20504         (gimplify_expr): Add cast to enum type.
20505         * ipa-prop.c (update_jump_functions_after_inlining): Change
20506         IPA_BOTTOM to IPA_JF_UNKNOWN.
20507         * ira.c (setup_class_subset_and_memory_move_costs): Change mode to int.
20508         Add casts to enum type.
20509         (setup_cover_and_important_classes): Change cl to int.  Add casts
20510         to enum type.
20511         (setup_class_translate): Change cl and mode to int.
20512         (ira_init_once): Change mode to int.
20513         (free_register_move_costs): Likewise.
20514         (setup_prohibited_mode_move_regs): Add casts to enum type.
20515         * langhooks.c (add_builtin_function_common): Rework assertion that
20516         value fits bitfield.
20517         * mcf.c (add_fixup_edge): Change type parameter to edge_type.
20518         * omega.c (omega_do_elimination): Avoid math on enum types.
20519         * optabs.c (expand_vec_shift_expr): Remove casts to int.
20520         * opts.c (set_debug_level): Change 2 to enum constant.  Use new
20521         int local to handle integral_argment value.
20522         * regmove.c (try_auto_increment): Change PUT_MODE to
20523         PUT_REG_NOTE_KIND.
20524         * reload.c (push_secondary_reload): Add casts to enum type.
20525         (secondary_reload_class, find_valid_class): Likewise.
20526         * reload1.c (emit_input_reload_insns): Likewise.
20527         * rtl.h (NOTE_VAR_LOCATION_STATUS): Likewise.
20528         * sel-sched.c (init_hard_regs_data): Change cur_mode to int.
20529         * sel-sched-ir.c (hash_with_unspec_callback): Change 0 to enum
20530         constant.
20531         * tree.c (build_common_builtin_nodes): Add casts to enum type.
20532         * tree-complex.c (complex_lattice_t): Typedef to int rather than
20533         enum type.
20534         (expand_complex_libcall): Add casts to enum type.
20535         * tree-into-ssa.c (get_ssa_name_ann): Change 0 to enum constant.
20536         * tree-vect-loop.c (vect_model_reduction_cost): Compare reduc_code
20537         with ERROR_MARK, not NUM_TREE_CODES.
20538         (vect_create_epilog_for_reduction): Likewise.
20539         (vectorizable_reduction): Don't initialize epiloc_reduc_code.
20540         When not using it, set it to ERROR_MARK rather than NUM_TREE_CODES.
20541         * tree-vect-patterns.c (vect_pattern_recog_1): Change vec_mode to
20542         enum machine_mode.
20543         * tree-vect-stmts.c (new_stmt_vec_info): Change 0 to
20544         vect_unused_in_loop.  Change 0 to loop_vect.
20545         * tree-vectorizer.c (vect_set_verbosity_level): Add casts to enum type.
20546         * var-tracking.c (get_init_value): Change return type to enum
20547         var_init_status.
20548         * vec.h (DEF_VEC_FUNC_P) [iterate]: Cast 0 to type T.
20549         * config/arm/arm.c (fp_model_for_fpu): Change to array to enum
20550         arm_fp_model.
20551         (arm_override_options): Add casts to enum type.
20552         (arm_emit_tls_decoration): Likewise.
20553         * config/i386/i386.c (ix86_function_specific_restore): Add casts
20554         to enum type.
20555         * config/i386/i386-c.c (ix86_pragma_target_parse): Likewise.
20556         * config/ia64/ia64.c (ia64_expand_compare): Change magic to int.
20557         * config/rs6000/rs6000.c (rs6000_override_options): Add casts to
20558         enum type.
20559         * config/s390/s390.c (code_for_builtin_64): Change to array of
20560         enum insn_code.
20561         (code_for_builtin_31): Likewise.
20562         (s390_expand_builtin): Change code_for_builtin to enum insn_code
20563         const *.
20564         * config/sparc/sparc.c (sparc_override_options): Change value
20565         field in struct code_model to enum cmodel.  In initializer change
20566         0 to NULL and add cast to enum type.
20567
20568         * c-typeck.c (build_modify_expr): Add lhs_origtype parameter.
20569         Change all callers.  Issue a -Wc++-compat warning using
20570         lhs_origtype if necessary.
20571         (convert_for_assignment): Issue -Wc++-compat warnings about
20572         invalid conversions to enum type on assignment.
20573         * c-common.h (build_modify_expr): Update declaration.
20574
20575 2009-04-24  Nick Clifton  <nickc@redhat.com>
20576
20577         * config/iq2000/iq2000.c (function_arg): Handle TImode values.
20578         (function_arg_advance): Likewise.
20579         * config/iq2000/iq2000.md (movsi_internal2): Fix the length of the
20580         5th alternative.
20581
20582 2009-04-24  Andreas Krebbel  <krebbel1@de.ibm.com>
20583
20584         * config/s390/constraints.md ('I', 'J'): Fix condition.
20585
20586 2009-04-24  Diego Novillo  <dnovillo@google.com>
20587
20588         * gengtype-parse.c (parse_error): Add newline after message.
20589
20590 2009-04-24  H.J. Lu  <hongjiu.lu@intel.com>
20591
20592         * config/i386/sse.md (avxmodesuffixs): Removed.
20593         (*avx_pinsr<avxmodesuffixs>): Renamed to ...
20594         (*avx_pinsr<ssevecsize>): This.
20595
20596 2009-04-24  Bernd Schmidt  <bernd.schmidt@analog.com>
20597
20598         * loop-iv.c (replace_single_def_regs): Look for REG_EQUAL notes;
20599         follow chains of regs with a single definition, and allow expressions
20600         that are function_invariant_p.
20601         (simple_rhs_p): Allow expressions that are function_invariant_p.
20602
20603 2009-04-24  Paolo Bonzini  <bonzini@gnu.org>
20604
20605         PR middle-end/39867
20606         * fold-const.c (fold_cond_expr_with_comparison): When folding
20607         > and >= to MAX, make sure the MAX uses the same type as the
20608         comparison's operands.
20609
20610 2009-04-24  Nick Clifton  <nickc@redhat.com>
20611
20612         * config/frv/frv.c (frv_frame_access): Do not use reg+reg
20613         addressing for DImode accesses.
20614         (frv_print_operand_address): Handle PLUS case.
20615         * config/frv/frv.h (FIXED_REGISTERS): Mark link register as fixed.
20616
20617 2009-04-24  Jakub Jelinek  <jakub@redhat.com>
20618
20619         PR rtl-optimization/39794
20620         * alias.c (canon_true_dependence): Add x_addr argument.
20621         * rtl.h (canon_true_dependence): Adjust prototype.
20622         * cse.c (check_dependence): Adjust canon_true_dependence callers.
20623         * cselib.c (cselib_invalidate_mem): Likewise.
20624         * gcse.c (compute_transp): Likewise.
20625         * dse.c (scan_reads_nospill): Likewise.
20626         (record_store, check_mem_read_rtx): Likewise.  For non-const-or-frame
20627         addresses pass base->val_rtx as mem_addr, for const-or-frame addresses
20628         canon_base_addr of the group, plus optional offset.
20629         (struct group_info): Rename canon_base_mem to
20630         canon_base_addr.
20631         (get_group_info): Set canon_base_addr to canon_rtx of base, not
20632         canon_rtx of base_mem.
20633
20634 2009-04-23  Paolo Bonzini  <bonzini@gnu.org>
20635
20636         * config/sh/sh.c (sh_expand_prologue, sh_expand_epilogue):
20637         Use memory_address_p instead of GO_IF_LEGITIMATE_ADDRESS.
20638
20639 2009-04-23  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
20640
20641         * config/spu/spu-builtins.h: Delete file.
20642
20643         * config/spu/spu.h (enum spu_builtin_type): Move here from
20644         spu-builtins.h.
20645         (struct spu_builtin_description): Likewise.  Add GTY marker.
20646         Do not use enum spu_function_code or enum insn_code.
20647         (spu_builtins): Add extern declaration.
20648
20649         * config/spu/spu.c: Do not include "spu-builtins.h".
20650         (enum spu_function_code, enum spu_builtin_type_index,
20651         V16QI_type_node, V8HI_type_node, V4SI_type_node, V2DI_type_node,
20652         V4SF_type_node, V2DF_type_node, unsigned_V16QI_type_node,
20653         unsigned_V8HI_type_node, unsigned_V4SI_type_node,
20654         unsigned_V2DI_type_node): Move here from spu-builtins.h.
20655         (spu_builtin_types): Make static.  Add GTY marker.
20656         (spu_builtins): Add extern declaration with GTY marker.
20657         Include "gt-spu.h".
20658
20659         * config/spu/spu-c.c: Do not include "spu-builtins.h".
20660         (spu_resolve_overloaded_builtin): Do not use spu_function_code.
20661         Check programmatically whether all parameters are scalar.
20662
20663         * config/spu/t-spu-elf (spu.o, spu-c.o): Update dependencies.
20664
20665 2009-04-23  Eric Botcazou  <ebotcazou@adacore.com>
20666
20667         * gimplify.c (gimplify_modify_expr_rhs) <VAR_DECL>: Do not do a direct
20668         assignment from the constructor either if the target is volatile.
20669
20670 2009-04-23  Daniel Jacobowitz  <dan@codesourcery.com>
20671
20672         * config/arm/arm.md (insv): Do not share operands[0].
20673
20674 2009-04-23  Nathan Sidwell  <nathan@codesourcery.com>
20675
20676         * config/vxlib-tls.c (active_tls_threads): Delete.
20677         (delete_hook_installed): New.
20678         (tls_delete_hook): Don't delete the delete hook.
20679         (tls_destructor): Delete it here.
20680         (__gthread_set_specific): Adjust installing the delete hook.
20681         (tls_delete_hook): Use __gthread_enter_tsd_dtor_context and
20682         __gthread_leave_tsd_dtor_context.
20683
20684 2009-04-23  Rafael Avila de Espindola  <espindola@google.com>
20685
20686         * c-format.c (gcc_tdiag_char_table): Add support for %E.
20687
20688 2009-04-23  Uros Bizjak  <ubizjak@gmail.com>
20689
20690         * config/alpha/alpha.c (alpha_legitimize_reload_address): Add cast to
20691         enum type.
20692         (alpha_rtx_costs): Ditto.
20693         (emit_unlikely_jump): Use add_reg_note.
20694         (emit_frame_store_1): Ditto.
20695         (alpha_expand_prologue): Ditto.
20696         (alpha_expand_builtin): Change 0 to EXPAND_NORMAL in function call.
20697         * config/alpha/alpha.c (Unicos/Mk address splitter): Use add_reg_note.
20698
20699 2009-04-23  Nick Clifton  <nickc@redhat.com>
20700
20701         * config/v850/v850.md (epilogue): Remove suppressed code.
20702         (return): Rename to return_simple and remove test of frame size.
20703         * config/v850/v850.c (expand_epilogue): Rename call to gen_return
20704         to gen_return_simple.
20705
20706 2009-04-22  Jing Yu  <jingyu@google.com>
20707
20708         PR testsuite/39781
20709         * config/arm/arm.h: Define HANDLE_PRAGMA_PACK_PUSH_POP.
20710
20711 2009-04-22  Andrew Pinski  <andrew_pinski@playstation.sony.com>
20712
20713         PR C/31499
20714         * c-typeck.c (process_init_element): Treat VECTOR_TYPE like ARRAY_TYPE
20715         and RECORD_TYPE/UNION_TYPE.  When outputing the actual element and the
20716         value is a VECTOR_CST, the element type is the element type of the
20717         vector.
20718
20719 2009-04-22  DJ Delorie  <dj@redhat.com>
20720
20721         * config/m32c/m32c.h: Update GTY annotations to new syntax.
20722
20723 2009-04-22  Jakub Jelinek  <jakub@redhat.com>
20724
20725         * alias.c (find_base_term): Move around LO_SUM case, so that
20726         CONST falls through into PLUS/MINUS handling.
20727
20728         PR c/39855
20729         * fold-const.c (fold_binary) <case LSHIFT_EXPR>: When optimizing
20730         into 0, use omit_one_operand.
20731
20732 2009-04-23  Ben Elliston  <bje@au.ibm.com>
20733
20734         * config/rs6000/linux-unwind.h (get_regs): Remove type
20735         puns. Change the type of `pc' to an array of unsigned ints and
20736         update all users.  Constify frame24.
20737
20738 2009-04-22  DJ Delorie  <dj@redhat.com>
20739
20740         * config/m32c/m32c.c (m32c_special_page_vector_p): Move
20741         declarations before code.
20742         (current_function_special_page_vector): Likewise.
20743         (m32c_expand_insv): Silence a warning.
20744
20745 2009-04-21  Taras Glek  <tglek@mozilla.com>
20746
20747         * alias.c: Update GTY annotations to new syntax.
20748         * basic-block.h: Likewise.
20749         * bitmap.h: Likewise.
20750         * c-common.h: Likewise.
20751         * c-decl.c: Likewise.
20752         * c-parser.c: Likewise.
20753         * c-pragma.c: Likewise.
20754         * c-tree.h: Likewise.
20755         * cfgloop.h: Likewise.
20756         * cgraph.h: Likewise.
20757         * config/alpha/alpha.c: Likewise.
20758         * config/arm/arm.h: Likewise.
20759         * config/avr/avr.h: Likewise.
20760         * config/bfin/bfin.c: Likewise.
20761         * config/cris/cris.c: Likewise.
20762         * config/darwin.c: Likewise.
20763         * config/frv/frv.c: Likewise.
20764         * config/i386/i386.c: Likewise.
20765         * config/i386/i386.h: Likewise.
20766         * config/i386/winnt.c: Likewise.
20767         * config/ia64/ia64.h: Likewise.
20768         * config/iq2000/iq2000.c: Likewise.
20769         * config/mips/mips.c: Likewise.
20770         * config/mmix/mmix.h: Likewise.
20771         * config/pa/pa.c: Likewise.
20772         * config/pa/pa.h: Likewise.
20773         * config/rs6000/rs6000.c: Likewise.
20774         * config/s390/s390.c: Likewise.
20775         * config/sparc/sparc.c: Likewise.
20776         * config/xtensa/xtensa.c: Likewise.
20777         * cselib.h: Likewise.
20778         * dbxout.c: Likewise.
20779         * dwarf2out.c: Likewise.
20780         * except.c: Likewise.
20781         * except.h: Likewise.
20782         * fixed-value.h: Likewise.
20783         * function.c: Likewise.
20784         * function.h: Likewise.
20785         * gimple.h: Likewise.
20786         * integrate.c: Likewise.
20787         * optabs.c: Likewise.
20788         * output.h: Likewise.
20789         * real.h: Likewise.
20790         * rtl.h: Likewise.
20791         * stringpool.c: Likewise.
20792         * tree-data-ref.c: Likewise.
20793         * tree-flow.h: Likewise.
20794         * tree-scalar-evolution.c: Likewise.
20795         * tree-ssa-address.c: Likewise.
20796         * tree-ssa-alias.h: Likewise.
20797         * tree-ssa-operands.h: Likewise.
20798         * tree.c: Likewise.
20799         * tree.h: Likewise.
20800         * varasm.c: Likewise.
20801         * varray.h: Likewise.
20802         * vec.h: Likewise.
20803         * coretypes.h: Do not define GTY macro if it is already defined.
20804         * doc/gty.texi: Update GTY documentation to new syntax.
20805         * gengtype-lex.l: Enforce attribute-like syntax for GTY
20806         annotations on structs.
20807         * gengtype-parse.c: Likewise.
20808
20809 2009-04-22  Mark Heffernan  <meheff@google.com>
20810
20811         * gcc.c (LINK_COMMAND_SPEC): Link with gcov with -fprofile-generate=.
20812
20813 2009-04-22  Kazu Hirata  <kazu@codesourcery.com>
20814
20815         * config/arm/arm.c (arm_rtx_costs_1): Use power_of_two_operand
20816         where appropriate.
20817
20818 2009-04-22  Kazu Hirata  <kazu@codesourcery.com>
20819
20820         * config/arm/arm.c (arm_size_rtx_costs): Treat a PLUS with a shift
20821         the same as a PLUS without a shift.  Increase the cost of a
20822         CONST_INT in MULT.
20823
20824 2009-04-22  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
20825
20826         * Makefile.in: Update dependencies.
20827         * errors.c (warning): Remove unused parameter 'opt'. Returns 'void'.
20828         * errors.h: Remove bogus comment about compatibility.
20829         (warning): Update declaration.
20830         * genautomata.c: Update all calls to warning.
20831         * gimple.c: Do not include errors.h. Include toplev.h.
20832         * tree-ssa-structalias.c: Do not include errors.h.
20833         * omega.c: Likewise.
20834         * tree-ssa-reassoc.c: Likewise.
20835         * config/spu/spu-c.c: Likewise.
20836         * config/spu/t-spu-elf: Update dependencies.
20837
20838 2009-04-22  Richard Guenther  <rguenther@suse.de>
20839
20840         PR tree-optimization/39824
20841         * tree-ssa-ccp.c (fold_const_aggregate_ref): For INDIRECT_REFs
20842         make sure the types are compatible.
20843
20844 2009-04-22  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
20845
20846         PR c++/14875
20847         * c-common.c (c_parse_error): Take a token_flags parameter.
20848         Use token_type for the token type instead.
20849         Pass token_flags to cpp_type2name.
20850         * c-common.h (c_parse_error): Update declaration.
20851         * c-parser.c (c_parser_error): Pass 0 as token flags.
20852
20853 2009-04-22  Andrey Belevantsev  <abel@ispras.ru>
20854
20855         PR rtl-optimization/39580
20856         * sel-sched-ir.c (insert_in_history_vect): Remove incorrect gcc_assert.
20857
20858 2009-04-22  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
20859
20860         * function.c (expand_function_end): Do not emit a jump to the "naked"
20861         return label for fall-through returns.
20862         * except.c (sjlj_emit_function_exit): Always place the call to the
20863         unregister function at the location installed by expand_function_end.
20864
20865 2009-04-22  Richard Guenther  <rguenther@suse.de>
20866
20867         PR tree-optimization/39845
20868         * tree-switch-conversion.c (build_arrays): Add new referenced vars.
20869         (gen_inbound_check): Likewise.
20870
20871 2009-04-22  Nathan Sidwell  <nathan@codesourcery.com>
20872
20873         * gthr-vxworks.h (struct __gthread_once_t): Add alignment and
20874         padding for PPC.
20875         (__GTHREAD_ONCE_INIT): Adjust ppc initializer.
20876         * config/vxlib.c (__gthread_once): Add race guard for PPC.
20877
20878 2009-04-22  Paolo Bonzini  <bonzini@gnu.org>
20879
20880         * config/sh/sh.c (shift_insns_rtx, shiftcosts, gen_shifty_op,
20881         sh_dynamicalize_shift_p, shl_and_scr_length): Truncate
20882         shift counts to avoid out-of-bounds array accesses.
20883
20884 2009-04-22  Paolo Bonzini  <bonzini@gnu.org>
20885
20886         * config/sparc/sparc.h (POINTER_SIZE): Fix comment.
20887         (Pmode): Move above.
20888
20889 2009-04-22  Uros Bizjak  <ubizjak@gmail.com>
20890
20891         * config/alpha/alpha.c: Use REG_P, MEM_P, CONST_INT_P, JUMP_P,
20892         NONJUMP_INSN_P, CALL_P, LABEL_P and NOTE_P predicates instead of
20893         GET_CODE macro.  Use IN_RANGE macro where appropriate.
20894         * config/alpha/alpha.h: Ditto.
20895         * config/alpha/alpha.md: Ditto.
20896         * config/alpha/constraints.md: Ditto.
20897         * config/alpha/predicates.md: Ditto.
20898
20899 2009-04-22  Paolo Bonzini  <bonzini@gnu.org>
20900
20901         * defaults.h (GO_IF_MODE_DEPENDENT_ADDRESS): Provide empty default.
20902         * config/frv/frv.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20903         * config/s390/s390.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20904         * config/m32c/m32c.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20905         * config/spu/spu.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20906         * config/i386/i386.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20907         * config/sh/sh.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20908         * config/pdp11/pdp11.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20909         * config/avr/avr.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20910         * config/crx/crx.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20911         * config/fr30/fr30.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20912         * config/m68hc11/m68hc11.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20913         * config/cris/cris.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20914         * config/iq2000/iq2000.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20915         * config/mn10300/mn10300.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20916         * config/ia64/ia64.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20917         * config/m68k/m68k.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20918         * config/picochip/picochip.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20919         * config/arc/arc.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20920         * config/mcore/mcore.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20921         * config/score/score.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20922         * config/arm/arm.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20923         * config/pa/pa.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20924         * config/mips/mips.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20925         * config/v850/v850.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20926         * config/mmix/mmix.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20927         * config/bfin/bfin.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
20928
20929 2009-04-22  Laurynas Biveinis  <laurynas.biveinis@gmail.com>
20930
20931         * cfghooks.c (tidy_fallthru_edges): Remove find_basic_blocks
20932         references from comments.
20933         * cfgbuild.c: (count_basic_blocks): Delete.
20934         (find_basic_blocks_1): Delete.
20935         (find_basic_blocks): Delete.
20936         * except.c (finish_eh_generation): Make static.  Move comment from
20937         except.h here.  Remove find_basic_blocks references from comments.
20938         * except.h (finish_eh_generation): Delete.
20939         * basic-block.h (find_basic_blocks): Delete.
20940         * config/sh/sh.c (sh_output_mi_thunk): Delete a "#if 0" block.
20941
20942 2009-04-22  Dave Korn  <dave.korn.cygwin@gmail.com>
20943
20944         * sdbout.c (sdbout_symbol):  Pass VOIDmode to eliminate_regs.
20945         (sdbout_parms):  Likewise.
20946
20947 2009-04-21  Kaz Kojima  <kkojima@gcc.gnu.org>
20948
20949         * config/sh/sh.c (prepare_cbranch_operands): Use
20950         LAST_AND_UNUSED_RTX_CODE instead of CODE_FOR_nothing.
20951         (expand_cbranchdi4): Likewise.
20952         (from_compare): Add cast to enum type.
20953         (expand_cbranchsi4): Use add_reg_note.
20954         (output_stack_adjust, push, pop, sh_expand_prologue): Likewise.
20955         (sh_insn_length_adjustment): Use sh_cpu_attr instead of sh_cpu.
20956         (sh_initialize_trampoline): Change 0 to LCT_NORMAL in function call.
20957         (sh_expand_builtin): Change 0 to EXPAND_NORMAL in function call.
20958         * config/sh/sh.md (cbranchsi4): Use LAST_AND_UNUSED_RTX_CODE
20959         instead of CODE_FOR_nothing.
20960         (cbranchdi4): Likewise.  Fix the order of arguments for
20961         gen_rtx_fmt_ee.
20962         (push_fpscr): Use add_reg_note.
20963         (pop_fpscr, movdf_i4+1, reload_outdf__RnFRm+3, reload_outdf__RnFRm+4,
20964         reload_outdf__RnFRm+5, fpu_switch+1, fpu_switch+2): Likewise.
20965
20966 2009-04-21  Joseph Myers  <joseph@codesourcery.com>
20967
20968         * ABOUT-GCC-NLS, ChangeLog, ChangeLog-1997, ChangeLog-1998,
20969         ChangeLog-1999, ChangeLog-2000, ChangeLog-2001, ChangeLog-2002,
20970         ChangeLog-2003, ChangeLog-2004, ChangeLog-2005, ChangeLog-2006,
20971         ChangeLog-2007, ChangeLog-2008, ChangeLog.dataflow, ChangeLog.lib,
20972         ChangeLog.ptr, ChangeLog.tree-ssa, ChangeLog.tuples, FSFChangeLog,
20973         FSFChangeLog.10, FSFChangeLog.11, LANGUAGES, ONEWS, acinclude.m4,
20974         config/alpha/gnu.h, config/alpha/libgcc-alpha-ldbl.ver,
20975         config/alpha/t-osf4, config/alpha/t-vms, config/alpha/va_list.h,
20976         config/alpha/x-vms, config/arc/t-arc,
20977         config/arm/README-interworking, config/arm/arm-c.c,
20978         config/arm/gentune.sh, config/arm/libgcc-bpabi.ver,
20979         config/arm/t-arm, config/arm/t-arm-elf, config/arm/t-arm-softfp,
20980         config/arm/t-bpabi, config/arm/t-linux, config/arm/t-linux-eabi,
20981         config/arm/t-netbsd, config/arm/t-pe, config/arm/t-strongarm-elf,
20982         config/arm/t-symbian, config/arm/t-vxworks, config/arm/t-wince-pe,
20983         config/avr/t-avr, config/bfin/elf.h, config/bfin/libgcc-bfin.ver,
20984         config/bfin/linux.h, config/bfin/t-bfin, config/bfin/t-bfin-elf,
20985         config/bfin/t-bfin-linux, config/bfin/t-bfin-uclinux,
20986         config/bfin/uclinux.h, config/cris/mulsi3.asm, config/cris/t-cris,
20987         config/cris/t-elfmulti, config/crx/t-crx,
20988         config/darwin-ppc-ldouble-patch.def, config/darwin-sections.def,
20989         config/divmod.c, config/fr30/t-fr30, config/frv/libgcc-frv.ver,
20990         config/frv/t-frv, config/frv/t-linux, config/h8300/genmova.sh,
20991         config/h8300/t-h8300, config/i386/athlon.md,
20992         config/i386/darwin-libgcc.10.4.ver,
20993         config/i386/darwin-libgcc.10.5.ver, config/i386/libgcc-glibc.ver,
20994         config/i386/mach.h, config/i386/netbsd.h, config/i386/t-crtpc,
20995         config/i386/t-cygming, config/i386/t-cygwin, config/i386/t-i386,
20996         config/i386/t-linux64, config/i386/t-nwld,
20997         config/i386/t-rtems-i386, config/i386/t-sol2-10,
20998         config/i386/x-mingw32, config/ia64/div.md, config/ia64/elf.h,
20999         config/ia64/ia64.opt, config/ia64/libgcc-glibc.ver,
21000         config/ia64/libgcc-ia64.ver, config/ia64/linux.h,
21001         config/ia64/sysv4.h, config/ia64/t-hpux, config/ia64/t-ia64,
21002         config/iq2000/abi, config/iq2000/lib2extra-funcs.c,
21003         config/iq2000/t-iq2000, config/libgcc-glibc.ver,
21004         config/m32r/libgcc-glibc.ver, config/m32r/t-linux,
21005         config/m32r/t-m32r, config/m68hc11/t-m68hc11,
21006         config/m68k/t-floatlib, config/m68k/t-linux, config/m68k/t-mlibs,
21007         config/m68k/t-uclinux, config/mcore/t-mcore,
21008         config/mcore/t-mcore-pe, config/mips/20kc.md, config/mips/4130.md,
21009         config/mips/5400.md, config/mips/5500.md, config/mips/crti.asm,
21010         config/mips/crtn.asm, config/mips/irix-crti.asm,
21011         config/mips/irix-crtn.asm, config/mips/libgcc-mips16.ver,
21012         config/mips/mips-dsp.md, config/mips/mips-dspr2.md,
21013         config/mips/mips-fixed.md, config/mips/sb1.md,
21014         config/mips/sr71k.md, config/mips/t-elf, config/mips/t-gofast,
21015         config/mips/t-iris6, config/mips/t-isa3264,
21016         config/mips/t-libgcc-mips16, config/mips/t-linux64,
21017         config/mips/t-mips, config/mips/t-r3900, config/mips/t-rtems,
21018         config/mips/t-sb1, config/mips/t-sde, config/mips/t-sdemtk,
21019         config/mips/t-slibgcc-irix, config/mips/t-sr71k, config/mips/t-st,
21020         config/mips/t-vr, config/mips/t-vxworks, config/mmix/t-mmix,
21021         config/mn10300/t-linux, config/mn10300/t-mn10300,
21022         config/pa/pa32-regs.h, config/pa/t-hpux-shlib, config/pa/t-linux,
21023         config/pa/t-linux64, config/pa/t-pa64, config/pdp11/t-pdp11,
21024         config/picochip/libgccExtras/clzsi2.asm,
21025         config/picochip/t-picochip, config/rs6000/darwin-ldouble-format,
21026         config/rs6000/darwin-libgcc.10.4.ver,
21027         config/rs6000/darwin-libgcc.10.5.ver,
21028         config/rs6000/libgcc-ppc-glibc.ver, config/rs6000/ppc-asm.h,
21029         config/rs6000/t-aix43, config/rs6000/t-aix52,
21030         config/rs6000/t-darwin, config/rs6000/t-fprules,
21031         config/rs6000/t-fprules-fpbit, config/rs6000/t-linux64,
21032         config/rs6000/t-lynx, config/rs6000/t-netbsd,
21033         config/rs6000/t-ppccomm, config/rs6000/t-ppcendian,
21034         config/rs6000/t-ppcgas, config/rs6000/t-rs6000,
21035         config/rs6000/t-rtems, config/rs6000/t-spe,
21036         config/rs6000/t-vxworks, config/s390/libgcc-glibc.ver,
21037         config/score/t-score-elf, config/sh/divcost-analysis,
21038         config/sh/libgcc-glibc.ver, config/sh/t-netbsd, config/sh/t-sh,
21039         config/sh/t-sh64, config/sh/t-superh, config/sh/t-symbian,
21040         config/sparc/libgcc-sparc-glibc.ver, config/sparc/sol2-bi.h,
21041         config/sparc/sol2-gas.h, config/sparc/sol2-gld-bi.h,
21042         config/sparc/t-elf, config/sparc/t-linux64, config/sparc/t-sol2,
21043         config/stormy16/stormy-abi, config/stormy16/t-stormy16,
21044         config/t-darwin, config/t-libunwind, config/t-libunwind-elf,
21045         config/t-linux, config/t-lynx, config/t-slibgcc-elf-ver,
21046         config/t-slibgcc-sld, config/t-sol2, config/t-vxworks,
21047         config/udivmod.c, config/udivmodsi4.c, config/v850/t-v850,
21048         config/v850/t-v850e, config/xtensa/t-xtensa, diagnostic.def,
21049         gdbinit.in, glimits.h, gstab.h, gsyms.h, java/ChangeLog,
21050         java/ChangeLog.ptr, java/ChangeLog.tree-ssa, libgcc-std.ver,
21051         limitx.h, version.c, xcoff.h: Add copyright and license notices.
21052         * config/h8300/genmova.sh: Include copyright and license notices
21053         in generated output.
21054         * config/h8300/mova.md: Regenerate.
21055         * doc/install.texi2html: Include word "Copyright" in copyright
21056         notice and use name "Free Software Foundation, Inc.".
21057         * ChangeLog, ChangeLog-2000, ChangeLog-2001, ChangeLog-2002,
21058         ChangeLog-2003, ChangeLog-2004, ChangeLog-2005, ChangeLog-2006,
21059         ChangeLog-2007, ChangeLog-2008: Correct dates.
21060
21061 2009-04-21  Eric Botcazou  <ebotcazou@adacore.com>
21062
21063         * c-common.c (c_common_truthvalue_conversion): Use LOCATION to build
21064         NE_EXPR operations as well.
21065         * c-parser.c (c_parser_condition): Do not set location information on
21066         the condition.
21067         (c_parser_conditional_expression): Likewise.
21068         (c_parser_binary_expression): Set location information on operators.
21069         * c-typeck.c (build_unary_op) <TRUTH_NOT_EXPR>: Reset the location if
21070         TRUTH_NOT_EXPR has been folded.
21071         * fold-const.c (fold_truth_not_expr): Copy location information from
21072         the incoming expression to the outgoing one.
21073         * gimplify.c (shortcut_cond_r): Add locus parameter.  Pass it to
21074         recursive calls on the LHS of the operator but pass that of the
21075         operator to recursive calls on the RHS of the operator.  Set it
21076         on the COND_EXPR.
21077         (shortcut_cond_expr): Set the locus of the operator on the second
21078         COND_EXPR and that of the expression on the first in degenerate cases.
21079         Pass the locus of the expression to calls to shortcut_cond_r.
21080         Set the locus of the 'then' block on the associated jump, if any.
21081         (gimplify_boolean_expr): Add locus parameter.  Set it on the COND_EXPR.
21082         (gimplify_expr) <TRUTH_ANDIF_EXPR>: Pass the locus of the outer
21083         expression to call to gimplify_boolean_expr.
21084
21085 2009-04-21  Kai Tietz  <kai.tietz@onevision.com>
21086
21087         * config.gcc: Add additional configuration for
21088         i686-w64-mingw* and x86_64-w64-mingw* triplet.
21089         * config/i386/mingw-w64.h: New mingw-w64 specific header.
21090         (CPP_SPEC): Redefine for allowing -municode option.
21091         (STARTFILE_SPEC): Likewise.
21092         * config/i386/t-mingw-w64: New.
21093         * config/i386/mingw-w64.opt: New.
21094         (municode): Add new target option.
21095         * doc/invoke.texi (municode): Add documentation for new option.
21096
21097 2009-04-21  Ian Lance Taylor  <iant@google.com>
21098
21099         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
21100         Correct test for number of arguments.
21101         * config/spu/spu-c.c (spu_resolve_overloaded_builtin): Likewise.
21102
21103 2009-04-21  Andreas Schwab  <schwab@linux-m68k.org>
21104
21105         * config/m68k/linux.h (FINALIZE_TRAMPOLINE): Use enum for second
21106         argument of emit_library_call.
21107
21108 2009-04-21  Richard Guenther  <rguenther@suse.de>
21109
21110         PR middle-end/39829
21111         * gimple.c (walk_stmt_load_store_addr_ops): Catch addresses
21112         inside VIEW_CONVERT_EXPRs.
21113
21114 2009-04-21  Martin Jambor  <mjambor@suse.cz>
21115
21116         * tree-switch-conversion.c (build_constructors): Split a long line.
21117         (constructor_contains_same_values_p): New function.
21118         (build_one_array): Create assigns of constants if possible, do not
21119         call mark_sym_for_renaming, call update_stmt.
21120         (build_arrays): Call make_ssa_name (create_tmp_var ()) instead of
21121         make_rename_temp.  Do not call mark_symbols_for_renaming, call
21122         update_stmt.
21123         (gen_def_assigns): Do not call mark_symbols_for_renaming or
21124         find_new_referenced_vars, call update_stmt.
21125         (gen_inbound_check): Use create_tmp_var and create ssa names manually
21126         instead of calling make_rename_temp.  Do not call
21127         find_new_referenced_vars or mark_symbols_for_renaming, call
21128         update_stmt.
21129
21130 2009-04-21  Richard Guenther  <rguenther@suse.de>
21131
21132         PR tree-optimization/39827
21133         * tree-ssa-phiprop.c (propagate_with_phi): Check SSA_NAME is in range.
21134         (tree_ssa_phiprop): Pass the correct array size.
21135
21136 2009-04-21  Uros Bizjak  <ubizjak@gmail.com>
21137
21138         * config/alpha/alpha.md (tune): Add cast to enum attr_tune.
21139
21140 2009-04-21  Manuel López-Ibáñez  <manu@gcc.gnu.org>
21141
21142         PR 16202
21143         * c-typeck.c (lvalue_p): Move declaration ...
21144         * c-common.h (lvalue_p): ... to here.
21145         * c-common.c (candidate_equal_p): New.
21146         (add_tlist): Use it.
21147         (merge_tlist): Use it.
21148         (warn_for_collisions_1): Likewise.
21149         (warning_candidate_p): Accept more candidates.
21150         (verify_tree): A warning candidate can be an expression. Use
21151         candidate_equal_p.
21152
21153 2009-04-21  Ben Elliston  <bje@au.ibm.com>
21154
21155         PR target/5267
21156         * doc/invoke.texi (RS/6000 and PowerPC Options): Add documentation
21157         for -mcall-eabi, -mcall-aixdesc, -mcall-freebsd and -mcall-openbsd
21158         options.  Remove -mcall-solaris documentation.
21159
21160 2009-04-21  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
21161
21162         PR c++/13358
21163         * doc/invoke.texi (-Wlong-long): Update description.
21164         * c-lex (interpret_integer): Only warn if there was no previous
21165         overflow and -Wlong-long is enabled.
21166         * c-decl.c (declspecs_add_type): Drop redundant flags.
21167         * c.opt (Wlong-long): Init to -1.
21168         * c-opts.c (sanitize_cpp_opts): Synchronize cpp's warn_long_long
21169         and front-end warn_long_long. Wlong-long only depends on other
21170         flags if it is uninitialized.
21171         * c-parser.c (disable_extension_diagnostics): warn_long_long is
21172         the same for CPP and FE.
21173         (restore_extension_diagnostics): Likewise.
21174
21175 2009-04-20  Ian Lance Taylor  <iant@google.com>
21176
21177         Fix enum conversions which are invalid in C++:
21178         * auto-inc-dec.c (attempt_change): Change 0 to SET in function call.
21179         * calls.c (store_one_arg): Change 0 to EXPAND_NORMAL in function call.
21180         * cse.c (hash_rtx_cb): Change 0 to VOIDmode in function call.
21181         * dbgcnt.c (dbg_cnt_set_limit_by_name): Add cast to enum type.
21182         * dbxout.c (dbxout_symbol): Change 0 to VOIDmode in function call.
21183         (dbxout_parms): Likewise.
21184         * df-core.c (df_set_flags): Change changeable_flags parameter to int.
21185         (df_clear_flags): Likewise.
21186         * df-problems.c (df_rd_bb_local_compute_process_def): Change
21187         top_flag parameter to int.
21188         (df_chain_create_bb_process_use): Likewise.
21189         (df_chain_add_problem): Change chain_flags parameter to unsigned int.
21190         Remove cast.
21191         * df-scan.c (df_ref_create): Change ref_flags parameter to int.
21192         (df_ref_create_structure, df_def_record_1): Likewise.
21193         (df_defs_record, df_uses_record, df_get_call_refs): Likewise.
21194         (df_notes_rescan): Change 0 to VOIDmode in function call.
21195         (df_get_call_refs, df_insn_refs_collect): Likewise.
21196         (df_bb_regs_collect): Likewise.
21197         (df_entry_block_defs_collect): Likewise.
21198         (df_exit_block_uses_collect): Likewise.
21199         * df.h: Update declarations.
21200         * double-int.c (double_int_divmod): Add cast to enum type.
21201         * dse.c (replace_inc_dec): Reverse parameters to gen_int_mode.
21202         * dwarf2out.c (new_reg_loc_descr): Add casts to enum type.
21203         (based_loc_descr): Likewise.
21204         (loc_descriptor_from_tree_1): Change first_op and second_op to
21205         enum dwarf_location_atom.  Add cast to enum type.
21206         * expmed.c (init_expmed): Change 0 to SET in function call.
21207         * expr.c (init_expr_target): Change 0 to VOIDmode in function call.
21208         (expand_expr_real_1): Change 0 to EXPAND_NORMAL in function call.
21209         (do_store_flag): Likewise.
21210         * fixed-value.h (struct fixed_value): Change mode to enum
21211         machine_mode.
21212         * function.c (assign_parms): Change 0 to VOIDmode in function call.
21213         * genautomata.c (insert_automaton_decl): Change 1 to INSERT in
21214         function call.
21215         (insert_insn_decl, insert_decl, insert_state): Likewise.
21216         (automata_list_finish): Likewise.
21217         * genrecog.c (process_define_predicate): Add cast to enum type.
21218         * gensupport.c (init_predicate_table): Add cast to enum type.
21219         * gimple.c (gimple_build_return): Change 0 to ERROR_MARK in
21220         function call.
21221         (gimple_build_call_1, gimple_build_label): Likewise.
21222         (gimple_build_goto, gimple_build_asm_1): Likewise.
21223         (gimple_build_switch_1, gimple_build_cdt): Likewise.
21224         * gimple.h (GIMPLE_CHECK): Change 0 to ERROR_MARK in function call.
21225         (enum fallback): Rename from enum fallback_t.
21226         (fallback_t): Typedef as int.
21227         * gimple-low.c (lower_builtin_setjmp): Change TSI_SAME_STMT to
21228         GSI_SAME_STMT in function call.
21229         * ira.c (setup_class_subset_and_memory_move_costs): Add casts to
21230         enum type.
21231         (setup_reg_class_relations): Likewise.
21232         (setup_reg_class_nregs): Change cl to int.  Add casts to enum type.
21233         (setup_prohibited_class_mode_regs): Add cast to enum type.
21234         (setup_prohibited_mode_move_regs): Likewise.
21235         * ira-costs.c (record_reg_classes): Change rclass to enum reg_class.
21236         (record_address_regs): Change i to enum reg_class.
21237         * lists.c (alloc_EXPR_LIST): Add cast to enum type.
21238         * machmode.h (GET_MODE_CLASS): Cast value to enum mode_class.
21239         (GET_MODE_WIDER_MODE): Cast value to enum machine_mode.
21240         (GET_MODE_2XWIDER_MODE): Likewise.
21241         (GET_CLASS_NARROWEST_MODE): Likewise.
21242         * omp-low.c (expand_omp_for): Add cast to enum type.
21243         * optabs.c (debug_optab_libfuncs): Add casts to enum type.
21244         * opts.c (enable_warning_as_error): Change kind to diagostic_t.
21245         * postreload.c (reload_cse_simplify_operands): Change rclass local
21246         to enum reg_class.
21247         * predict.c (combine_predictions_for_insn): Change best_predictor
21248         and predictor to enum br_predictor.
21249         (combine_predictions_for_bb): Likewise.
21250         (build_predict_expr): Change assignment to PREDICT_EXPR_OUTCOME to
21251         use SET_PREDICT_EXPR_OUTCOME.
21252         * real.c (real_arithmetic): Change icode to code in function call.
21253         * reginfo.c (init_move_cost): Add casts to enum type.
21254         (init_reg_sets_1, init_fake_stack_mems): Likewise.
21255         * regmove.c (regclass_compatible_p): Change class0 and class1 to
21256         enum reg_class.
21257         * reload.c (find_valid_class): Add casts to enum type.
21258         (push_reload): Change 0 to NO_REGS in function call.
21259         (find_reloads): Change this_alternative to array of enum
21260         reg_class.  Remove some now-unnecessary casts.
21261         (make_memloc): Change 0 to VOIDmode in function call.
21262         * reload1.c (reload): Change 0 to VOIDmode in function call.
21263         (eliminate_regs_1, elimination_effects): Likewise.
21264         (eliminate_regs_in_insn): Likewise.
21265         (emit_input_reload_insns): Add cast to enum type.
21266         (delete_output_reload): Change 0 to VOIDmode in function call.
21267         * reorg.c (insn_sets_resource_p): Convert include_delayed_effects
21268         to enum type in function call.
21269         * tree.h (PREDICT_EXPR_OUTCOME): Add cast to enum type.
21270         (SET_PREDICT_EXPR_OUTCOME): Define.
21271         * tree-dump.c (get_dump_file_info): Change phase parameter to int.
21272         (get_dump_file_name, dump_begin, dump_enabled_p): Likewise.
21273         (dump_initialized_p, dump_flag_name, dump_end): Likewise.
21274         (dump_function): Likewise.
21275         * tree-dump.h: Update declarations.
21276         * tree-pass.h: Update declarations.
21277         * varasm.c (assemble_integer): Change mclass to enum mode_class.
21278         * config/arm/arm.c (thumb_legitimize_reload_address): Add cast to
21279         enum type.
21280         (arm_rtx_costs_1): Correct parenthesization.
21281         (arm_rtx_costs): Add casts to enum type.
21282         (adjacent_mem_locations): Reverse arguments to const_ok_for_op.
21283         (vfp_emit_fstmd): Use add_rg_note.
21284         (emit_multi_reg_push, emit_sfm): Likewise.
21285         (thumb_set_frame_pointer): Likewise.
21286         (arm_expand_prologue): Likewise.
21287         (arm_regno_class): Change return type to enum reg_class.
21288         (thumb1_expand_prologue): Use add_reg_note.
21289         * config/arm/arm-protos.h (arm_regno_class): Update declaration.
21290         * config/arm/arm.h (INITIALIZE_TRAMPOLINE): Change 0 to LCT_NORMAL
21291         in function call.
21292         * config/arm/gentune.sh: Add cast to enum type.
21293         * config/arm/arm-tune.md: Rebuild.
21294         * config/i386/i386.c (ix86_expand_prologue): Use add_reg_note.
21295         (ix86_split_fp_branch, predict_jump): Likewise.
21296         (ix86_expand_multi_arg_builtin): Change sub_code from enum
21297         insn_code to enum rtx_code.
21298         (ix86_builtin_vectorized_function): Add cast to enum type.
21299         * config/i386/i386.md (truncdfsf2): Change slot to enum
21300         ix86_stack_slot.
21301         (truncxf<mode>2, isinf<mode>2): Likewise.
21302         * config/i386/i386-c.c (ix86_pragma_target_parse): Add cast to
21303         enum type.
21304         * config/ia64/ia64.c (ia64_split_tmode_move): Use add_reg_note.
21305         (spill_restore_mem, do_spill, ia64_expand_prologue): Likewise.
21306         (insert_bundle_state): Change 1 to INSERT in function call.
21307         (ia64_add_bundle_selector_before): Likewise.
21308         * config/ia64/ia64.md (cpu attr): Add cast to enum type.
21309         (save_stack_nonlocal): Change 0 to LCT_NORMAL in function call.
21310         (restore_stack_nonlocal): Likewise.
21311         * config/mips/mips.h (MIPS_ICACHE_SYNC): Change 0 to LCT_NORMAL in
21312         function call.
21313         * config/mips/mips.c (mips_binary_cost): Change 0 to SET in
21314         function call.
21315         (mips_rtx_costs): Likewise.
21316         (mips_override_options): Add casts to enum type.
21317         * config/mips/sdemtk.h (MIPS_ICACHE_SYNC): Change 0 to LCT_NORMAL
21318         in function call.
21319         * config/pa/pa.c (legitimize_pic_address): Use add_reg_note.
21320         (store_reg, set_reg_plus_d): Likewise.
21321         (hppa_expand_prologue, hppa_profile_hook): Likewise.
21322         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Add
21323         cast to enum type.
21324         (altivec_expand_vec_set_builtin): Change 0 to EXPAND_NORMAL in
21325         function call.
21326         (emit_unlikely_jump): Use add_reg_note.
21327         (rs6000_emit_allocate_stack): Likewise.
21328         (rs6000_frame_related, rs6000_emit_prologue): Likewise.
21329         (output_toc): Change 1 to INSERT in function call.
21330         (output_profile_hook): Change 0 to LCT_NORMAL in function call.
21331         (rs6000_initialize_trampoline): Likewise.
21332         (rs6000_init_dwarf_reg_sizes_extra): Change 0 to EXPAND_NORMAL in
21333         function call.
21334         * config/s390/s390.c (s390_rtx_costs): Add cast to enum type.
21335         (s390_expand_movmem): Change 0 to OPTAB_DIRECT in function call.
21336         (s390_expand_setmem, s390_expand_cmpmem): Likewise.
21337         (save_gprs): Use add_reg_note.
21338         (s390_emit_prologue): Likewise.
21339         (s390_expand_builtin): Change 0 to EXPAND_NORMAL in function call.
21340         * config/sparc/sparc.c (sparc_expand_prologue): Use add_reg_note.
21341         (sparc_fold_builtin): Add cast to enum type.
21342         * config/spu/spu.c (spu_emit_branch_or_set): Change ior_code to
21343         enum insn_code.
21344         (spu_expand_prologue): Use add_reg_note.
21345         (expand_builtin_args): Change 0 to EXPAND_NORMAL in function call.
21346
21347 2009-04-20  Ian Lance Taylor  <iant@google.com>
21348
21349         * c-parser.c (c_parser_attributes): Change VEC back to tree list.
21350         (c_parser_postfix_expression_after_primary): Get VEC for list of
21351         arguments.  Get original types of arguments.  Call
21352         build_function_call_vec.
21353         (cached_expr_list_1, cached_expr_list_2): New static variables.
21354         (c_parser_expr_list): Change return type to VEC *.  Add
21355         p_orig_types parameter.  Change all callers.
21356         (c_parser_release_expr): New static function.
21357         (c_parser_vec_to_tree_list): New static function.
21358         * c-typeck.c (build_function_call): Rewrite to build a VEC and
21359         call build_function_call_vec.
21360         (build_function_call_vec): New function, based on old
21361         build_function_call.
21362         (convert_arguments): Remove nargs and argarray parameters.  Change
21363         values to a VEC.  Add origtypes parameter.
21364         (build_modify_expr): Add rhs_origtype parameter.  Change all callers.
21365         (convert_for_assignment): Add origtype parameter.  Change all
21366         callers.  If warn_cxx_compat, check for conversion to an enum
21367         type when calling a function.
21368         (store_init_value): Add origtype parameter.  Change all callers.
21369         (digest_init): Likewise.
21370         (struct init_node): Add origtype field.
21371         (add_pending_init): Add origtype parameter.  Change all callers.
21372         (output_init_element): Likewise.
21373         (output_pending_init_elements): Pass origtype from init_node to
21374         output_init_element.
21375         (process_init_element): Pass origtype from c_expr to
21376         output_init_element.
21377         (c_finish_return): Add origtype parameter.  Change all callers.
21378         * c-common.c (sync_resolve_size): Change params to VEC *.  Change
21379         caller.
21380         (sync_resolve_params): Likewise.
21381         (sync_resolve_return): Change params to first_param.  Change caller.
21382         (resolve_overloaded_builtins): Change params to VEC *.  Change
21383         callers.  Save first parameter around call to build_function_call_vec.
21384         * c-decl.c (finish_decl): Add origtype parameter.  Change all
21385         callers.  Call build_function_call_vec rather than
21386         build_function_call for cleanup.
21387         * c-tree.h: Update declarations.
21388         * c-common.h: Update declarations.
21389         * stub-objc.c (objc_rewrite_function_call): Change parameter from
21390         params to first_param.
21391         * target.h (struct gcc_target): Change resolve_overloaded_builtin
21392         params parameter from tree to void *.
21393         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
21394         Change arglist parameter to have type void *, and to be a pointer
21395         to a VEC.
21396         * config/rs6000/rs6000-protos.h
21397         (altivec_resolve_overloaded_builtin): Update declaration.
21398         * config/spu/spu-c.c (spu_resolved_overloaded_builtin): Change
21399         fnargs parameter to have type void *, and to be a pointer to a
21400         VEC.  Call build_function_call_vec instead of
21401         build_function_call.
21402         * config/spu/spu-protos.h (spu_expand_builtin): Update declaration.
21403
21404 2009-04-20  Joey Ye  <joey.ye@intel.com>
21405             Xuepeng Guo  <xuepeng.guo@intel.com>
21406             H.J. Lu  <hongjiu.lu@intel.com>
21407
21408         * config/i386/atom.md: Add bypasses with ix86_dep_by_shift_count.
21409
21410         * config/i386/i386.c (LEA_SEARCH_THRESHOLD): New macro.
21411         (IX86_LEA_PRIORITY): Likewise.
21412         (distance_non_agu_define): New function.
21413         (distance_agu_use): Likewise.
21414         (ix86_lea_for_add_ok): Likewise.
21415         (ix86_dep_by_shift_count): Likewise.
21416
21417         * config/i386/i386.md: Call ix86_lea_for_add_ok to decide we
21418         should split for LEA.
21419
21420         * config/i386/i386-protos.h (ix86_lea_for_add_ok): Declare new
21421         function.
21422         (ix86_dep_by_shift_count): Likewise.
21423
21424 2009-04-20  Richard Guenther  <rguenther@suse.de>
21425
21426         * expr.c (handled_component_p): Move ...
21427         * tree.h (handled_component_p): ... here.
21428         * tree.def: Re-order BIT_FIELD_REF, COMPONENT_REF,
21429         ARRAY_REF, ARRAY_RANGE_REF, VIEW_CONVERT_EXPR, IMAGPART_EXPR
21430         and REALPART_EXPR to be in one group.
21431
21432 2009-04-20  Richard Guenther  <rguenther@suse.de>
21433
21434         * basic-block.h (get_all_dominated_blocks): Declare.
21435         * dominance.c (get_all_dominated_blocks): New function.
21436         * tree-cfg.c (get_all_dominated_blocks): Remove.
21437         (remove_edge_and_dominated_blocks): Adjust.
21438         * tree-ssa-phiprop.c (tree_ssa_phiprop_1): Fold in ...
21439         (tree_ssa_phiprop): ... here.  Use get_all_dominated_blocks
21440         instead of recursing.
21441
21442 2009-04-20  Doug Kwan  <dougkwan@google.com>
21443
21444         * cgraph.h (cgraph_node_ptr): New type for vector functions.
21445         (struct cgraph_node_set_def): New type.
21446         (cgraph_node_set) New type. Also declare vector functions.
21447         (struct cgraph_node_set_element_def): New type.
21448         (cgraph_node_set_element): Ditto.
21449         (cgraph_node_set_iterator): New iterator type.
21450         (cgraph_node_set_new, cgraph_node_set_find, cgraph_node_set_add,
21451         cgraph_node_set_remove, dump_cgraph_node_set,
21452         debug_cgraph_node_set): New prototypes.
21453         (csi_end_p, csi_next, csi_node, csi_start, cgraph_node_in_set_p,
21454         cgraph_node_set_size): New inlines.
21455         * tree-pass.h (struct cgraph_node_set_def): New decl to avoid
21456         including cgraph.h.
21457         (struct ipa_opt_pass): Add struct cgraph_node_set_def
21458         argument to function 'write_summary'.
21459         * ipa.c: Include ggc.h.
21460         (hash_cgraph_node_set_element,
21461         eq_cgraph_node_set_element, cgraph_node_set_new,
21462         cgraph_node_set_add, cgraph_node_set_remove,
21463         cgraph_node_set_find, dump_cgraph_node_set,
21464         debug_cgraph_node_set): New functions.
21465         * Makefile.in (ipa.o): Add dependency on GGC_H.
21466
21467 2009-04-20  Ira Rosen  <irar@il.ibm.com>
21468
21469         PR tree-optimization/39675
21470         * tree-vect-loop.c (vect_transform_loop): Remove currently redundant
21471         check of the return code of vect_schedule_slp. Check that
21472         stmt_vec_info still exists for the statement, before checking its
21473         vectorization type.
21474
21475 2009-04-20  Michael Matz  <matz@suse.de>
21476
21477         * Makefile.in (generated_files): Take out $(simple_generated_c).
21478
21479 2009-04-19  Dave Korn  <dave.korn.cygwin@gmail.com>
21480
21481         * config/i386/cygwin-stdint.h (INTPTR_TYPE):  Remove "long".
21482         (UINTPTR_TYPE):  Likewise.
21483
21484 2009-04-19  Joseph Myers  <joseph@codesourcery.com>
21485
21486         PR c/37481
21487         * c-typeck.c (digest_init): Check for initializing an array with a
21488         string literal.
21489
21490 2009-04-19  Joseph Myers  <joseph@codesourcery.com>
21491
21492         PR c/19771
21493         * c-semantics.c (pop_stmt_list): Propagate
21494         STATEMENT_LIST_HAS_LABEL to parent statement list.
21495
21496 2009-04-19  Adam Nemet  <anemet@caviumnetworks.com>
21497
21498         * config/mips/mips.h (mips_tune_attr): New macro.
21499         * config/mips/mips.md (cpu): Use it.
21500
21501 2009-04-19  Joseph Myers  <joseph@codesourcery.com>
21502
21503         PR c/38243
21504         * c-decl.c (shadow_tag_warned): Diagnose use of restrict when
21505         declaring a tag.
21506
21507 2009-04-19  Diego Novillo  <dnovillo@google.com>
21508
21509         * toplev.c (compile_file): Move call to coverage_finish ...
21510         * cgraphunit.c (ipa_passes): ... here.
21511         Call cgraph_process_new_functions.
21512         * ipa-utils.c (get_base_var): Handle CONSTRUCTOR.
21513         * Makefile.in (cgraphunit.o): Add dependency on COVERAGE_H.
21514
21515 2009-04-19  Jan Hubicka  <jh@suse.cz>
21516
21517         * cgraph.c (cgraph_create_edge, cgraph_set_call_stmt): Set proper
21518         cfun.
21519         (dump_cgraph_node): Dump can throw external flag.
21520         * ipa-pure-const.c (propagate): Fix propagation of nothrow flags.
21521
21522 2009-04-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
21523
21524         PR c/32061
21525         PR c++/36954
21526         * doc/invoke.texi: Add -Wlogical-op to -Wextra.
21527         * common.opt (Wlogical-op): Move from here...
21528         * c.opt (Wlogical-op): ... to here.
21529         * c-typeck.c (parser_build_binary_op): Update call to
21530         warn_logical_operator.
21531         * c-opts.c (c_common_post_options): Enable warn_logical_op with
21532         extra_warnings.
21533         * c-common.c (warn_logical_op): Update.
21534         * c-common.h (warn_logical_op): Update declaration.
21535
21536 2009-04-19  Eric Botcazou  <ebotcazou@adacore.com>
21537
21538         * tree.c (protected_set_expr_location): Fix formatting.
21539
21540 2009-04-18  Joseph Myers  <joseph@codesourcery.com>
21541
21542         PR c/27676
21543         * c-typeck.c (readonly_warning): new.
21544         (build_unary_op, build_modify_expr): Use readonly_warning for
21545         storing into something readonly but not const-qualified.
21546
21547 2009-04-18  Joseph Myers  <joseph@codesourcery.com>
21548
21549         PR c/22367
21550         * c-typeck.c (build_unary_op): Check for taking address of
21551         expression of type void.
21552
21553 2009-04-18  Joseph Myers  <joseph@codesourcery.com>
21554
21555         PR c/35210
21556         * c-typeck.c (build_function_call): Check for calling a function
21557         with qualified void return types.  Call require_complete_type when
21558         generating a trap.
21559
21560 2009-04-18  Jan Hubicka  <jh@suse.cz>
21561
21562         * cgraph.c (cgraph_make_edge, dump_cgraph_node, cgraph_set_call_stmt):
21563         Set nothrow flag.
21564         * cgraph.h (struct function): Reduce loop_nest to 30 bits; add
21565         can_throw_external flag.
21566         * ipa-reference.c (ipa_utils_reduced_inorder): Update call.
21567         * ipa-pure-const.c (ignore_edge): New function.
21568         (propagate): Compute order for NOTHROW computation; set NOTHROWs
21569         only over can_throw_external edges.
21570         (local_pure_const): Add nothrow flag.
21571         * ipa-utils.c (searchc): Add ignore_edge callback.
21572         (ipa_utils_reduced_inorder): Add ignore_edge callback.
21573         * ipa-utils.h (ipa_utils_reduced_inorder): Update prototype.
21574         (set_nothrow_function_flags): Update cgraph.
21575         * tree-cfg.c (verify_stmt): Relax nothrow checking when in IPA mode.
21576
21577 2009-04-18  Richard Guenther  <rguenther@suse.de>
21578
21579         PR middle-end/39804
21580         * tree-ssa-ccp.c (fold_stmt_1): New function factored from ...
21581         (fold_stmt): ... this and ...
21582         (fold_stmt_inplace): ... this.
21583         (fold_stmt_1): Fold references in calls and asms.
21584         * tree-cfg.c (remove_useless_stmts_cond): Use fold_stmt.
21585
21586 2009-04-18  Kazu Hirata  <kazu@codesourcery.com>
21587
21588         * tree-vrp.c (ssa_name_nonzero_p): Remove.
21589         * tree.h: Remove the prototype for ssa_name_nonzero_p.
21590
21591 2009-04-18  Kazu Hirata  <kazu@codesourcery.com>
21592
21593         * tree.c (function_args_count): Remove.
21594         * tree.h: Remove the prototype for function_args_count.
21595
21596 2009-04-18  Kazu Hirata  <kazu@codesourcery.com>
21597
21598         * tree-iterator.c (expr_only): Remove.
21599         * tree.h: Remove the prototype for expr_only.
21600
21601 2009-04-18  Kazu Hirata  <kazu@codesourcery.com>
21602
21603         * reginfo.c (cannot_change_mode_set_regs): Remove.
21604         * rtl.h: Remove the prototype for cannot_change_mode_set_regs.
21605
21606 2009-04-08  Anatoly Sokolov  <aesok@post.ru>
21607
21608         * config/avr/avr.md (*rotlsi3_8, *rotlsi3_16, *rotlsi3_24 ): Check
21609         whether operands 0 and 1 overlaps.
21610
21611 2009-04-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>
21612
21613         PR middle-end/36902
21614         * tree-vrp.c (check_array_ref): Pass a location_t instead of a
21615         pointer. Use warning_at instead of warning.
21616         (search_for_addr_array): Likewise.
21617         (check_array_bounds): Likewise.
21618         (check_all_array_refs): Check that the incoming edge is not in the
21619         list of edges to be removed.
21620         (check_all_array_refs): Avoid the temporal pointer.
21621         (vrp_visit_cond_stmt): Fix typo.
21622         (simplify_switch_using_ranges): Handle the case where the switch
21623         index is an integer constant.
21624
21625 2009-04-18  Adam Nemet  <anemet@caviumnetworks.com>
21626
21627         * config/mips/mips.c (mips_final_postscan_insn): Make it static.
21628
21629 2009-04-18  Kazu Hirata  <kazu@codesourcery.com>
21630
21631         * doc/extend.texi, doc/invoke.texi: Fix typos.
21632
21633 2009-04-17  Cary Coutant  <ccoutant@google.com>
21634
21635         * tree-flow-inline.h (get_lineno): Fix inverted test.
21636
21637 2009-04-17  Diego Novillo  <dnovillo@google.com>
21638
21639         * tree-ssa-pre.c (create_expression_by_pieces): Remove
21640         assertion for AVAIL_OUT.
21641
21642 2009-04-17  Mike Frysinger  <vapier@gentoo.org>
21643
21644         PR target/38627
21645         * config/sh/lib1funcs.asm [__ELF__ && __linux__]: Add .note.GNU-stack.
21646         * config/sh/linux-atomic.asm: Likewise.
21647
21648 2009-04-17  Diego Novillo  <dnovillo@google.com>
21649
21650         * except.c (debug_eh_tree): New.
21651         (struct eh_region, struct eh_status): Move ...
21652         * except.h: ... here.
21653         (add_type_for_runtime): Declare extern.
21654         (lookup_type_for_runtime): Likewise.
21655         (debug_eh_tree): Declare.
21656         * Makefile.in (GTFILES): List except.h before except.c
21657
21658 2009-04-17  Diego Novillo  <dnovillo@google.com>
21659
21660         * omp-low.c (create_omp_child_function): Set DECL_CONTEXT for DECL.
21661         * cgraphunit.c (cgraph_build_static_cdtor): Likewise.
21662         * tree-dfa.c (find_referenced_vars_in): Factor out of ...
21663         (find_vars_r): ... here.
21664         * tree-flow.h (find_referenced_vars_in): Declare.
21665         * tree-ssa-pre.c (create_expression_by_pieces): Assert
21666         that AVAIL_OUT exists for BLOCK.
21667         * Makefile.in (CGRAPH_H): Add dependency on cif-code.def
21668         (tree-loop-distribution.o): Fix dependency on TREE_VECTORIZER_H.
21669         (tree-parloops.o): Likewise.
21670
21671 2009-04-17  Simon Baldwin  <simonb@google.com>
21672
21673         * toplev.c (default_tree_printer): Add handling for %E format.
21674
21675 2009-04-17  Diego Novillo  <dnovillo@google.com>
21676
21677         * tree-pretty-print.c (dump_generic_node): Add break after
21678         TREE_BINFO handler.  Handle COMPLEX_TYPE, REAL_TYPE and
21679         FIXED_POINT_TYPE.  Handle NULL TREE_TYPEs.  Handle METHOD_TYPE and
21680         FUNCTION_TYPE together.  Call print_struct_decl when printing
21681         structures and TDF_SLIM is not given.
21682         (print_struct_decl): Fix logic for detecting recursion.
21683
21684 2009-04-17  Rafael Avila de Espindola  <espindola@google.com>
21685
21686         PR 31567
21687         * gcc.c (create_at_file): New.
21688         (compile_input_file_p): New.
21689         (do_spec_1): Use @args files for %i. Use create_at_file for %o.
21690         * main.c (main): Update call to toplev_main.
21691         * toplev.c (toplev_main): Change signature. Call expandargv.
21692         * toplev.h (toplev_main): Change signature.
21693
21694 2009-04-17  Eric Botcazou  <ebotcazou@adacore.com>
21695
21696         * dwarf2out.c (field_byte_offset): Use the type size as the field size
21697         if the latter is not constant.
21698
21699 2009-04-17  David Edelsohn  <edelsohn@gnu.org>
21700
21701         * dbxout.c (xcoff_debug_hooks): Add set_name_debug_nothing.
21702
21703 2009-04-17  Eric Botcazou  <ebotcazou@adacore.com>
21704
21705         * dbxout.c (dbxout_block): Reinstate test on TREE_USED.
21706         * tree-ssa-live.c (remove_unused_scope_block_p): Update TREE_USED bit.
21707
21708 2009-04-17  Richard Guenther  <rguenther@suse.de>
21709
21710         * tree-ssa-structalias.c (get_constraint_for_component_ref):
21711         Handle component references view-converting an invariant address.
21712
21713 2009-04-17  Adam Nemet  <anemet@caviumnetworks.com>
21714
21715         * doc/tm.texi (TARGET_DEFAULT_TARGET_FLAGS,
21716         TARGET_MIN_ANCHOR_OFFSET, TARGET_MAX_ANCHOR_OFFSET,
21717         TARGET_HAVE_SRODATA_SECTION, TARGET_HAVE_TLS,
21718         TARGET_UNWIND_TABLES_DEFAULT, TARGET_TERMINATE_DW2_EH_FRAME_INFO):
21719         Use @deftypevr rather than @deftypevar.
21720
21721 2009-04-17  Richard Guenther  <rguenther@suse.de>
21722
21723         * tree-ssa-forwprop.c (get_prop_dest_stmt): Clean up tuplification.
21724         (get_prop_source_stmt): Likewise.
21725         (can_propagate_from): Likewise.
21726
21727 2009-04-17  Andrew Stubbs  <ams@codesourcery.com>
21728
21729         * configure.ac: Add new AC_SUBST for TM_ENDIAN_CONFIG,
21730         TM_MULTILIB_CONFIG and TM_MULTILIB_EXCEPTIONS_CONFIG.
21731         (--with-multilib-list): Add default value.
21732         * configure: Regenerate.
21733         * Makefile.in (TM_ENDIAN_CONFIG): Define.
21734         (TM_MULTILIB_CONFIG, TM_MULTILIB_EXCEPTIONS_CONFIG): Define.
21735         * config.gcc (sh-*-*): Switch to using TM_ENDIAN_CONFIG,
21736         TM_MULTILIB_CONFIG, and TM_MULTILIB_EXCEPTIONS_CONFIG.
21737         Don't add default cpu to multilib list unnecessarily, but do enable
21738         the relevant compiler option..
21739         Add support for --with-multilib-list=<blank> and
21740         --with-multilib-list=!<somelib> to supress unwanted multilibs.
21741         * config/sh/t-sh (DEFAULT_ENDIAN, OTHER_ENDIAN): New variables.
21742         (MULTILIB_ENDIAN, MULTILIB_CPUS): Delete variables.
21743         (MULTILIB_OPTIONS): Redefine using OTHER_ENDIAN and
21744         TM_MULTILIB_CONFIG.
21745         (MULTILIB_EXCEPTIONS): Add TM_MULTILIB_EXCEPTIONS_CONFIG.
21746         (MULTILIB_OSDIRNAMES): New variable.
21747         * config/sh/t-1e: Delete file.
21748         * config/sh/t-mlib-sh1: Delete file.
21749         * config/sh/t-mlib-sh2: Delete file.
21750         * config/sh/t-mlib-sh2a: Delete file.
21751         * config/sh/t-mlib-sh2a-nofpu: Delete file.
21752         * config/sh/t-mlib-sh2a-single: Delete file.
21753         * config/sh/t-mlib-sh2a-single-only: Delete file.
21754         * config/sh/t-mlib-sh2e: Delete file.
21755         * config/sh/t-mlib-sh3e: Delete file.
21756         * config/sh/t-mlib-sh4: Delete file.
21757         * config/sh/t-mlib-sh4-nofpu: Delete file.
21758         * config/sh/t-mlib-sh4-single: Delete file.
21759         * config/sh/t-mlib-sh4-single-only: Delete file.
21760         * config/sh/t-mlib-sh4a: Delete file.
21761         * config/sh/t-mlib-sh4a-nofpu: Delete file.
21762         * config/sh/t-mlib-sh4a-single: Delete file.
21763         * config/sh/t-mlib-sh4a-single-only: Delete file.
21764         * config/sh/t-mlib-sh4al: Delete file.
21765         * config/sh/t-mlib-sh5-32media: Delete file.
21766         * config/sh/t-mlib-sh5-32media-nofpu: Delete file.
21767         * config/sh/t-mlib-sh5-64media: Delete file.
21768         * config/sh/t-mlib-sh5-64media-nofpu: Delete file.
21769         * config/sh/t-mlib-sh5-compact: Delete file.
21770         * config/sh/t-mlib-sh5-compact-nofpu: Delete file.
21771         * config/sh/t-linux: Don't override MULTILIB_EXCEPTIONS.
21772         * doc/install.texi (Options specification): Add
21773         --with-multilib-list and --with-endian.
21774
21775 2009-04-17  Rafael Avila de Espindola  <espindola@google.com>
21776
21777         * Makefile.in (REVISION_s): Always include quotes. Change ifdef to use
21778         REVISION_c.
21779         (OBJS-common): Add plugin-version.o.
21780         (plugin-version.o): New.
21781         * gcc-plugin.h (plugin_gcc_version): New.
21782         (plugin_default_version_check): New.
21783         (plugin_init_func, plugin_init): Add version argument.
21784         * plugin-version.c: New.
21785         * plugin.c (str_plugin_gcc_version_name): New.
21786         (try_init_one_plugin): Read plugin_gcc_version from the plugin and
21787         pass it to the init function.
21788         (plugin_default_version_check): New.
21789
21790 2009-04-17  Richard Guenther  <rguenther@suse.de>
21791
21792         * tree-ssa-alias.c (refs_may_alias_p_1): Do not use TBAA
21793         for decl-vs-decl disambiguation.
21794
21795 2009-04-17  Andreas Krebbel  <krebbel1@de.ibm.com>
21796
21797         * config/s390/s390.h (s390_tune_attr): New macro definition.
21798         * config/s390/s390.md (cpu attribute): Map to s390_tune_attr.
21799
21800 2009-04-17  Richard Guenther  <rguenther@suse.de>
21801
21802         * tree-ssa-ccp.c (struct fold_stmt_r_data): Remove.
21803         (fold_stmt_r): Likewise.
21804         (maybe_fold_reference): New function.
21805         (fold_gimple_assign): Handle cases fold_stmt_r did.
21806         (fold_stmt): Do not use fold_stmt_r.
21807         (fold_stmt_inplace): Likewise.
21808
21809 2009-04-17  Richard Guenther  <rguenther@suse.de>
21810
21811         * tree-ssa-dom.c (gimple_assign_unary_useless_conversion_p): Remove.
21812         (record_equivalences_from_stmt): Remove useless checks and
21813         simplifications.
21814         * tree-ssa-pre.c (eliminate): Avoid converting a constant if
21815         the type is already suitable.
21816
21817 2009-04-17  Paolo Bonzini  <bonzini@gnu.org>
21818
21819         * config/sh/sh.h (FUNCTION_VALUE): Fix call to sh_promote_prototypes.
21820
21821 2009-04-17  Uros Bizjak  <ubizjak@gmail.com>
21822
21823         * config/arm/sfp-machine.h (__gcc_CMPtype): New typedef.
21824         (CMPtype): Define as __gcc_CMPtype.
21825
21826 2009-04-17  Aurelien Jarno  <aurelien@aurel32.net>
21827
21828         * config.gcc: Add soft-fp/t-softfp and i386/t-linux to tmake_file
21829         for i[34567]86-*-kfreebsd*-gnu*, x86_64-*-kfreebsd*-gnu*.
21830
21831 2009-04-17  Richard Guenther  <rguenther@suse.de>
21832
21833         PR tree-optimization/39746
21834         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Remove
21835         special-casing for builtins and static variable use/def.
21836         (call_may_clobber_ref_p_1): Likewise.
21837
21838 2009-04-16  Ian Lance Taylor  <iant@google.com>
21839
21840         * df.h: Include "timevar.h".
21841         (struct df_problem): Change tv_id field to timevar_id_t.
21842         * tree-pass.h: Include "timevar.h".
21843         (struct opt_pass): Change tv_id field to timevar_id_t.
21844         * timevar.h (timevar_id_t): Define TV_NONE.
21845         * passes.c (execute_one_ipa_transform_pass): Check for tv_id !=
21846         TV_NONE rather than tv_id != 0.
21847         (execute_one_pass): Likewise.
21848         * Makefile.in (DF_H): Add $(TIMEVAR_H).
21849         (TREE_PASS_H): Define.  Change all instances of tree-pass.h in
21850         dependencies to $(TREE_PASS_H).
21851         * bt-load.c (pass_branch_target_load_optimize1): Set tv_id field
21852         to TV_NONE.
21853         (pass_branch_target_load_optimize2): Likewise.
21854         * cfglayout.c (pass_into_cfg_layout_mode): Likewise.
21855         (pass_outof_cfg_layout_mode): Likewise.
21856         * cgraphbuild.c (pass_remove_cgraph_callee_edges): Likewise.
21857         (pass_rebuild_cgraph_edges): Likewise.
21858         (pass_remove_cgraph_callee_edges): Likewise.
21859         * df-core.c (pass_df_initialize_opt): Likewise.
21860         (pass_df_initialize_no_opt): Likewise.
21861         (pass_df_finish): Likewise.
21862         * emit-rtl.c (pass_unshare_all_rtl): Likewise.
21863         * except.c (pass_set_nothrow_function_flags): Likewise.
21864         (pass_convert_to_eh_region_ranges): Likewise.
21865         * final.c (pass_compute_alignments): Likewise.
21866         * function.c (pass_instantiate_virtual_regs): Likewise.
21867         (pass_init_function): Likewise.
21868         (pass_leaf_regs): Likewise.
21869         (pass_match_asm_constraints): Likewise.
21870         * gimple-low.c (pass_lower_cf): Likewise.
21871         (pass_mark_used_blocks): Likewise.
21872         * init-regs.c (pass_initialize_regs): Likewise.
21873         * integrate.c (pass_initial_value_sets): Likewise.
21874         * ira.c (pass_ira): Likewise.
21875         * jump.c (pass_cleanup_barriers): Likewise.
21876         * omp-low.c (pass_expand_omp): Likewise.
21877         (pass_lower_omp): Likewise.
21878         * matrix-reorg.c (pass_ipa_matrix_reorg): Likewise.
21879         * recog.c (pass_split_all_insns): Likewise.
21880         (pass_split_after_reload): Likewise.
21881         (pass_split_before_regstack): Likewise.
21882         (pass_split_before_sched2): Likewise.
21883         (pass_split_for_shorten_branches): Likewise.
21884         * reginfo.c (pass_reginfo_init): Likewise.
21885         (pass_subregs_of_mode_init): Likewise.
21886         (pass_subregs_of_mode_finish): Likewise.
21887         * passes.c (pass_postreload): Likewise.
21888         * stack-ptr-mod.c (pass_stack_ptr_mod): Likewise.
21889         * tree-cfg.c (pass_remove_useless_stmts): Likewise.
21890         (pass_warn_function_return): Likewise.
21891         (pass_warn_function_noreturn): Likewise.
21892         * tree-complex.c (pass_lower_complex): Likewise.
21893         (pass_lower_complex_O0): Likewise.
21894         * tree-if-conv.c (pass_if_conversion): Likewise.
21895         * tree-into-ssa.c (pass_build_ssa): Likewise.
21896         * tree-mudflap.c (pass_mudflap_1): Likewise.
21897         (pass_mudflap_2): Likewise.
21898         * tree-nomudflap.c (pass_mudflap_1): Likewise.
21899         (pass_mudflap_2): Likewise.
21900         * tree-nrv.c (pass_return_slot): Likewise.
21901         * tree-object-size.c (pass_object_sizes): Likewise.
21902         * tree-optimize.c (pass_all_optimizations): Likewise.
21903         (pass_early_local_passes): Likewise.
21904         (pass_all_early_optimizations): Likewise.
21905         (pass_cleanup_cfg): Likewise.
21906         (pass_cleanup_cfg_post_optimizing): Likewise.
21907         (pass_free_datastructures): Likewise.
21908         (pass_free_cfg_annotations): Likewise.
21909         (pass_fixup_cfg): Likewise.
21910         (pass_init_datastructures): Likewise.
21911         * tree-ssa.c (pass_early_warn_uninitialized): Likewise.
21912         (pass_late_warn_uninitialized): Likewise.
21913         (pass_update_address_taken): Likewise.
21914         * tree-ssa-ccp.c (pass_fold_builtins): Likewise.
21915         * tree-ssa-math-opts.c (pass_cse_reciprocals): Likewise.
21916         (pass_cse_sincos): Likewise.
21917         (pass_convert_to_rsqrt): Likewise.
21918         * tree-ssa-structalias.c (pass_build_alias): Likewise.
21919         * tree-stdarg.c (pass_stdarg): Likewise.
21920         * tree-tailcall.c (pass_tail_recursion): Likewise.
21921         (pass_tail_calls): Likewise.
21922         * tree-vect-generic.c (pass_lower_vector): Likewise.
21923         (pass_lower_vector_ssa): Likewise.
21924         * tree-vectorizer.c (pass_ipa_increase_alignment): Likewise.
21925
21926 2009-04-16  Joseph Myers  <joseph@codesourcery.com>
21927
21928         * config/mips/mips.c (mips_rtx_cost_data): Use SOFT_FP_COSTS in
21929         XLR entry.
21930         * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC, MIPS_ARCH_FLOAT_SPEC):
21931         Handle -march=xlr.
21932         * config/mips/xlr.md (ir_xlr_alu): Also accept insn types move,
21933         logical and signext.
21934
21935 2009-04-16  Kaz Kojima  <kkojima@gcc.gnu.org>
21936
21937         PR target/39767
21938         * config/sh/predicates.md (arith_operand): Check if the operand
21939         of TRUNCATE is a REG.
21940
21941 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
21942
21943         * cfgrtl.c (delete_insn_chain_and_edges): Remove.
21944         * rtl.h: Remove the prototype for delete_insn_chain_and_edges.
21945
21946 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
21947
21948         * tree-iterator.c (tsi_split_statement_list_after,
21949         tsi_split_statement_list_before): Remove.
21950         * tree-iterator.h: Remove the prototypes for
21951         tsi_split_statement_list_after and tsi_split_statement_list_before.
21952
21953 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
21954
21955         * tree-ssa-propagate.c (stmt_makes_single_load): Remove.
21956         * tree-ssa-propagate.h: Remove the prototype for
21957         stmt_makes_single_load.
21958
21959 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
21960
21961         * emit-rtl.c (set_mem_attrs_from_reg): Remove.
21962         * rtl.h: Remove the prototype for set_mem_attrs_from_reg.
21963
21964 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
21965
21966         * tree-iterator.c (EXPR_LAST_BODY): Remove.
21967
21968 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
21969
21970         * except.c (eh_region_outer_p): Remove.
21971         * except.h: Remove the prototype for eh_region_outer_p.
21972
21973 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
21974
21975         * function.c (current_function_assembler_name): Remove.
21976         * function.h: Remove the prototype for
21977         current_function_assembler_name.
21978
21979 2009-04-16  Ian Lance Taylor  <iant@google.com>
21980
21981         * rtlanal.c (alloc_reg_note): New function, broken out of add_reg_note.
21982         (add_reg_note): Call alloc_reg_note.
21983         * rtl.h (alloc_reg_note): Declare.
21984         * combine.c (try_combine): Use alloc_reg_note.
21985         (recog_for_combine, move_deaths): Likewise.
21986         (distribute_notes): Use alloc_reg_note and add_reg_note.
21987         * haifa-sched.c (sched_create_recovery_edges): Use add_reg_note.
21988         * combine-stack-adj.c (adjust_frame_related_expr): Likewise.
21989         * reload1.c (eliminate_regs_1): Use alloc_reg_note.
21990
21991 2009-04-16  Vladimir Makarov  <vmakarov@redhat.com>
21992
21993         PR rtl-optimization/39762
21994         * ira-int.h (ira_register_move_cost, ira_may_move_in_cost,
21995         ira_may_move_out_cost): Add comments about way of their usage.
21996         (ira_get_register_move_cost, ira_get_may_move_cost): New functions.
21997
21998         * ira-conflicts.c (process_regs_for_copy): Use function
21999         ira_get_register_move_cost instead of global
22000         ira_register_move_cost.
22001
22002         * ira-color.c (update_copy_costs, calculate_allocno_spill_cost,
22003         color_pass, move_spill_restore, update_curr_costs): Ditto.
22004
22005         * ira-lives.c (process_single_reg_class_operands): Ditto.
22006
22007         * ira-emit.c (emit_move_list): Ditto.
22008
22009         * ira-costs.c (copy_cost): Don't call ira_init_register_move_cost.
22010         (record_reg_classes): Ditto.  Use functions
22011         ira_get_register_move_cost and ira_get_may_move_cost instead of
22012         global vars ira_register_move_cost, ira_may_move_out_cost and
22013         ira_may_move_in_cost.
22014         (record_address_regs): Don't call ira_init_register_move_cost.
22015         Use function ira_get_may_move_cost instead of global
22016         ira_may_move_in_cost.
22017         (process_bb_node_for_hard_reg_moves): Use function
22018         ira_get_register_move_cost instead of global ira_register_move_cost.
22019         (ira_costs): Don't call ira_init_register_move_cost.
22020
22021 2009-04-16  Richard Guenther  <rguenther@suse.de>
22022
22023         * tree-cfg.c (verify_gimple_assign_binary):
22024         Allow POINTER_PLUS_EXPR-like PLUS_EXPR for vectors.
22025         * ipa-struct-reorg.c (gen_size): Fold the built expressions.
22026         (create_general_new_stmt): Note that this function is broken.
22027
22028 2009-04-16  Rafael Avila de Espindola  <espindola@google.com>
22029
22030         * common.opt (fhelp): Add Var(help_flag).
22031         * gcc-plugin.h (plugin_info): Add help.
22032         * plugin.c (plugin_name_args): Add help.
22033         (register_plugin_info): Set plugin->help.
22034         (print_help_one_plugin): New.
22035         (print_plugins_help): New.
22036         * plugin.h (print_plugins_help): New.
22037         * toplev.c (toplev_main): Call print_plugins_help if needed.
22038
22039 2009-04-16  Richard Guenther  <rguenther@suse.de>
22040
22041         * gimple.c (gimple_copy): Do not clear addresses_taken bitmap.
22042         (gimple_ior_addresses_taken_1): New function.
22043         (gimple_ior_addresses_taken): Likewise.
22044         * gimple.h (struct gimple_statement_with_ops_base): Remove
22045         addresses_taken member.
22046         (gimple_ior_addresses_taken): Declare.
22047         (gimple_addresses_taken, gimple_addresses_taken_ptr,
22048         gimple_set_addresses_taken): Remove.
22049         * ipa-reference.c (mark_address): New function.
22050         (scan_stmt_for_static_refs): Use it for marking addresses taken.
22051         * tree-ssa-operands.c (add_to_addressable_set): Rename to ...
22052         (mark_address_taken): ... this.  Just set TREE_ADDRESSABLE.
22053         (gimple_add_to_addresses_taken): Remove.
22054         (get_tmr_operands): Call mark_address_taken.
22055         (get_asm_expr_operands): Likewise.
22056         (get_expr_operands): Likewise.
22057         (build_ssa_operands): Do not clear the addresses_taken bitmap.
22058         (free_stmt_operands): Do not free it.
22059         * tree-ssa.c (delete_tree_ssa): Likewise.
22060         (execute_update_addresses_taken): Use gimple_ior_addresses_taken.
22061
22062 2009-04-16  Richard Guenther  <rguenther@suse.de>
22063
22064         * gimple.h (walk_stmt_load_store_addr_ops): Declare.
22065         (walk_stmt_load_store_ops): Likewise.
22066         * gimple.c (get_base_loadstore): New function.
22067         (walk_stmt_load_store_addr_ops): Likewise.
22068         (walk_stmt_load_store_ops): Likewise.
22069         * ipa-pure-const.c (check_op): Simplify.
22070         (check_load, check_store): New functions.
22071         (check_stmt): Use walk_stmt_load_store_ops.
22072         * ipa-reference.c (mark_load): Adjust signature.
22073         (mark_store): Likewise.
22074         (scan_stmt_for_static_refs): Use walk_stmt_load_store_addr_ops.
22075
22076 2009-04-16  Rafael Avila de Espindola  <espindola@google.com>
22077
22078         * gcc-plugin.h (plugin_event): Add PLUGIN_INFO.
22079         (plugin_info): New.
22080         * opts.c (common_handle_option): Don't call print_version.
22081         * plugin.c (plugin_name_args): Add version.
22082         (register_plugin_info): New.
22083         (register_callback): Handle PLUGIN_INFO.
22084         (try_init_one_plugin): New.
22085         (init_one_plugin): Use try_init_one_plugin. Only free plugin_name_args
22086         if failed to init.
22087         (finalize_one_plugin): New.
22088         (finalize_plugins): New.
22089         (print_one_plugin): New.
22090         (print_plugins_versions): New.
22091         * plugin.h (print_plugins_versions): New.
22092         (finalize_plugins): New.
22093         * toplev.c (compile_file): Don't call initialize_plugins.
22094         (print_version): Call print_plugins_versions.
22095         (toplev_main): Call initialize_plugins. Print version if needed.
22096         Call finalize_plugins.
22097
22098 2009-04-16  Rafael Avila de Espindola  <espindola@google.com>
22099
22100         * common.opt (fversion): New.
22101         * gcc.c (print_version): New.
22102         (process_command): Don't print the version. Just set print_version.
22103         (main): Print version. Call subprocesses if print_version and
22104         verbose_flag are set.
22105         * opts.c (common_handle_option): Handle OPT_fversion.
22106
22107 2009-04-16  Richard Guenther  <rguenther@suse.de>
22108             Ira Rosen  <irar@il.ibm.com>
22109
22110         PR tree-optimization/39698
22111         * tree-vect-loop.c (get_initial_def_for_reduction): Use the
22112         type of the reduction variable.  Only generate the def if
22113         it is needed.
22114
22115         * omp-low.c (expand_omp_for_generic): When converting to a pointer
22116         make sure to first convert to an integer of the same precision.
22117         * tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer): Retain
22118         the type of the evolution correctly in computing the new
22119         induction variable base.
22120
22121 2009-04-16  Richard Guenther  <rguenther@suse.de>
22122
22123         PR middle-end/39625
22124         * tree-cfg.c (make_blocks): Split statements with to-be
22125         abnormal SSA names on the lhs.
22126
22127 2009-04-16  Paolo Bonzini  <bonzini@gnu.org>
22128
22129         * c-common.c (vector_targets_convertible_p, vector_types_convertible_p):
22130         Use TYPE_VECTOR_OPAQUE instead of targetm.vector_opaque_p.
22131         * c-typeck.c (really_start_incremental_init): Likewise.
22132         * target-def.h (TARGET_VECTOR_OPAQUE_P): Remove.
22133         (TARGET_INITIALIZER): Remove it.
22134         * target.h (struct target): Remove vector_opaque_p.
22135         * tree.c (build_opaque_vector_type): New.
22136         * tree.h (TYPE_VECTOR_OPAQUE): New.
22137         (build_opaque_vector_type): Declare.
22138         * doc/tm.texi (TARGET_VECTOR_OPAQUE_P): Remove.
22139         * config/rs6000/rs6000.c (build_opaque_vector_type,
22140         rs6000_is_vector_type, TARGET_VECTOR_OPAQUE_P): Remove.
22141         (rs6000_init_builtins): Use build_opaque_vector_type for
22142         opaque_V4SI_type_node.
22143
22144 2009-04-15  Catherine Moore  <clm@codesourcery.com>
22145
22146         * debug.h (set_name):  Declare.
22147         * dwarf2out.c (dwarf2out_set_name): Declare.
22148         (dwarf2_debug_hooks): Add set_name.
22149         (find_AT_string): New.
22150         (add_AT_string): Call find_AT_string.
22151         (dwarf2out_set_name): New.
22152         * cp/decl.c (grokdeclarator): Call set_name.
22153         * vmsdbgout.c (vmsdbg_debug_hooks): Add set_name_debug_nothing.
22154         * debug.c (do_nothing_debug_hooks):  Likewise.
22155         * dbxout.c (dbx_debug_hooks): Likewise.
22156         * sdbout.c (sdb_debug_hooks): Likewise.
22157
22158 2009-04-15  Michael Eager  <eager@eagercon.com>
22159
22160         * config/rs6000/rs6000.c (rs6000_function_value): Set function return
22161         reg for single-precision FPU.
22162         * config/rs6000/rs6000.md (movsi_internal1): Only for
22163         !TARGET_SINGLE_FPU.
22164         (movsi_internal1_single): New. Add pattern to move SI values to/from
22165         single-precision FP regs.
22166
22167 2009-04-15  Richard Guenther  <rguenther@suse.de>
22168
22169         * omp-low.c (lower_rec_input_clauses): Build correct address
22170         expressions.
22171         (expand_omp_for_generic): Fix multiplication type.
22172         * tree-loop-distribution.c (build_size_arg): Build a size_t argument.
22173         (generate_memset_zero): Fix types.
22174         * tree-profile.c (prepare_instrumented_value): Correctly
22175         widen a pointer.
22176
22177 2009-04-15  Ian Lance Taylor  <iant@google.com>
22178
22179         * c.opt (Wenum-compare): Enable for C and Objc.  Initialize to -1.
22180         * c-opts.c (c_common_handle_option): For C, set warn_enum_compare
22181         for -Wall and for -Wc++-compat.
22182         (c_common_post_options): For C++, set warn_enum_compare if not
22183         already set.
22184         * c-tree.h (struct c_expr): Add field original_type.
22185         (build_external_ref): Update declaration.
22186         * c-parser.c (c_parser_braced_init): Set original_type.
22187         (c_parser_initelt): Likewise.
22188         (c_parser_expr_no_commas): Likewise.
22189         (c_parser_conditional_expression): Likewise.
22190         (c_parser_cast_expression): Likewise.
22191         (c_parser_unary_expression): Likewise.  Pull setting of
22192         original_code to top of function.
22193         (c_parser_sizeof_expression): Set original_type.
22194         (c_parser_alignof_expression): Likewise.
22195         (c_parser_postfix_expression): Likewise.  Pull setting of
22196         original_code to top of function.
22197         (c_parser_postfix_expression_after_paren_type): Set original_type.
22198         (c_parser_postfix_expression_after_primary): Likewise.
22199         (c_parser_expression): Likewise.
22200         * c-typeck.c (build_external_ref): Add type parameter.  Change all
22201         callers.
22202         (c_expr_sizeof_expr): Set original_type field.
22203         (parser_build_unary_op): Likewise.
22204         (parser_build_binary_op): Likewise.  Optionally warn about
22205         comparisons of enums of different types.
22206         (digest_init): Set original_type field.
22207         (really_start_incremental_init): Likewise.
22208         (push_init_level, pop_init_level): Likewise.
22209         * doc/invoke.texi (Warning Options): -Wenum-compare now
22210         supported in C.
22211
22212 2009-04-15  Richard Guenther  <rguenther@suse.de>
22213
22214         * tree-ssa-pre.c (eliminate): When replacing a PHI node carry
22215         out a necessary conversion.
22216         * tree-ssa-sccvn.c (run_scc_vn): Also assign value-ids to
22217         names we didn't value number.
22218         * tree-mudflap.c (mf_build_check_statement_for): Use correct types.
22219
22220 2009-04-15  Richard Guenther  <rguenther@suse.de>
22221
22222         PR tree-optimization/39764
22223         * tree-ssa-ccp.c (get_value): Canonicalize value with
22224         canonicalize_float_value.
22225
22226 2009-04-15  Jan Hubicka  <jh@suse.cz>
22227
22228         * builtins.def (va_start, va_end, va_copy): Fix my previous commit.
22229         Wrong version of patch.
22230
22231 2009-04-15  Jan Hubicka  <jh@suse.cz>
22232
22233         * builtins.def (va_start, va_end, va_copy): Mark nothrow.
22234
22235 2009-04-15  Nathan Sidwell  <nathan@codesourcery.com>
22236
22237         * config/rs6000/rs6000.c (rs6000_init_builtins): Set TYPE_NAME of
22238         our distinct integral and vector types.
22239
22240 2009-04-15  Rafael Avila de Espindola  <espindola@google.com>
22241
22242         * class.c (build_vtbl_ref_1): Remove call to assemble_external.
22243         * init.c (build_vtbl_address): Remove call to assemble_external.
22244
22245 2009-04-14  Daniel Jacobowitz  <dan@codesourcery.com>
22246
22247         * config/rs6000/rs6000.c (rs6000_dwarf_register_span): Fix debug
22248         output for other floating point modes.
22249
22250 2009-04-14  Diego Novillo  <dnovillo@google.com>
22251
22252         * diagnostic.c (diagnostic_report_diagnostic): Do not
22253         warn about loaded plugins for DK_ERROR and DK_WARNING.
22254         * c-decl.c (declspecs_add_type): Move call to
22255         invoke_plugin_callbacks ...
22256         * c-parser.c (c_parser_declspecs): ... here.
22257         * plugin.c (dump_active_plugins): Tidy output.
22258
22259 2009-04-14  Diego Novillo  <dnovillo@google.com>
22260             Le-Chun Wu  <lcwu@google.com>
22261
22262         * configure.ac: Add --enable-plugin support.
22263         Define ENABLE_PLUGIN and PLUGINLIBS when specified.
22264         * Makefile.in (PLUGIN_H): Define.
22265         Export ENABLE_PLUGIN and GMPINC to site.exp.
22266         Add PLUGINLIBS to link command.
22267         Add/modify dependencies for plugin.o and files including plugin.h.
22268         (plugin.o): New.
22269         * config.in: Regenerate.
22270
22271         * opts.c (common_handle_option): Handle OPT_fplugin_ and
22272         OPT_fplugin_arg_.
22273
22274 2009-04-14  Le-Chun Wu  <lcwu@google.com>
22275
22276         * tree-pass.h (register_one_dump_file): Add a prototype for
22277         register_one_dump_file.
22278         * toplev.c (compile_file): Call initialize_plugins.
22279         (do_compile): Call invoke_plugin_callbacks.
22280         (toplev_main): Call invoke_plugin_callbacks.
22281         * common.opt: Add -fplugin= and -fplugin-arg-.
22282         * gcc-plugin.h: New public header file for plugins to include.
22283         * plugin.c: New source file.
22284         * plugin.h: New internal header file.
22285         * passes.c (register_one_dump_file): Make it external.
22286
22287         * c-parser.c (c_parser_declspecs): Call invoke_plugin_callbacks.
22288
22289 2009-04-14  Diego Novillo  <dnovillo@google.com>
22290
22291         * doc/plugins.texi: New.
22292         * doc/gccint.texi: Add reference to Plugins chapter.
22293         * doc/invoke.texi: Document -fplugin and -fplugin-arg
22294         * diagnostic.c (diagnostic_report_diagnostic): Warn about
22295         loaded plugins, if any.
22296         * timevar.def (TV_PLUGIN_INIT): Define.
22297         (TV_PLUGIN_RUN): Define.
22298         * plugin.c: Include timevar.h
22299         (plugins_active_p): New.
22300         (dump_active_plugins): New.
22301         (debug_active_plugins): New.
22302
22303 2009-04-14  Joseph Myers  <joseph@codesourcery.com>
22304
22305         * config/sol2.h (LINK_ARCH32_SPEC_BASE): Use %R with absolute
22306         library paths.
22307         * config/sparc/sol2-bi.h (LINK_ARCH64_SPEC_BASE): Likewise.
22308
22309 2009-04-14  Kazu Hirata  <kazu@codesourcery.com>
22310
22311         * config/arm/arm.c (arm_rtx_costs_1): Treat a minus with a shift
22312         the same as a minus without a shift.
22313
22314 2009-04-14  Nick Clifton  <nickc@redhat.com>
22315
22316         * config/stormy16/stormy16.md (ineqbranch_1): Do not assume that
22317         comparisons with small integers will always produce a short
22318         branch.
22319
22320 2009-04-14  Rafael Avila de Espindola  <espindola@google.com>
22321
22322         Merge:
22323         2008-12-19  Diego Novillo  <dnovillo@google.com>
22324
22325         * cgraph.c (dump_cgraph_node): Show memory address of NODE.
22326
22327 2009-04-14  Richard Guenther  <rguenther@suse.de>
22328
22329         * tree-cfg.c (verify_gimple_assign_unary): Adjust vector code
22330         verification.
22331         (verify_gimple_assign_binary): Likewise.  Handle shifts and
22332         rotates correctly.
22333         (verify_gimple_phi): Print the mismatched argument position.
22334         * tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer):
22335         Fix types.
22336         (vect_update_init_of_dr): Likewise.
22337         * matrix-reorg.c (transform_access_sites): Do what the
22338         comment suggests.
22339         * omp-low.c (expand_omp_atomic_pipeline): Use the correct types.
22340
22341 2009-04-13  Michael Eager  <eager@eagercon.com>
22342
22343         * config/rs6000/rs6000-c.c: generate defines if rs6000_xilinx_fpu:
22344         _XFPU, _XFPU_SP_LITE, _XFPU_SP_FULL, _XFPU_DP_LITE, _XFPU_DP_FULL
22345         * config/rs6000/xilinx.h: New.  Spec for powerpc-xilinx-eabi
22346         * config.gcc (powerpc-xilinx-eabi): add xilinx.h to tm_file,
22347         remove duplicate config
22348
22349 2009-04-13  Dwarakanath Rajagopal  <dwarak.rajagopal@amd.com>
22350
22351         * ipa-inline.c (cgraph_decide_inlining_of_small_function): Dump
22352         file_name:line_number type locator of the call site.
22353
22354 2009-04-13  Vladimir Makarov  <vmakarov@redhat.com>
22355
22356         * genautomata.c: Put blank after comma.
22357         (automaton_decls): New.
22358         (struct unit_usage): Add comments to member next.
22359         (store_alt_unit_usage): Keep the list ordered.
22360         (unit_present_on_list_p, equal_alternatives_p): New.
22361         (check_regexp_units_distribution): Check units distribution
22362         correctness correctly.
22363         (main): Don't write automata if error is found.  Return correct
22364         exit code.
22365
22366         * config/m68k/cf.md (cfv4_ds): Remove.
22367         (cfv4_pOEP1, cfv4_sOEP1, cfv4_pOEP2,cfv4_sOEP2, cfv4_pOEP3,
22368         cfv4_sOEP3): Assign to cfv4_oep instead of cfv4_ds.
22369
22370         * config/rs6000/power4.md (lsuq_power4, iq_power4, fpq_power4,
22371         power4-load-ext, power4-store, power4-store-update,
22372         power4-fpstore, power4-fpstore-update, power4-two, power4-three,
22373         power4-insert, power4-compare, power4-lmul-cmp, power4-imul-cmp,
22374         power4-lmul, , power4-imul, power4-imul3, power4-sdiv,
22375         power4-sqrt, power4-isync): Modify reservation to make correct
22376         unit distribution to automata.
22377
22378         * config/rs6000/power5.md (iq_power5, fpq_power5, power5-store,
22379         power5-store-update, power5-two, power5-three, power5-lmul,
22380         power5-imul, power5-imul3, power5-sdiv, power5-sqrt): Ditto.
22381
22382 2009-04-13  Adam Nemet  <anemet@caviumnetworks.com>
22383
22384         * except.c (pass_set_nothrow_function_flags): Set name and add
22385         TODO_dump_func.
22386         (set_nothrow_function_flags): Mention in the dump file when
22387         changing a function to nothrow.
22388
22389 2009-04-13  Ozkan Sezer  <sezeroz@gmail.com>
22390
22391         PR/39066
22392         * gbl-ctors.h (DO_GLOBAL_CTORS_BODY): Use __SIZE_TYPE__
22393         instead of unsigned long.
22394
22395 2009-04-13  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
22396
22397         * config/arm/arm.c (return_used_this_function): Remove.
22398         (arm_output_function_prologue): Remove use of
22399         return_used_this_function.
22400         (output_return_instruction): Replace use of
22401         return_used_this_function
22402         by cfun->machine->return_used_this_function.
22403         (arm_output_epilogue): Likewise.
22404         (arm_output_function_epilogue): Likewise.
22405         (thumb_unexpanded_epilogue): Likewise.
22406         * config/arm/arm.h (struct machine_function):
22407         New member return_used_this_function.
22408
22409 2009-04-12  Mark Mitchell  <mark@codesourcery.com>
22410
22411         * doc/install.texi: Correct description of default directory for
22412         --with-gxx-include-dir.
22413
22414 2009-04-12  Eric Botcazou  <ebotcazou@adacore.com>
22415
22416         * fold-const.c (build_range_check): Properly deal with enumeral and
22417         boolean base types.
22418
22419 2009-04-12  Steven Bosscher  <steven@gcc.gnu.org>
22420
22421         * doc/invoke.texi (max_gcse_passes): Remove documentation.
22422         * params.def (PARAM_MAX_GCSE_PASSES): Remove.
22423         * params.h (MAX_GCSE_PASSES): Remove.
22424         * gcse.c (gcse_main): Run CPROP1, PRE or HOIST, and CPROP2
22425         in sequence.  Remove ability to run multiple passes.
22426         (bypass_jumps): Report run as third CPROP pass.
22427
22428 2009-04-12  Adam Nemet  <anemet@caviumnetworks.com>
22429
22430         PR middle-end/39651
22431         * except.c (can_throw_external): Look at each insn in a SEQUENCE
22432         when deciding whether the whole SEQUENCE can throw.
22433
22434 2009-04-12  Uros Bizjak  <ubizjak@gmail.com>
22435
22436         PR target/39740
22437         * config/alpha/predicates.md (local_symbolic_operand): Return 1 for
22438         offseted label references.
22439
22440 2009-04-11  Jan Hubicka  <jh@suse.cz>
22441
22442         * tree-ssa-pre.c (eliminate): Fix call of update_stmt.
22443
22444 2009-04-11  Richard Guenther  <rguenther@suse.de>
22445
22446         PR middle-end/39732
22447         * tree-inline.c (declare_return_variable): Mark DECL_BY_REFERENCE
22448         return variables as TREE_ADDRESSABLE.
22449
22450 2009-04-11  Richard Guenther  <rguenther@suse.de>
22451
22452         PR tree-optimization/39713
22453         * tree-ssa-sccvn.c (vn_get_expr_for): Make sure built
22454         reference trees have SSA_NAME operands.
22455
22456 2009-04-11  Richard Guenther  <rguenther@suse.de>
22457
22458         PR c/39712
22459         * c-gimplify.c (c_gimplify_expr): Adjust check for mismatched
22460         address expressions.
22461
22462 2009-04-11  Dave Korn  <dave.korn.cygwin@gmail.com>
22463
22464         * config/i386/cygwin-stdint.h (INT_LEAST32_TYPE):  Update to
22465         match changes in Cygwin 1.7
22466         (UINT_LEAST32_TYPE, INT_FAST16_TYPE, INT_FAST32_TYPE,
22467         UINT_FAST16_TYPE, UINT_FAST32_TYPE):  Likewise.
22468
22469 2009-04-10  Paolo Bonzini  <bonzini@gnu.org>
22470
22471         PR tree-optimization/39701
22472         * doc/invoke.texi (Optimization Options): Document change in
22473         meaning and initialization of -fdelete-null-pointer-checks.
22474
22475 2009-04-10  H.J. Lu  <hongjiu.lu@intel.com>
22476
22477         PR middle-end/39701
22478         * common.opt (-fdelete-null-pointer-checks): Initialize to 1.
22479
22480         * opts.c (decode_options): Don't set flag_delete_null_pointer_checks
22481         here.
22482
22483         * doc/invoke.texi: Update -fdelete-null-pointer-checks.
22484
22485 2009-04-10  Chao-ying Fu  <fu@mips.com>
22486
22487         * doc/tm.texi (Instruction Output): Document
22488         TARGET_ASM_FINAL_POSTSCAN_INSN.
22489         * target.h (final_postscan_insn): New field in asm_out.
22490         * target-def.h (TARGET_ASM_FINAL_POSTSCAN_INSN): New define.
22491         (TARGET_ASM_OUT): Add TARGET_ASM_FINAL_POSTSCAN_INSN.
22492         * final.c (final_scan_insn): Call
22493         targetm.asm_out.final_postscan_insn after outputting
22494         an asm macro and a normal instruction.
22495
22496         * config/mips/mips.h (FINAL_PRESCAN_INSN): New define.
22497         * config/mips/mips-protos.h (mips_final_prescan_insn): Declare.
22498         * config/mips/mips.c (mips_at_reg_p): New for_each_rtx callback.
22499         (mips_final_prescan_insn, mips_final_postscan_insn): New functions.
22500         (TARGET_ASM_FINAL_POSTSCAN_INSN): New define.
22501
22502 2009-04-10  Paolo Bonzini  <bonzini@gnu.org>
22503
22504         PR middle-end/39701
22505         * fold-const.c (tree_single_nonzero_warnv_p): Pass non-static
22506         variables as non-NULL even with -fdelete-null-pointer-checks.
22507
22508 2009-04-10  H.J. Lu  <hongjiu.lu@intel.com>
22509
22510         * config/rs6000/darwin-vecsave.asm: Remove extra "*/".
22511
22512 2009-04-09  H.J. Lu  <hongjiu.lu@intel.com>
22513
22514         PR target/39678
22515         * config/i386/i386.c (classify_argument): Handle SCmode with
22516         (bit_offset % 64) != 0.
22517
22518 2009-04-09  Sandra Loosemore  <sandra@codesourcery.com>
22519
22520         * doc/invoke.texi (Optimize Options): Add cross-reference to
22521         -Q --help=optimizers examples.
22522
22523 2009-04-10  Ben Elliston  <bje@au.ibm.com>
22524
22525         PR target/36800
22526         * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Do not set
22527         regalign for the reg == fpr and TDmode case.
22528
22529 2009-04-09  David Ayers  <ayers@fsfe.org>
22530
22531         PR objc/29200
22532         * objc/objc-act.c (warn_with_method): Remove helper function.
22533         (check_duplicates): Call warning and inform directly.
22534         (really_start_method): Likewise.
22535
22536 2009-04-09  Paolo Bonzini  <bonzini@gnu.org>
22537
22538         * expmed.c (expand_divmod): Always use a comparison for a division
22539         by a large unsigned integer.
22540
22541         * fold-const.c (tree_single_nonzero_warnv_p): Always treat decls
22542         for things others than variables or functions as nonzero.
22543
22544 2009-04-09  Nick Clifton  <nickc@redhat.com>
22545
22546         * unwind-compat.c: Change copyright header to refer to version
22547         3 of the GNU General Public License with version 3.1 of the
22548         GCC Runtime Library Exception and to point readers at the
22549         COPYING3 and COPYING3.RUNTIME files and the FSF's license web page.
22550         * config/alpha/crtfastmath.c: Likewise.
22551         * config/alpha/linux-unwind.h: Likewise.
22552         * config/alpha/qrnnd.asm: Likewise.
22553         * config/alpha/vms-crt0-64.c: Likewise.
22554         * config/alpha/vms-crt0.c: Likewise.
22555         * config/alpha/vms-dwarf2.asm: Likewise.
22556         * config/alpha/vms-dwarf2eh.asm: Likewise.
22557         * config/alpha/vms-psxcrt0-64.c: Likewise.
22558         * config/alpha/vms-psxcrt0.c: Likewise.
22559         * config/alpha/vms_tramp.asm: Likewise.
22560         * config/arc/initfini.c: Likewise.
22561         * config/arc/lib1funcs.asm: Likewise.
22562         * config/arm/bpabi-v6m.S: Likewise.
22563         * config/arm/bpabi.S: Likewise.
22564         * config/arm/bpabi.c: Likewise.
22565         * config/arm/crti.asm: Likewise.
22566         * config/arm/crtn.asm: Likewise.
22567         * config/arm/ieee754-df.S: Likewise.
22568         * config/arm/ieee754-sf.S: Likewise.
22569         * config/arm/lib1funcs.asm: Likewise.
22570         * config/arm/libunwind.S: Likewise.
22571         * config/arm/linux-atomic.c: Likewise.
22572         * config/arm/mmintrin.h: Likewise.
22573         * config/arm/pr-support.c: Likewise.
22574         * config/arm/unaligned-funcs.c: Likewise.
22575         * config/arm/unwind-arm.c: Likewise.
22576         * config/arm/unwind-arm.h: Likewise.
22577         * config/avr/libgcc.S: Likewise.
22578         * config/bfin/crti.s: Likewise.
22579         * config/bfin/crtlibid.s: Likewise.
22580         * config/bfin/crtn.s: Likewise.
22581         * config/bfin/lib1funcs.asm: Likewise.
22582         * config/bfin/linux-unwind.h: Likewise.
22583         * config/cris/arit.c: Likewise.
22584         * config/cris/cris_abi_symbol.c: Likewise.
22585         * config/darwin-64.c: Likewise.
22586         * config/darwin-crt2.c: Likewise.
22587         * config/darwin-crt3.c: Likewise.
22588         * config/darwin.h: Likewise.
22589         * config/dbxelf.h: Likewise.
22590         * config/dfp-bit.c: Likewise.
22591         * config/dfp-bit.h: Likewise.
22592         * config/elfos.h: Likewise.
22593         * config/fixed-bit.c: Likewise.
22594         * config/fixed-bit.h: Likewise.
22595         * config/fp-bit.c: Likewise.
22596         * config/fp-bit.h: Likewise.
22597         * config/fr30/crti.asm: Likewise.
22598         * config/fr30/crtn.asm: Likewise.
22599         * config/fr30/lib1funcs.asm: Likewise.
22600         * config/freebsd-spec.h: Likewise.
22601         * config/frv/cmovd.c: Likewise.
22602         * config/frv/cmovh.c: Likewise.
22603         * config/frv/cmovw.c: Likewise.
22604         * config/frv/frvbegin.c: Likewise.
22605         * config/frv/frvend.c: Likewise.
22606         * config/frv/lib1funcs.asm: Likewise.
22607         * config/glibc-stdint.h: Likewise.
22608         * config/h8300/clzhi2.c: Likewise.
22609         * config/h8300/crti.asm: Likewise.
22610         * config/h8300/crtn.asm: Likewise.
22611         * config/h8300/ctzhi2.c: Likewise.
22612         * config/h8300/fixunssfsi.c: Likewise.
22613         * config/h8300/lib1funcs.asm: Likewise.
22614         * config/h8300/parityhi2.c: Likewise.
22615         * config/h8300/popcounthi2.c: Likewise.
22616         * config/i386/ammintrin.h: Likewise.
22617         * config/i386/att.h: Likewise.
22618         * config/i386/avxintrin.h: Likewise.
22619         * config/i386/biarch64.h: Likewise.
22620         * config/i386/bmmintrin.h: Likewise.
22621         * config/i386/cpuid.h: Likewise.
22622         * config/i386/cross-stdarg.h: Likewise.
22623         * config/i386/crtfastmath.c: Likewise.
22624         * config/i386/crtprec.c: Likewise.
22625         * config/i386/cygming-crtbegin.c: Likewise.
22626         * config/i386/cygming-crtend.c: Likewise.
22627         * config/i386/cygwin.asm: Likewise.
22628         * config/i386/emmintrin.h: Likewise.
22629         * config/i386/gmm_malloc.h: Likewise.
22630         * config/i386/gthr-win32.c: Likewise.
22631         * config/i386/i386.h: Likewise.
22632         * config/i386/immintrin.h: Likewise.
22633         * config/i386/linux-unwind.h: Likewise.
22634         * config/i386/linux64.h: Likewise.
22635         * config/i386/mm3dnow.h: Likewise.
22636         * config/i386/mmintrin-common.h: Likewise.
22637         * config/i386/mmintrin.h: Likewise.
22638         * config/i386/nmmintrin.h: Likewise.
22639         * config/i386/pmm_malloc.h: Likewise.
22640         * config/i386/pmmintrin.h: Likewise.
22641         * config/i386/smmintrin.h: Likewise.
22642         * config/i386/sol2-c1.asm: Likewise.
22643         * config/i386/sol2-ci.asm: Likewise.
22644         * config/i386/sol2-cn.asm: Likewise.
22645         * config/i386/sol2-gc1.asm: Likewise.
22646         * config/i386/tmmintrin.h: Likewise.
22647         * config/i386/unix.h: Likewise.
22648         * config/i386/w32-unwind.h: Likewise.
22649         * config/i386/wmmintrin.h: Likewise.
22650         * config/i386/x86-64.h: Likewise.
22651         * config/i386/x86intrin.h: Likewise.
22652         * config/i386/xmmintrin.h: Likewise.
22653         * config/ia64/crtbegin.asm: Likewise.
22654         * config/ia64/crtend.asm: Likewise.
22655         * config/ia64/crtfastmath.c: Likewise.
22656         * config/ia64/crti.asm: Likewise.
22657         * config/ia64/crtn.asm: Likewise.
22658         * config/ia64/fde-glibc.c: Likewise.
22659         * config/ia64/lib1funcs.asm: Likewise.
22660         * config/ia64/linux-unwind.h: Likewise.
22661         * config/ia64/quadlib.c: Likewise.
22662         * config/ia64/unwind-ia64.c: Likewise.
22663         * config/linux.h: Likewise.
22664         * config/m32c/m32c-lib1.S: Likewise.
22665         * config/m32c/m32c-lib2-trapv.c: Likewise.
22666         * config/m32c/m32c-lib2.c: Likewise.
22667         * config/m32r/initfini.c: Likewise.
22668         * config/m68hc11/larith.asm: Likewise.
22669         * config/m68hc11/m68hc11-crt0.S: Likewise.
22670         * config/m68k/cf.md: Likewise.
22671         * config/m68k/crti.s: Likewise.
22672         * config/m68k/crtn.s: Likewise.
22673         * config/m68k/lb1sf68.asm: Likewise.
22674         * config/m68k/linux-unwind.h: Likewise.
22675         * config/mcore/crti.asm: Likewise.
22676         * config/mcore/crtn.asm: Likewise.
22677         * config/mcore/lib1.asm: Likewise.
22678         * config/mips/linux-unwind.h: Likewise.
22679         * config/mips/loongson.h: Likewise.
22680         * config/mips/mips16.S: Likewise.
22681         * config/mmix/crti.asm: Likewise.
22682         * config/mmix/crtn.asm: Likewise.
22683         * config/pa/fptr.c: Likewise.
22684         * config/pa/hpux-unwind.h: Likewise.
22685         * config/pa/lib2funcs.asm: Likewise.
22686         * config/pa/linux-atomic.c: Likewise.
22687         * config/pa/linux-unwind.h: Likewise.
22688         * config/pa/milli64.S: Likewise.
22689         * config/pa/quadlib.c: Likewise.
22690         * config/pa/stublib.c: Likewise.
22691         * config/picochip/libgccExtras/adddi3.asm: Likewise.
22692         * config/picochip/libgccExtras/ashlsi3.asm: Likewise.
22693         * config/picochip/libgccExtras/ashlsi3.c: Likewise.
22694         * config/picochip/libgccExtras/ashrsi3.asm: Likewise.
22695         * config/picochip/libgccExtras/ashrsi3.c: Likewise.
22696         * config/picochip/libgccExtras/cmpsi2.asm: Likewise.
22697         * config/picochip/libgccExtras/divmod15.asm: Likewise.
22698         * config/picochip/libgccExtras/divmodhi4.asm: Likewise.
22699         * config/picochip/libgccExtras/divmodsi4.asm: Likewise.
22700         * config/picochip/libgccExtras/longjmp.asm: Likewise.
22701         * config/picochip/libgccExtras/lshrsi3.asm: Likewise.
22702         * config/picochip/libgccExtras/lshrsi3.c: Likewise.
22703         * config/picochip/libgccExtras/parityhi2.asm: Likewise.
22704         * config/picochip/libgccExtras/popcounthi2.asm: Likewise.
22705         * config/picochip/libgccExtras/setjmp.asm: Likewise.
22706         * config/picochip/libgccExtras/subdi3.asm: Likewise.
22707         * config/picochip/libgccExtras/ucmpsi2.asm: Likewise.
22708         * config/picochip/libgccExtras/udivmodhi4.asm: Likewise.
22709         * config/picochip/libgccExtras/udivmodsi4.asm: Likewise.
22710         * config/rs6000/750cl.h: Likewise.
22711         * config/rs6000/altivec.h: Likewise.
22712         * config/rs6000/biarch64.h: Likewise.
22713         * config/rs6000/crtresfpr.asm: Likewise.
22714         * config/rs6000/crtresgpr.asm: Likewise.
22715         * config/rs6000/crtresxfpr.asm: Likewise.
22716         * config/rs6000/crtresxgpr.asm: Likewise.
22717         * config/rs6000/crtsavfpr.asm: Likewise.
22718         * config/rs6000/crtsavgpr.asm: Likewise.
22719         * config/rs6000/darwin-asm.h: Likewise.
22720         * config/rs6000/darwin-fallback.c: Likewise.
22721         * config/rs6000/darwin-fpsave.asm: Likewise.
22722         * config/rs6000/darwin-ldouble.c: Likewise.
22723         * config/rs6000/darwin-tramp.asm: Likewise.
22724         * config/rs6000/darwin-unwind.h: Likewise.
22725         * config/rs6000/darwin-vecsave.asm: Likewise.
22726         * config/rs6000/darwin-world.asm: Likewise.
22727         * config/rs6000/e500crtres32gpr.asm: Likewise.
22728         * config/rs6000/e500crtres64gpr.asm: Likewise.
22729         * config/rs6000/e500crtres64gprctr.asm: Likewise.
22730         * config/rs6000/e500crtrest32gpr.asm: Likewise.
22731         * config/rs6000/e500crtrest64gpr.asm: Likewise.
22732         * config/rs6000/e500crtresx32gpr.asm: Likewise.
22733         * config/rs6000/e500crtresx64gpr.asm: Likewise.
22734         * config/rs6000/e500crtsav32gpr.asm: Likewise.
22735         * config/rs6000/e500crtsav64gpr.asm: Likewise.
22736         * config/rs6000/e500crtsav64gprctr.asm: Likewise.
22737         * config/rs6000/e500crtsavg32gpr.asm: Likewise.
22738         * config/rs6000/e500crtsavg64gpr.asm: Likewise.
22739         * config/rs6000/e500crtsavg64gprctr.asm: Likewise.
22740         * config/rs6000/eabi-ci.asm: Likewise.
22741         * config/rs6000/eabi-cn.asm: Likewise.
22742         * config/rs6000/eabi.asm: Likewise.
22743         * config/rs6000/linux-unwind.h: Likewise.
22744         * config/rs6000/linux64.h: Likewise.
22745         * config/rs6000/paired.h: Likewise.
22746         * config/rs6000/paired.md: Likewise.
22747         * config/rs6000/ppc64-fp.c: Likewise.
22748         * config/rs6000/ppu_intrinsics.h: Likewise.
22749         * config/rs6000/rs6000.h: Likewise.
22750         * config/rs6000/si2vmx.h: Likewise.
22751         * config/rs6000/sol-ci.asm: Likewise.
22752         * config/rs6000/sol-cn.asm: Likewise.
22753         * config/rs6000/spe.h: Likewise.
22754         * config/rs6000/spu2vmx.h: Likewise.
22755         * config/rs6000/sysv4.h: Likewise.
22756         * config/rs6000/tramp.asm: Likewise.
22757         * config/rs6000/vec_types.h: Likewise.
22758         * config/s390/linux-unwind.h: Likewise.
22759         * config/s390/tpf-unwind.h: Likewise.
22760         * config/score/crti.asm: Likewise.
22761         * config/score/crtn.asm: Likewise.
22762         * config/sh/crt1.asm: Likewise.
22763         * config/sh/crti.asm: Likewise.
22764         * config/sh/crtn.asm: Likewise.
22765         * config/sh/divtab-sh4-300.c: Likewise.
22766         * config/sh/divtab-sh4.c: Likewise.
22767         * config/sh/divtab.c: Likewise.
22768         * config/sh/lib1funcs-4-300.asm: Likewise.
22769         * config/sh/lib1funcs-Os-4-200.asm: Likewise.
22770         * config/sh/lib1funcs.asm: Likewise.
22771         * config/sh/lib1funcs.h: Likewise.
22772         * config/sh/linux-atomic.asm: Likewise.
22773         * config/sh/linux-unwind.h: Likewise.
22774         * config/sh/shmedia.h: Likewise.
22775         * config/sh/sshmedia.h: Likewise.
22776         * config/sh/ushmedia.h: Likewise.
22777         * config/sparc/crtfastmath.c: Likewise.
22778         * config/sparc/linux-unwind.h: Likewise.
22779         * config/sparc/sol2-c1.asm: Likewise.
22780         * config/sparc/sol2-ci.asm: Likewise.
22781         * config/sparc/sol2-cn.asm: Likewise.
22782         * config/spu/divmodti4.c: Likewise.
22783         * config/spu/divv2df3.c: Likewise.
22784         * config/spu/float_disf.c: Likewise.
22785         * config/spu/float_unsdidf.c: Likewise.
22786         * config/spu/float_unsdisf.c: Likewise.
22787         * config/spu/float_unssidf.c: Likewise.
22788         * config/spu/mfc_multi_tag_release.c: Likewise.
22789         * config/spu/mfc_multi_tag_reserve.c: Likewise.
22790         * config/spu/mfc_tag_release.c: Likewise.
22791         * config/spu/mfc_tag_reserve.c: Likewise.
22792         * config/spu/mfc_tag_table.c: Likewise.
22793         * config/spu/multi3.c: Likewise.
22794         * config/spu/spu_internals.h: Likewise.
22795         * config/spu/spu_intrinsics.h: Likewise.
22796         * config/spu/spu_mfcio.h: Likewise.
22797         * config/spu/vec_types.h: Likewise.
22798         * config/spu/vmx2spu.h: Likewise.
22799         * config/stormy16/stormy16-lib2.c: Likewise.
22800         * config/svr4.h: Likewise.
22801         * config/sync.c: Likewise.
22802         * config/v850/lib1funcs.asm: Likewise.
22803         * config/vxlib-tls.c: Likewise.
22804         * config/vxlib.c: Likewise.
22805         * config/vxworks-dummy.h: Likewise.
22806         * config/xtensa/crti.asm: Likewise.
22807         * config/xtensa/crtn.asm: Likewise.
22808         * config/xtensa/ieee754-df.S: Likewise.
22809         * config/xtensa/ieee754-sf.S: Likewise.
22810         * config/xtensa/lib1funcs.asm: Likewise.
22811         * config/xtensa/lib2funcs.S: Likewise.
22812         * config/xtensa/linux-unwind.h: Likewise.
22813         * config/xtensa/unwind-dw2-xtensa.c: Likewise.
22814         * config/xtensa/unwind-dw2-xtensa.h: Likewise.
22815         * coretypes.h: Likewise.
22816         * crtstuff.c: Likewise.
22817         * defaults.h: Likewise.
22818         * dwarf2.h: Likewise.
22819         * emutls.c: Likewise.
22820         * gbl-ctors.h: Likewise.
22821         * gcov-io.h: Likewise.
22822         * ginclude/float.h: Likewise.
22823         * ginclude/iso646.h: Likewise.
22824         * ginclude/stdarg.h: Likewise.
22825         * ginclude/stdbool.h: Likewise.
22826         * ginclude/stddef.h: Likewise.
22827         * ginclude/stdfix.h: Likewise.
22828         * ginclude/stdint-gcc.h: Likewise.
22829         * ginclude/tgmath.h: Likewise.
22830         * gthr-aix.h: Likewise.
22831         * gthr-dce.h: Likewise.
22832         * gthr-gnat.c: Likewise.
22833         * gthr-gnat.h: Likewise.
22834         * gthr-lynx.h: Likewise.
22835         * gthr-mipssde.h: Likewise.
22836         * gthr-nks.h: Likewise.
22837         * gthr-posix.c: Likewise.
22838         * gthr-posix.h: Likewise.
22839         * gthr-posix95.h: Likewise.
22840         * gthr-rtems.h: Likewise.
22841         * gthr-single.h: Likewise.
22842         * gthr-solaris.h: Likewise.
22843         * gthr-tpf.h: Likewise.
22844         * gthr-vxworks.h: Likewise.
22845         * gthr-win32.h: Likewise.
22846         * gthr.h: Likewise.
22847         * libgcc2.c: Likewise.
22848         * libgcc2.h: Likewise.
22849         * libgcov.c: Likewise.
22850         * tsystem.h: Likewise.
22851         * typeclass.h: Likewise.
22852         * unwind-c.c: Likewise.
22853         * unwind-compat.h: Likewise.
22854         * unwind-dw2-fde-compat.c: Likewise.
22855         * unwind-dw2-fde-darwin.c: Likewise.
22856         * unwind-dw2-fde-glibc.c: Likewise.
22857         * unwind-dw2-fde.c: Likewise.
22858         * unwind-dw2-fde.h: Likewise.
22859         * unwind-dw2.c: Likewise.
22860         * unwind-dw2.h: Likewise.
22861         * unwind-generic.h: Likewise.
22862         * unwind-pe.h: Likewise.
22863         * unwind-sjlj.c: Likewise.
22864         * unwind.inc: Likewise.
22865         * config/arm/neon-gen.ml: Change generated copyright header to
22866         refer to version 3 of the GNU General Public License with
22867         version 3.1 of the GCC Runtime Library Exception and to point
22868         readers at the COPYING3 and COPYING3.RUNTIME files and the
22869         FSF's license web page.
22870         * config/arm/arm_neon.h: Regenerate.
22871
22872 2009-04-09  Jakub Jelinek  <jakub@redhat.com>
22873
22874         * config/cris/cris.md: Change copyright header to refer to version
22875         3 of the GNU General Public License.
22876         * doc/install.texi2html: Change copyright header to refer to version
22877         3 of the GNU General Public License and to point readers at the
22878         COPYING3 file and the FSF's license web page.
22879         * config/vax/linux.h: Likewise.
22880
22881 2009-04-09  Paolo Bonzini  <bonzini@gnu.org>
22882
22883         * config/i386/i386.md (cmpcc): New.
22884         * config/i386/sync.md (sync_compare_and_swap*): Set FLAGS_REG.
22885         (sync_compare_and_swap_cc*): Delete.
22886
22887         * config/s390/s390.c (s390_compare_emitted): Remove.
22888         (s390_emit_compare): Handle MODE_CC s390_compare_op0 like
22889         s390_compare_emitted used to be handled.  Assert that modes match.
22890         (s390_emit_compare_and_swap): Use s390_emit_compare, do not
22891         refer to sync_compare_and_swap_ccsi.
22892         * config/s390/s390.h (s390_compare_emitted): Remove.
22893         * config/s390/s390.md (seq): Look for MODE_CC s390_compare_op0
22894         instead of s390_compare_emitted.
22895         (stack_protect_test, sync_compare_and_swap_cc): Set s390_compare_op0
22896         instead of s390_compare_emitted.
22897         * config/s390/s390.md (cmpcc): New.
22898         (sync_compare_and_swapqi, sync_compare_and_swaphi): Clobber
22899         CC_REGNUM, do not pretend it's set.
22900         (sync_compare_and_swap_cc*): Delete.
22901         * config/s390/predicates.md (cc_reg_operand): New.
22902
22903         * expr.c (sync_compare_and_swap_cc): Delete.
22904         * optabs.h (sync_compare_and_swap_cc): Delete.
22905         * optabs.c (prepare_cmp_insn): Ignore which specific CCmode
22906         is being used with can_compare_p.
22907         (emit_cmp_and_jump_insn_1): Likewise when looking in the optab.
22908         (find_cc_set): New.
22909         (expand_bool_compare_and_swap): Do not use sync_compare_and_swap_cc,
22910         look for a MODE_CC set instead.  Use emit_store_flag.
22911         (expand_compare_and_swap_loop): Likewise, with some additional
22912         complication to avoid a force_reg when useless.  Use
22913         emit_cmp_and_jump_insns.
22914         * genopinit.c (optabs): Delete sync_compare_and_swap_cc.
22915         * doc/md.texi (sync_compare_and_swap_cc): Merge with
22916         sync_compare_and_swap documentation.
22917
22918 2009-04-09  Jan Hubicka  <jh@suse.cz>
22919
22920         * except.c (find_prev_try): Break out from ....
22921         (duplicate_eh_regions): ... here; properly update prev_try pointers
22922         when duplication part of tree.
22923         (dump_eh_tree): Improve dumping.
22924         (verify_eh_region): New.
22925         (verify_eh_tree): Use it.
22926
22927 2009-04-06  Richard Guenther  <rguenther@suse.de>
22928
22929         * c-gimplify.c (c_gimplify_expr): Fix the invalid GENERIC
22930         &ARRAY addresses by adjusting their types and prepending
22931         a conversion.
22932         * tree-cfg.c (verify_gimple_assign_single): Verify that
22933         addresses are correct.
22934
22935 2009-04-09  Richard Guenther  <rguenther@suse.de>
22936
22937         * tree-ssa-ccp.c (maybe_fold_stmt_addition): Move non-constant
22938         indices into an array reference if possible.
22939         * tree-ssa-forwprop.c (tree_ssa_forward_propagate_single_use_vars):
22940         Fold POINTER_PLUS_EXPR statements with invariant address.
22941
22942 2009-04-09  Alan Modra  <amodra@bigpond.net.au>
22943
22944         PR target/39634
22945         * config.gcc (powerpc64-*-linux*): Always build biarch.
22946
22947 2009-04-09  Joseph Myers  <joseph@codesourcery.com>
22948
22949         PR c/39613
22950         * c-typeck.c (do_case): If case label is not an INTEGER_CST, fold
22951         it and pedwarn if this results in an INTEGER_CST.
22952
22953 2009-04-08  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
22954
22955         * doc/install.texi: Update minimum GMP version.  Remove obsolete
22956         text in MPFR section.
22957
22958 2009-04-08  Jakub Jelinek  <jakub@redhat.com>
22959
22960         * dwarf2out.c (class_scope_p): New static inline.
22961         (class_or_namespace_scope_p): Use it.
22962         (gen_variable_die): Use DW_TAG_member tag for static data member
22963         declarations instead of DW_TAG_variable.
22964
22965         PR middle-end/39573
22966         * omp-low.c (expand_omp_taskreg): Finalize taskreg static local_decls
22967         variables.
22968
22969 2009-04-08  Richard Guenther  <rguenther@suse.de>
22970
22971         * tree-ssa-sccvn.c (valueize_refs): Do not continue to
22972         valueize random data.
22973
22974 2009-04-08  David Edelsohn  <edelsohn@gnu.org>
22975
22976         * config.gcc (aix tm_file):  Add aix-stdint.h.
22977         (aix tm clause use_gcc_stdint):  Set to wrap.
22978         * config/rs6000/aix-stdint.h:  New file.
22979
22980 2009-04-08  Richard Guenther  <rguenther@suse.de>
22981
22982         PR middle-end/36291
22983         * tree-dfa.c (add_referenced_var): Do not recurse into
22984         global initializers.
22985         * tree-ssa-ccp.c (get_symbol_constant_value): Add newly
22986         exposed variables.
22987         (fold_const_aggregate_ref): Likewise.
22988
22989 2009-04-08  Paolo Bonzini  <bonzini@gnu.org>
22990
22991         * recog.c (ordered_comparison_operator): New.
22992         * gensupport.c (std_preds): Add it.
22993         * doc/md.texi (Machine-Independent Predicates): Document it.
22994
22995 2009-04-08  Jan Hubicka  <jh@suse.cz>
22996
22997         * tree-eh.c (cleanup_eh): When not optimizing, do not try EH merging.
22998         * function.h (rtl_eh): Remove exception_handler_label_map.
22999         * except.c (ehl_hash, ehl_eq, add_ehl_entry,
23000         remove_exception_handler_label, for_each_eh_label_1): Remove.
23001         (rtl_remove_unreachable_regions): Remove.
23002         (convert_from_eh_region_ranges): Do not remove unreachable regions.
23003         (find_exception_handler_labels): Don't build the hashtable.
23004         (maybe_remove_eh_handler): Remove.
23005         (for_each_eh_label): Rewrite to walk the tree.
23006         (rest_of_handle_eh): Do not cleanup cfg prior EH construction.
23007         * except.h (maybe_remove_eh_handler): Remove.
23008         * passes.c (init_optimization_passes): Schedule second EH cleanup
23009         before out-of-ssa.
23010         * cfgrtl.c (rtl_delete_block, rtl_merge_blocks,
23011         cfg_layout_merge_blocks): Do not call maybe_remove_eh_handler.
23012
23013 2009-04-08  Paolo Bonzini  <bonzini@gnu.org>
23014
23015         * genoutput.c (validate_optab_operands): New.
23016         (gen_insn, gen_expand): Call it.
23017
23018         * genflags.c (gen_insn): Detect misused iterators.
23019         (main): Pass line_no to gen_insn, exit with status 1 on error.
23020
23021         * genextract.c (line_no): Make global.
23022         (VEC_safe_set_locstr): Change assertion to error message.
23023         (main): Exit with status 1 on error.
23024
23025 2009-04-08  Joseph Myers  <joseph@codesourcery.com>
23026
23027         PR c/39614
23028         PR c/39673
23029         * c-common.h (C_MAYBE_CONST_EXPR_PRE, C_MAYBE_CONST_EXPR_EXPR,
23030         C_MAYBE_CONST_EXPR_INT_OPERANDS, C_MAYBE_CONST_EXPR_NON_CONST,
23031         EXPR_INT_CONST_OPERANDS): Remove duplicate definitions.
23032         * c-convert.c (convert): Do not call fold on results of conversion
23033         functions when the result is a C_MAYBE_CONST_EXPR.
23034         * c-parser.c (c_parser_postfix_expression): Do not fold condition
23035         of __builtin_choose_expr.
23036         * c-typeck.c (remove_c_maybe_const_expr): New.
23037         (build_unary_op, build_conditional_expr, build_compound_expr,
23038         build_binary_op, c_objc_common_truthvalue_conversion): Call
23039         remove_c_maybe_const_expr on any input C_MAYBE_CONST_EXPR with
23040         integer operands.
23041
23042 2009-04-08  Bingfeng Mei  <bmei@broadcom.com>
23043
23044         * fold-const.c (const_binop): Combine two VECTOR_CST under operation
23045         CODE to produce a new one. Add a prototype to use fold_convert_const
23046
23047 2009-04-08  Danny Smith  <dannysmith@users.sourceforge.net>
23048
23049         PR bootstrap/39660
23050         * config/i386/host-mingw32.c (mingw32_gt_pch_use_address): Don't
23051         mix declarations and code.
23052
23053 2009-04-08  Ben Elliston  <bje@au.ibm.com>
23054
23055         * gcc.c: Replace `CC' with `GCC' throughout.
23056
23057 2009-04-07  H.J. Lu  <hongjiu.lu@intel.com>
23058
23059         * doc/invoke.texi: Document Atom support.
23060
23061 2009-04-07  Jason Merrill  <jason@redhat.com>
23062
23063         PR c++/25185
23064         * c-common.h, c-common.c: Add flag_pretty_templates.
23065         * c-opts.c (c_common_handle_option): Set it.
23066         * c.opt: Add -fno-pretty-templates.
23067         * doc/invoke.texi (C++ Dialect Options): Likewise.
23068
23069 2009-04-07  Uros Bizjak  <ubizjak@gmail.com>
23070
23071         * config/ia64/ia64.c (ia64_builtins): Add IA64_BUILTIN_HUGE_VALQ.
23072         (ia64_init_builtins): Handle IA64_BUILTIN_HUGE_VALQ.
23073         (ia64_expand_builtin): Likewise.
23074
23075 2009-04-07  Martin Jambor  <mjambor@suse.cz>
23076
23077         * tree-ssa-alias.c (refs_may_alias_p_1): Check for
23078         is_gimple_min_invariant rather than CONSTANT_CLASS_P so that invariant
23079         ADDR_EXPRS are include too.
23080
23081 2009-04-07  Richard Guenther  <rguenther@suse.de>
23082
23083         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Non-aliased
23084         decls are only used if passes as parameters or if they are
23085         local statics and the call is not to a builtin.
23086         (call_may_clobber_ref_p_1): Likewise.
23087
23088 2009-04-07  Paolo Bonzini  <bonzini@gnu.org>
23089
23090         * expr.c (do_store_flag): Remove last argument.  Simplify code
23091         to avoid duplication of tests already done by can_compare_p.
23092         (expand_expr_real_1): Adjust caller.
23093
23094 2009-04-07  Paolo Bonzini  <bonzini@gnu.org>
23095
23096         * optabs.c (can_compare_p): Test the predicate of a
23097         cbranch and cstore pattern.
23098
23099 2009-04-07  Paolo Bonzini  <bonzini@gnu.org>
23100
23101         * expr.c (convert_move): Use emit_store_flag instead of
23102         "emulating" it.
23103
23104 2009-04-07  Paolo Bonzini  <bonzini@gnu.org>
23105
23106         * config/i386/i386.c (ix86_compare_emitted): Remove.
23107         (ix86_expand_compare, ix86_expand_branch): Handle MODE_CC
23108         ix86_compare_op0 like ix86_compare_emitted used to be handled.
23109         * config/i386/i386.h (ix86_compare_emitted): Remove.
23110         * config/i386/i386.md (stack_protect_test): Set ix86_compare_op0
23111         instead of ix86_compare_emitted.
23112         * config/i386/sync.md (sync_compare_and_swap_cc): Likewise.
23113
23114 2009-04-07  Andrew Stubbs  <ams@codesourcery.com>
23115
23116         * config.gcc (sh-*-*): Add sysroot-suffix.h to tm_file.
23117         Add t-sysroot-suffix to tmake_file.
23118         * config/print-sysroot-suffix.sh: New file.
23119         * config/t-sysroot-suffix: New file.
23120
23121 2009-04-07  Ben Elliston  <bje@au.ibm.com>
23122
23123         * libgcc2.c (INFINITY): Use __builtin_huge_val, not __builtin_inf,
23124         as the latter produces a warning when the target does not support
23125         infinity.
23126
23127 2009-04-07  Ben Elliston  <bje@au.ibm.com>
23128
23129         * dfp.c: Replace type punning assignments with memcpy throughout.
23130         * Makefile.in (dfp.o-warn): Remove.
23131
23132 2009-04-07  Alan Modra  <amodra@bigpond.net.au>
23133
23134         PR target/39634
23135         * config.gcc: Merge powerpc-*-linux* and powerpc64-*-linux*.
23136         Include soft-fp/t-softfp after rs6000/t-linux64.
23137
23138 2009-04-06  Eric Botcazou  <ebotcazou@adacore.com>
23139
23140         * stor-layout.c (set_sizetype): Use the full precision of their
23141         machine mode for bitsize types.
23142
23143 2009-04-06  H.J. Lu  <hongjiu.lu@intel.com>
23144
23145         * config/i386/i386.md: Revert 2 accidental checkins.
23146
23147 2009-04-06  Joey Ye  <joey.ye@intel.com>
23148             Xuepeng Guo  <xuepeng.guo@intel.com>
23149             H.J. Lu  <hongjiu.lu@intel.com>
23150
23151         Atom pipeline model, tuning and insn selection.
23152         * config.gcc (atom): Add atom config options and target.
23153
23154         * config/i386/atom.md: New.
23155
23156         * config/i386/i386.c (atom_cost): New cost.
23157         (m_ATOM): New macro flag.
23158         (initial_ix86_tune_features): Set m_ATOM.
23159         (x86_accumulate_outgoing_args): Likewise.
23160         (x86_arch_always_fancy_math_387): Likewise.
23161         (processor_target): Add Atom cost.
23162         (cpu_names): Add Atom cpu name.
23163         (override_options): Set Atom ISA.
23164         (ix86_issue_rate): New case PROCESSOR_ATOM.
23165         (ix86_adjust_cost): Likewise.
23166
23167         * config/i386/i386.h (TARGET_ATOM): New target macro.
23168         (ix86_tune_indices): Add X86_TUNE_OPT_AGU.
23169         (TARGET_OPT_AGU): New target option.
23170         (target_cpu_default): Add TARGET_CPU_DEFAULT_atom.
23171         (processor_type): Add PROCESSOR_ATOM.
23172
23173         * config/i386/i386.md (cpu): Add new value "atom".
23174         (use_carry, movu): New attr.
23175         (atom.md): Include atom.md.
23176         (adddi3_carry_rex64): Set attr "use_carry".
23177         (addqi3_carry): Likewise.
23178         (addhi3_carry): Likewise.
23179         (addsi3_carry): Likewise.
23180         (*addsi3_carry_zext): Likewise.
23181         (subdi3_carry_rex64): Likewise.
23182         (subqi3_carry): Likewise.
23183         (subhi3_carry): Likewise.
23184         (subsi3_carry): Likewise.
23185         (x86_movdicc_0_m1_rex64): Likewise.
23186         (*x86_movdicc_0_m1_se): Likewise.
23187         (x86_movsicc_0_m1): Likewise.
23188         (*x86_movsicc_0_m1_se): Likewise.
23189         (*adddi_1_rex64): Emit add insn as much as possible.
23190         (*addsi_1): Likewise.
23191         (return_internal): Set atom_unit.
23192         (return_internal_long): Likewise.
23193         (return_pop_internal): Likewise.
23194         (*rcpsf2_sse): Set atom_sse_attr attr.
23195         (*qrt<mode>2_sse): Likewise.
23196         (*prefetch_sse): Likewise.
23197
23198         * config/i386/i386-c.c (ix86_target_macros_internal): New case
23199         PROCESSOR_ATOM.
23200         (ix86_target_macros_internal): Likewise.
23201
23202         * config/i386/sse.md (cpu): Set attr "atom_sse_attr".
23203         (*prefetch_sse_rex): Likewise.
23204         (sse_rcpv4sf2): Likewise.
23205         (sse_vmrcpv4sf2): Likewise.
23206         (sse_sqrtv4sf2): Likewise.
23207         (<sse>_vmsqrt<mode>2): Likewise.
23208         (sse_ldmxcsr): Likewise.
23209         (sse_stmxcsr): Likewise.
23210         (*sse_sfence): Likewise.
23211         (sse2_clflush): Likewise.
23212         (*sse2_mfence): Likewise.
23213         (*sse2_lfence): Likewise.
23214         (avx_movup<avxmodesuffixf2c><avxmodesuffix>): Set attr "movu".
23215         (<sse>_movup<ssemodesuffixf2c>): Likewise.
23216         (avx_movdqu<avxmodesuffix>): Likewise.
23217         (avx_lddqu<avxmodesuffix>): Likewise.
23218         (sse2_movntv2di): Change attr "type" to "ssemov".
23219         (sse2_movntsi): Likewise.
23220         (rsqrtv8sf2): Change attr "type" to "sseadd".
23221         (sse3_addsubv2df3): Set attr "atom_unit".
23222         (sse3_h<plusminus_insn>v4sf3): Likewise.
23223         (*sse2_pmaddwd): Likewise.
23224         (*vec_extractv2di_1_rex64): Likewise.
23225         (*vec_extractv2di_1_avx): Likewise.
23226         (sse2_psadbw): Likewise.
23227         (ssse3_phaddwv8hi3): Likewise.
23228         (ssse3_phaddwv4hi3): Likewise.
23229         (ssse3_phadddv4si3): Likewise.
23230         (ssse3_phadddv2si3): Likewise.
23231         (ssse3_phaddswv8hi3): Likewise.
23232         (ssse3_phaddswv4hi3): Likewise.
23233         (ssse3_phsubwv8hi3): Likewise.
23234         (ssse3_phsubwv4hi3): Likewise.
23235         (ssse3_phsubdv4si3): Likewise.
23236         (ssse3_phsubdv2si3): Likewise.
23237         (ssse3_phsubswv8hi3): Likewise.
23238         (ssse3_phsubswv4hi3): Likewise.
23239         (ssse3_pmaddubsw128): Likewise.
23240         (sse3_pmaddubsw: Likewise.
23241         (ssse3_palignrti): Likewise.
23242         (ssse3_palignrdi): Likewise.
23243
23244 2009-04-06  Gerald Pfeifer  <gerald@pfeifer.com>
23245
23246         * doc/install.texi (Specific): Fix two cross-references to MinGW.
23247
23248 2009-04-06  Richard Guenther  <rguenther@suse.de>
23249
23250         PR tree-optimization/28868
23251         * tree-ssa-pre.c (inserted_phi_names): New bitmap to keep track
23252         of which PHI results we inserted.
23253         (insert_into_preds_of_block): Record inserted PHIs.
23254         (eliminate): Eliminate redundant PHI nodes.
23255         (init_pre): Init inserted_phi_names.
23256
23257 2009-04-06  Richard Guenther  <rguenther@suse.de>
23258
23259         PR tree-optimization/39643
23260         * tree-ssa-ccp.c (ccp_fold): Fold REALPART_EXPRs and
23261         IMAGPART_EXPRs of complex constants.
23262         (execute_fold_all_builtins): If we folded a call queue
23263         TODO_update_address_taken.
23264
23265 2009-04-06  Jan Hubicka  <jh@suse.cz>
23266
23267         PR middle-end/39659
23268         * except.c (remove_unreachable_regions): Propagate may_contain_throw
23269         flag.
23270
23271 2009-04-06  Andrew Stubbs  <ams@codesourcery.com>
23272
23273         * config/sh/lib1funcs.asm (ic_invalidate): Move ICBI out of the
23274         delay slot.
23275         (ic_invalidate_array): Likewise.
23276
23277 2009-04-06  Hariharan Sandanagobalane  <hariharan@picochip.com>
23278
23279         * calls.c (emit_library_call_value_1): Fix a problem with parameter
23280         alignment for library calls.
23281
23282 2009-04-06  Danny Smith  <dannysmith@users.sourceforge.net>
23283
23284         * config.gcc (mingw32 tm_file):  Add mingw-stdint.h.
23285         (mingw32 tm clause use_gcc_stdint):  Set to wrap.
23286         * config/i386/mingw-stdint.h:  New file.
23287
23288 2009-04-05  Richard Guenther  <rguenther@suse.de>
23289
23290         PR tree-optimization/39648
23291         * tree-ssa-sccvn.c (vn_reference_fold_indirect): Work around
23292         our &A vs. &A[0] IL deficiencies.
23293
23294 2009-04-04  Jan Hubicka  <jh@suse.cz>
23295
23296         * except.c (sjlj_find_directly_reachable_regions): Be ready for
23297         removed toplevel regions.
23298         (sjlj_mark_call_sites): Likewise.
23299
23300 2009-04-04  Dave Korn  <dave.korn.cygwin@gmail.com>
23301
23302         * config.gcc (cygwin tm_file):  Add cygwin-stdint.h.
23303         (cygwin tm clause use_gcc_stdint):  Set to wrap.
23304         * config/i386/cygwin-stdint.h:  New file.
23305
23306 2009-04-04  Richard Guenther  <rguenther@suse.de>
23307
23308         * Makefile.in (tree-ssa-copy.o): Add $(CFGLOOP_H) dependency.
23309         * tree-ssa-copy.c (init_copy_prop): Do not propagate through
23310         single-argument PHIs if we are in loop-closed SSA form.
23311         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Pass extra guards
23312         for the pre-condition.
23313         (slpeel_tree_peel_loop_to_edge): Likewise.
23314         (vect_build_loop_niters): Take an optional sequence to append stmts.
23315         (vect_generate_tmps_on_preheader): Likewise.
23316         (vect_do_peeling_for_loop_bound): Take extra guards for the
23317         pre-condition.
23318         (vect_do_peeling_for_alignment): Adjust.  Unconditionally apply
23319         the cost model check.
23320         (vect_loop_versioning): Take stmt and stmt list to put pre-condition
23321         guards if we are going to peel.  Do not apply versioning in that case.
23322         * tree-vectorizer.h (vect_loop_versioning): Adjust declaration.
23323         (vect_do_peeling_for_loop_bound): Likewise.
23324         * tree-vect-loop.c (vect_transform_loop): If we are peeling for
23325         loop bound only record extra pre-conditions, do not apply loop
23326         versioning.
23327
23328 2009-04-04  Richard Guenther  <rguenther@suse.de>
23329
23330         * tree-ssa-operands.c (pop_stmt_changes): Remove automatic
23331         renaming code.
23332
23333 2009-04-04  Jan Hubicka  <jh@suse.cz>
23334
23335         * tree-ssa-uncprop.c (associate_equivalences_with_edges): Use
23336         last_basic_block for size of bb->index indexed array.
23337         * bt-load.c (compute_defs_uses_and_gen, compute_kill,
23338         compute_out, link_btr_uses, build_btr_def_use_webs,
23339         build_btr_def_use_webs, migrate_btr_defs): Likewise.
23340
23341 2009-04-04  Jan Hubicka  <jh@suse.cz>
23342
23343         * except.c (remove_eh_handler_and_replace): Break out from ...
23344         (remove_eh_handler): ... here.
23345         (bring_to_root): New function.
23346         (remove_unreachable_regions): Collect MUST_NOT_THROW, unify runtime
23347         handled ones, bring others to root of tree.
23348
23349 2009-04-04  Jan Hubicka  <jh@suse.cz>
23350
23351         * tree-eh.c (tree_empty_eh_handler_p): Pattern match more curefully.
23352         (all_phis_safe_to_merge): New function.
23353         (update_info): New structure.
23354         (make_eh_edge_and_update_phi, update_eh_edges): New functions.
23355         (cleanup_empty_eh): Update SSA if possible.
23356
23357 2009-04-04  Richard Guenther  <rguenther@suse.de>
23358
23359         * tree-ssa.c (verify_ssa): With -O0 we do not need VOPs.
23360         * tree-ssa-operands.c (append_vdef): Do not append VOPs at -O0.
23361         (append_vuse): Likewise.
23362
23363 2009-04-04  Jakub Jelinek  <jakub@redhat.com>
23364
23365         * unwind-dw2.h (_Unwind_FrameState): Add REG_UNDEFINED enum value.
23366         * unwind-dw2.c (execute_cfa_program): Set how to REG_UNDEFINED
23367         instead of REG_UNSAVED for DW_CFA_undefined.
23368         (uw_update_context_1): Handle REG_UNDEFINED the same as REG_UNSAVED.
23369         (uw_update_context): If RA column is REG_UNDEFINED, mark it as
23370         outermost frame.
23371
23372 2009-04-04  Richard Earnshaw  <rearnsha@arm.com>
23373
23374         PR target/39501
23375         * arm.md (movsfcc): Disable if not TARGET_HARD_FLOAT.
23376
23377 2009-04-04  Richard Guenther  <rguenther@suse.de>
23378
23379         PR tree-optimization/8781
23380         PR tree-optimization/37892
23381         * tree-ssa-sccvn.h (vn_reference_fold_indirect): Declare.
23382         * tree-ssa-sccvn.c (vn_reference_fold_indirect): New function.
23383         (valueize_refs): Call it for *& valueizations.
23384         (shared_reference_ops_from_ref): Rename to ...
23385         (valueize_shared_reference_ops_from_ref): ... this and valueize.
23386         (shared_reference_ops_from_call): Rename to ...
23387         (valueize_shared_reference_ops_from_call): ... this and valueize.
23388         (vn_reference_lookup): Update.
23389         (visit_reference_op_call): Likewise.
23390         * tree-ssa-pre.c (phi_translate_1): Fold *&.
23391         (eliminate): Value-replace the call address in call statements.
23392
23393 2009-04-04  Richard Guenther  <rguenther@suse.de>
23394
23395         PR tree-optimization/39636
23396         * tree-ssa-forwprop.c
23397         (forward_propagate_addr_into_variable_array_index): Check for
23398         GIMPLE_ASSIGN before accessing the rhs code.
23399
23400 2009-04-03  Jason Merrill  <jason@redhat.com>
23401
23402         * stor-layout.c (set_sizetype): Set TYPE_CANONICAL.
23403
23404 2009-04-03  Steve Ellcey  <sje@cup.hp.com>
23405
23406         * config/ia64/ia64.md (extendsfdf2, extendsfxf2, extenddfxf2,
23407         truncdfsf2, truncxfsf2, truncxfdf2, floatdixf2, fix_truncsfdi2,
23408         fix_truncdfdi2, fix_truncxfdi2, fix_truncxfdi2_alts, floatunsdisf2,
23409         floatunsdidf2, floatunsdixf2, fixuns_truncsfdi2, fixuns_truncdfdi2,
23410         fixuns_truncxfdi2, fixuns_truncxfdi2_alts, divsi3_internal,
23411         smuldi3_highpart, umuldi3_highpart, ctzdi2, *getf_exp_xf,
23412         divdi3_internal_lat, divdi3_internal_thr, mulditi3, *mulditi3_internal,
23413         umulditi3, *umulditi3_internal, addsf3, mulsf3, abssf2, negsf2,
23414         *nabssf2, sminsf3, smaxsf3, *maddsf4, *msubsf4, *nmulsf3, *nmaddsf4,
23415         *nmaddsf4_alts, divsf3, *sqrt_approx, sqrtsf2, sqrtsf2_internal_thr,
23416         adddf3, *adddf3_trunc, muldf3, *muldf3_trunc, absdf2, negdf2, *nabsdf2,
23417         smindf3, smaxdf3, *madddf4, *madddf4_trunc, *msubdf4, *msubdf4_trunc,
23418         *nmuldf3, *nmuldf3_trunc, *nmadddf4, *nmadddf4_alts, *nmadddf4_truncsf,
23419         *nmadddf4_truncsf_alts, divdf3, sqrtdf2, sqrtdf2_internal_thr, divxf3,
23420         sqrtxf2, sqrtxf2_internal_thr, *recip_approx):
23421         Use fr_reg_or_fp01_operand instead of fr_register_operand
23422
23423         * config/ia64/div.md (extend<mode>rf2, truncrf<mode>2,
23424         recip_approx_rf, divsf3_internal_thr, divsf3_internal_lat,
23425         divdf3_internal_thr, divdf3_internal_lat divxf3_internal): Ditto.
23426
23427 2009-04-03  Vladimir Makarov  <vmakarov@redhat.com>
23428
23429         PR rtl-optimization/39607
23430         PR rtl-optimization/39631
23431
23432         Revert:
23433
23434         2009-03-30  Vladimir Makarov  <vmakarov@redhat.com>
23435         * reload.c (push_reload, find_dummy_reload): Use df_get_live_out
23436         instead of DF_LR_OUT.
23437         * ira-lives.c (process_bb_node_lives): Ditto.
23438         * ira-color.c (ira_loop_edge_freq): Use df_get_live_{out,in}
23439         instead of DF_LR_{OUT,IN}.
23440         * ira-emit.c (generate_edge_moves, add_ranges_and_copies): Ditto.
23441         * ira-build.c (create_bb_allocnos, create_loop_allocnos): Ditto.
23442
23443 2009-04-03  Steven Bosscher  <steven@gcc.gnu.org>
23444
23445         * omp-low.c (pass_expand_omp): Don't claim to provide PROP_gimple_lomp.
23446         (execute_lower_omp): Always run but take the short way out if -fopenmp
23447         is not given.
23448         (gate_lower_omp): Remove, forcing the pass manager to always run the
23449         pass and always set PROP_gimple_lomp.
23450         (pass_lower_omp): Remove gate function.
23451         * matrix-reorg.c (pass_ipa_matrix_reorg): Don't claim to provide
23452         PROP_trees.  Instead, require it.
23453         * ipa-cp.c (pass_ipa_cp): Likewise.
23454         * ipa-inline.c (pass_early_inline): Don't claim to provide PROP_cfg.
23455         (pass_ipa_early_inline, pass_inline_parameters, pass_ipa_inline): Idem.
23456         * tree-profile.c (pass_tree_profile): Don't claim to provide PROP_cfg
23457         and PROP_gimple_leh.
23458
23459 2009-04-03  Richard Guenther  <rguenther@suse.de>
23460
23461         PR middle-end/13146
23462         PR tree-optimization/23940
23463         PR tree-optimization/33237
23464         PR middle-end/33974
23465         PR middle-end/34093
23466         PR tree-optimization/36201
23467         PR tree-optimization/36230
23468         PR tree-optimization/38049
23469         PR tree-optimization/38207
23470         PR tree-optimization/38230
23471         PR tree-optimization/38301
23472         PR tree-optimization/38585
23473         PR middle-end/38895
23474         PR tree-optimization/38985
23475         PR tree-optimization/39299
23476         * tree-ssa-structalias.h: Remove.
23477         * tree-ssa-operands.h (NULL_USE_OPERAND_P): Make of type use_operand_p.
23478         (NULL_DEF_OPERAND_P): Make of type def_operand_p.
23479         (struct vuse_element_d): Remove.
23480         (struct vuse_vec_d): Likewise.
23481         (VUSE_VECT_NUM_ELEM, VUSE_VECT_ELEMENT_NC, VUSE_ELEMENT_PTR_NC,
23482         VUSE_ELEMENT_VAR_NC, VUSE_VECT_ELEMENT, VUSE_ELEMENT_PTR,
23483         SET_VUSE_VECT_ELEMENT, SET_VUSE_ELEMENT_VAR, SET_VUSE_ELEMENT_PTR,
23484         VUSE_ELEMENT_VAR): Likewise.
23485         (struct voptype_d): Likewise.
23486         (NUM_VOP_FREE_BUCKETS): Likewise.
23487         (struct ssa_operands): Remove vop_free_buckets and mpt_table fields.
23488         (struct stmt_operands_d): Remove.
23489         (VUSE_OP_PTR, VUSE_OP, SET_VUSE_OP, VUSE_NUM, VUSE_VECT,
23490         VDEF_RESULT_PTR, VDEF_RESULT, VDEF_OP_PTR, VDEF_OP, SET_VDEF_OP,
23491         VDEF_NUM, VDEF_VECT): Likewise.
23492         (copy_virtual_operands): Remove.
23493         (operand_build_cmp): Likewise.
23494         (create_ssa_artificial_load_stmt): Likewise.
23495         (enum ssa_op_iter_type): Remove ssa_op_iter_vdef.
23496         (struct ssa_operand_iterator_d): Remove vuses, vdefs, mayusesm
23497         vuse_index and mayuse_index members.  Pack and move done and iter_type
23498         members to the front.
23499         (SSA_OP_VMAYUSE): Remove.
23500         (SSA_OP_VIRTUAL_USES): Adjust.
23501         (FOR_EACH_SSA_VDEF_OPERAND): Remove.
23502         (unlink_stmt_vdef): Declare.
23503         (add_to_addressable_set): Remove.
23504         * tree-vrp.c (stmt_interesting_for_vrp): Adjust.
23505         (vrp_visit_stmt): Likewise.
23506         * doc/tree-ssa.texi (Alias analysis): Update.
23507         * doc/invoke.texi (max-aliased-vops): Remove docs.
23508         (avg-aliased-vops): Likewise.
23509         * tree-into-ssa.c (syms_to_rename): Remove.
23510         (need_to_update_vops_p): Likewise.
23511         (need_to_initialize_update_ssa_p): Rename to ...
23512         (update_ssa_initialized_fn): ... this.  Track function we are
23513         initialized for.
23514         (symbol_marked_for_renaming): Simplify.
23515         (add_new_name_mapping): Do not set need_to_update_vops_p.
23516         (dump_currdefs): Use SYMS_TO_RENAME.
23517         (rewrite_update_stmt): Always walk all uses/defs.
23518         (dump_update_ssa): Adjust.
23519         (init_update_ssa): Take function argument.  Track what we are
23520         initialized for.
23521         (delete_update_ssa): Reset SYMS_TO_RENAME and update_ssa_initialized_fn.
23522         (create_new_def_for): Initialize for cfun, assert we are initialized
23523         for cfun.
23524         (mark_sym_for_renaming): Simplify.
23525         (mark_set_for_renaming): Do not initialize update-ssa.
23526         (need_ssa_update_p): Simplify.  Take function argument.
23527         (name_mappings_registered_p): Assert we ask for the correct function.
23528         (name_registered_for_update_p): Likewise.
23529         (ssa_names_to_replace): Likewise.
23530         (release_ssa_name_after_update_ssa): Likewise.
23531         (update_ssa): Likewise.  Use SYMS_TO_RENAME.
23532         (dump_decl_set): Do not print a newline.
23533         (debug_decl_set): Do it here.
23534         (dump_update_ssa): And here.
23535         * tree-ssa-loop-im.c (move_computations): Adjust.
23536         (movement_possibility): Likewise.
23537         (determine_max_movement): Likewise.
23538         (gather_mem_refs_stmt): Likewise.
23539         * tree-dump.c (dequeue_and_dump): Do not handle SYMBOL_MEMORY_TAG
23540         or NAME_MEMORY_TAG.
23541         * tree-complex.c (update_all_vops): Remove.
23542         (expand_complex_move): Adjust.
23543         * tree-ssa-loop-niter.c (chain_of_csts_start): Use NULL_TREE.
23544         Simplify test for memory referencing statement.  Exclude
23545         non-invariant ADDR_EXPRs.
23546         * tree-pretty-print.c (dump_generic_node): Do not handle memory tags.
23547         * tree-loop-distribution.c (generate_memset_zero): Adjust.
23548         (rdg_flag_uses): Likewise.
23549         * tree-tailcall.c (suitable_for_tail_opt_p): Remove memory-tag
23550         related code.
23551         (tree_optimize_tail_calls_1): Also split the
23552         edge from the entry block if we have degenerate PHI nodes in
23553         the first basic block.
23554         * tree.c (init_ttree): Remove memory-tag related code.
23555         (tree_code_size): Likewise.
23556         (tree_node_structure): Likewise.
23557         (build7_stat): Re-write to be build6_stat.
23558         * tree.h (MTAG_P, TREE_MEMORY_TAG_CHECK, TMR_TAG): Remove.
23559         (SSA_VAR_P): Adjust.
23560         (struct tree_memory_tag): Remove.
23561         (struct tree_memory_partition_tag): Likewise.
23562         (union tree_node): Adjust.
23563         (build7): Re-write to be build6.
23564         * tree-pass.h (pass_reset_cc_flags): Remove.
23565         (TODO_update_address_taken): New flag.
23566         (pass_simple_dse): Remove.
23567         * ipa-cp.c (ipcp_update_callgraph): Update SSA form.
23568         * params.h (MAX_ALIASED_VOPS): Remove.
23569         (AVG_ALIASED_VOPS): Likewise.
23570         * omp-low.c (expand_omp_taskreg): Update SSA form.
23571         * tree-ssa-dse.c (dse_optimize_stmt): Properly query if the rhs
23572         aliases the lhs in a copy stmt.
23573         * tree-ssa-dse.c (struct address_walk_data): Remove.
23574         (memory_ssa_name_same): Likewise.
23575         (memory_address_same): Likewise.
23576         (get_kill_of_stmt_lhs): Likewise.
23577         (dse_possible_dead_store_p): Simplify, use the oracle.  Handle
23578         unused stores.  Look through PHI nodes into post-dominated regions.
23579         (dse_optimize_stmt): Simplify.  Properly remove stores.
23580         (tree_ssa_dse): Compute dominators.
23581         (execute_simple_dse): Remove.
23582         (pass_simple_dse): Likewise.
23583         * ipa-reference.c (scan_stmt_for_static_refs): Open-code
23584         gimple_loaded_syms and gimple_stored_syms computation.
23585         * toplev.c (dump_memory_report): Dump alias and pta stats.
23586         * tree-ssa-sccvn.c (vn_reference_compute_hash): Simplify.
23587         (vn_reference_eq): Likewise.
23588         (vuses_to_vec, copy_vuses_from_stmt, vdefs_to_vec,
23589         copy_vdefs_from_stmt, shared_lookup_vops, shared_vuses_from_stmt,
23590         valueize_vuses): Remove.
23591         (get_def_ref_stmt_vuses): Simplify.  Rename to ...
23592         (get_def_ref_stmt_vuse): ... this.
23593         (vn_reference_lookup_2): New function.
23594         (vn_reference_lookup_pieces): Use walk_non_aliased_vuses for
23595         walking equivalent vuses.  Simplify.
23596         (vn_reference_lookup): Likewise.
23597         (vn_reference_insert): Likewise.
23598         (vn_reference_insert_pieces): Likewise.
23599         (visit_reference_op_call): Simplify.
23600         (visit_reference_op_load): Likewise.
23601         (visit_reference_op_store): Likewise.
23602         (init_scc_vn): Remove shared_lookup_vuses initialization.
23603         (free_scc_vn): Remove shared_lookup_vuses freeing.
23604         (sort_vuses, sort_vuses_heap): Remove.
23605         (get_ref_from_reference_ops): Export.
23606         * tree-ssa-sccvn.h (struct vn_reference_s): Replace vuses
23607         vector with single vuse pointer.
23608         (vn_reference_lookup_pieces, vn_reference_lookup,
23609         vn_reference_insert, vn_reference_insert_pieces): Adjust prototypes.
23610         (shared_vuses_from_stmt): Remove.
23611         (get_ref_from_reference_ops): Declare.
23612         * tree-ssa-loop-manip.c (slpeel_can_duplicate_loop_p): Adjust.
23613         * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Remove
23614         memory-tag related code.
23615         * tree-ssa-ccp.c (get_symbol_constant_value): Remove memory-tag code.
23616         (likely_value): Add comment, skip static-chain of call statements.
23617         (surely_varying_stmt_p): Adjust.
23618         (gimplify_and_update_call_from_tree): Likewise.
23619         (execute_fold_all_builtins): Do not rebuild alias info.
23620         (gimplify_and_update_call_from_tree): Properly update VOPs.
23621         * tree-ssa-loop-ivopts.c (get_ref_tag): Remove.
23622         (copy_ref_info): Remove memory-tag related code.
23623         * tree-call-cdce.c (tree_call_cdce): Rename the VOP.
23624         * ipa-pure-const.c (check_decl): Remove memory-tag related code.
23625         (check_stmt): Open-code gimple_loaded_syms and gimple_stored_syms
23626         computation.
23627         * tree-ssa-dom.c (gimple_p): Remove typedef.
23628         (eliminate_redundant_computations): Adjust.
23629         (record_equivalences_from_stmt): Likewise.
23630         (avail_expr_hash): Likewise.
23631         (avail_expr_eq): Likewise.
23632         * tree-ssa-propagate.c (update_call_from_tree): Properly update VOPs.
23633         (stmt_makes_single_load): Likewise.
23634         (stmt_makes_single_store): Likewise.
23635         * tree-ssa-alias.c: Rewrite completely.
23636         (debug_memory_partitions, dump_mem_ref_stats, debug_mem_ref_stats,
23637         debug_mem_sym_stats, dump_mem_sym_stats_for_var,
23638         debug_all_mem_sym_stats, debug_mp_info, update_mem_sym_stats_from_stmt,
23639         delete_mem_ref_stats, create_tag_raw, dump_points_to_info,
23640         dump_may_aliases_for, debug_may_aliases_for, new_type_alias):
23641         Remove public functions.
23642         (pass_reset_cc_flags): Remove.
23643         (pass_build_alias): Move ...
23644         * tree-ssa-structalias.c (pass_build_alias): ... here.
23645         * tree-ssa-alias.c (may_be_aliased): Move ...
23646         * tree-flow-inline.h (may_be_aliased): ... here.
23647         tree-ssa-alias.c (struct count_ptr_d, count_ptr_derefs,
23648         count_uses_and_derefs): Move ...
23649         * gimple.c: ... here.
23650         * gimple.h (count_uses_and_derefs): Declare.
23651         * tree-ssa-alias.c (dump_alias_stats, ptr_deref_may_alias_global_p,
23652         ptr_deref_may_alias_decl_p, ptr_derefs_may_alias_p,
23653         same_type_for_tbaa, nonaliasing_component_refs_p, decl_refs_may_alias_p,
23654         indirect_ref_may_alias_decl_p, indirect_refs_may_alias_p,
23655         ref_maybe_used_by_call_p, ref_maybe_used_by_stmt_p,
23656         call_may_clobber_ref_p, stmt_may_clobber_ref_p, maybe_skip_until,
23657         get_continuation_for_phi, walk_non_aliased_vuses, walk_aliased_vdefs):
23658         New functions.
23659         * tree-dfa.c (refs_may_alias_p): Move ...
23660         * tree-ssa-alias.c (refs_may_alias_p): ... here.  Extend.
23661         * tree-ssa-alias.h: New file.
23662         * tree-ssa-sink.c (is_hidden_global_store): Adjust.
23663         (statement_sink_location): Likewise.
23664         * opts.c (decode_options): Do not adjust max-aliased-vops or
23665         avg-aliased-vops values.
23666         * timevar.def (TV_TREE_MAY_ALIAS): Remove.
23667         (TV_CALL_CLOBBER): Likewise.
23668         (TV_FLOW_SENSITIVE): Likewise.
23669         (TV_FLOW_INSENSITIVE): Likewise.
23670         (TV_MEMORY_PARTITIONING): Likewise.
23671         (TV_ALIAS_STMT_WALK): New timevar.
23672         * tree-ssa-loop-ivcanon.c (empty_loop_p): Adjust.
23673         * tree-ssa-address.c (create_mem_ref_raw): Use build6.
23674         (get_address_description): Remove memory-tag related code.
23675         * tree-ssa-ifcombine.c (bb_no_side_effects_p): Adjust.
23676         * treestruct.def (TS_MEMORY_TAG, TS_MEMORY_PARTITION_TAG): Remove.
23677         * tree-eh.c (cleanup_empty_eh): Do not leave stale SSA_NAMEs
23678         and immediate uses in statements.  Document.
23679         * gimple-pretty-print.c (dump_gimple_mem_ops): Adjust.
23680         (dump_symbols): Remove.
23681         (dump_gimple_mem_ops): Do not dump loaded or stored syms.
23682         * alias.c (get_deref_alias_set): New function split out from ...
23683         (get_alias_set): ... here.
23684         * alias.h (get_deref_alias_set): Declare.
23685         * tree-vect-data-refs.c (vect_create_data_ref_ptr): Remove unused
23686         type parameter.  Remove restrict pointer handling.  Create a
23687         ref-all pointer in case type-based alias sets do not conflict.
23688         (vect_analyze_data_refs): Remove SMT related code.
23689         * tree-vect-stmts.c (vectorizable_store): Re-instantiate TBAA assert.
23690         (vectorizable_load): Likewise.
23691         * tree-data-ref.h (struct dr_alias): Remove symbol_tag field.
23692         (DR_SYMBOL_TAG, DR_VOPS): Remove.
23693         * tree-data-ref.c (dr_may_alias_p): Use the alias-oracle.
23694         Ignore vops and SMTs.
23695         (dr_analyze_alias): Likewise..
23696         (free_data_ref): Likewise.
23697         (create_data_ref): Likewise.
23698         (analyze_all_data_dependences): Likewise.
23699         (get_references_in_stmt): Adjust.
23700         * tree-flow-inline.h (gimple_aliases_computed_p,
23701         gimple_addressable_vars, gimple_call_clobbered_vars,
23702         gimple_call_used_vars, gimple_global_var, may_aliases, memory_partition,
23703         factoring_name_p, mark_call_clobbered, clear_call_clobbered,
23704         compare_ssa_operands_equal, symbol_mem_tag, set_symbol_mem_tag,
23705         gimple_mem_ref_stats): Remove.
23706         (gimple_vop): New function.
23707         (op_iter_next_use): Remove vuses and mayuses cases.
23708         (op_iter_next_def): Remove vdefs case.
23709         (op_iter_next_tree): Remove vuses, mayuses and vdefs cases.
23710         (clear_and_done_ssa_iter): Do not set removed fields.
23711         (op_iter_init): Likewise.  Skip vuse and/or vdef if requested.
23712         Assert we are not iterating over vuses or vdefs if not also
23713         iterating over uses or defs.
23714         (op_iter_init_use): Likewise.
23715         (op_iter_init_def): Likewise.
23716         (op_iter_next_vdef): Remove.
23717         (op_iter_next_mustdef): Likewise.
23718         (op_iter_init_vdef): Likewise.
23719         (compare_ssa_operands_equal): Likewise.
23720         (link_use_stmts_after): Handle vuse operand.
23721         (is_call_used): Use is_call_clobbered.
23722         (is_call_clobbered): Global variables are always call clobbered,
23723         query the call-clobbers bitmap.
23724         (mark_call_clobbered): Ignore global variables.
23725         (clear_call_clobbered): Likewise.
23726         * tree-ssa-coalesce.c (create_outofssa_var_map): Adjust
23727         virtual operands sanity check.
23728         * tree.def (NAME_MEMORY_TAG, SYMBOL_MEMORY_TAG, MEMORY_PARTITION_TAG):
23729         Remove.
23730         (TARGET_MEM_REF): Remove TMR_TAG operand.
23731         * tree-dfa.c (add_referenced_var): Initialize call-clobber state.
23732         Remove call-clobber related code.
23733         (remove_referenced_var): Likewise.  Do not clear mpt or symbol_mem_tag.
23734         (dump_variable): Do not dump SMTs, memory stats, may-aliases or
23735         partitions or escape reason.
23736         (get_single_def_stmt, get_single_def_stmt_from_phi,
23737         get_single_def_stmt_with_phi): Remove.
23738         (dump_referenced_vars): Tidy.
23739         (get_ref_base_and_extent): Allow bare decls.
23740         (collect_dfa_stats): Adjust.
23741         * graphite.c (rename_variables_in_stmt): Adjust.
23742         (graphite_copy_stmts_from_block): Likewise.
23743         (translate_clast): Likewise.
23744         * tree-ssa-pre.c (struct bb_bitmap_sets): Add expr_dies bitmap.
23745         (EXPR_DIES): New.
23746         (translate_vuse_through_block): Use the oracle.
23747         (phi_translate_1): Adjust.
23748         (value_dies_in_block_x): Use the oracle.  Cache the outcome
23749         in EXPR_DIES.
23750         (valid_in_sets): Check if the VUSE for
23751         a REFERENCE is available.
23752         (eliminate): Do not remove stmts during elimination,
23753         instead queue and remove them afterwards.
23754         (do_pre): Do not rebuild alias info.
23755         (pass_pre): Run TODO_rebuild_alias before PRE.
23756         * tree-ssa-live.c (remove_unused_locals): Remove memory-tag code.
23757         * tree-sra.c (sra_walk_function): Use gimple_references_memory_p.
23758         (mark_all_v_defs_stmt): Remove.
23759         (mark_all_v_defs_seq): Adjust.
23760         (sra_replace): Likewise.
23761         (scalarize_use): Likewise.
23762         (scalarize_copy): Likewise.
23763         (scalarize_init): Likewise.
23764         (scalarize_ldst): Likewise.
23765         (todoflags): Remove.
23766         (tree_sra): Do not rebuild alias info.
23767         (tree_sra_early): Adjust.
23768         (pass_sra): Run TODO_update_address_taken before SRA.
23769         * tree-predcom.c (set_alias_info): Remove.
23770         (prepare_initializers_chain): Do not call it.
23771         (mark_virtual_ops_for_renaming): Adjust.
23772         (mark_virtual_ops_for_renaming_list): Remove.
23773         (initialize_root_vars): Adjust.
23774         (initialize_root_vars_lm): Likewise.
23775         (prepare_initializers_chain): Likewise.
23776         * tree-ssa-copy.c (may_propagate_copy): Remove memory-tag related code.
23777         (may_propagate_copy_into_stmt): Likewise.
23778         (merge_alias_info): Do nothing for now.
23779         (propagate_tree_value_into_stmt): Adjust.
23780         (stmt_may_generate_copy): Likewise.
23781         * tree-ssa-forwprop.c (tidy_after_forward_propagate_addr): Do
23782         not mark symbols for renaming.
23783         (forward_propagate_addr_expr): Match up push/pop_stmt_changes
23784         with the same statement, make sure to update the new pointed-to one.
23785         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Do not copy
23786         call statements, do not mark symbols for renaming.
23787         (mark_operand_necessary): Dump something.
23788         (ref_may_be_aliased): New function.
23789         (mark_aliased_reaching_defs_necessary_1): New helper function.
23790         (mark_aliased_reaching_defs_necessary): Likewise.
23791         (mark_all_reaching_defs_necessary_1): Likewise.
23792         (mark_all_reaching_defs_necessary): Likewise.
23793         (propagate_necessity): Do not process virtual PHIs.  For
23794         non-aliased loads mark all reaching definitions as necessary.
23795         For aliased loads and stores mark the immediate dominating
23796         aliased clobbers as necessary.
23797         (visited): New global static.
23798         (perform_tree_ssa_dce): Free visited bitmap after propagating
23799         necessity.
23800         (remove_dead_phis): Perform simple dead virtual PHI removal.
23801         (remove_dead_stmt): Properly unlink virtual operands when
23802         removing stores.
23803         (eliminate_unnecessary_stmts): Schedule PHI removal after
23804         stmt removal.
23805         * tree-ssa-ter.c (is_replaceable_p): Adjust.
23806         (process_replaceable): Likewise.
23807         (find_replaceable_in_bb): Likewise.
23808         * tree-ssa.c (verify_ssa_name): Verify all VOPs are
23809         based on the single gimple vop.
23810         (verify_flow_insensitive_alias_info): Remove.
23811         (verify_flow_sensitive_alias_info): Likewise.
23812         (verify_call_clobbering): Likewise.
23813         (verify_memory_partitions): Likewise.
23814         (verify_alias_info): Likewise.
23815         (verify_ssa): Adjust..
23816         (execute_update_addresses_taken): Export.  Update SSA
23817         manually.  Optimize only when optimizing.  Use a local bitmap.
23818         (pass_update_address_taken): Remove TODO_update_ssa, add
23819         TODO_dump_func.
23820         (pass_update_address_taken): Just use TODO_update_address_taken.
23821         (init_tree_ssa): Do not initialize addressable_vars.
23822         (verify_ssa): Verify new VUSE / VDEF properties.
23823         Verify that all stmts definitions have the stmt as SSA_NAME_DEF_STMT.
23824         Do not call verify_alias_info.
23825         (delete_tree_ssa): Clear the VUSE, VDEF operands.
23826         Do not free the loaded and stored syms bitmaps.  Reset the escaped
23827         and callused solutions.  Do not free addressable_vars.
23828         Remove memory-tag related code.
23829         (warn_uninitialized_var): Aliases are always available.
23830         * tree-ssa-loop-prefetch.c (gather_memory_references): Adjust.
23831         * lambda-code.c (can_put_in_inner_loop): Adjust.
23832         (can_put_after_inner_loop): Likewise.
23833         (perfect_nestify): Likewise.
23834         * tree-vect-stmts.c (vect_stmt_relevant_p): Adjust.
23835         (vect_gen_widened_results_half): Remove CALL_EXPR handling.
23836         (vectorizable_conversion): Do not mark symbols for renaming.
23837         * tree-inline.c (remap_gimple_stmt): Clear VUSE/VDEF.
23838         (expand_call_inline): Unlink the calls virtual operands before
23839         replacing it.
23840         (tree_function_versioning): Do not call update_ssa if we are not
23841         updating clones.  Simplify.
23842         * tree-ssa-phiprop.c (phivn_valid_p): Adjust.
23843         (propagate_with_phi): Likewise..
23844         * tree-outof-ssa.c (create_temp): Remove memory tag and call
23845         clobber code.  Assert we are not aliased or global.
23846         * tree-flow.h: Include tree-ssa-alias.h
23847         (enum escape_type): Remove.
23848         (struct mem_sym_stats_d): Likewise.
23849         (struct mem_ref_stats_d): Likewise.
23850         (struct gimple_df): Add vop member.  Remove global_var,
23851         call_clobbered_vars, call_used_vars, addressable_vars,
23852         aliases_compted_p and mem_ref_stats members.  Add syms_to_rename,
23853         escaped and callused members.
23854         (struct ptr_info_def): Remove all members, add points-to solution
23855         member pt.
23856         (struct var_ann_d): Remove in_vuse_list, in_vdef_list,
23857         call_clobbered, escape_mask, mpt and symbol_mem_tag members.
23858         * Makefile.in (TREE_FLOW_H): Add tree-ssa-alias.h.
23859         (tree-ssa-structalias.o): Remove tree-ssa-structalias.h.
23860         (tree-ssa-alias.o): Likewise.
23861         (toplev.o): Add tree-ssa-alias.h
23862         (GTFILES): Remove tree-ssa-structalias.h, add tree-ssa-alias.h.
23863         * gimple.c (gimple_set_bb): Fix off-by-one error.
23864         (is_gimple_reg): Do not handle memory tags.
23865         (gimple_copy): Also copy virtual operands.
23866         Delay updating the statement.  Do not reset loaded and stored syms.
23867         (gimple_set_stored_syms): Remove.
23868         (gimple_set_loaded_syms): Likewise.
23869         (gimple_call_copy_skip_args): Copy the virtual operands
23870         and mark the new statement modified.
23871         * tree-ssa-structalias.c (may_alias_p): Remove.
23872         (set_uids_in_ptset): Take the alias set to prune with as
23873         parameter.  Fold in the alias test of may_alias_p.
23874         (compute_points_to_sets): Compute whether a ptr is dereferenced
23875         in a local sbitmap.
23876         (process_constraint): Deal with &ANYTHING on the lhs, reject all
23877         other ADDRESSOF constraints on the lhs.
23878         (get_constraint_for_component_ref): Assert that we don't get
23879         ADDRESSOF constraints from the base of the reference.
23880         Properly generate UNKNOWN_OFFSET for DEREF if needed.
23881         (struct variable_info): Remove collapsed_to member.
23882         (get_varinfo_fc): Remove.
23883         (new_var_info): Do not set collapsed_to.
23884         (dump_constraint): Do not follow cycles.
23885         (dump_constraint_graph): Likewise.
23886         (build_pred_graph): Likewise.
23887         (build_succ_graph): Likewise.
23888         (rewrite_constraints): Likewise.
23889         (do_simple_structure_copy): Remove.
23890         (do_rhs_deref_structure_copy): Remove.
23891         (do_lhs_deref_structure_copy): Remove.
23892         (collapse_rest_of_var): Remove.
23893         (do_structure_copy): Re-implement.
23894         (pta_stats): New global variable.
23895         (dump_pta_stats): New function.
23896         (struct constraint_expr): Make offset signed.
23897         (UNKNOWN_OFFSET): Define special value.
23898         (dump_constraint): Dump UNKNOWN_OFFSET as UNKNOWN.
23899         (solution_set_expand): New helper function split out from ...
23900         (do_sd_constraint): ... here.
23901         (solution_set_add): Handle UNKNOWN_OFFSET.  Handle negative offsets.
23902         (do_ds_constraint): Likewise.
23903         (do_sd_constraint): Likewise.  Do not special-case ESCAPED = *ESCAPED
23904         and CALLUSED = *CALLUSED.
23905         (set_union_with_increment): Make inc argument signed.
23906         (type_safe): Remove.
23907         (get_constraint_for_ptr_offset): Handle unknown and negative
23908         constant offsets.
23909         (first_vi_for_offset): Handle offsets before start.  Bail
23910         out early for offsets beyond the variable extent.
23911         (first_or_preceding_vi_for_offset): New function.
23912         (init_base_vars): Add ESCAPED = ESCAPED + UNKNOWN_OFFSET constraint.
23913         Together with ESCAPED = *ESCAPED this properly computes reachability.
23914         (find_what_var_points_to): New function.
23915         (find_what_p_points_to): Implement in terms of find_what_var_points_to.
23916         (pt_solution_reset, pt_solution_empty_p, pt_solution_includes_global,
23917         pt_solution_includes_1, pt_solution_includes, pt_solutions_intersect_1,
23918         pt_solutions_intersect): New functions.
23919         (compute_call_used_vars): Remove.
23920         (compute_may_aliases): New main entry into PTA computation.
23921         * gimple.h (gimple_p): New typedef.
23922         (struct gimple_statement_base): Remove references_memory_p.
23923         (struct gimple_statement_with_memory_ops_base): Remove
23924         vdef_ops, vuse_ops, stores and loads members.  Add vdef and vuse
23925         members.
23926         (gimple_vuse_ops, gimple_set_vuse_ops, gimple_vdef_ops,
23927         gimple_set_vdef_ops, gimple_loaded_syms, gimple_stored_syms,
23928         gimple_set_references_memory): Remove.
23929         (gimple_vuse_op, gimple_vdef_op, gimple_vuse, gimple_vdef,
23930         gimple_vuse_ptr, gimple_vdef_ptri, gimple_set_vuse, gimple_set_vdef):
23931         New functions.
23932         * tree-cfg.c (move_block_to_fn): Fix off-by-one error.
23933         (verify_expr): Allow RESULT_DECL.
23934         (gimple_duplicate_bb): Do not copy virtual operands.
23935         (gimple_duplicate_sese_region): Adjust.
23936         (gimple_duplicate_sese_tail): Likewise.
23937         (mark_virtual_ops_in_region): Remove.
23938         (move_sese_region_to_fn): Do not call it.
23939         * passes.c (init_optimization_passes): Remove pass_reset_cc_flags
23940         and pass_simple_dse.
23941         (execute_function_todo): Handle TODO_update_address_taken,
23942         call execute_update_addresses_taken for TODO_rebuild_alias.
23943         (execute_todo): Adjust.
23944         (execute_one_pass): Init dump files early.
23945         * ipa-struct-reorg.c (finalize_var_creation): Do not mark vars
23946         call-clobbered.
23947         (create_general_new_stmt): Clear vops.
23948         * tree-ssa-reassoc.c (get_rank): Adjust.
23949         * tree-vect-slp.c (vect_create_mask_and_perm): Do not mark
23950         symbols for renaming.
23951         * params.def (PARAM_MAX_ALIASED_VOPS): Remove.
23952         (PARAM_AVG_ALIASED_VOPS): Likewise.
23953         * tree-ssanames.c (init_ssanames): Allocate SYMS_TO_RENAME.
23954         (duplicate_ssa_name_ptr_info): No need to copy the shared bitmaps.
23955         * tree-ssa-operands.c: Simplify for new virtual operand representation.
23956         (operand_build_cmp, copy_virtual_operands,
23957         create_ssa_artificial_load_stmt, add_to_addressable_set,
23958         gimple_add_to_addresses_taken): Remove public functions.
23959         (unlink_stmt_vdef): New function.
23960
23961 2009-04-03  Alan Modra  <amodra@bigpond.net.au>
23962
23963         * config.gcc (powerpc-*-linux*): Merge variants.
23964
23965 2009-04-02  Chao-ying Fu  <fu@mips.com>
23966             James Grosbach  <james.grosbach@microchip.com>
23967
23968         * config/mips/mips.c (mips_frame_info): Add acc_mask, num_acc,
23969         num_cop0_regs, acc_save_offset, cop0_save_offset, acc_sp_offset,
23970         cop0_sp_offset.
23971         (machine_function): Add interrupt_handler_p, use_shadow_register_set_p,
23972         keep_interrupts_masked_p, use_debug_exception_return_p.
23973         (mips_attribute_table): Add interrupt, use_shadow_register_set,
23974         keep_interrupts_masked, use_debug_exception_return.
23975         (mips_interrupt_type_p, mips_use_shadow_register_set_p,
23976         mips_keep_interrupts_masked_p, mips_use_debug_exception_return_p):
23977         New functions.
23978         (mips_function_ok_for_sibcall): Return false for interrupt handlers.
23979         (mips_print_operand): Process COP0 registers to print $0 .. $31
23980         correctly for GAS to process.
23981         (mips_interrupt_extra_call_saved_reg_p): New function.
23982         (mips_cfun_call_saved_reg_p): For interrupt handlers, we need to check
23983         extra registers.
23984         (mips_cfun_might_clobber_call_saved_reg_p): Likewise.
23985         (mips_compute_frame_info): Add supports for interrupt context that
23986         includes doubleword accumulators and COP0 registers.
23987         (mips_for_each_saved_acc): New function.
23988         (mips_for_each_saved_gpr_and_fpr): Change the function name from
23989         mips_for_each_saved_reg.
23990         (mips_save_reg): Save accumulators.
23991         (mips_kernel_reg_p): A new for_each_rtx callback.
23992         (mips_expand_prologue): Support interrupt handlers.
23993         (mips_restore_reg): Restore accumulators.
23994         (mips_expand_epilogue): Support interrupt handlers.
23995         (mips_can_use_return_insn): Return false for interrupt handlers.
23996         (mips_epilogue_uses): New function.
23997         * config/mips/mips.md (UNSPEC_ERET, UNSPEC_DERET, UNSPEC_DI,
23998         UNSPEC_EHB, UNSPEC_RDPGPR, UNSPEC_COP0): New UNSPEC.
23999         (mips_eret, mips_deret, mips_di, mips_ehb, mips_rdpgpr,
24000         cop0_move): New instructions.
24001         * config/mips/mips-protos.h (mips_epilogue_uses): Declare.
24002         * config/mips/mips.h (K0_REG_NUM, K1_REG_NUM, KERNEL_REG_P): New
24003         defines.
24004         (COP0_STATUS_REG_NUM, COP0_CAUSE_REG_NUM, COP0_EPC_REG_NUM):
24005         New defines.
24006         (CAUSE_IPL, SR_IPL, SR_EXL, SR_IE): New defines.
24007         (MIPS_PROLOGUE_TEMP_REGNUM, MIPS_EPILOGUE_TEMP_REGNUM): For
24008         interrupt handlers, we use K0 as the temporary register.
24009         (EPILOGUE_USES): Change to a function call.
24010         * config/mips/sde.h (MIPS_EPILOGUE_TEMP_REGNUM): For interrupt
24011         handlers, we use K0 as the temporary register.
24012
24013         * doc/extend.texi (Function Attributes): Document interrupt,
24014         use_shadow_register_set, keep_interrupts_masked,
24015         use_debug_exception_return for MIPS attributes.
24016
24017 2009-04-03  Alan Modra  <amodra@bigpond.net.au>
24018
24019         * config.gcc (powerpc64-*-gnu*): Add rs6000/default64.h to tm_file.
24020         Remove a number of t-files from tmake_file.
24021         * config/rs6000/sysv4.opt (mprototype): Name variable target_prototype.
24022         * config/rs6000/sysv4.h (TARGET_PROTOTYPE): Define.
24023         * config/rs6000/linux64.h (SUBSUBTARGET_OVERRIDE_OPTIONS): Set
24024         target_prototype, not TARGET_PROTOTYPE.
24025         (LINK_OS_GNU_SPEC): Define.
24026         * config/rs6000/t-linux64 (LIB2FUNCS_EXTRA): Delete tramp.S
24027         and darwin-ldoubdle.c.
24028
24029 2009-04-02  Michael Meissner  <meissner@linux.vnet.ibm.com>
24030
24031         PR driver/39293
24032         * gcc.c (save_temps_flag): Add support for -save-temps=obj.
24033         (cpp_options): Ditto.
24034         (default_compilers): Ditto.
24035         (display_help): Ditto.
24036         (process_command): Ditto.
24037         (do_spec_1): Ditto.
24038         (set_input): Use lbasename instead of duplicate code.
24039         (save_temps_prefix): New static for -save-temps=obj.
24040         (save_temps_length): Ditto.
24041
24042         * doc/invoke.texi (-save-temps=obj): Document new variant to
24043         -save-temps switch.
24044
24045 2009-04-02  Jeff Law  <law@redhat.com>
24046
24047         * reload1.c (fixup_eh_region_notes): Remove write-only "trap_count"
24048         variable.
24049
24050 2009-04-02  H.J. Lu  <hongjiu.lu@intel.com>
24051
24052         * configure.ac: Support -Bstatic/-Bdynamic for linker version > 2.
24053         * configure: Regenerated.
24054
24055 2009-04-02  Rafael Avila de Espindola  <espindola@google.com>
24056
24057         * c-decl.c (merge_decls): Make sure newdecl and olddecl don't
24058         share the argument list.
24059
24060 2009-04-02  Rafael Avila de Espindola  <espindola@google.com>
24061
24062         Merge
24063
24064         2009-02-12  Diego Novillo  <dnovillo@google.com>
24065
24066         * varpool.c (debug_varpool): New.
24067         * cgraph.h (debug_varpool): Declare.
24068
24069 2009-04-02  Jan Hubicka  <jh@suse.cz>
24070
24071         * passes.c (init_optimization_passes): Remove two copies of ehcleanup
24072         pass.
24073
24074 2009-04-02  H.J. Lu  <hongjiu.lu@intel.com>
24075
24076         * config/i386/i386.c (ix86_abi): Move initialization to ...
24077         (override_options): Here.
24078
24079 2009-04-02  Christian Bruel  <christian.bruel@st.com>
24080
24081         * config/sh/sh.c (sh_dwarf_register_span): New function.
24082         (TARGET_DWARF_REGISTER_SPAN): Define.
24083         * config/sh/sh-protos.h (sh_dwarf_register_span): Declare.
24084
24085 2009-04-02  Ira Rosen  <irar@il.ibm.com>
24086
24087         PR tree-optimization/39595
24088         * tree-vect-slp.c (vect_build_slp_tree): Check that the size of
24089         interleaved loads group is not  greater than the SLP group size.
24090
24091 2009-04-02  Rafael Avila de Espindola  <espindola@google.com>
24092
24093         * builtins.c (is_builtin_name): New.
24094         (called_as_built_in): Use is_builtin_name.
24095         * tree.h (is_builtin_name): New.
24096         * varasm.c (incorporeal_function_p): Use is_builtin_name
24097
24098 2009-04-02  Andrew Stubbs  <ams@codesourcery.com>
24099
24100         * config/sh/linux-unwind.h: Disable when inhibit_libc is defined.
24101
24102 2009-04-02  Dodji Seketeli  <dodji@redhat.com>
24103
24104         PR c++/26693
24105         * c-decl.c (clone_underlying_type): Move this ...
24106         * c-common.c (set_underlying_type): ... here.
24107         Also, make sure the function properly sets TYPE_STUB_DECL() on
24108         the newly created typedef variant type.
24109         * c-common.h (is_typedef_decl, set_underlying_type): Declare ...
24110         * c-common.c (is_typedef_decl, set_underlying_type): ... new entry
24111         points.
24112
24113 2009-04-02  Richard Guenther  <rguenther@suse.de>
24114
24115         PR tree-optimization/37221
24116         * tree-flow.h (degenerate_phi_result): Declare.
24117         * tree-ssa-dom.c (degenerate_phi_result): Export.
24118         * tree-scalar-evolution.c (analyze_initial_condition): If
24119         the initial condition is defined by a degenerate PHI node
24120         use the degenerate value.
24121
24122 2009-04-01  Eric Botcazou  <ebotcazou@adacore.com>
24123
24124         PR rtl-optimization/39588
24125         * combine.c (merge_outer_ops): Do not set the constant when this
24126         is not necessary.
24127         (simplify_shift_const_1): Do not modify it either in this case.
24128
24129 2009-04-01  Steven Bosscher  <steven@gcc.gnu.org>
24130
24131         * config/ia64/ia64.c (ia64_handle_option): Inform user that Itanium1
24132         tuning is deprecated if -mtune value is set to an Itanium1 variant.
24133
24134 2009-04-01  Janis Johnson  <janis187@us.ibm.com>
24135
24136         PR c/29027
24137         * c-lex.c (interpret_float): Default (no suffix) is double.
24138
24139 2009-04-1  Xinliang David Li  <davidxl@google.com>
24140
24141         * config/i386/i386.c (legitimate_constant_p): Recognize
24142         all one vector constant.
24143
24144 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
24145
24146         * config/vax/vax.c: Add #includes to silence warnings.
24147         Change #include order to silence two warnings.
24148
24149 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
24150
24151         * config/vax/linux.h (TARGET_DEFAULT): Add the MASK_QMATH flag bit.
24152         (ASM_SPEC): Pass -k to the assembler for PIC code.
24153
24154 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
24155
24156         * config.gcc: Add vax-*-linux* to the switch.
24157         * config/vax/linux.h: New file. (TARGET_VERSION,
24158         TARGET_OS_CPP_BUILTINS, TARGET_DEFAULT, CPP_SPEC, LINK_SPEC): Define.
24159
24160 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
24161
24162         * config/vax/vax.c (vax_output_int_move, adjacent_operands_p):
24163         Use predicate macros instead of GET_CODE() == foo.
24164         * config/vax/vax.md (movsi_2, movstrictqi, and<mode>3, ashrsi3,
24165         ashlsi3, rotrsi3, <unnamed>): Likewise.
24166
24167 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
24168
24169         * config/vax/builtins.md (jbbssiqi, jbbssihi, jbbssisi, jbbcciqi,
24170         jbbccihi, jbbccisi): Remova trailing whitespace.
24171         * config/vax/constraints.md: Likewise.
24172         * config/vax/elf.h: (ASM_PREFERRED_EH_DATA_FORMAT): Likewise.
24173         * config/vax/openbsd1.h (OBSD_OLD_GAS): Likewise.
24174         * config/vax/predicates.md: Likewise.
24175         * config/vax/vax.c (print_operand_address, vax_output_int_move,
24176         vax_expand_addsub_di_operands, adjacent_operands_p): Likewise.
24177         * config/vax/vax.h: Likewise.
24178         * config/vax/vax.md (nonlocal_goto): Likewise.
24179
24180 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
24181
24182         * config/vax/vax.c (vax_float_literal, vax_output_int_move)
24183         (indirectable_address_p, adjacent_operands_p): Add spaces around
24184         braces.
24185         * config/vax/vax-protos.h (adjacent_operands_p): Likewise.
24186
24187 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
24188
24189         * config/vax/vax.c (legitimate_constant_address_p,
24190         legitimate_constant_p, indirectable_address_p, nonindexed_address_p,
24191         index_term_p, reg_plus_index_p, legitimate_address_p,
24192         vax_mode_dependent_address_p): Update comments to match functions
24193         modified by the recent int->bool conversion.
24194
24195 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
24196
24197         * config/vax/builtins.md: Update copyright message.
24198         * config/vax/constraints.md: Likewise.
24199         * config/vax/netbsd-elf.h: Likewise.
24200         * config/vax/predicates.md: Likewise.
24201         * config/vax/vax-protos.h: Likewise.
24202         * config/vax/vax.c: Likewise.
24203         * config/vax/vax.h: Likewise.
24204         * config/vax/vax.md: Likewise.
24205         * config/vax/vax.opt: Likewise.
24206
24207 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
24208
24209         * config/vax/builtins.md (ffssi2, ffssi2_internal,
24210         sync_lock_test_and_set<mode>, sync_lock_release<mode>): Fix indention.
24211         * config/vax/constraints.md (B, R): Likewise.
24212         * config/vax/predicates.md (external_memory_operand,
24213         nonimmediate_addsub_di_operand): Likewise.
24214         * config/vax/vax.c (vax_output_int_add): Likewise.
24215         * config/vax/vax.md (movsi, movsi_2, mov<mode>, call_value,
24216         untyped_call): Likewise.
24217
24218 2009-04-01  Matt Thomas  <matt@3am-software.com>
24219
24220         * config/vax/predicates.md: New file.
24221         (symbolic_operand, local_symbolic_operand, external_symbolic_operand,
24222         external_const_operand, nonsymbolic_operand, external_memory_operand,
24223         indirect_memory_operand, indexed_memory_operand,
24224         illegal_blk_memory_operand, illegal_addsub_di_memory_operand,
24225         nonimmediate_addsub_di_operand, general_addsub_di_operand): New
24226         predicate.
24227         * config/vax/constraints.md: New file.
24228         (Z0, U06,  U08, U16, CN6, S08, S16, I, J, K, L, M, N, O, G, Q, B, R, T):
24229         New constraint.
24230         * config/vax/builtins.md: New file.
24231         (ffssi2, ffssi2_internal, sync_lock_test_and_set<mode>, jbbssiqi,
24232         jbbssihi, jbbssisi, sync_lock_release<mode>, jbbcciqi, jbbccihi,
24233         jbbccisi): Define.
24234         * config/vax/vax.opt (mqmath): Add option.
24235         * config/vax/vax.md (isfx): Extend with DI.
24236         (VAXintQH, VAXintQHSD): Define.
24237         (tst<mode>, cmp<mode>, *bit<mode>, movmemhi1, truncsiqi2, truncsihi2,
24238         mulsidi3, add<mode>3, sub<mode>, mul<mode>3, div<mode>3, and<mode>,
24239         and<mode>_const_int, ior<mode>3, xor<mode>3, neg<mode>2,
24240         one_cmpl<mode>2, ashlsi3, lshrsi3, rotlsi3): Update constraints.
24241         (movdi): Update constraints and use vax_output_int_move().
24242         (movsi, movsi_2, pushlclsymreg, pushextsymreg, movlclsymreg,
24243         movextsymreg, adddi3, adcdi3, subdi3, sbcdi3, pushextsym, movextsym,
24244         pushlclsym, movlclsym, movaddr<mode>, pushaddr<mode>,
24245         nonlocal_goto): New.
24246         (mov<mode>): Extend accepted operand types.
24247         (subdi3_old): Rename from subdi3, change update constraints and use
24248         a new implementation.
24249         * config/vax/vax.h (PCC_BITFIELD_TYPE_MATTERS): Add space.
24250         (FRAME_POINTER_CFA_OFFSET, IRA_COVER_CLASSES, CLASS_MAX_NREGS,
24251         MOVE_RATIO, CLEAR_RATIO): Define.
24252         (REG_CLASS_FROM_LETTER, CONST_OK_FOR_LETTER_P,
24253         CONST_DOUBLE_OK_FOR_LETTER_P, EXTRA_CONSTRAINT): Delete.
24254         (PRINT_OPERAND): Redefine using a function instead of inlined code.
24255         * config/vax/vax.c (TARGET_BUILTIN_SETJMP_FRAME_VALUE): Define.
24256         (split_quadword_operands): Make static and really allow variable
24257         splitting.
24258         (print_operand_address): Update for PIC generation.
24259         (print_operand, vax_builtin_setjmp_frame_value, vax_output_int_subtract,
24260         indexable_address_p, fixup_mathdi_operand,
24261         vax_expand_addsub_di_operands, adjacent_operands_p): New.
24262         (vax_float_literal, legitimate_constant_p,
24263         indirectable_constant_address_p, index_term_p,
24264         reg_plus_index_p): Return bool instead of int.
24265         (vax_rtx_costs): Fix cost for CONST_INT, indent and use HOST_WIDE_INT
24266         where needed.
24267         (vax_output_int_move, vax_output_int_add): Extend to allow PIC
24268         generation.
24269         (vax_output_conditional_branch): Indent.
24270         (legitimate_constant_address_p, indirectable_constant_address_p,
24271         indirectable_address_p, nonindexed_address_p, legitimate_address_p,
24272         vax_mode_dependent_address_p): Return bool instead of int, update for
24273         PIC generation.
24274         * config/vax/vax-protos.h (legitimate_constant_address_p,
24275         legitimate_constant_p, legitimate_address_p,
24276         vax_mode_dependent_address_p): Change declaration to bool.
24277         (legitimate_pic_operand_p, adjacent_operands_p, print_operand,
24278         vax_expand_addsub_di_operands, vax_output_int_subtract,
24279         vax_output_movmemsi): Declare.
24280         (split_quadword_operands, vax_float_literal): Delete declaration.
24281         * config/vax/netbsd-elf.h (CC1_SPEC, CC1PLUS_SPEC) Define.
24282         * config/vax/elf.h (NO_EXTERNAL_INDIRECT_ADDRESS,
24283         VAX_CC1_AND_CC1PLUS_SPEC, ASM_PREFERRED_EH_DATA_FORMAT,
24284         ASM_OUTPUT_DWARF_PCREL): Define.
24285         (ASM_SPEC): Change definition to allow PIC generation.
24286
24287 2009-04-01  Steve Ellcey  <sje@cup.hp.com>
24288
24289         * doc/sourcebuild.texi: Update front-end requirements.
24290
24291 2009-04-01  Jakub Jelinek  <jakub@redhat.com>
24292
24293         PR target/39226
24294         * config/rs6000/rs6000.md (andsi3_internal5_nomc,
24295         anddi3_internal2_nomc, anddi3_internal3_nomc): Removed.
24296         (booldi3_internal3): Use boolean_or_operator instead of
24297         boolean_operator.
24298
24299 2009-04-01  Joseph Myers  <joseph@codesourcery.com>
24300
24301         PR c/39605
24302         * c-decl.c (grokdeclarator): Pedwarn for file-scope array
24303         declarator whose size is not an integer constant expression but
24304         folds to an integer constant, then treat it as a constant
24305         subsequently.
24306
24307 2009-04-01  Richard Guenther  <rguenther@suse.de>
24308
24309         * fold-const.c (fold_plusminus_mult_expr): Do not fold
24310         i * 4 + 2 to (i * 2 + 1) * 2.
24311
24312 2009-04-01  Jakub Jelinek  <jakub@redhat.com>
24313
24314         PR c/37772
24315         * c-parser.c (c_parser_asm_statement): Skip until close paren and
24316         return if c_parser_asm_string_literal returned NULL.
24317
24318 2009-04-01  Nick Clifton  <nickc@redhat.com>
24319
24320         * config/m32c/m32c.h (LIBGCC2_UNITS_PER_WORD): Define if not
24321         already defined.
24322         * config/m32c/t-m32c (LIB2FUNCS_EXTRA): Add m32c-lib2-trapv.c.
24323         * config/m32c/m32c-lib2.c: Remove unused typedefs.  Rename the
24324         other typedefs to avoid conflicts with libgcc2.c.  Define labels
24325         to gain 16-bit bit-manipulation functions from libgcc2.c and then
24326         include it.
24327         * config/m32c/m32c-lib2-trapv.c: New file.  Define labels
24328         to gain 16-bit trapping arithmetic functions from libgcc2.c and
24329         then include it.
24330
24331 2009-04-01  Rafael Avila de Espindola  <espindola@google.com>
24332
24333         * varasm.c (default_function_rodata_section): Declare DOT as
24334         const char*.
24335
24336 2009-04-01  Kai Tietz  <kai.tietz@onevision.com>
24337             Andrey Galkin  <agalkin@hypercom.com>
24338
24339         PR/39492
24340         * config/i386/host-mingw32.c (mingw32_gt_pch_use_address):
24341         Make object_name unique for each process.
24342
24343 2009-04-01  Jakub Jelinek  <jakub@redhat.com>
24344
24345         PR other/39591
24346         * omp-low.c (remove_exit_barrier): Don't optimize if there are any
24347         addressable variables in the parallel that could go out of scope while
24348         running queued tasks.
24349
24350 2009-04-01  Anatoly Sokolov  <aesok@post.ru>
24351
24352         * config/avr/avr.h (avr_case_values_threshold): Remove declaration.
24353         (CASE_VALUES_THRESHOLD): Redefine.
24354         * config/avr/avr.c (avr_override_options): Remove initialization of
24355         avr_case_values_threshold variable.
24356         (avr_case_values_threshold): Remove variable. Add new function.
24357         * config/avr/avr-protos.h (avr_case_values_threshold): Declare.
24358         * config/avr/avr.opt (mno-tablejump): Remove option.
24359         * doc/invoke.texi (AVR Options): Remove -mno-tablejump.
24360
24361 2009-04-01  DJ Delorie  <dj@redhat.com>
24362
24363         * varasm.c (default_function_rodata_section): Don't assume
24364         anything about where the first '.' in the section name is.
24365
24366 2009-04-01  Alan Modra  <amodra@bigpond.net.au>
24367
24368         * config/rs6000/rs6000.c (rs6000_emit_stack_reset): Delete redundant
24369         rs6000_emit_stack_tie.
24370
24371 2009-03-31  Ian Lance Taylor  <iant@google.com>
24372
24373         * tree-eh.c (tree_remove_unreachable_handlers): Compare
24374         gimple_code with GIMPLE_RESX, not RESX.
24375
24376 2009-03-31  Joseph Myers  <joseph@codesourcery.com>
24377
24378         * c-common.c (c_get_ident): New.
24379         (c_common_nodes_and_builtins): Call it for type names that may be NULL.
24380
24381 2009-04-01  Ben Elliston  <bje@au.ibm.com>
24382
24383         * config/rs6000/sysv4.opt (msdata): Improve option description.
24384
24385 2009-03-31  Steve Ellcey  <sje@cup.hp.com>
24386
24387         * config/ia64/ia64.md (divsf3_internal_lat): Remove.
24388         (divdf3_internal_lat): Remove.
24389         (divxf3_internal_lat): Remove.
24390         (divxf3_internal_thr): Remove.
24391         (divxf): Use divxf3_internal.
24392         * config/ia64/div.md (divsf3_internal_lat): New.
24393         (divdf3_internal_lat): New.
24394         (divxf3_internal): New.
24395
24396 2009-03-31  Joseph Myers  <joseph@codesourcery.com>
24397
24398         PR c/448
24399         * Makefile.in (USE_GCC_STDINT): Define.
24400         (stmp-int-hdrs): Install stdint.h if applicable.
24401         * c-common.c (CHAR16_TYPE): Define in terms of UINT_LEAST16_TYPE
24402         if known.
24403         (CHAR32_TYPE): Define in terms of UINT_LEAST32_TYPE if known.
24404         (SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE, INT32_TYPE, INT64_TYPE,
24405         UINT8_TYPE, UINT16_TYPE, UINT32_TYPE, UINT64_TYPE,
24406         INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE,
24407         INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE,
24408         UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE,
24409         INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE,
24410         UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE,
24411         UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE): Define.
24412         (c_common_nodes_and_builtins): Initialize
24413         underlying_wchar_type_node.  Do not initialize
24414         signed_wchar_type_node or unsigned_wchar_type_node.  Initialize
24415         nodes for new types.
24416         (c_stddef_cpp_builtins): Define macros for new types.
24417         * c-common.h (CTI_SIGNED_WCHAR_TYPE, CTI_UNSIGNED_WCHAR_TYPE):
24418         Remove.
24419         (CTI_UNDERLYING_WCHAR_TYPE, CTI_SIG_ATOMIC_TYPE, CTI_INT8_TYPE,
24420         CTI_INT16_TYPE, CTI_INT32_TYPE, CTI_INT64_TYPE, CTI_UINT8_TYPE,
24421         CTI_UINT16_TYPE, CTI_UINT32_TYPE, CTI_UINT64_TYPE,
24422         CTI_INT_LEAST8_TYPE, CTI_INT_LEAST16_TYPE, CTI_INT_LEAST32_TYPE,
24423         CTI_INT_LEAST64_TYPE, CTI_UINT_LEAST8_TYPE, CTI_UINT_LEAST16_TYPE,
24424         CTI_UINT_LEAST32_TYPE, CTI_UINT_LEAST64_TYPE, CTI_INT_FAST8_TYPE,
24425         CTI_INT_FAST16_TYPE, CTI_INT_FAST32_TYPE, CTI_INT_FAST64_TYPE,
24426         CTI_UINT_FAST8_TYPE, CTI_UINT_FAST16_TYPE, CTI_UINT_FAST32_TYPE,
24427         CTI_UINT_FAST64_TYPE, CTI_INTPTR_TYPE, CTI_UINTPTR_TYPE): Define.
24428         (signed_wchar_type_node, unsigned_wchar_type_node): Remove.
24429         (underlying_wchar_type_node, sig_atomic_type_node, int8_type_node,
24430         int16_type_node, int32_type_node, int64_type_node,
24431         uint8_type_node, uint16_type_node, c_uint32_type_node,
24432         c_uint64_type_node, int_least8_type_node, int_least16_type_node,
24433         int_least32_type_node, int_least64_type_node,
24434         uint_least8_type_node, uint_least16_type_node,
24435         uint_least32_type_node, uint_least64_type_node,
24436         int_fast8_type_node, int_fast16_type_node, int_fast32_type_node,
24437         int_fast64_type_node, uint_fast8_type_node, uint_fast16_type_node,
24438         uint_fast32_type_node, uint_fast64_type_node, intptr_type_node,
24439         uintptr_type_node): Define.
24440         * c-cppbuiltin.c (builtin_define_constants,
24441         builtin_define_type_minmax): New.
24442         (builtin_define_stdint_macros): Define more macros.
24443         (c_cpp_builtins): Define more limit macros.
24444         (type_suffix): New.
24445         (builtin_define_type_max): Define in terms of
24446         builtin_define_type_minmax.  Remove is_long parameter.  All
24447         callers changed.
24448         * config.gcc (use_gcc_stdint): Define.
24449         (tm_file): Add glibc-stdint.h for targets using glibc or uClibc.
24450         Add newlib-stdint.h for generic targets.
24451         * config/glibc-stdint.h, config/newlib-stdint.h,
24452         ginclude/stdint-gcc.h, ginclude/stdint-wrap.h: New.
24453         * config/m32c/m32c.h (UINTPTR_TYPE): Define.
24454         * config/score/score.h (UINTPTR_TYPE): Define.
24455         * config/sol2.h (SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE,
24456         INT32_TYPE, INT64_TYPE, UINT8_TYPE, UINT16_TYPE, UINT32_TYPE,
24457         UINT64_TYPE, INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE,
24458         INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE,
24459         UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE,
24460         INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE,
24461         UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE,
24462         UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE): Define.
24463         * config/spu/spu.h (STDINT_LONG32): Define.
24464         * configure.ac (use_gcc_stdint): Substitute.
24465         * configure: Regenerate.
24466         * doc/cpp.texi (__SIG_ATOMIC_TYPE__, __INT8_TYPE__,
24467         __INT16_TYPE__, __INT32_TYPE__, __INT64_TYPE__, __UINT8_TYPE__,
24468         __UINT16_TYPE__, __UINT32_TYPE__, __UINT64_TYPE__,
24469         __INT_LEAST8_TYPE__, __INT_LEAST16_TYPE__, __INT_LEAST32_TYPE__,
24470         __INT_LEAST64_TYPE__, __UINT_LEAST8_TYPE__, __UINT_LEAST16_TYPE__,
24471         __UINT_LEAST32_TYPE_, __UINT_LEAST64_TYPE__, __INT_FAST8_TYPE__,
24472         __INT_FAST16_TYPE__, __INT_FAST32_TYPE__, __INT_FAST64_TYPE__,
24473         __UINT_FAST8_TYPE__, __UINT_FAST16_TYPE__, __UINT_FAST32_TYPE__,
24474         __UINT_FAST64_TYPE__, __INTPTR_TYPE__, __UINTPTR_TYPE__,
24475         __WINT_MAX__, __SIZE_MAX__, __PTRDIFF_MAX__, __UINTMAX_MAX__,
24476         __SIG_ATOMIC_MAX__, __INT8_MAX__, __INT16_MAX__, __INT32_MAX__,
24477         __INT64_MAX__, __UINT8_MAX__, __UINT16_MAX__, __UINT32_MAX__,
24478         __UINT64_MAX__, __INT_LEAST8_MAX__, __INT_LEAST16_MAX__,
24479         __INT_LEAST32_MAX__, __INT_LEAST64_MAX__, __UINT_LEAST8_MAX__,
24480         __UINT_LEAST16_MAX__, __UINT_LEAST32_MAX__, __UINT_LEAST64_MAX__,
24481         __INT_FAST8_MAX__, __INT_FAST16_MAX__, __INT_FAST32_MAX__,
24482         __INT_FAST64_MAX__, __UINT_FAST8_MAX__, __UINT_FAST16_MAX__,
24483         __UINT_FAST32_MAX__, __UINT_FAST64_MAX__, __INTPTR_MAX__,
24484         __UINTPTR_MAX__, __WCHAR_MIN__, __WINT_MIN__, __SIG_ATOMIC_MIN__,
24485         __INT8_C, __INT16_C, __INT32_C, __INT64_C, __UINT8_C, __UINT16_C,
24486         __UINT32_C, __UINT64_C, __INTMAX_C, __UINTMAX_C): Document.
24487         * doc/tm.texi (SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE, INT32_TYPE,
24488         INT64_TYPE, UINT8_TYPE, UINT16_TYPE, UINT32_TYPE, UINT64_TYPE,
24489         INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE,
24490         INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE,
24491         UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE,
24492         INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE,
24493         UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE,
24494         UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE): Document.
24495
24496 2009-03-31  Bernd Schmidt  <bernd.schmidt@analog.com>
24497
24498         * loop-iv.c (suitable_set_for_replacement): Renamed from
24499         simplify_using_assignment; changed to return bool and to accept new
24500         args DEST and SRC.  Return true iff we find a source/destination pair
24501         that can be used to make a replacement, and fill SRC and DEST if so.
24502         Remove arg ALTERED.  Don't deal with altered regs here.  All callers
24503         changed.
24504         (simplify_using_initial_values): Deal with altered regs here and track
24505         more precisely the effect they have on the validity of our expression.
24506
24507         * loop-iv.c (simplify_using_condition): A condition of the form
24508         (EQ REG CONST) can be used to simply make a substitution.
24509         (simplify_using_initial_values): Keep track of conditions we have seen
24510         and keep using them to simplify new expressions, while applying the
24511         same substitutions to them as to the expression.
24512
24513         * simplify-rtx.c (simplify_relational_operation_1): Simplify
24514         (LTU (PLUS a C) C) or (LTU (PLUS a C) a) to (GEU a -C); likewise with
24515         GEU/LTU reversed.
24516
24517         * loop-iv.c (determine_max_iter): New arg OLD_NITER.  All callers
24518         changed.  Use this when trying to improve the upper bound.
24519         Generate the comparison by using simplify_gen_relational.
24520
24521         * loop-iv.c (simple_rhs_p): Allow more kinds of expressions.
24522
24523         * loop-iv.c (replace_single_def_regs, replace_in_expr): New static
24524         functions.
24525         (simplify_using_assignment, simplify_using_initial_values): Call
24526         replace_in_expr to make replacements.  Call replace_single_def_regs
24527         once on the initial version of the expression.
24528
24529 2009-03-31  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
24530
24531         PR target/27237
24532         * doc/invoke.texi (ARM Options): Update documentation for -mthumb.
24533
24534 2009-03-31  Richard Guenther  <rguenther@suse.de>
24535
24536         PR middle-end/31029
24537         * fold-const.c (fold_binary): Fold X +- Y CMP X to Y CMP 0 for
24538         equality comparisons.  Fold C - X CMP X if C % 2 == 1.
24539
24540 2009-03-31  Richard Guenther  <rguenther@suse.de>
24541
24542         * tree.h (div_if_zero_remainder): Declare.
24543         * fold-const.c (div_if_zero_remainder): Export.
24544         * tree-ssa-forwprop.c
24545         (forward_propagate_addr_into_variable_array_index): Handle
24546         constant array index addition outside of the variable index.
24547
24548 2009-03-31  Joseph Myers  <joseph@codesourcery.com>
24549
24550         PR target/39592
24551         * config/i386/i386.md (*floatunssi<mode>2_1, two unnamed
24552         define_splits, floatunssi<mode>2): Require x87 conversions from
24553         DImode to be permitted.
24554
24555 2009-03-31  Joseph Myers  <joseph@codesourcery.com>
24556
24557         PR preprocessor/15638
24558         * c-common.c (c_cpp_error): Handle CPP_DL_FATAL.
24559
24560 2009-03-31  Richard Guenther  <rguenther@suse.de>
24561
24562         PR middle-end/23401
24563         PR middle-end/27810
24564         * tree.h (DECL_GIMPLE_FORMAL_TEMP_P): Remove.
24565         (struct tree_decl_with_vis): Remove gimple_formal_temp member.
24566         * tree-eh.c (lower_eh_constructs_2): Move LHS assignment to
24567         a separate statement.
24568         * gimplify.c (pop_gimplify_context): Remove formal temp handling.
24569         (lookup_tmp_var): Likewise.
24570         (is_gimple_formal_tmp_or_call_rhs): Remove.
24571         (is_gimple_reg_or_call_rhs): Rename to ...
24572         (is_gimple_reg_rhs_or_call): ... this.
24573         (is_gimple_mem_or_call_rhs): Rename to ...
24574         (is_gimple_mem_rhs_or_call): ... this.
24575         (internal_get_tmp_var): Use is_gimple_reg_rhs_or_call.  Set
24576         DECL_GIMPLE_REG_P only if is_formal is true.
24577         (gimplify_compound_lval): Use is_gimple_reg.  Remove workaround
24578         for non-proper post-modify expression gimplification.
24579         (gimplify_self_mod_expr): For post-modify expressions gimplify
24580         the lvalue to a minimal lvalue.
24581         (rhs_predicate_for): Remove formal temp case.
24582         (gimplify_modify_expr_rhs): Likewise.
24583         (gimplify_addr_expr): Use is_gimple_reg.
24584         (gimplify_expr): Remove formal temp cases.
24585         (gimple_regimplify_operands): Likewise.
24586         * tree-ssa-pre.c (get_or_alloc_expr_for): Treat EXC_PTR_EXPR
24587         and FILTER_EXPR like constants.
24588         * gimple.c (walk_gimple_op): Fix val_only initialization, use
24589         is_gimple_reg.
24590         (is_gimple_formal_tmp_rhs): Remove.
24591         (is_gimple_reg_rhs): Remove special casing.
24592         (is_gimple_mem_rhs): Fix.
24593         (is_gimple_reg): Move DECL_GIMPLE_REG_P handling earlier.
24594         (is_gimple_formal_tmp_var): Remove.
24595         (is_gimple_formal_tmp_reg): Likewise.
24596         (is_gimple_min_lval): Allow invariant component ref parts.
24597         * gimple.h (is_gimple_formal_tmp_rhs, is_gimple_formal_tmp_var,
24598         is_gimple_formal_tmp_reg): Remove declarations.
24599         * tree-cfg.c (verify_expr): Verify that variables with address
24600         taken do not have DECL_GIMPLE_REG_P set.
24601         * tree-mudflap.c (mf_build_check_statement_for): Use
24602         force_gimple_operand instead of gimplify_expr.
24603
24604 2009-03-31  Ayal Zaks  <zaks@il.ibm.com>
24605
24606         * modulo-sched.c (sms_schedule_by_order): Pass the actual
24607         schedulable rows to compute_split_row.
24608
24609 2009-03-31  Ben Elliston  <bje@au.ibm.com>
24610
24611         PR target/31635
24612         * config/rs6000/rs6000.c (rs6000_handle_option): Handle
24613         OPT_mvrsave.
24614
24615 2009-03-31  Alan Modra  <amodra@bigpond.net.au>
24616
24617         * doc/invoke.texi (RS/6000 and PowerPC Options):Document mtls-markers.
24618         * configure.ac (HAVE_AS_TLS_MARKERS): New gas feature check.
24619         * configure: Regenerate.
24620         * config.in: Regenerate.
24621         * config/rs6000/rs6000.opt (mtls-markers): Add.
24622         * config/rs6000/rs6000.h (TARGET_TLS_MARKERS): Define.
24623         * config/rs6000/rs6000.md (tls_gd_aix, tls_gd_sysv): Add splitter.
24624         (tls_ld_aix, tls_ld_sysv): Likewise.
24625         (tls_gd, tls_gd_call_aix, tls_gd_call_sysv): New insns.
24626         (tls_ld, tls_ld_call_aix, tls_ld_call_sysv): Likewise.
24627
24628 2009-03-31  Alan Modra  <amodra@bigpond.net.au>
24629
24630         * config/spu/spu.c (spu_expand_prologue): Delete redundant code.
24631
24632 2009-03-30  Jan Hubicka  <jh@suse.cz>
24633
24634         * tree-eh.c (make_eh_edges): Set probability 100% to first edge
24635         out of RESX.
24636         (tree_remove_unreachable_handlers): Cleanup EH predecestor
24637         detection and label handling.
24638
24639 2009-03-30  Vladimir Makarov  <vmakarov@redhat.com>
24640
24641         * ira-int.h (ira_allocno): Rename left_conflicts_num to
24642         left_conflicts_size.
24643         (ALLOCNO_LEFT_CONFLICTS_NUM): Rename to
24644         ALLOCNO_LEFT_CONFLICTS_SIZE.
24645
24646         * ira-color.c (allocno_spill_priority, push_allocno_to_stack,
24647         remove_allocno_from_bucket_and_push,
24648         allocno_spill_priority_compare, push_allocnos_to_stack,
24649         setup_allocno_available_regs_num): Use ALLOCNO_LEFT_CONFLICTS_SIZE
24650         instead of ALLOCNO_LEFT_CONFLICTS_NUM.
24651         (setup_allocno_left_conflicts_num): Ditto.  Rename to
24652         setup_allocno_left_conflicts_size.
24653         (put_allocno_into_bucket): Use ALLOCNO_LEFT_CONFLICTS_SIZE
24654         instead of ALLOCNO_LEFT_CONFLICTS_NUM and
24655         setup_allocno_left_conflicts_size instead of
24656         setup_allocno_left_conflicts_num.
24657
24658         * ira-build.c (ira_create_allocno): Use
24659         ALLOCNO_LEFT_CONFLICTS_SIZE instead of
24660         ALLOCNO_LEFT_CONFLICTS_NUM.
24661
24662 2009-03-30  Vladimir Makarov  <vmakarov@redhat.com>
24663
24664         * reload.c (push_reload, find_dummy_reload): Use df_get_live_out
24665         instead of DF_LR_OUT.
24666
24667         * ira-lives.c (process_bb_node_lives): Ditto.
24668
24669         * ira-color.c (ira_loop_edge_freq): Use df_get_live_{out,in}
24670         instead of DF_LR_{OUT,IN}.
24671
24672         * ira-emit.c (generate_edge_moves, add_ranges_and_copies): Ditto.
24673
24674         * ira-build.c (create_bb_allocnos, create_loop_allocnos): Ditto.
24675
24676 2009-03-30  Jan Hubicka  <jh@suse.cz>
24677
24678         * except.c (label_to_region_map): Fix thinko.
24679
24680 2009-03-30  Steve Ellcey  <sje@cup.hp.com>
24681
24682         PR middle-end/38237
24683         * tree.h (tree_find_value): New declaration.
24684         * tree.c (tree_find_value): New function.
24685         * varasm.c (assemble_external): Avoid duplicate entries on lists.
24686
24687 2009-03-30  Jakub Jelinek  <jakub@redhat.com>
24688
24689         PR debug/39563
24690         * c-decl.c (struct c_binding): Add locus field.
24691         (bind): Add locus argument, set locus field from it.
24692         (pop_scope): For b->nested VAR_DECL or FUNCTION_DECL,
24693         add a DECL_EXTERNAL copy of b->decl to current BLOCK_VARS.
24694         (push_file_scope, pushtag, pushdecl, pushdecl_top_level,
24695         implicitly_declare, undeclared_variable, lookup_label,
24696         declare_label, c_make_fname_decl, c_builtin_function,
24697         c_builtin_function_ext_scope, store_parm_decls_newstyle): Adjust
24698         bind callers.
24699
24700 2009-03-30  H.J. Lu  <hongjiu.lu@intel.com>
24701
24702         PR target/38781
24703         * config/i386/i386.c (classify_argument): Check total size of
24704         structure.
24705
24706 2009-03-30  Martin Jambor  <mjambor@suse.cz>
24707
24708         * ipa-prop.h (jump_func_type): Rename IPA_UNKNOWN, IPA_CONST,
24709         IPA_CONST_MEMBER_PTR, and IPA_PASS_THROUGH to IPA_JF_UNKNOWN,
24710         IPA_JF_CONST, IPA_JF_CONST_MEMBER_PTR, and IPA_JF_PASS_THROUGH
24711         respectively.
24712
24713         * tree-dfa.c (get_ref_base_and_extent): Return -1 maxsize if
24714         seen_variable_array_ref while also traversing a union.
24715
24716         * tree-inline.c (optimize_inline_calls): Do not call
24717         cgraph_node_remove_callees.
24718         * cgraphbuild.c (remove_cgraph_callee_edges): New function.
24719         (pass_remove_cgraph_callee_edges): New variable.
24720         * passes.c (init_optimization_passes): Add
24721         pass_remove_cgraph_callee_edges after early inlining and before all
24722         late intraprocedural passes.
24723
24724         * omp-low.c (expand_omp_taskreg): Always set current_function_decl.
24725
24726 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
24727
24728         * config/sparc/sparc.md (*nand<V64mode>_vis, *nand<V32mode>_vis):
24729         Fix typos in names.
24730
24731 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
24732
24733         * combine.c (simplify_comparison): Use have_insn_for.
24734         * dojump.c (do_jump): Likewise.
24735
24736 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
24737
24738         * config/sparc/sparc.c (sparc_compare_emitted): Remove.
24739         (gen_compare_reg, emit_v9_brxx_insn): Handle MODE_CC
24740         sparc_compare_op0 like sparc_compare_emitted used to be handled.
24741         (sparc_expand_compare_and_swap_12): Set sparc_compare_op0
24742         instead of sparc_compare_emitted.
24743         * config/sparc/sparc.h (sparc_compare_emitted): Remove.
24744         * config/sparc/sparc.md (stack_protect_test): Set sparc_compare_op0
24745         instead of sparc_compare_emitted.
24746
24747 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
24748
24749         * bb-reorder.c (partition_hot_cold_basic_blocks): Do not
24750         enter/exit cfglayout mode.
24751         (pass_partition_block): Require it.
24752         * combine.c (find_single_use, reg_dead_at_p): Use CFG.
24753         (combine_instructions): Track basic blocks instead of labels.
24754         (update_cfg_for_uncondjump): New.
24755         (try_combine): Use it.  Update jumps after rescanning.
24756         (pass_combine): Require PROP_cfglayout.
24757         * passes.c (pass_outof_cfg_layout_mode): Move after regmove.
24758
24759 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
24760
24761         * cfglayout.c (pass_into_cfg_layout_mode, pass_outof_cfg_layout_mode):
24762         Provide/destroy PROP_cfglayout respectively.
24763         * gcse.c (pass_jump_bypass, pass_gcse): Require it.
24764         * tree-pass.h (PROP_cfglayout): New.
24765
24766 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
24767
24768         * fold-const.c (const_binop, fold_convert_const_real_from_fixed,
24769         fold_convert_const_fixed_from_fixed,
24770         fold_convert_const_fixed_from_int,
24771         fold_convert_const_fixed_from_real, fold_negate_const): Do not
24772         set TREE_CONSTANT_OVERFLOW.
24773         * tree.def: Remove mention of TREE_CONSTANT_OVERFLOW.
24774         * tree.h (TREE_CONSTANT_OVERFLOW): Delete.
24775
24776 2009-03-30  Ira Rosen  <irar@il.ibm.com>
24777
24778         * tree-vect-loop-manip.c: New file.
24779         * tree-vectorizer.c: Update documentation and included files.
24780         (vect_loop_location): Make extern.
24781         (rename_use_op): Move to tree-vect-loop-manip.c
24782         (rename_variables_in_bb, rename_variables_in_loop,
24783         slpeel_update_phis_for_duplicate_loop,
24784         slpeel_update_phi_nodes_for_guard1,
24785         slpeel_update_phi_nodes_for_guard2, slpeel_make_loop_iterate_ntimes,
24786         slpeel_tree_duplicate_loop_to_edge_cfg, slpeel_add_loop_guard,
24787         slpeel_can_duplicate_loop_p, slpeel_verify_cfg_after_peeling,
24788         set_prologue_iterations, slpeel_tree_peel_loop_to_edge,
24789         find_loop_location): Likewise.
24790         (new_stmt_vec_info): Move to tree-vect-stmts.c.
24791         (init_stmt_vec_info_vec, free_stmt_vec_info_vec, free_stmt_vec_info,
24792         get_vectype_for_scalar_type, vect_is_simple_use,
24793         supportable_widening_operation, supportable_narrowing_operation):
24794         Likewise.
24795         (bb_in_loop_p): Move to tree-vect-loop.c.
24796         (new_loop_vec_info, destroy_loop_vec_info,
24797         reduction_code_for_scalar_code, report_vect_op,
24798         vect_is_simple_reduction, vect_is_simple_iv_evolution): Likewise.
24799         (vect_can_force_dr_alignment_p): Move to tree-vect-data-refs.c.
24800         (vect_supportable_dr_alignment): Likewise.
24801         * tree-vectorizer.h (tree-data-ref.h): Include.
24802         (vect_loop_location): Declare.
24803         Reorganize function declarations according to the new file structure.
24804         * tree-vect-loop.c: New file.
24805         * tree-vect-analyze.c: Remove. Move functions to tree-vect-data-refs.c,
24806         tree-vect-stmts.c, tree-vect-slp.c, tree-vect-loop.c.
24807         * tree-vect-data-refs.c: New file.
24808         * tree-vect-patterns.c (timevar.h): Don't include.
24809         * tree-vect-stmts.c: New file.
24810         * tree-vect-transform.c: Remove. Move functions to tree-vect-stmts.c,
24811         tree-vect-slp.c, tree-vect-loop.c.
24812         * Makefile.in (OBJS-common): Remove tree-vect-analyze.o and
24813         tree-vect-transform.o. Add tree-vect-data-refs.o, tree-vect-stmts.o,
24814         tree-vect-loop.o, tree-vect-loop-manip.o, tree-vect-slp.o.
24815         (tree-vect-analyze.o): Remove.
24816         (tree-vect-transform.o): Likewise.
24817         (tree-vect-data-refs.o): Add rule.
24818         (tree-vect-stmts.o, tree-vect-loop.o, tree-vect-loop-manip.o,
24819         tree-vect-slp.o): Likewise.
24820         (tree-vect-patterns.o): Remove redundant dependencies.
24821         (tree-vectorizer.o): Likewise.
24822         * tree-vect-slp.c: New file.
24823
24824 2009-03-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
24825
24826         * optc-gen.awk: Warn if an option flag has multiple different
24827         help strings.
24828
24829 2009-03-30  Sebastian Pop  <sebastian.pop@amd.com>
24830
24831         * doc/invoke.texi (-floop-interchange, -floop-strip-mine,
24832         -floop-block): Document dependences on PPL, CLooG and Graphite.
24833
24834 2009-03-30  Joseph Myers  <joseph@codesourcery.com>
24835
24836         PR rtl-optimization/323
24837         * c-common.c (c_fully_fold, convert_and_check,
24838         c_common_truthvalue_conversion): Handle EXCESS_PRECISION_EXPR.
24839         (c_fully_fold_internal): Disallow EXCESS_PRECISION_EXPR.
24840         * c-common.def (EXCESS_PRECISION_EXPR): New.
24841         * c-cppbuiltin.c (builtin_define_float_constants): Define
24842         constants with enough digits for long double.
24843         * c-lex.c (interpret_float): Interpret constant with excess
24844         precision where appropriate.
24845         * c-opts.c (c_common_post_options): Set
24846         flag_excess_precision_cmdline.  Give an error for
24847         -fexcess-precision=standard for C++ for processors where the
24848         option is significant.
24849         * c-parser.c (c_parser_conditional_expression): Handle excess
24850         precision in condition.
24851         * c-typeck.c (convert_arguments): Handle arguments with excess
24852         precision.
24853         (build_unary_op): Move excess precision outside operation.
24854         (build_conditional_expr): Likewise.
24855         (build_compound_expr): Likewise.
24856         (build_c_cast): Do cast on operand of EXCESS_PRECISION_EXPR.
24857         (build_modify_expr): Handle excess precision in RHS.
24858         (convert_for_assignment): Handle excess precision in converted
24859         value.
24860         (digest_init, output_init_element, process_init_element): Handle
24861         excess precision in initializer.
24862         (c_finish_return): Handle excess precision in return value.
24863         (build_binary_op): Handle excess precision in operands and add
24864         excess precision as needed for operation.
24865         * common.opt (-fexcess-precision=): New option.
24866         * config/i386/i386.h (X87_ENABLE_ARITH, X87_ENABLE_FLOAT): New.
24867         * config/i386/i386.md (float<SSEMODEI24:mode><X87MODEF:mode>2):
24868         For standard excess precision, output explicit conversion to and
24869         truncation from XFmode.
24870         (*float<SSEMODEI24:mode><X87MODEF:mode>2_1,
24871         *float<SSEMODEI24:mode><X87MODEF:mode>2_i387_with_temp,
24872         *float<SSEMODEI24:mode><X87MODEF:mode>2_i387, two unnamed
24873         define_splits, floatdi<X87MODEF:mode>2_i387_with_xmm, two unnamed
24874         define_splits, *floatunssi<mode>2_1, two unnamed define_splits,
24875         floatunssi<mode>2, add<mode>3, sub<mode>3, mul<mode>3, divdf3,
24876         divsf3, *fop_<mode>_comm_i387, *fop_<mode>_1_i387,
24877         *fop_<MODEF:mode>_2_i387, *fop_<MODEF:mode>_3_i387,
24878         *fop_df_4_i387, *fop_df_5_i387, *fop_df_6_i387, two unnamed
24879         define_splits, sqrt<mode>2): Disable where appropriate for
24880         standard excess precision.
24881         * convert.c (convert_to_real): Do not shorten arithmetic to type
24882         for which excess precision would be used.
24883         * defaults.h (TARGET_FLT_EVAL_METHOD_NON_DEFAULT): Define.
24884         * doc/invoke.texi (-fexcess-precision=): Document option.
24885         (-mfpmath=): Correct index entry.
24886         * flags.h (enum excess_precision, flag_excess_precision_cmdline,
24887         flag_excess_precision): New.
24888         * langhooks.c (lhd_post_options): Set
24889         flag_excess_precision_cmdline.
24890         * opts.c (common_handle_option): Handle -fexcess-precision=.
24891         * toplev.c (flag_excess_precision_cmdline, flag_excess_precision,
24892         init_excess_precision): New.
24893         (lang_dependent_init_target): Call init_excess_precision.
24894         * tree.c (excess_precision_type): New.
24895         * tree.h (excess_precision_type): Declare.
24896
24897 2009-03-30  Joseph Myers  <joseph@codesourcery.com>
24898
24899         PR c/35235
24900         * c-typeck.c (build_component_ref): Do not copy qualifiers from
24901         non-lvalue to component.
24902
24903 2009-03-29  Joseph Myers  <joseph@codesourcery.com>
24904
24905         PR preprocessor/34695
24906         * Makefile.in (c-opts.o): Depend on c-tree.h.
24907         * c-common.c: Move down include of diagnostic.h.
24908         (done_lexing, c_cpp_error): New.
24909         * c-common.h (done_lexing): Declare.
24910         * c-decl.c (c_write_global_declarations): Don't check cpp_errors
24911         (parse_in).
24912         * c-opts.c: Include c-tree.h.
24913         (c_common_init_options): Set preprocessor error callback.
24914         (c_common_handle_option): Do not set preprocessor
24915         inhibit_warnings, warnings_are_errors, warn_system_headers,
24916         pedantic_errors or inhibit_warnings flags.
24917         (c_common_post_options): Do not check cpp_errors (parse_in).
24918         (c_common_finish): Do not output dependencies if there were
24919         errors.  Do not check return value of cpp_finish.
24920         * c-ppoutput.c (pp_file_change): Set input_location.
24921         * c-tree.h (c_cpp_error): Declare.
24922         * diagnostic.c (diagnostic_set_info_translated): Also initialize
24923         override_column.
24924         (diagnostic_build_prefix): Check override_column.
24925         * diagnostic.h (diagnostic_info): Add override_column field.
24926         (diagnostic_override_column): Define.
24927
24928 2009-03-28  Paolo Bonzini  <bonzini@gnu.org>
24929
24930         * c-common.c (c_expand_expr, c_staticp): Remove.
24931         * c-common.def (COMPOUND_LITERAL_EXPR): Delete.
24932         * c-common.h (emit_local_var, c_staticp, COMPOUND_LITERAL_EXPR_DECL,
24933         COMPOUND_LITERAL_EXPR_DECL_EXPR): Remove.
24934         * c-gimplify.c (gimplify_compound_literal_expr,
24935         optimize_compound_literals_in_ctor): Remove.
24936         (c_gimplify_expr): Remove COMPOUND_LITERAL_EXPR handling.
24937         * c-objc-common.h (LANG_HOOKS_STATICP): Remove.
24938         * c-semantics.c (emit_local_var): Remove.
24939
24940         * langhooks-def.h (lhd_expand_expr): Remove.
24941         * langhooks.c (lhd_expand_expr): Remove.
24942         * langhooks.h (LANG_HOOKS_DEF): Remove LANG_HOOKS_EXPAND_EXPR.
24943
24944         * expr.c (expand_expr_real_1): Move COMPOUND_LITERAL_EXPR
24945         handling from c-semantics.c; don't call into langhook.
24946         (expand_expr_addr_expr_1): Check that we don't get non-GENERIC trees.
24947         * gimplify.c (gimplify_compound_literal_expr,
24948         optimize_compound_literals_in_ctor): Move from c-gimplify.c.
24949         (gimplify_init_constructor): Call optimize_compound_literals_in_ctor.
24950         (gimplify_modify_expr_rhs, gimplify_expr): Handle COMPOUND_LITERAL_EXPR
24951         as was done in c-gimplify.c.
24952         * tree.c (staticp): Move COMPOUND_LITERAL_EXPR handling from c_staticp.
24953         * tree.h (COMPOUND_LITERAL_EXPR_DECL, COMPOUND_LITERAL_EXPR_DECL_EXPR):
24954         Move from c-common.h.
24955         * tree.def (COMPOUND_LITERAL_EXPR): Move from c-common.def.
24956
24957         * tree.c (staticp): Do not call langhook.
24958         * langhooks.c (lhd_staticp): Delete.
24959         * langhooks-def.h (lhd_staticp): Delete prototype.
24960         (LANG_HOOKS_STATICP): Delete.
24961         (LANG_HOOKS_INITIALIZER): Delete LANG_HOOKS_STATICP.
24962
24963         * doc/c-tree.texi (Expression nodes): Refer to DECL_EXPRs
24964         instead of DECL_STMTs.
24965
24966 2009-03-29  Joseph Myers  <joseph@codesourcery.com>
24967
24968         PR c/456
24969         PR c/5675
24970         PR c/19976
24971         PR c/29116
24972         PR c/31871
24973         PR c/35198
24974         * builtins.c (fold_builtin_sincos): Build COMPOUND_EXPR in
24975         void_type_node.
24976         (fold_call_expr): Return a NOP_EXPR from folding rather than the
24977         contained expression.
24978         * c-common.c (c_fully_fold, c_fully_fold_internal, c_save_expr): New.
24979         (c_common_truthvalue_conversion): Use c_save_expr.  Do not fold
24980         conditional expressions for C.
24981         (decl_constant_value_for_optimization): Move from
24982         decl_constant_value_for_broken_optimization in c-typeck.c.  Check
24983         whether optimizing and that the expression is a VAR_DECL not of
24984         array type instead of doing such checks in the caller.  Do not
24985         check pedantic.  Call gcc_unreachable for C++.
24986         * c-common.def (C_MAYBE_CONST_EXPR): New.
24987         * c-common.h (c_fully_fold, c_save_expr,
24988         decl_constant_value_for_optimization): New prototypes.
24989         (C_MAYBE_CONST_EXPR_PRE, C_MAYBE_CONST_EXPR_EXPR,
24990         C_MAYBE_CONST_EXPR_INT_OPERANDS, C_MAYBE_CONST_EXPR_NON_CONST,
24991         EXPR_INT_CONST_OPERANDS): Define.
24992         * c-convert.c (convert): Strip nops from expression.
24993         * c-decl.c (groktypename): Take extra parameters expr and
24994         expr_const_operands.  Update call to grokdeclarator.
24995         (start_decl): Update call to grokdeclarator.  Add statement for
24996         expressions used in type of decl.
24997         (grokparm): Update call to grokdeclarator.
24998         (push_parm_decl): Update call to grokdeclarator.
24999         (build_compound_literal): Add parameter non_const and build a
25000         C_MAYBE_COSNT_EXPR if applicable.
25001         (grokdeclarator): Take extra parameters expr and
25002         expr_const_operands.  Track expressions used in declaration
25003         specifiers and declarators.  Fold array sizes and track whether
25004         they are constant expressions and whether they are integer
25005         constant expressions.
25006         (parser_xref_tag): Set expr and expr_const_operands fields in
25007         return value.
25008         (grokfield): Update call to grokdeclarator.
25009         (start_function): Update call to grokdeclarator.
25010         (build_null_declspecs): Set expr and expr_const_operands fields in
25011         return value.
25012         (declspecs_add_type): Handle expressions in typeof specifiers.
25013         * c-parser.c (c_parser_declspecs): Set expr and
25014         expr_const_operands fields for declaration specifiers.
25015         (c_parser_enum_specifier): Likewise.
25016         (c_parser_struct_or_union_specifier): Likewise.
25017         (c_parser_typeof_specifier): Likewise.  Update call to
25018         groktypename.  Fold expression as needed.  Return expressions with
25019         type instead of adding statements.
25020         (c_parser_attributes): Update calls to c_parser_expr_list.
25021         (c_parser_statement_after_labels): Fold expression before passing
25022         to objc_build_throw_stmt.
25023         (c_parser_condition): Fold expression.
25024         (c_parser_asm_operands): Fold expression.
25025         (c_parser_conditional_expression): Use c_save_expr.  Update call
25026         to build_conditional_expr.
25027         (c_parser_alignof_expression): Update call to groktypename.
25028         (c_parser_postfix_expression): Preserve C_MAYBE_CONST_EXPR as
25029         original_code.  Fold expression argument of va_arg.  Create
25030         C_MAYBE_CONST_EXPR to preserve side effects of expressions in type
25031         argument to va_arg.  Update calls to groktypename.  Fold array
25032         index for offsetof.  Verify that first argument to
25033         __builtin_choose_expr has integer type.
25034         (c_parser_postfix_expression_after_paren_type): Update calls to
25035         groktypename and build_compound_literal.  Handle expressions with
25036         side effects in type name.
25037         (c_parser_postfix_expression_after_primary): Update call to
25038         c_parser_expr_list.  Set original_code for calls to
25039         __builtin_constant_p.
25040         (c_parser_expr_list): Take extra parameter fold_p.  Fold
25041         expressions if requested.
25042         (c_parser_objc_type_name): Update call to groktypename.
25043         (c_parser_objc_synchronized_statement): Fold expression.
25044         (c_parser_objc_receiver): Fold expression.
25045         (c_parser_objc_keywordexpr): Update call to c_parser_expr_list.
25046         (c_parser_omp_clause_num_threads, c_parser_omp_clause_schedule,
25047         c_parser_omp_atomic, c_parser_omp_for_loop): Fold expressions.
25048         * c-tree.h (CONSTRUCTOR_NON_CONST): Define.
25049         (struct c_typespec): Add elements expr and expr_const_operands.
25050         (struct c_declspecs): Add elements expr and expr_const_operands.
25051         (groktypename, build_conditional_expr, build_compound_literal):
25052         Update prototypes.
25053         (in_late_binary_op): Declare.
25054         * c-typeck.c (note_integer_operands): New function.
25055         (in_late_binary_op): New variable.
25056         (decl_constant_value_for_broken_optimization): Move to c-common.c
25057         and rename to decl_constant_value_for_optimization.
25058         (default_function_array_conversion): Do not strip nops.
25059         (default_conversion): Do not call
25060         decl_constant_value_for_broken_optimization.
25061         (build_array_ref): Do not fold result.
25062         (c_expr_sizeof_expr): Fold operand.  Use C_MAYBE_CONST_EXPR for
25063         result when operand is a VLA.
25064         (c_expr_sizeof_type): Update call to groktypename.  Handle
25065         expressions included in type name.  Use C_MAYBE_CONST_EXPR for
25066         result when operand names a VLA type.
25067         (build_function_call): Update call to build_compound_literal.
25068         Only fold result for calls to __builtin_* functions.  Strip
25069         NOP_EXPR from INTEGER_CST returned from such functions.  Fold
25070         the function designator.
25071         (convert_arguments): Fold arguments.  Update call to
25072         convert_for_assignment.
25073         (build_unary_op): Handle increment and decrement of
25074         C_MAYBE_CONST_EXPR.  Move lvalue checks for increment and
25075         decrement earlier.  Fold operand of increment and decrement.
25076         Handle address of C_MAYBE_CONST_EXPR.  Only fold expression being
25077         built for integer operand.  Wrap returns that are INTEGER_CSTs
25078         without being integer constant expressions or that have integer
25079         constant operands without being INTEGER_CSTs.
25080         (lvalue_p): Handle C_MAYBE_CONST_EXPR.
25081         (build_conditional_expr): Add operand ifexp_bcp.  Track whether
25082         result is an integer constant expression or can be used in
25083         unevaluated parts of one and avoid folding and wrap as
25084         appropriate.  Fold operands before possibly doing -Wsign-compare
25085         warnings.
25086         (build_compound_expr): Wrap result for C99 if operands can be used
25087         in integer constant expressions.
25088         (build_c_cast): Update call to digest_init.  Do not ignore
25089         overflow from casting floating-point constants to integers.  Wrap
25090         results that could be confused with integer constant expressions,
25091         null pointer constants or floating-point constants.
25092         (c_cast_expr): Update call to groktypename.  Handle expressions
25093         included in type name.
25094         (build_modify_expr): Handle modifying a C_MAYBE_CONST_EXPR.  Fold
25095         lhs inside possible SAVE_EXPR.  Fold RHS before assignment.
25096         Update calls to convert_for_assignment.
25097         (convert_for_assignment): Take new parameter
25098         null_pointer_constant.  Do not strip nops or call
25099         decl_constant_value_for_broken_optimization.  Set
25100         in_late_binary_op for conversions to boolean.
25101         (store_init_value): Update call to digest_init.
25102         (digest_init): Take new parameter null_pointer_constant.  Do not
25103         call decl_constant_value_for_broken_optimization.  pedwarn for
25104         initializers not constant expressions.  Update calls to
25105         convert_for_assignment.
25106         (constructor_nonconst): New.
25107         (struct constructor_stack): Add nonconst element.
25108         (really_start_incremental_init, push_init_level, pop_init_level):
25109         Handle constructor_nonconst and nonconst element.
25110         (set_init_index): Call constant_expression_warning for array
25111         designators.
25112         (output_init_element): Fold value.  Set constructor_nonconst as
25113         applicable.  pedwarn for initializers not constant expressions.
25114         Update call to digest_init.  Call constant_expression_warning
25115         where constant initializers are required.
25116         (process_init_element): Use c_save_expr.
25117         (c_finish_goto_ptr): Fold expression.
25118         (c_finish_return): Fold return value.  Update call to
25119         convert_for_assignment.
25120         (c_start_case): Fold switch expression.
25121         (c_process_expr_stmt): Fold expression.
25122         (c_finish_stmt_expr): Create C_MAYBE_CONST_EXPR as needed to
25123         ensure statement expression is not evaluated in constant expression.
25124         (build_binary_op): Track whether results are integer constant
25125         expressions or may occur in such, disable folding and wrap results
25126         as applicable.  Fold operands for -Wsign-compare warnings unless
25127         in_late_binary_op.
25128         (c_objc_common_truthvalue_conversion): Handle results folded to
25129         integer constants that are not integer constant expressions.
25130         * doc/extend.texi: Document when typeof operands are evaluated,
25131         that condition of __builtin_choose_expr is an integer constant
25132         expression, and more about use of __builtin_constant_p in
25133         initializers.
25134
25135 2009-03-29  Richard Guenther  <rguenther@suse.de>
25136
25137         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Properly
25138         propagate addresses of array references.
25139
25140 2009-03-29  Steven Bosscher  <steven@gcc.gnu.org>
25141
25142         * regmove.c (perhaps_ends_bb_p): Remove.
25143         (optimize_reg_copy_1): Don't call perhaps_ends_bb_p.  Get basic block
25144         from INSN and check that the main loop stays within that basic block.
25145         (optimize_reg_copy_1, optimize_reg_copy_3, fixup_match_2): Likewise.
25146         (regmove_forward_pass): Split out from regmove_optimize.  Use
25147         FOR_EACH_BB and FOR_BB_INSNS instead of traversing the insns stream.
25148         (regmove_backward_pass): Split out from regmove_optimize.  Use
25149         FOR_EACH_BB_REVERSE and FOR_BB_INSNS_REVERS_SAFE.
25150         (regmove_optimize): Simplify.
25151
25152 2009-03-29  H.J. Lu  <hongjiu.lu@intel.com>
25153
25154         PR target/39545
25155         * config/i386/i386.c (classify_argument): Ignore flexible array
25156         member in struct and warn ABI change.
25157
25158 2009-03-29  H.J. Lu  <hongjiu.lu@intel.com>
25159
25160         * config/i386/i386-protos.h (ix86_agi_dependent): New.
25161
25162         * config/i386/i386.c (ix86_agi_dependent): Rewrite.
25163         (ix86_adjust_cost): Updated.
25164
25165 2009-03-29  Jan Hubicka  <jh@suse.cz>
25166
25167         PR middle-end/28850
25168         * tree-pass.h (pass_cleanup_eh): New function.
25169         (remove_unreachable_regions): Break code handling RTL
25170         to rtl_remove_unreachable_regions; remove ERT_MUST_NOT_THROW
25171         that can not be reached by runtime.
25172         (can_be_reached_by_runtime): New function.
25173         (label_to_region_map): New function.
25174         (num_eh_regions): New function.
25175         (rtl_remove_unreachable_regions): New function.
25176         (convert_from_eh_region_ranges): Call rtl_remove_unreachable_regions.
25177         (remove_eh_region): New function.
25178         * except.h: Include sbitmap and vecprim.
25179         (remove_eh_region, remove_unreachable_regions, label_to_region_map,
25180         num_eh_regions): Declare.
25181         * passes.c (init_optimization_passes): Schedule cleanup_eh.
25182         * Makefile.in (EXCEPT_H): New; replace all uses of except.h by it.
25183         * tree-eh.c (tree_remove_unreachable_handlers): New function.
25184         (tree_empty_eh_handler_p): New function.
25185         (cleanup_empty_eh): New function.
25186         (cleanup_eh): New function.
25187         (pass_cleanup_eh): New function.
25188
25189 2009-03-29  Jan Hubicka  <jh@suse.cz>
25190
25191         * except.c (verify_eh_tree): Fix handling of fun!=cfun; be ready
25192         for removed regions.
25193
25194 2009-03-29  Jan Hubicka  <jh@suse.cz>
25195
25196         * except.c (dump_eh_tree): Dump all datastructures.
25197
25198 2009-03-29  Jan Hubicka  <jh@suse.cz>
25199
25200         * except.c (duplicate_eh_regions_0): Handle AKA bitmap.
25201         (duplicate_eh_regions_1): Likewise.
25202         (duplicate_eh_regions): Likewise; cleanup code gorwing the region
25203         vector; call EH verification.
25204         (foreach_reachable_handler, can_throw_internal_1, can_throw_external_1):
25205         Be ready for region being removed.
25206
25207 2009-03-29  Jan Hubicka  <jh@suse.cz>
25208
25209         * bitmap.c (bitmap_last_set_bit): New function.
25210         * bitmap.h (bitmap_last_set_bit): Declare.
25211
25212 2009-03-29  David Ayers  <ayers@fsfe.org>
25213
25214         PR objc/27377
25215         * c-typeck.c (build_conditional_expr): Emit ObjC warnings
25216         by calling objc_compare_types and surpress warnings about
25217         incompatible C pointers that are compatible ObjC pointers.
25218
25219 2009-03-29  Adam Nemet  <anemet@caviumnetworks.com>
25220
25221         * cgraphbuild.c (build_cgraph_edges, rebuild_cgraph_edges): Don't
25222         call initialize_inline_failed.
25223         (initialize_inline_failed): Move it from here ...
25224         * cgraph.c (initialize_inline_failed): ... to here.
25225         (cgraph_create_edge): Call initialize_inline_failed rather than
25226         setting inline_failed directly.
25227
25228 2009-03-29  Ben Elliston  <bje@au.ibm.com>
25229
25230         PR target/32542
25231         * sysv4.opt (msdata): Improve comment.
25232         * linux64.h (ASM_SPEC32): Do not pass -memb when -msdata is given.
25233         * sysv4.h (SVR4_ASM_SPEC): Likewise.
25234
25235 2009-03-29  Ben Elliston  <bje@au.ibm.com>
25236
25237         PR target/30451
25238         * config/rs6000/rs6000.md (*movti_ppc64): Correct the order of
25239         load and store attributes.
25240
25241 2009-03-29  Ben Elliston  <bje@au.ibm.com>
25242
25243         * config/i386/i386.c (enum ix86_builtins): Add IX86_BUILTIN_HUGE_VALQ.
25244         (ix86_init_builtins): Add built-in function __builtin_huge_valq.
25245         (ix86_expand_builtin): Handle IX86_BUILTIN_HUGE_VALQ.
25246         * doc/extend.texi (X86 Built-in Functions): Add index entries for
25247         __builtin_infq and __builtin_huge_valq.
25248
25249 2009-03-28  Anatoly Sokolov  <aesok@post.ru>
25250
25251         * config/avr/avr.c (avr_mcu_t): Add atmega8c1, atmega16c1 and
25252         atmega8m1 devices.
25253         * config/avr/avr.h (LINK_SPEC, CRT_BINUTILS_SPECS): (Ditto.).
25254         * config/avr/t-avr (MULTILIB_MATCHES): (Ditto.)
25255
25256 2009-03-28  Xinliang David Li  <davidxl@google.com>
25257
25258         * tree-ssa-ccp.c (ccp_finalize): Add dbg_count support.
25259         (do_dbg_cnt): New function.
25260
25261 2009-03-28  Jan Hubicka  <jh@suse.cz>
25262
25263         Merge from pretty-ipa:
25264
25265         2009-03-27  Jan Hubicka  <jh@suse.cz>
25266
25267         * cgraph.c (dump_cgraph_node): Add replace output flag by process.
25268         * tree-pass.h (function_called_by_processed_nodes_p): Declare.
25269         * passes.c (function_called_by_processed_nodes_p): New.
25270         * ipa-pure-const.c (check_call): Fix handling of operands.
25271         (analyze_function): Dump debug output for skipped bodies.
25272         (local_pure_const): Use function_called_by_processed_nodes_p.
25273         * dwarf2out.c (reference_to_unused): Use output.
25274         * passes.c (do_per_function_toporder): Likewise.
25275
25276         2008-11-12  Jan Hubicka  <jh@suse.cz>
25277
25278         * tree-pass.h (pass_fixup_cfg, pass_local_pure_const): Declare.
25279         * ipa-pure-const.c (funct_state_d): Add can throw field; make
25280         state_set_in_source enum
25281         (check_decl): Ignore memory tags; do not set fake looping flags;
25282         dump diagnostics.
25283         (check_operand, check_tree, check_rhs_var, check_lhs_var,
25284         get_asm_expr_operands, scan_function_op, scan_function_stmt): Remove.
25285         (check_call, analyze_function): Rewrite.
25286         (check_stmt): New.
25287         (add_new_function): Update call of analyze_function.
25288         (generate_summary): Add call of analyze_function.
25289         (propagate): Propagate can_throw; handle state_set_in_source correctly.
25290         (local_pure_const): New function.
25291         (pass_local_pure_const): New pass.
25292         * ipa-inline.c (inline_transform): Set after_inlining.
25293         * tree-eh.c (stmt_can_throw_external): New.
25294         * tree-optimize.c (execute_fixup_cfg): Do not set after_inlining;
25295         work with aliasing built.
25296         * tree-flow.h (stmt_can_throw_external): New.
25297         * passes.c (init_optimization_passes): Schedule fixup_cfg pass early;
25298         and local pure/const pass in early and late optimization queue.
25299
25300 2009-03-28  Martin Jambor  <mjambor@suse.cz>
25301
25302         * fold-const.c (get_pointer_modulus_and_residue): New parameter
25303         allow_func_align.
25304         (fold_binary): Allow function decl aligment consideration is the
25305         second argument is integer constant one.
25306         * tree-ssa-forwprop.c (simplify_bitwise_and): New function.
25307         (tree_ssa_forward_propagate_single_use_vars): Handle assing statements
25308         with BIT_AND_EXPR on the RHS by calling simplify_bitwise_and.
25309
25310 2009-03-28  Jan Hubicka  <jh@suse.cz>
25311
25312         * dwarf2out.c (dwarf2out_begin_prologue): Use crtl->nothrow
25313         * tree-eh.c (stmt_could_throw_p): Remove check for WEAK decls.
25314         * function.h (rtl_data): Add nothrow flag.
25315         * except.c (set_nothrow_function_flags): Use crtl->nothrow;
25316         set DECL_NOTHROW for AVAILABLE functions.
25317
25318 2009-03-28  Jakub Jelinek  <jakub@redhat.com>
25319
25320         * config/rs6000/rs6000-c.c (rs6000_macro_to_expand): If macro
25321         following vector keyword has expansion starting with pixel or bool
25322         keyword, expand vector to __vector and pixel or bool to __pixel or
25323         __bool.
25324
25325         PR c++/39554
25326         * opts.c (warning_disallowed_functions, warn_disallowed_functions,
25327         warn_if_disallowed_function_p): Removed.
25328         (common_handle_option): Don't handle OPT_Wdisallowed_function_list_.
25329         * c-parser.c (c_parser_postfix_expression_after_primary): Don't call
25330         warning_if_disallowed_function_p.
25331         * flags.h (warn_if_disallowed_function_p,
25332         warn_disallowed_functions): Removed.
25333         * common.opt (Wdisallowed-function-list=): Removed.
25334         * doc/invoke.texi (-Wdisallowed-function-list=): Removed.
25335
25336 2009-03-28  Richard Guenther  <rguenther@suse.de>
25337
25338         PR tree-optimization/38723
25339         * tree-ssa-pre.c (compute_avail): Add all default definitions to
25340         the entry block.
25341
25342 2009-03-28  Jan Hubicka  <jh@suse.cz>
25343
25344         * tree-ssa-structalias.c (ipa_pta_execute): Fix bogus node->analyzed
25345         test introduced by my previous patch.
25346
25347 2009-03-28  Richard Guenther  <rguenther@suse.de>
25348
25349         * tree-ssa-copy.c (copy_prop_visit_phi_node): Do not leave
25350         the PHIs value undefined.
25351
25352 2009-03-28  Jan Hubicka  <jh@suse.cz>
25353
25354         * tree-pass.h (pass_fixup_cfg): New pass.
25355         * ipa-inline.c (inline_transform): Set
25356         always_inline_functions_inlined/after_inlining.
25357         * tree-optimize.c (execute_fixup_cfg): Do not set them here.
25358         (pass_fixup_cfg): New pass.
25359         * passes.c (init_optimization_passes): Add fixup_cfg.
25360
25361 2009-03-28  Richard Guenther  <rguenther@suse.de>
25362
25363         PR tree-optimization/38458
25364         * tree-ssa-copy.c (copy_prop_visit_phi_node): For the first
25365         argument use the arguments copy-of value.
25366
25367 2009-03-28  Richard Guenther  <rguenther@suse.de>
25368
25369         PR tree-optimization/38180
25370         * tree-ssa-ccp.c (get_default_value): Simplify.
25371         (likely_value): Likewise.
25372         (surely_varying_stmt_p): Properly handle VOP case.
25373         (ccp_initialize): Likewise.
25374         (ccp_fold): Handle propagating through *&.
25375         (fold_const_aggregate_ref): Also handle decls.
25376
25377 2009-03-28  Jan Hubicka  <jh@suse.cz>
25378
25379         * cgraph.c (dump_cgraph_node): Add replace output flag by process.
25380         * cgraph.h (cgraph_node): Likewise.
25381         * cgraphunit.c (cgraph_process_new_functions): Set process flag.
25382         (cgraph_reset_node): Use process flag.
25383         (cgraph_mark_functions_to_output): Likewise.
25384         (cgraph_expand_function): Likewise.
25385         (cgraph_expand_all_functions): Likewise.
25386         (cgraph_output_in_order): Likewise.
25387         * dwarf2out.c (reference_to_unused): Likewise.
25388         * passes.c do_per_function_toporder): Likewise.
25389
25390 2009-03-28  Jan Hubicka  <jh@suse.cz>
25391
25392         Bring from lto-branch:
25393
25394         2008-09-03  Doug Kwan  <dougkwan@google.com>
25395
25396         * cgraphbuild.c (initialize_inline_failed): Use cgraph_inline_failed_t
25397         enums instead of reason strings.
25398         * cgraph.c (cgraph_create_edge): Same.
25399         (cgraph_inline_failed_string): New function.
25400         * cgraph.h (cgraph_inline_failed_t): New enum type.
25401         (cgraph_inline_failed_string): New prototype.
25402         (struct cgraph_edge): Change type of INLINED_FAILED from constant
25403         char pointer to cgraph_inline_failed_t.
25404         (cgraph_inline_p): Adjust prototype to use cgraph_inline_failed_t.
25405         (cgraph_default_inline_p): Ditto.
25406         * cgraphunit.c (cgraph_inline_p): Change type of parameter REASON
25407         to cgraph_inline_failed_t pointer.
25408         * cif-code.def: New file.
25409         * ipa-inline.c (cgraph_mark_inline_edge): Use an enum instead of a
25410         reason string.
25411         (cgraph_check_inline_limits): Change type of REASON to pointer to
25412         cgraph_inline_failed_t.  Replace reason strings with enums.
25413         (cgraph_default_inline_p): Ditto.
25414         (cgraph_recursive_inlining_p): Ditto.
25415         (update_caller_keys): Change type of FAILED_REASON to
25416         cgraph_inline_failed_t.
25417         (cgraph_set_inline_failed): Change type of REASON to pointer to
25418         cgraph_inline_failed_t.  Call cgraph_inline_failed_string to
25419         convert enums to strings for text output.
25420         (cgraph_decide_inlining_of_small_function): Change FAILED_REASON
25421         to be of type cgraph_inline_failed_t.  Replace reason strings with
25422         enums.  Call cgraph_inline_failed_string to covert enums
25423         to strings for text output.
25424         (cgraph_decide_inlining): Replace reason strings with enums.
25425         (cgraph_decide_inlining_incrementally): Change type of FAILED_REASON
25426         to cgraph_inline_failed_t type.  Call cgraph_inline_failed_string
25427         for text output.
25428         * tree-inline.c (expand_call_inline): Change type of REASON
25429         to cgraph_inline_failed_t.  Replace reason strings with enums.
25430         Call cgraph_inline_failed_string for text output.
25431         * Makefile.in (CGRAPH_H): Add cif-code.def to dependencies.
25432         (cgraph.o): Ditto.
25433
25434 2009-03-28  Jan Hubicka  <jh@suse.cz>
25435
25436         * cgraph.c (cgraph_node, cgraph_remove_node, dump_cgraph_node,
25437         cgraph_clone_node): Remove master clone handling.
25438         (cgraph_is_master_clone, cgraph_master_clone): Remove.
25439         * cgraph.h (master_clone): Remove.
25440         (cgraph_is_master_clone, cgraph_master_clone): Remove.
25441         * ipa-type-escape.c (type_escape_execute): Remove use of master clone.
25442         (tree-ssa-structalias.c (ipa_pta_execute): Likewise.
25443
25444 2009-03-28  Jan Hubicka  <jh@suse.cz>
25445
25446         * cgraph.c (cgraph_function_body_availability): Functions declared
25447         inline are always safe to assume that it is not going to be replaced.
25448
25449 2009-03-28  Richard Guenther  <rguenther@suse.de>
25450
25451         PR tree-optimization/38513
25452         * tree-ssa-pre.c (eliminate): Remove redundant stores.
25453         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Handle
25454         EXC_PTR_EXPR and FILTER_EXPR.
25455         (get_ref_from_reference_ops): Likewise.
25456
25457 2009-03-28  Richard Guenther  <rguenther@suse.de>
25458
25459         PR tree-optimization/38968
25460         * tree-vect-analyze.c (vect_compute_data_ref_alignment):
25461         Use FLOOR_MOD_EXPR to compute misalignment.
25462
25463 2009-03-28  Richard Guenther  <rguenther@suse.de>
25464
25465         PR tree-optimization/37795
25466         * tree.h (combine_comparisons): Declare.
25467         * fold-const.c (combine_comparisons): Export.
25468         * tree-ssa-ifcombine.c (ifcombine_ifandif): Optimize two successive
25469         comparisons.
25470         (ifcombine_iforif): Use combine_comparisons.
25471
25472 2009-03-28  Jan Hubicka  <jh@suse.cz>
25473
25474         * tree-eh.c (inlinable_call_p): New function.
25475         (make_eh_edges): Use it.
25476         (verify_eh_edges): Use it.
25477         (stmt_can_throw_external, stmt_can_throw_internal): Use it.
25478         * except.c (reachable_next_level): Add inlinable_function argument
25479         (sjlj_find_directly_reachable_regions): Update.
25480         (add_reachable_handler): Do not set saw_any_handlers.
25481         (reachable_next_level): Handle MUST_NOT_THROW more curefully.
25482         (foreach_reachable_handler, can_throw_internal_1, can_throw_external_1):
25483         Add new inlinable call parameter.
25484         (can_throw_internal, can_throw_external): Update.
25485         * except.h (can_throw_internal_1, can_throw_external_1,
25486         foreach_reachable_handler): Update declaration.
25487
25488 2009-03-28  Joseph Myers  <joseph@codesourcery.com>
25489
25490         * config/arm/t-arm-coff, config/h8300/coff.h,
25491         config/i386/i386-aout.h, config/i386/i386-coff.h,
25492         config/libgloss.h, config/m68k/coff.h, config/m68k/m68k-aout.h,
25493         config/pdp11/2bsd.h, config/rs6000/aix41.h,
25494         config/rs6000/aix41.opt, config/rs6000/t-newas, config/sh/coff.h,
25495         fix-header.c, fixproto, gen-protos.c, protoize.c, scan-decls.c,
25496         scan-types.sh, scan.c, scan.h, sort-protos, sys-protos.h,
25497         sys-types.h: Remove.
25498         * Makefile.in: Remove protoize and fixproto support and references
25499         in comments.
25500         (SYSCALLS.c.X-warn, TARGET_GETGROUPS_T, STMP_FIXPROTO,
25501         PROTOIZE_INSTALL_NAME, UNPROTOIZE_INSTALL_NAME, FIXPROTO_DEFINES):
25502         Remove.
25503         (ALL_HOST_OBJS): Remove $(PROTO_OBJS).
25504         (MOSTLYCLEANFILES): Remove protoize$(exeext) and
25505         unprotoize$(exeext).
25506         (rest.encap): Don't depend on $(STMP_FIXPROTO)
25507         (.PHONY): Don't depend on proto.
25508         (libgcc-support): Don't depend on $(STMP_FIXPROTO).
25509         (proto, PROTO_OBJS, protoize$(exeext), unprotoize$(exeext),
25510         protoize.o, unprotoize.o, SYSCALLS.c.X, test-protoize-simple,
25511         deduced.h, GEN_PROTOS_OBJS, build/gen-protos$(build_exeext),
25512         build/gen-protos.o, build/scan.o, xsys-protos.h,
25513         build/fix-header$(build_exeext), build/fix-header.o,
25514         build/scan-decls.o, fixhdr.ready, stmp-fixproto,
25515         stmp-install-fixproto): Remove.
25516         (mostlyclean): Don't remove xsys-protos.hT, SYSCALLS.c.X,
25517         SYSCALLS.c or fixproto files.
25518         (install-common): Don't install protoize.
25519         (install-headers-tar, install-headers-cpio, install-headers-cp):
25520         Don't depend on $(STMP_FIXPROTO).
25521         (install-mkheaders): Don't depend on $(STMP_FIXPROTO).  Don't
25522         install fixproto files or write out fixproto settings.
25523         (uninstall): Don't uninstall protoize.
25524         * config.gcc (use_fixproto): Remove.
25525         (arm-*-coff*, armel-*-coff*, h8300-*-*, i[34567]86-*-aout*,
25526         i[34567]86-*-coff*, m68k-*-aout*, m68k-*-coff*, pdp11-*-bsd,
25527         rs6000-ibm-aix4.[12]*, powerpc-ibm-aix4.[12]*, sh-*-*): Remove.
25528         * config/m32r/t-linux (STMP_FIXPROTO): Remove.
25529         * config/m68k/m68k.c: Remove M68K_TARGET_COFF-conditional code.
25530         * config/mips/t-iris (FIXPROTO_DEFINES): Remove.
25531         * config/pa/t-pa-hpux (FIXPROTO_DEFINES): Remove.
25532         * config/pdp11/pdp11.c: Remove TWO_BSD-conditional code.
25533         * config/t-svr4 (FIXPROTO_DEFINES): Remove.
25534         * config/t-vxworks (STMP_FIXPROTO): Remove.
25535         * configure.ac (AC_TYPE_GETGROUPS, TARGET_GETGROUPS_T,
25536         STMP_FIXPROTO): Remove.
25537         * config.in, configure: Regenerate.
25538         * crtstuff.c (gid_t, uid_t): Don't undefine.
25539         * doc/install.texi: Change m68k-coff to m68k-elf in example.
25540         (arm-*-coff, arm-*-aout: Remove target entries.
25541         (*-ibm-aix*): Mention removal of support for AIX 4.2 and older.
25542         Remove mention of AIX 4.1.
25543         (m68k-*-*): Remove mention of m68k-*-aout and m68k-*-coff*.
25544         * doc/invoke.texi (Running Protoize): Remove.
25545         * doc/trouble.texi (Actual Bugs): Remove mention of fixproto.
25546         (Protoize Caveats): Remove.
25547         * tsystem.h: Update comments on headers assumed to exist.
25548
25549 2009-03-27  Vladimir Makarov  <vmakarov@redhat.com>
25550
25551         * genautomata.c: Add a new year to the copyright.  Add a new
25552         reference.
25553         (struct insn_reserv_decl): Add comments for member bypass_list.
25554         (find_bypass): Remove.
25555         (insert_bypass): New.
25556         (process_decls): Use insert_bypass.
25557         (output_internal_insn_latency_func): Output all bypasses with the
25558         same input insn in one switch case.
25559
25560         * rtl.def (define_bypass): Describe bypass choice.
25561         * doc/md.texi (define_bypass): Ditto.
25562
25563 2009-03-27  Richard Guenther  <rguenther@suse.de>
25564
25565         * gimplify.c (mark_addressable): Export.
25566         * tree-flow.h (mark_addressable): Declare.
25567         * tree-ssa-loop-manip.c (create_iv): Mark the base addressable.
25568         * tree-ssa.c (verify_phi_args): Verify that address taken
25569         variables have TREE_ADDRESSABLE set.
25570
25571 2009-03-27  Richard Guenther  <rguenther@suse.de>
25572
25573         * fold-const.c (build_fold_addr_expr_with_type_1): Rename back to ...
25574         (build_fold_addr_expr_with_type): ... this.  Remove in_fold handling.
25575         Do not mark decls TREE_ADDRESSABLE.
25576         (build_fold_addr_expr): Adjust.
25577         (fold_addr_expr): Remove.
25578         (fold_unary): Use build_fold_addr_expr.
25579         (fold_comparison): Likewise.
25580         (split_address_to_core_and_offset): Likewise.
25581         * coverage.c (tree_coverage_counter_addr): Mark the array decl
25582         TREE_ADDRESSABLE.
25583         * gimplify.c (mark_addressable): Do not exclude RESULT_DECLs.
25584         (gimplify_modify_expr_to_memcpy): Mark source and destination
25585         addressable.
25586         * omp-low.c (create_omp_child_function): Mark the object decl
25587         TREE_ADDRESSABLE.
25588         (lower_rec_input_clauses): Mark the var we take the address of
25589         TREE_ADDRESSABLE.
25590         (lower_omp_taskreg): Mark the sender decl TREE_ADDRESSABLE.
25591
25592 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
25593
25594         PR middle-end/39315
25595         * cfgexpand.c (expand_one_stack_var_at): Change alignment
25596         limit to MAX_SUPPORTED_STACK_ALIGNMENT.
25597
25598 2009-03-27  Richard Guenther  <rguenther@suse.de>
25599
25600         PR tree-optimization/39120
25601         * tree-ssa-structalias.c (handle_rhs_call): Fill out return
25602         constraints.
25603         (handle_lhs_call): Process return constraints.  Add escape
25604         constraints if necessary.
25605         (handle_const_call): Fill out return constraints.  Make nested
25606         case more precise.  Avoid consttmp if possible.
25607         (handle_pure_call): Fill out return constraints.  Avoid
25608         callused if possible.
25609         (find_func_aliases): Simplify call handling.
25610
25611 2009-03-27  Richard Guenther  <rguenther@suse.de>
25612
25613         PR tree-optimization/39120
25614         * tree-ssa-structalias.c (do_sd_constraint): Do not use CALLUSED
25615         as a representative.
25616         (solve_graph): Do propagate CALLUSED.
25617         (handle_pure_call): Use a scalar constraint from CALLUSED for
25618         the return value.
25619         (find_what_p_points_to): CALLUSED shall not appear in poins-to
25620         solutions.
25621
25622 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
25623
25624         PR c/39323
25625         * c-common.c (handle_aligned_attribute): Properly check alignment
25626         overflow.  Use (1U << i) instead of (1 << i).
25627
25628         * emit-rtl.c (get_mem_align_offset): Use "unsigned int" for align.
25629
25630         * expr.h (get_mem_align_offset): Updated.
25631
25632         * tree.h (tree_decl_common): Change align to "unsigned int" and
25633         move it before pointer_alias_set.
25634
25635 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
25636             Jakub Jelinek  <jakub@redhat.com>
25637
25638         PR target/38034
25639         * config/ia64/sync.md (cmpxchg_rel_<mode>): Replace input
25640         gr_register_operand with gr_reg_or_0_operand.
25641         (cmpxchg_rel_di): Likewise.
25642         (sync_lock_test_and_set<mode>): Likewise.
25643
25644 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
25645
25646         * jump.c (rtx_renumbered_equal_p): Use subreg_get_info.
25647         (true_regnum): Likewise.
25648
25649         * rtlanal.c (subreg_info): Moved to ...
25650         * rtl.h (subreg_info): Here.  New.
25651         (subreg_get_info): New.
25652
25653         * rtlanal.c (subreg_get_info): Make it extern.
25654
25655 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
25656
25657         PR target/39472
25658         * config/i386/i386.c (ix86_abi): New.
25659         (override_options): Handle -mabi=.
25660         (ix86_function_arg_regno_p): Replace DEFAULT_ABI with ix86_abi.
25661         (ix86_call_abi_override): Likewise.
25662         (init_cumulative_args): Likewise.
25663         (function_arg_advance): Likewise.
25664         (function_arg_64): Likewise.
25665         (function_arg): Likewise.
25666         (ix86_pass_by_reference): Likewise.
25667         (ix86_function_value_regno_p): Likewise.
25668         (ix86_build_builtin_va_list_abi): Likewise.
25669         (setup_incoming_varargs_64): Likewise.
25670         (is_va_list_char_pointer): Likewise.
25671         (ix86_init_machine_status): Likewise.
25672         (ix86_reg_parm_stack_space): Use enum calling_abi on call_abi.
25673         (ix86_function_type_abi): Return enum calling_abi.  Rewrite
25674         for 64bit.  Replace DEFAULT_ABI with ix86_abi.
25675         (ix86_function_abi): Make it static and return enum calling_abi.
25676         (ix86_cfun_abi): Return enum calling_abi.  Replace DEFAULT_ABI
25677         with ix86_abi.
25678         (ix86_fn_abi_va_list): Updated.
25679
25680         * config/i386/i386.h (ix86_abi): New.
25681         (STACK_BOUNDARY): Replace DEFAULT_ABI with ix86_abi.
25682         (CONDITIONAL_REGISTER_USAGE): Likewise.
25683         (CUMULATIVE_ARGS): Change call_abi type to enum calling_abi.
25684         (machine_function): Likewise.
25685
25686         * config/i386/i386.md (untyped_call): Replace DEFAULT_ABI
25687         with ix86_abi.
25688         * config/i386/cygming.h (TARGET_64BIT_MS_ABI): Likewise.
25689         (STACK_BOUNDARY): Likewise.
25690         * config/i386/mingw32.h (EXTRA_OS_CPP_BUILTINS): Likewise.
25691
25692         * config/i386/i386.opt (mabi=): New.
25693
25694         * config/i386/i386-protos.h (ix86_cfun_abi): Changed to
25695         return enum calling_abi.
25696         (ix86_function_type_abi): Likewise.
25697         (ix86_function_abi): Removed.
25698
25699         * doc/invoke.texi: Document -mabi= option for x86.
25700
25701 2009-03-27  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
25702
25703         * builtins.c (real_dconstp): Delete.
25704         (fold_builtin_logarithm): Remove inaccurate log(e) special case.
25705
25706 2009-03-27  Dodji Seketeli  <dodji@redhat.com>
25707             Jakub Jelinek  <jakub@redhat.com>
25708
25709         PR debug/37959
25710         * dwarf2out.c (dwarf_attr_name): Handle DW_AT_explicit attribute.
25711         (gen_subprogram_die): When a function is explicit, generate the
25712         DW_AT_explicit attribute.
25713         * langhooks.h (struct lang_hooks_for_decls): Add
25714         function_decl_explicit_p langhook.
25715         * langhooks-def.h (LANG_HOOKS_FUNCTION_DECL_EXPLICIT_P): Define.
25716         (LANG_HOOKS_DECLS): Add LANG_HOOKS_FUNCTION_DECL_EXPLICIT_P.
25717
25718 2009-03-27  Jakub Jelinek  <jakub@redhat.com>
25719
25720         * builtins.c (fold_builtin_memory_op): Optimize memmove
25721         into memcpy if we can prove source and destination don't overlap.
25722
25723         * tree-inline.c: Include gt-tree-inline.h.
25724         (clone_fn_id_num): New variable.
25725         (clone_function_name): New function.
25726         (tree_function_versioning): Use it.
25727         * Makefile.in (GTFILES): Add tree-inline.c.
25728
25729 2009-03-27  Mark Mitchell  <mark@codesourcery.com>
25730
25731         * BASE-VER: Change to 4.5.0.
25732
25733 2009-03-27  Xinliang David Li  <davidxl@google.com>
25734
25735         PR tree-optimization/39557
25736         * tree-ssa.c (warn_uninitialized_vars): free postdom info.
25737
25738 2009-03-27  Xinliang David Li  <davidxl@google.com>
25739
25740         PR tree-optimization/39548
25741         * tree-ssa-copy.c (copy_prop_visit_phi_node): Add copy
25742         candidate check.
25743
25744 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
25745
25746         * c-common.c (pointer_int_sum): Use %wd on return from
25747         tree_low_cst.
25748
25749 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
25750
25751         * c-common.c (pointer_int_sum): Use HOST_WIDE_INT_PRINT_DEC
25752         on return from tree_low_cst.
25753
25754 2009-03-27  Andrew Pinski  <andrew_pinski@playstation.sony.com>
25755
25756         PR c++/36799
25757         * ginclude/stdarg.h (va_copy): Define also for
25758         __GXX_EXPERIMENTAL_CXX0X__.
25759
25760 2009-03-27  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
25761
25762         PR c++/35652
25763         * builtins.h (c_strlen): Do not warn here.
25764         * c-typeck.c (build_binary_op): Adjust calls to pointer_int_sum.
25765         * c-common.c (pointer_int_sum): Take an explicit location.
25766         Warn about offsets out of bounds.
25767         * c-common.h (pointer_int_sum): Adjust declaration.
25768
25769 2009-03-26  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25770
25771         * doc/invoke.texi (i386 and x86-64 Windows Options): Fix texinfo
25772         markup glitch.
25773
25774 2009-03-26  Jakub Jelinek  <jakub@redhat.com>
25775
25776         PR c++/39554
25777         * opts.c (warn_if_disallowed_function_p): Don't assume
25778         get_callee_fndecl must return non-NULL.
25779
25780 2009-03-26  Vladimir Makarov  <vmakarov@redhat.com>
25781
25782         PR rtl-optimization/39522
25783         * reload1.c (reload_as_needed): Invalidate reg_last_reload_reg too
25784         when reg_reloaded_valid is set.
25785
25786 2009-03-26  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
25787
25788         * config/spu/divv2df3.c: New file.
25789         * config/spu/t-spu-elf (LIB2FUNCS_STATIC_EXTRA): Add it.
25790         (DPBIT_FUNCS): Filter out _div_df.
25791
25792 2009-03-26  Bernd Schmidt  <bernd.schmidt@analog.com>
25793
25794         * config/bfin/bfin.c (bfin_optimize_loop): If the LSETUP goes before
25795         a jump insn, count that jump in the distance to the loop start.
25796
25797 2009-03-25  Kaz Kojima  <kkojima@gcc.gnu.org>
25798
25799         PR target/39523
25800         * config/sh/sh.c (calc_live_regs): Fix condition for global
25801         registers except PIC_OFFSET_TABLE_REGNUM.
25802
25803 2009-03-25  Kai Tietz  <kai.tietz@onevision.com>
25804
25805         PR/39518
25806         * doc/invoke.texi (-mconsole): New.
25807         (-mcygwin): New.
25808         (-mno-cygwin): New.
25809         (-mdll): New.
25810         (-mnop-fun-dllimport): New.
25811         (-mthread): New.
25812         (-mwin32): New.
25813         (-mwindows): New.
25814         (sub section "i386 and x86-64 Windows Options"): New.
25815
25816 2009-03-25  Ralf Corsépius  <ralf.corsepius@rtems.org>
25817
25818         * config/arm/rtems-elf.h: Remove LINK_GCC_C_SEQUENCE_SPEC.
25819         * config/rs6000/t-rtems: Remove MULTILIB_EXTRA_OPTS.
25820
25821 2009-03-25  Richard Guenther  <rguenther@suse.de>
25822
25823         PR middle-end/39497
25824         * Makefile.in (dfp.o-warn): Use -fno-strict-aliasing instead
25825         of -Wno-error.
25826
25827 2009-03-25  Andrey Belevantsev  <abel@ispras.ru>
25828
25829         * config/ia64/ia64.c (ia64_set_sched_flags): Zero spec_info->mask when
25830         neither of haifa/selective schedulers are working.
25831
25832 2009-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25833
25834         * doc/invoke.texi (Debugging Options): Fix description of
25835         -fno-merge-debug-strings.
25836
25837 2009-03-24  Hans-Peter Nilsson  <hp@axis.com>
25838
25839         * config/cris/libgcc.ver: New version-script.
25840         * config/cris/t-linux (SHLIB_MAPFILES): Use it.
25841
25842         * configure.ac <GAS features, nop mnemonic>: Add pattern
25843         crisv32-*-* for "nop".
25844         <GAS features, Thread-local storage>: Add item for CRIS and CRIS v32.
25845         * configure: Regenerate.
25846
25847 2009-03-24  Ira Rosen  <irar@il.ibm.com>
25848
25849         PR tree-optimization/39529
25850         * tree-vect-transform.c (vect_create_data_ref_ptr): Call
25851         mark_sym_for_renaming for the tag copied to the new vector
25852         pointer.
25853
25854 2009-03-24  Arthur Loiret  <aloiret@debian.org>
25855
25856         * config.host (alpha*-*-linux*): Use driver-alpha.o and alpha/x-alpha.
25857         * config/alpha/linux.h (host_detect_local_cpu): Declare, add to
25858         EXTRA_SPEC_FUNCTIONS.
25859         (MCPU_MTUNE_NATIVE_SPECS, DRIVER_SELF_SPECS): New macros.
25860         * config/alpha/driver-alpha.c, config/alpha/x-alpha: New.
25861         * doc/invoke.texi (DEC Alpha Options): Document 'native' value for
25862         -march and -mtune options.
25863
25864 2009-03-24  Ralf Corsépius  <ralf.corsepius@rtems.org>
25865
25866         * config/m68k/t-rtems: Add m5329 multilib.
25867
25868 2009-03-24  Dodji Seketeli  <dodji@redhat.com>
25869             Jakub Jelinek  <jakub@redhat.com>
25870
25871         PR debug/39524
25872         * dwarf2out.c (gen_variable_die): Avoid adding duplicate declaration
25873         nodes.
25874
25875 2009-03-23  Jakub Jelinek  <jakub@redhat.com>
25876
25877         PR c/39495
25878         * c-parser.c (c_parser_omp_for_loop): Call c_parser_binary_expression
25879         instead of c_parser_expression_conv, if original_code isn't one of the
25880         4 allowed comparison codes, fail.
25881
25882 2009-03-23  Richard Guenther  <rguenther@suse.de>
25883
25884         * cgraph.h (struct cgraph_node): Reorder fields for 64-bit hosts.
25885         * tree.h (struct tree_type): Likewise.
25886         * reload.h (struct insn_chain): Likewise.
25887         * dwarf2out.c (struct dw_loc_descr_struct): Likewise.
25888         * function.h (struct function): Likewise.
25889         * tree-ssa-structalias.c (struct equiv_class_label): Likewise.
25890
25891 2009-03-23  Jakub Jelinek  <jakub@redhat.com>
25892
25893         PR tree-optimization/39516
25894         * lambda-code.c (perfect_nestify): Fix type of the uboundvar variable.
25895
25896 2009-03-23  Bingfeng Mei  <bmei@broadcom.com>
25897
25898         * config.gcc (need_64bit_hwint): Make clear that need_64bit_hwint
25899         should be set true if BITS_PER_WORD of target is bigger than 32
25900
25901 2009-03-22  Hans-Peter Nilsson  <hp@axis.com>
25902
25903         * config/cris/linux.h (CRIS_LINK_SUBTARGET_SPEC):
25904         Translate -B-options to -rpath-link.  Correct existing
25905         rpath-link and conditionalize on !nostdlib.
25906
25907 2009-03-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25908
25909         * doc/extend.texi (Function Attributes, Variable Attributes):
25910         Fix typos.
25911         * doc/invoke.texi (Debugging Options, Optimize Options)
25912         (i386 and x86-64 Options, MCore Options): Likewise.
25913
25914 2009-03-20  Jakub Jelinek  <jakub@redhat.com>
25915
25916         PR debug/37890
25917         * dwarf2out.c (gen_namespace_die): Add context_die argument and use
25918         it for block local namespace aliases.
25919         (gen_decl_die): Pass context_die to gen_namespace_die.
25920
25921 2009-03-19  Jakub Jelinek  <jakub@redhat.com>
25922
25923         PR c/39495
25924         * c-omp.c (c_finish_omp_for): Allow NE_EXPR with TREE_TYPE (decl)'s
25925         minimum or maximum value.
25926
25927 2009-03-19  Alexandre Oliva  <aoliva@redhat.com>
25928
25929         * reginfo.c (globalize_reg): Recompute derived reg sets.
25930
25931 2009-03-19  Ozkan Sezer  <sezeroz@gmail.com>
25932
25933         PR target/39063
25934         * libgcc2.c (mprotect): Do not use signed arguments for
25935         VirtualProtect, use DWORD arguments.  Also fix the 'may
25936         be used uninitialized' warning for the np variable.
25937
25938 2009-03-19  Jakub Jelinek  <jakub@redhat.com>
25939
25940         PR target/39496
25941         * config/i386/i386.c (ix86_function_regparm): Don't optimize local
25942         functions using regparm calling conventions when not optimizing.
25943         (ix86_function_sseregparm): Similarly for sseregparm calling
25944         conventions.
25945
25946 2009-03-19  Li Feng  <nemokingdom@gmail.com>
25947
25948         PR middle-end/39500
25949         * tree-data-ref.c (analyze_subscript_affine_affine): There is no
25950         dependence if the first conflict is after niter iterations.
25951
25952 2009-03-19  Hans-Peter Nilsson  <hp@axis.com>
25953
25954         PR middle-end/38609
25955         * config/cris/cris.h (FRAME_POINTER_REQUIRED): Force for all
25956         functions with dynamic stack-pointer adjustments.
25957
25958 2009-03-19  Ben Elliston  <bje@au.ibm.com>
25959
25960         * doc/invoke.texi (RS/6000 and PowerPC Options): Fix -msdata-data
25961         option; change to -msdata=data.
25962
25963 2009-03-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25964
25965         * c.opt: Unify help texts for -Wdeprecated, -Wsystem-headers,
25966         and -fopenmp.
25967
25968 2009-03-18  Eric Botcazou  <ebotcazou@adacore.com>
25969
25970         PR target/35180
25971         * config/sparc/sparc.md (do_builtin_setjmp_setup): Prettify asm output.
25972
25973 2009-03-18  Sandra Loosemore  <sandra@codesourcery.com>
25974
25975         * doc/invoke.texi (Code Gen Options): Expand discussion of
25976         -fno-common.
25977
25978 2009-03-18  Jakub Jelinek  <jakub@redhat.com>
25979
25980         * dse.c (struct group_info): Reorder fields for 64-bit hosts.
25981         * matrix-reorg.c (struct matrix_info): Likewise.
25982         * tree-ssa-loop-ivopts.c (struct ivopts_data): Likewise.
25983         * rtl.h (struct mem_attrs): Likewise.
25984         * df.h (struct df): Likewise.
25985         * tree-data-ref.h (struct data_dependence_relation): Likewise.
25986         * ira-int.h (struct ira_allocno): Likewise.
25987         * df-scan.c (struct df_collection_rec): Likewise.
25988         * ira.c (struct equivalence): Likewise.
25989         * function.c (struct temp_slot): Likewise.
25990         * cfgloop.h (struct loop): Likewise.
25991
25992         PR debug/39485
25993         * function.c (use_register_for_decl): When not optimizing, disregard
25994         register keyword for variables with types containing methods.
25995
25996 2009-03-18  Sebastian Pop  <sebastian.pop@amd.com>
25997
25998         PR middle-end/39447
25999         * graphite.c (exclude_component_ref): Renamed contains_component_ref_p.
26000         (is_simple_operand): Call contains_component_ref_p before calling data
26001         reference analysis that would fail on COMPONENT_REFs.
26002
26003         * tree-vrp.c (search_for_addr_array): Fix formatting.
26004
26005 2009-03-18  Richard Guenther  <rguenther@suse.de>
26006
26007         * tree-vect-transform.c (vect_loop_versioning): Fold the
26008         generated comparisons.
26009         * tree-vectorizer.c (set_prologue_iterations): Likewise.
26010         (slpeel_tree_peel_loop_to_edge): Likewise.
26011
26012 2009-03-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
26013
26014         PR middle-end/37805
26015         * opts.c (print_specific_help): In addition to `undocumented',
26016         accept `separate' and `joined' flags if passed alone.  Describe
26017         output by the first matched one of those.
26018         (common_handle_option): Skip over empty strings.
26019         * gcc.c (display_help): Fix help string for `--help='.
26020         * doc/invoke.texi (Option Summary, Overall Options): With
26021         `--help=', classes and qualifiers can both be repeated, but
26022         only the latter can be negated.  One should not pass only
26023         negated qualifiers.  Fix markup and examples.
26024
26025         Revert
26026         2008-10-14  Jakub Jelinek  <jakub@redhat.com>
26027         PR middle-end/37805
26028         * opts.c (common_handle_option): Don't ICE on -fhelp=joined
26029         and -fhelp=separate.
26030
26031 2009-03-17  Jing Yu  <jingyu@google.com>
26032
26033         PR middle-end/39378
26034         * function.h (struct rtl_data): Move is_thunk from here...
26035         (struct function): ...to here.
26036         * cp/method.c (use_thunk): Change is_thunk from crtl to cfun.
26037         * varasm.c (assemble_start_function): Change is_thunk from crtl to
26038         cfun.
26039         * config/alpha/alpha.c (alpha_sa_mask): Change is_thunk from crtl to
26040         cfun.
26041         (alpha_does_function_need_gp, alpha_start_function): Likewise.
26042         (alpha_output_function_end_prologue): Likewise.
26043         (alpha_end_function, alpha_output_mi_thunk_osf): Likewise.
26044         * config/rs6000/rs6000.c (rs6000_ra_ever_killed): Likewise.
26045         (rs6000_output_function_epilogue): Likewise.
26046         * config/arm/arm.h (ARM_DECLARE_FUNCTION_NAME): Likewise.
26047
26048 2009-03-17  Uros Bizjak  <ubizjak@gmail.com>
26049
26050         PR target/39482
26051         * config/i386/i386.md (*truncdfsf_mixed): Avoid combining registers
26052         from different units in a single alternative.
26053         (*truncdfsf_i387): Ditto.
26054         (*truncxfsf2_mixed): Ditto.
26055         (*truncxfdf2_mixed): Ditto.
26056
26057 2009-03-17  Jakub Jelinek  <jakub@redhat.com>
26058
26059         * dwarf2out.c (dwarf2out_imported_module_or_decl_1): Allow
26060         non-NAMESPACE_DECL IMPORTED_DECL_ASSOCIATED_DECL.
26061
26062         PR debug/39474
26063         * tree-ssa-live.c (remove_unused_locals): Don't remove local
26064         unused non-artificial variables when not optimizing.
26065
26066         PR debug/39471
26067         * dwarf2out.c (dwarf2out_imported_module_or_decl_1): Emit
26068         DW_TAG_imported_module even if decl is IMPORTED_DECL with
26069         NAMESPACE_DECL in its DECL_INITIAL.
26070
26071         PR middle-end/39443
26072         * optabs.c (set_user_assembler_libfunc): New function.
26073         * expr.h (set_user_assembler_libfunc): New prototype.
26074         * c-common.c: Include libfuncs.h.
26075         (set_builtin_user_assembler_name): Call set_user_assembler_libfunc
26076         for memcmp, memset, memcpy, memmove and abort.
26077         * Makefile.in (c-common.o): Depend on libfuncs.h.
26078
26079         PR debug/39412
26080         * dwarf2out.c (gen_inlined_enumeration_type_die,
26081         gen_inlined_structure_type_die, gen_inlined_union_type_die,
26082         gen_tagged_type_instantiation_die): Removed.
26083         (gen_decl_die): For TYPE_DECL_IS_STUB with non-NULL decl_origin
26084         do nothing.
26085
26086 2009-03-17  Janis Johnson  <janis187@us.ibm.com>
26087
26088         PR testsuite/38526
26089         * Makefile.in (site.exp): Rename TEST_GCC_EXEC_PREFIX and comment
26090         its use.
26091         (check-%): Don't set GCC_EXEC_PREFIX when invoking runtest.
26092         (check-parallel-%): Ditto.
26093         (check-consistency): Ditto.
26094
26095 2009-03-17  Kai Tietz  <kai.tietz@onevision.com>
26096
26097         * ipa-struct-reorg.c (create_general_new_stmt): Initialize
26098         local variable rhs by NULL_TREE.
26099
26100 2009-03-17  H.J. Lu  <hongjiu.lu@intel.com>
26101
26102         PR target/39477
26103         * doc/extend.texi: Correct register behavior for regparm on Intel 386.
26104
26105 2009-03-17  H.J. Lu  <hongjiu.lu@intel.com>
26106
26107         PR target/39476
26108         * config/i386/i386.c (ix86_function_regparm): Rewrite for 64bit.
26109
26110 2009-03-17  H.J. Lu  <hongjiu.lu@intel.com>
26111
26112         PR target/39473
26113         * config/i386/i386.c (ix86_expand_call): Check extra clobbers
26114         for ms->sysv ABI calls only in 64bit mode.
26115
26116         * config/i386/i386.md (untyped_call): Support 32bit.
26117
26118 2009-03-16  H.J. Lu  <hongjiu.lu@intel.com>
26119
26120         * doc/extend.texi: Replace x86_65 with x86_64.
26121
26122 2009-03-16  Jakub Jelinek  <jakub@redhat.com>
26123
26124         PR tree-optimization/39455
26125         * tree-ssa-loop-niter.c (number_of_iterations_lt_to_ne): Fix types
26126         mismatches for POINTER_TYPE_P (type).
26127         (number_of_iterations_le): Likewise.
26128
26129 2009-03-16  Hariharan Sandanagobalane  <hariharan@picochip.com>
26130
26131         * config/picochip/picochip.c: Removed profiling support.
26132         * config/picochip/picochip.md: Removed profiling instruction.
26133         * config/picochip/picochip.h: Removed profiling builtin.
26134
26135 2009-03-16  Joseph Myers  <joseph@codesourcery.com>
26136
26137         * doc/install.texi (--with-host-libstdcxx): Document.
26138
26139 2009-03-14  Anatoly Sokolov  <aesok@post.ru>
26140
26141         PR target/34299
26142         * config/avr/avr.c (avr_handle_fndecl_attribute): Move code for
26143         generate a warning if the function name does not begin with
26144         "__vector" and the function has either the 'signal' or 'interrupt'
26145         attribute, from here to ...
26146         (avr_declare_function_name): ...here. New function.
26147         * config/avr/avr.h (ASM_DECLARE_FUNCTION_NAME): Redefine.
26148         * config/avr/avr-protos.h (avr_declare_function_name): Declare.
26149
26150 2009-03-14  Jakub Jelinek  <jakub@redhat.com>
26151
26152         PR bootstrap/39454
26153         * cse.c (fold_rtx): Don't modify original const_arg1 when
26154         canonicalizing SHIFT_COUNT_TRUNCATED shift count, do it on a
26155         separate variable instead.
26156         * rtlanal.c (nonzero_bits1) <case ASHIFTRT>: Don't assume anything
26157         from out of range shift counts.
26158         (num_sign_bit_copies1) <case ASHIFTRT, case ASHIFT>: Similarly.
26159
26160 2009-03-13  Catherine Moore  <clm@codesourcery.com>
26161
26162         * config/i386/x-mingw32 (host-mingw32.o): Replace
26163         diagnostic.h with $(DIAGNOSTIC_H).
26164
26165 2009-03-12  Jakub Jelinek  <jakub@redhat.com>
26166
26167         PR target/39431
26168         * config/i386/predicates.md (cmpxchg8b_pic_memory_operand): New
26169         predicate.
26170         * config/i386/sync.md (sync_compare_and_swap<mode>,
26171         sync_compare_and_swap_cc<mode>): For DImode with -m32 -fpic check
26172         if operands[1] is cmpxchg8b_pic_memory_operand, if not force address
26173         into a register.
26174         (sync_double_compare_and_swapdi_pic,
26175         sync_double_compare_and_swap_ccdi_pic): Require operand 1 to be
26176         cmpxchg8b_pic_memory_operand instead of just memory_operand.
26177
26178 2009-03-12  H.J. Lu  <hongjiu.lu@intel.com>
26179
26180         PR target/39445
26181         * config/i386/i386.c (ix86_expand_push): Don't set memory alignment.
26182
26183 2009-03-12  H.J. Lu  <hongjiu.lu@intel.com>
26184
26185         PR target/39327
26186         * config/i386/sse.md (avx_addsubv8sf3): Correct item bits.
26187         (avx_addsubv4df3): Likewise.
26188         (*avx_addsubv4sf3): Likewise.
26189         (sse3_addsubv4sf3): Likewise.
26190
26191 2009-03-12  H.J. Lu  <hongjiu.lu@intel.com>
26192
26193         PR target/38824
26194         * config/i386/i386.md: Compare REGNO on the new peephole2 patterns.
26195
26196 2009-03-12  Vladimir Makarov  <vmakarov@redhat.com>
26197
26198         PR debug/39432
26199         * ira-int.h (struct allocno): Fix comment for calls_crossed_num.
26200         * ira-conflicts.c (ira_build_conflicts): Prohibit call used
26201         registers for allocnos created from user-defined variables.
26202
26203 2009-03-11  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
26204
26205         PR target/39181
26206         * config/spu/spu.c (spu_expand_mov): Handle invalid subregs
26207         of non-integer mode as well.
26208
26209 2009-03-11  Adam Nemet  <anemet@caviumnetworks.com>
26210
26211         * gimplify.c (gimplify_call_expr): Don't set CALL_CANNOT_INLINE_P
26212         for functions for which the parameter types are unknown.
26213
26214 2009-03-11  Jakub Jelinek  <jakub@redhat.com>
26215
26216         PR target/39137
26217         * cfgexpand.c (get_decl_align_unit): Use LOCAL_DECL_ALIGNMENT macro.
26218         * defaults.h (LOCAL_DECL_ALIGNMENT): Define if not yet defined.
26219         * config/i386/i386.h (LOCAL_DECL_ALIGNMENT): Define.
26220         * config/i386/i386.c (ix86_local_alignment): For
26221         -m32 -mpreferred-stack-boundary=2 use 32-bit alignment for
26222         long long variables on the stack to avoid dynamic realignment.
26223         Allow the first argument to be a decl rather than type.
26224         * doc/tm.texi (LOCAL_DECL_ALIGNMENT): Document.
26225
26226 2009-03-11  Nick Clifton  <nickc@redhat.com>
26227
26228         PR target/5362
26229         * config/mcore/mcore.opt: Remove deprecated m4align and m8align
26230         options.
26231         Add description to mno-lsim option.
26232         * config/mcore/mcore.h: Remove comment about deprecated m4align
26233         option.
26234         (TARGET_DEFAULT): Remove deprecated MASK_M8ALIGN.
26235         * doc/invoke.texi: Add description of mno-lsim and
26236         mstack-increment options.
26237
26238         * config/fr30/fr30.opt: Document the -mno-lsim option.
26239         * doc/invoke.texi: Add descriptions of the FR30's -msmall-model
26240         and -mno-lsim options.
26241
26242 2009-03-11  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
26243
26244         * fold-const.c (fold_comparison): Only call fold_inf_compare
26245         if the mode supports infinities.
26246
26247 2009-03-11  Jason Merrill  <jason@redhat.com>
26248
26249         PR debug/39086
26250         * tree-nrv.c (tree_nrv): Don't do this optimization if the front
26251         end already did.  Notice GIMPLE_CALL modifications of the result.
26252         Don't copy debug information from an ignored decl or a decl from
26253         another function.
26254
26255 2009-03-10  Richard Guenther  <rguenther@suse.de>
26256             Nathan Froyd  <froydnj@codesourcery.com>
26257
26258         PR middle-end/37850
26259         * libgcc2.c (__mulMODE3): Use explicit assignments to form the result.
26260         (__divMODE3): Likewise.
26261
26262 2009-03-09  Jakub Jelinek  <jakub@redhat.com>
26263
26264         PR tree-optimization/39394
26265         * gimplify.c (gimplify_type_sizes): Gimplify DECL_SIZE and
26266         DECL_SIZE_UNIT of variable length FIELD_DECLs.
26267
26268 2009-03-09  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
26269
26270         * recog.c (verfiy_changes): Disallow renaming of hard regs in
26271         inline asms for register asm ("") declarations.
26272
26273 2009-03-09  Eric Botcazou  <ebotcazou@adacore.com>
26274
26275         * fold-const.c (fold_unary): Fix comment.
26276
26277 2009-03-07  Jan Hubicka  <jh@suse.cz>
26278
26279         PR target/39361
26280         * tree-inline.c (setup_one_parameter): Do replacement of const
26281         argument by constant in SSA form.
26282
26283 2009-03-07  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
26284
26285         PR middle-end/38028
26286         * function.c (assign_parm_setup_stack): Use STACK_SLOT_ALIGNMENT to
26287         determine alignment passed to assign_stack_local.
26288         (assign_parms_unsplit_complex): Likewise.
26289         * except.c (sjlj_build_landing_pads): Likewise.
26290
26291 2009-03-06  Jakub Jelinek  <jakub@redhat.com>
26292
26293         PR middle-end/39360
26294         * tree-flow.h (add_referenced_var): Return bool instead of void.
26295         * tree-dfa.c (add_referenced_var): Return result of
26296         referenced_var_check_and_insert call.
26297         * tree-inline.c (expand_call_inline): Call add_referenced_var instead
26298         of referenced_var_check_and_insert.
26299
26300         PR debug/39372
26301         * dwarf2out.c (add_abstract_origin_attribute): Return origin_die.
26302         (gen_variable_die): Emit DW_AT_location on abstract static variable's
26303         DIE, don't emit it if abstract origin already has it.
26304         * tree-cfg.c (remove_useless_stmts_bind): GIMPLE_BINDs with any
26305         BLOCK_NONLOCALIZED_VARS in its gimple_bind_block aren't useless.
26306
26307 2009-03-06  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
26308
26309         * genpreds.c (needs_variable): Fix parentheses at variable name
26310         detection.
26311         (write_tm_constrs_h): Indent generated code.
26312
26313 2009-03-06  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
26314
26315         * doc/extend.texi (Function Attributes): Add documentation
26316         for isr attributes.
26317
26318 2009-03-06  Jakub Jelinek  <jakub@redhat.com>
26319
26320         PR debug/39387
26321         * dwarf2out.c (dwarf2out_imported_module_or_decl_1): For IMPORTED_DECL
26322         take locus from its DECL_SOURCE_LOCATION instead of input_location.
26323
26324 2009-03-05  Bernd Schmidt  <bernd.schmidt@analog.com>
26325
26326         * config/bfin/bfin.c (bfin_discover_loop): When retrying fails, mark
26327         the loop as bad.
26328
26329 2009-03-05  Jakub Jelinek  <jakub@redhat.com>
26330
26331         PR debug/39379
26332         * tree-cfg.c (remove_useless_stmts_bind): Don't remove GIMPLE_BINDs
26333         with blocks containing IMPORTED_DECLs in BLOCK_VARS.
26334
26335 2009-03-05  Uros Bizjak  <ubizjak@gmail.com>
26336
26337         * config/i386/i386.md (R8_REG, R9_REG): New constants.
26338         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Use named
26339         constants instead of magic numbers.
26340         (HARD_REGNO_CALLER_SAVE_MODE): Ditto.
26341         (QI_REG_P): Ditto.
26342         * config/i386/i386.c (x86_64_int_parameter_registers): Ditto.
26343         (x86_64_ms_abi_int_parameter_registers): Ditto.
26344         (x86_64_int_return_registers): Ditto.
26345         (ix86_maybe_switch_abi): Ditto.
26346         (ix86_expand_call): Ditto for clobbered_registers array.
26347         (ix86_hard_regno_mode_ok): Ditto.
26348         (x86_extended_QIreg_mentioned_p): Ditto.
26349
26350 2009-03-05  J"orn Rennecke  <joern.rennecke@arc.com>
26351
26352         PR tree-optimization/39349
26353         * cse.c (cse_insn): Fix loop to stop at VOIDmode.
26354
26355         * combine.c (gen_lowpart_for_combine): Use omode when generating
26356         clobber.
26357
26358 2009-03-04  J"orn Rennecke  <joern.rennecke@arc.com>
26359
26360         PR rtl-optimization/39235
26361         * loop-iv.c (get_simple_loop_desc): Use XCNEW.
26362
26363 2009-03-04  Zdenek Dvorak  <ook@ucw.cz>
26364
26365         * graphite.c (nb_reductions_in_loop): Update simple_iv arguments.
26366
26367 2009-03-04  Richard Guenther  <rguenther@suse.de>
26368
26369         PR tree-optimization/39362
26370         * tree-ssa-sccvn.c (visit_use): Stores and copies from SSA_NAMEs
26371         that occur in abnormal PHIs should be varying.
26372
26373 2009-03-04  Zdenek Dvorak  <ook@ucw.cz>
26374
26375         * tree-scalar-evolution.c (analyze_scalar_evolution_in_loop):
26376         Extend comments.
26377         (simple_iv):  Take loop as an argument instead of statement.
26378         * tree-scalar-evolution.h (simple_iv): Declaration changed.
26379         * tree-ssa-loop-niter.c (number_of_iterations_exit): Update calls
26380         to simple_iv.
26381         * tree-ssa-loop-ivopts.c (determine_biv_step, find_givs_in_stmt_scev):
26382         Ditto.
26383         * tree-parloops.c (loop_parallel_p, canonicalize_loop_ivs): Ditto.
26384         * matrix-reorg.c (analyze_transpose): Ditto.
26385         * tree-data-ref.c (dr_analyze_innermost): Ditto.
26386         * tree-vect-analyze.c (vect_analyze_data_refs): Ditto.
26387         * tree-predcom.c (ref_at_iteration): Ditto.
26388         * tree-ssa-loop-prefetch.c (idx_analyze_ref): Ditto.
26389
26390 2009-03-04  Richard Guenther  <rguenther@suse.de>
26391
26392         PR tree-optimization/39358
26393         * tree-ssa-structalias.c (do_sd_constraint): Fix check for
26394         escaped_id and callused_id.
26395         (solve_graph): Likewise.
26396
26397 2009-03-04  Richard Guenther  <rguenther@suse.de>
26398
26399         PR tree-optimization/39339
26400         * tree-sra.c (try_instantiate_multiple_fields): Make it
26401         no longer ICE on the above.
26402
26403 2009-03-03  Joseph Myers  <joseph@codesourcery.com>
26404
26405         * emit-rtl.c (adjust_address_1): Reduce offset to a signed value
26406         that fits within Pmode.
26407
26408 2009-03-03  Steve Ellcey  <sje@cup.hp.com>
26409
26410         PR middle-end/10109
26411         * tm.texi (LIBCALL_VALUE): Update description.
26412
26413 2009-03-03  Steve Ellcey  <sje@cup.hp.com>
26414
26415         PR middle-end/34443
26416         * doc/extend.texi (section): Update description.
26417
26418 2009-03-03  H.J. Lu  <hongjiu.lu@intel.com>
26419
26420         PR middle-end/39345
26421         * tree-inline.c (remapped_type): New.
26422         (can_be_nonlocal): Call remapped_type instead of remap_type.
26423
26424 2009-03-03  Jakub Jelinek  <jakub@redhat.com>
26425
26426         PR fortran/39354
26427         * gimplify.c (goa_stabilize_expr): Handle tcc_comparison,
26428         TRUTH_ANDIF_EXPR and TRUTH_ORIF_EXPR.
26429
26430 2009-03-03  Richard Guenther  <rguenther@suse.de>
26431
26432         PR middle-end/39272
26433         * tree.c (tree_nonartificial_location): New function.
26434         * tree.h (tree_nonartificial_location): Declare.
26435         * builtins.c (expand_builtin_memory_chk): Provide location
26436         of the call location for artificial function pieces.
26437         (maybe_emit_chk_warning): Likewise.
26438         (maybe_emit_sprintf_chk_warning): Likewise.
26439         (maybe_emit_free_warning): Likewise.
26440         * expr.c (expand_expr_real_1): Likewise.
26441
26442 2009-03-03  Jakub Jelinek  <jakub@redhat.com>
26443
26444         PR tree-optimization/39343
26445         * tree-ssa-ccp.c (maybe_fold_offset_to_address): Don't check if
26446         COMPONENT_REF t has ARRAY_TYPE.
26447
26448 2009-03-02  Sebastian Pop  <sebastian.pop@amd.com>
26449
26450         PR middle-end/39335
26451         * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
26452         when the type precision of the induction variable should be
26453         larger than the type precision of nit.
26454         (gen_parallel_loop): Update use of canonicalize_loop_ivs.
26455         * graphite.c (graphite_loop_normal_form): Same.
26456         * tree-flow.h (canonicalize_loop_ivs): Update declaration.
26457
26458 2009-03-02  Uros Bizjak  <ubizjak@gmail.com>
26459
26460         * config/i386/i386.md (ST?_REG, MM?_REG): New constants.
26461         (*call_1_rex64_ms_sysv): Use named constants instead of magic
26462         numbers to describe clobbered registers.
26463         (*call_value_0_rex64_ms_sysv): Ditto.
26464         * config/i386/mmx.md (mmx_emms): Ditto.
26465         (mmx_femms): Ditto.
26466
26467 2009-03-02  Richard Sandiford  <rdsandiford@googlemail.com>
26468
26469         * config/mips/mips.c (mips_mdebug_abi_name): Fix the handling
26470         of ABI_64.
26471
26472 2009-03-02  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
26473
26474         * config/spu/spu.c (TARGET_SECTION_TYPE_FLAGS): Define.
26475         (spu_section_type_flags): New function.
26476
26477 2009-03-02  Uros Bizjak  <ubizjak@gmail.com>
26478
26479         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Do not copy
26480         reg_class_contents of FLOAT_REGS into a temporary.
26481
26482 2009-03-02  Richard Guenther  <rguenther@suse.de>
26483             Ira Rosen  <irar@il.ibm.com>
26484
26485         PR tree-optimization/39318
26486         * tree-vect-transform.c (vectorizable_call): Transfer the EH region
26487         information to the vectorized statement.
26488
26489 2009-03-01  Uros Bizjak  <ubizjak@gmail.com>
26490
26491         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Do not shadow "i"
26492         variable.  Use defined names instead of magic constants for REX SSE
26493         registers.
26494
26495 2009-03-01  Richard Guenther  <rguenther@suse.de>
26496
26497         PR tree-optimization/39331
26498         * omp-low.c (lower_send_shared_vars): Do not receive new
26499         values for the reference of DECL_BY_REFERENCE parms or results.
26500
26501 2009-03-01  Jan Hubicka  <jh@suse.cz>
26502
26503         PR debug/39267
26504         * tree.h (BLOCK_NONLOCALIZED_VARS, BLOCK_NUM_NONLOCALIZED_VARS,
26505         BLOCK_NONLOCALIZED_VAR): New macros.
26506         (tree_block): Add nonlocalized_vars.
26507         * dwarf2out.c (gen_formal_parameter_die, gen_variable_die,
26508         gen_decl_die): Add origin argument.  Allow generation of die with
26509         origin at hand only.
26510         (gen_member_die, gen_type_die_with_usage, force_decl_die,
26511         declare_in_namespace, gen_namescpace_die, dwarf2out_decl): Update use
26512         of gen_*.
26513         (gen_block_die): Fix checking for unused blocks.
26514         (process_scope_var): Break out from .... ; work with origins only.
26515         (decls_for_scope) ... here; process nonlocalized list.
26516         (dwarf2out_ignore_block): Look for nonlocalized vars.
26517         * tree-ssa-live.c (remove_unused_scope_block_p): Look for nonlocalized
26518         vars.
26519         (dump_scope_block): Dump them.
26520         * tree-inline.c (remap_decls): Handle nonlocalized vars.
26521         (remap_block): Likewise.
26522         (can_be_nonlocal): New predicate.
26523         (copy_bind_expr, copy_gimple_bind): Update use of remap_block.
26524
26525 2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
26526
26527         * configure: Regenerate.
26528
26529 2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
26530
26531         * optc-gen.awk: No need to duplicate option flags twice.
26532         Reuse help texts for duplicate options which do not have any.
26533
26534         * gcc.c (display_help): Document --version.
26535
26536         * gcc.c (main): If print_help_list and verbose_flag, ensure
26537         driver output comes before subprocess output.
26538
26539         * optc-gen.awk: Assign all remaining fields to help string,
26540         space-separated, for multi-line help in *.opt.
26541
26542         * doc/invoke.texi (Warning Options): -Wsync-nand is C/C++ only.
26543         -Wno-pedantic-ms-format is for MinGW targets only.
26544
26545         * doc/options.texi (Option file format): Fix bad indentation,
26546         restoring dropped sentence.
26547
26548 2009-02-28  Jan Hubicka  <jh@suse.cz>
26549
26550         * tree-inline.c (tree_function_versioning): Output debug info.
26551
26552 2009-02-28  Jan Hubicka  <jh@suse.cz>
26553
26554         PR debug/39267
26555         * tree-inline.c (setup_one_parameter): Do not copy propagate
26556         arguments when not optimizing.
26557
26558 2009-02-28  H.J. Lu  <hongjiu.lu@intel.com>
26559
26560         PR target/39327
26561         * config/i386/sse.md (avx_addsubv8sf3): Correct item bits.
26562         (avx_addsubv4df3): Likewise.
26563         (*avx_addsubv4sf3): Likewise.
26564         (sse3_addsubv4sf3): Likewise.
26565         (*avx_addsubv2df3): Likewise.
26566         (sse3_addsubv2df3): Likewise.
26567         (avx_unpckhps256): Correct item selectors.
26568         (avx_unpcklps256): Likewise.
26569         (avx_unpckhpd256): Likewise.
26570         (avx_unpcklpd256): Likewise.
26571
26572 2009-02-28  Jan Hubicka  <jh@suse.cz>
26573
26574         * tree-inline.c (expand_call_inline): Avoid duplicate declarations of
26575         static vars.
26576         (copy_arguments_for_versioning): If var is declared don't declare it.
26577         (tree_function_versioning): First setup substitutions and then copy
26578         args.
26579
26580 2009-02-27  Jan Hubicka  <jh@suse.cz>
26581
26582         PR debug/39267
26583         * cgraph.h (varpool_output_debug_info): Remove.
26584         * cgraphunit.c (varpool_output_debug_info): Remove.
26585         * dwarf2out.c (deferred_locations_struct): New struct
26586         (deferred_locations): New type.
26587         (deferred_locations_list): New static var.
26588         (deffer_location): New function.
26589         (gen_variable_die): Use it.
26590         (decls_for_scope): Output info on local static vars.
26591         (dwarf2out_finish): Process deferred locations.
26592         * varpool.c (varpool_output_debug_info): Remove.
26593
26594 2009-02-27  Jan Hubicka  <jh@suse.cz>
26595
26596         PR debug/39267
26597         * tree.h (TREE_PROTECTED): Fix comment.
26598         (BLOCK_HANDLER_BLOCK): Remove.
26599         (struct tree_block): Remove handler_block add body_block.
26600         (inlined_function_outer_scope_p): New.
26601         (is_body_block): Remove.
26602         * dbxout.c (dbxout_block): Remove BLOCK_HANDLER_BLOCK.
26603         * dwarf2out.c (is_inlined_entry_point): Remove.
26604         (add_high_low_attributes): Use inlined_function_outer_scope_p.
26605         (gen_block_die): Use is_inlined_entry_point check.  Remove body block
26606         code.
26607         * langhooks.h (struct lang_hooks): Remove no_bodu_blocks.
26608         * gimplify.c (gimplify_expr): Gimplify body blocks.
26609         * tree-ssa-live.c (remove_unused_scope_block_p): Allow removing wrapper
26610         block with multiple subblocks.
26611         (dump_scope_block): Prettier output; dump more flags and info.
26612         (dump_scope_blocks): New.
26613         (remove_unused_locals): Use dump_scope_blocks.
26614         * tree-flow.h (dump_scope_blocks): Declare.
26615         * tree-cfg.c (execute_build_cfg): Dump scope blocks.
26616         * stmt.c (is_body_block): Remove.
26617         * tree-inline.c (remap_block): Copy BODY_BLOCK info.
26618         * langhooks-def.h (LANG_HOOKS_NO_BODY_BLOCKS): Remove.
26619
26620 2009-02-27  Sebastian Pop  <sebastian.pop@amd.com>
26621
26622         PR middle-end/39308
26623         * graphite.c (graphite_loop_normal_form): Do not call
26624         number_of_iterations_exit from a gcc_assert.
26625
26626 2009-02-27  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
26627
26628         * config/s390/s390.c (s390_swap_cmp): Look for conditional
26629         jumps if COND is NULL.
26630         (find_cond_jump): New function.
26631         (s390_z10_optimize_cmp): Handling for reg-reg compares added.
26632         * config/s390/s390.md: Remove z10_cobra attribute value.
26633
26634 2009-02-26  Uros Bizjak  <ubizjak@gmail.com>
26635
26636         * config/alpha/alpha.h (alpha_expand_mov): Return false if
26637         force_const_mem returns NULL_RTX.
26638
26639 2009-02-26  Jan Hubicka  <jh@suse.cz>
26640
26641         PR debug/39267
26642         * cgraph.h (varpool_output_debug_info): Remove.
26643         * cgraphunit.c (varpool_output_debug_info): Remove.
26644         * dwarf2out.c (deferred_locations_struct): New struct
26645         (deferred_locations): New type.
26646         (deferred_locations_list): New static var.
26647         (deffer_location): New function.
26648         (gen_variable_die): Use it.
26649         (decls_for_scope): Output info on local static vars.
26650         (dwarf2out_finish): Process deferred locations.
26651         * varpool.c (varpool_output_debug_info): Remove.
26652
26653 2009-02-25  H.J. Lu  <hongjiu.lu@intel.com>
26654
26655         PR rtl-optimization/39241
26656         * jump.c (rtx_renumbered_equal_p): Remove 2 superfluous calls
26657         to subreg_offset_representable_p.
26658
26659 2009-02-25  Paolo Bonzini  <bonzini@gnu.org>
26660
26661         * regmove.c (regmove_optimize): Conform to struct rtl_opt_pass
26662         execute function prototype.  Get f and nregs from max_reg_num
26663         and get_insns.  Remove the first backward pass as it's dead,
26664         guard the forward pass by flag_expensive_optimizations.
26665         (rest_of_handle_regmove): Delete.
26666         (pass_regmove): Replace it with regmove_optimize.
26667
26668 2009-02-25  Martin Jambor  <mjambor@suse.cz>
26669
26670         PR tree-optimization/39259
26671         * tree-inline.c (initialize_cfun): Remove asserts for calls_setjmp and
26672         calls_alloca function flags.
26673         (copy_bb): Set calls_setjmp and alls_alloca function flags if such
26674         calls are detected.
26675
26676 2009-02-25  Paolo Bonzini  <bonzini@gnu.org>
26677
26678         * regmove.c (discover_flags_reg, flags_set_1, mark_flags_life_zones,
26679         flags_set_1_rtx, flags_set_1_set): Delete.
26680         (regmove_optimize): Do not call mark_flags_life_zones.
26681
26682 2009-02-24  Julian Brown  <julian@codesourcery.com>
26683
26684         PR target/35965
26685         * config/arm/arm.c (require_pic_register): Only set
26686         cfun->machine->pic_reg once per function.
26687
26688 2009-02-24  Sandra Loosemore  <sandra@codesourcery.com>
26689
26690         * doc/invoke.texi (Link Options): Document an easier way to pass
26691         options that take arguments to the GNU linker using -Xlinker and -Wl.
26692
26693 2009-02-24  Steve Ellcey  <sje@cup.hp.com>
26694
26695         PR target/33785
26696         * doc/tm.texi (TARGET_C99_FUNCTIONS): Fix description.
26697
26698 2009-02-24  Richard Guenther  <rguenther@suse.de>
26699
26700         PR debug/39285
26701         * dwarf2out.c (gen_enumeration_type_die): Handle CONST_DECLs.
26702
26703 2009-02-24  Richard Guenther  <rguenther@suse.de>
26704             Zdenek Dvorak  <ook@ucw.cz>
26705
26706         PR tree-optimization/39233
26707         * tree-ssa-loop-ivopts.c (add_candidate_1): Do not except pointers
26708         from converting them to a generic type.
26709
26710 2009-02-23  Sebastian Pop  <sebastian.pop@amd.com>
26711
26712         PR tree-optimization/39260
26713         * graphite.c (harmful_stmt_in_bb): Stop a SCoP when the basic block
26714         contains a condition with a real type.
26715         (build_scop_conditions_1): Conditions are always last_stmt of a bb.
26716
26717 2009-02-23  Jason Merrill  <jason@redhat.com>
26718
26719         PR c++/38880
26720         * varasm.c (initializer_constant_valid_p) [PLUS_EXPR]: Check
26721         narrowing_initializer_constant_valid_p.
26722         (narrowing_initializer_constant_valid_p): Don't return
26723         null_pointer_node for adding a pointer to itself.
26724
26725 2009-02-23  Jan Hubicka  <jh@suse.cz>
26726
26727         PR c/12245
26728         * ggc.h (htab_create_ggc): Use ggc_free to free hashtable when
26729         resizing.
26730
26731 2009-02-23  Jan Hubicka  <jh@suse.cz>
26732
26733         PR tree-optimization/37709
26734         * tree.c (block_ultimate_origin): Move here from dwarf2out.
26735         * tree.h (block_ultimate_origin): Declare.
26736         * dwarf2out.c (block_ultimate_origin): Move to tree.c
26737         * tree-ssa-live.c (remove_unused_scope_block_p):
26738         Eliminate blocks containig no instructions nor live variables nor
26739         nested blocks.
26740         (dump_scope_block): New function.
26741         (remove_unused_locals): Enable removal of dead blocks by default;
26742         enable dumping at TDF_DETAILS.
26743
26744 2009-02-21  H.J. Lu  <hongjiu.lu@intel.com>
26745
26746         * config/i386/i386.c (classify_argument): Don't allow COImode
26747         and OImode.
26748         (function_arg_advance_32): Don't allow OImode.
26749         (function_arg_32): Likewise.
26750         (function_value_32): Likewise.
26751         (return_in_memory_32): Likewise.
26752         (function_arg_64): Remove OImode comment.
26753
26754 2009-02-21  H.J. Lu  <hongjiu.lu@intel.com>
26755
26756         PR target/39261
26757         * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): Use
26758         ix86_expand_vector_set for V4DImode in 64bit mode only.
26759         (ix86_expand_vector_init_one_var): Likewise.
26760
26761 2009-02-21  Sebastian Pop  <sebastian.pop@amd.com>
26762
26763         * graphite.c (graphite_trans_loop_block): Adjust tile size to 51.
26764
26765 2009-02-21  Richard Sandiford  <rdsandiford@googlemail.com>
26766
26767         PR bootstrap/39257
26768         * loop-iv.c: Revert last change.
26769         * emit-rtl.c: Likewise.
26770
26771 2009-02-21  H.J. Lu  <hongjiu.lu@intel.com>
26772
26773         PR target/39256
26774         * config/i386/i386.c (type_natural_mode): Remove an extra
26775         space in the warning message.
26776         (function_value_32): Handle 32-byte vector modes.
26777         (return_in_memory_32): Likewise.
26778
26779 2009-02-21  Richard Sandiford  <rdsandiford@googlemail.com>
26780
26781         * loop-iv.c (truncate_value): New function.
26782         (iv_subreg, get_iv_value, iv_number_of_iterations): Use it instead
26783         of lowpart_subreg.
26784         (lowpart_subreg): Move to...
26785         * emit-rtl.c: ...here.
26786
26787 2009-02-21  Danny Smith  <dannysmith@users.sourceforge.net>
26788
26789         * config/i386/winnt.c (i386_pe_asm_output_aligned_decl_common): Revert
26790         accidental and undocumented change at revision 140860.
26791
26792 2009-02-21  Joseph Myers  <joseph@codesourcery.com>
26793
26794         * config/arm/arm.c (arm_gimplify_va_arg_expr): Update prototype to
26795         take gimple_seq * arguments.
26796         (arm_mangle_type): Use CONST_CAST_TREE on type argument passed to
26797         types_compatible_p langhook.
26798
26799 2009-02-20  Mark Mitchell  <mark@codesourcery.com>
26800             Joseph Myers  <joseph@codesourcery.com>
26801
26802         * config/arm/arm.c (arm_builtin_va_list): New function.
26803         (arm_expand_builtin_va_start): Likewise.
26804         (arm_gimplify_va_arg_expr): Likewise.
26805         (TARGET_BUILD_BUILTIN_VA_LIST): Define.
26806         (TARGET_BUILD_BUILTIN_VA_START): Likewise.
26807         (TARGET_BUILD_BUILTIN_VA_ARG_EXPR): Likewise.
26808         (va_list_type): New variable.
26809         (arm_mangle_type): Mangle va_list_type appropriately.
26810
26811 2009-02-20  Jakub Jelinek  <jakub@redhat.com>
26812
26813         PR middle-end/39157
26814         * Makefile.in (loop-invariant.o): Depend on $(PARAMS_H).
26815         * params.h (LOOP_INVARIANT_MAX_BBS_IN_LOOP): Define.
26816         * params.def (loop-invariant-max-bbs-in-loop): New parameter.
26817         * opts.c (decode_options): Set loop-invariant-max-bbs-in-loop
26818         parameter to 1000 for -O1 by default.
26819         * doc/invoke.texi (loop-invariant-max-bbs-in-loop): Document new
26820         parameter.
26821         * loop-invariant.c: Include params.h.
26822         (move_loop_invariants): Don't call move_single_loop_invariants on
26823         very large loops.
26824
26825 2009-02-20  Jaka Mocnik  <jaka@xlab.si>
26826
26827         * calls.c (emit_library_call_value_1): Use slot_offset instead of
26828         offset when calculating bounds for indexing stack_usage_map.  Fixes
26829         a buffer overflow with certain target setups.
26830
26831 2009-02-20  Jakub Jelinek  <jakub@redhat.com>
26832
26833         PR target/39240
26834         * calls.c (expand_call): Clear try_tail_call if caller and callee
26835         disagree in promotion of function return value.
26836
26837 2009-02-19  Jakub Jelinek  <jakub@redhat.com>
26838
26839         PR target/39175
26840         * c-common.c (c_determine_visibility): If visibility changed and
26841         DECL_RTL has been already set, call make_decl_rtl to update symbol
26842         flags.
26843
26844 2009-02-19  H.J. Lu  <hongjiu.lu@intel.com>
26845
26846         PR c++/39188
26847         * varasm.c (assemble_variable): Don't check DECL_NAME when
26848         globalizing a variable.
26849
26850 2009-02-19  Joseph Myers  <joseph@codesourcery.com>
26851
26852         PR c/38483
26853         * builtins.c (gimplify_va_arg_expr): Evaluate the va_list
26854         expression before any __builtin_trap call.
26855         * c-typeck.c (build_function_call): Convert and check function
26856         arguments before generating a call to a trap.  Evaluate the
26857         function arguments before the trap.
26858
26859 2009-02-19  Uros Bizjak  <ubizjak@gmail.com>
26860
26861         PR target/39228
26862         * config/i386/i386.md (isinfxf2): Split from isinf<mode>2.
26863         (UNSPEC_FXAM_MEM): New unspec.
26864         (fxam<mode>2_i387_with_temp): New insn and split pattern.
26865         (isinf<mode>2): Use MODEF mode iterator.  Force operand[1] through
26866         memory using fxam<mode>2_i387_with_temp to remove excess precision.
26867
26868 2009-02-19  Richard Guenther  <rguenther@suse.de>
26869
26870         PR tree-optimization/39207
26871         PR tree-optimization/39074
26872         * tree-ssa-structalias.c (storedanything_id, var_storedanything,
26873         storedanything_tree): New.
26874         (do_ds_constraint): Simplify ANYTHING shortcutting.  Update
26875         the STOREDANYTHING solution if the lhs solution contains ANYTHING.
26876         (build_succ_graph): Add edges from STOREDANYTHING to all
26877         non-direct nodes.
26878         (init_base_vars): Initialize STOREDANYTHING.
26879         (compute_points_to_sets): Free substitution info after
26880         building the succ graph.
26881         (ipa_pta_execute): Likewise.
26882
26883         * tree-ssa-structalias.c (struct variable_info): Add may_have_pointers
26884         field.
26885         (do_ds_constraint): Do not add to special var or non-pointer
26886         field solutions.
26887         (type_could_have_pointers): Split out from ...
26888         (could_have_pointers): ... here.  For arrays use the element type.
26889         (create_variable_info_for): Initialize may_have_pointers.
26890         (new_var_info): Likewise.
26891         (handle_lhs_call): Make the HEAP variable unknown-sized.
26892         (intra_create_variable_infos): Use a type with pointers for
26893         PARM_NOALIAS, make it unknown-sized.
26894
26895 2009-02-18  H.J. Lu  <hongjiu.lu@intel.com>
26896
26897         PR target/39224
26898         * config/i386/i386.c (ix86_return_in_memory): Properly check ABI.
26899
26900 2009-02-18  Jason Merrill  <jason@redhat.com>
26901
26902         PR target/39179
26903         * tree-ssa-ccp.c (get_symbol_constant_value): Don't assume zero
26904         value if DECL_EXTERNAL.
26905         * tree-sra.c (sra_walk_gimple_assign): Likewise.
26906         * target.h (gcc_target::binds_local_p): Clarify "module".
26907         * tree.h (TREE_PUBLIC): Clarify "module".
26908
26909 2009-02-17  Xuepeng Guo  <xuepeng.guo@intel.com>
26910
26911         PR target/38891
26912         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Move the hunk of
26913         initialization for MS_ABI prior to the hunk of !TARGET_MMX.
26914
26915 2009-02-17  H.J. Lu  <hongjiu.lu@intel.com>
26916
26917         PR target/39082
26918         * c.opt (Wabi): Support C and ObjC.
26919         (Wpsabi): New.
26920
26921         * c-opts.c (c_common_handle_option): Handle OPT_Wabi.
26922
26923         * config/i386/i386.c (classify_argument): Warn once about the ABI
26924         change when passing union with long double.
26925
26926         * doc/invoke.texi: Update -Wabi for warning psABI changes.
26927
26928 2009-02-18  Joseph Myers  <joseph@codesourcery.com>
26929
26930         PR c/35447
26931         * c-parser.c (c_parser_compound_statement): Always enter and leave
26932         a scope.
26933
26934 2009-02-17  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
26935
26936         PR target/34587
26937         * config/darwin.h (SUPPORTS_INIT_PRIORITY): Define.
26938
26939 2009-02-18  Jakub Jelinek  <jakub@redhat.com>
26940
26941         PR tree-optimization/36922
26942         * tree-data-ref.c (initialize_matrix_A): Handle BIT_NOT_EXPR.
26943         * tree-scalar-evolution.c (interpret_rhs_expr, instantiate_scev_1):
26944         Likewise.
26945
26946 2009-02-17  Richard Sandiford  <rdsandiford@googlemail.com>
26947
26948         * config/mips/mips.c (mips_override_options): Set flag_dwarf2_cfi_asm
26949         to 0 for EABI64.
26950
26951 2009-02-17  Richard Sandiford  <rdsandiford@googlemail.com>
26952
26953         * config/mips/mips.md (type): Reclassify lui_movf as "unknown".
26954
26955 2009-02-17  Richard Sandiford  <rdsandiford@googlemail.com>
26956
26957         * config/mips/mips.c (mips_gimplify_va_arg_expr): Fix invalid
26958         tree sharing.
26959
26960 2009-02-17  Ruan Beihong  <ruanbeihong@gmail.com>
26961             Richard Sandiford  <rdsandiford@googlemail.com>
26962
26963         * config/mips/mips.c (CODE_FOR_loongson_biadd): Delete.
26964         * config/mips/loongson.md (reduc_uplus_<mode>): Rename to...
26965         (loongson_biadd): ...this.
26966
26967 2009-02-17  Richard Guenther  <rguenther@suse.de>
26968
26969         PR tree-optimization/39202
26970         * tree-ssa-structalias.c (do_structure_copy): Before collapsing
26971         a var make sure to follow existing collapses.
26972
26973 2009-02-17  Richard Guenther  <rguenther@suse.de>
26974
26975         PR middle-end/39214
26976         * langhooks.c (lhd_print_error_function): Check for NULL block.
26977
26978 2009-02-17  Richard Guenther  <rguenther@suse.de>
26979
26980         PR tree-optimization/39204
26981         * tree-ssa-pre.c (phi_translate_1): Lookup the value-number
26982         of the PHI arg.
26983
26984 2009-02-17  Uros Bizjak  <ubizjak@gmail.com>
26985
26986         * config/soft-fp/double.h: Update from glibc CVS.
26987
26988 2009-02-17  Richard Guenther  <rguenther@suse.de>
26989
26990         PR tree-optimization/39207
26991         * tree-ssa-structalias.c (find_what_p_points_to): Do not emit
26992         strict-aliasing warnings for pointers pointing to NULL.
26993
26994 2009-02-16  Joseph Myers  <joseph@codesourcery.com>
26995
26996         PR c/35446
26997         * c-parser.c (c_parser_braced_init): Call pop_init_level when
26998         skipping until next close brace.
26999
27000 2009-02-16  H.J. Lu  <hongjiu.lu@intel.com>
27001
27002         PR target/37049
27003         * config/i386/i386.c (ix86_expand_push): Set memory alignment
27004         to function argument boundary.
27005
27006 2009-02-16  Hariharan Sandanagobalane  <hariharan@picochip.com>
27007
27008         * config/picochip/picochip.md (lea_add): Allow any nonimmediate
27009         in the lea_add. Reload eventually constraints it properly.
27010         * config/picochip/constraints.md: Remove the target constraint
27011         "b", since it is not needed anymore.
27012
27013 2009-02-16  Jakub Jelinek  <jakub@redhat.com>
27014
27015         * gthr-dce.h: Uglify function parameter and local variable names.
27016         * gthr-gnat.h: Likewise.
27017         * gthr-mipssde.h: Likewise.
27018         * gthr-nks.h: Likewise.
27019         * gthr-posix95.h: Likewise.
27020         * gthr-posix.h: Likewise.
27021         * gthr-rtems.h: Likewise.
27022         * gthr-single.h: Likewise.
27023         * gthr-solaris.h: Likewise.
27024         * gthr-tpf.h: Likewise.
27025         * gthr-vxworks.h: Likewise.
27026         * gthr-win32.h: Likewise.
27027
27028 2009-02-15  H.J. Lu  <hongjiu.lu@intel.com>
27029
27030         PR target/39196
27031         * config/i386/i386.md: Restrict the new peephole2 to move
27032         between MMX/SSE registers.
27033
27034 2009-02-15  Richard Guenther  <rguenther@suse.de>
27035
27036         Revert
27037         2009-02-13  Richard Guenther  <rguenther@suse.de>
27038
27039         * configure.ac: Enable LFS.
27040         * configure: Re-generate.
27041         * config.in: Likewise.
27042
27043 2009-02-13  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
27044
27045         * config/spu/spu_internals.h (spu_sr, spu_sra, spu_srqw,
27046         spu_srqwbyte, spu_srqwbytebc): Define.
27047         * config/spu/spu-builtins.def (spu_sr, spu_sra, spu_srqw,
27048         spu_srqwbyte, spu_srqwbytebc): New overloaded builtins.
27049         * config/spu/spu.md ("shrqbybi_<mode>", "shrqbi_<mode>",
27050         "shrqby_<mode>"): New insn-and-split patterns.
27051         * config/spu/spu.c (expand_builtin_args): Determine and return
27052         number of operands using spu_builtin_description data.
27053         (spu_expand_builtin_1): Use it.
27054
27055 2009-02-13  Steve Ellcey  <sje@cup.hp.com>
27056
27057         PR target/38056
27058         * config/ia64/ia64.c (ia64_function_ok_for_sibcall): Check
27059         TARGET_CONST_GP.
27060
27061 2009-02-13  H.J. Lu  <hongjiu.lu@intel.com>
27062
27063         PR target/39149
27064         * config/i386/i386.c (override_options): Correct warning
27065         messages for -malign-loops, -malign-jumps and -malign-functions.
27066
27067 2009-02-13  H.J. Lu  <hongjiu.lu@intel.com>
27068
27069         PR target/39152
27070         * config/i386/i386.md: Restrict the new peephole2 to move
27071         between the general purpose registers.
27072
27073 2009-02-13  H.J. Lu  <hongjiu.lu@intel.com>
27074
27075         PR target/39162
27076         * config/i386/i386.c (type_natural_mode): Add a new argument.
27077         Return the original mode and warn ABI change if vector size is 32byte.
27078         (function_arg_advance): Updated.
27079         (function_arg): Likewise.
27080         (ix86_function_value): Likewise.
27081         (ix86_return_in_memory): Likewise.
27082         (ix86_sol10_return_in_memory): Likewise.
27083         (ix86_gimplify_va_arg): Likewise.
27084         (function_arg_32): Don't warn ABX ABI change here.
27085         (function_arg_64): Likewise.
27086
27087 2009-02-13  Bernd Schmidt  <bernd.schmidt@analog.com>
27088
27089         * loop-iv.c (implies_p): In the final case, test that operands 0
27090         of the two comparisons match.
27091
27092         * config/bfin/bfin.c (find_prev_insn_start): New function.
27093         (bfin_optimize_loop): Use it in some cases instead of PREV_INSN.
27094         (find_next_insn_start): Move.
27095
27096 2009-02-13  Richard Guenther  <rguenther@suse.de>
27097
27098         * configure.ac: Enable LFS.
27099         * configure: Re-generate.
27100         * config.in: Likewise.
27101
27102 2009-02-13  Joseph Myers  <joseph@codesourcery.com>
27103
27104         PR c/35444
27105         * c-parser.c (c_parser_parms_list_declarator): Discard pending
27106         sizes on syntax error after some arguments have been parsed.
27107
27108 2009-02-12  Jakub Jelinek  <jakub@redhat.com>
27109
27110         * doc/invoke.texi (-fira): Remove.
27111
27112 2009-02-12  H.J. Lu  <hongjiu.lu@intel.com>
27113
27114         * caller-save.c: Replace regclass.c with reginfo.c in comments.
27115         * recog.c: Likewise.
27116         * rtl.h: Likewise.
27117
27118 2009-02-12  Uros Bizjak  <ubizjak@gmail.com>
27119
27120         * longlong.h (sub_ddmmss): New for ia64. Ported from GMP 4.2.
27121         (umul_ppmm): Likewise.
27122         (count_leading_zeros): Likewise.
27123         (count_trailing_zeros): Likewise.
27124         (UMUL_TIME): Likewise.
27125
27126 2009-02-12  H.J. Lu  <hongjiu.lu@intel.com>
27127
27128         * config.gcc (ia64*-*-linux*): Add ia64/t-fprules-softfp and
27129         soft-fp/t-softfp to tmake_file.
27130
27131         * config/ia64/ia64.c (ia64_soft_fp_init_libfuncs): New.
27132         (ia64_expand_compare): Use HPUX library for TFmode only for HPUX.
27133         (ia64_builtins) [IA64_BUILTIN_COPYSIGNQ, IA64_BUILTIN_FABSQ,
27134         IA64_BUILTIN_INFQ]: New.
27135         (ia64_init_builtins): Initialize __builtin_infq,
27136         __builtin_fabsq and __builtin_copysignq if not HPUX.
27137         (ia64_expand_builtin): Handle IA64_BUILTIN_COPYSIGNQ,
27138         IA64_BUILTIN_FABSQ and IA64_BUILTIN_INFQ.
27139
27140         * config/ia64/lib1funcs.asm (__divtf3): Define only if
27141         SHARED is defined.
27142         (__fixtfti): Likewise.
27143         (__fixunstfti): Likewise.
27144         (__floattitf): Likewise.
27145
27146         * config/ia64/libgcc-glibc.ver: New.
27147         * config/ia64/t-fprules-softfp: Likewise.
27148         * config/ia64/sfp-machine.h: Likewise.
27149
27150         * config/ia64/linux.h (LIBGCC2_HAS_TF_MODE): New.
27151         (LIBGCC2_TF_CEXT): Likewise.
27152         (TF_SIZE): Likewise.
27153         (TARGET_INIT_LIBFUNCS): Likewise.
27154
27155         * config/ia64/t-glibc (SHLINB_MAPFILES):
27156         Add $(srcdir)/config/ia64/libgcc-glibc.ver.
27157
27158 2009-02-12  H.J. Lu  <hongjiu.lu@intel.com>
27159
27160         * config/i386/i386.c (construct_container): Rewrite processing
27161         BLKmode with X86_64_SSE_CLASS.
27162
27163 2009-02-12  Paolo Bonzini  <bonzini@gnu.org>
27164
27165         PR target/39152
27166         * config/i386/i386.md: Replace simplify_replace_rtx with
27167         replace_rtx in the new peephole2.
27168
27169 2009-02-12  Nathan Sidwell  <nathan@codesourcery.com>
27170
27171         * doc/invoke.texi (Optimize Options): Stop claiming inlining and
27172         loop unrolling do not happen at -O2.
27173
27174 2009-02-12  Michael Matz  <matz@suse.de>
27175
27176         * gcc.c (ASM_DEBUG_SPEC): Check for -g0.
27177
27178 2009-02-12  Jakub Jelinek  <jakub@redhat.com>
27179
27180         * dwarf2out.c (dwarf2out_finish): Force output of comp_unit_die
27181         for -g3.
27182
27183 2009-02-12  Ben Elliston  <bje@au.ibm.com>
27184
27185         * config/rs6000/rs6000.md (allocate_stack): Use _stack form of
27186         patterns when updating the back chain.  Missed in the 2009-02-10
27187         change.
27188
27189 2009-02-11  Janis Johnson  <janis187@us.ibm.com>
27190
27191         * doc/extend.texi (Decimal Floating Types): Update identifier of
27192         draft TR and list of missing support.
27193
27194 2009-02-11  Jakub Jelinek  <jakub@redhat.com>
27195
27196         PR middle-end/39154
27197         * gimplify.c (omp_notice_variable): If adding GOVD_SEEN
27198         bit to variable length decl's flags, add it also to its
27199         pointer replacement variable.
27200
27201 2009-02-11  Uros Bizjak  <ubizjak@gmail.com>
27202             Jakub Jelinek  <jakub@redhat.com>
27203
27204         PR target/39118
27205         * config/i386/i386.md (UNSPEC_MEMORY_BLOCKAGE): New constant.
27206         (memory_blockage): New expander.
27207         (*memory_blockage): New insn pattern.
27208         * config/i386/i386.c (ix86_expand_prologue): Use memory_blockage
27209         instead of general blockage at the end of function prologue when
27210         frame pointer is used to access red zone area.  Do not emit blockage
27211         when profiling, it is emitted in generic code.
27212         (ix86_expand_epilogue): Emit memory_blockage at the beginning of
27213         function epilogue when frame pointer is used to access red zone area.
27214
27215 2009-02-11  Paolo Bonzini  <bonzini@gnu.org>
27216
27217         PR target/38824
27218         * config/i386/i386.md: Add two new peephole2 to avoid mov followed
27219         by arithmetic with memory operands.
27220         * config/i386/predicates.md (commutative_operator): New.
27221
27222 2009-02-10  Janis Johnson  <janis187@us.ibm.com>
27223
27224         * doc/extend.texi (Fixed-Point Types): Break long paragraphs into
27225         bulleted lists.
27226
27227 2009-02-10  Eric Botcazou  <ebotcazou@adacore.com>
27228
27229         * alias.h (record_alias_subset): Declare.
27230         * alias.c (record_alias_subset): Make global.
27231
27232 2009-02-10  Nick Clifton  <nickc@redhat.com>
27233
27234         * tree-parloops.c: Change license to GPLv3.
27235         * ipa-struct-reorg.c: Change license to GPLv3.
27236         * ipa-struct-reorg.h: Change license to GPLv3.
27237
27238 2009-02-10  Steve Ellcey  <sje@cup.hp.com>
27239
27240         PR c/39084
27241         * c-decl.c (start_struct): Return NULL on error.
27242
27243 2009-02-10  Jakub Jelinek  <jakub@redhat.com>
27244
27245         PR middle-end/39124
27246         * cfgloopmanip.c (remove_path): Call remove_bbs after
27247         cancel_loop_tree, not before it.
27248
27249         PR target/39139
27250         * function.h (struct function): Add has_local_explicit_reg_vars bit.
27251         * gimplify.c (gimplify_bind_expr): Set it if local DECL_HARD_REGISTER
27252         VAR_DECLs were seen.
27253         * tree-ssa-live.c (remove_unused_locals): Recompute
27254         cfun->has_local_explicit_reg_vars.
27255         * tree-ssa-sink.c (statement_sink_location): Don't sink BLKmode
27256         copies or clearings if cfun->has_local_explicit_reg_vars.
27257
27258 2009-02-10  Uros Bizjak  <ubizjak@gmail.com>
27259
27260         PR target/39118
27261         * config/i386/i386.c (expand_prologue): Emit blockage at the end
27262         of function prologue when frame pointer is used to access
27263         red zone area.
27264
27265 2009-02-10  Richard Guenther  <rguenther@suse.de>
27266
27267         PR middle-end/39127
27268         * gimplify.c (gimple_regimplify_operands): Always look if
27269         we need to create a temporary.
27270
27271 2009-02-10  Richard Guenther  <rguenther@suse.de>
27272
27273         PR tree-optimization/39132
27274         * tree-loop-distribution.c (todo): New global var.
27275         (generate_memset_zero): Trigger TODO_rebuild_alias.
27276         (tree_loop_distribution): Return todo.
27277
27278 2009-02-10  H.J. Lu  <hongjiu.lu@intel.com>
27279
27280         PR target/39119
27281         * config/i386/i386.c (x86_64_reg_class): Remove X86_64_AVX_CLASS.
27282         (x86_64_reg_class_name): Removed.
27283         (classify_argument): Return 0 if bytes > 32.  Return 0 if the
27284         first one isn't X86_64_SSE_CLASS or any other ones aren't
27285         X86_64_SSEUP_CLASS when size > 16bytes.  Don't turn
27286         X86_64_SSEUP_CLASS into X86_64_SSE_CLASS if the preceded one
27287         is X86_64_SSEUP_CLASS.  Set AVX modes to 1 X86_64_SSE_CLASS
27288         and 3 X86_64_SSEUP_CLASS.
27289         (construct_container): Remove X86_64_AVX_CLASS.  Handle 4
27290         registers with 1 X86_64_SSE_CLASS and 3 X86_64_SSEUP_CLASS.
27291
27292 2009-02-10  Ben Elliston  <bje@au.ibm.com>
27293
27294         * config/rs6000/rs6000.md (allocate_stack): Always use an update
27295         form instruction to update the stack back chain word, even if the
27296         user has disabled the generation of update instructions.
27297         (movdi_<mode>_update_stack): New.
27298         (movsi_update_stack): Likewise.
27299         * config/rs6000/rs6000.c (rs6000_emit_allocate_stack): Likewise,
27300         always use an update form instruction to update the stack back
27301         chain word.
27302
27303 2009-02-09  Sebastian Pop  <sebastian.pop@amd.com>
27304
27305         PR middle-end/38953
27306         * graphite.c (if_region_set_false_region): After moving a region in
27307         the false branch of a condition, remove the empty dummy basic block.
27308         (gloog): Remove wrong fix for PR38953.
27309
27310 2009-02-09  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
27311
27312         * config/spu/spu.c (array_to_constant): Fix (latent) wrong-code
27313         generation due to implicit sign extension.
27314
27315 2009-02-09  Eric Botcazou  <ebotcazou@adacore.com>
27316
27317         PR middle-end/38981
27318         * tree-ssa-coalesce.c (add_coalesce): Cap the costs of coalesce pairs
27319         at MUST_COALESCE_COST-1 instead of MUST_COALESCE_COST.
27320
27321 2009-02-09  Richard Guenther  <rguenther@suse.de>
27322
27323         PR middle-end/35202
27324         * convert.c (convert_to_real): Disable (float)fn((double)x)
27325         to fnf(x) conversion if errno differences may occur and
27326         -fmath-errno is set.
27327
27328 2009-02-07  Anatoly Sokolov  <aesok@post.ru>
27329
27330         * config/avr/avr.c (avr_mcu_t): Add ata6289 device.
27331         * config/avr/avr.h (LINK_SPEC, CRT_BINUTILS_SPECS): (Ditto.).
27332         * config/avr/t-avr (MULTILIB_MATCHES): (Ditto.).
27333
27334 2009-02-06  Joseph Myers  <joseph@codesourcery.com>
27335
27336         PR c/35434
27337         * c-common.c (handle_alias_attribute): Disallow attribute for
27338         anything not a FUNCTION_DECL or VAR_DECL.
27339
27340 2009-02-06  Janis Johnson  <janis187@us.ibm.com>
27341
27342         PR c/39035
27343         * real.c (do_compare): Special-case compare of zero against
27344         decimal float value.
27345
27346 2009-02-06  Joseph Myers  <joseph@codesourcery.com>
27347
27348         PR c/36432
27349         * c-decl.c (grokdeclarator): Don't treat [] declarators in fields
27350         as indicating flexible array members unless the field itself is
27351         being declarared as the incomplete array.
27352
27353 2009-02-06  Jan Hubicka  <jh@suse.cz>
27354
27355         PR tree-optimization/38844
27356         * ipa-inline.c (try_inline): Stop inlining recursion when edge
27357         is already inlined.
27358
27359 2009-02-06  Richard Guenther  <rguenther@suse.de>
27360
27361         PR middle-end/38977
27362         * tree-cfg.c (need_fake_edge_p): Force a fake edge for
27363         fork because we may expand it as __gcov_fork.
27364
27365 2009-02-06  Nick Clifton  <nickc@redhat.com>
27366
27367         * config/m32c/m32c.h (PCC_BITFIELD_TYPE_MATTERS): Define to zero.
27368
27369 2009-02-06  Paolo Bonzini  <bonzini@gnu.org>
27370
27371         PR tree-optimization/35659
27372         * tree-ssa-sccvn.c (vn_constant_eq, vn_reference_eq, vn_nary_op_eq
27373         vn_phi_eq): Shortcut if hashcode does not match.
27374         (vn_reference_op_compute_hash): Do not call iterative_hash_expr for
27375         NULL operands.
27376         * tree-ssa-pre.c (pre_expr_hash): Look at hashcode if available,
27377         and avoid iterative_hash_expr.
27378         (FOR_EACH_VALUE_ID_IN_SET): New.
27379         (value_id_compare): Remove.
27380         (sorted_array_from_bitmap_set): Use FOR_EACH_VALUE_ID_IN_SET to
27381         sort expressions by value id.
27382
27383 2009-02-05  Kaz Kojima  <kkojima@gcc.gnu.org>
27384
27385         PR target/38991
27386         * config/sh/predicates.md (general_movsrc_operand): Don't check
27387         the subreg of system registers here.
27388
27389 2009-02-05  Jakub Jelinek  <jakub@redhat.com>
27390
27391         PR c++/39106
27392         * cgraphunit.c (cgraph_function_versioning): Clear also DECL_VIRTUAL_P
27393         on the copied decl.
27394
27395 2009-02-05  Paolo Bonzini  <bonzini@gnu.org>
27396
27397         PR rtl-optimization/39110
27398         * rtlanal.c (rtx_addr_can_trap_p_1): Shortcut unaligned
27399         addresses, not aligned ones.
27400
27401 2009-02-05  Daniel Berlin  <dberlin@dberlin.org>
27402             Richard Guenther  <rguenther@suse.de>
27403
27404         PR tree-optimization/39100
27405         * tree-ssa-structalias.c (do_ds_constraint): Actually do what the
27406         comment says and add edges.
27407
27408 2009-02-05  Joseph Myers  <joseph@codesourcery.com>
27409
27410         PR c/35435
27411         * c-common.c (handle_tls_model_attribute): Ignore attribute for
27412         non-VAR_DECLs without checking DECL_THREAD_LOCAL_P.
27413
27414 2009-02-04  Tobias Grosser  <grosser@fim.uni-passau.de>
27415
27416         * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
27417         sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
27418         register_bb_in_sese, new_sese, free_sese): Moved.
27419         (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
27420         outermost_loop_in_scop, build_scop_iteration_domain,
27421         expand_scalar_variables_ssa_name, get_vdef_before_scop,
27422         limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
27423         Use loop_in_sese_p instead of loop_in_scop_p.
27424         (new_graphite_bb, gloog): Do not initialize SCOP_BBS_B.
27425         (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP and SCOP_BBS_B.
27426         (scopdet_basic_block_info): Fix bug in scop detection.
27427         (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
27428         eq_loop_to_cloog_loop): Remove.
27429         (nb_loops_around_loop_in_scop, nb_loop
27430         ref_nb_loops): Moved here...
27431         * graphite.h (ref_nb_loops): ... from here.
27432         (struct scop): Remove bbs_b bitmap and loop2cloog_loop.
27433         (loop_domain_dim, loop_iteration_vector_dim): Remove.
27434         (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
27435
27436 2009-02-04  Paolo Bonzini  <bonzini@gnu.org>
27437             Hans-Peter Nilsson  <hp@axis.com>
27438
27439         PR rtl-optimization/37889
27440         * rtlanal.c (rtx_addr_can_trap_p_1): Add offset and size arguments.
27441         Move offset handling from PLUS to before the switch.  Use new
27442         arguments when considering SYMBOL_REFs too.
27443         (rtx_addr_can_trap_p): Pass dummy offset and size.
27444         (enum may_trap_p_flags): Remove.
27445         (may_trap_p_1): Pass size from MEM_SIZE.
27446
27447         PR rtl-optimization/38921
27448         * loop-invariant.c (find_invariant_insn): Use may_trap_or_fault_p.
27449         * rtl.h (may_trap_after_code_motion_p): Delete prototype.
27450         * rtlanal.c (may_trap_after_code_motion_p): Delete.
27451         (may_trap_p, may_trap_or_fault_p): Pass 0/1 as flags.
27452
27453 2009-02-04  H.J. Lu  <hongjiu.lu@intel.com>
27454
27455         AVX Programming Reference (January, 2009)
27456         * config/i386/sse.md (*vpclmulqdq): New.
27457
27458 2009-02-04  Jakub Jelinek  <jakub@redhat.com>
27459
27460         PR tree-optimization/38977
27461         PR gcov-profile/38292
27462         * calls.c (special_function_p): Disregard __builtin_ prefix.
27463
27464 2009-02-04  Hariharan Sandanagobalane  <hariharan@picochip.com>
27465
27466         * config/picochip/picochip.c (GO_IF_LEGITIMATE_ADDRESS): Disallow
27467         non-indexable addresses even before reload.
27468
27469 2009-02-03  Joseph Myers  <joseph@codesourcery.com>
27470
27471         PR c/29129
27472         * c-decl.c (grokdeclarator): Mark [*] arrays in field declarators
27473         as having variable size.  Do not give an error for unnamed
27474         parameters with [*] declarators.  Give a warning for type names
27475         with [*] declarators and mark them as variable size.
27476         * c-parser.c (c_parser_sizeof_expression): Do not give an error
27477         for sizeof applied to [*] type names.
27478
27479 2009-02-03  Andrew Pinski  <andrew_pinski@playstation.sony.com>
27480
27481         PR C++/36607
27482         * convert.c (convert_to_integer): Treat OFFSET_TYPE like INTEGER_TYPE.
27483
27484 2009-02-03  Jakub Jelinek  <jakub@redhat.com>
27485
27486         * gcc.c (process_command): Update copyright notice dates.
27487         * gcov.c (print_version): Likewise.
27488         * gcov-dump.c (print_version): Likewise.
27489         * mips-tfile.c (main): Likewise.
27490         * mips-tdump.c (main): Likewise.
27491
27492 2009-02-03  Joseph Myers  <joseph@codesourcery.com>
27493
27494         PR c/35433
27495         * c-typeck.c (composite_type): Set TYPE_SIZE and TYPE_SIZE_UNIT
27496         for composite type involving a zero-length array type.
27497
27498 2009-02-03  Jakub Jelinek  <jakub@redhat.com>
27499
27500         PR target/35318
27501         * function.c (match_asm_constraints_1): Skip over
27502         initial optional % in the constraint.
27503
27504         PR inline-asm/39059
27505         * c-parser.c (c_parser_postfix_expression): If fixed point is not
27506         supported, don't accept FIXED_CSTs.
27507         * c-decl.c (finish_declspecs): Error if fixed point is not supported
27508         and _Sat is used without _Fract/_Accum.  Set specs->type to
27509         integer_type_node for cts_fract/cts_accum if fixed point is not
27510         supported.
27511
27512 2009-02-02  Catherine Moore  <clm@codesourcery.com>
27513
27514         * sde.h (SUBTARGET_ARM_SPEC): Don't assemble -fpic code as -mabicalls.
27515
27516 2009-02-02  Richard Sandiford  <rdsandiford@googlemail.com>
27517
27518         * config/mips/mips.h (FILE_HAS_64BIT_SYMBOLS): New macro.
27519         (ABI_HAS_64BIT_SYMBOLS): Use it.
27520         (DWARF2_ADDR_SIZE): Use it instead of ABI_HAS_64BIT_SYMBOLS.
27521
27522 2009-02-02  Paul Brook  <paul@codesourcery.com>
27523
27524         * config/arm/arm.md (arm_addsi3): Add r/r/k alternative.
27525
27526 2009-02-02  Jakub Jelinek  <jakub@redhat.com>
27527
27528         PR inline-asm/39058
27529         * recog.h (asm_operand_ok): Add constraints argument.
27530         * recog.c (asm_operand_ok): Likewise.  If it is set, for digits
27531         recurse on matching constraint.
27532         (check_asm_operands): Pass constraints as 3rd argument to
27533         asm_operand_ok.  Don't look up matching constraint here.
27534         * stmt.c (expand_asm_operands): Pass NULL as 3rd argument
27535         to asm_operand_ok.
27536
27537 2009-02-02  Ben Elliston  <bje@au.ibm.com>
27538
27539         * doc/tm.texi (Storage Layout): Fix TARGET_ALIGN_ANON_BITFIELD and
27540         TARGET_NARROW_VOLATILE_BITFIELD macro names.
27541
27542 2009-01-31  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
27543
27544         * doc/install.texi (hppa*-hp-hpux*): Update binutils and linker
27545         information.  Remove some obsolete information.  Reorganize.
27546
27547         * config/pa/fptr.c: Revert license to GPL 2.
27548         * config/pa/milli64.S: Likewise.
27549
27550 2009-01-31  Dave Korn  <dave.korn.cygwin@gmail.com>
27551
27552         PR target/38904
27553         * mkmap-flat.awk (END):  Use pe_dll command-line arg to pass
27554         LIBRARY name in, instead of hard-coding it.
27555         * config.gcc (i[34567]86-*-pe | i[34567]86-*-cygwin*):  Add an
27556         extra target make frag to tmake_files according to EH model.
27557         (i[34567]86-*-mingw* | x86_64-*-mingw*):  Likewise.
27558         * config/i386/t-dw2-eh, config/i386/t-sjlj-eh:  Add new target
27559         frags that define makefile variable EH_MODEL appropriately.
27560         * config/i386/cygming.h (DWARF2_UNWIND_INFO):  Add comment.
27561         * config/i386/cygwin.h (LIBGCC_EH_EXTN):  Define to nothing or
27562         to "-sjlj" according to type of EH configured.
27563         (LIBGCC_SONAME):  Concatenate it to shared library base name.
27564         * config/i386/mingw32.h (LIBGCC_EH_EXTN):  Define to "_dw2" or
27565         to "_sjlj" according to type of EH configured.
27566         (LIBGCC_SONAME):  Concatenate it to shared library base name.
27567         * config/i386/t-cygming (SHLIB_SONAME):  Use EH_MODEL.
27568         (SHLIB_LINK):  Add missing semicolon to if-else construct.
27569         (SHLIB_MKMAP_OPTS):  Pass library name to mkmap-flat.awk as
27570         string value of "pe_dll" command-line option.
27571         * config/i386/t-cygwin (SHLIB_EH_EXTENSION):  New helper.
27572         (SHLIB_SONAME):  Use it when overriding t-cygming default.
27573         (SHLIB_IMPLIB):  Override t-cygming default.
27574         (SHLIB_MKMAP_OPTS):  Pass library name to mkmap-flat.awk as
27575         string value of "pe_dll" command-line option.
27576
27577 2009-01-31  Dave Korn  <dave.korn.cygwin@gmail.com>
27578
27579         PR target/38952
27580         * config/i386/i386.c (ix86_builtin_setjmp_frame_value): New.
27581         (TARGET_BUILTIN_SETJMP_FRAME_VALUE): Override default to point at it.
27582
27583 2009-01-31  Richard Guenther  <rguenther@suse.de>
27584
27585         PR tree-optimization/38937
27586         * tree-ssa-structalias.c (do_sd_constraint): Do not shortcut
27587         computing the transitive closure.
27588
27589 2009-01-30  Richard Guenther  <rguenther@suse.de>
27590
27591         PR tree-optimization/39041
27592         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1):
27593         Propagate variable indices only if the types match for this stmt.
27594
27595 2009-01-30  Jakub Jelinek  <jakub@redhat.com>
27596
27597         PR target/39013
27598         * c-decl.c (pop_scope): Set DECL_EXTERNAL for functions declared
27599         inline but never defined.
27600
27601 2009-01-30  Wolfgang Gellerich  <gellerich@de.ibm.com>
27602
27603         * config/s390/s390.md (*insv<mode>_reg_extimm): Removed.
27604         (*insv_h_di_reg_extimm): New insn.
27605         (*insv_l<mode>_reg_extimm): New insn.
27606
27607 2009-01-30  Hariharan Sandanagobalane  <hariharan@picochip.com>
27608
27609         * config/picochip/picochip.c (flag_conserve_stack): set
27610         PARAM_LARGE_STACK_FRAME and PARAM_STACK_FRAME_GROWTH to zero under
27611         fconserve-stack. Reduce call-overhead used by inliner.
27612
27613 2009-01-30  Hariharan Sandanagobalane  <hariharan@picochip.com>
27614
27615         PR/38157
27616         * common.opt (flag_conserve_stack): Initialised to zero.
27617
27618 2009-01-30  Kai Tietz  <kai.tietz@onevision.com>
27619
27620         PR/39002
27621         * config/i386/i386.c (ix86_can_use_return_insn_p): Check for nsseregs.
27622         (ix86_expand_epilogue): Take nsseregs in account to use proper restore
27623         method.
27624
27625 2009-01-29  H.J. Lu  <hongjiu.lu@intel.com>
27626
27627         * ira-color.c (allocno_reload_assign): Update comments.
27628         * regmove.c (regmove_optimize): Likewise.
27629
27630         * ra.h: Removed.
27631
27632 2009-01-29  Robert Millan  <rmh@aybabtu.com>
27633
27634         * config.gcc: Recognize GNU/kOpenSolaris (*-*-kopensolaris*-gnu).
27635         * config/i386/kopensolaris-gnu.h: New file.  Undefine
27636         `MD_UNWIND_SUPPORT'.
27637         * config/kopensolaris-gnu.h: New file (based on kfreebsd-gnu.h).
27638
27639 2009-01-29  Kazu Hirata  <kazu@codesourcery.com>
27640
27641         PR tree-optimization/39007
27642         * tree-loop-distribution.c (generate_builtin): Use
27643         recompute_dominator to compute the immediate dominator of the
27644         basic block just after the loop.
27645
27646 2009-01-29  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
27647
27648         * config/i386/sol2-10.h [!HAVE_AS_IX86_DIFF_SECT_DELTA]
27649         (ASM_OUTPUT_DWARF_PCREL): Define.
27650
27651 2009-01-29  Vladimir Makarov  <vmakarov@redhat.com>
27652
27653         * doc/tm.texi (TARGET_IRA_COVER_CLASSES): Modify description.
27654         * doc/passes.texi: Remove entries about regclass, local-alloc, and
27655         global.  Modify entries about regmove and IRA.
27656
27657         * ra-conflict.c: Remove the file.
27658
27659         * reload.c (push_reload, find_dummy_reload): Remove flag_ira.
27660
27661         * tree-pass.h (pass_local_alloc, pass_global_alloc): Remove.
27662         (pass_regclass_init): Rename to pass_reginfo_init.
27663
27664         * cfgloopanal.c (estimate_reg_pressure_cost): Remove flag_ira.
27665
27666         * toplev.h (flag_ira): Remove.
27667
27668         * caller-save.c (setup_save_areas): Remove flag_ira.
27669
27670         * ira-color.c (ira_reuse_stack_slot, ira_mark_new_stack_slot): Ditto.
27671
27672         * global.c: Remove the file.
27673
27674         * opts.c (decode_options): Remove flag_ira.
27675
27676         * hard-reg-set.h (losing_caller_save_reg_set): Remove.
27677
27678         * regmove.c: Modify file description.
27679         (find_use_as_address, try_auto_increment): Define them only if
27680         AUTO_INC_DEC is defined.
27681         (replacement_quality, replace_in_call_usage, fixup_match_1,
27682         stable_and_no_regs_but_for_p): Remove.
27683         (reg_set_in_bb): Make it static.
27684         (regmove_optimize): Remove flag_ira and code which worked for
27685         !flag_ira.
27686
27687         * local-alloc.c: Remove the file.
27688
27689         * common.opt (fira): Remove.
27690
27691         * ira.c: Include except.h.
27692         (eliminable_regset): Move from global.c.
27693         (mark_elimination): Ditto.  Remove flag_ira.
27694         (reg_renumber, struct equivalence, reg_equiv, equiv_mem,
27695         equiv_mem_modified, validate_equiv_mem_from_store,
27696         validate_equiv_mem, equiv_init_varies_p, equiv_init_movable_p,
27697         contains_replace_regs, memref_referenced_p, memref_used_between_p,
27698         no_equiv, recorded_label_ref): Move from local-alloc.c.
27699         (update_equiv_regs): Ditto.  Make it static.
27700         (print_insn_chain, print_insn_chains): Move it from global.c.
27701         (pseudo_for_reload_consideration_p): Ditto.  Remove flag_ira.
27702         (build_insn_chain): Ditto.  Make it static.
27703         (ra_init_live_subregs): Move from ra-conflict.c.  Make it static.
27704         Rename to init_live_subregs.
27705         (gate_ira): Remove flag_ira.
27706
27707         * regclass.c: Rename reginfo.c.  Change file description.
27708         (FORBIDDEN_INC_DEC_CLASSES): Remove.
27709         (reg_class_superclasses, forbidden_inc_dec_class, in_inc_dec): Remove.
27710         (init_reg_sets_1): Remove code for evaluation of
27711         reg_class_superclasses and losing_caller_save_reg_set.
27712         (init_regs): Remove init_reg_autoinc.
27713         (struct costs, costs, init_cost, ok_for_index_p_nonstrict,
27714         ok_for_base_p_nonstrict): Remove.
27715         (regclass_init): Rename to reginfo_init.  Don't initialize init_cost.
27716         (pass_regclass_init): Rename to pass_reginfo_init.  Modify
27717         corresponding entries.
27718         (dump_regclass, record_operand_costs, scan_one_insn,
27719         init_reg_autoinc, regclass, record_reg_classes, copy_cost,
27720         record_address_regs, auto_inc_dec_reg_p): Remove.
27721         (gt-regclass.h): Rename to gt-reginfo.h.
27722
27723         * rtl.h (dump_global_regs, retry_global_alloc,
27724         build_insn_chain, dump_local_alloc, update_equiv_regs): Remove.
27725
27726         * Makefile.in (RA_H): Remove.
27727         (OBJS-common): Remove global.o, local-alloc.o, and ra-conflict.o.
27728         Rename regclass.o to reginfo.o.
27729         (regclass.o): Rename to reginfo.o.  Rename gt-regclass.h to
27730         gt-reginfo.h.
27731         (global.o, local-alloc.o, ra-conflict.o): Remove entries.
27732         (GTFILES): Rename regclass.c to reginfo.c.
27733
27734         * passes.c (init_optimization_passes): Remove pass_local_alloc and
27735         pass_global_alloc.  Rename pass_regclass_init to pass_reginfo_init.
27736
27737         * reload1.c (compute_use_by_pseudos, reload, count_pseudo,
27738         count_spilled_pseudo, find_reg, alter_reg, delete_output_reload):
27739         Remove flag_ira.
27740         (finish_spills): Ditto.  Remove code for !flag_ira.
27741
27742 2009-01-29  Kenneth Zadeck  <zadeck@naturalbridge.com>
27743
27744         PR middle-end/35854
27745         * doc/invoke.texi (rtl debug options): Complete rewrite.
27746         * auto-inc-dec.c (pass_inc_dec): Rename pass from "auto-inc-dec"
27747         to auto_inc_dec".
27748         * mode-switching.c (pass_mode_switching): Rename pass from
27749         "mode-sw" to "mode_sw".
27750         * except.c (pass_convert_to_eh_ranges): Rename pass from
27751         "eh-ranges" to "eh_ranges".
27752         * lower-subreg.c (pass_lower_subreg): Renamed pass from "subreg"
27753         to "subreg1".
27754
27755
27756 2009-01-29  Andrey Belevantsev  <abel@ispras.ru>
27757             Alexander Monakov  <amonakov@ispras.ru>
27758
27759         PR middle-end/38857
27760         * sel-sched.c (count_occurrences_1): Check that *cur_rtx is a hard
27761         register.
27762         (move_exprs_to_boundary): Change return type and pass through
27763         should_move from move_op.  Relax assert.  Update usage ...
27764         (schedule_expr_on_boundary): ... here.  Use should_move instead of
27765         cant_move.
27766         (move_op_orig_expr_found): Indicate that insn was disconnected from
27767         stream.
27768         (code_motion_process_successors): Do not call after_merge_succs
27769         callback if original expression was not found when traversing any of
27770         the branches.
27771         (code_motion_path_driver): Change return type.  Update prototype.
27772         (move_op): Update comment.  Add a new parameter (should_move).  Update
27773         prototype.  Set *should_move based on indication provided by
27774         move_op_orig_expr_found.
27775
27776 2009-01-28  Pat Haugen  <pthaugen@us.ibm.com>
27777
27778         * doc/invoke.texi (avoid-indexed-addresses): Document new option.
27779         * config/rs6000/rs6000-protos.h (avoiding_indexed_address_p): Declare.
27780         * config/rs6000/rs6000.opt (avoid-indexed-addresses): New option.
27781         * config/rs6000/rs6000.c (rs6000_override_options): Default
27782         avoid-indexed-addresses on for Power6, off for everything else.
27783         (avoiding_indexed_address_p): New function.
27784         (rs6000_legitimize_address): Use it.
27785         (rs6000_legitimate_address): Likewise.
27786         * config/rs6000/rs6000.md (movXX_updateX): Likewise
27787
27788 2009-01-28  Kazu Hirata  <kazu@codesourcery.com>
27789
27790         PR tree-optimization/38997
27791         * tree-loop-distribution.c (generate_memset_zero): Use
27792         POINTER_PLUS_EXPR for a pointer addition.
27793
27794 2009-01-28  Andreas Krebbel  <krebbel1@de.ibm.com>
27795
27796         * config/s390/s390.md (bswap<mode>2): New pattern added.
27797
27798 2009-01-28  Wolfgang Gellerich  <gellerich@de.ibm.com>
27799
27800         * config/s390/s390.md (*tls_load_31): Added type attribute.
27801
27802 2009-01-28  Wolfgang Gellerich  <gellerich@de.ibm.com>
27803
27804         * config/s390/s390.md: Fix a few comments.
27805
27806 2009-01-28  Wolfgang Gellerich  <gellerich@de.ibm.com>
27807
27808         * config/s390/s390.md (*tmsi_reg): Fixed z10prop attribute.
27809         (*tm<mode>_full): Fixed z10prop attribute.
27810         (*tst<mode>_extimm): Fixed z10prop attribute.
27811         (*tst<mode>_cconly_extimm): Fixed z10prop attribute.
27812         (*tstqiCCT_cconly): Fixed z10prop attribute.
27813         (*cmpsi_ccu_zerohi_rlsi): Fixed z10prop attribute.
27814         (*movsi_larl): Fixed z10prop attribute.
27815         (*movsi_zarch): Fixed z10prop attribute.
27816         (*movsi_eas): Fixed z10prop attribute.
27817         (*movhi): Fixed z10prop attribute.
27818         (*movqi): Fixed z10prop attribute.
27819         (*movstrictqi): Fixed z10prop attribute.
27820         (*mov<mode>): Fixed z10prop attribute.
27821         (*movcc): Fixed z10prop attribute.
27822         (*sethighpartdi_64): Fixed z10prop attribute.
27823         (*zero_extendhi<mode>2_z10): Fixed z10prop attribute.
27824         (*negdi2_sign_cc): Fixed z10prop attribute.
27825         (*negdi2_sign): Fixed z10prop attribute.
27826         (*absdi2_sign_cc): Fixed z10prop attribute.
27827         (*absdi2_sign): Fixed z10prop attribute.
27828         (*negabsdi2_sign_cc): Fixed z10prop attribute.
27829         (*negabsdi2_sign): Fixed z10prop attribute.
27830         (*cmp_and_trap_signed_int<mode>): Fixed z10prop attribute.
27831         (*cmp_and_trap_unsigned_int<mode>): Fixed z10prop attribute.
27832         (doloop_si64): Fixed z10prop attribute.
27833         (doloop_si31): Fixed z10prop attribute.
27834         (doloop_long): Fixed z10prop attribute.
27835         (indirect_jump): Fixed z10prop attribute.
27836         (nop): Fixed z10prop attribute.
27837         (main_base_64): Fixed z10prop attribute.
27838         (reload_base_64): Fixed z10prop attribute.
27839
27840 2009-01-28  Jakub Jelinek  <jakub@redhat.com>
27841
27842         PR rtl-optimization/38740
27843         * reorg.c (gate_handle_delay_slots): Avoid dbr scheduling
27844         if !optimize.
27845         * config/mips/mips.c (mips_reorg): Likewise.
27846
27847 2009-01-28  Richard Guenther  <rguenther@suse.de>
27848
27849         PR tree-optimization/38926
27850         * tree-ssa-pre.c (add_to_value): Assert we add only expressions
27851         with the correct value id to a value.
27852         (do_regular_insertion): Use the value number of edoubleprime
27853         for the value number of the expr.
27854
27855         Revert
27856         2008-08-21  Richard Guenther  <rguenther@suse.de>
27857
27858         * tree-ssa-pre.c (insert_into_preds_of_block): Before inserting
27859         a PHI ask VN if it is already available.
27860         * tree-ssa-sccvn.h (vn_phi_lookup): Declare.
27861         * tree-ssa-sccvn.c (vn_phi_lookup): Export.
27862
27863 2009-01-28  Jakub Jelinek  <jakub@redhat.com>
27864
27865         PR middle-end/38934
27866         * tree-vrp.c (extract_range_from_assert): For LE_EXPR and LT_EXPR
27867         set to varying whenever max has TREE_OVERFLOW set, similarly
27868         for GE_EXPR and GT_EXPR and TREE_OVERFLOW min.
27869
27870 2009-01-28  Richard Guenther  <rguenther@suse.de>
27871
27872         PR middle-end/38908
27873         * tree-ssa.c (warn_uninitialized_var): Do not warn for seemingly
27874         uninitialized aggregate uses in call arguments.
27875
27876 2009-01-28  Paolo Bonzini  <bonzini@gnu.org>
27877
27878         PR tree-optimization/38984
27879         * tree-ssa-structalias.c (get_constraints_for_1): Do not use
27880         the nothing_id variable if -fno-delete-null-pointer-checks.
27881
27882 2009-01-28  Uros Bizjak  <ubizjak@gmail.com>
27883
27884         PR target/38988
27885         * config/i386/i386.md (set_rip_rex64): Wrap operand 1 in label_ref.
27886         (set_got_offset_rex64): Ditto.
27887
27888 2009-01-27  H.J. Lu  <hongjiu.lu@intel.com>
27889
27890         PR target/38941
27891         * doc/extend.texi: Improve local variable with asm reg.
27892
27893 2009-01-27  Adam Nemet  <anemet@caviumnetworks.com>
27894
27895         * c.opt (Wpacked-bitfield-compat): Change init value to -1.
27896         * c-opts.c (c_common_post_options): If -W*packed-bitfield-compat
27897         was not supplied then set warn_packed_bitfield_compat to the
27898         default value of 1.
27899         * stor-layout.c (place_field): Check warn_packed_bitfield_compat
27900         against 1.
27901
27902 2009-01-27  Richard Guenther  <rguenther@suse.de>
27903
27904         PR tree-optimization/38503
27905         * cfgexpand.c (expand_gimple_basic_block): Ignore
27906         GIMPLE_CHANGE_DYNAMIC_TYPE during expansion.
27907         * tree-ssa-structalias.c (set_uids_in_ptset): Do not prune
27908         variables that cannot have TBAA applied.
27909         (compute_points_to_sets): Do not remove GIMPLE_CHANGE_DYNAMIC_TYPE
27910         statements.
27911
27912 2009-01-27  Uros Bizjak  <ubizjak@gmail.com>
27913
27914         PR middle-end/38969
27915         * calls.c (initialize_argument_information): Do not wrap complex
27916         arguments in SAVE_EXPR.
27917
27918 2009-01-26  Andreas Tobler  <a.tobler@schweiz.org>
27919
27920         * config/t-vxworks (LIBGCC2_INCLUDES): Fix typo.
27921         (INSTALL_LIBGCC): Revert typo commit.
27922
27923 2009-01-26  Richard Guenther  <rguenther@suse.de>
27924
27925         PR tree-optimization/38745
27926         * tree-ssa-alias.c (update_alias_info_1): Exclude RESULT_DECL
27927         from special handling.
27928
27929 2009-01-26  Richard Guenther  <rguenther@suse.de>
27930
27931         PR tree-optimization/38745
27932         * tree-ssa.c (execute_update_addresses_taken): Do not include
27933         variables that cannot possibly be a register in not_reg_needs.
27934         Do not clear TREE_ADDRESSABLE on vars that may not become
27935         registers.
27936         * tree-ssa.c (update_alias_info_1): Include those in the set
27937         of addressable vars.
27938
27939 2009-01-26  Richard Guenther  <rguenther@suse.de>
27940
27941         PR middle-end/38851
27942         * Makefile.in (tree-ssa-dse.o): Add langhooks.h.
27943         * tree-ssa-dse.c: Include langhooks.h
27944         (execute_simple_dse): Remove stores with zero size.
27945
27946 2009-01-24  Jakub Jelinek  <jakub@redhat.com>
27947
27948         PR c/38957
27949         * c-typeck.c (c_finish_return): Handle POINTER_PLUS_EXPR the same way
27950         as PLUS_EXPR.
27951
27952 2009-01-24  Julian Brown  <julian@codesourcery.com>
27953
27954         * config/arm/t-linux-eabi (LIB2FUNCS_STATIC_EXTRA): Add
27955         config/arm/linux-atomic.c.
27956         * config/arm/linux-atomic.c: New.
27957
27958 2009-01-24  Eric Botcazou  <ebotcazou@adacore.com>
27959
27960         * config/sparc/linux.h (DBX_REGISTER_NUMBER): Delete.
27961         * config/sparc/linux64.h (DBX_REGISTER_NUMBER): Likewise.
27962         * config/sparc/sysv4.h (DBX_REGISTER_NUMBER): Likewise.
27963
27964 2009-01-24  H.J. Lu  <hongjiu.lu@intel.com>
27965
27966         PR c/38938
27967         * c-opts.c (c_common_handle_option): Update warn_pointer_sign
27968         properly.
27969
27970 2009-01-24  Sebastian Pop  <sebastian.pop@amd.com>
27971
27972         PR tree-optimization/38953
27973         * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
27974         (scop_adjust_phis_for_liveouts): Initialize false_i to zero.
27975         (gloog): Split the exit of the scop when the scop exit is a loop exit.
27976         (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
27977         changed the CFG.
27978
27979 2009-01-24  Paul Brook  <paul@codesourcery.com>
27980
27981         * config/arm/neon.md (neon_type): Move to arm.md.
27982         (neon_mov<VSTRUCT>): Add neon_type attribute.
27983         * config/arm/arm.md (neon_type): Move to here.
27984         (conds): Add "unconditioal" and use as default for NEON insns.
27985
27986 2009-01-24  Ben Elliston  <bje@au.ibm.com>
27987
27988         * bitmap.h (BITMAP_FREE): Eliminate `implicit conversion from
27989         void *' warning from -Wc++-compat.
27990         * Makefile.in (dominance.o-warn): Remove.
27991
27992 2009-01-23  Paolo Bonzini  <bonzini@gnu.org>
27993
27994         PR tree-optimization/38932
27995         * fold-const.c (fold_unary_ignore_overflow): New.
27996         * tree.h (fold_unary_ignore_overflow): Declare.
27997         * tree-ssa-ccp.c (ccp_fold): Use fold_unary_ignore_overflow.
27998         * tree-ssa-sccvn.c (visit_reference_op_load,
27999         simplify_unary_expression): Likewise.
28000
28001 2009-01-22  Adam Nemet  <anemet@caviumnetworks.com>
28002
28003         * c-decl.c (finish_struct): Move code to set DECL_PACKED after
28004         DECL_BIT_FIELD is alreay known.  Also inherit packed for bitfields
28005         regardless of their type.
28006         * c-common.c (handle_packed_attribute): Don't ignore packed on
28007         bitfields.
28008         * c.opt (Wpacked-bitfield-compat): New warning option.
28009         * stor-layout.c (place_field): Warn if offset of a field changed.
28010         * doc/extend.texi (packed): Mention the ABI change.
28011         * doc/invoke.texi (-Wpacked-bitfield-compat): Document.
28012         (Warning Options): Add it to the list.
28013
28014 2009-01-22  H.J. Lu  <hongjiu.lu@intel.com>
28015
28016         * c-opts.c (c_common_post_options): Fix a typo in comments.
28017
28018 2009-01-22  Steve Ellcey  <sje@cup.hp.com>
28019
28020         PR middle-end/38615
28021         * gimplify.c (gimplify_init_constructor): Fix promotion of const
28022         variables to static.
28023         * doc/invoke.texi (-fmerge-all-constants): Update description.
28024
28025 2009-01-22  Uros Bizjak  <ubizjak@gmail.com>
28026
28027         PR target/38931
28028         * config/i386/i386.md (*movsi_1): Use type "mmx" for alternative 2.
28029         (*movdi_1_rex64): Use type "mmx" for alternative 5.
28030
28031 2009-01-22  Richard Earnshaw  <rearnsha@arm.com>
28032
28033         * arm.h (DATA_ALIGNMENT): Align structures, unions and arrays to
28034         a word boundary.
28035         (LOCAL_ALIGNMENT): Similarly.
28036
28037 2009-01-22  Mark Shinwell  <shinwell@codesourcery.com>
28038             Joseph Myers  <joseph@codesourcery.com>
28039
28040         * config/arm/arm.c (all_architectures): Add iWMMXt2 entry.
28041         * config/arm/arm-cores.def: New ARM_CORE entry for iWMMXt2.
28042         * config/arm/arm-tune.md: Regenerate.
28043         * doc/invoke.texi (ARM Options): Document -mcpu=iwmmxt2 and
28044         -march=iwmmxt2.
28045
28046 2009-01-22  Mark Shinwell  <shinwell@codesourcery.com>
28047
28048         * config/arm/bpabi.h (SUBTARGET_EXTRA_ASM_SPEC): Bump EABI
28049         version number to five.
28050
28051 2009-01-22  Dodji Seketeli  <dodji@redhat.com>
28052
28053         PR c++/38930
28054         * c-decl.c (clone_underlying_type): Revert PR c++/26693 changes.
28055         * c-common.c (set_underlying_type): Likewise.
28056         (is_typedef_decl ): Likewise
28057         * tree.h: Likewise
28058         (set_underlying_type): Likewise.
28059         (is_typedef_type): Likewise.
28060
28061 2009-01-21  Vladimir Makarov  <vmakarov@redhat.com>
28062
28063         PR middle-end/38587
28064         * ira-color.c (coalesce_spill_slots): Don't coalesce allocnos
28065         crossing setjmps.
28066
28067 2009-01-21  Dave Korn  <dave.korn.cygwin@gmail.com>
28068
28069         PR bootstrap/37660
28070         * config/i386/cygwin.h (SHARED_LIBGCC_SPEC):  New helper macro.
28071         (LIBGCC_SPEC):  Don't define.
28072         (REAL_LIBGCC_SPEC):  Define instead, using SHARED_LIBGCC_SPEC.
28073
28074 2009-01-21  Uros Bizjak  <ubizjak@gmail.com>
28075
28076         PR rtl-optimization/38879
28077         * alias.c (base_alias_check): Unaligned access via AND address can
28078         alias all surrounding object types except those with sizes equal
28079         or wider than the size of unaligned access.
28080
28081 2009-01-21  Dodji Seketeli  <dodji@redhat.com>
28082
28083         PR c++/26693
28084         * c-decl.c (clone_underlying_type): Move this ...
28085         * c-common.c (set_underlying_type): ... here.
28086         Also, make sure the function properly sets TYPE_STUB_DECL() on
28087         the newly created typedef variant type.
28088         (is_typedef_decl ): New entry point.
28089         * tree.h: Added a new member member_types_needing_access_check to
28090         struct tree_decl_non_common.
28091         (set_underlying_type): New entry point.
28092         (is_typedef_type): Likewise.
28093
28094 2009-01-21  Bingfeng Mei  <bmei@broadcom.com>
28095
28096         * alias.c (walk_mems_1, walk_mems_2, insn_alias_sets_conflict_p):
28097         Check whether two instructions have memory references that
28098         belong to conflicting alias sets.  walk_mems_1 and walk_mems_2
28099         are helper functions for traversing.
28100         * alias.h (insn_alias_sets_confilict_p): New prototypes.
28101         * ddg.c (add_inter_loop_mem_dep): Call insn_alias_sets_conflict_p
28102         not to draw dependency edge for instructions with non-conflicting
28103         alias sets.
28104
28105 2009-01-20  Joseph Myers  <joseph@codesourcery.com>
28106
28107         PR other/38758
28108         * longlong.h: Update copyright years.  Use soft-fp license notice.
28109         Sync __clz_tab declaration with glibc.
28110
28111 2009-01-20  Steve Ellcey  <sje@cup.hp.com>
28112
28113         PR target/30687
28114         * doc/extend.texi (syscall_linkage): New.
28115         (version_id): Modify.
28116
28117 2009-01-20  Andrew Pinski  <andrew_pinski@playstation.sony.com>
28118             Richard Guenther  <rguenther@suse.de>
28119
28120         PR tree-optimization/38747
28121         PR tree-optimization/38748
28122         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Disable the VCE
28123         conversion if the base address is an indirect reference and the
28124         aliasing sets could cause issues.
28125
28126 2009-01-20  Sebastian Pop  <sebastian.pop@amd.com>
28127
28128         * common.opt (fgraphite, fgraphite-identity): Add comment for
28129         explaining why these options are not documented.
28130
28131 2009-01-20  Sebastian Pop  <sebastian.pop@amd.com>
28132
28133         * graphite.c (stmt_simple_for_scop_p): Also handle cases when
28134         gimple_call_lhs is NULL.
28135
28136 2009-01-20  Paolo Bonzini  <bonzini@gnu.org>
28137
28138         PR target/38868
28139         * emit-rtl.c (adjust_address_1): Make sure memref is never
28140         overwritten.
28141
28142 2009-01-20  Ben Elliston  <bje@au.ibm.com>
28143
28144         * libgcov.c (__gcov_execl, __gcov_execlp, __gcov_execle): Remove
28145         const qualifier from arg parameter. Remove unnecessary cast to char *.
28146         * gcov-io.h (__gcov_execl, __gcov_execlp, __gcov_execle): Remove
28147         const qualifier from arg 2.
28148
28149 2009-01-19  Iain Sandoe  <iain.sandoe@sandoe-acoustics.co.uk>
28150
28151         * config/darwin.h: Add static-libgfortran to LINK_SPEC.
28152
28153 2009-01-19  Vladimir Makarov  <vmakarov@redhat.com>
28154
28155         PR c/38869
28156         * rtl.h (reinit_regs): New prototype.
28157         * regclass.c: Include ira.h.
28158         (reinit_regs): New.
28159         * Makefile.in (regclass.o): Add ira.h.
28160         * config/i386/i386.c (ix86_maybe_switch_abi): Use reinit_regs.
28161
28162 2009-01-18  H.J. Lu  <hongjiu.lu@intel.com>
28163
28164         PR target/38736
28165         * c-common.c (handle_aligned_attribute): Use
28166         ATTRIBUTE_ALIGNED_VALUE instead of BIGGEST_ALIGNMENT for
28167         default alignment value.
28168
28169         * c-cppbuiltin.c (c_cpp_builtins): Define __BIGGEST_ALIGNMENT__.
28170
28171         * defaults.h (ATTRIBUTE_ALIGNED_VALUE): New.
28172         * config/i386/i386.h (ATTRIBUTE_ALIGNED_VALUE): Likewise.
28173
28174         * doc/extend.texi: Update __attribute__ ((aligned)).  Document
28175         __BIGGEST_ALIGNMENT__.
28176
28177         * doc/tm.texi: Document ATTRIBUTE_ALIGNED_VALUE.
28178
28179 2009-01-18  Richard Guenther  <rguenther@suse.de>
28180
28181         PR tree-optimization/38819
28182         * tree-flow.h (operation_could_trap_helper_p): Declare.
28183         * tree-eh.c (operation_could_trap_helper_p): Export.
28184         * tree-ssa-sccvn.h (vn_nary_may_trap): Declare.
28185         * tree-ssa-sccvn.c (vn_nary_may_trap): New function.
28186         * tree-ssa-pre.c (insert_into_preds_of_block): Check if we
28187         are about to insert a possibly trapping instruction and fail
28188         in this case.
28189
28190 2009-01-18  Andreas Schwab  <schwab@suse.de>
28191
28192         * doc/install.texi (Configuration): Remove obsolete paragraph
28193         about use of --with-gnu-ld with --with-gnu-as.
28194
28195 2009-01-18  Kazu Hirata  <kazu@codesourcery.com>
28196
28197         * doc/extend.texi, doc/gimple.texi, doc/invoke.texi,
28198         doc/md.texi, doc/sourcebuild.texi, doc/tm.texi: Fix typos.
28199         Follow spelling conventions.
28200
28201 2009-01-18  Ben Elliston  <bje@au.ibm.com>
28202
28203         * bitmap.c (bitmap_obstack_alloc_stat): Adjust cast to eliminate
28204         C++ warning about implicit conversion from void * to struct
28205         bitmap_head_def *.
28206         (bitmap_obstack_free): Likewise for bitmap_element *.
28207         * Makefile.in (bitmap.o-warn): Remove.
28208
28209 2009-01-17  Dave Korn  <dave.korn.cygwin@gmail.com>
28210
28211         * Makefile.in (BACKENDLIBS):  Reorder to match dependencies.
28212
28213 2009-01-17  Sebastian Pop  <sebastian.pop@amd.com>
28214             Tobias Grosser  <tobi.grosser@amd.com>
28215
28216         * graphite.c (graphite_trans_scop_block): Do not block single
28217         nested loops.
28218
28219 2009-01-16  Alexandre Oliva  <aoliva@redhat.com>
28220
28221         * ebitmap.h (ebitmap_iter_init): Initialize all fields.
28222         * ipa-struct-reorg.c (gen_struct_type): Replace known-true
28223         test with assertion.
28224
28225 2009-01-16  Richard Guenther  <rguenther@suse.de>
28226
28227         PR tree-optimization/38835
28228         PR middle-end/36227
28229         * fold-const.c (fold_binary): Remove PTR + INT -> (INT)(PTR p+ INT)
28230         and INT + PTR -> (INT)(PTR p+ INT) folding.
28231         * tree-ssa-address.c (create_mem_ref): Properly use POINTER_PLUS_EXPR.
28232
28233 2009-01-16  Adam Nemet  <anemet@caviumnetworks.com>
28234
28235         PR target/38554
28236         * expmed.c (expand_shift): With SHIFT_COUNT_TRUNCATED, don't lift
28237         the subreg from a lowpart subreg if it is also casting the value.
28238
28239 2009-01-16  Sebastian Pop  <sebastian.pop@amd.com>
28240             Tobias Grosser  <tobi.grosser@amd.com>
28241
28242         * graphite.c (compare_prefix_loops): New.
28243         (build_scop_canonical_schedules): Rewritten.
28244         (graphite_transform_loops): Move build_scop_canonical_schedules
28245         after build_scop_iteration_domain.
28246
28247 2009-01-16  Sebastian Pop  <sebastian.pop@amd.com>
28248             Tobias Grosser  <tobi.grosser@amd.com>
28249
28250         * graphite.c (add_conditions_to_domain): Add the loops to
28251         the dimension of the iteration domain.  Do copy the domain
28252         only when it exists.
28253         (build_scop_conditions_1): Do not call add_conditions_to_domain.
28254         (add_conditions_to_constraints): New.
28255         (can_generate_code_stmt, can_generate_code): Removed.
28256         (gloog): Do not call can_generate_code.
28257         (graphite_transform_loops): Call add_conditions_to_constraints
28258         after building the iteration domain.
28259
28260 2009-01-16  Jakub Jelinek  <jakub@redhat.com>
28261
28262         PR tree-optimization/38789
28263         * tree-ssa-threadedge.c
28264         (record_temporary_equivalences_from_stmts_at_dest): Ignore calls to
28265         __builtin_constant_p.
28266
28267 2009-01-16  Kenneth Zadeck  <zadeck@naturalbridge.com>
28268
28269         * dce.c (delete_unmarked_insns): Reversed the order that insns are
28270         examined before deleting them.
28271
28272 2009-01-16  Richard Earnshaw  <rearnsha@arm.com>
28273
28274         * function.c (aggregate_value_p): Correctly extract the function
28275         type from CALL_EXPR_FN lookup.
28276
28277 2009-01-16  Hariharan Sandanagobalane  <hariharan@picochip.com>
28278
28279         * config/picochip/picochip.c (picochip_override_options): Revert
28280         CFI asm flag disable commited previously.
28281
28282 2009-01-15  Sebastian Pop  <sebastian.pop@amd.com>
28283             Tobias Grosser  <tobi.grosser@amd.com>
28284             Jan Sjodin  <jan.sjodin@amd.com>
28285
28286         * graphite.c (scan_tree_for_params): On substractions negate
28287         all the coefficients of the term.
28288         (clast_to_gcc_expression_red): New.  Handle reduction expressions
28289         of more than two operands.
28290         (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
28291         (get_vdef_before_scop): Handle also the case of default definitions.
28292
28293 2009-01-15  Richard Sandiford  <rdsandiford@googlemail.com>
28294
28295         * caller-save.c (add_used_regs_1, add_used_regs): New functions.
28296         (insert_one_insn): Use them instead of REG_DEAD and REG_INC notes.
28297         Also use them when walking CALL_INSN_FUNCTION_USAGE.
28298
28299 2009-01-15  H.J. Lu  <hongjiu.lu@intel.com>
28300             Joey Ye  <joey.ye@intel.com>
28301
28302         PR middle-end/37843
28303         * cfgexpand.c (expand_stack_alignment): Don't update stack
28304         boundary nor check incoming stack boundary here.
28305         (gimple_expand_cfg): Update stack boundary and check incoming
28306         stack boundary here.
28307
28308 2009-01-15  Kenneth Zadeck  <zadeck@naturalbridge.com>
28309
28310         * dce.c (find_call_stack_args, delete_unmarked_insns): Fixed comments.
28311
28312 2009-01-14  Jakub Jelinek  <jakub@redhat.com>
28313
28314         PR rtl-optimization/38245
28315         * calls.c (expand_call): Add stack arguments to
28316         CALL_INSN_FUNCTION_USAGE even for pure calls (when
28317         ACCUMULATE_OUTGOING_ARGS) and even for args partially passed
28318         in regs and partially in memory or BLKmode arguments.
28319         (emit_library_call_value_1): Add stack arguments to
28320         CALL_INSN_FUNCTION_USAGE even for pure calls (when
28321         ACCUMULATE_OUTGOING_ARGS).
28322         * dce.c: Include tm_p.h.
28323         (find_call_stack_args): New function.
28324         (deletable_insn_p): Call it for CALL_P insns.  Add ARG_STORES
28325         argument.
28326         (mark_insn): Call find_call_stack_args for CALL_Ps.
28327         (prescan_insns_for_dce): Walk insns backwards in bb rather than
28328         forwards.  Allocate and free arg_stores bitmap if needed, pass it
28329         down to deletable_insn_p, don't mark stores set in arg_stores
28330         bitmap, clear the bitmap at the beginning of each bb.
28331         * Makefile.in (dce.o): Depend on $(TM_P_H).
28332
28333 2009-01-14  Michael Meissner  <gnu@the-meissners.org>
28334
28335         PR target/22599
28336         * config/i386/i386.c (print_operand): Add tests for 'D', 'C', 'F', 'f'
28337         to make sure the insn is a conditional test (bug 22599).  Reformat a
28338         few long lines.
28339
28340 2009-01-14  Sebastian Pop  <sebastian.pop@amd.com>
28341
28342         PR middle-end/38431
28343         * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
28344         (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
28345         (gloog): Do not call cleanup_tree_cfg.
28346         (graphite_transform_loops): Call cleanup_tree_cfg after all
28347         scops have been code generated.
28348
28349 2009-01-14  Basile Starynkevitch  <basile@starynkevitch.net>
28350         * doc/gty.texi (Invoking the garbage collector): Added new node
28351         and section documenting ggc_collect.
28352
28353 2009-01-14  Richard Guenther  <rguenther@suse.de>
28354
28355         PR tree-optimization/38826
28356         PR middle-end/38477
28357         * tree-ssa-structalias.c (emit_alias_warning): Emit the pointer
28358         initialization notes only if we actually emitted a warning.
28359         (intra_create_variable_infos): Add constraints for a result decl
28360         that is passed by hidden reference.
28361         (build_pred_graph): Mark all related variables non-direct on
28362         address-taking.
28363
28364 2009-01-14  Nick Clifton  <nickc@redhat.com>
28365
28366         * ira-conflicts.c: Include addresses.h for the definition of
28367         base_reg_class.
28368         (ira_build_conflicts): Use base_reg_class instead of BASE_REG_CLASS.
28369         * Makefile.in: Add a dependency of ira-conflicts.o on addresses.h.
28370
28371 2009-01-13  Vladimir Makarov  <vmakarov@redhat.com>
28372
28373         PR target/38811
28374         * Makefile.in (ira-lives.o): Add except.h.
28375
28376         * ira-lives.c: Include except.h.
28377         (process_bb_node_lives): Process can_throw_internal.
28378
28379 2009-01-13  Jakub Jelinek  <jakub@redhat.com>
28380
28381         PR rtl-optimization/38774
28382         * combine.c (simplify_set): When undoing cc_use change, don't do
28383         PUT_CODE on the newly created comparison, but instead put back the
28384         old comparison.
28385
28386 2009-01-13  Joseph Myers  <joseph@codesourcery.com>
28387
28388         * doc/invoke.texi (ARM Options): Update lists of -mcpu and -march
28389         values.  Remove duplicate arm8 entry.
28390
28391 2009-01-13  Sebastian Pop  <sebastian.pop@amd.com>
28392
28393         PR tree-optimization/38786
28394         * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
28395         the SSA_NAME case of expand_scalar_variables_expr.
28396         Set the type of an expression to the type of its assign statement.
28397         (expand_scalar_variables_expr): Also gather the scalar computation
28398         used to index the memory access.  Do not pass loop_p.
28399         Fix comment.  Stop recursion on tcc_constant or tcc_declaration.
28400         (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
28401         the gimple_stmt_iterator where it inserts new code.
28402         Do not pass loop_p.
28403         (copy_bb_and_scalar_dependences): Do not pass loop_p.
28404         (translate_clast): Update call to copy_bb_and_scalar_dependences.
28405
28406 2009-01-13  Sebastian Pop  <sebastian.pop@amd.com>
28407
28408         * graphite.h (debug_value): Removed.
28409         * graphite.c (debug_value): Removed.
28410
28411 2009-01-13  Richard Earnshaw  <rearnsha@arm.com>
28412
28413         * config/arm/arm.c (output_move_double): Don't synthesize thumb-2
28414         ldrd/strd with two 32-bit instructions.
28415
28416 2009-01-13  Richard Earnshaw  <rearnsha@arm.com>
28417
28418         * config/arm/arm.c (struct processors): Pass for speed down into
28419         cost helper functions.
28420         (const_ok_for_op): Handle COMPARE and inequality nodes.
28421         (arm_rtx_costs_1): Rewrite.
28422         (arm_size_rtx_costs): Update prototype.
28423         (arm_rtx_costs): Pass speed down to helper functions.
28424         (arm_slowmul_rtx_costs): Rework cost calculations.
28425         (arm_fastmul_rtx_costs, arm_xscale_rtx_costs): Likewise.
28426         (arm_9e_rtx_costs): Likewise.
28427
28428 2009-01-13  Uros Bizjak  <ubizjak@gmail.com>
28429
28430         * config/alpha/alpha.c (alpha_legitimate_address_p): Explicit
28431         relocations of local symbols wider than UNITS_PER_WORD are not valid.
28432         (alpha_legitimize_address): Do not split local symbols wider than
28433         UNITS_PER_WORD into HIGH/LO_SUM parts.
28434
28435 2009-01-13  Danny Smith  <dannysmith@users.sourceforge.net>
28436
28437         PR bootstrap/38580
28438         * gcc.c (process_command): Replace call to execvp with calls
28439         to pex_one and exit.
28440
28441 2009-01-03  Anatoly Sokolov  <aesok@post.ru>
28442
28443         PR target/29141
28444         * config/avr/t-avr (LIB1ASMFUNCS): Add _tablejump_elpm.
28445         * config/avr/libgcc.S (__do_global_ctors, __do_global_dtors): Add
28446         variant for devices with 3-byte PC.
28447         (__tablejump_elpm__): New.
28448
28449 2009-01-12  Jakub Jelinek  <jakub@redhat.com>
28450
28451         PR c/32041
28452         * c-parser.c (c_parser_postfix_expression): Allow `->' in
28453         offsetof member-designator, handle it as `[0].'.
28454
28455 2009-01-12  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
28456
28457         * pa.c (pa_asm_output_mi_thunk): Use pc-relative branch to thunk
28458         function when not using named sections on targets with named sections
28459         if branch distance is less than 262132.
28460
28461 2009-01-12  Richard Earnshaw  <rearnsha@arm.com>
28462
28463         * combine.c (combine_instructions):  Recompute
28464         optimize_this_for_speed_p  for each BB in the main combine loop.
28465
28466 2009-01-12  Tomas Bily  <tbily@suse.cz>
28467
28468         PR middlend/38385
28469         * tree-loop-distribution.c (prop_phis): New function.
28470         (generate_builtin): Call prop_phis.
28471
28472 2009-01-12  Jakub Jelinek  <jakub@redhat.com>
28473
28474         PR tree-optimization/38807
28475         * tree-ssa-reassoc.c (remove_visited_stmt_chain): Don't look at
28476         gimple_visited_p unless stmt is GIMPLE_ASSIGN.
28477
28478 2009-01-11  Adam Nemet  <anemet@caviumnetworks.com>
28479
28480         * expmed.c (store_bit_field_1): Properly truncate the paradoxical
28481         subreg of op0 to the original op0.
28482
28483 2009-01-11  Laurent GUERBY  <laurent@guerby.net>
28484
28485         * doc/sourcebuild.texi (Source Tree): Move up intl and fixinc.
28486
28487 2009-01-11  Markus Schoepflin  <markus.schoepflin@comsoft.de>
28488
28489         PR debug/7055
28490         * mips-tfile.c (parse_def): Fix parsing of def strings
28491         starting with digits.
28492
28493 2009-01-10  Jakub Jelinek  <jakub@redhat.com>
28494
28495         PR target/38695
28496         * config/arm/arm.c (arm_is_long_call_p): Don't call
28497         arm_function_in_section_p if decl isn't a FUNCTION_DECL.
28498
28499 2009-01-09  Steven Bosscher  <steven@gcc.gnu.org>
28500
28501         * regrename.c (regrename_optimize): Fix dumping.
28502         (find_oldest_value_reg): Preserve REG_POINTER.
28503         (copy_hardreg_forward_1): Likewise.
28504
28505 2009-01-09  Diego Novillo  <dnovillo@google.com>
28506
28507         * gimple.h (struct gimple_statement_base) <uid>: Document
28508         the restrictions on its use.
28509         (gimple_uid): Tidy.
28510         (gimple_set_uid): Tidy.
28511
28512 2009-01-09  Jakub Jelinek  <jakub@redhat.com>
28513
28514         * config/i386/i386.c (ix86_expand_movmem, ix86_expand_setmem): Add
28515         zero guard even if align_bytes != 0 and count is smaller than
28516         size_needed.
28517
28518 2009-01-09  Vladimir Makarov  <vmakarov@redhat.com>
28519
28520         PR rtl-optimization/38495
28521         * ira-emit.c (print_move_list, ira_debug_move_list): New functions.
28522         (add_range_and_copies_from_move_list): Print all added ranges.
28523         Add ranges to memory optimized destination.
28524
28525 2009-01-09  Jakub Jelinek  <jakub@redhat.com>
28526
28527         PR target/38686
28528         PR target/38708
28529         * config/i386/i386.c (override_options): Reject
28530         -mstringop-strategy=rep_8byte with -m32.
28531         (ix86_expand_movmem): For size_needed == 1 set epilogue_size_needed
28532         to 1.  Do count comparison against epilogue_size_needed at compile
28533         time even when count_exp was constant forced into register.  For
28534         size_needed don't jump to epilogue, instead just avoid aligning
28535         and invoke the body algorithm.  If need_zero_guard, add zero guard
28536         even if count is non-zero, but smaller than size_needed + number of
28537         bytes that could be stored for alignment.
28538         (ix86_expand_setmem): For size_needed == 1 set epilogue_size_needed
28539         to 1.  If need_zero_guard, add zero guard even if count is non-zero,
28540         but smaller than size_needed + number of bytes that could be stored
28541         for alignment.  Compare size_needed with epilogue_size_needed instead
28542         of desired_align - align, don't adjust size_needed, pass
28543         epilogue_size_needed to the epilogue expanders.
28544
28545         PR c/35742
28546         * c-pretty-print.c (pp_c_expression): Handle GOTO_EXPR like BIND_EXPR.
28547
28548 2009-01-09  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
28549
28550         * pa.c (last_address): Change to unsigned.
28551         (update_total_code_bytes): Change argument to unsigned.  Don't
28552         check if insn addresses are set.
28553         (pa_output_function_epilogue): Set last_address to UINT_MAX if insn
28554         addresses are not set.
28555         (pa_asm_output_mi_thunk): Handle wrap when updating last_address.
28556
28557 2009-01-09  Nick Clifton  <nickc@redhat.com>
28558
28559         * config/sh/symbian.c: Replace uses of DECL_INLINE with
28560         DECL_DECLARED_INLINE_P.
28561
28562 2009-01-09  Jakub Jelinek  <jakub@redhat.com>
28563
28564         PR middle-end/38347
28565         * dojump.c (do_jump_by_parts_zero_rtx): Use mode instead of
28566         GET_MODE (op0) in operand_subword_force calls.
28567
28568         PR middle-end/38771
28569         * fold-const.c (fold_unary): For COMPOUND_EXPR and COND_EXPR,
28570         fold_convert arg0 operands to TREE_TYPE (op0) first.
28571
28572 2009-01-08  Vladimir Makarov  <vmakarov@redhat.com>
28573
28574         * params.def (ira-max-conflict-table-size): Decrease default value
28575         to 1000.
28576
28577 2009-01-08  Jakub Jelinek  <jakub@redhat.com>
28578
28579         PR tree-optimization/37031
28580         * lambda-code.c (lambda_collect_parameters): Call pointer_set_destroy
28581         on parameter_set.
28582         (build_access_matrix): Reserve correct size for AM_MATRIX vector,
28583         allocate it using gc instead of heap, use VEC_quick_push instead of
28584         VEC_safe_push.
28585         * graphite.c (build_access_matrix): Allocate AM_MATRIX vector using gc
28586         instead of heap, use VEC_quick_push instead of VEC_safe_push.
28587         * tree-data-ref.h (struct access_matrix): Change matrix to gc
28588         allocated vector from heap allocated.
28589         * lambda.h: Add DEF_VEC_ALLOC_P for gc allocated lambda_vector.
28590         * tree-loop-linear.c (linear_transform_loops): Allocate nest
28591         vector only after perfect_loop_nest_depth call.
28592
28593 2009-01-08  Sebastian Pop  <sebastian.pop@amd.com>
28594             Jan Sjodin  <jan.sjodin@amd.com>
28595
28596         PR tree-optimization/38559
28597         * graphite.c (debug_value, copy_constraint,
28598         swap_constraint_variables, scale_constraint_variable, ): New.
28599         (get_lower_bound, get_upper_bound): Removed.
28600         (graphite_trans_bb_strip_mine): Clean up this code that works
28601         only for constant number of iterations.  Fully copy upper and
28602         lower bound constraints, not only the constant part of them.
28603         * graphite.h (debug_value): Declared.
28604
28605 2009-01-08  Ira Rosen  <irar@il.ibm.com>
28606
28607         PR tree-optimization/37194
28608         * tree-vect-transform.c (vect_estimate_min_profitable_iters):
28609         Don't add the cost of cost model guard in prologue to scalar
28610         outside cost in case of known number of iterations.
28611
28612 2009-01-07  Nathan Froyd  <froydnj@codesourcery.com>
28613             Alan Modra  <amodra@bigpond.net.au>
28614
28615         * config/rs6000/rs6000.c (rs6000_legitimize_address): Check for
28616         non-word-aligned REG+CONST addressing.
28617
28618 2009-01-07  Uros Bizjak  <ubizjak@gmail.com>
28619
28620         PR target/38706
28621         * config/alpha/alpha.c (alpha_end_function): For TARGET_ABI_OSF, call
28622         free_after_compilation when outputting a thunk.
28623         (alpha_output_mi_thunk_osf): Assert that we are processing a thunk.
28624         Do not call free_after_compilation here.
28625
28626 2009-01-07  Uros Bizjak  <ubizjak@gmail.com>
28627
28628         * config/i386/i386.c (ix86_target_string): Use ARRAY_SIZE.
28629         (ix86_valid_target_attribute_inner_p): Ditto.
28630
28631 2009-01-07  Jan Sjodin  <jan.sjodin@amd.com>
28632
28633         PR tree-optimization/38492
28634         PR tree-optimization/38498
28635         * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
28636         * tree-chrec.h (scev_is_linear_expression): Declared.
28637         * graphite.c (graphite_cannot_represent_loop_niter): New.
28638         (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
28639         (graphite_loop_normal_form): Use gcc_assert.
28640         (scan_tree_for_params): Use CASE_CONVERT.
28641         (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
28642         (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
28643         Use gcc_assert.  Discard scops that contain unhandled cases.
28644         (build_scop_conditions): Return a boolean status for unhandled cases.
28645         (strip_mine_profitable_p): Print the loop number, not its depth.
28646         (is_interchange_valid): Pass the depth of the loop nest, don't
28647         recompute it wrongly.
28648         (graphite_trans_bb_block): Same.
28649         (graphite_trans_bb_block): Print tentative of loop blocking.
28650         (graphite_trans_scop_block): Do not print that the loop has been
28651         blocked.
28652         (graphite_transform_loops): Do not handle scops that contain condition
28653         scalar phi nodes.
28654
28655 2009-01-07  H.J. Lu  <hongjiu.lu@intel.com>
28656
28657         AVX Programming Reference (December, 2008)
28658         * config/i386/avxintrin.h (_mm256_stream_si256): New.
28659         (_mm256_stream_pd): Likewise.
28660         (_mm256_stream_ps): Likewise.
28661
28662         * config/i386/i386.c (ix86_builtins): Add IX86_BUILTIN_MOVNTDQ256,
28663         IX86_BUILTIN_MOVNTPD256 and IX86_BUILTIN_MOVNTPS256.
28664         (ix86_special_builtin_type): Add VOID_FTYPE_PV4DI_V4DI.
28665         (bdesc_special_args): Add __builtin_ia32_movntdq256,
28666         __builtin_ia32_movntpd256 and __builtin_ia32_movntps256.
28667         (ix86_init_mmx_sse_builtins): Handle VOID_FTYPE_PV4DI_V4DI.
28668         (ix86_expand_special_args_builtin): Likewise.
28669
28670         * config/i386/sse.md (AVXMODEDI): New.
28671         (avx_movnt<mode>): Likewise.
28672         (avx_movnt<mode>): Likewise.
28673         (<sse>_movnt<mode>): Remove AVX support.
28674         (sse2_movntv2di): Likewise.
28675
28676 2009-01-07  Richard Guenther  <rguenther@suse.de>
28677
28678         PR middle-end/38751
28679         * fold-const.c (extract_muldiv): Remove obsolete comment.
28680         (fold_plusminus_mult_expr): Undo MINUS_EXPR
28681         to PLUS_EXPR canonicalization for the canonicalization.
28682
28683 2009-01-07  Gerald Pfeifer  <gerald@pfeifer.com>
28684
28685         * doc/install.texi (alpha*-dec-osf*): Remove note on 32-bit
28686         hosted cross-compilers generating less efficient code.
28687
28688 2009-01-06  Richard Sandiford  <rdsandiford@googlemail.com>
28689
28690         * function.h (rtl_data): Add a dbr_scheduled_p field.
28691         * reorg.c (dbr_schedule): Set it.
28692         (gate_handle_delay_slots): Check it.
28693         * config/mips/mips.c (mips_base_delayed_branch): Delete.
28694         (mips_reorg): Check flag_delayed_branch instead of
28695         mips_base_delayed_branch.
28696         (mips_override_options): Don't set mips_base_delayed_branch
28697         or flag_delayed_branch.
28698
28699 2009-01-06  Richard Sandiford  <rdsandiford@googlemail.com>
28700
28701         PR rtl-optimization/38426.
28702         * ira.c (ira): Set current_function_is_leaf earlier.
28703
28704 2009-01-06  Jakub Jelinek  <jakub@redhat.com>
28705
28706         PR rtl-optimization/38722
28707         * combine.c (try_combine): Don't modify PATTERN (i3) and notes
28708         too early, only set a flag and modify after last possible
28709         undo_all point.
28710
28711 2009-01-06  Janis Johnson  <janis187@us.ibm.com>
28712
28713         PR c/34252
28714         * ginclude/float.h: Rename DECnn_DEN to DECnn_SUBNORMAL_MIN.
28715         * real.c (decimal_single_format): Correct values of emin and emax.
28716         (decimal_double_format): Ditto.
28717         (decimal_quad_format): Ditto.
28718         * c-cppbuiltin.c (builtin_define_decimal_float_constants): Adjust
28719         computation of DECnn_MIN and DECnn_MAX for corrected values of
28720         emin and emax.  Define __DECnn_SUBNORMAL_MIN__ instead of
28721         __DECnn_MIN__, and adjust its computation for the corrected value
28722         of emin.
28723
28724 2009-01-06  Jan Hubicka  <jh@suse.cz>
28725
28726         PR target/38744
28727         * config/i386/i386.c (ix86_expand_call): Use ARRAY_SIZE.
28728
28729 2009-01-06  Gerald Pfeifer  <gerald@pfeifer.com>
28730
28731         * doc/contrib.texi (Contributors): Slightly adjust the end note.
28732         Add Robert Clark to the list of testers.
28733
28734 2009-01-06  Jan Hubicka  <jh@suse.cz>
28735             Kai Tietz  <kai.tietz@onevision.com>
28736
28737         * config/i386/i386.md (*msabi_syvabi): Add SSE regs clobbers.
28738         * config/i386/i386.c (ix86_expand_call): Add clobbers.
28739
28740 2009-01-06  Jan Hubicka  <jh@suse.cz>
28741             Kai Tietz  <kai.tietz@onevision.com>
28742
28743         * config/i386/i386.h (CONDITIONAL_CALL_USAGE): SSE regs are not used
28744         for w64 ABI.
28745         * config/i386/i386.c (struct ix86_frame): Add padding0 and nsseregs.
28746         (ix86_nsaved_regs): Count only general purpose regs.
28747         (ix86_nsaved_sseregs): New.
28748         (ix86_compute_frame_layout): Update nsseregs; set preferred alignment
28749         to 16 for w64; compute padding and size of sse reg save area.
28750         (ix86_emit_save_regs, ix86_emit_save_regs_using_mov): Save only
28751         general purpose regs.
28752         (ix86_emit_save_sse_regs_using_mov): New.
28753         (ix86_expand_prologue): Save SSE regs if needed.
28754         (ix86_emit_restore_regs_using_mov): Use only general purpose regs.
28755         (ix86_emit_restore_sse_regs_using_mov): New.
28756         (ix86_expand_epilogue): Save SSE regs if needed.
28757
28758 2009-01-06  Jan Hubicka  <jh@suse.cz>
28759             Kai Tietz  <kai.tietz@onevision.com>
28760
28761         * config/i386/i386.h (ACCUMULATE_OUTGOING_ARGS): Enable for MSABI
28762         * config/i386/i386.c (init_cumulative_args): Disallow calls of MSABI
28763         functions when accumulate outgoing args is off.
28764
28765 2009-01-06  H.J. Lu  <hongjiu.lu@intel.com>
28766
28767         PR bootstrap/38742
28768         * ira-color.c (ira_reuse_stack_slot): Check ENABLE_IRA_CHECKING
28769         before using pseudos_have_intersected_live_ranges_p.
28770
28771         * ira-int.h (ira_assert): Always define.
28772
28773 2009-01-06  H.J. Lu  <hongjiu.lu@intel.com>
28774
28775         AVX Programming Reference (December, 2008)
28776         * config/i386/avxintrin.h (_mm_permute2_pd): Removed.
28777         (_mm256_permute2_pd): Likewise.
28778         (_mm_permute2_ps): Likewise.
28779         (_mm256_permute2_ps): Likewise.
28780         * config/i386/i386.md (UNSPEC_VPERMIL2): Likewise.
28781         * config/i386/sse.md (avx_vpermil2<mode>3): Likewise.
28782
28783         * config/i386/i386.c (ix86_builtins): Remove
28784         IX86_BUILTIN_VPERMIL2PD, IX86_BUILTIN_VPERMIL2PS,
28785         IX86_BUILTIN_VPERMIL2PD256 and IX86_BUILTIN_VPERMIL2PS256.
28786         (ix86_builtin_type): Remove V8SF_FTYPE_V8SF_V8SF_V8SI_INT,
28787         V4DF_FTYPE_V4DF_V4DF_V4DI_INT, V4SF_FTYPE_V4SF_V4SF_V4SI_INT
28788         and V2DF_FTYPE_V2DF_V2DF_V2DI_INT.
28789         (bdesc_args): Remove __builtin_ia32_vpermil2pd,
28790         __builtin_ia32_vpermil2ps, __builtin_ia32_vpermil2pd256 and
28791         __builtin_ia32_vpermil2ps256.
28792         (ix86_init_mmx_sse_builtins): Updated.
28793         (ix86_expand_args_builtin): Likewise.
28794
28795 2009-01-05  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
28796
28797         * pa.c (output_call): Relocate non-jump insns in the delay slot of
28798         long absolute calls when generating PA 2.0 code.
28799
28800 2009-01-05  Vladimir Makarov  <vmakarov@redhat.com>
28801
28802         PR rtl-optimization/38583
28803         * params.h (IRA_MAX_CONFLICT_TABLE_SIZE): New macro.
28804
28805         * params.def (ira-max-conflict-table-size): New.
28806
28807         * doc/invoke.texi (ira-max-conflict-table-size): Decribe.
28808
28809         * ira.h (ira_conflicts_p): New external definition.
28810
28811         * ira-conflicts.c (build_conflict_bit_table): Do not build too big
28812         table.  Report this.  Return result of building.
28813         (ira_build_conflicts): Use ira_conflicts_p.  Check result of
28814         building conflict table.
28815
28816         * ira-color.c (fast_allocation): Use num instead of ira_allocnos_num.
28817         (ira_color): Use ira_conflicts_p.
28818
28819         * global.c: Include ira.h.
28820         (pseudo_for_reload_consideration_p, build_insn_chain): Use
28821         ira_conflicts_p.
28822
28823         * Makefile.in (global.o): Add ira.h.
28824
28825         * ira-build.c (mark_all_loops_for_removal,
28826         propagate_some_info_from_allocno): New.
28827         (remove_unnecessary_allocnos): Call
28828         propagate_some_info_from_allocno.
28829         (remove_low_level_allocnos): New.
28830         (remove_unnecessary_regions): Add parameter.  Call
28831         mark_all_loops_for_removal and remove_low_level_allocnos.  Pass
28832         parameter to remove_unnecessary_regions.
28833         (ira_build): Remove all regions but root if the conflict table was
28834         not built.  Update conflict hard regs for allocnos crossing calls.
28835
28836         * ira.c (ira_conflicts_p): New global.
28837         (ira): Define and use ira_conflicts_p.
28838
28839         * reload1.c (compute_use_by_pseudos, reload, count_pseudo,
28840         count_spilled_pseudo, find_reg, alter_reg, finish_spills,
28841         emit_input_reload_insns, delete_output_reload): Use ira_conflicts_p.
28842
28843 2009-01-06  Ben Elliston  <bje@au.ibm.com>
28844
28845         * gengtype-lex.l (YY_NO_INPUT): Define.
28846
28847 2009-01-05  Andrew Pinski  <andrew_pinski@playstation.sony.com>
28848
28849         PR c/34911
28850         * c-common.c (handle_vector_size_attribute): Also reject
28851         BOOLEAN_TYPE types.
28852
28853 2009-01-05  Sebastian Pop  <sebastian.pop@amd.com>
28854
28855         PR tree-optimization/38492
28856         * graphite.c (rename_map_elt, debug_rename_elt,
28857         debug_rename_map_1, debug_rename_map, new_rename_map_elt,
28858         rename_map_elt_info, eq_rename_map_elts,
28859         get_new_name_from_old_name, bb_in_sese_p): Moved around.
28860         (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
28861         (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
28862         (sese_build_livein_liveouts): New.
28863         (new_sese, free_sese): New.
28864         (new_scop): Call new_sese.
28865         (free_scop): Call free_sese.
28866         (rename_variables_from_edge, rename_phis_end_scop): Removed.
28867         (register_old_new_names): Renamed register_old_and_new_names.
28868         (register_scop_liveout_renames, add_loop_exit_phis,
28869         insert_loop_close_phis, struct igp,
28870         default_liveout_before_guard, add_guard_exit_phis,
28871         insert_guard_phis, copy_renames): New.
28872         (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
28873         (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
28874         (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
28875         (scop_adjust_phis_for_liveouts): New.
28876         (gloog): Call scop_adjust_phis_for_liveouts.
28877
28878         * graphite.h (struct sese): Documented.  Added fields liveout,
28879         num_ver and livein.
28880         (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
28881         (new_sese, free_sese, sese_build_livein_liveouts): Declared.
28882         (struct scop): Added field liveout_renames.
28883         (SCOP_LIVEOUT_RENAMES): New.
28884
28885 2009-01-05  Harsha Jagasia  <harsha.jagasia@amd.com>
28886
28887         PR tree-optimization/38510
28888         * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
28889         (translate_clast): Call recompute_all_dominators before
28890         graphite_verify.
28891         (gloog): Call recompute_all_dominators before graphite_verify.
28892
28893 2009-01-05  Harsha Jagasia  <harsha.jagasia@amd.com>
28894             Jan Sjodin  <jan.sjodin@amd.com>
28895
28896         PR tree-optimization/38500
28897         * graphite.c (create_sese_edges): Call fix_loop_structure after
28898         splitting blocks.
28899
28900 2009-01-05  Joel Sherrill  <joel.sherrill@oarcorp.com>
28901
28902         * config.gcc: Add m32r*-*-rtems*.
28903         * config/m32r/rtems.h: New file.
28904
28905 2009-01-05  Ben Elliston  <bje@au.ibm.com>
28906
28907         * Makefile.in (.po.gmo): Use mkinstalldirs, not test -d || mkdir.
28908         (.po.pox): Likewise.
28909         (po/gcc.pot): Likewise.
28910
28911 2009-01-04  David S. Miller  <davem@davemloft.net>
28912
28913         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED_RTX): Delete.
28914         (STARTING_FRAME_OFFSET): Always set to zero.
28915
28916 2009-01-04  Richard Sandiford  <rdsandiford@googlemail.com>
28917
28918         * tree.def (LSHIFT_EXPR, RSHIFT_EXPR): Add commentary.
28919         * tree-cfg.c (verify_gimple_assign_binary): Allow shifts of
28920         fixed-point types, and vectors of the same.
28921
28922 2009-01-04  Richard Sandiford  <rdsandiford@googlemail.com>
28923
28924         * config/mips/sync.md (*mb_barrier): Rename to...
28925         (*memory_barrier): ...this.
28926
28927 2009-01-04  Jonathan Wakely  <jwakely.gcc@gmail.com>
28928
28929         * doc/extend.texi (Function Attributes): Move @cindex after @item
28930         for 'artificial' and 'flatten'. Fix grammar for 'externally_visible'
28931         and put in alphabetical order. Fix 'target' name and put in order.
28932         * doc/invoke.texi (-Wstrict-null-sentinel, -fipa-matrix-reorg): Fix
28933         typos.
28934
28935 2009-01-04  Uros Bizjak  <ubizjak@gmail.com>
28936
28937         * config/s390/s390.md (UNSPEC_MB): Rename from UNSPECV_MB.
28938         (memory_barrier): Expand as unspec instead of unspec_volatile.
28939         Remove mem:BLK from insn operands.  Use Pmode scratch register.
28940         (*memory_barrier): Define as unspec instead of unspec_volatile.
28941         Use (match_dup 0) as input operand.
28942
28943         * config/sparc/sparc.md (UNSPEC_MEMBAR): Rename from UNSPECV_MEMBAR.
28944         * config/sparc/sync.md (memory_barrier): Expand as unspec instead of
28945         unspec_volatile.  Remove mem:BLK from insn operands.  Use Pmode
28946         scratch register.  Remove operand 1.
28947         (*stbar): Define as unspec instead of unspec_volatile.
28948         Use (match_dup 0) as input operand, remove (const_int 8).
28949         (*membar): Define as unspec instead of unspec_volatile.
28950         Use (match_dup 0) as input operand, remove input operand 2.
28951
28952         * config/xtensa/xtensa.md (UNSPEC_MEMW): Rename from UNSPECV_MEMW.
28953         (memory_barrier): Expand as unspec instead of unspec_volatile.
28954         Remove mem:BLK from insn operands.  Use Pmode scratch register.
28955         (*memory_barrier): Define as unspec instead of unspec_volatile.
28956         Use (match_dup 0) as input operand.
28957
28958         * config/ia64/sync.md (memory_barrier): Redefine as expander pattern.
28959         Remove mem:BLK from insn operands.  Use Pmode scratch register.
28960         Set volatile flag on operand 0.
28961         (*memory_barrier): New insn pattern.
28962
28963         * config/rs6000/sync.md (memory_barrier): Remove mem:BLK from
28964         insn operands.
28965         (*memory_barrier): Use (match_dup 0) as input operand.
28966
28967         * config/mips/sync.md (memory_barrier): Redefine as expander pattern.
28968         Remove mem:BLK from insn operands.  Use Pmode scratch register.
28969         Set volatile flag on operand 0.
28970         (*mb_internal): New insn pattern.
28971
28972         * config/alpha/sync.md (*memory_barrier): Rename from *mb_internal.
28973
28974 2009-01-04  Steven Bosscher  <steven@gcc.gnu.org>
28975
28976         PR middle-end/38586
28977         * function.c (struct temp_slot): Move to the section of the file
28978         that deals with temp slots.  Remove field 'address'.
28979         (temp_slot_address_table): New hash table of address -> temp slot.
28980         (struct temp_slot_address_entry): New struct, items for the table.
28981         (temp_slot_address_compute_hash, temp_slot_address_hash,
28982         temp_slot_address_eq, insert_temp_slot_address): Support functions
28983         for the new table.
28984         (find_temp_slot_from_address): Rewrite to use the new hash table.
28985         (remove_unused_temp_slot_addresses): Remove addresses of temp
28986         slots that have been made available.
28987         (remove_unused_temp_slot_addresses_1): Call-back for htab_traverse,
28988         worker function for remove_unused_temp_slot_addresses.
28989         (assign_stack_temp_for_type): Don't clear the temp slot address list.
28990         Add the temp slot address to the address -> temp slot map.
28991         (update_temp_slot_address): Update via insert_temp_slot_address.
28992         (free_temp_slots): Call remove_unused_temp_slot_addresses.
28993         (pop_temp_slots): Likewise.
28994         (init_temp_slots): Allocate the address -> temp slot map, or empty
28995         the map if it is already allocated.
28996         (prepare_function_start): Initialize temp slot processing.
28997
28998 2009-01-04  Steven Bosscher  <steven@gcc.gnu.org>
28999
29000         PR middle-end/38584
29001         * cfgexpand.c (estimate_stack_frame_size): Simplify the estimate:
29002         Calculate the size of all stack vars assuming no packing of stack
29003         vars will happen, replacing a quadratic algorithm with a linear one.
29004
29005 2009-01-03  Jakub Jelinek  <jakub@redhat.com>
29006
29007         PR target/38707
29008         * expmed.c (store_bit_field_1): Don't modify op0 if movstrict insn
29009         can't be used.
29010
29011 2009-01-03  Diego Novillo  <dnovillo@google.com>
29012
29013         * doc/contrib.texi: Update contributions.
29014
29015 2009-01-03  Jakub Jelinek  <jakub@redhat.com>
29016
29017         PR c++/38705
29018         * builtins.c (fold_builtin_memory_op): Give up if either operand
29019         is volatile.  Set srctype or desttype to non-qualified version
29020         of the other type.
29021
29022         PR c/38700
29023         * builtins.c (fold_builtin_expect): Only check DECL_WEAK for VAR_DECLs
29024         and FUNCTION_DECLs.
29025
29026 2009-01-02  Kenneth Zadeck  <zadeck@naturalbridge.com>
29027
29028         PR rtl-optimization/35805
29029         * df-problems.c (df_lr_finalize): Add recursive call to resolve lr
29030         problem if fast dce is able to remove any instructions.
29031         * dce.c (dce_process_block): Fix dump message.
29032
29033 2009-01-02  Mark Mitchell  <mark@codesourcery.com>
29034
29035         PR 33649
29036         * tree-ssa-pre.c (compute_antic): Correct loop bounds.
29037
29038 2009-01-02  Jakub Jelinek  <jakub@redhat.com>
29039
29040         PR middle-end/38690
29041         * tree-flow.h (op_code_prio, op_prio): New prototypes.
29042         * tree-pretty-print.c (op_code_prio): New function.
29043         (op_prio): No longer static.  Use op_code_prio.
29044         * gimple-pretty-print.c (dump_unary_rhs, dump_binary_rhs):
29045         Use op_prio and op_code_prio to determine if () should be
29046         printed around operand(s) or not.
29047
29048         * gimple-pretty-print.c (dump_unary_rhs, dump_binary_rhs,
29049         dump_gimple_call, dump_gimple_switch, dump_gimple_cond,
29050         dump_gimple_label, dump_gimple_try, dump_symbols, dump_gimple_phi,
29051         dump_gimple_mem_ops, dump_bb_header, dump_bb_end, pp_cfg_jump): Use
29052         pp_character instead of pp_string for single letter printing.
29053
29054 2009-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
29055
29056         * doc/extend.texi: Fix '#pragma GCC option' typo.
29057
29058 2009-01-02  Richard Guenther  <rguenther@suse.de>
29059
29060         * doc/install.texi (--enable-checking): Mention different
29061         default for stage1.
29062         (--enable-stage1-checking): Document.
29063
29064 2009-01-01  Andrew Pinski  <pinskia@gmail.com>
29065
29066         PR middle-end/30142
29067         * tree-cfg.c (verify_expr): Add INDIRECT_REF case.  Change MODIFY_EXPR
29068         case to be an error.
29069
29070 2009-01-02  Ben Elliston  <bje@au.ibm.com>
29071
29072         * config/fp-bit.h (pack_d): Constify argument.
29073         * config/fp-bit.c (makenan): Constify return type. Remove casts.
29074         (isnan): Constify argument.
29075         (isinf): Likewise.
29076         (iszero): Likewise.
29077         (pack_d): Likewise.
29078         (_fpadd_parts): Constify return type.
29079         (_fpmul_parts): Likewise.
29080         (_fpdiv_parts): Likewise.
29081
29082 2009-01-01  Jakub Jelinek  <jakub@redhat.com>
29083
29084         PR c/36489
29085         * c-typeck.c (add_pending_init): Add IMPLICIT argument.  Only
29086         warn about overwriting initializer with side-effects or
29087         -Woverride-init if !IMPLICIT.
29088         (output_init_element): Likewise.  Pass IMPLICIT down to
29089         add_pending_init.
29090         (process_init_element): Add IMPLICIT argument.  Pass it down
29091         to output_init_element.
29092         (push_init_element, pop_init_level, set_designator): Adjust
29093         process_init_element callers.
29094         (set_nonincremental_init, set_nonincremental_init_from_string):
29095         Adjust add_pending_init callers.
29096         (output_pending_init_elements): Adjust output_init_element callers.
29097         * c-tree.h (process_init_element): Adjust prototype.
29098         * c-parser.c (c_parser_initelt, c_parser_initval): Adjust
29099         process_init_element callers.
29100
29101 \f
29102 Copyright (C) 2009 Free Software Foundation, Inc.
29103
29104 Copying and distribution of this file, with or without modification,
29105 are permitted in any medium without royalty provided the copyright
29106 notice and this notice are preserved.