OSDN Git Service

ca2a399c1df4557b3d8ce43c7753c83413a6d8ad
[pf3gnuchains/gcc-fork.git] / gcc / ChangeLog
1 2009-08-14  Olatunji Ruwase <tjruwase@google.com>
2
3         * doc/extend.texi (Symbol-Renaming Pragmas): redefine_extname is
4         supported on all platforms.
5         * target.h (struct gcc_target): Remove
6         handle_pragma_redefine_extname.
7         * c-cppbuiltin.c: Remove use of
8         targetm.handle_pragma_redefine_extname.
9         * c-pragma.c: Likewise.
10         * target-def.h (TARGET_INITIALIZER): Remove
11         TARGET_HANDLE_PRAGMA_REDEFINE_EXTNAME.
12         * config/sol2.h: Remove use of
13         TARGET_HANDLE_PRAGMA_REDEFINE_EXTNAME.
14
15 2009-08-14  Douglas B Rupp  <rupp@gnat.com>
16
17         * config/ia64/fde-vms.c: New file.
18         * config/ia64/fde-glibc.c (_Unwind_FindTableEntry): Add dummy arg.
19         * config/ia64/unwind-ia64.c (UNW_ accessors): Move to unwind-ia64.h
20         (MD_UNW_COMPATIBLE_PERSONALITY_P): Provide default.
21         (uw_frame_state_for): Only register a personality routine if it is
22         known to be compatible with our expectations.
23         (_Unwind_FindEnclosingFunction, uw_frame_state_for):
24         Declare unw_table_entry stack variable and
25         mod all calls to _Unwind_FindTableEntry to add arg.
26         * config/ia64/unwind-ia64.h (UNW_ accessors): Move here.
27         (_Unwind_FindTableEntry): Add arg to prototype.
28
29 2009-08-14  Eric Botcazou  <ebotcazou@adacore.com>
30
31         * config/ia64/unwind-ia64.c (struct _Unwind_Context): Add new
32         field 'signal_pfs_loc'.
33         (uw_frame_state_for): Remove duplicate code dealing with leaf
34         procedures without unwind info.
35         If in the frame after unwinding through a signal handler, restore
36         the AR.PFS register instead of the CFM if AR.PFS has not been saved.
37         * config/ia64/linux-unwind.h (ia64_fallback_frame_state): Do not set
38         'pfs_loc' to the AR.PFS location in the signal context; instead
39         set 'signal_pfs_loc'.
40         Manually generate the unwind info for the AR.PFS register.
41         (ABI_MARKER_OLD_LINUX_SIGTRAMP, ABI_MARKER_OLD_LINUX_INTERRUPT,
42         ABI_MARKER_LINUX_SIGTRAMP, ABI_MARKER_LINUX_INTERRUPT): Define.
43         (ia64_handle_unwabi): Test 'fs->unwabi' against them.
44         Do not set 'pfs_loc' to the AR.PFS location in the signal context;
45         instead set 'signal_pfs_loc'.
46         Remove code preventing the AR.PFS register from being restored
47         from the signal context.
48
49 2009-08-14  Douglas B Rupp  <rupp@gnat.com>
50             Tristan Gingold  <gingold@adacore.com>
51
52         * config.gcc (ia64-hp-*vms*): Insert ia64/t-ia64 in tmake_file.
53         * config/ia64/t-vms: New file.
54         * config/ia64/vms64.h: New file.
55         * config/ia64/vms.h: New file.
56         * config/ia64/vms-crtinit.asm: New file.
57         * config/ia64/vms_symvec_libgcc_s.opt: New file.
58         * config/ia64/vms-unwind.h: New file.
59
60 2009-08-14  Uros Bizjak  <ubizjak@gmail.com>
61
62         * config/alpha/alpha.c (alpha_emit_conditional_move): Handle
63         TFmode compares.
64
65 2009-08-14  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
66
67         PR middle-end/30789
68         * builtins.c (do_mpc_arg2): Make extern, define for any MPC
69         version.  Move declaration...
70         * real.h (do_mpc_arg2): ... here.
71         * fold-const.c (const_binop): Use MPC for complex MULT_EXPR
72         and RDIV_EXPR.
73
74 2009-08-14  Rafael Avila de Espindola  <espindola@google.com>
75
76         * final.c (add_debug_prefix_map): Don't use GC memory for
77         old_prefix and new_prefix.
78
79 2009-08-14  Richard Guenther  <rguenther@suse.de>
80
81         * ipa-prop.c (compute_complex_pass_through): If we cannot
82         compute a non-varying offset for IPA_JF_ANCESTOR punt.
83
84 2009-08-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
85
86         * c-lex.c (c_lex_with_flags): Increase size of local variable
87         to avoid memory clobber.
88
89 2009-08-14  Paolo Bonzini  <bonzini@gnu.org>
90
91         PR target/40934
92         * config/i386/i386.c (ix86_fp_comparison_strategy):
93         Only enable/disable sahf at function granularity.
94
95 2009-08-14  Hans-Peter Nilsson  <hp@axis.com>
96
97         PR rtl-optimization/41064
98         * reload1.c (reload_as_needed): Don't call extract_insn
99         for known invalid replacements after calling
100         validate_replace_rtx_group and verify_changes.
101
102 2009-08-14  Uros Bizjak  <ubizjak@gmail.com>
103
104         PR target/41019
105         * config/i386/sse.md (SSEMODE124C8): New mode iterator.
106         (vcond<SSEMODEF2P:mode>): Assert that operation is supported by
107         ix86_expand_fp_vcond.
108         (vcond<SSEMODE124C8:mode>): Use SSEMODE124C8 instead of SSEMODE124.
109         Assert that operation is supported by ix86_expand_int_vcond.
110         (vcondu<SSEMODE124C8:mode>): Ditto.
111
112 2009-08-13  DJ Delorie  <dj@redhat.com>
113
114         * config/i386/djgpp-stdint.h: New.
115         * config.gcc (djgpp): Use it.
116
117 2009-08-13  Kaz Kojima  <kkojima@gcc.gnu.org>
118
119         * config/sh/sh.c (sh_override_options): When flag_exceptions or
120         flag_unwind_tables is on, turn flag_reorder_blocks_and_partition off.
121
122 2009-08-13  Ghassan Shobaki  <ghassan.shobaki@amd.com>
123
124         * tree-ssa-loop-prefetch.c
125         (prune_ref_by_group_reuse): Enhance probabilistic analysis
126         for long-stride pruning.
127         (compute_miss_rate): New function to compute the probability
128         that two memory references access different cache lines.
129
130 2009-08-13  Dave Korn  <dave.korn.cygwin@gmail.com>
131
132         * gcc/config/i386/cygwin.h (LINK_SPEC): Add --enable-auto-image-base.
133
134 2009-08-13  Richard Guenther  <rguenther@suse.de>
135
136         PR middle-end/41047
137         * tree-ssa-ccp.c (ccp_fold): When folding pointer additions
138         use the constant pointer type.
139         * gimplify.c (canonicalize_addr_expr): Canonicalize independent
140         of CV qualifiers on the target pointer type.
141         * tree-ssa.c (useless_type_conversion_p): Move incomplete pointer
142         conversion check before restrict check.
143
144 2009-08-12  Kaz Kojima  <kkojima@gcc.gnu.org>
145
146         PR target/41029
147         * config/sh/sh.md (reload_outdf__RnFRm+4): Fix thinko.
148
149 2009-08-12  Kaz Kojima  <kkojima@gcc.gnu.org>
150
151         * config/sh/sh.c (sh_promote_function_mode): Add ATTRIBUTE_UNUSED.
152
153 2009-08-12  Richard Guenther  <rguenther@suse.de>
154
155         PR tree-optimization/41011
156         * ipa-cp.c (ipcp_lattice_from_jfunc): Deal with failing fold
157         and reference constructing.
158
159 2009-08-12  Xinliang David Li  <davidxl@google.com>
160
161         PR tree-optimization/41012
162         * tree-flow.h : New external interface.
163         * gimple-low.c (check_call_arg): Change to public function.
164         Remove argument mismatch check in lowering.
165         * tree-inline.h (tree_can_inline_p): Interface change.
166         * tree-inline.c (tree_can_inline_p): Fold argument mismatch check
167         into this function.
168         * ipa-inline.c (cgraph_decide_inlining_of_small_functions):
169         Call change to tree_can_inline_p function.
170         (cgraph_decide_inlining_incrementally): Ditto.
171
172 2009-08-12  Richard Sandiford  <rdsandiford@googlemail.com>
173
174         PR tree-optimization/41031
175         * tree-outof-ssa.c (insert_value_copy_on_edge): Use promote_decl_mode
176         on the partition variable rather than promote_mode on the source
177         type.  Assert that the partition variable's type has the same
178         mode as the source value's.
179
180 2009-08-12  Paolo Bonzini  <bonzini@gnu.org>
181
182         * doc/tm.texi (TARGET_PROMOTE_FUNCTION_MODE): Add documentation
183         for for_return == 2.
184         * function.c (assign_parm_setup_reg): Use for_return == 2, improve
185         comments.
186         * calls.c (expand_call): Fix typo.
187         * explow.c (promote_decl_mode): Use for_return == 2 for RESULT_DECL
188         and PARM_DECL.
189         * stmt.c (expand_value_return): Use promote_function_mode to copy out
190         of pseudo.
191         * targhooks.c (default_promote_function_mode): Handle for_return == 2.
192         * config/cris/cris.c (cris_promote_function_mode): Likewise.
193         * config/mmix/mmix.c (mmix_promote_function_mode): Likewise.
194         * config/pa/pa.c (pa_promote_function_mode): Likewise.
195
196 2009-08-11  Andrew Haley  <aph@redhat.com>
197
198         * config/arm/arm.c (arm_init_libfuncs): Add __sync_synchronize.
199
200 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
201
202         PR bootstrap/40103
203         * graphite.c: Remove pragma GCC diagnostic warning "-Wc++-compat".
204
205 2009-08-12  Richard Guenther  <rguenther@suse.de>
206
207         * alias.c (get_alias_set): Honor TYPE_STRUCTURAL_EQUALITY_P.
208         * gimplify.c (gimplify_modify_expr): Do not use
209         lang_hooks.types_compatible_p.
210         * tree-ssa.c (useless_type_conversion_p): For aggregates
211         just return false if the canonical types differ.
212
213 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
214
215         PR middle-end/40980
216         * sese.c (convert_for_phi_arg): New.
217         (add_guard_exit_phis): Use convert_for_phi_arg.
218
219 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
220
221         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Dont add
222         unknown subscript upper bounds.
223
224 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
225             Pranav Garg  <pranav.garg2107@gmail.com>
226
227         * graphite-interchange.c (gather_access_strides): Removed.
228         (ppl_max_for_le): New.
229         (build_linearized_memory_access): New.
230         (memory_stride_in_loop): New.
231         (pbb_interchange_profitable_p): Reimplemented.
232         * graphite-ppl.h (ppl_new_id_map): New.
233         (ppl_interchange): New.
234
235 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
236
237         * graphite-interchange.c (compute_subscript): Removed.
238         (compute_array_size_cstr): Removed.
239         (compute_array_size_poly): Removed.
240         (compute_array_size): Removed.
241         (gather_access_strides_poly): Removed.
242         (gather_access_strides): Empty.
243
244 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
245
246         * graphite-dependences.c (dependence_polyhedron_1): Replace
247         pdr_nb_subscripts with PDR_NB_SUBSCRIPTS.
248         (graphite_legal_transform_dr): Same.
249         (graphite_carried_dependence_level_k): Same.
250         * graphite-poly.c (new_poly_dr): Add a parameter nb_subscripts.
251         Initialize PDR_NB_SUBSCRIPTS.
252         (print_pdr_access_layout): Replace pdr_nb_subscripts with
253         PDR_NB_SUBSCRIPTS.
254         * graphite-poly.h (struct poly_dr): Add nb_subscripts field.
255         (PDR_NB_SUBSCRIPTS): New.
256         (pdr_nb_subscripts): Removed.
257         (pdr_dim): Simplified.
258         * graphite-sese-to-poly.c (build_poly_dr): Replace pdr_nb_subscripts
259         with PDR_NB_SUBSCRIPTS.
260
261 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
262
263         * graphite-interchange.c (compute_array_size): Remove use of
264         PDR_DATA_CONTAINER.
265         * graphite-poly.c (new_poly_dr): Remove argument data_container.
266         Do not initialize PDR_DATA_CONTAINER.
267         (print_pdr): Do not print PDR_DATA_CONTAINER.
268         * graphite-poly.h (struct poly_dr): Remove data_container field.
269         (PDR_DATA_CONTAINER): Removed.
270         * graphite-sese-to-poly.c (pdr_add_data_dimensions): Remove use of
271         PDR_DATA_CONTAINER.
272         (build_poly_dr): Same.
273
274 2009-08-12  Konrad Trifunovic  <konrad.trifunovic@gmail.com>
275             Sebastian Pop  <sebastian.pop@amd.com>
276
277         * graphite-dependences.c (graphite_legal_transform_dr): Work on a
278         copy of the dependence polyhedron.  Free the temporary objects.
279         (graphite_carried_dependence_level_k): Free unused objects before
280         returning.
281
282         * testsuite/gcc.dg/graphite/interchange-1.c: XFAILed.
283         * testsuite/gcc.dg/graphite/interchange-2.c: XFAILed.
284         * testsuite/gcc.dg/graphite/interchange-3.c: XFAILed.
285         * testsuite/gcc.dg/graphite/interchange-4.c: XFAILed.
286         * testsuite/gcc.dg/graphite/interchange-7.c: XFAILed.
287
288 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
289
290         * graphite-blocking.c (scop_do_strip_mine): Call store_scattering.
291         Early return without analyzing the data dependences if no
292         transform has been done.  Call restore_scattering if the transform
293         is not legal.
294         (graphite-interchange.c): Same.
295         * graphite-poly.c (print_scattering_function): Test for
296         PBB_TRANSFORMED.
297         (graphite_read_transforms): Initialize PBB_TRANSFORMED.
298         (apply_poly_transforms): Do not gcc_assert that
299         the transform is legal.
300         (new_poly_bb): Initialize PBB_TRANSFORMED, PBB_SAVED and PBB_ORIGINAL.
301         Do not initialize PBB_NB_SCATTERING_TRANSFORM, PBB_NB_LOCAL_VARIABLES,
302         PBB_TRANSFORMED_SCATTERING, and PBB_ORIGINAL_SCATTERING.
303         (free_poly_dr): Free PBB_TRANSFORMED, PBB_SAVED, and PBB_ORIGINAL.
304         * graphite-poly.h (struct poly_scattering): New.
305         (struct poly_bb): Add original, transformed, and saved fields.
306         Remove transformed_scattering, original_scattering,
307         nb_local_variables and nb_scattering_transform fields.
308         (PBB_ORIGINAL, PBB_TRANSFORMED, PBB_SAVED): New.
309         (poly_scattering_new): New.
310         (poly_scattering_free): New.
311         (poly_scattering_copy): New.
312         (store_scattering_pbb): New.
313         (store_scattering): New.
314         (restore_scattering_pbb): New.
315         (restore_scattering): New.
316         * graphite-sese-to-poly.c (build_pbb_scattering_polyhedrons):
317         Initialize PBB_TRANSFORMED and PBB_ORIGINAL.
318
319 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
320
321         * graphite-poly.c (print_pbb): Add parentheses in the pretty print.
322         (print_scop): Same.
323
324 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
325
326         * Makefile.in (graphite.o): Depends on PREDICT_H.
327         * graphite.c: Include predict.h.
328         (graphite_finalize): Call tree_estimate_probability.
329         * predict.c (predict_loops): Do not call scev_initialize and
330         scev_finalize.
331         (tree_estimate_probability_bb): New.
332         (tree_estimate_probability): Do not initialize loops: move that
333         code to the driver.  Call tree_estimate_probability_bb.
334         (tree_estimate_probability_driver): New.
335         (pass_profile): Use tree_estimate_probability_driver.
336         * predict.h (tree_estimate_probability): Declared.
337
338 2009-08-12  Sebastian Pop  <sebastian.pop@amd.com>
339
340         * graphite-clast-to-gimple.c (gloog): Add time to TV_GRAPHITE_CODE_GEN.
341         * graphite-dependences.c (graphite_legal_transform): Add time to
342         TV_GRAPHITE_DATA_DEPS.
343         (dependency_between_pbbs_p): Same.
344         * timevar.def (TV_GRAPHITE_DATA_DEPS, TV_GRAPHITE_CODE_GEN): New.
345
346 2009-08-12  Andrey Belevantsev  <abel@ispras.ru>
347
348         PR rtl-optimization/41033
349         * alias.c (nonoverlapping_component_refs_p): Punt when strict
350         aliasing is disabled.
351
352 2009-08-11  Adam Nemet  <anemet@caviumnetworks.com>
353
354         * config/mips/predicates.md (qi_mask_operand, hi_mask_operand,
355         si_mask_operand, and_load_operand, low_bitmask_operand,
356         and_reg_operand, and_operand): New predicates.
357         * config/mips/constraints.md (Yb, Yh, Yw, Yz): New constraints.
358         * config/mips/mips.c (and_operands_ok): New function.
359         * config/mips/mips-protos.h (and_operands_ok): Declare it.
360         * config/mips/mips.md (move_type): Add ext_ins and logical.
361         (type): Handle them.
362         (and<mode>3): Use and_reg_operand as the second operand's predicate.
363         (*and<mode>3): Add alternatives for lbu, lhu, lwu, <d>ext and
364         shift_shift.  Remove commutative constraint modifier.
365         (*and<mode>3_mips16): Add alternatives for lbu, lhu, lwu and
366         shift_shift.
367         (*clear_upper32_dext): Remove define_insn_and_split.
368         (*clear_upper32): Turn this define_insn_and_split ...
369         (splitter for ANDing register with 0xffff_ffff): .. into this.
370
371 2009-08-11  Adam Nemet  <anemet@caviumnetworks.com>
372
373         * combine.c (try_widen_shift_mode): Factor out code to check if an
374         integer constant is a low-order bitmask from here ...
375         * rtlanal.c (low_bitmask_len): ... to here.
376         * rtl.h (low_bitmask_len): Declare.
377
378 2009-08-11  Uros Bizjak  <ubizjak@gmail.com>
379
380         PR target/8603
381         * config/alpha/alpha.md (addsi3): Remove expander.
382         (addsi3): Rename from *addsi3_internal insn pattern.
383         (subsi3): Remove expander.
384         (subsi3): Rename from *subsi3_internal insn pattern.
385
386 2009-08-11  Douglas B Rupp  <rupp@gnat.com>
387
388         * config/alpha/alpha.c (alpha_init_builtins): Nullify FWRITE and
389         FWRITE_UNLOCKED.
390
391 2009-08-11  Vasiliy Fofanov  <fofanov@adacore.com>
392             Eric Botcazou  <botcazou@adacore.com>
393             Douglas B Rupp  <rupp@gnat.com>
394
395         * config/alpha/alpha.c (alpha_return_in_memory): On VMS, ensure
396         that records that fit in 64 bits are returned by immediate value,
397         as required by OpenVMS Calling Standard.
398         (function_value): Adjust for above modification.
399         (alpha_va_start) <TARGET_ABI_OPEN_VMS>: Use
400         virtual_incoming_args_rtx as base object, not next_arg.
401         * config/alpha/vms.h: (DEFAULT_PCC_STRUCT_RETURN): Define as 0.
402
403 2009-08-11  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
404
405         * reload.c (find_reloads_subreg_address): Check the original
406         req_equiv_mem address to detect the case where an address is
407         not valid in the outer mode.
408
409 2009-08-11  Richard Guenther  <rguenther@suse.de>
410
411         PR bootstrap/40788
412         * builtins.c (gimplify_va_arg_expr): Do not call SET_EXPR_LOCATION.
413
414 2009-08-10  Douglas B Rupp  <rupp@gnat.com>
415
416         * config/alpha/vms.h (OPTIMIZATION_OPTIONS): Remove
417         (OVERRIDE_OPTIONS): Incorporate removed OPTIMIZATION_OPTIONS.
418
419 2009-08-10  Olivier Hainque  <hainqueu@adacore.com>
420             Douglas B Rupp  <rupp@gnat.com>
421
422         * config/alpha/alpha.c (alpha_sa_size): Force procedure type to
423         PT_STACK when frame_pointer_needed on OpenVMS.
424         (alpha_pv_save_size, alpha_using_fp): Remove.
425         (alpha_vms_can_eliminate): New function. Support for CAN_ELIMINATE
426         with proper processing for PT_NULL.
427         (alpha_vms_initial_elimination_offset): New function. Support for
428         INITIAL_ELIMINATION_OFFSET with proper processing for PT_NULL.
429         (alpha_sa_size): Force procedure type to PT_STACK when
430         frame_pointer_needed on OpenVMS.
431         * config/alpha/alpha-protos.h (alpha_pv_save_size): Remove prototype.
432         (alpha_using_fp): Likewise.
433         (alpha_vms_can_eliminate): Add prototype.
434         (alpha_vms_initial_elimination_offset): Likewise.
435         * config/alpha/vms.h (CAN_ELIMINATE, INITIAL_ELIMINATION_OFFSET):
436         Call alpha_vms_can_eliminate and alpha_vms_initial_elimination_offset.
437
438 2009-08-10  Eric Botcazou  <botcazou@adacore.com>
439             Douglas B Rupp  <rupp@gnat.com>
440
441         * config/alpha/alpha.c (common_object_handler): New function.
442         (vms_attribute_table): Declare a single attribute "common_object".
443         (vms_output_aligned_decl_common): New global function.
444         (SECTION_VMS_OVERLAY): Delete.
445         (SECTION_VMS_GLOBAL): Likewise.
446         (SECTION_VMS_INITIALIZE): Likewise.
447         (vms_asm_named_section): Remove support for above flags.
448         (vms_section_type_flags): Delete.
449         (TARGET_SECTION_TYPE_FLAGS): Likewise.
450         * config/alpha/alpha-protos.h (vms_output_aligned_decl_common): New.
451         * config/alpha/vms.h (ASM_OUTPUT_ALIGNED_COMMON): Delete.
452         (ASM_OUTPUT_ALIGNED_DECL_COMMON): New macro.
453
454 2009-08-10  SUGIOKA Toshinobu  <sugioka@itonet.co.jp>
455
456         PR target/41015
457         * longlong.h [__sh__] (udiv_qrnnd): Add T register to clobber list.
458         (sub_ddmmss): Likewise.
459
460 2009-08-10  Andreas Tobler  <a.tobler@schweiz.org>
461
462         PR bootstrap/41018
463         * config/rs6000/freebsd.h: Define SVR4_ASM_SPEC. Adjust copyright
464         year.
465
466 2009-08-10  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
467
468         PR target/37053
469         * reload1.c (reload_as_needed): Use cancel_changes to completely
470         undo a failed replacement attempt.
471
472 2009-08-10  Richard Guenther  <rguenther@suse.de>
473
474         PR middle-end/41006
475         * tree-ssa.c (useless_type_conversion_p_1): Fold into ...
476         (useless_type_conversion_p): ... here.  Require pointer targets
477         to be compatible.
478
479 2009-08-10  Dodji Seketeli  <dodji@redhat.com>
480
481         PR c++/40866
482         * tree-inline.c (copy_statement_list): The resulting copy shouldn't
483         loose the original type of the statement list.
484
485 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
486
487         * config/alpha/alpha.c: Include libfuncs.h
488         (avms_asm_output_extern): New function.
489         (alpha_init_libfuncs): Init some decc libfuncs.
490         * config/alpha/alpha-protos.h (avms_asm_output_external): Declare.
491         * config/alpha/vms.h (ASM_OUTPUT_EXTERNAL): Define.
492         (DO_CRTL_NAMES): Define.
493         (LIB_SPEC): Remove.
494         * config/alpha/vms64.h: (POINTERS_EXTEND_UNSIGNED): Remove undef.
495         (LONG_TYPE_SIZE): Define.
496         (TARGET_OS_CPP_BUILTINS): Define with __LONG_POINTERS=1
497         (SUBTARGET_SWITCHES): Define malloc64 switch.
498         (TARGET_DEFAULT): Default MASK_MALLOC64 set.
499         (MASK_RETURN_ADDR): Define.
500         doc/invoke.texi (mmalloc64): Document switch.
501
502 2009-08-09  Olivier Hainque  <hainque@adacore.com>
503             Douglas B Rupp  <rupp@gnat.com>
504
505         * config/alpha/alpha.c (struct machine_function): New flag for VMS,
506         uses_condition_handler.
507         (alpha_expand_builtin_establish_vms_condition_handler): New expander.
508         (alpha_expand_builtin_revert_vms_condition_handler): New expander.
509         (enum alpha_builtin): New ALPHA_BUILTIN_REVERT_VMS_CONDITION_HANDLER
510         and ALPHA_BUILTIN_ESTABLISH_VMS_CONDITION_HANDLER values.
511         (code_for_builtin): New insn codes for the new alpha_builtins.
512         (alpha_init_builtins): Register the new functions as BUILT_IN_MD.
513         (alpha_sa_size): Account for uses_condition_handler.
514         (alpha_expand_prologue): Likewise.
515         (alpha_start_function): Likewise.
516         (alpha_expand_epilogue): Likewise.
517         * config/alpha/alpha-protos.h: Prototype the new alpha.c builtin
518         establish/revert expanders.
519         * config/alpha/alpha.h (DWARF_FRAME_REGNUM): Define.
520         * config/alpha/alpha.md (builtin_establish_vms_condition_handler):
521         New expander, resorting to the alpha.c associated function.
522         (builtin_revert_vms_condition_handler): Likewise.
523         * config/alpha/vms-gcc_shell_handler.c: New file. Implements
524         __gcc_shell_handler, the static VMS condition handler used as
525         an indirection wrapper to the current dynamically established
526         handler.
527         * config/alpha/vms-unwind.h: Complete rewrite.
528         * config/alpha/t-vms (LIB2FUNCS_EXTRA): Add vms-gcc_shell_handler.c
529         * config/alpha/vms.h (MD_UNWIND_SUPPORT):
530
531 2009-08-09  Eric Botcazou  <botcazou@adacore.com>
532             Douglas B Rupp  <rupp@gnat.com>
533
534         * config/alpha/alpha.c (alpha_links): Add 'target' field.
535         (alpha_need_linkage): Handle aliases.  Return function symbol.
536         (alpha_use_linkage): Rename 'linkage' argument to 'func'.
537         Use ultimate alias target for the linkage name.
538         * config/alpha/alpha.md (movmemdi): Use the symbol returned
539         by alpha_need_linkage for the function symbol.
540         (setmemdi): Likewise.
541
542 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
543
544         * config/alpha/alpha.c (TARGET_ASM_UNALIGNED_*_OP): Define if on VMS.
545         * config/alpha/vms.h (OBJECT_FORMAT_ELF): Define.
546         (ASM_WEAKEN_LABEL): Define.
547         (CRT_CALL_STATIC_FUNCTION): Define.
548         (STARTFILE_SPEC): Add crtbegin.o crtbeginS.o.
549         (ENDFILE_SPEC): Define.
550         (INIT_SECTION_ASM_OP): Define.
551         * config/alpha/vms-dwarf2eh.asm (__EH_FRAME_BEGIN__): Remove.
552         * config/alpha/t-vms (EXTRA_PARTS): Add crtbegin.o crtbeginS.o
553         crtend.o crtendS.o.
554         (MULTILIB_OSDIRNAMES): Define.
555         (shlib_version): Define.
556         (SHLIB_EXT): Define.
557         (SHLIB_OBJS): Define.
558         (SHLIB_NAME): Define.
559         (SHLIB_MULTILIB): Define.
560         (SHLIB_INSTALL): Define.
561         (SHLIB_SYMVEC): Define.
562         (SHLIB_SYMVECX2): Define.
563         (SHLIB_LINK): Define.
564
565 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
566
567         * config/alpha/alpha.c (alpha_initialize_trampoline):
568         Initialize VMS trampoline IAW ABI for bounded procedure calls.
569         (alpha_start_function): Emit transfer address on nested functions
570         for VMS trampoline call.
571         * config/alpha/t-vms (LIB2FUNCS_EXTRA): Remove vms_tramp.asm
572         since no longer used.
573         * config/alpha/vms-tramp.asm: Remove.
574         * config/alpha/vms.h (TRAMPOLINE_TEMPLATE): Leave undefined
575         since now only data initialized at runtime.
576
577 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
578
579         * config/alpha/vms.h (HANDLE_SYSV_PRAGMA): Define.
580         (LINK_GCC_C_SEQUENCE_SPEC): Define.
581         (MD_EXEC_PREFIX): Remove, no longer used.
582         (MD_STARTFILE_PREFIX): Likewise.
583         (INCLUDE_DEFAULTS): Likewise.
584         * config/alpha/t-vms:
585         (vms-dwarf2.o, vms-dwarf2eh.o): Use GCC_FOR_TARGET to compile.
586
587 2009-08-09  Richard Guenther  <rguenther@suse.de>
588
589         PR tree-optimization/41016
590         * tree-ssa-ifcombine.c (get_name_for_bit_test): Fix tuplification bug.
591         (operand_precision): Remove.
592         (integral_operand_p): Likewise.
593         (recognize_single_bit_test): Adjust.
594
595 2009-08-09  Richard Sandiford  <rdsandiford@googlemail.com>
596
597         * c-common.c (c_fully_fold_internal): Issue a warning if a binary
598         operation overflows.  Likewise non-cast unary arithmetic.
599         If one arm of a conditional expression is always taken,
600         inhibit evaluation warnings for the other arm.  Likewise inhibit
601         evaluation warnings for the second && or || operand if the first
602         operand is enough to determine the result.
603         * c-typeck.c (build_conditional_expr): Apply the same inhibition
604         rules here.
605         (build_binary_op): Prevent duplicate evaluation warnings.
606
607 2009-08-09  Richard Sandiford  <rdsandiford@googlemail.com>
608
609         * tree-out-of-ssa.c (insert_value_copy_on_edge): If the source
610         and destination have different modes, Use promote_mode to
611         determine the signedness of the conversion.  Assert that the
612         promoted source mode matches the destination mode.  Don't pass
613         the destination and destination mode to expand_expr if the source
614         mode is different.  Simplify conversion logic.
615
616 2009-08-09  Ira Rosen  <irar@il.ibm.com>
617
618         PR tree-optimization/41008
619         * tree-vect-loop.c (vect_is_simple_reduction): Get operands
620         from condition only in case it's a comparison. Adjust checks.
621
622 2009-08-09  Bernd Schmidt  <bernd.schmidt@analog.com>
623
624         * tree-dfa.c (renumber_gimple_stmt_uids_in_blocks): New function.
625         * tree-flow.h (renumber_gimple_stmt_uids_in_blocks): Declare it.
626         * tree-ssa-loop-ivopts.c (comp_cost): Make COST an integer.
627         (enum iv_position): Add IP_AFTER_USE and IP_BEFORE_USE.
628         (dump_cand): Handle them.
629         (struct iv_cand): New members COST_STEP and AINC_USE.
630         (stmt_after_increment): Likewise.
631         (stmt_after_inc_pos): Renamed from stmt_after_ip_original_pos.  All
632         callers changed.  Use gimple_uid comparison instead of scanning.
633         (add_candidate_1): When looking for identical candidates, take
634         AINC_USE into account.  Set it for new candidates.
635         (force_expr_to_var_cost): Cast target_spill_cost to int.
636         (get_address_cost): New arguments STMT_AFTER_INC and MAY_AUTOINC.
637         All callers changed.  Check for availability of autoinc addressing
638         modes, both in general for a given mode, and in the specific use case.
639         (get_computation_cost_at): New argument CAN_AUTOINC.  All callers
640         changed.
641         (get_computation_cost): Likewise.
642         (autoinc_possible_for_pair, set_autoinc_for_original_candidates,
643         add_autoinc_candidates): New static functions.
644         (add_candidate): Call add_autoinc_candidates for candidates based on
645         a USE_ADDRESS use.
646         (find_iv_candidates): Call set_autoinc_for_original_candidates.
647         (determine_use_iv_cost_address): If we have an autoinc candidate at
648         the matching use, verify autoinc is possible and subtract the cost
649         of the candidate's step from the cost.
650         (determine_iv_cost): Record the cost of the increment in the COST_STEP
651         member of the candidate.
652         (tree_ssa_iv_optimize_loop): Swap the calls to determine_iv_costs and
653         determine_use_iv_costs.  Call renumber_gimple_stmt_uids_in_blocks.
654
655 2009-08-09  Douglas B Rupp  <rupp@gnat.com>
656
657         * config.build (ia64-hp-*vms*): New target.
658         (alpha64-dec-*vms*,alpha*-dec-*vms*): Fix for config/vms and unify
659         with ia64-hp-*vms*.
660         * config.gcc (ia64-hp-*vms*): New target.
661         (alpha64-dec-*vms*,alpha*-dec-*vms*): Fix for config/vms and unify
662         with ia64-hp-*vms*.
663         * config.host (ia64-hp-*vms*): New target.
664         (alpha64-dec-*vms*,alpha*-dec-*vms*): Fix for config/vms and unify
665         with ia64-hp-*vms*.
666
667 2009-08-08  Richard Guenther  <rguenther@suse.de>
668
669         PR tree-optimization/40991
670         * tree-ssa-pre.c (eliminate): Delay purging EH edges.
671
672 2009-08-08  Richard Sandiford  <rdsandiford@googlemail.com>
673
674         * combine.c (gen_lowpart_or_truncate): Exclude CONST_INTs from
675         mode check.  Do truncations in an integer mode.
676         (force_to_mode): Handle subregs for all mode types.  Only do
677         arithmetic simplifications on integer modes.
678
679 2009-08-07  Richard Guenther  <rguenther@suse.de>
680
681         PR tree-optimization/40999
682         * tree-ssa-ccp.c (get_symbol_constant_value): Handle CONST_DECLs.
683         (maybe_fold_reference): Lookup constant initializers.
684         (fold_gimple_assign): Likewise.
685
686 2009-08-07  Richard Guenther  <rguenther@suse.de>
687
688         * tree-ssa.c (useless_type_conversion_p_1): Only for types
689         that require structural equality defer to the langhook.
690
691 2009-08-07  Martin Jambor  <mjambor@suse.cz>
692
693         * ipa-prop.h (enum jump_func_type): New value IPA_JF_ANCESTOR, changed
694         comments.
695         (struct ipa_pass_through_data): New type.
696         (struct ipa_ancestor_jf_data): New type.
697         (union jump_func_value): Removed field formal_id, added fields
698         pass_through and ancestor.
699         (struct ipa_param_call_note): Changed type of formal_id to int from
700         unsigned.
701         * ipa-prop.c (ipa_print_node_jump_functions): Print pass through with
702         operations jump functions and ancestor jump functions.
703         (compute_complex_pass_through): New function.
704         (compute_scalar_jump_functions): Call compute_complex_pass_through,
705         reflect changes in the jump function strucutre.
706         (update_jump_functions_after_inlining): Ignore complex pass-through
707         and ancestor jump functions.
708         * ipa-cp.c (ipcp_lattice_from_jfunc): Added support for ancestor and
709         polynomial pass-through with operation jump functions.
710
711 2009-08-07  Jakub Jelinek  <jakub@redhat.com>
712
713         * dwarf2out.c (output_fde): When doing hot/cold partitioning, use
714         fde->dw_fde_begin as begin label instead of hot/cold label.
715         Use LLSDAC label instead of LLSDA for second section lsda.
716         (dwarf2out_do_cfi_startproc): Add SECOND argument.  Use LLSDAC
717         label instead of LLSDA if it is true.
718         (dwarf2out_begin_prologue, dwarf2out_switch_text_section): Adjust
719         callers.
720         * except.c (add_call_site, dw2_size_of_call_site_table): Add
721         SECTION argument.  Use it as index into crtl->eh.call_site_record
722         array.
723         (dw2_output_call_site_table): Likewise.  Add CS_FORMAT argument,
724         use it to determine how to print table entries instead of using
725         #ifdef HAVE_AS_LEB128.  For SECTION > 0 use hot resp. cold
726         label instead of normal begin label as base.
727         (sjlj_assign_call_site_values): Adjust add_call_site caller.
728         (convert_to_eh_region_ranges): When doing hot/cold partitioning,
729         ensure no EH range spans between sections and that landing pads
730         are always in the corresponding section.
731         (sjlj_size_of_call_site_table, sjlj_output_call_site_table): Adjust
732         for crtl->eh.call_site_record being an array rather than scalar.
733         (output_one_function_exception_table): New function, copied
734         from output_function_exception_table.  Adjust
735         dw2_size_of_call_site_table, dw2_output_call_site_table
736         callers.  For SECOND section use *C suffixed labels.
737         (output_function_exception_table): Call
738         output_one_function_exception_table and, when doing hot/cold
739         partitioning, also another time for the second section.
740         * opts.c: Include except.h.
741         (decode_options): Allow -freorder-blocks-and-partition with
742         exceptions, unless SJLJ or TARGET_UNWIND_INFO.
743         * Makefile.in (opts.o): Depend on $(EXCEPT_H).
744         * function.h (struct rtl_eh): Change call_site_record from
745         scalar into array of 2 elements.
746
747 2009-08-07  Martin Jambor  <mjambor@suse.cz>
748
749         * ipa-prop.c (count_formal_params_1): New function.
750         (ipa_get_vector_of_formal_parms): New function.
751         (get_vector_of_formal_parm_types): New function.
752         (ipa_modify_formal_parameters): New function.
753         (ipa_modify_call_arguments): New function.
754         (index_in_adjustments_multiple_times_p): New function.
755         (ipa_combine_adjustments): New function.
756         (ipa_dump_param_adjustments): New function.
757         * ipa-prop.h (struct ipa_parm_adjustment): New type.
758         (ipa_get_vector_of_formal_parms): Declare.
759         (ipa_modify_formal_parameters): Declare.
760         (ipa_modify_call_arguments): Declare.
761         (ipa_combine_adjustments): Declare.
762         (ipa_dump_param_adjustments): Declare.
763         (build_ref_for_offset): Declare.
764         * Makefile.in (tree-sra.o): Add ipa-prop.h to dependencies.
765         * tree-sra.c: Include ipa-prop.c.
766         (build_ref_for_offset): Make public.
767
768 2009-08-06  Neil Vachharajani  <nvachhar@gmail.com>
769
770         * value-prof.c (init_pid_map): Replace xmalloc with XCNEWVEC.
771
772 2009-08-06  Thomas Schwinge  <tschwinge@gnu.org>
773
774         * gcc/doc/extend.texi (__builtin_extract_return_address)
775         (__builtin_frob_return_address): Document.
776
777 2009-08-06  Paul Brook  <paul@codesourcery.com>
778
779         * config/arm/lib1funcs.asm (ARM_DIV_BODY): Add Thumb-2 implementation.
780         (udivsi3, aeabi_uidivmod, divsi3, aeabi_idivmod): Only use Thumb-1
781         implementation on ARMv6-M.
782
783 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
784
785         * doc/extend.texi (pcs): Document new attribute for ARM.
786
787 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
788
789         * arm.c (pcs_attribute_args): Comment out unsupported attribute
790         variants.
791
792 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
793
794         * arm.c (arm_handle_pcs_attribute): Pass the entire name object to
795         warning ().
796
797 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
798
799         * arm.c (arm_handle_pcs_attribute): Use %qE in warning.
800
801 2009-08-06  Richard Earnshaw  <rearnsha@arm.com>
802
803         Merge ARM/hard_vfp_branch to trunk.
804
805         2009-08-04  Richard Earnshaw  <rearnsha@arm.com>
806
807         * arm.c (libcall_eq): New function.
808         (libcall_hash): New function.
809         (add_libcall): New function.
810         (arm_libcall_uses_aapcs_base): New function.
811         (arm_libcall_value): Use arm_libcall_uses_aapcs_base to check for
812         libcalls using the base PCS.
813         (arm_init_cumulative_args): Likewise.
814
815         2009-07-20  Joseph Myers  <joseph@codesourcery.com>
816
817         * config/arm/arm.c (arm_libcall_value, arm_init_cumulative_args):
818         Use base ABI for conversion libfuncs between HFmode and SFmode.
819
820         2009-05-12  Joseph Myers  <joseph@codesourcery.com>
821
822         * config/arm/arm.c (aapcs_vfp_sub_candidate): Use V2SImode and
823         V4SImode as representatives of all 64-bit and 128-bit vector
824         types.  Allow vector types without vector modes.
825         (aapcs_vfp_is_call_or_return_candidate): Handle vector types
826         without vector modes like BLKmode.
827         (aapcs_vfp_allocate): Handle TImode for non-TARGET_NEON like
828         BLKmode.  Avoid unsupported vector modes or TImode moves for
829         non-TARGET_NEON.
830         (aapcs_vfp_allocate_return_reg): Likewise.
831         (arm_vector_mode_supported_p): Only support V2SImode, V4HImode and
832         V8QImode if TARGET_NEON || TARGET_IWMMXT.
833
834         2009-05-12  Joseph Myers  <joseph@codesourcery.com>
835
836         * config/arm/arm.c (arm_handle_pcs_attribute): New.
837         (arm_get_pcs_model): Pass attribute arguments to
838         arm_pcs_from_attribute.
839         (arm_init_cumulative_args): Use base AAPCS for conversions from
840         floating-point types to DImode.
841         (arm_attribute_table): Add pcs attribute.
842         (arm_handle_pcs_attribute): New.
843         * config/arm/bpabi.h (DECLARE_LIBRARY_RENAMES): When renaming
844         conversions from floating-point types to DImode, also declare them
845         to use base AAPCS and declare functions they call to use base
846         AAPCS and their RTABI names.
847
848         2009-05-12  Joseph Myers  <joseph@codesourcery.com>
849
850         * doc/invoke.texi (-mfloat-abi=@var{name}): Remove statement about
851         -mfloat-abi=hard not being supported for VFP.
852
853         2009-05-11  Kazu Hirata  <kazu@codesourcery.com>
854
855         * config/sparc/sparc.c (sparc_emit_float_lib_cmp): Pass a libcall
856         SYMBOL_REF to hard_libcall_value.
857
858         2009-03-05  Joseph Myers  <joseph@codesourcery.com>
859             Richard Earnshaw  <rearnsha@arm.com>
860
861         * config/arm/arm.c (aapcs_layout_arg): Once a co-processor argument
862         has been put on the stack, all remaining co-processory arguments for
863         that co-processor also go on the stack.
864
865         2009-03-05  Joseph Myers  <joseph@codesourcery.com>
866
867         * config/arm/arm.c (arm_return_in_memory): Handle returning
868         vectors of suitable size in registers also for AAPCS case.
869
870         2009-01-13  Richard Earnshaw <rearnsha@arm.com>
871
872         * doc/tm.texi (TARGET_LIBCALL_VALUE): Add missing end statement.
873
874         2008-12-09  Richard Earnshaw <rearnsha@arm.com>
875
876         ARM Hard-VFP calling convention
877         * target-def.h (TARGET_LIBCALL_VALUE): New hook.
878         * target.h (gcc_target): Add libcall_value to table of call hooks.
879         * targhooks.h (default_libcall_value): Default implementation.
880         * targhooks.c (default_libcall_value): Likewise.
881         * doc/tm.texi (TARGET_LIBCALL_VALUE): Document it.
882         * optabs.c (expand_unop): Use it.
883         * expr.h (hard_libcall_value): Pass the function RTX through.
884         * calls.c (emit_library_call_value_1): Update call to
885         hard_libcall_value.
886         * explow.c (hard_libcall_value): Use new target hook.
887         * testsuite/lib/target-supports.exp
888         (check_effective_target_arm_hard_vfp_ok): New hook.
889         (check_effective_target_arm_neon_ok): Improve test for neon
890         availability.
891         * testsuite/gcc.target/arm/eabi1.c: Only run test in base variant.
892         * config/arm/arm.c: Include cgraph.h
893         (TARGET_FUNCTION_VALUE): Override default hook.
894         (arm_pcs_default): New variable.
895         (arm_override_options): Don't fault hard calling convention with VFP.
896         Add support for AAPCS variants.
897         (arm_function_value): Make static.  Handle AAPCS variants.
898         (arm_libcall_value): New function.
899         (arm_apply_result_size): Handle VFP registers in results.
900         (arm_return_in_memory): Rework all AAPCS variants; handle hard-vfp
901         conventions.
902         (pcs_attribute_args): New variable.
903         (arm_pcs_from_attribute): New function.
904         (arm_get_pcs_model): New function.
905         (aapcs_vfp_cum_init): New function.
906         (aapcs_vfp_sub_candidate): New function.
907         (aapcs_vfp_is_return_candidate): New function.
908         (aapcs_vfp_is_call_candidate): New function.
909         (aapcs_vfp_allocate): New function.
910         (aapcs_vfp_allocate_return_reg): New function.
911         (aapcs_vfp_advance): New function.
912         (aapcs_cp_arg_layout): New variable.
913         (aapcs_select_call_coproc): New function.
914         (aapcs_select_return_coproc): New function.
915         (aapcs_allocate_return_reg): New function.
916         (aapcs_libcall_value): New function.
917         (aapcs_layout_arg): New function.
918         (arm_init_cumulative_args): Initialize AAPCS args data.
919         (arm_function_arg): Handle AAPCS variants using new interface.
920         (arm_arg_parital_bytes): Likewise.
921         (arm_function_arg_advance): New function.
922         (arm_function_ok_for_sibcall): Ensure that sibling calls agree on
923         calling conventions.
924         (arm_setup_incoming_varargs): Handle new AAPCS args data.
925         * arm.h (NUM_VFP_ARG_REGS): Define.
926         (LIBCALL_VALUE): Update.
927         (FUNCTION_VALUE): Delete.
928         (FUNCTION_VALUE_REGNO_P): Add VFP regs.
929         (arm_pcs): New enum.
930         (CUMULATIVE_ARGS): New data to support AAPCS argument marshalling.
931         (FUNCTION_ARG_ADVANCE): Call arm_function_arg_advance.
932         (FUNCTION_ARG_REGNO_P): Add VFP regs.
933         * arm-protos.h (arm_function_arg_advance): Add.
934         (aapcs_libcall_value): Add.
935         (arm_function_value): Delete.
936
937 2009-08-06  Uros Bizjak  <ubizjak@gmail.com>
938             H.J. Lu  <hongjiu.lu@intel.com>
939
940         PR target/40957
941         * config/i386/i386.c (standard_sse_mode_p): Remove.
942         (standard_sse_constant_p): Return 2 for integer mode
943         vector_all_ones_operand when SSE2 is enabled.
944         (standard_sse_constant_opcode)<case 2>: Always return [v]pcmpeqd.
945         (ix86_expand_vector_move): Do not check for negative values from
946         standard_sse_constant_p.
947
948 2009-08-06  Richard Guenther  <rguenther@suse.de>
949
950         * tree-ssa.c (useless_type_conversion_p_1): Make function and
951         array type comparisons frontend independent.
952         * Makefile.in (tree-ssa.o): Add $(TARGET_H) dependency.
953         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Always fill
954         out array reference lower bound and element size operands.
955         (ao_ref_init_from_vn_reference): Properly compute the offset
956         for ARRAY_RANGE_REF.
957         (vn_reference_fold_indirect): Fill out array reference lower
958         bound and element size operands.
959         * tree-ssa-pre.c (phi_translate_1): Fail if we have to translate
960         a non gimple valued reference operand which can happen for
961         array reference lower bound or element size.
962         (create_component_ref_by_pieces_1): Properly generate the
963         element size operand for array references.
964
965 2009-08-06  Richard Guenther  <rguenther@suse.de>
966
967         PR tree-optimization/40964
968         * tree.c (iterative_hash_host_wide_int): Export.
969         * tree.h (iterative_hash_host_wide_int): Declare.
970         * tree-ssa-structalias.c (heapvar_map): New struct.
971         (heapvar_map_eq): New function.
972         (heapvar_map_hash): Likewise.
973         (heapvar_lookup): Adjust.
974         (heapvar_insert): Likewise.
975         (make_constraint_from_heapvar): Allow multiple heap variables
976         per decl at different offsets.
977         (init_alias_heapvars): Adjust.
978
979 2009-08-04  David Daney  <ddaney@caviumnetworks.com>
980
981         * config/mips/mips.h (TARGET_SYNC_AFTER_SC): New macro.
982         * mips_output_sync_loop (mips_output_sync_loop): Only emit
983         trailing sync if TARGET_SYNC_AFTER_SC.
984
985 2009-08-05  David Daney  <ddaney@caviumnetworks.com>
986
987         * gcc/config/mips/sync.md (sync_compare_and_swap<mode>,
988         compare_and_swap_12, sync_add<mode>, sync_<optab>_12,
989         sync_old_<optab>_12, sync_new_<optab>_12, sync_nand_12,
990         sync_old_nand_12, sync_new_nand_12, sync_sub<mode>,
991         sync_old_add<mode>, sync_old_sub<mode>, sync_new_add<mode>,
992         sync_new_sub<mode>, sync_<optab><mode>, sync_old_<optab><mode>,
993         sync_new_<optab><mode>, sync_nand<mode>, sync_old_nand<mode>,
994         sync_new_nand<mode>, sync_lock_test_and_set<mode>,
995         test_and_set_12): Rewrite calls to mips_output_sync_loop.
996         * gcc/config/mips/mips-protos.h (mips_output_sync_loop): Make
997         the prototype declaration match the definition.
998         * gcc/config/mips/mips.c (mips_output_sync_loop):  Emit sync
999         instructions explicitly.  Add barrier_before and operands
1000         parameters.
1001         * gcc/config/mips/mips.h (MIPS_COMPARE_AND_SWAP,
1002         MIPS_COMPARE_AND_SWAP_12, MIPS_SYNC_OP, MIPS_SYNC_OP_12,
1003         MIPS_SYNC_OLD_OP_12, MIPS_SYNC_NEW_OP_12, MIPS_SYNC_OLD_OP,
1004         MIPS_SYNC_NEW_OP, MIPS_SYNC_NAND, MIPS_SYNC_OLD_NAND,
1005         MIPS_SYNC_NEW_NAND, MIPS_SYNC_EXCHANGE,
1006         MIPS_SYNC_EXCHANGE_12): Remove sync instructions.
1007
1008 2009-08-05  Andrew Pinski  <pinskia@gmail.com>
1009
1010         * tree-ssa-alias.c: Fix intervals to use [) syntax.
1011
1012 2009-08-05  Uros Bizjak  <ubizjak@gmail.com>
1013             Mikulas Patocka  <mikulas@artax.karlin.mff.cuni.cz>
1014
1015         PR target/40906
1016         * config/i386/i386.c (ix86_split_long_move): Fix push of multi-part
1017         source operand.
1018
1019 2009-08-05  Jakub Jelinek  <jakub@redhat.com>
1020
1021         PR rtl-optimization/40924
1022         * dse.c (canon_address): Before calling cselib_expand_value_rtx
1023         make sure canon_rtx (mem_address) isn't simpler than
1024         canon_rtx (expanded_mem_address).
1025
1026 2009-08-05  Li Feng  <nemokingdom@gmail.com>
1027
1028         * graphite-sese-to-poly.c (build_pbb_drs): Remove build alias set
1029         for each poly_bb_p.
1030         (build_scop_drs): Build alias set for each SCoP.
1031
1032 2009-08-04  Sandra Loosemore  <sandra@codesourcery.com>
1033
1034         * doc/invoke.texi (MIPS Options): Document new 1004K -march options.
1035         * config/mips/mips.c (mips_cpu_info_table): Add 1004K cores.
1036         * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Add pattern for 1004K.
1037         (MIPS_ARCH_FLOAT_SPEC): Likewise.
1038         (BASE_DRIVER_SELF_SPECS): Likewise.
1039
1040 2009-08-04  Andrew Pinski  <pinskia@gmail.com>
1041
1042         * tree-ssa-alias.c: Fix some comment typos.
1043
1044 2009-08-04  Kaz Kojima  <kkojima@gcc.gnu.org>
1045
1046         * config/sh/linux-atomic.asm (ATOMIC_BOOL_COMPARE_AND_SWAP,
1047         ATOMIC_OP_AND_FETCH, ATOMIC_COMBOP_AND_FETCH): Define.
1048
1049 2009-08-03  Janis Johnson  <janis187@us.ibm.com>
1050
1051         PR c/39902
1052         * simplify-rtx.c (simplify_binary_operation_1): Disable
1053         simplifications for decimal float operations.
1054
1055 2009-08-03  Jakub Jelinek  <jakub@redhat.com>
1056
1057         PR middle-end/40943
1058         * tree-ssa.c (warn_uninitialized_var): Even on LHS warn for
1059         operand of INDIRECT_REF.
1060
1061 2009-08-03  Uros Bizjak  <ubizjak@gmail.com>
1062
1063         * config/alpha/alpha.c (alpha_legitimate_constant_p): Reject CONST
1064         constants referencing TLS symbols.
1065
1066 2009-08-03  SUGIOKA Toshinobu  <sugioka@itonet.co.jp>
1067
1068         * config/sh/linux-atomic.asm (ATOMIC_COMPARE_AND_SWAP): Rename
1069         __sync_compare_and_swap_* to __sync_val_compare_and_swap_*.
1070
1071 2009-08-03  Richard Guenther  <rguenther@suse.de>
1072
1073         * tree.c (make_vector_type): Build a main variant first,
1074         get the canonical one and then build the variant.
1075         * tree-ssa.c (useless_type_conversion_p_1): Handle
1076         fixed-point types.
1077         (useless_type_conversion_p): Conversions to pointers to
1078         incomplete record types are useless.
1079
1080 2009-08-03  Richard Guenther  <rguenther@suse.de>
1081
1082         * tree-cfg.c (pass_warn_unused_result): Mark name that no dump
1083         file will be created.
1084         * omp-low.c (pass_diagnose_omp_blocks): Likewise.
1085         * toplev.c (compile_file): Adjust comment.
1086
1087 2009-08-03  Kaz Kojima  <kkojima@gcc.gnu.org>
1088
1089         * config/sh/sh-protos.h (sh_promote_function_mode): Remove.
1090         * config/sh/sh.c (sh_promote_function_mode): Wrap long lines.
1091         (TARGET_PROMOTE_FUNCTION_MODE): Define.
1092         (TARGET_PROMOTE_FUNCTION_ARGS): Remove.
1093         (sh_promote_function_mode): Fix typo.
1094
1095 2009-08-03  Andreas Krebbel  <krebbel1@de.ibm.com>
1096
1097         * explow.c (promote_mode): Mark TYPE and PUNSIGNEDP as possibly unused.
1098
1099 2009-08-02  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1100
1101         * pa.c (pa_promote_function_mode): Remove ATTRIBUTE_UNUSED from
1102         declaration arguments.
1103
1104 2009-08-02  Uros Bizjak  <ubizjak@gmail.com>
1105
1106         * config/i386/i386.c (ix86_expand_fp_compare): Use const0_rtx instead
1107         of GEN_INT (0x00) and const1_rtx instead of GEN_INT (0x01).
1108         (ix86_split_ashl): Ditto.
1109         (ix86_expand_vector_init_one_nonzero): Ditto.
1110         (ix86_expand_vector_set): Ditto.
1111         (ix86_expand_reduc_v4sf): Ditto.
1112
1113 2009-08-02  Paolo Bonzini  <bonzini@gnu.org>
1114
1115         * explow.c (promote_function_mode): Remove assert.
1116         * config/sh/sh.c (sh_promote_function_mode): Declare.
1117
1118 2009-08-01  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1119
1120         * config/pa/pa.c (pa_promote_function_mode): Declare.
1121         Change to static.  Fix promote_mode call.
1122
1123         * gthr-dce.h (CONST_CAST2): Define if not defined.
1124         (__gthread_setspecific): Use CONST_CAST2 to fix warning.
1125
1126         * config.gcc (hppa[12]*-*-hpux10*): Add stdint support.
1127
1128 2009-08-01  Paolo Bonzini  <bonzini@gnu.org>
1129
1130         * expr.c (store_constructor): Use promote_decl_mode.  Remove
1131         now write-only variable unsignedp.
1132         (expand_expr_real_1): Use promote_decl_mode.
1133         * expr.h (promote_function_mode, promote_decl_mode): New.
1134         (promote_mode): Remove last argument.
1135         * function.c (assign_temp): Drop last argument of promote_mode.
1136         (assign_parm_find_data_types): Use promote_function_mode.
1137         (assign_parm_setup_reg): Likewise.
1138         (expand_function_end): Use promote_function_mode.
1139         * calls.c (initialize_argument_information): Use promote_function_mode.
1140         (precompute_arguments): Use promote_mode instead of checking if
1141         only PROMOTE_FUNCTION_MODE is defined.
1142         (expand_call): When making sibcall decisions, use promote_function_mode.
1143         Below, remove an if for targetm.calls.promote_function_return and
1144         and use promote_function_mode.
1145         (emit_library_call_value_1): Use promote_function_mode, fix bug
1146         where promote_mode was passed FOR_CALL == 0 for a return value in an
1147         assertion.
1148         * cfgexpand.c (expand_one_register_var): Use promote_decl_mode.
1149         * explow.c (promote_function_mode, promote_decl_mode): New.
1150         (promote_mode): Keep only the FOR_CALL == 0 case.
1151         * combine.c (setup_incoming_promotion): Remove test of
1152         promote_function_args.  Use promote_function_mode.
1153         * stmt.c (expand_value_return): Use promote_decl_mode.
1154         (expand_decl): Use promote_decl_mode.
1155
1156         * expr.c (store_constructor): Use promote_decl_mode.  Remove
1157         now write-only variable unsignedp.
1158         (expand_expr_real_1): Use promote_decl_mode.
1159         * expr.h (promote_function_mode, promote_decl_mode): New.
1160         (promote_mode): Remove last argument.
1161         * function.c (assign_temp): Drop last argument of promote_mode.
1162         (assign_parm_find_data_types): Use promote_function_mode.
1163         (assign_parm_setup_reg): Likewise.
1164         (expand_function_end): Use promote_function_mode.
1165         * calls.c (initialize_argument_information): Use promote_function_mode.
1166         (precompute_arguments): Use promote_mode instead of checking if
1167         only PROMOTE_FUNCTION_MODE is defined.
1168         (expand_call): When making sibcall decisions, use promote_function_mode.
1169         Below, remove an if for targetm.calls.promote_function_return and
1170         and use promote_function_mode.
1171         (emit_library_call_value_1): Use promote_function_mode, fix bug
1172         where promote_mode was passed FOR_CALL == 0 for a return value in an
1173         assertion.
1174         * cfgexpand.c (expand_one_register_var): Use promote_decl_mode.
1175         * explow.c (promote_function_mode, promote_decl_mode): New.
1176         (promote_mode): Keep only the FOR_CALL == 0 case.
1177         * combine.c (setup_incoming_promotion): Remove test of
1178         promote_function_args.  Use promote_function_mode.
1179         * stmt.c (expand_value_return): Use promote_decl_mode.
1180         (expand_decl): Use promote_decl_mode.
1181
1182         * explow.c (promote_function_mode): Just call the target hook.
1183         * targhooks.c (default_promote_function_mode,
1184         default_promote_function_mode_always_promote): New.
1185         * targhooks.h (default_promote_function_mode,
1186         default_promote_function_mode_always_promote): Declare.
1187         * target.h (promote_function_args, promote_function_return): Remove.
1188         (promote_function_mode): New.
1189         * target-def.h (TARGET_PROMOTE_FUNCTION_ARGS,
1190         TARGET_PROMOTE_FUNCTION_RETURN): Remove.
1191         (TARGET_PROMOTE_FUNCTION_MODE): New.
1192         (TARGET_CALLS): Adjust.
1193         * system.h (TARGET_PROMOTE_FUNCTION_ARGS,
1194         TARGET_PROMOTE_FUNCTION_RETURN, PROMOTE_FUNCTION_MODE): Poison.
1195
1196         * config/s390/s390.h (PROMOTE_FUNCTION_MODE): Move...
1197         * config/s390/s390.c (s390_promote_function_mode): ... here,
1198         with pointer handling.
1199         (TARGET_PROMOTE_FUNCTION_MODE): Define.
1200         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
1201
1202         * config/sparc/sparc.h (PROMOTE_FUNCTION_MODE): Move...
1203         * config/sparc/sparc.c (sparc_promote_function_mode): ... here,
1204         with pointer handling.
1205         (TARGET_PROMOTE_FUNCTION_MODE): Define.
1206         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
1207
1208         * config/sh/sh-protos.h (sh_promote_function_mode): New.
1209         * config/sh/sh.c (sh_promote_function_mode): New.
1210         (TARGET_PROMOTE_FUNCTION_MODE): Define.
1211         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
1212
1213         * config/cris/cris.h (PROMOTE_FUNCTION_MODE): Move...
1214         * config/cris/cris.c (cris_promote_function_mode): ... here.
1215         (TARGET_PROMOTE_FUNCTION_MODE): Define.
1216         (TARGET_PROMOTE_FUNCTION_ARGS): Remove.
1217
1218         * config/mmix/mmix.h (PROMOTE_FUNCTION_MODE): Move...
1219         * config/mmix/mmix.c (mmix_promote_function_mode): ... here.
1220         (TARGET_PROMOTE_FUNCTION_MODE): Define.
1221         (TARGET_PROMOTE_FUNCTION_ARGS): Remove.
1222
1223         * config/arm/arm.h (PROMOTE_FUNCTION_MODE): Move...
1224         * config/arm/arm.c (arm_promote_function_mode): ... here, without
1225         complex type handling.
1226         (TARGET_PROMOTE_FUNCTION_MODE): Define.
1227         (TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
1228
1229         * config/pa/pa.c (pa_promote_function_mode): New.
1230         (TARGET_PROMOTE_FUNCTION_MODE): Define.
1231         (TARGET_PROMOTE_FUNCTION_RETURN): Remove.
1232
1233         * config/alpha/alpha.c (TARGET_PROMOTE_FUNCTION_ARGS,
1234         TARGET_PROMOTE_FUNCTION_RETURN): Remove.
1235         (TARGET_PROMOTE_FUNCTION_MODE): Define equivalently.
1236         * config/xtensa/xtensa.c: Likewise.
1237         * config/stormy16/stormy16.c: Likewise.
1238         * config/iq2000/iq2000.c: Likewise.
1239         * config/rs6000/rs6000.c: Likewise.
1240         * config/picochip/picochip.c: Likewise.
1241         * config/arc/arc.c: Likewise.
1242         * config/mcore/mcore.c: Likewise.
1243         * config/score/score.c: Likewise.
1244         * config/mips/mips.c: Likewise.
1245         * config/bfin/bfin.c: Likewise.
1246         * config/ia64/ia64.c: Likewise (disabled though).
1247
1248         * config/frv/frv.h: Remove pointless remark.
1249
1250         * doc/tm.texi (PROMOTE_FUNCTION_MODE,
1251         TARGET_PROMOTE_FUNCTION_ARGS,
1252         TARGET_PROMOTE_FUNCTION_RETURN): Consolidate into...
1253         (TARGET_PROMOTE_FUNCTION_MODE): ... this.
1254
1255 2009-08-01  Sebastian Pop  <sebastian.pop@amd.com>
1256
1257         * doc/invoke.texi (-fgraphite-force-parallel): Renamed
1258         -floop-parallelize-all.
1259         * toplev.c (process_options): Rename flag_graphite_force_parallel to
1260         flag_loop_parallelize_all.
1261         * tree-ssa-loop.c (gate_graphite_transforms): Same.
1262         * graphite.c (graphite_transform_loops): Same.
1263         * common.opt: Same.
1264         * graphite-poly.c (apply_poly_transforms): Same.
1265
1266 2009-07-31  Richard Earnshaw  <rearnsha@arm.com>
1267
1268         PR tree-optimization/40914
1269         * ipa-prop.c (ipa_get_ptr_load_param): New argument use_delta,
1270         if set, then check the delta field of the PMF record.
1271         (ipa_get_stmt_member_ptr_load_param): Propagate new param use_delta.
1272         (ipa_analyze_call_uses): Handle machines where the vbit for a PMF
1273         call is stored in the delta.
1274
1275 2009-07-31  Adam Nemet  <anemet@caviumnetworks.com>
1276
1277         * config/mips/mips.md (*clear_upper32_dext): New pattern.
1278
1279 2009-07-31  Uros Bizjak  <ubizjak@gmail.com>
1280
1281         * config/i386/bsd.h (ASM_BYTE): New define.
1282         * config/i386/darwin.h (ASM_BYTE): Rename from ASM_BYTE_OP.
1283         * config/i386/att.h (ASM_BYTE): New define. Use ASM_BYTE instead of
1284         .byte.  Use fputs or putc instead of fprintf where appropriate.
1285         * config/i386/i386-interix.h: Use ASM_BYTE instead of .byte.  Use
1286         fputs or putc instead of fprintf where appropriate.
1287         * config/i386/i386elf.h: Ditto.
1288         * config/i386/sysv4.h: Ditto.
1289
1290         * config/i386/i386.c (TARGET_ASM_BYTE_OP): New define.
1291         * config/i386/i386.md (x86_sahf_1): Use ASM_BYTE instead of .byte.
1292         (*tls_global_dynamic_64): Ditto.
1293
1294 2009-07-31  Christian Bruel  <christian.bruel@st.com>
1295
1296         * gcc/config.gcc (sh*-*-elf): test with_libgloss.
1297
1298 2009-07-31  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
1299
1300         * config/arm/arm.c (arm_arm_address_cost): Fix typo.
1301         Remove dead code for MINUS.
1302
1303 2009-07-31  Anthony Green  <green@moxielogic.com>
1304
1305         * config/moxie/moxie.c (moxie_expand_prologue): Use $r5 instead of
1306         $r12 in prologue.
1307         (moxie_expand_epilogue): Ditto for epilogue.
1308         (moxie_setup_incoming_varargs): ABI change.  Use 5 registers for
1309         incoming arguments.
1310         (moxie_function_arg): Ditto.
1311         (moxie_pass_by_reference): Ditto.
1312         (moxie_arg_partial_bytes): Ditto.
1313         * config/moxie/moxie.h (CALL_USED_REGISTERS): Ditto.
1314         (FUNCTION_ARG_ADVANCE) Ditto.
1315         (REG_PARM_STACK_SPACE) Ditto.
1316         (FUNCTION_ARG_REGNO_P) Dito.
1317
1318         * config.gcc: Add moxie linux config support.
1319         * gcc/config/moxie/uclinux.h: New file.
1320
1321 2009-07-31  DJ Delorie  <dj@redhat.com>
1322
1323         * config/sh/sh.md (UNSPECV_SP_SWITCH_B): New.
1324         (UNSPECV_SP_SWITCH_E): New.
1325         (sp_switch_1): Change to an unspec.
1326         (sp_switch_2): Change to an unspec.  Don't use post-inc when we
1327         replace $r15.
1328         * config/sh/sh.c (sh_expand_prologue): Use the constant pool to
1329         reference the new stack's address
1330
1331 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1332
1333         * Makefile.in (OBJS-common): Added dependence on graphite-blocking.o,
1334         graphite-clast-to-gimple.o, graphite-dependences.o,
1335         graphite-interchange.o, graphite-poly.o, graphite-ppl.o,
1336         graphite-scop-detection.o, graphite-sese-to-poly.o, and sese.o.
1337         (graphite-blocking.o,
1338         graphite-clast-to-gimple.o, graphite-dependences.o,
1339         graphite-interchange.o, graphite-poly.o, graphite-ppl.o,
1340         graphite-scop-detection.o, graphite-sese-to-poly.o, and sese.o): New.
1341         * cfgloop.c (alloc_loop): Set loop->can_be_parallel to false.
1342         * cfgloop.h (struct loop): Add can_be_parallel field.
1343         * common.opt (fgraphite-identity): Moved up.
1344         (fgraphite-force-parallel): New flag.
1345         * graphite.c: Rewrite.
1346         * graphite.h: Rewrite.
1347         * passes.c (init_optimization_passes): Schedule a pass of DCE and LIM
1348         after Graphite.
1349         * toplev.c (graphite_out_file): New file descriptor.
1350         (graphite_in_file): New.
1351         (process_options): flag_graphite_force_parallel cannot be used without
1352         Graphite.
1353         * tree-ssa-loop.c: Include toplev.h.
1354         (gate_graphite_transforms): Enable flag_graphite for
1355         flag_graphite_force_parallel.
1356
1357 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1358
1359         * ChangeLog.graphite: New.
1360         * graphite-blocking.c: New.
1361         * graphite-clast-to-gimple.c: New.
1362         * graphite-clast-to-gimple.h: New.
1363         * graphite-dependences.c: New.
1364         * graphite-dependences.h: New.
1365         * graphite-interchange.c: New.
1366         * graphite-poly.c: New.
1367         * graphite-poly.h: New.
1368         * graphite-ppl.c: New.
1369         * graphite-ppl.h: New.
1370         * graphite-scop-detection.c: New.
1371         * graphite-scop-detection.h: New.
1372         * graphite-sese-to-poly.c: New.
1373         * graphite-sese-to-poly.h: New.
1374         * sese.c: New.
1375         * sese.h: New.
1376
1377 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1378
1379         * tree-chrec.c (evolution_function_right_is_integer_cst): New.
1380         * tree-chrec.h (evolution_function_right_is_integer_cst): Declared.
1381
1382 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1383
1384         * tree-chrec.c (operator_is_linear): Handle BIT_NOT_EXPR.
1385         (scev_is_linear_expression): Return false if the evolution is not
1386         affine multivariate.
1387
1388 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1389
1390         * tree-data-ref.c (graphite_find_data_references_in_stmt): New.
1391         * tree-data-ref.h (graphite_find_data_references_in_stmt): Declared.
1392
1393 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1394
1395         * tree-data-ref.c (debug_data_references): New.
1396         (debug_data_reference): New.
1397         * tree-data-ref.h (debug_data_references): Declared.
1398         (debug_data_reference): Declared.
1399
1400 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1401
1402         * tree-data-ref.c (stmt_simple_memref_p: Removed.
1403         * tree-data-ref.h (scop_p): Removed.
1404         (struct data_reference): Remove field scop.
1405         (DR_SCOP): Removed.
1406         (stmt_simple_memref_p): Removed.
1407
1408 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1409
1410         * cfgloop.h (create_empty_loop_on_edge): Pass an extra argument.
1411         * cfgloopmanip.c (create_empty_loop_on_edge): Leave the loop_latch
1412         basic block empty.
1413
1414 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1415
1416         * doc/invoke.texi (-fgraphite-force-parallel): Documented.
1417
1418 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1419
1420         * doc/invoke.texi (-fgraphite-identity): Documented.
1421
1422 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1423
1424         * tree-scalar-evolution.c: Fix comment.
1425         (instantiate_scev_1): Return unknow from scev instantiation if the
1426         result is not above instantiate_below.
1427
1428 2009-07-30  Sebastian Pop  <sebastian.pop@amd.com>
1429
1430         * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop): Not
1431         static anymore.  Instantiate the symbols that may have been introduced
1432         by chrec_apply.
1433         * tree-scalar-evolution.h (compute_overall_effect_of_inner_loop):
1434         Declared.
1435
1436 2009-07-30  DJ Delorie  <dj@redhat.com>
1437
1438         * config/mep/mep.c (mep_asm_init_sections): Add section flags and
1439         .vliw directive to VLIW sections.
1440
1441 2009-07-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1442
1443         * Makefile.in (AUTOCONF, ACLOCAL, ACLOCAL_AMFLAGS, aclocal_deps):
1444         New variables.
1445         ($(srcdir)/configure, $(srcdir)/aclocal.m4): New rules.
1446         (AUTOHEADER): New variable.
1447         ($(srcdir)/cstamp-h.in): Use it.
1448
1449 2009-07-30  Michael Meissner  <meissner@linux.vnet.ibm.com>
1450             Pat Haugen  <pthaugen@us.ibm.com>
1451             Revital Eres <ERES@il.ibm.com>
1452
1453         * config/rs6000/vector.md (VEC_F): Add VSX support.
1454         (VEC_A): Ditto.
1455         (VEC_N): Ditto.
1456         (mov<mode>): Ditto.
1457         (vector_load_<mode>): Ditto.
1458         (vector_store_<mode>): Ditto.
1459         (vector GPR move split): Ditto.
1460         (vec_reload_and_plus_<mptrsize>): Ditto.
1461         (vec_reload_and_reg_<mptrsize>): Ditto.
1462         (add<mode>3): Ditto.
1463         (sub<mode>3): Ditto.
1464         (mul<mode>3): Ditto.
1465         (neg<mode>2): Ditto.
1466         (abs<mode>2): Ditto.
1467         (smin<mode>3): Ditto.
1468         (smax<mode>3): Ditto.
1469         (vector_eq<mode>): Ditto.
1470         (vector_gt<mode>): Ditto.
1471         (vector_ge<mode>): Ditto.
1472         (vector_gtu<mode>): Ditto.
1473         (vector_select_<mode>_uns): Ditto.
1474         (vector_eq_<mode>_p): Ditto.
1475         (vector_gt_<mode>_p): Ditto.
1476         (vector_ge_<mode>_p): Ditto.
1477         (vector_gtu_<mode>_p): Ditto.
1478         (cr6_test_for_zero): Ditto.
1479         (cr6_test_for_zero_reverse): Ditto.
1480         (cr6_test_for_lt): Ditto.
1481         (cr6_test_for_lt_reverse): Ditto.
1482         (xor<mode>3): Ditto.
1483         (ior<mode>3): Ditto.
1484         (and<mode>3): Ditto.
1485         (one_cmpl<mode>2): Ditto.
1486         (nor<mode>2): Ditto.
1487         (andc<mode>2): Ditto.
1488         (float<VEC_int<mode>2): Ditto.
1489         (unsigned_float<VEC_int><mode>2): Ditto.
1490         (fix_trunc<mode><VEC_int>2): Ditto.
1491         (fixuns_trunc<mode><VEC_int>2): Ditto.
1492         (vec_init<mode>):
1493         (vec_set<mode>): Ditto.
1494         (vec_extract<mode>): Ditto.
1495         (vec_interleave_highv4sf): Ditto.
1496         (vec_interleave_lowv4sf): Ditto.
1497         (vec_realign_load_<mode>): Ditto.
1498         (vec_shl_<mode>): Ditto.
1499         (vec_shr_<mode>): Ditto.
1500         (div<mode>3): New patterns for VSX.
1501         (vec_interleave_highv2df): Ditto.
1502         (vec_interleave_lowv2df): Ditto.
1503         (vec_pack_trunc_v2df): Ditto.
1504         (vec_pack_sfix_trunc_v2df): Ditto.
1505         (vec_pack_ufix_trunc_v2df): Ditto.
1506         (vec_unpacks_hi_v4sf): Ditto.
1507         (vec_unpacks_lo_v4sf): Ditto.
1508         (vec_unpacks_float_hi_v4si): Ditto.
1509         (vec_unpacks_float_lo_v4si): Ditto.
1510         (vec_unpacku_float_hi_v4si): Ditto.
1511         (vec_unpacku_float_lo_v4si): Ditto.
1512         (movmisalign<mode>): Ditto.
1513         (vector_ceil<mode>2): New patterns for vectorizing math library.
1514         (vector_floor<mode>2): Ditto.
1515         (vector_btrunc<mode>2): Ditto.
1516         (vector_copysign<mode>3): Ditto.
1517
1518         * config/rs6000/predicates.md (easy_vector_constant_msb): New
1519         predicate for setting the high bit in each word, used for copysign.
1520
1521         * config/rs6000/ppc-asm.h (f19): Whitespace.
1522         (f32-f63): Define if VSX.
1523         (v0-v31): Define if Altivec.
1524         (vs0-vs63): Define if VSX.
1525
1526         * config/rs6000/t-rs6000 (MD_INCLUDES): Add power7.md and vsx.md.
1527
1528         * config/rs6000/power7.md: New file, provide tuning parameters for
1529         -mcpu=power7.
1530
1531         * config/rs6000/rs6000-c.c (rs6000_macro_to_expand): Add VSX support.
1532         (rs6000_cpu_cpp_builtins): Ditto.
1533         (altivec_overloaded_builtins): Ditto.
1534         (altivec_resolve_overloaded_builtin): Ditto.
1535
1536         * config/rs6000/rs6000.opt (-mno-vectorize-builtins): Add new
1537         debug switch to disable vectorizing simple math builtin
1538         functions.
1539
1540         * config/rs6000/rs6000.c (rs6000_builtin_vectorized_function):
1541         Vectorize simple math builtin functions.
1542         (TARGET_VECTORIZE_BUILTIN_VECTORIZED_FUNCTION): Define target
1543         hook to vectorize math builtins.
1544         (rs6000_override_options): Enable -mvsx on -mcpu=power7.
1545         (rs6000_builtin_conversion): Add VSX/power7 support.
1546         (rs6000_builtin_vec_perm): Ditto.
1547         (vsplits_constant): Add support for loading up a vector constant
1548         with just the high bit set in each part.
1549         (rs6000_expand_vector_init): Add VSX/power7 support.
1550         (rs6000_expand_vector_set): Ditto.
1551         (rs6000_expand_vector_extract): Ditto.
1552         (rs6000_emit_move): Ditto.
1553         (bdesc_3arg): Ditto.
1554         (bdesc_2arg): Ditto.
1555         (bdesc_1arg): Ditto.
1556         (rs6000_expand_ternop_builtin): Ditto.
1557         (altivec_expand_builtin): Ditto.
1558         (rs6000_expand_unop_builtin): Ditto.
1559         (rs6000_init_builtins): Ditto.
1560         (altivec_init_builtins): Ditto.
1561         (builtin_function_type): Ditto.
1562         (rs6000_common_init_builtins): Ditto.
1563         (rs6000_handle_altivec_attribute); Ditto.
1564         (rs6000_mangle_type): Ditto.
1565         (rs6000_vector_mode_supported_p): Ditto.
1566         (rs6000_mode_dependent_address): Altivec addresses with AND -16
1567         are mode dependent.
1568
1569         * config/rs6000/vsx.md: New file for VSX support.
1570
1571         * config/rs6000/rs6000.h (EASY_VECTOR_MSB): New macro for
1572         identifing values with just the most significant bit set.
1573         (enum rs6000_builtins): Add builtins for VSX.  Add simple math
1574         vectorized builtins.
1575
1576         * config/rs6000/altivec.md (UNSPEC_VRFIP): Delete.
1577         (UNSPEC_VRFIM): Delete.
1578         (splitter for loading up vector with most significant bit): New
1579         splitter for vectorizing copysign.
1580         (altivec_vrfiz): Rename from altivec_fturncv4sf2.  Add support for
1581         vectorizing simple math functions.
1582         (altivec_vrfip): Add support for vectorizing simple math functions.
1583         (altivec_vrfim): Ditto.
1584         (altivec_copysign_v4sf3): New insn for Altivec copysign support.
1585
1586         * config/rs6000/rs6000.md (UNSPEC_BPERM): New constant.
1587         (power7.md, vsx.md): Include for power7 support.
1588         (copysigndf3): Use VSX instructions if -mvsx.
1589         (negdf2_fpr): Ditto.
1590         (absdf2_fpr): Ditto.
1591         (nabsdf2_fpr): Ditto.
1592         (adddf3_fpr): Ditto.
1593         (subdf3_fpr): Ditto.
1594         (muldf3_fpr): Ditto.
1595         (divdf3_fpr): Ditto.
1596         (fix_truncdfdi2_fpr): Ditto.
1597         (cmpdf_internal1): Ditto.
1598         (fred, fred_fpr): Convert into expander/insn to add VSX support.
1599         (btruncdf2, btruncdf2_fpr): Ditto.
1600         (ceildf2, ceildf2_fpr): Ditto.
1601         (floordf2, floordf2_fpr): Ditto.
1602         (floatdidf2, floatdidf2_fpr): Ditto.
1603         (fmadddf4_fpr): Name insn.  Use VSX instructions if -mvsx.
1604         (fmsubdf4_fpr): Ditto.
1605         (fnmadddf4_fpr_1): Ditto.
1606         (fnmadddf4_fpr_2): Ditto.
1607         (fnmsubdf4_fpr_1): Ditto.
1608         (fnmsubdf4_fpr_2): Ditto.
1609         (fixuns_truncdfdi2): Add expander for VSX support.
1610         (fix_truncdfdi2): Ditto.
1611         (fix_truncdfsi2): Ditto.
1612         (ftruncdf2): Ditto.
1613         (btruncsf2): Whitespace.
1614         (movdf_hardfloat32): Add support for VSX registers.
1615         (movdf_softfloat32): Ditto.
1616         (movdf_hardfloat64): Ditto.
1617         (movdf_hardfloat64_mfpgpr): Ditto.
1618         (movdf_softfloat64): Ditto.
1619         (movti splitters): Add check for vector registers supporting
1620         TImode in the future.
1621         (bpermd): Add power7 bpermd instruction.
1622
1623         * config/rs6000/altivec.h (vec_div): Define if VSX.
1624         (vec_mul): Ditto.
1625         (vec_msub): Ditto.
1626         (vec_nmadd): Ditto.
1627         (vec_nearbyint): Ditto.
1628         (vec_rint): Ditto.
1629         (vec_sqrt): Ditto.
1630         (all predicates): Use the generic builtin function, and not the V4SF
1631         specific function so that the predicates will work with VSX's V2DF.
1632         (vec_all_*): Ditto.
1633         (vec_any_*): Ditto.
1634
1635         * doc/extend.texi (PowerPC Altivec/VSX Built-in Functions):
1636         Document new VSX functions and types.
1637
1638         * doc/invoke.texi (PowerPc options): Document -mpopcntd, -mvsx
1639         switches.
1640
1641         * doc/md.texi (PowerPC constraints): Document "wd", "wf", "ws",
1642         "wa", and "j" constraints.  Modify "v" to talk about Altivec
1643         instead of just vector.
1644
1645 2009-07-30  Andrew MacLeod  <amacleod@redhat.com>
1646
1647         PR debug/26475
1648         * tree-into-ssa.c (insert_phi_nodes_for, rewrite_add_phi_arguments): Set
1649         location for phi arguments.
1650         (rewrite_update_phi_arguments): Find locations for reaching defs.
1651         * tree-ssa-threadupdate.c (create_edge_and_update_destination_phis):
1652         Add location to add_phi_arg calls.
1653         * tree-loop-districbution.c (update_phis_for_loop_copy): Add locations.
1654         * tree-ssa-loop-manip.c (create_iv, add_exit_phis_edge,
1655         split_loop_exit_edge, tree_transform_and_unroll_loop): Add locations.
1656         * tree-tailcall.c (add_successor_phi_arg, eliminate_tail_call,
1657         create_tailcall_accumulator, tree_optimize_tail_calls_1): Add locations.
1658         * tree.h (struct phi_arg_d): Add location_t to PHI arguments.
1659         * tree-phinodes.c (make_phi_node): Initialize location.
1660         (resize_phi_node): Initialize location to UNKNOWN_LOCATION.
1661         (add_phi_arg): Add location parameter.
1662         (remove_phi_arg_num): Move location when moving phi argument.
1663         * omp-low.c (expand_parallel_call, expand_omp_for_static_chunk): Set
1664         location.
1665         * tree-vect-loop-manip.c (slpeel_update_phis_for_duplicate_loop,
1666         slpeel_update_phi_nodes_for_guard1,
1667         slpeel_update_phi_nodes_for_guard2,
1668         slpeel_tree_duplicate_loop_to_edge_cfg, set_prologue_iterations,
1669         vect_loop_versioning): Set locations.
1670         * tree-parloops.c (create_phi_for_local_result,
1671         transform_to_exit_first_loop, create_parallel_loop): Add locations.
1672         * gimple-pretty-print.c (dump_gimple_phi): Dump lineno's if present.
1673         * tree-vect-loop.c (get_initial_def_for_induction,
1674         vect_create_epilog_for_reduction, vect_finalize_reduction): Add
1675         locations.
1676         * tree-flow-inline.h (gimple_phi_arg_location): New.  Return locus.
1677         (gimple_phi_arg_location_from_edge): New.  Return locus from an edge.
1678         (gimple_phi_arg_set_location): New.  Set locus.
1679         (gimple_phi_arg_has_location): New.  Check for locus.
1680         (redirect_edge_var_map_location): New.  Return locus from var_map.
1681         * tree-vect-data-refs.c (vect_setup_realignment): Set location.
1682         * tree-ssa-phiopt.c (conditional_replacement): Set locus when
1683         combining PHI arguments.
1684         (cond_store_replacement): Set location.
1685         * cfgexpand.c (gimple_assign_rhs_to_tree): Transfer locus if possible.
1686         * grpahite.c (add_loop_exit_phis, add_guard_exit_phis,
1687         scop_add_exit_phis_edge): Add locations.
1688         * tree-cfgcleanup.c (remove_forwarder_block,
1689         remove_forwarder_block_with_phi): Add locations.
1690         * tree-ssa-pre.c (insert_into_preds_of_block): Add locations.
1691         * tree-predcom.c (initialize_root_vars, initialize_root_vars_lm): Add
1692         locations.
1693         * tree-ssa-dce.c (forward_edge_to_pdom): Add locations.
1694         * tree-ssa.c (redirect_edge_var_map_add, ssa_redirect_edge,
1695         flush_pending_stmts): Add source location.
1696         * lambda-code.c (perfect_nestify): Maintain location stack with argument
1697         stack to preserve locations.
1698         * tree-vect-stmts.c (vectorizable_load): Add location.
1699         * tree-inline.c (copy_phis_for_bb): Copy locus.
1700         (setup_one_parameter): Add call locus to inlined parameter stmts.
1701         (initialize_inlined_parameters): Pass in call location as parameter
1702         assignment locus.
1703         (tree_function_versioning): Pass location to setup_one_parameter.
1704         * tree-ssa-phiprop.c (phiprop_insert_phi): Set locations.
1705         * tree-outof-ssa.c (struct _elim_graph): Add source_location vecs for
1706         copy and edge lists.
1707         (insert_partition_copy_on_edge, insert_value_copy_on_edge,
1708         insert_rtx_to_part_on_edge, insert_part_to_rtx_on_edge): Provide a
1709         locus parameter and override the stmt default if provided.
1710         (new_elim_graph, clear_elim_graph, delete_elim_graph,
1711         elim_graph_add_edge, elim_graph_remove_succ_edge,
1712         FOR_EACH_ELIM_GRAPH_SUCC, FOR_EACH_ELIM_GRAPH_PRED, eliminate_build,
1713         elim_forward, elim_unvisited_predecessor, elim_backward, elim_create,
1714         eliminate_phi):  Add locus info in elimination graph for each edge and
1715         value copy.
1716         (insert_backedge_copies): Copy locus if present.
1717         * tree-flow.h (struct _edge_var_map): Add locus field.
1718         * tree-switch_conversions.c (fix_phi_nodes): Add locations.
1719         * tree-cfg.c (reinstall_phi_args, gimple_make_forwarder_block,
1720         add_phi_args_after_copy_edge, gimple_lv_adjust_loop_header_phi): Add
1721         locations.
1722         * ipa-struct-reorg.c (make_edge_and_fix_phis_of_dest): Add locations.
1723
1724 2009-07-30  Martin Jambor  <mjambor@suse.cz>
1725
1726         PR tree-optimization/40570
1727         * ipa-inline.c (cgraph_decide_inlining): Watch out for dead single
1728         use inlining loops.
1729
1730 2009-07-30  Razya Ladelsky <razya@il.ibm.com>
1731
1732         * ssa-loop-manip.c: Include langhooks.h.
1733         (rewrite_phi_with_iv): New.
1734         (rewrite_all_phi_nodes_with_iv): New.
1735         (canonicalize_loop_ivs): Move here from tree-parloops.c.
1736         Remove reduction_list argument. Use rewrite_all_phi_nodes_with_iv.
1737         * tree-parloops.c (loop_parallel_p): Move out all conditions
1738         except dependency check.
1739         (canonicalize_loop_ivs): Move to tree-ssa-loop-manip.c.
1740         (gen_parallel_loop): Call canonicalize_loop_ivs without
1741         reduction_list argument.
1742         (build_new_reduction): New.
1743         (gather_scalar_reductions): New.
1744         (try_get_loop_niter): New.
1745         (try_create_reduction_list): New.
1746         (parallleize_loops): Change the parallel conditions check.
1747         * tree-flow.h (canonicalize_loop_ivs): Remove one argument.
1748         * Makefile.in (tree-ssa-loop-manip.o): Add langhooks.h dependency.
1749
1750 2009-07-30  Dave Korn  <dave.korn.cygwin@gmail.com>
1751
1752         * opt-functions.awk (opt_args): Allow argument to be enclosed in
1753         curly braces.
1754         * doc/options.texi (Option properties):  Mention new quoting syntax.
1755
1756 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
1757
1758         * config/alpha/alpha.c (alpha_start_function):
1759         Handle VMS_DEBUG_MAIN_POINTER
1760         * config/alpha/vms.h (VMS_DEBUG_MAIN_POINTER): Define new macro.
1761         * doc/invoke.texi: Document -mdebug-main switch.
1762
1763 2009-07-29  Richard Henderson  <rth@redhat.com>
1764
1765         * cgraph.c (cgraph_set_call_stmt_including_clones): Tidy.
1766         (cgraph_create_edge_including_clones): Likewise.
1767         * tree-inline.c (copy_bb): Operate on the correct edges
1768         when updating the callgraph.
1769
1770 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
1771
1772         * config/alpha/vms-cc.c: Deleted.
1773         * config/alpha/vms-ld.c: Deleted.
1774         * config/alpha/t-vms64: Moved to config/vms
1775         * config/alpha/vms-crt0-64.c: Moved to config/vms
1776         * config/alpha/vms-crt0.c: Moved to config/vms
1777         * config/alpha/vms-psxcrt0-64.c: Moved to config/vms
1778         * config/alpha/vms-psxcrt0.c: Moved to config/vms
1779         * config/alpha/xm-vms.h: Moved to config/vms
1780         * config/alpha/x-vms: Moved to config/vms
1781         * config/alpha/t-vms (vcrt0.o, pcrt0.o): Move rules to new file
1782         config/vms/t-vms.
1783         * config/vms/t-vms: Moved here from config/alpha. Alpha specific
1784         parts removed. (STMP_FIXPROTO, STMP_FIXINC, LIMITS_H_TEST): Set.
1785         (version): Set.
1786         * config/vms/t-vms64: Moved here from config/alpha
1787         * config/vms/vms-crt0-64.c: Moved here from config/alpha.
1788         (argc,argv,envp): Enforce 32bit malloc'ing.
1789         * config/vms/vms-psxcrt0-64.c: Likewise.
1790         * config/vms/vms-crt0.c: Moved here from config/alpha.
1791         * config/vms/vms-psxcrt0.c: Likewise.
1792         * config/vms/vms-crtl-64.h: New file.
1793         * config/vms/vms-crtl.h: New file.
1794         * config/vms/vms.opt: New file.
1795         * config/vms/xm-vms64.h: New file.
1796         * config/vms/xm-vms.h: Moved here from config/alpha.
1797         (STANARD_EXEC_PREFIX, STANDARD_STARTFILE_PREFIX, STANDARD_INCLUDE_DIR):
1798         Set.
1799         * config/vms/x-vms: Moved here from config/alpha.
1800         (version, VMS_EXTRA_PARTS): Moved to t-vms.
1801         (vms-ld.o, vms-cc.o): Removed.
1802         (LN, LN_S, USE_COLLECT2, POD2MAN): Set.
1803
1804 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
1805
1806         * dwarf2out.c (add_name_and_src_coords_attributes): Push on the
1807         correct stack (obvious VMS fix).
1808
1809 2009-07-29  Douglas B Rupp  <rupp@gnat.com>
1810
1811         * dwarf2out.c (output_file_names): Output VMS style file name, size,
1812         date, version info if VMS_DEBUGGING_INFO defined.
1813         * vmsdgbout.c (vms_file_stats_name): New functon. VMS style file name,
1814         size, date calculating code moved here.
1815
1816 2009-07-29  Paul Brook  <paul@codesourcery.com>
1817
1818         * config/arm/lib1funcs.asm (clear_cache): Use ARM_FUNC_START and
1819         do_push/do_pop.
1820
1821 2009-07-29  Uros Bizjak  <ubizjak@gmail.com>
1822
1823         PR target/40577
1824         * config/alpha/alpha.c (alpha_expand_unaligned_store): Convert src
1825         to DImode when generating insq_le insn.
1826
1827 2009-07-28  Douglas B Rupp  <rupp@gnat.com>
1828
1829         * dwarf2out.c (DWARF2_INDIRECT_STRING_SUPPORT_MISSING_ON_TARGET):
1830         New macro set for VMS_DEBUGGGING_INFO.
1831         (AT_string_form): Use it.
1832
1833 2009-07-28  DJ Delorie  <dj@redhat.com>
1834
1835         * config/mep/mep.c (vtext_section): New.
1836         (vftext_section): New.
1837         (ftext_section): New.
1838         (mep_select_section): Add support for functions.
1839         (mep_unique_section): Likewise.
1840         (mep_asm_init_sections): Likewise.
1841         (mep_encode_section_info): Remove it from here.
1842
1843         * config/mep/mep.h (USE_SELECT_SECTION_FOR_FUNCTIONS): Define.
1844
1845 2009-07-28  Paolo Bonzini  <bonzinI@gnu.org>
1846
1847         * tree.h (TREE_DEPRECATED): Document it is used for types too.
1848         (TYPE_VECTOR_OPAQUE): Use default_def_flag
1849
1850 2009-07-28  Douglas B Rupp  <rupp@gnat.com>
1851
1852         * dwarf2out.c (output_file_names): Test new macro
1853         DWARF2_DIR_SHOULD_END_WITH_SEPARATOR.
1854         (add_comp_dir_attribute): Likewise.
1855
1856 2009-07-28  Kai Tietz  <kai.tietz@onevision.com>
1857
1858         * config/i386/mingw-w64.h (LINK_SPEC): Add
1859         separating space between commands.
1860
1861 2009-07-28  Jan Hubicka  <jh@suse.cz>
1862
1863         PR tree-optimization/40759
1864         * tree-ssa-dce.c (mark_virtual_phi_result_for_renaming): Mark all uses
1865         for renaming.
1866
1867 2009-07-27  DJ Delorie  <dj@redhat.com>
1868
1869         * config/mep/mep.c (mep_expand_builtin_saveregs): Make sure 64-bit
1870         types are dword-aligned.
1871         (mep_expand_va_start): Likewise.
1872
1873 2009-07-27  Olivier Hainque  <hainque@adacore.com>
1874             Douglas B Rupp  <rupp@gnat.com>
1875
1876         * convert.c (convert_to_pointer): Don't assume the target
1877         pointer type is POINTER_SIZE long. Fetch its precision instead.
1878
1879 2009-07-27  Douglas B Rupp  <rupp@gnat.com>
1880
1881         * system.h (fopen): Undefine if macro.
1882
1883 2009-07-27  Jakub Jelinek  <jakub@redhat.com>
1884
1885         * dwarf2out.c (output_cfi_p): Removed.
1886         (output_cfis): New function.
1887         (output_fde): New function, split from output_call_frame_info.
1888         (output_call_frame_info): Use it.
1889         (dwarf2out_switch_text_section): Use output_cfis.
1890
1891 2009-07-24  Kai Tietz  <kai.tietz@onevision.com>
1892
1893         * config/i386/cygming.h (DWARF2_UNWIND_INFO): Error build when
1894         TARGET_BI_ARCH is specified without enabling SJLJ.
1895         * config/i386/mingw32.h (MD_UNWIND_SUPPORT): Define MD_UNWIND_SUPPORT,
1896         if TARGET_64BIT and TARGET_BI_ARCH aren't defined.
1897
1898 2009-07-26  Mikael Pettersson <mikpe@it.uu.se>
1899
1900         * arm.md (negdi2): Use DImode if forcing a value into a register.
1901
1902 2009-07-26  Ira Rosen  <irar@il.ibm.com>
1903
1904         PR tree-optimization/40801
1905         * tree-vect-stmts.c (vectorizable_call): Get previous copy
1906         of vector operand from the previous copy of vector statement.
1907         Pass the correct definition type value to
1908         vect_get_vec_def_for_stmt_copy().
1909
1910 2009-07-25  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1911
1912         * collect2.c (scan_libraries): Use CONST_CAST2 to perform char ** to
1913         const char ** conversion.
1914
1915 2009-07-25 David Daney <ddaney@caviumnetworks.com>
1916
1917         * system.h (gcc_assert): Invoke __builtin_unreachable() instead of
1918         fancy_abort() if !ENABLE_ASSERT_CHECKING.
1919         (gcc_unreachable): Invoke __builtin_unreachable() if
1920         !ENABLE_ASSERT_CHECKING.
1921
1922 2009-07-25  David Daney  <ddaney@caviumnetworks.com>
1923
1924         PR rtl-optimization/40445
1925         * emit-rtl.c (next_nonnote_insn_bb): New function.
1926         * rtl.h (next_nonnote_insn_bb): Declare new function.
1927         * cfgcleanup.c (try_optimize_cfg): Don't remove an empty block
1928         with no successors that is the successor of the ENTRY_BLOCK.
1929         Continue from the top after removing an empty fallthrough block.
1930         * cfgrtl.c (get_last_bb_insn): Call next_nonnote_insn_bb instead
1931         of next_nonnote_insn.
1932
1933 2009-07-25  David Daney  <ddaney@caviumnetworks.com>
1934
1935         * cfgcleanup.c (old_insns_match_p): Handle the case of empty blocks.
1936
1937 2009-07-25  Martin Jambor  <mjambor@suse.cz>
1938
1939         * c-common.c (c_common_attribute_table): New element for noclone.
1940         (handle_noclone_attribute): New function. Forward-declare.
1941         * tree-inline.c (tree_versionable_function_p): Check for noclone
1942         attribute.
1943         * doc/extend.texi (Labels as Values): Document need for noclone.
1944         (Function Attributes): Document noclone attribute.
1945
1946 2009-07-25  Jakub Jelinek  <jakub@redhat.com>
1947
1948         PR rtl-optimization/34999
1949         * dwarf2out.c (struct dw_fde_struct): Add dw_fde_switch_cfi
1950         and dw_fde_switched_cold_to_hot fields.
1951         (output_cfi_p): New function.
1952         (output_call_frame_info): If fde->dw_fde_switched_sections,
1953         output 2 FDEs instead of one with corrupted header.
1954         (dwarf2out_do_cfi_startproc): New function.
1955         (dwarf2out_begin_prologue): Use it.  Initialize fde->dw_fde_switch_cfi
1956         and fde->dw_fde_switched_cold_to_hot.
1957         (dwarf2out_switch_text_section): Compute
1958         fde->dw_fde_switched_cold_to_hot.  Switch to new text section here.
1959         If dwarf2out_do_cfi_asm, emit .cfi_endproc before it and call
1960         dwarf2out_do_cfi_startproc plus emit again currently active CFI insns.
1961         Otherwise, compute fde->dw_fde_switch_cfi.
1962
1963 2009-07-24  Cary Coutant  <ccoutant@google.com>
1964
1965         * tree-cfg.c (assign_discriminator): Add explicit parentheses.
1966
1967 2009-07-24  Cary Coutant  <ccoutant@google.com>
1968
1969         * cfghooks.c (split_block): Copy discriminator to new block.
1970         * tree-cfg.c (assign_discriminator): Check location of last
1971         instruction in block as well as first.
1972
1973 2009-07-24  Uros Bizjak  <ubizjak@gmail.com>
1974
1975         * config/i386/linux.c: Use fputs or putc instead of fprintf
1976         where appropriate.
1977         * config/i386/gas.h: Ditto.
1978         * config/i386/x86-64.h: Ditto.
1979         * config/i386/att.h: Ditto.
1980
1981 2009-07-24  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
1982
1983         * expmed.c (emit_store_flag): Use a recursive call to optimize the
1984         xor case.
1985
1986 2009-07-24  Martin Jambor  <mjambor@suse.cz>
1987
1988         * ipa-prop.h (struct ipa_node_params): New flag node_enqued.
1989         (ipa_push_func_to_list_1): Declare.
1990         (ipa_push_func_to_list): New function.
1991
1992         * ipa-prop.c (ipa_push_func_to_list_1): New function.
1993         (ipa_init_func_list): Call ipa_push_func_to_list_1.
1994         (ipa_push_func_to_list): Removed.
1995         (ipa_pop_func_from_list): Clear node_enqueued flag.
1996
1997 2009-07-24  Andreas Krebbel  <krebbel1@de.ibm.com>
1998
1999         * config/s390/s390.c (override_options): Default
2000         max-unrolled-insns to 100 for z10 tuning.
2001
2002 2009-07-24  Tobias Grosser  <grosser@fim.uni-passau.de>
2003
2004         * Makefile.in (TREE_DATA_REF_H, tree-vrp.o, tree-cfg.o, tree-if-conv.o
2005         tree-ssa-loop.o, tree-ssa-loop-niter.o, tree-ssa-loop-ivcanon.o,
2006         tree-ssa-loop-prefetch.o, tree-predcom.o, tree-affine.o,
2007         tree-scalar-evolution.o, tree-data-ref.o, tree-vect-loop.o,
2008         tree-vect-data-refs.o, tree-loop-linear.o, tree-loop-distribution.o
2009         tree-parloops.o, tree-pretty-printer.o, fold-const.o, tree-ssa-dce.o,
2010         lambda-code.o, params.o): Cleanup use of SCEV_H and TREE_DATA_REF_H.
2011
2012 2009-07-24  Kai Tietz  <kai.tietz@onevision.com>
2013
2014         * config/i386/mingw-w64.h (STANDARD_INCLUDE_DIR): Remove and
2015         use default set in mingw32.h header.
2016         * config/i386/mingw32.h (STANDARD_INCLUDE_DIR): Use for 32-bit and
2017         64-bit /mingw/include path.
2018         (STANDARD_STARTFILE_PREFIX_1): Use for 32-bit and 64-bit /mingw/lib
2019         path.
2020
2021 2009-07-23  Neil Vachharajani  <nvachhar@google.com>
2022
2023         PR rtl-optimization/40209
2024         * loop-iv.c (iv_analysis_loop_init): Call df_note_add_problem.
2025
2026 2009-07-23  Uros Bizjak  <ubizjak@gmail.com>
2027
2028         * config/i386/i386.c: Use ASM_LONG instead of .long.  Concatenate
2029         ASM_LONG, LPREFIX, MCOUNT_NAME and PROFILE_COUNT_REGISTER strings
2030         with the rest of string where appropriate.  Use fputs or putc
2031         instead of fprintf where appropriate.
2032
2033 2009-07-22  Michael Meissner  <meissner@linux.vnet.ibm.com>
2034             Pat Haugen  <pthaugen@us.ibm.com>
2035             Revital Eres <ERES@il.ibm.com>
2036
2037         * config/rs6000/vector.md: New file.  Move most of the vector
2038         expander support here from altivec.md to allow for the VSX vector
2039         unit in the future.  Add support for secondary_reload patterns.
2040         Rewrite the patterns for vector comparison, and vector comparison
2041         predicate instructions so that the RTL expresses the desired
2042         behavior, instead of using unspec.
2043
2044         * config/rs6000/constraints.md ("f" constraint): Use
2045         rs6000_constraints to hold the precalculated register class.
2046         ("d" constraint): Ditto.
2047         ("wd" constraint): New constraint for VSX.
2048         ("wf" constraint): Ditto.
2049         ("ws" constraint): Ditto.
2050         ("wa" constraint): Ditto.
2051         ("wZ" constraint): Ditto.
2052         ("j" constraint): Ditto.
2053
2054         * config/rs6000/predicates.md (vsx_register_operand): New
2055         predicate for VSX.
2056         (vfloat_operand): New predicate for vector.md.
2057         (vint_operand): Ditto.
2058         (vlogical_operand): Ditto.
2059         (easy_fp_constant): If VSX, 0.0 is an easy constant.
2060         (easy_vector_constant): Add VSX support.
2061         (altivec_indexed_or_indirect_operand): New predicate for
2062         recognizing Altivec style memory references with AND -16.
2063
2064         * config/rs6000/rs6000.c (rs6000_vector_reload): New static global
2065         for vector secondary reload support.
2066         (rs6000_vector_reg_class): Delete, replacing it with
2067         rs6000_constraints.
2068         (rs6000_vsx_reg_class): Ditto.
2069         (rs6000_constraints): New array to hold the register classes of
2070         each of the register constraints that can vary at runtime.
2071         (builtin_mode_to_type): New static array for builtin function type
2072         creation.
2073         (builtin_hash_table): New static hash table for builtin function
2074         type creation.
2075         (TARGET_SECONDARY_RELOAD): Define target hook.
2076         (TARGET_IRA_COVER_CLASSES): Ditto.
2077         (rs6000_hard_regno_nregs_internal): If -mvsx, floating point
2078         registers are 128 bits if VSX memory reference instructions are used.
2079         (rs6000_hard_regno_mode_ok): For VSX, only check if the VSX memory
2080         unit is being used.
2081         (rs6000_debug_vector_unit): Move into rs6000_debug_reg_global.
2082         (rs6000_debug_reg_global): Move -mdebug=reg statements here.
2083         Print several of the scheduling related parameters.
2084         (rs6000_init_hard_regno_mode_ok): Switch to putting constraints in
2085         rs6000_constraints instead of rs6000_vector_reg_class.  Move
2086         -mdebug=reg code to rs6000_debug_reg_global.  Add support for
2087         -mvsx-align-128 debug switch.  Drop testing float_p if VSX or
2088         Altivec.  Add VSX support.  Setup for secondary reload support on
2089         Altivec/VSX registers.
2090         (rs6000_override_options): Make power7 set the scheduling groups
2091         like the power5.  Add support for new debug switches to override
2092         the scheduling defaults.  Temporarily disable -mcpu=power7 from
2093         setting -mvsx.  Add support for debug switches -malways-hint,
2094         -msched-groups, and -malign-branch-targets.
2095         (rs6000_buitlin_conversion): Add support for returning unsigned
2096         vector conversion functions to fix regressions due to stricter
2097         type checking.
2098         (rs6000_builtin_mul_widen_even): Ditto.
2099         (rs6000_builtin_mul_widen_odd): Ditto.
2100         (rs6000_builtin_vec_perm): Ditto.
2101         (rs6000_vec_const_move): On VSX, use xxlxor to clear register.
2102         (rs6000_expand_vector_init): Initial VSX support for using xxlxor
2103         to zero a register.
2104         (rs6000_emit_move): Fixup invalid const symbol_ref+reg that is
2105         generated upstream.
2106         (bdesc_3arg): Add builtins for unsigned types.  Add builtins for
2107         VSX types for bit operations.  Changes to accomidate vector.md.
2108         (bdesc_2arg): Ditto.
2109         (bdesc_1arg): Ditto.
2110         (struct builtin_description_predicates): Rewrite predicate
2111         handling so that RTL describes the operation, instead of passing
2112         the instruction to be used as a string argument.
2113         (bdesc_altivec_preds): Ditto.
2114         (altivec_expand_predicate_builtin): Ditto.
2115         (altivec_expand_builtin): Ditto.
2116         (rs6000_expand_ternop_builtin): Use a switch instead of an if
2117         statement for vsldoi support.
2118         (altivec_expand_ld_builtin): Change to use new names from vector.md.
2119         (altivec_expand_st_builtin): Ditto.
2120         (paired_expand_builtin): Whitespace changes.
2121         (rs6000_init_builtins): Add V2DF/V2DI types.  Initialize the
2122         builtin_mode_to_type table for secondary reload.  Call
2123         builtin_function_type to build random builtin functions.
2124         (altivec_init_builtins): Change to use builtin_function_type to
2125         create builtin function types dynamically as we need them.
2126         (builtin_hash_function): New support for hashing the tree types
2127         for builtin function as we need it, rather than trying to build
2128         all of the trees that we need.  Add initial preliminary VSX support.
2129         (builtin_function_type): Ditto.
2130         (builtin_function_eq): Ditto.
2131         (builtin_hash_struct): Ditto.
2132         (rs6000_init_builtins): Ditto.
2133         (rs6000_common_init_builtins): Ditto.
2134         (altivec_init_builtins): Ditto.
2135         (rs6000_common_init_builtins): Ditto.
2136         (enum reload_reg_type): New enum for simplifing reg classes.
2137         (rs6000_reload_register_type): Simplify register classes into GPR,
2138         Vector, and other registers.  Altivec and VSX addresses in reload.
2139         (rs6000_secondary_reload_inner): Ditto.
2140         (rs6000_ira_cover_classes): New target hook, that returns the
2141         appropriate cover classes, based on -mvsx being used or not.
2142         (rs6000_secondary_reload_class): Add VSX support.
2143         (get_vec_cmp_insn): Delete, rewrite vector conditionals.
2144         (get_vsel_insn): Ditto.
2145         (rs6000_emit_vector_compare): Rewrite vector conditional support
2146         so that where we can, we use RTL operators, instead of blindly use
2147         UNSPEC.
2148         (rs6000_emit_vector_select): Ditto.
2149         (rs6000_emit_vector_cond_expr): Ditto.
2150         (rs6000_emit_minmax): Directly generate min/max under altivec, vsx.
2151         (create_TOC_reference): Add -mdebug=addr support.
2152         (emit_frame_save): VSX loads/stores need register indexed addressing.
2153
2154         * config/rs6000/rs6000.md: Include vector.md.
2155
2156         * config/rs6000/t-rs6000 (MD_INCLUDES): Add vector.md.
2157
2158         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
2159         support for V2DI, V2DF in logical, permute, select operations.
2160
2161         * config/rs6000/rs6000.opt (-mvsx-scalar-double): Add new debug
2162         switch for vsx/power7.
2163         (-mvsx-scalar-memory): Ditto.
2164         (-mvsx-align-128): Ditto.
2165         (-mallow-movmisalign): Ditto.
2166         (-mallow-df-permute): Ditto.
2167         (-msched-groups): Ditto.
2168         (-malways-hint): Ditto.
2169         (-malign-branch-targets): Ditto.
2170
2171         * config/rs6000/rs6000.h (IRA_COVER_CLASSES): Delete, use target
2172         hook instead.
2173         (IRA_COVER_CLASSES_PRE_VSX): Cover classes if not -mvsx.
2174         (IRA_COVER_CLASSES_VSX): Cover classes if -mvsx.
2175         (rs6000_vector_reg_class): Delete.
2176         (rs6000_vsx_reg_class): Ditto.
2177         (enum rs6000_reg_class_enum): New enum for the constraints that
2178         vary based on target switches.
2179         (rs6000_constraints): New array to hold the register class for all
2180         of the register constraints that vary based on the switches used.
2181         (ALTIVEC_BUILTIN_*_UNS): Add unsigned builtin functions.
2182         (enum rs6000_builtins): Add unsigned varients for the builtin
2183         declarations returned by target hooks for expanding multiplies,
2184         select, and permute operations.  Add VSX builtins.
2185         (enum rs6000_builtin_type_index): Add entries for VSX.
2186         (V2DI_type_node): Ditto.
2187         (V2DF_type_node): Ditto.
2188         (unsigned_V2DI_type_node): Ditto.
2189         (bool_long_type_node): Ditto.
2190         (intDI_type_internal_node): Ditto.
2191         (uintDI_type_internal_node): Ditto.
2192         (double_type_internal_node): Ditto.
2193
2194         * config/rs6000/altivec.md (whole file): Move all expanders to
2195         vector.md from altivec.md.  Rename insn matching functions to be
2196         altivec_foo.
2197         (UNSPEC_VCMP*): Delete, rewrite vector comparisons.
2198         (altivec_vcmp*): Ditto.
2199         (UNSPEC_VPERM_UNS): New, add for unsigned types using vperm.
2200         (VM): New iterator for moves that includes the VSX types.
2201         (altivec_vperm_<mode>): Add VSX types.  Add unsigned types.
2202         (altivec_vperm_<mode>_uns): New, for unsigned types.
2203         (altivec_vsel_*): Rewrite vector comparisons and predicate builtins.
2204         (altivec_eq<mode>): Ditto.
2205         (altivec_gt<mode>): Ditto.
2206         (altivec_gtu<mode>): Ditto.
2207         (altivec_eqv4sf): Ditto.
2208         (altivec_gev4sf): Ditto.
2209         (altivec_gtv4sf): Ditto.
2210         (altivec_vcmpbfp_p): Ditto.
2211
2212 2009-07-23  Richard Earnshaw  <rearnsha@arm.com>
2213
2214         * arm.md (split for ior/xor with shift and zero-extend): Cast op3 to
2215         unsigned HWI.
2216
2217 2009-07-23  Uros Bizjak  <ubizjak@gmail.com>
2218
2219         PR target/40832
2220         * config/i386/i386.c (output_387_ffreep): Rewrite to use
2221         ASM_SHORT instead of .word.
2222         * config/i386/i386.md (*tls_global_dynamic_64): Use ASM_SHORT
2223         instead of .word in asm template.
2224
2225 2009-07-22  Vladimir Makarov  <vmakarov@redhat.com>
2226
2227         PR target/37488
2228         * ira-lives.c (bb_has_abnormal_call_pred): New function.
2229         (process_bb_node_lives): Use it.
2230
2231         * ira.c (setup_cover_and_important_classes): Don't setup
2232         ira_important_class_nums.  Add cover classes to the end of
2233         important classes.
2234         (cover_class_order, comp_reg_classes_func, reorder_important_classes):
2235         New.
2236         (find_reg_class_closure): Use reorder_important_classes.
2237
2238         * config/i386/i386.h (IRA_COVER_CLASSES): Remove.
2239
2240         * config/i386/i386.c (i386_ira_cover_classes): New function.
2241         (TARGET_IRA_COVER_CLASSES): Redefine.
2242
2243         * doc/tm.texi (TARGET_IRA_COVER_CLASSES): Add a comment about
2244         importance of order of cover classes in the array.
2245
2246 2009-07-22  Diego Novillo  <dnovillo@google.com>
2247
2248         * tree-pass.h (TDF_EH): Define.
2249         * gimple-pretty-print.c (dump_gimple_stmt): If FLAGS
2250         contains TDF_EH, print the EH region number holding GS.
2251         * tree-dump.c (dump_options): Add "eh".
2252         * doc/invoke.texi: Document it.
2253
2254 2009-07-22  Doug Kwan  <dougkwan@google.com>
2255
2256         * config/arm/arm.md (subdi3) Copy non-reg values to DImode registers.
2257
2258 2009-07-22  Michael Matz  <matz@suse.de>
2259
2260         PR tree-optimization/35229
2261         PR tree-optimization/39300
2262
2263         * tree-ssa-pre.c (includes): Include tree-scalar-evolution.h.
2264         (inhibit_phi_insertion): New function.
2265         (insert_into_preds_of_block): Call it for REFERENCEs.
2266         (init_pre): Initialize and finalize scalar evolutions.
2267         * Makefile.in (tree-ssa-pre.o): Depend on tree-scalar-evolution.h .
2268
2269 2009-07-22  Uros Bizjak  <ubizjak@gmail.com>
2270
2271         * config/i386/predicates.md (zero_extended_scalar_load_operand):
2272         Use CONST_VECTOR_NUNITS to determine number of elements.
2273
2274 2009-07-22  Andreas Krebbel  <krebbel1@de.ibm.com>
2275
2276         * config/s390/constraints.md (ZQ, ZR, ZS, ZT): New constraints.
2277         (U, W): Constraints are now deprecated and will be removed if we
2278         run out of letters.
2279         * config/s390/s390.md (U, W): Replaced with ZQZR, ZSZT throughout
2280         the file.
2281         ("prefetch"): Add the stcmh instruction for prefetching.
2282         * config/s390/s390.c (s390_symref_operand_p): Function moved. No
2283         changes.
2284         (s390_short_displacement): Return always true if compiling for
2285         machines not providing the long displacement facility.
2286         (s390_mem_constraint): Support the new constraint letter Z.
2287         (s390_check_qrst_address): New function.
2288
2289 2009-07-21  DJ Delorie  <dj@redhat.com>
2290
2291         * config/mep/mep.c (mep_legitimize_arg): Leave control registers
2292         alone too.
2293
2294 2009-07-21  Jason Merrill  <jason@redhat.com>
2295
2296         * c-common.c (max_tinst_depth): Increase default to 1024.
2297
2298 2009-07-21  Uros Bizjak  <ubizjak@gmail.com>
2299
2300         * config/i386/sse.md (vec_unpacku_float_hi_v4si): New expander.
2301         (vec_unpacku_float_lo_v4si): Ditto.
2302
2303 2009-07-21  Uros Bizjak  <ubizjak@gmail.com>
2304
2305         PR target/40811
2306         * config/i386/sse.md (sse2_cvtudq2ps): New expander.
2307         (enum ix86_builtins): Add IX86_BUILTIN_CVTUDQ2PS.
2308         (builtin_description): Add __builtin_ia32_cvtudq2ps.
2309         (ix86_vectorize_builtin_conversion): Handle IX86_BUILTIN_CVTUDQ2PS.
2310
2311 2009-07-21  Jakub Jelinek  <jakub@redhat.com>
2312
2313         PR tree-optimization/40813
2314         * tree-inline.c (copy_bb): Regimplify RHS after last stmt, not before
2315         it.
2316
2317 2009-07-21  Kaz Kojima  <kkojima@gcc.gnu.org>
2318
2319         * config/sh/sh.c (sh_gimplify_va_arg_expr): Wrap the result
2320         with a NOP_EXPR if needed.
2321
2322 2009-07-21  Paul Brook <paul@codesourcery.com>
2323
2324         * tree-vectorizer.c (increase_alignment): Handle nested arrays.
2325         Terminate debug dump with newline.
2326
2327 2009-07-20  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
2328
2329         * pa.c (compute_zdepwi_operands): Limit deposit length to 32 - lsb.
2330         Cast "1" to unsigned HOST_WIDE_INT.
2331         (compute_zdepdi_operands): Limit maximum length to 64 bits.  Limit
2332         deposit length to the maximum length - lsb.  Extend length if
2333         HOST_BITS_PER_WIDE_INT is 32.
2334
2335 2009-07-20  Olatunji Ruwase <tjruwase@google.com>
2336
2337         * cgraph.h (constant_pool_htab): New function.
2338         (constant_descriptor_tree): Move from varasm.c.
2339         * varasm.c (constant_pool_htab): New function.
2340         (constant_descriptor_tree): Move to cgraph.h.
2341
2342 2009-07-20  Olatunji Ruwase  <tjruwase@google.com>
2343
2344         * toplev.c: Invoke FINISH_UNIT callbacks before call to finalize().
2345
2346 2009-07-20  Shujing Zhao  <pearly.zhao@oracle.com>
2347
2348         * Makefile.in (TREE_INLINE_H, tree-inline.o, cgraph.o): Remove
2349         $(VARRAY_H).
2350
2351 2009-07-20  Xinliang David Li  <davidxl@google.com>
2352
2353         * dbgcnt.c (dbg_cnt_set_limit_by_name): Add length check.
2354
2355 2009-07-20  Adam Nemet  <anemet@caviumnetworks.com>
2356
2357         * config/mips/mips.md (move_type): Add arith.
2358         (type): Handle arith.
2359         (zero_extendsidi2): Rename this into ...
2360         (*zero_extendsidi2): ... this.  Don't match if ISA_HAS_EXT_INS.
2361         (zero_extendsidi2): New expander.
2362         (*zero_extendsidi2_dext): New pattern.
2363
2364 2009-07-20  Nick Clifton  <nickc@redhat.com>
2365
2366         * config.gcc (mips64-*-*): Add definition of tm_defines in order
2367         to set MIPS_ABI_DEFAULT.
2368         * config/mips/vr.h (MIPS_ABI_DEFAULT): Remove definition.
2369
2370 2009-07-20  Jakub Jelinek  <jakub@redhat.com>
2371
2372         * tree-object-size.c (addr_object_size): Handle unions with
2373         array in it as last field of structs in __bos (, 1) as __bos (, 0).
2374
2375         PR tree-optimization/40792
2376         * tree.c (build_function_type_skip_args): Remove bogus assert.
2377
2378 2009-07-20  Jan Hubicka  <jh@suse.cz>
2379             Martin Jambor  <mjambor@suse.cz>
2380
2381         * cgraph.h (combined_args_to_skip): New field.
2382         * cgraph.c (cgraph_create_virtual_clone): Properly handle
2383         combined_args_to_skip and args_to_skip.
2384         * tree-inline.c (update_clone_info): New function.
2385         (tree_function_versioning): Call update_clone_info.
2386         * cgraphunit.c: (cgraph_materialize_clone): Dump materialized
2387         functions.
2388         (cgraph_materialize_all_clones): More extensive dumping, working
2389         with combined_args_to_skip rather than args_to_skip.
2390
2391 2009-07-20  Ira Rosen  <irar@il.ibm.com>
2392
2393         * tree-vectorizer.h (vectorizable_condition): Add parameters.
2394         * tree-vect-loop.c (vect_is_simple_reduction): Support COND_EXPR.
2395         (get_initial_def_for_reduction): Likewise.
2396         (vectorizable_reduction): Skip the check of first operand in case
2397         of COND_EXPR. Add check that it is outer loop vectorization if
2398         nested cycle was detected. Call vectorizable_condition() for
2399         COND_EXPR. If reduction epilogue cannot be created do not fail for
2400         nested cycles (if it is not double reduction). Assert that there
2401         is only one type in the loop in case of COND_EXPR. Call
2402         vectorizable_condition() to vectorize COND_EXPR.
2403         * tree-vect-stmts.c (vectorizable_condition): Update comment.
2404         Add parameters. Allow nested cycles if called from
2405         vectorizable_reduction(). Use reduction vector variable if provided.
2406         (vect_analyze_stmt): Call vectorizable_reduction() before
2407         vectorizable_condition().
2408         (vect_transform_stmt): Update call to vectorizable_condition().
2409
2410 2009-07-20  Christian Bruel  <christian.bruel@st.com>
2411
2412         * config/sh/sh.opt (-mfmovd): Resurrect and document.
2413         * doc/invoke.texi (-mfmovd): Likewise.
2414         * config/sh/sh.h (TARGET_FMOVD, MASK_FMOVD): Remove default setting.
2415
2416 2009-07-20  Jan Hubicka  <jh@suse.cz>
2417
2418         * tree-ssa-dce.c (remove_dead_phis): Only look for abnormal PHIs
2419         when handling SSA name.
2420
2421 2009-07-19  Jan Hubicka  <jh@suse.cz>
2422
2423         PR tree-optimization/40676
2424         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Do renaming on all
2425         virtual PHIs in empty BBs.
2426
2427 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
2428
2429         * combine.c (make_compound_operation) <SUBREG>: If force_to_mode
2430         re-expanded the compound use gen_lowpart instead to convert to the
2431         desired mode.
2432
2433 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
2434
2435         * combine.c (try_widen_shift_mode): Add COUNT, OUTER_CODE and
2436         OUTER_CONST arguments.
2437         <LSHIFTRT>: Use them to allow widening if the bits shifted in from
2438         the new wider mode will be masked off.
2439         (simplify_shift_const_1): Adjust calls to try_widen_shift_mode.
2440
2441 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
2442
2443         * combine.c (try_widen_shift_mode) <LSHIFTRT>: Allow widening if the
2444         high-order bits are zero.
2445
2446 2009-07-18  Adam Nemet  <anemet@caviumnetworks.com>
2447
2448         * combine.c (simplify_shift_const_1): Split code to determine
2449         shift_mode into ...
2450         (try_widen_shift_mode): ... here.  Allow widening for ASHIFTRT if the
2451         new bits shifted in are identical to the old sign bit.
2452
2453 2009-07-18  Richard Guenther  <rguenther@suse.de>
2454
2455         PR c/40787
2456         * gimplify.c (gimplify_call_expr): Reject code using results from
2457         functions returning void.
2458
2459 2009-07-18  Richard Sandiford  <r.sandiford@uk.ibm.com>
2460
2461         * doc/md.texi: Document the new PowerPC "es" constraint.
2462         Document that "m" can include automodified addresses on this target,
2463         and explain how %U must be used.  Extend the "Q" and "Z" documentation
2464         to suggest "es" as well as "m".
2465         * config/rs6000/constraints.md (es): New memory constraint.
2466         (Q, Z): Update strings to match new documentation.
2467
2468 2009-07-18  Richard Sandiford  <r.sandiford@uk.ibm.com>
2469
2470         * config/rs6000/rs6000.c (rs6000_mode_dependent_address): Allow any
2471         offset from virtual_stack_vars_rtx and arg_pointer_rtx.
2472         * config/rs6000/predicates.md (volatile_mem_operand): Use
2473         offsettable_nonstrict_memref_p.
2474         * config/rs6000/rs6000.md (*floatsidf2_internal): Remove split check.
2475         (*floatunssidf2_internal): Likewise.
2476         (*fix_truncdfsi2_internal): Likewise.
2477         (*fix_trunctfsi2_internal): Likewise.
2478
2479 2009-07-17  Anatoly Sokolov  <aesok@post.ru>
2480
2481         * config/avr/avr-devices.c (avr_mcu_t): Add atmega8u2, atmega16u2 and
2482         atmega32u2 devices.
2483         * config/avr/t-avr (MULTILIB_MATCHES): (Ditto.).
2484
2485 2009-07-17  Richard Guenther  <rguenther@suse.de>
2486
2487         PR c/40401
2488         * tree-pass.h (pass_diagnose_omp_blocks): Declare.
2489         (pass_warn_unused_result): Likewise.
2490         (TODO_set_props): Remove.
2491         * omp-low.c (diagnose_omp_structured_block_errors): Change to
2492         run as a pass.
2493         (pass_diagnose_omp_blocks): Define.
2494         * c-decl.c (pop_file_scope): Do not finalize the CU here.
2495         (c_gimple_diagnostics_recursively): Remove.
2496         (finish_function): Do not call it.
2497         (c_write_global_declarations): Continue after errors.
2498         Finalize the CU here.
2499         * c-gimplify.c (c_genericize): Do not gimplify here.
2500         * c-common.c (c_warn_unused_result): Move ...
2501         * tree-cfg.c (do_warn_unused_result): ... here.
2502         (run_warn_unused_result): New function.
2503         (gate_warn_unused_result): New function.
2504         (pass_warn_unused_result): New pass.
2505         * c-common.h (c_warn_unused_result): Remove.
2506         * flags.h (flag_warn_unused_result): Declare.
2507         * c-opts.c (c_common_init_options): Enable flag_warn_unused_result.
2508         * opts.c (flag_warn_unused_result): Initialize to false.
2509         * toplev.c (compile_file): Add comment.
2510         * omp-low.c (create_omp_child_function): Do not register
2511         the function with the frontend.
2512         (diagnose_omp_structured_block_errors): Prepare to be
2513         called as optimization pass.
2514         (gate_diagnose_omp_blocks): New function.
2515         (pass_diagnose_omp_blocks): New pass.
2516         * cgraph.h (cgraph_optimize): Remove.
2517         (cgraph_analyze_function): Likewise.
2518         * cgraph.c (cgraph_add_new_function): Gimplify C++ thunks.
2519         * cgraphunit.c (cgraph_lower_function): Lower nested functions
2520         before their parents here.
2521         (cgraph_finalize_function): Not here.
2522         (cgraph_analyze_function): Gimplify functions here.
2523         (cgraph_finalize_compilation_unit): Continue after errors.
2524         Optimize the callgraph from here.
2525         (cgraph_optimize): Make static.
2526         * langhooks.c (write_global_declarations): Finalize the CU.
2527         * gimplify.c (gimplify_asm_expr): Do not emit ASMs with errors.
2528         (gimplify_function_tree): Assert we gimplify only once.
2529         Set PROP_gimple_any property.
2530         * tree-nested.c (gimplify_all_functions): New function.
2531         (lower_nested_functions): Gimplify all nested functions.
2532         * gimple.h (diagnose_omp_structured_block_errors): Remove.
2533         * passes.c (init_optimization_passes): Add pass_warn_unused_result
2534         and pass_diagnose_omp_blocks after gimplification.  Do not
2535         set TODO_set_props on all_lowering_passes.
2536         (execute_one_pass): Do not handle TODO_set_props.
2537         * Makefile.in (cgraphunit.o): Add $(TREE_DUMP_H) dependency.
2538         (gimplify.o): Add tree-pass.h dependency.
2539         * tree-inline.c (copy_statement_list): Properly copy STATEMENT_LIST.
2540         (copy_tree_body_r): Properly handle TARGET_EXPR like SAVE_EXPR.
2541         (unsave_r): Likewise.
2542         * c-omp.c (c_finish_omp_atomic): Set DECL_CONTEXT on the
2543         temporary variable.
2544
2545 2009-07-17  Sandra Loosemore  <sandra@codesourcery.com>
2546
2547         * doc/service.texi (Service): Restore previously removed link,
2548         which isn't broken after all.
2549
2550 2009-07-17  Richard Guenther  <rguenther@suse.de>
2551
2552         PR tree-optimization/40321
2553         * tree-ssa-pre.c (add_to_exp_gen): Also add names defined by
2554         PHI nodes to the maximal set.
2555         (make_values_for_phi): Add PHI arguments to the maximal set.
2556         (execute_pre): Dump PHI_GEN and the maximal set.
2557
2558 2009-07-17  Jakub Jelinek  <jakub@redhat.com>
2559
2560         PR c++/40780
2561         * gimplify.c (gimplify_conversion): Don't change non-conversions into
2562         VIEW_CONVERT_EXPR.
2563
2564 2009-07-16  Sandra Loosemore  <sandra@codesourcery.com>
2565
2566         * doc/extend.texi (Nested Functions): Replace broken link with
2567         textual reference.
2568         * doc/service.texi (Service): Remove broken link.
2569
2570 2009-07-16  H.J. Lu  <hongjiu.lu@intel.com>
2571
2572         PR bootstrap/40781
2573         * builtins.c (expand_builtin_memcmp): Use loc instead of
2574         EXPR_LOCATION (exp).
2575         (expand_builtin_strncmp): Likewise.
2576
2577 2009-07-17  Aldy Hernandez  <aldyh@redhat.com>
2578             Manuel López-Ibáñez  <manu@gcc.gnu.org>
2579
2580         PR 40435
2581         * tree-complex.c, tree-loop-distribution.c, tree.c, tree.h,
2582         builtins.c, fold-const.c, omp-low.c, cgraphunit.c, tree-ssa-ccp.c,
2583         tree-ssa-dom.c, gimple-low.c, expr.c, tree-ssa-ifcombine.c,
2584         c-decl.c, stor-layout.c, tree-if-conv.c, c-typeck.c, gimplify.c,
2585         calls.c, tree-sra.c, tree-mudflap.c, tree-ssa-copy.c,
2586         tree-ssa-forwprop.c, c-convert.c, c-omp.c, varasm.c,
2587         tree-inline.c, c-common.c, c-common.h, gimple.c,
2588         tree-switch-conversion.c, gimple.h, tree-cfg.c, c-parser.c,
2589         convert.c: Add location argument to fold_{unary,binary,ternary},
2590         fold_build[123], build_call_expr, build_size_arg,
2591         build_fold_addr_expr, build_call_array, non_lvalue, size_diffop,
2592         fold_build1_initializer, fold_build2_initializer,
2593         fold_build3_initializer, fold_build_call_array,
2594         fold_build_call_array_initializer, fold_single_bit_test,
2595         omit_one_operand, omit_two_operands, invert_truthvalue,
2596         fold_truth_not_expr, build_fold_indirect_ref, fold_indirect_ref,
2597         combine_comparisons, fold_builtin_*, fold_call_expr,
2598         build_range_check, maybe_fold_offset_to_address, round_up,
2599         round_down.
2600
2601 2009-07-16  Jason Merrill  <jason@redhat.com>
2602
2603         PR libstdc++/37907
2604         * c-common.c (c_common_reswords): Add __is_standard_layout
2605         and __is_trivial.
2606         * c-common.h (enum rid): Add RID_IS_STD_LAYOUT and RID_IS_TRIVIAL.
2607         * doc/implement-cxx.texi: New.
2608         * doc/gcc.texi: Include it.
2609
2610 2009-07-16  DJ Delorie  <dj@redhat.com>
2611
2612         * config/m32c/m32c.c (m32c_compare_redundant): Avoid removing
2613         compares that may be indirectly affected by previous instructions.
2614
2615 2009-07-16  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
2616
2617         * builtins.c (do_mpc_arg2): New.
2618         (fold_builtin_2): Fold builtin cpow.
2619         * real.h (HAVE_mpc_pow): New.
2620
2621 2009-07-16  Bingfeng Mei  <bmei@broadcom.com>
2622
2623         * modulo-sched.c (sms_schedule): stage_count <= 1 as correct
2624         comparison to skip unprofitable schedule
2625
2626 2009-07-16  Simon Baldwin  <simonb@google.com>
2627
2628         * gcc.c (option_map): New flag -no-canonical-prefixes.
2629         * (display_help): Print help text for new flag.
2630         * (process_command): Move options translation and language specifics
2631         and handle new flag early.  Use it to set a function pointer to a
2632         prefix builder.  Replace make_relative_prefix calls with calls to
2633         the function pointed to.  Ignore new flag in regular options handling.
2634         * doc/invoke.texi (Overall Options): Documented -no-canonical-prefixes.
2635
2636 2009-07-15  DJ Delorie  <dj@redhat.com>
2637
2638         * config/mep/mep.md (sibcall_internal): Change register to avoid
2639         argument registers.
2640         (sibcall_value_internal): Likewise.
2641
2642 2009-07-15  Eric Botcazou  <ebotcazou@adacore.com>
2643
2644         PR rtl-optimization/40710
2645         * resource.c (mark_target_live_regs): Reset DF problem to LR.
2646
2647 2009-07-15  Adam Nemet  <anemet@caviumnetworks.com>
2648
2649         * config/mips/mips.md (*extenddi_truncate<mode>,
2650         *extendsi_truncate<mode>): Change type attribute to move_type
2651         with shift_shift.  Split out code handling exts from here ...
2652         (*extend<GPR:mode>_truncate<SHORT:mode>_exts): ... to this new
2653         pattern.
2654         (*extendhi_truncateqi): Change type attribute to move_type with
2655         shift_shift.  Split out code handling exts from here ...
2656         (*extendhi_truncateqi_exts): ... to this new pattern.
2657
2658 2009-07-15  Uros Bizjak  <ubizjak@gmail.com>
2659
2660         * config/i386/sse.md (copysign<mode>3): Use "and-not" SSE instruction
2661         instead of "and" with inverted sign bit mask value.  Use
2662         "nonimmediate_operand" for operand 1 and operand 2 predicate.
2663         Allocate registers only for operand 4 and operand 5.
2664
2665 2009-07-15  Jakub Jelinek  <jakub@redhat.com>
2666
2667         PR middle-end/40747
2668         * fold-const.c (fold_cond_expr_with_comparison): When folding
2669         < and <= to MIN, make sure the MIN uses the same type as the
2670         comparison's operands.
2671
2672 2009-07-15  Richard Earnshaw  <rearnsha@arm.com>
2673
2674         * arm.md (ior_xor): New code iterator.
2675         (split for ior/xor with shift and zero-extend): New split pattern.
2676         * arm/predicates.md (subreg_lowpart_operator): New special predicate.
2677
2678 2009-07-15  Richard Guenther  <rguenther@suse.de>
2679
2680         * tree-ssa-structalias.c (make_constraint_from_heapvar): Initialize
2681         offset member.
2682
2683 2009-07-15  Richard Guenther  <rguenther@suse.de>
2684
2685         PR middle-end/40753
2686         * alias.c (ao_ref_from_mem): Reject FUNCTION_DECL and LABEL_DECL bases.
2687
2688 2009-07-15  Maxim Kuvyrkov  <maxim@codesourcery.com>
2689
2690         * config/m68k/linux-unwind.h (m68k_fallback_frame_state): Update to
2691         handle 2.6.30 kernel.
2692
2693 2009-07-15  DJ Delorie  <dj@redhat.com>
2694
2695         * config/mep/mep.md (sibcall_internal): Change register to allow
2696         for 24-bit addresses.
2697         (sibcall_value_internal): Likewise.
2698
2699 2009-07-14  Ghassan Shobaki  <ghassan.shobaki@amd.com>
2700
2701         * doc/invoke.texi: Added descriptions of the  scheduling heuristics
2702         that are enabled/disabled by the flags introduced by a previous patch.
2703
2704 2009-07-14  DJ Delorie  <dj@redhat.com>
2705
2706         * config/mep/mep.md (sibcall_internal): Include non-toggling
2707         non-jmp case.
2708         (sibcall_value_internal): Likewise.
2709
2710 2009-07-14  Taras Glek  <tglek@mozilla.com>
2711             Rafael Espindola  <espindola@google.com>
2712
2713         * doc/sourcebuild.texi: Document install-plugin target.
2714         * configure.ac: Added install-plugin target to language makefiles.
2715         * configure: Regenerate.
2716         * Makefile.in: (install-plugin): Install more headers,
2717         depend on lang.install-plugin.
2718
2719 2009-07-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
2720
2721         * tree-vrp.c (vrp_evaluate_conditional): Mark strings for
2722         translation.
2723
2724 2009-07-14  DJ Delorie  <dj@redhat.com>
2725
2726         * config/mep/mep.c (mep_vliw_jmp_match): New function.
2727         * config/mep/mep-protos.h (mep_vliw_jmp_match): Prototype it.
2728         * config/mep/mep.md (sibcall_internal): Change test from
2729         mep_vliw_mode_match to mep_vliw_jmp_match.
2730         (sibcall_value_internal): Likewise.
2731
2732 2009-07-14  Uros Bizjak  <ubizjak@gmail.com>
2733
2734         * config/i386/sse.md (copysign<mode>3): New expander.
2735         * config/i386/i386-protos.h (ix86_build_signbit_mask): New prototype.
2736         * config/i386/i386.c (ix86_build_signbit_mask): Make public.
2737         Use ix86_build_const_vector.
2738         (enum ix86_builtins): Add IX86_BUILTIN_CPYSGNPS and
2739         IX86_BUILTIN_CPYSGNPD.
2740         (builtin_description): Add __builtin_ia32_copysignps and
2741         __builtin_ia32_copysignpd.
2742         (ix86_builtin_vectorized_function): Handle BUILT_IN_COPYSIGN
2743         and BUILT_IN_COPYSIGNF.
2744
2745 2009-07-13  Jason Merrill  <jason@redhat.com>
2746
2747         * builtins.c (can_trust_pointer_alignment): New fn.
2748         (get_pointer_alignment): Factor it out from here.
2749         * tree.h: Declare it.
2750
2751 2009-07-14  David Edelsohn  <edelsohn@gnu.org>
2752
2753         * config/rs6000/predicates.md (offsettable_mem_operand): Test
2754         RTX_AUTOINC class.
2755
2756 2009-07-14  Dodji Seketeli  <dodji@redhat.com>
2757
2758         PR debug/40705
2759         PR c++/403057
2760         * dwarf2.out.c (gen_type_die_with_usage): Added comment.
2761
2762 2009-07-14  Richard Guenther  <rguenther@suse.de>
2763             Andrey Belevantsev <abel@ispras.ru>
2764
2765         PR middle-end/40745
2766         * cfgexpand.c (partition_stack_vars): Do not bother to update
2767         alias information when not optimizing.
2768
2769 2009-07-14  Richard Guenther  <rguenther@suse.de>
2770             Andrey Belevantsev <abel@ispras.ru>
2771
2772         * tree-ssa-alias.h (refs_may_alias_p_1): Declare.
2773         (pt_solution_set): Likewise.
2774         * tree-ssa-alias.c (refs_may_alias_p_1): Export.
2775         * tree-ssa-structalias.c (pt_solution_set): New function.
2776         * final.c (rest_of_clean_state): Free SSA data structures.
2777         * print-rtl.c (print_decl_name): Remove.
2778         (print_mem_expr): Implement in terms of print_generic_expr.
2779         * alias.c (ao_ref_from_mem): New function.
2780         (rtx_refs_may_alias_p): Likewise.
2781         (true_dependence): Query alias-export info.
2782         (canon_true_dependence): Likewise.
2783         (write_dependence_p): Likewise.
2784         * tree-dfa.c (get_ref_base_and_extent): For void types leave
2785         size unknown.
2786         * emit-rtl.c (component_ref_for_mem_expr): Remove.
2787         (mem_expr_equal_p): Use operand_equal_p.
2788         (set_mem_attributes_minus_bitpos): Do not use
2789         component_ref_for_mem_expr.
2790         * cfgexpand.c (add_partitioned_vars_to_ptset): New function.
2791         (update_alias_info_with_stack_vars): Likewise.
2792         (partition_stack_vars): Call update_alias_info_with_stack_vars.
2793         * tree-ssa.c (delete_tree_ssa): Do not release SSA names
2794         explicitly nor clear stmt operands.
2795         Free the decl-to-pointer map.
2796         * tree-optimize.c (execute_free_datastructures): Do not free
2797         SSA data structures here.
2798         * tree-flow.h (struct gimple_df): Add decls_to_pointers member.
2799         * Makefile.in (emit-rtl.o): Add pointer-set.h dependency.
2800         (alias.o): Add tree-ssa-alias.h, pointer-set.h and $(TREE_FLOW_H)
2801         dependencies.
2802         (print-rtl.o): Add $(DIAGNOSTIC_H) dependency.
2803
2804 2009-07-13  DJ Delorie  <dj@redhat.com>
2805
2806         * config/mep/mep.h (CC1_SPEC): Tweak parameters to trigger
2807         unrolling at the right iteration count.
2808
2809         * config/mep/mep.c (mep_expand_prologue): Fix frame pointer
2810         calculations.
2811
2812 2009-07-13  Ghassan Shobaki  <ghassan.shobaki@amd.com>
2813
2814         * haifa-sched.c (rank_for_schedule): Introduced flags to
2815         enable/disable individual scheduling heuristics.
2816         * common.opt: Introduced flags to enable/disable individual
2817         heuristics in the scheduler.
2818         * doc/invoke.texi: Introduced flags to enable/disable individual
2819         heuristics in the scheduler.
2820
2821 2009-07-13  Kai Tietz  <kai.tietz@onevision.com>
2822
2823         * config/i386/t-gthr-win32 (LIB2FUNCS_EXTRA): Remove file
2824         config/i386/mingw-tls.c.
2825         * config/i386/mingw-tls.c: Removed.
2826
2827 2009-07-13  Ira Rosen  <irar@il.ibm.com>
2828
2829         * tree-vect-loop.c (get_initial_def_for_reduction): Ensure that the
2830         checks access only relevant statements.
2831         (vectorizable_reduction): Likewise.
2832
2833 2009-07-12  Kai Tietz  <kai.tietz@onevision.com>
2834
2835         * config/i386/cygming.h (TARGET_OS_CPP_BUILTINS): Define _X86_
2836         just for 32-bit case.
2837
2838 2009-07-12  Jan Hubicka  <jh@suse.cz>
2839
2840         PR tree-optimization/40585
2841         * except.c (expand_resx_expr): When there already is resume
2842         instruction, produce linked list.
2843         (build_post_landing_pads): Assert that resume is empty.
2844         (connect_post_landing_pads): Handle resume lists.
2845         (dump_eh_tree): Dump resume list.
2846
2847 2009-07-12  Ira Rosen  <irar@il.ibm.com>
2848
2849         * tree-parloops.c (loop_parallel_p): Call vect_is_simple_reduction
2850         with additional argument.
2851         * tree-vectorizer.h (enum vect_def_type): Add
2852         vect_double_reduction_def.
2853         (vect_is_simple_reduction): Add argument.
2854         * tree-vect-loop.c (vect_determine_vectorization_factor): Fix
2855         indentation.
2856         (vect_analyze_scalar_cycles_1): Detect double reduction. Call
2857         vect_is_simple_reduction with additional argument.
2858         (vect_analyze_loop_operations): Handle exit phi nodes in case of
2859         double reduction.
2860         (reduction_code_for_scalar_code): Handle additional codes by
2861         returning ERROR_MARK for them. Fix comment and indentation.
2862         (vect_is_simple_reduction): Fix comment, add argument to specify
2863         double reduction. Detect double reduction.
2864         (get_initial_def_for_induction): Fix indentation.
2865         (get_initial_def_for_reduction): Fix comment and indentation.
2866         Handle double reduction. Create initial definitions that do not
2867         require adjustment if ADJUSTMENT_DEF is NULL. Handle additional cases.
2868         (vect_create_epilog_for_reduction): Fix comment, add argument to
2869         handle double reduction. Use PLUS_EXPR in case of MINUS_EXPR in
2870         epilogue result extraction. Create double reduction phi node and
2871         replace relevant uses.
2872         (vectorizable_reduction): Call vect_is_simple_reduction with
2873         additional argument. Fix indentation. Update epilogue code treatment
2874         according to the changes in reduction_code_for_scalar_code. Check
2875         for double reduction. Call vect_create_epilog_for_reduction with
2876         additional argument.
2877         * tree-vect-stmts.c (process_use): Handle double reduction, update
2878         documentation.
2879         (vect_mark_stmts_to_be_vectorized): Handle double reduction.
2880         (vect_get_vec_def_for_operand): Likewise.
2881
2882 2009-07-12  Danny Smith  <dansmister@gmail.com>
2883
2884         * config/i386/winnt.c (i386_pe_determine_dllexport_p): Don't
2885         dllexport if !TREE_PUBLIC.
2886         (i386_pe_maybe_record_exported_symbol): Assert TREE_PUBLIC.
2887
2888 2009-07-11  Anatoly Sokolov  <aesok@post.ru>
2889
2890         * config/avr/avr.h (TARGET_CPU_CPP_BUILTINS): Redefine.
2891         (avr_extra_arch_macro) Remove declatation.
2892         * config/avr/avr.c (avr_cpu_cpp_builtins): New function.
2893         (avr_extra_arch_macro) Declare as static.
2894         * config/avr/avr-protos.h (avr_cpu_cpp_builtins): Dclare.
2895
2896 2009-07-11  Jan Hubicka  <jh@suse.cz>
2897
2898         PR middle-end/48388
2899         * except.c (can_be_reached_by_runtime): Test for NULL aka bitmap.
2900
2901 2009-07-11  Jakub Jelinek  <jakub@redhat.com>
2902
2903         PR debug/40713
2904         * dwarf2out.c (dw_fde_struct): Add in_std_section and
2905         cold_in_std_section bits.
2906         (dwarf2out_begin_prologue): Initialize them.
2907         (dwarf2out_finish): Don't emit FDE range into .debug_ranges
2908         if already covered by text_section or cold_text_section range.
2909
2910         PR rtl-optimization/40667
2911         * defaults.h (MINIMUM_ALIGNMENT): Define if not defined.
2912         * doc/tm.texi (MINIMUM_ALIGNMENT): Document it.
2913         * config/i386/i386.h (MINIMUM_ALIGNMENT): Define.
2914         * config/i386/i386.c (ix86_minimum_alignment): New function.
2915         * config/i386/i386-protos.h (ix86_minimum_alignment): New prototype.
2916         * cfgexpand.c (expand_one_var): Use MINIMIM_ALIGNMENT.
2917         * emit-rtl.c (gen_reg_rtx): Likewise.
2918         * function.c (assign_parms): Likewise.  If nominal_type needs
2919         bigger alignment than FUNCTION_ARG_BOUNDARY, use its alignment
2920         rather than passed_type's alignment.
2921
2922         PR target/40668
2923         * function.c (assign_parm_setup_stack): Adjust
2924         MEM_OFFSET (data->stack_parm) if promoted_mode is different
2925         from nominal_mode on big endian.
2926
2927 2009-07-11  Paolo Bonzini  <bonzini@gnu.org>
2928
2929         * expmed.c (emit_store_flag_1): Fix choice of zero vs. sign extension.
2930
2931 2009-07-10  DJ Delorie  <dj@redhat.com>
2932
2933         * config/mep/mep.c (mep_can_inline_p): Correct logic, and simplify.
2934
2935 2009-07-10  Mark Mitchell  <mark@codesourcery.com>
2936
2937         * config/arm/thumb2.md (thumb2_cbz): Correct computation of length
2938         attribute.
2939         (thumb2_cbnz): Likewise.
2940
2941 2009-07-10  David Daney  <ddaney@caviumnetworks.com>
2942
2943         PR target/39079
2944         * config.gcc (supported_defaults): Add synci.
2945         (with_synci): Add validation.
2946         (all_defaults): Add synci.
2947         * config/mips/mips.md (clear_cache): Use TARGET_SYNCI instead of
2948         ISA_HAS_SYNCI.
2949         (synci): Same.
2950         * config/mips/mips.opt (msynci): New option.
2951         * config/mips/mips.c (mips_override_options): Warn on use of
2952         -msynci for targets that do now support it.
2953         * gcc/config/mips/mips.h (OPTION_DEFAULT_SPECS): Add a default for
2954         msynci.
2955         * gcc/doc/invoke.texi (-msynci): Document the new option.
2956         * doc/install.texi (--with-synci): Document the new option.
2957
2958 2009-07-10  Richard Guenther  <rguenther@suse.de>
2959
2960         PR tree-optimization/40496
2961         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Create
2962         the PHI result with a compatible type.
2963
2964 2009-07-10  Manuel López-Ibáñez  <manu@gcc.gnu.org>
2965
2966         PR 25509
2967         PR 40614
2968         * c.opt (Wunused-result): New.
2969         * doc/invoke.texi: Document it.
2970         * c-common.c (c_warn_unused_result): Use it.
2971
2972 2009-07-09  DJ Delorie  <dj@redhat.com>
2973
2974         * targhooks.c (default_target_can_inline_p): Rename from
2975         default_target_option_can_inline_p.
2976         * targhooks.h (default_target_can_inline_p): Likewise.
2977         * target-def.h (TARGET_CAN_INLINE_P): Rename from
2978         TARGET_OPTION_CAN_INLINE_P.
2979         * config/i386/i386.c (TARGET_CAN_INLINE_P): Likewise.
2980         * config/mep/mep.c (TARGET_CAN_INLINE_P): Likewise.
2981         (mep_target_can_inline_p): Rename from
2982         mep_target_option_can_inline_p.
2983
2984         PR target/40626
2985         * config/mep/mep.h (FUNCTION_ARG_REGNO_P): Add coprocessor
2986         registers used to pass vectors.
2987
2988         * config/mep/mep.c (mep_option_can_inline_p): Remove error call.
2989
2990 2009-07-09  Tom Tromey  <tromey@redhat.com>
2991
2992         * unwind-dw2-fde-darwin.c: Include dwarf2.h.
2993         * config/mmix/mmix.c: Include dwarf2.h.
2994         * config/rs6000/darwin-fallback.c: Include dwarf2.h.
2995         * config/xtensa/unwind-dw2-xtensa.c: Include dwarf2.h.
2996         * config/sh/sh.c: Include dwarf2.h.
2997         * config/i386/i386.c: Include dwarf2.h.
2998         * Makefile.in (DWARF2_H): Remove 'elf'.
2999         * except.c: Include dwarf2.h.
3000         * unwind-dw2.c: Include dwarf2.h.
3001         * dwarf2out.c: Include dwarf2.h.
3002         * unwind-dw2-fde-glibc.c: Include dwarf2.h.
3003         * unwind-dw2-fde.c: Include dwarf2.h.
3004         * dwarf2asm.c: Include dwarf2.h.
3005
3006 2009-07-09  Maxim Kuvyrkov  <maxim@codesourcery.com>
3007
3008         * haifa-sched.c (insn_finishes_cycle_p): New static function.
3009         (max_issue): Use it.
3010         * sched-int.h (struct sched_info: insn_finishes_block_p): New
3011         scheduler hook.
3012         * sched-rgn.c (rgn_insn_finishes_block_p): Implement it.
3013         (region_sched_info): Update.
3014         * sched-ebb.c (ebb_sched_info): Update.
3015         * modulo-sched.c (sms_sched_info): Update.
3016         * sel-sched-ir.c (sched_sel_haifa_sched_info): Update.
3017
3018 2009-07-09  Maxim Kuvyrkov  <maxim@codesourcery.com>
3019
3020         * varasm.c (build_constant_desc): Don't share RTL in pool entries.
3021
3022 2009-07-09  Basile Starynkevitch  <basile@starynkevitch.net>
3023
3024         * plugin.c (try_init_one_plugin): passes RTLD_GLOBAL to dlopen.
3025
3026 2009-07-09  Jakub Jelinek  <jakub@redhat.com>
3027
3028         PR middle-end/40692
3029         * fold-const.c (fold_cond_expr_with_comparison): Don't replace
3030         arg1 with arg01 if arg1 is already INTEGER_CST.
3031
3032 2009-07-08  Adam Nemet  <anemet@caviumnetworks.com>
3033
3034         * simplify-rtx.c (simplify_binary_operation_1) <AND>:
3035         Transform (and (truncate)) into (truncate (and)).
3036
3037 2009-07-08  Adam Nemet  <anemet@caviumnetworks.com>
3038
3039         * combine.c (make_extraction): Check TRULY_NOOP_TRUNCATION before
3040         creating LHS paradoxical subregs.  Fix surrounding returns to
3041         use NULL_RTX rather than 0.
3042
3043 2009-07-08  DJ Delorie  <dj@redhat.com>
3044
3045         * config/mep/mep.c: (mep_option_can_inline_p): New.
3046         (TARGET_OPTION_CAN_INLINE_P): Define.
3047
3048 2009-07-08  Mark Wielaard  <mjw@redhat.com>
3049
3050         PR debug/40659
3051         * dwarf2out.c (add_data_member_location_attribute): When we have
3052         only a constant offset don't emit a new location description using
3053         DW_OP_plus_uconst, but just add the constant with add_AT_int, when
3054         dwarf_version > 2.
3055
3056 2009-07-08  Richard Henderson  <rth@redhat.com>
3057
3058         PR target/38900
3059         * config/i386/i386.h (CONDITIONAL_REGISTER_USAGE): Move to i386.c.
3060         (enum reg_class): Add CLOBBERED_REGS.
3061         (REG_CLASS_NAMES, REG_CLASS_CONTENTS): Likewise.
3062         * config/i386/i386.c (ix86_conditional_register_usage): Moved
3063         from CONDITIONAL_REGISTER_USAGE; build CLOBBERED_REGS for 64-bit.
3064         (ix86_function_ok_for_sibcall): Tidy.  Disallow MS->SYSV sibcalls.
3065         (ix86_expand_call): Use sibcall_insn_operand when needed.  Don't
3066         force 64-bit sibcalls into R11.
3067         * config/i386/constraints.md (U): New constraint.
3068         * config/i386/i386.md (sibcall_1, sibcall_value_1): Use it.
3069         (sibcall_1_rex64, sibcall_value_1_rex64): Likewise.
3070         (sibcall_1_rex64_v, sibcall_value_1_rex64_v): Remove.
3071
3072 2009-07-08  Shujing Zhao  <pearly.zhao@oracle.com>
3073
3074         * basic-block.h (dump_regset, debug_regset): Remove duplicate
3075         prototypes.
3076         * c-objc-common.h (c_initialize_diagnostics): Ditto.
3077         * ebitmap.h (dump_ebitmap): Ditto.
3078         * optabs.h (optab_libfunc): Ditto.
3079         * tree.h (tree_expr_nonzero_warnv_p): Ditto.
3080         * tree-flow.h (vect_can_force_dr_alignment_p,
3081         get_vectype_for_scalar_type): Ditto.
3082         (vectorize_loops): Move prototype to ...
3083         * tree-vectorizer.h: ... here. Also, adjust comment.
3084         (vect_set_verbosity_level): Remove duplicate prototype.
3085         * tree-ssa-loop.c: Include tree-vectorizer.h.
3086         * Makefile.in (tree-ssa-loop.o): Depend on tree-vectorizer.h.
3087
3088 2009-07-08  Nick Clifton  <nickc@redhat.com>
3089
3090         * config/i386/unix.h (ASM_COMMENT_START): Add a space after the
3091         forward slash.
3092
3093 2009-07-08  DJ Delorie  <dj@redhat.com>
3094
3095         * config/mep/mep-ivc2.cpu (cpmovtocsar0_C3, cpmovtocsar1_C3,
3096         cpmovtocc_C3, cpmovtocsar0_P0S_P1, cpmovtocsar1_P0S_P1,
3097         cpmovtocc_P0S_P1): Mark volatile.  Note which registers are
3098         written to.
3099         * config/mep/intrinsics.md: Regenerated.
3100         * config/mep/mep.c (mep_interrupt_saved_reg): Save IVC2 control
3101         registers when asm() or calls are detected.
3102
3103 2009-07-08  Manuel López-Ibáñez  <manu@gcc.gnu.org>
3104
3105         PR c++/31246
3106         * gimplify.c (gimplify_expr): Propagate no_warning flag when
3107         gimplifying.
3108         * gimple (gimple_build_call_from_tree): Likewise.
3109         * tree-cfg.c (remove_useless_stmts_warn_notreached): Check
3110         no_warning flag before warning.
3111
3112 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
3113
3114         * tree.c (set_expr_locus): Remove.
3115         * tree.h (EXPR_LOCUS,SET_EXPR_LOCUS,set_expr_locus): Remove.
3116         * c-typeck.c (c_finish_stmt_expr):  Replace EXPR_LOCUS by
3117         EXPR_LOCATION.
3118         * gimplify.c (internal_get_tmp_var): Likewise.
3119         (gimplify_call_expr): Likewise.
3120         (gimplify_one_sizepos): Likewise.
3121
3122 2009-07-07  Eric Botcazou  <ebotcazou@adacore.com>
3123
3124         PR debug/40666
3125         * dbxout.c (dbxout_symbol) <PARM_DECL>: Deal with parameters pointing
3126         to variables for debugging purposes.
3127
3128 2009-06-23  Mark Loeser  <mark@halcy0n.com>
3129
3130         PR build/40010
3131         * Makefile.in (gcc.pod): Depend on gcc-vers.texi.
3132
3133 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
3134
3135         * pretty-print.c (pp_base_format): Remove %J.
3136         * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
3137         gcc_cxxdiag_char_table): Likewise.
3138         (init_dynamic_diag_info): Likewise.
3139
3140 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
3141
3142         * pretty-print.c (pp_base_format): Remove %H.
3143         * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
3144         gcc_cxxdiag_char_table): Likewise.
3145         (init_dynamic_diag_info): Likewise.
3146         * config/mep/mep.c (mep_select_section): Likewise.
3147
3148 2009-07-07  Duncan Sands  <baldrick@free.fr>
3149
3150         * final.c (pass_clean_state): Give the pass a name.
3151         * passes.c (pass_rest_of_compilation): Likewise.
3152         * tree-optimize.c (pass_all_optimizations): Likewise.
3153
3154 2009-07-07  H.J. Lu  <hongjiu.lu@intel.com>
3155
3156         * config/ia64/ia64.c (ia64_handle_model_attribute): Remove
3157         an extra 'decl' for error_at.
3158
3159 2009-07-07  Jakub Jelinek  <jakub@redhat.com>
3160
3161         PR middle-end/40669
3162         * tree-tailcall.c (adjust_return_value_with_ops,
3163         create_tailcall_accumulator): Set DECL_GIMPLE_REG_P on the temporary
3164         if it has complex or vector type.
3165
3166 2009-07-07  Olivier Hainque  <hainque@adacore.com>
3167
3168         * config/alpha/t-osf4 (SHLIB_LINK): Do not hide the dummy weak
3169         pthread symbols.
3170
3171 2009-07-07  Basile Starynkevitch  <basile@starynkevitch.net>
3172
3173         * Makefile.in: added more lists of includes to PLUGIN_HEADERS.
3174
3175 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
3176
3177         * cgraphunit.c: Replace %J by an explicit location.  Update all calls.
3178         * c-decl.c: Likewise.
3179         * function.c: Likewise.
3180         * varasm.c: Likewise.
3181         * tree-ssa.c: Likewise.
3182         * c-common.c: Likewise.
3183         * tree-cfg.c: Likewise.
3184         * config/spu/spu.c: Likewise.
3185         * config/ia64/ia64.c: Likewise.
3186         * config/v850/v850.c: Likewise.
3187
3188 2009-07-06  DJ Delorie  <dj@redhat.com>
3189
3190         * config/mep/mep-core.cpu (fsft, ssarb): Mark as VOLATILE.
3191         * config/mep/mep-ivc2.cpu (many): Add VOLATILE to more insns that make
3192         unspecified accesses to control registers.
3193         * config/mep/intrinsics.md: Regenerate.
3194         * config/mep/intrinsics.h: Regenerate.
3195         * config/mep/mep-intrin.h: Regenerate.
3196
3197 2009-07-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
3198
3199         * c-lex.c: Replace %H by an explicit location. Update all calls.
3200         * c-common.c: Likewise.
3201         * c-decl.c: Likewise.
3202         * c-typeck.c: Likewise.
3203         * fold-const.c: Likewise.
3204         * gimplify.c: Likewise.
3205         * stmt.c: Likewise.
3206         * tree-cfg.c: Likewise.
3207         * tree-ssa-loop-niter.c: Likewise.
3208         * tree-vrp.c: Likewise.
3209         * value-prof.c: Likewise.
3210
3211 2009-07-06  Diego Novillo  <dnovillo@google.com>
3212
3213         * tree-dfa.c (dump_variable): Write DECL_INITIAL for VAR
3214         if it has one.  Handle cases where VAR does not have an
3215         annotation or cfun is NULL.
3216
3217 2009-07-06  Diego Novillo  <dnovillo@google.com>
3218
3219         * tree.c: Include debug.h.
3220         (initialize_tree_contains_struct): New.
3221         (init_ttree): Call it.
3222         (tree_node_structure_for_code): Factor out of ...
3223         (tree_node_structure): ... here.
3224         * treestruct.def (TS_PHI_NODE): Remove.
3225         (TS_GIMPLE_STATEMENT): Remove.
3226
3227 2009-07-06  Diego Novillo  <dnovillo@google.com>
3228
3229         * tree-pretty-print.c (dump_generic_node): Protect against NULL op0.
3230         (debug_tree_chain): Handle cycles.
3231
3232 2009-07-06  Nick Clifton  <nickc@redhat.com>
3233             DJ Delorie  <dj@redhat.com>
3234
3235         * config.sh/lib1funcs.h (FMOVD_WORKS): Only define if
3236         __FMOVD_ENABLED__ is defined.
3237         * config/sh/sh.h
3238         (TARGET_FMOVD): Provide a default definition.
3239         (MASK_FMOVD): Likewise.
3240         (TARGET_CPU_CPP_BUILTINS): Define
3241         __FMOVD_ENABLED__ if TARGET_FMOVD is true.
3242         * config/sh/sh.md (movdf_i4): For alternative 0 use either one or
3243         two fmov instructions depending upon whether TARGET_FMOVD is enabled.
3244         (split for DF load from memory into register): Also handle
3245         MEMs which consist of REG+DISP addressing.
3246         (split for DF store from register to memory): Likewise.
3247         (movsf_ie): Always use single fp_mode.
3248         * config/sh/sh.c (sh_override_options): Do not automatically
3249         enable TARGET_MOVD for the SH2A when supporting doubles - leave
3250         that to the -mfmovd command line switch.
3251         (broken_move): Do not restrict fldi test to only the SH4 and SH4A.
3252         (fldi_ok): Always allow.
3253         * config/sh/sh.opt (mfmovd): Remove this switch.
3254         * doc/invoke.texi (-mfmovd): Remove documentation of this switch.
3255
3256 2009-07-06  J"orn Rennecke  <joern.rennecke@arc.com>
3257             Kaz Kojima  <kkojima@gcc.gnu.org>
3258
3259         PR rtl-optimization/30807
3260         * postreload.c (reload_combine): For every new use of REG_SUM,
3261         record the use of BASE.
3262
3263 2009-07-06  Jan Hubicka  <jh@suse.cz>
3264
3265         * params.def: Revert my accidental commit at 2009-06-30.
3266
3267 2009-07-04  Ian Lance Taylor  <iant@google.com>
3268
3269         PR target/40636
3270         * config/i386/msformat-c.c (mingw_format_attributes): Declare as
3271         EXPORTED_CONST.
3272         (mingw_format_attribute_overrides): Likewise.
3273
3274 2009-07-04  Jakub Jelinek  <jakub@redhat.com>
3275
3276         PR debug/40596
3277         * dwarf2out.c (based_loc_descr): For crtl->stack_realign_tried
3278         don't check cfa.reg.  Instead of cfa.indirect use
3279         fde && fde->drap_reg != INVALID_REGNUM test.
3280
3281 2009-07-04  Eric Botcazou  <ebotcazou@adacore.com>
3282
3283         * postreload.c (reload_combine): Replace CONST_REG with INDEX_REG.
3284
3285 2009-07-03  Vladimir Makarov  <vmakarov@redhat.com>
3286
3287         PR target/40587
3288         * ira.c (build_insn_chain): Use DF_LR_OUT instead of df_get_live_out.
3289
3290 2009-07-03  Richard Guenther  <rguenther@suse.de>
3291
3292         PR tree-optimization/40640
3293         * tree-switch-conversion.c (build_arrays): Perform arithmetic
3294         in original type.
3295
3296 2009-07-03  Jan Hubicka  <jh@suse.cz>
3297
3298         * ipa-inline.c (cgraph_decide_inlining_incrementally): When optimizing
3299         for size, reduce amount of inlining.
3300
3301 2009-07-03  Richard Guenther  <rguenther@suse.de>
3302
3303         PR middle-end/34163
3304         * tree-chrec.c (chrec_convert_1): Fold (T2)(t +- x) to (T2)t +- (T2)x
3305         if t +- x is known to not overflow and the conversion widens the
3306         operation.
3307         * Makefile.in (tree-chrec.o): Add $(FLAGS_H) dependency.
3308
3309 2009-07-03  Jan Hubicka  <jh@suse.cz>
3310
3311         * ipa-pure-const.c (analyze): Update loop optimizer init.
3312         * tree-ssa-loop-iv-canon.c (empty_loop_p, remove_empty_loop,
3313         try_remove_empty_loop, remove_empty_loops): Remove.
3314         * tree-ssa-loop.c (tree_ssa_empty_loop, pass_empty_loop): Remove.
3315         * tree-ssa-dce.c (find_obviously_necessary_stmts): Use finiteness info
3316         to mark regular loops as neccesary.
3317         (degenerate_phi_p): New function.
3318         (propagate_necessity, remove_dead_phis): Use it.
3319         (forward_edge_to_pdom): Likewise.
3320         (eliminate_unnecessary_stmts): Take care to remove uses of results of
3321         virtual PHI nodes that became unreachable.
3322         (perform_tree_ssa_dce): Initialize/deinitialize loop optimizer.
3323         * tree-flow.h (remove_empty_loops): Remove.
3324         * passes.c (init_optimization_passes): Remove.
3325
3326 2009-07-03  Uros Bizjak  <ubizjak@gmail.com>
3327
3328         * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Use
3329         can_create_pseudo_p.
3330         (*fix_trunc<mode>_i387_1): Ditto.
3331         (*floathi<mode>2_1): Ditto.
3332         (*float<SSEMODEI24:mode><X87MODEF:mode>2_1): Ditto.
3333         (*fistdi2_1): Ditto.
3334         (*fist<mode>2_1): Ditto.
3335         (frndintxf2_floor): Ditto.
3336         (*fist<mode>2_floor_1): Ditto.
3337         (frndintxf2_ceil): Ditto.
3338         (*fist<mode>2_ceil_1): Ditto.
3339         (frndintxf2_trunc): Ditto.
3340         (frndintxf2_mask_pm): Ditto.
3341         (fxam<mode>2_i387_with_temp): Ditto.
3342         * config/i386/sse.md (mulv16qi3): Ditto.
3343         (*sse2_mulv4si3): Ditto.
3344         (mulv2di3): Ditto.
3345         (sse4_2_pcmpestr): Ditto.
3346         (sse4_2_pcmpistr): Ditto.
3347
3348 2009-07-03  Jan Hubicka  <jh@suse.cz>
3349
3350         * tree-ssa-dce.c (bb_contains_live_stmts): New bitmap.
3351         (mark_stmt_necessary): Set it.
3352         (mark_operand_necessary): Set it.
3353         (mark_control_dependent_edges_necessary): Set it.
3354         (mark_virtual_phi_result_for_renaming): New function.
3355         (get_live_post_dom): New function.
3356         (forward_edge_to_pdom): New function.
3357         (remove_dead_stmt): Fix handling of control dependences.
3358         (tree_dce_init): Init new bitmap.
3359         (tree_dce_done): Free it.
3360
3361 2009-07-02  Richard Guenther  <rguenther@suse.de>
3362
3363         PR bootstrap/40617
3364         * tree-ssa-structalias.c (new_var_info): Initialize
3365         is_restrict_var.
3366
3367 2009-07-02  Jan Hubicka  <jh@suse.cz>
3368
3369         * ipa-pure-const.c (check_op): Use PTA info to see if indirect_ref is
3370         local.
3371
3372 2009-07-02  Paolo Bonzini  <bonzini@gnu.org>
3373
3374         * expmed.c (emit_cstore, emit_store_flag_1): Accept target_mode
3375         instead of recomputing it.  Adjust calls.
3376         (emit_store_flag): Adjust recursive calls.
3377
3378 2009-07-02  Richard Guenther  <rguenther@suse.de>
3379
3380         * tree-ssa-live.c (remove_unused_locals): Do not remove
3381         heap variables.
3382         * tree-ssa-structalias.c (handle_lhs_call): Delay setting
3383         of DECL_EXTERNAL for HEAP variables.
3384         (compute_points_to_sets): Set DECL_EXTERNAL for escaped
3385         HEAP variables.  Do not adjust RESTRICT vars.
3386         (find_what_var_points_to): Nobody cares if something
3387         points to READONLY.
3388
3389 2009-07-02  Ben Elliston  <bje@au.ibm.com>
3390
3391         * unwind-dw2-fde-glibc.c (_Unwind_IteratePhdrCallback): Move
3392         pc_low and pc_high declarations to the top of the function.
3393
3394 2009-07-01  DJ Delorie  <dj@redhat.com>
3395
3396         * config/mep/mep.c (mep_handle_option): Leave IVC2 control
3397         registers as fixed.
3398         (mep_interrupt_saved_reg): Save appropriate IVC2 control registers.
3399         * config/mep/mep-ivc2.cpu: Add VOLATILE to insns that make
3400         unspecified accesses to control registers.
3401         * config/mep/intrinsics.md: Regenerate.
3402         * config/mep/intrinsics.h: Regenerate.
3403         * config/mep/mep-intrin.h: Regenerate.
3404
3405 2009-07-01  Anthony Green  <green@moxielogic.com>
3406
3407         * config/moxie/moxie.c (moxie_expand_prologue): Use dec
3408         instruction when possible.
3409         (moxie_expand_prologue): Ditto.  Also, save an instruction and
3410         some complexity by popping off of $r12 instead of $sp.
3411         * config/moxie/moxie.md (movsi_pop): Don't assume $sp.  Take two
3412         operands.
3413
3414 2009-07-01  Richard Henderson  <rth@redhat.com>
3415
3416         PR bootstrap/40347
3417         * function.c (reposition_prologue_and_epilogue_notes): If epilogue
3418         contained no insns, reposition note before last insn.
3419
3420 2009-07-01  Richard Henderson  <rth@redhat.com>
3421
3422         PR debug/40431
3423         * dwarf2out.c (def_cfa_1): Revert 2009-06-11 change for
3424         DW_CFA_def_cfa_offset and DW_CFA_def_cfa.
3425
3426 2009-07-01  Michael Meissner  <meissner@linux.vnet.ibm.com>
3427
3428         PR bootstrap/40558
3429         * config/rs6000/rs6000.c (print_operand): Undo change that breaks
3430         darwin9 for printing reg addresses with %y.
3431
3432 2009-07-01  Adam Nemet  <anemet@caviumnetworks.com>
3433
3434         * combine.c (force_to_mode): Handle TRUNCATE.  Factor out
3435         truncation from operands in binary operations.
3436
3437 2009-07-01  Adam Nemet  <anemet@caviumnetworks.com>
3438
3439         Revert:
3440         2009-01-11  Adam Nemet  <anemet@caviumnetworks.com>
3441         * expmed.c (store_bit_field_1): Properly truncate the paradoxical
3442         subreg of op0 to the original op0.
3443
3444         * expmed.c (store_bit_field_1): Use a temporary as the destination
3445         instead of a paradoxical subreg when we need to truncate the result.
3446
3447 2009-07-01  DJ Delorie  <dj@redhat.com>
3448
3449         * config/mep/mep-ivc2.cpu (cmov, cmovc, cmovh): Add intrinsic
3450         names to VLIW variants.
3451         (ivc2rm, ivc2crn): Make data type consistent with non-VLIW variants.
3452         * config/mep/intrinsics.md: Regenerate.
3453         * config/mep/intrinsics.h: Regenerate.
3454         * config/mep/mep-intrin.h: Regenerate.
3455
3456 2009-07-01  Jakub Jelinek  <jakub@redhat.com>
3457
3458         PR debug/40462
3459         * jump.c (returnjump_p): Revert last patch.
3460         * dwarf2out.c (dwarf2out_begin_epilogue): Handle SEQUENCEs.
3461
3462 2009-07-01  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
3463
3464         PR target/40575
3465         * pa.md (casesi32p): Use jump table label to determine the offset
3466         of the jump table.
3467         (casesi64p): Likewise.
3468
3469         * pa.c (forward_branch_p): Return bool type.  Use instruction
3470         addresses when available.  Assert that INSN has a jump label.
3471         (pa_adjust_insn_length): Don't call forward_branch_p if INSN doesn't
3472         have a jump label.
3473
3474 2009-07-01  Richard Guenther  <rguenther@suse.de>
3475
3476         PR tree-optimization/19831
3477         * tree-ssa-dce.c (propagate_necessity): Calls to functions
3478         that only act as barriers do not make any previous stores necessary.
3479         * tree-ssa-structalias.c (handle_lhs_call): Delay making
3480         HEAP variables global, do not add a constraint from nonlocal.
3481         (find_func_aliases): Handle escapes through return statements.
3482         (compute_points_to_sets): Make escaped HEAP variables global.
3483
3484 2009-07-01  Paolo Bonzini  <bonzini@gnu.org>
3485
3486         PR bootstrap/40597
3487         * expmed.c (emit_store_flag): Perform a conversion if necessary,
3488         after reducing a DImode cstore to SImode.
3489
3490 2009-07-01  Paolo Bonzini  <bonzini@gnu.org>
3491
3492         * expr.c (expand_expr_real_1): Reinstate fallthrough to
3493         TRUTH_ANDIF_EXPR if do_store_flag returns NULL.
3494
3495 2009-07-01  Maciej W. Rozycki  <macro@linux-mips.org>
3496
3497         * config/vax/vax.h (TARGET_BSD_DIVMOD): New macro.  Set to 1.
3498         * config/vax/linux.h (TARGET_BSD_DIVMOD): New macro.  Redefine the
3499         to 0.
3500         * config/vax/vax.c (vax_init_libfuncs): Only redefine udiv_optab
3501         and umod_optab if TARGET_BSD_DIVMOD.
3502         * config/vax/lib1funcs.asm: New file.
3503         * config/vax/t-linux: New file.
3504         * config.gcc (vax-*-linux*): Set tmake_file to vax/t-linux.
3505
3506 2009-06-30  Jakub Jelinek  <jakub@redhat.com>
3507
3508         PR c++/40566
3509         * convert.c (convert_to_integer) <case COND_EXPR>: Don't convert
3510         to type arguments that have void type.
3511
3512         PR debug/40573
3513         * dwarf2out.c (gen_formal_parameter_die): Call
3514         equate_decl_number_to_die if node is different from origin.
3515
3516 2009-06-30  Anthony Green  <green@moxielogic.com>
3517
3518         Clean up moxie port for --enable-build-with-cxx.
3519         * config/moxie/moxie.c (moxie_function_value): First two
3520         parameters are const_tree, not tree.
3521         * config/moxie/moxie.h (enum reg_class): Rename CC_REG to CC_REGS.
3522         (REG_CLASS_NAMES): Ditto.
3523         (REGNO_REG_CLASS): Ditto.
3524         * config/moxie/moxie-protos.h (moxie_override_options): Declare.
3525         (moxie_function_value): Fix constyness of arguments.
3526
3527 2009-06-30  Eric Botcazou  <ebotcazou@adacore.com>
3528
3529         * cgraphunit.c (cgraph_finalize_compilation_unit): Call
3530         finalize_size_functions before further processing.
3531         * stor-layout.c: Include cgraph.h, tree-inline.h and tree-dump.h.
3532         (variable_size): Call self_referential_size on size expressions
3533         that contain a PLACEHOLDER_EXPR.
3534         (size_functions): New static variable.
3535         (copy_self_referential_tree_r): New static function.
3536         (self_referential_size): Likewise.
3537         (finalize_size_functions): New global function.
3538         * tree.c: Include tree-inline.h.
3539         (push_without_duplicates): New static function.
3540         (find_placeholder_in_expr): New global function.
3541         (substitute_in_expr) <tcc_declaration>: Return the replacement object
3542         on equality.
3543         <tcc_expression>: Likewise.
3544         <tcc_vl_exp>: If the replacement object is a constant, try to inline
3545         the call in the expression.
3546         * tree.h (finalize_size_functions): Declare.
3547         (find_placeholder_in_expr): Likewise.
3548         (FIND_PLACEHOLDER_IN_EXPR): New macro.
3549         (substitute_placeholder_in_expr): Update comment.
3550         * tree-inline.c (remap_decl): Do not unshare trees if do_not_unshare
3551         is true.
3552         (copy_tree_body_r): Likewise.
3553         (copy_tree_body): New static function.
3554         (maybe_inline_call_in_expr): New global function.
3555         * tree-inline.h (struct copy_body_data): Add do_not_unshare field.
3556         (maybe_inline_call_in_expr): Declare.
3557         * Makefile.in (tree.o): Depend on TREE_INLINE_H.
3558         (stor-layout.o): Depend on CGRAPH_H, TREE_INLINE_H, TREE_DUMP_H and
3559         GIMPLE_H.
3560
3561 2009-06-30  Richard Guenther  <rguenther@suse.de>
3562
3563         * tree-ssa-dce.c (mark_all_reaching_defs_necessary_1): Always
3564         continue walking.
3565         (propagate_necessity): Do not mark reaching defs of stores
3566         as necessary.
3567
3568 2009-06-30  Jan Hubicka  <jh@suse.cz>
3569
3570         * cfgloopanal.c (check_irred): Move into ...
3571         (mark_irreducible_loops): ... here; return true if ireducible
3572         loops was found.
3573         * ipa-pure-const.c: Include cfgloop.h and tree-scalar-evolution.h
3574         (analyze_function): Try to prove loop finiteness.
3575         * cfgloop.h (mark_irreducible_loops): Update prototype.
3576         * Makefile.in (ipa-pure-const.o): Add dependency on SCEV and CFGLOOP.
3577
3578 2009-06-30  Basile Starynkevitch  <basile@starynkevitch.net>
3579
3580         * Makefile.in (PLUGIN_HEADERS): added ggc, tree-dump, pretty-print.
3581
3582 2009-06-30  Ira Rosen  <irar@il.ibm.com>
3583
3584         PR tree-optimization/40542
3585         * tree-vect-stmts.c (vect_analyze_stmt): Don't vectorize volatile
3586         types.
3587
3588 2009-06-30  Martin Jambor  <mjambor@suse.cz>
3589
3590         PR tree-optimization/40582
3591         * tree-sra.c (build_ref_for_offset_1): Use types_compatible_p rather
3592         than useless_type_conversion_p.
3593         (generate_subtree_copies): Increment sra_stats.subtree_copies at a
3594         proper place.
3595
3596 2009-06-30  Martin Jambor  <mjambor@suse.cz>
3597
3598         PR middle-end/40554
3599         * tree-sra.c (sra_modify_expr): Add access->offset to start_offset.
3600
3601 2009-06-30  Richard Guenther  <rguenther@suse.de>
3602
3603         * tree-ssa-alias.c (walk_aliased_vdefs_1): Change interface to
3604         use ao_ref references.
3605         (walk_aliased_vdefs): Likewise.
3606         * tree-ssa-alias.h (walk_aliased_vdefs): Adjust prototype.
3607         * tree-ssa-dce.c (struct ref_data): Remove.
3608         (mark_aliased_reaching_defs_necessary_1): Use the ao_ref argument.
3609         (mark_aliased_reaching_defs_necessary): Adjust.
3610         (mark_all_reaching_defs_necessary_1): Likewise.
3611
3612 2009-06-30  Paolo Bonzini  <bonzini@gnu.org>
3613
3614         PR boostrap/40597
3615         * expmed.c (emit_cstore): New name of emit_store_flag_1.
3616         (emit_store_flag_1): Extract from emit_store_flag, adjust
3617         calls to (what now is) emit_cstore.
3618         (emit_store_flag): Call emit_store_flag_1 and also use it
3619         for what used to be recursive calls.
3620
3621 2009-06-30  Wei Guozhi  <carrot@google.com>
3622
3623         PR/40416
3624         * tree-ssa-sink.c (statement_sink_location): Stop sinking expression
3625         if the target bb post dominates from bb.
3626         * config/i386/i386.c (memory_address_length): Check existence of base
3627         register before using it.
3628
3629 2009-06-30  Nick Clifton  <nickc@redhat.com>
3630             DJ Delorie  <dj@redhat.com>
3631
3632         * config.sh/lib1funcs.h (FMOVD_WORKS): Only define if
3633         __FMOVD_ENABLED__ is defined.
3634         * config/sh/sh.h
3635         (TARGET_FMOVD): Provide a default definition.
3636         (MASK_FMOVD): Likewise.
3637         (TARGET_CPU_CPP_BUILTINS): Define
3638         __FMOVD_ENABLED__ if TARGET_FMOVD is true.
3639         * config/sh/sh.md (movdf_i4): For alternative 0 use either one or
3640         two fmov instructions depending upon whether TARGET_FMOVD is
3641         enabled.
3642         (split for DF load from memory into register): Also handle
3643         MEMs which consist of REG+DISP addressing.
3644         (split for DF store from register to memory): Likewise.
3645         * config/sh/sh.opt (mfmovd): Remove this switch.
3646         * doc/invoke.texi (-mfmovd): Remove documentation of this switch.
3647         * config/sh/sh.c (sh_override_options): Do not automatically
3648         enable TARGET_MOVD for the SH2A when supporting doubles - leave
3649         that to the -mfmovd command line switch.
3650
3651         * config/sh/sh.c (broken_move): Do not restrict fldi test to only
3652         the SH4 and SH4A.
3653         (fldi_ok): Always allow.
3654         * config/sh/sh.md (movsf_ie): Always use single fp_mode.
3655
3656 2009-06-29  DJ Delorie  <dj@redhat.com>
3657
3658         * doc/install.texi (mep-x-elf): Correct chip's full name.
3659
3660 2009-06-29  H.J. Lu  <hongjiu.lu@intel.com>
3661
3662         * doc/extend.texi: Fix typo.
3663
3664 2009-06-29  Tom Tromey  <tromey@redhat.com>
3665
3666         * dwarf2.h: Remove.
3667         * Makefile.in (DWARF2_H): New variable.
3668         (except.o): Use it.
3669         (dwarf2out.o): Likewise.
3670         (dwarf2asm.o): Likewise.
3671         * config/i386/t-i386: Use DWARF2_H.
3672         * except.c: Include elf/dwarf2.h.
3673         * unwind-dw2.c: Include elf/dwarf2.h.
3674         * dwarf2out.c: Include elf/dwarf2.h.
3675         (dw_loc_descr_struct) <dw_loc_opc>: Now a bitfield.
3676         <dtprel>: New field.
3677         (dwarf_stack_op_name): Don't handle INTERNAL_DW_OP_tls_addr.
3678         (size_of_loc_descr): Likewise.
3679         (output_loc_operands_raw): Likewise.
3680         (output_loc_operands): Handle new dtprel field.
3681         (loc_checksum): Update.
3682         (loc_descriptor_from_tree_1) <VAR_DDECL>: Set dtprel field.
3683         * unwind-dw2-fde-glibc.c: Include elf/dwarf2.h.
3684         * unwind-dw2-fde.c: Include elf/dwarf2.h.
3685         * dwarf2asm.c: Include elf/dwarf2.h.
3686         * unwind-dw2-fde-darwin.c: Include elf/dwarf2.h.
3687         * config/mmix/mmix.c: Include elf/dwarf2.h.
3688         * config/rs6000/darwin-fallback.c: Include elf/dwarf2.h.
3689         * config/xtensa/unwind-dw2-xtensa.c: Include elf/dwarf2.h.
3690         * config/sh/sh.c: Include elf/dwarf2.h.
3691         * config/i386/i386.c: Include elf/dwarf2.h.
3692
3693 2009-06-29  DJ Delorie  <dj@redhat.com>
3694
3695         * config/mep/mep.h (CPP_SPEC): Remove __cop macro.
3696
3697         * doc/extend.texi: Add MeP attributes and pragmas.
3698         * doc/invoke.text: Add MeP Options.
3699         * doc/contrib.texi: Add MeP contribution.
3700         * doc/md.texi: Add MeP constraints.
3701         * doc/install.texi: Add MeP target.
3702
3703 2009-06-30  Anatoly Sokolov  <aesok@post.ru>
3704
3705         * target.h (struct gcc_target): Add frame_pointer_required field.
3706         * target-def.h (TARGET_FRAME_POINTER_REQUIRED): New.
3707         (TARGET_INITIALIZER): Use TARGET_FRAME_POINTER_REQUIRED.
3708         * ira.c (setup_eliminable_regset): Use frame_pointer_required target
3709         hook.
3710         * reload1.c (update_eliminables): (Ditto.).
3711         * gcc/system.h (FRAME_POINTER_REQUIRED): Poison.
3712         * doc/tm.texi (FRAME_POINTER_REQUIRED): Revise documentation.
3713         (INITIAL_FRAME_POINTER_OFFSET): (Ditto.).
3714
3715         * config/arc/arc.h (FRAME_POINTER_REQUIRED): Remove macro.
3716
3717         * config/arm/arm.h (FRAME_POINTER_REQUIRED): Remove macro.
3718         * config/arm/arm.c (TARGET_FRAME_POINTER_REQUIRED): Define.
3719         (arm_frame_pointer_required): New function.
3720
3721         * config/avr/avr.h (FRAME_POINTER_REQUIRED): Remove macro.
3722         * config/avr/avr.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
3723         (avr_frame_pointer_required_p): Declare as static.
3724         * config/avr/avr-protos.h (avr_frame_pointer_required_p): Remove.
3725
3726         * config/bfin/bfin.h (FRAME_POINTER_REQUIRED): Remove macro.
3727         * config/bfin/bfin.c (TARGET_FRAME_POINTER_REQUIRED): Define.
3728         (bfin_frame_pointer_required): Make as static, change return type
3729         to bool.
3730         * config/bfin/bfin-protos.h (bfin_frame_pointer_required): Remove.
3731
3732         * config/cris/cris.h (FRAME_POINTER_REQUIRED): Remove macro.
3733         * config/cris/cris.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
3734         (cris_frame_pointer_required): New function.
3735
3736         * config/crx/crx.h (FRAME_POINTER_REQUIRED): Remove macro.
3737
3738         * config/fr30/fr30.h (FRAME_POINTER_REQUIRED): Remove macro.
3739         * config/fr30/fr30.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
3740         (fr30_frame_pointer_required): New function.
3741
3742         * config/frv/frv.h (FRAME_POINTER_REQUIRED): Remove macro.
3743         * config/frv/frv.c (TARGET_FRAME_POINTER_REQUIRED): Define.
3744         (frv_frame_pointer_required): Make as static, change return type
3745         to bool.
3746         * config/bfin/bfin-protos.h (frv_frame_pointer_required): Remove.
3747
3748         * config/i386/i386.h (FRAME_POINTER_REQUIRED): Remove macro.
3749         * config/i386/i386.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
3750         (ix86_frame_pointer_required): Make as static, change return type to
3751         bool.
3752         * config/i386/i386-protos.h (ix86_frame_pointer_required): Remove.
3753
3754         * config/m32c/m32c.h (FRAME_POINTER_REQUIRED): Remove macro.
3755         * config/m32c/m32c.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
3756
3757         * config/m32r/m32r.h (FRAME_POINTER_REQUIRED): Remove macro.
3758
3759         * config/mcore/mcore.h (CAN_ELIMINATE): Remove macro.
3760
3761         * config/mep/mep.h (FRAME_POINTER_REQUIRED): Remove macro.
3762
3763         * config/mips/mips.h (FRAME_POINTER_REQUIRED): Remove macro.
3764         * config/mips/mips.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
3765         (mips_frame_pointer_required): Make as static.
3766         * config/mips/mips-protos.h (mips_frame_pointer_required): Remove.
3767
3768         * config/mmix/mmix.h (FRAME_POINTER_REQUIRED): Remove macro.
3769         * config/mmix/mmix.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
3770         (mmix_frame_pointer_required): Mew function.
3771
3772         * config/moxie/moxie.h (FRAME_POINTER_REQUIRED): Remove macro.
3773         * config/moxie/moxie.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
3774
3775         * config/pa/pa.h (FRAME_POINTER_REQUIRED): Remove macro.
3776
3777         * config/score/score.h (FRAME_POINTER_REQUIRED): Remove macro.
3778
3779         * config/sh/sh.h (CAN_ELIMINATE): Remove macro.
3780
3781         * config/sparc/sparc.h (FRAME_POINTER_REQUIRED): Remove macro.
3782         (CAN_ELIMINATE): Redefine.
3783         * config/sparc/sparc.c (TARGET_FRAME_POINTER_REQUIRED): Define macro.
3784         (sparc_frame_pointer_required): New function.
3785         (sparc_can_eliminate): New function.
3786         * config/sparc/sparc-protos.h (sparc_can_eliminate): Declare.
3787
3788         * config/vax/vax.h (FRAME_POINTER_REQUIRED): Remove macro.
3789         * config/vax/vax.c (TARGET_FRAME_POINTER_REQUIRED): Define.
3790
3791         * config/xtensa/xtensa.h (FRAME_POINTER_REQUIRED): Remove macro.
3792         * config/xtensa/xtensa.c (TARGET_FRAME_POINTER_REQUIRED): Define.
3793         (xtensa_frame_pointer_required): Make as static, change return type
3794         to bool.
3795         * config/xtensa/xtensa-protos.h (xtensa_frame_pointer_required):
3796         Remove.
3797
3798 2009-06-29  Olatunji Ruwase  <tjruwase@google.com>
3799
3800         * doc/plugins.texi: Document PLUGIN_START_UNIT.
3801         * toplev.c (compile_file): Call PLUGIN_START_UNIT.
3802         * gcc-plugin.h (PLUGIN_START_UNIT): Added new event.
3803         * plugin.c (plugin_event_name): Added PLUGIN_START_UNIT.
3804         (register_callback): Handle PLUGIN_START_UNIT.
3805         (invoke_plugin_callbacks): Handle PLUGIN_START_UNIT.
3806
3807 2009-06-29  Eric Botcazou  <ebotcazou@adacore.com>
3808
3809         * tree.c (process_call_operands): Propagate TREE_READONLY from the
3810         operands.
3811         (PROCESS_ARG): Do not clear TREE_READONLY if CONSTANT_CLASS_P.
3812         (build3_stat): Propagate TREE_READONLY for COND_EXPR.
3813
3814 2009-06-29  Daniel Jacobowitz  <dan@codesourcery.com>
3815
3816         * config/arm/arm.h (REGISTER_MOVE_COST): Increase VFP register
3817         move cost.
3818
3819 2009-06-29  Uros Bizjak  <ubizjak@gmail.com>
3820
3821         * doc/extend.texi (Additional Floating Types): __float128 is also
3822         supported on i386 targets.
3823
3824 2009-06-29  Richard Guenther  <rguenther@suse.de>
3825
3826         PR middle-end/14187
3827         * tree-ssa-alias.h (struct pt_solution): Add vars_contains_restrict
3828         flag.
3829         (pt_solutions_same_restrict_base): Declare.
3830         * tree-ssa-structalias.c (struct variable_info): Add is_restrict_var
3831         flag.
3832         (new_var_info): Initialize is_global_var properly for SSA_NAMEs.
3833         (make_constraint_from, make_copy_constraint): Move earlier.
3834         (make_constraint_from_heapvar): New function.
3835         (make_constraint_from_restrict): Likewise.
3836         (handle_lhs_call): Use it.
3837         (find_func_aliases): Use it to track conversions to restrict
3838         qualified pointers.
3839         (struct fieldoff): Add only_restrict_pointers flag.
3840         (push_fields_onto_fieldstack): Initialize it.
3841         (create_variable_info_for): Track global restrict qualified pointers.
3842         (intra_create_variable_infos): Use make_constraint_from_heapvar.
3843         Track restrict qualified pointer arguments.
3844         (set_uids_in_ptset): Use varinfo is_global_var flag.
3845         (find_what_var_points_to): Set the vars_contains_restrict flag.
3846         Always create the points-to solution for sets including restrict tags.
3847         (pt_solutions_same_restrict_base): New function.
3848         * tree-ssa-alias.c (ptr_derefs_may_alias_p): For two restrict
3849         qualified pointers use pt_solutions_same_restrict_base as
3850         additional source for disambiguation.
3851
3852 2009-06-29  Richard Guenther  <rguenther@suse.de>
3853
3854         PR middle-end/38212
3855         * alias.c (find_base_decl): Remove.
3856         (get_deref_alias_set_1): Remove restrict handling.
3857         * c-common.c (c_apply_type_quals_to_decl): Do not set
3858         DECL_POINTER_ALIAS_SET.
3859         * gimplify.c (find_single_pointer_decl_1): Remove.
3860         (find_single_pointer_decl): Likewise.
3861         (internal_get_tmp_var): Remove restrict handling.
3862         (gimple_regimplify_operands): Likewise.
3863         * omp-low.c (expand_omp_atomic_pipeline): Do not set
3864         DECL_POINTER_ALIAS_SET. Use ref-all pointers.
3865         * print-tree.c (print_node): Do not print DECL_POINTER_ALIAS_SET.
3866         * tree.c (restrict_base_for_decl): Remove.
3867         (init_ttree): Do not allocate it.
3868         (make_node_stat): Do not set DECL_POINTER_ALIAS_SET.  Set
3869         LABEL_DECL_UID for label decls.
3870         (copy_node_stat): Do not copy restrict information.
3871         (decl_restrict_base_lookup): Remove.
3872         (decl_restrict_base_insert): Likewise.
3873         (print_restrict_base_statistics): Likewise.
3874         (dump_tree_statistics): Do not call print_restrict_base_statistics.
3875         * tree.h (DECL_POINTER_ALIAS_SET): Remove.
3876         (DECL_POINTER_ALIAS_SET_KNOWN_P): Likewise.
3877         (struct tree_decl_common): Rename pointer_alias_set to label_decl_uid.
3878         (LABEL_DECL_UID): Adjust.
3879         (DECL_BASED_ON_RESTRICT_P): Remove.
3880         (DECL_GET_RESTRICT_BASE): Likewise.
3881         (SET_DECL_RESTRICT_BASE): Likewise.
3882         (struct tree_decl_with_vis): Remove based_on_restrict_p flag.
3883
3884         * config/i386/i386.c (ix86_gimplify_va_arg): Use ref-all pointers
3885         instead of DECL_POINTER_ALIAS_SET.
3886         * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Likewise.
3887         * config/s390/s390.c (s390_gimplify_va_arg): Likewise.
3888         * config/spu/spu.c (spu_gimplify_va_arg_expr): Likewise.
3889
3890 2009-06-29  Richard Guenther  <rguenther@suse.de>
3891
3892         PR tree-optimization/40579
3893         * tree-vrp.c (vrp_evaluate_conditional): Bail out early if
3894         the IL to simplify has constants that overflowed.
3895
3896 2009-06-28  Uros Bizjak  <ubizjak@gmail.com>
3897
3898         PR tree-optimization/40550
3899         * tree-vect-generic.c (expand_vector_operations_1): Compute in
3900         vector_compute_type only when the size of vector_compute_type is
3901         less than the size of type.
3902
3903 2009-06-28  Eric Botcazou  <ebotcazou@adacore.com>
3904
3905         * fold-const.c (contains_label_1): Fix comments.
3906         (contains_label_p): Do not walk trees multiple time.
3907
3908 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
3909
3910         * config/i386/i386.h (enum ix86_fpcmp_strategy): New.
3911         * config/i386/i386.md (cbranchxf4, cstorexf4, cbranch<MODEF>4,
3912         cstore<MODEF>4, mov<X87MODEF>cc): Change predicate to
3913         ix86_fp_comparison_operator.
3914         (*fp_jcc_1_mixed, *fp_jcc_1_sse, *fp_jcc_1_387, *fp_jcc_2_mixed,
3915         *fp_jcc_2_sse, *fp_jcc_2_387): Delete
3916         (*fp_jcc_3_387, *fp_jcc_4_387, *fp_jcc_5_387, *fp_jcc_6_387,
3917         *fp_jcc_7_387, *fp_jcc_8<MODEF>_387): Eliminate call to
3918         !ix86_use_fcomi_compare, change ix86_fp_jump_nontrivial_p call
3919         to !TARGET_CMOVE, change predicate to ix86_fp_comparison_operator.
3920         (related splits): Change predicate to ix86_fp_comparison_operator.
3921         * config/i386/predicates.md: Use ix86_trivial_fp_comparison_operator
3922         instead of ix86_fp_comparison_codes.
3923         (ix86_trivial_fp_comparison_operator,
3924         ix86_fp_comparison_operator): New.
3925         * config/i386/i386-protos.h (ix86_fp_comparison_strategy): New.
3926         (ix86_expand_compare): Eliminate last two parameters.
3927         (ix86_fp_jump_nontrivial_p): Kill.
3928         * config/i386/i386.c (put_condition_code): Eliminate call to
3929         ix86_fp_comparison_codes and subsequent assertion.
3930         (ix86_fp_comparison_codes): Eliminate.
3931         (ix86_fp_swap_condition): New.
3932         (ix86_fp_comparison_arithmetics_cost, ix86_fp_comparison_fcomi_cost,
3933         ix86_fp_comparison_sahf_cost, ix86_use_fcomi_compare): Consolidate
3934         into ix86_fp_comparison_cost and ix86_fp_comparison_strategy.
3935         (ix86_prepare_fp_compare_args): Use ix86_fp_comparison_strategy
3936         and ix86_fp_swap_condition.
3937         (ix86_expand_fp_compare): Eliminate code for second jump/bypass jump.
3938         Use ix86_fp_comparison_strategy.
3939         (ix86_expand_compare): Likewise.  Eliminate last two arguments.
3940         (ix86_fp_jump_nontrivial_p): Eliminate.
3941         (ix86_expand_branch): Treat SFmode/DFmode/XFmode as simple.  Adjust
3942         call to ix86_expand_compare.
3943         (ix86_split_fp_branch, ix86_expand_setcc,
3944         ix86_expand_carry_flag_compare, ix86_expand_int_movcc,
3945         ix86_expand_fp_movcc): Eliminate code for second jump/bypass jump.
3946
3947 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
3948
3949         * config/arm/arm.c (arm_final_prescan_ins): Eliminate code
3950         related to jump_clobbers.
3951         * config/arm/arm.md (conds): Remove jump_clob case.
3952         (addsi3_cbranch, addsi3_cbranch_scratch, subsi3_cbranch, two
3953         splits): Change comparison_operator to arm_comparison_operator.
3954         (*arm_buneq, *arm_bltgt, *arm_buneq_reversed, *arm_bltgt_reversed):
3955         Eliminate.
3956
3957 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
3958
3959         * dojump.c (do_compare_rtx_and_jump): Try swapping the
3960         condition for floating point modes.
3961         * expmed.c (emit_store_flag_1): Move here a bigger part
3962         of emit_store_flag.
3963         (emit_store_flag): Try swapping the condition for floating point
3964         modes.
3965         * optabs.c (emit_cmp_and_jump_insns): Cope with constant op0 better.
3966
3967 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
3968
3969         * expr.c (expand_expr_real_1): Just use do_store_flag.
3970         (do_store_flag): Drop support for TRUTH_NOT_EXPR.  Use
3971         emit_store_flag_force.
3972         * expmed.c (emit_store_flag_force): Copy here trick
3973         previously in expand_expr_real_1.  Try reversing the comparison.
3974         (emit_store_flag_1): Work if target is NULL.
3975         (emit_store_flag): Work if target is NULL, using the result mode
3976         from the comparison.  Use split_comparison, restructure final part
3977         to simplify conditionals.
3978
3979 2009-06-28  Paolo Bonzini  <bonzini@gnu.org>
3980
3981         * builtins.c (expand_errno_check): Use do_compare_rtx_and_jump.
3982         * dojump.c (do_jump): Change handling of floating-point
3983         ops to use just do_compare_and_jump.
3984         (split_comparison): New.
3985         (do_compare_rtx_and_jump): Add here logic coming previously
3986         in do_jump, using split_comparison.
3987
3988 2009-06-27  H.J. Lu  <hongjiu.lu@intel.com>
3989
3990         PR target/40489
3991         * config/ia64/ia64.c (ia64_reorg): Check NULL insn.
3992
3993 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
3994
3995         * tree-ssa-alias.c: Fix unintentional commit.
3996
3997 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
3998
3999         * passes.c (execute_one_pass): Fix unintentional commit.
4000
4001 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
4002
4003         * df-problems.c (df_set_seen, df_unset_seen): Delete.
4004         (df_rd_local_compute, df_md_local_compute): Inline them.
4005
4006         (df_md_scratch): New.
4007         (df_md_alloc, df_md_free): Allocate/free it.
4008         (df_md_local_compute): Only include live registers in init.
4009