OSDN Git Service

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