OSDN Git Service

* config/mips/mips.opt (mrelax-pic-calls): New option.
[pf3gnuchains/gcc-fork.git] / gcc / ChangeLog
1 2009-09-19  Adam Nemet  <anemet@caviumnetworks.com>
2
3         * config/mips/mips.opt (mrelax-pic-calls): New option.
4         * config/mips/mips.c (mips_strip_unspec_address): Move it up in
5         the file.
6         (mips_unspec_call): Change "unspec_call" expander into this.
7         (mips_strip_unspec_call): New function.
8         (mips_got_load): Call mips_unspec_call instead of
9         gen_unspec_call<mode>.
10         (mips16_build_call_stub): Fix comment for fp_code.  Adjust call to
11         MIPS_CALL.
12         (mips_cfg_in_reorg): New function.
13         (mips16_lay_out_constants): Use it to decide whether to call
14         CFG-aware insn splitting.
15         (r10k_insert_cache_barriers): Move CFG set-up code from here to
16         mips_reorg.  Move DF set-up code from here ...
17         (mips_df_reorg): ... to here.  Call r10k_insert_cache_barriers
18         from here.
19         (mips_reorg): Call mips_df_reorg instead of
20         r10k_insert_cache_barriers.  Move CFG set-up code here from
21         r10k_insert_cache_barriers.
22         (mips_call_expr_from_insn): New function.
23         (mips_pic_call_symbol_from_set): Likewise.
24         (mips_find_pic_call_symbol): Likewise.
25         (mips_annotate_pic_call_expr): Likewise.
26         (mips_get_pic_call_symbol): Likewise.
27         (mips_annotate_pic_calls): Likewise.
28         (mips_override_options): Disable -mrelax-pic-calls unless PIC
29         calls are used.
30         (mips_set_mips16_mode): Disable -mrelax-pic-calls for MIPS16.
31         * config/mips/mips-protos.h (mips_get_pic_call_symbol): Declare it.
32         * config/mips/mips.h (MIPS_CALL): Use it to print the .reloc
33         directive.
34         * config/mips/mips.md (UNSPEC_CALL_ATTR): New unspec.
35         (unspec_call<mode>): Remove it.
36         (sibcall_internal, sibcall_value_internal,
37         sibcall_value_multiple_internal, call_internal, call_split,
38         call_value_internal, call_value_split,
39         call_value_multiple_internal, call_value_multiple_split): Pass
40         SIZE_OPNO to MIPS_CALL.
41         (call_internal_direct, call_direct_split,
42         call_value_internal_direct, call_value_direct_split): Pass -1 as
43         SIZE_OPNO to MIPS_CALL.
44         * configure.ac <mips*-*-*>: Add test for .reloc R_MIPS_JALR.
45         * configure: Regenerate.
46         * doc/invoke.texi (Option Summary): Add -mrelax-pic-calls
47         and -mno-relax-pic-calls.
48         (MIPS Options): Document -mrelax-pic-calls
49         and -mno-relax-pic-calls.
50
51 2009-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
52
53         PR bootstrap/35619
54         * Makefile.in (stmp-fixinc): Ensure `include-fixed' is created
55         in the directory this rule is called from, rather than the
56         toplevel 'gcc' directory, to fix in-tree build.
57
58 2009-09-19  Chris Demetriou  <cgd@google.com>
59
60         PR preprocessor/28435:
61         * c-opts.c (c_common_handle_option): For -MD and -MMD, indicate
62         to cpplib that the preprocessor output is needed.
63
64 2009-09-19  Jakub Jelinek  <jakub@redhat.com>
65
66         * config/rs6000/rs6000.md (*save_gpregs_<mode>, *save_fpregs_<mode>,
67         *restore_gpregs_<mode>, *return_and_restore_gpregs_<mode>,
68         *return_and_restore_fpregs_<mode>,
69         *return_and_restore_fpregs_aix_<mode>): Remove 'z' operand modifier.
70
71         PR bootstrap/41397
72         * dwarf2out.c (mem_loc_descriptor) <case SUBREG>: Recurse
73         instead of assuming it has always a REG inside of it.
74
75 2009-09-18  Gerald Pfeifer  <gerald@pfeifer.com>
76
77         * config/freebsd.h: Update comment on types.
78         (WINT_TYPE): Define.
79
80 2009-09-18  Jason Merrill  <jason@redhat.com>
81
82         * c.opt: Add -fno-deduce-init-list.
83
84 2009-09-18  Neil Vachharajani  <nvachhar@google.com>
85
86         * value-prof.c (interesting_stringop_to_profile_p): Added output
87         argument to indicate which parameter is the size parameter.
88         * value-prof.c (gimple_stringop_fixed_value): Use
89         INTERESTING_STRINGOP_TO_PROFILE_P to find size argument.
90         * value-prof.c (gimple_stringops_transform): Update call sites to
91         INTERESTING_STRINGOP_TO_PROFILE_P to reflect parameter change.
92         * testsuite/gcc.dg/tree-prof/val-prof-7.c: Added test case.
93
94 2009-09-18  Uros Bizjak  <ubizjak@gmail.com>
95
96         PR target/38288
97         From David Binderman <dcb314@hotmail.com>:
98         * gcc/config/i386/i386.c (ix86_function_regparm): Remove useless
99         local variable f.  Remove stale comments.
100         (ix86_compute_frame_layout): Remove useless local variable total_size.
101         Remove #if 0'd code.
102         (legitimate_address_p): Remove useless local variables
103         reason_rtx and reason.
104         (ix86_split_copysign_const): Remove useless local variable op1.
105         (scale_counter): Remove useless local variable piece_size_mask.
106
107 2009-09-18  Jakub Jelinek  <jakub@redhat.com>
108
109         * stmt.c (expand_asm_operands): Set REG_ATTRS on the temporary from
110         output decl.
111
112 2009-09-17  Michael Haubenwallner  <michael.haubenwallner@salomon.at>
113
114         PR target/40913
115         * config/pa/t-hpux-shlib: Set soname in libgcc_s.sl.
116
117 2009-09-17  Jakub Jelinek  <jakub@redhat.com>
118
119         * c-decl.c (finish_struct): Adjust DECL_SOURCE_LOCATION of
120         TYPE_STUB_DECL.
121
122 2009-09-17  Alexandre Oliva  <aoliva@redhat.com>
123
124         * dwarf2out.c (loc_descriptor): Emit DW_OP_stack_value and
125         DW_OP_implicit_value even without dwarf_version 4.
126
127 2009-09-17  Jan Hubicka  <jh@suse.cz>
128
129         * dwarf2out.c: Include tree-pass.h and gimple.h.
130         (loc_list_plus_const): New function.
131         (loc_descriptor_from_tree_1): Rename to ...
132         (loc_descriptor_from_tree): ... remove original.
133         (loc_list_from_tree): New function.
134         (add_AT_location_description): Accept location list.
135         (tls_mem_loc_descriptor): Update call of loc_descriptor_from_tree.
136         (concatn_mem_loc_descriptor): Remove.
137         (mem_loc_descriptor): Handle CONCAT/CONCATN and VAR_LOCATION by
138         returning NULL.
139         (secname_for_decl): Move up.
140         (hidden_reference_p): New function; break out from ...
141         (loc_by_refernece): ... here; move up.
142         (dw_loc_list): New function.
143         (single_element_loc_list): New function.
144         (single_element_loc_list_p): New function.
145         (add_loc_descr_to_each): New function.
146         (add_loc_list): New function.
147         (loc_descr_from_tree): Make wraper of loc_list_from_tree.
148         (loc_list_from_tree): Reroganized from loc_descr_from_tree;
149         add diagnostics why expansion failed.
150         (add_location_or_const_value_attribute): Support location lists.
151         (add_bound_info): Likewise.
152         (descr_info_loc): Update call of loc_descriptor_from_tree.
153         (gen_variable_die): Work on location lists.
154         * final.c (pass_final): Add dump file.
155         * Makefile.in (dwarf2out.o): Add new dependencies.
156
157 2009-09-17  Janis Johnson  <janis187@us.ibm.com>
158
159         PR c/41049
160         * real.c decimal_from_integer, decimal_integer_string): New.
161         (real_from_integer): Use them as special case for decimal float.
162         * config/dfp-bit.c (_si_to_sd, _usi_to_sd): Use default rounding.
163         (_di_to_sd, _di_to_dd, _di_to_td, _udi_to_sd, _udi_to_dd, _udi_to_td):
164         Do not append zero after the decimal point in string to convert.
165
166 2009-09-17  Alexander Monakov  <amonakov@ispras.ru>
167
168         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Add bounds only
169         for ARRAY_REFs.  Use array_ref_{low,up}_bound to determine bounds.
170
171 2009-09-17  Martin Jambor  <mjambor@suse.cz>
172
173         * common.opt (fipa-sra): New switch.
174         * opts.c (decode_options): Turn flag_ipa_sra on for opt2.
175         * timevar.def (TV_IPA_SRA): New timevar.
176         * params.def (ipa-sra-ptr-growth-factor): New parameter.
177         * doc/invoke.texi: Document -fipa-sra and ipa-sra-ptr-growth-factor.
178         * tree-sra.c: Include cgraph.c.
179         (enum sra_mode): Added SRA_MODE_EARLY_IPA.
180         (struct access): Added fields stmt, grp_maybe_modified, grp_scalar_ptr
181         and grp_not_necessarilly_dereferenced.
182         (func_param_count): New variable.
183         (encountered_apply_args): New variable.
184         (bb_dereferences): New variable.
185         (final_bbs): New variable.
186         (no_accesses_representant): New variable.
187         (no_accesses_p): New function.
188         (dump_access): Dump the new fields.
189         (sra_initialize): Set encountered_apply_args to false.
190         (get_ssa_base_param): New function.
191         (mark_parm_dereference): New function.
192         (create_access): Caring for INIDRECT_REFs and different handling of
193         varialble length accesses in early IPA SRA.  Store the stmt - a new
194         parameter - to the new access.
195         (build_access_from_expr_1): New parameter stmt, passed to
196         create_access.  Handle INDIRECT_REFs.
197         (build_access_from_expr): Pass the current statement to
198         build_access_from_expr_1.
199         (disqualify_ops_if_throwing_stmt): Trigger only in intraprocedural
200         passes.
201         (build_accesses_from_assign): Pass the current statement to
202         build_access_from_expr_1.  Do not create assign links in IPA-SRA.
203         (scan_function): Call handle_ssa_defs on phi nodes.  Set bits in
204         final_bbs when necessary.  Check for calls to __builtin_apply_args.
205         Fixup EH info if anythng was changed.
206         (is_unused_scalar_param): New function.
207         (ptr_parm_has_direct_uses): New function.
208         (find_param_candidates): New function.
209         (mark_maybe_modified): New function.
210         (analyze_modified_params): New function.
211         (propagate_dereference_distances): New function.
212         (dump_dereferences_table): New function.
213         (analyze_caller_dereference_legality): New function.
214         (unmodified_by_ref_scalar_representative): New function.
215         (splice_param_accesses): New function.
216         (decide_one_param_reduction): New function.
217         (enum ipa_splicing_result): New type.
218         (splice_all_param_accesses): New function.
219         (get_param_index): New function.
220         (turn_representatives_into_adjustments): New function.
221         (analyze_all_param_acesses): New function.
222         (get_replaced_param_substitute): New function.
223         (get_adjustment_for_base): New function.
224         (replace_removed_params_ssa_names): New function.
225         (sra_ipa_reset_debug_stmts): New function.
226         (sra_ipa_modify_expr): New function.
227         (sra_ipa_modify_assign): New function.
228         (convert_callers): New function.
229         (modify_function): New function.
230         (ipa_sra_preliminary_function_checks): New function.
231         (ipa_early_sra): New function.
232         (ipa_early_sra_gate): New function.
233         (pass_early_ipa_sra): New variable.
234         * Makefile.in (tree-sra.o): Add cgraph.h to dependencies.
235
236 2009-09-17  Michael Matz  <matz@suse.de>
237
238         PR middle-end/41347
239         * tree.c (build_type_attribute_qual_variant): Export.
240         * tree.h (build_type_attribute_qual_variant): Declare.
241         * tree-inline.c (remap_type_1): Use it to build variants with
242         the original qualifiers and attributes.
243
244 2009-09-17  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
245
246         * cfglayout.c (fixup_reorder_chain): Accept conditional jumps
247         without a fallthrough edge.
248
249 2009-09-16  DJ Delorie  <dj@redhat.com>
250
251         * config/m32c/m32c.c (m32c_emit_epilogue): Check for R8C or M16C
252         chip and ignore the "fast_interrupt" attribute if so.
253
254 2009-09-16  Richard Henderson  <rth@redhat.com>
255
256         PR middle-end/41360
257         * cfgbuild.c (find_bb_boundaries): Really re-instate 2009-09-02
258         barrier fix.
259
260 2009-09-16  Richard Henderson  <rth@redhat.com>
261
262         PR target/41246
263         * tree-cfg.c (verify_gimple_call): Validate that gimple_call_chain
264         is set only if DECL_NO_STATIC_CHAIN is unset.
265         * tree-nested.c (iter_nestinfo_start, iter_nestinfo_next): New.
266         (FOR_EACH_NEST_INFO): New.
267         (walk_all_functions): Use it.
268         (finalize_nesting_tree): Likewise.
269         (unnest_nesting_tree): Likewise.
270         (free_nesting_tree): Use iter_nestinfo_start, iter_nestinfo_next.
271         (get_chain_decl, get_chain_field): Reset DECL_NO_STATIC_CHAIN.
272         (convert_gimple_call): Early out if gimple_call_chain already set.
273         (convert_all_function_calls): Iterate until no new functions
274         require a static chain.
275         (finalize_nesting_tree_1): Assert DECL_NO_STATIC_CHAIN is unset
276         when building a trampoline.  Use dump_function_to_file instead
277         of dump_function.
278         (lower_nested_functions): Open dump_file.  Validate that decls
279         that have DECL_NO_STATIC_CHAIN from the front end don't have that
280         bit reset by this pass.
281
282 2009-09-16  Michael Matz  <matz@suse.de>
283
284         PR fortran/41212
285         * tree.h (struct tree_decl_common): Add decl_restricted_flag,
286         shorten decl_common_unused.
287         (DECL_RESTRICTED_P): New accessor.
288         * tree-ssa-alias.c (ptr_deref_may_alias_decl_p): Use it
289         to disambiguate marked decls and restrict pointers.
290
291 2009-09-16  Richard Henderson  <rth@redhat.com>
292
293         PR middle-end/41360
294         * cfgbuild.c (find_bb_boundaries): Re-instate 2009-09-02 barrier fix.
295
296 2009-09-16  Jakub Jelinek  <jakub@redhat.com>
297
298         * integrate.c (set_block_abstract_flags): Call
299         set_decl_abstract_flags also on BLOCK_NONLOCALIZED_VARs.
300
301 2009-09-16  Richard Guenther  <rguenther@suse.de>
302
303         PR middle-end/34011
304         * tree-flow-inline.h (may_be_aliased): Compute readonly variables
305         as non-aliased.
306
307 2009-09-16  DJ Delorie  <dj@redhat.com>
308             Kaz Kojima  <kkojima@gcc.gnu.org>
309
310         * config/sh/sh.c (output_stack_adjust): Add new argument frame_p.
311         (sh_expand_prologue): Update calls to output_stack_adjust.
312         (sh_expand_epilogue): Likewise.
313
314 2009-09-15  Adam Nemet  <anemet@caviumnetworks.com>
315
316         PR bootstrap/41349
317         * reorg.c (redundant_insn): Don't count notes or DEBUG_INSNs when
318         trying to limit the extent of searches in the insn stream.
319
320 2009-09-15  Nathan Froyd  <froydnj@codesourcery.com>
321             Jakub Jelinek  <jakub@redhat.com>
322
323         PR target/41175
324         PR target/40677
325         * config/rs6000/rs6000.c (no_global_regs_above): Fix precedence
326         problem.
327         (SAVRES_NOINLINE_GPRS_SAVES_LR, SAVRES_NOINLINE_FPRS_SAVES_LR,
328         SAVRES_NOINLINE_FPRS_DOESNT_RESTORE_LR): New strategy bits.
329         (rs6000_savres_strategy): Always save FP registers inline if the
330         target doesn't support hardware double-precision.  Set the above
331         bits in return value when needed.
332         (rs6000_savres_routine_sym): Fix computation for cache selector.
333         Mark the generated symbol as a function.  Rename exitp argument to
334         lr.  Move code for determining the name of the symbol...
335         (rs6000_savres_routine_name): ...here.  New function.  Add cases for
336         getting the names right on AIX and 64-bit Linux.
337         (savres_routine_name): New variable.
338         (rs6000_make_savres_rtx): Rename exitp argument to lr.  Don't assert
339         lr isn't set when savep.  Use r12 resp. r1 instead of r11 depending
340         on what the target routine uses as a base register.  If savep && lr
341         describe saving of r0 into memory slot.
342         (rs6000_emit_prologue): Correct use of call_used_regs.  Fix out of
343         line calls for AIX ABI.
344         (rs6000_output_function_prologue): Use rs6000_savres_routine_name to
345         determine FP save/restore functions.
346         (rs6000_emit_stack_reset): Handle savres if sp_offset != 0 and
347         frame_reg_rtx != sp_reg_rtx.  Use gen_add3_insn instead of
348         gen_addsi3.
349         (rs6000_emit_epilogue): Adjust computation of restore_lr.
350         Duplicate restoration of LR and execute the appropriate one
351         depending on whether GPRs are being restored inline.  Set r11 from
352         offsetted frame_reg_rtx instead of sp_reg_rtx; if frame_reg_rtx is
353         r11, adjust sp_offset.  Use gen_add3_insn instead of gen_addsi3.
354         Fix out of line calls for AIX ABI.
355         * config/rs6000/rs6000.md (*return_and_restore_fpregs_aix_<mode>):
356         New insn.
357         * config/rs6000/spe.md (*save_gpregs_spe): Use explicit match for
358         register 11.
359         (*restore_gpregs_spe): Likewise.
360         (*return_and_restore_gpregs_spe): Likewise.
361         * config/rs6000/linux64.h (SAVE_FP_SUFFIX, RESTORE_FP_SUFFIX):
362         Define to empty string unconditionally.
363         * config/rs6000/sysv4.h (SAVE_FP_SUFFIX, RESTORE_FP_SUFFIX):
364         Define to empty string unconditionally.
365         (GP_SAVE_INLINE, FP_SAVE_INLINE): Handle TARGET_64BIT the same as
366         !TARGET_64BIT.
367
368 2009-09-15  Jan Hubicka  <jh@suse.cz>
369
370         * doc/invoke.texi (inline-insns-auto): Drop from 60 to 50.
371         * params.def (inline-insns-auto): Likewise.
372
373 2009-09-15  Martin Jambor  <mjambor@suse.cz>
374
375         * ipa-inline.c (estimate_function_body_sizes): Dump info about
376         individual statements only at TDF_DETAILS dump level.  Format
377         source for 80 characters per line.
378
379 2009-09-15  Christian Bruel  <christian.bruel@st.com>
380
381         * regrename.c (do_replace): Update REG_DEAD notes.
382
383 2009-09-15  Revital Eres  <eres@il.ibm.com>
384
385         * doc/tm.texi (TARGET_SUPPORT_VECTOR_MISALIGNMENT): Document.
386         * targhooks.c (default_builtin_support_vector_misalignment):
387         New builtin function.
388         * targhooks.h (default_builtin_support_vector_misalignment):
389         Declare.
390         * target.h (builtin_support_vector_misalignment):
391         New field in struct gcc_target.
392         * tree-vect-data-refs.c (vect_supportable_dr_alignment): Call
393         new builtin function.
394         * target-def.h (TARGET_SUPPORT_VECTOR_MISALIGNMENT):
395         Define.
396         * config/rs6000/rs6000.c
397         (rs6000_builtin_support_vector_misalignment): New function.
398         (TARGET_SUPPORT_VECTOR_MISALIGNMENT): Define.
399
400 2009-09-15  Jie Zhang  <jie.zhang@analog.com>
401
402         * config/bfin/bfin.c (length_for_loop): Use NONDEBUG_INSN_P
403         instead of INSN_P.
404         (bfin_optimize_loop): Likewise.
405         (bfin_gen_bundles): Likewise.
406         (workaround_speculation): Likewise.
407         (find_load): Return NULL_RTX for debug_insn.
408
409 2009-09-15  Uros Bizjak  <ubizjak@gmail.com>
410
411         * config/alpha/alpha.md (smaxsf3): Disable for IEEE mode.
412         (sminsf3): Ditto.
413
414 2009-09-14  DJ Delorie  <dj@redhat.com>
415
416         * config/mep/mep.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
417         * config/mep/mep.c (mep_emit_cbranch): Don't use BEQZ/BNEI in
418         VLIW mode.
419
420 2009-09-14  Richard Henderson  <rth@redhat.com>
421             Jakub Jelinek  <jakub@redhat.com>
422
423         * builtins.c (expand_builtin_synchronize): Use gimple_build_asm_vec.
424         * cfgbuild.c (make_edges): Handle asm goto.
425         * cfglayout.c (fixup_reorder_chain): Likewise.
426         * cfgrtl.c (patch_jump_insn): Likewise.
427         * gimple-pretty-print.c (dump_gimple_asm): Likewise.
428         * gimple.c (gimple_build_asm_1): Add and use nlabels parameter.
429         (gimple_build_asm_vec): Add and use labels parameter.
430         (gimple_build_asm): Remove.
431         (walk_gimple_asm): Walk labels too.
432         * gimple.def (GIMPLE_ASM): Update docs.
433         * gimple.h: Update decls.
434         (struct gimple_statement_asm): Change nc to use unsigned char;
435         add nl member.
436         (gimple_asm_nlabels): New.
437         (gimple_asm_label_op, gimple_asm_set_label_op): New.
438         * gimplify.c (gimplify_asm_expr): Copy labels from ASM_EXPR
439         into gimple_build_asm_vec.
440         * jump.c (mark_jump_label_asm): New.
441         (mark_jump_label): Use it.
442         (redirect_jump_1): Handle asm goto.
443         (invert_jump_1): Soft fail if X is null.
444         * recog.c (extract_asm_operands): New.
445         (asm_noperands): Use it; handle asm labels.
446         (decode_asm_operands): Use extract_asm_operands.
447         (asm_operand_ok): Properly handle empty string.
448         * reg-stack.c (get_asm_operands_in_out): Rename from
449         get_asm_operand_n_inputs; use extract_asm_operands; return both
450         inputs and outputs by reference; update all callers.
451         * rtl.def (ASM_OPERANDS): Add label vector as operand 6.
452         * rtl.h (ASM_OPERANDS_LABEL_VEC): New.
453         (ASM_OPERANDS_LABEL_LENGTH, ASM_OPERANDS_LABEL): New.
454         (ASM_OPERANDS_SOURCE_LOCATION): Renumber.
455         (extract_asm_operands): Declare.
456         * stmt.c (expand_asm_operands): Add and use labels parameter.
457         (check_unique_operand_names): Likewise.
458         (resolve_asm_operand_names, resolve_operand_name_1): Likewise.
459         (expand_asm_stmt): Handle asm labels.
460         * tree-cfg.c (make_gimple_asm_edges): New.
461         (make_edges): Use it.
462         (cleanup_dead_labels): Handle asm labels.
463         (is_ctrl_altering_stmt): Likewise.
464         (gimple_redirect_edge_and_branch): Likewise.
465         * tree.def (ASM_EXPR): Add 5th operand.
466         * tree.h (ASM_LABELS): New.
467         (resolve_asm_operand_names): Update decl.
468
469         * c-parser.c (c_parser_asm_statement): Parse asm goto.
470         (c_parser_asm_goto_operands): New.
471         * c-tree.h (build_asm_expr): Update decl.
472         * c-typeck.c (build_asm_expr): Add and use labels parameter.
473         * doc/extend.texi: Document asm goto.
474
475 2009-09-14  Richard Henderson  <rth@redhat.com>
476
477         * except.h: Update declarations.
478         (struct pointer_map_t): Forward declare.
479         (ERT_UNKNOWN, ERT_THROW, ERT_CATCH): Remove.
480         (struct eh_landing_pad_d, eh_landing_pad): New.
481         (struct eh_catch_d, eh_catch): New.
482         (struct eh_region_d): Remove next_region_sharing_label, aka,
483         label, tree_label, landing_pad, post_landing_pad, resume,
484         may_contain_throw.  Rename region_number to index.  Remove
485         u.eh_catch, u.eh_throw.  Rename u.eh_try.eh_catch to first_catch.
486         Add u.must_not_throw, landing_pads, exc_ptr_reg, filter_reg.
487         (VEC(eh_landing_pad,gc)): New.
488         (struct eh_status): Remove last_region_number.  Add lp_array,
489         throw_stmt_table, ttype_data, ehspec_data.
490         (ehr_next, FOR_ALL_EH_REGION_AT): New.
491         (FOR_ALL_EH_REGION_FN, FOR_ALL_EH_REGION): New.
492         * except.c (lang_protect_cleanup_actions): Return tree.
493         (struct ehl_map_entry): Remove.
494         (init_eh_for_function): Push zero entries for region and lp_array.
495         (gen_eh_region): Add to region_array immediately.
496         (gen_eh_region_catch): Operate on eh_catch objects.
497         (gen_eh_landing_pad): New.
498         (get_eh_region_may_contain_throw, get_eh_region_tree_label): Remove.
499         (get_eh_region_no_tree_label, set_eh_region_tree_label): Remove.
500         (get_eh_region_from_number, get_eh_region_from_number_fn): New.
501         (get_eh_landing_pad_from_number_fn): New.
502         (get_eh_landing_pad_from_number): New.
503         (get_eh_region_from_lp_number_fn): New.
504         (get_eh_region_from_lp_number): New.
505         (expand_resx_stmt, note_eh_region_may_contain_throw): Remove.
506         (get_exception_pointer, get_exception_filter): Remove.
507         (collect_eh_region_array, can_be_reached_by_runtime): Remove.
508         (current_function_has_exception_handlers): Simplify.
509         (bring_to_root, eh_region_replaceable_by_p): Remove.
510         (replace_region, hash_type_list, hash_eh_region): Remove.
511         (eh_regions_equal_p, merge_peers, remove_unreachable_regions): Remove.
512         (label_to_region_map, num_eh_regions): Remove.
513         (get_next_region_sharing_label, must_not_throw_labels): Remove.
514         (find_exception_handler_labels): Remove.
515         (duplicate_eh_regions_0, find_prev_try): Remove.
516         (struct duplicate_eh_regions_data): New.
517         (duplicate_eh_regions_1): Rewrite.
518         (duplicate_eh_regions): Return a pointer map instead of an
519         integer offset.
520         (copy_eh_region_1, copy_eh_region, push_reachable_handler): Remove.
521         (redirect_eh_edge_to_label): Remove.
522         (eh_region_outermost): Rewrite using eh_region pointers
523         instead of integers.
524         (add_ttypes_entry): Update for ttype_data move to eh_status.
525         (add_ehspec_entry): Rewrite with VEC instead of varray.
526         (assign_filter_values): Likewise.  Export.
527         (build_post_landing_pads, connect_post_landing_pads): Remove.
528         (dw2_build_landing_pads): Rewrite to use lp_array.
529         (struct sjlj_lp_info, sjlj_find_directly_reachable_regions): Remove.
530         (sjlj_assign_call_site_values): Rewrite to use lp_array.
531         (sjlj_emit_dispatch_table, sjlj_build_landing_pads): Likewise.
532         (sjlj_mark_call_sites): Update for landing pad numbers.
533         (finish_eh_generation): Rewrite.
534         (gate_handle_eh): Do nothing for no eh tree.
535         (pass_rtl_eh): Move up near finish_eh_generation.
536         (remove_eh_landing_pad): New.
537         (remove_eh_handler): Export.
538         (remove_eh_region, remove_eh_handler_and_replace): Remove.
539         (for_each_eh_label): Rewrite to use lp_array.
540         (make_reg_eh_region_note): New.
541         (make_reg_eh_region_note_nothrow_nononlocal): New.
542         (insn_could_throw_p): New.
543         (copy_reg_eh_region_note_forward): New.
544         (copy_reg_eh_region_note_backward): New.
545         (check_handled, add_reachable_handler): Remove.
546         (reachable_next_level, foreach_reachable_handler): Remove.
547         (arh_to_landing_pad, arh_to_label, reachable_handlers): Remove.
548         (get_eh_region_and_lp_from_rtx): New.
549         (get_eh_region_from_rtx): New.
550         (can_throw_internal_1, can_throw_external_1): Remove.
551         (can_throw_internal): Use get_eh_region_from_rtx.
552         (can_throw_external): Use get_eh_region_and_lp_from_rtx.
553         (insn_nothrow_p, can_nonlocal_goto): New.
554         (expand_builtin_eh_common, expand_builtin_eh_pointer): New.
555         (expand_builtin_eh_filter, expand_builtin_eh_copy_values): New.
556         (add_action_record): Use VEC not varray.
557         (collect_one_action_chain): Update for eh_region changes.
558         (convert_to_eh_region_ranges): Make static.  Use VEC not varray.
559         Use get_eh_region_and_lp_from_rtx.
560         (gate_convert_to_eh_region_ranges): New.
561         (pass_convert_to_eh_region_ranges): Use it.
562         (push_uleb128, push_sleb128): Use VEC not varray.
563         (output_one_function_exception_table): Likewise.
564         (dump_eh_tree): Update for eh_region changes.
565         (verify_eh_tree): Likewise.
566         (verify_eh_region, default_init_unwind_resume_libfunc): Remove.
567         * tree-eh.c: Include target.h.
568         (add_stmt_to_eh_lp_fn): Rename from add_stmt_to_eh_region_fn.
569         Don't disallow GIMPLE_RESX; adjust argument check.
570         (add_stmt_to_eh_lp): Rename from add_stmt_to_eh_region.
571         (record_stmt_eh_region): Update for landing pad numbers;
572         generate a landing pad if necessary.
573         (remove_stmt_from_eh_lp): Rename from remove_stmt_from_eh_region.
574         (remove_stmt_from_eh_lp_fn): Similarly.
575         (lookup_stmt_eh_lp_fn): Rename from lookup_stmt_eh_region_fn.
576         Update for lp numbers; don't special case missing throw_stmt_table.
577         (lookup_expr_eh_lp): Similarly.
578         (lookup_stmt_eh_lp): Rename from lookup_stmt_eh_region.
579         (eh_seq, eh_region_may_contain_throw): New.
580         (struct leh_state): Add ehp_region.
581         (struct leh_tf_state): Remove eh_label.
582         (emit_post_landing_pad): New.
583         (emit_resx, emit_eh_dispatch): New.
584         (note_eh_region_may_contain_throw): New.
585         (frob_into_branch_around): Take eh_region not eh label;
586         emit eh code into eh_seq.
587         (honor_protect_cleanup_actions): Early exit for no actions.  Don't
588         handle EXC_PTR_EXPR, FILTER_EXPR.  Use gimple_build_eh_must_not_throw,
589         lower_eh_must_not_throw.  Emit code to eh_seq.
590         (lower_try_finally_nofallthru): Emit eh code to eh_seq.
591         (lower_try_finally_onedest): Likewise.
592         (lower_try_finally_copy): Likewise.
593         (lower_try_finally_switch): Likewise.
594         (lower_try_finally): Initialize ehp_region.
595         (lower_catch): Update for eh_catch objects.
596         (lower_eh_filter): Don't handle must_not_throw.
597         (lower_eh_must_not_throw): New.
598         (lower_cleanup): Don't set eh_label.
599         (lower_eh_constructs_2): Resolve eh builtins.
600         Handle GIMPLE_EH_MUST_NOT_THROW.
601         (lower_eh_constructs): Initialize eh_region_may_contain_throw.
602         Add eh_seq to the end of the function body.
603         (make_eh_dispatch_edges): New.
604         (make_eh_edge): Remove.
605         (make_eh_edges): Simplify for landing pads.
606         (redirect_eh_edge_1): New.
607         (redirect_eh_edge): Use it.
608         (redirect_eh_dispatch_edge): New.
609         (stmt_could_throw_p): Use a switch.  Allow RESX.
610         (stmt_can_throw_external): Use lookup_stmt_eh_lp.
611         (stmt_can_throw_internal): Likewise.
612         (maybe_clean_eh_stmt_fn, maybe_clean_eh_stmt): New.
613         (maybe_clean_or_replace_eh_stmt): Update for landing pads.
614         (maybe_duplicate_eh_stmt_fn, maybe_duplicate_eh_stmt): New.
615         (gate_refactor_eh): New.
616         (pass_refactor_eh): Use it.
617         (lower_resx, execute_lower_resx, pass_lower_resx): New.
618         (lower_eh_dispatch, execute_lower_eh_dispatch): New.
619         (gate_lower_ehcontrol, pass_lower_eh_dispatch): New.
620         (remove_unreachable_handlers): Rename from
621         tree_remove_unreachable_handlers; rewrite for landing pads;
622         call remove_eh_handler directly.
623         (remove_unreachable_handlers_no_lp): New.
624         (unsplit_eh, unsplit_all_eh): New.
625         (tree_empty_eh_handler_p, all_phis_safe_to_merge): Remove.
626         (cleanup_empty_eh_merge_phis, cleanup_empty_eh_move_lp): New.
627         (cleanup_empty_eh_unsplit): New.
628         (cleanup_empty_eh): Rewrite.
629         (cleanup_all_empty_eh): New.
630         (execute_cleanup_eh): Rename from cleanup_eh.  Remove unreachable
631         handlers first.  Use unsplit_all_eh, cleanup_all_empty_eh.
632         (gate_cleanup_eh): New.
633         (pass_cleanup_eh): Use it.
634         (verify_eh_edges): Move later in file.  Expect one EH edge.
635         (verify_eh_dispatch_edge): New.
636
637         * Makefile.in (FUNCTION_H): Use vecprim.h, not varray.h.
638         (gtype-desc.o): Add TARGET_H.
639         (tree.o): Use EXCEPT_H, not except.h.
640         (cfgbuild.o): Add EXPR_H.
641         (GTFILES): Add vecprim.h.
642         * builtins.c (expand_builtin): Handle BUILT_IN_EH_POINTER,
643         BUILT_IN_EH_FILTER, BUILT_IN_EH_COPY_VALUES.
644         * builtins.def (BUILT_IN_UNWIND_RESUME, BUILT_IN_EH_POINTER,
645         BUILT_IN_EH_FILTER, BUILT_IN_EH_COPY_VALUES): New.
646         * calls.c (emit_call_1): Use make_reg_eh_region_note.
647         * cfgbuild.c (control_flow_insn_p): Use can_nonlocal_goto; tidy
648         calls to can_throw_internal.
649         (rtl_make_eh_edge): Use get_eh_landing_pad_from_rtx.
650         (make_edges): Don't handle RESX; use can_nonlocal_goto.
651         * cfgexpand.c (expand_gimple_stmt_1): Don't handle RESX.
652         (expand_gimple_stmt): Use make_reg_eh_region_note.
653         (expand_debug_expr): Don't handle EXC_PTR_EXPR and FILTER_EXPR.
654         (gimple_expand_cfg): Don't call convert_from_eh_region_ranges,
655         or find_exception_handler_labels.
656         * cfgrtl.c (rtl_verify_flow_info_1): Don't handle RESX.  Assert
657         there is exacly one EH edge.  Use can_nonlocal_goto and
658         can_throw_internal.
659         * cgraphunit.c (update_call_expr): Use maybe_clean_eh_stmt_fn.
660         (cgraph_materialize_all_clones): Use maybe_clean_or_replace_eh_stmt.
661         * combine.c (can_combine_p, try_combine): Use insn_nothrow_p.
662         * cse.c (count_reg_usage, insn_live_p): Use insn_could_throw_p.
663         * dce.c (deletable_insn_p_1): Don't test may_trap_p.
664         (deletable_insn_p): Use insn_nothrow_p; reorder nonjump insn test.
665         * dse.c (scan_insn): Use insn_could_throw_p.
666         * emit-rtl.c (try_split): Use copy_reg_eh_region_note_backward.
667         * expr.c (expand_expr_real): Use make_reg_eh_region_note.
668         (expand_expr_real_1): Don't handle RESX, EXC_PTR, or FILTER_EXPR.
669         * fold-const.c (tree_expr_nonnegative_warnv_p): Don't handle
670         EXC_PTR_EXPR or FILTER_EXPR.
671         (tree_expr_nonzero_warnv_p): Likewise.
672         * function.h: Include vecprim.h, not varray.h
673         (struct rtl_eh): Remove filter, exc_ptr, built_landing_pad members;
674         move ttype_data and ehspec_data members to struct eh_status; change
675         action_record_data member to a VEC.
676         * gcse.c (hash_scan_set): Use can_throw_internal.
677         * gengtype.c (open_base_files): Add target.h to gtype-desc.c.
678         * gimple-iterator.c (gsi_replace): Use maybe_clean_or_replace_eh_stmt.
679         * gimple-low.c (lower_stmt): Handle GIMPLE_EH_MUST_NOT_THROW.
680         (block_may_fallthru): Don't handle RESX_EXPR.
681         * gimple-pretty-print.c (dump_gimple_label): Dump EH_LANDING_PAD_NR.
682         (dump_gimple_eh_must_not_throw, dump_gimple_eh_dispatch): New.
683         (dump_gimple_stmt): Dump landing pad information with TDF_EH;
684         handle GIMPLE_EH_MUST_NOT_THROW, GIMPLE_EH_DISPATCH.
685         * gimple.c (gss_for_code): Handle GIMPLE_EH_MUST_NOT_THROW,
686         GIMPLE_EH_DISPATCH, GIMPLE_RESX.
687         (gimple_size): Likewise.
688         (gimple_build_eh_dispatch, gimple_build_eh_must_not_throw): New.
689         (gimple_build_resx): Use gimple_build_with_ops.
690         (DEFTREECODE): Don't handle EXC_PTR_EXPR, FILTER_EXPR.
691         (is_gimple_val): Likewise.
692         (is_gimple_stmt): Remove RESX_EXPR.
693         * gimple.def (GIMPLE_EH_MUST_NOT_THROW, GIMPLE_EH_DISPATCH): New.
694         (GIMPLE_RESX): Reorder with other EH constructs.
695         * gimple.h (struct gimple_statement_eh_mnt): New.
696         (struct gimple_statement_eh_ctrl): Rename from gimple_statement_resx.
697         (gimple_eh_filter_must_not_throw): Remove.
698         (gimple_eh_filter_set_must_not_throw): Remove.
699         (gimple_eh_must_not_throw_fndecl): New.
700         (gimple_eh_dispatch_region, gimple_eh_dispatch_set_region): New.
701         (is_gimple_resx): New.
702         * gimplify.c (gimplify_expr): Don't handle EXC_PTR_EXPR, RESX_EXPR.
703         Don't copy EH_FILTER_MUST_NOT_THROW.
704         * gsstruct.def (GSS_EH_MNT, GSS_EHCONTROL): New.
705         * ipa-inline.c (estimate_function_body_sizes): Don't try to
706         handle must_not_throw_labels specially.
707         * ipa-pure-const.c (check_call): Update debug statement for LP.
708         * ipa-type-escape.c (check_operand): Don't handle EXC_PTR or FILTER.
709         * ipa-utils.c (get_base_var): Likewise.
710         * libfunc.h (LTI_unwind_resume, unwind_resume_libfunc): Remove.
711         * lower-subreg.c (move_eh_region_note): Remove.
712         (resolve_simple_move): Use copy_reg_eh_region_note_forward.
713         * omp-low.c (new_omp_context): Update for eh_lp_nr.
714         (create_task_copyfn): Likewise.
715         (maybe_catch_exception): Use gimple_build_eh_filter.
716         * optabs.c (emit_libcall_block): Update test for no-nonlocal-goto
717         REG_EH_REGION.  Use make_reg_eh_region_note_nothrow_nononlocal.
718         * passes.c (init_optimization_passes): Add pass_lower_eh_dispatch
719         and pass_lower_resx.
720         * print-tree.c (print_node): Dump EH_LANDING_PAD_NR.
721         * recog.c (peephole2_optimize): Use copy_reg_eh_region_note_backward,
722         can_throw_internal, can_nonlocal_goto.
723         * reload1.c (fixup_eh_region_note): Use insn_could_throw_p,
724         copy_reg_eh_region_note_forward.
725         (emit_input_reload_insns): Use copy_reg_eh_region_note_forward.
726         (emit_output_reload_insns): Likewise.
727         (copy_eh_notes): Remove.
728         * rtl.def (RESX): Remove.
729         * rtl.h: Update declarations.
730         * sese.c (graphite_copy_stmts_from_block): Use maybe_duplicate_eh_stmt.
731         * tree-cfg.c (make_edges): Handle GIMPLE_EH_DISPATCH.
732         (update_eh_label): Remove.
733         (cleanup_dead_labels_eh): New.
734         (cleanup_deal_labels): Use it instead of update_eh_label.
735         (gimple_merge_blocks): Update landing pad data structure when
736         removing a landing pad label.
737         (remove_useless_stmts_tc): Remove gimple_eh_filter_must_not_throw
738         test; handle GIMPLE_EH_MUST_NOT_THROW.
739         (is_ctrl_altering_stmt): Handle GIMPLE_EH_DISPATCH.
740         (verify_gimple_assign_single): Don't handle EXC_PTR or FILTER_EXPR.
741         (verify_types_in_gimple_stmt): Handle GIMPLE_EH_DISPATCH.
742         (verify_stmt): Likewise.  Verify landing pads.
743         (gimple_redirect_edge_and_branch): Handle GIMPLE_EH_DISPATCH.
744         (gimple_duplicate_bb): Use maybe_duplicate_eh_stmt.
745         (struct move_stmt_d): Add eh_map.
746         (move_stmt_eh_region_nr, move_stmt_eh_region_tree_nr): New.
747         (move_stmt_r): Remap eh region numbers in builtin calls,
748         resx and eh_dispatch.
749         (move_block_to_fn): Remove eh_offset parameter.  Use
750         maybe_duplicate_eh_stmt_fn.
751         (find_outermost_region_in_block): Operate on eh_region pointers
752         instead of region numbers.
753         (move_sese_region_to_fn): Expect eh_map instead of eh_offset from
754         duplicate_eh_regions.
755         * tree-cfgcleanup.c (tree_forwarder_block_p): Move entry block edge
756         test earlier.  Disallow EH landing pads.
757         * tree-cfa.c (create_tree_common_ann): Don't set ann->rn.
758         * tree-flow.h: Update declarations.
759         (struct tree_ann_common_d): Replace rn with lp_nr.
760         * tree-inline.c (copy_tree_body_r): Don't handle RESX_EXPR.
761         (remap_eh_region_nr, remap_eh_region_tree_nr): New.
762         (remap_gimple_stmt): Remap eh region numbers in builtin calls,
763         resx and eh_dispatch.
764         (copy_bb): Use maybe_duplicate_eh_stmt_fn.
765         (copy_edges_for_bb): Use make_eh_dispatch_edges.
766         (copy_cfg_body): Expect eh_map instead of eh_region_offset
767         from duplicate_eh_regions.
768         (estimate_num_insns): Don't handle EXC_PTR_EXPR or FILTER_EXPR;
769         update RESX; handle EH_DISPATCH.
770         (expand_call_inline): Set eh_lp_nr, not eh_region.
771         (maybe_inline_call_in_expr): Likewise.
772         * tree-inline.h (struct copy_body_data): Replace eh_region with
773         eh_lp_nr, eh_region_offset with eh_map.
774         * tree-optimize.c (execute_fixup_cfg): Use maybe_clean_eh_stmt.
775         * tree-pass.h (pass_lower_eh_dispatch, pass_lower_resx): New.
776         * tree-pretty-print.c (dump_generic_node): Don't handle
777         EXC_PTR_EXPR, FILTER_EXPR, RESX_EXPR.
778         * tree-sra.c (scan_function): Use maybe_clean_eh_stmt.
779         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Don't handle
780         EXC_PTR_EXPR, FILTER_EXPR.
781         * tree-ssa-operands.c (get_expr_operands): Likewise.
782         * tree-ssa-propagate.c (valid_gimple_rhs_p): Likewise.
783         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Likewise.
784         (ao_ref_init_from_vn_reference): Likewise.
785         * tree-ssa-sink.c (statement_sink_location): Likewise.
786         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
787         (mark_virtual_phi_result_for_renaming): Export.  Tidy.
788         * tree-ssa-pre.c (get_or_alloc_expr_for): Don't handle
789         EXC_PTR_EXPR, FILTER_EXPR.
790         (is_exception_related): Remove.
791         (compute_avail): Don't call it.
792         * tree-ssa-structalias.c: Remove VEC definitions for int and unsigned.
793         * tree.c (find_decls_types_in_eh_region): Update for eh_region changes.
794         (find_decls_types_in_node): Use FOR_ALL_EH_REGION_FN.
795         (build_common_builtin_nodes): Add enable_cxa_end_cleanup parameter.
796         Build EH builtins.
797         (build_resx): Remove.
798         * tree.def (EXC_PTR_EXPR, FILTER_EXPR, RESX_EXPR): Remove.
799         * tree.h: Update declarations.
800         (EH_FILTER_MUST_NOT_THROW): Remove.
801         (struct tree_label_decl): Add eh_landing_pad_nr.
802         (EH_LANDING_PAD_NR): New.
803         * value-prof.c (gimple_ic): Tidy variable names.  Update for
804         landing pad numbers.
805         (gimple_stringop_fixed_value): Tidy variable names.  Assert
806         that neither call stmt can throw.
807         * vecprim.h (uchar): New.
808         (VEC(uchar,heap), VEC(uchar,gc)): New.
809
810         * c-common.c (c_define_builtins): Update call to
811         build_common_builtin_nodes.
812         * c-parser.c (c_parse_file): Don't call
813         default_init_unwind_resume_libfunc.
814
815 2009-09-14  Richard Sandiford  <rdsandiford@googlemail.com>
816
817         * config/mips/mips-protos.h (mips_cfun_has_cprestore_slot_p): Declare.
818         (mips_cprestore_address_p): Likewise.
819         (mips_save_gp_to_cprestore_slot): Likewise.
820         (mips_restore_gp): Rename to...
821         (mips_restore_gp_from_cprestore_slot): ...this.
822         (mips_must_initialize_gp_p): Declare.
823         (mips_emit_save_slot_move): Likewise.
824         (mips_output_load_label): Return nothing.
825         (mips_eh_uses): Declare.
826         * config/mips/mips.h (TARGET_SPLIT_CALLS): Require epilogue_completed.
827         (TARGET_CPRESTORE_DIRECTIVE): New macro.
828         (TARGET_ABSOLUTE_JUMPS): Likewise.
829         (EH_USES): Likewise.
830         (FIRST_PSEUDO_REGISTER): Update comment.
831         (MIPS_ABSOLUTE_JUMP): New macro, extracted from...
832         (MIPS_CALL): ...here.
833         (REGISTER_NAMES): Add $cprestore.
834         * config/mips/mips.c (machine_function): Remove has_gp_insn_p.
835         Add load_label_length, has_inflexible_gp_insn_p,
836         has_flexible_gp_insn_p, must_initialize_gp_p and
837         must_restore_gp_when_clobbered_p.
838         (mips_expand_call): Don't generate split instructions here.
839         (mips_split_call): Update the call to mips_restore_gp after
840         the above name change.
841         (mips16_cfun_returns_in_fpr_p): Move earlier in file.
842         (mips_find_gp_ref): New function.
843         (mips_insn_has_inflexible_gp_ref_p): Likewise.
844         (mips_cfun_has_inflexible_gp_ref_p): Likewise.
845         (mips_insn_has_flexible_gp_ref_p): Likewise.
846         (mips_cfun_has_flexible_gp_ref_p): Likewise.
847         (mips_function_has_gp_insn): Delete.
848         (mips_global_pointer): Drop the df_regs_ever_live_p check.
849         Use the new functions above.  Only return INVALID_REGNUM
850         for TARGET_ABSOLUTE_JUMPS.
851         (mips_must_initialize_gp_p): New function.
852         (mips_get_cprestore_base_and_offset): New function, extracted from...
853         (mips_cprestore_slot): ...here.  Take a bool parameter.
854         (mips_cfun_has_cprestore_slot_p): New function.
855         (mips_cprestore_address_p): Likewise.
856         (mips_save_gp_to_cprestore_slot): Likewise.
857         (mips_restore_gp): Rename to...
858         (mips_restore_gp_from_cprestore_slot): ...this.  Assert
859         epilogue_completed.  Update the call to mips_cprestore_slot.
860         Test cfun->machine->must_restore_gp_when_clobbered_p.
861         (mips_direct_save_slot_move_p): New function.
862         (mips_emit_save_slot_move): Likewise.
863         (mips_output_cplocal): Test mips_must_initialize_gp_p () instead
864         of cfun->machine->global_pointer.
865         (mips_output_function_prologue): Check mips_must_initialize_gp_p ().
866         (mips_save_reg): Use mips_emit_save_slot_move.
867         (mips_expand_prologue): Set must_initialize_gp_p.
868         Use mips_cfun_has_cprestore_slot_p.  Use gen_potential_cprestore
869         for all cprestore saves.  Emit a use_cprestore instruction after
870         setting up the cprestore slot.
871         (mips_restore_reg): Use mips_emit_save_slot_move.
872         (mips_process_load_label): New function.
873         (mips_load_label_length): Likewise.
874         (mips_output_load_label): Don't return asm: output it here instead.
875         Use mips_process_load_label.
876         (mips_adjust_insn_length): Adjust the length of branch instructions
877         that have length MAX_PIC_BRANCH_LENGTH.
878         (mips_output_conditional_branch): Update the call to
879         mips_output_load_label.  Assume the branch target is OPERANDS[0]
880         rather than OPERANDS[1].  Use MIPS_ABSOLUTE_JUMP for absolute jumps.
881         (mips_output_order_conditional_branch): Swap the meaning of
882         OPERANDS[0] and OPERANDS[1].
883         (mips_variable_issue): Don't count ghost instructions.
884         (mips_expand_ghost_gp_insns): New function.
885         (mips_reorg): Rerun mips_reorg_process_insns if it returns true.
886         (mips_output_mi_thunk): Set must_initialize_gp_p.
887         (mips_eh_uses): New function.
888         * config/mips/predicates.md (cprestore_save_slot_operand)
889         (cprestore_load_slot_operand): New predicates.
890         * config/mips/mips.md (UNSPEC_POTENTIAL_CPRESTORE): New unspec.
891         (UNSPEC_MOVE_GP): Likewise.
892         (UNSPEC_CPRESTORE, UNSPEC_RESTORE_GP, UNSPEC_EH_RETURN)
893         (UNSPEC_CONSTTABLE_INT, UNSPEC_CONSTTABLE_FLOAT): Bump to make room.
894         (CPRESTORE_SLOT_REGNUM): New register.
895         (MAX_PIC_BRANCH_LENGTH): New constant.
896         (jal_macro): Use MIPS_ABSOLUTE_JUMPS.
897         (length): Use MAX_PIC_BRANCH_LENGTH as a placeholder for PIC long
898         branches.  Fix commentary.
899         (loadgp_newabi_<mode>): Change from unspec_volatile to unspec.
900         Only split if mips_must_initialize_gp_p; expand to nothing otherwise.
901         Change type to "ghost".
902         (loadgp_absolute_<mode>): Likewise.
903         (loadgp_rtp_<mode>): Likewise.
904         (copygp_mips16): Likewise.
905         (loadgp_blockage): Remove redundant mode attribute.
906         (potential_cprestore): New instruction.
907         (cprestore): Turn into an unspec set.
908         (use_cprestore): New instruction.
909         (*branch_fp): Swap operands 0 and 1.  Remove redundant mode attribute.
910         (*branch_fp_inverted): Likewise.
911         (*branch_order<mode>): Likewise.
912         (*branch_order<mode>_inverted): Likewise.
913         (*branch_equality<mode>): Likewise.
914         (*branch_equality<mode>_inverted): Likewise.
915         (*branch_bit<bbv><mode>): Likewise.
916         (*branch_bit<bbv><mode>_inverted): Likewise.
917         (*branch_equality<mode>_mips16): Remove redundant mode.
918         (jump): Turn into a define_expand.
919         (*jump_absolute): New instruction.
920         (*jump_pic): Likewise.
921         (*jump_mips16): Rename previously-unnamed pattern.  Remove
922         redundant mode attribute.
923         (restore_gp): Split on epilogue_completed rather than
924         reload_completed.  Change type to "ghost".
925         (move_gp<mode>): New instruction.
926         * config/mips/mips-dsp.md (mips_bposge): Swap operands 0 and 1.
927         Remove redundant mode attribute.
928         * config/mips/mips-ps-3d.md (bc1any4t): Likewise.
929         (bc1any4f, bc1any2t, bc1any2f): Likewise.
930         (*branch_upper_lower, *branch_upper_lower_inverted): Likewise.
931
932 2009-09-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
933
934         PR target/41210
935         * config/rs6000/rs6000.c (rs6000_function_value): V2DF and V2DI
936         are returned in the same register (vs34 or v2) that Altivec vector
937         types are returned in.
938         (rs6000_libcall_value): Ditto.
939
940         PR target/41331
941         * config/rs6000/rs6000.c (rs6000_emit_move): Use gen_add3_insn
942         instead of explicit addsi3/adddi3 calls.
943         (rs6000_split_multireg_move): Ditto.
944         (rs6000_emit_allocate_stack): Ditto.
945         (rs6000_emit_prologue): Ditto.
946         (rs6000_output_mi_thunk): Ditto.
947
948         * config/rs6000/rs6000.md (bswapdi*): Don't assume the pointer
949         size is 64 bits if we can use 64-bit registers.
950
951 2009-09-14  Bernd Schmidt  <bernd.schmidt@analog.com>
952
953         * config/bfin/bfin.c (bfin_longcall_p): Don't use short calls for weak
954         symbols.
955
956         From Jie Zhang <jie.zhang@analog.com>:
957         * config/bfin/bfin.c (bfin_expand_prologue): Ask do_link to
958         save FP and RETS with saveall attribute.
959         (bfin_expand_epilogue): Ask do_unlink to restore FP and RETS
960         with saveall attribute.
961
962         * config/bfin/bfin.c (bfin_expand_builtin,
963         case BFIN_BUILTIN_MULT_1X32X32): Force constants to registers for the
964         operands.
965
966         From Jie Zhang <jie.zhang@analog.com>:
967         * config/bfin/bfin.c (bfin_expand_builtin): Initialize icodes
968         before use in two places.
969         * config/bfin/bfin.md (AREG): Define mode iterator.
970         (reload_in, reload_out): Use mode iterator AREG.
971
972 2009-09-14  Richard Guenther  <rguenther@suse.de>
973
974         PR middle-end/41350
975         * dwarf2out.c (dwarf2out_begin_prologue): Adjust non-CFI asm
976         EH personality path.
977
978 2009-09-13  Richard Guenther  <rguenther@suse.de>
979             Rafael Avila de Espindola  <espindola@google.com>
980
981         * langhooks-def.h (LANG_HOOKS_EH_RUNTIME_TYPE): Define.
982         (LANG_HOOKS_EH_PERSONALITY): Likewise.
983         (LANG_HOOKS_INITIALIZER): Adjust.
984         (lhd_pass_through_t): Declare.
985         * langhooks.h (struct lang_hooks): Add eh_runtime_type and
986         eh_personality.
987         * langhooks.c (lhd_pass_through_t): New function.
988         * dwarf2out.c (output_call_frame_info, dwarf2out_do_cfi_startproc,
989         dwarf2out_begin_prologue): Use personality from current_function_decl.
990         * expr.h (get_personality_function): Declare.
991         * expr.c (get_personality_function): New function.
992         (build_personality_function): Likewise.
993         * libfuncs.h (libfunc_index): Remove LTI_eh_personality.
994         (eh_personality_libfunc): Remove.
995         * optabs.c (build_libfunc_function): New function split out from ...
996         (init_one_libfunc): ... here.
997         * tree.h (DECL_FUNCTION_PERSONALITY): New.
998         (tree_function_decl): Add personality.
999         (lhd_gcc_personality): Declare.
1000         (build_personality_function): Likewise.
1001         * tree.c (gcc_eh_personality_decl): New.
1002         (lhd_gcc_personality): New function.
1003         * except.h (lang_eh_runtime_type): Remove.
1004         (enum eh_personality_kind): New.
1005         (build_personality_function): Declare.
1006         (function_needs_eh_personality): Declare.
1007         * except.c (lang_eh_runtime_type): Remove.
1008         (function_needs_eh_personality): New function.
1009         (add_type_for_runtime): Call lang_hooks.type_for_runtime instead.
1010         (sjlj_emit_function_enter, output_function_exception_table):
1011         Use personality from current_function_decl.
1012         * tree-eh.c (lower_eh_constructs): Set DECL_FUNCTION_PERSONALITY.
1013         * tree-inline.c (tree_can_inline_p): Do not inline across different
1014         EH personalities.
1015         (expand_call_inline): Likewise.  Adjust the callers EH personality.
1016         (tree_function_versioning): Copy DECL_FUNCTION_PERSONALITY.
1017         * cgraph.c (cgraph_add_new_function): Set DECL_FUNCTION_PERSONALITY.
1018         * Makefile.in (cgraph.o): Add $(EXCEPT_H) dependency.
1019         (c-parser.o): Likewise
1020         * c-tree.h (c_eh_initialized_p): Remove.
1021         (c_maybe_initialize_eh): Likewise.
1022         * c-decl.c (finish_decl): Don't call c_maybe_initialize_eh.
1023         (finish_decl): Don't call c_maybe_initialize_eh.
1024         (c_eh_initialized_p): Remove.
1025         (c_maybe_initialize_eh): Likewise.
1026         * c-parser.c (c_parser_omp_construct): Likewise.
1027         (c_parse_file): Initialize exception handling.
1028
1029 2009-09-13  Kai Tietz  <kai.tietz@onevision.com>
1030
1031         * config.gcc (tm_file): Remove i386/biarch32.h
1032         for i?86-w64-mingw* case.
1033         (i?86-*-mingw* andx86_64-*-mingw*): Add multilib
1034         support.
1035         * config.host: Set for x64 mingw the option
1036         use_long_long_for_widest_fast_int to yes.
1037
1038 2009-09-13  Eric Botcazou  <ebotcazou@adacore.com>
1039
1040         * tree.h (DECL_IGNORED_P): Document further effect for FUNCTION_DECL.
1041         * dbxout.c (dbxout_function_end): Do not test DECL_IGNORED_P.
1042         (dbxout_begin_function): Likewise.
1043         * final.c (dwarf2_debug_info_emitted_p): New predicate.
1044         (final_start_function): Do not emit debug info if DECL_IGNORED_P is
1045         set on the function.
1046         (final_end_function): Likewise.
1047         (final_scan_insn): Likewise.
1048         (rest_of_handle_final): Likewise.
1049         * varasm.c (assemble_start_function): Likewise.
1050         * config/rs6000/xcoff.h (ASM_DECLARE_FUNCTION_NAME): Likewise.
1051
1052 2009-09-12  Jason Merrill  <jason@redhat.com>
1053
1054         * dbgcnt.c (dbg_cnt_process_single_pair): constify.
1055         * opts.c (common_handle_option): constify.
1056
1057 2009-09-12  Gerald Pfeifer  <gerald@pfeifer.com>
1058
1059         * doc/install.texi (avr): Remove obsolete reference site.
1060
1061 2009-09-12  Gerald Pfeifer  <gerald@pfeifer.com>
1062         
1063         * doc/install.texi (Binaries): Adjust AIX link.
1064
1065 2009-09-12  Akim Demaille  <demaille@gostai.com>
1066
1067         * doc/invoke.texi (-fstrict-aliasing): Correct two examples.
1068         Use an imperative sentence.
1069
1070 2009-09-11  Richard Henderson  <rth@redhat.com>
1071
1072         * gsstruct.def (DEFGSSTRUCT): Remove printable-name argument; add
1073         structure-name and has-tree-operands arguments; update all entries.
1074         * gimple.def (DEFGSCODE): Replace 3rd argument with GSS_symbol;
1075         update all entries.
1076         * gimple.c (gimple_ops_offset_): Use HAS_TREE_OP argument.
1077         (gsstruct_code_size): New.
1078         (gss_for_code_): New.
1079         (gss_for_code): Remove.
1080         (gimple_size): Rewrite using gsstruct_code_size.
1081         (gimple_statement_structure): Move to gimple.h.
1082         * gimple.h (gimple_ops_offset_, gss_for_code_): Declare.
1083         (gss_for_code, gimple_statement_structure): New.
1084         (gimple_ops): Use new arrays; tidy.
1085
1086 2009-09-11  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1087
1088         * config/pa/predicates.md (symbolic_operand): Require a CONST symbolic
1089         operand to be a PLUS expression.
1090         * config/pa/pa.c (pa_secondary_reload): Likewise.
1091
1092 2009-09-11  Jakub Jelinek  <jakub@redhat.com>
1093
1094         * combine.c (propagate_for_debug_subst): Call wrap_constant on top.
1095
1096         * print-rtl.c (print_rtx): Use JUMP_LABEL (in_rtx) instead of
1097         XEXP (in_rtx, 8).
1098
1099 2009-09-11  Bernd Schmidt  <bernd.schmidt@analog.com>
1100
1101         From Jie Zhang <jie.zhang@analog.com>:
1102         * doc/extend.texi (node Function Attributes): Document l2
1103         function attribute.
1104         (node Blackfin Variable Attributes): Document l2 variable attributes.
1105
1106 2009-09-11  Loren J. Rittle  <ljrittle@acm.org>
1107
1108         * config.gcc (*-*-freebsd*): Enable default_use_cxa_atexit
1109         to match the system compiler's configuration at inflection point.
1110         Add comment to remark a remaining difference with system compiler.
1111
1112         * configure.ac (*-*-freebsd*): Enable check for __stack_chk_fail.
1113         * configure: Regenerate.
1114
1115 2009-09-11  Bernd Schmidt  <bernd.schmidt@analog.com>
1116
1117         From Jie Zhang <jie.zhang@analog.com>:
1118         * config/bfin/bfin.c (bfin_expand_call): Handle L2 functions.
1119         (bfin_handle_l2_attribute): New.
1120         (bfin_attribute_table): Add l2 attribute.
1121
1122 2009-09-11  Michael Matz  <matz@suse.de>
1123
1124         PR middle-end/41275
1125         * tree-inline.c (remap_decls): Don't put DECL_EXTERNAL decls
1126         on the local_decls list.
1127
1128 2009-09-11  Alexandre Oliva  <aoliva@redhat.com>
1129
1130         PR debug/41276
1131         PR debug/41307
1132         * cselib.c (cselib_expand_value_rtx_cb): Document callback
1133         interface.
1134         (cselib_expand_value_rtx_1): Use callback for SUBREGs.  Adjust
1135         for VALUEs, to implement the documented interface.
1136         * var-tracking.c (vt_expand_loc_callback): Handle SUBREGs.
1137         Adjust for VALUEs and anything else, to implement the
1138         documented interface.
1139
1140 2009-09-10  Nathan Froyd  <froydnj@codesourcery.com>
1141
1142         * config/rs6000/rs6000.h (DATA_ALIGNMENT): Check that we are dealing
1143         with actual SPE/paired vector modes before using 64-bit alignment.
1144         Check that TYPE is a REAL_TYPE for TARGET_E500_DOUBLE.
1145
1146 2009-09-10  DJ Delorie  <dj@redhat.com>
1147
1148         * config/mep/mep.md (eh_epilogue): Defer until after epilogue is
1149         emitted.
1150
1151         * config/mep/mep.h (LEGITIMATE_CONSTANT_P): New.
1152         * config/mep/mep.c (mep_legitimate_constant_p): New.
1153         * config/mep/mep-protos.h: Prototype it.
1154
1155 2009-09-10  Richard Henderson  <rth@redhat.com>
1156
1157         * print-rtl.c (print_rtx): Fix JUMP_LABEL index.
1158
1159 2009-09-10  Jason Merrill  <jason@redhat.com>
1160
1161         * tree.c (chain_index): New fn.
1162         * tree.h: Declare it.
1163
1164 2009-09-10  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
1165
1166         * config/sol2-c.c (cmn_err_length_specs): Initialize
1167         scalar_identity_flag.
1168
1169 2009-09-10  Richard Henderson  <rth@redhat.com>
1170
1171         * tree.h (struct tree_decl_common): Move align member earlier;
1172         move label_decl_uid member ...
1173         (struct tree_label_decl): ... here.
1174         (LABEL_DECL_UID): Update to match.
1175
1176         * tree-cfg.c (dump_function_to_file): Dump eh tree with TDF_EH,
1177         not TDF_DETAILS.
1178
1179         * tree-cfg.c (gimple_redirect_edge_and_branch): Do
1180         gimple_try_redirect_by_replacing_jump test after no-op and EH tests.
1181
1182         * tree-cfg.c (split_edge_bb_loc): Don't disallow placement at
1183         dest_prev if the edge is complex.
1184
1185         * tree-cfg.c (is_ctrl_stmt): Use a switch.
1186
1187         * tree-cfg.c (gimple_can_merge_blocks_p): Move label and
1188         loop latch tests earlier.
1189
1190         * gimple-iterator.c (gimple_find_edge_insert_loc): Insert
1191         before GIMPLE_RETURN, not after its predecessor; insert
1192         before GIMPLE_RESX.
1193
1194         * gimple-iterator.c (gimple_find_edge_insert_loc): Use
1195         gimple_seq_empty_p to test for no PHI nodes.
1196         * tree-cfg.c (split_critical_edges): Likewise.
1197
1198         * c-common.h (c_dialect_cxx, c_dialect_objc): Boolify.
1199
1200 2009-09-10  Hariharan Sandanagobalane  <hariharan@picochip.com>
1201
1202         * final.c (shorten_branches) : Ignore DEBUG_INSN_P instructions
1203         introduced by the VTA branch merge.
1204
1205 2009-09-10  Uros Bizjak  <ubizjak@gmail.com>
1206
1207         * ira-conflicts.c: Use fputs or putc instead of fprintf
1208         where appropriate.
1209         * cfg.c: Ditto.
1210         * toplev.c: Ditto.
1211         * tree-switch-conversion.c: Ditto.
1212
1213 2009-09-10  Hariharan Sandanagobalane  <hariharan@picochip.com>
1214
1215         * config/picochip/picochip.c : Ignore DEBUG_INSN_P instructions
1216         introduced by the VTA branch merge.
1217
1218 2009-09-10  Uros Bizjak  <ubizjak@gmail.com>
1219
1220         Revert:
1221         2009-09-09  Uros Bizjak  <ubizjak@gmail.com>
1222
1223         PR rtl-optimization/39779
1224         * expr.c (convert_modes): Return when mode == oldmode after
1225         CONST_INTs are processed.
1226
1227 2009-09-10  Nick Clifton  <nickc@redhat.com>
1228
1229         * config/mep/mep.c (mep_encode_section_info): Copy weakness
1230         attribute and referring decl when creating renamed symbol.
1231
1232 2009-09-10  Richard Guenther  <rguenther@suse.de>
1233
1234         PR middle-end/41257
1235         * cgraphunit.c (cgraph_emit_thunks): Emit thunks only for
1236         reachable nodes.
1237         (cgraph_finalize_compilation_unit): Compute reachability
1238         before emitting thunks.  Properly process aliases before
1239         possibly removing unreachable nodes.
1240
1241 2009-09-10  Richard Guenther  <rguenther@suse.de>
1242
1243         PR middle-end/41254
1244         * tree.c (struct free_lang_data_d): Add worklist member.
1245         (find_decls_types_r): Push onto the worklist instead of recursing.
1246         Handle TREE_BINFOs properly.
1247         (find_decls_types): New function wrapped around find_decls_types_r
1248         to process the worklist.
1249         (find_decls_types_in_eh_region): Use it.
1250         (find_decls_types_in_node): Likewise.
1251         (find_decls_types_in_var): Likewise.
1252         (free_lang_data_in_cgraph): Likewise.  Free the worklist.
1253         * tree.h (RECORD_OR_UNION_TYPE_P): New.
1254         (AGGREGATE_TYPE_P): Adjust.
1255
1256 2009-09-09  Jason Merrill  <jason@redhat.com>
1257
1258         * configure.ac: Check glibc version even if we have an in-tree
1259         assembler.
1260
1261 2009-09-09  Anthony Green  <green@moxielogic.com>
1262
1263         * config/moxie/moxie.md (*movsi, *movhi, *movqi): Use xor to load
1264         the constant 0 when appropriate.
1265         * config/moxie/constraints.md: Add constraint O.
1266
1267         * config/moxie/moxie.c (moxie_setup_incoming_varargs): Adjust
1268         to pass up to 6 32-bit argument values in registers.
1269         (moxie_function_arg): Ditto.
1270         (moxie_arg_partial_bytes): Ditto.
1271         * config/moxie/moxie.h (FUNCTION_ARG_ADVANCE): Ditto.
1272         (REG_PARM_STACK_SPACE): Ditto.
1273         (FUNCTION_ARG_REGNO_P): Ditto.
1274
1275         * config/moxie/moxie.c (moxie_expand_prologue): Use dec
1276         instruction to allocate stack space.
1277
1278 2009-09-09  Segher Boessenkool  <segher@kernel.crashing.org>
1279
1280         * config/rs6000/rs6000.md (bswapdi2_64bit): Fix
1281         unnecessarily stringent constraints.  Fix address
1282         calculation in the splitters.
1283
1284 2009-09-09  Uros Bizjak  <ubizjak@gmail.com>
1285
1286         PR rtl-optimization/39779
1287         * expr.c (convert_modes): Return when mode == oldmode after
1288         CONST_INTs are processed.
1289
1290 2009-09-09  Kai Tietz  <kai.tietz@onevision.com>
1291
1292         PR/41315
1293         * config/i386.c (ix86_can_use_return_insn_p): Check for padding0, too.
1294         (ix86_expand_prologue): Take frame.padding0 into logic of
1295         to_allocate checks.
1296         (ix86_expand_epilogue): Likewise.
1297
1298 2009-09-09  Jakub Jelinek  <jakub@redhat.com>
1299
1300         * config/t-slibgcc-elf-ver (SHLIB_MAKE_SOLINK, SHLIB_INSTALL_SOLINK):
1301         New variables.
1302         (SHLIB_LINK, SHLIB_INSTALL): Use them.
1303         * config/t-slibgcc-libgcc: New file.
1304         * config.gcc (powerpc*-*-linux*, powerpc*-*-gnu*): Use it.
1305
1306 2009-09-09  Martin Jambor  <mjambor@suse.cz>
1307
1308         PR tree-optimization/41089
1309         * tree-sra.c (find_var_candidates): Do not consider va_lists in
1310         early SRA.
1311
1312 2009-09-09  Richard Henderson  <rth@redhat.com>
1313
1314         * gimple.h (CASE_GIMPLE_OMP): New.
1315         (is_gimple_omp): Use it.
1316         * tree-cfg.c (is_ctrl_altering_stmt): Likewise.
1317         (verify_gimple_debug): Likewise.
1318
1319 2009-09-09  Richard Guenther  <rguenther@suse.de>
1320
1321         PR tree-optimization/41101
1322         * tree-ssa-pre.c (maximal_set): Remove.
1323         (compute_antic_aux): Treat the maximal set as implicitly all ones.
1324         Defer all blocks we didn't visit at least one successor.
1325         (add_to_exp_gen): Do not add to the maximal set.
1326         (make_values_for_phi): Likewise.
1327         (compute_avail): Likewise.
1328         (init_pre): Do not allocate the maximal set.
1329         (execute_pre): Do not dump it.
1330
1331 2009-09-09  Martin Jambor  <mjambor@suse.cz>
1332
1333         * tree-cfg.c (verify_gimple_phi): Check that gimple_phi_result is
1334         an SSA_NAME rather than a is_gimple_variable.
1335
1336 2009-09-09  Richard Guenther  <rguenther@suse.de>
1337
1338         PR middle-end/41317
1339         * tree-ssa-ccp.c (maybe_fold_offset_to_component_ref): Remove
1340         code dealing with plain pointer bases.
1341         (maybe_fold_offset_to_reference): Likewise.
1342         (maybe_fold_stmt_addition): Adjust.
1343
1344 2009-09-09  Richard Guenther  <rguenther@suse.de>
1345
1346         * tree.c (free_lang_data_in_type): Do not free the type variant
1347         chains.
1348         (free_lang_data): Merge char_type_node with its properly signed
1349         variant.
1350         (pass_ipa_free): Collect after freeing language specific data.
1351
1352 2009-09-09  Michael Matz  <matz@suse.de>
1353
1354         PR middle-end/41268
1355         * cfgexpand.c (expand_gimple_stmt_1): Use an int for storing
1356         SUBREG_PROMOTED_UNSIGNED_P, instead of a bool.
1357         * rtl.h (struct rtx, SUBREG_PROMOTED_UNSIGNED_P): Update comments
1358         to reflect reality.
1359
1360 2009-09-08  DJ Delorie  <dj@redhat.com>
1361
1362         * config/mep/mep.c (conversions[]): Add "ml" pattern.
1363
1364 2009-09-04  Jason Merrill  <jason@redhat.com>
1365
1366         * tree.c (tree_find_value): Remove.
1367         * tree.h: Remove prototype.
1368         * varasm.c (assemble_external): Use value_member instead.
1369
1370 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
1371
1372         * toplev.c (process_options): Choose default debugging type when
1373         gtoggle enables debug info and type is unset.
1374
1375 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
1376
1377         PR debug/41276
1378         PR debug/41307
1379         * cselib.c (cselib_expand_value_rtx_1): Don't return copy of
1380         invalid subreg.
1381
1382 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
1383
1384         * configure: Rebuilt with modified libtool.m4.
1385
1386 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
1387
1388         PR debug/41229
1389         PR debug/41291
1390         PR debug/41300
1391         * tree-ssa.c (execute_update_addresses_taken): Update debug insns.
1392
1393 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
1394
1395         * tree-ssa-loop-ivopts.c (get_phi_with_result): Remove.
1396         (remove_statement): Likewise.
1397         (rewrite_use_nonlinear_expr): Adjust.
1398         (remove_unused_ivs): Collect SSA NAMEs to remove and call...
1399         * tree-ssa.c (release_defs_bitset): ... this.  New.
1400         * tree-flow.h (release_defs_bitset): Declare.
1401
1402 2009-09-08  Alexandre Oliva  <aoliva@redhat.com>
1403
1404         PR debug/41232
1405         * tree-ssa-phiopt.c (minmax_replacement): Skip debug stmts
1406         in the middle block.
1407
1408 2009-09-08  Kai Tietz  <kai.tietz@onevision.com>
1409
1410         * tree-ssa-reassoc.c (find_operand_rank): Cast pointer
1411         via intptr_t to long type.
1412         (insert_operand_rank): Cast long type via intptr_t to
1413         pointer type.
1414         * genattrtab.c (RTL_HASH): Use intptr_t to cast from
1415         pointer to scalar.
1416         * c-pretty-print.c (pp_c_tree_decl_identifier): Cast
1417         from pointer to unsigned via uintptr_t.
1418
1419         * configure.ac (GCC_STDINT_TYPES): Initialize intptr_t,
1420         uintptr_t, HAVE_INTTYPES_H, HAVE_STDINT_H, HAVE_UINTPTR_T,
1421         and HAVE_INTPTR_T.
1422         * configure: Regenerated.
1423         * config.in: Regenerated
1424         * system.h (stdint.h): Add include.
1425         (inttypes.h): Likewise.
1426         * Makefile.in (aclocal): Add config/stdint.m4.
1427         * aclocal.m4: Regenerated.
1428
1429 2009-09-08  Bernd Schmidt  <bernd.schmidt@analog.com>
1430
1431         * config/bfin/bfin.c (np_check_regno, np_after_branch): New static
1432         variables.
1433         (note_np_check_stores): New function.
1434         (harmless_null_pointer_p): New function.
1435         (trapping_loads_p): New args NP_REG and AFTER_NP_BRANCH.  Callers
1436         changed.  Take into account whether we're in the shadow of a condjump
1437         that tested NP_REG for NULL.
1438         Lose all code that tested for SEQUENCEs.
1439         (workaround_speculation): Avoid inserting NOPs for loads that are
1440         either always executed or a NULL pointer.
1441
1442 2009-09-08  Jan Hubicka  <jh@suse.cz>
1443
1444         * doc/invoke.texi (early-inlining-insns): Reduce from 12 to 8.
1445         * params.def (early-inlining-insns): Likewise.
1446
1447 2009-09-08  Jakub Jelinek  <jakub@redhat.com>
1448
1449         PR rtl-optimization/41239
1450         * sched-int.h (struct deps): Add last_function_call_may_noreturn field.
1451         * sched-rgn.c (deps_join): Join also last_function_call_may_noreturn
1452         lists.
1453         * sched-deps.c (sched_analyze_insn): Prevent moving trapping insns
1454         across calls, as the calls might not always return normally.
1455         (call_may_noreturn_p): New function.
1456         (deps_analyze_insn): Update last_function_call_may_noreturn list.
1457         (init_deps): Initialize it.
1458         (remove_from_deps): Also remove calls from
1459         last_function_call_may_noreturn list.
1460
1461 2009-09-07  Richard Henderson  <rth@redhat.com>
1462
1463         * tree-ssa-sccvn.c (vn_reference_lookup_3): Don't assume there are
1464         more VR->OPERANDS than LHS operands.  Free LHS before returning.
1465
1466 2009-09-07  Bernd Schmidt  <bernd.schmidt@analog.com>
1467
1468         * config/bfin/bfin.md (UNSPEC_VOLATILE_STALL): New constant.
1469         (attr "addrtype"): New member "spreg".
1470         Use it if mem_spfp_address_operand is true for the address.
1471         (attr "type"): New entry "stall".
1472         (cpu_unit "load"): New.
1473         (insn_reservations "load32", "loadp", "loadi"): Add reservation of
1474         "load".
1475         (insn_reservation "loadsp"): New.
1476         (insn_reservation "load_stall1"): New.
1477         (insn_reservation "load_stall3"): New.
1478         (stall): New insn.
1479         * config/bfin/predicates.md (const1_operand, const3_operand): New.
1480         (mem_p_address_operand): Exclude stack and frame pointer based
1481         addresses.
1482         (mem_spfp_address_operand): New; match them here.
1483         * config/bfin/bfin.c (add_sched_insns_for_speculation): New function.
1484         (bfin_reorg): Call it if scheduling insns.
1485         (bfin_gen_bundles): Remove dummy insns created by
1486         add_sched_insns_for_speculation.
1487
1488         From Jie Zhang <jie.zhang@analog.com>:
1489         * config/bfin/bfin-protos.h (enum bfin_cpu_type, bfin_cpu_type,
1490         bfin_si_revision, bfin_workarounds): Move these ...
1491         * config/bfin/bfin.h: ... here.
1492
1493         From Mike Frysinger  <michael.frysinger@analog.com>
1494         * config/bfin/bfin-protos.h (bfin_cpu_type): Add BFIN_CPU_BF542M,
1495         BFIN_CPU_BF544M, BFIN_CPU_BF547M, BFIN_CPU_BF548M, and BFIN_CPU_BF549M.
1496         * config/bfin/bfin.c (bfin_cpus[]): Add 0.3 for bf542m, bf544m,
1497         bf547m, bf548m, and bf549m.
1498         * config/bfin/bfin.h (TARGET_CPU_CPP_BUILTINS): Define __ADSPBF542M__
1499         for BFIN_CPU_BF542M, __ADSPBF544M__ for BFIN_CPU_BF544M,
1500         __ADSPBF547M__ for BFIN_CPU_BF547M, __ADSPBF548M__ for
1501         BFIN_CPU_BF548M, and __ADSPBF549M__ for BFIN_CPU_BF549M.
1502         * config/bfin/t-bfin-elf (MULTILIB_MATCHES): Select bf532-none for
1503         bf542m-none, bf544m-none, bf547m-none, bf548m-none, and bf549m-none.
1504         * config/bfin/t-bfin-linux (MULTILIB_MATCHES): Likewise.
1505         * config/bfin/t-bfin-uclinux (MULTILIB_MATCHES): Likewise.
1506         * doc/invoke.texi (Blackfin Options): Document that -mcpu now accepts
1507         bf542m, bf544m, bf547m, bf548m, and bf549m.
1508
1509         From Jie Zhang <jie.zhang@analog.com>:
1510         * config/bfin/predicates.md (p_register_operand): New predicate.
1511         (dp_register_operand): New predicate.
1512         * config/bfin/bfin-protos.h (WA_05000074): Define.
1513         (ENABLE_WA_05000074): Define.
1514         * config/bfin/bfin.c (bfin_cpus[]): Add WA_05000074 for all cpus.
1515         (bfin_gen_bundles): Put dsp32shiftimm instruction in slot[0].
1516         * config/bfin/bfin.md (define_attr type): Add dsp32shiftimm.
1517         (define_attr addrtype): Allow load/store register to be P register.
1518         (define_attr storereg): New.
1519         (define_cpu_unit anomaly_05000074): New.
1520         (define_insn_reservation dsp32shiftimm): New.
1521         (define_insn_reservation dsp32shiftimm_anomaly_05000074): New.
1522         (define_insn_reservation loadp): Cannot use slot2.
1523         (define_insn_reservation loadsp): Cannot use slot2.
1524         (define_insn_reservation storep): Cannot use slot2. Does not
1525         apply when working around 05000074.
1526         (define_insn_reservation storep_anomaly_05000074): New.
1527         (define_insn_reservation storei): Does not apply when working
1528         around 05000074.
1529         (define_insn_reservation storei_anomaly_05000074): New.
1530         (define_attr length): Add dsp32shiftimm case.
1531         (define_insn movsi_insn32, movsi_insv, ashlsi3_insn, ashrsi3,
1532         ror_one, rol_one, lshrsi3, lshrpdi3, ashrpdi3, movhiv2hi_low,
1533         movhiv2hi_high, composev2hi, packv2hi, movv2hi_hi,
1534         ssashiftv2hi3, ssashifthi3, ssashiftsi3, lshiftv2hi3, lshifthi3):
1535         Set type as dsp32shiftimm for dsp32shiftimm alternatives.
1536
1537 2009-09-07  Martin Jambor  <mjambor@suse.cz>
1538
1539         PR middle-end/41282
1540         * tree-sra.c (create_artificial_child_access): Return NULL if
1541         build_ref_for_offset fails.
1542         (propagate_subacesses_accross_link): Allow build_ref_for_offset
1543         and create_artificial_child_access to fail.
1544
1545 2009-09-06  Dmitry Gorbachev  <d.g.gorbachev@gmail.com>
1546
1547         PR c++/41214
1548         * unwind-dw2.c (uw_init_context_1): Mark noinline.
1549         * config/ia64/unwind-ia64.c (uw_init_context_1): Likewise.
1550         * config/xtensa/unwind-dw2-xtensa.c (uw_init_context_1): Likewise.
1551
1552 2009-09-07  Bernd Schmidt  <bernd.schmidt@analog.com>
1553
1554         * config/bfin/bfin.c (bfin_optimize_loop): When creating a new basic
1555         block, ensure it has an exit edge.  Emit a barrier after a jump.
1556
1557 2009-09-07  Nick Clifton  <nickc@redhat.com>
1558
1559         * gcc.c (this_is_linker_script): New variable.  Like
1560         this_is_library_file but for the %T constructor.
1561         (end_going_arg): If this_is_linker_script is set then locate the
1562         script and insert a --script switch before it
1563         (do_spec_2): Initialise this_is_linker_script.
1564         (do_spec_1): Likewise.  Handle %T construct.
1565         (eval_spec_function): Preserve this_is_linker_script.
1566         * doc/invoke.texi: Document %T construct in spec files.
1567         * config/m32c/m32c.h (LIB_SPEC): Use it.
1568
1569 2009-09-07  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
1570
1571         * rtl.h (PREFETCH_SCHEDULE_BARRIER_P): New macro.
1572         * sched-deps.c (sched_analyze_2): Make prefetches a hard barrier
1573         when volatile flag is set.
1574         * doc/rtl.texi (PREFETCH_SCHEDULE_BARRIER_P): Add documentation pieces.
1575
1576 2009-09-06  Eric Botcazou  <ebotcazou@adacore.com>
1577
1578         PR bootstrap/41241
1579         * combine-stack-adj.c (try_apply_stack_adjustment): Handle stores.
1580         (combine_stack_adjustments_for_block): Allow insns between stack
1581         adjustments and stores with corresponding pre-(dec|inc)rement or
1582         pre-modify operation.
1583
1584 2009-09-06  Jakub Jelinek  <jakub@redhat.com>
1585
1586         PR bootstrap/41241
1587         * combine-stack-adj.c (struct csa_memlist): Rename to...
1588         (struct csa_reflist): ... this.  Rename mem field to ref.
1589         (free_csa_memlist): Rename to...
1590         (free_csa_reflist): ... this.
1591         (record_one_stack_memref): Rename to...
1592         (record_one_stack_ref): ... this.  Handle also REG_P.
1593         (try_apply_stack_adjustment): Handle also REG_P.
1594         (struct record_stack_memrefs_data): Rename to...
1595         (struct record_stack_refs_data): ... this.  Rename memlist field to
1596         reflist.
1597         (record_stack_memrefs): Rename to...
1598         (record_stack_refs): ... this.  For DEBUG_INSNs keep traversing
1599         subexpressions instead of failing when a MEM contains SP references.
1600         For SP itself in DEBUG_INSNs queue it also onto reflist chain.
1601         (combine_stack_adjustments_for_block): Adjust for mem to ref renaming.
1602
1603 2009-09-06  Richard Guenther  <rguenther@suse.de>
1604
1605         PR middle-end/41144
1606         * tree.c (build_array_type): Do not record types marked
1607         with structural equality in the canonical type hashtable.
1608
1609 2009-09-06  Richard Guenther  <rguenther@suse.de>
1610
1611         PR middle-end/41261
1612         * tree-ssa-alias.c (refs_may_alias_p_1): Bail out for function decls.
1613
1614 2009-09-05  Richard Guenther  <rguenther@suse.de>
1615
1616         PR middle-end/41181
1617         * tree-ssa-ccp.c (maybe_fold_stmt_addition): Use the correct type.
1618
1619 2009-09-05  Richard Guenther  <rguenther@suse.de>
1620
1621         PR debug/41273
1622         * tree-ssa-operands.c (get_tmr_operands): Pass through opf_no_vops.
1623
1624 2009-09-05  Richard Guenther  <rguenther@suse.de>
1625
1626         PR middle-end/41271
1627         * tree-ssa.c (useless_type_conversion_p): Drop qualifiers
1628         before comparing function argument types.
1629
1630 2009-09-05  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1631
1632         PR target/41024
1633         * config/i386/mingw-w64.h (ASM_SPEC): Pass -v instead of -V to
1634         the assembler.
1635
1636 2009-09-04  Uros Bizjak  <ubizjak@gmail.com>
1637
1638         Revert:
1639         2009-08-18  Uros Bizjak  <ubizjak@gmail.com>
1640
1641         * config/alpha/alpha.c (alpha_output_mi_thunk_osf): Allocate insn
1642         locators before emit_insn is called.
1643
1644 2009-09-04  Vladimir Makarov  <vmakarov@redhat.com>
1645
1646         PR bootstrap/41241
1647         * ira.c (update_equiv_reg): Revert my previous patch for the PR.
1648         * reginfo.c (resize_reg_info): Call allocate_reg_info if necessary.
1649         (reginfo_init): Don't call allocate_reg_info.
1650
1651 2009-09-04  Uros Bizjak  <ubizjak@gmail.com>
1652
1653         PR target/41262
1654         * config/alpha/alpha.c (alpha_does_function_need_gp): Use
1655         NONDEBUG_INSN_P instead of INSN_P.
1656
1657 2009-09-04  Alexandre Oliva  <aoliva@redhat.com>
1658
1659         PR debug/41225
1660         * tree-vect-stmts.c (vect_stmt_relevant_p): Skip debug uses.
1661
1662 2009-09-04  Alexandre Oliva  <aoliva@redhat.com>
1663
1664         PR target/41252
1665         * config/arm/vfp.md (*cmpdf_split_vfp): Fix src mode in the second
1666         pattern of the split.
1667
1668 2009-09-04  Alexandre Oliva  <aoliva@redhat.com>
1669
1670         * toplev.c (process_options): Move setter of flag_var_tracking
1671         before other tests that depend on it.  Move down setter of
1672         flag_rename_registers.  Don't enable var-tracking-assignments
1673         by default if selective scheduling is enabled.  Warn if both
1674         are enabled.
1675
1676 2009-09-04  Alexandre Oliva  <aoliva@redhat.com>
1677
1678         * var-tracking.c (dv_is_decl_p): Adjust NULL behavior to match
1679         comment.  Use switch statement to catch overlaps between rtx
1680         and tree codes.  Accept FUNCTION_DECLs in addition to those in...
1681         (IS_DECL_CODE): ... here. Remove.
1682         (check_value_is_not_decl): Remove.
1683         (dv_from_decl, dv_from_value): Check after conversion.
1684
1685 2009-09-04  Richard Guenther  <rguenther@suse.de>
1686
1687         PR middle-end/41257
1688         * (cgraph_finalize_compilation_unit): Move finalizing aliases
1689         after emitting tunks.  Move emitting thunks and ctors from ...
1690         (cgraph_optimize): ... here.  Remove redundant
1691         cgraph_analyze_functions.
1692         * varasm.c (find_decl_and_mark_needed): Remove no longer
1693         necessary check.
1694         (finish_aliases_1): Adjust check for thunk aliases.
1695
1696 2009-09-04  Daniel Gutson  <dgutson@codesourcery.com>
1697
1698         * config/arm/arm.md (ctzsi2): Added braces
1699         to avoid warning that broke booststrap.
1700
1701 2009-09-04  Martin Jambor  <mjambor@suse.cz>
1702
1703         PR tree-optimization/41112
1704         * tree-sra.c (build_ref_for_offset_1): Signal that we cannot
1705         handle variable-bounded arrays.
1706         (expr_with_var_bounded_array_refs_p): New function.
1707         (analyze_access_subtree): Call expr_with_var_bounded_array_refs_p.
1708
1709 2009-09-04  Wolfgang Gellerich  <gellerich@de.ibm.com>
1710
1711         * config/s390/2097.md: Removed two incorrect bypasses.
1712         (z10_fsimpdf): Fixed latency.
1713         (z10_fhex): New insn_reservation.
1714         (z10_floaddf): Fixed latency.
1715         (z10_floadsf): Fixed latency.
1716         (z10_ftrunctf): Fixed latency.
1717         (z10_ftruncdf): Fixed latency.
1718         * config/s390/s390.c (z10_cost): Fixed values.
1719         (s390_adjust_priority): Added z10 path.
1720         * config/s390/s390.md (type): Added fhex.
1721         (*mov<mode>_64dfp): Updated type attribute.
1722         (*mov<mode>_64): Updated type attribute.
1723         (*mov<mode>_31): Updated type attribute.
1724         (*mov<mode>"): Likewise.
1725         * config/s390/2084.md (x_fsimpdf): Updated condition.
1726
1727 2009-09-04  Andreas Krebbel  <krebbel1@de.ibm.com>
1728
1729         * config/s390/s390.md ("*fmadd<mode>", "*fmsub<mode>"): Enable mem
1730         RTXs in the predicate for operand 1.
1731
1732 2009-09-03  Daniel Gutson  <dgutson@codesourcery.com>
1733
1734         * config/arm/arm.md (UNSPEC_RBIT): New constant.
1735         (rbitsi2): New insn.
1736         (ctzsi2): New expand.
1737         * config/arm/arm.h (CTZ_DEFINED_VALUE_AT_ZERO): New macro.
1738
1739 2009-09-03  Martin Jambor  <mjambor@suse.cz>
1740
1741         * tree-sra.c (duplicate_expr_for_different_base): Removed.
1742         (create_artificial_child_access): Use build_ref_for_offset instead
1743         of duplicate_expr_for_different_base.
1744         (propagate_subacesses_accross_link): Likewise.
1745
1746 2009-09-03  Richard Sandiford  <rdsandiford@googlemail.com>
1747
1748         * config/mips/mips.c (USEFUL_INSN_P): Use NONDEBUG_INSN_P instead
1749         of INSN_P.
1750         (mips16e_collect_argument_saves): Skip debug instructions.
1751         (mips_74k_agen_init): Use CALL_P || JUMP_P instead of !NONJUMP_INSN_P.
1752         (mips16_lay_out_constants): Use USEFUL_INSN_P instead of INSN_P.
1753         (r10k_insert_cache_barriers): Likewise.
1754         (mips_reorg_process_insns): Likewise.
1755
1756 2009-09-03  Vladimir Makarov  <vmakarov@redhat.com>
1757
1758         PR bootstrap/41241
1759         * ira.c (update_equiv_reg): Remove check on class likely spill.
1760
1761 2009-09-03  Jakub Jelinek  <jakub@redhat.com>
1762
1763         PR debug/41236
1764         * dwarf2out.c (loc_descriptor): Don't use SUBREG_REG macro on
1765         SIGN_EXTEND or ZERO_EXTEND.  Don't assume there is a REG inside of
1766         it or SUBREG.
1767
1768         PR debug/41238
1769         * function.c (assign_parm_find_stack_rtl): Don't set mem attributes on
1770         the stack slot if it is passed by invisible reference.
1771         * var-tracking.c (vt_add_function_parameters): Handle arguments passed
1772         by invisible reference.
1773
1774 2009-09-03  Bernd Schmidt  <bernd.schmidt@analog.com>
1775
1776         * config/bfin/linux.h (TARGET_SUPPORTS_SYNC_CALLS): Define to 1.
1777         * config/bfin/uclinux.h (TARGET_SUPPORTS_SYNC_CALLS): Define to 1.
1778         * config/bfin/bfin.h (TARGET_SUPPORTS_SYNC_CALLS): Provide default of
1779         0.
1780         * config/bfin/sync.md: New file.
1781         * config/bfin/bfin.md: Include it.
1782         (UNSPEC_ATOMIC): New.
1783         (UNSPEC_ONES): Provide a unique number.
1784
1785         From Jie Zhang <jie.zhang@analog.com>:
1786         * config/bfin/bfin.c (ret_regs): New.
1787         (must_save_fp_p): Don't return true because of frame_pointer_needed.
1788         (must_save_rets_p): New.
1789         (n_regs_saved_by_prologue): Use must_save_rets_p instead of
1790         current_function_is_leaf.
1791         (do_link): Likewise.
1792         (do_unlink): Likewise.
1793         (expand_interrupt_handler_prologue): Use ret_regs array.
1794         (expand_interrupt_handler_epilogue): Use ret_regs array and
1795         pass return register to gen_return_internal.
1796         (bfin_expand_epilogue): Pass return register to
1797         gen_return_internal.
1798         (bfin_expand_call): Explicitly clobber RETS.
1799         * config/bfin/bfin.h (FUNCTION_RETURN_REGISTERS): Define.
1800         * config/bfin/bfin.md (call_symbol_fdpic, call_value_symbol_fdpic,
1801         call_insn_fdpic, call_value_insn_fdpic, call_symbol,
1802         call_value_symbol, call_insn, call_value_insn): Explicitly clobber
1803         RETS.
1804         (return_internal): Take a reg rtx rather than the register number.
1805
1806 2009-09-03  H.J. Lu  <hongjiu.lu@intel.com>
1807
1808         * tree-parloops.c (parallelize_loops): Cast to HOST_WIDE_INT
1809         when comparing against estimated_loop_iterations_int return.
1810
1811 2009-09-03  Richard Guenther  <rguenther@suse.de>
1812
1813         * dwarf2out.c (dwarf2out_do_cfi_asm): Remove check of
1814         eh_personality_libfunc.
1815
1816 2009-09-03  Razya Ladelsky  <razya@il.ibm.com>
1817
1818         * tree-parloops.c (separate_decls_in_region): Add space.
1819
1820 2009-09-03  Razya Ladelsky  <razya@il.ibm.com>
1821
1822         * tree-parloops.c (separate_decls_in_region): Change the condition
1823         checking if there are reductions in the loop.
1824
1825 2009-09-03  Razya Ladelsky  <razya@il.ibm.com>
1826
1827         PR tree-optimization/38275
1828         * tree-parloops.c (parallelize_loops): Replace profitability condition
1829         for expected number of iterations.
1830
1831 2009-09-03  Alexandre Oliva  <aoliva@redhat.com>
1832
1833         * doc/invoke.texi (BUILD_CONFIG): Document --with-build-config.
1834         (bootstrap-debug): Explain conditions in which it becomes default.
1835         (bootstrap-debug-big): Rather than duplicate bootstrap-debug,
1836         make it add to it.
1837
1838 2009-09-03  Namhyung Kim  <namhyung@gmail.com>
1839
1840         * doc/invoke.texi (Optimize Options): Move
1841         -finline-small-functions to the -O2 list.
1842
1843 2009-09-03  Alexandre Oliva  <aoliva@redhat.com>
1844
1845         * toplev.c (process_options): Enable var-tracking-assignments
1846         by default if var-tracking is enabled.
1847
1848 2009-09-02  David Daney  <ddaney@caviumnetworks.com>
1849
1850         * cfgbuild.c (find_bb_boundaries): Split blocks containing a
1851         barrier.
1852         * emit-rtl.c (prev_nonnote_insn_bb): New function.
1853         * rtl.h (prev_nonnote_insn_bb): Declare it.
1854
1855 2009-09-03  Diego Novillo  <dnovillo@google.com>
1856
1857         * cgraph.c (cgraph_node_for_decl): New.
1858         * cgraph.h (cgraph_node_for_decl): Declare.
1859         * tree.c (host_integerp): Return 0 if T is NULL.
1860
1861 2009-09-03  Diego Novillo  <dnovillo@google.com>
1862
1863         * tree.h (struct alias_pair): Move from varasm.c.
1864         (alias_pairs): Likewise.
1865         (TYPE_MAXVAL): Define.
1866         (TYPE_MINVAL): Define.
1867         (iterative_hash_host_wide_int): Declare.
1868         (remove_unreachable_alias_pairs): Declare.
1869         * tree-pass.h (pass_ipa_free_lang_data): Declare.
1870         * diagnostic.c (default_diagnostic_starter): Make extern.
1871         (default_diagnostic_finalizer): Make extern.
1872         * diagnostic.h (default_diagnostic_starter): Declare.
1873         (default_diagnostic_finalizer): Declare.
1874         (default_tree_printer): Declare.
1875         * toplev.c (default_tree_printer): Make extern.
1876
1877 2009-09-03  Richard Guenther  <rguenther@suse.de>
1878             Diego Novillo  <dnovillo@google.com>
1879
1880         * cgraph.c (cgraph_add_new_function): Remove gimplification.
1881         * cgraphunit.c (cgraph_expand_function): Do not emit
1882         associated thunks from here.
1883         (cgraph_emit_thunks): New.
1884         (cgraph_optimize): Call it.
1885         Return if any IPA pass finds an error.
1886         * varasm.c (finish_aliases_1): Ignore errorneous aliases used
1887         by thunks.
1888
1889 2009-09-03  Simon Baldwin  <simonb@google.com>
1890             Rafael Espindola  <espindola@google.com>
1891             Richard Guenther  <rguenther@suse.de>
1892             Doug Kwan  <dougkwan@google.com>
1893             Diego Novillo  <dnovillo@google.com>
1894
1895         * tree.c: Include tree-pass.h, langhooks-def.h,
1896         diagnostic.h, cgraph.h, timevar.h, except.h and debug.h.
1897         (free_lang_data_in_type): New.
1898         (need_assembler_name_p): New.
1899         (free_lang_data_in_block): New.
1900         (free_lang_data_in_decl): New.
1901         (struct free_lang_data_d): New.
1902         (add_tree_to_fld_list): New.
1903         (find_decls_types_r): New.
1904         (get_eh_types_for_runtime): New.
1905         (find_decls_types_in_eh_region): New.
1906         (find_decls_types_in_node): New.
1907         (find_decls_types_in_var): New.
1908         (free_lang_data_in_cgraph): New.
1909         (free_lang_data): New.
1910         (gate_free_lang_data): New.
1911         (pass_ipa_free_lang_data): New.
1912
1913 2009-09-03  Diego Novillo  <dnovillo@google.com>
1914
1915         * timevar.def (TV_IPA_FREE_LANG_DATA): Define.
1916         * langhooks.h (struct lang_hooks): Add field free_lang_data.
1917         (lang_hooks): Remove const qualifier.
1918         * ipa.c (cgraph_remove_unreachable_nodes): Call
1919         remove_unreachable_alias_pairs.
1920         * except.c (add_type_for_runtime): Check if TYPE has
1921         already been converted.
1922         (lookup_type_for_runtime): Likewise.
1923         (check_handled): Handle converted types.
1924         * varasm.c (remove_unreachable_alias_pairs): New.
1925         * gimple.c: Include demangle.h.
1926         (gimple_decl_printable_name): New.
1927         (gimple_fold_obj_type_ref): New.
1928         * gimple.h (gimple_decl_printable_name): Declare.
1929         (gimple_fold_obj_type_ref): Declare.
1930         * passes.c (init_optimization_passes): Add pass
1931         pass_ipa_free_lang_data.
1932         * langhooks-def.h (LANG_HOOKS_FREE_LANG_DATA): Define.
1933         (LANG_HOOKS_INITIALIZER): Add LANG_HOOKS_FREE_LANG_DATA.
1934
1935 2009-09-03  Diego Novillo  <dnovillo@google.com>
1936
1937         * c-lang.c (lang_hooks): Remove const qualifier.
1938
1939 2009-09-02  Loren James Rittle  <ljrittle@acm.org>
1940
1941         * doc/install.texi (*-*-freebsd*): Update target information.
1942
1943 2009-09-02  Anatoly Sokolov  <aesok@post.ru>
1944
1945         * hard-reg-set.h (call_fixed_regs): Remove.
1946         * reginfo.c (call_fixed_regs): Remove.
1947         (init_reg_sets_1): Remove initialization of call_fixed_regs.
1948         (globalize_reg): Don't use call_fixed_regs.
1949         * caller-save.c (init_caller_save): Use call_fixed_reg_set instead of
1950         call_fixed_regs.
1951
1952 2009-09-01  Michael Matz  <matz@suse.de>
1953
1954         * expr.h (emit_storent_insn, expand_expr_real_1,
1955         expand_expr_real_2): Declare.
1956         * expr.c (emit_storent_insn, expand_expr_real_1,
1957         expand_expr_real_2): Export.
1958         (store_expr): Setting and evaluating dont_return_target is useless.
1959         (expand_expr_real_1, <case GOTO_EXPR, RETURN_EXPR, SWITCH_EXPR,
1960         LABEL_EXPR and ASM_EXPR>): Move to gcc_unreachable.
1961         * except.c (expand_resx_expr): Rename to ...
1962         (expand_resx_stmt): ... this.  Rewrite to take gimple statement.
1963         * except.h (expand_resx_stmt): Declare.
1964         * stmt.c: Add include gimple.h
1965         (expand_asm_expr): Rename to ...
1966         (expand_asm_stmt): ... this. Rewrite to take gimple statement.
1967         (expand_case): Rewrite to take gimple statement.
1968         * tree.h (expand_asm_stmt): Declare.
1969         (expand_case): Change prototype.
1970         * Makefile.in (stmt.o): Depend on gimple.h.
1971         * builtins.c (expand_builtin_synchronize): Build gimple asm
1972         statement, not an ASM_EXPR.
1973         * cfgexpand.c (gimple_cond_pred_to_tree, set_expr_location_r,
1974         gimple_to_tree, release_stmt_tree): Remove.
1975         (expand_gimple_cond): Don't call gimple_cond_pred_to_tree or
1976         ggc_free, but hold comparison code and operands separately.
1977         Call jumpif_1 and jumpifnot_1 instead of jumpif and jumpifnot.
1978         (expand_call_stmt, expand_gimple_stmt_1,
1979         expand_gimple_stmt): New helpers.
1980         (expand_gimple_tailcall): Don't call gimple_to_tree, expand_expr_stmt,
1981         release_stmt_tree.  Call expand_gimple_stmt instead.
1982         (expand_gimple_basic_block): Ditto.
1983
1984         * calls.c (emit_call_1): Don't look at EH regions here, make
1985         fntree parameter useless.
1986         (expand_call): New local rettype for TREE_TYPE(exp), use it
1987         throughout.  Remove local p, use addr instead.
1988         Don't look at EH regions here.
1989
1990 2009-09-02  Vladimir Makarov  <vmakarov@redhat.com>
1991
1992         * doc/invoke.texi (-fsched-pressure): Document it.
1993         (-fsched-reg-pressure-heuristic): Remove it.
1994
1995         * reload.c (ira.h): Include.
1996         (find_reloads): Add choosing reload on number of small spilled
1997         classes.
1998
1999         * haifa-sched.c (ira.h): Include.
2000         (sched_pressure_p, sched_regno_cover_class, curr_reg_pressure,
2001         saved_reg_pressure, curr_reg_live, saved_reg_live,
2002         region_ref_regs): New variables.
2003         (sched_init_region_reg_pressure_info, mark_regno_birth_or_death,
2004         initiate_reg_pressure_info, setup_ref_regs,
2005         initiate_bb_reg_pressure_info, save_reg_pressure,
2006         restore_reg_pressure, dying_use_p, print_curr_reg_pressure): New
2007         functions.
2008         (setup_insn_reg_pressure_info): New function.
2009         (rank_for_schedule): Add pressure checking and insn issue time.
2010         Remove comparison of insn reg weights.
2011         (ready_sort): Set insn reg pressure info.
2012         (update_register_pressure, setup_insn_max_reg_pressure,
2013         update_reg_and_insn_max_reg_pressure,
2014         sched_setup_bb_reg_pressure_info): New functions.
2015         (schedule_insn): Add code for printing and updating reg pressure info.
2016         (find_set_reg_weight, find_insn_reg_weight): Remove.
2017         (ok_for_early_queue_removal): Do nothing if pressure_only_p.
2018         (debug_ready_list): Print reg pressure info.
2019         (schedule_block): Ditto.  Check insn issue time.
2020         (sched_init): Set up sched_pressure_p.  Allocate and set up some
2021         reg pressure related info.
2022         (sched_finish): Free some reg pressure related info.
2023         (fix_tick_ready): Make insn always ready if pressure_p.
2024         (init_h_i_d): Don't call find_insn_reg_weight.
2025         (haifa_finish_h_i_d): Free insn reg pressure info.
2026
2027         * ira-int.h (ira_hard_regno_cover_class, ira_reg_class_nregs,
2028         ira_memory_move_cost, ira_class_hard_regs,
2029         ira_class_hard_regs_num, ira_no_alloc_regs,
2030         ira_available_class_regs, ira_reg_class_cover_size,
2031         ira_reg_class_cover, ira_class_translate): Move to ira.h.
2032
2033         * ira-lives.c (single_reg_class): Check mode to find how many
2034         registers are necessary for operand.
2035         (ira_implicitly_set_insn_hard_regs): New.
2036
2037         * common.opt (fsched-pressure): New options.
2038         (fsched-reg-pressure-heuristic): Remove.
2039
2040         * ira.c (setup_eliminable_regset): Rename to
2041         ira_setup_eliminable_regset.  Make it external.
2042         (expand_reg_info): Pass cover class to setup_reg_classes.
2043         (ira): Call resize_reg_info instead of allocate_reg_info.
2044
2045         * sched-deps.c: Include ira.h.
2046         (implicit_reg_pending_clobbers, implicit_reg_pending_uses): New.
2047         (create_insn_reg_use, create_insn_reg_set, setup_insn_reg_uses,
2048         reg_pressure_info, insn_use_p, mark_insn_pseudo_birth,
2049         mark_insn_hard_regno_birth, mark_insn_reg_birth,
2050         mark_pseudo_death, mark_hard_regno_death, mark_reg_death,
2051         mark_insn_reg_store, mark_insn_reg_clobber,
2052         setup_insn_reg_pressure_info): New.
2053         (sched_analyze_1): Update implicit_reg_pending_uses.
2054         (sched_analyze_insn): Find implicit sets, uses, clobbers of regs.
2055         Use them to create dependencies.  Set insn reg uses and pressure
2056         info.  Process reg_pending_uses in one place.
2057         (free_deps): Free implicit sets.
2058         (remove_from_deps): Remove implicit sets if necessary.  Check
2059         implicit sets when clearing reg_last_in_use.
2060         (init_deps_global): Clear implicit_reg_pending_clobbers and
2061         implicit_reg_pending_uses.
2062
2063         * ira.h (ira_hard_regno_cover_class, ira_reg_class_nregs,
2064         ira_memory_move_cost, ira_class_hard_regs,
2065         ira_class_hard_regs_num, ira_no_alloc_regs,
2066         ira_available_class_regs, ira_reg_class_cover_size,
2067         ira_reg_class_cover, ira_class_translate): Move from ira-int.h.
2068         (ira_setup_eliminable_regset, ira_set_pseudo_classes,
2069         ira_implicitly_set_insn_hard_regs): New prototypes.
2070
2071         * ira-costs.c (pseudo_classes_defined_p, allocno_p,
2072         cost_elements_num): New variables.
2073         (allocno_costs, total_costs): Rename to costs and
2074         total_allocno_costs.
2075         (COSTS_OF_ALLOCNO): Rename to COSTS.
2076         (allocno_pref): Rename to pref.
2077         (allocno_pref_buffer): Rename to pref_buffer.
2078         (common_classes): Rename to regno_cover_class.
2079         (COST_INDEX): New.
2080         (record_reg_classes): Set allocno attributes only if allocno_p.
2081         (record_address_regs): Ditto.  Use COST_INDEX instead of ALLOCNO_NUM.
2082         (scan_one_insn): Use COST_INDEX and COSTS instead of ALLOCNO_NUM
2083         and COSTS_OF_ALLOCNO.
2084         (print_costs): Rename to print_allocno_costs.
2085         (print_pseudo_costs): New.
2086         (process_bb_node_for_costs): Split into 2 functions with new
2087         function process_bb_for_costs.  Pass BB to process_bb_for_costs.
2088         (find_allocno_class_costs): Rename to find_costs_and_classes.  Add
2089         new parameter dump_file.  Use cost_elements_num instead of
2090         ira_allocnos_num.  Make one iteration if preferred classes were
2091         already calculated for scheduler.  Make 2 versions of code
2092         depending on allocno_p.
2093         (setup_allocno_cover_class_and_costs): Check allocno_p.  Use
2094         regno_cover_class and COSTS instead of common_classes and
2095         COSTS_OF_ALLOCNO.
2096         (init_costs, finish_costs): New.
2097         (ira_costs): Set up allocno_p and cost_elements_num.  Call
2098         init_costs and finish_costs.
2099         (ira_set_pseudo_classes): New.
2100
2101         * rtl.h (allocate_reg_info): Remove.
2102         (resize_reg_info): Change return type.
2103         (reg_cover_class): New.
2104         (setup_reg_classes): Add new parameter.
2105
2106         * sched-int.h (struct deps_reg): New member implicit_sets.
2107         (sched_pressure_p, sched_regno_cover_class): New external definitions.
2108         (INCREASE_BITS): New macro.
2109         (struct reg_pressure_data, struct reg_use_data): New.
2110         (struct _haifa_insn_data): Remove reg_weight.  Add members
2111         reg_pressure, reg_use_list, reg_set_list, and
2112         reg_pressure_excess_cost_change.
2113         (struct deps): New member implicit_sets.
2114         (pressure_p): New variable.
2115         (COVER_CLASS_BITS, INCREASE_BITS): New macros.
2116         (struct reg_pressure_data, struct reg_use_data): New.
2117         (INSN_REG_WEIGHT): Remove.
2118         (INSN_REG_PRESSURE, INSN_MAX_REG_PRESSURE, INSN_REG_USE_LIST,
2119         INSN_REG_SET_LIST, INSN_REG_PRESSURE_EXCESS_COST_CHANGE): New macros.
2120         (sched_init_region_reg_pressure_info,
2121         sched_setup_bb_reg_pressure_info): New prototypes.
2122
2123         * reginfo.c (struct reg_pref): New member coverclass.
2124         (reg_cover_class): New function.
2125         (reginfo_init, pass_reginfo_init): Move after free_reg_info.
2126         (reg_info_size): New variable.
2127         (allocate_reg_info): Make static.  Setup reg_info_size.
2128         (resize_reg_info): Use reg_info_size.  Return flag of resizing.
2129         (setup_reg_classes): Add a new parameter.  Setup cover class too.
2130
2131         * Makefile.in (reload.o, haifa-sched.o, sched-deps.o): Add ira.h to
2132         the dependencies.
2133
2134         * sched-rgn.c (deps_join): Set up implicit_sets.
2135         (schedule_region): Set up region and basic blocks pressure
2136         relative info.
2137
2138         * passes.c (init_optimization_passes): Move
2139         pass_subregs_of_mode_init before pass_sched.
2140
2141 2009-09-02  Martin Jambor  <mjambor@suse.cz>
2142
2143         * tree-sra.c (struct access): New field grp_hint.
2144         (dump_access): Dump grp_hint.
2145         (sort_and_splice_var_accesses): Set grp_hint if a group is read
2146         multiple times.
2147         (analyze_access_subtree): Only scalarize accesses with grp_hint set or
2148         those which have been specifically read and somehow written to.
2149         (propagate_subacesses_accross_link): Set grp_hint of right child and
2150         also possibly of the left child.
2151
2152 2009-09-02  Jakub Jelinek  <jakub@redhat.com>
2153
2154         * tree-object-size.c (addr_object_size): Always use object_size_type
2155         0 or 2 when determining the pointer pointed object size.
2156
2157 2009-09-02  Richard Guenther  <rguenther@suse.de>
2158
2159         Revert
2160         2009-08-31  Richard Guenther  <rguenther@suse.de>
2161
2162         * builtins.c (fold_builtin_memory_op): Use the alias oracle
2163         to query if the memory regions for memmove overlap.
2164         * tree-ssa-alias.c (ptr_deref_may_alias_decl_p): Relax the
2165         asserts on pointers, instead deal with odd trees.
2166         (ptr_derefs_may_alias_p): Likewise.
2167         (refs_may_alias_p_1): Constructor bases also never alias.
2168
2169 2009-08-01  Christian Bruel  <christian.bruel@st.com>
2170
2171         Revert:
2172         2009-07-31  Christian Bruel  <christian.bruel@st.com>
2173         * gcc/config.gcc (sh*-*-elf): test with_libgloss.
2174
2175 2009-09-01  Alexandre Oliva  <aoliva@redhat.com>
2176
2177         * doc/invoke.texi (-fvar-tracking-assignments): New.
2178         (-fvar-tracking-assignments-toggle): New.
2179         (-fdump-final-insns=file): Mark filename as optional.
2180         (--param min-nondebug-insn-uid): New.
2181         (-gdwarf-@{version}): Mention version 4.
2182         * opts.c (common_handle_option): Accept it.
2183         * tree-vrp.c (find_assert_locations_1): Skip debug stmts.
2184         * regrename.c (regrename_optimize): Drop last.  Don't count debug
2185         insns as uses.  Don't reject change because of debug insn.
2186         (do_replace): Reject DEBUG_INSN as chain starter.  Take base_regno
2187         from the chain starter, and check for inexact matches in DEBUG_INSNS.
2188         (scan_rtx_reg): Accept inexact matches in DEBUG_INSNs.
2189         (build_def_use): Simplify and fix the marking of DEBUG_INSNs.
2190         * sched-ebb.c (schedule_ebbs): Skip boundary debug insns.
2191         * fwprop.c (forward_propagate_and_simplify): ...into debug insns.
2192         * doc/gimple.texi (is_gimple_debug): New.
2193         (gimple_debug_bind_p): New.
2194         (is_gimple_call, gimple_assign_cast_p): End sentence with period.
2195         * doc/install.texi (bootstrap-debug): More details.
2196         (bootstrap-debug-big, bootstrap-debug-lean): Document.
2197         (bootstrap-debug-lib): More details.
2198         (bootstrap-debug-ckovw): Update.
2199         (bootstrap-time): New.
2200         * tree-into-ssa.c (mark_def_sites): Skip debug stmts.
2201         (insert_phi_nodes_for): Insert debug stmts.
2202         (rewrite_stmt): Take iterator.  Insert debug stmts.
2203         (rewrite_enter_block): Adjust.
2204         (maybe_replace_use_in_debug_stmt): New.
2205         (rewrite_update_stmt): Use it.
2206         (mark_use_interesting): Return early for debug stmts.
2207         * tree-ssa-loop-im.c (rewrite_bittest): Propagate DEFs into debug
2208         stmts before replacing stmt.
2209         (move_computations_stmt): Likewise.
2210         * ira-conflicts.c (add_copies): Skip debug insns.
2211         * regstat.c (regstat_init_n_sets_and_refs): Discount debug insns.
2212         (regstat_bb_compute_ri): Skip debug insns.
2213         * tree-ssa-threadupdate.c (redirection_block_p): Skip debug stmts.
2214         * tree-ssa-loop-manip.c (find_uses_to_rename_stmt,
2215         check_loop_closed_ssa_stmt): Skip debug stmts.
2216         * tree-tailcall.c (find_tail_calls): Likewise.
2217         * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): Likewise.
2218         * tree.h (MAY_HAVE_DEBUG_STMTS): New.
2219         (build_var_debug_value_stat): Declare.
2220         (build_var_debug_value): Define.
2221         (target_for_debug_bind): Declare.
2222         * reload.c (find_equiv_reg): Skip debug insns.
2223         * rtlanal.c (reg_used_between_p): Skip debug insns.
2224         (side_effects_p): Likewise.
2225         (canonicalize_condition): Likewise.
2226         * ddg.c (create_ddg_dep_from_intra_loop_link): Check that non-debug
2227         insns never depend on debug insns.
2228         (create_ddg_dep_no_link): Likewise.
2229         (add_cross_iteration_register_deps): Use ANTI_DEP for debug insns.
2230         Don't add inter-loop dependencies for debug insns.
2231         (build_intra_loop_deps): Likewise.
2232         (create_ddg): Count debug insns.
2233         * ddg.h (struct ddg::num_debug): New.
2234         (num_backargs): Pair up with previous int field.
2235         * diagnostic.c (diagnostic_report_diagnostic): Skip notes on
2236         -fcompare-debug-second.
2237         * final.c (get_attr_length_1): Skip debug insns.
2238         (rest_of_clean-state): Don't dump CFA_RESTORE_STATE.
2239         * gcc.c (invoke_as): Call compare-debug-dump-opt.
2240         (driver_self_specs): Map -fdump-final-insns to
2241         -fdump-final-insns=..
2242         (get_local_tick): New.
2243         (compare_debug_dump_opt_spec_function): Test for . argument and
2244         compute output name.  Compute temp output spec without flag name.
2245         Compute -frandom-seed.
2246         (OPT): Undef after use.
2247         * cfgloopanal.c (num_loop_insns): Skip debug insns.
2248         (average_num_loop_insns): Likewise.
2249         * params.h (MIN_NONDEBUG_INSN_UID): New.
2250         * gimple.def (GIMPLE_DEBUG): New.
2251         * ipa-reference.c (scan_stmt_for_static_refs): Skip debug stmts.
2252         * auto-inc-dec.c (merge_in_block): Skip debug insns.
2253         (merge_in_block): Fix whitespace.
2254         * toplev.c (flag_var_tracking): Update comment.
2255         (flag_var_tracking_assignments): New.
2256         (flag_var_tracking_assignments_toggle): New.
2257         (process_options): Don't open final insns dump file if we're not
2258         going to write to it.  Compute defaults for var_tracking.
2259         * df-scan.c (df_insn_rescan_debug_internal): New.
2260         (df_uses_record): Handle debug insns.
2261         * haifa-sched.c (ready): Initialize n_debug.
2262         (contributes_to_priority): Skip debug insns.
2263         (dep_list_size): New.
2264         (priority): Use it.
2265         (rank_for_schedule): Likewise.  Schedule debug insns as soon as
2266         they're ready.  Disregard previous debug insns to make decisions.
2267         (queue_insn): Never queue debug insns.
2268         (ready_add, ready_remove_first, ready_remove): Count debug insns.
2269         (schedule_insn): Don't reject debug insns because of issue rate.
2270         (get_ebb_head_tail, no_real_insns_p): Skip boundary debug insns.
2271         (queue_to_ready): Skip and discount debug insns.
2272         (choose_ready): Let debug insns through.
2273         (schedule_block): Check boundary debug insns.  Discount debug
2274         insns, schedule them early.  Adjust whitespace.
2275         (set_priorities): Check for boundary debug insns.
2276         (add_jump_dependencies): Use dep_list_size.
2277         (prev_non_location_insn): New.
2278         (check_cfg): Use it.
2279         * tree-ssa-loop-ivopts.c (find-interesting_users): Skip debug
2280         stmts.
2281         (remove_unused_ivs): Reset debug stmts.
2282         * modulo-sched.c (const_iteration_count): Skip debug insns.
2283         (res_MII): Discount debug insns.
2284         (loop_single_full_bb_p): Skip debug insns.
2285         (sms_schedule): Likewise.
2286         (sms_schedule_by_order): Likewise.
2287         (ps_has_conflicts): Likewise.
2288         * caller-save.c (refmarker_fn): New.
2289         (save_call_clobbered_regs): Replace regs with saved mem in
2290         debug insns.
2291         (mark_referenced_regs): Take pointer, mark and arg.  Adjust.
2292         Call refmarker_fn mark for hardregnos.
2293         (mark_reg_as_referenced): New.
2294         (replace_reg_with_saved_mem): New.
2295         * ipa-pure-const.c (check_stmt): Skip debug stmts.
2296         * cse.c (cse_insn): Canonicalize debug insns.  Skip them when
2297         searching back.
2298         (cse_extended_basic_block): Skip debug insns.
2299         (count_reg_usage): Likewise.
2300         (is_dead_reg): New, split out of...
2301         (set_live_p): ... here.
2302         (insn_live_p): Use it for debug insns.
2303         * tree-stdarg.c (check_all_va_list_escapes): Skip debug stmts.
2304         (execute_optimize_stdarg): Likewise.
2305         * tree-ssa-dom.c (propagate_rhs_into_lhs): Likewise.
2306         * tree-ssa-propagate.c (substitute_and_fold): Don't regard
2307         changes in debug stmts as changes.
2308         * sel-sched.c (moving_insn_creates_bookkeeping_block_p): New.
2309         (moveup_expr): Don't move across debug insns.  Don't move
2310         debug insn if it would create a bookkeeping block.
2311         (moveup_expr_cached): Don't use cache for debug insns that
2312         are heads of blocks.
2313         (compute_av_set_inside_bb): Skip debug insns.
2314         (sel_rank_for_schedule): Schedule debug insns first.  Remove
2315         dead code.
2316         (block_valid_for_bookkeeping_p); Support lax searches.
2317         (create_block_for_bookkeeping): Adjust block numbers when
2318         encountering debug-only blocks.
2319         (find_place_for_bookkeeping): Deal with debug-only blocks.
2320         (generate_bookkeeping_insn): Accept no place to insert.
2321         (remove_temp_moveop_nops): New argument full_tidying.
2322         (prepare_place_to_insert): Deal with debug insns.
2323         (advance_state_on_fence): Debug insns don't start cycles.
2324         (update_boundaries): Take fence as argument.  Deal with
2325         debug insns.
2326         (schedule_expr_on_boundary): No full_tidying on debug insns.
2327         (fill_insns): Deal with debug insns.
2328         (track_scheduled_insns_and_blocks): Don't count debug insns.
2329         (need_nop_to_preserve_insn_bb): New, split out of...
2330         (remove_insn_from_stream): ... this.
2331         (fur_orig_expr_not_found): Skip debug insns.
2332         * rtl.def (VALUE): Move up.
2333         (DEBUG_INSN): New.
2334         * tree-ssa-sink.c (all_immediate_uses_same_place): Skip debug stmts.
2335         (nearest_common_dominator_of_uses): Take debug_stmts argument.
2336         Set it if debug stmts are found.
2337         (statement_sink_location): Skip debug stmts.  Propagate
2338         moving defs into debug stmts.
2339         * ifcvt.c (first_active_insn): Skip debug insns.
2340         (last_active_insns): Likewise.
2341         (cond_exec_process_insns): Likewise.
2342         (noce_process_if_block): Likewise.
2343         (check_cond_move_block): Likewise.
2344         (cond_move_convert_if_block): Likewise.
2345         (block_jumps_and_fallthru_p): Likewise.
2346         (dead_or_predicable): Likewise.
2347         * dwarf2out.c (debug_str_hash_forced): New.
2348         (find_AT_string): Add comment.
2349         (gen_label_for_indirect_string): New.
2350         (get_debug_string_label): New.
2351         (AT_string_form): Use it.
2352         (mem_loc_descriptor): Handle non-TLS symbols.  Handle MINUS , DIV,
2353         MOD, AND, IOR, XOR, NOT, ABS, NEG, and CONST_STRING.  Accept but
2354         discard COMPARE, IF_THEN_ELSE, ROTATE, ROTATERT, TRUNCATE and
2355         several operations that cannot be represented with DWARF opcodes.
2356         (loc_descriptor): Ignore SIGN_EXTEND and ZERO_EXTEND.  Require
2357         dwarf_version 4 for DW_OP_implicit_value and DW_OP_stack_value.
2358         (dwarf2out_var_location): Take during-call mark into account.
2359         (output_indirect_string): Update comment.  Output if there are
2360         label and references.
2361         (prune_indirect_string): New.
2362         (prune_unused_types): Call it if debug_str_hash_forced.
2363         More in dwarf2out.c, from Jakub Jelinek <jakub@redhat.com>:
2364         (dw_long_long_const): Remove.
2365         (struct dw_val_struct): Change val_long_long type to rtx.
2366         (print_die, attr_checksum, same_dw_val_p, loc_descriptor): Adjust for
2367         val_long_long change to CONST_DOUBLE rtx from a long hi/lo pair.
2368         (output_die): Likewise.  Use HOST_BITS_PER_WIDE_INT size of each
2369         component instead of HOST_BITS_PER_LONG.
2370         (output_loc_operands): Likewise.  For const8* assert
2371         HOST_BITS_PER_WIDE_INT rather than HOST_BITS_PER_LONG is >= 64.
2372         (output_loc_operands_raw): For const8* assert HOST_BITS_PER_WIDE_INT
2373         rather than HOST_BITS_PER_LONG is >= 64.
2374         (add_AT_long_long): Remove val_hi and val_lo arguments, add
2375         val_const_double.
2376         (size_of_die): Use HOST_BITS_PER_WIDE_INT size multiplier instead of
2377         HOST_BITS_PER_LONG for dw_val_class_long_long.
2378         (add_const_value_attribute): Adjust add_AT_long_long caller.  Don't
2379         handle TLS SYMBOL_REFs.  If CONST wraps a constant, tail recurse.
2380         (dwarf_stack_op_name): Handle DW_OP_implicit_value and
2381         DW_OP_stack_value.
2382         (size_of_loc_descr, output_loc_operands, output_loc_operands_raw):
2383         Handle DW_OP_implicit_value.
2384         (extract_int): Move prototype earlier.
2385         (mem_loc_descriptor): For SUBREG punt if inner
2386         mode size is wider than DWARF2_ADDR_SIZE.  Handle SIGN_EXTEND
2387         and ZERO_EXTEND by DW_OP_shl and DW_OP_shr{a,}.  Handle
2388         EQ, NE, GT, GE, LT, LE, GTU, GEU, LTU, LEU, SMIN, SMAX, UMIN,
2389         UMAX, SIGN_EXTRACT, ZERO_EXTRACT.
2390         (loc_descriptor): Compare mode size with DWARF2_ADDR_SIZE
2391         instead of Pmode size.
2392         (loc_descriptor): Add MODE argument.  Handle CONST_INT, CONST_DOUBLE,
2393         CONST_VECTOR, CONST, LABEL_REF and SYMBOL_REF if mode != VOIDmode,
2394         attempt to handle other expressions.  Don't handle TLS SYMBOL_REFs.
2395         (concat_loc_descriptor, concatn_loc_descriptor,
2396         loc_descriptor_from_tree_1): Adjust loc_descriptor callers.
2397         (add_location_or_const_value_attribute): Likewise.  For single
2398         location loc_lists attempt to use add_const_value_attribute
2399         for constant decls.  Add DW_AT_const_value even if
2400         NOTE_VAR_LOCATION is VAR_LOCATION with CONSTANT_P or CONST_STRING
2401         in its expression.
2402         * cfgbuild.c (inside_basic_block_p): Handle debug insns.
2403         (control_flow_insn_p): Likewise.
2404         * tree-parloops.c (eliminate_local_variables_stmt): Handle debug stmt.
2405         (separate_decls_in_region_debug_bind): New.
2406         (separate_decls_in_region): Process debug bind stmts afterwards.
2407         * recog.c (verify_changes): Handle debug insns.
2408         (extract_insn): Likewise.
2409         (peephole2_optimize): Skip debug insns.
2410         * dse.c (scan_insn): Skip debug insns.
2411         * sel-sched-ir.c (return_nop_to_pool): Take full_tidying argument.
2412         Pass it on.
2413         (setup_id_for_insn): Handle debug insns.
2414         (maybe_tidy_empty_bb): Adjust whitespace.
2415         (tidy_control_flow): Skip debug insns.
2416         (sel_remove_insn): Adjust for debug insns.
2417         (sel_estimate_number_of_insns): Skip debug insns.
2418         (create_insn_rtx_from_pattern): Handle debug insns.
2419         (create_copy_of_insn_rtx): Likewise.
2420         * sel-sched-.h (sel_bb_end): Declare.
2421         (sel_bb_empty_or_nop_p): New.
2422         (get_all_loop_exits): Use it.
2423         (_eligible_successor_edge_p): Likewise.
2424         (return_nop_to_pool): Adjust.
2425         * tree-eh.c (tre_empty_eh_handler_p): Skip debug stmts.
2426         * ira-lives.c (process_bb_node_lives): Skip debug insns.
2427         * gimple-pretty-print.c (dump_gimple_debug): New.
2428         (dump_gimple_stmt): Use it.
2429         (dump_bb_header): Skip gimple debug stmts.
2430         * regmove.c (optimize_reg_copy_1): Discount debug insns.
2431         (fixup_match_2): Likewise.
2432         (regmove_backward_pass): Likewise.  Simplify combined
2433         replacement.  Handle debug insns.
2434         * function.c (instantiate_virtual_regs): Handle debug insns.
2435         * function.h (struct emit_status): Add x_cur_debug_insn_uid.
2436         * print-rtl.h: Include cselib.h.
2437         (print_rtx): Print VALUEs.  Split out and recurse for VAR_LOCATIONs.
2438         * df.h (df_inns_rescan_debug_internal): Declare.
2439         * gcse.c (alloc_hash_table): Estimate n_insns.
2440         (cprop_insn): Don't regard debug insns as changes.
2441         (bypass_conditional_jumps): Skip debug insns.
2442         (one_pre_gcse_pass): Adjust.
2443         (one_code_hoisting_pass): Likewise.
2444         (compute_ld_motion_mems): Skip debug insns.
2445         (one_cprop_pass): Adjust.
2446         * tree-if-conv.c (tree_if_convert_stmt): Reset debug stmts.
2447         (if_convertible_stmt_p): Handle debug stmts.
2448         * init-regs.c (initialize_uninitialized_regs): Skip debug insns.
2449         * tree-vect-loop.c (vect_is_simple_reduction): Skip debug stmts.
2450         * ira-build.c (create_bb_allocnos): Skip debug insns.
2451         * tree-flow-inline.h (has_zero_uses): Discount debug stmts.
2452         (has_single_use): Likewise.
2453         (single_imm_use): Likewise.
2454         (num_imm_uses): Likewise.
2455         * tree-ssa-phiopt.c (empty_block_p): Skip debug stmts.
2456         * tree-ssa-coalesce.c (build_ssa_conflict_graph): Skip debug stmts.
2457         (create_outofssa_var_map): Likewise.
2458         * lower-subreg.c (adjust_decomposed_uses): New.
2459         (resolve_debug): New.
2460         (decompose_multiword_subregs): Use it.
2461         * tree-dfa.c (find_referenced_vars): Skip debug stmts.
2462         * emit-rtl.c: Include params.h.
2463         (cur_debug_insn_uid): Define.
2464         (set_new_first_and_last_insn): Set cur_debug_insn_uid too.
2465         (copy_rtx_if_shared_1): Handle debug insns.
2466         (reset_used_flags): Likewise.
2467         (set_used_flags): LIkewise.
2468         (get_max_insn_count): New.
2469         (next_nondebug_insn): New.
2470         (prev_nondebug_insn): New.
2471         (make_debug_insn_raw): New.
2472         (emit_insn_before_noloc): Handle debug insns.
2473         (emit_jump_insn_before_noloc): Likewise.
2474         (emit_call_insn_before_noloc): Likewise.
2475         (emit_debug_insn_before_noloc): New.
2476         (emit_insn_after_noloc): Handle debug insns.
2477         (emit_jump_insn_after_noloc): Likewise.
2478         (emit_call_insn_after_noloc): Likewise.
2479         (emit_debug_insn_after_noloc): Likewise.
2480         (emit_insn_after): Take loc from earlier non-debug insn.
2481         (emit_jump_insn_after): Likewise.
2482         (emit_call_insn_after): Likewise.
2483         (emit_debug_insn_after_setloc): New.
2484         (emit_debug_insn_after): New.
2485         (emit_insn_before): Take loc from later non-debug insn.
2486         (emit_jump_insn_before): Likewise.
2487         (emit_call_insn_before): Likewise.
2488         (emit_debug_insn_before_setloc): New.
2489         (emit_debug_insn_before): New.
2490         (emit_insn): Handle debug insns.
2491         (emit_debug_insn): New.
2492         (emit_jump_insn): Handle debug insns.
2493         (emit_call_insn): Likewise.
2494         (emit): Likewise.
2495         (init_emit): Take min-nondebug-insn-uid into account.
2496         Initialize cur_debug_insn_uid.
2497         (emit_copy_of_insn_after): Handle debug insns.
2498         * cfgexpand.c (gimple_assign_rhs_to_tree): Do not overwrite
2499         location of single rhs in place.
2500         (maybe_dump_rtl_for_gimple_stmt): Dump lineno.
2501         (floor_sdiv_adjust): New.
2502         (cell_sdiv_adjust): New.
2503         (cell_udiv_adjust): New.
2504         (round_sdiv_adjust): New.
2505         (round_udiv_adjust): New.
2506         (wrap_constant): Moved from cselib.
2507         (unwrap_constant): New.
2508         (expand_debug_expr): New.
2509         (expand_debug_locations): New.
2510         (expand_gimple_basic_block): Drop hiding redeclaration.  Expand
2511         debug bind stmts.
2512         (gimple_expand_cfg): Expand debug locations.
2513         * cselib.c: Include tree-pass.h.
2514         (struct expand_value_data): New.
2515         (cselib_record_sets_hook): New.
2516         (PRESERVED_VALUE_P, LONG_TERM_PRESERVED_VALUE_P): New.
2517         (cselib_clear_table): Move, and implemnet in terms of...
2518         (cselib_reset_table_with_next_value): ... this.
2519         (cselib_get_next_unknown_value): New.
2520         (discard_useless_locs): Don't discard preserved values.
2521         (cselib_preserve_value): New.
2522         (cselib_preserved_value_p): New.
2523         (cselib_preserve_definitely): New.
2524         (cselib_clear_preserve): New.
2525         (cselib_preserve_only_values): New.
2526         (new_cselib_val): Take rtx argument.  Dump it in details.
2527         (cselib_lookup_mem): Adjust.
2528         (expand_loc): Take regs_active in struct.  Adjust.  Silence
2529         dumps unless details are requested.
2530         (cselib_expand_value_rtx_cb): New.
2531         (cselib_expand_value_rtx): Rename and reimplment in terms of...
2532         (cselib_expand_value_rtx_1): ... this.  Adjust.  Silence dumps
2533         without details.  Copy more subregs.  Try to resolve values
2534         using a callback.  Wrap constants.
2535         (cselib_subst_to_values): Adjust.
2536         (cselib_log_lookup): New.
2537         (cselib_lookup): Call it.
2538         (cselib_invalidate_regno): Don't count preserved values as useless.
2539         (cselib_invalidate_mem): Likewise.
2540         (cselib_record_set): Likewise.
2541         (struct set): Renamed to cselib_set, moved to cselib.h.
2542         (cselib_record_sets): Adjust.  Call hook.
2543         (cselib_process_insn): Reset table when it would be cleared.
2544         (dump_cselib_val): New.
2545         (dump_cselib_table): New.
2546         * tree-cfgcleanup.c (tree_forwarded_block_p): Skip debug stmts.
2547         (remove_forwarder_block): Support moving debug stmts.
2548         * cselib.h (cselib_record_sets_hook): Declare.
2549         (cselib_expand_callback): New type.
2550         (cselib_expand_value_rtx_cb): Declare.
2551         (cselib_reset_table_with_next_value): Declare.
2552         (cselib_get_next_unknown_value): Declare.
2553         (cselib_preserve_value): Declare.
2554         (cselib_preserved_value_p): Declare.
2555         (cselib_preserve_only_values): Declare.
2556         (dump_cselib_table): Declare.
2557         * cfgcleanup.c (flow_find_cross_jump): Skip debug insns.
2558         (try_crossjump_to_edge): Likewise.
2559         (delete_unreachable_blocks): Remove dominant GIMPLE blocks after
2560         dominated blocks when debug stmts are present.
2561         * simplify-rtx.c (delegitimize_mem_from_attrs): New.
2562         * tree-ssa-live.c (remove_unused_locals): Skip debug stmts.
2563         (set_var_live_on_entry): Likewise.
2564         * loop-invariant.c (find_invariants_bb): Skip debug insns.
2565         * cfglayout.c (curr_location, last_location): Make static.
2566         (set_curr_insn_source_location): Don't avoid bouncing.
2567         (get_curr_insn_source_location): New.
2568         (get_curr_insn_block): New.
2569         (duplicate_insn_chain): Handle debug insns.
2570         * tree-ssa-forwprop.c (forward_propagate_addr_expr): Propagate
2571         into debug stmts.
2572         * common.opt (fcompare-debug): Move to sort order.
2573         (fdump-unnumbered-links): Likewise.
2574         (fvar-tracking-assignments): New.
2575         (fvar-tracking-assignments-toggle): New.
2576         * tree-ssa-dce.c (mark_stmt_necessary): Don't mark blocks
2577         because of debug stmts.
2578         (mark_stmt_if_obviously_necessary): Mark debug stmts.
2579         (eliminate_unnecessary_stmts): Walk dominated blocks before
2580         dominators.
2581         * tree-ssa-ter.c (find_replaceable_in_bb): Skip debug stmts.
2582         * ira.c (memref_used_between_p): Skip debug insns.
2583         (update_equiv_regs): Likewise.
2584         * sched-deps.c (sd_lists_size): Accept empty list.
2585         (sd_init_insn): Mark debug insns.
2586         (sd_finish_insn): Unmark them.
2587         (sd_add_dep): Reject non-debug deps on debug insns.
2588         (fixup_sched_groups): Give debug insns group treatment.
2589         Skip debug insns.
2590         (sched_analyze_reg): Don't mark debug insns for sched before call.
2591         (sched_analyze_2): Handle debug insns.
2592         (sched_analyze_insn): Compute next non-debug insn.  Handle debug
2593         insns.
2594         (deps_analyze_insn): Handle debug insns.
2595         (deps_start_bb): Skip debug insns.
2596         (init_deps): Initialize last_debug_insn.
2597         * tree-ssa.c (target_for_debug_bind): New.
2598         (find_released_ssa_name): New.
2599         (propagate_var_def_into_debug_stmts): New.
2600         (propagate_defs_into_debug_stmts): New.
2601         (verify_ssa): Skip debug bind stmts without values.
2602         (warn_uninialized_vars): Skip debug stmts.
2603         * target-def.h (TARGET_DELEGITIMIZE_ADDRESS): Set default.
2604         * rtl.c (rtx_equal_p_cb): Handle VALUEs.
2605         (rtx_equal_p): Likewise.
2606         * ira-costs.c (scan_one_insn): Skip debug insns.
2607         (process_bb_node_for_hard_reg_moves): Likewise.
2608         * rtl.h (DEBUG_INSN_P): New.
2609         (NONDEBUG_INSN_P): New.
2610         (MAY_HAVE_DEBUG_INSNS): New.
2611         (INSN_P): Accept debug insns.
2612         (RTX_FRAME_RELATED_P): Likewise.
2613         (INSN_DELETED_P): Likewise
2614         (PAT_VAR_LOCATION_DECL): New.
2615         (PAT_VAR_LOCATION_LOC): New.
2616         (PAT_VAR_OCATION_STATUS): New.
2617         (NOTE_VAR_LOCATION_DECL): Reimplement.
2618         (NOTE_VAR_LOCATION_LOC): Likewise.
2619         (NOTE_VAR_LOCATION_STATUS): Likewise.
2620         (INSN_VAR_LOCATION): New.
2621         (INSN_VAR_LOCATION_DECL): New.
2622         (INSN_VAR_LOCATION_LOC): New.
2623         (INSN_VAR_LOCATION_STATUS): New.
2624         (gen_rtx_UNKNOWN_VAR_LOC): New.
2625         (VAR_LOC_UNKNOWN_P): New.
2626         (NOTE_DURING_CALL_P): New.
2627         (SCHED_GROUP_P): Accept debug insns.
2628         (emit_debug_insn_before): Declare.
2629         (emit_debug_insn_before_noloc): Declare.
2630         (emit_debug_insn_beore_setloc): Declare.
2631         (emit_debug_insn_after): Declare.
2632         (emit_debug_insn_after_noloc): Declare.
2633         (emit_debug_insn_after_setloc): Declare.
2634         (emit_debug_insn): Declare.
2635         (make_debug_insn_raw): Declare.
2636         (prev_nondebug_insn): Declare.
2637         (next_nondebug_insn): Declare.
2638         (delegitimize_mem_from_attrs): Declare.
2639         (get_max_insn_count): Declare.
2640         (wrap_constant): Declare.
2641         (unwrap_constant): Declare.
2642         (get_curr_insn_source_location): Declare.
2643         (get_curr_insn_block): Declare.
2644         * tree-inline.c (insert_debug_decl_map): New.
2645         (processing_debug_stmt): New.
2646         (remap_decl): Don't create new mappings in debug stmts.
2647         (remap_gimple_op_r): Don't add references in debug stmts.
2648         (copy_tree_body_r): Likewise.
2649         (remap_gimple_stmt): Handle debug bind stmts.
2650         (copy_bb): Skip debug stmts.
2651         (copy_edges_for_bb): Likewise.
2652         (copy_debug_stmt): New.
2653         (copy_debug_stmts): New.
2654         (copy_body): Copy debug stmts at the end.
2655         (insert_init_debug_bind): New.
2656         (insert_init_stmt): Take id.  Skip and emit debug stmts.
2657         (setup_one_parameter): Remap variable earlier, register debug mapping.
2658         (estimate_num_insns): Skip debug stmts.
2659         (expand_call_inline): Preserve debug_map.
2660         (optimize_inline_calls): Check for no debug_stmts left-overs.
2661         (unsave_expr_now): Preserve debug_map.
2662         (copy_gimple_seq_and_replace_locals): Likewise.
2663         (tree_function_versioning): Check for no debug_stmts left-overs.
2664         Init and destroy debug_map as needed.  Split edges unconditionally.
2665         (build_duplicate_type): Init and destroy debug_map as needed.
2666         * tree-inline.h: Include gimple.h instead of pointer-set.h.
2667         (struct copy_body_data): Add debug_stmts and debug_map.
2668         * sched-int.h (struct ready_list): Add n_debug.
2669         (struct deps): Add last_debug_insn.
2670         (DEBUG_INSN_SCHED_P): New.
2671         (BOUNDARY_DEBUG_INSN_P): New.
2672         (SCHEDULE_DEBUG_INSN_P): New.
2673         (sd_iterator_cond): Accept empty list.
2674         * combine.c (create_log_links): Skip debug insns.
2675         (combine_instructions): Likewise.
2676         (cleanup_auto_inc_dec): New.  From Jakub Jelinek: Make sure the
2677         return value is always unshared.
2678         (struct rtx_subst_pair): New.
2679         (auto_adjust_pair): New.
2680         (propagate_for_debug_subst): New.
2681         (propagate_for_debug): New.
2682         (try_combine): Skip debug insns.  Propagate removed defs into
2683         debug insns.
2684         (next_nonnote_nondebug_insn): New.
2685         (distribute_notes): Use it.  Skip debug insns.
2686         (distribute_links): Skip debug insns.
2687         * tree-outof-ssa.c (set_location_for_edge): Likewise.
2688         * resource.c (mark_target_live_regs): Likewise.
2689         * var-tracking.c: Include cselib.h and target.h.
2690         (enum micro_operation_type): Add MO_VAL_USE, MO_VAL_LOC, and
2691         MO_VAL_SET.
2692         (micro_operation_type_name): New.
2693         (enum emit_note_where): Add EMIT_NOTE_AFTER_CALL_INSN.
2694         (struct micro_operation_def): Update comments.
2695         (decl_or_value): New type.  Use instead of decls.
2696         (struct emit_note_data_def): Add vars.
2697         (struct attrs_def): Use decl_or_value.
2698         (struct variable_tracking_info_def): Add permp, flooded.
2699         (struct location_chain_def): Update comment.
2700         (struct variable_part_def): Use decl_or_value.
2701         (struct variable_def): Make var_part a variable length array.
2702         (valvar_pool): New.
2703         (scratch_regs): New.
2704         (cselib_hook_called): New.
2705         (dv_is_decl_p): New.
2706         (dv_is_value_p): New.
2707         (dv_as_decl): New.
2708         (dv_as_value): New.
2709         (dv_as_opaque): New.
2710         (dv_onepart_p): New.
2711         (dv_pool): New.
2712         (IS_DECL_CODE): New.
2713         (check_value_is_not_decl): New.
2714         (dv_from_decl): New.
2715         (dv_from_value): New.
2716         (dv_htab_hash): New.
2717         (variable_htab_hash): Use it.
2718         (variable_htab_eq): Support values.
2719         (variable_htab_free): Free from the right pool.
2720         (attrs_list_member, attrs_list_insert): Use decl_or_value.
2721         (attrs_list_union): Adjust.
2722         (attrs_list_mpdv_union): New.
2723         (tie_break_pointers): New.
2724         (canon_value_cmp): New.
2725         (unshare_variable): Return possibly-modified slot.
2726         (vars_copy_1): Adjust.
2727         (var_reg_decl_set): Adjust.  Split out of...
2728         (var_reg_set): ... this.
2729         (get_init_value): Adjust.
2730         (var_reg_delete_and_set): Adjust.
2731         (var_reg_delete): Adjust.
2732         (var_regno_delete): Adjust.
2733         (var_mem_decl_set): Split out of...
2734         (var_mem_set): ... this.
2735         (var_mem_delete_and_set): Adjust.
2736         (var_mem_delete): Adjust.
2737         (val_store): New.
2738         (val_reset): New.
2739         (val_resolve): New.
2740         (variable_union): Adjust.  Speed up merge of 1-part vars.
2741         (variable_canonicalize): Use unshared slot.
2742         (VALUED_RECURSED_INTO): New.
2743         (find_loc_in_1pdv): New.
2744         (struct dfset_merge): New.
2745         (insert_into_intersection): New.
2746         (intersect_loc_chains): New.
2747         (loc_cmp): New.
2748         (canonicalize_loc_order_check): New.
2749         (canonicalize_values_mark): New.
2750         (canonicalize_values_star): New.
2751         (variable_merge_over_cur): New.
2752         (variable_merge_over_src): New.
2753         (dataflow_set_merge): New.
2754         (dataflow_set_equiv_regs): New.
2755         (remove_duplicate_values): New.
2756         (struct dfset_post_merge): New.
2757         (variable_post_merge_new_vals): New.
2758         (variable_post_merge_perm_vals): New.
2759         (dataflow_post_merge_adjust): New.
2760         (find_mem_expr_in_1pdv): New.
2761         (dataflow_set_preserve_mem_locs): New.
2762         (dataflow_set_remove_mem_locs): New.
2763         (dataflow_set_clear_at_call): New.
2764         (onepart_variable_different_p): New.
2765         (variable_different_p): Use it.
2766         (dataflow_set_different_1): Adjust.  Make detailed dump more verbose.
2767         (track_expr_p): Add need_rtl parameter.  Don't generate rtl
2768         if not needed.
2769         (track_loc_p): Pass it true.
2770         (struct count_use_info): New.
2771         (find_use_val): New.
2772         (replace_expr_with_values): New.
2773         (log_op_type): New.
2774         (use_type): New, partially split out of...
2775         (count_uses): ... this.  Count new micro-ops.
2776         (count_uses_1): Adjust.
2777         (count_stores): Adjust.
2778         (count_with_sets): New.
2779         (VAL_NEEDS_RESOLUTION): New.
2780         (VAL_HOLDS_TRACK_EXPR): New.
2781         (VAL_EXPR_IS_COPIED): New.
2782         (VAL_EXPR_IS_CLOBBERED): New.
2783         (add_uses): Adjust.  Generate new micro-ops.
2784         (add_uses_1): Adjust.
2785         (add_stores): Generate new micro-ops.
2786         (add_with_sets): New.
2787         (find_src_status): Adjust.
2788         (find_src_set_src): Adjust.
2789         (compute_bb_dataflow): Use dataflow_set_clear_at_call.
2790         Handle new micro-ops.  Canonicalize value equivalances.
2791         (vt_find_locations): Compute total size of hash tables for
2792         dumping.  Perform merge for var-tracking-assignments.  Don't
2793         disregard single-block loops.
2794         (dump_attrs_list): Handle decl_or_value.
2795         (dump_variable): Take variable.  Deal with decl_or_value.
2796         (dump_variable_slot): New.
2797         (dump_vars): Use it.
2798         (dump_dataflow_sets): Adjust.
2799         (set_slot_part): New, extended to support one-part variables
2800         after splitting out of...
2801         (set_variable_part): ... this.
2802         (clobber_slot_part): New, split out of...
2803         (clobber_variable_part): ... this.
2804         (delete_slot_part): New, split out of...
2805         (delete_variable_part): .... this.
2806         (check_wrap_constant): New.
2807         (vt_expand_loc_callback): New.
2808         (vt_expand_loc): New.
2809         (emit_note_insn_var_location): Adjust.  Handle values.  Handle
2810         EMIT_NOTE_AFTER_CALL_INSN.
2811         (emit_notes_for_differences_1): Adjust.  Handle values.
2812         (emit_notes_for_differences_2): Likewise.
2813         (emit_notes_for_differences): Adjust.
2814         (emit_notes_in_bb): Take pointer to set.  Emit AFTER_CALL_INSN notes.
2815         Adjust.  Handle new micro-ops.
2816         (vt_add_function_parameters): Adjust.  Create and bind values.
2817         (vt_initialize): Adjust.  Initialize scratch_regs and
2818         valvar_pool, flooded and perm..  Initialize and use cselib.  Log
2819         operations.  Move some code to count_with_sets and add_with_sets.
2820         (delete_debug_insns): New.
2821         (vt_debug_insns_local): New.
2822         (vt_finalize): Release permp, valvar_pool, scratch_regs.  Finish
2823         cselib.
2824         (var_tracking_main): If var-tracking-assignments is enabled
2825         but var-tracking isn't, delete debug insns and leave.  Likewise
2826         if we exceed limits or fail the stack adjustments tests, and
2827         after all var-tracking processing.
2828         More in var-tracking, from Jakub Jelinek <jakub@redhat.com>:
2829         (dataflow_set): Add traversed_vars.
2830         (value_chain, const_value_chain): New typedefs.
2831         (value_chain_pool, value_chains): New variables.
2832         (value_chain_htab_hash, value_chain_htab_eq, add_value_chain,
2833         add_value_chains, add_cselib_value_chains, remove_value_chain,
2834         remove_value_chains, remove_cselib_value_chains): New functions.
2835         (shared_hash_find_slot_unshare_1, shared_hash_find_slot_1,
2836         shared_hash_find_slot_noinsert_1, shared_hash_find_1): New
2837         static inlines.
2838         (shared_hash_find_slot_unshare, shared_hash_find_slot,
2839         shared_hash_find_slot_noinsert, shared_hash_find): Update.
2840         (dst_can_be_shared): New variable.
2841         (unshare_variable): Unshare set->vars if shared, use shared_hash_*.
2842         Clear dst_can_be_shared.  If set->traversed_vars is non-NULL and
2843         different from set->vars, look up slot again instead of using the
2844         passed in slot.
2845         (dataflow_set_init): Initialize traversed_vars.
2846         (variable_union): Use shared_hash_*.  Use initially NO_INSERT
2847         lookup if set->vars is shared.  Don't keep slot cleared before
2848         calling unshare_variable.  Unshare set->vars if needed.  Adjust
2849         unshare_variable callers.  Clear dst_can_be_shared if needed.
2850         Even ->refcount == 1 vars must be unshared if set->vars is shared
2851         and var needs to be modified.
2852         (dataflow_set_union): Set traversed_vars during canonicalization.
2853         (VALUE_CHANGED, DECL_CHANGED): Define.
2854         (set_dv_changed, dv_changed_p): New static inlines.
2855         (track_expr_p): Clear DECL_CHANGED.
2856         (dump_dataflow_sets): Set it.
2857         (variable_was_changed): Call set_dv_changed.
2858         (emit_note_insn_var_location): Likewise.
2859         (changed_variables_stack): New variable.
2860         (check_changed_vars_1, check_changed_vars_2): New functions.
2861         (emit_notes_for_changes): Do nothing if changed_variables is
2862         empty.  Traverse changed_variables with check_changed_vars_1,
2863         call check_changed_vars_2 on each changed_variables_stack entry.
2864         (emit_notes_in_bb): Add SET argument.  Just clear it at the
2865         beginning, use it instead of local &set, don't destroy it at the end.
2866         (vt_emit_notes): Call dataflow_set_clear early on all
2867         VTI(bb)->out sets, never use them, instead use emit_notes_in_bb
2868         computed set, dataflow_set_clear also VTI(bb)->in when we are
2869         done with the basic block.  Initialize changed_variables_stack,
2870         free it afterwards.  If ENABLE_CHECKING verify that after noting
2871         differences to an empty set value_chains hash table is empty.
2872         (vt_initialize): Initialize value_chains and value_chain_pool.
2873         (vt_finalize): Delete value_chains htab, free value_chain_pool.
2874         (variable_tracking_main): Call dump_dataflow_sets before calling
2875         vt_emit_notes, not after it.
2876         * tree-flow.h (propagate_defs_into_debug_stmts): Declare.
2877         (propagate_var_def_into_debug_stmts): Declare.
2878         * df-problems.c (df_lr_bb_local_compute): Skip debug insns.
2879         (df_set_note): Reject debug insns.
2880         (df_whole_mw_reg_dead_p): Take added_notes_p argument.  Don't
2881         add notes to debug insns.
2882         (df_note_bb_compute): Adjust.  Likewise.
2883         (df_simulate_uses): Skip debug insns.
2884         (df_simulate_initialize_backwards): Likewise.
2885         * reg-stack.c (subst_stack_regs_in_debug_insn): New.
2886         (subst_stack_regs_pat): Reject debug insns.
2887         (convert_regs_1): Handle debug insns.
2888         * Makefile.in (TREE_INLINE_H): Take pointer-set.h from GIMPLE_H.
2889         (print-rtl.o): Depend on cselib.h.
2890         (cselib.o): Depend on TREE_PASS_H.
2891         (var-tracking.o): Depend on cselib.h and TARGET_H.
2892         * sched-rgn.c (rgn_estimate_number_of_insns): Discount debug insns.
2893         (init_ready_list): Skip boundary debug insns.
2894         (add_branch_dependences): Skip debug insns.
2895         (free_block_dependencies): Check for blocks with only debug insns.
2896         (compute_priorities): Likewise.
2897         * gimple.c (gss_for_code): Handle GIMPLE_DEBUG.
2898         (gimple_build_with_ops_stat): Take subcode as unsigned.  Adjust
2899         all callers.
2900         (gimple_build_debug_bind_stat): New.
2901         (empty_body_p): Skip debug stmts.
2902         (gimple_has_side_effects): Likewise.
2903         (gimple_rhs_has_side_effects): Likewise.
2904         * gimple.h (enum gimple_debug_subcode, GIMPLE_DEBUG_BIND): New.
2905         (gimple_build_debug_bind_stat): Declare.
2906         (gimple_build_debug_bind): Define.
2907         (is_gimple_debug): New.
2908         (gimple_debug_bind_p): New.
2909         (gimple_debug_bind_get_var): New.
2910         (gimple_debug_bind_get_value): New.
2911         (gimple_debug_bind_get_value_ptr): New.
2912         (gimple_debug_bind_set_var): New.
2913         (gimple_debug_bind_set_value): New.
2914         (GIMPLE_DEBUG_BIND_NOVALUE): New internal temporary macro.
2915         (gimple_debug_bind_reset_value): New.
2916         (gimple_debug_bind_has_value_p): New.
2917         (gsi_next_nondebug): New.
2918         (gsi_prev_nondebug): New.
2919         (gsi_start_nondebug_bb): New.
2920         (gsi_last_nondebug_bb): New.
2921         * sched-vis.c (print_pattern): Handle VAR_LOCATION.
2922         (print_insn): Handle DEBUG_INSN.
2923         * tree-cfg.c (remove_bb): Walk stmts backwards.  Let loc
2924         of first insn prevail.
2925         (first_stmt): Skip debug stmts.
2926         (first_non_label_stmt): Likewise.
2927         (last_stmt): Likewise.
2928         (has_zero_uses_1): New.
2929         (single_imm_use_1): New.
2930         (verify_gimple_debug): New.
2931         (verify_types_in_gimple_stmt): Handle debug stmts.
2932         (verify_stmt): Likewise.
2933         (debug_loop_num): Skip debug stmts.
2934         (remove_edge_and_dominated_blocks): Remove dominators last.
2935         * tree-ssa-reasssoc.c (rewrite_expr_tree): Propagate into debug stmts.
2936         (linearize_expr): Likewise.
2937         * config/i386/i386.c (ix86_delegitimize_address): Call
2938         default implementation.
2939         * config/ia64/ia64.c (ia64_safe_itanium_class): Handle debug insns.
2940         (group_barrier_needed): Skip debug insns.
2941         (emit_insn_group_barriers): Likewise.
2942         (emit_all_insn_group_barriers): Likewise.
2943         (ia64_variable_issue): Handle debug insns.
2944         (ia64_dfa_new_cycle): Likewise.
2945         (final_emit_insn_group_barriers): Skip debug insns.
2946         (ia64_dwarf2out_def_steady_cfa): Take frame argument.  Don't
2947         def cfa without frame.
2948         (process_set): Likewise.
2949         (process_for_unwind_directive): Pass frame on.
2950         * config/rs6000/rs6000.c (TARGET_DELEGITIMIZE_ADDRESS): Define.
2951         (rs6000_delegitimize_address): New.
2952         (rs6000_debug_adjust_cost): Handle debug insns.
2953         (is_microcoded_insn): Likewise.
2954         (is_cracked_insn): Likewise.
2955         (is_nonpipeline_insn): Likewise.
2956         (insn_must_be_first_in_group): Likewise.
2957         (insn_must_be_last_in_group): Likewise.
2958         (force_new_group): Likewise.
2959         * cfgrtl.c (rtl_split_block): Emit INSN_DELETED note if block
2960         contains only debug insns.
2961         (rtl_merge_blocks): Skip debug insns.
2962         (purge_dead_edges): Likewise.
2963         (rtl_block_ends_with_call_p): Skip debug insns.
2964         * dce.c (deletable_insn_p): Handle VAR_LOCATION.
2965         (mark_reg_dependencies): Skip debug insns.
2966         * params.def (PARAM_MIN_NONDEBUG_INSN_UID): New.
2967         * tree-ssanames.c (release_ssa_name): Propagate def into debug stmts.
2968         * tree-ssa-threadedge.c
2969         (record_temporary_equivalences_from_stmts): Skip debug stmts.
2970         * regcprop.c (replace_oldest_value_addr): Skip debug insns.
2971         (replace_oldest_value_mem): Use ALL_REGS for debug insns.
2972         (copyprop_hardreg_forward_1): Handle debug insns.
2973         * reload1.c (reload): Skip debug insns.  Replace unassigned
2974         pseudos in debug insns with their equivalences.
2975         (eliminate_regs_in_insn): Skip debug insns.
2976         (emit_input_reload_insns): Skip debug insns at first, adjust
2977         them later.
2978         * tree-ssa-operands.c (add_virtual_operand): Reject debug stmts.
2979         (get_indirect_ref_operands): Pass opf_no_vops on.
2980         (get_expr_operands): Likewise.  Skip debug stmts.
2981         (parse_ssa_operands): Scan debug insns with opf_no_vops.
2982
2983 2009-09-01  Richard Henderson  <rth@redhat.com>
2984
2985         * tree-ssa-ccp.c (ccp_initialize): Make sure to simulate
2986         stmt_ends_pp_p statements at least once.
2987         * tree-vrp.c (vrp_initialize): Likewise.
2988         (vrp_visit_stmt): Be prepared for non-interesting stmts.
2989
2990 2009-09-01  Dodji Seketeli  <dodji@redhat.com>
2991
2992         PR bootstrap/41205
2993         Fix AIX bootstrap after PR debug/30161
2994         * dwarf2out.c (make_ith_pack_parameter_name): Don't used strnlen
2995         that is a GNU extension.
2996         (tmpl_value_parm_die_table): Move the definition of this global
2997         outside #ifdef DWARF2_DEBUGGING_INFO region.
2998
2999 2009-09-01  Richard Guenther  <rguenther@suse.de>
3000
3001         * tree.c (tree_expr_size): New function.
3002         * tree.h (tree_expr_size): Declare.
3003         * rtlanal.c (rtx_addr_can_trap_p_1): Adjust comment.
3004         * builtins.c (fold_builtin_memory_op): Use tree_expr_size.
3005         * langhooks.c (lhd_expr_size): Remove.
3006         * langhooks.h (struct lang_hooks): Remove expr_size.
3007         * explow.c (expr_size): Use tree_expr_size.
3008         (int_expr_size): Likewise.
3009         * langhooks-def.h (lhd_expr_size): Remove.
3010         (LANG_HOOKS_EXPR_SIZE): Likewise.
3011         (LANG_HOOKS_INITIALIZER): Adjust.
3012
3013 2009-09-01  Richard Guenther  <rguenther@suse.de>
3014
3015         * tree-flow.h (mark_addressable): Move declaration ...
3016         * tree.h (mark_addressable): ... here.
3017         * stmt.c (expand_asm_operands): Use mark_addressable, not
3018         lang_hooks.mark_addressable.
3019         * langhooks-def.h (LANG_HOOKS_INITIALIZER): Remove
3020         LANG_HOOKS_MARK_ADDRESSABLE.
3021         * langhooks.h (struct lang_hooks): Remove mark_addressable langhook.
3022         * c-objc-common.h (LANG_HOOKS_MARK_ADDRESSABLE): Remove.
3023
3024 2009-08-31  Chris Demetriou  <cgd@google.com>
3025
3026         * config/i386/i386.c (ix86_vectorize_builtin_conversion): Never
3027         vectorize if not TARGET_SSE2.
3028
3029 2009-08-31  DJ Delorie  <dj@redhat.com>
3030
3031         * config/mep/mep.h (FUNCTION_ARG_REGNO_P): Exclude coprocessor
3032         registers if no coprocessor is enabled.
3033
3034 2009-08-31  Dodji Seketeli  <dodji@redhat.com>
3035
3036         PR debug/30161
3037         * cgraph.h (cgraph_get_node): Declare ...
3038         * cgraph.c (cgraph_get_node): ... new function.
3039         * dwarf2out.c (gen_generic_params_dies,
3040         generic_parameter_die, tree_add_const_value_attribute_for_decl,
3041         make_ith_pack_parameter_name,
3042         append_entry_to_tmpl_value_parm_die_table,
3043         gen_remaining_tmpl_value_param_die_attribute): New functions.
3044         (gen_subprogram_die): Generate debug info for template parameters
3045         if debug info level is higher than DINFO_LEVEL_TERSE.
3046         Use tree_add_const_value_attribute_for_decl instead of
3047         tree_add_const_value_attribute.
3048         (gen_const_die): Use tree_add_const_value_attribute_for_decl
3049         instead of tree_add_const_value_attribute.
3050         (gen_struct_or_union_type_die): Generate debug
3051         info for template parameters if debug info level is higher than
3052         DINFO_LEVEL_TERSE.
3053         (tree_add_const_value_attribute): Handle integral and pointer
3054         constants. Update comment.
3055         (dwarf_tag_name): Support DW_TAG_GNU_template_template_param.
3056         (dwarf_attr_name): Support DW_AT_GNU_template_name.
3057         (reference_to_unused): Fix thinko. Remove redundant predicates from
3058         tests.
3059         (tree_add_const_value_attribute): Make this work for constant
3060         expressions only.
3061         tree_add_const_value_attribute_for_decl is to be used for variable
3062         DECLs now.
3063         (add_location_or_const_value_attribute): Use
3064         tree_add_const_value_attribute_for_decl now.
3065         (dwarf2out_finish): Emit the DW_AT_const_value attribute of
3066         DW_TAG_template_value_param DIEs after function DIEs have been
3067         emitted.
3068         * langhooks.h (lang_hooks_for_types): Add
3069         get_argument_pack_elems.
3070         (lang_hooks_for_decls): Add generic_generic_parameter_decl_p.
3071         (lang_hooks): Added get_innermost_generic_parms,
3072         get_innermost_generic_args.
3073         * langhooks-def.h (LANG_HOOKS_GET_INNERMOST_GENERIC_PARMS,
3074         LANG_HOOKS_GET_INNERMOST_GENERIC_ARGS,
3075         LANG_HOOKS_GET_ARGUMENT_PACK_ELEMS,
3076         LANG_HOOKS_GENERIC_GENERIC_PARAMETER_DECL_P): New language hooks.
3077
3078 2009-08-31  DJ Delorie  <dj@redhat.com>
3079
3080         * config/mep/mep.c (machine_function): Add frame_locked flag.  Set
3081         it once we start generating the prologue or epilogue.
3082         (mep_call_saves_register): If the frame is locked, re-use
3083         cached values.
3084         (mep_assign_save_slots): New, broken out from mep_expand_prologue.
3085         (mep_expand_prologue): Call it.
3086         (mep_expand_epilogue): Likewise.
3087         (mep_start_function): Use the same logic as mep_expand_prologue.
3088         (mep_pass_by_reference): Make logic more readable.
3089         (mep_return_in_memory): Zero-sized objects are passed in memory.
3090         (mep_reorg_noframe): Make sure we have accurate REG_DEAD notes.
3091
3092 2009-08-31  Richard Guenther  <rguenther@suse.de>
3093
3094         * builtins.c (fold_builtin_memory_op): Use the alias oracle
3095         to query if the memory regions for memmove overlap.
3096         * tree-ssa-alias.c (ptr_deref_may_alias_decl_p): Relax the
3097         asserts on pointers, instead deal with odd trees.
3098         (ptr_derefs_may_alias_p): Likewise.
3099         (refs_may_alias_p_1): Constructor bases also never alias.
3100
3101 2009-08-31  Gerald Pfeifer  <gerald@pfeifer.com>
3102
3103         * doc/install.texi (Final install): Adjust reference on where to
3104         order printed manuals.
3105
3106 2009-08-30  Olivier Hainque  <hainque@adacore.com>
3107
3108         * dwarf2out.c (switch_to_frame_table_section): Move
3109         definition prior to first use.
3110
3111 2009-08-30  Richard Guenther  <rguenther@suse.de>
3112
3113         PR tree-optimization/41186
3114         * tree-ssa-alias.c (ptr_deref_may_alias_ref_p): Remove.
3115         (ao_ref_init_from_ptr_and_size): New function.
3116         (ref_maybe_used_by_call_p_1): Be more precise tracking
3117         used ranges for builtin functions.
3118         (ref_maybe_used_by_call_p): Adjust.
3119         (call_may_clobber_ref_p_1): Be more precise tracking clobbered
3120         ranges for builtin functions.
3121         * tree-ssa-alias.h (ao_ref_init_from_ptr_and_size): Declare.
3122
3123 2009-08-30  Alan Modra  <amodra@bigpond.net.au>
3124
3125         PR target/41081
3126         * fwprop.c (get_reg_use_in): Delete.
3127         (free_load_extend): New function.
3128         (forward_propagate_subreg): Use it.
3129
3130 2009-08-29  Kaz Kojima  <kkojima@gcc.gnu.org>
3131
3132         * config.gcc (sh*-*-elf): Add superh stuff only for sh*-superh-elf.
3133
3134 2009-08-29  Kai Tietz<kai.tietz@onevision.com>
3135
3136         PR/41184
3137         * config/i386.c (ix86_expand_epilogue): Correct stack adjustment for
3138         padding.
3139
3140 2009-08-29  Douglas B Rupp  <rupp@gnat.com>
3141
3142         * crtstuff.c (__do_global_dtors_aux): Use atexit if no
3143         fini or fini_array section.
3144
3145 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
3146
3147         * graphite-dependences.c (graphite_legal_transform_bb): Call
3148         pbb_remove_duplicate_pdrs.
3149         * graphite-poly.c (can_collapse_pdr): Removed.
3150         (pdr_find_duplicate): Removed.
3151         (can_collapse_pdrs): New.
3152         (pbb_remove_duplicate_pdrs): New.
3153         (new_poly_dr): Do not look for duplicates.
3154         * graphite-poly.h (struct poly_bb): New field pdr_duplicates_removed.
3155         (PBB_PDR_DUPLICATES_REMOVED): New.
3156         (pbb_remove_duplicate_pdrs): Declared.
3157
3158 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
3159
3160         * graphite-interchange.c (pbb_interchange_profitable_p): Adjust
3161         the strides by multiplying by PDR_NB_REFS.
3162         * graphite-poly.c (can_collapse_pdr): New.
3163         (pdr_find_duplicate): New.
3164         (new_poly_dr): Call pdr_find_duplicate.  Collapse duplicate PDRs.
3165         Initialize PDR_NB_REFS.
3166         * graphite-poly.h (struct poly_dr): Add field nb_refs.
3167         (PDR_NB_REFS): New.
3168         (new_poly_dr): Number of subscripts is a graphite_dim_t.
3169
3170 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
3171
3172         PR middle-end/40965
3173         * graphite-poly.c (apply_poly_transforms): Remove legality test before
3174         any transform.
3175
3176 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
3177
3178         * graphite-dependences.c (pddr_original_scattering): Return NULL
3179         for read-read dependence relations.
3180         * graphite-poly.h (enum poly_dr_type): Fix comment.
3181         (pdr_read_p): New.
3182         (pdr_write_p): New.
3183         (pdr_may_write_p): New.
3184
3185 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
3186
3187         * graphite-poly.h (enum POLY_DR_TYPE): Renamed poly_dr_type.
3188         (struct poly_dr): Same.
3189         (new_poly_dr): Same.
3190         * graphite-poly.c (new_poly_dr): Same.
3191         * graphite-dependences.c (dot_deps): Disable call to system.
3192
3193 2009-08-28  Cary Coutant  <ccoutant@google.com>
3194
3195         PR debug/41063
3196         * dwarf2out.c (gen_type_die_with_usage): Use proper context for
3197         struct/union/enum types local to a function.
3198
3199 2009-08-28  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
3200             Sebastian Pop  <sebastian.pop@amd.com>
3201
3202         * graphite-blocking.c (pbb_strip_mine_loop_depth): Renamed
3203         pbb_strip_mine_time_depth.  Changed the implementation so that
3204         transformation is expressed as a transformation on
3205         time (scatttering) dimensions.  Also, ensures that the 2d+1
3206         scheduling format is preserved.
3207         (pbb_strip_mine_profitable_p): Profitability is based on the
3208         iteration number of a given time (scattering) dimension,
3209         and not on a original loop depth dimension.
3210         (pbb_strip_mine): Call pbb_number_of_iterations_at_time.
3211         (pbb_do_strip_mine): Call psct_dynamic_dim.
3212         * graphite-poly.c (pbb_number_of_iterations_at_time): New.
3213         * graphite-poly.h (pbb_number_of_iterations_at_time): Declared.
3214         (pbb_nb_dynamic_scattering_transform): New.
3215         (psct_dynamic_dim): New.
3216
3217 2009-08-28  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
3218
3219         * graphite-ppl.c (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
3220         * graphite-ppl.h (ppl_max_for_le): Renamed ppl_max_for_le_pointset.
3221         * graphite-poly.c (pbb_number_of_iterations): Rename ppl_max_for_le.
3222         * graphite-interchange.c (build_linearized_memory_access): Same.
3223         (memory_stride_in_loop): Same.
3224
3225 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
3226
3227         * graphite-dependences.c (pddr_original_scattering): New.
3228         (graphite_legal_transform_dr): Call pddr_original_scattering.
3229         (dot_deps_1): New.
3230         (dot_deps): New.
3231         * graphite-dependences.h (dot_deps): Declared.
3232         * graphite-poly.c (new_poly_dr): Initialize PDR_ID.
3233         (print_pdr): Print PDR_ID.
3234         * graphite-poly.h (struct poly_dr): Add field id.
3235         (PDR_ID): New.
3236         (pbb_index): New.
3237         * graphite-scop-detection.c (dot_all_scops_1): Cleanup comment.
3238
3239 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
3240
3241         * graphite-dependences.c (graphite_carried_dependence_level_k): Do
3242         not delete the original dependence relation.
3243
3244 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
3245
3246         * graphite-dependences.c (new_poly_dr_pair): Renamed new_poly_ddr.
3247         (eq_poly_dr_pair_p): Renamed eq_poly_ddr_p.
3248         (hash_poly_dr_pair_p): Renamed hash_poly_ddr_p.
3249         (free_poly_ddr): New.
3250         (pddr_is_empty): New.
3251         (dependence_polyhedron_1): Now returns a poly_ddr_p.
3252         (dependence_polyhedron): Same.  Remove useless gcc_assert.
3253         Remove fprintfs.
3254         (graphite_legal_transform_dr): Call pddr_is_empty and free_poly_ddr.
3255         (graphite_carried_dependence_level_k): Call pddr_is_empty.
3256         * graphite-dependences.h (enum poly_dependence_kind): New.
3257         (poly_dr_pair): Renamed poly_ddr.  Added a field kind.
3258         (PDRP_SOURCE): Renamed PDDR_SOURCE.
3259         (PDRP_SINK): Renamed PDDR_SINK.
3260         (PDRP_DDP): Renamed PDDR_DDP.
3261         (PDDR_KIND): New.
3262         (free_poly_ddr): Declared.
3263         * graphite-poly.c (new_scop): Use the new hash function names.
3264         * graphite-poly.h (struct scop): Renamed field original_pdr_pairs
3265         into original_pddrs.
3266         (SCOP_ORIGINAL_PDR_PAIRS): Renamed SCOP_ORIGINAL_PDDRS.
3267
3268 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
3269
3270         * cfgloopmanip.c (create_empty_loop_on_edge): Generate upper
3271         bounds with LT_EXPR to make niter analysis more precise on code
3272         generated by Graphite.
3273
3274 2009-08-28  Sebastian Pop  <sebastian.pop@amd.com>
3275
3276         * graphite-dependences.c (graphite_legal_transform_dr): Fix formatting.
3277         (graphite_legal_transform_bb): Same.
3278         (poly_drs_may_alias_p): Same.
3279
3280 2009-08-28  Richard Guenther  <rguenther@suse.de>
3281
3282         * tree.def: Remove note about obsolete TYPE_NONCOPIED_PARTS.
3283
3284 2009-08-28  Jan Beulich  <jbeulich@novell.com>
3285
3286         * config/i386/netware.c: Include langhooks.h.
3287         (i386_nlm_encode_section_info): Simplify.
3288         (netware_override_options): Delete.
3289         * config/i386/netware.h (netware_override_options): Delete
3290         declaration.
3291         (OVERRIDE_OPTIONS): Delete definition.
3292         (SUBTARGET_OVERRIDE_OPTIONS): Define.
3293         (ASM_COMMENT_START): Define.
3294         * config/i386/nwld.h (SUBSUBTARGET_OVERRIDE_OPTIONS): Define.
3295
3296 2009-08-28  Jan Beulich  <jbeulich@novell.com>
3297
3298         * configure.ac: For in-tree ld, do a plain version check to
3299         determine whether comdat groups are supported.
3300         * configure: Regenerate.
3301
3302 2009-08-28  Olivier Hainque  <hainque@adacore.com>
3303
3304         * collect2.c (DO_COLLECT_EXPORT_LIST): New internal macro,
3305         always defined.  Reflect definition or absence of such for
3306         COLLECT_EXPORT_LIST.  Readability helper.
3307         (scanfilter): New enum, to help control what symbols
3308         are to be considered or ignored by scan_prog_file.
3309         (enum pass): Rename as "scanpass", moved together with scanfilter
3310         prior to scan_prog_file's prototype.
3311         (scan_prog_file): Accept and honor scanpass and scanfilter arguments.
3312         Group prototype with the scanpass/scanfilter definitions, factorize
3313         head comments for the several implementations at the prototype.
3314         (main): Reorganize the first pass link control to let AIX
3315         drag only the needed frame tables in executables.  Prevent
3316         frame tables collection during the scan aimed at static ctors.
3317         Pre-link and scan for frame tables later to compensate.
3318         * doc/tm.texi (ASM_OUTPUT_DWARF_TABLE_REF): New macro.
3319         A C statement to issue assembly directives that create a reference
3320         to the given DWARF table identifier label from the current function
3321         section.
3322         * dwarf2out.c (switch_to_eh_frame_section): Add a BACK argument
3323         to differentiate first time section entry.  Only emit a .data
3324         tables start identifier label the first time around.
3325         (switch_to_frame_table_section): New function.  Helper for
3326         output_call_frame_info to switch possibly BACK into the eh_frame
3327         or the debug_frame section depending on FOR_EH.
3328         (output_call_frame_info): Use helper to first enter the proper
3329         frame section.
3330         (output_fde): Use ASM_OUTPUT_DWARF_TABLE_REF when defined to
3331         emit a link to the frame table start label from each function
3332         section.
3333         * config/rs6000/rs6000.c (rs6000_aix_asm_output_dwarf_table_ref):
3334         New function.  Implementation of ASM_OUTPUT_DWARF_TABLE_REF.
3335         * config/rs6000/rs6000-protos.h: Declare it.
3336         * config/rs6000/aix.h (ASM_OUTPUT_DWARF_TABLE_REF): Define.
3337
3338 2009-08-27  Kaz Kojima  <kkojima@gcc.gnu.org>
3339
3340         * config/sh/sh.c (split_branches): Check the result of
3341         next_active_insn.
3342
3343 2009-08-27  Steve Ellcey  <sje@cup.hp.com>
3344
3345         * config/ia64/hpux.h (LIB_SPEC): Add -lrt for when
3346         using -pthread -fopenmp
3347
3348 2009-08-27  Gerald Pfeifer  <gerald@pfeifer.com>
3349
3350         * doc/service.texi (service directory): Update URL.
3351
3352 2009-08-27  Uros Bizjak  <ubizjak@gmail.com>
3353
3354         PR rtl-optimization/40861
3355         * simplify-rtx.c (simplify_subreg): Do not call simplify_gen_subreg to
3356         extract word from a multi-word subreg for negative byte positions.
3357
3358 2009-08-27  Tristan Gingold  <gingold@adacore.com>
3359             Douglas B Rupp  <rupp@gnat.com>
3360
3361         * config/ia64/ia64.c (ia64_attribute_table): Add "common_object" entry.
3362         (SECTION_VMS_OVERLAY): Define.
3363         (ia64_vms_common_object_attribute): Added.  Handle the "common_object"
3364         attribute.
3365         (ia64_vms_elf_asm_named_section): Added.  Generate .section pseudo-op
3366         for common_object.
3367         (ia64_vms_output_aligned_decl_common): Added.  Generate pseudo-op for
3368         common_object declarations.
3369         (ia64_section_type_flags): Set section flag for common_object.
3370         * config/ia64/ia64-protos.h
3371         (ia64_vms_output_aligned_decl_common): Declare.
3372         (ia64_vms_elf_asm_named_section): Declare.
3373
3374 2009-08-27  Michael Matz  <matz@suse.de>
3375
3376         * expr.c (expand_expr_real_2): New function taking exploded
3377         unary or binary expression, split out from ...
3378         (expand_expr_real_1): ... here.  Move over all unary/binary
3379         switch parts to above function, in particular these codes:
3380         PAREN_EXPR, NOP_EXPR, CONVERT_EXPR, POINTER_PLUS_EXPR, PLUS_EXPR,
3381         MINUS_EXPR, MULT_EXPR, TRUNC_DIV_EXPR, FLOOR_DIV_EXPR, CEIL_DIV_EXPR,
3382         ROUND_DIV_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, TRUNC_MOD_EXPR,
3383         FLOOR_MOD_EXPR, CEIL_MOD_EXPR, ROUND_MOD_EXPR, FIXED_CONVERT_EXPR,
3384         FIX_TRUNC_EXPR, FLOAT_EXPR, NEGATE_EXPR, ABS_EXPR, MAX_EXPR, MIN_EXPR,
3385         BIT_NOT_EXPR, TRUTH_AND_EXPR, BIT_AND_EXPR, TRUTH_OR_EXPR,
3386         BIT_IOR_EXPR, TRUTH_XOR_EXPR, BIT_XOR_EXPR, LROTATE_EXPR, RROTATE_EXPR,
3387         LSHIFT_EXPR, RSHIFT_EXPR, LT_EXPR, LE_EXPR, GT_EXPR, GE_EXPR, EQ_EXPR,
3388         NE_EXPR, UNORDERED_EXPR, ORDERED_EXPR, UNLT_EXPR, UNLE_EXPR, UNGT_EXPR,
3389         UNGE_EXPR, UNEQ_EXPR, LTGT_EXPR, TRUTH_NOT_EXPR, COMPLEX_EXPR,
3390         WIDEN_SUM_EXPR, REDUC_MAX_EXPR, REDUC_MIN_EXPR, REDUC_PLUS_EXPR,
3391         VEC_EXTRACT_EVEN_EXPR, VEC_EXTRACT_ODD_EXPR, VEC_INTERLEAVE_HIGH_EXPR,
3392         VEC_INTERLEAVE_LOW_EXPR, VEC_LSHIFT_EXPR, VEC_RSHIFT_EXPR,
3393         VEC_UNPACK_HI_EXPR, VEC_UNPACK_LO_EXPR, VEC_UNPACK_FLOAT_HI_EXPR,
3394         VEC_UNPACK_FLOAT_LO_EXPR, VEC_WIDEN_MULT_HI_EXPR,
3395         VEC_WIDEN_MULT_LO_EXPR, VEC_PACK_TRUNC_EXPR, VEC_PACK_SAT_EXPR,
3396         VEC_PACK_FIX_TRUNC_EXPR.
3397         (<case PAREN_EXPR>): Call set_mem_attributes() with type, not the
3398         full expression.
3399
3400 2009-08-27  Richard Guenther  <rguenther@suse.de>
3401
3402         * gengtype.c (main): Handle uint64_t.
3403         * ipa-utils.c (get_base_var): Indent properly.
3404         * tree-ssa-live.c (debug_scope_block): New function.
3405         * tree-flow.h (debug_scope_block): Declare.
3406         * tree-ssa-copy.c (replace_exp_1): Add vertical space.
3407         * basic-block.h (enum profile_status): Rename to
3408         enum profile_status_d.
3409         (x_profile_status): Adjust type.
3410
3411 2009-08-27  Dodji Seketeli  <dodji@redhat.com>
3412
3413         PR debug/41170
3414         * dwarf2out.c (get_context_die): Declare this static function.
3415         (gen_type_die_with_usage): Make sure a DIE is a generated for
3416         the context of a typedef.
3417
3418 2009-08-26  Anatoly Sokolov  <aesok@post.ru>
3419
3420         * doc/invoke.texi (AVR Options): Remove documentation of -minit-stack
3421         switch.
3422
3423 2009-08-26  Richard Sandiford  <rdsandiford@googlemail.com>
3424
3425         * config/mips/mips-protos.h (mips_output_sync): Declare.
3426         (mips_sync_loop_insns): Likewise.
3427         (mips_output_sync_loop): Replace first two parameters with an rtx.
3428         * config/mips/mips.c (mips_multi_member): New structure.
3429         (mips_multi_members): New variable.
3430         (mips_multi_start): New function.
3431         (mips_multi_add): Likewise.
3432         (mips_multi_add_insn): Likewise.
3433         (mips_multi_add_label): Likewise.
3434         (mips_multi_last_index): Likewise.
3435         (mips_multi_copy_insn): Likewise.
3436         (mips_multi_set_operand): Likewise.
3437         (mips_multi_write): Likewise.
3438         (mips_print_operand_punctuation): Remove '%|' and '%-'.
3439         (mips_init_print_operand_punct): Update accordingly.
3440         (mips_start_ll_sc_sync_block): New function.
3441         (mips_end_ll_sc_sync_block): Likewise.
3442         (mips_output_sync): Likewise.
3443         (mips_sync_insn1_template): Likewise.
3444         (mips_sync_insn2_template): Likewise.
3445         (mips_get_sync_operand): Likewise.
3446         (mips_process_sync_loop): Likewise.
3447         (mips_output_sync_loop): Use mips_process_sync_loop.
3448         (mips_sync_loop_insns): New function.
3449         * config/mips/mips.h (MIPS_COMPARE_AND_SWAP): Delete.
3450         (MIPS_COMPARE_AND_SWAP_12): Likewise.
3451         (MIPS_COMPARE_AND_SWAP_12_ZERO_OP): Likewise.
3452         (MIPS_COMPARE_AND_SWAP_12_NONZERO_OP): Likewise.
3453         (MIPS_SYNC_OP, MIPS_SYNC_OP_12): Likewise.
3454         (MIPS_SYNC_OP_12_AND, MIPS_SYNC_OP_12_XOR): Likewise.
3455         (MIPS_SYNC_OLD_OP_12): Likewise.
3456         (MIPS_SYNC_OLD_OP_12_AND, MIPS_SYNC_OLD_OP_12_XOR): Likewise.
3457         (MIPS_SYNC_NEW_OP_12): Likewise.
3458         (MIPS_SYNC_NEW_OP_12_AND, MIPS_SYNC_NEW_OP_12_XOR): Likewise.
3459         (MIPS_SYNC_OLD_OP, MIPS_SYNC_NEW_OP): Likewise.
3460         (MIPS_SYNC_NAND, MIPS_SYNC_OLD_NAND, MIPS_SYNC_NEW_NAND): Likewise.
3461         (MIPS_SYNC_EXCHANGE, MIPS_SYNC_EXCHANGE_12): Likewise.
3462         (MIPS_SYNC_EXCHANGE_12_ZERO_OP): Likewise.
3463         (MIPS_SYNC_EXCHANGE_12_NONZER_OP): Likewise.
3464         * config/mips/mips.md (sync_mem): New attribute.
3465         (sync_oldval, sync_newval, sync_inclusive_mask): Likewise.
3466         (sync_exclusive_mask, sync_required_oldval): Likewise.
3467         (sync_insn1_op2, sync_insn1, sync_insn2): Likewise.
3468         (sync_release_barrier): Likewise.
3469         (length): Handle sync loops.
3470         (sync): Use mips_output_sync.
3471         * config/mips/sync.md (*memory_barrier): Use mips_output_sync.
3472         (sync_compare_and_swap<mode>): Set the new sync_* attributes
3473         and use mips_output_sync_loop.
3474         (compare_and_swap_12, sync_add<mode>, sync_<optab>_12): Likewise.
3475         (sync_old_<optab>_12, sync_new_<optab>_12, sync_nand_12): Likewise.
3476         (sync_old_nand_12, sync_new_nand_12, sync_sub<mode>): Likewise.
3477         (sync_old_add<mode>, sync_old_sub<mode>): Likewise.
3478         (sync_new_add<mode>, sync_new_sub<mode>): Likewise.
3479         (sync_<optab><mode>, sync_old_<optab><mode>): Likewise.
3480         (sync_new_<optab><mode>, sync_nand<mode>): Likewise.
3481         (sync_old_nand<mode>, sync_new_nand<mode>): Likewise.
3482         (sync_lock_test_and_set<mode>, test_and_set_12): Likewise.
3483
3484 2009-08-26  Richard Guenther  <rguenther@suse.de>
3485
3486         PR middle-end/41163
3487         * gimplify.c (gimplify_addr_expr): Canonicalize ADDR_EXPRs if
3488         the types to not match.
3489         * tree-cfg.c (verify_gimple_assign_single): Adjust ADDR_EXPR
3490         verification.
3491         * tree-ssa.c (useless_type_conversion_p): Conversions to
3492         pointers to unprototyped functions are useless.
3493
3494 2009-08-26  Richard Guenther  <rguenther@suse.de>
3495
3496         * tree-ssa-structalias.c (create_variable_info_for): Remove strange
3497         whole-program condition, prepare to be called for non-globals.
3498         (intra_create_variable_infos): For restrict qualified DECL_BY_REFERENCE
3499         params build a representative with known type and track its fields.
3500
3501 2009-08-26  Uros Bizjak  <ubizjak@gmail.com>
3502
3503         * config/alpha/sync.md: Update comment about unpredictable LL/SC lock
3504         clearing by a taken branch.
3505         (sync_<fetchop_name><mode>): Split when epilogue_completed is set,
3506         effectively after bbro pass.
3507         (sync_nand<mode>): Ditto.
3508         (sync_old_<fetchop_name><mode>): Ditto.
3509         (sync_old_nand<mode>): Ditto.
3510         (sync_new_<fetchop_name><mode>): Dito.
3511         (sync_new_nand<mode>): Ditto.
3512         (sync_compare_and_swap<mode>_1): Ditto.
3513         (*sync_compare_and_swap<mode>): Ditto.
3514         (sync_lock_test_and_set<mode>_1): Ditto.
3515         ("sync_lock_test_and_set<mode>): Ditto.
3516
3517 2009-08-25  Douglas B Rupp  <rupp@gnat.com>
3518
3519         * hwint.h (HOST_LONG_FORMAT): New macro
3520         * bitmap.c, c-decl.c, mips-tfile.c, print-rtl.c, print-tree.c:
3521         Use HOST_PTR_PRINTF.
3522         * system.h (HOST_PTR_PRINTF): Resurrect old macro
3523         * doc/hostconfig.texi (HOST_LONG_FORMAT): Document.
3524         (HOST_PTR_PRINTF): Document.
3525
3526 2009-08-25 Jan Hubicka  <jh@suse.cz>
3527
3528         * config/i386/bmmintrin.h: Replace by #error.
3529
3530         Revert:
3531         Michael Meissner  <michael.meissner@amd.com>
3532         Dwarakanath Rajagopal  <dwarak.rajagopal@amd.com>
3533         Tony Linthicum  <tony.linthicum@amd.com>
3534
3535         * config/i386/i386.h (TARGET_SSE5): New macro for SSE5.
3536         (TARGET_ROUND): New macro for the round/ptest instructions which
3537         are shared between SSE4.1 and SSE5.
3538         (OPTION_MASK_ISA_ROUND): Ditto.
3539         (OPTION_ISA_ROUND): Ditto.
3540         (TARGET_FUSED_MADD): New macro for -mfused-madd swtich.
3541         (TARGET_CPU_CPP_BUILTINS): Add SSE5 support.
3542
3543         * config/i386/i386.opt (-msse5): New switch for SSE5 support.
3544         (-mfused-madd): New switch to give users control over whether the
3545         compiler optimizes to use the multiply/add SSE5 instructions.
3546
3547         * config/i386/i386.c (enum pta_flags): Add PTA_SSE5.
3548         (ix86_handle_option): Turn off 3dnow if -msse5.
3549         (override_options): Add SSE5 support.
3550         (print_operand): %Y prints comparison codes for SSE5 com/pcom
3551         instructions.
3552         (ix86_expand_sse_movcc): Add SSE5 support.
3553         (ix86_expand_sse5_unpack): New function to use pperm to unpack a
3554         vector type to the next largest size.
3555         (ix86_expand_sse5_pack): New function to use pperm to pack a
3556         vector type to the next smallest size.
3557         (IX86_BUILTIN_FMADDSS): New for SSE5 intrinsic.
3558         (IX86_BUILTIN_FMADDSD): Ditto.
3559         (IX86_BUILTIN_FMADDPS): Ditto.
3560         (IX86_BUILTIN_FMADDPD): Ditto.
3561         (IX86_BUILTIN_FMSUBSS): Ditto.
3562         (IX86_BUILTIN_FMSUBSD): Ditto.
3563         (IX86_BUILTIN_FMSUBPS): Ditto.
3564         (IX86_BUILTIN_FMSUBPD): Ditto.
3565         (IX86_BUILTIN_FNMADDSS): Ditto.
3566         (IX86_BUILTIN_FNMADDSD): Ditto.
3567         (IX86_BUILTIN_FNMADDPS): Ditto.
3568         (IX86_BUILTIN_FNMADDPD): Ditto.
3569         (IX86_BUILTIN_FNMSUBSS): Ditto.
3570         (IX86_BUILTIN_FNMSUBSD): Ditto.
3571         (IX86_BUILTIN_FNMSUBPS): Ditto.
3572         (IX86_BUILTIN_FNMSUBPD): Ditto.
3573         (IX86_BUILTIN_PCMOV_V2DI): Ditto.
3574         (IX86_BUILTIN_PCMOV_V4SI): Ditto.
3575         (IX86_BUILTIN_PCMOV_V8HI): Ditto.
3576         (IX86_BUILTIN_PCMOV_V16QI): Ditto.
3577         (IX86_BUILTIN_PCMOV_V4SF): Ditto.
3578         (IX86_BUILTIN_PCMOV_V2DF): Ditto.
3579         (IX86_BUILTIN_PPERM): Ditto.
3580         (IX86_BUILTIN_PERMPS): Ditto.
3581         (IX86_BUILTIN_PERMPD): Ditto.
3582         (IX86_BUILTIN_PMACSSWW): Ditto.
3583         (IX86_BUILTIN_PMACSWW): Ditto.
3584         (IX86_BUILTIN_PMACSSWD): Ditto.
3585         (IX86_BUILTIN_PMACSWD): Ditto.
3586         (IX86_BUILTIN_PMACSSDD): Ditto.
3587         (IX86_BUILTIN_PMACSDD): Ditto.
3588         (IX86_BUILTIN_PMACSSDQL): Ditto.
3589         (IX86_BUILTIN_PMACSSDQH): Ditto.
3590         (IX86_BUILTIN_PMACSDQL): Ditto.
3591         (IX86_BUILTIN_PMACSDQH): Ditto.
3592         (IX86_BUILTIN_PMADCSSWD): Ditto.
3593         (IX86_BUILTIN_PMADCSWD): Ditto.
3594         (IX86_BUILTIN_PHADDBW): Ditto.
3595         (IX86_BUILTIN_PHADDBD): Ditto.
3596         (IX86_BUILTIN_PHADDBQ): Ditto.
3597         (IX86_BUILTIN_PHADDWD): Ditto.
3598         (IX86_BUILTIN_PHADDWQ): Ditto.
3599         (IX86_BUILTIN_PHADDDQ): Ditto.
3600         (IX86_BUILTIN_PHADDUBW): Ditto.
3601         (IX86_BUILTIN_PHADDUBD): Ditto.
3602         (IX86_BUILTIN_PHADDUBQ): Ditto.
3603         (IX86_BUILTIN_PHADDUWD): Ditto.
3604         (IX86_BUILTIN_PHADDUWQ): Ditto.
3605         (IX86_BUILTIN_PHADDUDQ): Ditto.
3606         (IX86_BUILTIN_PHSUBBW): Ditto.
3607         (IX86_BUILTIN_PHSUBWD): Ditto.
3608         (IX86_BUILTIN_PHSUBDQ): Ditto.
3609         (IX86_BUILTIN_PROTB): Ditto.
3610         (IX86_BUILTIN_PROTW): Ditto.
3611         (IX86_BUILTIN_PROTD): Ditto.
3612         (IX86_BUILTIN_PROTQ): Ditto.
3613         (IX86_BUILTIN_PROTB_IMM): Ditto.
3614         (IX86_BUILTIN_PROTW_IMM): Ditto.
3615         (IX86_BUILTIN_PROTD_IMM): Ditto.
3616         (IX86_BUILTIN_PROTQ_IMM): Ditto.
3617         (IX86_BUILTIN_PSHLB): Ditto.
3618         (IX86_BUILTIN_PSHLW): Ditto.
3619         (IX86_BUILTIN_PSHLD): Ditto.
3620         (IX86_BUILTIN_PSHLQ): Ditto.
3621         (IX86_BUILTIN_PSHAB): Ditto.
3622         (IX86_BUILTIN_PSHAW): Ditto.
3623         (IX86_BUILTIN_PSHAD): Ditto.
3624         (IX86_BUILTIN_PSHAQ): Ditto.
3625         (IX86_BUILTIN_FRCZSS): Ditto.
3626         (IX86_BUILTIN_FRCZSD): Ditto.
3627         (IX86_BUILTIN_FRCZPS): Ditto.
3628         (IX86_BUILTIN_FRCZPD): Ditto.
3629         (IX86_BUILTIN_CVTPH2PS): Ditto.
3630         (IX86_BUILTIN_CVTPS2PH): Ditto.
3631         (IX86_BUILTIN_COMEQSS): Ditto.
3632         (IX86_BUILTIN_COMNESS): Ditto.
3633         (IX86_BUILTIN_COMLTSS): Ditto.
3634         (IX86_BUILTIN_COMLESS): Ditto.
3635         (IX86_BUILTIN_COMGTSS): Ditto.
3636         (IX86_BUILTIN_COMGESS): Ditto.
3637         (IX86_BUILTIN_COMUEQSS): Ditto.
3638         (IX86_BUILTIN_COMUNESS): Ditto.
3639         (IX86_BUILTIN_COMULTSS): Ditto.
3640         (IX86_BUILTIN_COMULESS): Ditto.
3641         (IX86_BUILTIN_COMUGTSS): Ditto.
3642         (IX86_BUILTIN_COMUGESS): Ditto.
3643         (IX86_BUILTIN_COMORDSS): Ditto.
3644         (IX86_BUILTIN_COMUNORDSS): Ditto.
3645         (IX86_BUILTIN_COMFALSESS): Ditto.
3646         (IX86_BUILTIN_COMTRUESS): Ditto.
3647         (IX86_BUILTIN_COMEQSD): Ditto.
3648         (IX86_BUILTIN_COMNESD): Ditto.
3649         (IX86_BUILTIN_COMLTSD): Ditto.
3650         (IX86_BUILTIN_COMLESD): Ditto.
3651         (IX86_BUILTIN_COMGTSD): Ditto.
3652         (IX86_BUILTIN_COMGESD): Ditto.
3653         (IX86_BUILTIN_COMUEQSD): Ditto.
3654         (IX86_BUILTIN_COMUNESD): Ditto.
3655         (IX86_BUILTIN_COMULTSD): Ditto.
3656         (IX86_BUILTIN_COMULESD): Ditto.
3657         (IX86_BUILTIN_COMUGTSD): Ditto.
3658         (IX86_BUILTIN_COMUGESD): Ditto.
3659         (IX86_BUILTIN_COMORDSD): Ditto.
3660         (IX86_BUILTIN_COMUNORDSD): Ditto.
3661         (IX86_BUILTIN_COMFALSESD): Ditto.
3662         (IX86_BUILTIN_COMTRUESD): Ditto.
3663         (IX86_BUILTIN_COMEQPS): Ditto.
3664         (IX86_BUILTIN_COMNEPS): Ditto.
3665         (IX86_BUILTIN_COMLTPS): Ditto.
3666         (IX86_BUILTIN_COMLEPS): Ditto.
3667         (IX86_BUILTIN_COMGTPS): Ditto.
3668         (IX86_BUILTIN_COMGEPS): Ditto.
3669         (IX86_BUILTIN_COMUEQPS): Ditto.
3670         (IX86_BUILTIN_COMUNEPS): Ditto.
3671         (IX86_BUILTIN_COMULTPS): Ditto.
3672         (IX86_BUILTIN_COMULEPS): Ditto.
3673         (IX86_BUILTIN_COMUGTPS): Ditto.
3674         (IX86_BUILTIN_COMUGEPS): Ditto.
3675         (IX86_BUILTIN_COMORDPS): Ditto.
3676         (IX86_BUILTIN_COMUNORDPS): Ditto.
3677         (IX86_BUILTIN_COMFALSEPS): Ditto.
3678         (IX86_BUILTIN_COMTRUEPS): Ditto.
3679         (IX86_BUILTIN_COMEQPD): Ditto.
3680         (IX86_BUILTIN_COMNEPD): Ditto.
3681         (IX86_BUILTIN_COMLTPD): Ditto.
3682         (IX86_BUILTIN_COMLEPD): Ditto.
3683         (IX86_BUILTIN_COMGTPD): Ditto.
3684         (IX86_BUILTIN_COMGEPD): Ditto.
3685         (IX86_BUILTIN_COMUEQPD): Ditto.
3686         (IX86_BUILTIN_COMUNEPD): Ditto.
3687         (IX86_BUILTIN_COMULTPD): Ditto.
3688         (IX86_BUILTIN_COMULEPD): Ditto.
3689         (IX86_BUILTIN_COMUGTPD): Ditto.
3690         (IX86_BUILTIN_COMUGEPD): Ditto.
3691         (IX86_BUILTIN_COMORDPD): Ditto.
3692         (IX86_BUILTIN_COMUNORDPD): Ditto.
3693         (IX86_BUILTIN_COMFALSEPD): Ditto.
3694         (IX86_BUILTIN_COMTRUEPD): Ditto.
3695         (IX86_BUILTIN_PCOMEQUB): Ditto.
3696         (IX86_BUILTIN_PCOMNEUB): Ditto.
3697         (IX86_BUILTIN_PCOMLTUB): Ditto.
3698         (IX86_BUILTIN_PCOMLEUB): Ditto.
3699         (IX86_BUILTIN_PCOMGTUB): Ditto.
3700         (IX86_BUILTIN_PCOMGEUB): Ditto.
3701         (IX86_BUILTIN_PCOMFALSEUB): Ditto.
3702         (IX86_BUILTIN_PCOMTRUEUB): Ditto.
3703         (IX86_BUILTIN_PCOMEQUW): Ditto.
3704         (IX86_BUILTIN_PCOMNEUW): Ditto.
3705         (IX86_BUILTIN_PCOMLTUW): Ditto.
3706         (IX86_BUILTIN_PCOMLEUW): Ditto.
3707         (IX86_BUILTIN_PCOMGTUW): Ditto.
3708         (IX86_BUILTIN_PCOMGEUW): Ditto.
3709         (IX86_BUILTIN_PCOMFALSEUW): Ditto.
3710         (IX86_BUILTIN_PCOMTRUEUW): Ditto.
3711         (IX86_BUILTIN_PCOMEQUD): Ditto.
3712         (IX86_BUILTIN_PCOMNEUD): Ditto.
3713         (IX86_BUILTIN_PCOMLTUD): Ditto.
3714         (IX86_BUILTIN_PCOMLEUD): Ditto.
3715         (IX86_BUILTIN_PCOMGTUD): Ditto.
3716         (IX86_BUILTIN_PCOMGEUD): Ditto.
3717         (IX86_BUILTIN_PCOMFALSEUD): Ditto.
3718         (IX86_BUILTIN_PCOMTRUEUD): Ditto.
3719         (IX86_BUILTIN_PCOMEQUQ): Ditto.
3720         (IX86_BUILTIN_PCOMNEUQ): Ditto.
3721         (IX86_BUILTIN_PCOMLTUQ): Ditto.
3722         (IX86_BUILTIN_PCOMLEUQ): Ditto.
3723         (IX86_BUILTIN_PCOMGTUQ): Ditto.
3724         (IX86_BUILTIN_PCOMGEUQ): Ditto.
3725         (IX86_BUILTIN_PCOMFALSEUQ): Ditto.
3726         (IX86_BUILTIN_PCOMTRUEUQ): Ditto.
3727         (IX86_BUILTIN_PCOMEQB): Ditto.
3728         (IX86_BUILTIN_PCOMNEB): Ditto.
3729         (IX86_BUILTIN_PCOMLTB): Ditto.
3730         (IX86_BUILTIN_PCOMLEB): Ditto.
3731         (IX86_BUILTIN_PCOMGTB): Ditto.
3732         (IX86_BUILTIN_PCOMGEB): Ditto.
3733         (IX86_BUILTIN_PCOMFALSEB): Ditto.
3734         (IX86_BUILTIN_PCOMTRUEB): Ditto.
3735         (IX86_BUILTIN_PCOMEQW): Ditto.
3736         (IX86_BUILTIN_PCOMNEW): Ditto.
3737         (IX86_BUILTIN_PCOMLTW): Ditto.
3738         (IX86_BUILTIN_PCOMLEW): Ditto.
3739         (IX86_BUILTIN_PCOMGTW): Ditto.
3740         (IX86_BUILTIN_PCOMGEW): Ditto.
3741         (IX86_BUILTIN_PCOMFALSEW): Ditto.
3742         (IX86_BUILTIN_PCOMTRUEW): Ditto.
3743         (IX86_BUILTIN_PCOMEQD): Ditto.
3744         (IX86_BUILTIN_PCOMNED): Ditto.
3745         (IX86_BUILTIN_PCOMLTD): Ditto.
3746         (IX86_BUILTIN_PCOMLED): Ditto.
3747         (IX86_BUILTIN_PCOMGTD): Ditto.
3748         (IX86_BUILTIN_PCOMGED): Ditto.
3749         (IX86_BUILTIN_PCOMFALSED): Ditto.
3750         (IX86_BUILTIN_PCOMTRUED): Ditto.
3751         (IX86_BUILTIN_PCOMEQQ): Ditto.
3752         (IX86_BUILTIN_PCOMNEQ): Ditto.
3753         (IX86_BUILTIN_PCOMLTQ): Ditto.
3754         (IX86_BUILTIN_PCOMLEQ): Ditto.
3755         (IX86_BUILTIN_PCOMGTQ): Ditto.
3756         (IX86_BUILTIN_PCOMGEQ): Ditto.
3757         (IX86_BUILTIN_PCOMFALSEQ): Ditto.
3758         (IX86_BUILTIN_PCOMTRUEQ): Ditto.
3759         (enum multi_arg_type): New enum for describing the various SSE5
3760         intrinsic argument types.
3761         (bdesc_multi_arg): New table for SSE5 intrinsics.
3762         (ix86_init_mmx_sse_builtins): Add SSE5 intrinsic support.
3763         (ix86_expand_multi_arg_builtin): New function for creating SSE5
3764         intrinsics.
3765         (ix86_expand_builtin): Add SSE5 intrinsic support.
3766         (ix86_sse5_valid_op_p): New function to validate SSE5 3 and 4
3767         operand instructions.
3768         (ix86_expand_sse5_multiple_memory): New function to split the
3769         second memory reference from SSE5 instructions.
3770         (type_has_variadic_args_p): Delete in favor of stdarg_p.
3771         (ix86_return_pops_args): Use stdarg_p to determine if the function
3772         has variable arguments.
3773         (ix86_setup_incoming_varargs): Ditto.
3774         (x86_this_parameter): Ditto.
3775
3776         * config/i386/i386-protos.h (ix86_expand_sse5_unpack): Add
3777         declaration.
3778         (ix86_expand_sse5_pack): Ditto.
3779         (ix86_sse5_valid_op_p): Ditto.
3780         (ix86_expand_sse5_multiple_memory): Ditto.
3781
3782         * config/i386/i386.md (UNSPEC_SSE5_INTRINSIC): Add new UNSPEC
3783         constant for SSE5 support.
3784         (UNSPEC_SSE5_UNSIGNED_CMP): Ditto.
3785         (UNSPEC_SSE5_TRUEFALSE): Ditto.
3786         (UNSPEC_SSE5_PERMUTE): Ditto.
3787         (UNSPEC_SSE5_ASHIFT): Ditto.
3788         (UNSPEC_SSE5_LSHIFT): Ditto.
3789         (UNSPEC_FRCZ): Ditto.
3790         (UNSPEC_CVTPH2PS): Ditto.
3791         (UNSPEC_CVTPS2PH): Ditto.
3792         (PCOM_FALSE): Add new constant for true/false SSE5 comparisons.
3793         (PCOM_TRUE): Ditto.
3794         (COM_FALSE_S): Ditto.
3795         (COM_FALSE_P): Ditto.
3796         (COM_TRUE_S): Ditto.
3797         (COM_TRUE_P): Ditto.
3798         (type attribute): Add ssemuladd, sseiadd1, ssecvt1, sse4arg types.
3799         (unit attribute): Add support for ssemuladd, ssecvt1, sseiadd1 sse4arg
3800         types.
3801         (memory attribute): Ditto.
3802         (sse4_1_round<mode>2): Use TARGET_ROUND instead of TARGET_SSE4_1.
3803         Use SSE4_1_ROUND_* constants instead of hard coded numbers.
3804         (rint<mode>2): Use TARGET_ROUND instead of TARGET_SSE4_1.
3805         (floor<mode>2): Ditto.
3806         (ceil<mode>2): Ditto.
3807         (btrunc<mode>2): Ditto.
3808         (nearbyintdf2): Ditto.
3809         (nearbyintsf2): Ditto.
3810         (sse_setccsf): Disable if SSE5.
3811         (sse_setccdf): Ditto.
3812         (sse5_setcc<mode>): New support for SSE5 conditional move.
3813         (sse5_pcmov_<mode>): Ditto.
3814
3815         * config/i386/sse.md (SSEMODE1248): New mode iterator for SSE5.
3816         (SSEMODEF4): Ditto.
3817         (SSEMODEF2P): Ditto.
3818         (ssemodesuffixf4): New mode attribute for SSE5.
3819         (ssemodesuffixf2s): Ditto.
3820         (ssemodesuffixf2c): Ditto.
3821         (sserotatemax): Ditto.
3822         (ssescalarmode): Ditto.
3823         (sse_maskcmpv4sf3): Disable if SSE5.
3824         (sse_maskcmpv2df3): Ditto.
3825         (sse_vmmaskcmpv4sf3): Ditto.
3826         (sse5_fmadd<mode>4): Add SSE5 floating point multiply/add instructions.
3827         (sse5_vmfmadd<mode>4): Ditto.
3828         (sse5_fmsub<mode>4): Ditto.
3829         (sse5_vmfmsub<mode>4): Ditto.
3830         (sse5_fnmadd<mode>4): Ditto.
3831         (sse5_vmfnmadd<mode>4): Ditto.
3832         (sse5_fnmsub<mode>4): Ditto.
3833         (sse5_vmfnmsub<mode>4): Ditto.
3834         (sse5i_fmadd<mode>4): Ditto.
3835         (sse5i_fmsub<mode>4): Ditto.
3836         (sse5i_fnmadd<mode>4): Ditto.
3837         (sse5i_fnmsub<mode>4): Ditto.
3838         (sse5i_vmfmadd<mode>4): Ditto.
3839         (sse5i_vmfmsub<mode>4): Ditto.
3840         (sse5i_vmfnmadd<mode>4): Ditto.
3841         (sse5i_vmfnmsub<mode>4): Ditto.
3842         (mulv16qi3): Add SSE5 support.
3843         (mulv4si3): Ditto.
3844         (sse5_mulv4si3): New insn for 32-bit multiply support on SSE5.
3845         (sse2_mulv4si3): Disable if SSE5.
3846         (sse4_1_roundpd): Use TARGET_ROUND instead of TARGET_SSE4_1.
3847         (sse4_1_roundps): Ditto.
3848         (sse4_1_roundsd): Ditto.
3849         (sse4_1_roundss): Ditto.
3850         (sse_maskcmpv4sf3): Disable if SSE5 so the SSE5 instruction will
3851         be generated.
3852         (sse_maskcmpsf3): Ditto.
3853         (sse_vmmaskcmpv4sf3): Ditto.
3854         (sse2_maskcmpv2df3): Ditto.
3855         (sse2_maskcmpdf3): Ditto.
3856         (sse2_vmmaskcmpv2df3): Ditto.
3857         (sse2_eq<mode>3): Ditto.
3858         (sse2_gt<mode>3): Ditto.
3859         (sse5_pcmov_<mode>): Add SSE5 support.
3860         (vec_unpacku_hi_v16qi): Ditto.
3861         (vec_unpacks_hi_v16qi): Ditto.
3862         (vec_unpacku_lo_v16qi): Ditto.
3863         (vec_unpacks_lo_v16qi): Ditto.
3864         (vec_unpacku_hi_v8hi): Ditto.
3865         (vec_unpacks_hi_v8hi): Ditto.
3866         (vec_unpacku_lo_v8hi): Ditto.
3867         (vec_unpacks_lo_v8hi): Ditto.
3868         (vec_unpacku_hi_v4si): Ditto.
3869         (vec_unpacks_hi_v4si): Ditto.
3870         (vec_unpacku_lo_v4si): Ditto.
3871         (vec_unpacks_lo_v4si): Ditto.
3872         (sse5_pmacsww): New SSE5 intrinsic insn.
3873         (sse5_pmacssww): Ditto.
3874         (sse5_pmacsdd): Ditto.
3875         (sse5_pmacssdd): Ditto.
3876         (sse5_pmacssdql): Ditto.
3877         (sse5_pmacssdqh): Ditto.
3878         (sse5_pmacsdqh): Ditto.
3879         (sse5_pmacsswd): Ditto.
3880         (sse5_pmacswd): Ditto.
3881         (sse5_pmadcsswd): Ditto.
3882         (sse5_pmadcswd): Ditto.
3883         (sse5_pcmov_<move>): Conditional move support on SSE5.
3884         (sse5_phaddbw): New SSE5 intrinsic insn.
3885         (sse5_phaddbd): Ditto.
3886         (sse5_phaddbq): Ditto.
3887         (sse5_phaddwd): Ditto.
3888         (sse5_phaddwq): Ditto.
3889         (sse5_phadddq): Ditto.
3890         (sse5_phaddubw): Ditto.
3891         (sse5_phaddubd): Ditto.
3892         (sse5_phaddubq): Ditto.
3893         (sse5_phadduwd): Ditto.
3894         (sse5_phadduwq): Ditto.
3895         (sse5_phaddudq): Ditto.
3896         (sse5_phsubbw): Ditto.
3897         (sse5_phsubwd): Ditto.
3898         (sse5_phsubdq): Ditto.
3899         (sse5_pperm): Ditto.
3900         (sse5_pperm_sign_v16qi_v8hi): New insns for pack/unpack with SSE5.
3901         (sse5_pperm_zero_v16qi_v8hi): Ditto.
3902         (sse5_pperm_sign_v8hi_v4si): Ditto.
3903         (sse5_pperm_zero_v8hi_v4si): Ditto.
3904         (sse5_pperm_sign_v4si_v2di): Ditto.
3905         (sse5_pperm_sign_v4si_v2di): Ditto.
3906         (sse5_pperm_pack_v2di_v4si): Ditto.
3907         (sse5_pperm_pack_v4si_v8hi): Ditto.
3908         (sse5_pperm_pack_v8hi_v16qi): Ditto.
3909         (sse5_perm<mode>): New SSE5 intrinsic insn.
3910         (rotl<mode>3): Ditto.
3911         (sse5_rotl<mode>3): Ditto.
3912         (sse5_ashl<mode>3): Ditto.
3913         (sse5_lshl<mode>3): Ditto.
3914         (sse5_frcz<mode>2): Ditto.
3915         (sse5s_frcz<mode>2): Ditto.
3916         (sse5_cvtph2ps): Ditto.
3917         (sse5_cvtps2ph): Ditto.
3918         (sse5_vmmaskcmp<mode>3): Ditto.
3919         (sse5_com_tf<mode>3): Ditto.
3920         (sse5_maskcmp<mode>3): Ditto.
3921         (sse5_maskcmp_uns<mode>3): Ditto.
3922         (sse5_maskcmp_uns2<mode>3): Ditto.
3923         (sse5_pcom_tf<mode>3): Ditto.
3924
3925         * config/i386/predicates.md (sse5_comparison_float_operator):
3926         New predicate to match the comparison operators supported by
3927         the SSE5 com instruction.
3928         (ix86_comparison_int_operator): New predicate to match just the
3929         signed int comparisons.
3930         (ix86_comparison_uns_operator): New predicate to match just the
3931         unsigned int comparisons.
3932
3933         * doc/invoke.texi (-msse5): Add documentation.
3934         (-mfused-madd): Ditto.
3935
3936         * doc/extend.texi (x86 intrinsics): Document new SSE5 intrinsics.
3937
3938         * config.gcc (i[34567]86-*-*): Include bmmintrin.h and
3939         mmintrin-common.h.
3940         (x86_64-*-*): Ditto.
3941
3942         * config/i386/cpuid.h (bit_SSE5): Define SSE5 bit.
3943
3944         * config/i386/bmmintrin.h: New file, provide common x86 compiler
3945         intrinisics for SSE5.
3946
3947         * config/i386/smmintrin.h: Move instructions shared with SSE5 to
3948         mmintrin-common.h.
3949
3950         * config/i386/mmintrin-common.h: New file, to contain common
3951         instructions between SSE4.1 and SSE5.
3952
3953         * config/i386/netware.c (gen_stdcall_or_fastcall_decoration): Use
3954         FOREACH_FUNCTION_ARGS to iterate over the argument list.
3955         (gen_regparm_prefix): Ditto.
3956
3957         * config/i386/winnt.c (gen_stdcall_or_fastcall_suffix): Use
3958         FOREACH_FUNCTION_ARGS to iterate over the argument list.  Use
3959         prototype_p to determine if a function is prototyped.
3960
3961 2009-08-25 Ville Voutilainen <ville.voutilainen@gmail.com>
3962
3963         * c-common.c (c_common_reswords) add the alignof keyword,
3964         with same RID as __alignof and __alignof__
3965
3966 2009-08-25  Anatoly Sokolov  <aesok@post.ru>
3967
3968         * hooks.h (hook_bool_const_int_const_int_true): Declare.
3969         * hooks.c (hook_bool_const_int_const_int_true): New function.
3970         * target.h (struct gcc_target): Add can_eliminate field.
3971         * target-def.h (TARGET_CAN_ELIMINATE): Define.
3972         (TARGET_INITIALIZER): Use TARGET_CAN_ELIMINATE.
3973         * ira.c (setup_eliminable_regset): Use can_eliminate target hook.
3974         * reload1.c (update_eliminables, init_elim_table): (Ditto.).
3975         (elim_table): Revise comment.
3976         * system.h (CAN_ELIMINATE): Poison.
3977         * defaults.h (CAN_ELIMINATE): Remove.
3978         * doc/tm.texi (CAN_ELIMINATE): Revise documentation.
3979
3980         * config/alpha/vms.h (CAN_ELIMINATE): Remove macro.
3981         * config/alpha/alpha.c (TARGET_CAN_ELIMINATE) [TARGET_ABI_OPEN_VMS]:
3982         Define macro.
3983         (alpha_vms_can_eliminate): Declare as static, change return type to
3984         bool.
3985         * config/alpha/alpha-protos.h (alpha_vms_can_eliminate): Remove.
3986
3987         * config/arm/arm.h (CAN_ELIMINATE): Remove macro.
3988         * config/arm/arm.c (TARGET_CAN_ELIMINATE): Define macro.
3989         (arm_can_eliminate): New function.
3990
3991         * config/avr/avr.h (CAN_ELIMINATE): Remove macro.
3992         * config/avr/avr.c (TARGET_CAN_ELIMINATE): Define macro.
3993         (avr_can_eliminate): Declare as static.
3994         * config/avr/avr-protos.h (avr_can_eliminate): Remove.
3995
3996         * config/bfin/bfin.h (CAN_ELIMINATE): Remove macro.
3997         * config/bfin/bfin.c (TARGET_CAN_ELIMINATE): Define macro.
3998         (bfin_can_eliminate): New function.
3999
4000         * config/crx/crx.h (CAN_ELIMINATE): Remove macro.
4001         * config/crx/crx.c (TARGET_CAN_ELIMINATE): Define macro.
4002         (crx_can_eliminate): New function.
4003
4004         * config/fr30/fr30.h (CAN_ELIMINATE): Remove macro.
4005         * config/fr30/fr30.c (TARGET_CAN_ELIMINATE): Define macro.
4006         (fr30_can_eliminate): New function.
4007
4008         * config/frv/frv.h (CAN_ELIMINATE): Remove macro.
4009         * config/frv/frv.c (TARGET_CAN_ELIMINATE): Define macro.
4010         (frv_can_eliminate): New function.
4011
4012         * config/h8300/h8300.h (CAN_ELIMINATE): Remove macro.
4013         * config/h8300/h8300.c (TARGET_CAN_ELIMINATE): Define macro.
4014         (h8300_can_eliminate): New function.
4015
4016         * config/i386/i386.h (CAN_ELIMINATE): Remove macro.
4017         * config/i386/i386.c (TARGET_CAN_ELIMINATE): Define macro.
4018         (i386_can_eliminate): Declare as static, change return type to bool.
4019         * config/i386/i386-protos.h (i386_can_eliminate): Remove.
4020
4021         * config/ia64/ia64.h (CAN_ELIMINATE): Remove macro.
4022         * config/ia64/ia64.c (TARGET_CAN_ELIMINATE): Define macro.
4023         (ia64_can_eliminate): New function.
4024
4025         * config/iq2000/iq2000.h (CAN_ELIMINATE): Remove macro.
4026         * config/iq2000/iq2000.c (TARGET_CAN_ELIMINATE): Define macro.
4027         (iq2000_can_eliminate): New function.
4028
4029         * config/m32r/m32r.h (CAN_ELIMINATE): Remove macro.
4030         * config/m32r/m32r.c (TARGET_CAN_ELIMINATE): Define macro.
4031         (m32r_can_eliminate): New function.
4032
4033         * config/m68hc11/m68hc11.h (CAN_ELIMINATE): Remove macro.
4034         * config/m68hc11/m68hc11.c (TARGET_CAN_ELIMINATE): Define macro.
4035         (m68hc11_can_eliminate): New function.
4036
4037         * config/m68k/m68k.h (CAN_ELIMINATE): Remove macro.
4038         * config/m68k/m68k.c (TARGET_CAN_ELIMINATE): Define macro.
4039         (m68k_can_eliminate): New function.
4040
4041         * config/mep/mep.h (CAN_ELIMINATE): Remove macro.
4042         * config/mep/mep.c (TARGET_CAN_ELIMINATE): Define macro.
4043         (mep_can_eliminate): New function.
4044
4045         * config/mips/mips.h (CAN_ELIMINATE): Remove macro.
4046         * config/mips/mips.c (TARGET_CAN_ELIMINATE): Define macro.
4047         (mips_can_eliminate): New function.
4048
4049         * config/rs6000/rs6000.h (CAN_ELIMINATE): Remove macro.
4050         * config/rs6000/rs6000.c (TARGET_CAN_ELIMINATE): Define macro.
4051         (rs6000_can_eliminate): New function.
4052
4053         * config/s390/s390.h (CAN_ELIMINATE): Remove macro.
4054         * config/s390/s390.c (TARGET_CAN_ELIMINATE): Define macro.
4055         (s390_can_eliminate): Declare as static.
4056         * config/s390/s390-protos.h (sparc_can_eliminate): Remove.
4057
4058         * config/score/score.h (CAN_ELIMINATE): Remove macro.
4059         * config/score/score.c (TARGET_CAN_ELIMINATE): Define macro.
4060         (score_can_eliminate): New function.
4061
4062         * config/sparc/sparc.h (CAN_ELIMINATE): Remove macro.
4063         * config/sparc/sparc.c (TARGET_CAN_ELIMINATE): Define macro.
4064         (sparc_can_eliminate): Declare as static.
4065         * config/sparc/sparc-protos.h (sparc_can_eliminate): Remove.
4066
4067         * config/stormy16/stormy16.h (CAN_ELIMINATE): Remove macro.
4068         * config/stormy16/stormy16.c (TARGET_CAN_ELIMINATE): Define macro.
4069         (xstormy16_can_eliminate): New function.
4070
4071         * config/v850/v850.h (CAN_ELIMINATE): Remove macro.
4072         * config/v850/v850.c (TARGET_CAN_ELIMINATE): Define macro.
4073         (v850_can_eliminate): New function.
4074
4075 2009-08-25  Uros Bizjak  <ubizjak@gmail.com>
4076
4077         * config/alpha/alpha.md (*cmpdf_ieee_ext[123]): Remove.
4078         (*cmpdf_internal): Enable for all ALPHA_FPTM levels.
4079         (*movdfcc_ext[1234]): Disable for IEEE mode.
4080
4081 2009-08-25  Eric Botcazou  <ebotcazou@adacore.com>
4082
4083         * gimplify.c (prepare_gimple_addressable): New static function.
4084         (gimplify_modify_expr_to_memcpy): Invoke it on the RHS before marking
4085         it addressable.
4086         (gimplify_addr_expr): Invoke it similarly on the operand instead of
4087         manually fiddling with it.
4088
4089 2009-08-25  Michael Matz  <matz@suse.de>
4090
4091         * expr.h (jumpifnot_1, jumpif_1, do_jump_1): Declare.
4092         * dojump.c (do_jump_by_parts_greater): Take two operands instead of
4093         full expression.
4094         (do_jump_by_parts_equality, do_compare_and_jump): Ditto.
4095         (jumpifnot_1, jumpif_1): New wrappers for do_jump_1.
4096         (do_jump): Split out code for simple binary comparisons into ...
4097         (do_jump_1): ... this, taking the individual operands and code.
4098         Change callers to helper function above accordingly.
4099         * expr.c (expand_expr_real_1): Use jumpifnot_1 for simple binary
4100         comparisons.
4101
4102 2009-08-25  Michael Matz  <matz@suse.de>
4103
4104         * expr.h (struct separate_ops, sepops): New type for passing
4105         around an exploded simple expression.
4106         * optabs.c (expand_widen_pattern_expr, expand_vec_shift_expr):
4107         Use this structure instead of expression tree.
4108         (get_vcond_icode, expand_vec_cond_expr_p): Don't take whole
4109         expression, only its type.
4110         (expand_vec_cond_expr): Take type and individual operands instead
4111         of full expression.
4112         * optabs.h (expand_widen_pattern_expr, expand_vec_cond_expr,
4113         expand_vec_shift_expr): Change prototype accordingly.
4114         * tree-vect-stmts.c (vectorizable_condition): Change call of
4115         expand_vec_cond_expr_p to pass only type.
4116         * expr.c (do_store_flags): Change prototype and implementation
4117         to take an exploded expression.
4118         (expand_expr_real_1): New local ops initialized with details
4119         of the full expression.  Use it instead of full
4120         expression in calls to do_store_flags, expand_vec_cond_expr,
4121         expand_widen_pattern_expr and expand_vec_shift_expr.
4122
4123 2009-08-25  Michael Matz  <matz@suse.de>
4124
4125         * expr.c (expand_expr_real_1): New local treeop0, treeop1,
4126         treeop2 initialized with first three operands of the full expression.
4127         Substitute all TREE_OPERAND (exp, [012]) calls with them.
4128
4129 2009-08-25  Kai Tietz  <kai.tietz@onevision.com>
4130
4131         * gcc/gthr-win32.h (__UNUSED_PARAM): Define, if not already present.
4132         (__gthread_objc_condition_allocate): Mark arguments as unused.
4133         (__gthread_objc_condition_deallocate): Likewise.
4134         (__gthread_objc_condition_wait): Likewise.
4135         (__gthread_objc_condition_broadcast): Likewise.
4136         (__gthread_objc_condition_signal): Likewise.
4137         (__gthread_objc_thread_detach): Cast via INT_PTR to pointer.
4138         (__gthread_objc_thread_id): Likewise.
4139
4140 2009-08-25  Janus Weil  <janus@gcc.gnu.org>
4141
4142         PR middle-end/41149
4143         * tree-pretty-print.c (print_call_name): Print the correct call name
4144         for procedure pointer components.
4145
4146 2009-08-24  Steve Ellcey  <sje@cup.hp.com>
4147
4148         * config/ia64/ia64.c (ia64_promote_function_mode): Call
4149         default_promote_function_mode when not VMS.
4150
4151 2009-08-24  Olivier Hainque  <hainque@adacore.com>
4152
4153         * convert.c (convert_to_integer): Don't assume an input pointer is
4154         POINTER_SIZE wide.  Fetch from the type instead.
4155
4156 2009-08-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4157
4158         * configure.ac (AC_PREREQ): Bump to 2.64.
4159
4160 2009-08-24  Rafael Avila de Espindola  <espindola@google.com>
4161
4162         * gcc.c (standard_exec_prefix_1,standard_exec_prefix_2): Remove.
4163         (process_command): Don't search standard_exec_prefix_1 and
4164         standard_exec_prefix_2.
4165
4166 2009-08-24  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
4167
4168         * config/arm/arm.c (output_return_instruction): Handle for
4169         unified syntax.
4170
4171 2009-08-24  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
4172
4173         * config/arm/arm.c (arm_select_cc_mode): Handle subreg.
4174
4175 2009-08-24  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
4176
4177         * config/arm/vfp.md (*arm_movdi_vfp): Mark as predicable.
4178         (*arm_movdf_vfp): Likewise.
4179
4180 2009-08-24  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
4181
4182         * config/arm/neon.md (vashl<mode>3): Rename from ashl<mode>3.
4183         (vashr<mode>3): Rename from ashr<mode>3.
4184         (vlshr<mode>3): Rename from lshr<mode>3.
4185
4186 2009-08-24  Kai Tietz  <kai.tietz@onevision.com>
4187
4188         PR/40786
4189         * c-format.c (format_wanted_type): Add new member scalar_identity_flag.
4190         (check_format_info_main): Use scalar_identify_flag.
4191         (check_format_types): Check for scalar size identity if
4192         scalar_identify_flag is set.
4193         (printf_length_specs): Extend by new field.
4194         (asm_fprintf_length_specs): Likewise.
4195         (gcc_diag_length_specs): Likewise.
4196         (scanf_length_specs): Likewise.
4197         (strfmon_length_specs): Likewise.
4198         (gcc_gfc_length_specs): Likewise.
4199         * config/i386/msformat-c.c (ms_printf_length_specs): Likewise.
4200         (ms_printf_flag_specs): Likewise.
4201         * c-format.h (format_length_info): Add new member scalar_identity_flag.
4202
4203 2009-08-23  Uros Bizjak  <ubizjak@gmail.com>
4204
4205         PR target/40718
4206         * config/i386/i386.c (*call_pop_1): Disable for sibling calls.
4207         (*call_value_pop_1): Ditto.
4208         (*sibcall_pop_1): New insn pattern.
4209         (*sibcall_value_pop_1): Ditto.
4210
4211 2009-08-23  Alan Modra  <amodra@bigpond.net.au>
4212
4213         PR target/41081
4214         * config/rs6000/rs6000.md (rotlsi3_64, ashlsi3_64, lshrsi3_64,
4215         ashrsi3_64): New.
4216
4217 2009-08-23  Alan Modra  <amodra@bigpond.net.au>
4218
4219         PR target/41081
4220         * fwprop.c (try_fwprop_subst): Allow multiple sets.
4221         (get_reg_use_in): New function.
4222         (forward_propagate_subreg): Propagate through subreg of zero_extend
4223         or sign_extend.
4224
4225 2009-08-22  Kaz Kojima  <kkojima@gcc.gnu.org>
4226
4227         * config/sh/t-sh (TARGET_LIBGCC2_CFLAGS): Define.
4228         * config/sh/t-netbsd (TARGET_LIBGCC2_CFLAGS): Add -mieee.
4229
4230 2009-08-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4231
4232         * configure.ac: Remove --with-datarootdir, --with-docdir,
4233         --with-htmldir switches.  No need to call AC_SUBST for
4234         datarootdir, docdir, htmldir any more.
4235         * configure: Regenerate.
4236         * doc/install.texi (Configuration): Document --datarootdir,
4237         --docdir, --htmldir, --pdfdir; update documentation for
4238         --infodir, --mandir.
4239         (Prerequisites): Bump Autoconf version to 2.64, Automake to 1.11,
4240         M4 to 1.4.6.
4241
4242         * aclocal.m4: Regenerate.
4243         * config.in: Regenerate.
4244         * configure: Regenerate.
4245
4246 2009-08-21  Douglas B Rupp  <rupp@gnat.com>
4247             Olivier Hainque  <hainque@adacore.com>
4248
4249         * config/ia64/ia64.c: Include libfuncs.h.
4250         (TARGET_PROMOTE_FUNCITON_MODE): Define target macro.
4251         (ia64_expand_call): Use reg 25 on VMS.
4252         (ia64_initialize_trampoline): Fix for VMS ABI.
4253         (ia64_function_arg_offset): Always returns 0 when TARGET_ABI_OPEN_VMS.
4254         (ia64_function_arg): Initialize reg 25 on VMS.
4255         Fix OpenVMS ABI issues for varargs.
4256         For OpenVMS, emit the Argument Information register set in the
4257         incoming/sibcall case as well.
4258         (ia64_arg_type): New function.
4259         (ia64_function_arg_advance): Keep track of cum->words.
4260         Fix OpenVMS ABI issues for varargs.
4261         (ia64_function_value): On VMS, promote mode of non-aggregate types.
4262         (ia64_override_options): Set flag_no_common on VMS.
4263         (ia64_init_builtins): Disable FWRITE builtin.
4264         (ia64_asm_output_external): Call DO_CRTL_NAMES.
4265         (ia64_vms_init_libfuncs): Add decc$ routines.
4266         (ia64_vms_valid_pointer_mode): New function.
4267         (ia64_struct_value_rtx): Allways NULL_RTX on VMS.
4268         (ia64_promote_function_mode): New function
4269         * config/ia64/ia64.h (TARGET_ABI_OPEN_VMS): Define as 0 for default.
4270         (LONG_DOUBLE_TYPE_SIZE): Force to 64 on VMS.
4271         (LIBCGC2_LONG_DOUBLE_TYPE_SIZE): Likewise.
4272         (INIT_CUMULATIVE_ARGS): Add atypes for VMS.
4273         (INIT_CUMULATIVE_INCOMING_ARGS): Likewise.
4274         (ASM_OUTPUT_DEF): Use ISDIGIT instead of isdigit.
4275         Suppress trailing '#' if VALUE is numeric.
4276         * config/ia64/vms.h (PROMOTE_FUNCTION_MODE): Remove, code moved to
4277         ia64_promote_function_mode.
4278         (TARGET_VALID_POINTER_MODE): Define.
4279
4280 2009-08-21  Michael Meissner  <meissner@linux.vnet.ibm.com>
4281
4282         PR target/40671
4283         * config/rs6000/rs6000.c (rs6000_override_options): Use
4284         TARGET_64BIT instead of TARGET_POWERPC64 to set the size of pointers.
4285
4286         PR target/41145
4287         * config/rs6000/rs6000.c (rs6000_handle_altivec_attribute): Fix
4288         reporting of vector + decimal/boolean/complex error.
4289
4290 2009-08-21  Jakub Jelinek  <jakub@redhat.com>
4291
4292         * config/rs6000/rs6000.c (rs6000_init_builtins): Fix type of
4293         __vector double TYPE_DECL.
4294
4295 2009-08-21  Richard Earnshaw  <rearnsha@arm.com>
4296
4297         * arm.h (MACHMODE): New define.  Include insn-modes.h if available.
4298         (CUMULATIVE_ARGS): Use MACHMODE for declaration of aapcs_vfp_mode.
4299         * arm.c (aapcs_vfp_is_call_or_return_candidate): Change base_mode
4300         to pointer to enum machine_mode.  Update all callers as needed.
4301
4302 2009-08-21 Uros Bizjak <ubizjak@gmail.com>
4303
4304         * config/alpha/alpha.md (exception_receiver): Emit alternative
4305         GP load sequence if flag_reorder_blocks_and_partition is set.
4306         (*exception_receiver_2): Also enable when
4307         flag_reorder_blocks_and_partition is set.
4308
4309 2009-08-20  Matt Rice  <ratmice@gmail.com>
4310             Diego Novillo  <dnovillo@google.com>
4311
4312         * Makefile.in (PLUGIN_HEADERS): Include incpath.h and
4313         tree-ssa-sccvn.h.
4314
4315 2009-08-20  Richard Guenther  <rguenther@suse.de>
4316
4317         * c-objc-common.h (LANG_HOOKS_DUP_LANG_SPECIFIC_DECL): Do not define.
4318         * c-tree.h (c_dup_lang_specific_decl): Remove.
4319         (struct lang_decl, struct lang_type): Move definitions ...
4320         * c-lang.h: ... here.  New file.
4321         * c-decl.c: Include c-lang.h.
4322         (c_dup_lang_specific_decl): Remove.
4323         * c-typeck.c: Include c-lang.h.
4324         * Makefile.in (c-decl.o): Add c-lang.h dependency.
4325         (c-typeck.o): Likewise.
4326         * c-config-lang.in (gtfiles): Add c-lang.h.
4327         * gengtype.c (get_output_file_with_visibility): Handle c-lang.h
4328         like c-tree.h.
4329
4330 2009-08-20  Uros Bizjak  <ubizjak@gmail.com>
4331
4332         * config/alpha/alpha.c (alpha_end_function): Do not clear
4333         crtl->emit structure and free insn locators if cfun->is_thunk is true,
4334         this is now handled in generic code.
4335
4336 2009-08-20  Andreas Krebbel  <krebbel1@de.ibm.com>
4337
4338         * config/s390/s390.c (Z10_PREDICT_DISTANCE): New macro.
4339         (s390_z10_fix_long_loop_prediction): New function.
4340         (s390_z10_optimize_cmp): INSN walk moved to callee - s390_reorg.
4341         (s390_reorg): Walk over the INSNs and invoke
4342         s390_z10_fix_long_loop_prediction and s390_z10_optimize_cmp.
4343
4344 2009-08-20  Andreas Krebbel  <krebbel1@de.ibm.com>
4345
4346         * config/s390/s390.md ("*brx_stage1_<GPR:mode>", "*brxg_64bit",
4347         "*brx_64bit", "*brx_31bit"): New patterns.
4348         * config/s390/s390.c ('E'): New output modifier.
4349
4350 2009-08-20  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
4351             Richard Earnshaw  <richard.earnshaw@arm.com>
4352
4353         * config/arm/arm.c (arm_emit_movpair): Handle CONST_INT.
4354         * config/arm/arm.md (*arm_movtas_ze): New pattern for movt.
4355
4356 2009-08-19  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
4357
4358         * pa.md (reload_inhi, reload_outhi, reload_inqi, reload_outqi): New
4359         patterns.
4360         * pa.c (emit_move_sequence): Check if address of operand1 is valid
4361         for mode mode of operand0 when doing secondary reload for SAR.
4362
4363 2009-08-19  Jakub Jelinek  <jakub@redhat.com>
4364
4365         PR middle-end/41123
4366         * expr.c (expand_expr_real_1) <normal_inner_ref>: Handle all kinds
4367         of CONCAT, not just bitpos 0 bitsize size of the whole CONCAT.
4368
4369 2009-08-19  Jason Merrill  <jason@redhat.com>
4370
4371         * doc/invoke.texi (C++ Dialect Options): Note change of minimum
4372         supported template depth in C++0x.
4373
4374 2009-08-19  Jakub Jelinek  <jakub@redhat.com>
4375
4376         * config/rs6000/rs6000.c (rs6000_output_mi_thunk): Don't call
4377         free_after_compilation.
4378         * config/score/score7.c (score7_output_mi_thunk): Likewise.
4379         * config/score/score3.c (score3_output_mi_thunk): Likewise.
4380         * config/ia64/ia64.c (ia64_output_mi_thunk): Likewise.
4381         * config/mips/mips.c (mips_output_mi_thunk): Likewise.
4382         * config/sh/sh.c (sh_output_mi_thunk): Likewise.
4383         * config/m68k/m68k.c (m68k_output_mi_thunk): Likewise.
4384         * config/sparc/sparc.c (sparc_output_mi_thunk): Likewise.
4385
4386 2009-08-19  Ian Lance Taylor  <iant@google.com>
4387
4388         * doc/md.texi (Insn Canonicalizations): Correct canonicalization
4389         of (plus (mult (neg B) C) A).
4390
4391 2009-08-18  Michael Matz  <matz@suse.de>
4392
4393         * omp-low.c (optimize_omp_library_calls): Use types_compatible_p
4394         instead of comparing TYPE_MAIN_VARIANT for equality.
4395         * tree-vect-patterns.c (vect_recog_dot_prod_pattern,
4396         vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern): Ditto.
4397         * tree-vect-loop.c (vect_is_simple_reduction): Ditto.
4398         * gimplify.c (goa_lhs_expr_p): Ditto and use
4399         STRIP_USELESS_TYPE_CONVERSION.
4400
4401 2009-08-18  Michael Matz  <matz@suse.de>
4402
4403         * tree-ssa-structalias.c (create_variable_info_for): Also mark
4404         first field in a struct.
4405         (intra_create_variable_infos): Don't deal with flag_argument_noalias.
4406
4407 2009-08-18  Uros Bizjak  <ubizjak@gmail.com>
4408
4409         * config/alpha/alpha.c (alpha_output_mi_thunk_osf): Allocate insn
4410         locators before emit_insn is called.  Remove assert that
4411         cfun->is_thunk.
4412         (alpha_end_function): Clear crtl->emit structure and free insn
4413         locators if cfun->is_thunk is true.
4414
4415 2009-08-18  Jason Merrill  <jason@redhat.com>
4416
4417         * config/elfos.h (ASM_DECLARE_OBJECT_NAME): Use gnu_unique_object
4418         type if available.
4419         * configure.ac: Test for it.
4420         * configure, config.in: Regenerate.
4421         * doc/install.texi: Document --enable-gnu-unique-object.
4422
4423 2009-08-18  Richard Guenther  <rguenther@suse.de>
4424
4425         PR middle-end/41094
4426         * builtins.c (fold_builtin_pow): Fold pow(pow(x,y),z) to
4427         pow(x,y*z) only if x is nonnegative.
4428
4429 2009-08-18  Jakub Jelinek  <jakub@redhat.com>
4430
4431         * bb-reorder.c (fix_up_fall_thru_edges): Only call invert_jump
4432         on jumps.
4433
4434         PR target/40971
4435         * config/rs6000/rs6000.c (rs6000_legitimize_address): For
4436         [DT][FDI]mode ensure the offset isn't 4/8/12 bytes below 0x8000.
4437
4438 2009-08-17  DJ Delorie  <dj@redhat.com>
4439
4440         * config/m32c/m32c.md (UNS_FSETB, UNS_FREIT): New.
4441         * config/m32c/prologue.md (epilogue_freit): New.
4442         (fset_b): New.
4443         * config/m32c/m32c.c (m32c_function_needs_enter): Add prototype.
4444         (bank_switch_p): Likewise.
4445         (fast_interrupt_p): Likewise.
4446         (interrupt_p): Likewise.
4447         (m32c_conditional_register_usage): Round memregs size up.
4448         (need_to_save): We only need to save $a0 when we use ENTER.
4449         (interrupt_p): Check for fast_interrupt too.
4450         (bank_switch_p): New.
4451         (fast_interrupt_p): New.
4452         (m32c_attribute_table): Add bank_switch and fast_interrupt.
4453         (m32c_emit_prolog): Support bank switching and fast interrupts.
4454         * doc/extend.texi (Function Attributes): Add bank_switch and
4455         fast_interrupt.
4456
4457 2009-08-17  Douglas B Rupp  <rupp@gnat.com>
4458
4459         * config/alpha/alpha.c (vms_valid_pointer_mode): New function.
4460         * config/alpha/vms.h (TARGET_VALID_POINTER_MODE): Define.
4461
4462 2009-08-16  Douglas B Rupp  <rupp@gnat.com>
4463
4464         * doc/invoke.texi (Target options): Add new option list for IA-64/VMS.
4465         (menu): Add IA-64/VMS Options.
4466         (IA-64/VMS Options): Likewise.
4467
4468 2009-08-16  Richard Sandiford  <rdsandiford@googlemail.com>
4469
4470         PR target/38599
4471         * config/mips/mips.md (*lwxs): Use :P for pointer values.
4472
4473 2009-08-16  Richard Sandiford  <rdsandiford@googlemail.com>
4474
4475         * config/mips/mips-protos.h (mips_push_asm_switch): New function.
4476         (mips_pop_asm_switch): Likewise.
4477         * config/mips/mips.c (set_noreorder, set_nomacro, set_noat): Replace
4478         with...
4479         (mips_noreorder, mips_nomacro, mips_noat): ...these new variables.
4480         (mips_push_asm_switch_1, mips_pop_asm_switch_1): New functions.
4481         (mips_push_asm_switch, mips_pop_asm_switch): Likewise.
4482         (mips_print_operand_punctuation): Use them.  Check mips_noreorder
4483         instead of set_noreorder.
4484         (mips_output_function_prologue): Use the new functions.
4485         (mips_output_function_epilogue): Likewise.
4486         (mips_need_noat_wrapper_p): New function, split out from...
4487         (mips_final_prescan_insn, mips_final_postscan_insn): ...here.
4488         Use mips_push_asm_switch and mips_pop_asm_switch.
4489         * config/mips/mips.h (FUNCTION_PROFILER): Use mips_push_asm_switch
4490         and mips_pop_asm_switch.
4491         (ASM_OUTPUT_REG_POP): Likewise.
4492         (DBR_OUTPUT_SEQEND): Remove boilerplate comment.
4493         Use mips_pop_asm_switch.
4494         (mips_asm_switch): New structure.
4495         (set_noreorder, set_nomacro): Replace with...
4496         (mips_noreorder, mips_nomacro, mips_noat): ...these new variables.
4497         * config/mips/mips.md (fix_truncdfsi2_macro): Use mips_nomacro
4498         instead of set_nomacro.
4499         (fix_truncsfsi2_macro): Likewise.
4500         (cprestore): Likewise.
4501         (hazard): Use mips_noreorder instead of set_noreorder.
4502         * config/mips/sdemtk.h (FUNCTION_PROFILER): As for mips.h.
4503
4504 2009-08-16  Uros Bizjak  <ubizjak@gmail.com>
4505
4506         * config/alpha/alpha.c (alpha_end_function): Handle NULL_RTX returned
4507         from prev_active_insn.
4508
4509 2009-08-16  Anatoly Sokolov  <aesok@post.ru>
4510
4511         * config/avr/avr.h (AVR_HAVE_8BIT_SP): New macros.
4512         * config/avr/avr.c (avr_override_options): Initialize
4513         avr_current_arch variable.
4514         (avr_cpu_cpp_builtins): Define __AVR_HAVE_8BIT_SP__ or
4515         __AVR_HAVE_16BIT_SP__ according to the device type.
4516         (expand_prologue, output_movhi): Use AVR_HAVE_8BIT_SP instead of
4517         TARGET_TINY_STACK.
4518         (expand_epilogue): Use correct QI mode frame pointer for tiny stack.
4519         Use AVR_HAVE_8BIT_SP instead of TARGET_TINY_STACK.
4520
4521 2009-08-16  Dodji Seketeli  <dodji@redhat.com>
4522
4523         PR debug/37801
4524         * gcc/dwarf2out.c (gen_inlined_subroutine_die): Concentrate on
4525         generating inlined subroutine die only. We shouldn't be
4526         called for anything else.
4527         (gen_block_die): Don't generate inline subroutine debug info for
4528         abstract blocks.
4529
4530 2009-08-15  Sebastian Pop  <sebastian.pop@amd.com>
4531
4532         * graphite-poly.c (print_pbb): Print PBB index.
4533
4534 2009-08-15  Sebastian Pop  <sebastian.pop@amd.com>
4535
4536         PR middle-end/40981
4537         * graphite-interchange.c (ppl_max_for_le): Moved...
4538         * graphite-poly.c (pbb_number_of_iterations): Call ppl_max_for_le.
4539         * graphite-ppl.c (ppl_max_for_le): ... here.  Correct the use of
4540         ppl_Pointset_Powerset_C_Polyhedron_maximize.
4541         * graphite-ppl.h (ppl_max_for_le): Declared.
4542
4543 2009-08-14  Olatunji Ruwase <tjruwase@google.com>
4544
4545         * doc/extend.texi (Symbol-Renaming Pragmas): redefine_extname is
4546         supported on all platforms.
4547         * target.h (struct gcc_target): Remove handle_pragma_redefine_extname.
4548         * c-cppbuiltin.c: Remove use of targetm.handle_pragma_redefine_extname.
4549         * c-pragma.c: Likewise.
4550         * target-def.h (TARGET_INITIALIZER): Remove
4551         TARGET_HANDLE_PRAGMA_REDEFINE_EXTNAME.
4552         * config/sol2.h: Remove use of TARGET_HANDLE_PRAGMA_REDEFINE_EXTNAME.
4553
4554 2009-08-14  Douglas B Rupp  <rupp@gnat.com>
4555
4556         * config/ia64/fde-vms.c: New file.
4557         * config/ia64/fde-glibc.c (_Unwind_FindTableEntry): Add dummy arg.
4558         * config/ia64/unwind-ia64.c (UNW_ accessors): Move to unwind-ia64.h
4559         (MD_UNW_COMPATIBLE_PERSONALITY_P): Provide default.
4560         (uw_frame_state_for): Only register a personality routine if it is
4561         known to be compatible with our expectations.
4562         (_Unwind_FindEnclosingFunction, uw_frame_state_for):
4563         Declare unw_table_entry stack variable and
4564         mod all calls to _Unwind_FindTableEntry to add arg.
4565         * config/ia64/unwind-ia64.h (UNW_ accessors): Move here.
4566         (_Unwind_FindTableEntry): Add arg to prototype.
4567
4568 2009-08-14  Eric Botcazou  <ebotcazou@adacore.com>
4569
4570         * config/ia64/unwind-ia64.c (struct _Unwind_Context): Add new
4571         field 'signal_pfs_loc'.
4572         (uw_frame_state_for): Remove duplicate code dealing with leaf
4573         procedures without unwind info.
4574         If in the frame after unwinding through a signal handler, restore
4575         the AR.PFS register instead of the CFM if AR.PFS has not been saved.
4576         * config/ia64/linux-unwind.h (ia64_fallback_frame_state): Do not set
4577         'pfs_loc' to the AR.PFS location in the signal context; instead
4578         set 'signal_pfs_loc'.
4579         Manually generate the unwind info for the AR.PFS register.
4580         (ABI_MARKER_OLD_LINUX_SIGTRAMP, ABI_MARKER_OLD_LINUX_INTERRUPT,
4581         ABI_MARKER_LINUX_SIGTRAMP, ABI_MARKER_LINUX_INTERRUPT): Define.
4582         (ia64_handle_unwabi): Test 'fs->unwabi' against them.
4583         Do not set 'pfs_loc' to the AR.PFS location in the signal context;
4584         instead set 'signal_pfs_loc'.
4585         Remove code preventing the AR.PFS register from being restored
4586         from the signal context.
4587
4588 2009-08-14  Douglas B Rupp  <rupp@gnat.com>
4589             Tristan Gingold  <gingold@adacore.com>
4590
4591         * config.gcc (ia64-hp-*vms*): Insert ia64/t-ia64 in tmake_file.
4592         * config/ia64/t-vms: New file.
4593         * config/ia64/vms64.h: New file.
4594         * config/ia64/vms.h: New file.
4595         * config/ia64/vms-crtinit.asm: New file.
4596         * config/ia64/vms_symvec_libgcc_s.opt: New file.
4597         * config/ia64/vms-unwind.h: New file.
4598
4599 2009-08-14  Uros Bizjak  <ubizjak@gmail.com>
4600
4601         * config/alpha/alpha.c (alpha_emit_conditional_move): Handle
4602         TFmode compares.
4603
4604 2009-08-14  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
4605
4606         PR middle-end/30789
4607         * builtins.c (do_mpc_arg2): Make extern, define for any MPC version.
4608         Move declaration...
4609         * real.h (do_mpc_arg2): ... here.
4610         * fold-const.c (const_binop): Use MPC for complex MULT_EXPR
4611         and RDIV_EXPR.
4612
4613 2009-08-14  Rafael Avila de Espindola  <espindola@google.com>
4614
4615         * final.c (add_debug_prefix_map): Don't use GC memory for
4616         old_prefix and new_prefix.
4617
4618 2009-08-14  Richard Guenther  <rguenther@suse.de>
4619
4620         * ipa-prop.c (compute_complex_pass_through): If we cannot
4621         compute a non-varying offset for IPA_JF_ANCESTOR punt.
4622
4623 2009-08-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
4624
4625         * c-lex.c (c_lex_with_flags): Increase size of local variable
4626         to avoid memory clobber.
4627
4628 2009-08-14  Paolo Bonzini  <bonzini@gnu.org>
4629
4630         PR target/40934
4631         * config/i386/i386.c (ix86_fp_comparison_strategy):
4632         Only enable/disable sahf at function granularity.
4633
4634 2009-08-14  Hans-Peter Nilsson  <hp@axis.com>
4635
4636         PR rtl-optimization/41064
4637         * reload1.c (reload_as_needed): Don't call extract_insn
4638         for known invalid replacements after calling
4639         validate_replace_rtx_group and verify_changes.
4640
4641 2009-08-14  Uros Bizjak  <ubizjak@gmail.com>
4642
4643         PR target/41019
4644         * config/i386/sse.md (SSEMODE124C8): New mode iterator.
4645         (vcond<SSEMODEF2P:mode>): Assert that operation is supported by
4646         ix86_expand_fp_vcond.
4647         (vcond<SSEMODE124C8:mode>): Use SSEMODE124C8 instead of SSEMODE124.
4648         Assert that operation is supported by ix86_expand_int_vcond.
4649         (vcondu<SSEMODE124C8:mode>): Ditto.
4650
4651 2009-08-13  DJ Delorie  <dj@redhat.com>
4652
4653         * config/i386/djgpp-stdint.h: New.
4654         * config.gcc (djgpp): Use it.
4655
4656 2009-08-13  Kaz Kojima  <kkojima@gcc.gnu.org>
4657
4658         * config/sh/sh.c (sh_override_options): When flag_exceptions or
4659         flag_unwind_tables is on, turn flag_reorder_blocks_and_partition off.
4660
4661 2009-08-13  Ghassan Shobaki  <ghassan.shobaki@amd.com>
4662
4663         * tree-ssa-loop-prefetch.c
4664         (prune_ref_by_group_reuse): Enhance probabilistic analysis
4665         for long-stride pruning.
4666         (compute_miss_rate): New function to compute the probability
4667         that two memory references access different cache lines.
4668
4669 2009-08-13  Dave Korn  <dave.korn.cygwin@gmail.com>
4670
4671         * gcc/config/i386/cygwin.h (LINK_SPEC): Add --enable-auto-image-base.
4672
4673 2009-08-13  Richard Guenther  <rguenther@suse.de>
4674
4675         PR middle-end/41047
4676         * tree-ssa-ccp.c (ccp_fold): When folding pointer additions
4677         use the constant pointer type.
4678         * gimplify.c (canonicalize_addr_expr): Canonicalize independent
4679         of CV qualifiers on the target pointer type.
4680         * tree-ssa.c (useless_type_conversion_p): Move incomplete pointer
4681         conversion check before restrict check.
4682
4683 2009-08-12  Kaz Kojima  <kkojima@gcc.gnu.org>
4684
4685         PR target/41029
4686         * config/sh/sh.md (reload_outdf__RnFRm+4): Fix thinko.
4687
4688 2009-08-12  Kaz Kojima  <kkojima@gcc.gnu.org>
4689
4690         * config/sh/sh.c (sh_promote_function_mode): Add ATTRIBUTE_UNUSED.
4691
4692 2009-08-12  Richard Guenther  <rguenther@suse.de>
4693
4694         PR tree-optimization/41011
4695         * ipa-cp.c (ipcp_lattice_from_jfunc): Deal with failing fold
4696         and reference constructing.
4697
4698 2009-08-12  Xinliang David Li  <davidxl@google.com>
4699
4700         PR tree-optimization/41012
4701         * tree-flow.h : New external interface.
4702         * gimple-low.c (check_call_arg): Change to public function.
4703         Remove argument mismatch check in lowering.
4704         * tree-inline.h (tree_can_inline_p): Interface change.
4705         * tree-inline.c (tree_can_inline_p): Fold argument mismatch check
4706         into this function.
4707         * ipa-inline.c (cgraph_decide_inlining_of_small_functions):
4708         Call change to tree_can_inline_p function.
4709         (cgraph_decide_inlining_incrementally): Ditto.
4710
4711 2009-08-12  Richard Sandiford  <rdsandiford@googlemail.com>
4712
4713         PR tree-optimization/41031
4714         * tree-outof-ssa.c (insert_value_copy_on_edge): Use promote_decl_mode
4715         on the partition variable rather than promote_mode on the source
4716         type.  Assert that the partition variable's type has the same
4717         mode as the source value's.
4718
4719 2009-08-12  Paolo Bonzini  <bonzini@gnu.org>
4720
4721         * doc/tm.texi (TARGET_PROMOTE_FUNCTION_MODE): Add documentation
4722         for for_return == 2.
4723         * function.c (assign_parm_setup_reg): Use for_return == 2, improve
4724         comments.
4725         * calls.c (expand_call): Fix typo.
4726         * explow.c (promote_decl_mode): Use for_return == 2 for RESULT_DECL
4727         and PARM_DECL.
4728         * stmt.c (expand_value_return): Use promote_function_mode to copy out
4729         of pseudo.
4730         * targhooks.c (default_promote_function_mode): Handle for_return == 2.
4731         * config/cris/cris.c (cris_promote_function_mode): Likewise.
4732         * config/mmix/mmix.c (mmix_promote_function_mode): Likewise.
4733         * config/pa/pa.c (pa_promote_function_mode): Likewise.
4734
4735 2009-08-12  Andrew Haley  <aph@redhat.com>
4736
4737         * config/arm/arm.c (arm_init_libfuncs): Add __sync_synchronize.
4738
4739 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4740
4741         PR bootstrap/40103
4742         * graphite.c: Remove pragma GCC diagnostic warning "-Wc++-compat".
4743
4744 2009-08-12  Richard Guenther  <rguenther@suse.de>
4745
4746         * alias.c (get_alias_set): Honor TYPE_STRUCTURAL_EQUALITY_P.
4747         * gimplify.c (gimplify_modify_expr): Do not use
4748         lang_hooks.types_compatible_p.
4749         * tree-ssa.c (useless_type_conversion_p): For aggregates
4750         just return false if the canonical types differ.
4751
4752 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4753
4754         PR middle-end/40980
4755         * sese.c (convert_for_phi_arg): New.
4756         (add_guard_exit_phis): Use convert_for_phi_arg.
4757
4758 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4759
4760         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
4761         unknown subscript upper bounds.
4762
4763 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4764             Pranav Garg  <pranav.garg2107@gmail.com>
4765
4766         * graphite-interchange.c (gather_access_strides): Removed.
4767         (ppl_max_for_le): New.
4768         (build_linearized_memory_access): New.
4769         (memory_stride_in_loop): New.
4770         (pbb_interchange_profitable_p): Reimplemented.
4771         * graphite-ppl.h (ppl_new_id_map): New.
4772         (ppl_interchange): New.
4773
4774 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4775
4776         * graphite-interchange.c (compute_subscript): Removed.
4777         (compute_array_size_cstr): Removed.
4778         (compute_array_size_poly): Removed.
4779         (compute_array_size): Removed.
4780         (gather_access_strides_poly): Removed.
4781         (gather_access_strides): Empty.
4782
4783 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4784
4785         * graphite-dependences.c (dependence_polyhedron_1): Replace
4786         pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
4787         (graphite_legal_transform_dr): Same.
4788         (graphite_carried_dependence_level_k): Same.
4789         * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
4790         Initialize PDR_NB_SUBSCRIPTS.
4791         (print_pdr_access_layout): Replace pdr_nb_subscripts with
4792         PDR_NB_SUBSCRIPTS.
4793         * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
4794         (PDR_NB_SUBSCRIPTS): New.
4795         (pdr_nb_subscripts): Removed.
4796         (pdr_dim): Simplified.
4797         * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
4798         with PDR_NB_SUBSCRIPTS.
4799
4800 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4801
4802         * graphite-interchange.c (compute_array_size): Remove use of
4803         PDR_DATA_CONTAINER.
4804         * graphite-poly.c (new_poly_dr): Remove argument data_container.
4805         Do not initialize PDR_DATA_CONTAINER.
4806         (print_pdr): Do not print PDR_DATA_CONTAINER.
4807         * graphite-poly.h (struct poly_dr): Remove data_container field.
4808         (PDR_DATA_CONTAINER): Removed.
4809         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
4810         PDR_DATA_CONTAINER.
4811         (build_poly_dr): Same.
4812
4813 2009-08-12  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
4814             Sebastian Pop  <sebastian.pop@amd.com>
4815
4816         * graphite-dependences.c (graphite_legal_transform_dr): Work on a
4817         copy of the dependence polyhedron.  Free the temporary objects.
4818         (graphite_carried_dependence_level_k): Free unused objects before
4819         returning.
4820
4821         * testsuite/gcc.dg/graphite/interchange-1.c: XFAILed.
4822         * testsuite/gcc.dg/graphite/interchange-2.c: XFAILed.
4823         * testsuite/gcc.dg/graphite/interchange-3.c: XFAILed.
4824         * testsuite/gcc.dg/graphite/interchange-4.c: XFAILed.
4825         * testsuite/gcc.dg/graphite/interchange-7.c: XFAILed.
4826
4827 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4828
4829         * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
4830         Early return without analyzing the data dependences if no
4831         transform has been done.  Call restore_scattering if the transform
4832         is not legal.
4833         (graphite-interchange.c): Same.
4834         * graphite-poly.c (print_scattering_function): Test for
4835         PBB_TRANSFORMED.
4836         (graphite_read_transforms): Initialize PBB_TRANSFORMED.
4837         (apply_poly_transforms): Do not gcc_assert that
4838         the transform is legal.
4839         (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED and PBB_ORIGINAL.
4840         Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
4841         PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
4842         (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
4843         * graphite-poly.h (struct poly_scattering): New.
4844         (struct poly_bb): Add original, transformed, and saved fields.
4845         Remove transformed_scattering, original_scattering,
4846         nb_local_variables and nb_scattering_transform fields.
4847         (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
4848         (poly_scattering_new): New.
4849         (poly_scattering_free): New.
4850         (poly_scattering_copy): New.
4851         (store_scattering_pbb): New.
4852         (store_scattering): New.
4853         (restore_scattering_pbb): New.
4854         (restore_scattering): New.
4855         * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
4856         Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
4857
4858 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4859
4860         * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
4861         (print_scop): Same.
4862
4863 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4864
4865         * Makefile.in (graphite.o): Depends on PREDICT_H.
4866         * graphite.c: Include predict.h.
4867         (graphite_finalize): Call tree_estimate_probability.
4868         * predict.c (predict_loops): Do not call scev_initialize and
4869         scev_finalize.
4870         (tree_estimate_probability_bb): New.
4871         (tree_estimate_probability): Do not initialize loops: move that
4872         code to the driver.  Call tree_estimate_probability_bb.
4873         (tree_estimate_probability_driver): New.
4874         (pass_profile): Use tree_estimate_probability_driver.
4875         * predict.h (tree_estimate_probability): Declared.
4876
4877 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
4878
4879         * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
4880         * graphite-dependences.c (graphite_legal_transform): Add time to
4881         TV_GRAPHITE_DATA_DEPS.
4882         (dependency_between_pbbs_p): Same.
4883         * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
4884
4885 2009-08-12  Andrey Belevantsev  <abel@ispras.ru>
4886
4887         PR rtl-optimization/41033
4888         * alias.c (nonoverlapping_component_refs_p): Punt when strict
4889         aliasing is disabled.
4890
4891 2009-08-11  Adam Nemet  <anemet@caviumnetworks.com>
4892
4893         * config/mips/predicates.md (qi_mask_operand, hi_mask_operand,
4894         si_mask_operand, and_load_operand, low_bitmask_operand,
4895         and_reg_operand, and_operand): New predicates.
4896         * config/mips/constraints.md (Yb, Yh, Yw, Yz): New constraints.
4897         * config/mips/mips.c (and_operands_ok): New function.
4898         * config/mips/mips-protos.h (and_operands_ok): Declare it.
4899         * config/mips/mips.md (move_type): Add ext_ins and logical.
4900         (type): Handle them.
4901         (and<mode>3): Use and_reg_operand as the second operand's predicate.
4902         (*and<mode>3): Add alternatives for lbu, lhu, lwu, <d>ext and
4903         shift_shift.  Remove commutative constraint modifier.
4904         (*and<mode>3_mips16): Add alternatives for lbu, lhu, lwu and
4905         shift_shift.
4906         (*clear_upper32_dext): Remove define_insn_and_split.
4907         (*clear_upper32): Turn this define_insn_and_split ...
4908         (splitter for ANDing register with 0xffff_ffff): .. into this.
4909
4910 2009-08-11  Adam Nemet  <anemet@caviumnetworks.com>
4911
4912         * combine.c (try_widen_shift_mode): Factor out code to check if an
4913         integer constant is a low-order bitmask from here ...
4914         * rtlanal.c (low_bitmask_len): ... to here.
4915         * rtl.h (low_bitmask_len): Declare.
4916
4917 2009-08-11  Uros Bizjak  <ubizjak@gmail.com>
4918
4919         PR target/8603
4920         * config/alpha/alpha.md (addsi3): Remove expander.
4921         (addsi3): Rename from *addsi3_internal insn pattern.
4922         (subsi3): Remove expander.
4923         (subsi3): Rename from *subsi3_internal insn pattern.
4924
4925 2009-08-11  Douglas B Rupp  <rupp@gnat.com>
4926
4927         * config/alpha/alpha.c (alpha_init_builtins): Nullify FWRITE and
4928         FWRITE_UNLOCKED.
4929
4930 2009-08-11  Vasiliy Fofanov  <fofanov@adacore.com>
4931             Eric Botcazou  <botcazou@adacore.com>
4932             Douglas B Rupp  <rupp@gnat.com>
4933
4934         * config/alpha/alpha.c (alpha_return_in_memory): On VMS, ensure
4935         that records that fit in 64 bits are returned by immediate value,
4936         as required by OpenVMS Calling Standard.
4937         (function_value): Adjust for above modification.
4938         (alpha_va_start) <TARGET_ABI_OPEN_VMS>: Use
4939         virtual_incoming_args_rtx as base object, not next_arg.
4940         * config/alpha/vms.h: (DEFAULT_PCC_STRUCT_RETURN): Define as 0.
4941
4942 2009-08-11  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
4943
4944         * reload.c (find_reloads_subreg_address): Check the original
4945         req_equiv_mem address to detect the case where an address is
4946         not valid in the outer mode.
4947
4948 2009-08-11  Richard Guenther  <rguenther@suse.de>
4949
4950         PR bootstrap/40788
4951         * builtins.c (gimplify_va_arg_expr): Do not call SET_EXPR_LOCATION.
4952
4953 2009-08-10  Douglas B Rupp  <rupp@gnat.com>
4954
4955         * config/alpha/vms.h (OPTIMIZATION_OPTIONS): Remove
4956         (OVERRIDE_OPTIONS): Incorporate removed OPTIMIZATION_OPTIONS.
4957
4958 2009-08-10  Olivier Hainque  <hainqueu@adacore.com>
4959             Douglas B Rupp  <rupp@gnat.com>
4960
4961         * config/alpha/alpha.c (alpha_sa_size): Force procedure type to
4962         PT_STACK when frame_pointer_needed on OpenVMS.
4963         (alpha_pv_save_size, alpha_using_fp): Remove.
4964         (alpha_vms_can_eliminate): New function. Support for CAN_ELIMINATE
4965         with proper processing for PT_NULL.
4966         (alpha_vms_initial_elimination_offset): New function. Support for
4967         INITIAL_ELIMINATION_OFFSET with proper processing for PT_NULL.
4968         (alpha_sa_size): Force procedure type to PT_STACK when
4969         frame_pointer_needed on OpenVMS.
4970         * config/alpha/alpha-protos.h (alpha_pv_save_size): Remove prototype.
4971         (alpha_using_fp): Likewise.
4972         (alpha_vms_can_eliminate): Add prototype.
4973         (alpha_vms_initial_elimination_offset): Likewise.
4974         * config/alpha/vms.h (CAN_ELIMINATE, INITIAL_ELIMINATION_OFFSET):
4975         Call alpha_vms_can_eliminate and alpha_vms_initial_elimination_offset.
4976
4977 2009-08-10  Eric Botcazou  <botcazou@adacore.com>
4978             Douglas B Rupp  <rupp@gnat.com>
4979
4980         * config/alpha/alpha.c (common_object_handler): New function.
4981         (vms_attribute_table): Declare a single attribute "common_object".
4982         (vms_output_aligned_decl_common): New global function.
4983         (SECTION_VMS_OVERLAY): Delete.
4984         (SECTION_VMS_GLOBAL): Likewise.
4985         (SECTION_VMS_INITIALIZE): Likewise.
4986         (vms_asm_named_section): Remove support for above flags.
4987         (vms_section_type_flags): Delete.
4988         (TARGET_SECTION_TYPE_FLAGS): Likewise.
4989         * config/alpha/alpha-protos.h (vms_output_aligned_decl_common): New.
4990         * config/alpha/vms.h (ASM_OUTPUT_ALIGNED_COMMON): Delete.
4991         (ASM_OUTPUT_ALIGNED_DECL_COMMON): New macro.
4992
4993 2009-08-10  SUGIOKA Toshinobu  <sugioka@itonet.co.jp>
4994
4995         PR target/41015
4996         * longlong.h [__sh__] (udiv_qrnnd): Add T register to clobber list.
4997         (sub_ddmmss): Likewise.
4998
4999 2009-08-10  Andreas Tobler  <a.tobler@schweiz.org>
5000
5001         PR bootstrap/41018
5002         * config/rs6000/freebsd.h: Define SVR4_ASM_SPEC. Adjust copyright
5003         year.
5004
5005 2009-08-10  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
5006
5007         PR target/37053
5008         * reload1.c (reload_as_needed): Use cancel_changes to completely
5009         undo a failed replacement attempt.
5010
5011 2009-08-10  Richard Guenther  <rguenther@suse.de>
5012
5013         PR middle-end/41006
5014         * tree-ssa.c (useless_type_conversion_p_1): Fold into ...
5015         (useless_type_conversion_p): ... here.  Require pointer targets
5016         to be compatible.
5017
5018 2009-08-10  Dodji Seketeli  <dodji@redhat.com>
5019
5020         PR c++/40866
5021         * tree-inline.c (copy_statement_list): The resulting copy shouldn't
5022         loose the original type of the statement list.
5023
5024 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
5025
5026         * config/alpha/alpha.c: Include libfuncs.h
5027         (avms_asm_output_extern): New function.
5028         (alpha_init_libfuncs): Init some decc libfuncs.
5029         * config/alpha/alpha-protos.h (avms_asm_output_external): Declare.
5030         * config/alpha/vms.h (ASM_OUTPUT_EXTERNAL): Define.
5031         (DO_CRTL_NAMES): Define.
5032         (LIB_SPEC): Remove.
5033         * config/alpha/vms64.h: (POINTERS_EXTEND_UNSIGNED): Remove undef.
5034         (LONG_TYPE_SIZE): Define.
5035         (TARGET_OS_CPP_BUILTINS): Define with __LONG_POINTERS=1
5036         (SUBTARGET_SWITCHES): Define malloc64 switch.
5037         (TARGET_DEFAULT): Default MASK_MALLOC64 set.
5038         (MASK_RETURN_ADDR): Define.
5039         doc/invoke.texi (mmalloc64): Document switch.
5040
5041 2009-08-09  Olivier Hainque  <hainque@adacore.com>
5042             Douglas B Rupp  <rupp@gnat.com>
5043
5044         * config/alpha/alpha.c (struct machine_function): New flag for VMS,
5045         uses_condition_handler.
5046         (alpha_expand_builtin_establish_vms_condition_handler): New expander.
5047         (alpha_expand_builtin_revert_vms_condition_handler): New expander.
5048         (enum alpha_builtin): New ALPHA_BUILTIN_REVERT_VMS_CONDITION_HANDLER
5049         and ALPHA_BUILTIN_ESTABLISH_VMS_CONDITION_HANDLER values.
5050         (code_for_builtin): New insn codes for the new alpha_builtins.
5051         (alpha_init_builtins): Register the new functions as BUILT_IN_MD.
5052         (alpha_sa_size): Account for uses_condition_handler.
5053         (alpha_expand_prologue): Likewise.
5054         (alpha_start_function): Likewise.
5055         (alpha_expand_epilogue): Likewise.
5056         * config/alpha/alpha-protos.h: Prototype the new alpha.c builtin
5057         establish/revert expanders.
5058         * config/alpha/alpha.h (DWARF_FRAME_REGNUM): Define.
5059         * config/alpha/alpha.md (builtin_establish_vms_condition_handler):
5060         New expander, resorting to the alpha.c associated function.
5061         (builtin_revert_vms_condition_handler): Likewise.
5062         * config/alpha/vms-gcc_shell_handler.c: New file. Implements
5063         __gcc_shell_handler, the static VMS condition handler used as
5064         an indirection wrapper to the current dynamically established
5065         handler.
5066         * config/alpha/vms-unwind.h: Complete rewrite.
5067         * config/alpha/t-vms (LIB2FUNCS_EXTRA): Add vms-gcc_shell_handler.c
5068         * config/alpha/vms.h (MD_UNWIND_SUPPORT):
5069
5070 2009-08-09  Eric Botcazou  <botcazou@adacore.com>
5071             Douglas B Rupp  <rupp@gnat.com>
5072
5073         * config/alpha/alpha.c (alpha_links): Add 'target' field.
5074         (alpha_need_linkage): Handle aliases.  Return function symbol.
5075         (alpha_use_linkage): Rename 'linkage' argument to 'func'.
5076         Use ultimate alias target for the linkage name.
5077         * config/alpha/alpha.md (movmemdi): Use the symbol returned
5078         by alpha_need_linkage for the function symbol.
5079         (setmemdi): Likewise.
5080
5081 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
5082
5083         * config/alpha/alpha.c (TARGET_ASM_UNALIGNED_*_OP): Define if on VMS.
5084         * config/alpha/vms.h (OBJECT_FORMAT_ELF): Define.
5085         (ASM_WEAKEN_LABEL): Define.
5086         (CRT_CALL_STATIC_FUNCTION): Define.
5087         (STARTFILE_SPEC): Add crtbegin.o crtbeginS.o.
5088         (ENDFILE_SPEC): Define.
5089         (INIT_SECTION_ASM_OP): Define.
5090         * config/alpha/vms-dwarf2eh.asm (__EH_FRAME_BEGIN__): Remove.
5091         * config/alpha/t-vms (EXTRA_PARTS): Add crtbegin.o crtbeginS.o
5092         crtend.o crtendS.o.
5093         (MULTILIB_OSDIRNAMES): Define.
5094         (shlib_version): Define.
5095         (SHLIB_EXT): Define.
5096         (SHLIB_OBJS): Define.
5097         (SHLIB_NAME): Define.
5098         (SHLIB_MULTILIB): Define.
5099         (SHLIB_INSTALL): Define.
5100         (SHLIB_SYMVEC): Define.
5101         (SHLIB_SYMVECX2): Define.
5102         (SHLIB_LINK): Define.
5103
5104 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
5105
5106         * config/alpha/alpha.c (alpha_initialize_trampoline):
5107         Initialize VMS trampoline IAW ABI for bounded procedure calls.
5108         (alpha_start_function): Emit transfer address on nested functions
5109         for VMS trampoline call.
5110         * config/alpha/t-vms (LIB2FUNCS_EXTRA): Remove vms_tramp.asm
5111         since no longer used.
5112         * config/alpha/vms-tramp.asm: Remove.
5113         * config/alpha/vms.h (TRAMPOLINE_TEMPLATE): Leave undefined
5114         since now only data initialized at runtime.
5115
5116 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
5117
5118         * config/alpha/vms.h (HANDLE_SYSV_PRAGMA): Define.
5119         (LINK_GCC_C_SEQUENCE_SPEC): Define.
5120         (MD_EXEC_PREFIX): Remove, no longer used.
5121         (MD_STARTFILE_PREFIX): Likewise.
5122         (INCLUDE_DEFAULTS): Likewise.
5123         * config/alpha/t-vms:
5124         (vms-dwarf2.o, vms-dwarf2eh.o): Use GCC_FOR_TARGET to compile.
5125
5126 2009-08-09  Richard Guenther  <rguenther@suse.de>
5127
5128         PR tree-optimization/41016
5129         * tree-ssa-ifcombine.c (get_name_for_bit_test): Fix tuplification bug.
5130         (operand_precision): Remove.
5131         (integral_operand_p): Likewise.
5132         (recognize_single_bit_test): Adjust.
5133
5134 2009-08-09  Richard Sandiford  <rdsandiford@googlemail.com>
5135
5136         * c-common.c (c_fully_fold_internal): Issue a warning if a binary
5137         operation overflows.  Likewise non-cast unary arithmetic.
5138         If one arm of a conditional expression is always taken,
5139         inhibit evaluation warnings for the other arm.  Likewise inhibit
5140         evaluation warnings for the second && or || operand if the first
5141         operand is enough to determine the result.
5142         * c-typeck.c (build_conditional_expr): Apply the same inhibition
5143         rules here.
5144         (build_binary_op): Prevent duplicate evaluation warnings.
5145
5146 2009-08-09  Richard Sandiford  <rdsandiford@googlemail.com>
5147
5148         * tree-out-of-ssa.c (insert_value_copy_on_edge): If the source
5149         and destination have different modes, Use promote_mode to
5150         determine the signedness of the conversion.  Assert that the
5151         promoted source mode matches the destination mode.  Don't pass
5152         the destination and destination mode to expand_expr if the source
5153         mode is different.  Simplify conversion logic.
5154
5155 2009-08-09  Ira Rosen  <irar@il.ibm.com>
5156
5157         PR tree-optimization/41008
5158         * tree-vect-loop.c (vect_is_simple_reduction): Get operands
5159         from condition only in case it's a comparison. Adjust checks.
5160
5161 2009-08-09  Bernd Schmidt  <bernd.schmidt@analog.com>
5162
5163         * tree-dfa.c (renumber_gimple_stmt_uids_in_blocks): New function.
5164         * tree-flow.h (renumber_gimple_stmt_uids_in_blocks): Declare it.
5165         * tree-ssa-loop-ivopts.c (comp_cost): Make COST an integer.
5166         (enum iv_position): Add IP_AFTER_USE and IP_BEFORE_USE.
5167         (dump_cand): Handle them.
5168         (struct iv_cand): New members COST_STEP and AINC_USE.
5169         (stmt_after_increment): Likewise.
5170         (stmt_after_inc_pos): Renamed from stmt_after_ip_original_pos.  All
5171         callers changed.  Use gimple_uid comparison instead of scanning.
5172         (add_candidate_1): When looking for identical candidates, take
5173         AINC_USE into account.  Set it for new candidates.
5174         (force_expr_to_var_cost): Cast target_spill_cost to int.
5175         (get_address_cost): New arguments STMT_AFTER_INC and MAY_AUTOINC.
5176         All callers changed.  Check for availability of autoinc addressing
5177         modes, both in general for a given mode, and in the specific use case.
5178         (get_computation_cost_at): New argument CAN_AUTOINC.  All callers
5179         changed.
5180         (get_computation_cost): Likewise.
5181         (autoinc_possible_for_pair, set_autoinc_for_original_candidates,
5182         add_autoinc_candidates): New static functions.
5183         (add_candidate): Call add_autoinc_candidates for candidates based on
5184         a USE_ADDRESS use.
5185         (find_iv_candidates): Call set_autoinc_for_original_candidates.
5186         (determine_use_iv_cost_address): If we have an autoinc candidate at
5187         the matching use, verify autoinc is possible and subtract the cost
5188         of the candidate's step from the cost.
5189         (determine_iv_cost): Record the cost of the increment in the COST_STEP
5190         member of the candidate.
5191         (tree_ssa_iv_optimize_loop): Swap the calls to determine_iv_costs and
5192         determine_use_iv_costs.  Call renumber_gimple_stmt_uids_in_blocks.
5193
5194 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
5195
5196         * config.build (ia64-hp-*vms*): New target.
5197         (alpha64-dec-*vms*,alpha*-dec-*vms*): Fix for config/vms and unify
5198         with ia64-hp-*vms*.
5199         * config.gcc (ia64-hp-*vms*): New target.
5200         (alpha64-dec-*vms*,alpha*-dec-*vms*): Fix for config/vms and unify
5201         with ia64-hp-*vms*.
5202         * config.host (ia64-hp-*vms*): New target.
5203         (alpha64-dec-*vms*,alpha*-dec-*vms*): Fix for config/vms and unify
5204         with ia64-hp-*vms*.
5205
5206 2009-08-08  Richard Guenther  <rguenther@suse.de>
5207
5208         PR tree-optimization/40991
5209         * tree-ssa-pre.c (eliminate): Delay purging EH edges.
5210
5211 2009-08-08  Richard Sandiford  <rdsandiford@googlemail.com>
5212
5213         * combine.c (gen_lowpart_or_truncate): Exclude CONST_INTs from
5214         mode check.  Do truncations in an integer mode.
5215         (force_to_mode): Handle subregs for all mode types.  Only do
5216         arithmetic simplifications on integer modes.
5217
5218 2009-08-07  Richard Guenther  <rguenther@suse.de>
5219
5220         PR tree-optimization/40999
5221         * tree-ssa-ccp.c (get_symbol_constant_value): Handle CONST_DECLs.
5222         (maybe_fold_reference): Lookup constant initializers.
5223         (fold_gimple_assign): Likewise.
5224
5225 2009-08-07  Richard Guenther  <rguenther@suse.de>
5226
5227         * tree-ssa.c (useless_type_conversion_p_1): Only for types
5228         that require structural equality defer to the langhook.
5229
5230 2009-08-07  Martin Jambor  <mjambor@suse.cz>
5231
5232         * ipa-prop.h (enum jump_func_type): New value IPA_JF_ANCESTOR, changed
5233         comments.
5234         (struct ipa_pass_through_data): New type.
5235         (struct ipa_ancestor_jf_data): New type.
5236         (union jump_func_value): Removed field formal_id, added fields
5237         pass_through and ancestor.
5238         (struct ipa_param_call_note): Changed type of formal_id to int from
5239         unsigned.
5240         * ipa-prop.c (ipa_print_node_jump_functions): Print pass through with
5241         operations jump functions and ancestor jump functions.
5242         (compute_complex_pass_through): New function.
5243         (compute_scalar_jump_functions): Call compute_complex_pass_through,
5244         reflect changes in the jump function strucutre.
5245         (update_jump_functions_after_inlining): Ignore complex pass-through
5246         and ancestor jump functions.
5247         * ipa-cp.c (ipcp_lattice_from_jfunc): Added support for ancestor and
5248         polynomial pass-through with operation jump functions.
5249
5250 2009-08-07  Jakub Jelinek  <jakub@redhat.com>
5251
5252         * dwarf2out.c (output_fde): When doing hot/cold partitioning, use
5253         fde->dw_fde_begin as begin label instead of hot/cold label.
5254         Use LLSDAC label instead of LLSDA for second section lsda.
5255         (dwarf2out_do_cfi_startproc): Add SECOND argument.  Use LLSDAC
5256         label instead of LLSDA if it is true.
5257         (dwarf2out_begin_prologue, dwarf2out_switch_text_section): Adjust
5258         callers.
5259         * except.c (add_call_site, dw2_size_of_call_site_table): Add
5260         SECTION argument.  Use it as index into crtl->eh.call_site_record
5261         array.
5262         (dw2_output_call_site_table): Likewise.  Add CS_FORMAT argument,
5263         use it to determine how to print table entries instead of using
5264         #ifdef HAVE_AS_LEB128.  For SECTION > 0 use hot resp. cold
5265         label instead of normal begin label as base.
5266         (sjlj_assign_call_site_values): Adjust add_call_site caller.
5267         (convert_to_eh_region_ranges): When doing hot/cold partitioning,
5268         ensure no EH range spans between sections and that landing pads
5269         are always in the corresponding section.
5270         (sjlj_size_of_call_site_table, sjlj_output_call_site_table): Adjust
5271         for crtl->eh.call_site_record being an array rather than scalar.
5272         (output_one_function_exception_table): New function, copied
5273         from output_function_exception_table.  Adjust
5274         dw2_size_of_call_site_table, dw2_output_call_site_table
5275         callers.  For SECOND section use *C suffixed labels.
5276         (output_function_exception_table): Call
5277         output_one_function_exception_table and, when doing hot/cold
5278         partitioning, also another time for the second section.
5279         * opts.c: Include except.h.
5280         (decode_options): Allow -freorder-blocks-and-partition with
5281         exceptions, unless SJLJ or TARGET_UNWIND_INFO.
5282         * Makefile.in (opts.o): Depend on $(EXCEPT_H).
5283         * function.h (struct rtl_eh): Change call_site_record from
5284         scalar into array of 2 elements.
5285
5286 2009-08-07  Martin Jambor  <mjambor@suse.cz>
5287
5288         * ipa-prop.c (count_formal_params_1): New function.
5289         (ipa_get_vector_of_formal_parms): New function.
5290         (get_vector_of_formal_parm_types): New function.
5291         (ipa_modify_formal_parameters): New function.
5292         (ipa_modify_call_arguments): New function.
5293         (index_in_adjustments_multiple_times_p): New function.
5294         (ipa_combine_adjustments): New function.
5295         (ipa_dump_param_adjustments): New function.
5296         * ipa-prop.h (struct ipa_parm_adjustment): New type.
5297         (ipa_get_vector_of_formal_parms): Declare.
5298         (ipa_modify_formal_parameters): Declare.
5299         (ipa_modify_call_arguments): Declare.
5300         (ipa_combine_adjustments): Declare.
5301         (ipa_dump_param_adjustments): Declare.
5302         (build_ref_for_offset): Declare.
5303         * Makefile.in (tree-sra.o): Add ipa-prop.h to dependencies.
5304         * tree-sra.c: Include ipa-prop.c.
5305         (build_ref_for_offset): Make public.
5306
5307 2009-08-06  Neil Vachharajani  <nvachhar@gmail.com>
5308
5309         * value-prof.c (init_pid_map): Replace xmalloc with XCNEWVEC.
5310
5311 2009-08-06  Thomas Schwinge  <tschwinge@gnu.org>
5312
5313         * gcc/doc/extend.texi (__builtin_extract_return_address)
5314         (__builtin_frob_return_address): Document.
5315
5316 2009-08-06  Paul Brook  <paul@codesourcery.com>
5317
5318         * config/arm/lib1funcs.asm (ARM_DIV_BODY): Add Thumb-2 implementation.
5319         (udivsi3, aeabi_uidivmod, divsi3, aeabi_idivmod): Only use Thumb-1
5320         implementation on ARMv6-M.
5321
5322 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
5323
5324         * doc/extend.texi (pcs): Document new attribute for ARM.
5325
5326 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
5327
5328         * arm.c (pcs_attribute_args): Comment out unsupported attribute
5329         variants.
5330
5331 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
5332
5333         * arm.c (arm_handle_pcs_attribute): Pass the entire name object to
5334         warning ().
5335
5336 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
5337
5338         * arm.c (arm_handle_pcs_attribute): Use %qE in warning.
5339
5340 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
5341
5342         Merge ARM/hard_vfp_branch to trunk.
5343
5344         2009-08-04  Richard Earnshaw  <rearnsha@arm.com>
5345
5346         * arm.c (libcall_eq): New function.
5347         (libcall_hash): New function.
5348         (add_libcall): New function.
5349         (arm_libcall_uses_aapcs_base): New function.
5350         (arm_libcall_value): Use arm_libcall_uses_aapcs_base to check for
5351         libcalls using the base PCS.
5352         (arm_init_cumulative_args): Likewise.
5353
5354         2009-07-20  Joseph Myers  <joseph@codesourcery.com>
5355
5356         * config/arm/arm.c (arm_libcall_value, arm_init_cumulative_args):
5357         Use base ABI for conversion libfuncs between HFmode and SFmode.
5358
5359         2009-05-12  Joseph Myers  <joseph@codesourcery.com>
5360
5361         * config/arm/arm.c (aapcs_vfp_sub_candidate): Use V2SImode and
5362         V4SImode as representatives of all 64-bit and 128-bit vector
5363         types.  Allow vector types without vector modes.
5364         (aapcs_vfp_is_call_or_return_candidate): Handle vector types
5365         without vector modes like BLKmode.
5366         (aapcs_vfp_allocate): Handle TImode for non-TARGET_NEON like
5367         BLKmode.  Avoid unsupported vector modes or TImode moves for
5368         non-TARGET_NEON.
5369         (aapcs_vfp_allocate_return_reg): Likewise.
5370         (arm_vector_mode_supported_p): Only support V2SImode, V4HImode and
5371         V8QImode if TARGET_NEON || TARGET_IWMMXT.
5372
5373         2009-05-12  Joseph Myers  <joseph@codesourcery.com>
5374
5375         * config/arm/arm.c (arm_handle_pcs_attribute): New.
5376         (arm_get_pcs_model): Pass attribute arguments to
5377         arm_pcs_from_attribute.
5378         (arm_init_cumulative_args): Use base AAPCS for conversions from
5379         floating-point types to DImode.
5380         (arm_attribute_table): Add pcs attribute.
5381         (arm_handle_pcs_attribute): New.
5382         * config/arm/bpabi.h (DECLARE_LIBRARY_RENAMES): When renaming
5383         conversions from floating-point types to DImode, also declare them
5384         to use base AAPCS and declare functions they call to use base
5385         AAPCS and their RTABI names.
5386
5387         2009-05-12  Joseph Myers  <joseph@codesourcery.com>
5388
5389         * doc/invoke.texi (-mfloat-abi=@var{name}): Remove statement about
5390         -mfloat-abi=hard not being supported for VFP.
5391
5392         2009-05-11  Kazu Hirata  <kazu@codesourcery.com>
5393
5394         * config/sparc/sparc.c (sparc_emit_float_lib_cmp): Pass a libcall
5395         SYMBOL_REF to hard_libcall_value.
5396
5397         2009-03-05  Joseph Myers  <joseph@codesourcery.com>
5398             Richard Earnshaw  <rearnsha@arm.com>
5399
5400         * config/arm/arm.c (aapcs_layout_arg): Once a co-processor argument
5401         has been put on the stack, all remaining co-processory arguments for
5402         that co-processor also go on the stack.
5403
5404         2009-03-05  Joseph Myers  <joseph@codesourcery.com>
5405
5406         * config/arm/arm.c (arm_return_in_memory): Handle returning
5407         vectors of suitable size in registers also for AAPCS case.
5408
5409         2009-01-13  Richard Earnshaw <rearnsha@arm.com>
5410
5411         * doc/tm.texi (TARGET_LIBCALL_VALUE): Add missing end statement.
5412
5413         2008-12-09  Richard Earnshaw <rearnsha@arm.com>
5414
5415         ARM Hard-VFP calling convention
5416         * target-def.h (TARGET_LIBCALL_VALUE): New hook.
5417         * target.h (gcc_target): Add libcall_value to table of call hooks.
5418         * targhooks.h (default_libcall_value): Default implementation.
5419         * targhooks.c (default_libcall_value): Likewise.
5420         * doc/tm.texi (TARGET_LIBCALL_VALUE): Document it.
5421         * optabs.c (expand_unop): Use it.
5422         * expr.h (hard_libcall_value): Pass the function RTX through.
5423         * calls.c (emit_library_call_value_1): Update call to
5424         hard_libcall_value.
5425         * explow.c (hard_libcall_value): Use new target hook.
5426         * testsuite/lib/target-supports.exp
5427         (check_effective_target_arm_hard_vfp_ok): New hook.
5428         (check_effective_target_arm_neon_ok): Improve test for neon
5429         availability.
5430         * testsuite/gcc.target/arm/eabi1.c: Only run test in base variant.
5431         * config/arm/arm.c: Include cgraph.h
5432         (TARGET_FUNCTION_VALUE): Override default hook.
5433         (arm_pcs_default): New variable.
5434         (arm_override_options): Don't fault hard calling convention with VFP.
5435         Add support for AAPCS variants.
5436         (arm_function_value): Make static.  Handle AAPCS variants.
5437         (arm_libcall_value): New function.
5438         (arm_apply_result_size): Handle VFP registers in results.
5439         (arm_return_in_memory): Rework all AAPCS variants; handle hard-vfp
5440         conventions.
5441         (pcs_attribute_args): New variable.
5442         (arm_pcs_from_attribute): New function.
5443         (arm_get_pcs_model): New function.
5444         (aapcs_vfp_cum_init): New function.
5445         (aapcs_vfp_sub_candidate): New function.
5446         (aapcs_vfp_is_return_candidate): New function.
5447         (aapcs_vfp_is_call_candidate): New function.
5448         (aapcs_vfp_allocate): New function.
5449         (aapcs_vfp_allocate_return_reg): New function.
5450         (aapcs_vfp_advance): New function.
5451         (aapcs_cp_arg_layout): New variable.
5452         (aapcs_select_call_coproc): New function.
5453         (aapcs_select_return_coproc): New function.
5454         (aapcs_allocate_return_reg): New function.
5455         (aapcs_libcall_value): New function.
5456         (aapcs_layout_arg): New function.
5457         (arm_init_cumulative_args): Initialize AAPCS args data.
5458         (arm_function_arg): Handle AAPCS variants using new interface.
5459         (arm_arg_parital_bytes): Likewise.
5460         (arm_function_arg_advance): New function.
5461         (arm_function_ok_for_sibcall): Ensure that sibling calls agree on
5462         calling conventions.
5463         (arm_setup_incoming_varargs): Handle new AAPCS args data.
5464         * arm.h (NUM_VFP_ARG_REGS): Define.
5465         (LIBCALL_VALUE): Update.
5466         (FUNCTION_VALUE): Delete.
5467         (FUNCTION_VALUE_REGNO_P): Add VFP regs.
5468         (arm_pcs): New enum.
5469         (CUMULATIVE_ARGS): New data to support AAPCS argument marshalling.
5470         (FUNCTION_ARG_ADVANCE): Call arm_function_arg_advance.
5471         (FUNCTION_ARG_REGNO_P): Add VFP regs.
5472         * arm-protos.h (arm_function_arg_advance): Add.
5473         (aapcs_libcall_value): Add.
5474         (arm_function_value): Delete.
5475
5476 2009-08-06  Uros Bizjak  <ubizjak@gmail.com>
5477             H.J. Lu  <hongjiu.lu@intel.com>
5478
5479         PR target/40957
5480         * config/i386/i386.c (standard_sse_mode_p): Remove.
5481         (standard_sse_constant_p): Return 2 for integer mode
5482         vector_all_ones_operand when SSE2 is enabled.
5483         (standard_sse_constant_opcode)<case 2>: Always return [v]pcmpeqd.
5484         (ix86_expand_vector_move): Do not check for negative values from
5485         standard_sse_constant_p.
5486
5487 2009-08-06  Richard Guenther  <rguenther@suse.de>
5488
5489         * tree-ssa.c (useless_type_conversion_p_1): Make function and
5490         array type comparisons frontend independent.
5491         * Makefile.in (tree-ssa.o): Add $(TARGET_H) dependency.
5492         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Always fill
5493         out array reference lower bound and element size operands.
5494         (ao_ref_init_from_vn_reference): Properly compute the offset
5495         for ARRAY_RANGE_REF.
5496         (vn_reference_fold_indirect): Fill out array reference lower
5497         bound and element size operands.
5498         * tree-ssa-pre.c (phi_translate_1): Fail if we have to translate
5499         a non gimple valued reference operand which can happen for
5500         array reference lower bound or element size.
5501         (create_component_ref_by_pieces_1): Properly generate the
5502         element size operand for array references.
5503
5504 2009-08-06  Richard Guenther  <rguenther@suse.de>
5505
5506         PR tree-optimization/40964
5507         * tree.c (iterative_hash_host_wide_int): Export.
5508         * tree.h (iterative_hash_host_wide_int): Declare.
5509         * tree-ssa-structalias.c (heapvar_map): New struct.
5510         (heapvar_map_eq): New function.
5511         (heapvar_map_hash): Likewise.
5512         (heapvar_lookup): Adjust.
5513         (heapvar_insert): Likewise.
5514         (make_constraint_from_heapvar): Allow multiple heap variables
5515         per decl at different offsets.
5516         (init_alias_heapvars): Adjust.
5517
5518 2009-08-04  David Daney  <ddaney@caviumnetworks.com>
5519
5520         * config/mips/mips.h (TARGET_SYNC_AFTER_SC): New macro.
5521         * mips_output_sync_loop (mips_output_sync_loop): Only emit
5522         trailing sync if TARGET_SYNC_AFTER_SC.
5523
5524 2009-08-05  David Daney  <ddaney@caviumnetworks.com>
5525
5526         * gcc/config/mips/sync.md (sync_compare_and_swap<mode>,
5527         compare_and_swap_12, sync_add<mode>, sync_<optab>_12,
5528         sync_old_<optab>_12, sync_new_<optab>_12, sync_nand_12,
5529         sync_old_nand_12, sync_new_nand_12, sync_sub<mode>,
5530         sync_old_add<mode>, sync_old_sub<mode>, sync_new_add<mode>,
5531         sync_new_sub<mode>, sync_<optab><mode>, sync_old_<optab><mode>,
5532         sync_new_<optab><mode>, sync_nand<mode>, sync_old_nand<mode>,
5533         sync_new_nand<mode>, sync_lock_test_and_set<mode>,
5534         test_and_set_12): Rewrite calls to mips_output_sync_loop.
5535         * gcc/config/mips/mips-protos.h (mips_output_sync_loop): Make
5536         the prototype declaration match the definition.
5537         * gcc/config/mips/mips.c (mips_output_sync_loop):  Emit sync
5538         instructions explicitly.  Add barrier_before and operands
5539         parameters.
5540         * gcc/config/mips/mips.h (MIPS_COMPARE_AND_SWAP,
5541         MIPS_COMPARE_AND_SWAP_12, MIPS_SYNC_OP, MIPS_SYNC_OP_12,
5542         MIPS_SYNC_OLD_OP_12, MIPS_SYNC_NEW_OP_12, MIPS_SYNC_OLD_OP,
5543         MIPS_SYNC_NEW_OP, MIPS_SYNC_NAND, MIPS_SYNC_OLD_NAND,
5544         MIPS_SYNC_NEW_NAND, MIPS_SYNC_EXCHANGE,
5545         MIPS_SYNC_EXCHANGE_12): Remove sync instructions.
5546
5547 2009-08-05  Andrew Pinski  <pinskia@gmail.com>
5548
5549         * tree-ssa-alias.c: Fix intervals to use [) syntax.
5550
5551 2009-08-05  Uros Bizjak  <ubizjak@gmail.com>
5552             Mikulas Patocka  <mikulas@artax.karlin.mff.cuni.cz>
5553
5554         PR target/40906
5555         * config/i386/i386.c (ix86_split_long_move): Fix push of multi-part
5556         source operand.
5557
5558 2009-08-05  Jakub Jelinek  <jakub@redhat.com>
5559
5560         PR rtl-optimization/40924
5561         * dse.c (canon_address): Before calling cselib_expand_value_rtx
5562         make sure canon_rtx (mem_address) isn't simpler than
5563         canon_rtx (expanded_mem_address).
5564
5565 2009-08-05  Li Feng  <nemokingdom@gmail.com>
5566
5567         * graphite-sese-to-poly.c (build_pbb_drs): Remove build alias set
5568         for each poly_bb_p.
5569         (build_scop_drs): Build alias set for each SCoP.
5570
5571 2009-08-04  Sandra Loosemore  <sandra@codesourcery.com>
5572
5573         * doc/invoke.texi (MIPS Options): Document new 1004K -march options.
5574         * config/mips/mips.c (mips_cpu_info_table): Add 1004K cores.
5575         * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Add pattern for 1004K.
5576         (MIPS_ARCH_FLOAT_SPEC): Likewise.
5577         (BASE_DRIVER_SELF_SPECS): Likewise.
5578
5579 2009-08-04  Andrew Pinski  <pinskia@gmail.com>
5580
5581         * tree-ssa-alias.c: Fix some comment typos.
5582
5583 2009-08-04  Kaz Kojima  <kkojima@gcc.gnu.org>
5584
5585         * config/sh/linux-atomic.asm (ATOMIC_BOOL_COMPARE_AND_SWAP,
5586         ATOMIC_OP_AND_FETCH, ATOMIC_COMBOP_AND_FETCH): Define.
5587
5588 2009-08-03  Janis Johnson  <janis187@us.ibm.com>
5589
5590         PR c/39902
5591         * simplify-rtx.c (simplify_binary_operation_1): Disable
5592         simplifications for decimal float operations.
5593
5594 2009-08-03  Jakub Jelinek  <jakub@redhat.com>
5595
5596         PR middle-end/40943
5597         * tree-ssa.c (warn_uninitialized_var): Even on LHS warn for
5598         operand of INDIRECT_REF.
5599
5600 2009-08-03  Uros Bizjak  <ubizjak@gmail.com>
5601
5602         * config/alpha/alpha.c (alpha_legitimate_constant_p): Reject CONST
5603         constants referencing TLS symbols.
5604
5605 2009-08-03  SUGIOKA Toshinobu  <sugioka@itonet.co.jp>
5606
5607         * config/sh/linux-atomic.asm (ATOMIC_COMPARE_AND_SWAP): Rename
5608         __sync_compare_and_swap_* to __sync_val_compare_and_swap_*.
5609
5610 2009-08-03  Richard Guenther  <rguenther@suse.de>
5611
5612         * tree.c (make_vector_type): Build a main variant first,
5613         get the canonical one and then build the variant.
5614         * tree-ssa.c (useless_type_conversion_p_1): Handle
5615         fixed-point types.
5616         (useless_type_conversion_p): Conversions to pointers to
5617         incomplete record types are useless.
5618
5619 2009-08-03  Richard Guenther  <rguenther@suse.de>
5620
5621         * tree-cfg.c (pass_warn_unused_result): Mark name that no dump
5622         file will be created.
5623         * omp-low.c (pass_diagnose_omp_blocks): Likewise.
5624         * toplev.c (compile_file): Adjust comment.
5625
5626 2009-08-03  Kaz Kojima  <kkojima@gcc.gnu.org>
5627
5628         * config/sh/sh-protos.h (sh_promote_function_mode): Remove.
5629         * config/sh/sh.c (sh_promote_function_mode): Wrap long lines.
5630         (TARGET_PROMOTE_FUNCTION_MODE): Define.
5631         (TARGET_PROMOTE_FUNCTION_ARGS): Remove.
5632         (sh_promote_function_mode): Fix typo.
5633
5634 2009-08-03  Andreas Krebbel  <krebbel1@de.ibm.com>
5635
5636         * explow.c (promote_mode): Mark TYPE and PUNSIGNEDP as possibly unused.
5637
5638 2009-08-02  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
5639
5640         * pa.c (pa_promote_function_mode): Remove ATTRIBUTE_UNUSED from
5641         declaration arguments.
5642
5643 2009-08-02  Uros Bizjak  <ubizjak@gmail.com>
5644
5645         * config/i386/i386.c (ix86_expand_fp_compare): Use const0_rtx instead
5646         of GEN_INT (0x00) and const1_rtx instead of GEN_INT (0x01).
5647         (ix86_split_ashl): Ditto.
5648         (ix86_expand_vector_init_one_nonzero): Ditto.
5649         (ix86_expand_vector_set): Ditto.
5650         (ix86_expand_reduc_v4sf): Ditto.
5651
5652 2009-08-02  Paolo Bonzini  <bonzini@gnu.org>
5653
5654         * explow.c (promote_function_mode): Remove assert.
5655         * config/sh/sh.c (sh_promote_function_mode): Declare.
5656
5657 2009-08-01  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
5658
5659         * config/pa/pa.c (pa_promote_function_mode): Declare.
5660         Change to static.  Fix promote_mode call.
5661
5662         * gthr-dce.h (CONST_CAST2): Define if not defined.
5663         (__gthread_setspecific): Use CONST_CAST2 to fix warning.
5664
5665         * config.gcc (hppa[12]*-*-hpux10*): Add stdint support.
5666
5667 2009-08-01  Paolo Bonzini  <bonzini@gnu.org>
5668
5669         * expr.c (store_constructor): Use promote_decl_mode.  Remove
5670         now write-only variable unsignedp.
5671         (expand_expr_real_1): Use promote_decl_mode.
5672         * expr.h (promote_function_mode, promote_decl_mode): New.
5673         (promote_mode): Remove last argument.
5674         * function.c (assign_temp): Drop last argument of promote_mode.
5675         (assign_parm_find_data_types): Use promote_function_mode.
5676         (assign_parm_setup_reg): Likewise.
5677         (expand_function_end): Use promote_function_mode.
5678         * calls.c (initialize_argument_information): Use promote_function_mode.
5679         (precompute_arguments): Use promote_mode instead of checking if
5680         only PROMOTE_FUNCTION_MODE is defined.
5681         (expand_call): When making sibcall decisions, use promote_function_mode.
5682         Below, remove an if for targetm.calls.promote_function_return and
5683         and use promote_function_mode.
5684         (emit_library_call_value_1): Use promote_function_mode, fix bug
5685         where promote_mode was passed FOR_CALL == 0 for a return value in an
5686         assertion.
5687         * cfgexpand.c (expand_one_register_var): Use promote_decl_mode.
5688         * explow.c (promote_function_mode, promote_decl_mode): New.
5689         (promote_mode): Keep only the FOR_CALL == 0 case.
5690         * combine.c (setup_incoming_promotion): Remove test of
5691         promote_function_args.  Use promote_function_mode.
5692         * stmt.c (expand_value_return): Use promote_decl_mode.
5693         (expand_decl): Use promote_decl_mode.
5694
5695         * expr.c (store_constructor): Use promote_decl_mode.  Remove
5696         now write-only variable unsignedp.
5697         (expand_expr_real_1): Use promote_decl_mode.
5698         * expr.h (promote_function_mode, promote_decl_mode): New.
5699         (promote_mode): Remove last argument.
5700         * function.c (assign_temp): Drop last argument of promote_mode.
5701         (assign_parm_find_data_types): Use promote_function_mode.
5702         (assign_parm_setup_reg): Likewise.
5703         (expand_function_end): Use promote_function_mode.
5704         * calls.c (initialize_argument_information): Use promote_function_mode.
5705         (precompute_arguments): Use promote_mode instead of checking if
5706         only PROMOTE_FUNCTION_MODE is defined.
5707         (expand_call): When making sibcall decisions, use promote_function_mode.
5708         Below, remove an if for targetm.calls.promote_function_return and
5709         and use promote_function_mode.
5710         (emit_library_call_value_1): Use promote_function_mode, fix bug
5711         where promote_mode was passed FOR_CALL == 0 for a return value in an
5712         assertion.
5713         * cfgexpand.c (expand_one_register_var): Use promote_decl_mode.
5714         * explow.c (promote_function_mode, promote_decl_mode): New.
5715         (promote_mode): Keep only the FOR_CALL == 0 case.
5716         * combine.c (setup_incoming_promotion): Remove test of
5717         promote_function_args.  Use promote_function_mode.
5718         * stmt.c (expand_value_return): Use promote_decl_mode.
5719         (expand_decl): Use promote_decl_mode.
5720
5721         * explow.c (promote_function_mode): Just call the target hook.
5722         * targhooks.c (default_promote_function_mode,
5723         default_promote_function_mode_always_promote): New.
5724         * targhooks.h (default_promote_function_mode,
5725         default_promote_function_mode_always_promote): Declare.
5726         * target.h (promote_function_args, promote_function_return): Remove.
5727         (promote_function_mode): New.
5728         * target-def.h (TARGET_PROMOTE_FUNCTION_ARGS,
5729         TARGET_PROMOTE_FUNCTION_RETURN): Remove.
5730         (TARGET_PROMOTE_FUNCTION_MODE): New.
5731         (TARGET_CALLS): Adjust.
5732         * system.h (TARGET_PROMOTE_FUNCTION_ARGS,
5733         TARGET_PROMOTE_FUNCTION_RETURN, PROMOTE_FUNCTION_MODE): Poison.
5734
5735         * config/s390/s390.h (PROMOTE_FUNCTION_MODE): Move...
5736         * config/s390/s390.c (s390_promote_function_mode): ... here,
5737         with pointer handling.
5738         (TARGET_PROMOTE_FUNCTION_MODE): Define.
5739         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
5740
5741         * config/sparc/sparc.h (PROMOTE_FUNCTION_MODE): Move...
5742         * config/sparc/sparc.c (sparc_promote_function_mode): ... here,
5743         with pointer handling.
5744         (TARGET_PROMOTE_FUNCTION_MODE): Define.
5745         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
5746
5747         * config/sh/sh-protos.h (sh_promote_function_mode): New.
5748         * config/sh/sh.c (sh_promote_function_mode): New.
5749         (TARGET_PROMOTE_FUNCTION_MODE): Define.
5750         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
5751
5752         * config/cris/cris.h (PROMOTE_FUNCTION_MODE): Move...
5753         * config/cris/cris.c (cris_promote_function_mode): ... here.
5754         (TARGET_PROMOTE_FUNCTION_MODE): Define.
5755         (TARGET_PROMOTE_FUNCTION_ARGS): Remove.
5756
5757         * config/mmix/mmix.h (PROMOTE_FUNCTION_MODE): Move...
5758         * config/mmix/mmix.c (mmix_promote_function_mode): ... here.
5759         (TARGET_PROMOTE_FUNCTION_MODE): Define.
5760         (TARGET_PROMOTE_FUNCTION_ARGS): Remove.
5761
5762         * config/arm/arm.h (PROMOTE_FUNCTION_MODE): Move...
5763         * config/arm/arm.c (arm_promote_function_mode): ... here, without
5764         complex type handling.
5765         (TARGET_PROMOTE_FUNCTION_MODE): Define.
5766         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
5767
5768         * config/pa/pa.c (pa_promote_function_mode): New.
5769         (TARGET_PROMOTE_FUNCTION_MODE): Define.
5770         (TARGET_PROMOTE_FUNCTION_RETURN): Remove.
5771
5772         * config/alpha/alpha.c (TARGET_PROMOTE_FUNCTION_ARGS,
5773         TARGET_PROMOTE_FUNCTION_RETURN): Remove.
5774         (TARGET_PROMOTE_FUNCTION_MODE): Define equivalently.
5775         * config/xtensa/xtensa.c: Likewise.
5776         * config/stormy16/stormy16.c: Likewise.
5777         * config/iq2000/iq2000.c: Likewise.
5778         * config/rs6000/rs6000.c: Likewise.
5779         * config/picochip/picochip.c: Likewise.
5780         * config/arc/arc.c: Likewise.
5781         * config/mcore/mcore.c: Likewise.
5782         * config/score/score.c: Likewise.
5783         * config/mips/mips.c: Likewise.
5784         * config/bfin/bfin.c: Likewise.
5785         * config/ia64/ia64.c: Likewise (disabled though).
5786
5787         * config/frv/frv.h: Remove pointless remark.
5788
5789         * doc/tm.texi (PROMOTE_FUNCTION_MODE,
5790         TARGET_PROMOTE_FUNCTION_ARGS,
5791         TARGET_PROMOTE_FUNCTION_RETURN): Consolidate into...
5792         (TARGET_PROMOTE_FUNCTION_MODE): ... this.
5793
5794 2009-08-01  Sebastian Pop  <sebastian.pop@amd.com>
5795
5796         * doc/invoke.texi (-fgraphite-force-parallel): Renamed
5797         -floop-parallelize-all.
5798         * toplev.c (process_options): Rename flag_graphite_force_parallel to
5799         flag_loop_parallelize_all.
5800         * tree-ssa-loop.c (gate_graphite_transforms): Same.
5801         * graphite.c (graphite_transform_loops): Same.
5802         * common.opt: Same.
5803         * graphite-poly.c (apply_poly_transforms): Same.
5804
5805 2009-07-31  Richard Earnshaw  <rearnsha@arm.com>
5806
5807         PR tree-optimization/40914
5808         * ipa-prop.c (ipa_get_ptr_load_param): New argument use_delta,
5809         if set, then check the delta field of the PMF record.
5810         (ipa_get_stmt_member_ptr_load_param): Propagate new param use_delta.
5811         (ipa_analyze_call_uses): Handle machines where the vbit for a PMF
5812         call is stored in the delta.
5813
5814 2009-07-31  Adam Nemet  <anemet@caviumnetworks.com>
5815
5816         * config/mips/mips.md (*clear_upper32_dext): New pattern.
5817
5818 2009-07-31  Uros Bizjak  <ubizjak@gmail.com>
5819
5820         * config/i386/bsd.h (ASM_BYTE): New define.
5821         * config/i386/darwin.h (ASM_BYTE): Rename from ASM_BYTE_OP.
5822         * config/i386/att.h (ASM_BYTE): New define. Use ASM_BYTE instead of
5823         .byte.  Use fputs or putc instead of fprintf where appropriate.
5824         * config/i386/i386-interix.h: Use ASM_BYTE instead of .byte.  Use
5825         fputs or putc instead of fprintf where appropriate.
5826         * config/i386/i386elf.h: Ditto.
5827         * config/i386/sysv4.h: Ditto.
5828
5829         * config/i386/i386.c (TARGET_ASM_BYTE_OP): New define.
5830         * config/i386/i386.md (x86_sahf_1): Use ASM_BYTE instead of .byte.
5831         (*tls_global_dynamic_64): Ditto.
5832
5833 2009-07-31  Christian Bruel  <christian.bruel@st.com>
5834
5835         * gcc/config.gcc (sh*-*-elf): test with_libgloss.
5836
5837 2009-07-31  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
5838
5839         * config/arm/arm.c (arm_arm_address_cost): Fix typo.
5840         Remove dead code for MINUS.
5841
5842 2009-07-31  Anthony Green  <green@moxielogic.com>
5843
5844         * config/moxie/moxie.c (moxie_expand_prologue): Use $r5 instead of
5845         $r12 in prologue.
5846         (moxie_expand_epilogue): Ditto for epilogue.
5847         (moxie_setup_incoming_varargs): ABI change.  Use 5 registers for
5848         incoming arguments.
5849         (moxie_function_arg): Ditto.
5850         (moxie_pass_by_reference): Ditto.
5851         (moxie_arg_partial_bytes): Ditto.
5852         * config/moxie/moxie.h (CALL_USED_REGISTERS): Ditto.
5853         (FUNCTION_ARG_ADVANCE) Ditto.
5854         (REG_PARM_STACK_SPACE) Ditto.
5855         (FUNCTION_ARG_REGNO_P) Dito.
5856
5857         * config.gcc: Add moxie linux config support.
5858         * gcc/config/moxie/uclinux.h: New file.
5859
5860 2009-07-31  DJ Delorie  <dj@redhat.com>
5861
5862         * config/sh/sh.md (UNSPECV_SP_SWITCH_B): New.
5863         (UNSPECV_SP_SWITCH_E): New.
5864         (sp_switch_1): Change to an unspec.
5865         (sp_switch_2): Change to an unspec.  Don't use post-inc when we
5866         replace $r15.
5867         * config/sh/sh.c (sh_expand_prologue): Use the constant pool to
5868         reference the new stack's address
5869
5870 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5871
5872         * Makefile.in (OBJS-common): Added dependence on graphite-blocking.o,
5873         graphite-clast-to-gimple.o, graphite-dependences.o,
5874         graphite-interchange.o, graphite-poly.o, graphite-ppl.o,
5875         graphite-scop-detection.o, graphite-sese-to-poly.o, and sese.o.
5876         (graphite-blocking.o,
5877         graphite-clast-to-gimple.o, graphite-dependences.o,
5878         graphite-interchange.o, graphite-poly.o, graphite-ppl.o,
5879         graphite-scop-detection.o, graphite-sese-to-poly.o, and sese.o): New.
5880         * cfgloop.c (alloc_loop): Set loop->can_be_parallel to false.
5881         * cfgloop.h (struct loop): Add can_be_parallel field.
5882         * common.opt (fgraphite-identity): Moved up.
5883         (fgraphite-force-parallel): New flag.
5884         * graphite.c: Rewrite.
5885         * graphite.h: Rewrite.
5886         * passes.c (init_optimization_passes): Schedule a pass of DCE and LIM
5887         after Graphite.
5888         * toplev.c (graphite_out_file): New file descriptor.
5889         (graphite_in_file): New.
5890         (process_options): flag_graphite_force_parallel cannot be used without
5891         Graphite.
5892         * tree-ssa-loop.c: Include toplev.h.
5893         (gate_graphite_transforms): Enable flag_graphite for
5894         flag_graphite_force_parallel.
5895
5896 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5897
5898         * ChangeLog.graphite: New.
5899         * graphite-blocking.c: New.
5900         * graphite-clast-to-gimple.c: New.
5901         * graphite-clast-to-gimple.h: New.
5902         * graphite-dependences.c: New.
5903         * graphite-dependences.h: New.
5904         * graphite-interchange.c: New.
5905         * graphite-poly.c: New.
5906         * graphite-poly.h: New.
5907         * graphite-ppl.c: New.
5908         * graphite-ppl.h: New.
5909         * graphite-scop-detection.c: New.
5910         * graphite-scop-detection.h: New.
5911         * graphite-sese-to-poly.c: New.
5912         * graphite-sese-to-poly.h: New.
5913         * sese.c: New.
5914         * sese.h: New.
5915
5916 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5917
5918         * tree-chrec.c (evolution_function_right_is_integer_cst): New.
5919         * tree-chrec.h (evolution_function_right_is_integer_cst): Declared.
5920
5921 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5922
5923         * tree-chrec.c (operator_is_linear): Handle BIT_NOT_EXPR.
5924         (scev_is_linear_expression): Return false if the evolution is not
5925         affine multivariate.
5926
5927 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5928
5929         * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
5930         * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
5931
5932 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5933
5934         * tree-data-ref.c (debug_data_references): New.
5935         (debug_data_reference): New.
5936         * tree-data-ref.h (debug_data_references): Declared.
5937         (debug_data_reference): Declared.
5938
5939 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5940
5941         * tree-data-ref.c (stmt_simple_memref_p: Removed.
5942         * tree-data-ref.h (scop_p): Removed.
5943         (struct data_reference): Remove field scop.
5944         (DR_SCOP): Removed.
5945         (stmt_simple_memref_p): Removed.
5946
5947 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5948
5949         * cfgloop.h (create_empty_loop_on_edge): Pass an extra argument.
5950         * cfgloopmanip.c (create_empty_loop_on_edge): Leave the loop_latch
5951         basic block empty.
5952
5953 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5954
5955         * doc/invoke.texi (-fgraphite-force-parallel): Documented.
5956
5957 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5958
5959         * doc/invoke.texi (-fgraphite-identity): Documented.
5960
5961 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5962
5963         * tree-scalar-evolution.c: Fix comment.
5964         (instantiate_scev_1): Return unknow from scev instantiation if the
5965         result is not above instantiate_below.
5966
5967 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
5968
5969         * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
5970         static anymore.  Instantiate the symbols that may have been introduced
5971         by chrec_apply.
5972         * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
5973         Declared.
5974
5975 2009-07-30  DJ Delorie  <dj@redhat.com>
5976
5977         * config/mep/mep.c (mep_asm_init_sections): Add section flags and
5978         .vliw directive to VLIW sections.
5979
5980 2009-07-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5981
5982         * Makefile.in (AUTOCONF, ACLOCAL, ACLOCAL_AMFLAGS, aclocal_deps):
5983         New variables.
5984         ($(srcdir)/configure, $(srcdir)/aclocal.m4): New rules.
5985         (AUTOHEADER): New variable.
5986         ($(srcdir)/cstamp-h.in): Use it.
5987
5988 2009-07-30  Michael Meissner  <meissner@linux.vnet.ibm.com>
5989             Pat Haugen  <pthaugen@us.ibm.com>
5990             Revital Eres <ERES@il.ibm.com>
5991
5992         * config/rs6000/vector.md (VEC_F): Add VSX support.
5993         (VEC_A): Ditto.
5994         (VEC_N): Ditto.
5995         (mov<mode>): Ditto.
5996         (vector_load_<mode>): Ditto.
5997         (vector_store_<mode>): Ditto.
5998         (vector GPR move split): Ditto.
5999         (vec_reload_and_plus_<mptrsize>): Ditto.
6000         (vec_reload_and_reg_<mptrsize>): Ditto.
6001         (add<mode>3): Ditto.
6002         (sub<mode>3): Ditto.
6003         (mul<mode>3): Ditto.
6004         (neg<mode>2): Ditto.
6005         (abs<mode>2): Ditto.
6006         (smin<mode>3): Ditto.
6007         (smax<mode>3): Ditto.
6008         (vector_eq<mode>): Ditto.
6009         (vector_gt<mode>): Ditto.
6010         (vector_ge<mode>): Ditto.
6011         (vector_gtu<mode>): Ditto.
6012         (vector_select_<mode>_uns): Ditto.
6013         (vector_eq_<mode>_p): Ditto.
6014         (vector_gt_<mode>_p): Ditto.
6015         (vector_ge_<mode>_p): Ditto.
6016         (vector_gtu_<mode>_p): Ditto.
6017         (cr6_test_for_zero): Ditto.
6018         (cr6_test_for_zero_reverse): Ditto.
6019         (cr6_test_for_lt): Ditto.
6020         (cr6_test_for_lt_reverse): Ditto.
6021         (xor<mode>3): Ditto.
6022         (ior<mode>3): Ditto.
6023         (and<mode>3): Ditto.
6024         (one_cmpl<mode>2): Ditto.
6025         (nor<mode>2): Ditto.
6026         (andc<mode>2): Ditto.
6027         (float<VEC_int<mode>2): Ditto.
6028         (unsigned_float<VEC_int><mode>2): Ditto.
6029         (fix_trunc<mode><VEC_int>2): Ditto.
6030         (fixuns_trunc<mode><VEC_int>2): Ditto.
6031         (vec_init<mode>):
6032         (vec_set<mode>): Ditto.
6033         (vec_extract<mode>): Ditto.
6034         (vec_interleave_highv4sf): Ditto.
6035         (vec_interleave_lowv4sf): Ditto.
6036         (vec_realign_load_<mode>): Ditto.
6037         (vec_shl_<mode>): Ditto.
6038         (vec_shr_<mode>): Ditto.
6039         (div<mode>3): New patterns for VSX.
6040         (vec_interleave_highv2df): Ditto.
6041         (vec_interleave_lowv2df): Ditto.
6042         (vec_pack_trunc_v2df): Ditto.
6043         (vec_pack_sfix_trunc_v2df): Ditto.
6044         (vec_pack_ufix_trunc_v2df): Ditto.
6045         (vec_unpacks_hi_v4sf): Ditto.
6046         (vec_unpacks_lo_v4sf): Ditto.
6047         (vec_unpacks_float_hi_v4si): Ditto.
6048         (vec_unpacks_float_lo_v4si): Ditto.
6049         (vec_unpacku_float_hi_v4si): Ditto.
6050         (vec_unpacku_float_lo_v4si): Ditto.
6051         (movmisalign<mode>): Ditto.
6052         (vector_ceil<mode>2): New patterns for vectorizing math library.
6053         (vector_floor<mode>2): Ditto.
6054         (vector_btrunc<mode>2): Ditto.
6055         (vector_copysign<mode>3): Ditto.
6056
6057         * config/rs6000/predicates.md (easy_vector_constant_msb): New
6058         predicate for setting the high bit in each word, used for copysign.
6059
6060         * config/rs6000/ppc-asm.h (f19): Whitespace.
6061         (f32-f63): Define if VSX.
6062         (v0-v31): Define if Altivec.
6063         (vs0-vs63): Define if VSX.
6064
6065         * config/rs6000/t-rs6000 (MD_INCLUDES): Add power7.md and vsx.md.
6066
6067         * config/rs6000/power7.md: New file, provide tuning parameters for
6068         -mcpu=power7.
6069
6070         * config/rs6000/rs6000-c.c (rs6000_macro_to_expand): Add VSX support.
6071         (rs6000_cpu_cpp_builtins): Ditto.
6072         (altivec_overloaded_builtins): Ditto.
6073         (altivec_resolve_overloaded_builtin): Ditto.
6074
6075         * config/rs6000/rs6000.opt (-mno-vectorize-builtins): Add new
6076         debug switch to disable vectorizing simple math builtin
6077         functions.
6078
6079         * config/rs6000/rs6000.c (rs6000_builtin_vectorized_function):
6080         Vectorize simple math builtin functions.
6081         (TARGET_VECTORIZE_BUILTIN_VECTORIZED_FUNCTION): Define target
6082         hook to vectorize math builtins.
6083         (rs6000_override_options): Enable -mvsx on -mcpu=power7.
6084         (rs6000_builtin_conversion): Add VSX/power7 support.
6085         (rs6000_builtin_vec_perm): Ditto.
6086         (vsplits_constant): Add support for loading up a vector constant
6087         with just the high bit set in each part.
6088         (rs6000_expand_vector_init): Add VSX/power7 support.
6089         (rs6000_expand_vector_set): Ditto.
6090         (rs6000_expand_vector_extract): Ditto.
6091         (rs6000_emit_move): Ditto.
6092         (bdesc_3arg): Ditto.
6093         (bdesc_2arg): Ditto.
6094         (bdesc_1arg): Ditto.
6095         (rs6000_expand_ternop_builtin): Ditto.
6096         (altivec_expand_builtin): Ditto.
6097         (rs6000_expand_unop_builtin): Ditto.
6098         (rs6000_init_builtins): Ditto.
6099         (altivec_init_builtins): Ditto.
6100         (builtin_function_type): Ditto.
6101         (rs6000_common_init_builtins): Ditto.
6102         (rs6000_handle_altivec_attribute); Ditto.
6103         (rs6000_mangle_type): Ditto.
6104         (rs6000_vector_mode_supported_p): Ditto.
6105         (rs6000_mode_dependent_address): Altivec addresses with AND -16
6106         are mode dependent.
6107
6108         * config/rs6000/vsx.md: New file for VSX support.
6109
6110         * config/rs6000/rs6000.h (EASY_VECTOR_MSB): New macro for
6111         identifing values with just the most significant bit set.
6112         (enum rs6000_builtins): Add builtins for VSX.  Add simple math
6113         vectorized builtins.
6114
6115         * config/rs6000/altivec.md (UNSPEC_VRFIP): Delete.
6116         (UNSPEC_VRFIM): Delete.
6117         (splitter for loading up vector with most significant bit): New
6118         splitter for vectorizing copysign.
6119         (altivec_vrfiz): Rename from altivec_fturncv4sf2.  Add support for
6120         vectorizing simple math functions.
6121         (altivec_vrfip): Add support for vectorizing simple math functions.
6122         (altivec_vrfim): Ditto.
6123         (altivec_copysign_v4sf3): New insn for Altivec copysign support.
6124
6125         * config/rs6000/rs6000.md (UNSPEC_BPERM): New constant.
6126         (power7.md, vsx.md): Include for power7 support.
6127         (copysigndf3): Use VSX instructions if -mvsx.
6128         (negdf2_fpr): Ditto.
6129         (absdf2_fpr): Ditto.
6130         (nabsdf2_fpr): Ditto.
6131         (adddf3_fpr): Ditto.
6132         (subdf3_fpr): Ditto.
6133         (muldf3_fpr): Ditto.
6134         (divdf3_fpr): Ditto.
6135         (fix_truncdfdi2_fpr): Ditto.
6136         (cmpdf_internal1): Ditto.
6137         (fred, fred_fpr): Convert into expander/insn to add VSX support.
6138         (btruncdf2, btruncdf2_fpr): Ditto.
6139         (ceildf2, ceildf2_fpr): Ditto.
6140         (floordf2, floordf2_fpr): Ditto.
6141         (floatdidf2, floatdidf2_fpr): Ditto.
6142         (fmadddf4_fpr): Name insn.  Use VSX instructions if -mvsx.
6143         (fmsubdf4_fpr): Ditto.
6144         (fnmadddf4_fpr_1): Ditto.
6145         (fnmadddf4_fpr_2): Ditto.
6146         (fnmsubdf4_fpr_1): Ditto.
6147         (fnmsubdf4_fpr_2): Ditto.
6148         (fixuns_truncdfdi2): Add expander for VSX support.
6149         (fix_truncdfdi2): Ditto.
6150         (fix_truncdfsi2): Ditto.
6151         (ftruncdf2): Ditto.
6152         (btruncsf2): Whitespace.
6153         (movdf_hardfloat32): Add support for VSX registers.
6154         (movdf_softfloat32): Ditto.
6155         (movdf_hardfloat64): Ditto.
6156         (movdf_hardfloat64_mfpgpr): Ditto.
6157         (movdf_softfloat64): Ditto.
6158         (movti splitters): Add check for vector registers supporting
6159         TImode in the future.
6160         (bpermd): Add power7 bpermd instruction.
6161
6162         * config/rs6000/altivec.h (vec_div): Define if VSX.
6163         (vec_mul): Ditto.
6164         (vec_msub): Ditto.
6165         (vec_nmadd): Ditto.
6166         (vec_nearbyint): Ditto.
6167         (vec_rint): Ditto.
6168         (vec_sqrt): Ditto.
6169         (all predicates): Use the generic builtin function, and not the V4SF
6170         specific function so that the predicates will work with VSX's V2DF.
6171         (vec_all_*): Ditto.
6172         (vec_any_*): Ditto.
6173
6174         * doc/extend.texi (PowerPC Altivec/VSX Built-in Functions):
6175         Document new VSX functions and types.
6176
6177         * doc/invoke.texi (PowerPc options): Document -mpopcntd, -mvsx
6178         switches.
6179
6180         * doc/md.texi (PowerPC constraints): Document "wd", "wf", "ws",
6181         "wa", and "j" constraints.  Modify "v" to talk about Altivec
6182         instead of just vector.
6183
6184 2009-07-30  Andrew MacLeod  <amacleod@redhat.com>
6185
6186         PR debug/26475
6187         * tree-into-ssa.c (insert_phi_nodes_for, rewrite_add_phi_arguments): Set
6188         location for phi arguments.
6189         (rewrite_update_phi_arguments): Find locations for reaching defs.
6190         * tree-ssa-threadupdate.c (create_edge_and_update_destination_phis):
6191         Add location to add_phi_arg calls.
6192         * tree-loop-districbution.c (update_phis_for_loop_copy): Add locations.
6193         * tree-ssa-loop-manip.c (create_iv, add_exit_phis_edge,
6194         split_loop_exit_edge, tree_transform_and_unroll_loop): Add locations.
6195         * tree-tailcall.c (add_successor_phi_arg, eliminate_tail_call,
6196         create_tailcall_accumulator, tree_optimize_tail_calls_1): Add locations.
6197         * tree.h (struct phi_arg_d): Add location_t to PHI arguments.
6198         * tree-phinodes.c (make_phi_node): Initialize location.
6199         (resize_phi_node): Initialize location to UNKNOWN_LOCATION.
6200         (add_phi_arg): Add location parameter.
6201         (remove_phi_arg_num): Move location when moving phi argument.
6202         * omp-low.c (expand_parallel_call, expand_omp_for_static_chunk): Set
6203         location.
6204         * tree-vect-loop-manip.c (slpeel_update_phis_for_duplicate_loop,
6205         slpeel_update_phi_nodes_for_guard1,
6206         slpeel_update_phi_nodes_for_guard2,
6207         slpeel_tree_duplicate_loop_to_edge_cfg, set_prologue_iterations,
6208         vect_loop_versioning): Set locations.
6209         * tree-parloops.c (create_phi_for_local_result,
6210         transform_to_exit_first_loop, create_parallel_loop): Add locations.
6211         * gimple-pretty-print.c (dump_gimple_phi): Dump lineno's if present.
6212         * tree-vect-loop.c (get_initial_def_for_induction,
6213         vect_create_epilog_for_reduction, vect_finalize_reduction): Add
6214         locations.
6215         * tree-flow-inline.h (gimple_phi_arg_location): New.  Return locus.
6216         (gimple_phi_arg_location_from_edge): New.  Return locus from an edge.
6217         (gimple_phi_arg_set_location): New.  Set locus.
6218         (gimple_phi_arg_has_location): New.  Check for locus.
6219         (redirect_edge_var_map_location): New.  Return locus from var_map.
6220         * tree-vect-data-refs.c (vect_setup_realignment): Set location.
6221         * tree-ssa-phiopt.c (conditional_replacement): Set locus when
6222         combining PHI arguments.
6223         (cond_store_replacement): Set location.
6224         * cfgexpand.c (gimple_assign_rhs_to_tree): Transfer locus if possible.
6225         * grpahite.c (add_loop_exit_phis, add_guard_exit_phis,
6226         scop_add_exit_phis_edge): Add locations.
6227         * tree-cfgcleanup.c (remove_forwarder_block,
6228         remove_forwarder_block_with_phi): Add locations.
6229         * tree-ssa-pre.c (insert_into_preds_of_block): Add locations.
6230         * tree-predcom.c (initialize_root_vars, initialize_root_vars_lm): Add
6231         locations.
6232         * tree-ssa-dce.c (forward_edge_to_pdom): Add locations.
6233         * tree-ssa.c (redirect_edge_var_map_add, ssa_redirect_edge,
6234         flush_pending_stmts): Add source location.
6235         * lambda-code.c (perfect_nestify): Maintain location stack with argument
6236         stack to preserve locations.
6237         * tree-vect-stmts.c (vectorizable_load): Add location.
6238         * tree-inline.c (copy_phis_for_bb): Copy locus.
6239         (setup_one_parameter): Add call locus to inlined parameter stmts.
6240         (initialize_inlined_parameters): Pass in call location as parameter
6241         assignment locus.
6242         (tree_function_versioning): Pass location to setup_one_parameter.
6243         * tree-ssa-phiprop.c (phiprop_insert_phi): Set locations.
6244         * tree-outof-ssa.c (struct _elim_graph): Add source_location vecs for
6245         copy and edge lists.
6246         (insert_partition_copy_on_edge, insert_value_copy_on_edge,
6247         insert_rtx_to_part_on_edge, insert_part_to_rtx_on_edge): Provide a
6248         locus parameter and override the stmt default if provided.
6249         (new_elim_graph, clear_elim_graph, delete_elim_graph,
6250         elim_graph_add_edge, elim_graph_remove_succ_edge,
6251         FOR_EACH_ELIM_GRAPH_SUCC, FOR_EACH_ELIM_GRAPH_PRED, eliminate_build,
6252         elim_forward, elim_unvisited_predecessor, elim_backward, elim_create,
6253         eliminate_phi):  Add locus info in elimination graph for each edge and
6254         value copy.
6255         (insert_backedge_copies): Copy locus if present.
6256         * tree-flow.h (struct _edge_var_map): Add locus field.
6257         * tree-switch_conversions.c (fix_phi_nodes): Add locations.
6258         * tree-cfg.c (reinstall_phi_args, gimple_make_forwarder_block,
6259         add_phi_args_after_copy_edge, gimple_lv_adjust_loop_header_phi): Add
6260         locations.
6261         * ipa-struct-reorg.c (make_edge_and_fix_phis_of_dest): Add locations.
6262
6263 2009-07-30  Martin Jambor  <mjambor@suse.cz>
6264
6265         PR tree-optimization/40570
6266         * ipa-inline.c (cgraph_decide_inlining): Watch out for dead single
6267         use inlining loops.
6268
6269 2009-07-30  Razya Ladelsky <razya@il.ibm.com>
6270
6271         * ssa-loop-manip.c: Include langhooks.h.
6272         (rewrite_phi_with_iv): New.
6273         (rewrite_all_phi_nodes_with_iv): New.
6274         (canonicalize_loop_ivs): Move here from tree-parloops.c.
6275         Remove reduction_list argument. Use rewrite_all_phi_nodes_with_iv.
6276         * tree-parloops.c (loop_parallel_p): Move out all conditions
6277         except dependency check.
6278         (canonicalize_loop_ivs): Move to tree-ssa-loop-manip.c.
6279         (gen_parallel_loop): Call canonicalize_loop_ivs without
6280         reduction_list argument.
6281         (build_new_reduction): New.
6282         (gather_scalar_reductions): New.
6283         (try_get_loop_niter): New.
6284         (try_create_reduction_list): New.
6285         (parallleize_loops): Change the parallel conditions check.
6286         * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
6287         * Makefile.in (tree-ssa-loop-manip.o): Add langhooks.h dependency.
6288
6289 2009-07-30  Dave Korn  <dave.korn.cygwin@gmail.com>
6290
6291         * opt-functions.awk (opt_args): Allow argument to be enclosed in
6292         curly braces.
6293         * doc/options.texi (Option properties):  Mention new quoting syntax.
6294
6295 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
6296
6297         * config/alpha/alpha.c (alpha_start_function):
6298         Handle VMS_DEBUG_MAIN_POINTER
6299         * config/alpha/vms.h (VMS_DEBUG_MAIN_POINTER): Define new macro.
6300         * doc/invoke.texi: Document -mdebug-main switch.
6301
6302 2009-07-29  Richard Henderson  <rth@redhat.com>
6303
6304         * cgraph.c (cgraph_set_call_stmt_including_clones): Tidy.
6305         (cgraph_create_edge_including_clones): Likewise.
6306         * tree-inline.c (copy_bb): Operate on the correct edges
6307         when updating the callgraph.
6308
6309 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
6310
6311         * config/alpha/vms-cc.c: Deleted.
6312         * config/alpha/vms-ld.c: Deleted.
6313         * config/alpha/t-vms64: Moved to config/vms
6314         * config/alpha/vms-crt0-64.c: Moved to config/vms
6315         * config/alpha/vms-crt0.c: Moved to config/vms
6316         * config/alpha/vms-psxcrt0-64.c: Moved to config/vms
6317         * config/alpha/vms-psxcrt0.c: Moved to config/vms
6318         * config/alpha/xm-vms.h: Moved to config/vms
6319         * config/alpha/x-vms: Moved to config/vms
6320         * config/alpha/t-vms (vcrt0.o, pcrt0.o): Move rules to new file
6321         config/vms/t-vms.
6322         * config/vms/t-vms: Moved here from config/alpha. Alpha specific
6323         parts removed. (STMP_FIXPROTO, STMP_FIXINC, LIMITS_H_TEST): Set.
6324         (version): Set.
6325         * config/vms/t-vms64: Moved here from config/alpha
6326         * config/vms/vms-crt0-64.c: Moved here from config/alpha.
6327         (argc,argv,envp): Enforce 32bit malloc'ing.
6328         * config/vms/vms-psxcrt0-64.c: Likewise.
6329         * config/vms/vms-crt0.c: Moved here from config/alpha.
6330         * config/vms/vms-psxcrt0.c: Likewise.
6331         * config/vms/vms-crtl-64.h: New file.
6332         * config/vms/vms-crtl.h: New file.
6333         * config/vms/vms.opt: New file.
6334         * config/vms/xm-vms64.h: New file.
6335         * config/vms/xm-vms.h: Moved here from config/alpha.
6336         (STANARD_EXEC_PREFIX, STANDARD_STARTFILE_PREFIX, STANDARD_INCLUDE_DIR):
6337         Set.
6338         * config/vms/x-vms: Moved here from config/alpha.
6339         (version, VMS_EXTRA_PARTS): Moved to t-vms.
6340         (vms-ld.o, vms-cc.o): Removed.
6341         (LN, LN_S, USE_COLLECT2, POD2MAN): Set.
6342
6343 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
6344
6345         * dwarf2out.c (add_name_and_src_coords_attributes): Push on the
6346         correct stack (obvious VMS fix).
6347
6348 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
6349
6350         * dwarf2out.c (output_file_names): Output VMS style file name, size,
6351         date, version info if VMS_DEBUGGING_INFO defined.
6352         * vmsdgbout.c (vms_file_stats_name): New functon. VMS style file name,
6353         size, date calculating code moved here.
6354
6355 2009-07-29  Paul Brook  <paul@codesourcery.com>
6356
6357         * config/arm/lib1funcs.asm (clear_cache): Use ARM_FUNC_START and
6358         do_push/do_pop.
6359
6360 2009-07-29  Uros Bizjak  <ubizjak@gmail.com>
6361
6362         PR target/40577
6363         * config/alpha/alpha.c (alpha_expand_unaligned_store): Convert src
6364         to DImode when generating insq_le insn.
6365
6366 2009-07-28  Douglas B Rupp  <rupp@gnat.com>
6367
6368         * dwarf2out.c (DWARF2_INDIRECT_STRING_SUPPORT_MISSING_ON_TARGET):
6369         New macro set for VMS_DEBUGGGING_INFO.
6370         (AT_string_form): Use it.
6371
6372 2009-07-28  DJ Delorie  <dj@redhat.com>
6373
6374         * config/mep/mep.c (vtext_section): New.
6375         (vftext_section): New.
6376         (ftext_section): New.
6377         (mep_select_section): Add support for functions.
6378         (mep_unique_section): Likewise.
6379         (mep_asm_init_sections): Likewise.
6380         (mep_encode_section_info): Remove it from here.
6381
6382         * config/mep/mep.h (USE_SELECT_SECTION_FOR_FUNCTIONS): Define.
6383
6384 2009-07-28  Paolo Bonzini  <bonzinI@gnu.org>
6385
6386         * tree.h (TREE_DEPRECATED): Document it is used for types too.
6387         (TYPE_VECTOR_OPAQUE): Use default_def_flag
6388
6389 2009-07-28  Douglas B Rupp  <rupp@gnat.com>
6390
6391         * dwarf2out.c (output_file_names): Test new macro
6392         DWARF2_DIR_SHOULD_END_WITH_SEPARATOR.
6393         (add_comp_dir_attribute): Likewise.
6394
6395 2009-07-28  Kai Tietz  <kai.tietz@onevision.com>
6396
6397         * config/i386/mingw-w64.h (LINK_SPEC): Add
6398         separating space between commands.
6399
6400 2009-07-28  Jan Hubicka  <jh@suse.cz>
6401
6402         PR tree-optimization/40759
6403         * tree-ssa-dce.c (mark_virtual_phi_result_for_renaming): Mark all uses
6404         for renaming.
6405
6406 2009-07-27  DJ Delorie  <dj@redhat.com>
6407
6408         * config/mep/mep.c (mep_expand_builtin_saveregs): Make sure 64-bit
6409         types are dword-aligned.
6410         (mep_expand_va_start): Likewise.
6411
6412 2009-07-27  Olivier Hainque  <hainque@adacore.com>
6413             Douglas B Rupp  <rupp@gnat.com>
6414
6415         * convert.c (convert_to_pointer): Don't assume the target
6416         pointer type is POINTER_SIZE long. Fetch its precision instead.
6417
6418 2009-07-27  Douglas B Rupp  <rupp@gnat.com>
6419
6420         * system.h (fopen): Undefine if macro.
6421
6422 2009-07-27  Jakub Jelinek  <jakub@redhat.com>
6423
6424         * dwarf2out.c (output_cfi_p): Removed.
6425         (output_cfis): New function.
6426         (output_fde): New function, split from output_call_frame_info.
6427         (output_call_frame_info): Use it.
6428         (dwarf2out_switch_text_section): Use output_cfis.
6429
6430 2009-07-24  Kai Tietz  <kai.tietz@onevision.com>
6431
6432         * config/i386/cygming.h (DWARF2_UNWIND_INFO): Error build when
6433         TARGET_BI_ARCH is specified without enabling SJLJ.
6434         * config/i386/mingw32.h (MD_UNWIND_SUPPORT): Define MD_UNWIND_SUPPORT,
6435         if TARGET_64BIT and TARGET_BI_ARCH aren't defined.
6436
6437 2009-07-26  Mikael Pettersson <mikpe@it.uu.se>
6438
6439         * arm.md (negdi2): Use DImode if forcing a value into a register.
6440
6441 2009-07-26  Ira Rosen  <irar@il.ibm.com>
6442
6443         PR tree-optimization/40801
6444         * tree-vect-stmts.c (vectorizable_call): Get previous copy
6445         of vector operand from the previous copy of vector statement.
6446         Pass the correct definition type value to
6447         vect_get_vec_def_for_stmt_copy().
6448
6449 2009-07-25  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
6450
6451         * collect2.c (scan_libraries): Use CONST_CAST2 to perform char ** to
6452         const char ** conversion.
6453
6454 2009-07-25 David Daney <ddaney@caviumnetworks.com>
6455
6456         * system.h (gcc_assert): Invoke __builtin_unreachable() instead of
6457         fancy_abort() if !ENABLE_ASSERT_CHECKING.
6458         (gcc_unreachable): Invoke __builtin_unreachable() if
6459         !ENABLE_ASSERT_CHECKING.
6460
6461 2009-07-25  David Daney  <ddaney@caviumnetworks.com>
6462
6463         PR rtl-optimization/40445
6464         * emit-rtl.c (next_nonnote_insn_bb): New function.
6465         * rtl.h (next_nonnote_insn_bb): Declare new function.
6466         * cfgcleanup.c (try_optimize_cfg): Don't remove an empty block
6467         with no successors that is the successor of the ENTRY_BLOCK.
6468         Continue from the top after removing an empty fallthrough block.
6469         * cfgrtl.c (get_last_bb_insn): Call next_nonnote_insn_bb instead
6470         of next_nonnote_insn.
6471
6472 2009-07-25  David Daney  <ddaney@caviumnetworks.com>
6473
6474         * cfgcleanup.c (old_insns_match_p): Handle the case of empty blocks.
6475
6476 2009-07-25  Martin Jambor  <mjambor@suse.cz>
6477
6478         * c-common.c (c_common_attribute_table): New element for noclone.
6479         (handle_noclone_attribute): New function. Forward-declare.
6480         * tree-inline.c (tree_versionable_function_p): Check for noclone
6481         attribute.
6482         * doc/extend.texi (Labels as Values): Document need for noclone.
6483         (Function Attributes): Document noclone attribute.
6484
6485 2009-07-25  Jakub Jelinek  <jakub@redhat.com>
6486
6487         PR rtl-optimization/34999
6488         * dwarf2out.c (struct dw_fde_struct): Add dw_fde_switch_cfi
6489         and dw_fde_switched_cold_to_hot fields.
6490         (output_cfi_p): New function.
6491         (output_call_frame_info): If fde->dw_fde_switched_sections,
6492         output 2 FDEs instead of one with corrupted header.
6493         (dwarf2out_do_cfi_startproc): New function.
6494         (dwarf2out_begin_prologue): Use it.  Initialize fde->dw_fde_switch_cfi
6495         and fde->dw_fde_switched_cold_to_hot.
6496         (dwarf2out_switch_text_section): Compute
6497         fde->dw_fde_switched_cold_to_hot.  Switch to new text section here.
6498         If dwarf2out_do_cfi_asm, emit .cfi_endproc before it and call
6499         dwarf2out_do_cfi_startproc plus emit again currently active CFI insns.
6500         Otherwise, compute fde->dw_fde_switch_cfi.
6501
6502 2009-07-24  Cary Coutant  <ccoutant@google.com>
6503
6504         * tree-cfg.c (assign_discriminator): Add explicit parentheses.
6505
6506 2009-07-24  Cary Coutant  <ccoutant@google.com>
6507
6508         * cfghooks.c (split_block): Copy discriminator to new block.
6509         * tree-cfg.c (assign_discriminator): Check location of last
6510         instruction in block as well as first.
6511
6512 2009-07-24  Uros Bizjak  <ubizjak@gmail.com>
6513
6514         * config/i386/linux.c: Use fputs or putc instead of fprintf
6515         where appropriate.
6516         * config/i386/gas.h: Ditto.
6517         * config/i386/x86-64.h: Ditto.
6518         * config/i386/att.h: Ditto.
6519
6520 2009-07-24  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
6521
6522         * expmed.c (emit_store_flag): Use a recursive call to optimize the
6523         xor case.
6524
6525 2009-07-24  Martin Jambor  <mjambor@suse.cz>
6526
6527         * ipa-prop.h (struct ipa_node_params): New flag node_enqued.
6528         (ipa_push_func_to_list_1): Declare.
6529         (ipa_push_func_to_list): New function.
6530
6531         * ipa-prop.c (ipa_push_func_to_list_1): New function.
6532         (ipa_init_func_list): Call ipa_push_func_to_list_1.
6533         (ipa_push_func_to_list): Removed.
6534         (ipa_pop_func_from_list): Clear node_enqueued flag.
6535
6536 2009-07-24  Andreas Krebbel  <krebbel1@de.ibm.com>
6537
6538         * config/s390/s390.c (override_options): Default
6539         max-unrolled-insns to 100 for z10 tuning.
6540
6541 2009-07-24  Tobias Grosser  <grosser@fim.uni-passau.de>
6542
6543         * Makefile.in (TREE_DATA_REF_H, tree-vrp.o, tree-cfg.o, tree-if-conv.o
6544         tree-ssa-loop.o, tree-ssa-loop-niter.o, tree-ssa-loop-ivcanon.o,
6545         tree-ssa-loop-prefetch.o, tree-predcom.o, tree-affine.o,
6546         tree-scalar-evolution.o, tree-data-ref.o, tree-vect-loop.o,
6547         tree-vect-data-refs.o, tree-loop-linear.o, tree-loop-distribution.o
6548         tree-parloops.o, tree-pretty-printer.o, fold-const.o, tree-ssa-dce.o,
6549         lambda-code.o, params.o): Cleanup use of SCEV_H and TREE_DATA_REF_H.
6550
6551 2009-07-24  Kai Tietz  <kai.tietz@onevision.com>
6552
6553         * config/i386/mingw-w64.h (STANDARD_INCLUDE_DIR): Remove and
6554         use default set in mingw32.h header.
6555         * config/i386/mingw32.h (STANDARD_INCLUDE_DIR): Use for 32-bit and
6556         64-bit /mingw/include path.
6557         (STANDARD_STARTFILE_PREFIX_1): Use for 32-bit and 64-bit /mingw/lib
6558         path.
6559
6560 2009-07-23  Neil Vachharajani  <nvachhar@google.com>
6561
6562         PR rtl-optimization/40209
6563         * loop-iv.c (iv_analysis_loop_init): Call df_note_add_problem.
6564
6565 2009-07-23  Uros Bizjak  <ubizjak@gmail.com>
6566
6567         * config/i386/i386.c: Use ASM_LONG instead of .long.  Concatenate
6568         ASM_LONG, LPREFIX, MCOUNT_NAME and PROFILE_COUNT_REGISTER strings
6569         with the rest of string where appropriate.  Use fputs or putc
6570         instead of fprintf where appropriate.
6571
6572 2009-07-22  Michael Meissner  <meissner@linux.vnet.ibm.com>
6573             Pat Haugen  <pthaugen@us.ibm.com>
6574             Revital Eres <ERES@il.ibm.com>
6575
6576         * config/rs6000/vector.md: New file.  Move most of the vector
6577         expander support here from altivec.md to allow for the VSX vector
6578         unit in the future.  Add support for secondary_reload patterns.
6579         Rewrite the patterns for vector comparison, and vector comparison
6580         predicate instructions so that the RTL expresses the desired
6581         behavior, instead of using unspec.
6582
6583         * config/rs6000/constraints.md ("f" constraint): Use
6584         rs6000_constraints to hold the precalculated register class.
6585         ("d" constraint): Ditto.
6586         ("wd" constraint): New constraint for VSX.
6587         ("wf" constraint): Ditto.
6588         ("ws" constraint): Ditto.
6589         ("wa" constraint): Ditto.
6590         ("wZ" constraint): Ditto.
6591         ("j" constraint): Ditto.
6592
6593         * config/rs6000/predicates.md (vsx_register_operand): New
6594         predicate for VSX.
6595         (vfloat_operand): New predicate for vector.md.
6596         (vint_operand): Ditto.
6597         (vlogical_operand): Ditto.
6598         (easy_fp_constant): If VSX, 0.0 is an easy constant.
6599         (easy_vector_constant): Add VSX support.
6600         (altivec_indexed_or_indirect_operand): New predicate for
6601         recognizing Altivec style memory references with AND -16.
6602
6603         * config/rs6000/rs6000.c (rs6000_vector_reload): New static global
6604         for vector secondary reload support.
6605         (rs6000_vector_reg_class): Delete, replacing it with
6606         rs6000_constraints.
6607         (rs6000_vsx_reg_class): Ditto.
6608         (rs6000_constraints): New array to hold the register classes of
6609         each of the register constraints that can vary at runtime.
6610         (builtin_mode_to_type): New static array for builtin function type
6611         creation.
6612         (builtin_hash_table): New static hash table for builtin function
6613         type creation.
6614         (TARGET_SECONDARY_RELOAD): Define target hook.
6615         (TARGET_IRA_COVER_CLASSES): Ditto.
6616         (rs6000_hard_regno_nregs_internal): If -mvsx, floating point
6617         registers are 128 bits if VSX memory reference instructions are used.
6618         (rs6000_hard_regno_mode_ok): For VSX, only check if the VSX memory
6619         unit is being used.
6620         (rs6000_debug_vector_unit): Move into rs6000_debug_reg_global.
6621         (rs6000_debug_reg_global): Move -mdebug=reg statements here.
6622         Print several of the scheduling related parameters.
6623         (rs6000_init_hard_regno_mode_ok): Switch to putting constraints in
6624         rs6000_constraints instead of rs6000_vector_reg_class.  Move
6625         -mdebug=reg code to rs6000_debug_reg_global.  Add support for
6626         -mvsx-align-128 debug switch.  Drop testing float_p if VSX or
6627         Altivec.  Add VSX support.  Setup for secondary reload support on
6628         Altivec/VSX registers.
6629         (rs6000_override_options): Make power7 set the scheduling groups
6630         like the power5.  Add support for new debug switches to override
6631         the scheduling defaults.  Temporarily disable -mcpu=power7 from
6632         setting -mvsx.  Add support for debug switches -malways-hint,
6633         -msched-groups, and -malign-branch-targets.
6634         (rs6000_buitlin_conversion): Add support for returning unsigned
6635         vector conversion functions to fix regressions due to stricter
6636         type checking.
6637         (rs6000_builtin_mul_widen_even): Ditto.
6638         (rs6000_builtin_mul_widen_odd): Ditto.
6639         (rs6000_builtin_vec_perm): Ditto.
6640         (rs6000_vec_const_move): On VSX, use xxlxor to clear register.
6641         (rs6000_expand_vector_init): Initial VSX support for using xxlxor
6642         to zero a register.
6643         (rs6000_emit_move): Fixup invalid const symbol_ref+reg that is
6644         generated upstream.
6645         (bdesc_3arg): Add builtins for unsigned types.  Add builtins for
6646         VSX types for bit operations.  Changes to accomidate vector.md.
6647         (bdesc_2arg): Ditto.
6648         (bdesc_1arg): Ditto.
6649         (struct builtin_description_predicates): Rewrite predicate
6650         handling so that RTL describes the operation, instead of passing
6651         the instruction to be used as a string argument.
6652         (bdesc_altivec_preds): Ditto.
6653         (altivec_expand_predicate_builtin): Ditto.
6654         (altivec_expand_builtin): Ditto.
6655         (rs6000_expand_ternop_builtin): Use a switch instead of an if
6656         statement for vsldoi support.
6657         (altivec_expand_ld_builtin): Change to use new names from vector.md.
6658         (altivec_expand_st_builtin): Ditto.
6659         (paired_expand_builtin): Whitespace changes.
6660         (rs6000_init_builtins): Add V2DF/V2DI types.  Initialize the
6661         builtin_mode_to_type table for secondary reload.  Call
6662         builtin_function_type to build random builtin functions.
6663         (altivec_init_builtins): Change to use builtin_function_type to
6664         create builtin function types dynamically as we need them.
6665         (builtin_hash_function): New support for hashing the tree types
6666         for builtin function as we need it, rather than trying to build
6667         all of the trees that we need.  Add initial preliminary VSX support.
6668         (builtin_function_type): Ditto.
6669         (builtin_function_eq): Ditto.
6670         (builtin_hash_struct): Ditto.
6671         (rs6000_init_builtins): Ditto.
6672         (rs6000_common_init_builtins): Ditto.
6673         (altivec_init_builtins): Ditto.
6674         (rs6000_common_init_builtins): Ditto.
6675         (enum reload_reg_type): New enum for simplifing reg classes.
6676         (rs6000_reload_register_type): Simplify register classes into GPR,
6677         Vector, and other registers.  Altivec and VSX addresses in reload.
6678         (rs6000_secondary_reload_inner): Ditto.
6679         (rs6000_ira_cover_classes): New target hook, that returns the
6680         appropriate cover classes, based on -mvsx being used or not.
6681         (rs6000_secondary_reload_class): Add VSX support.
6682         (get_vec_cmp_insn): Delete, rewrite vector conditionals.
6683         (get_vsel_insn): Ditto.
6684         (rs6000_emit_vector_compare): Rewrite vector conditional support
6685         so that where we can, we use RTL operators, instead of blindly use
6686         UNSPEC.
6687         (rs6000_emit_vector_select): Ditto.
6688         (rs6000_emit_vector_cond_expr): Ditto.
6689         (rs6000_emit_minmax): Directly generate min/max under altivec, vsx.
6690         (create_TOC_reference): Add -mdebug=addr support.
6691         (emit_frame_save): VSX loads/stores need register indexed addressing.
6692
6693         * config/rs6000/rs6000.md: Include vector.md.
6694
6695         * config/rs6000/t-rs6000 (MD_INCLUDES): Add vector.md.
6696
6697         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
6698         support for V2DI, V2DF in logical, permute, select operations.
6699
6700         * config/rs6000/rs6000.opt (-mvsx-scalar-double): Add new debug
6701         switch for vsx/power7.
6702         (-mvsx-scalar-memory): Ditto.
6703         (-mvsx-align-128): Ditto.
6704         (-mallow-movmisalign): Ditto.
6705         (-mallow-df-permute): Ditto.
6706         (-msched-groups): Ditto.
6707         (-malways-hint): Ditto.
6708         (-malign-branch-targets): Ditto.
6709
6710         * config/rs6000/rs6000.h (IRA_COVER_CLASSES): Delete, use target
6711         hook instead.
6712         (IRA_COVER_CLASSES_PRE_VSX): Cover classes if not -mvsx.
6713         (IRA_COVER_CLASSES_VSX): Cover classes if -mvsx.
6714         (rs6000_vector_reg_class): Delete.
6715         (rs6000_vsx_reg_class): Ditto.
6716         (enum rs6000_reg_class_enum): New enum for the constraints that
6717         vary based on target switches.
6718         (rs6000_constraints): New array to hold the register class for all
6719         of the register constraints that vary based on the switches used.
6720         (ALTIVEC_BUILTIN_*_UNS): Add unsigned builtin functions.
6721         (enum rs6000_builtins): Add unsigned varients for the builtin
6722         declarations returned by target hooks for expanding multiplies,
6723         select, and permute operations.  Add VSX builtins.
6724         (enum rs6000_builtin_type_index): Add entries for VSX.
6725         (V2DI_type_node): Ditto.
6726         (V2DF_type_node): Ditto.
6727         (unsigned_V2DI_type_node): Ditto.
6728         (bool_long_type_node): Ditto.
6729         (intDI_type_internal_node): Ditto.
6730         (uintDI_type_internal_node): Ditto.
6731         (double_type_internal_node): Ditto.
6732
6733         * config/rs6000/altivec.md (whole file): Move all expanders to
6734         vector.md from altivec.md.  Rename insn matching functions to be
6735         altivec_foo.
6736         (UNSPEC_VCMP*): Delete, rewrite vector comparisons.
6737         (altivec_vcmp*): Ditto.
6738         (UNSPEC_VPERM_UNS): New, add for unsigned types using vperm.
6739         (VM): New iterator for moves that includes the VSX types.
6740         (altivec_vperm_<mode>): Add VSX types.  Add unsigned types.
6741         (altivec_vperm_<mode>_uns): New, for unsigned types.
6742         (altivec_vsel_*): Rewrite vector comparisons and predicate builtins.
6743         (altivec_eq<mode>): Ditto.
6744         (altivec_gt<mode>): Ditto.
6745         (altivec_gtu<mode>): Ditto.
6746         (altivec_eqv4sf): Ditto.
6747         (altivec_gev4sf): Ditto.
6748         (altivec_gtv4sf): Ditto.
6749         (altivec_vcmpbfp_p): Ditto.
6750
6751 2009-07-23  Richard Earnshaw  <rearnsha@arm.com>
6752
6753         * arm.md (split for ior/xor with shift and zero-extend): Cast op3 to
6754         unsigned HWI.
6755
6756 2009-07-23  Uros Bizjak  <ubizjak@gmail.com>
6757
6758         PR target/40832
6759         * config/i386/i386.c (output_387_ffreep): Rewrite to use
6760         ASM_SHORT instead of .word.
6761         * config/i386/i386.md (*tls_global_dynamic_64): Use ASM_SHORT
6762         instead of .word in asm template.
6763
6764 2009-07-22  Vladimir Makarov  <vmakarov@redhat.com>
6765
6766         PR target/37488
6767         * ira-lives.c (bb_has_abnormal_call_pred): New function.
6768         (process_bb_node_lives): Use it.
6769
6770         * ira.c (setup_cover_and_important_classes): Don't setup
6771         ira_important_class_nums.  Add cover classes to the end of
6772         important classes.
6773         (cover_class_order, comp_reg_classes_func, reorder_important_classes):
6774         New.
6775         (find_reg_class_closure): Use reorder_important_classes.
6776
6777         * config/i386/i386.h (IRA_COVER_CLASSES): Remove.
6778
6779         * config/i386/i386.c (i386_ira_cover_classes): New function.
6780         (TARGET_IRA_COVER_CLASSES): Redefine.
6781
6782         * doc/tm.texi (TARGET_IRA_COVER_CLASSES): Add a comment about
6783         importance of order of cover classes in the array.
6784
6785 2009-07-22  Diego Novillo  <dnovillo@google.com>
6786
6787         * tree-pass.h (TDF_EH): Define.
6788         * gimple-pretty-print.c (dump_gimple_stmt): If FLAGS
6789         contains TDF_EH, print the EH region number holding GS.
6790         * tree-dump.c (dump_options): Add "eh".
6791         * doc/invoke.texi: Document it.
6792
6793 2009-07-22  Doug Kwan  <dougkwan@google.com>
6794
6795         * config/arm/arm.md (subdi3) Copy non-reg values to DImode registers.
6796
6797 2009-07-22  Michael Matz  <matz@suse.de>
6798
6799         PR tree-optimization/35229
6800         PR tree-optimization/39300
6801
6802         * tree-ssa-pre.c (includes): Include tree-scalar-evolution.h.
6803         (inhibit_phi_insertion): New function.
6804         (insert_into_preds_of_block): Call it for REFERENCEs.
6805         (init_pre): Initialize and finalize scalar evolutions.
6806         * Makefile.in (tree-ssa-pre.o): Depend on tree-scalar-evolution.h .
6807
6808 2009-07-22  Uros Bizjak  <ubizjak@gmail.com>
6809
6810         * config/i386/predicates.md (zero_extended_scalar_load_operand):
6811         Use CONST_VECTOR_NUNITS to determine number of elements.
6812
6813 2009-07-22  Andreas Krebbel  <krebbel1@de.ibm.com>
6814
6815         * config/s390/constraints.md (ZQ, ZR, ZS, ZT): New constraints.
6816         (U, W): Constraints are now deprecated and will be removed if we
6817         run out of letters.
6818         * config/s390/s390.md (U, W): Replaced with ZQZR, ZSZT throughout
6819         the file.
6820         ("prefetch"): Add the stcmh instruction for prefetching.
6821         * config/s390/s390.c (s390_symref_operand_p): Function moved. No
6822         changes.
6823         (s390_short_displacement): Return always true if compiling for
6824         machines not providing the long displacement facility.
6825         (s390_mem_constraint): Support the new constraint letter Z.
6826         (s390_check_qrst_address): New function.
6827
6828 2009-07-21  DJ Delorie  <dj@redhat.com>
6829
6830         * config/mep/mep.c (mep_legitimize_arg): Leave control registers
6831         alone too.
6832
6833 2009-07-21  Jason Merrill  <jason@redhat.com>
6834
6835         * c-common.c (max_tinst_depth): Increase default to 1024.
6836
6837 2009-07-21  Uros Bizjak  <ubizjak@gmail.com>
6838
6839         * config/i386/sse.md (vec_unpacku_float_hi_v4si): New expander.
6840         (vec_unpacku_float_lo_v4si): Ditto.
6841
6842 2009-07-21  Uros Bizjak  <ubizjak@gmail.com>
6843
6844         PR target/40811
6845         * config/i386/sse.md (sse2_cvtudq2ps): New expander.
6846         (enum ix86_builtins): Add IX86_BUILTIN_CVTUDQ2PS.
6847         (builtin_description): Add __builtin_ia32_cvtudq2ps.
6848         (ix86_vectorize_builtin_conversion): Handle IX86_BUILTIN_CVTUDQ2PS.
6849
6850 2009-07-21  Jakub Jelinek  <jakub@redhat.com>
6851
6852         PR tree-optimization/40813
6853         * tree-inline.c (copy_bb): Regimplify RHS after last stmt, not before
6854         it.
6855
6856 2009-07-21  Kaz Kojima  <kkojima@gcc.gnu.org>
6857
6858         * config/sh/sh.c (sh_gimplify_va_arg_expr): Wrap the result
6859         with a NOP_EXPR if needed.
6860
6861 2009-07-21  Paul Brook <paul@codesourcery.com>
6862
6863         * tree-vectorizer.c (increase_alignment): Handle nested arrays.
6864         Terminate debug dump with newline.
6865
6866 2009-07-20  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
6867
6868         * pa.c (compute_zdepwi_operands): Limit deposit length to 32 - lsb.
6869         Cast "1" to unsigned HOST_WIDE_INT.
6870         (compute_zdepdi_operands): Limit maximum length to 64 bits.  Limit
6871         deposit length to the maximum length - lsb.  Extend length if
6872         HOST_BITS_PER_WIDE_INT is 32.
6873
6874 2009-07-20  Olatunji Ruwase <tjruwase@google.com>
6875
6876         * cgraph.h (constant_pool_htab): New function.
6877         (constant_descriptor_tree): Move from varasm.c.
6878         * varasm.c (constant_pool_htab): New function.
6879         (constant_descriptor_tree): Move to cgraph.h.
6880
6881 2009-07-20  Olatunji Ruwase  <tjruwase@google.com>
6882
6883         * toplev.c: Invoke FINISH_UNIT callbacks before call to finalize().
6884
6885 2009-07-20  Shujing Zhao  <pearly.zhao@oracle.com>
6886
6887         * Makefile.in (TREE_INLINE_H, tree-inline.o, cgraph.o): Remove
6888         $(VARRAY_H).
6889
6890 2009-07-20  Xinliang David Li  <davidxl@google.com>
6891
6892         * dbgcnt.c (dbg_cnt_set_limit_by_name): Add length check.
6893
6894 2009-07-20  Adam Nemet  <anemet@caviumnetworks.com>
6895
6896         * config/mips/mips.md (move_type): Add arith.
6897         (type): Handle arith.
6898         (zero_extendsidi2): Rename this into ...
6899         (*zero_extendsidi2): ... this.  Don't match if ISA_HAS_EXT_INS.
6900         (zero_extendsidi2): New expander.
6901         (*zero_extendsidi2_dext): New pattern.
6902
6903 2009-07-20  Nick Clifton  <nickc@redhat.com>
6904
6905         * config.gcc (mips64-*-*): Add definition of tm_defines in order
6906         to set MIPS_ABI_DEFAULT.
6907         * config/mips/vr.h (MIPS_ABI_DEFAULT): Remove definition.
6908
6909 2009-07-20  Jakub Jelinek  <jakub@redhat.com>
6910
6911         * tree-object-size.c (addr_object_size): Handle unions with
6912         array in it as last field of structs in __bos (, 1) as __bos (, 0).
6913
6914         PR tree-optimization/40792
6915         * tree.c (build_function_type_skip_args): Remove bogus assert.
6916
6917 2009-07-20  Jan Hubicka  <jh@suse.cz>
6918             Martin Jambor  <mjambor@suse.cz>
6919
6920         * cgraph.h (combined_args_to_skip): New field.
6921         * cgraph.c (cgraph_create_virtual_clone): Properly handle
6922         combined_args_to_skip and args_to_skip.
6923         * tree-inline.c (update_clone_info): New function.
6924         (tree_function_versioning): Call update_clone_info.
6925         * cgraphunit.c: (cgraph_materialize_clone): Dump materialized
6926         functions.
6927         (cgraph_materialize_all_clones): More extensive dumping, working
6928         with combined_args_to_skip rather than args_to_skip.
6929
6930 2009-07-20  Ira Rosen  <irar@il.ibm.com>
6931
6932         * tree-vectorizer.h (vectorizable_condition): Add parameters.
6933         * tree-vect-loop.c (vect_is_simple_reduction): Support COND_EXPR.
6934         (get_initial_def_for_reduction): Likewise.
6935         (vectorizable_reduction): Skip the check of first operand in case
6936         of COND_EXPR. Add check that it is outer loop vectorization if
6937         nested cycle was detected. Call vectorizable_condition() for
6938         COND_EXPR. If reduction epilogue cannot be created do not fail for
6939         nested cycles (if it is not double reduction). Assert that there
6940         is only one type in the loop in case of COND_EXPR. Call
6941         vectorizable_condition() to vectorize COND_EXPR.
6942         * tree-vect-stmts.c (vectorizable_condition): Update comment.
6943         Add parameters. Allow nested cycles if called from
6944         vectorizable_reduction(). Use reduction vector variable if provided.
6945         (vect_analyze_stmt): Call vectorizable_reduction() before
6946         vectorizable_condition().
6947         (vect_transform_stmt): Update call to vectorizable_condition().
6948
6949 2009-07-20  Christian Bruel  <christian.bruel@st.com>
6950
6951         * config/sh/sh.opt (-mfmovd): Resurrect and document.
6952         * doc/invoke.texi (-mfmovd): Likewise.
6953         * config/sh/sh.h (TARGET_FMOVD, MASK_FMOVD): Remove default setting.
6954
6955 2009-07-20  Jan Hubicka  <jh@suse.cz>
6956
6957         * tree-ssa-dce.c (remove_dead_phis): Only look for abnormal PHIs
6958         when handling SSA name.
6959
6960 2009-07-19  Jan Hubicka  <jh@suse.cz>
6961
6962         PR tree-optimization/40676
6963         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Do renaming on all
6964         virtual PHIs in empty BBs.
6965
6966 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
6967
6968         * combine.c (make_compound_operation) <SUBREG>: If force_to_mode
6969         re-expanded the compound use gen_lowpart instead to convert to the
6970         desired mode.
6971
6972 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
6973
6974         * combine.c (try_widen_shift_mode): Add COUNT, OUTER_CODE and
6975         OUTER_CONST arguments.
6976         <LSHIFTRT>: Use them to allow widening if the bits shifted in from
6977         the new wider mode will be masked off.
6978         (simplify_shift_const_1): Adjust calls to try_widen_shift_mode.
6979
6980 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
6981
6982         * combine.c (try_widen_shift_mode) <LSHIFTRT>: Allow widening if the
6983         high-order bits are zero.
6984
6985 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
6986
6987         * combine.c (simplify_shift_const_1): Split code to determine
6988         shift_mode into ...
6989         (try_widen_shift_mode): ... here.  Allow widening for ASHIFTRT if the
6990         new bits shifted in are identical to the old sign bit.
6991
6992 2009-07-18  Richard Guenther  <rguenther@suse.de>
6993
6994         PR c/40787
6995         * gimplify.c (gimplify_call_expr): Reject code using results from
6996         functions returning void.
6997
6998 2009-07-18  Richard Sandiford  <r.sandiford@uk.ibm.com>
6999
7000         * doc/md.texi: Document the new PowerPC "es" constraint.
7001         Document that "m" can include automodified addresses on this target,
7002         and explain how %U must be used.  Extend the "Q" and "Z" documentation
7003         to suggest "es" as well as "m".
7004         * config/rs6000/constraints.md (es): New memory constraint.
7005         (Q, Z): Update strings to match new documentation.
7006
7007 2009-07-18  Richard Sandiford  <r.sandiford@uk.ibm.com>
7008
7009         * config/rs6000/rs6000.c (rs6000_mode_dependent_address): Allow any
7010         offset from virtual_stack_vars_rtx and arg_pointer_rtx.
7011         * config/rs6000/predicates.md (volatile_mem_operand): Use
7012         offsettable_nonstrict_memref_p.
7013         * config/rs6000/rs6000.md (*floatsidf2_internal): Remove split check.
7014         (*floatunssidf2_internal): Likewise.
7015         (*fix_truncdfsi2_internal): Likewise.
7016         (*fix_trunctfsi2_internal): Likewise.
7017
7018 2009-07-17  Anatoly Sokolov  <aesok@post.ru>
7019
7020         * config/avr/avr-devices.c (avr_mcu_t): Add atmega8u2, atmega16u2 and
7021         atmega32u2 devices.
7022         * config/avr/t-avr (MULTILIB_MATCHES): (Ditto.).
7023
7024 2009-07-17  Richard Guenther  <rguenther@suse.de>
7025
7026         PR c/40401
7027         * tree-pass.h (pass_diagnose_omp_blocks): Declare.
7028         (pass_warn_unused_result): Likewise.
7029         (TODO_set_props): Remove.
7030         * omp-low.c (diagnose_omp_structured_block_errors): Change to
7031         run as a pass.
7032         (pass_diagnose_omp_blocks): Define.
7033         * c-decl.c (pop_file_scope): Do not finalize the CU here.
7034         (c_gimple_diagnostics_recursively): Remove.
7035         (finish_function): Do not call it.
7036         (c_write_global_declarations): Continue after errors.
7037         Finalize the CU here.
7038         * c-gimplify.c (c_genericize): Do not gimplify here.
7039         * c-common.c (c_warn_unused_result): Move ...
7040         * tree-cfg.c (do_warn_unused_result): ... here.
7041         (run_warn_unused_result): New function.
7042         (gate_warn_unused_result): New function.
7043         (pass_warn_unused_result): New pass.
7044         * c-common.h (c_warn_unused_result): Remove.
7045         * flags.h (flag_warn_unused_result): Declare.
7046         * c-opts.c (c_common_init_options): Enable flag_warn_unused_result.
7047         * opts.c (flag_warn_unused_result): Initialize to false.
7048         * toplev.c (compile_file): Add comment.
7049         * omp-low.c (create_omp_child_function): Do not register
7050         the function with the frontend.
7051         (diagnose_omp_structured_block_errors): Prepare to be
7052         called as optimization pass.
7053         (gate_diagnose_omp_blocks): New function.
7054         (pass_diagnose_omp_blocks): New pass.
7055         * cgraph.h (cgraph_optimize): Remove.
7056         (cgraph_analyze_function): Likewise.
7057         * cgraph.c (cgraph_add_new_function): Gimplify C++ thunks.
7058         * cgraphunit.c (cgraph_lower_function): Lower nested functions
7059         before their parents here.
7060         (cgraph_finalize_function): Not here.
7061         (cgraph_analyze_function): Gimplify functions here.
7062         (cgraph_finalize_compilation_unit): Continue after errors.
7063         Optimize the callgraph from here.
7064         (cgraph_optimize): Make static.
7065         * langhooks.c (write_global_declarations): Finalize the CU.
7066         * gimplify.c (gimplify_asm_expr): Do not emit ASMs with errors.
7067         (gimplify_function_tree): Assert we gimplify only once.
7068         Set PROP_gimple_any property.
7069         * tree-nested.c (gimplify_all_functions): New function.
7070         (lower_nested_functions): Gimplify all nested functions.
7071         * gimple.h (diagnose_omp_structured_block_errors): Remove.
7072         * passes.c (init_optimization_passes): Add pass_warn_unused_result
7073         and pass_diagnose_omp_blocks after gimplification.  Do not
7074         set TODO_set_props on all_lowering_passes.
7075         (execute_one_pass): Do not handle TODO_set_props.
7076         * Makefile.in (cgraphunit.o): Add $(TREE_DUMP_H) dependency.
7077         (gimplify.o): Add tree-pass.h dependency.
7078         * tree-inline.c (copy_statement_list): Properly copy STATEMENT_LIST.
7079         (copy_tree_body_r): Properly handle TARGET_EXPR like SAVE_EXPR.
7080         (unsave_r): Likewise.
7081         * c-omp.c (c_finish_omp_atomic): Set DECL_CONTEXT on the
7082         temporary variable.
7083
7084 2009-07-17  Sandra Loosemore  <sandra@codesourcery.com>
7085
7086         * doc/service.texi (Service): Restore previously removed link,
7087         which isn't broken after all.
7088
7089 2009-07-17  Richard Guenther  <rguenther@suse.de>
7090
7091         PR tree-optimization/40321
7092         * tree-ssa-pre.c (add_to_exp_gen): Also add names defined by
7093         PHI nodes to the maximal set.
7094         (make_values_for_phi): Add PHI arguments to the maximal set.
7095         (execute_pre): Dump PHI_GEN and the maximal set.
7096
7097 2009-07-17  Jakub Jelinek  <jakub@redhat.com>
7098
7099         PR c++/40780
7100         * gimplify.c (gimplify_conversion): Don't change non-conversions into
7101         VIEW_CONVERT_EXPR.
7102
7103 2009-07-16  Sandra Loosemore  <sandra@codesourcery.com>
7104
7105         * doc/extend.texi (Nested Functions): Replace broken link with
7106         textual reference.
7107         * doc/service.texi (Service): Remove broken link.
7108
7109 2009-07-16  H.J. Lu  <hongjiu.lu@intel.com>
7110
7111         PR bootstrap/40781
7112         * builtins.c (expand_builtin_memcmp): Use loc instead of
7113         EXPR_LOCATION (exp).
7114         (expand_builtin_strncmp): Likewise.
7115
7116 2009-07-17  Aldy Hernandez  <aldyh@redhat.com>
7117             Manuel López-Ibáñez  <manu@gcc.gnu.org>
7118
7119         PR 40435
7120         * tree-complex.c, tree-loop-distribution.c, tree.c, tree.h,
7121         builtins.c, fold-const.c, omp-low.c, cgraphunit.c, tree-ssa-ccp.c,
7122         tree-ssa-dom.c, gimple-low.c, expr.c, tree-ssa-ifcombine.c,
7123         c-decl.c, stor-layout.c, tree-if-conv.c, c-typeck.c, gimplify.c,
7124         calls.c, tree-sra.c, tree-mudflap.c, tree-ssa-copy.c,
7125         tree-ssa-forwprop.c, c-convert.c, c-omp.c, varasm.c,
7126         tree-inline.c, c-common.c, c-common.h, gimple.c,
7127         tree-switch-conversion.c, gimple.h, tree-cfg.c, c-parser.c,
7128         convert.c: Add location argument to fold_{unary,binary,ternary},
7129         fold_build[123], build_call_expr, build_size_arg,
7130         build_fold_addr_expr, build_call_array, non_lvalue, size_diffop,
7131         fold_build1_initializer, fold_build2_initializer,
7132         fold_build3_initializer, fold_build_call_array,
7133         fold_build_call_array_initializer, fold_single_bit_test,
7134         omit_one_operand, omit_two_operands, invert_truthvalue,
7135         fold_truth_not_expr, build_fold_indirect_ref, fold_indirect_ref,
7136         combine_comparisons, fold_builtin_*, fold_call_expr,
7137         build_range_check, maybe_fold_offset_to_address, round_up,
7138         round_down.
7139
7140 2009-07-16  Jason Merrill  <jason@redhat.com>
7141
7142         PR libstdc++/37907
7143         * c-common.c (c_common_reswords): Add __is_standard_layout
7144         and __is_trivial.
7145         * c-common.h (enum rid): Add RID_IS_STD_LAYOUT and RID_IS_TRIVIAL.
7146         * doc/implement-cxx.texi: New.
7147         * doc/gcc.texi: Include it.
7148
7149 2009-07-16  DJ Delorie  <dj@redhat.com>
7150
7151         * config/m32c/m32c.c (m32c_compare_redundant): Avoid removing
7152         compares that may be indirectly affected by previous instructions.
7153
7154 2009-07-16  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
7155
7156         * builtins.c (do_mpc_arg2): New.
7157         (fold_builtin_2): Fold builtin cpow.
7158         * real.h (HAVE_mpc_pow): New.
7159
7160 2009-07-16  Bingfeng Mei  <bmei@broadcom.com>
7161
7162         * modulo-sched.c (sms_schedule): stage_count <= 1 as correct
7163         comparison to skip unprofitable schedule
7164
7165 2009-07-16  Simon Baldwin  <simonb@google.com>
7166
7167         * gcc.c (option_map): New flag -no-canonical-prefixes.
7168         * (display_help): Print help text for new flag.
7169         * (process_command): Move options translation and language specifics
7170         and handle new flag early.  Use it to set a function pointer to a
7171         prefix builder.  Replace make_relative_prefix calls with calls to
7172         the function pointed to.  Ignore new flag in regular options handling.
7173         * doc/invoke.texi (Overall Options): Documented -no-canonical-prefixes.
7174
7175 2009-07-15  DJ Delorie  <dj@redhat.com>
7176
7177         * config/mep/mep.md (sibcall_internal): Change register to avoid
7178         argument registers.
7179         (sibcall_value_internal): Likewise.
7180
7181 2009-07-15  Eric Botcazou  <ebotcazou@adacore.com>
7182
7183         PR rtl-optimization/40710
7184         * resource.c (mark_target_live_regs): Reset DF problem to LR.
7185
7186 2009-07-15  Adam Nemet  <anemet@caviumnetworks.com>
7187
7188         * config/mips/mips.md (*extenddi_truncate<mode>,
7189         *extendsi_truncate<mode>): Change type attribute to move_type
7190         with shift_shift.  Split out code handling exts from here ...
7191         (*extend<GPR:mode>_truncate<SHORT:mode>_exts): ... to this new
7192         pattern.
7193         (*extendhi_truncateqi): Change type attribute to move_type with
7194         shift_shift.  Split out code handling exts from here ...
7195         (*extendhi_truncateqi_exts): ... to this new pattern.
7196
7197 2009-07-15  Uros Bizjak  <ubizjak@gmail.com>
7198
7199         * config/i386/sse.md (copysign<mode>3): Use "and-not" SSE instruction
7200         instead of "and" with inverted sign bit mask value.  Use
7201         "nonimmediate_operand" for operand 1 and operand 2 predicate.
7202         Allocate registers only for operand 4 and operand 5.
7203
7204 2009-07-15  Jakub Jelinek  <jakub@redhat.com>
7205
7206         PR middle-end/40747
7207         * fold-const.c (fold_cond_expr_with_comparison): When folding
7208         < and <= to MIN, make sure the MIN uses the same type as the
7209         comparison's operands.
7210
7211 2009-07-15  Richard Earnshaw  <rearnsha@arm.com>
7212
7213         * arm.md (ior_xor): New code iterator.
7214         (split for ior/xor with shift and zero-extend): New split pattern.
7215         * arm/predicates.md (subreg_lowpart_operator): New special predicate.
7216
7217 2009-07-15  Richard Guenther  <rguenther@suse.de>
7218
7219         * tree-ssa-structalias.c (make_constraint_from_heapvar): Initialize
7220         offset member.
7221
7222 2009-07-15  Richard Guenther  <rguenther@suse.de>
7223
7224         PR middle-end/40753
7225         * alias.c (ao_ref_from_mem): Reject FUNCTION_DECL and LABEL_DECL bases.
7226
7227 2009-07-15  Maxim Kuvyrkov  <maxim@codesourcery.com>
7228
7229         * config/m68k/linux-unwind.h (m68k_fallback_frame_state): Update to
7230         handle 2.6.30 kernel.
7231
7232 2009-07-15  DJ Delorie  <dj@redhat.com>
7233
7234         * config/mep/mep.md (sibcall_internal): Change register to allow
7235         for 24-bit addresses.
7236         (sibcall_value_internal): Likewise.
7237
7238 2009-07-14  Ghassan Shobaki  <ghassan.shobaki@amd.com>
7239
7240         * doc/invoke.texi: Added descriptions of the  scheduling heuristics
7241         that are enabled/disabled by the flags introduced by a previous patch.
7242
7243 2009-07-14  DJ Delorie  <dj@redhat.com>
7244
7245         * config/mep/mep.md (sibcall_internal): Include non-toggling
7246         non-jmp case.
7247         (sibcall_value_internal): Likewise.
7248
7249 2009-07-14  Taras Glek  <tglek@mozilla.com>
7250             Rafael Espindola  <espindola@google.com>
7251
7252         * doc/sourcebuild.texi: Document install-plugin target.
7253         * configure.ac: Added install-plugin target to language makefiles.
7254         * configure: Regenerate.
7255         * Makefile.in: (install-plugin): Install more headers,
7256         depend on lang.install-plugin.
7257
7258 2009-07-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7259
7260         * tree-vrp.c (vrp_evaluate_conditional): Mark strings for
7261         translation.
7262
7263 2009-07-14  DJ Delorie  <dj@redhat.com>
7264
7265         * config/mep/mep.c (mep_vliw_jmp_match): New function.
7266         * config/mep/mep-protos.h (mep_vliw_jmp_match): Prototype it.
7267         * config/mep/mep.md (sibcall_internal): Change test from
7268         mep_vliw_mode_match to mep_vliw_jmp_match.
7269         (sibcall_value_internal): Likewise.
7270
7271 2009-07-14  Uros Bizjak  <ubizjak@gmail.com>
7272
7273         * config/i386/sse.md (copysign<mode>3): New expander.
7274         * config/i386/i386-protos.h (ix86_build_signbit_mask): New prototype.
7275         * config/i386/i386.c (ix86_build_signbit_mask): Make public.
7276         Use ix86_build_const_vector.
7277         (enum ix86_builtins): Add IX86_BUILTIN_CPYSGNPS and
7278         IX86_BUILTIN_CPYSGNPD.
7279         (builtin_description): Add __builtin_ia32_copysignps and
7280         __builtin_ia32_copysignpd.
7281         (ix86_builtin_vectorized_function): Handle BUILT_IN_COPYSIGN
7282         and BUILT_IN_COPYSIGNF.
7283
7284 2009-07-13  Jason Merrill  <jason@redhat.com>
7285
7286         * builtins.c (can_trust_pointer_alignment): New fn.
7287         (get_pointer_alignment): Factor it out from here.
7288         * tree.h: Declare it.
7289
7290 2009-07-14  David Edelsohn  <edelsohn@gnu.org>
7291
7292         * config/rs6000/predicates.md (offsettable_mem_operand): Test
7293         RTX_AUTOINC class.
7294
7295 2009-07-14  Dodji Seketeli  <dodji@redhat.com>
7296
7297         PR debug/40705
7298         PR c++/403057
7299         * dwarf2.out.c (gen_type_die_with_usage): Added comment.
7300
7301 2009-07-14  Richard Guenther  <rguenther@suse.de>
7302             Andrey Belevantsev <abel@ispras.ru>
7303
7304         PR middle-end/40745
7305         * cfgexpand.c (partition_stack_vars): Do not bother to update
7306         alias information when not optimizing.
7307
7308 2009-07-14  Richard Guenther  <rguenther@suse.de>
7309             Andrey Belevantsev <abel@ispras.ru>
7310
7311         * tree-ssa-alias.h (refs_may_alias_p_1): Declare.
7312         (pt_solution_set): Likewise.
7313         * tree-ssa-alias.c (refs_may_alias_p_1): Export.
7314         * tree-ssa-structalias.c (pt_solution_set): New function.
7315         * final.c (rest_of_clean_state): Free SSA data structures.
7316         * print-rtl.c (print_decl_name): Remove.
7317         (print_mem_expr): Implement in terms of print_generic_expr.
7318         * alias.c (ao_ref_from_mem): New function.
7319         (rtx_refs_may_alias_p): Likewise.
7320         (true_dependence): Query alias-export info.
7321         (canon_true_dependence): Likewise.
7322         (write_dependence_p): Likewise.
7323         * tree-dfa.c (get_ref_base_and_extent): For void types leave
7324         size unknown.
7325         * emit-rtl.c (component_ref_for_mem_expr): Remove.
7326         (mem_expr_equal_p): Use operand_equal_p.
7327         (set_mem_attributes_minus_bitpos): Do not use
7328         component_ref_for_mem_expr.
7329         * cfgexpand.c (add_partitioned_vars_to_ptset): New function.
7330         (update_alias_info_with_stack_vars): Likewise.
7331         (partition_stack_vars): Call update_alias_info_with_stack_vars.
7332         * tree-ssa.c (delete_tree_ssa): Do not release SSA names
7333         explicitly nor clear stmt operands.
7334         Free the decl-to-pointer map.
7335         * tree-optimize.c (execute_free_datastructures): Do not free
7336         SSA data structures here.
7337         * tree-flow.h (struct gimple_df): Add decls_to_pointers member.
7338         * Makefile.in (emit-rtl.o): Add pointer-set.h dependency.
7339         (alias.o): Add tree-ssa-alias.h, pointer-set.h and $(TREE_FLOW_H)
7340         dependencies.
7341         (print-rtl.o): Add $(DIAGNOSTIC_H) dependency.
7342
7343 2009-07-13  DJ Delorie  <dj@redhat.com>
7344
7345         * config/mep/mep.h (CC1_SPEC): Tweak parameters to trigger
7346         unrolling at the right iteration count.
7347
7348         * config/mep/mep.c (mep_expand_prologue): Fix frame pointer
7349         calculations.
7350
7351 2009-07-13  Ghassan Shobaki  <ghassan.shobaki@amd.com>
7352
7353         * haifa-sched.c (rank_for_schedule): Introduced flags to
7354         enable/disable individual scheduling heuristics.
7355         * common.opt: Introduced flags to enable/disable individual
7356         heuristics in the scheduler.
7357         * doc/invoke.texi: Introduced flags to enable/disable individual
7358         heuristics in the scheduler.
7359
7360 2009-07-13  Kai Tietz  <kai.tietz@onevision.com>
7361
7362         * config/i386/t-gthr-win32 (LIB2FUNCS_EXTRA): Remove file
7363         config/i386/mingw-tls.c.
7364         * config/i386/mingw-tls.c: Removed.
7365
7366 2009-07-13  Ira Rosen  <irar@il.ibm.com>
7367
7368         * tree-vect-loop.c (get_initial_def_for_reduction): Ensure that the
7369         checks access only relevant statements.
7370         (vectorizable_reduction): Likewise.
7371
7372 2009-07-12  Kai Tietz  <kai.tietz@onevision.com>
7373
7374         * config/i386/cygming.h (TARGET_OS_CPP_BUILTINS): Define _X86_
7375         just for 32-bit case.
7376
7377 2009-07-12  Jan Hubicka  <jh@suse.cz>
7378
7379         PR tree-optimization/40585
7380         * except.c (expand_resx_expr): When there already is resume
7381         instruction, produce linked list.
7382         (build_post_landing_pads): Assert that resume is empty.
7383         (connect_post_landing_pads): Handle resume lists.
7384         (dump_eh_tree): Dump resume list.
7385
7386 2009-07-12  Ira Rosen  <irar@il.ibm.com>
7387
7388         * tree-parloops.c (loop_parallel_p): Call vect_is_simple_reduction
7389         with additional argument.
7390         * tree-vectorizer.h (enum vect_def_type): Add
7391         vect_double_reduction_def.
7392         (vect_is_simple_reduction): Add argument.
7393         * tree-vect-loop.c (vect_determine_vectorization_factor): Fix
7394         indentation.
7395         (vect_analyze_scalar_cycles_1): Detect double reduction. Call
7396         vect_is_simple_reduction with additional argument.
7397         (vect_analyze_loop_operations): Handle exit phi nodes in case of
7398         double reduction.
7399         (reduction_code_for_scalar_code): Handle additional codes by
7400         returning ERROR_MARK for them. Fix comment and indentation.
7401         (vect_is_simple_reduction): Fix comment, add argument to specify
7402         double reduction. Detect double reduction.
7403         (get_initial_def_for_induction): Fix indentation.
7404         (get_initial_def_for_reduction): Fix comment and indentation.
7405         Handle double reduction. Create initial definitions that do not
7406         require adjustment if ADJUSTMENT_DEF is NULL. Handle additional cases.
7407         (vect_create_epilog_for_reduction): Fix comment, add argument to
7408         handle double reduction. Use PLUS_EXPR in case of MINUS_EXPR in
7409         epilogue result extraction. Create double reduction phi node and
7410         replace relevant uses.
7411         (vectorizable_reduction): Call vect_is_simple_reduction with
7412         additional argument. Fix indentation. Update epilogue code treatment
7413         according to the changes in reduction_code_for_scalar_code. Check
7414         for double reduction. Call vect_create_epilog_for_reduction with
7415         additional argument.
7416         * tree-vect-stmts.c (process_use): Handle double reduction, update
7417         documentation.
7418         (vect_mark_stmts_to_be_vectorized): Handle double reduction.
7419         (vect_get_vec_def_for_operand): Likewise.
7420
7421 2009-07-12  Danny Smith  <dansmister@gmail.com>
7422
7423         * config/i386/winnt.c (i386_pe_determine_dllexport_p): Don't
7424         dllexport if !TREE_PUBLIC.
7425         (i386_pe_maybe_record_exported_symbol): Assert TREE_PUBLIC.
7426
7427 2009-07-11  Anatoly Sokolov  <aesok@post.ru>
7428
7429         * config/avr/avr.h (TARGET_CPU_CPP_BUILTINS): Redefine.
7430         (avr_extra_arch_macro) Remove declatation.
7431         * config/avr/avr.c (avr_cpu_cpp_builtins): New function.
7432         (avr_extra_arch_macro) Declare as static.
7433         * config/avr/avr-protos.h (avr_cpu_cpp_builtins): Dclare.
7434
7435 2009-07-11  Jan Hubicka  <jh@suse.cz>
7436
7437         PR middle-end/48388
7438         * except.c (can_be_reached_by_runtime): Test for NULL aka bitmap.
7439
7440 2009-07-11  Jakub Jelinek  <jakub@redhat.com>
7441
7442         PR debug/40713
7443         * dwarf2out.c (dw_fde_struct): Add in_std_section and
7444         cold_in_std_section bits.
7445         (dwarf2out_begin_prologue): Initialize them.
7446         (dwarf2out_finish): Don't emit FDE range into .debug_ranges
7447         if already covered by text_section or cold_text_section range.
7448
7449         PR rtl-optimization/40667
7450         * defaults.h (MINIMUM_ALIGNMENT): Define if not defined.
7451         * doc/tm.texi (MINIMUM_ALIGNMENT): Document it.
7452         * config/i386/i386.h (MINIMUM_ALIGNMENT): Define.
7453         * config/i386/i386.c (ix86_minimum_alignment): New function.
7454         * config/i386/i386-protos.h (ix86_minimum_alignment): New prototype.
7455         * cfgexpand.c (expand_one_var): Use MINIMIM_ALIGNMENT.
7456         * emit-rtl.c (gen_reg_rtx): Likewise.
7457         * function.c (assign_parms): Likewise.  If nominal_type needs
7458         bigger alignment than FUNCTION_ARG_BOUNDARY, use its alignment
7459         rather than passed_type's alignment.
7460
7461         PR target/40668
7462         * function.c (assign_parm_setup_stack): Adjust
7463         MEM_OFFSET (data->stack_parm) if promoted_mode is different
7464         from nominal_mode on big endian.
7465
7466 2009-07-11  Paolo Bonzini  <bonzini@gnu.org>
7467
7468         * expmed.c (emit_store_flag_1): Fix choice of zero vs. sign extension.
7469
7470 2009-07-10  DJ Delorie  <dj@redhat.com>
7471
7472         * config/mep/mep.c (mep_can_inline_p): Correct logic, and simplify.
7473
7474 2009-07-10  Mark Mitchell  <mark@codesourcery.com>
7475
7476         * config/arm/thumb2.md (thumb2_cbz): Correct computation of length
7477         attribute.
7478         (thumb2_cbnz): Likewise.
7479
7480 2009-07-10  David Daney  <ddaney@caviumnetworks.com>
7481
7482         PR target/39079
7483         * config.gcc (supported_defaults): Add synci.
7484         (with_synci): Add validation.
7485         (all_defaults): Add synci.
7486         * config/mips/mips.md (clear_cache): Use TARGET_SYNCI instead of
7487         ISA_HAS_SYNCI.
7488         (synci): Same.
7489         * config/mips/mips.opt (msynci): New option.
7490         * config/mips/mips.c (mips_override_options): Warn on use of
7491         -msynci for targets that do now support it.
7492         * gcc/config/mips/mips.h (OPTION_DEFAULT_SPECS): Add a default for
7493         msynci.
7494         * gcc/doc/invoke.texi (-msynci): Document the new option.
7495         * doc/install.texi (--with-synci): Document the new option.
7496
7497 2009-07-10  Richard Guenther  <rguenther@suse.de>
7498
7499         PR tree-optimization/40496
7500         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Create
7501         the PHI result with a compatible type.
7502
7503 2009-07-10  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7504
7505         PR 25509
7506         PR 40614
7507         * c.opt (Wunused-result): New.
7508         * doc/invoke.texi: Document it.
7509         * c-common.c (c_warn_unused_result): Use it.
7510
7511 2009-07-09  DJ Delorie  <dj@redhat.com>
7512
7513         * targhooks.c (default_target_can_inline_p): Rename from
7514         default_target_option_can_inline_p.
7515         * targhooks.h (default_target_can_inline_p): Likewise.
7516         * target-def.h (TARGET_CAN_INLINE_P): Rename from
7517         TARGET_OPTION_CAN_INLINE_P.
7518         * config/i386/i386.c (TARGET_CAN_INLINE_P): Likewise.
7519         * config/mep/mep.c (TARGET_CAN_INLINE_P): Likewise.
7520         (mep_target_can_inline_p): Rename from
7521         mep_target_option_can_inline_p.
7522
7523         PR target/40626
7524         * config/mep/mep.h (FUNCTION_ARG_REGNO_P): Add coprocessor
7525         registers used to pass vectors.
7526
7527         * config/mep/mep.c (mep_option_can_inline_p): Remove error call.
7528
7529 2009-07-09  Tom Tromey  <tromey@redhat.com>
7530
7531         * unwind-dw2-fde-darwin.c: Include dwarf2.h.
7532         * config/mmix/mmix.c: Include dwarf2.h.
7533         * config/rs6000/darwin-fallback.c: Include dwarf2.h.
7534         * config/xtensa/unwind-dw2-xtensa.c: Include dwarf2.h.
7535         * config/sh/sh.c: Include dwarf2.h.
7536         * config/i386/i386.c: Include dwarf2.h.
7537         * Makefile.in (DWARF2_H): Remove 'elf'.
7538         * except.c: Include dwarf2.h.
7539         * unwind-dw2.c: Include dwarf2.h.
7540         * dwarf2out.c: Include dwarf2.h.
7541         * unwind-dw2-fde-glibc.c: Include dwarf2.h.
7542         * unwind-dw2-fde.c: Include dwarf2.h.
7543         * dwarf2asm.c: Include dwarf2.h.
7544
7545 2009-07-09  Maxim Kuvyrkov  <maxim@codesourcery.com>
7546
7547         * haifa-sched.c (insn_finishes_cycle_p): New static function.
7548         (max_issue): Use it.
7549         * sched-int.h (struct sched_info: insn_finishes_block_p): New
7550         scheduler hook.
7551         * sched-rgn.c (rgn_insn_finishes_block_p): Implement it.
7552         (region_sched_info): Update.
7553         * sched-ebb.c (ebb_sched_info): Update.
7554         * modulo-sched.c (sms_sched_info): Update.
7555         * sel-sched-ir.c (sched_sel_haifa_sched_info): Update.
7556
7557 2009-07-09  Maxim Kuvyrkov  <maxim@codesourcery.com>
7558
7559         * varasm.c (build_constant_desc): Don't share RTL in pool entries.
7560
7561 2009-07-09  Basile Starynkevitch  <basile@starynkevitch.net>
7562
7563         * plugin.c (try_init_one_plugin): passes RTLD_GLOBAL to dlopen.
7564
7565 2009-07-09  Jakub Jelinek  <jakub@redhat.com>
7566
7567         PR middle-end/40692
7568         * fold-const.c (fold_cond_expr_with_comparison): Don't replace
7569         arg1 with arg01 if arg1 is already INTEGER_CST.
7570
7571 2009-07-08  Adam Nemet  <anemet@caviumnetworks.com>
7572
7573         * simplify-rtx.c (simplify_binary_operation_1) <AND>:
7574         Transform (and (truncate)) into (truncate (and)).
7575
7576 2009-07-08  Adam Nemet  <anemet@caviumnetworks.com>
7577
7578         * combine.c (make_extraction): Check TRULY_NOOP_TRUNCATION before
7579         creating LHS paradoxical subregs.  Fix surrounding returns to
7580         use NULL_RTX rather than 0.
7581
7582 2009-07-08  DJ Delorie  <dj@redhat.com>
7583
7584         * config/mep/mep.c: (mep_option_can_inline_p): New.
7585         (TARGET_OPTION_CAN_INLINE_P): Define.
7586
7587 2009-07-08  Mark Wielaard  <mjw@redhat.com>
7588
7589         PR debug/40659
7590         * dwarf2out.c (add_data_member_location_attribute): When we have
7591         only a constant offset don't emit a new location description using
7592         DW_OP_plus_uconst, but just add the constant with add_AT_int, when
7593         dwarf_version > 2.
7594
7595 2009-07-08  Richard Henderson  <rth@redhat.com>
7596
7597         PR target/38900
7598         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Move to i386.c.
7599         (enum reg_class): Add CLOBBERED_REGS.
7600         (REG_CLASS_NAMES, REG_CLASS_CONTENTS): Likewise.
7601         * config/i386/i386.c (ix86_conditional_register_usage): Moved
7602         from CONDITIONAL_REGISTER_USAGE; build CLOBBERED_REGS for 64-bit.
7603         (ix86_function_ok_for_sibcall): Tidy.  Disallow MS->SYSV sibcalls.
7604         (ix86_expand_call): Use sibcall_insn_operand when needed.  Don't
7605         force 64-bit sibcalls into R11.
7606         * config/i386/constraints.md (U): New constraint.
7607         * config/i386/i386.md (sibcall_1, sibcall_value_1): Use it.
7608         (sibcall_1_rex64, sibcall_value_1_rex64): Likewise.
7609         (sibcall_1_rex64_v, sibcall_value_1_rex64_v): Remove.
7610
7611 2009-07-08  Shujing Zhao  <pearly.zhao@oracle.com>
7612
7613         * basic-block.h (dump_regset, debug_regset): Remove duplicate
7614         prototypes.
7615         * c-objc-common.h (c_initialize_diagnostics): Ditto.
7616         * ebitmap.h (dump_ebitmap): Ditto.
7617         * optabs.h (optab_libfunc): Ditto.
7618         * tree.h (tree_expr_nonzero_warnv_p): Ditto.
7619         * tree-flow.h (vect_can_force_dr_alignment_p,
7620         get_vectype_for_scalar_type): Ditto.
7621         (vectorize_loops): Move prototype to ...
7622         * tree-vectorizer.h: ... here. Also, adjust comment.
7623         (vect_set_verbosity_level): Remove duplicate prototype.
7624         * tree-ssa-loop.c: Include tree-vectorizer.h.
7625         * Makefile.in (tree-ssa-loop.o): Depend on tree-vectorizer.h.
7626
7627 2009-07-08  Nick Clifton  <nickc@redhat.com>
7628
7629         * config/i386/unix.h (ASM_COMMENT_START): Add a space after the
7630         forward slash.
7631
7632 2009-07-08  DJ Delorie  <dj@redhat.com>
7633
7634         * config/mep/mep-ivc2.cpu (cpmovtocsar0_C3, cpmovtocsar1_C3,
7635         cpmovtocc_C3, cpmovtocsar0_P0S_P1, cpmovtocsar1_P0S_P1,
7636         cpmovtocc_P0S_P1): Mark volatile.  Note which registers are
7637         written to.
7638         * config/mep/intrinsics.md: Regenerated.
7639         * config/mep/mep.c (mep_interrupt_saved_reg): Save IVC2 control
7640         registers when asm() or calls are detected.
7641
7642 2009-07-08  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7643
7644         PR c++/31246
7645         * gimplify.c (gimplify_expr): Propagate no_warning flag when
7646         gimplifying.
7647         * gimple (gimple_build_call_from_tree): Likewise.
7648         * tree-cfg.c (remove_useless_stmts_warn_notreached): Check
7649         no_warning flag before warning.
7650
7651 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7652
7653         * tree.c (set_expr_locus): Remove.
7654         * tree.h (EXPR_LOCUS,SET_EXPR_LOCUS,set_expr_locus): Remove.
7655         * c-typeck.c (c_finish_stmt_expr):  Replace EXPR_LOCUS by
7656         EXPR_LOCATION.
7657         * gimplify.c (internal_get_tmp_var): Likewise.
7658         (gimplify_call_expr): Likewise.
7659         (gimplify_one_sizepos): Likewise.
7660
7661 2009-07-07  Eric Botcazou  <ebotcazou@adacore.com>
7662
7663         PR debug/40666
7664         * dbxout.c (dbxout_symbol) <PARM_DECL>: Deal with parameters pointing
7665         to variables for debugging purposes.
7666
7667 2009-06-23  Mark Loeser  <mark@halcy0n.com>
7668
7669         PR build/40010
7670         * Makefile.in (gcc.pod): Depend on gcc-vers.texi.
7671
7672 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7673
7674         * pretty-print.c (pp_base_format): Remove %J.
7675         * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
7676         gcc_cxxdiag_char_table): Likewise.
7677         (init_dynamic_diag_info): Likewise.
7678
7679 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7680
7681         * pretty-print.c (pp_base_format): Remove %H.
7682         * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
7683         gcc_cxxdiag_char_table): Likewise.
7684         (init_dynamic_diag_info): Likewise.
7685         * config/mep/mep.c (mep_select_section): Likewise.
7686
7687 2009-07-07  Duncan Sands  <baldrick@free.fr>
7688
7689         * final.c (pass_clean_state): Give the pass a name.
7690         * passes.c (pass_rest_of_compilation): Likewise.
7691         * tree-optimize.c (pass_all_optimizations): Likewise.
7692
7693 2009-07-07  H.J. Lu  <hongjiu.lu@intel.com>
7694
7695         * config/ia64/ia64.c (ia64_handle_model_attribute): Remove
7696         an extra 'decl' for error_at.
7697
7698 2009-07-07  Jakub Jelinek  <jakub@redhat.com>
7699
7700         PR middle-end/40669
7701         * tree-tailcall.c (adjust_return_value_with_ops,
7702         create_tailcall_accumulator): Set DECL_GIMPLE_REG_P on the temporary
7703         if it has complex or vector type.
7704
7705 2009-07-07  Olivier Hainque  <hainque@adacore.com>
7706
7707         * config/alpha/t-osf4 (SHLIB_LINK): Do not hide the dummy weak
7708         pthread symbols.
7709
7710 2009-07-07  Basile Starynkevitch  <basile@starynkevitch.net>
7711
7712         * Makefile.in: added more lists of includes to PLUGIN_HEADERS.
7713
7714 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7715
7716         * cgraphunit.c: Replace %J by an explicit location.  Update all calls.
7717         * c-decl.c: Likewise.
7718         * function.c: Likewise.
7719         * varasm.c: Likewise.
7720         * tree-ssa.c: Likewise.
7721         * c-common.c: Likewise.
7722         * tree-cfg.c: Likewise.
7723         * config/spu/spu.c: Likewise.
7724         * config/ia64/ia64.c: Likewise.
7725         * config/v850/v850.c: Likewise.
7726
7727 2009-07-06  DJ Delorie  <dj@redhat.com>
7728
7729         * config/mep/mep-core.cpu (fsft, ssarb): Mark as VOLATILE.
7730         * config/mep/mep-ivc2.cpu (many): Add VOLATILE to more insns that make
7731         unspecified accesses to control registers.
7732         * config/mep/intrinsics.md: Regenerate.
7733         * config/mep/intrinsics.h: Regenerate.
7734         * config/mep/mep-intrin.h: Regenerate.
7735
7736 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7737
7738         * c-lex.c: Replace %H by an explicit location. Update all calls.
7739         * c-common.c: Likewise.
7740         * c-decl.c: Likewise.
7741         * c-typeck.c: Likewise.
7742         * fold-const.c: Likewise.
7743         * gimplify.c: Likewise.
7744         * stmt.c: Likewise.
7745         * tree-cfg.c: Likewise.
7746         * tree-ssa-loop-niter.c: Likewise.
7747         * tree-vrp.c: Likewise.
7748         * value-prof.c: Likewise.
7749
7750 2009-07-06  Diego Novillo  <dnovillo@google.com>
7751
7752         * tree-dfa.c (dump_variable): Write DECL_INITIAL for VAR
7753         if it has one.  Handle cases where VAR does not have an
7754         annotation or cfun is NULL.
7755
7756 2009-07-06  Diego Novillo  <dnovillo@google.com>
7757
7758         * tree.c: Include debug.h.
7759         (initialize_tree_contains_struct): New.
7760         (init_ttree): Call it.
7761         (tree_node_structure_for_code): Factor out of ...
7762         (tree_node_structure): ... here.
7763         * treestruct.def (TS_PHI_NODE): Remove.
7764         (TS_GIMPLE_STATEMENT): Remove.
7765
7766 2009-07-06  Diego Novillo  <dnovillo@google.com>
7767
7768         * tree-pretty-print.c (dump_generic_node): Protect against NULL op0.
7769         (debug_tree_chain): Handle cycles.
7770
7771 2009-07-06  Nick Clifton  <nickc@redhat.com>
7772             DJ Delorie  <dj@redhat.com>
7773
7774         * config.sh/lib1funcs.h (FMOVD_WORKS): Only define if
7775         __FMOVD_ENABLED__ is defined.
7776         * config/sh/sh.h
7777         (TARGET_FMOVD): Provide a default definition.
7778         (MASK_FMOVD): Likewise.
7779         (TARGET_CPU_CPP_BUILTINS): Define
7780         __FMOVD_ENABLED__ if TARGET_FMOVD is true.
7781         * config/sh/sh.md (movdf_i4): For alternative 0 use either one or
7782         two fmov instructions depending upon whether TARGET_FMOVD is enabled.
7783         (split for DF load from memory into register): Also handle
7784         MEMs which consist of REG+DISP addressing.
7785         (split for DF store from register to memory): Likewise.
7786         (movsf_ie): Always use single fp_mode.
7787         * config/sh/sh.c (sh_override_options): Do not automatically
7788         enable TARGET_MOVD for the SH2A when supporting doubles - leave
7789         that to the -mfmovd command line switch.
7790         (broken_move): Do not restrict fldi test to only the SH4 and SH4A.
7791         (fldi_ok): Always allow.
7792         * config/sh/sh.opt (mfmovd): Remove this switch.
7793         * doc/invoke.texi (-mfmovd): Remove documentation of this switch.
7794
7795 2009-07-06  J"orn Rennecke  <joern.rennecke@arc.com>
7796             Kaz Kojima  <kkojima@gcc.gnu.org>
7797
7798         PR rtl-optimization/30807
7799         * postreload.c (reload_combine): For every new use of REG_SUM,
7800         record the use of BASE.
7801
7802 2009-07-06  Jan Hubicka  <jh@suse.cz>
7803
7804         * params.def: Revert my accidental commit at 2009-06-30.
7805
7806 2009-07-04  Ian Lance Taylor  <iant@google.com>
7807
7808         PR target/40636
7809         * config/i386/msformat-c.c (mingw_format_attributes): Declare as
7810         EXPORTED_CONST.
7811         (mingw_format_attribute_overrides): Likewise.
7812
7813 2009-07-04  Jakub Jelinek  <jakub@redhat.com>
7814
7815         PR debug/40596
7816         * dwarf2out.c (based_loc_descr): For crtl->stack_realign_tried
7817         don't check cfa.reg.  Instead of cfa.indirect use
7818         fde && fde->drap_reg != INVALID_REGNUM test.
7819
7820 2009-07-04  Eric Botcazou  <ebotcazou@adacore.com>
7821
7822         * postreload.c (reload_combine): Replace CONST_REG with INDEX_REG.
7823
7824 2009-07-03  Vladimir Makarov  <vmakarov@redhat.com>
7825
7826         PR target/40587
7827         * ira.c (build_insn_chain): Use DF_LR_OUT instead of df_get_live_out.
7828
7829 2009-07-03  Richard Guenther  <rguenther@suse.de>
7830
7831         PR tree-optimization/40640
7832         * tree-switch-conversion.c (build_arrays): Perform arithmetic
7833         in original type.
7834
7835 2009-07-03  Jan Hubicka  <jh@suse.cz>
7836
7837         * ipa-inline.c (cgraph_decide_inlining_incrementally): When optimizing
7838         for size, reduce amount of inlining.
7839
7840 2009-07-03  Richard Guenther  <rguenther@suse.de>
7841
7842         PR middle-end/34163
7843         * tree-chrec.c (chrec_convert_1): Fold (T2)(t +- x) to (T2)t +- (T2)x
7844         if t +- x is known to not overflow and the conversion widens the
7845         operation.
7846         * Makefile.in (tree-chrec.o): Add $(FLAGS_H) dependency.
7847
7848 2009-07-03  Jan Hubicka  <jh@suse.cz>
7849
7850         * ipa-pure-const.c (analyze): Update loop optimizer init.
7851         * tree-ssa-loop-iv-canon.c (empty_loop_p, remove_empty_loop,
7852         try_remove_empty_loop, remove_empty_loops): Remove.
7853         * tree-ssa-loop.c (tree_ssa_empty_loop, pass_empty_loop): Remove.
7854         * tree-ssa-dce.c (find_obviously_necessary_stmts): Use finiteness info
7855         to mark regular loops as neccesary.
7856         (degenerate_phi_p): New function.
7857         (propagate_necessity, remove_dead_phis): Use it.
7858         (forward_edge_to_pdom): Likewise.
7859         (eliminate_unnecessary_stmts): Take care to remove uses of results of
7860         virtual PHI nodes that became unreachable.
7861         (perform_tree_ssa_dce): Initialize/deinitialize loop optimizer.
7862         * tree-flow.h (remove_empty_loops): Remove.
7863         * passes.c (init_optimization_passes): Remove.
7864
7865 2009-07-03  Uros Bizjak  <ubizjak@gmail.com>
7866
7867         * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Use
7868         can_create_pseudo_p.
7869         (*fix_trunc<mode>_i387_1): Ditto.
7870         (*floathi<mode>2_1): Ditto.
7871         (*float<SSEMODEI24:mode><X87MODEF:mode>2_1): Ditto.
7872         (*fistdi2_1): Ditto.
7873         (*fist<mode>2_1): Ditto.
7874         (frndintxf2_floor): Ditto.
7875         (*fist<mode>2_floor_1): Ditto.
7876         (frndintxf2_ceil): Ditto.
7877         (*fist<mode>2_ceil_1): Ditto.
7878         (frndintxf2_trunc): Ditto.
7879         (frndintxf2_mask_pm): Ditto.
7880         (fxam<mode>2_i387_with_temp): Ditto.
7881         * config/i386/sse.md (mulv16qi3): Ditto.
7882         (*sse2_mulv4si3): Ditto.
7883         (mulv2di3): Ditto.
7884         (sse4_2_pcmpestr): Ditto.
7885         (sse4_2_pcmpistr): Ditto.
7886
7887 2009-07-03  Jan Hubicka  <jh@suse.cz>
7888
7889         * tree-ssa-dce.c (bb_contains_live_stmts): New bitmap.
7890         (mark_stmt_necessary): Set it.
7891         (mark_operand_necessary): Set it.
7892         (mark_control_dependent_edges_necessary): Set it.
7893         (mark_virtual_phi_result_for_renaming): New function.
7894         (get_live_post_dom): New function.
7895         (forward_edge_to_pdom): New function.
7896         (remove_dead_stmt): Fix handling of control dependences.
7897         (tree_dce_init): Init new bitmap.
7898         (tree_dce_done): Free it.
7899
7900 2009-07-02  Richard Guenther  <rguenther@suse.de>
7901
7902         PR bootstrap/40617
7903         * tree-ssa-structalias.c (new_var_info): Initialize
7904         is_restrict_var.
7905
7906 2009-07-02  Jan Hubicka  <jh@suse.cz>
7907
7908         * ipa-pure-const.c (check_op): Use PTA info to see if indirect_ref is
7909         local.
7910
7911 2009-07-02  Paolo Bonzini  <bonzini@gnu.org>
7912
7913         * expmed.c (emit_cstore, emit_store_flag_1): Accept target_mode
7914         instead of recomputing it.  Adjust calls.
7915         (emit_store_flag): Adjust recursive calls.
7916
7917 2009-07-02  Richard Guenther  <rguenther@suse.de>
7918
7919         * tree-ssa-live.c (remove_unused_locals): Do not remove
7920         heap variables.
7921         * tree-ssa-structalias.c (handle_lhs_call): Delay setting
7922         of DECL_EXTERNAL for HEAP variables.
7923         (compute_points_to_sets): Set DECL_EXTERNAL for escaped
7924         HEAP variables.  Do not adjust RESTRICT vars.
7925         (find_what_var_points_to): Nobody cares if something
7926         points to READONLY.
7927
7928 2009-07-02  Ben Elliston  <bje@au.ibm.com>
7929
7930         * unwind-dw2-fde-glibc.c (_Unwind_IteratePhdrCallback): Move
7931         pc_low and pc_high declarations to the top of the function.
7932
7933 2009-07-01  DJ Delorie  <dj@redhat.com>
7934
7935         * config/mep/mep.c (mep_handle_option): Leave IVC2 control
7936         registers as fixed.
7937         (mep_interrupt_saved_reg): Save appropriate IVC2 control registers.
7938         * config/mep/mep-ivc2.cpu: Add VOLATILE to insns that make
7939         unspecified accesses to control registers.
7940         * config/mep/intrinsics.md: Regenerate.
7941         * config/mep/intrinsics.h: Regenerate.
7942         * config/mep/mep-intrin.h: Regenerate.
7943
7944 2009-07-01  Anthony Green  <green@moxielogic.com>
7945
7946         * config/moxie/moxie.c (moxie_expand_prologue): Use dec
7947         instruction when possible.
7948         (moxie_expand_prologue): Ditto.  Also, save an instruction and
7949         some complexity by popping off of $r12 instead of $sp.
7950         * config/moxie/moxie.md (movsi_pop): Don't assume $sp.  Take two
7951         operands.
7952
7953 2009-07-01  Richard Henderson  <rth@redhat.com>
7954
7955         PR bootstrap/40347
7956         * function.c (reposition_prologue_and_epilogue_notes): If epilogue
7957         contained no insns, reposition note before last insn.
7958
7959 2009-07-01  Richard Henderson  <rth@redhat.com>
7960
7961         PR debug/40431
7962         * dwarf2out.c (def_cfa_1): Revert 2009-06-11 change for
7963         DW_CFA_def_cfa_offset and DW_CFA_def_cfa.
7964
7965 2009-07-01  Michael Meissner  <meissner@linux.vnet.ibm.com>
7966
7967         PR bootstrap/40558
7968         * config/rs6000/rs6000.c (print_operand): Undo change that breaks
7969         darwin9 for printing reg addresses with %y.
7970
7971 2009-07-01  Adam Nemet  <anemet@caviumnetworks.com>
7972
7973         * combine.c (force_to_mode): Handle TRUNCATE.  Factor out
7974         truncation from operands in binary operations.
7975
7976 2009-07-01  Adam Nemet  <anemet@caviumnetworks.com>
7977
7978         Revert:
7979         2009-01-11  Adam Nemet  <anemet@caviumnetworks.com>
7980         * expmed.c (store_bit_field_1): Properly truncate the paradoxical
7981         subreg of op0 to the original op0.
7982
7983         * expmed.c (store_bit_field_1): Use a temporary as the destination
7984         instead of a paradoxical subreg when we need to truncate the result.
7985
7986 2009-07-01  DJ Delorie  <dj@redhat.com>
7987
7988         * config/mep/mep-ivc2.cpu (cmov, cmovc, cmovh): Add intrinsic
7989         names to VLIW variants.
7990         (ivc2rm, ivc2crn): Make data type consistent with non-VLIW variants.
7991         * config/mep/intrinsics.md: Regenerate.
7992         * config/mep/intrinsics.h: Regenerate.
7993         * config/mep/mep-intrin.h: Regenerate.
7994
7995 2009-07-01  Jakub Jelinek  <jakub@redhat.com>
7996
7997         PR debug/40462
7998         * jump.c (returnjump_p): Revert last patch.
7999         * dwarf2out.c (dwarf2out_begin_epilogue): Handle SEQUENCEs.
8000
8001 2009-07-01  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
8002
8003         PR target/40575
8004         * pa.md (casesi32p): Use jump table label to determine the offset
8005         of the jump table.
8006         (casesi64p): Likewise.
8007
8008         * pa.c (forward_branch_p): Return bool type.  Use instruction
8009         addresses when available.  Assert that INSN has a jump label.
8010         (pa_adjust_insn_length): Don't call forward_branch_p if INSN doesn't
8011         have a jump label.
8012
8013 2009-07-01  Richard Guenther  <rguenther@suse.de>
8014
8015         PR tree-optimization/19831
8016         * tree-ssa-dce.c (propagate_necessity): Calls to functions
8017         that only act as barriers do not make any previous stores necessary.
8018         * tree-ssa-structalias.c (handle_lhs_call): Delay making
8019         HEAP variables global, do not add a constraint from nonlocal.
8020         (find_func_aliases): Handle escapes through return statements.
8021         (compute_points_to_sets): Make escaped HEAP variables global.
8022
8023 2009-07-01  Paolo Bonzini  <bonzini@gnu.org>
8024
8025         PR bootstrap/40597
8026         * expmed.c (emit_store_flag): Perform a conversion if necessary,
8027         after reducing a DImode cstore to SImode.
8028
8029 2009-07-01  Paolo Bonzini  <bonzini@gnu.org>
8030
8031         * expr.c (expand_expr_real_1): Reinstate fallthrough to
8032         TRUTH_ANDIF_EXPR if do_store_flag returns NULL.
8033
8034 2009-07-01  Maciej W. Rozycki  <macro@linux-mips.org>
8035
8036         * config/vax/vax.h (TARGET_BSD_DIVMOD): New macro.  Set to 1.
8037         * config/vax/linux.h (TARGET_BSD_DIVMOD): New macro.  Redefine the
8038         to 0.
8039         * config/vax/vax.c (vax_init_libfuncs): Only redefine udiv_optab
8040         and umod_optab if TARGET_BSD_DIVMOD.
8041         * config/vax/lib1funcs.asm: New file.
8042         * config/vax/t-linux: New file.
8043         * config.gcc (vax-*-linux*): Set tmake_file to vax/t-linux.
8044
8045 2009-06-30  Jakub Jelinek  <jakub@redhat.com>
8046
8047         PR c++/40566
8048         * convert.c (convert_to_integer) <case COND_EXPR>: Don't convert
8049         to type arguments that have void type.
8050
8051         PR debug/40573
8052         * dwarf2out.c (gen_formal_parameter_die): Call
8053         equate_decl_number_to_die if node is different from origin.
8054
8055 2009-06-30  Anthony Green  <green@moxielogic.com>
8056
8057         Clean up moxie port for --enable-build-with-cxx.
8058         * config/moxie/moxie.c (moxie_function_value): First two
8059         parameters are const_tree, not tree.
8060         * config/moxie/moxie.h (enum reg_class): Rename CC_REG to CC_REGS.
8061         (REG_CLASS_NAMES): Ditto.
8062         (REGNO_REG_CLASS): Ditto.
8063         * config/moxie/moxie-protos.h (moxie_override_options): Declare.
8064         (moxie_function_value): Fix constyness of arguments.
8065
8066 2009-06-30  Eric Botcazou  <ebotcazou@adacore.com>
8067
8068         * cgraphunit.c (cgraph_finalize_compilation_unit): Call
8069         finalize_size_functions before further processing.
8070         * stor-layout.c: Include cgraph.h, tree-inline.h and tree-dump.h.
8071         (variable_size): Call self_referential_size on size expressions
8072         that contain a PLACEHOLDER_EXPR.
8073         (size_functions): New static variable.
8074         (copy_self_referential_tree_r): New static function.
8075         (self_referential_size): Likewise.
8076         (finalize_size_functions): New global function.
8077         * tree.c: Include tree-inline.h.
8078         (push_without_duplicates): New static function.
8079         (find_placeholder_in_expr): New global function.
8080         (substitute_in_expr) <tcc_declaration>: Return the replacement object
8081         on equality.
8082         <tcc_expression>: Likewise.
8083         <tcc_vl_exp>: If the replacement object is a constant, try to inline
8084         the call in the expression.
8085         * tree.h (finalize_size_functions): Declare.
8086         (find_placeholder_in_expr): Likewise.
8087         (FIND_PLACEHOLDER_IN_EXPR): New macro.
8088         (substitute_placeholder_in_expr): Update comment.
8089         * tree-inline.c (remap_decl): Do not unshare trees if do_not_unshare
8090         is true.
8091         (copy_tree_body_r): Likewise.
8092         (copy_tree_body): New static function.
8093         (maybe_inline_call_in_expr): New global function.
8094         * tree-inline.h (struct copy_body_data): Add do_not_unshare field.
8095         (maybe_inline_call_in_expr): Declare.
8096         * Makefile.in (tree.o): Depend on TREE_INLINE_H.
8097         (stor-layout.o): Depend on CGRAPH_H, TREE_INLINE_H, TREE_DUMP_H and
8098         GIMPLE_H.
8099
8100 2009-06-30  Richard Guenther  <rguenther@suse.de>
8101
8102         * tree-ssa-dce.c (mark_all_reaching_defs_necessary_1): Always
8103         continue walking.
8104         (propagate_necessity): Do not mark reaching defs of stores
8105         as necessary.
8106
8107 2009-06-30  Jan Hubicka  <jh@suse.cz>
8108
8109         * cfgloopanal.c (check_irred): Move into ...
8110         (mark_irreducible_loops): ... here; return true if ireducible
8111         loops was found.
8112         * ipa-pure-const.c: Include cfgloop.h and tree-scalar-evolution.h
8113         (analyze_function): Try to prove loop finiteness.
8114         * cfgloop.h (mark_irreducible_loops): Update prototype.
8115         * Makefile.in (ipa-pure-const.o): Add dependency on SCEV and CFGLOOP.
8116
8117 2009-06-30  Basile Starynkevitch  <basile@starynkevitch.net>
8118
8119         * Makefile.in (PLUGIN_HEADERS): added ggc, tree-dump, pretty-print.
8120
8121 2009-06-30  Ira Rosen  <irar@il.ibm.com>
8122
8123         PR tree-optimization/40542
8124         * tree-vect-stmts.c (vect_analyze_stmt): Don't vectorize volatile
8125         types.
8126
8127 2009-06-30  Martin Jambor  <mjambor@suse.cz>
8128
8129         PR tree-optimization/40582
8130         * tree-sra.c (build_ref_for_offset_1): Use types_compatible_p rather
8131         than useless_type_conversion_p.
8132         (generate_subtree_copies): Increment sra_stats.subtree_copies at a
8133         proper place.
8134
8135 2009-06-30  Martin Jambor  <mjambor@suse.cz>
8136
8137         PR middle-end/40554
8138         * tree-sra.c (sra_modify_expr): Add access->offset to start_offset.
8139
8140 2009-06-30  Richard Guenther  <rguenther@suse.de>
8141
8142         * tree-ssa-alias.c (walk_aliased_vdefs_1): Change interface to
8143         use ao_ref references.
8144         (walk_aliased_vdefs): Likewise.
8145         * tree-ssa-alias.h (walk_aliased_vdefs): Adjust prototype.
8146         * tree-ssa-dce.c (struct ref_data): Remove.
8147         (mark_aliased_reaching_defs_necessary_1): Use the ao_ref argument.
8148         (mark_aliased_reaching_defs_necessary): Adjust.
8149         (mark_all_reaching_defs_necessary_1): Likewise.
8150
8151 2009-06-30  Paolo Bonzini  <bonzini@gnu.org>
8152
8153         PR boostrap/40597
8154         * expmed.c (emit_cstore): New name of emit_store_flag_1.
8155         (emit_store_flag_1): Extract from emit_store_flag, adjust
8156         calls to (what now is) emit_cstore.
8157         (emit_store_flag): Call emit_store_flag_1 and also use it
8158         for what used to be recursive calls.
8159
8160 2009-06-30  Wei Guozhi  <carrot@google.com>
8161
8162         PR/40416
8163         * tree-ssa-sink.c (statement_sink_location): Stop sinking expression
8164         if the target bb post dominates from bb.
8165         * config/i386/i386.c (memory_address_length): Check existence of base
8166         register before using it.
8167
8168 2009-06-30  Nick Clifton  <nickc@redhat.com>
8169             DJ Delorie  <dj@redhat.com>
8170
8171         * config.sh/lib1funcs.h (FMOVD_WORKS): Only define if
8172         __FMOVD_ENABLED__ is defined.
8173         * config/sh/sh.h
8174         (TARGET_FMOVD): Provide a default definition.
8175         (MASK_FMOVD): Likewise.
8176         (TARGET_CPU_CPP_BUILTINS): Define
8177         __FMOVD_ENABLED__ if TARGET_FMOVD is true.
8178         * config/sh/sh.md (movdf_i4): For alternative 0 use either one or
8179         two fmov instructions depending upon whether TARGET_FMOVD is
8180         enabled.
8181         (split for DF load from memory into register): Also handle
8182         MEMs which consist of REG+DISP addressing.
8183         (split for DF store from register to memory): Likewise.
8184         * config/sh/sh.opt (mfmovd): Remove this switch.
8185         * doc/invoke.texi (-mfmovd): Remove documentation of this switch.
8186         * config/sh/sh.c (sh_override_options): Do not automatically
8187         enable TARGET_MOVD for the SH2A when supporting doubles - leave
8188         that to the -mfmovd command line switch.
8189
8190         * config/sh/sh.c (broken_move): Do not restrict fldi test to only
8191         the SH4 and SH4A.
8192         (fldi_ok): Always allow.
8193         * config/sh/sh.md (movsf_ie): Always use single fp_mode.
8194
8195 2009-06-29  DJ Delorie  <dj@redhat.com>
8196
8197         * doc/install.texi (mep-x-elf): Correct chip's full name.
8198
8199 2009-06-29  H.J. Lu  <hongjiu.lu@intel.com>
8200
8201         * doc/extend.texi: Fix typo.
8202
8203 2009-06-29  Tom Tromey  <tromey@redhat.com>
8204
8205         * dwarf2.h: Remove.
8206         * Makefile.in (DWARF2_H): New variable.
8207         (except.o): Use it.
8208         (dwarf2out.o): Likewise.
8209         (dwarf2asm.o): Likewise.
8210         * config/i386/t-i386: Use DWARF2_H.
8211         * except.c: Include elf/dwarf2.h.
8212         * unwind-dw2.c: Include elf/dwarf2.h.
8213         * dwarf2out.c: Include elf/dwarf2.h.
8214         (dw_loc_descr_struct) <dw_loc_opc>: Now a bitfield.
8215         <dtprel>: New field.
8216         (dwarf_stack_op_name): Don't handle INTERNAL_DW_OP_tls_addr.
8217         (size_of_loc_descr): Likewise.
8218         (output_loc_operands_raw): Likewise.
8219         (output_loc_operands): Handle new dtprel field.
8220         (loc_checksum): Update.
8221         (loc_descriptor_from_tree_1) <VAR_DDECL>: Set dtprel field.
8222         * unwind-dw2-fde-glibc.c: Include elf/dwarf2.h.
8223         * unwind-dw2-fde.c: Include elf/dwarf2.h.
8224         * dwarf2asm.c: Include elf/dwarf2.h.
8225         * unwind-dw2-fde-darwin.c: Include elf/dwarf2.h.
8226         * config/mmix/mmix.c: Include elf/dwarf2.h.
8227         * config/rs6000/darwin-fallback.c: Include elf/dwarf2.h.
8228         * config/xtensa/unwind-dw2-xtensa.c: Include elf/dwarf2.h.
8229         * config/sh/sh.c: Include elf/dwarf2.h.
8230         * config/i386/i386.c: Include elf/dwarf2.h.
8231
8232 2009-06-29  DJ Delorie  <dj@redhat.com>
8233
8234         * config/mep/mep.h (CPP_SPEC): Remove __cop macro.
8235
8236         * doc/extend.texi: Add MeP attributes and pragmas.
8237         * doc/invoke.text: Add MeP Options.
8238         * doc/contrib.texi: Add MeP contribution.
8239         * doc/md.texi: Add MeP constraints.
8240         * doc/install.texi: Add MeP target.
8241
8242 2009-06-30  Anatoly Sokolov  <aesok@post.ru>
8243
8244         * target.h (struct gcc_target): Add frame_pointer_required field.
8245         * target-def.h (TARGET_FRAME_POINTER_REQUIRED): New.
8246         (TARGET_INITIALIZER): Use TARGET_FRAME_POINTER_REQUIRED.
8247         * ira.c (setup_eliminable_regset): Use frame_pointer_required target
8248         hook.
8249         * reload1.c (update_eliminables): (Ditto.).
8250         * gcc/system.h (FRAME_POINTER_REQUIRED): Poison.
8251         * doc/tm.texi (FRAME_POINTER_REQUIRED): Revise documentation.
8252         (INITIAL_FRAME_POINTER_OFFSET): (Ditto.).
8253
8254         * config/arc/arc.h (FRAME_POINTER_REQUIRED): Remove macro.
8255
8256         * config/arm/arm.h (FRAME_POINTER_REQUIRED): Remove macro.
8257         * config/arm/arm.c (TARGET_FRAME_POINTER_REQUIRED): Define.
8258         (arm_frame_pointer_required): New function.
8259
8260         * config/avr/avr.h (FRAME_POINTER_REQUIRED): Remove macro.
8261         * config/avr/avr.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
8262         (avr_frame_pointer_required_p): Declare as static.
8263         * config/avr/avr-protos.h (avr_frame_pointer_required_p): Remove.
8264
8265         * config/bfin/bfin.h (FRAME_POINTER_REQUIRED): Remove macro.
8266         * config/bfin/bfin.c (TARGET_FRAME_POINTER_REQUIRED): Define.
8267         (bfin_frame_pointer_required): Make as static, change return type
8268         to bool.
8269         * config/bfin/bfin-protos.h (bfin_frame_pointer_required): Remove.
8270
8271         * config/cris/cris.h (FRAME_POINTER_REQUIRED): Remove macro.
8272         * config/cris/cris.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
8273         (cris_frame_pointer_required): New function.
8274
8275         * config/crx/crx.h (FRAME_POINTER_REQUIRED): Remove macro.
8276
8277         * config/fr30/fr30.h (FRAME_POINTER_REQUIRED): Remove macro.
8278         * config/fr30/fr30.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
8279         (fr30_frame_pointer_required): New function.
8280
8281         * config/frv/frv.h (FRAME_POINTER_REQUIRED): Remove macro.
8282         * config/frv/frv.c (TARGET_FRAME_POINTER_REQUIRED): Define.
8283         (frv_frame_pointer_required): Make as static, change return type
8284         to bool.
8285         * config/bfin/bfin-protos.h (frv_frame_pointer_required): Remove.
8286
8287         * config/i386/i386.h (FRAME_POINTER_REQUIRED): Remove macro.
8288         * config/i386/i386.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
8289         (ix86_frame_pointer_required): Make as static, change return type to
8290         bool.
8291         * config/i386/i386-protos.h (ix86_frame_pointer_required): Remove.
8292
8293         * config/m32c/m32c.h (FRAME_POINTER_REQUIRED): Remove macro.
8294         * config/m32c/m32c.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
8295
8296         * config/m32r/m32r.h (FRAME_POINTER_REQUIRED): Remove macro.
8297
8298         * config/mcore/mcore.h (CAN_ELIMINATE): Remove macro.
8299
8300         * config/mep/mep.h (FRAME_POINTER_REQUIRED): Remove macro.
8301
8302         * config/mips/mips.h (FRAME_POINTER_REQUIRED): Remove macro.
8303         * config/mips/mips.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
8304         (mips_frame_pointer_required): Make as static.
8305         * config/mips/mips-protos.h (mips_frame_pointer_required): Remove.
8306
8307         * config/mmix/mmix.h (FRAME_POINTER_REQUIRED): Remove macro.
8308         * config/mmix/mmix.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
8309         (mmix_frame_pointer_required): Mew function.
8310
8311         * config/moxie/moxie.h (FRAME_POINTER_REQUIRED): Remove macro.
8312         * config/moxie/moxie.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
8313
8314         * config/pa/pa.h (FRAME_POINTER_REQUIRED): Remove macro.
8315
8316         * config/score/score.h (FRAME_POINTER_REQUIRED): Remove macro.
8317
8318         * config/sh/sh.h (CAN_ELIMINATE): Remove macro.
8319
8320         * config/sparc/sparc.h (FRAME_POINTER_REQUIRED): Remove macro.
8321         (CAN_ELIMINATE): Redefine.
8322         * config/sparc/sparc.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
8323         (sparc_frame_pointer_required): New function.
8324         (sparc_can_eliminate): New function.
8325         * config/sparc/sparc-protos.h (sparc_can_eliminate): Declare.
8326
8327         * config/vax/vax.h (FRAME_POINTER_REQUIRED): Remove macro.
8328         * config/vax/vax.c (TARGET_FRAME_POINTER_REQUIRED): Define.
8329
8330         * config/xtensa/xtensa.h (FRAME_POINTER_REQUIRED): Remove macro.
8331         * config/xtensa/xtensa.c (TARGET_FRAME_POINTER_REQUIRED): Define.
8332         (xtensa_frame_pointer_required): Make as static, change return type
8333         to bool.
8334         * config/xtensa/xtensa-protos.h (xtensa_frame_pointer_required):
8335         Remove.
8336
8337 2009-06-29  Olatunji Ruwase  <tjruwase@google.com>
8338
8339         * doc/plugins.texi: Document PLUGIN_START_UNIT.
8340         * toplev.c (compile_file): Call PLUGIN_START_UNIT.
8341         * gcc-plugin.h (PLUGIN_START_UNIT): Added new event.
8342         * plugin.c (plugin_event_name): Added PLUGIN_START_UNIT.
8343         (register_callback): Handle PLUGIN_START_UNIT.
8344         (invoke_plugin_callbacks): Handle PLUGIN_START_UNIT.
8345
8346 2009-06-29  Eric Botcazou  <ebotcazou@adacore.com>
8347
8348         * tree.c (process_call_operands): Propagate TREE_READONLY from the
8349         operands.
8350         (PROCESS_ARG): Do not clear TREE_READONLY if CONSTANT_CLASS_P.
8351         (build3_stat): Propagate TREE_READONLY for COND_EXPR.
8352
8353 2009-06-29  Daniel Jacobowitz  <dan@codesourcery.com>
8354
8355         * config/arm/arm.h (REGISTER_MOVE_COST): Increase VFP register
8356         move cost.
8357
8358 2009-06-29  Uros Bizjak  <ubizjak@gmail.com>
8359
8360         * doc/extend.texi (Additional Floating Types): __float128 is also
8361         supported on i386 targets.
8362
8363 2009-06-29  Richard Guenther  <rguenther@suse.de>
8364
8365         PR middle-end/14187
8366         * tree-ssa-alias.h (struct pt_solution): Add vars_contains_restrict
8367         flag.
8368         (pt_solutions_same_restrict_base): Declare.
8369         * tree-ssa-structalias.c (struct variable_info): Add is_restrict_var
8370         flag.
8371         (new_var_info): Initialize is_global_var properly for SSA_NAMEs.
8372         (make_constraint_from, make_copy_constraint): Move earlier.
8373         (make_constraint_from_heapvar): New function.
8374         (make_constraint_from_restrict): Likewise.
8375         (handle_lhs_call): Use it.
8376         (find_func_aliases): Use it to track conversions to restrict
8377         qualified pointers.
8378         (struct fieldoff): Add only_restrict_pointers flag.
8379         (push_fields_onto_fieldstack): Initialize it.
8380         (create_variable_info_for): Track global restrict qualified pointers.
8381         (intra_create_variable_infos): Use make_constraint_from_heapvar.
8382         Track restrict qualified pointer arguments.
8383         (set_uids_in_ptset): Use varinfo is_global_var flag.
8384         (find_what_var_points_to): Set the vars_contains_restrict flag.
8385         Always create the points-to solution for sets including restrict tags.
8386         (pt_solutions_same_restrict_base): New function.
8387         * tree-ssa-alias.c (ptr_derefs_may_alias_p): For two restrict
8388         qualified pointers use pt_solutions_same_restrict_base as
8389         additional source for disambiguation.
8390
8391 2009-06-29  Richard Guenther  <rguenther@suse.de>
8392
8393         PR middle-end/38212
8394         * alias.c (find_base_decl): Remove.
8395         (get_deref_alias_set_1): Remove restrict handling.
8396         * c-common.c (c_apply_type_quals_to_decl): Do not set
8397         DECL_POINTER_ALIAS_SET.
8398         * gimplify.c (find_single_pointer_decl_1): Remove.
8399         (find_single_pointer_decl): Likewise.
8400         (internal_get_tmp_var): Remove restrict handling.
8401         (gimple_regimplify_operands): Likewise.
8402         * omp-low.c (expand_omp_atomic_pipeline): Do not set
8403         DECL_POINTER_ALIAS_SET. Use ref-all pointers.
8404         * print-tree.c (print_node): Do not print DECL_POINTER_ALIAS_SET.
8405         * tree.c (restrict_base_for_decl): Remove.
8406         (init_ttree): Do not allocate it.
8407         (make_node_stat): Do not set DECL_POINTER_ALIAS_SET.  Set
8408         LABEL_DECL_UID for label decls.
8409         (copy_node_stat): Do not copy restrict information.
8410         (decl_restrict_base_lookup): Remove.
8411         (decl_restrict_base_insert): Likewise.
8412         (print_restrict_base_statistics): Likewise.
8413         (dump_tree_statistics): Do not call print_restrict_base_statistics.
8414         * tree.h (DECL_POINTER_ALIAS_SET): Remove.
8415         (DECL_POINTER_ALIAS_SET_KNOWN_P): Likewise.
8416         (struct tree_decl_common): Rename pointer_alias_set to label_decl_uid.
8417         (LABEL_DECL_UID): Adjust.
8418         (DECL_BASED_ON_RESTRICT_P): Remove.
8419         (DECL_GET_RESTRICT_BASE): Likewise.
8420         (SET_DECL_RESTRICT_BASE): Likewise.
8421         (struct tree_decl_with_vis): Remove based_on_restrict_p flag.
8422
8423         * config/i386/i386.c (ix86_gimplify_va_arg): Use ref-all pointers
8424         instead of DECL_POINTER_ALIAS_SET.
8425         * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Likewise.
8426         * config/s390/s390.c (s390_gimplify_va_arg): Likewise.
8427         * config/spu/spu.c (spu_gimplify_va_arg_expr): Likewise.
8428
8429 2009-06-29  Richard Guenther  <rguenther@suse.de>
8430
8431         PR tree-optimization/40579
8432         * tree-vrp.c (vrp_evaluate_conditional): Bail out early if
8433         the IL to simplify has constants that overflowed.
8434
8435 2009-06-28  Uros Bizjak  <ubizjak@gmail.com>
8436
8437         PR tree-optimization/40550
8438         * tree-vect-generic.c (expand_vector_operations_1): Compute in
8439         vector_compute_type only when the size of vector_compute_type is
8440         less than the size of type.
8441
8442 2009-06-28  Eric Botcazou  <ebotcazou@adacore.com>
8443
8444         * fold-const.c (contains_label_1): Fix comments.
8445         (contains_label_p): Do not walk trees multiple time.
8446
8447 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
8448
8449         * config/i386/i386.h (enum ix86_fpcmp_strategy): New.
8450         * config/i386/i386.md (cbranchxf4, cstorexf4, cbranch<MODEF>4,
8451         cstore<MODEF>4, mov<X87MODEF>cc): Change predicate to
8452         ix86_fp_comparison_operator.
8453         (*fp_jcc_1_mixed, *fp_jcc_1_sse, *fp_jcc_1_387, *fp_jcc_2_mixed,
8454         *fp_jcc_2_sse, *fp_jcc_2_387): Delete
8455         (*fp_jcc_3_387, *fp_jcc_4_387, *fp_jcc_5_387, *fp_jcc_6_387,
8456         *fp_jcc_7_387, *fp_jcc_8<MODEF>_387): Eliminate call to
8457         !ix86_use_fcomi_compare, change ix86_fp_jump_nontrivial_p call
8458         to !TARGET_CMOVE, change predicate to ix86_fp_comparison_operator.
8459         (related splits): Change predicate to ix86_fp_comparison_operator.
8460         * config/i386/predicates.md: Use ix86_trivial_fp_comparison_operator
8461         instead of ix86_fp_comparison_codes.
8462         (ix86_trivial_fp_comparison_operator,
8463         ix86_fp_comparison_operator): New.
8464         * config/i386/i386-protos.h (ix86_fp_comparison_strategy): New.
8465         (ix86_expand_compare): Eliminate last two parameters.
8466         (ix86_fp_jump_nontrivial_p): Kill.
8467         * config/i386/i386.c (put_condition_code): Eliminate call to
8468         ix86_fp_comparison_codes and subsequent assertion.
8469         (ix86_fp_comparison_codes): Eliminate.
8470         (ix86_fp_swap_condition): New.
8471         (ix86_fp_comparison_arithmetics_cost, ix86_fp_comparison_fcomi_cost,
8472         ix86_fp_comparison_sahf_cost, ix86_use_fcomi_compare): Consolidate
8473         into ix86_fp_comparison_cost and ix86_fp_comparison_strategy.
8474         (ix86_prepare_fp_compare_args): Use ix86_fp_comparison_strategy
8475         and ix86_fp_swap_condition.
8476         (ix86_expand_fp_compare): Eliminate code for second jump/bypass jump.
8477         Use ix86_fp_comparison_strategy.
8478         (ix86_expand_compare): Likewise.  Eliminate last two arguments.
8479         (ix86_fp_jump_nontrivial_p): Eliminate.
8480         (ix86_expand_branch): Treat SFmode/DFmode/XFmode as simple.  Adjust
8481         call to ix86_expand_compare.
8482         (ix86_split_fp_branch, ix86_expand_setcc,
8483         ix86_expand_carry_flag_compare, ix86_expand_int_movcc,
8484         ix86_expand_fp_movcc): Eliminate code for second jump/bypass jump.
8485
8486 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
8487
8488         * config/arm/arm.c (arm_final_prescan_ins): Eliminate code
8489         related to jump_clobbers.
8490         * config/arm/arm.md (conds): Remove jump_clob case.
8491         (addsi3_cbranch, addsi3_cbranch_scratch, subsi3_cbranch, two
8492         splits): Change comparison_operator to arm_comparison_operator.
8493         (*arm_buneq, *arm_bltgt, *arm_buneq_reversed, *arm_bltgt_reversed):
8494         Eliminate.
8495
8496 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
8497
8498         * dojump.c (do_compare_rtx_and_jump): Try swapping the
8499         condition for floating point modes.
8500         * expmed.c (emit_store_flag_1): Move here a bigger part
8501         of emit_store_flag.
8502         (emit_store_flag): Try swapping the condition for floating point
8503         modes.
8504         * optabs.c (emit_cmp_and_jump_insns): Cope with constant op0 better.
8505
8506 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
8507
8508         * expr.c (expand_expr_real_1): Just use do_store_flag.
8509         (do_store_flag): Drop support for TRUTH_NOT_EXPR.  Use
8510         emit_store_flag_force.
8511         * expmed.c (emit_store_flag_force): Copy here trick
8512         previously in expand_expr_real_1.  Try reversing the comparison.
8513         (emit_store_flag_1): Work if target is NULL.
8514         (emit_store_flag): Work if target is NULL, using the result mode
8515         from the comparison.  Use split_comparison, restructure final part
8516         to simplify conditionals.
8517
8518 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
8519
8520         * builtins.c (expand_errno_check): Use do_compare_rtx_and_jump.
8521         * dojump.c (do_jump): Change handling of floating-point
8522         ops to use just do_compare_and_jump.
8523         (split_comparison): New.
8524         (do_compare_rtx_and_jump): Add here logic coming previously
8525         in do_jump, using split_comparison.
8526
8527 2009-06-27  H.J. Lu  <hongjiu.lu@intel.com>
8528
8529         PR target/40489
8530         * config/ia64/ia64.c (ia64_reorg): Check NULL insn.
8531
8532 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
8533
8534         * tree-ssa-alias.c: Fix unintentional commit.
8535
8536 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
8537
8538         * passes.c (execute_one_pass): Fix unintentional commit.
8539
8540 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
8541
8542         * df-problems.c (df_set_seen, df_unset_seen): Delete.
8543         (df_rd_local_compute, df_md_local_compute): Inline them.
8544
8545         (df_md_scratch): New.
8546         (df_md_alloc, df_md_free): Allocate/free it.
8547         (df_md_local_compute): Only include live registers in init.
8548         (df_md_transfer_function): Prune the in-set computed by
8549         the confluence function, and the gen-set too.
8550
8551 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
8552
8553         PR rtl-optimization/26854
8554         * timevar.def: Remove TV_DF_RU, add TV_DF_MD.
8555         * df-problems.c (df_rd_add_problem): Fix comment.
8556         (df_md_set_bb_info, df_md_free_bb_info, df_md_alloc,
8557         df_md_simulate_artificial_defs_at_top,
8558         df_md_simulate_one_insn, df_md_bb_local_compute_process_def,
8559         df_md_bb_local_compute, df_md_local_compute, df_md_reset,
8560         df_md_transfer_function, df_md_init, df_md_confluence_0,
8561         df_md_confluence_n, df_md_free, df_md_top_dump, df_md_bottom_dump,
8562         problem_MD, df_md_add_problem): New.
8563         * df.h (DF_MD, DF_MD_BB_INFO, struct df_md_bb_info, df_md,
8564         df_md_get_bb_info): New.
8565         (DF_LAST_PROBLEM_PLUS1): Adjust.
8566
8567         * Makefile.in (fwprop.o): Include domwalk.h.
8568         * fwprop.c: Include domwalk.h.
8569         (reg_defs, reg_defs_stack): New.
8570         (bitmap_only_bit_between): Remove.
8571         (process_defs): New.
8572         (process_uses): Use reg_defs and local_md instead of
8573         bitmap_only_bit_between and local_rd.
8574         (single_def_use_enter_block): New, from build_single_def_use_links.
8575         (single_def_use_leave_block): New.
8576         (build_single_def_use_links): Remove code moved to
8577         single_def_use_enter_block, invoke domwalk.
8578         (use_killed_between): Adjust comment.
8579
8580 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
8581
8582         * bitmap.h (bitmap_ior_and_into): New.
8583         * bitmap.c (bitmap_ior_and_into): New.
8584
8585 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
8586
8587         * domwalk.h (struct dom_walk_data): Remove all callbacks except
8588         before_dom_children_before_stmts and after_dom_children_after_stmts.
8589         Rename the two remaining callbacks to just before_dom_children and
8590         after_dom_children. Remove other GIMPLE statement walking bits.
8591         * domwalk.c (walk_dominator_tree): Remove now unsupported features.
8592         * graphite.c: Do not include domwalk.h.
8593         * tree-into-ssa.c (interesting_blocks): New global.
8594         (struct mark_def_sites_global_data): Remove it and names_to_rename.
8595         (mark_def_sites, rewrite_stmt, rewrite_add_phi_arguments,
8596         rewrite_update_stmt, rewrite_update_phi_arguments): Simplify
8597         now that they're not domwalk callbacks.
8598         (rewrite_initialize_block): Rename to...
8599         (rewrite_enter_block): ... this, place after called functions.  Test
8600         interesting_blocks, call rewrite_stmt and rewrite_add_phi_arguments.
8601         (rewrite_finalize_block): Rename to...
8602         (rewrite_leave_block): ... this, place after called functions.
8603         (rewrite_update_init_block): Rename to...
8604         (rewrite_update_enter_block): ... this, place after called functions.
8605         Test interesting_blocks, call rewrite_update_stmt and
8606         rewrite_update_phi_arguments.
8607         (rewrite_update_fini_block): Rename to...
8608         (rewrite_leave_block): ... this, place after called functions.
8609         (rewrite_blocks): Remove last argument, simplify initialization of
8610         walk_data.
8611         (mark_def_sites_initialize_block): Rename to...
8612         (mark_def_sites_block): ... this, call mark_def_sites.
8613         (mark_def_sites_blocks): Remove argument, simplify initialization of
8614         walk_data.
8615         (rewrite_into_ssa): Adjust for interesting_blocks_being a global.
8616         (update_ssa): Likewise.
8617         * tree-ssa-dom.c (optimize_stmt): Simplify now that it's not a domwalk
8618         callback.
8619         (tree_ssa_dominator_optimize): Simplify initialization of walk_data.
8620         (dom_opt_initialize_block): Rename to...
8621         (dom_opt_enter_block): ... this, place after called functions.  Walk
8622         statements here, inline propagate_to_outgoing_edges.
8623         (dom_opt_finalize_block): Rename to...
8624         (dom_opt_leave_block): ... this, place after called functions.
8625         * tree-ssa-dse.c (dse_optimize_stmt): Simplify now that it's not a
8626         domwalk callback.
8627         (dse_enter_block, dse_record_phi): New.
8628         (dse_record_phis): Delete.
8629         (dse_finalize_block): Rename to...
8630         (dse_leave_block): ... this.
8631         (tree_ssa_dse): Simplify initialization of walk_data.
8632         * tree-ssa-loop-im.c (determine_invariantness, move_computations):
8633         Adjust initialization of walk_data.
8634         * tree-ssa-loop-unswitch.c: Do not include domwalk.h.
8635         * tree-ssa-loop-phiopt.c (get_non_trapping):
8636         Adjust initialization of walk_data.
8637         * tree-ssa-loop-threadedge.c: Do not include domwalk.h.
8638         * tree-ssa-uncprop.c (uncprop_into_successor_phis): Simplify now that
8639         it's not a domwalk callback.
8640         (uncprop_initialize_block): Rename to...
8641         (dse_enter_block): ... this, call uncprop_into_successor_phis.
8642         (dse_finalize_block): Rename to...
8643         (dse_leave_block): ... this.
8644         (tree_ssa_uncprop): Simplify initialization of walk_data.
8645         * Makefile.in: Adjust dependencies.
8646
8647 2009-06-27  Richard Earnshaw  <rearnsha@arm.com>
8648
8649         * arm.md (casesi): Fix test for Thumb1.
8650         (thumb1_casesi_internal_pic): Likewise.
8651         (thumb1_casesi_dispatch): Likewise.
8652
8653 2009-06-26  Daniel Gutson  <dgutson@codesourcery.com>
8654
8655         * config/arm/arm-cores.def: Added core cortex-m0.
8656         * config/arm/arm-tune.md: Regenerated.
8657         * doc/invoke.texi: Added entry for cpu ARM Cortex-M0.
8658
8659 2009-06-26  DJ Delorie  <dj@redhat.com>
8660
8661         * config/mep/mep.opt (mfar): Remove -mfar as it doesn't do anything.
8662
8663         * config/mep/mep.c (mep_bundle_insns): Account for the fact that
8664         the scheduler doesn't tag jump insns.
8665
8666 2009-06-26  H.J. Lu  <hongjiu.lu@intel.com>
8667
8668         * c-decl.c (merge_decls): Re-indent.
8669
8670 2009-06-26  Janis Johnson  <janis187@us.ibm.com>
8671
8672         PR c/39902
8673         * tree.c (real_zerop, real_onep, real_twop, real_minus_onep):
8674         Special-case decimal float constants.
8675
8676 2009-06-26  Richard Henderson  <rth@redhat.com>
8677
8678         * function.h (struct function): Add cannot_be_copied_reason,
8679         and cannot_be_copied_set.
8680         * tree-inline.c (has_label_address_in_static_1): Rename from
8681         inline_forbidden_p_2; don't set inline_forbidden_reason here.
8682         (cannot_copy_type_1): Rename from inline_forbidden_p_op; likewise
8683         don't set inline_forbidden_reason.
8684         (copy_forbidden): New function, split out of inline_forbidden_p.
8685         (inline_forbidden_p_stmt): Don't check for nonlocal labels here.
8686         (inline_forbidden_p): Use copy_forbidden.
8687         (tree_versionable_function_p): Likewise.
8688         (inlinable_function_p): Merge into tree_inlinable_function_p.
8689         (tree_function_versioning): Remap cfun->nonlocal_goto_save_area.
8690         * ipa-cp.c (ipcp_versionable_function_p): New function.
8691         (ipcp_cloning_candidate_p): Use it.
8692         (ipcp_node_modifiable_p): Likewise.
8693
8694 2009-06-26  Olatunji Ruwase  <tjruwase@google.com>
8695
8696         * builtins.c (expand_builtin_alloca): Handle builtin alloca
8697         that is marked not to be inlined. Remove flag_mudflap use.
8698         * tree-mudflap.c: Rename mf_xform_derefs to mf_xfrom_statements.
8699         (mf_xform_statements): Mark builtin alloca calls as un-inlineable.
8700
8701 2009-06-26  Steve Ellcey  <sje@cup.hp.com>
8702
8703         PR bootstrap/40338
8704         * config/pa/t-pa-hpux10 (TARGET_LIBGCC2_CFLAGS): Add -frandom-seed.
8705         * config/pa/t-pa-hpux11 (TARGET_LIBGCC2_CFLAGS): Ditto.
8706
8707 2009-06-26  Kai Tietz  <kai.tietz@onevision.com>
8708
8709         * config/i386/mingw-tls.c (__mingwthr_key_dtor): Remove for none
8710         shared libgcc.
8711         (__mingwthr_remove_key_dtor): Likewise.
8712
8713 2009-06-26  Richard Guenther  <rguenther@suse.de>
8714
8715         * tree-ssa-structalias.c (do_ds_constraint): Simplify escape handling.
8716
8717 2009-06-26  Steven Bosscher  <steven@gcc.gnu.org>
8718
8719         PR middle-end/40525
8720         * ifcvt.c (dead_or_predicable): If predicating MERGE_BB fails,
8721         try the non-cond_exec path also.
8722
8723 2009-06-25  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
8724
8725         PR target/40468
8726         * pa.c (branch_to_delay_slot_p, branch_needs_nop_p): New functions.
8727         (output_cbranch): Use new functions.
8728         (output_lbranch, output_bb, output_bvb, output_dbra, output_movb):
8729         Likewise.
8730
8731 2009-06-25  Michael Meissner  <meissner@linux.vnet.ibm.com>
8732             Pat Haugen  <pthaugen@us.ibm.com>
8733             Revital Eres <ERES@il.ibm.com>
8734
8735         * config/rs6000/rs6000.c (print_operand): Correct lossage message
8736         for %c error.  Add %x support to print VSX registers as a unified
8737         register set, instead of separate float and altivec registers.
8738         Switch to use VECTOR_MEM_ALTIVEC_P instead of TARGET_ALTIVEC for
8739         %y case, and add support for VSX pre-modify addresses.
8740         (output_toc): Add assert for CONST containing an integer constant
8741         in the PLUS case.
8742         (rs6000_adjust_cost): Add POWER7 support.
8743         (insn_must_be_first_in_group): Ditto.
8744         (insn_must_be_last_in_group): Ditto.
8745         (rs6000_emit_popcount): Ditto.
8746         (rs6000_vector_mode_supported_p): Ditto.
8747
8748         * config/rs6000/rs6000-protos.h (rs6000_secondary_reload_class):
8749         Change some of the functions called by macros to being called
8750         through a pointer, so debug functions can be inserted if
8751         -mdebug=addr or -mdebug=cost.
8752         (rs6000_preferred_reload_class_ptr): Ditto.
8753         (rs6000_secondary_reload_class_ptr): Ditto.
8754         (rs6000_secondary_memory_needed_ptr): Ditto.
8755         (rs6000_cannot_change_mode_class_ptr): Ditto.
8756         (rs6000_secondary_reload_inner): Ditto.
8757         (rs6000_legitimize_reload_address): Ditto.
8758         (rs6000_legitimize_reload_address_ptr): Ditto.
8759         (rs6000_mode_dependent_address): Ditto.
8760         (rs6000_mode_dependent_address_ptr): Ditto.
8761
8762         * config/rs6000/rs6000.c (reg_offset_addressing_ok_p): New
8763         function to return true if the mode allows reg + integer
8764         addresses.
8765         (virtual_stack_registers_memory_p): New function to return true if
8766         the address refers to a virtual stack register.
8767         (rs6000_legitimate_offset_address_p): Move code to say whether a
8768         mode supports reg+int addressing to reg_offset_addressing_ok_p and
8769         call it.
8770         (rs6000_legitimate_address_p): Add checks for modes that only can
8771         do reg+reg addressing.  Start adding VSX support.
8772         (rs6000_legitimize_reload_address): Ditto.
8773         (rs6000_legitimize_address): Ditto.
8774         (rs6000_debug_legitimate_address_p): New debug functions for
8775         -mdebug=addr and -mdebug=cost.
8776         (rs6000_debug_rtx_costs): Ditto.
8777         (rs6000_debug_address_costs): Ditto.
8778         (rs6000_debug_adjust_cost): Ditto.
8779         (rs6000_debug_legitimize_address): Ditto.
8780         (rs6000_legitimize_reload_address_ptr): Point to call normal
8781         function or debug function.  Make functions called via pointer
8782         static.
8783         (rs6000_mode_dependent_address_ptr): Ditto.
8784         (rs6000_secondary_reload_class_ptr): Ditto.
8785         (rs6000_hard_regno_mode_ok): Add preliminary VSX support.
8786         (rs6000_emit_move): Add -mdebug=addr support.  Change an abort
8787         into a friendlier error.
8788         (rs6000_init_builtins): Add initial VSX support.
8789         (rs6000_adjust_cost): Fix some spacing issues.
8790
8791         * config/rs6000/rs6000.h (enum reg_class): Add VSX_REGS.
8792         (REG_CLASS_NAMES): Ditto.
8793         (REG_CLASS_CONTENTS): Ditto.
8794         (PREFERRED_RELOAD_CLASS): Move from a macro to calling through a
8795         pointer, to add -mdebug=addr support.
8796         (CANNOT_CHANGE_MODE_CLASS): Ditto.
8797         (SECONDARY_RELOAD_CLASS): Call through a pointer to add
8798         -mdebug=addr support.
8799         (LEGITIMIZE_RELOAD_ADDRESS): Ditto.
8800         (GO_IF_MODE_DEPENDENT_ADDRESS): Ditto.
8801         (enum rs6000_builtins): Add RS6000_BUILTIN_BSWAP_HI.
8802
8803         * config/rs6000/rs6000.md (bswaphi*): Add support for swapping
8804         16-bit values.
8805         (bswapsi*): Set attribute types for load/store.  Add combiner
8806         patterns to eliminate zero extend on 64-bit.
8807         (bswapdi*): Add support for swapping 64-bit values.  Use ldbrx and
8808         stdbrx if the hardware supports those instructions.
8809
8810 2009-06-25  Ian Lance Taylor  <iant@google.com>
8811
8812         * doc/invoke.texi (Option Summary): Mention -static-libstdc++.
8813         (Link Options): Document -static-libstdc++.
8814
8815 2009-06-25  Andrew Pinski  <andrew_pinski@playstation.sony.com>
8816
8817         PR target/38731
8818         * config/rs6000/rs6000.c (LOCAL_ALIGNMENT): Redefine to just use
8819         DATA_ALIGNMENT instead.
8820
8821 2009-06-25  Richard Guenther  <rguenther@suse.de>
8822
8823         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Disambiguate
8824         indirect references against the callused/escaped solutions.
8825         (call_may_clobber_ref_p_1): Likewise.
8826
8827 2009-06-25  Martin Jambor  <mjambor@suse.cz>
8828
8829         PR tree-optimization/40493
8830         * tree-sra.c (sra_modify_expr): Correct BIT_FIELD_REF argument numbers.
8831         (enum unscalarized_data_handling): New type.
8832         (handle_unscalarized_data_in_subtree): Return what has been done.
8833         (load_assign_lhs_subreplacements): Handle left flushes differently.
8834         (sra_modify_assign): Use unscalarized_data_handling, simplified
8835         condition determining whether to remove the statement.
8836
8837 2009-06-25  Basile Starynkevitch  <basile@starynkevitch.net>
8838
8839         * doc/plugins.texi (Building GCC plugins): Correct typo in Makefile
8840         excerpt - @ should be doubled for texinfo.
8841
8842 2009-06-24  Ian Lance Taylor  <iant@google.com>
8843
8844         * config/arc/arc.c: Include "df.h".
8845         (arc_attribute_table): Make static.  Move higher in file.
8846         (arc_address_cost): Call SMALL_INT on INTVAL, not rtx.
8847         (output_shift): Initialize n later to avoid warning.
8848         * config/arm/arm.c (arm_attribute_table): Make static.  Move
8849         higher in file.
8850         * config/avr/avr.c (avr_attribute_table): Make static.  Move
8851         higher in file.
8852         (reg_class_tab): Change array type from int to enum reg_class.
8853         (avr_jump_mode): Change GET_MODE to GET_CODE when checking for
8854         LABEL_REF.
8855         (out_tsthi, ashlhi3_out): Don't use AS2 with "or" or "and".
8856         (lshrhi3_out): Likewise.
8857         (class_likely_spilled_p): Change return type to bool.
8858         (avr_rtx_costs): Use local code variable with enum type.
8859         * config/avr/avr.md (movmemhi): Use add_reg_note.
8860         (andhi3, andsi3): Don't use AS2 with "and".
8861         (iorhi3, iorsi3): Don't use AS2 with "or".
8862         * config/avr/avr-protos.h (class_likely_spilled_p): Update declaration.
8863         * config/crx/crx.c: Include "df.h".
8864         (crx_attribute_table): Make static.
8865         * config/m32r/m32r.c: Include "df.h".
8866         (m32r_attribute_table): Make static.  Move higher in file.
8867         (pop): Use add_reg_note.
8868         (block_move_call): Change 0 to LCT_NORMAL in function call.
8869         * config/m32r/m32r.md (movsi_insn): Remove unused local value.
8870         * config/m32r/m32r.h (INITIALIZE_TRAMPOLINE): Likewise.
8871         * config/m32r/m32r-protos.h (m32r_compute_function_type): Always
8872         declare, not just when TREE_CODE is defined.
8873         * config/m68hc11/m68hc11.c: Include "expr.h".
8874         (m68hc11_attribute_table): Make static.  Move higher in file.
8875         (m68hc11_small_indexed_indirect_p): Change 0 to VOIDmode in
8876         function call.
8877         (m68hc11_register_indirect_p): Likewise.
8878         (m68hc11_function_arg_padding): Change return type to enum
8879         direction.
8880         (emit_move_after_reload): Use add_reg_note.
8881         (m68hc11_emit_logical): Change code parameter to enum rtx_code.
8882         (m68hc11_split_logical): Likewise.
8883         (m68hc11_rtx_costs): Add local code_and outer_code variables with
8884         enum type.
8885         * config/m68hc11/predicates.md (reg_or_some_mem_operand): Change 0
8886         to VOIDmode in function call.
8887         * config/m68hc11/m68hc11-protos.h: Don't check TREE_CODE to see if
8888         tree is defined.
8889         (m68hc11_split_logical): Update declaration.
8890         (m68hc11_function_arg_padding): Update declaration.
8891         * config/mcore/mcore.c (regno_reg_class): Change form array of int
8892         to array of enum reg_class.
8893         (mcore_attribute_table): Make static.  Move higher in file.
8894         (mcore_rtx_costs): Add cast to enum type.
8895         * config/mcore/mcore.h (regno_reg_class): Update declaration.
8896         (GO_IF_LEGITIMATE_INDEX): Add cast to avoid warning.
8897         * config/sh/sh.c (sh_attribute_table): Make static.  Move higher
8898         in file.
8899         * config/sh/predicates.md (trapping_target_operand): Rename and to
8900         and_expr.
8901         * config/sparc/sparc.c (sparc_attribute_table): Make static.  Move
8902         higher in file.
8903         * config/spu/spu.c (spu_attribute_table): Make static.  Move
8904         higher in file.
8905         * config/v850/v850.c (v850_attribute_table): Make static.  Move
8906         higher in file.
8907         (v850_rtx_costs): Use local code with enum type.
8908         (expand_epilogue): Add cast.
8909         * config/v850/v850-c.c (ghs_pragma_section): Initialize repeat.
8910
8911 2009-06-23  Takashi YOSHII  <yoshii.takashi@renesas.com>
8912
8913         PR target/40515
8914         * doc/invoke.texi (SH Options): Document -m2a, -m2a-single,
8915         -m2a-single-only and -m2a-nofpu.
8916         * config/sh/sh.opt: Document m2a generates FPU code.
8917
8918 2009-06-24  Anatoly Sokolov  <aesok@post.ru>
8919
8920         * defaults.h (CAN_ELIMINATE): Provide default.
8921         * doc/tm.texi (CAN_ELIMINATE): Revise documentation.
8922         * config/alpha/alpha.h (CAN_ELIMINATE): Delete.
8923         * config/m32c/m32c.h (CAN_ELIMINATE): Delete.
8924         * config/spu/spu.h (CAN_ELIMINATE): Delete.
8925         * config/xtensa/xtensa.h (CAN_ELIMINATE): Delete.
8926         * config/moxie/moxie.h (CAN_ELIMINATE): Delete.
8927         * config/cris/cris.h (CAN_ELIMINATE): Delete.
8928         * config/mn10300/mn10300.h (CAN_ELIMINATE): Delete.
8929         * config/pa/pa64-linux.h (CAN_ELIMINATE): Delete.
8930         * config/mmix/mmix.h (CAN_ELIMINATE): Delete.
8931
8932 2009-06-24  DJ Delorie  <dj@redhat.com>
8933
8934         * mep-ext-cop.cpu: Fix copyright notice.
8935         * mep-default: Fix copyright notice.
8936         * mep-core: Fix copyright notice.
8937         * mep: Fix copyright notice.
8938         * mep-ivc2: Fix copyright notice.
8939         * mep-c5: Fix copyright notice.
8940
8941 2009-06-24  Denis Chertykov  <chertykov@gmail.com>
8942
8943         * doc/contrib.texi (Contributors):
8944
8945 2009-06-24  Andreas Krebbel  <krebbel1@de.ibm.com>
8946
8947         PR middle-end/40501
8948         * tree-ssa-math-opts.c (execute_optimize_bswap): Convert the bswap
8949         src and dst operands if necessary.
8950
8951 2009-06-23  DJ Delorie  <dj@redhat.com>
8952
8953         Add MeP port.
8954         * config.gcc: Add mep support.
8955         * recog.c: Resurrect validate_replace_rtx_subexp().
8956         * recog.h: Likewise.
8957         * config/mep/: Add new port:
8958         * config/mep/constraints.md: New file.
8959         * config/mep/default.h: New file.
8960         * config/mep/intrinsics.h: New file.
8961         * config/mep/intrinsics.md: New file.
8962         * config/mep/ivc2-template.h: New file.
8963         * config/mep/mep-c5.cpu: New file.
8964         * config/mep/mep-core.cpu: New file.
8965         * config/mep/mep-default.cpu: New file.
8966         * config/mep/mep-ext-cop.cpu: New file.
8967         * config/mep/mep-intrin.h: New file.
8968         * config/mep/mep-ivc2.cpu: New file.
8969         * config/mep/mep-lib1.asm: New file.
8970         * config/mep/mep-lib2.c: New file.
8971         * config/mep/mep-pragma.c: New file.
8972         * config/mep/mep-protos.h: New file.
8973         * config/mep/mep-tramp.c: New file.
8974         * config/mep/mep.c: New file.
8975         * config/mep/mep.cpu: New file.
8976         * config/mep/mep.h: New file.
8977         * config/mep/mep.md: New file.
8978         * config/mep/mep.opt: New file.
8979         * config/mep/predicates.md: New file.
8980         * config/mep/t-mep: New file.
8981
8982 2009-06-23  Ian Lance Taylor  <iant@google.com>
8983
8984         * configure.ac: Invoke AC_PROG_CXX.  Separate C specific warnings
8985         from loose_warn into c_loose_warn and from strict_warn into
8986         c_strict_warn.  Set and substitute warn_cxxflags.  Check for
8987         --enable-build-with-cxx.  Set and substitute
8988         ENABLE_BUILD_WITH_CXX.  Set and substitute HOST_LIBS.
8989         * Makefile.in (CXXFLAGS): New variable.
8990         (C_LOOSE_WARN, C_STRICT_WARN): New variables.
8991         (GCC_WARN_CFLAGS): Add $(C_LOOSE_WARN).  Add $(C_STRICT_WARN) if
8992         the default is the same as $(STRICT_WARN).
8993         (GCC_WARN_CXXFLAGS, WARN_CXXFLAGS): New variables.
8994         (CXX): New variable.
8995         (COMPILER): New value if ENABLE_BUILD_WITH_CXX.
8996         (COMPILER_FLAGS, LINKER, LINKER_FLAGS): Likewise.
8997         (ALL_COMPILERFLAGS, ALL_LINKERFLAGS): Likewise.
8998         (HOST_LIBS): New variable.
8999         (GCC_CFLAGS): Add $(C_LOOSE_WARN).
9000         (ALL_CXXFLAGS): New variable.
9001         (LIBS, BACKENDLIBS): Add $(HOST_LIBS).
9002         * doc/install.texi (Configuration): Document
9003         --enable-build-with-cxx, --with-stage1-ldflags,
9004         --with-stage1-libs, --with-boot-ldflags, --with-boot-libs.
9005         * configure: Rebuild.
9006
9007 2009-06-24  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
9008
9009         * config/arm/arm.c (arm_override_options): Fix braces and formatting
9010         from previous commit.
9011
9012 2009-06-23  Ian Lance Taylor  <iant@google.com>
9013
9014         * Makefile.in ($(out_object_file)): Depend upon $(DF_H).
9015
9016 2009-06-23  Ian Lance Taylor  <iant@google.com>
9017
9018         * reload.c (alternative_allows_const_pool_ref): Mark mem parameter
9019         with ATTRIBUTE_UNUSED.
9020
9021 2009-06-23  Michael Meissner  <meissner@linux.vnet.ibm.com>
9022             Pat Haugen  <pthaugen@us.ibm.com>
9023             Revital Eres  <eres@il.ibm.com>
9024
9025         * config.in (HAVE_AS_POPCNTD): Add default definition.
9026         (HAVE_AS_LWSYNC): Ditto.
9027
9028         * configure.ac (gcc_cv_as_powerpc_mfpgpr): Provide real binutils
9029         release number.
9030         (gcc_cv_as_powerpc_cmpb): Ditto.
9031         (gcc_cv_as_powerpc_dfp): Ditto.
9032         (gcc_cv_as_powerpc_vsx): Ditto.
9033         (gcc_cv_as_powerpc_popcntd): Add feature test for assembler
9034         supporting the popcntd/lwsync instructions.
9035         (gcc_cv_as_powerpc_lwsync): Ditto.
9036         * configure: Regenerate.
9037
9038         * config/rs6000/aix53.h (ASM_CPU_SPEC): Add support for
9039         -mcpu=native and -mcpu=power7.
9040         * config/rs6000/aix61.h (ASM_CPU_SPEC): Ditto.
9041
9042         * config/rs6000/linux64.opt (-mprofile-kernel): Move switch to be
9043         a variable instead of a mask to reduce the number of mask bits.
9044         * config/rs6000/sysv4.opt (-mbit-align): Ditto.
9045         (-mbit-word): Ditto.
9046         (-mregnames): Ditto.
9047         * config/rs6000/rs6000.opt (-mupdate): Ditto.
9048         (-mfused-madd): Ditto.
9049
9050         * config/rs6000/rs6000.opt (-mpopcntd): New switch for non-VSX ISA
9051         2.06 instructions.
9052         (-mvsx): New switch for VSX instructions.
9053         (-misel): Move from a variable to a mask to allow it to be set by
9054         -mcpu=.
9055
9056         * config/rs6000/rs6000-protos.h (rs6000_hard_regno_nregs): Change
9057         function declaration to an array declaration.
9058         (rs6000_hard_regno_nregs): New external array declaration.
9059
9060         * config/rs6000/t-rs6000 (MD_INCLUDES): Define, add all of the .md
9061         files included by rs6000.md.
9062
9063         * config/rs6000/linux64.h (SUBSUBTARGET_OVERRIDE_OPTIONS): Use
9064         SET_PROFILE_KERNEL macro to reset the -mprofile-kernel switch.
9065
9066         * config/rs6000/rs6000.c (rs6000_isel): Delete, -misel moved to be
9067         a target mask.
9068         (rs6000_debug_reg): New -mdebug= variables.
9069         (rs6000_debug_addr): Ditto.
9070         (rs6000_debug_cost): Ditto.
9071         (rs6000_pmode): New variable to hold Pmode.
9072         (rs6000_pointer_size): New variable to hold POINTER_SIZE.
9073         (rs6000_class_max_nregs): New array to hold CLASS_MAX_NREGS
9074         calculated at compiler start.
9075         (rs6000_hard_regno_nregs): Change function to an array which holds
9076         HARD_REGNO_NREGS calculated at compiler start.
9077         (rs6000_explicit_options): Delete isel field.
9078         (rs6000_vector_unit): New array to hold which vector unit
9079         supports arithmetic options for a given type.
9080         (rs6000_vector_mem): New array to hold which vector unit supports
9081         memory reference operations for a given type.
9082         (rs6000_vector_align): New array to given the alignment of each
9083         vector type.
9084         (power7_cost): New basic costs for power7.
9085         (SET_PROFILE_KERNEL): New macro for resetting -mprofile-kernel.
9086         (rs6000_hard_regno_nregs_internal): New function, moved from
9087         HARD_REGNO_NREGS, to calculate the number of registers each hard
9088         register takes for each type.
9089         (rs6000_debug_reg_print): New function for -mdebug=reg support.
9090         (rs6000_debug_vector_unit): New array, map rs6000_vector to string.
9091         (+rs6000_init_hard_regno_mode_ok): New function, move calculation
9092         of HARD_REGNO_NREGS, CLASS_MAX_NREGS, REGNO_REG_CLASS, and vector
9093         unit information here so it is calculated once at compiler startup
9094         time.
9095         (rs6000_override_options): Make -misel a target mask.  Add more
9096         power7 target masks.  Setup Pmode and POINTER_SIZE.  Add initial
9097         VSX support.  Add support for -mdebug=reg, -mdebug=addr, and
9098         -mdebug=cost.
9099         (POWERPC_MASKS): Add MASK_POPCNTD, MASK_VSX, and MASK_ISEL.
9100         (rs6000_handle_option): Move -misel from variable to target mask.
9101         (rs6000_builtin_mask_for_load): Add VSX support.
9102         (rs6000_conditional_register_usage): Ditto.
9103         (USE_ALTIVEC_FOR_ARG_P): Ditto.
9104         (function_arg_boundary): Ditto.
9105         (rs6000_expand_builtin): Ditto.
9106         (def_builtin): Make abort message a little friendlier.
9107         (rs6000_emit_int_cmove): Add support for 64-bit isel.
9108
9109         * config/rs6000/rs6000.h (ASM_CPU_POWER7_SPEC): Depend on the
9110         assembler support the popcntd instruction instead of a vsx
9111         instruction to enable power7 support.
9112         (ASM_CPU_SPEC): Add support for -mcpu=native and -mcpu=power7.
9113         (EXTRA_SPECS): Add ASM_CPU_NATIVE_SPEC to allow passing the right
9114         option to the assembler if -mcpu=native.
9115         (ASM_CPU_NATIVE_SPEC): Ditto.
9116         (TARGET_POPCNTD): If assembler doesn't support popcntd, turn off
9117         ISA 2.06 features.
9118         (TARGET_LWSYNC_INSTRUCTION): Define whether it is safe to issue
9119         the lwsync instruction.
9120         (enum processor_type): Add PROCESSOR_POWER7.
9121         (rs6000_debug_reg): New -mdebug= options.
9122         (rs6000_debug_addr): Ditto.
9123         (rs6000_debug_cost): Ditto.
9124         (rs6000_isel): Delete.
9125         (enum rs6000_vector): New enum to say what vector unit we have.
9126         (VECTOR_UNIT_*): New macros to say which vector unit has
9127         arithmetic operations for a given type.
9128         (VECTOR_MEM_*): New macros to say which vector unit has memory
9129         operations for a given type.
9130         (TARGET_LDBRX): Whether the machine supports the ldbrx
9131         instruction.
9132         (TARGET_ISEL): Delete, -misel moved to be a mask.
9133         (TARGET_ISEL64): New macro for 64-bit isel support.
9134         (UNITS_PER_VSX_WORD): New macro.
9135         (POINTER_SIZE): Move to be an external variable, rather than
9136         calculating whether we are generating 32 ot 64-bit code.
9137         (Pmode): Ditto.
9138         (STACK_BOUNDARY): Add VSX support.
9139         (LOCAL_ALIGNMENT): Ditto.
9140         (SLOW_UNALIGNED_ACCESS): Ditto.
9141         (VSX_REGNO_P): New macro for VSX support.
9142         (VFLOAT_REGNO_P): Ditto.
9143         (VINT_REGNO_P): Ditto.
9144         (VLOGICAL_REGNO_P): Ditto.
9145         (VSX_VECTOR_MODE): Ditto.
9146         (VSX_SCALAR_MODE): Ditto.
9147         (VSX_MODE): Ditto.
9148         (VSX_MOVE_MODE): Ditto.
9149         (VSX_REG_CLASS_P): Ditto.
9150         (HARD_REGNO_NREGS): Instead of calling a function, use an array
9151         lookup.
9152         (UNITS_PER_SIMD_WORD): Add VSX support.
9153         (MODES_TIEABLE_P): Ditto.
9154         (STARTING_FRAME_OFFSET): Ditto.
9155         (STACK_DYNAMIC_OFFSET): Ditto.
9156         (EPILOGUE_USES): Ditto.
9157         (REGNO_REG_CLASS): Move to array lookup.
9158         (CLASS_MAX_NREGS): Ditto.
9159         (rs6000_vector_reg_class): Add declaration.
9160         (ADDITIONAL_REGISTER_NAMES): Add VSX names for the registers that
9161         overlap with the floating point and Altivec registers.
9162
9163         * config/rs6000/e500.h (CHECK_E500_OPTIONS): Disallow -mvsx.
9164
9165         * config/rs6000/driver-rs6000.c (asm_names): New static array to
9166         give the appropriate asm switches if -mcpu=native.
9167         (host_detect_local_cpu): Add support for "asm".
9168         (host_detect_local_cpu): Follow GNU code guidelines for name.
9169
9170         * config/rs6000/sysv4.h (SUBTARGET_OVERRIDE_OPTIONS): Move
9171         -mbit-word to a variable instead of being a target mask.
9172
9173         * config/rs6000/sync.md (lwsync): If the assembler supports it,
9174         emit the lwsync instruction instead of emitting the instruction as
9175         an integer constant.
9176
9177         * config/rs6000/spe.md (spe_fixuns_truncdfsi2): Rename from
9178         fixuns_trundfsi2, move expander into rs6000.md.
9179
9180         * config/rs6000/rs6000.md (cpu): Add power7.
9181         (sel, *ptrsize): New mode attributes for 32/64-bit isel.
9182         (logical predicate patterns): Change the single instruction
9183         primitives that set CR0 to be fast_compare instead of compare.
9184         (norsi*): Ditto.
9185         (popcntwsi2): Add support for ISA 2.06 popcount instructions.
9186         (popcntddi2): Ditto.
9187         (popcount<mode>): Ditto.
9188         (floating multiply/add insns): Name the floating point
9189         multiply/add insns.
9190         (isel_signed_<mode>): Add support for -misel on 64-bit systems.
9191         (isel_unsigned_<mode>): Ditto.
9192         (fixuns_trundfsi2): Move expander here from spe.md.
9193         (smindi3): Define if we have -misel on 64-bit systems.
9194         (smaxdi3): Ditto.
9195         (umindi3): Ditto.
9196         (umaxdi3): Ditto.
9197
9198 2009-06-23  Anatoly Sokolov  <aesok@post.ru>
9199
9200         * config.gcc (avr-*-rtems*, avr-*-*): Set extra_gcc_objs and
9201         extra_objs.
9202         * config/avr/avr.c (avr_current_device): New variable.
9203         (avr_arch_types, avr_mcu_types): Move to avr-deveces.c.
9204         (avr_arch, mcu_type_s): Move to avr.h.
9205         * config/avr/avr.h (base_arch_s). Add reserved2, arch_name and
9206         default_data_section_start fields.
9207         (avr_arch): Moved from avr.c.
9208         (mcu_type_s): Moved from avr.c. Add short_sp, data_section_start and
9209         library_name fields.
9210         (avr_current_device, avr_mcu_types, avr_arch_types,
9211         avr_device_to_arch, avr_device_to_data_start,
9212         avr_device_to_startfiles, avr_device_to_devicelib): Declare.
9213         (EXTRA_SPEC_FUNCTIONS): Define.
9214         (LINK_SPEC): Remove device name to '-m ...' and '-Tdata ...' linker
9215         options mapping. Use device_to_arch and device_to_data_start insted.
9216         (STARTFILE_SPEC): Use device_to_startfile instead of crt_binutils.
9217         (CRT_BINUTILS_SPECS, EXTRA_SPECS): Remove.
9218         * config/avr/t-avr (driver-avr.o, avr-devices.o): New rules.
9219         * config/avr/driver-avr.c: New file.
9220         * config/avr/avr-devices.c: New file.
9221
9222 2009-06-23  Jakub Jelinek  <jakub@redhat.com>
9223
9224         * var-tracking.c (unshare_variable): Force initialized to
9225         be VAR_INIT_STATUS_INITIALIZED unless flag_var_tracking_uninit.
9226         (set_variable_part): Likewise.
9227         (struct variable_union_info): Remove pos_src field.
9228         (vui_vec, vui_allocated): New variables.
9229         (variable_union): Pass VAR_INIT_STATUS_UNKNOWN to unshare_variable
9230         unconditionally.  Avoid XCVECNEW/free for every sorting, for dst_l
9231         == 1 use a simpler sorting algorithm.  Compute pos field right
9232         away, don't fill in pos_src.  For dst_l == 2 avoid qsort.
9233         Avoid quadratic comparison if !flag_var_tracking_uninit.
9234         (variable_canonicalize): Pass VAR_INIT_STATUS_UNKNOWN to
9235         unshare_variable unconditionally.
9236         (dataflow_set_different_2): Removed.
9237         (dataflow_set_different): Don't traverse second hash table.
9238         (compute_bb_dataflow): Pass VAR_INIT_STATUS_UNINITIALIZED
9239         unconditionally to var_reg_set or var_mem_set.
9240         (emit_notes_in_bb): Likewise.
9241         (delete_variable_part): Pass VAR_INIT_STATUS_UNKNOWN to
9242         unshare_variable.
9243         (emit_note_insn_var_location): Don't set initialized to
9244         VAR_INIT_STATUS_INITIALIZED early.
9245         (vt_finalize): Free vui_vec if needed, clear vui_vec and
9246         vui_allocated.
9247         * rtl.c (rtx_equal_p): Don't implement on top of rtx_equal_p_cb.
9248
9249         * tree-object-size.c (addr_object_size): Instead of checking
9250         for non-NULL TREE_CHAIN of the FIELD_DECL check that there
9251         are no FIELD_DECLs following it.
9252
9253 2009-06-23  Andreas Krebbel  <krebbel1@de.ibm.com>
9254
9255         * tree-ssa-math-opts.c (find_bswap): Increase the search depth in
9256         order to match bswaps with signed source operands.
9257
9258 2009-06-23  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
9259
9260         * sdbout.c (sdbout_one_type): Fix braces in switch.
9261
9262 2009-06-23  Richard Guenther  <rguenther@suse.de>
9263
9264         * tree-ssa-structalias.c (struct variable_info): Add is_global_var
9265         member.
9266         (var_anything, anything_tree, var_nothing, nothing_tree, var_readonly,
9267         readonly_tree, var_escaped, escaped_tree, var_nonlocal, nonlocal_tree,
9268         var_callused, callused_tree, var_storedanything, storedanything_tree,
9269         var_integer, integer_tree): Remove global variables.
9270         (new_var_info): Do not pass new id, append the new var to the
9271         global variable vector.
9272         (do_ds_constraint): Use is_global_var member of the variable-info.
9273         (new_scalar_tmp_constraint_exp): Adjust.
9274         (create_function_info_for): Likewise.
9275         (create_variable_info_for): Likewise.
9276         (find_what_var_points_to): Remove dead code.
9277         (init_base_vars): Simplify.
9278         (compute_points_to_sets): Adjust.
9279
9280 2009-06-22  Adam Nemet  <anemet@caviumnetworks.com>
9281
9282         * combine.c (try_combine): Dump information about the insns we're
9283         combining.
9284
9285 2009-06-22  Adam Nemet  <anemet@caviumnetworks.com>
9286
9287         * combine.c (combine_simplify_rtx): Remove TRULY_NOOP_TRUNCATION
9288         check when calling force_to_mode on TRUNCATE's operand.
9289
9290 2009-06-22  Ian Lance Taylor  <iant@google.com>
9291
9292         * config/rs6000/rs6000.opt: Move msched-epilog before msched-prolog.
9293
9294 2009-06-22  Steven Bosscher  <steven@gcc.gnu.org>
9295
9296         * config/arm/arm.md (prologue_use): Set length of fake insn to 0.
9297
9298 2009-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9299
9300         * doc/invoke.texi (Link Options): -nodefaultlibs and -nostdlib
9301         override library linkage flags such as -static-libgcc or
9302         -shared-libgcc.
9303
9304 2009-06-22  Maxim Kuvyrkov  <maxim@codesourcery.com>
9305
9306         * config/m68k/m68k-devices.def: Add line for MCF5221x.
9307
9308 2009-06-22  Ian Lance Taylor  <iant@google.com>
9309
9310         * config/linux.opt: Put mglibc ahead of muclibc.
9311
9312         * c-decl.c (diagnose_mismatched_decls): Add -Wc++-compat warning
9313         for duplicate decls.
9314
9315 2009-06-22  Matthias Klose  <doko@ubuntu.com>
9316
9317         * Makefile.in (install-plugin): Remove extra `/' after $(DESTDIR).
9318
9319 2009-06-22  Steven Bosscher  <steven@gcc.gnu.org>
9320
9321         PR objc/28050
9322         * c-parser.c (c_parser_objc_message_args): Return error_mark_node
9323         instead of NULL if a parser error occurs.
9324
9325 2009-06-22  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
9326
9327         * dwarf2out.c (dwarf2_debug_hooks): Initialize
9328         non-DWARF2_DEBUGGING_INFO version.
9329
9330 2009-06-22  Kai Tietz  <kai.tietz@onevision.com>
9331
9332         * config.gcc (i[34567]86-*-mingw*, x86_64-*-mingw*): Add
9333         i386/t-fprules-softfp and soft-fp/t-softfp to tmake_file.
9334
9335         * config/i386/mingw32.h (LIBGCC2_HAS_TF_MODE): Define.
9336         (LIBGCC2_TF_CEXT): Define.
9337         (TF_SIZE): Define.
9338
9339 2009-06-22  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
9340
9341         PR target/40463
9342         * config/arm/linux-eabi.h (CLEAR_INSN_CACHE): Fix definition.
9343
9344 2009-06-22  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
9345
9346         * config/arm/arm.c (arm_override_options): Disable
9347         -mcaller-super-interworking and -mcallee-super-interworking.
9348         * doc/invoke.texi (ARM Options): Document this.
9349
9350 2009-06-22  Nathan Sidwell  <nathan@codesourcery.com>
9351
9352         * config/arm/arm.c (arm_print_operand): Deal with HIGH.
9353         * config/arm/constraints.md (j): New constraint for movw operands.
9354         (N): Remove thumb2 meaning.
9355         * config/arm/arm.md (*arm_movw): Delete.
9356         (*arm_movsi_insn): Use j constraint for movw instead of N constraint.
9357         * config/arm/vfp.md (*arm_movsi_vfp, *thumb2_movsi_vfp): Likewise.
9358         * config/arm/thumb2.md (*thumb2_movsi_insn): Likewise.
9359
9360 2009-06-22  Martin Jambor  <mjambor@suse.cz>
9361
9362         PR tree-optimization/40492
9363         * tree-sra.c (sra_modify_assign): Pass zero offsets to
9364         build_ref_for_offset.
9365
9366 2009-06-22  Shujing Zhao  <pearly.zhao@oracle.com>
9367
9368         * alias.c: Use REG_P, MEM_P, CONST_INT_P, LABEL_P, CALL_P, NOTE_P and
9369         JUMP_TABLE_DATA_P predicates where applicable.
9370         * auto-inc-dec.c: Ditto.
9371         * builtins.c: Ditto.
9372         * caller-save.c: Ditto.
9373         * calls.c: Ditto.
9374         * cfgcleanup.c: Ditto.
9375         * cfglayout.c: Ditto.
9376         * cfgrtl.c: Ditto.
9377         * combine.c: Ditto.
9378         * combine-stack-adj.c: Ditto.
9379         * cse.c: Ditto.
9380         * cselib.c: Ditto.
9381         * dbxout.c: Ditto.
9382         * df-scan.c: Ditto.
9383         * dse.c: Ditto.
9384         * dwarf2asm.c: Ditto.
9385         * dwarf2out.c: Ditto.
9386         * emit-rtl.c: Ditto.
9387         * except.c: Ditto.
9388         * explow.c: Ditto.
9389         * expmed.c: Ditto.
9390         * expr.c: Ditto.
9391         * final.c: Ditto.
9392         * function.c: Ditto.
9393         * fwprop.c: Ditto.
9394         * gcse.c: Ditto.
9395         * genpreds.c: Ditto.
9396         * genrecog.c: Ditto.
9397         * ifcvt.c: Ditto.
9398         * ira-costs.c: Ditto.
9399         * ira-lives.c: Ditto.
9400         * jump.c: Ditto.
9401         * loop-iv.c: Ditto.
9402         * lower-subreg.c: Ditto.
9403         * modulo-sched.c: Ditto.
9404         * optabs.c: Ditto.
9405         * postreload.c: Ditto.
9406         * print-rtl.c: Ditto.
9407         * recog.c: Ditto.
9408         * reginfo.c: Ditto.
9409         * regmove.c: Ditto.
9410         * reload1.c: Ditto.
9411         * reload.c: Ditto.
9412         * reorg.c: Ditto.
9413         * rtlanal.c: Ditto.
9414         * rtl.c: Ditto.
9415         * sched-vis.c: Ditto.
9416         * sdbout.c: Ditto.
9417         * sel-sched-ir.c: Ditto.
9418         * simplify-rtx.c: Ditto.
9419         * targhooks.c: Ditto.
9420         * var-tracking.c: Ditto.
9421         * vmsdbgout.c: Ditto.
9422
9423 2009-06-22  Matthias Klose  <doko@ubuntu.com>
9424
9425         * Makefile.in (install-plugin): Always use DESTDIR.
9426
9427 2009-06-22  Olivier Hainque  <hainque@adacore.com>
9428
9429         * config/pa/pa.c (output_call): Don't optimize post call jumps
9430         into return address adjustments if the call may throw.
9431
9432 2009-06-21  Richard Earnshaw  <rearnsha@arm.com>
9433
9434         * arm.c (thumb1_output_casesi): New function.
9435         * arm.h (CASE_VECTOR_PC_RELATIVE): Thumb-1 code is also relative if
9436         optimizing for size or PIC.
9437         (CASE_VECTOR_SHORTEN_MODE): Handle thumb-1.
9438         * arm.md (UNSPEC_THUMB1_CASESI): New constant.
9439         (casesi): Handle Thumb-1 when optimizing for size or PIC.
9440         (thumb1_casesi_internal_pic): New expand rule.
9441         (thumb1_casesi_dispatch): New pattern.
9442         * aout.h (ASM_OUTPUT_ADDR_DIFF_ELT): Use shortened vectors for
9443         thumb-1 mode.
9444         * coff.h (JUMP_TABLES_IN_TEXT_SECTION): Thumb-1 jump tables are now
9445         in the text seciton when PIC or optimizing for size.
9446         * elf.h (JUMP_TABLES_IN_TEXT_SECTION): Likewise.
9447         * lib1funcs.asm ([__ARM_EABI__]): Add an attribute describing stack
9448         preservation properties of code.
9449         (__gnu_thumb1_case_sqi, __gnu_thumb1_case_uqi): New functions.
9450         (__gnu_thumb1_case_shi, __gnu_thumb1_case_uhi): New functions.
9451         (__gnu_thumb1_case_si): New function.
9452         * t-arm (LIB1ASMSRC): Define here.
9453         (LIB1ASMFUNCS): Add some common functions.
9454         * t-arm-elf (LIB1ASMSRC): Delete.
9455         (LIB1ASMFUNCS): Append to existing set.
9456         * t-pe (LIB1ASMSRC, LIB1ASMFUNCS): Likewise.
9457         * t-strongarm-elf (LIB1ASMSRC, LIB1ASMFUNCS): Likewise.
9458         * t-symbian (LIB1ASMFUNCS): Likewise.
9459         * t-vxworks (LIB1ASMSRC, LIB1ASMFUNCS): Likewise.
9460         * t-wince-pe (LIB1ASMSRC, LIB1ASMFUNCS): Likewise.
9461
9462 2009-06-21  Richard Guenther  <rguenther@suse.de>
9463
9464         PR tree-optimization/38729
9465         * tree-ssa-loop-niter.c (find_loop_niter_by_eval): Restrict
9466         to loops with a single exit if -fno-expensive-optimizations.
9467
9468 2009-06-21  Jakub Jelinek  <jakub@redhat.com>
9469
9470         * var-tracking.c (struct shared_hash_def, shared_hash): New types.
9471         (dataflow_set): Change vars type from htab_t to shared_hash.
9472         (shared_hash_pool, empty_shared_hash): New variables.
9473         (vars_clear): Removed.
9474         (shared_hash_shared, shared_hash_htab, shared_hash_copy,
9475         shared_hash_find_slot_unshare, shared_hash_find_slot,
9476         shared_hash_find_slot_noinsert, shared_hash_find): New
9477         static inlines.
9478         (shared_hash_unshare, shared_hash_destroy): New functions.
9479         (unshare_variable): Unshare set->vars if shared, use
9480         shared_hash_htab.
9481         (vars_copy): Use htab_traverse_noresize instead of htab_traverse.
9482         (get_init_value, find_src_set_src, dump_dataflow_set,
9483         clobber_variable_part, emit_notes_for_differences): Use
9484         shared_hash_htab.
9485         (dataflow_set_init): Remove second argument, set vars to
9486         empty_shared_hash instead of creating a new htab.
9487         (dataflow_set_clear): Call shared_hash_destroy and set vars
9488         to empty_shared_hash instead of calling vars_clear.
9489         (dataflow_set_copy): Don't call vars_copy, instead just share
9490         the src htab with dst.
9491         (variable_union): Use shared_hash_*, use initially NO_INSERT
9492         lookup if set->vars is shared.  Don't keep slot cleared before
9493         calling unshare_variable.  Unshare set->vars if needed.
9494         Even ->refcount == 1 vars must be unshared if set->vars is shared
9495         and var needs to be modified.
9496         (variable_canonicalize): New function.
9497         (dataflow_set_union): If dst->vars is empty, just share src->vars
9498         with dst->vars and traverse with variable_canonicalize to canonicalize
9499         and unshare what is needed.
9500         (dataflow_set_different): If old_set and new_set use the same shared
9501         htab, they aren't different.  If number of htab elements is different,
9502         htabs are different.  Use shared_hash_*.
9503         (dataflow_set_destroy): Call shared_hash_destroy instead of
9504         htab_delete.
9505         (compute_bb_dataflow, emit_notes_in_bb, vt_emit_notes): Don't pass
9506         second argument to dataflow_set_init.
9507         (vt_initialize): Likewise.  Initialize shared_hash_pool and
9508         empty_shared_hash, move bb in/out initialization afterwards.
9509         Use variable_htab_free instead of NULL as changed_variables del hook.
9510         (variable_was_changed): Change type of second argument to pointer to
9511         dataflow_set.  When inserting var into changed_variables, bump
9512         refcount.  Unshare set->vars if set is shared htab and slot needs to
9513         be cleared.
9514         (set_variable_part): Use shared_hash_*, use initially NO_INSERT
9515         lookup if set->vars is shared.  Unshare set->vars if needed.
9516         Even ->refcount == 1 vars must be unshared if set->vars is shared
9517         and var needs to be modified.  Adjust variable_was_changed caller.
9518         (delete_variable_part): Use shared_hash_*.  Even ->refcount == 1
9519         vars must be unshared if set->vars is shared and var needs to be
9520         modified.  Adjust variable_was_changed caller.
9521         (emit_note_insn_var_location): Don't pool_free var.
9522         (emit_notes_for_differences_1): Initialize empty_var->refcount to 0
9523         instead of 1.
9524         (vt_finalize): Call htab_delete on empty_shared_hash->htab and
9525         free_alloc_pool on shared_hash_pool.
9526
9527 2009-06-20  Anthony Green  <green@moxielogic.com>
9528
9529         * config/moxie/sfp-machine.h (__gcc_CMPtype, CMPtype): Define.
9530         * config/moxie/moxie.h (LOAD_EXTEND_OP): Define.
9531
9532 2009-06-20  Richard Guenther  <rguenther@suse.de>
9533
9534         * tree-ssa-structalias.c (find_func_aliases): For memset use
9535         a constraint from NULL if we memset to zero.
9536         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Add builtins
9537         we explicitly handle that do not read from memory.
9538         (call_may_clobber_ref_p_1): Properly handle builtins that may
9539         set errno.
9540
9541 2009-06-20  Richard Guenther  <rguenther@suse.de>
9542
9543         PR tree-optimization/40495
9544         * tree-ssa-structalias.c (get_constraint_exp_for_temp): Remove.
9545         (new_scalar_tmp_constraint_exp): New function.
9546         (process_constraint): Do not create temporary decls.
9547         (process_all_all_constraints): Likewise.
9548         (handle_const_call): Likewise.
9549         (create_function_info_for): Do not set decl.
9550
9551 2009-06-19  Ian Lance Taylor  <iant@google.com>
9552
9553         * config/rs6000/rs6000.c (rs6000_explicit_options): Make static.
9554         (rs6000_attribute_table): Make static; move before use.
9555
9556 2009-06-19  Eric Botcazou  <ebotcazou@adacore.com>
9557
9558         * tree.c (substitute_in_expr) <COMPONENT_REF>: Tweak and reformat.
9559         <tcc_vl_exp>: Call process_call_operands on the new CALL_EXPR.
9560         Propagate the TREE_READONLY flag without overwriting it.
9561         (substitute_placeholder_in_expr) <tcc_vl_exp>: Likewise.
9562         Propagate the TREE_READONLY flag onto the result.
9563         (process_call_operands): Move around.  Use correct constant value.
9564
9565 2009-06-19  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
9566
9567         PR target/40482
9568         * config/arm/arm.c (thumb_shiftable_const): Truncate val to 32 bits.
9569         * config/arm/arm.md: Likewise.
9570
9571 2009-06-19  Ian Lance Taylor  <iant@google.com>
9572
9573         * tree-cfg.c (gimple_redirect_edge_and_branch): Change ERROR_MARK
9574         to GIMPLE_ERROR_MARK.
9575
9576         * c-typeck.c (build_conditional_expr): Add op1_original_type and
9577         op2_original_type parameters.  Warn about using different enum types.
9578         * c-parser.c (c_parser_conditional_expression): Pass original
9579         types to build_conditional_expr.
9580         * c-tree.h (build_conditional_expr): Update declaration.
9581
9582 2009-06-19  Ian Lance Taylor  <iant@google.com>
9583
9584         * config/i386/i386.c (ix86_function_specific_save): Test that
9585         fields match values, rather than testing the values are in a
9586         certain range.
9587
9588 2009-06-19  Richard Guenther  <rguenther@suse.de>
9589
9590         * tree-ssa-alias.c (ptr_deref_may_alias_decl_p): Handle
9591         ADDR_EXPR pointers.
9592         (ptr_derefs_may_alias_p): Likewise.
9593         (ptr_deref_may_alias_ref_p_1): New function.
9594         (ptr_deref_may_alias_ref_p): Likewise.
9595         (ref_maybe_used_by_call_p_1): Handle builtins that are not
9596         covered by looking at the ESCAPED solution.
9597         (call_may_clobber_ref_p_1): Likewise.
9598         * tree-ssa-structalias.c (get_constraint_for_ptr_offset):
9599         Handle NULL_TREE offset.  Do not produce redundant constraints.
9600         (process_all_all_constraints): New helper function.
9601         (do_structure_copy): Use it.
9602         (handle_lhs_call): Likewise.
9603         (find_func_aliases): Handle some builtins with pointer arguments
9604         and/or return values explicitly.
9605
9606 2009-06-19  Ian Lance Taylor  <iant@google.com>
9607
9608         * varasm.c (const_rtx_hash_1): Remove const qualifier from shift.
9609
9610 2009-06-19  Ian Lance Taylor  <iant@google.com>
9611
9612         * rtl.h (SUBREG_PROMOTED_UNSIGNED_P): Add cast to int.
9613
9614 2009-06-19  Ian Lance Taylor  <iant@google.com>
9615
9616         * ggc-page.c (ggc_pch_write_object): Initialize emptyBytes.
9617         * sdbout.c (sdb_debug_hooks): Initialize non-SDB_DEBUGGING_INFO
9618         version.
9619
9620         * c-decl.c (finish_decl): If -Wc++-compat, warn about
9621         uninitialized const.
9622
9623 2009-06-19  Ian Lance Taylor  <iant@google.com>
9624
9625         * dse.c (struct store_info): Rename bitmap field to bmap.  Change
9626         all uses.
9627
9628         * c-decl.c (in_struct, struct_types): Remove.
9629         (struct c_binding): Add in_struct field.
9630         (c_binding_ptr): Define type, along with VEC.
9631         (struct c_struct_parse_info): Define.
9632         (struct_parse_info): New static variable.
9633         (bind): Initialize in_struct field.
9634         (start_struct): Remove enclosing_in_struct and
9635         enclosing_struct_types parameters.  Add
9636         enclosing_struct_parse_info parameter.  Change all callers.  Set
9637         struct_parse_info rather than in_struct and struct_types.
9638         (grokfield): If -Wc++-compat and there is a symbol binding for the
9639         field name, set the in_struct flag and push it on the
9640         struct_parse_info->fields vector.
9641         (warn_cxx_compat_finish_struct): New static function.
9642         (finish_struct): Remove enclosing_in_struct and
9643         enclosing_struct_types parameters.  Add
9644         enclosing_struct_parse_info parameter.  Change all callers.  Don't
9645         set C_TYPE_DEFINED_IN_STRUCT here.  Call
9646         warn_cxx_compat_finish_struct.  Free struct_parse_info and set to
9647         parameter.  Only push on struct_types if warn_cxx_compat.
9648         (finish_enum): Only push on struct_types if warn_cxx_compat.
9649         (declspecs_add_type): Add loc parameter.  Change all callers.
9650         Change all error calls to error_at.  Pass loc, not input_location,
9651         to pedwarn calls.  Warn if -Wc++-compat and a typedef name is
9652         defined in a struct.  If -Wc++-compat and parsing a struct, record
9653         that a typedef name was used.
9654         * c-parser.c (c_parser_declspecs): Get location to pass to
9655         declspecs_add_type.
9656         (c_parser_struct_or_union_specifier): Update calls to start_struct
9657         and finish_struct.
9658         * c-tree.h (struct c_struct_parse_info): Declare.
9659         (finish_struct, start_struct): Update declarations.
9660         (declspecs_add_type): Update declaration.
9661
9662 2009-06-19  Ian Lance Taylor  <iant@google.com>
9663
9664         * c-decl.c (grokdeclarator): If -Wc++-compat, warn about a global
9665         variable with an anonymous type.
9666
9667 2009-06-19  Uros Bizjak  <ubizjak@gmail.com>
9668
9669         * see.c: Remove for real.
9670
9671 2009-06-19  Uros Bizjak  <ubizjak@gmail.com>
9672
9673         * optabs.h (enum optab_index): Add new OTI_significand.
9674         (significand_optab): Define corresponding macro.
9675         * optabs.c (init_optabs): Initialize significand_optab.
9676         * genopinit.c (optabs): Implement significand_optab using
9677         significand?f2 patterns.
9678         * builtins.c (expand_builtin_mathfn): Handle
9679         BUILT_IN_SIGNIFICAND{,F,L}.
9680         (expand_builtin): Expand BUILT_IN_SIGNIFICAND{,F,L} using
9681         expand_builtin_mathfn if flag_unsafe_math_optimizations is set.
9682
9683         * config/i386/i386.md (significandxf2, significand<mode>2): New
9684         expanders to implement significandf, significand and significandl
9685         built-ins as inline x87 intrinsics.
9686
9687 2009-06-18  Anatoly Sokolov  <aesok@post.ru>
9688
9689         * config/avr/avr.c (avr_override_options): Remove setting value of
9690         PARAM_INLINE_CALL_COST.
9691
9692 2009-06-18  Richard Henderson  <rth@redhat.com>
9693
9694         PR 40488
9695         * tree-pass.h (TDF_ASMNAME): New.
9696         * tree-dump.c (dump_options): Add asmname.
9697         * doc/invoke.texi: Document it.
9698
9699         * tree-pretty-print.c (maybe_dump_asm_name): Merge into...
9700         (dump_decl_name): ...here.
9701         (dump_function_name): New flags arg; mind TDF_ASMNAME.
9702         (dump_generic_node): Update dump_function_name calls.
9703         (print_call_name): New flags arg; update all dump calls.
9704         * diagnostic.h (print_call_name): Update.
9705         * gimple-pretty-print.c (dump_gimple_call): Update.
9706
9707 2009-06-18  H.J. Lu  <hongjiu.lu@intel.com>
9708
9709         PR target/40470
9710         * config/i386/i386.h (CLASS_LIKELY_SPILLED_P): Add SSE_FIRST_REG.
9711
9712 2009-06-18  Diego Novillo  <dnovillo@google.com>
9713
9714         * doc/plugins.texi: Document plugin_is_GPL_compatible.
9715         * plugin.c (str_license): Declare.
9716         (try_init_one_plugin): Assert that the symbol
9717         'plugin_is_GPL_compatible' exists.
9718
9719 2009-06-18  Sergei Dyshel  <sergeid@il.ibm.com>
9720
9721         * see.c: Remove.
9722         * Makefile.in (OBJS-common): Remove see.o.
9723         (see.o): Remove.
9724         * common.opt (fsee): Mark as preserved for backward compatibility.
9725         * opts.c (common_handle_option): Add OPT_fsee to the backward
9726         compatibility section.
9727         * passes.c (init_optimization_passes, pass_see): Remove pass.
9728         * timevar.def (TV_SEE): Remove.
9729         * tree-pass.h (pass_see): Remove declaration.
9730         * doc/invoke.texi (-fsee): Remove documentation.
9731
9732 2009-06-18  Martin Jambor  <mjambor@suse.cz>
9733
9734         * tree-sra.c: Include statistics.h
9735         (sra_stats): New variable.
9736         (sra_initialize): Clear sra_stats.
9737         (create_access_replacement): Increment sra_stats.replacements.
9738         (get_access_replacement): Do not return twice.
9739         (analyze_all_variable_accesses): Increment statistics counter by the
9740         number of scalarized aggregates.
9741         (generate_subtree_copies): Increment sra_stats.subtree_copies.
9742         (sra_modify_expr): Increment sra_stats.exprs.
9743         (load_assign_lhs_subreplacements): Increment sra_stats.subreplacements.
9744         (sra_modify_assign): Increment sra_stats.exprs,
9745         sra_stats.separate_lhs_rhs_handling and sra_stats.deleted.
9746         (perform_intra_sra): Update statistics counters.
9747         * Makefile.in (tree-sra.o): Add statistics.h to dependencies.
9748
9749 2009-06-18  Sandra Loosemore  <sandra@codesourcery.com>
9750
9751         * config/arm/arm.c (TARGET_SCALAR_MODE_SUPPORTED_P): Redefine.
9752         (arm_scalar_mode_supported_p): New function.
9753
9754 2009-06-18  Paul Brook  <paul@codesourcery.com>
9755             Sandra Loosemore  <sandra@codesourcery.com>
9756
9757         * config/arm/sfp-machine.h (_FP_NANFRAC_H, _FP_NANSIGN_H): Define.
9758         (__extendhfsf2, __truncsfhf2): Define.
9759         * config/arm/fp16.c: New file.
9760         * config/arm/t-bpabi (LIB2FUNCS_STATIC_EXTRA): Add fp16.c.
9761         * config/arm/t-symbian (LIB2FUNCS_STATIC_EXTRA):  Add fp16.c.
9762
9763 2009-06-18  Sandra Loosemore  <sandra@codesourcery.com>
9764
9765         * doc/extend.texi (Half-Precision): New section.
9766         * doc/invoke.texi (Option Summary): List -mfp16-format.
9767         (ARM Options): List neon-fp16 as -mfpu value.  Document -mfp16-format.
9768         * config/arm/arm.opt (mfp16-format=): New.
9769         * config/arm/arm.c: Include intl.h.
9770         (TARGET_INVALID_PARAMETER_TYPE): Redefine.
9771         (TARGET_INVALID_RETURN_TYPE): Redefine.
9772         (TARGET_PROMOTED_TYPE): Redefine.
9773         (TARGET_CONVERT_TO_TYPE): Redefine.
9774         (arm_fp16_format): Define.
9775         (all_fpus): Add entry for neon-fp16.
9776         (fp_model_for_fpu): Likewise.
9777         (struct fp16_format): Declare.
9778         (all_fp16_formats): Define.
9779         (arm_init_libfuncs): Add entries for HFmode conversions and arithmetic
9780         functions.
9781         (arm_override_options): Set arm_fp16_format. Call sorry for fp16
9782         and no ldrh.
9783         (arm_legitimate_index_p): Treat HFmode like HImode.
9784         (thumb1_legitimate_address_p): Make it recognize HFmode constants.
9785         (coproc_secondary_reload_class): Special-case HFmode.
9786         (arm_print_operand): Add 'z' specifier for vld1.16/vst1.16.
9787         (arm_hard_regno_mode_ok): Allow HFmode values in VFP registers.
9788         (arm_init_fp16_builtins): New.
9789         (arm_init_builtins): Call it.
9790         (arm_invalid_parameter_type): New.
9791         (arm_invalid_return_type): New.
9792         (arm_promoted_type): New.
9793         (arm_convert_to_type).
9794         (arm_file_start): Deal with neon-fp16 as fpu_name.  Emit tag for fp16
9795         format.
9796         (arm_emit_fp16_const): New function.
9797         (arm_mangle_type): Mangle __fp16 as "Dh".
9798         * config/arm/arm.h (TARGET_VFPD32): Make it know about
9799         FPUTYPE_NEON_FP16.
9800         (TARGET_NEON_FP16): New.
9801         (TARGET_NEON): Make it know about FPUTYPE_NEON_FP16.
9802         (enum fputype): Add FPUTYPE_NEON_FP16.
9803         (enum arm_fp16_format_type): Declare.
9804         (arm_fp16_format): Declare.
9805         (LARGEST_EXPONENT_IS_NORMAL): Define.
9806         * config/arm/arm-protos.h (arm_emit_fp16_const): Declare.
9807         * config/arm/arm-modes.def (HFmode): Define.
9808         * config/arm/vfp.md: (*movhf_vfp): New.
9809         (extendhfsf2): New.
9810         (truncsfhf2): New.
9811         * config/arm/arm.md: (fpu): Add neon_fp16.
9812         (floatsihf2, floatdihf2): New.
9813         (fix_trunchfsi2, fix_trunchfdi2): New.
9814         (truncdfhf2): New.
9815         (extendhfdf2): New.
9816         (movhf): New.
9817         (*arm32_movhf): New.
9818         (*thumb1_movhf): New.
9819         (consttable_2): Add check for HFmode constants.
9820         (consttable_4): Handle HFmode constants.
9821
9822 2009-06-18  Uros Bizjak  <ubizjak@gmail.com>
9823
9824         * convert.c (convert_to_integer): Convert (int)logb() into ilogb().
9825
9826 2009-06-17  Olivier Hainque  <hainque@adacore.com>
9827
9828         * collect2.c (main): Use CONST_CAST2 to perform char ** to
9829         const char ** conversion in AIX specific section.
9830
9831 2009-06-17  H.J. Lu  <hongjiu.lu@intel.com>
9832
9833         * config/i386/i386.c (ix86_special_builtin_type): Remove
9834         UINT64_FTYPE_PINT.  Add UINT64_FTYPE_PUNSIGNED.
9835         (bdesc_special_args): Updated.
9836         (ix86_init_mmx_sse_builtins): Likewise.
9837         (ix86_expand_special_args_builtin): Likewise.
9838
9839 2009-06-17  Richard Henderson  <rth@redhat.com>
9840
9841         * tree-pretty-print.c (maybe_dump_asm_name): New.
9842         (dump_decl_name): Use it.
9843         (PRINT_FUNCTION_NAME): Merge into...
9844         (dump_function_name): ... here.  Use maybe_dump_asm_name.
9845
9846 2009-06-17  Cary Coutant  <ccoutant@google.com>
9847
9848         * dbxout.c (dbxout_source_line): Add is_stmt parameter.
9849         Change caller.
9850         * debug.c (struct gcc_debug_hooks): Change placeholder for
9851         source_line hook.
9852         (debug_nothing_int_charstar_int): Replaced by...
9853         (debug_nothing_int_charstar_int_bool): ...this.
9854         * debug.h (struct gcc_debug_hooks): Add is_stmt parameter to
9855         source_line prototype.
9856         (debug_nothing_int_charstar_int): Replaced by...
9857         (debug_nothing_int_charstar_int_bool): ...this.
9858         * defaults.h (SUPPORTS_DISCRIMINATOR): New constant.
9859         * dwarf2out.c (dwarf2out_source_line): Add is_stmt parameter.
9860         Output is_stmt operand when necessary.
9861         * final.c (final_scan_insn): Pass is_stmt to source_line debug hook.
9862         (notice_source_line): Add is_stmt parameter.
9863         * sdbout.c (sdbout_source_line): Add is_stmt parameter.
9864         * vmsdbgout.c (vmsdbgout_source_line): Add is_stmt parameter.
9865         Change callers.
9866         * xcoffout.c (xcoffout_source_line): Add is_stmt parameter.
9867         * xcoffout.h (xcoffout_source_line): Add is_stmt parameter.
9868
9869 2009-06-17  Ian Lance Taylor  <iant@google.com>
9870
9871         * expr.c (struct move_by_pieces_d): Rename from move_by_pieces.
9872         Change all uses.
9873         (struct store_by_pieces_d): Rename from store_by_pieces.  Change
9874         call uses.
9875
9876 2009-06-17  Adam Nemet  <anemet@caviumnetworks.com>
9877
9878         * tree.h (STRIP_NOPS, STRIP_SIGN_NOPS,
9879         STRIP_USELESS_TYPE_CONVERSION): Use tree_strip_nop_conversions,
9880         tree_strip_sign_nop_conversions and
9881         tree_ssa_strip_useless_type_conversions rather than stripping
9882         the operations here.
9883         (tree_strip_nop_conversions, tree_strip_sign_nop_conversions):
9884         Declare them.
9885         * gimple.h (tree_ssa_strip_useless_type_conversions): Declare it.
9886         * tree-ssa.c (tree_ssa_strip_useless_type_conversions): New function.
9887         * tree.c (tree_nop_conversion, tree_sign_nop_conversion,
9888         tree_strip_nop_conversions, tree_strip_sign_nop_conversions): New
9889         functions.
9890
9891 2009-06-17  Michael Eager  <eager@eagercon.com>
9892
9893         * config/rs6000/constraints.md (register_constraint "d"): New.
9894         * config/rs6000/dfp.md (movsd_store, extendsddd2, extendsdtd2,
9895         truncddsd2, *negdd2_fpr, *absdd2_fpr, *nabsdd2_fpr,
9896         *movdd_hardfloat32, *movdd_hardfloat64_mfpgpr, *movdd_hardfloat64,
9897         *negtd2_fp, *abstd2_fpr, *nabstd2_fpr, *movtd_internal, extendddtd2,
9898         trunctddd2, adddd3, addtd3, subdd3, subtd3, muldd3, multd3, divdd3,
9899         divtd3, *cmpdd_internal1, *cmptd_internal1, floatditd2, ftruncdd2,
9900         fixdddi2, ftrunctd2, fixtddi2): replace 'f' constraint with 'd'
9901         * config/rs6000/ppu_intrinsics.h (__mffs, __mtfsf, __mtfsfi, __fabs,
9902         __fnabs, __fmadd, __fmsub, __fnmadd, __fnmsub, __fsel, __frsqrte,
9903         __fsqrt, __fmul, __fmuls, __frsp, __fcfid, __fctid, __fctidz, __fctiw,
9904         __fctiwz): Same.
9905         * config/rs6000/rs6000.md (*extendsfdf2_fpr, *truncdfsf2_fpr,
9906         *fseldfsf4, *negdf2_fpr, *absdf2_fpr, *nabsdf2_fpr, *adddf3_fpr,
9907         *subdf3_fpr, *muldf3_fpr, *divdf3_fpr, recipdf3, fred, sqrtdf2,
9908         *fseldfdf4, *fselsfdf4, *floatsidf2_internal, *floatunssidf2_internal,
9909         *fix_truncdfsi2_internal, fix_truncdfsi2_internal_gfxopt,
9910         fix_truncdfsi2_mfpgpr, fctiwz, btruncdf2, ceildf2, floordf2, rounddf2,
9911         stfiwx, floatdidf2, fix_truncdfdi2, floatdisf2_internal1,
9912         *movdf_hardfloat32, *movdf_hardfloat64_mfpgpr, *movdf_hardfloat64,
9913         *movtf_internal, *extenddftf2_internal, trunctfdf2_internal1,
9914         trunctfdf2_internal2, trunctfsf2_fprs, fix_trunc_helper,
9915         *fix_trunctfsi2_internal, negtf2_internal, *movdi_internal32,
9916         *movdi_mfpgpr, *movdi_internal64, *movdf_update1, *movdf_update2,
9917         *cmpdf_internal1, *cmptf_internal1, *cmptf_internal2): Same.
9918         * doc/md.texi: Describe PowerPC 'd' constraint, update 'f' constraint.
9919
9920 2009-06-16  Ian Lance Taylor  <iant@google.com>
9921
9922         * profile.c (total_num_never_executed): Don't define.
9923         (compute_branch_probabilities): Don't count or print
9924         num_never_executed.
9925         (init_branch_prob): Don't set total_num_never_executed.
9926         (end_branch_prob): Don't print total_num_never_executed.
9927
9928 2009-06-17  David Daney  <ddaney@caviumnetworks.com>
9929
9930         * jump.c (cleanup_barriers): Handle case of no insns before a barrier.
9931
9932 2009-06-17  David Edelsohn  <edelsohn@gnu.org>
9933
9934         * config/rs6000/dfp.md (nabsdd2_fpr): Correct mode.
9935         (nabstd2_fpr): Same.
9936
9937 2009-06-17  Steve Ellcey  <sje@cup.hp.com>
9938
9939         * expr.c (expand_assignment): Change complex type check.
9940
9941 2009-06-17  Basile Starynkevitch  <basile@starynkevitch.net>
9942
9943         * doc/plugins.texi (Building GCC plugins): Added new section.
9944
9945 2009-06-17  Ian Lance Taylor  <iant@google.com>
9946
9947         * c-pch.c (get_ident): Don't set size of templ array.
9948         (pch_init): Don't set size of partial_pch array.
9949
9950         * c-typeck.c (digest_init): If -Wc++-compat, warn about using a
9951         string constant to intialize an array whose size is the length of
9952         the string.
9953
9954 2009-06-17  Richard Guenther  <rguenther@suse.de>
9955
9956         PR tree-optimization/40389
9957         * tree-ssa-structalias.c (handle_rhs_call): Restrict NRV case
9958         to addressable types.
9959         * gimple.c (walk_stmt_load_store_addr_ops): Likewise.
9960
9961 2009-06-17  Richard Guenther  <rguenther@suse.de>
9962
9963         PR middle-end/40460
9964         * tree-chrec.h (build_polynomial_chrec): If we cannot determine
9965         if there is no evolution of left in the loop bail out.
9966         * tree-chrec.c (chrec_fold_multiply_poly_poly): CSE one
9967         chrec_fold_multiply.
9968
9969 2009-06-16  J"orn Rennecke  <joern.rennecke@arc.com>
9970             Janis Johnson  <janis187@us.ibm.com>
9971
9972         PR target/39254
9973         * config/rs6000/rs6000.c (rs6000_emit_move): Don't emit a USE
9974         for the symbol ref of a constant that is the source of a move
9975         - nor for any other not-obvious-label-ref constants.
9976
9977 2009-06-16  Olatunji Ruwase  <tjruwase@google.com>
9978
9979         * plugin.c (position_pass): Skip newly inserted pass during list
9980         traversal to avoid repeated insertion.
9981
9982 2009-06-16  Ian Lance Taylor  <iant@google.com>
9983
9984         * vec.h (VEC_stack_alloc): Define different version if
9985         GATHER_STATISTICS is defined, to accept and ignore MEM_STAT.
9986         (DEF_VEC_ALLOC_FUNC_P_STACK): Remove MEM_STAT_DECL.
9987         (DEF_VEC_ALLOC_FUNC_O_STACK): Likewise.
9988         (DEF_VEC_ALLOC_FUNC_I_STACK): Likewise.
9989
9990 2009-06-16  H.J. Lu  <hongjiu.lu@intel.com>
9991
9992         * config.gcc (extra_headers): Add ia32intrin.h for x86.
9993
9994         * config/i386/i386.c (ix86_builtins): Add IX86_BUILTIN_BSRSI,
9995         IX86_BUILTIN_BSRDI.  IX86_BUILTIN_RDPMC, IX86_BUILTIN_RDTSC.
9996         IX86_BUILTIN_RDTSCP.  IX86_BUILTIN_ROLQI, IX86_BUILTIN_ROLHI,
9997         IX86_BUILTIN_RORQI and IX86_BUILTIN_RORHI.
9998         (ix86_special_builtin_type): Add UINT64_FTYPE_VOID,
9999         UINT64_FTYPE_PINT, INT_FTYPE_INT, UINT64_FTYPE_INT,
10000         INT64_FTYPE_INT64, UINT16_FTYPE_UINT16_INT and UINT8_FTYPE_UINT8_INT.
10001         (bdesc_special_args): Add __builtin_ia32_rdtsc and
10002         __builtin_ia32_rdtscp.
10003         (bdesc_args): Add __builtin_ia32_bsrsi, __builtin_ia32_bsrdi,
10004         __builtin_ia32_rolqi, __builtin_ia32_rolhi, __builtin_ia32_rorqi
10005         and __builtin_ia32_rorhi.
10006         (ix86_init_mmx_sse_builtins): Handle UINT64_FTYPE_VOID,
10007         UINT64_FTYPE_PINT, INT_FTYPE_INT, UINT64_FTYPE_INT,
10008         INT64_FTYPE_INT64, UINT16_FTYPE_UINT16_INT and UINT8_FTYPE_UINT8_INT.
10009         (ix86_expand_args_builtin): Likewise.
10010         (ix86_expand_special_args_builtin): Likewise.
10011
10012         * config/i386/i386.md (UNSPECV_RDTSCP): New.
10013         (UNSPECV_RDTSC): Likewise.
10014         (UNSPECV_RDPMC): Likewise.
10015         (*bsr): Renamed to ...
10016         (bsr): This
10017         (*bsr_rex64): Renamed to ...
10018         (bsr_rex64): This.
10019         (rdpmc): New.
10020         (*rdpmc): Likewise.
10021         (*rdpmc_rex64): Likewise.
10022         (rdtsc): Likewise.
10023         (*rdtsc): Likewise.
10024         (*rdtsc_rex64): Likewise.
10025         (rdtscp): Likewise.
10026         (*rdtscp): Likewise.
10027         (*rdtscp_rex64): Likewise.
10028
10029         * config/i386/ia32intrin.h: New.
10030
10031         * config/i386/x86intrin.h: Include <ia32intrin.h>.
10032
10033 2009-06-16  Ian Lance Taylor  <iant@google.com>
10034
10035         * ira-build.c (copy_info_to_removed_store_destinations):
10036         Initialize parent_a.
10037
10038 2009-06-16  Ian Lance Taylor  <iant@google.com>
10039
10040         * c-decl.c (grokdeclarator): Change size_varies to bool.
10041
10042 2009-06-16  Ian Lance Taylor  <iant@google.com>
10043
10044         * sel-sched.c: Make forward declarations of move_op_hooks and
10045         fur_hooks explicitly extern.
10046
10047 2009-06-16  Ian Lance Taylor  <iant@google.com>
10048
10049         * df-problems.c (df_byte_lr_alloc): Don't set problem_data to itself.
10050         * vec.c (vec_gc_o_reserve_1): Don't set alloc to itself.
10051
10052 2009-06-16  Ian Lance Taylor  <iant@google.com>
10053
10054         * resource.c (mark_referenced_resources): Change
10055         include_delayed_effects parameter to bool.  Change all callers.
10056         (mark_end_of_function_resources): Likewise.
10057         * reorg.c (insn_references_resource_p): Likewise.
10058         (insn_sets_resource_p): Likewise.
10059         * resource.h (mark_referenced_resources): Update declaration.
10060         (mark_end_of_function_resources): Update declaration.
10061
10062 2009-06-16  David Edelsohn  <edelsohn@gnu.org>
10063
10064         * config/rs6000/aix.h (LIBSTDCXX_STATIC): Remove -lstdc++.
10065
10066 2009-06-16  David Edelsohn  <edelsohn@gnu.org>
10067
10068         * doc/install.texi (*-*-aix): Update explanation of XLC bootstrap.
10069         GCC can bootstrap on AIX with GNU Binutils 2.20.
10070
10071 2009-06-16  Ian Lance Taylor  <iant@google.com>
10072
10073         * Makefile.in (tree-vect-stmts.o): Depend upon $(TOPLEV_H).
10074
10075 2009-06-16  Ian Lance Taylor  <iant@google.com>
10076
10077         * toplev.h (floor_log2): If GCC_VERSION >= 3004, declare as static
10078         inline, not extern inline.
10079         (exact_log2): Likewise.
10080         * toplev.c (floor_log2): Only define if GCC_VERSION < 3004. Don't
10081         test CLZ_HWI.
10082         (exact_log2): Likewise, but don't test CTZ_HWI.
10083
10084 2009-06-16  Ian Lance Taylor  <iant@google.com>
10085
10086         * bitmap.c (bitmap_clear): Don't declare as inline.
10087         * gimple.c (gimplify_assign): Likewise.
10088         * tree-ssa-sccvn.c (vn_nary_op_compute_hash): Likewise.
10089         * haifa-sched.c (insn_cost): Don't declare with HAIFA_INLINE.
10090         (sched_scan_info): Remove duplicate definition.
10091
10092 2009-06-16  Ian Lance Taylor  <iant@google.com>
10093
10094         * c-common.c (skip_evaluation): Don't define.
10095         (c_inhibit_evaluation_warnings): Define global variable.
10096         (overflow_warning): Check c_inhibit_evaluation_warnings rather
10097         than skip_evaluation.
10098         (convert_and_check, warn_for_div_by_zero): Likewise.
10099         * c-common.h (skip_evaluation): Don't declare.
10100         (c_inhibit_evaluation_warnings): Declare.
10101         * c-parser.c (c_parser_typeof_specifier): Set
10102         c_inhibit_evaluation_warnings rather than skip_evaluation.
10103         (c_parser_conditional_expression): Likewise.
10104         (c_parser_binary_expression): Likewise.
10105         (c_parser_sizeof_expression): Likewise.
10106         (c_parser_alignof_expression): Likewise.
10107         * c-typeck.c (build_indirect_ref): Check
10108         c_inhibit_evaluation_warnings rather than skip_evaluation.
10109         (build_conditional_expr, build_binary_op): Likewise.
10110
10111 2009-06-16  Richard Guenther  <rguenther@suse.de>
10112
10113         * tree-ssa-alias.c (is_escape_site): Remove.
10114         * tree-ssa-alias.h (enum escape_type): Remove.
10115         (is_escape_site): Likewise.
10116         * tree-ssa-structalias.c (find_func_aliases): Handle escapes
10117         via casts and asms without deferring to is_escape_site.
10118
10119 2009-06-16  Jakub Jelinek  <jakub@redhat.com>
10120
10121         PR middle-end/40446
10122         * expr.c (expand_expr_real_1) <case VIEW_CONVERT_EXPR>: Don't
10123         use gen_lowpart if op0 has complex mode.
10124
10125 2009-06-16  Richard Guenther  <rguenther@suse.de>
10126
10127         * tree-ssa-structalias.c (do_ds_constraint): Stores in global
10128         variables add them to ESCAPED.
10129         (find_func_aliases): Do not make all indirectly stored values escaped.
10130
10131 2009-06-16  Rafael Avila de Espindola  <espindola@google.com>
10132
10133         * config/i386/winnt.c (i386_pe_encode_section_info): Update call to
10134         make_decl_one_only.
10135
10136 2009-06-16  Martin Jambor  <mjambor@suse.cz>
10137
10138         PR tree-optimization/40432
10139         * tree-sra.c (sra_modify_assign): When creating VIEW_CONVERT_EXPR,
10140         check whether we need to force gimple register operand.
10141
10142 2009-06-16  Martin Jambor  <mjambor@suse.cz>
10143
10144         PR tree-optimization/40413
10145         * tree-sra.c (load_assign_lhs_subreplacements): Pass offset to
10146         build_ref_for_offset.
10147         (propagate_subacesses_accross_link): Fix a typo in a comment.
10148
10149 2009-06-16  Ira Rosen  <irar@il.ibm.com>
10150
10151         * tree-parloops.c (loop_parallel_p): Call vect_is_simple_reduction
10152         with additional parameter.
10153         * tree-vectorizer.h (enum vect_def_type): Add new value
10154         vect_nested_cycle.
10155         (enum vect_relevant): Add comments.
10156         (vect_is_simple_reduction): Add new argument.
10157         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Add comments.
10158         Detect nested cycles.
10159         (vect_is_simple_reduction): Update documentation, add an argument to
10160         distinguish inner-loop reduction from nested cycle, detect nested
10161         cycles, fix printings and indentation, don't swap operands in case
10162         of nested cycle.
10163         (get_initial_def_for_reduction): Handle subtraction.
10164         (vect_create_epilog_for_reduction): Add new argument to specify
10165         reduction variable.
10166         (vect_finalize_reduction): Handle subtraction, fix comments.
10167         (vectorizable_reduction): Handle nested cycles. In case of nested
10168         cycle keep track of the reduction variable position. Call
10169         vect_is_simple_reduction with additional parameter. Use original
10170         statement code in reduction epilogue for nested cycle. Call
10171         vect_create_epilog_for_reduction with additional parameter.
10172         * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Assert
10173         inner-loop vectorization.
10174         (vect_recog_widen_sum_pattern): Likewise.
10175         * tree-vect-stmts.c (process_use): Distinguish between nested cycles
10176         and reductions.
10177         (vect_mark_stmts_to_be_vectorized): Likewise.
10178         (vect_get_vec_def_for_operand): Handle nested cycles.
10179
10180 2009-06-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10181
10182         * doc/invoke.texi (Debugging Options): Fix option index entries
10183         for -fdump-statistics, -frandom-seed add entries for
10184         -fdump-tree-original, -fdump-tree-optimized, -frandom-seed.
10185         (FRV Options): Fix entries for -mTLS, -mtls.
10186         (HPPA Options): Fix entries for -mgnu-ld, -mhp-ld.
10187         (i386 and x86-64 Options): Fix entry for -mno-red-zone.
10188         (M68hc1x Options): Fix @itemx for -mnominmax.
10189         (MCore Options): Fix entry for -mno-lsim.
10190         (MMIX Options): Fix entry for -mabi=mmixware.
10191         (PDP-11 Options): Fix entry for -mbcopy-builtin.
10192
10193 2009-06-16  Basile Starynkevitch  <basile@starynkevitch.net>
10194
10195         * doc/plugins.texi (Interacting with the GCC Garbage Collector):
10196         Mention the plugin mode of gengtype.
10197         * doc/gty.texi (Source Files Containing Type Information): Likewise.
10198         * gengtype.c: Updated copyright.
10199         (plugin_files, nb_plugin_files) Added new static variables.
10200         (measure_input_list) Care about plugin_files.
10201         (write_rtx_next): Added early return in plugin mode.
10202         (create_file): Updated copyright year in generated file. Added
10203         asserts.
10204         (oprintf): Added early return if NULL outf.
10205         (get_output_file_with_visibility): Care of plugin_files.
10206         (get_output_file_name): May return null.
10207         (write_local): Added early return.
10208         (put_mangled_filename): Ditto.
10209         (finish_root_table): Added check for base_files.
10210         (write_roots): Care about null when plugins.
10211         (main): Added plugin mode.
10212
10213 2009-06-15  Ian Lance Taylor  <iant@google.com>
10214
10215         * df-problems.c (df_simulate_one_insn_forwards): Fix braces in switch.
10216         * gcov.c (read_count_file): Add braces around variables declared
10217         before label.
10218
10219         * c.opt (Wjump-misses-init): New warning.
10220         * c-opts.c (c_common_handle_option): Set warn_jump_misses_init for
10221         -Wall and -Wc++-compat if not already set.
10222         (c_common_post_options): Clear warn_jump_misses_init if it was not
10223         set.
10224         * c-decl.c (struct c_binding): Change type field to a union with
10225         new label field.  Make it the first field in the struct.  Update
10226         references to type to use u.type instead.
10227         (struct c_spot_bindings): Define.
10228         (struct c_goto_bindings): Define.
10229         (c_goto_bindings_p): Define, along with VECs.
10230         (struct c_label_vars): Define.
10231         (struct c_scope): Add has_label_bindings field.
10232         (bind_label, set_spot_bindings): New static functions.
10233         (decl_jump_unsafe, update_spot_bindings): New static functions.
10234         (update_label_decls): New static function.
10235         (pop_scope): Call update_label_decls.  Don't call c_end_vm_scope.
10236         Update binding u.label field to shadowed field.
10237         (c_binding_start_stmt_expr): New function.
10238         (c_binding_end_stmt_expr): New function.
10239         (pushdecl): Don't call c_begin_vm_scope.
10240         (make_label): Add defining and p_label_vars parameters.  Change
10241         all callers.
10242         (lookup_label): Correct test for whether a label has not yet been
10243         defined.  Call bind_label rather than bind.
10244         (warn_about_goto): New static function.
10245         (lookup_label_for_goto): New function.
10246         (declare_label): Call bind_label rather than bind.
10247         (check_earlier_gotos): New static function.
10248         (define_label): Don't give errors about jumping into statement
10249         expressions or scopes of variably modified types.  Call
10250         set_spot_bindings and check_earlier_gotos.  Call bind_label
10251         instead of bind.  Don't set label_context_stack_se or
10252         label_context_stack_vm.
10253         (c_get_switch_bindings): New function.
10254         (c_release_switch_bindings): New function.
10255         (c_check_switch_jump_warnings): New function.
10256         (start_function): Don't set label_context_stack_se or
10257         label_context_stack_vm.
10258         (finish_function): Likewise.
10259         * c-typeck.c (label_context_stack_se): Don't define.
10260         (label_context_stack_vm): Don't define.
10261         (c_finish_goto_label): Call lookup_label_for_goto rather than
10262         lookup_label.  Don't give errors about jumping into a statement
10263         expression or the scope of a variably modified type.  Don't set
10264         label_context_stack_se or label_context_stack_vm.
10265         (struct c_switch): Remove blocked_stmt_expr and blocked_vm
10266         fields.  Add bindings field.
10267         (c_start_case): Don't set deleted fields.  Set bindings field.
10268         (do_case): Rework order of tests.  Don't check blocked_stmt_expr
10269         or blocked_vm.  Call c_check_switch_jump_warnings.
10270         (c_finish_case): Don't test blocked_stmt_expr field.  Call
10271         c_release_switch_bindings.
10272         (c_begin_stmt_expr): Don't increment blocked_stmt_expr in
10273         c_switch_stack.  Don't walk label_context_stack_se labels.  Don't
10274         set label_context_stack_se.  Call c_bindings_start_stmt_expr.
10275         (c_finish_stmt_expr): Don't decrement blocked_stmt_expr in
10276         c_switch_stack.  Don't walk label_context_stack_se labels.  Don't
10277         set label_context_stack_se.  Call c_bindings_end_stmt_expr.
10278         (c_begin_vm_scope, c_end_vm_scope): Don't define.
10279         * c-tree.h (C_DECL_UNJUMPABLE_STMT_EXPR): Don't define.
10280         (C_DECL_UNDEFINABLE_STMT_EXPR): Don't define.
10281         (C_DECL_UNJUMPABLE_VM): Don't define.
10282         (C_DECL_UNDEFINABLE_VM): Don't define.
10283         (struct c_label_list): Don't define.
10284         (struct c_label_context_se): Don't define.
10285         (struct c_label_context_vm): Don't define.
10286         (struct c_spot_bindings): Declare.
10287         (c_bindings_start_stmt_expr): Declare.
10288         (c_bindings_end_stmt_expr): Declare.
10289         (lookup_label_for_goto): Declare.
10290         (c_get_switch_bindings, c_release_switch_bindings): Declare.
10291         (c_check_switch_jump_warnings): Declare.
10292         (label_context_stack_se, label_context_stack_vm): Don't declare.
10293         (c_finish_goto_label): Update declaration.
10294         (c_begin_vm_scope, c_end_vm_scope): Don't declare.
10295         * doc/invoke.texi (Option Summary): Mention -Wjump-misses-init.
10296         (Warning Options): Document -Wjump-misses-init.
10297
10298 2009-06-15  Jakub Jelinek  <jakub@redhat.com>
10299
10300         * tree-object-size.c (addr_object_size): Fix a pasto in the last
10301         change.
10302
10303 2009-06-15  Rafael Avila de Espindola  <espindola@google.com>
10304
10305         * cgraph.c (cgraph_make_node_local): Use DECL_COMDAT_GROUP.
10306
10307 2009-06-15  Aldy Hernandez  <aldyh@redhat.com>
10308
10309         * except.c (init_eh): Use BUILTINS_LOCATION when calling build_decl.
10310
10311 2009-06-15  Aldy Hernandez  <aldyh@redhat.com>
10312
10313         * tree-eh.c (lower_try_finally_switch): Initialize tf_loc.
10314
10315 2009-06-15  Rafael Avila de Espindola  <espindola@google.com>
10316
10317         * cgraphunit.c (cgraph_function_versioning,save_inline_function_body):
10318         Use DECL_COMDAT_GROUP instead of DECL_ONE_ONLY.
10319         * cgraph.c (cgraph_create_virtual_clone): Use DECL_COMDAT_GROUP.
10320         * config/i386/i386.c (ix86_file_end): Compute DECL_COMDAT_GROUP.
10321         * dwarf2asm.c (dw2_force_const_mem): Update call to
10322         make_decl_one_only.
10323         * langhooks-def.h (lhd_comdat_group, LANG_HOOKS_COMDAT_GROUP): Remove.
10324         (LANG_HOOKS_DECLS): Remove LANG_HOOKS_COMDAT_GROUP.
10325         * langhooks.c (lhd_comdat_group): Remove.
10326         * langhooks.h (lang_hooks_for_decls): Remove comdat_group.
10327         * tree.h (DECL_COMDAT_GROUP): New.
10328         (DECL_ONE_ONLY): Use DECL_COMDAT_GROUP.
10329         (tree_decl_with_vis): Add comdat_group. Remove one_only.
10330         (make_decl_one_only): Change signature.
10331         * varasm.c (get_emutls_init_templ_addr, emutls_decl): Update call to
10332         make_decl_one_only.
10333         (make_decl_one_only): Change signature.
10334         (default_elf_asm_named_section): Use DECL_COMDAT_GROUP.
10335
10336 2009-06-15  Richard Guenther  <rguenther@suse.de>
10337
10338         PR middle-end/40439
10339         * tree.c (widest_int_cst_value): Fix bootstrap on 32bit HWI hosts.
10340
10341 2009-06-14  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
10342
10343         * tree-ssa-math-opts.c: Remove extra divide.
10344
10345 2009-06-14  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
10346
10347         * config/s390/s390.md ("bswap<mode>2"): Only available on z900.
10348
10349 2009-06-14  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
10350
10351         * passes.c: Add bswap pass.
10352         * tree-pass.h: Add pass_optimize_bswap declaration.
10353         * tree-ssa-math-opts.c: Include diagnostics.h for print_gimple_stmt.
10354         Include rtl.h, expr.h and optabs.h for optab_handler check.
10355         (struct symbolic_number, pass_optimize_bswap): New definition.
10356         (do_shift_rotate, verify_symbolic_number_p): New functions.
10357         (find_bswap_1, find_bswap, execute_optimize_bswap): New functions.
10358         (gate_optimize_bswap): New function.
10359         * tree.c (widest_int_cst_value): New function.
10360         * tree.h (widest_int_cst_value): Prototype added.
10361
10362 2009-06-14  Steven Bosscher  <steven@gcc.gnu.org>
10363
10364         * cfgcleanup.c (old_insns_match_p): Remove code to substitute
10365         REG_EQUAL/REG_EQUIV notes.
10366
10367 2009-06-14  Richard Guenther  <rguenther@suse.de>
10368
10369         PR middle-end/40389
10370         * gimple.c (walk_stmt_load_store_addr_ops): The LHS of a call
10371         has its address taken if NRV was applied and it is addressable.
10372         * tree-ssa-structalias.c (get_constraint_for_address_of): New
10373         function split out from ...
10374         (get_constraint_for_1): ... here.
10375         (handle_rhs_call): Use it to mark the return slot escaped if
10376         it is addressable and NRV was applied.
10377
10378 2009-06-13  Aldy Hernandez  <aldyh@redhat.com>
10379
10380         * config/rs6000/rs6000-protos.h (altivec_resolve_overloaded_builtin):
10381         Change first argument type to location_t.
10382         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Same.
10383         Do not set input_location.
10384         Use loc instead of input_location throughout.
10385
10386 2009-06-13  Richard Guenther  <rguenther@suse.de>
10387
10388         PR tree-optimization/40421
10389         * tree-predcom.c (should_unroll_loop_p): Remove.
10390         (tree_predictive_commoning_loop): Use can_unroll_loop_p.
10391
10392 2009-06-13  Michael Meissner  <meissner@linux.vnet.ibm.com>
10393
10394         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
10395         Add location argument.
10396
10397 2009-06-13  Aldy Hernandez  <aldyh@redhat.com>
10398
10399         * config/alpha/alpha.c (alpha_build_builtin_va_list): Pass location to
10400         build_decl.
10401         * config/s390/s390.c (s390_build_builtin_va_list): Same.
10402         (s390_gimplify_va_arg): Pass location to create_artificial_label.
10403         * config/spu/spu-protos.h: Add location to
10404         spu_resolve_overloaded_builtin.
10405         * config/spu/spu.c (spu_build_builtin_va_list): Pass location to
10406         spu_build_builtin_va_list.
10407         * config/spu/spu-c.c (spu_resolve_overloaded_builtin): Add location
10408         argument.  Pass location to build_function_call_vec.
10409         * config/sh/sh.c (sh_build_builtin_va_list): Pass location to
10410         build_decl.
10411         (emit_fpu_switch): Same.
10412         (sh_gimplify_va_arg_expr): Pass location to create_artificial_label.
10413         * config/xtensa/xtensa.c (xtensa_build_builtin_va_list): Pass location
10414         to build_decl and create_artificial_label.
10415         (xtensa_gimplify_va_arg_expr): Same.
10416         * config/stormy16/stormy16.c (xstormy16_build_builtin_va_list): Same.
10417         (xstormy16_gimplify_va_arg_expr): Same.
10418         * config/iq2000/iq2000.c (iq2000_expand_prologue): Same.
10419         * config/arm/arm.c (arm_build_builtin_va_list): Same.
10420         * config/mips/mips.c (mips_build_builtin_va_list): Same.
10421         (mips16_build_function_stub): Same.
10422         (mips16_build_call_stub): Same.
10423
10424 2009-06-13  Richard Earnshaw  <rearnsha@arm.com>
10425
10426         PR target/40327
10427         * arm/constraints.md (Pa, Pb): New constraints.
10428         * arm/arm.md (thumb1_addsi3): Support more complex additions.  Add a
10429         split pattern to deal with them.
10430
10431 2009-06-13  Joerg Sonnenberger  <joerg@britannica.bec.de>
10432
10433         * doc/invoke.texi: Add missing option -Wp,OPTION in list,
10434         fix index entry for -Xpreprocessor.
10435
10436 2009-06-12  Aldy Hernandez  <aldyh@redhat.com>
10437
10438         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
10439         Add location argument to build_decl call.
10440         * config/rs6000/rs6000.c (rs6000_build_builtin_va_list): Same.
10441         (rs6000_init_builtins): Same.
10442         (spe_init_builtins): Same.
10443         (rs6000_gimplify_va_arg): Add location argument to
10444         create_artificial_label call.
10445
10446 2009-06-12  Steven Bosscher  <steven@gcc.gnu.org>
10447
10448         * timevar.def (TV_COMBINE_STACK_ADJUST): New timevar.
10449         * combine-stack-adj.c (pass_stack_adjustments): Use it.
10450         * Makefile.in: Fix GGC dependency for gcse.o.
10451
10452 2009-06-12  Aldy Hernandez  <aldyh@redhat.com>
10453
10454         * tree-pretty-print.c (dump_generic_node): Dump column numbers.
10455         * gimple-pretty-print.c (dump_gimple_stmt): Same.
10456         * gimplify.c (gimplify_modify_expr): Set location for GIMPLE_ASSIGNs
10457         created.
10458         * c-parser.c (c_parser_binary_expression): Use current column while
10459         building binary operations.
10460         * common.opt (fshow-column): Enable by default.
10461         * tree-vrp.c (check_array_ref): Use warning_at.
10462         (check_array_bounds): Use location from call back if expr has no
10463         location.
10464         * tree.h: Add location argument to maybe_fold_*.
10465         * tree-ssa-ccp.c (ccp_fold): Pass location to maybe_fold_*.
10466         (maybe_fold_offset_to_array_ref): Add location argument and use it.
10467         (maybe_fold_offset_to_component_ref): Same.
10468         (maybe_fold_offset_to_reference): Same.
10469         (maybe_fold_offset_to_address): Same.
10470         (maybe_fold_stmt_indirect): Same.
10471         (maybe_fold_stmt_addition): Same.
10472         (fold_stmt_r): Pass location to maybe_fold_*.
10473         (fold_gimple_assign): Same.
10474         * c-tree.h: Add location argument to finish_decl,
10475         default_function_array_conversion, store_init_value.
10476         * c-decl.c (define_label): Use error_at.
10477         (c_make_fname_decl): Pass location to finish_decl.
10478         (finish_decl): New location argument.
10479         (build_compound_literal): Pass location to store_init_value.
10480         (grokdeclarator): Pass location to finish_decl.
10481         (grokfield): Same.
10482         * c-typeck.c (array_to_pointer_conversion): New location argument.
10483         (function_to_pointer_conversion): Same.
10484         (default_function_array_conversion): Same.
10485         (parser_build_unary_op): Pass location to overflow_warning.
10486         (parser_build_binary_op): Same.  Use warning_at.
10487         (build_unary_op): Pass location to array_to_pointer_conversion.
10488         (build_c_cast): Pass location to digest_init.
10489         (build_modify_expr): New location argument.
10490         (convert_for_assignment): Same.
10491         (store_init_value): Same.
10492         (digest_init): Same.
10493         (output_init_element): Pass location to digest_init and
10494         array_to_pointer_conversion.
10495         (c_finish_return): Pass location to convert_for_assignment.
10496         * gimplify.c (gimplify_conversion): Pass location to
10497         maybe_fold_offset_to_address.
10498         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Pass location
10499         to maybe_fold_stmt_addition.
10500         * c-omp.c (c_finish_omp_atomic): Pass new location to
10501         build_modify_expr.
10502         (c_finish_omp_for): Same.
10503         * c-common.c (overflow_warning): New argument.
10504         * c-common.h: New argument to build_modify_expr, overflow_warning.
10505         * c-parser.c (c_parser_declaration_or_fndef): Pass location to
10506         finish_decl.
10507         (c_parser_initializer): Pass location to
10508         default_function_array_conversion.
10509         (c_parser_initelt): Same.
10510         (c_parser_initval): Same.
10511         (c_parser_asm_operands): Same.
10512         (c_parser_expr_no_commas): Same.  Pass location to build_modify_expr.
10513         (c_parser_conditional_expression): Same.
10514         (c_parser_binary_expression): Add location info to stack.  Use it.
10515         (c_parser_unary_expression): Pass location to
10516         default_function_array_conversion, parser_build_unary_op,
10517         build_indirect_ref, c_parser_postfix_expression_after_primary.
10518         (c_parser_postfix_expression_after_primary): New location argument.
10519         Use it.
10520         (c_parser_expression_conv): Pass location to
10521         default_function_array_conversion.
10522         (c_parser_expr_list): Same.
10523         (c_parser_omp_atomic): Same.
10524         (c_parser_omp_for_loop): Same.
10525         * c-tree.h: (struct c_declarator): Add comment to id_loc.
10526         (build_array_declarator): New argument.
10527         * c-decl.c (build_array_declarator): Add location argument.
10528         (grokdeclarator): Set id_loc for cdk_array.
10529         * c-parser.c (c_parser_direct_declarator_inner): Pass location to
10530         build_array_declarator.
10531         * tree.c (build_omp_clause): Add location argument.
10532         * tree.h (OMP_CLAUSE_HAS_LOCATION): New macro.
10533         (OMP_CLAUSE_LOCATION): New macro.
10534         (struct tree_omp_clause): Add location field.
10535         (build_omp_clause): Add argument.
10536         * testsuite/gcc.dg/gomp/for-1.c: Fix column.
10537         * cp/pt.c (tsubst_omp_for_iterator): Pass location to
10538         build_omp_clause.
10539         * cp/parser.c (cp_parser_omp_var_list_no_open): Same.
10540         (cp_parser_omp_clause_collapse): Same.
10541         (cp_parser_omp_clause_default): Same.
10542         (cp_parser_omp_clause_if): Same.
10543         (cp_parser_omp_clause_nowait): Same.
10544         (cp_parser_omp_clause_num_threads): Same.
10545         (cp_parser_omp_clause_ordered): Same.
10546         (cp_parser_omp_clause_schedule): Same.
10547         (cp_parser_omp_clause_untied): Same.
10548         (cp_parser_omp_for_loop): Same.
10549         (cp_parser_omp_parallel): Pass location to c_split_parallel_clauses.
10550         * c-tree.h (c_start_case): Add location argument.
10551         (c_process_expr_stmt): Same.
10552         (c_finish_goto_*): Same.
10553         * tree-parloops.c (initialize_reductions): Pass location to
10554         build_omp_clause.
10555         (create_parallel_loop): Same.
10556         * fortran/trans-openmp.c (gfc_trans_omp_variable_list): Same.
10557         (gfc_trans_omp_reduction_list): Same.
10558         (gfc_trans_omp_clauses): Same.
10559         (gfc_trans_omp_do): Same.
10560         * c-typeck.c (c_finish_goto_label): Same.
10561         (c_finish_goto_ptr): New location argument.
10562         (c_start_case): Same.
10563         (emit_side_effect_warnings): Same.
10564         (c_process_expr_stmt): Same.
10565         (c_finish_stmt_expr): Same.
10566         (c_finish_omp_clauses): Use error_at instead of error.
10567         * gimplify.c (gimplify_adjust_omp_clauses_1): Pass location to
10568         build_omp_clause.
10569         * c-omp.c (c_split_parallel_clauses): New location argument.
10570         * tree-nested.c (convert_nonlocal_reference_stmt): Pass location
10571         to build_omp_clause.
10572         (convert_local_reference_stmt): Same.
10573         (convert_gimple_call): Same.
10574         * c-common.h (c_split_parallel_clauses): New argument.
10575         * c-parser.c (c_parser_statement_after_labels): Pass location to
10576         c_finish_goto_label.
10577         (c_parser_switch_statement): Pass location to c_start_case.
10578         (c_parser_for_statement): Pass location to c_finish_expr_stmt,
10579         and c_process_expr_stmt.
10580         (c_parser_omp_variable_list): Add location argument.
10581         (c_parser_omp_clause_collapse): Pass location to build_omp_clause.
10582         (c_parser_omp_clause_default): Same.
10583         (c_parser_omp_clause_if): Same.
10584         (c_parser_omp_clause_num_threads): Same.
10585         (-c_parser_omp_clause_ordered): Same.
10586         (c_parser_omp_clause_reduction): Pass location to
10587         c_parser_omp_variable_list.
10588         (c_parser_omp_clause_schedule): Pass location to build_omp_clause.
10589         (c_parser_omp_clause_untied): Same.
10590         (c_parser_omp_for_loop): Pass location to c_process_expr_stmt.
10591         (c_parser_omp_parallel): Pass location to c_split_parallel_clauses.
10592
10593         * c-tree.h (check_for_loop_decls, undeclared_variable,
10594         build_component_ref, build_array_ref, build_external_ref,
10595         c_expr_sizeof_expr, c_expr_sizeof_type, parser_build_unary_op,
10596         build_conditional_expr, build_compound_expr, c_cast_expr,
10597         build_c_cast, build_asm_expr, c_end_compound_stmt, c_finish_stmt_expr,
10598         c_finish_return, c_finish_omp_parallel, c_finish_omp_task): New
10599         argument.
10600         * c-semantics.c (build_stmt): Same.
10601         (build_case_label): Same.
10602         * c-decl.c (c_finish_incomplete_decl): Pass location on down.
10603         (undeclared_variable): New argument.
10604         (make_label): Same.
10605         (lookup_label): Pass location on down.
10606         (define_label): Same.
10607         (finish_decl): Same.
10608         (build_compound_literal): Same.
10609         (finish_struct): Same.
10610         (finish_function): Do not set location here.
10611         (check_for_loop_decls): New argument.
10612         * tree.c (save_expr): Set location.
10613         (build_empty_stmt): New argument.
10614         * tree.h (build_empty_stmt): New argument to build_empty_stmt.
10615         (CAN_HAVE_LOCATION_P): Make sure we have a non empty node.
10616         * builtins.c (gimplify_va_arg_expr): Use locations.
10617         (expand_builtin_sync_operation): Same.
10618         * c-typeck.c (build_component_ref): New argument.
10619         (build_array_ref): Same.
10620         (build_external_ref): Same.
10621         (c_expr_sizeof_expr): Same.
10622         (c_expr_sizeof_type): Same.
10623         (parser_build_unary_op): Same.
10624         (build_conditional_expr): Same.
10625         (build_compound_expr): Pass location on down.
10626         (build_compound_expr): New argument.
10627         (build_c_cast): Same.
10628         (c_cast_expr): Same.
10629         (build_asm_expr): Same.
10630         (c_finish_return): Same.
10631         (c_process_expr_stmt): Pass location on down.
10632         (c_finish_stmt_expr): New argument.
10633         (push_clenaup): Same.
10634         (c_finish_omp_parallel): Same.
10635         (c_finish_omp_task): Same.
10636         * gimplify.c (gimplify_call_expr): Pass location on down.
10637         * c-omp.c (c_finish_omp_master): New argument.
10638         (c_finish_omp_critical): Same.
10639         (c_finish_omp_ordered): Same.
10640         (c_finish_omp_barrier): Same.
10641         (-c_finish_omp_taskwait): Same.
10642         (c_finish_omp_atomic): Same.
10643         (c_finish_omp_flush): Same.
10644         * tree-inline.c (copy_tree_body_r): Pass location on down.
10645         (inline_forbidden_p): Remove use of input_location.
10646         * c-gimplify.c (c_build_bind_expr): New argument.
10647         * c-common.c (c_common_truthvalue_conversion): Pass location on down.
10648         (c_sizeof_or_alignof_type): New argument.
10649         (c_alignof_expr): Same.
10650         (build_va_arg): Same.
10651         (c_add_case_label): Same.
10652         * c-common.h (c_sizeof_or_alignof_type, c_alignof_expr,
10653         c_sizeof, c_alignof, build_va_arg, build_stmt, build_case_label,
10654         c_build_bind_expr, objc_build_selector_expr, objc_build_throw_stmt,
10655         c_finish_omp_master, c_finish_omp_critical, c_finish_omp_ordered,
10656         c_finish_omp_barrier, c_finish_omp_atomic, c_finish_omp_flush,
10657         c_finish_omp_taskwait, c_finish_omp_for, c_split_parallel_clauses):
10658         New argument.
10659         * stub-objc.c (objc_build_selector_expr): Same.
10660         (objc_build_throw_stmt): Same.
10661         * c-parser.c (c_parser_declaration_or_fndef): Pass location on down.
10662         (c_parser_initelt): Same.
10663         (c_parser_compound_statement): Same.
10664         (c_parser_compound_statement_nostart): Same.
10665         (c_parser_label): Same.
10666         (c_parser_statement_after_labels): Same.
10667         (c_parser_if_body): Same.
10668         (c_parser_else_body): Same.
10669         (c_parser_if_statement): Same.
10670         (c_parser_switch_statement): Same.
10671         (c_parser_while_statement): Same.
10672         (c_parser_do_statement): Same.
10673         (c_parser_for_statement): Same.
10674         (c_parser_asm_statement): Same.
10675         (c_parser_conditional_expression): Same.
10676         (c_parser_binary_expression): Same.
10677         (c_parser_cast_expression): Same.
10678         (c_parser_unary_expression): Same.
10679         (c_parser_sizeof_expression): Same.
10680         (c_parser_alignof_expression): Same.
10681         (c_parser_postfix_expression): Same.
10682         (c_parser_expression): Same.
10683         (c_parser_objc_receiver): Same.
10684         (c_parser_omp_variable_list): Same.
10685         (c_parser_omp_structured_block): Same.
10686         (c_parser_omp_atomic): New argument.
10687         (c_parser_omp_barrier): Same.
10688         (c_parser_omp_critical): Same.
10689         (c_parser_omp_flush): Pass location on down.
10690         (c_parser_omp_for_loop): New argument.
10691         (c_parser_omp_for): Same.
10692         (c_parser_omp_master): Same.
10693         (c_parser_omp_ordered): Same.
10694         (c_parser_omp_sections_scope): Same.
10695         (c_parser_omp_sections): Same.
10696         (c_parser_omp_parallel): Same.
10697         (c_parser_omp_single): Same.
10698         (c_parser_omp_task): Same.
10699         (c_parser_omp_taskwait): Pass location on down.
10700         (c_parser_omp_construct): Same.
10701         (c_parser_omp_threadprivate): Same.
10702         * dwarf2asm.c, targhooks.c, optabs.c, tree.c, tree.h, target.h,
10703         builtins.c, omp-low.c, cgraphunit.c, tree-call-cdce.c,
10704         tree-ssa-alias.c, gimple-low.c, c-tree.h, expr.c, tree-parloops.c,
10705         c-decl.c, tree-eh.c, langhooks.c, function.c, stor-layout.c,
10706         c-typeck.c, gimplify.c, c-pragma.c, expmed.c, except.c, coverage.c,
10707         emit-rtl.c, cfgexpand.c, tree-mudflap.c, varasm.c, tree-nested.c,
10708         rtl.h, tree-inline.c, tree-profile.c, c-common.c, c-common.h,
10709         tree-switch-conversion.c, tree-cfg.c, ipa-struct-reorg.c, c-parser.c,
10710         config/i386/i386.c, stmt.c:
10711         Add location argument to the following function definitions and/or
10712         function calls: build_decl, objcp_start_struct, objcp_finish_struct,
10713         start_struct, finish_struct, PUSH_FIELD, create_artificial_label,
10714         cp_make_fname_decl, pushtag, implicitly_declare, c_make_fname_decl,
10715         build_compound_literal, parser_xref_tag, resolve_overloaded_builtin,
10716         do_case, c_finish_bc_stmt, build_compound_literal,
10717         build_function_call.
10718         * c-decl.c (build_compound_literal): Add location argument.
10719         Make all diagnostic calls use location.
10720         (start_struct): Same.
10721         (finish_struct): Same.
10722         (start_enum): Same.
10723         (build_enumerator): Same.
10724         (start_function): Same.
10725         (grokdeclarator): Make all diagnostic calls use location.
10726         (store_parm_decls_oldstyle): Same.
10727         * c-typeck.c (build_function_call): Add location argument.
10728         Make all diagnostic calls use location.
10729         (do_case): Same.
10730         (c_finish_bc_stmt): Same.
10731         * tree-nested.c (get_trampoline_type): Add argument.
10732         Pass location to build_decl.
10733         (lookup_tramp_for_decl): Pass location to get_trampoline_type.
10734         * rtl.h (RTL_LOCATION): New.
10735         * c-common.c (c_add_case_label): Add location argument.
10736         Make all diagnostic calls use location.
10737         * c-common.h: Add location argument to make_fname_decl, do_case,
10738         c_add_case_label, build_function_call, resolve_overloaded_builtin.
10739         * c-parser.c (c_parser_enum_specifier): Rename ident_loc to enum_loc.
10740         Set it appropriately for every case.  Pass enum_loc to start_enum
10741         call.  Pass value_loc first to build_enumerator.  Pass enum_loc to
10742         parser_xref_tag.
10743         (c_parser_struct_or_union_specifier): Save location.  Use it for
10744         start_struct, finish_struct, and parser_xref_tag.
10745
10746 2009-06-12  Ian Lance Taylor  <iant@google.com>
10747
10748         * fold-const.c (fold_unary): Rename local variable and to and_expr.
10749
10750         * c-opts.c (c_common_handle_option): For -Wc++-compat set
10751         cpp_opts->warn_cxx_operator_names.
10752
10753 2009-06-12  Andrew Pinski  <andrew_pinski@playstation.sony.com>
10754
10755         PR tree-opt/38865
10756         * tree-ssa-sccvn.c (visit_reference_op_load): If vn_reference_lookup
10757         is returns NULL and OP is a VCE, look through the VCE.
10758
10759 2009-06-12  Ian Lance Taylor  <iant@google.com>
10760
10761         PR bootstrap/40430
10762         * collect2.c (main): Use CONST_CAST2 in code inside #if
10763         LINK_ELIMINATE_DUPLICATE_LDIRECTORIES.
10764
10765 2009-06-12  Joey Ye  <joey.ye@intel.com>
10766
10767         PR middle-end/39146
10768         * cfgexpand.c (get_decl_align_unit): Update
10769         max_used_stack_slot_alignment with align instead of
10770         stack_alignment_needed.
10771
10772         * function.c (assign_stack_local_1): Update
10773         max_used_stack_slot_alignment with alignment_in_bits instead
10774         of stack_alignment_needed.
10775         (locate_and_pad_parm): Don't update max_used_stack_slot_alignment
10776         here.
10777
10778 2009-06-12  Jakub Jelinek  <jakub@redhat.com>
10779
10780         * dwarf2out.c (last_var_location_insn): New variable.
10781         (dwarf2out_end_epilogue): Clear last_var_location_insn.
10782         (dwarf2out_var_location): Don't record anything after last real
10783         insn.  Only change labels if there were any real instructions
10784         in between last note and this one, or if changed sections.
10785
10786 2009-06-11  Richard Henderson  <rth@redhat.com>
10787
10788         * alpha.c (alpha_expand_prologue): Add a REF_CFA_REGISTER
10789         note when storing the frame pointer in a register.
10790         (FRP): Don't redefine to nothing for epilogue.
10791         (alpha_expand_epilogue): Mark register and sp restores.
10792         (unicosmk_gen_dsib): Don't mark weird frame pointer adjust.
10793
10794         * config/alpha/alpha.c (alpha_emit_setcc): Fix test for
10795         when gen_lowpart is needed.
10796
10797 2009-06-11  Richard Henderson  <rth@redhat.com>
10798
10799         * dwarf2out.c (def_cfa_1): Likewise for DW_CFA_cfa_offset.
10800
10801         * dwarf2out.c (need_data_align_sf_opcode): New.
10802         (div_data_align): Move earlier.
10803         (def_cfa_1, reg_save): Use it.
10804
10805 2009-06-11  H.J. Lu  <hongjiu.lu@intel.com>
10806
10807         * config/i386/i386.c (OPTION_MASK_ISA_CRC32_SET): New.
10808         (OPTION_MASK_ISA_CRC32_UNSET): Likewise.
10809         (ix86_handle_option): Handle OPT_mcrc32.
10810         (ix86_target_string): Add -mcrc32.
10811         (bdesc_args): Enable crc32 builtins with OPTION_MASK_ISA_CRC32.
10812
10813         * config/i386/i386.h (TARGET_CRC32): New.
10814
10815         * config/i386/i386.md (sse4_2_crc32<mode>): Also check TARGET_CRC32.
10816         (sse4_2_crc32di): Likewise.
10817
10818         * config/i386/i386.opt (mcrc32): New.
10819
10820         * doc/invoke.texi: Document -mcrc32.
10821
10822 2009-06-11  Richard Henderson  <rth@redhat.com>
10823
10824         * common.opt (gdwarf-): Accept a version number.
10825         * doc/invoke.texi (gdwarf-): Update docs.
10826         * opth-gen.awk: Special case -gdwarf+ to OPT_gdwarfplus.
10827         * opts.c (common_handle_option) [OPT_gdwarf_]: Verify dwarf
10828         version level, and record it.
10829
10830         * dwarf2.h (DW_CIE_VERSION): Remove.
10831         * dwarf2out.c (DWARF_VERSION): Remove.
10832         (add_fde_cfi): Skip DW_CFA_set_loc addition for dwarf3.
10833         (output_call_frame_info): Use CIE version 3 for dwarf3,
10834         or if the return register column is out of range for version 1.
10835         (dwarf_stack_op_name): Add all dwarf3 values.
10836         (DEBUG_PUBTYPES_SECTION): New.
10837         (size_of_die) [dw_val_class_die_ref]: Handle DW_FORM_ref_addr
10838         encoding change for dwarf3.
10839         (output_die) [dw_val_class_die_ref]: Likewise.
10840         (output_compilation_unit_header): Emit correct version for dwarf3.
10841         (output_line_info): Likewise.
10842         (output_pubnames): Update for DWARF_VERSION removal.
10843         (output_aranges): Likewise.
10844         (gen_subprogram_die): Emit DW_OP_call_frame_cfa if emitting dwarf3.
10845         (dwarf2out_init): Don't ifdef DEBUG_PUBTYPES_SECTION.
10846         (dwarf2out_finish): Likewise.
10847
10848 2009-06-11  David Daney  <ddaney@caviumnetworks.com>
10849
10850         * system.h (gcc_assert, gcc_unreachable): Revert accidental commit
10851         in r148403.
10852
10853 2009-06-11  David Daney  <ddaney@caviumnetworks.com>
10854
10855         PR c/39252
10856         * doc/extend.texi ( __builtin_unreachable): Document new builtin.
10857         * builtins.c (expand_builtin_unreachable): New function.
10858         (expand_builtin): Handle BUILT_IN_UNREACHABLE case.
10859         * builtins.def (BUILT_IN_UNREACHABLE): Add new builtin.
10860         * cfgcleanup.c (try_optimize_cfg): Delete empty blocks with no
10861         successors.
10862         * cfgrtl.c (rtl_verify_flow_info): Handle empty blocks when
10863         searching for missing barriers.
10864
10865 2009-06-11  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
10866
10867         * config/darwin.h (LINK_COMMAND_SPEC): Adjust spec to link libcov
10868         when -fprofile-generate* was passed.
10869         * config/darwin9.h (LINK_COMMAND_SPEC): Likewise.
10870
10871 2009-06-11  Anthony Green  <green@moxielogic.com>
10872
10873         * config/moxie/moxie.md: Define length attribute for all instructions.
10874         (rCC): Define.
10875         (*b<cond:code>): Support limited branch ranges for new PC-relative
10876         branch instructions.
10877         * config/moxie/moxie.h (HAS_LONG_UNCOND_BRANCH): Define.
10878
10879 2009-06-11  Jakub Jelinek  <jakub@redhat.com>
10880
10881         * config/i386/i386.c (min_insn_size): Use get_attr_length
10882         for normal insns other than TYPE_MULTI, TYPE_OTHER and TYPE_FCMP.
10883         For __asm return 0.
10884
10885         * config/i386/i386.c (ix86_pad_returns): Use emit_jump_insn_before
10886         instead of emit_insn_before.
10887
10888 2009-06-10  Ian Lance Taylor  <iant@google.com>
10889
10890         PR bootstrap/40408
10891         * graphite.c (add_conditions_to_domain): Change SWITCH_EXPR to
10892         GIMPLE_SWITCH.
10893
10894 2009-06-10  Revital Eres  <eres@il.ibm.com>
10895
10896         * passes.c (init_optimization_passes): Reschedule
10897         predictive-commoning pass before complete unroll pass.
10898
10899 2009-06-10  Martin Jambor  <mjambor@suse.cz>
10900
10901         * cgraph.c (cgraph_node_can_be_local_p): New function.
10902         (cgraph_make_node_local): New function.
10903         * cgraph.h (cgraph_node_can_be_local_p): Declare.
10904         (cgraph_make_node_local): Declare.
10905
10906 2009-06-10  Nathan Froyd  <froydnj@codesourcery.com>
10907
10908         * tree.h (tree_base): Add packed_flag and user_align fields.
10909         Decrease size of spare field.
10910         (TYPE_USER_ALIGN): Use user_align from tree_base.
10911         (DECL_USER_ALIGN): Likewise.
10912         (TYPE_PACKED): Use packed_flag from tree_base.
10913         (DECL_PACKED): Likewise.
10914         (tree_type): Delete packed_flag and user_align fields.  Widen
10915         precision field.  Widen mode field and shuffle fields to align
10916         mode on an 8-bit boundary.
10917         (tree_decl_common): Delete decl_flag_1 and user_align fields.
10918         Renumber decl_flag_* fields.  Fix comments.  Widen
10919         decl_common_unused field.
10920         (DECL_HAS_VALUE_EXPR_P): Adjust for renumbering of decl_flag_* fields.
10921         (DECL_EXTERNAL): Likewise.
10922         (DECL_BIT_FIELD): Likewise.
10923         (DECL_NONADDRESSABLE_P): Likewise.
10924         (TYPE_DECL_SUPRESS_DEBUG): Likewise.
10925         * config/arm/arm-modes.def (XImode): Make it an INT_MODE.
10926
10927 2009-06-10  Ian Lance Taylor  <iant@google.com>
10928
10929         * vec.h (DEF_VEC_ALLOC_I): Use DEF_VEC_NONALLOC_FUNCS_I.
10930         (DEF_VEC_ALLOC_P): Use DEF_VEC_NONALLOC_FUNCS_P.
10931         (DEF_VEC_ALLOC_O): Use DEF_VEC_NONALLOC_FUNCS_O.
10932         (DEF_VEC_ALLOC_FUNC_P): Only define VEC_OP (T,A,alloc).
10933         (DEF_VEC_NONALLOC_FUNCS_P): New macro, broken out of old
10934         DEF_VEC_ALLOC_FUNC_P.
10935         (DEF_VEC_ALLOC_FUNC_O): Only define VEC_OP (T,A,alloc).
10936         (DEF_VEC_NONALLOC_FUNCS_O): New macro, broken out of old
10937         DEF_VEC_ALLOC_FUNC_O.
10938         (DEF_VEC_ALLOC_FUNC_I): Only define VEC_OP (T,A,alloc).
10939         (DEF_VEC_NONALLOC_FUNCS_I): New macro, broken out of old
10940         DEF_VEC_ALLOC_FUNC_I.
10941         (vec_stack_p_reserve, vec_stack_p_reserve_exact): Declare.
10942         (vec_stack_p_reserve_exact_1): Declare.
10943         (vec_stack_o_reserve, vec_stack_o_reserve_exact): Declare.
10944         (vec_stack_free): Declare.
10945         (VEC_stack_alloc): Define.
10946         (DEF_VEC_ALLOC_P_STACK, DEF_VEC_ALLOC_FUNC_P_STACK): Define.
10947         (DEF_VEC_ALLOC_O_STACK, DEF_VEC_ALLOC_FUNC_O_STACK): Define.
10948         (DEF_VEC_ALLOC_I_STACK, DEF_VEC_ALLOC_FUNC_I_STACK): Define.
10949         * vec.c (void_p): New type.  Call DEF_VEC_P and DEF_VEC_ALLOC_P
10950         for void_p.
10951         (stack_vecs): New static variable.
10952         (vec_stack_p_reserve_exact_1): New function.
10953         (vec_stack_o_reserve_1): New static function.
10954         (vec_stack_p_reserve, vec_stack_p_reserve_exact): New functions.
10955         (vec_stack_o_reserve, vec_stack_o_reserve_exact): New functions.
10956         (vec_stack_free): New function.
10957         * df-scan.c (df_ref): Use DEF_VEC_P and DEF_VEC_ALLOC_P_STACK.
10958         (VEC_df_ref_stack_alloc): Define.
10959         (df_mw_hardreg_ptr): New type.  Use DEF_VEC_P and
10960         DEF_VEC_ALLOC_P_STACK.
10961         (VEC_df_mw_hardreg_ptr_stack_alloc): Define.
10962         (struct df_collection_rec): Change _vec fields to VEC.  Remove
10963         _use fields.
10964         (df_free_collection_rec): Adjust for new fields.
10965         (df_insn_rescan): Use new df_collection_rec fields.
10966         (df_notes_rescan, df_canonize_collection_rec): Likewise.
10967         (df_ref_create_structure, df_ref_record): Likewise.
10968         (df_get_conditional_uses, df_get_call_refs): Likewise.
10969         (df_insn_refs_collect, df_bb_refs_collect): Likewise.
10970         (df_bb_refs_record, df_record_entry_block_defs): Likewise.
10971         (df_record_exit_block_uses, df_bb_verify): Likewise.
10972         (df_swap_refs): Change ref_vec parameter to VEC.  Change all callers.
10973         (df_sort_and_compress_refs): Change ref_vec parameter to VEC.
10974         Remove count parameter.  Change return type to void.  Change all
10975         callers.
10976         (df_sort_and_compress_mws): Change mw_vec parameter to VEC.
10977         Remove count parameter.  Change return type to void.  Change all
10978         callers.
10979         (df_install_refs): Change old_vec parameter to VEC.  Remove count
10980         parameter.  Change all callers.
10981         (df_install_mws): Change old_vec parameter to VEC.  Remove count
10982         parameter.  Change all callers.
10983         (df_refs_verify): Change new_rec parameter to VEC.  Change call
10984         callers.
10985         (df_mws_verify): Likewise.
10986
10987 2009-06-10  Alexandre Oliva  <aoliva@redhat.com>
10988
10989         * gcc.c (compare_files): Cast munmap argumento to caddr_t.
10990
10991 2009-06-10  H.J. Lu  <hongjiu.lu@intel.com>
10992
10993         * doc/extend.texi: Add description for __builtin_ia32_crc32di.
10994
10995 2009-06-10  Anthony Green  <green@moxielogic.com>
10996
10997         * config/moxie/crti.asm: New file.
10998         * config/moxie/crtn.asm: New file.
10999         * config/moxie/moxie.c: New file.
11000         * config/moxie/moxie.h: New file.
11001         * config/moxie/sfp-machine.h: New file.
11002         * config/moxie/moxie-protos.h: New file.
11003         * config/moxie/t-moxie: Created.
11004         * config/moxie/t-moxie-softfp: Created.
11005         * config/moxie/moxie.md: Created.
11006         * config/moxie/constraints.md: Created.
11007         * config.gcc: Add moxie support.
11008         * doc/md.texi (Machine Constraints): Add moxie constraints.
11009         * doc/contrib.texi (Contributors): Mention moxie port.
11010         * doc/install.texi (Specific): Mention the moxie port.
11011
11012 2009-06-09  Ian Lance Taylor  <iant@google.com>
11013
11014         * system.h (HAVE_DESIGNATED_INITIALIZERS): Don't define if
11015         compiling with C++.
11016         * optabs.c (optab_table): Only use designated initializers if
11017         HAVE_DESIGNATED_INITIALIZERS is defined.
11018         (convert_optab_table): Likewise.
11019         (init_optabs): Always call init_insn_codes if
11020         HAVE_DESIGNATED_INITIALIZERS is not defined.
11021
11022 2009-06-09  Ian Lance Taylor  <iant@google.com>
11023
11024         * targhooks.c (default_builtin_vectorized_function): Change fn
11025         parameter to unsigned int.
11026         (default_builtin_vectorized_conversion): Change code parameter to
11027         unsigned int.
11028         (default_builtin_reciprocal): Change fn parameter to unsigned int.
11029         * targhooks.h: Update declarations.
11030         * config/rs6000/rs6000.c (rs6000_builtin_conversion): Change code
11031         parameter to unsigned int.
11032
11033         * c-typeck.c (comptypes_check_enum_int): New static function.
11034         (comptypes_internal): Add enum_and_int_p parameter.  Change all
11035         callers.
11036         (comp_target_types): Add location parameter.  Change all callers.
11037         (tagged_types_tu_compatible_p): Add enum_and_int_p parameter.
11038         Change all callers.
11039         (function_types_compatible_p, type_lists_compatible_p): Likewise.
11040         (build_conditional_expr): Add colon_loc parameter.  Change all
11041         callers.
11042         (convert_for_assignment): Add location parameter.  Change all callers.
11043         * c-parser.c (c_parser_conditional_expression): Pass location of
11044         colon to build_conditional_expr.
11045         * c-tree.h (build_conditional_expr): Update declaration.
11046
11047 2009-06-09  Sebastian Pop  <sebastian.pop@amd.com>
11048
11049         * graphite.c: Revert previous patch.
11050
11051 2009-06-09  Sebastian Pop  <sebastian.pop@amd.com>
11052
11053         PR bootstrap/40103
11054         * graphite.c: Remove pragma GCC diagnostic warning "-Wc++-compat".
11055
11056 2009-06-09  Ghassan Shobaki  <ghassan.shobaki@amd.com>
11057
11058         * tree-ssa-loop-prefetch.c
11059         (loop_prefetch_arrays): Fixed a portability problem in printf format
11060         string.
11061
11062 2009-06-09  Martin Jambor  <mjambor@suse.cz>
11063
11064         PR tree-optimization/40351
11065         * tree-sra.c (propagate_subacesses_accross_link): Check that a
11066         refrence to a potential artifical subaccess can be constructed.
11067
11068 2009-06-08  Kaz Kojima  <kkojima@gcc.gnu.org>
11069
11070         * config/sh/sh-protos.h (sh_optimization_options): Declare.
11071         (sh_override_options): Likewise.
11072         * config/sh/sh.c: Include params.h.
11073         (sh_optimization_options): New.
11074         (sh_override_options): Likewise.
11075         * config/sh/sh.c (OPTIMIZATION_OPTIONS): Use sh_optimization_options.
11076         (OVERRIDE_OPTIONS): Use sh_override_options.
11077
11078 2009-06-08  Jakub Jelinek  <jakub@redhat.com>
11079
11080         * dwarf2out.c (emit_cfa_remember): New variable.
11081         (add_fde_cfi): If emit_cfa_remember, recurse to add
11082         DW_CFA_remember_state first.
11083         (dwarf2out_begin_epilogue): Don't add_fde_cfi DW_CFA_remember_state,
11084         instead just set emit_cfa_remember.
11085
11086 2009-06-08  Jan Hubicka  <jh@suse.cz>
11087
11088         PR debug/40126
11089         * dwarf2out.c (dwarf2out_abstract_function): Free decl_loc_table.
11090
11091 2009-06-08  Jan Hubicka  <jh@suse.cz>
11092
11093         PR middle-end/39834
11094         * cgraphunit.c (save_inline_function_body): Do not copy transform
11095         hooks for saved inline bodies.
11096         * ipa-passes.c (do_per_function): Do not add the hoks multiple times
11097         for given function.
11098
11099 2009-06-08  Adam Nemet  <anemet@caviumnetworks.com>
11100
11101         * jump.c (returnjump_p): Handle delayed branches.  Add missing
11102         function comment.
11103
11104 2009-06-08  Jan Hubicka  <jh@suse.cz>
11105
11106         PR middle-end/40102
11107         * cgraph.c (cgraph_create_edge_including_clones): Also asume that the
11108         original node might've been modified.
11109         * tree-inline.c (copy_bb): Do not assume that all clones are the same.
11110
11111 2009-06-08  Jakub Jelinek  <jakub@redhat.com>
11112
11113         * tree-object-size.c (addr_object_size): Add OSI argument.
11114         Handle also INDIRECT_REF with SSA_NAME inside of it as base address.
11115         (compute_builtin_object_size, expr_object_size): Adjust callers.
11116         (plus_stmt_object_size): Call addr_object_size instead of
11117         compute_builtin_object_size.
11118
11119 2009-06-08  Ghassan Shobaki  <ghassan.shobaki@amd.com>
11120             Dwarakanath Rajagopal  <dwarak.rajagopal@amd.com>
11121
11122         * tree-ssa-loop-prefetch.c
11123         (gather_memory_references): Introduced a counter for the number of
11124         memory references.
11125         (anything_to_prefetch_p): Introduced a counter for the number of
11126         prefetches.
11127         (is_loop_prefetching_profitable): New function with a cost model
11128         for prefetching.
11129         (loop_prefetch_arrays): Use the new cost model to determine if
11130         prefetching is profitable.
11131         * params.def (MIN_INSN_TO_PREFETCH_RATIO,
11132         PREFETCH_MIN_INSN_TO_MEM_RATIO): New parameters.
11133         * params.h (MIN_INSN_TO_PREFETCH_RATIO,
11134         PREFETCH_MIN_INSN_TO_MEM_RATIO): New parameters.
11135         * doc/invoke.texi (MIN_INSN_TO_PREFETCT_RATIO,
11136         PREFETCH_MIN_INSN_TO_MEM_RATIO): New parameters.
11137
11138 2009-06-08  Michael Matz  <matz@suse.de>
11139
11140         PR debug/40012
11141         * cfgexpand.c (set_rtl): Store place also in DECL_RTL, if all
11142         partitions use the same.
11143         (expand_one_var): Deal with DECL_RTL sometimes begin set also
11144         for basevars of SSA_NAMEs.
11145         (expand_used_vars): Reset TREE_USED for basevars of SSA_NAMEs,
11146         to not expand them twice.
11147         (gimple_expand_cfg): Clear DECL_RTL for those decls that have
11148         multiple places.
11149
11150 2009-06-08  Alexandre Oliva  <aoliva@redhat.com>
11151
11152         * common.opt (fcompare-debug=, fcompare-debug-second): New.
11153         (fdump-final-insns=, gtoggle): New.
11154         * doc/invoke.texi: Document them.
11155         * final.c (rest_of_clean_state): Dump final insn stream.
11156         * gcc.c (invoke_as): Hook in -fcompare-debug.
11157         (static_spec_functions): Add compare-debug-dump-opt,
11158         compare-debug-self-opt and compare-debug-auxbase-opt.
11159         (compare_debug, compare_debug_second, compare_debug_opt): New.
11160         (switches_debug_check, n_switches_debug_check): New.
11161         (debug_auxbase_opt, debug_check_temp_file): New.
11162         (process_command): Handle -fno-compare-debug, -fcompare-debug and
11163         -fcompare-debug=*.
11164         (do_self_spec): Handle arguments after switches.
11165         (do_spec_1): Add .gk extension to temp file basenames for compare.
11166         (check_live_switch): Take SWITCH_IGNORE into account, and earlier.
11167         (cc1_options): Use it instead of normal auxbase computation for
11168         the second compare-debug compilation.
11169         (compare_files): New.
11170         (main): Set up and implement compare debug mode.
11171         (compare_debug_dump_opt_spec_function): New.
11172         (compare_debug_self_opt_spec_function): New.
11173         (compare_debug_auxbase_opt_spec_function): New.
11174         * toplev.c (process_options): Handle flag_gtoggle,
11175         flag_dump_final_insns.
11176         * coverage.c (coverage_begin_output): Don't overwrite .gcno file
11177         during -fcompare-debug-second compilation.
11178
11179 2009-06-07  Ian Lance Taylor  <iant@google.com>
11180
11181         * dwarf2.h (enum dwarf_location_atom): Add INTERNAL_DW_OP_tls_addr.
11182         * dwarf2out.c (INTERNAL_DW_OP_tls_addr): Don't #define.
11183
11184         * c-common.c (c_do_switch_warnings): Don't exit early for -Wswitch
11185         with no default node.  Change warning with %H to warning_at.
11186         Don't clear warn_switch around case checking.
11187         * doc/invoke.texi (Warning Options): Clarify distinction between
11188         -Wswitch and -Wswitch-enum.
11189
11190 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
11191
11192         * tree-pass.h (TODO_update_ssa_any): Document internal use only.
11193
11194 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
11195
11196         * gbl-ctors.h: Add header guard.
11197
11198 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
11199
11200         * tree-flow.h (make_value_handle, set_value_handle, sort_vuses,
11201         sort_vuses_heap, vn_lookup_or_add, vn_lookup_or_add_with_stmt,
11202         vn_lookup_or_add_with_vuses, vn_add, vn_add_with_vuses,
11203         vn_lookup_with_stmt, vn_lookup, vn_lookup_with_vuses): Remove
11204         prototypes for removed functions.
11205         (expressions_equal_p): Move to ...
11206         * tree-ssa-sccvn.h: ... here and ...
11207         * matrix-reorg.c: ... adjust includes.
11208
11209 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
11210
11211         * ipa-struct-reorg.c (do_reorg_1): Fix whitespace in dump output.
11212
11213 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
11214
11215         * c-decl.c (finish_decl): Use bool for variable was_incomplete.
11216         (finish_function): Remove erroneous whitespace.
11217
11218 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
11219
11220         * tree-cfg.c (gimple_merge_blocks): Commentary typo fix.
11221         (verify_stmts): Print statement who's gimple_bb is set to a wrong BB
11222
11223 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
11224
11225         * errors.c (internal_error): Commentary typo fix.
11226         * gimple-iterator.c (gsi_insert_seq_on_edge): Ditto.
11227         * tree-ssa-pre.c: Ditto.
11228
11229 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
11230
11231         * basic-block.h (ENTRY_BLOCK, EXIT_BLOCK): Document that neither of
11232         them is supposed to hold actual statements.
11233
11234 2009-06-06  Ian Lance Taylor  <iant@google.com>
11235
11236         * doc/extend.texi (Attribute Syntax): Document that C++ labels on
11237         empty statements can now have attributes.
11238
11239 2009-06-05  Shujing Zhao  <pearly.zhao@oracle.com>
11240
11241         * config/mips/mips.c: Use REG_P and CONST_INT_P where applicable.
11242         * config/mips/mips.md: Ditto.
11243
11244 2009-06-05  Nathan Froyd  <froydnj@codesourcery.com>
11245
11246         * config/rs6000/eabi.asm (__eabi_convert): Don't define if
11247         _RELOCATABLE.
11248         (__eabi_uconvert): Likewise.
11249
11250 2009-06-05  Nathan Froyd  <froydnj@codesourcery.com>
11251
11252         * config/rs6000/ppc-asm.h: Protect auto-host.h inclusion and
11253         CFI_* definitions with IN_GCC.
11254
11255 2009-06-05  David Edelsohn  <edelsohn@gnu.org>
11256
11257         * xcoffout.h (xcoffout_source_line): Update prototype.
11258
11259 2009-06-05  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
11260
11261         * builtins.c (do_mpc_ckconv, do_mpc_arg1): Use
11262         mpc_realref/mpc_imagref instead of MPC_RE/MPC_IM.
11263
11264 2009-06-05  Jakub Jelinek  <jakub@redhat.com>
11265
11266         PR middle-end/40340
11267         * tree-ssa-live.c (remove_unused_scope_block_p): Don't prune
11268         inlined_function_outer_scope_p blocks for artificial inlines
11269         even at -g0/-g1.
11270         * tree.c (tree_nonartificial_location): Rewrite using
11271         block_nonartificial_location.
11272
11273 2009-06-05  Revital Eres  <eres@il.ibm.com>
11274             Leehod Baruch  <leehod@il.ibm.com>
11275
11276         * expr.c (expand_assignment): Expand MISALIGNED_INDIRECT_REF.
11277         (expand_expr_real_1): Remove comment.
11278         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment):
11279         Vectorize misaligned access when the target supports it.
11280         (vect_supportable_dr_alignment): Check for unaligned access support.
11281         * tree-vect-stmts.c (vectorizable_store): Generate misaligned store
11282         and remove asset.
11283
11284 2009-06-05  Julian Brown  <julian@codesourcery.com>
11285
11286         * config/arm/ieee754-df.S (cmpdf2): Avoid writing below SP.
11287         * config/arm/ieee754-sf.S (cmpsf2): Likewise.
11288
11289 2009-06-05  Richard Guenther  <rguenther@suse.de>
11290
11291         PR bootstrap/40350
11292         * dwarf2out.c (dwarf2out_begin_function): Mark discriminator
11293         as possibly unused.
11294
11295 2009-06-05  Jakub Jelinek  <jakub@redhat.com>
11296
11297         * config/s390/s390.c (global_not_special_regno_p): New static inline.
11298         (save_gprs): Don't tell unwinder when a global register is saved.
11299         (s390_emit_epilogue): Emit needed epilogue unwind info.
11300
11301 2009-06-05  Alexandre Oliva  <aoliva@redhat.com>
11302
11303         * dwarf2out.c (deferred_asm_name): New.
11304         (add_name_and_src_coords_attributes): Defer creation of
11305         DW_AT_MIPS_linkage_name attribute if DECL_ASSEMBLER_NAME was not
11306         computed yet.
11307         (move_linkage_attr): New.
11308         (dwarf2out_finish): Revisit deferrals and emit attributes at the
11309         right place.
11310
11311 2009-06-05  Alexandre Oliva  <aoliva@redhat.com>
11312
11313         * tree-nested.c (finalize_nesting_tree_1): Declare the
11314         frame_decl in the binding tree.
11315
11316 2009-06-04  Cary Coutant  <ccoutant@google.com>
11317
11318         * basic-block.h (struct basic_block_def): Add discriminator field.
11319         * dbxout.c (dbxout_source_line): Add new parameter.  Change all
11320         callers.
11321         * debug.c (do_nothing_debug_hooks): Add additional entry.
11322         (debug_nothing_int_charstar_int): New function.
11323         * debug.h (struct gcc_debug_hooks): Add parameter to source_line hook.
11324         (debug_nothing_int_charstar_int): New declaration.
11325         * dwarf2out.c (dwarf2out_source_line): Add new parameter.  Write
11326         discriminator value in .loc directive.
11327         * final.c (last_discriminator): New variable.
11328         (discriminator): New variable.
11329         (final_start_function): Initialize above variables, pass current
11330         discriminator to debug hook.
11331         (notice_source_line): Check for discriminator change.
11332         * gimple-pretty-print.c (dump_bb_header): Print discriminator value.
11333         * sdbout.c (sdbout_source_line): New parameter.
11334         * tree-cfg.c (struct locus_discrim_map): New structure type.
11335         (discriminator_per_locus): New hash table.
11336         (build_gimple_cfg): Allocate and free discriminator hash table.
11337         (make_edges): Call assign_discriminator.
11338         (locus_map_hash): New function.
11339         (locus_map_eq): New function.
11340         (next_discriminator_for_locus): New function.
11341         (same_line_p): New function.
11342         (assign_discriminator): New function.
11343         (make_cond_expr_edges): Call assign_discriminator.
11344         (make_gimple_switch_edges): Likewise.
11345         (first_non_label_stmt): New function.
11346         * vmsdbgout.c (vmsdbgout_source_line): Add new parameter.  Change
11347         all callers.
11348         * xcoffout.c (xcoffout_source_line): Add new parameter.
11349
11350         * configure.ac (gcc_cv_as_discriminator): New configury check for
11351         gas support for discriminator.
11352         * configure: Regenerate.
11353         * config.in: Regenerate.
11354
11355 2009-06-04  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
11356
11357         * config/arm/arm.c (thumb2_legitimate_index_p): Initialize
11358         val after checking for integers.
11359
11360 2009-06-04  Uros Bizjak  <ubizjak@gmail.com>
11361
11362         * config/i386/i386.h (X86_64_MS_REGPARM_MAX): Rename from
11363         X64_REGPARM_MAX.
11364         (REGPARM_MAX): Use X86_64_MS_REGPARM_MAX.
11365         (X86_64_MS_SSE_REGPARM_MAX): Rename from X64_SSE_REGPARM_MAX.
11366         (SSE_REGPARM_MAX): Use X86_64_MS_SSE_REGPARM_MAX.
11367         * config/i386/i386.c: Use X86_64_MS_REGPARM_MAX instead of
11368         X64_REGPARM_MAX.  Use X86_64_MS_SSE_REGPARM_MAX instead of
11369         X64_SSE_REGPARM_MAX.
11370         * config/i386/i386.md: Use X86_64_MS_SSE_REGPARM_MAX instead of
11371         X64_SSE_REGPARM_MAX.
11372
11373 2009-06-04  Alexandre Oliva  <aoliva@redhat.com>
11374
11375         * gcc.c (report_times_to_file): New.
11376         (execute): Implement it.
11377         (process_command): Support -time=.
11378         * doc/invoke.texi: Document it.
11379
11380 2009-06-04  Alexandre Oliva  <aoliva@redhat.com>
11381
11382         * tree-ssa-live.c (remove_unused_scope_block_p): Keep variables
11383         that have value exprs.
11384
11385 2009-06-04  Alexandre Oliva  <aoliva@redhat.com>
11386
11387         * dwarf2asm.c (dw2_force_const_mem): Defer creation of
11388         declarations for constants until...
11389         (dw2_output_indirect_constant_1): ... this point.
11390
11391 2009-06-04  Richard Earnshaw  <rearnsha@arm.com>
11392
11393         PR target/10242
11394         * arm.md (arm_addsi3): Don't try to split an add with an
11395         eliminable register until after reload has completed.
11396
11397 2009-06-03  Ian Lance Taylor  <iant@google.com>
11398
11399         * dummy-checksum.c (executable_checksum): Use EXPORTED_CONST.
11400         * genattrtab.c (write_length_unit_log): Likewise.
11401         * genchecksum.c (dosum): Likewise.
11402         * gengtype.c (write_rtx_next): Likewise.
11403         (finish_root_table, write_roots): Likewise.
11404         * gimple.c (gimple_ops_offset_): Likewise.
11405         * tree-nomudflap.c (gt_ggc_r_gt_tree_mudflap_h): Likewise.
11406         * config/arc/arc.c (arc_attribute_table): Likewise.
11407         * config/arm/arm.c (arm_attribute_table): Likewise.
11408         * config/avr/avr.c (avr_attribute_table): Likewise.
11409         * config/crx/crx.c (crx_attribute_table): Likewise.
11410         * config/m32r/m32r.c (m32r_attribute_table): Likewise.
11411         * config/m68hc11/m68hc11.c (m68hc11_attribute_table): Likewise.
11412         * config/mcore/mcore.c (mcore_attribute_table): Likewise.
11413         * config/rs6000/rs6000.c (rs6000_attribute_table): Likewise.
11414         * config/sh/sh.c (sh_attribute_table): Likewise.
11415         * config/sparc/sparc.c (sparc_attribute_table): Likewise.
11416         * config/spu/spu.c (spu_attribute_table): Likewise.
11417         * config/v850/v850.c (v850_attribute_table): Likewise.
11418
11419         * config/alpha/alpha.c (vms_attribute_table): Make static.
11420         * config/bfin/bfin.c (bfin_attribute_table): Likewise.
11421         * config/h8300/h8300.c (h8300_attribute_table): Likewise.
11422         * config/mips/mips.c (mips_attribute_table): Likewise.
11423
11424         * Makefile.in (dummy-checksum.o): Depend upon $(CONFIG_H) and
11425         $(SYSTEM_H).
11426         (cc1-checksum.o): Likewise.
11427
11428 2009-06-03  Steve Ellcey  <sje@cup.hp.com>
11429
11430         * config/ia64/vect.md (*movv2sf_internal): Handle big endian case.
11431
11432 2009-06-03  Jakub Jelinek  <jakub@redhat.com>
11433
11434         * config/rs6000/rs6000.c (rs6000_emit_stack_reset): Return generated
11435         insn if it is changing sp.  Use gen_add3_insn instead of
11436         conditionally gen_addsi3 and gen_adddi3.
11437         (offset_below_red_zone_p): New static inline function.
11438         (rs6000_emit_epilogue): Emit needed epilogue unwind info.
11439         Use gen_add3_insn instead of conditionally gen_addsi3 and gen_adddi3.
11440         * config/rs6000/ppc-asm.h: Include auto-host.h.
11441         (CFI_STARTPROC, CFI_ENDPROC, CFI_DEF_CFA_REGISTER, CFI_OFFSET,
11442         CFI_RESTORE): Define.
11443         * config/rs6000/crtresxgpr.asm: Add unwind info.
11444         * config/rs6000/crtresxfpr.asm: Likewise.
11445         * config/rs6000/crtresgpr.asm: Likewise.
11446         * config/rs6000/crtresfpr.asm: Likewise.
11447         * config/rs6000/crtsavgpr.asm: Likewise.
11448         * config/rs6000/crtsavfpr.asm: Likewise.
11449
11450         * dwarf2out.c (output_cfi_directive): Pass 1 instead of 0 to second
11451         argument of DWARF2_FRAME_REG_OUT macros.
11452
11453 2009-06-03  Julian Brown  <julian@codesourcery.com>
11454
11455         * config/arm/arm.c (arm_hard_regno_mode_ok): Permit values of four
11456         words or less (including TImode) in core registers.
11457
11458 2009-06-03  Richard Guenther  <rguenther@suse.de>
11459
11460         PR middle-end/40328
11461         * fold-const.c (fold_convert): Fold the build COMPLEX_EXPR.
11462
11463 2009-06-03  Andrey Belevantsev  <abel@ispras.ru>
11464
11465         * statistics.c (statistics_counter_event): Do not record event
11466         in pass dump if its number == -1.
11467         (curr_statistics_hash): Add assert that we never get passes
11468         with static number == -1.
11469
11470 2009-06-03  Richard Guenther  <rguenther@suse.de>
11471             Andrey Belevantsev  <abel@ispras.ru>
11472
11473         * cfgexpand.c (discover_nonconstant_array_refs_r): Make only
11474         non-BLKmode arrays addressable.
11475
11476 2009-06-03  Maxim Kuvyrkov  <maxim@codesourcery.com>
11477
11478         * config/m68k/linux.h (HAVE_GAS_BALIGN_AND_P2ALIGN): Move to ...
11479         * config/m68k/m68k.h: ... here.
11480         * testsuite/gcc.dg/falign-labels.c (dg-options): Don't restrict for
11481         m68k and fido.
11482
11483 2009-06-03  Martin Jambor  <mjambor@suse.cz>
11484
11485         PR tree-optimization/40323
11486         * ipa-prop.c (get_ssa_def_if_simple_copy): Break if not single
11487         assignment.
11488
11489 2009-06-03  Richard Guenther  <rguenther@suse.de>
11490
11491         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Use DECL_SIZE
11492         consistently.
11493
11494 2009-06-03  Shujing Zhao  <pearly.zhao@oracle.com>
11495
11496         * config/sh/predicates.md: Use REG_P, MEM_P, CONST_INT_P, LABEL_P,
11497         JUMP_P, CALL_P, NONJUMP_INSN_P, NOTE_P, BARRIER_P and
11498         JUMP_TABLE_DATA_P where applicable.
11499         * config/sh/sh.c: Ditto.
11500         * config/sh/sh.h: Ditto.
11501         * config/sh/sh.md: Ditto.
11502         * config/sh/symbian.c: Ditto.
11503
11504 2009-06-03  Uros Bizjak  <ubizjak@gmail.com>
11505
11506         * config/i386/driver-i386.c (describe_cache): Optimize
11507         concatenation of strings.  Use snprintf instead of sprintf.
11508         (host_detect_local_cpu): Ditto.  Ignore -march and -mtune for native
11509         target when not compiling with GCC.
11510
11511 2009-06-02  Kaz Kojima  <kkojima@gcc.gnu.org>
11512
11513         * config/sh/sh.c: Revert last change.
11514         (sh_expand_epilogue): Emit a blockage insn before the frame
11515         pointer adjustment unconditionally.
11516
11517 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
11518
11519         * config/pa/pa-hpux.h (LINK_SPEC): Remove "%<fwhole-program".
11520         * config/pa/pa-hpux10.h (LINK_SPEC): Likewise.
11521         * config/pa/pa-hpux11.h (LINK_SPEC): Likewise.
11522         * gcc.c (set_collect_gcc_options): Don't add -fwhole-program
11523         to COLLECT_GCC_OPTIONS.
11524
11525 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
11526
11527         * collect2.c (target_system_root): New variable.
11528         (main): Handle --sysroot=.
11529         (ignore_library): Strip the sysroot from the library path.
11530
11531 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
11532
11533         * Makefile.in (COLLECT2_OBJS): Add collect2-aix.o.
11534         (collect2.o): Depend on collect2-aix.h.
11535         (collect2-aix.o): New rule.
11536         * collect2-aix.h: New file.
11537         * collect2-aix.c: Likewise.
11538         * collect2.c: Include collect2-aix.h.  Don't undefine
11539         OBJECT_FORMAT_COFF if CROSS_AIX_SUPPORT is defined.
11540         Guard native includes with #ifndef CROSS_DIRECTORY_STRUCTURE.
11541         Use TARGET_AIX_VERSION instead of _AIX51.
11542         * config/rs6000/aix43.h (TARGET_AIX_VERSION): Define.
11543         * config/rs6000/aix51.h (TARGET_AIX_VERSION): Likewise.
11544         * config/rs6000/aix52.h (TARGET_AIX_VERSION): Likewise.
11545         * config/rs6000/aix53.h (TARGET_AIX_VERSION): Likewise.
11546         * config/rs6000/aix61.h (TARGET_AIX_VERSION): Likewise.
11547
11548 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
11549
11550         * collect2.c (ignore_library): Avoid premature post-increment
11551         and null deference.
11552
11553 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
11554
11555         * Makefile.in (libgcc.mvars): Add TARGET_SYSTEM_ROOT.
11556         * config/rs6000/aix.h (LINK_SYSCALLS_SPEC): Add %R to the
11557         !CROSS_DIRECTORY_STRUCTURE alternative and use it for
11558         CROSS_DIRECTORY_STRUCTURE too.
11559         (LINK_LIBG_SPEC): Likewise.
11560         (LIB_SPEC): Add %R to sysroot paths.
11561         * config/rs6000/aix43.h (CPP_SPEC): Add %R to sysroot paths.
11562         (CPLUSPLUS_CPP_SPEC, LIB_SPEC): Likewise.
11563         * config/rs6000/aix51.h: As for aix43.h.
11564         * config/rs6000/aix52.h: Likewise.
11565         * config/rs6000/aix53.h: Likewise.
11566         * config/rs6000/aix61.h: Likewise.
11567         * config/rs6000/t-aix52 (SHLIB_LINK): Add $(TARGET_SYSTEM_ROOT)
11568         to the beginning of sysroot paths.
11569
11570 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
11571
11572         * print_rtl (print_rtx): Don't print modes in EXPR_LISTs and
11573         INSN_LISTs that are out of the REG_NOTE range.
11574
11575 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
11576
11577         * loop-unroll.c (struct iv_to_split): Add pointer to next.
11578         (struct var_to_expand): Likewise.
11579         (struct opt_info): Add head and tail for linked lists of the above.
11580         (analyze_insn_to_expand_var): Initialize next.
11581         (analyze_iv_to_split_insn): Likewise.
11582         (analyze_insns_in_loop): Create linked lists.
11583         (allocate_basic_variable): Simplify for use without hash table.
11584         (insert_var_expansion_initialization): Likewise, make it type-safer.
11585         (combine_var_copies_in_loop_exit): Likewise.
11586         (apply_opt_in_copies): Walk lists rather than hash tables.
11587         (release_var_copies): Simplified and inlined by hand into...
11588         (free_opt_info): ... this function.
11589
11590 2009-06-02  Richard Guenther  <rguenther@suse.de>
11591
11592         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Use DECL_SIZE
11593         for field decls.
11594
11595 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
11596
11597         * cfgexpand.c (gimple_expand_cfg): Discard the source location
11598         only for builtins that are not overridden.
11599
11600 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
11601
11602         * gengtype.c (adjust_field_rtx_def): Add NOTE_INSN_DELETED_LABEL's
11603         label string.
11604
11605 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
11606
11607         * df-core.c (df_ref_debug): Honor -fdump-noaddr.
11608
11609 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
11610
11611         * combine.c (move_deaths): Compare LUIDs within the same BB only.
11612
11613 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
11614
11615         * common.opt (fdump-unnumbered-links): New.
11616         * doc/invoke.texi (-fdump-unnumbered-links): Document it.
11617         * print-rtl.c (flag_dump_unnumbered_links): New.
11618         (print_rtx): Test it.
11619
11620 2009-06-02  Richard Earnshaw  <rearnsha@arm.com>
11621
11622         * arm.c (arm_get_frame_offsets): Prefer using r3 for padding a
11623         push/pop multiple to 8-byte alignment.
11624
11625 2009-06-01  Jakub Jelinek  <jakub@redhat.com>
11626
11627         * config/i386/i386.c (queued_cfa_restores): New static variable.
11628         (ix86_add_cfa_restore_note, ix86_add_queued_cfa_restore_notes): New
11629         functions.
11630         (pro_epilogue_adjust_stack): Call ix86_add_queued_cfa_restore_notes.
11631         (ix86_emit_restore_reg_using_pop): Add RED_OFFSET argument.
11632         Set RTX_FRAME_RELATED_P immediately after adding a REG_CFA_* note.
11633         Call ix86_add_cfa_restore_note instead of adding REG_CFA_OFFSET
11634         note unconditionally.
11635         (ix86_emit_restore_regs_using_mov): Likewise.
11636         (ix86_emit_restore_sse_regs_using_mov): Likewise.
11637         (ix86_emit_restore_regs_using_pop): Add RED_OFFSET argument, pass
11638         it through to ix86_emit_restore_reg_using_pop.
11639         (ix86_emit_leave): Add RED_OFFSET argument.  Call
11640         ix86_add_queued_cfa_restore_notes.  Call ix86_add_cfa_restore_note
11641         instead of adding REG_CFA_OFFSET note unconditionally.
11642         (ix86_expand_epilogue): Compute RED_OFFSET, pass it down to
11643         the above functions.  Call ix86_add_queued_cfa_restore_notes when
11644         needed.
11645
11646         * dwarf2out.c (dwarf2out_cfi_label): Add FORCE argument, if true,
11647         force output of the label even for dwarf2out_do_cfi_asm.
11648         (add_fde_cfi): If -g2 and above and cfi might change CFA,
11649         force creation of CFI label and chain DW_CFA_set_loc jumping to it
11650         for convert_cfa_to_fb_loc_list.  Adjust other dwarf2out_cfi_label
11651         caller.
11652         (dwarf2out_stack_adjust, dwarf2out_frame_debug,
11653         dwarf2out_begin_epilogue, dwarf2out_frame_debug_restore_state): Adjust
11654         dwarf2out_cfi_label callers.
11655         * tree.h (dwarf2out_cfi_label): Adjust prototype.
11656         * config/arm/arm.c (thumb_pushpop, thumb1_output_function_prologue):
11657         Adjust dwarf2out_cfi_label callers.
11658         * config/vax/vax.c (vax_output_function_prologue): Likewise.
11659
11660         * config/i386/i386.h (struct machine_cfa_state,
11661         struct machine_function): Guard with ifndef USED_FOR_TARGET
11662         instead of not IN_LIBGCC2 and not in IN_TARGET_LIBS.
11663
11664         PR other/40024
11665         * emutls.c (__emutls_get_address): Change arr->size to mean number
11666         of allocated arr->data entries instead of # of slots + 1.
11667
11668         PR middle-end/40316
11669         * recog.c (peep2_reinit_state): New function.
11670         (peephole2_init_state): Use it at the end of a basic block and also
11671         when seeing a RTX_FRAME_RELATED_P insn.
11672
11673 2009-06-01  Steve Ellcey  <sje@cup.hp.com>
11674
11675         * ia64.md (floatdirf2, fix_truncrfdi, floatunsdirf,
11676         fixuns_truncrfdi2): New.
11677         (fix_truncxfdi2_alts, fixuns_truncxfdi2_alts,
11678         *nmaddsf4_alts, *nmadddf4_alts, *nmadddf4_truncsf_alts,
11679         *mulxf3_alts, *mulxf3_truncsf_alts, *mulxf3_truncdf_alts,
11680         *maddxf4_alts, *maddxf4_alts_truncsf, *maddxf4_alts_truncdf,
11681         *nmaddxf4_alts, *nmaddxf4_truncsf_alts, *nmaddxf4_truncdf_alts,
11682         *recip_approx): Remove.
11683         (divsi3 modsi3, udivsi3, umodsi3, divsi3_internal, divdi3,
11684         moddi3, udivdi3, umoddi3, divdi3_internal_lat, divdi3_internal_thr,
11685         divsf3, sqrtsf2, divdf3, sqrtdf2, divxf3, sqrtxf2): Modify and
11686         move to div.md.
11687         * div.md (fix_truncrfdi2_alts, fixuns_truncrfdi2_alt,
11688         setf_exp_rf): New.
11689
11690 2009-06-01  Ian Lance Taylor  <iant@google.com>
11691
11692         * attribs.c (register_attribute): Use CONST_CAST.
11693         * collect2.c (main): Use CONST_CAST2.
11694         (scan_prog_file): Likewise.
11695         * gcc.c (process_command, main): Likewise.
11696         * toplev.c (toplev_main): Likewise.
11697
11698         * c-typeck.c (handle_warn_cast_qual): New static function,
11699         partially broken out of build_c_cast.
11700         (build_c_cast): Call handle_warn_cast_qual.
11701         * doc/invoke.texi (Warning Options): Document new effect of
11702         -Wcast-qual.
11703
11704 2009-06-01  Aldy Hernandez  <aldyh@redhat.com>
11705
11706         * diagnostic.c (diagnostic_build_prefix): Always print columns.
11707         (diagnostic_report_current_module): Print columns.
11708         * common.opt (flag_show_column): Enable by default.
11709
11710 2009-06-01  Luis Machado  <luisgpm@br.ibm.com>
11711
11712         * alias.c (find_base_term): Check for NULL term before returning.
11713
11714 2009-06-01  Maxim Kuvyrkov  <maxim@codesourcery.com>
11715
11716         Revert due to PR40320:
11717         2009-06-01  Maxim Kuvyrkov  <maxim@codesourcery.com>
11718         * calls.c (emit_library_call_value_1): Don't force_operand for move
11719         and push insns.
11720
11721 2009-06-01  Olivier Hainque  <hainque@adacore.com>
11722             Eric Botcazou  <ebotcazou@adacore.com>
11723
11724         * tree.h (CONSTRUCTOR_BITFIELD_P): True if NODE, a FIELD_DECL, is
11725         to be processed as a bitfield for constructor output purposes.
11726         * output.h (initializer_constant_valid_for_bitfield_p): Declare
11727         new function.
11728         * varasm.c (oc_local_state): New type, output_constructor
11729         local state to support communication with helpers.
11730         (oc_outer_state): New type, output_constructor outer state of
11731         relevance in recursive calls.
11732         (output_constructor_array_range): New output_constructor helper,
11733         extracted code for an array range element.
11734         (output_constructor_regular_field): New output_constructor helper,
11735         extracted code for an element that is not a bitfield.
11736         (output_constructor_bitfield): New output_constructor helper,
11737         extracted code for a bitfield element.  Accept an OUTER state
11738         argument for recursive processing.  Recurse on record or array
11739         CONSTRUCTOR values, possibly past noop conversions.
11740         (initializer_constant_valid_for_bitfield_p): New predicate.  Whether
11741         VALUE is a valid constant-valued expression for use in a static
11742         bit-field initializer.
11743         (output_constructor): Rework to use helpers.  Accept and honor an
11744         OUTER state argument for recursive calls.  Return total size.  Be
11745         prepared for nested constructors initializing bitfields.
11746         (output_constant): Feed OUTER in calls to output_constructor.
11747
11748 2009-06-01  Maxim Kuvyrkov  <maxim@codesourcery.com>
11749
11750         * calls.c (emit_library_call_value_1): Don't force_operand for move
11751         and push insns.
11752
11753 2009-06-01  Nick Clifton  <nickc@redhat.com>
11754
11755         * doc/invoke.texi (IA-64 Options): Fix typo.
11756
11757 2009-06-01  Ira Rosen  <irar@il.ibm.com>
11758
11759         PR tree-optimization/39129
11760         * tree-vect-loop-manip.c (conservative_cost_threshold): Change the
11761         printed message.
11762         (vect_do_peeling_for_loop_bound): Use
11763         LOOP_REQUIRES_VERSIONING_FOR_ALIGNMENT and
11764         LOOP_REQUIRES_VERSIONING_FOR_ALIAS macros.
11765         (vect_loop_versioning): Likewise.
11766         (vect_create_cond_for_alias_checks): Fix indentation.
11767         * tree-vectorizer.h (struct _loop_vec_info): Fix indentation of the
11768         macros.
11769         (LOOP_REQUIRES_VERSIONING_FOR_ALIGNMENT): Define.
11770         (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Likewise.
11771         * tree-vect-loop.c (vect_analyze_loop_form): Change "too many BBs" to
11772         "control flow in loop".
11773         (vect_estimate_min_profitable_iters): Use
11774         LOOP_REQUIRES_VERSIONING_FOR_ALIGNMENT and
11775         LOOP_REQUIRES_VERSIONING_FOR_ALIAS macros.
11776         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
11777         (vect_create_data_ref_ptr): Don't mention array dimension in printing.
11778         * tree-vect-stmts.c (vectorizable_store): Replace the check that the
11779         statement belongs to a group of strided accesses with the exact code
11780         check.
11781         (vectorizable_load): Likewise.
11782         * tree-vect-slp.c (vect_analyze_slp_instance): Spell out "basic block".
11783         (vect_slp_analyze_bb, vect_slp_transform_bb): Likewise.
11784
11785 2009-06-01  Gerald Pfeifer  <gerald@pfeifer.com>
11786
11787         * config/freebsd-stdint.h: New file.
11788         * config.gcc (*-*-freebsd): Set use_gcc_stdint=wrap.
11789         Add freebsd-stdint.h to tm_file.
11790
11791 2009-06-01  Richard Earnshaw  <rearnsha@arm.com>
11792
11793         * arm/thumb2.md (thumb2_zero_extendhidi2): New insn and split.
11794         (thumb2_extendhidi2): Likewise.
11795
11796 2009-05-31  Ian Lance Taylor  <iant@google.com>
11797
11798         * regstat.c (regstat_n_sets_and_refs): Remove duplicate definition.
11799
11800 2009-05-31  Ian Lance Taylor  <iant@google.com>
11801
11802         * Makefile.in (except.o): Depend upon gt-except.h, not gt-$(EXCEPT_H).
11803         (ipa-cp.o): Depend upon $(FIBHEAP_H) and $(PARAMS_H).
11804         (ipa-reference.o): Depend upon gt-ipa-reference.h.
11805
11806 2009-05-31  Jason Merrill  <jason@redhat.com>
11807
11808         * tree-pretty-print.c (print_call_name): Take the callee, not the
11809         call itself.  Make non-static.  Use dump_function_name for functions.
11810         (dump_generic_node): Adjust.
11811         * diagnostic.h: Declare print_call_name.
11812         * gimple-pretty-print.c (dump_gimple_call): Use it.
11813
11814 2009-05-31  Kaz Kojima  <kkojima@gcc.gnu.org>
11815
11816         * config/sh/sh.md (ashldi3_std): New define_expand.
11817         (ashldi3): Use it.
11818
11819 2009-05-31  Kaz Kojima  <kkojima@gcc.gnu.org>
11820
11821         PR target/40313
11822         * config/sh/sh.c: Include debug.h.
11823         (sh_expand_epilogue): Emit a blockage insn before the frame
11824         pointer adjustment also when dwarf2out_do_frame returns true.
11825
11826 2009-05-31  Richard Earnshaw  <rearnsha@arm.com>
11827
11828         * arm/thumb2.md (thumb2_extendsidi2): Add a split sub-pattern.
11829         (thumb2_extendqidi2): New pattern.
11830
11831 2009-05-31  Ira Rosen  <irar@il.ibm.com>
11832
11833         * tree-vect-loop-manip.c (slpeel_update_phi_nodes_for_guard1): Don't
11834         mark phis for renaming.
11835         * tree-vectorizer.c (vect_memsyms_to_rename): Remove.
11836         (vectorize_loops): Don't allocate and free vect_memsyms_to_rename.
11837         Call mark_sym_for_renaming.
11838         * tree-vectorizer.h (vect_memsyms_to_rename): Remove.
11839         * tree-vect-loop.c (vect_transform_loop): Remove
11840         vect_memsyms_to_rename initialization and a call to
11841         mark_set_for_renaming.
11842
11843 2009-05-31  Jakub Jelinek  <jakub@redhat.com>
11844
11845         PR middle-end/40304
11846         * config/i386/i386.c (pro_epilogue_adjust_stack): Mark insns
11847         frame related even if !set_cfa && style < 0.
11848
11849 2009-05-30  Kai Tietz  <kai.tietz@onevision.com>
11850
11851         * config/i386/mingw-tls.c: New file.
11852         * config/i386/t-gthr-win32 (LIB2FUNCS_EXTRA): Add mingw-tls.c file.
11853         * gthr-win32.h (MINGW32_SUPPORTS_MT_EH): Define it for targets
11854         defining _WIN32 but not __CYGWIN__.
11855
11856 2009-05-29  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
11857
11858         * configure.ac: Add MPC support.
11859
11860         * config.in, configure: Regenerate.
11861
11862 2009-05-29  Richard Henderson  <rth@redhat.com>
11863
11864         * cfgcleanup.c (try_crossjump_to_edge): Only skip past
11865         NOTE_INSN_BASIC_BLOCK.
11866         * cfglayout.c (duplicate_insn_chain): Copy epilogue insn marks.
11867         Duplicate NOTE_INSN_EPILOGUE_BEG notes.
11868         * cfgrtl.c (can_delete_note_p): Allow NOTE_INSN_EPILOGUE_BEG
11869         to be deleted.
11870         * dwarf2out.c (struct cfa_loc): Change indirect field to bitfield,
11871         add in_use field.
11872         (add_cfi): Disable check redefining cfa away from drap.
11873         (lookup_cfa_1): Add remember argument; handle remember/restore.
11874         (lookup_cfa): Pass remember argument.
11875         (cfa_remember): New.
11876         (compute_barrier_args_size_1): Remove sibcall check.
11877         (dwarf2out_frame_debug_def_cfa): New.
11878         (dwarf2out_frame_debug_adjust_cfa): New.
11879         (dwarf2out_frame_debug_cfa_offset): New.
11880         (dwarf2out_frame_debug_cfa_register): New.
11881         (dwarf2out_frame_debug_cfa_restore): New.
11882         (dwarf2out_frame_debug): Handle REG_CFA_* notes.
11883         (dwarf2out_begin_epilogue): New.
11884         (dwarf2out_frame_debug_restore_state): New.
11885         (dw_cfi_oprnd1_desc): Handle DW_CFA_remember_state,
11886         DW_CFA_restore_state.
11887         (output_cfi_directive): Likewise.
11888         (convert_cfa_to_fb_loc_list): Likewise.
11889         (dw_cfi_oprnd1_desc): Handle DW_CFA_restore.
11890         * dwarf2out.h: Update.
11891         * emit-rtl.c (try_split): Don't split RTX_FRAME_RELATED_P.
11892         (copy_insn_1): Early out for null.
11893         * final.c (final_scan_insn): Call dwarf2out_begin_epilogue
11894         and dwarf2out_frame_debug_restore_state.
11895         * function.c (prologue, epilogue, sibcall_epilogue): Remove.
11896         (prologue_insn_hash, epilogue_insn_hash): New.
11897         (free_after_compilation): Adjust freeing accordingly.
11898         (record_insns): Create hash table if needed; push insns into
11899         hash instead of array.
11900         (maybe_copy_epilogue_insn): New.
11901         (contains): Search hash table instead of array.
11902         (sibcall_epilogue_contains): Remove.
11903         (thread_prologue_and_epilogue_insns): Split eh_return insns
11904         and mark them as epilogues.
11905         (reposition_prologue_and_epilogue_notes): Rewrite epilogue
11906         scanning in terms of basic blocks.
11907         * insn-notes.def (CFA_RESTORE_STATE): New.
11908         * jump.c (returnjump_p_1): Accept EH_RETURN.
11909         (eh_returnjump_p_1, eh_returnjump_p): New.
11910         * reg-notes.def (CFA_DEF_CFA, CFA_ADJUST_CFA, CFA_OFFSET,
11911         CFA_REGISTER, CFA_RESTORE): New.
11912         * rtl.def (EH_RETURN): New.
11913         * rtl.h (eh_returnjump_p, maybe_copy_epilogue_insn): Declare.
11914
11915         * config/bfin/bfin.md (UNSPEC_VOLATILE_EH_RETURN): Remove.
11916         (eh_return_internal): Use eh_return rtx; split w/ epilogue.
11917
11918         * config/i386/i386.c (gen_push): Update cfa state.
11919         (pro_epilogue_adjust_stack): Add set_cfa argument.  When true,
11920         add a CFA_ADJUST_CFA note.
11921         (ix86_dwarf_handle_frame_unspec): Remove.
11922         (ix86_expand_prologue): Update cfa state.
11923         (ix86_emit_restore_reg_using_pop): New.
11924         (ix86_emit_restore_regs_using_pop): New.
11925         (ix86_emit_leave): New.
11926         (ix86_emit_restore_regs_using_mov): Add CFA_RESTORE notes.
11927         (ix86_expand_epilogue): Add notes for unwinding the epilogue.
11928         * config/i386/i386.h (struct machine_cfa_state): New.
11929         (ix86_cfa_state): New.
11930         * config/i386/i386.md (UNSPEC_EH_RETURN): Remove.
11931         (eh_return_internal): Merge from eh_return_<mode>,
11932         use eh_return rtx, split w/ epilogue.
11933
11934 2009-05-29  Ian Lance Taylor  <iant@google.com>
11935
11936         * builtins.c (validate_gimple_arglist): Don't use va_arg with
11937         enum type.
11938         * calls.c (emit_library_call_value_1): Likewise.
11939
11940         * c-typeck.c (c_build_va_arg): New function.
11941         * c-tree.h (c_build_va_arg): Declare.
11942         * c-parser.c (c_parser_postfix_expression): Call c_build_va_arg
11943         instead of build_va_arg.
11944
11945 2009-05-29  Eric Botcazou  <ebotcazou@adacore.com>
11946
11947         * tree-ssa-loop-ivopts.c (strip_offset_1) <MULT_EXPR>: New case.
11948         (force_expr_to_var_cost) <NEGATE_EXPR>: Likewise.
11949         (ptr_difference_cost): Use affine combinations to compute it.
11950         (difference_cost): Likewise.
11951         (get_computation_cost_at): Compute more accurate cost for addresses
11952         if the ratio is a multiplier allowed in addresses.
11953         For non-addresses, consider that an additional offset or symbol is
11954         added only once.
11955
11956 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
11957
11958         * config/i386/i386.c (ix86_decompose_address): Avoid useless
11959         0 displacement.  Add 0 displacement if base is %[er]bp or %r13.
11960
11961         * config/i386/i386.md (prefix_data16, prefix_rep): Set to 0 for
11962         TYPE_SSE{MULADD,4ARG,IADD1,CVT1} by default.
11963         (prefix_rex): For UNIT_MMX don't imply the prefix by default
11964         if MODE_DI.
11965         (prefix_extra): Default to 2 for TYPE_SSE{MULADD,4ARG} and
11966         to 1 for TYPE_SSE{IADD1,CVT1}.
11967         (prefix_vex_imm8): Removed.
11968         (length_vex): Only pass 1 as second argument to
11969         ix86_attr_length_vex_default if prefix_extra is 0.
11970         (modrm): For TYPE_INCDEC only set to 0 if not TARGET_64BIT.
11971         (length): For prefix vex computation use length_immediate
11972         attribute instead of prefix_vex_imm8.
11973         (cmpqi_ext_3_insn, cmpqi_ext_3_insn_rex64,
11974         addqi_ext_1, addqi_ext_1_rex64, *testqi_ext_0, andqi_ext_0,
11975         *andqi_ext_0_cc, *iorqi_ext_0, *xorqi_ext_0, *xorqi_cc_ext_1,
11976         *xorqi_cc_ext_1_rex64): Override modrm attribute to 1.
11977         (extendsidi2_rex64, extendhidi2, extendqidi2, extendhisi2,
11978         *extendhisi2_zext, extendqihi2, extendqisi2, *extendqisi2_zext): Emit
11979         a space in between the operands.
11980         (*anddi_1_rex64, *andsi_1): Likewise.  Override prefix_rex to 1
11981         if one operand is 0xff and the other one si, di, bp or sp.
11982         (*andhi_1): Override prefix_rex to 1 if one operand is 0xff and the
11983         other one si, di, bp or sp.
11984         (*btsq, *btrq, *btcq, *btdi_rex64, *btsi): Add mode attribute.
11985         (*ffssi_1, *ffsdi_1, ctzsi2, ctzdi2): Add
11986         type and mode attributes.
11987         (*bsr, *bsr_rex64, *bsrhi): Add type attribute.
11988         (*cmpfp_i_mixed, *cmpfp_iu_mixed): For TYPE_SSECOMI, clear
11989         prefix_rep attribute and set prefix_data16 attribute iff MODE_DF.
11990         (*cmpfp_i_sse, *cmpfp_iu_sse): Clear prefix_rep attribute and set
11991         prefix_data16 attribute iff MODE_DF.
11992         (*movsi_1): For TYPE_SSEMOV MODE_SI set prefix_data16 attribute.
11993         (fix_trunc<mode>di_sse): Set prefix_rex attribute.
11994         (*adddi_4_rex64, *addsi_4): Use const128_operand instead of
11995         constm128_operand in length_immediate computation.
11996         (*addhi_4): Likewise.  Fix mode attribute to MODE_HI.
11997         (anddi_1_rex64): Use movzbl/movzwl instead of movzbq/movzwq.
11998         (*avx_ashlti3, sse2_ashlti3, *avx_lshrti3, sse2_lshrti3): Set
11999         length_immediate attribute to 1.
12000         (x86_fnstsw_1, x86_fnstcw_1, x86_fldcw_1): Fix length attribute.
12001         (*movdi_1_rex64): Override prefix_rex or prefix_data16 attributes
12002         for certain alternatives.
12003         (*movdf_nointeger, *movdf_integer_rex64, *movdf_integer): Override
12004         prefix_data16 attribute if MODE_V1DF.
12005         (*avx_setcc<mode>, *sse_setcc<mode>, *sse5_setcc<mode>): Set
12006         length_immediate to 1.
12007         (set_got_rex64, set_rip_rex64): Remove length attribute, set
12008         length_address to 4, set mode attribute to MODE_DI.
12009         (set_got_offset_rex64): Likewise.  Set length_immediate to 0.
12010         (fxam<mode>2_i387): Set length attribute to 4.
12011         (*prefetch_sse, *prefetch_sse_rex, *prefetch_3dnow,
12012         *prefetch_3dnow_rex): Override length_address attribute.
12013         (sse4_2_crc32<mode>): Override prefix_data16 and prefix_rex
12014         attributes.
12015         * config/i386/predicates.md (ext_QIreg_nomode_operand): New predicate.
12016         (constm128_operand): Removed.
12017         * config/i386/i386.c (memory_address_length): For
12018         disp && !index && !base in 64-bit mode account for SIB byte if
12019         print_operand_address can't optimize disp32 into disp32(%rip)
12020         and UNSPEC doesn't imply (%rip) addressing.  Add 1 to length
12021         for fs: or gs: segment.
12022         (ix86_attr_length_immediate_default): When checking if shortform
12023         is possible, truncate immediate to the length of the non-shortened
12024         immediate.
12025         (ix86_attr_length_address_default): Ignore MEM_P operands
12026         with X constraint.
12027         (ix86_attr_length_vex_default): Only check for DImode on
12028         GENERAL_REG_P operands.
12029         * config/i386/sse.md (<sse>_comi, <sse>_ucomi): Clear
12030         prefix_rep attribute, set prefix_data16 attribute iff MODE_DF.
12031         (sse_cvttps2pi): Clear prefix_rep attribute.
12032         (sse2_cvttps2dq, *sse2_cvtpd2dq, sse2_cvtps2pd): Clear prefix_data16
12033         attribute.
12034         (*sse2_cvttpd2dq): Don't clear prefix_rep attribute.
12035         (*avx_ashr<mode>3, ashr<mode>3, *avx_lshr<mode>3, lshr<mode>3,
12036         *avx_ashl<mode>3, ashl<mode>3): Set length_immediate attribute to 1
12037         iff operand 2 is const_int_operand.
12038         (*vec_dupv4si, avx_shufpd256_1, *avx_shufpd_<mode>,
12039         sse2_shufpd_<mode>): Set length_immediate attribute to 1.
12040         (sse2_pshufd_1): Likewise.  Set prefix attribute to maybe_vex
12041         instead of vex.
12042         (sse2_pshuflw_1, sse2_pshufhw_1): Set length_immediate to 1 and clear
12043         prefix_data16.
12044         (sse2_unpckhpd, sse2_unpcklpd, sse2_storehpd, *vec_concatv2df): Set
12045         prefix_data16 attribute for movlpd and movhpd instructions.
12046         (sse2_loadhpd, sse2_loadlpd, sse2_movsd): Likewise.  Override
12047         length_immediate for shufpd instruction.
12048         (sse2_movntsi, sse3_lddqu): Clear prefix_data16 attribute.
12049         (avx_cmpp<avxmodesuffixf2c><mode>3,
12050         avx_cmps<ssemodesuffixf2c><mode>3, *avx_maskcmp<mode>3,
12051         <sse>_maskcmp<mode>3, <sse>_vmmaskcmp<mode>3,
12052         avx_shufps256_1, *avx_shufps_<mode>, sse_shufps_<mode>,
12053         *vec_dupv4sf_avx, *vec_dupv4sf): Set length_immediate attribute to 1.
12054         (*avx_cvtsi2ssq, *avx_cvtsi2sdq): Set length_vex attribute to 4.
12055         (sse_cvtsi2ssq, sse2_cvtsi2sdq): Set prefix_rex attribute to 1.
12056         (sse2_cvtpi2pd, sse_loadlps, sse2_storelpd): Override
12057         prefix_data16 attribute for the first alternative to 1.
12058         (*avx_loadlps): Override length_immediate for the first alternative.
12059         (*vec_concatv2sf_avx): Override length_immediate and prefix_extra
12060         attributes for second alternative.
12061         (*vec_concatv2sf_sse4_1): Override length_immediate and
12062         prefix_data16 attributes for second alternative.
12063         (*vec_setv4sf_avx, *avx_insertps, vec_extract_lo_<mode>,
12064         vec_extract_hi_<mode>, vec_extract_lo_v16hi,
12065         vec_extract_hi_v16hi, vec_extract_lo_v32qi,
12066         vec_extract_hi_v32qi): Set prefix_extra and length_immediate to 1.
12067         (*vec_setv4sf_sse4_1, sse4_1_insertps, *sse4_1_extractps): Set
12068         prefix_data16 and length_immediate to 1.
12069         (*avx_mulv2siv2di3, *avx_mulv4si3, sse4_2_gtv2di3): Set prefix_extra
12070         to 1.
12071         (*avx_<code><mode>3, *avx_eq<mode>3, *avx_gt<mode>3): Set
12072         prefix_extra attribute for variants that don't have 0f prefix alone.
12073         (*avx_pinsr<ssevecsize>): Likewise.  Set length_immediate to 1.
12074         (*sse4_1_pinsrb, *sse2_pinsrw, *sse4_1_pinsrd, *sse4_1_pextrb,
12075         *sse4_1_pextrb_memory, *sse2_pextrw, *sse4_1_pextrw_memory,
12076         *sse4_1_pextrd): Set length_immediate to 1.
12077         (*sse4_1_pinsrd): Likewise.  Set prefix_extra to 1.
12078         (*sse4_1_pinsrq, *sse4_1_pextrq): Set prefix_rex and length_immediate
12079         to 1.
12080         (*vec_extractv2di_1_rex64_avx, *vec_extractv2di_1_rex64,
12081         *vec_extractv2di_1_avx, *vec_extractv2di_1_sse2): Override
12082         length_immediate to 1 for second alternative.
12083         (*vec_concatv2si_avx, *vec_concatv2di_rex64_avx): Override
12084         prefix_extra and length_immediate attributes for the first
12085         alternative.
12086         (vec_concatv2si_sse4_1): Override length_immediate to 1 for the
12087         first alternative.
12088         (*vec_concatv2di_rex64_sse4_1): Likewise.  Override prefix_rex
12089         to 1 for the first and third alternative.
12090         (*vec_concatv2di_rex64_sse): Override prefix_rex to 1 for the second
12091         alternative.
12092         (*sse2_maskmovdqu, *sse2_maskmovdqu_rex64): Override length_vex
12093         attribute.
12094         (*sse_sfence, sse2_mfence, sse2_lfence): Override length_address
12095         attribute to 0.
12096         (*avx_phaddwv8hi3, *avx_phadddv4si3, *avx_phaddswv8hi3,
12097         *avx_phsubwv8hi3, *avx_phsubdv4si3, *avx_phsubswv8hi,
12098         *avx_pmaddubsw128, *avx_pmulhrswv8hi3, *avx_pshufbv16qi3,
12099         *avx_psign<mode>3): Set prefix_extra attribute to 1.
12100         (ssse3_phaddwv4hi3, ssse3_phadddv2si3, ssse3_phaddswv4hi3,
12101         ssse3_phsubwv4hi3, ssse3_phsubdv2si3, ssse3_phsubswv4hi3,
12102         ssse3_pmaddubsw, *ssse3_pmulhrswv4hi, ssse3_pshufbv8qi3,
12103         ssse3_psign<mode>3): Override prefix_rex attribute.
12104         (*avx_palignrti): Override prefix_extra and length_immediate to 1.
12105         (ssse3_palignrti): Override length_immediate to 1.
12106         (ssse3_palignrdi): Override length_immediate to 1, override
12107         prefix_rex attribute.
12108         (abs<mode>2): Override prefix_rep to 0, override prefix_rex attribute.
12109         (sse4a_extrqi): Override length_immediate to 2.
12110         (sse4a_insertqi): Likewise.  Override prefix_data16 to 0.
12111         (sse4a_insertq): Override prefix_data16 to 0.
12112         (avx_blendp<avxmodesuffixf2c><avxmodesuffix>,
12113         avx_blendvp<avxmodesuffixf2c><avxmodesuffix>,
12114         avx_dpp<avxmodesuffixf2c><avxmodesuffix>, *avx_mpsadbw,
12115         *avx_pblendvb, *avx_pblendw, avx_roundp<avxmodesuffixf2c>256,
12116         avx_rounds<avxmodesuffixf2c>256): Override prefix_extra
12117         and length_immediate to 1.
12118         (sse4_1_blendp<ssemodesuffixf2c>, sse4_1_dpp<ssemodesuffixf2c>,
12119         sse4_2_pcmpestr, sse4_2_pcmpestri, sse4_2_pcmpestrm,
12120         sse4_2_pcmpestr_cconly, sse4_2_pcmpistr, sse4_2_pcmpistri,
12121         sse4_2_pcmpistrm, sse4_2_pcmpistr_cconly): Override prefix_data16
12122         and length_immediate to 1.
12123         (sse4_1_blendvp<ssemodesuffixf2c>): Override prefix_data16 to 1.
12124         (sse4_1_mpsadbw, sse4_1_pblendw): Override length_immediate to 1.
12125         (*avx_packusdw, avx_vtestp<avxmodesuffixf2c><avxmodesuffix>,
12126         avx_ptest256): Override prefix_extra to 1.
12127         (sse4_1_roundp<ssemodesuffixf2c>, sse4_1_rounds<ssemodesuffixf2c>):
12128         Override prefix_data16 and length_immediate to 1.
12129         (sse5_pperm_zero_v16qi_v8hi, sse5_pperm_sign_v16qi_v8hi,
12130         sse5_pperm_zero_v8hi_v4si, sse5_pperm_sign_v8hi_v4si,
12131         sse5_pperm_zero_v4si_v2di, sse5_pperm_sign_v4si_v2di,
12132         sse5_vrotl<mode>3, sse5_ashl<mode>3, sse5_lshl<mode>3): Override
12133         prefix_data16 to 0 and prefix_extra to 2.
12134         (sse5_rotl<mode>3, sse5_rotr<mode>3): Override length_immediate to 1.
12135         (sse5_frcz<mode>2, sse5_vmfrcz<mode>2): Don't override prefix_extra
12136         attribute.
12137         (*sse5_vmmaskcmp<mode>3, sse5_com_tf<mode>3,
12138         sse5_maskcmp<mode>3, sse5_maskcmp<mode>3, sse5_maskcmp_uns<mode>3):
12139         Override prefix_data16 and prefix_rep to 0, length_immediate to 1
12140         and prefix_extra to 2.
12141         (sse5_maskcmp_uns2<mode>3, sse5_pcom_tf<mode>3): Override
12142         prefix_data16 to 0, length_immediate to 1 and prefix_extra to 2.
12143         (*avx_aesenc, *avx_aesenclast, *avx_aesdec, *avx_aesdeclast,
12144         avx_vpermilvar<mode>3,
12145         avx_vbroadcasts<avxmodesuffixf2c><avxmodesuffix>,
12146         avx_vbroadcastss256, avx_vbroadcastf128_p<avxmodesuffixf2c>256,
12147         avx_maskloadp<avxmodesuffixf2c><avxmodesuffix>,
12148         avx_maskstorep<avxmodesuffixf2c><avxmodesuffix>):
12149         Override prefix_extra to 1.
12150         (aeskeygenassist, pclmulqdq): Override length_immediate to 1.
12151         (*vpclmulqdq, avx_vpermil<mode>, avx_vperm2f128<mode>3,
12152         vec_set_lo_<mode>, vec_set_hi_<mode>, vec_set_lo_v16hi,
12153         vec_set_hi_v16hi, vec_set_lo_v32qi, vec_set_hi_v32qi): Override
12154         prefix_extra and length_immediate to 1.
12155         (*avx_vzeroall, avx_vzeroupper, avx_vzeroupper_rex64): Override
12156         modrm to 0.
12157         (*vec_concat<mode>_avx): Override prefix_extra and length_immediate
12158         to 1 for the first alternative.
12159         * config/i386/mmx.md (*mov<mode>_internal_rex64): Override
12160         prefix_rep, prefix_data16 and/or prefix_rex attributes in certain
12161         cases.
12162         (*mov<mode>_internal_avx, *movv2sf_internal_rex64,
12163         *movv2sf_internal_avx, *movv2sf_internal): Override
12164         prefix_rep attribute for certain alternatives.
12165         (*mov<mode>_internal): Override prefix_rep or prefix_data16
12166         attributes for certain alternatives.
12167         (*movv2sf_internal_rex64_avx): Override prefix_rep and length_vex
12168         attributes for certain alternatives.
12169         (*mmx_addv2sf3, *mmx_subv2sf3, *mmx_mulv2sf3,
12170         *mmx_<code>v2sf3_finite, *mmx_<code>v2sf3, mmx_rcpv2sf2,
12171         mmx_rcpit1v2sf3, mmx_rcpit2v2sf3, mmx_rsqrtv2sf2, mmx_rsqit1v2sf3,
12172         mmx_haddv2sf3, mmx_hsubv2sf3, mmx_addsubv2sf3,
12173         *mmx_eqv2sf3, mmx_gtv2sf3, mmx_gev2sf3, mmx_pf2id, mmx_pf2iw,
12174         mmx_pi2fw, mmx_floatv2si2, mmx_pswapdv2sf2, *mmx_pmulhrwv4hi3,
12175         mmx_pswapdv2si2): Set prefix_extra attribute to 1.
12176         (mmx_ashr<mode>3, mmx_lshr<mode>3, mmx_ashl<mode>3): Set
12177         length_immediate to 1 if operand 2 is const_int_operand.
12178         (*mmx_pinsrw, mmx_pextrw, mmx_pshufw_1, *vec_dupv4hi,
12179         *vec_extractv2si_1): Set length_immediate attribute to 1.
12180         (*mmx_uavgv8qi3): Override prefix_extra attribute to 1 if
12181         using old 3DNOW insn rather than SSE/3DNOW_A.
12182         (mmx_emms, mmx_femms): Clear modrm attribute.
12183
12184 2009-05-29  Martin Jambor  <mjambor@suse.cz>
12185
12186         * tree-sra.c:  New implementation of SRA.
12187
12188         * params.def (PARAM_SRA_MAX_STRUCTURE_SIZE): Removed.
12189         (PARAM_SRA_MAX_STRUCTURE_COUNT): Removed.
12190         (PARAM_SRA_FIELD_STRUCTURE_RATIO): Removed.
12191         * params.h (SRA_MAX_STRUCTURE_SIZE): Removed.
12192         (SRA_MAX_STRUCTURE_COUNT): Removed.
12193         (SRA_FIELD_STRUCTURE_RATIO): Removed.
12194         * doc/invoke.texi (sra-max-structure-size): Removed.
12195         (sra-field-structure-ratio): Removed.
12196
12197 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
12198
12199         PR middle-end/40291
12200         * builtins.c (expand_builtin_memcmp): Convert len to sizetype
12201         before expansion.
12202
12203 2009-05-29  Andrey Belevantsev  <abel@ispras.ru>
12204
12205         PR rtl-optimization/40101
12206         * sel-sched-ir.c (get_seqno_by_preds): Allow returning negative
12207         seqno.  Adjust comment.
12208         * sel-sched.c (find_seqno_for_bookkeeping): Assert that when
12209         inserting bookkeeping before a jump, the jump is not scheduled.
12210         When no positive seqno found, provide a value.  Add comment.
12211
12212 2009-05-29  Richard Guenther  <rguenther@suse.de>
12213
12214         * tree-ssa-alias.c (nonaliasing_component_refs_p): Remove
12215         short-cutting on the first component.
12216
12217 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
12218
12219         PR middle-end/39958
12220         * omp-low.c (scan_omp_1_op): Call remap_type on TREE_TYPE
12221         for trees other than decls/types.
12222
12223 2009-05-29  Richard Guenther  <rguenther@suse.de>
12224
12225         * tree-ssa-operands.c (get_expr_operands): Do not handle
12226         INDIRECT_REFs in the handled-component case.  Remove
12227         unused get_ref_base_and_extent case.
12228         * tree-dfa.c (get_ref_base_and_extent): Avoid calling
12229         tree_low_cst and host_integerp where possible.
12230         * tree-ssa-structalias.c (equiv_class_label_eq): Check hash
12231         codes for equivalence.
12232         * dce.c (find_call_stack_args): Avoid redundant bitmap queries.
12233
12234 2009-05-29  David Billinghurst <billingd@gcc.gnu.org>
12235
12236         * config.gcc: Add i386/t-fprules-softfp and soft-fp/t-softfp
12237         to tmake_file for i[34567]86-*-cygwin*.
12238
12239 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
12240
12241         PR target/40017
12242         * config/rs6000/rs6000-c.c (_Bool_keyword): New variable.
12243         (altivec_categorize_keyword, init_vector_keywords,
12244         rs6000_cpu_cpp_builtins): Define _Bool as conditional macro
12245         similar to bool.
12246
12247 2009-05-29  Kai Tietz  <kai.tietz@onevision.com>
12248
12249         * tree.c (handle_dll_attribute): Check if node is
12250         of kind FUNCTION_DECL for DECL_DECLARED_INLINE_P check.
12251
12252 2009-05-29  Richard Earnshaw  <rearnsha@arm.com>
12253
12254         * config/arm/thumb2.md (thumb2_zero_extendsidi2): Add a split
12255         component.
12256         (thumb2_zero_extendqidi2): Likewise.
12257
12258 2009-05-28  Kaz Kojima  <kkojima@gcc.gnu.org>
12259
12260         * config/sh/sh.c (sh_expand_t_scc): Use gen_xorsi3_movrt
12261         instead of gen_movrt.
12262         * config/sh/sh.md (movrt): Remove.
12263
12264 2009-05-28  Steve Ellcey  <sje@cup.hp.com>
12265
12266         * doc/invoke.texi (IA-64 Options):
12267         Add -msdata, -mfused-madd, -mno-inline-float-divide,
12268         -mno-inline-int-divide, -mno-inline-sqrt, -msched-spec-ldc,
12269         -msched-spec-control-ldc, -msched-prefer-non-data-spec-insns,
12270         -msched-prefer-non-control-spec-insns,
12271         -msched-stop-bits-after-every-cycle,
12272         -msched-count-spec-in-critical-path,
12273         -msel-sched-dont-check-control-spec, -msched-fp-mem-deps-zero-cost
12274         -msched-max-memory-insns-hard-limit, -msched-max-memory-insns.
12275         Remove -mt, -pthread, -msched-ldc, -mno-sched-control-ldc,
12276         and -msched-spec-verbose.
12277
12278 2009-05-28  Joseph Myers  <joseph@codesourcery.com>
12279
12280         * config/arm/lib1funcs.asm (__clear_cache): Define if L_clear_cache.
12281         * config/arm/linux-eabi.h (CLEAR_INSN_CACHE): Define to give an
12282         error if used.
12283         * config/arm/t-linux-eabi (LIB1ASMFUNCS): Add _clear_cache.
12284
12285 2009-05-28  Richard Guenther  <rguenther@suse.de>
12286
12287         * tree-ssa-alias.c (ao_ref_init): New function.
12288         (ao_ref_base): Likewise.
12289         (ao_ref_base_alias_set): Likewise.
12290         (ao_ref_alias_set): Likewise.
12291         (refs_may_alias_p_1): Change signature.
12292         (refs_may_alias_p): Adjust.
12293         (refs_anti_dependent_p): Likewise.
12294         (refs_output_dependent_p): Likewise.
12295         (call_may_clobber_ref_p_1): Change signature.
12296         (call_may_clobber_ref_p): Adjust.
12297         (stmt_may_clobber_ref_p_1): New function split out from ...
12298         (stmt_may_clobber_ref_p): ... here.
12299         (maybe_skip_until): Adjust signature.
12300         (get_continuation_for_phi): Likewise.
12301         (walk_non_aliased_vuses): Likewise.
12302         * tree-ssa-alias.h (struct ao_ref_s): New structure type.
12303         (ao_ref_init): Declare.
12304         (ao_ref_base): Likewise.
12305         (ao_ref_alias_set): Likewise.
12306         (stmt_may_clobber_ref_p_1): Likewise.
12307         (walk_non_aliased_vuses): Adjust.
12308         * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): New function.
12309         (get_ref_from_reference_ops): remove.
12310         (vn_reference_lookup_2): Adjust signature.
12311         (vn_reference_lookup_3): Do not re-build trees.  Handle unions.
12312         (vn_reference_lookup_pieces): Adjust signature, do not re-build trees.
12313         (vn_reference_lookup): Adjust.
12314         (vn_reference_insert): Likewise.
12315         (vn_reference_insert_pieces): Adjust signature.
12316         (visit_reference_op_call): Adjust.
12317         * tree-ssa-pre.c (get_expr_type): Simplify.
12318         (phi_translate_1): Adjust.
12319         (compute_avail): Likewise.
12320         (translate_vuse_through_block): Do not re-build trees.
12321         (value_dies_in_block_x): Likewise.
12322         * tree-ssa-sccvn.h (struct vn_reference_s): Add type and alias-set
12323         fields.
12324         (vn_reference_lookup_pieces): Adjust declaration.
12325         (vn_reference_insert_pieces): Likewise.
12326
12327 2009-05-28  Benjamin Kosnik  <bkoz@redhat.com>
12328
12329         * tree-ssa-copy.c (replace_exp_1): Move op for warning-free use
12330         with checking disabled.
12331
12332 2009-05-28  Dave Korn  <dave.korn.cygwin@gmail.com>
12333
12334         PR target/37216
12335
12336         * configure.ac (HAVE_GAS_ALIGNED_COMM):  Add autoconf test and
12337         macro definition for support of three-operand format aligned
12338         .comm directive in assembler on cygwin/pe/mingw target OS.
12339         * configure:  Regenerate.
12340         * config.h:  Regenerate.
12341
12342         * config/i386/winnt.c (i386_pe_asm_output_aligned_decl_common):  Use
12343         aligned form of .comm directive if -mpe-aligned-commons is in effect.
12344         * config/i386/cygming.opt (-mpe-aligned-commons):  Add new option.
12345
12346         * doc/invoke.texi (-mpe-aligned-commons):  Document new target option.
12347         * doc/tm.texi (ASM_OUTPUT_COMMON):  Document zero size commons.
12348
12349 2009-05-28  Ira Rosen  <irar@il.ibm.com>
12350
12351         PR tree-optimization/40254
12352         * tree-data-ref.c (dr_analyze_innermost): Take POFFSET into account
12353         in analysis of basic blocks.
12354
12355 2009-05-28  Adam Nemet  <anemet@caviumnetworks.com>
12356
12357         PR middle-end/33699
12358         * target.h (struct gcc_target): Fix indentation.  Add const_anchor.
12359         * target-def.h (TARGET_CONST_ANCHOR): New macro.
12360         (TARGET_INITIALIZER): Use it.
12361         * cse.c (CHEAPER): Move it up to the other macros.
12362         (insert): Rename this ...
12363         (insert_with_costs): ... to this.  Add cost parameters.  Update
12364         function comment.
12365         (insert): New function.  Call insert_with_costs.
12366         (compute_const_anchors, insert_const_anchor, insert_const_anchors,
12367         find_reg_offset_for_const, try_const_anchors): New functions.
12368         (cse_insn): Call try_const_anchors.  Adjust cost of src_related
12369         when using a const-anchor.  Call insert_const_anchors.
12370         * config/mips/mips.c (mips_set_mips16_mode): Set targetm.const_anchor.
12371         * doc/tm.texi (Misc): Document TARGET_CONST_ANCHOR.
12372
12373 2009-05-28  Alexandre Oliva  <aoliva@redhat.com>
12374
12375         * tree-inline.c (remap_decls): Enable nonlocalized variables
12376         when not optimizing.
12377
12378 2009-05-28  Alexandre Oliva  <aoliva@redhat.com>
12379
12380         * tree-ssa-live.c (remove_unused_locals): Skip when not optimizing.
12381         Simplify other tests involving optimize.
12382
12383 2009-05-27  Tom Tromey  <tromey@redhat.com>
12384
12385         * unwind-dw2.c (_Unwind_DebugHook): New function.
12386         (uw_install_context): Call _Unwind_DebugHook.
12387
12388 2009-05-27  Tom Tromey  <tromey@redhat.com>
12389
12390         * system.h (CONST_CAST2): Use C++ const_cast when compiled as C++
12391
12392 2009-05-27  Ian Lance Taylor  <iant@google.com>
12393
12394         * Makefile.in (LINKER, LINKER_FLAGS): Define.
12395         (LINKER_FOR_BUILD, BUILD_LINKERFLAGS): Define.
12396         (ALL_LINKERFLAGS): Define.
12397         (xgcc$(exeext)): Change $(COMPILER) to $(LINKER).
12398         (cpp$(exeext), cc1-dummy$(exeext), cc1$(exeext)): Likewise.
12399         (collect2$(exeext), mips-tfile, mips-tdump): Likewise.
12400         (gcov$(exeext), gcov-dump$(exeext)): Likewise.
12401         (build/gen%$(build_exeext)): Change $(COMPILER_FOR_BUILD) to
12402         $(LINKER_FOR_BUILD).
12403         (build/gcov-iov$(build_exeext)): Likewise.
12404
12405 2009-05-27  Julian Brown  <julian@codesourcery.com>
12406
12407         * gcse.c (target.h): Include.
12408         (can_assign_to_reg_without_clobbers_p): Check that the target allows
12409         copy of argument to a pseudo register.
12410
12411 2009-05-27  Diego Novillo  <dnovillo@google.com>
12412
12413         * tree-ssa-live.c (dump_scope_block): Document arguments.
12414         (dump_scope_blocks): Document.
12415         (debug_scope_blocks): New.
12416         * tree-flow.h (debug_scope_blocks): Declare.
12417
12418 2009-05-21  Denis Chertykov  <denisc@overta.ru>
12419
12420         * doc/contrib.texi (Contributors): Add myself to the list.
12421
12422 2009-05-27  Olivier Hainque  <hainque@adacore.com>
12423
12424         * expr.c (target_align): New function.  Alignment the TARGET of an
12425         assignment may be assume to have.
12426         (highest_pow2_factor_for_target): Use it instead of relying on
12427         immediate tree attributes of TARGET, not necessarily honored when
12428         intermediate bitfields are involved.
12429
12430 2009-05-27  H.J. Lu  <hongjiu.lu@intel.com>
12431
12432         PR target/40266
12433         * config/i386/driver-i386.c (host_detect_local_cpu): Support
12434         AVX, SSE4, AES, PCLMUL and POPCNT.
12435
12436 2009-05-27  Diego Novillo  <dnovillo@google.com>
12437
12438         * tree-pretty-print.c (dump_location): New.
12439         (dump_generic_node): Call it.
12440         Factor code to handle BLOCK nodes ...
12441         (dump_block_node): ... here.
12442
12443 2009-05-27  Rafael Avila de Espindola  <espindola@google.com>
12444
12445         * Makefile.in (GCC_PLUGIN_H): New. Replace all uses of gcc-plugin.h
12446         with it.
12447         * doc/plugins.texi: Document that gcc-plugin.h must be the first to be
12448         included.
12449         * gcc-plugin.h: Include config.h and system.h.
12450         (IN_GCC): Define if not defined.
12451
12452 2009-05-27  Hans-Peter Nilsson  <hp@axis.com>
12453
12454         PR middle-end/40249
12455         * Makefile.in (CRTSTUFF_CFLAGS): Replace -fno-inline-functions
12456         with -fno-inline.
12457
12458 2009-05-27  Shujing Zhao  <pearly.zhao@oracle.com>
12459
12460         * config/m32r/m32r.c: Use REG_P, MEM_P and CONST_INT_P where
12461         applicable.
12462         * config/m32r/m32r.h: Ditto.
12463         * config/m32r/m32r.md: Ditto.
12464         * config/m32r/predicates.md: Ditto.
12465
12466 2009-05-27  Alexandre Oliva  <aoliva@redhat.com>
12467
12468         * cgraph.c (dump_cgraph_node): Honor -fdump-noaddr.
12469
12470 2009-05-26  Basile Starynkevitch  <basile@starynkevitch.net>
12471
12472         * doc/plugins.texi
12473         (Loading plugins): typo.
12474         (Plugin callbacks): Documented PLUGIN_INFO, PLUGIN_GGC_START,
12475         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS.
12476         (Interacting with the GCC Garbage Collector): Added new section.
12477         (Giving information about a plugin): Added new section for
12478         PLUGIN_INFO.
12479         * ggc.h (ggc_register_root_tab): Added declaration.
12480         * gcc-plugin.h (PLUGIN_GGC_START, PLUGIN_GGC_MARKING)
12481         (PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS): Added new events.
12482         (register_callback): Improved comment in declaration.
12483         * ggc-common.c (const_ggc_root_tab_t) Added new typedef for vectors.
12484         (extra_root_vec) Added static variable for dynamic roots registration.
12485         (ggc_register_root_tab) Added new routine.
12486         (ggc_mark_roots) Added iteration inside extra_root_vec, and invoke
12487         PLUGIN_GGC_MARKING event.
12488         * ggc-zone.c: Include plugin.h.
12489         (ggc_collect): Invoke PLUGIN_GGC_START & PLUGIN_GGC_END events.
12490         * ggc-page.c: Include plugin.h.
12491         (ggc_collect): Invoke PLUGIN_GGC_START & PLUGIN_GGC_END events.
12492         * plugin.c (plugin_event_name): added names of PLUGIN_GGC_START,
12493         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS
12494         (register_callback): check lack of callbacks for
12495         pseudo-events. Added handling of PLUGIN_REGISTER_GGC_ROOTS,
12496         PLUGIN_GGC_START, PLUGIN_GGC_MARKING, PLUGIN_GGC_END.
12497         (invoke_plugin_callbacks): Handle PLUGIN_GGC_START,
12498         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS.
12499         * Makefile.in (ggc-common.o, ggc-zone.o, ggc-page.o): Added
12500         dependency on plugin.h.
12501         (plugin.o): Added dependency on ggc.h...
12502
12503 2009-05-26  Richard Guenther  <rguenther@suse.de>
12504
12505         PR middle-end/40248
12506         Revert
12507         * expr.c (expand_expr_real_1): Avoid calling do_store_flag
12508         with mismatched comparison modes.
12509
12510         * expr.c (expand_expr_real_1): Expand the operand of a
12511         VIEW_CONVERT_EXPR in its natural mode.
12512
12513 2009-05-26  Ian Lance Taylor  <iant@google.com>
12514
12515         * Makefile.in (COMPILER, COMPILER_FLAGS): Define.
12516         (COMPILER_FOR_BUILD, BUILD_COMPILERFLAGS): Define.
12517         (ALL_COMPILERFLAGS): Define.
12518         (.c.o, xgcc$(exeext), cpp$(exeext)): Use $(COMPILER).
12519         (cc1-dummy$(exeext), cc1$(exeext)): Likewise.
12520         (collect2$(exeext), collect2.o): Likewise.
12521         (c-opts.o, c-cppbuiltin.o, c-pch.o, gcc.o, gccspec.o): Likewise.
12522         (gcc-options.o, version.o, prefix.o, toplev.o): Likewise.
12523         ($(out_object_file), mips-tfile, mips-tdump): Likewise.
12524         (libbackend.o, intl.o, cppdefault.o): Likewise.
12525         (gcov$(exeext), gcov-dump$(exeext)): Likewise.
12526         (build/%.o): Use $(COMPILER_FOR_BUILD).
12527         (build/gen%$(build_exeext)): Likewise.
12528         (build/gcov-iov$(build_exeext)): LIkewise.
12529         * config/t-darwin (darwin.o): Use $(COMPILER).
12530         (darwin-c.o, darwin-f.o, darwin-driver.o): Likewise.
12531         * config/t-sol2 (sol2-c.o): Likewise.
12532         (sol2.o): Likewise.
12533         * config/t-vxworks (vxworks.o): Likewise.
12534         * config/x-darwin (host-darwin.o): Likewise.
12535         * config/x-hpux (host-hpux.o): Likewise.
12536         * config/x-linux (host-linux.o): Likewise.
12537         * config/x-solaris (host-solaris.o): Likewise.
12538         * config/alpha/x-alpha (driver-alpha.o): Likewise.
12539         * config/arm/t-arm (arm-c.o): Likewise.
12540         * config/arm/t-pe (pe.o): Likewise.
12541         * config/arm/t-wince-pe (pe.o): Likewise.
12542         * config/i386/t-cygming (winnt.o): Likewise.
12543         (winnt-cxx.o, winnt-stubs.o, msformat-c.o): Likewise.
12544         * config/i386/t-cygwin (cygwin1.o): Likewise.
12545         (cygwin2.o): Likewise.
12546         * config/i386/t-i386 (i386-c.o): Likewise.
12547         * config/i386/t-interix (winnt.o): Likewise.
12548         * config/i386/t-netware (netware.o): Likewise.
12549         * config/i386/t-nwld (nwld.o): Likewise.
12550         * config/i386/x-darwin (host-i386-darwin.o): Likewise.
12551         * config/i386/x-i386 (driver-i386.o): Likewise.
12552         * config/i386/x-cygwin (host-cygwin.o): Likewise.
12553         * config/i386/x-mingw32 (host-mingw32.o): Likewise.
12554         * config/ia64/t-ia64 (ia64-c.o): Likewise.
12555         * config/m32c/t-m32c (m32c-pragma.o): Likewise.
12556         * config/mips/x-native (driver-native.o): Likewise.
12557         * config/rs6000/t-rs6000 (rs6000-c.o): Likewise.
12558         * config/rs6000/x-darwin (host-ppc-darwin.o): Likewise.
12559         * config/rs6000/x-darwin64 (host-ppc64-darwin.o): Likewise.
12560         * config/rs6000/x-rs6000 (driver-rs6000.o): Likewise.
12561         * config/score/t-score-elf (score7.o): Likewise.
12562         (score3.o): Likewise.
12563         * config/sh/t-sh (sh-c.o): Likewise.
12564         * config/sh/t-symbian (sh-c.o): Likewise.
12565         (symbian.o): Likewise.
12566         * config/spu/t-spu-elf (spu-c.o): Likewise.
12567         * config/v850/t-v850 (v850-c.o): Likewise.
12568         * config/v850/t-v850e (v850-c.o): Likewise.
12569
12570 2009-05-26  Richard Guenther  <rguenther@suse.de>
12571
12572         PR tree-optimization/40122
12573         * tree-ssa-ccp.c (ccp_fold): Fold vector CONSTRUCTORs to
12574         VECTOR_CSTs if possible.
12575         (fold_gimple_assign): Likewise.
12576
12577 2009-05-26  Richard Guenther  <rguenther@suse.de>
12578
12579         PR middle-end/40252
12580         * fold-const.c (fold_binary): Use the correct types for building
12581         rotates.
12582
12583 2009-05-26  Richard Guenther  <rguenther@suse.de>
12584
12585         * tree-vect-data-refs.c (vect_create_data_ref_ptr): Remove
12586         redundant calls to merge_alias_info.
12587         (bump_vector_ptr): Likewise.
12588         * tree-ssa-copy.c (merge_alias_info): Remove.
12589         (replace_exp_1): Remove call to merge_alias_info.
12590         (propagate_tree_value): Likewise.
12591         (fini_copy_prop): Propagate points-to info.
12592         * tree-flow.h (merge_alias_info): Remove.
12593
12594 2009-05-07  Hariharan Sandanagobalane <hariharan@picochip.com>
12595
12596         * config/picochip/picochip.C (PARAM_INLINE_CALL_COST): Remove.
12597
12598 2009-05-25  Jan Hubicka  <jh@suse.cz>
12599
12600         * cgraph.c (dump_cgraph_node): Dump size/time/benefit.
12601         * cgraph.h (struct inline_summary): New filed self_wize,
12602         size_inlining_benefit, self_time and time_inlining_benefit.
12603         (struct cgraph_global_info): Replace insns by time ans size fields.
12604         * ipa-cp (ipcp_cloning_candidate_p): Base estimate on size
12605         (ipcp_estimate_growth, ipcp_insert_stage): Likewise.
12606         (ipcp_update_callgraph): Do not touch function bodies.
12607         * ipa-inline.c: Include except.h
12608         (MAX_TIME): New constant.
12609         (overall_insns): Remove.
12610         (leaf_node_p): New.
12611         (overall_size, max_benefit): New static variables.
12612         (cgraph_estimate_time_after_inlining): New function.
12613         (cgraph_estimate_size_after_inlining): Rewrite using benefits.
12614         (cgraph_clone_inlined_nodes): Update size.
12615         (cgraph_mark_inline_edge): Update size.
12616         (cgraph_estimate_growth): Use size info.
12617         (cgraph_check_inline_limits): Check size.
12618         (cgraph_default_inline_p): Likewise.
12619         (cgraph_edge_badness): Compute badness based on benefit and size cost.
12620         (cgraph_decide_recursive_inlining): Check size.
12621         (cgraph_decide_inlining_of_small_function): Update size; dump sizes
12622         and times.
12623         (cgraph_decide_inlining): Likewise.
12624         (cgraph_decide_inlining_incrementally): Likewise; honor
12625         PARAM_EARLY_INLINING_INSNS.
12626         (likely_eliminated_by_inlining_p): New predicate.
12627         (estimate_function_body_sizes): New function.
12628         (compute_inline_parameters): Use it.
12629         * except.c (must_not_throw_labels): New function.
12630         * except.h (must_not_throw_labels): Declare.
12631         * tree-inline.c (init_inline_once): Kill inlining_weigths
12632         * tree-ssa-structalias.c: Avoid uninitialized warning.
12633         * params.def (PARAM_MAX_INLINE_INSNS_SINGLE): Reduce to 300.
12634         (PARAM_MAX_INLINE_INSNS_AUTO): Reduce to 60.
12635         (PARAM_INLINE_CALL_COST): Remove.
12636         (PARAM_EARLY_INLINING_INSNS): New.
12637
12638 2009-05-25  Richard Guenther  <rguenther@suse.de>
12639
12640         PR tree-optimization/36327
12641         * tree-ssa-alias.c (walk_non_aliased_vuses): Add second walker
12642         callback for reference translation or lookup at the point of may-defs.
12643         * tree-ssa-alias.h (walk_non_aliased_vuses): Adjust prototype.
12644         * tree-ssa-sccvn.c (get_ref_from_reference_ops): Bail out
12645         for union COMPONENT_REFs.
12646         (vn_reference_lookup_3): New callback.  Lookup from memset
12647         and CONSTRUCTOR assignment, translate through struct copies.
12648         (vn_reference_lookup_pieces): Make sure to not free the
12649         passed operands array.  Adjust walk_non_aliased_vuses call.
12650         (vn_reference_lookup): Adjust walk_non_aliased_vuses call,
12651         make sure we do not leak memory.
12652
12653 2009-05-25  Richard Guenther  <rguenther@suse.de>
12654
12655         * tree-ssa-alias.h (dump_points_to_solution): Declare.
12656         * tree-inline.c (expand_call_inline): Reset the escaped and
12657         callused solutions.
12658         * tree-ssa-structalias.c (pass_build_ealias): New.
12659         * tree-pass.h (pass_build_ealias): Declare.
12660         * passes.c (init_optimization_passes): Add PTA during
12661         early optimizations.
12662         * tree-ssa-alias.c (dump_alias_info): Dump the ESCAPED
12663         and CALLUSED solutions.
12664         (dump_points_to_solution): New function, split out from ...
12665         (dump_points_to_info_for): ... here.
12666         * tree-parloops.c (parallelize_loops): Reset the escaped and
12667         callused solutions.
12668
12669 2009-05-25  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
12670
12671         PR bootstrap/40027
12672         * config/i386/i386.c (USE_HIDDEN_LINKONCE): Only define if missing.
12673         * config/i386/sol2.h [!TARGET_GNU_LD] (USE_HIDDEN_LINKONCE): Define.
12674
12675 2009-05-25  Ira Rosen  <irar@il.ibm.com>
12676
12677         PR tree-optimization/40238
12678         * tree-vect-stmts.c (vect_init_vector): Insert initialization
12679         statements after basic block's labels.
12680         * tree-vect-slp.c (vect_slp_transform_bb): Call destroy_bb_vec_info()
12681         to free the allocated memory.
12682
12683 2009-05-24  Kaz Kojima  <kkojima@gcc.gnu.org>
12684
12685         * gcc/config/sh/sh.c (sh_set_return_address): Mark store of
12686         return address with a USE.
12687
12688 2009-05-24  Richard Guenther  <rguenther@suse.de>
12689
12690         PR middle-end/40233
12691         * tree.c (make_vector_type): Build the TYPE_DEBUG_REPRESENTATION_TYPEs
12692         array type from the main variant of the inner type.
12693
12694 2009-05-24  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
12695
12696         * config/vax/vax-protos.h (legitimate_constant_address_p): Change
12697         definition to bool (from int) to un-break build.
12698         (legitimate_constant_p, vax_mode_dependent_address_p): Likewise.
12699
12700 2009-05-24  Paolo Bonzini  <bonzini@gnu.org>
12701
12702         * tree-ssa-operands.h (push_stmt_changes, pop_stmt_changes,
12703         discard_stmt_changes): Delete.
12704         * tree-ssa-operands.c (scb_stack): Delete.
12705         (init_ssa_operands): Do not initialize it.
12706         (fini_ssa_operands): Do not free it.
12707         (push_stmt_changes, pop_stmt_changes, discard_stmt_changes): Delete.
12708
12709         * tree-cfg.c (replace_uses_by): Replace pop_stmt_changes with
12710         update_stmt, remove the others.  Fix comments.
12711         * tree-dfa.c (optimize_stack_restore): Likewise.
12712         * tree-ssa-forwprop.c (forward_propagate_addr_expr): Likewise.
12713         * tree-ssa-loop-ivopts.c (rewrite_use): Likewise.
12714         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Likewise.
12715         * tree-ssa-ccp.c (optimize_stack_restore, execute_fold_all_builtins):
12716         Likewise.
12717         * tree-ssa-propagate.c (substitute_and_fold): Likewise.
12718         * tree-ssa-dom.c (propagate_rhs_into_lhs): Likewise.
12719         (dom_opt_finalize_block): Likewise, adjusting access to
12720         stmts_to_rescan.
12721         (optimize_stmt): Likewise, adjusting access to stmts_to_rescan.
12722         (stmts_to_rescan): Change item type to gimple.
12723         (tree_ssa_dominator_optimize): Change type of stmts_to_rescan.
12724
12725 2009-05-24  Ira Rosen  <irar@il.ibm.com>
12726
12727         * doc/passes.texi (Tree-SSA passes): Document SLP pass.
12728         * tree-pass.h (pass_slp_vectorize): New pass.
12729         * params.h (SLP_MAX_INSNS_IN_BB): Define.
12730         * timevar.def (TV_TREE_SLP_VECTORIZATION): Define.
12731         * tree-vectorizer.c (timevar.h): Include.
12732         (user_vect_verbosity_level): Declare.
12733         (vect_location): Fix comment.
12734         (vect_set_verbosity_level): Update user_vect_verbosity_level
12735         instead of vect_verbosity_level.
12736         (vect_set_dump_settings): Add an argument. Ignore user defined
12737         verbosity if dump flags require higher level of verbosity. Print to
12738         stderr only for loop vectorization.
12739         (vectorize_loops): Update call to vect_set_dump_settings.
12740         (execute_vect_slp): New function.
12741         (gate_vect_slp): Likewise.
12742         (struct gimple_opt_pass pass_slp_vectorize): New.
12743         * tree-vectorizer.h (struct _bb_vec_info): Define along macros to
12744         access its members.
12745         (vec_info_for_bb): New function.
12746         (struct _stmt_vec_info): Add bb_vinfo and a macro for its access.
12747         (VECTORIZATION_ENABLED): New macro.
12748         (SLP_ENABLED, SLP_DISABLED): Likewise.
12749         (vect_is_simple_use): Add bb_vec_info argument.
12750         (new_stmt_vec_info, vect_analyze_data_ref_dependences,
12751         vect_analyze_data_refs_alignment, vect_verify_datarefs_alignment,
12752         vect_analyze_data_ref_accesses, vect_analyze_data_refs,
12753         vect_schedule_slp, vect_analyze_slp): Likewise.
12754         (vect_analyze_stmt): Add slp_tree argument.
12755         (find_bb_location): Declare.
12756         (vect_slp_analyze_bb, vect_slp_transform_bb): Likewise.
12757         * tree-vect-loop.c (new_loop_vec_info): Adjust function calls.
12758         (vect_analyze_loop_operations, vect_analyze_loop,
12759         get_initial_def_for_induction, vect_create_epilog_for_reduction,
12760         vect_finalize_reduction, vectorizable_reduction,
12761         vectorizable_live_operation, vect_transform_loop): Likewise.
12762         * tree-data-ref.c (dr_analyze_innermost): Update comment,
12763         skip evolution analysis if analyzing a basic block.
12764         (dr_analyze_indices): Likewise.
12765         (initialize_data_dependence_relation): Skip the test whether the
12766         object is invariant for basic blocks.
12767         (compute_all_dependences): Skip dependence analysis for data
12768         references in basic blocks.
12769         (find_data_references_in_stmt): Don't fail in case of invariant
12770         access in basic block.
12771         (find_data_references_in_bb): New function.
12772         (find_data_references_in_loop): Move code to
12773         find_data_references_in_bb and add a call to it.
12774         (compute_data_dependences_for_bb): New function.
12775         * tree-data-ref.h (compute_data_dependences_for_bb): Declare.
12776         * tree-vect-data-refs.c (vect_check_interleaving): Adjust to the case
12777         that STEP is 0.
12778         (vect_analyze_data_ref_dependence): Check for interleaving in case of
12779         unknown dependence in basic block and fail in case of dependence in
12780         basic block.
12781         (vect_analyze_data_ref_dependences): Add bb_vinfo argument, get data
12782         dependence instances from either loop or basic block vectorization
12783         info.
12784         (vect_compute_data_ref_alignment): Check if it is loop vectorization
12785         before calling nested_in_vect_loop_p.
12786         (vect_compute_data_refs_alignment): Add bb_vinfo argument, get data
12787         dependence instances from either loop or basic block vectorization
12788         info.
12789         (vect_verify_datarefs_alignment): Likewise.
12790         (vect_enhance_data_refs_alignment): Adjust function calls.
12791         (vect_analyze_data_refs_alignment): Likewise.
12792         (vect_analyze_group_access): Fix printing. Skip different checks if
12793         DR_STEP is 0. Keep strided stores either in loop or basic block
12794         vectorization data structure. Fix indentation.
12795         (vect_analyze_data_ref_access): Fix comments, allow zero step in
12796         basic blocks.
12797         (vect_analyze_data_ref_accesses): Add bb_vinfo argument, get data
12798         dependence instances from either loop or basic block vectorization
12799         info.
12800         (vect_analyze_data_refs): Update comment. Call
12801         compute_data_dependences_for_bb to analyze basic blocks.
12802         (vect_create_addr_base_for_vector_ref): Check for outer loop only in
12803         case of loop vectorization. In case of basic block vectorization use
12804         data-ref itself as a base.
12805         (vect_create_data_ref_ptr): In case of basic block vectorization:
12806         don't advance the pointer, add new statements before the current
12807         statement.  Adjust function calls.
12808         (vect_supportable_dr_alignment): Support only aligned accesses in
12809         basic block vectorization.
12810         * common.opt (ftree-slp-vectorize): New flag.
12811         * tree-vect-patterns.c (widened_name_p): Adjust function calls.
12812         (vect_pattern_recog_1): Likewise.
12813         * tree-vect-stmts.c (process_use): Likewise.
12814         (vect_init_vector): Add new statements in the beginning of the basic
12815         block in case of basic block SLP.
12816         (vect_get_vec_def_for_operand): Adjust function calls.
12817         (vect_finish_stmt_generation): Likewise.
12818         (vectorizable_call): Add assert that it is loop vectorization, adjust
12819         function calls.
12820         (vectorizable_conversion, vectorizable_assignment): Likewise.
12821         (vectorizable_operation): In case of basic block SLP, take
12822         vectorization factor from statement's type and skip the relevance
12823         check. Adjust function calls.
12824         (vectorizable_type_demotion): Add assert that it is loop
12825         vectorization, adjust function calls.
12826         (vectorizable_type_promotion): Likewise.
12827         (vectorizable_store): Check for outer loop only in case of loop
12828         vectorization. Adjust function calls. For basic blocks, skip the
12829         relevance check and don't advance pointers.
12830         (vectorizable_load): Likewise.
12831         (vectorizable_condition): Add assert that it is loop vectorization,
12832         adjust function calls.
12833         (vect_analyze_stmt): Add argument. In case of basic block SLP, check
12834         that it is not reduction, get vector type, call only supported
12835         functions, skip loop specific parts.
12836         (vect_transform_stmt): Check for outer loop only in case of loop
12837         vectorization.
12838         (new_stmt_vec_info): Add new argument and initialize bb_vinfo.
12839         (vect_is_simple_use): Fix comment, add new argument, fix conditions
12840         for external definition.
12841         * passes.c (pass_slp_vectorize): New pass.
12842         * tree-vect-slp.c (find_bb_location): New function.
12843         (vect_get_and_check_slp_defs): Add argument, adjust function calls,
12844         check for patterns only in loops.
12845         (vect_build_slp_tree): Add argument, adjust function calls, fail in
12846         case of multiple types in basic block SLP.
12847         (vect_mark_slp_stmts_relevant): New function.
12848         (vect_supported_load_permutation_p): Fix comment.
12849         (vect_analyze_slp_instance): Add argument. In case of basic block
12850         SLP, take vectorization factor from statement's type, check that
12851         unrolling factor is 1. Adjust function call. Save SLP instance in
12852         either loop or basic block vectorization structure. Return FALSE,
12853         if SLP failed.
12854         (vect_analyze_slp): Add argument. Get strided stores groups from
12855         either loop or basic block vectorization structure. Return FALSE
12856         if basic block SLP failed.
12857         (new_bb_vec_info): New function.
12858         (destroy_bb_vec_info, vect_slp_analyze_node_operations,
12859         vect_slp_analyze_operations, vect_slp_analyze_bb): Likewise.
12860         (vect_schedule_slp): Add argument. Get SLP instances from either
12861         loop or basic block vectorization structure. Set vectorization factor
12862         to be 1 for basic block SLP.
12863         (vect_slp_transform_bb): New function.
12864         * params.def (PARAM_SLP_MAX_INSNS_IN_BB): Define.
12865
12866 2009-05-23  Mark Mitchell  <mark@codesourcery.com>
12867
12868         * final.c (shorten_branches): Do not align labels for jump tables.
12869         (final_scan_insn): Use JUMP_TABLE_DATA_P.
12870
12871 2009-05-23  Eric Botcazou  <ebotcazou@adacore.com>
12872
12873         * doc/passes.texi: Standardize spelling of RTL, Tree and Tree SSA.
12874         Remove outdated reference to flow.c and fix nits.
12875         * doc/gccint.texi: Tweak RTL description.
12876         * doc/rtl.texi: Likewise.
12877
12878 2009-05-23  Denis Chertykov  <chertykov@gmail.com>
12879
12880         * config/avr/avr.c: Change my email address.
12881         * config/avr/avr.h: Likewise.
12882         * config/avr/avr.md: Likewise.
12883         * config/avr/avr-protos.h: Likewise.
12884         * config/avr/libgcc.S: Likewise.
12885
12886 2009-05-22  Trevor Smigiel <Trevor_Smigiel@playstation.sony.com>
12887
12888         * config/spu/spu-protos.h (aligned_mem_p, spu_valid_mov): Remove.
12889         (spu_split_load, spu_split_store): Change return type to int.
12890         (spu_split_convert): Declare.
12891         * config/spu/predicates.md (spu_mem_operand): Remove.
12892         (spu_mov_operand): Update.
12893         (spu_dest_operand, shiftrt_operator, extend_operator): Define.
12894         * config/spu/spu.c (regno_aligned_for_load): Remove.
12895         (reg_aligned_for_addr, spu_expand_load): Define.
12896         (spu_expand_extv): Reimplement and handle MEM.
12897         (spu_expand_insv): Handle MEM.
12898         (spu_sched_reorder): Handle insn's with length 0.
12899         (spu_legitimate_address_p): Reimplement.
12900         (store_with_one_insn_p): Return TRUE for any mode with size
12901         larger than 16 bytes.
12902         (address_needs_split): Define.
12903         (spu_expand_mov): Call spu_split_load and spu_split_store for MEM
12904         operands.
12905         (spu_convert_move): Define.
12906         (spu_split_load): Use spu_expand_load and change all MEM's to TImode.
12907         (spu_split_store): Change all MEM's to TImode.
12908         (spu_init_expanders): Preallocate registers that correspond to
12909         LAST_VIRTUAL_REG+1 and LAST_VIRTUAL_REG+2 and set them with
12910         mark_reg_pointer.
12911         (spu_split_convert): Define.
12912         * config/spu/spu.md (QHSI, QHSDI): New mode iterators.
12913         (_move<mode>, _movdi, _movti): Update predicate and condition.
12914         (load, store): Change to define_split.
12915         (extendqiti2, extendhiti2, extendsiti2, extendditi2): Simplify to
12916         extend<mode>ti2.
12917         (zero_extendqiti2, zero_extendhiti2, <v>lshr<mode>3_imm): Define.
12918         (lshr<mode>3, lshr<mode>3_imm, lshr<mode>3_re): Simplify to one
12919         define_insn_and_split of lshr<mode>3.
12920         (shrqbybi_<mode>, shrqby_<mode>): Simplify to define_expand.
12921         (<v>ashr<mode>3_imm): Define.
12922         (extv, extzv, insv): Allow MEM operands.
12923         (trunc_shr_ti<mode>, trunc_shr_tidi, shl_ext_<mode>ti,
12924         shl_ext_diti, sext_trunc_lshr_tiqisi, zext_trunc_lshr_tiqisi,
12925         sext_trunc_lshr_tihisi, zext_trunc_lshr_tihisi): Define for combine.
12926         (_spu_convert2): Change to define_insn_and_split and remove the
12927         corresponding define_peephole2.
12928         (stack_protect_set, stack_protect_test, stack_protect_test_si):
12929         Change predicates to memory_operand.
12930
12931 2009-05-22  Mark Mitchell  <mark@codesourcery.com>
12932
12933         * config/arm/thumb2.md: Add 16-bit multiply instructions.
12934
12935 2009-05-21  Michael Meissner  <meissner@linux.vnet.ibm.com>
12936
12937         PR tree-optimization/40219
12938         * tree.c (iterative_hash_expr): Make sure the builtin function is
12939         a normal builtin function and not a front end or back end builtin
12940         before indexing into the built_in_decls array.
12941
12942 2009-05-22  Richard Guenther  <rguenther@suse.de>
12943
12944         PR middle-end/38964
12945         * alias.c (write_dependence_p): Do not use TBAA for answering
12946         anti-dependence or output-dependence.
12947         * tree-ssa-structalias.c (set_uids_in_ptset): Remove TBAA pruning code.
12948         (emit_pointer_definition): Remove.
12949         (emit_alias_warning): Likewise.
12950         (find_what_var_points_to): Remove TBAA pruning code.
12951         (find_what_p_points_to): Likewise.  Do not warn about strict-aliasing
12952         violations.
12953         (compute_points_to_sets): Remove code computing the set of
12954         dereferenced pointers.
12955         * tree-data-ref.c (dr_may_alias_p): Properly use the split
12956         oracle for querying anti and output dependencies.
12957         * tree-ssa-alias.c (refs_may_alias_p_1): Add argument specifying
12958         if TBAA may be applied.
12959         (refs_anti_dependent_p): New function.
12960         (refs_output_dependent_p): Likewise.
12961         * tree-ssa-alias.h (refs_anti_dependent_p): Declare.
12962         (refs_output_dependent_p): Likewise.
12963         * doc/tree-ssa.texi (Memory model): New section.
12964         * doc/c-tree.texi (CHANGE_DYNAMIC_TYPE_EXPR): Remove.
12965         * doc/gimple.texi (GIMPLE_CHANGE_DYNAMIC_TYPE): Remove.
12966         * cfgexpand.c (expand_gimple_basic_block): Do not handle
12967         GIMPLE_CHANGE_DYNAMIC_TYPE or CHANGE_DYNAMIC_TYPE_EXPR.
12968         * expr.c (expand_expr_real_1): Likewise.
12969         * gimple-low.c (lower_stmt): Likewise.
12970         * gimple-pretty-print.c (dump_gimple_stmt): Likewise.
12971         (dump_gimple_cdt): Remove.
12972         * gimple.c (gss_for_code): Do not handle GIMPLE_CHANGE_DYNAMIC_TYPE.
12973         (gimple_size): Likewise.
12974         (walk_gimple_op): Likewise.
12975         (is_gimple_stmt): Likewise.
12976         (walk_stmt_load_store_addr_ops): Likewise.
12977         (gimple_build_cdt): Remove.
12978         * gimple.def (GIMPLE_CHANGE_DYNAMIC_TYPE): Remove.
12979         * gimple.h (gimple_cdt_new_type): Remove.
12980         (gimple_cdt_new_type_ptr): Likewise.
12981         (gimple_cdt_set_new_type): Likewise.
12982         (gimple_cdt_location): Likewise.
12983         (gimple_cdt_location_ptr): Likewise.
12984         (gimple_cdt_set_location): Likewise.
12985         * gimplify.c (gimplify_expr): Do not handle CHANGE_DYNAMIC_TYPE_EXPR.
12986         * tree-cfg.c (remove_useless_stmts_1): Do not handle
12987         GIMPLE_CHANGE_DYNAMIC_TYPE.
12988         (verify_types_in_gimple_stmt): Likewise.
12989         * tree-inline.c (estimate_num_insns): Likewise.
12990         (expand_call_inline): Do not copy DECL_NO_TBAA_P.
12991         (copy_decl_to_var): Likewise.
12992         (copy_result_decl_to_var): Likewise.
12993         * tree-pretty-print.c (dump_generic_node): Do not handle
12994         CHANGE_DYNAMIC_TYPE_EXPR.
12995         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
12996         * tree-ssa-operands.c (get_expr_operands): Likewise.
12997         * tree-ssa-structalias.c (struct variable_info): Remove
12998         no_tbaa_pruning member.
12999         (new_var_info): Do not set it based on DECL_NO_TBAA_P.
13000         (unify_nodes): Do not copy it.
13001         (find_func_aliases): Do not handle GIMPLE_CHANGE_DYNAMIC_TYPE.
13002         (dump_solution_for_var): Do not dump no_tbaa_pruning state.
13003         (set_uids_in_ptset): Do not check it.
13004         (find_what_var_points_to): Likewise.
13005         (compute_tbaa_pruning): Remove.
13006         (compute_points_to_sets): Do not call it.
13007         * tree.c (walk_tree_1): Do not handle CHANGE_DYNAMIC_TYPE_EXPR.
13008         * tree.def (CHANGE_DYNAMIC_TYPE_EXPR): Remove.
13009         * tree.h (CHANGE_DYNAMIC_TYPE_NEW_TYPE): Remove.
13010         (CHANGE_DYNAMIC_TYPE_LOCATION): Likewise.
13011         (DECL_NO_TBAA_P): Likewise.
13012         (struct tree_decl_common): Move no_tbaa_flag to unused flags section.
13013         * omp-low.c (copy_var_decl): Do not copy DECL_NO_TBAA_P.
13014         (expand_omp_atomic_pipeline): Do not set it.
13015         * print-tree.c (print_node): Do not dump it.
13016         * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Remove
13017         redundant check.
13018
13019 2009-05-22 Vladimir Makarov <vmakarov@redhat.com>
13020
13021         PR target/39856
13022         * reg-stack.c (subst_stack_regs_pat): Remove gcc_assert for note
13023         for clobber.
13024
13025 2009-05-22  Mark Mitchell  <mark@codesourcery.com>
13026
13027         * tree.c (handle_dll_attribute): Mark dllexport'd inlines as
13028         non-external.
13029
13030 2009-05-22  Ben Elliston  <bje@au.ibm.com>
13031
13032         * Makefile.in (bversion.h, s-bversion): New targets.
13033         (TOPLEV_H): Add bversion.h.
13034         * toplev.h: Include "bversion.h".
13035         (ATTRIBUTE_GCC_DIAG): When building with checking disabled, use
13036         the __format__ attribute only if compiling with the same version
13037         of GCC as the sources (the "build version").
13038
13039 2009-05-22  Ben Elliston  <bje@au.ibm.com>
13040
13041         * c-format.c (handle_format_attribute): Fix comment typo.
13042
13043 2009-05-21  Steve Ellcey  <sje@cup.hp.com>
13044
13045         PR target/37846
13046         * config/ia64/ia64.opt (mfused-madd): New.
13047         * config/ia64/ia64.h (TARGET_DEFAULT): Set MASK_FUSED_MADD.
13048         * config/ia64/hpux.h (TARGET_DEFAULT): Ditto.
13049         * config/ia64/ia64.md (maddsf4, msubsf4, nmaddsf4,
13050         madddf4, madddf4_trunc, msubdf4, msubdf4_trunc, nmadddf4,
13051         nmadddf4_truncsf, maddxf4, maddxf4_truncsf, maddxf4_truncdf,
13052         msubxf4, msubxf4_truncsf msubxf4_truncdf, nmaddxf4,
13053         nmaddxf4_truncsf, nmaddxf4_truncdf): Check TARGET_FUSED_MADD.
13054         * config/ia64/vect.md (addv2sf3, subv2sf3): Force fpma/fpms
13055         instruction if !TARGET_FUSED_MADD.
13056         (fpma, fpms): Remove colon from name.
13057
13058 2009-05-22  Richard Guenther  <rguenther@suse.de>
13059
13060         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Record
13061         TMR_ORIGINAL.  Always either record TMR_SYMBOL or TMR_BASE.
13062         * tree-ssa-pre.c (create_component_ref_by_pieces_1): Handle
13063         TARGET_MEM_REF.
13064         (create_expression_by_pieces): Only convert if necessary.
13065         * gimplify.c (gimplify_expr): Handle TARGET_MEM_REF.
13066         * tree-ssa-loop-im.c (gen_lsm_tmp_name): Handle INTEGER_CST.
13067
13068 2009-05-21  Adam Nemet  <anemet@caviumnetworks.com>
13069
13070         * config/mips/mips.md (*extzv_trunc<mode>_exts): Turn into a
13071         regular pattern from a template and rename it ...
13072         (*extzv_truncsi_exts): ... to this.
13073
13074 2009-05-21  Richard Guenther  <rguenther@suse.de>
13075
13076         * cgraph.h (struct cgraph_node): Remove inline_decl member.
13077         * ipa-inline.c (cgraph_mark_inline_edge): Do not check it.
13078         (cgraph_default_inline_p): Likewise.
13079         (cgraph_decide_inlining_incrementally): Likewise.
13080
13081 2009-05-21  H.J. Lu  <hongjiu.lu@intel.com>
13082             Uros Bizjak  <ubizjak@gmail.com>
13083
13084         * config/i386/cpuid.h (bit_MOVBE): New.
13085
13086         * config/i386/driver-i386.c (host_detect_local_cpu): Check movbe.
13087
13088         * config/i386/i386.c (OPTION_MASK_ISA_MOVBE_SET): New.
13089         (OPTION_MASK_ISA_MOVBE_UNSET): Likewise.
13090         (ix86_handle_option): Handle OPT_mmovbe.
13091         (ix86_target_string): Add -mmovbe.
13092         (pta_flags): Add PTA_MOVBE.
13093         (processor_alias_table): Add PTA_MOVBE to "atom".
13094         (override_options): Handle PTA_MOVBE.
13095
13096         * config/i386/i386.h (TARGET_MOVBE): New.
13097
13098         * config/i386/i386.md (bswapsi2): Check TARGET_MOVBE.
13099         (*bswapsi_movbe): New.
13100         (*bswapdi_movbe): Likewise.
13101         (bswapdi2): Renamed to ...
13102         (*bswapdi_1): This.
13103         (bswapdi2): New expander.
13104
13105         * config/i386/i386.opt (mmovbe): New.
13106
13107         * doc/invoke.texi: Document -mmovbe.
13108
13109 2009-05-21  Taras Glek  <tglek@mozilla.com>
13110
13111         * plugin.c (try_init_one_plugin): Updated to new plugin_init API.
13112         * gcc-plugin.h (plugin_init): Updated signature.
13113         * gcc-plugin.h (plugin_name_args): Moved to this header.
13114         * doc/plugins.texi (plugin_init): Updated documention to reflect
13115         API change.
13116         * doc/plugins.texi (plugin_name_args): Added to documention.
13117
13118 2009-05-21  Mark Mitchell  <mark@codesourcery.com>
13119
13120         * config/arm/neon.md (*mul<mode>3add<mode>_neon): New pattern.
13121         (*mul<mode>3neg<mode>add<mode>_neon): Likewise.
13122
13123 2009-05-21  Shujing Zhao  <pearly.zhao@oracle.com>
13124
13125         * config/i386/i386.c: Use REG_P, MEM_P, CONST_INT_P, LABEL_P and
13126         JUMP_TABLE_DATA_P predicates where applicable.
13127         * config/i386/predicates.md: Ditto.
13128         * config/i386/sse.md: Ditto.
13129
13130 2009-05-21  Jakub Jelinek  <jakub@redhat.com>
13131
13132         * config/i386/i386.md (adddi_4_rex64, addsi_4, addhi_4): For
13133         operand2 -128 override length_immediate attribute to 1.
13134         * config/i386/predicates.md (constm128_operand): New predicate.
13135
13136         * config/i386/i386.c (memory_address_length): Handle %r12
13137         the same as %rsp and %r13 the same as %rbp.  For %rsp and %rbp
13138         also check REGNO.
13139         (ix86_attr_length_address_default): For MODE_SI lea in 64-bit
13140         mode look through optional ZERO_EXTEND and SUBREG.
13141         * config/i386/i386.md (R12_REG): New define_constant.
13142         (prefix_data16): For sse unit set also for MODE_TI insns.
13143         (prefix_rex): For -m32 always return 0.  For TYPE_IMOVX
13144         insns set if operand 1 is ext_QIreg_operand.
13145         (modrm): For TYPE_IMOV clear only if not MODE_DI.  For
13146         TYPE_{ALU{,1},ICMP,TEST} insn clear if there is non-shortened
13147         immediate.
13148         (*movdi_extzv_1, zero_extendhidi2, zero_extendqidi2): Change
13149         mode from MODE_DI to MODE_SI.
13150         (movdi_1_rex64): Override modrm and length_immediate attributes
13151         only for movabs (TYPE_IMOV, alternative 2).
13152         (zero_extendsidi2_rex64): Clear prefix_0f attribute if TYPE_IMOVX.
13153         (*float<SSEMODEI24:mode><MODEF:mode>2_mixed_interunit,
13154         *float<SSEMODEI24:mode><MODEF:mode>2_mixed_nointerunit,
13155         *float<SSEMODEI24:mode><MODEF:mode>2_sse_interunit,
13156         *float<SSEMODEI24:mode><MODEF:mode>2_sse_nointerunit): Set
13157         prefix_rex attribute if DImode.
13158         (*adddi_1_rex64, *adddi_2_rex64, *adddi_3_rex64, *adddi_5_rex64,
13159         *addsi_1, *addsi_1_zext, *addsi_2, *addsi_2_zext, *addsi_3,
13160         *addsi_3_zext, *addsi_5, *addhi_1_lea, *addhi_1, *addhi_2, *addhi_3,
13161         *addhi_5, *addqi_1_lea, *addqi_1): Override length_immediate
13162         attribute to 1 if TYPE_ALU and operand 2 is const128_operand.
13163         (pro_epilogue_adjust_stack_1, pro_epilogue_adjust_stack_rex64):
13164         Likewise.  For TYPE_IMOV clear length_immediate attribute.
13165         (*ashldi3_1_rex64, *ashldi3_cmp_rex64, *ashldi3_cconly_rex64,
13166         *ashlsi3_1, *ashlsi3_1_zext, *ashlsi3_cmp, **ashlsi3_cconly,
13167         *ashlsi3_cmp_zext, *ashlhi3_1_lea, *ashlhi3_1, *ashlhi3_cmp,
13168         *ashlhi3_cconly, *ashlqi3_1_lea, *ashlqi3_1, *ashlqi3_cmp,
13169         *ashlqi3_cconly): Override length_immediate attribute to 0 if TYPE_ALU
13170         or one operand TYPE_ISHIFT.
13171         (*ashrdi3_1_one_bit_rex64, *ashrdi3_one_bit_cmp_rex64,
13172         *ashrdi3_one_bit_cconly_rex64, *ashrsi3_1_one_bit,
13173         *ashrsi3_1_one_bit_zext, *ashrsi3_one_bit_cmp,
13174         *ashrsi3_one_bit_cconly, *ashrsi3_one_bit_cmp_zext,
13175         *ashrhi3_1_one_bit, *ashrhi3_one_bit_cmp, *ashrhi3_one_bit_cconly,
13176         *ashrqi3_1_one_bit, *ashrqi3_1_one_bit_slp, *ashrqi3_one_bit_cmp,
13177         *ashrqi3_one_bit_cconly, *lshrdi3_1_one_bit_rex64,
13178         *lshrdi3_cmp_one_bit_rex64, *lshrdi3_cconly_one_bit_rex64,
13179         *lshrsi3_1_one_bit, *lshrsi3_1_one_bit_zext, *lshrsi3_one_bit_cmp,
13180         *lshrsi3_one_bit_cconly, *lshrsi3_cmp_one_bit_zext,
13181         *lshrhi3_1_one_bit, *lshrhi3_one_bit_cmp, *lshrhi3_one_bit_cconly,
13182         *lshrqi3_1_one_bit, *lshrqi3_1_one_bit_slp, *lshrqi2_one_bit_cmp,
13183         *lshrqi2_one_bit_cconly, *rotlsi3_1_one_bit_rex64, *rotlsi3_1_one_bit,
13184         *rotlsi3_1_one_bit_zext, *rotlhi3_1_one_bit, *rotlqi3_1_one_bit_slp,
13185         *rotlqi3_1_one_bit, *rotrdi3_1_one_bit_rex64, *rotrsi3_1_one_bit,
13186         *rotrsi3_1_one_bit_zext, *rotrhi3_one_bit, *rotrqi3_1_one_bit,
13187         *rotrqi3_1_one_bit_slp): Override length_immediate attribute to 0,
13188         set mode attribute, don't override length attribute.
13189         (*btsq, *btrq, *btcq, *btdi_rex64, *btsi): Set prefix_0f attribute
13190         to 1.
13191         (return_internal_long): Set length attribute to 2 instead of 1.
13192         (*strmovqi_rex_1, *strsetqi_rex_1, *rep_stosqi_rex64,
13193         *cmpstrnqi_nz_rex_1, *cmpstrnqi_rex_1, *strlenqi_rex_1): Clear
13194         prefix_rex attribute.
13195         * config/i386/predicates.md (ext_QIreg_operand, const128_operand):
13196         New predicates.
13197         (memory_displacement_only_operand): Always return 0 for TARGET_64BIT.
13198
13199 2009-05-21  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
13200
13201         * config/arm/thumb2.md (orsi_notsi_si): Fix typo in pattern.
13202
13203 2009-05-20  Ian Lance Taylor  <iant@google.com>
13204
13205         * tree.c (build_tree_list_vec_stat): New function.
13206         (ctor_to_vec): New function.
13207         (build_nt_call_vec): New function.
13208         (build_call_array): Change args to be a const pointer.
13209         (build_call_vec): New function.
13210         * tree.h (build_nt_call_vec): Declare.
13211         (build_tree_list_vec_stat): Declare.
13212         (build_tree_list_vec): Define.
13213         (build_call_array): Update declaration.
13214         (build_call_vec): Declare.
13215         (ctor_to_vec): Declare.
13216         * c-common.c (tree_vector_cache): New static variable.
13217         (make_tree_vector): New function.
13218         (release_tree_vector): New function.
13219         (make_tree_vector_single): New function.
13220         (make_tree_vector_copy): New function.
13221         * c-common.h (tree_vector_cache, make_tree_vector): Declare.
13222         (make_tree_vector_single, make_tree_vector_copy): Declare.
13223         * c-parser.c (cached_expr_list_1, cached_expr_list_2): Remove.
13224         (c_parser_expr_list): Don't manage cache here, instead call
13225         make_tree_vector.
13226         (c_parser_release_expr_list): Remove static function.
13227         (c_parser_vec_to_tree_list): Remove static function.
13228         (c_parser_attributes): Call build_tree_list_vec instead of
13229         c_parser_vec_to_tree_list.  Call release_tree_vector instead of
13230         c_parser_release_expr_list.
13231         (c_parser_postfix_expression_after_primary): Likewise.
13232         (c_parser_objc_keywordexpr): Likewise.
13233
13234 2009-05-20  Sandra Loosemore  <sandra@codesourcery.com>
13235
13236         * doc/tm.texi (Misc): Document TARGET_INVALID_PARAMETER_TYPE,
13237         TARGET_INVALID_RETURN_TYPE, TARGET_PROMOTED_TYPE, and
13238         TARGET_CONVERT_TO_TYPE.
13239         * hooks.c (hook_tree_const_tree_null): Define.
13240         * hooks.h (hook_tree_const_tree_null): Declare.
13241         * target.h (struct gcc_target):  Add invalid_parameter_type,
13242         invalid_return_type, promoted_type, and convert_to_type fields.
13243         * target-def.h: (TARGET_INVALID_PARAMETER_TYPE): Define.
13244         (TARGET_INVALID_RETURN_TYPE): Define.
13245         (TARGET_PROMOTED_TYPE): Define.
13246         (TARGET_CONVERT_TO_TYPE): Define.
13247         (TARGET_INITIALIZER): Update for new fields.
13248         * c-decl.c (grokdeclarator): Check targetm.invalid_return_type.
13249         (grokparms): Check targetm.invalid_parameter_type.
13250         * c-typeck.c (default_conversion): Check targetm.promoted_type.
13251         * c-convert.c (convert): Check targetm.convert_to_type.
13252
13253 2009-05-20  Adam Nemet  <anemet@caviumnetworks.com>
13254
13255         * config/mips/mips.md (*extenddi_truncate<mode>,
13256         *extendsi_truncate<mode>): Emit exts if supported.  Add attribute
13257         defintions.
13258         (*extendhi_truncateqi): New define_insn_and_sptit.
13259
13260 2009-05-20  Jakub Jelinek  <jakub@redhat.com>
13261
13262         PR middle-end/40204
13263         * fold-const.c (fold_binary) <case BIT_AND_EXPR>: Avoid infinite
13264         recursion if build_int_cst_type returns the same INTEGER_CST as arg1.
13265
13266 2009-05-20  Eric Botcazou  <ebotcazou@adacore.com>
13267
13268         * fold-const.c (build_fold_addr_expr_with_type): Take the address of
13269         the operand of VIEW_CONVERT_EXPR.
13270
13271 2009-05-20  H.J. Lu  <hongjiu.lu@intel.com>
13272
13273         * config/i386/driver-i386.c (host_detect_local_cpu): Check
13274         extended family and model for Intel processors.  Support Intel Atom.
13275
13276 2009-05-20  Olivier Hainque  <hainque@adacore.com>
13277
13278         * gstab.h (stab_code_type): Define, to be used instead of the
13279         __stab_debug_code enum, made anonymous.  Add 2009 to the copyright
13280         notice.
13281         * dbxout.c (STAB_CODE_TYPE): Remove #define and replace use
13282         occurrences by stab_code_type.
13283         * mips-tfile.c (STAB_CODE_TYPE): Remove #define, unused.
13284
13285 2009-05-20  Martin Jambor  <mjambor@suse.cz>
13286
13287         * tree-flow.h (insert_edge_copies_seq): Undeclare.
13288         (sra_insert_before): Likewise.
13289         (sra_insert_after): Likewise.
13290         (sra_init_cache): Likewise.
13291         (sra_type_can_be_decomposed_p): Likewise.
13292         * tree-mudflap.c (insert_edge_copies_seq): Copied here from tree-sra.c
13293         * tree-sra.c (sra_type_can_be_decomposed_p): Made static.
13294         (sra_insert_before): Likewise.
13295         (sra_insert_after): Likewise.
13296         (sra_init_cache): Likewise.
13297         (insert_edge_copies_seq): Made static and moved upwards.
13298
13299         * tree-complex.c (extract_component): Added VIEW_CONVERT_EXPR switch
13300         case.
13301
13302         * tree-flow-inline.h (contains_view_convert_expr_p): New function.
13303
13304         * ipa-prop.c (get_ssa_def_if_simple_copy): New function.
13305         (determine_cst_member_ptr): Call get_ssa_def_if_simple_copy to skip
13306         simple copies.
13307
13308 2009-05-20  Richard Guenther  <rguenther@suse.de>
13309
13310         * expr.c (expand_expr_real_1): Avoid calling do_store_flag
13311         with mismatched comparison modes.
13312
13313 2009-05-20  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
13314
13315         * config/arm/arm.md (*arm_iorsi3): Refactored for only ARM.
13316         (peephole ior (reg, int) -> mov, ior): Refactored for only ARM.
13317         * config/arm/thumb2.md (*thumb_andsi_not_shiftsi_si): Allow bic
13318         with shifts for Thumb2.
13319         (orsi_notsi): New for orn.
13320         (*thumb_orsi_notshiftsi_si): Allow orn with shifts.
13321         (*thumb2_iorsi3): Rewrite support for iorsi for Thumb2.
13322         * config/arm/arm.c (const_ok_for_op): Split case for IOR for Thumb2.
13323         (arm_gen_constant): Set can_invert for IOR and Thumb2, Add comments.
13324         Don't invert remainder for IOR.
13325
13326 2009-05-19  Zdenek Dvorak  <ook@ucw.cz>
13327
13328         PR tree-optimization/40087
13329         * tree-ssa-loop-niter.c (number_of_iterations_ne_max,
13330         number_of_iterations_ne): Rename never_infinite argument.
13331         (number_of_iterations_lt_to_ne, number_of_iterations_lt,
13332         number_of_iterations_le): Handle pointer-type ivs when
13333         exit_must_be_taken is false.
13334         (number_of_iterations_cond):  Do not always assume that
13335         exit_must_be_taken if the control variable is a pointer.
13336
13337 2009-05-19  Andrew Pinski  <andrew_pinski@playstation.sony.com>
13338
13339         * c-typeck.c (build_binary_op): Allow % on integal vectors.
13340         * doc/extend.texi (Vector Extension): Document that % is allowed too.
13341
13342 2009-05-19  H.J. Lu  <hongjiu.lu@intel.com>
13343
13344         * config/i386/i386.c (ix86_avoid_jump_mispredicts): Check
13345         ASM_OUTPUT_MAX_SKIP_PAD instead of ASM_OUTPUT_MAX_SKIP_ALIGN.
13346
13347 2009-05-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
13348
13349         PR c/40172
13350         * c.opt (Wlogical-op): Disabled by default.
13351         * c-opt (c_common_post_options): Do not enable Wlogical-op with
13352         Wextra.
13353         * doc/invoke.texi (Wlogical-op): Likewise.
13354
13355 2009-05-19  Eric Botcazou  <ebotcazou@adacore.com>
13356
13357         * tree-scalar-evolution.c (follow_ssa_edge_expr) <NOP_EXPR>: Turn
13358         into CASE_CONVERT.
13359         <PLUS_EXPR>: Strip useless type conversions instead of type nops.
13360         Propagate the type of the first operand.
13361         <ASSERT_EXPR>: Simplify.
13362         (follow_ssa_edge_in_rhs): Use gimple_expr_type to get the type.
13363         Rewrite using the RHS code as discriminant.
13364         <NOP_EXPR>: Turn into CASE_CONVERT.
13365         <PLUS_EXPR>: Propagate the type of the first operand.
13366
13367 2009-05-19  Steve Ellcey  <sje@cup.hp.com>
13368
13369         * config/ia64/ia64-protos.h (ia64_dconst_0_5): New.
13370         (ia64_dconst_0_375): New.
13371         * config/ia64/ia64.c (ia64_override_options): Remove
13372         -minline-sqrt-min-latency warning.
13373         (ia64_dconst_0_5_rtx, ia64_dconst_0_5): New.
13374         (ia64_dconst_0_375_rtx, ia64_dconst_0_375): New
13375         * config/ia64/ia64.md (*sqrt_approx): Remove.
13376         (sqrtsf2): Remove #if 0.
13377         (sqrtsf2_internal_thr): Rewrite and move to div.md.
13378         (sqrtdf): Remove assert.
13379         (sqrtdf2_internal_thr): Rewrite and move to div.md.
13380         (sqrtxf2): Remove #if 0.
13381         (sqrtxf2_internal_thr): Rewrite and move to div.md.
13382         * div.md (sqrt_approx_rf): New.
13383         (sqrtsf2_internal_thr): New implementation.
13384         (sqrtsf2_internal_lat): New.
13385         (sqrtdf2_internal_thr: New implementation.
13386         (sqrtxf2_internal): New implementation.
13387
13388 2009-05-19  Francois-Xavier Coudert  <fxcoudert@gmail.com>
13389             Hans-Peter Nilsson  <hp@axis.com>
13390
13391         * defaults.h (UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE)
13392         (WCHAR_TYPE, MODIFIED_WCHAR_TYPE, PTRDIFF_TYPE, WINT_TYPE)
13393         (INTMAX_TYPE, UINTMAX_TYPE, SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE)
13394         (INT32_TYPE, INT64_TYPE, UINT8_TYPE, UINT16_TYPE, UINT32_TYPE)
13395         (UINT64_TYPE, INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE)
13396         (INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE)
13397         (UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE)
13398         (INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE)
13399         (UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE)
13400         (SIZE_TYPE, PID_TYPE, CHAR16_TYPE, CHAR32_TYPE): Move defaults here...
13401         * c-common.c: ...from here.
13402
13403 2009-05-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
13404
13405         * c-common.c (warn_logical_operator): Remove unnecessary conditionals.
13406
13407 2009-05-19  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
13408
13409         * builtins.c (do_mpc_arg1): Separate MPFR/MPC C rounding types.
13410
13411 2009-05-19  Ben Elliston  <bje@au.ibm.com>
13412
13413         * unwind-dw2-fde.c (fde_unencoded_compare): Replace type punning
13414         assignments with memcpy calls.
13415         (add_fdes): Likewise.
13416         (binary_search_unencoded_fdes): Likewise.
13417         (linear_search_fdes): Eliminate type puns.
13418
13419 2009-05-19  Richard Guenther  <rguenther@suse.de>
13420
13421         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Do
13422         not falsely claim to have propagated into all uses.
13423
13424 2009-05-19  Ben Elliston  <bje@au.ibm.com>
13425
13426         * doc/invoke.texi (C Dialect Options): Update OpenMP specification
13427         version to v3.0.
13428
13429 2009-05-18  Kaz Kojima  <kkojima@gcc.gnu.org>
13430
13431         * config/sh/sh-protos.h (sh_legitimate_address_p): Remove.
13432         * config/sh/sh.c (sh_legitimate_address_p): Make static.
13433         (TARGET_LEGITIMATE_ADDRESS_P): New.
13434         * config/sh/sh.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
13435         * config/sh/sh.md: Clean up references to GO_IF_LEGITIMATE_ADDRESS.
13436
13437 2009-05-18  Dodji Seketeli  <dodji@redhat.com>
13438
13439         PR debug/40109
13440         * dwarf2out.c (gen_type_die_with_usage): Generate the DIE as a
13441         child of the containing namespace's DIE.
13442
13443 2009-05-18  Adam Nemet  <anemet@caviumnetworks.com>
13444
13445         * config/mips/mips.md (*zero_extend<GPR:mode>_trunc<SHORT:mode>,
13446         *zero_extendhi_truncqi):  Move after the zero_extend patterns.
13447         (*extenddi_truncate<mode>, *extendsi_truncate<mode>): Move after the
13448         extend patterns.
13449
13450 2009-05-18  H.J. Lu  <hongjiu.lu@intel.com>
13451
13452         PR target/39942
13453         * config/i386/i386.c (ix86_avoid_jump_misspredicts): Replace
13454         gen_align with gen_pad.
13455         (ix86_reorg): Check ASM_OUTPUT_MAX_SKIP_PAD instead of
13456         #ifdef ASM_OUTPUT_MAX_SKIP_ALIGN.
13457
13458         * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): New.
13459         * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
13460
13461         * config/i386/i386.md (align): Renamed to ...
13462         (pad): This.  Replace ASM_OUTPUT_MAX_SKIP_ALIGN with
13463         ASM_OUTPUT_MAX_SKIP_PAD.
13464
13465 2009-05-18  Andreas Schwab  <schwab@linux-m68k.org>
13466
13467         * config.gcc: Fix variable syntax.
13468
13469         PR target/39531
13470         * config/m68k/m68k.c (output_andsi3): Mask off sign bit copies
13471         before calling exact_log2.
13472         (output_iorsi3): Likewise.
13473         (output_xorsi3): Likewise.
13474
13475 2009-05-18  Kaz Kojima  <kkojima@gcc.gnu.org>
13476
13477         * config/sh/sh.c (expand_cbranchdi4): Use a scratch register
13478         for the none zero constant operand except for EQ and NE
13479         comprisons even when the first operand is R0.
13480
13481 2009-05-18  Andreas Krebbel  <krebbel1@de.ibm.com>
13482
13483         * config/s390/2064.md: Remove trailing whitespaces.
13484         * config/s390/2084.md: Likewise.
13485         * config/s390/constraints.md: Likewise.
13486         * config/s390/fixdfdi.h: Likewise.
13487         * config/s390/libgcc-glibc.ver: Likewise.
13488         * config/s390/s390-modes.def: Likewise.
13489         * config/s390/s390-protos.h: Likewise.
13490         * config/s390/s390.c: Likewise.
13491         * config/s390/s390.h: Likewise.
13492         * config/s390/s390.md: Likewise.
13493         * config/s390/tpf-unwind.h: Likewise.
13494
13495 2009-05-18  Maxim Kuvyrkov  <maxim@codesourcery.com>
13496
13497         * config/m68k/m68k.c (m68k_legitimize_address): Fix typo in signature.
13498
13499 2009-05-18  Maxim Kuvyrkov  <maxim@codesourcery.com>
13500
13501         M68K TLS support.
13502         * configure.ac (m68k-*-*): Check if binutils support TLS.
13503         * configure: Regenerate.
13504         * config/m68k/predicates.md (symbolic_operand): Extend comment.
13505         * config/m68k/constraints.md (Cu): New constraint.
13506         * config/m68k/m68k.md (UNSPEC_GOTOFF): Remove.
13507         (UNSPEC_RELOC16, UNSPEC_RELOC32): New constants.
13508         (movsi): Handle TLS symbols.
13509         (addsi3_5200): Handle XTLS symbols, indent.
13510         * config/m68k/m68k-protos.h (m68k_legitimize_tls_address): Declare.
13511         (m68k_tls_reference_p): Declare.
13512         (m68k_legitimize_address): Declare.
13513         (m68k_unwrap_symbol): Declare.
13514         * config/m68k/m68k.opt (mxtls): New option.
13515         * config/m68k/m68k.c (ggc.h): Include.
13516         (m68k_output_dwarf_dtprel): Implement hook.
13517         (TARGET_HAVE_TLS, TARGET_ASM_OUTPUT_DWARF_DTPREL): Define.
13518         (m68k_expand_prologue): Load GOT pointer when function needs it.
13519         (m68k_illegitimate_symbolic_constant_p): Handle TLS symbols.
13520         (m68k_legitimate_constant_address_p): Same.
13521         (m68k_decompose_address): Handle TLS references.
13522         (m68k_get_gp): New static function.
13523         (enum m68k_reloc): New contants.
13524         (TLS_RELOC_P): New macro.
13525         (m68k_wrap_symbol): New static function.
13526         (m68k_unwrap_symbol): New function.
13527         (m68k_final_prescan_insn_1): New static function.
13528         (m68k_final_prescan_insn): New function.
13529         (m68k_move_to_reg, m68k_wrap_symbol_into_got_ref): New static
13530         functions.
13531         (legitimize_pic_address): Handle TLS references..
13532         (m68k_tls_get_addr, m68k_get_tls_get_addr)
13533         (m68k_libcall_value_in_a0_p)
13534         (m68k_call_tls_get_addr, m68k_read_tp, m68k_get_m68k_read_tp)
13535         (m68k_call_m68k_read_tp): Helper variables and functions for ...
13536         (m68k_legitimize_tls_address): Handle TLS references.
13537         (m68k_tls_symbol_p, m68k_tls_reference_p_1, m68k_tls_reference_p):
13538         New functions.
13539         (m68k_legitimize_address): Handle TLS symbols.
13540         (m68k_get_reloc_decoration): New static function.
13541         (m68k_output_addr_const_extra): Handle UNSPEC_RELOC16 and
13542         UNSPEC_RELOC32.
13543         (m68k_output_dwarf_dtprel): Implement hook.
13544         (print_operand_address): Handle UNSPEC_RELOC16 adn UNSPEC_RELOC32.
13545         (m68k_libcall_value): Return result in A0 instead of D0 when asked by
13546         m68k_call_* routines.
13547         (sched_attr_op_type): Handle TLS symbols.
13548         (gt-m68k.h): Include.
13549         * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Define.
13550         (LEGITIMATE_PIC_OPERAND_P): Support TLS.
13551
13552 2009-05-18  Martin Jambor  <mjambor@suse.cz>
13553
13554         * ipa-prop.c (ipa_check_stmt_modifications): Removed.
13555         (visit_store_addr_for_mod_analysis): New function.
13556         (ipa_detect_param_modifications): Use walk_stmt_load_store_addr_ops.
13557         (determine_cst_member_ptr): Use gimple_assign_single_p.
13558         (ipa_get_stmt_member_ptr_load_param): Use gimple_assign_single_p.
13559         (ipa_analyze_call_uses): Use !gimple_assign_rhs2 rather than number of
13560         operands.  Don't check number of operands of a NOP_EXPR.
13561
13562 2009-05-18  Eric Fisher  <joefoxreal@gmail.com>
13563
13564         * doc/tree-ssa.texi (SSA Operands): Fix a mistake.
13565
13566 2009-05-17  Manuel López-Ibáñez  <manu@gcc.gnu.org>
13567
13568         PR c/40172
13569         * c-common.c (warn_logical_operator): Don't warn if one of
13570         expression isn't always true or false.
13571
13572 2009-05-17  Kai Tietz  <kai.tietz@onevision.com>
13573
13574         * config/i386/biarch32.h: New file.
13575         * config.gcc: Add for target i386-w64-* the biarch32.h to tm_file.
13576
13577 2009-05-17  Adam Nemet  <anemet@caviumnetworks.com>
13578
13579         * config/mips/mips.md (*zero_extend<mode>_trunchi,
13580         *zero_extend<mode>_truncqi): Merge these into ...
13581         (*zero_extend<GPR:mode>_trunc<SHORT:mode>): ... this new pattern.
13582         Name the pattern following this as *zero_extendhi_truncqi.
13583
13584 2009-05-16  Brad Lucier  <lucier@math.purdue.edu>
13585
13586         PR middle-end/39301
13587         * hwint.h: Add macro HOST_WIDEST_INT_PRINT.
13588         * bitmap.c (bitmap_descriptor): Make fields HOST_WIDEST_INT.
13589         (output_info): Make field HOST_WIDEST_INT.
13590         (print_statistics): Use HOST_WIDEST_INT_PRINT.
13591         (dump_bitmat_statistics): Same.
13592
13593 2009-05-16  Francois-Xavier Coudert  <fxcoudert@gmail.com>
13594
13595         * config.gcc (use_gcc_stdint):  Set to wrap.
13596         * config/darwin.h (SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE,
13597         INT32_TYPE, INT64_TYPE, UINT8_TYPE, UINT16_TYPE, UINT32_TYPE,
13598         UINT64_TYPE, INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE,
13599         INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE,
13600         UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE,
13601         INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE,
13602         UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE,
13603         UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE): Define.
13604
13605 2009-05-16  Joseph Myers  <joseph@codesourcery.com>
13606
13607         * config.gcc (mips*-*-*): Support arch_32, arch_64, tune_32 and
13608         tune_64.
13609         * config/mips/mips.h (MIPS_ABI_DEFAULT, MULTILIB_ABI_DEFAULT):
13610         Move definitions earlier.
13611         (OPT_ARCH64, OPT_ARCH32): Define.
13612         (OPTION_DEFAULT_SPECS): Add entries for arch_32, arch_64, tune_32
13613         and tune_64.
13614
13615 2009-05-16  Richard Earnshaw  <rearnsha@arm.com>
13616
13617         PR target/40153
13618         * arm.md (cstoresi_nltu_thumb1): Use a neg of ltu as the pattern name
13619         implies.
13620
13621 2009-05-16  Richard Earnshaw  <rearnsha@arm.com>
13622
13623         * arm.md (movdi2): Copy non-reg values to DImode registers.
13624
13625 2009-05-16  Jakub Jelinek  <jakub@redhat.com>
13626
13627         PR target/39942
13628         * final.c (label_to_max_skip): New function.
13629         (label_to_alignment): Only use LABEL_TO_ALIGNMENT if
13630         CODE_LABEL_NUMBER <= max_labelno.
13631         * output.h (label_to_max_skip): New prototype.
13632         * config/i386/i386.c (ix86_avoid_jump_misspredicts): Renamed to...
13633         (ix86_avoid_jump_mispredicts): ... this.  Don't define if
13634         ASM_OUTPUT_MAX_SKIP_ALIGN isn't defined.  Update comment.
13635         Handle CODE_LABELs with >= 16 byte alignment or with
13636         max_skip == (1 << align) - 1.
13637         (ix86_reorg): Don't call ix86_avoid_jump_mispredicts if
13638         ASM_OUTPUT_MAX_SKIP_ALIGN isn't defined.
13639
13640         PR target/39942
13641         * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Don't emit second
13642         .p2align 3 if MAX_SKIP is smaller than 7.
13643         * config/i386/linux.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
13644
13645 2009-05-15  Ian Lance Taylor  <iant@google.com>
13646
13647         * alias.c (struct alias_set_entry_d): Rename from struct
13648         alias_set_entry.  Change all uses.
13649         * except.c (struct call_site_record_d): Rename from struct
13650         call_site_record.  Change all uses.
13651         * except.h (struct eh_region_d): Rename from struct eh_region.
13652         Change all uses.
13653         * gcse.c (struct hash_table_d): Rename from struct hash_table.
13654         Change all uses.
13655         * graphite.c (struct ivtype_map_elt_d): Rename fromstruct
13656         ivtype_map_elt.  Change all uses.
13657         (struct rename_map_elt_d): Rename fromstruct rename_map_elt.
13658         Change all uses.
13659         (struct ifsese_d): Rename fromstruct ifsese.  Change all uses.
13660         * graphite.h (struct name_tree_d): Rename from struct name_tree.
13661         Change all uses.
13662         (struct sese_d): Rename from struct sese.  Change all uses.
13663         * omega.h (struct eqn_d): Rename from struct eqn.  Change all uses.
13664         (struct omega_pb_d): Rename from struct omega_pb.  Change all uses.
13665         * optabs.h (struct optab_d): Rename from struct optab.  Change all
13666         uses.
13667         (struct convert_optab_d): Rename from struct convert_optab.
13668         Change all uses.
13669         * tree-pass.h (struct ipa_opt_pass_d): Rename fromstruct
13670         ipa_opt_pass.  Change all uses.
13671         * tree-predcom.c (struct dref_d): Rename from struct dref.  Change
13672         all uses.
13673
13674         * c-decl.c (pushtag): If -Wc++-compat, warn if the tag is already
13675         defined as a typedef.
13676         (grokdeclarator): If -Wc++-compat, warn if a typedef is already
13677         defined as a tag.
13678
13679 2009-05-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
13680
13681         PR 16302
13682         * fold-const.c (make_range,build_range_check,merge_ranges): Move
13683         declaration to...
13684         (merge_ranges): Returns bool.
13685         * tree.h (make_range): .. to here.
13686         (build_range_check): Likewise.
13687         (merge_ranges): Likewise. Renamed from merge_ranges.
13688         * c-typeck.c (parser_build_binary_op): Update calls to
13689         warn_logical_operator.
13690         * c-common.c (warn_logical_operator): Add new warning.
13691         * c-common.h (warn_logical_operator): Update declaration.
13692
13693 2009-05-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
13694
13695         * ira-conflicts.c (add_insn_allocno_copies): Fix wrong conditional.
13696
13697 2009-05-15  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
13698
13699         * doc/install.texi: Document MPC requirements, flags etc.
13700
13701         * builtins.c (do_mpc_arg1, fold_builtin_ccos): New.
13702         (fold_builtin_cexp): Ensure we get a complex REAL_TYPE.
13703         Evaluate constant arguments.
13704         (fold_builtin_carg): Ensure we get a complex REAL_TYPE.
13705         (fold_builtin_1): Likewise, also evaluate constant arguments.
13706         Remove superfluous break.
13707         (do_mpc_ckconv): New.
13708         * real.h: Include mpc.h.
13709         * toplev.c (print_version): Output MPC version info if available.
13710
13711 2009-05-15  Sandra Loosemore  <sandra@codesourcery.com>
13712
13713         * fold-const.c (fold_convert_const_real_from_real): Check for overflow.
13714
13715 2009-05-15  H.J. Lu  <hongjiu.lu@intel.com>
13716
13717         * config/i386/i386.c (ix86_reorg): Call optimize_function_for_speed_p
13718         only once.
13719
13720 2009-05-15  Jan Hubicka  <jh@suse.cz>
13721
13722         * doc/invoke.texi (max-early-inliner-iterations): New flag.
13723         * ipa-inline.c (enum inlining_mode): New INLINE_SIZE_NORECURSIVE.
13724         (try_inline): Fix return value.
13725         (cgraph_decide_inlining_incrementally): Honor new value.
13726         (cgraph_early_inlining): Handle indirect inlining.
13727         * params.def (PARAM_EARLY_INLINER_MAX_ITERATIONS): New.
13728
13729 2009-05-15  Jan Hubicka  <jh@suse.cz>
13730
13731         * cgraph.h (struct cgraph_node): Add finalized_by_frotnend flag.
13732         * cgraphunit.c (cgraph_finalize_function): Set it.
13733         (cgraph_expand_function): Use it.
13734
13735 2009-05-15  Sandra Loosemore  <sandra@codesourcery.com>
13736
13737         * real.c (encode_ieee_half): Define.
13738         (decode_ieee_half): Define.
13739         (ieee_half_format): Define.
13740         (arm_half_format): Define.
13741         * real.h (ieee_half_format): Declare.
13742         (arm_half_format): Declare.
13743
13744 2009-05-15  Sandra Loosemore  <sandra@codesourcery.com>
13745
13746         * optabs.c (prepare_float_lib_cmp):  Test that the comparison,
13747         swapped, and reversed optabs exist before trying to use them.
13748
13749 2009-05-15  Paul Brook  <paul@codesourcery.com>
13750             Sandra Loosemore  <sandra@codesourcery.com>
13751
13752         * config/arm/arm.c (neon_vector_mem_operand): Handle element/structure
13753         loads.  Allow PRE_DEC.
13754         (output_move_neon): Handle PRE_DEC.
13755         (arm_print_operand): Add 'A' for neon structure loads.
13756         * config/arm/arm-protos.h (neon_vector_mem_operand): Update prototype.
13757         * config/arm/neon.md (neon_mov): Update comment.
13758         * config/arm/constraints.md (Un, Us): Update neon_vector_mem_operand
13759         calls.
13760         (Um): New constraint.
13761
13762 2009-05-15  Jan Hubicka  <jh@suse.cz>
13763
13764         Revert the following patch until testsuite fallout is fixed:
13765         * cgraph.c (dump_cgraph_node): Dump size/time/benefit.
13766         * cgraph.h (struct inline_summary): New filed self_wize,
13767         size_inlining_benefit, self_time and time_inlining_benefit.
13768         (struct cgraph_global_info): Replace insns by time ans size fields.
13769         * ipa-cp (ipcp_cloning_candidate_p): Base estimate on size
13770         (ipcp_estimate_growth, ipcp_insert_stage): Likewise.
13771         (ipcp_update_callgraph): Do not touch function bodies.
13772         * ipa-inline.c: Include except.h
13773         (MAX_TIME): New constant.
13774         (overall_insns): Remove
13775         (overall_size, max_benefit): New static variables.
13776         (cgraph_estimate_time_after_inlining): New function.
13777         (cgraph_estimate_size_after_inlining): Rewrite using benefits.
13778         (cgraph_clone_inlined_nodes): Update size.
13779         (cgraph_mark_inline_edge): Update size.
13780         (cgraph_estimate_growth): Use size info.
13781         (cgraph_check_inline_limits): Check size.
13782         (cgraph_default_inline_p): Likewise.
13783         (cgraph_edge_badness): Compute badness based on benefit and size cost.
13784         (cgraph_decide_recursive_inlining): Check size.
13785         (cgraph_decide_inlining_of_small_function): Update size; dump sizes
13786         and times.
13787         (cgraph_decide_inlining): Likewise.
13788         (cgraph_decide_inlining_incrementally): Likewise; honor
13789         PARAM_EARLY_INLINING_INSNS.
13790         (likely_eliminated_by_inlining_p): New predicate.
13791         (estimate_function_body_sizes): New function.
13792         (compute_inline_parameters): Use it.
13793         * except.c (must_not_throw_labels): New function.
13794         * except.h (must_not_throw_labels): Declare.
13795         * tree-inline.c (init_inline_once): Kill inlining_weigths
13796         * tree-ssa-structalias.c: Avoid uninitialized warning.
13797         * params.def (PARAM_MAX_INLINE_INSNS_SINGLE): Reduce to 300.
13798         (PARAM_MAX_INLINE_INSNS_AUTO): Reduce to 60.
13799         (PARAM_INLINE_CALL_COST): Remove.
13800         (PARAM_EARLY_INLINING_INSNS): New.
13801
13802 2009-05-15  Richard Guenther  <rguenther@suse.de>
13803
13804         * tree-ssa-pre.c (eliminate): Use TODO_update_ssa_only_virtuals,
13805         not TODO_update_ssa.
13806
13807 2009-05-15  Richard Guenther  <rguenther@suse.de>
13808
13809         PR tree-optimization/39999
13810         * gimple.h (gimple_expr_type): Use the expression type looking
13811         through useless conversions.
13812         * tree-ssa-sccvn.c (vn_nary_op_lookup_stmt): Use gimple_expr_type.
13813         (vn_nary_op_insert_stmt): Likewise.
13814         (simplify_binary_expression): Likewise.
13815
13816 2009-05-15  Richard Guenther  <rguenther@suse.de>
13817
13818         * common.opt (-ftree-forwprop, -ftree-phiprop, -ftree-pta):
13819         New options, enabled by default.
13820         * doc/invoke.texi (-ftree-forwprop, -ftree-phiprop, -ftree-pta):
13821         Document.
13822         * tree-ssa-forwprop.c (gate_forwprop): Use flag_tree_forwprop.
13823         * tree-ssa-phiprop.c (gate_phiprop): Use flag_tree_phiprop.
13824         * tree-ssa-structalias.c (gate_tree_pta): New function.
13825         (pass_build_alias): Use it.
13826
13827 2009-05-15  Joseph Myers  <joseph@codesourcery.com>
13828
13829         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Also
13830         recurse on an invariant address if a conversion from a pointer
13831         type to a wider integer type is involved.
13832
13833 2009-05-15  Jan Hubicka  <jh@suse.cz>
13834
13835         * cgraph.c (dump_cgraph_node): Dump size/time/benefit.
13836         * cgraph.h (struct inline_summary): New filed self_wize,
13837         size_inlining_benefit, self_time and time_inlining_benefit.
13838         (struct cgraph_global_info): Replace insns by time ans size fields.
13839         * ipa-cp (ipcp_cloning_candidate_p): Base estimate on size
13840         (ipcp_estimate_growth, ipcp_insert_stage): Likewise.
13841         (ipcp_update_callgraph): Do not touch function bodies.
13842         * ipa-inline.c: Include except.h
13843         (MAX_TIME): New constant.
13844         (overall_insns): Remove
13845         (overall_size, max_benefit): New static variables.
13846         (cgraph_estimate_time_after_inlining): New function.
13847         (cgraph_estimate_size_after_inlining): Rewrite using benefits.
13848         (cgraph_clone_inlined_nodes): Update size.
13849         (cgraph_mark_inline_edge): Update size.
13850         (cgraph_estimate_growth): Use size info.
13851         (cgraph_check_inline_limits): Check size.
13852         (cgraph_default_inline_p): Likewise.
13853         (cgraph_edge_badness): Compute badness based on benefit and size cost.
13854         (cgraph_decide_recursive_inlining): Check size.
13855         (cgraph_decide_inlining_of_small_function): Update size; dump sizes
13856         and times.
13857         (cgraph_decide_inlining): Likewise.
13858         (cgraph_decide_inlining_incrementally): Likewise; honor
13859         PARAM_EARLY_INLINING_INSNS.
13860         (likely_eliminated_by_inlining_p): New predicate.
13861         (estimate_function_body_sizes): New function.
13862         (compute_inline_parameters): Use it.
13863         * except.c (must_not_throw_labels): New function.
13864         * except.h (must_not_throw_labels): Declare.
13865         * tree-inline.c (init_inline_once): Kill inlining_weigths
13866         * tree-ssa-structalias.c: Avoid uninitialized warning.
13867         * params.def (PARAM_MAX_INLINE_INSNS_SINGLE): Reduce to 300.
13868         (PARAM_MAX_INLINE_INSNS_AUTO): Reduce to 60.
13869         (PARAM_INLINE_CALL_COST): Remove.
13870         (PARAM_EARLY_INLINING_INSNS): New.
13871         doc/invoke.texi (max-inline-insns-auto, early-inlining-insns): Update.
13872         (inline-call-cost): Remove.
13873         (early-inlining-insns): New.
13874
13875 2009-05-15  Eric Botcazou  <ebotcazou@adacore.com>
13876
13877         * dbxout.c (dbxout_range_type): Add LOW and HIGH parameters.  Use them
13878         for bounds.
13879         (print_int_cst_bounds_in_octal_p): Likewise.
13880         (dbxout_type): Adjust calls to above functions.  Be prepared to deal
13881         with subtypes.
13882         * dwarf2out.c (base_type_die): Likewise.
13883         (is_subrange_type): Delete.
13884         (subrange_type_die): Add LOW and HIGH parameters.  Use them for bounds.
13885         (modified_type_die): Call subrange_type_for_debug_p on subtypes.
13886         * fold-const.c (fold_truth_not_expr) <CONVERT_EXPR>: Do not strip it
13887         if the destination type is boolean.
13888         (build_range_check): Do not special-case subtypes.
13889         (fold_sign_changed_comparison): Likewise.
13890         (fold_unary): Likewise.
13891         * langhooks-def.h (LANG_HOOKS_GET_SUBRANGE_BOUNDS): Define.
13892         (LANG_HOOKS_FOR_TYPES_INITIALIZER): Add LANG_HOOKS_GET_SUBRANGE_BOUNDS.
13893         * langhooks.h (lang_hooks_for_types): Add get_subrange_bounds.
13894         * tree.c (subrange_type_for_debug_p): New predicate based on the
13895         former is_subrange_type.
13896         * tree.h (subrange_type_for_debug_p): Declare.
13897         * tree-chrec.c (avoid_arithmetics_in_type_p): Delete.
13898         (convert_affine_scev): Remove call to above function.
13899         (chrec_convert_aggressive): Likewise.
13900         * tree-ssa.c (useless_type_conversion_p_1): Do not specifically return
13901         false for conversions involving subtypes.
13902         * tree-vrp.c (vrp_val_max): Do not special-case subtypes.
13903         (vrp_val_min): Likewise.
13904         (needs_overflow_infinity): Likewise.
13905         (extract_range_from_unary_expr): Likewise.
13906
13907 2009-05-15  Paolo Bonzini  <bonzini@gnu.org>
13908
13909         * config/frv/frv.h: Clean up references to GO_IF_LEGITIMATE_ADDRESS.
13910         * config/frv/frv.c: Likewise.
13911         * config/s390/s390.c: Likewise.
13912         * config/sparc/sparc.h: Likewise.
13913         * config/i386/i386.h: Likewise.
13914         * config/i386/i386.c: Likewise.
13915         * config/crx/crx.c: Likewise.
13916         * config/m68hc11/m68hc11.h: Likewise.
13917         * config/iq2000/iq2000.c: Likewise.
13918         * config/mn10300/mn10300.h: Likewise.
13919         * config/mn10300/mn10300.c: Likewise.
13920         * config/m68k/m68k.c: Likewise.
13921         * config/rs6000/rs6000.c: Likewise.
13922         * config/rs6000/xcoff.h: Likewise.
13923         * config/rs6000/linux64.h: Likewise.
13924         * config/rs6000/sysv4.h: Likewise.
13925         * config/score/score3.c: Likewise.
13926         * config/score/score7.c: Likewise.
13927         * config/score/score.c: Likewise.
13928         * config/arm/arm.md: Likewise.
13929         * config/mips/mips.c: Likewise.
13930         * config/mips/mips.md: Likewise.
13931         * config/bfin/bfin.h: Likewise.
13932         * config/pa/pa.c: Likewise.
13933         * config/pa/constraints.md: Likewise.
13934
13935         * config/pdp11/pdp11-protos.h (legitimate_address_p): Delete.
13936         * config/pdp11/pdp11.c (legitimate_address_p): Delete.
13937         * config/pdp11/pdp11.h: Use memory_address_p instead.
13938
13939 2009-05-14  Ian Lance Taylor  <iant@google.com>
13940
13941         * passes.c (finish_optimization_passes): Change i to int.
13942         * plugin.c (plugins_active_p): Change event to int.
13943         (dump_active_plugins): Likewise.
13944         * reginfo.c (invalid_mode_change_p): Change to to unsigned int.
13945         Add cast.
13946         * tree.c (tree_range_check_failed): Change c to unsigned int.
13947         (omp_clause_range_check_failed): Likewise.
13948         (build_common_builtin_nodes): Change mode to int.  Add cast.
13949         * config/ia64/ia64.c (is_emitted): Change r to unsigned int.
13950         (ia64_hard_regno_rename_ok, ia64_eh_uses): Likewise.
13951
13952         * c-typeck.c (build_unary_op): If -Wc++-compat, warn about using
13953         ++ or -- with a variable of enum type.
13954
13955 2009-05-14  Steven Bosscher  <steven@gcc.gnu.org>
13956
13957         PR driver/40144
13958         * opts.c (common_handle_option): Add OPT_fcse_skip_blocks as a no-op.
13959
13960 2009-05-14  Steven Bosscher  <steven@gcc.gnu.org>
13961
13962         * store-motion.c: Do not include params.h
13963         * Makefile.in: Fix dependencies for various files.
13964
13965 2009-05-14  Steven Bosscher  <steven@gcc.gnu.org>
13966
13967         * auto-inc-dec.c: Fix pass description, remove apparent
13968         accidental duplication.
13969
13970 2009-05-14  H.J. Lu  <hongjiu.lu@intel.com>
13971
13972         PR middle-end/40147
13973         * ipa-utils.h (memory_identifier_string): Moved to ...
13974         * tree.h (memory_identifier_string): Here.  Add GTY(()).
13975
13976 2009-05-14  Paolo Bonzini  <bonzini@gnu.org>
13977
13978         * doc/tm.texi (TARGET_LEGITIMATE_ADDRESS_P): Refer mainly to this
13979         in the former documentation of...
13980         (GO_IF_LEGITIMATE_ADDRESS): ... this.
13981         * ira-conflicts.c (get_dup_num): Use address_operand.
13982         * targhooks.c (default_legitimate_address_p): New.
13983         * targhooks.h (default_legitimate_address_p): New.
13984         * reload.c (strict_memory_address_p) [!GO_IF_LEGITIMATE_ADDRESS]:
13985         Call hook.
13986         * recog.c (memory_address_p) [!GO_IF_LEGITIMATE_ADDRESS]: Call hook.
13987         * target.h (struct target): Add legitimate_address_p.
13988         * target-def.h (TARGET_LEGITIMATE_ADDRESS_P): New.
13989         (TARGET_INITIALIZER): Include it.
13990
13991         * config/alpha/alpha.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
13992         * config/alpha/alpha-protos.h (alpha_legitimate_address_p): Remove.
13993         * config/alpha/alpha.c (alpha_legitimate_address_p): Make static.
13994         (TARGET_LEGITIMATE_ADDRESS_P): New.
13995
13996         * config/frv/frv.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
13997         (REG_OK_STRICT_P): Delete.
13998         * config/frv/frv-protos.h (frv_legitimate_address_p): Rename to...
13999         (frv_legitimate_address_p_1): ... this.
14000         * config/frv/frv.c (frv_legitimate_address_p): Forward to...
14001         (frv_legitimate_address_p_1): ... the renamed old
14002         frv_legitimate_address_p.
14003         * config/frv/predicates.md: Adjust calls to frv_legitimate_address_p.
14004         (TARGET_LEGITIMATE_ADDRESS_P): New.
14005
14006         * config/s390/s390.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14007         * config/s390/s390-protos.h (legitimate_address_p): Remove.
14008         * config/s390/s390.c (legitimate_address_p): Rename to...
14009         (s390_legitimate_address_p): ... this, make static.
14010         (legitimize_address): Adjust call.
14011         (TARGET_LEGITIMATE_ADDRESS_P): New.
14012         * config/s390/constraints.md ("e"): Call strict_memory_address_p.
14013
14014         * config/m32c/m32c.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14015         * config/m32c/m32c-protos.h (m32c_legitimate_address_p): Remove.
14016         * config/m32c/m32c.c (m32c_legitimate_address_p): Make static.
14017         (TARGET_LEGITIMATE_ADDRESS_P): New.
14018
14019         * config/spu/spu.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14020         * config/spu/spu-protos.h (spu_legitimate_address): Remove.
14021         * config/spu/spu.c (spu_legitimate_address): Rename to...
14022         (spu_legitimate_address_p): ... this, make static.
14023         (TARGET_LEGITIMATE_ADDRESS_P): New.
14024
14025         * config/sparc/sparc.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14026         * config/sparc/sparc-protos.h (legitimate_address_p): Remove.
14027         * config/sparc/sparc.c (legitimate_address_p): Rename to...
14028         (sparc_legitimate_address_p): ... this, make static and return bool.
14029         (legitimize_address): Adjust call.
14030         (TARGET_LEGITIMATE_ADDRESS_P): New.
14031
14032         * config/i386/i386.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14033         * config/i386/i386-protos.h (legitimate_address_p): Remove.
14034         * config/i386/i386.c (legitimate_address_p): Rename to...
14035         (ix86_legitimate_address_p): ... this, make static.
14036         (constant_address_p): Move after it, adjust call.
14037         (TARGET_LEGITIMATE_ADDRESS_P): New.
14038
14039         * config/avr/avr.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14040         * config/avr/avr-protos.h (legitimate_address_p): Remove.
14041         * config/avr/avr.c (legitimate_address_p): Rename to...
14042         (avr_legitimate_address_p): ... this, make static.
14043         (legitimize_address): Adjust call.
14044         (TARGET_LEGITIMATE_ADDRESS_P): New.
14045
14046         * config/crx/crx.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14047         * config/crx/crx-protos.h (crx_legitimate_address_p): Remove.
14048         * config/crx/crx.c (crx_legitimate_address_p): Make static.
14049         (TARGET_LEGITIMATE_ADDRESS_P): New.
14050
14051         * config/xtensa/xtensa.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14052         * config/xtensa/xtensa-protos.h (xtensa_legitimate_address_p): Remove.
14053         * config/xtensa/xtensa.c (xtensa_legitimate_address_p): Make static.
14054         (TARGET_LEGITIMATE_ADDRESS_P): New.
14055
14056         * config/stormy16/stormy16.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14057         * config/stormy16/stormy16-protos.h (xstormy16_legitimate_address_p):
14058         Remove.
14059         * config/stormy16/stormy16.c (xstormy16_legitimate_address_p):
14060         Make static.
14061         (TARGET_LEGITIMATE_ADDRESS_P): New.
14062
14063         * config/m68hc11/m68hc11.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14064         * config/m68hc11/m68hc11-protos.h (m68hc11_go_if_legitimate_address):
14065         Remove.
14066         * config/m68hc11/m68hc11.c (m68hc11_go_if_legitimate_address):
14067         Rename to...
14068         (m68hc11_legitimate_address_p): ... this, make static.
14069         (go_if_legitimate_address_internal): Rename to...
14070         (m68hc11_legitimate_address_p_1): ... this.
14071         (legitimize_address): Adjust call.
14072         (TARGET_LEGITIMATE_ADDRESS_P): New.
14073
14074         * config/iq2000/iq2000.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14075         * config/iq2000/iq2000-protos.h (iq2000_legitimate_address_p): Remove.
14076         * config/iq2000/iq2000.c (iq2000_legitimate_address_p): Make static.
14077         (TARGET_LEGITIMATE_ADDRESS_P): New.
14078
14079         * config/mn10300/mn10300.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14080         * config/mn10300/mn10300-protos.h (legitimate_address_p): Remove.
14081         * config/mn10300/mn10300.c (legitimate_address_p): Rename to...
14082         (mn10300_legitimate_address_p): ... this, make static.
14083         (TARGET_LEGITIMATE_ADDRESS_P): New.
14084
14085         * config/m68k/m68k.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14086         * config/m68k/m68k-protos.h (m68k_legitimate_address_p): Remove.
14087         * config/m68k/m68k.c (m68k_legitimate_address_p): Make static.
14088         (TARGET_LEGITIMATE_ADDRESS_P): New.
14089
14090         * config/rs6000/rs6000.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14091         (REG_OK_STRICT_FLAG, REG_OK_FOR_BASE_P, REG_OK_FOR_INDEX_P): Delete.
14092         (INT_REG_OK_FOR_BASE_P, INT_REG_OK_FOR_INDEX_P): Move above.
14093         * config/rs6000/rs6000.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14094         * config/rs6000/rs6000-protos.h (rs6000_legitimate_address): Remove.
14095         * config/rs6000/rs6000.c (rs6000_legitimate_address): Rename to...
14096         (rs6000_legitimate_address_p): ... this, make static.
14097         (TARGET_LEGITIMATE_ADDRESS_P): New.
14098         (REG_MODE_OK_FOR_BASE_P): Delete.
14099         (rs6000_legitimize_reload_address): Use INT_REG_OK_FOR_BASE_P.
14100
14101         * config/picochip/picochip.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14102         * config/picochip/picochip-protos.h (picochip_legitimate_address_p):
14103         Delete.
14104         * config/picochip/picochip.c (picochip_legitimate_address_p): Make
14105         static, adjust types.
14106         (TARGET_LEGITIMATE_ADDRESS_P): New.
14107
14108         * config/score/score.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14109         * config/score/score.c (score_address_p): Rename to...
14110         (score_legitimate_address_p): ... this.
14111         (TARGET_LEGITIMATE_ADDRESS_P): New.
14112         * config/score/score3.c (score3_address_p): Rename to...
14113         (score3_legitimate_address_p): ... this.
14114         * config/score/score7.c (score7_address_p): Rename to...
14115         (score7_legitimate_address_p): ... this.
14116
14117         * config/arm/arm.h (ARM_GO_IF_LEGITIMATE_ADDRESS,
14118         THUMB2_GO_IF_LEGITIMATE_ADDRESS, THUMB1_GO_IF_LEGITIMATE_ADDRESS,
14119         GO_IF_LEGITIMATE_ADDRESS): Delete.
14120         * config/arm/arm-protos.h (thumb1_legitimate_address_p,
14121         thumb2_legitimate_address_p): Delete.
14122         (arm_legitimate_address_p): Rename to...
14123         (arm_legitimate_address_outer_p): ... this.
14124         * config/arm/constraints.md ("Uq"): Adjust call.
14125         * config/arm/predicates.md (arm_extendqisi_mem_op): Likewise.
14126         * config/arm/arm.c (arm_legitimate_address_p): New, rename old one
14127         to...
14128         (arm_legitimate_address_outer_p): ... this.
14129         (thumb1_legitimate_address_p, thumb2_legitimate_address_p): Make
14130         static.
14131         (TARGET_LEGITIMATE_ADDRESS_P): New.
14132
14133         * config/mips/mips.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14134         * config/mips/mips-protos.h (mips_legitimate_address_p): Remove.
14135         * config/mips/mips.c (mips_legitimate_address_p): ... Make static.
14136         (TARGET_LEGITIMATE_ADDRESS_P): New.
14137
14138         * config/vax/vax.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14139         * config/vax/vax-protos.h (legitimate_address_p): Remove.
14140         * config/vax/vax.c (legitimate_address_p): Rename to...
14141         (vax_legitimate_address_p): ... this, make static.
14142         (TARGET_LEGITIMATE_ADDRESS_P): New.
14143
14144         * config/h8300/h8300.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14145         * config/h8300/h8300-protos.h (h8300_legitimate_address_p): Remove.
14146         * config/h8300/h8300.c (h8300_legitimate_address_p): ... Make static.
14147         (TARGET_LEGITIMATE_ADDRESS_P): New.
14148
14149         * config/mmix/mmix.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14150         * config/mmix/mmix-protos.h (mmix_legitimize_address): Remove.
14151         * config/mmix/mmix.c (mmix_legitimate_address): Rename to...
14152         (mmix_legitimate_address_p): ... this, make static.
14153         (TARGET_LEGITIMATE_ADDRESS_P): New.
14154
14155         * config/bfin/bfin.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
14156         * config/bfin/bfin-protos.h (bfin_legitimate_address_p): Remove.
14157         * config/bfin/bfin.c (bfin_legitimate_address_p): ... Make static.
14158         (TARGET_LEGITIMATE_ADDRESS_P): New.
14159
14160 2009-05-14  Paolo Bonzini  <bonzini@gnu.org>
14161
14162         * config/arm/arm.h (PROMOTE_FUNCTION_MODE): Remove handling
14163         of MODE_COMPLEX_INT.
14164
14165 2009-05-14  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
14166
14167         * config/alpha/alpha.c (alpha_initialize_trampoline): Change 0 to
14168         LCT_NORMAL in function call.
14169         * mips-tdump.c (print_file_desc): Add cast to enum type.
14170         * mips-tfile.c (add_ext_symbol): Add casts to enum types.
14171         (mark_stabs): Add casts to enum types.
14172         (parse_stabs_common): Add casts to enum types.
14173
14174 2009-05-13  Adam Nemet  <anemet@caviumnetworks.com>
14175
14176         * config/mips/mips.c (mips_print_operand) <REG, MEM, default>:
14177         Check for invalid values of LETTER.
14178
14179 2009-05-13  Taras Glek  <tglek@mozilla.com>
14180
14181         * attribs.c (register_attribute): moved out attribute registration
14182         into register_attribute.
14183         * doc/plugins.texi: Documented register_attribute and
14184         PLUGIN_ATTRIBUTES.
14185         * gcc-plugin.h: Added forward decl for register_attribute.
14186         * gcc-plugin.h (plugins_event): Added PLUGIN_ATTRIBUTES.
14187         * plugin.c (register_callback, invoke_plugin_callbacks): Added
14188         PLUGIN_ATTRIBUTES boilerplate.
14189
14190 2009-05-14  Dave Korn  <dave.korn.cygwin@gmail.com>
14191
14192         * config/i386/msformat-c.c (ms_printf_length_specs):  Use enumeration
14193         values even in sentinel and empty entries.
14194         (ms_printf_flag_specs):  Likewise.
14195         (ms_scanf_flag_specs):  Likewise.
14196         (ms_strftime_flag_specs):  Likewise.
14197         (ms_print_char_table):  Likewise.
14198         (ms_scan_char_table):  Likewise.
14199         (ms_time_char_table):  Likewise.
14200
14201 2009-05-13  Doug Kwan  <dougkwan@google.com>
14202
14203         * tree-ssa-sccvn.c (compare_ops): Stabilize qsort.
14204
14205 2009-05-13  Adam Nemet  <anemet@caviumnetworks.com>
14206
14207         * config/mips/mips.md (store): Add attributes for QI and HI.
14208         Update comment.
14209         (truncdisi2, truncdihi2, truncdiqi2): Merge these into ...
14210         (truncdi<mode>2): ... this new pattern.
14211
14212 2009-05-13  Brad Hards  <bradh@kde.org>
14213
14214         * Makefile.in (TEXI_GCCINT_FILES): Add plugins.texi.
14215
14216 2009-05-14  Jakub Jelinek  <jakub@redhat.com>
14217             Ben Elliston <bje@au.ibm.com>
14218
14219         PR middle-end/40035
14220         * dse.c (check_mem_read_rtx): Guard against width == -1.
14221
14222 2009-05-13  Michael Matz  <matz@suse.de>
14223
14224         PR middle-end/39976
14225         * tree-outof-ssa.c (maybe_renumber_stmts_bb): New function.
14226         (trivially_conflicts_p): New function.
14227         (insert_backedge_copies): Use it.
14228
14229 2009-05-13  Janis Johnson  <janis187@us.ibm.com>
14230
14231         * c-pragma.c (enum pragma_switch_t): Prefix constants with PRAGMA_.
14232         (handle_stdc_pragma): Use new enum constant names.
14233         (handle_pragma_float_const_decimal64): Ditto.
14234
14235 2009-05-13  Ian Lance Taylor  <iant@google.com>
14236
14237         * Makefile.in (build/gencheck.o): Depend upon all-tree.def, not
14238         tree.def.
14239
14240 2009-05-13  Nathan Sidwell  <nathan@codesourcery.com>
14241
14242         * config/m68k/t-uclinux (M68K_MLIB_CPU): Check for FL_UCLINUX.
14243         * config/m68k/m68k-devices.def: Add FL_UCLINUX to 68020 and 54455
14244         multilibs.
14245         * config/m68k/m68k.h (FL_UCLINUX): Define.
14246
14247 2009-05-13  Jan Hubicka  <jh@suse.cz>
14248
14249         * options.c (gfc_post_options): -fwhole-program imply -fwhole-file.
14250
14251 2009-05-12  Kaz Kojima  <kkojima@gcc.gnu.org>
14252
14253         * config/sh/sh.h (OVERRIDE_OPTIONS): Clear flag_schedule_insns
14254         unless -fschedule-insns is specified.
14255
14256 2009-05-12  Kaz Kojima  <kkojima@gcc.gnu.org>
14257
14258         PR target/39561
14259         * config/sh/sh.h (OPTIMIZATION_OPTIONS): Don't set
14260         TARGET_EXPAND_CBRANCHDI4.
14261         * config/sh/sh.md (cbranchdi4): Don't check TARGET_EXPAND_CBRANCHDI4.
14262         * config/sh/sh.opt (mexpand-cbranchdi): Remove.
14263         (cmpeqdi): Fix comment.
14264
14265 2009-05-12  Kaz Kojima  <kkojima@gcc.gnu.org>
14266
14267         * config/sh/sh-protos.h (sh_legitimate_index_p): Declare.
14268         (sh_legitimate_address_p): Likewise.
14269         * config/sh/sh.c (sh_legitimate_index_p): New.
14270         (sh_legitimate_address_p): Likewise.
14271         * config/sh/sh.h (REG_OK_FOR_BASE_P): Add STRICT parameter.
14272         (REG_OK_FOR_INDEX_P, SUBREG_OK_FOR_INDEX_P): Likewise.
14273         (MODE_DISP_OK_4, MODE_DISP_OK_8): Remove.
14274         (MAYBE_BASE_REGISTER_RTX_P): New macro.
14275         (MAYBE_INDEX_REGISTER_RTX_P): Likewise.
14276         (BASE_REGISTER_RTX_P): Use MAYBE_BASE_REGISTER_RTX_P.
14277         (INDEX_REGISTER_RTX_P): Use MAYBE_INDEX_REGISTER_RTX_P.
14278         (GO_IF_LEGITIMATE_INDEX): Use sh_legitimate_index_p.
14279         (GO_IF_LEGITIMATE_ADDRESS): Use sh_legitimate_address_p.
14280
14281 2009-05-12  Jan Hubicka  <jh@suse.cz>
14282
14283         * tree-inline.c (estimate_operator_cost): Add operands;
14284         when division happens by constant, it is cheap.
14285         (estimate_num_insns): Loads and stores are not having cost of 0;
14286         EH magic stuff is cheap; when computing runtime cost of switch,
14287         use log2 base of amount of its cases; builtin_expect has cost of 0;
14288         compute cost for moving return value of call.
14289         (init_inline_once): Initialize time_based flags.
14290         * tree-inline.h (eni_weights_d): Add time_based flag.
14291
14292 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
14293
14294         * df-core.c: Update head documentation.
14295
14296 2009-05-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
14297
14298         PR bootstrap/40118
14299         * rs6000.c (rs6000_generate_compare): Use op1b instead of
14300         shadowing exisiting variable op1.
14301
14302 2009-05-12  Uros Bizjak  <ubizjak@gmail.com>
14303
14304         PR target/37179
14305         * config/i386/driver-i386.c (processor_signatures): New enum.
14306         (SIG_GEODE): Move from vendor_signatures to processor_signatures.
14307         (host_detect_local_cpu): For SIG_AMD vendor, check for SIG_GEODE
14308         processor signature to detect geode processor.
14309
14310 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
14311
14312         Revert:
14313
14314         2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
14315
14316         * optabs.c (prepare_cmp_insn): Temporarily disable test that
14317         causes spurious differences between trunk and cond-optab branch.
14318
14319 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
14320
14321         * dojump.c (compare_from_rtx): Delete.
14322         * expmed.c (emit_store_flag): Only try cstore_optab.  Canonicalize
14323         any MODE_CC mode to the cstorecc4 pattern.  Use prepare_operand, fail
14324         if the comparison does not satisfy the predicate; test predicates for
14325         operands 2 and 3 of a cstore pattern.  Don't try cstore optab
14326         further if one existing pattern fails.
14327         * expr.h (compare_from_rtx): Delete.
14328         (prepare_operand): Declare it.
14329         * optabs.c: Change "lib call" to "libcall" throughout.
14330         (bcc_gen_fctn, setcc_gen_code, trap_rtx,
14331         HAVE_conditional_trap, emit_cmp_insn): Delete.
14332         (can_compare_p): Delete cmp_optab case.
14333         (prepare_float_lib_cmp): Return an rtx and a machine mode.
14334         Accept other parameters by value.
14335         (prepare_operand): Make non-static.
14336         (prepare_cmp_insn): Return an rtx and a machine mode.  Accept
14337         other parameters by value.  Try to widen operands here based on
14338         an optab_methods argument and looking at cbranch_optab.
14339         (emit_cmp_and_jump_insn_1): Accept test and mode, remove widening
14340         loop.  Use cbranch_optab directly.
14341         (emit_cmp_and_jump_insns): Fix comment.  Adjust call to
14342         prepare_cmp_insn and emit_cmp_and_jump_insn_1, remove obsolete
14343         assertion.
14344         (emit_conditional_move, emit_conditional_add): Inline what's needed
14345         of compare_from_rtx, using new prepare_cmp_insn for the rest.
14346         (init_optabs): Init cmp_optab with UNKNOWN, cbranch_optab
14347         with COMPARE.  Move cmov_optab and cstore_optab above
14348         with cbranch_optab, move cmp_optab down with ucmp_optab,
14349         remove tst_otpab.  Do not initialize trap_rtx.
14350         (gen_cond_trap): Do it here.  Use ctrap_optab.  Test predicate
14351         for trap code.  Do not check HAVE_conditional_trap.  Use
14352         prepare_cmp_insn.  Accept no predicate for operand 3.
14353         * optabs.h (OTI_cmp): Mark as used only for libcalls.
14354         (OTI_ctrap, ctrap_optab): New.
14355         (tst_optab): Delete.
14356         (bcc_gen_fctn, setcc_gen_code, emit_cmp_insn): Delete.
14357         * ifcvt.c (find_if_header): Replace HAVE_conditional_trap
14358         with lookup of ctrap_optab.
14359         * genopinit.c (cmp_optab, tst_optab, bcc_gen_fctn, setcc_gen_code):
14360         Delete.
14361         (ctrap_optab): New.
14362
14363         * combine.c (combine_simplify_rtx, simplify_set): Do not
14364         special case comparing against zero for cc0 machines.
14365         * simplify-rtx.c (simplify_binary_operation_1): Never remove
14366         COMPARE on cc0 machines.
14367         (simplify_relational_operation): Return a new expression when
14368         a COMPARE could be removed.
14369         * final.c (final_scan_insn): Compare cc_status values
14370         against LHS of a (compare FOO (const_int 0)) cc0 source.
14371         Also check if cc_status.value is the full compare.
14372
14373         * doc/md.texi (bCC, sCC, tstMM, cmpMM): Delete.
14374         (cstoreMM4): Document.
14375         (conditional_trap): Document ctrapMM4 instead.
14376         (sync_compare_and_swapMM): Refer to cbranchcc4.
14377         (Dependent Patterns): Eliminate obsolete information referring to
14378         the old jump optimization phase.
14379         (Canonicalization): Include cbranchcc4 case, omit canonicalization
14380         of compares with 0 on cc0 machines.
14381         (Jump Patterns): Refer to MODE_CC jump patterns preferably,
14382         avoiding references to cc0.  Remove text about storing operands
14383         in cmpMM.
14384         * doc/tm.texi (Condition Codes): Include blurb on different
14385         condition code representations, separate into subsections for
14386         CC0, MODE_CC and conditional execution.
14387
14388         * config/alpha/alpha-protos.h (alpha_emit_conditional_branch,
14389         alpha_emit_setcc): Accept operands and a machine mode.
14390         * config/alpha/alpha.c (alpha_emit_conditional_branch):
14391         Get code/op0/op1 from operands, use machine mode argument
14392         instead of alpha_compare.fp_p.  Emit the branch here.
14393         (alpha_emit_setcc): Likewise, and return boolean.
14394         (alpha_emit_conditional_move): Likewise.  Assert that
14395         cmp_op_mode == cmp_mode, and simplify accordingly.
14396         * config/alpha/alpha.h (struct alpha_compare, alpha_compare): Delete.
14397         * config/alpha/alpha.md (cmpdf, cmptf, cmpdi, bCC, sCC): Delete.
14398         (cbranchdf4, cbranchtf4, cbranchdi4, cstoredf4, cstoretf4,cstoredi4):
14399         Delete.
14400         (stack probe test): Use cbranchdi4.
14401         * config/alpha/predicates.md (alpha_cbranch_operator): New.
14402
14403         * config/arc/arc.c (gen_compare_reg): Do not emit cmp.
14404         * config/arc/arc.h (movsicc, movsfcc): Use it.
14405         (movdicc, *movdicc_insn, movdfcc, *movdfcc_insn): Remove.
14406         (cbranchsi4, cstoresi4): New.
14407         (cmpsi, bCC and sCC expanders): Remove.
14408
14409         * config/arm/arm.c (arm_compare_op0, arm_compare_op1): Delete.
14410         * config/arm/arm.h (arm_compare_op0, arm_compare_op1): Delete.
14411         * config/arm/predicates.md (arm_comparison_operator): Only include
14412         floating-point operators if there is a hardware floating-point unit.
14413         * config/arm/arm.md (cbranchsi4, cstoresi4): Enable for TARGET_32BIT,
14414         deferring to cbranch_cc and cstore_cc respectively.
14415         (cbranchsf4, cbranchdf4, cbranchdi4, cstoresf4, cstoredf4, cstoredi4,
14416         cbranch_cc, cstore_cc): New.
14417         (movsicc, movsfcc, movdfcc): Do not use arm_compare_op0 and
14418         arm_compare_op1.
14419         (bCC, sCC, cmpsi, cmpsf, cmpdf, cmpdi): Delete.
14420
14421         * config/avr/avr-protos.h (out_tstsi, out_tsthi): Adjust prototype.
14422         * config/avr/avr.c (out_tstsi, out_tsthi): Get the tested operand
14423         as an argument.
14424         (adjust_insn_length): Adjust calls.
14425         (avr_reorg): Handle (compare (foo) (const_int 0)).
14426         * config/avr/avr.md (tstqi, tsthi, tstsi): Remove.
14427         (*negated_tstqi, *negated_tsthi, *negated_tstsi): Unmacroize.
14428         (*reversed_tsthi, *reversed_tstsi): Add a scratch for simplicity.
14429         (cmpqi, cmphi, cmpsi): Prepend asterisk, fuse tst[qhs]i here.
14430         (bCC): Remove.
14431         (cbranchqi4, cbranchhi4, cbranchsi4): New.
14432         (tst -> sbrc/sbrs peephole2, cpse peephole): Wrap RHS with COMPARE.
14433
14434         * config/bfin/bfin.md (cmpbi, cmpsi, bCC, sCC): Delete.
14435         (cbranchsi4, cstorebi4, cstoresi4): New.
14436         (movbisi): This insn is duplicate, split it to zero_extend.
14437         * config/bfin/bfin.c (bfin_compare_op0, bfin_compare_op1): Delete
14438         (bfin_gen_compare): Do not use them.  Emit VOIDmode SET, not BImode.
14439         (bfin_optimize_loop): Use cbranch expander.
14440         * config/bfin/bfin.h (bfin_compare_op0, bfin_compare_op1): Delete.
14441         * config/bfin/predicates.md (bfin_cbranch_operator): Rename to...
14442         (bfin_bimode_comparison_operator): ... this.
14443         (bfin_direct_comparison_operator): New.
14444
14445         * config/cris/cris.c (cris_normal_notice_update_cc): Look
14446         inside (compare FOO (const_int 0)).
14447         (cris_rtx_costs): Handle ZERO_EXTRACT.
14448         * config/cris/cris.md (tstdi, tst<mode>, cmpdi): Delete.
14449         (*tstdi_non_v32): Fold in *cmpdi_non_v32.
14450         (*tstdi_v32): Delete.
14451         (*cmpdi_non_v32): Add M alternative for operand 1.
14452         (cmpsi, cmp<mode>): Make private.
14453         (*tstsi, *tst<mode>_cmp, *tst<mode>_non_cmp, *btst): Wrap LHS
14454         with COMPARE.
14455         (cbranch<mode>4, cbranchdi4, cstore<mode>4): New.
14456
14457         * config/crx/crx.md (cstore<mode>4, cbranchcc4): New.
14458         (cmp<mode>, bCOND_internal, b<code>, s<code>): Delete.
14459         (cbranch<mode>4, sCOND_internal): Use ordered_comparison_operator.
14460         (cc_reg_operand): New.
14461         (any_cond): Delete.
14462         * config/crx/crx.c (crx_compare_op0, crx_compare_op1,
14463         crx_expand_compare, crx_expand_branch, crx_expand_scond): Delete.
14464         * config/crx/crx.h (crx_compare_op0, crx_compare_op1): Delete.
14465         * config/crx/crx-protos.h (crx_expand_compare, crx_expand_branch,
14466         crx_expand_scond): Delete.
14467
14468         * config/fr30/fr30.md (cmp<mode>, bCC): Delete.
14469         (cbranchsi4): New.
14470         * config/fr30/fr30.c (fr30_compare_op0, fr30_compare_op1): Delete
14471         * config/fr30/fr30.h (fr30_compare_op0, fr30_compare_op1): Delete.
14472
14473         * config/frv/frv.md (cbranchsi4, cbranchsf4, cbranchdf4,
14474         cstoresi4, cstoresf4, cstoredf4): New.
14475         (cmpdi, cmpsi, cmpsf, cmpdf, bCC, sCC): Remove.
14476         * config/frv/frv-protos.h (frv_emit_cbranch, frv_emit_scc):
14477         Receive the entire operands array.
14478         * config/frv/frv.h (frv_compare_op0, frv_compare_op1): Delete.
14479         * config/frv/frv.c (frv_compare_op0, frv_compare_op1): Delete.
14480         * config/frv/frv-protos.h (frv_emit_cbranch, frv_emit_scc):
14481         Get test/op0/op1 from the operands array.
14482         (frv_emit_cond_move): Get test/op0/op1 from the test_rtx.
14483
14484         * config/h8300/h8300-protos.h (h8300_expand_branch): Accept operands.
14485         (h8300_expand_store): New.
14486         * config/h8300/h8300.c (h8300_rtx_costs): Handle (compare FOO
14487         (const_int 0)).
14488         (h8300_expand_branch): Emit compare here.  Adjust for new arguments.
14489         (h8300_expand_store): New.
14490         * config/h8300/h8300.md (btst combine patterns): Wrap with COMPARE
14491         or do not try to produce (set (cc0) REG).
14492         (peepholes): Wrap arguments with COMPARE.  Add a peephole to
14493         change a compare into a move to a scratch register.  Disable some
14494         peepholes when comparing with zero.
14495         (tstsi, tsthi, tstsi, cmpqi): Make private.
14496         (cmphi): Delete.
14497         (bCC, sCC): Delete.
14498         (cbranchqi4, cbranchhi4, cbranchsi4, cstoreqi4, cstorehi4,
14499         cstoresi4): New.
14500
14501         * config/i386/i386.c (ix86_expand_int_movcc, ix86_expand_int_addcc,
14502         ix86_expand_fp_movcc): Set ix86_compare_op0 and ix86_compare_op1.
14503         (ix86_emit_i387_log1p): Use gen_cbranchxf4.
14504         (ix86_emit_i387_log1p): Use cbranchxf2.
14505         (ix86_expand_setcc): Return void.
14506         * config/i386/i386-protos.h (ix86_expand_setcc): Return void.
14507         * config/i386/i386.md (cmpti, cmpdi, cmpsi, cmphi, cmpqi, cmpxf,
14508         cmp<MODEF>, cmpcc): Remove.
14509         (cbranchti4, cbranchdi4, cbranchsi4, cbranchhi4, cbranchqi4,
14510         cbranchxf4, cbranch<MODEF>4, cbranchcc4, cstoredi4, cstoresi4,
14511         cstorehi4, cstoreqi4, cstorexf4, cstore<MODEF>4, cstorecc): New.
14512         (sCC and bCC expanders): Remove.
14513         (stack_protect_test): Use cbranchcc4.
14514
14515         * config/ia64/ia64-protos.h (ia64_compare_op0, ia64_compare_op1):
14516         Delete.
14517         (ia64_expand_compare): Accept three rtx by reference and return void.
14518         * config/ia64/ia64.c (ia64_compare_op0, ia64_compare_op1): Delete.
14519         (ia64_expand_compare): Replace op0/op1 with *op0/*op1.  Get code
14520         from *expr.  Update *expr with the BImode comparison to do.
14521         * config/ia64/ia64.md (cmpbi, cmpsi, cmpdi, cmpsf, cmpdf, cmpxf,
14522         cmptf, bCC, sCC, conditional_trap): Delete.
14523         (cbranchbi4, cbranchsi4, cbranchdi4, cbranchsf4, cbranchdf4,
14524         cbranchxf4, cbranchtf4, cstorebi4, cstoresi4, cstoredi4, cstoresf4,
14525         cstoredf4, cstorexf4, cstoretf4, ctrapbi4, ctrapsi4, ctrapdi4,
14526         ctrapsf4, ctrapdf4, ctrapxf4, ctraptf4): New.
14527         * config/ia64/predicates.md (ia64_cbranch_operator): New.
14528
14529         * config/iq2000/iq2000-protos.h (gen_conditional_branch): Change
14530         type of last argument.
14531         * config/iq2000/iq2000.c (branch_cmp, branch_type): Remove.
14532         (gen_conditional_branch): Get code/cmp0/cmp1 from operands,
14533         use machine mode argument instead of branch_type.  Remove dead
14534         code for floating-point comparisons.
14535         * config/iq2000/iq2000.h (branch_cmp, branch_type): Remove.
14536         * config/iq2000/iq2000.md (cmpsi, cmpdi, cmpsf, cmpdf, tstsi, bCC):
14537         Remove.
14538         (cbranchsi4, cstoresi4): New.
14539         * config/iq2000/predicates.md (reg_or_const_operand): New.
14540
14541         * config/m32c/m32c.md (cbranch splitter): Use match_op_dup.
14542         * config/m32c/m32c.md (any_cond, gl_cond): Delete.
14543         (b<code>_op): Rewrite to...
14544         (bcc_op): ... this, using match_operator.
14545         (s<code>_op): Rewrite to...
14546         (scc_op): ... this, using match_operator.
14547         (s<code>_24_op): Rewrite to...
14548         (scc_op_24): ... this, using match_operator.
14549         (s<code>_<mode>): Rewrite to...
14550         (cstore<mode>4): ... this, using match_operator.
14551         (s<code>_<mode>_24): Rewrite to...
14552         (cstore<mode>4_24): ... this, using match_operator.
14553         * config/m32c/m32c-protos.h (m32c_cmp_flg_0, m32c_pend_compare,
14554         m32c_unpend_compare, m32c_expand_scc): Delete.
14555         * config/m32c/m32c.c (compare_op0, compare_op1, m32c_cmp_flg_0,
14556         m32c_pend_compare, m32c_unpend_compare, m32c_expand_scc): Delete.
14557         (m32c_expand_movcc): Change NE to EQ if necessary.
14558         (m32c_init_libfuncs): Modify cstore optab instead of setcc_gen_code.
14559
14560         * config/m32r/m32r-protos.h (gen_cond_store): New.
14561         * config/m32r/m32r.c (m32r_compare_op0, m32r_compare_op1): Delete.
14562         (gen_cond_store): New, from sCC patterns.
14563         (m32r_expand_block_move): Use cbranchsi4.
14564         * config/m32r/m32r.h (m32r_compare_op0, m32r_compare_op1): Delete.
14565         * config/m32r/m32r.md (cmpsi, bCC, sCC): Delete.
14566         (cbranchsi4, cstoresi4): New.
14567
14568         * config/m68hc11/m68hc11.c (m68hc11_compare_op0, m68hc11_compare_op1):
14569         Delete.
14570         (m68hc11_rtx_costs_1, m68hc11_rtx_costs): Handle ZERO_EXTRACT.
14571         (m68hc11_notice_update_cc): Look into a compare with 0.
14572         * config/m68hc11/m68hc11.h (m68hc11_compare_op0, m68hc11_compare_op1):
14573         Delete.
14574         * config/m68hc11/m68hc11.md (tstsi, tsthi, tstqi, cmpsi,
14575         cmphi, cmpqi, bCC): Delete.
14576         (cbranchsi4, cbranchhi4, cbranchqi4): New.
14577         (tstqi_1, tstqi_z_used, tstqi_1, bitcmpqi, bitcmpqi_z_used,
14578         bitcmpqi_12, bitcmphi, various splits and peephole2s): Wrap cc0<-reg
14579         sets with COMPARE.
14580
14581         * config/m68k/predicates.md (m68k_cstore_comparison_operator,
14582         const0_operand, const1_operand, m68k_subword_comparison_operand): New.
14583         * config/m68k/constraints.md (H): New.
14584         * config/m68k/m68k.md (tstdi): Remove define_expand, use name for
14585         the define_insn below.
14586         (tstsi, tsthi, tst<FP:mode>, cmphi, cmpqi, cmp<FP:mode>): Delete.
14587         (*tstsi_internal_68020_cf, *tstsi_internal, *tsthi_internal,
14588         *tstqi_internal, tst<mode>_6881, tst<mode>_cf, many unnamed
14589         patterns): Wrap RHS with COMPARE.
14590         (tst<FP>_68881, tst<FP>_cf): Use const0_operand.
14591         (*cmpdi_internal): Name this pattern.
14592         (cmpdi): Change to define_insn.
14593         (cbranchdi4, cstoredi4, cbranchsi4, cstoresi4, cbranchhi4, cstorehi4,
14594         cbranchqi4, cstoreqi4, cbranch<FP:mode>4, cstore<FP:mode>4): New.
14595         (scc0_di, scc0_di_5200, scc_di): Use the ordered_comparison_operator
14596         predicate.
14597         (seq, sne, sgt, sgtu, slt, sltu, sge, sgeu, sle, sleu, sordered,
14598         sunordered, suneq, sunge, sungt, sunle, sunlt, sltgt): Delete
14599         (conditional_trap): Change to...
14600         (ctrapdi4, ctrapsi4, ctraphi4, ctrapqi4): ... these.
14601         (*conditional_trap): Use the ordered_comparison_operator and
14602         const1_operand predicates.
14603         * config/m68k/m68k.c (m68k_last_compare_had_fp_operands): Delete.
14604         (m68k_expand_prologue): Use ctrapsi4 instead of cmpsi+conditional_trap.
14605         (m68k_rtx_costs): Look for ZERO_EXTRACT in a COMPARE.
14606         * config/m68k/m68k.h (m68k_last_compare_had_fp_operands): Delete.
14607
14608         * config/mcore/mcore-protos.h (arch_compare_op0, arch_compare_op1,
14609         mcore_modify_comparison, mcore_gen_compare_reg): Remove.
14610         (mcore_gen_compare): New.
14611         * config/mcore/mcore.c (arch_compare_op0, arch_compare_op1): Delete.
14612         (mcore_modify_comparison, mcore_gen_compare_reg): Fold into...
14613         (mcore_gen_compare): ... this.
14614         * config/mcore/mcore.md (cmpsi, bCC, sCC): Remove.
14615         (cbranchsi4, cstoresi4): New, using mcore_gen_compare.
14616         (stack probe pattern): Use cbranchsi4.
14617
14618         * config/mips/predicates.md (mips_cstore_operator): New.
14619         * config/mips/mips-ps-3d.md (movv2sfcc): Do not use cmp_operands.
14620         * config/mips/mips.md (any_cond): Delete.
14621         (conditional_trap): Rename to ctrap<GPR:mode>4.  Adjust predicates,
14622         always succeed.
14623         (fixuns_truncdfsi2, fixuns_truncdfdi2, fixuns_truncsfsi2,
14624         fixuns_truncsfdi2): Use cbranch patterns.
14625         (cmp<GPR:mode>, cmp<SCALARF:mode>): Delete.
14626         (b<code>): Change to cbranch<GPR:mode>4 and cbranch<SCALARF:mode>4.
14627         Adjust call to mips_expand_conditional_branch.
14628         (seq, sne, slt<u>, sle<u>, sgt<u>, sge<u>): Change to
14629         cstore<GPR:mode>4.
14630         * config/mips/mips-protos.h (mips_expand_conditional_branch,
14631         mips_expand_scc, mips_expand_conditional_trap): Adjust prototypes.
14632         * config/mips/mips.c (cmp_operands): Delete.
14633         (mips_emit_compare): Get comparison operands from *op0/*op1.
14634         (mips_expand_scc): Get code/op0/op1/target from operands.  Assert
14635         that it succeeds.  Use op0/op1 instead of cmp_operands.
14636         (mips_expand_conditional_branch, mips_expand_conditional_move,
14637         mips_expand_conditional_trap): Likewise.
14638         (mips_block_move_loop): Use cbranch patterns.
14639         * config/mips/mips.h (cmp_operands): Delete.
14640
14641         * config/mmix/mmix.c (mmix_valid_comparison): Delete.
14642         (mmix_gen_compare_reg): Just return a register in the right CC mode.
14643         * config/mmix/mmix.h (mmix_compare_op0, mmix_compare_op1): New.
14644         * config/mmix/mmix.md (cmpdi, cmpdf): Remove.
14645         (*cmpcc_folded): Rename to...
14646         (*cmpdi_folded): this.
14647         (*cmpcc): Rename to...
14648         (*cmps): ... this.
14649         (movdfcc, movdicc): Adjust for new semantics of mmix_gen_compare_reg.
14650         (bCC): Remove.
14651         (cbranchdi4): New.
14652         (cbranchdf4): New.  Handle invalid comparisons here.
14653         * config/mmix/predicates.md (float_comparison_operator): New.
14654
14655         * config/mn10300/mn10300.c (mn10300_rtx_costs): Consider 0 and
14656         zero_extract to be cheap in (compare (zero_extract) (const_int 0).
14657         * config/mn10300/mn10300.md (tst): Delete.
14658         (*tst_extqisi_am33, *tst_extqisi, *tst_exthisi_am33, *tst_exthisi):
14659         Name these patterns and wrap RHS in a compare.
14660         (*cmpsi): Make this pattern private.  Include tst.
14661         (*cmpsf): Make this pattern private.
14662         (and and zero_extract cc0 set): Wrap RHS in a COMPARE.
14663         (compare with zero peepholes): Likewise.
14664         (bCC): Remove.
14665         (cbranchsi4, cbranchsf4): New.
14666         (casesi): Use cbranchsi4.
14667
14668         * config/pa/pa.c (hppa_compare_op0, hppa_compare_op1,
14669         hppa_branch_type): Delete.
14670         (return_addr_rtx): Use cbranchsi4.
14671         (emit_bcond_fp): Accept all operands.  Replace CODE with NE.
14672         Emit CCFPmode comparison here.
14673         (gen_cmp_fp): Delete, now part of emit_bcond_fp.
14674         * config/pa/pa.h (enum cmp_type, hppa_compare_op0, hppa_compare_op1,
14675         hppa_branch_type): Delete.
14676         * config/pa/pa.md (cmpdi, cmpsi, cmpsf, cmpdf, sCC, bCC): Delete.
14677         (movsicc, movdicc): Remove references to hppa_compare_op0,
14678         hppa_compare_op1 and compare_from_rtx.
14679         (cbranchdi4, cbranchsi4, cbranchsf4, cbranchdf4, cstoresi4): New.
14680         (casesi): Use cbranchsi4.
14681
14682         * config/pdp11/pdp11-protos.h (output_jump): Change prototype.
14683         * config/pdp11/pdp11.c (output_jump): Embed opcodes here.
14684         * config/pdp11/pdp11.md (register_or_const0_operand): New.
14685         (cmpdf, cmphi, cmpqi): Make private.  Add tst alternatives.
14686         (cmpsi, tstsi, tstdf, tsthi, tstqi): Delete.
14687         (bCC): Delete.
14688         (cbranchdf4, cbranchhi4, cbranchqi4): New.
14689         (*branch, *branch_inverted): New.
14690
14691         * config/picochip/picochip.md (cbranchhi4): Use
14692         ordered_comparison_operator.
14693         (cmphi, bCC): Remove.
14694
14695         * config/rs6000/predicates.md (rs6000_cbranch_operator): New.
14696         (trap_comparison_operator): Delete.
14697         * config/rs6000/rs6000-protos.h (rs6000_emit_sCOND,
14698         rs6000_emit_cbranch): Accept mode and operands.
14699         * config/rs6000/rs6000.c (rs6000_compare_op0, rs6000_compare_op1,
14700         rs6000_compare_fp_p): Delete.
14701         (rs6000_generate_compare): Accept mode and comparison.  Extract code
14702         and op0/op1 from there.  Replace references to rs6000_compare_op0
14703         and rs6000_compare_op1.
14704         (rs6000_emit_sCOND): Adjust call to rs6000_generate_compare and
14705         extract result from passed operands.
14706         (rs6000_emit_cbranch): Adjust call to rs6000_generate_compare and
14707         extract loc from passed operands.
14708         (rs6000_emit_cmove): Likewise.
14709         * config/rs6000/rs6000.h (rs6000_compare_op0, rs6000_compare_op1,
14710         rs6000_compare_fp_p): Delete.
14711         * config/rs6000/rs6000.md (cmp<GPR>, cmp<FP>, bCC, sCC): Delete.
14712         (cbranch<GPR>4, cbranch<FP>4): New.
14713         (cstore<mode>4): New.  Consolidate here all choices about when to use
14714         portable or specialized sCC sequences.
14715         (stack_protect_test): Use cbranchsi4.
14716         (conditional_trap): Replace with ctrap<GPR>4.
14717         (conditional trap insn): Replace trap_comparison_operator with
14718         ordered_comparison_operator.
14719
14720         * config/s390/s390.c (s390_compare_op0, s390_compare_op1): Delete.
14721         (s390_emit_prologue): Use ctrap.
14722         * config/s390/s390.h (s390_compare_op0, s390_compare_op1): Delete.
14723         * config/s390/predicates.md (s390_eqne_operator, s390_scond_operator):
14724         New predicates replacing...
14725         * config/s390/s390.md (COMPARE, SCOND): ... these iterators.
14726         (cmp<GPR>, cmp<FP>, cmpcc): Delete.
14727         (trunc patterns): Use emit_cmp_and_jump_insns instead of cmp/branch.
14728         (add<mode>cc): Do not use s390_compare_op0/op1.
14729         (s<code>): Change to...
14730         (cstore<mode>4): ... this. Do not use s390_compare_op0/op1.
14731         (seq): Change to...
14732         (cstorecc4): ... this.  Handle EQ or NE equally.
14733         (*sne): Un-privatize for use in cstorecc4.
14734         (b<code>): Change to...
14735         (cbranch<GPR>4, cbranch<FP>4, cbranchcc4): ... these.
14736         (conditional_trap): Replace with...
14737         (ctrap<GPR>4, ctrap<FP>4): ... these.
14738         (stack_protect): Use cbranchcc4.
14739
14740         * config/score/score-conv.h (cmp_op0, cmp_op1): Delete.
14741         * config/score/score-protos.h (score_gen_cmp): Delete.
14742         * config/score/score.c (cmp_op0, cmp_op1, score_gen_cmp): Delete.
14743         (score_block_move-loop): Use cbranchsi4.
14744         * config/score/score.md (cbranchsi4): New.
14745         (cmpsi, bCC): Delete.
14746         * config/score/score3.c (cmp_op0, cmp_op1, score3_gen_cmp): Delete.
14747         (score3_movsicc): Use ops[1] operands instead of cmp_op0/cmp_op1.
14748         * config/score/score7.c (cmp_op0, cmp_op1, score7_gen_cmp): Delete.
14749         (score7_movsicc): Use ops[1] operands instead of cmp_op0/cmp_op1.
14750         * config/score/score3.h (score3_gen_cmp): Delete.
14751         * config/score/score7.h (score7_gen_cmp): Delete.
14752
14753         * config/sh/sh-protos.h (prepare_scc_operands): Rename to...
14754         (sh_emit_scc_to_t): ... this.  Return void.
14755         (from_compare): Rename to...
14756         (sh_emit_compare_and_branch): ... this.
14757         (sh_emit_compare_and_set): New.
14758         (sh_expand_t_scc): Accept operands.
14759         * config/sh/predicates.md (sh_float_comparison_operator): New.
14760         * config/sh/sh.c (sh_compare_op0, sh_compare_op1): Delete.
14761         (prepare_scc_operands): Rename to...
14762         (sh_emit_scc_to_t): ... this.  Return void.  Get op0/op1 from
14763         arguments.
14764         (sh_emit_cheap_store_flag): New.
14765         (sh_emit_set_t_insn): New.
14766         (from_compare): Rename to...
14767         (sh_emit_compare_and_branch): ... this.  Accept mode.  Rewrite
14768         handling of TARGET_SH2E floating point to avoid recursive call.
14769         Generate branch here.
14770         (sh_emit_compare_and_set): New.
14771         (sh_expand_t_scc): Get op0/op1 from arguments.
14772         (sh_emit_cheap_store_flag): New.
14773         * config/sh/sh.md (cbranchdi4, cbranchsi4): Include -mno-cbranchdi
14774         cases.
14775         (cbranchdi4_i): Use an "I08" constraint instead of an "i" constraint.
14776         (cmpsi, cmpdi, cmpsf, cmpdf): Delete.
14777         (movsicc, movdicc): Do nothing when it recreated operands from
14778         sh_compare_*. Use sh_emit_cheap_store_flag.  Adjust call to
14779         prepare_scc_operands (now sh_emit_scc_to_t).
14780         (udivdi3): Use cstoresi4.
14781         (beq_media, bne_media, bge_media, bgtu_media, bgeu_media, beq,
14782         bne, bgt, blt, ble, bge, bgtu, bltu, bgeu, bleu, bunordered): Delete.
14783         (cbranchint4_media, cbranchfp4_media): New.
14784         (casesi): Use cbranchdi4.
14785         (seq, slt, sle, sgt, sge, sgtu, sltu, sgeu, sne, sleu, sunordered):
14786         Delete.
14787         (cstore4_media, cstoresi4, cstoredi4, cstoresf4, cstoredf4): New.
14788         (movnegt): Remove second operand.
14789         (cbranchsf4, cbranchdf4): New.
14790         (stack_protect): Use cbranchdi4/cbranchsi4.
14791
14792         * config/sparc/sparc.c (sparc_compare_op0, sparc_compare_op1): Delete.
14793         (gen_compare_reg): Accept comparison, extract part of it to...
14794         (gen_compare_reg_1): ... this.
14795         (gen_compare_operator): Delete.
14796         (gen_v9_scc): Accept separate destination, comparison code and arms.
14797         Do not use sparc_compare_op0/sparc_compare_op1.
14798         (emit_scc_insn, emit_conditional_branch_insn): New.
14799         (emit_v9_brxx): Make static.  Remove useless assertion.
14800         (sparc_emit_float_lib_cmp): Return RTL instead of calling
14801         emit_cmp_insn.
14802         (sparc_expand_compare_and_swap_12): Use gen_compare_reg_1+cbranchcc4.
14803         * config/sparc/sparc-protos.h (gen_compare_reg,
14804         sparc_emit_float_lib_cmp): Adjust prototype.
14805         (emit_scc_insn, emit_conditional_branch_insn): New.
14806         (gen_v9_scc, emit_v9_brxx_insn, gen_compare_operator): Delete.
14807         * config/sparc/sparc.h (sparc_compare_op0, sparc_compare_op1): Delete.
14808         * config/sparc/sparc.md (P, I, F, V32, V32I, V64, V64I): Move all
14809         iterators to the top.
14810         (cmpsi, cmpdi, cmpsf, cmpdf, cmptf, seqsi_special_extend,
14811         snesi_special_extend, sCC, bCC, seqdi_special_trunc,
14812         snedi_special_trunc): Delete.
14813         (seqdi_special, snedi_special): Use expansion of seqdi_special_trunc
14814         and snedi_special_trunc.
14815         (cstoresi4, cstoredi4, cstore<F:mode>4, cbranchcc4, cbranchsi4,
14816         cbranchdi4, cbranch<F:mode>4): New.
14817         (mov<I:mode>cc, mov<F:mode>cc): Handle sparc_emit_float_lib_cmp
14818         here.  Use gen_compare_reg instead of gen_compare_operator.
14819         (conditional_trap): Replace with...
14820         (ctrapsi4, ctrapdi4): ... this.
14821         (stack_protect_test): Use cbranchcc4.
14822
14823         * config/spu/spu-protos.h (spu_emit_branch_or_set): Change second
14824         argument to rtx.
14825         * config/spu/spu.c (spu_compare_op0, spu_compare_op1): Remove.
14826         (spu_emit_branch_or_set): Get code/op0/op1 from second argument.
14827         Change spu_compare_op0/op1 to op0/op1 throughout.  Get target
14828         from operands[0] or operands[3] depending on is_set.
14829         * config/spu/spu.h (spu_compare_op0, spu_compare_op1): Remove.
14830         * config/spu/spu.md (cmp<mode:VQHSI>, cmp<mode:DTI>, cmp<mode:VSF>,
14831         cmpdf, bCC), sCC: Remove.
14832         (cbranch<mode:VQHSI>4, cbranch<mode:DTI>, cbranch<mode:VSF>4,
14833         cbranchdf4, cstore<mode:VQHSI>4, cstore<mode:DTI>, cstore<mode:VSF>4,
14834         cstoredf4): New.
14835         (mov<mode>cc): Accept ordered_comparison_operator, adjust call to
14836         spu_emit_branch_or_set.
14837
14838         * config/stormy16/stormy16-protos.h (xstormy16_emit_cbranch):
14839         Add two arguments.
14840         * config/stormy16/stormy16.h (xstormy16_compare_op0,
14841         xstormy16_compare_op1): Delete.
14842         * config/stormy16/stormy16.c (xstormy16_compare_op0,
14843         xstormy16_compare_op1): Delete.
14844         (xstormy16_emit_cbranch): Get op0/op1 from the new arguments.
14845         Adjust calls.
14846         * config/stormy16/stormy16.md (cbranchsi4, cbranchhi4): New.
14847         (cmphi, cmpsi, bCC): Remove.
14848
14849         * config/v850/v850.md (tstsi, cmpsi): Fold into...
14850         (*cmpsi): ... this one.
14851         (cbranchsi4, cstoresi4): New.
14852         (bCC expanders): Delete.
14853         (sCC insns): Fold into...
14854         (*setcc): ... this one.
14855         (casesi): Do not use gen_cmpsi and gen_bgtu.
14856         (various splits): Wrap "naked" RHS of a cc0 set with COMPARE.
14857         (movsicc): Simplify.
14858         * config/v850/v850.c (v850_rtx_costs): Handle ZERO_EXTRACT in COMPARE.
14859
14860         * config/vax/vax-protos.h (cond_name): New.
14861         (vax_output_conditional_branch): Remove.
14862         * config/vax/vax.c (cond_name): New.
14863         (vax_output_conditional_branch): Remove.
14864         * config/vax/vax.h (PRINT_OPERAND): Dispatch %c to cond_name.
14865         * config/vax/vax.md (tst<VAXint>, tst<VAXfp>): Remove.
14866         (cmp<VAXint>, cmp<VAXfp>): Privatize.  Add constraints for tst.
14867         (bit<VAXint>): Wrap source with (compare).
14868         (b<code> and following unnamed pattern): Rename to *branch and
14869         *branch_reversed.  Change macroization to match_operator.
14870         (cbranch<VAXint>4, cbranch<VAXfp>4): New.
14871
14872         * config/xtensa/predicates.md (xtensa_cstoresi_operator): New.
14873         * config/xtensa/xtensa-protos.h (xtensa_expand_conditional_branch):
14874         Change last argument to machine_mode.
14875         (xtensa_expand_scc): Add machine_mode argument.
14876         * config/xtensa/xtensa.c (branch_cmp, branch_type): Remove.
14877         (gen_conditional_move, xtensa_expand_conditional_branch,
14878         xtensa_expand_scc, xtensa_expand_conditional_move): Use mode
14879         instead of branch_type, fetch cmp0/cmp1/test_code from operands[].
14880         Adjust operand numbers.
14881         * config/xtensa/xtensa.h (enum cmp_type, branch_cmp, branch_type):
14882         Delete.
14883         * config/xtensa/xtensa.md (any_cond, any_scc): Delete.
14884         (cmpsi, cmpsf, b<code>, s<code>): Delete.
14885         (cbranchsi4, cbranchsf4, cstoresi4, cstoresf4): New.
14886
14887 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
14888
14889         * optabs.c (prepare_cmp_insn): Temporarily disable test that
14890         causes spurious differences between trunk and cond-optab branch.
14891
14892 2009-05-12  Alexandre Oliva  <aoliva@redhat.com>
14893
14894         PR target/37137
14895         * doc/install.texi (STAGE1_TFLAGS, BUILD_CONFIG): Document.
14896
14897 2009-05-12  Alexandre Oliva  <aoliva@redhat.com>
14898
14899         * tree.c (iterative_hash_pointer): Delete.
14900         (iterative_hash_expr): Short-circuit handling of NULL pointer.
14901         Hash UIDs and versions of SSA names.  Don't special-case built-in
14902         function declarations.
14903
14904 2009-05-11  Ian Lance Taylor  <iant@google.com>
14905
14906         PR bootstrap/40103
14907         * graphite.c: Force -Wc++-compat to only be a warning before
14908         #including "cloog/cloog.h".
14909
14910 2009-05-11  Martin Jambor  <mjambor@suse.cz>
14911
14912         * ipa-cp.c (ipcp_cloning_candidate_p): Add missing return false.
14913
14914 2009-05-11  Jan Hubicka  <jh@suse.cz>
14915
14916         * tree-ssa-loop-ivcanon.c: Include target.h
14917         (struct loop_size): new structure.
14918         (constant_after_peeling): New predicate.
14919         (tree_estimate_loop_size): New function.
14920         (estimated_unrolled_size): Rewrite for new estimates.
14921         (try_unroll_loop_completely): Use new estimates.
14922         * Makefile.in (tree-ssa-loop-ivcanon.o): Add dependenc on target.h
14923
14924 2009-05-11  Andrew Pinski  <andrew_pinski@playstation.sony.com>
14925
14926         * config/spu/spu-c.c (spu_categorize_keyword): Update for recent
14927         libcpp interface change.
14928         (spu_macro_to_expand): Likewise.
14929
14930 2009-05-11  Paolo Bonzini  <bonzini@gnu.org>
14931
14932         PR tree-optimization/40026
14933         * gimplify.c (gimplify_init_constructor): Change initial conditional
14934         to assertion.  Rewrite TREE_OPERAND (*expr_p, 1) after
14935         optimize_compound_literals_in_ctor.
14936
14937 2009-05-11  Nathan Sidwell  <nathan@codesourcery.com>
14938
14939         * config/m68k/m68k-devices.def (52274, 52277, 5301x, 5225x, 51xx):
14940         New devices.
14941         * doc/invoke.texi (M680x0 Options): Document new coldfire cpus.
14942
14943 2009-05-11  H.J. Lu  <hongjiu.lu@intel.com>
14944
14945         * tree-vect-data-refs.c (vect_analyze_group_access): Use
14946         HOST_WIDE_INT for gap.
14947
14948 2009-05-11  Ira Rosen  <irar@il.ibm.com>
14949
14950         PR tree-optimization/40074
14951         * tree-vect-data-refs.c (vect_analyze_group_access): Take gaps into
14952         account in group size and step comparison.
14953
14954 2009-05-11  Richard Guenther  <rguenther@suse.de>
14955
14956         * passes.c (init_optimization_passes): Strip now incorrect comment.
14957         (execute_function_todo): Do not set PROP_alias.
14958         * tree-pass.h (PROP_alias): Remove.
14959         * tree-ssa-structalias.c (pass_build_alias): Do not provide PROP_alias.
14960         * tree-if-conv.c (pass_if_conversion): Do not require PROP_alias.
14961         * tree-nrv.c (pass_return_slot): Likewise.
14962         * tree-object-size.c (pass_object_sizes): Likewise.
14963         * tree-ssa-dom.c (pass_dominator): Likewise.
14964         (pass_phi_only_cprop): Likewise.
14965         * tree-ssa-dse.c (pass_dse): Likewise.
14966         * tree-ssa-phiopt.c (pass_phiopt): Likewise.
14967         (pass_cselim): Likewise.
14968         * tree-ssa-pre.c (pass_pre): Likewise.
14969         (pass_fre): Likewise.
14970         * tree-ssa-reassoc.c (pass_reassoc): Likewise.
14971         * tree-ssa-sink.c (pass_sink_code): Likewise.
14972         * tree-stdarg.c (pass_stdarg): Likewise.
14973         * tree-tailcall.c (pass_tail_calls): Likewise.
14974         * tree-vrp.c (pass_vrp): Likewise.
14975
14976 2009-05-10  Ian Lance Taylor  <iant@google.com>
14977
14978         * basic-block.h (enum profile_status): Break out of struct
14979         control_flow_graph.
14980         * cgraph.h (struct inline_summary): Break out of struct
14981         cgraph_local_info.
14982         * cgraphunit.c (enum cgraph_order_sort_kind): New enum, broken out
14983         of struct cgraph_order_sort.
14984         * combine.c (enum undo_kind): New enum, broken out of struct undo.
14985         * cse.c (struct branch_path): Break out of struct
14986         cse_basic_block_data.
14987         * except.h (enum eh_region_type): Break out of struct eh_region.
14988         * gcc.c (enum add_del): Break out of struct modify_target.
14989         * genrecog.c (enum decision_type): Break out of struct decision_test.
14990         * ggc-page.c (struct ggc_pch_ondisk): Break out of struct
14991         ggc_pch_data.
14992         * matrix-reorg.c (struct free_info): Break out of struct matrix_info.
14993         * regmove.c (enum match_use): New enum, broken out of struct match.
14994         * sched-int.h (enum post_call_group): New enum, broken out of
14995         struct deps.
14996         (struct deps_reg): Break out of struct deps.
14997         * target.h (struct asm_int_op): Break out of struct gcc_target.
14998         * tree-eh.c (struct goto_queue_node): Break out of struct
14999         leh_tf_state.
15000         * tree-inline.h (enum copy_body_cge_which): Break out of
15001         copy_body_data.
15002         * tree-pass.h (enum opt_pass_type): Break out of struct opt_pass.
15003
15004         * c-decl.c (in_struct, struct_types): New static variables.
15005         (pushtag): Add loc parameter.  Change all callers.
15006         (lookup_tag): Add ploc parameter.  Change all callers.
15007         (check_compound_literal_type): New function.
15008         (parser_xref_tag): Add loc parameter.  Change all callers.  If
15009         -Wc++-compat, warn about struct/union/enum types defined within a
15010         struct or union.
15011         (start_struct): Add enclosing_in_struct, enclosing_struct_types,
15012         and loc parameters.  Change all callers.  Change error calls to
15013         error_at, using loc.  For a redefinition, if the location of the
15014         original definition is known, report it.  Set in_struct and
15015         struct_types.  If -Wc++-compat warn if in sizeof, typeof, or alignof.
15016         (finish_struct): Add new parameters enclosing_in_struct and
15017         enclosing_struct_types.  Change all callers.  Set
15018         C_TYPE_DEFINED_IN_STRUCT for all struct/union/enum types defined
15019         in the struct.  If in a struct, add this struct to struct_types.
15020         (start_enum): Add loc parameter.  Change all callers.  Use
15021         error_at for errors, using loc.  For a redefinition, if the
15022         location of the original definition is known, report it.  If in a
15023         struct, add this enum type to struct_types.  If -Wc++-compat warn
15024         if in sizeof, typeof, or alignof.
15025         * c-parser.c (disable_extension_diagnostics): Disable -Wc++-compat.
15026         (enable_extension_diagnostics): Reenable -Wc++-compat if appropriate.
15027         (c_parser_enum_specifier): Get enum location for start_enum.
15028         (c_parser_struct_or_union_specifier): Get struct location for
15029         start_struct.  Save in_struct and struct_types status between
15030         start_struct and finish_struct.
15031         (c_parser_cast_expression): Get location of cast.
15032         (c_parser_alignof_expression): Get location of type.
15033         (c_parser_postfix_expression): Likewise.
15034         (c_parser_postfix_expression_after_paren_type): Add type_loc
15035         parameter.  Change all callers.  Call check_compound_literal_type.
15036         Use type_loc for error about variable size type.
15037         * c-typeck.c (build_external_ref): If -Wc++-compat, warn about a use
15038         of an enum constant from an enum type defined in a struct or union.
15039         (c_cast_expr): Add loc parameter.  Change all callers.  If
15040         -Wc++-compat, warn about defining a type in a cast.
15041         * c-tree.h (C_TYPE_DEFINED_IN_STRUCT): Define.
15042         (start_enum, start_struct, finish_struct): Update declarations.
15043         (parser_xref_tag, c_cast_expr): Update declarations.
15044         (check_compound_literal_type): Declare.
15045
15046 2009-05-11  Ben Elliston  <bje@au.ibm.com>
15047
15048         * config/rs6000/rs6000-c.c (altivec_categorize_keyword): Update
15049         for recent libcpp interface change.
15050         (rs6000_macro_to_expand): Likewise.
15051
15052 2009-05-10  Michael Matz  <matz@suse.de>
15053
15054         PR target/40031
15055         * config/arm/arm.c (require_pic_register): Emit on entry edge,
15056         not at entry of function.
15057
15058 2009-05-10  Richard Guenther  <rguenther@suse.de>
15059
15060         PR tree-optimization/40081
15061         Revert
15062         * tree-sra.c (instantiate_element): Instantiate scalar replacements
15063         using the main variant of the element type.  Do not fiddle with
15064         TREE_THIS_VOLATILE or TREE_SIDE_EFFECTS.
15065
15066         * tree-sra.c (sra_type_can_be_decomposed_p): Do not decompose
15067         structs with volatile fields.
15068
15069 2009-05-10  Jan Hubicka  <jh@suse.cz>
15070
15071         * tree-inline.c (delete_unreachable_blocks_update_callgraph): Declare.
15072         (estimate_move_cost): Assert that it does not get called for
15073         VOID_TYPE_P.
15074         (estimate_num_insns): Skip VOID types in argument handling.
15075         (optimize_inline_calls): Delete unreachable blocks and verify that
15076         callgraph is valid.
15077
15078 2009-05-10  Jan Hubicka  <jh@suse.cz>
15079
15080         * cgraphbuild.c (record_reference): Use cgraph_mark_address_taken_node.
15081         * cgraph.c (cgraph_mark_address_taken_node): New function.
15082         (dump_cgraph_node): Dump new flag.
15083         * cgraph.h (struct cgraph_node): Add address_taken.
15084         (cgraph_mark_address_taken_node): New function.
15085         * ipa.c (cgraph_postorder): Prioritize functions with address taken
15086         since new direct calls can be born.
15087
15088 2009-05-10  Joseph Myers  <joseph@codesourcery.com>
15089
15090         * c-lex.c (c_lex_with_flags): Expect cpp_hashnode in
15091         tok->val.node.node.
15092
15093 2009-05-10  Jan Hubicka  <jh@suse.cz>
15094
15095         PR middle-end/40084
15096         * cgraph.c (cgraph_update_edges_for_call_stmt_node): Take old_call
15097         argument; rewrite.
15098         (cgraph_update_edges_for_call_stmt): Take old_decl argument.
15099         * cgraph.h (cgraph_update_edges_for_call_stmt): Update prototype.
15100         * tree-inline.c (copy_bb): Set frequency correctly.
15101         (fold_marked_statements): Update call to
15102         cgraph_update_edges_for_call_stmt.
15103
15104 2009-05-10  Joseph Myers  <joseph@codesourcery.com>
15105
15106         * config/arc/arc.c (arc_handle_interrupt_attribute): Use %qE for
15107         identifiers in diagnostics.
15108         * config/arm/arm.c (arm_handle_fndecl_attribute,
15109         arm_handle_isr_attribute): Likewise.
15110         * config/avr/avr.c (avr_handle_progmem_attribute,
15111         avr_handle_fndecl_attribute, avr_handle_fntype_attribute): Likewise.
15112         * config/bfin/bfin.c (handle_int_attribute,
15113         bfin_handle_longcall_attribute, bfin_handle_l1_text_attribute,
15114         bfin_handle_l1_data_attribute, bfin_handle_longcall_attribute,
15115         bfin_handle_l1_text_attribute, bfin_handle_l1_data_attribute):
15116         Likewise.
15117         * config/darwin.c (darwin_handle_kext_attribute,
15118         darwin_handle_weak_import_attribute): Likewise.
15119         * config/h8300/h8300.c (h8300_handle_fndecl_attribute,
15120         h8300_handle_eightbit_data_attribute,
15121         h8300_handle_tiny_data_attribute): Likewise.
15122         * config/i386/i386.c (ix86_handle_cconv_attribute,
15123         ix86_handle_abi_attribute, ix86_handle_struct_attribute): Likewise.
15124         * config/i386/winnt.c (ix86_handle_shared_attribute,
15125         ix86_handle_selectany_attribute): Likewise.
15126         * config/ia64/ia64.c (ia64_handle_model_attribute): Likewise.
15127         * config/m32c/m32c.c (function_vector_handler): Likewise.
15128         * config/m68hc11/m68hc11.c (m68hc11_handle_page0_attribute,
15129         m68hc11_handle_fntype_attribute): Likewise.
15130         * config/m68k/m68k.c (m68k_handle_fndecl_attribute): Likewise.
15131         * config/mcore/mcore.c (mcore_handle_naked_attribute): Likewise.
15132         * config/mips/mips.c (mips_insert_attributes,
15133         mips_merge_decl_attributes, mips_expand_builtin): Likewise.
15134         * config/rs6000/rs6000.c (rs6000_handle_longcall_attribute,
15135         rs6000_handle_struct_attribute): Likewise.
15136         * config/sh/sh.c (sh_insert_attributes,
15137         sh_handle_resbank_handler_attribute,
15138         sh_handle_interrupt_handler_attribute,
15139         sh2a_handle_function_vector_handler_attribute,
15140         sh_handle_sp_switch_attribute, sh_handle_trap_exit_attribute):
15141         Likewise.
15142         * config/sh/symbian.c (sh_symbian_mark_dllimport): Likewise.
15143         * config/spu/spu.c (spu_handle_fndecl_attribute,
15144         spu_handle_vector_attribute): Likewise.
15145         * config/stormy16/stormy16.c
15146         (xstormy16_handle_interrupt_attribute): Likewise.
15147         * config/v850/v850-c.c (ghs_pragma_section): Likewise.
15148         * config/v850/v850.c (v850_handle_interrupt_attribute): Likewise.
15149
15150 2009-05-10  Joseph Myers  <joseph@codesourcery.com>
15151
15152         * pretty-print.h (struct pretty_print_info): Add translate_identifiers.
15153         (pp_translate_identifiers): New.
15154         (pp_identifier): Only conditionally translate identifier to locale
15155         character set.
15156         * pretty-print.c (pp_construct): Set pp_translate_identifiers.
15157         (pp_base_tree_identifier): Only conditionally translate identifier
15158         to locale character set.
15159         * c-pretty-print.c (M_): Define.
15160         (pp_c_type_specifier, pp_c_primary_expression): Mark English
15161         fragments for conditional translation with M_.
15162         * tree-pretty-print.c (maybe_init_pretty_print): Disable
15163         identifier translation.
15164
15165 2009-05-10  Richard Guenther  <rguenther@suse.de>
15166
15167         PR tree-optimization/40081
15168         * tree-sra.c (instantiate_element): Instantiate scalar replacements
15169         using the main variant of the element type.  Do not fiddle with
15170         TREE_THIS_VOLATILE or TREE_SIDE_EFFECTS.
15171
15172 2009-05-09  Jan Hubicka  <jh@suse.cz>
15173
15174         PR middle-end/40080
15175         * cgraphunit.c (cgraph_materialize_all_clones): Do not redirect
15176         indirect calls; verify cgraph afterwards.
15177
15178 2009-05-09  Jan Hubicka  <jh@suse.cz>
15179
15180         PR bootstrap/40082
15181         * ipa.c (update_inlined_to_pointer): New function.
15182         (cgraph_remove_unreachable_nodes): Use it.
15183
15184 2009-05-09  Jan Hubicka  <jh@suse.cz>
15185
15186         * tree-eh.c (struct leh_state): Remove prev_try.
15187         (lower_try_finally, lower_catch, lower_eh_filter, lower_cleanup): Do
15188         not track prev_try.
15189         * except.c (gen_eh_region_cleanup, duplicate_eh_regions,
15190         copy_eh_region_1, copy_eh_region, redirect_eh_edge_to_label,
15191         remove_eh_handler_and_replace, foreach_reachable_handler,
15192         verify_eh_region, verify_eh_tree): Remove tracking of prev_try pointer.
15193         * except.h (struct eh_region): Remove eh_region_u_cleanup.
15194         (gen_eh_region_cleanup): Update prototype.
15195
15196 2009-05-09  Jan Hubicka  <jh@suse.cz>
15197
15198         PR middle-end/40043
15199         * except.c (copy_eh_region): Always set prev_try.
15200         (redirect_eh_edge_to_label): Find outer try.
15201         (foreach_reachable_handler): When looking for prev try
15202         handle case where previous try is not going to be taken.
15203
15204 2009-05-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
15205
15206         PR tree-optimization/40049
15207         * tree-vect-stmts.c (vectorizable_operation): If the machine has
15208         only vector/vector shifts, convert the type of the constant to the
15209         appropriate type to avoid building incorrect trees, which
15210         eventually have problems with garbage collection.
15211
15212 2009-05-08  Joseph Myers  <joseph@codesourcery.com>
15213
15214         * fold-const.c (fold_binary): Do not fold multiplication by 1 or
15215         -1 for complex floating-point types if honoring signed zeros.
15216
15217 2009-05-08  Jan Hubicka  <jh@suse.cz>
15218
15219         * cgraphbuild.c (compute_call_stmt_bb_frequency): Accept function
15220         argument; handle correctly when profile is absent.
15221         (build_cgraph_edges): Update.
15222         (rebuild_cgraph_edges): Update.
15223         * cgraph.c: Do not include varray.h.
15224         (cgraph_set_call_stmt_including_clones): New function.
15225         (cgraph_create_edge_including_clones): Likewise
15226         (cgraph_update_edges_for_call_stmt_node): New static cfunction.
15227         (cgraph_update_edges_for_call_stmt): Handle clones.
15228         (cgraph_remove_node): Handle clone tree.
15229         (cgraph_remove_node_and_inline_clones): New function.
15230         (dump_cgraph_node): Dump clone tree.
15231         (cgraph_clone_node): Handle clone tree.
15232         (clone_function_name): Bring here from tree-inline.c.
15233         (cgraph_create_virtual_clone): New function.
15234         * cgraph.h (ipa_replace_map): Move here from ipa.h.
15235         (cgraph_clone_info): New function.
15236         (strut cgraph_node): Add clone_info and new clone tree pointers.
15237         (cgraph_remove_node_and_inline_clones,
15238         cgraph_set_call_stmt_including_clones,
15239         cgraph_create_edge_including_clones,
15240         cgraph_create_virtual_clone): Declare.
15241         (cgraph_function_versioning): Use VEC argument.
15242         (compute_call_stmt_bb_frequency): Update prototype.
15243         (cgraph_materialize_all_clones): New function.
15244         * ipa-cp.c (ipcp_update_cloned_node): Remove.
15245         (ipcp_create_replace_map): Update to VECtors.
15246         (ipcp_update_callgraph): Use virtual clones.
15247         (ipcp_update_bb_counts, ipcp_update_edges_counts): Remove.
15248         (ipcp_update_profiling): Do not update local profiling.
15249         (ipcp_insert_stage): Use VECtors and virtual clones.
15250         * cgraphunit.c (verify_cgraph_node): Verify clone tree.
15251         (clone_of_p): New function.
15252         (cgraph_preserve_function_body_p): Use clone tree.
15253         (cgraph_optimize): Materialize clones.
15254         (cgraph_function_versioning): Update for VECtors.
15255         (save_inline_function_body): Use clone tree.
15256         (cgraph_materialize_clone): New function.
15257         (cgraph_materialize_all_clones): Likewise.
15258         * ipa-inline.c (cgraph_default_inline_p): Use analyzed flags.
15259         * ipa.c: Include gimple.h.
15260         (cgraph_remove_unreachable_nodes): Use clone tree.
15261         * ipa-prop.c (ipa_note_param_call): Update call to
15262         compute_call_stmt_bb_frequencycall.
15263         * ipa-prop.h (ipa_replace_map): Move to cgraph.h.
15264         * tree-inline.c: Do not include varray.h or gt-tree-inline.h.
15265         (copy_bb): Handle updating of clone tree; add new edge when new call
15266         appears.
15267         (expand_call_inline): Be strict about every call having edge.
15268         (clone_fn_id_num, clone_function_name): Move to cgraph.c.
15269         (delete_unreachable_blocks_update_callgraph): New function.
15270         (tree_function_versioning): Use VECtors; always remove unreachable
15271         blocks and fold conditionals.
15272         * tree-inline.h: Do not include varray.h.
15273         (tree_function_versioning): Remove.
15274         * Makefile.in (GTFILES): Remove tree-inline.c
15275         * passes.c (do_per_function): Do only functions having body.
15276         * ipa-struct-reorg.c (do_reorg_1, collect_data_accesses): Handle clone
15277         tree.
15278
15279 2009-05-08  H.J. Lu  <hongjiu.lu@intel.com>
15280             Andrew Morrow  <acm@google.com>
15281
15282         PR c/36892
15283         * c-common.c (c_common_attribute_table): Permit deprecated
15284         attribute to take an optional argument.
15285         (handle_deprecated_attribute): If the optional argument to
15286         __attribute__((deprecated)) is not a string ignore the attribute
15287         and emit a warning.
15288
15289         * c-decl.c (grokdeclarator): Updated warn_deprecated_use call.
15290         * c-typeck.c (build_component_ref): Likewise.
15291         (build_external_ref): Likewise.
15292
15293         * toplev.c (warn_deprecated_use): Add an attribute argument.
15294         Emit the message associated with __attribute__((deprecated)).
15295
15296         * toplev.h (warn_deprecated_use): Updated.
15297
15298         * doc/extend.texi: Document new optional parameter to
15299         __attribute__((deprecated))
15300
15301 2009-05-08  Michael Eager <eager@eagercon.com>
15302
15303         * config/rs6000/rs6000.md (*movdf_softfloat32): replace
15304         !TARGET_DOUBLE_FLOAT with TARGET_SINGLE_FLOAT.
15305
15306 2009-05-08  Richard Guenther  <rguenther@suse.de>
15307
15308         PR tree-optimization/40062
15309         * tree-scalar-evolution.c (follow_ssa_edge_in_condition_phi):
15310         Avoid exponential behavior.
15311
15312 2009-05-08  Paolo Bonzini  <bonzini@gnu.org>
15313
15314         PR rtl-optimization/33928
15315         PR 26854
15316         * fwprop.c (use_def_ref, get_def_for_use, bitmap_only_bit_bitween,
15317         process_uses, build_single_def_use_links): New.
15318         (update_df): Update use_def_ref.
15319         (forward_propagate_into): Use get_def_for_use instead of use-def
15320         chains.
15321         (fwprop_init): Call build_single_def_use_links and let it initialize
15322         dataflow.
15323         (fwprop_done): Free use_def_ref.
15324         (fwprop_addr): Eliminate duplicate call to df_set_flags.
15325         * df-problems.c (df_rd_simulate_artificial_defs_at_top,
15326         df_rd_simulate_one_insn): New.
15327         (df_rd_bb_local_compute_process_def): Update head comment.
15328         (df_chain_create_bb): Use the new RD simulation functions.
15329         * df.h (df_rd_simulate_artificial_defs_at_top,
15330         df_rd_simulate_one_insn): New.
15331         * opts.c (decode_options): Enable fwprop at -O1.
15332         * doc/invoke.texi (-fforward-propagate): Document this.
15333
15334 2009-05-08  Joseph Myers  <joseph@codesourcery.com>
15335
15336         PR c/24581
15337         * c-typeck.c (build_binary_op): Handle arithmetic between one real
15338         and one complex operand specially.
15339         * tree-complex.c (some_nonzerop): Do not identify a real value as
15340         zero if flag_signed_zeros.
15341
15342 2009-05-08  Paolo Bonzini  <bonzini@gnu.org>
15343
15344         PR rtl-optimization/33928
15345         * loop-invariant.c (record_use): Fix && vs. || mishap.
15346
15347 2009-05-08  Paolo Bonzini  <bonzini@gnu.org>
15348
15349         PR rtl-optimization/33928
15350         * loop-invariant.c (struct use): Add addr_use_p.
15351         (struct def): Add n_addr_uses.
15352         (struct invariant): Add cheap_address.
15353         (create_new_invariant): Set cheap_address.
15354         (record_use): Accept df_ref.  Set addr_use_p and update n_addr_uses.
15355         (record_uses): Pass df_ref to record_use.
15356         (get_inv_cost): Do not add inv->cost to comp_cost for cheap addresses
15357         used only as such.
15358
15359 2009-05-08  Kaz Kojima  <kkojima@gcc.gnu.org>
15360
15361         * config/sh/sh.c: Do not include c-pragma.h.
15362
15363 2009-05-07  Andrew Pinski  <andrew_pinski@playstation.sony.com>
15364
15365         * config/spu/spu.c: Remove include of c-common.h.
15366
15367 2009-05-07  Janis Johnson  <janis187@us.ibm.com>
15368
15369         PR c/39037
15370         * c-common.h (mark_valid_location_for_stdc_pragma,
15371         valid_location_for_stdc_pragma_p, set_float_const_decimal64,
15372         clear_float_const_decimal64, float_const_decimal64_p): New.
15373         * c.opt (Wunsuffixed-float-constants): New.
15374         * c-lex.c (interpret_float): Use pragma FLOAT_CONST_DECIMAL64 for
15375         unsuffixed float constant, handle new warning.
15376         * c-cppbuiltin.c (c_cpp_builtins): Use cast for double constants.
15377         * c-decl.c (c_scope): New flag float_const_decimal64.
15378         (set_float_const_decimal64, clear_float_const_decimal64,
15379         float_const_decimal64_p): New.
15380         (push_scope): Set new flag.
15381         * c-parser.c (c_parser_translation_unit): Mark when it's valid
15382         to use STDC pragmas.
15383         (c_parser_external_declaration): Ditto.
15384         (c_parser_compound_statement_nostart): Ditto.
15385         * c-pragma.c (valid_location_for_stdc_pragma,
15386         mark_valid_location_for_stdc_pragma,
15387         valid_location_for_stdc_pragma_p, handle_stdc_pragma,
15388         handle_pragma_float_const_decimal64): New.
15389         (init_pragma): Register new pragma FLOAT_CONST_DECIMAL64.
15390         * cp/semantics.c (valid_location_for_stdc_pragma_p,
15391         set_float_const_decimal64, clear_float_const_decimal64,
15392         float_const_decimal64_p): New dummy functions.
15393         * doc/extend.texi (Decimal Float): Remove statement that the
15394         pragma, and suffix for double constants, are not supported.
15395         * doc/invoke.texi (Warning Options): List new option.
15396         (-Wunsuffixed-float-constants): New.
15397
15398 2009-05-08  Steven Bosscher  <steven@gcc.gnu.org>
15399
15400         * config/i386/i386.c: Do not include c-common.h.
15401
15402 2009-05-07  Mark Heffernan  <meheff@google.com>
15403
15404         * doc/invoke.texi (Debugging Options): Document change of debugging
15405         dump location.
15406         * opts.c (decode_options): Make dump_base_name relative to
15407         aux_base_name directory.
15408
15409 2009-05-07  Hariharan Sandanagobalane <hariharan@picochip.com>
15410
15411         * config/picochip/picochip.h (NO_DOLLAR_IN_LABEL): Added.
15412         * config/picochip/libgccExtras/divmod15.asm : Removed redefiniton.
15413
15414 2009-05-07  Rafael Avila de Espindola  <espindola@google.com>
15415
15416         * Makefile.in (install-plugin): Simplify a bit.
15417
15418 2009-05-07  Paolo Bonzini  <bonzini@gnu.org>
15419
15420         * Makefile.in (OBJS-common): Add regcprop.o.
15421         (regcprop.o): New.
15422         * timevar.def (TV_CPROP_REGISTERS): New.
15423         * regrename.c (regrename_optimize): Return 0.
15424         (rest_of_handle_regrename): Delete.
15425         (pass_rename_registers): Point to regrename_optimize.
15426         (struct value_data_entry, struct value_data,
15427         kill_value_one_regno, kill_value_regno, kill_value,
15428         set_value_regno, init_value_data, kill_clobbered_value,
15429         kill_set_value, kill_autoinc_value, copy_value,
15430         mode_change_ok, maybe_mode_change, find_oldest_value_reg,
15431         replace_oldest_value_reg, replace_oldest_value_addr,
15432         replace_oldest_value_mem, copyprop_hardreg_forward_1,
15433         debug_value_data, validate_value_data): Move...
15434         * regcprop.c: ... here.
15435         (rest_of_handle_cprop): Delete.
15436         (pass_cprop_hardreg): Point to copyprop_hardreg_forward.
15437
15438 2009-05-07  Jakub Jelinek  <jakub@redhat.com>
15439
15440         PR middle-end/40057
15441         * dojump.c (prefer_and_bit_test): Use immed_double_const instead of
15442         GEN_INT for 1 << bitnum.
15443         (do_jump) <case BIT_AND_EXPR>: Use build_int_cst_wide_type instead of
15444         build_int_cst_type.
15445
15446 2009-05-07  Uros Bizjak  <ubizjak@gmail.com>
15447
15448         * doc/md.texi (Standard Pattern Names For Generation) [sync_nand]:
15449         Remove wrong description of "nand" operation.
15450
15451 2009-05-06  Richard Guenther  <rguenther@suse.de>
15452             Adam Nemet  <anemet@caviumnetworks.com>
15453
15454         * gimple.def (GIMPLE_ASSIGN): Fix incorrect information in the
15455         comment.  Add that if LHS is not a gimple register, then RHS1 has
15456         to be a single object (GIMPLE_SINGLE_RHS).
15457
15458 2009-05-06  Adam Nemet  <anemet@caviumnetworks.com>
15459
15460         * expr.c (get_def_for_expr): Move it up in the file.
15461         (store_field): When expanding a bit-field store, look at the
15462         defining gimple stmt for the masking conversion.
15463
15464 2009-05-06  Janis Johnson  <janis187@us.ibm.com>
15465
15466         PR middle-end/39986
15467         * dfp.c (encode_decimal32, decode_decimal32, encode_decimal64,
15468         decode_decimal64, encode_decimal128, decode_decimal128): Avoid
15469         32-bit memcpy into long.
15470
15471 2009-05-06  Jakub Jelinek  <jakub@redhat.com>
15472
15473         * dwarf2out.c (new_reg_loc_descr): Don't ever create DW_OP_regX.
15474         (one_reg_loc_descriptor): Create DW_OP_regX here instead of calling
15475         new_reg_loc_descr.
15476         (loc_by_reference): If loc is DW_OP_regX, change it into DW_OP_bregX 0
15477         instead of appending DW_OP_deref*.
15478
15479 2009-05-06  Michael Matz  <matz@suse.de>
15480
15481         PR middle-end/40021
15482         * cfgexpand.c (maybe_cleanup_end_of_block): New static function.
15483         (expand_gimple_cond): Use it to cleanup CFG and superfluous jumps.
15484
15485 2009-05-06  Rafael Avila de Espindola  <espindola@google.com>
15486
15487         * Makefile.in (install-plugin): Fix srcdir handling.
15488
15489 2009-05-06  Andrey Belevantsev  <abel@ispras.ru>
15490
15491         * tree-ssa.c (execute_update_address_taken): Handle TARGET_MEM_REF
15492         when processing for not_regs_needed bitmap.
15493         * gimple.c (walk_stmt_load_store_addr_ops): When visiting address,
15494         handle TARGET_MEM_REF in lhs.  Check TMR_BASE for NULL while
15495         handling it for rhs.
15496
15497 2009-05-06  H.J. Lu  <hongjiu.lu@intel.com>
15498
15499         * config/i386/i386.md (unnamed inc/dec peephole): Use
15500         optimize_insn_for_size_p instead of optimize_size.
15501         * config/i386/predicates.md (incdec_operand): Likewise.
15502         (aligned_operand): Likewise.
15503         * config/i386/sse.md (divv8sf3): Likewise.
15504         (sqrtv8sf2): Likewise.
15505
15506 2009-05-06  H.J. Lu  <hongjiu.lu@intel.com>
15507
15508         * config/i386/i386.c (ix86_build_signbit_mask): Make it static.
15509
15510         * config/i386/i386-protos.h (ix86_build_signbit_mask): Removed.
15511
15512 2009-05-06  H.J. Lu  <hongjiu.lu@intel.com>
15513
15514         * config/i386/i386.md (*avx_<code><mode>3_finite): Replace
15515         ssemodesuffixf2c with avxmodesuffixf2c.
15516
15517 2009-05-06  Joseph Myers  <joseph@codesourcery.com>
15518
15519         PR c/40032
15520         * c-decl.c (grokdeclarator): Handle incomplete type of unnamed field.
15521
15522 2009-05-05  Jakub Jelinek  <jakub@redhat.com>
15523
15524         * tree.h: Remove DECL_BY_REFERENCE from private_flag comment.
15525         (struct tree_base): Adjust spacing for 8 bit boundaries.
15526         (struct tree_decl_common): Add decl_by_reference_flag bit.
15527         (DECL_BY_REFERENCE): Adjust.
15528         * print-tree.c (print_node): For VAR_DECL, PARM_DECL or RESULT_DECL,
15529         print DECL_BY_REFERENCE bit.
15530         * dbxout.c (DECL_ACCESSIBILITY_CHAR): Revert last change.
15531         * dwarf2out.c (loc_by_reference, gen_decl_die): Check
15532         DECL_BY_REFERENCE for all VAR_DECLs, not just non-static ones.
15533         (gen_variable_die): Likewise.  Check TREE_PRIVATE/TREE_PROTECTED
15534         unconditionally.
15535
15536         PR middle-end/39666
15537         * gimplify.c (gimplify_switch_expr): If case labels cover the whole
15538         range of the type, but default label is missing, add it with one
15539         of the existing labels instead of adding a new label for it.
15540
15541 2009-05-05  Joseph Myers  <joseph@codesourcery.com>
15542
15543         * dwarf.h: Remove.
15544
15545 2009-05-05  Rafael Avila de Espindola  <espindola@google.com>
15546
15547         * Makefile.in (enable_plugin, plugin_includedir): New.
15548         (install): Depend on install-plugin.
15549         (PLUGIN_HEADERS): New.
15550         (install-plugin): New.
15551         * config.gcc: Add vxworks-dummy.h to tm_file for x86 and x86-64.
15552
15553 2009-05-05  Richard Guenther  <rguenther@suse.de>
15554
15555         PR tree-optimization/40022
15556         * tree-ssa-phiprop.c (struct phiprop_d): Exchange vop_stmt for
15557         the only vuse.
15558         (phivn_valid_p): Fix tuplification error, simplify.
15559         (phiprop_insert_phi): Add dumps.
15560         (propagate_with_phi): Simplify.
15561
15562 2009-05-05  Richard Guenther  <rguenther@suse.de>
15563
15564         PR middle-end/40023
15565         * builtins.c (gimplify_va_arg_expr): Properly build the address.
15566
15567 2009-05-05  Shujing Zhao  <pearly.zhao@oracle.com>
15568
15569         * tree.h (strip_float_extensions): Remove duplicate declaration.
15570         (build_low_bits_mask, debug_fold_checksum, expand_function_end,
15571         expand_function_start, stack_protect_prologue, stack_protect_epilogue,
15572         block_ultimate_origin): Rearrange the declarations line to match the
15573         comment that indicates the .c file which the functions are defined.
15574         (dwarf2out_*, set_decl_rtl): Add comment.
15575         (get_base_address): Adjust comment.
15576         (change_decl_assembler_name, maybe_fold_*, build_addr): Rearrange the
15577         declarations line and add comment.
15578         (is_builtin_name): Add blank after function name, for clarity.
15579
15580 2009-05-04  Joseph Myers  <joseph@codesourcery.com>
15581
15582         * attribs.c (decl_attributes): Use %qE for identifiers in
15583         diagnostics.
15584         * cgraphunit.c (verify_cgraph_node): Translate function names to
15585         locale character set in diagnostics.
15586         * coverage.c (get_coverage_counts): Use %qE for identifiers in
15587         diagnostics.
15588         * doc/invoke.texi (-finstrument-functions-exclude-function-list):
15589         Document that functions are named in UTF-8.
15590         * expr.c (expand_expr_real_1): Translate function names to locale
15591         character set in diagnostics.
15592         * gimplify.c (omp_notice_variable, omp_is_private,
15593         gimplify_scan_omp_clauses): Use %qE for identifiers in
15594         diagnostics.
15595         * langhooks.c (lhd_print_error_function): Translate function names
15596         to locale character set.
15597         * langhooks.h (decl_printable_name): Document that return value is
15598         in internal character set.
15599         * stmt.c: Include pretty-print.h
15600         (tree_conflicts_with_clobbers_p): Use %qE for identifiers in
15601         diagnostics.
15602         (resolve_operand_name_1): Translate named operand name to locale
15603         character set.
15604         * stor-layout.c (finalize_record_size): Use %qE for identifiers in
15605         diagnostics.
15606         * toplev.c (announce_function): Translate function names to locale
15607         character set.
15608         (warn_deprecated_use): Use %qE for identifiers in diagnostics.
15609         (default_tree_printer): Use pp_identifier or translate identifiers
15610         to locale character set.  Mark "<anonymous>" for translation.
15611         * tree-mudflap.c (mx_register_decls, mudflap_finish_file): Use %qE
15612         for identifiers in diagnostics.
15613         * tree.c (handle_dll_attribute): Use %qE for identifiers in
15614         diagnostics.
15615         * varasm.c (output_constructor): Use %qE for identifiers in
15616         diagnostics.
15617
15618 2009-05-04  Rafael Avila de Espindola  <espindola@google.com>
15619
15620         * configure.ac: use ` ` instead of $()
15621         * configure: Regenerate.
15622
15623 2009-05-05  Ben Elliston  <bje@au.ibm.com>
15624
15625         * config/pa/linux-atomic.c: Eliminate conditional include of
15626         errno.h on non-LP64 systems to simplify build requirements.
15627
15628 2009-05-04  Joseph Myers  <joseph@codesourcery.com>
15629
15630         * c-common.c (handle_mode_attribute): Use %qE for identifiers in
15631         diagnostics.
15632         * c-decl.c (check_bitfield_type_and_width): Make orig_name a tree
15633         and pass value to identifier_to_locale.
15634         (warn_variable_length_array): Make name a tree.
15635         (grokdeclarator): Separate diagnostic texts for named and unnamed
15636         declarators.  Use %qE for named declarators.
15637         * c-parser.c (c_lex_one_token): Use %qE for identifiers in
15638         diagnostics.
15639         * c-pragma.c (pop_alignment, handle_pragma_pack): Use %qE for
15640         identifiers in diagnostics.
15641         * c-typeck.c (push_member_name, start_init): Pass identifiers to
15642         identifier_to_locale.  Mark "anonymous" strings for translation.
15643
15644 2009-05-04  Michael Eager <eager@eagercon.com>
15645
15646         * config/rs6000/rs6000.c (rs6000_legitimate_address): Allow
15647         address for DImode/DFmode only if double-precision FP regs.
15648
15649 2009-05-04  Michael Eager <eager@eagercon.com>
15650
15651         * config/rs6000/rs6000.c (rs6000_libcall_value): Add
15652         TARGET_SINGLE_FLOAT check.
15653
15654 2009-05-04  Michael Eager <eager@eagercon.com>
15655
15656         * config/rs6000/xilinx.h: Add CPP_SPEC for -mxilinx-fpu options.
15657
15658 2009-05-04  Michael Eager <eager@eagercon.com>
15659
15660         * gcc/config.gcc: (powerpc-xilinx-eabi*): Add tm t-xilinx
15661         * config/rs6000/t-xilinx: New
15662
15663 2009-05-04  Paolo Bonzini  <bonzini@gnu.org>
15664
15665         * doc/tm.texi (LEGITIMIZE_ADDRESS): Revise documentation.
15666         * gcc/defaults.h (LEGITIMIZE_ADDRESS): Delete.
15667         * gcc/explow.c (memory_address): Use target hook.
15668         * gcc/targhooks.c (default_legitimize_address): New.
15669         * gcc/targhooks.h (default_legitimize_address): New.
15670         * gcc/target.h (legitimize_address): New.
15671         * gcc/target-def.h (TARGET_LEGITIMIZE_ADDRESS): New.
15672         (TARGET_INITIALIZER): Include it.
15673         * gcc/system.h (LEGITIMIZE_ADDRESS): Poison.
15674
15675         * config/bfin/bfin-protos.h (legitimize_address): Remove.
15676         * config/bfin/bfin.c (legitimize_address): Remove.
15677         * config/bfin/bfin.h (LEGITIMIZE_ADDRESS): Remove.
15678         * config/m68hc11/m68hc11-protos.h (m68hc11_legitimize_address):
15679         Remove.
15680         * config/m68hc11/m68hc11.c (m68hc11_legitimize_address): Remove.
15681         * config/m68hc11/m68hc11.h (LEGITIMIZE_ADDRESS): Remove.
15682
15683         * gcc/config/arm/arm.h (LEGITIMIZE_ADDRESS, ARM_LEGITIMIZE_ADDRESS,
15684         THUMB_LEGITIMIZE_ADDRESS, THUMB2_LEGITIMIZE_ADDRESS): Delete.
15685         * gcc/config/s390/s390.h (LEGITIMIZE_ADDRESS): Delete.
15686         * gcc/config/m32c/m32c.h (LEGITIMIZE_ADDRESS): Delete.
15687         * gcc/config/sparc/sparc.h (LEGITIMIZE_ADDRESS): Delete.
15688         * gcc/config/m32r/m32r.h (LEGITIMIZE_ADDRESS): Delete.
15689         * gcc/config/i386/i386.h (LEGITIMIZE_ADDRESS): Delete.
15690         * gcc/config/sh/sh.h (LEGITIMIZE_ADDRESS): Delete.
15691         * gcc/config/avr/avr.h (LEGITIMIZE_ADDRESS): Delete.
15692         * gcc/config/m68hc11/m68hc11.h (LEGITIMIZE_ADDRESS): Delete.
15693         * gcc/config/iq2000/iq2000.h (LEGITIMIZE_ADDRESS): Delete.
15694         * gcc/config/mn10300/mn10300.h (LEGITIMIZE_ADDRESS): Delete.
15695         * gcc/config/m68k/m68k.h (LEGITIMIZE_ADDRESS): Delete.
15696         * gcc/config/score/score.h (LEGITIMIZE_ADDRESS): Delete.
15697         * gcc/config/pa/pa.h (LEGITIMIZE_ADDRESS): Delete.
15698         * gcc/config/mips/mips.h (LEGITIMIZE_ADDRESS): Delete.
15699         * gcc/config/alpha/alpha.h (LEGITIMIZE_ADDRESS): Delete.
15700         * gcc/config/frv/frv.h (LEGITIMIZE_ADDRESS): Delete.
15701         * gcc/config/spu/spu.h (LEGITIMIZE_ADDRESS): Delete.
15702         * gcc/config/xtensa/xtensa.h (LEGITIMIZE_ADDRESS): Delete.
15703         * gcc/config/cris/cris.h (LEGITIMIZE_ADDRESS): Delete.
15704         * gcc/config/rs6000/rs6000.h (LEGITIMIZE_ADDRESS): Delete.
15705         * gcc/config/picochip/picochip.h (LEGITIMIZE_ADDRESS): Delete.
15706
15707         * gcc/config/s390/s390-protos.h (legitimize_address): Delete.
15708         * gcc/config/m32c/m32c-protos.h (m32c_legitimize_address): Delete.
15709         * gcc/config/sparc/sparc-protos.h (legitimize_address): Delete.
15710         * gcc/config/i386/i386-protos.h (legitimize_address): Delete.
15711         * gcc/config/avr/avr-protos.h (legitimize_address): Delete.
15712         * gcc/config/mn10300/mn10300-protos.h (legitimize_address): Delete.
15713         * gcc/config/score/score-protos.h (score_legitimize_address): Delete.
15714         * gcc/config/arm/arm-protos.h (arm_legitimize_address,
15715         (thumb_legitimize_address): Delete.
15716         * gcc/config/pa/pa-protos.h (hppa_legitimize_address): Delete.
15717         * gcc/config/mips/mips-protos.h (mips_legitimize_address): Delete.
15718         * gcc/config/alpha/alpha-protos.h (alpha_legitimize_address): Delete.
15719         * gcc/config/frv/frv-protos.h (frv_legitimize_address): Delete.
15720         * gcc/config/spu/spu-protos.h (spu_legitimize_address): Delete.
15721         * gcc/config/xtensa/xtensa-protos.h (xtensa_legitimize_address):
15722         Delete.
15723         * gcc/config/rs6000/rs6000-protos.h (rs6000_legitimize_address):
15724         Delete.
15725
15726         * config/arm/arm.c (arm_legitimize_address): Maybe call Thumb version.
15727         * config/m32c/m32c.c (m32c_legitimize_address): Standardize.
15728         * config/m32r/m32r.c (m32r_legitimize_address): New.
15729         * config/m68k/m68k.c (m68k_legitimize_address): New.
15730         * config/score/score.c (score_legitimize_address): Standardize.
15731         * config/score/score3.c (score3_legitimize_address): Standardize.
15732         * config/score/score3.h (score3_legitimize_address): Adjust.
15733         * config/score/score7.c (score7_legitimize_address): Standardize.
15734         * config/score/score7.h (score7_legitimize_address): Adjust.
15735         * config/sh/sh.c (sh_legitimize_address): New.
15736         * config/iq2000/iq2000.c (iq2000_legitimize_address): New.
15737
15738         * gcc/config/s390/s390.c (legitimize_address): Rename to...
15739         (s390_legitimize_address): ... this.
15740         * gcc/config/sparc/sparc.c (legitimize_address): Rename to...
15741         (sparc_legitimize_address): ... this.
15742         * gcc/config/i386/i386.c (legitimize_address): Rename to...
15743         (ix86_legitimize_address): ... this.
15744         * gcc/config/avr/avr.c (legitimize_address): Rename to...
15745         (avr_legitimize_address): ... this.
15746         * gcc/config/mn10300/mn10300.c (legitimize_address): Rename to...
15747         (mn10300_legitimize_address): ... this.
15748         * config/alpha/alpha.c (alpha_legitimize_address): Wrap...
15749         (alpha_legitimize_address_1): ... the old alpha_legitimize_address.
15750         (alpha_expand_mov): Adjust call.
15751
15752         * config/frv/frv.c (frv_legitimize_address): Return x on failure.
15753         * config/spu/spu.c (spu_legitimize_address): Likewise.
15754         * config/xtensa/xtensa.c (xtensa_legitimize_address): Likewise.
15755         * config/rs6000/rs6000.c (rs6000_legitimize_address): Likewise.
15756
15757 2009-05-04  Joseph Myers  <joseph@codesourcery.com>
15758
15759         * intl.c (locale_encoding, locale_utf8): New.
15760         (gcc_init_libintl): Initialize locale_encoding and locale_utf8.
15761         * intl.h (locale_encoding, locale_utf8): Declare.
15762         * pretty-print.c: Include ggc.h.  Include iconv.h if HAVE_ICONV.
15763         (pp_base_tree_identifier, decode_utf8_char, identifier_to_locale):
15764         New.
15765         * pretty-print.h (pp_identifier): Call identifier_to_locale on ID
15766         argument.
15767         (pp_tree_identifier): Define to call pp_base_tree_identifier.
15768         (pp_base_tree_identifier): Declare as function.
15769         (identifier_to_locale): Declare.
15770         * Makefile.in (pretty-print.o): Update dependencies.
15771         * varasm.c (finish_aliases_1): Use %qE for identifiers in diagnostics.
15772
15773 2009-05-04  Richard Guenther  <rguenther@suse.de>
15774
15775         PR middle-end/40015
15776         * builtins.c (fold_builtin_memory_op): Do not decay to element
15777         type if the size matches the whole array.
15778
15779 2009-05-04  Kazu Hirata  <kazu@codesourcery.com>
15780
15781         * expmed.c (synth_mult): When trying out a shift, pass the result
15782         of a signed shift.
15783
15784 2009-05-04  Kazu Hirata  <kazu@codesourcery.com>
15785
15786         * expmed.c (shiftsub_cost): Rename to shiftsub0_cost.
15787         (shiftsub1_cost): New.
15788         (init_expmed): Compute shiftsub1_cost.
15789         (synth_mult): Optimize multiplications by constants of the form
15790         -(2^^m-1) for some constant positive integer m.
15791
15792 2009-05-03  Richard Guenther  <rguenther@suse.de>
15793
15794         PR c/39983
15795         * c-typeck.c (array_to_pointer_conversion): Do not built
15796         ADDR_EXPRs of arrays of pointer-to-element type.
15797         * c-gimplify.c (c_gimplify_expr): Revert change fixing
15798         up wrong ADDR_EXPRs after-the-fact.
15799         * c-common.c (strict_aliasing_warning): Strip pointer
15800         conversions for obtaining the original type.
15801         * builtins.c (fold_builtin_memset): Handle array types.
15802         (fold_builtin_memory_op): Handle folded POINTER_PLUS_EXPRs
15803         and array types
15804
15805 2009-05-03  Richard Guenther  <rguenther@suse.de>
15806
15807         PR middle-end/23329
15808         * tree-ssa.c (useless_type_conversion_p_1): Use get_deref_alias_set.
15809         Do not lose casts from array types with unknown extent to array
15810         types with known extent.
15811         * tree-ssa-copy.c (may_propagate_copy): Remove hack checking for
15812         alias set compatibility.
15813
15814 2009-05-03  Manuel López-Ibáñez  <manu@gcc.gnu.org>
15815
15816         * flags.h (extra_warnings): Delete.
15817         * toplev.c (process_options): Handle Wuninitialized here.
15818         * opts.c (extra_warnings): Delete.
15819         (set_Wextra): Delete.
15820         (common_handle_option): -Wextra can be handled automatically.
15821         * c-opts.c (c_common_handle_option): Delete obsolete code.
15822         (c_common_post_options): Simplify comment.
15823         * common.opt (W): Add Var.
15824         (Wextra): Add Var.
15825         (Wuninitialized): Initialize to -1.
15826
15827 2009-05-03  Adam Nemet  <anemet@caviumnetworks.com>
15828             Richard Guenther  <rguenther@suse.de>
15829
15830         * expr.c (get_def_for_expr): New function.
15831         (expand_expr_real_1) <PLUS_EXPR, MINUS_EXPR>: Adjust to work with
15832         SSA rather than trees.
15833         <MULT_EXPR>: Likewise.  Use subexp0 and subexp1 instead of
15834         TREE_OPERAND (exp, 0) and TREE_OPERAND (exp, 1).
15835
15836 2009-05-03  Joseph Myers  <joseph@codesourcery.com>
15837
15838         * c-common.c (reswords): Add _Imaginary.
15839         * c-common.c (enum rid): Add RID_IMAGINARY.
15840
15841 2009-05-03  Paolo Bonzini  <bonzini@gnu.org>
15842
15843         * tree.h (TYPE_VECTOR_OPAQUE): Fix documentation.
15844         Patch by Richard Guenther.
15845
15846 2009-05-03  Anatoly Sokolov  <aesok@post.ru>
15847
15848         * defaults.h (FRAME_POINTER_REQUIRED): Provide default.
15849         * doc/tm.texi (FRAME_POINTER_REQUIRED): Revise documentation.
15850         * config/alpha/alpha.h (FRAME_POINTER_REQUIRED): Delete.
15851         * config/s390/s390.h (FRAME_POINTER_REQUIRED): Delete.
15852         * config/spu/spu.h (FRAME_POINTER_REQUIRED): Delete.
15853         * config/sh/sh.h (FRAME_POINTER_REQUIRED): Delete.
15854         * config/pdp11/pdp11.h (FRAME_POINTER_REQUIRED): Delete.
15855         * config/stormy16/stormy16.h (FRAME_POINTER_REQUIRED): Delete.
15856         * config/m68hc11/m68hc11.h (FRAME_POINTER_REQUIRED): Delete.
15857         * config/iq2000/iq2000.h (FRAME_POINTER_REQUIRED): Delete.
15858         * config/mn10300/mn10300.h (FRAME_POINTER_REQUIRED): Delete.
15859         * config/ia64/ia64.h (FRAME_POINTER_REQUIRED): Delete.
15860         * config/m68k/m68k.h (FRAME_POINTER_REQUIRED): Delete.
15861         * config/rs6000/rs6000.h (FRAME_POINTER_REQUIRED): Delete.
15862         * config/picochip/picochip.h (FRAME_POINTER_REQUIRED): Delete.
15863         * config/mcore/mcore.h (FRAME_POINTER_REQUIRED): Delete.
15864         * config/h8300/h8300.h (FRAME_POINTER_REQUIRED): Delete.
15865         * config/v850/v850.h (FRAME_POINTER_REQUIRED): Delete.
15866
15867 2009-05-02  Richard Guenther  <rguenther@suse.de>
15868
15869         PR tree-optimization/39940
15870         * tree-ssa-pre.c (eliminate): Make sure we may propagate before
15871         doing so.
15872
15873 2009-05-02  Richard Guenther  <rguenther@suse.de>
15874
15875         PR middle-end/40001
15876         * tree-ssa.c (execute_update_addresses_taken): Properly check
15877         if we can mark a variable DECL_GIMPLE_REG_P.
15878         * gimple.c (is_gimple_reg): Re-order check for DECL_GIMPLE_REG_P
15879         back to the end of the function.
15880         (is_gimple_reg_type): Remove complex type special casing.
15881         * gimplify.c (gimplify_bind_expr): Do not set DECL_GIMPLE_REG_P
15882         if not optimizing.
15883
15884 2009-05-02  Ben Elliston  <bje@au.ibm.com>
15885
15886         * doc/collect2.texi (Collect2): Document search path behaviour
15887         when configured with --with-ld.
15888
15889 2009-05-02  Jan Hubicka  <jh@suse.cz>
15890
15891         * tree-ssa-coalesce.c (coalesce_cost): Do not take ciritical
15892         parameter; update callers.
15893         (coalesce_cost_edge): EH edges are costier because they needs
15894         splitting even if not critical and even more costier when there are
15895         multiple EH predecestors.
15896
15897 2009-05-02  Jan Hubicka  <jh@suse.cz>
15898
15899         * except.c (remove_eh_handler_and_replace): Handle updating after
15900         removing TRY blocks.
15901
15902 2009-05-02  Eric Botcazou  <ebotcazou@adacore.com>
15903
15904         * store-motion.c (compute_store_table): Add ENABLE_CHECKING guard.
15905
15906 2009-05-02  Steven Bosscher  <steven@gcc.gnu.org>
15907
15908         * varasm.c: Do not include c-pragma.h.
15909         * attribs.c: Do not incude c-common.h.
15910
15911 2009-05-01  Michael Matz  <matz@suse.de>
15912
15913         * calls.c (initialize_argument_information): Handle SSA names like
15914         decls with a non MEM_P DECL_RTL.
15915
15916 2009-05-01  Steven Bosscher  <steven@gcc.gnu.org>
15917
15918         * ipa-reference.c: Do not include c-common.h, include splay-tree.h.
15919         * ipa-utils.c: Likewise.
15920         * ipa-type-escape.c: Likewise.
15921         * cgraphunit.c Do not include c-common.h.
15922         * ipa-pure-const.c: Likewise.
15923         * tree-if-conv.c: Likewise.
15924         * matrix-reorg.c: Do not include c-common.h and c-tree.h.
15925         * ipa-struct-reorg.c: Likewise.
15926         * tree-nomudflap.c: Likewise.
15927         * tree-ssa-structalias.c: Likewise.
15928
15929 2009-05-01  Steven Bosscher  <steven@gcc.gnu.org>
15930
15931         * store-motion.c: Many cleanups to make this pass a first-class
15932         citizen instead of an appendix to gcse load motion.  Add TODO list
15933         to make this pass faster/cleaner/better.
15934
15935         (struct ls_expr): Post gcse.c-split cleanups.
15936         Rename to st_expr.  Rename "loads" field to "antic_stores".  Rename
15937         "stores" field to "avail_stores".
15938         (pre_ldst_mems): Rename to store_motion_mems.
15939         (pre_ldst_table): Rename to store_motion_mems_table.
15940         (pre_ldst_expr_hash): Rename to pre_st_expr_hash, update users.
15941         (pre_ldst_expr_eq): Rename to pre_st_expr_eq, update users.
15942         (ldst_entry): Rename to st_expr_entry, update users.
15943         (free_ldst_entry): Rename to free_st_expr_entry, update users.
15944         (free_ldst_mems): Rename to free_store_motion_mems, update users.
15945         (enumerate_ldsts): Rename to enumerate_store_motion_mems,
15946         update caller.
15947         (first_ls_expr): Rename to first_st_expr, update users.
15948         (next_ls_expr): Rename to next_st_expr, update users.
15949         (print_ldst_list): Rename to print_store_motion_mems.  Print names of
15950         fields properly for store motion instead of names inherited from load
15951         motion in gcse.c.
15952         (ANTIC_STORE_LIST, AVAIL_STORE_LIST): Remove.
15953         (LAST_AVAIL_CHECK_FAILURE): Explain what this is.  Undefine when we
15954         are done with it.
15955
15956         (ae_kill): Rename to st_kill, update users.
15957         (ae_gen): Rename to st_avloc, update users.
15958         (transp): Rename to st_transp, update users.
15959         (pre_insert_map): Rename to st_insert_map, update users.
15960         (pre_delete_map): Rename to st_delete_map, update users.
15961         (insert_store, build_store_vectors, free_store_memory,
15962         one_store_motion_pass): Update for abovementioned changes.
15963
15964         (gcse_subst_count, gcse_create_count): Remove.
15965         (one_store_motion_pass): New statistics counters "n_stores_deleted"
15966         and "n_stores_created", local variables.
15967
15968         (extract_mentioned_regs, extract_mentioned_regs_1): Rewrite to
15969         use for_each_rtx.
15970
15971         (regvec, compute_store_table_current_insn): Remove.
15972         (reg_set_info, reg_clear_last_set): Remove.
15973         (compute_store_table): Use DF caches instead of local dataflow
15974         solvers.
15975
15976 2009-05-01  Joseph Myers  <joseph@codesourcery.com>
15977
15978         * c-objc-common.c (c_tree_printer): Print identifiers with
15979         pp_identifier, not pp_string.  Mark "({anonymous})" for
15980         translation.
15981         * c-pretty-print.c (pp_c_ws_string): New.
15982         (pp_c_cv_qualifier, pp_c_type_specifier,
15983         pp_c_specifier_qualifier_list, pp_c_parameter_type_list,
15984         pp_c_storage_class_specifier, pp_c_function_specifier,
15985         pp_c_attributes, pp_c_bool_constant, pp_c_constant,
15986         pp_c_primary_expression, pp_c_postfix_expression,
15987         pp_c_unary_expression, pp_c_shift_expression,
15988         pp_c_relational_expression, pp_c_equality_expression,
15989         pp_c_logical_and_expression, pp_c_logical_or_expression): Mostly
15990         use pp_string and pp_c_ws_string in place of pp_identifier and
15991         pp_c_identifier for non-identifiers.  Mark English strings for
15992         translation.
15993         * c-pretty-print.h (pp_c_ws_string): Declare.
15994
15995 2009-04-30  Paul Pluzhnikov  <ppluzhnikov@google.com>
15996             Roland McGrath <roland@redhat.com>
15997
15998         * configure.ac (HAVE_LD_BUILDID): New check for ld --build-id support.
15999         (ENABLE_LD_BUILDID): New configuration option.
16000         * gcc.c [HAVE_LD_BUILDID and ENABLE_LD_BUILDID]
16001         (LINK_BUILDID_SPEC): New macro.
16002         (init_spec): If defined, prepend it between LINK_EH_SPEC and
16003         link_spec.
16004         * doc/install.texi: Document --enable-linker-build-id option.
16005         * configure: Rebuild.
16006         * config.in: Rebuild.
16007
16008 2009-04-30  Adam Nemet  <anemet@caviumnetworks.com>
16009
16010         * config/mips/mips.h (FRAME_GROWS_DOWNWARD,
16011         MIPS_GP_SAVE_AREA_SIZE): Define new macros.
16012         (STARTING_FRAME_OFFSET): Return 0 if FRAME_GROWS_DOWNWARD.  Use
16013         MIPS_GP_SAVE_AREA_SIZE.
16014         * config/mips/mips.c (struct mips_frame_info): Update comment
16015         before arg_pointer_offset and hard_frame_pointer_offset.
16016         (mips_compute_frame_info): Update diagram before function: to
16017         correctly use stack_pointer_rtx for fp_sp_offset and gp_sp_offset, to
16018         indicate the position of frame_pointer_rtx with -fstack-protector and
16019         to show args_size.  Don't allocate cprestore area for leaf functions
16020         if FRAME_GROWS_DOWNWARD.  Use MIPS_GP_SAVE_AREA_SIZE to set
16021         cprestore_size.
16022         (mips_initial_elimination_offset): Update for FRAME_GROWS_DOWNWARD.
16023
16024 2009-04-30  Michael Matz  <matz@suse.de>
16025
16026         PR tree-optimization/39955
16027         * config/rs6000/rs6000.c (rs6000_check_sdmode): Also check SSA_NAMEs.
16028
16029 2009-04-30  Dave Korn  <dave.korn.cygwin@gmail.com>
16030
16031         * ira.c (setup_cover_and_important_classes):  Use safe macro
16032         REG_CLASS_FOR_CONSTRAINT instead of calling regclass_for_constraint
16033         directly.
16034         * genpreds.c (write_tm_preds_h):  Output suitable definition of
16035         REG_CLASS_FOR_CONSTRAINT.
16036
16037 2009-04-30  Rafael Avila de Espindola  <espindola@google.com>
16038
16039         * alloc-pool.c (alloc_pool_descriptor): Use an insert_opion value
16040         instead of an int.
16041         * bitmap.c (bitmap_descriptor): Likewise.
16042         * ggc-common.c (loc_descriptor): Likewise.
16043         * varray.c (varray_descriptor): Likewise.
16044         * vec.c (vec_descriptor): Likewise.
16045
16046 2009-04-30  Eric Botcazou  <ebotcazou@adacore.com>
16047
16048         * Makefile.in (dce.o): Add $(EXCEPT_H).
16049         * dce.c: Include except.h and delete redundant vector definitions.
16050         (deletable_insn_p): Return false for non-call insns that can throw
16051         if DF is running.
16052
16053 2009-04-30  Steven Bosscher  <steven@gcc.gnu.org>
16054
16055         * gcse.c (ae_gen): Remove.
16056         (can_assign_to_reg_p): Rename to can_assign_to_reg_without_clobbers_p
16057         and make non-static function to make it available in store-motion.c.
16058         Update call sites with search-and-replace.
16059         (enumerate_ldsts, reg_set_info, reg_clear_last_set, store_ops_ok,
16060         extract_mentioned_regs, extract_mentioned_regs_helper,
16061         find_moveable_store, compute_store_table, load_kills_store, find_loads,
16062         store_killed_in_insn, store_killed_after, store_killed_before,
16063         build_store_vectors, insert_insn_start_basic_block, insert-store,
16064         remove_reachable_equiv_notes, replace_store_insn, delete_store,
16065         free_store_memory, one_store_motion_pass, gate_rtl_store_motion,
16066         execute_rtl_store_motion, pass_rtl_store_motion): Move to...
16067         * store-motion.c: ...new file.  Also copy data structures from gcse.c
16068         and clean up to remove parts not used by store motion.
16069         * rtl.h (can_assign_to_reg_without_clobbers_p): Add prototype.
16070         * Makefile.in (store-motion.o): New rule. Add to OBJS-common.
16071
16072 2009-04-30  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
16073
16074         PR target/38571
16075         * config/arm/arm.h (FUNCTION_BOUNDARY): Set to 16 for thumb
16076         when optimizing for size.
16077
16078 2009-04-30  Hans-Peter Nilsson  <hp@axis.com>
16079
16080         * gcse.c (gcse_constant_p): Fix typo in last change.
16081
16082 2009-04-30  Rafael Avila de Espindola  <espindola@google.com>
16083
16084         * plugin.c: Include plugin-version.h only if ENABLE_PLUGIN is defined.
16085
16086 2009-04-30  Andreas Krebbel  <krebbel1@de.ibm.com>
16087
16088         * gcse.c (gcse_constant_p): Make sure the constant is sharable.
16089
16090 2009-04-29  James E. Wilson  <wilson@codesourcery.com>
16091
16092         * config/mips/mips.c (mips_add_offset): Use gen_int_mode for
16093         CONST_HIGH_PART result.
16094
16095 2009-04-29  Anatoly Sokolov  <aesok@post.ru>
16096
16097         * config/avr/avr.c (initial_elimination_offset): Rename to
16098         avr_initial_elimination_offset.
16099         (frame_pointer_required_p): Rename to avr_frame_pointer_required_p,
16100         change return type to bool.
16101         (avr_can_eliminate): New function.
16102         * config/avr/avr.h (CAN_ELIMINATE): Use avr_can_eliminate.
16103         (FRAME_POINTER_REQUIRED): Use avr_frame_pointer_required_p.
16104         (INITIAL_ELIMINATION_OFFSET): Use avr_initial_elimination_offset.
16105         * config/avr/avr-protos.h (initial_elimination_offset): Rename to
16106         avr_initial_elimination_offset.
16107         (frame_pointer_required_p): Rename to avr_frame_pointer_required_p.
16108         (avr_initial_elimination_offset): Define.
16109
16110 2009-04-29  Eric Botcazou  <ebotcazou@adacore.com>
16111             Steven Bosscher  <steven@gcc.gnu.org>
16112
16113         PR rtl-optimization/39938
16114         * Makefile.in (cfgrtl.o): Add $(INSN_ATTR_H).
16115         * cfgrtl.c: Include insn-attr.h.
16116         (rest_of_pass_free_cfg): New function.
16117         (pass_free_cfg): Use rest_of_pass_free_cfg as execute function.
16118         * resource.c (init_resource_info): Remove call to df_analyze.
16119
16120 2009-04-29  Richard Guenther  <rguenther@suse.de>
16121
16122         PR target/39943
16123         * config/i386/i386.c (ix86_vectorize_builtin_conversion): Only
16124         allow conversion to signed integers.
16125
16126 2009-04-29  Richard Guenther  <rguenther@suse.de>
16127
16128         * tree-cfg.c (verify_gimple_assign_binary): Allow vector
16129         shifts of floating point vectors if the shift amount is
16130         a constant multiple of the element size.
16131
16132 2009-04-29  Andreas Krebbel  <krebbel1@de.ibm.com>
16133             Michael Matz  <matz@suse.de>
16134
16135         PR middle-end/39927
16136         PR bootstrap/39929
16137         * tree-outof-ssa.c (emit_partition_copy): New function.
16138         (insert_partition_copy_on_edge, insert_rtx_to_part_on_edge,
16139         insert_part_to_rtx_on_edge): Perform the partition base var
16140         copy using emit_partition_copy.
16141         (insert_value_copy_on_edge): Convert constants to the right mode.
16142         (insert_rtx_to_part_on_edge): Add UNSIGNEDSRCP parameter.
16143         (elim_create): Pass the sign of the src to insert_rtx_to_part_on_edge.
16144
16145 2009-04-29  Bernd Schmidt  <bernd.schmidt@analog.com>
16146
16147         * config/bfin/bfin.c (bfin_optimize_loop): If we need a scratch reg,
16148         scan backwards to try to find a constant to initialize it.
16149
16150         * config/bfin/bfin.c (bfin_optimize_loop): When looking for the last
16151         insn before the loop_end instruction, don't look past labels.
16152
16153 2009-04-29  Richard Guenther  <rguenther@suse.de>
16154
16155         PR middle-end/39937
16156         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Do not
16157         loose type conversions.
16158         (forward_propagate_addr_expr): Fix tuplification bug.  Remove
16159         stmts only if there are no uses of its definition.
16160
16161 2009-04-29  Bernd Schmidt  <bernd.schmidt@analog.com>
16162
16163         * config/bfin/bfin.h (splitting_loops): Declare.
16164         * config/bfin/bfin-protos.h (WA_05000257, WA_05000283, WA_05000315):
16165         Reorder bit definitions to be ascending.
16166         (WA_LOAD_LCREGS, ENABLE_WA_LOAD_LCREGS): New macros.
16167         * config/bfin/bfin.c (splitting_loops): New variable.
16168         (bfin_cpus): Add WA_LOAD_LCREGS as needed.
16169         (struct loop_info): Remove members INIT and LOOP_INIT.
16170         (bfin_optimize_loop): Don't set them.  Reorder the code that generates
16171         the LSETUP sequence.  Allow LC to be loaded from any register, but
16172         also add a case to push/pop a PREG scratch if ENABLE_WA_LOAD_LCREGS.
16173         (bfin_reorg_loops): When done, split all BB_ENDs with splitting_loops
16174         set to 1.
16175         * config/bfin/bfin.md (loop_end splitter): Use splitting_loops instead
16176         of reload_completed.
16177
16178         From Jie Zhang:
16179         * config/bfin/bfin.md (movsi_insn): Refine constraints.
16180
16181 2009-04-29  Rafael Avila de Espindola  <espindola@google.com>
16182
16183         * Makefile.in (PLUGIN_VERSION_H): New.
16184         (OBJS-common): Remove plugin-version.o.
16185         (plugin.o): Depend on (PLUGIN_VERSION_H).
16186         (plugin-version.o): Remove.
16187         * configure: Regenerate
16188         * configure.ac: Create plugin-version.h.
16189         * gcc-plugin.h (plugin_gcc_version): Remove.
16190         (plugin_default_version_check): Change signature.
16191         * plugin-version.c: Remove.
16192         * plugin.c: Include plugin-version.h.
16193         (str_plugin_gcc_version_name): Remove.
16194         (try_init_one_plugin): Pass gcc version to plugin_init.
16195         (plugin_default_version_check): Both gcc and plugin versions are now
16196         arguments.
16197
16198 2009-04-29  Bernd Schmidt  <bernd.schmidt@analog.com>
16199
16200         * config/bfin/bfin.c (bfin_optimize_loop): Unify handling of
16201         problematic last insns.  Test for TYPE_CALL rather than CALL_P.
16202         Remove special case testing for last insn of inner loops. Don't fail
16203         if the loop ends with a jump, emit an extra nop instead.
16204
16205         * config/bfin/bfin.c (bfin_register_move_cost): Test for subsets of
16206         DREGS rather than comparing directly.  Remove code that tries to
16207         account for latencies.
16208
16209 2009-04-29  Richard Guenther  <rguenther@suse.de>
16210
16211         PR tree-optimization/39941
16212         * tree-ssa-pre.c (eliminate): Schedule update-ssa after
16213         eliminating an indirect call.
16214
16215 2009-04-29  Richard Guenther  <rguenther@suse.de>
16216
16217         * tree-cfg.c (verify_types_in_gimple_reference): Add require_lvalue
16218         parameter.  Allow invariants as base if !require_lvalue.
16219         (verify_gimple_assign_single): Adjust.
16220
16221 2009-04-29  Bernd Schmidt  <bernd.schmidt@analog.com>
16222
16223         * config/bfin/bfin.md (sp_or_sm, spm_string, spm_name): New macro.
16224         (ss<spm_name>hi3, ss<spm_name>hi3_parts, ss<spm_name>hi3_low_parts,
16225         ss<spm_name_hi3_high_parts): New patterns, replacing ssaddhi3,
16226         ssubhi3, ssaddhi3_parts and sssubhi3_parts.
16227         (flag_mulhi3_parts): Produce a HImode output rather than trying to set
16228         a VEC_SELECT.
16229         * config/bfin/bfin.c (bfin_expand_builtin,
16230         case BFIN_BUILTIN_CPLX_SQU): Adjust accordingly.
16231
16232 2009-04-28  Richard Guenther  <rguenther@suse.de>
16233
16234         * tree-vect-loop.c (get_initial_def_for_induction): Use
16235         correct types for pointer increment.
16236
16237 2009-04-29  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
16238
16239         * toplev.c (print_version): Update GMP version string calculation.
16240
16241 2009-04-28  Eric Botcazou  <ebotcazou@adacore.com>
16242
16243         PR rtl-optimization/39938
16244         * resource.c (init_resource_info): Add call to df_analyze.
16245
16246 2009-04-28  Uros Bizjak  <ubizjak@gmail.com>
16247
16248         * config/alpha/alpha.md (usegp): Cast the result of
16249         alpha_find_lo_sum_using_gp to enum attr_usegp.
16250         * config/alpha/alpha.c (override_options): Remove end-of-structure
16251         marker element from cpu_table.  Use array size of cpu_table to handle
16252         -mcpu and -mtune options.
16253         (tls_symbolic_operand_type): Change 0 to TLS_MODEL_NONE.
16254
16255 2009-04-28  Joseph Myers  <joseph@codesourcery.com>
16256
16257         * config.gcc (powerpc*-*-* | rs6000-*-*): Add
16258         rs6000/option-defaults.h to tm_file.  Support cpu_32, cpu_64,
16259         tune_32 and tune_64.
16260         * doc/install.texi (--with-cpu-32, --with-cpu-64): Document
16261         support on PowerPC.
16262         * config/rs6000/rs6000.h (OPTION_DEFAULT_SPECS): Move to ...
16263         * config/rs6000/option-defaults.h: ... here.  New file.
16264         (OPT_64, OPT_32): Define.
16265         (MASK_64BIT): Define to 0 if not already defined.
16266         (OPT_ARCH64, OPT_ARCH32): Define.
16267         (OPTION_DEFAULT_SPECS): Add entries for cpu_32, cpu_64, tune_32
16268         and tune_64.
16269
16270 2009-04-28  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
16271
16272         * config/arm/arm.c (arm_override_options): Emit error on using
16273         fpa with AAPCS.
16274
16275 2009-04-28  Uros Bizjak  <ubizjak@gmail.com>
16276
16277         PR rtl-optimization/39914
16278         * ira-conflicts.c (ira_build_conflicts): Prohibit call used
16279         registers for allocnos created from user-defined variables only
16280         when not optimizing.
16281
16282 2009-04-28  Richard Guenther  <rguenther@suse.de>
16283
16284         PR middle-end/39937
16285         * fold-const.c (fold_binary): Use distribute_real_division only
16286         on float types.
16287
16288 2009-04-28  Steve Ellcey  <sje@cup.hp.com>
16289
16290         * config.gcc (hppa*64*-*-hpux11*): Set use_gcc_stdint and
16291         add hpux-stdint.h to tm_file.
16292         (hppa[12]*-*-hpux11*): Ditto.
16293         (ia64*-*-hpux*): Ditto.
16294         * config/hpux-stdint.h: New.
16295         * config/ia64/hpux.h (TARGET_OS_CPP_BUILTINS): Set
16296         __STDC_EXT__ for all compiles.
16297         * config/pa/pa-hpux.h: Ditto.
16298         * config/pa/pa-hpux10.h: Ditto.
16299         * config/pa/pa-hpux11.h: Ditto.
16300
16301 2009-04-28  Catherine Moore  <clm@codesourcery.com>
16302
16303         * debug.h (set_name): Add comment.
16304
16305 2009-04-28  Andrew Pinski  <pinskia@gmail.com>
16306
16307         PR target/39929
16308         * config/darwin.c (machopic_gen_offset): Check
16309         currently_expanding_to_rtl if current_ir_type returns IR_GIMPLE.
16310         * config/arm/arm.c (require_pic_register): Likewise.
16311
16312 2009-04-28  Paolo Bonzini  <bonzini@gnu.org>
16313
16314         * config/m32c/m32c.c (TARGET_PROMOTE_FUNCTION_RETURN,
16315         m32c_promote_function_return, TARGET_PROMOTE_PROTOTYPES,
16316         m32c_promote_prototypes): Delete.
16317
16318 2009-04-28  Michael Matz  <matz@suse.de>
16319
16320         PR middle-end/39922
16321         * tree-outof-ssa.c (insert_value_copy_on_edge): Don't convert
16322         constants.
16323
16324 2009-04-28  Richard Guenther  <rguenther@suse.de>
16325
16326         * tree-vect-stmts.c (vect_get_vec_def_for_operand): Fix type error.
16327
16328 2009-04-28  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
16329
16330         * config/arm/arm-cores.def: Add support for arm1156t2f-s.
16331         * doc/invoke.texi (ARM Options): Document support for arm1156t2f-s.
16332         * config/arm/arm-tune.md: Regenerate.
16333
16334 2009-04-28  Alexander Monakov  <amonakov@ispras.ru>
16335
16336         * sel-sched-ir.c (maybe_tidy_empty_bb): Do not attempt to delete a
16337         block if there are complex incoming edges.
16338         (sel_merge_blocks): Remove useless assert.
16339         (sel_redirect_edge_and_branch): Check that edge was redirected.
16340         * sel-sched-ir.h (_eligible_successor_edge_p): Remove assert.
16341         (sel_find_rgns): Delete declaration.
16342         * sel-sched.c (purge_empty_blocks): Attempt to remove first block of
16343         the region when it is not a preheader.
16344
16345 2009-04-28  Uros Bizjak  <ubizjak@gmail.com>
16346
16347         PR c/39323
16348         * config/alpha/elf.h (MAX_OFILE_ALIGNMENT): Sync with elfos.h
16349
16350 2009-04-28  Richard Guenther  <rguenther@suse.de>
16351
16352         * tree.h (SSA_NAME_VALUE): Remove.
16353         (struct tree_ssa_name): Remove value_handle member.
16354         * tree-vrp.c (execute_vrp): Initialize/free the value-handle
16355         array for jump threading.
16356         * tree-ssa-propagate.c (ssa_prop_init): Do not initialize
16357         SSA_NAME_VALUEs.
16358         * print-tree.c (print_node): Do not dump SSA_NAME_VALUEs.
16359         * tree-flow.h (threadedge_initialize_values): Declare.
16360         (threadedge_finalize_values): Likewise.
16361         * tree-ssa-threadedge.c (ssa_name_values): New global variable.
16362         (SSA_NAME_VALUE): Define.
16363         (threadedge_initialize_values): New function.
16364         (threadedge_finalize_values): Likewise.
16365         * tree-ssa-dom.c (ssa_name_values): New global variable.
16366         (SSA_NAME_VALUE): Define.
16367         (tree_ssa_dominator_optimize): Initialize/free the value-handle array.
16368
16369 2009-04-28  Ira Rosen  <irar@il.ibm.com>
16370
16371         * tree-vect-loop-manip.c (vect_create_cond_for_alias_checks):
16372         Use REPORT_VECTORIZED_LOCATIONS instead
16373         REPORT_VECTORIZED_LOOPS.
16374         * tree-vectorizer.c (vect_verbosity_level): Make static.
16375         (vect_loop_location): Rename to vect_location.
16376         (vect_set_verbosity_level): Update comment.
16377         (vect_set_dump_settings): Use REPORT_VECTORIZED_LOCATIONS
16378         and vect_location.
16379         (vectorize_loops): Fix comment. Use REPORT_VECTORIZED_LOCATIONS
16380         and vect_location. Use REPORT_UNVECTORIZED_LOCATIONS
16381         instead REPORT_UNVECTORIZED_LOOPS.
16382         * tree-vectorizer.h (enum vect_def_type): Rename vect_invariant_def
16383         and vect_loop_def to vect_external_def and vect_internal_def.
16384         (enum verbosity_levels): Rename REPORT_VECTORIZED_LOOPS
16385         and REPORT_UNVECTORIZED_LOOPS to REPORT_VECTORIZED_LOCATIONS and
16386         REPORT_UNVECTORIZED_LOCATIONS.
16387         (enum vect_relevant): Update comment. Rename vect_unused_in_loop
16388         and vect_used_in_loop and to vect_unused_in_scope and
16389         vect_used_in_scope.
16390         (STMT_VINFO_RELEVANT_P): Use vect_unused_in_scope.
16391         (vect_verbosity_level): Remove declaration.
16392         (vect_analyze_operations): Likewise.
16393         (vect_analyze_stmt): Declare.
16394         * tree-vect-loop.c (vect_determine_vectorization_factor): Use
16395         REPORT_UNVECTORIZED_LOCATIONS.
16396         (vect_get_loop_niters): Fix indentation.
16397         (vect_analyze_loop_form): Use REPORT_UNVECTORIZED_LOCATIONS.
16398         (vect_analyze_loop_operations): New function.
16399         (vect_analyze_loop): Call vect_analyze_loop_operations instead of
16400         vect_analyze_operations.
16401         (vect_is_simple_reduction): Use new names.
16402         (vectorizable_live_operation, vect_transform_loop): Likewise.
16403         * tree-vect-data-refs.c (vect_check_interleaving): Add a return value
16404         to specify whether the data references can be a part of interleaving
16405         chain.
16406         (vect_analyze_data_ref_dependence): Use new names.
16407         (vect_analyze_data_refs_alignment, vect_analyze_data_refs): Likewise.
16408         (vect_create_addr_base_for_vector_ref): Remove redundant code.
16409         * tree-vect-patterns.c (widened_name_p): Use new names.
16410         (vect_recog_dot_prod_pattern): Likewise.
16411         * tree-vect-stmts.c (vect_stmt_relevant_p): Use new names.
16412         (process_use, vect_mark_stmts_to_be_vectorized,
16413         vect_model_simple_cost, vect_model_store_cost,
16414         vect_get_vec_def_for_operand, vect_get_vec_def_for_stmt_copy,
16415         vectorizable_call, vectorizable_conversion, vectorizable_assignment,
16416         vectorizable_operation, vectorizable_type_demotion,
16417         vectorizable_type_promotion, vectorizable_store, vectorizable_load,
16418         vectorizable_condition): Likewise.
16419         (vect_analyze_operations): Split into vect_analyze_loop_operations
16420         and ...
16421         (vect_analyze_stmt): ... new function.
16422         (new_stmt_vec_info): Use new names.
16423         (vect_is_simple_use): Use new names and fix comment.
16424         * tree-vect-slp.c (vect_get_and_check_slp_defs): Use new names.
16425         (vect_build_slp_tree, vect_analyze_slp, vect_schedule_slp): Likewise.
16426
16427 2009-04-28  Uros Bizjak  <ubizjak@gmail.com>
16428
16429         PR target/39911
16430         * config/i386/i386.c (print_operand) ['Z']: Handle floating point
16431         and integer modes for x87 operands.  Do not ICE for unsupported size,
16432         generate error instead.  Generate error for unsupported operand types.
16433         ['z']: Do not handle HImode memory operands specially.  Warning
16434         for floating-point operands.  Fallthru to 'Z' for unsupported operand
16435         types.  Do not ICE for unsupported size, generate error instead.
16436         (output_387_binary_op): Use %Z to output operands.
16437         (output_fp_compare): Ditto.
16438         (output_387_reg_move): Ditto.
16439
16440 2009-04-28  Ben Elliston  <bje@au.ibm.com>
16441
16442         PR c++/35652
16443         Revert:
16444
16445         2009-03-27  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
16446
16447         * builtins.c (c_strlen): Do not warn here.
16448         * c-typeck.c (build_binary_op): Adjust calls to pointer_int_sum.
16449         * c-common.c (pointer_int_sum): Take an explicit location.
16450         Warn about offsets out of bounds.
16451         * c-common.h (pointer_int_sum): Adjust declaration.
16452
16453 2009-04-27  Ian Lance Taylor  <iant@google.com>
16454
16455         * collect2.c (is_ctor_dtor): Change type of ret field in struct
16456         names to symkind.
16457         * dce.c (run_fast_df_dce): Change type of old_flags to int.
16458         * df-core.c (df_set_flags): Change return type to int.  Change
16459         type of old_flags to int.
16460         (df_clear_flags): Likewise.
16461         * df-scan.c (df_def_record_1): Change 0 to VOIDmode.
16462         (df_get_conditional_uses): Likewise.
16463         * df.h (df_set_flags, df_clear_flags): Update declarations.
16464         * dwarf2out.c (struct indirect_string_node): Change type of form
16465         field to enum dwarf_form.
16466         (AT_string_form): Change return type to enum dwarf_form.
16467         * fixed-value.c (fixed_compare): Add cast to enum type.
16468         * fwprop.c (update_df): Change 0 to VOIDmode.
16469         * gensupport.c: Change 0 to UNKNOWN.
16470         * gimple.h (gimple_cond_code): Add cast to enum type.
16471         * haifa-sched.c (reemit_notes): Add cast to enum type.
16472         * hooks.c (hook_int_void_no_regs): Remove function.
16473         * hooks.h (hook_int_void_no_regs): Remove declaration.
16474         * optabs.c (expand_widen_pattern_expr): Change 0 to VOIDmode.
16475         * predict.c (combine_predictions_for_insn): Add casts to enum type.
16476         * real.c (real_arithmetic): Add cast to enum type.
16477         (real_compare): Likewise.
16478         * target.h (struct gcc_target): Change return type of
16479         branch_target_register_class to enum reg_class.
16480         * target-def.h (TARGET_BRANCH_TARGET_REGISTER_CLASS): Define as
16481         default_branch_target_register_class.
16482         * targhooks.c (default_branch_target_register_class): New function.
16483         * targhooks.h (default_branch_target_register_class): Declare.
16484         * tree-data-ref.c (print_direction_vector): Add cast to enum type.
16485         * tree-vect-data-refs.c (vect_supportable_dr_alignment): Remove
16486         cast to int.
16487         * tree-vect-loop.c (vect_create_epilog_for_reduction): Change 0 to
16488         ERROR_MARK.
16489         * tree-vect-slp.c (vect_build_slp_tree): Change 0 to
16490         vect_uninitialized_def.  Change 0 to ERROR_MARK.
16491         * tree-vect-stmts.c (supportable_widening_operation): Don't
16492         initialize icode1 and icode2.
16493         * tree-vectorizer.h (enum vect_def_type): Add vect_uninitialized_def.
16494         * config/sol2-c.c (cmn_err_length_specs): Change 0 to FMT_LEN_none
16495         and to STD_C89.
16496         (cmn_err_flag_specs): Change 0 to STD_C89.
16497         (cmn_err_char_table): Likewise.
16498         * config/arm/arm.c (get_arm_condition_code): Change type of code
16499         to enum arm_cond_code.
16500         (IWMMXT_BUILTIN): Change 0 to UNKNOWN.
16501         (IWMMXT_BUILTIN2): Likewise.
16502         (neon_builtin_type_bits): Don't define typedef.
16503         (neon_builtin_datum): Change type of bits field to int.
16504         (arm_expand_neon_args): Add cast to enum type.
16505         * config/ia64/ia64.c (tls_symbolic_operand_type): Change 0 to
16506         TLS_MODEL_NONE.
16507         * config/i386/i386.c (bdesc_multi_arg): Change 0 to UNKNOWN.  Add
16508         casts to enum type.
16509         * config/mips/mips.c (LOONGSON_BUILTIN_ALIAS): Change 0 to
16510         MIPS_FP_COND_f.
16511         * config/mips/mips.md (jal_macro): Return enum constant.
16512         (single_insn): Likewise.
16513         * config/rs6000/rs6000.c (bdesc_altivec_preds): Change 0 to
16514         CODE_FOR_nothing.
16515         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
16516         casts to enum type.
16517         * config/s390/s390.c (s390_tune_flags): Change type to int.
16518         (s390_arch_flags): Likewise.
16519         (s390_handle_arch_option): Change flags field of struct pta to int.
16520         * config/s390/s390.h (s390_tune_flags): Update declaration.
16521         (s390_arch_flags): Likewise.
16522         * config/sh/sh.c (prepare_move_operands): Compare
16523         tls_symbolic_operand result with enum constant.
16524         (sh_reorg): Change PUT_MODE to PUT_REG_NOTE_KIND.
16525         (sh_expand_prologue): Add cast to enum type.
16526         (sh_expand_epilogue): Likewise.
16527         (tls_symbolic_operand): Change return type to enum tls_model.
16528         (fpscr_set_from_mem): Add cast to enum type.
16529         (legitimize_pic_address): Compare tls_symbolic_operand result with
16530         enum constant.
16531         (sh_target_reg_class): Change return type to enum reg_class.
16532         * config/sh/sh.h (OVERRIDE_OPTIONS): Change CPU_xxx to
16533         PROCESSOR_xxx.
16534         * config/sh/sh-protos.h (tls_symbolic_operand): Update declaration.
16535         * config/sparc/sparc.c (sparc_override_options): Add cast to enum type.
16536         * config/sparc/sparc.md (empty_delay_slot): Return enum constant.
16537         (pic, calls_alloca, calls_eh_return, leaf_function): Likewise.
16538         (delayed_branch, tls_call_delay): Likewise.
16539         (eligible_for_sibcall_delay): Likewise.
16540         (eligible_for_return_delay): Likewise.
16541         * config/spu/spu.c (expand_builtin_args): Add cast to enum type.
16542         (spu_expand_builtin_1): Likewise.
16543
16544         * c-typeck.c (convert_for_assignment): Issue -Wc++-compat warnings
16545         for all types of conversions.
16546         (output_init_element): Issue -Wc++-compat warning if needed when
16547         initializing a bitfield with enum type.
16548         * c-parser.c (c_parser_expression): Set original_type to
16549         original_type of right hand operand of comma operator.
16550
16551 2009-04-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
16552
16553         * doc/c-tree.texi (Types, Functions, Expression trees): Fix
16554         grammar nits.
16555         * doc/cfg.texi (Maintaining the CFG, Liveness information): Likewise.
16556         * doc/cpp.texi (Standard Predefined Macros)
16557         (Implementation-defined behavior): Likewise.
16558         * doc/extend.texi (Function Attributes, Type Attributes): Likewise.
16559         * doc/gimple.texi (GIMPLE Exception Handling)
16560         (@code{GIMPLE_ASSIGN}): Likewise.
16561         * doc/install.texi (Prerequisites, Configuration, Specific): Likewise.
16562         * doc/invoke.texi (Warning Options, Optimize Options)
16563         (AVR Options, Darwin Options): Likewise.
16564         (Optimize Options): Reformulate -fwhole-program description.
16565         * doc/loop.texi (Lambda): Likewise.
16566         * doc/md.texi (Output Template, Define Constraints)
16567         (Standard Names, Insn Splitting): Likewise.
16568         * doc/options.texi (Option properties): Likewise.
16569         * doc/passes.texi (Tree-SSA passes): Likewise.
16570         * doc/rtl.texi (Side Effects, Assembler, Insns): Likewise.
16571         * doc/tm.texi (Register Classes, Old Constraints, Scalar Return)
16572         (File Names and DBX): Likewise.
16573         * doc/trouble.texi (Incompatibilities): Likewise.
16574
16575 2009-04-27  Trevor Smigiel  <trevor_smigiel@playstation.sony.com>
16576
16577         * spu.c (spu_machine_dependent_reorg): Make sure branch label on hint
16578         instruction is correct.
16579
16580 2009-04-27  Trevor Smigiel  <trevor_smigiel@playstation.sony.com>
16581
16582         Allow non-constant arguments to conversion intrinsics.
16583         * spu-protos.h (exp2_immediate_p, spu_gen_exp2): Declare.
16584         * predicates.md (spu_inv_exp2_operand, spu_exp2_operand): New.
16585         * spu.c (print_operand): Handle 'v' and 'w'.
16586         (exp2_immediate_p, spu_gen_exp2): Define.
16587         * spu-builtins.def (spu_convts, spu_convtu, spu_convtf_0,
16588         spu_convtf_1): Update parameter descriptions.
16589         * spu-builtins.md (spu_csflt, spu_cuflt, spu_cflts, spu_cfltu): Update.
16590         * constraints.md ('v', 'w'): New.
16591         * spu.md (UNSPEC_CSFLT, UNSPEC_CFLTS, UNSPEC_CUFLT, UNSPEC_CFLTU):
16592         Remove.
16593         (i2f, I2F): New define_mode_attr.
16594         (floatsisf2, floatv4siv4sf2, fix_truncsfsi2, fix_truncv4sfv4si2,
16595         floatunssisf2, floatunsv4siv4sf2, fixuns_truncsfsi2,
16596         fixuns_truncv4sfv4si2):  Update to use mode attribute.
16597         (float<mode><i2f>2_mul, float<mode><i2f>2_div,
16598         fix_trunc<mode><f2i>2_mul, floatuns<mode><i2f>2_mul,
16599         floatuns<mode><i2f>2_div, fixuns_trunc<mode><f2i>2_mul): New
16600         patterns for combine.
16601
16602 2009-04-27  Steven Bosscher  <steven@gcc.gnu.org>
16603
16604         * dbgcnt.def (cprop1, cprop2, gcse, jump_bypass): Remove
16605         (cprop, hoist, pre, store_motion): New debug counters.
16606         * tree-pass.h (pass_tracer): Move to list of gimple passes, it
16607         is not an RTL pass anymore.
16608         (pass_profiling): Remove extern decl for pass removed in 2005.
16609         (pass_gcse, pass_jump_bypass): Remove.
16610         * final.c (rest_of_clean_state): Set flag_rerun_cse_after_global_opts
16611         to 0 for clean state.
16612         * toplev.h (flag_rerun_cse_after_global_opts): Add extern declaration.
16613         * cse.c (gate_handle_cse_after_global_opts,
16614         rest_of_handle_cse_after_global_opts): New functions.
16615         (pass_cse_after_global_opts): New pass, does local CSE.
16616         * timevar.def (TV_GCSE, TV_CPROP1, TV_CPROP2, TV_BYPASS): Remove.
16617         (TV_CPROP): New timevar.
16618         * gcse.c (flag_rerun_cse_after_global_opts): New global variable.
16619         (run_jump_opt_after_gcse, max_gcse_regno): Remove global vars.
16620         (gcse_main, recompute_all_luids): Remove.
16621         (compute_hash_table_work): Call max_reg_num instead of reading
16622         max_gcse_regno.
16623         (cprop_jump): Don't set run_jump_opt_after_gcse.
16624         (constprop_register): Always allow to alter jumps.
16625         (cprop_insn): Likewise.
16626         (do_local_cprop): Likewise.
16627         (local_cprop_pass): Likewise.  Return non-zero if something changed.
16628         (cprop): Remove function, fold interesting bits into one_cprop_pass.
16629         (find_implicit_sets): Add note about missed optimization opportunity.
16630         (one_cprop_pass): Rewrite to be "the" CPROP pass, called from the
16631         pass_rtl_cprop execute function.
16632         Don't bother tracking the pass number, each pass gets its own dumpfile
16633         now anyway.
16634         Always allow to alter jumpsand bypass jumps.
16635         (bypass_block): Don't ignore regno >= max_gcse_regno, find_bypass_set
16636         will just find no suitable set.
16637         (pre_edge_insert): Fix dumping, this function is for PRE only.
16638         (one_pre_gcse_pass): Rewrite to be "the" PRE pass, called from the
16639         pass_rtl_pre execute function.
16640         (hoist_code): Return non-zero if something changed.  Keep track of
16641         substitutions and insertions for statistics gathering similar to PRE.
16642         (one_code_hoisting_pass): Rewrite to be "the" code hoisting pass,
16643         called from the pass_rtl_hoist execute function.  Show pass statistics.
16644         (compute_store_table): Use max_reg_num directly instead of using the
16645         formerly global max_gcse_regno.
16646         (build_store_vectors): Likewise.
16647         (replace_store_insn): Fix dumping.
16648         (store_motion): Rename to ...
16649         (one_store_motion_pass): ... this.  Rewrite to be "the" STORE_MOTION
16650         pass, called from the pass_rtl_store_motion execute function.  Keep
16651         track of substitutions and insertions for statistics gathering similar
16652         to PRE.
16653         (bypass_jumps): Remove, fold interesting bits into ...
16654         (one_cprop_pass): ... this.  Rewrite to be "the" CPROP pass, called
16655         from the pass_rtl_cprop execute function.
16656         (gate_handle_jump_bypass, rest_of_handle_jump_bypass,
16657         pass_jump_bypass): Remove.
16658         (gate_handle_gcse, rest_of_handle_gcse): Remove.
16659         (gate_rtl_cprop, execute_rtl_cprop, pass_rtl_cprop): New.
16660         (gate_rtl_pre, execute_rtl_pre, pass_rtl_pre): New.
16661         (gate_rtl_hoist, execute_rtl_hoist, pass_rtl_hoist): New.
16662         (gate_rtl_store_motion, execute_rtl_store_motion,
16663         pass_rtl_store_motion): New.
16664         * common.opt: Remove flag_cse_skip_blocks, adjust documentation to
16665         make it clear that -fcse-skip-blocks is a no-op for backward compat.
16666         * passes.c (init_optimization_passes): Remove pass_gcse and
16667         pass_jump_bypass.  Schedule cprop, pre, hoist, cprop, store_motion,
16668         and cse_after_global_opts in place of pass_gcse.  Schedule cprop
16669         instead of pass_jump_bypass.
16670
16671 2009-04-27  Richard Guenther  <rguenther@suse.de>
16672
16673         PR middle-end/39928
16674         * gimplify.c (gimplify_expr): If we are required to create
16675         a temporary make sure it ends up as register.
16676
16677 2009-04-27  H.J. Lu  <hongjiu.lu@intel.com>
16678
16679         PR target/39903
16680         * config/i386/i386.c (construct_container): Don't call
16681         gen_reg_or_parallel with BLKmode on X86_64_SSE_CLASS,
16682         X86_64_SSESF_CLASS and X86_64_SSEDF_CLASS.
16683
16684 2009-04-27  Michael Matz  <matz@suse.de>
16685
16686         * ssaexpand.h (struct ssaexpand): Member 'values' is a bitmap.
16687         (get_gimple_for_ssa_name): Adjust, lookup using SSA_NAME_DEF_STMT.
16688         * tree-ssa-live.h: (find_replaceable_exprs): Return a bitmap.
16689         (dump_replaceable_exprs): Take a bitmap.
16690         * cfgexpand.c (gimple_cond_pred_to_tree): Handle bitmap instead of
16691         array.
16692         (expand_gimple_basic_block): Likewise.
16693         * tree-ssa-ter.c (struct temp_expr_table_d): Make
16694         replaceable_expressions member a bitmap.
16695         (free_temp_expr_table): Pass back and deal with bitmap, not gimple*.
16696         (mark_replaceable): Likewise.
16697         (find_replaceable_in_bb, dump_replaceable_exprs): Likewise.
16698         * tree-outof-ssa.c (remove_ssa_form): 'values' is a bitmap.
16699
16700 2009-04-27  Richard Guenther  <rguenther@suse.de>
16701
16702         * tree-cfg.c (remove_useless_stmts): Verify stmts afterwards.
16703         (verify_stmts): Dispatch to gimple/type verification code.
16704         * tree-inline.c (remap_gimple_op_r): Work around C++ FE
16705         issue with call argument types.
16706
16707 2009-04-27  Michael Matz  <matz@suse.de>
16708
16709         * tree-into-ssa.c (regs_to_rename, mem_syms_to_rename): Remove.
16710         (init_update_ssa, delete_update_ssa, update_ssa): Remove references
16711         to above.
16712
16713 2009-04-27  Richard Sandiford  <rdsandiford@googlemail.com>
16714             Eric Botcazou  <ebotcazou@adacore.com>
16715
16716         * resource.c (find_basic_block): Use BLOCK_FOR_INSN to look up
16717         a label's basic block.
16718         (mark_target_live_regs): Tidy and rework obsolete comments.
16719         Change back DF problem to LIVE.  If a label starts a basic block,
16720         assume that all registers that used to be live then still are.
16721         (init_resource_info): If a label starts a basic block, set its
16722         BLOCK_FOR_INSN accordingly.
16723         (fini_resource_info): Undo the setting of BLOCK_FOR_INSN.
16724
16725 2009-04-27  Richard Guenther  <rguenther@suse.de>
16726
16727         * tree-flow-inline.h (function_ann): Remove.
16728         (get_function_ann): Likewise.
16729         * tree-dfa.c (create_function_ann): Remove.
16730         * tree-flow.h (struct static_var_ann_d): Remove.
16731         (struct function_ann_d): Likewise.
16732         (union tree_ann_d): Remove fdecl member.
16733         (function_ann_t): Remove.
16734         (function_ann, get_function_ann, create_function_ann): Remove
16735         declarations.
16736
16737 2009-04-27  Uros Bizjak  <ubizjak@gmail.com>
16738
16739         * config/alpha/alpha.c (code_for_builtin): Declare as enum insn_code.
16740
16741 2009-04-27  Jan Hubicka  <jh@suse.cz>
16742
16743         * ipa-pure-const.c (struct funct_state_d): New fields
16744         state_previously_known, looping_previously_known; remove
16745         state_set_in_source.
16746         (analyze_function): Use new fields.
16747         (propagate): Avoid assumption that state_set_in_source imply
16748         nonlooping.
16749
16750         * tree-ssa-loop-niter.c (finite_loop_p): New function.
16751         * tree-ssa-loop-ivcanon.c (empty_loop_p): Use it.
16752         * cfgloop.h (finite_loop_p): Declare.
16753
16754 2009-04-26  Michael Matz  <matz@suse.de>
16755
16756         * tree-flow.h (tree_ann_common_d): Remove aux and value_handle members.
16757
16758 2009-04-26  Michael Matz  <matz@suse.de>
16759
16760         * tree-pass.h (pass_del_ssa, pass_mark_used_blocks,
16761         pass_free_cfg_annotations, pass_free_datastructures): Remove decls.
16762         * gimple-low.c (mark_blocks_with_used_vars, mark_used_blocks,
16763         pass_mark_used_blocks): Remove.
16764         * tree-optimize.c (pass_free_datastructures,
16765         execute_free_cfg_annotations, pass_free_cfg_annotations): Remove.
16766         * passes.c (init_optimization_passes): Don't call
16767         pass_mark_used_blocks, remove dead code.
16768
16769 2009-04-26  H.J. Lu  <hongjiu.lu@intel.com>
16770
16771         * tree-outof-ssa.c (rewrite_trees): Add ATTRIBUTE_UNUSED.
16772         * tree-ssa-live.h (register_ssa_partition): Likewise.
16773
16774 2009-04-26  Michael Matz  <matz@suse.de>
16775
16776         Expand from SSA.
16777         * builtins.c (fold_builtin_next_arg): Handle SSA names.
16778         * tree-ssa-copyrename.c (rename_ssa_copies): Use ssa_name() directly.
16779         * tree-ssa-coalesce.c (create_outofssa_var_map): Mark only useful
16780         SSA names.
16781         (compare_pairs): Swap cost comparison.
16782         (coalesce_ssa_name): Don't use change_partition_var.
16783         * tree-nrv.c (struct nrv_data): Add modified member.
16784         (finalize_nrv_r): Set it.
16785         (tree_nrv): Use it to update statements.
16786         (pass_nrv): Require PROP_ssa.
16787         * tree-mudflap.c (mf_decl_cache_locals,
16788         mf_build_check_statement_for): Use make_rename_temp.
16789         (pass_mudflap_2): Require PROP_ssa, run ssa update at finish.
16790         * alias.c (find_base_decl): Handle SSA names.
16791         * emit-rtl (set_reg_attrs_for_parm): Make non-static.
16792         (component_ref_for_mem_expr): Don't leak SSA names into RTL.
16793         * rtl.h (set_reg_attrs_for_parm): Declare.
16794         * tree-optimize.c (pass_cleanup_cfg_post_optimizing): Rename
16795         to "optimized", remove unused locals at finish.
16796         (execute_free_datastructures): Make global, call
16797         delete_tree_cfg_annotations.
16798         (execute_free_cfg_annotations): Don't call
16799         delete_tree_cfg_annotations.
16800
16801         * ssaexpand.h: New file.
16802         * expr.c (toplevel): Include ssaexpand.h.
16803         (expand_assignment): Handle SSA names the same as register variables.
16804         (expand_expr_real_1): Expand SSA names.
16805         * cfgexpand.c (toplevel): Include ssaexpand.h.
16806         (SA): New global variable.
16807         (gimple_cond_pred_to_tree): Fold TERed comparisons into predicates.
16808         (SSAVAR): New macro.
16809         (set_rtl): New helper function.
16810         (add_stack_var): Deal with SSA names, use set_rtl.
16811         (expand_one_stack_var_at): Likewise.
16812         (expand_one_stack_var): Deal with SSA names.
16813         (stack_var_size_cmp): Use code (SSA_NAME / DECL) as tie breaker
16814         before unique numbers.
16815         (expand_stack_vars): Use set_rtl.
16816         (expand_one_var): Accept SSA names, add asserts for them, feed them
16817         to above subroutines.
16818         (expand_used_vars): Expand all partitions (without default defs),
16819         then only the local decls (ignoring those expanded already).
16820         (expand_gimple_cond): Remove edges when jumpif() expands an
16821         unconditional jump.
16822         (expand_gimple_basic_block): Don't clear EDGE_EXECUTABLE here,
16823         or remove abnormal edges.  Ignore insns setting the LHS of a TERed
16824         SSA name.
16825         (gimple_expand_cfg): Call into rewrite_out_of_ssa, initialize
16826         members of SA; deal with PARM_DECL partitions here; expand
16827         all PHI nodes, free tree datastructures and SA.  Commit instructions
16828         on edges, clear EDGE_EXECUTABLE and remove abnormal edges here.
16829         (pass_expand): Require and destroy PROP_ssa, verify SSA form, flow
16830         info and statements at start, collect garbage at finish.
16831         * tree-ssa-live.h (struct _var_map): Remove partition_to_var member.
16832         (VAR_ANN_PARTITION) Remove.
16833         (change_partition_var): Don't declare.
16834         (partition_to_var): Always return SSA names.
16835         (var_to_partition): Only accept SSA names.
16836         (register_ssa_partition): Only check argument.
16837         * tree-ssa-live.c (init_var_map): Don't allocate partition_to_var
16838         member.
16839         (delete_var_map): Don't free it.
16840         (var_union): Only accept SSA names, simplify.
16841         (partition_view_init): Mark only useful SSA names as used.
16842         (partition_view_fini): Only deal with SSA names.
16843         (change_partition_var): Remove.
16844         (dump_var_map): Use ssa_name instead of partition_to_var member.
16845         * tree-ssa.c (delete_tree_ssa): Don't remove PHI nodes on RTL
16846         basic blocks.
16847         * tree-outof-ssa.c (toplevel): Include ssaexpand.h and expr.h.
16848         (struct _elim_graph): New member const_dests; nodes member vector of
16849         ints.
16850         (set_location_for_edge): New static helper.
16851         (create_temp): Remove.
16852         (insert_partition_copy_on_edge, insert_part_to_rtx_on_edge,
16853         insert_value_copy_on_edge, insert_rtx_to_part_on_edge): New functions.
16854         (new_elim_graph): Allocate const_dests member.
16855         (clean_elim_graph): Truncate const_dests member.
16856         (delete_elim_graph): Free const_dests member.
16857         (elim_graph_size): Adapt to new type of nodes member.
16858         (elim_graph_add_node): Likewise.
16859         (eliminate_name): Likewise.
16860         (eliminate_build): Don't take basic block argument, deal only with
16861         partition numbers, not variables.
16862         (get_temp_reg): New static helper.
16863         (elim_create): Use it, deal with RTL temporaries instead of trees.
16864         (eliminate_phi): Adjust all calls to new signature.
16865         (assign_vars, replace_use_variable, replace_def_variable): Remove.
16866         (rewrite_trees): Only do checking.
16867         (edge_leader, stmt_list, leader_has_match, leader_match): Remove.
16868         (same_stmt_list_p, identical_copies_p, identical_stmt_lists_p,
16869         init_analyze_edges_for_bb, fini_analyze_edges_for_bb,
16870         contains_tree_r, MAX_STMTS_IN_LATCH,
16871         process_single_block_loop_latch, analyze_edges_for_bb,
16872         perform_edge_inserts): Remove.
16873         (expand_phi_nodes): New global function.
16874         (remove_ssa_form): Take ssaexpand parameter.  Don't call removed
16875         functions, initialize new parameter, remember partitions having a
16876         default def.
16877         (finish_out_of_ssa): New global function.
16878         (rewrite_out_of_ssa): Make global.  Adjust call to remove_ssa_form,
16879         don't reset in_ssa_p here, don't disable TER when mudflap.
16880         (pass_del_ssa): Remove.
16881         * tree-flow.h (struct var_ann_d): Remove out_of_ssa_tag and
16882         partition members.
16883         (execute_free_datastructures): Declare.
16884         * Makefile.in (SSAEXPAND_H): New variable.
16885         (tree-outof-ssa.o, expr.o, cfgexpand.o): Depend on SSAEXPAND_H.
16886         * basic-block.h (commit_one_edge_insertion): Declare.
16887         * passes.c (init_optimization_passes): Move pass_nrv and
16888         pass_mudflap2 before pass_cleanup_cfg_post_optimizing, remove
16889         pass_del_ssa, pass_free_datastructures, pass_free_cfg_annotations.
16890         * cfgrtl.c (commit_one_edge_insertion): Make global, don't declare.
16891         (redirect_branch_edge): Deal with super block when expanding, split
16892         out jump patching itself into ...
16893         (patch_jump_insn): ... here, new static helper.
16894
16895 2009-04-26  Michael Matz  <matz@suse.de>
16896
16897         * tree-ssa-copyrename.c (rename_ssa_copies): Don't iterate
16898         beyond num_ssa_names.
16899         * tree-ssa-ter.c (free_temp_expr_table): Likewise.
16900         * tree-ssa-coalesce.c (create_outofssa_var_map): Likewise.
16901
16902 2009-04-26  Jakub Jelinek  <jakub@redhat.com>
16903
16904         PR inline-asm/39543
16905         * fwprop.c (forward_propagate_asm): New function.
16906         (forward_propagate_and_simplify): Propagate also into __asm, if it
16907         doesn't increase the number of referenced registers.
16908
16909         PR c/39889
16910         * stmt.c (warn_if_unused_value): Look through NON_LVALUE_EXPR.
16911
16912 2009-04-26  Jakub Jelinek  <jakub@redhat.com>
16913
16914         * tree-nested.c (get_nonlocal_vla_type): If not optimizing, call
16915         note_nonlocal_vla_type for nonlocal VLAs.
16916         (note_nonlocal_vla_type, note_nonlocal_block_vlas,
16917         contains_remapped_vars, remap_vla_decls): New functions.
16918         (convert_nonlocal_reference_stmt): If not optimizing, call
16919         note_nonlocal_block_vlas on GIMPLE_BIND block vars.
16920         (nesting_copy_decl): Return {VAR,PARM,RESULT}_DECL unmodified
16921         if it wasn't found in var_map.
16922         (finalize_nesting_tree_1): Call remap_vla_decls.  If outermost
16923         GIMPLE_BIND doesn't have gimple_bind_block, chain debug_var_chain
16924         to BLOCK_VARS (DECL_INITIAL (root->context)) instead of calling
16925         declare_vars.
16926         * gimplify.c (nonlocal_vlas): New variable.
16927         (gimplify_var_or_parm_decl): Add debug VAR_DECLs for non-local
16928         referenced VLAs.
16929         (gimplify_body): Create and destroy nonlocal_vlas.
16930
16931         * dwarf2out.c (loc_descr_plus_const): New function.
16932         (build_cfa_aligned_loc, tls_mem_loc_descriptor,
16933         mem_loc_descriptor, loc_descriptor_from_tree_1,
16934         descr_info_loc, gen_variable_die): Use it.
16935
16936         * tree.h (DECL_BY_REFERENCE): Note that it is also valid for
16937         !TREE_STATIC VAR_DECLs.
16938         * dwarf2out.c (loc_by_reference, gen_decl_die): Handle
16939         DECL_BY_REFERENCE on !TREE_STATIC VAR_DECLs.
16940         (gen_variable_die): Likewise.  Don't look at TREE_PRIVATE if
16941         DECL_BY_REFERENCE is valid.
16942         * dbxout.c (DECL_ACCESSIBILITY_CHAR): Don't look at TREE_PRIVATE
16943         for PARM_DECLs, RESULT_DECLs or !TREE_STATIC VAR_DECLs.
16944         * tree-nested.c (get_nonlocal_debug_decl, get_local_debug_decl):
16945         Copy DECL_BY_REFERENCE.
16946         (struct nesting_copy_body_data): New type.
16947         (nesting_copy_decl): New function.
16948         (finalize_nesting_tree_1): Remap types of debug_var_chain variables,
16949         if they have variable length.
16950
16951 2009-04-26  Michael Matz  <matz@suse.de>
16952
16953         * tree-sra.c (sra_build_assignment): Don't use into_ssa mode,
16954         mark new temporaries for renaming.
16955
16956 2009-04-26  Joseph Myers  <joseph@codesourcery.com>
16957
16958         PR c/39581
16959         * c-decl.c (global_bindings_p): Return negative value.
16960         (c_variable_size): New.  Based on variable_size from
16961         stor-layout.c.
16962         (grokdeclarator): Call c_variable_size not variable_size.
16963
16964 2009-04-26  Uros Bizjak  <ubizjak@gmail.com>
16965
16966         * config/i386/i386.c (print_operand) ['z']: Fix typo.
16967
16968 2009-04-26  Kai Tietz  <kai.tietz@onevision.com>
16969
16970         * config/i386/mingw-w64.h (STANDARD_INCLUDE_DIR):
16971         Redefine it to just use mingw/include.
16972         (ASM_SPEC): Rules for -m32 and -m64.
16973         (LINK_SPEC): Use Likewise.
16974         (SPEC_32): New define.
16975         (SPEC_64): Likewise.
16976         (SUB_LINK_SPEC): Likewise.
16977         (MULTILIB_DEFAULTS): New define.
16978         * config/i386/t-mingw-w64 (MULTILIB_OPTIONS):
16979         Add multilib options.
16980         (MULTILIB_DIRNAMES): Likewise.
16981         (MULTILIB_OSDIRNAMES): Likewise.
16982         (LIBGCC): Likewise.
16983         (INSTALL_LIBGCC): Likewise.
16984
16985 2009-04-26  Joseph Myers  <joseph@codesourcery.com>
16986
16987         PR c/39556
16988         * c-tree.h (enum c_inline_static_type): New.
16989         (record_inline_static): Declare.
16990         * c-decl.c (struct c_inline_static, c_inline_statics,
16991         record_inline_static, check_inline_statics): New.
16992         (pop_file_scope): Call check_inline_statics.
16993         (start_decl): Call record_inline_static instead of pedwarning
16994         directly for static in inline function.
16995         * c-typeck.c (build_external_ref): Call record_inline_static
16996         instead of pedwarning directly for static referenced in inline
16997         function.
16998
16999 2009-04-26  Steven Bosscher  <steven@gcc.gnu.org>
17000
17001         * df-scan.c (df_insn_rescan): Salvage insn's LUID if the insn is
17002         not new but only being rescanned.
17003         * gcse.c (uid_cuid, max_uid, INSN_CUID, max_cuid, struct reg_set,
17004         reg_set_table, REG_SET_TABLE_SLOP, reg_set_in_block,
17005         alloc_reg_set_mem, free_reg_set_mem, record_one_set,
17006         record_set_info, compute_set, grealloc): Remove.
17007         (recompute_all_luids): New function.
17008         (gcse_main): Don't compute sets, and don't do related memory
17009         allocations/free-ing.  If something changed before the end of the
17010         pass, update LUIDs using recompute_all_luids.
17011         (alloc_gcse_mem): Don't compute LUIDs.  Don't allocate reg_set memory.
17012         (free_gcse_mem): Don't free it either.
17013         (oprs_unchanged_p, load_killed_in_block, record_last_reg_set_info):
17014         Use the df insn LUIDs.
17015         (load_killed_in_block): Likewise.
17016         (compute_hash_table_work): Don't compute reg_set_in_block.
17017         (compute_transp): Use DF_REG_DEF_CHAINs.
17018         (local_cprop_pass): Don't use compute_sets and related functions.
17019         (one_cprop_pass, pre_gcse, one_pre_gcse_pass, one_code_hoisting_pass):
17020         Use get_max_uid() instead of max_cuid.
17021         (insert_insn_end_basic_block, pre_insert_copy_insn,
17022         update_ld_motion_stores): Don't try to
17023         keep reg_set tables up to date.
17024         (pre_insert_copies): Use df insn LUIDs.
17025         (sbitmap pre_redundant_insns): Replace with uses of INSN_DELETED_P.
17026         (reg_set_info): Don't use extra bitmap argument.
17027         (compute_store_table): Don't compute reg_set_in_block.  Use DF scan
17028         information to compute regs_set_in_block.
17029         (free_store_memory, store_motion): Don't nullify reg_set_in_block.
17030         (bypass_jumps): Don't use compute_sets and friends.
17031
17032 2009-04-26  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
17033
17034         PR testsuite/39710
17035         * opts.c (undocumented_msg): Do not leave blank even with
17036         ENABLE_CHECKING.
17037
17038 2009-04-25  Joseph Myers  <joseph@codesourcery.com>
17039
17040         * c-decl.c (build_enumerator): Allow values folding to integer
17041         constants but not integer constant expressions with a pedwarn if
17042         pedantic.
17043
17044 2009-04-25  Joseph Myers  <joseph@codesourcery.com>
17045
17046         PR c/39582
17047         * c-typeck.c (c_expr_sizeof_type): Create a C_MAYBE_CONST_EXPR
17048         with non-null C_MAYBE_CONST_EXPR_PRE if size of a variable-length
17049         type is an integer constant.
17050
17051 2009-04-25  Uros Bizjak  <ubizjak@gmail.com>
17052
17053         PR target/39897
17054         * config/i386/i386.c (print_operand) ['z']: Revert handling of
17055         HImode operands.
17056
17057 2009-04-25  Joseph Myers  <joseph@codesourcery.com>
17058
17059         PR c/39564
17060         * c-decl.c (grokdeclarator): Diagnose declarations of functions
17061         with variably modified return type and no storage class
17062         specifiers, except for the case of nested functions.  Distinguish
17063         extern declarations of functions with variably modified return
17064         types from those of objects with variably modified types.
17065
17066 2009-04-25  Jan Hubicka  <jh@suse.cz>
17067
17068         * tree.c (list_equal_p): New function.
17069         * tree.h (list_equal_p): Declare.
17070         * coretypes.h (edge_def, edge, const_edge, basic_block_def
17071         basic_block_def, basic_block, const_basic_block): New.
17072         * tree-eh.c (make_eh_edge): EH edges are not abnormal.
17073         (redirect_eh_edge): New function.
17074         (make_eh_edge_update_phi): EH edges are not abnormal.
17075         * except.c: Include tree-flow.h.
17076         (list_match): New function.
17077         (eh_region_replaceable_by_p): New function.
17078         (replace_region): New function.
17079         (hash_type_list): New function.
17080         (hash_eh_region): New function.
17081         (eh_regions_equal_p): New function.
17082         (merge_peers): New function.
17083         (remove_unreachable_regions): Verify EH tree when checking;
17084         merge peers.
17085         (copy_eh_region_1): New function.
17086         (copy_eh_region): New function.
17087         (push_reachable_handler): New function.
17088         (build_post_landing_pads, dw2_build_landing_pads): Be ready for
17089         regions without label but with live RESX.
17090         * except.h (redirect_eh_edge_to_label): New.
17091         * tree-flow.h (redirect_eh_edge): New.
17092         * coretypes.h (edge_def, edge, const_edge, basic_block_def
17093         basic_block_def, basic_block, const_basic_block): Remove.
17094         * Makefile.in (except.o): Add dependency on tree-flow.h
17095         * tree-cfg.c (gimple_redirect_edge_and_branch): Handle EH edges.
17096         * basic-block.h (edge, const_edge, basic_block, const_basic_block):
17097         Remove.
17098
17099 2009-04-25  Eric Botcazou  <ebotcazou@adacore.com>
17100
17101         PR bootstrap/39645
17102         * config/sparc/sparc.c (sparc_gimplify_va_arg): Set TREE_ADDRESSABLE
17103         on the destination of memcpy.
17104
17105 2009-04-25  Paolo Bonzini  <bonzini@gnu.org>
17106
17107         * doc/tm.texi (REGNO_OK_FOR_BASE_P, REGNO_MODE_OK_FOR_BASE_P,
17108         REGNO_MODE_OK_FOR_REG_BASE_P, REGNO_MODE_CODE_OK_FOR_BASE_P,
17109         REGNO_OK_FOR_INDEX_P): Mention strict/nonstrict difference.
17110
17111 2009-04-25  Jan Hubicka  <jh@suse.cz>
17112
17113         * tree-eh.c (tree_remove_unreachable_handlers): Handle shared labels.
17114         (tree_empty_eh_handler_p): Allow non-EH predecestors; allow region
17115         to be reached by different label than left.
17116         (update_eh_edges): Update comment; remove edge_to_remove if possible
17117         and return true if suceeded.
17118         (cleanup_empty_eh): Accept sharing map; handle shared regions.
17119         (cleanup_eh): Compute sharing map.
17120         * except.c (remove_eh_handler_and_replace): Add argument if we should
17121         update regions.
17122         (remove_unreachable_regions): Update for label sharing.
17123         (label_to_region_map): Likewise.
17124         (get_next_region_sharing_label): New function.
17125         (remove_eh_handler_and_replace): Add update_catch_try parameter; update
17126         prev_try pointers.
17127         (remove_eh_handler): Update.
17128         (remove_eh_region_and_replace_by_outer_of): New function.
17129         * except.h (struct eh_region): Add next_region_sharing_label.
17130         (remove_eh_region_and_replace_by_outer_of,
17131         get_next_region_sharing_label): Declare.
17132         * tree-cfgcleanup.c (tree_forwarder_block_p): Simplify.
17133
17134 2009-04-25  Jan Hubicka  <jh@suse.cz>
17135
17136         * tree-cfg.c (split_critical_edges): Split also edges where we can't
17137         insert code even if they are not critical.
17138
17139 2009-04-25  Jan Hubicka  <jh@suse.cz>
17140
17141         * tree-cfg.c (gimple_can_merge_blocks_p): EH edges are unmergable.
17142         (gimple_can_remove_branch_p): EH edges won't remove branch by
17143         redirection.
17144         * tree-inline.c (update_ssa_across_abnormal_edges): Do handle
17145         updating of non-abnormal EH edges.
17146         * tree-cfg.c (gimple_can_merge_blocks_p): EH edges are unmergable.
17147         (gimple_can_remove_branch_p): EH edges are unremovable by redirection.
17148         (split_critical_edges): Split also edges where emitting code on them
17149         will lead to splitting later.
17150
17151 2009-04-25  Uros Bizjak  <ubizjak@gmail.com>
17152             H.J. Lu  <hongjiu.lu@intel.com>
17153
17154         PR target/39590
17155         * configure.ac (HAVE_AS_IX86_FILDQ): On x86 targets check whether
17156         the configured assembler supports fildq and fistpq mnemonics.
17157         (HAVE_AS_IX86_FILDS): Rename from HAVE_GAS_FILDS_FISTS.
17158         * configure: Regenerated.
17159         * config.in: Ditto.
17160
17161         * config/i386/i386.c (print_operand): Handle 'Z'.
17162         ['z']: Remove handling of special fild/fist suffixes.
17163         (output_fix_trunc): Use '%Z' to output suffix of fist{,p,tp} insn.
17164         * config/i386/i386.md (*floathi<mode>2_i387): Use '%Z' to output
17165         suffix of fild insn.
17166         (*floatsi<mode>2_vector_mixed): Ditto.
17167         (*float<SSEMODEI24:mode><MODEF:mode>2_mixed_interunit): Ditto.
17168         (*float<SSEMODEI24:mode><MODEF:mode>2_mixed_nointerunit): Ditto.
17169         (*float<SSEMODEI24:mode><X87MODEF:mode>2_i387_with_temp): Ditto.
17170         (*float<SSEMODEI24:mode><X87MODEF:mode>2_i387): Ditto.
17171         * config/i386/gas.h (GAS_MNEMONICS): Remove.
17172
17173 2009-04-25  Ben Elliston  <bje@au.ibm.com>
17174
17175         * genrecog.c (validate_pattern): Do not warn for VOIDmode CALLs as
17176         the source of a set operation.
17177
17178 2009-04-25  Anatoly Sokolov  <aesok@post.ru>
17179
17180         * target.h (struct gcc_target): Add case_values_threshold field.
17181         * target-def.h (TARGET_CASE_VALUES_THRESHOLD): New.
17182         (TARGET_INITIALIZER): Use TARGET_CASE_VALUES_THRESHOLD.
17183         * targhooks.c (default_case_values_threshold): New function.
17184         * targhooks.h (default_case_values_threshold): Declare function.
17185         * stmt.c (expand_case): Use case_values_threshold target hook.
17186         * expr.h (case_values_threshold): Remove declartation.
17187         * expr.c (case_values_threshold): Remove function.
17188         * doc/tm.texi (CASE_VALUES_THRESHOLD): Revise documentation.
17189
17190         * config/avr/avr.h (CASE_VALUES_THRESHOLD): Remove macro.
17191         * config/avr/avr.c (TARGET_CASE_VALUES_THRESHOLD): Define macro.
17192         (avr_case_values_threshold): Declare as static.
17193         * config/avr/avr-protos.h (avr_case_values_threshold): Remove.
17194
17195         * config/avr/mn10300.h (CASE_VALUES_THRESHOLD): Remove macro.
17196         * config/avr/mn10300.c (TARGET_CASE_VALUES_THRESHOLD): Define macro.
17197         (mn10300_case_values_threshold): New function.
17198
17199 2009-04-24  H.J. Lu  <hongjiu.lu@intel.com>
17200
17201         * ira.c (setup_cover_and_important_classes): Add enum cast.
17202
17203 2009-04-24  Vladimir Makarov  <vmakarov@redhat.com>
17204
17205         * genpreds.c (write_enum_constraint_num): Output definition of
17206         CONSTRAINT_NUM_DEFINED_P macro.
17207         * ira.c (setup_cover_and_important_classes): Use
17208         CONSTRAINT_NUM_DEFINED_P instead of CONSTRAINT__LIMIT in #ifdef.
17209
17210 2009-04-24  DJ Delorie  <dj@redhat.com>
17211
17212         * config/sh/sh.h (LIBGCC2_DOUBLE_TYPE_SIZE): Test
17213         __SH2A_SINGLE_ONLY__ also.
17214
17215 2009-04-24  Steve Ellcey  <sje@cup.hp.com>
17216
17217         * config/ia64/ia64.md (movfs_internal): Allow flt constants.
17218         (movdf_internal): Ditto.
17219         * config/ia64/ia64.c (ia64_legitimate_constant_p): Allow
17220         SFmode and DFmode constants.
17221         (ia64_print_operand): Add 'G' format for printing
17222         floating point constants.
17223
17224 2009-04-24  Richard Guenther  <rguenther@suse.de>
17225
17226         * tree-vrp.c (extract_range_from_binary_expr): Handle overflow
17227         from unsigned additions.
17228
17229 2009-04-24  Joseph Myers  <joseph@codesourcery.com>
17230
17231         * c-typeck.c (set_init_index): Allow array designators that are
17232         not integer constant expressions with a pedwarn if pedantic.
17233
17234 2009-04-24  Bernd Schmidt  <bernd.schmidt@analog.com>
17235
17236         * simplify-rtx.c (simplify_binary_operation_1, case AND): Result is
17237         zero if no overlap in nonzero bits between the operands.
17238
17239 2009-04-24  Ian Lance Taylor  <iant@google.com>
17240
17241         * combine.c (record_value_for_reg): Change 0 to VOIDmode, twice.
17242         (record_dead_and_set_regs): Likewise.
17243         * df.h (struct df_mw_hardreg): Change flags field to int.
17244         (struct df_base_ref): Likewise.
17245         (struct df): Change changeable_flags field to int.
17246         * df-scan.c (df_defs_record): Change clobber_flags to int.
17247         * dwarf2.h (enum dwarf_tag): Make lo_user and hi_user values enum
17248         constants rather than #define macros.
17249         (enum dwarf_attribute, enum dwarf_location_atom): Likewise.
17250         (enum dwarf_type, enum dwarf_endianity_encoding): Likewise.
17251         (enum dwarf_calling_convention): Likewise.
17252         (enum dwarf_line_number_x_ops): Likewise.
17253         (enum dwarf_call_frame_info): Likewise.
17254         (enum dwarf_source_language): Likewise.
17255         * dwarf2out.c (int_loc_descriptor): Add cast to enum type.
17256         (add_calling_convention_attribute): Likewise.
17257         * fold-const.c (fold_undefer_overflow_warnings): Add cast to enum type.
17258         (combine_comparisons): Change compcode to int.  Add cast to enum type.
17259         * genrecog.c (maybe_both_true_2): Change c to int.
17260         (write_switch): Likewise.  Add cast to enum type.
17261         * gimplify.c (gimplify_omp_for): Handle return values from
17262         gimplify_expr using MIN rather than bitwise or.
17263         (gimplify_expr): Add cast to enum type.
17264         * ipa-prop.c (update_jump_functions_after_inlining): Change
17265         IPA_BOTTOM to IPA_JF_UNKNOWN.
17266         * ira.c (setup_class_subset_and_memory_move_costs): Change mode to int.
17267         Add casts to enum type.
17268         (setup_cover_and_important_classes): Change cl to int.  Add casts
17269         to enum type.
17270         (setup_class_translate): Change cl and mode to int.
17271         (ira_init_once): Change mode to int.
17272         (free_register_move_costs): Likewise.
17273         (setup_prohibited_mode_move_regs): Add casts to enum type.
17274         * langhooks.c (add_builtin_function_common): Rework assertion that
17275         value fits bitfield.
17276         * mcf.c (add_fixup_edge): Change type parameter to edge_type.
17277         * omega.c (omega_do_elimination): Avoid math on enum types.
17278         * optabs.c (expand_vec_shift_expr): Remove casts to int.
17279         * opts.c (set_debug_level): Change 2 to enum constant.  Use new
17280         int local to handle integral_argment value.
17281         * regmove.c (try_auto_increment): Change PUT_MODE to
17282         PUT_REG_NOTE_KIND.
17283         * reload.c (push_secondary_reload): Add casts to enum type.
17284         (secondary_reload_class, find_valid_class): Likewise.
17285         * reload1.c (emit_input_reload_insns): Likewise.
17286         * rtl.h (NOTE_VAR_LOCATION_STATUS): Likewise.
17287         * sel-sched.c (init_hard_regs_data): Change cur_mode to int.
17288         * sel-sched-ir.c (hash_with_unspec_callback): Change 0 to enum
17289         constant.
17290         * tree.c (build_common_builtin_nodes): Add casts to enum type.
17291         * tree-complex.c (complex_lattice_t): Typedef to int rather than
17292         enum type.
17293         (expand_complex_libcall): Add casts to enum type.
17294         * tree-into-ssa.c (get_ssa_name_ann): Change 0 to enum constant.
17295         * tree-vect-loop.c (vect_model_reduction_cost): Compare reduc_code
17296         with ERROR_MARK, not NUM_TREE_CODES.
17297         (vect_create_epilog_for_reduction): Likewise.
17298         (vectorizable_reduction): Don't initialize epiloc_reduc_code.
17299         When not using it, set it to ERROR_MARK rather than NUM_TREE_CODES.
17300         * tree-vect-patterns.c (vect_pattern_recog_1): Change vec_mode to
17301         enum machine_mode.
17302         * tree-vect-stmts.c (new_stmt_vec_info): Change 0 to
17303         vect_unused_in_loop.  Change 0 to loop_vect.
17304         * tree-vectorizer.c (vect_set_verbosity_level): Add casts to enum type.
17305         * var-tracking.c (get_init_value): Change return type to enum
17306         var_init_status.
17307         * vec.h (DEF_VEC_FUNC_P) [iterate]: Cast 0 to type T.
17308         * config/arm/arm.c (fp_model_for_fpu): Change to array to enum
17309         arm_fp_model.
17310         (arm_override_options): Add casts to enum type.
17311         (arm_emit_tls_decoration): Likewise.
17312         * config/i386/i386.c (ix86_function_specific_restore): Add casts
17313         to enum type.
17314         * config/i386/i386-c.c (ix86_pragma_target_parse): Likewise.
17315         * config/ia64/ia64.c (ia64_expand_compare): Change magic to int.
17316         * config/rs6000/rs6000.c (rs6000_override_options): Add casts to
17317         enum type.
17318         * config/s390/s390.c (code_for_builtin_64): Change to array of
17319         enum insn_code.
17320         (code_for_builtin_31): Likewise.
17321         (s390_expand_builtin): Change code_for_builtin to enum insn_code
17322         const *.
17323         * config/sparc/sparc.c (sparc_override_options): Change value
17324         field in struct code_model to enum cmodel.  In initializer change
17325         0 to NULL and add cast to enum type.
17326
17327         * c-typeck.c (build_modify_expr): Add lhs_origtype parameter.
17328         Change all callers.  Issue a -Wc++-compat warning using
17329         lhs_origtype if necessary.
17330         (convert_for_assignment): Issue -Wc++-compat warnings about
17331         invalid conversions to enum type on assignment.
17332         * c-common.h (build_modify_expr): Update declaration.
17333
17334 2009-04-24  Nick Clifton  <nickc@redhat.com>
17335
17336         * config/iq2000/iq2000.c (function_arg): Handle TImode values.
17337         (function_arg_advance): Likewise.
17338         * config/iq2000/iq2000.md (movsi_internal2): Fix the length of the
17339         5th alternative.
17340
17341 2009-04-24  Andreas Krebbel  <krebbel1@de.ibm.com>
17342
17343         * config/s390/constraints.md ('I', 'J'): Fix condition.
17344
17345 2009-04-24  Diego Novillo  <dnovillo@google.com>
17346
17347         * gengtype-parse.c (parse_error): Add newline after message.
17348
17349 2009-04-24  H.J. Lu  <hongjiu.lu@intel.com>
17350
17351         * config/i386/sse.md (avxmodesuffixs): Removed.
17352         (*avx_pinsr<avxmodesuffixs>): Renamed to ...
17353         (*avx_pinsr<ssevecsize>): This.
17354
17355 2009-04-24  Bernd Schmidt  <bernd.schmidt@analog.com>
17356
17357         * loop-iv.c (replace_single_def_regs): Look for REG_EQUAL notes;
17358         follow chains of regs with a single definition, and allow expressions
17359         that are function_invariant_p.
17360         (simple_rhs_p): Allow expressions that are function_invariant_p.
17361
17362 2009-04-24  Paolo Bonzini  <bonzini@gnu.org>
17363
17364         PR middle-end/39867
17365         * fold-const.c (fold_cond_expr_with_comparison): When folding
17366         > and >= to MAX, make sure the MAX uses the same type as the
17367         comparison's operands.
17368
17369 2009-04-24  Nick Clifton  <nickc@redhat.com>
17370
17371         * config/frv/frv.c (frv_frame_access): Do not use reg+reg
17372         addressing for DImode accesses.
17373         (frv_print_operand_address): Handle PLUS case.
17374         * config/frv/frv.h (FIXED_REGISTERS): Mark link register as fixed.
17375
17376 2009-04-24  Jakub Jelinek  <jakub@redhat.com>
17377
17378         PR rtl-optimization/39794
17379         * alias.c (canon_true_dependence): Add x_addr argument.
17380         * rtl.h (canon_true_dependence): Adjust prototype.
17381         * cse.c (check_dependence): Adjust canon_true_dependence callers.
17382         * cselib.c (cselib_invalidate_mem): Likewise.
17383         * gcse.c (compute_transp): Likewise.
17384         * dse.c (scan_reads_nospill): Likewise.
17385         (record_store, check_mem_read_rtx): Likewise.  For non-const-or-frame
17386         addresses pass base->val_rtx as mem_addr, for const-or-frame addresses
17387         canon_base_addr of the group, plus optional offset.
17388         (struct group_info): Rename canon_base_mem to
17389         canon_base_addr.
17390         (get_group_info): Set canon_base_addr to canon_rtx of base, not
17391         canon_rtx of base_mem.
17392
17393 2009-04-23  Paolo Bonzini  <bonzini@gnu.org>
17394
17395         * config/sh/sh.c (sh_expand_prologue, sh_expand_epilogue):
17396         Use memory_address_p instead of GO_IF_LEGITIMATE_ADDRESS.
17397
17398 2009-04-23  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
17399
17400         * config/spu/spu-builtins.h: Delete file.
17401
17402         * config/spu/spu.h (enum spu_builtin_type): Move here from
17403         spu-builtins.h.
17404         (struct spu_builtin_description): Likewise.  Add GTY marker.
17405         Do not use enum spu_function_code or enum insn_code.
17406         (spu_builtins): Add extern declaration.
17407
17408         * config/spu/spu.c: Do not include "spu-builtins.h".
17409         (enum spu_function_code, enum spu_builtin_type_index,
17410         V16QI_type_node, V8HI_type_node, V4SI_type_node, V2DI_type_node,
17411         V4SF_type_node, V2DF_type_node, unsigned_V16QI_type_node,
17412         unsigned_V8HI_type_node, unsigned_V4SI_type_node,
17413         unsigned_V2DI_type_node): Move here from spu-builtins.h.
17414         (spu_builtin_types): Make static.  Add GTY marker.
17415         (spu_builtins): Add extern declaration with GTY marker.
17416         Include "gt-spu.h".
17417
17418         * config/spu/spu-c.c: Do not include "spu-builtins.h".
17419         (spu_resolve_overloaded_builtin): Do not use spu_function_code.
17420         Check programmatically whether all parameters are scalar.
17421
17422         * config/spu/t-spu-elf (spu.o, spu-c.o): Update dependencies.
17423
17424 2009-04-23  Eric Botcazou  <ebotcazou@adacore.com>
17425
17426         * gimplify.c (gimplify_modify_expr_rhs) <VAR_DECL>: Do not do a direct
17427         assignment from the constructor either if the target is volatile.
17428
17429 2009-04-23  Daniel Jacobowitz  <dan@codesourcery.com>
17430
17431         * config/arm/arm.md (insv): Do not share operands[0].
17432
17433 2009-04-23  Nathan Sidwell  <nathan@codesourcery.com>
17434
17435         * config/vxlib-tls.c (active_tls_threads): Delete.
17436         (delete_hook_installed): New.
17437         (tls_delete_hook): Don't delete the delete hook.
17438         (tls_destructor): Delete it here.
17439         (__gthread_set_specific): Adjust installing the delete hook.
17440         (tls_delete_hook): Use __gthread_enter_tsd_dtor_context and
17441         __gthread_leave_tsd_dtor_context.
17442
17443 2009-04-23  Rafael Avila de Espindola  <espindola@google.com>
17444
17445         * c-format.c (gcc_tdiag_char_table): Add support for %E.
17446
17447 2009-04-23  Uros Bizjak  <ubizjak@gmail.com>
17448
17449         * config/alpha/alpha.c (alpha_legitimize_reload_address): Add cast to
17450         enum type.
17451         (alpha_rtx_costs): Ditto.
17452         (emit_unlikely_jump): Use add_reg_note.
17453         (emit_frame_store_1): Ditto.
17454         (alpha_expand_prologue): Ditto.
17455         (alpha_expand_builtin): Change 0 to EXPAND_NORMAL in function call.
17456         * config/alpha/alpha.c (Unicos/Mk address splitter): Use add_reg_note.
17457
17458 2009-04-23  Nick Clifton  <nickc@redhat.com>
17459
17460         * config/v850/v850.md (epilogue): Remove suppressed code.
17461         (return): Rename to return_simple and remove test of frame size.
17462         * config/v850/v850.c (expand_epilogue): Rename call to gen_return
17463         to gen_return_simple.
17464
17465 2009-04-22  Jing Yu  <jingyu@google.com>
17466
17467         PR testsuite/39781
17468         * config/arm/arm.h: Define HANDLE_PRAGMA_PACK_PUSH_POP.
17469
17470 2009-04-22  Andrew Pinski  <andrew_pinski@playstation.sony.com>
17471
17472         PR C/31499
17473         * c-typeck.c (process_init_element): Treat VECTOR_TYPE like ARRAY_TYPE
17474         and RECORD_TYPE/UNION_TYPE.  When outputing the actual element and the
17475         value is a VECTOR_CST, the element type is the element type of the
17476         vector.
17477
17478 2009-04-22  DJ Delorie  <dj@redhat.com>
17479
17480         * config/m32c/m32c.h: Update GTY annotations to new syntax.
17481
17482 2009-04-22  Jakub Jelinek  <jakub@redhat.com>
17483
17484         * alias.c (find_base_term): Move around LO_SUM case, so that
17485         CONST falls through into PLUS/MINUS handling.
17486
17487         PR c/39855
17488         * fold-const.c (fold_binary) <case LSHIFT_EXPR>: When optimizing
17489         into 0, use omit_one_operand.
17490
17491 2009-04-23  Ben Elliston  <bje@au.ibm.com>
17492
17493         * config/rs6000/linux-unwind.h (get_regs): Remove type
17494         puns. Change the type of `pc' to an array of unsigned ints and
17495         update all users.  Constify frame24.
17496
17497 2009-04-22  DJ Delorie  <dj@redhat.com>
17498
17499         * config/m32c/m32c.c (m32c_special_page_vector_p): Move
17500         declarations before code.
17501         (current_function_special_page_vector): Likewise.
17502         (m32c_expand_insv): Silence a warning.
17503
17504 2009-04-21  Taras Glek  <tglek@mozilla.com>
17505
17506         * alias.c: Update GTY annotations to new syntax.
17507         * basic-block.h: Likewise.
17508         * bitmap.h: Likewise.
17509         * c-common.h: Likewise.
17510         * c-decl.c: Likewise.
17511         * c-parser.c: Likewise.
17512         * c-pragma.c: Likewise.
17513         * c-tree.h: Likewise.
17514         * cfgloop.h: Likewise.
17515         * cgraph.h: Likewise.
17516         * config/alpha/alpha.c: Likewise.
17517         * config/arm/arm.h: Likewise.
17518         * config/avr/avr.h: Likewise.
17519         * config/bfin/bfin.c: Likewise.
17520         * config/cris/cris.c: Likewise.
17521         * config/darwin.c: Likewise.
17522         * config/frv/frv.c: Likewise.
17523         * config/i386/i386.c: Likewise.
17524         * config/i386/i386.h: Likewise.
17525         * config/i386/winnt.c: Likewise.
17526         * config/ia64/ia64.h: Likewise.
17527         * config/iq2000/iq2000.c: Likewise.
17528         * config/mips/mips.c: Likewise.
17529         * config/mmix/mmix.h: Likewise.
17530         * config/pa/pa.c: Likewise.
17531         * config/pa/pa.h: Likewise.
17532         * config/rs6000/rs6000.c: Likewise.
17533         * config/s390/s390.c: Likewise.
17534         * config/sparc/sparc.c: Likewise.
17535         * config/xtensa/xtensa.c: Likewise.
17536         * cselib.h: Likewise.
17537         * dbxout.c: Likewise.
17538         * dwarf2out.c: Likewise.
17539         * except.c: Likewise.
17540         * except.h: Likewise.
17541         * fixed-value.h: Likewise.
17542         * function.c: Likewise.
17543         * function.h: Likewise.
17544         * gimple.h: Likewise.
17545         * integrate.c: Likewise.
17546         * optabs.c: Likewise.
17547         * output.h: Likewise.
17548         * real.h: Likewise.
17549         * rtl.h: Likewise.
17550         * stringpool.c: Likewise.
17551         * tree-data-ref.c: Likewise.
17552         * tree-flow.h: Likewise.
17553         * tree-scalar-evolution.c: Likewise.
17554         * tree-ssa-address.c: Likewise.
17555         * tree-ssa-alias.h: Likewise.
17556         * tree-ssa-operands.h: Likewise.
17557         * tree.c: Likewise.
17558         * tree.h: Likewise.
17559         * varasm.c: Likewise.
17560         * varray.h: Likewise.
17561         * vec.h: Likewise.
17562         * coretypes.h: Do not define GTY macro if it is already defined.
17563         * doc/gty.texi: Update GTY documentation to new syntax.
17564         * gengtype-lex.l: Enforce attribute-like syntax for GTY
17565         annotations on structs.
17566         * gengtype-parse.c: Likewise.
17567
17568 2009-04-22  Mark Heffernan  <meheff@google.com>
17569
17570         * gcc.c (LINK_COMMAND_SPEC): Link with gcov with -fprofile-generate=.
17571
17572 2009-04-22  Kazu Hirata  <kazu@codesourcery.com>
17573
17574         * config/arm/arm.c (arm_rtx_costs_1): Use power_of_two_operand
17575         where appropriate.
17576
17577 2009-04-22  Kazu Hirata  <kazu@codesourcery.com>
17578
17579         * config/arm/arm.c (arm_size_rtx_costs): Treat a PLUS with a shift
17580         the same as a PLUS without a shift.  Increase the cost of a
17581         CONST_INT in MULT.
17582
17583 2009-04-22  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
17584
17585         * Makefile.in: Update dependencies.
17586         * errors.c (warning): Remove unused parameter 'opt'. Returns 'void'.
17587         * errors.h: Remove bogus comment about compatibility.
17588         (warning): Update declaration.
17589         * genautomata.c: Update all calls to warning.
17590         * gimple.c: Do not include errors.h. Include toplev.h.
17591         * tree-ssa-structalias.c: Do not include errors.h.
17592         * omega.c: Likewise.
17593         * tree-ssa-reassoc.c: Likewise.
17594         * config/spu/spu-c.c: Likewise.
17595         * config/spu/t-spu-elf: Update dependencies.
17596
17597 2009-04-22  Richard Guenther  <rguenther@suse.de>
17598
17599         PR tree-optimization/39824
17600         * tree-ssa-ccp.c (fold_const_aggregate_ref): For INDIRECT_REFs
17601         make sure the types are compatible.
17602
17603 2009-04-22  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
17604
17605         PR c++/14875
17606         * c-common.c (c_parse_error): Take a token_flags parameter.
17607         Use token_type for the token type instead.
17608         Pass token_flags to cpp_type2name.
17609         * c-common.h (c_parse_error): Update declaration.
17610         * c-parser.c (c_parser_error): Pass 0 as token flags.
17611
17612 2009-04-22  Andrey Belevantsev  <abel@ispras.ru>
17613
17614         PR rtl-optimization/39580
17615         * sel-sched-ir.c (insert_in_history_vect): Remove incorrect gcc_assert.
17616
17617 2009-04-22  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
17618
17619         * function.c (expand_function_end): Do not emit a jump to the "naked"
17620         return label for fall-through returns.
17621         * except.c (sjlj_emit_function_exit): Always place the call to the
17622         unregister function at the location installed by expand_function_end.
17623
17624 2009-04-22  Richard Guenther  <rguenther@suse.de>
17625
17626         PR tree-optimization/39845
17627         * tree-switch-conversion.c (build_arrays): Add new referenced vars.
17628         (gen_inbound_check): Likewise.
17629
17630 2009-04-22  Nathan Sidwell  <nathan@codesourcery.com>
17631
17632         * gthr-vxworks.h (struct __gthread_once_t): Add alignment and
17633         padding for PPC.
17634         (__GTHREAD_ONCE_INIT): Adjust ppc initializer.
17635         * config/vxlib.c (__gthread_once): Add race guard for PPC.
17636
17637 2009-04-22  Paolo Bonzini  <bonzini@gnu.org>
17638
17639         * config/sh/sh.c (shift_insns_rtx, shiftcosts, gen_shifty_op,
17640         sh_dynamicalize_shift_p, shl_and_scr_length): Truncate
17641         shift counts to avoid out-of-bounds array accesses.
17642
17643 2009-04-22  Paolo Bonzini  <bonzini@gnu.org>
17644
17645         * config/sparc/sparc.h (POINTER_SIZE): Fix comment.
17646         (Pmode): Move above.
17647
17648 2009-04-22  Uros Bizjak  <ubizjak@gmail.com>
17649
17650         * config/alpha/alpha.c: Use REG_P, MEM_P, CONST_INT_P, JUMP_P,
17651         NONJUMP_INSN_P, CALL_P, LABEL_P and NOTE_P predicates instead of
17652         GET_CODE macro.  Use IN_RANGE macro where appropriate.
17653         * config/alpha/alpha.h: Ditto.
17654         * config/alpha/alpha.md: Ditto.
17655         * config/alpha/constraints.md: Ditto.
17656         * config/alpha/predicates.md: Ditto.
17657
17658 2009-04-22  Paolo Bonzini  <bonzini@gnu.org>
17659
17660         * defaults.h (GO_IF_MODE_DEPENDENT_ADDRESS): Provide empty default.
17661         * config/frv/frv.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17662         * config/s390/s390.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17663         * config/m32c/m32c.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17664         * config/spu/spu.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17665         * config/i386/i386.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17666         * config/sh/sh.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17667         * config/pdp11/pdp11.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17668         * config/avr/avr.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17669         * config/crx/crx.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17670         * config/fr30/fr30.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17671         * config/m68hc11/m68hc11.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17672         * config/cris/cris.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17673         * config/iq2000/iq2000.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17674         * config/mn10300/mn10300.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17675         * config/ia64/ia64.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17676         * config/m68k/m68k.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17677         * config/picochip/picochip.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17678         * config/arc/arc.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17679         * config/mcore/mcore.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17680         * config/score/score.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17681         * config/arm/arm.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17682         * config/pa/pa.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17683         * config/mips/mips.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17684         * config/v850/v850.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17685         * config/mmix/mmix.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17686         * config/bfin/bfin.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
17687
17688 2009-04-22  Laurynas Biveinis  <laurynas.biveinis@gmail.com>
17689
17690         * cfghooks.c (tidy_fallthru_edges): Remove find_basic_blocks
17691         references from comments.
17692         * cfgbuild.c: (count_basic_blocks): Delete.
17693         (find_basic_blocks_1): Delete.
17694         (find_basic_blocks): Delete.
17695         * except.c (finish_eh_generation): Make static.  Move comment from
17696         except.h here.  Remove find_basic_blocks references from comments.
17697         * except.h (finish_eh_generation): Delete.
17698         * basic-block.h (find_basic_blocks): Delete.
17699         * config/sh/sh.c (sh_output_mi_thunk): Delete a "#if 0" block.
17700
17701 2009-04-22  Dave Korn  <dave.korn.cygwin@gmail.com>
17702
17703         * sdbout.c (sdbout_symbol):  Pass VOIDmode to eliminate_regs.
17704         (sdbout_parms):  Likewise.
17705
17706 2009-04-21  Kaz Kojima  <kkojima@gcc.gnu.org>
17707
17708         * config/sh/sh.c (prepare_cbranch_operands): Use
17709         LAST_AND_UNUSED_RTX_CODE instead of CODE_FOR_nothing.
17710         (expand_cbranchdi4): Likewise.
17711         (from_compare): Add cast to enum type.
17712         (expand_cbranchsi4): Use add_reg_note.
17713         (output_stack_adjust, push, pop, sh_expand_prologue): Likewise.
17714         (sh_insn_length_adjustment): Use sh_cpu_attr instead of sh_cpu.
17715         (sh_initialize_trampoline): Change 0 to LCT_NORMAL in function call.
17716         (sh_expand_builtin): Change 0 to EXPAND_NORMAL in function call.
17717         * config/sh/sh.md (cbranchsi4): Use LAST_AND_UNUSED_RTX_CODE
17718         instead of CODE_FOR_nothing.
17719         (cbranchdi4): Likewise.  Fix the order of arguments for
17720         gen_rtx_fmt_ee.
17721         (push_fpscr): Use add_reg_note.
17722         (pop_fpscr, movdf_i4+1, reload_outdf__RnFRm+3, reload_outdf__RnFRm+4,
17723         reload_outdf__RnFRm+5, fpu_switch+1, fpu_switch+2): Likewise.
17724
17725 2009-04-21  Joseph Myers  <joseph@codesourcery.com>
17726
17727         * ABOUT-GCC-NLS, ChangeLog, ChangeLog-1997, ChangeLog-1998,
17728         ChangeLog-1999, ChangeLog-2000, ChangeLog-2001, ChangeLog-2002,
17729         ChangeLog-2003, ChangeLog-2004, ChangeLog-2005, ChangeLog-2006,
17730         ChangeLog-2007, ChangeLog-2008, ChangeLog.dataflow, ChangeLog.lib,
17731         ChangeLog.ptr, ChangeLog.tree-ssa, ChangeLog.tuples, FSFChangeLog,
17732         FSFChangeLog.10, FSFChangeLog.11, LANGUAGES, ONEWS, acinclude.m4,
17733         config/alpha/gnu.h, config/alpha/libgcc-alpha-ldbl.ver,
17734         config/alpha/t-osf4, config/alpha/t-vms, config/alpha/va_list.h,
17735         config/alpha/x-vms, config/arc/t-arc,
17736         config/arm/README-interworking, config/arm/arm-c.c,
17737         config/arm/gentune.sh, config/arm/libgcc-bpabi.ver,
17738         config/arm/t-arm, config/arm/t-arm-elf, config/arm/t-arm-softfp,
17739         config/arm/t-bpabi, config/arm/t-linux, config/arm/t-linux-eabi,
17740         config/arm/t-netbsd, config/arm/t-pe, config/arm/t-strongarm-elf,
17741         config/arm/t-symbian, config/arm/t-vxworks, config/arm/t-wince-pe,
17742         config/avr/t-avr, config/bfin/elf.h, config/bfin/libgcc-bfin.ver,
17743         config/bfin/linux.h, config/bfin/t-bfin, config/bfin/t-bfin-elf,
17744         config/bfin/t-bfin-linux, config/bfin/t-bfin-uclinux,
17745         config/bfin/uclinux.h, config/cris/mulsi3.asm, config/cris/t-cris,
17746         config/cris/t-elfmulti, config/crx/t-crx,
17747         config/darwin-ppc-ldouble-patch.def, config/darwin-sections.def,
17748         config/divmod.c, config/fr30/t-fr30, config/frv/libgcc-frv.ver,
17749         config/frv/t-frv, config/frv/t-linux, config/h8300/genmova.sh,
17750         config/h8300/t-h8300, config/i386/athlon.md,
17751         config/i386/darwin-libgcc.10.4.ver,
17752         config/i386/darwin-libgcc.10.5.ver, config/i386/libgcc-glibc.ver,
17753         config/i386/mach.h, config/i386/netbsd.h, config/i386/t-crtpc,
17754         config/i386/t-cygming, config/i386/t-cygwin, config/i386/t-i386,
17755         config/i386/t-linux64, config/i386/t-nwld,
17756         config/i386/t-rtems-i386, config/i386/t-sol2-10,
17757         config/i386/x-mingw32, config/ia64/div.md, config/ia64/elf.h,
17758         config/ia64/ia64.opt, config/ia64/libgcc-glibc.ver,
17759         config/ia64/libgcc-ia64.ver, config/ia64/linux.h,
17760         config/ia64/sysv4.h, config/ia64/t-hpux, config/ia64/t-ia64,
17761         config/iq2000/abi, config/iq2000/lib2extra-funcs.c,
17762         config/iq2000/t-iq2000, config/libgcc-glibc.ver,
17763         config/m32r/libgcc-glibc.ver, config/m32r/t-linux,
17764         config/m32r/t-m32r, config/m68hc11/t-m68hc11,
17765         config/m68k/t-floatlib, config/m68k/t-linux, config/m68k/t-mlibs,
17766         config/m68k/t-uclinux, config/mcore/t-mcore,
17767         config/mcore/t-mcore-pe, config/mips/20kc.md, config/mips/4130.md,
17768         config/mips/5400.md, config/mips/5500.md, config/mips/crti.asm,
17769         config/mips/crtn.asm, config/mips/irix-crti.asm,
17770         config/mips/irix-crtn.asm, config/mips/libgcc-mips16.ver,
17771         config/mips/mips-dsp.md, config/mips/mips-dspr2.md,
17772         config/mips/mips-fixed.md, config/mips/sb1.md,
17773         config/mips/sr71k.md, config/mips/t-elf, config/mips/t-gofast,
17774         config/mips/t-iris6, config/mips/t-isa3264,
17775         config/mips/t-libgcc-mips16, config/mips/t-linux64,
17776         config/mips/t-mips, config/mips/t-r3900, config/mips/t-rtems,
17777         config/mips/t-sb1, config/mips/t-sde, config/mips/t-sdemtk,
17778         config/mips/t-slibgcc-irix, config/mips/t-sr71k, config/mips/t-st,
17779         config/mips/t-vr, config/mips/t-vxworks, config/mmix/t-mmix,
17780         config/mn10300/t-linux, config/mn10300/t-mn10300,
17781         config/pa/pa32-regs.h, config/pa/t-hpux-shlib, config/pa/t-linux,
17782         config/pa/t-linux64, config/pa/t-pa64, config/pdp11/t-pdp11,
17783         config/picochip/libgccExtras/clzsi2.asm,
17784         config/picochip/t-picochip, config/rs6000/darwin-ldouble-format,
17785         config/rs6000/darwin-libgcc.10.4.ver,
17786         config/rs6000/darwin-libgcc.10.5.ver,
17787         config/rs6000/libgcc-ppc-glibc.ver, config/rs6000/ppc-asm.h,
17788         config/rs6000/t-aix43, config/rs6000/t-aix52,
17789         config/rs6000/t-darwin, config/rs6000/t-fprules,
17790         config/rs6000/t-fprules-fpbit, config/rs6000/t-linux64,
17791         config/rs6000/t-lynx, config/rs6000/t-netbsd,
17792         config/rs6000/t-ppccomm, config/rs6000/t-ppcendian,
17793         config/rs6000/t-ppcgas, config/rs6000/t-rs6000,
17794         config/rs6000/t-rtems, config/rs6000/t-spe,
17795         config/rs6000/t-vxworks, config/s390/libgcc-glibc.ver,
17796         config/score/t-score-elf, config/sh/divcost-analysis,
17797         config/sh/libgcc-glibc.ver, config/sh/t-netbsd, config/sh/t-sh,
17798         config/sh/t-sh64, config/sh/t-superh, config/sh/t-symbian,
17799         config/sparc/libgcc-sparc-glibc.ver, config/sparc/sol2-bi.h,
17800         config/sparc/sol2-gas.h, config/sparc/sol2-gld-bi.h,
17801         config/sparc/t-elf, config/sparc/t-linux64, config/sparc/t-sol2,
17802         config/stormy16/stormy-abi, config/stormy16/t-stormy16,
17803         config/t-darwin, config/t-libunwind, config/t-libunwind-elf,
17804         config/t-linux, config/t-lynx, config/t-slibgcc-elf-ver,
17805         config/t-slibgcc-sld, config/t-sol2, config/t-vxworks,
17806         config/udivmod.c, config/udivmodsi4.c, config/v850/t-v850,
17807         config/v850/t-v850e, config/xtensa/t-xtensa, diagnostic.def,
17808         gdbinit.in, glimits.h, gstab.h, gsyms.h, java/ChangeLog,
17809         java/ChangeLog.ptr, java/ChangeLog.tree-ssa, libgcc-std.ver,
17810         limitx.h, version.c, xcoff.h: Add copyright and license notices.
17811         * config/h8300/genmova.sh: Include copyright and license notices
17812         in generated output.
17813         * config/h8300/mova.md: Regenerate.
17814         * doc/install.texi2html: Include word "Copyright" in copyright
17815         notice and use name "Free Software Foundation, Inc.".
17816         * ChangeLog, ChangeLog-2000, ChangeLog-2001, ChangeLog-2002,
17817         ChangeLog-2003, ChangeLog-2004, ChangeLog-2005, ChangeLog-2006,
17818         ChangeLog-2007, ChangeLog-2008: Correct dates.
17819
17820 2009-04-21  Eric Botcazou  <ebotcazou@adacore.com>
17821
17822         * c-common.c (c_common_truthvalue_conversion): Use LOCATION to build
17823         NE_EXPR operations as well.
17824         * c-parser.c (c_parser_condition): Do not set location information on
17825         the condition.
17826         (c_parser_conditional_expression): Likewise.
17827         (c_parser_binary_expression): Set location information on operators.
17828         * c-typeck.c (build_unary_op) <TRUTH_NOT_EXPR>: Reset the location if
17829         TRUTH_NOT_EXPR has been folded.
17830         * fold-const.c (fold_truth_not_expr): Copy location information from
17831         the incoming expression to the outgoing one.
17832         * gimplify.c (shortcut_cond_r): Add locus parameter.  Pass it to
17833         recursive calls on the LHS of the operator but pass that of the
17834         operator to recursive calls on the RHS of the operator.  Set it
17835         on the COND_EXPR.
17836         (shortcut_cond_expr): Set the locus of the operator on the second
17837         COND_EXPR and that of the expression on the first in degenerate cases.
17838         Pass the locus of the expression to calls to shortcut_cond_r.
17839         Set the locus of the 'then' block on the associated jump, if any.
17840         (gimplify_boolean_expr): Add locus parameter.  Set it on the COND_EXPR.
17841         (gimplify_expr) <TRUTH_ANDIF_EXPR>: Pass the locus of the outer
17842         expression to call to gimplify_boolean_expr.
17843
17844 2009-04-21  Kai Tietz  <kai.tietz@onevision.com>
17845
17846         * config.gcc: Add additional configuration for
17847         i686-w64-mingw* and x86_64-w64-mingw* triplet.
17848         * config/i386/mingw-w64.h: New mingw-w64 specific header.
17849         (CPP_SPEC): Redefine for allowing -municode option.
17850         (STARTFILE_SPEC): Likewise.
17851         * config/i386/t-mingw-w64: New.
17852         * config/i386/mingw-w64.opt: New.
17853         (municode): Add new target option.
17854         * doc/invoke.texi (municode): Add documentation for new option.
17855
17856 2009-04-21  Ian Lance Taylor  <iant@google.com>
17857
17858         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
17859         Correct test for number of arguments.
17860         * config/spu/spu-c.c (spu_resolve_overloaded_builtin): Likewise.
17861
17862 2009-04-21  Andreas Schwab  <schwab@linux-m68k.org>
17863
17864         * config/m68k/linux.h (FINALIZE_TRAMPOLINE): Use enum for second
17865         argument of emit_library_call.
17866
17867 2009-04-21  Richard Guenther  <rguenther@suse.de>
17868
17869         PR middle-end/39829
17870         * gimple.c (walk_stmt_load_store_addr_ops): Catch addresses
17871         inside VIEW_CONVERT_EXPRs.
17872
17873 2009-04-21  Martin Jambor  <mjambor@suse.cz>
17874
17875         * tree-switch-conversion.c (build_constructors): Split a long line.
17876         (constructor_contains_same_values_p): New function.
17877         (build_one_array): Create assigns of constants if possible, do not
17878         call mark_sym_for_renaming, call update_stmt.
17879         (build_arrays): Call make_ssa_name (create_tmp_var ()) instead of
17880         make_rename_temp.  Do not call mark_symbols_for_renaming, call
17881         update_stmt.
17882         (gen_def_assigns): Do not call mark_symbols_for_renaming or
17883         find_new_referenced_vars, call update_stmt.
17884         (gen_inbound_check): Use create_tmp_var and create ssa names manually
17885         instead of calling make_rename_temp.  Do not call
17886         find_new_referenced_vars or mark_symbols_for_renaming, call
17887         update_stmt.
17888
17889 2009-04-21  Richard Guenther  <rguenther@suse.de>
17890
17891         PR tree-optimization/39827
17892         * tree-ssa-phiprop.c (propagate_with_phi): Check SSA_NAME is in range.
17893         (tree_ssa_phiprop): Pass the correct array size.
17894
17895 2009-04-21  Uros Bizjak  <ubizjak@gmail.com>
17896
17897         * config/alpha/alpha.md (tune): Add cast to enum attr_tune.
17898
17899 2009-04-21  Manuel López-Ibáñez  <manu@gcc.gnu.org>
17900
17901         PR 16202
17902         * c-typeck.c (lvalue_p): Move declaration ...
17903         * c-common.h (lvalue_p): ... to here.
17904         * c-common.c (candidate_equal_p): New.
17905         (add_tlist): Use it.
17906         (merge_tlist): Use it.
17907         (warn_for_collisions_1): Likewise.
17908         (warning_candidate_p): Accept more candidates.
17909         (verify_tree): A warning candidate can be an expression. Use
17910         candidate_equal_p.
17911
17912 2009-04-21  Ben Elliston  <bje@au.ibm.com>
17913
17914         PR target/5267
17915         * doc/invoke.texi (RS/6000 and PowerPC Options): Add documentation
17916         for -mcall-eabi, -mcall-aixdesc, -mcall-freebsd and -mcall-openbsd
17917         options.  Remove -mcall-solaris documentation.
17918
17919 2009-04-21  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
17920
17921         PR c++/13358
17922         * doc/invoke.texi (-Wlong-long): Update description.
17923         * c-lex (interpret_integer): Only warn if there was no previous
17924         overflow and -Wlong-long is enabled.
17925         * c-decl.c (declspecs_add_type): Drop redundant flags.
17926         * c.opt (Wlong-long): Init to -1.
17927         * c-opts.c (sanitize_cpp_opts): Synchronize cpp's warn_long_long
17928         and front-end warn_long_long. Wlong-long only depends on other
17929         flags if it is uninitialized.
17930         * c-parser.c (disable_extension_diagnostics): warn_long_long is
17931         the same for CPP and FE.
17932         (restore_extension_diagnostics): Likewise.
17933
17934 2009-04-20  Ian Lance Taylor  <iant@google.com>
17935
17936         Fix enum conversions which are invalid in C++:
17937         * auto-inc-dec.c (attempt_change): Change 0 to SET in function call.
17938         * calls.c (store_one_arg): Change 0 to EXPAND_NORMAL in function call.
17939         * cse.c (hash_rtx_cb): Change 0 to VOIDmode in function call.
17940         * dbgcnt.c (dbg_cnt_set_limit_by_name): Add cast to enum type.
17941         * dbxout.c (dbxout_symbol): Change 0 to VOIDmode in function call.
17942         (dbxout_parms): Likewise.
17943         * df-core.c (df_set_flags): Change changeable_flags parameter to int.
17944         (df_clear_flags): Likewise.
17945         * df-problems.c (df_rd_bb_local_compute_process_def): Change
17946         top_flag parameter to int.
17947         (df_chain_create_bb_process_use): Likewise.
17948         (df_chain_add_problem): Change chain_flags parameter to unsigned int.
17949         Remove cast.
17950         * df-scan.c (df_ref_create): Change ref_flags parameter to int.
17951         (df_ref_create_structure, df_def_record_1): Likewise.
17952         (df_defs_record, df_uses_record, df_get_call_refs): Likewise.
17953         (df_notes_rescan): Change 0 to VOIDmode in function call.
17954         (df_get_call_refs, df_insn_refs_collect): Likewise.
17955         (df_bb_regs_collect): Likewise.
17956         (df_entry_block_defs_collect): Likewise.
17957         (df_exit_block_uses_collect): Likewise.
17958         * df.h: Update declarations.
17959         * double-int.c (double_int_divmod): Add cast to enum type.
17960         * dse.c (replace_inc_dec): Reverse parameters to gen_int_mode.
17961         * dwarf2out.c (new_reg_loc_descr): Add casts to enum type.
17962         (based_loc_descr): Likewise.
17963         (loc_descriptor_from_tree_1): Change first_op and second_op to
17964         enum dwarf_location_atom.  Add cast to enum type.
17965         * expmed.c (init_expmed): Change 0 to SET in function call.
17966         * expr.c (init_expr_target): Change 0 to VOIDmode in function call.
17967         (expand_expr_real_1): Change 0 to EXPAND_NORMAL in function call.
17968         (do_store_flag): Likewise.
17969         * fixed-value.h (struct fixed_value): Change mode to enum
17970         machine_mode.
17971         * function.c (assign_parms): Change 0 to VOIDmode in function call.
17972         * genautomata.c (insert_automaton_decl): Change 1 to INSERT in
17973         function call.
17974         (insert_insn_decl, insert_decl, insert_state): Likewise.
17975         (automata_list_finish): Likewise.
17976         * genrecog.c (process_define_predicate): Add cast to enum type.
17977         * gensupport.c (init_predicate_table): Add cast to enum type.
17978         * gimple.c (gimple_build_return): Change 0 to ERROR_MARK in
17979         function call.
17980         (gimple_build_call_1, gimple_build_label): Likewise.
17981         (gimple_build_goto, gimple_build_asm_1): Likewise.
17982         (gimple_build_switch_1, gimple_build_cdt): Likewise.
17983         * gimple.h (GIMPLE_CHECK): Change 0 to ERROR_MARK in function call.
17984         (enum fallback): Rename from enum fallback_t.
17985         (fallback_t): Typedef as int.
17986         * gimple-low.c (lower_builtin_setjmp): Change TSI_SAME_STMT to
17987         GSI_SAME_STMT in function call.
17988         * ira.c (setup_class_subset_and_memory_move_costs): Add casts to
17989         enum type.
17990         (setup_reg_class_relations): Likewise.
17991         (setup_reg_class_nregs): Change cl to int.  Add casts to enum type.
17992         (setup_prohibited_class_mode_regs): Add cast to enum type.
17993         (setup_prohibited_mode_move_regs): Likewise.
17994         * ira-costs.c (record_reg_classes): Change rclass to enum reg_class.
17995         (record_address_regs): Change i to enum reg_class.
17996         * lists.c (alloc_EXPR_LIST): Add cast to enum type.
17997         * machmode.h (GET_MODE_CLASS): Cast value to enum mode_class.
17998         (GET_MODE_WIDER_MODE): Cast value to enum machine_mode.
17999         (GET_MODE_2XWIDER_MODE): Likewise.
18000         (GET_CLASS_NARROWEST_MODE): Likewise.
18001         * omp-low.c (expand_omp_for): Add cast to enum type.
18002         * optabs.c (debug_optab_libfuncs): Add casts to enum type.
18003         * opts.c (enable_warning_as_error): Change kind to diagostic_t.
18004         * postreload.c (reload_cse_simplify_operands): Change rclass local
18005         to enum reg_class.
18006         * predict.c (combine_predictions_for_insn): Change best_predictor
18007         and predictor to enum br_predictor.
18008         (combine_predictions_for_bb): Likewise.
18009         (build_predict_expr): Change assignment to PREDICT_EXPR_OUTCOME to
18010         use SET_PREDICT_EXPR_OUTCOME.
18011         * real.c (real_arithmetic): Change icode to code in function call.
18012         * reginfo.c (init_move_cost): Add casts to enum type.
18013         (init_reg_sets_1, init_fake_stack_mems): Likewise.
18014         * regmove.c (regclass_compatible_p): Change class0 and class1 to
18015         enum reg_class.
18016         * reload.c (find_valid_class): Add casts to enum type.
18017         (push_reload): Change 0 to NO_REGS in function call.
18018         (find_reloads): Change this_alternative to array of enum
18019         reg_class.  Remove some now-unnecessary casts.
18020         (make_memloc): Change 0 to VOIDmode in function call.
18021         * reload1.c (reload): Change 0 to VOIDmode in function call.
18022         (eliminate_regs_1, elimination_effects): Likewise.
18023         (eliminate_regs_in_insn): Likewise.
18024         (emit_input_reload_insns): Add cast to enum type.
18025         (delete_output_reload): Change 0 to VOIDmode in function call.
18026         * reorg.c (insn_sets_resource_p): Convert include_delayed_effects
18027         to enum type in function call.
18028         * tree.h (PREDICT_EXPR_OUTCOME): Add cast to enum type.
18029         (SET_PREDICT_EXPR_OUTCOME): Define.
18030         * tree-dump.c (get_dump_file_info): Change phase parameter to int.
18031         (get_dump_file_name, dump_begin, dump_enabled_p): Likewise.
18032         (dump_initialized_p, dump_flag_name, dump_end): Likewise.
18033         (dump_function): Likewise.
18034         * tree-dump.h: Update declarations.
18035         * tree-pass.h: Update declarations.
18036         * varasm.c (assemble_integer): Change mclass to enum mode_class.
18037         * config/arm/arm.c (thumb_legitimize_reload_address): Add cast to
18038         enum type.
18039         (arm_rtx_costs_1): Correct parenthesization.
18040         (arm_rtx_costs): Add casts to enum type.
18041         (adjacent_mem_locations): Reverse arguments to const_ok_for_op.
18042         (vfp_emit_fstmd): Use add_rg_note.
18043         (emit_multi_reg_push, emit_sfm): Likewise.
18044         (thumb_set_frame_pointer): Likewise.
18045         (arm_expand_prologue): Likewise.
18046         (arm_regno_class): Change return type to enum reg_class.
18047         (thumb1_expand_prologue): Use add_reg_note.
18048         * config/arm/arm-protos.h (arm_regno_class): Update declaration.
18049         * config/arm/arm.h (INITIALIZE_TRAMPOLINE): Change 0 to LCT_NORMAL
18050         in function call.
18051         * config/arm/gentune.sh: Add cast to enum type.
18052         * config/arm/arm-tune.md: Rebuild.
18053         * config/i386/i386.c (ix86_expand_prologue): Use add_reg_note.
18054         (ix86_split_fp_branch, predict_jump): Likewise.
18055         (ix86_expand_multi_arg_builtin): Change sub_code from enum
18056         insn_code to enum rtx_code.
18057         (ix86_builtin_vectorized_function): Add cast to enum type.
18058         * config/i386/i386.md (truncdfsf2): Change slot to enum
18059         ix86_stack_slot.
18060         (truncxf<mode>2, isinf<mode>2): Likewise.
18061         * config/i386/i386-c.c (ix86_pragma_target_parse): Add cast to
18062         enum type.
18063         * config/ia64/ia64.c (ia64_split_tmode_move): Use add_reg_note.
18064         (spill_restore_mem, do_spill, ia64_expand_prologue): Likewise.
18065         (insert_bundle_state): Change 1 to INSERT in function call.
18066         (ia64_add_bundle_selector_before): Likewise.
18067         * config/ia64/ia64.md (cpu attr): Add cast to enum type.
18068         (save_stack_nonlocal): Change 0 to LCT_NORMAL in function call.
18069         (restore_stack_nonlocal): Likewise.
18070         * config/mips/mips.h (MIPS_ICACHE_SYNC): Change 0 to LCT_NORMAL in
18071         function call.
18072         * config/mips/mips.c (mips_binary_cost): Change 0 to SET in
18073         function call.
18074         (mips_rtx_costs): Likewise.
18075         (mips_override_options): Add casts to enum type.
18076         * config/mips/sdemtk.h (MIPS_ICACHE_SYNC): Change 0 to LCT_NORMAL
18077         in function call.
18078         * config/pa/pa.c (legitimize_pic_address): Use add_reg_note.
18079         (store_reg, set_reg_plus_d): Likewise.
18080         (hppa_expand_prologue, hppa_profile_hook): Likewise.
18081         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Add
18082         cast to enum type.
18083         (altivec_expand_vec_set_builtin): Change 0 to EXPAND_NORMAL in
18084         function call.
18085         (emit_unlikely_jump): Use add_reg_note.
18086         (rs6000_emit_allocate_stack): Likewise.
18087         (rs6000_frame_related, rs6000_emit_prologue): Likewise.
18088         (output_toc): Change 1 to INSERT in function call.
18089         (output_profile_hook): Change 0 to LCT_NORMAL in function call.
18090         (rs6000_initialize_trampoline): Likewise.
18091         (rs6000_init_dwarf_reg_sizes_extra): Change 0 to EXPAND_NORMAL in
18092         function call.
18093         * config/s390/s390.c (s390_rtx_costs): Add cast to enum type.
18094         (s390_expand_movmem): Change 0 to OPTAB_DIRECT in function call.
18095         (s390_expand_setmem, s390_expand_cmpmem): Likewise.
18096         (save_gprs): Use add_reg_note.
18097         (s390_emit_prologue): Likewise.
18098         (s390_expand_builtin): Change 0 to EXPAND_NORMAL in function call.
18099         * config/sparc/sparc.c (sparc_expand_prologue): Use add_reg_note.
18100         (sparc_fold_builtin): Add cast to enum type.
18101         * config/spu/spu.c (spu_emit_branch_or_set): Change ior_code to
18102         enum insn_code.
18103         (spu_expand_prologue): Use add_reg_note.
18104         (expand_builtin_args): Change 0 to EXPAND_NORMAL in function call.
18105
18106 2009-04-20  Ian Lance Taylor  <iant@google.com>
18107
18108         * c-parser.c (c_parser_attributes): Change VEC back to tree list.
18109         (c_parser_postfix_expression_after_primary): Get VEC for list of
18110         arguments.  Get original types of arguments.  Call
18111         build_function_call_vec.
18112         (cached_expr_list_1, cached_expr_list_2): New static variables.
18113         (c_parser_expr_list): Change return type to VEC *.  Add
18114         p_orig_types parameter.  Change all callers.
18115         (c_parser_release_expr): New static function.
18116         (c_parser_vec_to_tree_list): New static function.
18117         * c-typeck.c (build_function_call): Rewrite to build a VEC and
18118         call build_function_call_vec.
18119         (build_function_call_vec): New function, based on old
18120         build_function_call.
18121         (convert_arguments): Remove nargs and argarray parameters.  Change
18122         values to a VEC.  Add origtypes parameter.
18123         (build_modify_expr): Add rhs_origtype parameter.  Change all callers.
18124         (convert_for_assignment): Add origtype parameter.  Change all
18125         callers.  If warn_cxx_compat, check for conversion to an enum
18126         type when calling a function.
18127         (store_init_value): Add origtype parameter.  Change all callers.
18128         (digest_init): Likewise.
18129         (struct init_node): Add origtype field.
18130         (add_pending_init): Add origtype parameter.  Change all callers.
18131         (output_init_element): Likewise.
18132         (output_pending_init_elements): Pass origtype from init_node to
18133         output_init_element.
18134         (process_init_element): Pass origtype from c_expr to
18135         output_init_element.
18136         (c_finish_return): Add origtype parameter.  Change all callers.
18137         * c-common.c (sync_resolve_size): Change params to VEC *.  Change
18138         caller.
18139         (sync_resolve_params): Likewise.
18140         (sync_resolve_return): Change params to first_param.  Change caller.
18141         (resolve_overloaded_builtins): Change params to VEC *.  Change
18142         callers.  Save first parameter around call to build_function_call_vec.
18143         * c-decl.c (finish_decl): Add origtype parameter.  Change all
18144         callers.  Call build_function_call_vec rather than
18145         build_function_call for cleanup.
18146         * c-tree.h: Update declarations.
18147         * c-common.h: Update declarations.
18148         * stub-objc.c (objc_rewrite_function_call): Change parameter from
18149         params to first_param.
18150         * target.h (struct gcc_target): Change resolve_overloaded_builtin
18151         params parameter from tree to void *.
18152         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
18153         Change arglist parameter to have type void *, and to be a pointer
18154         to a VEC.
18155         * config/rs6000/rs6000-protos.h
18156         (altivec_resolve_overloaded_builtin): Update declaration.
18157         * config/spu/spu-c.c (spu_resolved_overloaded_builtin): Change
18158         fnargs parameter to have type void *, and to be a pointer to a
18159         VEC.  Call build_function_call_vec instead of
18160         build_function_call.
18161         * config/spu/spu-protos.h (spu_expand_builtin): Update declaration.
18162
18163 2009-04-20  Joey Ye  <joey.ye@intel.com>
18164             Xuepeng Guo  <xuepeng.guo@intel.com>
18165             H.J. Lu  <hongjiu.lu@intel.com>
18166
18167         * config/i386/atom.md: Add bypasses with ix86_dep_by_shift_count.
18168
18169         * config/i386/i386.c (LEA_SEARCH_THRESHOLD): New macro.
18170         (IX86_LEA_PRIORITY): Likewise.
18171         (distance_non_agu_define): New function.
18172         (distance_agu_use): Likewise.
18173         (ix86_lea_for_add_ok): Likewise.
18174         (ix86_dep_by_shift_count): Likewise.
18175
18176         * config/i386/i386.md: Call ix86_lea_for_add_ok to decide we
18177         should split for LEA.
18178
18179         * config/i386/i386-protos.h (ix86_lea_for_add_ok): Declare new
18180         function.
18181         (ix86_dep_by_shift_count): Likewise.
18182
18183 2009-04-20  Richard Guenther  <rguenther@suse.de>
18184
18185         * expr.c (handled_component_p): Move ...
18186         * tree.h (handled_component_p): ... here.
18187         * tree.def: Re-order BIT_FIELD_REF, COMPONENT_REF,
18188         ARRAY_REF, ARRAY_RANGE_REF, VIEW_CONVERT_EXPR, IMAGPART_EXPR
18189         and REALPART_EXPR to be in one group.
18190
18191 2009-04-20  Richard Guenther  <rguenther@suse.de>
18192
18193         * basic-block.h (get_all_dominated_blocks): Declare.
18194         * dominance.c (get_all_dominated_blocks): New function.
18195         * tree-cfg.c (get_all_dominated_blocks): Remove.
18196         (remove_edge_and_dominated_blocks): Adjust.
18197         * tree-ssa-phiprop.c (tree_ssa_phiprop_1): Fold in ...
18198         (tree_ssa_phiprop): ... here.  Use get_all_dominated_blocks
18199         instead of recursing.
18200
18201 2009-04-20  Doug Kwan  <dougkwan@google.com>
18202
18203         * cgraph.h (cgraph_node_ptr): New type for vector functions.
18204         (struct cgraph_node_set_def): New type.
18205         (cgraph_node_set) New type. Also declare vector functions.
18206         (struct cgraph_node_set_element_def): New type.
18207         (cgraph_node_set_element): Ditto.
18208         (cgraph_node_set_iterator): New iterator type.
18209         (cgraph_node_set_new, cgraph_node_set_find, cgraph_node_set_add,
18210         cgraph_node_set_remove, dump_cgraph_node_set,
18211         debug_cgraph_node_set): New prototypes.
18212         (csi_end_p, csi_next, csi_node, csi_start, cgraph_node_in_set_p,
18213         cgraph_node_set_size): New inlines.
18214         * tree-pass.h (struct cgraph_node_set_def): New decl to avoid
18215         including cgraph.h.
18216         (struct ipa_opt_pass): Add struct cgraph_node_set_def
18217         argument to function 'write_summary'.
18218         * ipa.c: Include ggc.h.
18219         (hash_cgraph_node_set_element,
18220         eq_cgraph_node_set_element, cgraph_node_set_new,
18221         cgraph_node_set_add, cgraph_node_set_remove,
18222         cgraph_node_set_find, dump_cgraph_node_set,
18223         debug_cgraph_node_set): New functions.
18224         * Makefile.in (ipa.o): Add dependency on GGC_H.
18225
18226 2009-04-20  Ira Rosen  <irar@il.ibm.com>
18227
18228         PR tree-optimization/39675
18229         * tree-vect-loop.c (vect_transform_loop): Remove currently redundant
18230         check of the return code of vect_schedule_slp. Check that
18231         stmt_vec_info still exists for the statement, before checking its
18232         vectorization type.
18233
18234 2009-04-20  Michael Matz  <matz@suse.de>
18235
18236         * Makefile.in (generated_files): Take out $(simple_generated_c).
18237
18238 2009-04-19  Dave Korn  <dave.korn.cygwin@gmail.com>
18239
18240         * config/i386/cygwin-stdint.h (INTPTR_TYPE):  Remove "long".
18241         (UINTPTR_TYPE):  Likewise.
18242
18243 2009-04-19  Joseph Myers  <joseph@codesourcery.com>
18244
18245         PR c/37481
18246         * c-typeck.c (digest_init): Check for initializing an array with a
18247         string literal.
18248
18249 2009-04-19  Joseph Myers  <joseph@codesourcery.com>
18250
18251         PR c/19771
18252         * c-semantics.c (pop_stmt_list): Propagate
18253         STATEMENT_LIST_HAS_LABEL to parent statement list.
18254
18255 2009-04-19  Adam Nemet  <anemet@caviumnetworks.com>
18256
18257         * config/mips/mips.h (mips_tune_attr): New macro.
18258         * config/mips/mips.md (cpu): Use it.
18259
18260 2009-04-19  Joseph Myers  <joseph@codesourcery.com>
18261
18262         PR c/38243
18263         * c-decl.c (shadow_tag_warned): Diagnose use of restrict when
18264         declaring a tag.
18265
18266 2009-04-19  Diego Novillo  <dnovillo@google.com>
18267
18268         * toplev.c (compile_file): Move call to coverage_finish ...
18269         * cgraphunit.c (ipa_passes): ... here.
18270         Call cgraph_process_new_functions.
18271         * ipa-utils.c (get_base_var): Handle CONSTRUCTOR.
18272         * Makefile.in (cgraphunit.o): Add dependency on COVERAGE_H.
18273
18274 2009-04-19  Jan Hubicka  <jh@suse.cz>
18275
18276         * cgraph.c (cgraph_create_edge, cgraph_set_call_stmt): Set proper
18277         cfun.
18278         (dump_cgraph_node): Dump can throw external flag.
18279         * ipa-pure-const.c (propagate): Fix propagation of nothrow flags.
18280
18281 2009-04-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
18282
18283         PR c/32061
18284         PR c++/36954
18285         * doc/invoke.texi: Add -Wlogical-op to -Wextra.
18286         * common.opt (Wlogical-op): Move from here...
18287         * c.opt (Wlogical-op): ... to here.
18288         * c-typeck.c (parser_build_binary_op): Update call to
18289         warn_logical_operator.
18290         * c-opts.c (c_common_post_options): Enable warn_logical_op with
18291         extra_warnings.
18292         * c-common.c (warn_logical_op): Update.
18293         * c-common.h (warn_logical_op): Update declaration.
18294
18295 2009-04-19  Eric Botcazou  <ebotcazou@adacore.com>
18296
18297         * tree.c (protected_set_expr_location): Fix formatting.
18298
18299 2009-04-18  Joseph Myers  <joseph@codesourcery.com>
18300
18301         PR c/27676
18302         * c-typeck.c (readonly_warning): new.
18303         (build_unary_op, build_modify_expr): Use readonly_warning for
18304         storing into something readonly but not const-qualified.
18305
18306 2009-04-18  Joseph Myers  <joseph@codesourcery.com>
18307
18308         PR c/22367
18309         * c-typeck.c (build_unary_op): Check for taking address of
18310         expression of type void.
18311
18312 2009-04-18  Joseph Myers  <joseph@codesourcery.com>
18313
18314         PR c/35210
18315         * c-typeck.c (build_function_call): Check for calling a function
18316         with qualified void return types.  Call require_complete_type when
18317         generating a trap.
18318
18319 2009-04-18  Jan Hubicka  <jh@suse.cz>
18320
18321         * cgraph.c (cgraph_make_edge, dump_cgraph_node, cgraph_set_call_stmt):
18322         Set nothrow flag.
18323         * cgraph.h (struct function): Reduce loop_nest to 30 bits; add
18324         can_throw_external flag.
18325         * ipa-reference.c (ipa_utils_reduced_inorder): Update call.
18326         * ipa-pure-const.c (ignore_edge): New function.
18327         (propagate): Compute order for NOTHROW computation; set NOTHROWs
18328         only over can_throw_external edges.
18329         (local_pure_const): Add nothrow flag.
18330         * ipa-utils.c (searchc): Add ignore_edge callback.
18331         (ipa_utils_reduced_inorder): Add ignore_edge callback.
18332         * ipa-utils.h (ipa_utils_reduced_inorder): Update prototype.
18333         (set_nothrow_function_flags): Update cgraph.
18334         * tree-cfg.c (verify_stmt): Relax nothrow checking when in IPA mode.
18335
18336 2009-04-18  Richard Guenther  <rguenther@suse.de>
18337
18338         PR middle-end/39804
18339         * tree-ssa-ccp.c (fold_stmt_1): New function factored from ...
18340         (fold_stmt): ... this and ...
18341         (fold_stmt_inplace): ... this.
18342         (fold_stmt_1): Fold references in calls and asms.
18343         * tree-cfg.c (remove_useless_stmts_cond): Use fold_stmt.
18344
18345 2009-04-18  Kazu Hirata  <kazu@codesourcery.com>
18346
18347         * tree-vrp.c (ssa_name_nonzero_p): Remove.
18348         * tree.h: Remove the prototype for ssa_name_nonzero_p.
18349
18350 2009-04-18  Kazu Hirata  <kazu@codesourcery.com>
18351
18352         * tree.c (function_args_count): Remove.
18353         * tree.h: Remove the prototype for function_args_count.
18354
18355 2009-04-18  Kazu Hirata  <kazu@codesourcery.com>
18356
18357         * tree-iterator.c (expr_only): Remove.
18358         * tree.h: Remove the prototype for expr_only.
18359
18360 2009-04-18  Kazu Hirata  <kazu@codesourcery.com>
18361
18362         * reginfo.c (cannot_change_mode_set_regs): Remove.
18363         * rtl.h: Remove the prototype for cannot_change_mode_set_regs.
18364
18365 2009-04-08  Anatoly Sokolov  <aesok@post.ru>
18366
18367         * config/avr/avr.md (*rotlsi3_8, *rotlsi3_16, *rotlsi3_24 ): Check
18368         whether operands 0 and 1 overlaps.
18369
18370 2009-04-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>
18371
18372         PR middle-end/36902
18373         * tree-vrp.c (check_array_ref): Pass a location_t instead of a
18374         pointer. Use warning_at instead of warning.
18375         (search_for_addr_array): Likewise.
18376         (check_array_bounds): Likewise.
18377         (check_all_array_refs): Check that the incoming edge is not in the
18378         list of edges to be removed.
18379         (check_all_array_refs): Avoid the temporal pointer.
18380         (vrp_visit_cond_stmt): Fix typo.
18381         (simplify_switch_using_ranges): Handle the case where the switch
18382         index is an integer constant.
18383
18384 2009-04-18  Adam Nemet  <anemet@caviumnetworks.com>
18385
18386         * config/mips/mips.c (mips_final_postscan_insn): Make it static.
18387
18388 2009-04-18  Kazu Hirata  <kazu@codesourcery.com>
18389
18390         * doc/extend.texi, doc/invoke.texi: Fix typos.
18391
18392 2009-04-17  Cary Coutant  <ccoutant@google.com>
18393
18394         * tree-flow-inline.h (get_lineno): Fix inverted test.
18395
18396 2009-04-17  Diego Novillo  <dnovillo@google.com>
18397
18398         * tree-ssa-pre.c (create_expression_by_pieces): Remove
18399         assertion for AVAIL_OUT.
18400
18401 2009-04-17  Mike Frysinger  <vapier@gentoo.org>
18402
18403         PR target/38627
18404         * config/sh/lib1funcs.asm [__ELF__ && __linux__]: Add .note.GNU-stack.
18405         * config/sh/linux-atomic.asm: Likewise.
18406
18407 2009-04-17  Diego Novillo  <dnovillo@google.com>
18408
18409         * except.c (debug_eh_tree): New.
18410         (struct eh_region, struct eh_status): Move ...
18411         * except.h: ... here.
18412         (add_type_for_runtime): Declare extern.
18413         (lookup_type_for_runtime): Likewise.
18414         (debug_eh_tree): Declare.
18415         * Makefile.in (GTFILES): List except.h before except.c
18416
18417 2009-04-17  Diego Novillo  <dnovillo@google.com>
18418
18419         * omp-low.c (create_omp_child_function): Set DECL_CONTEXT for DECL.
18420         * cgraphunit.c (cgraph_build_static_cdtor): Likewise.
18421         * tree-dfa.c (find_referenced_vars_in): Factor out of ...
18422         (find_vars_r): ... here.
18423         * tree-flow.h (find_referenced_vars_in): Declare.
18424         * tree-ssa-pre.c (create_expression_by_pieces): Assert
18425         that AVAIL_OUT exists for BLOCK.
18426         * Makefile.in (CGRAPH_H): Add dependency on cif-code.def
18427         (tree-loop-distribution.o): Fix dependency on TREE_VECTORIZER_H.
18428         (tree-parloops.o): Likewise.
18429
18430 2009-04-17  Simon Baldwin  <simonb@google.com>
18431
18432         * toplev.c (default_tree_printer): Add handling for %E format.
18433
18434 2009-04-17  Diego Novillo  <dnovillo@google.com>
18435
18436         * tree-pretty-print.c (dump_generic_node): Add break after
18437         TREE_BINFO handler.  Handle COMPLEX_TYPE, REAL_TYPE and
18438         FIXED_POINT_TYPE.  Handle NULL TREE_TYPEs.  Handle METHOD_TYPE and
18439         FUNCTION_TYPE together.  Call print_struct_decl when printing
18440         structures and TDF_SLIM is not given.
18441         (print_struct_decl): Fix logic for detecting recursion.
18442
18443 2009-04-17  Rafael Avila de Espindola  <espindola@google.com>
18444
18445         PR 31567
18446         * gcc.c (create_at_file): New.
18447         (compile_input_file_p): New.
18448         (do_spec_1): Use @args files for %i. Use create_at_file for %o.
18449         * main.c (main): Update call to toplev_main.
18450         * toplev.c (toplev_main): Change signature. Call expandargv.
18451         * toplev.h (toplev_main): Change signature.
18452
18453 2009-04-17  Eric Botcazou  <ebotcazou@adacore.com>
18454
18455         * dwarf2out.c (field_byte_offset): Use the type size as the field size
18456         if the latter is not constant.
18457
18458 2009-04-17  David Edelsohn  <edelsohn@gnu.org>
18459
18460         * dbxout.c (xcoff_debug_hooks): Add set_name_debug_nothing.
18461
18462 2009-04-17  Eric Botcazou  <ebotcazou@adacore.com>
18463
18464         * dbxout.c (dbxout_block): Reinstate test on TREE_USED.
18465         * tree-ssa-live.c (remove_unused_scope_block_p): Update TREE_USED bit.
18466
18467 2009-04-17  Richard Guenther  <rguenther@suse.de>
18468
18469         * tree-ssa-structalias.c (get_constraint_for_component_ref):
18470         Handle component references view-converting an invariant address.
18471
18472 2009-04-17  Adam Nemet  <anemet@caviumnetworks.com>
18473
18474         * doc/tm.texi (TARGET_DEFAULT_TARGET_FLAGS,
18475         TARGET_MIN_ANCHOR_OFFSET, TARGET_MAX_ANCHOR_OFFSET,
18476         TARGET_HAVE_SRODATA_SECTION, TARGET_HAVE_TLS,
18477         TARGET_UNWIND_TABLES_DEFAULT, TARGET_TERMINATE_DW2_EH_FRAME_INFO):
18478         Use @deftypevr rather than @deftypevar.
18479
18480 2009-04-17  Richard Guenther  <rguenther@suse.de>
18481
18482         * tree-ssa-forwprop.c (get_prop_dest_stmt): Clean up tuplification.
18483         (get_prop_source_stmt): Likewise.
18484         (can_propagate_from): Likewise.
18485
18486 2009-04-17  Andrew Stubbs  <ams@codesourcery.com>
18487
18488         * configure.ac: Add new AC_SUBST for TM_ENDIAN_CONFIG,
18489         TM_MULTILIB_CONFIG and TM_MULTILIB_EXCEPTIONS_CONFIG.
18490         (--with-multilib-list): Add default value.
18491         * configure: Regenerate.
18492         * Makefile.in (TM_ENDIAN_CONFIG): Define.
18493         (TM_MULTILIB_CONFIG, TM_MULTILIB_EXCEPTIONS_CONFIG): Define.
18494         * config.gcc (sh-*-*): Switch to using TM_ENDIAN_CONFIG,
18495         TM_MULTILIB_CONFIG, and TM_MULTILIB_EXCEPTIONS_CONFIG.
18496         Don't add default cpu to multilib list unnecessarily, but do enable
18497         the relevant compiler option..
18498         Add support for --with-multilib-list=<blank> and
18499         --with-multilib-list=!<somelib> to supress unwanted multilibs.
18500         * config/sh/t-sh (DEFAULT_ENDIAN, OTHER_ENDIAN): New variables.
18501         (MULTILIB_ENDIAN, MULTILIB_CPUS): Delete variables.
18502         (MULTILIB_OPTIONS): Redefine using OTHER_ENDIAN and
18503         TM_MULTILIB_CONFIG.
18504         (MULTILIB_EXCEPTIONS): Add TM_MULTILIB_EXCEPTIONS_CONFIG.
18505         (MULTILIB_OSDIRNAMES): New variable.
18506         * config/sh/t-1e: Delete file.
18507         * config/sh/t-mlib-sh1: Delete file.
18508         * config/sh/t-mlib-sh2: Delete file.
18509         * config/sh/t-mlib-sh2a: Delete file.
18510         * config/sh/t-mlib-sh2a-nofpu: Delete file.
18511         * config/sh/t-mlib-sh2a-single: Delete file.
18512         * config/sh/t-mlib-sh2a-single-only: Delete file.
18513         * config/sh/t-mlib-sh2e: Delete file.
18514         * config/sh/t-mlib-sh3e: Delete file.
18515         * config/sh/t-mlib-sh4: Delete file.
18516         * config/sh/t-mlib-sh4-nofpu: Delete file.
18517         * config/sh/t-mlib-sh4-single: Delete file.
18518         * config/sh/t-mlib-sh4-single-only: Delete file.
18519         * config/sh/t-mlib-sh4a: Delete file.
18520         * config/sh/t-mlib-sh4a-nofpu: Delete file.
18521         * config/sh/t-mlib-sh4a-single: Delete file.
18522         * config/sh/t-mlib-sh4a-single-only: Delete file.
18523         * config/sh/t-mlib-sh4al: Delete file.
18524         * config/sh/t-mlib-sh5-32media: Delete file.
18525         * config/sh/t-mlib-sh5-32media-nofpu: Delete file.
18526         * config/sh/t-mlib-sh5-64media: Delete file.
18527         * config/sh/t-mlib-sh5-64media-nofpu: Delete file.
18528         * config/sh/t-mlib-sh5-compact: Delete file.
18529         * config/sh/t-mlib-sh5-compact-nofpu: Delete file.
18530         * config/sh/t-linux: Don't override MULTILIB_EXCEPTIONS.
18531         * doc/install.texi (Options specification): Add
18532         --with-multilib-list and --with-endian.
18533
18534 2009-04-17  Rafael Avila de Espindola  <espindola@google.com>
18535
18536         * Makefile.in (REVISION_s): Always include quotes. Change ifdef to use
18537         REVISION_c.
18538         (OBJS-common): Add plugin-version.o.
18539         (plugin-version.o): New.
18540         * gcc-plugin.h (plugin_gcc_version): New.
18541         (plugin_default_version_check): New.
18542         (plugin_init_func, plugin_init): Add version argument.
18543         * plugin-version.c: New.
18544         * plugin.c (str_plugin_gcc_version_name): New.
18545         (try_init_one_plugin): Read plugin_gcc_version from the plugin and
18546         pass it to the init function.
18547         (plugin_default_version_check): New.
18548
18549 2009-04-17  Richard Guenther  <rguenther@suse.de>
18550
18551         * tree-ssa-alias.c (refs_may_alias_p_1): Do not use TBAA
18552         for decl-vs-decl disambiguation.
18553
18554 2009-04-17  Andreas Krebbel  <krebbel1@de.ibm.com>
18555
18556         * config/s390/s390.h (s390_tune_attr): New macro definition.
18557         * config/s390/s390.md (cpu attribute): Map to s390_tune_attr.
18558
18559 2009-04-17  Richard Guenther  <rguenther@suse.de>
18560
18561         * tree-ssa-ccp.c (struct fold_stmt_r_data): Remove.
18562         (fold_stmt_r): Likewise.
18563         (maybe_fold_reference): New function.
18564         (fold_gimple_assign): Handle cases fold_stmt_r did.
18565         (fold_stmt): Do not use fold_stmt_r.
18566         (fold_stmt_inplace): Likewise.
18567
18568 2009-04-17  Richard Guenther  <rguenther@suse.de>
18569
18570         * tree-ssa-dom.c (gimple_assign_unary_useless_conversion_p): Remove.
18571         (record_equivalences_from_stmt): Remove useless checks and
18572         simplifications.
18573         * tree-ssa-pre.c (eliminate): Avoid converting a constant if
18574         the type is already suitable.
18575
18576 2009-04-17  Paolo Bonzini  <bonzini@gnu.org>
18577
18578         * config/sh/sh.h (FUNCTION_VALUE): Fix call to sh_promote_prototypes.
18579
18580 2009-04-17  Uros Bizjak  <ubizjak@gmail.com>
18581
18582         * config/arm/sfp-machine.h (__gcc_CMPtype): New typedef.
18583         (CMPtype): Define as __gcc_CMPtype.
18584
18585 2009-04-17  Aurelien Jarno  <aurelien@aurel32.net>
18586
18587         * config.gcc: Add soft-fp/t-softfp and i386/t-linux to tmake_file
18588         for i[34567]86-*-kfreebsd*-gnu*, x86_64-*-kfreebsd*-gnu*.
18589
18590 2009-04-17  Richard Guenther  <rguenther@suse.de>
18591
18592         PR tree-optimization/39746
18593         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Remove
18594         special-casing for builtins and static variable use/def.
18595         (call_may_clobber_ref_p_1): Likewise.
18596
18597 2009-04-16  Ian Lance Taylor  <iant@google.com>
18598
18599         * df.h: Include "timevar.h".
18600         (struct df_problem): Change tv_id field to timevar_id_t.
18601         * tree-pass.h: Include "timevar.h".
18602         (struct opt_pass): Change tv_id field to timevar_id_t.
18603         * timevar.h (timevar_id_t): Define TV_NONE.
18604         * passes.c (execute_one_ipa_transform_pass): Check for tv_id !=
18605         TV_NONE rather than tv_id != 0.
18606         (execute_one_pass): Likewise.
18607         * Makefile.in (DF_H): Add $(TIMEVAR_H).
18608         (TREE_PASS_H): Define.  Change all instances of tree-pass.h in
18609         dependencies to $(TREE_PASS_H).
18610         * bt-load.c (pass_branch_target_load_optimize1): Set tv_id field
18611         to TV_NONE.
18612         (pass_branch_target_load_optimize2): Likewise.
18613         * cfglayout.c (pass_into_cfg_layout_mode): Likewise.
18614         (pass_outof_cfg_layout_mode): Likewise.
18615         * cgraphbuild.c (pass_remove_cgraph_callee_edges): Likewise.
18616         (pass_rebuild_cgraph_edges): Likewise.
18617         (pass_remove_cgraph_callee_edges): Likewise.
18618         * df-core.c (pass_df_initialize_opt): Likewise.
18619         (pass_df_initialize_no_opt): Likewise.
18620         (pass_df_finish): Likewise.
18621         * emit-rtl.c (pass_unshare_all_rtl): Likewise.
18622         * except.c (pass_set_nothrow_function_flags): Likewise.
18623         (pass_convert_to_eh_region_ranges): Likewise.
18624         * final.c (pass_compute_alignments): Likewise.
18625         * function.c (pass_instantiate_virtual_regs): Likewise.
18626         (pass_init_function): Likewise.
18627         (pass_leaf_regs): Likewise.
18628         (pass_match_asm_constraints): Likewise.
18629         * gimple-low.c (pass_lower_cf): Likewise.
18630         (pass_mark_used_blocks): Likewise.
18631         * init-regs.c (pass_initialize_regs): Likewise.
18632         * integrate.c (pass_initial_value_sets): Likewise.
18633         * ira.c (pass_ira): Likewise.
18634         * jump.c (pass_cleanup_barriers): Likewise.
18635         * omp-low.c (pass_expand_omp): Likewise.
18636         (pass_lower_omp): Likewise.
18637         * matrix-reorg.c (pass_ipa_matrix_reorg): Likewise.
18638         * recog.c (pass_split_all_insns): Likewise.
18639         (pass_split_after_reload): Likewise.
18640         (pass_split_before_regstack): Likewise.
18641         (pass_split_before_sched2): Likewise.
18642         (pass_split_for_shorten_branches): Likewise.
18643         * reginfo.c (pass_reginfo_init): Likewise.
18644         (pass_subregs_of_mode_init): Likewise.
18645         (pass_subregs_of_mode_finish): Likewise.
18646         * passes.c (pass_postreload): Likewise.
18647         * stack-ptr-mod.c (pass_stack_ptr_mod): Likewise.
18648         * tree-cfg.c (pass_remove_useless_stmts): Likewise.
18649         (pass_warn_function_return): Likewise.
18650         (pass_warn_function_noreturn): Likewise.
18651         * tree-complex.c (pass_lower_complex): Likewise.
18652         (pass_lower_complex_O0): Likewise.
18653         * tree-if-conv.c (pass_if_conversion): Likewise.
18654         * tree-into-ssa.c (pass_build_ssa): Likewise.
18655         * tree-mudflap.c (pass_mudflap_1): Likewise.
18656         (pass_mudflap_2): Likewise.
18657         * tree-nomudflap.c (pass_mudflap_1): Likewise.
18658         (pass_mudflap_2): Likewise.
18659         * tree-nrv.c (pass_return_slot): Likewise.
18660         * tree-object-size.c (pass_object_sizes): Likewise.
18661         * tree-optimize.c (pass_all_optimizations): Likewise.
18662         (pass_early_local_passes): Likewise.
18663         (pass_all_early_optimizations): Likewise.
18664         (pass_cleanup_cfg): Likewise.
18665         (pass_cleanup_cfg_post_optimizing): Likewise.
18666         (pass_free_datastructures): Likewise.
18667         (pass_free_cfg_annotations): Likewise.
18668         (pass_fixup_cfg): Likewise.
18669         (pass_init_datastructures): Likewise.
18670         * tree-ssa.c (pass_early_warn_uninitialized): Likewise.
18671         (pass_late_warn_uninitialized): Likewise.
18672         (pass_update_address_taken): Likewise.
18673         * tree-ssa-ccp.c (pass_fold_builtins): Likewise.
18674         * tree-ssa-math-opts.c (pass_cse_reciprocals): Likewise.
18675         (pass_cse_sincos): Likewise.
18676         (pass_convert_to_rsqrt): Likewise.
18677         * tree-ssa-structalias.c (pass_build_alias): Likewise.
18678         * tree-stdarg.c (pass_stdarg): Likewise.
18679         * tree-tailcall.c (pass_tail_recursion): Likewise.
18680         (pass_tail_calls): Likewise.
18681         * tree-vect-generic.c (pass_lower_vector): Likewise.
18682         (pass_lower_vector_ssa): Likewise.
18683         * tree-vectorizer.c (pass_ipa_increase_alignment): Likewise.
18684
18685 2009-04-16  Joseph Myers  <joseph@codesourcery.com>
18686
18687         * config/mips/mips.c (mips_rtx_cost_data): Use SOFT_FP_COSTS in
18688         XLR entry.
18689         * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC, MIPS_ARCH_FLOAT_SPEC):
18690         Handle -march=xlr.
18691         * config/mips/xlr.md (ir_xlr_alu): Also accept insn types move,
18692         logical and signext.
18693
18694 2009-04-16  Kaz Kojima  <kkojima@gcc.gnu.org>
18695
18696         PR target/39767
18697         * config/sh/predicates.md (arith_operand): Check if the operand
18698         of TRUNCATE is a REG.
18699
18700 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
18701
18702         * cfgrtl.c (delete_insn_chain_and_edges): Remove.
18703         * rtl.h: Remove the prototype for delete_insn_chain_and_edges.
18704
18705 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
18706
18707         * tree-iterator.c (tsi_split_statement_list_after,
18708         tsi_split_statement_list_before): Remove.
18709         * tree-iterator.h: Remove the prototypes for
18710         tsi_split_statement_list_after and tsi_split_statement_list_before.
18711
18712 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
18713
18714         * tree-ssa-propagate.c (stmt_makes_single_load): Remove.
18715         * tree-ssa-propagate.h: Remove the prototype for
18716         stmt_makes_single_load.
18717
18718 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
18719
18720         * emit-rtl.c (set_mem_attrs_from_reg): Remove.
18721         * rtl.h: Remove the prototype for set_mem_attrs_from_reg.
18722
18723 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
18724
18725         * tree-iterator.c (EXPR_LAST_BODY): Remove.
18726
18727 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
18728
18729         * except.c (eh_region_outer_p): Remove.
18730         * except.h: Remove the prototype for eh_region_outer_p.
18731
18732 2009-04-16  Kazu Hirata  <kazu@codesourcery.com>
18733
18734         * function.c (current_function_assembler_name): Remove.
18735         * function.h: Remove the prototype for
18736         current_function_assembler_name.
18737
18738 2009-04-16  Ian Lance Taylor  <iant@google.com>
18739
18740         * rtlanal.c (alloc_reg_note): New function, broken out of add_reg_note.
18741         (add_reg_note): Call alloc_reg_note.
18742         * rtl.h (alloc_reg_note): Declare.
18743         * combine.c (try_combine): Use alloc_reg_note.
18744         (recog_for_combine, move_deaths): Likewise.
18745         (distribute_notes): Use alloc_reg_note and add_reg_note.
18746         * haifa-sched.c (sched_create_recovery_edges): Use add_reg_note.
18747         * combine-stack-adj.c (adjust_frame_related_expr): Likewise.
18748         * reload1.c (eliminate_regs_1): Use alloc_reg_note.
18749
18750 2009-04-16  Vladimir Makarov  <vmakarov@redhat.com>
18751
18752         PR rtl-optimization/39762
18753         * ira-int.h (ira_register_move_cost, ira_may_move_in_cost,
18754         ira_may_move_out_cost): Add comments about way of their usage.
18755         (ira_get_register_move_cost, ira_get_may_move_cost): New functions.
18756
18757         * ira-conflicts.c (process_regs_for_copy): Use function
18758         ira_get_register_move_cost instead of global
18759         ira_register_move_cost.
18760
18761         * ira-color.c (update_copy_costs, calculate_allocno_spill_cost,
18762         color_pass, move_spill_restore, update_curr_costs): Ditto.
18763
18764         * ira-lives.c (process_single_reg_class_operands): Ditto.
18765
18766         * ira-emit.c (emit_move_list): Ditto.
18767
18768         * ira-costs.c (copy_cost): Don't call ira_init_register_move_cost.
18769         (record_reg_classes): Ditto.  Use functions
18770         ira_get_register_move_cost and ira_get_may_move_cost instead of
18771         global vars ira_register_move_cost, ira_may_move_out_cost and
18772         ira_may_move_in_cost.
18773         (record_address_regs): Don't call ira_init_register_move_cost.
18774         Use function ira_get_may_move_cost instead of global
18775         ira_may_move_in_cost.
18776         (process_bb_node_for_hard_reg_moves): Use function
18777         ira_get_register_move_cost instead of global ira_register_move_cost.
18778         (ira_costs): Don't call ira_init_register_move_cost.
18779
18780 2009-04-16  Richard Guenther  <rguenther@suse.de>
18781
18782         * tree-cfg.c (verify_gimple_assign_binary):
18783         Allow POINTER_PLUS_EXPR-like PLUS_EXPR for vectors.
18784         * ipa-struct-reorg.c (gen_size): Fold the built expressions.
18785         (create_general_new_stmt): Note that this function is broken.
18786
18787 2009-04-16  Rafael Avila de Espindola  <espindola@google.com>
18788
18789         * common.opt (fhelp): Add Var(help_flag).
18790         * gcc-plugin.h (plugin_info): Add help.
18791         * plugin.c (plugin_name_args): Add help.
18792         (register_plugin_info): Set plugin->help.
18793         (print_help_one_plugin): New.
18794         (print_plugins_help): New.
18795         * plugin.h (print_plugins_help): New.
18796         * toplev.c (toplev_main): Call print_plugins_help if needed.
18797
18798 2009-04-16  Richard Guenther  <rguenther@suse.de>
18799
18800         * gimple.c (gimple_copy): Do not clear addresses_taken bitmap.
18801         (gimple_ior_addresses_taken_1): New function.
18802         (gimple_ior_addresses_taken): Likewise.
18803         * gimple.h (struct gimple_statement_with_ops_base): Remove
18804         addresses_taken member.
18805         (gimple_ior_addresses_taken): Declare.
18806         (gimple_addresses_taken, gimple_addresses_taken_ptr,
18807         gimple_set_addresses_taken): Remove.
18808         * ipa-reference.c (mark_address): New function.
18809         (scan_stmt_for_static_refs): Use it for marking addresses taken.
18810         * tree-ssa-operands.c (add_to_addressable_set): Rename to ...
18811         (mark_address_taken): ... this.  Just set TREE_ADDRESSABLE.
18812         (gimple_add_to_addresses_taken): Remove.
18813         (get_tmr_operands): Call mark_address_taken.
18814         (get_asm_expr_operands): Likewise.
18815         (get_expr_operands): Likewise.
18816         (build_ssa_operands): Do not clear the addresses_taken bitmap.
18817         (free_stmt_operands): Do not free it.
18818         * tree-ssa.c (delete_tree_ssa): Likewise.
18819         (execute_update_addresses_taken): Use gimple_ior_addresses_taken.
18820
18821 2009-04-16  Richard Guenther  <rguenther@suse.de>
18822
18823         * gimple.h (walk_stmt_load_store_addr_ops): Declare.
18824         (walk_stmt_load_store_ops): Likewise.
18825         * gimple.c (get_base_loadstore): New function.
18826         (walk_stmt_load_store_addr_ops): Likewise.
18827         (walk_stmt_load_store_ops): Likewise.
18828         * ipa-pure-const.c (check_op): Simplify.
18829         (check_load, check_store): New functions.
18830         (check_stmt): Use walk_stmt_load_store_ops.
18831         * ipa-reference.c (mark_load): Adjust signature.
18832         (mark_store): Likewise.
18833         (scan_stmt_for_static_refs): Use walk_stmt_load_store_addr_ops.
18834
18835 2009-04-16  Rafael Avila de Espindola  <espindola@google.com>
18836
18837         * gcc-plugin.h (plugin_event): Add PLUGIN_INFO.
18838         (plugin_info): New.
18839         * opts.c (common_handle_option): Don't call print_version.
18840         * plugin.c (plugin_name_args): Add version.
18841         (register_plugin_info): New.
18842         (register_callback): Handle PLUGIN_INFO.
18843         (try_init_one_plugin): New.
18844         (init_one_plugin): Use try_init_one_plugin. Only free plugin_name_args
18845         if failed to init.
18846         (finalize_one_plugin): New.
18847         (finalize_plugins): New.
18848         (print_one_plugin): New.
18849         (print_plugins_versions): New.
18850         * plugin.h (print_plugins_versions): New.
18851         (finalize_plugins): New.
18852         * toplev.c (compile_file): Don't call initialize_plugins.
18853         (print_version): Call print_plugins_versions.
18854         (toplev_main): Call initialize_plugins. Print version if needed.
18855         Call finalize_plugins.
18856
18857 2009-04-16  Rafael Avila de Espindola  <espindola@google.com>
18858
18859         * common.opt (fversion): New.
18860         * gcc.c (print_version): New.
18861         (process_command): Don't print the version. Just set print_version.
18862         (main): Print version. Call subprocesses if print_version and
18863         verbose_flag are set.
18864         * opts.c (common_handle_option): Handle OPT_fversion.
18865
18866 2009-04-16  Richard Guenther  <rguenther@suse.de>
18867             Ira Rosen  <irar@il.ibm.com>
18868
18869         PR tree-optimization/39698
18870         * tree-vect-loop.c (get_initial_def_for_reduction): Use the
18871         type of the reduction variable.  Only generate the def if
18872         it is needed.
18873
18874         * omp-low.c (expand_omp_for_generic): When converting to a pointer
18875         make sure to first convert to an integer of the same precision.
18876         * tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer): Retain
18877         the type of the evolution correctly in computing the new
18878         induction variable base.
18879
18880 2009-04-16  Richard Guenther  <rguenther@suse.de>
18881
18882         PR middle-end/39625
18883         * tree-cfg.c (make_blocks): Split statements with to-be
18884         abnormal SSA names on the lhs.
18885
18886 2009-04-16  Paolo Bonzini  <bonzini@gnu.org>
18887
18888         * c-common.c (vector_targets_convertible_p, vector_types_convertible_p):
18889         Use TYPE_VECTOR_OPAQUE instead of targetm.vector_opaque_p.
18890         * c-typeck.c (really_start_incremental_init): Likewise.
18891         * target-def.h (TARGET_VECTOR_OPAQUE_P): Remove.
18892         (TARGET_INITIALIZER): Remove it.
18893         * target.h (struct target): Remove vector_opaque_p.
18894         * tree.c (build_opaque_vector_type): New.
18895         * tree.h (TYPE_VECTOR_OPAQUE): New.
18896         (build_opaque_vector_type): Declare.
18897         * doc/tm.texi (TARGET_VECTOR_OPAQUE_P): Remove.
18898         * config/rs6000/rs6000.c (build_opaque_vector_type,
18899         rs6000_is_vector_type, TARGET_VECTOR_OPAQUE_P): Remove.
18900         (rs6000_init_builtins): Use build_opaque_vector_type for
18901         opaque_V4SI_type_node.
18902
18903 2009-04-15  Catherine Moore  <clm@codesourcery.com>
18904
18905         * debug.h (set_name):  Declare.
18906         * dwarf2out.c (dwarf2out_set_name): Declare.
18907         (dwarf2_debug_hooks): Add set_name.
18908         (find_AT_string): New.
18909         (add_AT_string): Call find_AT_string.
18910         (dwarf2out_set_name): New.
18911         * cp/decl.c (grokdeclarator): Call set_name.
18912         * vmsdbgout.c (vmsdbg_debug_hooks): Add set_name_debug_nothing.
18913         * debug.c (do_nothing_debug_hooks):  Likewise.
18914         * dbxout.c (dbx_debug_hooks): Likewise.
18915         * sdbout.c (sdb_debug_hooks): Likewise.
18916
18917 2009-04-15  Michael Eager  <eager@eagercon.com>
18918
18919         * config/rs6000/rs6000.c (rs6000_function_value): Set function return
18920         reg for single-precision FPU.
18921         * config/rs6000/rs6000.md (movsi_internal1): Only for
18922         !TARGET_SINGLE_FPU.
18923         (movsi_internal1_single): New. Add pattern to move SI values to/from
18924         single-precision FP regs.
18925
18926 2009-04-15  Richard Guenther  <rguenther@suse.de>
18927
18928         * omp-low.c (lower_rec_input_clauses): Build correct address
18929         expressions.
18930         (expand_omp_for_generic): Fix multiplication type.
18931         * tree-loop-distribution.c (build_size_arg): Build a size_t argument.
18932         (generate_memset_zero): Fix types.
18933         * tree-profile.c (prepare_instrumented_value): Correctly
18934         widen a pointer.
18935
18936 2009-04-15  Ian Lance Taylor  <iant@google.com>
18937
18938         * c.opt (Wenum-compare): Enable for C and Objc.  Initialize to -1.
18939         * c-opts.c (c_common_handle_option): For C, set warn_enum_compare
18940         for -Wall and for -Wc++-compat.
18941         (c_common_post_options): For C++, set warn_enum_compare if not
18942         already set.
18943         * c-tree.h (struct c_expr): Add field original_type.
18944         (build_external_ref): Update declaration.
18945         * c-parser.c (c_parser_braced_init): Set original_type.
18946         (c_parser_initelt): Likewise.
18947         (c_parser_expr_no_commas): Likewise.
18948         (c_parser_conditional_expression): Likewise.
18949         (c_parser_cast_expression): Likewise.
18950         (c_parser_unary_expression): Likewise.  Pull setting of
18951         original_code to top of function.
18952         (c_parser_sizeof_expression): Set original_type.
18953         (c_parser_alignof_expression): Likewise.
18954         (c_parser_postfix_expression): Likewise.  Pull setting of
18955         original_code to top of function.
18956         (c_parser_postfix_expression_after_paren_type): Set original_type.
18957         (c_parser_postfix_expression_after_primary): Likewise.
18958         (c_parser_expression): Likewise.
18959         * c-typeck.c (build_external_ref): Add type parameter.  Change all
18960         callers.
18961         (c_expr_sizeof_expr): Set original_type field.
18962         (parser_build_unary_op): Likewise.
18963         (parser_build_binary_op): Likewise.  Optionally warn about
18964         comparisons of enums of different types.
18965         (digest_init): Set original_type field.
18966         (really_start_incremental_init): Likewise.
18967         (push_init_level, pop_init_level): Likewise.
18968         * doc/invoke.texi (Warning Options): -Wenum-compare now
18969         supported in C.
18970
18971 2009-04-15  Richard Guenther  <rguenther@suse.de>
18972
18973         * tree-ssa-pre.c (eliminate): When replacing a PHI node carry
18974         out a necessary conversion.
18975         * tree-ssa-sccvn.c (run_scc_vn): Also assign value-ids to
18976         names we didn't value number.
18977         * tree-mudflap.c (mf_build_check_statement_for): Use correct types.
18978
18979 2009-04-15  Richard Guenther  <rguenther@suse.de>
18980
18981         PR tree-optimization/39764
18982         * tree-ssa-ccp.c (get_value): Canonicalize value with
18983         canonicalize_float_value.
18984
18985 2009-04-15  Jan Hubicka  <jh@suse.cz>
18986
18987         * builtins.def (va_start, va_end, va_copy): Fix my previous commit.
18988         Wrong version of patch.
18989
18990 2009-04-15  Jan Hubicka  <jh@suse.cz>
18991
18992         * builtins.def (va_start, va_end, va_copy): Mark nothrow.
18993
18994 2009-04-15  Nathan Sidwell  <nathan@codesourcery.com>
18995
18996         * config/rs6000/rs6000.c (rs6000_init_builtins): Set TYPE_NAME of
18997         our distinct integral and vector types.
18998
18999 2009-04-15  Rafael Avila de Espindola  <espindola@google.com>
19000
19001         * class.c (build_vtbl_ref_1): Remove call to assemble_external.
19002         * init.c (build_vtbl_address): Remove call to assemble_external.
19003
19004 2009-04-14  Daniel Jacobowitz  <dan@codesourcery.com>
19005
19006         * config/rs6000/rs6000.c (rs6000_dwarf_register_span): Fix debug
19007         output for other floating point modes.
19008
19009 2009-04-14  Diego Novillo  <dnovillo@google.com>
19010
19011         * diagnostic.c (diagnostic_report_diagnostic): Do not
19012         warn about loaded plugins for DK_ERROR and DK_WARNING.
19013         * c-decl.c (declspecs_add_type): Move call to
19014         invoke_plugin_callbacks ...
19015         * c-parser.c (c_parser_declspecs): ... here.
19016         * plugin.c (dump_active_plugins): Tidy output.
19017
19018 2009-04-14  Diego Novillo  <dnovillo@google.com>
19019             Le-Chun Wu  <lcwu@google.com>
19020
19021         * configure.ac: Add --enable-plugin support.
19022         Define ENABLE_PLUGIN and PLUGINLIBS when specified.
19023         * Makefile.in (PLUGIN_H): Define.
19024         Export ENABLE_PLUGIN and GMPINC to site.exp.
19025         Add PLUGINLIBS to link command.
19026         Add/modify dependencies for plugin.o and files including plugin.h.
19027         (plugin.o): New.
19028         * config.in: Regenerate.
19029
19030         * opts.c (common_handle_option): Handle OPT_fplugin_ and
19031         OPT_fplugin_arg_.
19032
19033 2009-04-14  Le-Chun Wu  <lcwu@google.com>
19034
19035         * tree-pass.h (register_one_dump_file): Add a prototype for
19036         register_one_dump_file.
19037         * toplev.c (compile_file): Call initialize_plugins.
19038         (do_compile): Call invoke_plugin_callbacks.
19039         (toplev_main): Call invoke_plugin_callbacks.
19040         * common.opt: Add -fplugin= and -fplugin-arg-.
19041         * gcc-plugin.h: New public header file for plugins to include.
19042         * plugin.c: New source file.
19043         * plugin.h: New internal header file.
19044         * passes.c (register_one_dump_file): Make it external.
19045
19046         * c-parser.c (c_parser_declspecs): Call invoke_plugin_callbacks.
19047
19048 2009-04-14  Diego Novillo  <dnovillo@google.com>
19049
19050         * doc/plugins.texi: New.
19051         * doc/gccint.texi: Add reference to Plugins chapter.
19052         * doc/invoke.texi: Document -fplugin and -fplugin-arg
19053         * diagnostic.c (diagnostic_report_diagnostic): Warn about
19054         loaded plugins, if any.
19055         * timevar.def (TV_PLUGIN_INIT): Define.
19056         (TV_PLUGIN_RUN): Define.
19057         * plugin.c: Include timevar.h
19058         (plugins_active_p): New.
19059         (dump_active_plugins): New.
19060         (debug_active_plugins): New.
19061
19062 2009-04-14  Joseph Myers  <joseph@codesourcery.com>
19063
19064         * config/sol2.h (LINK_ARCH32_SPEC_BASE): Use %R with absolute
19065         library paths.
19066         * config/sparc/sol2-bi.h (LINK_ARCH64_SPEC_BASE): Likewise.
19067
19068 2009-04-14  Kazu Hirata  <kazu@codesourcery.com>
19069
19070         * config/arm/arm.c (arm_rtx_costs_1): Treat a minus with a shift
19071         the same as a minus without a shift.
19072
19073 2009-04-14  Nick Clifton  <nickc@redhat.com>
19074
19075         * config/stormy16/stormy16.md (ineqbranch_1): Do not assume that
19076         comparisons with small integers will always produce a short
19077         branch.
19078
19079 2009-04-14  Rafael Avila de Espindola  <espindola@google.com>
19080
19081         Merge:
19082         2008-12-19  Diego Novillo  <dnovillo@google.com>
19083
19084         * cgraph.c (dump_cgraph_node): Show memory address of NODE.
19085
19086 2009-04-14  Richard Guenther  <rguenther@suse.de>
19087
19088         * tree-cfg.c (verify_gimple_assign_unary): Adjust vector code
19089         verification.
19090         (verify_gimple_assign_binary): Likewise.  Handle shifts and
19091         rotates correctly.
19092         (verify_gimple_phi): Print the mismatched argument position.
19093         * tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer):
19094         Fix types.
19095         (vect_update_init_of_dr): Likewise.
19096         * matrix-reorg.c (transform_access_sites): Do what the
19097         comment suggests.
19098         * omp-low.c (expand_omp_atomic_pipeline): Use the correct types.
19099
19100 2009-04-13  Michael Eager  <eager@eagercon.com>
19101
19102         * config/rs6000/rs6000-c.c: generate defines if rs6000_xilinx_fpu:
19103         _XFPU, _XFPU_SP_LITE, _XFPU_SP_FULL, _XFPU_DP_LITE, _XFPU_DP_FULL
19104         * config/rs6000/xilinx.h: New.  Spec for powerpc-xilinx-eabi
19105         * config.gcc (powerpc-xilinx-eabi): add xilinx.h to tm_file,
19106         remove duplicate config
19107
19108 2009-04-13  Dwarakanath Rajagopal  <dwarak.rajagopal@amd.com>
19109
19110         * ipa-inline.c (cgraph_decide_inlining_of_small_function): Dump
19111         file_name:line_number type locator of the call site.
19112
19113 2009-04-13  Vladimir Makarov  <vmakarov@redhat.com>
19114
19115         * genautomata.c: Put blank after comma.
19116         (automaton_decls): New.
19117         (struct unit_usage): Add comments to member next.
19118         (store_alt_unit_usage): Keep the list ordered.
19119         (unit_present_on_list_p, equal_alternatives_p): New.
19120         (check_regexp_units_distribution): Check units distribution
19121         correctness correctly.
19122         (main): Don't write automata if error is found.  Return correct
19123         exit code.
19124
19125         * config/m68k/cf.md (cfv4_ds): Remove.
19126         (cfv4_pOEP1, cfv4_sOEP1, cfv4_pOEP2,cfv4_sOEP2, cfv4_pOEP3,
19127         cfv4_sOEP3): Assign to cfv4_oep instead of cfv4_ds.
19128
19129         * config/rs6000/power4.md (lsuq_power4, iq_power4, fpq_power4,
19130         power4-load-ext, power4-store, power4-store-update,
19131         power4-fpstore, power4-fpstore-update, power4-two, power4-three,
19132         power4-insert, power4-compare, power4-lmul-cmp, power4-imul-cmp,
19133         power4-lmul, , power4-imul, power4-imul3, power4-sdiv,
19134         power4-sqrt, power4-isync): Modify reservation to make correct
19135         unit distribution to automata.
19136
19137         * config/rs6000/power5.md (iq_power5, fpq_power5, power5-store,
19138         power5-store-update, power5-two, power5-three, power5-lmul,
19139         power5-imul, power5-imul3, power5-sdiv, power5-sqrt): Ditto.
19140
19141 2009-04-13  Adam Nemet  <anemet@caviumnetworks.com>
19142
19143         * except.c (pass_set_nothrow_function_flags): Set name and add
19144         TODO_dump_func.
19145         (set_nothrow_function_flags): Mention in the dump file when
19146         changing a function to nothrow.
19147
19148 2009-04-13  Ozkan Sezer  <sezeroz@gmail.com>
19149
19150         PR/39066
19151         * gbl-ctors.h (DO_GLOBAL_CTORS_BODY): Use __SIZE_TYPE__
19152         instead of unsigned long.
19153
19154 2009-04-13  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
19155
19156         * config/arm/arm.c (return_used_this_function): Remove.
19157         (arm_output_function_prologue): Remove use of
19158         return_used_this_function.
19159         (output_return_instruction): Replace use of
19160         return_used_this_function
19161         by cfun->machine->return_used_this_function.
19162         (arm_output_epilogue): Likewise.
19163         (arm_output_function_epilogue): Likewise.
19164         (thumb_unexpanded_epilogue): Likewise.
19165         * config/arm/arm.h (struct machine_function):
19166         New member return_used_this_function.
19167
19168 2009-04-12  Mark Mitchell  <mark@codesourcery.com>
19169
19170         * doc/install.texi: Correct description of default directory for
19171         --with-gxx-include-dir.
19172
19173 2009-04-12  Eric Botcazou  <ebotcazou@adacore.com>
19174
19175         * fold-const.c (build_range_check): Properly deal with enumeral and
19176         boolean base types.
19177
19178 2009-04-12  Steven Bosscher  <steven@gcc.gnu.org>
19179
19180         * doc/invoke.texi (max_gcse_passes): Remove documentation.
19181         * params.def (PARAM_MAX_GCSE_PASSES): Remove.
19182         * params.h (MAX_GCSE_PASSES): Remove.
19183         * gcse.c (gcse_main): Run CPROP1, PRE or HOIST, and CPROP2
19184         in sequence.  Remove ability to run multiple passes.
19185         (bypass_jumps): Report run as third CPROP pass.
19186
19187 2009-04-12  Adam Nemet  <anemet@caviumnetworks.com>
19188
19189         PR middle-end/39651
19190         * except.c (can_throw_external): Look at each insn in a SEQUENCE
19191         when deciding whether the whole SEQUENCE can throw.
19192
19193 2009-04-12  Uros Bizjak  <ubizjak@gmail.com>
19194
19195         PR target/39740
19196         * config/alpha/predicates.md (local_symbolic_operand): Return 1 for
19197         offseted label references.
19198
19199 2009-04-11  Jan Hubicka  <jh@suse.cz>
19200
19201         * tree-ssa-pre.c (eliminate): Fix call of update_stmt.
19202
19203 2009-04-11  Richard Guenther  <rguenther@suse.de>
19204
19205         PR middle-end/39732
19206         * tree-inline.c (declare_return_variable): Mark DECL_BY_REFERENCE
19207         return variables as TREE_ADDRESSABLE.
19208
19209 2009-04-11  Richard Guenther  <rguenther@suse.de>
19210
19211         PR tree-optimization/39713
19212         * tree-ssa-sccvn.c (vn_get_expr_for): Make sure built
19213         reference trees have SSA_NAME operands.
19214
19215 2009-04-11  Richard Guenther  <rguenther@suse.de>
19216
19217         PR c/39712
19218         * c-gimplify.c (c_gimplify_expr): Adjust check for mismatched
19219         address expressions.
19220
19221 2009-04-11  Dave Korn  <dave.korn.cygwin@gmail.com>
19222
19223         * config/i386/cygwin-stdint.h (INT_LEAST32_TYPE):  Update to
19224         match changes in Cygwin 1.7
19225         (UINT_LEAST32_TYPE, INT_FAST16_TYPE, INT_FAST32_TYPE,
19226         UINT_FAST16_TYPE, UINT_FAST32_TYPE):  Likewise.
19227
19228 2009-04-10  Paolo Bonzini  <bonzini@gnu.org>
19229
19230         PR tree-optimization/39701
19231         * doc/invoke.texi (Optimization Options): Document change in
19232         meaning and initialization of -fdelete-null-pointer-checks.
19233
19234 2009-04-10  H.J. Lu  <hongjiu.lu@intel.com>
19235
19236         PR middle-end/39701
19237         * common.opt (-fdelete-null-pointer-checks): Initialize to 1.
19238
19239         * opts.c (decode_options): Don't set flag_delete_null_pointer_checks
19240         here.
19241
19242         * doc/invoke.texi: Update -fdelete-null-pointer-checks.
19243
19244 2009-04-10  Chao-ying Fu  <fu@mips.com>
19245
19246         * doc/tm.texi (Instruction Output): Document
19247         TARGET_ASM_FINAL_POSTSCAN_INSN.
19248         * target.h (final_postscan_insn): New field in asm_out.
19249         * target-def.h (TARGET_ASM_FINAL_POSTSCAN_INSN): New define.
19250         (TARGET_ASM_OUT): Add TARGET_ASM_FINAL_POSTSCAN_INSN.
19251         * final.c (final_scan_insn): Call
19252         targetm.asm_out.final_postscan_insn after outputting
19253         an asm macro and a normal instruction.
19254
19255         * config/mips/mips.h (FINAL_PRESCAN_INSN): New define.
19256         * config/mips/mips-protos.h (mips_final_prescan_insn): Declare.
19257         * config/mips/mips.c (mips_at_reg_p): New for_each_rtx callback.
19258         (mips_final_prescan_insn, mips_final_postscan_insn): New functions.
19259         (TARGET_ASM_FINAL_POSTSCAN_INSN): New define.
19260
19261 2009-04-10  Paolo Bonzini  <bonzini@gnu.org>
19262
19263         PR middle-end/39701
19264         * fold-const.c (tree_single_nonzero_warnv_p): Pass non-static
19265         variables as non-NULL even with -fdelete-null-pointer-checks.
19266
19267 2009-04-10  H.J. Lu  <hongjiu.lu@intel.com>
19268
19269         * config/rs6000/darwin-vecsave.asm: Remove extra "*/".
19270
19271 2009-04-09  H.J. Lu  <hongjiu.lu@intel.com>
19272
19273         PR target/39678
19274         * config/i386/i386.c (classify_argument): Handle SCmode with
19275         (bit_offset % 64) != 0.
19276
19277 2009-04-09  Sandra Loosemore  <sandra@codesourcery.com>
19278
19279         * doc/invoke.texi (Optimize Options): Add cross-reference to
19280         -Q --help=optimizers examples.
19281
19282 2009-04-10  Ben Elliston  <bje@au.ibm.com>
19283
19284         PR target/36800
19285         * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Do not set
19286         regalign for the reg == fpr and TDmode case.
19287
19288 2009-04-09  David Ayers  <ayers@fsfe.org>
19289
19290         PR objc/29200
19291         * objc/objc-act.c (warn_with_method): Remove helper function.
19292         (check_duplicates): Call warning and inform directly.
19293         (really_start_method): Likewise.
19294
19295 2009-04-09  Paolo Bonzini  <bonzini@gnu.org>
19296
19297         * expmed.c (expand_divmod): Always use a comparison for a division
19298         by a large unsigned integer.
19299
19300         * fold-const.c (tree_single_nonzero_warnv_p): Always treat decls
19301         for things others than variables or functions as nonzero.
19302
19303 2009-04-09  Nick Clifton  <nickc@redhat.com>
19304
19305         * unwind-compat.c: Change copyright header to refer to version
19306         3 of the GNU General Public License with version 3.1 of the
19307         GCC Runtime Library Exception and to point readers at the
19308         COPYING3 and COPYING3.RUNTIME files and the FSF's license web page.
19309         * config/alpha/crtfastmath.c: Likewise.
19310         * config/alpha/linux-unwind.h: Likewise.
19311         * config/alpha/qrnnd.asm: Likewise.
19312         * config/alpha/vms-crt0-64.c: Likewise.
19313         * config/alpha/vms-crt0.c: Likewise.
19314         * config/alpha/vms-dwarf2.asm: Likewise.
19315         * config/alpha/vms-dwarf2eh.asm: Likewise.
19316         * config/alpha/vms-psxcrt0-64.c: Likewise.
19317         * config/alpha/vms-psxcrt0.c: Likewise.
19318         * config/alpha/vms_tramp.asm: Likewise.
19319         * config/arc/initfini.c: Likewise.
19320         * config/arc/lib1funcs.asm: Likewise.
19321         * config/arm/bpabi-v6m.S: Likewise.
19322         * config/arm/bpabi.S: Likewise.
19323         * config/arm/bpabi.c: Likewise.
19324         * config/arm/crti.asm: Likewise.
19325         * config/arm/crtn.asm: Likewise.
19326         * config/arm/ieee754-df.S: Likewise.
19327         * config/arm/ieee754-sf.S: Likewise.
19328         * config/arm/lib1funcs.asm: Likewise.
19329         * config/arm/libunwind.S: Likewise.
19330         * config/arm/linux-atomic.c: Likewise.
19331         * config/arm/mmintrin.h: Likewise.
19332         * config/arm/pr-support.c: Likewise.
19333         * config/arm/unaligned-funcs.c: Likewise.
19334         * config/arm/unwind-arm.c: Likewise.
19335         * config/arm/unwind-arm.h: Likewise.
19336         * config/avr/libgcc.S: Likewise.
19337         * config/bfin/crti.s: Likewise.
19338         * config/bfin/crtlibid.s: Likewise.
19339         * config/bfin/crtn.s: Likewise.
19340         * config/bfin/lib1funcs.asm: Likewise.
19341         * config/bfin/linux-unwind.h: Likewise.
19342         * config/cris/arit.c: Likewise.
19343         * config/cris/cris_abi_symbol.c: Likewise.
19344         * config/darwin-64.c: Likewise.
19345         * config/darwin-crt2.c: Likewise.
19346         * config/darwin-crt3.c: Likewise.
19347         * config/darwin.h: Likewise.
19348         * config/dbxelf.h: Likewise.
19349         * config/dfp-bit.c: Likewise.
19350         * config/dfp-bit.h: Likewise.
19351         * config/elfos.h: Likewise.
19352         * config/fixed-bit.c: Likewise.
19353         * config/fixed-bit.h: Likewise.
19354         * config/fp-bit.c: Likewise.
19355         * config/fp-bit.h: Likewise.
19356         * config/fr30/crti.asm: Likewise.
19357         * config/fr30/crtn.asm: Likewise.
19358         * config/fr30/lib1funcs.asm: Likewise.
19359         * config/freebsd-spec.h: Likewise.
19360         * config/frv/cmovd.c: Likewise.
19361         * config/frv/cmovh.c: Likewise.
19362         * config/frv/cmovw.c: Likewise.
19363         * config/frv/frvbegin.c: Likewise.
19364         * config/frv/frvend.c: Likewise.
19365         * config/frv/lib1funcs.asm: Likewise.
19366         * config/glibc-stdint.h: Likewise.
19367         * config/h8300/clzhi2.c: Likewise.
19368         * config/h8300/crti.asm: Likewise.
19369         * config/h8300/crtn.asm: Likewise.
19370         * config/h8300/ctzhi2.c: Likewise.
19371         * config/h8300/fixunssfsi.c: Likewise.
19372         * config/h8300/lib1funcs.asm: Likewise.
19373         * config/h8300/parityhi2.c: Likewise.
19374         * config/h8300/popcounthi2.c: Likewise.
19375         * config/i386/ammintrin.h: Likewise.
19376         * config/i386/att.h: Likewise.
19377         * config/i386/avxintrin.h: Likewise.
19378         * config/i386/biarch64.h: Likewise.
19379         * config/i386/bmmintrin.h: Likewise.
19380         * config/i386/cpuid.h: Likewise.
19381         * config/i386/cross-stdarg.h: Likewise.
19382         * config/i386/crtfastmath.c: Likewise.
19383         * config/i386/crtprec.c: Likewise.
19384         * config/i386/cygming-crtbegin.c: Likewise.
19385         * config/i386/cygming-crtend.c: Likewise.
19386         * config/i386/cygwin.asm: Likewise.
19387         * config/i386/emmintrin.h: Likewise.
19388         * config/i386/gmm_malloc.h: Likewise.
19389         * config/i386/gthr-win32.c: Likewise.
19390         * config/i386/i386.h: Likewise.
19391         * config/i386/immintrin.h: Likewise.
19392         * config/i386/linux-unwind.h: Likewise.
19393         * config/i386/linux64.h: Likewise.
19394         * config/i386/mm3dnow.h: Likewise.
19395         * config/i386/mmintrin-common.h: Likewise.
19396         * config/i386/mmintrin.h: Likewise.
19397         * config/i386/nmmintrin.h: Likewise.
19398         * config/i386/pmm_malloc.h: Likewise.
19399         * config/i386/pmmintrin.h: Likewise.
19400         * config/i386/smmintrin.h: Likewise.
19401         * config/i386/sol2-c1.asm: Likewise.
19402         * config/i386/sol2-ci.asm: Likewise.
19403         * config/i386/sol2-cn.asm: Likewise.
19404         * config/i386/sol2-gc1.asm: Likewise.
19405         * config/i386/tmmintrin.h: Likewise.
19406         * config/i386/unix.h: Likewise.
19407         * config/i386/w32-unwind.h: Likewise.
19408         * config/i386/wmmintrin.h: Likewise.
19409         * config/i386/x86-64.h: Likewise.
19410         * config/i386/x86intrin.h: Likewise.
19411         * config/i386/xmmintrin.h: Likewise.
19412         * config/ia64/crtbegin.asm: Likewise.
19413         * config/ia64/crtend.asm: Likewise.
19414         * config/ia64/crtfastmath.c: Likewise.
19415         * config/ia64/crti.asm: Likewise.
19416         * config/ia64/crtn.asm: Likewise.
19417         * config/ia64/fde-glibc.c: Likewise.
19418         * config/ia64/lib1funcs.asm: Likewise.
19419         * config/ia64/linux-unwind.h: Likewise.
19420         * config/ia64/quadlib.c: Likewise.
19421         * config/ia64/unwind-ia64.c: Likewise.
19422         * config/linux.h: Likewise.
19423         * config/m32c/m32c-lib1.S: Likewise.
19424         * config/m32c/m32c-lib2-trapv.c: Likewise.
19425         * config/m32c/m32c-lib2.c: Likewise.
19426         * config/m32r/initfini.c: Likewise.
19427         * config/m68hc11/larith.asm: Likewise.
19428         * config/m68hc11/m68hc11-crt0.S: Likewise.
19429         * config/m68k/cf.md: Likewise.
19430         * config/m68k/crti.s: Likewise.
19431         * config/m68k/crtn.s: Likewise.
19432         * config/m68k/lb1sf68.asm: Likewise.
19433         * config/m68k/linux-unwind.h: Likewise.
19434         * config/mcore/crti.asm: Likewise.
19435         * config/mcore/crtn.asm: Likewise.
19436         * config/mcore/lib1.asm: Likewise.
19437         * config/mips/linux-unwind.h: Likewise.
19438         * config/mips/loongson.h: Likewise.
19439         * config/mips/mips16.S: Likewise.
19440         * config/mmix/crti.asm: Likewise.
19441         * config/mmix/crtn.asm: Likewise.
19442         * config/pa/fptr.c: Likewise.
19443         * config/pa/hpux-unwind.h: Likewise.
19444         * config/pa/lib2funcs.asm: Likewise.
19445         * config/pa/linux-atomic.c: Likewise.
19446         * config/pa/linux-unwind.h: Likewise.
19447         * config/pa/milli64.S: Likewise.
19448         * config/pa/quadlib.c: Likewise.
19449         * config/pa/stublib.c: Likewise.
19450         * config/picochip/libgccExtras/adddi3.asm: Likewise.
19451         * config/picochip/libgccExtras/ashlsi3.asm: Likewise.
19452         * config/picochip/libgccExtras/ashlsi3.c: Likewise.
19453         * config/picochip/libgccExtras/ashrsi3.asm: Likewise.
19454         * config/picochip/libgccExtras/ashrsi3.c: Likewise.
19455         * config/picochip/libgccExtras/cmpsi2.asm: Likewise.
19456         * config/picochip/libgccExtras/divmod15.asm: Likewise.
19457         * config/picochip/libgccExtras/divmodhi4.asm: Likewise.
19458         * config/picochip/libgccExtras/divmodsi4.asm: Likewise.
19459         * config/picochip/libgccExtras/longjmp.asm: Likewise.
19460         * config/picochip/libgccExtras/lshrsi3.asm: Likewise.
19461         * config/picochip/libgccExtras/lshrsi3.c: Likewise.
19462         * config/picochip/libgccExtras/parityhi2.asm: Likewise.
19463         * config/picochip/libgccExtras/popcounthi2.asm: Likewise.
19464         * config/picochip/libgccExtras/setjmp.asm: Likewise.
19465         * config/picochip/libgccExtras/subdi3.asm: Likewise.
19466         * config/picochip/libgccExtras/ucmpsi2.asm: Likewise.
19467         * config/picochip/libgccExtras/udivmodhi4.asm: Likewise.
19468         * config/picochip/libgccExtras/udivmodsi4.asm: Likewise.
19469         * config/rs6000/750cl.h: Likewise.
19470         * config/rs6000/altivec.h: Likewise.
19471         * config/rs6000/biarch64.h: Likewise.
19472         * config/rs6000/crtresfpr.asm: Likewise.
19473         * config/rs6000/crtresgpr.asm: Likewise.
19474         * config/rs6000/crtresxfpr.asm: Likewise.
19475         * config/rs6000/crtresxgpr.asm: Likewise.
19476         * config/rs6000/crtsavfpr.asm: Likewise.
19477         * config/rs6000/crtsavgpr.asm: Likewise.
19478         * config/rs6000/darwin-asm.h: Likewise.
19479         * config/rs6000/darwin-fallback.c: Likewise.
19480         * config/rs6000/darwin-fpsave.asm: Likewise.
19481         * config/rs6000/darwin-ldouble.c: Likewise.
19482         * config/rs6000/darwin-tramp.asm: Likewise.
19483         * config/rs6000/darwin-unwind.h: Likewise.
19484         * config/rs6000/darwin-vecsave.asm: Likewise.
19485         * config/rs6000/darwin-world.asm: Likewise.
19486         * config/rs6000/e500crtres32gpr.asm: Likewise.
19487         * config/rs6000/e500crtres64gpr.asm: Likewise.
19488         * config/rs6000/e500crtres64gprctr.asm: Likewise.
19489         * config/rs6000/e500crtrest32gpr.asm: Likewise.
19490         * config/rs6000/e500crtrest64gpr.asm: Likewise.
19491         * config/rs6000/e500crtresx32gpr.asm: Likewise.
19492         * config/rs6000/e500crtresx64gpr.asm: Likewise.
19493         * config/rs6000/e500crtsav32gpr.asm: Likewise.
19494         * config/rs6000/e500crtsav64gpr.asm: Likewise.
19495         * config/rs6000/e500crtsav64gprctr.asm: Likewise.
19496         * config/rs6000/e500crtsavg32gpr.asm: Likewise.
19497         * config/rs6000/e500crtsavg64gpr.asm: Likewise.
19498         * config/rs6000/e500crtsavg64gprctr.asm: Likewise.
19499         * config/rs6000/eabi-ci.asm: Likewise.
19500         * config/rs6000/eabi-cn.asm: Likewise.
19501         * config/rs6000/eabi.asm: Likewise.
19502         * config/rs6000/linux-unwind.h: Likewise.
19503         * config/rs6000/linux64.h: Likewise.
19504         * config/rs6000/paired.h: Likewise.
19505         * config/rs6000/paired.md: Likewise.
19506         * config/rs6000/ppc64-fp.c: Likewise.
19507         * config/rs6000/ppu_intrinsics.h: Likewise.
19508         * config/rs6000/rs6000.h: Likewise.
19509         * config/rs6000/si2vmx.h: Likewise.
19510         * config/rs6000/sol-ci.asm: Likewise.
19511         * config/rs6000/sol-cn.asm: Likewise.
19512         * config/rs6000/spe.h: Likewise.
19513         * config/rs6000/spu2vmx.h: Likewise.
19514         * config/rs6000/sysv4.h: Likewise.
19515         * config/rs6000/tramp.asm: Likewise.
19516         * config/rs6000/vec_types.h: Likewise.
19517         * config/s390/linux-unwind.h: Likewise.
19518         * config/s390/tpf-unwind.h: Likewise.
19519         * config/score/crti.asm: Likewise.
19520         * config/score/crtn.asm: Likewise.
19521         * config/sh/crt1.asm: Likewise.
19522         * config/sh/crti.asm: Likewise.
19523         * config/sh/crtn.asm: Likewise.
19524         * config/sh/divtab-sh4-300.c: Likewise.
19525         * config/sh/divtab-sh4.c: Likewise.
19526         * config/sh/divtab.c: Likewise.
19527         * config/sh/lib1funcs-4-300.asm: Likewise.
19528         * config/sh/lib1funcs-Os-4-200.asm: Likewise.
19529         * config/sh/lib1funcs.asm: Likewise.
19530         * config/sh/lib1funcs.h: Likewise.
19531         * config/sh/linux-atomic.asm: Likewise.
19532         * config/sh/linux-unwind.h: Likewise.
19533         * config/sh/shmedia.h: Likewise.
19534         * config/sh/sshmedia.h: Likewise.
19535         * config/sh/ushmedia.h: Likewise.
19536         * config/sparc/crtfastmath.c: Likewise.
19537         * config/sparc/linux-unwind.h: Likewise.
19538         * config/sparc/sol2-c1.asm: Likewise.
19539         * config/sparc/sol2-ci.asm: Likewise.
19540         * config/sparc/sol2-cn.asm: Likewise.
19541         * config/spu/divmodti4.c: Likewise.
19542         * config/spu/divv2df3.c: Likewise.
19543         * config/spu/float_disf.c: Likewise.
19544         * config/spu/float_unsdidf.c: Likewise.
19545         * config/spu/float_unsdisf.c: Likewise.
19546         * config/spu/float_unssidf.c: Likewise.
19547         * config/spu/mfc_multi_tag_release.c: Likewise.
19548         * config/spu/mfc_multi_tag_reserve.c: Likewise.
19549         * config/spu/mfc_tag_release.c: Likewise.
19550         * config/spu/mfc_tag_reserve.c: Likewise.
19551         * config/spu/mfc_tag_table.c: Likewise.
19552         * config/spu/multi3.c: Likewise.
19553         * config/spu/spu_internals.h: Likewise.
19554         * config/spu/spu_intrinsics.h: Likewise.
19555         * config/spu/spu_mfcio.h: Likewise.
19556         * config/spu/vec_types.h: Likewise.
19557         * config/spu/vmx2spu.h: Likewise.
19558         * config/stormy16/stormy16-lib2.c: Likewise.
19559         * config/svr4.h: Likewise.
19560         * config/sync.c: Likewise.
19561         * config/v850/lib1funcs.asm: Likewise.
19562         * config/vxlib-tls.c: Likewise.
19563         * config/vxlib.c: Likewise.
19564         * config/vxworks-dummy.h: Likewise.
19565         * config/xtensa/crti.asm: Likewise.
19566         * config/xtensa/crtn.asm: Likewise.
19567         * config/xtensa/ieee754-df.S: Likewise.
19568         * config/xtensa/ieee754-sf.S: Likewise.
19569         * config/xtensa/lib1funcs.asm: Likewise.
19570         * config/xtensa/lib2funcs.S: Likewise.
19571         * config/xtensa/linux-unwind.h: Likewise.
19572         * config/xtensa/unwind-dw2-xtensa.c: Likewise.
19573         * config/xtensa/unwind-dw2-xtensa.h: Likewise.
19574         * coretypes.h: Likewise.
19575         * crtstuff.c: Likewise.
19576         * defaults.h: Likewise.
19577         * dwarf2.h: Likewise.
19578         * emutls.c: Likewise.
19579         * gbl-ctors.h: Likewise.
19580         * gcov-io.h: Likewise.
19581         * ginclude/float.h: Likewise.
19582         * ginclude/iso646.h: Likewise.
19583         * ginclude/stdarg.h: Likewise.
19584         * ginclude/stdbool.h: Likewise.
19585         * ginclude/stddef.h: Likewise.
19586         * ginclude/stdfix.h: Likewise.
19587         * ginclude/stdint-gcc.h: Likewise.
19588         * ginclude/tgmath.h: Likewise.
19589         * gthr-aix.h: Likewise.
19590         * gthr-dce.h: Likewise.
19591         * gthr-gnat.c: Likewise.
19592         * gthr-gnat.h: Likewise.
19593         * gthr-lynx.h: Likewise.
19594         * gthr-mipssde.h: Likewise.
19595         * gthr-nks.h: Likewise.
19596         * gthr-posix.c: Likewise.
19597         * gthr-posix.h: Likewise.
19598         * gthr-posix95.h: Likewise.
19599         * gthr-rtems.h: Likewise.
19600         * gthr-single.h: Likewise.
19601         * gthr-solaris.h: Likewise.
19602         * gthr-tpf.h: Likewise.
19603         * gthr-vxworks.h: Likewise.
19604         * gthr-win32.h: Likewise.
19605         * gthr.h: Likewise.
19606         * libgcc2.c: Likewise.
19607         * libgcc2.h: Likewise.
19608         * libgcov.c: Likewise.
19609         * tsystem.h: Likewise.
19610         * typeclass.h: Likewise.
19611         * unwind-c.c: Likewise.
19612         * unwind-compat.h: Likewise.
19613         * unwind-dw2-fde-compat.c: Likewise.
19614         * unwind-dw2-fde-darwin.c: Likewise.
19615         * unwind-dw2-fde-glibc.c: Likewise.
19616         * unwind-dw2-fde.c: Likewise.
19617         * unwind-dw2-fde.h: Likewise.
19618         * unwind-dw2.c: Likewise.
19619         * unwind-dw2.h: Likewise.
19620         * unwind-generic.h: Likewise.
19621         * unwind-pe.h: Likewise.
19622         * unwind-sjlj.c: Likewise.
19623         * unwind.inc: Likewise.
19624         * config/arm/neon-gen.ml: Change generated copyright header to
19625         refer to version 3 of the GNU General Public License with
19626         version 3.1 of the GCC Runtime Library Exception and to point
19627         readers at the COPYING3 and COPYING3.RUNTIME files and the
19628         FSF's license web page.
19629         * config/arm/arm_neon.h: Regenerate.
19630
19631 2009-04-09  Jakub Jelinek  <jakub@redhat.com>
19632
19633         * config/cris/cris.md: Change copyright header to refer to version
19634         3 of the GNU General Public License.
19635         * doc/install.texi2html: Change copyright header to refer to version
19636         3 of the GNU General Public License and to point readers at the
19637         COPYING3 file and the FSF's license web page.
19638         * config/vax/linux.h: Likewise.
19639
19640 2009-04-09  Paolo Bonzini  <bonzini@gnu.org>
19641
19642         * config/i386/i386.md (cmpcc): New.
19643         * config/i386/sync.md (sync_compare_and_swap*): Set FLAGS_REG.
19644         (sync_compare_and_swap_cc*): Delete.
19645
19646         * config/s390/s390.c (s390_compare_emitted): Remove.
19647         (s390_emit_compare): Handle MODE_CC s390_compare_op0 like
19648         s390_compare_emitted used to be handled.  Assert that modes match.
19649         (s390_emit_compare_and_swap): Use s390_emit_compare, do not
19650         refer to sync_compare_and_swap_ccsi.
19651         * config/s390/s390.h (s390_compare_emitted): Remove.
19652         * config/s390/s390.md (seq): Look for MODE_CC s390_compare_op0
19653         instead of s390_compare_emitted.
19654         (stack_protect_test, sync_compare_and_swap_cc): Set s390_compare_op0
19655         instead of s390_compare_emitted.
19656         * config/s390/s390.md (cmpcc): New.
19657         (sync_compare_and_swapqi, sync_compare_and_swaphi): Clobber
19658         CC_REGNUM, do not pretend it's set.
19659         (sync_compare_and_swap_cc*): Delete.
19660         * config/s390/predicates.md (cc_reg_operand): New.
19661
19662         * expr.c (sync_compare_and_swap_cc): Delete.
19663         * optabs.h (sync_compare_and_swap_cc): Delete.
19664         * optabs.c (prepare_cmp_insn): Ignore which specific CCmode
19665         is being used with can_compare_p.
19666         (emit_cmp_and_jump_insn_1): Likewise when looking in the optab.
19667         (find_cc_set): New.
19668         (expand_bool_compare_and_swap): Do not use sync_compare_and_swap_cc,
19669         look for a MODE_CC set instead.  Use emit_store_flag.
19670         (expand_compare_and_swap_loop): Likewise, with some additional
19671         complication to avoid a force_reg when useless.  Use
19672         emit_cmp_and_jump_insns.
19673         * genopinit.c (optabs): Delete sync_compare_and_swap_cc.
19674         * doc/md.texi (sync_compare_and_swap_cc): Merge with
19675         sync_compare_and_swap documentation.
19676
19677 2009-04-09  Jan Hubicka  <jh@suse.cz>
19678
19679         * except.c (find_prev_try): Break out from ....
19680         (duplicate_eh_regions): ... here; properly update prev_try pointers
19681         when duplication part of tree.
19682         (dump_eh_tree): Improve dumping.
19683         (verify_eh_region): New.
19684         (verify_eh_tree): Use it.
19685
19686 2009-04-06  Richard Guenther  <rguenther@suse.de>
19687
19688         * c-gimplify.c (c_gimplify_expr): Fix the invalid GENERIC
19689         &ARRAY addresses by adjusting their types and prepending
19690         a conversion.
19691         * tree-cfg.c (verify_gimple_assign_single): Verify that
19692         addresses are correct.
19693
19694 2009-04-09  Richard Guenther  <rguenther@suse.de>
19695
19696         * tree-ssa-ccp.c (maybe_fold_stmt_addition): Move non-constant
19697         indices into an array reference if possible.
19698         * tree-ssa-forwprop.c (tree_ssa_forward_propagate_single_use_vars):
19699         Fold POINTER_PLUS_EXPR statements with invariant address.
19700
19701 2009-04-09  Alan Modra  <amodra@bigpond.net.au>
19702
19703         PR target/39634
19704         * config.gcc (powerpc64-*-linux*): Always build biarch.
19705
19706 2009-04-09  Joseph Myers  <joseph@codesourcery.com>
19707
19708         PR c/39613
19709         * c-typeck.c (do_case): If case label is not an INTEGER_CST, fold
19710         it and pedwarn if this results in an INTEGER_CST.
19711
19712 2009-04-08  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
19713
19714         * doc/install.texi: Update minimum GMP version.  Remove obsolete
19715         text in MPFR section.
19716
19717 2009-04-08  Jakub Jelinek  <jakub@redhat.com>
19718
19719         * dwarf2out.c (class_scope_p): New static inline.
19720         (class_or_namespace_scope_p): Use it.
19721         (gen_variable_die): Use DW_TAG_member tag for static data member
19722         declarations instead of DW_TAG_variable.
19723
19724         PR middle-end/39573
19725         * omp-low.c (expand_omp_taskreg): Finalize taskreg static local_decls
19726         variables.
19727
19728 2009-04-08  Richard Guenther  <rguenther@suse.de>
19729
19730         * tree-ssa-sccvn.c (valueize_refs): Do not continue to
19731         valueize random data.
19732
19733 2009-04-08  David Edelsohn  <edelsohn@gnu.org>
19734
19735         * config.gcc (aix tm_file):  Add aix-stdint.h.
19736         (aix tm clause use_gcc_stdint):  Set to wrap.
19737         * config/rs6000/aix-stdint.h:  New file.
19738
19739 2009-04-08  Richard Guenther  <rguenther@suse.de>
19740
19741         PR middle-end/36291
19742         * tree-dfa.c (add_referenced_var): Do not recurse into
19743         global initializers.
19744         * tree-ssa-ccp.c (get_symbol_constant_value): Add newly
19745         exposed variables.
19746         (fold_const_aggregate_ref): Likewise.
19747
19748 2009-04-08  Paolo Bonzini  <bonzini@gnu.org>
19749
19750         * recog.c (ordered_comparison_operator): New.
19751         * gensupport.c (std_preds): Add it.
19752         * doc/md.texi (Machine-Independent Predicates): Document it.
19753
19754 2009-04-08  Jan Hubicka  <jh@suse.cz>
19755
19756         * tree-eh.c (cleanup_eh): When not optimizing, do not try EH merging.
19757         * function.h (rtl_eh): Remove exception_handler_label_map.
19758         * except.c (ehl_hash, ehl_eq, add_ehl_entry,
19759         remove_exception_handler_label, for_each_eh_label_1): Remove.
19760         (rtl_remove_unreachable_regions): Remove.
19761         (convert_from_eh_region_ranges): Do not remove unreachable regions.
19762         (find_exception_handler_labels): Don't build the hashtable.
19763         (maybe_remove_eh_handler): Remove.
19764         (for_each_eh_label): Rewrite to walk the tree.
19765         (rest_of_handle_eh): Do not cleanup cfg prior EH construction.
19766         * except.h (maybe_remove_eh_handler): Remove.
19767         * passes.c (init_optimization_passes): Schedule second EH cleanup
19768         before out-of-ssa.
19769         * cfgrtl.c (rtl_delete_block, rtl_merge_blocks,
19770         cfg_layout_merge_blocks): Do not call maybe_remove_eh_handler.
19771
19772 2009-04-08  Paolo Bonzini  <bonzini@gnu.org>
19773
19774         * genoutput.c (validate_optab_operands): New.
19775         (gen_insn, gen_expand): Call it.
19776
19777         * genflags.c (gen_insn): Detect misused iterators.
19778         (main): Pass line_no to gen_insn, exit with status 1 on error.
19779
19780         * genextract.c (line_no): Make global.
19781         (VEC_safe_set_locstr): Change assertion to error message.
19782         (main): Exit with status 1 on error.
19783
19784 2009-04-08  Joseph Myers  <joseph@codesourcery.com>
19785
19786         PR c/39614
19787         PR c/39673
19788         * c-common.h (C_MAYBE_CONST_EXPR_PRE, C_MAYBE_CONST_EXPR_EXPR,
19789         C_MAYBE_CONST_EXPR_INT_OPERANDS, C_MAYBE_CONST_EXPR_NON_CONST,
19790         EXPR_INT_CONST_OPERANDS): Remove duplicate definitions.
19791         * c-convert.c (convert): Do not call fold on results of conversion
19792         functions when the result is a C_MAYBE_CONST_EXPR.
19793         * c-parser.c (c_parser_postfix_expression): Do not fold condition
19794         of __builtin_choose_expr.
19795         * c-typeck.c (remove_c_maybe_const_expr): New.
19796         (build_unary_op, build_conditional_expr, build_compound_expr,
19797         build_binary_op, c_objc_common_truthvalue_conversion): Call
19798         remove_c_maybe_const_expr on any input C_MAYBE_CONST_EXPR with
19799         integer operands.
19800
19801 2009-04-08  Bingfeng Mei  <bmei@broadcom.com>
19802
19803         * fold-const.c (const_binop): Combine two VECTOR_CST under operation
19804         CODE to produce a new one. Add a prototype to use fold_convert_const
19805
19806 2009-04-08  Danny Smith  <dannysmith@users.sourceforge.net>
19807
19808         PR bootstrap/39660
19809         * config/i386/host-mingw32.c (mingw32_gt_pch_use_address): Don't
19810         mix declarations and code.
19811
19812 2009-04-08  Ben Elliston  <bje@au.ibm.com>
19813
19814         * gcc.c: Replace `CC' with `GCC' throughout.
19815
19816 2009-04-07  H.J. Lu  <hongjiu.lu@intel.com>
19817
19818         * doc/invoke.texi: Document Atom support.
19819
19820 2009-04-07  Jason Merrill  <jason@redhat.com>
19821
19822         PR c++/25185
19823         * c-common.h, c-common.c: Add flag_pretty_templates.
19824         * c-opts.c (c_common_handle_option): Set it.
19825         * c.opt: Add -fno-pretty-templates.
19826         * doc/invoke.texi (C++ Dialect Options): Likewise.
19827
19828 2009-04-07  Uros Bizjak  <ubizjak@gmail.com>
19829
19830         * config/ia64/ia64.c (ia64_builtins): Add IA64_BUILTIN_HUGE_VALQ.
19831         (ia64_init_builtins): Handle IA64_BUILTIN_HUGE_VALQ.
19832         (ia64_expand_builtin): Likewise.
19833
19834 2009-04-07  Martin Jambor  <mjambor@suse.cz>
19835
19836         * tree-ssa-alias.c (refs_may_alias_p_1): Check for
19837         is_gimple_min_invariant rather than CONSTANT_CLASS_P so that invariant
19838         ADDR_EXPRS are include too.
19839
19840 2009-04-07  Richard Guenther  <rguenther@suse.de>
19841
19842         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Non-aliased
19843         decls are only used if passes as parameters or if they are
19844         local statics and the call is not to a builtin.
19845         (call_may_clobber_ref_p_1): Likewise.
19846
19847 2009-04-07  Paolo Bonzini  <bonzini@gnu.org>
19848
19849         * expr.c (do_store_flag): Remove last argument.  Simplify code
19850         to avoid duplication of tests already done by can_compare_p.
19851         (expand_expr_real_1): Adjust caller.
19852
19853 2009-04-07  Paolo Bonzini  <bonzini@gnu.org>
19854
19855         * optabs.c (can_compare_p): Test the predicate of a
19856         cbranch and cstore pattern.
19857
19858 2009-04-07  Paolo Bonzini  <bonzini@gnu.org>
19859
19860         * expr.c (convert_move): Use emit_store_flag instead of
19861         "emulating" it.
19862
19863 2009-04-07  Paolo Bonzini  <bonzini@gnu.org>
19864
19865         * config/i386/i386.c (ix86_compare_emitted): Remove.
19866         (ix86_expand_compare, ix86_expand_branch): Handle MODE_CC
19867         ix86_compare_op0 like ix86_compare_emitted used to be handled.
19868         * config/i386/i386.h (ix86_compare_emitted): Remove.
19869         * config/i386/i386.md (stack_protect_test): Set ix86_compare_op0
19870         instead of ix86_compare_emitted.
19871         * config/i386/sync.md (sync_compare_and_swap_cc): Likewise.
19872
19873 2009-04-07  Andrew Stubbs  <ams@codesourcery.com>
19874
19875         * config.gcc (sh-*-*): Add sysroot-suffix.h to tm_file.
19876         Add t-sysroot-suffix to tmake_file.
19877         * config/print-sysroot-suffix.sh: New file.
19878         * config/t-sysroot-suffix: New file.
19879
19880 2009-04-07  Ben Elliston  <bje@au.ibm.com>
19881
19882         * libgcc2.c (INFINITY): Use __builtin_huge_val, not __builtin_inf,
19883         as the latter produces a warning when the target does not support
19884         infinity.
19885
19886 2009-04-07  Ben Elliston  <bje@au.ibm.com>
19887
19888         * dfp.c: Replace type punning assignments with memcpy throughout.
19889         * Makefile.in (dfp.o-warn): Remove.
19890
19891 2009-04-07  Alan Modra  <amodra@bigpond.net.au>
19892
19893         PR target/39634
19894         * config.gcc: Merge powerpc-*-linux* and powerpc64-*-linux*.
19895         Include soft-fp/t-softfp after rs6000/t-linux64.
19896
19897 2009-04-06  Eric Botcazou  <ebotcazou@adacore.com>
19898
19899         * stor-layout.c (set_sizetype): Use the full precision of their
19900         machine mode for bitsize types.
19901
19902 2009-04-06  H.J. Lu  <hongjiu.lu@intel.com>
19903
19904         * config/i386/i386.md: Revert 2 accidental checkins.
19905
19906 2009-04-06  Joey Ye  <joey.ye@intel.com>
19907             Xuepeng Guo  <xuepeng.guo@intel.com>
19908             H.J. Lu  <hongjiu.lu@intel.com>
19909
19910         Atom pipeline model, tuning and insn selection.
19911         * config.gcc (atom): Add atom config options and target.
19912
19913         * config/i386/atom.md: New.
19914
19915         * config/i386/i386.c (atom_cost): New cost.
19916         (m_ATOM): New macro flag.
19917         (initial_ix86_tune_features): Set m_ATOM.
19918         (x86_accumulate_outgoing_args): Likewise.
19919         (x86_arch_always_fancy_math_387): Likewise.
19920         (processor_target): Add Atom cost.
19921         (cpu_names): Add Atom cpu name.
19922         (override_options): Set Atom ISA.
19923         (ix86_issue_rate): New case PROCESSOR_ATOM.
19924         (ix86_adjust_cost): Likewise.
19925
19926         * config/i386/i386.h (TARGET_ATOM): New target macro.
19927         (ix86_tune_indices): Add X86_TUNE_OPT_AGU.
19928         (TARGET_OPT_AGU): New target option.
19929         (target_cpu_default): Add TARGET_CPU_DEFAULT_atom.
19930         (processor_type): Add PROCESSOR_ATOM.
19931
19932         * config/i386/i386.md (cpu): Add new value "atom".
19933         (use_carry, movu): New attr.
19934         (atom.md): Include atom.md.
19935         (adddi3_carry_rex64): Set attr "use_carry".
19936         (addqi3_carry): Likewise.
19937         (addhi3_carry): Likewise.
19938         (addsi3_carry): Likewise.
19939         (*addsi3_carry_zext): Likewise.
19940         (subdi3_carry_rex64): Likewise.
19941         (subqi3_carry): Likewise.
19942         (subhi3_carry): Likewise.
19943         (subsi3_carry): Likewise.
19944         (x86_movdicc_0_m1_rex64): Likewise.
19945         (*x86_movdicc_0_m1_se): Likewise.
19946         (x86_movsicc_0_m1): Likewise.
19947         (*x86_movsicc_0_m1_se): Likewise.
19948         (*adddi_1_rex64): Emit add insn as much as possible.
19949         (*addsi_1): Likewise.
19950         (return_internal): Set atom_unit.
19951         (return_internal_long): Likewise.
19952         (return_pop_internal): Likewise.
19953         (*rcpsf2_sse): Set atom_sse_attr attr.
19954         (*qrt<mode>2_sse): Likewise.
19955         (*prefetch_sse): Likewise.
19956
19957         * config/i386/i386-c.c (ix86_target_macros_internal): New case
19958         PROCESSOR_ATOM.
19959         (ix86_target_macros_internal): Likewise.
19960
19961         * config/i386/sse.md (cpu): Set attr "atom_sse_attr".
19962         (*prefetch_sse_rex): Likewise.
19963         (sse_rcpv4sf2): Likewise.
19964         (sse_vmrcpv4sf2): Likewise.
19965         (sse_sqrtv4sf2): Likewise.
19966         (<sse>_vmsqrt<mode>2): Likewise.
19967         (sse_ldmxcsr): Likewise.
19968         (sse_stmxcsr): Likewise.
19969         (*sse_sfence): Likewise.
19970         (sse2_clflush): Likewise.
19971         (*sse2_mfence): Likewise.
19972         (*sse2_lfence): Likewise.
19973         (avx_movup<avxmodesuffixf2c><avxmodesuffix>): Set attr "movu".
19974         (<sse>_movup<ssemodesuffixf2c>): Likewise.
19975         (avx_movdqu<avxmodesuffix>): Likewise.
19976         (avx_lddqu<avxmodesuffix>): Likewise.
19977         (sse2_movntv2di): Change attr "type" to "ssemov".
19978         (sse2_movntsi): Likewise.
19979         (rsqrtv8sf2): Change attr "type" to "sseadd".
19980         (sse3_addsubv2df3): Set attr "atom_unit".
19981         (sse3_h<plusminus_insn>v4sf3): Likewise.
19982         (*sse2_pmaddwd): Likewise.
19983         (*vec_extractv2di_1_rex64): Likewise.
19984         (*vec_extractv2di_1_avx): Likewise.
19985         (sse2_psadbw): Likewise.
19986         (ssse3_phaddwv8hi3): Likewise.
19987         (ssse3_phaddwv4hi3): Likewise.
19988         (ssse3_phadddv4si3): Likewise.
19989         (ssse3_phadddv2si3): Likewise.
19990         (ssse3_phaddswv8hi3): Likewise.
19991         (ssse3_phaddswv4hi3): Likewise.
19992         (ssse3_phsubwv8hi3): Likewise.
19993         (ssse3_phsubwv4hi3): Likewise.
19994         (ssse3_phsubdv4si3): Likewise.
19995         (ssse3_phsubdv2si3): Likewise.
19996         (ssse3_phsubswv8hi3): Likewise.
19997         (ssse3_phsubswv4hi3): Likewise.
19998         (ssse3_pmaddubsw128): Likewise.
19999         (sse3_pmaddubsw: Likewise.
20000         (ssse3_palignrti): Likewise.
20001         (ssse3_palignrdi): Likewise.
20002
20003 2009-04-06  Gerald Pfeifer  <gerald@pfeifer.com>
20004
20005         * doc/install.texi (Specific): Fix two cross-references to MinGW.
20006
20007 2009-04-06  Richard Guenther  <rguenther@suse.de>
20008
20009         PR tree-optimization/28868
20010         * tree-ssa-pre.c (inserted_phi_names): New bitmap to keep track
20011         of which PHI results we inserted.
20012         (insert_into_preds_of_block): Record inserted PHIs.
20013         (eliminate): Eliminate redundant PHI nodes.
20014         (init_pre): Init inserted_phi_names.
20015
20016 2009-04-06  Richard Guenther  <rguenther@suse.de>
20017
20018         PR tree-optimization/39643
20019         * tree-ssa-ccp.c (ccp_fold): Fold REALPART_EXPRs and
20020         IMAGPART_EXPRs of complex constants.
20021         (execute_fold_all_builtins): If we folded a call queue
20022         TODO_update_address_taken.
20023
20024 2009-04-06  Jan Hubicka  <jh@suse.cz>
20025
20026         PR middle-end/39659
20027         * except.c (remove_unreachable_regions): Propagate may_contain_throw
20028         flag.
20029
20030 2009-04-06  Andrew Stubbs  <ams@codesourcery.com>
20031
20032         * config/sh/lib1funcs.asm (ic_invalidate): Move ICBI out of the
20033         delay slot.
20034         (ic_invalidate_array): Likewise.
20035
20036 2009-04-06  Hariharan Sandanagobalane  <hariharan@picochip.com>
20037
20038         * calls.c (emit_library_call_value_1): Fix a problem with parameter
20039         alignment for library calls.
20040
20041 2009-04-06  Danny Smith  <dannysmith@users.sourceforge.net>
20042
20043         * config.gcc (mingw32 tm_file):  Add mingw-stdint.h.
20044         (mingw32 tm clause use_gcc_stdint):  Set to wrap.
20045         * config/i386/mingw-stdint.h:  New file.
20046
20047 2009-04-05  Richard Guenther  <rguenther@suse.de>
20048
20049         PR tree-optimization/39648
20050         * tree-ssa-sccvn.c (vn_reference_fold_indirect): Work around
20051         our &A vs. &A[0] IL deficiencies.
20052
20053 2009-04-04  Jan Hubicka  <jh@suse.cz>
20054
20055         * except.c (sjlj_find_directly_reachable_regions): Be ready for
20056         removed toplevel regions.
20057         (sjlj_mark_call_sites): Likewise.
20058
20059 2009-04-04  Dave Korn  <dave.korn.cygwin@gmail.com>
20060
20061         * config.gcc (cygwin tm_file):  Add cygwin-stdint.h.
20062         (cygwin tm clause use_gcc_stdint):  Set to wrap.
20063         * config/i386/cygwin-stdint.h:  New file.
20064
20065 2009-04-04  Richard Guenther  <rguenther@suse.de>
20066
20067         * Makefile.in (tree-ssa-copy.o): Add $(CFGLOOP_H) dependency.
20068         * tree-ssa-copy.c (init_copy_prop): Do not propagate through
20069         single-argument PHIs if we are in loop-closed SSA form.
20070         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Pass extra guards
20071         for the pre-condition.
20072         (slpeel_tree_peel_loop_to_edge): Likewise.
20073         (vect_build_loop_niters): Take an optional sequence to append stmts.
20074         (vect_generate_tmps_on_preheader): Likewise.
20075         (vect_do_peeling_for_loop_bound): Take extra guards for the
20076         pre-condition.
20077         (vect_do_peeling_for_alignment): Adjust.  Unconditionally apply
20078         the cost model check.
20079         (vect_loop_versioning): Take stmt and stmt list to put pre-condition
20080         guards if we are going to peel.  Do not apply versioning in that case.
20081         * tree-vectorizer.h (vect_loop_versioning): Adjust declaration.
20082         (vect_do_peeling_for_loop_bound): Likewise.
20083         * tree-vect-loop.c (vect_transform_loop): If we are peeling for
20084         loop bound only record extra pre-conditions, do not apply loop
20085         versioning.
20086
20087 2009-04-04  Richard Guenther  <rguenther@suse.de>
20088
20089         * tree-ssa-operands.c (pop_stmt_changes): Remove automatic
20090         renaming code.
20091
20092 2009-04-04  Jan Hubicka  <jh@suse.cz>
20093
20094         * tree-ssa-uncprop.c (associate_equivalences_with_edges): Use
20095         last_basic_block for size of bb->index indexed array.
20096         * bt-load.c (compute_defs_uses_and_gen, compute_kill,
20097         compute_out, link_btr_uses, build_btr_def_use_webs,
20098         build_btr_def_use_webs, migrate_btr_defs): Likewise.
20099
20100 2009-04-04  Jan Hubicka  <jh@suse.cz>
20101
20102         * except.c (remove_eh_handler_and_replace): Break out from ...
20103         (remove_eh_handler): ... here.
20104         (bring_to_root): New function.
20105         (remove_unreachable_regions): Collect MUST_NOT_THROW, unify runtime
20106         handled ones, bring others to root of tree.
20107
20108 2009-04-04  Jan Hubicka  <jh@suse.cz>
20109
20110         * tree-eh.c (tree_empty_eh_handler_p): Pattern match more curefully.
20111         (all_phis_safe_to_merge): New function.
20112         (update_info): New structure.
20113         (make_eh_edge_and_update_phi, update_eh_edges): New functions.
20114         (cleanup_empty_eh): Update SSA if possible.
20115
20116 2009-04-04  Richard Guenther  <rguenther@suse.de>
20117
20118         * tree-ssa.c (verify_ssa): With -O0 we do not need VOPs.
20119         * tree-ssa-operands.c (append_vdef): Do not append VOPs at -O0.
20120         (append_vuse): Likewise.
20121
20122 2009-04-04  Jakub Jelinek  <jakub@redhat.com>
20123
20124         * unwind-dw2.h (_Unwind_FrameState): Add REG_UNDEFINED enum value.
20125         * unwind-dw2.c (execute_cfa_program): Set how to REG_UNDEFINED
20126         instead of REG_UNSAVED for DW_CFA_undefined.
20127         (uw_update_context_1): Handle REG_UNDEFINED the same as REG_UNSAVED.
20128         (uw_update_context): If RA column is REG_UNDEFINED, mark it as
20129         outermost frame.
20130
20131 2009-04-04  Richard Earnshaw  <rearnsha@arm.com>
20132
20133         PR target/39501
20134         * arm.md (movsfcc): Disable if not TARGET_HARD_FLOAT.
20135         * testsuite/gcc.c-torture/execute/pr39501.c: New file.
20136         * testsuite/gcc.c-torture/execute/pr39501.x: New file.
20137
20138 2009-04-04  Richard Guenther  <rguenther@suse.de>
20139
20140         PR tree-optimization/8781
20141         PR tree-optimization/37892
20142         * tree-ssa-sccvn.h (vn_reference_fold_indirect): Declare.
20143         * tree-ssa-sccvn.c (vn_reference_fold_indirect): New function.
20144         (valueize_refs): Call it for *& valueizations.
20145         (shared_reference_ops_from_ref): Rename to ...
20146         (valueize_shared_reference_ops_from_ref): ... this and valueize.
20147         (shared_reference_ops_from_call): Rename to ...
20148         (valueize_shared_reference_ops_from_call): ... this and valueize.
20149         (vn_reference_lookup): Update.
20150         (visit_reference_op_call): Likewise.
20151         * tree-ssa-pre.c (phi_translate_1): Fold *&.
20152         (eliminate): Value-replace the call address in call statements.
20153
20154 2009-04-04  Richard Guenther  <rguenther@suse.de>
20155
20156         PR tree-optimization/39636
20157         * tree-ssa-forwprop.c
20158         (forward_propagate_addr_into_variable_array_index): Check for
20159         GIMPLE_ASSIGN before accessing the rhs code.
20160
20161 2009-04-03  Jason Merrill  <jason@redhat.com>
20162
20163         * stor-layout.c (set_sizetype): Set TYPE_CANONICAL.
20164
20165 2009-04-03  Steve Ellcey  <sje@cup.hp.com>
20166
20167         * config/ia64/ia64.md (extendsfdf2, extendsfxf2, extenddfxf2,
20168         truncdfsf2, truncxfsf2, truncxfdf2, floatdixf2, fix_truncsfdi2,
20169         fix_truncdfdi2, fix_truncxfdi2, fix_truncxfdi2_alts, floatunsdisf2,
20170         floatunsdidf2, floatunsdixf2, fixuns_truncsfdi2, fixuns_truncdfdi2,
20171         fixuns_truncxfdi2, fixuns_truncxfdi2_alts, divsi3_internal,
20172         smuldi3_highpart, umuldi3_highpart, ctzdi2, *getf_exp_xf,
20173         divdi3_internal_lat, divdi3_internal_thr, mulditi3, *mulditi3_internal,
20174         umulditi3, *umulditi3_internal, addsf3, mulsf3, abssf2, negsf2,
20175         *nabssf2, sminsf3, smaxsf3, *maddsf4, *msubsf4, *nmulsf3, *nmaddsf4,
20176         *nmaddsf4_alts, divsf3, *sqrt_approx, sqrtsf2, sqrtsf2_internal_thr,
20177         adddf3, *adddf3_trunc, muldf3, *muldf3_trunc, absdf2, negdf2, *nabsdf2,
20178         smindf3, smaxdf3, *madddf4, *madddf4_trunc, *msubdf4, *msubdf4_trunc,
20179         *nmuldf3, *nmuldf3_trunc, *nmadddf4, *nmadddf4_alts, *nmadddf4_truncsf,
20180         *nmadddf4_truncsf_alts, divdf3, sqrtdf2, sqrtdf2_internal_thr, divxf3,
20181         sqrtxf2, sqrtxf2_internal_thr, *recip_approx):
20182         Use fr_reg_or_fp01_operand instead of fr_register_operand
20183
20184         * config/ia64/div.md (extend<mode>rf2, truncrf<mode>2,
20185         recip_approx_rf, divsf3_internal_thr, divsf3_internal_lat,
20186         divdf3_internal_thr, divdf3_internal_lat divxf3_internal): Ditto.
20187
20188 2009-04-03  Vladimir Makarov  <vmakarov@redhat.com>
20189
20190         PR rtl-optimization/39607
20191         PR rtl-optimization/39631
20192
20193         Revert:
20194
20195         2009-03-30  Vladimir Makarov  <vmakarov@redhat.com>
20196         * reload.c (push_reload, find_dummy_reload): Use df_get_live_out
20197         instead of DF_LR_OUT.
20198         * ira-lives.c (process_bb_node_lives): Ditto.
20199         * ira-color.c (ira_loop_edge_freq): Use df_get_live_{out,in}
20200         instead of DF_LR_{OUT,IN}.
20201         * ira-emit.c (generate_edge_moves, add_ranges_and_copies): Ditto.
20202         * ira-build.c (create_bb_allocnos, create_loop_allocnos): Ditto.
20203
20204 2009-04-03  Steven Bosscher  <steven@gcc.gnu.org>
20205
20206         * omp-low.c (pass_expand_omp): Don't claim to provide PROP_gimple_lomp.
20207         (execute_lower_omp): Always run but take the short way out if -fopenmp
20208         is not given.
20209         (gate_lower_omp): Remove, forcing the pass manager to always run the
20210         pass and always set PROP_gimple_lomp.
20211         (pass_lower_omp): Remove gate function.
20212         * matrix-reorg.c (pass_ipa_matrix_reorg): Don't claim to provide
20213         PROP_trees.  Instead, require it.
20214         * ipa-cp.c (pass_ipa_cp): Likewise.
20215         * ipa-inline.c (pass_early_inline): Don't claim to provide PROP_cfg.
20216         (pass_ipa_early_inline, pass_inline_parameters, pass_ipa_inline): Idem.
20217         * tree-profile.c (pass_tree_profile): Don't claim to provide PROP_cfg
20218         and PROP_gimple_leh.
20219
20220 2009-04-03  Richard Guenther  <rguenther@suse.de>
20221
20222         PR middle-end/13146
20223         PR tree-optimization/23940
20224         PR tree-optimization/33237
20225         PR middle-end/33974
20226         PR middle-end/34093
20227         PR tree-optimization/36201
20228         PR tree-optimization/36230
20229         PR tree-optimization/38049
20230         PR tree-optimization/38207
20231         PR tree-optimization/38230
20232         PR tree-optimization/38301
20233         PR tree-optimization/38585
20234         PR middle-end/38895
20235         PR tree-optimization/38985
20236         PR tree-optimization/39299
20237         * tree-ssa-structalias.h: Remove.
20238         * tree-ssa-operands.h (NULL_USE_OPERAND_P): Make of type use_operand_p.
20239         (NULL_DEF_OPERAND_P): Make of type def_operand_p.
20240         (struct vuse_element_d): Remove.
20241         (struct vuse_vec_d): Likewise.
20242         (VUSE_VECT_NUM_ELEM, VUSE_VECT_ELEMENT_NC, VUSE_ELEMENT_PTR_NC,
20243         VUSE_ELEMENT_VAR_NC, VUSE_VECT_ELEMENT, VUSE_ELEMENT_PTR,
20244         SET_VUSE_VECT_ELEMENT, SET_VUSE_ELEMENT_VAR, SET_VUSE_ELEMENT_PTR,
20245         VUSE_ELEMENT_VAR): Likewise.
20246         (struct voptype_d): Likewise.
20247         (NUM_VOP_FREE_BUCKETS): Likewise.
20248         (struct ssa_operands): Remove vop_free_buckets and mpt_table fields.
20249         (struct stmt_operands_d): Remove.
20250         (VUSE_OP_PTR, VUSE_OP, SET_VUSE_OP, VUSE_NUM, VUSE_VECT,
20251         VDEF_RESULT_PTR, VDEF_RESULT, VDEF_OP_PTR, VDEF_OP, SET_VDEF_OP,
20252         VDEF_NUM, VDEF_VECT): Likewise.
20253         (copy_virtual_operands): Remove.
20254         (operand_build_cmp): Likewise.
20255         (create_ssa_artificial_load_stmt): Likewise.
20256         (enum ssa_op_iter_type): Remove ssa_op_iter_vdef.
20257         (struct ssa_operand_iterator_d): Remove vuses, vdefs, mayusesm
20258         vuse_index and mayuse_index members.  Pack and move done and iter_type
20259         members to the front.
20260         (SSA_OP_VMAYUSE): Remove.
20261         (SSA_OP_VIRTUAL_USES): Adjust.
20262         (FOR_EACH_SSA_VDEF_OPERAND): Remove.
20263         (unlink_stmt_vdef): Declare.
20264         (add_to_addressable_set): Remove.
20265         * tree-vrp.c (stmt_interesting_for_vrp): Adjust.
20266         (vrp_visit_stmt): Likewise.
20267         * doc/tree-ssa.texi (Alias analysis): Update.
20268         * doc/invoke.texi (max-aliased-vops): Remove docs.
20269         (avg-aliased-vops): Likewise.
20270         * tree-into-ssa.c (syms_to_rename): Remove.
20271         (need_to_update_vops_p): Likewise.
20272         (need_to_initialize_update_ssa_p): Rename to ...
20273         (update_ssa_initialized_fn): ... this.  Track function we are
20274         initialized for.
20275         (symbol_marked_for_renaming): Simplify.
20276         (add_new_name_mapping): Do not set need_to_update_vops_p.
20277         (dump_currdefs): Use SYMS_TO_RENAME.
20278         (rewrite_update_stmt): Always walk all uses/defs.
20279         (dump_update_ssa): Adjust.
20280         (init_update_ssa): Take function argument.  Track what we are
20281         initialized for.
20282         (delete_update_ssa): Reset SYMS_TO_RENAME and update_ssa_initialized_fn.
20283         (create_new_def_for): Initialize for cfun, assert we are initialized
20284         for cfun.
20285         (mark_sym_for_renaming): Simplify.
20286         (mark_set_for_renaming): Do not initialize update-ssa.
20287         (need_ssa_update_p): Simplify.  Take function argument.
20288         (name_mappings_registered_p): Assert we ask for the correct function.
20289         (name_registered_for_update_p): Likewise.
20290         (ssa_names_to_replace): Likewise.
20291         (release_ssa_name_after_update_ssa): Likewise.
20292         (update_ssa): Likewise.  Use SYMS_TO_RENAME.
20293         (dump_decl_set): Do not print a newline.
20294         (debug_decl_set): Do it here.
20295         (dump_update_ssa): And here.
20296         * tree-ssa-loop-im.c (move_computations): Adjust.
20297         (movement_possibility): Likewise.
20298         (determine_max_movement): Likewise.
20299         (gather_mem_refs_stmt): Likewise.
20300         * tree-dump.c (dequeue_and_dump): Do not handle SYMBOL_MEMORY_TAG
20301         or NAME_MEMORY_TAG.
20302         * tree-complex.c (update_all_vops): Remove.
20303         (expand_complex_move): Adjust.
20304         * tree-ssa-loop-niter.c (chain_of_csts_start): Use NULL_TREE.
20305         Simplify test for memory referencing statement.  Exclude
20306         non-invariant ADDR_EXPRs.
20307         * tree-pretty-print.c (dump_generic_node): Do not handle memory tags.
20308         * tree-loop-distribution.c (generate_memset_zero): Adjust.
20309         (rdg_flag_uses): Likewise.
20310         * tree-tailcall.c (suitable_for_tail_opt_p): Remove memory-tag
20311         related code.
20312         (tree_optimize_tail_calls_1): Also split the
20313         edge from the entry block if we have degenerate PHI nodes in
20314         the first basic block.
20315         * tree.c (init_ttree): Remove memory-tag related code.
20316         (tree_code_size): Likewise.
20317         (tree_node_structure): Likewise.
20318         (build7_stat): Re-write to be build6_stat.
20319         * tree.h (MTAG_P, TREE_MEMORY_TAG_CHECK, TMR_TAG): Remove.
20320         (SSA_VAR_P): Adjust.
20321         (struct tree_memory_tag): Remove.
20322         (struct tree_memory_partition_tag): Likewise.
20323         (union tree_node): Adjust.
20324         (build7): Re-write to be build6.
20325         * tree-pass.h (pass_reset_cc_flags): Remove.
20326         (TODO_update_address_taken): New flag.
20327         (pass_simple_dse): Remove.
20328         * ipa-cp.c (ipcp_update_callgraph): Update SSA form.
20329         * params.h (MAX_ALIASED_VOPS): Remove.
20330         (AVG_ALIASED_VOPS): Likewise.
20331         * omp-low.c (expand_omp_taskreg): Update SSA form.
20332         * tree-ssa-dse.c (dse_optimize_stmt): Properly query if the rhs
20333         aliases the lhs in a copy stmt.
20334         * tree-ssa-dse.c (struct address_walk_data): Remove.
20335         (memory_ssa_name_same): Likewise.
20336         (memory_address_same): Likewise.
20337         (get_kill_of_stmt_lhs): Likewise.
20338         (dse_possible_dead_store_p): Simplify, use the oracle.  Handle
20339         unused stores.  Look through PHI nodes into post-dominated regions.
20340         (dse_optimize_stmt): Simplify.  Properly remove stores.
20341         (tree_ssa_dse): Compute dominators.
20342         (execute_simple_dse): Remove.
20343         (pass_simple_dse): Likewise.
20344         * ipa-reference.c (scan_stmt_for_static_refs): Open-code
20345         gimple_loaded_syms and gimple_stored_syms computation.
20346         * toplev.c (dump_memory_report): Dump alias and pta stats.
20347         * tree-ssa-sccvn.c (vn_reference_compute_hash): Simplify.
20348         (vn_reference_eq): Likewise.
20349         (vuses_to_vec, copy_vuses_from_stmt, vdefs_to_vec,
20350         copy_vdefs_from_stmt, shared_lookup_vops, shared_vuses_from_stmt,
20351         valueize_vuses): Remove.
20352         (get_def_ref_stmt_vuses): Simplify.  Rename to ...
20353         (get_def_ref_stmt_vuse): ... this.
20354         (vn_reference_lookup_2): New function.
20355         (vn_reference_lookup_pieces): Use walk_non_aliased_vuses for
20356         walking equivalent vuses.  Simplify.
20357         (vn_reference_lookup): Likewise.
20358         (vn_reference_insert): Likewise.
20359         (vn_reference_insert_pieces): Likewise.
20360         (visit_reference_op_call): Simplify.
20361         (visit_reference_op_load): Likewise.
20362         (visit_reference_op_store): Likewise.
20363         (init_scc_vn): Remove shared_lookup_vuses initialization.
20364         (free_scc_vn): Remove shared_lookup_vuses freeing.
20365         (sort_vuses, sort_vuses_heap): Remove.
20366         (get_ref_from_reference_ops): Export.
20367         * tree-ssa-sccvn.h (struct vn_reference_s): Replace vuses
20368         vector with single vuse pointer.
20369         (vn_reference_lookup_pieces, vn_reference_lookup,
20370         vn_reference_insert, vn_reference_insert_pieces): Adjust prototypes.
20371         (shared_vuses_from_stmt): Remove.
20372         (get_ref_from_reference_ops): Declare.
20373         * tree-ssa-loop-manip.c (slpeel_can_duplicate_loop_p): Adjust.
20374         * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Remove
20375         memory-tag related code.
20376         * tree-ssa-ccp.c (get_symbol_constant_value): Remove memory-tag code.
20377         (likely_value): Add comment, skip static-chain of call statements.
20378         (surely_varying_stmt_p): Adjust.
20379         (gimplify_and_update_call_from_tree): Likewise.
20380         (execute_fold_all_builtins): Do not rebuild alias info.
20381         (gimplify_and_update_call_from_tree): Properly update VOPs.
20382         * tree-ssa-loop-ivopts.c (get_ref_tag): Remove.
20383         (copy_ref_info): Remove memory-tag related code.
20384         * tree-call-cdce.c (tree_call_cdce): Rename the VOP.
20385         * ipa-pure-const.c (check_decl): Remove memory-tag related code.
20386         (check_stmt): Open-code gimple_loaded_syms and gimple_stored_syms
20387         computation.
20388         * tree-ssa-dom.c (gimple_p): Remove typedef.
20389         (eliminate_redundant_computations): Adjust.
20390         (record_equivalences_from_stmt): Likewise.
20391         (avail_expr_hash): Likewise.
20392         (avail_expr_eq): Likewise.
20393         * tree-ssa-propagate.c (update_call_from_tree): Properly update VOPs.
20394         (stmt_makes_single_load): Likewise.
20395         (stmt_makes_single_store): Likewise.
20396         * tree-ssa-alias.c: Rewrite completely.
20397         (debug_memory_partitions, dump_mem_ref_stats, debug_mem_ref_stats,
20398         debug_mem_sym_stats, dump_mem_sym_stats_for_var,
20399         debug_all_mem_sym_stats, debug_mp_info, update_mem_sym_stats_from_stmt,
20400         delete_mem_ref_stats, create_tag_raw, dump_points_to_info,
20401         dump_may_aliases_for, debug_may_aliases_for, new_type_alias):
20402         Remove public functions.
20403         (pass_reset_cc_flags): Remove.
20404         (pass_build_alias): Move ...
20405         * tree-ssa-structalias.c (pass_build_alias): ... here.
20406         * tree-ssa-alias.c (may_be_aliased): Move ...
20407         * tree-flow-inline.h (may_be_aliased): ... here.
20408         tree-ssa-alias.c (struct count_ptr_d, count_ptr_derefs,
20409         count_uses_and_derefs): Move ...
20410         * gimple.c: ... here.
20411         * gimple.h (count_uses_and_derefs): Declare.
20412         * tree-ssa-alias.c (dump_alias_stats, ptr_deref_may_alias_global_p,
20413         ptr_deref_may_alias_decl_p, ptr_derefs_may_alias_p,
20414         same_type_for_tbaa, nonaliasing_component_refs_p, decl_refs_may_alias_p,
20415         indirect_ref_may_alias_decl_p, indirect_refs_may_alias_p,
20416         ref_maybe_used_by_call_p, ref_maybe_used_by_stmt_p,
20417         call_may_clobber_ref_p, stmt_may_clobber_ref_p, maybe_skip_until,
20418         get_continuation_for_phi, walk_non_aliased_vuses, walk_aliased_vdefs):
20419         New functions.
20420         * tree-dfa.c (refs_may_alias_p): Move ...
20421         * tree-ssa-alias.c (refs_may_alias_p): ... here.  Extend.
20422         * tree-ssa-alias.h: New file.
20423         * tree-ssa-sink.c (is_hidden_global_store): Adjust.
20424         (statement_sink_location): Likewise.
20425         * opts.c (decode_options): Do not adjust max-aliased-vops or
20426         avg-aliased-vops values.
20427         * timevar.def (TV_TREE_MAY_ALIAS): Remove.
20428         (TV_CALL_CLOBBER): Likewise.
20429         (TV_FLOW_SENSITIVE): Likewise.
20430         (TV_FLOW_INSENSITIVE): Likewise.
20431         (TV_MEMORY_PARTITIONING): Likewise.
20432         (TV_ALIAS_STMT_WALK): New timevar.
20433         * tree-ssa-loop-ivcanon.c (empty_loop_p): Adjust.
20434         * tree-ssa-address.c (create_mem_ref_raw): Use build6.
20435         (get_address_description): Remove memory-tag related code.
20436         * tree-ssa-ifcombine.c (bb_no_side_effects_p): Adjust.
20437         * treestruct.def (TS_MEMORY_TAG, TS_MEMORY_PARTITION_TAG): Remove.
20438         * tree-eh.c (cleanup_empty_eh): Do not leave stale SSA_NAMEs
20439         and immediate uses in statements.  Document.
20440         * gimple-pretty-print.c (dump_gimple_mem_ops): Adjust.
20441         (dump_symbols): Remove.
20442         (dump_gimple_mem_ops): Do not dump loaded or stored syms.
20443         * alias.c (get_deref_alias_set): New function split out from ...
20444         (get_alias_set): ... here.
20445         * alias.h (get_deref_alias_set): Declare.
20446         * tree-vect-data-refs.c (vect_create_data_ref_ptr): Remove unused
20447         type parameter.  Remove restrict pointer handling.  Create a
20448         ref-all pointer in case type-based alias sets do not conflict.
20449         (vect_analyze_data_refs): Remove SMT related code.
20450         * tree-vect-stmts.c (vectorizable_store): Re-instantiate TBAA assert.
20451         (vectorizable_load): Likewise.
20452         * tree-data-ref.h (struct dr_alias): Remove symbol_tag field.
20453         (DR_SYMBOL_TAG, DR_VOPS): Remove.
20454         * tree-data-ref.c (dr_may_alias_p): Use the alias-oracle.
20455         Ignore vops and SMTs.
20456         (dr_analyze_alias): Likewise..
20457         (free_data_ref): Likewise.
20458         (create_data_ref): Likewise.
20459         (analyze_all_data_dependences): Likewise.
20460         (get_references_in_stmt): Adjust.
20461         * tree-flow-inline.h (gimple_aliases_computed_p,
20462         gimple_addressable_vars, gimple_call_clobbered_vars,
20463         gimple_call_used_vars, gimple_global_var, may_aliases, memory_partition,
20464         factoring_name_p, mark_call_clobbered, clear_call_clobbered,
20465         compare_ssa_operands_equal, symbol_mem_tag, set_symbol_mem_tag,
20466         gimple_mem_ref_stats): Remove.
20467         (gimple_vop): New function.
20468         (op_iter_next_use): Remove vuses and mayuses cases.
20469         (op_iter_next_def): Remove vdefs case.
20470         (op_iter_next_tree): Remove vuses, mayuses and vdefs cases.
20471         (clear_and_done_ssa_iter): Do not set removed fields.
20472         (op_iter_init): Likewise.  Skip vuse and/or vdef if requested.
20473         Assert we are not iterating over vuses or vdefs if not also
20474         iterating over uses or defs.
20475         (op_iter_init_use): Likewise.
20476         (op_iter_init_def): Likewise.
20477         (op_iter_next_vdef): Remove.
20478         (op_iter_next_mustdef): Likewise.
20479         (op_iter_init_vdef): Likewise.
20480         (compare_ssa_operands_equal): Likewise.
20481         (link_use_stmts_after): Handle vuse operand.
20482         (is_call_used): Use is_call_clobbered.
20483         (is_call_clobbered): Global variables are always call clobbered,
20484         query the call-clobbers bitmap.
20485         (mark_call_clobbered): Ignore global variables.
20486         (clear_call_clobbered): Likewise.
20487         * tree-ssa-coalesce.c (create_outofssa_var_map): Adjust
20488         virtual operands sanity check.
20489         * tree.def (NAME_MEMORY_TAG, SYMBOL_MEMORY_TAG, MEMORY_PARTITION_TAG):
20490         Remove.
20491         (TARGET_MEM_REF): Remove TMR_TAG operand.
20492         * tree-dfa.c (add_referenced_var): Initialize call-clobber state.
20493         Remove call-clobber related code.
20494         (remove_referenced_var): Likewise.  Do not clear mpt or symbol_mem_tag.
20495         (dump_variable): Do not dump SMTs, memory stats, may-aliases or
20496         partitions or escape reason.
20497         (get_single_def_stmt, get_single_def_stmt_from_phi,
20498         get_single_def_stmt_with_phi): Remove.
20499         (dump_referenced_vars): Tidy.
20500         (get_ref_base_and_extent): Allow bare decls.
20501         (collect_dfa_stats): Adjust.
20502         * graphite.c (rename_variables_in_stmt): Adjust.
20503         (graphite_copy_stmts_from_block): Likewise.
20504         (translate_clast): Likewise.
20505         * tree-ssa-pre.c (struct bb_bitmap_sets): Add expr_dies bitmap.
20506         (EXPR_DIES): New.
20507         (translate_vuse_through_block): Use the oracle.
20508         (phi_translate_1): Adjust.
20509         (value_dies_in_block_x): Use the oracle.  Cache the outcome
20510         in EXPR_DIES.
20511         (valid_in_sets): Check if the VUSE for
20512         a REFERENCE is available.
20513         (eliminate): Do not remove stmts during elimination,
20514         instead queue and remove them afterwards.
20515         (do_pre): Do not rebuild alias info.
20516         (pass_pre): Run TODO_rebuild_alias before PRE.
20517         * tree-ssa-live.c (remove_unused_locals): Remove memory-tag code.
20518         * tree-sra.c (sra_walk_function): Use gimple_references_memory_p.
20519         (mark_all_v_defs_stmt): Remove.
20520         (mark_all_v_defs_seq): Adjust.
20521         (sra_replace): Likewise.
20522         (scalarize_use): Likewise.
20523         (scalarize_copy): Likewise.
20524         (scalarize_init): Likewise.
20525         (scalarize_ldst): Likewise.
20526         (todoflags): Remove.
20527         (tree_sra): Do not rebuild alias info.
20528         (tree_sra_early): Adjust.
20529         (pass_sra): Run TODO_update_address_taken before SRA.
20530         * tree-predcom.c (set_alias_info): Remove.
20531         (prepare_initializers_chain): Do not call it.
20532         (mark_virtual_ops_for_renaming): Adjust.
20533         (mark_virtual_ops_for_renaming_list): Remove.
20534         (initialize_root_vars): Adjust.
20535         (initialize_root_vars_lm): Likewise.
20536         (prepare_initializers_chain): Likewise.
20537         * tree-ssa-copy.c (may_propagate_copy): Remove memory-tag related code.
20538         (may_propagate_copy_into_stmt): Likewise.
20539         (merge_alias_info): Do nothing for now.
20540         (propagate_tree_value_into_stmt): Adjust.
20541         (stmt_may_generate_copy): Likewise.
20542         * tree-ssa-forwprop.c (tidy_after_forward_propagate_addr): Do
20543         not mark symbols for renaming.
20544         (forward_propagate_addr_expr): Match up push/pop_stmt_changes
20545         with the same statement, make sure to update the new pointed-to one.
20546         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Do not copy
20547         call statements, do not mark symbols for renaming.
20548         (mark_operand_necessary): Dump something.
20549         (ref_may_be_aliased): New function.
20550         (mark_aliased_reaching_defs_necessary_1): New helper function.
20551         (mark_aliased_reaching_defs_necessary): Likewise.
20552         (mark_all_reaching_defs_necessary_1): Likewise.
20553         (mark_all_reaching_defs_necessary): Likewise.
20554         (propagate_necessity): Do not process virtual PHIs.  For
20555         non-aliased loads mark all reaching definitions as necessary.
20556         For aliased loads and stores mark the immediate dominating
20557         aliased clobbers as necessary.
20558         (visited): New global static.
20559         (perform_tree_ssa_dce): Free visited bitmap after propagating
20560         necessity.
20561         (remove_dead_phis): Perform simple dead virtual PHI removal.
20562         (remove_dead_stmt): Properly unlink virtual operands when
20563         removing stores.
20564         (eliminate_unnecessary_stmts): Schedule PHI removal after
20565         stmt removal.
20566         * tree-ssa-ter.c (is_replaceable_p): Adjust.
20567         (process_replaceable): Likewise.
20568         (find_replaceable_in_bb): Likewise.
20569         * tree-ssa.c (verify_ssa_name): Verify all VOPs are
20570         based on the single gimple vop.
20571         (verify_flow_insensitive_alias_info): Remove.
20572         (verify_flow_sensitive_alias_info): Likewise.
20573         (verify_call_clobbering): Likewise.
20574         (verify_memory_partitions): Likewise.
20575         (verify_alias_info): Likewise.
20576         (verify_ssa): Adjust..
20577         (execute_update_addresses_taken): Export.  Update SSA
20578         manually.  Optimize only when optimizing.  Use a local bitmap.
20579         (pass_update_address_taken): Remove TODO_update_ssa, add
20580         TODO_dump_func.
20581         (pass_update_address_taken): Just use TODO_update_address_taken.
20582         (init_tree_ssa): Do not initialize addressable_vars.
20583         (verify_ssa): Verify new VUSE / VDEF properties.
20584         Verify that all stmts definitions have the stmt as SSA_NAME_DEF_STMT.
20585         Do not call verify_alias_info.
20586         (delete_tree_ssa): Clear the VUSE, VDEF operands.
20587         Do not free the loaded and stored syms bitmaps.  Reset the escaped
20588         and callused solutions.  Do not free addressable_vars.
20589         Remove memory-tag related code.
20590         (warn_uninitialized_var): Aliases are always available.
20591         * tree-ssa-loop-prefetch.c (gather_memory_references): Adjust.
20592         * lambda-code.c (can_put_in_inner_loop): Adjust.
20593         (can_put_after_inner_loop): Likewise.
20594         (perfect_nestify): Likewise.
20595         * tree-vect-stmts.c (vect_stmt_relevant_p): Adjust.
20596         (vect_gen_widened_results_half): Remove CALL_EXPR handling.
20597         (vectorizable_conversion): Do not mark symbols for renaming.
20598         * tree-inline.c (remap_gimple_stmt): Clear VUSE/VDEF.
20599         (expand_call_inline): Unlink the calls virtual operands before
20600         replacing it.
20601         (tree_function_versioning): Do not call update_ssa if we are not
20602         updating clones.  Simplify.
20603         * tree-ssa-phiprop.c (phivn_valid_p): Adjust.
20604         (propagate_with_phi): Likewise..
20605         * tree-outof-ssa.c (create_temp): Remove memory tag and call
20606         clobber code.  Assert we are not aliased or global.
20607         * tree-flow.h: Include tree-ssa-alias.h
20608         (enum escape_type): Remove.
20609         (struct mem_sym_stats_d): Likewise.
20610         (struct mem_ref_stats_d): Likewise.
20611         (struct gimple_df): Add vop member.  Remove global_var,
20612         call_clobbered_vars, call_used_vars, addressable_vars,
20613         aliases_compted_p and mem_ref_stats members.  Add syms_to_rename,
20614         escaped and callused members.
20615         (struct ptr_info_def): Remove all members, add points-to solution
20616         member pt.
20617         (struct var_ann_d): Remove in_vuse_list, in_vdef_list,
20618         call_clobbered, escape_mask, mpt and symbol_mem_tag members.
20619         * Makefile.in (TREE_FLOW_H): Add tree-ssa-alias.h.
20620         (tree-ssa-structalias.o): Remove tree-ssa-structalias.h.
20621         (tree-ssa-alias.o): Likewise.
20622         (toplev.o): Add tree-ssa-alias.h
20623         (GTFILES): Remove tree-ssa-structalias.h, add tree-ssa-alias.h.
20624         * gimple.c (gimple_set_bb): Fix off-by-one error.
20625         (is_gimple_reg): Do not handle memory tags.
20626         (gimple_copy): Also copy virtual operands.
20627         Delay updating the statement.  Do not reset loaded and stored syms.
20628         (gimple_set_stored_syms): Remove.
20629         (gimple_set_loaded_syms): Likewise.
20630         (gimple_call_copy_skip_args): Copy the virtual operands
20631         and mark the new statement modified.
20632         * tree-ssa-structalias.c (may_alias_p): Remove.
20633         (set_uids_in_ptset): Take the alias set to prune with as
20634         parameter.  Fold in the alias test of may_alias_p.
20635         (compute_points_to_sets): Compute whether a ptr is dereferenced
20636         in a local sbitmap.
20637         (process_constraint): Deal with &ANYTHING on the lhs, reject all
20638         other ADDRESSOF constraints on the lhs.
20639         (get_constraint_for_component_ref): Assert that we don't get
20640         ADDRESSOF constraints from the base of the reference.
20641         Properly generate UNKNOWN_OFFSET for DEREF if needed.
20642         (struct variable_info): Remove collapsed_to member.
20643         (get_varinfo_fc): Remove.
20644         (new_var_info): Do not set collapsed_to.
20645         (dump_constraint): Do not follow cycles.
20646         (dump_constraint_graph): Likewise.
20647         (build_pred_graph): Likewise.
20648         (build_succ_graph): Likewise.
20649         (rewrite_constraints): Likewise.
20650         (do_simple_structure_copy): Remove.
20651         (do_rhs_deref_structure_copy): Remove.
20652         (do_lhs_deref_structure_copy): Remove.
20653         (collapse_rest_of_var): Remove.
20654         (do_structure_copy): Re-implement.
20655         (pta_stats): New global variable.
20656         (dump_pta_stats): New function.
20657         (struct constraint_expr): Make offset signed.
20658         (UNKNOWN_OFFSET): Define special value.
20659         (dump_constraint): Dump UNKNOWN_OFFSET as UNKNOWN.
20660         (solution_set_expand): New helper function split out from ...
20661         (do_sd_constraint): ... here.
20662         (solution_set_add): Handle UNKNOWN_OFFSET.  Handle negative offsets.
20663         (do_ds_constraint): Likewise.
20664         (do_sd_constraint): Likewise.  Do not special-case ESCAPED = *ESCAPED
20665         and CALLUSED = *CALLUSED.
20666         (set_union_with_increment): Make inc argument signed.
20667         (type_safe): Remove.
20668         (get_constraint_for_ptr_offset): Handle unknown and negative
20669         constant offsets.
20670         (first_vi_for_offset): Handle offsets before start.  Bail
20671         out early for offsets beyond the variable extent.
20672         (first_or_preceding_vi_for_offset): New function.
20673         (init_base_vars): Add ESCAPED = ESCAPED + UNKNOWN_OFFSET constraint.
20674         Together with ESCAPED = *ESCAPED this properly computes reachability.
20675         (find_what_var_points_to): New function.
20676         (find_what_p_points_to): Implement in terms of find_what_var_points_to.
20677         (pt_solution_reset, pt_solution_empty_p, pt_solution_includes_global,
20678         pt_solution_includes_1, pt_solution_includes, pt_solutions_intersect_1,
20679         pt_solutions_intersect): New functions.
20680         (compute_call_used_vars): Remove.
20681         (compute_may_aliases): New main entry into PTA computation.
20682         * gimple.h (gimple_p): New typedef.
20683         (struct gimple_statement_base): Remove references_memory_p.
20684         (struct gimple_statement_with_memory_ops_base): Remove
20685         vdef_ops, vuse_ops, stores and loads members.  Add vdef and vuse
20686         members.
20687         (gimple_vuse_ops, gimple_set_vuse_ops, gimple_vdef_ops,
20688         gimple_set_vdef_ops, gimple_loaded_syms, gimple_stored_syms,
20689         gimple_set_references_memory): Remove.
20690         (gimple_vuse_op, gimple_vdef_op, gimple_vuse, gimple_vdef,
20691         gimple_vuse_ptr, gimple_vdef_ptri, gimple_set_vuse, gimple_set_vdef):
20692         New functions.
20693         * tree-cfg.c (move_block_to_fn): Fix off-by-one error.
20694         (verify_expr): Allow RESULT_DECL.
20695         (gimple_duplicate_bb): Do not copy virtual operands.
20696         (gimple_duplicate_sese_region): Adjust.
20697         (gimple_duplicate_sese_tail): Likewise.
20698         (mark_virtual_ops_in_region): Remove.
20699         (move_sese_region_to_fn): Do not call it.
20700         * passes.c (init_optimization_passes): Remove pass_reset_cc_flags
20701         and pass_simple_dse.
20702         (execute_function_todo): Handle TODO_update_address_taken,
20703         call execute_update_addresses_taken for TODO_rebuild_alias.
20704         (execute_todo): Adjust.
20705         (execute_one_pass): Init dump files early.
20706         * ipa-struct-reorg.c (finalize_var_creation): Do not mark vars
20707         call-clobbered.
20708         (create_general_new_stmt): Clear vops.
20709         * tree-ssa-reassoc.c (get_rank): Adjust.
20710         * tree-vect-slp.c (vect_create_mask_and_perm): Do not mark
20711         symbols for renaming.
20712         * params.def (PARAM_MAX_ALIASED_VOPS): Remove.
20713         (PARAM_AVG_ALIASED_VOPS): Likewise.
20714         * tree-ssanames.c (init_ssanames): Allocate SYMS_TO_RENAME.
20715         (duplicate_ssa_name_ptr_info): No need to copy the shared bitmaps.
20716         * tree-ssa-operands.c: Simplify for new virtual operand representation.
20717         (operand_build_cmp, copy_virtual_operands,
20718         create_ssa_artificial_load_stmt, add_to_addressable_set,
20719         gimple_add_to_addresses_taken): Remove public functions.
20720         (unlink_stmt_vdef): New function.
20721
20722 2009-04-03  Alan Modra  <amodra@bigpond.net.au>
20723
20724         * config.gcc (powerpc-*-linux*): Merge variants.
20725
20726 2009-04-02  Chao-ying Fu  <fu@mips.com>
20727             James Grosbach  <james.grosbach@microchip.com>
20728
20729         * config/mips/mips.c (mips_frame_info): Add acc_mask, num_acc,
20730         num_cop0_regs, acc_save_offset, cop0_save_offset, acc_sp_offset,
20731         cop0_sp_offset.
20732         (machine_function): Add interrupt_handler_p, use_shadow_register_set_p,
20733         keep_interrupts_masked_p, use_debug_exception_return_p.
20734         (mips_attribute_table): Add interrupt, use_shadow_register_set,
20735         keep_interrupts_masked, use_debug_exception_return.
20736         (mips_interrupt_type_p, mips_use_shadow_register_set_p,
20737         mips_keep_interrupts_masked_p, mips_use_debug_exception_return_p):
20738         New functions.
20739         (mips_function_ok_for_sibcall): Return false for interrupt handlers.
20740         (mips_print_operand): Process COP0 registers to print $0 .. $31
20741         correctly for GAS to process.
20742         (mips_interrupt_extra_call_saved_reg_p): New function.
20743         (mips_cfun_call_saved_reg_p): For interrupt handlers, we need to check
20744         extra registers.
20745         (mips_cfun_might_clobber_call_saved_reg_p): Likewise.
20746         (mips_compute_frame_info): Add supports for interrupt context that
20747         includes doubleword accumulators and COP0 registers.
20748         (mips_for_each_saved_acc): New function.
20749         (mips_for_each_saved_gpr_and_fpr): Change the function name from
20750         mips_for_each_saved_reg.
20751         (mips_save_reg): Save accumulators.
20752         (mips_kernel_reg_p): A new for_each_rtx callback.
20753         (mips_expand_prologue): Support interrupt handlers.
20754         (mips_restore_reg): Restore accumulators.
20755         (mips_expand_epilogue): Support interrupt handlers.
20756         (mips_can_use_return_insn): Return false for interrupt handlers.
20757         (mips_epilogue_uses): New function.
20758         * config/mips/mips.md (UNSPEC_ERET, UNSPEC_DERET, UNSPEC_DI,
20759         UNSPEC_EHB, UNSPEC_RDPGPR, UNSPEC_COP0): New UNSPEC.
20760         (mips_eret, mips_deret, mips_di, mips_ehb, mips_rdpgpr,
20761         cop0_move): New instructions.
20762         * config/mips/mips-protos.h (mips_epilogue_uses): Declare.
20763         * config/mips/mips.h (K0_REG_NUM, K1_REG_NUM, KERNEL_REG_P): New
20764         defines.
20765         (COP0_STATUS_REG_NUM, COP0_CAUSE_REG_NUM, COP0_EPC_REG_NUM):
20766         New defines.
20767         (CAUSE_IPL, SR_IPL, SR_EXL, SR_IE): New defines.
20768         (MIPS_PROLOGUE_TEMP_REGNUM, MIPS_EPILOGUE_TEMP_REGNUM): For
20769         interrupt handlers, we use K0 as the temporary register.
20770         (EPILOGUE_USES): Change to a function call.
20771         * config/mips/sde.h (MIPS_EPILOGUE_TEMP_REGNUM): For interrupt
20772         handlers, we use K0 as the temporary register.
20773
20774         * doc/extend.texi (Function Attributes): Document interrupt,
20775         use_shadow_register_set, keep_interrupts_masked,
20776         use_debug_exception_return for MIPS attributes.
20777
20778 2009-04-03  Alan Modra  <amodra@bigpond.net.au>
20779
20780         * config.gcc (powerpc64-*-gnu*): Add rs6000/default64.h to tm_file.
20781         Remove a number of t-files from tmake_file.
20782         * config/rs6000/sysv4.opt (mprototype): Name variable target_prototype.
20783         * config/rs6000/sysv4.h (TARGET_PROTOTYPE): Define.
20784         * config/rs6000/linux64.h (SUBSUBTARGET_OVERRIDE_OPTIONS): Set
20785         target_prototype, not TARGET_PROTOTYPE.
20786         (LINK_OS_GNU_SPEC): Define.
20787         * config/rs6000/t-linux64 (LIB2FUNCS_EXTRA): Delete tramp.S
20788         and darwin-ldoubdle.c.
20789
20790 2009-04-02  Michael Meissner  <meissner@linux.vnet.ibm.com>
20791
20792         PR driver/39293
20793         * gcc.c (save_temps_flag): Add support for -save-temps=obj.
20794         (cpp_options): Ditto.
20795         (default_compilers): Ditto.
20796         (display_help): Ditto.
20797         (process_command): Ditto.
20798         (do_spec_1): Ditto.
20799         (set_input): Use lbasename instead of duplicate code.
20800         (save_temps_prefix): New static for -save-temps=obj.
20801         (save_temps_length): Ditto.
20802
20803         * doc/invoke.texi (-save-temps=obj): Document new variant to
20804         -save-temps switch.
20805
20806 2009-04-02  Jeff Law  <law@redhat.com>
20807
20808         * reload1.c (fixup_eh_region_notes): Remove write-only "trap_count"
20809         variable.
20810
20811 2009-04-02  H.J. Lu  <hongjiu.lu@intel.com>
20812
20813         * configure.ac: Support -Bstatic/-Bdynamic for linker version > 2.
20814         * configure: Regenerated.
20815
20816 2009-04-02  Rafael Avila de Espindola  <espindola@google.com>
20817
20818         * c-decl.c (merge_decls): Make sure newdecl and olddecl don't
20819         share the argument list.
20820
20821 2009-04-02  Rafael Avila de Espindola  <espindola@google.com>
20822
20823         Merge
20824
20825         2009-02-12  Diego Novillo  <dnovillo@google.com>
20826
20827         * varpool.c (debug_varpool): New.
20828         * cgraph.h (debug_varpool): Declare.
20829
20830 2009-04-02  Jan Hubicka  <jh@suse.cz>
20831
20832         * passes.c (init_optimization_passes): Remove two copies of ehcleanup
20833         pass.
20834
20835 2009-04-02  H.J. Lu  <hongjiu.lu@intel.com>
20836
20837         * config/i386/i386.c (ix86_abi): Move initialization to ...
20838         (override_options): Here.
20839
20840 2009-04-02  Christian Bruel  <christian.bruel@st.com>
20841
20842         * config/sh/sh.c (sh_dwarf_register_span): New function.
20843         (TARGET_DWARF_REGISTER_SPAN): Define.
20844         * config/sh/sh-protos.h (sh_dwarf_register_span): Declare.
20845
20846 2009-04-02  Ira Rosen  <irar@il.ibm.com>
20847
20848         PR tree-optimization/39595
20849         * tree-vect-slp.c (vect_build_slp_tree): Check that the size of
20850         interleaved loads group is not  greater than the SLP group size.
20851
20852 2009-04-02  Rafael Avila de Espindola  <espindola@google.com>
20853
20854         * builtins.c (is_builtin_name): New.
20855         (called_as_built_in): Use is_builtin_name.
20856         * tree.h (is_builtin_name): New.
20857         * varasm.c (incorporeal_function_p): Use is_builtin_name
20858
20859 2009-04-02  Andrew Stubbs  <ams@codesourcery.com>
20860
20861         * config/sh/linux-unwind.h: Disable when inhibit_libc is defined.
20862
20863 2009-04-02  Dodji Seketeli  <dodji@redhat.com>
20864
20865         PR c++/26693
20866         * c-decl.c (clone_underlying_type): Move this ...
20867         * c-common.c (set_underlying_type): ... here.
20868         Also, make sure the function properly sets TYPE_STUB_DECL() on
20869         the newly created typedef variant type.
20870         * c-common.h (is_typedef_decl, set_underlying_type): Declare ...
20871         * c-common.c (is_typedef_decl, set_underlying_type): ... new entry
20872         points.
20873
20874 2009-04-02  Richard Guenther  <rguenther@suse.de>
20875
20876         PR tree-optimization/37221
20877         * tree-flow.h (degenerate_phi_result): Declare.
20878         * tree-ssa-dom.c (degenerate_phi_result): Export.
20879         * tree-scalar-evolution.c (analyze_initial_condition): If
20880         the initial condition is defined by a degenerate PHI node
20881         use the degenerate value.
20882
20883 2009-04-01  Eric Botcazou  <ebotcazou@adacore.com>
20884
20885         PR rtl-optimization/39588
20886         * combine.c (merge_outer_ops): Do not set the constant when this
20887         is not necessary.
20888         (simplify_shift_const_1): Do not modify it either in this case.
20889
20890 2009-04-01  Steven Bosscher  <steven@gcc.gnu.org>
20891
20892         * config/ia64/ia64.c (ia64_handle_option): Inform user that Itanium1
20893         tuning is deprecated if -mtune value is set to an Itanium1 variant.
20894
20895 2009-04-01  Janis Johnson  <janis187@us.ibm.com>
20896
20897         PR c/29027
20898         * c-lex.c (interpret_float): Default (no suffix) is double.
20899
20900 2009-04-1  Xinliang David Li  <davidxl@google.com>
20901
20902         * config/i386/i386.c (legitimate_constant_p): Recognize
20903         all one vector constant.
20904
20905 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
20906
20907         * config/vax/vax.c: Add #includes to silence warnings.
20908         Change #include order to silence two warnings.
20909
20910 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
20911
20912         * config/vax/linux.h (TARGET_DEFAULT): Add the MASK_QMATH flag bit.
20913         (ASM_SPEC): Pass -k to the assembler for PIC code.
20914
20915 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
20916
20917         * config.gcc: Add vax-*-linux* to the switch.
20918         * config/vax/linux.h: New file. (TARGET_VERSION,
20919         TARGET_OS_CPP_BUILTINS, TARGET_DEFAULT, CPP_SPEC, LINK_SPEC): Define.
20920
20921 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
20922
20923         * config/vax/vax.c (vax_output_int_move, adjacent_operands_p):
20924         Use predicate macros instead of GET_CODE() == foo.
20925         * config/vax/vax.md (movsi_2, movstrictqi, and<mode>3, ashrsi3,
20926         ashlsi3, rotrsi3, <unnamed>): Likewise.
20927
20928 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
20929
20930         * config/vax/builtins.md (jbbssiqi, jbbssihi, jbbssisi, jbbcciqi,
20931         jbbccihi, jbbccisi): Remova trailing whitespace.
20932         * config/vax/constraints.md: Likewise.
20933         * config/vax/elf.h: (ASM_PREFERRED_EH_DATA_FORMAT): Likewise.
20934         * config/vax/openbsd1.h (OBSD_OLD_GAS): Likewise.
20935         * config/vax/predicates.md: Likewise.
20936         * config/vax/vax.c (print_operand_address, vax_output_int_move,
20937         vax_expand_addsub_di_operands, adjacent_operands_p): Likewise.
20938         * config/vax/vax.h: Likewise.
20939         * config/vax/vax.md (nonlocal_goto): Likewise.
20940
20941 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
20942
20943         * config/vax/vax.c (vax_float_literal, vax_output_int_move)
20944         (indirectable_address_p, adjacent_operands_p): Add spaces around
20945         braces.
20946         * config/vax/vax-protos.h (adjacent_operands_p): Likewise.
20947
20948 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
20949
20950         * config/vax/vax.c (legitimate_constant_address_p,
20951         legitimate_constant_p, indirectable_address_p, nonindexed_address_p,
20952         index_term_p, reg_plus_index_p, legitimate_address_p,
20953         vax_mode_dependent_address_p): Update comments to match functions
20954         modified by the recent int->bool conversion.
20955
20956 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
20957
20958         * config/vax/builtins.md: Update copyright message.
20959         * config/vax/constraints.md: Likewise.
20960         * config/vax/netbsd-elf.h: Likewise.
20961         * config/vax/predicates.md: Likewise.
20962         * config/vax/vax-protos.h: Likewise.
20963         * config/vax/vax.c: Likewise.
20964         * config/vax/vax.h: Likewise.
20965         * config/vax/vax.md: Likewise.
20966         * config/vax/vax.opt: Likewise.
20967
20968 2009-04-01  Jan-Benedict Glaw  <jbglaw@jbglaw-dev.homezone.telefonica.de>
20969
20970         * config/vax/builtins.md (ffssi2, ffssi2_internal,
20971         sync_lock_test_and_set<mode>, sync_lock_release<mode>): Fix indention.
20972         * config/vax/constraints.md (B, R): Likewise.
20973         * config/vax/predicates.md (external_memory_operand,
20974         nonimmediate_addsub_di_operand): Likewise.
20975         * config/vax/vax.c (vax_output_int_add): Likewise.
20976         * config/vax/vax.md (movsi, movsi_2, mov<mode>, call_value,
20977         untyped_call): Likewise.
20978
20979 2009-04-01  Matt Thomas  <matt@3am-software.com>
20980
20981         * config/vax/predicates.md: New file.
20982         (symbolic_operand, local_symbolic_operand, external_symbolic_operand,
20983         external_const_operand, nonsymbolic_operand, external_memory_operand,
20984         indirect_memory_operand, indexed_memory_operand,
20985         illegal_blk_memory_operand, illegal_addsub_di_memory_operand,
20986         nonimmediate_addsub_di_operand, general_addsub_di_operand): New
20987         predicate.
20988         * config/vax/constraints.md: New file.
20989         (Z0, U06,  U08, U16, CN6, S08, S16, I, J, K, L, M, N, O, G, Q, B, R, T):
20990         New constraint.
20991         * config/vax/builtins.md: New file.
20992         (ffssi2, ffssi2_internal, sync_lock_test_and_set<mode>, jbbssiqi,
20993         jbbssihi, jbbssisi, sync_lock_release<mode>, jbbcciqi, jbbccihi,
20994         jbbccisi): Define.
20995         * config/vax/vax.opt (mqmath): Add option.
20996         * config/vax/vax.md (isfx): Extend with DI.
20997         (VAXintQH, VAXintQHSD): Define.
20998         (tst<mode>, cmp<mode>, *bit<mode>, movmemhi1, truncsiqi2, truncsihi2,
20999         mulsidi3, add<mode>3, sub<mode>, mul<mode>3, div<mode>3, and<mode>,
21000         and<mode>_const_int, ior<mode>3, xor<mode>3, neg<mode>2,
21001         one_cmpl<mode>2, ashlsi3, lshrsi3, rotlsi3): Update constraints.
21002         (movdi): Update constraints and use vax_output_int_move().
21003         (movsi, movsi_2, pushlclsymreg, pushextsymreg, movlclsymreg,
21004         movextsymreg, adddi3, adcdi3, subdi3, sbcdi3, pushextsym, movextsym,
21005         pushlclsym, movlclsym, movaddr<mode>, pushaddr<mode>,
21006         nonlocal_goto): New.
21007         (mov<mode>): Extend accepted operand types.
21008         (subdi3_old): Rename from subdi3, change update constraints and use
21009         a new implementation.
21010         * config/vax/vax.h (PCC_BITFIELD_TYPE_MATTERS): Add space.
21011         (FRAME_POINTER_CFA_OFFSET, IRA_COVER_CLASSES, CLASS_MAX_NREGS,
21012         MOVE_RATIO, CLEAR_RATIO): Define.
21013         (REG_CLASS_FROM_LETTER, CONST_OK_FOR_LETTER_P,
21014         CONST_DOUBLE_OK_FOR_LETTER_P, EXTRA_CONSTRAINT): Delete.
21015         (PRINT_OPERAND): Redefine using a function instead of inlined code.
21016         * config/vax/vax.c (TARGET_BUILTIN_SETJMP_FRAME_VALUE): Define.
21017         (split_quadword_operands): Make static and really allow variable
21018         splitting.
21019         (print_operand_address): Update for PIC generation.
21020         (print_operand, vax_builtin_setjmp_frame_value, vax_output_int_subtract,
21021         indexable_address_p, fixup_mathdi_operand,
21022         vax_expand_addsub_di_operands, adjacent_operands_p): New.
21023         (vax_float_literal, legitimate_constant_p,
21024         indirectable_constant_address_p, index_term_p,
21025         reg_plus_index_p): Return bool instead of int.
21026         (vax_rtx_costs): Fix cost for CONST_INT, indent and use HOST_WIDE_INT
21027         where needed.
21028         (vax_output_int_move, vax_output_int_add): Extend to allow PIC
21029         generation.
21030         (vax_output_conditional_branch): Indent.
21031         (legitimate_constant_address_p, indirectable_constant_address_p,
21032         indirectable_address_p, nonindexed_address_p, legitimate_address_p,
21033         vax_mode_dependent_address_p): Return bool instead of int, update for
21034         PIC generation.
21035         * config/vax/vax-protos.h (legitimate_constant_address_p,
21036         legitimate_constant_p, legitimate_address_p,
21037         vax_mode_dependent_address_p): Change declaration to bool.
21038         (legitimate_pic_operand_p, adjacent_operands_p, print_operand,
21039         vax_expand_addsub_di_operands, vax_output_int_subtract,
21040         vax_output_movmemsi): Declare.
21041         (split_quadword_operands, vax_float_literal): Delete declaration.
21042         * config/vax/netbsd-elf.h (CC1_SPEC, CC1PLUS_SPEC) Define.
21043         * config/vax/elf.h (NO_EXTERNAL_INDIRECT_ADDRESS,
21044         VAX_CC1_AND_CC1PLUS_SPEC, ASM_PREFERRED_EH_DATA_FORMAT,
21045         ASM_OUTPUT_DWARF_PCREL): Define.
21046         (ASM_SPEC): Change definition to allow PIC generation.
21047
21048 2009-04-01  Steve Ellcey  <sje@cup.hp.com>
21049
21050         * doc/sourcebuild.texi: Update front-end requirements.
21051
21052 2009-04-01  Jakub Jelinek  <jakub@redhat.com>
21053
21054         PR target/39226
21055         * config/rs6000/rs6000.md (andsi3_internal5_nomc,
21056         anddi3_internal2_nomc, anddi3_internal3_nomc): Removed.
21057         (booldi3_internal3): Use boolean_or_operator instead of
21058         boolean_operator.
21059
21060 2009-04-01  Joseph Myers  <joseph@codesourcery.com>
21061
21062         PR c/39605
21063         * c-decl.c (grokdeclarator): Pedwarn for file-scope array
21064         declarator whose size is not an integer constant expression but
21065         folds to an integer constant, then treat it as a constant
21066         subsequently.
21067
21068 2009-04-01  Richard Guenther  <rguenther@suse.de>
21069
21070         * fold-const.c (fold_plusminus_mult_expr): Do not fold
21071         i * 4 + 2 to (i * 2 + 1) * 2.
21072
21073 2009-04-01  Jakub Jelinek  <jakub@redhat.com>
21074
21075         PR c/37772
21076         * c-parser.c (c_parser_asm_statement): Skip until close paren and
21077         return if c_parser_asm_string_literal returned NULL.
21078
21079 2009-04-01  Nick Clifton  <nickc@redhat.com>
21080
21081         * config/m32c/m32c.h (LIBGCC2_UNITS_PER_WORD): Define if not
21082         already defined.
21083         * config/m32c/t-m32c (LIB2FUNCS_EXTRA): Add m32c-lib2-trapv.c.
21084         * config/m32c/m32c-lib2.c: Remove unused typedefs.  Rename the
21085         other typedefs to avoid conflicts with libgcc2.c.  Define labels
21086         to gain 16-bit bit-manipulation functions from libgcc2.c and then
21087         include it.
21088         * config/m32c/m32c-lib2-trapv.c: New file.  Define labels
21089         to gain 16-bit trapping arithmetic functions from libgcc2.c and
21090         then include it.
21091
21092 2009-04-01  Rafael Avila de Espindola  <espindola@google.com>
21093
21094         * varasm.c (default_function_rodata_section): Declare DOT as
21095         const char*.
21096
21097 2009-04-01  Kai Tietz  <kai.tietz@onevision.com>
21098             Andrey Galkin  <agalkin@hypercom.com>
21099
21100         PR/39492
21101         * config/i386/host-mingw32.c (mingw32_gt_pch_use_address):
21102         Make object_name unique for each process.
21103
21104 2009-04-01  Jakub Jelinek  <jakub@redhat.com>
21105
21106         PR other/39591
21107         * omp-low.c (remove_exit_barrier): Don't optimize if there are any
21108         addressable variables in the parallel that could go out of scope while
21109         running queued tasks.
21110
21111 2009-04-01  Anatoly Sokolov  <aesok@post.ru>
21112
21113         * config/avr/avr.h (avr_case_values_threshold): Remove declaration.
21114         (CASE_VALUES_THRESHOLD): Redefine.
21115         * config/avr/avr.c (avr_override_options): Remove initialization of
21116         avr_case_values_threshold variable.
21117         (avr_case_values_threshold): Remove variable. Add new function.
21118         * config/avr/avr-protos.h (avr_case_values_threshold): Declare.
21119         * config/avr/avr.opt (mno-tablejump): Remove option.
21120         * doc/invoke.texi (AVR Options): Remove -mno-tablejump.
21121
21122 2009-04-01  DJ Delorie  <dj@redhat.com>
21123
21124         * varasm.c (default_function_rodata_section): Don't assume
21125         anything about where the first '.' in the section name is.
21126
21127 2009-04-01  Alan Modra  <amodra@bigpond.net.au>
21128
21129         * config/rs6000/rs6000.c (rs6000_emit_stack_reset): Delete redundant
21130         rs6000_emit_stack_tie.
21131
21132 2009-03-31  Ian Lance Taylor  <iant@google.com>
21133
21134         * tree-eh.c (tree_remove_unreachable_handlers): Compare
21135         gimple_code with GIMPLE_RESX, not RESX.
21136
21137 2009-03-31  Joseph Myers  <joseph@codesourcery.com>
21138
21139         * c-common.c (c_get_ident): New.
21140         (c_common_nodes_and_builtins): Call it for type names that may be NULL.
21141
21142 2009-04-01  Ben Elliston  <bje@au.ibm.com>
21143
21144         * config/rs6000/sysv4.opt (msdata): Improve option description.
21145
21146 2009-03-31  Steve Ellcey  <sje@cup.hp.com>
21147
21148         * config/ia64/ia64.md (divsf3_internal_lat): Remove.
21149         (divdf3_internal_lat): Remove.
21150         (divxf3_internal_lat): Remove.
21151         (divxf3_internal_thr): Remove.
21152         (divxf): Use divxf3_internal.
21153         * config/ia64/div.md (divsf3_internal_lat): New.
21154         (divdf3_internal_lat): New.
21155         (divxf3_internal): New.
21156
21157 2009-03-31  Joseph Myers  <joseph@codesourcery.com>
21158
21159         PR c/448
21160         * Makefile.in (USE_GCC_STDINT): Define.
21161         (stmp-int-hdrs): Install stdint.h if applicable.
21162         * c-common.c (CHAR16_TYPE): Define in terms of UINT_LEAST16_TYPE
21163         if known.
21164         (CHAR32_TYPE): Define in terms of UINT_LEAST32_TYPE if known.
21165         (SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE, INT32_TYPE, INT64_TYPE,
21166         UINT8_TYPE, UINT16_TYPE, UINT32_TYPE, UINT64_TYPE,
21167         INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE,
21168         INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE,
21169         UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE,
21170         INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE,
21171         UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE,
21172         UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE): Define.
21173         (c_common_nodes_and_builtins): Initialize
21174         underlying_wchar_type_node.  Do not initialize
21175         signed_wchar_type_node or unsigned_wchar_type_node.  Initialize
21176         nodes for new types.
21177         (c_stddef_cpp_builtins): Define macros for new types.
21178         * c-common.h (CTI_SIGNED_WCHAR_TYPE, CTI_UNSIGNED_WCHAR_TYPE):
21179         Remove.
21180         (CTI_UNDERLYING_WCHAR_TYPE, CTI_SIG_ATOMIC_TYPE, CTI_INT8_TYPE,
21181         CTI_INT16_TYPE, CTI_INT32_TYPE, CTI_INT64_TYPE, CTI_UINT8_TYPE,
21182         CTI_UINT16_TYPE, CTI_UINT32_TYPE, CTI_UINT64_TYPE,
21183         CTI_INT_LEAST8_TYPE, CTI_INT_LEAST16_TYPE, CTI_INT_LEAST32_TYPE,
21184         CTI_INT_LEAST64_TYPE, CTI_UINT_LEAST8_TYPE, CTI_UINT_LEAST16_TYPE,
21185         CTI_UINT_LEAST32_TYPE, CTI_UINT_LEAST64_TYPE, CTI_INT_FAST8_TYPE,
21186         CTI_INT_FAST16_TYPE, CTI_INT_FAST32_TYPE, CTI_INT_FAST64_TYPE,
21187         CTI_UINT_FAST8_TYPE, CTI_UINT_FAST16_TYPE, CTI_UINT_FAST32_TYPE,
21188         CTI_UINT_FAST64_TYPE, CTI_INTPTR_TYPE, CTI_UINTPTR_TYPE): Define.
21189         (signed_wchar_type_node, unsigned_wchar_type_node): Remove.
21190         (underlying_wchar_type_node, sig_atomic_type_node, int8_type_node,
21191         int16_type_node, int32_type_node, int64_type_node,
21192         uint8_type_node, uint16_type_node, c_uint32_type_node,
21193         c_uint64_type_node, int_least8_type_node, int_least16_type_node,
21194         int_least32_type_node, int_least64_type_node,
21195         uint_least8_type_node, uint_least16_type_node,
21196         uint_least32_type_node, uint_least64_type_node,
21197         int_fast8_type_node, int_fast16_type_node, int_fast32_type_node,
21198         int_fast64_type_node, uint_fast8_type_node, uint_fast16_type_node,
21199         uint_fast32_type_node, uint_fast64_type_node, intptr_type_node,
21200         uintptr_type_node): Define.
21201         * c-cppbuiltin.c (builtin_define_constants,
21202         builtin_define_type_minmax): New.
21203         (builtin_define_stdint_macros): Define more macros.
21204         (c_cpp_builtins): Define more limit macros.
21205         (type_suffix): New.
21206         (builtin_define_type_max): Define in terms of
21207         builtin_define_type_minmax.  Remove is_long parameter.  All
21208         callers changed.
21209         * config.gcc (use_gcc_stdint): Define.
21210         (tm_file): Add glibc-stdint.h for targets using glibc or uClibc.
21211         Add newlib-stdint.h for generic targets.
21212         * config/glibc-stdint.h, config/newlib-stdint.h,
21213         ginclude/stdint-gcc.h, ginclude/stdint-wrap.h: New.
21214         * config/m32c/m32c.h (UINTPTR_TYPE): Define.
21215         * config/score/score.h (UINTPTR_TYPE): Define.
21216         * config/sol2.h (SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE,
21217         INT32_TYPE, INT64_TYPE, UINT8_TYPE, UINT16_TYPE, UINT32_TYPE,
21218         UINT64_TYPE, INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE,
21219         INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE,
21220         UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE,
21221         INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE,
21222         UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE,
21223         UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE): Define.
21224         * config/spu/spu.h (STDINT_LONG32): Define.
21225         * configure.ac (use_gcc_stdint): Substitute.
21226         * configure: Regenerate.
21227         * doc/cpp.texi (__SIG_ATOMIC_TYPE__, __INT8_TYPE__,
21228         __INT16_TYPE__, __INT32_TYPE__, __INT64_TYPE__, __UINT8_TYPE__,
21229         __UINT16_TYPE__, __UINT32_TYPE__, __UINT64_TYPE__,
21230         __INT_LEAST8_TYPE__, __INT_LEAST16_TYPE__, __INT_LEAST32_TYPE__,
21231         __INT_LEAST64_TYPE__, __UINT_LEAST8_TYPE__, __UINT_LEAST16_TYPE__,
21232         __UINT_LEAST32_TYPE_, __UINT_LEAST64_TYPE__, __INT_FAST8_TYPE__,
21233         __INT_FAST16_TYPE__, __INT_FAST32_TYPE__, __INT_FAST64_TYPE__,
21234         __UINT_FAST8_TYPE__, __UINT_FAST16_TYPE__, __UINT_FAST32_TYPE__,
21235         __UINT_FAST64_TYPE__, __INTPTR_TYPE__, __UINTPTR_TYPE__,
21236         __WINT_MAX__, __SIZE_MAX__, __PTRDIFF_MAX__, __UINTMAX_MAX__,
21237         __SIG_ATOMIC_MAX__, __INT8_MAX__, __INT16_MAX__, __INT32_MAX__,
21238         __INT64_MAX__, __UINT8_MAX__, __UINT16_MAX__, __UINT32_MAX__,
21239         __UINT64_MAX__, __INT_LEAST8_MAX__, __INT_LEAST16_MAX__,
21240         __INT_LEAST32_MAX__, __INT_LEAST64_MAX__, __UINT_LEAST8_MAX__,
21241         __UINT_LEAST16_MAX__, __UINT_LEAST32_MAX__, __UINT_LEAST64_MAX__,
21242         __INT_FAST8_MAX__, __INT_FAST16_MAX__, __INT_FAST32_MAX__,
21243         __INT_FAST64_MAX__, __UINT_FAST8_MAX__, __UINT_FAST16_MAX__,
21244         __UINT_FAST32_MAX__, __UINT_FAST64_MAX__, __INTPTR_MAX__,
21245         __UINTPTR_MAX__, __WCHAR_MIN__, __WINT_MIN__, __SIG_ATOMIC_MIN__,
21246         __INT8_C, __INT16_C, __INT32_C, __INT64_C, __UINT8_C, __UINT16_C,
21247         __UINT32_C, __UINT64_C, __INTMAX_C, __UINTMAX_C): Document.
21248         * doc/tm.texi (SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE, INT32_TYPE,
21249         INT64_TYPE, UINT8_TYPE, UINT16_TYPE, UINT32_TYPE, UINT64_TYPE,
21250         INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE,
21251         INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE,
21252         UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE,
21253         INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE,
21254         UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE,
21255         UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE): Document.
21256
21257 2009-03-31  Bernd Schmidt  <bernd.schmidt@analog.com>
21258
21259         * loop-iv.c (suitable_set_for_replacement): Renamed from
21260         simplify_using_assignment; changed to return bool and to accept new
21261         args DEST and SRC.  Return true iff we find a source/destination pair
21262         that can be used to make a replacement, and fill SRC and DEST if so.
21263         Remove arg ALTERED.  Don't deal with altered regs here.  All callers
21264         changed.
21265         (simplify_using_initial_values): Deal with altered regs here and track
21266         more precisely the effect they have on the validity of our expression.
21267
21268         * loop-iv.c (simplify_using_condition): A condition of the form
21269         (EQ REG CONST) can be used to simply make a substitution.
21270         (simplify_using_initial_values): Keep track of conditions we have seen
21271         and keep using them to simplify new expressions, while applying the
21272         same substitutions to them as to the expression.
21273
21274         * simplify-rtx.c (simplify_relational_operation_1): Simplify
21275         (LTU (PLUS a C) C) or (LTU (PLUS a C) a) to (GEU a -C); likewise with
21276         GEU/LTU reversed.
21277
21278         * loop-iv.c (determine_max_iter): New arg OLD_NITER.  All callers
21279         changed.  Use this when trying to improve the upper bound.
21280         Generate the comparison by using simplify_gen_relational.
21281
21282         * loop-iv.c (simple_rhs_p): Allow more kinds of expressions.
21283
21284         * loop-iv.c (replace_single_def_regs, replace_in_expr): New static
21285         functions.
21286         (simplify_using_assignment, simplify_using_initial_values): Call
21287         replace_in_expr to make replacements.  Call replace_single_def_regs
21288         once on the initial version of the expression.
21289
21290 2009-03-31  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
21291
21292         PR target/27237
21293         * doc/invoke.texi (ARM Options): Update documentation for -mthumb.
21294
21295 2009-03-31  Richard Guenther  <rguenther@suse.de>
21296
21297         PR middle-end/31029
21298         * fold-const.c (fold_binary): Fold X +- Y CMP X to Y CMP 0 for
21299         equality comparisons.  Fold C - X CMP X if C % 2 == 1.
21300
21301 2009-03-31  Richard Guenther  <rguenther@suse.de>
21302
21303         * tree.h (div_if_zero_remainder): Declare.
21304         * fold-const.c (div_if_zero_remainder): Export.
21305         * tree-ssa-forwprop.c
21306         (forward_propagate_addr_into_variable_array_index): Handle
21307         constant array index addition outside of the variable index.
21308
21309 2009-03-31  Joseph Myers  <joseph@codesourcery.com>
21310
21311         PR target/39592
21312         * config/i386/i386.md (*floatunssi<mode>2_1, two unnamed
21313         define_splits, floatunssi<mode>2): Require x87 conversions from
21314         DImode to be permitted.
21315
21316 2009-03-31  Joseph Myers  <joseph@codesourcery.com>
21317
21318         PR preprocessor/15638
21319         * c-common.c (c_cpp_error): Handle CPP_DL_FATAL.
21320
21321 2009-03-31  Richard Guenther  <rguenther@suse.de>
21322
21323         PR middle-end/23401
21324         PR middle-end/27810
21325         * tree.h (DECL_GIMPLE_FORMAL_TEMP_P): Remove.
21326         (struct tree_decl_with_vis): Remove gimple_formal_temp member.
21327         * tree-eh.c (lower_eh_constructs_2): Move LHS assignment to
21328         a separate statement.
21329         * gimplify.c (pop_gimplify_context): Remove formal temp handling.
21330         (lookup_tmp_var): Likewise.
21331         (is_gimple_formal_tmp_or_call_rhs): Remove.
21332         (is_gimple_reg_or_call_rhs): Rename to ...
21333         (is_gimple_reg_rhs_or_call): ... this.
21334         (is_gimple_mem_or_call_rhs): Rename to ...
21335         (is_gimple_mem_rhs_or_call): ... this.
21336         (internal_get_tmp_var): Use is_gimple_reg_rhs_or_call.  Set
21337         DECL_GIMPLE_REG_P only if is_formal is true.
21338         (gimplify_compound_lval): Use is_gimple_reg.  Remove workaround
21339         for non-proper post-modify expression gimplification.
21340         (gimplify_self_mod_expr): For post-modify expressions gimplify
21341         the lvalue to a minimal lvalue.
21342         (rhs_predicate_for): Remove formal temp case.
21343         (gimplify_modify_expr_rhs): Likewise.
21344         (gimplify_addr_expr): Use is_gimple_reg.
21345         (gimplify_expr): Remove formal temp cases.
21346         (gimple_regimplify_operands): Likewise.
21347         * tree-ssa-pre.c (get_or_alloc_expr_for): Treat EXC_PTR_EXPR
21348         and FILTER_EXPR like constants.
21349         * gimple.c (walk_gimple_op): Fix val_only initialization, use
21350         is_gimple_reg.
21351         (is_gimple_formal_tmp_rhs): Remove.
21352         (is_gimple_reg_rhs): Remove special casing.
21353         (is_gimple_mem_rhs): Fix.
21354         (is_gimple_reg): Move DECL_GIMPLE_REG_P handling earlier.
21355         (is_gimple_formal_tmp_var): Remove.
21356         (is_gimple_formal_tmp_reg): Likewise.
21357         (is_gimple_min_lval): Allow invariant component ref parts.
21358         * gimple.h (is_gimple_formal_tmp_rhs, is_gimple_formal_tmp_var,
21359         is_gimple_formal_tmp_reg): Remove declarations.
21360         * tree-cfg.c (verify_expr): Verify that variables with address
21361         taken do not have DECL_GIMPLE_REG_P set.
21362         * tree-mudflap.c (mf_build_check_statement_for): Use
21363         force_gimple_operand instead of gimplify_expr.
21364
21365 2009-03-31  Ayal Zaks  <zaks@il.ibm.com>
21366
21367         * modulo-sched.c (sms_schedule_by_order): Pass the actual
21368         schedulable rows to compute_split_row.
21369
21370 2009-03-31  Ben Elliston  <bje@au.ibm.com>
21371
21372         PR target/31635
21373         * config/rs6000/rs6000.c (rs6000_handle_option): Handle
21374         OPT_mvrsave.
21375
21376 2009-03-31  Alan Modra  <amodra@bigpond.net.au>
21377
21378         * doc/invoke.texi (RS/6000 and PowerPC Options):Document mtls-markers.
21379         * configure.ac (HAVE_AS_TLS_MARKERS): New gas feature check.
21380         * configure: Regenerate.
21381         * config.in: Regenerate.
21382         * config/rs6000/rs6000.opt (mtls-markers): Add.
21383         * config/rs6000/rs6000.h (TARGET_TLS_MARKERS): Define.
21384         * config/rs6000/rs6000.md (tls_gd_aix, tls_gd_sysv): Add splitter.
21385         (tls_ld_aix, tls_ld_sysv): Likewise.
21386         (tls_gd, tls_gd_call_aix, tls_gd_call_sysv): New insns.
21387         (tls_ld, tls_ld_call_aix, tls_ld_call_sysv): Likewise.
21388
21389 2009-03-31  Alan Modra  <amodra@bigpond.net.au>
21390
21391         * config/spu/spu.c (spu_expand_prologue): Delete redundant code.
21392
21393 2009-03-30  Jan Hubicka  <jh@suse.cz>
21394
21395         * tree-eh.c (make_eh_edges): Set probability 100% to first edge
21396         out of RESX.
21397         (tree_remove_unreachable_handlers): Cleanup EH predecestor
21398         detection and label handling.
21399
21400 2009-03-30  Vladimir Makarov  <vmakarov@redhat.com>
21401
21402         * ira-int.h (ira_allocno): Rename left_conflicts_num to
21403         left_conflicts_size.
21404         (ALLOCNO_LEFT_CONFLICTS_NUM): Rename to
21405         ALLOCNO_LEFT_CONFLICTS_SIZE.
21406
21407         * ira-color.c (allocno_spill_priority, push_allocno_to_stack,
21408         remove_allocno_from_bucket_and_push,
21409         allocno_spill_priority_compare, push_allocnos_to_stack,
21410         setup_allocno_available_regs_num): Use ALLOCNO_LEFT_CONFLICTS_SIZE
21411         instead of ALLOCNO_LEFT_CONFLICTS_NUM.
21412         (setup_allocno_left_conflicts_num): Ditto.  Rename to
21413         setup_allocno_left_conflicts_size.
21414         (put_allocno_into_bucket): Use ALLOCNO_LEFT_CONFLICTS_SIZE
21415         instead of ALLOCNO_LEFT_CONFLICTS_NUM and
21416         setup_allocno_left_conflicts_size instead of
21417         setup_allocno_left_conflicts_num.
21418
21419         * ira-build.c (ira_create_allocno): Use
21420         ALLOCNO_LEFT_CONFLICTS_SIZE instead of
21421         ALLOCNO_LEFT_CONFLICTS_NUM.
21422
21423 2009-03-30  Vladimir Makarov  <vmakarov@redhat.com>
21424
21425         * reload.c (push_reload, find_dummy_reload): Use df_get_live_out
21426         instead of DF_LR_OUT.
21427
21428         * ira-lives.c (process_bb_node_lives): Ditto.
21429
21430         * ira-color.c (ira_loop_edge_freq): Use df_get_live_{out,in}
21431         instead of DF_LR_{OUT,IN}.
21432
21433         * ira-emit.c (generate_edge_moves, add_ranges_and_copies): Ditto.
21434
21435         * ira-build.c (create_bb_allocnos, create_loop_allocnos): Ditto.
21436
21437 2009-03-30  Jan Hubicka  <jh@suse.cz>
21438
21439         * except.c (label_to_region_map): Fix thinko.
21440
21441 2009-03-30  Steve Ellcey  <sje@cup.hp.com>
21442
21443         PR middle-end/38237
21444         * tree.h (tree_find_value): New declaration.
21445         * tree.c (tree_find_value): New function.
21446         * varasm.c (assemble_external): Avoid duplicate entries on lists.
21447
21448 2009-03-30  Jakub Jelinek  <jakub@redhat.com>
21449
21450         PR debug/39563
21451         * c-decl.c (struct c_binding): Add locus field.
21452         (bind): Add locus argument, set locus field from it.
21453         (pop_scope): For b->nested VAR_DECL or FUNCTION_DECL,
21454         add a DECL_EXTERNAL copy of b->decl to current BLOCK_VARS.
21455         (push_file_scope, pushtag, pushdecl, pushdecl_top_level,
21456         implicitly_declare, undeclared_variable, lookup_label,
21457         declare_label, c_make_fname_decl, c_builtin_function,
21458         c_builtin_function_ext_scope, store_parm_decls_newstyle): Adjust
21459         bind callers.
21460
21461 2009-03-30  H.J. Lu  <hongjiu.lu@intel.com>
21462
21463         PR target/38781
21464         * config/i386/i386.c (classify_argument): Check total size of
21465         structure.
21466
21467 2009-03-30  Martin Jambor  <mjambor@suse.cz>
21468
21469         * ipa-prop.h (jump_func_type): Rename IPA_UNKNOWN, IPA_CONST,
21470         IPA_CONST_MEMBER_PTR, and IPA_PASS_THROUGH to IPA_JF_UNKNOWN,
21471         IPA_JF_CONST, IPA_JF_CONST_MEMBER_PTR, and IPA_JF_PASS_THROUGH
21472         respectively.
21473
21474         * tree-dfa.c (get_ref_base_and_extent): Return -1 maxsize if
21475         seen_variable_array_ref while also traversing a union.
21476
21477         * tree-inline.c (optimize_inline_calls): Do not call
21478         cgraph_node_remove_callees.
21479         * cgraphbuild.c (remove_cgraph_callee_edges): New function.
21480         (pass_remove_cgraph_callee_edges): New variable.
21481         * passes.c (init_optimization_passes): Add
21482         pass_remove_cgraph_callee_edges after early inlining and before all
21483         late intraprocedural passes.
21484
21485         * omp-low.c (expand_omp_taskreg): Always set current_function_decl.
21486
21487 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
21488
21489         * config/sparc/sparc.md (*nand<V64mode>_vis, *nand<V32mode>_vis):
21490         Fix typos in names.
21491
21492 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
21493
21494         * combine.c (simplify_comparison): Use have_insn_for.
21495         * dojump.c (do_jump): Likewise.
21496
21497 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
21498
21499         * config/sparc/sparc.c (sparc_compare_emitted): Remove.
21500         (gen_compare_reg, emit_v9_brxx_insn): Handle MODE_CC
21501         sparc_compare_op0 like sparc_compare_emitted used to be handled.
21502         (sparc_expand_compare_and_swap_12): Set sparc_compare_op0
21503         instead of sparc_compare_emitted.
21504         * config/sparc/sparc.h (sparc_compare_emitted): Remove.
21505         * config/sparc/sparc.md (stack_protect_test): Set sparc_compare_op0
21506         instead of sparc_compare_emitted.
21507
21508 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
21509
21510         * bb-reorder.c (partition_hot_cold_basic_blocks): Do not
21511         enter/exit cfglayout mode.
21512         (pass_partition_block): Require it.
21513         * combine.c (find_single_use, reg_dead_at_p): Use CFG.
21514         (combine_instructions): Track basic blocks instead of labels.
21515         (update_cfg_for_uncondjump): New.
21516         (try_combine): Use it.  Update jumps after rescanning.
21517         (pass_combine): Require PROP_cfglayout.
21518         * passes.c (pass_outof_cfg_layout_mode): Move after regmove.
21519
21520 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
21521
21522         * cfglayout.c (pass_into_cfg_layout_mode, pass_outof_cfg_layout_mode):
21523         Provide/destroy PROP_cfglayout respectively.
21524         * gcse.c (pass_jump_bypass, pass_gcse): Require it.
21525         * tree-pass.h (PROP_cfglayout): New.
21526
21527 2009-03-30  Paolo Bonzini  <bonzini@gnu.org>
21528
21529         * fold-const.c (const_binop, fold_convert_const_real_from_fixed,
21530         fold_convert_const_fixed_from_fixed,
21531         fold_convert_const_fixed_from_int,
21532         fold_convert_const_fixed_from_real, fold_negate_const): Do not
21533         set TREE_CONSTANT_OVERFLOW.
21534         * tree.def: Remove mention of TREE_CONSTANT_OVERFLOW.
21535         * tree.h (TREE_CONSTANT_OVERFLOW): Delete.
21536
21537 2009-03-30  Ira Rosen  <irar@il.ibm.com>
21538
21539         * tree-vect-loop-manip.c: New file.
21540         * tree-vectorizer.c: Update documentation and included files.
21541         (vect_loop_location): Make extern.
21542         (rename_use_op): Move to tree-vect-loop-manip.c
21543         (rename_variables_in_bb, rename_variables_in_loop,
21544         slpeel_update_phis_for_duplicate_loop,
21545         slpeel_update_phi_nodes_for_guard1,
21546         slpeel_update_phi_nodes_for_guard2, slpeel_make_loop_iterate_ntimes,
21547         slpeel_tree_duplicate_loop_to_edge_cfg, slpeel_add_loop_guard,
21548         slpeel_can_duplicate_loop_p, slpeel_verify_cfg_after_peeling,
21549         set_prologue_iterations, slpeel_tree_peel_loop_to_edge,
21550         find_loop_location): Likewise.
21551         (new_stmt_vec_info): Move to tree-vect-stmts.c.
21552         (init_stmt_vec_info_vec, free_stmt_vec_info_vec, free_stmt_vec_info,
21553         get_vectype_for_scalar_type, vect_is_simple_use,
21554         supportable_widening_operation, supportable_narrowing_operation):
21555         Likewise.
21556         (bb_in_loop_p): Move to tree-vect-loop.c.
21557         (new_loop_vec_info, destroy_loop_vec_info,
21558         reduction_code_for_scalar_code, report_vect_op,
21559         vect_is_simple_reduction, vect_is_simple_iv_evolution): Likewise.
21560         (vect_can_force_dr_alignment_p): Move to tree-vect-data-refs.c.
21561         (vect_supportable_dr_alignment): Likewise.
21562         * tree-vectorizer.h (tree-data-ref.h): Include.
21563         (vect_loop_location): Declare.
21564         Reorganize function declarations according to the new file structure.
21565         * tree-vect-loop.c: New file.
21566         * tree-vect-analyze.c: Remove. Move functions to tree-vect-data-refs.c,
21567         tree-vect-stmts.c, tree-vect-slp.c, tree-vect-loop.c.
21568         * tree-vect-data-refs.c: New file.
21569         * tree-vect-patterns.c (timevar.h): Don't include.
21570         * tree-vect-stmts.c: New file.
21571         * tree-vect-transform.c: Remove. Move functions to tree-vect-stmts.c,
21572         tree-vect-slp.c, tree-vect-loop.c.
21573         * Makefile.in (OBJS-common): Remove tree-vect-analyze.o and
21574         tree-vect-transform.o. Add tree-vect-data-refs.o, tree-vect-stmts.o,
21575         tree-vect-loop.o, tree-vect-loop-manip.o, tree-vect-slp.o.
21576         (tree-vect-analyze.o): Remove.
21577         (tree-vect-transform.o): Likewise.
21578         (tree-vect-data-refs.o): Add rule.
21579         (tree-vect-stmts.o, tree-vect-loop.o, tree-vect-loop-manip.o,
21580         tree-vect-slp.o): Likewise.
21581         (tree-vect-patterns.o): Remove redundant dependencies.
21582         (tree-vectorizer.o): Likewise.
21583         * tree-vect-slp.c: New file.
21584
21585 2009-03-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
21586
21587         * optc-gen.awk: Warn if an option flag has multiple different
21588         help strings.
21589
21590 2009-03-30  Sebastian Pop  <sebastian.pop@amd.com>
21591
21592         * doc/invoke.texi (-floop-interchange, -floop-strip-mine,
21593         -floop-block): Document dependences on PPL, CLooG and Graphite.
21594
21595 2009-03-30  Joseph Myers  <joseph@codesourcery.com>
21596
21597         PR rtl-optimization/323
21598         * c-common.c (c_fully_fold, convert_and_check,
21599         c_common_truthvalue_conversion): Handle EXCESS_PRECISION_EXPR.
21600         (c_fully_fold_internal): Disallow EXCESS_PRECISION_EXPR.
21601         * c-common.def (EXCESS_PRECISION_EXPR): New.
21602         * c-cppbuiltin.c (builtin_define_float_constants): Define
21603         constants with enough digits for long double.
21604         * c-lex.c (interpret_float): Interpret constant with excess
21605         precision where appropriate.
21606         * c-opts.c (c_common_post_options): Set
21607         flag_excess_precision_cmdline.  Give an error for
21608         -fexcess-precision=standard for C++ for processors where the
21609         option is significant.
21610         * c-parser.c (c_parser_conditional_expression): Handle excess
21611         precision in condition.
21612         * c-typeck.c (convert_arguments): Handle arguments with excess
21613         precision.
21614         (build_unary_op): Move excess precision outside operation.
21615         (build_conditional_expr): Likewise.
21616         (build_compound_expr): Likewise.
21617         (build_c_cast): Do cast on operand of EXCESS_PRECISION_EXPR.
21618         (build_modify_expr): Handle excess precision in RHS.
21619         (convert_for_assignment): Handle excess precision in converted
21620         value.
21621         (digest_init, output_init_element, process_init_element): Handle
21622         excess precision in initializer.
21623         (c_finish_return): Handle excess precision in return value.
21624         (build_binary_op): Handle excess precision in operands and add
21625         excess precision as needed for operation.
21626         * common.opt (-fexcess-precision=): New option.
21627         * config/i386/i386.h (X87_ENABLE_ARITH, X87_ENABLE_FLOAT): New.
21628         * config/i386/i386.md (float<SSEMODEI24:mode><X87MODEF:mode>2):
21629         For standard excess precision, output explicit conversion to and
21630         truncation from XFmode.
21631         (*float<SSEMODEI24:mode><X87MODEF:mode>2_1,
21632         *float<SSEMODEI24:mode><X87MODEF:mode>2_i387_with_temp,
21633         *float<SSEMODEI24:mode><X87MODEF:mode>2_i387, two unnamed
21634         define_splits, floatdi<X87MODEF:mode>2_i387_with_xmm, two unnamed
21635         define_splits, *floatunssi<mode>2_1, two unnamed define_splits,
21636         floatunssi<mode>2, add<mode>3, sub<mode>3, mul<mode>3, divdf3,
21637         divsf3, *fop_<mode>_comm_i387, *fop_<mode>_1_i387,
21638         *fop_<MODEF:mode>_2_i387, *fop_<MODEF:mode>_3_i387,
21639         *fop_df_4_i387, *fop_df_5_i387, *fop_df_6_i387, two unnamed
21640         define_splits, sqrt<mode>2): Disable where appropriate for
21641         standard excess precision.
21642         * convert.c (convert_to_real): Do not shorten arithmetic to type
21643         for which excess precision would be used.
21644         * defaults.h (TARGET_FLT_EVAL_METHOD_NON_DEFAULT): Define.
21645         * doc/invoke.texi (-fexcess-precision=): Document option.
21646         (-mfpmath=): Correct index entry.
21647         * flags.h (enum excess_precision, flag_excess_precision_cmdline,
21648         flag_excess_precision): New.
21649         * langhooks.c (lhd_post_options): Set
21650         flag_excess_precision_cmdline.
21651         * opts.c (common_handle_option): Handle -fexcess-precision=.
21652         * toplev.c (flag_excess_precision_cmdline, flag_excess_precision,
21653         init_excess_precision): New.
21654         (lang_dependent_init_target): Call init_excess_precision.
21655         * tree.c (excess_precision_type): New.
21656         * tree.h (excess_precision_type): Declare.
21657
21658 2009-03-30  Joseph Myers  <joseph@codesourcery.com>
21659
21660         PR c/35235
21661         * c-typeck.c (build_component_ref): Do not copy qualifiers from
21662         non-lvalue to component.
21663
21664 2009-03-29  Joseph Myers  <joseph@codesourcery.com>
21665
21666         PR preprocessor/34695
21667         * Makefile.in (c-opts.o): Depend on c-tree.h.
21668         * c-common.c: Move down include of diagnostic.h.
21669         (done_lexing, c_cpp_error): New.
21670         * c-common.h (done_lexing): Declare.
21671         * c-decl.c (c_write_global_declarations): Don't check cpp_errors
21672         (parse_in).
21673         * c-opts.c: Include c-tree.h.
21674         (c_common_init_options): Set preprocessor error callback.
21675         (c_common_handle_option): Do not set preprocessor
21676         inhibit_warnings, warnings_are_errors, warn_system_headers,
21677         pedantic_errors or inhibit_warnings flags.
21678         (c_common_post_options): Do not check cpp_errors (parse_in).
21679         (c_common_finish): Do not output dependencies if there were
21680         errors.  Do not check return value of cpp_finish.
21681         * c-ppoutput.c (pp_file_change): Set input_location.
21682         * c-tree.h (c_cpp_error): Declare.
21683         * diagnostic.c (diagnostic_set_info_translated): Also initialize
21684         override_column.
21685         (diagnostic_build_prefix): Check override_column.
21686         * diagnostic.h (diagnostic_info): Add override_column field.
21687         (diagnostic_override_column): Define.
21688
21689 2009-03-28  Paolo Bonzini  <bonzini@gnu.org>
21690
21691         * c-common.c (c_expand_expr, c_staticp): Remove.
21692         * c-common.def (COMPOUND_LITERAL_EXPR): Delete.
21693         * c-common.h (emit_local_var, c_staticp, COMPOUND_LITERAL_EXPR_DECL,
21694         COMPOUND_LITERAL_EXPR_DECL_EXPR): Remove.
21695         * c-gimplify.c (gimplify_compound_literal_expr,
21696         optimize_compound_literals_in_ctor): Remove.
21697         (c_gimplify_expr): Remove COMPOUND_LITERAL_EXPR handling.
21698         * c-objc-common.h (LANG_HOOKS_STATICP): Remove.
21699         * c-semantics.c (emit_local_var): Remove.
21700
21701         * langhooks-def.h (lhd_expand_expr): Remove.
21702         * langhooks.c (lhd_expand_expr): Remove.
21703         * langhooks.h (LANG_HOOKS_DEF): Remove LANG_HOOKS_EXPAND_EXPR.
21704
21705         * expr.c (expand_expr_real_1): Move COMPOUND_LITERAL_EXPR
21706         handling from c-semantics.c; don't call into langhook.
21707         (expand_expr_addr_expr_1): Check that we don't get non-GENERIC trees.
21708         * gimplify.c (gimplify_compound_literal_expr,
21709         optimize_compound_literals_in_ctor): Move from c-gimplify.c.
21710         (gimplify_init_constructor): Call optimize_compound_literals_in_ctor.
21711         (gimplify_modify_expr_rhs, gimplify_expr): Handle COMPOUND_LITERAL_EXPR
21712         as was done in c-gimplify.c.
21713         * tree.c (staticp): Move COMPOUND_LITERAL_EXPR handling from c_staticp.
21714         * tree.h (COMPOUND_LITERAL_EXPR_DECL, COMPOUND_LITERAL_EXPR_DECL_EXPR):
21715         Move from c-common.h.
21716         * tree.def (COMPOUND_LITERAL_EXPR): Move from c-common.def.
21717
21718         * tree.c (staticp): Do not call langhook.
21719         * langhooks.c (lhd_staticp): Delete.
21720         * langhooks-def.h (lhd_staticp): Delete prototype.
21721         (LANG_HOOKS_STATICP): Delete.
21722         (LANG_HOOKS_INITIALIZER): Delete LANG_HOOKS_STATICP.
21723
21724         * doc/c-tree.texi (Expression nodes): Refer to DECL_EXPRs
21725         instead of DECL_STMTs.
21726
21727 2009-03-29  Joseph Myers  <joseph@codesourcery.com>
21728
21729         PR c/456
21730         PR c/5675
21731         PR c/19976
21732         PR c/29116
21733         PR c/31871
21734         PR c/35198
21735         * builtins.c (fold_builtin_sincos): Build COMPOUND_EXPR in
21736         void_type_node.
21737         (fold_call_expr): Return a NOP_EXPR from folding rather than the
21738         contained expression.
21739         * c-common.c (c_fully_fold, c_fully_fold_internal, c_save_expr): New.
21740         (c_common_truthvalue_conversion): Use c_save_expr.  Do not fold
21741         conditional expressions for C.
21742         (decl_constant_value_for_optimization): Move from
21743         decl_constant_value_for_broken_optimization in c-typeck.c.  Check
21744         whether optimizing and that the expression is a VAR_DECL not of
21745         array type instead of doing such checks in the caller.  Do not
21746         check pedantic.  Call gcc_unreachable for C++.
21747         * c-common.def (C_MAYBE_CONST_EXPR): New.
21748         * c-common.h (c_fully_fold, c_save_expr,
21749         decl_constant_value_for_optimization): New prototypes.
21750         (C_MAYBE_CONST_EXPR_PRE, C_MAYBE_CONST_EXPR_EXPR,
21751         C_MAYBE_CONST_EXPR_INT_OPERANDS, C_MAYBE_CONST_EXPR_NON_CONST,
21752         EXPR_INT_CONST_OPERANDS): Define.
21753         * c-convert.c (convert): Strip nops from expression.
21754         * c-decl.c (groktypename): Take extra parameters expr and
21755         expr_const_operands.  Update call to grokdeclarator.
21756         (start_decl): Update call to grokdeclarator.  Add statement for
21757         expressions used in type of decl.
21758         (grokparm): Update call to grokdeclarator.
21759         (push_parm_decl): Update call to grokdeclarator.
21760         (build_compound_literal): Add parameter non_const and build a
21761         C_MAYBE_COSNT_EXPR if applicable.
21762         (grokdeclarator): Take extra parameters expr and
21763         expr_const_operands.  Track expressions used in declaration
21764         specifiers and declarators.  Fold array sizes and track whether
21765         they are constant expressions and whether they are integer
21766         constant expressions.
21767         (parser_xref_tag): Set expr and expr_const_operands fields in
21768         return value.
21769         (grokfield): Update call to grokdeclarator.
21770         (start_function): Update call to grokdeclarator.
21771         (build_null_declspecs): Set expr and expr_const_operands fields in
21772         return value.
21773         (declspecs_add_type): Handle expressions in typeof specifiers.
21774         * c-parser.c (c_parser_declspecs): Set expr and
21775         expr_const_operands fields for declaration specifiers.
21776         (c_parser_enum_specifier): Likewise.
21777         (c_parser_struct_or_union_specifier): Likewise.
21778         (c_parser_typeof_specifier): Likewise.  Update call to
21779         groktypename.  Fold expression as needed.  Return expressions with
21780         type instead of adding statements.
21781         (c_parser_attributes): Update calls to c_parser_expr_list.
21782         (c_parser_statement_after_labels): Fold expression before passing
21783         to objc_build_throw_stmt.
21784         (c_parser_condition): Fold expression.
21785         (c_parser_asm_operands): Fold expression.
21786         (c_parser_conditional_expression): Use c_save_expr.  Update call
21787         to build_conditional_expr.
21788         (c_parser_alignof_expression): Update call to groktypename.
21789         (c_parser_postfix_expression): Preserve C_MAYBE_CONST_EXPR as
21790         original_code.  Fold expression argument of va_arg.  Create
21791         C_MAYBE_CONST_EXPR to preserve side effects of expressions in type
21792         argument to va_arg.  Update calls to groktypename.  Fold array
21793         index for offsetof.  Verify that first argument to
21794         __builtin_choose_expr has integer type.
21795         (c_parser_postfix_expression_after_paren_type): Update calls to
21796         groktypename and build_compound_literal.  Handle expressions with
21797         side effects in type name.
21798         (c_parser_postfix_expression_after_primary): Update call to
21799         c_parser_expr_list.  Set original_code for calls to
21800         __builtin_constant_p.
21801         (c_parser_expr_list): Take extra parameter fold_p.  Fold
21802         expressions if requested.
21803         (c_parser_objc_type_name): Update call to groktypename.
21804         (c_parser_objc_synchronized_statement): Fold expression.
21805         (c_parser_objc_receiver): Fold expression.
21806         (c_parser_objc_keywordexpr): Update call to c_parser_expr_list.
21807         (c_parser_omp_clause_num_threads, c_parser_omp_clause_schedule,
21808         c_parser_omp_atomic, c_parser_omp_for_loop): Fold expressions.
21809         * c-tree.h (CONSTRUCTOR_NON_CONST): Define.
21810         (struct c_typespec): Add elements expr and expr_const_operands.
21811         (struct c_declspecs): Add elements expr and expr_const_operands.
21812         (groktypename, build_conditional_expr, build_compound_literal):
21813         Update prototypes.
21814         (in_late_binary_op): Declare.
21815         * c-typeck.c (note_integer_operands): New function.
21816         (in_late_binary_op): New variable.
21817         (decl_constant_value_for_broken_optimization): Move to c-common.c
21818         and rename to decl_constant_value_for_optimization.
21819         (default_function_array_conversion): Do not strip nops.
21820         (default_conversion): Do not call
21821         decl_constant_value_for_broken_optimization.
21822         (build_array_ref): Do not fold result.
21823         (c_expr_sizeof_expr): Fold operand.  Use C_MAYBE_CONST_EXPR for
21824         result when operand is a VLA.
21825         (c_expr_sizeof_type): Update call to groktypename.  Handle
21826         expressions included in type name.  Use C_MAYBE_CONST_EXPR for
21827         result when operand names a VLA type.
21828         (build_function_call): Update call to build_compound_literal.
21829         Only fold result for calls to __builtin_* functions.  Strip
21830         NOP_EXPR from INTEGER_CST returned from such functions.  Fold
21831         the function designator.
21832         (convert_arguments): Fold arguments.  Update call to
21833         convert_for_assignment.
21834         (build_unary_op): Handle increment and decrement of
21835         C_MAYBE_CONST_EXPR.  Move lvalue checks for increment and
21836         decrement earlier.  Fold operand of increment and decrement.
21837         Handle address of C_MAYBE_CONST_EXPR.  Only fold expression being
21838         built for integer operand.  Wrap returns that are INTEGER_CSTs
21839         without being integer constant expressions or that have integer
21840         constant operands without being INTEGER_CSTs.
21841         (lvalue_p): Handle C_MAYBE_CONST_EXPR.
21842         (build_conditional_expr): Add operand ifexp_bcp.  Track whether
21843         result is an integer constant expression or can be used in
21844         unevaluated parts of one and avoid folding and wrap as
21845         appropriate.  Fold operands before possibly doing -Wsign-compare
21846         warnings.
21847         (build_compound_expr): Wrap result for C99 if operands can be used
21848         in integer constant expressions.
21849         (build_c_cast): Update call to digest_init.  Do not ignore
21850         overflow from casting floating-point constants to integers.  Wrap
21851         results that could be confused with integer constant expressions,
21852         null pointer constants or floating-point constants.
21853         (c_cast_expr): Update call to groktypename.  Handle expressions
21854         included in type name.
21855         (build_modify_expr): Handle modifying a C_MAYBE_CONST_EXPR.  Fold
21856         lhs inside possible SAVE_EXPR.  Fold RHS before assignment.
21857         Update calls to convert_for_assignment.
21858         (convert_for_assignment): Take new parameter
21859         null_pointer_constant.  Do not strip nops or call
21860         decl_constant_value_for_broken_optimization.  Set
21861         in_late_binary_op for conversions to boolean.
21862         (store_init_value): Update call to digest_init.
21863         (digest_init): Take new parameter null_pointer_constant.  Do not
21864         call decl_constant_value_for_broken_optimization.  pedwarn for
21865         initializers not constant expressions.  Update calls to
21866         convert_for_assignment.
21867         (constructor_nonconst): New.
21868         (struct constructor_stack): Add nonconst element.
21869         (really_start_incremental_init, push_init_level, pop_init_level):
21870         Handle constructor_nonconst and nonconst element.
21871         (set_init_index): Call constant_expression_warning for array
21872         designators.
21873         (output_init_element): Fold value.  Set constructor_nonconst as
21874         applicable.  pedwarn for initializers not constant expressions.
21875         Update call to digest_init.  Call constant_expression_warning
21876         where constant initializers are required.
21877         (process_init_element): Use c_save_expr.
21878         (c_finish_goto_ptr): Fold expression.
21879         (c_finish_return): Fold return value.  Update call to
21880         convert_for_assignment.
21881         (c_start_case): Fold switch expression.
21882         (c_process_expr_stmt): Fold expression.
21883         (c_finish_stmt_expr): Create C_MAYBE_CONST_EXPR as needed to
21884         ensure statement expression is not evaluated in constant expression.
21885         (build_binary_op): Track whether results are integer constant
21886         expressions or may occur in such, disable folding and wrap results
21887         as applicable.  Fold operands for -Wsign-compare warnings unless
21888         in_late_binary_op.
21889         (c_objc_common_truthvalue_conversion): Handle results folded to
21890         integer constants that are not integer constant expressions.
21891         * doc/extend.texi: Document when typeof operands are evaluated,
21892         that condition of __builtin_choose_expr is an integer constant
21893         expression, and more about use of __builtin_constant_p in
21894         initializers.
21895
21896 2009-03-29  Richard Guenther  <rguenther@suse.de>
21897
21898         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Properly
21899         propagate addresses of array references.
21900
21901 2009-03-29  Steven Bosscher  <steven@gcc.gnu.org>
21902
21903         * regmove.c (perhaps_ends_bb_p): Remove.
21904         (optimize_reg_copy_1): Don't call perhaps_ends_bb_p.  Get basic block
21905         from INSN and check that the main loop stays within that basic block.
21906         (optimize_reg_copy_1, optimize_reg_copy_3, fixup_match_2): Likewise.
21907         (regmove_forward_pass): Split out from regmove_optimize.  Use
21908         FOR_EACH_BB and FOR_BB_INSNS instead of traversing the insns stream.
21909         (regmove_backward_pass): Split out from regmove_optimize.  Use
21910         FOR_EACH_BB_REVERSE and FOR_BB_INSNS_REVERS_SAFE.
21911         (regmove_optimize): Simplify.
21912
21913 2009-03-29  H.J. Lu  <hongjiu.lu@intel.com>
21914
21915         PR target/39545
21916         * config/i386/i386.c (classify_argument): Ignore flexible array
21917         member in struct and warn ABI change.
21918
21919 2009-03-29  H.J. Lu  <hongjiu.lu@intel.com>
21920
21921         * config/i386/i386-protos.h (ix86_agi_dependent): New.
21922
21923         * config/i386/i386.c (ix86_agi_dependent): Rewrite.
21924         (ix86_adjust_cost): Updated.
21925
21926 2009-03-29  Jan Hubicka  <jh@suse.cz>
21927
21928         PR middle-end/28850
21929         * tree-pass.h (pass_cleanup_eh): New function.
21930         (remove_unreachable_regions): Break code handling RTL
21931         to rtl_remove_unreachable_regions; remove ERT_MUST_NOT_THROW
21932         that can not be reached by runtime.
21933         (can_be_reached_by_runtime): New function.
21934         (label_to_region_map): New function.
21935         (num_eh_regions): New function.
21936         (rtl_remove_unreachable_regions): New function.
21937         (convert_from_eh_region_ranges): Call rtl_remove_unreachable_regions.
21938         (remove_eh_region): New function.
21939         * except.h: Include sbitmap and vecprim.
21940         (remove_eh_region, remove_unreachable_regions, label_to_region_map,
21941         num_eh_regions): Declare.
21942         * passes.c (init_optimization_passes): Schedule cleanup_eh.
21943         * Makefile.in (EXCEPT_H): New; replace all uses of except.h by it.
21944         * tree-eh.c (tree_remove_unreachable_handlers): New function.
21945         (tree_empty_eh_handler_p): New function.
21946         (cleanup_empty_eh): New function.
21947         (cleanup_eh): New function.
21948         (pass_cleanup_eh): New function.
21949
21950 2009-03-29  Jan Hubicka  <jh@suse.cz>
21951
21952         * except.c (verify_eh_tree): Fix handling of fun!=cfun; be ready
21953         for removed regions.
21954
21955 2009-03-29  Jan Hubicka  <jh@suse.cz>
21956
21957         * except.c (dump_eh_tree): Dump all datastructures.
21958
21959 2009-03-29  Jan Hubicka  <jh@suse.cz>
21960
21961         * except.c (duplicate_eh_regions_0): Handle AKA bitmap.
21962         (duplicate_eh_regions_1): Likewise.
21963         (duplicate_eh_regions): Likewise; cleanup code gorwing the region
21964         vector; call EH verification.
21965         (foreach_reachable_handler, can_throw_internal_1, can_throw_external_1):
21966         Be ready for region being removed.
21967
21968 2009-03-29  Jan Hubicka  <jh@suse.cz>
21969
21970         * bitmap.c (bitmap_last_set_bit): New function.
21971         * bitmap.h (bitmap_last_set_bit): Declare.
21972
21973 2009-03-29  David Ayers  <ayers@fsfe.org>
21974
21975         PR objc/27377
21976         * c-typeck.c (build_conditional_expr): Emit ObjC warnings
21977         by calling objc_compare_types and surpress warnings about
21978         incompatible C pointers that are compatible ObjC pointers.
21979
21980 2009-03-29  Adam Nemet  <anemet@caviumnetworks.com>
21981
21982         * cgraphbuild.c (build_cgraph_edges, rebuild_cgraph_edges): Don't
21983         call initialize_inline_failed.
21984         (initialize_inline_failed): Move it from here ...
21985         * cgraph.c (initialize_inline_failed): ... to here.
21986         (cgraph_create_edge): Call initialize_inline_failed rather than
21987         setting inline_failed directly.
21988
21989 2009-03-29  Ben Elliston  <bje@au.ibm.com>
21990
21991         PR target/32542
21992         * sysv4.opt (msdata): Improve comment.
21993         * linux64.h (ASM_SPEC32): Do not pass -memb when -msdata is given.
21994         * sysv4.h (SVR4_ASM_SPEC): Likewise.
21995
21996 2009-03-29  Ben Elliston  <bje@au.ibm.com>
21997
21998         PR target/30451
21999         * config/rs6000/rs6000.md (*movti_ppc64): Correct the order of
22000         load and store attributes.
22001
22002 2009-03-29  Ben Elliston  <bje@au.ibm.com>
22003
22004         * config/i386/i386.c (enum ix86_builtins): Add IX86_BUILTIN_HUGE_VALQ.
22005         (ix86_init_builtins): Add built-in function __builtin_huge_valq.
22006         (ix86_expand_builtin): Handle IX86_BUILTIN_HUGE_VALQ.
22007         * doc/extend.texi (X86 Built-in Functions): Add index entries for
22008         __builtin_infq and __builtin_huge_valq.
22009
22010 2009-03-28  Anatoly Sokolov  <aesok@post.ru>
22011
22012         * config/avr/avr.c (avr_mcu_t): Add atmega8c1, atmega16c1 and
22013         atmega8m1 devices.
22014         * config/avr/avr.h (LINK_SPEC, CRT_BINUTILS_SPECS): (Ditto.).
22015         * config/avr/t-avr (MULTILIB_MATCHES): (Ditto.)
22016
22017 2009-03-28  Xinliang David Li  <davidxl@google.com>
22018
22019         * tree-ssa-ccp.c (ccp_finalize): Add dbg_count support.
22020         (do_dbg_cnt): New function.
22021
22022 2009-03-28  Jan Hubicka  <jh@suse.cz>
22023
22024         Merge from pretty-ipa:
22025
22026         2009-03-27  Jan Hubicka  <jh@suse.cz>
22027
22028         * cgraph.c (dump_cgraph_node): Add replace output flag by process.
22029         * tree-pass.h (function_called_by_processed_nodes_p): Declare.
22030         * passes.c (function_called_by_processed_nodes_p): New.
22031         * ipa-pure-const.c (check_call): Fix handling of operands.
22032         (analyze_function): Dump debug output for skipped bodies.
22033         (local_pure_const): Use function_called_by_processed_nodes_p.
22034         * dwarf2out.c (reference_to_unused): Use output.
22035         * passes.c (do_per_function_toporder): Likewise.
22036
22037         2008-11-12  Jan Hubicka  <jh@suse.cz>
22038
22039         * tree-pass.h (pass_fixup_cfg, pass_local_pure_const): Declare.
22040         * ipa-pure-const.c (funct_state_d): Add can throw field; make
22041         state_set_in_source enum
22042         (check_decl): Ignore memory tags; do not set fake looping flags;
22043         dump diagnostics.
22044         (check_operand, check_tree, check_rhs_var, check_lhs_var,
22045         get_asm_expr_operands, scan_function_op, scan_function_stmt): Remove.
22046         (check_call, analyze_function): Rewrite.
22047         (check_stmt): New.
22048         (add_new_function): Update call of analyze_function.
22049         (generate_summary): Add call of analyze_function.
22050         (propagate): Propagate can_throw; handle state_set_in_source correctly.
22051         (local_pure_const): New function.
22052         (pass_local_pure_const): New pass.
22053         * ipa-inline.c (inline_transform): Set after_inlining.
22054         * tree-eh.c (stmt_can_throw_external): New.
22055         * tree-optimize.c (execute_fixup_cfg): Do not set after_inlining;
22056         work with aliasing built.
22057         * tree-flow.h (stmt_can_throw_external): New.
22058         * passes.c (init_optimization_passes): Schedule fixup_cfg pass early;
22059         and local pure/const pass in early and late optimization queue.
22060
22061 2009-03-28  Martin Jambor  <mjambor@suse.cz>
22062
22063         * fold-const.c (get_pointer_modulus_and_residue): New parameter
22064         allow_func_align.
22065         (fold_binary): Allow function decl aligment consideration is the
22066         second argument is integer constant one.
22067         * tree-ssa-forwprop.c (simplify_bitwise_and): New function.
22068         (tree_ssa_forward_propagate_single_use_vars): Handle assing statements
22069         with BIT_AND_EXPR on the RHS by calling simplify_bitwise_and.
22070
22071 2009-03-28  Jan Hubicka  <jh@suse.cz>
22072
22073         * dwarf2out.c (dwarf2out_begin_prologue): Use crtl->nothrow
22074         * tree-eh.c (stmt_could_throw_p): Remove check for WEAK decls.
22075         * function.h (rtl_data): Add nothrow flag.
22076         * except.c (set_nothrow_function_flags): Use crtl->nothrow;
22077         set DECL_NOTHROW for AVAILABLE functions.
22078
22079 2009-03-28  Jakub Jelinek  <jakub@redhat.com>
22080
22081         * config/rs6000/rs6000-c.c (rs6000_macro_to_expand): If macro
22082         following vector keyword has expansion starting with pixel or bool
22083         keyword, expand vector to __vector and pixel or bool to __pixel or
22084         __bool.
22085
22086         PR c++/39554
22087         * opts.c (warning_disallowed_functions, warn_disallowed_functions,
22088         warn_if_disallowed_function_p): Removed.
22089         (common_handle_option): Don't handle OPT_Wdisallowed_function_list_.
22090         * c-parser.c (c_parser_postfix_expression_after_primary): Don't call
22091         warning_if_disallowed_function_p.
22092         * flags.h (warn_if_disallowed_function_p,
22093         warn_disallowed_functions): Removed.
22094         * common.opt (Wdisallowed-function-list=): Removed.
22095         * doc/invoke.texi (-Wdisallowed-function-list=): Removed.
22096
22097 2009-03-28  Richard Guenther  <rguenther@suse.de>
22098
22099         PR tree-optimization/38723
22100         * tree-ssa-pre.c (compute_avail): Add all default definitions to
22101         the entry block.
22102
22103 2009-03-28  Jan Hubicka  <jh@suse.cz>
22104
22105         * tree-ssa-structalias.c (ipa_pta_execute): Fix bogus node->analyzed
22106         test introduced by my previous patch.
22107
22108 2009-03-28  Richard Guenther  <rguenther@suse.de>
22109
22110         * tree-ssa-copy.c (copy_prop_visit_phi_node): Do not leave
22111         the PHIs value undefined.
22112
22113 2009-03-28  Jan Hubicka  <jh@suse.cz>
22114
22115         * tree-pass.h (pass_fixup_cfg): New pass.
22116         * ipa-inline.c (inline_transform): Set
22117         always_inline_functions_inlined/after_inlining.
22118         * tree-optimize.c (execute_fixup_cfg): Do not set them here.
22119         (pass_fixup_cfg): New pass.
22120         * passes.c (init_optimization_passes): Add fixup_cfg.
22121
22122 2009-03-28  Richard Guenther  <rguenther@suse.de>
22123
22124         PR tree-optimization/38458
22125         * tree-ssa-copy.c (copy_prop_visit_phi_node): For the first
22126         argument use the arguments copy-of value.
22127
22128 2009-03-28  Richard Guenther  <rguenther@suse.de>
22129
22130         PR tree-optimization/38180
22131         * tree-ssa-ccp.c (get_default_value): Simplify.
22132         (likely_value): Likewise.
22133         (surely_varying_stmt_p): Properly handle VOP case.
22134         (ccp_initialize): Likewise.
22135         (ccp_fold): Handle propagating through *&.
22136         (fold_const_aggregate_ref): Also handle decls.
22137
22138 2009-03-28  Jan Hubicka  <jh@suse.cz>
22139
22140         * cgraph.c (dump_cgraph_node): Add replace output flag by process.
22141         * cgraph.h (cgraph_node): Likewise.
22142         * cgraphunit.c (cgraph_process_new_functions): Set process flag.
22143         (cgraph_reset_node): Use process flag.
22144         (cgraph_mark_functions_to_output): Likewise.
22145         (cgraph_expand_function): Likewise.
22146         (cgraph_expand_all_functions): Likewise.
22147         (cgraph_output_in_order): Likewise.
22148         * dwarf2out.c (reference_to_unused): Likewise.
22149         * passes.c do_per_function_toporder): Likewise.
22150
22151 2009-03-28  Jan Hubicka  <jh@suse.cz>
22152
22153         Bring from lto-branch:
22154
22155         2008-09-03  Doug Kwan  <dougkwan@google.com>
22156
22157         * cgraphbuild.c (initialize_inline_failed): Use cgraph_inline_failed_t
22158         enums instead of reason strings.
22159         * cgraph.c (cgraph_create_edge): Same.
22160         (cgraph_inline_failed_string): New function.
22161         * cgraph.h (cgraph_inline_failed_t): New enum type.
22162         (cgraph_inline_failed_string): New prototype.
22163         (struct cgraph_edge): Change type of INLINED_FAILED from constant
22164         char pointer to cgraph_inline_failed_t.
22165         (cgraph_inline_p): Adjust prototype to use cgraph_inline_failed_t.
22166         (cgraph_default_inline_p): Ditto.
22167         * cgraphunit.c (cgraph_inline_p): Change type of parameter REASON
22168         to cgraph_inline_failed_t pointer.
22169         * cif-code.def: New file.
22170         * ipa-inline.c (cgraph_mark_inline_edge): Use an enum instead of a
22171         reason string.
22172         (cgraph_check_inline_limits): Change type of REASON to pointer to
22173         cgraph_inline_failed_t.  Replace reason strings with enums.
22174         (cgraph_default_inline_p): Ditto.
22175         (cgraph_recursive_inlining_p): Ditto.
22176         (update_caller_keys): Change type of FAILED_REASON to
22177         cgraph_inline_failed_t.
22178         (cgraph_set_inline_failed): Change type of REASON to pointer to
22179         cgraph_inline_failed_t.  Call cgraph_inline_failed_string to
22180         convert enums to strings for text output.
22181         (cgraph_decide_inlining_of_small_function): Change FAILED_REASON
22182         to be of type cgraph_inline_failed_t.  Replace reason strings with
22183         enums.  Call cgraph_inline_failed_string to covert enums
22184         to strings for text output.
22185         (cgraph_decide_inlining): Replace reason strings with enums.
22186         (cgraph_decide_inlining_incrementally): Change type of FAILED_REASON
22187         to cgraph_inline_failed_t type.  Call cgraph_inline_failed_string
22188         for text output.
22189         * tree-inline.c (expand_call_inline): Change type of REASON
22190         to cgraph_inline_failed_t.  Replace reason strings with enums.
22191         Call cgraph_inline_failed_string for text output.
22192         * Makefile.in (CGRAPH_H): Add cif-code.def to dependencies.
22193         (cgraph.o): Ditto.
22194
22195 2009-03-28  Jan Hubicka  <jh@suse.cz>
22196
22197         * cgraph.c (cgraph_node, cgraph_remove_node, dump_cgraph_node,
22198         cgraph_clone_node): Remove master clone handling.
22199         (cgraph_is_master_clone, cgraph_master_clone): Remove.
22200         * cgraph.h (master_clone): Remove.
22201         (cgraph_is_master_clone, cgraph_master_clone): Remove.
22202         * ipa-type-escape.c (type_escape_execute): Remove use of master clone.
22203         (tree-ssa-structalias.c (ipa_pta_execute): Likewise.
22204
22205 2009-03-28  Jan Hubicka  <jh@suse.cz>
22206
22207         * cgraph.c (cgraph_function_body_availability): Functions declared
22208         inline are always safe to assume that it is not going to be replaced.
22209
22210 2009-03-28  Richard Guenther  <rguenther@suse.de>
22211
22212         PR tree-optimization/38513
22213         * tree-ssa-pre.c (eliminate): Remove redundant stores.
22214         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Handle
22215         EXC_PTR_EXPR and FILTER_EXPR.
22216         (get_ref_from_reference_ops): Likewise.
22217
22218 2009-03-28  Richard Guenther  <rguenther@suse.de>
22219
22220         PR tree-optimization/38968
22221         * tree-vect-analyze.c (vect_compute_data_ref_alignment):
22222         Use FLOOR_MOD_EXPR to compute misalignment.
22223
22224 2009-03-28  Richard Guenther  <rguenther@suse.de>
22225
22226         PR tree-optimization/37795
22227         * tree.h (combine_comparisons): Declare.
22228         * fold-const.c (combine_comparisons): Export.
22229         * tree-ssa-ifcombine.c (ifcombine_ifandif): Optimize two successive
22230         comparisons.
22231         (ifcombine_iforif): Use combine_comparisons.
22232
22233 2009-03-28  Jan Hubicka  <jh@suse.cz>
22234
22235         * tree-eh.c (inlinable_call_p): New function.
22236         (make_eh_edges): Use it.
22237         (verify_eh_edges): Use it.
22238         (stmt_can_throw_external, stmt_can_throw_internal): Use it.
22239         * except.c (reachable_next_level): Add inlinable_function argument
22240         (sjlj_find_directly_reachable_regions): Update.
22241         (add_reachable_handler): Do not set saw_any_handlers.
22242         (reachable_next_level): Handle MUST_NOT_THROW more curefully.
22243         (foreach_reachable_handler, can_throw_internal_1, can_throw_external_1):
22244         Add new inlinable call parameter.
22245         (can_throw_internal, can_throw_external): Update.
22246         * except.h (can_throw_internal_1, can_throw_external_1,
22247         foreach_reachable_handler): Update declaration.
22248
22249 2009-03-28  Joseph Myers  <joseph@codesourcery.com>
22250
22251         * config/arm/t-arm-coff, config/h8300/coff.h,
22252         config/i386/i386-aout.h, config/i386/i386-coff.h,
22253         config/libgloss.h, config/m68k/coff.h, config/m68k/m68k-aout.h,
22254         config/pdp11/2bsd.h, config/rs6000/aix41.h,
22255         config/rs6000/aix41.opt, config/rs6000/t-newas, config/sh/coff.h,
22256         fix-header.c, fixproto, gen-protos.c, protoize.c, scan-decls.c,
22257         scan-types.sh, scan.c, scan.h, sort-protos, sys-protos.h,
22258         sys-types.h: Remove.
22259         * Makefile.in: Remove protoize and fixproto support and references
22260         in comments.
22261         (SYSCALLS.c.X-warn, TARGET_GETGROUPS_T, STMP_FIXPROTO,
22262         PROTOIZE_INSTALL_NAME, UNPROTOIZE_INSTALL_NAME, FIXPROTO_DEFINES):
22263         Remove.
22264         (ALL_HOST_OBJS): Remove $(PROTO_OBJS).
22265         (MOSTLYCLEANFILES): Remove protoize$(exeext) and
22266         unprotoize$(exeext).
22267         (rest.encap): Don't depend on $(STMP_FIXPROTO)
22268         (.PHONY): Don't depend on proto.
22269         (libgcc-support): Don't depend on $(STMP_FIXPROTO).
22270         (proto, PROTO_OBJS, protoize$(exeext), unprotoize$(exeext),
22271         protoize.o, unprotoize.o, SYSCALLS.c.X, test-protoize-simple,
22272         deduced.h, GEN_PROTOS_OBJS, build/gen-protos$(build_exeext),
22273         build/gen-protos.o, build/scan.o, xsys-protos.h,
22274         build/fix-header$(build_exeext), build/fix-header.o,
22275         build/scan-decls.o, fixhdr.ready, stmp-fixproto,
22276         stmp-install-fixproto): Remove.
22277         (mostlyclean): Don't remove xsys-protos.hT, SYSCALLS.c.X,
22278         SYSCALLS.c or fixproto files.
22279         (install-common): Don't install protoize.
22280         (install-headers-tar, install-headers-cpio, install-headers-cp):
22281         Don't depend on $(STMP_FIXPROTO).
22282         (install-mkheaders): Don't depend on $(STMP_FIXPROTO).  Don't
22283         install fixproto files or write out fixproto settings.
22284         (uninstall): Don't uninstall protoize.
22285         * config.gcc (use_fixproto): Remove.
22286         (arm-*-coff*, armel-*-coff*, h8300-*-*, i[34567]86-*-aout*,
22287         i[34567]86-*-coff*, m68k-*-aout*, m68k-*-coff*, pdp11-*-bsd,
22288         rs6000-ibm-aix4.[12]*, powerpc-ibm-aix4.[12]*, sh-*-*): Remove.
22289         * config/m32r/t-linux (STMP_FIXPROTO): Remove.
22290         * config/m68k/m68k.c: Remove M68K_TARGET_COFF-conditional code.
22291         * config/mips/t-iris (FIXPROTO_DEFINES): Remove.
22292         * config/pa/t-pa-hpux (FIXPROTO_DEFINES): Remove.
22293         * config/pdp11/pdp11.c: Remove TWO_BSD-conditional code.
22294         * config/t-svr4 (FIXPROTO_DEFINES): Remove.
22295         * config/t-vxworks (STMP_FIXPROTO): Remove.
22296         * configure.ac (AC_TYPE_GETGROUPS, TARGET_GETGROUPS_T,
22297         STMP_FIXPROTO): Remove.
22298         * config.in, configure: Regenerate.
22299         * crtstuff.c (gid_t, uid_t): Don't undefine.
22300         * doc/install.texi: Change m68k-coff to m68k-elf in example.
22301         (arm-*-coff, arm-*-aout: Remove target entries.
22302         (*-ibm-aix*): Mention removal of support for AIX 4.2 and older.
22303         Remove mention of AIX 4.1.
22304         (m68k-*-*): Remove mention of m68k-*-aout and m68k-*-coff*.
22305         * doc/invoke.texi (Running Protoize): Remove.
22306         * doc/trouble.texi (Actual Bugs): Remove mention of fixproto.
22307         (Protoize Caveats): Remove.
22308         * tsystem.h: Update comments on headers assumed to exist.
22309
22310 2009-03-27  Vladimir Makarov  <vmakarov@redhat.com>
22311
22312         * genautomata.c: Add a new year to the copyright.  Add a new
22313         reference.
22314         (struct insn_reserv_decl): Add comments for member bypass_list.
22315         (find_bypass): Remove.
22316         (insert_bypass): New.
22317         (process_decls): Use insert_bypass.
22318         (output_internal_insn_latency_func): Output all bypasses with the
22319         same input insn in one switch case.
22320
22321         * rtl.def (define_bypass): Describe bypass choice.
22322         * doc/md.texi (define_bypass): Ditto.
22323
22324 2009-03-27  Richard Guenther  <rguenther@suse.de>
22325
22326         * gimplify.c (mark_addressable): Export.
22327         * tree-flow.h (mark_addressable): Declare.
22328         * tree-ssa-loop-manip.c (create_iv): Mark the base addressable.
22329         * tree-ssa.c (verify_phi_args): Verify that address taken
22330         variables have TREE_ADDRESSABLE set.
22331
22332 2009-03-27  Richard Guenther  <rguenther@suse.de>
22333
22334         * fold-const.c (build_fold_addr_expr_with_type_1): Rename back to ...
22335         (build_fold_addr_expr_with_type): ... this.  Remove in_fold handling.
22336         Do not mark decls TREE_ADDRESSABLE.
22337         (build_fold_addr_expr): Adjust.
22338         (fold_addr_expr): Remove.
22339         (fold_unary): Use build_fold_addr_expr.
22340         (fold_comparison): Likewise.
22341         (split_address_to_core_and_offset): Likewise.
22342         * coverage.c (tree_coverage_counter_addr): Mark the array decl
22343         TREE_ADDRESSABLE.
22344         * gimplify.c (mark_addressable): Do not exclude RESULT_DECLs.
22345         (gimplify_modify_expr_to_memcpy): Mark source and destination
22346         addressable.
22347         * omp-low.c (create_omp_child_function): Mark the object decl
22348         TREE_ADDRESSABLE.
22349         (lower_rec_input_clauses): Mark the var we take the address of
22350         TREE_ADDRESSABLE.
22351         (lower_omp_taskreg): Mark the sender decl TREE_ADDRESSABLE.
22352
22353 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
22354
22355         PR middle-end/39315
22356         * cfgexpand.c (expand_one_stack_var_at): Change alignment
22357         limit to MAX_SUPPORTED_STACK_ALIGNMENT.
22358
22359 2009-03-27  Richard Guenther  <rguenther@suse.de>
22360
22361         PR tree-optimization/39120
22362         * tree-ssa-structalias.c (handle_rhs_call): Fill out return
22363         constraints.
22364         (handle_lhs_call): Process return constraints.  Add escape
22365         constraints if necessary.
22366         (handle_const_call): Fill out return constraints.  Make nested
22367         case more precise.  Avoid consttmp if possible.
22368         (handle_pure_call): Fill out return constraints.  Avoid
22369         callused if possible.
22370         (find_func_aliases): Simplify call handling.
22371
22372 2009-03-27  Richard Guenther  <rguenther@suse.de>
22373
22374         PR tree-optimization/39120
22375         * tree-ssa-structalias.c (do_sd_constraint): Do not use CALLUSED
22376         as a representative.
22377         (solve_graph): Do propagate CALLUSED.
22378         (handle_pure_call): Use a scalar constraint from CALLUSED for
22379         the return value.
22380         (find_what_p_points_to): CALLUSED shall not appear in poins-to
22381         solutions.
22382
22383 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
22384
22385         PR c/39323
22386         * c-common.c (handle_aligned_attribute): Properly check alignment
22387         overflow.  Use (1U << i) instead of (1 << i).
22388
22389         * emit-rtl.c (get_mem_align_offset): Use "unsigned int" for align.
22390
22391         * expr.h (get_mem_align_offset): Updated.
22392
22393         * tree.h (tree_decl_common): Change align to "unsigned int" and
22394         move it before pointer_alias_set.
22395
22396 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
22397             Jakub Jelinek  <jakub@redhat.com>
22398
22399         PR target/38034
22400         * config/ia64/sync.md (cmpxchg_rel_<mode>): Replace input
22401         gr_register_operand with gr_reg_or_0_operand.
22402         (cmpxchg_rel_di): Likewise.
22403         (sync_lock_test_and_set<mode>): Likewise.
22404
22405 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
22406
22407         * jump.c (rtx_renumbered_equal_p): Use subreg_get_info.
22408         (true_regnum): Likewise.
22409
22410         * rtlanal.c (subreg_info): Moved to ...
22411         * rtl.h (subreg_info): Here.  New.
22412         (subreg_get_info): New.
22413
22414         * rtlanal.c (subreg_get_info): Make it extern.
22415
22416 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
22417
22418         PR target/39472
22419         * config/i386/i386.c (ix86_abi): New.
22420         (override_options): Handle -mabi=.
22421         (ix86_function_arg_regno_p): Replace DEFAULT_ABI with ix86_abi.
22422         (ix86_call_abi_override): Likewise.
22423         (init_cumulative_args): Likewise.
22424         (function_arg_advance): Likewise.
22425         (function_arg_64): Likewise.
22426         (function_arg): Likewise.
22427         (ix86_pass_by_reference): Likewise.
22428         (ix86_function_value_regno_p): Likewise.
22429         (ix86_build_builtin_va_list_abi): Likewise.
22430         (setup_incoming_varargs_64): Likewise.
22431         (is_va_list_char_pointer): Likewise.
22432         (ix86_init_machine_status): Likewise.
22433         (ix86_reg_parm_stack_space): Use enum calling_abi on call_abi.
22434         (ix86_function_type_abi): Return enum calling_abi.  Rewrite
22435         for 64bit.  Replace DEFAULT_ABI with ix86_abi.
22436         (ix86_function_abi): Make it static and return enum calling_abi.
22437         (ix86_cfun_abi): Return enum calling_abi.  Replace DEFAULT_ABI
22438         with ix86_abi.
22439         (ix86_fn_abi_va_list): Updated.
22440
22441         * config/i386/i386.h (ix86_abi): New.
22442         (STACK_BOUNDARY): Replace DEFAULT_ABI with ix86_abi.
22443         (CONDITIONAL_REGISTER_USAGE): Likewise.
22444         (CUMULATIVE_ARGS): Change call_abi type to enum calling_abi.
22445         (machine_function): Likewise.
22446
22447         * config/i386/i386.md (untyped_call): Replace DEFAULT_ABI
22448         with ix86_abi.
22449         * config/i386/cygming.h (TARGET_64BIT_MS_ABI): Likewise.
22450         (STACK_BOUNDARY): Likewise.
22451         * config/i386/mingw32.h (EXTRA_OS_CPP_BUILTINS): Likewise.
22452
22453         * config/i386/i386.opt (mabi=): New.
22454
22455         * config/i386/i386-protos.h (ix86_cfun_abi): Changed to
22456         return enum calling_abi.
22457         (ix86_function_type_abi): Likewise.
22458         (ix86_function_abi): Removed.
22459
22460         * doc/invoke.texi: Document -mabi= option for x86.
22461
22462 2009-03-27  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
22463
22464         * builtins.c (real_dconstp): Delete.
22465         (fold_builtin_logarithm): Remove inaccurate log(e) special case.
22466
22467 2009-03-27  Dodji Seketeli  <dodji@redhat.com>
22468             Jakub Jelinek  <jakub@redhat.com>
22469
22470         PR debug/37959
22471         * dwarf2out.c (dwarf_attr_name): Handle DW_AT_explicit attribute.
22472         (gen_subprogram_die): When a function is explicit, generate the
22473         DW_AT_explicit attribute.
22474         * langhooks.h (struct lang_hooks_for_decls): Add
22475         function_decl_explicit_p langhook.
22476         * langhooks-def.h (LANG_HOOKS_FUNCTION_DECL_EXPLICIT_P): Define.
22477         (LANG_HOOKS_DECLS): Add LANG_HOOKS_FUNCTION_DECL_EXPLICIT_P.
22478
22479 2009-03-27  Jakub Jelinek  <jakub@redhat.com>
22480
22481         * builtins.c (fold_builtin_memory_op): Optimize memmove
22482         into memcpy if we can prove source and destination don't overlap.
22483
22484         * tree-inline.c: Include gt-tree-inline.h.
22485         (clone_fn_id_num): New variable.
22486         (clone_function_name): New function.
22487         (tree_function_versioning): Use it.
22488         * Makefile.in (GTFILES): Add tree-inline.c.
22489
22490 2009-03-27  Mark Mitchell  <mark@codesourcery.com>
22491
22492         * BASE-VER: Change to 4.5.0.
22493
22494 2009-03-27  Xinliang David Li  <davidxl@google.com>
22495
22496         PR tree-optimization/39557
22497         * tree-ssa.c (warn_uninitialized_vars): free postdom info.
22498
22499 2009-03-27  Xinliang David Li  <davidxl@google.com>
22500
22501         PR tree-optimization/39548
22502         * tree-ssa-copy.c (copy_prop_visit_phi_node): Add copy
22503         candidate check.
22504
22505 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
22506
22507         * c-common.c (pointer_int_sum): Use %wd on return from
22508         tree_low_cst.
22509
22510 2009-03-27  H.J. Lu  <hongjiu.lu@intel.com>
22511
22512         * c-common.c (pointer_int_sum): Use HOST_WIDE_INT_PRINT_DEC
22513         on return from tree_low_cst.
22514
22515 2009-03-27  Andrew Pinski  <andrew_pinski@playstation.sony.com>
22516
22517         PR c++/36799
22518         * ginclude/stdarg.h (va_copy): Define also for
22519         __GXX_EXPERIMENTAL_CXX0X__.
22520
22521 2009-03-27  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
22522
22523         PR c++/35652
22524         * builtins.h (c_strlen): Do not warn here.
22525         * c-typeck.c (build_binary_op): Adjust calls to pointer_int_sum.
22526         * c-common.c (pointer_int_sum): Take an explicit location.
22527         Warn about offsets out of bounds.
22528         * c-common.h (pointer_int_sum): Adjust declaration.
22529
22530 2009-03-26  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
22531
22532         * doc/invoke.texi (i386 and x86-64 Windows Options): Fix texinfo
22533         markup glitch.
22534
22535 2009-03-26  Jakub Jelinek  <jakub@redhat.com>
22536
22537         PR c++/39554
22538         * opts.c (warn_if_disallowed_function_p): Don't assume
22539         get_callee_fndecl must return non-NULL.
22540
22541 2009-03-26  Vladimir Makarov  <vmakarov@redhat.com>
22542
22543         PR rtl-optimization/39522
22544         * reload1.c (reload_as_needed): Invalidate reg_last_reload_reg too
22545         when reg_reloaded_valid is set.
22546
22547 2009-03-26  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
22548
22549         * config/spu/divv2df3.c: New file.
22550         * config/spu/t-spu-elf (LIB2FUNCS_STATIC_EXTRA): Add it.
22551         (DPBIT_FUNCS): Filter out _div_df.
22552
22553 2009-03-26  Bernd Schmidt  <bernd.schmidt@analog.com>
22554
22555         * config/bfin/bfin.c (bfin_optimize_loop): If the LSETUP goes before
22556         a jump insn, count that jump in the distance to the loop start.
22557
22558 2009-03-25  Kaz Kojima  <kkojima@gcc.gnu.org>
22559
22560         PR target/39523
22561         * config/sh/sh.c (calc_live_regs): Fix condition for global
22562         registers except PIC_OFFSET_TABLE_REGNUM.
22563
22564 2009-03-25  Kai Tietz  <kai.tietz@onevision.com>
22565
22566         PR/39518
22567         * doc/invoke.texi (-mconsole): New.
22568         (-mcygwin): New.
22569         (-mno-cygwin): New.
22570         (-mdll): New.
22571         (-mnop-fun-dllimport): New.
22572         (-mthread): New.
22573         (-mwin32): New.
22574         (-mwindows): New.
22575         (sub section "i386 and x86-64 Windows Options"): New.
22576
22577 2009-03-25  Ralf Corsépius  <ralf.corsepius@rtems.org>
22578
22579         * config/arm/rtems-elf.h: Remove LINK_GCC_C_SEQUENCE_SPEC.
22580         * config/rs6000/t-rtems: Remove MULTILIB_EXTRA_OPTS.
22581
22582 2009-03-25  Richard Guenther  <rguenther@suse.de>
22583
22584         PR middle-end/39497
22585         * Makefile.in (dfp.o-warn): Use -fno-strict-aliasing instead
22586         of -Wno-error.
22587
22588 2009-03-25  Andrey Belevantsev  <abel@ispras.ru>
22589
22590         * config/ia64/ia64.c (ia64_set_sched_flags): Zero spec_info->mask when
22591         neither of haifa/selective schedulers are working.
22592
22593 2009-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
22594
22595         * doc/invoke.texi (Debugging Options): Fix description of
22596         -fno-merge-debug-strings.
22597
22598 2009-03-24  Hans-Peter Nilsson  <hp@axis.com>
22599
22600         * config/cris/libgcc.ver: New version-script.
22601         * config/cris/t-linux (SHLIB_MAPFILES): Use it.
22602
22603         * configure.ac <GAS features, nop mnemonic>: Add pattern
22604         crisv32-*-* for "nop".
22605         <GAS features, Thread-local storage>: Add item for CRIS and CRIS v32.
22606         * configure: Regenerate.
22607
22608 2009-03-24  Ira Rosen  <irar@il.ibm.com>
22609
22610         PR tree-optimization/39529
22611         * tree-vect-transform.c (vect_create_data_ref_ptr): Call
22612         mark_sym_for_renaming for the tag copied to the new vector
22613         pointer.
22614
22615 2009-03-24  Arthur Loiret  <aloiret@debian.org>
22616
22617         * config.host (alpha*-*-linux*): Use driver-alpha.o and alpha/x-alpha.
22618         * config/alpha/linux.h (host_detect_local_cpu): Declare, add to
22619         EXTRA_SPEC_FUNCTIONS.
22620         (MCPU_MTUNE_NATIVE_SPECS, DRIVER_SELF_SPECS): New macros.
22621         * config/alpha/driver-alpha.c, config/alpha/x-alpha: New.
22622         * doc/invoke.texi (DEC Alpha Options): Document 'native' value for
22623         -march and -mtune options.
22624
22625 2009-03-24  Ralf Corsépius  <ralf.corsepius@rtems.org>
22626
22627         * config/m68k/t-rtems: Add m5329 multilib.
22628
22629 2009-03-24  Dodji Seketeli  <dodji@redhat.com>
22630             Jakub Jelinek  <jakub@redhat.com>
22631
22632         PR debug/39524
22633         * dwarf2out.c (gen_variable_die): Avoid adding duplicate declaration
22634         nodes.
22635
22636 2009-03-23  Jakub Jelinek  <jakub@redhat.com>
22637
22638         PR c/39495
22639         * c-parser.c (c_parser_omp_for_loop): Call c_parser_binary_expression
22640         instead of c_parser_expression_conv, if original_code isn't one of the
22641         4 allowed comparison codes, fail.
22642
22643 2009-03-23  Richard Guenther  <rguenther@suse.de>
22644
22645         * cgraph.h (struct cgraph_node): Reorder fields for 64-bit hosts.
22646         * tree.h (struct tree_type): Likewise.
22647         * reload.h (struct insn_chain): Likewise.
22648         * dwarf2out.c (struct dw_loc_descr_struct): Likewise.
22649         * function.h (struct function): Likewise.
22650         * tree-ssa-structalias.c (struct equiv_class_label): Likewise.
22651
22652 2009-03-23  Jakub Jelinek  <jakub@redhat.com>
22653
22654         PR tree-optimization/39516
22655         * lambda-code.c (perfect_nestify): Fix type of the uboundvar variable.
22656
22657 2009-03-23  Bingfeng Mei  <bmei@broadcom.com>
22658
22659         * config.gcc (need_64bit_hwint): Make clear that need_64bit_hwint
22660         should be set true if BITS_PER_WORD of target is bigger than 32
22661
22662 2009-03-22  Hans-Peter Nilsson  <hp@axis.com>
22663
22664         * config/cris/linux.h (CRIS_LINK_SUBTARGET_SPEC):
22665         Translate -B-options to -rpath-link.  Correct existing
22666         rpath-link and conditionalize on !nostdlib.
22667
22668 2009-03-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
22669
22670         * doc/extend.texi (Function Attributes, Variable Attributes):
22671         Fix typos.
22672         * doc/invoke.texi (Debugging Options, Optimize Options)
22673         (i386 and x86-64 Options, MCore Options): Likewise.
22674
22675 2009-03-20  Jakub Jelinek  <jakub@redhat.com>
22676
22677         PR debug/37890
22678         * dwarf2out.c (gen_namespace_die): Add context_die argument and use
22679         it for block local namespace aliases.
22680         (gen_decl_die): Pass context_die to gen_namespace_die.
22681
22682 2009-03-19  Jakub Jelinek  <jakub@redhat.com>
22683
22684         PR c/39495
22685         * c-omp.c (c_finish_omp_for): Allow NE_EXPR with TREE_TYPE (decl)'s
22686         minimum or maximum value.
22687
22688 2009-03-19  Alexandre Oliva  <aoliva@redhat.com>
22689
22690         * reginfo.c (globalize_reg): Recompute derived reg sets.
22691
22692 2009-03-19  Ozkan Sezer  <sezeroz@gmail.com>
22693
22694         PR target/39063
22695         * libgcc2.c (mprotect): Do not use signed arguments for
22696         VirtualProtect, use DWORD arguments.  Also fix the 'may
22697         be used uninitialized' warning for the np variable.
22698
22699 2009-03-19  Jakub Jelinek  <jakub@redhat.com>
22700
22701         PR target/39496
22702         * config/i386/i386.c (ix86_function_regparm): Don't optimize local
22703         functions using regparm calling conventions when not optimizing.
22704         (ix86_function_sseregparm): Similarly for sseregparm calling
22705         conventions.
22706
22707 2009-03-19  Li Feng  <nemokingdom@gmail.com>
22708
22709         PR middle-end/39500
22710         * tree-data-ref.c (analyze_subscript_affine_affine): There is no
22711         dependence if the first conflict is after niter iterations.
22712
22713 2009-03-19  Hans-Peter Nilsson  <hp@axis.com>
22714
22715         PR middle-end/38609
22716         * config/cris/cris.h (FRAME_POINTER_REQUIRED): Force for all
22717         functions with dynamic stack-pointer adjustments.
22718
22719 2009-03-19  Ben Elliston  <bje@au.ibm.com>
22720
22721         * doc/invoke.texi (RS/6000 and PowerPC Options): Fix -msdata-data
22722         option; change to -msdata=data.
22723
22724 2009-03-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
22725
22726         * c.opt: Unify help texts for -Wdeprecated, -Wsystem-headers,
22727         and -fopenmp.
22728
22729 2009-03-18  Eric Botcazou  <ebotcazou@adacore.com>
22730
22731         PR target/35180
22732         * config/sparc/sparc.md (do_builtin_setjmp_setup): Prettify asm output.
22733
22734 2009-03-18  Sandra Loosemore  <sandra@codesourcery.com>
22735
22736         * doc/invoke.texi (Code Gen Options): Expand discussion of
22737         -fno-common.
22738
22739 2009-03-18  Jakub Jelinek  <jakub@redhat.com>
22740
22741         * dse.c (struct group_info): Reorder fields for 64-bit hosts.
22742         * matrix-reorg.c (struct matrix_info): Likewise.
22743         * tree-ssa-loop-ivopts.c (struct ivopts_data): Likewise.
22744         * rtl.h (struct mem_attrs): Likewise.
22745         * df.h (struct df): Likewise.
22746         * tree-data-ref.h (struct data_dependence_relation): Likewise.
22747         * ira-int.h (struct ira_allocno): Likewise.
22748         * df-scan.c (struct df_collection_rec): Likewise.
22749         * ira.c (struct equivalence): Likewise.
22750         * function.c (struct temp_slot): Likewise.
22751         * cfgloop.h (struct loop): Likewise.
22752
22753         PR debug/39485
22754         * function.c (use_register_for_decl): When not optimizing, disregard
22755         register keyword for variables with types containing methods.
22756
22757 2009-03-18  Sebastian Pop  <sebastian.pop@amd.com>
22758
22759         PR middle-end/39447
22760         * graphite.c (exclude_component_ref): Renamed contains_component_ref_p.
22761         (is_simple_operand): Call contains_component_ref_p before calling data
22762         reference analysis that would fail on COMPONENT_REFs.
22763
22764         * tree-vrp.c (search_for_addr_array): Fix formatting.
22765
22766 2009-03-18  Richard Guenther  <rguenther@suse.de>
22767
22768         * tree-vect-transform.c (vect_loop_versioning): Fold the
22769         generated comparisons.
22770         * tree-vectorizer.c (set_prologue_iterations): Likewise.
22771         (slpeel_tree_peel_loop_to_edge): Likewise.
22772
22773 2009-03-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
22774
22775         PR middle-end/37805
22776         * opts.c (print_specific_help): In addition to `undocumented',
22777         accept `separate' and `joined' flags if passed alone.  Describe
22778         output by the first matched one of those.
22779         (common_handle_option): Skip over empty strings.
22780         * gcc.c (display_help): Fix help string for `--help='.
22781         * doc/invoke.texi (Option Summary, Overall Options): With
22782         `--help=', classes and qualifiers can both be repeated, but
22783         only the latter can be negated.  One should not pass only
22784         negated qualifiers.  Fix markup and examples.
22785
22786         Revert
22787         2008-10-14  Jakub Jelinek  <jakub@redhat.com>
22788         PR middle-end/37805
22789         * opts.c (common_handle_option): Don't ICE on -fhelp=joined
22790         and -fhelp=separate.
22791
22792 2009-03-17  Jing Yu  <jingyu@google.com>
22793
22794         PR middle-end/39378
22795         * function.h (struct rtl_data): Move is_thunk from here...
22796         (struct function): ...to here.
22797         * cp/method.c (use_thunk): Change is_thunk from crtl to cfun.
22798         * varasm.c (assemble_start_function): Change is_thunk from crtl to
22799         cfun.
22800         * config/alpha/alpha.c (alpha_sa_mask): Change is_thunk from crtl to
22801         cfun.
22802         (alpha_does_function_need_gp, alpha_start_function): Likewise.
22803         (alpha_output_function_end_prologue): Likewise.
22804         (alpha_end_function, alpha_output_mi_thunk_osf): Likewise.
22805         * config/rs6000/rs6000.c (rs6000_ra_ever_killed): Likewise.
22806         (rs6000_output_function_epilogue): Likewise.
22807         * config/arm/arm.h (ARM_DECLARE_FUNCTION_NAME): Likewise.
22808
22809 2009-03-17  Uros Bizjak  <ubizjak@gmail.com>
22810
22811         PR target/39482
22812         * config/i386/i386.md (*truncdfsf_mixed): Avoid combining registers
22813         from different units in a single alternative.
22814         (*truncdfsf_i387): Ditto.
22815         (*truncxfsf2_mixed): Ditto.
22816         (*truncxfdf2_mixed): Ditto.
22817
22818 2009-03-17  Jakub Jelinek  <jakub@redhat.com>
22819
22820         * dwarf2out.c (dwarf2out_imported_module_or_decl_1): Allow
22821         non-NAMESPACE_DECL IMPORTED_DECL_ASSOCIATED_DECL.
22822
22823         PR debug/39474
22824         * tree-ssa-live.c (remove_unused_locals): Don't remove local
22825         unused non-artificial variables when not optimizing.
22826
22827         PR debug/39471
22828         * dwarf2out.c (dwarf2out_imported_module_or_decl_1): Emit
22829         DW_TAG_imported_module even if decl is IMPORTED_DECL with
22830         NAMESPACE_DECL in its DECL_INITIAL.
22831
22832         PR middle-end/39443
22833         * optabs.c (set_user_assembler_libfunc): New function.
22834         * expr.h (set_user_assembler_libfunc): New prototype.
22835         * c-common.c: Include libfuncs.h.
22836         (set_builtin_user_assembler_name): Call set_user_assembler_libfunc
22837         for memcmp, memset, memcpy, memmove and abort.
22838         * Makefile.in (c-common.o): Depend on libfuncs.h.
22839
22840         PR debug/39412
22841         * dwarf2out.c (gen_inlined_enumeration_type_die,
22842         gen_inlined_structure_type_die, gen_inlined_union_type_die,
22843         gen_tagged_type_instantiation_die): Removed.
22844         (gen_decl_die): For TYPE_DECL_IS_STUB with non-NULL decl_origin
22845         do nothing.
22846
22847 2009-03-17  Janis Johnson  <janis187@us.ibm.com>
22848
22849         PR testsuite/38526
22850         * Makefile.in (site.exp): Rename TEST_GCC_EXEC_PREFIX and comment
22851         its use.
22852         (check-%): Don't set GCC_EXEC_PREFIX when invoking runtest.
22853         (check-parallel-%): Ditto.
22854         (check-consistency): Ditto.
22855
22856 2009-03-17  Kai Tietz  <kai.tietz@onevision.com>
22857
22858         * ipa-struct-reorg.c (create_general_new_stmt): Initialize
22859         local variable rhs by NULL_TREE.
22860
22861 2009-03-17  H.J. Lu  <hongjiu.lu@intel.com>
22862
22863         PR target/39477
22864         * doc/extend.texi: Correct register behavior for regparm on Intel 386.
22865
22866 2009-03-17  H.J. Lu  <hongjiu.lu@intel.com>
22867
22868         PR target/39476
22869         * config/i386/i386.c (ix86_function_regparm): Rewrite for 64bit.
22870
22871 2009-03-17  H.J. Lu  <hongjiu.lu@intel.com>
22872
22873         PR target/39473
22874         * config/i386/i386.c (ix86_expand_call): Check extra clobbers
22875         for ms->sysv ABI calls only in 64bit mode.
22876
22877         * config/i386/i386.md (untyped_call): Support 32bit.
22878
22879 2009-03-16  H.J. Lu  <hongjiu.lu@intel.com>
22880
22881         * doc/extend.texi: Replace x86_65 with x86_64.
22882
22883 2009-03-16  Jakub Jelinek  <jakub@redhat.com>
22884
22885         PR tree-optimization/39455
22886         * tree-ssa-loop-niter.c (number_of_iterations_lt_to_ne): Fix types
22887         mismatches for POINTER_TYPE_P (type).
22888         (number_of_iterations_le): Likewise.
22889
22890 2009-03-16  Hariharan Sandanagobalane  <hariharan@picochip.com>
22891
22892         * config/picochip/picochip.c: Removed profiling support.
22893         * config/picochip/picochip.md: Removed profiling instruction.
22894         * config/picochip/picochip.h: Removed profiling builtin.
22895
22896 2009-03-16  Joseph Myers  <joseph@codesourcery.com>
22897
22898         * doc/install.texi (--with-host-libstdcxx): Document.
22899
22900 2009-03-14  Anatoly Sokolov  <aesok@post.ru>
22901
22902         PR target/34299
22903         * config/avr/avr.c (avr_handle_fndecl_attribute): Move code for
22904         generate a warning if the function name does not begin with
22905         "__vector" and the function has either the 'signal' or 'interrupt'
22906         attribute, from here to ...
22907         (avr_declare_function_name): ...here. New function.
22908         * config/avr/avr.h (ASM_DECLARE_FUNCTION_NAME): Redefine.
22909         * config/avr/avr-protos.h (avr_declare_function_name): Declare.
22910
22911 2009-03-14  Jakub Jelinek  <jakub@redhat.com>
22912
22913         PR bootstrap/39454
22914         * cse.c (fold_rtx): Don't modify original const_arg1 when
22915         canonicalizing SHIFT_COUNT_TRUNCATED shift count, do it on a
22916         separate variable instead.
22917         * rtlanal.c (nonzero_bits1) <case ASHIFTRT>: Don't assume anything
22918         from out of range shift counts.
22919         (num_sign_bit_copies1) <case ASHIFTRT, case ASHIFT>: Similarly.
22920
22921 2009-03-13  Catherine Moore  <clm@codesourcery.com>
22922
22923         * config/i386/x-mingw32 (host-mingw32.o): Replace
22924         diagnostic.h with $(DIAGNOSTIC_H).
22925
22926 2009-03-12  Jakub Jelinek  <jakub@redhat.com>
22927
22928         PR target/39431
22929         * config/i386/predicates.md (cmpxchg8b_pic_memory_operand): New
22930         predicate.
22931         * config/i386/sync.md (sync_compare_and_swap<mode>,
22932         sync_compare_and_swap_cc<mode>): For DImode with -m32 -fpic check
22933         if operands[1] is cmpxchg8b_pic_memory_operand, if not force address
22934         into a register.
22935         (sync_double_compare_and_swapdi_pic,
22936         sync_double_compare_and_swap_ccdi_pic): Require operand 1 to be
22937         cmpxchg8b_pic_memory_operand instead of just memory_operand.
22938
22939 2009-03-12  H.J. Lu  <hongjiu.lu@intel.com>
22940
22941         PR target/39445
22942         * config/i386/i386.c (ix86_expand_push): Don't set memory alignment.
22943
22944 2009-03-12  H.J. Lu  <hongjiu.lu@intel.com>
22945
22946         PR target/39327
22947         * config/i386/sse.md (avx_addsubv8sf3): Correct item bits.
22948         (avx_addsubv4df3): Likewise.
22949         (*avx_addsubv4sf3): Likewise.
22950         (sse3_addsubv4sf3): Likewise.
22951
22952 2009-03-12  H.J. Lu  <hongjiu.lu@intel.com>
22953
22954         PR target/38824
22955         * config/i386/i386.md: Compare REGNO on the new peephole2 patterns.
22956
22957 2009-03-12  Vladimir Makarov  <vmakarov@redhat.com>
22958
22959         PR debug/39432
22960         * ira-int.h (struct allocno): Fix comment for calls_crossed_num.
22961         * ira-conflicts.c (ira_build_conflicts): Prohibit call used
22962         registers for allocnos created from user-defined variables.
22963
22964 2009-03-11  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
22965
22966         PR target/39181
22967         * config/spu/spu.c (spu_expand_mov): Handle invalid subregs
22968         of non-integer mode as well.
22969
22970 2009-03-11  Adam Nemet  <anemet@caviumnetworks.com>
22971
22972         * gimplify.c (gimplify_call_expr): Don't set CALL_CANNOT_INLINE_P
22973         for functions for which the parameter types are unknown.
22974
22975 2009-03-11  Jakub Jelinek  <jakub@redhat.com>
22976
22977         PR target/39137
22978         * cfgexpand.c (get_decl_align_unit): Use LOCAL_DECL_ALIGNMENT macro.
22979         * defaults.h (LOCAL_DECL_ALIGNMENT): Define if not yet defined.
22980         * config/i386/i386.h (LOCAL_DECL_ALIGNMENT): Define.
22981         * config/i386/i386.c (ix86_local_alignment): For
22982         -m32 -mpreferred-stack-boundary=2 use 32-bit alignment for
22983         long long variables on the stack to avoid dynamic realignment.
22984         Allow the first argument to be a decl rather than type.
22985         * doc/tm.texi (LOCAL_DECL_ALIGNMENT): Document.
22986
22987 2009-03-11  Nick Clifton  <nickc@redhat.com>
22988
22989         PR target/5362
22990         * config/mcore/mcore.opt: Remove deprecated m4align and m8align
22991         options.
22992         Add description to mno-lsim option.
22993         * config/mcore/mcore.h: Remove comment about deprecated m4align
22994         option.
22995         (TARGET_DEFAULT): Remove deprecated MASK_M8ALIGN.
22996         * doc/invoke.texi: Add description of mno-lsim and
22997         mstack-increment options.
22998
22999         * config/fr30/fr30.opt: Document the -mno-lsim option.
23000         * doc/invoke.texi: Add descriptions of the FR30's -msmall-model
23001         and -mno-lsim options.
23002
23003 2009-03-11  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
23004
23005         * fold-const.c (fold_comparison): Only call fold_inf_compare
23006         if the mode supports infinities.
23007
23008 2009-03-11  Jason Merrill  <jason@redhat.com>
23009
23010         PR debug/39086
23011         * tree-nrv.c (tree_nrv): Don't do this optimization if the front
23012         end already did.  Notice GIMPLE_CALL modifications of the result.
23013         Don't copy debug information from an ignored decl or a decl from
23014         another function.
23015
23016 2009-03-10  Richard Guenther  <rguenther@suse.de>
23017             Nathan Froyd  <froydnj@codesourcery.com>
23018
23019         PR middle-end/37850
23020         * libgcc2.c (__mulMODE3): Use explicit assignments to form the result.
23021         (__divMODE3): Likewise.
23022
23023 2009-03-09  Jakub Jelinek  <jakub@redhat.com>
23024
23025         PR tree-optimization/39394
23026         * gimplify.c (gimplify_type_sizes): Gimplify DECL_SIZE and
23027         DECL_SIZE_UNIT of variable length FIELD_DECLs.
23028
23029 2009-03-09  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
23030
23031         * recog.c (verfiy_changes): Disallow renaming of hard regs in
23032         inline asms for register asm ("") declarations.
23033
23034 2009-03-09  Eric Botcazou  <ebotcazou@adacore.com>
23035
23036         * fold-const.c (fold_unary): Fix comment.
23037
23038 2009-03-07  Jan Hubicka  <jh@suse.cz>
23039
23040         PR target/39361
23041         * tree-inline.c (setup_one_parameter): Do replacement of const
23042         argument by constant in SSA form.
23043
23044 2009-03-07  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
23045
23046         PR middle-end/38028
23047         * function.c (assign_parm_setup_stack): Use STACK_SLOT_ALIGNMENT to
23048         determine alignment passed to assign_stack_local.
23049         (assign_parms_unsplit_complex): Likewise.
23050         * except.c (sjlj_build_landing_pads): Likewise.
23051
23052 2009-03-06  Jakub Jelinek  <jakub@redhat.com>
23053
23054         PR middle-end/39360
23055         * tree-flow.h (add_referenced_var): Return bool instead of void.
23056         * tree-dfa.c (add_referenced_var): Return result of
23057         referenced_var_check_and_insert call.
23058         * tree-inline.c (expand_call_inline): Call add_referenced_var instead
23059         of referenced_var_check_and_insert.
23060
23061         PR debug/39372
23062         * dwarf2out.c (add_abstract_origin_attribute): Return origin_die.
23063         (gen_variable_die): Emit DW_AT_location on abstract static variable's
23064         DIE, don't emit it if abstract origin already has it.
23065         * tree-cfg.c (remove_useless_stmts_bind): GIMPLE_BINDs with any
23066         BLOCK_NONLOCALIZED_VARS in its gimple_bind_block aren't useless.
23067
23068 2009-03-06  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
23069
23070         * genpreds.c (needs_variable): Fix parentheses at variable name
23071         detection.
23072         (write_tm_constrs_h): Indent generated code.
23073
23074 2009-03-06  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
23075
23076         * doc/extend.texi (Function Attributes): Add documentation
23077         for isr attributes.
23078
23079 2009-03-06  Jakub Jelinek  <jakub@redhat.com>
23080
23081         PR debug/39387
23082         * dwarf2out.c (dwarf2out_imported_module_or_decl_1): For IMPORTED_DECL
23083         take locus from its DECL_SOURCE_LOCATION instead of input_location.
23084
23085 2009-03-05  Bernd Schmidt  <bernd.schmidt@analog.com>
23086
23087         * config/bfin/bfin.c (bfin_discover_loop): When retrying fails, mark
23088         the loop as bad.
23089
23090 2009-03-05  Jakub Jelinek  <jakub@redhat.com>
23091
23092         PR debug/39379
23093         * tree-cfg.c (remove_useless_stmts_bind): Don't remove GIMPLE_BINDs
23094         with blocks containing IMPORTED_DECLs in BLOCK_VARS.
23095
23096 2009-03-05  Uros Bizjak  <ubizjak@gmail.com>
23097
23098         * config/i386/i386.md (R8_REG, R9_REG): New constants.
23099         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Use named
23100         constants instead of magic numbers.
23101         (HARD_REGNO_CALLER_SAVE_MODE): Ditto.
23102         (QI_REG_P): Ditto.
23103         * config/i386/i386.c (x86_64_int_parameter_registers): Ditto.
23104         (x86_64_ms_abi_int_parameter_registers): Ditto.
23105         (x86_64_int_return_registers): Ditto.
23106         (ix86_maybe_switch_abi): Ditto.
23107         (ix86_expand_call): Ditto for clobbered_registers array.
23108         (ix86_hard_regno_mode_ok): Ditto.
23109         (x86_extended_QIreg_mentioned_p): Ditto.
23110
23111 2009-03-05  J"orn Rennecke  <joern.rennecke@arc.com>
23112
23113         PR tree-optimization/39349
23114         * cse.c (cse_insn): Fix loop to stop at VOIDmode.
23115
23116         * combine.c (gen_lowpart_for_combine): Use omode when generating
23117         clobber.
23118
23119 2009-03-04  J"orn Rennecke  <joern.rennecke@arc.com>
23120
23121         PR rtl-optimization/39235
23122         * loop-iv.c (get_simple_loop_desc): Use XCNEW.
23123
23124 2009-03-04  Zdenek Dvorak  <ook@ucw.cz>
23125
23126         * graphite.c (nb_reductions_in_loop): Update simple_iv arguments.
23127
23128 2009-03-04  Richard Guenther  <rguenther@suse.de>
23129
23130         PR tree-optimization/39362
23131         * tree-ssa-sccvn.c (visit_use): Stores and copies from SSA_NAMEs
23132         that occur in abnormal PHIs should be varying.
23133
23134 2009-03-04  Zdenek Dvorak  <ook@ucw.cz>
23135
23136         * tree-scalar-evolution.c (analyze_scalar_evolution_in_loop):
23137         Extend comments.
23138         (simple_iv):  Take loop as an argument instead of statement.
23139         * tree-scalar-evolution.h (simple_iv): Declaration changed.
23140         * tree-ssa-loop-niter.c (number_of_iterations_exit): Update calls
23141         to simple_iv.
23142         * tree-ssa-loop-ivopts.c (determine_biv_step, find_givs_in_stmt_scev):
23143         Ditto.
23144         * tree-parloops.c (loop_parallel_p, canonicalize_loop_ivs): Ditto.
23145         * matrix-reorg.c (analyze_transpose): Ditto.
23146         * tree-data-ref.c (dr_analyze_innermost): Ditto.
23147         * tree-vect-analyze.c (vect_analyze_data_refs): Ditto.
23148         * tree-predcom.c (ref_at_iteration): Ditto.
23149         * tree-ssa-loop-prefetch.c (idx_analyze_ref): Ditto.
23150
23151 2009-03-04  Richard Guenther  <rguenther@suse.de>
23152
23153         PR tree-optimization/39358
23154         * tree-ssa-structalias.c (do_sd_constraint): Fix check for
23155         escaped_id and callused_id.
23156         (solve_graph): Likewise.
23157
23158 2009-03-04  Richard Guenther  <rguenther@suse.de>
23159
23160         PR tree-optimization/39339
23161         * tree-sra.c (try_instantiate_multiple_fields): Make it
23162         no longer ICE on the above.
23163
23164 2009-03-03  Joseph Myers  <joseph@codesourcery.com>
23165
23166         * emit-rtl.c (adjust_address_1): Reduce offset to a signed value
23167         that fits within Pmode.
23168
23169 2009-03-03  Steve Ellcey  <sje@cup.hp.com>
23170
23171         PR middle-end/10109
23172         * tm.texi (LIBCALL_VALUE): Update description.
23173
23174 2009-03-03  Steve Ellcey  <sje@cup.hp.com>
23175
23176         PR middle-end/34443
23177         * doc/extend.texi (section): Update description.
23178
23179 2009-03-03  H.J. Lu  <hongjiu.lu@intel.com>
23180
23181         PR middle-end/39345
23182         * tree-inline.c (remapped_type): New.
23183         (can_be_nonlocal): Call remapped_type instead of remap_type.
23184
23185 2009-03-03  Jakub Jelinek  <jakub@redhat.com>
23186
23187         PR fortran/39354
23188         * gimplify.c (goa_stabilize_expr): Handle tcc_comparison,
23189         TRUTH_ANDIF_EXPR and TRUTH_ORIF_EXPR.
23190
23191 2009-03-03  Richard Guenther  <rguenther@suse.de>
23192
23193         PR middle-end/39272
23194         * tree.c (tree_nonartificial_location): New function.
23195         * tree.h (tree_nonartificial_location): Declare.
23196         * builtins.c (expand_builtin_memory_chk): Provide location
23197         of the call location for artificial function pieces.
23198         (maybe_emit_chk_warning): Likewise.
23199         (maybe_emit_sprintf_chk_warning): Likewise.
23200         (maybe_emit_free_warning): Likewise.
23201         * expr.c (expand_expr_real_1): Likewise.
23202
23203 2009-03-03  Jakub Jelinek  <jakub@redhat.com>
23204
23205         PR tree-optimization/39343
23206         * tree-ssa-ccp.c (maybe_fold_offset_to_address): Don't check if
23207         COMPONENT_REF t has ARRAY_TYPE.
23208
23209 2009-03-02  Sebastian Pop  <sebastian.pop@amd.com>
23210
23211         PR middle-end/39335
23212         * tree-parloops.c (canonicalize_loop_ivs): Call fold_convert
23213         when the type precision of the induction variable should be
23214         larger than the type precision of nit.
23215         (gen_parallel_loop): Update use of canonicalize_loop_ivs.
23216         * graphite.c (graphite_loop_normal_form): Same.
23217         * tree-flow.h (canonicalize_loop_ivs): Update declaration.
23218
23219 2009-03-02  Uros Bizjak  <ubizjak@gmail.com>
23220
23221         * config/i386/i386.md (ST?_REG, MM?_REG): New constants.
23222         (*call_1_rex64_ms_sysv): Use named constants instead of magic
23223         numbers to describe clobbered registers.
23224         (*call_value_0_rex64_ms_sysv): Ditto.
23225         * config/i386/mmx.md (mmx_emms): Ditto.
23226         (mmx_femms): Ditto.
23227
23228 2009-03-02  Richard Sandiford  <rdsandiford@googlemail.com>
23229
23230         * config/mips/mips.c (mips_mdebug_abi_name): Fix the handling
23231         of ABI_64.
23232
23233 2009-03-02  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
23234
23235         * config/spu/spu.c (TARGET_SECTION_TYPE_FLAGS): Define.
23236         (spu_section_type_flags): New function.
23237
23238 2009-03-02  Uros Bizjak  <ubizjak@gmail.com>
23239
23240         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Do not copy
23241         reg_class_contents of FLOAT_REGS into a temporary.
23242
23243 2009-03-02  Richard Guenther  <rguenther@suse.de>
23244             Ira Rosen  <irar@il.ibm.com>
23245
23246         PR tree-optimization/39318
23247         * tree-vect-transform.c (vectorizable_call): Transfer the EH region
23248         information to the vectorized statement.
23249
23250 2009-03-01  Uros Bizjak  <ubizjak@gmail.com>
23251
23252         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Do not shadow "i"
23253         variable.  Use defined names instead of magic constants for REX SSE
23254         registers.
23255
23256 2009-03-01  Richard Guenther  <rguenther@suse.de>
23257
23258         PR tree-optimization/39331
23259         * omp-low.c (lower_send_shared_vars): Do not receive new
23260         values for the reference of DECL_BY_REFERENCE parms or results.
23261
23262 2009-03-01  Jan Hubicka  <jh@suse.cz>
23263
23264         PR debug/39267
23265         * tree.h (BLOCK_NONLOCALIZED_VARS, BLOCK_NUM_NONLOCALIZED_VARS,
23266         BLOCK_NONLOCALIZED_VAR): New macros.
23267         (tree_block): Add nonlocalized_vars.
23268         * dwarf2out.c (gen_formal_parameter_die, gen_variable_die,
23269         gen_decl_die): Add origin argument.  Allow generation of die with
23270         origin at hand only.
23271         (gen_member_die, gen_type_die_with_usage, force_decl_die,
23272         declare_in_namespace, gen_namescpace_die, dwarf2out_decl): Update use
23273         of gen_*.
23274         (gen_block_die): Fix checking for unused blocks.
23275         (process_scope_var): Break out from .... ; work with origins only.
23276         (decls_for_scope) ... here; process nonlocalized list.
23277         (dwarf2out_ignore_block): Look for nonlocalized vars.
23278         * tree-ssa-live.c (remove_unused_scope_block_p): Look for nonlocalized
23279         vars.
23280         (dump_scope_block): Dump them.
23281         * tree-inline.c (remap_decls): Handle nonlocalized vars.
23282         (remap_block): Likewise.
23283         (can_be_nonlocal): New predicate.
23284         (copy_bind_expr, copy_gimple_bind): Update use of remap_block.
23285
23286 2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
23287
23288         * configure: Regenerate.
23289
23290 2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
23291
23292         * optc-gen.awk: No need to duplicate option flags twice.
23293         Reuse help texts for duplicate options which do not have any.
23294
23295         * gcc.c (display_help): Document --version.
23296
23297         * gcc.c (main): If print_help_list and verbose_flag, ensure
23298         driver output comes before subprocess output.
23299
23300         * optc-gen.awk: Assign all remaining fields to help string,
23301         space-separated, for multi-line help in *.opt.
23302
23303         * doc/invoke.texi (Warning Options): -Wsync-nand is C/C++ only.
23304         -Wno-pedantic-ms-format is for MinGW targets only.
23305
23306         * doc/options.texi (Option file format): Fix bad indentation,
23307         restoring dropped sentence.
23308
23309 2009-02-28  Jan Hubicka  <jh@suse.cz>
23310
23311         * tree-inline.c (tree_function_versioning): Output debug info.
23312
23313 2009-02-28  Jan Hubicka  <jh@suse.cz>
23314
23315         PR debug/39267
23316         * tree-inline.c (setup_one_parameter): Do not copy propagate
23317         arguments when not optimizing.
23318
23319 2009-02-28  H.J. Lu  <hongjiu.lu@intel.com>
23320
23321         PR target/39327
23322         * config/i386/sse.md (avx_addsubv8sf3): Correct item bits.
23323         (avx_addsubv4df3): Likewise.
23324         (*avx_addsubv4sf3): Likewise.
23325         (sse3_addsubv4sf3): Likewise.
23326         (*avx_addsubv2df3): Likewise.
23327         (sse3_addsubv2df3): Likewise.
23328         (avx_unpckhps256): Correct item selectors.
23329         (avx_unpcklps256): Likewise.
23330         (avx_unpckhpd256): Likewise.
23331         (avx_unpcklpd256): Likewise.
23332
23333 2009-02-28  Jan Hubicka  <jh@suse.cz>
23334
23335         * tree-inline.c (expand_call_inline): Avoid duplicate declarations of
23336         static vars.
23337         (copy_arguments_for_versioning): If var is declared don't declare it.
23338         (tree_function_versioning): First setup substitutions and then copy
23339         args.
23340
23341 2009-02-27  Jan Hubicka  <jh@suse.cz>
23342
23343         PR debug/39267
23344         * cgraph.h (varpool_output_debug_info): Remove.
23345         * cgraphunit.c (varpool_output_debug_info): Remove.
23346         * dwarf2out.c (deferred_locations_struct): New struct
23347         (deferred_locations): New type.
23348         (deferred_locations_list): New static var.
23349         (deffer_location): New function.
23350         (gen_variable_die): Use it.
23351         (decls_for_scope): Output info on local static vars.
23352         (dwarf2out_finish): Process deferred locations.
23353         * varpool.c (varpool_output_debug_info): Remove.
23354
23355 2009-02-27  Jan Hubicka  <jh@suse.cz>
23356
23357         PR debug/39267
23358         * tree.h (TREE_PROTECTED): Fix comment.
23359         (BLOCK_HANDLER_BLOCK): Remove.
23360         (struct tree_block): Remove handler_block add body_block.
23361         (inlined_function_outer_scope_p): New.
23362         (is_body_block): Remove.
23363         * dbxout.c (dbxout_block): Remove BLOCK_HANDLER_BLOCK.
23364         * dwarf2out.c (is_inlined_entry_point): Remove.
23365         (add_high_low_attributes): Use inlined_function_outer_scope_p.
23366         (gen_block_die): Use is_inlined_entry_point check.  Remove body block
23367         code.
23368         * langhooks.h (struct lang_hooks): Remove no_bodu_blocks.
23369         * gimplify.c (gimplify_expr): Gimplify body blocks.
23370         * tree-ssa-live.c (remove_unused_scope_block_p): Allow removing wrapper
23371         block with multiple subblocks.
23372         (dump_scope_block): Prettier output; dump more flags and info.
23373         (dump_scope_blocks): New.
23374         (remove_unused_locals): Use dump_scope_blocks.
23375         * tree-flow.h (dump_scope_blocks): Declare.
23376         * tree-cfg.c (execute_build_cfg): Dump scope blocks.
23377         * stmt.c (is_body_block): Remove.
23378         * tree-inline.c (remap_block): Copy BODY_BLOCK info.
23379         * langhooks-def.h (LANG_HOOKS_NO_BODY_BLOCKS): Remove.
23380
23381 2009-02-27  Sebastian Pop  <sebastian.pop@amd.com>
23382
23383         PR middle-end/39308
23384         * graphite.c (graphite_loop_normal_form): Do not call
23385         number_of_iterations_exit from a gcc_assert.
23386
23387 2009-02-27  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
23388
23389         * config/s390/s390.c (s390_swap_cmp): Look for conditional
23390         jumps if COND is NULL.
23391         (find_cond_jump): New function.
23392         (s390_z10_optimize_cmp): Handling for reg-reg compares added.
23393         * config/s390/s390.md: Remove z10_cobra attribute value.
23394
23395 2009-02-26  Uros Bizjak  <ubizjak@gmail.com>
23396
23397         * config/alpha/alpha.h (alpha_expand_mov): Return false if
23398         force_const_mem returns NULL_RTX.
23399
23400 2009-02-26  Jan Hubicka  <jh@suse.cz>
23401
23402         PR debug/39267
23403         * cgraph.h (varpool_output_debug_info): Remove.
23404         * cgraphunit.c (varpool_output_debug_info): Remove.
23405         * dwarf2out.c (deferred_locations_struct): New struct
23406         (deferred_locations): New type.
23407         (deferred_locations_list): New static var.
23408         (deffer_location): New function.
23409         (gen_variable_die): Use it.
23410         (decls_for_scope): Output info on local static vars.
23411         (dwarf2out_finish): Process deferred locations.
23412         * varpool.c (varpool_output_debug_info): Remove.
23413
23414 2009-02-25  H.J. Lu  <hongjiu.lu@intel.com>
23415
23416         PR rtl-optimization/39241
23417         * jump.c (rtx_renumbered_equal_p): Remove 2 superfluous calls
23418         to subreg_offset_representable_p.
23419
23420 2009-02-25  Paolo Bonzini  <bonzini@gnu.org>
23421
23422         * regmove.c (regmove_optimize): Conform to struct rtl_opt_pass
23423         execute function prototype.  Get f and nregs from max_reg_num
23424         and get_insns.  Remove the first backward pass as it's dead,
23425         guard the forward pass by flag_expensive_optimizations.
23426         (rest_of_handle_regmove): Delete.
23427         (pass_regmove): Replace it with regmove_optimize.
23428
23429 2009-02-25  Martin Jambor  <mjambor@suse.cz>
23430
23431         PR tree-optimization/39259
23432         * tree-inline.c (initialize_cfun): Remove asserts for calls_setjmp and
23433         calls_alloca function flags.
23434         (copy_bb): Set calls_setjmp and alls_alloca function flags if such
23435         calls are detected.
23436
23437 2009-02-25  Paolo Bonzini  <bonzini@gnu.org>
23438
23439         * regmove.c (discover_flags_reg, flags_set_1, mark_flags_life_zones,
23440         flags_set_1_rtx, flags_set_1_set): Delete.
23441         (regmove_optimize): Do not call mark_flags_life_zones.
23442
23443 2009-02-24  Julian Brown  <julian@codesourcery.com>
23444
23445         PR target/35965
23446         * config/arm/arm.c (require_pic_register): Only set
23447         cfun->machine->pic_reg once per function.
23448
23449 2009-02-24  Sandra Loosemore  <sandra@codesourcery.com>
23450
23451         * doc/invoke.texi (Link Options): Document an easier way to pass
23452         options that take arguments to the GNU linker using -Xlinker and -Wl.
23453
23454 2009-02-24  Steve Ellcey  <sje@cup.hp.com>
23455
23456         PR target/33785
23457         * doc/tm.texi (TARGET_C99_FUNCTIONS): Fix description.
23458
23459 2009-02-24  Richard Guenther  <rguenther@suse.de>
23460
23461         PR debug/39285
23462         * dwarf2out.c (gen_enumeration_type_die): Handle CONST_DECLs.
23463
23464 2009-02-24  Richard Guenther  <rguenther@suse.de>
23465             Zdenek Dvorak  <ook@ucw.cz>
23466
23467         PR tree-optimization/39233
23468         * tree-ssa-loop-ivopts.c (add_candidate_1): Do not except pointers
23469         from converting them to a generic type.
23470
23471 2009-02-23  Sebastian Pop  <sebastian.pop@amd.com>
23472
23473         PR tree-optimization/39260
23474         * graphite.c (harmful_stmt_in_bb): Stop a SCoP when the basic block
23475         contains a condition with a real type.
23476         (build_scop_conditions_1): Conditions are always last_stmt of a bb.
23477
23478 2009-02-23  Jason Merrill  <jason@redhat.com>
23479
23480         PR c++/38880
23481         * varasm.c (initializer_constant_valid_p) [PLUS_EXPR]: Check
23482         narrowing_initializer_constant_valid_p.
23483         (narrowing_initializer_constant_valid_p): Don't return
23484         null_pointer_node for adding a pointer to itself.
23485
23486 2009-02-23  Jan Hubicka  <jh@suse.cz>
23487
23488         PR c/12245
23489         * ggc.h (htab_create_ggc): Use ggc_free to free hashtable when
23490         resizing.
23491
23492 2009-02-23  Jan Hubicka  <jh@suse.cz>
23493
23494         PR tree-optimization/37709
23495         * tree.c (block_ultimate_origin): Move here from dwarf2out.
23496         * tree.h (block_ultimate_origin): Declare.
23497         * dwarf2out.c (block_ultimate_origin): Move to tree.c
23498         * tree-ssa-live.c (remove_unused_scope_block_p):
23499         Eliminate blocks containig no instructions nor live variables nor
23500         nested blocks.
23501         (dump_scope_block): New function.
23502         (remove_unused_locals): Enable removal of dead blocks by default;
23503         enable dumping at TDF_DETAILS.
23504
23505 2009-02-21  H.J. Lu  <hongjiu.lu@intel.com>
23506
23507         * config/i386/i386.c (classify_argument): Don't allow COImode
23508         and OImode.
23509         (function_arg_advance_32): Don't allow OImode.
23510         (function_arg_32): Likewise.
23511         (function_value_32): Likewise.
23512         (return_in_memory_32): Likewise.
23513         (function_arg_64): Remove OImode comment.
23514
23515 2009-02-21  H.J. Lu  <hongjiu.lu@intel.com>
23516
23517         PR target/39261
23518         * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): Use
23519         ix86_expand_vector_set for V4DImode in 64bit mode only.
23520         (ix86_expand_vector_init_one_var): Likewise.
23521
23522 2009-02-21  Sebastian Pop  <sebastian.pop@amd.com>
23523
23524         * graphite.c (graphite_trans_loop_block): Adjust tile size to 51.
23525
23526 2009-02-21  Richard Sandiford  <rdsandiford@googlemail.com>
23527
23528         PR bootstrap/39257
23529         * loop-iv.c: Revert last change.
23530         * emit-rtl.c: Likewise.
23531
23532 2009-02-21  H.J. Lu  <hongjiu.lu@intel.com>
23533
23534         PR target/39256
23535         * config/i386/i386.c (type_natural_mode): Remove an extra
23536         space in the warning message.
23537         (function_value_32): Handle 32-byte vector modes.
23538         (return_in_memory_32): Likewise.
23539
23540 2009-02-21  Richard Sandiford  <rdsandiford@googlemail.com>
23541
23542         * loop-iv.c (truncate_value): New function.
23543         (iv_subreg, get_iv_value, iv_number_of_iterations): Use it instead
23544         of lowpart_subreg.
23545         (lowpart_subreg): Move to...
23546         * emit-rtl.c: ...here.
23547
23548 2009-02-21  Danny Smith  <dannysmith@users.sourceforge.net>
23549
23550         * config/i386/winnt.c (i386_pe_asm_output_aligned_decl_common): Revert
23551         accidental and undocumented change at revision 140860.
23552
23553 2009-02-21  Joseph Myers  <joseph@codesourcery.com>
23554
23555         * config/arm/arm.c (arm_gimplify_va_arg_expr): Update prototype to
23556         take gimple_seq * arguments.
23557         (arm_mangle_type): Use CONST_CAST_TREE on type argument passed to
23558         types_compatible_p langhook.
23559
23560 2009-02-20  Mark Mitchell  <mark@codesourcery.com>
23561             Joseph Myers  <joseph@codesourcery.com>
23562
23563         * config/arm/arm.c (arm_builtin_va_list): New function.
23564         (arm_expand_builtin_va_start): Likewise.
23565         (arm_gimplify_va_arg_expr): Likewise.
23566         (TARGET_BUILD_BUILTIN_VA_LIST): Define.
23567         (TARGET_BUILD_BUILTIN_VA_START): Likewise.
23568         (TARGET_BUILD_BUILTIN_VA_ARG_EXPR): Likewise.
23569         (va_list_type): New variable.
23570         (arm_mangle_type): Mangle va_list_type appropriately.
23571
23572 2009-02-20  Jakub Jelinek  <jakub@redhat.com>
23573
23574         PR middle-end/39157
23575         * Makefile.in (loop-invariant.o): Depend on $(PARAMS_H).
23576         * params.h (LOOP_INVARIANT_MAX_BBS_IN_LOOP): Define.
23577         * params.def (loop-invariant-max-bbs-in-loop): New parameter.
23578         * opts.c (decode_options): Set loop-invariant-max-bbs-in-loop
23579         parameter to 1000 for -O1 by default.
23580         * doc/invoke.texi (loop-invariant-max-bbs-in-loop): Document new
23581         parameter.
23582         * loop-invariant.c: Include params.h.
23583         (move_loop_invariants): Don't call move_single_loop_invariants on
23584         very large loops.
23585
23586 2009-02-20  Jaka Mocnik  <jaka@xlab.si>
23587
23588         * calls.c (emit_library_call_value_1): Use slot_offset instead of
23589         offset when calculating bounds for indexing stack_usage_map.  Fixes
23590         a buffer overflow with certain target setups.
23591
23592 2009-02-20  Jakub Jelinek  <jakub@redhat.com>
23593
23594         PR target/39240
23595         * calls.c (expand_call): Clear try_tail_call if caller and callee
23596         disagree in promotion of function return value.
23597
23598 2009-02-19  Jakub Jelinek  <jakub@redhat.com>
23599
23600         PR target/39175
23601         * c-common.c (c_determine_visibility): If visibility changed and
23602         DECL_RTL has been already set, call make_decl_rtl to update symbol
23603         flags.
23604
23605 2009-02-19  H.J. Lu  <hongjiu.lu@intel.com>
23606
23607         PR c++/39188
23608         * varasm.c (assemble_variable): Don't check DECL_NAME when
23609         globalizing a variable.
23610
23611 2009-02-19  Joseph Myers  <joseph@codesourcery.com>
23612
23613         PR c/38483
23614         * builtins.c (gimplify_va_arg_expr): Evaluate the va_list
23615         expression before any __builtin_trap call.
23616         * c-typeck.c (build_function_call): Convert and check function
23617         arguments before generating a call to a trap.  Evaluate the
23618         function arguments before the trap.
23619
23620 2009-02-19  Uros Bizjak  <ubizjak@gmail.com>
23621
23622         PR target/39228
23623         * config/i386/i386.md (isinfxf2): Split from isinf<mode>2.
23624         (UNSPEC_FXAM_MEM): New unspec.
23625         (fxam<mode>2_i387_with_temp): New insn and split pattern.
23626         (isinf<mode>2): Use MODEF mode iterator.  Force operand[1] through
23627         memory using fxam<mode>2_i387_with_temp to remove excess precision.
23628
23629 2009-02-19  Richard Guenther  <rguenther@suse.de>
23630
23631         PR tree-optimization/39207
23632         PR tree-optimization/39074
23633         * tree-ssa-structalias.c (storedanything_id, var_storedanything,
23634         storedanything_tree): New.
23635         (do_ds_constraint): Simplify ANYTHING shortcutting.  Update
23636         the STOREDANYTHING solution if the lhs solution contains ANYTHING.
23637         (build_succ_graph): Add edges from STOREDANYTHING to all
23638         non-direct nodes.
23639         (init_base_vars): Initialize STOREDANYTHING.
23640         (compute_points_to_sets): Free substitution info after
23641         building the succ graph.
23642         (ipa_pta_execute): Likewise.
23643
23644         * tree-ssa-structalias.c (struct variable_info): Add may_have_pointers
23645         field.
23646         (do_ds_constraint): Do not add to special var or non-pointer
23647         field solutions.
23648         (type_could_have_pointers): Split out from ...
23649         (could_have_pointers): ... here.  For arrays use the element type.
23650         (create_variable_info_for): Initialize may_have_pointers.
23651         (new_var_info): Likewise.
23652         (handle_lhs_call): Make the HEAP variable unknown-sized.
23653         (intra_create_variable_infos): Use a type with pointers for
23654         PARM_NOALIAS, make it unknown-sized.
23655
23656 2009-02-18  H.J. Lu  <hongjiu.lu@intel.com>
23657
23658         PR target/39224
23659         * config/i386/i386.c (ix86_return_in_memory): Properly check ABI.
23660
23661 2009-02-18  Jason Merrill  <jason@redhat.com>
23662
23663         PR target/39179
23664         * tree-ssa-ccp.c (get_symbol_constant_value): Don't assume zero
23665         value if DECL_EXTERNAL.
23666         * tree-sra.c (sra_walk_gimple_assign): Likewise.
23667         * target.h (gcc_target::binds_local_p): Clarify "module".
23668         * tree.h (TREE_PUBLIC): Clarify "module".
23669
23670 2009-02-17  Xuepeng Guo  <xuepeng.guo@intel.com>
23671
23672         PR target/38891
23673         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Move the hunk of
23674         initialization for MS_ABI prior to the hunk of !TARGET_MMX.
23675
23676 2009-02-17  H.J. Lu  <hongjiu.lu@intel.com>
23677
23678         PR target/39082
23679         * c.opt (Wabi): Support C and ObjC.
23680         (Wpsabi): New.
23681
23682         * c-opts.c (c_common_handle_option): Handle OPT_Wabi.
23683
23684         * config/i386/i386.c (classify_argument): Warn once about the ABI
23685         change when passing union with long double.
23686
23687         * doc/invoke.texi: Update -Wabi for warning psABI changes.
23688
23689 2009-02-18  Joseph Myers  <joseph@codesourcery.com>
23690
23691         PR c/35447
23692         * c-parser.c (c_parser_compound_statement): Always enter and leave
23693         a scope.
23694
23695 2009-02-17  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
23696
23697         PR target/34587
23698         * config/darwin.h (SUPPORTS_INIT_PRIORITY): Define.
23699
23700 2009-02-18  Jakub Jelinek  <jakub@redhat.com>
23701
23702         PR tree-optimization/36922
23703         * tree-data-ref.c (initialize_matrix_A): Handle BIT_NOT_EXPR.
23704         * tree-scalar-evolution.c (interpret_rhs_expr, instantiate_scev_1):
23705         Likewise.
23706
23707 2009-02-17  Richard Sandiford  <rdsandiford@googlemail.com>
23708
23709         * config/mips/mips.c (mips_override_options): Set flag_dwarf2_cfi_asm
23710         to 0 for EABI64.
23711
23712 2009-02-17  Richard Sandiford  <rdsandiford@googlemail.com>
23713
23714         * config/mips/mips.md (type): Reclassify lui_movf as "unknown".
23715
23716 2009-02-17  Richard Sandiford  <rdsandiford@googlemail.com>
23717
23718         * config/mips/mips.c (mips_gimplify_va_arg_expr): Fix invalid
23719         tree sharing.
23720
23721 2009-02-17  Ruan Beihong  <ruanbeihong@gmail.com>
23722             Richard Sandiford  <rdsandiford@googlemail.com>
23723
23724         * config/mips/mips.c (CODE_FOR_loongson_biadd): Delete.
23725         * config/mips/loongson.md (reduc_uplus_<mode>): Rename to...
23726         (loongson_biadd): ...this.
23727
23728 2009-02-17  Richard Guenther  <rguenther@suse.de>
23729
23730         PR tree-optimization/39202
23731         * tree-ssa-structalias.c (do_structure_copy): Before collapsing
23732         a var make sure to follow existing collapses.
23733
23734 2009-02-17  Richard Guenther  <rguenther@suse.de>
23735
23736         PR middle-end/39214
23737         * langhooks.c (lhd_print_error_function): Check for NULL block.
23738
23739 2009-02-17  Richard Guenther  <rguenther@suse.de>
23740
23741         PR tree-optimization/39204
23742         * tree-ssa-pre.c (phi_translate_1): Lookup the value-number
23743         of the PHI arg.
23744
23745 2009-02-17  Uros Bizjak  <ubizjak@gmail.com>
23746
23747         * config/soft-fp/double.h: Update from glibc CVS.
23748
23749 2009-02-17  Richard Guenther  <rguenther@suse.de>
23750
23751         PR tree-optimization/39207
23752         * tree-ssa-structalias.c (find_what_p_points_to): Do not emit
23753         strict-aliasing warnings for pointers pointing to NULL.
23754
23755 2009-02-16  Joseph Myers  <joseph@codesourcery.com>
23756
23757         PR c/35446
23758         * c-parser.c (c_parser_braced_init): Call pop_init_level when
23759         skipping until next close brace.
23760
23761 2009-02-16  H.J. Lu  <hongjiu.lu@intel.com>
23762
23763         PR target/37049
23764         * config/i386/i386.c (ix86_expand_push): Set memory alignment
23765         to function argument boundary.
23766
23767 2009-02-16  Hariharan Sandanagobalane  <hariharan@picochip.com>
23768
23769         * config/picochip/picochip.md (lea_add): Allow any nonimmediate
23770         in the lea_add. Reload eventually constraints it properly.
23771         * config/picochip/constraints.md: Remove the target constraint
23772         "b", since it is not needed anymore.
23773
23774 2009-02-16  Jakub Jelinek  <jakub@redhat.com>
23775
23776         * gthr-dce.h: Uglify function parameter and local variable names.
23777         * gthr-gnat.h: Likewise.
23778         * gthr-mipssde.h: Likewise.
23779         * gthr-nks.h: Likewise.
23780         * gthr-posix95.h: Likewise.
23781         * gthr-posix.h: Likewise.
23782         * gthr-rtems.h: Likewise.
23783         * gthr-single.h: Likewise.
23784         * gthr-solaris.h: Likewise.
23785         * gthr-tpf.h: Likewise.
23786         * gthr-vxworks.h: Likewise.
23787         * gthr-win32.h: Likewise.
23788
23789 2009-02-15  H.J. Lu  <hongjiu.lu@intel.com>
23790
23791         PR target/39196
23792         * config/i386/i386.md: Restrict the new peephole2 to move
23793         between MMX/SSE registers.
23794
23795 2009-02-15  Richard Guenther  <rguenther@suse.de>
23796
23797         Revert
23798         2009-02-13  Richard Guenther  <rguenther@suse.de>
23799
23800         * configure.ac: Enable LFS.
23801         * configure: Re-generate.
23802         * config.in: Likewise.
23803
23804 2009-02-13  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
23805
23806         * config/spu/spu_internals.h (spu_sr, spu_sra, spu_srqw,
23807         spu_srqwbyte, spu_srqwbytebc): Define.
23808         * config/spu/spu-builtins.def (spu_sr, spu_sra, spu_srqw,
23809         spu_srqwbyte, spu_srqwbytebc): New overloaded builtins.
23810         * config/spu/spu.md ("shrqbybi_<mode>", "shrqbi_<mode>",
23811         "shrqby_<mode>"): New insn-and-split patterns.
23812         * config/spu/spu.c (expand_builtin_args): Determine and return
23813         number of operands using spu_builtin_description data.
23814         (spu_expand_builtin_1): Use it.
23815
23816 2009-02-13  Steve Ellcey  <sje@cup.hp.com>
23817
23818         PR target/38056
23819         * config/ia64/ia64.c (ia64_function_ok_for_sibcall): Check
23820         TARGET_CONST_GP.
23821
23822 2009-02-13  H.J. Lu  <hongjiu.lu@intel.com>
23823
23824         PR target/39149
23825         * config/i386/i386.c (override_options): Correct warning
23826         messages for -malign-loops, -malign-jumps and -malign-functions.
23827
23828 2009-02-13  H.J. Lu  <hongjiu.lu@intel.com>
23829
23830         PR target/39152
23831         * config/i386/i386.md: Restrict the new peephole2 to move
23832         between the general purpose registers.
23833
23834 2009-02-13  H.J. Lu  <hongjiu.lu@intel.com>
23835
23836         PR target/39162
23837         * config/i386/i386.c (type_natural_mode): Add a new argument.
23838         Return the original mode and warn ABI change if vector size is 32byte.
23839         (function_arg_advance): Updated.
23840         (function_arg): Likewise.
23841         (ix86_function_value): Likewise.
23842         (ix86_return_in_memory): Likewise.
23843         (ix86_sol10_return_in_memory): Likewise.
23844         (ix86_gimplify_va_arg): Likewise.
23845         (function_arg_32): Don't warn ABX ABI change here.
23846         (function_arg_64): Likewise.
23847
23848 2009-02-13  Bernd Schmidt  <bernd.schmidt@analog.com>
23849
23850         * loop-iv.c (implies_p): In the final case, test that operands 0
23851         of the two comparisons match.
23852
23853         * config/bfin/bfin.c (find_prev_insn_start): New function.
23854         (bfin_optimize_loop): Use it in some cases instead of PREV_INSN.
23855         (find_next_insn_start): Move.
23856
23857 2009-02-13  Richard Guenther  <rguenther@suse.de>
23858
23859         * configure.ac: Enable LFS.
23860         * configure: Re-generate.
23861         * config.in: Likewise.
23862
23863 2009-02-13  Joseph Myers  <joseph@codesourcery.com>
23864
23865         PR c/35444
23866         * c-parser.c (c_parser_parms_list_declarator): Discard pending
23867         sizes on syntax error after some arguments have been parsed.
23868
23869 2009-02-12  Jakub Jelinek  <jakub@redhat.com>
23870
23871         * doc/invoke.texi (-fira): Remove.
23872
23873 2009-02-12  H.J. Lu  <hongjiu.lu@intel.com>
23874
23875         * caller-save.c: Replace regclass.c with reginfo.c in comments.
23876         * recog.c: Likewise.
23877         * rtl.h: Likewise.
23878
23879 2009-02-12  Uros Bizjak  <ubizjak@gmail.com>
23880
23881         * longlong.h (sub_ddmmss): New for ia64. Ported from GMP 4.2.
23882         (umul_ppmm): Likewise.
23883         (count_leading_zeros): Likewise.
23884         (count_trailing_zeros): Likewise.
23885         (UMUL_TIME): Likewise.
23886
23887 2009-02-12  H.J. Lu  <hongjiu.lu@intel.com>
23888
23889         * config.gcc (ia64*-*-linux*): Add ia64/t-fprules-softfp and
23890         soft-fp/t-softfp to tmake_file.
23891
23892         * config/ia64/ia64.c (ia64_soft_fp_init_libfuncs): New.
23893         (ia64_expand_compare): Use HPUX library for TFmode only for HPUX.
23894         (ia64_builtins) [IA64_BUILTIN_COPYSIGNQ, IA64_BUILTIN_FABSQ,
23895         IA64_BUILTIN_INFQ]: New.
23896         (ia64_init_builtins): Initialize __builtin_infq,
23897         __builtin_fabsq and __builtin_copysignq if not HPUX.
23898         (ia64_expand_builtin): Handle IA64_BUILTIN_COPYSIGNQ,
23899         IA64_BUILTIN_FABSQ and IA64_BUILTIN_INFQ.
23900
23901         * config/ia64/lib1funcs.asm (__divtf3): Define only if
23902         SHARED is defined.
23903         (__fixtfti): Likewise.
23904         (__fixunstfti): Likewise.
23905         (__floattitf): Likewise.
23906
23907         * config/ia64/libgcc-glibc.ver: New.
23908         * config/ia64/t-fprules-softfp: Likewise.
23909         * config/ia64/sfp-machine.h: Likewise.
23910
23911         * config/ia64/linux.h (LIBGCC2_HAS_TF_MODE): New.
23912         (LIBGCC2_TF_CEXT): Likewise.
23913         (TF_SIZE): Likewise.
23914         (TARGET_INIT_LIBFUNCS): Likewise.
23915
23916         * config/ia64/t-glibc (SHLINB_MAPFILES):
23917         Add $(srcdir)/config/ia64/libgcc-glibc.ver.
23918
23919 2009-02-12  H.J. Lu  <hongjiu.lu@intel.com>
23920
23921         * config/i386/i386.c (construct_container): Rewrite processing
23922         BLKmode with X86_64_SSE_CLASS.
23923
23924 2009-02-12  Paolo Bonzini  <bonzini@gnu.org>
23925
23926         PR target/39152
23927         * config/i386/i386.md: Replace simplify_replace_rtx with
23928         replace_rtx in the new peephole2.
23929
23930 2009-02-12  Nathan Sidwell  <nathan@codesourcery.com>
23931
23932         * doc/invoke.texi (Optimize Options): Stop claiming inlining and
23933         loop unrolling do not happen at -O2.
23934
23935 2009-02-12  Michael Matz  <matz@suse.de>
23936
23937         * gcc.c (ASM_DEBUG_SPEC): Check for -g0.
23938
23939 2009-02-12  Jakub Jelinek  <jakub@redhat.com>
23940
23941         * dwarf2out.c (dwarf2out_finish): Force output of comp_unit_die
23942         for -g3.
23943
23944 2009-02-12  Ben Elliston  <bje@au.ibm.com>
23945
23946         * config/rs6000/rs6000.md (allocate_stack): Use _stack form of
23947         patterns when updating the back chain.  Missed in the 2009-02-10
23948         change.
23949
23950 2009-02-11  Janis Johnson  <janis187@us.ibm.com>
23951
23952         * doc/extend.texi (Decimal Floating Types): Update identifier of
23953         draft TR and list of missing support.
23954
23955 2009-02-11  Jakub Jelinek  <jakub@redhat.com>
23956
23957         PR middle-end/39154
23958         * gimplify.c (omp_notice_variable): If adding GOVD_SEEN
23959         bit to variable length decl's flags, add it also to its
23960         pointer replacement variable.
23961
23962 2009-02-11  Uros Bizjak  <ubizjak@gmail.com>
23963             Jakub Jelinek  <jakub@redhat.com>
23964
23965         PR target/39118
23966         * config/i386/i386.md (UNSPEC_MEMORY_BLOCKAGE): New constant.
23967         (memory_blockage): New expander.
23968         (*memory_blockage): New insn pattern.
23969         * config/i386/i386.c (ix86_expand_prologue): Use memory_blockage
23970         instead of general blockage at the end of function prologue when
23971         frame pointer is used to access red zone area.  Do not emit blockage
23972         when profiling, it is emitted in generic code.
23973         (ix86_expand_epilogue): Emit memory_blockage at the beginning of
23974         function epilogue when frame pointer is used to access red zone area.
23975
23976 2009-02-11  Paolo Bonzini  <bonzini@gnu.org>
23977
23978         PR target/38824
23979         * config/i386/i386.md: Add two new peephole2 to avoid mov followed
23980         by arithmetic with memory operands.
23981         * config/i386/predicates.md (commutative_operator): New.
23982
23983 2009-02-10  Janis Johnson  <janis187@us.ibm.com>
23984
23985         * doc/extend.texi (Fixed-Point Types): Break long paragraphs into
23986         bulleted lists.
23987
23988 2009-02-10  Eric Botcazou  <ebotcazou@adacore.com>
23989
23990         * alias.h (record_alias_subset): Declare.
23991         * alias.c (record_alias_subset): Make global.
23992
23993 2009-02-10  Nick Clifton  <nickc@redhat.com>
23994
23995         * tree-parloops.c: Change license to GPLv3.
23996         * ipa-struct-reorg.c: Change license to GPLv3.
23997         * ipa-struct-reorg.h: Change license to GPLv3.
23998
23999 2009-02-10  Steve Ellcey  <sje@cup.hp.com>
24000
24001         PR c/39084
24002         * c-decl.c (start_struct): Return NULL on error.
24003
24004 2009-02-10  Jakub Jelinek  <jakub@redhat.com>
24005
24006         PR middle-end/39124
24007         * cfgloopmanip.c (remove_path): Call remove_bbs after
24008         cancel_loop_tree, not before it.
24009
24010         PR target/39139
24011         * function.h (struct function): Add has_local_explicit_reg_vars bit.
24012         * gimplify.c (gimplify_bind_expr): Set it if local DECL_HARD_REGISTER
24013         VAR_DECLs were seen.
24014         * tree-ssa-live.c (remove_unused_locals): Recompute
24015         cfun->has_local_explicit_reg_vars.
24016         * tree-ssa-sink.c (statement_sink_location): Don't sink BLKmode
24017         copies or clearings if cfun->has_local_explicit_reg_vars.
24018
24019 2009-02-10  Uros Bizjak  <ubizjak@gmail.com>
24020
24021         PR target/39118
24022         * config/i386/i386.c (expand_prologue): Emit blockage at the end
24023         of function prologue when frame pointer is used to access
24024         red zone area.
24025
24026 2009-02-10  Richard Guenther  <rguenther@suse.de>
24027
24028         PR middle-end/39127
24029         * gimplify.c (gimple_regimplify_operands): Always look if
24030         we need to create a temporary.
24031
24032 2009-02-10  Richard Guenther  <rguenther@suse.de>
24033
24034         PR tree-optimization/39132
24035         * tree-loop-distribution.c (todo): New global var.
24036         (generate_memset_zero): Trigger TODO_rebuild_alias.
24037         (tree_loop_distribution): Return todo.
24038
24039 2009-02-10  H.J. Lu  <hongjiu.lu@intel.com>
24040
24041         PR target/39119
24042         * config/i386/i386.c (x86_64_reg_class): Remove X86_64_AVX_CLASS.
24043         (x86_64_reg_class_name): Removed.
24044         (classify_argument): Return 0 if bytes > 32.  Return 0 if the
24045         first one isn't X86_64_SSE_CLASS or any other ones aren't
24046         X86_64_SSEUP_CLASS when size > 16bytes.  Don't turn
24047         X86_64_SSEUP_CLASS into X86_64_SSE_CLASS if the preceded one
24048         is X86_64_SSEUP_CLASS.  Set AVX modes to 1 X86_64_SSE_CLASS
24049         and 3 X86_64_SSEUP_CLASS.
24050         (construct_container): Remove X86_64_AVX_CLASS.  Handle 4
24051         registers with 1 X86_64_SSE_CLASS and 3 X86_64_SSEUP_CLASS.
24052
24053 2009-02-10  Ben Elliston  <bje@au.ibm.com>
24054
24055         * config/rs6000/rs6000.md (allocate_stack): Always use an update
24056         form instruction to update the stack back chain word, even if the
24057         user has disabled the generation of update instructions.
24058         (movdi_<mode>_update_stack): New.
24059         (movsi_update_stack): Likewise.
24060         * config/rs6000/rs6000.c (rs6000_emit_allocate_stack): Likewise,
24061         always use an update form instruction to update the stack back
24062         chain word.
24063
24064 2009-02-09  Sebastian Pop  <sebastian.pop@amd.com>
24065
24066         PR middle-end/38953
24067         * graphite.c (if_region_set_false_region): After moving a region in
24068         the false branch of a condition, remove the empty dummy basic block.
24069         (gloog): Remove wrong fix for PR38953.
24070
24071 2009-02-09  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
24072
24073         * config/spu/spu.c (array_to_constant): Fix (latent) wrong-code
24074         generation due to implicit sign extension.
24075
24076 2009-02-09  Eric Botcazou  <ebotcazou@adacore.com>
24077
24078         PR middle-end/38981
24079         * tree-ssa-coalesce.c (add_coalesce): Cap the costs of coalesce pairs
24080         at MUST_COALESCE_COST-1 instead of MUST_COALESCE_COST.
24081
24082 2009-02-09  Richard Guenther  <rguenther@suse.de>
24083
24084         PR middle-end/35202
24085         * convert.c (convert_to_real): Disable (float)fn((double)x)
24086         to fnf(x) conversion if errno differences may occur and
24087         -fmath-errno is set.
24088
24089 2009-02-07  Anatoly Sokolov  <aesok@post.ru>
24090
24091         * config/avr/avr.c (avr_mcu_t): Add ata6289 device.
24092         * config/avr/avr.h (LINK_SPEC, CRT_BINUTILS_SPECS): (Ditto.).
24093         * config/avr/t-avr (MULTILIB_MATCHES): (Ditto.).
24094
24095 2009-02-06  Joseph Myers  <joseph@codesourcery.com>
24096
24097         PR c/35434
24098         * c-common.c (handle_alias_attribute): Disallow attribute for
24099         anything not a FUNCTION_DECL or VAR_DECL.
24100
24101 2009-02-06  Janis Johnson  <janis187@us.ibm.com>
24102
24103         PR c/39035
24104         * real.c (do_compare): Special-case compare of zero against
24105         decimal float value.
24106
24107 2009-02-06  Joseph Myers  <joseph@codesourcery.com>
24108
24109         PR c/36432
24110         * c-decl.c (grokdeclarator): Don't treat [] declarators in fields
24111         as indicating flexible array members unless the field itself is
24112         being declarared as the incomplete array.
24113
24114 2009-02-06  Jan Hubicka  <jh@suse.cz>
24115
24116         PR tree-optimization/38844
24117         * ipa-inline.c (try_inline): Stop inlining recursion when edge
24118         is already inlined.
24119
24120 2009-02-06  Richard Guenther  <rguenther@suse.de>
24121
24122         PR middle-end/38977
24123         * tree-cfg.c (need_fake_edge_p): Force a fake edge for
24124         fork because we may expand it as __gcov_fork.
24125
24126 2009-02-06  Nick Clifton  <nickc@redhat.com>
24127
24128         * config/m32c/m32c.h (PCC_BITFIELD_TYPE_MATTERS): Define to zero.
24129
24130 2009-02-06  Paolo Bonzini  <bonzini@gnu.org>
24131
24132         PR tree-optimization/35659
24133         * tree-ssa-sccvn.c (vn_constant_eq, vn_reference_eq, vn_nary_op_eq
24134         vn_phi_eq): Shortcut if hashcode does not match.
24135         (vn_reference_op_compute_hash): Do not call iterative_hash_expr for
24136         NULL operands.
24137         * tree-ssa-pre.c (pre_expr_hash): Look at hashcode if available,
24138         and avoid iterative_hash_expr.
24139         (FOR_EACH_VALUE_ID_IN_SET): New.
24140         (value_id_compare): Remove.
24141         (sorted_array_from_bitmap_set): Use FOR_EACH_VALUE_ID_IN_SET to
24142         sort expressions by value id.
24143
24144 2009-02-05  Kaz Kojima  <kkojima@gcc.gnu.org>
24145
24146         PR target/38991
24147         * config/sh/predicates.md (general_movsrc_operand): Don't check
24148         the subreg of system registers here.
24149
24150 2009-02-05  Jakub Jelinek  <jakub@redhat.com>
24151
24152         PR c++/39106
24153         * cgraphunit.c (cgraph_function_versioning): Clear also DECL_VIRTUAL_P
24154         on the copied decl.
24155
24156 2009-02-05  Paolo Bonzini  <bonzini@gnu.org>
24157
24158         PR rtl-optimization/39110
24159         * rtlanal.c (rtx_addr_can_trap_p_1): Shortcut unaligned
24160         addresses, not aligned ones.
24161
24162 2009-02-05  Daniel Berlin  <dberlin@dberlin.org>
24163             Richard Guenther  <rguenther@suse.de>
24164
24165         PR tree-optimization/39100
24166         * tree-ssa-structalias.c (do_ds_constraint): Actually do what the
24167         comment says and add edges.
24168
24169 2009-02-05  Joseph Myers  <joseph@codesourcery.com>
24170
24171         PR c/35435
24172         * c-common.c (handle_tls_model_attribute): Ignore attribute for
24173         non-VAR_DECLs without checking DECL_THREAD_LOCAL_P.
24174
24175 2009-02-04  Tobias Grosser  <grosser@fim.uni-passau.de>
24176
24177         * graphite.c (bb_in_sese_p, sese_build_livein_liveouts_use,
24178         sese_build_livein_liveouts_bb, sese_build_livein_liveouts,
24179         register_bb_in_sese, new_sese, free_sese): Moved.
24180         (dot_scop_1, build_scop_loop_nests, build_loop_iteration_domains,
24181         outermost_loop_in_scop, build_scop_iteration_domain,
24182         expand_scalar_variables_ssa_name, get_vdef_before_scop,
24183         limit_scops): Use bb_in_sese_p instead of bb_in_scop_p.
24184         Use loop_in_sese_p instead of loop_in_scop_p.
24185         (new_graphite_bb, gloog): Do not initialize SCOP_BBS_B.
24186         (new_scop, free_scop): Remove SCOP_LOOP2CLOOG_LOOP and SCOP_BBS_B.
24187         (scopdet_basic_block_info): Fix bug in scop detection.
24188         (new_loop_to_cloog_loop_str, hash_loop_to_cloog_loop,
24189         eq_loop_to_cloog_loop): Remove.
24190         (nb_loops_around_loop_in_scop, nb_loop
24191         ref_nb_loops): Moved here...
24192         * graphite.h (ref_nb_loops): ... from here.
24193         (struct scop): Remove bbs_b bitmap and loop2cloog_loop.
24194         (loop_domain_dim, loop_iteration_vector_dim): Remove.
24195         (SCOP_BBS_B, bb_in_scop_p, loop_in_scop_p): Removed.
24196         * testsuite/gcc.dg/graphite/scop-19.c: New
24197
24198 2009-02-04  Paolo Bonzini  <bonzini@gnu.org>
24199             Hans-Peter Nilsson  <hp@axis.com>
24200
24201         PR rtl-optimization/37889
24202         * rtlanal.c (rtx_addr_can_trap_p_1): Add offset and size arguments.
24203         Move offset handling from PLUS to before the switch.  Use new
24204         arguments when considering SYMBOL_REFs too.
24205         (rtx_addr_can_trap_p): Pass dummy offset and size.
24206         (enum may_trap_p_flags): Remove.
24207         (may_trap_p_1): Pass size from MEM_SIZE.
24208
24209         PR rtl-optimization/38921
24210         * loop-invariant.c (find_invariant_insn): Use may_trap_or_fault_p.
24211         * rtl.h (may_trap_after_code_motion_p): Delete prototype.
24212         * rtlanal.c (may_trap_after_code_motion_p): Delete.
24213         (may_trap_p, may_trap_or_fault_p): Pass 0/1 as flags.
24214
24215 2009-02-04  H.J. Lu  <hongjiu.lu@intel.com>
24216
24217         AVX Programming Reference (January, 2009)
24218         * config/i386/sse.md (*vpclmulqdq): New.
24219
24220 2009-02-04  Jakub Jelinek  <jakub@redhat.com>
24221
24222         PR tree-optimization/38977
24223         PR gcov-profile/38292
24224         * calls.c (special_function_p): Disregard __builtin_ prefix.
24225
24226 2009-02-04  Hariharan Sandanagobalane  <hariharan@picochip.com>
24227
24228         * config/picochip/picochip.c (GO_IF_LEGITIMATE_ADDRESS): Disallow
24229         non-indexable addresses even before reload.
24230
24231 2009-02-03  Joseph Myers  <joseph@codesourcery.com>
24232
24233         PR c/29129
24234         * c-decl.c (grokdeclarator): Mark [*] arrays in field declarators
24235         as having variable size.  Do not give an error for unnamed
24236         parameters with [*] declarators.  Give a warning for type names
24237         with [*] declarators and mark them as variable size.
24238         * c-parser.c (c_parser_sizeof_expression): Do not give an error
24239         for sizeof applied to [*] type names.
24240
24241 2009-02-03  Andrew Pinski  <andrew_pinski@playstation.sony.com>
24242
24243         PR C++/36607
24244         * convert.c (convert_to_integer): Treat OFFSET_TYPE like INTEGER_TYPE.
24245
24246 2009-02-03  Jakub Jelinek  <jakub@redhat.com>
24247
24248         * gcc.c (process_command): Update copyright notice dates.
24249         * gcov.c (print_version): Likewise.
24250         * gcov-dump.c (print_version): Likewise.
24251         * mips-tfile.c (main): Likewise.
24252         * mips-tdump.c (main): Likewise.
24253
24254 2009-02-03  Joseph Myers  <joseph@codesourcery.com>
24255
24256         PR c/35433
24257         * c-typeck.c (composite_type): Set TYPE_SIZE and TYPE_SIZE_UNIT
24258         for composite type involving a zero-length array type.
24259
24260 2009-02-03  Jakub Jelinek  <jakub@redhat.com>
24261
24262         PR target/35318
24263         * function.c (match_asm_constraints_1): Skip over
24264         initial optional % in the constraint.
24265
24266         PR inline-asm/39059
24267         * c-parser.c (c_parser_postfix_expression): If fixed point is not
24268         supported, don't accept FIXED_CSTs.
24269         * c-decl.c (finish_declspecs): Error if fixed point is not supported
24270         and _Sat is used without _Fract/_Accum.  Set specs->type to
24271         integer_type_node for cts_fract/cts_accum if fixed point is not
24272         supported.
24273
24274 2009-02-02  Catherine Moore  <clm@codesourcery.com>
24275
24276         * sde.h (SUBTARGET_ARM_SPEC): Don't assemble -fpic code as -mabicalls.
24277
24278 2009-02-02  Richard Sandiford  <rdsandiford@googlemail.com>
24279
24280         * config/mips/mips.h (FILE_HAS_64BIT_SYMBOLS): New macro.
24281         (ABI_HAS_64BIT_SYMBOLS): Use it.
24282         (DWARF2_ADDR_SIZE): Use it instead of ABI_HAS_64BIT_SYMBOLS.
24283
24284 2009-02-02  Paul Brook  <paul@codesourcery.com>
24285
24286         * config/arm/arm.md (arm_addsi3): Add r/r/k alternative.
24287
24288 2009-02-02  Jakub Jelinek  <jakub@redhat.com>
24289
24290         PR inline-asm/39058
24291         * recog.h (asm_operand_ok): Add constraints argument.
24292         * recog.c (asm_operand_ok): Likewise.  If it is set, for digits
24293         recurse on matching constraint.
24294         (check_asm_operands): Pass constraints as 3rd argument to
24295         asm_operand_ok.  Don't look up matching constraint here.
24296         * stmt.c (expand_asm_operands): Pass NULL as 3rd argument
24297         to asm_operand_ok.
24298
24299 2009-02-02  Ben Elliston  <bje@au.ibm.com>
24300
24301         * doc/tm.texi (Storage Layout): Fix TARGET_ALIGN_ANON_BITFIELD and
24302         TARGET_NARROW_VOLATILE_BITFIELD macro names.
24303
24304 2009-01-31  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
24305
24306         * doc/install.texi (hppa*-hp-hpux*): Update binutils and linker
24307         information.  Remove some obsolete information.  Reorganize.
24308
24309         * config/pa/fptr.c: Revert license to GPL 2.
24310         * config/pa/milli64.S: Likewise.
24311
24312 2009-01-31  Dave Korn  <dave.korn.cygwin@gmail.com>
24313
24314         PR target/38904
24315         * mkmap-flat.awk (END):  Use pe_dll command-line arg to pass
24316         LIBRARY name in, instead of hard-coding it.
24317         * config.gcc (i[34567]86-*-pe | i[34567]86-*-cygwin*):  Add an
24318         extra target make frag to tmake_files according to EH model.
24319         (i[34567]86-*-mingw* | x86_64-*-mingw*):  Likewise.
24320         * config/i386/t-dw2-eh, config/i386/t-sjlj-eh:  Add new target
24321         frags that define makefile variable EH_MODEL appropriately.
24322         * config/i386/cygming.h (DWARF2_UNWIND_INFO):  Add comment.
24323         * config/i386/cygwin.h (LIBGCC_EH_EXTN):  Define to nothing or
24324         to "-sjlj" according to type of EH configured.
24325         (LIBGCC_SONAME):  Concatenate it to shared library base name.
24326         * config/i386/mingw32.h (LIBGCC_EH_EXTN):  Define to "_dw2" or
24327         to "_sjlj" according to type of EH configured.
24328         (LIBGCC_SONAME):  Concatenate it to shared library base name.
24329         * config/i386/t-cygming (SHLIB_SONAME):  Use EH_MODEL.
24330         (SHLIB_LINK):  Add missing semicolon to if-else construct.
24331         (SHLIB_MKMAP_OPTS):  Pass library name to mkmap-flat.awk as
24332         string value of "pe_dll" command-line option.
24333         * config/i386/t-cygwin (SHLIB_EH_EXTENSION):  New helper.
24334         (SHLIB_SONAME):  Use it when overriding t-cygming default.
24335         (SHLIB_IMPLIB):  Override t-cygming default.
24336         (SHLIB_MKMAP_OPTS):  Pass library name to mkmap-flat.awk as
24337         string value of "pe_dll" command-line option.
24338
24339 2009-01-31  Dave Korn  <dave.korn.cygwin@gmail.com>
24340
24341         PR target/38952
24342         * config/i386/i386.c (ix86_builtin_setjmp_frame_value): New.
24343         (TARGET_BUILTIN_SETJMP_FRAME_VALUE): Override default to point at it.
24344
24345 2009-01-31  Richard Guenther  <rguenther@suse.de>
24346
24347         PR tree-optimization/38937
24348         * tree-ssa-structalias.c (do_sd_constraint): Do not shortcut
24349         computing the transitive closure.
24350
24351 2009-01-30  Richard Guenther  <rguenther@suse.de>
24352
24353         PR tree-optimization/39041
24354         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1):
24355         Propagate variable indices only if the types match for this stmt.
24356
24357 2009-01-30  Jakub Jelinek  <jakub@redhat.com>
24358
24359         PR target/39013
24360         * c-decl.c (pop_scope): Set DECL_EXTERNAL for functions declared
24361         inline but never defined.
24362
24363 2009-01-30  Wolfgang Gellerich  <gellerich@de.ibm.com>
24364
24365         * config/s390/s390.md (*insv<mode>_reg_extimm): Removed.
24366         (*insv_h_di_reg_extimm): New insn.
24367         (*insv_l<mode>_reg_extimm): New insn.
24368
24369 2009-01-30  Hariharan Sandanagobalane  <hariharan@picochip.com>
24370
24371         * config/picochip/picochip.c (flag_conserve_stack): set
24372         PARAM_LARGE_STACK_FRAME and PARAM_STACK_FRAME_GROWTH to zero under
24373         fconserve-stack. Reduce call-overhead used by inliner.
24374
24375 2009-01-30  Hariharan Sandanagobalane  <hariharan@picochip.com>
24376
24377         PR/38157
24378         * common.opt (flag_conserve_stack): Initialised to zero.
24379
24380 2009-01-30  Kai Tietz  <kai.tietz@onevision.com>
24381
24382         PR/39002
24383         * config/i386/i386.c (ix86_can_use_return_insn_p): Check for nsseregs.
24384         (ix86_expand_epilogue): Take nsseregs in account to use proper restore
24385         method.
24386
24387 2009-01-29  H.J. Lu  <hongjiu.lu@intel.com>
24388
24389         * ira-color.c (allocno_reload_assign): Update comments.
24390         * regmove.c (regmove_optimize): Likewise.
24391
24392         * ra.h: Removed.
24393
24394 2009-01-29  Robert Millan  <rmh@aybabtu.com>
24395
24396         * config.gcc: Recognize GNU/kOpenSolaris (*-*-kopensolaris*-gnu).
24397         * config/i386/kopensolaris-gnu.h: New file.  Undefine
24398         `MD_UNWIND_SUPPORT'.
24399         * config/kopensolaris-gnu.h: New file (based on kfreebsd-gnu.h).
24400
24401 2009-01-29  Kazu Hirata  <kazu@codesourcery.com>
24402
24403         PR tree-optimization/39007
24404         * tree-loop-distribution.c (generate_builtin): Use
24405         recompute_dominator to compute the immediate dominator of the
24406         basic block just after the loop.
24407
24408 2009-01-29  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
24409
24410         * config/i386/sol2-10.h [!HAVE_AS_IX86_DIFF_SECT_DELTA]
24411         (ASM_OUTPUT_DWARF_PCREL): Define.
24412
24413 2009-01-29  Vladimir Makarov  <vmakarov@redhat.com>
24414
24415         * doc/tm.texi (TARGET_IRA_COVER_CLASSES): Modify description.
24416         * doc/passes.texi: Remove entries about regclass, local-alloc, and
24417         global.  Modify entries about regmove and IRA.
24418
24419         * ra-conflict.c: Remove the file.
24420
24421         * reload.c (push_reload, find_dummy_reload): Remove flag_ira.
24422
24423         * tree-pass.h (pass_local_alloc, pass_global_alloc): Remove.
24424         (pass_regclass_init): Rename to pass_reginfo_init.
24425
24426         * cfgloopanal.c (estimate_reg_pressure_cost): Remove flag_ira.
24427
24428         * toplev.h (flag_ira): Remove.
24429
24430         * caller-save.c (setup_save_areas): Remove flag_ira.
24431
24432         * ira-color.c (ira_reuse_stack_slot, ira_mark_new_stack_slot): Ditto.
24433
24434         * global.c: Remove the file.
24435
24436         * opts.c (decode_options): Remove flag_ira.
24437
24438         * hard-reg-set.h (losing_caller_save_reg_set): Remove.
24439
24440         * regmove.c: Modify file description.
24441         (find_use_as_address, try_auto_increment): Define them only if
24442         AUTO_INC_DEC is defined.
24443         (replacement_quality, replace_in_call_usage, fixup_match_1,
24444         stable_and_no_regs_but_for_p): Remove.
24445         (reg_set_in_bb): Make it static.
24446         (regmove_optimize): Remove flag_ira and code which worked for
24447         !flag_ira.
24448
24449         * local-alloc.c: Remove the file.
24450
24451         * common.opt (fira): Remove.
24452
24453         * ira.c: Include except.h.
24454         (eliminable_regset): Move from global.c.
24455         (mark_elimination): Ditto.  Remove flag_ira.
24456         (reg_renumber, struct equivalence, reg_equiv, equiv_mem,
24457         equiv_mem_modified, validate_equiv_mem_from_store,
24458         validate_equiv_mem, equiv_init_varies_p, equiv_init_movable_p,
24459         contains_replace_regs, memref_referenced_p, memref_used_between_p,
24460         no_equiv, recorded_label_ref): Move from local-alloc.c.
24461         (update_equiv_regs): Ditto.  Make it static.
24462         (print_insn_chain, print_insn_chains): Move it from global.c.
24463         (pseudo_for_reload_consideration_p): Ditto.  Remove flag_ira.
24464         (build_insn_chain): Ditto.  Make it static.
24465         (ra_init_live_subregs): Move from ra-conflict.c.  Make it static.
24466         Rename to init_live_subregs.
24467         (gate_ira): Remove flag_ira.
24468
24469         * regclass.c: Rename reginfo.c.  Change file description.
24470         (FORBIDDEN_INC_DEC_CLASSES): Remove.
24471         (reg_class_superclasses, forbidden_inc_dec_class, in_inc_dec): Remove.
24472         (init_reg_sets_1): Remove code for evaluation of
24473         reg_class_superclasses and losing_caller_save_reg_set.
24474         (init_regs): Remove init_reg_autoinc.
24475         (struct costs, costs, init_cost, ok_for_index_p_nonstrict,
24476         ok_for_base_p_nonstrict): Remove.
24477         (regclass_init): Rename to reginfo_init.  Don't initialize init_cost.
24478         (pass_regclass_init): Rename to pass_reginfo_init.  Modify
24479         corresponding entries.
24480         (dump_regclass, record_operand_costs, scan_one_insn,
24481         init_reg_autoinc, regclass, record_reg_classes, copy_cost,
24482         record_address_regs, auto_inc_dec_reg_p): Remove.
24483         (gt-regclass.h): Rename to gt-reginfo.h.
24484
24485         * rtl.h (dump_global_regs, retry_global_alloc,
24486         build_insn_chain, dump_local_alloc, update_equiv_regs): Remove.
24487
24488         * Makefile.in (RA_H): Remove.
24489         (OBJS-common): Remove global.o, local-alloc.o, and ra-conflict.o.
24490         Rename regclass.o to reginfo.o.
24491         (regclass.o): Rename to reginfo.o.  Rename gt-regclass.h to
24492         gt-reginfo.h.
24493         (global.o, local-alloc.o, ra-conflict.o): Remove entries.
24494         (GTFILES): Rename regclass.c to reginfo.c.
24495
24496         * passes.c (init_optimization_passes): Remove pass_local_alloc and
24497         pass_global_alloc.  Rename pass_regclass_init to pass_reginfo_init.
24498
24499         * reload1.c (compute_use_by_pseudos, reload, count_pseudo,
24500         count_spilled_pseudo, find_reg, alter_reg, delete_output_reload):
24501         Remove flag_ira.
24502         (finish_spills): Ditto.  Remove code for !flag_ira.
24503
24504 2009-01-29  Kenneth Zadeck  <zadeck@naturalbridge.com>
24505
24506         PR middle-end/35854
24507         * doc/invoke.texi (rtl debug options): Complete rewrite.
24508         * auto-inc-dec.c (pass_inc_dec): Rename pass from "auto-inc-dec"
24509         to auto_inc_dec".
24510         * mode-switching.c (pass_mode_switching): Rename pass from
24511         "mode-sw" to "mode_sw".
24512         * except.c (pass_convert_to_eh_ranges): Rename pass from
24513         "eh-ranges" to "eh_ranges".
24514         * lower-subreg.c (pass_lower_subreg): Renamed pass from "subreg"
24515         to "subreg1".
24516
24517
24518 2009-01-29  Andrey Belevantsev  <abel@ispras.ru>
24519             Alexander Monakov  <amonakov@ispras.ru>
24520
24521         PR middle-end/38857
24522         * sel-sched.c (count_occurrences_1): Check that *cur_rtx is a hard
24523         register.
24524         (move_exprs_to_boundary): Change return type and pass through
24525         should_move from move_op.  Relax assert.  Update usage ...
24526         (schedule_expr_on_boundary): ... here.  Use should_move instead of
24527         cant_move.
24528         (move_op_orig_expr_found): Indicate that insn was disconnected from
24529         stream.
24530         (code_motion_process_successors): Do not call after_merge_succs
24531         callback if original expression was not found when traversing any of
24532         the branches.
24533         (code_motion_path_driver): Change return type.  Update prototype.
24534         (move_op): Update comment.  Add a new parameter (should_move).  Update
24535         prototype.  Set *should_move based on indication provided by
24536         move_op_orig_expr_found.
24537
24538 2009-01-28  Pat Haugen  <pthaugen@us.ibm.com>
24539
24540         * doc/invoke.texi (avoid-indexed-addresses): Document new option.
24541         * config/rs6000/rs6000-protos.h (avoiding_indexed_address_p): Declare.
24542         * config/rs6000/rs6000.opt (avoid-indexed-addresses): New option.
24543         * config/rs6000/rs6000.c (rs6000_override_options): Default
24544         avoid-indexed-addresses on for Power6, off for everything else.
24545         (avoiding_indexed_address_p): New function.
24546         (rs6000_legitimize_address): Use it.
24547         (rs6000_legitimate_address): Likewise.
24548         * config/rs6000/rs6000.md (movXX_updateX): Likewise
24549
24550 2009-01-28  Kazu Hirata  <kazu@codesourcery.com>
24551
24552         PR tree-optimization/38997
24553         * tree-loop-distribution.c (generate_memset_zero): Use
24554         POINTER_PLUS_EXPR for a pointer addition.
24555
24556 2009-01-28  Andreas Krebbel  <krebbel1@de.ibm.com>
24557
24558         * config/s390/s390.md (bswap<mode>2): New pattern added.
24559
24560 2009-01-28  Wolfgang Gellerich  <gellerich@de.ibm.com>
24561
24562         * config/s390/s390.md (*tls_load_31): Added type attribute.
24563
24564 2009-01-28  Wolfgang Gellerich  <gellerich@de.ibm.com>
24565
24566         * config/s390/s390.md: Fix a few comments.
24567
24568 2009-01-28  Wolfgang Gellerich  <gellerich@de.ibm.com>
24569
24570         * config/s390/s390.md (*tmsi_reg): Fixed z10prop attribute.
24571         (*tm<mode>_full): Fixed z10prop attribute.
24572         (*tst<mode>_extimm): Fixed z10prop attribute.
24573         (*tst<mode>_cconly_extimm): Fixed z10prop attribute.
24574         (*tstqiCCT_cconly): Fixed z10prop attribute.
24575         (*cmpsi_ccu_zerohi_rlsi): Fixed z10prop attribute.
24576         (*movsi_larl): Fixed z10prop attribute.
24577         (*movsi_zarch): Fixed z10prop attribute.
24578         (*movsi_eas): Fixed z10prop attribute.
24579         (*movhi): Fixed z10prop attribute.
24580         (*movqi): Fixed z10prop attribute.
24581         (*movstrictqi): Fixed z10prop attribute.
24582         (*mov<mode>): Fixed z10prop attribute.
24583         (*movcc): Fixed z10prop attribute.
24584         (*sethighpartdi_64): Fixed z10prop attribute.
24585         (*zero_extendhi<mode>2_z10): Fixed z10prop attribute.
24586         (*negdi2_sign_cc): Fixed z10prop attribute.
24587         (*negdi2_sign): Fixed z10prop attribute.
24588         (*absdi2_sign_cc): Fixed z10prop attribute.
24589         (*absdi2_sign): Fixed z10prop attribute.
24590         (*negabsdi2_sign_cc): Fixed z10prop attribute.
24591         (*negabsdi2_sign): Fixed z10prop attribute.
24592         (*cmp_and_trap_signed_int<mode>): Fixed z10prop attribute.
24593         (*cmp_and_trap_unsigned_int<mode>): Fixed z10prop attribute.
24594         (doloop_si64): Fixed z10prop attribute.
24595         (doloop_si31): Fixed z10prop attribute.
24596         (doloop_long): Fixed z10prop attribute.
24597         (indirect_jump): Fixed z10prop attribute.
24598         (nop): Fixed z10prop attribute.
24599         (main_base_64): Fixed z10prop attribute.
24600         (reload_base_64): Fixed z10prop attribute.
24601
24602 2009-01-28  Jakub Jelinek  <jakub@redhat.com>
24603
24604         PR rtl-optimization/38740
24605         * reorg.c (gate_handle_delay_slots): Avoid dbr scheduling
24606         if !optimize.
24607         * config/mips/mips.c (mips_reorg): Likewise.
24608
24609 2009-01-28  Richard Guenther  <rguenther@suse.de>
24610
24611         PR tree-optimization/38926
24612         * tree-ssa-pre.c (add_to_value): Assert we add only expressions
24613         with the correct value id to a value.
24614         (do_regular_insertion): Use the value number of edoubleprime
24615         for the value number of the expr.
24616
24617         Revert
24618         2008-08-21  Richard Guenther  <rguenther@suse.de>
24619
24620         * tree-ssa-pre.c (insert_into_preds_of_block): Before inserting
24621         a PHI ask VN if it is already available.
24622         * tree-ssa-sccvn.h (vn_phi_lookup): Declare.
24623         * tree-ssa-sccvn.c (vn_phi_lookup): Export.
24624
24625 2009-01-28  Jakub Jelinek  <jakub@redhat.com>
24626
24627         PR middle-end/38934
24628         * tree-vrp.c (extract_range_from_assert): For LE_EXPR and LT_EXPR
24629         set to varying whenever max has TREE_OVERFLOW set, similarly
24630         for GE_EXPR and GT_EXPR and TREE_OVERFLOW min.
24631
24632 2009-01-28  Richard Guenther  <rguenther@suse.de>
24633
24634         PR middle-end/38908
24635         * tree-ssa.c (warn_uninitialized_var): Do not warn for seemingly
24636         uninitialized aggregate uses in call arguments.
24637
24638 2009-01-28  Paolo Bonzini  <bonzini@gnu.org>
24639
24640         PR tree-optimization/38984
24641         * tree-ssa-structalias.c (get_constraints_for_1): Do not use
24642         the nothing_id variable if -fno-delete-null-pointer-checks.
24643
24644 2009-01-28  Uros Bizjak  <ubizjak@gmail.com>
24645
24646         PR target/38988
24647         * config/i386/i386.md (set_rip_rex64): Wrap operand 1 in label_ref.
24648         (set_got_offset_rex64): Ditto.
24649
24650 2009-01-27  H.J. Lu  <hongjiu.lu@intel.com>
24651
24652         PR target/38941
24653         * doc/extend.texi: Improve local variable with asm reg.
24654
24655 2009-01-27  Adam Nemet  <anemet@caviumnetworks.com>
24656
24657         * c.opt (Wpacked-bitfield-compat): Change init value to -1.
24658         * c-opts.c (c_common_post_options): If -W*packed-bitfield-compat
24659         was not supplied then set warn_packed_bitfield_compat to the
24660         default value of 1.
24661         * stor-layout.c (place_field): Check warn_packed_bitfield_compat
24662         against 1.
24663
24664 2009-01-27  Richard Guenther  <rguenther@suse.de>
24665
24666         PR tree-optimization/38503
24667         * cfgexpand.c (expand_gimple_basic_block): Ignore
24668         GIMPLE_CHANGE_DYNAMIC_TYPE during expansion.
24669         * tree-ssa-structalias.c (set_uids_in_ptset): Do not prune
24670         variables that cannot have TBAA applied.
24671         (compute_points_to_sets): Do not remove GIMPLE_CHANGE_DYNAMIC_TYPE
24672         statements.
24673
24674 2009-01-27  Uros Bizjak  <ubizjak@gmail.com>
24675
24676         PR middle-end/38969
24677         * calls.c (initialize_argument_information): Do not wrap complex
24678         arguments in SAVE_EXPR.
24679
24680 2009-01-26  Andreas Tobler  <a.tobler@schweiz.org>
24681
24682         * config/t-vxworks (LIBGCC2_INCLUDES): Fix typo.
24683         (INSTALL_LIBGCC): Revert typo commit.
24684
24685 2009-01-26  Richard Guenther  <rguenther@suse.de>
24686
24687         PR tree-optimization/38745
24688         * tree-ssa-alias.c (update_alias_info_1): Exclude RESULT_DECL
24689         from special handling.
24690
24691 2009-01-26  Richard Guenther  <rguenther@suse.de>
24692
24693         PR tree-optimization/38745
24694         * tree-ssa.c (execute_update_addresses_taken): Do not include
24695         variables that cannot possibly be a register in not_reg_needs.
24696         Do not clear TREE_ADDRESSABLE on vars that may not become
24697         registers.
24698         * tree-ssa.c (update_alias_info_1): Include those in the set
24699         of addressable vars.
24700
24701 2009-01-26  Richard Guenther  <rguenther@suse.de>
24702
24703         PR middle-end/38851
24704         * Makefile.in (tree-ssa-dse.o): Add langhooks.h.
24705         * tree-ssa-dse.c: Include langhooks.h
24706         (execute_simple_dse): Remove stores with zero size.
24707
24708 2009-01-24  Jakub Jelinek  <jakub@redhat.com>
24709
24710         PR c/38957
24711         * c-typeck.c (c_finish_return): Handle POINTER_PLUS_EXPR the same way
24712         as PLUS_EXPR.
24713
24714 2009-01-24  Julian Brown  <julian@codesourcery.com>
24715
24716         * config/arm/t-linux-eabi (LIB2FUNCS_STATIC_EXTRA): Add
24717         config/arm/linux-atomic.c.
24718         * config/arm/linux-atomic.c: New.
24719
24720 2009-01-24  Eric Botcazou  <ebotcazou@adacore.com>
24721
24722         * config/sparc/linux.h (DBX_REGISTER_NUMBER): Delete.
24723         * config/sparc/linux64.h (DBX_REGISTER_NUMBER): Likewise.
24724         * config/sparc/sysv4.h (DBX_REGISTER_NUMBER): Likewise.
24725
24726 2009-01-24  H.J. Lu  <hongjiu.lu@intel.com>
24727
24728         PR c/38938
24729         * c-opts.c (c_common_handle_option): Update warn_pointer_sign
24730         properly.
24731
24732 2009-01-24  Sebastian Pop  <sebastian.pop@amd.com>
24733
24734         PR tree-optimization/38953
24735         * graphite.c (graphite_verify): Add a call to verify_loop_closed_ssa.
24736         (scop_adjust_phis_for_liveouts): Initialize false_i to zero.
24737         (gloog): Split the exit of the scop when the scop exit is a loop exit.
24738         (graphite_transform_loops): Only call cleanup_tree_cfg if gloog
24739         changed the CFG.
24740
24741 2009-01-24  Paul Brook  <paul@codesourcery.com>
24742
24743         * config/arm/neon.md (neon_type): Move to arm.md.
24744         (neon_mov<VSTRUCT>): Add neon_type attribute.
24745         * config/arm/arm.md (neon_type): Move to here.
24746         (conds): Add "unconditioal" and use as default for NEON insns.
24747
24748 2009-01-24  Ben Elliston  <bje@au.ibm.com>
24749
24750         * bitmap.h (BITMAP_FREE): Eliminate `implicit conversion from
24751         void *' warning from -Wc++-compat.
24752         * Makefile.in (dominance.o-warn): Remove.
24753
24754 2009-01-23  Paolo Bonzini  <bonzini@gnu.org>
24755
24756         PR tree-optimization/38932
24757         * fold-const.c (fold_unary_ignore_overflow): New.
24758         * tree.h (fold_unary_ignore_overflow): Declare.
24759         * tree-ssa-ccp.c (ccp_fold): Use fold_unary_ignore_overflow.
24760         * tree-ssa-sccvn.c (visit_reference_op_load,
24761         simplify_unary_expression): Likewise.
24762
24763 2009-01-22  Adam Nemet  <anemet@caviumnetworks.com>
24764
24765         * c-decl.c (finish_struct): Move code to set DECL_PACKED after
24766         DECL_BIT_FIELD is alreay known.  Also inherit packed for bitfields
24767         regardless of their type.
24768         * c-common.c (handle_packed_attribute): Don't ignore packed on
24769         bitfields.
24770         * c.opt (Wpacked-bitfield-compat): New warning option.
24771         * stor-layout.c (place_field): Warn if offset of a field changed.
24772         * doc/extend.texi (packed): Mention the ABI change.
24773         * doc/invoke.texi (-Wpacked-bitfield-compat): Document.
24774         (Warning Options): Add it to the list.
24775
24776 2009-01-22  H.J. Lu  <hongjiu.lu@intel.com>
24777
24778         * c-opts.c (c_common_post_options): Fix a typo in comments.
24779
24780 2009-01-22  Steve Ellcey  <sje@cup.hp.com>
24781
24782         PR middle-end/38615
24783         * gimplify.c (gimplify_init_constructor): Fix promotion of const
24784         variables to static.
24785         * doc/invoke.texi (-fmerge-all-constants): Update description.
24786
24787 2009-01-22  Uros Bizjak  <ubizjak@gmail.com>
24788
24789         PR target/38931
24790         * config/i386/i386.md (*movsi_1): Use type "mmx" for alternative 2.
24791         (*movdi_1_rex64): Use type "mmx" for alternative 5.
24792
24793 2009-01-22  Richard Earnshaw  <rearnsha@arm.com>
24794
24795         * arm.h (DATA_ALIGNMENT): Align structures, unions and arrays to
24796         a word boundary.
24797         (LOCAL_ALIGNMENT): Similarly.
24798
24799 2009-01-22  Mark Shinwell  <shinwell@codesourcery.com>
24800             Joseph Myers  <joseph@codesourcery.com>
24801
24802         * config/arm/arm.c (all_architectures): Add iWMMXt2 entry.
24803         * config/arm/arm-cores.def: New ARM_CORE entry for iWMMXt2.
24804         * config/arm/arm-tune.md: Regenerate.
24805         * doc/invoke.texi (ARM Options): Document -mcpu=iwmmxt2 and
24806         -march=iwmmxt2.
24807
24808 2009-01-22  Mark Shinwell  <shinwell@codesourcery.com>
24809
24810         * config/arm/bpabi.h (SUBTARGET_EXTRA_ASM_SPEC): Bump EABI
24811         version number to five.
24812
24813 2009-01-22  Dodji Seketeli  <dodji@redhat.com>
24814
24815         PR c++/38930
24816         * c-decl.c (clone_underlying_type): Revert PR c++/26693 changes.
24817         * c-common.c (set_underlying_type): Likewise.
24818         (is_typedef_decl ): Likewise
24819         * tree.h: Likewise
24820         (set_underlying_type): Likewise.
24821         (is_typedef_type): Likewise.
24822
24823 2009-01-21  Vladimir Makarov  <vmakarov@redhat.com>
24824
24825         PR middle-end/38587
24826         * ira-color.c (coalesce_spill_slots): Don't coalesce allocnos
24827         crossing setjmps.
24828
24829 2009-01-21  Dave Korn  <dave.korn.cygwin@gmail.com>
24830
24831         PR bootstrap/37660
24832         * config/i386/cygwin.h (SHARED_LIBGCC_SPEC):  New helper macro.
24833         (LIBGCC_SPEC):  Don't define.
24834         (REAL_LIBGCC_SPEC):  Define instead, using SHARED_LIBGCC_SPEC.
24835
24836 2009-01-21  Uros Bizjak  <ubizjak@gmail.com>
24837
24838         PR rtl-optimization/38879
24839         * alias.c (base_alias_check): Unaligned access via AND address can
24840         alias all surrounding object types except those with sizes equal
24841         or wider than the size of unaligned access.
24842
24843 2009-01-21  Dodji Seketeli  <dodji@redhat.com>
24844
24845         PR c++/26693
24846         * c-decl.c (clone_underlying_type): Move this ...
24847         * c-common.c (set_underlying_type): ... here.
24848         Also, make sure the function properly sets TYPE_STUB_DECL() on
24849         the newly created typedef variant type.
24850         (is_typedef_decl ): New entry point.
24851         * tree.h: Added a new member member_types_needing_access_check to
24852         struct tree_decl_non_common.
24853         (set_underlying_type): New entry point.
24854         (is_typedef_type): Likewise.
24855
24856 2009-01-21  Bingfeng Mei  <bmei@broadcom.com>
24857
24858         * alias.c (walk_mems_1, walk_mems_2, insn_alias_sets_conflict_p):
24859         Check whether two instructions have memory references that
24860         belong to conflicting alias sets.  walk_mems_1 and walk_mems_2
24861         are helper functions for traversing.
24862         * alias.h (insn_alias_sets_confilict_p): New prototypes.
24863         * ddg.c (add_inter_loop_mem_dep): Call insn_alias_sets_conflict_p
24864         not to draw dependency edge for instructions with non-conflicting
24865         alias sets.
24866
24867 2009-01-20  Joseph Myers  <joseph@codesourcery.com>
24868
24869         PR other/38758
24870         * longlong.h: Update copyright years.  Use soft-fp license notice.
24871         Sync __clz_tab declaration with glibc.
24872
24873 2009-01-20  Steve Ellcey  <sje@cup.hp.com>
24874
24875         PR target/30687
24876         * doc/extend.texi (syscall_linkage): New.
24877         (version_id): Modify.
24878
24879 2009-01-20  Andrew Pinski  <andrew_pinski@playstation.sony.com>
24880             Richard Guenther  <rguenther@suse.de>
24881
24882         PR tree-optimization/38747
24883         PR tree-optimization/38748
24884         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Disable the VCE
24885         conversion if the base address is an indirect reference and the
24886         aliasing sets could cause issues.
24887
24888 2009-01-20  Sebastian Pop  <sebastian.pop@amd.com>
24889
24890         * common.opt (fgraphite, fgraphite-identity): Add comment for
24891         explaining why these options are not documented.
24892
24893 2009-01-20  Sebastian Pop  <sebastian.pop@amd.com>
24894
24895         * graphite.c (stmt_simple_for_scop_p): Also handle cases when
24896         gimple_call_lhs is NULL.
24897
24898 2009-01-20  Paolo Bonzini  <bonzini@gnu.org>
24899
24900         PR target/38868
24901         * emit-rtl.c (adjust_address_1): Make sure memref is never
24902         overwritten.
24903
24904 2009-01-20  Ben Elliston  <bje@au.ibm.com>
24905
24906         * libgcov.c (__gcov_execl, __gcov_execlp, __gcov_execle): Remove
24907         const qualifier from arg parameter. Remove unnecessary cast to char *.
24908         * gcov-io.h (__gcov_execl, __gcov_execlp, __gcov_execle): Remove
24909         const qualifier from arg 2.
24910
24911 2009-01-19  Iain Sandoe  <iain.sandoe@sandoe-acoustics.co.uk>
24912
24913         * config/darwin.h: Add static-libgfortran to LINK_SPEC.
24914
24915 2009-01-19  Vladimir Makarov  <vmakarov@redhat.com>
24916
24917         PR c/38869
24918         * rtl.h (reinit_regs): New prototype.
24919         * regclass.c: Include ira.h.
24920         (reinit_regs): New.
24921         * Makefile.in (regclass.o): Add ira.h.
24922         * config/i386/i386.c (ix86_maybe_switch_abi): Use reinit_regs.
24923
24924 2009-01-18  H.J. Lu  <hongjiu.lu@intel.com>
24925
24926         PR target/38736
24927         * c-common.c (handle_aligned_attribute): Use
24928         ATTRIBUTE_ALIGNED_VALUE instead of BIGGEST_ALIGNMENT for
24929         default alignment value.
24930
24931         * c-cppbuiltin.c (c_cpp_builtins): Define __BIGGEST_ALIGNMENT__.
24932
24933         * defaults.h (ATTRIBUTE_ALIGNED_VALUE): New.
24934         * config/i386/i386.h (ATTRIBUTE_ALIGNED_VALUE): Likewise.
24935
24936         * doc/extend.texi: Update __attribute__ ((aligned)).  Document
24937         __BIGGEST_ALIGNMENT__.
24938
24939         * doc/tm.texi: Document ATTRIBUTE_ALIGNED_VALUE.
24940
24941 2009-01-18  Richard Guenther  <rguenther@suse.de>
24942
24943         PR tree-optimization/38819
24944         * tree-flow.h (operation_could_trap_helper_p): Declare.
24945         * tree-eh.c (operation_could_trap_helper_p): Export.
24946         * tree-ssa-sccvn.h (vn_nary_may_trap): Declare.
24947         * tree-ssa-sccvn.c (vn_nary_may_trap): New function.
24948         * tree-ssa-pre.c (insert_into_preds_of_block): Check if we
24949         are about to insert a possibly trapping instruction and fail
24950         in this case.
24951
24952 2009-01-18  Andreas Schwab  <schwab@suse.de>
24953
24954         * doc/install.texi (Configuration): Remove obsolete paragraph
24955         about use of --with-gnu-ld with --with-gnu-as.
24956
24957 2009-01-18  Kazu Hirata  <kazu@codesourcery.com>
24958
24959         * doc/extend.texi, doc/gimple.texi, doc/invoke.texi,
24960         doc/md.texi, doc/sourcebuild.texi, doc/tm.texi: Fix typos.
24961         Follow spelling conventions.
24962
24963 2009-01-18  Ben Elliston  <bje@au.ibm.com>
24964
24965         * bitmap.c (bitmap_obstack_alloc_stat): Adjust cast to eliminate
24966         C++ warning about implicit conversion from void * to struct
24967         bitmap_head_def *.
24968         (bitmap_obstack_free): Likewise for bitmap_element *.
24969         * Makefile.in (bitmap.o-warn): Remove.
24970
24971 2009-01-17  Dave Korn  <dave.korn.cygwin@gmail.com>
24972
24973         * Makefile.in (BACKENDLIBS):  Reorder to match dependencies.
24974
24975 2009-01-17  Sebastian Pop  <sebastian.pop@amd.com>
24976             Tobias Grosser  <tobi.grosser@amd.com>
24977
24978         * graphite.c (graphite_trans_scop_block): Do not block single
24979         nested loops.
24980
24981 2009-01-16  Alexandre Oliva  <aoliva@redhat.com>
24982
24983         * ebitmap.h (ebitmap_iter_init): Initialize all fields.
24984         * ipa-struct-reorg.c (gen_struct_type): Replace known-true
24985         test with assertion.
24986
24987 2009-01-16  Richard Guenther  <rguenther@suse.de>
24988
24989         PR tree-optimization/38835
24990         PR middle-end/36227
24991         * fold-const.c (fold_binary): Remove PTR + INT -> (INT)(PTR p+ INT)
24992         and INT + PTR -> (INT)(PTR p+ INT) folding.
24993         * tree-ssa-address.c (create_mem_ref): Properly use POINTER_PLUS_EXPR.
24994
24995 2009-01-16  Adam Nemet  <anemet@caviumnetworks.com>
24996
24997         PR target/38554
24998         * expmed.c (expand_shift): With SHIFT_COUNT_TRUNCATED, don't lift
24999         the subreg from a lowpart subreg if it is also casting the value.
25000
25001 2009-01-16  Sebastian Pop  <sebastian.pop@amd.com>
25002             Tobias Grosser  <tobi.grosser@amd.com>
25003
25004         * graphite.c (compare_prefix_loops): New.
25005         (build_scop_canonical_schedules): Rewritten.
25006         (graphite_transform_loops): Move build_scop_canonical_schedules
25007         after build_scop_iteration_domain.
25008
25009 2009-01-16  Sebastian Pop  <sebastian.pop@amd.com>
25010             Tobias Grosser  <tobi.grosser@amd.com>
25011
25012         * graphite.c (add_conditions_to_domain): Add the loops to
25013         the dimension of the iteration domain.  Do copy the domain
25014         only when it exists.
25015         (build_scop_conditions_1): Do not call add_conditions_to_domain.
25016         (add_conditions_to_constraints): New.
25017         (can_generate_code_stmt, can_generate_code): Removed.
25018         (gloog): Do not call can_generate_code.
25019         (graphite_transform_loops): Call add_conditions_to_constraints
25020         after building the iteration domain.
25021
25022 2009-01-16  Jakub Jelinek  <jakub@redhat.com>
25023
25024         PR tree-optimization/38789
25025         * tree-ssa-threadedge.c
25026         (record_temporary_equivalences_from_stmts_at_dest): Ignore calls to
25027         __builtin_constant_p.
25028
25029 2009-01-16  Kenneth Zadeck  <zadeck@naturalbridge.com>
25030
25031         * dce.c (delete_unmarked_insns): Reversed the order that insns are
25032         examined before deleting them.
25033
25034 2009-01-16  Richard Earnshaw  <rearnsha@arm.com>
25035
25036         * function.c (aggregate_value_p): Correctly extract the function
25037         type from CALL_EXPR_FN lookup.
25038
25039 2009-01-16  Hariharan Sandanagobalane  <hariharan@picochip.com>
25040
25041         * config/picochip/picochip.c (picochip_override_options): Revert
25042         CFI asm flag disable commited previously.
25043
25044 2009-01-15  Sebastian Pop  <sebastian.pop@amd.com>
25045             Tobias Grosser  <tobi.grosser@amd.com>
25046             Jan Sjodin  <jan.sjodin@amd.com>
25047
25048         * graphite.c (scan_tree_for_params): On substractions negate
25049         all the coefficients of the term.
25050         (clast_to_gcc_expression_red): New.  Handle reduction expressions
25051         of more than two operands.
25052         (clast_to_gcc_expression): Call clast_to_gcc_expression_red.
25053         (get_vdef_before_scop): Handle also the case of default definitions.
25054
25055 2009-01-15  Richard Sandiford  <rdsandiford@googlemail.com>
25056
25057         * caller-save.c (add_used_regs_1, add_used_regs): New functions.
25058         (insert_one_insn): Use them instead of REG_DEAD and REG_INC notes.
25059         Also use them when walking CALL_INSN_FUNCTION_USAGE.
25060
25061 2009-01-15  H.J. Lu  <hongjiu.lu@intel.com>
25062             Joey Ye  <joey.ye@intel.com>
25063
25064         PR middle-end/37843
25065         * cfgexpand.c (expand_stack_alignment): Don't update stack
25066         boundary nor check incoming stack boundary here.
25067         (gimple_expand_cfg): Update stack boundary and check incoming
25068         stack boundary here.
25069
25070 2009-01-15  Kenneth Zadeck  <zadeck@naturalbridge.com>
25071
25072         * dce.c (find_call_stack_args, delete_unmarked_insns): Fixed comments.
25073
25074 2009-01-14  Jakub Jelinek  <jakub@redhat.com>
25075
25076         PR rtl-optimization/38245
25077         * calls.c (expand_call): Add stack arguments to
25078         CALL_INSN_FUNCTION_USAGE even for pure calls (when
25079         ACCUMULATE_OUTGOING_ARGS) and even for args partially passed
25080         in regs and partially in memory or BLKmode arguments.
25081         (emit_library_call_value_1): Add stack arguments to
25082         CALL_INSN_FUNCTION_USAGE even for pure calls (when
25083         ACCUMULATE_OUTGOING_ARGS).
25084         * dce.c: Include tm_p.h.
25085         (find_call_stack_args): New function.
25086         (deletable_insn_p): Call it for CALL_P insns.  Add ARG_STORES
25087         argument.
25088         (mark_insn): Call find_call_stack_args for CALL_Ps.
25089         (prescan_insns_for_dce): Walk insns backwards in bb rather than
25090         forwards.  Allocate and free arg_stores bitmap if needed, pass it
25091         down to deletable_insn_p, don't mark stores set in arg_stores
25092         bitmap, clear the bitmap at the beginning of each bb.
25093         * Makefile.in (dce.o): Depend on $(TM_P_H).
25094
25095 2009-01-14  Michael Meissner  <gnu@the-meissners.org>
25096
25097         PR target/22599
25098         * config/i386/i386.c (print_operand): Add tests for 'D', 'C', 'F', 'f'
25099         to make sure the insn is a conditional test (bug 22599).  Reformat a
25100         few long lines.
25101
25102 2009-01-14  Sebastian Pop  <sebastian.pop@amd.com>
25103
25104         PR middle-end/38431
25105         * graphite.c (get_vdef_before_scop, scop_adjust_vphi): New.
25106         (scop_adjust_phis_for_liveouts): Call scop_adjust_vphi.
25107         (gloog): Do not call cleanup_tree_cfg.
25108         (graphite_transform_loops): Call cleanup_tree_cfg after all
25109         scops have been code generated.
25110
25111 2009-01-14  Basile Starynkevitch  <basile@starynkevitch.net>
25112         * doc/gty.texi (Invoking the garbage collector): Added new node
25113         and section documenting ggc_collect.
25114
25115 2009-01-14  Richard Guenther  <rguenther@suse.de>
25116
25117         PR tree-optimization/38826
25118         PR middle-end/38477
25119         * tree-ssa-structalias.c (emit_alias_warning): Emit the pointer
25120         initialization notes only if we actually emitted a warning.
25121         (intra_create_variable_infos): Add constraints for a result decl
25122         that is passed by hidden reference.
25123         (build_pred_graph): Mark all related variables non-direct on
25124         address-taking.
25125
25126 2009-01-14  Nick Clifton  <nickc@redhat.com>
25127
25128         * ira-conflicts.c: Include addresses.h for the definition of
25129         base_reg_class.
25130         (ira_build_conflicts): Use base_reg_class instead of BASE_REG_CLASS.
25131         * Makefile.in: Add a dependency of ira-conflicts.o on addresses.h.
25132
25133 2009-01-13  Vladimir Makarov  <vmakarov@redhat.com>
25134
25135         PR target/38811
25136         * Makefile.in (ira-lives.o): Add except.h.
25137
25138         * ira-lives.c: Include except.h.
25139         (process_bb_node_lives): Process can_throw_internal.
25140
25141 2009-01-13  Jakub Jelinek  <jakub@redhat.com>
25142
25143         PR rtl-optimization/38774
25144         * combine.c (simplify_set): When undoing cc_use change, don't do
25145         PUT_CODE on the newly created comparison, but instead put back the
25146         old comparison.
25147
25148 2009-01-13  Joseph Myers  <joseph@codesourcery.com>
25149
25150         * doc/invoke.texi (ARM Options): Update lists of -mcpu and -march
25151         values.  Remove duplicate arm8 entry.
25152
25153 2009-01-13  Sebastian Pop  <sebastian.pop@amd.com>
25154
25155         PR tree-optimization/38786
25156         * graphite.c (expand_scalar_variables_ssa_name): New, outlined from
25157         the SSA_NAME case of expand_scalar_variables_expr.
25158         Set the type of an expression to the type of its assign statement.
25159         (expand_scalar_variables_expr): Also gather the scalar computation
25160         used to index the memory access.  Do not pass loop_p.
25161         Fix comment.  Stop recursion on tcc_constant or tcc_declaration.
25162         (expand_scalar_variables_stmt): Pass to expand_scalar_variables_expr
25163         the gimple_stmt_iterator where it inserts new code.
25164         Do not pass loop_p.
25165         (copy_bb_and_scalar_dependences): Do not pass loop_p.
25166         (translate_clast): Update call to copy_bb_and_scalar_dependences.
25167
25168 2009-01-13  Sebastian Pop  <sebastian.pop@amd.com>
25169
25170         * graphite.h (debug_value): Removed.
25171         * graphite.c (debug_value): Removed.
25172
25173 2009-01-13  Richard Earnshaw  <rearnsha@arm.com>
25174
25175         * config/arm/arm.c (output_move_double): Don't synthesize thumb-2
25176         ldrd/strd with two 32-bit instructions.
25177
25178 2009-01-13  Richard Earnshaw  <rearnsha@arm.com>
25179
25180         * config/arm/arm.c (struct processors): Pass for speed down into
25181         cost helper functions.
25182         (const_ok_for_op): Handle COMPARE and inequality nodes.
25183         (arm_rtx_costs_1): Rewrite.
25184         (arm_size_rtx_costs): Update prototype.
25185         (arm_rtx_costs): Pass speed down to helper functions.
25186         (arm_slowmul_rtx_costs): Rework cost calculations.
25187         (arm_fastmul_rtx_costs, arm_xscale_rtx_costs): Likewise.
25188         (arm_9e_rtx_costs): Likewise.
25189
25190 2009-01-13  Uros Bizjak  <ubizjak@gmail.com>
25191
25192         * config/alpha/alpha.c (alpha_legitimate_address_p): Explicit
25193         relocations of local symbols wider than UNITS_PER_WORD are not valid.
25194         (alpha_legitimize_address): Do not split local symbols wider than
25195         UNITS_PER_WORD into HIGH/LO_SUM parts.
25196
25197 2009-01-13  Danny Smith  <dannysmith@users.sourceforge.net>
25198
25199         PR bootstrap/38580
25200         * gcc.c (process_command): Replace call to execvp with calls
25201         to pex_one and exit.
25202
25203 2009-01-03  Anatoly Sokolov  <aesok@post.ru>
25204
25205         PR target/29141
25206         * config/avr/t-avr (LIB1ASMFUNCS): Add _tablejump_elpm.
25207         * config/avr/libgcc.S (__do_global_ctors, __do_global_dtors): Add
25208         variant for devices with 3-byte PC.
25209         (__tablejump_elpm__): New.
25210
25211 2009-01-12  Jakub Jelinek  <jakub@redhat.com>
25212
25213         PR c/32041
25214         * c-parser.c (c_parser_postfix_expression): Allow `->' in
25215         offsetof member-designator, handle it as `[0].'.
25216
25217 2009-01-12  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
25218
25219         * pa.c (pa_asm_output_mi_thunk): Use pc-relative branch to thunk
25220         function when not using named sections on targets with named sections
25221         if branch distance is less than 262132.
25222
25223 2009-01-12  Richard Earnshaw  <rearnsha@arm.com>
25224
25225         * combine.c (combine_instructions):  Recompute
25226         optimize_this_for_speed_p  for each BB in the main combine loop.
25227
25228 2009-01-12  Tomas Bily  <tbily@suse.cz>
25229
25230         PR middlend/38385
25231         * tree-loop-distribution.c (prop_phis): New function.
25232         (generate_builtin): Call prop_phis.
25233         * testsuite/gcc.dg/tree-ssa/pr38385.c: New file.
25234
25235 2009-01-12  Jakub Jelinek  <jakub@redhat.com>
25236
25237         PR tree-optimization/38807
25238         * tree-ssa-reassoc.c (remove_visited_stmt_chain): Don't look at
25239         gimple_visited_p unless stmt is GIMPLE_ASSIGN.
25240
25241 2009-01-11  Adam Nemet  <anemet@caviumnetworks.com>
25242
25243         * expmed.c (store_bit_field_1): Properly truncate the paradoxical
25244         subreg of op0 to the original op0.
25245
25246 2009-01-11  Laurent GUERBY  <laurent@guerby.net>
25247
25248         * doc/sourcebuild.texi (Source Tree): Move up intl and fixinc.
25249
25250 2009-01-11  Markus Schoepflin  <markus.schoepflin@comsoft.de>
25251
25252         PR debug/7055
25253         * mips-tfile.c (parse_def): Fix parsing of def strings
25254         starting with digits.
25255
25256 2009-01-10  Jakub Jelinek  <jakub@redhat.com>
25257
25258         PR target/38695
25259         * config/arm/arm.c (arm_is_long_call_p): Don't call
25260         arm_function_in_section_p if decl isn't a FUNCTION_DECL.
25261
25262 2009-01-09  Steven Bosscher  <steven@gcc.gnu.org>
25263
25264         * regrename.c (regrename_optimize): Fix dumping.
25265         (find_oldest_value_reg): Preserve REG_POINTER.
25266         (copy_hardreg_forward_1): Likewise.
25267
25268 2009-01-09  Diego Novillo  <dnovillo@google.com>
25269
25270         * gimple.h (struct gimple_statement_base) <uid>: Document
25271         the restrictions on its use.
25272         (gimple_uid): Tidy.
25273         (gimple_set_uid): Tidy.
25274
25275 2009-01-09  Jakub Jelinek  <jakub@redhat.com>
25276
25277         * config/i386/i386.c (ix86_expand_movmem, ix86_expand_setmem): Add
25278         zero guard even if align_bytes != 0 and count is smaller than
25279         size_needed.
25280
25281 2009-01-09  Vladimir Makarov  <vmakarov@redhat.com>
25282
25283         PR rtl-optimization/38495
25284         * ira-emit.c (print_move_list, ira_debug_move_list): New functions.
25285         (add_range_and_copies_from_move_list): Print all added ranges.
25286         Add ranges to memory optimized destination.
25287
25288 2009-01-09  Jakub Jelinek  <jakub@redhat.com>
25289
25290         PR target/38686
25291         PR target/38708
25292         * config/i386/i386.c (override_options): Reject
25293         -mstringop-strategy=rep_8byte with -m32.
25294         (ix86_expand_movmem): For size_needed == 1 set epilogue_size_needed
25295         to 1.  Do count comparison against epilogue_size_needed at compile
25296         time even when count_exp was constant forced into register.  For
25297         size_needed don't jump to epilogue, instead just avoid aligning
25298         and invoke the body algorithm.  If need_zero_guard, add zero guard
25299         even if count is non-zero, but smaller than size_needed + number of
25300         bytes that could be stored for alignment.
25301         (ix86_expand_setmem): For size_needed == 1 set epilogue_size_needed
25302         to 1.  If need_zero_guard, add zero guard even if count is non-zero,
25303         but smaller than size_needed + number of bytes that could be stored
25304         for alignment.  Compare size_needed with epilogue_size_needed instead
25305         of desired_align - align, don't adjust size_needed, pass
25306         epilogue_size_needed to the epilogue expanders.
25307
25308         PR c/35742
25309         * c-pretty-print.c (pp_c_expression): Handle GOTO_EXPR like BIND_EXPR.
25310
25311 2009-01-09  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
25312
25313         * pa.c (last_address): Change to unsigned.
25314         (update_total_code_bytes): Change argument to unsigned.  Don't
25315         check if insn addresses are set.
25316         (pa_output_function_epilogue): Set last_address to UINT_MAX if insn
25317         addresses are not set.
25318         (pa_asm_output_mi_thunk): Handle wrap when updating last_address.
25319
25320 2009-01-09  Nick Clifton  <nickc@redhat.com>
25321
25322         * config/sh/symbian.c: Replace uses of DECL_INLINE with
25323         DECL_DECLARED_INLINE_P.
25324
25325 2009-01-09  Jakub Jelinek  <jakub@redhat.com>
25326
25327         PR middle-end/38347
25328         * dojump.c (do_jump_by_parts_zero_rtx): Use mode instead of
25329         GET_MODE (op0) in operand_subword_force calls.
25330
25331         PR middle-end/38771
25332         * fold-const.c (fold_unary): For COMPOUND_EXPR and COND_EXPR,
25333         fold_convert arg0 operands to TREE_TYPE (op0) first.
25334
25335 2009-01-08  Vladimir Makarov  <vmakarov@redhat.com>
25336
25337         * params.def (ira-max-conflict-table-size): Decrease default value
25338         to 1000.
25339
25340 2009-01-08  Jakub Jelinek  <jakub@redhat.com>
25341
25342         PR tree-optimization/37031
25343         * lambda-code.c (lambda_collect_parameters): Call pointer_set_destroy
25344         on parameter_set.
25345         (build_access_matrix): Reserve correct size for AM_MATRIX vector,
25346         allocate it using gc instead of heap, use VEC_quick_push instead of
25347         VEC_safe_push.
25348         * graphite.c (build_access_matrix): Allocate AM_MATRIX vector using gc
25349         instead of heap, use VEC_quick_push instead of VEC_safe_push.
25350         * tree-data-ref.h (struct access_matrix): Change matrix to gc
25351         allocated vector from heap allocated.
25352         * lambda.h: Add DEF_VEC_ALLOC_P for gc allocated lambda_vector.
25353         * tree-loop-linear.c (linear_transform_loops): Allocate nest
25354         vector only after perfect_loop_nest_depth call.
25355
25356 2009-01-08  Sebastian Pop  <sebastian.pop@amd.com>
25357             Jan Sjodin  <jan.sjodin@amd.com>
25358
25359         PR tree-optimization/38559
25360         * graphite.c (debug_value, copy_constraint,
25361         swap_constraint_variables, scale_constraint_variable, ): New.
25362         (get_lower_bound, get_upper_bound): Removed.
25363         (graphite_trans_bb_strip_mine): Clean up this code that works
25364         only for constant number of iterations.  Fully copy upper and
25365         lower bound constraints, not only the constant part of them.
25366         * graphite.h (debug_value): Declared.
25367
25368 2009-01-08  Ira Rosen  <irar@il.ibm.com>
25369
25370         PR tree-optimization/37194
25371         * tree-vect-transform.c (vect_estimate_min_profitable_iters):
25372         Don't add the cost of cost model guard in prologue to scalar
25373         outside cost in case of known number of iterations.
25374
25375 2009-01-07  Nathan Froyd  <froydnj@codesourcery.com>
25376             Alan Modra  <amodra@bigpond.net.au>
25377
25378         * config/rs6000/rs6000.c (rs6000_legitimize_address): Check for
25379         non-word-aligned REG+CONST addressing.
25380
25381 2009-01-07  Uros Bizjak  <ubizjak@gmail.com>
25382
25383         PR target/38706
25384         * config/alpha/alpha.c (alpha_end_function): For TARGET_ABI_OSF, call
25385         free_after_compilation when outputting a thunk.
25386         (alpha_output_mi_thunk_osf): Assert that we are processing a thunk.
25387         Do not call free_after_compilation here.
25388
25389 2009-01-07  Uros Bizjak  <ubizjak@gmail.com>
25390
25391         * config/i386/i386.c (ix86_target_string): Use ARRAY_SIZE.
25392         (ix86_valid_target_attribute_inner_p): Ditto.
25393
25394 2009-01-07  Jan Sjodin  <jan.sjodin@amd.com>
25395
25396         PR tree-optimization/38492
25397         PR tree-optimization/38498
25398         * tree-check.c (operator_is_linear, scev_is_linear_expression): New.
25399         * tree-chrec.h (scev_is_linear_expression): Declared.
25400         * graphite.c (graphite_cannot_represent_loop_niter): New.
25401         (scopdet_basic_block_info): Call graphite_cannot_represent_loop_niter.
25402         (graphite_loop_normal_form): Use gcc_assert.
25403         (scan_tree_for_params): Use CASE_CONVERT.
25404         (phi_node_is_iv, bb_contains_non_iv_scalar_phi_nodes): New.
25405         (build_scop_conditions_1): Call bb_contains_non_iv_scalar_phi_nodes.
25406         Use gcc_assert.  Discard scops that contain unhandled cases.
25407         (build_scop_conditions): Return a boolean status for unhandled cases.
25408         (strip_mine_profitable_p): Print the loop number, not its depth.
25409         (is_interchange_valid): Pass the depth of the loop nest, don't
25410         recompute it wrongly.
25411         (graphite_trans_bb_block): Same.
25412         (graphite_trans_bb_block): Print tentative of loop blocking.
25413         (graphite_trans_scop_block): Do not print that the loop has been
25414         blocked.
25415         (graphite_transform_loops): Do not handle scops that contain condition
25416         scalar phi nodes.
25417
25418 2009-01-07  H.J. Lu  <hongjiu.lu@intel.com>
25419
25420         AVX Programming Reference (December, 2008)
25421         * config/i386/avxintrin.h (_mm256_stream_si256): New.
25422         (_mm256_stream_pd): Likewise.
25423         (_mm256_stream_ps): Likewise.
25424
25425         * config/i386/i386.c (ix86_builtins): Add IX86_BUILTIN_MOVNTDQ256,
25426         IX86_BUILTIN_MOVNTPD256 and IX86_BUILTIN_MOVNTPS256.
25427         (ix86_special_builtin_type): Add VOID_FTYPE_PV4DI_V4DI.
25428         (bdesc_special_args): Add __builtin_ia32_movntdq256,
25429         __builtin_ia32_movntpd256 and __builtin_ia32_movntps256.
25430         (ix86_init_mmx_sse_builtins): Handle VOID_FTYPE_PV4DI_V4DI.
25431         (ix86_expand_special_args_builtin): Likewise.
25432
25433         * config/i386/sse.md (AVXMODEDI): New.
25434         (avx_movnt<mode>): Likewise.
25435         (avx_movnt<mode>): Likewise.
25436         (<sse>_movnt<mode>): Remove AVX support.
25437         (sse2_movntv2di): Likewise.
25438
25439 2009-01-07  Richard Guenther  <rguenther@suse.de>
25440
25441         PR middle-end/38751
25442         * fold-const.c (extract_muldiv): Remove obsolete comment.
25443         (fold_plusminus_mult_expr): Undo MINUS_EXPR
25444         to PLUS_EXPR canonicalization for the canonicalization.
25445
25446 2009-01-07  Gerald Pfeifer  <gerald@pfeifer.com>
25447
25448         * doc/install.texi (alpha*-dec-osf*): Remove note on 32-bit
25449         hosted cross-compilers generating less efficient code.
25450
25451 2009-01-06  Richard Sandiford  <rdsandiford@googlemail.com>
25452
25453         * function.h (rtl_data): Add a dbr_scheduled_p field.
25454         * reorg.c (dbr_schedule): Set it.
25455         (gate_handle_delay_slots): Check it.
25456         * config/mips/mips.c (mips_base_delayed_branch): Delete.
25457         (mips_reorg): Check flag_delayed_branch instead of
25458         mips_base_delayed_branch.
25459         (mips_override_options): Don't set mips_base_delayed_branch
25460         or flag_delayed_branch.
25461
25462 2009-01-06  Richard Sandiford  <rdsandiford@googlemail.com>
25463
25464         PR rtl-optimization/38426.
25465         * ira.c (ira): Set current_function_is_leaf earlier.
25466
25467 2009-01-06  Jakub Jelinek  <jakub@redhat.com>
25468
25469         PR rtl-optimization/38722
25470         * combine.c (try_combine): Don't modify PATTERN (i3) and notes
25471         too early, only set a flag and modify after last possible
25472         undo_all point.
25473
25474 2009-01-06  Janis Johnson  <janis187@us.ibm.com>
25475
25476         PR c/34252
25477         * ginclude/float.h: Rename DECnn_DEN to DECnn_SUBNORMAL_MIN.
25478         * real.c (decimal_single_format): Correct values of emin and emax.
25479         (decimal_double_format): Ditto.
25480         (decimal_quad_format): Ditto.
25481         * c-cppbuiltin.c (builtin_define_decimal_float_constants): Adjust
25482         computation of DECnn_MIN and DECnn_MAX for corrected values of
25483         emin and emax.  Define __DECnn_SUBNORMAL_MIN__ instead of
25484         __DECnn_MIN__, and adjust its computation for the corrected value
25485         of emin.
25486
25487 2009-01-06  Jan Hubicka  <jh@suse.cz>
25488
25489         PR target/38744
25490         * config/i386/i386.c (ix86_expand_call): Use ARRAY_SIZE.
25491
25492 2009-01-06  Gerald Pfeifer  <gerald@pfeifer.com>
25493
25494         * doc/contrib.texi (Contributors): Slightly adjust the end note.
25495         Add Robert Clark to the list of testers.
25496
25497 2009-01-06  Jan Hubicka  <jh@suse.cz>
25498             Kai Tietz  <kai.tietz@onevision.com>
25499
25500         * config/i386/i386.md (*msabi_syvabi): Add SSE regs clobbers.
25501         * config/i386/i386.c (ix86_expand_call): Add clobbers.
25502
25503 2009-01-06  Jan Hubicka  <jh@suse.cz>
25504             Kai Tietz  <kai.tietz@onevision.com>
25505
25506         * config/i386/i386.h (CONDITIONAL_CALL_USAGE): SSE regs are not used
25507         for w64 ABI.
25508         * config/i386/i386.c (struct ix86_frame): Add padding0 and nsseregs.
25509         (ix86_nsaved_regs): Count only general purpose regs.
25510         (ix86_nsaved_sseregs): New.
25511         (ix86_compute_frame_layout): Update nsseregs; set preferred alignment
25512         to 16 for w64; compute padding and size of sse reg save area.
25513         (ix86_emit_save_regs, ix86_emit_save_regs_using_mov): Save only
25514         general purpose regs.
25515         (ix86_emit_save_sse_regs_using_mov): New.
25516         (ix86_expand_prologue): Save SSE regs if needed.
25517         (ix86_emit_restore_regs_using_mov): Use only general purpose regs.
25518         (ix86_emit_restore_sse_regs_using_mov): New.
25519         (ix86_expand_epilogue): Save SSE regs if needed.
25520
25521 2009-01-06  Jan Hubicka  <jh@suse.cz>
25522             Kai Tietz  <kai.tietz@onevision.com>
25523
25524         * config/i386/i386.h (ACCUMULATE_OUTGOING_ARGS): Enable for MSABI
25525         * config/i386/i386.c (init_cumulative_args): Disallow calls of MSABI
25526         functions when accumulate outgoing args is off.
25527
25528 2009-01-06  H.J. Lu  <hongjiu.lu@intel.com>
25529
25530         PR bootstrap/38742
25531         * ira-color.c (ira_reuse_stack_slot): Check ENABLE_IRA_CHECKING
25532         before using pseudos_have_intersected_live_ranges_p.
25533
25534         * ira-int.h (ira_assert): Always define.
25535
25536 2009-01-06  H.J. Lu  <hongjiu.lu@intel.com>
25537
25538         AVX Programming Reference (December, 2008)
25539         * config/i386/avxintrin.h (_mm_permute2_pd): Removed.
25540         (_mm256_permute2_pd): Likewise.
25541         (_mm_permute2_ps): Likewise.
25542         (_mm256_permute2_ps): Likewise.
25543         * config/i386/i386.md (UNSPEC_VPERMIL2): Likewise.
25544         * config/i386/sse.md (avx_vpermil2<mode>3): Likewise.
25545
25546         * config/i386/i386.c (ix86_builtins): Remove
25547         IX86_BUILTIN_VPERMIL2PD, IX86_BUILTIN_VPERMIL2PS,
25548         IX86_BUILTIN_VPERMIL2PD256 and IX86_BUILTIN_VPERMIL2PS256.
25549         (ix86_builtin_type): Remove V8SF_FTYPE_V8SF_V8SF_V8SI_INT,
25550         V4DF_FTYPE_V4DF_V4DF_V4DI_INT, V4SF_FTYPE_V4SF_V4SF_V4SI_INT
25551         and V2DF_FTYPE_V2DF_V2DF_V2DI_INT.
25552         (bdesc_args): Remove __builtin_ia32_vpermil2pd,
25553         __builtin_ia32_vpermil2ps, __builtin_ia32_vpermil2pd256 and
25554         __builtin_ia32_vpermil2ps256.
25555         (ix86_init_mmx_sse_builtins): Updated.
25556         (ix86_expand_args_builtin): Likewise.
25557
25558 2009-01-05  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
25559
25560         * pa.c (output_call): Relocate non-jump insns in the delay slot of
25561         long absolute calls when generating PA 2.0 code.
25562
25563 2009-01-05  Vladimir Makarov  <vmakarov@redhat.com>
25564
25565         PR rtl-optimization/38583
25566         * params.h (IRA_MAX_CONFLICT_TABLE_SIZE): New macro.
25567
25568         * params.def (ira-max-conflict-table-size): New.
25569
25570         * doc/invoke.texi (ira-max-conflict-table-size): Decribe.
25571
25572         * ira.h (ira_conflicts_p): New external definition.
25573
25574         * ira-conflicts.c (build_conflict_bit_table): Do not build too big
25575         table.  Report this.  Return result of building.
25576         (ira_build_conflicts): Use ira_conflicts_p.  Check result of
25577         building conflict table.
25578
25579         * ira-color.c (fast_allocation): Use num instead of ira_allocnos_num.
25580         (ira_color): Use ira_conflicts_p.
25581
25582         * global.c: Include ira.h.
25583         (pseudo_for_reload_consideration_p, build_insn_chain): Use
25584         ira_conflicts_p.
25585
25586         * Makefile.in (global.o): Add ira.h.
25587
25588         * ira-build.c (mark_all_loops_for_removal,
25589         propagate_some_info_from_allocno): New.
25590         (remove_unnecessary_allocnos): Call
25591         propagate_some_info_from_allocno.
25592         (remove_low_level_allocnos): New.
25593         (remove_unnecessary_regions): Add parameter.  Call
25594         mark_all_loops_for_removal and remove_low_level_allocnos.  Pass
25595         parameter to remove_unnecessary_regions.
25596         (ira_build): Remove all regions but root if the conflict table was
25597         not built.  Update conflict hard regs for allocnos crossing calls.
25598
25599         * ira.c (ira_conflicts_p): New global.
25600         (ira): Define and use ira_conflicts_p.
25601
25602         * reload1.c (compute_use_by_pseudos, reload, count_pseudo,
25603         count_spilled_pseudo, find_reg, alter_reg, finish_spills,
25604         emit_input_reload_insns, delete_output_reload): Use ira_conflicts_p.
25605
25606 2009-01-06  Ben Elliston  <bje@au.ibm.com>
25607
25608         * gengtype-lex.l (YY_NO_INPUT): Define.
25609
25610 2009-01-05  Andrew Pinski  <andrew_pinski@playstation.sony.com>
25611
25612         PR c/34911
25613         * c-common.c (handle_vector_size_attribute): Also reject
25614         BOOLEAN_TYPE types.
25615
25616 2009-01-05  Sebastian Pop  <sebastian.pop@amd.com>
25617
25618         PR tree-optimization/38492
25619         * graphite.c (rename_map_elt, debug_rename_elt,
25620         debug_rename_map_1, debug_rename_map, new_rename_map_elt,
25621         rename_map_elt_info, eq_rename_map_elts,
25622         get_new_name_from_old_name, bb_in_sese_p): Moved around.
25623         (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
25624         (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
25625         (sese_build_livein_liveouts): New.
25626         (new_sese, free_sese): New.
25627         (new_scop): Call new_sese.
25628         (free_scop): Call free_sese.
25629         (rename_variables_from_edge, rename_phis_end_scop): Removed.
25630         (register_old_new_names): Renamed register_old_and_new_names.
25631         (register_scop_liveout_renames, add_loop_exit_phis,
25632         insert_loop_close_phis, struct igp,
25633         default_liveout_before_guard, add_guard_exit_phis,
25634         insert_guard_phis, copy_renames): New.
25635         (translate_clast): Call insert_loop_close_phis and insert_guard_phis.
25636         (sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
25637         (rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
25638         (scop_adjust_phis_for_liveouts): New.
25639         (gloog): Call scop_adjust_phis_for_liveouts.
25640
25641         * graphite.h (struct sese): Documented.  Added fields liveout,
25642         num_ver and livein.
25643         (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
25644         (new_sese, free_sese, sese_build_livein_liveouts): Declared.
25645         (struct scop): Added field liveout_renames.
25646         (SCOP_LIVEOUT_RENAMES): New.
25647
25648 2009-01-05  Harsha Jagasia  <harsha.jagasia@amd.com>
25649
25650         PR tree-optimization/38510
25651         * graphite.c (recompute_all_dominators): Call mark_irreducible_loops.
25652         (translate_clast): Call recompute_all_dominators before
25653         graphite_verify.
25654         (gloog): Call recompute_all_dominators before graphite_verify.
25655
25656 2009-01-05  Harsha Jagasia  <harsha.jagasia@amd.com>
25657             Jan Sjodin  <jan.sjodin@amd.com>
25658
25659         PR tree-optimization/38500
25660         * graphite.c (create_sese_edges): Call fix_loop_structure after
25661         splitting blocks.
25662
25663 2009-01-05  Joel Sherrill  <joel.sherrill@oarcorp.com>
25664
25665         * config.gcc: Add m32r*-*-rtems*.
25666         * config/m32r/rtems.h: New file.
25667
25668 2009-01-05  Ben Elliston  <bje@au.ibm.com>
25669
25670         * Makefile.in (.po.gmo): Use mkinstalldirs, not test -d || mkdir.
25671         (.po.pox): Likewise.
25672         (po/gcc.pot): Likewise.
25673
25674 2009-01-04  David S. Miller  <davem@davemloft.net>
25675
25676         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED_RTX): Delete.
25677         (STARTING_FRAME_OFFSET): Always set to zero.
25678
25679 2009-01-04  Richard Sandiford  <rdsandiford@googlemail.com>
25680
25681         * tree.def (LSHIFT_EXPR, RSHIFT_EXPR): Add commentary.
25682         * tree-cfg.c (verify_gimple_assign_binary): Allow shifts of
25683         fixed-point types, and vectors of the same.
25684
25685 2009-01-04  Richard Sandiford  <rdsandiford@googlemail.com>
25686
25687         * config/mips/sync.md (*mb_barrier): Rename to...
25688         (*memory_barrier): ...this.
25689
25690 2009-01-04  Jonathan Wakely  <jwakely.gcc@gmail.com>
25691
25692         * doc/extend.texi (Function Attributes): Move @cindex after @item
25693         for 'artificial' and 'flatten'. Fix grammar for 'externally_visible'
25694         and put in alphabetical order. Fix 'target' name and put in order.
25695         * doc/invoke.texi (-Wstrict-null-sentinel, -fipa-matrix-reorg): Fix
25696         typos.
25697
25698 2009-01-04  Uros Bizjak  <ubizjak@gmail.com>
25699
25700         * config/s390/s390.md (UNSPEC_MB): Rename from UNSPECV_MB.
25701         (memory_barrier): Expand as unspec instead of unspec_volatile.
25702         Remove mem:BLK from insn operands.  Use Pmode scratch register.
25703         (*memory_barrier): Define as unspec instead of unspec_volatile.
25704         Use (match_dup 0) as input operand.
25705
25706         * config/sparc/sparc.md (UNSPEC_MEMBAR): Rename from UNSPECV_MEMBAR.
25707         * config/sparc/sync.md (memory_barrier): Expand as unspec instead of
25708         unspec_volatile.  Remove mem:BLK from insn operands.  Use Pmode
25709         scratch register.  Remove operand 1.
25710         (*stbar): Define as unspec instead of unspec_volatile.
25711         Use (match_dup 0) as input operand, remove (const_int 8).
25712         (*membar): Define as unspec instead of unspec_volatile.
25713         Use (match_dup 0) as input operand, remove input operand 2.
25714
25715         * config/xtensa/xtensa.md (UNSPEC_MEMW): Rename from UNSPECV_MEMW.
25716         (memory_barrier): Expand as unspec instead of unspec_volatile.
25717         Remove mem:BLK from insn operands.  Use Pmode scratch register.
25718         (*memory_barrier): Define as unspec instead of unspec_volatile.
25719         Use (match_dup 0) as input operand.
25720
25721         * config/ia64/sync.md (memory_barrier): Redefine as expander pattern.
25722         Remove mem:BLK from insn operands.  Use Pmode scratch register.
25723         Set volatile flag on operand 0.
25724         (*memory_barrier): New insn pattern.
25725
25726         * config/rs6000/sync.md (memory_barrier): Remove mem:BLK from
25727         insn operands.
25728         (*memory_barrier): Use (match_dup 0) as input operand.
25729
25730         * config/mips/sync.md (memory_barrier): Redefine as expander pattern.
25731         Remove mem:BLK from insn operands.  Use Pmode scratch register.
25732         Set volatile flag on operand 0.
25733         (*mb_internal): New insn pattern.
25734
25735         * config/alpha/sync.md (*memory_barrier): Rename from *mb_internal.
25736
25737 2009-01-04  Steven Bosscher  <steven@gcc.gnu.org>
25738
25739         PR middle-end/38586
25740         * function.c (struct temp_slot): Move to the section of the file
25741         that deals with temp slots.  Remove field 'address'.
25742         (temp_slot_address_table): New hash table of address -> temp slot.
25743         (struct temp_slot_address_entry): New struct, items for the table.
25744         (temp_slot_address_compute_hash, temp_slot_address_hash,
25745         temp_slot_address_eq, insert_temp_slot_address): Support functions
25746         for the new table.
25747         (find_temp_slot_from_address): Rewrite to use the new hash table.
25748         (remove_unused_temp_slot_addresses): Remove addresses of temp
25749         slots that have been made available.
25750         (remove_unused_temp_slot_addresses_1): Call-back for htab_traverse,
25751         worker function for remove_unused_temp_slot_addresses.
25752         (assign_stack_temp_for_type): Don't clear the temp slot address list.
25753         Add the temp slot address to the address -> temp slot map.
25754         (update_temp_slot_address): Update via insert_temp_slot_address.
25755         (free_temp_slots): Call remove_unused_temp_slot_addresses.
25756         (pop_temp_slots): Likewise.
25757         (init_temp_slots): Allocate the address -> temp slot map, or empty
25758         the map if it is already allocated.
25759         (prepare_function_start): Initialize temp slot processing.
25760
25761 2009-01-04  Steven Bosscher  <steven@gcc.gnu.org>
25762
25763         PR middle-end/38584
25764         * cfgexpand.c (estimate_stack_frame_size): Simplify the estimate:
25765         Calculate the size of all stack vars assuming no packing of stack
25766         vars will happen, replacing a quadratic algorithm with a linear one.
25767
25768 2009-01-03  Jakub Jelinek  <jakub@redhat.com>
25769
25770         PR target/38707
25771         * expmed.c (store_bit_field_1): Don't modify op0 if movstrict insn
25772         can't be used.
25773
25774 2009-01-03  Diego Novillo  <dnovillo@google.com>
25775
25776         * doc/contrib.texi: Update contributions.
25777
25778 2009-01-03  Jakub Jelinek  <jakub@redhat.com>
25779
25780         PR c++/38705
25781         * builtins.c (fold_builtin_memory_op): Give up if either operand
25782         is volatile.  Set srctype or desttype to non-qualified version
25783         of the other type.
25784
25785         PR c/38700
25786         * builtins.c (fold_builtin_expect): Only check DECL_WEAK for VAR_DECLs
25787         and FUNCTION_DECLs.
25788
25789 2009-01-02  Kenneth Zadeck  <zadeck@naturalbridge.com>
25790
25791         PR rtl-optimization/35805
25792         * df-problems.c (df_lr_finalize): Add recursive call to resolve lr
25793         problem if fast dce is able to remove any instructions.
25794         * dce.c (dce_process_block): Fix dump message.
25795
25796 2009-01-02  Mark Mitchell  <mark@codesourcery.com>
25797
25798         PR 33649
25799         * tree-ssa-pre.c (compute_antic): Correct loop bounds.
25800
25801 2009-01-02  Jakub Jelinek  <jakub@redhat.com>
25802
25803         PR middle-end/38690
25804         * tree-flow.h (op_code_prio, op_prio): New prototypes.
25805         * tree-pretty-print.c (op_code_prio): New function.
25806         (op_prio): No longer static.  Use op_code_prio.
25807         * gimple-pretty-print.c (dump_unary_rhs, dump_binary_rhs):
25808         Use op_prio and op_code_prio to determine if () should be
25809         printed around operand(s) or not.
25810
25811         * gimple-pretty-print.c (dump_unary_rhs, dump_binary_rhs,
25812         dump_gimple_call, dump_gimple_switch, dump_gimple_cond,
25813         dump_gimple_label, dump_gimple_try, dump_symbols, dump_gimple_phi,
25814         dump_gimple_mem_ops, dump_bb_header, dump_bb_end, pp_cfg_jump): Use
25815         pp_character instead of pp_string for single letter printing.
25816
25817 2009-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
25818
25819         * doc/extend.texi: Fix '#pragma GCC option' typo.
25820
25821 2009-01-02  Richard Guenther  <rguenther@suse.de>
25822
25823         * doc/install.texi (--enable-checking): Mention different
25824         default for stage1.
25825         (--enable-stage1-checking): Document.
25826
25827 2009-01-01  Andrew Pinski  <pinskia@gmail.com>
25828
25829         PR middle-end/30142
25830         * tree-cfg.c (verify_expr): Add INDIRECT_REF case.  Change MODIFY_EXPR
25831         case to be an error.
25832
25833 2009-01-02  Ben Elliston  <bje@au.ibm.com>
25834
25835         * config/fp-bit.h (pack_d): Constify argument.
25836         * config/fp-bit.c (makenan): Constify return type. Remove casts.
25837         (isnan): Constify argument.
25838         (isinf): Likewise.
25839         (iszero): Likewise.
25840         (pack_d): Likewise.
25841         (_fpadd_parts): Constify return type.
25842         (_fpmul_parts): Likewise.
25843         (_fpdiv_parts): Likewise.
25844
25845 2009-01-01  Jakub Jelinek  <jakub@redhat.com>
25846
25847         PR c/36489
25848         * c-typeck.c (add_pending_init): Add IMPLICIT argument.  Only
25849         warn about overwriting initializer with side-effects or
25850         -Woverride-init if !IMPLICIT.
25851         (output_init_element): Likewise.  Pass IMPLICIT down to
25852         add_pending_init.
25853         (process_init_element): Add IMPLICIT argument.  Pass it down
25854         to output_init_element.
25855         (push_init_element, pop_init_level, set_designator): Adjust
25856         process_init_element callers.
25857         (set_nonincremental_init, set_nonincremental_init_from_string):
25858         Adjust add_pending_init callers.
25859         (output_pending_init_elements): Adjust output_init_element callers.
25860         * c-tree.h (process_init_element): Adjust prototype.
25861         * c-parser.c (c_parser_initelt, c_parser_initval): Adjust
25862         process_init_element callers.
25863
25864 \f
25865 Copyright (C) 2009 Free Software Foundation, Inc.
25866
25867 Copying and distribution of this file, with or without modification,
25868 are permitted in any medium without royalty provided the copyright
25869 notice and this notice are preserved.