OSDN Git Service

f368de2bb5f43be0d37b250bafcdb114e6a7ea4c
[pf3gnuchains/gcc-fork.git] / gcc / ChangeLog
1 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
2
3         PR target/40017
4         * config/rs6000/rs6000-c.c (_Bool_keyword): New variable.
5         (altivec_categorize_keyword, init_vector_keywords,
6         rs6000_cpu_cpp_builtins): Define _Bool as conditional macro
7         similar to bool.
8
9 2009-05-29  Kai Tietz  <kai.tietz@onevision.com>
10
11         * tree.c (handle_dll_attribute): Check if node is
12         of kind FUNCTION_DECL for DECL_DECLARED_INLINE_P check.
13
14 2009-05-29  Richard Earnshaw  <rearnsha@arm.com>
15
16         * config/arm/thumb2.md (thumb2_zero_extendsidi2): Add a split
17         component.
18         (thumb2_zero_extendqidi2): Likewise.
19
20 2009-05-28  Kaz Kojima  <kkojima@gcc.gnu.org>
21
22         * config/sh/sh.c (sh_expand_t_scc): Use gen_xorsi3_movrt
23         instead of gen_movrt.
24         * config/sh/sh.md (movrt): Remove.
25
26 2009-05-28  Steve Ellcey  <sje@cup.hp.com>
27
28         * doc/invoke.texi (IA-64 Options)
29         Add -msdata, -mfused-madd, -mno-inline-float-divide, 
30         -mno-inline-int-divide, -mno-inline-sqrt, -msched-spec-ldc,
31         -msched-spec-control-ldc, -msched-prefer-non-data-spec-insns,
32         -msched-prefer-non-control-spec-insns,
33         -msched-stop-bits-after-every-cycle,
34         -msched-count-spec-in-critical-path,
35         -msel-sched-dont-check-control-spec, -msched-fp-mem-deps-zero-cost
36         -msched-max-memory-insns-hard-limit, -msched-max-memory-insns
37         Remove -mt, -pthread, -msched-ldc, -mno-sched-control-ldc,
38         and -msched-spec-verbose.
39
40 2009-05-28  Joseph Myers  <joseph@codesourcery.com>
41
42         * config/arm/lib1funcs.asm (__clear_cache): Define if
43         L_clear_cache.
44         * config/arm/linux-eabi.h (CLEAR_INSN_CACHE): Define to give an
45         error if used.
46         * config/arm/t-linux-eabi (LIB1ASMFUNCS): Add _clear_cache.
47
48 2009-05-28  Richard Guenther  <rguenther@suse.de>
49
50         * tree-ssa-alias.c (ao_ref_init): New function.
51         (ao_ref_base): Likewise.
52         (ao_ref_base_alias_set): Likewise.
53         (ao_ref_alias_set): Likewise.
54         (refs_may_alias_p_1): Change signature.
55         (refs_may_alias_p): Adjust.
56         (refs_anti_dependent_p): Likewise.
57         (refs_output_dependent_p): Likewise.
58         (call_may_clobber_ref_p_1): Change signature.
59         (call_may_clobber_ref_p): Adjust.
60         (stmt_may_clobber_ref_p_1): New function split out from ...
61         (stmt_may_clobber_ref_p): ... here.
62         (maybe_skip_until): Adjust signature.
63         (get_continuation_for_phi): Likewise.
64         (walk_non_aliased_vuses): Likewise.
65         * tree-ssa-alias.h (struct ao_ref_s): New structure type.
66         (ao_ref_init): Declare.
67         (ao_ref_base): Likewise.
68         (ao_ref_alias_set): Likewise.
69         (stmt_may_clobber_ref_p_1): Likewise.
70         (walk_non_aliased_vuses): Adjust.
71         * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): New function.
72         (get_ref_from_reference_ops): remove.
73         (vn_reference_lookup_2): Adjust signature.
74         (vn_reference_lookup_3): Do not re-build trees.  Handle unions.
75         (vn_reference_lookup_pieces): Adjust signature, do not re-build
76         trees.
77         (vn_reference_lookup): Adjust.
78         (vn_reference_insert): Likewise.
79         (vn_reference_insert_pieces): Adjust signature.
80         (visit_reference_op_call): Adjust.
81         * tree-ssa-pre.c (get_expr_type): Simplify.
82         (phi_translate_1): Adjust.
83         (compute_avail): Likewise.
84         (translate_vuse_through_block): Do not re-build trees.
85         (value_dies_in_block_x): Likewise.
86         * tree-ssa-sccvn.h (struct vn_reference_s): Add type and alias-set
87         fields.
88         (vn_reference_lookup_pieces): Adjust declaration.
89         (vn_reference_insert_pieces): Likewise.
90
91 2009-05-28  Benjamin Kosnik  <bkoz@redhat.com>
92
93         * tree-ssa-copy.c (replace_exp_1): Move op for warning-free use
94         with checking disabled.
95
96 2009-05-28  Dave Korn  <dave.korn.cygwin@gmail.com>
97
98         PR target/37216
99
100         * configure.ac (HAVE_GAS_ALIGNED_COMM):  Add autoconf test and
101         macro definition for support of three-operand format aligned
102         .comm directive in assembler on cygwin/pe/mingw target OS.
103         * configure:  Regenerate.
104         * config.h:  Regenerate.
105
106         * config/i386/winnt.c (i386_pe_asm_output_aligned_decl_common):  Use
107         aligned form of .comm directive if -mpe-aligned-commons is in effect.
108         * config/i386/cygming.opt (-mpe-aligned-commons):  Add new option.
109
110         * doc/invoke.texi (-mpe-aligned-commons):  Document new target option.
111         * doc/tm.texi (ASM_OUTPUT_COMMON):  Document zero size commons.
112
113 2009-05-28  Ira Rosen  <irar@il.ibm.com>
114
115         PR tree-optimization/40254
116         * tree-data-ref.c (dr_analyze_innermost): Take POFFSET into account
117         in analysis of basic blocks.
118
119 2009-05-28  Adam Nemet  <anemet@caviumnetworks.com>
120
121         PR middle-end/33699
122         * target.h (struct gcc_target): Fix indentation.  Add
123         const_anchor.
124         * target-def.h (TARGET_CONST_ANCHOR): New macro.
125         (TARGET_INITIALIZER): Use it.
126         * cse.c (CHEAPER): Move it up to the other macros.
127         (insert): Rename this ...
128         (insert_with_costs): ... to this.  Add cost parameters.  Update
129         function comment.
130         (insert): New function.  Call insert_with_costs.
131         (compute_const_anchors, insert_const_anchor, insert_const_anchors,
132         find_reg_offset_for_const, try_const_anchors): New functions.
133         (cse_insn): Call try_const_anchors.  Adjust cost of src_related
134         when using a const-anchor.  Call insert_const_anchors.
135         * config/mips/mips.c (mips_set_mips16_mode): Set
136         targetm.const_anchor.
137         * doc/tm.texi (Misc): Document TARGET_CONST_ANCHOR.
138
139 2009-05-28  Alexandre Oliva  <aoliva@redhat.com>
140
141         * tree-inline.c (remap_decls): Enable nonlocalized variables
142         when not optimizing.
143
144 2009-05-28  Alexandre Oliva  <aoliva@redhat.com>
145
146         * tree-ssa-live.c (remove_unused_locals): Skip when not optimizing.
147         Simplify other tests involving optimize.
148
149 2009-05-27  Tom Tromey  <tromey@redhat.com>
150
151         * unwind-dw2.c (_Unwind_DebugHook): New function.
152         (uw_install_context): Call _Unwind_DebugHook.
153
154 2009-05-27  Tom Tromey  <tromey@redhat.com>
155
156         * system.h (CONST_CAST2): Use C++ const_cast when compiled as C++
157
158 2009-05-27  Ian Lance Taylor  <iant@google.com>
159
160         * Makefile.in (LINKER, LINKER_FLAGS): Define.
161         (LINKER_FOR_BUILD, BUILD_LINKERFLAGS): Define.
162         (ALL_LINKERFLAGS): Define.
163         (xgcc$(exeext)): Change $(COMPILER) to $(LINKER).
164         (cpp$(exeext), cc1-dummy$(exeext), cc1$(exeext)): Likewise.
165         (collect2$(exeext), mips-tfile, mips-tdump): Likewise.
166         (gcov$(exeext), gcov-dump$(exeext)): Likewise.
167         (build/gen%$(build_exeext)): Change $(COMPILER_FOR_BUILD) to
168         $(LINKER_FOR_BUILD).
169         (build/gcov-iov$(build_exeext)): Likewise.
170
171 2009-05-27  Julian Brown  <julian@codesourcery.com>
172
173         * gcse.c (target.h): Include.
174         (can_assign_to_reg_without_clobbers_p): Check that the target allows
175         copy of argument to a pseudo register.
176
177 2009-05-27  Diego Novillo  <dnovillo@google.com>
178
179         * tree-ssa-live.c (dump_scope_block): Document arguments.
180         (dump_scope_blocks): Document.
181         (debug_scope_blocks): New.
182         * tree-flow.h (debug_scope_blocks): Declare.
183
184 2009-05-21  Denis Chertykov  <denisc@overta.ru>
185
186         * doc/contrib.texi (Contributors): add myself to the list.
187
188 2009-05-27  Olivier Hainque  <hainque@adacore.com>
189
190         * expr.c (target_align): New function.  Alignment the TARGET of an
191         assignment may be assume to have.
192         (highest_pow2_factor_for_target): Use it instead of relying on
193         immediate tree attributes of TARGET, not necessarily honored when
194         intermediate bitfields are involved.
195         
196 2009-05-27  H.J. Lu  <hongjiu.lu@intel.com>
197
198         PR target/40266
199         * config/i386/driver-i386.c (host_detect_local_cpu): Support
200         AVX, SSE4, AES, PCLMUL and POPCNT.
201
202 2009-05-27  Diego Novillo  <dnovillo@google.com>
203
204         * tree-pretty-print.c (dump_location): New.
205         (dump_generic_node): Call it.
206         Factor code to handle BLOCK nodes ...
207         (dump_block_node): ... here.
208
209 2009-05-27  Rafael Avila de Espindola  <espindola@google.com>
210
211         * Makefile.in (GCC_PLUGIN_H): New. Replace all uses of gcc-plugin.h with
212         it.
213         * doc/plugins.texi: Document that gcc-plugin.h must be the first to be
214         included.
215         * gcc-plugin.h: Include config.h and system.h.
216         (IN_GCC): Define if not defined.
217
218 2009-05-27  Hans-Peter Nilsson  <hp@axis.com>
219
220         PR middle-end/40249
221         * Makefile.in (CRTSTUFF_CFLAGS): Replace -fno-inline-functions
222         with -fno-inline.
223
224 2009-05-27  Shujing Zhao  <pearly.zhao@oracle.com>
225
226         * config/m32r/m32r.c: Use REG_P, MEM_P and CONST_INT_P where
227         applicable.
228         * config/m32r/m32r.h: Ditto.
229         * config/m32r/m32r.md: Ditto.
230         * config/m32r/predicates.md: Ditto.
231
232 2009-05-27  Alexandre Oliva  <aoliva@redhat.com>
233
234         * cgraph.c (dump_cgraph_node): Honor -fdump-noaddr.
235
236 2009-05-26  Basile Starynkevitch  <basile@starynkevitch.net>
237
238         * doc/plugins.texi
239         (Loading plugins): typo.
240         (Plugin callbacks): Documented PLUGIN_INFO, PLUGIN_GGC_START,
241         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS.
242         (Interacting with the GCC Garbage Collector): Added new section.
243         (Giving information about a plugin): Added new section for
244         PLUGIN_INFO.
245         * testsuite/gcc.dg/plugin/plugin.exp: Added ggcplug.c test plugin
246         with ggcplug-test-1.c for testing PLUGIN_GGC_MARKING etc...
247         * testsuite/gcc.dg/plugin/ggcplug-test-1.c: Added new file.
248         * testsuite/gcc.dg/plugin/ggcplug.c: Added new file.
249         * ggc.h (ggc_register_root_tab): Added declaration.
250         * gcc-plugin.h (PLUGIN_GGC_START, PLUGIN_GGC_MARKING)
251         (PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS): Added new events.
252         (register_callback): Improved comment in declaration.
253         * ggc-common.c (const_ggc_root_tab_t) Added new typedef for
254         vectors.
255         (extra_root_vec) Added static variable for dynamic roots
256         registration.
257         (ggc_register_root_tab) Added new routine.
258         (ggc_mark_roots) Added iteration inside extra_root_vec, and invoke
259         PLUGIN_GGC_MARKING event.
260         * ggc-zone.c: Include plugin.h.
261         (ggc_collect): Invoke PLUGIN_GGC_START & PLUGIN_GGC_END events.
262         * ggc-page.c: Include plugin.h.
263         (ggc_collect): Invoke PLUGIN_GGC_START & PLUGIN_GGC_END events.
264         * plugin.c (plugin_event_name): added names of PLUGIN_GGC_START,
265         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS
266         (register_callback): check lack of callbacks for
267         pseudo-events. Added handling of PLUGIN_REGISTER_GGC_ROOTS,
268         PLUGIN_GGC_START, PLUGIN_GGC_MARKING, PLUGIN_GGC_END.
269         (invoke_plugin_callbacks): Handle PLUGIN_GGC_START,
270         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS.
271         * Makefile.in (ggc-common.o, ggc-zone.o, ggc-page.o): Added
272         dependency on plugin.h.
273         (plugin.o): Added dependency on ggc.h...
274
275 2009-05-26  Richard Guenther  <rguenther@suse.de>
276
277         PR middle-end/40248
278         Revert
279         * expr.c (expand_expr_real_1): Avoid calling do_store_flag
280         with mismatched comparison modes.
281
282         * expr.c (expand_expr_real_1): Expand the operand of a
283         VIEW_CONVERT_EXPR in its natural mode.
284
285 2009-05-26  Ian Lance Taylor  <iant@google.com>
286
287         * Makefile.in (COMPILER, COMPILER_FLAGS): Define.
288         (COMPILER_FOR_BUILD, BUILD_COMPILERFLAGS): Define.
289         (ALL_COMPILERFLAGS): Define.
290         (.c.o, xgcc$(exeext), cpp$(exeext)): Use $(COMPILER).
291         (cc1-dummy$(exeext), cc1$(exeext)): Likewise.
292         (collect2$(exeext), collect2.o): Likewise.
293         (c-opts.o, c-cppbuiltin.o, c-pch.o, gcc.o, gccspec.o): Likewise.
294         (gcc-options.o, version.o, prefix.o, toplev.o): Likewise.
295         ($(out_object_file), mips-tfile, mips-tdump): Likewise.
296         (libbackend.o, intl.o, cppdefault.o): Likewise.
297         (gcov$(exeext), gcov-dump$(exeext)): Likewise.
298         (build/%.o): Use $(COMPILER_FOR_BUILD).
299         (build/gen%$(build_exeext)): Likewise.
300         (build/gcov-iov$(build_exeext)): LIkewise.
301         * config/t-darwin (darwin.o): Use $(COMPILER).
302         (darwin-c.o, darwin-f.o, darwin-driver.o): Likewise.
303         * config/t-sol2 (sol2-c.o): Likewise.
304         (sol2.o): Likewise.
305         * config/t-vxworks (vxworks.o): Likewise.
306         * config/x-darwin (host-darwin.o): Likewise.
307         * config/x-hpux (host-hpux.o): Likewise.
308         * config/x-linux (host-linux.o): Likewise.
309         * config/x-solaris (host-solaris.o): Likewise.
310         * config/alpha/x-alpha (driver-alpha.o): Likewise.
311         * config/arm/t-arm (arm-c.o): Likewise.
312         * config/arm/t-pe (pe.o): Likewise.
313         * config/arm/t-wince-pe (pe.o): Likewise.
314         * config/i386/t-cygming (winnt.o): Likewise.
315         (winnt-cxx.o, winnt-stubs.o, msformat-c.o): Likewise.
316         * config/i386/t-cygwin (cygwin1.o): Likewise.
317         (cygwin2.o): Likewise.
318         * config/i386/t-i386 (i386-c.o): Likewise.
319         * config/i386/t-interix (winnt.o): Likewise.
320         * config/i386/t-netware (netware.o): Likewise.
321         * config/i386/t-nwld (nwld.o): Likewise.
322         * config/i386/x-darwin (host-i386-darwin.o): Likewise.
323         * config/i386/x-i386 (driver-i386.o): Likewise.
324         * config/i386/x-cygwin (host-cygwin.o): Likewise.
325         * config/i386/x-mingw32 (host-mingw32.o): Likewise.
326         * config/ia64/t-ia64 (ia64-c.o): Likewise.
327         * config/m32c/t-m32c (m32c-pragma.o): Likewise.
328         * config/mips/x-native (driver-native.o): Likewise.
329         * config/rs6000/t-rs6000 (rs6000-c.o): Likewise.
330         * config/rs6000/x-darwin (host-ppc-darwin.o): Likewise.
331         * config/rs6000/x-darwin64 (host-ppc64-darwin.o): Likewise.
332         * config/rs6000/x-rs6000 (driver-rs6000.o): Likewise.
333         * config/score/t-score-elf (score7.o): Likewise.
334         (score3.o): Likewise.
335         * config/sh/t-sh (sh-c.o): Likewise.
336         * config/sh/t-symbian (sh-c.o): Likewise.
337         (symbian.o): Likewise.
338         * config/spu/t-spu-elf (spu-c.o): Likewise.
339         * config/v850/t-v850 (v850-c.o): Likewise.
340         * config/v850/t-v850e (v850-c.o): Likewise.
341
342 2009-05-26  Richard Guenther  <rguenther@suse.de>
343
344         PR tree-optimization/40122
345         * tree-ssa-ccp.c (ccp_fold): Fold vector CONSTRUCTORs to
346         VECTOR_CSTs if possible.
347         (fold_gimple_assign): Likewise.
348
349 2009-05-26  Richard Guenther  <rguenther@suse.de>
350
351         PR middle-end/40252
352         * fold-const.c (fold_binary): Use the correct types for building
353         rotates.
354
355 2009-05-26  Richard Guenther  <rguenther@suse.de>
356
357         * tree-vect-data-refs.c (vect_create_data_ref_ptr): Remove
358         redundant calls to merge_alias_info.
359         (bump_vector_ptr): Likewise.
360         * tree-ssa-copy.c (merge_alias_info): Remove.
361         (replace_exp_1): Remove call to merge_alias_info.
362         (propagate_tree_value): Likewise.
363         (fini_copy_prop): Propagate points-to info.
364         * tree-flow.h (merge_alias_info): Remove.
365
366 2009-05-07  Hariharan Sandanagobalane <hariharan@picochip.com>
367
368         * config/picochip/picochip.C (PARAM_INLINE_CALL_COST): Remove.
369
370 2009-05-25  Jan Hubicka  <jh@suse.cz>
371
372         * cgraph.c (dump_cgraph_node): Dump size/time/benefit.
373         * cgraph.h (struct inline_summary): New filed self_wize,
374         size_inlining_benefit, self_time and time_inlining_benefit.
375         (struct cgraph_global_info): Replace insns by time ans size fields.
376         * ipa-cp (ipcp_cloning_candidate_p): Base estimate on size
377         (ipcp_estimate_growth, ipcp_insert_stage): Likewise.
378         (ipcp_update_callgraph): Do not touch function bodies.
379         * ipa-inline.c: Include except.h
380         (MAX_TIME): New constant.
381         (overall_insns): Remove.
382         (leaf_node_p): New.
383         (overall_size, max_benefit): New static variables.
384         (cgraph_estimate_time_after_inlining): New function.
385         (cgraph_estimate_size_after_inlining): Rewrite using benefits.
386         (cgraph_clone_inlined_nodes): Update size.
387         (cgraph_mark_inline_edge): Update size.
388         (cgraph_estimate_growth): Use size info.
389         (cgraph_check_inline_limits): Check size.
390         (cgraph_default_inline_p): Likewise.
391         (cgraph_edge_badness): Compute badness based on benefit and size cost.
392         (cgraph_decide_recursive_inlining): Check size.
393         (cgraph_decide_inlining_of_small_function): Update size; dump sizes and
394         times.
395         (cgraph_decide_inlining): Likewise.
396         (cgraph_decide_inlining_incrementally): Likewise; honor
397         PARAM_EARLY_INLINING_INSNS.
398         (likely_eliminated_by_inlining_p): New predicate.
399         (estimate_function_body_sizes): New function.
400         (compute_inline_parameters): Use it.
401         * except.c (must_not_throw_labels): New function.
402         * except.h (must_not_throw_labels): Declare.
403         * tree-inline.c (init_inline_once): Kill inlining_weigths
404         * tree-ssa-structalias.c: Avoid uninitialized warning.
405         * params.def (PARAM_MAX_INLINE_INSNS_SINGLE): Reduce to 300.
406         (PARAM_MAX_INLINE_INSNS_AUTO): Reduce to 60.
407         (PARAM_INLINE_CALL_COST): Remove.
408         (PARAM_EARLY_INLINING_INSNS): New.
409
410 2009-05-25  Richard Guenther  <rguenther@suse.de>
411
412         PR tree-optimization/36327
413         * tree-ssa-alias.c (walk_non_aliased_vuses): Add second walker
414         callback for reference translation or lookup at the point
415         of may-defs.
416         * tree-ssa-alias.h (walk_non_aliased_vuses): Adjust prototype.
417         * tree-ssa-sccvn.c (get_ref_from_reference_ops): Bail out
418         for union COMPONENT_REFs.
419         (vn_reference_lookup_3): New callback.  Lookup from memset
420         and CONSTRUCTOR assignment, translate through struct copies.
421         (vn_reference_lookup_pieces): Make sure to not free the
422         passed operands array.  Adjust walk_non_aliased_vuses call.
423         (vn_reference_lookup): Adjust walk_non_aliased_vuses call,
424         make sure we do not leak memory.
425
426 2009-05-25  Richard Guenther  <rguenther@suse.de>
427
428         * tree-ssa-alias.h (dump_points_to_solution): Declare.
429         * tree-inline.c (expand_call_inline): Reset the escaped and
430         callused solutions.
431         * tree-ssa-structalias.c (pass_build_ealias): New.
432         * tree-pass.h (pass_build_ealias): Declare.
433         * passes.c (init_optimization_passes): Add PTA during 
434         early optimizations.
435         * tree-ssa-alias.c (dump_alias_info): Dump the ESCAPED
436         and CALLUSED solutions.
437         (dump_points_to_solution): New function, split out from ...
438         (dump_points_to_info_for): ... here.
439         * tree-parloops.c (parallelize_loops): Reset the escaped and
440         callused solutions.
441
442 2009-05-25  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
443
444         PR bootstrap/40027
445         * config/i386/i386.c (USE_HIDDEN_LINKONCE): Only define if missing.
446         * config/i386/sol2.h [!TARGET_GNU_LD] (USE_HIDDEN_LINKONCE): Define.
447
448 2009-05-25  Ira Rosen  <irar@il.ibm.com>
449
450         PR tree-optimization/40238
451         * tree-vect-stmts.c (vect_init_vector): Insert initialization
452         statements after basic block's labels.
453         * tree-vect-slp.c (vect_slp_transform_bb): Call destroy_bb_vec_info() 
454         to free the allocated memory.
455
456 2009-05-24  Kaz Kojima  <kkojima@gcc.gnu.org>
457
458         * gcc/config/sh/sh.c (sh_set_return_address): Mark store of
459         return address with a USE.
460
461 2009-05-24  Richard Guenther  <rguenther@suse.de>
462
463         PR middle-end/40233
464         * tree.c (make_vector_type): Build the TYPE_DEBUG_REPRESENTATION_TYPEs
465         array type from the main variant of the inner type.
466
467 2009-05-24  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
468
469         * config/vax/vax-protos.h (legitimate_constant_address_p): Change
470         definition to bool (from int) to un-break build.
471         (legitimate_constant_p, vax_mode_dependent_address_p): Likewise.
472
473 2009-05-24  Paolo Bonzini  <bonzini@gnu.org>
474
475         * tree-ssa-operands.h (push_stmt_changes, pop_stmt_changes,
476         discard_stmt_changes): Delete.
477         * tree-ssa-operands.c (scb_stack): Delete.
478         (init_ssa_operands): Do not initialize it.
479         (fini_ssa_operands): Do not free it.
480         (push_stmt_changes, pop_stmt_changes, discard_stmt_changes): Delete.
481
482         * tree-cfg.c (replace_uses_by): Replace pop_stmt_changes with 
483         update_stmt, remove the others.  Fix comments.
484         * tree-dfa.c (optimize_stack_restore): Likewise.
485         * tree-ssa-forwprop.c (forward_propagate_addr_expr): Likewise.
486         * tree-ssa-loop-ivopts.c (rewrite_use): Likewise.
487         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Likewise.
488         * tree-ssa-ccp.c (optimize_stack_restore, execute_fold_all_builtins):
489         Likewise.
490         * tree-ssa-propagate.c (substitute_and_fold): Likewise.
491         * tree-ssa-dom.c (propagate_rhs_into_lhs): Likewise.
492         (dom_opt_finalize_block): Likewise, adjusting access to stmts_to_rescan.
493         (optimize_stmt): Likewise, adjusting access to stmts_to_rescan.
494         (stmts_to_rescan): Change item type to gimple.
495         (tree_ssa_dominator_optimize): Change type of stmts_to_rescan.
496
497 2009-05-24  Ira Rosen  <irar@il.ibm.com>
498
499         * doc/passes.texi (Tree-SSA passes): Document SLP pass.
500         * tree-pass.h (pass_slp_vectorize): New pass.
501         * params.h (SLP_MAX_INSNS_IN_BB): Define.
502         * timevar.def (TV_TREE_SLP_VECTORIZATION): Define.
503         * tree-vectorizer.c (timevar.h): Include.
504         (user_vect_verbosity_level): Declare.
505         (vect_location): Fix comment.
506         (vect_set_verbosity_level): Update user_vect_verbosity_level
507         instead of vect_verbosity_level.
508         (vect_set_dump_settings): Add an argument. Ignore user defined
509         verbosity if dump flags require higher level of verbosity. Print to
510         stderr only for loop vectorization.
511         (vectorize_loops): Update call to vect_set_dump_settings.
512         (execute_vect_slp): New function.
513         (gate_vect_slp): Likewise.
514         (struct gimple_opt_pass pass_slp_vectorize): New.
515         * tree-vectorizer.h (struct _bb_vec_info): Define along macros to
516         access its members.
517         (vec_info_for_bb): New function.
518         (struct _stmt_vec_info): Add bb_vinfo and a macro for its access.
519         (VECTORIZATION_ENABLED): New macro.
520         (SLP_ENABLED, SLP_DISABLED): Likewise.
521         (vect_is_simple_use): Add bb_vec_info argument.
522         (new_stmt_vec_info, vect_analyze_data_ref_dependences,
523         vect_analyze_data_refs_alignment, vect_verify_datarefs_alignment,
524         vect_analyze_data_ref_accesses, vect_analyze_data_refs,
525         vect_schedule_slp, vect_analyze_slp): Likewise.
526         (vect_analyze_stmt): Add slp_tree argument.
527         (find_bb_location): Declare.
528         (vect_slp_analyze_bb, vect_slp_transform_bb): Likewise.
529         * tree-vect-loop.c (new_loop_vec_info): Adjust function calls.
530         (vect_analyze_loop_operations, vect_analyze_loop,
531         get_initial_def_for_induction, vect_create_epilog_for_reduction,
532         vect_finalize_reduction, vectorizable_reduction,
533         vectorizable_live_operation, vect_transform_loop): Likewise.
534         * tree-data-ref.c (dr_analyze_innermost): Update comment,
535         skip evolution analysis if analyzing a basic block.
536         (dr_analyze_indices): Likewise.
537         (initialize_data_dependence_relation): Skip the test whether the
538         object is invariant for basic blocks.
539         (compute_all_dependences): Skip dependence analysis for data
540         references in basic blocks.
541         (find_data_references_in_stmt): Don't fail in case of invariant
542         access in basic block.
543         (find_data_references_in_bb): New function.
544         (find_data_references_in_loop): Move code to
545         find_data_references_in_bb and add a call to it.
546         (compute_data_dependences_for_bb): New function.
547         * tree-data-ref.h (compute_data_dependences_for_bb): Declare.
548         * tree-vect-data-refs.c (vect_check_interleaving): Adjust to the case
549         that STEP is 0.
550         (vect_analyze_data_ref_dependence): Check for interleaving in case of
551         unknown dependence in basic block and fail in case of dependence in
552         basic block.
553         (vect_analyze_data_ref_dependences): Add bb_vinfo argument, get data
554         dependence instances from either loop or basic block vectorization
555         info.
556         (vect_compute_data_ref_alignment): Check if it is loop vectorization
557         before calling nested_in_vect_loop_p.
558         (vect_compute_data_refs_alignment): Add bb_vinfo argument, get data
559         dependence instances from either loop or basic block vectorization
560         info.
561         (vect_verify_datarefs_alignment): Likewise.
562         (vect_enhance_data_refs_alignment): Adjust function calls.
563         (vect_analyze_data_refs_alignment): Likewise.
564         (vect_analyze_group_access): Fix printing. Skip different checks if
565         DR_STEP is 0. Keep strided stores either in loop or basic block
566         vectorization data structure. Fix indentation.
567         (vect_analyze_data_ref_access): Fix comments, allow zero step in
568         basic blocks.
569         (vect_analyze_data_ref_accesses): Add bb_vinfo argument, get data
570         dependence instances from either loop or basic block vectorization
571         info.
572         (vect_analyze_data_refs): Update comment. Call
573         compute_data_dependences_for_bb to analyze basic blocks.
574         (vect_create_addr_base_for_vector_ref): Check for outer loop only in
575         case of loop vectorization. In case of basic block vectorization use
576         data-ref itself as a base.
577         (vect_create_data_ref_ptr): In case of basic block vectorization:
578         don't advance the pointer, add new statements before the current
579         statement.  Adjust function calls.
580         (vect_supportable_dr_alignment): Support only aligned accesses in
581         basic block vectorization.
582         * common.opt (ftree-slp-vectorize): New flag.
583         * tree-vect-patterns.c (widened_name_p): Adjust function calls.
584         (vect_pattern_recog_1): Likewise.
585         * tree-vect-stmts.c (process_use): Likewise.
586         (vect_init_vector): Add new statements in the beginning of the basic
587         block in case of basic block SLP.
588         (vect_get_vec_def_for_operand): Adjust function calls.
589         (vect_finish_stmt_generation): Likewise.
590         (vectorizable_call): Add assert that it is loop vectorization, adjust
591         function calls.
592         (vectorizable_conversion, vectorizable_assignment): Likewise.
593         (vectorizable_operation): In case of basic block SLP, take
594         vectorization factor from statement's type and skip the relevance
595         check. Adjust function calls.
596         (vectorizable_type_demotion): Add assert that it is loop
597         vectorization, adjust function calls.
598         (vectorizable_type_promotion): Likewise.
599         (vectorizable_store): Check for outer loop only in case of loop
600         vectorization. Adjust function calls. For basic blocks, skip the
601         relevance check and don't advance pointers.
602         (vectorizable_load): Likewise.
603         (vectorizable_condition): Add assert that it is loop vectorization,
604         adjust function calls.
605         (vect_analyze_stmt): Add argument. In case of basic block SLP, check
606         that it is not reduction, get vector type, call only supported
607         functions, skip loop specific parts.
608         (vect_transform_stmt): Check for outer loop only in case of loop
609         vectorization.
610         (new_stmt_vec_info): Add new argument and initialize bb_vinfo.
611         (vect_is_simple_use): Fix comment, add new argument, fix conditions
612         for external definition.
613         * passes.c (pass_slp_vectorize): New pass.
614         * tree-vect-slp.c (find_bb_location): New function.
615         (vect_get_and_check_slp_defs): Add argument, adjust function calls,
616         check for patterns only in loops.
617         (vect_build_slp_tree): Add argument, adjust function calls, fail in
618         case of multiple types in basic block SLP.
619         (vect_mark_slp_stmts_relevant): New function.
620         (vect_supported_load_permutation_p): Fix comment.
621         (vect_analyze_slp_instance): Add argument. In case of basic block
622         SLP, take vectorization factor from statement's type, check that
623         unrolling factor is 1. Adjust function call. Save SLP instance in
624         either loop or basic block vectorization structure. Return FALSE,
625         if SLP failed.
626         (vect_analyze_slp): Add argument. Get strided stores groups from
627         either loop or basic block vectorization structure. Return FALSE
628         if basic block SLP failed.
629         (new_bb_vec_info): New function.
630         (destroy_bb_vec_info, vect_slp_analyze_node_operations,
631         vect_slp_analyze_operations, vect_slp_analyze_bb): Likewise.
632         (vect_schedule_slp): Add argument. Get SLP instances from either
633         loop or basic block vectorization structure. Set vectorization factor
634         to be 1 for basic block SLP.
635         (vect_slp_transform_bb): New function.
636         * params.def (PARAM_SLP_MAX_INSNS_IN_BB): Define.
637
638 2009-05-23  Mark Mitchell  <mark@codesourcery.com>
639
640         * final.c (shorten_branches): Do not align labels for jump tables.
641         (final_scan_insn): Use JUMP_TABLE_DATA_P.
642
643 2009-05-23  Eric Botcazou  <ebotcazou@adacore.com>
644
645         * doc/passes.texi: Standardize spelling of RTL, Tree and Tree SSA.
646         Remove outdated reference to flow.c and fix nits.
647         * doc/gccint.texi: Tweak RTL description.
648         * doc/rtl.texi: Likewise.
649
650 2009-05-23  Denis Chertykov  <chertykov@gmail.com>
651
652         * config/avr/avr.c: Change my email address.
653         * config/avr/avr.h: Likewise.
654         * config/avr/avr.md: Likewise.
655         * config/avr/avr-protos.h: Likewise.
656         * config/avr/libgcc.S: Likewise.
657
658 2009-05-22  Trevor Smigiel <Trevor_Smigiel@playstation.sony.com>
659
660         * config/spu/spu-protos.h (aligned_mem_p, spu_valid_mov): Remove.
661         (spu_split_load, spu_split_store): Change return type to int.
662         (spu_split_convert): Declare.
663         * config/spu/predicates.md (spu_mem_operand): Remove.
664         (spu_mov_operand): Update.
665         (spu_dest_operand, shiftrt_operator, extend_operator): Define.
666         * config/spu/spu.c (regno_aligned_for_load): Remove.
667         (reg_aligned_for_addr, spu_expand_load): Define.
668         (spu_expand_extv): Reimplement and handle MEM.
669         (spu_expand_insv): Handle MEM.
670         (spu_sched_reorder): Handle insn's with length 0.
671         (spu_legitimate_address_p): Reimplement.
672         (store_with_one_insn_p): Return TRUE for any mode with size
673         larger than 16 bytes.
674         (address_needs_split): Define.
675         (spu_expand_mov): Call spu_split_load and spu_split_store for MEM
676         operands.
677         (spu_convert_move): Define.
678         (spu_split_load): Use spu_expand_load and change all MEM's to TImode.
679         (spu_split_store): Change all MEM's to TImode.
680         (spu_init_expanders): Preallocate registers that correspond to
681         LAST_VIRTUAL_REG+1 and LAST_VIRTUAL_REG+2 and set them with
682         mark_reg_pointer.
683         (spu_split_convert): Define.
684         * config/spu/spu.md (QHSI, QHSDI): New mode iterators.
685         (_move<mode>, _movdi, _movti): Update predicate and condition.
686         (load, store): Change to define_split.
687         (extendqiti2, extendhiti2, extendsiti2, extendditi2): Simplify to
688         extend<mode>ti2.
689         (zero_extendqiti2, zero_extendhiti2, <v>lshr<mode>3_imm): Define.
690         (lshr<mode>3, lshr<mode>3_imm, lshr<mode>3_re): Simplify to one
691         define_insn_and_split of lshr<mode>3.
692         (shrqbybi_<mode>, shrqby_<mode>): Simplify to define_expand.
693         (<v>ashr<mode>3_imm): Define.
694         (extv, extzv, insv): Allow MEM operands.
695         (trunc_shr_ti<mode>, trunc_shr_tidi, shl_ext_<mode>ti,
696         shl_ext_diti, sext_trunc_lshr_tiqisi, zext_trunc_lshr_tiqisi,
697         sext_trunc_lshr_tihisi, zext_trunc_lshr_tihisi): Define for combine.
698         (_spu_convert2): Change to define_insn_and_split and remove the
699         corresponding define_peephole2.
700         (stack_protect_set, stack_protect_test, stack_protect_test_si):
701         Change predicates to memory_operand.
702
703 2009-05-22  Mark Mitchell  <mark@codesourcery.com>
704
705         * config/arm/thumb2.md: Add 16-bit multiply instructions.
706
707 2009-05-21  Michael Meissner  <meissner@linux.vnet.ibm.com>
708
709         PR tree-optimization/40219
710         * tree.c (iterative_hash_expr): Make sure the builtin function is
711         a normal builtin function and not a front end or back end builtin
712         before indexing into the built_in_decls array.
713
714 2009-05-22  Richard Guenther  <rguenther@suse.de>
715
716         PR middle-end/38964
717         * alias.c (write_dependence_p): Do not use TBAA for answering
718         anti-dependence or output-dependence.
719         * tree-ssa-structalias.c (set_uids_in_ptset): Remove TBAA pruning code.
720         (emit_pointer_definition): Remove.
721         (emit_alias_warning): Likewise.
722         (find_what_var_points_to): Remove TBAA pruning code.
723         (find_what_p_points_to): Likewise.  Do not warn about strict-aliasing
724         violations.
725         (compute_points_to_sets): Remove code computing the set of
726         dereferenced pointers.
727         * tree-data-ref.c (dr_may_alias_p): Properly use the split
728         oracle for querying anti and output dependencies.
729         * tree-ssa-alias.c (refs_may_alias_p_1): Add argument specifying
730         if TBAA may be applied.
731         (refs_anti_dependent_p): New function.
732         (refs_output_dependent_p): Likewise.
733         * tree-ssa-alias.h (refs_anti_dependent_p): Declare.
734         (refs_output_dependent_p): Likewise.
735         * doc/tree-ssa.texi (Memory model): New section.
736         * doc/c-tree.texi (CHANGE_DYNAMIC_TYPE_EXPR): Remove.
737         * doc/gimple.texi (GIMPLE_CHANGE_DYNAMIC_TYPE): Remove.
738         * cfgexpand.c (expand_gimple_basic_block): Do not handle
739         GIMPLE_CHANGE_DYNAMIC_TYPE or CHANGE_DYNAMIC_TYPE_EXPR.
740         * expr.c (expand_expr_real_1): Likewise.
741         * gimple-low.c (lower_stmt): Likewise.
742         * gimple-pretty-print.c (dump_gimple_stmt): Likewise.
743         (dump_gimple_cdt): Remove.
744         * gimple.c (gss_for_code): Do not handle GIMPLE_CHANGE_DYNAMIC_TYPE.
745         (gimple_size): Likewise.
746         (walk_gimple_op): Likewise.
747         (is_gimple_stmt): Likewise.
748         (walk_stmt_load_store_addr_ops): Likewise.
749         (gimple_build_cdt): Remove.
750         * gimple.def (GIMPLE_CHANGE_DYNAMIC_TYPE): Remove.
751         * gimple.h (gimple_cdt_new_type): Remove.
752         (gimple_cdt_new_type_ptr): Likewise.
753         (gimple_cdt_set_new_type): Likewise.
754         (gimple_cdt_location): Likewise.
755         (gimple_cdt_location_ptr): Likewise.
756         (gimple_cdt_set_location): Likewise.
757         * gimplify.c (gimplify_expr): Do not handle CHANGE_DYNAMIC_TYPE_EXPR.
758         * tree-cfg.c (remove_useless_stmts_1): Do not handle
759         GIMPLE_CHANGE_DYNAMIC_TYPE.
760         (verify_types_in_gimple_stmt): Likewise.
761         * tree-inline.c (estimate_num_insns): Likewise.
762         (expand_call_inline): Do not copy DECL_NO_TBAA_P.
763         (copy_decl_to_var): Likewise.
764         (copy_result_decl_to_var): Likewise.
765         * tree-pretty-print.c (dump_generic_node): Do not handle
766         CHANGE_DYNAMIC_TYPE_EXPR.
767         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
768         * tree-ssa-operands.c (get_expr_operands): Likewise.
769         * tree-ssa-structalias.c (struct variable_info): Remove
770         no_tbaa_pruning member.
771         (new_var_info): Do not set it based on DECL_NO_TBAA_P.
772         (unify_nodes): Do not copy it.
773         (find_func_aliases): Do not handle GIMPLE_CHANGE_DYNAMIC_TYPE.
774         (dump_solution_for_var): Do not dump no_tbaa_pruning state.
775         (set_uids_in_ptset): Do not check it.
776         (find_what_var_points_to): Likewise.
777         (compute_tbaa_pruning): Remove.
778         (compute_points_to_sets): Do not call it.
779         * tree.c (walk_tree_1): Do not handle CHANGE_DYNAMIC_TYPE_EXPR.
780         * tree.def (CHANGE_DYNAMIC_TYPE_EXPR): Remove.
781         * tree.h (CHANGE_DYNAMIC_TYPE_NEW_TYPE): Remove.
782         (CHANGE_DYNAMIC_TYPE_LOCATION): Likewise.
783         (DECL_NO_TBAA_P): Likewise.
784         (struct tree_decl_common): Move no_tbaa_flag to unused flags section.
785         * omp-low.c (copy_var_decl): Do not copy DECL_NO_TBAA_P.
786         (expand_omp_atomic_pipeline): Do not set it.
787         * print-tree.c (print_node): Do not dump it.
788         * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Remove
789         redundant check.
790
791 2009-05-22 Vladimir Makarov <vmakarov@redhat.com>
792
793         PR target/39856
794         * reg-stack.c (subst_stack_regs_pat): Remove gcc_assert for note
795         for clobber.
796
797 2009-05-22  Mark Mitchell  <mark@codesourcery.com>
798
799         * tree.c (handle_dll_attribute): Mark dllexport'd inlines as
800         non-external.
801
802 2009-05-22  Ben Elliston  <bje@au.ibm.com>
803
804         * Makefile.in (bversion.h, s-bversion): New targets.
805         (TOPLEV_H): Add bversion.h.
806         * toplev.h: Include "bversion.h".
807         (ATTRIBUTE_GCC_DIAG): When building with checking disabled, use
808         the __format__ attribute only if compiling with the same version
809         of GCC as the sources (the "build version").
810
811 2009-05-22  Ben Elliston  <bje@au.ibm.com>
812
813         * c-format.c (handle_format_attribute): Fix comment typo.
814
815 2009-05-21  Steve Ellcey  <sje@cup.hp.com>
816
817         PR target/37846
818         * config/ia64/ia64.opt (mfused-madd): New.
819         * config/ia64/ia64.h (TARGET_DEFAULT): Set MASK_FUSED_MADD.
820         * config/ia64/hpux.h (TARGET_DEFAULT): Ditto.
821         * config/ia64/ia64.md (maddsf4, msubsf4, nmaddsf4,
822         madddf4, madddf4_trunc, msubdf4, msubdf4_trunc, nmadddf4,
823         nmadddf4_truncsf, maddxf4, maddxf4_truncsf, maddxf4_truncdf,
824         msubxf4, msubxf4_truncsf msubxf4_truncdf, nmaddxf4,
825         nmaddxf4_truncsf, nmaddxf4_truncdf): Check TARGET_FUSED_MADD.
826         * config/ia64/vect.md (addv2sf3, subv2sf3): Force fpma/fpms 
827         instruction if !TARGET_FUSED_MADD.
828         (fpma, fpms): Remove colon from name.
829
830 2009-05-22  Richard Guenther  <rguenther@suse.de>
831
832         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Record
833         TMR_ORIGINAL.  Always either record TMR_SYMBOL or TMR_BASE.
834         * tree-ssa-pre.c (create_component_ref_by_pieces_1): Handle
835         TARGET_MEM_REF.
836         (create_expression_by_pieces): Only convert if necessary.
837         * gimplify.c (gimplify_expr): Handle TARGET_MEM_REF.
838         * tree-ssa-loop-im.c (gen_lsm_tmp_name): Handle INTEGER_CST.
839
840 2009-05-21  Adam Nemet  <anemet@caviumnetworks.com>
841
842         * config/mips/mips.md (*extzv_trunc<mode>_exts): Turn into a
843         regular pattern from a template and rename it ...
844         (*extzv_truncsi_exts): ... to this.
845
846 2009-05-21  Richard Guenther  <rguenther@suse.de>
847
848         * cgraph.h (struct cgraph_node): Remove inline_decl member.
849         * ipa-inline.c (cgraph_mark_inline_edge): Do not check it.
850         (cgraph_default_inline_p): Likewise.
851         (cgraph_decide_inlining_incrementally): Likewise.
852
853 2009-05-21  H.J. Lu  <hongjiu.lu@intel.com>
854             Uros Bizjak  <ubizjak@gmail.com>
855
856         * config/i386/cpuid.h (bit_MOVBE): New.
857
858         * config/i386/driver-i386.c (host_detect_local_cpu): Check movbe.
859
860         * config/i386/i386.c (OPTION_MASK_ISA_MOVBE_SET): New.
861         (OPTION_MASK_ISA_MOVBE_UNSET): Likewise.
862         (ix86_handle_option): Handle OPT_mmovbe.
863         (ix86_target_string): Add -mmovbe.
864         (pta_flags): Add PTA_MOVBE.
865         (processor_alias_table): Add PTA_MOVBE to "atom".
866         (override_options): Handle PTA_MOVBE.
867
868         * config/i386/i386.h (TARGET_MOVBE): New.
869
870         * config/i386/i386.md (bswapsi2): Check TARGET_MOVBE.
871         (*bswapsi_movbe): New.
872         (*bswapdi_movbe): Likewise.
873         (bswapdi2): Renamed to ...
874         (*bswapdi_1): This.
875         (bswapdi2): New expander.
876
877         * config/i386/i386.opt (mmovbe): New.
878
879         * doc/invoke.texi: Document -mmovbe.
880
881 2009-05-21  Taras Glek  <tglek@mozilla.com>
882
883         * plugin.c (try_init_one_plugin): Updated to new plugin_init API.
884         * gcc-plugin.h (plugin_init): Updated signature.
885         * gcc-plugin.h (plugin_name_args): Moved to this header.
886         * doc/plugins.texi (plugin_init): Updated documention to reflect
887         API change.
888         * doc/plugins.texi (plugin_name_args): Added to documention.
889
890 2009-05-21  Mark Mitchell  <mark@codesourcery.com>
891
892         * config/arm/neon.md (*mul<mode>3add<mode>_neon): New pattern.
893         (*mul<mode>3neg<mode>add<mode>_neon): Likewise.
894
895 2009-05-21  Shujing Zhao  <pearly.zhao@oracle.com>
896
897         * config/i386/i386.c: Use REG_P, MEM_P, CONST_INT_P, LABEL_P and
898         JUMP_TABLE_DATA_P predicates where applicable.
899         * config/i386/predicates.md: Ditto.
900         * config/i386/sse.md: Ditto.
901
902 2009-05-21  Jakub Jelinek  <jakub@redhat.com>
903
904         * config/i386/i386.md (adddi_4_rex64, addsi_4, addhi_4): For
905         operand2 -128 override length_immediate attribute to 1.
906         * config/i386/predicates.md (constm128_operand): New predicate.
907
908         * config/i386/i386.c (memory_address_length): Handle %r12
909         the same as %rsp and %r13 the same as %rbp.  For %rsp and %rbp
910         also check REGNO.
911         (ix86_attr_length_address_default): For MODE_SI lea in 64-bit
912         mode look through optional ZERO_EXTEND and SUBREG.
913         * config/i386/i386.md (R12_REG): New define_constant.
914         (prefix_data16): For sse unit set also for MODE_TI insns.
915         (prefix_rex): For -m32 always return 0.  For TYPE_IMOVX
916         insns set if operand 1 is ext_QIreg_operand.
917         (modrm): For TYPE_IMOV clear only if not MODE_DI.  For
918         TYPE_{ALU{,1},ICMP,TEST} insn clear if there is non-shortened
919         immediate.
920         (*movdi_extzv_1, zero_extendhidi2, zero_extendqidi2): Change
921         mode from MODE_DI to MODE_SI.
922         (movdi_1_rex64): Override modrm and length_immediate attributes
923         only for movabs (TYPE_IMOV, alternative 2).
924         (zero_extendsidi2_rex64): Clear prefix_0f attribute if TYPE_IMOVX.
925         (*float<SSEMODEI24:mode><MODEF:mode>2_mixed_interunit,
926         *float<SSEMODEI24:mode><MODEF:mode>2_mixed_nointerunit,
927         *float<SSEMODEI24:mode><MODEF:mode>2_sse_interunit,
928         *float<SSEMODEI24:mode><MODEF:mode>2_sse_nointerunit): Set
929         prefix_rex attribute if DImode.
930         (*adddi_1_rex64, *adddi_2_rex64, *adddi_3_rex64, *adddi_5_rex64,
931         *addsi_1, *addsi_1_zext, *addsi_2, *addsi_2_zext, *addsi_3,
932         *addsi_3_zext, *addsi_5, *addhi_1_lea, *addhi_1, *addhi_2, *addhi_3,
933         *addhi_5, *addqi_1_lea, *addqi_1): Override length_immediate
934         attribute to 1 if TYPE_ALU and operand 2 is const128_operand.
935         (pro_epilogue_adjust_stack_1, pro_epilogue_adjust_stack_rex64):
936         Likewise.  For TYPE_IMOV clear length_immediate attribute.
937         (*ashldi3_1_rex64, *ashldi3_cmp_rex64, *ashldi3_cconly_rex64,
938         *ashlsi3_1, *ashlsi3_1_zext, *ashlsi3_cmp, **ashlsi3_cconly,
939         *ashlsi3_cmp_zext, *ashlhi3_1_lea, *ashlhi3_1, *ashlhi3_cmp,
940         *ashlhi3_cconly, *ashlqi3_1_lea, *ashlqi3_1, *ashlqi3_cmp,
941         *ashlqi3_cconly): Override length_immediate attribute to 0 if TYPE_ALU
942         or one operand TYPE_ISHIFT.
943         (*ashrdi3_1_one_bit_rex64, *ashrdi3_one_bit_cmp_rex64,
944         *ashrdi3_one_bit_cconly_rex64, *ashrsi3_1_one_bit,
945         *ashrsi3_1_one_bit_zext, *ashrsi3_one_bit_cmp,
946         *ashrsi3_one_bit_cconly, *ashrsi3_one_bit_cmp_zext,
947         *ashrhi3_1_one_bit, *ashrhi3_one_bit_cmp, *ashrhi3_one_bit_cconly,
948         *ashrqi3_1_one_bit, *ashrqi3_1_one_bit_slp, *ashrqi3_one_bit_cmp,
949         *ashrqi3_one_bit_cconly, *lshrdi3_1_one_bit_rex64,
950         *lshrdi3_cmp_one_bit_rex64, *lshrdi3_cconly_one_bit_rex64,
951         *lshrsi3_1_one_bit, *lshrsi3_1_one_bit_zext, *lshrsi3_one_bit_cmp,
952         *lshrsi3_one_bit_cconly, *lshrsi3_cmp_one_bit_zext,
953         *lshrhi3_1_one_bit, *lshrhi3_one_bit_cmp, *lshrhi3_one_bit_cconly,
954         *lshrqi3_1_one_bit, *lshrqi3_1_one_bit_slp, *lshrqi2_one_bit_cmp,
955         *lshrqi2_one_bit_cconly, *rotlsi3_1_one_bit_rex64, *rotlsi3_1_one_bit,
956         *rotlsi3_1_one_bit_zext, *rotlhi3_1_one_bit, *rotlqi3_1_one_bit_slp,
957         *rotlqi3_1_one_bit, *rotrdi3_1_one_bit_rex64, *rotrsi3_1_one_bit,
958         *rotrsi3_1_one_bit_zext, *rotrhi3_one_bit, *rotrqi3_1_one_bit,
959         *rotrqi3_1_one_bit_slp): Override length_immediate attribute to 0,
960         set mode attribute, don't override length attribute.
961         (*btsq, *btrq, *btcq, *btdi_rex64, *btsi): Set prefix_0f attribute
962         to 1.
963         (return_internal_long): Set length attribute to 2 instead of 1.
964         (*strmovqi_rex_1, *strsetqi_rex_1, *rep_stosqi_rex64,
965         *cmpstrnqi_nz_rex_1, *cmpstrnqi_rex_1, *strlenqi_rex_1): Clear
966         prefix_rex attribute.
967         * config/i386/predicates.md (ext_QIreg_operand, const128_operand):
968         New predicates.
969         (memory_displacement_only_operand): Always return 0 for TARGET_64BIT.
970
971 2009-05-21  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
972
973         * config/arm/thumb2.md (orsi_notsi_si): Fix typo in pattern.
974
975 2009-05-20  Ian Lance Taylor  <iant@google.com>
976
977         * tree.c (build_tree_list_vec_stat): New function.
978         (ctor_to_vec): New function.
979         (build_nt_call_vec): New function.
980         (build_call_array): Change args to be a const pointer.
981         (build_call_vec): New function.
982         * tree.h (build_nt_call_vec): Declare.
983         (build_tree_list_vec_stat): Declare.
984         (build_tree_list_vec): Define.
985         (build_call_array): Update declaration.
986         (build_call_vec): Declare.
987         (ctor_to_vec): Declare.
988         * c-common.c (tree_vector_cache): New static variable.
989         (make_tree_vector): New function.
990         (release_tree_vector): New function.
991         (make_tree_vector_single): New function.
992         (make_tree_vector_copy): New function.
993         * c-common.h (tree_vector_cache, make_tree_vector): Declare.
994         (make_tree_vector_single, make_tree_vector_copy): Declare.
995         * c-parser.c (cached_expr_list_1, cached_expr_list_2): Remove.
996         (c_parser_expr_list): Don't manage cache here, instead call
997         make_tree_vector.
998         (c_parser_release_expr_list): Remove static function.
999         (c_parser_vec_to_tree_list): Remove static function.
1000         (c_parser_attributes): Call build_tree_list_vec instead of
1001         c_parser_vec_to_tree_list.  Call release_tree_vector instead of
1002         c_parser_release_expr_list.
1003         (c_parser_postfix_expression_after_primary): Likewise.
1004         (c_parser_objc_keywordexpr): Likewise.
1005
1006 2009-05-20  Sandra Loosemore  <sandra@codesourcery.com>
1007
1008         * doc/tm.texi (Misc): Document TARGET_INVALID_PARAMETER_TYPE,
1009         TARGET_INVALID_RETURN_TYPE, TARGET_PROMOTED_TYPE, and
1010         TARGET_CONVERT_TO_TYPE.
1011         * hooks.c (hook_tree_const_tree_null): Define.
1012         * hooks.h (hook_tree_const_tree_null): Declare.
1013         * target.h (struct gcc_target):  Add invalid_parameter_type,
1014         invalid_return_type, promoted_type, and convert_to_type fields.
1015         * target-def.h: (TARGET_INVALID_PARAMETER_TYPE): Define.
1016         (TARGET_INVALID_RETURN_TYPE): Define.
1017         (TARGET_PROMOTED_TYPE): Define.
1018         (TARGET_CONVERT_TO_TYPE): Define.
1019         (TARGET_INITIALIZER): Update for new fields.
1020         * c-decl.c (grokdeclarator): Check targetm.invalid_return_type.
1021         (grokparms): Check targetm.invalid_parameter_type.
1022         * c-typeck.c (default_conversion): Check targetm.promoted_type.
1023         * c-convert.c (convert): Check targetm.convert_to_type.
1024
1025 2009-05-20  Adam Nemet  <anemet@caviumnetworks.com>
1026
1027         * config/mips/mips.md (*extenddi_truncate<mode>,
1028         *extendsi_truncate<mode>): Emit exts if supported.  Add attribute
1029         defintions.
1030         (*extendhi_truncateqi): New define_insn_and_sptit.
1031
1032 2009-05-20  Jakub Jelinek  <jakub@redhat.com>
1033
1034         PR middle-end/40204
1035         * fold-const.c (fold_binary) <case BIT_AND_EXPR>: Avoid infinite
1036         recursion if build_int_cst_type returns the same INTEGER_CST as arg1.
1037
1038 2009-05-20  Eric Botcazou  <ebotcazou@adacore.com>
1039
1040         * fold-const.c (build_fold_addr_expr_with_type): Take the address of
1041         the operand of VIEW_CONVERT_EXPR.
1042
1043 2009-05-20  H.J. Lu  <hongjiu.lu@intel.com>
1044
1045         * config/i386/driver-i386.c (host_detect_local_cpu): Check
1046         extended family and model for Intel processors.  Support Intel
1047         Atom.
1048
1049 2009-05-20  Olivier Hainque  <hainque@adacore.com>
1050
1051         * gstab.h (stab_code_type): Define, to be used instead of the
1052         __stab_debug_code enum, made anonymous.  Add 2009 to the copyright
1053         notice.
1054         * dbxout.c (STAB_CODE_TYPE): Remove #define and replace use
1055         occurrences by stab_code_type.
1056         * mips-tfile.c (STAB_CODE_TYPE): Remove #define, unused.
1057
1058 2009-05-20  Martin Jambor  <mjambor@suse.cz>
1059
1060         * tree-flow.h (insert_edge_copies_seq): Undeclare.
1061         (sra_insert_before): Likewise.
1062         (sra_insert_after): Likewise.
1063         (sra_init_cache): Likewise.
1064         (sra_type_can_be_decomposed_p): Likewise.
1065         * tree-mudflap.c (insert_edge_copies_seq): Copied here from tree-sra.c
1066         * tree-sra.c (sra_type_can_be_decomposed_p): Made static.
1067         (sra_insert_before): Likewise.
1068         (sra_insert_after): Likewise.
1069         (sra_init_cache): Likewise.
1070         (insert_edge_copies_seq): Made static and moved upwards.
1071
1072         * tree-complex.c (extract_component): Added VIEW_CONVERT_EXPR switch
1073         case.
1074
1075         * tree-flow-inline.h (contains_view_convert_expr_p): New function.
1076
1077         * ipa-prop.c (get_ssa_def_if_simple_copy): New function.
1078         (determine_cst_member_ptr): Call get_ssa_def_if_simple_copy to skip
1079         simple copies.
1080
1081 2009-05-20  Richard Guenther  <rguenther@suse.de>
1082
1083         * expr.c (expand_expr_real_1): Avoid calling do_store_flag
1084         with mismatched comparison modes.
1085
1086 2009-05-20  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
1087
1088         * config/arm/arm.md (*arm_iorsi3): Refactored for only ARM.
1089         (peephole ior (reg, int) -> mov, ior): Refactored for only ARM.
1090         * config/arm/thumb2.md (*thumb_andsi_not_shiftsi_si): Allow bic
1091         with shifts for Thumb2.
1092         (orsi_notsi): New for orn.
1093         (*thumb_orsi_notshiftsi_si): Allow orn with shifts.
1094         (*thumb2_iorsi3): Rewrite support for iorsi for Thumb2.
1095         * config/arm/arm.c (const_ok_for_op): Split case for IOR for Thumb2.
1096         (arm_gen_constant): Set can_invert for IOR and Thumb2, Add comments.
1097         Don't invert remainder for IOR.
1098         
1099 2009-05-19  Zdenek Dvorak  <ook@ucw.cz>
1100
1101         PR tree-optimization/40087
1102         * tree-ssa-loop-niter.c (number_of_iterations_ne_max,
1103         number_of_iterations_ne): Rename never_infinite argument.
1104         (number_of_iterations_lt_to_ne, number_of_iterations_lt,
1105         number_of_iterations_le): Handle pointer-type ivs when
1106         exit_must_be_taken is false.
1107         (number_of_iterations_cond):  Do not always assume that
1108         exit_must_be_taken if the control variable is a pointer.
1109
1110 2009-05-19  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1111
1112         * c-typeck.c (build_binary_op): Allow % on integal vectors.
1113         * doc/extend.texi (Vector Extension): Document that % is allowed too.
1114
1115 2009-05-19  H.J. Lu  <hongjiu.lu@intel.com>
1116
1117         * config/i386/i386.c (ix86_avoid_jump_mispredicts): Check
1118         ASM_OUTPUT_MAX_SKIP_PAD instead of ASM_OUTPUT_MAX_SKIP_ALIGN.
1119
1120 2009-05-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1121
1122         PR c/40172
1123         * c.opt (Wlogical-op): Disabled by default.
1124         * c-opt (c_common_post_options): Do not enable Wlogical-op with
1125         Wextra.
1126         * doc/invoke.texi (Wlogical-op): Likewise.
1127         
1128 2009-05-19  Eric Botcazou  <ebotcazou@adacore.com>
1129
1130         * tree-scalar-evolution.c (follow_ssa_edge_expr) <NOP_EXPR>: Turn
1131         into CASE_CONVERT.
1132         <PLUS_EXPR>: Strip useless type conversions instead of type nops.
1133         Propagate the type of the first operand.
1134         <ASSERT_EXPR>: Simplify.
1135         (follow_ssa_edge_in_rhs): Use gimple_expr_type to get the type.
1136         Rewrite using the RHS code as discriminant.
1137         <NOP_EXPR>: Turn into CASE_CONVERT.
1138         <PLUS_EXPR>: Propagate the type of the first operand.
1139
1140 2009-05-19  Steve Ellcey  <sje@cup.hp.com>
1141
1142         * config/ia64/ia64-protos.h (ia64_dconst_0_5): New.
1143         (ia64_dconst_0_375): New.
1144         * config/ia64/ia64.c (ia64_override_options): Remove
1145         -minline-sqrt-min-latency warning.
1146         (ia64_dconst_0_5_rtx, ia64_dconst_0_5): New.
1147         (ia64_dconst_0_375_rtx, ia64_dconst_0_375): New
1148         * config/ia64/ia64.md (*sqrt_approx): Remove.
1149         (sqrtsf2): Remove #if 0.
1150         (sqrtsf2_internal_thr): Rewrite and move to div.md.
1151         (sqrtdf): Remove assert.
1152         (sqrtdf2_internal_thr): Rewrite and move to div.md.
1153         (sqrtxf2): Remove #if 0.
1154         (sqrtxf2_internal_thr): Rewrite and move to div.md.
1155         * div.md (sqrt_approx_rf): New.
1156         (sqrtsf2_internal_thr): New implementation.
1157         (sqrtsf2_internal_lat): New.
1158         (sqrtdf2_internal_thr: New implementation.
1159         (sqrtxf2_internal): New implementation.
1160
1161 2009-05-19  Francois-Xavier Coudert  <fxcoudert@gmail.com>
1162             Hans-Peter Nilsson  <hp@axis.com>
1163
1164         * defaults.h (UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE)
1165         (WCHAR_TYPE, MODIFIED_WCHAR_TYPE, PTRDIFF_TYPE, WINT_TYPE)
1166         (INTMAX_TYPE, UINTMAX_TYPE, SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE)
1167         (INT32_TYPE, INT64_TYPE, UINT8_TYPE, UINT16_TYPE, UINT32_TYPE)
1168         (UINT64_TYPE, INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE)
1169         (INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE)
1170         (UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE)
1171         (INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE)
1172         (UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE)
1173         (SIZE_TYPE, PID_TYPE, CHAR16_TYPE, CHAR32_TYPE): Move defaults here...
1174         * c-common.c: ...from here.
1175
1176 2009-05-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1177
1178         * c-common.c (warn_logical_operator): Remove unnecessary
1179         conditionals.
1180
1181 2009-05-19  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
1182
1183         * builtins.c (do_mpc_arg1): Separate MPFR/MPC C rounding types.
1184
1185 2009-05-19  Ben Elliston  <bje@au.ibm.com>
1186
1187         * unwind-dw2-fde.c (fde_unencoded_compare): Replace type punning
1188         assignments with memcpy calls.
1189         (add_fdes): Likewise.
1190         (binary_search_unencoded_fdes): Likewise.
1191         (linear_search_fdes): Eliminate type puns.
1192         
1193 2009-05-19  Richard Guenther  <rguenther@suse.de>
1194
1195         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Do
1196         not falsely claim to have propagated into all uses.
1197
1198 2009-05-19  Ben Elliston  <bje@au.ibm.com>
1199
1200         * doc/invoke.texi (C Dialect Options): Update OpenMP specification
1201         version to v3.0.
1202
1203 2009-05-18  Kaz Kojima  <kkojima@gcc.gnu.org>
1204
1205         * config/sh/sh-protos.h (sh_legitimate_address_p): Remove.
1206         * config/sh/sh.c (sh_legitimate_address_p): Make static.
1207         (TARGET_LEGITIMATE_ADDRESS_P): New.
1208         * config/sh/sh.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1209         * config/sh/sh.md: Clean up references to GO_IF_LEGITIMATE_ADDRESS.
1210         
1211 2009-05-18  Dodji Seketeli  <dodji@redhat.com>
1212
1213         PR debug/40109
1214         * dwarf2out.c (gen_type_die_with_usage): Generate the DIE as a
1215         child of the containing namespace's DIE.
1216
1217 2009-05-18  Adam Nemet  <anemet@caviumnetworks.com>
1218
1219         * config/mips/mips.md (*zero_extend<GPR:mode>_trunc<SHORT:mode>,
1220         *zero_extendhi_truncqi):  Move after the zero_extend patterns.
1221         (*extenddi_truncate<mode>, *extendsi_truncate<mode>): Move after the
1222         extend patterns.
1223
1224 2009-05-18  H.J. Lu  <hongjiu.lu@intel.com>
1225
1226         PR target/39942
1227         * config/i386/i386.c (ix86_avoid_jump_misspredicts): Replace
1228         gen_align with gen_pad.
1229         (ix86_reorg): Check ASM_OUTPUT_MAX_SKIP_PAD instead of
1230         #ifdef ASM_OUTPUT_MAX_SKIP_ALIGN.
1231
1232         * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): New.
1233         * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
1234
1235         * config/i386/i386.md (align): Renamed to ...
1236         (pad): This.  Replace ASM_OUTPUT_MAX_SKIP_ALIGN with
1237         ASM_OUTPUT_MAX_SKIP_PAD.
1238
1239 2009-05-18  Andreas Schwab  <schwab@linux-m68k.org>
1240
1241         * config.gcc: Fix variable syntax.
1242
1243         PR target/39531
1244         * config/m68k/m68k.c (output_andsi3): Mask off sign bit copies
1245         before calling exact_log2.
1246         (output_iorsi3): Likewise.
1247         (output_xorsi3): Likewise.
1248
1249 2009-05-18  Kaz Kojima  <kkojima@gcc.gnu.org>
1250
1251         * config/sh/sh.c (expand_cbranchdi4): Use a scratch register
1252         for the none zero constant operand except for EQ and NE
1253         comprisons even when the first operand is R0.
1254
1255 2009-05-18  Andreas Krebbel  <krebbel1@de.ibm.com>
1256
1257         * config/s390/2064.md: Remove trailing whitespaces.
1258         * config/s390/2084.md: Likewise.
1259         * config/s390/constraints.md: Likewise.
1260         * config/s390/fixdfdi.h: Likewise.
1261         * config/s390/libgcc-glibc.ver: Likewise.
1262         * config/s390/s390-modes.def: Likewise.
1263         * config/s390/s390-protos.h: Likewise.
1264         * config/s390/s390.c: Likewise.
1265         * config/s390/s390.h: Likewise.
1266         * config/s390/s390.md: Likewise.
1267         * config/s390/tpf-unwind.h: Likewise.
1268
1269 2009-05-18  Maxim Kuvyrkov  <maxim@codesourcery.com>
1270
1271         * config/m68k/m68k.c (m68k_legitimize_address): Fix typo in signature.
1272
1273 2009-05-18  Maxim Kuvyrkov  <maxim@codesourcery.com>
1274
1275         M68K TLS support.
1276         * configure.ac (m68k-*-*): Check if binutils support TLS.
1277         * configure: Regenerate.
1278         * config/m68k/predicates.md (symbolic_operand): Extend comment.
1279         * config/m68k/constraints.md (Cu): New constraint.
1280         * config/m68k/m68k.md (UNSPEC_GOTOFF): Remove.
1281         (UNSPEC_RELOC16, UNSPEC_RELOC32): New constants.
1282         (movsi): Handle TLS symbols.
1283         (addsi3_5200): Handle XTLS symbols, indent.
1284         * config/m68k/m68k-protos.h (m68k_legitimize_tls_address): Declare.
1285         (m68k_tls_reference_p): Declare.
1286         (m68k_legitimize_address): Declare.
1287         (m68k_unwrap_symbol): Declare.
1288         * config/m68k/m68k.opt (mxtls): New option.
1289         * config/m68k/m68k.c (ggc.h): Include.
1290         (m68k_output_dwarf_dtprel): Implement hook.
1291         (TARGET_HAVE_TLS, TARGET_ASM_OUTPUT_DWARF_DTPREL): Define.
1292         (m68k_expand_prologue): Load GOT pointer when function needs it.
1293         (m68k_illegitimate_symbolic_constant_p): Handle TLS symbols.
1294         (m68k_legitimate_constant_address_p): Same.
1295         (m68k_decompose_address): Handle TLS references.
1296         (m68k_get_gp): New static function.
1297         (enum m68k_reloc): New contants.
1298         (TLS_RELOC_P): New macro.
1299         (m68k_wrap_symbol): New static function.
1300         (m68k_unwrap_symbol): New function.
1301         (m68k_final_prescan_insn_1): New static function.
1302         (m68k_final_prescan_insn): New function.
1303         (m68k_move_to_reg, m68k_wrap_symbol_into_got_ref): New static
1304         functions.
1305         (legitimize_pic_address): Handle TLS references..
1306         (m68k_tls_get_addr, m68k_get_tls_get_addr)
1307         (m68k_libcall_value_in_a0_p)
1308         (m68k_call_tls_get_addr, m68k_read_tp, m68k_get_m68k_read_tp)
1309         (m68k_call_m68k_read_tp): Helper variables and functions for ...
1310         (m68k_legitimize_tls_address): Handle TLS references.
1311         (m68k_tls_symbol_p, m68k_tls_reference_p_1, m68k_tls_reference_p):
1312         New functions.
1313         (m68k_legitimize_address): Handle TLS symbols.
1314         (m68k_get_reloc_decoration): New static function.
1315         (m68k_output_addr_const_extra): Handle UNSPEC_RELOC16 and
1316         UNSPEC_RELOC32.
1317         (m68k_output_dwarf_dtprel): Implement hook.
1318         (print_operand_address): Handle UNSPEC_RELOC16 adn UNSPEC_RELOC32.
1319         (m68k_libcall_value): Return result in A0 instead of D0 when asked by
1320         m68k_call_* routines.
1321         (sched_attr_op_type): Handle TLS symbols.
1322         (gt-m68k.h): Include.
1323         * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Define.
1324         (LEGITIMATE_PIC_OPERAND_P): Support TLS.
1325
1326 2009-05-18  Martin Jambor  <mjambor@suse.cz>
1327
1328         * ipa-prop.c (ipa_check_stmt_modifications): Removed.
1329         (visit_store_addr_for_mod_analysis): New function.
1330         (ipa_detect_param_modifications): Use walk_stmt_load_store_addr_ops.
1331         (determine_cst_member_ptr): Use gimple_assign_single_p.
1332         (ipa_get_stmt_member_ptr_load_param): Use gimple_assign_single_p.
1333         (ipa_analyze_call_uses): Use !gimple_assign_rhs2 rather than number of
1334         operands.  Don't check number of operands of a NOP_EXPR.
1335
1336 2009-05-18  Eric Fisher  <joefoxreal@gmail.com>
1337
1338         * doc/tree-ssa.texi (SSA Operands): Fix a mistake.
1339
1340 2009-05-17  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1341
1342         PR c/40172
1343         * c-common.c (warn_logical_operator): Don't warn if one of
1344         expression isn't always true or false.
1345
1346 2009-05-17  Kai Tietz  <kai.tietz@onevision.com>
1347
1348         * config/i386/biarch32.h: New file.
1349         * config.gcc: Add for target i386-w64-* the biarch32.h to tm_file.
1350
1351 2009-05-17  Adam Nemet  <anemet@caviumnetworks.com>
1352
1353         * config/mips/mips.md (*zero_extend<mode>_trunchi,
1354         *zero_extend<mode>_truncqi): Merge these into ...
1355         (*zero_extend<GPR:mode>_trunc<SHORT:mode>): ... this new pattern.
1356         Name the pattern following this as *zero_extendhi_truncqi.
1357
1358 2009-05-16  Brad Lucier  <lucier@math.purdue.edu>
1359
1360         PR middle-end/39301
1361         * hwint.h: Add macro HOST_WIDEST_INT_PRINT.
1362         * bitmap.c (bitmap_descriptor): Make fields HOST_WIDEST_INT.
1363         (output_info): Make field HOST_WIDEST_INT.
1364         (print_statistics): Use HOST_WIDEST_INT_PRINT.
1365         (dump_bitmat_statistics): Same.
1366
1367 2009-05-16  Francois-Xavier Coudert  <fxcoudert@gmail.com>
1368
1369         * config.gcc (use_gcc_stdint):  Set to wrap.
1370         * config/darwin.h (SIG_ATOMIC_TYPE, INT8_TYPE, INT16_TYPE,
1371         INT32_TYPE, INT64_TYPE, UINT8_TYPE, UINT16_TYPE, UINT32_TYPE,
1372         UINT64_TYPE, INT_LEAST8_TYPE, INT_LEAST16_TYPE, INT_LEAST32_TYPE,
1373         INT_LEAST64_TYPE, UINT_LEAST8_TYPE, UINT_LEAST16_TYPE,
1374         UINT_LEAST32_TYPE, UINT_LEAST64_TYPE, INT_FAST8_TYPE,
1375         INT_FAST16_TYPE, INT_FAST32_TYPE, INT_FAST64_TYPE,
1376         UINT_FAST8_TYPE, UINT_FAST16_TYPE, UINT_FAST32_TYPE,
1377         UINT_FAST64_TYPE, INTPTR_TYPE, UINTPTR_TYPE): Define.
1378
1379 2009-05-16  Joseph Myers  <joseph@codesourcery.com>
1380
1381         * config.gcc (mips*-*-*): Support arch_32, arch_64, tune_32 and
1382         tune_64.
1383         * config/mips/mips.h (MIPS_ABI_DEFAULT, MULTILIB_ABI_DEFAULT):
1384         Move definitions earlier.
1385         (OPT_ARCH64, OPT_ARCH32): Define.
1386         (OPTION_DEFAULT_SPECS): Add entries for arch_32, arch_64, tune_32
1387         and tune_64.
1388
1389 2009-05-16  Richard Earnshaw  <rearnsha@arm.com>
1390
1391         PR target/40153
1392         * arm.md (cstoresi_nltu_thumb1): Use a neg of ltu as the pattern name
1393         implies.
1394
1395 2009-05-16  Richard Earnshaw  <rearnsha@arm.com>
1396
1397         * arm.md (movdi2): Copy non-reg values to DImode registers.
1398
1399 2009-05-16  Jakub Jelinek  <jakub@redhat.com>
1400
1401         PR target/39942
1402         * final.c (label_to_max_skip): New function.
1403         (label_to_alignment): Only use LABEL_TO_ALIGNMENT if
1404         CODE_LABEL_NUMBER <= max_labelno.
1405         * output.h (label_to_max_skip): New prototype.
1406         * config/i386/i386.c (ix86_avoid_jump_misspredicts): Renamed to...
1407         (ix86_avoid_jump_mispredicts): ... this.  Don't define if
1408         ASM_OUTPUT_MAX_SKIP_ALIGN isn't defined.  Update comment.
1409         Handle CODE_LABELs with >= 16 byte alignment or with
1410         max_skip == (1 << align) - 1.
1411         (ix86_reorg): Don't call ix86_avoid_jump_mispredicts if
1412         ASM_OUTPUT_MAX_SKIP_ALIGN isn't defined.
1413
1414         PR target/39942
1415         * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Don't emit second
1416         .p2align 3 if MAX_SKIP is smaller than 7.
1417         * config/i386/linux.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
1418
1419 2009-05-15  Ian Lance Taylor  <iant@google.com>
1420
1421         * alias.c (struct alias_set_entry_d): Rename from struct
1422         alias_set_entry.  Change all uses.
1423         * except.c (struct call_site_record_d): Rename from struct
1424         call_site_record.  Change all uses.
1425         * except.h (struct eh_region_d): Rename from struct eh_region.
1426         Change all uses.
1427         * gcse.c (struct hash_table_d): Rename from struct hash_table.
1428         Change all uses.
1429         * graphite.c (struct ivtype_map_elt_d): Rename fromstruct
1430         ivtype_map_elt.  Change all uses.
1431         (struct rename_map_elt_d): Rename fromstruct rename_map_elt.
1432         Change all uses.
1433         (struct ifsese_d): Rename fromstruct ifsese.  Change all uses.
1434         * graphite.h (struct name_tree_d): Rename from struct name_tree.
1435         Change all uses.
1436         (struct sese_d): Rename from struct sese.  Change all uses.
1437         * omega.h (struct eqn_d): Rename from struct eqn.  Change all uses.
1438         (struct omega_pb_d): Rename from struct omega_pb.  Change all uses.
1439         * optabs.h (struct optab_d): Rename from struct optab.  Change all
1440         uses.
1441         (struct convert_optab_d): Rename from struct convert_optab.
1442         Change all uses.
1443         * tree-pass.h (struct ipa_opt_pass_d): Rename fromstruct
1444         ipa_opt_pass.  Change all uses.
1445         * tree-predcom.c (struct dref_d): Rename from struct dref.  Change
1446         all uses.
1447
1448         * c-decl.c (pushtag): If -Wc++-compat, warn if the tag is already
1449         defined as a typedef.
1450         (grokdeclarator): If -Wc++-compat, warn if a typedef is already
1451         defined as a tag.
1452
1453 2009-05-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1454
1455         PR 16302
1456         * fold-const.c (make_range,build_range_check,merge_ranges): Move
1457         declaration to...
1458         (merge_ranges): Returns bool. 
1459         * tree.h (make_range): .. to here.
1460         (build_range_check): Likewise.
1461         (merge_ranges): Likewise. Renamed from merge_ranges.
1462         * c-typeck.c (parser_build_binary_op): Update calls to
1463         warn_logical_operator.
1464         * c-common.c (warn_logical_operator): Add new warning.
1465         * c-common.h (warn_logical_operator): Update declaration.
1466         
1467 2009-05-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1468
1469         * ira-conflicts.c (add_insn_allocno_copies): Fix wrong conditional.
1470         
1471 2009-05-15  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
1472
1473         * doc/install.texi: Document MPC requirements, flags etc.
1474
1475         * builtins.c (do_mpc_arg1, fold_builtin_ccos): New.
1476         (fold_builtin_cexp): Ensure we get a complex REAL_TYPE.
1477         Evaluate constant arguments.
1478         (fold_builtin_carg): Ensure we get a complex REAL_TYPE.
1479         (fold_builtin_1): Likewise, also evaluate constant arguments.
1480         Remove superfluous break.
1481         (do_mpc_ckconv): New.
1482         * real.h: Include mpc.h.
1483         * toplev.c (print_version): Output MPC version info if available.
1484
1485 2009-05-15  Sandra Loosemore  <sandra@codesourcery.com>
1486
1487         * fold-const.c (fold_convert_const_real_from_real): Check for overflow.
1488
1489 2009-05-15  H.J. Lu  <hongjiu.lu@intel.com>
1490
1491         * config/i386/i386.c (ix86_reorg): Call optimize_function_for_speed_p
1492         only once.
1493
1494 2009-05-15  Jan Hubicka  <jh@suse.cz>
1495
1496         * doc/invoke.texi (max-early-inliner-iterations): New flag.
1497         * ipa-inline.c (enum inlining_mode): New INLINE_SIZE_NORECURSIVE.
1498         (try_inline): Fix return value.
1499         (cgraph_decide_inlining_incrementally): Honor new value.
1500         (cgraph_early_inlining): Handle indirect inlining.
1501         * params.def (PARAM_EARLY_INLINER_MAX_ITERATIONS): New.
1502
1503 2009-05-15  Jan Hubicka  <jh@suse.cz>
1504
1505         * cgraph.h (struct cgraph_node): Add finalized_by_frotnend flag.
1506         * cgraphunit.c (cgraph_finalize_function): Set it.
1507         (cgraph_expand_function): Use it.
1508
1509 2009-05-15  Sandra Loosemore  <sandra@codesourcery.com>
1510
1511         * real.c (encode_ieee_half): Define.
1512         (decode_ieee_half): Define.
1513         (ieee_half_format): Define.
1514         (arm_half_format): Define.
1515         * real.h (ieee_half_format): Declare.
1516         (arm_half_format): Declare.
1517
1518 2009-05-15  Sandra Loosemore  <sandra@codesourcery.com>
1519
1520         * optabs.c (prepare_float_lib_cmp):  Test that the comparison,
1521         swapped, and reversed optabs exist before trying to use them.
1522
1523 2009-05-15  Paul Brook  <paul@codesourcery.com>
1524             Sandra Loosemore  <sandra@codesourcery.com>
1525
1526         * config/arm/arm.c (neon_vector_mem_operand): Handle element/structure
1527         loads.  Allow PRE_DEC.
1528         (output_move_neon): Handle PRE_DEC.
1529         (arm_print_operand): Add 'A' for neon structure loads.
1530         * config/arm/arm-protos.h (neon_vector_mem_operand): Update prototype.
1531         * config/arm/neon.md (neon_mov): Update comment.
1532         * config/arm/constraints.md (Un, Us): Update neon_vector_mem_operand
1533         calls.
1534         (Um): New constraint.
1535
1536 2009-05-15  Jan Hubicka  <jh@suse.cz>
1537
1538         Revert the following patch until testsuite fallout is fixed:
1539         * cgraph.c (dump_cgraph_node): Dump size/time/benefit.
1540         * cgraph.h (struct inline_summary): New filed self_wize,
1541         size_inlining_benefit, self_time and time_inlining_benefit.
1542         (struct cgraph_global_info): Replace insns by time ans size fields.
1543         * ipa-cp (ipcp_cloning_candidate_p): Base estimate on size
1544         (ipcp_estimate_growth, ipcp_insert_stage): Likewise.
1545         (ipcp_update_callgraph): Do not touch function bodies.
1546         * ipa-inline.c: Include except.h
1547         (MAX_TIME): New constant.
1548         (overall_insns): Remove
1549         (overall_size, max_benefit): New static variables.
1550         (cgraph_estimate_time_after_inlining): New function.
1551         (cgraph_estimate_size_after_inlining): Rewrite using benefits.
1552         (cgraph_clone_inlined_nodes): Update size.
1553         (cgraph_mark_inline_edge): Update size.
1554         (cgraph_estimate_growth): Use size info.
1555         (cgraph_check_inline_limits): Check size.
1556         (cgraph_default_inline_p): Likewise.
1557         (cgraph_edge_badness): Compute badness based on benefit and size cost.
1558         (cgraph_decide_recursive_inlining): Check size.
1559         (cgraph_decide_inlining_of_small_function): Update size; dump sizes and
1560         times.
1561         (cgraph_decide_inlining): Likewise.
1562         (cgraph_decide_inlining_incrementally): Likewise; honor
1563         PARAM_EARLY_INLINING_INSNS.
1564         (likely_eliminated_by_inlining_p): New predicate.
1565         (estimate_function_body_sizes): New function.
1566         (compute_inline_parameters): Use it.
1567         * except.c (must_not_throw_labels): New function.
1568         * except.h (must_not_throw_labels): Declare.
1569         * tree-inline.c (init_inline_once): Kill inlining_weigths
1570         * tree-ssa-structalias.c: Avoid uninitialized warning.
1571         * params.def (PARAM_MAX_INLINE_INSNS_SINGLE): Reduce to 300.
1572         (PARAM_MAX_INLINE_INSNS_AUTO): Reduce to 60.
1573         (PARAM_INLINE_CALL_COST): Remove.
1574         (PARAM_EARLY_INLINING_INSNS): New.
1575
1576 2009-05-15  Richard Guenther  <rguenther@suse.de>
1577
1578         * tree-ssa-pre.c (eliminate): Use TODO_update_ssa_only_virtuals,
1579         not TODO_update_ssa.
1580
1581 2009-05-15  Richard Guenther  <rguenther@suse.de>
1582
1583         PR tree-optimization/39999
1584         * gimple.h (gimple_expr_type): Use the expression type looking
1585         through useless conversions.
1586         * tree-ssa-sccvn.c (vn_nary_op_lookup_stmt): Use gimple_expr_type.
1587         (vn_nary_op_insert_stmt): Likewise.
1588         (simplify_binary_expression): Likewise.
1589
1590 2009-05-15  Richard Guenther  <rguenther@suse.de>
1591
1592         * common.opt (-ftree-forwprop, -ftree-phiprop, -ftree-pta):
1593         New options, enabled by default.
1594         * doc/invoke.texi (-ftree-forwprop, -ftree-phiprop, -ftree-pta):
1595         Document.
1596         * tree-ssa-forwprop.c (gate_forwprop): Use flag_tree_forwprop.
1597         * tree-ssa-phiprop.c (gate_phiprop): Use flag_tree_phiprop.
1598         * tree-ssa-structalias.c (gate_tree_pta): New function.
1599         (pass_build_alias): Use it.
1600
1601 2009-05-15  Joseph Myers  <joseph@codesourcery.com>
1602
1603         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Also
1604         recurse on an invariant address if a conversion from a pointer
1605         type to a wider integer type is involved.
1606
1607 2009-05-15  Jan Hubicka  <jh@suse.cz>
1608
1609         * cgraph.c (dump_cgraph_node): Dump size/time/benefit.
1610         * cgraph.h (struct inline_summary): New filed self_wize,
1611         size_inlining_benefit, self_time and time_inlining_benefit.
1612         (struct cgraph_global_info): Replace insns by time ans size fields.
1613         * ipa-cp (ipcp_cloning_candidate_p): Base estimate on size
1614         (ipcp_estimate_growth, ipcp_insert_stage): Likewise.
1615         (ipcp_update_callgraph): Do not touch function bodies.
1616         * ipa-inline.c: Include except.h
1617         (MAX_TIME): New constant.
1618         (overall_insns): Remove
1619         (overall_size, max_benefit): New static variables.
1620         (cgraph_estimate_time_after_inlining): New function.
1621         (cgraph_estimate_size_after_inlining): Rewrite using benefits.
1622         (cgraph_clone_inlined_nodes): Update size.
1623         (cgraph_mark_inline_edge): Update size.
1624         (cgraph_estimate_growth): Use size info.
1625         (cgraph_check_inline_limits): Check size.
1626         (cgraph_default_inline_p): Likewise.
1627         (cgraph_edge_badness): Compute badness based on benefit and size cost.
1628         (cgraph_decide_recursive_inlining): Check size.
1629         (cgraph_decide_inlining_of_small_function): Update size; dump sizes and
1630         times.
1631         (cgraph_decide_inlining): Likewise.
1632         (cgraph_decide_inlining_incrementally): Likewise; honor
1633         PARAM_EARLY_INLINING_INSNS.
1634         (likely_eliminated_by_inlining_p): New predicate.
1635         (estimate_function_body_sizes): New function.
1636         (compute_inline_parameters): Use it.
1637         * except.c (must_not_throw_labels): New function.
1638         * except.h (must_not_throw_labels): Declare.
1639         * tree-inline.c (init_inline_once): Kill inlining_weigths
1640         * tree-ssa-structalias.c: Avoid uninitialized warning.
1641         * params.def (PARAM_MAX_INLINE_INSNS_SINGLE): Reduce to 300.
1642         (PARAM_MAX_INLINE_INSNS_AUTO): Reduce to 60.
1643         (PARAM_INLINE_CALL_COST): Remove.
1644         (PARAM_EARLY_INLINING_INSNS): New.
1645         doc/invoke.texi (max-inline-insns-auto, early-inlining-insns): Update.
1646         (inline-call-cost): Remove.
1647         (early-inlining-insns): New.
1648
1649 2009-05-15  Eric Botcazou  <ebotcazou@adacore.com>
1650
1651         * dbxout.c (dbxout_range_type): Add LOW and HIGH parameters.  Use them
1652         for bounds.
1653         (print_int_cst_bounds_in_octal_p): Likewise.
1654         (dbxout_type): Adjust calls to above functions.  Be prepared to deal
1655         with subtypes.
1656         * dwarf2out.c (base_type_die): Likewise.
1657         (is_subrange_type): Delete.
1658         (subrange_type_die): Add LOW and HIGH parameters.  Use them for bounds.
1659         (modified_type_die): Call subrange_type_for_debug_p on subtypes.
1660         * fold-const.c (fold_truth_not_expr) <CONVERT_EXPR>: Do not strip it if
1661         the destination type is boolean.
1662         (build_range_check): Do not special-case subtypes.
1663         (fold_sign_changed_comparison): Likewise.
1664         (fold_unary): Likewise.
1665         * langhooks-def.h (LANG_HOOKS_GET_SUBRANGE_BOUNDS): Define.
1666         (LANG_HOOKS_FOR_TYPES_INITIALIZER): Add LANG_HOOKS_GET_SUBRANGE_BOUNDS.
1667         * langhooks.h (lang_hooks_for_types): Add get_subrange_bounds.
1668         * tree.c (subrange_type_for_debug_p): New predicate based on the former
1669         is_subrange_type.
1670         * tree.h (subrange_type_for_debug_p): Declare.
1671         * tree-chrec.c (avoid_arithmetics_in_type_p): Delete.
1672         (convert_affine_scev): Remove call to above function.
1673         (chrec_convert_aggressive): Likewise.
1674         * tree-ssa.c (useless_type_conversion_p_1): Do not specifically return
1675         false for conversions involving subtypes.
1676         * tree-vrp.c (vrp_val_max): Do not special-case subtypes.
1677         (vrp_val_min): Likewise.
1678         (needs_overflow_infinity): Likewise.
1679         (extract_range_from_unary_expr): Likewise.
1680
1681 2009-05-15  Paolo Bonzini  <bonzini@gnu.org>
1682
1683         * config/frv/frv.h: Clean up references to GO_IF_LEGITIMATE_ADDRESS.
1684         * config/frv/frv.c: Likewise.
1685         * config/s390/s390.c: Likewise.
1686         * config/sparc/sparc.h: Likewise.
1687         * config/i386/i386.h: Likewise.
1688         * config/i386/i386.c: Likewise.
1689         * config/crx/crx.c: Likewise.
1690         * config/m68hc11/m68hc11.h: Likewise.
1691         * config/iq2000/iq2000.c: Likewise.
1692         * config/mn10300/mn10300.h: Likewise.
1693         * config/mn10300/mn10300.c: Likewise.
1694         * config/m68k/m68k.c: Likewise.
1695         * config/rs6000/rs6000.c: Likewise.
1696         * config/rs6000/xcoff.h: Likewise.
1697         * config/rs6000/linux64.h: Likewise.
1698         * config/rs6000/sysv4.h: Likewise.
1699         * config/score/score3.c: Likewise.
1700         * config/score/score7.c: Likewise.
1701         * config/score/score.c: Likewise.
1702         * config/arm/arm.md: Likewise.
1703         * config/mips/mips.c: Likewise.
1704         * config/mips/mips.md: Likewise.
1705         * config/bfin/bfin.h: Likewise.
1706         * config/pa/pa.c: Likewise.
1707         * config/pa/constraints.md: Likewise.
1708
1709         * config/pdp11/pdp11-protos.h (legitimate_address_p): Delete.
1710         * config/pdp11/pdp11.c (legitimate_address_p): Delete.
1711         * config/pdp11/pdp11.h: Use memory_address_p instead.
1712
1713 2009-05-14  Ian Lance Taylor  <iant@google.com>
1714
1715         * passes.c (finish_optimization_passes): Change i to int.
1716         * plugin.c (plugins_active_p): Change event to int.
1717         (dump_active_plugins): Likewise.
1718         * reginfo.c (invalid_mode_change_p): Change to to unsigned int.
1719         Add cast.
1720         * tree.c (tree_range_check_failed): Change c to unsigned int.
1721         (omp_clause_range_check_failed): Likewise.
1722         (build_common_builtin_nodes): Change mode to int.  Add cast.
1723         * config/ia64/ia64.c (is_emitted): Change r to unsigned int.
1724         (ia64_hard_regno_rename_ok, ia64_eh_uses): Likewise.
1725
1726         * c-typeck.c (build_unary_op): If -Wc++-compat, warn about using
1727         ++ or -- with a variable of enum type.
1728
1729 2009-05-14  Steven Bosscher  <steven@gcc.gnu.org>
1730
1731         PR driver/40144
1732         * opts.c (common_handle_option): Add OPT_fcse_skip_blocks as a no-op.
1733
1734 2009-05-14  Steven Bosscher  <steven@gcc.gnu.org>
1735
1736         * store-motion.c: Do not include params.h
1737         * Makefile.in: Fix dependencies for various files.
1738
1739 2009-05-14  Steven Bosscher  <steven@gcc.gnu.org>
1740
1741         * auto-inc-dec.c: Fix pass description, remove apparent
1742         accidental duplication.
1743
1744 2009-05-14  H.J. Lu  <hongjiu.lu@intel.com>
1745
1746         PR middle-end/40147
1747         * ipa-utils.h (memory_identifier_string): Moved to ...
1748         * tree.h (memory_identifier_string): Here.  Add GTY(()).
1749
1750 2009-05-14  Paolo Bonzini  <bonzini@gnu.org>
1751
1752         * doc/tm.texi (TARGET_LEGITIMATE_ADDRESS_P): Refer mainly to this
1753         in the former documentation of...
1754         (GO_IF_LEGITIMATE_ADDRESS): ... this.
1755         * ira-conflicts.c (get_dup_num): Use address_operand.
1756         * targhooks.c (default_legitimate_address_p): New.
1757         * targhooks.h (default_legitimate_address_p): New.
1758         * reload.c (strict_memory_address_p) [!GO_IF_LEGITIMATE_ADDRESS]:
1759         Call hook.
1760         * recog.c (memory_address_p) [!GO_IF_LEGITIMATE_ADDRESS]: Call hook.
1761         * target.h (struct target): Add legitimate_address_p.
1762         * target-def.h (TARGET_LEGITIMATE_ADDRESS_P): New.
1763         (TARGET_INITIALIZER): Include it.
1764
1765         * config/alpha/alpha.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1766         * config/alpha/alpha-protos.h (alpha_legitimate_address_p): Remove.
1767         * config/alpha/alpha.c (alpha_legitimate_address_p): Make static.
1768         (TARGET_LEGITIMATE_ADDRESS_P): New.
1769
1770         * config/frv/frv.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1771         (REG_OK_STRICT_P): Delete.
1772         * config/frv/frv-protos.h (frv_legitimate_address_p): Rename to...
1773         (frv_legitimate_address_p_1): ... this.
1774         * config/frv/frv.c (frv_legitimate_address_p): Forward to...
1775         (frv_legitimate_address_p_1): ... the renamed old
1776         frv_legitimate_address_p.
1777         * config/frv/predicates.md: Adjust calls to frv_legitimate_address_p.
1778         (TARGET_LEGITIMATE_ADDRESS_P): New.
1779
1780         * config/s390/s390.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1781         * config/s390/s390-protos.h (legitimate_address_p): Remove.
1782         * config/s390/s390.c (legitimate_address_p): Rename to...
1783         (s390_legitimate_address_p): ... this, make static.
1784         (legitimize_address): Adjust call.
1785         (TARGET_LEGITIMATE_ADDRESS_P): New.
1786         * config/s390/constraints.md ("e"): Call strict_memory_address_p.
1787
1788         * config/m32c/m32c.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1789         * config/m32c/m32c-protos.h (m32c_legitimate_address_p): Remove.
1790         * config/m32c/m32c.c (m32c_legitimate_address_p): Make static.
1791         (TARGET_LEGITIMATE_ADDRESS_P): New.
1792
1793         * config/spu/spu.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1794         * config/spu/spu-protos.h (spu_legitimate_address): Remove.
1795         * config/spu/spu.c (spu_legitimate_address): Rename to...
1796         (spu_legitimate_address_p): ... this, make static.
1797         (TARGET_LEGITIMATE_ADDRESS_P): New.
1798
1799         * config/sparc/sparc.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1800         * config/sparc/sparc-protos.h (legitimate_address_p): Remove.
1801         * config/sparc/sparc.c (legitimate_address_p): Rename to...
1802         (sparc_legitimate_address_p): ... this, make static and return bool.
1803         (legitimize_address): Adjust call.
1804         (TARGET_LEGITIMATE_ADDRESS_P): New.
1805
1806         * config/i386/i386.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1807         * config/i386/i386-protos.h (legitimate_address_p): Remove.
1808         * config/i386/i386.c (legitimate_address_p): Rename to...
1809         (ix86_legitimate_address_p): ... this, make static.
1810         (constant_address_p): Move after it, adjust call.
1811         (TARGET_LEGITIMATE_ADDRESS_P): New.
1812
1813         * config/avr/avr.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1814         * config/avr/avr-protos.h (legitimate_address_p): Remove.
1815         * config/avr/avr.c (legitimate_address_p): Rename to...
1816         (avr_legitimate_address_p): ... this, make static.
1817         (legitimize_address): Adjust call.
1818         (TARGET_LEGITIMATE_ADDRESS_P): New.
1819
1820         * config/crx/crx.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1821         * config/crx/crx-protos.h (crx_legitimate_address_p): Remove.
1822         * config/crx/crx.c (crx_legitimate_address_p): Make static.
1823         (TARGET_LEGITIMATE_ADDRESS_P): New.
1824
1825         * config/xtensa/xtensa.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1826         * config/xtensa/xtensa-protos.h (xtensa_legitimate_address_p): Remove.
1827         * config/xtensa/xtensa.c (xtensa_legitimate_address_p): Make static.
1828         (TARGET_LEGITIMATE_ADDRESS_P): New.
1829
1830         * config/stormy16/stormy16.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1831         * config/stormy16/stormy16-protos.h (xstormy16_legitimate_address_p):
1832         Remove.
1833         * config/stormy16/stormy16.c (xstormy16_legitimate_address_p):
1834         Make static.
1835         (TARGET_LEGITIMATE_ADDRESS_P): New.
1836
1837         * config/m68hc11/m68hc11.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1838         * config/m68hc11/m68hc11-protos.h (m68hc11_go_if_legitimate_address):
1839         Remove.
1840         * config/m68hc11/m68hc11.c (m68hc11_go_if_legitimate_address):
1841         Rename to...
1842         (m68hc11_legitimate_address_p): ... this, make static.
1843         (go_if_legitimate_address_internal): Rename to...
1844         (m68hc11_legitimate_address_p_1): ... this.
1845         (legitimize_address): Adjust call.
1846         (TARGET_LEGITIMATE_ADDRESS_P): New.
1847
1848         * config/iq2000/iq2000.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1849         * config/iq2000/iq2000-protos.h (iq2000_legitimate_address_p): Remove.
1850         * config/iq2000/iq2000.c (iq2000_legitimate_address_p): Make static.
1851         (TARGET_LEGITIMATE_ADDRESS_P): New.
1852
1853         * config/mn10300/mn10300.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1854         * config/mn10300/mn10300-protos.h (legitimate_address_p): Remove.
1855         * config/mn10300/mn10300.c (legitimate_address_p): Rename to...
1856         (mn10300_legitimate_address_p): ... this, make static.
1857         (TARGET_LEGITIMATE_ADDRESS_P): New.
1858
1859         * config/m68k/m68k.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1860         * config/m68k/m68k-protos.h (m68k_legitimate_address_p): Remove.
1861         * config/m68k/m68k.c (m68k_legitimate_address_p): Make static.
1862         (TARGET_LEGITIMATE_ADDRESS_P): New.
1863
1864         * config/rs6000/rs6000.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1865         (REG_OK_STRICT_FLAG, REG_OK_FOR_BASE_P, REG_OK_FOR_INDEX_P): Delete.
1866         (INT_REG_OK_FOR_BASE_P, INT_REG_OK_FOR_INDEX_P): Move above.
1867         * config/rs6000/rs6000.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1868         * config/rs6000/rs6000-protos.h (rs6000_legitimate_address): Remove.
1869         * config/rs6000/rs6000.c (rs6000_legitimate_address): Rename to...
1870         (rs6000_legitimate_address_p): ... this, make static.
1871         (TARGET_LEGITIMATE_ADDRESS_P): New.
1872         (REG_MODE_OK_FOR_BASE_P): Delete.
1873         (rs6000_legitimize_reload_address): Use INT_REG_OK_FOR_BASE_P.
1874
1875         * config/picochip/picochip.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1876         * config/picochip/picochip-protos.h (picochip_legitimate_address_p):
1877         Delete.
1878         * config/picochip/picochip.c (picochip_legitimate_address_p): Make
1879         static, adjust types.
1880         (TARGET_LEGITIMATE_ADDRESS_P): New.
1881
1882         * config/score/score.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1883         * config/score/score.c (score_address_p): Rename to...
1884         (score_legitimate_address_p): ... this.
1885         (TARGET_LEGITIMATE_ADDRESS_P): New.
1886         * config/score/score3.c (score3_address_p): Rename to...
1887         (score3_legitimate_address_p): ... this.
1888         * config/score/score7.c (score7_address_p): Rename to...
1889         (score7_legitimate_address_p): ... this.
1890
1891         * config/arm/arm.h (ARM_GO_IF_LEGITIMATE_ADDRESS,
1892         THUMB2_GO_IF_LEGITIMATE_ADDRESS, THUMB1_GO_IF_LEGITIMATE_ADDRESS,
1893         GO_IF_LEGITIMATE_ADDRESS): Delete.
1894         * config/arm/arm-protos.h (thumb1_legitimate_address_p,
1895         thumb2_legitimate_address_p): Delete.
1896         (arm_legitimate_address_p): Rename to...
1897         (arm_legitimate_address_outer_p): ... this.
1898         * config/arm/constraints.md ("Uq"): Adjust call.
1899         * config/arm/predicates.md (arm_extendqisi_mem_op): Likewise.
1900         * config/arm/arm.c (arm_legitimate_address_p): New, rename old one to...
1901         (arm_legitimate_address_outer_p): ... this.
1902         (thumb1_legitimate_address_p, thumb2_legitimate_address_p): Make static.
1903         (TARGET_LEGITIMATE_ADDRESS_P): New.
1904
1905         * config/mips/mips.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1906         * config/mips/mips-protos.h (mips_legitimate_address_p): Remove.
1907         * config/mips/mips.c (mips_legitimate_address_p): ... Make static.
1908         (TARGET_LEGITIMATE_ADDRESS_P): New.
1909
1910         * config/vax/vax.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1911         * config/vax/vax-protos.h (legitimate_address_p): Remove.
1912         * config/vax/vax.c (legitimate_address_p): Rename to...
1913         (vax_legitimate_address_p): ... this, make static.
1914         (TARGET_LEGITIMATE_ADDRESS_P): New.
1915
1916         * config/h8300/h8300.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1917         * config/h8300/h8300-protos.h (h8300_legitimate_address_p): Remove.
1918         * config/h8300/h8300.c (h8300_legitimate_address_p): ... Make static.
1919         (TARGET_LEGITIMATE_ADDRESS_P): New.
1920
1921         * config/mmix/mmix.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1922         * config/mmix/mmix-protos.h (mmix_legitimize_address): Remove.
1923         * config/mmix/mmix.c (mmix_legitimate_address): Rename to...
1924         (mmix_legitimate_address_p): ... this, make static.
1925         (TARGET_LEGITIMATE_ADDRESS_P): New.
1926
1927         * config/bfin/bfin.h (GO_IF_LEGITIMATE_ADDRESS): Delete.
1928         * config/bfin/bfin-protos.h (bfin_legitimate_address_p): Remove.
1929         * config/bfin/bfin.c (bfin_legitimate_address_p): ... Make static.
1930         (TARGET_LEGITIMATE_ADDRESS_P): New.
1931
1932 2009-05-14  Paolo Bonzini  <bonzini@gnu.org>
1933
1934         * config/arm/arm.h (PROMOTE_FUNCTION_MODE): Remove handling
1935         of MODE_COMPLEX_INT.
1936
1937 2009-05-14  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
1938
1939         * config/alpha/alpha.c (alpha_initialize_trampoline): Change 0 to
1940         LCT_NORMAL in function call.
1941         * mips-tdump.c (print_file_desc): Add cast to enum type.
1942         * mips-tfile.c (add_ext_symbol): Add casts to enum types.
1943         (mark_stabs): Add casts to enum types.
1944         (parse_stabs_common): Add casts to enum types.
1945
1946 2009-05-13  Adam Nemet  <anemet@caviumnetworks.com>
1947
1948         * config/mips/mips.c (mips_print_operand) <REG, MEM, default>:
1949         Check for invalid values of LETTER.
1950
1951 2009-05-13  Taras Glek  <tglek@mozilla.com>
1952
1953         * attribs.c (register_attribute): moved out attribute registration into
1954         register_attribute.
1955         * doc/plugins.texi: Documented register_attribute and PLUGIN_ATTRIBUTES.
1956         * gcc-plugin.h: Added forward decl for register_attribute.
1957         * gcc-plugin.h (plugins_event): Added PLUGIN_ATTRIBUTES.
1958         * plugin.c (register_callback, invoke_plugin_callbacks): Added
1959         PLUGIN_ATTRIBUTES boilerplate.
1960
1961 2009-05-14  Dave Korn  <dave.korn.cygwin@gmail.com>
1962
1963         * config/i386/msformat-c.c (ms_printf_length_specs):  Use enumeration
1964         values even in sentinel and empty entries.
1965         (ms_printf_flag_specs):  Likewise.
1966         (ms_scanf_flag_specs):  Likewise.
1967         (ms_strftime_flag_specs):  Likewise.
1968         (ms_print_char_table):  Likewise.
1969         (ms_scan_char_table):  Likewise.
1970         (ms_time_char_table):  Likewise.
1971
1972 2009-05-13  Doug Kwan  <dougkwan@google.com>
1973
1974         * tree-ssa-sccvn.c (compare_ops): Stabilize qsort.
1975
1976 2009-05-13  Adam Nemet  <anemet@caviumnetworks.com>
1977
1978         * config/mips/mips.md (store): Add attributes for QI and HI.
1979         Update comment.
1980         (truncdisi2, truncdihi2, truncdiqi2): Merge these into ...
1981         (truncdi<mode>2): ... this new pattern.
1982
1983 2009-05-13  Brad Hards  <bradh@kde.org>
1984
1985         * Makefile.in (TEXI_GCCINT_FILES): Add plugins.texi.
1986
1987 2009-05-14  Jakub Jelinek  <jakub@redhat.com>
1988             Ben Elliston <bje@au.ibm.com>
1989
1990         PR middle-end/40035
1991         * dse.c (check_mem_read_rtx): Guard against width == -1.
1992
1993 2009-05-13  Michael Matz  <matz@suse.de>
1994
1995         PR middle-end/39976
1996         * tree-outof-ssa.c (maybe_renumber_stmts_bb): New function.
1997         (trivially_conflicts_p): New function.
1998         (insert_backedge_copies): Use it.
1999
2000 2009-05-13  Janis Johnson  <janis187@us.ibm.com>
2001
2002         * c-pragma.c (enum pragma_switch_t): Prefix constants with PRAGMA_.
2003         (handle_stdc_pragma): Use new enum constant names.
2004         (handle_pragma_float_const_decimal64): Ditto.
2005
2006 2009-05-13  Ian Lance Taylor  <iant@google.com>
2007
2008         * Makefile.in (build/gencheck.o): Depend upon all-tree.def, not
2009         tree.def.
2010
2011 2009-05-13  Nathan Sidwell  <nathan@codesourcery.com>
2012
2013         * config/m68k/t-uclinux (M68K_MLIB_CPU): Check for FL_UCLINUX.
2014         * config/m68k/m68k-devices.def: Add FL_UCLINUX to 68020 and 54455
2015         multilibs.
2016         * config/m68k/m68k.h (FL_UCLINUX): Define.
2017
2018 2009-05-13  Jan Hubicka  <jh@suse.cz>
2019
2020         * options.c (gfc_post_options): -fwhole-program imply -fwhole-file.
2021
2022 2009-05-12  Kaz Kojima  <kkojima@gcc.gnu.org>
2023
2024         * config/sh/sh.h (OVERRIDE_OPTIONS): Clear flag_schedule_insns
2025         unless -fschedule-insns is specified.
2026
2027 2009-05-12  Kaz Kojima  <kkojima@gcc.gnu.org>
2028
2029         PR target/39561
2030         * config/sh/sh.h (OPTIMIZATION_OPTIONS): Don't set
2031         TARGET_EXPAND_CBRANCHDI4.
2032         * config/sh/sh.md (cbranchdi4): Don't check TARGET_EXPAND_CBRANCHDI4.
2033         * config/sh/sh.opt (mexpand-cbranchdi): Remove.
2034         (cmpeqdi): Fix comment.
2035
2036 2009-05-12  Kaz Kojima  <kkojima@gcc.gnu.org>
2037
2038         * config/sh/sh-protos.h (sh_legitimate_index_p): Declare.
2039         (sh_legitimate_address_p): Likewise.
2040         * config/sh/sh.c (sh_legitimate_index_p): New.
2041         (sh_legitimate_address_p): Likewise.
2042         * config/sh/sh.h (REG_OK_FOR_BASE_P): Add STRICT parameter.
2043         (REG_OK_FOR_INDEX_P, SUBREG_OK_FOR_INDEX_P): Likewise.
2044         (MODE_DISP_OK_4, MODE_DISP_OK_8): Remove.
2045         (MAYBE_BASE_REGISTER_RTX_P): New macro.
2046         (MAYBE_INDEX_REGISTER_RTX_P): Likewise.
2047         (BASE_REGISTER_RTX_P): Use MAYBE_BASE_REGISTER_RTX_P.
2048         (INDEX_REGISTER_RTX_P): Use MAYBE_INDEX_REGISTER_RTX_P.
2049         (GO_IF_LEGITIMATE_INDEX): Use sh_legitimate_index_p.
2050         (GO_IF_LEGITIMATE_ADDRESS): Use sh_legitimate_address_p.
2051
2052 2009-05-12  Jan Hubicka  <jh@suse.cz>
2053
2054         * tree-inline.c (estimate_operator_cost): Add operands;
2055         when division happens by constant, it is cheap.
2056         (estimate_num_insns): Loads and stores are not having cost of 0;
2057         EH magic stuff is cheap; when computing runtime cost of switch,
2058         use log2 base of amount of its cases; builtin_expect has cost of 0;
2059         compute cost for moving return value of call.
2060         (init_inline_once): Initialize time_based flags.
2061         * tree-inline.h (eni_weights_d): Add time_based flag.
2062
2063 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
2064
2065         * df-core.c: Update head documentation.
2066
2067 2009-05-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
2068
2069         PR bootstrap/40118
2070         * rs6000.c (rs6000_generate_compare): Use op1b instead of
2071         shadowing exisiting variable op1.
2072
2073 2009-05-12  Uros Bizjak  <ubizjak@gmail.com>
2074
2075         PR target/37179
2076         * config/i386/driver-i386.c (processor_signatures): New enum.
2077         (SIG_GEODE): Move from vendor_signatures to processor_signatures.
2078         (host_detect_local_cpu): For SIG_AMD vendor, check for SIG_GEODE
2079         processor signature to detect geode processor.
2080
2081 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
2082
2083         Revert:
2084
2085         2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
2086
2087         * optabs.c (prepare_cmp_insn): Temporarily disable test that
2088         causes spurious differences between trunk and cond-optab branch.
2089
2090 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
2091
2092         * dojump.c (compare_from_rtx): Delete.
2093         * expmed.c (emit_store_flag): Only try cstore_optab.  Canonicalize
2094         any MODE_CC mode to the cstorecc4 pattern.  Use prepare_operand, fail
2095         if the comparison does not satisfy the predicate; test predicates for
2096         operands 2 and 3 of a cstore pattern.  Don't try cstore optab
2097         further if one existing pattern fails.
2098         * expr.h (compare_from_rtx): Delete.
2099         (prepare_operand): Declare it.
2100         * optabs.c: Change "lib call" to "libcall" throughout.
2101         (bcc_gen_fctn, setcc_gen_code, trap_rtx,
2102         HAVE_conditional_trap, emit_cmp_insn): Delete.
2103         (can_compare_p): Delete cmp_optab case.
2104         (prepare_float_lib_cmp): Return an rtx and a machine mode.
2105         Accept other parameters by value.
2106         (prepare_operand): Make non-static.
2107         (prepare_cmp_insn): Return an rtx and a machine mode.  Accept
2108         other parameters by value.  Try to widen operands here based on
2109         an optab_methods argument and looking at cbranch_optab.
2110         (emit_cmp_and_jump_insn_1): Accept test and mode, remove widening
2111         loop.  Use cbranch_optab directly.
2112         (emit_cmp_and_jump_insns): Fix comment.  Adjust call to
2113         prepare_cmp_insn and emit_cmp_and_jump_insn_1, remove obsolete
2114         assertion.
2115         (emit_conditional_move, emit_conditional_add): Inline what's needed
2116         of compare_from_rtx, using new prepare_cmp_insn for the rest.
2117         (init_optabs): Init cmp_optab with UNKNOWN, cbranch_optab
2118         with COMPARE.  Move cmov_optab and cstore_optab above
2119         with cbranch_optab, move cmp_optab down with ucmp_optab,
2120         remove tst_otpab.  Do not initialize trap_rtx.
2121         (gen_cond_trap): Do it here.  Use ctrap_optab.  Test predicate
2122         for trap code.  Do not check HAVE_conditional_trap.  Use
2123         prepare_cmp_insn.  Accept no predicate for operand 3.
2124         * optabs.h (OTI_cmp): Mark as used only for libcalls.
2125         (OTI_ctrap, ctrap_optab): New.
2126         (tst_optab): Delete.
2127         (bcc_gen_fctn, setcc_gen_code, emit_cmp_insn): Delete.
2128         * ifcvt.c (find_if_header): Replace HAVE_conditional_trap
2129         with lookup of ctrap_optab.
2130         * genopinit.c (cmp_optab, tst_optab, bcc_gen_fctn,
2131         setcc_gen_code): Delete.
2132         (ctrap_optab): New.
2133
2134         * combine.c (combine_simplify_rtx, simplify_set): Do not
2135         special case comparing against zero for cc0 machines.
2136         * simplify-rtx.c (simplify_binary_operation_1): Never remove
2137         COMPARE on cc0 machines.
2138         (simplify_relational_operation): Return a new expression when
2139         a COMPARE could be removed.
2140         * final.c (final_scan_insn): Compare cc_status values
2141         against LHS of a (compare FOO (const_int 0)) cc0 source.
2142         Also check if cc_status.value is the full compare.
2143
2144         * doc/md.texi (bCC, sCC, tstMM, cmpMM): Delete.
2145         (cstoreMM4): Document.
2146         (conditional_trap): Document ctrapMM4 instead.
2147         (sync_compare_and_swapMM): Refer to cbranchcc4.
2148         (Dependent Patterns): Eliminate obsolete information referring to
2149         the old jump optimization phase.
2150         (Canonicalization): Include cbranchcc4 case, omit canonicalization
2151         of compares with 0 on cc0 machines.
2152         (Jump Patterns): Refer to MODE_CC jump patterns preferably,
2153         avoiding references to cc0.  Remove text about storing operands
2154         in cmpMM.
2155         * doc/tm.texi (Condition Codes): Include blurb on different
2156         condition code representations, separate into subsections for
2157         CC0, MODE_CC and conditional execution.
2158
2159         * config/alpha/alpha-protos.h (alpha_emit_conditional_branch,
2160         alpha_emit_setcc): Accept operands and a machine mode.
2161         * config/alpha/alpha.c (alpha_emit_conditional_branch):
2162         Get code/op0/op1 from operands, use machine mode argument
2163         instead of alpha_compare.fp_p.  Emit the branch here.
2164         (alpha_emit_setcc): Likewise, and return boolean.
2165         (alpha_emit_conditional_move): Likewise.  Assert that
2166         cmp_op_mode == cmp_mode, and simplify accordingly.
2167         * config/alpha/alpha.h (struct alpha_compare, alpha_compare): Delete.
2168         * config/alpha/alpha.md (cmpdf, cmptf, cmpdi, bCC, sCC): Delete.
2169         (cbranchdf4, cbranchtf4, cbranchdi4, cstoredf4, cstoretf4,cstoredi4):
2170         Delete.
2171         (stack probe test): Use cbranchdi4.
2172         * config/alpha/predicates.md (alpha_cbranch_operator): New.
2173
2174         * config/arc/arc.c (gen_compare_reg): Do not emit cmp. 
2175         * config/arc/arc.h (movsicc, movsfcc): Use it.
2176         (movdicc, *movdicc_insn, movdfcc, *movdfcc_insn): Remove.
2177         (cbranchsi4, cstoresi4): New.
2178         (cmpsi, bCC and sCC expanders): Remove. 
2179
2180         * config/arm/arm.c (arm_compare_op0, arm_compare_op1): Delete.
2181         * config/arm/arm.h (arm_compare_op0, arm_compare_op1): Delete.
2182         * config/arm/predicates.md (arm_comparison_operator): Only include
2183         floating-point operators if there is a hardware floating-point unit.
2184         * config/arm/arm.md (cbranchsi4, cstoresi4): Enable for TARGET_32BIT,
2185         deferring to cbranch_cc and cstore_cc respectively.
2186         (cbranchsf4, cbranchdf4, cbranchdi4, cstoresf4, cstoredf4, cstoredi4,
2187         cbranch_cc, cstore_cc): New.
2188         (movsicc, movsfcc, movdfcc): Do not use arm_compare_op0 and
2189         arm_compare_op1.
2190         (bCC, sCC, cmpsi, cmpsf, cmpdf, cmpdi): Delete.
2191
2192         * config/avr/avr-protos.h (out_tstsi, out_tsthi): Adjust prototype.
2193         * config/avr/avr.c (out_tstsi, out_tsthi): Get the tested operand
2194         as an argument.
2195         (adjust_insn_length): Adjust calls.
2196         (avr_reorg): Handle (compare (foo) (const_int 0)).
2197         * config/avr/avr.md (tstqi, tsthi, tstsi): Remove.
2198         (*negated_tstqi, *negated_tsthi, *negated_tstsi): Unmacroize.
2199         (*reversed_tsthi, *reversed_tstsi): Add a scratch for simplicity.
2200         (cmpqi, cmphi, cmpsi): Prepend asterisk, fuse tst[qhs]i here.
2201         (bCC): Remove.
2202         (cbranchqi4, cbranchhi4, cbranchsi4): New.
2203         (tst -> sbrc/sbrs peephole2, cpse peephole): Wrap RHS with COMPARE.
2204
2205         * config/bfin/bfin.md (cmpbi, cmpsi, bCC, sCC): Delete.
2206         (cbranchsi4, cstorebi4, cstoresi4): New.
2207         (movbisi): This insn is duplicate, split it to zero_extend.
2208         * config/bfin/bfin.c (bfin_compare_op0, bfin_compare_op1): Delete
2209         (bfin_gen_compare): Do not use them.  Emit VOIDmode SET, not BImode.
2210         (bfin_optimize_loop): Use cbranch expander.
2211         * config/bfin/bfin.h (bfin_compare_op0, bfin_compare_op1): Delete.
2212         * config/bfin/predicates.md (bfin_cbranch_operator): Rename to...
2213         (bfin_bimode_comparison_operator): ... this.
2214         (bfin_direct_comparison_operator): New.
2215  
2216         * config/cris/cris.c (cris_normal_notice_update_cc): Look
2217         inside (compare FOO (const_int 0)).
2218         (cris_rtx_costs): Handle ZERO_EXTRACT.
2219         * config/cris/cris.md (tstdi, tst<mode>, cmpdi): Delete.
2220         (*tstdi_non_v32): Fold in *cmpdi_non_v32.
2221         (*tstdi_v32): Delete.
2222         (*cmpdi_non_v32): Add M alternative for operand 1.
2223         (cmpsi, cmp<mode>): Make private.
2224         (*tstsi, *tst<mode>_cmp, *tst<mode>_non_cmp, *btst): Wrap LHS
2225         with COMPARE.
2226         (cbranch<mode>4, cbranchdi4, cstore<mode>4): New.
2227
2228         * config/crx/crx.md (cstore<mode>4, cbranchcc4): New.
2229         (cmp<mode>, bCOND_internal, b<code>, s<code>): Delete.
2230         (cbranch<mode>4, sCOND_internal): Use ordered_comparison_operator.
2231         (cc_reg_operand): New.
2232         (any_cond): Delete.
2233         * config/crx/crx.c (crx_compare_op0, crx_compare_op1,
2234         crx_expand_compare, crx_expand_branch, crx_expand_scond): Delete.
2235         * config/crx/crx.h (crx_compare_op0, crx_compare_op1): Delete.
2236         * config/crx/crx-protos.h (crx_expand_compare, crx_expand_branch,
2237         crx_expand_scond): Delete.
2238
2239         * config/fr30/fr30.md (cmp<mode>, bCC): Delete.
2240         (cbranchsi4): New.
2241         * config/fr30/fr30.c (fr30_compare_op0, fr30_compare_op1): Delete
2242         * config/fr30/fr30.h (fr30_compare_op0, fr30_compare_op1): Delete.
2243
2244         * config/frv/frv.md (cbranchsi4, cbranchsf4, cbranchdf4,
2245         cstoresi4, cstoresf4, cstoredf4): New.
2246         (cmpdi, cmpsi, cmpsf, cmpdf, bCC, sCC): Remove.
2247         * config/frv/frv-protos.h (frv_emit_cbranch, frv_emit_scc):
2248         Receive the entire operands array.
2249         * config/frv/frv.h (frv_compare_op0, frv_compare_op1): Delete.
2250         * config/frv/frv.c (frv_compare_op0, frv_compare_op1): Delete.
2251         * config/frv/frv-protos.h (frv_emit_cbranch, frv_emit_scc):
2252         Get test/op0/op1 from the operands array.
2253         (frv_emit_cond_move): Get test/op0/op1 from the test_rtx.
2254
2255         * config/h8300/h8300-protos.h (h8300_expand_branch): Accept operands.
2256         (h8300_expand_store): New.
2257         * config/h8300/h8300.c (h8300_rtx_costs): Handle (compare FOO
2258         (const_int 0)).
2259         (h8300_expand_branch): Emit compare here.  Adjust for new arguments.
2260         (h8300_expand_store): New.
2261         * config/h8300/h8300.md (btst combine patterns): Wrap with COMPARE
2262         or do not try to produce (set (cc0) REG).
2263         (peepholes): Wrap arguments with COMPARE.  Add a peephole to
2264         change a compare into a move to a scratch register.  Disable some
2265         peepholes when comparing with zero.
2266         (tstsi, tsthi, tstsi, cmpqi): Make private.
2267         (cmphi): Delete.
2268         (bCC, sCC): Delete.
2269         (cbranchqi4, cbranchhi4, cbranchsi4, cstoreqi4, cstorehi4,
2270         cstoresi4): New.
2271
2272         * config/i386/i386.c (ix86_expand_int_movcc, ix86_expand_int_addcc,
2273         ix86_expand_fp_movcc): Set ix86_compare_op0 and ix86_compare_op1.
2274         (ix86_emit_i387_log1p): Use gen_cbranchxf4.
2275         (ix86_emit_i387_log1p): Use cbranchxf2.
2276         (ix86_expand_setcc): Return void.
2277         * config/i386/i386-protos.h (ix86_expand_setcc): Return void.
2278         * config/i386/i386.md (cmpti, cmpdi, cmpsi, cmphi, cmpqi, cmpxf,
2279         cmp<MODEF>, cmpcc): Remove.
2280         (cbranchti4, cbranchdi4, cbranchsi4, cbranchhi4, cbranchqi4,
2281         cbranchxf4, cbranch<MODEF>4, cbranchcc4, cstoredi4, cstoresi4,
2282         cstorehi4, cstoreqi4, cstorexf4, cstore<MODEF>4, cstorecc): New.
2283         (sCC and bCC expanders): Remove.
2284         (stack_protect_test): Use cbranchcc4.
2285
2286         * config/ia64/ia64-protos.h (ia64_compare_op0, ia64_compare_op1):
2287         Delete.
2288         (ia64_expand_compare): Accept three rtx by reference and return void.
2289         * config/ia64/ia64.c (ia64_compare_op0, ia64_compare_op1): Delete.
2290         (ia64_expand_compare): Replace op0/op1 with *op0/*op1.  Get code
2291         from *expr.  Update *expr with the BImode comparison to do.
2292         * config/ia64/ia64.md (cmpbi, cmpsi, cmpdi, cmpsf, cmpdf, cmpxf,
2293         cmptf, bCC, sCC, conditional_trap): Delete.
2294         (cbranchbi4, cbranchsi4, cbranchdi4, cbranchsf4, cbranchdf4, 
2295         cbranchxf4, cbranchtf4, cstorebi4, cstoresi4, cstoredi4, cstoresf4,
2296         cstoredf4, cstorexf4, cstoretf4, ctrapbi4, ctrapsi4, ctrapdi4,
2297         ctrapsf4, ctrapdf4, ctrapxf4, ctraptf4): New.
2298         * config/ia64/predicates.md (ia64_cbranch_operator): New.
2299
2300         * config/iq2000/iq2000-protos.h (gen_conditional_branch): Change
2301         type of last argument.
2302         * config/iq2000/iq2000.c (branch_cmp, branch_type): Remove.
2303         (gen_conditional_branch): Get code/cmp0/cmp1 from operands,
2304         use machine mode argument instead of branch_type.  Remove dead
2305         code for floating-point comparisons.
2306         * config/iq2000/iq2000.h (branch_cmp, branch_type): Remove.
2307         * config/iq2000/iq2000.md (cmpsi, cmpdi, cmpsf, cmpdf, tstsi, bCC):
2308         Remove.
2309         (cbranchsi4, cstoresi4): New.
2310         * config/iq2000/predicates.md (reg_or_const_operand): New.
2311
2312         * config/m32c/m32c.md (cbranch splitter): Use match_op_dup.
2313         * config/m32c/m32c.md (any_cond, gl_cond): Delete.
2314         (b<code>_op): Rewrite to...
2315         (bcc_op): ... this, using match_operator.
2316         (s<code>_op): Rewrite to...
2317         (scc_op): ... this, using match_operator.
2318         (s<code>_24_op): Rewrite to...
2319         (scc_op_24): ... this, using match_operator.
2320         (s<code>_<mode>): Rewrite to...
2321         (cstore<mode>4): ... this, using match_operator.
2322         (s<code>_<mode>_24): Rewrite to...
2323         (cstore<mode>4_24): ... this, using match_operator.
2324         * config/m32c/m32c-protos.h (m32c_cmp_flg_0, m32c_pend_compare,
2325         m32c_unpend_compare, m32c_expand_scc): Delete.
2326         * config/m32c/m32c.c (compare_op0, compare_op1, m32c_cmp_flg_0,
2327         m32c_pend_compare, m32c_unpend_compare, m32c_expand_scc): Delete.
2328         (m32c_expand_movcc): Change NE to EQ if necessary.
2329         (m32c_init_libfuncs): Modify cstore optab instead of setcc_gen_code.
2330
2331         * config/m32r/m32r-protos.h (gen_cond_store): New.
2332         * config/m32r/m32r.c (m32r_compare_op0, m32r_compare_op1): Delete.
2333         (gen_cond_store): New, from sCC patterns.
2334         (m32r_expand_block_move): Use cbranchsi4.
2335         * config/m32r/m32r.h (m32r_compare_op0, m32r_compare_op1): Delete.
2336         * config/m32r/m32r.md (cmpsi, bCC, sCC): Delete.
2337         (cbranchsi4, cstoresi4): New.
2338         
2339         * config/m68hc11/m68hc11.c (m68hc11_compare_op0, m68hc11_compare_op1):
2340         Delete.
2341         (m68hc11_rtx_costs_1, m68hc11_rtx_costs): Handle ZERO_EXTRACT.
2342         (m68hc11_notice_update_cc): Look into a compare with 0.
2343         * config/m68hc11/m68hc11.h (m68hc11_compare_op0, m68hc11_compare_op1):
2344         Delete.
2345         * config/m68hc11/m68hc11.md (tstsi, tsthi, tstqi, cmpsi,
2346         cmphi, cmpqi, bCC): Delete.
2347         (cbranchsi4, cbranchhi4, cbranchqi4): New.
2348         (tstqi_1, tstqi_z_used, tstqi_1, bitcmpqi, bitcmpqi_z_used,
2349         bitcmpqi_12, bitcmphi, various splits and peephole2s): Wrap cc0<-reg
2350         sets with COMPARE.
2351
2352         * config/m68k/predicates.md (m68k_cstore_comparison_operator,
2353         const0_operand, const1_operand, m68k_subword_comparison_operand): New.
2354         * config/m68k/constraints.md (H): New.
2355         * config/m68k/m68k.md (tstdi): Remove define_expand, use name for
2356         the define_insn below.
2357         (tstsi, tsthi, tst<FP:mode>, cmphi, cmpqi, cmp<FP:mode>): Delete.
2358         (*tstsi_internal_68020_cf, *tstsi_internal, *tsthi_internal,
2359         *tstqi_internal, tst<mode>_6881, tst<mode>_cf, many unnamed
2360         patterns): Wrap RHS with COMPARE.
2361         (tst<FP>_68881, tst<FP>_cf): Use const0_operand.
2362         (*cmpdi_internal): Name this pattern.
2363         (cmpdi): Change to define_insn.
2364         (cbranchdi4, cstoredi4, cbranchsi4, cstoresi4, cbranchhi4, cstorehi4,
2365         cbranchqi4, cstoreqi4, cbranch<FP:mode>4, cstore<FP:mode>4): New.
2366         (scc0_di, scc0_di_5200, scc_di): Use the ordered_comparison_operator
2367         predicate.
2368         (seq, sne, sgt, sgtu, slt, sltu, sge, sgeu, sle, sleu, sordered,
2369         sunordered, suneq, sunge, sungt, sunle, sunlt, sltgt): Delete
2370         (conditional_trap): Change to...
2371         (ctrapdi4, ctrapsi4, ctraphi4, ctrapqi4): ... these.
2372         (*conditional_trap): Use the ordered_comparison_operator and
2373         const1_operand predicates.
2374         * config/m68k/m68k.c (m68k_last_compare_had_fp_operands): Delete.
2375         (m68k_expand_prologue): Use ctrapsi4 instead of cmpsi+conditional_trap.
2376         (m68k_rtx_costs): Look for ZERO_EXTRACT in a COMPARE.
2377         * config/m68k/m68k.h (m68k_last_compare_had_fp_operands): Delete.
2378
2379         * config/mcore/mcore-protos.h (arch_compare_op0, arch_compare_op1,
2380         mcore_modify_comparison, mcore_gen_compare_reg): Remove.
2381         (mcore_gen_compare): New. 
2382         * config/mcore/mcore.c (arch_compare_op0, arch_compare_op1): Delete.
2383         (mcore_modify_comparison, mcore_gen_compare_reg): Fold into...
2384         (mcore_gen_compare): ... this.
2385         * config/mcore/mcore.md (cmpsi, bCC, sCC): Remove.
2386         (cbranchsi4, cstoresi4): New, using mcore_gen_compare.
2387         (stack probe pattern): Use cbranchsi4.
2388
2389         * config/mips/predicates.md (mips_cstore_operator): New.
2390         * config/mips/mips-ps-3d.md (movv2sfcc): Do not use cmp_operands.
2391         * config/mips/mips.md (any_cond): Delete.
2392         (conditional_trap): Rename to ctrap<GPR:mode>4.  Adjust predicates,
2393         always succeed.
2394         (fixuns_truncdfsi2, fixuns_truncdfdi2, fixuns_truncsfsi2,
2395         fixuns_truncsfdi2): Use cbranch patterns.
2396         (cmp<GPR:mode>, cmp<SCALARF:mode>): Delete. 
2397         (b<code>): Change to cbranch<GPR:mode>4 and cbranch<SCALARF:mode>4.
2398         Adjust call to mips_expand_conditional_branch.
2399         (seq, sne, slt<u>, sle<u>, sgt<u>, sge<u>): Change to
2400         cstore<GPR:mode>4.
2401         * config/mips/mips-protos.h (mips_expand_conditional_branch,
2402         mips_expand_scc, mips_expand_conditional_trap): Adjust prototypes.
2403         * config/mips/mips.c (cmp_operands): Delete.
2404         (mips_emit_compare): Get comparison operands from *op0/*op1.
2405         (mips_expand_scc): Get code/op0/op1/target from operands.  Assert
2406         that it succeeds.  Use op0/op1 instead of cmp_operands.
2407         (mips_expand_conditional_branch, mips_expand_conditional_move,
2408         mips_expand_conditional_trap): Likewise.
2409         (mips_block_move_loop): Use cbranch patterns. 
2410         * config/mips/mips.h (cmp_operands): Delete.
2411
2412         * config/mmix/mmix.c (mmix_valid_comparison): Delete.
2413         (mmix_gen_compare_reg): Just return a register in the right CC mode.
2414         * config/mmix/mmix.h (mmix_compare_op0, mmix_compare_op1): New.
2415         * config/mmix/mmix.md (cmpdi, cmpdf): Remove.
2416         (*cmpcc_folded): Rename to...
2417         (*cmpdi_folded): this.
2418         (*cmpcc): Rename to...
2419         (*cmps): ... this.
2420         (movdfcc, movdicc): Adjust for new semantics of mmix_gen_compare_reg.
2421         (bCC): Remove.
2422         (cbranchdi4): New.
2423         (cbranchdf4): New.  Handle invalid comparisons here.
2424         * config/mmix/predicates.md (float_comparison_operator): New.
2425
2426         * config/mn10300/mn10300.c (mn10300_rtx_costs): Consider 0 and
2427         zero_extract to be cheap in (compare (zero_extract) (const_int 0).
2428         * config/mn10300/mn10300.md (tst): Delete.
2429         (*tst_extqisi_am33, *tst_extqisi, *tst_exthisi_am33, *tst_exthisi):
2430         Name these patterns and wrap RHS in a compare.
2431         (*cmpsi): Make this pattern private.  Include tst.
2432         (*cmpsf): Make this pattern private.
2433         (and and zero_extract cc0 set): Wrap RHS in a COMPARE.
2434         (compare with zero peepholes): Likewise.
2435         (bCC): Remove.
2436         (cbranchsi4, cbranchsf4): New.
2437         (casesi): Use cbranchsi4.
2438
2439         * config/pa/pa.c (hppa_compare_op0, hppa_compare_op1,
2440         hppa_branch_type): Delete.
2441         (return_addr_rtx): Use cbranchsi4.
2442         (emit_bcond_fp): Accept all operands.  Replace CODE with NE.
2443         Emit CCFPmode comparison here.
2444         (gen_cmp_fp): Delete, now part of emit_bcond_fp.
2445         * config/pa/pa.h (enum cmp_type, hppa_compare_op0, hppa_compare_op1,
2446         hppa_branch_type): Delete.
2447         * config/pa/pa.md (cmpdi, cmpsi, cmpsf, cmpdf, sCC, bCC): Delete.
2448         (movsicc, movdicc): Remove references to hppa_compare_op0,
2449         hppa_compare_op1 and compare_from_rtx.
2450         (cbranchdi4, cbranchsi4, cbranchsf4, cbranchdf4, cstoresi4): New.
2451         (casesi): Use cbranchsi4.
2452
2453         * config/pdp11/pdp11-protos.h (output_jump): Change prototype.
2454         * config/pdp11/pdp11.c (output_jump): Embed opcodes here.
2455         * config/pdp11/pdp11.md (register_or_const0_operand): New.
2456         (cmpdf, cmphi, cmpqi): Make private.  Add tst alternatives.
2457         (cmpsi, tstsi, tstdf, tsthi, tstqi): Delete.
2458         (bCC): Delete.
2459         (cbranchdf4, cbranchhi4, cbranchqi4): New.
2460         (*branch, *branch_inverted): New.
2461
2462         * config/picochip/picochip.md (cbranchhi4): Use
2463         ordered_comparison_operator.
2464         (cmphi, bCC): Remove.
2465
2466         * config/rs6000/predicates.md (rs6000_cbranch_operator): New.
2467         (trap_comparison_operator): Delete.
2468         * config/rs6000/rs6000-protos.h (rs6000_emit_sCOND,
2469         rs6000_emit_cbranch): Accept mode and operands.
2470         * config/rs6000/rs6000.c (rs6000_compare_op0, rs6000_compare_op1,
2471         rs6000_compare_fp_p): Delete.   
2472         (rs6000_generate_compare): Accept mode and comparison.  Extract code
2473         and op0/op1 from there.  Replace references to rs6000_compare_op0
2474         and rs6000_compare_op1.
2475         (rs6000_emit_sCOND): Adjust call to rs6000_generate_compare and
2476         extract result from passed operands.
2477         (rs6000_emit_cbranch): Adjust call to rs6000_generate_compare and
2478         extract loc from passed operands.
2479         (rs6000_emit_cmove): Likewise.
2480         * config/rs6000/rs6000.h (rs6000_compare_op0, rs6000_compare_op1,
2481         rs6000_compare_fp_p): Delete.
2482         * config/rs6000/rs6000.md (cmp<GPR>, cmp<FP>, bCC, sCC): Delete.
2483         (cbranch<GPR>4, cbranch<FP>4): New.
2484         (cstore<mode>4): New.  Consolidate here all choices about when to use
2485         portable or specialized sCC sequences.
2486         (stack_protect_test): Use cbranchsi4.
2487         (conditional_trap): Replace with ctrap<GPR>4.
2488         (conditional trap insn): Replace trap_comparison_operator with
2489         ordered_comparison_operator. 
2490
2491         * config/s390/s390.c (s390_compare_op0, s390_compare_op1): Delete.
2492         (s390_emit_prologue): Use ctrap.
2493         * config/s390/s390.h (s390_compare_op0, s390_compare_op1): Delete.
2494         * config/s390/predicates.md (s390_eqne_operator, s390_scond_operator):
2495         New predicates replacing...
2496         * config/s390/s390.md (COMPARE, SCOND): ... these iterators.
2497         (cmp<GPR>, cmp<FP>, cmpcc): Delete.
2498         (trunc patterns): Use emit_cmp_and_jump_insns instead of cmp/branch.
2499         (add<mode>cc): Do not use s390_compare_op0/op1.
2500         (s<code>): Change to...
2501         (cstore<mode>4): ... this. Do not use s390_compare_op0/op1.
2502         (seq): Change to...
2503         (cstorecc4): ... this.  Handle EQ or NE equally.
2504         (*sne): Un-privatize for use in cstorecc4.
2505         (b<code>): Change to...
2506         (cbranch<GPR>4, cbranch<FP>4, cbranchcc4): ... these.
2507         (conditional_trap): Replace with...
2508         (ctrap<GPR>4, ctrap<FP>4): ... these.
2509         (stack_protect): Use cbranchcc4.
2510
2511         * config/score/score-conv.h (cmp_op0, cmp_op1): Delete.
2512         * config/score/score-protos.h (score_gen_cmp): Delete.
2513         * config/score/score.c (cmp_op0, cmp_op1, score_gen_cmp): Delete.
2514         (score_block_move-loop): Use cbranchsi4.
2515         * config/score/score.md (cbranchsi4): New.
2516         (cmpsi, bCC): Delete.
2517         * config/score/score3.c (cmp_op0, cmp_op1, score3_gen_cmp): Delete.
2518         (score3_movsicc): Use ops[1] operands instead of cmp_op0/cmp_op1.
2519         * config/score/score7.c (cmp_op0, cmp_op1, score7_gen_cmp): Delete.
2520         (score7_movsicc): Use ops[1] operands instead of cmp_op0/cmp_op1.
2521         * config/score/score3.h (score3_gen_cmp): Delete.
2522         * config/score/score7.h (score7_gen_cmp): Delete.
2523
2524         * config/sh/sh-protos.h (prepare_scc_operands): Rename to...
2525         (sh_emit_scc_to_t): ... this.  Return void.
2526         (from_compare): Rename to...
2527         (sh_emit_compare_and_branch): ... this.
2528         (sh_emit_compare_and_set): New.
2529         (sh_expand_t_scc): Accept operands.
2530         * config/sh/predicates.md (sh_float_comparison_operator): New.
2531         * config/sh/sh.c (sh_compare_op0, sh_compare_op1): Delete.
2532         (prepare_scc_operands): Rename to...
2533         (sh_emit_scc_to_t): ... this.  Return void.  Get op0/op1 from
2534         arguments.
2535         (sh_emit_cheap_store_flag): New.
2536         (sh_emit_set_t_insn): New.
2537         (from_compare): Rename to...
2538         (sh_emit_compare_and_branch): ... this.  Accept mode.  Rewrite
2539         handling of TARGET_SH2E floating point to avoid recursive call.
2540         Generate branch here.
2541         (sh_emit_compare_and_set): New.
2542         (sh_expand_t_scc): Get op0/op1 from arguments.
2543         (sh_emit_cheap_store_flag): New.
2544         * config/sh/sh.md (cbranchdi4, cbranchsi4): Include -mno-cbranchdi
2545         cases.
2546         (cbranchdi4_i): Use an "I08" constraint instead of an "i" constraint.
2547         (cmpsi, cmpdi, cmpsf, cmpdf): Delete.
2548         (movsicc, movdicc): Do nothing when it recreated operands from
2549         sh_compare_*. Use sh_emit_cheap_store_flag.  Adjust call to
2550         prepare_scc_operands (now sh_emit_scc_to_t).
2551         (udivdi3): Use cstoresi4.
2552         (beq_media, bne_media, bge_media, bgtu_media, bgeu_media, beq,
2553         bne, bgt, blt, ble, bge, bgtu, bltu, bgeu, bleu, bunordered): Delete.
2554         (cbranchint4_media, cbranchfp4_media): New.
2555         (casesi): Use cbranchdi4.
2556         (seq, slt, sle, sgt, sge, sgtu, sltu, sgeu, sne, sleu, sunordered):
2557         Delete.
2558         (cstore4_media, cstoresi4, cstoredi4, cstoresf4, cstoredf4): New.
2559         (movnegt): Remove second operand.
2560         (cbranchsf4, cbranchdf4): New.
2561         (stack_protect): Use cbranchdi4/cbranchsi4.
2562
2563         * config/sparc/sparc.c (sparc_compare_op0, sparc_compare_op1): Delete.
2564         (gen_compare_reg): Accept comparison, extract part of it to...
2565         (gen_compare_reg_1): ... this. 
2566         (gen_compare_operator): Delete.
2567         (gen_v9_scc): Accept separate destination, comparison code and arms.
2568         Do not use sparc_compare_op0/sparc_compare_op1.
2569         (emit_scc_insn, emit_conditional_branch_insn): New.
2570         (emit_v9_brxx): Make static.  Remove useless assertion.
2571         (sparc_emit_float_lib_cmp): Return RTL instead of calling
2572         emit_cmp_insn.
2573         (sparc_expand_compare_and_swap_12): Use gen_compare_reg_1+cbranchcc4.
2574         * config/sparc/sparc-protos.h (gen_compare_reg,
2575         sparc_emit_float_lib_cmp): Adjust prototype.
2576         (emit_scc_insn, emit_conditional_branch_insn): New.
2577         (gen_v9_scc, emit_v9_brxx_insn, gen_compare_operator): Delete.
2578         * config/sparc/sparc.h (sparc_compare_op0, sparc_compare_op1): Delete.
2579         * config/sparc/sparc.md (P, I, F, V32, V32I, V64, V64I): Move all
2580         iterators to the top.
2581         (cmpsi, cmpdi, cmpsf, cmpdf, cmptf, seqsi_special_extend,
2582         snesi_special_extend, sCC, bCC, seqdi_special_trunc,
2583         snedi_special_trunc): Delete.
2584         (seqdi_special, snedi_special): Use expansion of seqdi_special_trunc
2585         and snedi_special_trunc.
2586         (cstoresi4, cstoredi4, cstore<F:mode>4, cbranchcc4, cbranchsi4,
2587         cbranchdi4, cbranch<F:mode>4): New.
2588         (mov<I:mode>cc, mov<F:mode>cc): Handle sparc_emit_float_lib_cmp
2589         here.  Use gen_compare_reg instead of gen_compare_operator.
2590         (conditional_trap): Replace with...
2591         (ctrapsi4, ctrapdi4): ... this.
2592         (stack_protect_test): Use cbranchcc4.
2593
2594         * config/spu/spu-protos.h (spu_emit_branch_or_set): Change second
2595         argument to rtx.
2596         * config/spu/spu.c (spu_compare_op0, spu_compare_op1): Remove. 
2597         (spu_emit_branch_or_set): Get code/op0/op1 from second argument.
2598         Change spu_compare_op0/op1 to op0/op1 throughout.  Get target
2599         from operands[0] or operands[3] depending on is_set.
2600         * config/spu/spu.h (spu_compare_op0, spu_compare_op1): Remove.
2601         * config/spu/spu.md (cmp<mode:VQHSI>, cmp<mode:DTI>, cmp<mode:VSF>,
2602         cmpdf, bCC), sCC: Remove.
2603         (cbranch<mode:VQHSI>4, cbranch<mode:DTI>, cbranch<mode:VSF>4, 
2604         cbranchdf4, cstore<mode:VQHSI>4, cstore<mode:DTI>, cstore<mode:VSF>4,
2605         cstoredf4): New.
2606         (mov<mode>cc): Accept ordered_comparison_operator, adjust call to
2607         spu_emit_branch_or_set.
2608
2609         * config/stormy16/stormy16-protos.h (xstormy16_emit_cbranch):
2610         Add two arguments.
2611         * config/stormy16/stormy16.h (xstormy16_compare_op0,
2612         xstormy16_compare_op1): Delete.
2613         * config/stormy16/stormy16.c (xstormy16_compare_op0,
2614         xstormy16_compare_op1): Delete. 
2615         (xstormy16_emit_cbranch): Get op0/op1 from the new arguments.
2616         Adjust calls.
2617         * config/stormy16/stormy16.md (cbranchsi4, cbranchhi4): New.
2618         (cmphi, cmpsi, bCC): Remove.
2619
2620         * config/v850/v850.md (tstsi, cmpsi): Fold into...
2621         (*cmpsi): ... this one.
2622         (cbranchsi4, cstoresi4): New.
2623         (bCC expanders): Delete.
2624         (sCC insns): Fold into...
2625         (*setcc): ... this one.
2626         (casesi): Do not use gen_cmpsi and gen_bgtu. 
2627         (various splits): Wrap "naked" RHS of a cc0 set with COMPARE.
2628         (movsicc): Simplify.
2629         * config/v850/v850.c (v850_rtx_costs): Handle ZERO_EXTRACT in COMPARE.
2630
2631         * config/vax/vax-protos.h (cond_name): New.
2632         (vax_output_conditional_branch): Remove.
2633         * config/vax/vax.c (cond_name): New.
2634         (vax_output_conditional_branch): Remove.
2635         * config/vax/vax.h (PRINT_OPERAND): Dispatch %c to cond_name.
2636         * config/vax/vax.md (tst<VAXint>, tst<VAXfp>): Remove.
2637         (cmp<VAXint>, cmp<VAXfp>): Privatize.  Add constraints for tst.
2638         (bit<VAXint>): Wrap source with (compare).
2639         (b<code> and following unnamed pattern): Rename to *branch and
2640         *branch_reversed.  Change macroization to match_operator.
2641         (cbranch<VAXint>4, cbranch<VAXfp>4): New.
2642
2643         * config/xtensa/predicates.md (xtensa_cstoresi_operator): New.
2644         * config/xtensa/xtensa-protos.h (xtensa_expand_conditional_branch):
2645         Change last argument to machine_mode.
2646         (xtensa_expand_scc): Add machine_mode argument.
2647         * config/xtensa/xtensa.c (branch_cmp, branch_type): Remove.
2648         (gen_conditional_move, xtensa_expand_conditional_branch,
2649         xtensa_expand_scc, xtensa_expand_conditional_move): Use mode
2650         instead of branch_type, fetch cmp0/cmp1/test_code from operands[].
2651         Adjust operand numbers.
2652         * config/xtensa/xtensa.h (enum cmp_type, branch_cmp, branch_type):
2653         Delete.
2654         * config/xtensa/xtensa.md (any_cond, any_scc): Delete.
2655         (cmpsi, cmpsf, b<code>, s<code>): Delete.
2656         (cbranchsi4, cbranchsf4, cstoresi4, cstoresf4): New.
2657
2658 2009-05-12  Paolo Bonzini  <bonzini@gnu.org>
2659
2660         * optabs.c (prepare_cmp_insn): Temporarily disable test that
2661         causes spurious differences between trunk and cond-optab branch.
2662
2663 2009-05-12  Alexandre Oliva  <aoliva@redhat.com>
2664
2665         PR target/37137
2666         * doc/install.texi (STAGE1_TFLAGS, BUILD_CONFIG): Document.
2667
2668 2009-05-12  Alexandre Oliva  <aoliva@redhat.com>
2669
2670         * tree.c (iterative_hash_pointer): Delete.
2671         (iterative_hash_expr): Short-circuit handling of NULL pointer.
2672         Hash UIDs and versions of SSA names.  Don't special-case built-in
2673         function declarations.
2674
2675 2009-05-11  Ian Lance Taylor  <iant@google.com>
2676
2677         PR bootstrap/40103
2678         * graphite.c: Force -Wc++-compat to only be a warning before
2679         #including "cloog/cloog.h".
2680
2681 2009-05-11  Martin Jambor  <mjambor@suse.cz>
2682
2683         * ipa-cp.c (ipcp_cloning_candidate_p): Add missing return false.
2684         
2685 2009-05-11  Jan Hubicka  <jh@suse.cz>
2686
2687         * tree-ssa-loop-ivcanon.c: Include target.h
2688         (struct loop_size): new structure.
2689         (constant_after_peeling): New predicate.
2690         (tree_estimate_loop_size): New function.
2691         (estimated_unrolled_size): Rewrite for new estimates.
2692         (try_unroll_loop_completely): Use new estimates.
2693         * Makefile.in (tree-ssa-loop-ivcanon.o): Add dependenc on target.h
2694
2695 2009-05-11  Andrew Pinski  <andrew_pinski@playstation.sony.com>
2696
2697         * config/spu/spu-c.c (spu_categorize_keyword): Update for recent
2698         libcpp interface change.
2699         (spu_macro_to_expand): Likewise.
2700
2701 2009-05-11  Paolo Bonzini  <bonzini@gnu.org>
2702
2703         PR tree-optimization/40026
2704         * gimplify.c (gimplify_init_constructor): Change initial conditional
2705         to assertion.  Rewrite TREE_OPERAND (*expr_p, 1) after
2706         optimize_compound_literals_in_ctor.
2707
2708 2009-05-11  Nathan Sidwell  <nathan@codesourcery.com>
2709
2710         * config/m68k/m68k-devices.def (52274, 52277, 5301x, 5225x, 51xx):
2711         New devices.
2712         * doc/invoke.texi (M680x0 Options): Document new coldfire cpus.
2713
2714 2009-05-11  H.J. Lu  <hongjiu.lu@intel.com>
2715
2716         * tree-vect-data-refs.c (vect_analyze_group_access): Use
2717         HOST_WIDE_INT for gap.
2718
2719 2009-05-11  Ira Rosen  <irar@il.ibm.com>
2720
2721         PR tree-optimization/40074
2722         * tree-vect-data-refs.c (vect_analyze_group_access): Take gaps into
2723         account in group size and step comparison.
2724
2725 2009-05-11  Richard Guenther  <rguenther@suse.de>
2726
2727         * passes.c (init_optimization_passes): Strip now incorrect comment.
2728         (execute_function_todo): Do not set PROP_alias.
2729         * tree-pass.h (PROP_alias): Remove.
2730         * tree-ssa-structalias.c (pass_build_alias): Do not provide PROP_alias.
2731         * tree-if-conv.c (pass_if_conversion): Do not require PROP_alias.
2732         * tree-nrv.c (pass_return_slot): Likewise.
2733         * tree-object-size.c (pass_object_sizes): Likewise.
2734         * tree-ssa-dom.c (pass_dominator): Likewise.
2735         (pass_phi_only_cprop): Likewise.
2736         * tree-ssa-dse.c (pass_dse): Likewise.
2737         * tree-ssa-phiopt.c (pass_phiopt): Likewise.
2738         (pass_cselim): Likewise.
2739         * tree-ssa-pre.c (pass_pre): Likewise.
2740         (pass_fre): Likewise.
2741         * tree-ssa-reassoc.c (pass_reassoc): Likewise.
2742         * tree-ssa-sink.c (pass_sink_code): Likewise.
2743         * tree-stdarg.c (pass_stdarg): Likewise.
2744         * tree-tailcall.c (pass_tail_calls): Likewise.
2745         * tree-vrp.c (pass_vrp): Likewise.
2746
2747 2009-05-10  Ian Lance Taylor  <iant@google.com>
2748
2749         * basic-block.h (enum profile_status): Break out of struct
2750         control_flow_graph.
2751         * cgraph.h (struct inline_summary): Break out of struct
2752         cgraph_local_info.
2753         * cgraphunit.c (enum cgraph_order_sort_kind): New enum, broken out
2754         of struct cgraph_order_sort.
2755         * combine.c (enum undo_kind): New enum, broken out of struct undo.
2756         * cse.c (struct branch_path): Break out of struct
2757         cse_basic_block_data.
2758         * except.h (enum eh_region_type): Break out of struct eh_region.
2759         * gcc.c (enum add_del): Break out of struct modify_target.
2760         * genrecog.c (enum decision_type): Break out of struct decision_test.
2761         * ggc-page.c (struct ggc_pch_ondisk): Break out of struct
2762         ggc_pch_data.
2763         * matrix-reorg.c (struct free_info): Break out of struct matrix_info.
2764         * regmove.c (enum match_use): New enum, broken out of struct match.
2765         * sched-int.h (enum post_call_group): New enum, broken out of
2766         struct deps.
2767         (struct deps_reg): Break out of struct deps.
2768         * target.h (struct asm_int_op): Break out of struct gcc_target.
2769         * tree-eh.c (struct goto_queue_node): Break out of struct
2770         leh_tf_state.
2771         * tree-inline.h (enum copy_body_cge_which): Break out of
2772         copy_body_data.
2773         * tree-pass.h (enum opt_pass_type): Break out of struct opt_pass.
2774
2775         * c-decl.c (in_struct, struct_types): New static variables.
2776         (pushtag): Add loc parameter.  Change all callers.
2777         (lookup_tag): Add ploc parameter.  Change all callers.
2778         (check_compound_literal_type): New function.
2779         (parser_xref_tag): Add loc parameter.  Change all callers.  If
2780         -Wc++-compat, warn about struct/union/enum types defined within a
2781         struct or union.
2782         (start_struct): Add enclosing_in_struct, enclosing_struct_types,
2783         and loc parameters.  Change all callers.  Change error calls to
2784         error_at, using loc.  For a redefinition, if the location of the
2785         original definition is known, report it.  Set in_struct and
2786         struct_types.  If -Wc++-compat warn if in sizeof, typeof, or alignof.
2787         (finish_struct): Add new parameters enclosing_in_struct and
2788         enclosing_struct_types.  Change all callers.  Set
2789         C_TYPE_DEFINED_IN_STRUCT for all struct/union/enum types defined
2790         in the struct.  If in a struct, add this struct to struct_types.
2791         (start_enum): Add loc parameter.  Change all callers.  Use
2792         error_at for errors, using loc.  For a redefinition, if the
2793         location of the original definition is known, report it.  If in a
2794         struct, add this enum type to struct_types.  If -Wc++-compat warn
2795         if in sizeof, typeof, or alignof.
2796         * c-parser.c (disable_extension_diagnostics): Disable -Wc++-compat.
2797         (enable_extension_diagnostics): Reenable -Wc++-compat if appropriate.
2798         (c_parser_enum_specifier): Get enum location for start_enum.
2799         (c_parser_struct_or_union_specifier): Get struct location for
2800         start_struct.  Save in_struct and struct_types status between
2801         start_struct and finish_struct.
2802         (c_parser_cast_expression): Get location of cast.
2803         (c_parser_alignof_expression): Get location of type.
2804         (c_parser_postfix_expression): Likewise.
2805         (c_parser_postfix_expression_after_paren_type): Add type_loc
2806         parameter.  Change all callers.  Call check_compound_literal_type.
2807         Use type_loc for error about variable size type.
2808         * c-typeck.c (build_external_ref): If -Wc++-compat, warn about a use
2809         of an enum constant from an enum type defined in a struct or union.
2810         (c_cast_expr): Add loc parameter.  Change all callers.  If
2811         -Wc++-compat, warn about defining a type in a cast.
2812         * c-tree.h (C_TYPE_DEFINED_IN_STRUCT): Define.
2813         (start_enum, start_struct, finish_struct): Update declarations.
2814         (parser_xref_tag, c_cast_expr): Update declarations.
2815         (check_compound_literal_type): Declare.
2816
2817 2009-05-11  Ben Elliston  <bje@au.ibm.com>
2818
2819         * config/rs6000/rs6000-c.c (altivec_categorize_keyword): Update
2820         for recent libcpp interface change.
2821         (rs6000_macro_to_expand): Likewise.
2822
2823 2009-05-10  Michael Matz  <matz@suse.de>
2824
2825         PR target/40031
2826         * config/arm/arm.c (require_pic_register): Emit on entry edge,
2827         not at entry of function.
2828
2829 2009-05-10  Richard Guenther  <rguenther@suse.de>
2830
2831         PR tree-optimization/40081
2832         Revert
2833         * tree-sra.c (instantiate_element): Instantiate scalar replacements
2834         using the main variant of the element type.  Do not fiddle with
2835         TREE_THIS_VOLATILE or TREE_SIDE_EFFECTS.
2836
2837         * tree-sra.c (sra_type_can_be_decomposed_p): Do not decompose
2838         structs with volatile fields.
2839
2840 2009-05-10  Jan Hubicka  <jh@suse.cz>
2841
2842         * tree-inline.c (delete_unreachable_blocks_update_callgraph): Declare.
2843         (estimate_move_cost): Assert that it does not get called for
2844         VOID_TYPE_P.
2845         (estimate_num_insns): Skip VOID types in argument handling.
2846         (optimize_inline_calls): Delete unreachable blocks and verify that
2847         callgraph is valid.
2848
2849 2009-05-10  Jan Hubicka  <jh@suse.cz>
2850
2851         * cgraphbuild.c (record_reference): Use cgraph_mark_address_taken_node.
2852         * cgraph.c (cgraph_mark_address_taken_node): New function.
2853         (dump_cgraph_node): Dump new flag.
2854         * cgraph.h (struct cgraph_node): Add address_taken.
2855         (cgraph_mark_address_taken_node): New function.
2856         * ipa.c (cgraph_postorder): Prioritize functions with address taken
2857         since new direct calls can be born.
2858
2859 2009-05-10  Joseph Myers  <joseph@codesourcery.com>
2860
2861         * c-lex.c (c_lex_with_flags): Expect cpp_hashnode in
2862         tok->val.node.node.
2863
2864 2009-05-10  Jan Hubicka  <jh@suse.cz>
2865
2866         PR middle-end/40084
2867         * cgraph.c (cgraph_update_edges_for_call_stmt_node): Take old_call
2868         argument; rewrite.
2869         (cgraph_update_edges_for_call_stmt): Take old_decl argument.
2870         * cgraph.h (cgraph_update_edges_for_call_stmt): Update prototype.
2871         * tree-inline.c (copy_bb): Set frequency correctly.
2872         (fold_marked_statements): Update call to
2873         cgraph_update_edges_for_call_stmt.
2874
2875 2009-05-10  Joseph Myers  <joseph@codesourcery.com>
2876
2877         * config/arc/arc.c (arc_handle_interrupt_attribute): Use %qE for
2878         identifiers in diagnostics.
2879         * config/arm/arm.c (arm_handle_fndecl_attribute,
2880         arm_handle_isr_attribute): Likewise.
2881         * config/avr/avr.c (avr_handle_progmem_attribute,
2882         avr_handle_fndecl_attribute, avr_handle_fntype_attribute): Likewise.
2883         * config/bfin/bfin.c (handle_int_attribute,
2884         bfin_handle_longcall_attribute, bfin_handle_l1_text_attribute,
2885         bfin_handle_l1_data_attribute, bfin_handle_longcall_attribute,
2886         bfin_handle_l1_text_attribute, bfin_handle_l1_data_attribute):
2887         Likewise.
2888         * config/darwin.c (darwin_handle_kext_attribute,
2889         darwin_handle_weak_import_attribute): Likewise.
2890         * config/h8300/h8300.c (h8300_handle_fndecl_attribute,
2891         h8300_handle_eightbit_data_attribute,
2892         h8300_handle_tiny_data_attribute): Likewise.
2893         * config/i386/i386.c (ix86_handle_cconv_attribute,
2894         ix86_handle_abi_attribute, ix86_handle_struct_attribute): Likewise.
2895         * config/i386/winnt.c (ix86_handle_shared_attribute,
2896         ix86_handle_selectany_attribute): Likewise.
2897         * config/ia64/ia64.c (ia64_handle_model_attribute): Likewise.
2898         * config/m32c/m32c.c (function_vector_handler): Likewise.
2899         * config/m68hc11/m68hc11.c (m68hc11_handle_page0_attribute,
2900         m68hc11_handle_fntype_attribute): Likewise.
2901         * config/m68k/m68k.c (m68k_handle_fndecl_attribute): Likewise.
2902         * config/mcore/mcore.c (mcore_handle_naked_attribute): Likewise.
2903         * config/mips/mips.c (mips_insert_attributes,
2904         mips_merge_decl_attributes, mips_expand_builtin): Likewise.
2905         * config/rs6000/rs6000.c (rs6000_handle_longcall_attribute,
2906         rs6000_handle_struct_attribute): Likewise.
2907         * config/sh/sh.c (sh_insert_attributes,
2908         sh_handle_resbank_handler_attribute,
2909         sh_handle_interrupt_handler_attribute,
2910         sh2a_handle_function_vector_handler_attribute,
2911         sh_handle_sp_switch_attribute, sh_handle_trap_exit_attribute):
2912         Likewise.
2913         * config/sh/symbian.c (sh_symbian_mark_dllimport): Likewise.
2914         * config/spu/spu.c (spu_handle_fndecl_attribute,
2915         spu_handle_vector_attribute): Likewise.
2916         * config/stormy16/stormy16.c
2917         (xstormy16_handle_interrupt_attribute): Likewise.
2918         * config/v850/v850-c.c (ghs_pragma_section): Likewise.
2919         * config/v850/v850.c (v850_handle_interrupt_attribute): Likewise.
2920
2921 2009-05-10  Joseph Myers  <joseph@codesourcery.com>
2922
2923         * pretty-print.h (struct pretty_print_info): Add translate_identifiers.
2924         (pp_translate_identifiers): New.
2925         (pp_identifier): Only conditionally translate identifier to locale
2926         character set.
2927         * pretty-print.c (pp_construct): Set pp_translate_identifiers.
2928         (pp_base_tree_identifier): Only conditionally translate identifier
2929         to locale character set.
2930         * c-pretty-print.c (M_): Define.
2931         (pp_c_type_specifier, pp_c_primary_expression): Mark English
2932         fragments for conditional translation with M_.
2933         * tree-pretty-print.c (maybe_init_pretty_print): Disable
2934         identifier translation.
2935
2936 2009-05-10  Richard Guenther  <rguenther@suse.de>
2937
2938         PR tree-optimization/40081
2939         * tree-sra.c (instantiate_element): Instantiate scalar replacements
2940         using the main variant of the element type.  Do not fiddle with
2941         TREE_THIS_VOLATILE or TREE_SIDE_EFFECTS.
2942
2943 2009-05-09  Jan Hubicka  <jh@suse.cz>
2944
2945         PR middle-end/40080
2946         * cgraphunit.c (cgraph_materialize_all_clones): Do not redirect
2947         indirect calls; verify cgraph afterwards.
2948
2949 2009-05-09  Jan Hubicka  <jh@suse.cz>
2950
2951         PR bootstrap/40082
2952         * ipa.c (update_inlined_to_pointer): New function.
2953         (cgraph_remove_unreachable_nodes): Use it.
2954
2955 2009-05-09  Jan Hubicka  <jh@suse.cz>
2956
2957         * tree-eh.c (struct leh_state): Remove prev_try.
2958         (lower_try_finally, lower_catch, lower_eh_filter, lower_cleanup): Do
2959         not track prev_try.
2960         * except.c (gen_eh_region_cleanup, duplicate_eh_regions, 
2961         copy_eh_region_1, copy_eh_region, redirect_eh_edge_to_label,
2962         remove_eh_handler_and_replace, foreach_reachable_handler,
2963         verify_eh_region, verify_eh_tree): Remove tracking of prev_try pointer.
2964         * except.h (struct eh_region): Remove eh_region_u_cleanup.
2965         (gen_eh_region_cleanup): Update prototype.
2966
2967 2009-05-09  Jan Hubicka  <jh@suse.cz>
2968
2969         PR middle-end/40043
2970         * except.c (copy_eh_region): Always set prev_try.
2971         (redirect_eh_edge_to_label): Find outer try.
2972         (foreach_reachable_handler): When looking for prev try
2973         handle case where previous try is not going to be taken.
2974
2975 2009-05-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
2976
2977         PR tree-optimization/40049
2978         * tree-vect-stmts.c (vectorizable_operation): If the machine has
2979         only vector/vector shifts, convert the type of the constant to the
2980         appropriate type to avoid building incorrect trees, which
2981         eventually have problems with garbage collection.
2982
2983 2009-05-08  Joseph Myers  <joseph@codesourcery.com>
2984
2985         * fold-const.c (fold_binary): Do not fold multiplication by 1 or
2986         -1 for complex floating-point types if honoring signed zeros.
2987
2988 2009-05-08  Jan Hubicka  <jh@suse.cz>
2989
2990         * cgraphbuild.c (compute_call_stmt_bb_frequency): Accept function
2991         argument; handle correctly when profile is absent.
2992         (build_cgraph_edges): Update.
2993         (rebuild_cgraph_edges): Update.
2994         * cgraph.c: Do not include varray.h.
2995         (cgraph_set_call_stmt_including_clones): New function.
2996         (cgraph_create_edge_including_clones): Likewise
2997         (cgraph_update_edges_for_call_stmt_node): New static cfunction.
2998         (cgraph_update_edges_for_call_stmt): Handle clones.
2999         (cgraph_remove_node): Handle clone tree.
3000         (cgraph_remove_node_and_inline_clones): New function.
3001         (dump_cgraph_node): Dump clone tree.
3002         (cgraph_clone_node): Handle clone tree.
3003         (clone_function_name): Bring here from tree-inline.c.
3004         (cgraph_create_virtual_clone): New function.
3005         * cgraph.h (ipa_replace_map): Move here from ipa.h.
3006         (cgraph_clone_info): New function.
3007         (strut cgraph_node): Add clone_info and new clone tree pointers.
3008         (cgraph_remove_node_and_inline_clones,
3009         cgraph_set_call_stmt_including_clones,
3010         cgraph_create_edge_including_clones,
3011         cgraph_create_virtual_clone): Declare.
3012         (cgraph_function_versioning): Use VEC argument.
3013         (compute_call_stmt_bb_frequency): Update prototype.
3014         (cgraph_materialize_all_clones): New function.
3015         * ipa-cp.c (ipcp_update_cloned_node): Remove.
3016         (ipcp_create_replace_map): Update to VECtors.
3017         (ipcp_update_callgraph): Use virtual clones.
3018         (ipcp_update_bb_counts, ipcp_update_edges_counts): Remove.
3019         (ipcp_update_profiling): Do not update local profiling.
3020         (ipcp_insert_stage): Use VECtors and virtual clones.
3021         * cgraphunit.c (verify_cgraph_node): Verify clone tree.
3022         (clone_of_p): New function.
3023         (cgraph_preserve_function_body_p): Use clone tree.
3024         (cgraph_optimize): Materialize clones.
3025         (cgraph_function_versioning): Update for VECtors.
3026         (save_inline_function_body): Use clone tree.
3027         (cgraph_materialize_clone): New function.
3028         (cgraph_materialize_all_clones): Likewise.
3029         * ipa-inline.c (cgraph_default_inline_p): Use analyzed flags.
3030         * ipa.c: Include gimple.h.
3031         (cgraph_remove_unreachable_nodes): Use clone tree.
3032         * ipa-prop.c (ipa_note_param_call): Update call to
3033         compute_call_stmt_bb_frequencycall.
3034         * ipa-prop.h (ipa_replace_map): Move to cgraph.h.
3035         * tree-inline.c: Do not include varray.h or gt-tree-inline.h.
3036         (copy_bb): Handle updating of clone tree; add new edge when new call
3037         appears.
3038         (expand_call_inline): Be strict about every call having edge.
3039         (clone_fn_id_num, clone_function_name): Move to cgraph.c.
3040         (delete_unreachable_blocks_update_callgraph): New function.
3041         (tree_function_versioning): Use VECtors; always remove unreachable
3042         blocks and fold conditionals.
3043         * tree-inline.h: Do not include varray.h.
3044         (tree_function_versioning): Remove.
3045         * Makefile.in (GTFILES): Remove tree-inline.c
3046         * passes.c (do_per_function): Do only functions having body.
3047         * ipa-struct-reorg.c (do_reorg_1, collect_data_accesses): Handle clone
3048         tree.
3049
3050 2009-05-08  H.J. Lu  <hongjiu.lu@intel.com>
3051             Andrew Morrow  <acm@google.com>
3052
3053         PR c/36892
3054         * c-common.c (c_common_attribute_table): Permit deprecated
3055         attribute to take an optional argument.
3056         (handle_deprecated_attribute): If the optional argument to
3057         __attribute__((deprecated)) is not a string ignore the attribute
3058         and emit a warning.
3059
3060         * c-decl.c (grokdeclarator): Updated warn_deprecated_use call.
3061         * c-typeck.c (build_component_ref): Likewise.
3062         (build_external_ref): Likewise.
3063
3064         * toplev.c (warn_deprecated_use): Add an attribute argument.
3065         Emit the message associated with __attribute__((deprecated)).
3066
3067         * toplev.h (warn_deprecated_use): Updated.
3068
3069         * doc/extend.texi: Document new optional parameter to
3070         __attribute__((deprecated))
3071
3072 2009-05-08  Michael Eager <eager@eagercon.com>
3073
3074         * config/rs6000/rs6000.md (*movdf_softfloat32): replace
3075         !TARGET_DOUBLE_FLOAT with TARGET_SINGLE_FLOAT.
3076
3077 2009-05-08  Richard Guenther  <rguenther@suse.de>
3078
3079         PR tree-optimization/40062
3080         * tree-scalar-evolution.c (follow_ssa_edge_in_condition_phi):
3081         Avoid exponential behavior.
3082
3083 2009-05-08  Paolo Bonzini  <bonzini@gnu.org>
3084
3085         PR rtl-optimization/33928
3086         PR 26854
3087         * fwprop.c (use_def_ref, get_def_for_use, bitmap_only_bit_bitween,
3088         process_uses, build_single_def_use_links): New.
3089         (update_df): Update use_def_ref.
3090         (forward_propagate_into): Use get_def_for_use instead of use-def
3091         chains.
3092         (fwprop_init): Call build_single_def_use_links and let it initialize
3093         dataflow.
3094         (fwprop_done): Free use_def_ref.
3095         (fwprop_addr): Eliminate duplicate call to df_set_flags.
3096         * df-problems.c (df_rd_simulate_artificial_defs_at_top, 
3097         df_rd_simulate_one_insn): New.
3098         (df_rd_bb_local_compute_process_def): Update head comment.
3099         (df_chain_create_bb): Use the new RD simulation functions.
3100         * df.h (df_rd_simulate_artificial_defs_at_top, 
3101         df_rd_simulate_one_insn): New.
3102         * opts.c (decode_options): Enable fwprop at -O1.
3103         * doc/invoke.texi (-fforward-propagate): Document this.
3104
3105 2009-05-08  Joseph Myers  <joseph@codesourcery.com>
3106
3107         PR c/24581
3108         * c-typeck.c (build_binary_op): Handle arithmetic between one real
3109         and one complex operand specially.
3110         * tree-complex.c (some_nonzerop): Do not identify a real value as
3111         zero if flag_signed_zeros.
3112
3113 2009-05-08  Paolo Bonzini  <bonzini@gnu.org>
3114
3115         PR rtl-optimization/33928
3116         * loop-invariant.c (record_use): Fix && vs. || mishap.
3117
3118 2009-05-08  Paolo Bonzini  <bonzini@gnu.org>
3119
3120         PR rtl-optimization/33928
3121         * loop-invariant.c (struct use): Add addr_use_p.
3122         (struct def): Add n_addr_uses.
3123         (struct invariant): Add cheap_address.
3124         (create_new_invariant): Set cheap_address.
3125         (record_use): Accept df_ref.  Set addr_use_p and update n_addr_uses.
3126         (record_uses): Pass df_ref to record_use.
3127         (get_inv_cost): Do not add inv->cost to comp_cost for cheap addresses
3128         used only as such.
3129
3130 2009-05-08  Kaz Kojima  <kkojima@gcc.gnu.org>
3131
3132         * config/sh/sh.c: Do not include c-pragma.h.
3133
3134 2009-05-07  Andrew Pinski  <andrew_pinski@playstation.sony.com>
3135
3136         * config/spu/spu.c: Remove include of c-common.h.
3137
3138 2009-05-07  Janis Johnson  <janis187@us.ibm.com>
3139
3140         PR c/39037
3141         * c-common.h (mark_valid_location_for_stdc_pragma,
3142         valid_location_for_stdc_pragma_p, set_float_const_decimal64,
3143         clear_float_const_decimal64, float_const_decimal64_p): New.
3144         * c.opt (Wunsuffixed-float-constants): New.
3145         * c-lex.c (interpret_float): Use pragma FLOAT_CONST_DECIMAL64 for
3146         unsuffixed float constant, handle new warning.
3147         * c-cppbuiltin.c (c_cpp_builtins): Use cast for double constants.
3148         * c-decl.c (c_scope): New flag float_const_decimal64.
3149         (set_float_const_decimal64, clear_float_const_decimal64,
3150         float_const_decimal64_p): New.
3151         (push_scope): Set new flag.
3152         * c-parser.c (c_parser_translation_unit): Mark when it's valid
3153         to use STDC pragmas.
3154         (c_parser_external_declaration): Ditto.
3155         (c_parser_compound_statement_nostart): Ditto.
3156         * c-pragma.c (valid_location_for_stdc_pragma,
3157         mark_valid_location_for_stdc_pragma,
3158         valid_location_for_stdc_pragma_p, handle_stdc_pragma,
3159         handle_pragma_float_const_decimal64): New.
3160         (init_pragma): Register new pragma FLOAT_CONST_DECIMAL64.
3161         * cp/semantics.c (valid_location_for_stdc_pragma_p,
3162         set_float_const_decimal64, clear_float_const_decimal64,
3163         float_const_decimal64_p): New dummy functions.
3164         * doc/extend.texi (Decimal Float): Remove statement that the
3165         pragma, and suffix for double constants, are not supported.
3166         * doc/invoke.texi (Warning Options): List new option.
3167         (-Wunsuffixed-float-constants): New.
3168
3169 2009-05-08  Steven Bosscher  <steven@gcc.gnu.org>
3170
3171         * config/i386/i386.c: Do not include c-common.h.
3172
3173 2009-05-07  Mark Heffernan  <meheff@google.com>
3174
3175         * doc/invoke.texi (Debugging Options): Document change of debugging
3176         dump location.
3177         * opts.c (decode_options): Make dump_base_name relative to
3178         aux_base_name directory.
3179
3180 2009-05-07  Hariharan Sandanagobalane <hariharan@picochip.com>
3181
3182         * config/picochip/picochip.h (NO_DOLLAR_IN_LABEL): Added.
3183         * config/picochip/libgccExtras/divmod15.asm : Removed redefiniton.
3184
3185 2009-05-07  Rafael Avila de Espindola  <espindola@google.com>
3186
3187         * Makefile.in (install-plugin): Simplify a bit.
3188
3189 2009-05-07  Paolo Bonzini  <bonzini@gnu.org>
3190
3191         * Makefile.in (OBJS-common): Add regcprop.o.
3192         (regcprop.o): New.
3193         * timevar.def (TV_CPROP_REGISTERS): New.
3194         * regrename.c (regrename_optimize): Return 0.
3195         (rest_of_handle_regrename): Delete.
3196         (pass_rename_registers): Point to regrename_optimize.
3197         (struct value_data_entry, struct value_data, 
3198         kill_value_one_regno, kill_value_regno, kill_value,
3199         set_value_regno, init_value_data, kill_clobbered_value,
3200         kill_set_value, kill_autoinc_value, copy_value,
3201         mode_change_ok, maybe_mode_change, find_oldest_value_reg,
3202         replace_oldest_value_reg, replace_oldest_value_addr,
3203         replace_oldest_value_mem, copyprop_hardreg_forward_1,
3204         debug_value_data, validate_value_data): Move...
3205         * regcprop.c: ... here.
3206         (rest_of_handle_cprop): Delete.
3207         (pass_cprop_hardreg): Point to copyprop_hardreg_forward.
3208
3209 2009-05-07  Jakub Jelinek  <jakub@redhat.com>
3210
3211         PR middle-end/40057
3212         * dojump.c (prefer_and_bit_test): Use immed_double_const instead of
3213         GEN_INT for 1 << bitnum.
3214         (do_jump) <case BIT_AND_EXPR>: Use build_int_cst_wide_type instead of
3215         build_int_cst_type.
3216
3217 2009-05-07  Uros Bizjak  <ubizjak@gmail.com>
3218
3219         * doc/md.texi (Standard Pattern Names For Generation) [sync_nand]:
3220         Remove wrong description of "nand" operation.
3221
3222 2009-05-06  Richard Guenther  <rguenther@suse.de>
3223             Adam Nemet  <anemet@caviumnetworks.com>
3224
3225         * gimple.def (GIMPLE_ASSIGN): Fix incorrect information in the
3226         comment.  Add that if LHS is not a gimple register, then RHS1 has
3227         to be a single object (GIMPLE_SINGLE_RHS).
3228
3229 2009-05-06  Adam Nemet  <anemet@caviumnetworks.com>
3230
3231         * expr.c (get_def_for_expr): Move it up in the file.
3232         (store_field): When expanding a bit-field store, look at the
3233         defining gimple stmt for the masking conversion.
3234
3235 2009-05-06  Janis Johnson  <janis187@us.ibm.com>
3236
3237         PR middle-end/39986
3238         * dfp.c (encode_decimal32, decode_decimal32, encode_decimal64,
3239         decode_decimal64, encode_decimal128, decode_decimal128): Avoid
3240         32-bit memcpy into long.
3241
3242 2009-05-06  Jakub Jelinek  <jakub@redhat.com>
3243
3244         * dwarf2out.c (new_reg_loc_descr): Don't ever create DW_OP_regX.
3245         (one_reg_loc_descriptor): Create DW_OP_regX here instead of calling
3246         new_reg_loc_descr.
3247         (loc_by_reference): If loc is DW_OP_regX, change it into DW_OP_bregX 0
3248         instead of appending DW_OP_deref*.
3249
3250 2009-05-06  Michael Matz  <matz@suse.de>
3251
3252         PR middle-end/40021
3253         * cfgexpand.c (maybe_cleanup_end_of_block): New static function.
3254         (expand_gimple_cond): Use it to cleanup CFG and superfluous jumps.
3255
3256 2009-05-06  Rafael Avila de Espindola  <espindola@google.com>
3257
3258         * Makefile.in (install-plugin): Fix srcdir handling.
3259
3260 2009-05-06  Andrey Belevantsev  <abel@ispras.ru>
3261
3262         * tree-ssa.c (execute_update_address_taken): Handle TARGET_MEM_REF
3263         when processing for not_regs_needed bitmap.
3264         * gimple.c (walk_stmt_load_store_addr_ops): When visiting address,
3265         handle TARGET_MEM_REF in lhs.  Check TMR_BASE for NULL while 
3266         handling it for rhs. 
3267
3268 2009-05-06  H.J. Lu  <hongjiu.lu@intel.com>
3269
3270         * config/i386/i386.md (unnamed inc/dec peephole): Use
3271         optimize_insn_for_size_p instead of optimize_size.
3272         * config/i386/predicates.md (incdec_operand): Likewise.
3273         (aligned_operand): Likewise.
3274         * config/i386/sse.md (divv8sf3): Likewise.
3275         (sqrtv8sf2): Likewise.
3276
3277 2009-05-06  H.J. Lu  <hongjiu.lu@intel.com>
3278
3279         * config/i386/i386.c (ix86_build_signbit_mask): Make it static.
3280
3281         * config/i386/i386-protos.h (ix86_build_signbit_mask): Removed.
3282
3283 2009-05-06  H.J. Lu  <hongjiu.lu@intel.com>
3284
3285         * config/i386/i386.md (*avx_<code><mode>3_finite): Replace
3286         ssemodesuffixf2c with avxmodesuffixf2c.
3287
3288 2009-05-06  Joseph Myers  <joseph@codesourcery.com>
3289
3290         PR c/40032
3291         * c-decl.c (grokdeclarator): Handle incomplete type of unnamed field.
3292
3293 2009-05-05  Jakub Jelinek  <jakub@redhat.com>
3294
3295         * tree.h: Remove DECL_BY_REFERENCE from private_flag comment.
3296         (struct tree_base): Adjust spacing for 8 bit boundaries.
3297         (struct tree_decl_common): Add decl_by_reference_flag bit.
3298         (DECL_BY_REFERENCE): Adjust.
3299         * print-tree.c (print_node): For VAR_DECL, PARM_DECL or RESULT_DECL,
3300         print DECL_BY_REFERENCE bit.
3301         * dbxout.c (DECL_ACCESSIBILITY_CHAR): Revert last change.
3302         * dwarf2out.c (loc_by_reference, gen_decl_die): Check
3303         DECL_BY_REFERENCE for all VAR_DECLs, not just non-static ones.
3304         (gen_variable_die): Likewise.  Check TREE_PRIVATE/TREE_PROTECTED
3305         unconditionally.
3306
3307         PR middle-end/39666
3308         * gimplify.c (gimplify_switch_expr): If case labels cover the whole
3309         range of the type, but default label is missing, add it with one
3310         of the existing labels instead of adding a new label for it.
3311
3312 2009-05-05  Joseph Myers  <joseph@codesourcery.com>
3313
3314         * dwarf.h: Remove.
3315
3316 2009-05-05  Rafael Avila de Espindola  <espindola@google.com>
3317
3318         * Makefile.in (enable_plugin, plugin_includedir): New.
3319         (install): Depend on install-plugin.
3320         (PLUGIN_HEADERS): New.
3321         (install-plugin): New.
3322         * config.gcc: Add vxworks-dummy.h to tm_file for x86 and x86-64.
3323
3324 2009-05-05  Richard Guenther  <rguenther@suse.de>
3325
3326         PR tree-optimization/40022
3327         * tree-ssa-phiprop.c (struct phiprop_d): Exchange vop_stmt for
3328         the only vuse.
3329         (phivn_valid_p): Fix tuplification error, simplify.
3330         (phiprop_insert_phi): Add dumps.
3331         (propagate_with_phi): Simplify.
3332
3333 2009-05-05  Richard Guenther  <rguenther@suse.de>
3334
3335         PR middle-end/40023
3336         * builtins.c (gimplify_va_arg_expr): Properly build the address.
3337
3338 2009-05-05  Shujing Zhao  <pearly.zhao@oracle.com>
3339
3340         * tree.h (strip_float_extensions): Remove duplicate declaration.
3341         (build_low_bits_mask, debug_fold_checksum, expand_function_end,
3342         expand_function_start, stack_protect_prologue, stack_protect_epilogue,
3343         block_ultimate_origin): Rearrange the declarations line to match the
3344         comment that indicates the .c file which the functions are defined.
3345         (dwarf2out_*, set_decl_rtl): Add comment.
3346         (get_base_address): Adjust comment.
3347         (change_decl_assembler_name, maybe_fold_*, build_addr): Rearrange the
3348         declarations line and add comment.
3349         (is_builtin_name): Add blank after function name, for clarity.
3350
3351 2009-05-04  Joseph Myers  <joseph@codesourcery.com>
3352
3353         * attribs.c (decl_attributes): Use %qE for identifiers in
3354         diagnostics.
3355         * cgraphunit.c (verify_cgraph_node): Translate function names to
3356         locale character set in diagnostics.
3357         * coverage.c (get_coverage_counts): Use %qE for identifiers in
3358         diagnostics.
3359         * doc/invoke.texi (-finstrument-functions-exclude-function-list):
3360         Document that functions are named in UTF-8.
3361         * expr.c (expand_expr_real_1): Translate function names to locale
3362         character set in diagnostics.
3363         * gimplify.c (omp_notice_variable, omp_is_private,
3364         gimplify_scan_omp_clauses): Use %qE for identifiers in
3365         diagnostics.
3366         * langhooks.c (lhd_print_error_function): Translate function names
3367         to locale character set.
3368         * langhooks.h (decl_printable_name): Document that return value is
3369         in internal character set.
3370         * stmt.c: Include pretty-print.h
3371         (tree_conflicts_with_clobbers_p): Use %qE for identifiers in
3372         diagnostics.
3373         (resolve_operand_name_1): Translate named operand name to locale
3374         character set.
3375         * stor-layout.c (finalize_record_size): Use %qE for identifiers in
3376         diagnostics.
3377         * toplev.c (announce_function): Translate function names to locale
3378         character set.
3379         (warn_deprecated_use): Use %qE for identifiers in diagnostics.
3380         (default_tree_printer): Use pp_identifier or translate identifiers
3381         to locale character set.  Mark "<anonymous>" for translation.
3382         * tree-mudflap.c (mx_register_decls, mudflap_finish_file): Use %qE
3383         for identifiers in diagnostics.
3384         * tree.c (handle_dll_attribute): Use %qE for identifiers in
3385         diagnostics.
3386         * varasm.c (output_constructor): Use %qE for identifiers in
3387         diagnostics.
3388
3389 2009-05-04  Rafael Avila de Espindola  <espindola@google.com>
3390
3391         * configure.ac: use ` ` instead of $()
3392         * configure: Regenerate.
3393
3394 2009-05-05  Ben Elliston  <bje@au.ibm.com>
3395
3396         * config/pa/linux-atomic.c: Eliminate conditional include of
3397         errno.h on non-LP64 systems to simplify build requirements.
3398
3399 2009-05-04  Joseph Myers  <joseph@codesourcery.com>
3400
3401         * c-common.c (handle_mode_attribute): Use %qE for identifiers in
3402         diagnostics.
3403         * c-decl.c (check_bitfield_type_and_width): Make orig_name a tree
3404         and pass value to identifier_to_locale.
3405         (warn_variable_length_array): Make name a tree.
3406         (grokdeclarator): Separate diagnostic texts for named and unnamed
3407         declarators.  Use %qE for named declarators.
3408         * c-parser.c (c_lex_one_token): Use %qE for identifiers in
3409         diagnostics.
3410         * c-pragma.c (pop_alignment, handle_pragma_pack): Use %qE for
3411         identifiers in diagnostics.
3412         * c-typeck.c (push_member_name, start_init): Pass identifiers to
3413         identifier_to_locale.  Mark "anonymous" strings for translation.
3414
3415 2009-05-04  Michael Eager <eager@eagercon.com>
3416
3417         * config/rs6000/rs6000.c (rs6000_legitimate_address): Allow
3418         address for DImode/DFmode only if double-precision FP regs.
3419
3420 2009-05-04  Michael Eager <eager@eagercon.com>
3421
3422         * config/rs6000/rs6000.c (rs6000_libcall_value): Add
3423         TARGET_SINGLE_FLOAT check.
3424
3425 2009-05-04  Michael Eager <eager@eagercon.com>
3426
3427         * config/rs6000/xilinx.h: Add CPP_SPEC for -mxilinx-fpu options.
3428
3429 2009-05-04  Michael Eager <eager@eagercon.com>
3430
3431         * gcc/config.gcc: (powerpc-xilinx-eabi*): Add tm t-xilinx
3432         * config/rs6000/t-xilinx: New
3433
3434 2009-05-04  Paolo Bonzini  <bonzini@gnu.org>
3435
3436         * doc/tm.texi (LEGITIMIZE_ADDRESS): Revise documentation.
3437         * gcc/defaults.h (LEGITIMIZE_ADDRESS): Delete.
3438         * gcc/explow.c (memory_address): Use target hook.
3439         * gcc/targhooks.c (default_legitimize_address): New.
3440         * gcc/targhooks.h (default_legitimize_address): New.
3441         * gcc/target.h (legitimize_address): New.
3442         * gcc/target-def.h (TARGET_LEGITIMIZE_ADDRESS): New.
3443         (TARGET_INITIALIZER): Include it.
3444         * gcc/system.h (LEGITIMIZE_ADDRESS): Poison.
3445
3446         * config/bfin/bfin-protos.h (legitimize_address): Remove.
3447         * config/bfin/bfin.c (legitimize_address): Remove.
3448         * config/bfin/bfin.h (LEGITIMIZE_ADDRESS): Remove.
3449         * config/m68hc11/m68hc11-protos.h (m68hc11_legitimize_address):
3450         Remove.
3451         * config/m68hc11/m68hc11.c (m68hc11_legitimize_address): Remove.
3452         * config/m68hc11/m68hc11.h (LEGITIMIZE_ADDRESS): Remove.
3453
3454         * gcc/config/arm/arm.h (LEGITIMIZE_ADDRESS, ARM_LEGITIMIZE_ADDRESS,
3455         THUMB_LEGITIMIZE_ADDRESS, THUMB2_LEGITIMIZE_ADDRESS): Delete.
3456         * gcc/config/s390/s390.h (LEGITIMIZE_ADDRESS): Delete.
3457         * gcc/config/m32c/m32c.h (LEGITIMIZE_ADDRESS): Delete.
3458         * gcc/config/sparc/sparc.h (LEGITIMIZE_ADDRESS): Delete.
3459         * gcc/config/m32r/m32r.h (LEGITIMIZE_ADDRESS): Delete.
3460         * gcc/config/i386/i386.h (LEGITIMIZE_ADDRESS): Delete.
3461         * gcc/config/sh/sh.h (LEGITIMIZE_ADDRESS): Delete.
3462         * gcc/config/avr/avr.h (LEGITIMIZE_ADDRESS): Delete.
3463         * gcc/config/m68hc11/m68hc11.h (LEGITIMIZE_ADDRESS): Delete.
3464         * gcc/config/iq2000/iq2000.h (LEGITIMIZE_ADDRESS): Delete.
3465         * gcc/config/mn10300/mn10300.h (LEGITIMIZE_ADDRESS): Delete.
3466         * gcc/config/m68k/m68k.h (LEGITIMIZE_ADDRESS): Delete.
3467         * gcc/config/score/score.h (LEGITIMIZE_ADDRESS): Delete.
3468         * gcc/config/pa/pa.h (LEGITIMIZE_ADDRESS): Delete.
3469         * gcc/config/mips/mips.h (LEGITIMIZE_ADDRESS): Delete.
3470         * gcc/config/alpha/alpha.h (LEGITIMIZE_ADDRESS): Delete.
3471         * gcc/config/frv/frv.h (LEGITIMIZE_ADDRESS): Delete.
3472         * gcc/config/spu/spu.h (LEGITIMIZE_ADDRESS): Delete.
3473         * gcc/config/xtensa/xtensa.h (LEGITIMIZE_ADDRESS): Delete.
3474         * gcc/config/cris/cris.h (LEGITIMIZE_ADDRESS): Delete.
3475         * gcc/config/rs6000/rs6000.h (LEGITIMIZE_ADDRESS): Delete.
3476         * gcc/config/picochip/picochip.h (LEGITIMIZE_ADDRESS): Delete.
3477
3478         * gcc/config/s390/s390-protos.h (legitimize_address): Delete.
3479         * gcc/config/m32c/m32c-protos.h (m32c_legitimize_address): Delete.
3480         * gcc/config/sparc/sparc-protos.h (legitimize_address): Delete.
3481         * gcc/config/i386/i386-protos.h (legitimize_address): Delete.
3482         * gcc/config/avr/avr-protos.h (legitimize_address): Delete.
3483         * gcc/config/mn10300/mn10300-protos.h (legitimize_address): Delete.
3484         * gcc/config/score/score-protos.h (score_legitimize_address): Delete.
3485         * gcc/config/arm/arm-protos.h (arm_legitimize_address,
3486         (thumb_legitimize_address): Delete.
3487         * gcc/config/pa/pa-protos.h (hppa_legitimize_address): Delete.
3488         * gcc/config/mips/mips-protos.h (mips_legitimize_address): Delete.
3489         * gcc/config/alpha/alpha-protos.h (alpha_legitimize_address): Delete.
3490         * gcc/config/frv/frv-protos.h (frv_legitimize_address): Delete.
3491         * gcc/config/spu/spu-protos.h (spu_legitimize_address): Delete.
3492         * gcc/config/xtensa/xtensa-protos.h (xtensa_legitimize_address):
3493         Delete.
3494         * gcc/config/rs6000/rs6000-protos.h (rs6000_legitimize_address):
3495         Delete.
3496
3497         * config/arm/arm.c (arm_legitimize_address): Maybe call Thumb version.
3498         * config/m32c/m32c.c (m32c_legitimize_address): Standardize.
3499         * config/m32r/m32r.c (m32r_legitimize_address): New.
3500         * config/m68k/m68k.c (m68k_legitimize_address): New.
3501         * config/score/score.c (score_legitimize_address): Standardize.
3502         * config/score/score3.c (score3_legitimize_address): Standardize.
3503         * config/score/score3.h (score3_legitimize_address): Adjust.
3504         * config/score/score7.c (score7_legitimize_address): Standardize.
3505         * config/score/score7.h (score7_legitimize_address): Adjust.
3506         * config/sh/sh.c (sh_legitimize_address): New.
3507         * config/iq2000/iq2000.c (iq2000_legitimize_address): New.
3508
3509         * gcc/config/s390/s390.c (legitimize_address): Rename to...
3510         (s390_legitimize_address): ... this.
3511         * gcc/config/sparc/sparc.c (legitimize_address): Rename to...
3512         (sparc_legitimize_address): ... this.
3513         * gcc/config/i386/i386.c (legitimize_address): Rename to...
3514         (ix86_legitimize_address): ... this.
3515         * gcc/config/avr/avr.c (legitimize_address): Rename to...
3516         (avr_legitimize_address): ... this.
3517         * gcc/config/mn10300/mn10300.c (legitimize_address): Rename to...
3518         (mn10300_legitimize_address): ... this.
3519         * config/alpha/alpha.c (alpha_legitimize_address): Wrap...
3520         (alpha_legitimize_address_1): ... the old alpha_legitimize_address.
3521         (alpha_expand_mov): Adjust call.
3522
3523         * config/frv/frv.c (frv_legitimize_address): Return x on failure.
3524         * config/spu/spu.c (spu_legitimize_address): Likewise.
3525         * config/xtensa/xtensa.c (xtensa_legitimize_address): Likewise.
3526         * config/rs6000/rs6000.c (rs6000_legitimize_address): Likewise.
3527
3528 2009-05-04  Joseph Myers  <joseph@codesourcery.com>
3529
3530         * intl.c (locale_encoding, locale_utf8): New.
3531         (gcc_init_libintl): Initialize locale_encoding and locale_utf8.
3532         * intl.h (locale_encoding, locale_utf8): Declare.
3533         * pretty-print.c: Include ggc.h.  Include iconv.h if HAVE_ICONV.
3534         (pp_base_tree_identifier, decode_utf8_char, identifier_to_locale):
3535         New.
3536         * pretty-print.h (pp_identifier): Call identifier_to_locale on ID
3537         argument.
3538         (pp_tree_identifier): Define to call pp_base_tree_identifier.
3539         (pp_base_tree_identifier): Declare as function.
3540         (identifier_to_locale): Declare.
3541         * Makefile.in (pretty-print.o): Update dependencies.
3542         * varasm.c (finish_aliases_1): Use %qE for identifiers in diagnostics.
3543
3544 2009-05-04  Richard Guenther  <rguenther@suse.de>
3545
3546         PR middle-end/40015
3547         * builtins.c (fold_builtin_memory_op): Do not decay to element
3548         type if the size matches the whole array.
3549
3550 2009-05-04  Kazu Hirata  <kazu@codesourcery.com>
3551
3552         * expmed.c (synth_mult): When trying out a shift, pass the result
3553         of a signed shift.
3554
3555 2009-05-04  Kazu Hirata  <kazu@codesourcery.com>
3556
3557         * expmed.c (shiftsub_cost): Rename to shiftsub0_cost.
3558         (shiftsub1_cost): New.
3559         (init_expmed): Compute shiftsub1_cost.
3560         (synth_mult): Optimize multiplications by constants of the form
3561         -(2^^m-1) for some constant positive integer m.
3562
3563 2009-05-03  Richard Guenther  <rguenther@suse.de>
3564
3565         PR c/39983
3566         * c-typeck.c (array_to_pointer_conversion): Do not built
3567         ADDR_EXPRs of arrays of pointer-to-element type.
3568         * c-gimplify.c (c_gimplify_expr): Revert change fixing
3569         up wrong ADDR_EXPRs after-the-fact.
3570         * c-common.c (strict_aliasing_warning): Strip pointer
3571         conversions for obtaining the original type.
3572         * builtins.c (fold_builtin_memset): Handle array types.
3573         (fold_builtin_memory_op): Handle folded POINTER_PLUS_EXPRs
3574         and array types
3575
3576 2009-05-03  Richard Guenther  <rguenther@suse.de>
3577
3578         PR middle-end/23329
3579         * tree-ssa.c (useless_type_conversion_p_1): Use get_deref_alias_set.
3580         Do not lose casts from array types with unknown extent to array
3581         types with known extent.
3582         * tree-ssa-copy.c (may_propagate_copy): Remove hack checking for
3583         alias set compatibility.
3584
3585 2009-05-03  Manuel López-Ibáñez  <manu@gcc.gnu.org>
3586
3587         * flags.h (extra_warnings): Delete.
3588         * toplev.c (process_options): Handle Wuninitialized here.
3589         * opts.c (extra_warnings): Delete.
3590         (set_Wextra): Delete.
3591         (common_handle_option): -Wextra can be handled automatically.
3592         * c-opts.c (c_common_handle_option): Delete obsolete code.
3593         (c_common_post_options): Simplify comment.
3594         * common.opt (W): Add Var.
3595         (Wextra): Add Var.
3596         (Wuninitialized): Initialize to -1.
3597
3598 2009-05-03  Adam Nemet  <anemet@caviumnetworks.com>
3599             Richard Guenther  <rguenther@suse.de>
3600
3601         * expr.c (get_def_for_expr): New function.
3602         (expand_expr_real_1) <PLUS_EXPR, MINUS_EXPR>: Adjust to work with
3603         SSA rather than trees.
3604         <MULT_EXPR>: Likewise.  Use subexp0 and subexp1 instead of
3605         TREE_OPERAND (exp, 0) and TREE_OPERAND (exp, 1).
3606         
3607 2009-05-03  Joseph Myers  <joseph@codesourcery.com>
3608
3609         * c-common.c (reswords): Add _Imaginary.
3610         * c-common.c (enum rid): Add RID_IMAGINARY.
3611
3612 2009-05-03  Paolo Bonzini  <bonzini@gnu.org>
3613
3614         * tree.h (TYPE_VECTOR_OPAQUE): Fix documentation.
3615         Patch by Richard Guenther.
3616
3617 2009-05-03  Anatoly Sokolov  <aesok@post.ru>
3618
3619         * defaults.h (FRAME_POINTER_REQUIRED): Provide default.
3620         * doc/tm.texi (FRAME_POINTER_REQUIRED): Revise documentation.
3621         * config/alpha/alpha.h (FRAME_POINTER_REQUIRED): Delete.
3622         * config/s390/s390.h (FRAME_POINTER_REQUIRED): Delete.
3623         * config/spu/spu.h (FRAME_POINTER_REQUIRED): Delete.
3624         * config/sh/sh.h (FRAME_POINTER_REQUIRED): Delete.
3625         * config/pdp11/pdp11.h (FRAME_POINTER_REQUIRED): Delete.
3626         * config/stormy16/stormy16.h (FRAME_POINTER_REQUIRED): Delete.
3627         * config/m68hc11/m68hc11.h (FRAME_POINTER_REQUIRED): Delete.
3628         * config/iq2000/iq2000.h (FRAME_POINTER_REQUIRED): Delete.
3629         * config/mn10300/mn10300.h (FRAME_POINTER_REQUIRED): Delete.
3630         * config/ia64/ia64.h (FRAME_POINTER_REQUIRED): Delete.
3631         * config/m68k/m68k.h (FRAME_POINTER_REQUIRED): Delete.
3632         * config/rs6000/rs6000.h (FRAME_POINTER_REQUIRED): Delete.
3633         * config/picochip/picochip.h (FRAME_POINTER_REQUIRED): Delete.
3634         * config/mcore/mcore.h (FRAME_POINTER_REQUIRED): Delete.
3635         * config/h8300/h8300.h (FRAME_POINTER_REQUIRED): Delete.
3636         * config/v850/v850.h (FRAME_POINTER_REQUIRED): Delete.
3637
3638 2009-05-02  Richard Guenther  <rguenther@suse.de>
3639
3640         PR tree-optimization/39940
3641         * tree-ssa-pre.c (eliminate): Make sure we may propagate before
3642         doing so.
3643
3644 2009-05-02  Richard Guenther  <rguenther@suse.de>
3645
3646         PR middle-end/40001
3647         * tree-ssa.c (execute_update_addresses_taken): Properly check
3648         if we can mark a variable DECL_GIMPLE_REG_P.
3649         * gimple.c (is_gimple_reg): Re-order check for DECL_GIMPLE_REG_P
3650         back to the end of the function.
3651         (is_gimple_reg_type): Remove complex type special casing.
3652         * gimplify.c (gimplify_bind_expr): Do not set DECL_GIMPLE_REG_P
3653         if not optimizing.
3654
3655 2009-05-02  Ben Elliston  <bje@au.ibm.com>
3656
3657         * doc/collect2.texi (Collect2): Document search path behaviour
3658         when configured with --with-ld.
3659
3660 2009-05-02  Jan Hubicka  <jh@suse.cz>
3661
3662         * tree-ssa-coalesce.c (coalesce_cost): Do not take ciritical
3663         parameter; update callers.
3664         (coalesce_cost_edge): EH edges are costier because they needs
3665         splitting even if not critical and even more costier when there are
3666         multiple EH predecestors.
3667
3668 2009-05-02  Jan Hubicka  <jh@suse.cz>
3669
3670         * except.c (remove_eh_handler_and_replace): Handle updating after
3671         removing TRY blocks.
3672
3673 2009-05-02  Eric Botcazou  <ebotcazou@adacore.com>
3674
3675         * store-motion.c (compute_store_table): Add ENABLE_CHECKING guard.
3676
3677 2009-05-02  Steven Bosscher  <steven@gcc.gnu.org>
3678
3679         * varasm.c: Do not include c-pragma.h.
3680         * attribs.c: Do not incude c-common.h.
3681
3682 2009-05-01  Michael Matz  <matz@suse.de>
3683
3684         * calls.c (initialize_argument_information): Handle SSA names like
3685         decls with a non MEM_P DECL_RTL.
3686
3687 2009-05-01  Steven Bosscher  <steven@gcc.gnu.org>
3688
3689         * ipa-reference.c: Do not include c-common.h, include splay-tree.h.
3690         * ipa-utils.c: Likewise.
3691         * ipa-type-escape.c: Likewise.
3692         * cgraphunit.c Do not include c-common.h.
3693         * ipa-pure-const.c: Likewise.
3694         * tree-if-conv.c: Likewise.
3695         * matrix-reorg.c: Do not include c-common.h and c-tree.h.
3696         * ipa-struct-reorg.c: Likewise.
3697         * tree-nomudflap.c: Likewise.
3698         * tree-ssa-structalias.c: Likewise.
3699
3700 2009-05-01  Steven Bosscher  <steven@gcc.gnu.org>
3701
3702         * store-motion.c: Many cleanups to make this pass a first-class
3703         citizen instead of an appendix to gcse load motion.  Add TODO list
3704         to make this pass faster/cleaner/better.
3705
3706         (struct ls_expr): Post gcse.c-split cleanups.
3707         Rename to st_expr.  Rename "loads" field to "antic_stores".  Rename
3708         "stores" field to "avail_stores".
3709         (pre_ldst_mems): Rename to store_motion_mems.
3710         (pre_ldst_table): Rename to store_motion_mems_table.
3711         (pre_ldst_expr_hash): Rename to pre_st_expr_hash, update users.
3712         (pre_ldst_expr_eq): Rename to pre_st_expr_eq, update users.
3713         (ldst_entry): Rename to st_expr_entry, update users.
3714         (free_ldst_entry): Rename to free_st_expr_entry, update users.
3715         (free_ldst_mems): Rename to free_store_motion_mems, update users.
3716         (enumerate_ldsts): Rename to enumerate_store_motion_mems,
3717         update caller.
3718         (first_ls_expr): Rename to first_st_expr, update users.
3719         (next_ls_expr): Rename to next_st_expr, update users.
3720         (print_ldst_list): Rename to print_store_motion_mems.  Print names of
3721         fields properly for store motion instead of names inherited from load
3722         motion in gcse.c.
3723         (ANTIC_STORE_LIST, AVAIL_STORE_LIST): Remove.
3724         (LAST_AVAIL_CHECK_FAILURE): Explain what this is.  Undefine when we
3725         are done with it.
3726
3727         (ae_kill): Rename to st_kill, update users.
3728         (ae_gen): Rename to st_avloc, update users.
3729         (transp): Rename to st_transp, update users.
3730         (pre_insert_map): Rename to st_insert_map, update users.
3731         (pre_delete_map): Rename to st_delete_map, update users.
3732         (insert_store, build_store_vectors, free_store_memory,
3733         one_store_motion_pass): Update for abovementioned changes.
3734
3735         (gcse_subst_count, gcse_create_count): Remove.
3736         (one_store_motion_pass): New statistics counters "n_stores_deleted"
3737         and "n_stores_created", local variables.
3738
3739         (extract_mentioned_regs, extract_mentioned_regs_1): Rewrite to
3740         use for_each_rtx.
3741
3742         (regvec, compute_store_table_current_insn): Remove.
3743         (reg_set_info, reg_clear_last_set): Remove.
3744         (compute_store_table): Use DF caches instead of local dataflow
3745         solvers.
3746
3747 2009-05-01  Joseph Myers  <joseph@codesourcery.com>
3748
3749         * c-objc-common.c (c_tree_printer): Print identifiers with
3750         pp_identifier, not pp_string.  Mark "({anonymous})" for
3751         translation.
3752         * c-pretty-print.c (pp_c_ws_string): New.
3753         (pp_c_cv_qualifier, pp_c_type_specifier,
3754         pp_c_specifier_qualifier_list, pp_c_parameter_type_list,
3755         pp_c_storage_class_specifier, pp_c_function_specifier,
3756         pp_c_attributes, pp_c_bool_constant, pp_c_constant,
3757         pp_c_primary_expression, pp_c_postfix_expression,
3758         pp_c_unary_expression, pp_c_shift_expression,
3759         pp_c_relational_expression, pp_c_equality_expression,
3760         pp_c_logical_and_expression, pp_c_logical_or_expression): Mostly
3761         use pp_string and pp_c_ws_string in place of pp_identifier and
3762         pp_c_identifier for non-identifiers.  Mark English strings for
3763         translation.
3764         * c-pretty-print.h (pp_c_ws_string): Declare.
3765
3766 2009-04-30  Paul Pluzhnikov  <ppluzhnikov@google.com>
3767             Roland McGrath <roland@redhat.com>
3768
3769         * configure.ac (HAVE_LD_BUILDID): New check for ld --build-id support.
3770         (ENABLE_LD_BUILDID): New configuration option.
3771         * gcc.c [HAVE_LD_BUILDID and ENABLE_LD_BUILDID]
3772         (LINK_BUILDID_SPEC): New macro.
3773         (init_spec): If defined, prepend it between LINK_EH_SPEC and
3774         link_spec.
3775         * doc/install.texi: Document --enable-linker-build-id option.
3776         * configure: Rebuild.
3777         * config.in: Rebuild.
3778
3779 2009-04-30  Adam Nemet  <anemet@caviumnetworks.com>
3780
3781         * config/mips/mips.h (FRAME_GROWS_DOWNWARD,
3782         MIPS_GP_SAVE_AREA_SIZE): Define new macros.
3783         (STARTING_FRAME_OFFSET): Return 0 if FRAME_GROWS_DOWNWARD.  Use
3784         MIPS_GP_SAVE_AREA_SIZE.
3785         * config/mips/mips.c (struct mips_frame_info): Update comment
3786         before arg_pointer_offset and hard_frame_pointer_offset.
3787         (mips_compute_frame_info): Update diagram before function: to
3788         correctly use stack_pointer_rtx for fp_sp_offset and gp_sp_offset, to
3789         indicate the position of frame_pointer_rtx with -fstack-protector and
3790         to show args_size.  Don't allocate cprestore area for leaf functions
3791         if FRAME_GROWS_DOWNWARD.  Use MIPS_GP_SAVE_AREA_SIZE to set
3792         cprestore_size.
3793         (mips_initial_elimination_offset): Update for FRAME_GROWS_DOWNWARD.
3794
3795 2009-04-30  Michael Matz  <matz@suse.de>
3796
3797         PR tree-optimization/39955
3798         * config/rs6000/rs6000.c (rs6000_check_sdmode): Also check SSA_NAMEs.
3799
3800 2009-04-30  Dave Korn  <dave.korn.cygwin@gmail.com>
3801
3802         * ira.c (setup_cover_and_important_classes):  Use safe macro
3803         REG_CLASS_FOR_CONSTRAINT instead of calling regclass_for_constraint
3804         directly.
3805         * genpreds.c (write_tm_preds_h):  Output suitable definition of
3806         REG_CLASS_FOR_CONSTRAINT.
3807
3808 2009-04-30  Rafael Avila de Espindola  <espindola@google.com>
3809
3810         * alloc-pool.c (alloc_pool_descriptor): Use an insert_opion value
3811         instead of an int.
3812         * bitmap.c (bitmap_descriptor): Likewise.
3813         * ggc-common.c (loc_descriptor): Likewise.
3814         * varray.c (varray_descriptor): Likewise.
3815         * vec.c (vec_descriptor): Likewise.
3816
3817 2009-04-30  Eric Botcazou  <ebotcazou@adacore.com>
3818
3819         * Makefile.in (dce.o): Add $(EXCEPT_H).
3820         * dce.c: Include except.h and delete redundant vector definitions.
3821         (deletable_insn_p): Return false for non-call insns that can throw
3822         if DF is running.
3823
3824 2009-04-30  Steven Bosscher  <steven@gcc.gnu.org>
3825
3826         * gcse.c (ae_gen): Remove.
3827         (can_assign_to_reg_p): Rename to can_assign_to_reg_without_clobbers_p
3828         and make non-static function to make it available in store-motion.c.
3829         Update call sites with search-and-replace.
3830         (enumerate_ldsts, reg_set_info, reg_clear_last_set, store_ops_ok,
3831         extract_mentioned_regs, extract_mentioned_regs_helper,
3832         find_moveable_store, compute_store_table, load_kills_store, find_loads,
3833         store_killed_in_insn, store_killed_after, store_killed_before,
3834         build_store_vectors, insert_insn_start_basic_block, insert-store,
3835         remove_reachable_equiv_notes, replace_store_insn, delete_store,
3836         free_store_memory, one_store_motion_pass, gate_rtl_store_motion,
3837         execute_rtl_store_motion, pass_rtl_store_motion): Move to...
3838         * store-motion.c: ...new file.  Also copy data structures from gcse.c
3839         and clean up to remove parts not used by store motion.
3840         * rtl.h (can_assign_to_reg_without_clobbers_p): Add prototype.
3841         * Makefile.in (store-motion.o): New rule. Add to OBJS-common.
3842
3843 2009-04-30  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
3844
3845         PR target/38571
3846         * config/arm/arm.h (FUNCTION_BOUNDARY): Set to 16 for thumb
3847         when optimizing for size.
3848
3849 2009-04-30  Hans-Peter Nilsson  <hp@axis.com>
3850
3851         * gcse.c (gcse_constant_p): Fix typo in last change.
3852
3853 2009-04-30  Rafael Avila de Espindola  <espindola@google.com>
3854
3855         * plugin.c: Include plugin-version.h only if ENABLE_PLUGIN is defined.
3856
3857 2009-04-30  Andreas Krebbel  <krebbel1@de.ibm.com>
3858
3859         * gcse.c (gcse_constant_p): Make sure the constant is sharable.
3860
3861 2009-04-29  James E. Wilson  <wilson@codesourcery.com>
3862
3863         * config/mips/mips.c (mips_add_offset): Use gen_int_mode for
3864         CONST_HIGH_PART result.
3865
3866 2009-04-29  Anatoly Sokolov  <aesok@post.ru>
3867
3868         * config/avr/avr.c (initial_elimination_offset): Rename to
3869         avr_initial_elimination_offset.
3870         (frame_pointer_required_p): Rename to avr_frame_pointer_required_p,
3871         change return type to bool.
3872         (avr_can_eliminate): New function.
3873         * config/avr/avr.h (CAN_ELIMINATE): Use avr_can_eliminate.
3874         (FRAME_POINTER_REQUIRED): Use avr_frame_pointer_required_p.
3875         (INITIAL_ELIMINATION_OFFSET): Use avr_initial_elimination_offset.
3876         * config/avr/avr-protos.h (initial_elimination_offset): Rename to
3877         avr_initial_elimination_offset.
3878         (frame_pointer_required_p): Rename to avr_frame_pointer_required_p.
3879         (avr_initial_elimination_offset): Define.
3880
3881 2009-04-29  Eric Botcazou  <ebotcazou@adacore.com>
3882             Steven Bosscher  <steven@gcc.gnu.org>
3883
3884         PR rtl-optimization/39938
3885         * Makefile.in (cfgrtl.o): Add $(INSN_ATTR_H).
3886         * cfgrtl.c: Include insn-attr.h.
3887         (rest_of_pass_free_cfg): New function.
3888         (pass_free_cfg): Use rest_of_pass_free_cfg as execute function.
3889         * resource.c (init_resource_info): Remove call to df_analyze.
3890
3891 2009-04-29  Richard Guenther  <rguenther@suse.de>
3892
3893         PR target/39943
3894         * config/i386/i386.c (ix86_vectorize_builtin_conversion): Only
3895         allow conversion to signed integers.
3896
3897 2009-04-29  Richard Guenther  <rguenther@suse.de>
3898
3899         * tree-cfg.c (verify_gimple_assign_binary): Allow vector
3900         shifts of floating point vectors if the shift amount is
3901         a constant multiple of the element size.
3902
3903 2009-04-29  Andreas Krebbel  <krebbel1@de.ibm.com>
3904             Michael Matz  <matz@suse.de>
3905
3906         PR middle-end/39927
3907         PR bootstrap/39929
3908         * tree-outof-ssa.c (emit_partition_copy): New function.
3909         (insert_partition_copy_on_edge, insert_rtx_to_part_on_edge,
3910         insert_part_to_rtx_on_edge): Perform the partition base var
3911         copy using emit_partition_copy.
3912         (insert_value_copy_on_edge): Convert constants to the right&n