OSDN Git Service

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