tree.h (tree_constructor): Remove IS_UNKNOWN_LOCATION.
[platform/upstream/gcc.git] / gcc / ChangeLog
1 2012-09-27  Dehao Chen  <dehao@google.com>
2
3         * tree.h (tree_constructor): Remove IS_UNKNOWN_LOCATION.
4         (extern void protected_set_expr_location): Likewise.
5         (function_args_iter_next): Likewise.
6         (inlined_function_outer_scope_p): Likewise.
7         * input.h (IS_UNKNOWN_LOCATION): Likewise.
8         * fold-const.c (expr_location_or): Likewise.
9         * lto-cgraph.c (output_node_opt_summary): Likewise.
10         * dwarf2out.c (add_src_coords_attributes): Likewise.
11         * tree-eh.c (lower_try_finally_dup_block): Likewise.
12         * profile.c (branch_prob):
13         * cfgexpand.c (expand_gimple_cond): Likewise.
14         (expand_gimple_basic_block): Likewise.
15         (construct_exit_block): Likewise.
16         (gimple_expand_cfg): Likewise.
17         * cfgcleanup.c (try_forward_edges): Likewise.
18         * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
19         (dump_scope_block): Likewise.
20         * ipa-prop.c (ipa_write_jump_function): Likewise.
21         * rtl.h (extern void rtl_check_failed_flag): Likewise.
22         * gimple.h (gimple_set_location): Likewise.
23         (gimple_has_location): Likewise.
24         * cfgrtl.c (unique_locus_on_edge_between_p): Likewise.
25         (force_nonfallthru_and_redirect): Likewise.
26         (fixup_reorder_chain): Likewise.
27         (cfg_layout_merge_blocks): Likewise.
28
29 2012-09-27  Meador Inge  <meadori@codesourcery.com>
30
31         * gcc-ar.c (main): Handle the returning of the sub-process error
32         code correctly.
33
34 2012-09-27  Ulrich Weigand  <ulrich.weigand@linaro.org>
35
36         * lower-subreg.c (enum classify_move_insn): Rename
37         SIMPLE_PSEUDO_REG_MOVE to DECOMPOSABLE_SIMPLE_MOVE.
38         (find_decomposable_subregs): Update.
39         (decompose_multiword_subregs): Add DECOMPOSE_COPIES parameter.
40         Only mark pseudo-to-pseudo copies as DECOMPOSABLE_SIMPLE_MOVE
41         if that parameter is true.
42         (rest_of_handle_lower_subreg): Call decompose_multiword_subregs
43         with DECOMPOSE_COPIES false.
44         (rest_of_handle_lower_subreg2): Call decompose_multiword_subregs
45         with DECOMPOSE_COPIES true.
46
47 2012-09-27  Marek Polacek  <polacek@redhat.com>
48
49         * doc/gcov.texi (Gcov Data Files): Fix a typo.
50
51 2012-09-27  Jakub Jelinek  <jakub@redhat.com>
52
53         PR target/54703
54         * simplify-rtx.c (simplify_binary_operation_1): Perform
55         (x - (x & y)) -> (x & ~y) optimization only for integral
56         modes.
57
58 2012-09-27  Marc Glisse  <marc.glisse@inria.fr>
59
60         PR c/53024
61         PR c++/54427
62         * doc/extend.texi (Vector Extensions): C++ improvements.
63         Power of 2 size requirement.
64
65 2012-09-27  Richard Guenther  <rguenther@suse.de>
66
67         PR lto/54709
68         * lto-symtab.c (resolution_guessed_p): Remove.
69         (set_resolution_guessed): Likewise.
70         (lto_symtab_register_decl): Remove assert.
71         (lto_symtab_resolve_symbols): Do not alter symbol resolutions
72         and return the prevailing symbol, checking for multiple prevailing
73         symbols here.
74         (lto_symtab_merge_decls_1): Use the result from
75         lto_symtab_resolve_symbols.  Do not alter symbol resolutions.
76
77 2012-09-26  Steve Ellcey  <sellcey@mips.com>
78
79         PR web/54711
80         * doc/install.texi: Fix example.
81
82 2012-09-26  Dehao Chen  <dehao@google.com>
83
84          * tree-ssa-live.c (clear_unused_block_pointer): Use explicitit (void)
85         for function parameter.
86         (remove_unused_locals): Don't use LOCATION_BLOCK if it is NULL.
87
88 2012-09-26  Oleg Endo  <olegendo@gcc.gnu.org>
89
90         * doc/extend.texi (bswap Builtins): Change signed types to unsigned
91         types.
92
93 2012-09-26  Ian Lance Taylor  <iant@google.com>
94
95         * diagnostic.c (bt_callback): Cast pc when calling fprintf.
96
97 2012-09-26  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
98
99         PR tree-optimization/54674
100         * gimple-ssa-strength-reduction.c (analyze_increments): Don't
101         introduce a multiplication with a pointer operand.
102
103 2012-09-26  Georg-Johann Lay  <avr@gjlay.de>
104
105         PR middle-end/54635
106         * doc/tm.texi.in (TARGET_MODE_DEPENDENT_ADDRESS_P): Document new
107         parameter addrspace.
108         * doc/tm.texi: Regenerate.
109         * target.def (mode_dependent_address_p): Add addr_space_t parameter.
110         * targhooks.h (default_mode_dependent_address_p): Ditto.
111         * targhooks.c (default_mode_dependent_address_p): Ditto.
112         * expr.c (convert_move): Pass address space to mode_dependent_address_p.
113         * combine.c (combine_simplify_rtx): Ditto.
114         (make_extraction): Ditto.
115         (simplify_shift_const_1): Ditto.
116         (gen_lowpart_for_combine): Ditto.
117         * lower-subreg.c (simple_move_operand): Ditto.
118         * recog.c (simplify_while_replacing): Ditto.
119         (offsettable_address_addr_space_p): Ditto.
120         (mode_dependent_address_p): Ditto.
121         * simplify-rtx.c (simplify_unary_operation_1): Ditto.
122         (simplify_subreg): Ditto.
123         * config/m68k/m68k.md: Ditto.
124         * config/vax/vax.md: Ditto.
125         * config/vax/constraints.md (Q): Ditto.
126         * config/vax/predicates.md (indexed_memory_operand): Ditto.
127         * config/alpha/alpha.c (alpha_mode_dependent_address_p): Add
128         unused addr_space_t parameter.
129         * config/avr/avr.c (avr_mode_dependent_address_p): Ditto.
130         * config/h8300/h8300.c (h8300_mode_dependent_address_p): Ditto.
131         * config/m32r/m32r.c (m32r_mode_dependent_address_p): Ditto.
132         * config/rs6000/rs6000.c (rs6000_mode_dependent_address_p): Ditto.
133         * config/rx/rx.c (rx_mode_dependent_address_p): Ditto.
134         * config/sparc/sparc.c (sparc_mode_dependent_address_p): Ditto.
135         * config/stormy16/stormy16.c (xstormy16_mode_dependent_address_p):
136         Ditto.
137         * config/vax/vax.c (vax_mode_dependent_address_p): Ditto.
138         * config/xtensa/xtensa.c (xtensa_mode_dependent_address_p): Ditto.
139
140 2012-09-26  Christophe Lyon <christophe.lyon@linaro.org>
141
142         * tree-ssa-math-opts.c (bswap_stats): Add found_16bit field.
143         (execute_optimize_bswap): Add support for builtin_bswap16.
144
145 2012-09-26  Richard Guenther  <rguenther@suse.de>
146
147         * tree.h (DECL_IS_BUILTIN): Compare LOCATION_LOCUS.
148
149 2012-09-26  Ian Lance Taylor  <iant@google.com>
150
151         * diagnostic.c: Include "demangle.h" and "backtrace.h".
152         (bt_stop): New static array.
153         (bt_callback, bt_err_callback): New static functions.
154         (diagnostic_action_after_output): Call backtrace_full for DK_ICE.
155         * Makefile.in (BACKTRACE): New variable.
156         (BACKTRACEINC, LIBBACKTRACE): New variables.
157         (BACKTRACE_H): New variable.
158         (LIBDEPS, LIBS): Add $(LIBBACKTRACE).
159         (INCLUDES): Add $(BACKTRACEINC).
160         (diagnostic.o): Depend upon $(DEMANGLE_H) and $(BACKTRACE_H).
161
162 2012-09-25  Segher Boessenkool  <segher@kernel.crashing.org>
163
164         PR target/51274
165         PR target/53087
166         * config/rs6000/rs6000.md (ne0si): Remove unnecessary
167         earlyclobber.  Merge with...
168         (ne0di): ... to...
169         (ne0_<mode>): New.
170         (plus_ne0si): Merge with...
171         (plus_ne0di): ... to...
172         (plus_ne0_<mode>): New.
173         (compare_plus_ne0si): Merge with...
174         (compare_plus_ne0di)... to...
175         (compare_plus_ne0_<mode>): New.
176         (compare_plus_ne0_<mode>_1): New.
177         (plus_ne0si_compare): Merge with...
178         (plus_ne0di_compare)... to...
179         (plus_ne0_<mode>_compare): New.
180
181 2012-09-25  Oleg Endo  <olegendo@gcc.gnu.org>
182
183         PR target/54089
184         * config/sh/constraints.md (Jhb): New constraint.
185         * config/sh/predicates.md (negt_reg_shl31_operand): New predicate.
186         * config/sh/sh.md (rotrsi3): New expander.
187         (rotrsi3_1, *rotrsi3_1, *rotlsi3_1): New insns.
188         (rotlsi3, rotlhi3): Use const_int_operand predicate instead of
189         immediate_operand and remove CONST_INT_P checks in expansion code.
190         (*rotcr): Cleanup variable usage.  Handle preceding nott insn.  Add
191         split with swapped operands.
192         (*rotcr_neg_t, *movt_msb, *negt_msb): New insns and splits.
193
194 2012-09-25  Aldy Hernandez  <aldyh@redhat.com>
195
196         PR middle-end/53850
197         * trans-mem.c (expand_call_tm): Handle late built built-ins.
198
199 2012-09-25  Georg-Johann Lay  <avr@gjlay.de>
200
201         PR other/54701
202         * config/avr/avr-log.c (avr_double_int_pop_digit): Rewrite using
203         double_int::udivmod.
204
205 2012-09-25  Georg-Johann Lay  <avr@gjlay.de>
206
207         * config/avr/avr.c (avr_set_current_function): Check cfun->machine
208         to be non-NULL.
209
210 2012-09-25  Georg-Johann Lay  <avr@gjlay.de>
211
212         PR target/54641
213         * config/avr/t-avr: Use ALL_COMPILERFLAGS instead of ALL_CFLAGS
214         for sources compiled with COMPILER.
215         
216 2012-09-25  Richard Guenther  <rguenther@suse.de>
217
218         PR lto/54625
219         * lto-symtab.c (lto_symtab_merge_cgraph_nodes_1): Do not merge
220         cgraph nodes for builtins.
221
222 2012-09-25  Jakub Jelinek  <jakub@redhat.com>
223
224         PR tree-optimization/54676
225         * tree-vrp.c (set_and_canonicalize_value_range): Handle
226         one bit precision properly.
227
228         PR other/54692
229         * configure.ac (CFLAGS, CXXFLAGS): Remove -Ofast or -Og
230         properly.
231         * configure: Regenerated.
232
233 2012-09-25  Georg-Johann Lay  <avr@gjlay.de>
234
235         PR other/54701
236         * config/avr/avr.c (avr_map_decompose): Use double_int::from_uhwi
237         instead of uhwi_to_double_int.
238
239 2012-09-25  Richard Guenther  <rguenther@suse.de>
240
241         * lto-symtab.c (lto_symtab_merge_decls_1): Properly merge
242         all of the chain.
243
244 2012-09-25  Richard Guenther  <rguenther@suse.de>
245
246         PR tree-optimization/53663
247         * tree-ssa-sccvn.c (vn_reference_lookup_3): Conditional
248         native encode/interpret translation on VN_WALKREWRITE.
249
250 2012-09-24  Dehao Chen  <dehao@google.com>
251
252         * tree-cfg.c (move_stmt_op): Reset the expr block only
253         when necessary.
254         (move_block_to_fn): Reset the edge's goto block even
255         when the goto locus is unknown.
256
257 2012-09-24  Lawrence Crowl  <crowl@google.com>
258
259         * double-int.h (double_int::from_pair): New.
260         (double_int::wide_mul_with_sign): New.
261         (double_int::sub_with_overflow): New.
262         (double_int::neg_with_overflow): New.
263         (double_int::divmod_with_overflow): New.
264         (shwi_to_double_int): Remove.
265         (uhwi_to_double_int): Remove.
266         (double_int_to_shwi): Remove.
267         (double_int_to_uhwi): Remove.
268         (double_int_fits_in_uhwi_p): Remove.
269         (double_int_fits_in_shwi_p): Remove.
270         (double_int_fits_in_hwi_p): Remove.
271         (double_int_mul): Remove.
272         (double_int_mul_with_sign): Remove.
273         (double_int_add): Remove.
274         (double_int_sub): Remove.
275         (double_int_neg): Remove.
276         (double_int_div): Remove.
277         (double_int_sdiv): Remove.
278         (double_int_udiv): Remove.
279         (double_int_mod): Remove.
280         (double_int_smod): Remove.
281         (double_int_umod): Remove.
282         (double_int_divmod): Remove.
283         (double_int_sdivmod): Remove.
284         (double_int_udivmod): Remove.
285         (double_int_multiple_of): Remove.
286         (double_int_setbit): Remove.
287         (double_int_ctz): Remove.
288         (double_int_not): Remove.
289         (double_int_ior): Remove.
290         (double_int_and): Remove.
291         (double_int_and_not): Remove.
292         (double_int_xor): Remove.
293         (double_int_lshift): Remove.
294         (double_int_rshift): Remove.
295         (double_int_lrotate): Remove.
296         (double_int_rrotate): Remove.
297         (double_int_negative_p): Remove.
298         (double_int_cmp): Remove.
299         (double_int_scmp): Remove.
300         (double_int_ucmp): Remove.
301         (double_int_max): Remove.
302         (double_int_smax): Remove.
303         (double_int_umax): Remove.
304         (double_int_min): Remove.
305         (double_int_smin): Remove.
306         (double_int_umin): Remove.
307         (double_int_ext): Remove.
308         (double_int_sext): Remove.
309         (double_int_zext): Remove.
310         (double_int_mask): Remove.
311         (double_int_max_value): Remove.
312         (double_int_min_value): Remove.
313         (double_int_zero_p): Remove.
314         (double_int_one_p): Remove.
315         (double_int_minus_one_p): Remove.
316         (double_int_equal_p): Remove.
317         (double_int_popcount): Remove.
318         (extern add_double_with_sign): Remove.
319         (#define add_double): Remove.
320         (extern neg_double): Remove.
321         (extern mul_double_with_sign): Remove.
322         (extern mul_double_wide_with_sign): Remove.
323         (#define mul_double): Remove.
324         (extern lshift_double): Remove.
325         (extern div_and_round_double): Remove.
326         * double-int.c (add_double_with_sign): Make static.
327         (#defined add_double): Localized from header.
328         (neg_double): Make static.
329         (mul_double_with_sign): Make static.
330         (mul_double_wide_with_sign): Make static.
331         (#defined mul_double): Localized from header.
332         (lshift_double): Make static.
333         (div_and_round_double): Make static.
334         (double_int::wide_mul_with_sign): New.
335         (double_int::sub_with_overflow): New.
336         (double_int::neg_with_overflow): New.
337         (double_int::divmod_with_overflow): New.
338         * emit-rtl.c (init_emit_once): Change to new double_int API.
339         * explow.c (plus_constant): Likewise.
340         * expmed.c (choose_multiplier): Likewise.
341         * fold-const.c (#define OVERFLOW_SUM_SIGN): Remove.
342         (int_const_binop_1): Change to new double_int API.
343         (fold_div_compare): Likewise.
344         (maybe_canonicalize_comparison): Likewise.
345         (pointer_may_wrap_p): Likewise.
346         (fold_negate_const): Likewise.
347         (fold_abs_const): Likewise.
348         * simplify-rtx.c (simplify_const_unary_operation): Likewise.
349         (simplify_const_binary_operation): Likewise.
350         * tree-chrec.c (tree_fold_binomial): Likewise.
351         * tree-vrp.c (extract_range_from_binary_expr_1): Likewise.
352         * config/sparc/sparc.c (sparc_fold_builtin): Likewise.
353         * config/avr/avr.c (avr_double_int_push_digit): Likewise.
354         (avr_map): Likewise.
355         (avr_map_decompose): Likewise.
356         (avr_out_insert_bits): Likewise.
357
358 2012-09-24  Janis Johnson  <janisjo@codesourcery.com>
359
360         doc/sourcebuild.texi (Selectors): Document the use of target
361         and xfail used together.
362
363 2012-09-24  Richard Guenther  <rguenther@suse.de>
364
365         PR middle-end/54632
366         * tree-ssa-live.c (clear_unused_block_pointer_1): Do not
367         handle DECL_DEBUG_EXPR_IS_FROM here...
368         (clear_unused_block_pointer): ... but here when walking all
369         local decls.
370
371 2012-09-24  Richard Guenther  <rguenther@suse.de>
372
373         PR tree-optimization/54684
374         * tree-ssa-ccp.c (optimize_unreachable): Properly update stmts.
375
376 2012-09-24  Marc Glisse  <marc.glisse@inria.fr>
377
378         * tree-ssa-forwprop.c: Include tree-ssa-propagate.h.
379         (simplify_bitfield_ref): Handle constructors.
380         * Makefile.in (tree-ssa-forwprop.o): Depend on tree-ssa-propagate.h.
381
382 2012-09-24  Richard Guenther  <rguenther@suse.de>
383
384         * tree-ssa-pre.c (bitmap_find_leader, create_expression_by_pieces,
385         find_or_generate_expression): Remove dominating stmt argument.
386         (find_leader_in_sets, phi_translate_1, bitmap_find_leader,
387         create_component_ref_by_pieces_1, create_component_ref_by_pieces,
388         do_regular_insertion, do_partial_partial_insertion): Adjust.
389         (compute_avail): Do not set uids.
390
391 2012-09-24  Eric Botcazou  <ebotcazou@adacore.com>
392
393         * tree-streamer-in.c (unpack_ts_type_common_value_fields): Stream in
394         TYPE_NONALIASED_COMPONENT flag.
395         * tree-streamer-out.c (pack_ts_type_common_value_fields): Stream out
396         TYPE_NONALIASED_COMPONENT flag.
397
398 2012-09-24  Jia Liu  <proljc@gmail.com>
399
400         * doc/lto.texi: Separate sections.
401         * doc/plugins.texi: Likewise.
402
403 2012-09-24  Richard Guenther  <rguenther@suse.de>
404
405         PR middle-end/52173
406         * gimple.c (gimple_copy): Properly mark the copy modified
407         if SSA operands are present.
408
409 2012-09-23  Eric Botcazou  <ebotcazou@adacore.com>
410
411         PR tree-optimization/54669
412         * tree-ssa-loop-ivcanon.c (propagate_into_all_uses): Invoke
413         maybe_clean_or_replace_eh_stmt on the modified use statements.
414
415 2012-09-23  Marc Glisse  <marc.glisse@inria.fr>
416
417         * expr.c (do_store_flag): Remove duplicated code.
418
419 2012-09-22  Segher Boessenkool  <segher@kernel.crashing.org>
420
421         * config/rs6000/predicates.md (altivec_register_operand,
422         vsx_register_operand, vfloat_operand, vint_operand,
423         vlogical_operand, gpc_reg_operand, cc_reg_operand,
424         cc_reg_not_cr0_operand, cc_reg_not_micro_cr0_operand):
425         If op is a SUBREG, consider its SUBREG_REG instead.
426
427 2012-09-22  Uros Bizjak  <ubizjak@gmail.com>
428
429         * optabs.c (prepare_cmp_insn): Expand comparison of the result
430         of memcmp through generic comparison expansion code.
431
432 2012-09-21  Jack Howarth  <howarth@bromo.med.uc.edu>
433
434         PR bootstrap/54642
435         * Makefile.in (lto-symtab.o): Remove gt-lto-symtab.h dependency.
436
437 2012-09-21  Dehao Chen  <dehao@google.com>
438
439         PR go/54649
440         * tree-eh.c (lower_try_finally_dup_block): Set the correct block for
441         stmts in the duplicated EH block.
442
443 2012-09-21  Richard Guenther  <rguenther@suse.de>
444
445         PR tree-optimization/54647
446         * tree-ssa-pre.c (compute_avail): Do not put COND_EXPR
447         or VEC_COND_EXPR into EXP_GEN again.
448
449 2012-09-21  Jakub Jelinek  <jakub@redhat.com>
450
451         PR tree-optimization/54629
452         * tree-loop-distribution.c (classify_partition): Free loop nest only
453         after freeing ddr.  Free ddr and loop nest also if successful.
454
455 2012-09-21  Matthias Klose  <doko@ubuntu.com>
456
457         * config/arm/arm.c (arm_mangle_type): Don't warn anymore that
458         4.4 has changed the `va_list' mangling.
459
460 2012-09-21  Eric Botcazou  <ebotcazou@adacore.com>
461
462         PR rtl-optimization/54290
463         PR rtl-optimization/54644
464         * reload1.c (choose_reload_regs): Fix thinko in previous change.
465
466 2012-09-20  Segher Boessenkool  <segher@kernel.crashing.org>
467
468         * config/rs6000/rs6000.md (define_split for plus_eqsi):
469         Fix output pattern.
470
471 2012-09-20  Eric Botcazou  <ebotcazou@adacore.com>
472
473         * reload1.c (choose_reload_regs): Add missing #ifdef/#endif pair.
474
475 2012-09-20  Bernd Schmidt  <bernds@codesourcery.com>
476
477         PR bootstrap/54643
478         * haifa-sched.c (schedule_block): Skip find_modifiable_mems if using
479         SCHED_PRESSURE_MODEL.
480
481 2012-09-20  Joern Rennecke  <joern.rennecke@embecosm.com>
482
483         * rtlanal.c (dead_or_set_regno_p): Fix COND_EXEC handling.
484
485 2012-09-20  Marek Polacek  <polacek@redhat.com>
486
487         * tree-ssa-operands.c (get_expr_operands): Merge identical cases.
488
489 2012-09-20  Marek Polacek  <polacek@redhat.com>
490
491         * tree-ssa-threadupdate.c (mark_threaded_blocks): Don't cast XNEWVEC's
492         result.
493         (create_edge_and_update_destination_phis): Likewise.
494
495 2012-09-20  Martin Jambor  <mjambor@suse.cz>
496
497         * function.c (push_cfun): Check old current_function_decl matches
498         old cfun, set new current_function_decl to the decl of the new cfun.
499         (push_struct_function): Likewise.
500         (pop_cfun): Likewise.
501         (allocate_struct_function): Move call to
502         invoke_set_current_function_hook to the end of the function.
503         * cfgexpand.c (estimated_stack_frame_size): Do not set and restore
504         current_function_decl.
505         * cgraph.c (cgraph_release_function_body): Likewise.
506         * cgraphunit.c (cgraph_process_new_functions): Likewise.
507         (cgraph_add_new_function): Likewise.
508         (cgraph_analyze_function): Likewise.
509         (assemble_thunk): Set cfun to NULL at the end.
510         (expand_function): Move call to set_cfun downwards.
511         * gimple-low.c (record_vars_into): Only check current_function_decl
512         before possibly doing push_cfun.
513         * gimplify.c (gimplify_function_tree): Do not set and restore
514         current_function_decl.
515         * ipa-inline-analysis.c (compute_inline_parameters): Likewise.
516         (inline_analyze_function): Likewise.
517         * ipa-prop.c (ipa_analyze_node): Likewise.
518         * ipa-pure-const.c (analyze_function): Likewise.
519         * lto-streamer-in.c (lto_input_function_body): Do not set
520         current_function_decl.
521         * lto-streamer-out.c (output_function): Do not set and restore
522         current_function_decl.
523         * omp-low.c (finalize_task_copyfn): Likewise.
524         (expand_omp_taskreg): Likewise.
525         (create_task_copyfn): Likewise, move push_cfun up quite a bit.
526         * passes.c (dump_passes): Do not set and restore current_function_decl.
527         (do_per_function): Likewise.
528         (do_per_function_toporder): Likewise.
529         * trans-mem.c (ipa_tm_scan_irr_function): Likewise.
530         (ipa_tm_transform_transaction): Likewise.
531         (ipa_tm_transform_clone): Likewise.
532         (ipa_tm_execute): Likewise.
533         * tree-emutls.c (lower_emutls_function_body): Likewise.
534         * tree-inline.c (initialize_cfun): Do not call pop_cfun.
535         (tree_function_versioning): Do not call push_cfun, do not set and
536         restore current_function_decl.  Remove assert checking consistency of
537         cfun and current_function_decl.
538         * tree-profile.c (tree_profiling): Do not set and restore
539         current_function_decl.
540         * tree-sra.c (convert_callers_for_node): Do not set
541         current_function_decl.
542         (convert_callers): Do not restore current_function_decl.
543         (modify_function): Do not set current_function_decl.
544         * tree-ssa-structalias.c (ipa_pta_execute): Do not set and restore
545         current_function_decl.
546
547 2012-09-20  Diego Novillo  <dnovillo@google.com>
548
549         PR target/54631
550         * config/vxworks.c (vxworks_emutls_var_init): Update for new
551         VEC_quick_push interface.
552
553 2012-09-20  Richard Guenther  <rguenther@suse.de>
554
555         PR tree-optimization/54634
556         * tree-data-ref.c (get_references_in_stmt): For now give
557         up for pure functions.
558
559 2012-09-20  Chen Wei-Ren  <chenwj@iis.sinica.edu.tw>
560
561         * doc/lto.texi: Correct typo.
562
563 2012-09-19  Dehao Chen  <dehao@google.com>
564
565         * config/s390/s390.c (s390_chunkify_start): Replacing INSN_LOCATOR.
566         * config/spu/spu.c (emit_nop_for_insn): Likewise.
567         (pad_bb): Likewise.
568         (spu_emit_branch_hint): Likewise.
569         (insert_hbrp_for_ilb_runout): Likewise.
570         * config/mep/mep.c (mep_make_bundle): Likewise.
571         (mep_bundle_insns): Likewise.
572         * config/sh/sh.c (gen_block_redirect): Likewise.
573         * config/c6x/c6x.c (gen_one_bundle): Likewise.
574         * config/rs6000/rs6000.c (rs6000_final_prescan_insn): Likewise.
575         * config/picochip/picochip.c (picochip_reorg): Likewise.
576         * config/arm/arm.c (require_pic_register): Likewise.
577         * config/mips/mips.c (mips16_gp_pseudo_reg): Likewise.
578         * config/bfin/bfin.c (gen_one_bundle): Likewise.
579
580 2012-09-19  Mark Kettenis  <kettenis@openbsd.org>
581
582         * config.gcc (hppa*-*-openbsd*): New target.
583         * config/pa/pa-openbsd.h: New file.
584         * config/pa/pa32-openbsd.h: New file.
585         * config/host-openbsd.c: Update copyright year.
586         (TRY_EXCEPT_VM_SPACE): Define for OpenBSD/hppa.
587
588 2012-09-19  Martin Jambor  <mjambor@suse.cz>
589
590         * ipa-prop.c (prune_expression_for_jf): New function.
591         (ipa_set_jf_constant): Use it.
592         (ipa_set_jf_arith_pass_through): Likewise.
593         (determine_known_aggregate_parts): Likewise.
594
595 2012-09-19  Steve Ellcey  <sellcey@mips.com>
596
597         * config.gcc (mips*-mti-elf*): New target.
598         * config/mips/mti-elf.h: New file.
599         * config/mips/t-mti-elf: New file.
600
601 2012-09-19  Dehao Chen  <dehao@google.com>
602
603         * toplev.c (general_init): Init block_locations.
604         * tree.c (tree_set_block): New.
605         (tree_block): Change to use LOCATION_BLOCK.
606         * tree.h (TREE_SET_BLOCK): New.
607         * final.c (reemit_insn_block_notes): Change to use LOCATION_BLOCK.
608         (final_start_function): Likewise.
609         * input.c (expand_location_1): Likewise.
610         * input.h (LOCATION_LOCUS): New.
611         (LOCATION_BLOCK): New.
612         (IS_UNKNOWN_LOCATION): New.
613         * fold-const.c (expr_location_or): Change to use new location.
614         * reorg.c (emit_delay_sequence): Likewise.
615         (try_merge_delay_insns): Likewise.
616         * modulo-sched.c (dump_insn_location): Likewise.
617         * lto-streamer-out.c (lto_output_location_bitpack): Likewise.
618         * lto-cgraph.c (output_node_opt_summary): Likewise.
619         * jump.c (rtx_renumbered_equal_p): Likewise.
620         * ifcvt.c (noce_try_move): Likewise.
621         (noce_try_store_flag): Likewise.
622         (noce_try_store_flag_constants): Likewise.
623         (noce_try_addcc): Likewise.
624         (noce_try_store_flag_mask): Likewise.
625         (noce_try_cmove): Likewise.
626         (noce_try_cmove_arith): Likewise.
627         (noce_try_minmax): Likewise.
628         (noce_try_abs): Likewise.
629         (noce_try_sign_mask): Likewise.
630         (noce_try_bitop): Likewise.
631         (noce_process_if_block): Likewise.
632         (cond_move_process_if_block): Likewise.
633         (find_cond_trap): Likewise.
634         * ipa-prop.c (ipa_set_jf_constant): Likewise.
635         (ipa_write_jump_function): Likewise.
636         * dwarf2out.c (add_src_coords_attributes): Likewise.
637         * expr.c (expand_expr_real): Likewise.
638         * tree-parloops.c (create_loop_fn): Likewise.
639         * recog.c (peep2_attempt): Likewise.
640         * function.c (free_after_compilation): Likewise.
641         (expand_function_end): Likewise.
642         (set_insn_locations): Likewise.
643         (thread_prologue_and_epilogue_insns): Likewise.
644         * print-rtl.c (print_rtx): Likewise.
645         * profile.c (branch_prob): Likewise.
646         * trans-mem.c (ipa_tm_scan_irr_block): Likewise.
647         * gimplify.c (gimplify_call_expr): Likewise.
648         * except.c (duplicate_eh_regions_1): Likewise.
649         * emit-rtl.c (try_split): Likewise.
650         (make_insn_raw): Likewise.
651         (make_debug_insn_raw): Likewise.
652         (make_jump_insn_raw): Likewise.
653         (make_call_insn_raw): Likewise.
654         (emit_pattern_after_setloc): Likewise.
655         (emit_pattern_after): Likewise.
656         (emit_debug_insn_after): Likewise.
657         (emit_pattern_before): Likewise.
658         (emit_insn_before_setloc): Likewise.
659         (emit_jump_insn_before): Likewise.
660         (emit_call_insn_before_setloc): Likewise.
661         (emit_call_insn_before): Likeise.
662         (emit_debug_insn_before_setloc): Likewise.
663         (emit_copy_of_insn_after): Likewise.
664         (insn_locators_alloc): Remove.
665         (insn_locators_finalize): Remove.
666         (insn_locators_free): Remove.
667         (set_curr_insn_source_location): Remove.
668         (get_curr_insn_source_location): Remove.
669         (set_curr_insn_block): Remove.
670         (get_curr_insn_block): Remove.
671         (locator_scope): Remove.
672         (insn_scope): Change to use new location.
673         (locator_location): Remove.
674         (insn_line): Change to use new location.
675         (locator_file): Remove.
676         (insn_file): Change to use new location.
677         (locator_eq): Remove.
678         (insn_locations_init): New.
679         (insn_locations_finalize): New.
680         (set_curr_insn_location): New.
681         (curr_insn_location): New.
682         * cfgexpand.c (gimple_assign_rhs_to_tree): Change to use new location.
683         (expand_gimple_cond): Likewise.
684         (expand_call_stmt): Likewise.
685         (expand_gimple_stmt_1): Likewise.
686         (expand_gimple_basic_block): Likewise.
687         (construct_exit_block): Likewise.
688         (gimple_expand_cfg): Likewise.
689         * cfgcleanup.c (try_forward_edges): Likewise.
690         * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
691         (dump_scope_block): Likewise.
692         (remove_unused_locals): Likewise.
693         * rtl.c (rtx_equal_p_cb): Likewise.
694         (rtx_equal_p): Likewise.
695         * rtl.h (XUINT): New.
696         (INSN_LOCATOR): Remove.
697         (CURR_INSN_LOCATION): Remove.
698         (INSN_LOCATION): New.
699         (INSN_HAS_LOCATION): New.
700         * tree-inline.c (remap_gimple_op_r): Change to use new location.
701         (copy_tree_body_r): Likewise.
702         (copy_phis_for_bb): Likewise.
703         (expand_call_inline): Likewise.
704         * tree-streamer-in.c (lto_input_ts_exp_tree_pointers): Likewise.
705         * tree-streamer-out.c (write_ts_decl_minimal_tree_pointers): Likewise.
706         * gimple-streamer-out.c (output_gimple_stmt): Likewise.
707         * combine.c (try_combine): Likewise.
708         * tree-outof-ssa.c (set_location_for_edge): Likewise.
709         (insert_partition_copy_on_edge): Likewise.
710         (insert_value_copy_on_edge): Likewise.
711         (insert_rtx_to_part_on_edge): Likewise.
712         (insert_part_to_rtx_on_edge): Likewise.
713         * basic-block.h (edge_def): Remove field.
714         * gimple.h (gimple_statement_base): Remove field.
715         (gimple_bb): Change to use new location.
716         (gimple_set_block): Likewise.
717         (gimple_has_location): Likewise.
718         * tree-cfg.c (make_cond_expr_edges): Likewise.
719         (make_goto_expr_edges): Likewise.
720         (gimple_can_merge_blocks_p): Likewise.
721         (move_stmt_op): Likewise.
722         (move_block_to_fn): Likewise.
723         * config/alpha/alpha.c (alpha_output_mi_thunk_osf): Likewise.
724         * config/sparc/sparc.c (sparc_output_mi_thunk): Likewise.
725         * config/i386/i386.c (x86_output_mi_thunk): Likewise.
726         * config/tilegx/tilegx.c (tilegx_output_mi_thunk): Likewise.
727         * config/sh/sh.c (sh_output_mi_thunk): Likewise.
728         * config/ia64/ia64.c (ia64_output_mi_thunk): Likewise.
729         * config/rs6000/rs6000.c (rs6000_output_mi_thunk): Likewise.
730         * config/score/score.c (score_output_mi_thunk): Likewise.
731         * config/tilepro/tilepro.c (tilepro_asm_output_mi_thunk): Likewise.
732         * config/mips/mips.c (mips_output_mi_thunk): Likewise.
733         * cfgrtl.c (unique_locus_on_edge_between_p): Likewise.
734         (unique_locus_on_edge_between_p): Likewise.
735         (emit_nop_for_unique_locus_between): Likewise.
736         (force_nonfallthru_and_redirect): Likewise.
737         (fixup_reorder_chain): Likewise.
738         (cfg_layout_merge_blocks): Likewise.
739         * stmt.c (emit_case_nodes): Likewise.
740
741 2012-09-19  Bernd Schmidt  <bernds@codesourcery.com>
742
743         * dbgcnt.def (sched_breakdep): New counter.
744         * haifa-sched.c (update_insn_after_change): New static function,
745         broken out of haifa_change_pattern.
746         (haifa_change_pattern): Call it.
747         (dep_t heap vecs): Declare.
748         (INSN_COST): Define earlier.
749         (next_cycle_replace_deps, next_cycle_apply): New static variables.
750         (apply_replacement): New static function.
751         (recompute_todo_spec): New argument FOR_BACKTRACK.  All callers
752         changed.  Handle DEP_REPLACE deps.
753         (contributes_to_priority_p): False for replaceable deps.
754         (must_restore_pattern_p, restore_pattern): New static functions.
755         (schedule_insn): Use them.  Apply replacements for broken deps.
756         (struct haifa_saved_data): Add new fields to keep track of
757         replacements.
758         (save_backtrack_point): Initialize them.
759         (undo_replacements_for_backtrack): New static function.
760         (restore_last_backtrack_point, free_topmost_backtrack_point):
761         Use it and keep track of replacements.
762         (perform_replacements_new_cycle, undo_all_replacements): New static
763         functions.
764         (schedule_block): Call these two as necessary.  Call
765         find_modifiable_mems.
766         (try_ready): Tweak the assert.  Check for DEP_POSTPONED.
767         * sched-deps.c: Include "emit-rtl.h".
768         (init_dep_1): Initialize DEP_NONREG, DEP_MULTIPLE and DEP_REPLACE.
769         (dep_spec_p): True for DEP_REPLACE deps.
770         (mark_as_hard): New static variable.
771         (update_dep): Update DEP_NONREG and DEP_MULTIPLE.
772         (add_dependence_list): New argument hard.  All callers changed.  Set
773         and clear mark_as_hard around function body.
774         (add_dependence_list_and_free): Likewise.
775         (haifa_note_mem_dep): Set DEP_NONREG.
776         (haifa_note_dep): Likewise if mark_as_hard is true.
777         (sched_analyze_insn): Switch loop with if statement testing for
778         sel_sched_p.
779         (struct mem_inc_info): New.
780         (attempt_change, parse_add_or_inc, find_inc, find_mem): New static
781         functions.
782         (find_modifiable_mems): New function.
783         * sched-int.h (struct dep_replacement): New.
784         (struct _dep): Add replace, nonreg and multiple fields.  Make type and
785         cost bitfields.
786         (UNKNOWN_DEP_COST): Change to match the bitfield.
787         (DEP_NONREG, DEP_MULTIPLE, DEP_REPLACE): New macros.
788         (DEP_POSTPONED): New macro.
789         (DEP_CANCELLED): Renumber.
790         (find_modifiable_mems): Declare.
791         (enum SCHED_FLAGS): Add DONT_BREAK_DEPENDENCIES.
792         * sched-rgn.c (init_ready_list): Set TODO_SPEC here.
793         (new_ready): Don't set HARD_DEP, use DEP_POSTPONED.
794         (debug_dependencies): Dump DEP_NONREG and DEP_MULTIPLE.
795         * Makefile.in (sched-deps.o): Update dependencies.
796         * config/c6x/c6x.c (in_hwloop): New static variable.
797         (c6x_set_sched_flags): If it is true, add DONT_BREAK_DEPENDENCIES.
798         (hwloop_optimize): Set and clear it around preliminary scheduling pass.
799
800 2012-09-19  Tulio Magno Quites Machado Filho  <tuliom@linux.vnet.ibm.com>
801
802         * config/rs6000/rs6000-builtin.def: Add __builtin_ppc_get_timebase
803         and __builtin_ppc_mftb.
804         * config/rs6000/rs6000.c (rs6000_expand_zeroop_builtin): New function
805         to expand an expression that calls a built-in without arguments.
806         (rs6000_expand_builtin): Add __builtin_ppc_get_timebase and
807         __builtin_ppc_mftb.
808         (rs6000_init_builtins): Likewise.
809         * config/rs6000/rs6000.md (rs6000_get_timebase): New pattern.
810         (rs6000_get_timebase_ppc32): New pattern.
811         (rs6000_mftb_<mode>): New pattern.
812
813         * doc/extend.texi (PowerPC Built-in Functions): New section.
814         (PowerPC AltiVec/VSX Built-in Functions): Move some built-ins
815         unrelated to Altivec/VSX to the new section.
816
817 2012-09-19  David Edelsohn  <dje.gcc@gmail.com>
818
819         * rs6000.md (mac*): Remove extra spaces.
820         (mulhw*): Same.
821
822 2012-09-19  Oleg Endo  <olegendo@gcc.gnu.org>
823
824         PR target/54089
825         * config/sh/predicates.md (arith_reg_or_t_reg_operand): New predicate.
826         * config/sh/sh.md (*rotcr): Use arith_reg_or_t_reg_operand predicate.
827         Handle the case where one of the operands is T_REG.
828         Add new pattern to handle MSB extraction.
829
830 2012-09-19  Oleg Endo  <olegendo@gcc.gnu.org>
831
832         PR target/54236
833         * config/sh/sh.md (*addc): Add pattern to handle one bit left shifts.
834
835 2012-09-19  Oleg Endo  <olegendo@gcc.gnu.org>
836
837         * config/sh/sh.md (prologue, epilogue): Use braced strings.
838
839 2012-09-19  Eric Botcazou  <ebotcazou@adacore.com>
840
841         PR rtl-optimization/54290
842         * reload1.c (choose_reload_regs): Also take into account secondary MEMs
843         to remove address replacements for inherited reloads.
844         (replaced_subreg): Move around.
845
846 2012-09-19  David Edelsohn  <dje.gcc@gmail.com>
847
848         * config/rs6000/aix61.h (TARGET_DEFAULT): Add MASK_PPC_GPOPT,
849         MASK_PPC_GFXOPT, and MASK_MFCRF.
850
851 2012-09-19  Richard Guenther  <rguenther@suse.de>
852
853         * passes.c (init_optimization_passes): For -Og move
854         pass_object_sizes inbetween CCP and copyprop.
855
856 2012-09-19  Richard Guenther  <rguenther@suse.de>
857
858         * tree-ssa-forwprop.c (get_prop_source_stmt): Simplify.
859
860 2012-09-19  Jan Hubicka  <jh@suse.cz>
861
862         * symtab.c (insert_to_assembler_name_hash): Do not insert
863         register vars.
864         (unlink_from_assembler_name_hash): NULL out pointers of unlinked var.
865         (symtab_prevail_in_asm_name_hash): New.
866         (symtab_initialize_asm_name_hash): Break out from ...
867         (symtab_node_for_asm): ... here.
868         (dump_symtab_base): Dump LTO file data.
869         (verify_symtab_base): Register vars are not in symtab.
870         * cgraph.h (symtab_initialize_asm_name_hash,
871         symtab_prevail_in_asm_name_hash): New functions.
872         (symtab_real_symbol_p): New inline.
873         * lto-symtab.c: Do not include gt-lto-symtab.h.
874         (lto_symtab_entry_def): Remove.
875         (lto_symtab_entry_t): Remove.
876         (lto_symtab_identifiers): Remove.
877         (lto_symtab_free): Remove.
878         (lto_symtab_entry_hash): Remove.
879         (lto_symtab_entry_eq): Remove.
880         (lto_symtab_entry_marked_p): Remove.
881         (lto_symtab_maybe_init_hash_table): Remove.
882         (resolution_guessed_p, set_resolution_guessed): New functions.
883         (lto_symtab_register_decl): Only set resolution info.
884         (lto_symtab_get, lto_symtab_get_resolution): Remove.
885         (lto_symtab_merge): Reorg to work across symtab; do nothing if decls
886         are same.
887         (lto_symtab_resolve_replaceable_p): Reorg to work on symtab.
888         (lto_symtab_resolve_can_prevail_p): Likewise; only real symbols can
889         prevail.
890         (lto_symtab_resolve_symbols): Reorg to work on symtab.
891         (lto_symtab_merge_decls_2): Likewise.
892         (lto_symtab_merge_decls_1): Likewise; add debug dumps.
893         (lto_symtab_merge_decls): Likewise; do not merge at ltrans stage.
894         (lto_symtab_merge_cgraph_nodes_1): Reorg to work on symtab.
895         (lto_symtab_merge_cgraph_nodes): Likewise; do not merge at ltrans
896         stage.
897         (lto_symtab_prevailing_decl): Rewrite to lookup into symtab.
898         * lto-streaer.h (lto_symtab_free): Remove.
899         * lto-cgraph.c (add_references): Cleanup.
900         * varpool.c (varpool_assemble_decl): Skip hard regs.
901
902 2012-09-19  Richard Guenther  <rguenther@suse.de>
903
904         PR other/53316
905         * common/common-target.h (OPT_LEVELS_1_PLUS_NOT_DEBUG): Add.
906
907 2012-09-19  Richard Guenther  <rguenther@suse.de>
908
909         PR other/53316
910         * common.opt (optimize_debug): New variable.
911         (Og): New optimization level.
912         * doc/invoke.texi (Og): Document.
913         * opts.c (maybe_default_option): Add debug parameter.
914         (maybe_default_options): Likewise.
915         (default_options_optimization): Handle -Og.
916         (common_handle_option): Likewise.
917         * passes.c (gate_all_optimizations): Do not run with -Og.
918         (gate_all_optimizations_g): New gate, run with -Og.
919         (pass_all_optimizations_g): New container pass, run with -Og.
920         (init_optimization_passes): Schedule pass_all_optimizations_g
921         alongside pass_all_optimizations.
922
923 2012-09-19  Richard Guenther  <rguenther@suse.de>
924
925         PR tree-optimization/54132
926         * tree-loop-distribution.c (classify_partition): Properly
927         check dependences for memmove.
928         * tree-data-ref.h (compute_affine_dependence): Declare.
929         * tree-data-ref.c (compute_affine_dependence): Export.
930
931 2012-09-19  Zhenqiang Chen <zhenqiang.chen@arm.com>
932
933         PR middle-end/54364
934         * bb-reorder.c (connect_better_edge_p): New added.
935         (find_traces_1_round): When optimizing for size, ignore edge frequency
936         and probability, and handle all in one round.
937         (bb_to_key): Use bb->index as key when optimizing for size.
938         (better_edge_p): The bb with smaller index is better when optimizing
939         for size.
940         (connect_traces): When optimizing for size, connect block n with
941         block n + 1; connect trace m with trace m + 1 if falling through.
942         (gate_handle_reorder_blocks): Enable bbro when optimizing for -Os.
943
944 2012-09-19  Bin Cheng  <bin.cheng@arm.com>
945
946         * fold-const.c (fold_truth_andor): Remove duplicated check on
947         BRANCH_COST.
948
949 2012-09-18  Eric Botcazou  <ebotcazou@adacore.com>
950
951         PR middle-end/54617
952         * expr.c (store_field): Handle a PARALLEL in more cases.
953
954 2012-09-18  Segher Boessenkool  <segher@kernel.crashing.org>
955
956         * config/rs6000/rs6000.md (sminsi3, smaxsi3, uminsi3, umaxsi3): Delete.
957         (abssi2, abs<mode>2_isel, nabs<mode>2_isel, abssi2_nopower,
958         nabs_nopower): Delete.
959         (absdi2, absdi2_internal, nabsdi2): Delete.
960         (smindi3, smaxdi3, umindi3, umaxdi3): Delete.
961
962 2012-09-18  Georg-Johann Lay  <avr@gjlay.de>
963
964         * config/avr/avr.md: Tidy up empty "".  Fix C code indentation.
965         * config/avr/avr-fixed.md: Ditto.
966
967 2012-09-18  Maciej W. Rozycki  <macro@codesourcery.com>
968
969         * config/rs6000/rs6000.c (print_operand) <'c'>: Remove.
970         * config/rs6000/spe.md: Remove a leftover comment.
971
972 2012-09-18  Jakub Jelinek  <jakub@redhat.com>
973
974         PR target/54592
975         * config/i386/i386.c (ix86_rtx_costs): Limit > UNITS_PER_WORD
976         AND/IOR/XOR cost calculation to MODE_INT class modes.
977
978 2012-09-18 Thomas Quinot  <quinot@adacore.com>
979
980         * doc/invoke.texi: Document -fada-spec-parent.
981
982 2012-09-18  Jakub Jelinek  <jakub@redhat.com>
983
984         PR tree-optimization/54610
985         * tree-ssa-forwprop.c: Include optabs.h.  Don't include
986         tree-vectorizer.h.
987         (simplify_vector_constructor): Don't use vect_gen_perm_mask,
988         instead create the mask constant here.
989         * Makefile.in (tree-ssa-forwprop.o): Depend on $(OPTABS_H).
990         Don't depend on $(TREE_VECTORIZER_H).
991
992 2012-09-18  Florian Weimer  <fweimer@redhat.com>
993
994         * Makefile.in (BASIC_BLOCK_H): Add cfg-flags.def.
995
996 2012-09-18  Richard Guenther  <rguenther@suse.de>
997
998         * statistics.h (CXX_MEM_STAT_INFO): New define.
999         * gimple.h (gimple_build_assign_with_ops_stat,
1000         gimple_build_assign_with_ops, gimple_build_assign_with_ops3):
1001         Turn into an overload of the function gimple_build_assign_with_ops.
1002         * gimple.c (gimple_build_assign_with_ops_stat): Rename to ...
1003         (gimple_build_assign_with_ops): ... this.
1004         * tree-ssa-loop-im.c (move_computations_stmt): Adjust.
1005         * tree-ssa-math-opts.c (convert_mult_to_fma): Likewise.
1006         * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
1007         (vect_permute_load_chain): Likewise.
1008         * tree-vect-generic.c (expand_vector_divmod): Likewise.
1009         * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Likewise.
1010         (vect_recog_divmod_pattern): Likewise.
1011         (vect_recog_mixed_size_cond_pattern): Likewise.
1012         (adjust_bool_pattern): Likewise.
1013         * tree-vect-slp.c (vect_create_mask_and_perm): Likewise.
1014         * tree-vect-stmts.c (vectorizable_operation): Likewise.
1015         (permute_vec_elements): Likewise.
1016         (vectorizable_load): Likewise.
1017
1018 2012-09-17  Paul Koning  <ni1d@arrl.net>
1019
1020         * doc/invoke.text (-feliminate-unused-debug-types): Update to
1021         reflect that this is enabled by default.
1022
1023 2012-09-17  Ben Cheng  <bccheng@google.com
1024
1025         * config/arm/linux-elf.h (LINUX_TARGET_LINK_SPEC): Suppress the
1026         dynamic linker commands for statically linked programs.
1027
1028 2012-09-17  Ulrich Weigand  <ulrich.weigand@linaro.org>
1029
1030         * config/arm/arm.c (arm_rtx_costs_1): Handle vec_extract and vec_set
1031         patterns.
1032         * config/arm/arm.md ("vec_set<mode>_internal"): Support memory source
1033         operands, implemented via vld1 instruction.
1034         ("vec_extract<mode>"): Support memory destination operands, implemented
1035         via vst1 instruction.
1036         ("neon_vst1_lane<mode>"): Use UNSPEC_VST1_LANE instead of vec_select.
1037         * config/arm/predicates.md ("neon_lane_number"): Remove.
1038
1039 2012-09-17  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
1040             Ulrich Weigand  <ulrich.weigand@linaro.org>
1041
1042         * config/arm/arm.c (output_move_neon): Update comment.
1043         Use vld1.64/vst1.64 instead of vldm/vstm where possible.
1044         (neon_vector_mem_operand): Support double-word modes.
1045         * config/arm/neon.md (*neon_mov VD): Call output_move_neon
1046         instead of output_move_vfp.  Change constraint from Uv to Un.
1047
1048 2012-09-17  Richard Guenther  <rguenther@suse.de>
1049
1050         PR lto/54598
1051         * tree-streamer-in.c (unpack_ts_real_cst_value_fields): Use ggc'ed
1052         FIXED_VALUE_TYPE instead of struct fixed_value.
1053
1054 2012-09-17  Georg-Johann Lay  <avr@gjlay.de>
1055
1056         * config/avr/avr.c (CONST_FIXED_P): Remove define.
1057         * config/avr/avr.md (add<mode>3): Use CONST_FIXED_P.
1058
1059 2012-09-17  Georg-Johann Lay  <avr@gjlay.de>
1060
1061         PR target/54607
1062         * config.gcc (tm_file,avr): Add avr/avr-arch.h.
1063         * config/avr/t-avr (gen-avr-mmcu-texi): Use CC_FOR_BUILD to
1064         compile.  Don't depend on TM_H.  Use CFLAGS_FOR_BUILD.
1065         * config/avr/avr.h (avr_arch, base_arch_s, mcu_type_s): Source out
1066         to...
1067         * config/avr/avr-arch.h: ...this new file.
1068         * config/avr/gen-avr-mmcu-texi.c: Include avr-arch.h, stdio.h,
1069         stdlib.h.
1070         * comparator: Make letters smaller than digits.
1071         * config/avr/avr-devices.c: Don't include headers if used in
1072         gen-avr-mmcu-texi.c.
1073         * doc/avr-mmcu.texi: Regenerate.
1074
1075 2012-09-17  Georg-Johann Lay  <avr@gjlay.de>
1076
1077         * rtl.h (CONST_FIXED_P): New predicate macro.
1078
1079 2012-09-17  Eric Botcazou  <ebotcazou@adacore.com>
1080
1081         * tree-cfgcleanup. (cleanup_control_expr_graph) <GIMPLE_COND>: Remove
1082         code doing propagation from degenerate PHI nodes.
1083         * tree-ssa-loop-ivcanon.c (propagate_into_all_uses): New function.
1084         (propagate_constants_for_unrolling): Likewise.
1085         (tree_unroll_loops_completely): If the current loop has been unrolled
1086         and its father isn't the entire function, propagate constants within
1087         the new basic blocks by means of propagate_constants_for_unrolling.
1088
1089 2012-09-17  Jakub Jelinek  <jakub@redhat.com>
1090
1091         PR tree-optimization/54563
1092         * tree-ssa-math-opts.c (execute_cse_sincos): Call
1093         gimple_purge_dead_eh_edges if last call has been changed.
1094
1095 2012-09-17  Georg-Johann Lay  <avr@gjlay.de>
1096
1097         PR target/54222
1098         * config/avr/avr.c (avr_out_plus_symbol): Fix typo if PLUS and PSImode.
1099         (avr_out_plus_1): Remove log comments from assembler output.
1100
1101 2012-09-17  Ruben Buchatskiy  <ruben@ispras.ru>
1102
1103         * config/arm/vfp.md (*thumb2_movdf_vfp): Require one of the operands
1104         to be a register.
1105
1106 2012-09-16  Richard Sandiford  <rdsandiford@googlemail.com>
1107
1108         * calls.c (expand_call): Use emit_group_move for PARALLEL->PARALLEL
1109         moves.
1110
1111 2012-09-15  Tom de Vries  <tom@codesourcery.com>
1112
1113         * tree-vrp.c (extract_range_from_binary_expr_1): Fix bug in handling of
1114         LSHIFT_EXPR with shift range.  Handle more LSHIFT_EXPR cases with shift
1115         range.
1116
1117 2012-09-15  Georg-Johann Lay  <avr@gjlay.de>
1118
1119         PR target/54222
1120         * config/avr/avr-fixed.md (ALL2S, ALL4S, ALL24S, ALL124S,
1121         ALL124U): New mode iterators.
1122         (<code_stdname><mode>3): New insns for SS_PLUS, SS_MINUS.
1123         (<code_stdname><mode>3): New insns for US_PLUS, US_MINUS.
1124         (usneg<mode>2): New insns.
1125         (<code_stdname><mode>2): New expanders for SS_NEG, SS_ABS.
1126         (*<code_stdname><mode>2): New insns for SS_NEG, SS_ABS.
1127         * config/avr/avr-dimode.md (ALL8U, ALL8S): New mode iterators.
1128         (avr_out_plus64, avr_out_minus64): Use avr_out_plus instead.
1129         (<code_stdname><mode>3): New expanders for SS_PLUS, SS_MINUS.
1130         (<code_stdname><mode>3): New expanders for US_PLUS, US_MINUS.
1131         (<code_stdname><mode>3_insn): New insns.
1132         (<code_stdname><mode>3_const_insn): New insns.
1133         * config/avr/avr.md (cc): Add: plus. Remove: out_plus,
1134         out_plus_noclobber, minus.
1135         (length): Add: plus.  Remove: out_plus, out_plus_noclobber,
1136         plus64, minus, minus64.
1137         (abelian): New code_attr.
1138         (code_stdname): Handle: ss_plus, ss_minus, ss_neg, ss_abs,
1139         us_plus, us_minus, us_neg.
1140         (*add<mode>3, add<mode>3_clobber, add<mode>3, addpsi3, sub<mode>3):
1141         Use avr_out_plus to output.
1142         * config/avr/avr-protos.h (avr_out_plus): Change prototype.
1143         (avr_out_plus_noclobber, avr_out_minus): Remove.
1144         (avr_out_plus64, avr_out_minus64): Remove.
1145         * config/avr/avr.c (avr_out_plus_1): Add new default arguments
1146         code_sat, sign.  Saturate after operation if code_sat != UNKNOWN.
1147         (avr_out_plus_symbol): New static function.
1148         (avr_out_plus): Rewrite.
1149         (adjust_insn_length): Handle: ADJUST_LEN_PLUS.  Remove handling
1150         of: ADJUST_LEN_OUT_PLUS, ADJUST_LEN_PLUS64, ADJUST_LEN_MINUS,
1151         ADJUST_LEN_MINUS64, ADJUST_LEN_OUT_PLUS_NOCLOBBER.
1152         (notice_update_cc): Handle: CC_PLUS.  Remove handling of: CC_MINUS,
1153         CC_OUT_PLUS, CC_OUT_PLUS_NOCLOBBER
1154         (avr_out_plus_noclobber, avr_out_minus): Remove.
1155         (avr_out_plus64, avr_out_minus64): Remove.
1156         (avr_print_operand): Print raw REGNO if 'r' is used with REG.
1157
1158 2012-09-15  Oleg Endo  <olegendo@gcc.gnu.org>
1159
1160         * config/sh/sh.c (sh_rtx_costs): Add handling of MEM, SIGN_EXTEND,
1161         ZERO_EXTEND and PARALLEL cases.
1162         (sh_address_cost): Correct rtx parsing and tweak cost estimations.
1163
1164 2012-09-14  Sandra Loosemore  <sandra@codesourcery.com>
1165
1166         * doc/tm.texi.in (Stack Arguments): Update obsolete references
1167         to current_function_outgoing_args_size.
1168         (Function Entry): Likewise for current_function_pops_args,
1169         current_function_pretend_args_size,
1170         current_function_outgoing_args_size, and
1171         current_function_epilogue_delay_list.
1172         (Misc): Fix garbled sentence referencing nonexistent
1173         current_function_leaf_function.
1174         * doc/tm.texi: Regenerated.
1175
1176 2012-09-14  Dehao Chen  <dehao@google.com>
1177
1178          * tree-eh.c (goto_queue_node): New field.
1179         (record_in_goto_queue): New parameter.
1180         (record_in_goto_queue_label): New parameter.
1181         (lower_try_finally_dup_block): New parameter.
1182         (maybe_record_in_goto_queue): Update source location.
1183         (lower_try_finally_copy): Likewise.
1184         (honor_protect_cleanup_actions): Likewise.
1185         * gimplify.c (gimplify_expr): Reset the location to unknown.
1186
1187 2012-09-14  David Edelsohn  <dje.gcc@gmail.com>
1188
1189         * configure: Regenerated.
1190
1191 2012-09-14  Walter Lee  <walt@tilera.com>
1192
1193         * doc/invoke.texi (Option Summary): fix typesetting for -mcpu
1194         option for TILEPro and TILE-Gx.
1195         (TILE-Gx Options): Fix grammar and spellings in documentation for
1196         -mcmodel.
1197
1198 2012-09-14  Marc Glisse  <marc.glisse@inria.fr>
1199
1200         PR c++/54427
1201         * fold-const.c (fold_unary_loc): Disable for VECTOR_TYPE.
1202         (fold_binary_loc): Likewise.
1203         * gimple-fold.c (and_comparisons_1): Handle VECTOR_TYPE.
1204         (or_comparisons_1): Likewise.
1205
1206 2012-09-14  Richard Earnshaw  <rearnsha@arm.com>
1207
1208         PR target/54516
1209         PR rtl-optimization/54540
1210         * reload.c (find_dummy_reload): Don't use OUT as a reload reg
1211         for IN if it overlaps a fixed register.
1212
1213 2012-09-14  Eric Botcazou  <ebotcazou@adacore.com>
1214
1215         PR rtl-optimization/44194
1216         * calls.c (expand_call): In the PARALLEL case, copy the return value
1217         into pseudos instead of spilling it onto the stack.
1218         * emit-rtl.c (adjust_address_1): Rename ADJUST into ADJUST_ADDRESS and
1219         add new ADJUST_OBJECT parameter.
1220         If ADJUST_OBJECT is set, drop the underlying object if it cannot be
1221         proved that the adjusted memory access is still within its bounds.
1222         (adjust_automodify_address_1): Adjust call to adjust_address_1.
1223         (widen_memory_access): Likewise.
1224         * expmed.c (store_bit_field_1): Call adjust_bitfield_address instead
1225         of adjust_address.  Do not drop the underlying object of a MEM.
1226         (store_fixed_bit_field): Likewise.
1227         (extract_bit_field_1): Likewise.  Fix oversight in recursion.
1228         (extract_fixed_bit_field): Likewise.
1229         * expr.h (adjust_address_1): Adjust prototype.
1230         (adjust_address): Adjust call to adjust_address_1.
1231         (adjust_address_nv): Likewise.
1232         (adjust_bitfield_address): New macro.
1233         (adjust_bitfield_address_nv): Likewise.
1234         * expr.c (expand_assignment): Handle a PARALLEL in more cases.
1235         (store_expr): Likewise.
1236         (store_field): Likewise.
1237
1238         * dse.c: Fix typos in the head comment.
1239
1240 2012-09-14  Christian Bruel  <christian.bruel@st.com>
1241
1242         PR target/54546
1243         * config/sh/sh-protos.h (sh_need_epilogue): Delete.
1244         (sh_can_use_simple_return_p): Declare.
1245         * config/sh/sh.c (sh_can_use_simple_return_p): Define.
1246         (sh_need_epilogue, sh_need_epilogue_known): Delete.
1247         (sh_output_function_epilogue): Remove sh_need_epilogue_known.
1248         * config/sh/sh.md (simple_return, return): Define.
1249         (epilogue): Use inline return rtl.
1250         (sh_expand_epilogue): Cleanup parameters boolean type.
1251         * config/sh/iterators.md (any_return): New iterator.
1252
1253 2012-09-14  Christian Bruel  <christian.bruel@st.com>
1254
1255         * config/sh/predicates.md (t_reg_operand): Check REG_P for SUBREG.
1256         * config/sh/sh.c (sequence_insn_p): Check INSNP_P for SEQUENCE.
1257
1258 2012-09-14  Jakub Jelinek  <jakub@redhat.com>
1259
1260         PR target/54564
1261         * config/i386/sse.md (fmai_vmfmadd_<mode>): Use (match_dup 1)
1262         instead of (match_dup 0) as second argument to vec_merge.
1263         (*fmai_fmadd_<mode>, *fmai_fmsub_<mode>): Likewise.
1264         Remove third alternative.
1265         (*fmai_fnmadd_<mode>, *fmai_fnmsub_<mode>): Likewise.  Negate
1266         operand 2 instead of operand 1, but put it as first argument of fma.
1267         * config/i386/fmaintrin.h (_mm_fnmadd_sd, _mm_fnmadd_ss,
1268         _mm_fnmsub_sd, _mm_fnmsub_ss): Negate the second argument instead
1269         of the first.
1270
1271 2012-09-14  Richard Guenther  <rguenther@suse.de>
1272
1273         PR tree-optimization/54565
1274         * passes.c (init_optimization_passes): Adjust comments.
1275         (execute_function_todo): Do not execute execute_update_addresses_taken
1276         before processing TODO_rebuild_alias.
1277         * tree-ssa-ccp.c (do_ssa_ccp): Schedule TODO_update_address_taken.
1278
1279 2012-09-14  Richard Guenther  <rguenther@suse.de>
1280
1281         * tree-vrp.c (register_new_assert_for): Simplify for backward walk.
1282         (find_assert_locations_1): Walk the basic-block backwards, properly
1283         add/prune from live.  Use live for asserts derived from stmts.
1284
1285 2012-09-14  Marc Glisse  <marc.glisse@inria.fr>
1286
1287         * tree-ssa-forwprop.c (simplify_bitfield_ref): Call
1288         get_prop_source_stmt.
1289         (simplify_permutation): Likewise.
1290         (simplify_vector_constructor): Likewise.
1291
1292 2012-09-14  Richard Guenther  <rguenther@suse.de>
1293
1294         * builtin-types.def (BT_FN_CONST_STRING): Add.
1295         * builtins.def (BUILT_IN_FILE, BUILT_IN_FUNCTION,
1296         BUILT_IN_LINE): New builtins.
1297         * gimplify.c (gimplify_call_expr): Expand them.
1298         * doc/extend.texi (__builtin_LINE, __builtin_FUNCTION,
1299         __builtin_FILE): Document.
1300
1301 2012-09-13  Anthony Green  <green@moxielogic.com>
1302
1303         * config/moxie/moxie.h (LINK_SPEC): Add bi-endian support.
1304         (MULTILIB_DEFAULTS): Define.
1305         (ASM_SPEC): Define.
1306         (BYTES_BIG_ENDIAN, WORDS_BIG_ENDIAN): Add bi-endian support.
1307         (TARGET_CPU_CPP_BUILTINS): Add __MOXIE_LITTLE_ENDIAN__ and
1308         __MOXIE_BIG_ENDIAN__.
1309         * config/moxie/t-moxie (MULTILIB_DIRNAMES, MULTILIB_OPTIONS): Define.
1310         * config/moxie/moxie.opt: New file.
1311         * doc/invoke.texi (Moxie Options): Add section documenting -mel
1312         and -meb.
1313
1314 2012-09-13  Paolo Carlini  <paolo.carlini@oracle.com>
1315             Manuel López-Ibáñez  <manu@gcc.gnu.org>
1316
1317         PR c++/53210
1318         * doc/invoke.texi ([Winit-self]): Document as enabled by -Wall in C++.
1319
1320 2012-09-13  Eric Botcazou  <ebotcazou@adacore.com>
1321
1322         * config/sparc/predicates.md (input_operand): Do not consider TImode
1323         constants as 1-instruction integer constants.
1324         Use register_or_zero_operand instead of register_operand and tidy up.
1325         * config/sparc/sparc.md (movti): New expander.
1326         (movti_insn_sp64): New instruction.
1327         (movti_insn_sp64_hq): Likewise.
1328         (TImode splitters): New splitters.
1329         * config/sparc/sparc.c (sparc_expand_move) <TImode>: New case.
1330         (sparc_legitimate_address_p): Return 0 for REG+REG in TImode.
1331
1332         * config/sparc/sparc-protos.h (arith_double_4096_operand): Delete.
1333         (arith_4096_operand): Likewise.
1334         (zero_operand): Likewise.
1335         (fp_zero_operand): Likewise.
1336         (reg_or_0_operand): Likewise.
1337
1338 2012-09-13  Jakub Jelinek  <jakub@redhat.com>
1339
1340         * configure.ac (CXXFLAGS): Remove -O2 when not bootstrapping.
1341         * configure: Regenerated.
1342
1343 2012-08-13  Uros Bizjak  <ubizjak@gmail.com>
1344
1345         * config/i386/i386.md (prefetch): Do not assert mode of operand 0.
1346         (*prefetch_sse_<mode>): Do not set mode of address_operand predicate.
1347         Rename to ...
1348         (*prefetch_sse): ... this.
1349         (*prefetch_3dnow_<mode>): Do not set mode of address_operand predicate.
1350         Rename to ...
1351         (*prefetch_3dnow): ... this.
1352
1353 2012-09-13  Steven Bosscher  <steven@gcc.gnu.org>
1354
1355         * ipa-pure-const.c (state_from_flags, local_pure_const): Use
1356         current_function_name instead of lang_hooks.decl_printable_name.
1357
1358         * function.h (fndecl_name): New prototype.
1359         * function.c (fndecl_name): New function.
1360         * vecir.h (cgraph_node_p): New standard IR VEC type.
1361         * trans-mem.c (cgraph_node_p): No need anymore to define it here.
1362         * ipa-utils.h (ipa_get_nodes_in_cycle): New prototype.
1363         * ipa-utils.c (ipa_get_nodes_in_cycle): New function.
1364         * ipa-reference.c: Don't include langhooks.h, and certainly not twice.
1365         Fix many formatting issues (long lines, short lines, spacing, etc.).
1366         (get_static_name): Use fndecl_name.
1367         (dump_static_vars_set_to_file): New function split out from propagate.
1368         (union_static_var_sets): New function, union two sets and collapse
1369         to all_module_statics as quickly as possible.
1370         (intersect_static_var_sets): New function, similar to above.
1371         (copy_static_var_set): Renamed from copy_global_bitmap and rewritten
1372         to allocate a copy on the same bitmap_obstack as the source set.
1373         (propagate_bits): Simplify, and clarify by using union_static_var_sets.
1374         (generate_summary): Remove bm_temp.  Print UID of promotable globals.
1375         (read_write_all_from_decl): Use pass-by-reference, bless C++.
1376         (get_read_write_all_from_node): New function, split out from propagate.
1377         (propagate): Simplify and clarify with helper functions.  Use
1378         ipa_get_nodes_in_cycle to walk all nodes in a reduced node.
1379         (ipa_reference_read_optimization_summary): Use fndecl_name instead of
1380         lang_hooks.decl_printable_name.
1381
1382         * rtl.h (print_rtl_single_with_indent): New prototype.
1383         * print-rtl.c (print_rtl_single_with_indent): New function.
1384         * cfghooks.h (empty_block_p, split_block_before_cond_jump): New hooks.
1385         * cfghooks.c (empty_block_p, split_block_before_cond_jump): Implement.
1386         * cfgrtl.c (rtl_block_empty_p, rtl_split_block_before_cond_jump):
1387         Implement RTL specific hooks.
1388         (rtl_cfg_hooks, cfg_layout_rtl_cfg_hooks): Register the new hooks.
1389         * tree-cfg.c (gimple_empty_block_p,
1390         gimple_split_block_before_cond_jump): Implement GIMPLE specific hooks.
1391         (gimple_cfg_hooks): Register the new hooks.
1392         * tree-ssa-phiopt.c (empty_block_p): Remove in favor of new hook.
1393
1394 2012-09-13  Richard Guenther  <rguenther@suse.de>
1395
1396         * tree-ssa-sccvn.h (enum vn_kind): New.
1397         (vn_get_stmt_kind): Likewise.
1398         * tree-ssa-sccvn.c (vn_get_stmt_kind): New function, adjust
1399         ADDR_EXPR handling.
1400         (visit_use): Use it.
1401         * tree-ssa-pre.c (compute_avail): Likewise, simplify further.
1402
1403 2012-09-13  Venkataramanan Kumar  <venkataramanan.kumar@amd.com>
1404
1405         * config/i386/i386.c (processor_alias_table): Enable PTA_PRFCHW
1406         for targets bdver1, bdver2, btver1 and btver2.
1407
1408 2012-09-13  Christophe Lyon  <christophe.lyon@linaro.org>
1409             Richard Earnshaw  <rearnsha@arm.com>
1410
1411         * config/arm/arm.md (arm_rev): Factorize thumb1, thumb2 and arm
1412         variants for rev instruction..
1413         (thumb1_rev): Delete pattern.
1414         (arm_revsh): New pattern to support builtin_bswap16.
1415         (arm_rev16, bswaphi2): Likewise.
1416
1417 2012-09-12  Teresa Johnson  <tejohnson@google.com>
1418
1419         PR gcov-profile/54487
1420         * configure.ac (HOST_HAS_F_SETLKW): Set based on compile
1421         test using F_SETLKW with fcntl.
1422         * configure, config.in: Regenerate.
1423
1424 2012-09-12  Jan Hubicka  <jh@suse.cz>
1425
1426         PR fortran/48636
1427         * ipa-inline-analysis.c (dump_inline_hints): Dump loop stride.
1428         (set_hint_predicate): New function.
1429         (reset_inline_summary): Reset loop stride.
1430         (remap_predicate_after_duplication): New function.
1431         (remap_hint_predicate_after_duplication): New function.
1432         (inline_node_duplication_hook): Update.
1433         (dump_inline_summary): Dump stride summaries.
1434         (estimate_function_body_sizes): Compute strides.
1435         (remap_hint_predicate): New function.
1436         (inline_merge_summary): Use it.
1437         (inline_read_section): Read stride.
1438         (inline_write_summary): Write stride.
1439         * ipa-inline.c (want_inline_small_function_p): Handle strides.
1440         (edge_badness): Likewise.
1441         * ipa-inline.h (inline_hints_vals): Add stride hint.
1442         (inline_summary): Update stride.
1443
1444 2012-09-12  Uros Bizjak  <ubizjak@gmail.com>
1445
1446         * config/i386/i386.c (x86_prefetch_sse): Change to unsigned char.
1447         * config/i386/i386.h (x86_prefetch_sse): Ditto.
1448
1449 2012-09-12  H.J. Lu  <hongjiu.lu@intel.com>
1450
1451         PR target/54445
1452         * config/i386/predicates.md (x86_64_immediate_operand): Allow
1453         negative offset for UNSPEC_DTPOFF/UNSPEC_NTPOFF.
1454
1455 2012-09-12  Jan Hubicka  <jh@suse.cz>
1456
1457         * common.opt (flto-partition): Add "max".
1458         * invoke.texi (flto-partition): Document "max"
1459
1460 2012-09-12  Ganesh Gopalasubramanian  <Ganesh.Gopalasubramanian@amd.com>
1461
1462         * config/i386/i386.md : Comments on fma4 instruction selection
1463         reflect requirement on register pressure based cost model.
1464
1465         * config/i386/driver-i386.c (host_detect_local_cpu): fma4
1466         flag is set-reset as informed by the cpuid flag.
1467
1468         * config/i386/i386.c (processor_alias_table): fma4
1469         flag is enabled for bdver2.
1470
1471 2012-09-12  Richard Guenther  <rguenther@suse.de>
1472
1473         PR tree-optimization/54489
1474         * tree-ssa-pre.c: Include domwalk.h.
1475         (in_fre): Remove.
1476         (sccvn_valnum_from_value_id): New function.
1477         (debug_bitmap_sets_for): Simplify.
1478         (get_representative_for): Properly initialize the SCCVN valnum.
1479         (create_expression_by_pieces): Likewise.
1480         (insert_into_preds_of_block): Likewise.
1481         (can_PRE_operation): Remove.
1482         (make_values_for_phi): Simplify.
1483         (compute_avail): Likewise.
1484         (do_SCCVN_insertion): Remove.
1485         (eliminate_avail, eliminate_push_avail, eliminate_insert):
1486         New functions.
1487         (eliminate): Split and perform a domwalk.
1488         (eliminate_bb): Former eliminate part that is now dom-enter.
1489         (eliminate_leave_block): New function.
1490         (fini_eliminate): Likewise.
1491         (init_pre): Simplify.
1492         (fini_pre): Likewise.
1493         (execute_pre): Fold into do_pre and do_fre.
1494         (do_pre): Consume execute_pre.
1495         (do_fre): Likewise.
1496         * Makefile.in (tree-ssa-pre.o): Add domwalk.h dependency.
1497
1498 2012-09-12  Diego Novillo  <dnovillo@google.com>
1499
1500         * vec.h: Remove compatibility notes for previous distinction
1501         between vectors of objects and vectors of pointers.
1502
1503 2012-09-12  Christian Bruel  <christian.bruel@st.com>
1504
1505         * config/sh/newlib.h (NO_IMPLICIT_EXTERN_C): Define.
1506
1507 2012-09-12  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
1508
1509         * rtl.h (FFS, FLOAT, ABS, PC): Don't undef.
1510         * system.h (FFS, FLOAT, ABS, PC): Undef.
1511
1512 2012-09-12  Richard Guenther  <rguenther@suse.de>
1513
1514         PR middle-end/54553
1515         * common.opt (finline): Mark with Optimization.
1516
1517 2012-09-12  Jakub Jelinek  <jakub@redhat.com>
1518
1519         * config.gcc: Obsolete picochip-*.
1520
1521 2012-09-12  Nathan Froyd  <froydnj@gcc.gnu.org>
1522             Hans-Peter Nilsson  <hp@bitrange.com>
1523
1524         * config/mmix/mmix.h (MMIX_REG_OK_STRICT): Delete.
1525         (REG_CLASS_FROM_LETTER, CONST_OK_FOR_LETTER_P): Delete.
1526         (CONST_DOUBLE_OK_FOR_LETTER_P, EXTRA_CONSTRAINT): Delete.
1527         * config/mmix/mmix-protos.h (mmix_intval): Declare.
1528         (mmix_const_ok_for_letter_p, mmix_extra_constraint): Delete.
1529         (mmix_const_double_ok_for_letter_p): Delete.
1530         * config/mmix/constraints.md: New file.
1531         * config/mmix/mmix.md: Include it.
1532         (iordi3): Fix typo; use "I" instead of undefined "H" constraint.
1533         ("*call_real"): Update comment about not using the "p" constraint.
1534         * config/mmix/predicates.md (mmix_reg_or_8bit_operand): Use
1535         satisfies_constraint_I.
1536         (mmix_address_operand): New predicate.
1537         (mmix_symbolic_or_address_operand): Use it instead of address_operand.
1538         * config/mmix/mmix.c: #include tm-constrs.h.
1539         (mmix_intval): Delete declaration.  Make non-static.
1540         (mmix_const_ok_for_letter_p, mmix_extra_constraint): Delete.
1541         (mmix_const_double_ok_for_letter_p): Delete.
1542         (mmix_legitimate_address_p): Use satisfies_constraint_I.
1543         (mmix_print_operand_address): Likewise.
1544         (mmix_emit_sp_add): Adjust to use insn_const_int_ok_for_constraint
1545         when matching "L" constraint.
1546
1547 2012-09-11  Steven Bosscher  <steven@gcc.gnu.org>
1548
1549         * tree.h (expand_case): Move prototype ...
1550         * expr.h (expand_case): ...here.
1551         (expand_sjlj_dispatch_table): New prototype.
1552         * stmt.c: Include pointer-set.h instead of bitmap.h.
1553         (expand_case): Use a pointer set instead of a bitmap for
1554         already-seen labels.  Fold label values here.
1555         (add_case_node): Don't fold label values here.
1556         (expand_sjlj_dispatch_table): New function.
1557         * except.c (sjlj_emit_dispatch_table): Use it.
1558
1559 2012-09-11  Marc Glisse  <marc.glisse@inria.fr>
1560
1561         * tree-ssa-forwprop.c (simplify_vector_constructor): New function.
1562         (ssa_forward_propagate_and_combine): Call it.
1563
1564 2012-09-11  Diego Novillo  <dnovillo@google.com>
1565
1566         * var-tracking.c (vt_add_function_parameter): Adjust for VEC changes.
1567
1568 2012-09-11  Dominique Dhumieres  <dominiq@lps.ens.fr>
1569
1570         * config/darwin.c (darwin_asm_named_section): Adjust for VEC changes.
1571         (darwin_asm_dwarf_section): Likewise.
1572
1573 2012-09-11  Martin Jambor  <mjambor@suse.cz>
1574
1575         * dwarf2out.c (dwarf2out_abstract_function): Do not change cfun.
1576         (premark_used_types): New parameter fun, use it instead of cfun.
1577         (gen_subprogram_die): Use DECL_STRUCT_FUNCTION (decl) instead of cfun,
1578         also pass it to premark_used_types.
1579
1580 2012-09-11  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
1581
1582         * doc/sourcebuild.texi (arm_neon_v2_ok): Adjust command line.
1583
1584 2012-09-11  Tobias Burnus  <burnus@net-b.de>
1585
1586         * doc/sourcebuild.texi (arm_neon_v2_ok): Fix @anchor.
1587
1588 2012-09-11  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
1589             Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
1590
1591         * config/arm/neon.md (fma<VCVTF:mode>4): New pattern.
1592         (*fmsub<VCVTF:mode>4): Likewise.
1593         * doc/sourcebuild.texi (arm_neon_v2_ok, arm_neon_v2_hw):  Document it.
1594
1595 2012-09-11  Aldy Hernandez  <aldyh@redhat.com>
1596
1597         PR middle-end/54149
1598         * tree-ssa-loop-im.c (execute_sm_if_changed_flag_set): Only set
1599         flag for writes.
1600
1601 2012-09-11  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
1602
1603         PR tree-optimization/55492
1604         * doc/invoke.texi (max-slsr-cand-scan): New description.
1605         * gimple-ssa-strength-reduction.c (find_basis_for_candidate): Limit
1606         the time spent searching for a basis.
1607         * params.def (PARAM_MAX_SLSR_CANDIDATE_SCAN): New param.
1608
1609 2012-09-11  Richard Guenther  <rguenther@suse.de>
1610
1611         * gimple.h (gimple_register_type): Remove.
1612         (print_gimple_types_stats): Adjust prototype.
1613         * lto-streamer.h (print_lto_report): Likewise.
1614         * lto-streamer.c (print_lto_report): Adjust.
1615         * gimple.c (gimple_types, type_hash_cache, enum gtc_mode,
1616         struct type_pair_d, lookup_type_pair, struct sccs,
1617         next_dfs_num, gtc_next_dfs_num, struct gimple_type_leader_entry_s,
1618         gimple_type_leader, gimple_lookup_type_leader, compare_type_names_p,
1619         gtc_visit, gimple_types_compatible_p_1, gimple_types_compatible_p,
1620         visit, iterative_hash_name, struct type_hash_pair,
1621         type_hash_pair_compare, iterative_hash_gimple_type, gimple_type_hash,
1622         gimple_type_eq, gimple_register_type_1, gimple_register_type):
1623         Move to lto/lto.c.
1624         (print_gimple_types_stats): Adjust.
1625         (free_gimple_type_tables): Likewise.
1626
1627 2012-09-11  Richard Guenther  <rguenther@suse.de>
1628
1629         * graphite-scop-detection.c (move_sd_regions): Adjust for VEC changes.
1630         (scopdet_basic_block_info): Likewise.
1631         (build_scops_1): Likewise.
1632         (limit_scops): Likewise.
1633
1634 2012-09-11  Richard Guenther  <rguenther@suse.de>
1635
1636         PR middle-end/54515
1637         * gimple.c (get_base_address): Do not return NULL_TREE apart
1638         from for WITH_SIZE_EXPR.
1639         * gimple-fold.c (canonicalize_constructor_val): Do not call
1640         get_base_address when not necessary.
1641
1642 2012-09-10  Andrew Pinski  <apinski@cavium.com>
1643
1644         PR tree-opt/54362
1645         * trans-mem.c (thread_private_new_memory): Handle COND_EXPR also.
1646
1647 2012-09-10  Maxim Kuvyrkov  <maxim@codesourcery.com>
1648
1649         * config/m68k/m68k.c (m68k_sched_dfa_post_advance_cycle): Support
1650         starting scheduling from a pre-existing state.
1651
1652 2012-09-10  Diego Novillo  <dnovillo@google.com>
1653
1654         * vec.h (vec_t::quick_push): Remove overload that accepts 'T *'.
1655         Update all users.
1656         (vec_t::safe_push): Likewise.
1657         (vec_t::quick_insert): Likewise.
1658         (vec_t::lower_bound): Likewise.
1659         (vec_t::safe_insert): Likewise.
1660         (vec_t::replace): Change second argument to 'T &'.
1661
1662 2012-09-10  Maciej W. Rozycki  <macro@codesourcery.com>
1663
1664         * config/rs6000/rs6000.md: Move a splitter next to its insn.
1665
1666 2012-09-10  Oleg Endo  <olegendo@gcc.gnu.org>
1667
1668         PR target/54089
1669         * config/sh/sh.h (SH_DYNAMIC_SHIFT_COST): Set always to 1 if
1670         dynamic shifts are available.
1671         (SHIFT_COUNT_TRUNCATED): Always define to 0.  Correct comment.
1672         * config/sh/sh.c (ashl_lshr_seq, ext_ashl_lshr_seq): Add comments.
1673         * config/sh/predicates.md (shift_count_operand): Allow
1674         arith_reg_operand even if TARGET_DYNSHIFT is false.
1675         * config/sh/sh.md (ashlsi3, lshrsi3): Expand library call patterns
1676         if needed.
1677         (ashlsi3_d_call, lshrsi3_d_call): New insns.
1678
1679 2012-09-10  Richard Sandiford  <rdsandiford@googlemail.com>
1680
1681         * ira.c (setup_pressure_classes): Handle synonymous classes.
1682
1683 2012-09-10  Marc Glisse  <marc.glisse@inria.fr>
1684
1685         * tree-ssa-forwprop.c (simplify_bitfield_ref): New function.
1686         (ssa_forward_propagate_and_combine): Call it.
1687
1688 2012-09-10  Steve Ellcey  <sellcey@mips.com>
1689
1690         * config.gcc: Add mips*-mti-linux* target
1691         Handle with_synci like other options.
1692         * config/mips/gnu-user64.h (LINUX64_DRIVER_SELF_SPECS): New.
1693         (DRIVER_SELF_SPECS): Define in terms of LINUX64_DRIVER_SELF_SPECS.
1694         * config/mips/mips.h (MIPS_ISA_SYNCI_SPEC): New.
1695         * config/mips/mti-linux.h: New file.
1696         * config/mips/t-mti-linux: New file.
1697
1698 2012-09-10  Marc Glisse  <marc.glisse@inria.fr>
1699
1700         * tree-ssa-forwprop.c (simplify_permutation): Handle CONSTRUCTOR.
1701
1702 2012-09-10  Martin Jambor  <mjambor@suse.cz>
1703
1704         * params.def (PARAM_IPA_MAX_AGG_ITEMS): New parameter.
1705         * ipa-prop.c: Include params.h.
1706         (IPA_MAX_AFF_JF_ITEMS): Removed.
1707         (determine_known_aggregate_parts): Use param value of
1708         PARAM_IPA_MAX_AGG_ITEMS instead of IPA_MAX_AFF_JF_ITEMS.
1709         * Makefile.in (ipa-prop.o): Add PARAMS_H dependency.
1710
1711 2012-09-10  Richard Guenther  <rguenther@suse.de>
1712
1713         PR tree-optimization/54520
1714         * tree-ssa-threadupdate.c (def_split_header_continue_p):
1715         Properly consider sub-loops.
1716
1717 2012-09-10  Richard Henderson  <rth@redhat.com>
1718
1719         * config/alpha/predicates.md (small_symbolic_operand): Disallow
1720         large offsets.
1721
1722 2012-09-10  Georg-Johann Lay  <avr@gjlay.de>
1723
1724         PR target/54536
1725         * config/avr/avr-mcus.def (at90usb1287): Set LIBRARY_NAME to "usb1287".
1726
1727 2012-09-10  Jan Hubicka  <jh@suse.cz>
1728
1729         * lto-cgraph.c (compute_ltrans_boundary): Do not care about aliases.
1730         * symtab.c (symtab_make_decl_local): Remove user defined visibility
1731         when making symbol local.
1732
1733 2012-09-09  Mark Kettenis  <kettenis@gnu.org>
1734
1735         * config/openbsd-stdint.h (INTMAX_TYPE, UINTMAX_TYPE): Define.
1736
1737 2012-09-09  Jan Hubicka  <jh@suse.cz>
1738
1739         * passes.c (ipa_write_summaries_1): Set state;
1740         do not call compute_ltrans_boundary.
1741         (ipa_write_optimization_summaries): Likewise.
1742         (ipa_write_summaries): compute_ltrans_boundary here.
1743         * lto-streamer.h (lto_symtab_encoder_d): NODES are allocated in heap.
1744         (compute_ltrans_boundary): Update prototype.
1745
1746 2012-09-09  Ulrich Drepper  <drepper@gmail.com>
1747
1748         * config/i386/cpuid.h: Define signature_*_e[bcd]x macros for
1749         matching results of level 0 calls to __cpuid to processor
1750         manufacturers.
1751         * config/i386/driver-i386.c (vendor_signatures): Removed.
1752         (processor_signatures): Removed.
1753         (host_detect_local_cpu): Replace uses of now-removed SIG_*
1754         constants with the new signature_*_ebx constants.
1755
1756 2012-09-08  Jan Hubicka  <jh@suse.cz>
1757
1758         Replace cgraph_node_set and varpool_node_set by symtab_node_encoder
1759         in partitioning.
1760         * tree-pass.h (cgraph_node_set_def, varpool_node_set_def): Remove
1761         forward declaration.
1762         (lto_symtab_encoder_d): Forward declare.
1763         (ipa_write_optimization_summaries): Update.
1764         * lto-cgraph.c (lto_symtab_encoder_new): Do not initialize
1765         body, initializer and in_partition.
1766         (lto_symtab_encoder_delete): Update.
1767         (lto_symtab_encoder_encode): Update.
1768         (lto_symtab_encoder_lookup): Move inline.
1769         (lto_symtab_encoder_delete_node): New function.
1770         (lto_symtab_encoder_encode_body_p, lto_set_symtab_encoder_encode_body,
1771         lto_symtab_encoder_encode_initializer_p,
1772         lto_set_symtab_encoder_encode_initializer,
1773         lto_symtab_encoder_in_partition_p,
1774         lto_symtab_encoder_in_partition_p): Update.
1775         (compute_ltrans_boundary): Take encoder as an input.
1776         * passes.c (ipa_write_summaries_1): Update.
1777         (ipa_write_summaries_1): Update.
1778         (ipa_write_summaries): Update.
1779         (ipa_write_optimization_summaries): Update.
1780         * lto-streamer.c (print_lto_report): Report number of cgraph nodes.
1781         * lto-streamer.h (lto_stats_d): Replace num_output_cgraph_nodes by
1782         num_output_symtab_nodes.
1783         (lto_encoder_entry): New structure.
1784         (struct lto_symtab_encoder_d): Reorg.
1785         (lto_symtab_encoder_delete_node): Declare.
1786         (lto_symtab_encoder_lookup): Bring inline.
1787         (compute_ltrans_boundary): Update.
1788         (lto_symtab_encoder_size): Update.
1789         (lsei_node, lsei_cgraph_node, lsei_varpool_node): Update.
1790         (lto_symtab_encoder_deref): Update.
1791
1792 2012-09-08  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1793
1794         * config/pa/pa.c (hppa_rtx_costs): Update costs for large
1795         integer modes.
1796
1797 2012-09-08  Andi Kleen  <ak@linux.intel.com>
1798
1799         * gcc/lto/lto.c (do_whole_program_analysis): Fix last broken patch.
1800
1801 2012-09-08  Andi Kleen  <ak@linux.intel.com>
1802
1803         * gcc/common.opt (-fmem-report-wpa): Add
1804         * gcc/doc/invoke.texi (-fmem-report-wpa): Document.
1805         * gcc/lto/lto.c (do_whole_program_analysis): Run mem_report
1806         when mem_report_wpa is set.
1807
1808 2012-09-07  Anthony Green  <green@moxielogic.com>
1809
1810         * config/moxie/moxie.c (moxie_expand_prologue): Optimize prologue
1811         for functions with large static stack requirements.
1812         (moxie_expand_epilogue): Use $r12 instead of $r5 for pulling saved
1813         values off of the stack.
1814
1815 2012-09-07  Nick Clifton  <nickc@redhat.com>
1816
1817         * config/v850/v850.h (DBX_DEBUGGING_INFO): Define.
1818         (ASM_GENERATE_INTERNAL_LABEL): Define if not already provided.
1819         * config/v850/v850.c (compute_register_save_size): Always include
1820         the link pointer.
1821         (increment_stack): New function - emits insns to increment or
1822         decrement the stack pointer.
1823         (expand_prologue, expand_epilogue): Use it.
1824         (expand_prologue): Set the function stack size, if requested.
1825         (v850_debug_unwind_info): New function.
1826         (TARGET_DEBUG_UNWIND_INFO): Define.
1827
1828 2012-09-07  Richard Earnshaw  <rearnsha@arm.com>
1829
1830         PR tree-ssa/54295
1831         * tree-ssa-math-opts.c (widening_mult_conversion_strippable_p):
1832         Sign-extension of a zero-extended value can be simplified to
1833         just zero-extension.
1834
1835 2012-09-07  Richard Guenther  <rguenther@suse.de>
1836
1837         PR middle-end/53667
1838         * tree-ssa-structalias.c (handle_rhs_call): Properly clobber
1839         EAF_NOESCAPED arguments.  Transitively close non-EAF_DIRECT
1840         arguments separately.
1841
1842 2012-09-07  Steven Bosscher  <steven@gcc.gnu.org>
1843
1844         * bitmap.c (bitmap_last_set_bit): Rewrite to return the correct bit.
1845
1846         * graphite.c (print_global_statistics): Use EDGE_COUNT instead
1847         of VEC_length.
1848         (print_graphite_scop_statistics): Likewise.
1849         * graphite-scop-detection.c (get_bb_type): Use single_succ_p.
1850         (print_graphite_scop_statistics): Use EDGE_COUNT, not VEC_length.
1851         (canonicalize_loop_closed_ssa): Use single_pred_p.
1852
1853         * alias.c (reg_seen): Make this an sbitmap.
1854         (record_set, init_alias_analysis): Update.
1855
1856         * tree-ssa-coalesce.c (ssa_conflicts_dump): Fix dumping.
1857
1858 2012-09-07  Tom de Vries  <tom@codesourcery.com>
1859
1860         PR tree-optimization/53986
1861         * tree-vrp.c (extract_range_from_multiplicative_op_1): Allow
1862         LSHIFT_EXPR.
1863         (extract_range_from_binary_expr_1): Handle LSHIFT with constant
1864         range as shift amount.
1865
1866 2012-09-07  Segher Boessenkool  <segher@kernel.crashing.org>
1867
1868         * config/rs6000/aix43.h (RS6000_CALL_GLUE): Delete.
1869         * config/rs6000/aix51.h (RS6000_CALL_GLUE): Delete.
1870         * config/rs6000/aix52.h (RS6000_CALL_GLUE): Delete.
1871         * config/rs6000/aix53.h (RS6000_CALL_GLUE): Delete.
1872         * config/rs6000/aix61.h (RS6000_CALL_GLUE): Delete.
1873         * config/rs6000/freebsd64.h (RS6000_CALL_GLUE): Delete.
1874         * config/rs6000/linux64.h (RS6000_CALL_GLUE): Delete.
1875         * config/rs6000/rs6000.c (print_operand) ['.']: Delete.
1876         * config/rs6000/rs6000.h (RS6000_CALL_GLUE): Delete.
1877         * config/rs6000/rs6000.md (tls_gd_aix<TLSmode:tls_abi_suffix>):
1878         Replace %. with nop.
1879         (tls_gd_call_aix<TLSmode:tls_abi_suffix>): Ditto.
1880         (tls_ld_aix<TLSmode:tls_abi_suffix>): Ditto.
1881         (tls_ld_call_aix<TLSmode:tls_abi_suffix>): Ditto.
1882         (call_nonlocal_aix32): Ditto.
1883         (call_nonlocal_aix64): Ditto.
1884         (call_value_nonlocal_aix32): Ditto.
1885         (call_value_nonlocal_aix64): Ditto.
1886
1887 2012-09-06  Andi Kleen  <ak@linux.intel.com>
1888
1889         * doc/invoke.texi (-ffat-lto-objects): Clarify that gcc-ar
1890         et.al. should be used.
1891
1892 2012-09-06  Andi Kleen  <ak@linux.intel.com>
1893
1894         * gcc/lto-streamer.h (res_pair): Add.
1895         (lto_file_decl_data): Replace resolutions with respairs.
1896         Add max_index.
1897         * gcc/lto/lto.c (lto_resolution_read): Remove max_index.  Add rp.
1898         Initialize respairs.
1899         (lto_file_finalize): Set up resolutions vector lazily from respairs.
1900
1901 2012-09-06  Lawrence Crowl  <crowl@google.com>
1902
1903         * double-int.h (double_int::operator &=): New.
1904         (double_int::operator ^=): New.
1905         (double_int::operator |=): New.
1906         (double_int::mul_with_sign): Modify overflow parameter to bool*.
1907         (double_int::add_with_sign): New.
1908         (double_int::ule): New.
1909         (double_int::sle): New.
1910         (binary double_int::operator *): Remove parameter name.
1911         (binary double_int::operator +): Likewise.
1912         (binary double_int::operator -): Likewise.
1913         (binary double_int::operator &): Likewise.
1914         (double_int::operator |): Likewise.
1915         (double_int::operator ^): Likewise.
1916         (double_int::and_not): Likewise.
1917         (double_int::from_shwi): Tidy formatting.
1918         (double_int::from_uhwi): Likewise.
1919         (double_int::from_uhwi): Likewise.
1920         * double-int.c (double_int::mul_with_sign): Modify overflow parameter
1921         to bool*.
1922         (double_int::add_with_sign): New.
1923         (double_int::ule): New.
1924         (double_int::sle): New.
1925         * builtins.c: Modify to use the new double_int interface.
1926         * cgraph.c: Likewise.
1927         * combine.c: Likewise.
1928         * dwarf2out.c: Likewise.
1929         * emit-rtl.c: Likewise.
1930         * expmed.c: Likewise.
1931         * expr.c: Likewise.
1932         * fixed-value.c: Likewise.
1933         * fold-const.c: Likewise.
1934         * gimple-fold.c: Likewise.
1935         * gimple-ssa-strength-reduction.c: Likewise.
1936         * gimplify-rtx.c: Likewise.
1937         * ipa-prop.c: Likewise.
1938         * loop-iv.c: Likewise.
1939         * optabs.c: Likewise.
1940         * stor-layout.c: Likewise.
1941         * tree-affine.c: Likewise.
1942         * tree-cfg.c: Likewise.
1943         * tree-dfa.c: Likewise.
1944         * tree-flow-inline.h: Likewise.
1945         * tree-object-size.c: Likewise.
1946         * tree-predcom.c: Likewise.
1947         * tree-pretty-print.c: Likewise.
1948         * tree-sra.c: Likewise.
1949         * tree-ssa-address.c: Likewise.
1950         * tree-ssa-alias.c: Likewise.
1951         * tree-ssa-ccp.c: Likewise.
1952         * tree-ssa-forwprop.c: Likewise.
1953         * tree-ssa-loop-ivopts.c: Likewise.
1954         * tree-ssa-loop-niter.c: Likewise.
1955         * tree-ssa-phiopt.c: Likewise.
1956         * tree-ssa-pre.c: Likewise.
1957         * tree-ssa-sccvn: Likewise.
1958         * tree-ssa-structalias.c: Likewise.
1959         * tree-ssa.c: Likewise.
1960         * tree-switch-conversion.c: Likewise.
1961         * tree-vect-loop-manip.c: Likewise.
1962         * tree-vrp.c: Likewise.
1963         * tree.h: Likewise.
1964         * tree.c: Likewise.
1965         * varasm.c: Likewise.
1966
1967 2012-09-06  Uros Bizjak  <ubizjak@gmail.com>
1968
1969         * configure.ac (hle prefixes): Remove .code64 directive.
1970         * configure: Regenerated.
1971
1972 2012-09-06  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
1973
1974         * config/arm/arm.c: Use CONST_INT_P, CONST_DOUBLE_P, REG_P, MEM_P,
1975         LABEL_P, JUMP_P, CALL_P, NOTE_P, BARRIER_P consistently.
1976         * config/arm/arm.h: Use REG_P, MEM_P consistently.
1977         * config/arm/arm.md: Use CONST_INT_P, REG_P, MEM_P, CONST_DOUBLE_P
1978         consistently.
1979         * config/arm/neon.md: Use REG_P consistently.
1980         * config/arm/predicates.md: Use CONST_INT_P, REG_P, MEM_P consistently.
1981         * config/arm/thumb2.md: Use CONST_INT_P, REG_P consistently.
1982         * config/arm/vec-common.md: Use REG_P consistently.
1983
1984 2012-09-06  Richard Guenther  <rguenther@suse.de>
1985
1986         PR tree-optimization/54498
1987         * tree-ssa-alias.h (get_continuation_for_phi): Add flag to
1988         abort when reaching an already visited region.
1989         * tree-ssa-alias.c (maybe_skip_until): Likewise.  And do it.
1990         (get_continuation_for_phi_1): Likewise.
1991         (walk_non_aliased_vuses): When we translated the reference,
1992         abort when we re-visit a region.
1993         * tree-ssa-pre.c (translate_vuse_through_block): Adjust.
1994
1995 2012-09-06  David Edelsohn  <dje.gcc@gmail.com>
1996
1997         * config/rs6000/rs6000.c (rs6000_xcoff_asm_named_section): Add TLS
1998         section.
1999         * config/rs6000/rs6000.c (rs6000_debug_address_cost): Add new
2000         arguments to TARGET_ADDRESS_COST call.
2001
2002 2012-09-06  Richard Guenther  <rguenther@suse.de>
2003
2004         * tree.h (MOVE_NONTEMPORAL): Remove.
2005         * tree-pretty-print.c (dump_generic_node): Remove
2006         MOVE_NONTEMPORAL handling.
2007         * expr.c (expand_expr_real_1): Likewise.
2008
2009 2012-09-06  Richard Guenther  <rguenther@suse.de>
2010
2011         * passes.c (execute_function_todo): Call compute_may_aliases
2012         only if flag_tree_pta is set.
2013
2014 2012-09-06  Andrew Pinski  <apinski@cavium.com>
2015
2016         PR tree-opt/54494
2017         * tree-inline.c (remap_gimple_op_r): Copy TREE_SIDE_EFFECTS also.
2018
2019 2012-09-06  Jakub Jelinek  <jakub@redhat.com>
2020
2021         PR rtl-optimization/54455
2022         * sel-sched-ir.c (maybe_tidy_empty_bb): Give up if previous fallthru
2023         bb ends up with asm goto referencing bb's label.
2024
2025 2012-09-06  Chen Liqin  <liqin.gcc@gmail.com>
2026
2027         * config/score/score.c: Remove TARGET_LEGITIMIZE_ADDRESS define and
2028         score_legitimize_address function, use compiler default code instead.
2029
2030 2012-09-05  Jan Hubicka  <jh@suse.cz>
2031
2032         * ipa-inline.c (want_inline_small_function_p): Use
2033         INLINE_HINT_loop_iterations hint.
2034
2035 2012-09-05  Andrew Pinski  <apinski@cavium.com>
2036
2037         * optabs.c (emit_conditional_add): Correct comment about the arguments.
2038         Remove code which might swap op2 and op3 since they cannot be swapped.
2039         * doc/md.texi (add@var{mode}cc): Fix document about how the arguments
2040         are used.
2041
2042 2012-09-05  Oleg Endo  <olegendo@gcc.gnu.org>
2043
2044         * hooks.c (hook_int_rtx_mode_as_bool_0): New function.
2045         * hooks.h (hook_int_rtx_mode_as_bool_0): Declare it.
2046         * output.h (default_address_cost): Add machine_mode and address space
2047         arguments.
2048         * target.def (address_cost): Likewise.
2049         * rtlanal.c (address_cost): Pass mode and address space to target hook.
2050         (default_address_cost): Add unnamed machine_mode and address space
2051         arguments.
2052         * doc/tm.texi: Regenerate.
2053         * config/alpha/alpha.c (TARGET_ADDRESS_COST): Use
2054         hook_int_rtx_mode_as_bool_0 instead of hook_int_rtx_bool_0.
2055         * config/arm/arm.c (arm_address_cost): Add machine_mode and address
2056         space arguments.
2057         * config/avr/avr.c (avr_address_cost): Likewise.
2058         * config/bfin/bfin.c (bfin_address_cost): Likewise.
2059         * config/cr16/cr16.c (cr16_address_cost): Likewise.
2060         * config/cris/cris.c (cris_address_cost): Likewise.
2061         * config/epiphany/epiphany.c (epiphany_address_cost): Likewise.
2062         * config/i386/i386.c (ix86_address_cost): Likewise.
2063         * config/ia64/ia64.c (TARGET_ADDRESS_COST): Use
2064         hook_int_rtx_mode_as_bool_0 instead of hook_int_rtx_bool_0.
2065         * config/iq2000/iq2000.c (iq2000_address_cost): Add machine_mode and
2066         address space arguments.  Pass them on in recursive invocation.
2067         * config/lm32/lm32.c (TARGET_ADDRESS_COST): Use
2068         hook_int_rtx_mode_as_bool_0 instead of hook_int_rtx_bool_0.
2069         * config/m32c/m32c.c (m32c_address_cost): Add machine_mode and address
2070         space arguments.
2071         * config/m32r/m32r.c (TARGET_ADDRESS_COST): Use
2072         hook_int_rtx_mode_as_bool_0 instead of hook_int_rtx_bool_0.
2073         * config/mcore/mcore.c (TARGET_ADDRESS_COST): Likewise.
2074         * config/mep/mep.c (mep_address_cost): Add machine_mode and address
2075         space arguments.
2076         * config/microblaze/microblaze.c (microblaze_address_cost): Likewise.
2077         * config/mips/mips.c (mips_address_cost): Likewise.
2078         * config/mmix/mmix.c (TARGET_ADDRESS_COST): Use
2079         hook_int_rtx_mode_as_bool_0 instead of hook_int_rtx_bool_0.
2080         * config/mn10300/mn10300.c (mn10300_address_cost): Add machine_mode and
2081         address space arguments.
2082         (mn10300_rtx_costs): Pass GET_MODE (x) and MEM_ADDR_SPACE (x) to
2083         mn10300_address_cost.
2084         * config/pa/pa.c (hppa_address_cost): Add machine_mode and address
2085         space arguments.
2086         * config/rs6000/rs6000.c (rs6000_debug_address_cost): Likewise.
2087         (TARGET_ADDRESS_COST): Use hook_int_rtx_mode_as_bool_0 instead of
2088         hook_int_rtx_bool_0.
2089         * config/rx/rx.c (rx_address_cost): Add machine_mode and address
2090         space arguments.
2091         * config/s390/s390.c (s390_address_cost): Likewise.
2092         * config/score/score-protos.h (score_address_cost): Likewise.
2093         * config/score/score.c (score_address_cost): Likewise.
2094         * config/sh/sh.c (sh_address_cost): Likewise.
2095         * config/sparc/sparc.c (TARGET_ADDRESS_COST): Use
2096         hook_int_rtx_mode_as_bool_0 instead of hook_int_rtx_bool_0.
2097         * config/spu/spu.c (TARGET_ADDRESS_COST): Likewise.
2098         * config/stormy16/stormy16.c (xstormy16_address_cost): Add machine_mode
2099         and address space arguments.
2100         * config/v850/v850.c (TARGET_ADDRESS_COST): Use
2101         hook_int_rtx_mode_as_bool_0 instead of hook_int_rtx_bool_0.
2102         * config/vax/vax.c (vax_address_cost): Add machine_mode and address
2103         space arguments.
2104         * config/xtensa/xtensa (TARGET_ADDRESS_COST): Use
2105         hook_int_rtx_mode_as_bool_0 instead of hook_int_rtx_bool_0.
2106
2107 2012-09-05  Diego Novillo  <dnovillo@google.com>
2108
2109         PR bootstrap/54484
2110         * vec.h (vec_t::lower_bound): Fix spelling of LESSTHAN argument.
2111
2112 2012-09-05  Jakub Jelinek  <jakub@redhat.com>
2113
2114         PR middle-end/54486
2115         * builtins.c (fold_builtin_strspn, fold_builtin_strcspn): Use
2116         build_int_cst with size_type_node instead of size_int.
2117
2118 2012-09-05  Uros Bizjak  <ubizjak@gmail.com>
2119
2120         * config/i386/sse.md (<sse4_1>_blendv<ssemodesuffix><avxsizesuffix>):
2121         Use register_operand instead of reg_not_xmm0_operand{,_maybe_avx}.
2122         Use nonimmediate_operand instead of
2123         nonimm_not_xmm0_operand{,_maybe_avx}.
2124         (<sse4_1_avx2>_pblendvb): Ditto.
2125         (sse4_2_pcmpestr): Ditto.
2126         (*sse4_2_pcmpestr_unaligned): Ditto.
2127         (sse4_2_pcmpistr): Ditto.
2128         (*sse4_2_pcmpistr_unaligned): Ditto.
2129         * config/i386/predicates.md (reg_not_xmm0_operand): Remove predicate.
2130         (nonimm_not_xmm0_operand): Ditto.
2131         (nonimm_not_xmm0_operand_maybe_avx): Ditto.
2132         (nonimm_not_xmm0_operand_maybe_avx): Ditto.
2133         * config/i386/i386.md (rdpmc): Do not force operand 1 into ecx.
2134
2135 2012-09-05  Eric Botcazou  <ebotcazou@adacore.com>
2136
2137         * bb-reorder.c: Clarify a few points in the head comment and fix
2138         long lines in other comments.
2139         (find_traces): Fix long line.
2140         (find_traces_1_round): Likewise.
2141         (better_edge_p): Likewise.
2142         (connect_traces): Likewise.
2143         (duplicate_computed_gotos): Likewise.
2144         (find_rarely_executed_basic_blocks_and_cr): Remove trailing spaces.
2145         (fix_up_fall_thru_edges): Fix formatting.
2146
2147 2012-09-05  Richard Guenther  <rguenther@suse.de>
2148
2149         PR tree-optimization/46590
2150         * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Do not
2151         update SSA form here.
2152         (canonicalize_induction_variables): Assert we do not need to
2153         update SSA form.
2154         (tree_unroll_loops_completely): Update SSA form here.
2155         * tree-ssa-loop-manip.c (gimple_duplicate_loop_to_header_edge):
2156         Do not verify loop-closed SSA form if SSA form is not up-to-date.
2157
2158 2012-09-05  Georg-Johann Lay  <avr@gjlay.de>
2159
2160         PR target/54461
2161         * config.gcc (tm_file,target=avr-*-*): Add avr/avrlibc.h if
2162         not configured --with-avrlibc=no.
2163         (tm_defines,target=avr-*-*): Add WITH_AVRLIBC if not configured
2164         --with-avrlibc=no.
2165         * config/avr/avrlibc.h: New file.
2166         * config/avr/avr-c.c: Build-in define __WITH_AVRLIBC__ if
2167         not configured --with-avrlibc=no.
2168         * doc/invoke.texi (AVR Built-in Macros): Document __WITH_AVRLIBC__
2169
2170 2012-09-04  Teresa Johnson  <tejohnson@google.com>
2171
2172         * gcov-io.c (gcov_write_summary): Write out non-zero histogram
2173         entries to function summary along with an occupancy bit vector.
2174         (gcov_read_summary): Read in the histogram entries.
2175         (gcov_histo_index): New function.
2176         (void gcov_histogram_merge): Ditto.
2177         * gcov-io.h (gcov_type_unsigned): New type.
2178         (struct gcov_bucket_type): Ditto.
2179         (struct gcov_ctr_summary): Include histogram.
2180         (GCOV_TAG_SUMMARY_LENGTH): Update to include histogram entries.
2181         (GCOV_HISTOGRAM_SIZE): New macro.
2182         (GCOV_HISTOGRAM_BITVECTOR_SIZE): Ditto.
2183         * profile.c (NUM_GCOV_WORKING_SETS): Ditto.
2184         (gcov_working_sets): New global variable.
2185         (compute_working_sets): New function.
2186         (find_working_set): Ditto.
2187         (get_exec_counts): Invoke compute_working_sets.
2188         * coverage.c (read_counts_file): Merge histograms, and
2189         fix bug with accessing summary info for non-summable counters.
2190         * basic-block.h (gcov_type_unsigned): New type.
2191         (struct gcov_working_set_info): Ditto.
2192         (find_working_set): Declare.
2193         * gcov-dump.c (tag_summary): Dump out histogram.
2194
2195 2012-09-04  Diego Novillo  <dnovillo@google.com>
2196
2197         PR bootstrap/54484
2198         * vec.h (vec_t::embedded_init): Move default argument value
2199         to function declaration.
2200
2201 2012-09-04  Eric Botcazou  <ebotcazou@adacore.com>
2202
2203         * bb-reorder.c (gate_handle_reorder_blocks): Move around.
2204         (rest_of_handle_reorder_blocks): Likewise.
2205         (pass_reorder_blocks): Likewise.
2206         (gate_handle_partition_blocks): Likewise.
2207
2208 2012-09-04  Eric Botcazou  <ebotcazou@adacore.com>
2209
2210         PR rtl-optimization/54456
2211         * sched-rgn.c (gate_handle_sched): Return 1 only if optimize > 0.
2212
2213 2012-09-04  Diego Novillo  <dnovillo@google.com>
2214
2215         PR bootstrap/54478
2216         * vec.h (vec_t::alloc): Remove explicit type specification
2217         in call to reserve.
2218         (vec_t::copy): Likewise.
2219         (vec_t::reserve): Likewise.
2220         (vec_t::reserve_exact): Likewise.
2221         (vec_t::safe_splice): Likewise.
2222         (vec_t::safe_push): Likewise.
2223         (vec_t::safe_grow): Likewise.
2224         (vec_t::safe_grow_cleared): Likewise.
2225         (vec_t::safe_insert): Likewise.
2226
2227 2012-09-04  Richard Henderson  <rth@redhat.com>
2228
2229         * alias.c (read_dependence): Return true for ALIAS_SET_MEMORY_BARRIER.
2230
2231 2012-09-04  Richard Guenther  <rguenther@suse.de>
2232
2233         * tree-ssa-pre.c (value_expressions): Make it a vector of
2234         bitmaps containing expression IDs.
2235         (add_to_value): Adjust.
2236         (sorted_array_from_bitmap_set): Likewise.
2237         (bitmap_set_replace_value): Likewise.
2238         (print_value_expressions): Likewise.
2239         (get_constant_for_value_id): Likewise.
2240         (get_representative_for): Likewise.
2241         (phi_translate_1): Likewise.
2242         (bitmap_find_leader): Likewise.
2243         (find_or_generate_expression): Likewise.
2244         (do_regular_insertion): Likewise.
2245         (init_pre): Likewise.
2246         (fini_pre): Likewise.
2247
2248 2012-09-04  Diego Novillo  <dnovillo@google.com>
2249
2250         PR bootstrap/54479
2251         * vec.h (vec_t::copy): Add cast in call to reserve_exact.
2252
2253 2012-09-04  Richard Guenther  <rguenther@suse.de>
2254
2255         * tree-ssa-pre.c (add_to_exp_gen): Adjust.
2256         (make_values_for_phi): Do not add to PHI_GEN for FRE.
2257         (compute_avail): Stop processing after adding all defs to
2258         AVAIL_OUT for FRE.
2259         (init_pre): Do not allocate not needed bitmap sets for FRE.
2260
2261 2012-09-04  Diego Novillo  <dnovillo@google.com>
2262
2263         Rewrite VEC_* functions as member functions of vec_t.
2264
2265         * vec.h: Update documentation.
2266         (ALONE_VEC_CHECK_INFO): Define.
2267         (ALONE_VEC_CHECK_DECL): Define.
2268         (ALONE_VEC_CHECK_PASS): Define.
2269         (struct vec_prefix): Rename field NUM to NUM_.
2270         Rename field ALLOC to ALLOC_.
2271         Update all users.
2272         (struct vec_t): Rename field PREFIX to PREFIX_.
2273         Rename field VEC to VEC_.
2274         Update all users.
2275         (vec_t::length): Rename from VEC_length_1.  Update all users.
2276         (vec_t::empty): Rename from VEC_empty_1.  Update all users.
2277         (vec_t::address): Rename from VEC_address_1.  Update all users.
2278         (vec_address): New.
2279         (vec_t::last): Rename from VEC_last_1.  Update all users.
2280         (vec_t::operator[]): Rename from VEC_index_1.  Update all users.
2281         (vec_t::iterate): Rename from VEC_iterate_1.  Update all users.
2282         (vec_t::embedded_size): Rename from VEC_embedded_size_1.
2283         Update all users.
2284         (vec_t::embedded_init): Rename from VEC_embedded_init_1.
2285         Update all users.
2286         (vec_t::alloc): Rename from VEC_alloc_1.  Update all users.
2287         (vec_t::free): Rename from VEC_free_1.  Update all users.
2288         (vec_t::copy): Rename from VEC_copy_1.  Update all users.
2289         (vec_t::space): Rename from VEC_space_1.  Update all users.
2290         (vec_t::reserve): Rename from VEC_reserve_1.  Update all users.
2291         (vec_t::reserve_exact): Rename from VEC_reserve_exact_1.
2292         Update all users.
2293         (vec_t::splice): Rename from VEC_splice_1.  Update all users.
2294         (vec_t::safe_splice): Rename from VEC_safe_splice_1.  Update all users.
2295         (vec_t::quick_push): Rename from VEC_quick_push_1.  Update all users.
2296         (vec_t::safe_push): Rename from VEC_safe_push_1.  Update all users.
2297         (vec_t::pop): Rename from VEC_pop_1.  Update all users.
2298         (vec_t::truncate): Rename from VEC_truncate_1.  Update all users.
2299         (vec_t::safe_grow): Rename from VEC_safe_grow_1.  Update all users.
2300         (vec_t::safe_grow_cleared): Rename from VEC_safe_grow_cleared_1.
2301         Update all users.
2302         (vec_t::replace): Rename from VEC_replace_1.  Update all users.
2303         (vec_t::quick_insert): Rename from VEC_quick_insert_1.
2304         Update all users.
2305         (vec_t::safe_insert): Rename from VEC_safe_insert_1.  Update all users.
2306         (vec_t::ordered_remove): Rename from VEC_ordered_remove_1.
2307         Update all users.
2308         (vec_t::unordered_remove): Rename from VEC_unordered_remove_1.
2309         Update all users.
2310         (vec_t::block_remove): Rename from VEC_block_remove_1. Update all users.
2311         (vec_t::lower_bound): Rename from VEC_lower_bound_1. Update all users.
2312
2313 2012-09-04  Steven Bosscher  <steven@gcc.gnu.org>
2314
2315         * gimple.h (gimple_build_switch): Remove.
2316         (gimple_build_switch_vec): Promote to the new gimple_build_switch.
2317         (gimple_switch_default_label): Assert the default case label is
2318         really a default case label.
2319         (gimple_switch_set_default_label): Likewise.
2320         * gimple.c (gimple_build_switch_nlabels): Make sure a default label
2321         is passed in, and simplify accordingly.
2322         (gimple_build_switch): Removed.
2323         (gimple_build_switch_vec): Rename to gimple_build_switch.
2324         * gimplify.c (gimplify_switch_expr): Update gimple_build_switch use.
2325         * gimple-pretty-print.c (dump_gimple_switch): Do not accept a NULL
2326         case label.
2327         * stmt.c (expand_case): Simplify using the fact that every GIMPLE
2328         switch must have a default case.
2329         * tree-cfg.c (group_case_labels_stmt): Likewise.
2330         (verify_gimple_switch): Use gimple_switch_label in verifier to get
2331         the label at index 0, and verify that it is a valid default case.
2332         * except.c (sjlj_emit_dispatch_table): Rewrite construction of the
2333         switch for dispatching.
2334         * tree-eh.c (lower_try_finally_switch): Update gimple_build_switch use.
2335         (lower_eh_dispatch): Likewise.
2336         * tree-vrp.c (execute_vrp): Use gimple_switch_label to get the case
2337         label at index 0 before turning it into a default case label.
2338         * omp-low.c (expand_omp_sections): Update gimple_build_switch use.
2339         * tree-switch-conversion.c (emit_case_bit_tests): Get the default case
2340         label using gimple_switch_default_label.
2341         (collect_switch_conv_info): Likewise.
2342         (process_switch): Likewise.
2343         * doc/gimple.texi: Update documentation of gimple_build_switch.
2344
2345 2012-09-04  Georg-Johann Lay  <avr@gjlay.de>
2346
2347         PR target/54476
2348         * config/avr/avr.c (avr_expand_delay_cycles): Mask operand with
2349         SImode.
2350
2351 2012-09-04  Bin Cheng  <bin.cheng@arm.com>
2352
2353         PR target/45070
2354         * config/arm/arm.c (thumb1_extra_regs_pushed): Handle return value
2355         of size less than 4 bytes by using macro ARM_NUM_INTS.
2356         (thumb1_unexpanded_epilogue): Use macro ARM_NUM_INTS.
2357
2358 2012-09-04  Richard Guenther  <rguenther@suse.de>
2359
2360         PR tree-optimization/54458
2361         * tree-ssa-threadupdate.c (thread_through_loop_header): If we
2362         turn the loop into one with multiple latches mark it so.
2363
2364 2012-09-04  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
2365
2366         PR target/54220
2367         * config/avr/avr.c (TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS): New
2368         define to...
2369         (avr_allocate_stack_slots_for_args): ...this new static function.
2370
2371 2012-09-04  Christophe Lyon  <christophe.lyon@linaro.org>
2372
2373         * config/arm/arm.c (arm_expand_builtin): Replace gen_rtx_CONST_INT
2374         by GEN_INT.
2375         (arm_emit_coreregs_64bit_shift): Likewise.
2376
2377 2012-09-04  Christophe Lyon  <christophe.lyon@linaro.org>
2378
2379         * config/arm/arm.c (arm_evpc_neon_vext): New function.
2380         (arm_expand_vec_perm_const_1): Add call to arm_evpc_neon_vext.
2381
2382 2012-09-04  Oleg Endo  <olegendo@gcc.gnu.org>
2383
2384         PR target/51244
2385         * config/sh/sh.c (prepare_cbranch_operands): Pull out comparison
2386         canonicalization code into...
2387         * (sh_canonicalize_comparison): This new function.
2388         * config/sh/sh-protos.h: Declare it.
2389         * config/sh/sh.h: Use it in new macro CANONICALIZE_COMPARISON.
2390         * config/sh/sh.md (cbranchsi4): Remove TARGET_CBRANCHDI4 check and
2391         always invoke expand_cbranchsi4.
2392
2393 2012-09-03  Andi Kleen  <ak@linux.intel.com>
2394
2395         * tree-ssa-sccvn.c (vn_reference_fold_indirect): Initialize
2396         addr_offset always.
2397
2398 2012-09-03  Andrew Pinski  <apinski@cavium.com>
2399
2400         PR tree-opt/53395
2401         * tree-if-conv.c (constant_or_ssa_name): New function.
2402         (fold_build_cond_expr): New function.
2403         (predicate_scalar_phi): Use fold_build_cond_expr instead of build3.
2404         (predicate_mem_writes): Likewise.
2405
2406 2012-09-03  Marc Glisse  <marc.glisse@inria.fr>
2407
2408         * fold-const.c (fold_ternary_loc): Constant-propagate after
2409         removing dead operands.
2410
2411 2012-09-03  Michael Matz  <matz@suse.de>
2412
2413         PR tree-optimization/46590
2414         * tree-cfg.c (gimple_duplicate_sese_region): Don't update
2415         SSA web here ...
2416         * tree-ssa-loop-ch.c (copy_loop_headers): ... but here.
2417
2418 2012-09-03  Sandra Loosemore  <sandra@codesourcery.com>
2419
2420         * doc/invoke.texi: Fix numerous typos and punctuation/grammatical
2421         errors throughout the file.  Re-word some awkward sentences and
2422         paragraphs.
2423
2424 2012-09-03  Richard Guenther  <rguenther@suse.de>
2425
2426         PR tree-optimization/54362
2427         * tree-ssa-structalias.c (find_func_aliases): Handle COND_EXPR.
2428
2429 2012-09-03  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
2430
2431         * config/s390/s390.c (s390_loadrelative_operand_p): New function.
2432         (s390_check_qrst_address, print_operand_address): Use
2433         s390_loadrelative_operand_p instead of s390_symref_operand_p.
2434         (s390_check_symref_alignment): Accept pointer size alignment for
2435         GOT slots.
2436         (legitimize_pic_address): Use load relative on z10 or later.
2437
2438 2012-09-03  Jakub Jelinek  <jakub@redhat.com>
2439
2440         PR debug/53923
2441         * valtrack.c (dead_debug_insert_temp): Drop non-reg uses
2442         from the chain.
2443
2444 2012-09-03  Joseph Myers  <joseph@codesourcery.com>
2445
2446         * common.opt (--no-sysroot-suffix): New driver option.
2447         * doc/invoke.texi (--no-sysroot-suffix): Document.
2448         * gcc.c (driver_handle_option): Handle --no-sysroot-suffix as not
2449         needing spec processing.
2450         (main): Do not process sysroot suffixes if no_sysroot_suffix.
2451
2452 2012-09-02  Oleg Endo  <olegendo@gcc.gnu.org>
2453
2454         PR target/33135
2455         * common/config/sh/sh-common.c: Update copyright years.
2456         (sh_option_init_struct): Delete.
2457         (TARGET_OPTION_INIT_STRUCT): Likewise.
2458
2459 2012-09-02  Oleg Endo  <olegendo@gcc.gnu.org>
2460
2461         PR target/54418
2462         * config/sh/sh.md (cmpgeusi_t): Remove N alternative.
2463         Check operands[1] in split condition instead of operands[0].
2464         Add comments.
2465
2466 2012-09-02  Mark Kettenis  <kettenis@openbsd.org>
2467
2468         * config.gcc (x86_64-*-openbsd*): New target.
2469         * config.host (*-*-openbsd*): New target.
2470         * config/openbsd.h (TARGET_C99_FUNCTIONS): Define.
2471         * config/i386/openbsdelf.h: Remove some superfluous defines and
2472         group things together in a more logical fashion.
2473         (DBX_REGISTER_NUMBER): Provide a
2474         definition that works on both 32-bit and 64-bit targets.
2475         (WCHAR_TYPE_SIZE): Hardcode as 32.
2476         (NO_DOLLAR_IN_LABEL): Remove undef.
2477         (TARGET_DEFAULT): Remove.
2478         (SET_ASM_OP): Remove.
2479         (DEFAULT_PCC_STRUCT_RETURN): Undef first to prevent warning.
2480         (ASM_OUTPUT_MAX_SKIP_ALIGN): Synch with x86-64.h
2481         (DWARF2_UNWIND_INFO): Remove define.
2482         (HAVE_ENABLE_EXECUTE_STACK): Define.
2483         * config/host-openbsd.c: New file.
2484         * config/t-openbsd (USER_H): Add EXTRA_HEADERS.
2485         * config/x-openbsd: New file.
2486
2487 2012-09-02  Oleg Endo  <olegendo@gcc.gnu.org>
2488
2489         * config/sh/sh.md (*extend<mode>si2_compact_mem_disp): Pass iterated
2490         mode to sh_legitimate_index_p instead of QImode.
2491
2492 2012-09-02  Eric Botcazou  <ebotcazou@adacore.com>
2493
2494         PR rtl-optimization/54369
2495         * config/mips/mips.c (mips_reorg): Invoke cleanup_barriers before
2496         calling dbr_schedule.
2497         * config/sparc/sparc.c (sparc_reorg): Likewise.
2498
2499 2012-09-01  Jakub Jelinek  <jakub@redhat.com>
2500
2501         PR target/54436
2502         * config/i386/i386.md (*mov<mode>_insv_1_rex64, *movsi_insv_1): If
2503         operands[1] is CONST_INT_P, convert it to QImode before printing.
2504
2505 2012-09-01  Andrew Pinski  <apinski@cavium.com>
2506
2507         * simplify-rtx.c (simplify_unary_operation_1 <case TRUNCATE>):
2508         A truncate of a memory is just loading the low part of the memory.
2509
2510 2012-09-01  Uros Bizjak  <ubizjak@gmail.com>
2511
2512         PR target/46829
2513         PR target/46843
2514         * config/i386/i386.c (ix86_legitimate_combined_insn): New function.
2515         (TARGET_LEGITIMATE_COMBINED_INSN): New macro.
2516
2517 2012-09-01  Uros Bizjak  <ubizjak@gmail.com>
2518
2519         * target.def (legitimate_combined_insn): New target hook.
2520         * doc/tm.texi.in (TARGET_LEGITIMATE_COMBINED_INSN): New hook.
2521         * doc/tm.texi: Regenerated.
2522         * combine.c (recog_for_combine): Call targetm.legitimate_combined_insn
2523         to allow targets to reject combined insn.
2524         * hooks.h (hook_bool_rtx_true): New.
2525         * hooks.c (hook_bool_rtx_true): Ditto.
2526
2527 2012-08-31  Martin Jambor  <mjambor@suse.cz>
2528
2529         * ipa-inline-analysis.c (estimate_function_body_sizes): Allocate
2530         nonconstant_names after calculate_dominance_info and
2531         loop_optimizer_init.
2532
2533 2012-08-31  Greta Yorsh  <Greta.Yorsh@arm.com>
2534
2535         * config/arm/arm.c (arm_expand_epilogue): Remove unused variable
2536         floats_from_frame.
2537
2538 2012-08-31  Martin Jambor  <mjambor@suse.cz>
2539
2540         PR middle-end/54409
2541         * ipa-inline-analysis.c (remap_predicate): Fix the offset_map
2542         checking condition.
2543
2544 2012-08-31  Martin Jambor  <mjambor@suse.cz>
2545
2546         * ipa-inline-analysis.c (phi_result_unknown_predicate): New function.
2547         (predicate_for_phi_result): Likewise.
2548         (estimate_function_body_sizes): Use the above two functions.
2549
2550 2012-08-31  Martin Jambor  <mjambor@suse.cz>
2551
2552         PR middle-end/54394
2553         * ipa-inline-analysis.c (estimate_function_body_sizes): Compute
2554         dominance info and loops whenever optimizing.
2555
2556 2012-08-29  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
2557             Richard Earnshaw  <richard.earnshaw@arm.com>
2558
2559         PR target/54252
2560         * config/arm/arm.c (neon_dereference_pointer): Adjust nelems by
2561         element size. Use elem_type from the formal parameter. New parameter
2562         fcode.
2563         (neon_expand_args): Adjust call to neon_dereference_pointer.
2564
2565 2012-08-29  Steven Bosscher  <steven@gcc.gnu.org>
2566
2567         * cfg.c (dump_bb_info): Print a newline if there were no edges to dump.
2568
2569 2012-08-29  Chung-Lin Tang  <cltang@codesourcery.com>
2570
2571         Revert:
2572         * config/mips/t-linux64 (MULTILIB_OSDIRNAMES): Change to use
2573         mapping style, add ../lib/mips16.
2574         (MULTILIB_OPTIONS,MULTILIB_DIRNAMES): Add mips16.
2575         (MULTILIB_EXCLUSIONS): Exclude mips16 when not -mabi=32.
2576
2577 2012-08-29  Richard Sandiford  <rdsandiford@googlemail.com>
2578
2579         * config/mips/mips.h (TARGET_CPU_CPP_BUILTINS): Define __mips_synci
2580         if TARGET_SYNCI.
2581
2582 2012-08-29  Oleg Endo  <olegendo@gcc.gnu.org>
2583
2584         * config/sh/sh.opt (menable-tas): Rename to mtas.
2585         * doc/invoke.texi (SH options): Likewise.
2586         * config/sh/sync.md: Update comments.
2587
2588 2012-08-29  Oleg Endo  <olegendo@gcc.gnu.org>
2589
2590         * config/sh/iterators.md: New file.
2591         * config/sh/sync.md (I124, I12, i124suffix): Delete.  Replace usage
2592         with new iterators QIHISI, QIHI, bw, bwl respectively throughout
2593         the file.
2594         * config/sh/sh.md: Include new file iterators.md.
2595         (zero_extendhisi2, zero_extendqisi2): Fold into zero_extend<mode>si2.
2596         (*zero_extendhisi2_compact, *zero_extendqisi2_compact): Fold into
2597         *zero_extend<mode>si2_compact.
2598         (*zero_extendqisi2_disp_mem, zero_extendhisi2_disp_mem): Fold into
2599         *zero_extend<mode>si2_disp_mem.
2600         (extendhisi2, extendqisi2): Fold into extend<mode>si2.
2601         (*extendqisi2_compact_reg, *extendhisi2_compact_reg): Fold into
2602         *extend<mode>si2_compact_reg.
2603         (*extendqisi2_compact_mem_disp, *extendhisi2_compact_mem_disp): Fold
2604         into *extend<mode>si2_compact_mem_disp.
2605         (*extendqisi2_compact_snd, *extendhisi2_compact_snd): Fold into
2606         *extend<mode>si2_compact_snd.
2607         (*movsi_index_disp, *movhi_index_disp): Fold with iterators and rename
2608         to *movsi_index_disp_load, *movhi_index_disp_load,
2609         *mov<mode>_index_disp_store.
2610         (*movqi_reg_reg, *movhi_reg_reg): Fold into *mov<mode>_reg_reg.
2611         (*movqi_store_mem_disp04, *movhi_store_mem_disp05): Fold into
2612         *mov<mode>_store_mem_disp04.
2613         (*movqi_store_mem_disp12, *movhi_store_mem_disp13): Fold into
2614         *mov<mode>_store_mem_disp12.
2615         (*movqi_load_mem_disp, *movhi_load_mem_disp): Fold into
2616         *mov<mode>_load_mem_disp04 and *mov<mode>_load_mem_disp12.
2617
2618 2012-08-29  Martin Jambor  <mjambor@suse.cz>
2619
2620         * ipa-inline.h (estimate_edge_hints): Call do_estimate_edge_hints, not
2621         do_estimate_edge_time.
2622
2623 2012-08-29  Chung-Lin Tang  <cltang@codesourcery.com>
2624
2625         * config/mips/mips.h (CRT_CALL_STATIC_FUNCTION): Add nomips16 asm
2626         directives, remove #ifndef __mips16 guards.
2627         * config/mips/t-linux64 (MULTILIB_OSDIRNAMES): Change to use
2628         mapping style, add ../lib/mips16.
2629         (MULTILIB_OPTIONS,MULTILIB_DIRNAMES): Add mips16.
2630         (MULTILIB_EXCLUSIONS): Exclude mips16 when not -mabi=32.
2631
2632 2012-08-28  Walter Lee  <walt@tilera.com>
2633         * confg/tilegx/tilegx.md: Fix code style.
2634         (*zero_extendsidi_truncdisi): Fix typo.
2635         * config/tilegx/tilegx.c: Fix code style.
2636         (tilegx_function_profiler): Fix typo.
2637
2638 2012-08-28  Walter Lee  <walt@tilera.com>
2639
2640         * doc/invoke.texi: Document -mcmodel=small, -mcmodel=large.
2641         * config/tilegx/tilegx.h: Include config/tilegx/tilegx-opts.h.
2642         (CRT_CALL_STATIC_FUNCTION): Define.
2643         * config/tilegx/predicates.md (const_last_symbolic_operand):
2644         Handle UNSPEC_HW2_LAST_PCREL, UNSPEC_HW1_LAST_PLT_PCREL, and
2645         UNSPEC_HW2_LAST_PLT_PCREL.
2646         (const_symbolic_operand): Handle UNSPEC_HW1_PCREL,
2647         UNSPEC_HW0_PLT_PCREL, and UNSPEC_HW1_PLT_PCREL.
2648         * config/tilegx/tilegx.md (UNSPEC_MOV_LARGE_PCREL_STEP4): Define,
2649         and renumber the constants that follow.
2650         (UNSPEC_HW1_PCREL): Ditto.
2651         (UNSPEC_HW2_LAST_PCREL): Ditto.
2652         (UNSPEC_HW0_PLT_PCREL): Define.
2653         (UNSPEC_HW1_PLT_PCREL): Define.
2654         (UNSPEC_HW1_LAST_PLT_PCREL): Define.
2655         (UNSPEC_HW2_LAST_PLT_PCREL): Define.
2656         (mov_large_pcrel_step1): Define.
2657         (mov_large_pcrel_step2): Define.
2658         (mov_large_pcrel_step3): Define.
2659         (mov_large_pcrel_step4): Define.
2660         (mov_plt_pcrel_step1): Define.
2661         (mov_plt_pcrel_step2): Define.
2662         (mov_plt_pcrel_step3): Define.
2663         (mov_plt_pcrel_step1_32bit): Define.
2664         (mov_plt_pcrel_step2_32bit): Define.
2665         (call): Handle tilegx_cmodel == CM_LARGE, CM_LARGE_PIC.
2666         (call_value): Ditto.
2667         * config/tilegx/tilegx.opt: Include config/tilegx/tilegx-opts.h.
2668         (mcmodel): New option.
2669         (enum cmodel): Define.
2670         (CM_SMALL): Define.
2671         (CM_LARGE): Define.
2672         * config/tilegx/tilegx-opts.h: New file.
2673         * config/tilegx/tilegx-protos.h (tilegx_compute_pcrel_address):
2674         Declare.
2675         (tilegx_compute_pcrel_plt_address): Declare.
2676         * config/tilegx/tilegx.c (tilegx_option_override): Handle
2677         tilegx_cmodel.
2678         (tilegx_function_ok_for_sibcall): Ditto.
2679         (compute_pcrel_address): Rename to tilegx_compute_pcrel_address,
2680         and don't declare static.  Handle tilegx_cmodel.
2681         (tilegx_compute_pcrel_plt_address): Define.
2682         (tilegx_legitimize_pic_address): Rename calls to
2683         compute_pcrel_address.
2684         (tilegx_delegitimize_address): Handle UNSPEC_HW1_PCREL,
2685         UNSPEC_HW2_LAST_PCREL, UNSPEC_HW0_PLT_PCREL, UNSPEC_HW1_PLT_PCREL,
2686         UNSPEC_HW1_LAST_PLT_PCREL, UNSPEC_HW2_LAST_PLT_PCREL.
2687         (load_pic_register): Rename call to compute_pcrel_address.
2688         (tilegx_print_operand): Handle UNSPEC_HW1_PCREL,
2689         UNSPEC_HW2_LAST_PCREL, UNSPEC_HW0_PLT_PCREL, UNSPEC_HW1_PLT_PCREL,
2690         UNSPEC_HW1_LAST_PLT_PCREL, UNSPEC_HW2_LAST_PLT_PCREL.
2691
2692 2012-08-27  Maxim Kuvyrkov  <maxim@codesourcery.com>
2693
2694         * sched-deps.c (add_dependence_list_and_free): Simplify.
2695         (flush_pending_list_and_free): Fix a hack that was fixing a hack.  Free
2696         lists when add_dependence_list_and_free doesn't free them.
2697
2698 2012-08-27  Uros Bizjak  <ubizjak@gmail.com>
2699
2700         PR target/46254
2701         * config/i386/predicates.md (cmpxchg8b_pic_memory_operand): Return
2702         true for TARGET_64BIT or !flag_pic.
2703         * config/i386/sync.md (*atomic_compare_and_swap_doubledi_pic): Remove.
2704         (atomic_compare_and_swap_double<mode>): Change operand 2 predicate
2705         to cmpxchg8b_pic_memory_operand.  Use DWIH mode iterator.
2706         Add insn constraint.  Conditionally emit xchg asm insns.
2707         (atomic_compare_and_swap<mode>): Update calls.  Check only
2708         cmpxchg8b_pic_memory_operand in memory address fixup.
2709         (DCASMODE): Remove.
2710         (CASHMODE): Rename from DCASHMODE.
2711         (doublemodesuffix): Update modes.
2712         (regprefix): New mode attribute.
2713
2714         (unspecv) <UNSPECV_CMPXCHG_{1,2,3,4}>: Remove.
2715         <UNSPECV_CMPXCHG>: New constant.
2716         (atomic_compare_and_swap<mode>_1): Rename from
2717         atomic_compare_and_swap_single<mode>.  Update calls and
2718         unspec_volatile constants.
2719         (atomic_compare_and_swap<mode>_doubleword): Rename from
2720         atomic_compare_and_swap_double<mode>.  Update calls and
2721         unspec_volatile constants.
2722
2723 2012-08-27  Walter Lee  <walt@tilera.com>
2724
2725         * doc/md.texi (TILE-Gx): Fix typo.
2726
2727 2012-08-27  Walter Lee  <walt@tilera.com>
2728
2729         * config/tilegx/tilegx.c (tilegx_function_profiler): Fix typo.
2730         * config/tilepro/tilepro.c (tilepro_function_profiler): Ditto.
2731
2732 2012-08-27  Walter Lee  <walt@tilera.com>
2733
2734         * config/tilegx/tilegx.md (*bfins): Rename to insn_bfins.
2735         (insn_bfins): Delete.
2736
2737 2012-08-27  Walter Lee  <walt@tilera.com>
2738
2739         * config/tilegx/sync.md (atomic_compare_and_swap_bare<mode>,
2740         atomic_exchange_bare<mode>,
2741         atomic_fetch_<fetchop_name>_bare<mode>): Set type to X1_remote.
2742         * config/tilegx/tilegx-generic.md (X1_remote): New
2743         insn_reservation.
2744         * config/tilegx/tilegx.md (type): Add X1_remove.
2745         (insn_cmpexch<four_if_si>, insn_exch<four_if_si>,
2746         insn_fetchadd<four_if_si>, insn_fetchaddgez<four_if_si>,
2747         insn_fetchand<four_if_si>, insn_fetchor<four_if_si>): Set type to
2748         X1_remote.
2749
2750 2012-08-27  Andreas Schwab  <schwab@linux-m68k.org>
2751
2752         * gdbinit.in: Fix syntax of skip command.
2753
2754 2012-08-27  Richard Sandiford  <rdsandiford@googlemail.com>
2755
2756         * config/mips/mips.c (mips_pic_call_symbol_from_set): Check for
2757         SYMBOL_REF SET_SRCs.
2758
2759 2012-08-27  Richard Sandiford  <rdsandiford@googlemail.com>
2760
2761         * config/mips/mips.c (vr4130_align_insns): Don't simulate
2762         ghost instructions.  Assert that the required instructions exist.
2763
2764 2012-08-26  Richard Sandiford  <rdsandiford@googlemail.com>
2765
2766         * config/mips/mips.h (AVOID_CCMODE_COPIES): Update rationale for
2767         definition.
2768         * config/mips/mips.c (machine_function): Add next_fcc.
2769         (mips_output_move): Remove handling of fcc moves.
2770         (mips_allocate_fcc): New function.
2771         (mips_emit_compare, mips_expand_vcondv2sf): Use it.
2772         (mips_hard_regno_mode_ok_p): Restrict CCmode to ST registers.
2773         Remove special case for CCmode reloads.
2774         (mips_expand_builtin_compare_1): Use mips_allocate_fcc and treat
2775         the result a fixed operand.
2776         * config/mips/mips.md (move_type): Remove lui_movf.
2777         (type, length): Remove references to it.
2778         (movcc, reload_incc, reload_outcc): Delete.
2779
2780 2012-08-26  Richard Sandiford  <rdsandiford@googlemail.com>
2781
2782         * config/mips/mips.c (mips_has_long_branch_p): New function,
2783         split out from...
2784         (mips_expand_ghost_gp_insns): ...here.  Look inside sequences.
2785
2786 2012-08-26  Richard Sandiford  <rdsandiford@googlemail.com>
2787
2788         * config/mips/mips.c (r10k_safe_mem_expr_p): Use get_inner_reference.
2789
2790 2012-08-26  Richard Sandiford  <rdsandiford@googlemail.com>
2791
2792         * config/mips/mips.c (mips_rtx_costs): Add costs for CINS.
2793
2794 2012-08-26  Richard Sandiford  <rdsandiford@googlemail.com>
2795
2796         * config/mips/mips.c (mips_rtx_costs): Add missing COSTS_N_INSNS
2797         to the size cost of multiplication.
2798
2799 2012-08-26  Gerald Pfeifer  <gerald@pfeifer.com>
2800
2801         * doc/install.texi (Specific): Clarify what needs to be added to
2802         this section.
2803
2804 2012-08-26  Gerald Pfeifer  <gerald@pfeifer.com>
2805
2806         * doc/tm.texi.in (Misc): Move descriptions of NO_DOLLAR_IN_LABEL
2807         and NO_DOT_IN_LABEL from here...
2808         (Label Output): ...to here.
2809         * doc/tm.texi: Regenerate.
2810
2811 2012-08-26  Gerald Pfeifer  <gerald@pfeifer.com>
2812
2813         * doc/invoke.texi (C++ Dialect Options): Add missing space.
2814
2815 2012-08-25  Eric Botcazou  <ebotcazou@adacore.com>
2816
2817         PR rtl-optimization/54088
2818         * jump.c (delete_related_insns): Robustify latest change.
2819
2820 2012-08-25  Ricardo Catalinas Jiménez  <jimenezrick@gmail.com>
2821
2822         * doc/extend.texi (__atomic Builtins): Remove space before comma.
2823
2824 2012-08-25  Richard Sandiford  <rdsandiford@googlemail.com>
2825             Andrew Pinski  <apinski@cavium.com>
2826
2827         * config/mips/mips.h (CASE_VECTOR_MODE): For not
2828         TARGET_MIPS16_SHORT_JUMP_TABLES use ptr_mode.
2829         (CASE_VECTOR_SHORTEN_MODE): Likewise.
2830
2831 2012-08-25  Uros Bizjak  <ubizjak@gmail.com>
2832
2833         * config/i386/i386.h (FP_REG_P): Remove macro.
2834         (FP_REGNO_P): Ditto.
2835         (HARD_REGNO_NREGS): Use STACK_REGNO_P instead of FP_REGNO_P.
2836         (HARD_REGNO_NREGS_HAS_PADDING): Ditto.
2837         (ANY_FP_REGNO_P): Ditto.
2838         (HARD_REGNO_RENAME_OK): Use STACK_REGNO_P.
2839         * config/i386/i386.c (output_387_ffreep): Use STACK_REGNO_P
2840         instead of FP_REGNO_P.
2841         (ix86_hard_regno_mode_ok): Ditto.
2842         * config/i386/predicates.md (fp_register_operand): Ditto.
2843         (register_and_not_fp_reg_operand): Ditto.
2844         * config/i386/sync.md (atomic_loaddi_fpu): Use STACK_REG_P instead
2845         of FP_REG_P.
2846
2847         * reg-stack.c (get_true_reg): Use STACK_REG_P instead of FP_REG_P.
2848
2849 2012-08-24  Jason Merrill  <jason@redhat.com>
2850
2851         * print-tree.c (print_node): Don't check TREE_LANG_FLAG_*
2852         on TREE_VEC or SSA_NAME.
2853
2854 2012-08-24  Jakub Jelinek  <jakub@redhat.com>
2855
2856         PR c/54363
2857         * gimplify.c (optimize_compound_literals_in_ctor): Only recurse
2858         if init is a CONSTRUCTOR.
2859
2860 2012-08-24  Steven Bosscher  <steven@gcc.gnu.org>
2861
2862         * tree-ssa-live.c (dump_var_map): Do not dump the partition
2863         map of virtual operands.
2864
2865 2012-08-24  Yuri Rumyantsev  <ysrumyan@gmail.com>
2866
2867         * config/i386/i386.c (ia32_multipass_dfa_lookahead) : Add
2868         case for Atom processor.
2869
2870 2012-08-24  Simon Baldwin  <simonb@google.com>
2871
2872         * dwarf2out.c (gen_producer_string): Omit command line switch if
2873         CL_NO_DWARF_RECORD flag set.
2874         * opts.h (CL_NO_DWARF_RECORD): New.
2875         * opt-functions.awk (switch_flags): Add NoDWARFRecord.
2876         * doc/options.texi: Document NoDWARFRecord option flag.
2877
2878 2012-08-24  H.J. Lu  <hongjiu.lu@intel.com>
2879
2880         PR debug/52857
2881         * dwarf2out.c (mem_loc_descriptor): Allow arg_pointer_rtx and
2882         frame_pointer_rtx for based_loc_descr.
2883
2884 2012-08-24  Martin Jambor  <mjambor@suse.cz>
2885
2886         * predict.c (maybe_hot_frequency_p): New parameter fun.  Use its decl
2887         instead of current_function_decl, use profile_status_for_function and
2888         ENTRY_BLOCK_PTR_FOR_FUNCTION with fun instead of their cfun variants.
2889         (maybe_hot_count_p): New parameter fun, use
2890         profile_status_for_function instead of its cfun_variant.
2891         (maybe_hot_bb_p): New parameter fun, checking-assert it, pass it to
2892         all callees.
2893         (maybe_hot_edge_p): Pass cfun to maybe_hot_count_p and
2894         maybe_hot_frequency_p.
2895         (probably_never_executed_bb_p): New parameter fun, use its decl
2896         instead of current_function_decl.
2897         (optimize_bb_for_size_p): Pass cfun to maybe_hot_bb_p.
2898         (rtl_profile_for_bb): Likewise.
2899         (compute_function_frequency): Pass cfun to maybe_hot_bb_p and
2900         probably_never_executed_bb_p.
2901         * tree-ssa-operands.c (ssa_operands_active): New operator fun.  Use it
2902         instead of cfun.
2903         (update_stmt_operands): Pass cfun as an argument of
2904         ssa_operands_active.
2905         (swap_tree_operands): Likewise.
2906         * gimple-iterator.c (update_modified_stmt): Likewise.
2907         (update_modified_stmts): Likewise.
2908         * tree-flow-inline.h (delink_stmt_imm_use): Likewise.
2909         * tree-ssa.c (delete_tree_ssa): Likewise.
2910         * bb-reorder.c (bb_to_key): Pass cfun to probably_never_executed_bb_p.
2911         (push_to_next_round_p): Likewise.
2912         (find_rarely_executed_basic_blocks_and_crossing_edges ): Likewise.
2913         * cfg.c: Inlude tree.h.
2914         (check_bb_profile): Use profile_status_for_function,
2915         EXIT_BLOCK_PTR_FOR_FUNCTION and ENTRY_BLOCK_PTR_FOR_FUNCTION with
2916         DECL_STRUCT_FUNCTION (current_function_decl) instead of their cfun
2917         variants.
2918         (dump_bb_info): Pass DECL_STRUCT_FUNCTION (current_function_decl) to
2919         maybe_hot_bb_p and probably_never_executed_bb_p.
2920         * gimple-pretty-print.c (gimple_dump_bb_buff): Checking-assert that
2921         DECL_STRUCT_FUNCTION (current_function_decl) is not NULL.  Pass it to
2922         dump_histograms_for_stmt.
2923         (dump_gimple_mem_ops): Pass
2924         DECL_STRUCT_FUNCTION (current_function_decl)
2925         as an argument to dump_gimple_mem_ops.
2926         * tree-cfg.c (dump_function_to_file): Rename parameter fn to fndecl.
2927         Do not change cfun.  Change and restore current_function_decl.
2928         * Makefile.in (cfg.o): Include TREE_H in dependencies.
2929
2930 2012-08-24  Georg-Johann Lay  <avr@gjlay.de>
2931
2932         PR target/54222
2933         * avr-modes.def (HA, SA, DA, TA, UTA): Adjust modes.
2934         * avr/avr-fixed.md: New file.
2935         * avr/avr.md: Include it.
2936         (cc): Add: minus.
2937         (adjust_len): Add: minus, minus64, ufract, sfract.
2938         (ALL1, ALL2, ALL4, ORDERED234): New mode iterators.
2939         (MOVMODE): Add: QQ, UQQ, HQ, UHQ, HA, UHA, SQ, USQ, SA, USA.
2940         (MPUSH): Add: HQ, UHQ, HA, UHA, SQ, USQ, SA, USA.
2941         (pushqi1, xload8_A, xload_8, movqi_insn, *reload_inqi, addqi3,
2942         subqi3, ashlqi3, *ashlqi3, ashrqi3, lshrqi3, *lshrqi3, *cmpqi,
2943         cbranchqi4, *cpse.eq): Generalize to handle all 8-bit modes in ALL1.
2944         (*movhi, reload_inhi, addhi3, *addhi3, addhi3_clobber, subhi3,
2945         ashlhi3, *ashlhi3_const, ashrhi3, *ashirhi3_const, lshrhi3,
2946         *lshrhi3_const, *cmphi, cbranchhi4): Generalize to handle all
2947         16-bit modes in ALL2.
2948         (subhi3, casesi, strlenhi): Add clobber when expanding minus:HI.
2949         (*movsi, *reload_insi, addsi3, subsi3, ashlsi3, *ashlsi3_const,
2950         ashrsi3, *ashrhi3_const, *ashrsi3_const, lshrsi3, *lshrsi3_const,
2951         *reversed_tstsi, *cmpsi, cbranchsi4): Generalize to handle all
2952         32-bit modes in ALL4.
2953         * avr-dimode.md (ALL8): New mode iterator.
2954         (adddi3, adddi3_insn, adddi3_const_insn, subdi3, subdi3_insn,
2955         subdi3_const_insn, cbranchdi4, compare_di2,
2956         compare_const_di2, ashrdi3, lshrdi3, rotldi3, ashldi3_insn,
2957         ashrdi3_insn, lshrdi3_insn, rotldi3_insn): Generalize to handle
2958         all 64-bit modes in ALL8.
2959         * config/avr/avr-protos.h (avr_to_int_mode): New prototype.
2960         (avr_out_fract, avr_out_minus, avr_out_minus64): New prototypes.
2961         * config/avr/avr.c (TARGET_FIXED_POINT_SUPPORTED_P): Define to...
2962         (avr_fixed_point_supported_p): ...this new static function.
2963         (TARGET_BUILD_BUILTIN_VA_LIST): Define to...
2964         (avr_build_builtin_va_list): ...this new static function.
2965         (avr_adjust_type_node): New static function.
2966         (avr_scalar_mode_supported_p): Allow if ALL_FIXED_POINT_MODE_P.
2967         (avr_builtin_setjmp_frame_value): Use gen_subhi3 and return new
2968         pseudo instead of gen_rtx_MINUS.
2969         (avr_print_operand, avr_operand_rtx_cost): Handle: CONST_FIXED.
2970         (notice_update_cc): Handle: CC_MINUS.
2971         (output_movqi): Generalize to handle respective fixed-point modes.
2972         (output_movhi, output_movsisf, avr_2word_insn_p): Ditto.
2973         (avr_out_compare, avr_out_plus_1): Also handle fixed-point modes.
2974         (avr_assemble_integer): Ditto.
2975         (output_reload_in_const, output_reload_insisf): Ditto.
2976         (avr_compare_pattern): Skip all modes > 4 bytes.
2977         (avr_2word_insn_p): Skip movuqq_insn, movqq_insn.
2978         (avr_out_fract, avr_out_minus, avr_out_minus64): New functions.
2979         (avr_to_int_mode): New function.
2980         (adjust_insn_length): Handle: ADJUST_LEN_SFRACT,
2981         ADJUST_LEN_UFRACT, ADJUST_LEN_MINUS, ADJUST_LEN_MINUS64.
2982         * config/avr/predicates.md (const0_operand): Allow const_fixed.
2983         (const_operand, const_or_immediate_operand): New.
2984         (nonmemory_or_const_operand): New.
2985         * config/avr/constraints.md (Ynn, Y00, Y01, Y02, Ym1, Ym2, YIJ):
2986         New constraints.
2987         * config/avr/avr.h (LONG_LONG_ACCUM_TYPE_SIZE): Define.
2988
2989 2012-08-23  Kenneth Zadeck <zadeck@naturalbridge.com>
2990
2991         * alias.c (rtx_equal_for_memref_p): Convert constant cases.
2992         * combine.c (find_single_use_1, mark_used_regs_combine): Convert
2993         to CASE_CONST_ANY.
2994         * cse.c (exp_equiv_p, canon_reg, fold_rtx, cse_process_notes_1,
2995         count_reg_usage): Convert constant cases.
2996         * cselib.c (cselib_expand_value_rtx_1): Convert to CASE_CONST_ANY.
2997         (cselib_subst_to_values): Convert constant cases.
2998         * df-scan.c (df_uses_record): Ditto.
2999         * dse.c (const_or_frame_p): Convert case statements to explicit
3000         if-then-else using mode classes.
3001         * emit-rtl.c (verify_rtx_sharing, copy_insn_1): Convert constant cases.
3002         * explow.c (convert_memory_address_addr_space): Ditto.
3003         * gcse.c (want_to_gcse_p, oprs_unchanged_p, compute_transp): Ditto.
3004         * genattrtab.c (attr_copy_rtx, clear_struct_flag): Ditto.
3005         * ira.c (equiv_init_varies_p, contains_replace_regs,
3006         memref_referenced_p, rtx_moveable_p): Ditto.
3007         * jump.c (mark_jump_label_1): Remove constant cases.
3008         (rtx_renumbered_equal_p): Convert to CASE_CONST_UNIQUE.
3009         * loop-invariant.c (check_maybe_invariant, hash_invariant_expr_1,
3010         invariant_expr_equal_p): Convert to CASE_CONST_ANY.
3011         * postreload-gcse.c (oprs_unchanged_p): Convert constant cases.
3012         * reginfo.c (reg_scan_mark_refs): Ditto.
3013         * regrename.c (scan_rtx): Ditto.
3014         * reload1.c (eliminate_regs_1, elimination_effects,
3015         scan_paradoxical_subregs): Ditto.
3016         * reload.c (operands_match_p, subst_reg_equivs):  Ditto.
3017         * resource.c (mark_referenced_resources, mark_set_resources): Ditto.
3018         * rtlanal.c (rtx_unstable_p, rtx_varies_p, count_occurrences)
3019         (reg_mentioned_p, modified_between_p, modified_in_p)
3020         (volatile_insn_p, volatile_refs_p, side_effects_p, may_trap_p_1,
3021         inequality_comparisons_p, computed_jump_p_1): Ditto.
3022         * rtl.c (copy_rtx, rtx_equal_p_cb, rtx_equal_p): Ditto.
3023         * sched-deps.c (sched_analyze_2): Ditto.
3024         * valtrack.c (cleanup_auto_inc_dec): Ditto.
3025         * rtl.h: (CASE_CONST_SCALAR_INT, CASE_CONST_UNIQUE,
3026         CASE_CONST_ANY): New macros.
3027
3028 2012-08-23  Julian Brown  <julian@codesourcery.com>
3029             Sandra Loosemore  <sandra@codesourcery.com>
3030
3031         * config/mips/mips.md
3032         (UNSPEC_CASESI_DISPATCH): New.
3033         (MIPS16_T_REGNUM): New constant.
3034         (tablejump): Don't use for MIPS16_SHORT_JUMP_TABLES.
3035         (casesi): New.
3036         (casesi_internal_mips16_<mode>): New.
3037         * config/mips/mips.c (mips16_split_long_branches): Adjust test
3038         to ignore casesi jump tables.
3039         * config/mips/mips.h (TARGET_MIPS16_SHORT_JUMP_TABLES): Update
3040         comment.
3041         (CASE_VECTOR_MODE): Use SImode unconditionally.
3042         (CASE_VECTOR_SHORTEN_MODE): Define.
3043         (ASM_OUTPUT_ADDR_DIFF_ELT): Output word-sized addr_diff_elts
3044         when necessary for MIPS16_SHORT_JUMP_TABLES.
3045
3046 2012-08-23  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
3047
3048         * config/rs6000/rs6000.c (rs6000_density_test): Free loop body.
3049
3050 2012-08-23  H.J. Lu  <hongjiu.lu@intel.com>
3051
3052         PR driver/54335
3053         * doc/invoke.texi: Add -da and remove -dm.
3054
3055 2012-08-23  Richard Guenther  <rguenther@suse.de>
3056
3057         * tree-vect-stmts.c (vect_finish_stmt_generation): Update
3058         virtual SSA form.
3059
3060 2012-08-23  Jakub Jelinek  <jakub@redhat.com>
3061
3062         * tree.c (copy_node_stat): Clear DECL_STRUCT_FUNCTION.
3063
3064 2012-08-23  Mingjie Xing  <mingjie.xing@gmail.com>
3065
3066         * doc/gty.texi: Fix typo.
3067
3068 2012-08-23  Richard Guenther  <rguenther@suse.de>
3069
3070         * tree-ssa-loop-manip.c (add_exit_phis_var): Allow virtual operands.
3071         (find_uses_to_rename_use): Likewise.
3072         (find_uses_to_rename_bb): Likewise.
3073         (find_uses_to_rename_stmt): Walk over all operands.
3074
3075 2012-08-22  Oleg Endo  <olegendo@gcc.gnu.org>
3076
3077         PR target/54089
3078         * config/sh/predicates (p27_rshift_count_operand,
3079         not_p27_rshift_count_operand): New predicates.
3080         * config/sh/sh.c (sh_ashlsi_clobbers_t_reg_p,
3081         sh_lshrsi_clobbers_t_reg_p, sh_dynamicalize_shift_p): Handle special
3082         case when shift amount is 31.
3083         (gen_ashift): Emit gen_shlr instead of gen_lshrsi3_m.
3084         * config/sh/sh.md (ashlsi3_d): Set type to 'dyn_shift' instead
3085         of 'arith'.
3086         (ashlsi_c): Rename to shll.  Adapt calls to gen_ashlsi_c throughout
3087         the file.
3088         (lshrsi3): Remove clobber from expander.  Use shift_count_operand
3089         instead of nonmemory_operand predicate for second operand.  Add
3090         handling of case lshrsi3_n_clobbers_t.
3091         (lshrsi3_k): Use p27_rshift_count_operand for second operand.
3092         (lshrsi3_d): Make insn_and_split.  Split dynamic shift to constant
3093         shift sequences if beneficial.
3094         (lshrsi3_n): Make insn_and_split.  Split constant shift sequence to
3095         dynamic shift if beneficial.
3096         (lshrsi3_n_clobbers_t): New insn_and_split.
3097         (lshrsi3_m): Delete.
3098
3099 2012-08-22  Steven Bosscher  <steven@gcc.gnu.org>
3100
3101         * tracer.c (mark_bb_seen): Use SBITMAP_SIZE.
3102
3103         * alias.c (MAX_ALIAS_LOOP_PASSES): Update comment with rationale,
3104         or rather a lack thereof.
3105         (init_alias_analysis): Propagate the latest information across
3106         the CFG in topological order to propagate as far as possible in
3107         each iteration.  Ignore debug insns.
3108
3109 2012-08-22  H.J. Lu  <hongjiu.lu@intel.com>
3110
3111         * doc/invoke.texi: Document -mlong-double-64/-mlong-double-80.
3112
3113         * config/i386/i386.c (flag_opts): Add -mlong-double-64.
3114         (TARGET_HAS_BIONIC): Default long double to 64-bit for Bionic.
3115
3116         * config/i386/i386.h (LONG_DOUBLE_TYPE_SIZE): Use 64 if
3117         TARGET_LONG_DOUBLE_64 is true.
3118         (LIBGCC2_LONG_DOUBLE_TYPE_SIZE): New macro.
3119         (WIDEST_HARDWARE_FP_SIZE): Defined to 80.
3120
3121         * config/i386/i386.opt (mlong-double-80): New option.
3122         (mlong-double-64): Likewise.
3123
3124         * config/i386/i386-c.c (ix86_target_macros): Define
3125         __LONG_DOUBLE_64__ for TARGET_LONG_DOUBLE_64.
3126
3127 2012-08-22  H.J. Lu  <hongjiu.lu@intel.com>
3128
3129         PR target/54347
3130         * config/i386/i386.c (ix86_split_to_parts): Replace
3131         REAL_VALUE_TO_TARGET_LONG_DOUBLE with real_to_target.
3132
3133 2012-08-22  Richard Guenther  <rguenther@suse.de>
3134
3135         * tree-vectorizer.c (vectorize_loops): Do not call
3136         mark_virtual_operands_for_renaming.
3137         * tree-vect-slp.c (vect_slp_transform_bb): Likewise.
3138         Do not update SSA form here.
3139
3140 2012-08-22  Dodji Seketeli  <dodji@redhat.com>
3141
3142         * tree.h (TREE_NOTHROW): Use the base.nothrow_flag.
3143
3144 2012-08-22  Richard Guenther  <rguenther@suse.de>
3145
3146         PR tree-optimization/46590
3147         * tree-ssa-alias.h (get_continuation_for_phi): Add alias query
3148         counter output argument.
3149         (walk_non_aliased_vuses): Add alias query counter argument
3150         to the walker callback.
3151         * tree-ssa-alias.c (maybe_skip_until): Add alias query counter
3152         output argument and count alias queries.
3153         (get_continuation_for_phi_1): Likewise.
3154         (get_continuation_for_phi): Likewise.
3155         (walk_non_aliased_vuses): Add alias query counter argument
3156         to the walker callback and allow it to abort the walk by
3157         returning -1.
3158         * tree-ssa-pre.c (translate_vuse_through_block): Adjust.
3159         * tree-ssa-sccvn.c (vn_reference_lookup_2): Add alias query
3160         counter parmeter, abort walk if that is bigger than
3161         --param sccvn-max-alias-queries-per-access.
3162         * params.def (sccvn-max-alias-queries-per-access): New param.
3163         * doc/invoke.texi (sccvn-max-alias-queries-per-access): Document.
3164
3165 2012-08-22  Richard Guenther  <rguenther@suse.de>
3166
3167         * tree-ssa-loop-ch.c (copy_loop_headers): Remove redundant checking.
3168         * tree-into-ssa.c (initialize_flags_in_bb): Use gcc_checking_assert
3169         instead of gcc_assert.
3170         (mark_block_for_update): Likewise.
3171         (add_new_name_mapping): Likewise.
3172         (mark_def_sites): Likewise.
3173         (insert_phi_nodes_for): Likewise.
3174         (rewrite_debug_stmt_uses): Likewise.
3175         (rewrite_stmt): Likewise.
3176         (maybe_register_def): Likewise.
3177         (rewrite_update_phi_arguments): Likewise.
3178         (rewrite_update_enter_block): Likewise.
3179         (mark_def_interesting): Likewise.
3180         (prepare_def_site_for): Likewise.
3181         (insert_updated_phi_nodes_for): Likewise.
3182
3183 2012-08-22  Jakub Jelinek  <jakub@redhat.com>
3184
3185         * tree-vect-loop.c (vect_transform_loop): Initialize
3186         check_profitability to false.
3187
3188         * tree-predcom.c (try_combine_chains): Free the worklist vector
3189         at the end.
3190
3191 2012-08-22  Marc Glisse  <marc.glisse@inria.fr>
3192
3193         PR tree-optimization/54317
3194         * tree-vrp.c (extract_range_from_binary_expr_1): Test for
3195         double_int overflow.
3196         Remove dead tests.
3197
3198 2012-08-22  Jakub Jelinek  <jakub@redhat.com>
3199
3200         * tree-vrp.c (find_assert_locations): Skip also edges
3201         from the entry block.
3202
3203         * tree-vect-loop-manip.c (slpeel_make_loop_iterate_ntimes): Call
3204         free_stmt_vec_info on orig_cond after gsi_removing it.
3205         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Always
3206         free body_cost_vec vector.
3207         (vect_analyze_data_refs): If gather is unsuccessful,
3208         free_data_ref (dr).
3209         * tree-inline.c (tree_function_versioning): Free
3210         old_transforms_to_apply vector.
3211
3212 2012-08-22  Steven Bosscher  <steven@gcc.gnu.org>
3213
3214         * tree-ssa-coalesce.c (struct ssa_conflicts_d): Make contents
3215         of this a VEC and add a bitmap obstack.
3216         (ssa_conflicts_new): Allocate the obstack and grow the VEC cleared
3217         to the right size.
3218         (ssa_conflicts_delete): Free the VEC and release the obstack.
3219         (ssa_conflicts_test_p, ssa_conflicts_test_p, ssa_conflicts_add_one,
3220         ssa_conflicts_merge, ssa_conflicts_dump): Update for above changes.
3221         (truct live_track_d): Add another bitmap obstack here.
3222         (new_live_track): Initialize it and use it for all bitmaps.
3223         (delete_live_track): Don't free the bitmaps one at a time, just
3224         release the obstack.
3225         (create_outofssa_var_map): Fix to conform to GCC code style rules.
3226
3227 2012-08-21  Nathan Froyd  <froydnj@gcc.gnu.org>
3228
3229         * config/m32c/constraints.md: New file.
3230         * config/m32c/t-m32c (MD_FILES): Add constraints.
3231         * config/m32c/m32c-protos.h (m32c_const_ok_for_constraint_p): Delete.
3232         (m32c_extra_address_constraint, m32c_extra_memory_constraint): Delete.
3233         (m32c_reg_class_from_constraint): Delete.
3234         (m32c_extra_constraint_p, m32c_extra_constraint_p2): Delete.
3235         (m32c_matches_constraint_p): Declare.
3236         * config/m32c/m32c.h (CONSTRAINT_LEN): Delete.
3237         (REG_CLASS_FROM_CONSTRAINT): Delete.
3238         (CONST_OK_FOR_CONSTRAINT_P): Delete.
3239         (CONST_DOUBLE_OK_FOR_CONSTRAINT_P): Delete.
3240         (EXTRA_CONSTRAINT_STR): Delete.
3241         (EXTRA_MEMORY_CONSTRAINT, EXTRA_ADDRESS_CONSTRAINT): Delete.
3242         * config/m32c/m32c.c: Include tm-constrs.h
3243         (m32c_reg_class_from_constraint): Delete.
3244         (m32c_const_ok_for_constraint_p): Delete.
3245         (m32c_extra_constraint_p2): Rename to...
3246         (m32c_matches_constraint_p): ...this.  Make it return bool.  Tweak
3247         formatting.
3248         (m32c_extra_constraint_p): Delete.
3249         (m32c_extra_address_constraint, m32c_extra_memory_constraint): Delete.
3250         (m32c_split_move): Use satisfies_constraint_Ss.
3251         * config/m32c/predicates.md (memsym_operand): Use
3252         satisfies_constraint_Si.
3253         (memimmed_operand): Use satisfies_constraint_Sp.
3254         (m32c_psi_scale, m32c_1bit8_operand): Use satisfies_constraint_Ilb.
3255         (m32c_1bit16_operand): Use satisfies_constraint_Ilw.
3256         (m32c_1mask8_operand): Use satisfies_constraint_ImB.
3257         (m32c_1mask16_operand): Use satisfies_constraint_Imw.
3258
3259 2012-08-21  Nathan Froyd  <froydnj@gcc.gnu.org>
3260
3261         * config/mep/mep.h (REG_CLASS_FROM_CONSTRAINT): Delete.
3262         (CONST_OK_FOR_LETTER_P, CONST_DOUBLE_OK_FOR_LETTER_P): Delete.
3263         (CONSTRAINT_LEN, EXTRA_CONSTRAINT): Delete.
3264         * config/mep/mep.c (mep_reg_class_from_constraint): Delete.
3265         (mep_const_ok_for_letter_p, mep_extra_constraint): Delete.
3266         * config/mep/mep-protos.h (mep_reg_class_from_constraint): Delete.
3267         (mep_const_ok_for_letter_p, mep_extra_constraint): Delete.
3268
3269 2012-08-21  Oleg Endo  <olegendo@gcc.gnu.org>
3270
3271         * config/sh/sh.md (cmpeqdi_t, cmpgtdi_t, cmpgedi_t, cmpgeudi_t,
3272         cmpgtudi_t, *movsicc_t_false, *movsicc_t_true, divsi_inv20, negsi_cond,
3273         truncdihi2, ic_invalidate_line_i, ic_invalidate_line_sh4a,
3274         ic_invalidate_line_media, movdf_i4, calli_pcrel, call_valuei,
3275         call_valuei_pcrel, sibcalli_pcrel, sibcall_compact,
3276         sibcall_valuei_pcrel, sibcall_value_compact, casesi_worker_1,
3277         casesi_worker_2, bandreg_m2a, borreg_m2a, bxorreg_m2a, sp_switch_1,
3278         sp_switch_2, stack_protect_set_si, stack_protect_set_si_media,
3279         stack_protect_set_di_media, stack_protect_test_si,
3280         stack_protect_test_si_media, stack_protect_test_di_media): Convert to
3281         multi-line asm output strings.
3282         (divsi_inv_qitable, divsi_inv_hitable): Use single-alternative asm
3283         output.
3284         (*andsi3_bclr, rotldi3_mextr, rotrdi3_mextr, calli,
3285         call_valuei_tbr_rel, movml_push_banked, movml_pop_banked, bclr_m2a,
3286         bclrmem_m2a, bset_m2a, bsetmem_m2a, bst_m2a, bld_m2a, bldsign_m2a,
3287         bld_reg, *bld_regqi, band_m2a, bor_m2a, bxor_m2a, mextr_rl, *mextr_lr):
3288         Use tab char instead of '\\t'.
3289         (iordi3): Use braced string.
3290         (*movsi_pop): Use tab chars instead of spaces.
3291
3292 2012-08-21  Oleg Endo  <olegendo@gcc.gnu.org>
3293
3294         PR target/39423
3295         * config/sh/sh.md (*movhi_index_disp): Add support for SH2A
3296         movu.w insn.
3297
3298 2012-08-21  H.J. Lu  <hongjiu.lu@intel.com>
3299
3300         PR middle-end/54332
3301         * df-scan.c (df_bb_verify): Restore df_free_collection_rec call
3302         inside the insn traversal loop.
3303
3304         * vec.h (vec_reserve): Remove the stack allocation check.
3305
3306 2012-08-21  Marc Glisse  <marc.glisse@inria.fr>
3307
3308         * fold-const.c (fold_ternary_loc): Detect identity permutations.
3309         Canonicalize permutations more.
3310         * tree-ssa-forwprop.c (is_combined_permutation_identity): New function.
3311         (simplify_permutation): Likewise.
3312         (ssa_forward_propagate_and_combine): Call it.
3313
3314 2012-08-21  Richard Guenther  <rguenther@suse.de>
3315
3316         * tree-ssa-loop-im.c (tree_ssa_lim_finalize): Properly free
3317         the affine expansion cache.
3318         * tree-ssa-dom.c (free_expr_hash_elt_contents): New function,
3319         split out from ...
3320         (free_expr_hash_elt): ... this one.
3321         (record_cond): Properly free a not needed hashtable element.
3322         (lookup_avail_expr): Likewise.
3323         * tree-into-ssa.c (init_ssa_renamer): Specify a free function
3324         for the var_infos hashtable.
3325         (update_ssa): Likewise.
3326
3327 2012-08-21  Richard Guenther  <rguenther@suse.de>
3328
3329         * alloc-pool.c (pool_alloc): Fix valgrind annotation.
3330         * tree.h: Fix typo and complete flags documentation.
3331
3332 2012-08-21  Richard Guenther  <rguenther@suse.de>
3333
3334         * tree.h (struct tree_base): Add union to make it possible to
3335         re-use the upper 4 bytes for tree codes that do not need as
3336         many flags as others.  Move visited and default_def_flag to
3337         common bits section in exchange for saturating_flag and
3338         unsigned_flag.  Add SSA name version and tree vec length
3339         fields here.
3340         (struct tree_vec): Remove length field here.
3341         (struct tree_ssa_name): Remove version field here.
3342
3343 2012-08-20  Jan Hubicka  <jh@suse.cz>
3344
3345         PR fortran/48636
3346         * ipa-inline.c (want_inline_small_function_p): Take loop_iterations
3347         hint.
3348         (edge_badness): Likewise.
3349         * ipa-inline.h (inline_hints_vals): Add INLINE_HINT_loop_iterations.
3350         (inline_summary): Add loop_iterations.
3351         * ipa-inline-analysis.c: Include tree-scalar-evolution.h.
3352         (dump_inline_hints): Dump loop_iterations.
3353         (reset_inline_summary): Free loop_iterations.
3354         (inline_node_duplication_hook): Update loop_iterations.
3355         (dump_inline_summary): Dump loop_iterations.
3356         (will_be_nonconstant_expr_predicate): New function.
3357         (estimate_function_body_sizes): Analyze loops.
3358         (estimate_node_size_and_time): Set hint loop_iterations.
3359         (inline_merge_summary): Merge loop iterations.
3360         (inline_read_section): Stream in loop_iterations.
3361         (inline_write_summary): Stream out loop_iterations.
3362
3363 2012-08-20  Florian Weimer  <fweimer@redhat.com>
3364
3365         PR c++/19351
3366         * call.c (build_operator_new_call): Add size_check argument and
3367         evaluate it.
3368         * cp-tree.h (build_operator_new_call): Adjust declaration.
3369         * init.c (build_new_1): Compute array size check and apply it.
3370
3371 2012-08-20  Oleg Endo  <olegendo@gcc.gnu.org>
3372
3373         PR target/54089
3374         * config/sh/sh.md (rotcr, *rotcr, shar, shlr): New insns and splits.
3375         (ashrdi3_k, lshrdi3_k): Rewrite as insn_and_split.
3376         * config/sh/sh.c (sh_lshrsi_clobbers_t_reg_p): New function.
3377         * config/sh/sh-protos.h (sh_lshrsi_clobbers_t_reg_p): Declare it.
3378
3379 2012-08-20  Oleg Endo  <olegendo@gcc.gnu.org>
3380
3381         PR target/51244
3382         * config/sh/sh.md (*cset_zero): New insns.
3383
3384 2012-08-20  Mark Wielaard  <mjw@redhat.com>
3385
3386         * dwarf2out.h (enum dw_val_class): Add dw_val_class_high_pc.
3387         * dwarf2out.c (dw_val_equal_p): Handle dw_val_class_high_pc.
3388         (add_AT_low_high_pc): New function.
3389         (AT_lbl): Handle dw_val_class_high_pc.
3390         (print_die): Likewise.
3391         (attr_checksum): Likewise.
3392         (attr_checksum_ordered): Likewise.
3393         (same_dw_val_p): Likewise.
3394         (size_of_die): Likewise.
3395         (value_format): Likewise.
3396         (output_die): Likewise.
3397         (gen_subprogram_die): Use add_AT_low_high_pc.
3398         (add_high_low_attributes): Likewise.
3399         (dwarf2out_finish): Likewise.
3400
3401 2012-08-20  Jakub Jelinek  <jakub@redhat.com>
3402
3403         PR rtl-optimization/54294
3404         * fwprop.c (all_uses_available_at): Ignore debug insns in between
3405         def_insn and target_insn when checking whether the shortcut is
3406         possible.
3407
3408 2012-08-20  Eric Botcazou  <ebotcazou@adacore.com>
3409
3410         * config/sparc/sparc.h (MAX_FIXED_MODE_SIZE): Define.
3411
3412 2012-08-20  Patrick Marlier  <patrick.marlier@gmail.com>
3413
3414         PR middle-end/53992
3415         * omp-low.c (lower_omp_1): Handle GIMPLE_TRANSACTION.
3416
3417 2012-08-20  Richard Earnshaw  <rearnsha@arm.com>
3418
3419         PR tree-ssa/54295
3420         * tree-ssa-math-opts.c (is_widening_mult_rhs_p): Delete rhs_code
3421         declaration and setter.
3422
3423 2012-08-20  Richard Earnshaw  <rearnsha@arm.com>
3424
3425         PR tree-ssa/54295
3426         * tree-ssa-math-opts.c (widening_mult_conversion_strippable_p):
3427         New function.
3428         (is_widening_mult_rhs_p): Use it.
3429
3430 2012-08-20  Joseph Myers  <joseph@codesourcery.com>
3431
3432         * configure.ac (ffs): Check for declaration.
3433         * configure, config.in: Regenerate.
3434
3435 2012-08-20  Richard Guenther  <rguenther@suse.de>
3436
3437         * tree-flow.h (register_new_name_mapping): Remove.
3438         * tree-into-ssa.c (register_new_name_mapping): Likewise.
3439         (add_new_name_mapping): Do not push/pop timevar here.
3440         (create_new_def_for): Instead do it here.  Initialize
3441         update-ssa here, handle a NULL def.
3442         * tree-vrp.c (build_assert_expr_for): Use create_new_def_for.
3443
3444 2012-08-20  Richard Guenther  <rguenther@suse.de>
3445
3446         PR tree-optimization/54327
3447         * gimple-fold.c (get_maxval_strlen): Do not walk use-def chains
3448         if the use is registered for SSA update.
3449
3450 2012-08-20  Jakub Jelinek  <jakub@redhat.com>
3451
3452         PR tree-optimization/54321
3453         * tree-ssa-forwprop.c (simplify_builtin_call): Pass 0 instead of 1
3454         as second argument to tree_low_cst call on val2.
3455
3456 2012-08-20  Richard Guenther  <rguenther@suse.de>
3457
3458         * gimple.h (gimple_statement_base): Annotate with GTY chain_next.
3459
3460 2012-08-20  Richard Guenther  <rguenther@suse.de>
3461
3462         PR bootstrap/54326
3463         * genoutput.c (note_constraint): Properly use CONST_CAST.
3464
3465 2012-08-19  Nick Clifton  <nickc@redhat.com>
3466
3467         PR target/54306
3468         * config/arm/mmintrin.h: Remove spurious #endif.
3469
3470 2012-08-18  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
3471
3472         * config/avr/avr-log.c (avr_log_vadump): Properly use
3473         int-promoted enum values.
3474         * config/avr/avr.h (struct mcu_type_s): Change `arch' from
3475         int to enum avr_arch.
3476         * config/avr/gen-avr-mmcu-texi.c (main): Use correct initializer.
3477
3478 2012-08-18  Jan Hubicka  <jh@suse.cz>
3479
3480         PR lto/45375
3481         * ipa-inline.c (want_inline_small_function_p): Bypass
3482         inline limits for hinted functions.
3483         (edge_badness): Dump hints; decrease badness for hinted funcitons.
3484         * ipa-inline.h (enum inline_hints_vals): New enum.
3485         (inline_hints): New type.
3486         (edge_growth_cache_entry): Add hints.
3487         (dump_inline_summary): Update.
3488         (dump_inline_hints): Declare.
3489         (do_estimate_edge_hints): Declare.
3490         (estimate_edge_hints): New inline function.
3491         (reset_edge_growth_cache): Update.
3492         * predict.c (cgraph_maybe_hot_edge_p): Do not ice on indirect edges.
3493         * ipa-inline-analysis.c (dump_inline_hints): New function.
3494         (estimate_edge_devirt_benefit): Return true when function should be
3495         hinted.
3496         (estimate_calls_size_and_time): New hints argument; set it when
3497         devritualization happens.
3498         (estimate_node_size_and_time): New hints argument.
3499         (do_estimate_edge_time): Cache hints.
3500         (do_estimate_edge_growth): Update.
3501         (do_estimate_edge_hints): New function
3502
3503 2012-08-18  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
3504
3505         PR middle-end/53823
3506         * expmed.c (expand_mult): Skip synth_mult for negative coefficients
3507         if the mode is larger than a wide int and it is too costly to multiply
3508         by a positive multiplier and negate the result.
3509
3510 2012-08-18  Steven Bosscher  <steven@gcc.gnu.org>
3511
3512         * sparseset.c (sparseset_alloc): Use non-clearing allocation.  Tell
3513         valgrind not to worry about reading from unitialized memory.
3514
3515 2012-08-18  Steven Bosscher  <steven@gcc.gnu.org>
3516
3517         PR middle-end/54313
3518         * dse.c (dse_step7): Don't free kill_on_calls bitmap, it is
3519         freed when its obstack is release.
3520
3521 2012-08-18  Andrew Pinski  <pinskia@gmail.com>
3522
3523         * alloc-pool.c (pool_alloc): Add valgrind markers.
3524         (pool_free): Likewise.
3525
3526 2012-08-17  Walter Lee  <walt@tilera.com>
3527
3528         * config/tilegx/feedback.h (FEEDBACK_ENTER_EXPLICIT): Define.
3529         (FEEDBACK_ENTER): Define.
3530         (FEEDBACK_REENTER): Define.
3531         (FEEDBACK_ENTRY): Define.
3532         * config/tilepro/feedback.h: (FEEDBACK_ENTER_EXPLICIT): Define.
3533         (FEEDBACK_ENTER): Define.
3534         (FEEDBACK_REENTER): Define.
3535         (FEEDBACK_ENTRY): Define.
3536
3537 2012-08-17  H.J. Lu  <hongjiu.lu@intel.com>
3538             Gary Funck <gary@intrepid.com>
3539
3540         PR target/20020
3541         * config/i386/i386.c (ix86_member_type_forces_blk): New function.
3542         (TARGET_MEMBER_TYPE_FORCES_BLK): New macro.
3543
3544         * config/i386/i386.h (MAX_FIXED_MODE_SIZE): New macro.
3545
3546 2012-08-17  Marc Glisse  <marc.glisse@inria.fr>
3547
3548         * simplify-rtx.c (simplify_binary_operation_1): Optimize shuffle of
3549         a concatenation.
3550
3551 2012-08-17  H.J. Lu  <hongjiu.lu@intel.com>
3552
3553         * stor-layout.c (compute_record_mode): Replace
3554         MEMBER_TYPE_FORCES_BLK with targetm.member_type_forces_blk.
3555         (layout_type): Likewise.
3556
3557         * system.h: Poison MEMBER_TYPE_FORCES_BLK.
3558
3559         * target.def (member_type_forces_blk): New target hook.
3560
3561         * targhooks.c (default_member_type_forces_blk): New.
3562         * targhooks.h (default_member_type_forces_blk): Likewise.
3563
3564         * doc/tm.texi.in (MEMBER_TYPE_FORCES_BLK): Removed.
3565         (TARGET_MEMBER_TYPE_FORCES_BLK): New hook.
3566         * doc/tm.texi: Regenerated.
3567
3568         * config/ia64/hpux.h (MEMBER_TYPE_FORCES_BLK): Removed.
3569
3570         * config/ia64/ia64.c (ia64_member_type_forces_blk): New function.
3571         (TARGET_MEMBER_TYPE_FORCES_BLK): New macro.
3572
3573         * config/rs6000/rs6000.c (TARGET_MEMBER_TYPE_FORCES_BLK): New macro.
3574         (rs6000_member_type_forces_blk): New function.
3575
3576         * config/rs6000/rs6000.h (MEMBER_TYPE_FORCES_BLK): Removed.
3577
3578         * config/xtensa/xtensa.c (xtensa_member_type_forces_blk): New function.
3579         (TARGET_MEMBER_TYPE_FORCES_BLK): New macro.
3580
3581         * config/xtensa/xtensa.h (MEMBER_TYPE_FORCES_BLK): Removed.
3582
3583 2012-08-17  Diego Novillo  <dnovillo@google.com>
3584
3585         PR bootstrap/54281
3586         * configure.ac: Add libintl.h to AC_CHECK_HEADERS list.
3587         * config.in: Regenerate.
3588         * configure: Regenerate.
3589         * intl.h: Always include libintl.h if HAVE_LIBINTL_H is set.
3590
3591 2012-08-17  Richard Guenther  <rguenther@suse.de>
3592
3593         * bitmap.h (struct bitmap_element_def): GTY annotate next/prev.
3594         (struct bitmap_head_def): GTY skip current field.
3595
3596 2012-08-17  Steven Bosscher  <steven@gcc.gnu.org>
3597
3598         PR middle-end/54146
3599         * tree-ssa-loop-im.c (lim_bitmap_obstack): New bitmap_obstack.
3600         (memref_free): Don't free the bitmaps individually here.
3601         (mem_ref_alloc): Allocate the bitmaps on the new bitmap obstack.
3602         (analyze_memory_references): Likewise.
3603         (tree_ssa_lim_initialize): Initialize the new bitmap obstack.
3604         (tree_ssa_lim_finalize): Release it.
3605         * dse.c (dse_bitmap_obstack): New bitmap obstack.
3606         (dse_obstack): New obstack.
3607         (get_group_info): Allocate the bitmaps on the new bitmap obstack.
3608         (dse_step0): Allocate the scratch bitmap on reg_obstack.  Initialize
3609         the new bitmap obstack and normal obstack.  Use XNEWVEC for bb_table.
3610         (record_store): Allocate regs_set on reg_obstack.
3611         (dse_step1): Allocate regs_live on reg_obstack.
3612         (dse_step2_init): Allocate offset_map_n and offset_map_p on the new
3613         obstack.
3614         (dse_step3_scan): Allocate bitmaps on the new bitmap obstack.
3615         (dse_step3): Likewise.
3616         (dse_confluence_0): Likewise.
3617         (dse_confluence_n): Likewise.
3618         (dse_transfer_function): Likewise.
3619         (dse_step7): Destroy the new obstacks, and everything allocated on
3620         them, in one big sweep.
3621         (rest_of_handle_dse): Update.
3622         * cfgexpand.c (stack_var_bitmap_obstack): New bitmap obstack.
3623         (add_stack_var_conflict): Allocate bitmaps on it.
3624         (add_scope_conflicts_1): Likewise.
3625         (add_scope_conflicts): Likewise.
3626         (update_alias_info_with_stack_vars): Likewise.
3627         (init_vars_expansion): Move TREE_USED fiddling expand_used_vars.
3628         Initialize the new bitmap obstack.
3629         (fini_vars_expansion): Release it.
3630         (estimated_stack_frame_size): Use init_vars_expansion to set things up
3631         and always clean up at the end.
3632         (expand_used_vars): Do the TREE_USED trickery here.  Always call
3633         fini_vars_expansion.
3634         * tree-ssa-live.h (struct tree_live_info_d): Make livein and liveout
3635         arrays of bitmap_head to avoid one indirection per bitmap access.
3636         (live_on_entry, live_on_exit, live_var_map, live_merge_and_clear,
3637         make_live_on_entry): Update.
3638         * tree-ssa-live.c (partition_view_bitmap): Don't double-free 'used'.
3639         (liveness_bitmap_obstack): New bitmap obstack.
3640         (remove_unused_locals): Use it to allocate all bitmaps on.  Update
3641         for livein/liveout changes in tree-ssa-live.h.
3642         (delete_tree_live_info): Release the bitmap obstack.
3643         (loe_visit_block, live_worklist, set_var_live_on_entry,
3644         calculate_live_on_exit, dump_live_info): Update.
3645         (calculate_live_ranges): Initialize the bitmap.
3646         * tree-ssa-ter.c (ter_bitmap_obstack): New bitmap obstack.
3647         (new_temp_expr_table): Allocate bitmap on it.
3648         (make_dependent_on_partition, add_to_partition_kill_list,
3649         add_dependence, process_replaceable): Likewise.
3650         (find_replaceable_exprs): Initialize and release the new obstack here.
3651         * df-problems.c (df_lr_add_problem): Allocate persistent bitmap
3652         for out_of_date_transfer_functions on df_bitmap_obstack.
3653         (df_live_add_problem): Likewise.
3654         (df_chain_add_problem): Likewise.
3655         (df_word_lr_add_problem): Likewise.
3656
3657 2012-08-17  Nick Clifton  <nickc@redhat.com>
3658
3659         * config/fr30/fr30.md  (cbranchsi4): Remove mode from comparison.
3660         (branch_true): Likewise.
3661         (branch_false): Likewise.
3662
3663         * config/mcore/mcore.md (cbranchsi4): Remove mode from comparison.
3664
3665         * config/iq2000/iq2000.md (cbranchsi4): Remove mode from
3666         comparison and label.
3667         (branch_zero): Likewise.
3668         (branch_zero_inverted): Likewise.
3669         (branch_equality): Likewise.
3670         (branch_equality_inverted): Likewise.
3671         (extend-and-compare): Disable until reload issues can be resolved.
3672         * config/iq2000/iq2000.c (gen_conditional_branch): Use VOIDmode
3673         for comparison.
3674         (iq2000_function_arg_advance): Remove CONST_CAST2.
3675
3676         * config/mep/t-mep (mep-pragma.o): Use $(COMPILER) to compile
3677         mep-pragma.c.
3678
3679 2012-08-17  Georg-Johann Lay  <avr@gjlay.de>
3680
3681         * config/avr/t-avr (gen-avr-mmcu-texi): Use $(CC) to compile
3682         gen-avr-mmcu-texi.c.
3683
3684 2012-08-17  Richard Earnshaw  <rearnsha@arm.com>
3685
3686         * arm.md (arm_addsi3): New variant for Thumb2 16-bit ADD instruction.
3687         * arm.c (thumb2_reorg): Don't convert an ADD instruction that's
3688         already 16 bits.
3689
3690 2012-08-17  Richard Guenther  <rguenther@suse.de>
3691
3692         * hash-table.h (class hash_table): Use a descriptor template
3693         argument instead of decomposed element type and support functions.
3694         (struct pointer_hash): New generic typed pointer-hash.
3695         (struct typed_free_remove, struct typed_noop_remove): Generic
3696         hash_table support pieces.
3697         * coverage.c (struct counts_entry): Add hash_table support members.
3698         * tree-ssa-ccp.c (gimple_htab): Use pointer_hash.
3699         * tree-ssa-coalesce.c (struct ssa_name_var_hash): New generic
3700         SSA name by SSA_NAME_VAR hash.
3701         (coalesce_ssa_name): Use it.
3702         * tree-ssa-pre.c (struct pre_expr_d): Add hash_table support.
3703         (expression_to_id): Adjust.
3704         (struct expr_pred_trans_d): Add hash_table support.
3705         (phi_translate_table): Adjust.
3706         (phi_trans_lookup): Likewise.
3707         (phi_trans_add): Likewise.
3708         (do_regular_insertion): Likewise.
3709         * tree-ssa-tail-merge.c (struct same_succ_def): Add hash_table support.
3710         (same_succ_htab): Adjust.
3711         (find_same_succ_bb): Likewise.
3712         (find_same_succ): Likewise.
3713         (update_worklist): Likewise.
3714         * tree-ssa-threadupdate.c (struct redirection_data): Add hash_table
3715         support.
3716         (redirection_data): Adjust.
3717
3718 2012-08-17  Richard Guenther  <rguenther@suse.de>
3719
3720         * params.def (integer-share-limit): Decrease from 256 to 251,
3721         add rationale.
3722
3723 2012-08-17  Richard Guenther  <rguenther@suse.de>
3724
3725         * tree-sra.c (modify_function): Free redirect_callers vector.
3726         * ipa-split.c (split_function): Free args_to_pass vector.
3727         * tree-vect-data-refs.c (vect_peeling_hash_get_lowest_cost): Free
3728         body_cost_vec properly.
3729         (vect_enhance_data_refs_alignment): Likewise.
3730         * tree-vect-stmts.c (vectorizable_operation): Do not pre-allocate
3731         vec_oprnds.
3732         (new_stmt_vec_info): Do not pre-allocate STMT_VINFO_SAME_ALIGN_REFS.
3733         * tree-vect-slp.c (vect_free_slp_instance): Free the instance.
3734         (vect_analyze_slp_instance): Free everything.
3735         (destroy_bb_vec_info): Free the SLP instances.
3736
3737 2012-08-17  Iain Sandoe  <iain@codesourcery.com>
3738
3739         * config/rs6000/rs6000.c (macho_branch_islands): Adjust for changes
3740         to vec.h.
3741
3742 2012-08-17  Jakub Jelinek  <jakub@redhat.com>
3743
3744         * doc/invoke.texi (-Wsizeof-pointer-memaccess): Document.
3745
3746 2012-08-16  Sandra Loosemore  <sandra@codesourcery.com>
3747
3748         * config/mips/mips-dsp.md (mips_dpau_h_qbl, mips_dpau_h_qbr)
3749         (mips_dpsu_h_qbl, mips_dpsu_h_qbr, mips_dpaq_s_w_ph)
3750         (mips_dpsq_s_w_ph, mips_mulsaq_s_w_ph, mips_dpaq_sa_l_w)
3751         (mips_dpsq_sa_l_w, mips_maq_s_w_phl, mips_maq_s_w_phr)
3752         (mips_maq_sa_w_phl, mips_maq_sa_w_phr): Add accum_in attribute.
3753
3754 2012-08-16  Oleg Endo  <olegendo@gcc.gnu.org>
3755
3756         PR target/54236
3757         * config/sh/sh.md (addc): Add commutative modifier.
3758         (*addc, *minus_plus_one, *subc, *negc): New insns and splits.
3759
3760 2012-08-16  Oleg Endo  <olegendo@gcc.gnu.org>
3761
3762         PR target/39423
3763         * config/sh/sh.md (*movsi_index_disp, *movhi_index_disp): Handle
3764         potential T_REG clobber.  Convert zero extending split to
3765         insn_and_split.
3766
3767 2012-08-16  Oleg Endo  <olegendo@gcc.gnu.org>
3768
3769         PR target/54089
3770         * config/sh/sh.md (ashlsi3_d): Do not split if it would result
3771         in a T_REG clobber.  Correct comment.
3772         (ashlsi3_n): Correct comment.
3773
3774 2012-08-16  Hans-Peter Nilsson  <hp@axis.com>
3775
3776         PR middle-end/54261
3777         * optabs.c (expand_atomic_fetch_op): Save and restore code when
3778         retrying after failed attempt.
3779
3780 2012-08-16  Yuri Rumyantsev  <ysrumyan@gmail.com>
3781
3782         * config/i386/i386-protos.h (ix86_split_lea_for_addr) : Add
3783         additional argument.
3784         * config/i386/i386.md (ix86_split_lea_for_addr) : Add
3785         additional argument curr_insn.
3786         * config/i386/i386.c (ix86_split_lea_for_addr): Load base or index
3787         register first, depending on their defintion distances.
3788         (ix86_lea_outperforms): Prefer LEA only if split cost exceeds
3789         AGU stall.
3790         (find_nearest_reg-def): New function. Find register with
3791         nearest definition.
3792
3793 2012-08-16  Walter Lee  <walt@tilera.com>
3794
3795         * config.gcc (tilegx-*-linux*): Add feedback.h.
3796         (tilepro-*-linux*): Likewise.
3797         * config/tilegx/feedback.h: New file.
3798         * config/tilepro/feedback.h: New file.
3799
3800 2012-08-16  Diego Novillo  <dnovillo@google.com>
3801
3802         Revert
3803
3804         PR bootstrap/54281
3805         * double-int.h: Move including of gmp.h ...
3806         * system.h: ... here.
3807         * realmpfr.h: Do not include gmp.h.
3808         * tree-ssa-loop-niter.c: Do not include gmp.h.
3809
3810 2012-08-16  Segher Boessenkool  <segher@kernel.crashing.org>
3811
3812         * config/rs6000/darwin.h (TARGET_IEEE_QUAD): Fix comment.
3813
3814 2012-08-16  Richard Guenther  <rguenther@suse.de>
3815
3816         PR middle-end/54146
3817         * tree-ssa-loop-niter.c (find_loop_niter_by_eval): Free the
3818         exit vector.
3819         * ipa-pure-const.c (analyze_function): Use FOR_EACH_LOOP_BREAK.
3820         * cfgloop.h (FOR_EACH_LOOP_BREAK): Fix.
3821         * tree-ssa-structalias.c (handle_lhs_call): Properly free rhsc.
3822         * tree-into-ssa.c (get_ssa_name_ann): Allocate info only when needed.
3823         * tree-ssa-loop-im.c (analyze_memory_references): Adjust.
3824         (tree_ssa_lim_finalize): Free all mem_refs.
3825         * tree-ssa-sccvn.c (extract_and_process_scc_for_name): Free
3826         scc when bailing out.
3827         * modulo-sched.c (sms_schedule): Use FOR_EACH_LOOP_BREAK.
3828         * ira-build.c (loop_with_complex_edge_p): Free loop exit vector.
3829         * graphite-sese-to-poly.c (scop_ivs_can_be_represented): Use
3830         FOR_EACH_LOOP_BREAK.
3831
3832 2012-08-16  Diego Novillo  <dnovillo@google.com>
3833
3834         PR bootstrap/54281
3835         * double-int.h: Move including of gmp.h ...
3836         * system.h: ... here.
3837         * realmpfr.h: Do not include gmp.h.
3838         * tree-ssa-loop-niter.c: Do not include gmp.h.
3839
3840 2012-08-16  Steven Bosscher  <steven@gcc.gnu.org>
3841
3842         PR middle-end/54146
3843         * tree-flow.h (compute_global_livein): Remove prototype.
3844         * tree-into-ssa.c (compute_global_livein): Remove function.
3845         * tree-ssa-loop-manip.c: Include gimple-pretty-print.h.
3846         (find_sibling_superloop): New function.
3847         (compute_live_loop_exits): New function.
3848         (add_exit_phis_edge): Rename to add_exit_phi.  Do not allow
3849         inserting a PHI in a block that is not a loop exit for VAR.
3850         Add dumping if TDF_DETAILS.
3851         (add_exit_phis_var): Rewrite.
3852         (add_exit_phis): Update.
3853         (get_loops_exits): Rewrite to return an array of per-loop exits
3854         rather than one bitmap with all loop exits.
3855         (find_uses_to_rename_bb): Ignore virtual PHI nodes.
3856         (rewrite_into_loop_closed_ssa): Update.
3857
3858 2012-08-16  Nick Clifton  <nickc@redhat.com>
3859
3860         * config/i386/i386elf.h (ASM_OUTPUT_ASCII): Cast _ascii_bytes
3861         before passing it to ASM_OUTPUT_LIMITED_STRING.
3862
3863         * config/bfin/bfin.c (hwloop_optimize): Fix use of VEC_last macro.
3864
3865         * config/avr/t-avr: Replace occurrences of $(CC) with $(COMPILER).
3866         * config/avr/avr.c (avr_legitimize_reload_address): Add casts
3867         for reload_type enums.
3868         (DEF_BUILTIN): Cast the icode to enum insn_code.
3869
3870 2012-08-15  Segher Boessenkool  <segher@kernel.crashing.org>
3871
3872         * config/rs6000/aix43.h (ASM_CPU_SPEC): Use %(asm_default)
3873         instead of -mppc.
3874         * config/rs6000/aix51.h (ASM_CPU_SPEC): Ditto.
3875
3876 2012-08-15  Segher Boessenkool  <segher@kernel.crashing.org>
3877
3878         * config/rs6000/aix43.h (TARGET_DEFAULT): Delete MASK_NEW_MNEMONICS.
3879         (RS6000_CALL_GLUE): Adjust for single assembler syntax.
3880         * config/rs6000/aix51.h (TARGET_DEFAULT, RS6000_CALL_GLUE): Ditto.
3881         * config/rs6000/aix52.h (TARGET_DEFAULT, RS6000_CALL_GLUE): Ditto.
3882         * config/rs6000/aix53.h (TARGET_DEFAULT, RS6000_CALL_GLUE): Ditto.
3883         * config/rs6000/aix61.h (TARGET_DEFAULT, RS6000_CALL_GLUE): Ditto.
3884         * config/rs6000/darwin.h (TARGET_DEFAULT): Ditto.
3885         * config/rs6000/darwin.md (whole file): Adjust to single
3886         assembler syntax.
3887         * config/rs6000/darwin64.h (TARGET_DEFAULT): Delete MASK_NEW_MNEMONICS.
3888         * config/rs6000/default64.h (TARGET_DEFAULT): Ditto.
3889         * config/rs6000/dfp.md: (whole file): Adjust to single
3890         assembler syntax.
3891         * config/rs6000/eabi.h (TARGET_DEFAULT): Delete MASK_NEW_MNEMONICS.
3892         * config/rs6000/eabialtivec.h (TARGET_DEFAULT): Ditto.
3893         * config/rs6000/eabispe.h (TARGET_DEFAULT): Ditto.
3894         * config/rs6000/linuxaltivec.h (TARGET_DEFAULT): Ditto.
3895         * config/rs6000/linuxspe.h (TARGET_DEFAULT): Ditto.
3896         * config/rs6000/rs6000-cpus.def (whole file): Delete POWERPC_BASE_MASK.
3897         * config/rs6000/rs6000-tables.opt: Regenerate.
3898         * config/rs6000/rs6000.c (POWERPC_BASE_MASK): Delete.
3899         (num_insns_constant_wide): Adjust comments.
3900         (whole file): Adjust to single assembler syntax.
3901         (output_cbranch): Adjust comment.
3902         * config/rs6000/rs6000.h (ASSEMBLER_DIALECT): Delete.
3903         * config/rs6000/rs6000.md: (whole file): Adjust to single
3904         assembler syntax.
3905         * config/rs6000/rs6000.opt (mnew-mnemonics): Delete.
3906         (mold-mnemonics): Delete.
3907         * config/rs6000/spe.md: (whole file): Adjust to single
3908         assembler syntax.
3909         * config/rs6000/sync.md: (whole file): Adjust to single
3910         assembler syntax.
3911         * config/rs6000/sysv4.h (TARGET_DEFAULT): Delete MASK_NEW_MNEMONICS.
3912         (ASM_OUTPUT_REG_PUSH): Adjust.
3913         (ASM_OUTPUT_REG_POP): Adjust.
3914         * config/rs6000/sysv4le.h (TARGET_DEFAULT): Delete MASK_NEW_MNEMONICS.
3915         * config/rs6000/vsx.md: (whole file): Adjust to single
3916         assembler syntax.
3917         * config/rs6000/vxworks.h (TARGET_DEFAULT): Delete MASK_NEW_MNEMONICS.
3918         * doc/invoke.texi: Adjust documentation to reflect the
3919         removal of -mnew-mnemonics and -mold-mnemonics.
3920
3921 2012-08-15  Segher Boessenkool  <segher@kernel.crashing.org>
3922
3923         * common/config/rs6000/rs6000-common.c (rs6000_handle_option):
3924         Delete handling for -mno-powerpc and -mpowerpc.
3925         * config/rs6000/aix43.h (ASM_CPU_SPEC): Similar.
3926         (ASM_DEFAULT_SPEC): Use -mppc instead of -mcom.
3927         * config/rs6000/aix51.h (ASM_CPU_SPEC, ASM_DEFAULT_SPEC): Ditto.
3928         * config/rs6000/aix52.h (TARGET_DEFAULT): Delete MASK_POWERPC.
3929         * config/rs6000/aix53.h (TARGET_DEFAULT): Ditto.
3930         * config/rs6000/aix61.h (TARGET_DEFAULT): Ditto.
3931         * config/rs6000/darwin.h (TARGET_DEFAULT): Ditto.
3932         * config/rs6000/darwin64.h (TARGET_DEFAULT): Ditto.
3933         * config/rs6000/default64.h (TARGET_DEFAULT): Ditto.
3934         * config/rs6000/driver-rs6000.c (asm_names): Delete handling
3935         for -mcpu=common and -mpowerpc.
3936         * config/rs6000/eabi.h (TARGET_DEFAULT): Delete MASK_POWERPC.
3937         * config/rs6000/eabialtivec.h (TARGET_DEFAULT): Ditto.
3938         * config/rs6000/eabispe.h (TARGET_DEFAULT): Ditto.
3939         * config/rs6000/linuxaltivec.h (TARGET_DEFAULT): Ditto.
3940         * config/rs6000/linuxspe.h (TARGET_DEFAULT): Ditto.
3941         * config/rs6000/rs6000-builtin.def (RS6000_BUILTIN_CFSTRING):
3942         Use RS6000_BTM_ALWAYS instead of RS6000_BTM_POWERPC.
3943         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Adjust.
3944         (rs6000_cpu_cpp_builtins): Adjust.
3945         * config/rs6000/rs6000.c (POWERPC_BASE_MASK): Delete MASK_POWERPC.
3946         (rs6000_builtin_mask_calculate): Adjust.
3947         (rs6000_emit_move): Delete code for ! TARGET_POWERPC.
3948         (rs6000_init_libfuncs): Ditto.
3949         (rs6000_output_function_prologue): Ditto.
3950         (rs6000_opt_masks): Delete MASK_POWERPC.
3951         (rs6000_builtin_mask_names): Delete RS6000_BTM_POWERPC.
3952         * config/rs6000/rs6000.h (ASM_CPU_SPEC): Delete handling for -mpowerpc.
3953         (RS6000_BTM_POWERPC): Delete.
3954         (RS6000_BTM_COMMON): Delete RS6000_BTM_POWERPC.
3955         * config/rs6000/rs6000.md (extendqisi2 patterns): Adjust for
3956         TARGET_POWERPC always on.
3957         (extendqihi2 patterns): Similar.
3958         (various unnamed subtract patterns): Similar.
3959         (bswaphi2 patterns): Similar.
3960         (divmodsi4): Similar.
3961         (udiv<GPR:mode>3): Similar.
3962         (div<GPR:mode>3 patterns): Similar.
3963         (udivmodsi4): Similar.
3964         (mulhcall): Delete.
3965         (mullcall): Delete.
3966         (divss_call): Delete.
3967         (divus_call): Delete.
3968         (quoss_call): Delete.
3969         (quous_call): Delete.
3970         (insvsi patterns): Adjust.
3971         (addsf3 patterns): Adjust.
3972         (subsf3 patterns): Adjust.
3973         (mulsf3 patterns): Adjust.
3974         (divsf3 patterns): Adjust.
3975         (*fmasf4_fpr): Adjust.
3976         (*fmssf4_fpr): Adjust.
3977         (*nfmasf4_fpr): Adjust.
3978         (*nfmssf4_fpr): Adjust.
3979         (*floatunssidf2_internal): Adjust.
3980         (fix_trunc<SFDF:mode>si2_internal): Adjust.
3981         (fctiwz_<SFDF:mode>): Adjust.
3982         (mulsidi3 patterns): Adjust.
3983         (smulsi3_highpart patterns): Adjust.
3984         (umulsi3_highpart patterns): Adjust.
3985         (fix_trunctfsi2 patterns): Adjust.
3986         (prefetch): Adjust.
3987         * config/rs6000/rs6000.opt (mpowerpc): Replace by stub option.
3988         (mno-powerpc): Delete.
3989         * config/rs6000/sync.md (load_locked<ATOMIC:mode>): Adjust.
3990         (store_conditional<ATOMIC:mode>): Adjust.
3991         (atomic_compare_and_swap<ATOMIC:mode>): Adjust.
3992         (atomic_exchange<ATOMIC:mode>): Adjust.
3993         (atomic_<fetchop_name><ATOMIC:mode>): Adjust.
3994         (atomic_nand<ATOMIC:mode>): Adjust.
3995         (atomic_fetch_<fetchop_name><ATOMIC:mode>): Adjust.
3996         (atomic_fetch_nand<ATOMIC:mode>): Adjust.
3997         (atomic_<fetchop_name>_fetch<ATOMIC:mode>): Adjust.
3998         (atomic_nand_fetch<ATOMIC:mode>): Adjust.
3999         * config/rs6000/sysv4.h (TARGET_DEFAULT): Delete MASK_POWERPC.
4000         * config/rs6000/sysv4le.h (TARGET_DEFAULT): Ditto.
4001         * config/rs6000/vxworks.h (TARGET_DEFAULT): Ditto.
4002         * doc/invoke.texi: Adjust documentation.
4003
4004 2012-08-15  Segher Boessenkool  <segher@kernel.crashing.org>
4005
4006         * config/rs6000/rs6000.h (RS6000_BTM_ALWAYS): New.
4007
4008 2012-08-15  Segher Boessenkool  <segher@kernel.crashing.org>
4009
4010         * config/rs6000/aix52.h (ASM_CPU_SPEC): Fix typo.
4011         * config/rs6000/aix53.h (ASM_CPU_SPEC): Ditto.
4012         * config/rs6000/aix61.h (ASM_CPU_SPEC): Ditto.
4013         * config/rs6000/driver-rs6000.c (asm_names): Ditto.
4014
4015 2012-08-15  Segher Boessenkool  <segher@kernel.crashing.org>
4016
4017         PR target/54142
4018         * config/rs6000/driver-rs6000.c (asm_names): Use %(asm_default)
4019         instead of -mcom.
4020         * config/rs6000/rs6000.h (ASM_CPU_SPEC): Ditto.
4021
4022 2012-08-15  Sandra Loosemore  <sandra@codesourcery.com>
4023             Maxim Kuvyrkov  <maxim@codesourcery.com>
4024             Julian Brown  <julian@codesourcery.com>
4025             MIPS Technologies, Inc.
4026
4027         * config/mips/mips.md (dspmac, dspmacsat, accext, accmod, dspalu)
4028         (dspalusat): Add insn types.
4029         * config/mips/mips-dsp.md (add<DSPV:mode>3)
4030         (mips_add<DSP:dspfmt1>_s_<DSP:dspfmt2>)
4031         (sub<DSPV:mode>3, mips_sub<DSP:dspfmt1>_s_<DSP:dspfmt2>, mips_addsc)
4032         (mips_addwc, mips_modsub, mips_raddu_w_qb, mips_absq_s_<DSPQ:dspfmt2>)
4033         (mips_precrq_qb_ph, mips_precrq_ph_w, mips_precrq_rs_ph_w)
4034         (mips_precrqu_s_qb_ph, mips_preceq_w_phl, mips_preceq_w_phr)
4035         (mips_precequ_ph_qbl, mips_precequ_ph_qbr, mips_precequ_ph_qbla)
4036         (mips_precequ_ph_qbra, mips_preceu_ph_qbl, mips_preceu_ph_qbr)
4037         (mips_preceu_ph_qbla, mips_preceu_ph_qbra, mips_shll_<DSPV:dspfmt2>)
4038         (mips_shll_s_<DSPQ:dspfmt2>, mips_shll_s_<DSPQ:dspfmt2>, mips_shrl_qb)
4039         (mips_shra_ph, mips_shra_r_<DSPQ:dspfmt2>, mips_bitrev, mips_insv)
4040         (mips_repl_qb, mips_repl_ph)
4041         (mips_cmp<DSPV:dspfmt1_1>_eq_<DSPV:dspfmt2>)
4042         (mips_cmp<DSPV:dspfmt1_1>_lt_<DSPV:dspfmt2>)
4043         (mips_cmp<DSPV:dspfmt1_1>_le_<DSPV:dspfmt2>, mips_cmpgu_eq_qb)
4044         (mips_cmpgu_lt_qb, mips_cmpgu_le_qb, mips_pick_<DSPV:dspfmt2>)
4045         (mips_packrl_ph, mips_wrdsp, mips_rddsp): Change type to dspalu.
4046         (mips_dpau_h_qbl, mips_dpau_h_qbr, mips_dpsu_h_qbl, mips_dpsu_h_qbr)
4047         (mips_dpaq_s_w_ph, mips_dpsq_s_w_ph, mips_mulsaq_s_w_ph)
4048         (mips_maq_s_w_phl, mips_maq_s_w_phr, mips_maq_sa_w_phr): Set type to
4049         dspmac.
4050         (mips_dpaq_sa_l_w, mips_dpsq_sa_l_w, mips_maq_sa_w_phl): Set type to
4051         dspmacsat.
4052         (mips_extr_w, mips_extr_r_w, mips_extr_rs_w, mips_extp, mips_extpdp):
4053         Set type to accext.
4054         (mips_shilo, mips_mthlip): Set type to accmod.
4055         * config/mips/mips-dspr2.md (mips_absq_s_qb, mips_addu_s_ph)
4056         (mips_adduh_r_qb): Set type to dspalusat.
4057         (mips_addu_ph, mips_adduh_qb, mips_append, mips_balign)
4058         (mips_cmpgdu_eq_qb, mips_cmpgdu_lt_qb, mips_cmpgdu_le_qb)
4059         (mips_precr_qb_ph, mips_precr_sra_ph_w, mips_precr_sra_r_ph_w)
4060         (mips_prepend, mips_shra_qb, mips_shra_r_qb, mips_shrl_ph)
4061         (mips_subu_ph, mips_subuh_qb, mips_subuh_r_qb, mips_addqh_ph)
4062         (mips_addqh_r_ph, mips_addqh_w, mips_addqh_r_w, mips_subqh_ph)
4063         (mips_subqh_r_ph, mips_subqh_w, mips_subqh_r_w): Set type to dspalu.
4064         (mips_dpa_w_ph, mips_dps_w_ph, mips_mulsa_w_ph, mips_dpax_w_ph)
4065         (mips_dpsx_w_ph, mips_dpaqx_s_w_ph, mips_dpsqx_s_w_ph): Set type to
4066         dspmac.  Set accum_in attribute.
4067         (mips_subu_s_ph): Set type to dspalusat.
4068         (mips_dpaqx_sa_w_ph, mips_dpsqx_sa_w_ph): Set type to dspmacsat.
4069         Set accum_in attribute.
4070         * config/mips/mips-protos.h (mips_dspalu_bypass_p): Add prototype.
4071         * config/mips/mips.c (dspalu_bypass_table): New.
4072         (mips_dspalu_bypass_p): New.
4073         * config/mips/24k.md (r24k_dsp_alu, r24k_dsp_mac, r24k_dsp_mac_sat)
4074         (r24k_dsp_acc_ext, r24k_dsp_acc_mod): New insn reservations.
4075         (r24k_int_mult, r24k_int_mthilo, r24k_dsp_mac, r24k_dsp_mac_sat)
4076         (r24k_dsp_acc_ext, r24k_dsp_acc_mod, r24k_dsp_alu): New bypasses.
4077         * config/mips/74k.md (r74k_dsp_alu, r74k_dsp_alu_sat, r74k_dsp_mac)
4078         (r74k_dsp_mac_sat, r74k_dsp_acc_ext, r74k_dsp_acc_mod): New insn
4079         reservations.
4080         (r74k_dsp_mac, r74k_dsp_mac_sat, r74k_int_mult, r74k_int_mul3)
4081         (r74k_dsp_mac, r74k_dsp_mac_sat): New bypasses.
4082
4083 2012-08-15  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
4084
4085         * config/spu/spu.c: Include "cfgloop.h".
4086         (spu_machine_dependent_reorg): Call loop_optimizer_init and
4087         loop_optimizer_finalize.  Use bb_loop_depth instead of loop_depth.
4088         Directly compare loop_father values where appropriate.
4089         * config/spu/t-spu-elf (spu.o): Update dependencies.
4090
4091 2012-08-15  H.J. Lu  <hongjiu.lu@intel.com>
4092
4093         * Makefile.in (tree-cfg.o): Also depend on $(TARGET_H).
4094
4095 2012-08-15  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
4096
4097         PR tree-optimization/54245
4098         * gimple-ssa-strength-reduction.c (legal_cast_p_1): New function.
4099         (legal_cast_p): Split out logic to legal_cast_p_1.
4100         (analyze_increments): Avoid introducing multiplies in smaller types.
4101
4102 2012-08-15  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
4103
4104         PR tree-optimization/54240
4105         * tree-ssa-phiopt.c (hoist_adjacent_loads): Correct test for
4106         existence of conditional move with given mode.
4107
4108 2012-08-15  Richard Guenther  <rguenther@suse.de>
4109
4110         * double-int.h (double_int::from_unsigned): Rename to ...
4111         (double_int::from_uhwi): ... this.
4112         (double_int::from_signed): Rename to ...
4113         (double_int::from_shwi): ... this.
4114         (double_int::to_signed): Rename to ...
4115         (double_int::to_shwi): ... this.
4116         (double_int::to_unsigned): Rename to ...
4117         (double_int::to_uhwi): ... this.
4118         (double_int::fits_unsigned): Rename to ...
4119         (double_int::fits_uhwi): ... this.
4120         (double_int::fits_signed): Rename to ...
4121         (double_int::fits_shwi): ... this.
4122         (double_int::fits): Rename to ...
4123         (double_int::fits_hwi): ... this.
4124         * double-int.c: Likewise.
4125
4126 2012-08-15  Steven Bosscher  <steven@gcc.gnu.org>
4127
4128         * timevar.def (TV_VARPOOL, TV_WHOPR_WPA_LTRANS_EXEC, TV_LIFE,
4129         TV_LIFE_UPDATE, TV_DF_UREC, TV_INLINE_HEURISTICS,
4130         TV_TREE_LINEAR_TRANSFORM, TV_TREE_LOOP_INIT, TV_TREE_LOOP_FINI,
4131         TV_VPT, TV_LOCAL_ALLOC, TV_GLOBAL_ALLOC, TV_SEQABSTR): Remove.
4132         (TV_IPA_INLINING, TV_FLATTEN_INLINING, TV_EARLY_INLINING,
4133         TV_INLINE_PARAMETERS, TV_LOOP_INIT, TV_LOOP_FINI): New.
4134         * timevar.c (timevar_print): Make printing width of timevar names
4135         more flexible, but enforce maximum length.
4136         * ipa-inline.c (pass_early_inline): Use TV_EARLY_INLINING.
4137         (pass_ipa_inline): Use TV_IPA_INLINING.
4138         * ipa-inline-analysis.c (pass_inline_parameters): Use
4139         TV_INLINE_HEURISTICS.
4140         * tree-ssa-loop.c (pass_tree_loop_init): No timevar for wrapper pass.
4141         (pass_tree_loop_done): Likewise.
4142         * final.c (pass_shorten_branches): Use TV_SHORTEN_BRANCH.
4143         * loop-init.c (loop_optimizer_init): Push/pop TV_LOOP_INIT.
4144         (loop_optimizer_finalize): Push/pop TV_LOOP_FINI.
4145
4146 2012-08-15  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
4147
4148         * config/arm/neon.md (neon_vaba<mode> VDQIW): Canonicalize operands.
4149         (neon_vabal<mode> VDQIW): Likewise.
4150
4151 2012-08-15  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
4152
4153         PR target/54212
4154         * config/arm/neon.md (vec_set<mode>_internal VD,VQ): Do not
4155         mark as predicable. Adjust asm template.
4156         (vec_setv2di_internal): Likewise.
4157         (vec_extract<mode> VD, VQ): Likewise.
4158         (vec_extractv2di): Likewise.
4159         (neon_vget_lane<mode>_sext_internal VD, VQ): Likewise.
4160         (neon_vset_lane<mode>_sext_internal VD, VQ): Likewise.
4161         (neon_vdup_n<mode> VX, V32): Likewise.
4162         (neon_vdup_nv2di): Likewise.
4163
4164 2012-08-14  Maxim Kuvyrkov  <maxim@codesourcery.com>
4165
4166         * config/mips/mips.md (define_attr accum_in): New instruction
4167         attribute.  Set it for imadd and fmadd patterns.
4168         * config/mips/mips.c (mips_linked_madd_p): Use accum_in to extract
4169         accumulator register.
4170
4171 2012-08-14  Diego Novillo  <dnovillo@google.com>
4172
4173         Merge from cxx-conversion branch.  Configury.
4174
4175         * configure.ac (CXX_FOR_BUILD): Define and substitute.
4176         (BUILD_CXXFLAGS): Define.
4177         Remove all handlers of ENABLE_BUILD_WITH_CXX.
4178         Force all build to be with C++.
4179         * Makefile.in (BUILD_CXXFLAGS): Use it.
4180         Remove all handlers of ENABLE_BUILD_WITH_CXX.
4181         * configure: Regenerate.
4182         * config.in: Regenerate.
4183         * doc/install.texi: Remove documentation for --enable-build-with-cxx
4184         and --enable-build-poststage1-with-cxx.
4185
4186 2012-08-14  Diego Novillo  <dnovillo@google.com>
4187
4188         Merge from cxx-conversion branch.  Re-implement VEC in C++.
4189
4190         * vec.c (vec_heap_free): Convert into a template function.
4191         (vec_gc_o_reserve_1): Make extern.
4192         (vec_gc_p_reserve): Remove.
4193         (vec_gc_p_reserve_exact): Remove.
4194         (vec_gc_o_reserve): Remove.
4195         (vec_gc_o_reserve_exact): Remove.
4196         (vec_heap_o_reserve_1): Make extern.
4197         (vec_heap_p_reserve): Remove.
4198         (vec_heap_p_reserve_exact): Remove.
4199         (vec_heap_o_reserve): Remove.
4200         (vec_heap_o_reserve_exact): Remove.
4201         (vec_stack_p_reserve): Remove.
4202         (vec_stack_p_reserve_exact): Remove.
4203         * vec.h (VEC_CHECK_INFO, VEC_CHECK_DECL, VEC_CHECK_PASS, VEC_ASSERT,
4204         VEC_ASSERT_FAIL, vec_assert_fail): Move earlier in the file.
4205         (VEC): Define to vec_t<T>.
4206         (vec_allocation_t): Define.
4207         (struct vec_prefix): Move earlier in the file.
4208         (vec_t<T>): New template.
4209         (DEF_VEC_I, DEF_VECL_ALLOC_I, DEF_VEC_P, DEF_VEC_ALLOC_P,
4210         DEF_VEC_O, DEF_VEC_ALLOC_P, DEF_VEC_O, DEF_VEC_ALLOC_O,
4211         DEF_VEC_ALLOC_P_STACK, DEF_VEC_ALLOC_O_STACK,
4212         DEF_VEC_ALLOC_I_STACK): Expand to 'struct vec_swallow_trailing_semi'.
4213         (DEF_VEC_A): Provide template instantiations for
4214         GC/PCH markers that do not traverse the vector.
4215         (vec_stack_p_reserve): Remove.
4216         (vec_stack_p_reserve_exact): Remove.
4217         (vec_stack_p_reserve_exact_1): Remove.
4218         (vec_stack_o_reserve): Remove.
4219         (vec_stack_o_reserve_exact): Remove.
4220         (vec_stack_free): Re-write as a template function.
4221         (vec_reserve): New template function.
4222         (vec_reserve_exact): New template function.
4223         (vec_heap_free): New template function if GATHER_STATISTICS is
4224         defined.  Otherwise, macro that expands to free().
4225         (VEC_length_1): New template function.
4226         (VEC_length): Call it.
4227         (VEC_empty_1): New template function.
4228         (VEC_empty): Call it.
4229         (VEC_address_1): New template function.
4230         (VEC_address): Call it.
4231         (VEC_last_1): New template function.
4232         (VEC_last): Call it.  Change return type to T&.
4233         Change all users that used VEC_Os.
4234         (VEC_index_1): New template function.
4235         (VEC_index): Call it.  Return a T& instead of a T*.
4236         Update all callers that were using VEC_O before.
4237         (VEC_iterate_1): New template function.
4238         (VEC_iterate): Call it.
4239         (VEC_embedded_size_1): New template function.
4240         (VEC_embedded_size): Call it.
4241         (VEC_embedded_init_1): New template function.
4242         (VEC_embedded_init): Call it.
4243         (VEC_alloc_1): New template function.
4244         (VEC_alloc): Call it.  If A is 'stack', call XALLOCAVAR to
4245         do the allocation.
4246         (VEC_free_1): New template function.
4247         (VEC_free): Call it.
4248         (VEC_copy_1): New template function.
4249         (VEC_copy): Call it.
4250         (VEC_space_1): New template function
4251         (VEC_space): Call it.
4252         (VEC_reserve_1): New template function.
4253         (VEC_reserve): Call it.
4254         (VEC_reserve_exact_1): New template function.
4255         (VEC_reserve_exact): Call it.
4256         (VEC_splice_1): New template function.
4257         (VEC_splice): Call it.
4258         (VEC_safe_splice_1): New template function.
4259         (VEC_safe_splice): Call it.
4260         (VEC_quick_push_1): New template function.  Create two overloads, one
4261         accepting T, the other accepting T *.  Update all callers
4262         where T and T * are ambiguous.
4263         (VEC_quick_push): Call it.
4264         (VEC_safe_push_1): New template function. Create two overloads, one
4265         accepting T, the other accepting T *.  Update all callers
4266         where T and T * are ambiguous.
4267         (VEC_safe_push): Call it.
4268         (VEC_pop_1): New template function.
4269         (VEC_pop): Call it.
4270         (VEC_truncate_1): New template function.
4271         (VEC_truncate): Call it.
4272         (VEC_safe_grow_1): New template function.
4273         (VEC_safe_grow): Call it.
4274         (VEC_safe_grow_cleared_1): New template function.
4275         (VEC_safe_grow_cleared): Call it.
4276         (VEC_replace_1): New template function.
4277         (VEC_replace): Call it.  Always accept T instead of T*.
4278         Update all callers that used VEC_Os.
4279         (VEC_quick_insert_1): New template function.
4280         (VEC_quick_insert): Call it.
4281         (VEC_safe_insert_1): New template function.
4282         (VEC_safe_insert): Call it.
4283         (VEC_ordered_remove_1): New template function.
4284         (VEC_ordered_remove): Call it.
4285         (VEC_unordered_remove_1): New template function.
4286         (VEC_unordered_remove): Call it.
4287         (VEC_block_remove_1): New template function.
4288         (VEC_block_remove): Call it.
4289         (VEC_lower_bound_1): New template function.
4290         (VEC_lower_bound): Call it.
4291         (VEC_OP): Remove.
4292         (DEF_VEC_FUNC_P): Remove.
4293         (DEF_VEC_ALLOC_FUNC_P): Remove.
4294         (DEF_VEC_NONALLOC_FUNCS_P): Remove.
4295         (DEF_VEC_FUNC_O): Remove.
4296         (DEF_VEC_ALLOC_FUNC_O): Remove.
4297         (DEF_VEC_NONALLOC_FUNCS_O): Remove.
4298         (DEF_VEC_ALLOC_FUNC_I): Remove.
4299         (DEF_VEC_NONALLOC_FUNCS_I): Remove.
4300         (DEF_VEC_ALLOC_FUNC_P_STACK): Remove.
4301         (DEF_VEC_ALLOC_FUNC_O_STACK): Remove.
4302         (DEF_VEC_ALLOC_FUNC_I_STACK): Remove.
4303         (vec_reserve_exact): New template function.
4304
4305         * gengtype-lex.l (DEF_VEC_ALLOC_[IOP]/{EOID}): Remove.
4306         * gengtype-parse.c (token_names): Remove DEF_VEC_ALLOC_[IOP].
4307         (typedef_name): Emit vec_t<C1> instead of VEC_C1_C2.
4308         (def_vec_alloc): Remove.  Update all callers.
4309         * gengtype.c (filter_type_name): New.
4310         (output_mangled_typename): Call it.
4311         (write_func_for_structure): Likewise.
4312         (write_types): Likewise.
4313         (write_root): Likewise.
4314         (write_typed_alloc_def): Likewise.
4315         (note_def_vec): Emit vec_t<TYPE_NAME> instead of VEC_TYPE_NAME_base.
4316         (note_def_vec_alloc): Remove.
4317         * gengtype.h (note_def_vec_alloc): Remove.
4318         (DEFVEC_ALLOC): Remove token code.
4319
4320         * df-scan.c (df_bb_verify): Remove call to df_free_collection_rec
4321         inside the insn traversal loop.
4322         * gimplify.c (gimplify_compound_lval): Rename STACK to EXPR_STACK.
4323         * ipa-inline.c (inline_small_functions): Rename HEAP to EDGE_HEAP.
4324         * reg-stack.c (stack): Rename to STACK_PTR.  Update all users.
4325         * tree-vrp.c (stack): Rename to EQUIV_STACK.  Update all users.
4326
4327         * config/bfin/bfin.c (hwloop_optimize): Update some calls to
4328         VEC_* for vectors of non-pointers.
4329         * config/c6x/c6x.c (try_rename_operands): Likewise.
4330         (reshuffle_units): Likewise.
4331         * config/mips/mips.c (mips_multi_start): Likewise.
4332         (mips_multi_add): Likewise.
4333         (mips_multi_copy_insn): Likewise.
4334         (mips_multi_set_operand): Likewise.
4335         * hw-doloop.c (discover_loop): Likewise.
4336         (discover_loops): Likewise.
4337         (reorg_loops): Likewise.
4338
4339 2012-08-14  Diego Novillo  <dnovillo@google.com>
4340
4341         Merge from cxx-conversion branch.  C++ support in gengtype.
4342
4343         * coretypes.h (gt_pointer_operator): Move from ...
4344         * ggc.h: ... here.
4345         * doc/gty.texi: Document support for C++ templates and
4346         user-provided markers.
4347         * gcc/gengtype-lex.l: Update copyright year.
4348         Remove support for recognizing DEF_VEC_O, DEF_VEC_P and DEFVEC_I.
4349         * gengtype-parse.c: Update copyright year.
4350         (token_names): Remove DEF_VEC_O, DEF_VEC_P and DEF_VEC_I.
4351         (require_template_declaration): New.
4352         (typedef_name): Call it.
4353         (type): Replace IS_UNION with KIND. Replace all users.
4354         (def_vec): Remove.  Update all users.
4355         * gengtype-state.c (type_lineloc): Handle TYPE_USER_STRUCT.
4356         (write_state_user_struct_type): New.
4357         (write_state_type): Call it.
4358         (read_state_user_struct_type): New.
4359         (read_state_type): Call it.
4360         * gengtype.c: Update copyright year.
4361         (dump_pair): Move declaration to the top.
4362         (dump_type): Likewise.
4363         (dump_type_list): Likewise.
4364         (dbgprint_count_type_at): Handle TYPE_USER_STRUCT.
4365         (create_user_defined_type): New.
4366         (resolve_typedef): Call it.
4367         (new_structure): Replace argument ISUNION with KIND.
4368         Change users to refer to KIND directly.
4369         Update all callers.
4370         (find_structure): Likewise.
4371         (set_gc_used_type): Handle TYPE_USER_STRUCT.
4372         (create_file): Update HDR to include new copyright year.
4373         (struct walk_type_data): Add field IN_PTR_FIELD.
4374         (output_mangled_typename): Handle TYPE_USER_STRUCT.
4375         (walk_type): Set D->IN_PTR_FIELD when walking a TYPE_POINTER.
4376         Clear it afterwards.
4377         Handle TYPE_USER_STRUCT.
4378         (write_types_process_field): Handle TYPE_USER_STRUCT.
4379         (get_type_specifier): Move earlier in the file.
4380         (write_type_decl): New.
4381         (write_marker_function_name): New.
4382         (write_user_func_for_structure_ptr): New.
4383         (write_user_func_for_structure_body): New.
4384         (write_user_marking_functions): New.
4385         (write_func_for_structure): Call write_marker_function_name
4386         and write_type_decl.
4387         Do not call walk_type for TYPE_USER_STRUCT. Emit a call to the user
4388         function directly.
4389         Call write_user_marking_functions on TYPE_USER_STRUCTs.
4390         (write_types_local_user_process_field): New.
4391         (write_pch_user_walking_for_structure_body): New.
4392         (write_pch_user_walking_functions): New.
4393         (write_types_local_process_field): Handle TYPE_USER_STRUCT.
4394         (write_local_func_for_structure): Do not call walk_type for
4395         TYPE_USER_STRUCT. Instead, emit the call to gt_pch_nx directly.
4396         Call write_pch_user_walking_functions for TYPE_USER_STRUCTs.
4397         (write_root): Handle TYPE_USER_STRUCT.
4398         (vec_prefix_type): Remove.  Update all users.
4399         (note_def_vec): Remove.  Update all users.
4400         (dump_typekind): Handle TYPE_USER_STRUCT.
4401         (dump_type): Initialize SEEN_TYPES, if needed.
4402         Handle TYPE_USER_STRUCT.
4403         (dump_everything): Do not initialize SEEN_TYPES.
4404         * gengtype.h: Update copyright year.
4405         (enum typekind): Add TYPE_USER_STRUCT.
4406         (union_or_struct_p): Rename from UNION_OR_STRUCT_P.
4407         Convert into function.
4408         Add an overload taking const_type_p.
4409         Update all callers.
4410         (new_structure): Change second field to type enum typekind.
4411         Update all users.
4412         (find_structure): Likewise.
4413         (note_def_vec): Remove.
4414         (DEFVEC_OP): Remove.
4415         (DEFVEC_I): Remove.
4416         * ggc-page.c (gt_ggc_mx): Add entry points for marking
4417         'const char *&', 'unsigned char *&' and 'unsigned char&'.
4418         * ggc-zone.c (gt_ggc_mx): Add entry points for marking
4419         'const char *&' and 'unsigned char *&'.
4420         * stringpool.c (gt_pch_nx): Add entry points for marking
4421         'const char *&', 'unsigned char *&' and 'unsigned char&'.
4422         Add an entry point for the overload taking arguments 'unsigned char
4423         *', 'gt_pointer_operator' and 'void *'.
4424         * vec.h (struct vec_prefix): Remove GTY marker.
4425         (struct vec_t): Remove GTY((length)) attribute from field 'vec'.
4426         (gt_ggc_mx (vec_t<T> *)): New template function.
4427         (gt_pch_nx (vec_t<T> *)): New template function.
4428         (gt_pch_nx (vec_t<T *> *, gt_pointer_operator, void *)): New template
4429         function.
4430         (gt_pch_nx (vec_t<T> *, gt_pointer_operator, void *)): New template
4431         function.
4432
4433         * basic-block.h (struct edge_def): Mark GTY((user)).
4434         Remove all GTY markers from fields.
4435         (gt_ggc_mx): Declare.
4436         (gt_pch_nx): Declare.
4437         * tree-cfg.c (gt_ggc_mx): New.
4438         (gt_pch_nx): New.
4439
4440         * gengtype-lex.l (USER_GTY): Add pattern for "user".
4441         * gengtype-parse.c (option): Handle USER_GTY.
4442         (opts_have): New.
4443         (type): Call it.
4444         If the keyword 'user' is used, do not walk the fields
4445         of the structure.
4446         * gengtype.h (USER_GTY): Add.
4447         * doc/gty.texi: Update.
4448
4449 2012-08-14  Lawrence Crowl  <crowl@google.com>
4450
4451         Merge cxx-conversion branch.  Implement C++ hash table.
4452
4453         * hash-table.h: New. Implementation borrowed from libiberty/hashtab.c.
4454         * hash-table.c: Likewise.
4455         * tree-ssa-tail-merge.c: Include hash-table.h instead of hashtab.h.
4456         (static htab_t same_succ_htab): Change type to hash_table;
4457         move specification of helper functions from create call to declaration.
4458         Change users to invoke member functions.
4459         (same_succ_print_traverse): Make extern ssa_.... Change callers.
4460         Remove void* casting.
4461         (same_succ_hash): Likewise.
4462         (same_succ_equal): Likewise.
4463         (same_succ_delete): Likewise.
4464         * tree-ssa-threadupdate.c: Include hash-table.h.
4465         (struct local_info): Rename to ssa_local_info_t to avoid overloading
4466         the type name local_info with the variable name local_info.
4467         (static htab_t redirection_data): Change type to hash_table.
4468         Move specification of helper functions from create call to declaration.
4469         Change users to invoke member functions.
4470         (redirection_data_hash): Make extern ssa_.... Change callers.
4471         Remove void* casting.
4472         (redirection_data_eq): Likewise.
4473         (fix_duplicate_block_edges): Likewise.
4474         (create_duplicates): Likewise.
4475         (fixup_template_block): Likewise.
4476         (redirect_edges): Likewise.
4477         (lookup_redirection_data): Change types associated with the hash table
4478         from void* to their actual type. Remove unnecessary casts.
4479         * tree-ssa-ccp.c: Include hash-table.h.
4480         (typedef gimple_htab): New.  Uses hash_table.  Replace specific uses
4481         of htab_t with gimple_htab.  Change users to invoke member functions.
4482         Move specification of helper functions from create call to declaration.
4483         * tree-ssa-coalesce.c: Include hash-table.h instead of hashtab.h.
4484         (hash_ssa_name_by_var): Make extern. Remove void* casting.
4485         (eq_ssa_name_by_var): Likewise.
4486         (coalesce_ssa_name): Change type of local static htab_t ssa_name_hash
4487         to hash_table. Change users to invoke member functions.
4488         Move specification of helper functions from create call to declaration.
4489         * coverage.c: Include hash-table.h instead of hashtab.h.
4490         (static htab_t counts_hash): Change type to hash_table;
4491         move specification of helper functions from create call to declaration.
4492         Change users to invoke member functions.
4493         (htab_counts_entry_hash): Make extern. Rename with coverage_... instead
4494         of htab_... Remove void* casting.
4495         (htab_counts_entry_eq): Likewise.
4496         (htab_counts_entry_del): Likewise.
4497         * tree-ssa-pre.c: Include hash-table.h instead of hashtab.h.
4498         (static htab_t expression_to_id): Change type to hash_table.
4499         Move specification of helper functions from create call to declaration.
4500         Change users to invoke member functions.
4501         (static htab_t phi_translate_table): Likewise.
4502         (pre_expr_eq): Make extern ssa_.... Change callers.
4503         Remove void* casting.
4504         (pre_expr_hash): Likewise.
4505         (expr_pred_trans_hash): Likewise.
4506         (expr_pred_trans_eq): Likewise.
4507         (alloc_expression_id): Change types associated with the hash table
4508         from void* to their actual type. Remove unnecessary casts.
4509         (lookup_expression_id): Likewise.
4510         (phi_trans_lookup): Likewise.
4511         (phi_trans_add): Likewise.
4512         * stringpool.c: Rename uses of libcpp typedef hash_table to
4513         cpp_hash_table.
4514         * Makefile.in: Add hash-table.o to OBJS-libcommon-target.
4515         Add $(HASH_TABLE_H). Add new dependences on $(HASH_TABLE_H).
4516
4517 2012-08-14  Lawrence Crowl  <crowl@google.com>
4518
4519         Merge from cxx-conversion branch.  Re-write double_int in C++.
4520
4521         * hash-table.h
4522         (typedef double_int): Change to struct (POD).
4523         (double_int::make): New overloads for int to double-int conversion.
4524         (double_int::mask): New.
4525         (double_int::max_value): New.
4526         (double_int::min_value): New.
4527         (double_int::operator ++): New.
4528         (double_int::operator --): New.
4529         (double_int::operator *=): New.
4530         (double_int::operator +=): New.
4531         (double_int::operator -=): New.
4532         (double_int::to_signed): New.
4533         (double_int::to_unsigned): New.
4534         (double_int::fits_unsigned): New.
4535         (double_int::fits_signed): New.
4536         (double_int::fits): New.
4537         (double_int::trailing_zeros): New.
4538         (double_int::popcount): New.
4539         (double_int::multiple_of): New.
4540         (double_int::set_bit): New.
4541         (double_int::mul_with_sign): New.
4542         (double_int::operator * (binary)): New.
4543         (double_int::operator + (binary)): New.
4544         (double_int::operator - (binary)): New.
4545         (double_int::operator - (unary)): New.
4546         (double_int::operator ~ (unary)): New.
4547         (double_int::operator & (binary)): New.
4548         (double_int::operator | (binary)): New.
4549         (double_int::operator ^ (binary)): New.
4550         (double_int::and_not): New.
4551         (double_int::lshift): New.
4552         (double_int::rshift): New.
4553         (double_int::alshift): New.
4554         (double_int::arshift): New.
4555         (double_int::llshift): New.
4556         (double_int::lrshift): New.
4557         (double_int::lrotate): New.
4558         (double_int::rrotate): New.
4559         (double_int::div): New.
4560         (double_int::sdiv): New.
4561         (double_int::udiv): New.
4562         (double_int::mod): New.
4563         (double_int::smod): New.
4564         (double_int::umod): New.
4565         (double_int::divmod): New.
4566         (double_int::sdivmod): New.
4567         (double_int::udivmod): New.
4568         (double_int::ext): New.
4569         (double_int::zext): New.
4570         (double_int::sext): New.
4571         (double_int::is_zero): New.
4572         (double_int::is_one): New.
4573         (double_int::is_minus_one): New.
4574         (double_int::is_negative): New.
4575         (double_int::cmp): New.
4576         (double_int::ucmp): New.
4577         (double_int::scmp): New.
4578         (double_int::ult): New.
4579         (double_int::ugt): New.
4580         (double_int::slt): New.
4581         (double_int::sgt): New.
4582         (double_int::max): New.
4583         (double_int::smax): New.
4584         (double_int::umax): New.
4585         (double_int::min): New.
4586         (double_int::smin): New.
4587         (double_int::umin): New.
4588         (double_int::operator ==): New.
4589         (double_int::operator !=): New.
4590         (shwi_to_double_int): Change implementation to use member function.
4591         (double_int_minus_one): Likewise.
4592         (double_int_zero): Likewise.
4593         (double_int_one): Likewise.
4594         (double_int_two): Likewise.
4595         (double_int_ten): Likewise.
4596         (uhwi_to_double_int): Likewise.
4597         (double_int_to_shwi): Likewise.
4598         (double_int_to_uhwi): Likewise.
4599         (double_int_fits_in_uhwi_p): Likewise.
4600         (double_int_fits_in_shwi_p): Likewise.
4601         (double_int_fits_in_hwi_p): Likewise.
4602         (double_int_mul): Likewise.
4603         (double_int_mul_with_sign): Likewise.
4604         (double_int_add): Likewise.
4605         (double_int_sub): Likewise.
4606         (double_int_neg): Likewise.
4607         (double_int_div): Likewise.
4608         (double_int_sdiv): Likewise.
4609         (double_int_udiv): Likewise.
4610         (double_int_mod): Likewise.
4611         (double_int_smod): Likewise.
4612         (double_int_umod): Likewise.
4613         (double_int_divmod): Likewise.
4614         (double_int_sdivmod): Likewise.
4615         (double_int_udivmod): Likewise.
4616         (double_int_multiple_of): Likewise.
4617         (double_int_setbit): Likewise.
4618         (double_int_ctz): Likewise.
4619         (double_int_not): Likewise.
4620         (double_int_ior): Likewise.
4621         (double_int_and): Likewise.
4622         (double_int_and_not): Likewise.
4623         (double_int_xor): Likewise.
4624         (double_int_lshift): Likewise.
4625         (double_int_rshift): Likewise.
4626         (double_int_lrotate): Likewise.
4627         (double_int_rrotate): Likewise.
4628         (double_int_cmp): Likewise.
4629         (double_int_scmp): Likewise.
4630         (double_int_ucmp): Likewise.
4631         (double_int_max): Likewise.
4632         (double_int_smax): Likewise.
4633         (double_int_umax): Likewise.
4634         (double_int_min): Likewise.
4635         (double_int_smin): Likewise.
4636         (double_int_umin): Likewise.
4637         (double_int_ext): Likewise.
4638         (double_int_sext): Likewise.
4639         (double_int_zext): Likewise.
4640         (double_int_mask): Likewise.
4641         (double_int_max_value): Likewise.
4642         (double_int_min_value): Likewise.
4643         (double_int_zero_p): Likewise.
4644         (double_int_one_p): Likewise.
4645         (double_int_minus_one_p): Likewise.
4646         (double_int_equal_p): Likewise.
4647         (double_int_popcount): Likewise.
4648         * hash-table.c
4649         (double_int_mask): Reuse implementation for double_int::mask.
4650         (double_int_max_value): Likewise.
4651         (double_int_min_value): Likewise.
4652         (double_int_ext): Likewise.
4653         (double_int_zext): Likewise.
4654         (double_int_sext): Likewise.
4655         (double_int_mul_with_sign): Likewise.
4656         (double_int_divmod): Likewise.
4657         (double_int_sdivmod): Likewise.
4658         (double_int_udivmod): Likewise.
4659         (double_int_div): Likewise.
4660         (double_int_sdiv): Likewise.
4661         (double_int_udiv): Likewise.
4662         (double_int_mod): Likewise.
4663         (double_int_smod): Likewise.
4664         (double_int_umod): Likewise.
4665         (double_int_multiple_of): Likewise.
4666         (double_int_lshift): Likewise.
4667         (double_int_rshift): Likewise.
4668         (double_int_lrotate): Likewise.
4669         (double_int_rrotate): Likewise.
4670         (double_int_cmp): Likewise.
4671         (double_int_ucmp): Likewise.
4672         (double_int_scmp): Likewise.
4673         (double_int_max): Likewise.
4674         (double_int_smax): Likewise.
4675         (double_int_umax): Likewise.
4676         (double_int_min): Likewise.
4677         (double_int_smin): Likewise.
4678         (double_int_umin): Likewise.
4679         (double_int_min): Likewise.
4680         (double_int_min): Likewise.
4681         (double_int_min): Likewise.
4682         (double_int_min): Likewise.
4683         (double_int_min): Likewise.
4684         (double_int_min): Likewise.
4685         (double_int::alshift): New.
4686         (double_int::arshift): New.
4687         (double_int::llshift): New.
4688         (double_int::lrshift): New.
4689         (double_int::ult): New.
4690         (double_int::ugt): New.
4691         (double_int::slt): New.
4692         (double_int::sgt): New.
4693         (double_int_setbit): Reuse implementation for double_int::set_bit,
4694         which avoids a name conflict with a macro.
4695         (double_int_double_int_ctz): Reuse implementation for
4696         double_int::trailing_zeros.
4697         (double_int_fits_in_shwi_p): Reuse implementation for
4698         double_int::fits_signed.
4699         (double_int_fits_in_hwi_p): Reuse implementation for double_int::fits.
4700         (double_int_mul): Reuse implementation for binary
4701         double_int::operator *.
4702         (double_int_add): Likewise.
4703         (double_int_sub): Likewise.
4704         (double_int_neg): Reuse implementation for unary
4705         double_int::operator -.
4706         (double_int_max_value): Likewise.
4707         * fixed-value.c: Change to use member functions introduced above.
4708
4709 2012-08-14  Lawrence Crowl  <crowl@google.com>
4710
4711         Merge cxx-conversion branch.  Support tree macro calling from gdb.
4712
4713         * tree.h (tree_check): New.
4714         (TREE_CHECK): Use inline function above instead of __extension__.
4715         (tree_not_check): New.
4716         (TREE_NOT_CHECK): Use inline function above instead of __extension__.
4717         (tree_check2): New.
4718         (TREE_CHECK2): Use inline function above instead of __extension__.
4719         (tree_not_check2): New.
4720         (TREE_NOT_CHECK2): Use inline function above instead of __extension__.
4721         (tree_check3): New.
4722         (TREE_CHECK3): Use inline function above instead of __extension__.
4723         (tree_not_check3): New.
4724         (TREE_NOT_CHECK3): Use inline function above instead of __extension__.
4725         (tree_check4): New.
4726         (TREE_CHECK4): Use inline function above instead of __extension__.
4727         (tree_not_check4): New.
4728         (TREE_NOT_CHECK4): Use inline function above instead of __extension__.
4729         (tree_check5): New.
4730         (TREE_CHECK5): Use inline function above instead of __extension__.
4731         (tree_not_check5): New.
4732         (TREE_NOT_CHECK5): Use inline function above instead of __extension__.
4733         (contains_struct_check): New.
4734         (CONTAINS_STRUCT_CHECK): Use inline function above instead of
4735         __extension__.
4736         (tree_class_check): New.
4737         (TREE_CLASS_CHECK): Use inline function above instead of __extension__.
4738         (tree_range_check): New.
4739         (TREE_RANGE_CHECK): Use inline function above instead of __extension__.
4740         (omp_clause_subcode_check): New.
4741         (OMP_CLAUSE_SUBCODE_CHECK): Use inline function above instead of
4742         __extension__.
4743         (omp_clause_range_check): New.
4744         (OMP_CLAUSE_RANGE_CHECK): Use inline function above instead of
4745         __extension__.
4746         (expr_check): New.
4747         (EXPR_CHECK): Use inline function above instead of __extension__.
4748         (non_type_check): New.
4749         (NON_TYPE_CHECK): Use inline function above instead of __extension__.
4750         (tree_vec_elt_check): New.
4751         (TREE_VEC_ELT_CHECK): Use inline function above instead of
4752         __extension__.
4753         (omp_clause_elt_check): New.
4754         (OMP_CLAUSE_ELT_CHECK): Use inline function above instead of
4755         __extension__.
4756         (tree_operand_check): New.
4757         (TREE_OPERAND_CHECK): Use inline function above instead of
4758         __extension__.
4759         (tree_operand_check_code): New.
4760         (TREE_OPERAND_CHECK_CODE): Use inline function above instead of
4761         __extension__.
4762         (TREE_CHAIN): Simplify implementation.
4763         (TREE_TYPE): Simplify implementation.
4764         (tree_operand_length): Move for compilation dependences.
4765         * gdbinit.in: (macro define __FILE__): New.
4766         (macro define __LINE__): New.
4767         (skip "tree.h"): New.
4768
4769 2012-08-14  Oleg Endo  <olegendo@gcc.gnu.org>
4770
4771         PR target/52933
4772         * config/sh/sh.md (cmp_div0s_0, cmp_div0s_1, *cmp_div0s_0,
4773         *cmp_div0s_1, *cbranch_div0s, *movsicc_div0s): New insns.
4774         * config/sh/sh.c (sh_rtx_costs): Handle div0s patterns.
4775
4776 2012-08-14  Oleg Endo  <olegendo@gcc.gnu.org>
4777
4778         PR target/50751
4779         * config/sh/constraints.md (Sra): New constraint.
4780         * config/sh/predicates.md (simple_mem_operand,
4781         displacement_mem_operand, zero_extend_movu_operand): New predicates.
4782         (zero_extend_operand): Check zero_extend_movu_operand for SH2A.
4783         * config/sh/sh.md (*zero_extendqisi2_disp_mem,
4784         *zero_extendhisi2_disp_mem): Add new insns and two new related
4785         peephole2 patterns.
4786
4787 2012-08-14  Steven Bosscher  <steven@gcc.gnu.org>
4788
4789         * graphite-scop-detection.c (create_sese_edges): Compute dominance
4790         info before trying to fix loop structure.
4791         * cfgloopmanip.c (fix_loop_structure): Require fast DOM queries.
4792         * tree-cfgcleanup.c (repair_loop_structures): Likewise.
4793         * cfgloop.c (verify_loop_structure): Verify loop fathers.
4794
4795         * dominance.c (init_dom_info): Use gcc_checking_assert, not gcc_assert.
4796         (dom_convert_dir_to_idx, compute_dom_fast_query,
4797         get_immediate_dominator, set_immediate_dominator, get_dominated_by,
4798         redirect_immediate_dominators, nearest_common_dominator,
4799         (dominated_by_p, bb_dom_dfs_in, bb_dom_dfs_out, recompute_dominator,
4800         iterate_fix_dominators, add_to_dominance_info,
4801         delete_from_dominance_info): Likewise.
4802
4803 2012-08-14  Richard Guenther  <rguenther@suse.de>
4804
4805         * cfgexpand.c (expand_used_vars): Use virtual_operand_p.
4806         * gimple-pretty-print.c (dump_phi_nodes): Likewise.
4807         * gimple-streamer-out.c (output_bb): Likewise.
4808         * graphite-sese-to-poly.c (scalar_close_phi_node_p): Likewise.
4809         (rewrite_reductions_out_of_ssa): Likewise.
4810         (rewrite_commutative_reductions_out_of_ss): Likewise.
4811         * ipa-split.c (verify_non_ssa_vars): Likewise.
4812         (consider_split): Likewise.
4813         (visit_bb): Likewise.
4814         (split_function): Likewise.
4815         * lto-streamer-out.c (output_ssa_names): Likewise.
4816         * sese.c (rename_uses): Likewise.
4817         * tree-cfg.c (replace_uses_by): Likewise.
4818         (gimple_merge_blocks): Likewise.
4819         (gimple_cfg2dot): Likewise.
4820         (verify_gimple_phi): Likewise.
4821         (replace_ssa_name): Likewise.
4822         (move_block_to_fn): Likewise.
4823         * tree-eh.c (cleanup_empty_eh_merge_phis): Likewise.
4824         * tree-if-conv.c (if_convertible_phi_p): Likewise.
4825         (predicate_scalar_phi): Likewise.
4826         * tree-inline.c (update_ssa_across_abnormal_edges): Likewise.
4827         (copy_phis_for_bb): Likewise.
4828         * tree-loop-distribution.c (generate_loops_for_partition): Likewise.
4829         (destroy_loop): Likewise.
4830         * tree-outof-ssa.c (eliminate_useless_phis): Likewise.
4831         (insert_backedge_copies): Likewise.
4832         * tree-parloops.c (transform_to_exit_first_loop): Likewise.
4833         (gather_scalar_reductions): Likewise.
4834         (try_create_reduction_list): Likewise.
4835         * tree-scalar-evolution.c (analyze_scalar_evolution_for_all_loop_ph):
4836         Likewise.
4837         (scev_const_prop): Likewise.
4838         * tree-ssa-ccp.c (debug_lattice_value): Likewise.
4839         (get_default_value): Likewise.
4840         (ccp_initialize): Likewise.
4841         * tree-ssa-coalesce.c (create_outofssa_var_map): Likewise.
4842         * tree-ssa-copy.c (may_propagate_copy): Likewise.
4843         (init_copy_prop): Likewise.
4844         * tree-ssa-dce.c (propagate_necessity): Likewise.
4845         (remove_dead_phis): Likewise.
4846         (forward_edge_to_pdom): Likewise.
4847         (eliminate_unnecessary_stmts): Likewise.
4848         * tree-ssa-live.c (partition_view_init): Likewise.
4849         (remove_unused_locals): Likewise.
4850         (register_ssa_partition_check): Likewise.
4851         * tree-ssa-loop-im.c (movement_possibility): Likewise.
4852         (move_computations_stmt): Likewise.
4853         * tree-ssa-loop-ivopts.c (determine_biv_step): Likewise.
4854         (record_invariant): Likewise.
4855         (find_interesting_uses_outside): Likewise.
4856         (determine_set_costs): Likewise.
4857         * tree-ssa-loop-manip.c (add_exit_phis_var): Likewise.
4858         (find_uses_to_rename_use): Likewise.
4859         (check_loop_closed_ssa_use): Likewise.
4860         (rewrite_phi_with_iv): Likewise.
4861         (canonicalize_loop_ivs): Likewise.
4862         * tree-ssa-math-opts.c (execute_cse_reciprocals): Likewise.
4863         * tree-ssa-phiopt.c (hoist_adjacent_loads): Likewise.
4864         * tree-ssa-pre.c (make_values_for_phi): Likewise.
4865         (compute_avail): Likewise.
4866         (eliminate): Likewise.
4867         * tree-ssa-propagate.c (substitute_and_fold): Likewise.
4868         * tree-ssa-reassoc.c (phi_rank): Likewise.
4869         * tree-ssa-strlen.c (strlen_enter_block): Likewise.
4870         * tree-ssa-structalias.c (compute_points_to_sets): Likewise.
4871         (ipa_pta_execute): Likewise.
4872         * tree-ssa-tail-merge.c (same_succ_hash): Likewise.
4873         (release_last_vdef): Likewise.
4874         (same_phi_alternatives_1): Likewise.
4875         (bb_has_non_vop_phi): Likewise.
4876         (vop_phi): Likewise.
4877         * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
4878         Likewise.
4879         * tree-ssa-uninit.c (warn_uninitialized_phi): Likewise.
4880         (execute_late_warn_uninitialized): Likewise.
4881         * tree-ssa.c (verify_ssa_name): Likewise.
4882         (verify_phi_args): Likewise.
4883         (verify_ssa): Likewise.
4884         * tree-stdarg.c (execute_optimize_stdarg): Likewise.
4885         * tree-vect-loop-manip.c (slpeel_update_phi_nodes_for_guard1):
4886         Likewise.
4887         (slpeel_tree_peel_loop_to_edge): Likewise.
4888         (vect_can_advance_ivs_p): Likewise.
4889         (vect_update_ivs_after_vectorizer): Likewise.
4890         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Likewise.
4891         * tree-vrp.c (remove_range_assertions): Likewise.
4892         * value-prof.c (gimple_divmod_values_to_profile): Likewise.
4893
4894 2012-08-14  Richard Guenther  <rguenther@suse.de>
4895
4896         PR tree-optimization/54146
4897         * tree-ssa-pre.c (do_regular_insertion): Use a VEC
4898         indexed by pred edge index for avail.
4899         (do_partial_partial_insertion): Likewise.
4900         (insert_into_preds_of_block): Adjust.
4901
4902 2012-08-14  Richard Guenther  <rguenther@suse.de>
4903
4904         * gimplify.c (create_tmp_from_val): Mark temporary with
4905         DECL_GIMPLE_REG_P here ...
4906         (internal_get_tmp_var): ... instead of here.  If we go into
4907         SSA create an SSA name instead of a VAR_DECL.
4908         (gimplify_modify_expr): Do not create SSA names here, assert
4909         we already got them.
4910         (force_gimple_operand_1): Create an SSA name if we go into SSA.
4911         * sese.c (rename_uses): Simplify.
4912
4913 2012-08-14  Richard Guenther  <rguenther@suse.de>
4914
4915         * tree-into-ssa.c: Include diagnostic-core.h.
4916         * Makefile.in (tree-into-ssa.o): Adjust.
4917
4918 2012-08-14  Richard Guenther  <rguenther@suse.de>
4919
4920         * tree-into-ssa.c (update_ssa): Verify we do not rename
4921         symbols that are already partly in SSA form.
4922
4923 2012-08-14  Jakub Jelinek  <jakub@redhat.com>
4924
4925         PR middle-end/53411
4926         PR rtl-optimization/53495
4927         * ira.c (ira): Move delete_trivially_dead_insns call before
4928         find_moveable_pseudos call.
4929
4930 2012-08-13  Steven Bosscher  <steven@gcc.gnu.org>
4931
4932         * tree-ssa-pre.c (do_regular_insertion): Add FIXME markers at points
4933         of potentially huge memset overhead.
4934         (do_partial_partial_insertion): Likewise.
4935         * cfgexpand.c (gimple_expand_cfg): Use XCNEWVEC instead of xcalloc.
4936         * tree-vrp.c (find_assert_locations): Use XNEWVEC instead of XCNEWVEC
4937         for arrays to be filled by pre_and_rev_post_order_compute.  Allocate
4938         the right number of slots, not that number plus NUM_FIXED_BLOCKS.
4939         * tree-ssa-reassoc.c (init_reassoc): Likewise.
4940         * cfganal.c (dfs_enumerate_from): Use XNEWVEC instead of XCNEWVEC for
4941         array used as stack.
4942         * tree-ssa-sccvn.c (init_scc_vn): Use XNEWVEC instead of XCNEWVEC for
4943         arrays to be filled by pre_and_rev_post_order_compute.
4944         * cfgloopmanip.c (find_path): Use XNEWVEC instead of XCNEWVEC for
4945         array to be filled by dfs_enumerate_from.
4946         (remove_path): Likewise.
4947         (duplicate_loop_to_header_edge): Use XNEWVEC instead of XCNEWVEC for
4948         array of loops that is filled on the next lines.
4949         * cfgloop.c (get_loop_body): Use XNEWVEC instead of XCNEWVEC for
4950         array of basic blocks to be returned.
4951         (get_loop_body_in_dom_order): Likewise.
4952         (get_loop_body_in_bfs_order): Likewise.
4953         * tree-ssa-loop-manip.c (loop_renamer_obstack): New static obstack
4954         for all bitmaps used for rewriting into loop-closed SSA form.
4955         (add_exit_phis_var): Allocate the def bitmap on it.  Clear the livein
4956         bitmap at the end to release a lot of memory.
4957         (add_exit_phis): Allocate the exits bitmap on the new obstack.
4958         (get_loops_exits): Allocate the exits bitmap on the new obstack.
4959         (find_uses_to_rename_use): Allocate a use_blocks bitmap if ver is
4960         seen for the first time.
4961         (find_uses_to_rename): Add "???" for why the whole function must
4962         be re-scanned if changed_bbs is empty.
4963         (rewrite_into_loop_closed_ssa): Allocate bitmaps on the new obstack.
4964         Use XNEWVEC to allocate the use_blocks array.  Initialize the new
4965         obstack, and free it at the end.  Remove loop over all SSA names.
4966         (check_loop_closed_ssa_stmt): Look only at SSA_OP_USE operands.
4967         * tree-cfg.c (move_sese_region_to_fn): Use XNEWVEC instead of
4968         xcalloc to allocate edge_pred and edge_flag arrays.
4969
4970 2012-08-13  Uros Bizjak  <ubizjak@gmail.com>
4971
4972         * config/i386/i386.h (FIXED_REGISTERS): Do not mark REX registers here.
4973         (CALL_USED_REGISTERS): Use bitmaps to mark call-used registers
4974         for different ABIs.
4975         (enum reg_class): Move CLOBBERED_REGS just before GENERAL_REGS.
4976         (REG_CLASS_NAMES): Update.
4977         (REG_CLASS_CONTENTS): Update.  Clear CLOBBERED_REGS members.
4978         * config/i386/i386.c (ix86_conditional_register_usage): Disable
4979         REX registers on 32bit targets.  Handle bitmaps from
4980         CALL_USED_REGISTERS initializer.  Calculate CLOBBERED_REGS register
4981         set from GENERAL_REGS also for 32bit targets.  Do not change call
4982         used register set for TARGET_64BIT_MS_ABI separately.
4983
4984 2012-08-13  Richard Guenther  <rguenther@suse.de>
4985
4986         * basic-block.h (struct basic_block): Remove loop_depth
4987         member, move flags and index members next to each other.
4988         * cfgloop.h (bb_loop_depth): New inline function.
4989         * cfghooks.c (split_block): Do not set loop_depth.
4990         (duplicate_block): Likewise.
4991         * cfgloop.c (flow_loop_nodes_find): Likewise.
4992         (flow_loops_find): Likewise.
4993         (add_bb_to_loop): Likewise.
4994         (remove_bb_from_loops): Likewise.
4995         * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
4996         * gimple-streamer-in.c (input_bb): Do not stream loop_depth.
4997         * gimple-streamer-out.c (output_bb): Likewise.
4998         * bt-load.c: Include cfgloop.h.
4999         (migrate_btr_defs): Use bb_loop_depth.
5000         * cfg.c (dump_bb_info): Likewise.
5001         * final.c (compute_alignments): Likewise.
5002         * ira.c (update_equiv_regs): Likewise.
5003         * tree-ssa-copy.c (init_copy_prop): Likewise.
5004         * tree-ssa-dom.c (loop_depth_of_name): Likewise.
5005         * tree-ssa-forwprop.c: Include cfgloop.h.
5006         (forward_propagate_addr_expr): Use bb_loop_depth.
5007         * tree-ssa-pre.c (insert_into_preds_of_block): Likewise.
5008         * tree-ssa-sink.c (select_best_block): Likewise.
5009         * ipa-inline-analysis.c: Include cfgloop.h.
5010         (estimate_function_body_sizes): Use bb_loop_depth.
5011         * Makefile.in (tree-ssa-forwprop.o): Depend on $(CFGLOOP_H).
5012         (ipa-inline-analysis.o): Likewise.
5013         (bt-load.o): Likewise.
5014
5015 2012-08-13  Ganesh Gopalasubramanian  <Ganesh.Gopalasubramanian@amd.com>
5016             Jakub Jelinek  <jakub@redhat.com>
5017
5018         PR driver/54210
5019         * config/i386/driver-i386.c (host_detect_local_cpu): Test bit_PRFCHW
5020         bit of CPUID 0x80000001 %ecx instead of CPUID 7 %ecx.
5021         * config/i386/cpuid.h (bits_PRFCHW): Move definition to CPUID
5022         0x80000001 %ecx flags.
5023
5024 2012-08-13  Richard Guenther  <rguenther@suse.de>
5025
5026         * tree-cfg.c (print_loop): Avoid ICEing for loops marked for
5027         removal and loops with multiple latches.
5028
5029 2012-08-13  Jakub Jelinek  <jakub@redhat.com>
5030
5031         PR c/53968
5032         * tree.c (integer_pow2p): Avoid undefined signed overflows.
5033         * simplify-rtx.c (neg_const_int): Likewise.
5034         * expr.c (fixup_args_size_notes): Likewise.
5035         * stor-layout.c (set_min_and_max_values_for_integral_type): Likewise.
5036         * double-int.c (mul_double_wide_with_sign): Likewise.
5037         (double_int_mask): Likewise.
5038         * tree-ssa-loop-ivopts.c (get_address_cost): Likewise.
5039
5040 2012-08-13  Richard Guenther  <rguenther@suse.de>
5041
5042         PR tree-optimization/54200
5043         * tree-ssa-copyrename.c (rename_ssa_copies): Do not add
5044         PHI results to another partition if not all PHI arguments
5045         have the same partition.
5046
5047 2012-08-12  Jan Hubicka  <jh@suse.cz>
5048
5049         * tree-pass.h (write_summary, write_optimization_summary): Remove
5050         set and vset arguments.
5051         * ipa-cp.c (ipcp_write_summary): Remove set and vset arugments.
5052         (write_node_summary_p): Likewise; use the encoder.
5053         (ipa_reference_write_optimization_summary): Likewise.
5054         * lto-cgraph.c (output_cgraph_opt_summary): Use encoder.
5055         (lto_symtab_encoder_new): Initialize in_partition field.
5056         (lto_symtab_encoder_delete): Destroy in_partition field.
5057         (LCC_NOT_FOUND): Move to lto-streamer.h
5058         (lto_symtab_encoder_deref): Likewise.
5059         (lto_symtab_encoder_in_partition_p,
5060         lto_set_symtab_encoder_in_partition): New functions.
5061         (referenced_from_other_partition_p): Rewrite to use encoder.
5062         (reachable_from_other_partition_p): Likewise.
5063         (referenced_from_this_partition_p): Likewise.
5064         (reachable_from_this_partition_p): Likewise.
5065         (lto_output_node): Likewise.
5066         (lto_output_varpool_node): Likewise.
5067         (output_refs): Likewise.
5068         (compute_ltrans_boundary): Initialize in_partition fileds of
5069         the encoder.
5070         (output_symtab): Likewise.
5071         (input_refs): Match the changes in output_refs.
5072         (output_cgraph_opt_summary_p): Remove set argument.
5073         (output_node_opt_summary): Replace set by encoder.
5074         (output_cgraph_opt_summary): Remove set argument; use
5075         the encoder.
5076         * ipa-pure-const.c (pure_const_write_summary): Remove set and vset
5077         arguments; use the encoder.
5078         * lto-streamer-out.c (lto_output): Remove set and vset argument; use
5079         the encoder.
5080         (produce_symtab): Likewise.
5081         * ipa-inline.h (inline_write_summary): Remove set and vset arguments.
5082         * ipa-inline-analysis.c (inline_write_summary): Likewise.
5083         * ipa-prop.c (ipa_prop_write_jump_functions): Remove set argument;
5084         use encoder.
5085         * ipa-prop.h (ipa_prop_write_jump_functions): Likewise.
5086         * passes.c (ipa_write_summaries_2): Remove set and vset arguments.
5087         (ipa_write_summaries_1): Update.
5088         (ipa_write_optimization_summaries_1): Likewise.
5089         (ipa_write_optimization_summaries): Likewise.
5090         * lto-streamer.h (lto_symtab_encoder_t): Add in_partition.
5091         (lto_symtab_encoder_iterator): New type.
5092         (lto_symtab_encoder_deref): Make inline.
5093         (output_symtab, referenced_from_other_partition_p,
5094         reachable_from_other_partition_p, referenced_from_this_partition_p,
5095         reachable_from_this_partition_p): Update.
5096         (lsei_end_p, lsei_next, lsei_node, lsei_cgraph_node,
5097         lsei_varpool_node): New inline functions.
5098         (LCC_NOT_FOUND): New macro.
5099         (lto_symtab_encoder_deref, lsei_start, lsei_next_in_partition,
5100         lsei_start_in_partition, lsei_next_function_in_partition,
5101         lsei_start_function_in_partition, lsei_next_variable_in_partition,
5102         lsei_start_variable_in_partition): New inline functions.
5103
5104 2012-08-12  Oleg Endo  <olegendo@gcc.gnu.org>
5105
5106         * config/sh/sh.md (prefetch): Simplify expander.  Fix condition to
5107         allow SH3.
5108         (*prefetch_media): Move insn below expander.
5109         (*prefetch): Fix condition to allow SH3.
5110
5111 2012-08-12  Oleg Endo  <olegendo@gcc.gnu.org>
5112
5113         PR target/51244
5114         * config/sh/sh.md: Add splits for inverted compare and branch
5115         opportunities.
5116         (*cmpeqsi_t): New insn.
5117         (cmpgtsi_t, cmpgesi_t): Swap r and N alternatives.
5118         (cmpgeusi_t): Use satisfies_constraint_Z.  Emit sett insn in
5119         replacement insn list and not in the preparation statements.
5120         (clrt, sett): Add mt_group attribute.
5121
5122 2012-08-12 Marc Glisse <marc.glisse@inria.fr>
5123
5124         PR middle-end/54193
5125         * gimple-pretty-print.c (dump_ternary_rhs): Handle 4 arguments.
5126
5127 2012-08-12  Oleg Endo  <olegendo@gcc.gnu.org>
5128
5129         PR target/39423
5130         * config/sh/predicates.md (mem_index_disp_operand): Check for
5131         arith_reg_operand instead of REG_P.
5132
5133 2012-08-11  Bernd Schmidt  <bernds@codesourcery.com>
5134
5135         * reload1.c (replaced_subreg, gen_reload): Add
5136         SECONDARY_MEMORY_NEEDED ifdefs as necessary.
5137
5138 2012-08-11  Jan Hubicka  <jh@suse.cz>
5139
5140         * lto-section-in.c (lto_section_name): Do not use "symtab" as part of
5141         symtab_node sectoin name; it confuses plugin.
5142
5143 2012-08-11  Uros Bizjak  <ubizjak@gmail.com>
5144
5145         * config/alpha/alpha.c (alpha_stdarg_optimize_hook): Shift DECL_UID
5146         index in the va_list_vars bitmap by num_ssa_names.
5147
5148 2012-08-11  Uros Bizjak  <ubizjak@gmail.com>
5149
5150         * config/i386/sse.md (xop integer multiply/add insns): Use
5151         register_operand for operand 3 predicate.
5152         (xop_phadd<u>bq):  Fix vec_select selectors.
5153
5154 2012-08-11  Martin Jambor  <mjambor@suse.cz>
5155
5156         PR fortran/48636
5157         * ipa-inline.h (condition): New fields offset, agg_contents and by_ref.
5158         * ipa-inline-analysis.c (agg_position_info): New type.
5159         (add_condition): New parameter aggpos, also store agg_contents, by_ref
5160         and offset.
5161         (dump_condition): Also dump aggregate conditions.
5162         (evaluate_conditions_for_known_args): Also handle aggregate
5163         conditions.  New parameter known_aggs.
5164         (evaluate_properties_for_edge): Gather known aggregate contents.
5165         (inline_node_duplication_hook): Pass NULL known_aggs to
5166         evaluate_conditions_for_known_args.
5167         (unmodified_parm): Split into unmodified_parm and unmodified_parm_1.
5168         (unmodified_parm_or_parm_agg_item): New function.
5169         (set_cond_stmt_execution_predicate): Handle values passed in
5170         aggregates.
5171         (set_switch_stmt_execution_predicate): Likewise.
5172         (will_be_nonconstant_predicate): Likewise.
5173         (estimate_edge_devirt_benefit): Pass new parameter known_aggs to
5174         ipa_get_indirect_edge_target.
5175         (estimate_calls_size_and_time): New parameter known_aggs, pass it
5176         recrsively to itself and to estimate_edge_devirt_benefit.
5177         (estimate_node_size_and_time): New vector known_aggs, pass it o
5178         functions which need it.
5179         (remap_predicate): New parameter offset_map, use it to remap aggregate
5180         conditions.
5181         (remap_edge_summaries): New parameter offset_map, pass it recursively
5182         to itself and to remap_predicate.
5183         (inline_merge_summary): Also create and populate vector offset_map.
5184         (do_estimate_edge_time): New vector of known aggregate contents,
5185         passed to functions which need it.
5186         (inline_read_section): Stream new fields of condition.
5187         (inline_write_summary): Likewise.
5188         * ipa-cp.c (ipa_get_indirect_edge_target): Also examine the aggregate
5189         contents.  Let all local callers pass NULL for known_aggs.
5190
5191 2012-08-11  Jan Hubicka  <jh@suse.cz>
5192
5193         * lto-cgraph.c (output_cgraph): Rename to ...
5194         (output_symtab): ... this one. Update for LTO_section_symtab_nodes.
5195         (input_cgraph): Rename to ...
5196         (input_symtab): ... this one. Update for LTO_section_symtab_nodes.
5197         * lto-streamer-out.c (create_output_block): Do not set
5198         section_type.
5199         (produce_asm): Likewise.
5200         (lto_output_toplevel_asms): Likewise.
5201         (produce_asm_for_decls): Likewise.
5202         (lto_output): Use output_symtab.
5203         * lto-section-in.c (lto_section_name): Update.
5204         * lto-section-out.c (lto_destroy_simple_output_block): Remove
5205         section_type.
5206         * lto-streamer.h (enum lto_section_type): Remove LTO_section_varpool;
5207         rename LTO_section_cgraph to LTO_section_symtab_nodes.
5208         (struct lto_header): Remove section_type.
5209
5210 2012-08-11  Jan Hubicka  <jh@suse.cz>
5211
5212         * cgraph.h (vector types for symtab_node): Add.
5213         * ipa-reference.c (ipa_reference_write_optimization_summary): Update
5214         for new symtab encoder.
5215         (ipa_reference_read_optimization_summary): Likewise.
5216         * lto-cgraph.c (output_varpool): Remove.
5217         (input_cgraph_opt_summary): Take symtab nodes vector as argument.
5218         (LTO_cgraph_tags): Rename to ...
5219         (LTO_symtab_tags): ... this one; add LTO_symtab_variable.
5220         (lto_cgraph_encoder_new): Rename to ...
5221         (lto_symtab_encoder_new): ... this on.
5222         (lto_cgraph_encoder_encode): Rename to ...
5223         (lto_symtab_encoder_encode): ... this one.
5224         (lto_cgraph_encoder_delete): Rename to ...
5225         (lto_symtab_encoder_delete): ... this one.
5226         (lto_cgraph_encoder_deref): Rename to ...
5227         (lto_symtab_encoder_deref): ... this one.
5228         (lto_cgraph_encoder_encode_body_p): Rename to ...
5229         (lto_symtab_encoder_encode_body_p): ... this one.
5230         (lto_varpool_encoder_new, lto_varpool_encoder_delete,
5231         lto_varpool_encoder_encode, lto_varpool_encoder_lookup,
5232         lto_varpool_encoder_deref): Remove.
5233         (lto_varpool_encoder_encode_initializer_p): Rename to ...
5234         (lto_symtab_encoder_encode_initializer_p): ... this one.
5235         (lto_set_varpool_encoder_encode_initializer): Rename to ...
5236         (lto_set_symtab_encoder_encode_initializer): ... this one.
5237         (lto_output_edge): Update.
5238         (lto_output_node): Update.
5239         (lto_output_varpool_node): Update; stream out LTO_symtab_variable tag.
5240         (lto_output_ref): Drop varpool_encoder; update.
5241         (add_node_to): Update.
5242         (add_references): Update.
5243         (output_outgoing_cgraph_edges): Update.
5244         (output_refs): Update.
5245         (compute_ltrans_boundary): Update.
5246         (output_cgraph): Update; output varpools too.
5247         (input_overwrite_node): Update.
5248         (output_varpool): Remove.
5249         (input_node): Update.
5250         (input_ref): Update.
5251         (input_edge): Update.
5252         (input_cgraph_1): Update; input varpool too; unify fixup code.
5253         (input_varpool_1): Remove.
5254         (input_refs): Update.
5255         (input_cgraph): Update.
5256         (output_node_opt_summary): Update.
5257         (input_cgraph_opt_section): Update.
5258         (input_cgraph_opt_summary): Update.
5259         * ipa-pure-const.c (pure_const_write_summary): Update.
5260         (pure_const_read_summary): Update.
5261         * lto-streamer-out.c (lto_write_tree): Update.
5262         (lto_output): Likewise.
5263         (produce_symtab): Update.
5264         (produce_asm_for_decls): Update.
5265         * ipa-inline-analysis.c (inline_read_section): Update.
5266         (inline_write_summary): Update.
5267         * ipa-prop.c (ipa_write_node_info): Update.
5268         (ipa_prop_read_section): Update.
5269         * lto-streamer.h (lto_cgraph_encoder_d): Rename to ...
5270         (lto_symtab_encoder_d): ... this one;  add initializer.
5271         (lto_cgraph_encoder_t): Rename to ...
5272         (lto_symtab_encoder_t): ... this one.
5273         (lto_cgraph_encoder_size): Rename to ...
5274         (lto_symtab_encoder_size): ... this one.
5275         (lto_varpool_encoder_d): ... remove.
5276         (lto_varpool_encoder_t): Remove.
5277         (lto_out_decl_state): Remove cgraph_node_encoder, varpool_node_encoder
5278         add symtab_node_encoder.
5279         (lto_file_decl_data): Likewise.
5280         (lto_cgraph_encoder_deref, lto_cgraph_encoder_lookup,
5281         lto_cgraph_encoder_new, lto_cgraph_encoder_encode,
5282         lto_cgraph_encoder_delete, lto_cgraph_encoder_encode_body_p,
5283         lto_varpool_encoder_encode_body_p, lto_varpool_encoder_deref,
5284         lto_varpool_encoder_lookup, lto_varpool_encoder_new,
5285         lto_varpool_encoder_encode, lto_varpool_encoder_delete,
5286         lto_varpool_encoder_encode_initializer_p): Remove.
5287         (lto_symtab_encoder_deref, lto_symtab_encoder_lookup,
5288         lto_symtab_encoder_t, lto_symtab_encoder_encode,
5289         lto_symtab_encoder_delete, lto_symtab_encoder_encode_body_p,
5290         lto_symtab_encoder_encode_initializer_p): New.
5291
5292 2012-08-11  Uros Bizjak  <ubizjak@gmail.com>
5293
5294         * config/i386/i386.md (isa): Add fma and fma4.
5295         (enabled): Handle fma and fma4.
5296         * config/i386/sse.md (*fma_fmadd_<mode>): Merge *fma4_fmadd_<mode>.
5297         (*fma_fmsub_<mode>): Merge *fma4_fmsub_<mode>.
5298         (*fma_fnmadd_<mode>): Merge *fma4_fnmadd_<mode>.
5299         (*fma_fnmsub_<mode>): Merge *fma4_fnmsub_<mode>.
5300         (*fma_fmaddsub_<mode>): Merge *fma4_fmaddsub_<mode>.
5301         (*fma_fmsubadd_<mode>): Merge *fma4_fmsubadd_<mode>.
5302
5303 2012-08-10  Uros Bizjak  <ubizjak@gmail.com>
5304
5305         * config/i386/sse.md (*fma_fmadd_<mode>, *fma_fmsub_<mode>,
5306         *fma_fnmadd_<mode>, *fma_fnmsub_<mode>, *fma_fmaddsub_<mode>,
5307         *fma_fmsubadd_<mode>): Move FMA3 insn patterns before FMA4 patterns.
5308
5309 2012-08-10  Uros Bizjak  <ubizjak@gmail.com>
5310
5311         * config/i386/i386.md (simple LEA peephole2s): Add zero-extend
5312         variants of PLUS and MULT simple LEA patterns.  Disable PLUS
5313         patterns for TARGET_OPT_AGU.
5314
5315 2012-08-10  Richard Guenther  <rguenther@suse.de>
5316
5317         * Makefile.in (OBJS): Remove matrix-reorg.o.
5318         (matrix-reorg.o): Remove dependence rule.
5319         (GTFILES): Remove matrix-reorg.c.
5320         * matrix-reorg.c: Remove.
5321         * passes.c (init_optimization_passes): Do not schedule
5322         pass_ipa_matrix_reorg.
5323         * tree-pass.h (pass_ipa_matrix_reorg): Remove.
5324         * common.opt (fipa-matrix-reorg): Stub out.
5325         * doc/invoke.texi (fipa-matrix-reorg): Remove documentation.
5326
5327 2012-08-10  Richard Guenther  <rguenther@suse.de>
5328
5329         PR middle-end/54219
5330         * fold-const.c (fold_ternary_loc): Do not reverse the mask
5331         when canonicalizing it when folding VEC_PERM_EXPR.
5332
5333 2012-08-10  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
5334
5335         PR middle-end/54211
5336         * gimple-ssa-strength-reduction.c (analyze_candidates_and_replace):
5337         Use cand_type to determine whether pointer arithmetic will be generated.
5338
5339 2012-08-10  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
5340
5341         * doc/sourcebuild.texi: Document long_neq_int effective target.
5342
5343 2012-08-10  Richard Guenther  <rguenther@suse.de>
5344
5345         PR tree-optimization/54109
5346         * tree-ssa-forwprop.c
5347         (forward_propagate_addr_into_variable_array_index): Remove.
5348         (forward_propagate_addr_expr_1): Adjust.
5349
5350 2012-08-10  Richard Guenther  <rguenther@suse.de>
5351
5352         * tree-cfg.c (dump_function_to_file): Make sure to dump
5353         anonymous SSA names when there are no local decls.
5354
5355 2012-08-10  Steven Bosscher  <steven@gcc.gnu.org>
5356
5357         * tree-ssa-pre.c (alloc_expression_id): Fix use of VEC_reserve.
5358         * tree-into-ssa.c (get_ssa_name_ann): Likewise.
5359         (mark_phi_for_rewrite): Likewise.
5360         (compute_global_livein): Use VEC_reserve outside the innermost
5361         loop and VEC_quick_push instead of VEC_safe_push in that loop.
5362         (update_ssa): Re-organize to avoid unnecessary sbitmap_zero'ing
5363         of new_ssa_names and old_ssa_names.  Allocate phis_to_rewrite to
5364         the correct initial size.
5365
5366 2012-08-10  Richard Guenther  <rguenther@suse.de>
5367
5368         * tree-ssa-pre.c (pretemp, storetemp, prephitemp): Remove.
5369         (need_creation): Remove.
5370         (get_representative_for): Use anonymous named SSA names.
5371         (create_expression_by_pieces): Likewise.
5372         (insert_into_preds_of_block): Likewise.
5373         (init_pre): Do not init removed vars.
5374         (fini_pre): Do not free need_creation.
5375         * tree-ssa-forwprop.c (simplify_bitwise_binary): Use anonymous
5376         SSA names.
5377         * tree-ssa-loop-manip.c (create_iv): Likewise.
5378         * value-prof.c (gimple_divmod_fixed_value): Likewise.
5379         (gimple_mod_pow2): Likewise.
5380         (gimple_mod_subtract): Likewise.
5381         (gimple_ic): Likewise.
5382         (gimple_stringop_fixed_value): Likewise.
5383         * tree-ssa-phiopt.c (condstoretemp): Remove.
5384         (tree_ssa_phiopt_worker): Use anonymous named SSA names.
5385         (conditional_replacement): Likewise.
5386         (abs_replacement): Likewise.
5387         (cond_store_replacement): Likewise.
5388         (cond_if_else_store_replacement_1): Likewise.
5389         * tree-ssa-loop-im.c (rewrite_reciprocal): Likewise.
5390         (rewrite_bittest): Likewise.
5391         * tree-ssa-reassoc.c (build_and_add_sum): Get type from callers
5392         and build anonymous SSA names.
5393         (undistribute_ops_list): Adjust.
5394         (eliminate_redundant_comparison): Use anonymous SSA names.
5395         (rewrite_expr_tree_parallel): Likewise.
5396         (get_reassoc_pow_ssa_name): Remove.
5397         (attempt_builtin_powi): Adjust.
5398         (reassociate_bb): Likewise.
5399         * tree-ssa-strlen.c (get_string_length): Use anonymous SSA names.
5400         * tree-switch-conversion.c (emit_case_bit_tests): Likewise.
5401         (build_arrays): Likewise.
5402         * tree-tailcall.c (adjust_return_value_with_ops): Likewise.
5403         (create_tailcall_accumulator): Likewise.
5404         * tree-vect-generic.c (expand_vector_divmod): Likewise.
5405         * tree-profile.c (gcov_type_tmp_var): Remove.
5406         (gimple_init_edge_profiler): Do not initialize it and use anonymous
5407         SSA names.
5408         (gimple_gen_ic_profiler): Likewise.
5409         (tree_profiling): Adjust.
5410         * tree-sra.c (build_ref_for_offset): Use anonymous SSA names.
5411         * tree-ssa-math-opts.c (execute_cse_sincos_1): Likewise.
5412         (powi_as_mults_1): Likewise.
5413         (powi_as_mults): Likewise.
5414         (build_and_insert_call): Adjust.
5415         (build_and_insert_binop): Likewise.
5416         (build_and_insert_ref): Likewise.
5417         (build_and_insert_cast): Likewise.
5418         (gimple_expand_builtin_pow): Likewise.
5419         (gimple_expand_builtin_cabs): Likewise.
5420         (execute_optimize_bswap): Use anonymous SSA names.
5421         (convert_mult_to_widen): Likewise.
5422         (convert_plusminus_to_widen): Likewise.
5423         * tree-ssa-phiprop.c (phiprop_insert_phi): Likewise.
5424         * tree-ssa-propagate.c (update_call_from_tree): Likewise.
5425         * tree-if-conv.c (ifc_temp_var): Likewise.
5426         * tree-loop-distribution.c (generate_memset_builtin): Likewise.
5427         * tree-parloops.c (take_address_of): Likewise.
5428         * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
5429         (vect_permute_load_chain): Likewise.
5430         * tree-vect-loop-manip.c (vect_create_cond_for_align_checks): Likewise.
5431         * tree-vect-patterns.c (vect_recog_temp_ssa_var): Likewise.
5432         (vect_handle_widen_op_by_const): Likewise.
5433         (vect_operation_fits_smaller_type): Likewise.
5434         (vect_recog_over_widening_pattern): Likewise.
5435         * tree-vect-stmts.c (vect_init_vector): Likewise.
5436         * tree-vrp.c (simplify_truth_ops_using_ranges): Likewise.
5437         (simplify_float_conversion_using_ranges): Likewise.
5438
5439 2012-08-10  Michael Zolotukhin  <michael.v.zolotukhin@intel.com>
5440
5441         * config/i386/i386.c (ix86_init_mmx_sse_builtins): Fix
5442         target mask of __builtin_ia32_rdseed_di_step builtin.
5443
5444 2012-08-10  Richard Guenther  <rguenther@suse.de>
5445
5446         PR tree-optimization/54027
5447         * tree-vrp.c (extract_range_from_binary_expr_1): Merge RSHIFT_EXPR
5448         and LSHIFT_EXPR handling, force -fwrapv for the multiplication used
5449         to handle LSHIFT_EXPR with a constant.
5450
5451 2012-08-10  Richard Guenther  <rguenther@suse.de>
5452
5453         * tree.h (SSA_NAME_VAR): Return NULL_TREE if an IDENTIFIER_NODE
5454         is recorded as var.
5455         (SSA_NAME_IDENTIFIER): Return the IDENTIFIER_NODE of the SSA_NAME
5456         or its SSA_NAME_VAR.
5457         (SET_SSA_NAME_VAR_OR_IDENTIFIER): New setter.
5458         * tree-ssanames.c (make_ssa_name_fn): Handle creating anonymous
5459         SSA names by passing a type instead of a variable decl.
5460         (release_ssa_name): Use SET_SSA_NAME_VAR_OR_IDENTIFIER.
5461         (copy_ssa_name_fn): Handle anonymous SSA names.
5462         (replace_ssa_name_symbol): Use SET_SSA_NAME_VAR_OR_IDENTIFIER.
5463         * tree-flow-inline.h (make_temp_ssa_name): New inline function.
5464         * tree-pretty-print.c (dump_generic_node): Use SSA_NAME_IDENTIFIER,
5465         dump SSA names without a name as <anon>.
5466         * cfgexpand.c (expand_used_vars): Assing anonymous SSA names we are
5467         going to expand a decl.
5468         (gimple_expand_cfg): Assign all SSA names of a partition the
5469         decl we created for its leader.
5470         * tree-ssa.c (target_for_debug_bind): Handle SSA_NAMEs.
5471         (verify_ssa_name): Handle anonymous SSA names.
5472         (verify_def): Likewise.
5473         * tree-predcom.c (eliminate_temp_copies): Likewise.
5474         * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Likewise.
5475         * tree-ssa-live.c (var_map_base_init): Compute conflicts for
5476         anonymous SSA names with the same type.
5477         (mark_all_vars_used_1): Handle anonymous SSA names.
5478         (verify_live_on_entry): Likewise.
5479         * tree-ssa-coalesce.c (abnormal_corrupt): Remove.
5480         (create_outofssa_var_map): Adjust with respect to conflicts we
5481         compute for anonymous SSA names.  Do not restrict abnormal
5482         coalescing.
5483         (coalesce_partitions): Do not restrict abnormal coalescing.
5484         Assert we only ever coalesce variables we computed conflicts for.
5485         * tree-ssa-ter.c (process_replaceable): Do not restrict TER
5486         of anonymous names.
5487         * expr.c (expand_expr_real_1): Handle anonymous SSA names
5488         expanded from IVOPTs by creating a raw REG here.
5489         * tree-cfg.c (replace_ssa_name): Handle anonymous SSA names.
5490         (dump_function_to_file): Dump anonymous SSA names alongside
5491         with their types in the variable list.
5492         (verify_gimple_return): Guard use of SSA_NAME_VAR.
5493         * tree-into-ssa.c (mark_for_renaming): Handle a NULL symbol.
5494         (rewrite_into_ssa): Make SSA names anonymous.
5495         * tree-ssa-structalias.c (alias_get_name): Rewrite.
5496         * tree-ssa-uninit.c (ssa_undefined_value_p): Handle anonymous
5497         SSA names.
5498         (warn_uninitialized_phi): Likewise.
5499         * tree-ssa-loop-ivopts.c (prepare_decl_rtl): Defer expanding
5500         anonymous SSA names to the expander.
5501         (determine_iv_cost): Anonymous SSA names are artificial.
5502         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop):
5503         Handle anonymous SSA names.
5504         * lto-streamer-out.c (output_ssa_names): Stream SSA_NAME_VAR
5505         or if NULL, the type of the SSA name.
5506         * tree-inline.c (remap_ssa_name): Handle anonymous SSA names,
5507         remap names as anonymous where appropriate.
5508         (insert_init_stmt): Pass SSA names down to insert_init_debug_bind.
5509         * tree-ssa-uncprop.c (uncprop_into_successor_phis): Adjust
5510         according to what we create conflicts for in out-of-SSA
5511         coalescing.
5512         * tree-parloops.c (separate_decls_in_region_name): Handle
5513         anonymous SSA names.
5514         (add_field_for_name): Likewise.
5515         * tree.c (get_name): Handle SSA names.
5516         * tree-ssa-loop-im.c (gen_lsm_tmp_name): Defer to get_name for
5517         SSA_NAMEs.
5518         * tree-vect-loop-manip.c (adjust_debug_stmts): Use
5519         virtual_operand_p.
5520         * tree-sra.c (create_access_replacement): Give up generating
5521         a DECL_DEBUG_EXPR for SSA names in the memory reference.
5522         (replace_removed_params_ssa_names): Guard use of SSA_NAME_VAR.
5523         * tree-complex.c (get_component_ssa_name): Handle anonymous
5524         SSA names.
5525         (set_component_ssa_name): Likewise.
5526         * tree-ssa-sccvn.c (visit_reference_op_load): Likewise.
5527         * tree-object-size.c (collect_object_sizes_for): Handle
5528         uninitialized SSA names properly.
5529         * ipa-inline-analysis.c (eliminated_by_inlining_prob): Guard use of
5530         SSA_NAME_VAR.
5531         * ipa-split.c (test_nonssa_use): Likewise.
5532         (consider_split): Likewise.
5533         (mark_nonssa_use): Likewise.
5534
5535 2012-08-09  Jan Hubicka  <jh@suse.cz>
5536
5537         PR middle-end/54146
5538         * ipa-inline-transform.c (inline_call): Add UPDATE_OVERALL_SUMMARY
5539         parameter; honnor it.
5540         * ipa-inline.c (recursive_inlining): Update call
5541         of inline_call.
5542         (inline_small_functions): Likewise.
5543         (ipa_inline): Likewise.
5544         (inline_always_inline_functions): Likewise.
5545         (early_inline_small_functions): Likewise.
5546         (flatten_function): Do separate update of summary info.
5547         * ipa-inline.h (inline_update_overall_summary): Declare.
5548         (inline_call): Update.
5549         * ipa-inline-analysis.c (inline_merge_summary): Break out
5550         updating code to ...
5551         (inline_update_overall_summary): Likewise.
5552
5553 2012-08-09  Richard Henderson  <rth@redhat.com>
5554
5555         * config/s390/s390.c (s390_expand_insv): Use VOIDmode in gen_rtx_SET.
5556
5557         * config/s390/s390.c (s390_expand_cs_hqi): Copy val to a temp before
5558         performing the compare for the restart loop.
5559
5560 2012-08-09  DJ Delorie  <dj@redhat.com>
5561
5562         * config/rl78/rl78.c (rl78_alloc_physical_registers): Check for
5563         SET before extracting SET_SRC.
5564         (rl78_remove_unused_sets): Check for REG before extractnig REGNO.
5565
5566 2012-08-09  Oleg Endo  <olegendo@gcc.gnu.org>
5567
5568         PR target/54089
5569         * config/sh/sh-protos (shift_insns_rtx): Delete.
5570         (sh_ashlsi_clobbers_t_reg_p): Add.
5571         * config/sh/sh.c (shift_insns, shift_amounts, ext_shift_insns,
5572         ext_shift_amounts): Merge arrays of ints to array of structs.
5573         Adapt usage of arrays throughout the file.
5574         (shift_insns_rtx): Delete unused function.
5575         (sh_ashlsi_clobbers_t_reg_p): New function.
5576         * config/sh/sh.md (ashlsi3): Emit ashlsi3_n_clobbers_t insn if the
5577         final shift sequence will clobber T_REG.
5578         (ashlsi3_n): Split only if the final shift sequence will not
5579         clobber T_REG.
5580         (ashlsi3_n_clobbers_t): New insn_and_split.
5581
5582 2012-08-09  Steven Bosscher  <steven@gcc.gnu.org>
5583
5584         * calls.c (mem_overlaps_already_clobbered_arg_p): Use SBITMAP_SIZE
5585         instead of looking at sbitmap n_bits member directly.
5586         * gcse.c (hoist_code): Likewise.
5587         * sched-rgn.c (split_edges): Likewise.
5588         * tree-into-ssa.c (is_old_name, is_new_name, add_new_name_mapping,
5589         update_ssa): Likewise.
5590
5591 2012-08-09  Uros Bizjak  <ubizjak@gmail.com>
5592
5593         * config/i386/i386.h (LIMIT_RELOAD_CLASS): Return preferred
5594         single unit register class for classes that contain registers form
5595         multiple units.
5596         (REG_CLASS_CONTENTS): Add missing "frame" register to FLOAT_INT_REGS,
5597         INT_SSE_REGS and FLOAT_INT_SSE_REGS register classes.
5598
5599 2012-08-09  Martin Jambor  <mjambor@suse.cz>
5600
5601         * cgraph.h (cgraph_indirect_call_info): Field anc_offse renamd to
5602         offset, updated all users.  New field agg_contents.
5603         * ipa-prop.h (jump_func_type): Removed IPA_JF_CONST_MEMBER_PTR.
5604         (ipa_pass_through_data): New field agg_preserved.
5605         (ipa_ancestor_jf_data): Likewise.
5606         (ipa_member_ptr_cst): Removed.
5607         (ipa_agg_jf_item): New type.
5608         (ipa_agg_jump_function): Likewise.
5609         (ipa_jump_func): New field agg.  Removed field member_cst.
5610         (ipa_get_jf_pass_through_agg_preserved): New function.
5611         (ipa_get_jf_ancestor_agg_preserved): Likewise.
5612         (ipa_get_jf_member_ptr_pfn): Removed.
5613         (ipa_find_agg_cst_for_param): Declare.
5614         (ipa_load_from_parm_agg): Likewise.
5615         * ipa-prop.c (param_analysis_info): Fields modified and
5616         visited_statements rename to parm_modified and parm_visited_statements
5617         respectively, added fields ref_modified, ref_visited_statements,
5618         pt_modified and pt_visited_statements.
5619         (ipa_print_node_jump_functions_for_edge): Do not dump const member
5620         functions.  Dump agg_preserved flags and aggregate jump functions.
5621         (ipa_set_jf_simple_pass_through): Set also agg_preserved.
5622         (ipa_set_ancestor_jf): Likewise.
5623         (ipa_set_jf_arith_pass_through): Clear agg_preserved.
5624         (ipa_set_jf_member_ptr_cst): Removed.
5625         (is_parm_modified_before_stmt): Logic reversed, renamed to
5626         parm_preserved_before_stmt_p.  Cache visited bitmap only for
5627         naked DECL parameters.  All callers updated.
5628         (load_from_unmodified_param): Allow NULL parms_ainfo.
5629         (parm_ref_data_preserved_p): New function.
5630         (parm_ref_data_pass_through_p): Likewise.
5631         (ipa_load_from_parm_agg_1): Likewise.
5632         (ipa_load_from_parm_agg): Likewise.
5633         (compute_complex_assign_jump_func): Check if aggregate contents are
5634         preserved.
5635         (compute_complex_ancestor_jump_func): Likewise.
5636         (compute_scalar_jump_functions): Removed.
5637         (type_like_member_ptr_p): Also check field position are known and sane.
5638         (compute_pass_through_member_ptrs): Removed.
5639         (determine_cst_member_ptr): Likewise.
5640         (ipa_known_agg_contents_list): New type.
5641         (determine_known_aggregate_parts): New function.
5642         (compute_cst_member_ptr_arguments): Removed.
5643         (ipa_compute_jump_functions_for_edge): Compute all kinds of jump
5644         functions (scalar, aggregate and member pointer).
5645         (ipa_get_member_ptr_load_param): Incorporate into
5646         ipa_get_stmt_member_ptr_load_param, also pass back an offset.
5647         (ipa_note_param_call): Clear agg_contents.
5648         (ipa_analyze_indirect_call_uses): Also look for simple pointers loaded
5649         from aggregates.  In such cases, store offset of the called field.
5650         (ipa_analyze_node): Initialize new fields of param_analysis_info.
5651         (update_jump_functions_after_inlining): Handle aggregate contents.
5652         (ipa_find_agg_cst_for_param): New function.
5653         (try_make_edge_direct_simple_call): Handle called aggregate values.
5654         (update_indirect_edges_after_inlining): Make sure aggregate preserving
5655         jump functions comply with type compatibility requirements.
5656         (ipa_edge_duplication_hook): Copy also aggregate jump functions.
5657         (ipa_write_jump_function): Stream agg_preserved flags and aggregate
5658         jump functions.  Do not stream member pointer constant jump functions.
5659         (ipa_read_jump_function): Likewise.
5660         (ipa_write_indirect_edge_info): Stream new cgraph_indirect_call_info
5661         fields.
5662         (ipa_read_indirect_edge_info): Likewise.
5663
5664 2012-08-09  Oleg Endo  <olegendo@gcc.gnu.org>
5665
5666         PR target/39423
5667         * config/sh/predicates.md (mem_index_disp_operand): New predicate.
5668         * config/sh/sh.md (*movsi_index_disp): Rewrite insns to use the new
5669         mem_index_disp_operand predicate.
5670
5671 2012-08-09  Oleg Endo  <olegendo@gcc.gnu.org>
5672
5673         PR target/51244
5674         * config/sh/sh.md: Add negc extu sequence peephole.
5675         (movrt, movnegt, movrt_negc, nott): Use t_reg_operand predicate.
5676         (*movrt_negc): New insn.
5677         * config/sh/sync.md (atomic_test_and_set): Pass gen_t_reg_rtx to
5678         gen_movnegt.
5679         * config/sh/sh.c (expand_cbranchsi4, sh_emit_scc_to_t,
5680         sh_emit_compare_and_branch, sh_emit_compare_and_set): Use
5681         get_t_reg_rtx.
5682         (sh_expand_t_scc): Pass gen_t_reg_rtx to gen_movnegt.
5683
5684 2012-08-09  Oleg Endo  <olegendo@gcc.gnu.org>
5685
5686         PR target/50751
5687         * config/sh/sh.md (*extendqisi2_compact_reg, *extendhisi2_compact_reg):
5688         Use arith_reg_operand predicate instead of register_operand.
5689         * config/sh/predicates.md (movsrc_no_disp_mem_operand): Accept
5690         only mem, simplify.
5691
5692 2012-08-09  Uros Bizjak  <ubizjak@gmail.com>
5693
5694         * config/alpha/alpha.c (alpha_pad_noreturn): Rename to ...
5695         (alpha_pad_function_end): ... this.  Also insert NOP between
5696         sibling call and GP load.
5697         (alpha_reorg): Update call to alpha_pad_function_end.  Expand comment.
5698
5699 2012-08-09  Michael Zolotukhin  <michael.v.zolotukhin@intel.com>
5700
5701         * config/i386/adxintrin.h: Remove guarding __ADX__ check.
5702         * config/i386/x86intrin.h: Likewise.
5703         * config/i386/i386.c (ix86_init_mmx_sse_builtins): Remove
5704         OPTION_MASK_ISA_ADX from needed options for
5705         __builtin_ia32_addcarryx_u32 and __builtin_ia32_addcarryx_u64.
5706         (ix86_expand_builtin): Use add<mode>3_carry in expanding of
5707         IX86_BUILTIN_ADDCARRYX32 and IX86_BUILTIN_ADDCARRYX64.
5708
5709 2012-08-09  Andrey Belevantsev  <abel@ispras.ru>
5710
5711         PR rtl-optimization/53701
5712         * sel-sched.c (vinsn_vec_has_expr_p): Clarify function comment.
5713         Process not only expr's vinsns but all old vinsns from expr's
5714         history of changes.
5715         (update_and_record_unavailable_insns): Clarify comment.
5716
5717 2012-08-09  Bernd Schmidt  <bernds@codesourcery.com>
5718
5719         * reload.c (find_valid_class_1): New static function.
5720         (push_reload): Use it when reloading a SYMBOL_REG as the inner
5721         of a subreg.  Keep better track of needed classes for the
5722         secondary memory case.
5723         * config/i386/i386.h (LIMIT_RELOAD_CLASS): Limit INT_SSE_REGS to
5724         GENERAL_REGS.
5725         * reload1.c (replaced_subreg): New static function.
5726         (gen_reload): Use it when deciding whether to use secondary
5727         memory.
5728
5729 2012-08-09  Richard Guenther  <rguenther@suse.de>
5730
5731         * tree.h (SSA_VAR_P): Simplify.
5732         * tree-ssanames.c (make_ssa_name_fn): Strengthen assert.
5733         * fold-const.c (fold_comparison): Check for default def first
5734         before checking for PARM_DECL.
5735         * tree-complex.c (get_component_ssa_name): Likewise.
5736         * tree-inline.c (remap_ssa_name): Likewise.
5737         * tree-ssa-loop-ivopts.c (parm_decl_cost): Likewise.
5738         * tree-ssa-structalias.c (get_fi_for_callee): Likewise.
5739         (find_what_p_points_to): Likewise.
5740         * tree-ssa-operands.c (add_stmt_operand): Simplify.
5741
5742 2012-08-08  Joseph Myers  <joseph@codesourcery.com>
5743
5744         * simplify-rtx.c (simplify_binary_operation_1): Do not simplify
5745         IOR to a constant if one operand has side effects.
5746
5747 2012-08-08  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
5748
5749         * builtins.c (expand_builtin_atomic_compare_exchange): Pass old
5750         value operand as MEM to expand_atomic_compare_and_swap.
5751
5752         * config/s390/s390.md ("atomic_compare_and_swap<mode>"): Accept
5753         nonimmediate_operand for old value; generate load and store if
5754         needed.
5755         * config/s390/s390.c (s390_expand_cs_hqi): Accept any operand
5756         as vtarget.
5757
5758 2012-08-08  Steven Bosscher  <steven@gcc.gnu.org>
5759
5760         PR middle-end/54146
5761         * gimpify.c (gimplify_body): Only verify_gimple_in_seq with
5762         checking enabled.
5763         * tree-ssa-loop-manip.c (add_exit_phis_var): Assert that var is
5764         a gimple_reg if checking is enabled.
5765         (find_uses_to_rename_stmt): Only look at non-virtual USE operands.
5766         * tree-into-ssa (compute_global_livein): Change the worklist
5767         type from an array to a VEC.
5768
5769 2012-08-08  Richard Guenther  <rguenther@suse.de>
5770
5771         * tree-ssa-operands.h (virtual_operand_p): Declare.
5772         * tree-ssa-operands.c (virtual_operand_p): New predicate.
5773         * gimple.c (is_gimple_reg): Use virtual_operand_p.
5774         * tree-into-ssa.c (prepare_block_for_update): Likewise.
5775         * tree-vect-loop-manip.c (adjust_debug_stmts): Likewise.
5776
5777 2012-08-08  Richard Guenther  <rguenther@suse.de>
5778
5779         * tree-call-cdce.c (check_pow): Simplify.
5780         (gen_conditions_for_pow_int_base): Likewise.
5781         * tree-ssa-dom.c (propagate_rhs_into_lhs): Do not handle
5782         virtual operands here.
5783         * tree-ssa-operands.c (get_name_decl): Remove unused function.
5784         * gimplify.c (gimple_regimplify_operands): Remove dead code.
5785         * tree-vrp.c (get_value_range): Move SSA_NAME_VAR access.
5786         * tree-parloops.c (create_phi_for_local_result): Use copy_ssa_name.
5787         * value-prof.c (gimple_ic): Use duplicate_ssa_name.
5788         (gimple_stringop_fixed_value): Likewise.
5789         * tree.c (needs_to_live_in_memory): Remove SSA name handling.
5790         * tree-stdarg.c (find_va_list_reference): Store SSA_NAME_VERSIONs
5791         in the bitmap alongside shifted DECL_UIDs.
5792         (va_list_counter_struct_op): Likewise.
5793         (va_list_ptr_read): Likewise.
5794         (va_list_ptr_write): Likewise.
5795         (check_va_list_escapes): Likewise.
5796         (check_all_va_list_escapes): Likewise.
5797         (execute_optimize_stdarg): Likewise.
5798         * tree-outof-ssa.c (insert_backedge_copies): Use copy_ssa_name.
5799
5800 2012-08-08  Richard Sandiford  <rdsandiford@googlemail.com>
5801             H.J. Lu  <hongjiu.lu@intel.com>
5802
5803         PR rtl-optimization/54157
5804         * combine.c (gen_lowpart_for_combine): Don't return identity
5805         for CONST or symbolic reference.
5806
5807 2012-08-08  Michael Zolotukhin  <michael.v.zolotukhin@intel.com>
5808
5809         * common/config/i386/i386-common.c (OPTION_MASK_ISA_ADX_SET): New.
5810         (OPTION_MASK_ISA_ADX_UNSET): Likewise.
5811         (ix86_handle_option): Handle madx option.
5812         * config.gcc (i[34567]86-*-*): Add adxintrin.h.
5813         (x86_64-*-*): Likewise.
5814         * config/i386/adxintrin.h: New header.
5815         * config/i386/driver-i386.c (host_detect_local_cpu): Detect ADCX/ADOX
5816         support.
5817         * config/i386/i386-builtin-types.def
5818         (UCHAR_FTYPE_UCHAR_UINT_UINT_PUNSIGNED): New function type.
5819         (UCHAR_FTYPE_UCHAR_ULONGLONG_ULONGLONG_PULONGLONG): Likewise.
5820         * config/i386/i386-c.c: Define __ADX__ if needed.
5821         * config/i386/i386.c (ix86_target_string): Define -madx option.
5822         (PTA_ADX): New.
5823         (ix86_option_override_internal): Handle new option.
5824         (ix86_valid_target_attribute_inner_p): Add OPT_madx.
5825         (ix86_builtins): Add IX86_BUILTIN_ADDCARRYX32,
5826         IX86_BUILTIN_ADDCARRYX64.
5827         (ix86_init_mmx_sse_builtins): Define corresponding built-ins.
5828         (ix86_expand_builtin): Handle these built-ins.
5829         (ix86_expand_args_builtin): Handle new function types.
5830         * config/i386/i386.h (TARGET_ADX): New.
5831         * config/i386/i386.md (adcx<mode>3): New define_insn.
5832         * config/i386/i386.opt (madx): New.
5833         * config/i386/x86intrin.h: Include adxintrin.h.
5834
5835 2012-08-08  Nick Clifton  <nickc@redhat.com>
5836
5837         * config/rl78/rl78.c: Include tree-pass.h.
5838
5839 2012-08-08  Steven Bosscher  <steven@gcc.gnu.org>
5840
5841         PR middle-end/54146
5842         * ira.c (init_live_subregs): Take live_subregs_used as a bitmap.
5843         (build_insn_chain): Make live_subregs_used a bitmap.
5844         Use SBITMAP_SIZE to ignore the paradoxical bytes of subregs.
5845         Use sbitmap_free to free the live_subreg sbitmaps.
5846
5847         PR middle-end/54146
5848         * ifcvt.c: Include pointer-set.h.
5849         (cond_move_process_if_block): Change type of then_regs and
5850         else_regs from alloca'd array to pointer_sets.
5851         (check_cond_move_block): Update for this change.
5852         (cond_move_convert_if_block): Likewise.
5853         * Makefile.in: Fix dependencies for ifcvt.o.
5854
5855 2012-08-07  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
5856
5857         * gimple-ssa-strength-reduction.c (struct incr_info_d): New struct.
5858         (incr_vec): New static var.
5859         (incr_vec_len): Likewise.
5860         (address_arithmetic_p): Likewise.
5861         (stmt_cost): Remove dead assignment.
5862         (dump_incr_vec): New function.
5863         (cand_abs_increment): Likewise.
5864         (lazy_create_slsr_reg): Likewise.
5865         (incr_vec_index): Likewise.
5866         (count_candidates): Likewise.
5867         (record_increment): Likewise.
5868         (record_increments): Likewise.
5869         (unreplaced_cand_in_tree): Likewise.
5870         (optimize_cands_for_speed_p): Likewise.
5871         (lowest_cost_path): Likewise.
5872         (total_savings): Likewise.
5873         (analyze_increments): Likewise.
5874         (ncd_for_two_cands): Likewise.
5875         (nearest_common_dominator_for_cands): Likewise.
5876         (profitable_increment_p): Likewise.
5877         (insert_initializers): Likewise.
5878         (introduce_cast_before_cand): Likewise.
5879         (replace_rhs_if_not_dup): Likewise.
5880         (replace_one_candidate): Likewise.
5881         (replace_profitable_candidates): Likewise.
5882         (analyze_candidates_and_replace): Handle candidates with SSA-name
5883         strides.
5884
5885 2012-08-07  Steven Bosscher  <steven@gcc.gnu.org>
5886
5887         * cfg.c (debug_bb): Do not set TDF_BLOCKS.
5888         * cfghooks.c (dump_bb): Honor ~TDF_BLOCKS.
5889         * pretty-print.c (pp_base_flush): Do not add a newline, and do not
5890         clear pp_needs_newline.
5891         * pretty-print.h (pp_newline_and_flush): New macro with the behavior
5892         of pp_base_flush before the above change.
5893         * langhooks.c (lhd_print_error_function): Use pp_newline_and_flush
5894         instead of pp_flush.
5895         * diagnostic.c (diagnostic_finish): Likewise.
5896         (diagnostic_report_diagnostic): Likewise.
5897         (verbatim): Likewise.
5898         (error_recursion): Likewise.
5899         * tree-pretty-print.c (print_generic_stmt): Likewise.
5900         (print_generic_stmt_indented): LIkewise.
5901         * gimple-pretty-print.c (print_gimple_stmt): Likewise.
5902         (print_gimple_seq): Likewise.
5903         (gimple_dump_bb_buff): Likewise.
5904
5905 2012-08-07  Uros Bizjak  <ubizjak@gmail.com>
5906
5907         PR debug/54177
5908         * var-tracking.c (var_lowpart): Exit early for matched modes.
5909
5910 2012-08-07  Richard Henderson  <rth@redhat.com>
5911
5912         * config/s390/s390.c (s390_emit_compare_and_swap): Update for
5913         atomic_compare_and_swapsi_internal name change.
5914         (s390_expand_insv): Try RISBG last, not requiring operands in
5915         registers but forcing them there.  Try a limited form of ICM.
5916         (s390_two_part_insv): New.
5917         (s390_expand_cs_hqi): Use it.  Update for atomic optabs.
5918         * config/s390/s390.md (UNSPEC_MOVA): New.
5919         (TDSI): Remove mode iterator.
5920         (DGPR, DINT, TDI): New mode iterators.
5921         (td): New mode attribute.
5922         (mem_signal_fence): New.
5923         (mem_thread_fence): Rename from memory_barrier; update for model arg.
5924         (mem_thread_fence_1): Rename from *memory_barrier.
5925         (atomic_load<DINT>, atomic_store<DINT>): New expanders.
5926         (atomic_loaddi_1, atomic_loadti_1): New.
5927         (atomic_storedi_1, atomic_storeti_1): New.
5928         (sync_compare_and_swap<TDSI>, sync_compare_and_swap<HQI>): Remove.
5929         (atomic_compare_and_swap<DGPR>, atomic_compare_and_swap<HQI>): New.
5930         (atomic_compare_and_swap<DGPR>_internal): New.
5931         (*sync_compare_and_swap<DW>, *sync_compare_and_swap<GPR>): Remove.
5932         (*atomic_compare_and_swap<TDI>_1): New.
5933         (*atomic_compare_and_swapdi_2, *atomic_compare_and_swapsi_3): New.
5934         (sync_<ATOMIC_Z196><GPR>, sync_old_<ATOMIC_Z196><GPR>): Remove.
5935         (atomic_fetch_<ATOMIC_Z196><GPR>): New.
5936         (atomic_fetch_<ATOMC_Z196><GPR>_iaf): New.
5937         (sync_<ATOMIC><HQI>, sync_old_<ATOMIC><HQI>): Remove.
5938         (sync_new_<ATOMIC><HQI>): Remove.
5939         (atomic_<ATOMIC><HQI>, atomic_fetch_<ATOMIC><HQI>): New.
5940         (atomic_<ATOMIC>_fetch<HQI>): New.
5941         (sync_lock_test_and_set<HQI>): Remove.
5942         (atomic_exchange<HQI>): New.
5943
5944 2012-08-07  Paul Brook  <paul@codesourcery.com>
5945             Sandra Loosemore  <sandra@codesourcery.com>
5946
5947         * except.c (switch_to_exception_section): Place tables for
5948         DECL_ONE_ONLY functions in comdat groups.
5949
5950 2012-08-07  Richard Guenther  <rguenther@suse.de>
5951
5952         * tree-flow.h (copy_ssa_name_fn): New function.
5953         (duplicate_ssa_name_fn): Likewise.
5954         * tree-flow-inline.h (copy_ssa_name): New function.
5955         (duplicate_ssa_name): Likewise.
5956         * tree-ssanames.c (copy_ssa_name_fn): New function.
5957         (duplicate_ssa_name): Rename to ...
5958         (duplicate_ssa_name_fn): ... this and adjust.
5959         * tree-tailcall.c (update_accumulator_with_ops): Use copy_ssa_name.
5960         * tree-vect-loop-manip.c (slpeel_update_phi_nodes_for_guard1):
5961         Likewise.
5962         (slpeel_update_phi_nodes_for_guard2): Likewise.
5963         (slpeel_tree_peel_loop_to_edge): Likewise.
5964         (vect_loop_versioning): Likewise.
5965         * tree-parloops.c (transform_to_exit_first_loop): Likewise.
5966         (create_parallel_loop): Likewise.
5967         * ipa-split.c (split_function): Likewise.
5968         * tree-vect-loop.c (vect_is_simple_reduction_1): Likewise.
5969         (vect_create_epilog_for_reduction): Likewise.
5970         * tree-vect-data-refs.c (bump_vector_ptr): Likewise.
5971         (vect_setup_realignment): Likewise.
5972         * tree-vect-stmts.c (vectorizable_load): Likewise.
5973         * tree-switch-conversion.c (build_one_array): Likewise.
5974         (gen_def_assigns): Likewise.
5975         * tree-cfg.c (gimple_make_forwarder_block): Likewise.
5976         * graphite-sese-to-poly.c (rewrite_close_phi_out_of_ssa): Call
5977         create_zero_dim_array with the SSA name.
5978         (rewrite_phi_out_of_ssa): Likewise.
5979         (rewrite_cross_bb_scalar_dependence): Likewise.  Use copy_ssa_name.
5980
5981 2012-08-07  Richard Guenther  <rguenther@suse.de>
5982
5983         * tree-dfa.c (set_ssa_default_def): Clear the SSA_NAME_DEFAULT_DEF
5984         bit of the old name when we clear the slot.
5985         * tree-ssa-live.c (remove_unused_locals): Release any default
5986         def associated with an unused var.
5987         * tree-ssa-copy.c (may_propagate_copy_into_asm): Always return true.
5988
5989 2012-08-07  Richard Guenther  <rguenther@suse.de>
5990
5991         * tree-into-ssa.c (rewrite_stmt): Remove clobbers for variables
5992         we rewrite into SSA form.
5993         (rewrite_enter_block): Adjust.
5994         * gimple-iterator.c (gsi_replace): Also allow replacement with
5995         a stmt without a lhs.
5996         * tree-ssa-live.c (remove_unused_locals): Remove code handling
5997         clobbers of SSA names.
5998         * tree-nested.c (convert_local_reference_stmt): Remove clobbers
5999         for variables we access through the local chain.
6000         * tree-cfg.c (verify_gimple_assign_single): Verify clobbers
6001         clobber full decls only.
6002
6003 2012-08-07  Richard Guenther  <rguenther@suse.de>
6004
6005         * gimple.h (gimple_phi_set_result): Adjust SSA_NAME_DEF_STMT.
6006         * tree-phinodes.c (make_phi_node): Allow a NULL var.
6007         * tree-into-ssa.c (insert_phi_nodes_for): Simplify.
6008         * tree-complex.c (update_phi_components): Likewise.
6009         * tree-ssa-loop-manip.c (create_iv): Likewise.
6010         (add_exit_phis_edge): Likewise.
6011         (split_loop_exit_edge): Likewise.
6012         (tree_transform_and_unroll_loop): Likewise.
6013         * value-prof.c (gimple_ic): Likewise.
6014         (gimple_stringop_fixed_value): Likewise.
6015         * tree-tailcall.c (tree_optimize_tail_calls_1): Likewise.
6016         * omp-low.c (expand_parallel_call): Likewise.
6017         (expand_omp_for_static_chunk): Likewise.
6018         (expand_omp_atomic_pipeline): Likewise.
6019         * tree-parloops.c (create_phi_for_local_result): Likewise.
6020         (transform_to_exit_first_loop): Likewise.
6021         * tree-vect-data-refs.c (vect_setup_realignment): Likewise.
6022         * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Likewise.
6023         * tree-predcom.c (initialize_root_vars): Likewise.
6024         (initialize_root_vars_lm): Likewise.
6025         * sese.c (sese_add_exit_phis_edge): Likewise.
6026         * gimple-streamer-in.c (input_phi): Likewise.
6027         * tree-inline.c (copy_phis_for_bb): Likewise.
6028         * tree-ssa-phiprop.c (phiprop_insert_phi): Likewise.
6029         * tree-cfg.c (gimple_make_forwarder_block): Likewise.
6030         (gimple_duplicate_bb): Likewise.
6031
6032 2012-08-07  Nick Clifton  <nickc@redhat.com>
6033
6034         * config/mn10300/mn10300.c (mn10300_expand_prologue): Report
6035         stack usage if requested.
6036
6037 2012-08-06  Cary Coutant  <ccoutant@google.com>
6038
6039         * cgraphunit.c (assemble_thunk): Add source line info.
6040         * final.c (final): Check for non-null cfg pointer.
6041
6042 2012-08-06  Sandra Loosemore  <sandra@codesourcery.com>
6043             Maxim Kuvyrkov  <maxim@codesourcery.com>
6044             Julian Brown  <julian@codesourcery.com>
6045
6046         * config/mips/24k.md (r24k_unknown_store): Delete special handling
6047         for cprestore.
6048         (r24k_int_load, r24k_int_arith, r24k_int_mul3, r24k_int_mfhilo)
6049         (r24k_int_cop, r24k_int_multi)
6050         (r24kf2_1_fcvt_f2i, r24kf2_1_fxfer)
6051         (r24kf1_1_fcvt_f2i, r24kf1_1_fxfer): Use mips_store_data_bypass_p
6052         instead of store_data_bypass_p.
6053         * config/mips/74k.md (r74k_int_store): Delete special handling for
6054         cprestore.
6055         (r74k_int_load, r74k_int_logical, r74k_int_arith, r74k_int_cmove):
6056         Use mips_store_data_bypass_p instead of store_data_bypass_p.
6057
6058 2012-08-06  Marc Glisse  <marc.glisse@inria.fr>
6059
6060         PR tree-optimization/51938
6061         PR tree-optimization/52005
6062         * tree-ssa-ifcombine.c (ifcombine_ifandif): New parameters for
6063         inverted conditions.
6064         (ifcombine_iforif): Remove, merge code into ifcombine_ifandif.
6065         (tree_ssa_ifcombine_bb): Update calls to the above. Detect !a&&b
6066         and !a||b patterns.
6067
6068 2012-08-06  Olivier Hainque  <hainque@adacore.com>
6069
6070         * tree-emutls.c (new_emutls_decl): When a var_section is requested by
6071         the target, attach the new decl to that, not to the template section.
6072
6073 2012-08-06  Tom de Vries  <tom@codesourcery.com>
6074
6075         * tree-switch-conversion.c (emit_case_bit_tests): Generate MINUS_EXPR in
6076         unsigned type.
6077
6078 2012-08-05  Venkataramanan Kumar  <venkataramanan.kumar@amd.com>
6079
6080         * doc/invoke.texi: Document AMD btver2.
6081         * doc/extend.texi: Document AMD btver1 and btver2.
6082
6083 2012-08-04  Sandra Loosemore  <sandra@codesourcery.com>
6084             Richard Sandiford  <rdsandiford@googlemail.com>
6085
6086         * config/mips/mips.c (mips_option_override): Check -fpic
6087         for compatibility with -mabicalls and ABI.
6088
6089 2012-08-04  Catherine Moore  <clm@codesourcery.com>
6090             Sandra Loosemore  <sandra@codesourcery.com>
6091
6092         * config/mips/xlr.md (ir_xlr_alu_clz): New insn_reservation.
6093         (ir_xlr_alu): Remove clz.
6094         * config/mips/mips-cpus.def (xlr): Set PTF_AVOID_BRANCHLIKELY.
6095
6096 2012-08-04  Richard Earnshaw  <rearnsha@arm.com>
6097
6098         * arm.c (arm_gen_constant): Use SImode when preparing operands for
6099         gen_extzv_t2.
6100
6101 2012-08-04  Uros Bizjak  <ubizjak@gmail.com>
6102
6103         * config/i386/i386.h (QI_REGNO_P): New define.
6104         (ANY_QI_REGNO_P): Ditto.
6105         (GENERAL_REGNO_P): Use IN_RANGE macro.
6106         (QI_REG_P): Use QI_REGNO_P.
6107         (ANY_QI_REG_P): Use GENERAL_REGNO_P and QI_REGNO_P.
6108         (HARD_REGNO_CALLER_SAVE_MODE): Use QI_REGNO_P.
6109         * config/i386/i386.c (ix86_hard_regno_mode_ok): Ditto.
6110         (x86_extended_QIreg_mentioned_p): Ditto.  Also check if
6111         register is a general register.
6112
6113 2012-08-03  Uros Bizjak  <ubizjak@gmail.com>
6114
6115         * config/i386/sync.md (*atomic_fetch_add_cmp<mode>): Use
6116         incdec_operand predicate to return INC or DEC insn mnemonic.
6117         Add %K operand modifier.
6118         (atomic_add<mode>): Use incdec_operand predicate to
6119         return INC or DEC insn mnemonic.
6120         (atomic_dec<mode>): Ditto.
6121
6122 2012-08-03  Michael Matz  <matz@suse.de>
6123
6124         PR tree-optimization/54146
6125         * cfgexpand.c (add_scope_conflicts_1): Use bitmap_ior_into.
6126         (add_scope_conflicts): Iterate in RPO order.
6127         (add_stack_protection_conflicts): Iterate over the other triangle.
6128         (fini_vars_expansion): Clear stack_vars_sorted.
6129
6130 2012-08-03  Marc Glisse  <marc.glisse@inria.fr>
6131
6132         PR tree-optimization/30318
6133         * double-int.c (mul_double_wide_with_sign): New function.
6134         (mul_double_with_sign): Call the new function.
6135         * double-int.h (mul_double_wide_with_sign): Declare the new function.
6136         * tree-vrp.c (extract_range_from_binary_expr_1) [MULT_EXPR]:
6137         Handle integer types that wrap on overflow.
6138         (quad_int_cmp): New helper function.
6139         (quad_int_pair_sort): Likewise.
6140
6141 2012-08-03  Richard Guenther  <rguenther@suse.de>
6142
6143         * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Query
6144         is_gimple_reg on the SSA name, not its variable.
6145         (vect_update_ivs_after_vectorizer): Likewise.
6146         * tree-ssa-copyrename.c (rename_ssa_copies): Likewise.
6147         * tree-if-conv.c (if_convertible_phi_p): Likewise.
6148         (predicate_scalar_phi): Likewise.
6149         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Likewise.
6150         (vect_analyze_scalar_cycles_1): Likewise.
6151         * tree-ssa-live.c (register_ssa_partition_check): Likewise.
6152         * tree-outof-ssa.c (eliminate_useless_phis): Likewise.
6153         * tree-ssa-reassoc.c (phi_rank): Likewise.
6154         * tree-parloops.c (separate_decls_in_region_name): Use
6155         replace_ssa_name_symbol.
6156         * tree-predcom.c (base_names_in_chain_on): Likewise.
6157         * matrix-reorg.c (update_type_size): Query the type of the SSA name,
6158         not its variable.
6159         * gimple-ssa-strength-reduction.c (create_mul_ssa_cand): Likewise.
6160         (create_mul_imm_cand): Likewise.
6161         (create_add_ssa_cand): Likewise.
6162         (create_add_imm_cand): Likewise.
6163         (slsr_process_add): Likewise.
6164         * tree-inline.c (remap_ssa_name): Do not set the type of the
6165         new SSA_NAME.
6166         * tree-ssa-structalias.c (get_constraint_for_ssa_var): Clarify assert.
6167         Check for default def first.
6168
6169 2012-08-04  Steven Bosscher  <steven@gcc.gnu.org>
6170
6171         * cfgrtl.c (print_rtl_with_bb): Do not print a newline between insns.
6172
6173         * sched-vis.c (print_pattern): Handle SEQUENCE also.
6174
6175 2012-08-02  Richard Henderson  <rth@redhat.com>
6176
6177         Revert:
6178         PR 34548
6179         * function.h (struct rtl_data): Add max_dynamic_stack_alignment.
6180         * cfgexpand.c (gimple_expand_cfg): Initialise it.
6181         * explow.c (allocate_dynamic_stack_space): Set it.  Simplify
6182         alignment requirements given the known alignment of dynamic_offset.
6183         * function.c (instantiate_virtual_regs): Align dtnamic_offset.
6184
6185 2012-08-02  Kenneth Zadeck <zadeck@naturalbridge.com>
6186
6187         * cfgexpand.c (expand_debug_locations):  Encapsulate test for
6188         CONST_DOUBLE in macro.
6189         * combine.c (try_combine, gen_lowpart_for_combine): Ditto.
6190         * cprop.c (implicit_set_cond_p): Ditto.
6191         * cselib.c (rtx_equal_for_cselib_1): Ditto.
6192         * expmed.c (expand_mult): Ditto.
6193         * expr.c (convert_modes): Ditto.
6194         * ira-costs.c (record_reg_classes): Ditto.
6195         * ira-lives.c (single_reg_class): Ditto.
6196         * optabs.c (expand_copysign_absneg, expand_copysign): Ditto.
6197         * print-rtl.c (print_rtx): Ditto.
6198         * recog.c (simplify_while_replacing, const_double_operand)
6199         (asm_operand_ok, constrain_operands): Ditto.
6200         * reg-stack.c (subst_stack_regs_pat): Ditto.
6201         * reload.c (find_reloads, find_equiv_reg): Ditto.
6202         * rtlanal.c (replace_rtx): Remove test.
6203         * rtlanal.c (constant_pool_constant_p, split_double): Encapsulate
6204         test for CONST_DOUBLE in macro.
6205         * simplify-rtx.c (mode_signbit_p, avoid_constant_pool_reference)
6206         (simplify_unary_operation_1, simplify_const_unary_operation)
6207         (simplify_binary_operation_1, simplify_const_binary_operation)
6208         (simplify_relational_operation_1)
6209         (simplify_const_relational_operations)
6210         (implify_subreg): Ditto.
6211         * varasm.c (output_constant_pool_2): Ditto.
6212         * rtl.h (CONST_DOUBLE_AS_INT_P, CONST_DOUBLE_AS_FLOAT_P): New macros.
6213         * rtl.def (CONST_DOUBLE):  Updated comments.
6214
6215 2012-08-02  Richard Sandiford  <rdsandiford@googlemail.com>
6216
6217         PR target/51931
6218         * config/mips/mips-protos.h (mips_strip_unspec_address): Declare.
6219         * config/mips/mips.c (mips_strip_unspec_address): Make extern.
6220         (mips16_rewrite_pool_constant): Make a copy of the pool constant
6221         before adding to a PC-relative table.
6222         (mips16_lay_out_constants): Add a SPLIT_P parameter.
6223         (mips16_load_branch_target, mips16_split_long_branches): New functions.
6224         (mips_reorg): Update call to mips16_lay_out_constants.
6225         Call mips16_split_long_branches.
6226         * config/mips/predicates.md (pc_or_label_operand): Delete.
6227         * config/mips/mips.md (length): Add a calculation for MIPS16 branches.
6228         Move the extended_mips16 handling further down.
6229         (*branch_equality<mode>_mips16): Replace use pc_or_label_operand
6230         with explicit label_ref and pc.  Follow the usual operand numbering.
6231         (*branch_equality<mode>_mips16_inverted): New pattern.
6232         (*jump_mips16): Add length attribute.
6233         (indirect_jump_and_restore_<mode>): New pattern.
6234         (consttable_int): Call mips_strip_unspec_address on the operand.
6235
6236 2012-08-02  Richard Sandiford  <rdsandiford@googlemail.com>
6237
6238         * recog.c (split_insn): Copy the original SET_SRC before using
6239         it as a note.
6240
6241 2012-08-02  Richard Sandiford  <rdsandiford@googlemail.com>
6242
6243         * reorg.c (dbr_schedule): Delete REG_BR_PRED loop.
6244
6245 2012-08-02  Marc Glisse  <marc.glisse@inria.fr>
6246
6247         PR tree-optimization/53805
6248         * fold-const.c (invert_tree_comparison): Invert ORDERED_EXPR and
6249         UNORDERED_EXPR even for trapping floating point.
6250
6251 2012-08-02  H.J. Lu  <hongjiu.lu@intel.com>
6252
6253         PR middle-end/53321
6254         PR middle-end/53865
6255         * ipa-inline-analysis.c (inline_free_summary): Return if
6256         inline_edge_summary_vec is NULL.
6257
6258         * ipa-split.c (execute_split_functions): Check if a function
6259         is inlinable only if inline_edge_summary_vec != NULL.
6260
6261         * ipa.c (symtab_remove_unreachable_nodes): Restore
6262         cgraph_propagate_frequency call when something was changed.
6263         (free_inline_summary): New function.
6264         (pass_ipa_free_inline_summary): New pass.
6265
6266         * passes.c (init_optimization_passes): Add
6267         pass_ipa_free_inline_summary before pass_ipa_tree_profile.
6268
6269         * timevar.def (TV_IPA_FREE_INLINE_SUMMARY): New.
6270
6271         * tree-pass.h (pass_ipa_free_inline_summary): New.
6272
6273 2012-08-02  Richard Earnshaw  <rearnsha@arm.com>
6274
6275         * arm.c (arm_gen_constant): Use UBFX for some AND operations when
6276         available.
6277
6278 2012-08-02  Richard Guenther  <rguenther@suse.de>
6279
6280         * tree-into-ssa.c (struct common_info_d): New struct.
6281         (struct var_info_d, struct ssa_name_info): Use it.
6282         (get_ssa_name_ann): Adjust.
6283         (get_phi_state, set_phi_state): Remove.
6284         (get_common_info): New function.
6285         (get_current_def, set_current_def): Adjust.
6286         (get_def_blocks_for): Take a common info as param.
6287         (set_def_block): Call get_common_info once.
6288         (set_livein_block): Likewise.
6289         (find_def_blocks_for): Adjust.
6290         (insert_phi_nodes): Likewise.
6291         (register_new_def): Call get_common_info once.
6292         (get_reaching_def): Likewise.
6293         (rewrite_debug_stmt_uses): Likewise.
6294         (rewrite_leave_block): Likewise.
6295         (dump_currdefs): Likewise.
6296         (debug_var_infos_r): Adjust.
6297         (register_new_update_single): Call get_common_info once.
6298         (maybe_replace_use_in_debug_stmt): Likewise.
6299         (rewrite_update_leave_block): Likewise.
6300         (mark_use_interesting): Adjust.
6301         (create_new_def_for): Likewise.
6302         (update_ssa): Likewise.
6303
6304 2012-08-02  Michael Matz  <matz@suse.de>
6305
6306         * tree-ssa-live.c (set_is_used): Return a bool.
6307         (mark_all_vars_used): Don't take data argument.
6308         (mark_all_vars_used_1): Adjust calls to above, merge handling
6309         of local and global vars.
6310         (remove_unused_scope_block_p): Don't take global_unused_vars,
6311         merge handling of local and global vars.
6312         (remove_unused_locals): Don't allocate/fill/pass global_unused_vars,
6313         use is_used_p for local and global vars.
6314
6315 2012-08-02  Richard Guenther  <rguenther@suse.de>
6316
6317         * tree-flow.h (make_rename_temp): Remove.
6318         * tree-dfa.c (make_rename_temp): Likewise.
6319         * cgraphunit.c (thunk_adjust, assemble_thunk): Use create_tmp_reg
6320         instead of make_rename_temp.
6321         * omp-low.c (expand_omp_for_generic, expand_omp_for_static_nochunk,
6322         expand_omp_atomic_pipeline): Likewise.
6323         * trans-mem.c (tm_log_emit_save_or_restores, build_tm_load,
6324         build_tm_store, expand_call_tm, expand_transaction,
6325         ipa_tm_insert_gettmclone_call): Likewise.
6326         * tree-complex.c (expand_complex_div_wide): Likewise.
6327         * tree-mudflap.c (mf_decl_cache_locals, mf_build_check_statement_for):
6328         Likewise.
6329         * tree-ssa-loop-im.c (execute_sm_if_changed_flag_set, execute_sm):
6330         Likewise.
6331         * tree-ssa-math-opts.c (insert_reciprocals): Likewise.
6332         * value-prof.c (gimple_divmod_fixed_value, gimple_mod_pow2,
6333         gimple_mod_subtract): Likewise.
6334
6335 2012-08-02  Richard Guenther  <rguenther@suse.de>
6336
6337         * tree-flow.h (set_default_def): Rename to ...
6338         (set_ssa_default_def): ... this.  Take a struct function argument.
6339         (gimple_default_def): Rename to ...
6340         (ssa_default_def): ... this.
6341         (get_or_create_ssa_default_def): New function.
6342         * tree-dfa.c: Likewise.
6343         (dump_variable): Adjust.
6344         * ipa-prop.c (ipa_analyze_params_uses): Adjust, properly check
6345         for used parameters.
6346         * ipa-split.c (consider_split): Adjust, avoid repeated default-def
6347         lookups.
6348         (split_function): Likewise.
6349         * lto-streamer-in.c (input_ssa_names): Adjust.
6350         * omp-low.c (expand_omp_taskreg): Likewise.
6351         * tree-cfg.c (replace_ssa_name): Adjust, no need to push/pop cfun.
6352         * tree-complex.c (init_parameter_lattice_values): Adjust.
6353         (get_component_ssa_name): Likewise.
6354         (update_parameter_components): Likewise.
6355         * tree-inline.c (remap_ssa_name): Likewise.
6356         (setup_one_parameter): Likewise.
6357         (initialize_inlined_parameters): Likewise.
6358         (declare_return_variable): Likewise.
6359         (expand_call_inline): Likewise.
6360         (tree_function_versioning): Likewise.
6361         * tree-into-ssa.c (get_default_def_for): Remove.
6362         (get_reaching_def): Use get_or_create_ssa_default_def instead.
6363         * tree-predcom.c (replace_ref_with): Adjust.
6364         * tree-sra.c (get_repl_default_def_ssa_name): Likewise.
6365         (is_unused_scalar_param): Likewise.
6366         (ptr_parm_has_direct_uses): Likewise.
6367         (sra_ipa_reset_debug_stmts): Likewise.
6368         * tree-ssa-coalesce.c (create_outofssa_var_map): Adjust.
6369         * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Likewise.
6370         * tree-ssa-live.c (verify_live_on_entry): Likewise.
6371         * tree-ssa-math-opts.c (execute_cse_reciprocals): Likewise,
6372         avoid repeated default def lookups.
6373         * tree-ssa-sccvn.c (run_scc_vn): Likewise.
6374         * tree-tailcall.c (arg_needs_copy_p): Adjust.
6375         (tree_optimize_tail_calls_1): Likewise.
6376
6377 2012-08-02  Richard Guenther  <rguenther@suse.de>
6378
6379         PR tree-optimization/50672
6380         Revert
6381         2012-08-01  Richard Guenther  <rguenther@suse.de>
6382
6383         * tree-ssa-tail-merge.c (release_last_vdef): Remove.
6384         (replace_block_by): Adjust.
6385
6386 2012-08-02  Richard Guenther  <rguenther@suse.de>
6387
6388         * tree-dfa.c (referenced_var_lookup): Remove.
6389         (find_referenced_vars): Remove.
6390         (pass_referenced_vars): Likewise.
6391         (make_rename_temp): Do not add referenced vars.
6392         (dump_referenced_vars): Remove.
6393         (debug_referenced_vars): Likewise.
6394         (dump_dfa_stats): Do not dump referenced var stats.
6395         (find_vars_r): Remove.
6396         (find_referenced_vars_in): Likewise.
6397         (referenced_var_check_and_insert): Likewise.
6398         (add_referenced_var_1): Likewise.
6399         (remove_referenced_var): Likewise.
6400         * tree-flow.h (referenced_var_lookup): Likewise.
6401         (struct gimple_df): Remove referenced_vars member.
6402         (typedef referenced_var_iterator): Remove.
6403         (FOR_EACH_REFERENCED_VAR): Likewise.
6404         (num_referenced_vars): Likewise.
6405         (debug_referenced_vars, dump_referenced_vars): Likewise.
6406         (add_referenced_var_1, add_referenced_var): Likewise.
6407         (remove_referenced_var): Likewise.
6408         (find_referenced_vars_in): Likewise.
6409         * tree-flow-inline.h (gimple_referenced_vars): Remove.
6410         (first_referenced_var): Likewise.
6411         (end_referenced_vars_p): Likewise.
6412         (next_referenced_var): Likewise.
6413         * cfgexpand.c (update_alias_info_with_stack_vars): Remove assert.
6414         * gimple-pretty-print.c (pp_points_to_solution): Dump UIDs
6415         unconditionally.
6416         * tree-into-ssa.c (dump_decl_set): Likewise.
6417         (pass_build_ssa): Do not require PROP_referenced_vars.
6418         * tree-ssa.c (target_for_debug_bind): Virtual operands are
6419         not suitable, but all register type vars are.
6420         (init_tree_ssa): Do not allocate referenced vars.
6421         (delete_tree_ssa): Do not free referenced vars.
6422         * cgraphunit.c (init_lowered_empty_function): Do not set
6423         PROP_referenced_vars.
6424         (assemble_thunk): Do not add referenced vars.
6425         * gimple-fold.c (canonicalize_constructor_val): Likewise.
6426         (gimplify_and_update_call_from_tree): Likewise.
6427         * gimple-streamer-in.c (input_bb): Likewise.
6428         * passes.c (init_optimization_passes): Do not run
6429         pass_referenced_vars.
6430         (dump_properties): Do not dump PROP_referenced_vars.
6431         * tree-inline.c (remap_decl): Do not add referenced vars.
6432         (remap_gimple_op_r): Likewise.
6433         (copy_tree_body_r): Likewise.
6434         (copy_bb): Likewise.
6435         (setup_one_parameter): Likewise.
6436         (declare_return_variable): Likewise.
6437         (copy_decl_for_dup_finish): Likewise.
6438         (copy_arguments_for_versioning): Likewise.
6439         (tree_function_versioning): Likewise.
6440         * tree-pass.h (PROP_referenced_vars): Remove.
6441         (pass_referenced_vars): Likewise.
6442         * tree-profile.c (gimple_gen_edge_profiler): Do not add
6443         referenced vars.
6444         (gimple_gen_interval_profiler): Likewise.
6445         (gimple_gen_pow2_profiler): Likewise.
6446         (gimple_gen_one_value_profiler): Likewise.
6447         (gimple_gen_ic_profiler): Likewise.
6448         (gimple_gen_average_profiler): Likewise.
6449         (gimple_gen_ior_profiler): Likewise.
6450         * tree-ssa-live.c (remove_unused_locals): Do not touch referenced vars.
6451         * tree-cfg.c (replace_ssa_name): Do not add referenced vars.
6452         (move_stmt_op): Likewise.
6453         * tree-ssa-operands.c (create_vop_var): Likewise.
6454         * gimple-low.c (record_vars_into): Likewise.
6455         * gimplify.c (gimple_regimplify_operands): Likewise.
6456         (force_gimple_operand_1): Likewise.
6457         * omp-low.c (expand_omp_for_generic): Likewise.
6458         (expand_omp_for_static_chunk): Likewise.
6459         (expand_omp_atomic_pipeline): Likewise.
6460         * graphite-clast-to-gimple.c (graphite_create_new_loop): Likewise.
6461         (translate_clast_assignment): Likewise.
6462         * graphite-sese-to-poly.c (create_zero_dim_array): Likewise.
6463         (handle_scalar_deps_crossing_scop_limits): Likewise.
6464         * ipa-prop.c (ipa_modify_formal_parameters): Likewise.
6465         * ipa-split.c (split_function): Likewise.
6466         * matrix-reorg.c (transform_access_sites): Likewise.
6467         * trans-mem.c (tm_log_add): Likewise.
6468         (ipa_tm_insert_gettmclone_call): Likewise.
6469         * tree-complex.c (create_one_component_var): Likewise.
6470         * tree-if-conv.c (ifc_temp_var): Likewise.
6471         * tree-parloops.c (take_address_of): Likewise.
6472         (initialize_reductions): Likewise.
6473         (separate_decls_in_region_name): Likewise.
6474         (create_call_for_reduction_1): Likewise.
6475         (separate_decls_in_region): Likewise.
6476         * tree-predcom.c (predcom_tmp_var): Likewise.
6477         (reassociate_to_the_same_stmt): Likewise.
6478         * tree-sra.c (build_ref_for_offset): Likewise.
6479         (create_access_replacement): Likewise.
6480         (get_replaced_param_substitute): Likewise.
6481         (sra_ipa_reset_debug_stmts): Likewise.
6482         * tree-ssa-loop-im.c (rewrite_reciprocal): Likewise.
6483         (rewrite_bittest): Likewise.
6484         * tree-ssa-loop-ivopts.c (create_new_iv): Likewise.
6485         * tree-ssa-loop-manip.c (create_iv): Likewise.
6486         (tree_transform_and_unroll_loop): Likewise.
6487         * tree-ssa-math-opts.c (powi_as_mults): Likewise.
6488         (build_and_insert_call): Likewise.
6489         (gimple_expand_builtin_cabs): Likewise.
6490         (execute_optimize_bswap): Likewise.
6491         * tree-ssa-phiopt.c (conditional_replacement): Likewise.
6492         (abs_replacement): Likewise.
6493         (cond_store_replacement): Likewise.
6494         (cond_if_else_store_replacement_1): Likewise.
6495         * tree-ssa-phiprop.c (phiprop_insert_phi): Likewise.
6496         * tree-ssa-pre.c (get_representative_for): Likewise.
6497         (create_expression_by_pieces): Likewise.
6498         (insert_into_preds_of_block): Likewise.
6499         * tree-ssa-propagate.c (update_call_from_tree): Likewise.
6500         * tree-ssa-reassoc.c (undistribute_ops_list): Likewise.
6501         (eliminate_redundant_comparison): Likewise.
6502         (rewrite_expr_tree_parallel): Likewise.
6503         (get_reassoc_pow_ssa_name): Likewise.
6504         * tree-ssa-strlen.c (get_string_length): Likewise.
6505         * tree-switch-conversion.c (emit_case_bit_tests): Likewise.
6506         (build_arrays): Likewise.
6507         * tree-tailcall.c (adjust_return_value_with_ops): Likewise.
6508         (create_tailcall_accumulator): Likewise.
6509         * tree-vect-data-refs.c (vect_get_new_vect_var): Likewise.
6510         (vect_create_addr_base_for_vector_ref): Likewise.
6511         (vect_permute_store_chain): Likewise.
6512         (vect_permute_load_chain): Likewise.
6513         * tree-vect-generic.c (expand_vector_divmod): Likewise.
6514         * tree-vect-loop-manip.c (set_prologue_iterations): Likewise.
6515         (vect_build_loop_niters): Likewise.
6516         (vect_generate_tmps_on_preheader): Likewise.
6517         (vect_update_ivs_after_vectorizer): Likewise.
6518         (vect_gen_niters_for_prolog_loop): Likewise.
6519         (vect_do_peeling_for_alignment): Likewise.
6520         (vect_create_cond_for_align_checks): Likewise.
6521         * tree-vect-patterns.c (vect_recog_temp_ssa_var): Likewise.
6522         (vect_handle_widen_op_by_const): Likewise.
6523         (vect_operation_fits_smaller_type): Likewise.
6524         (vect_recog_over_widening_pattern): Likewise.
6525         * tree-vect-stmts.c (vect_init_vector): Likewise.
6526
6527 2012-08-01  Alexandre Oliva  <aoliva@redhat.com>
6528
6529         PR debug/52983
6530         * valtrack.c (dead_debug_insert_temp): Use cleanup_auto_inc_dec.
6531
6532 2012-08-01  Alexandre Oliva  <aoliva@redhat.com>
6533
6534         PR debug/52983
6535         * valtrack.c (cleanup_auto_inc_dec): Implement unconditionally,
6536         falling back to copy_rtx on non-autoinc machines.
6537         (propagate_for_debug_subst): Always use cleanup_auto_inc_dec.
6538
6539 2012-08-01  Alexandre Oliva  <aoliva@redhat.com>
6540
6541         PR debug/52983
6542         * valtrack.h, valtrack.c: New.
6543         * Makefile.in (VALTRACK_H): New.
6544         (OBJS): Add valtrack.o.
6545         (valtrack.o): New.
6546         (cselib.o, dce.o, df-problems.o, combine.o): Add VALTRACK_H.
6547         * combine.c: Include valtrack.h.
6548         (make_compound_operation): Publish.
6549         (cleanup_auto_inc_dec): Move to valtrack.c.
6550         (struct rtx_subst_pair, propagate_for_debug_subst): Likewise.
6551         (propagate_for_debug): Likewise.  Add this_basic_block parameter.
6552         Adjust all callers.
6553         * cselib.c: Include valtrack.h.
6554         * dce.c: Likewise.
6555         * df-problems.c: Likewise.
6556         (dead_debug_init, dead_debug_reset_uses): Move to valtrack.c.
6557         (dead_debug_finish, dead_debug_add): Likewise.
6558         (dead_debug_insert_temp): Likewise.
6559         * df.h (struct dead_debug_use): Move to valtrack.h.
6560         (struct dead_debug, enum debug_temp_where): Likewise.
6561         (dead_debug_init, dead_debug_reset_uses): Move to valtrack.h.
6562         (dead_debug_finish, dead_debug_add): Likewise.
6563         (dead_debug_insert_temp): Likewise.
6564         * rtl.h (make_compound_operation): Declare.
6565
6566 2012-08-01  Catherine Moore  <clm@codesourcery.com>
6567             Sandra Loosemore  <sandra@codesourcery.com>
6568
6569         * config/mips/mips-cpus.def (34kn): New.
6570         * config/mips/mips.h (MIPS_ARCH_FLOAT_SPEC): Add 34kn.
6571         (BASE_DRIVER_SELF_SPECS): Do not imply -mdsp for the 34kn.
6572         * config/mips/mips-tables.opt: Regenerate.
6573         * doc/invoke.texi (MIPS Options): Document -march=34kn.
6574
6575 2012-08-01  Richard Henderson  <rth@redhat.com>
6576
6577         * expmed.h (NUM_MODE_PARTIAL_INT): New.
6578         (NUM_MODE_VECTOR_INT, NUM_MODE_IP_INT, NUM_MODE_IPV_INT): New.
6579         (struct expmed_op_cheap): Size one array on NUM_MODE_IPV_INT.
6580         (struct expmed_op_costs): Likewise.
6581         (struct target_expmed): Size x_convert_cost on NUM_MODE_IP_INT.
6582         (expmed_mode_index): New.
6583         (expmed_op_cheap_ptr, expmed_op_cost_ptr): Use expmed_mode_index.
6584         (convert_cost_ptr): Likewise.
6585         * expmed.c (struct init_expmed_rtl): Rename convert to trunc.
6586         (init_expmed_one_conv): Split out from ...
6587         (init_expmed_one_mode): ... here.  Iterate conversions over
6588         partial integer modes too.
6589         (init_expmed): Iterate over partial integer modes too.
6590
6591 2012-08-01  Richard Henderson  <rth@redhat.com>
6592
6593         * config/m32c/m32c.c (TARGET_INIT_LIBFUNCS): Remove.
6594         (m32c_init_libfuncs): Remove.
6595         * config/m32c/cond.md (cstore<QHPSI>4_16): Rename from cstore<QHPSI>4.
6596         (cstore<QHPSI>4): New expander.
6597
6598 2012-08-01  Richard Guenther  <rguenther@suse.de>
6599
6600         * tree-flow-inline.h (referenced_var): Remove.
6601         * tree-ssa-coalesce.c (create_outofssa_var_map): Remove duplicate
6602         checking code.
6603         * tree-sra.c (candidates): New global hashtable.
6604         (candidate): New function.
6605         (sra_initialize): Initialize candidates.
6606         (sra_deinitialize): Free candidates.
6607         (disqualify_candidate): Remove candidate from candidates.
6608         (maybe_add_sra_candidate): New function.
6609         (find_var_candidates): Walk over all local decls and parameters,
6610         add candidates to candidates hashtable.
6611         (find_param_candidates): Add candidates to candidates hashtable.
6612         (analyze_all_variable_accesses): Use candidate instead of
6613         referenced_var.
6614
6615 2012-08-01  Tom de Vries  <tom@codesourcery.com>
6616
6617         * tree-vrp.c (find_case_label_ranges): New function.
6618         (vrp_visit_switch_stmt, simplify_switch_using_ranges): Use
6619         find_case_label_ranges instead of find_case_label_range.  Handle second
6620         range.
6621
6622 2012-08-01  Michael Matz  <matz@suse.de>
6623
6624         * tree-complex.c (init_parameter_lattice_values): Don't call var_ann.
6625         * tree-dfa.c (struct dfa_stats_d): Remove num_var_anns member.
6626         (dump_dfa_stats): Don't dump stats about var anns.
6627         (collect_dfa_stats): Don't collect them.
6628         (add_referenced_var_1): Don't set var annotation pointers.
6629         (remove_referenced_var): Ditto, and only remove it it's in the
6630         hash table.
6631
6632         * tree-flow-inline.h (var_ann): Remove.
6633         * tree-flow.h (struct var_ann_d, var_ann_t): Remove.
6634
6635         * tree-inline.c (remapped_type): Remove.
6636         (can_be_nonlocal): Most variable will be considered live here,
6637         return false earlier.
6638         (remap_decls): Don't call var_ann, all variables will be considered
6639         referenced here.
6640         (copy_debug_stmt): Ditto, and use is_global_var.
6641
6642         * tree-into-ssa.c (rewrite_debug_stmt_uses): Use get_current_def to
6643         determine if a variable was referred to, not var_ann.
6644         * tree-ssa-live.c (remove_unused_scope_block_p): Don't check var_ann.
6645         (remove_unused_locals): Ditto.
6646         * tree-ssa.c (delete_tree_ssa): Don't free/clear var ann pointers.
6647         * tree-tailcall.c (arg_needs_copy_p): Don't check var_ann.
6648         * tree.c (copy_node_stat): Don't clear var ann pointer.
6649         * tree.h (tree_result_decl, tree_parm_decl, tree_var_decl): Remove
6650         ann member.
6651         (DECL_VAR_ANN_PTR): Remove.
6652
6653 2012-08-01  Michael Matz  <matz@suse.de>
6654
6655         * tree-flow.h (struct var_ann_d): Rename used member.
6656         (set_is_used): Don't declare.
6657         * tree-flow-inline.h (clear_is_used): Remove.
6658         (set_is_used, is_used_p): Move to ...
6659         * tree-ssa-live.c (set_is_used, is_used_p): ... here, and use
6660         on the side bitmap.
6661         (usedvars): New bitmap.
6662         (dump_scope_block): Don't dump unusedness.
6663         (remove_unused_locals): Allocate and free usedvars.
6664         * tree-nrv.c (tree_nrv): Don't clear used flags here.
6665
6666 2012-08-01  Michael Matz  <matz@suse.de>
6667
6668         * tree-flow.h (struct var_ann_d): Remove base_var_processed and
6669         base_index members.
6670         * tree-ssa-live.h (struct _var_map): Remove basevars member.
6671         (VAR_ANN_BASE_INDEX): Remove.
6672         * tree-ssa-live.c (var_map_base_init): Use a hash table instead
6673         of var annotation to compress index space.  Don't deal with above
6674         removed members.
6675         (var_map_base_fini): Don't free basevars.
6676         (init_var_map): Don't clear basevars.
6677
6678 2012-08-01  Bill Schmidt  <wschmidt@linux.ibm.com>
6679
6680         * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Change
6681         base_name to base_expr.
6682         (struct cand_chain_d): Likewise.
6683         (base_cand_hash): Likewise.
6684         (base_cand_eq): Likewise.
6685         (record_potential_basis): Likewise.
6686         (alloc_cand_and_find_basis): Likewise.
6687         (create_mul_ssa_cand): Likewise.
6688         (create_mul_imm_cand): Likewise.
6689         (create_add_ssa_cand): Likewise.
6690         (create_add_imm_cand): Likewise.
6691         (slsr_process_cast): Likewise.
6692         (slsr_process_copy): Likewise.
6693         (dump_candidate): Likewise.
6694         (base_cand_dump_callback): Likewise.
6695         (unconditional_cands_with_known_stride_p): Likewise.
6696         (cand_increment): Likewise.
6697
6698 2012-08-01  Bill Schmidt  <wschmidt@linux.ibm.com>
6699
6700         PR tree-optimization/46556
6701         * gimple-ssa-strength-reduction.c (enum cand_kind): Add CAND_REF.
6702         (base_cand_map): Change to hash table.
6703         (base_cand_hash): New function.
6704         (base_cand_free): Likewise.
6705         (base_cand_eq): Likewise.
6706         (lookup_cand): Change base_cand_map to hash table.
6707         (find_basis_for_candidate): Likewise.
6708         (base_cand_from_table): Exclude CAND_REF.
6709         (restructure_reference): New function.
6710         (slsr_process_ref): Likewise.
6711         (find_candidates_in_block): Call slsr_process_ref.
6712         (dump_candidate): Handle CAND_REF.
6713         (base_cand_dump_callback): New function.
6714         (dump_cand_chains): Change base_cand_map to hash table.
6715         (replace_ref): New function.
6716         (replace_refs): Likewise.
6717         (analyze_candidates_and_replace): Call replace_refs.
6718         (execute_strength_reduction): Change base_cand_map to hash table.
6719
6720 2012-08-01  Uros Bizjak  <ubizjak@gmail.com>
6721
6722         * config/i386/i386.c (ix86_address_subreg_operand): Reject
6723         stack pointer.
6724         (ix86_print_operand_address): Assert that parts.base and parts.index
6725         are non-NULL after call to simplify_subreg.
6726
6727 2012-08-01  Richard Guenther  <rguenther@suse.de>
6728
6729         * doc/tree-ssa.texi: Remove pieces mentioning mark_sym_for_renaming.
6730
6731 2012-08-01  Richard Guenther  <rguenther@suse.de>
6732
6733         * graphite-clast-to-gimple.c (translate_clast_user): Rename
6734         virtual operands.
6735         * sese.c (graphite_copy_stmts_from_block): Do not rename virtual
6736         operands here.
6737         * tree-call-cdce.c (tree_call_cdce): Use
6738         mark_virtual_operands_for_renaming.
6739         * tree-eh.c (sink_clobbers): Simplify.
6740         * tree-flow.h (mark_sym_for_renaming): Remove.
6741         (mark_virtual_operands_for_renaming): New function.
6742         * tree-if-conv.c (tree_if_conversion): Use
6743         mark_virtual_operands_for_renaming.
6744         * tree-inline.c (update_ssa_across_abnormal_edges): Likewise.
6745         * tree-into-ssa.c (mark_sym_for_renaming): Remove.
6746         (mark_virtual_operands_for_renaming): New function.
6747         * tree-loop-distribution.c (tree_loop_distribution): Use
6748         mark_virtual_operands_for_renaming.
6749         * tree-ssa-dce.c (mark_virtual_operand_for_renaming): Do not
6750         update stmts, use mark_virtual_operands_for_renaming.
6751         * tree-ssa-tail-merge.c (release_last_vdef): Remove.
6752         (replace_block_by): Adjust.
6753         (tail_merge_optimize): Use mark_virtual_operands_for_renaming.
6754         * tree-tailcall.c (tree_optimize_tail_calls_1): Use
6755         mark_virtual_operands_for_renaming.
6756         * tree-vect-slp.c (vect_slp_transform_bb): Likewise.
6757         * tree-vectorizer.c (vectorize_loops): Likewise.
6758
6759 2012-08-01  Richard Guenther  <rguenther@suse.de>
6760
6761         * tree-flow.h (struct gimple_df): Remove syms_to_rename member,
6762         add ssa_renaming_needed and rename_vops flags.
6763         (SYMS_TO_RENAME): Remove.
6764         (symbol_marked_for_renaming): Likewise.
6765         (mark_virtual_ops_for_renaming): Likewise.
6766         * tree-into-ssa.c (symbols_to_rename_set, symbols_to_rename):
6767         New globals.
6768         (mark_for_renaming, marked_for_renaming): New functions.
6769         (symbol_marked_for_renaming): Remove.
6770         (dump_currdefs): Adjust.
6771         (maybe_replace_use): Likewise.
6772         (maybe_replace_use_in_debug_stmt): Likewise.
6773         (maybe_register_def): Likewise.
6774         (rewrite_update_phi_arguments): Likewise.
6775         (rewrite_update_enter_block): Likewise.
6776         (fini_ssa_renamer): Clear update SSA status here ...
6777         (delete_update_ssa): ... not here.  Free rename set.
6778         (prepare_block_for_update): Compute which decls need renaming.
6779         (dump_update_ssa): Adjust.
6780         (mark_sym_for_renaming): Adjust update SSA status for virtuals.
6781         (need_ssa_update_p): Adjust.
6782         (insert_updated_phi_nodes_for): Likewise.
6783         (update_ssa): Likewise.
6784         * tree-ssa-operands.c (finalize_ssa_defs): Adjust update SSA status
6785         for virtual and real operands.
6786         (finalize_ssa_uses): Likewise.
6787         * tree-ssanames.c (init_ssanames): Adjust.
6788         * tree-ssa.c (maybe_rewrite_mem_ref_base, maybe_optimize_var,
6789         execute_update_addresses_taken): Add bitmap to keep track of which
6790         candidates are suitable for rewriting and later renaming by SSA update.
6791         * matrix-reorg.c (transform_access_sites): Do not rename all defs.
6792         * tree-dfa.c (make_rename_temp): Do not mark real operands for
6793         renaming.
6794         * cgraphunit.c (assemble_thunk): Likewise.
6795         * gimplify.c (gimple_regimplify_operands): Likewise.
6796         (force_gimple_operand_1): Likewise.
6797         * ipa-prop.c (ipa_modify_formal_parameters): Likewise.
6798         * tree-inline.c (declare_return_variable): Likewise.
6799         * tree-parloops.c (separate_decls_in_region_stmt): Do not call
6800         mark_virtual_ops_for_renaming.
6801         (create_stores_for_reduction): Likewise.
6802         (create_loads_and_stores_for_name): Likewise.
6803         * tree-predcom.c (mark_virtual_ops_for_renaming): Remove.
6804         (initialize_root_vars_lm): Do not call mark_virtual_ops_for_renaming.
6805         (execute_load_motion): Likewise.
6806         (remove_stmt): Likewise.
6807         (execute_pred_commoning_chain): Likewise.
6808         * tree-sra.c (create_access_replacement): Do not rename real operands.
6809         (get_unrenamed_access_replacement): Unify with ...
6810         (get_access_replacement): ... this.
6811         (get_repl_default_def_ssa_name): Adjust.
6812         * tree-ssa-loop-im.c (move_computations_stmt): Manually update
6813         virtual SSA form.
6814         (rewrite_mem_ref_loc): Do not call mark_virtual_ops_for_renaming.
6815         * tree-ssa-loop-prefetch.c (emit_mfence_after_loop): Likewise.
6816
6817 2012-07-31  DJ Delorie  <dj@redhat.com>
6818
6819         * config/s390/s390.c (s390_option_override): Disable DWARF 3/4
6820         extensions for TPF, unless specifically selected.
6821
6822 2012-08-01  Alan Modra  <amodra@gmail.com>
6823
6824         PR target/54131
6825         * config/rs6000/rs6000.c (mem_operand_gpr): Don't limit range
6826         of lo_sum offsets.  Comment.  Assert mode at least word size
6827         rather than bypassing powerpc64 word offset check.
6828
6829 2012-07-31  Bill Schmidt  <wschmidt@linux.ibm.com>
6830
6831         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost): Revise
6832         costs for vec_perm and vec_promote_demote down to more natural values.
6833         (struct _rs6000_cost_data): New data structure.
6834         (rs6000_density_test): New function.
6835         (rs6000_init_cost): Change to use rs6000_cost_data.
6836         (rs6000_add_stmt_cost): Likewise.
6837         (rs6000_finish_cost): Perform density test when vectorizing a loop.
6838
6839 2012-07-31  Steven Bosscher  <steven@gcc.gnu.org>
6840
6841         * sched-vis.c (print_exp): Handle FMA explicitly.  Simplify handling
6842         of RTX_UNARY function-like operations.  Print unknown expression
6843         RTX classes as pseudo-functions.
6844         (print_pattern): Simplify return pattern printing.
6845         (dump_insn_slim): Print the value of notes as a pattern for proper
6846         printing of CFA notes.
6847
6848 2012-07-31  Dehao Chen  <dehao@google.com>
6849
6850         * predict.c (tree_estimate_probability_driver): Normalize the
6851         loop when initializing the loop optimizer.
6852
6853 2012-07-31  Richard Guenther  <rguenther@suse.de>
6854
6855         * tree-flow.h (struct var_ann_d): Remove need_phi_state
6856         and current_def members.
6857         * tree-into-ssa.c (struct def_blocks_d): Remove var member.
6858         (def_blocks): Remove.
6859         (struct var_info_d): New.
6860         (var_infos): New hashtable.
6861         (struct ssa_name_info): Add def_blocks member.
6862         (get_ssa_name_ann): Adjust.
6863         (get_var_info): New function.
6864         (get_phi_state, set_phi_state, get_current_def,
6865         set_current_def, get_def_blocks_for, find_def_blocks_for): Adjust.
6866         (insert_phi_nodes_compare_def_blocks): Rename to ...
6867         (insert_phi_nodes_compare_var_infos): ... this and adjust.
6868         (insert_phi_nodes): Adjust.
6869         (dump_tree_ssa, dump_tree_ssa_stats): Adjust.
6870         (def_blocks_hash, def_blocks_eq, def_blocks_free): Remove.
6871         (debug_def_blocks_r): Rename to ...
6872         (debug_var_infos_r): ... this and adjust.
6873         (var_info_hash): New function.
6874         (var_info_eq): Likewise.
6875         (rewrite_blocks): Adjust.
6876         (init_ssa_renamer): Likewise.
6877         (fini_ssa_renamer): Likewise.
6878         (delete_update_ssa): Likewise.
6879         (update_ssa): Likewise.
6880         * tree-ssanames.c (release_dead_ssa_names): Do not clear current defs.
6881
6882 2012-07-31  Bill Schmidt  <wschmidt@linux.ibm.com>
6883
6884         PR tree-optimization/53773
6885         * tree-vectorizer.h (struct _loop_vec_info): Add operands_swapped.
6886         (LOOP_VINFO_OPERANDS_SWAPPED): New macro.
6887         * tree-vect-loop.c (new_loop_vec_info): Initialize
6888         LOOP_VINFO_OPERANDS_SWAPPED field.
6889         (destroy_loop_vec_info): Restore canonical form.
6890         (vect_is_slp_reduction): Set LOOP_VINFO_OPERANDS_SWAPPED field.
6891         (vect_is_simple_reduction_1): Likewise.
6892
6893 2012-07-31  Steven Bosscher  <steven@gcc.gnu.org>
6894
6895         * sched-vis.c (dump_insn_slim): Print print_rtx_head at the
6896         start of each new line.
6897         * final.c (final_scan_insn): If the final dump is requested as
6898         slim RTL, dump slim RTL to the assembly file also.
6899
6900 2012-07-31  Andrey Belevantsev  <abel@ispras.ru>
6901
6902         PR target/53975
6903
6904         * sel-sched-ir.c (has_dependence_note_reg_use): Clarify comment.
6905
6906         Revert
6907         2011-08-04  Sergey Grechanik  <mouseentity@ispras.ru>
6908
6909         * sel-sched-ir.c (has_dependence_note_reg_use): Call ds_full_merge
6910         only if producer writes to the register given by regno.
6911
6912 2012-07-31  Nick Clifton  <nickc@redhat.com>
6913
6914         * config/stormy16/stormy16.c (xstormy16_expand_prologue): Add
6915         support for reporting stack usage.
6916
6917         * config/frv/frv.c (QUAD): Fix typo.
6918         (frv_expand_prologue): Report stack usage.
6919
6920 2012-07-31  Steven Bosscher  <steven@gcc.gnu.org>
6921
6922         PR pch/53880
6923         * gengtype.c (struct walk_type_data): Add have_this_obj field.
6924         (walk_type): For functions that take a this_obj argument and
6925         that process fields with a GTY((length)) argument, write the
6926         test that write_types_local_process_field will write also at the
6927         head of the loop, effectively unswitching the loop.
6928         (write_func_for_structure, write_local_func_for_structure): Clear
6929         have_this_obj before calling walk_type.
6930         (write_local_func_for_structure): Set have_this_obj before walk_type.
6931         (write_array): Set have_this_obj for output of local pointer walking
6932         functions but not for marker functions.
6933         (write_types_local_process_field): Assert have_this_obj is set.
6934
6935         * rtl.h (simplify_using_condition): Adjust prototype using bitmap
6936         from coretypes.h.
6937
6938 2012-07-30  Nathan Froyd  <froydnj@gcc.gnu.org>
6939
6940
6941         * defaults.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
6942         * targhooks.c (default_mode_dependent_address_p): Delete code
6943         for GO_IF_MODE_DEPENDENT_ADDRESS.
6944         * system.h (GO_IF_MODE_DEPENDENT_ADDRESS): Poison.
6945         * doc/tm.texi.in (GO_IF_MODE_DEPENDENT_ADDRESS): Delete documention.
6946         * doc/tm.texi: Regenerate.
6947         * config/alpha.h (GO_IF_MODE_DEPENDENT_ADDRESS): Move code to...
6948         * config/alpha.c (alpha_mode_dependent_address_p): ...here.  New
6949         function.
6950         (TARGET_MODE_DEPENDENT_ADDRESS_P): Define.
6951         * config/cr16/cr16.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
6952         * config/mep/mep.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
6953         * config/vax/vax-protos.h (vax_mode_dependent_address_p): Delete.
6954         * config/vax/vax.h (GO_IF_MODE_DEPENDENT_ADDRESS): Delete.
6955         * config/vax/vax.c (vax_mode_dependent_address_p): Make static.
6956         Take a const_rtx.
6957         (TARGET_MODE_DEPENDENT_ADDRESS_P): Define.
6958
6959 2012-07-30  Nathan Froyd  <froydnj@gcc.gnu.org>
6960
6961         * expmed.h (NUM_MODE_VECTOR_INT): Define.
6962         (struct expmed_op_cheap, struct expmed_op_costs): New structures.
6963         (struct target_expmed): Convert x_mul_highpart_cost and
6964         x_mul_widen_cost fields to be indexed by integer modes.
6965         Convert x_sdiv_pow2_cheap and x_smod_pow2_cheap fields to be
6966         of type struct expmed_op_cheap.  Convert other cost fields to be
6967         of type struct_expmed_op_costs.
6968         (mul_widen_cost_ptr, mul_highpart_cost_ptr): Adjust for new
6969         indexing of respective fields.
6970         (expmed_op_cheap_ptr): New function.
6971         (sdiv_pow2_cheap_ptr, smod_pow2_cheap_ptr): Call it.
6972         (expmed_op_cost_ptr): New function.
6973         (add_cost_ptr, neg_cost_ptr, shift_cost_ptr, shiftadd_cost_ptr,
6974         shiftsub0_cost_ptr, shiftsub1_cost_ptr, mul_cost_ptr,
6975         sdiv_cost_ptr, udiv_cost_ptr): Call it.
6976
6977 2012-07-30  Sandra Loosemore  <sandra@codesourcery.com>
6978             Julian Brown  <julian@codesourcery.com>
6979
6980         * doc/invoke.texi (MIPS Options): Document -mno-float.
6981         * config/mips/mips.h (MIPS_ARCH_FLOAT_SPEC): Make it know
6982         about -mno-float.
6983
6984 2012-07-30  Joseph Myers  <joseph@codesourcery.com>
6985
6986         * doc/sourcebuild.texi (Subdirectories): Document common subdirectory.
6987
6988 2012-07-30  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
6989
6990         PR middle-end/53823
6991         * expmed.c (expand_mult): Skip synth_mult for constant double op1 except
6992         for special cases.  Don't initialize coeff and is_neg.
6993
6994 2012-07-30  Ulrich Weigand  <ulrich.weigand@linaro.org>
6995             Richard Earnshaw  <rearnsha@arm.com>
6996
6997         * target.def (vector_alignment): New target hook.
6998         * doc/tm.texi.in (TARGET_VECTOR_ALIGNMENT): Document new hook.
6999         * doc/tm.texi: Regenerate.
7000         * targhooks.c (default_vector_alignment): New function.
7001         * targhooks.h (default_vector_alignment): Add prototype.
7002         * stor-layout.c (layout_type): Use targetm.vector_alignment.
7003         * config/arm/arm.c (arm_vector_alignment): New function.
7004         (TARGET_VECTOR_ALIGNMENT): Define.
7005
7006         * tree-vect-data-refs.c (vect_update_misalignment_for_peel): Use
7007         vector type alignment instead of size.
7008         * tree-vect-loop-manip.c (vect_do_peeling_for_loop_bound): Use
7009         element type size directly instead of computing it from alignment.
7010         Fix variable naming and comment.
7011
7012 2012-07-30  Kirill Yukhin  <kirill.yukhin@intel.com>
7013             Michael Zolotukhin  <michael.v.zolotukhin@intel.com>
7014
7015         * common/config/i386/i386-common.c (OPTION_MASK_ISA_RDSEED_SET): New.
7016         (OPTION_MASK_ISA_RDSEED_UNSET): Likewise.
7017         (ix86_handle_option): Handle mrdseed option.
7018         * config.gcc (i[34567]86-*-*): Add rdseedintrin.h.
7019         (x86_64-*-*): Likewise.
7020         * config/i386/prfchwintrin.h: New header.
7021         * config/i386/cpuid.h (bit_RDSEED): New.
7022         * config/i386/driver-i386.c (host_detect_local_cpu): Detect
7023         RDSEED support.
7024         * config/i386/i386-c.c: Define __RDSEED__ if needed.
7025         * config/i386/i386.c (ix86_target_string): Define -mrdseed option.
7026         (PTA_RDSEED): New.
7027         (ix86_option_override_internal): Handle new option.
7028         (ix86_valid_target_attribute_inner_p): Add OPT_mrdseed.
7029         (ix86_builtins): Add enum entries for RDSEED* builtins.
7030         (ix86_init_mmx_sse_builtins): Define new builtins.
7031         (ix86_expand_builtin): Expand RDSEED* builtins.
7032         * config/i386/i386.h (TARGET_RDSEED): New.
7033         * config/i386/i386.md (rdseed<mode>_1): New.
7034         * config/i386/i386.opt (mrdseed): New.
7035         * config/i386/x86intrin.h: Include rdseedintrin.h.
7036
7037 2012-07-30  Richard Guenther  <rguenther@suse.de>
7038
7039         * tree-into-ssa.c (mark_def_sites): Also process virtual operands.
7040         (rewrite_stmt): Likewise.
7041         (rewrite_enter_block): Likewise.
7042         (pass_build_ssa): Do not update virtual SSA form during TODO.
7043         (mark_symbol_for_renaming): Do nothing if we are not in SSA form.
7044         * lto-streamer-in.c (lto_read_body): Set in_ssa_p earlier.
7045
7046 2012-07-30  Oleg Endo  <olegendo@gcc.gnu.org>
7047
7048         PR target/39423
7049         * config/gcc/sh/sh.md (*movsi_index_disp, *movhi_index_disp): New
7050         insns.
7051
7052 2012-07-30  Oleg Endo  <olegendo@gcc.gnu.org>
7053
7054         PR target/51244
7055         * config/sh/sh.md (mov_neg_si_t): Move to Scc instructions section.
7056         Use t_reg_operand predicate.  Add split for negated case.
7057         (ashrsi2_31): Pass get_t_reg_rtx to gen_mov_neg_si_t.
7058         * config/sh/sh.c (expand_ashiftrt): Likewise.
7059
7060 2012-07-30  Oleg Endo  <olegendo@gcc.gnu.org>
7061
7062         PR target/54089
7063         * config/sh/sh.md (ashlsi3_d): Invoke gen_shifty_op directly instead
7064         of trying to emit ashlsi3_n.
7065
7066 2012-07-30  Laurynas Biveinis  <laurynas.biveinis@gmail.com>
7067             Steven Bosscher  <steven@gcc.gnu.org>
7068
7069         * gengtype.c (adjust_field_type): Diagnose duplicate "length"
7070         option applications and option being applied to arrays of atomic types.
7071         (walk_type): Allow "atomic" option on strings too.
7072         * dwarf2out.h (struct dw_vec_struct): Use the "atomic" GTY option
7073         for the array field.
7074         * vec.h: Describe the atomic object "A" type of the macros in
7075         the header comment.
7076         (VEC_T_GTY_ATOMIC, DEF_VEC_A, DEF_VEC_ALLOC_A): Define.
7077         * emit-rtl.c (locations_locators_vals): use the atomic object vector.
7078         * doc/gty.texi: Clarify that GTY option "length" is only for
7079         arrays of non-atomic objects.  Fix typo in the description of the
7080         "atomic" option.
7081
7082 2012-07-27  Uros Bizjak  <ubizjak@gmail.com>
7083
7084         * config/i386/i386.c (ix86_avoid_lea_for_addr): Handle
7085         zero-extended addresses.  Return false if the address has less
7086         than two components.
7087         (ix86_split_lea_for_addr): Unconditionally convert target and
7088         all address operands to requested mode.
7089         * config/i386/i386.md (*lea<mode>): Recover operands from curr_insn.
7090         Pass SImode to ix86_split_lea_for_addr when splitting zero-extended
7091         address.
7092         (zero-extended add splitter): New splitter to conditionally split
7093         non-destructive adds.
7094         (*zero_extendsidi2_rex64): Conditionally emit leal instead of movl.
7095
7096 2012-07-28  Alan Modra  <amodra@gmail.com>
7097
7098         PR target/54093
7099         * config/rs6000/rs6000.c (rs6000_secondary_reload): Limit 32-bit
7100         multi-gpr reload to cases where predicate passes.  Do the same for
7101         64-bit multi-gpr reload.
7102
7103 2012-07-27  Nathan Froyd  <froydnj@gcc.gnu.org>
7104
7105         * expmed.h (alg_hash, alg_hash_used_p, sdiv_pow2_cheap,
7106         smod_pow2_cheap, zero_cost, add_cost, neg_cost, shift_cost)
7107         shiftadd_cost, shiftsub0_cost, shiftsub1_cost, mul_cost,
7108         sdiv_cost, udiv_cost, mul_widen_cost, mul_highpart_cost): Delete
7109         macro definitions and re-purpose as inline functions.
7110         (alg_hash_entry_ptr, set_alg_hash_used_p, sdiv_pow2_cheap_ptr,
7111         set_sdiv_pow2_cheap, smod_pow2_cheap_ptr, set_smod_pow2_cheap,
7112         zero_cost_ptr, set_zero_cost, add_cost_ptr, set_add_cost,
7113         neg_cost_ptr, set_neg_cost, shift_cost_ptr, set_shift_cost,
7114         shiftadd_cost_ptr, set_shiftadd_cost, shiftsub0_cost_ptr,
7115         set_shiftsub0_cost, shiftsub1_cost_ptr, set_shiftsub1_cost,
7116         mul_cost_ptr, set_mul_cost, sdiv_cost_ptr, set_sdiv_cost,
7117         udiv_cost_ptr, set_udiv_cost, mul_widen_cost_ptr,
7118         set_mul_widen_cost, mul_highpart_cost_ptr, set_mul_highpart_cost):
7119         New functions.
7120         (convert_cost_ptr): New function, split out from...
7121         (set_convert_cost, convert_cost): ...here.
7122         * expmed.c, tree-ssa-loop-ivopts.c: Update for new functions.
7123         * gimple-ssa-strength-reduction.c: Likewise.
7124
7125 2012-07-20  Ryan Mansfield  <rmansfield@qnx.com>
7126
7127         * gcc.c (main): Move GCC_DRIVER_HOST_INITIALIZATION after
7128         diagnostic_initialize.
7129
7130 2012-07-27  Oleg Endo  <olegendo@gcc.gnu.org>
7131
7132         PR target/54089
7133         * config/sh/sh.c (shiftcosts): Remove case where first operand
7134         is a const_int.  Move COSTS_N_INSNS usage into caller ...
7135         (sh_rtx_costs) ... here.  Return false when shiftcosts cannot be
7136         calculated instead of MAX_COST.
7137
7138 2012-07-27  Richard Guenther  <rguenther@suse.de>
7139
7140         * tree-cfg.c (gimple_can_merge_blocks_p): Do more fine-grained
7141         check whether SSA form is not up-to-date.
7142         * tree-flow.h (name_mappings_registered_p): Remove.
7143         * tree-into-ssa.c (struct repl_map_d): Remove.
7144         (repl_tbl): Likewise.
7145         (struct ssa_name_info): Add repl_set member.
7146         (update_ssa_obstack): New static global.
7147         (get_ssa_name_ann): Initialize repl_set.
7148         (clear_ssa_name_info): Assert age did not wrap.
7149         (repl_map_hash, repl_map_eq, repl_map_free): Remove.
7150         (names_replaced_by): Adjust.
7151         (add_to_repl_tbl): Likewise.
7152         (dump_tree_ssa_stats): Likewise.
7153         (init_update_ssa): Initialize update_ssa_obstack.
7154         (delete_update_ssa): Free update_ssa_obstack.
7155         (name_mappings_registered_p): Remove.
7156         (update_ssa): Adjust.
7157
7158 2012-07-27  Segher Boessenkool  <segher@kernel.crashing.org>
7159
7160         * config/rs6000/constraints.md: Delete "q" constraint.
7161         * config/rs6000/dfp.md (movsd_hardfloat, movsd_softfloat):
7162         Delete the "q" alternative.
7163         * config/rs6000/predicates.md (gpc_reg_operand): Adjust.
7164         * config/rs6000/rs6000.c (rs6000_debug_reg_global)
7165         (rs6000_init_hard_regno_mode_ok, rs6000_dbx_register_number):
7166         adjust to MQ_REGNO removal.
7167         * config/rs6000/rs6000.h (FIRST_PSEUDO_REGISTER): Adjust
7168         comment.
7169         (REG_ALLOC_ORDER): Adjust comment.  Remove MQ from alloc order.
7170         (enum reg_class): Adjust comment.  Delete MQ_REGS.
7171         (REG_CLASS_CONTENTS): Adjust.
7172         (REGISTER_NAMES, ADDITIONAL_REGISTER_NAMES): Adjust comment.
7173         * config/rs6000/rs6000.md: Delete MQ_REGNO.
7174         (movsi_internal1, movsi_internal1_single, movhi_internal,
7175         movqi_internal, movcc_internal1, movsf_hardfloat,
7176         movsf_softfloat): Delete the "q" alternative.
7177         (ctr<mode>_internal1, ctr<mode>_internal2, ctr<mode>_internal5,
7178         ctr<mode>_internal6): Delete "q" constraint.
7179
7180 2012-07-27  Richard Guenther  <rguenther@suse.de>
7181
7182         * tree-into-ssa.c (def_blocks_p): New typedef.
7183         (insert_phi_nodes_compare_def_blocks): New function.
7184         (insert_phi_nodes): Do not walk over referenced vars, instead
7185         walk over recorded def_blocks, record relevant ones and sort
7186         them to avoid repeated hashtable lookups.
7187
7188 2012-07-27  Richard Guenther  <rguenther@suse.de>
7189
7190         * doc/invoke.texi (min-virtual-mappings, virtual-mappings-ratio):
7191         Remove param documentation.
7192         * params.def (PARAM_MIN_VIRTUAL_MAPPINGS,
7193         PARAM_VIRTUAL_MAPPINGS_TO_SYMS_RATIO): Remove.
7194         * tree-flow.h (mark_set_for_renaming): Remove.
7195         * tree-into-ssa.c (struct update_ssa_stats_d): Remove.
7196         (add_new_name_mapping): Remove bookkeeping code.
7197         (dump_update_ssa): Remove stats dumping code.
7198         (init_update_ssa): Remove stats allocation code.
7199         (delete_update_ssa): Remove stats freeing code.
7200         (mark_set_for_renaming): Remove.
7201         (switch_virtuals_to_full_rewrite_p): Likewise.
7202         (switch_virtuals_to_full_rewrite): Likewise.
7203         (update_ssa): Do not call switch_virtuals_to_full_rewrite.
7204
7205 2012-07-27  Marek Polacek  <polacek@redhat.com>
7206
7207         * cgraphunit.c: Rename varpool_finalize_variable to
7208         varpool_finalize_decl in a comment.
7209
7210 2012-07-27  Segher Boessenkool  <segher@kernel.crashing.org>
7211
7212         * common/config/rs6000/rs6000-common.c (rs6000_handle_option):
7213         Delete code for -mno-power, -mpower, and -mpower2.
7214         * config/rs6000/aix43.h (NON_POWERPC_MASKS): Delete.
7215         (SUBTARGET_OVERRIDE_OPTIONS): Delete check for POWER together
7216         with -maix64.
7217         (ASM_CPU_SPEC): Delete support for POWER and POWER2.
7218         * config/rs6000/aix51.h (NON_POWERPC_MASKS): Delete.
7219         (SUBTARGET_OVERRIDE_OPTIONS): Delete check for POWER together
7220         with -maix64.
7221         (ASM_CPU_SPEC): Delete support for POWER and POWER2.
7222         * config/rs6000/aix52.h (NON_POWERPC_MASKS): Delete.
7223         (SUBTARGET_OVERRIDE_OPTIONS): Delete check for POWER together
7224         with -maix64.
7225         (TARGET_POWER): Delete.
7226         * config/rs6000/aix53.h (NON_POWERPC_MASKS): Delete.
7227         (SUBTARGET_OVERRIDE_OPTIONS): Delete check for POWER together
7228         with -maix64.
7229         (TARGET_POWER): Delete.
7230         * config/rs6000/aix61.h (NON_POWERPC_MASKS): Delete.
7231         (SUBTARGET_OVERRIDE_OPTIONS): Delete check for POWER together
7232         with -maix64.
7233         (TARGET_POWER): Delete.
7234         * config/rs6000/darwin.h (TARGET_POWER): Delete.
7235         * config/rs6000/driver-rs6000.c (struct asm_names): Delete
7236         support for -mpower, -mpower2, and -mno-power.
7237         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros):
7238         Likewise.
7239         (rs6000_cpu_cpp_builtins): Likewise.
7240         * config/rs6000/rs6000-cpus.def: Likewise.
7241         * config/rs6000/rs6000-tables.opt: Regenerate.
7242         * config/rs6000/rs6000.c (POWER_MASKS): Delete.
7243         (rs6000_option_override_internal): Adjust.
7244         (rs6000_conditional_register_usage): Adjust.
7245         (rs6000_emit_move): Adjust.
7246         (rs6000_common_init_builtins): Adjust.
7247         (rs6000_init_libfuncs): Adjust.
7248         (rs6000_output_function_prologue): Adjust.
7249         (rs6000_adjust_cost): Adjust.
7250         (struct rs6000_opt_masks): Delete MASK_POWER and MASK_POWER2.
7251         * config/rs6000/rs6000.h (ASM_CPU_SPEC): Delete support for
7252         POWER and POWER2.
7253         (TARGET_DEFAULT): Adjust.
7254         (PROCESSOR_POWER): Delete.
7255         (SHIFT_COUNT_TRUNCATED): Adjust.
7256         * config/rs6000/rs6000.md (extendqisi2): Delete POWER support.
7257         (extendqisi2_power): Delete.
7258         (extendqisi2_no_power): Adjust.
7259         (extendqihi2, extendqihi2_power, extendqihi2_no_power):
7260         Likewise.
7261         (sminsi3, smaxsi3, uminsi3, umaxsi3): Adjust.
7262         (anonymous doz insn patterns): Delete.
7263         (abssi2): Adjust.
7264         (abssi2_power): Delete.
7265         (abssi2_nopower): Adjust.
7266         (nabs_power, nabs_nopower): Likewise.
7267         (mulsi3, mulsi3_mq, mulsi3_no_mq, mulsi3_mq_internal1):
7268         Likewise.  Delete anonymous post-reload splitter.
7269         (mulsi3_no_mq_internal1): rename to...
7270         (mulsi3_internal1): New define_insn.
7271         (mulsi3_mq_internal2, mulsi3_no_mq_internal2, mulsi3_internal2):
7272         Likewise.
7273         (divmodsi4, divmodsi4_internal, udiv<mode>3, udivsi3_mq,
7274         udivsi3_no_mq, udivsi3, div<mode>3, divsi3_mq, div<mode>3_no_mq,
7275         udivmodsi4_normal, udivmodsi4_tests, udivmodsi4): Likewise.
7276         (mulh_call, mull_call, divss_call, divus_call, quoss_call,
7277         quous_call): Likewise.
7278         (maskir_internal1, maskir_internal2, maskir_internal3,
7279         maskir_internal4, maskir_internal5, maskir_internal6,
7280         maskir_internal7, maskir_internal8): Delete.
7281         (ashlsi3, ashlsi3_power, ashlsi3_no_power): Adjust.
7282         (anonymous sl insn patterns): Delete.
7283         (lshrsi3, lshrsi3_power, lshrsi3_no_power): Adjust.
7284         (lshrsi3_64): Adjust.
7285         (anonymous sr insn patterns): Delete.
7286         (anonymous rrib insn patterns): Delete.
7287         (ashrsi3, ashrsi3_power, ashrsi3_no_power): Adjust.
7288         (anonymous sra insn patterns): Delete.
7289         (sqrtsf2, sqrtdf2, sqrtdf2_fpr): Adjust.
7290         (fix_trunc<mode>si2, fix_trunc<mode>si2_internal,
7291         fctiwz_<mode>): Adjust.
7292         (mulsidi3, mulsidi3_mq, mulsidi3_no_mq, umulsidi3, umulsidi3_mq,
7293         umulsidi3_no_mq, smulsi3_highpart, smulsi3_highpart_mq,
7294         smulsi3_highpart_no_mq, umulsi3_highpart, umulsi3_highpart_mq,
7295         umulsi3_highpart_no_mq): Adjust.
7296         (ashldi3_power, lshrdi3_power, ashrdi3_power): Delete.
7297         (ashrdi3_no_power, ashldi3, ashldi3_internal1,
7298         lshrdi3_internal1): Adjust.
7299         (fix_trunctfsi2, fix_trunctfsi2_fprs): Adjust.
7300         (movti_power): Delete.
7301         (movti_string): Adjust.
7302         (stmsi8, stmsi7, stmsi6, stmsi5, stmsi4, stmsi3): Adjust.
7303         (stmsi8_power, stmsi7_power, stmsi6_power, stmsi5_power,
7304         stmsi4_power, stmsi3_power): Delete.
7305         (anonymous movmemsi insn patterns): Adjust.
7306         (lfq_power2, stfq_power2): Delete.
7307         (eq<mode>, eq<mode>_compare): Adjust.
7308         (eqsi_power): Delete.
7309         (ne0si): Adjust.
7310         (anonymous le, lt, ge, gt insn patterns): Delete.
7311         * config/rs6000/rs6000.opt (mpower, mno-power, mpower2): Delete.
7312         * config/rs6000/sysv4.h (TARGET_POWER): Delete.
7313         * config/rs6000/t-aix43 (MULTILIB_OPTIONS, MULTILIB_DIRNAMES,
7314         MULTILIB_MATCHES): Adjust.
7315         * doc/invoke.texi (RS/6000 and PowerPC Options): Delete
7316         -mpower, -mno-power, -mpower2, -mno-power2 documentation.
7317         Delete -mcpu=power and -mcpu=power2 documentation.
7318
7319 2012-07-27  Segher Boessenkool  <segher@kernel.crashing.org>
7320
7321         * config/rs6000/601.md: New file.
7322         * config/rs6000/aix43.h (ASM_CPU_SPEC): Delete support for
7323         RIOS CPUs.
7324         * config/rs6000/aix51.h (ASM_CPU_SPEC): Likewise.
7325         * config/rs6000/driver-rs6000.c (detect_processor_aix,
7326         struct asm_names): Likewise.
7327         * config/rs6000/rios1.md: Delete file.
7328         * config/rs6000/rios2.md: Delete file.
7329         * config/rs6000/rs6000-cpus.def: Delete definitions for RIOS
7330         CPUs.
7331         * config/rs6000/rs6000-opts.h (enum processor_type): Delete
7332         PROCESSOR_RIOS1 and PROCESSOR_RIOS2.
7333         * config/rs6000/rs6000-tables.opt: Regenerated.
7334         * config/rs6000/rs6000.c (struct rios1_cost, struct rios2_cost):
7335         Delete.
7336         (rs6000_option_override_internal): Delete support for RIOS CPUs.
7337         (rs6000_conditional_register_usage): Adjust comment.
7338         (rs6000_issue_rate):Delete support for RIOS CPUs.
7339         * config/rs6000/rs6000.h (ASM_CPU_SPEC): Delete support for
7340         RIOS CPUs.
7341         (PROCESSOR_POWER): Change to PROCESSOR_PPC601.
7342         (PROCESSOR_DEFAULT): Change to PROCESSOR_PPC603.
7343         * config/rs6000/rs6000.md (define_attr "cpu"): Delete rios1
7344         and rios2.
7345         (include "rios1.md", include "rios2.md"): Delete.
7346         (include "601.md"): New.
7347         * config/rs6000/rs6000.opt (enum rs6000_cpu): Default to
7348         PROCESSOR_PPC603.
7349         * config/rs6000/t-aix43 (MULTILIB_MATCHES): Delete support
7350         for RIOS CPUs.
7351         * config/rs6000/t-rs6000 (MD_INCLUDES): Delete rios1.md and
7352         rios2.md .  Add 601.md .
7353
7354 2012-07-26  Richard Henderson  <rth@redhat.com>
7355
7356         * doc/extend.texi (attribute): Document hot/cold for labels.
7357         * predict.c (tree_estimate_probability_bb): Handle hot/cold
7358         attributes on user labels.
7359         * predict.def (PRED_HOT_LABEL, PRED_COLD_LABEL): New.
7360
7361 2012-07-26  Andrew Jenner  <andrew@codesourcery.com>
7362             Sandra Loosemore  <sandra@codesourcery.com>
7363
7364         * cse.c (find_comparison_args): Check for cycles of any length.
7365
7366 2012-07-26  Nick Clifton  <nickc@redhat.com>
7367
7368         * config/mn10300/mn10300.c (REG_SAVE_BYTES): Delete.
7369         (mn10300_get_live_callee_saved_regs): If requested return a count
7370         of the number of bytes in the mask.
7371         (mn10300_expand_prologue): Add argument to invocation of
7372         mn10300_get_live_callee_regs.
7373         (mn10300_expand_epilogue): Compute reg_save_bytes by calling
7374         mn10300_get_live_callee_saved_regs.
7375         (mn10300_initial_offset): Likewise.
7376         * config/mn10300/mn10300-protos.h (mn10300_get_live_callee_saved_regs):
7377         Update prototype.
7378         * config/mn10300/mn10300.md (return_ret): Add argument to
7379         invocation of mn10300_get_live_callee_saved_regs.
7380
7381 2012-07-26  Steven Bosscher  <steven@gcc.gnu.org>
7382
7383         PR regression/54084
7384         * sel-sched-ir.c (cmp_v_in_regset_pool): Clarify logic, fix
7385         pointer difference check.
7386
7387 2012-07-26  Bill Schmidt  <wschmidt@linux.ibm.com>
7388
7389         * tree-ssa-loop-ivopts.c (mbc_entry_hash): Remove.
7390         (mbc_entry_eq): Likewise.
7391         (mult_costs): Likewise.
7392         (cost_tables_exist): Likewise.
7393         (initialize_costs): Likewise.
7394         (finalize_costs): Likewise.
7395         (tree_ssa_iv_optimize_init): Remove call to initialize_costs.
7396         (add_regs_cost): Remove.
7397         (multiply_regs_cost): Likewise.
7398         (add_const_cost): Likewise.
7399         (extend_or_trunc_reg_cost): Likewise.
7400         (negate_reg_cost): Likewise.
7401         (struct mbc_entry): Likewise.
7402         (multiply_by_const_cost): Likewise.
7403         (get_address_cost): Change add_regs_cost calls to add_cost lookups;
7404         change multiply_by_const_cost to mult_by_coeff_cost.
7405         (force_expr_to_var_cost): Likewise.
7406         (difference_cost): Change multiply_by_const_cost to mult_by_coeff_cost.
7407         (get_computation_cost_at): Change add_regs_cost calls to add_cost
7408         lookups; change multiply_by_const_cost to mult_by_coeff_cost.
7409         (determine_iv_cost): Change add_regs_cost calls to add_cost lookups.
7410         (tree_ssa_iv_optimize_finalize): Remove call to finalize_costs.
7411         * tree-ssa-address.c (expmed.h): New #include.
7412         (most_expensive_mult_to_index): Change multiply_by_const_cost to
7413         mult_by_coeff_cost.
7414         * gimple-ssa-strength-reduction.c (expmed.h): New #include.
7415         (stmt_cost): Change to use mult_by_coeff_cost, mul_cost, add_cost,
7416         neg_cost, and convert_cost instead of IVOPTS interfaces.
7417         (execute_strength_reduction): Remove calls to initialize_costs and
7418         finalize_costs.
7419         * expmed.c (struct init_expmed_rtl): Add convert rtx_def.
7420         (init_expmed_one_mode): Initialize convert rtx_def; initialize
7421         x_convert_cost for related modes.
7422         (mult_by_coeff_cost): New function.
7423         * expmed.h (NUM_MODE_INT): New #define.
7424         (struct target_expmed): Add x_convert_cost matrix.
7425         (set_convert_cost): New inline function.
7426         (convert_cost): Likewise.
7427         (mult_by_coeff_cost): New extern decl.
7428         * tree-flow.h (initialize_costs): Remove decl.
7429         (finalize_costs): Likewise.
7430         (multiply_by_const_cost): Likewise.
7431         (add_regs_cost): Likewise.
7432         (multiply_regs_cost): Likewise.
7433         (add_const_cost): Likewise.
7434         (extend_or_trunc_reg_cost): Likewise.
7435         (negate_reg_cost): Likewise.
7436         * Makefile.in (gimple-ssa-strength-reduction.o): Update dependencies.
7437         (tree-ssa-address.o): Update dependencies.
7438
7439 2012-07-26  Steven Bosscher  <steven@gcc.gnu.org>
7440
7441         * bitmap.h: Add explanation of sparse set as linked-list bitmap.
7442         * sbitmap.h: Add explanation about non-sparse sets as simple bitmap.
7443         (TEST_BIT): Make a static inline function for stronger type checking.
7444         (SET_BIT): Don't handle sbitmaps with popcount.
7445         (RESET_BIT): Likewise.
7446         (SET_BIT_WITH_POPCOUNT): New, like SET_BIT but with popcount.
7447         (RESET_BIT_WITH_POPCOUNT): New, like RESET_BIT but with popcount.
7448         * ebitmap.c (ebitmap_clear_bit): Use SET_BIT_WITH_POPCOUNT and
7449         RESET_BIT_WITH_POPCOUNT on wordmask bitmaps.
7450         (ebitmap_set_bit, ebitmap_and_into, ebitmap_and, ebitmap_ior_into,
7451         ebitmap_and_compl_into, ebitmap_and_compl): Likewise.
7452         * sparseset.h: Add explanation of sparse set representation.
7453
7454 2012-07-26  Richard Guenther  <rguenther@suse.de>
7455
7456         PR tree-optimization/54098
7457         * tree-vrp.c (vrp_visit_phi_node): Iterate once more if the
7458         original range was UNDEFINED.
7459
7460 2012-07-26  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
7461
7462         * config/arm/neon.ml (ops): Fix regexp for vld1Q_dups64 and
7463         vld1Q_dupu64 tests.
7464
7465 2012-07-26  Oleg Endo  <olegendo@gcc.gnu.org>
7466
7467         PR target/51244
7468         * config/sh/sh.opt (mzdcbranch): New option.
7469         * doc/invoke.texi: Document it.
7470         * config/sh/sh.md (negsi_cond): Use TARGET_ZDCBRANCH as condition
7471         instead of TARGET_HARD_SH4.
7472         * config/sh/sh.c (sh_option_override): Set TARGET_ZDCBRANCH as default
7473         for TARGET_HARD_SH4.
7474
7475 2012-07-25  Oleg Endo  <olegendo@gcc.gnu.org>
7476
7477         PR target/54089
7478         * config/sh/predicates.md (shift_count_operand): Handle not-SHMEDIA
7479         case.
7480         (p27_shift_count_operand, not_p27_shift_count_operand): New predicates.
7481         * config/sh/sh.md (ashlsi3): Remove parallel and T_REG clobber
7482         from expander.  Do not emit shift insn for not-SHMEDIA case.
7483         (ashlsi3_std): Replace with ...
7484         (ashlsi3_k, ashlsi3_d): ... these new insns.
7485         * config/sh/sh.c (gen_ashift): Make static.  Add sanity checks.
7486         Emit ashlsi3_k insn instead of ashlsi3_std in ASHIFT case.
7487         (gen_ashift_hi): Make static.
7488         * config/sh/sh-protos.h (gen_ashift, gen_ashift_hi): Remove forward
7489         declaration.
7490
7491 2012-07-25  Bharathi Seshadri  <bseshadr@cisco.com>
7492             Jim Wilson  <jimwilso@cisco.com>
7493
7494         * config/arm/bpabi.h (BE8_LINK_SPEC): Set according to
7495         TARGET_BIG_ENDIAN_DEFAULT.
7496
7497 2012-07-25  Eric Botcazou  <ebotcazou@adacore.com>
7498
7499         * gimple-low.c (lower_try_catch): New function.
7500         (lower_stmt) <GIMPLE_TRY>: Use it to lower GIMPLE_TRY_CATCH.
7501         <GIMPLE_CATCH>: Delete.
7502         <GIMPLE_EH_FILTER>: Likewise.
7503
7504 2012-07-25  Eric Botcazou  <ebotcazou@adacore.com>
7505
7506         * expr.c (expand_expr_real_1): Do not expand operand #1 and #2
7507         of BIT_FIELD_REF for ignored results.
7508         * fold-const.c (fold_ternary_loc) <BIT_FIELD_REF>: Check that the
7509         CONSTRUCTOR has vector type before using vector accessors on it.
7510         * gimplify.c (gimplify_compound_lval): Do not gimplify operand #1 and
7511         #2 of BIT_FIELD_REF.
7512         (gimplify_expr) <BIT_FIELD_REF>: Likewise.
7513         * tree-nested.c (convert_nonlocal_reference_op) <BIT_FIELD_REF>: Do
7514         not process operand #1 and #2.
7515         (convert_local_reference_op): Likewise.
7516         * tree-ssa-pre.c (create_component_ref_by_pieces_1): Remove superfluous
7517         breaks throughout.
7518         <BIT_FIELD_REF>: Reuse operand #1 and #2 directly.
7519         * tree.c (stabilize_reference) <BIT_FIELD_REF>: Do not stabilize
7520         operand #1 and #2.
7521         (UPDATE_FLAGS): Do not consider operand #2 of BIT_FIELD_REF.
7522         (build6_stat): Delete.
7523         * tree.h (build6_stat, build6, build6_stat_loc, build6_loc): Likewise.
7524
7525 2012-07-25 Marc Glisse <marc.glisse@inria.fr>
7526
7527         PR tree-optimization/30318
7528         * tree-vrp.c (extract_range_from_binary_expr_1) [PLUS_EXPR]:
7529         Handle __int128.
7530         [MINUS_EXPR]: Merge with PLUS_EXPR.
7531
7532 2012-07-25  Sandra Loosemore  <sandra@codesourcery.com>
7533             Paul Brook  <paul@codesourcery.com>
7534
7535         PR target/53633
7536         * target.def (warn_func_return): New hook.
7537         * doc/tm.texi.in (TARGET_WARN_FUNC_RETURN): New hook.
7538         * doc/tm.texi: Regenerate.
7539         * doc/sourcebuild.texi (Effective-Target Keywords): Document
7540         naked_functions.
7541         * ipa-pure-const.c (warn_function_noreturn): Check
7542         targetm.warn_func_return.
7543         * tree-cfg.c (execute_warn_function_return): Likewise.
7544         * config/spu/spu.c (spu_warn_func_return): New.
7545         (TARGET_WARN_FUNC_RETURN): Define.
7546         * config/rx/rx.c (rx_warn_func_return): New.
7547         (TARGET_WARN_FUNC_RETURN): Define.
7548         * config/avr/avr.c (avr_warn_func_return): New.
7549         (TARGET_WARN_FUNC_RETURN): Define.
7550         * config/arm/arm.c (arm_warn_func_return): New.
7551         (TARGET_WARN_FUNC_RETURN): Define.
7552         * config/mcore/mcore.c (mcore_warn_func_return): New.
7553         (TARGET_WARN_FUNC_RETURN): Define.
7554         (saved_warn_return_type, saved_warn_return_type_count): Remove.
7555         (mcore_reorg, mcore_handle_naked_attribute): Remove warn_return hack.
7556
7557 2012-07-25  Siddhesh Poyarekar  <siddhesh@redhat.com>
7558
7559         * final.c [ASSEMBLER_DIALECT](do_assembler_dialects): New
7560         function to implement assembler dialects.
7561         (output_asm_insn): Use do_assembler_dialects.
7562         (asm_fprintf): Likewise.
7563
7564 2012-07-25  Richard Henderson  <rth@redhat.com>
7565
7566         PR bootstrap/54092
7567         * libfuncs.h: Don't include optabs.h.
7568         (struct libfunc_entry): Use "int" for op, mode1, mode2 members.
7569         * optabs.c (hash_libfunc): Don't cast members to int.
7570         * Makefile.in (LIBFUNCS_H): Don't include OPTABS_H.
7571
7572 2012-07-25  Dodji Seketeli  <dodji@redhat.com>
7573
7574         * basic-block.c: Fix typo in comment.
7575
7576 2012-07-25  Kirill Yukhin  <kirill.yukhin@intel.com>
7577             Michael Zolotukhin  <michael.v.zolotukhin@intel.com>
7578
7579         * common/config/i386/i386-common.c (OPTION_MASK_ISA_PRFCHW_SET): New.
7580         (OPTION_MASK_ISA_PRFCHW_UNSET): Likewise.
7581         (ix86_handle_option): Handle mprfchw option.
7582         * config.gcc (i[34567]86-*-*): Add prfchwintrin.h.
7583         (x86_64-*-*): Likewise.
7584         * config/i386/prfchwintrin.h: New header.
7585         * config/i386/cpuid.h (bit_PRFCHW): New.
7586         (bit_BMI): Formatting fix.
7587         (bit_HLE): Likewise.
7588         (bit_RTM): Likewise.
7589         * config/i386/driver-i386.c (host_detect_local_cpu): Detect
7590         PREFETCHW support.
7591         * config/i386/i386-c.c: Define __PRFCHW__ if needed.
7592         * config/i386/i386.c (ix86_target_string): Define
7593         -mprfchw option. Formatting fixes.
7594         (PTA_HLE): Formatting fix.
7595         (PTA_PRFCHW): New.
7596         (ix86_option_override_internal): Handle new option.
7597         (ix86_valid_target_attribute_inner_p): Add OPT_mprfchw.
7598         * config/i386/i386.h (TARGET_PRFCHW): New.
7599         * config/i386/i386.md (prefetch): Enable for TARGET_PRFCHW.
7600         * config/i386/i386.opt (mprfchw): New.
7601         * config/i386/mm3dnow.h: Move _m_prefetchw from here to prfchwintrin.h.
7602         * config/i386/x86intrin.h: Include prfchwintrin.h.
7603
7604 2012-07-25 Sergey Melnikov <sergey.melnikov@intel.com>
7605
7606         * config/i386/i386.md (stack_protect_set): Disable the pattern
7607         for Android since Android libc (bionic) does not provide random
7608         value for stack protection guard at gs:0x14. Guard value
7609         will be provided from external symbol (default implementation).
7610         (stack_protect_set_<mode>): Likewise.
7611         (stack_protect_test): Likewise.
7612         (stack_protect_test_<mode>): Likewise.
7613         * gcc/defaults.h: Define macro TARGET_HAS_BIONIC to 0 - target does
7614         not have Bionic by default
7615         * config/linux.h: Redefine macro TARGET_HAS_BIONIC to (OPTION_BIONIC)
7616         Macro OPTION_BIONIC is defined in this file and provides Bionic
7617         accessibility status
7618
7619 2012-07-25  Steven Bosscher  <steven@gcc.gnu.org>
7620
7621         * gimple-pretty-print.c (gimple_dump_bb_buff): Call pp_flush.
7622
7623 2012-07-25  Venkataramanan Kumar  <venkataramanan.kumar@amd.com>
7624
7625         btver2 Enablement
7626         * config.gcc (i[34567]86-*-linux* | ...): Add btver2.
7627         (case ${target}): Add btver2.
7628         * config/i386/driver-i386.c (host_detect_local_cpu): Let
7629         -march=native recognize btver2 processors.
7630         * config/i386/i386-c.c (ix86_target_macros_internal): Add
7631         btver2 def_and_undef
7632         * config/i386/i386.c (struct processor_costs btver2_cost): New
7633         btver2 cost table.
7634         (m_BTVER2): New definition.
7635         (m_AMD_MULTIPLE): Includes m_BTVER2.
7636         (initial_ix86_tune_features): Add btver2 tune.
7637         (processor_target_table): Add btver2 entry.
7638         (static const char *const cpu_names): Add btver2 entry.
7639         (software_prefetching_beneficial_p): Add btver2.
7640         (ix86_option_override_internal): Add btver2 instruction sets.
7641         (ix86_issue_rate): Add btver2.
7642         (ix86_adjust_cost): Add btver2.
7643         * config/i386/i386.h (TARGET_BTVER2): New definition.
7644         (enum target_cpu_default): Add TARGET_CPU_DEFAULT_btver2.
7645         (enum processor_type): Add PROCESSOR_BTVER2.
7646         * config/i386/i386.md (define_attr "cpu"): Add btver2.
7647
7648 2012-07-24  Bill Schmidt  <wschmidt@linux.ibm.com>
7649
7650         * doc/tm.texi: Regenerate.
7651         * targhooks.c (default_init_cost): Add prologue and epilogue costs.
7652         (default_add_stmt_cost): Likewise; also handle NULL stmt_info.
7653         (default_finish_cost): Add prologue and epilogue costs.
7654         * targhooks.h (default_add_stmt_cost): Change parameter list.
7655         (default_finish_cost): Likewise.
7656         * target.def (init_cost): Change documentation string.
7657         (add_stmt_cost): Change documentation string and parameter list.
7658         (finish_cost): Likewise.
7659         * target.h (vect_cost_model_location): New enum.
7660         * tree-vectorizer.h (struct _slp_tree): Remove cost substruct.
7661         (struct _slp_instance): Remove cost substruct; rename stmt_cost_vec
7662         to body_cost_vec.
7663         (SLP_INSTANCE_OUTSIDE_OF_LOOP_COST): Remove.
7664         (SLP_INSTANCE_STMT_COST_VEC): Rename to SLP_INSTANCE_BODY_COST_VEC.
7665         (SLP_TREE_OUTSIDE_OF_LOOP_COST): Remove.
7666         (struct _vect_peel_extended_info): Rename stmt_cost_vec to
7667         body_cost_vec.
7668         (struct _stmt_vec_info): Remove cost substruct.
7669         (STMT_VINFO_OUTSIDE_OF_LOOP_COST): Remove.
7670         (stmt_vinfo_set_outside_of_loop_cost): Remove.
7671         (builtin_vectorization_cost): New function.
7672         (vect_get_stmt_cost): Change to use builtin_vectorization_cost.
7673         (add_stmt_cost): Change parameter list.
7674         (finish_cost): Likewise.
7675         (vect_model_simple_cost): Likewise.
7676         (vect_model_store_cost): Likewise.
7677         (vect_model_load_cost): Likewise.
7678         (record_stmt_cost): Likewise.
7679         (vect_get_load_cost): Likewise.
7680         (vect_get_known_peeling_cost): Likewise.
7681         * tree-vect-loop.c (vect_get_known_peeling_cost): Change parameter
7682         list; call record_stmt_cost for prologue and epilogue costs.
7683         (vect_estimate_min_profitable_iters): Call add_stmt_cost for
7684         prologue and epilogue costs; remove computation of vec_outside_cost;
7685         return vec_prologue_cost and vec_epilogue_cost from finish_cost.
7686         (vect_model_reduction_cost): Revise call to add_stmt_cost for body
7687         costs; call add_stmt_cost for prologue and epilogue costs.
7688         (vect_model_induction_cost): Revise call to add_stmt_cost for body
7689         costs; call add_stmt_cost for prologue costs.
7690         * tree-vect-data-refs.c (vect_get_data_access_cost): Change parameter
7691         list for function and arguments for calls to vect_get_load_cost and
7692         vect_get_store_cost.
7693         (vect_peeling_hash_get_lowest_cost): Change argument list for calls to
7694         vect_get_data_access_cost and vect_get_known_peeling_cost; use
7695         temporary vectors prologue_cost_vec and epilogue_cost_vec for the
7696         latter call and discard their results; rename stmt_cost_vec to
7697         body_cost_vec; correct possible storage leak for body_cost_vec.
7698         (vect_peeling_hash_choose_best_peeling): Rename stmt_cost_vec to
7699         body_cost_vec.
7700         (vect_enhance_data_refs_alignment): Rename stmt_cost_vec to
7701         body_cost_vec; add extra dummy parameter on calls to
7702         vect_get_data_access_cost; tolerate null si->stmt; add vect_body to
7703         argument list on call to add_stmt_cost.
7704         * tree-vect-stmts.c (record_stmt_cost): Change parameter list;
7705         rename stmt_cost_vec to body_cost_vec; tolerate null stmt_info; call
7706         builtin_vectorization_cost; add "where" parameter on call to
7707         add_stmt_cost.
7708         (vect_model_simple_cost): Change parameter list; call record_stmt_cost
7709         for prologue costs; remove call to stmt_vinfo_set_outside_of_loop_cost;
7710         rename stmt_cost_vec to body_cost_vec.
7711         (vect_model_promotion_demotion_cost): Add vect_body argument to call
7712         to add_stmt_cost; call add_stmt_cost for prologue costs; remove call
7713         to stmt_vinfo_set_outside_of_loop_cost.
7714         (vect_model_store_cost): Change parameter list; call record_stmt_cost
7715         for prologue costs; add vect_body argument to call to record_stmt_cost;
7716         rename stmt_cost_vec to body_cost_vec; remove call to
7717         stmt_vinfo_set_outside_of_loop_cost.
7718         (vect_get_store_cost): Rename stmt_cost_vec to body_cost_vec; add
7719         vect_body argument to calls to record_stmt_cost.
7720         (vect_model_load_cost): Change parameter list; rename stmt_cost_vec to
7721         body_cost_vec; add vect_body argument to calls to record_stmt_cost;
7722         remove call to stmt_vinfo_set_outside_of_loop_cost.
7723         (vect_get_load_cost): Change parameter list; rename stmt_cost_vec to
7724         body_cost_vec; add vect_body argument to calls to record_stmt_cost;
7725         call record_stmt_cost for prologue costs.
7726         (vectorizable_store): Change argument list for call to
7727         vect_model_store_cost.
7728         (vectorizable_load): Change argument list for call to
7729         vect_model_load_cost.
7730         (new_stmt_vec_info): Remove assignment to
7731         STMT_VINFO_OUTSIDE_OF_LOOP_COST.
7732         * config/spu/spu.c (spu_init_cost): Add prologue and epilogue costs.
7733         (spu_add_stmt_cost): Likewise; also handle NULL stmt_info.
7734         (spu_finish_cost): Add prologue and epilogue costs.
7735         * config/i386/i386.c (i386_init_cost): Add prologue and epilogue costs.
7736         (i386_add_stmt_cost): Likewise; also handle NULL stmt_info.
7737         (i386_finish_cost): Add prologue and epilogue costs.
7738         * config/rs6000/rs6000.c (rs6000_init_cost): Add prologue and epilogue
7739         costs.
7740         (rs6000_add_stmt_cost): Likewise; also handle NULL stmt_info.
7741         (rs6000_finish_cost): Add prologue and epilogue costs.
7742         * tree-vect-slp.c (vect_free_slp_instance): Rename
7743         SLP_INSTANCE_STMT_COST_VEC to SLP_INSTANCE_BODY_COST_VEC.
7744         (vect_create_new_slp_node): Remove assignment to
7745         SLP_TREE_OUTSIDE_OF_LOOP_COST.
7746         (vect_get_and_check_slp_defs): Change parameter list; change argument
7747         lists to calls to vect_model_store_cost and vect_model_simple_cost.
7748         (vect_build_slp_tree): Change parameter list; change argument lists
7749         to calls to vect_model_load_cost, vect_get_and_check_slp_defs, and
7750         recursive self-calls; remove setting of outside_cost from
7751         SLP_TREE_OUTSIDE_OF_LOOP_COST; add vect_body argument to call to
7752         record_stmt_cost.
7753         (vect_analyze_slp_instance): Rename stmt_cost_vec to body_cost_vec;
7754         rename SLP_INSTANCE_STMT_COST_VEC to SLP_INSTANCE_BODY_COST_VEC;
7755         remove assignment to SLP_INSTANCE_OUTSIDE_OF_LOOP_COST; record SLP
7756         prologue costs.
7757         (vect_bb_vectorization_profitable_p): Rename stmt_cost_vec to
7758         body_cost_vec; handle null ci->stmt; add vect_body argument to call
7759         to add_stmt_cost; simplify calls to targetm.vectorize.
7760         builtin_vectorization_cost; return vec_prologue_cost and
7761         vec_epilogue_cost from finish_cost.
7762         (vect_update_slp_costs_according_to_vf): Rename stmt_cost_vec to
7763         body_cost_vec; add vect_body argument to call to add_stmt_cost.
7764
7765 2012-07-24  Richard Henderson  <rth@redhat.com>
7766
7767         * system.h (FIXUNS_TRUNC_LIKE_FIX_TRUNC): Poison.
7768         * config/cris/cris.h (FIXUNS_TRUNC_LIKE_FIX_TRUNC): Remove.
7769         * config/h8300/h8300.h (FIXUNS_TRUNC_LIKE_FIX_TRUNC): Remove.
7770         * config/mn10300/mn10300.h (FIXUNS_TRUNC_LIKE_FIX_TRUNC): Remove.
7771         * config/rs6000/rs6000.h (FIXUNS_TRUNC_LIKE_FIX_TRUNC): Remove
7772         comment reference.
7773         * config/v850/v850.h (FIXUNS_TRUNC_LIKE_FIX_TRUNC): Remove.
7774         * config/v850/v850.md (fixuns_truncsfsi2, fixuns_truncdfsi2): New.
7775         (fix_truncsfsi2, fix_truncdfsi2): Avoid double FIX.
7776         * config/vax/vax.h (FIXUNS_TRUNC_LIKE_FIX_TRUNC): Remove.
7777         * config/vax/vax.md (fixuns_trunc<VAXfp><VAXint>): New.
7778         * doc/tm.texi.in (FIXUNS_TRUNC_LIKE_FIX_TRUNC): Remove.
7779         * doc/tm.texi: Rebuild.
7780
7781 2012-07-24  Richard Henderson  <rth@redhat.com>
7782
7783         * optabs.def: New file.
7784         * Makefile.in (OPTABS_H): Add insn-opinit.h.
7785         (MOSTLYCLEANFILES): Likewise.
7786         (insn-opinit.o): Remove reload.h
7787         (simple_rtl_generated_c): Remove insn-opinit.c.
7788         (s-opinit): New rule.
7789         (build/genopinit.o): Add optabs.def.
7790         * genopinit.c (rtx_upname): New.
7791         (optabs): Extract to optabs.def
7792         (enum optab_tag, struct optab_def_d, optabs): New.
7793         (struct pattern_d, patterns): New.
7794         (match_pattern): Split out from ...
7795         (gen_insn): ... here.  Push matches on patterns vec.
7796         (pattern_cmp, optab_kind_cmp, optab_rcode_cmp): New.
7797         (header_file_name, source_file_name, handle_arg): New.
7798         (open_outfile): New.
7799         (main): Sort and emit new tables.  Generate lookup_handler,
7800         raw_optab_handler, swap_optab_enable.
7801         * libfuncs.h (libfunc_entry): Change "size_t optab" to "optab op".
7802         * optabs.c (code_to_optab_): Remove.
7803         (hash_libfunc): Update for optab name change.
7804         (eq_libfunc): Likewise.
7805         (convert_optab_libfunc): Update computation of optab member;
7806         use the new convlib_def table.
7807         (optab_libfunc): Similarly.
7808         (set_optab_libfunc, set_conv_libfunc): Likewise.
7809         (sign_expand_binop): Use swap_optab_enable instead of fake optabs.
7810         (init_insn_codes, init_optab, init_optabv, init_convert_optab): Remove.
7811         (init_optabs): Don't call them; export the data to optabs.def.
7812         (gen_int_libfunc, gen_fp_libfunc): Export non-static.
7813         (gen_fixed_libfunc, gen_signed_fixed_libfunc): Likewise.
7814         (gen_unsigned_fixed_libfunc, gen_int_fp_libfunc): Likewise.
7815         (gen_intv_fp_libfunc, gen_int_fp_fixed_libfunc): Likewise.
7816         (gen_int_fp_signed_fixed_libfunc, gen_int_fixed_libfunc): Likewise.
7817         (gen_int_signed_fixed_libfunc): Likewise.
7818         (gen_int_unsigned_fixed_libfunc): Likewise.
7819         (gen_interclass_conv_libfunc, gen_int_to_fp_conv_libfunc): Likewise.
7820         (gen_ufloat_conv_libfunc): Likewise.
7821         (gen_int_to_fp_nondecimal_conv_libfunc): Likewise.
7822         (gen_fp_to_int_conv_libfunc, gen_intraclass_conv_libfunc): Likewise.
7823         (gen_trunc_conv_libfunc, gen_extend_conv_libfunc): Likewise.
7824         (gen_fract_conv_libfunc, gen_fractuns_conv_libfunc): Likewise.
7825         (gen_satfract_conv_libfunc, gen_satfractuns_conv_libfunc): Likewise.
7826         (debug_optab_libfuncs): Update for optab representation change.
7827         * optabs.h: Include insn-opinit.h.
7828         (optab, convert_optab, direct_optab): New typedefs.
7829         (struct optab_handlers, struct widening_optab_handlers): Remove.
7830         (struct optab_libcall_d): Rename from optab_d; remove code_,
7831         handlers, widening members.
7832         (struct convert_optab_libcall_d): Rename from convert_optab_d;
7833         remove code_ and handlers members.
7834         (enum optab_index, enum convert_optab_index): Remove.
7835         (enum direct_optab_index): Remove.
7836         (code_to_optab_): Fix array range.
7837         (optab_to_code): Covert to inline function.
7838         (optab_to_code_, convlib_def, normlib_def): Declare.
7839         (raw_optab_handler, swap_optab_enable): Declare.
7840         (unknown_optab): Remove; export to optabs.def
7841         (ssadd_optab, usadd_optab, sssub_optab, ussub_optab, ssmul_optab,
7842         usmul_optab, ssdiv_optab, usdiv_optab, ssneg_optab, usneg_optab,
7843         ssashl_optab, usashl_optab, add_optab, sub_optab, smul_optab,
7844         addv_optab, subv_optab, smul_highpart_optab, umul_highpart_optab,
7845         smul_widen_optab, umul_widen_optab, usmul_widen_optab,
7846         smadd_widen_optab, umadd_widen_optab, ssmadd_widen_optab,
7847         usmadd_widen_optab, smsub_widen_optab, umsub_widen_optab,
7848         ssmsub_widen_optab, usmsub_widen_optab, sdiv_optab, smulv_optab,
7849         sdivv_optab, sdivmod_optab, udiv_optab, udivmod_optab, smod_optab,
7850         umod_optab, fmod_optab, remainder_optab, ftrunc_optab, and_optab,
7851         ior_optab, xor_optab, ashl_optab, lshr_optab, ashr_optab, rotl_optab,
7852         rotr_optab, vashl_optab, vlshr_optab, vashr_optab, vrotl_optab,
7853         vrotr_optab, smin_optab, smax_optab, umin_optab, umax_optab, pow_optab,
7854         atan2_optab, fma_optab, fms_optab, fnma_optab, fnms_optab, mov_optab,
7855         movstrict_optab, movmisalign_optab, storent_optab, neg_optab,
7856         negv_optab, abs_optab, absv_optab, one_cmpl_optab, bswap_optab,
7857         ffs_optab, clz_optab, ctz_optab, clrsb_optab, popcount_optab,
7858         parity_optab, sqrt_optab, sincos_optab, sin_optab, asin_optab,
7859         cos_optab, acos_optab, exp_optab, exp10_optab, exp2_optab, expm1_optab,
7860         ldexp_optab, scalb_optab, significand_optab, logb_optab, ilogb_optab,
7861         log_optab, log10_optab, log2_optab, log1p_optab, floor_optab,
7862         ceil_optab, btrunc_optab, round_optab, nearbyint_optab, rint_optab,
7863         tan_optab, atan_optab, copysign_optab, signbit_optab, isinf_optab,
7864         cmp_optab, ucmp_optab, eq_optab, ne_optab, gt_optab, ge_optab,
7865         lt_optab, le_optab, unord_optab, strlen_optab, cbranch_optab,
7866         cmov_optab, cstore_optab, ctrap_optab, push_optab, addcc_optab,
7867         reduc_smax_optab, reduc_umax_optab, reduc_smin_optab, reduc_umin_optab,
7868         reduc_splus_optab, reduc_uplus_optab, ssum_widen_optab,
7869         usum_widen_optab, sdot_prod_optab, udot_prod_optab, vec_set_optab,
7870         vec_extract_optab, vec_init_optab, vec_shl_optab, vec_shr_optab,
7871         vec_realign_load_optab, vec_widen_umult_hi_optab,
7872         vec_widen_umult_lo_optab, vec_widen_smult_hi_optab,
7873         vec_widen_smult_lo_optab, vec_widen_umult_even_optab,
7874         vec_widen_umult_odd_optab, vec_widen_smult_even_optab,
7875         vec_widen_smult_odd_optab, vec_widen_ushiftl_hi_optab,
7876         vec_widen_ushiftl_lo_optab, vec_widen_sshiftl_hi_optab,
7877         vec_widen_sshiftl_lo_optab, vec_unpacks_hi_optab, vec_unpacks_lo_optab,
7878         vec_unpacku_hi_optab, vec_unpacku_lo_optab, vec_unpacks_float_hi_optab,
7879         vec_unpacks_float_lo_optab, vec_unpacku_float_hi_optab,
7880         vec_unpacku_float_lo_optab, vec_pack_trunc_optab, vec_pack_ssat_optab,
7881         vec_pack_usat_optab, vec_pack_sfix_trunc_optab,
7882         vec_pack_ufix_trunc_optab, powi_optab, sync_compare_and_swap_optab,
7883         sync_lock_test_and_set_optab, sync_old_add_optab, sync_old_sub_optab,
7884         sync_old_ior_optab, sync_old_and_optab, sync_old_xor_optab,
7885         sync_old_nand_optab, sync_new_add_optab, sync_new_sub_optab,
7886         sync_new_ior_optab, sync_new_and_optab, sync_new_xor_optab,
7887         sync_new_nand_optab, sext_optab, zext_optab, trunc_optab, sfix_optab,
7888         ufix_optab, sfixtrunc_optab, ufixtrunc_optab, sfloat_optab,
7889         ufloat_optab, lrint_optab, lround_optab, lfloor_optab, lceil_optab,
7890         fract_optab, fractuns_optab, satfract_optab, satfractuns_optab,
7891         vec_load_lanes_optab, vec_store_lanes_optab, vcond_optab, vcondu_optab,
7892         movcc_optab, reload_in_optab, reload_out_optab, movmem_optab,
7893         setmem_optab, cmpstr_optab, cmpstrn_optab, cmpmem_optab,
7894         sync_lock_release_optab, sync_add_optab, sync_sub_optab,
7895         sync_ior_optab, sync_and_optab, sync_xor_optab, sync_nand_optab,
7896         atomic_exchange_optab, atomic_compare_and_swap_optab,
7897         atomic_load_optab, atomic_store_optab, atomic_add_fetch_optab,
7898         atomic_sub_fetch_optab, atomic_and_fetch_optab,
7899         atomic_nand_fetch_optab, atomic_xor_fetch_optab, atomic_or_fetch_optab,
7900         atomic_fetch_add_optab, atomic_fetch_sub_optab, atomic_fetch_and_optab,
7901         atomic_fetch_nand_optab, atomic_fetch_xor_optab, atomic_fetch_or_optab,
7902         atomic_add_optab, atomic_sub_optab, atomic_and_optab,
7903         atomic_nand_optab, atomic_xor_optab, atomic_or_optab,
7904         atomic_always_lock_free_optab, atomic_is_lock_free_optab,
7905         atomic_thread_fence_optab, atomic_signal_fence_optab,
7906         vec_perm_optab, vec_perm_const_optab): Likewise.
7907         (struct target_optabs): Remove x_optab_table, x_convert_optab_table,
7908         and x_direct_optab_table members; add pat_enable.
7909         (optab_table, convert_optab_table, direct_optab_table): Remove.
7910         (optab_handler): Use raw_optab_handler.
7911         (widening_optab_handler, convert_optab_handler): Likewise.
7912         (set_optab_handler, set_widening_optab_handler): Remove.
7913         (set_convert_optab_handler, set_direct_optab_handler): Remove.
7914         (direct_optab_handler): Defer to optab_handler.
7915         * rtl.h (NON_GENERATOR_NUM_RTX_CODE): New.
7916
7917 2012-07-24  Jason Merrill  <jason@redhat.com>
7918
7919         * bitmap.c (bitmap_descriptor): Adjust order of parameters to
7920         match MEM_STAT_DECL.
7921         * statistics.h (ALONE_FINAL_MEM_STAT_DECL): Correct typo.
7922
7923 2012-07-24  Richard Henderson  <rth@redhat.com>
7924
7925         * optabs.h (struct optab_d): Rename code member to code_.
7926         (struct convert_optab_h): Likewise.
7927         (code_to_optab_): Rename from code_to_optab.
7928         (code_to_optab, optab_to_code): New.
7929         * dojump.c (do_compare_rtx_and_jump): Use code_to_optab.
7930         * ifcvt.c (noce_emit_move_insn): Likewise.
7931         * optabs.c (simplify_expand_binop): Use optab_to_code.
7932         (expand_simple_binop, shift_optab_p, commutative_optab_p): Likewise.
7933         (avoid_expensive_constant, expand_binop_directly): Likewise.
7934         (expand_binop, expand_simple_unop, expand_unop_direct): Likewise.
7935         (expand_unop, prepare_float_lib_cmp, expand_fixed_convert): Likewise.
7936         (have_insn_for, debug_optab_libfuncs): Likewise.
7937         (init_optab, init_optabv, init_convert_optab): Update for optab
7938         member name change.
7939
7940         * libfuncs.h: Include optabs.h.
7941         * dwarf2out.c, lto-streamer.in.c: Don't include libfuncs.h.
7942         * Makefile.in (LIBFUNCS_H): Add OPTABS_H.
7943         (lto-streamer-in.o, dwarf2out.o): Update deps.
7944
7945         * optabs.h (unknown_optab): New.
7946         * builtins.c (interclass_mathfn_icode): Use it.
7947         * dojump.c (do_compare_rtx_and_jump): Likewise.
7948         * optabs.c (optab_for_tree_code, expand_binop): Likewise.
7949         * tree-vect-generic.c (add_rshift, expand_vector_divmod): Likewise.
7950         (expand_vector_operations_1): Likewise.
7951         * tree-vect-patterns.c (vect_recog_divmod_pattern): Likewise.
7952         * tree-vect-stmts.c (supportable_narrowing_operation): Likewise.
7953
7954 2012-07-24  Steven Bosscher  <steven@gcc.gnu.org>
7955
7956         * alloc-pool.c (create_alloc_pool): Fix ENABLE_CHECKING check.
7957
7958 2012-07-24  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
7959
7960         PR target/54051
7961         * config/arm/arm.c (arm_print_operand_address): Remove superfluous
7962         printing of 0.
7963         * config/arm/neon.md ("neon_vld3_lane<mode>":VD): Remove alignment
7964         specifier.
7965         ("neon_vld3_lane<mode>":VMQ): Likewise.
7966         ("neon_vld3_dup<mode>":VDX): Likewise.
7967         ("neon_vst3_lane<mode>":VD): Likewise.
7968         ("neon_vst3_lane<mode>":VMQ): Likewise.
7969
7970 2012-07-24  Roland McGrath  <mcgrathr@google.com>
7971
7972         * arm.c (arm_get_frame_offsets): Don't use fixed regs for
7973         stack alignment padding.
7974
7975 2012-07-24  Uros Bizjak  <ubizjak@gmail.com>
7976
7977         PR target/53961
7978         * config/i386/i386.c (ix86_legitimate_address_p): Move check for
7979         negative constant address for TARGET_X32 ...
7980         (ix86_decompose_address): ... here.  Reject constant addresses
7981         that don't satisfy x86_64_immediate_operand predicate.
7982
7983 2012-07-24  Julian Brown  <julian@codesourcery.com>
7984
7985         * doc/sourcebuild.texi (arm_hf_eabi): Document effective-target check.
7986
7987 2012-07-24  Steven Bosscher  <steven@gcc.gnu.org>
7988
7989         * sbitmap.h (SBITMAP_ELT_BITS): Use "1u" trick as for BITMAP_WORD_BITS.
7990         Move test to check that there is a popcount function for the the number
7991         of bits in SBITMAP_ELT_BITS to sbitmap.c.
7992         * sbitmap.c: Test SBITMAP_ELT_BITS, not HOST_BITS_PER_WIDEST_FAST_INT.
7993         MEM_STAT_INFO): Define in terms of their ALONE counterparts.
7994
7995         * configure.ac (GATHER_STATISTICS): Always define, non-zero if enabled.
7996         * configure: Regenerate.
7997         * statistics.h (GATHER_STATISTICS): Error out if it is not defined.
7998         (GCC_MEM_STAT_ARGUMENTS): New define.
7999         (ALONE_MEM_STAT_DECL): Define in terms of GCC_MEM_STAT_ARGUMENTS.
8000         (ALONE_FINAL_MEM_STAT_DECL, ALONE_FINAL_PASS_MEM_STAT): New defines.
8001         (MEM_STAT_DECL, FINAL_MEM_STAT_DECL, PASS_MEM_STAT,
8002         FINAL_PASS_MEM_STAT): Define.
8003         * ggc-internal.h (ggc_record_overhead): Use FINAL_MEM_STAT_DECL.
8004         * ggc.h (ggc_record_overhead, ggc_free_overhead,
8005         ggc_prune_overhead_list): Remove internal prototypes, they are defined
8006         already in ggc-internal.h.
8007         * ggc-common.c (struct loc_descriptor): Remove #ifdef GATHER_STATISTICS
8008         wrappers.
8009         (add_statistics): Likewise.
8010         (dump_ggc_loc_statistics): Likewise. Return if GATHER_STATISTICS is 0.
8011         * ggc-zone.c (struct page_entry): Remove #ifdef GATHER_STATISTICS
8012         wrappers around "survived" and "stats" members.
8013         (alloc_large_page): Always initialize survived.
8014         (ggc_internal_alloc_zone_stat): Likewise.
8015         Remove #ifdef GATHER_STATISTICS wrappers.  Record overhead if
8016         GATHER_STATISTICS is non-0.
8017         (ggc_free): Convert #ifdef GATHER_STATISTICS to if-code.
8018         (sweep_pages): Always increase survived.
8019         (ggc_collect_1): Convert #ifdef GATHER_STATISTICS to if-code.
8020         (calculate_average_page_survival): Always define.
8021         (ggc_collect): Convert #ifdef GATHER_STATISTICS to if-code.
8022         (ggc_print_statistics): Likewise.
8023         (ggc_pch_read): Likewise.
8024         * ggc-page.c (struct globals): Always define "stats" member.
8025         (ggc_internal_alloc_stat): Convert #ifdef GATHER_STATISTICS to if-code.
8026         (ggc_free): Likewise.
8027         (ggc_collec): Likewise.
8028         (ggc_print_statistics): Likewise.
8029         * bitmap.h (struct bitmap_head_def): Always define "desc" member.
8030         (bitmap_initialize_stat): Convert #ifdef GATHER_STATISTICS to if-code.
8031         * gimple.h (enum gimple_alloc_kind): Always define.
8032         (gimple_alloc_kind): Likewise.
8033         * tree-flow.h (phinodes_print_statistics): Always define.
8034         (ssanames_print_statistics): Likewise.
8035         * vec.h (vec_heap_free): Always define.
8036         (VEC_stack_alloc): Define if GATHER_STATISTICS is non-0.
8037         * alloc-pool.c (alloc_pool_descriptor): Always define.
8038         (create_alloc_pool): Convert #ifdef GATHER_STATISTICS to if-code.
8039         (empty_alloc_pool): Likewise.
8040         (pool_alloc): Likewise.
8041         (pool_free): Likewise.
8042         (dump_alloc_pool_statistics): Likewise.
8043         (print_statistics): Always define.
8044         * bitmap.c (struct bitmap_descriptor): Always define.
8045         (bitmap_register): Pass ALONE_FINAL_PASS_MEM_STAT.
8046         (register_overhead): Always define.
8047         (bitmap_element_free): Convert #ifdef GATHER_STATISTICS to if-code.
8048         (bitmap_element_allocate): Likewise.
8049         (bitmap_elt_clear_from): Likewise.
8050         (bitmap_obstack_alloc_stat): Likewise.
8051         (bitmap_gc_alloc_stat): Likewise.
8052         (bitmap_obstack_free): Likewise.
8053         (bitmap_find_bit): Likewise.
8054         (bitmap_ior_and_into):  Likewise.
8055         (bitmap_print): Likewise.
8056         (dump_bitmap_statistics): Likewise. Return if GATHER_STATISTICS is 0.
8057         * gimple.c (gimple_alloc_counts, gimple_alloc_sizes): Always define.
8058         (gimple_alloc_kind_names): Likewise.
8059         (gimple_alloc_stat): Convert #ifdef GATHER_STATISTICS to if-code.
8060         (dump_gimple_statistics): Likewise. Return if GATHER_STATISTICS is 0.
8061         * rtl.c (rtx_alloc_counts, rtx_alloc_sizes, rtvec_alloc_counts,
8062         rtvec_alloc_sizes): Always define.
8063         (rvec_alloc): Convert #ifdef GATHER_STATISTICS to if-code.
8064         (rtx_alloc_stat): Likewise.
8065         (dump_rtx_statistics): Likewise. Return if GATHER_STATISTICS is 0.
8066         * tree.c (_obstack_allocated_p, tree_code_counts, tree_node_counts,
8067         tree_node_sizes, tree_node_kind_names): Always define.
8068         (record_node_allocation_statistics): Convert #ifdef GATHER_STATISTICS
8069         to if-code.
8070         (type_hash_canon): Likewise.
8071         (dump_tree_statistics): Likewise.
8072         * tree-ssanames.c (ssa_name_nodes_reused, ssa_name_nodes_created):
8073         Always define.
8074         (ssanames_print_statistics): Likewise.
8075         (make_ssa_name_fn): Convert #ifdef GATHER_STATISTICS to if-code.
8076         * tree-phinodes.c (phi_nodes_reused, phi_nodes_created): Always define.
8077         (phinodes_print_statistics): Likewise.
8078         (allocate_phi_node): Convert #ifdef GATHER_STATISTICS to if-code.
8079         * vec.c (struct vec_descriptor): Always define.
8080         (hash_descriptor, eq_descriptor, ptr_hash_entry, hash_ptr, eq_ptr,
8081         vec_descriptor, rester_overhead, free_overhead): Likewise.
8082         (cmp_statistic): Likewise.
8083         (vec_heap_free): Convert #ifdef GATHER_STATISTICS to if-code.
8084         (vec_heap_o_reserve_1): Likewise.
8085         (dump_vec_loc_statistics): Likewise.
8086
8087 2012-07-24  Richard Guenther  <rguenther@suse.de>
8088
8089         PR tree-optimization/53616
8090         * tree-loop-distribution.c (ldist_gen): Do not change
8091         partition ordering when merging partitions.
8092
8093 2012-07-24  Alan Modra  <amodra@gmail.com>
8094
8095         PR target/53914
8096         PR target/54009
8097         * config/rs6000/constraints.md (Y): Use mem_operand_gpr.
8098         * config/rs6000/predicates.md (word_offset_memref_operand): Delete.
8099         Adjust all rs6000_legitimate_offset_address_p calls.
8100         * config/rs6000/rs6000-protos.h (mem_operand_gpr): Declare.
8101         (rs6000_secondary_reload_gpr): Declare.
8102         (rs6000_legitimate_offset_address_p): Update prototype.
8103         (rs6000_offsettable_memref_p): Delete.
8104         (rs6000_secondary_reload_ppc64): Delete.
8105         * config/rs6000/rs6000.c (address_offset): New function.
8106         (mem_operand_gpr): Likewise.
8107         (rs6000_legitimate_offset_address_p): Add worst_case param.  When
8108         not worst_case assume class of regs with least restrictive offsets.
8109         Adjust all calls.
8110         (legitimate_lo_sum_address_p): Simplify register mode tests.
8111         (rs6000_legitimize_address): Likewise.  Assume best case offset
8112         addressing.  Combine ELF and MACHO lo_sum code.
8113         (rs6000_mode_dependent_address): Correct offset addressing limits.
8114         (rs6000_offsettable_memref_p): Make static, add reg_mode param.
8115         Use reg_mode to help rs6000_legitimate_offset_address_p.
8116         (rs6000_secondary_reload): Use address_offset.  Handle 32-bit multi
8117         gpr load/store when offset too large.
8118         (rs6000_secondary_reload_gpr): Renamed rs6000_secondary_reload_ppc64.
8119         (rs6000_split_multireg_move): Adjust rs6000_offsettable_memref_p calls.
8120         * config/rs6000/rs6000.md (movdf_hardfloat32): Use 'Y' constraint
8121         for gpr load/store.  Order alternatives as r->Y,Y->r,r->r and
8122         d->m,m->d,d->d.  Correct size of gpr load/store.
8123         (movdf_softfloat32): Use 'Y' constraint for gpr load/store.  Order
8124         alternatives.
8125         (movti_ppc64): Likewise.
8126         (movdi_internal32): Likewise.  Also disparage fprs.
8127         (movdi_mfpgpr, movdi_internal64): Likewise.
8128         (movtf_internal): Use 'm' for fpr load/store.  Order alternatives.
8129         (movtf_softfloat): Order alternatives.
8130         (extenddftf2_internal): Use 'm' and 'Y' for store.
8131         (movti_power, movti_string): Use 'Y' for gpr load/store.  Order.
8132         (stack_protect_setdi, stack_protect_testdi): Likewise.
8133         (movdf_hardfloat64_mfpgpr, movdf_hardfloat64): Order alternatives.
8134         (movdf_softfloat64): Likewise.
8135         (reload_<mode>_store): Adjust reload_di_store to provide
8136         reload_si_store as well.
8137         (reload_<mode>_load): Likewise.
8138
8139 2012-07-23  Oleg Endo  <olegendo@gcc.gnu.org>
8140
8141         PR target/51244
8142         * config/sh/predicates.md (general_movsrc_operand,
8143         general_movdst_operand): Reject T_REG.
8144         * config/sh/sh.md (*extendqisi2_compact_reg, *extendhisi2_compact_reg,
8145         movsi_i, movsi_ie, movsi_i_lowpart, *movqi_reg_reg, *movhi_reg_reg):
8146         Remove T_REG alternatives.
8147         (*negtstsi): New insn.
8148
8149 2012-07-23  Oleg Endo  <olegendo@gcc.gnu.org>
8150
8151         PR target/53511
8152         * config/sh/sh.md (mulsf3_ie): Delete.
8153         (mulsf3_i4): Rename to mulsf3_i.
8154         (mulsf3): Emit mulsf3_i insn.
8155
8156 2012-07-23  Oleg Endo  <olegendo@gcc.gnu.org>
8157
8158         * config/sh/sh.md (addc1, subc1): Delete.
8159         (adddi3_compact): Use addc instead of addc1.
8160         (subdi3_compact): Use subc instead of subc1.
8161
8162 2012-07-23  Uros Bizjak  <ubizjak@gmail.com>
8163
8164         * config/i386/i386-protos.h (ix86_lea_outperforms): Remove prototype.
8165         * config/i386/i386.c (ix86_lea_outperforms): Make static.  Make
8166         split_cost argument signed.
8167         (ix86_avoid_lea_for_add): Cleanup.
8168         (ix86_use_lea_for_mov): Use INVALID_REGNUM instead of -1.
8169         (ix86_avoid_lea_for_addr): Ditto.  Make split_cost signed.
8170         Use gen_lowpart instead of gen_rtx_SUBREG.  Cleanup.
8171
8172 2012-07-23  Ulrich Weigand  <ulrich.weigand@linaro.org>
8173
8174         * config/arm/arm.c (arm_reorg): Ensure all insns are split.
8175
8176 2012-07-23  Uros Bizjak  <ubizjak@gmail.com>
8177
8178         PR target/53961
8179         * config/i386/i386.md (*lea): Add asserts to detect invalid addresses.
8180         * config/i386/i386.c (ix86_print_operand_address): Ditto.
8181         (ix86_decompose_address): Allow (zero_extend:DI (subreg:SI (...)))
8182         addresses.  Prevent zero extensions of CONST_INT operands.
8183
8184 2012-07-23  Steven Bosscher  <steven@gcc.gnu.org>
8185
8186         * sbitmap.h (struct int_list): Remove.
8187         (sbitmap_intersect_of_predsucc, sbitmap_union_of_predsucc):
8188         Remove prototypes of non-existing function.
8189         (sbitmap_intersect_of_predecessors, sbitmap_intersect_of_successors,
8190         sbitmap_union_of_predecessors, sbitmap_union_of_successors): Remove
8191         unused defines.
8192         (sbitmap_intersection_of_succs, sbitmap_intersection_of_preds,
8193         sbitmap_union_of_succs, sbitmap_union_of_preds): Move prototypes to...
8194         * basic-block.h: ... here.
8195         * sbitmap.c: Do not include basic-block.h.
8196         (sbitmap_intersection_of_succs, sbitmap_intersection_of_preds,
8197         sbitmap_union_of_succs, sbitmap_union_of_preds): Move functions to...
8198         * cfganal.c: ... here.
8199         * bt-load.c (compute_out, link_btr_uses): Update for above changes.
8200         * gcse.c (compute_code_hoist_vbeinout): Likewise.
8201         * lcm.c (compute_antinout_edge, compute_available): Likewise.
8202         * Makefile.in: Fix sbitmap.o dependencies.
8203
8204 2012-07-23  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
8205             Nick Clifton  <nickc@redhat.com>
8206
8207         * config/frv/frv-protos.h (frv_ifcvt_machdep_init): Prototype.
8208         * config/frv/frv.c (frv_ifcvt_machdep_init): Change type of
8209         (unused) parameter to void *.
8210
8211 2012-07-23  Richard Guenther  <rguenther@suse.de>
8212
8213         * tree-ssa-alias.c (dump_alias_info): Walk over local decls
8214         instead of referenced vars.
8215
8216 2012-07-23  Steven Bosscher  <steven@gcc.gnu.org>
8217
8218         * coverage.c: Refer to "notes file" instead of "graph file"
8219         in all comments.  Explain history of bbg prefix.
8220         * gcov-io.h: Likewise.
8221         * gcov.c: Likewise.
8222         (find_source): Likewise in fnotice.
8223         (read_graph_file): Likewise.
8224         (read_count_file): Likewise.
8225         * doc/gcov.texi: Document -fprofile-dir flag.  Add "notes file"
8226         and "data file" explicitly in the explanation of the files.
8227
8228 2012-07-22  Steven Bosscher  <steven@gcc.gnu.org>
8229
8230         PR tree-optimization/53881
8231         * tree-cfg.c (group_case_labels_stmt): Look up the basic block
8232         for each label and compare them instead of labels.
8233
8234 2012-07-22  Steven Bosscher <steven@gcc.gnu.org>
8235
8236         * opts.c (common_handle_option): Do not set
8237         flag_value_profile_transformations for -fprofile-generate.
8238         * profile.c (instrument_values): Use COUNTER_FOR_HIST_TYPE.
8239         (BB_TO_GCOV_INDEX): Remove.
8240         (output_location): Don't use it.
8241         (branch_prob): Likewise.  Don't fiddle with the index of
8242         ENTRY_BLOCK_PTR and EXIT_BLOCK_PTR.  Use clear_aux_for_blocks.
8243         (find_spanning_tree):
8244         * gcov.c (struct function_info): Document that blocks 0 and 1
8245         are the entry resp. exit blocks in gcov, too, like in GCC itself.
8246         (solve_flow_graph): Use ENTRY_BLOCK and EXIT_BLOCK for special
8247         blocks identification.
8248         (output_lines): Likewise.
8249         * value-prof.c (gimple_value_profile_transformations): Do not
8250         test flag_value_profile_transformations again.
8251         (gimple_ic_transform): Take a gimple_stmt_iterator like all other
8252         transformation functions.
8253         (gimple_values_to_profile):
8254         Don't test flag_value_profile_transformations
8255         * tree-profile.c (tree_profiling): Assert that the cgraph is in
8256         the CGRAPH_STATE_IPA_SSA state.
8257         Do not set, or look at, after_tree_profile.
8258         * function.h (struct function): Remove after_tree_profile bit.
8259         * omp-low.c (expand_omp_taskreg): Don't set after_tree_profile.
8260         * tree-inline.c (initialize_cfun): Don't copy it.
8261         * lto-streamer-out.c (output_struct_function_base): Don't stream it.
8262         * lto-streamer-in.c (input_struct_function_base): Likewise.
8263
8264 2012-07-22  Oleg Endo  <olegendo@gcc.gnu.org>
8265
8266         * config/sh/sh.h (TARGET_DYNSHIFT): New macro.
8267         (SH_DYNAMIC_SHIFT_COST): Use it.
8268         * config/sh/sh.c (expand_ashiftrt, shl_sext_kind): Likewise.
8269         (sh_dynamicalize_shift_p): Add TARGET_DYNSHIFT condition.
8270         Add sanity check for input value.  Add function description.
8271         * config/sh/sh.md (ashlsi3, ashlsi3_std, ashrsi3_d, lshrsi3,
8272         lshrsi3_d): Use TARGET_DYNSHIFT.
8273
8274 2012-07-22  Oleg Endo  <olegendo@gcc.gnu.org>
8275
8276         * config/sh/sh.md (negc): Delete expander.
8277         (*negc): Rename insn to negc.
8278
8279 2012-07-22  Uros Bizjak  <ubizjak@gmail.com>
8280
8281         PR target/53961
8282         * config/i386/i386.md (*lea): New insn pattern.
8283         (*lea_1): Remove.
8284         (*lea<mode>_2): Ditto.
8285         (*lea_{3,4,5,6}_zext): Ditto.
8286         * config/i386/predicates.md (lea_address_operand): Do not reject
8287         zero-extended address operands.
8288         * config/i386/constraints.md (j): Remove address constraint.
8289         * config/i386/i386.c (ix86_decompose_address): Allow SImode subreg
8290         of an address.
8291         (ix86_print_operand_address): Handle SImode subreg of an address.
8292         (ix86_avoid_lea_for_addr): Reject zero-extended addresses for now.
8293
8294 2012-07-22  Hans-Peter Nilsson  <hp@axis.com>
8295
8296         Emit executable-stack note correctly for CRIS targets.
8297         * config/cris/cris.c (cris_file_end): New function.
8298         (TARGET_ASM_FILE_END): Define.
8299
8300 2012-07-22  Chung-Lin Tang  <cltang@codesourcery.com>
8301             Maxim Kuvyrkov  <maxim@codesourcery.com>
8302             NetLogic Microsystems Inc.
8303
8304         * config/mips/mips.c (mips_issue_rate): Handle XLP.
8305         * config/mips/mips.md: Include xlp.md.
8306         * config/mips/xlp.md: New file.
8307
8308 2012-07-21  Steven Bosscher <steven@gcc.gnu.org>
8309
8310         PR gcov-profile/32543
8311         * profile.c (branch_prob): Update total_num_edges_instrumented and
8312         report the number of edges to instrument.
8313
8314 2012-07-21  Oleg Endo  <olegendo@gcc.gnu.org>
8315
8316         * config/sh/sh.md: Correct comment regarding clrt and sett insns.
8317
8318 2012-07-21  Andrew Pinski  <apinski@cavium.com>
8319
8320         * config/mips/mips.md (*popcountdi2_trunc): New pattern
8321         to handle popcount of a truncation.
8322
8323 2012-07-21  Andrew Pinski  <apinski@cavium.com>
8324
8325         * config/mips/mips-protos.h (mips_expand_ext_as_unaligned_load):
8326         Add a bool argument.
8327         * config/mips/mips.c (mips_block_move_straight): Update call to
8328         mips_expand_ext_as_unaligned_load.
8329         (mips_expand_ext_as_unaligned_load): Add unsigned_p argument.
8330         Accept DImode dest when the width is that of SImode.
8331         * config/mips/mips.md (extv): Update call to
8332         mips_expand_ext_as_unaligned_load.
8333         (extzv): Likewise.
8334
8335 2012-07-21  Andrew Pinski  <apinski@cavium.com>
8336
8337         * config/mips/mips.c (mips_get_unaligned_mem): Copy *op after calling
8338         adjust_address.
8339
8340 2012-07-20  Maxim Kuvyrkov  <maxim@codesourcery.com>
8341
8342         * config/mips/mips.md (define_attr sync_*): Move before "type".
8343         (define_attr "type"): New values "atomic" and "syncloop".
8344         * config/mips/sync.md (atomic_exchange<mode>, atomic_fetch_add<mode>):
8345         Set "type" attribute.
8346         * config/mips/generic.md (generic_atomic, generic_syncloop):
8347         New reservations.
8348         * gcc/config/mips/10000.md, gcc/config/mips/20kc.md,
8349         * gcc/config/mips/24k.md, gcc/config/mips/4130.md,
8350         * gcc/config/mips/4k.md, gcc/config/mips/5400.md,
8351         * gcc/config/mips/5500.md, gcc/config/mips/5k.md,
8352         * gcc/config/mips/7000.md, gcc/config/mips/74k.md,
8353         * gcc/config/mips/9000.md, gcc/config/mips/loongson2ef.md,
8354         * gcc/config/mips/loongson3a.md, gcc/config/mips/octeon.md,
8355         * gcc/config/mips/sb1.md, gcc/config/mips/sr71k.md,
8356         * gcc/config/mips/xlr.md: Handle "atomic" and "syncloop" types.
8357
8358 2012-07-20  Oleg Endo  <olegendo@gcc.gnu.org>
8359
8360         * config/sh/sh.md: Group and sort shift related patterns.
8361         (ashlsi3_n, *ashlhi3_n, lshrsi3_n): Remove length attributes.
8362
8363 2012-07-20  Hans-Peter Nilsson  <hp@axis.com>
8364
8365         * config/cris/cris.c (cris_asm_output_ident): Remove unused
8366         local variables section_asm_op, size, buf.
8367
8368 2012-07-20  Pat Haugen <pthaugen@us.ibm.com>
8369             Steven Bosscher  <steven@gcc.gnu.org>
8370
8371         * config/rs6000/power4.md (power4-store-update): Fix reservation.
8372         (power4-three): Likewise.
8373
8374 2012-07-20  Sameera Deshpande  <sameera.deshpande@arm.com>
8375             Greta Yorsh  <Greta.Yorsh@arm.com>
8376
8377         * config/arm/arm.c (arm_cortex_a15_tune): New tune.
8378         * config/arm/arm-cores.def (cortex-a15): Use it.
8379
8380 2012-07-20  Sameera Deshpande  <sameera.deshpande@arm.com>
8381             Greta Yorsh  <Greta.Yorsh@arm.com>
8382
8383         * config/arm/arm-protos.h (tune_params): Add prefer_ldrd_strd.
8384         * config/arm/arm.c (arm_slowmul_tune): Initialize it.
8385         (arm_fastmul_tune, arm_strongarm_tune): Likewise.
8386         (arm_xscale_tune, arm_9e_tune, arm_v6t2_tune): Likewise.
8387         (arm_cortex_tune, arm_cortex_a5_tune, arm_cortex_a9_tune): Likewise.
8388         (arm_fa726te_tune): Likewise.
8389
8390 2012-07-20  Richard Guenther  <rguenther@suse.de>
8391
8392         * tree-dfa.c (collect_dfa_stats): Simplify.
8393         * tree-ssa-structalias.c (compute_may_aliases): Do not dump
8394         referenced vars.
8395         * cfgexpand.c (estimated_stack_frame_size): Walk over local
8396         decls instead of referenced vars.
8397         * tree-ssa.c (delete_tree_ssa): Simplify.
8398         * tree-tailcall.c (find_tail_calls): Walk over local decls
8399         instead of referenced vars.
8400         (add_virtual_phis): Remove.
8401         (tree_optimize_tail_calls_1): Instead mark the virtual operand
8402         for renaming.
8403
8404 2012-07-20  Steven Bosscher  <steven@gcc.gnu.org>
8405
8406         * basic-block.h (BB_FLAGS_TO_PRESERVE): New define.
8407         (brief_dump_cfg): Update prototype to take flags argument.
8408         (check_bb_profile): Remove prototype.
8409         * tracer.c (tracer): Update brief_dump_cfg calls.
8410         * cfghooks.c (dump_bb): Do not pass TDF_COMMENT to dump_bb_info.
8411         Call dump_bb_info before and after the cfghook dump_bb.  Terminate
8412         the dump with a newline.
8413         (dump_flow_info): Do not call check_bb_profile.
8414         * cfg.c (clear_bb_flags): Update using BB_FLAGS_TO_PRESERVE.
8415         (check_bb_profile): Make static.  Take indent and flags arguments.
8416         (dump_bb_info): Always dump loop depth.  With TDF_DETAILS, call
8417         check_bb_profile.  Print one edge per line.
8418         (brief_dump_cfg): Take a flags argument, and filter out
8419         TDF_COMMENT and TDF_DETAILS.
8420         * pretty-print.c (pp_base_newline): Set pp_needs_newline to false.
8421         * gimple-pretty-print.c (dump_gimple_bb_header): Do not use
8422         dump_bb_info here, it is already called from dump_bb.  Idem for
8423         check_bb_profile.
8424         (dump_gimple_bb_footer): Likewise.
8425         (gimple_dump_bb_buff): Call pp_flush after dump_gimple_stmt to
8426         avoid broken dumps for statement histograms.
8427         (gimple_dump_bb): Handle ENTRY_BLOCK and EXIT_BLOCK.  Do
8428         not call pp_flush here, the buffer should be empty.
8429         * sched-rgn.c (debug_region): Pass TDF_BLOCKS to dump_bb.
8430         * sched-vis.c (debug_bb_slim): Likewise.
8431         * tree-cfg.c (remove_bb): Pass dump_flags to dump_bb.
8432         (gimple_debug_bb): Pass TDF_BLOCKS to dump_bb.
8433         (gimple_dump_cfg): Do brief_dump_cfg with TDF_COMMENT.
8434         (dump_function_to_file): Do not call check_bb_profile on
8435         ENTRY_BLOCK and EXIT_BLOCK, check_bb_profile doesn't handle them.
8436         Use dump_bb instead of gimple_dump_bb.
8437         (print_loops_bb): Use dump_bb instead of gimple_dump_bb.
8438         * passes.c (execute_function_dump): Always call print_rtl_with_bb
8439         for RTL dumps.
8440         * cfgrtl.c (print_rtl_with_bb): Handle printing without an up-to-date
8441         CFG.  With TDF_BLOCKS and TDF_DETAILS, do DF dumps at the top and
8442         bottom of each basic block.
8443
8444 2012-07-20  Richard Guenther  <rguenther@suse.de>
8445
8446         PR tree-optimization/54031
8447         * tree-ssa-ccp.c (get_value_from_alignment): Use
8448         get_pointer_alignment_1.
8449
8450 2012-07-20  Richard Guenther  <rguenther@suse.de>
8451
8452         * tree-inline.c (add_local_variables): Remove check_var_ann
8453         parameter and dead code.
8454         (expand_call_inline): Adjust.
8455         (tree_function_versioning): Likewise.
8456
8457 2012-07-20  Jakub Jelinek  <jakub@redhat.com>
8458
8459         PR c++/28656
8460         * tree-vrp.c (nonnull_arg_p): Handle all nonnull attributes instead
8461         of just the first one.
8462
8463 2012-07-20  Richard Guenther  <rguenther@suse.de>
8464
8465         * builtins.c (get_object_alignment_2): Correct offset handling
8466         when using type alignment of a MEM_REF kind base.
8467
8468 2012-07-20  Kirill Yukhin  <kirill.yukhin@intel.com>
8469
8470         PR target/53877
8471         * config/i386/lzcntintrin.h (_lzcnt_u32): New.
8472         (_lzcnt_u64): Ditto.
8473
8474 2012-07-19  Eric Botcazou  <ebotcazou@adacore.com>
8475
8476         * config/sparc/sparc.md (adddi3_insn_sp32): Add earlyclobber.
8477
8478 2012-07-19  Eric Botcazou  <ebotcazou@adacore.com>
8479
8480         * tree-ssa-forwprop.c (combine_conversions): Punt if the RHS of the
8481         defining statement is a SSA name that occurs in abnormal PHIs.
8482
8483 2012-07-19  Eric Botcazou  <ebotcazou@adacore.com>
8484
8485         * gimple-fold.c (canonicalize_constructor_val): Strip only useless type
8486         conversions.
8487
8488 2012-07-19  Jakub Jelinek  <jakub@redhat.com>
8489
8490         PR rtl-optimization/53942
8491         * function.c (assign_parm_setup_reg): Avoid zero/sign extension
8492         directly from likely spilled non-fixed hard registers, move them
8493         to pseudo first.
8494
8495 2012-07-19  Steve Ellcey  <sellcey@mips.com>
8496
8497         * config/mips/mips.c (mips_set_mips16_mode): Clear SYNCI_MASK in
8498         MIPS16 mode.
8499
8500 2012-07-19  Jason Merrill  <jason@redhat.com>
8501
8502         PR debug/53235
8503         * dwarf2out.c (get_die_parent): New.
8504         (generate_type_signature): Use it.
8505
8506 2012-07-19  Richard Henderson  <rth@redhat.com>
8507
8508         * config/ia64/vect.md (smulv4hi3_highpart): New.
8509         (umulv4hi3_highpart): New.
8510         (vec_widen_smult_even_v4hi): Rename from pmpy2_even.
8511         (vec_widen_smult_odd_v4hi): Rename from pmpy2_odd.
8512         (udot_prodv8qi, sdot_prodv8qi): Remove.
8513         (sdot_prodv4hi, udot_prodv4hi): Remove.
8514         * config/ia64/ia64.c (ia64_expand_dot_prod_v8qi): Remove.
8515         * config/ia64/ia64-protos.h: Update.
8516
8517         * tree-vect-patterns.c (vect_recog_divmod_pattern): Do not require
8518         vectors larger than UNITS_PER_WORD.
8519
8520         * expr.c (store_constructor): Initialize icode with CODE_FOR_nothing.
8521         * tree-vect-stmts.c (vectorizable_operation): Use LAST_INSN_CODE for
8522         dummy != CODE_FOR_nothing value.
8523
8524 2012-07-19  Uros Bizjak  <ubizjak@gmail.com>
8525
8526         * doc/tm.texi.in (MODE_AFTER): Add entity as the first macro argument.
8527         * doc/tm.texi: Regenerate.
8528         * mode-switching.c (optimize_mode_switching): Update MODE_AFTER call.
8529         * config/sh/sh.h (MODE_AFTER): Update.
8530         * config/epiphany/epiphany.h (MODE_AFTER): Update.
8531
8532 2012-07-19  Jakub Jelinek  <jakub@redhat.com>
8533
8534         PR middle-end/54017
8535         * tree-cfgcleanup.c (cleanup_omp_return): Remove.
8536         (cleanup_tree_cfg_bb): Don't call it.
8537         * omp-low.c (expand_omp_sections): Fix up the !exit_reachable case
8538         handling.
8539
8540 2012-07-19  Christian Bruel  <christian.bruel@st.com>
8541
8542         PR target/54029
8543         * config/sh/sh.c (gen_far_branch): Set JUMP_LABEL for return jumps.
8544
8545 2012-07-19  Richard Guenther  <rguenther@suse.de>
8546             Eric Botcazou  <ebotcazou@adacore.com>
8547
8548         * tree-ssa-ccp.c (valid_lattice_transition): Clarify comment
8549         about transition from invariant to known bits.
8550         (likely_value): Addresses with UNDEFINED components are UNDEFINED.
8551
8552 2012-07-19  Richard Guenther  <rguenther@suse.de>
8553
8554         PR tree-optimization/53970
8555         * tree-vect-data-refs.c (not_size_aligned): Avoid sign-compare warning.
8556
8557 2012-07-19  Tristan Gingold  <gingold@adacore.com>
8558             Richard Henderson  <rth@redhat.com>
8559
8560         * opts.c (finish_options): Handle UI_SEH.
8561         * expr.c (build_personality_function): Handle UI_SEH.
8562         * dwarf2out.c (dwarf2out_begin_prologue): Handle UI_SEH.
8563         * coretypes.h (unwind_info_type): Add UI_SEH.
8564         * config/i386/winnt.c (i386_pe_seh_emit_except_personality):
8565         New function.
8566         (i386_pe_seh_init_sections): Likewise.
8567         * config/i386/cygming.h (TARGET_ASM_EMIT_EXCEPT_PERSONALITY): Define.
8568         (TARGET_ASM_INIT_SECTIONS): Define.
8569         * common/config/i386/i386-common.c (TARGET_EXCEPT_UNWIND_INFO): Define.
8570         (i386_except_unwind_info): New function.
8571
8572 2012-07-18  Maciej W. Rozycki  <macro@codesourcery.com>
8573             Chao-ying Fu  <fu@mips.com>
8574
8575         * config/mips/mips.opt (mmcu): New option.
8576         * config/mips/mips.h (TARGET_CPU_CPP_BUILTINS): Define
8577         _mips_mcu when TARGET_MCU.
8578         (ASM_SPEC): Pass mcu options to the assembler.
8579         * doc/invoke.texi (MIPS Options): Document -mmcu and -mno-mcu.
8580
8581 2012-07-18  Ralf Corsépius  <ralf.corsepius@rtems.org>
8582
8583         * config.gcc (v850-*-rtems*): New target.
8584         * config/v850/rtems.h: New.
8585         * config/v850/t-rtems: New.
8586
8587 2012-07-18  Bill Schmidt  <wschmidt@linux.ibm.com>
8588
8589         * doc/invoke.texi: Add -fhoist-adjacent-loads and -ftree-slsr to list
8590         of flags controlling optimization; add -ftree-slsr to list of flags
8591         enabled by default at -O; add -fhoist-adjacent-loads to list of flags
8592         enabled by default at -O2; add -fvect-cost-model to list of flags
8593         enabled by default at -O3; document -fhoist-adjacent-loads and
8594         -ftree-slsr.
8595         * opts.c (default_option): Make -ftree-slsr default at -O1 and above.
8596         * gimple-ssa-strength-reduction.c (gate_strength_reduction): Use
8597         flag_tree_slsr.
8598         * common.opt: Add -ftree-slsr with flag_tree_slsr.
8599
8600 2012-07-18  Jie Zhang  <jzhang918@gmail.com>
8601             Julian Brown  <julian@codesourcery.com>
8602
8603         * config/arm/arm.c (arm_rtx_costs_1): Adjust cost for CONST_VECTOR.
8604         (arm_size_rtx_costs): Likewise.
8605         (neon_valid_immediate): Add a case for double 0.0.
8606
8607 2012-07-18  Andrew Stubbs  <ams@codesourcery.com>
8608             Mark Shinwell  <shinwell@codesourcery.com>
8609             Julian Brown  <julian@codesourcery.com>
8610
8611         * config/arm/vfp.md (*arm_movsi_vfp, *thumb2_movsi_vfp)
8612         (*movdi_vfp_cortexa8, *movsf_vfp, *thumb2_movsf_vfp)
8613         (*movdf_vfp, *thumb2_movdf_vfp, *movsfcc_vfp)
8614         (*thumb2_movsfcc_vfp, *movdfcc_vfp, *thumb2_movdfcc_vfp): Add
8615         neon_type.
8616         * config/arm/arm.md (neon_type): Update comment.
8617
8618 2012-07-18  Richard Guenther  <rguenther@suse.de>
8619
8620         PR tree-optimization/53970
8621         * tree.h (contains_packed_reference): Remove.
8622         * expr.c (contains_packed_reference): Likewise.
8623         * tree-vect-data-refs.c (not_size_aligned): New function.
8624         (vector_alignment_reachable_p): Use it.
8625         (vect_supportable_dr_alignment): Likewise.
8626
8627 2012-07-18  Richard Guenther  <rguenther@suse.de>
8628
8629         * tree.h (get_object_or_type_alignment): Remove.
8630         * builtins.c (get_object_alignment_2): New function copied from
8631         get_object_alignment_1.  Take extra argument to indicate whether
8632         we take the address of EXP.  Rework to use type alignment information
8633         if not, and return whether the result is an approximation or not.
8634         (get_object_alignment_1): Wrap around get_object_alignment_2.
8635         (get_pointer_alignment_1): Call get_object_alignment_2 indicating
8636         we take the address.
8637         (get_object_or_type_alignment): Remove.
8638         * expr.c (expand_assignment): Call get_object_alignment.
8639         (expand_expr_real_1): Likewise.
8640
8641 2012-07-18  Nick Clifton  <nickc@redhat.com>
8642
8643         * doc/invoke.texi (ARM Options): Document -munaligned-access.
8644
8645 2012-07-18  Oleg Endo  <olegendo@gcc.gnu.org>
8646
8647         * config/sh/sh.md (mulsidi3, umulsidi3): Remove constraints in
8648         expander.  Use arith_reg_dest predicate.
8649         (rotldi3, rotrdi3): Remove constraints in expander.
8650         (adddi3_compact, subdi3_compact, mulsidi3_compact, umulsidi3_compact,
8651         ashlsi3_n, *ashlhi3_n, ashrsi2_16, ashrsi2_31, lshrsi3_n): Convert to
8652         insn_and_split.
8653
8654 2012-07-18  Oleg Endo  <olegendo@gcc.gnu.org>
8655
8656         PR target/33135
8657         * config/sh/sh.opt (mieee): Use Var instead of Mask.  Correct
8658         description.
8659         * config/sh/sh.c (sh_option_override): Do not change
8660         flag_finite_math_only.  Set TARGET_IEEE to complement of
8661         flag_finite_math_only.
8662         * doc/invoke.texi (SH options): Add mno-ieee.  Correct description
8663         of mieee and mno-ieee behavior.
8664
8665 2012-07-18  Steven Bosscher  <steven@gcc.gnu.org>
8666
8667         * graphite-poly.c (print_pbb_body): Fixup dump_bb call.
8668
8669 2012-07-18  Steven Bosscher  <steven@gcc.gnu.org>
8670
8671         * dumpfile.h (TDF_COMMENT): New define.
8672         * basic-block.h (EDGE_FALLTHRU, EDGE_ABNORMAL, EDGE_ABNORMAL_CALL,
8673         EDGE_EH, EDGE_FAKE, EDGE_DFS_BACK, EDGE_CAN_FALLTHRU,
8674         EDGE_IRREDUCIBLE_LOOP, EDGE_SIBCALL, EDGE_LOOP_EXIT, EDGE_TRUE_VALUE,
8675         EDGE_FALSE_VALUE, EDGE_EXECUTABLE, EDGE_CROSSING, EDGE_PRESERVE):
8676         Move to new file cfg-flags.h.
8677         (enum cfg_edge_flags): New enum, using cfg-flags.h.
8678         (EDGE_ALL_FLAGS): Compute value automatically.
8679         (BB_NEW, BB_REACHABLE, BB_IRREDUCIBLE_LOOP, BB_SUPERBLOCK,
8680         BB_DISABLE_SCHEDULE, BB_HOT_PARTITION, BB_COLD_PARTITION,
8681         BB_DUPLICATED, BB_NON_LOCAL_GOTO_TARGET, BB_RTL,
8682         BB_FORWARDER_BLOCK, BB_NONTHREADABLE_BLOCK, BB_MODIFIED, BB_VISITED,
8683         BB_IN_TRANSACTION): Move to new file cfg-flags.h.
8684         (enum bb_flags): Rename to cfg_bb_flags.  Use cfg-flags.h.
8685         (BB_ALL_FLAGS): New, compute value automatically.
8686         (dump_bb_info): Update prototype.
8687         (dump_edge_info): Update prototype.
8688         * cfg-flags.h: New file.
8689         * cfg.c (dump_edge_info): Take flags argument.  Be verbose only if
8690         TDF_DETAILS and not TDF_SLIM.  Include cfg-flags.h for bitnames.
8691         Check that the edge flags are within the range of EDGE_ALL_FLAGS.
8692         (debug_bb): Update dump_bb call.
8693         (dump_cfg_bb_info): Remove.
8694         (dump_bb_info): New function.  Use cfg-flags.h for bitnames.
8695         Adjust verbosity using TDF_* flags.  Check that the basic block flags
8696         are within the range of BB_ALL_FLAGS.
8697         (brief_dump_cfg): Use dump_bb_info instead of dump_cfg_bb_info.
8698         * cfghooks.h (struct cfghooks): Update dump_bb hook, take a FILE
8699         first for consistency with other dump functions.
8700         (dump_bb): Update prototype accordingly.
8701         * cfghooks.c: Include dumpfile.h.
8702         (verify_flow_info): Update dump_edge_info calls.
8703         (dump_bb): Take a flags argument and pass it around.
8704         Use dump_bb_info to dump common information about a basic block.
8705         (dump_flow_info): Moved here from cfgrtl.c.  Make IL agnostic.
8706         (debug_flow_info): Moved here from cfgrtl.c.
8707         * profile.c (is_edge_inconsistent): Update dump_bb calls.
8708         * loop-invariant.c (find_defs): Update print_rtl_with_bb call.
8709         * rtl.h (debug_bb_n_slim, debug_bb_slim, print_rtl_slim,
8710         print_rtl_slim_with_bb): Remove prototypes.
8711         (dump_insn_slim): Adjust prototype to take a const_rtx.
8712         (print_rtl_with_bb): Adjust prototype.
8713         * sched-rgn.c (debug_region): Use dump_bb instead of debug_bb_n_slim.
8714         * sched-vis.c (dump_insn_slim): Take a const_rtx.
8715         (debug_insn_slim): Prototype here near DEBUG_FUNCTION marker.
8716         (print_rtl_slim_with_bb): Remove.
8717         (print_rtl_slim): Rename to debug_rtl_slim.  Print only insn info,
8718         not basic block info (print_rtl_with_bb with TDF_SLIM should be used
8719         for that.  Prototype here near DEBUG_FUNCTION marker.
8720         (debug_bb_slim): Prototype here near DEBUG_FUNCTION marker.
8721         Use dump_bb.
8722         (debug_bb_n_slim): Prototype here near DEBUG_FUNCTION marker.
8723         * tree-cfg.c (gimple_can_merge_blocks_p): Use EDGE_COMPLEX.
8724         (remove_bb): Update dump_bb call.
8725         (gimple_debug_bb): Use dump_bb.
8726         (dump_function_to_file): Update gimple_dump_bb call.
8727         (print_loops_bb): Likewise.
8728         * tree-flow.h (gimple_dump_bb): Update prototype.
8729         * gimple-pretty-print.c (dump_bb_header): Rename to
8730         dump_gimple_bb_header.  Write to a stream instead of a pretty
8731         printer.  Use dump_bb_info to dump basic block info.
8732         (dump_bb_end): Rename to dump_gimple_bb_footer.  Write to a
8733         stream instead of a pretty printer.  Use dump_bb_info.
8734         (gimple_dump_bb_buff): Do not call dump_bb_header and dump_bb_end.
8735         (gimple_dump_bb): Do it here with dump_gimple_bb_header and
8736         dump_gimple_bb_footer.
8737         * cfgrtl.c (rtl_dump_bb): Update prototype.  Only dump DF if the
8738         dump flags have TDF_DETAILS.  Use dump_insn_slim if TDF_SLIM.
8739         (print_rtl_with_bb): Take a flags argument and pass it around.
8740         Use dump_insn_slim if TDF_SLIM.
8741         (dump_bb_info): Removed and re-incarnated in cfg.c.
8742         (dump_flow_info): Moved to cfghooks.c.
8743         (debug_flow_info): Moved to cfghooks.c.
8744         * passes.c (execute_function_dump): Unconditionally use
8745         print_rtl_with_bb for RTL dumps, now that it understands TDF_SLIM.
8746         * final.c (dump_basic_block_info): Update dump_edge_info calls.
8747         * tree-vrp.c (dump_asserts_for): Likewise.
8748         * ifcvt.c (if_convert): Unconditionally use print_rtl_with_bb.
8749         * tree-if-conv.c (if_convertible_bb_p): Don't look at
8750         EDGE_ABNORMAL_CALL, it has no meaning in the GIMPLE world.
8751         * trans-mem.c (make_tm_edge): Don't set EDGE_ABNORMAL_CALL,
8752         for the same reason.
8753         * config/rl78/rl78.c (rl78_reorg): Update print_rtl_with_bb calls.
8754
8755 2012-07-17  Richard Guenther  <rguenther@suse.de>
8756
8757         * tree-vect-data-refs.c (vect_get_new_vect_var): Add referenced
8758         vars here, use create_tmp_reg where appropriate.
8759         (vect_create_addr_base_for_vector_ref): Do not add referenced
8760         vars here, use create_tmp_reg where appropriate.
8761         (vect_create_data_ref_ptr): Likewise.
8762         (vect_create_destination_var): Likewise.
8763         (vect_permute_store_chain): Likewise.
8764         (vect_permute_load_chain): Likewise.
8765         * tree-vect-loop-manip.c (vect_create_cond_for_align_checks):
8766         Likewise.
8767         * tree-vect-loop.c (get_initial_def_for_induction): Likewise.
8768         * tree-vect-patterns.c (vect_recog_temp_ssa_var): Likewise.
8769         (vect_handle_widen_op_by_const): Likewise.
8770         * tree-vect-stmts.c (vect_init_vector): Likewise.
8771         (vectorizable_load): Likewise.
8772
8773 2012-07-17  Tom de Vries  <tom@codesourcery.com>
8774
8775         * hwint.c: Fix loop range.
8776
8777 2012-07-17  Tom de Vries  <tom@codesourcery.com>
8778
8779         * double-int.h (double_int_popcount): New inline function.
8780         * hwint.c (popcount_hwi): New function.
8781         * hwint.h (popcount_hwi): Declare function.  New inline function.
8782
8783 2012-07-17  Richard Henderson  <rth@redhat.com>
8784
8785         * tree-vect-stmts.c (supportable_widening_operation): Remove decl
8786         parameters.
8787         (vectorizable_conversion): Update supportable_widening_operation call.
8788         * tree-vect-patterns.c (vect_recog_widen_mult_pattern): Likewise.
8789         (vect_recog_widen_shift_pattern): Likewise.
8790         * tree-vectorizer.h: Update decl.
8791
8792 2012-07-17  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
8793             Ulrich Weigand  <ulrich.weigand@linaro.org>
8794
8795         * common/config/arm/arm-common.c (arm_option_optimization_table):
8796         Enable -fsched-pressure by default while optimizing.
8797         * config/arm/arm.c (arm_option_override): Use the alternate scheduler
8798         pressure algorithm by default.
8799
8800 2012-07-16  Oleg Endo  <olegendo@gcc.gnu.org>
8801
8802         * config/sh/sh.h (CONST_OK_FOR_I06): Delete.
8803         (CONST_OK_FOR_I10): Move macro to ...
8804         * config/sh/sh.c: ... here.
8805         (sh_legitimate_index_p): Use satisfies_constraint_I06 instead of
8806         CONST_OK_FOR_I06.
8807
8808 2012-07-16  Oleg Endo  <olegendo@gcc.gnu.org>
8809
8810         * config/sh/sh.md: Delete mov related define_peephole patterns.
8811
8812 2012-07-16  Jonathan Wakely  <jwakely.gcc@gmail.com>
8813
8814         PR c++/53919
8815         * doc/install.texi (Installing GCC): Refer to instructions for
8816         released versions. Fix hyphenation.
8817
8818 2012-07-16  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
8819
8820         * config/spu/spu.c (targetm): Move to bottom of file.
8821         (spu_attribute_table): Likewise.
8822         (spu_option_override, spu_init_builtins, spu_builtin_decl,
8823         spu_scalar_mode_supported_p, spu_vector_mode_supported_p,
8824         spu_legitimate_address_p, spu_addr_space_legitimate_address_p,
8825         adjust_operand, get_pic_reg, need_to_save_reg, frame_emit_store,
8826         frame_emit_load, frame_emit_add_imm, emit_nop_for_insn,
8827         insn_clobbers_hbr, spu_emit_branch_hint, spu_emit_vector_compare,
8828         get_branch_target, spu_machine_dependent_reorg, spu_sched_issue_rate,
8829         spu_sched_variable_issue, spu_sched_adjust_cost, spu_sched_init_global,
8830         spu_sched_init, spu_sched_reorder, spu_handle_fndecl_attribute,
8831         spu_handle_vector_attribute, spu_pass_by_reference, spu_function_arg,
8832         spu_function_arg_advance, spu_build_builtin_va_list, spu_va_start,
8833         spu_gimplify_va_arg_expr, store_with_one_insn_p, reg_aligned_for_addr,
8834         spu_assemble_integer, spu_asm_globalize_label, spu_rtx_costs,
8835         spu_function_ok_for_sibcall, spu_init_libfuncs, spu_return_in_memory,
8836         spu_encode_section_info, spu_legitimize_address,
8837         spu_addr_space_legitimize_address, spu_builtin_mask_for_load,
8838         spu_builtin_vectorization_cost, spu_vector_alignment_reachable,
8839         spu_addr_space_pointer_mode, spu_addr_space_address_mode,
8840         spu_addr_space_subset_p, spu_addr_space_convert, spu_sms_res_mii,
8841         spu_section_type_flags, spu_select_section, spu_unique_section,
8842         spu_trampoline_init, spu_conditional_register_usage,
8843         spu_ref_may_alias_errno, spu_output_mi_thunk, spu_unwind_word_mode,
8844         spu_libgcc_cmp_return_mode, spu_libgcc_shift_count_mode,
8845         spu_setup_incoming_varargs): Remove prototypes.
8846         (spu_legitimize_address): Add "static" to definition.
8847
8848 2012-07-16  Jakub Jelinek  <jakub@redhat.com>
8849
8850         * config/i386/rtmintrin.h (_xabort): Remove trailing semicolon.
8851
8852 2012-07-16  Ulrich Weigand  <ulrich.weigand@linaro.org>
8853
8854         * tree-ssa-ccp.c (optimize_unreachable): Check gsi_end_p
8855         before calling gsi_stmt.
8856
8857 2012-07-16  Kirill Yukhin  <kirill.yukhin@intel.com>
8858
8859         Revert
8860         2012-07-16 Sergey Melnikov <sergey.melnikov@intel.com>
8861
8862         * config/i386/i386.md (stack_protect_set): Disable the pattern
8863         for Android since Android libc (bionic) does not provide random
8864         value for stack protection guard at gs:0x14. Guard value
8865         will be provided from external symbol (default implementation).
8866         (stack_protect_set_<mode>): Likewise.
8867         (stack_protect_test): Likewise.
8868         (stack_protect_test_<mode>): Likewise.
8869
8870 2012-07-16  H.J. Lu  <hongjiu.lu@intel.com>
8871
8872         PR middle-end/53959
8873         PR bootstrap/53963
8874         * gimple.c (gimple_types_compatible_p_1): Restore type attribute
8875         comparison.
8876
8877 2012-07-16  Bill Schmidt  <wschmidt@linux.ibm.com>
8878
8879         * opts.c (default_option): Add -fvect-cost-model to default options
8880         at -O3 and above.
8881
8882 2012-07-16  Steven Bosscher  <steven@gcc.gnu.org>
8883
8884         * graphite-clast-to-gimple.c, graphite-dependences.c,
8885         graphite-sese-to-poly.c: Include tree-pass.h instead of dumpfile.h
8886         for pass TODO flags.
8887         * Makefile.in: Fix dependencies.
8888
8889 2012-07-16  Steven Bosscher  <steven@gcc.gnu.org>
8890
8891         * haifa-sched.c (init_before_recovery): Do not set EDGE_CAN_FALLTHRU.
8892         * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
8893
8894         * function.c (stack_protect_epilogue): Use expand_call to expand
8895         targetm.stack_protect_fail.
8896         * stmt.c (expand_expr_stmt): Remove now-unused function.
8897         * tree.h (expand_expr_stmt): Remove prototype.
8898         * doc/tm.texi.in (TARGET_STACK_PROTECT_FAIL): Document that this
8899         hook must return a CALL_EXPR.
8900         * doc/tm.texi: Regenerate.
8901
8902         * emit-rtl.c (emit_label_before): Do not allow the same label
8903         to be emitted twice.
8904         (emit_label_after): Likewise.
8905         (emit_label): Likewise.
8906
8907         * flags.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED,
8908         TYPE_OVERFLOW_TRAPS, POINTER_TYPE_OVERFLOW_UNDEFINED): Move to tree.h.
8909         * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED,
8910         TYPE_OVERFLOW_TRAPS, POINTER_TYPE_OVERFLOW_UNDEFINED): New home.
8911
8912 2012-07-16  Steven Bosscher  <steven@gcc.gnu.org>
8913
8914         * system.h (dump_file): Do not define.
8915         * tree-pass.h: Include dumpfile.h, which is a new file containing...
8916         (enum tree_dump_index, TDF_*, get_dump_file_name, dump_enabled_p,
8917         dump_initialized_p, dump_begin, dump_end, dump_node, dump_switch_p,
8918         dump_flag_name, dump_file, dump_flags, dump_file_name,
8919         get_dump_file_info, struct dump_file_info): all of this, moved to...
8920         * dumpfile.h: Here, new file.
8921         * tree-dump.h: Include dumpfile.h, but not tree-pass.h.
8922         (dump_stmt): Remove prototype for C++ specific function.
8923         (dump_enumerated_decls): Move prototype from here...
8924         * tree-flow.h (dump_enumerated_decls): ... to here.
8925         (get_ref_base_and_extent) Move prototype from here ...
8926         * tree.h (get_ref_base_and_extent) ... to here.
8927         * tree-ssa-live.c: Do not inclde tree-pretty-print.h, because
8928         gimple-pretty-print.h is enough.  Do not include tree-dump.h,
8929         include timevar.h and dumpfile.h instead.
8930         (struct numbered_tree_d, compare_decls_by_uid,
8931         dump_enumerated_decls_push, dump_enumerated_decls): Move from here ...
8932         * tree-dfa.c:(struct numbered_tree_d, compare_decls_by_uid,
8933         dump_enumerated_decls_push, dump_enumerated_decls):... to here.
8934         Do not include timevar.h.
8935         * tree.c: Do not include timevar.h.
8936         * tree-cfg.c: Do not include langhooks.h, tree-pretty-print.h, and
8937         timevar.h.
8938         (dump_cfg_stats): Use current_function_name.
8939         (gimple_cfg2vcg): Likewise.
8940         (dump_function_to_file): Likewise.
8941         * df-scan.c: Do not include tree-pass.h and timevar.h.
8942         Include dumpfile.h.
8943         (df_entry_block_bitmap_verify, df_exit_block_bitmap_verify): Do not
8944         use print_current_pass.
8945         * df-problems.c: Include dumpfile.h.
8946         Always define REG_DEAD_DEBUGGING, avoid #ifdef code, because it
8947         leads to errors in the code not selected.
8948         (df_note_compute): Do not print_rtl_with_bb here.  Fix compilation
8949         bug if REG_DEAD_DEBUGGING is not 0, get_insns is not available here.
8950         * lcm.c: Include dumpfile.h.
8951         Remove obsolete include of insn-attr.h.
8952         * dojump.c (do_compare_rtx_and_jump): Remove failure printing for
8953         missing probability notes.
8954         * stmt.c: Include dumpfile.h.
8955         (emit_case_decision_tree): Re-enable printing expand details only
8956         if TDF_DETAILS.
8957         * alias.c, auto-inc-dec.c, bb-reorder.c, caller-save.c, cfg.c,
8958         cfgcleanup.c, cfgexpand.c, cfgloop.c, cfgloopmanip.c, cgraph.c,
8959         cgraphclones.c, cgraphunit.c, combine.c, combine-stack-adj.c,
8960         coverage.c, cprop.c, cse.c, cselib.c, dbgcnt.c, dce.c, df-core.c,
8961         dse.c, dwarf2out.c, emit-rtl.c, except.c, expr.c, final.c,
8962         function.c, fwprop.c, gcse.c, gimple-fold.c,
8963         gimple-pretty-print.c, gimple-ssa-strength-reduction.c,
8964         gimplify.c, graphite-blocking.c, graphite-clast-to-gimple.c,
8965         graphite-dependences.c, graphite-interchange.c,
8966         graphite-optimize-isl.c, graphite-poly.c,
8967         graphite-sese-to-poly.c, haifa-sched.c, hw-doloop.c, ifcvt.c,
8968         ipa.c, ipa-cp.c, ipa-inline-analysis.c, ipa-inline.c,
8969         ipa-inline-transform.c, ipa-prop.c, ipa-pure-const.c,
8970         ipa-reference.c, ipa-split.c, ipa-utils.c, ira.c, ira-emit.c,
8971         jump.c, loop-doloop.c, loop-init.c, loop-invariant.c, loop-iv.c,
8972         loop-unroll.c, loop-unswitch.c, lower-subreg.c,
8973         lto-section-out.c, lto-streamer-in.c, matrix-reorg.c, mcf.c,
8974         mode-switching.c, modulo-sched.c, omega.c, omp-low.c, passes.c,
8975         plugin.c, postreload.c, postreload-gcse.c, predict.c, print-rtl.c,
8976         print-tree.c, profile.c, recog.c, ree.c, regcprop.c, reginfo.c,
8977         regmove.c, regrename.c, reg-stack.c, reload1.c, reorg.c,
8978         sched-rgn.c, sched-vis.c, sel-sched.c, sel-sched-ir.c,
8979         store-motion.c, tracer.c, trans-mem.c, tree-affine.c,
8980         tree-call-cdce.c, tree-cfgcleanup.c, tree-chrec.c,
8981         tree-data-ref.c, tree-diagnostic.c, tree-dump.c,
8982         tree-eh.c, tree-flow-inline.h, tree-if-conv.c, tree-into-ssa.c,
8983         tree-mudflap.c, tree-nrv.c, tree-object-size.c,
8984         tree-optimize.c, tree-outof-ssa.c, tree-predcom.c,
8985         tree-pretty-print.c, tree-profile.c, tree-scalar-evolution.c,
8986         tree-sra.c, tree-ssa-address.c, tree-ssa-alias.c, tree-ssa.c,
8987         tree-ssa-ccp.c, tree-ssa-coalesce.c, tree-ssa-copy.c,
8988         tree-ssa-copyrename.c,, tree-ssa-dce.c, tree-ssa-dom.c,
8989         tree-ssa-dse.c, tree-ssa-forwprop.c, tree-ssa-ifcombine.c,
8990         tree-ssa-loop.c, tree-ssa-loop-ch.c, tree-ssa-loop-im.c,
8991         tree-ssa-loop-ivcanon.c, tree-ssa-loop-ivopts.c,
8992         tree-ssa-loop-manip.c, tree-ssa-loop-niter.c,
8993         tree-ssa-loop-prefetch.c, tree-ssa-loop-unswitch.c,
8994         tree-ssa-math-opts.c, tree-ssa-operands.c, tree-ssa-phiopt.c,
8995         tree-ssa-phiprop.c, tree-ssa-pre.c, tree-ssa-propagate.c,
8996         tree-ssa-reassoc.c, tree-ssa-sccvn.c, tree-ssa-sink.c,
8997         tree-ssa-structalias.c, tree-ssa-tail-merge.c, tree-ssa-ter.c,
8998         tree-ssa-threadedge.c, tree-ssa-threadupdate.c,
8999         tree-ssa-uncprop.c, tree-ssa-uninit.c,
9000         tree-switch-conversion.c, tree-tailcall.c,
9001         tree-vect-data-refs.c, tree-vect-loop.c,
9002         tree-vect-loop-manip.c, tree-vectorizer.c,
9003         tree-vect-patterns.c, tree-vect-slp.c, tree-vect-stmts.c,
9004         tree-vrp.c, value-prof.c, var-tracking.c, web.c: Include tree-pass.h
9005         only if needed.  If tree-pass.h is included, do not include timevar.h
9006         and dumpfile.h.  If tree-pass.h is not included but dump_file, or
9007         dump_flags, or the TDF_* flags are used, include dumpfile.h.
9008         If gimple-pretty-print.h is included, don't include
9009         tree-pretty-print.h.  Remove assorted unnecessary includes.
9010
9011         * config/mn10300/mn10300.c, config/c6x/c6x.c, config/ia64/ia64.c,
9012         config/arm/arm.c, config/bfin/bfin.c, config/frv/frv.c,
9013         config/spu/spu.c, config/mep/mep.c, config/i386/i386.c:
9014         Include dumpfile.h.
9015         * config/rl78/rl78.c: Include dumpfile.h instead of tree-pass.h.
9016         * arm/t-arm, avr/t-avr, i386/t-i386, ia64/t-ia64, mep/t-mep,
9017         spu/t-spu-elf: Fix dependencies.
9018
9019 2012-07-16  Dehao Chen  <dehao@google.com>
9020
9021         Revert
9022         2012-07-10  Dehao Chen  <dehao@google.com>
9023
9024         * tree.h (phi_arg_d): New field.
9025         * tree-flow-inline.h (gimple_phi_arg_block): New function.
9026         (gimple_phi_arg_block_from_edge): New function.
9027         (gimple_phi_arg_set_block): New function.
9028         (gimple_phi_arg_has_block): New function.
9029         (redirect_edge_var_map_block): New function.
9030         * tree-flow.h (_edge_var_map): New field.
9031         * tree-ssa-live.c (remove_unused_locals): Mark phi_arg's block as used.
9032         * tree-eh.c (cleanup_empty_eh_merge_phis): Add block debug info for
9033         redirect_edge_var_map_add.
9034         * tree-outof-ssa.c (_elim_graph): New field.
9035         (insert_partition_copy_on_edge): New parameter.
9036         (insert_value_copy_on_edge): New parameter.
9037         (insert_rtx_to_part_on_edge): New parameter.
9038         (insert_part_to_rtx_on_edge): New parameter.
9039         (elim_graph_add_edge): New parameter.
9040         (elim_graph_remove_succ_edge): New parameter.
9041         (FOR_EACH_ELIM_GRAPH_SUCC): New parameter.
9042         (FOR_EACH_ELIM_GRAPH_PRED): New parameter.
9043         (new_elim_graph): Add block debug info.
9044         (clear_elim_graph): Likewise.
9045         (delete_elim_graph): Likewise.
9046         (elim_graph_add_node): Likewise.
9047         (elim_graph_add_edge): Likewise.
9048         (elim_graph_remove_succ_edge): Likewise.
9049         (eliminate_build): Likewise.
9050         (elim_forward): Likewise.
9051         (elim_unvisited_predecessor): Likewise.
9052         (elim_backward): Likewise.
9053         (elim_create): Likewise.
9054         (eliminate_phi): Likewise.
9055         (insert_backedge_copies): Likewise.
9056         * tree-into-ssa.c (insert_phi_nodes_for): Add block debug info for
9057         add_phi_arg.
9058         (rewrite_add_phi_arguments): Likewise.
9059         * tree-ssa-loop-im.c (execute_sm_if_changed): Likewise.
9060         * tree-ssa-tail-merge.c (replace_block_by): Likewise.
9061         * tree-ssa-threadupdate.c (copy_phi_args): Likewise.
9062         * tree-loop-distribution.c (update_phis_for_loop_copy): Likewise.
9063         * tree-ssa-loop-manip.c (create_iv): Likewise.
9064         (add_exit_phis_edge): Likewise.
9065         (split_loop_exit_edge): Likewise.
9066         (copy_phi_node_args): Likewise.
9067         (tree_transform_and_unroll_loop): Likewise.
9068         * value-prof.c (gimple_ic): Likewise.
9069         (gimple_stringop_fixed_value): Likewise.
9070         * tree-tailcall.c (add_successor_phi_arg): Likewise.
9071         (eliminate_tail_call): Likewise.
9072         (create_tailcall_accumulator): Likewise.
9073         (tree_optimize_tail_calls_1): Likewise.
9074         * tree-phinodes.c (add_phi_arg): Likewise.
9075         (make_phi_node): Likewise.
9076         (resize_phi_node): Likewise.
9077         (remove_phi_arg_num): Likewise.
9078         * omp-low.c (expand_parallel_call): Likewise.
9079         (expand_omp_for_static_chunk): Likewise.
9080         * tree-vect-loop-manip.c (slpeel_update_phis_for_duplicate_loop):
9081         Likewise.
9082         (slpeel_update_phi_nodes_for_guard1): Likewise.
9083         (slpeel_update_phi_nodes_for_guard2): Likewise.
9084         (slpeel_tree_duplicate_loop_to_edge_cfg): Likewise.
9085         (set_prologue_iterations): Likewise.
9086         (slpeel_tree_peel_loop_to_edge): Likewise.
9087         (vect_loop_versioning): Likewise.
9088         * tree-parloops.c (create_phi_for_local_result): Likewise.
9089         (transform_to_exit_first_loop): Likewise.
9090         (create_parallel_loop): Likewise.
9091         * ipa-split.c (split_function): Likewise.
9092         * tree-vect-loop.c (get_initial_def_for_induction): Likewise.
9093         (vect_create_epilog_for_reduction): Likewise.
9094         * tree-vect-data-refs.c (vect_setup_realignment): Likewise.
9095         * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Likewise.
9096         * tree-ssa-phiopt.c (cond_store_replacement): Likewise.
9097         (cond_if_else_store_replacement_1): Likewise.
9098         * tree-cfgcleanup.c (remove_forwarder_block): Likewise.
9099         (remove_forwarder_block_with_phi): Likewise.
9100         * tree-ssa-pre.c (insert_into_preds_of_block): Likewise.
9101         * tree-predcom.c (initialize_root_vars): Likewise.
9102         (initialize_root_vars_lm): Likewise.
9103         * sese.c (sese_add_exit_phis_edge): Likewise.
9104         * tree-ssa-dce.c (forward_edge_to_pdom): Likewise.
9105         * tree-ssa.c (flush_pending_stmts): Likewise.
9106         (redirect_edge_var_map_add): Likewise.
9107         (ssa_redirect_edge): Likewise.
9108         * gimple-streamer-in.c (input_phi): Likewise.
9109         * tree-vect-stmts.c (vectorizable_load): Likewise.
9110         * tree-inline.c (copy_phis_for_bb): Likewise.
9111         * tree-ssa-phiprop.c (phiprop_insert_phi): Likewise.
9112         * tree-switch-conversion.c (fix_phi_nodes): Likewise.
9113         * tree-cfg.c (reinstall_phi_args): Likewise.
9114         (gimple_make_forwarder_block): Likewise.
9115         (add_phi_args_after_copy_edge): Likewise.
9116         (gimple_duplicate_sese_tail): Likewise.
9117
9118 2012-07-16 Sergey Melnikov <sergey.melnikov@intel.com>
9119
9120         * config/i386/i386.md (stack_protect_set): Disable the pattern
9121         for Android since Android libc (bionic) does not provide random
9122         value for stack protection guard at gs:0x14. Guard value
9123         will be provided from external symbol (default implementation).
9124         (stack_protect_set_<mode>): Likewise.
9125         (stack_protect_test): Likewise.
9126         (stack_protect_test_<mode>): Likewise.
9127
9128 2012-07-16  Hans-Peter Nilsson  <hp@axis.com>
9129
9130         * config/cris/cris-protos.h (cris_legitimate_address_p): Declare.
9131         * config/cris/cris.h (CONSTANT_ADDRESS_P): Define in terms of
9132         CONSTANT_P and cris_legitimate_address_p.
9133         * config/cris/cris.c (cris_legitimate_address_p): Make non-static.
9134         (cris_preferred_reload_class): Don't return GENERAL_REGS as
9135         preferred to MOF_SRP_REGS.
9136
9137         * config/cris/cris.c (cris_init_libfuncs): Handle initialization
9138         of library functions for basic atomic compare-and-swap.
9139         * config/cris/cris.h (TARGET_ATOMICS_MAY_CALL_LIBFUNCS): New macro.
9140         * config/cris/cris.opt (munaligned-atomic-may-use-library): New option.
9141         * config/cris/sync.md ("atomic_fetch_<atomic_op_name><mode>")
9142         ("cris_atomic_fetch_<atomic_op_name><mode>_1")
9143         ("atomic_compare_and_swap<mode>")
9144         ("cris_atomic_compare_and_swap<mode>_1"): Make conditional on
9145         TARGET_ATOMICS_MAY_CALL_LIBFUNCS for sizes larger than byte.
9146         * config/cris/cris.c (cris_print_operand) <case 'P', 'q'>: New cases.
9147         * config/cris/sync.md (atomic_op_op_cnstr): New code_attr.
9148         (atomic_op_op_pred): Ditto.
9149         (atomic_op_mnem_pre_op2): Renamed from atomic_op_mnem_pre; to
9150         reflect the change to include %2 in expansion.  All callers changed.
9151         (qm3): New mode_attr.
9152         ("atomic_fetch_<atomic_op_name><mode>"): Use <atomic_op_op_pred>
9153         as predicate for operand 2.
9154         ("cris_atomic_fetch_<atomic_op_name><mode>_1"): Update FIXME.  Use
9155         "<atomic_op_op_pred>" "<atomic_op_op_cnstr>" for predicate and
9156         constraint for operand 2.
9157         ("atomic_compare_and_swap<mode>"): Add FIXME.  Change predicate to
9158         nonmemory_operand for operand 3.
9159         ("cris_atomic_compare_and_swap<mode>_1"): Change operand 3 to
9160         exclude memory.  Improve emitted sync code for v10 and v32.  Use
9161         <qm3> instead of <m> for size designator for cmp.
9162         ("atomic_compare_and_swap<mode>"): Change predicate to
9163         nonmemory_operand for operand 3.  Add FIXME.
9164         ("cris_atomic_compare_and_swap<mode>_1"): Change predicates and
9165         constraints for operand 3 to exclude memory.
9166         ("atomic_fetch_<atomic_op_name><mode>")
9167         ("atomic_compare_and_swap<mode>"): Gate expand_mem_thread_fence
9168         calls on result of call to need_atomic_barrier_p.
9169
9170 2012-07-15  Richard Sandiford  <rdsandiford@googlemail.com>
9171
9172         * config/mips/mips.md (move_type): Replace mfhilo and mthilo
9173         with mflo and mtlo.
9174         (type): Split mfhilo into mfhi and mflo.  Split mthilo into mthi
9175         and mtlo.  Adjust move_type->type mapping.
9176         (may_clobber_hilo): Split mthilo into mthi and mtlo.
9177         (*movdi_32bit, *movdi_32bit_mips16, *movdi_64bit, *movdi_64bit_mips16)
9178         (*mov<mode>_internal, *mov<mode>_mips16, *movhi_internal)
9179         (*movhi_mips16, *movqi_internal, *movqi_mips16): Use mtlo and mflo
9180         instead of mthilo and mfhilo.
9181         (mfhi<GPR:mode>_<HILO:mode>): Use mfhi instead of mfhilo.
9182         (mthi<GPR:mode>_<HILO:mode>): Use mthi instead of mthilo.
9183         * config/mips/mips-dsp.md (mips_extr_w, mips_extr_r_w, mips_extr_rs_w)
9184         (mips_extr_s_h, mips_extp, mips_extpdp, mips_shilo, mips_mthlip):
9185         Use mflo instead of mfhilo.
9186         * config/mips/10000.md (r10k_arith): Split mthilo.
9187         (r10k_mfhi, r10k_mflo): Use mfhi and mflo directly.
9188         * config/mips/sb1.md (ir_sb1_mfhi, ir_sb1_mflo): Likewise.
9189         (ir_sb1_mthilo): Split mthilo into mthi and mtlo.
9190         * config/mips/20kc.md (r20kc_imthilo, r20kc_imfhilo): Split
9191         mthilo and mfhilo.
9192         * config/mips/24k.md (r24k_int_mfhilo, r24k_int_mthilo): Likewise.
9193         * config/mips/4130.md (vr4130_class, vr4130_mfhilo, vr4130_mthilo):
9194         Likewise.
9195         * config/mips/4k.md (r4k_int_mthilo, r4k_int_mfhilo): Likewise.
9196         * config/mips/5400.md (ir_vr54_hilo): Likewise.
9197         * config/mips/5500.md (ir_vr55_mthilo, ir_vr55_mfhilo): Likewise.
9198         * config/mips/5k.md (r5k_int_mthilo, r5k_int_mfhilo): Likewise.
9199         * config/mips/7000.md (rm7_mthilo, rm7_mfhilo): Likewise.
9200         * config/mips/74k.md (r74k_int_mfhilo, r74k_int_mthilo): Likewise.
9201         * config/mips/9000.md (rm9k_mfhilo, rm9k_mthilo): Likewise.
9202         * config/mips/generic.md (generic_hilo): Likewise.
9203         * config/mips/loongson2ef.md (ls2_alu): Likewise.
9204         * config/mips/loongson3a.md (ls3a_mfhilo): Likewise.
9205         * config/mips/octeon.md (octeon_imul_o1, octeon_imul_o2)
9206         (octeon_mfhilo_o1, octeon_mfhilo_o2): Likewise.
9207         * config/mips/sr71k.md (ir_sr70_hilo): Likewise.
9208         * config/mips/xlr.md (xlr_hilo): Likewise.
9209
9210 2012-07-14  Andrew Stubbs  <ams@codesourcery.com>
9211             Sandra Loosemore  <sandra@codesourcery.com>
9212
9213         * config/sh/sh.h (SH_ASM_SPEC): Add spaces between options.
9214
9215 2012-07-14  Uros Bizjak  <ubizjak@gmail.com>
9216
9217         * config/i386/i386.c (ix86_set_reg_reg_cost): Enable TFmode/TCmode
9218         for TARGET_SSE.
9219
9220 2012-07-14  Steven Bosscher  <steven@gcc.gnu.org>
9221
9222         * toplev.c (init_asm_output): Open asm_out_file in 'w' mode.
9223
9224 2012-07-13  Bill Schmidt  <wschmidt@linux.ibm.com>
9225
9226         PR bootstrap/53955
9227         * config/spu/spu.c (spu_init_cost): Mark static.
9228         (spu_add_stmt_cost): Likewise.
9229         (spu_finish_cost): Likewise.
9230         (spu_destroy_cost_data): Likewise.
9231         * config/i386/i386.c (ix86_init_cost): Mark static.
9232         (ix86_add_stmt_cost): Likewise.
9233         (ix86_finish_cost): Likewise.
9234         (ix86_destroy_cost_data): Likewise.
9235         * config/rs6000/rs6000.c (rs6000_init_cost): Mark static.
9236         (rs6000_add_stmt_cost): Likewise.
9237         (rs6000_finish_cost): Likewise.
9238         (rs6000_destroy_cost_data): Likewise.
9239
9240 2012-07-13  Steven Bosscher  <steven@gcc.gnu.org>
9241
9242         * ggc.h (ggc_internal_alloc_stat, ggc_alloc_typed_stat,
9243         ggc_internal_cleared_alloc_stat, ggc_cleared_alloc_htab_ignore_args,
9244         ggc_cleared_alloc_ptr_array_two_args, ggc_splay_alloc): Add
9245         ATTRIBUTE_MALLOC.
9246         * alloc-pool.h (pool_alloc): Likewise.
9247
9248         * final.c (final): Do not loop to find max_uid.
9249
9250 2012-07-13  Steven Bosscher  <steven@gcc.gnu.org>
9251
9252         * emit-rtl.c (make_debug_insn_raw, make_jump_insn_raw): Make static.
9253         * rtl.h (make_debug_insn_raw, make_jump_insn_raw): Remove prototypes.
9254
9255 2012-07-13  Richard Guenther  <rguenther@suse.de>
9256
9257         PR tree-optimization/53907
9258         * tree-ssa-forwprop.c (associate_pointerplus): New function.
9259         (ssa_forward_propagate_and_combine): Call it.
9260
9261 2012-07-13  Richard Guenther  <rguenther@suse.de>
9262
9263         PR tree-optimization/53922
9264         * tree-vrp.c (value_inside_range): Change prototype to take
9265         min/max instead of value-range.
9266         (range_includes_zero_p): Likewise.  Return the result from
9267         value_inside_range.
9268         (extract_range_from_binary_expr_1): Adjust to handle dont-know
9269         return value from range_includes_zero_p.
9270         (extract_range_from_unary_expr_1): Likewise.
9271         (compare_range_with_value): Likewise.
9272         (vrp_meet_1): Likewise.
9273
9274 2012-07-13  Bill Schmidt  <wschmidt@linux.ibm.com>
9275
9276         * doc/tm.texi: Regenerate.
9277         * doc/tm.texi.in (TARGET_VECTORIZE_INIT_COST): New hook.
9278         (TARGET_VECTORIZE_ADD_STMT_COST): Likewise.
9279         (TARGET_VECTORIZE_FINISH_COST): Likewise.
9280         (TARGET_VECTORIZE_DESTROY_COST_DATA): Likewise.
9281         * targhooks.c (default_init_cost): New function.
9282         (default_add_stmt_cost): Likewise.
9283         (default_finish_cost): Likewise.
9284         (default_destroy_cost_data): Likewise.
9285         * targhooks.h (default_init_cost): New decl.
9286         (default_add_stmt_cost): Likewise.
9287         (default_finish_cost): Likewise.
9288         (default_destroy_cost_data): Likewise.
9289         * target.def (init_cost): New DEFHOOK.
9290         (add_stmt_cost): Likewise.
9291         (finish_cost): Likewise.
9292         (destroy_cost_data): Likewise.
9293         * target.h (struct _stmt_vec_info): New extern decl.
9294         (stmt_vectype): Likewise.
9295         (stmt_in_inner_loop_p): Likewise.
9296         * tree-vectorizer.h (stmt_info_for_cost): New struct/typedef.
9297         (stmt_vector_for_cost): New VEC/typedef.
9298         (add_stmt_info_to_vec): New function.
9299         (struct _slp_tree): Remove cost.inside_of_loop field.
9300         (struct _slp_instance): Remove cost.inside_of_loop field; add
9301         stmt_cost_vec field.
9302         (SLP_INSTANCE_INSIDE_OF_LOOP_COST): Remove macro.
9303         (SLP_INSTANCE_STMT_COST_VEC): New accessor macro.
9304         (SLP_TREE_INSIDE_OF_LOOP_COST): Remove macro.
9305         (struct _vect_peel_extended_info): Add stmt_cost_vec field.
9306         (struct _loop_vec_info): Add target_cost_data field.
9307         (LOOP_VINFO_TARGET_COST_DATA): New accessor macro.
9308         (struct _bb_vec_info): Add target_cost_data field.
9309         (BB_VINFO_TARGET_COST_DATA): New accessor macro.
9310         (struct _stmt_vec_info): Remove cost.inside_of_loop field.
9311         (STMT_VINFO_INSIDE_OF_LOOP_COST): Remove macro.
9312         (stmt_vinfo_set_inside_of_loop_cost): Remove function.
9313         (init_cost): New function.
9314         (add_stmt_cost): Likewise.
9315         (finish_cost): Likewise.
9316         (destroy_cost_data): Likewise.
9317         (vect_model_simple_cost): Change parameter list.
9318         (vect_model_store_cost): Likewise.
9319         (vect_model_load_cost): Likewise.
9320         (record_stmt_cost): New extern decl.
9321         (vect_get_load_cost): Change parameter list.
9322         (vect_get_store_cost): Likewise.
9323         * tree-vect-loop.c (new_loop_vec_info): Call init_cost.
9324         (destroy_loop_vec_info): Call destroy_cost_data.
9325         (vect_estimate_min_profitable_iters): Remove old calculation of
9326         inside costs; call finish_cost instead.
9327         (vect_model_reduction_cost): Call add_stmt_cost instead of old
9328         inside-costs calculation.
9329         (vect_model_induction_cost): Likewise.
9330         * tree-vect-data-refs.c (vect_get_data_access_cost): Change to
9331         return a stmt_vector_for_cost; modify calls to vect_get_load_cost
9332         and vect_get_store_cost to obtain the value to return.
9333         (vect_peeling_hash_get_lowest_cost): Obtain a stmt_cost_vec from
9334         vect_get_data_access_cost and store it in the minimum peeling
9335         structure.
9336         (vect_peeling_hash_choose_best_peeling): Change the parameter list
9337         to add a (stmt_vector_for_cost *) output parameter, and set its value.
9338         (vect_enhance_data_refs_alignment): Ignore the new return value from
9339         calls to vect_get_data_access_cost; obtain stmt_cost_vec from
9340         vect_peeling_hash_choose_best_peeling and pass its contents to the
9341         target cost model.
9342         * tree-vect-stmts.c (stmt_vectype): New function.
9343         (stmt_in_inner_loop_p): Likewise.
9344         (record_stmt_cost): Likewise.
9345         (vect_model_simple_cost): Add stmt_cost_vec parameter; call
9346         record_stmt_cost instead of old calculation; don't call
9347         stmt_vinfo_set_inside_of_loop_cost.
9348         (vect_model_promotion_demotion_cost): Call add_stmt_cost instead of
9349         old calculation; don't call stmt_vinfo_set_inside_of_loop_cost.
9350         (vect_model_store_cost): Add stmt_cost_vec parameter; call
9351         record_stmt_cost instead of old calculation; add stmt_cost_vec
9352         parameter to vect_get_store_cost call; don't call
9353         stmt_vinfo_set_inside_of_loop_cost.
9354         (vect_get_store_cost): Add stmt_cost_vec parameter; call
9355         record_stmt_cost instead of old calculation.
9356         (vect_model_load_cost): Add stmt_cost_vec parameter; call
9357         record_stmt_cost instead of old calculation; add stmt_cost_vec
9358         parameter to vect_get_load_cost call; don't call
9359         stmt_vinfo_set_inside_of_loop_cost.
9360         (vect_get_load_cost): Add stmt_cost_vec parameter; call
9361         record_stmt_cost instead of old calculation.
9362         (vectorizable_call): Add NULL parameter to vect_model_simple_cost call.
9363         (vectorizable_conversion): Likewise.
9364         (vectorizable_assignment): Likewise.
9365         (vectorizable_shift): Likewise.
9366         (vectorizable_operation): Likewise.
9367         (vectorizable_store): Add NULL parameter to vect_model_store_cost call.
9368         (vectorizable_load): Add NULL parameter to vect_model_load_cost call.
9369         (new_stmt_vec_info): Don't set STMT_VINFO_INSIDE_OF_LOOP_COST.
9370         * config/spu/spu.c (TARGET_VECTORIZE_INIT_COST): New macro def.
9371         (TARGET_VECTORIZE_ADD_STMT_COST): Likewise.
9372         (TARGET_VECTORIZE_FINISH_COST): Likewise.
9373         (TARGET_VECTORIZE_DESTROY_COST_DATA): Likewise.
9374         (spu_init_cost): New function.
9375         (spu_add_stmt_cost): Likewise.
9376         (spu_finish_cost): Likewise.
9377         (spu_destroy_cost_data): Likewise.
9378         * config/i386/i386.c (ix86_init_cost): New function.
9379         (ix86_add_stmt_cost): Likewise.
9380         (ix86_finish_cost): Likewise.
9381         (ix86_destroy_cost_data): Likewise.
9382         (TARGET_VECTORIZE_INIT_COST): New macro def.
9383         (TARGET_VECTORIZE_ADD_STMT_COST): Likewise.
9384         (TARGET_VECTORIZE_FINISH_COST): Likewise.
9385         (TARGET_VECTORIZE_DESTROY_COST_DATA): Likewise.
9386         * config/rs6000/rs6000.c (TARGET_VECTORIZE_INIT_COST): New macro def.
9387         (TARGET_VECTORIZE_ADD_STMT_COST): Likewise.
9388         (TARGET_VECTORIZE_FINISH_COST): Likewise.
9389         (TARGET_VECTORIZE_DESTROY_COST_DATA): Likewise.
9390         (rs6000_init_cost): New function.
9391         (rs6000_add_stmt_cost): Likewise.
9392         (rs6000_finish_cost): Likewise.
9393         (rs6000_destroy_cost_data): Likewise.
9394         * tree-vect-slp.c (vect_free_slp_instance): Free stmt_cost_vec.
9395         (vect_create_new_slp_node): Don't set SLP_TREE_INSIDE_OF_LOOP_COST.
9396         (vect_get_and_check_slp_defs): Add stmt_cost_vec parameter; add
9397         stmt_cost_vec parameter to vect_model_store_cost and
9398         vect_model_simple_cost calls.
9399         (vect_build_slp_tree): Remove inside_cost parameter; add stmt_cost_vec
9400         parameter; add stmt_cost_vec parameter to vect_get_and_check_slp_defs,
9401         vect_model_load_cost, and recursive vect_build_slp_tree calls; prevent
9402         calculating cost more than once for loads; remove inside_cost
9403         parameter from recursive vect_build_slp_tree calls; call
9404         record_stmt_cost instead of old calculation.
9405         (vect_analyze_slp_instance): Allocate stmt_cost_vec and save it with
9406         the instance; free it on premature exit; remove inside_cost parameter
9407         from vect_build_slp_tree call; add stmt_cost_vec parameter to
9408         vect_build_slp_tree call; don't set SLP_INSTANCE_INSIDE_OF_LOOP_COST.
9409         (new_bb_vec_info): Call init_cost.
9410         (destroy_bb_vec_info): Call destroy_cost_data.
9411         (vect_bb_vectorization_profitable_p): Call add_stmt_cost for each
9412         statement recorded with an SLP instance; call finish_cost instead of
9413         the old calculation.
9414         (vect_update_slp_costs_according_to_vf): Record statement costs from
9415         SLP instances, multiplying by the appropriate number of copies; don't
9416         update SLP_INSTANCE_INSIDE_OF_LOOP_COST.
9417
9418 2012-07-13  Richard Guenther  <rguenther@suse.de>
9419
9420         PR middle-end/53937
9421         * builtins.c (get_pointer_alignment_1): Handle constant
9422         pointers.
9423
9424 2012-07-13  Richard Sandiford  <rdsandiford@googlemail.com>
9425             Steven Bosscher  <steven@gcc.gnu.org>
9426             Bernd Schmidt  <bernds@codesourcery.com>
9427
9428         PR rtl-optimization/53908
9429         * df-problems.c (can_move_insns_across): When doing
9430         memory-reference book-keeping, handle call insns.
9431
9432 2012-07-13  Richard Guenther  <rguenther@suse.de>
9433
9434         * gimple.c (gimple_types_compatible_p_1): Remove redundant
9435         type attribute comparisons.
9436         (gimple_canonical_types_compatible_p): Likewise.
9437
9438 2012-07-12  Hans-Peter Nilsson  <hp@axis.com>
9439
9440         PR rtl-optimization/53176
9441         * rtlanal.c (rtx_cost): Adjust default cost for X with a
9442         UNITS_PER_WORD factor for all X according to the size of
9443         its mode, not just for SUBREGs with untieable modes.
9444         Handle SET.  Use factor * factor for MULT, DIV, UDIV,
9445         MOD, UMOD.
9446
9447 2012-07-12  Uros Bizjak  <ubizjak@gmail.com>
9448
9449         * config/i386/i386.md (QImode and HImode cmove splitters): Merge
9450         QImode and HImode splitters.  Use ix86_comparison_operator.
9451         Explicitly match FLAGS_REG.
9452         (DFmode cmove splitter): Explicitly match FLAGS_REG.
9453
9454 2012-07-11  Steven Bosscher  <steven@gcc.gnu.org>
9455
9456         * expr.h (can_move_by_pieces): Move prototype from here ...
9457         * tree.h (can_move_by_pieces): ... to here.
9458         * optabs.h (set_widening_optab_handler): Use XCNEW.
9459         * gimplify.c: Do not include expr.h.
9460
9461         * toplev.c: Do not include dwarf2out.h.
9462         * config/ia64/ia64.c: Likewise.
9463         * config/sparc/sparc.c: Likewise.
9464         * config/sparc/t-sparc (sparc.o): Fix dependencies.
9465
9466         * Makefile.in (toplev.o): Fix dependencies
9467         (c-family/c-gimplify.o): Likewise.
9468         (c-family/c-common.o): Likewise.
9469
9470 2012-07-11  Steven Bosscher  <steven@gcc.gnu.org>
9471
9472         * basic-block.h (struct edge_def): Use basic_block instead of
9473         basic_block_def *.
9474         * cfgloop.h (struct loop_exit, struct loop): Likewise.
9475         * gengenrtl.c (type_from_format): Likewise.  Also for 'tree'
9476         instead of union tree_node *.
9477         * rtl.h (union rtunion_def, emit_insn_before_noloc,
9478         emit_insn_after_noloc, add_insn_before, add_insn_after,
9479         debug_bb_slim): Likewise.
9480         * tree-inline.h (struct copy_body_data): Likewise.
9481         * sched-rgn.c (dump_region_dot): Likewise.
9482         * gimple.h (struct gimple_statement_base, gimple_set_bb,
9483         gsi_move_to_bb_end): Likewise.
9484         * sched-vis.c (debug_bb_slim): Likewise.
9485         (debug_bb_n_slim): Likewise.
9486         * config/mn10300/mn10300.c (mn10300_insert_setlb_lcc): Likewise.
9487         (mn10300_block_contains_call):
9488
9489 2012-07-11  Greta Yorsh  <Greta.Yorsh@arm.com>
9490
9491         PR target/53859
9492         * config/arm/arm.c (arm_early_load_addr_dep): Handle new
9493         epilogue patterns.
9494
9495 2012-07-11  Jonathan Wakely  <jwakely.gcc@gmail.com>
9496
9497         * doc/extend.texi (Namespace Association): Alter cautionary text.
9498
9499 2012-07-10  Oleg Endo  <olegendo@gcc.gnu.org>
9500
9501         PR target/53911
9502         * config/sh/sh.md: Remove displacement addresssing related splits.
9503
9504 2012-07-10  Xinliang David Li  <davidxl@google.com>
9505
9506         * doc/invoke.texi: New option documented.
9507         * flag-types.h: New enum type.
9508         * gimplify.c (gimplify_bind_expr): Control
9509         clobber generation with new option.
9510         (gimplify_target_expr): Ditto.
9511         * common.opt: New option.
9512
9513 2012-07-10  Julian Brown  <julian@codesourcery.com>
9514
9515         * config/arm/arm.md (movsi): Don't split symbol refs here.
9516         (define_split): New.
9517
9518 2012-07-10  Andreas Schwab  <schwab@linux-m68k.org>
9519
9520         PR bootstrap/53913
9521         * config/m68k/m68k.c (m68k_epilogue_uses): New.
9522         * config/m68k/m68k.h (EPILOGUE_USES): Use it.
9523         * config/m68k/m68k-protos.h (m68k_epilogue_uses): Add prototype.
9524
9525 2012-07-10  Richard Henderson  <rth@redhat.com>
9526
9527         * target.def (builtin_mul_widen_even, builtin_mul_widen_odd): Remove.
9528         * system.h (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_EVEN): Poison.
9529         (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_ODD): Poison.
9530         * config/i386/i386.c (IX86_BUILTIN_VEC_WIDEN_SMUL_ODD_V4SI): Remove.
9531         (IX86_BUILTIN_VEC_WIDEN_SMUL_ODD_V8SI): Remove.
9532         (IX86_BUILTIN_VEC_WIDEN_UMUL_ODD_V4SI): Remove.
9533         (IX86_BUILTIN_VEC_WIDEN_UMUL_ODD_V8SI): Remove.
9534         (IX86_BUILTIN_VEC_WIDEN_SMUL_EVEN_V4SI): Remove.
9535         (IX86_BUILTIN_VEC_WIDEN_UMUL_EVEN_V4SI): Remove.
9536         (IX86_BUILTIN_VEC_WIDEN_UMUL_EVEN_V8SI): Remove.
9537         (bdesc_args): Remove entries to match.
9538         (ix86_builtin_mul_widen_even, ix86_builtin_mul_widen_odd): Remove.
9539         (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_EVEN): Remove.
9540         (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_ODD): Remove.
9541         * config/rs6000/rs6000.c (rs6000_builtin_mul_widen_even): Remove.
9542         (rs6000_builtin_mul_widen_odd): Remove.
9543         (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_EVEN): Remove.
9544         (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_ODD): Remove.
9545         * config/spu/spu.c (spu_builtin_mul_widen_even): Remove.
9546         (spu_builtin_mul_widen_odd): Remove.
9547         (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_EVEN): Remove.
9548         (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_ODD): Remove.
9549         * doc/tm.texi.in: Don't document the removed hooks.
9550
9551         * tree-vect-stmts.c (supportable_widening_operation): Expand
9552         WIDEN_MULT_EXPR via VEC_WIDEN_MULT_EVEN/ODD_EXPR if possible.
9553
9554         * expmed.c (expmed_mult_highpart): Rename from expand_mult_highpart.
9555         (expmed_mult_highpart_optab): Rename from expand_mult_highpart_optab.
9556         * optabs.c (can_mult_highpart_p): New.
9557         (expand_mult_highpart): New.
9558         * expr.c (expand_expr_real_2) [MULT_HIGHPART_EXPR): Use it.
9559         * tree-vect-generic.c (expand_vector_operations_1): Don't expand
9560         by pieces if can_mult_highpart_p.
9561         (expand_vector_divmod): Use can_mult_highpart_p and always
9562         generate MULT_HIGHPART_EXPR.
9563         * tree-vect-patterns.c (vect_recog_divmod_pattern): Likewise.
9564         * tree-vect-stmts.c (vectorizable_operation): Likewise.
9565
9566         * config/spu/spu-builtins.md (spu_mpy): Move to spu.md.
9567         (spu_mpyu, spu_mpyhhu, spu_mpyhh): Likewise.
9568         * config/spu/spu.md (vec_widen_smult_odd_v8hi): Rename from spu_mpy.
9569         (vec_widen_umult_odd_v8hi): Rename from spu_mpyu.
9570         (vec_widen_smult_even_v8hi): Rename from spu_mpyhh.
9571         (vec_widen_umult_even_v8hi): Rename from spu_mpyhhu.
9572         * config/spu/spu-builtins.def: Update pattern names to match.
9573
9574         * config/rs6000/altivec.md (vec_widen_umult_even_v16qi): Rename
9575         from altivec_vmuleub.
9576         (vec_widen_smult_even_v16qi): Rename from altivec_vmulesb.
9577         (vec_widen_umult_even_v8hi): Rename from altivec_vmuleuh.
9578         (vec_widen_smult_even_v8hi): Rename from altivec_vmulesh.
9579         (vec_widen_umult_odd_v16qi): Rename from altivec_vmuloub.
9580         (vec_widen_smult_odd_v16qi): Rename from altivec_vmulosb.
9581         (vec_widen_umult_odd_v8hi): Rename from altivec_vmulouh.
9582         (vec_widen_smult_odd_v8hi): Rename from altivec_vmulosh.
9583         * config/rs6000/rs6000-builtin.def: Update pattern names to match.
9584
9585         * config/i386/sse.md (vec_widen_umult_even_v8si): Rename from
9586         avx2_umulv4siv4di3.
9587         (vec_widen_umult_even_v4si): Rename from sse2_umulv2siv2di3.
9588         (vec_widen_smult_even_v8si): Rename from avx2_mulv4siv4di3.
9589         (mulv4si3): Remove XOP test shadowed by SSE4 test.
9590         * config/i386/i386.c (bdesc_args): Update pattern names.
9591         (ix86_expand_sse2_mulvxdi3): Likewise.
9592         (ix86_expand_mul_widen_evenodd): Likewise.  Remove XOP test
9593         shadowed by SSE4 test.
9594
9595         * tree.def (VEC_WIDEN_MULT_EVEN_EXPR, VEC_WIDEN_MULT_ODD_EXPR): New.
9596         * cfgexpand.c (expand_debug_expr): Handle them.
9597         * expr.c (expand_expr_real_2): Likewise.
9598         * fold-const.c (fold_binary_loc): Likewise.
9599         * gimple-pretty-print.c (dump_binary_rhs): Likewise.
9600         * optabs.c (optab_for_tree_code): Likewise.
9601         * tree-cfg.c (verify_gimple_assign_binary): Likewise.
9602         * tree-inline.c (estimate_operator_cost): Likewise.
9603         * tree-pretty-print.c (dump_generic_node): Likewise.
9604         * tree.c (commutative_tree_code): Likewise.
9605         * tree-vect-generic.c (expand_vector_operations_1): Likewise.
9606         Handle type change before looking up optab.
9607         * optabs.h (OTI_vec_widen_umult_even, OTI_vec_widen_umult_odd): New.
9608         (OTI_vec_widen_smult_even, OTI_vec_widen_smult_odd): New.
9609         (vec_widen_umult_even_optab, vec_widen_umult_odd_optab): New.
9610         (vec_widen_smult_even_optab, vec_widen_smult_odd_optab): New.
9611         * genopinit.c (optabs): Initialize them.
9612         * doc/md.texi: Document them.
9613
9614 2012-07-10  Dehao Chen  <dehao@google.com>
9615
9616         * tree.h (phi_arg_d): New field.
9617         * tree-flow-inline.h (gimple_phi_arg_block): New function.
9618         (gimple_phi_arg_block_from_edge): New function.
9619         (gimple_phi_arg_set_block): New function.
9620         (gimple_phi_arg_has_block): New function.
9621         (redirect_edge_var_map_block): New function.
9622         * tree-flow.h (_edge_var_map): New field.
9623         * tree-ssa-live.c (remove_unused_locals): Mark phi_arg's block as used.
9624         * tree-eh.c (cleanup_empty_eh_merge_phis): Add block debug info for
9625         redirect_edge_var_map_add.
9626         * tree-outof-ssa.c (_elim_graph): New field.
9627         (insert_partition_copy_on_edge): New parameter.
9628         (insert_value_copy_on_edge): New parameter.
9629         (insert_rtx_to_part_on_edge): New parameter.
9630         (insert_part_to_rtx_on_edge): New parameter.
9631         (elim_graph_add_edge): New parameter.
9632         (elim_graph_remove_succ_edge): New parameter.
9633         (FOR_EACH_ELIM_GRAPH_SUCC): New parameter.
9634         (FOR_EACH_ELIM_GRAPH_PRED): New parameter.
9635         (new_elim_graph): Add block debug info.
9636         (clear_elim_graph): Likewise.
9637         (delete_elim_graph): Likewise.
9638         (elim_graph_add_node): Likewise.
9639         (elim_graph_add_edge): Likewise.
9640         (elim_graph_remove_succ_edge): Likewise.
9641         (eliminate_build): Likewise.
9642         (elim_forward): Likewise.
9643         (elim_unvisited_predecessor): Likewise.
9644         (elim_backward): Likewise.
9645         (elim_create): Likewise.
9646         (eliminate_phi): Likewise.
9647         (insert_backedge_copies): Likewise.
9648         * tree-into-ssa.c (insert_phi_nodes_for): Add block debug info for
9649         add_phi_arg.
9650         (rewrite_add_phi_arguments): Likewise.
9651         * tree-ssa-loop-im.c (execute_sm_if_changed): Likewise.
9652         * tree-ssa-tail-merge.c (replace_block_by): Likewise.
9653         * tree-ssa-threadupdate.c (copy_phi_args): Likewise.
9654         * tree-loop-distribution.c (update_phis_for_loop_copy): Likewise.
9655         * tree-ssa-loop-manip.c (create_iv): Likewise.
9656         (add_exit_phis_edge): Likewise.
9657         (split_loop_exit_edge): Likewise.
9658         (copy_phi_node_args): Likewise.
9659         (tree_transform_and_unroll_loop): Likewise.
9660         * value-prof.c (gimple_ic): Likewise.
9661         (gimple_stringop_fixed_value): Likewise.
9662         * tree-tailcall.c (add_successor_phi_arg): Likewise.
9663         (eliminate_tail_call): Likewise.
9664         (create_tailcall_accumulator): Likewise.
9665         (tree_optimize_tail_calls_1): Likewise.
9666         * tree-phinodes.c (add_phi_arg): Likewise.
9667         (make_phi_node): Likewise.
9668         (resize_phi_node): Likewise.
9669         (remove_phi_arg_num): Likewise.
9670         * omp-low.c (expand_parallel_call): Likewise.
9671         (expand_omp_for_static_chunk): Likewise.
9672         * tree-vect-loop-manip.c (slpeel_update_phis_for_duplicate_loop):
9673         Likewise.
9674         (slpeel_update_phi_nodes_for_guard1): Likewise.
9675         (slpeel_update_phi_nodes_for_guard2): Likewise.
9676         (slpeel_tree_duplicate_loop_to_edge_cfg): Likewise.
9677         (set_prologue_iterations): Likewise.
9678         (slpeel_tree_peel_loop_to_edge): Likewise.
9679         (vect_loop_versioning): Likewise.
9680         * tree-parloops.c (create_phi_for_local_result): Likewise.
9681         (transform_to_exit_first_loop): Likewise.
9682         (create_parallel_loop): Likewise.
9683         * ipa-split.c (split_function): Likewise.
9684         * tree-vect-loop.c (get_initial_def_for_induction): Likewise.
9685         (vect_create_epilog_for_reduction): Likewise.
9686         * tree-vect-data-refs.c (vect_setup_realignment): Likewise.
9687         * graphite-scop-detection.c (canonicalize_loop_closed_ssa): Likewise.
9688         * tree-ssa-phiopt.c (cond_store_replacement): Likewise.
9689         (cond_if_else_store_replacement_1): Likewise.
9690         * tree-cfgcleanup.c (remove_forwarder_block): Likewise.
9691         (remove_forwarder_block_with_phi): Likewise.
9692         * tree-ssa-pre.c (insert_into_preds_of_block): Likewise.
9693         * tree-predcom.c (initialize_root_vars): Likewise.
9694         (initialize_root_vars_lm): Likewise.
9695         * sese.c (sese_add_exit_phis_edge): Likewise.
9696         * tree-ssa-dce.c (forward_edge_to_pdom): Likewise.
9697         * tree-ssa.c (flush_pending_stmts): Likewise.
9698         (redirect_edge_var_map_add): Likewise.
9699         (ssa_redirect_edge): Likewise.
9700         * gimple-streamer-in.c (input_phi): Likewise.
9701         * tree-vect-stmts.c (vectorizable_load): Likewise.
9702         * tree-inline.c (copy_phis_for_bb): Likewise.
9703         * tree-ssa-phiprop.c (phiprop_insert_phi): Likewise.
9704         * tree-switch-conversion.c (fix_phi_nodes): Likewise.
9705         * tree-cfg.c (reinstall_phi_args): Likewise.
9706         (gimple_make_forwarder_block): Likewise.
9707         (add_phi_args_after_copy_edge): Likewise.
9708         (gimple_duplicate_sese_tail): Likewise.
9709
9710 2012-07-09  Oleg Endo  <olegendo@gcc.gnu.org>
9711
9712         PR target/53886
9713         * config/sh/sh.c (sequence_insn_p): New function.
9714         (find_barrier, sh_insn_length_adjustment): Use it.
9715
9716 2012-07-09  Iain Sandoe  <iain@codesourcery.com>
9717
9718         PR target/53283
9719         * config/i386/i386.c (ix86_fold_builtin): Call SUBTARGET_FOLD_BUILTIN
9720         if defined.
9721         * config/darwin.h: Rename TARGET_FOLD_BUILTIN to
9722         SUBTARGET_FOLD_BUILTIN.
9723         * config/rs6000/darwin.h: Map TARGET_FOLD_BUILTIN onto
9724         SUBTARGET_FOLD_BUILTIN.
9725
9726 2012-07-09  Iain Sandoe  <iain@codesourcery.com>
9727
9728         * config/darwin.h (SUBTARGET_C_COMMON_OVERRIDE_OPTIONS): Move NeXT
9729         runtime exceptions model setting from here ...
9730         * config/darwin.c (darwin_override_options): ... to here.
9731
9732 2012-07-09  Steven Bosscher  <steven@gcc.gnu.org>
9733
9734         PR tree-optimization/53887
9735         * tree-cfg.c (group_case_labels_stmt): Make non-static.
9736         * tree-flow.h (group_case_labels_stmt): Add prototype.
9737         * tree-switch-conversion.c (process_switch): Use group_case_labels_stmt
9738         to pre-process every switch.
9739
9740 2012-07-09  Jason Merrill  <jason@redhat.com>
9741
9742         PR c++/53882
9743         * tree.c (type_contains_placeholder_1): Handle NULLPTR_TYPE.
9744         (type_hash_eq): Likewise.
9745
9746 2012-07-09  Tom de Vries  <tom@codesourcery.com>
9747             Richard Guenther  <rguenther@suse.de>
9748
9749         * tree-ssa-ccp.c (optimize_unreachable): New function.
9750         (execute_fold_all_builtins): Use optimize_unreachable to optimize
9751         BUILT_IN_UNREACHABLE.  Don't optimize after BUILT_IN_UNREACHABLE.
9752
9753 2012-07-09  Richard Guenther  <rguenther@suse.de>
9754
9755         PR bootstrap/53898
9756         * graphite-optimize-isl.c: Make sure CU is not empty.
9757
9758 2012-07-09  Steven Bosscher  <steven@gcc.gnu.org>
9759
9760         * gensupport.c (init_rtx_reader_args_cb): Start counting code
9761         generating patterns from 1 to free up 0 for CODE_FOR_nothing.
9762         * gencodes.c (main): Give CODE_FOR_nothing the value 0.  Add
9763         the LAST_INSN_CODE marker at the end.
9764         * genoutput.c (nothing): New static struct data.
9765         (idata): Initialize to &nothing.
9766         (idata_end): Initialize to &nothing.next.
9767         (init_insn_for_nothing): New function to create dummy 'nothing' insn.
9768         (main): Use it.
9769         * genpeep.c (insn_code_number): Remove global variable.
9770         (gen_peephole): Take it as an argument instead.
9771         (main): Take insn_code_number from read_md_rtx.
9772         * optabs.h: Revert r161809:
9773         (optab_handlers): Change type of insn_code back to insn_code.
9774         (optab_handler, widening_optab_handler, set_optab_handler,
9775         set_widening_optab_handler, convert_optab_handler,
9776         set_convert_optab_handler, direct_optab_handler,
9777         set_direct_optab_handler): Remove int casts.
9778         Revert to treating the insn_code field as "insn_code".
9779
9780 2012-07-08  Oleg Endo  <olegendo@gcc.gnu.org>
9781
9782         * config/sh/sh.md (*return_i): Move trap_exit attribute check to ...
9783         * config/sh/sh.c (sh_cfun_trap_exit_p): ... this new function.
9784         * config/sh/sh-protos.h: Declare it.
9785
9786 2012-07-08  Steven Bosscher  <steven@gcc.gnu.org>
9787
9788         * mcf.c: Do not include tm.h, tree.h, and langhooks.h.
9789         (dump_fixup_graph): Use current_function_name.
9790         (adjust_cfg_counts): Likewise.
9791         * ira-conflicts.c: Do not include tree.h.
9792         (ira_build_conflicts): Use REG_USERVAR_P instead of DECL_ARTIFICIAL.
9793
9794 2012-07-08  Oleg Endo  <olegendo@gcc.gnu.org>
9795
9796         PR target/51244
9797         * config/sh/sh.md (*branch_true_eq, *branch_false_ne, nott): New insns.
9798
9799 2012-07-08  Steven Bosscher  <steven@gcc.gnu.org>
9800
9801         * basic-block.h: Re-group most prototypes per file.
9802         (struct edge_list): Remove num_blocks field.
9803         (dump_bb_info): Adjust prototypes.
9804         (dump_reg_info): Move prototype to regs.h.
9805         * function.h: Do not include tree.h.
9806         Include vec.h, vecir.h, input.h and machmode.h to compensate.
9807         (function_name): New prototype.
9808         * gimple.h: Include tree.h to compensate for basic-block.h change.
9809         * langhooks.h: Note that tree.h is only necessary for enum tree_code.
9810         * regs.h (dump_reg_info): Prototype here.
9811         * regset.h: Adjust file reference in comment.
9812         (debug_regset): Remove prototype.
9813         * rtl.h: Include flags.h for flag_var_tracking_assignments.
9814         (MAY_HAVE_DEBUG_INSNS): Define as flag_var_tracking_assignments
9815         instead of no-longer-available tree.h's MAY_HAVE_DEBUG_STMTS.
9816         (dump_reg_info, dump_flow_info): Remove prototypes.
9817         * bb-reorder.c (set_edge_can_fallthru_flag): Move from cfganal.c
9818         to here, the only user.  Make static.
9819         (reorder_basic_blocks): Call dump_reg_info before dump_flow_info.
9820         * cfg.c: Do not include tm.h, tree.h, rtl.h, hard-reg-set.h, regs.h,
9821         flags.h, function.h, except.h, diagnostic-core.h, tm_p.h, timevar.h,
9822         tree-pass.h, cfgloop.h, and tree-flow.h.
9823         Include basic-block.h, the first header I'd expect to be included.
9824         (reg_obstack): Move to df-core.c.
9825         (free_edge): Remove bogus ATTRIBUTE_UNUSED.
9826         (remove_edge_raw): Do not call tree-ssa's redirect_edge_var_map_clear.
9827         (redirect_edge_succ_nodup): Move to cfghooks.c.
9828         (dump_regset, debug_regset): Move to df-core.c.
9829         (dump_bb_info): Move to cfgrtl.c.
9830         (dump_reg_info): Move to regstat.c.
9831         (dump_flow_info): Move to cfgrtl.c.
9832         (debug_flow_info): Likewise.
9833         (dump_edge_info): Do not look at cfun, a CFG without cfun is nonsense.
9834         * cfganal.c: Do not include tm.h, rtl.h, obstack.h, hard-reg-set.h,
9835         insn-config.h, recog.h, diagnostic-core.h, tm_p.h, and cfgloop.h.
9836         (flow_active_insn_p, forwarder_block_p, can_fallthru,
9837         could_fall_through): Move to cfgrtl.c.
9838         (set_edge_can_fallthru_flag): Moved to bb-reorder.c.
9839         (create_edge_list): Do not set edge_list's removed num_blocks.
9840         (print_edge_list): Look at n_basic_blocks instead of num_blocks.
9841         (flow_nodes_print): Remove.
9842         (flow_edge_list_print): Remove.
9843         (inverted_post_order_compute): Use FOR_ALL_BB.
9844         * cfgrtl.c (dump_flow_info): Moved from cfg.c.
9845         Do not call dump_reg_info.
9846         (debug_flow_info): Moved from cfg.c
9847         (dump_bb_info): Moved from cfg.c.  Take 'verbose' argument
9848         to avoid looking at TDF_* flags from tree-pass.h.
9849         (flow_active_insn_p, forwarder_block_p, can_fallthru,
9850         could_fall_through): Moved from cfganal.c.
9851         (print_rtl_with_bb): Adjust dump_bb_info calls.
9852         * cfghooks.c (redirect_edge_succ_nodup): Moved from cfg.c.
9853         (remove_edge): Call redirect_edge_var_map_clear if IR_GIMPLE.
9854         (cfgcleanup.c): Look at MAY_HAVE_DEBUG_INSNS, not MAY_HAVE_DEBUG_STMTS.
9855         * cselib.c: Include tree.h with a FIXME.
9856         * df-core.c (reg_obstack): Moved from cfg.c.
9857         (dump_regset): Likewise.
9858         (debug_regset): Likewise.  Make a DEBUG_FUNCTION.
9859         * final.c (compute_alignments): Call dump_reg_info before
9860         dump_flow_info.
9861         * function.c (function_name): New function.
9862         (current_function_name): Use it.
9863         * ifcvt.c (rest_of_handle_if_conversion): Call dump_reg_info before
9864         dump_flow_info.
9865         * ira-conflicts.c: Include tree.h with a note.
9866         * regstat.c (dump_reg_info): Moved here from cfg.c.
9867         * loop-init.c: Include regs.h instead of hard-reg-set.h.
9868         (rtl_loop_init): Call dump_reg_info before dump_flow_info.
9869         (rtl_loop_done): Likewise.
9870         * mcf.c: Include tree.h before langhooks.h.
9871         * predict.c (maybe_hot_count_p): Assert we have cfun.
9872         (probably_never_executed_bb_p): Likewise.
9873         * profile.c (compute_branch_probabilities): Use gimple_dump_cfg
9874         instead of dump_flow_info.
9875         * sched-deps.c: Include tree.h with a FIXME.
9876         (call_may_noreturn_p): Add FIXME note why this function has to
9877         look at function decls instead of function decl flags.
9878         * sched-vis.c: Include tree.h with a FIXME.
9879         (print_rtl_slim): Adjust dump_bb_info uses.
9880         * statistics.c (statistics_fini_pass_2): Use current_function_name
9881         to avoid including tree.h.
9882         (statistics_counter_event): Use function_name for the same reason.
9883         (statistics_histogram_event): Likewise.
9884         * tracer.c (tracer): Remove bogus gcc_assert.  Use brief_dump_cfg
9885         instead of dump_flow_info.
9886         * var-tracking.c (variable_tracking_main_1): Call dump_reg_info
9887         before dump_flow_info.
9888         * doc/cfg.texi: Update CFG documentation.
9889         * Makefile.in (RTL_H): Depend on FLAGS_H.
9890         (GIMPLE_H): Depend on TREE_H.
9891         (FUNCTION_H): Depend on VEC_H, vecir.h, INPUT_H and MACHMODE_H,
9892         but no longer on TREE_H.
9893         (C_COMMON_H): Depend on TREE_H.
9894         (cselib.o, cse.o, cfganal.o, loop-init.o, ira-conflicts.o,
9895         sched-deps.o, sched-vis.o): Fixup dependencies.
9896
9897 2012-07-08  Steven Bosscher  <steven@gcc.gnu.org>
9898
9899         * alias.h: Do not include coretypes.h in header files.
9900         * cppbuiltin.h: Likewise.
9901         * double-int.h: Likewise.
9902         * gimple-fold.h: Likewise.
9903         * flags.h: Likewise.
9904         * tree-ssa-alias.h: Likewise.
9905         * gengtype.h (obstack_chunk_alloc, obstack_chunk_free,
9906         OBSTACK_CHUNK_SIZE): Define here to avoid dependency on coretypes.h.
9907         * Makefile.in (RTL_BASE_H): Depend on coretypes.h.
9908         (TREE_H): Likewise.
9909         (ALIAS_H): Do not depend on coretypes.h.
9910         (FLAGS_H): Likewise.
9911         (realmpfr.o): Depend on coretypes.h.
9912
9913 2012-07-08  Steven Bosscher  <steven@gcc.gnu.org>
9914
9915         * Makefile.in (gengtype-lex.o, gengtype-parse.o, gengtype-state.o,
9916         gengtype.o): Add -DGENERATOR_FILE manually for host gengtype objects.
9917
9918 2012-07-07  Richard Earnshaw  <rearnsha@arm.com>
9919
9920         * arm.h (TARGET_CPU_CPP_BUILTINS): Remove Maverick support.
9921         (TARGET_FPA): Delete definition.
9922         (TARGET_MAVERICK): Likewise.
9923         (TARGET_FPA_EMU2): Likewise.
9924         (arm_fp_model): Remove FPA and Maverick models.
9925         (arm_arch_cirrus): Delete declaration.
9926         (FLOAT_WORDS_BIG_ENDIAN): Delete definition.
9927         (FIXED_REGISTERS): Remove FPA and Maverick support.  Reorganize.
9928         (CALL_USED_REGISTERS): Likewise.
9929         (FIRST_FPA_REGNUM, LAST_FPA_REGNUM): Delete definition.
9930         (FIRST_VFP_REGNUM): Renumbered.
9931         (D7_VFP_REGNUM): Chain definition.
9932         (LAST_LO_VFP_REGNUM): Likewise.
9933         (FIRST_HI_VFP_REGNUM): Likewise.
9934         (LAST_HI_VFP_REGNUM): Likewise.
9935         (FIRST_IWMMXT_GR_REGNUM): Likewise.
9936         (LAST_IWMMXT_GR_REGNUM): Likewise.
9937         (FIRST_IWMMXT_REGNUM): Likewise.
9938         (LAST_IWMMXT_REGNUM): Likewise.
9939         (FRAME_POINTER_REGNUM): Renumbered.
9940         (ARG_POINTER_REGNUM): Renumbered.
9941         (FIRST_PSEUDO_REGISTER): Remove FPA and Maverick registers.
9942         (FIRST_CIRRUS_FP_REGNUM, LAST_CIRRUS_FP_REGNUM): Delete definitions.
9943         (HARD_REGNO_REGNUM): Remove FPA support.
9944         (REG_ALLOC_ORDER): Remove FPA and Maverick registers.  Reorganize.
9945         (reg_class): Likewise.
9946         (REG_CLASS_NAMES): Likewise.
9947         (REG_CLASS_CONTENTS): Likewise.
9948         (CANNOT_CHANGE_MODE_CLASS): Never true.  Update comment.
9949         (SECONDARY_INPUT_RELOAD_CLASS): Remove Maverick support.
9950         (CLASS_MAX_NREGS): Remove FPA and Maverick support.
9951         * aout.h (REGISTER_NAMES): Remove FPA and Maverick registers.
9952         Reorganize.  Use AAPCS preferred names.
9953         (ADDITIONAL_REGISTER_NAMES): Remove aliases for Maverick.  Update
9954         comments.
9955         (OVERLAPPING_REGISTER_NAMES): Update register numbering.
9956         * arm.c (FL_CIRRUS): Delete definition.
9957         (arm_arch_cirrus): Delete variable.
9958         (arm_float_words_big_endian): Delete function.
9959         (cirrus_memory_offset): Delete function.
9960         (output_mov_long_double_fpa_from_arm): Delete function.
9961         (output_mov_long_double_arm_from_fpa): Delete function.
9962         (output_mov_double_fpa_from_arm): Delete function.
9963         (output_mov_double_arm_from_fpa): Delete function.
9964         (emit_sfm): Delete function.
9965         (maybe_get_arm_condition_code): Update comment.
9966         (arm_file_start): Always use softvfp for softfloat systems.
9967         (thumb_core_reg_alloc_order): Adjust for updated register allocation.
9968         (arm_option_override): Remove FPA and Maverick support.  Always
9969         default to vfp as the fallback FPU format.
9970         (use_return_insn): Remove FPA support.
9971         (arm_get_frame_offsets): Likewise.
9972         (arm_save_coproc_regs): Likewise.
9973         (arm_canonicalize_comparison): Remove Maverick support.
9974         (arm_select_cc_mode): Likewise.
9975         (arm_gen_compare_reg): Likewise.
9976         (arm_print_operand): Likewise.
9977         (arm_libcall_value_1): Remove FPA and Maverick support.
9978         (arm_function_value_regno_p): Likewise.
9979         (arm_apply_result_size): Likewise.
9980         (arm_legitimate_index_p): Likewise.
9981         (thumb2_legitimate_index_p): Likewise.
9982         (legitimize_reload_address): Likewise.
9983         (arm_register_move_cost): Likewise.
9984         (arm_hard_regno_mode_ok): Likewise.
9985         (arm_regno_class): Likewise.
9986         (arm_dbx_register_number): Likewise.
9987         (arm_emit_unwind_sequence): Likewise.
9988         (arm_conditional_register_usage): Likewise.
9989         * arm-protos.h (neg_const_double_rtx_ok_for_fpa): Remove declaration.
9990         (cirrus_memory_offset): Likewise.
9991         (output_move_long_double_fpa_from_arm): Likewise.
9992         (output_move_long_double_arm_from_fpa): Likewise.
9993         (output_move_double_fpa_from_arm): Likewise.
9994         (output_move_double_arm_from_fpa): Likewise.
9995         (arm_float_words_big_endian): Likewise.
9996         * arm.md (CC_REGNUM): Renumbered.
9997         (VFPCC_REGNUM): Moved here.  Renumbered.
9998         (FPA_F0_REGNUM, FPA_F7_REGNUM): Delete.
9999         (attr fpu): Remove FPA and Maverick support.
10000         * vfp.md (VFPCC_REGNUM): Delete.  Moved to arm.md.
10001         * arm-cores.def (ep9312): Remove Maverick support.
10002         * arm-arches.def (ep9312): Delete architecture.
10003         * arm-tables.opt: Regenerated.
10004
10005         * arm/linux-elf.h (FPUTYPE_DEFAULT): Set to vfp.
10006
10007 2012-07-07  Steven Bosscher  <steven@gcc.gnu.org>
10008
10009         PR tree-optimization/53881
10010         * tree-switch-conversion.c (emit_case_bit_tests): Do not rely on
10011         comparing labels to establish uniqueness of a switch case target,
10012         use the CFG instead.
10013
10014 2012-07-07  Ulrich Weigand  <ulrich.weigand@linaro.org>
10015
10016         * combine.c (force_to_mode) [LSHIFTRT]: Avoid undefined behaviour
10017         due to negative shift amount.
10018
10019 2012-07-07  Hans-Peter Nilsson  <hp@axis.com>
10020
10021         Fix configure test for "stack protector support in target C library".
10022         * configure.ac (test_prefix, test_exec_prefix): Move setting from
10023         inside sysroot handling to before and outside it.
10024         * configure: Regenerate.
10025
10026 2012-07-06  Kai Tietz  <ktietz@redhat.com>
10027
10028         PR bootstrap/52947
10029         * config/i386/mingw32.h (NATIVE_SYSTEM_HEADER_DIR): Define it always
10030         as "/mingw/include".
10031
10032 2012-07-06  Alexandre Oliva  <aoliva@redhat.com>
10033
10034         PR debug/53820
10035         * var-tracking.c (vt_add_function_parameter): Convert
10036         internal_arg_pointer into arg_pointer-based address even
10037         without DRAP.
10038
10039 2012-07-06  Alexandre Oilva  <aoliva@redhat.com>
10040
10041         PR rtl-optimization/53827
10042         PR debug/53671
10043         PR debug/49888
10044         * alias.c (memrefs_conflict_p): Adjust offset and size by the
10045         same amount for alignment ANDs.
10046
10047 2012-07-06  Tom de Vries  <tom@codesourcery.com>
10048
10049         PR tree-optimization/51879
10050         * tree-ssa-sccvn.c (copy_reference_ops_from_call)
10051         (visit_reference_op_call): Handle case that lhs is not an SSA_NAME.
10052         (visit_use): Also call visit_reference_op_call for calls with a vdef.
10053
10054 2012-07-06  Tom de Vries  <tom@codesourcery.com>
10055
10056         PR tree-optimization/52009
10057         * tree-ssa-tail-merge.c (gimple_equal_p): For GIMPLE_ASSIGN, compare
10058         value numbers of gimple_vdef.
10059         * tree-ssa-sccvn.h (vn_reference_insert): Add vdef parameter to
10060         prototype.
10061         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Handle MODIFY_EXPR.
10062         (vn_reference_insert): Add and handle vdef parameter.
10063         (visit_reference_op_load): Add argument to vn_reference_insert call.
10064         (visit_reference_op_store): Find value number of vdef of store.  Insert
10065         value number of vdef of store.
10066
10067 2012-07-06  Uros Bizjak  <ubizjak@gmail.com>
10068
10069         * config/i386/i386.md (simple lea to add peephole): Also transform
10070         RTXes where second PLUS operand matches output.
10071
10072 2012-07-06  Uros Bizjak  <ubizjak@gmail.com>
10073
10074         * config/i386/i386.c (construct_plt_address): Make static.
10075         * config/i386/i386-protos.h (construct_plt_address): Remove.
10076
10077 2012-07-06  Nick Clifton  <nickc@redhat.com>
10078
10079         * config/mn10300/mn10300.c (mn10300_encode_section_info): Call
10080         default_encode_section_info.
10081
10082 2012-07-06  Uros Bizjak  <ubizjak@gmail.com>
10083
10084         PR target/53853
10085         * config/i386/i386.c (x86_output_mi_thunk): For CM_LARGE_PIC model,
10086         emit PIC sequence for fnaddr symbol reference in advance.
10087
10088 2012-07-06  Eric Botcazou  <ebotcazou@adacore.com>
10089
10090         Revert
10091         2012-06-14  Eric Botcazou  <ebotcazou@adacore.com>
10092
10093         * dwarf2out.c (function_possibly_abstracted_p): New static function.
10094         (gen_subprogram_die): Use it function_possibly_abstracted_p in lieu of
10095         cgraph_function_possibly_inlined_p.
10096         (gen_inlined_subroutine_die): Return if the origin is to be ignored.
10097         (process_scope_var): Do not emit concrete instances of abstracted
10098         nested functions from here.
10099         (gen_decl_die): Emit the abstract instance if the function is possibly
10100         abstracted and not only possibly inlined.
10101         (dwarf2out_finish): Find the first non-abstract parent instance and
10102         attach concrete instances on the limbo list to it.
10103
10104 2012-07-05  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
10105             Julian Brown  <julian@codesourcery.com>
10106
10107         PR target/48941
10108         PR target/51980
10109         * config/arm/neon-gen.ml (return_by_ptr): Delete.
10110         (print_function): Handle empty strings.
10111         (return): Delete use of return_by_ptr.
10112         (mask_shape_for_shuffle): New function.
10113         (mask_elems): Likewise.
10114         (shuffle_fn): Likewise.
10115         (params): Simplify and remove use of return_by_ptr.
10116         (get_shuffle): New function.
10117         (print_variant): Update.
10118         * config/arm/neon.ml (rev_elems): New function.
10119         (permute_range): Likewise.
10120         (zip_range): Likewise.
10121         (uzip_range): Likewise.
10122         (trn_range): Likewise.
10123         (zip_elems): Likewise.
10124         (uzip_elems): Likewise.
10125         (trn_elems): Likewise.
10126         (features): New enumeration Use_shuffle. Delete ReturnPtr.
10127         (pf_su_8_16): New.
10128         (suf_32): New.
10129         (ops): Update entries for Vrev64, Vrev32, Vrev16, Vtr, Vzip, Vuzp.
10130         * config/arm/arm_neon.h: Regenerate.
10131
10132 2012-07-05  Richard Guenther  <rguenther@suse.de>
10133
10134         * tree-pretty-print.c (dump_generic_node): Properly test
10135         the result of exact_log2.
10136
10137 2012-07-05  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
10138
10139         * config/s390/s390-protos.h (s390_expand_movmem)
10140         (s390_expand_cmpmem): Add return value.
10141         * config/s390/s390.c (s390_expand_movmem, s390_expand_cmpmem):
10142         Return FALSE to use the library function in some cases.
10143         * config/s390/s390.md (movmem, cmpmem): Evaluate return value of C
10144         helper functions.
10145
10146 2012-07-05  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
10147
10148         * config.gcc: Enable ifunc attribute by default on s390 and s390x.
10149
10150 2012-07-05  Steven Bosscher  <steven@gcc.gnu.org>
10151
10152         * expr.c (try_casesi): Remove bogus ATTRIBUTE_UNUSED markers.
10153         * stmt.c (dump_case_nodes): New.
10154         (expand_case): Split out code generation parts into new functions.
10155         (expand_switch_as_decision_tree_p): Split out from expand_case.
10156         (emit_case_decision_tree): Likewise.
10157         (emit_case_dispatch_table): Likewise.
10158
10159 2012-07-05  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
10160
10161         * config/arm/iterators.md (SDF): New mode iterator.
10162         (V_if_elem): Add support for SF and DF modes.
10163         (V_reg): Likewise.
10164         (F_constraint): New mode iterator attribute.
10165         (F_fma_type): Likewise.
10166         config/arm/vfp.md (fma<SDF:mode>4): New pattern.
10167         (*fmsub<SDF:mode>4): Likewise.
10168         (*fmnsub<SDF:mode>4): Likewise.
10169         (*fmnadd<SDF:mode>4): Likewise.
10170
10171 2012-07-04  Uros Bizjak  <ubizjak@gmail.com>
10172
10173         * expmed.c (expand_mult): Initialize coeff and is_neg.
10174
10175 2012-07-04  Oleg Endo  <olegendo@gcc.gnu.org>
10176
10177         * config/sh/predicates.md (zero_extend_operand): New predicate.
10178         * config/sh/sh.md (zero_extendhisi2): Simplify by using new
10179         zero_extend_operand predicate.
10180         (zero_extendqisi2): Likewise.
10181
10182 2012-07-04  Uros Bizjak  <ubizjak@gmail.com>
10183
10184         PR middle-end/53321
10185         * ipa.c (symtab_remove_unreachable_nodes): Partially revert r187375
10186         to not call cgraph_propagate_frequency if something was changed.
10187
10188 2012-07-04  Richard Guenther  <rguenther@suse.de>
10189
10190         PR middle-end/53433
10191         * gimple-fold.c (get_base_constructor): Do not return an
10192         error_mark_node DECL_INITIAL.
10193
10194 2012-07-04  Richard Guenther  <rguenther@suse.de>
10195
10196         PR tree-optimization/53844
10197         * tree-ssa-dse.c (dse_possible_dead_store_p): Properly handle
10198         the loop virtual PHI.
10199
10200 2012-07-04  Richard Guenther  <rguenther@suse.de>
10201
10202         PR tree-optimization/53849
10203         * tree-cfg.c (move_stmt_op): Only call add_referenced_var
10204         for duplicated locals.  Use add_referenced_var_1 to avoid
10205         pushing/popping cfun.
10206
10207 2012-07-04  Kai Tietz  <ktietz@redhat.com>
10208
10209         * config/i386/winnt.c (i386_pe_reloc_rw_mask): New function.
10210         * config/i386/i386-protos.h (i386_pe_reloc_rw_mask): Add
10211         prototype.
10212         * config/i386/cygming.h (TARGET_ASM_RELOC_RW_MASK): Define
10213         as i386_pe_reloc_rw_mask.
10214
10215 2012-07-04  Richard Guenther  <rguenther@suse.de>
10216
10217         * tree.c (find_decls_types_r): Handle TYPE_CONTEXT the same
10218         as in free_lang_data_in_type.
10219
10220 2012-07-04  Tobias Grosser <tobias@grosser.es>
10221             Michael Matz  <matz@suse.de>
10222
10223         * Makefile.in (OBJS): Add graphite-optimize-isl.o.
10224         (graphite-optimize-isl.o): Add dependencies.
10225         * common.opt (floop-nest-optimize): New flag.
10226         * doc/invoke.texi (floop-nest-optimize): Document.
10227         * graphite-dependences.c (compute_deps): Export.
10228         * graphite-poly.h (compute_deps): Declare.
10229         * graphite-optimize-isl.c: New file.
10230         * graphite-poly.c (apply_poly_transforms): Run the loop
10231         nest optimizer.
10232         * tree-ssa-loop.c (gate_graphite_transforms): Enable graphite
10233         if -floop-nest-optimize is enabled.
10234
10235 2012-07-03  Oleg Endo  <olegendo@gcc.gnu.org>
10236
10237         * config/sh/predicates.md (logical_and_operand): New predicate.
10238         * config/sh/constraints.md (Jmb, Jmw): New constraints.
10239         * config/sh/sh.md (andsi3): Move expander above insns.  Add handling
10240         of 0xFFFF constant.  Use logical_and_operand predicate and
10241         satisfies_constraint_Jmb, satisfies_constraint_Jmw.
10242         (*andsi3_compact): Make it an insn_and_split.  Use
10243         logical_and_operand predicate.  Add Jmb,Jmw alternatives.
10244
10245 2012-07-03  Jason Merrill  <jason@redhat.com>
10246
10247         PR c++/53826
10248         * tree.c (build_zero_cst): Handle NULLPTR_TYPE.
10249
10250 2012-07-03  Nick Clifton  <nickc@redhat.com>
10251
10252         * config/mep/mep.c (mep_reorg_regmove): Use
10253         next_nonnote_non_debug_insn to advance to the next insn.  Do not
10254         expect delete_insn to return an rtx.
10255
10256 2012-07-03  Richard Guenther  <rguenther@suse.de>
10257
10258         * doc/install.texi (CLooG): Clarify how CLooG needs to be
10259         configured and that it needs to be built against ISL 0.10.
10260
10261 2012-07-03  Uros Bizjak  <ubizjak@gmail.com>
10262
10263         * config/i386/i386.c (ix86_option_override_internal): Fix wrong
10264         code model string in the error message.
10265
10266 2012-07-03  Uros Bizjak  <ubizjak@gmail.com>
10267
10268         PR target/53811
10269         * config/i386/i386.c (x86_output_mi_thunk): Check if fnaddr satisfies
10270         sibcall_insn_operand.  Move it to a temporary register if not.
10271
10272 2012-07-03  Andreas Schwab  <schwab@linux-m68k.org>
10273
10274         PR target/28896
10275         * config/m68k/m68k.c (m68k_option_override): Reset stack_limit_rtx
10276         if !TARGET_68020.
10277
10278 2012-07-03  Uros Bizjak  <ubizjak@gmail.com>
10279
10280         * config/i386/xmmintrin.h (_mm_sfence): Use __builtin_ia32_pause.
10281
10282 2012-07-03  Roland McGrath  <mcgrathr@google.com>
10283
10284         * configure.ac (HAVE_AS_IX86_REP_LOCK_PREFIX): Also require that the
10285         assembler accept 'rep bsf ...', 'rep bsr ...', 'rep ret' and 'rep nop'.
10286         * configure: Regenerated.
10287         * config/i386/i386.md (simple_return_internal_long): Use %;
10288         (ctz<mode>2): Likewise.
10289         (*pause): Likewise.
10290
10291 2012-07-02  Oleg Endo  <olegendo@gcc.gnu.org>
10292
10293         PR target/51244
10294         * config/sh/predicates.md (t_reg_operand, negt_reg_operand): New
10295         predicates.
10296         * config/sh/sh-protos.h (get_t_reg_rtx): New prototype.
10297         * config/sh/sh.c (get_t_reg_rtx): New function.  Use it when invoking
10298         gen_branch_true and gen_branch_false.
10299         * config/sh/sh.md: Use get_t_reg_rtx when invoking gen_branch_true and
10300         gen_branch_false.
10301         (branch_true, branch_false): Use t_reg_operand predicate.
10302         (*branch_true, *branch_false): Delete.
10303         (movt): Use t_reg_operand predicate.
10304         (*negnegt): Use negt_reg_operand predicate and fold little and big
10305         endian variants.
10306         (*movtt): Use t_reg_operand and fold little and big endian variants.
10307         (*movt_qi): Delete.
10308
10309 2012-07-02  Steven Bosscher  <steven@gcc.gnu.org>
10310
10311         * stmt.c (emit_case_bit_tests): Remove.
10312         (expand_case): Remove expand_switch_using_bit_tests_p code.
10313         * tree-switch-conversion.c (hoist_edge_and_branch_if_true): New.
10314         (MAX_CASE_BIT_TESTS): Moved from stmt.c to here.
10315         (lshift_cheap_p): Likewise.
10316         (expand_switch_using_bit_tests_p): Likewise.
10317         (struct case_bit_test): Likewise.
10318         (case_bit_test_cmp): Likewise.
10319         (emit_case_bit_tests): New implementation for GIMPLE.
10320         (gen_inbound_check): Do not release post-dominator info here.
10321         (process_switch): Reorder code.  Expand as bit tests if it
10322         looks like a win.
10323         (do_switchconv): Release post-dominator info here if something changed.
10324         (struct gimple_opt_pass): Verify more.
10325         * tree.h (expand_switch_using_bit_tests_p): Remove prototype.
10326
10327 2012-07-02  Martin Jambor  <mjambor@suse.cz>
10328
10329         PR middle-end/38474
10330         * ipa-prop.c (compute_known_type_jump_func): Put BINFO check before a
10331         dynamic type change check.
10332
10333 2012-07-02  Richard Guenther  <rguenther@suse.de>
10334             Michael Matz  <matz@suse.de>
10335             Tobias Grosser <tobias@grosser.es>
10336             Sebastian Pop <sebpop@gmail.com>
10337
10338         * Makefile.in: Remove PPL flags in favor of ISL ones.
10339         (BACKENDLIBS): Remove PPL libs.
10340         (INCLUDES): Remove PPL includes in favor of ISL ones.
10341         (graphite-clast-to-gimple.o): Remove graphite-dependences.h and
10342         graphite-cloog-compat.h dependencies.
10343         (graphite-dependences.o): Likewise.
10344         (graphite-poly.o): Likewise.
10345         * configure.ac: Declare ISL vars instead of PPL ones.
10346         * configure: Regenerated.
10347         * doc/install.texi: Replace PPL requirement documentation with ISL one.
10348         * graphite-blocking.c: Remove PPL code, add ISL equivalent.
10349         * graphite-clast-to-gimple.c: Likewise.
10350         * graphite-dependences.c: Likewise.
10351         * graphite-interchange.c: Likewise.
10352         * graphite-poly.h: Likewise.
10353         * graphite-poly.c: Likewise.
10354         * graphite-sese-to-poly.c: Likewise.
10355         * graphite.c: Likewise.
10356         * graphite-scop-detection.c: Re-arrange includes.
10357         * graphite-cloog-util.c: Remove.
10358         * graphite-cloog-util.h: Likewise.
10359         * graphite-ppl.h: Likewise.
10360         * graphite-ppl.c: Likewise.
10361         * graphite-dependences.h: Likewise.
10362
10363 2012-07-02  Richard Guenther  <rguenther@suse.de>
10364
10365         Merge from graphite branch
10366         2011-07-21  Tobias Grosser  <tobias@grosser.es>
10367
10368         * Makefile.in (graphite-clast-to-gimple.o, graphite-cloog-util.o):
10369         Remove graphite-cloog-util.h.
10370         * graphite-clast-to-gimple.c (gcc_type_for_iv_of_clast_loop,
10371         build_iv_mapping, translate_clast_user, translate_clast,
10372         free_scattering, initialize_cloog_names, build_cloog_prog,
10373         create_params_index): Do not use old compatibility functions.
10374         (clast_name_to_index, set_cloog_options): Remove code for legacy cloog.
10375         * graphite-cloog-util.c (openscop_print_cloog_matrix): Do not use old
10376         compatibility functions.
10377         (new_Cloog_Scattering_from_ppl_Polyhedron): Remove code for legacy
10378         cloog.
10379         * graphite-cloog-util.h: Remove include of graphite-cloog-util.h.
10380         * graphite.c (graphite.c): Do not call outdated cloog_initialize() and
10381         cloog_finalize().
10382         * graphite-cloog-compat.h: Remove.
10383
10384         2011-08-09  Tobias Grosser <tobias@grosser.es>
10385
10386         * graphite-clast-to-gimple.c (new_clast_name_index): Store a copy
10387         of the string, no just a reference.
10388         (clast_name_index): Add a new field, that specifies if we need to free
10389         the name.
10390         (free_clast_name_index): If necessary, free the name string.
10391         (clast_name_index_elt_info): Calculate the hash based on the string
10392         content, not the memory location it is stored in.
10393         (clast_name_to_level): Specify that we do not need to free the name.
10394         (clast_name_to_index): Dito.
10395         (clast_name_to_lb_ub): Dito.
10396         (eq_clast_name_indexes): Compare the strings, not their base pointers.
10397         (free_scattering): Removed.
10398         (initialize_cloog_names): Renamed to add_names_to_union_domain().
10399         (add_names_to_union_domain): Changed to work on a union_domain,
10400         instead of a CloogNames structure.
10401         (build_cloog_prog): Removed.
10402         (build_cloog_union_domain): New.
10403         (generate_cloog_input): New.
10404         (scop_to_clast): Use CloogInput instead of CloogProgram.
10405         (print_generated_program): Adapt to new scop_to_clast() and do not
10406         print the CloogProgram any more.
10407         (create_params_index): Removed, functionality integrated in
10408         add_names_to_union_domain().
10409         (gloog): Adapt to new scop_to_clast().
10410         * graphite-clast-to-gimple.h (scop_to_clast): Remove.
10411
10412         2012-01-11  Tobias Grosser <tobias@grosser.es>
10413
10414         * graphite-clast-to-gimple.c (clast_name_to_index,
10415         clast_name_to_lb_ub, clast_name_to_gcc): Change types.
10416         (clast_to_gcc_expression): Add clast_expr_name as a new
10417         case. Do not assume a clast_expr_term points always to a
10418         clast_expr_name.
10419         (type_for_clast_term): Do not assume a clast_expr_term points always to
10420         a clast_expr_name.
10421         (type_for_clast_name): New.
10422         (type_for_clast_expr): Add clast_expr_name as a new case.
10423
10424         2011-08-03  Sebastian Pop <sebpop@gmail.com>
10425
10426         * graphite-cloog-util.c (new_Cloog_Domain_from_ppl_Polyhedron,
10427         new_Cloog_Scattering_from_ppl_Polyhedron,
10428         new_Cloog_Domain_from_ppl_Pointset_Powerset): Remove ATTRIBUTE_UNUSED.
10429
10430 2012-07-02  Jakub Jelinek  <jakub@redhat.com>
10431
10432         PR tree-optimization/53645
10433         * tree-vect-generic.c (expand_vector_divmod): Use TYPE_MODE (type)
10434         instead of TYPE_MODE (wider_type) as can_vec_perm_p argument.
10435
10436 2012-07-01  Wei Guozhi  <carrot@google.com>
10437
10438         PR target/53447
10439         * config/arm/arm-protos.h (const_ok_for_dimode_op): New prototype.
10440         * config/arm/arm.c (const_ok_for_dimode_op): New function.
10441         * config/arm/constraints.md (Dd): New constraint.
10442         * config/arm/predicates.md (arm_adddi_operand): New predicate.
10443         * config/arm/arm.md (adddi3): Extend it to handle constants.
10444         (arm_adddi3): Likewise.
10445         (addsi3_carryin_<optab>): Extend it to handle sbc case.
10446         (addsi3_carryin_alt2_<optab>): Likewise.
10447         * config/arm/neon.md (adddi3_neon): Extend it to handle constants.
10448
10449 2012-06-30  Nathan Sidwell  <nathan@acm.org>
10450
10451         * coverage.c (bbg_file_stamp): New.
10452         (read_counts_file): Merge incoming stamp with bbg_file_stamp.
10453         (build_info): Write bbg_file_stamp.
10454         (coverage_init): Initialize bbg_file_stamp.  Read counts file
10455         before writing graph header.
10456         (coverage_finish): Don't unlink the data file if we can generate a
10457         unique file stamp.
10458         * tree.h (crc32_unsigned): Declare.
10459         * tree.c (crc32_unsigned_bits): New, broken out of ...
10460         (crc32_byte): ... here.  Use it.
10461         (crc32_unsigned): New.
10462
10463 2012-06-29  Cary Coutant  <ccoutant@google.com>
10464
10465         * dwarf2out.c (add_pubname_string): Don't check for want_pubnames.
10466         (gen_subprogram_die): Don't add pubname if want_pubnames is false.
10467         (gen_variable_die): Likewise.
10468         (gen_namespace_die): Likewise.
10469
10470 2012-06-29  Eric Botcazou  <ebotcazou@adacore.com>
10471
10472         * tree-eh.c (lower_try_finally_switch): Really put the location of the
10473         last statement of the finally block onto the switch.
10474
10475 2012-06-29  H.J. Lu  <hongjiu.lu@intel.com>
10476
10477         PR target/53539
10478         * config/i386/gnu-user64.h (WCHAR_TYPE): Use "int" only for
10479         TARGET_LP64.
10480
10481 2012-06-29  Sterling Augustine  <saugustine@google.com>
10482
10483         * dwarf2out.c (add_pubname): Add comment.
10484         (add_pubtype): Fix indentation.
10485         (gen_enumeration_type_die): Likewise.
10486
10487 2012-06-29  Jakub Jelinek  <jakub@redhat.com>
10488
10489         * tree-vect-generic.c (expand_vector_divmod): For even/odd
10490         widening multiply, put even always as first argument to VEC_PERM_EXPR.
10491
10492 2012-06-29  Richard Henderson  <rth@redhat.com>
10493
10494         * tree-vect-generic.c: Include target.h.
10495         (expand_vector_divmod): Use builtin_mul_widen_even/odd if supported.
10496         * Makefile.in (tree-vect-generic.o): Update.
10497
10498 2012-06-29  Steven Bosscher  <steven@gcc.gnu.org>
10499
10500         * configure.ac: Remove special gtfiles case for C.
10501         * configure: Regenerate.
10502         * Makefile.in: Remove C front-end hooks and build hooks that
10503         will be picked up from c/Make-lang.in now.
10504         Add tree-mudflap to C_COMMON_OBJS.
10505         * gengtype.c (files_rules): Adjust gt-files for c/c-decl.c.
10506         * config/vms/vms.c: Look for c-tree.h in c/.
10507         * doc/gty.texi: Remove reference to c-config-lang.in.
10508         * doc/sourcebuild.texi: Document the c/ subdirectory.
10509
10510 2012-06-29  Steven Bosscher  <steven@gcc.gnu.org>
10511
10512         * system.h (CASE_USE_BIT_TESTS): Poison.
10513         * stmt.c (CASE_USE_BIT_TESTS): Fold away into its only user ...
10514         (expand_switch_using_bit_tests_p): ...here.
10515         * doc/tm.texi.in (CASE_USE_BIT_TESTS): Remove documentation.
10516         * doc/tm.texi (CASE_USE_BIT_TESTS): Regenerate.
10517
10518 2012-06-29  Steven Bosscher  <steven@gcc.gnu.org>
10519
10520         * system.h (IFCVT_EXTRA_FIELDS): Poison.
10521         (IFCVT_INIT_EXTRA_FIELDS): Poison.
10522         * basic-block.h (struct ce_if_block): Remove IFCVT_EXTRA_FIELDS.
10523         * ifcvt.c (find_if_header): Use IFCVT_MACHDEP_INIT instead of
10524         IFCVT_INIT_EXTRA_FIELDS.
10525         * gengtype-parse.c (struct_field_seq): Remove obsolete comment.
10526         * config/frv/frv.h (IFCVT_INIT_EXTRA_FIELDS): Rename to
10527         IFCVT_MACHDEP_INIT.
10528         * config/frv/frv.c (frv_ifcvt_init_extra_fields): Rename to
10529         frv_ifcvt_machdep_init.
10530         * doc/tm.texi.in (IFCVT_INIT_EXTRA_FIELDS, IFCVT_EXTRA_FIELDS):
10531         Remove documentation.
10532         (IFCVT_MACHDEP_INIT): Document.
10533         * doc/tm.texi: Regenerate.
10534
10535 2012-06-29  Nick Clifton  <nickc@redhat.com>
10536
10537         * config/lm32/lm32.c (lm32_compute_frame_size): Fix typo.
10538
10539 2012-06-29  Jakub Jelinek  <jakub@redhat.com>
10540
10541         * tree-vect-stmts.c (vectorizable_operation): Check both
10542         VEC_WIDEN_MULT_LO_EXPR and VEC_WIDEN_MULT_HI_EXPR optabs.
10543         Verify that operand[0]'s mode is TYPE_MODE (wide_vectype).
10544
10545 2012-06-28  Richard Henderson  <rth@redhat.com>
10546
10547         * doc/generic.texi (MULT_HIGHPART_EXPR): Document it.
10548
10549 2012-06-28  Jakub Jelinek  <jakub@redhat.com>
10550
10551         PR tree-optimization/51581
10552         * tree-vect-stmts.c (permute_vec_elements): Add forward decl.
10553         (vectorizable_operation): Handle vectorization of MULT_HIGHPART_EXPR
10554         also using VEC_WIDEN_MULT_*_EXPR or builtin_mul_widen_* plus
10555         VEC_PERM_EXPR if vector MULT_HIGHPART_EXPR isn't supported.
10556         * tree-vect-patterns.c (vect_recog_divmod_pattern): Use
10557         MULT_HIGHPART_EXPR instead of VEC_WIDEN_MULT_*_EXPR and shifts.
10558
10559         PR tree-optimization/53645
10560         * tree-vect-generic.c (expand_vector_divmod): Use MULT_HIGHPART_EXPR
10561         instead of VEC_WIDEN_MULT_{HI,LO}_EXPR followed by VEC_PERM_EXPR
10562         if possible.
10563
10564 2012-06-28  Georg-Johann Lay  <avr@gjlay.de>
10565
10566         PR 53595
10567         * config/avr/avr.c (avr_hard_regno_call_part_clobbered): New.
10568         * config/avr/avr-protos.h (avr_hard_regno_call_part_clobbered): New.
10569         * config/avr/avr.h (HARD_REGNO_CALL_PART_CLOBBERED): Forward to
10570         avr_hard_regno_call_part_clobbered.
10571
10572 2012-06-28  Richard Guenther  <rguenther@suse.de>
10573
10574         PR middle-end/53790
10575         * expr.c (expand_expr_real_1): Verify if the type is complete
10576         before inspecting its size.
10577
10578 2012-06-28  Andreas Schwab  <schwab@linux-m68k.org>
10579
10580         * doc/include/gpl.texi: Remove.
10581         * doc/sourcebuild.texi (Texinfo Manuals): Don't mention gpl.texi.
10582
10583 2012-06-28  Jakub Jelinek  <jakub@redhat.com>
10584
10585         PR tree-optimization/53645
10586         * tree-vect-generic.c (add_rshift): New function.
10587         (expand_vector_divmod): New function.
10588         (expand_vector_operation): Use it for vector integer
10589         TRUNC_{DIV,MOD}_EXPR by VECTOR_CST.
10590         * tree-vect-patterns.c (vect_recog_divmod_pattern): Replace
10591         unused lguup variable with dummy_int.
10592
10593 2012-06-28  OLivier Hainque  <hainque@adacore.com>
10594
10595         * expr.c (convert_move): Latch mem integer inputs into a
10596         register before expanding a multi-instructions sequence.
10597
10598 2012-06-28  Alexandre Oliva  <aoliva@redhat.com>
10599             Uros Bizjak  <ubizjak@gmail.com>
10600             Jakub Jelinek  <jakub@redhat.com>
10601
10602         PR debug/53706
10603         PR debug/47624
10604         * var-tracking.c (vt_emit_notes): Release loc_exp_dep_pool...
10605         (vt_finalize): ... here instead, if needed.
10606
10607 2012-06-28  Alexandre Oliva  <aoliva@redhat.com>
10608
10609         PR debug/53740
10610         PR debug/52983
10611         PR debug/48866
10612         * dce.c (word_dce_process_block): Check whether inserting debug
10613         temps are needed even for needed insns.
10614         (dce_process_block): Likewise.
10615         * df-problems.c (dead_debug_add): Add comment about multi-regs.
10616         (dead_debug_insert_temp): Likewise.  Don't subreg when we're
10617         setting fewer regs than a multi-reg requires.
10618
10619 2012-06-27  Richard Henderson  <rth@redhat.com>
10620
10621         * config/alpha/alpha.c (alpha_dimode_u): New.
10622         (alpha_init_builtins): Initialize it, and use it.
10623         (alpha_fold_builtin_cmpbge): Use alpha_dimode_u.
10624         (alpha_fold_builtin_zapnot, alpha_fold_builtin_insxx): Likewise.
10625         (alpha_fold_vector_minmax, alpha_fold_builtin_perr): Likewise.
10626         (alpha_fold_builtin_pklb, alpha_fold_builtin_pkwb): Likewise.
10627         (alpha_fold_builtin_unpkbl, alpha_fold_builtin_unpkbw): Likewise.
10628         (alpha_fold_builtin_cttz, alpha_fold_builtin_ctlz): Likewise.
10629         (alpha_fold_builtin_ctpop): Likewise.
10630         (alpha_fold_builtin_umulh): Remove.
10631         (alpha_fold_builtin): Use MULT_HIGHPART_EXPR for UMULH; fix
10632         typo in MAX_ARGS check.
10633
10634 2012-06-27  Richard Henderson  <rth@redhat.com>
10635
10636         * tree.def (MULT_HIGHPART_EXPR): New.
10637         * cfgexpand.c (expand_debug_expr): Ignore it.
10638         * expr.c (expand_expr_real_2): Handle it.
10639         * fold-const.c (int_const_binop_1): Likewise.
10640         * optabs.c (optab_for_tree_code): Likewise.
10641         * tree-cfg.c (verify_gimple_assign_binary): Likewise.
10642         * tree-inline.c (estimate_operator_cost): Likewise.
10643         * tree-pretty-print.c (dump_generic_node): Likewise.
10644         (op_code_prio, op_symbol_code): Likewise.
10645         * tree.c (commutative_tree_code): Likewise.  Also handle
10646         WIDEN_MULT_EXPR, VEC_WIDEN_MULT_HI_EXPR, VEC_WIDEN_MULT_LO_EXPR.
10647
10648 2012-06-27  Richard Henderson  <rth@redhat.com>
10649
10650         PR target/53749
10651         * config/i386/i386.c (ix86_rtx_costs): Fix typo vs UNITS_PER_WORD
10652         in 2012-06-23 change.  Adjust two other DImode tests as well.
10653
10654 2012-06-27  Nick Clifton  <nickc@redhat.com>
10655
10656         * config/rx/rx.md (comparesi3_extend): Remove = modifier from
10657         input operand.
10658
10659 2012-06-27  Richard Guenther  <rguenther@suse.de>
10660
10661         PR middle-end/53676
10662         * tree-chrec.c (chrec_convert_1): Represent truncation to
10663         a type with undefined overflow as truncation to an unsigned
10664         type converted to the type with undefined overflow.
10665         * tree-scalar-evolution.c (interpret_rhs_expr): For computing
10666         the scalar evolution of a truncated widened operation avoid
10667         looking at the non-existing evolution of the widened operation
10668         result.
10669
10670 2012-06-27  Richard Guenther  <rguenther@suse.de>
10671
10672         PR tree-optimization/53774
10673         * tree-ssa-reassoc.c (get_rank): All default defs have
10674         precomputed rank.
10675         (init_reassoc): Precompute rank for all SSA default defs.
10676
10677 2012-06-27  Nick Clifton  <nickc@redhat.com>
10678
10679         * config/rx/rx.md (simple_return): Use the simple_return rtx.
10680
10681 2012-06-26  Richard Henderson  <rth@redhat.com>
10682
10683         * config/i386/i386.c (ix86_rtx_costs): Use standard_sse_constant_p
10684         and don't fall thru from standard_80387_constant_p to the memory
10685         fallback.
10686
10687 2012-06-26  Richard Henderson  <rth@redhat.com>
10688
10689         * config/i386/i386.c (bdesc_args): Update.  Change
10690         IX86_BUILTIN_VEC_WIDEN_SMUL_ODD_V4SI to OPTION_MASK_ISA_SSE2.
10691         (IX86_BUILTIN_VEC_WIDEN_SMUL_EVEN_V4SI): New.
10692         (ix86_builtin_mul_widen_even): Use it.
10693         (ix86_builtin_mul_widen_odd): Relax SMUL_ODD from sse4 to sse2.
10694         (ix86_expand_mul_widen_evenodd): Handle signed for sse2.
10695         * config/i386/sse.md (vec_widen_<s>mult_hi_<V124_AVX2>): Allow
10696         for all SSE2.
10697         (vec_widen_<s>mult_lo_<V124_AVX2>): Likewise.
10698         (vec_widen_<s>mult_odd_<VI4_AVX2>): Likewise.  Relax from V124_AVX2.
10699         (vec_widen_smult_even_v4si): New.
10700
10701 2012-06-26  Richard Henderson  <rth@redhat.com>
10702
10703         * config/i386/sse.md (mul<VI8_AVX2>3): Change from insn_and_split
10704         to expander; move guts to ...
10705         * config/i386/i386.c (ix86_expand_sse2_mulvxdi3): ... here.  Add
10706         highparts before shifting up.
10707         * config/i386/i386-protos.h: Update.
10708
10709 2012-06-26  Steven Bosscher  <steven@gcc.gnu.org>
10710
10711         * system.h (USE_COMMON_FOR_ONE_ONLY): Poison.
10712         * defaults.h (USE_COMMON_FOR_ONE_ONLY): Do not provide default.
10713         * config/darwin.h (USE_COMMON_FOR_ONE_ONLY): Do not define.
10714
10715 2012-06-26  Alexandre Oliva  <aoliva@redhat.com>
10716
10717         * var-tracking.c (vt_add_function_parameter): Use a preserved
10718         VALUE for the MEM address of an incoming parameter.
10719
10720 2012-06-26  Sterling Augustine <saugustine@google.com>
10721
10722         * dwarf2out.c (output_pubnames): Add check for DW_TAG_enumerator.
10723         (prune_unused_types): Likewise.
10724
10725 2012-06-26  Steven Bosscher  <steven@gcc.gnu.org>
10726
10727         * system.h (UNALIGNED_SHORT_ASM_OP, UNALIGNED_INT_ASM_OP,
10728         UNALIGNED_LONG_ASM_OP, UNALIGNED_DOUBLE_INT_ASM_OP): Poison.
10729         * vmsdbgout.c (UNALIGNED_SHORT_ASM_OP, UNALIGNED_INT_ASM_OP,
10730         UNALIGNED_LONG_ASM_OP, UNALIGNED_DOUBLE_INT_ASM_OP): Rename to
10731         VMS_UNALIGNED_SHORT_ASM_OP, VMS_UNALIGNED_INT_ASM_OP,
10732         VMS_UNALIGNED_LONG_ASM_OP, and VMS_UNALIGNED_DOUBLE_INT_ASM_OP.
10733         * config/microblaze/microblaze.h (UNALIGNED_SHORT_ASM_OP,
10734         UNALIGNED_INT_ASM_OP, UNALIGNED_DOUBLE_INT_ASM_OP): Do not define.
10735         * doc/tm.texi.in: Remove UNALIGNED_INT_ASM_OP reference from the
10736         documentation.
10737         * doc/tm.texi: Regenerate.
10738         * doc/cpp.texi: Make example for #error generic.
10739         * config/frv/frv.h: Fix example text to match tm.texi.
10740
10741 2012-06-26  Bill Schmidt  <wschmidt@linux.ibm.com>
10742
10743         * tree-pass.h (pass_strength_reduction): New decl.
10744         * tree-ssa-loop-ivopts.c (initialize_costs): Make non-static.
10745         (finalize_costs): Likewise.
10746         * timevar.def (TV_TREE_SLSR): New timevar.
10747         * gimple-ssa-strength-reduction.c: New.
10748         * tree-flow.h (initialize_costs): New decl.
10749         (finalize_costs): Likewise.
10750         * Makefile.in (tree-ssa-strength-reduction.o): New dependencies.
10751         * passes.c (init_optimization_passes): Add pass_strength_reduction.
10752
10753 2012-06-26  Matt Turner  <mattst88@gmail.com>
10754
10755         * doc/extend.texi (__builtin_arm_tinsrb): Add missing second parameter.
10756         (__builtin_arm_tinsrh): Likewise.
10757         (__builtin_arm_tinsrw): Likewise.
10758         (__builtin_arm_wsadb): Add missing v2si parameter.
10759         (__builtin_arm_wsadh): Likewise.
10760         (__builtin_arm_getwcx): Delete.
10761         (__builtin_arm_setwcx): Delete.
10762         (__builtin_arm_getwcgr0): Add.
10763         (__builtin_arm_getwcgr1): Add.
10764         (__builtin_arm_getwcgr2): Add.
10765         (__builtin_arm_getwcgr3): Add.
10766         (__builtin_arm_setwcgr0): Add.
10767         (__builtin_arm_setwcgr1): Add.
10768         (__builtin_arm_setwcgr2): Add.
10769         (__builtin_arm_setwcgr3): Add.
10770
10771 2012-06-26  Richard Guenther  <rguenther@suse.de>
10772
10773         Revert
10774         2012-06-21  Richard Guenther  <rguenther@suse.de>
10775
10776         * tree-inline.c (estimate_num_insns): Estimate call cost for
10777         tailcalls properly.
10778
10779 2012-06-26  Steven Bosscher  <steven@gcc.gnu.org>
10780
10781         PR other/33190
10782         * doc/tm.texi.in: Document LOGICAL_OP_NON_SHORT_CIRCUIT.
10783         * doc/tm.texi: Regenerate.
10784
10785 2012-06-26  Steven Bosscher  <steven@gcc.gnu.org>
10786
10787         PR other/33190
10788         * config/mips/mips.h: Do not define ALL_COP_ADDITIONAL_REGISTER_NAMES.
10789         * config/frv/frv.h: Do not define REVERSE_CONDEXEC_PREDICATES_P.
10790         * doc/tm.texi.in: Remove documentation for unused target macros
10791         ALL_COP_ADDITIONAL_REGISTER_NAMES, DBX_OUTPUT_LBRAC, DBX_OUTPUT_NFUN,
10792         DBX_OUTPUT_RBRAC, RANGE_TEST_NON_SHORT_CIRCUIT, REAL_VALUE_TRUNCATE,
10793         REVERSE_CONDEXEC_PREDICATES_P, TARGET_ALIGN_ANON_BITFIELDS, and
10794         TARGET_NARROW_VOLATILE_BITFIELDS.
10795         Document that MD_HANDLE_UNWABI is a macro in libgcc.
10796         * doc/tm.texi: Regenerate.
10797         * system.h: Poison target macros
10798         ALL_COP_ADDITIONAL_REGISTER_NAMES, DBX_OUTPUT_LBRAC, DBX_OUTPUT_NFUN,
10799         DBX_OUTPUT_RBRAC, RANGE_TEST_NON_SHORT_CIRCUIT, REAL_VALUE_TRUNCATE,
10800         REVERSE_CONDEXEC_PREDICATES_P, TARGET_ALIGN_ANON_BITFIELDS, and
10801         TARGET_NARROW_VOLATILE_BITFIELDS
10802
10803 2012-06-26  Jan Hubicka  <jh@suse.cz>
10804
10805         PR lto/53572
10806         * cgraph.h (varpool_can_remove_if_no_refs): Fix handling of
10807         used symbols.
10808
10809 2012-06-26  Dehao Chen  <dehao@google.com>
10810
10811         * tree-inline.c: (expand_call_inline): Ensure that lexical block's
10812         source location is consistant with the call stmt.
10813
10814 2012-06-26  Ulrich Weigand  <ulrich.weigand@linaro.org>
10815
10816         PR tree-optimization/53729
10817         PR tree-optimization/53636
10818         * tree-vect-slp.c (vect_slp_analyze_bb_1): Delay call to
10819         vect_verify_datarefs_alignment until after statements have
10820         been marked as relevant/irrelevant.
10821         * tree-vect-data-refs.c (vect_verify_datarefs_alignment):
10822         Skip irrelevant statements.
10823         (vect_enhance_data_refs_alignment): Use STMT_VINFO_RELEVANT_P
10824         instead of STMT_VINFO_RELEVANT.
10825         (vect_get_data_access_cost): Do not check for supportable
10826         alignment before calling vect_get_load_cost/vect_get_store_cost.
10827         * tree-vect-stmts.c (vect_get_store_cost): Do not abort when
10828         handling unsupported alignment.
10829         (vect_get_load_cost): Likewise.
10830
10831 2012-06-25  Steven Bosscher  <steven@gcc.gnu.org>
10832
10833         * config/rl78/rl78.h: Do not undefine DONT_USE_BUILTIN_SETJMP.
10834         Do not define JMP_BUF_SIZE.
10835
10836 2012-06-26  Jakub Jelinek  <jakub@redhat.com>
10837
10838         PR tree-optimization/53748
10839         * tree-ssa-phiopt.c (conditional_replacement): Only optimize
10840         if arg0/arg1 have integral or pointer types.
10841
10842 2012-06-25  Richard Henderson  <rth@redhat.com>
10843
10844         * config/i386/sse.md (sse2_sse4_1): Remove code attr.
10845         (<s>dot_prodv4si, <s>dot_prodv8si): Remove
10846         (sdot_prodv4si): New; handle only XOP.
10847
10848 2012-06-25  Richard Henderson  <rth@redhat.com>
10849
10850         * config/i386/i386-builtin-types.def (V4UDI, V8USI): New.
10851         (V2UDI_FUNC_V4USI_V4USI): New.
10852         (V4UDI_FUNC_V8USI_V8USI): New.
10853         * config/i386/i386.c (ix86_expand_args_builtin): Handle them.
10854         (IX86_BUILTIN_VEC_WIDEN_SMUL_ODD_V4SI): New.
10855         (IX86_BUILTIN_VEC_WIDEN_SMUL_ODD_V8SI): New.
10856         (IX86_BUILTIN_VEC_WIDEN_UMUL_ODD_V4SI): New.
10857         (IX86_BUILTIN_VEC_WIDEN_UMUL_ODD_V8SI): New.
10858         (IX86_BUILTIN_VEC_WIDEN_UMUL_EVEN_V4SI): New.
10859         (IX86_BUILTIN_VEC_WIDEN_UMUL_EVEN_V8SI): New.
10860         (bdesc_args): Add them.
10861         (ix86_builtin_mul_widen_even, ix86_builtin_mul_widen_odd): New.
10862         (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_EVEN): New.
10863         (TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_ODD): New.
10864         (ix86_expand_mul_widen_evenodd): Use xop_pmacsdqh.
10865         * config/i386/sse.md (vec_widen_<s>mult_odd_<V124_AVX2>): New.
10866
10867 2012-06-25  Richard Henderson  <rth@redhat.com>
10868
10869         * config/i386.sse.md (mul<VI4_AVX2>3): Use xop_pmacsdd.
10870
10871 2012-06-25  Richard Henderson  <rth@redhat.com>
10872
10873         * config/i386/i386.c (ix86_rtx_costs) [MULT]: Only apply XOP cost
10874         to V16QImode.
10875         (ix86_expand_vec_interleave): New.
10876         (ix86_expand_mul_widen_evenodd): New.
10877         (ix86_expand_mul_widen_hilo): New.
10878         (ix86_expand_sse2_mulv4si3): Use ix86_expand_mul_widen_evenodd.
10879         * config/i386/i386.md (u_bool) New code attr.
10880         * config/i386/predicates.md
10881         (nonimmediate_or_const_vector_operand): Remove.
10882         * config/i386/sse.md (mul<VI4_AVX2>3): Don't use it; don't test
10883         both AVX and SSE4_1.
10884         (vec_widen<s>mult_hi_<VI2_AVX2>): Remove.
10885         (vec_widen<s>mult_lo_<VI2_AVX2>): Remove.
10886         (vec_widen<s>mult_hi_v8si): Remove.
10887         (vec_widen<s>mult_lo_v8si): Remove.
10888         (vec_widen_smult_hi_v4si): Remove.
10889         (vec_widen_smult_lo_v4si): Remove.
10890         (vec_widen_umult_hi_v4si): Remove.
10891         (vec_widen_umult_lo_v4si): Remove.
10892         (vec_widen_<s>mult_hi_<VI124_AVX2>): New.
10893         (vec_widen_<s>mult_lo_<VI124_AVX2>): New.
10894         * config/i386/i386-protos.h: Update.
10895
10896 2012-06-25  Christophe Lyon  <christophe.lyon@st.com>
10897
10898         * config/arm/neon.md (UNSPEC_VLD1_DUP): Remove.
10899         (neon_vld1_dup): Restrict to VQ operands.
10900         (neon_vld1_dupv2di): New, fixes vld1q_dup_s64.
10901
10902 2012-06-25  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
10903             James Greenhalgh  <james.greenhalgh@arm.com>
10904
10905         * config/arm/arm.h (TARGET_CPU_CPP_BUILTINS): Add new built-ins.
10906         (TARGET_FMA): New macro.
10907         (TARGET_ARM_QBIT, TARGET_ARM_SAT): Likewise.
10908         (TARGET_ARM_ARCH): Likewise.
10909         (TARGET_ARM_ARCH_ISA_THUMB): Likewise.
10910         (TARGET_V6M, TARGET_V7M): Likewise.
10911         (TARGET_ARM_ARCH_PROFILE): Likewise.
10912         (TARGET_ARM_FEATURE_LDREX): Likewise.
10913         (TARGET_ARM_FP, TARGET_NEON_FP): Likewise.
10914         (ARM_MIN_ENUM_SIZE): Likewise.
10915         * config/arm/arm.c (arm_file_start): Refactor appropriately.
10916         (base_architecture): New enumeration.
10917         (arm_base_arch): New global variable.
10918         (processors): Add field base_arch.
10919         (ARM_ARCH, ARM_CORE): Adjust accordingly.
10920         (arm_option_override): Add initialization of arm_base_arch.
10921         * doc/cpp.texi (system-specific predefined macros.): Change.
10922
10923 2012-06-25  Jakub Jelinek  <jakub@redhat.com>
10924
10925         PR target/53759
10926         * config/i386/sse.md (sse_loadlps): Use x m x constraints instead
10927         of x x x in the vmovlps load alternative.
10928
10929 2012-06-25  Richard Sandiford  <rdsandiford@googlemail.com>
10930
10931         PR debug/53740
10932         * df.h (dead_debug_add): Remove third argument.
10933         * df-problems.c (dead_debug_add): Likewise.  Use the REGNO of the
10934         REG that we want to replace instead.
10935         (dead_debug_insert_temp): Use the REGNO of the reg that we want
10936         to replace instead of DF_REF_REGNO.  Require there to always be
10937         at least one such use.  Check for cases where the same location
10938         has more than df_ref associated with it.
10939         (df_note_bb_compute): Remove third dead_debug_add argument.
10940         * dce.c (word_dce_process_block): Likewise.
10941
10942 2012-06-25  Steven Bosscher  <steven@gcc.gnu.org>
10943
10944         * config/v850/v850.c: Remove redundant extern declarations for
10945         last_assemble_variable_decl and size_directive_output.
10946
10947         * doc/tm.texi.in: Document JMP_BUF_SIZE.
10948         * doc/tm.texi: Regenerate.
10949         * config/sparc/sparc.h (JMP_BUF_SIZE): Do not define.
10950         * config/pa/pa.h (JMP_BUF_SIZE): Likewise.
10951         * config/stormy16/stormy16.h: Likewise.
10952
10953         * config/picochip/picochip.c: Do not define DONT_USE_BUILTIN_SETJMP.
10954
10955         * doc/sourcebuild.texi: Add missing subdirectories.
10956
10957 2012-06-25  Tristan Gingold  <gingold@adacore.com>
10958
10959         * config/i386/i386.h: Fix typo.
10960
10961 2012-06-25  Tristan Gingold  <gingold@adacore.com>
10962
10963         * config/i386/winnt.c (i386_pe_seh_end_prologue): Move code to ...
10964         (seh_cfa_adjust_cfa): ... that function.
10965         (seh_emit_stackalloc): Do not emit out of range values.
10966         * config/i386/i386.md: Delete unused UNSPEC_REG_SAVE,
10967         UNSPEC_DEF_CFA constants.
10968         * config/i386/i386.h (SEH_MAX_FRAME_SIZE): Define.
10969         * config/i386/i386.c (ix86_frame_pointer_required): Required
10970         for very large frames on SEH target.
10971         (ix86_compute_frame_layout): Save area is before frame pointer
10972         on SEH target.  Handle very large frames.
10973         (ix86_expand_prologue): Likewise.
10974
10975 2012-06-24  Steven Bosscher  <steven@gcc.gnu.org>
10976
10977         * output.h: (current_function_is_leaf,
10978         current_function_sp_is_unchanging,
10979         current_function_uses_only_leaf_regs): Remove.
10980         * function.c (current_function_is_leaf,
10981         current_function_sp_is_unchanging,
10982         current_function_uses_only_leaf_regs): Remove.
10983         (rest_of_handle_check_leaf_regs): Set crtl->uses_only_leaf_regs
10984         instead of current_function_uses_only_leaf_regs.
10985         * function.h (struct rtl_data): New fields sp_is_unchanging,
10986         is_leaf, uses_only_leaf_regs.
10987         * resource.c (init_resource_info): Replace current_function_is_leaf,
10988         current_function_sp_is_unchanging, and
10989         current_function_uses_only_leaf_regs with new crtl fields.
10990         * sdbout.c (sdbout_symbol): Likewise.
10991         * df-core.c (rest_of_handle_df_initialize): Likewise.
10992         * ira.c (ira): Likewise.
10993         * final.c (final_start_function): Likewise.
10994         * reorg.c (fill_simple_delay_slots): Likewise.
10995         * regrename.c (check_new_reg_p): Likewise.
10996         * stack-ptr-mod.c (notice_stack_pointer_modification_1): Likewise.
10997         (notice_stack_pointer_modification): Likewise.
10998         * dbxout.c (dbxout_symbol): Likewise.
10999         (dbxout_parms): Likewise.
11000         * sel-sched.c (init_regs_for_mode): Likewise.
11001         * dwarf2out.c (dbx_reg_number): Likewise.
11002         (multiple_reg_loc_descriptor): Likewise.
11003         * config/i386/i386.c (ix86_frame_pointer_required): Likewise.
11004         (gen_pop): Likewise.
11005         (ix86_select_alt_pic_regnum): Likewise.
11006         (ix86_compute_frame_layout): Likewise.
11007         (ix86_finalize_stack_realign_flags): Likewise.
11008         (ix86_expand_epilogue): Likewise.
11009         * config/rs6000/rs6000.c (rs6000_stack_info): Likewise.
11010         * config/h8300/h8300.c (byte_reg): Likewise.
11011         * config/c6x/c6x.c (must_reload_pic_reg_p): Likewise.
11012         (c6x_save_reg): Likewise.
11013         (c6x_compute_frame_layout): Likewise.
11014         * config/pa/pa.c (pa_compute_frame_size): Likewise.
11015         (pa_output_function_prologue): Likewise.
11016         * config/stormy16/stormy16.c (struct xstormy16_stack_layout): Likewise.
11017         * config/sparc/sparc.md (attr "leaf_function"): Likewise.
11018         * config/sparc/sparc.c (sparc_initial_elimination_offset): Likewise.
11019         (sparc_expand_prologue): Likewise.
11020         (sparc_flat_expand_prologue): Likewise.
11021         (sparc_asm_function_prologue): Likewise.
11022         (sparc_output_mi_thunk): Likewise.
11023         (sparc_frame_pointer_required): Likewise.
11024         * config/epiphany/epiphany.c (epiphany_compute_function_type):
11025         Likewise.
11026         (epiphany_compute_frame_size): Likewise.
11027         * config/lm32/lm32.c (lm32_compute_frame_size): Likewise.
11028         * config/cris/cris.c (cris_md_asm_clobbers): Likewise.
11029         (cris_frame_pointer_required): Likewise.
11030         * config/tilepro/tilepro.c (emit_sp_adjust): Likewise.
11031         (tilepro_current_function_is_leaf): Likewise.
11032         * config/arm/arm.c (arm_compute_save_reg0_reg12_mask): Likewise.
11033         * config/pdp11/pdp11.c (pdp11_expand_epilogue): Likewise.
11034         * config/ia64/ia64.c (find_gr_spill): Likewise.
11035         (ia64_compute_frame_size): Likewise.
11036         (ia64_can_eliminate): Likewise.
11037         (ia64_initial_elimination_offset): Likewise.
11038         * config/m68k/m68k.c (m68k_save_reg): Likewise.
11039         (m68k_expand_epilogue): Likewise.
11040         * config/rx/rx.c (rx_get_stack_layout): Likewise.
11041         * config/tilegx/tilegx.c (tilegx_current_function_is_leaf): Likewise.
11042         * config/picochip/picochip.c (picochip_can_eliminate_link_sp_save):
11043         Likewise.
11044         (picochip_output_frame_debug): Likewise.
11045         * config/sh/sh.c (sh_media_register_for_return): Likewise.
11046         (sh_allocate_initial_value): Likewise.
11047         (sh_output_mi_thunk): Likewise.
11048         * config/microblaze/microblaze.c (microblaze_must_save_register):
11049         Likewise.
11050         (compute_frame_size): Likewise.
11051         (microblaze_initial_elimination_offset): Likewise.
11052         (microblaze_expand_prologue): Likewise.
11053         (microblaze_expand_epilogue): Likewise.
11054         * config/frv/frv.c (frv_expand_epilogue): Likewise.
11055         (frv_frame_pointer_required): Likewise.
11056         * config/spu/spu.c (get_pic_reg): Likewise.
11057         (direct_return): Likewise.
11058         (spu_expand_prologue): Likewise.
11059         (spu_expand_epilogue): Likewise.
11060         (spu_initial_elimination_offset): Likewise.
11061         * config/mips/mips.c (mips_global_pointer): Likewise.
11062         (mips_cfun_might_clobber_call_saved_reg_p): Likewise.
11063         (mips_compute_frame_info): Likewise.
11064         * config/mep/mep.c (mep_interrupt_saved_reg): Likewise.
11065         (mep_reload_pointer): Likewise.
11066         * config/rl78/rl78.c (need_to_save): Likewise.
11067         * config/cr16/cr16.c (cr16_compute_save_regs): Likewise.
11068         * config/score/score.c (score_compute_frame_size): Likewise.
11069         (score_function_prologue): Likewise.
11070         * config/bfin/bfin.c (must_save_p): Likewise.
11071         (expand_prologue_reg_save): Likewise.
11072         (expand_epilogue_reg_restore): Likewise.
11073         (bfin_frame_pointer_required): Likewise.
11074         (n_regs_saved_by_prologue): Likewise.
11075         (add_to_reg): Likewise.
11076         (expand_interrupt_handler_prologue): Likewise.
11077         (expand_interrupt_handler_epilogue): Likewise.
11078         (bfin_expand_prologue): Likewise.
11079         * config/avr/avr.c (avr_regs_to_save): Likewise.
11080         (avr_prologue_setup_frame): Likewise.
11081         (expand_epilogue): Likewise.
11082         * config/s390/s390.c (s390_regs_ever_clobbered): Likewise.
11083         (s390_register_info): Likewise.
11084         (s390_frame_info): Likewise.
11085         (s390_init_frame_layout): Likewise.
11086         (s390_emit_prologue): Likewise.
11087
11088
11089 2012-06-24  Steven Bosscher  <steven@gcc.gnu.org>
11090
11091         * system.h: Poison ASM_BYTE_OP and ASM_OUTPUT_BYTE.
11092         * vmsdbgout: Do not undefine it if defined.
11093         Rename local ASM_BYTE_OP definition to VMS_ASM_BYTE_OP.
11094         * config/microblaze/microblaze/h: Do no define ASM_BYTE_OP.
11095         * config/mep/mep.h: Do not define ASM_OUTPUT_BYTE.
11096
11097 2012-06-24  Richard Sandiford  <rdsandiford@googlemail.com>
11098
11099         * config/mips/mips.c (mips_process_sync_loop): Add missing enum cast.
11100
11101 2012-06-23  Richard Henderson  <rth@redhat.com>
11102
11103         PR target/53749
11104         * config/i386/i386.c (ix86_rtx_costs): Add reasonable costs for
11105         V*QImode shifts and multiply.
11106         (ix86_expand_vecop_qihi): Support shifts.
11107         * config/i386/i386.md (any_shift): New code iterator.
11108         * config/i386/sse.md (ashlv16qi3): Merge ...
11109         (<any_shiftrt>v16qi3): ... into ...
11110         (<any_shift><VI1_AVX2>3): ... here.  Use ix86_expand_vecop_qihi
11111         to support SSE and AVX.
11112
11113         * config/i386/i386.c (ix86_expand_sse_unpack): Split operands[]
11114         parameter into src and dest.
11115         * config/i386/sse.md (vec_unpacku_hi_<V124_AVX2>): Update call.
11116         (vec_unpacks_hi_<V124_AVX2>): Likewise.
11117         (vec_unpacku_lo_<V124_AVX2>): Likewise.
11118         (vec_unpacks_lo_<V124_AVX2>): Likewise.
11119         * config/i386/i386-protos.h: Update.
11120
11121         * config/i386/sse.md (mul<VI1_AVX2>3): Change from insn_and_split to
11122         pure expander; move expansion code ...
11123         * config/i386/i386.c (ix86_expand_vecop_qihi): ... here.  New function.
11124         * config/i386/i386-protos.h: Update.
11125
11126 2012-06-22  Edmar Wienskoski  <edmar@freescale.com>
11127
11128         * config/rs6000/rs6000.md (define_attr "type"): New type popcnt.
11129         (popcntb<mode>2): Add attribute type popcnt.
11130         (popcntd<mode>2): Ditto.
11131         * config/rs6000/power4.md (define_insn_reservation): Add type popcnt.
11132         * config/rs6000/power5.md (define_insn_reservation): Ditto.
11133         * config/rs6000/power7.md (define_insn_reservation): Ditto.
11134         * config/rs6000/476.md (define_insn_reservation): Ditto.
11135         * config/rs6000/power6.md (define_insn_reservation): New
11136         reservation for popcnt instructions.
11137
11138 2012-06-22  H.J. Lu  <hongjiu.lu@intel.com>
11139
11140         * doc/invoke.texi: Update -mpreferred-stack-boundary=3 warning.
11141
11142 2012-06-22  H.J. Lu  <hongjiu.lu@intel.com>
11143
11144         PR target/53383
11145         * doc/invoke.texi: Add a warning for -mpreferred-stack-boundary=3.
11146
11147         * config/i386/i386.c (ix86_option_override_internal): Allow
11148         -mpreferred-stack-boundary=3 for 64-bit if SSE is disabled.
11149
11150         * config/i386/i386.h (MIN_STACK_BOUNDARY): Set to 64 for 64-bit
11151         if SSE is disabled.
11152
11153 2012-06-22  Bill Schmidt  <wschmidt@linux.ibm.com>
11154
11155         * double-int.c (double_int_multiple_of): New function.
11156         * double-int.h (double_int_multiple_of): New decl.
11157         * tree-ssa-loop-ivopts.c (add_cost, zero_cost): Remove undefs.
11158         (mbc_entry_hash): New forward decl.
11159         (mbc_entry_eq): Likewise.
11160         (zero_cost): Change to no_cost.
11161         (mult_costs): New static var.
11162         (cost_tables_exist): Likewise.
11163         (initialize_costs): New function.
11164         (finalize_costs): Likewise.
11165         (tree_ssa_iv_optimize_init): Call initialize_costs.
11166         (add_cost): Change to add_regs_cost; distinguish costs by speed.
11167         (multiply_regs_cost): New function.
11168         (add_const_cost): Likewise.
11169         (extend_or_trunc_reg_cost): Likewise.
11170         (negate_reg_cost): Likewise.
11171         (multiply_by_cost): Change to multiply_by_const_cost; distinguish
11172         costs by speed.
11173         (get_address_cost): Change add_cost to add_regs_cost; change
11174         multiply_by_cost to multiply_by_const_cost.
11175         (force_expr_to_var_cost): Change zero_cost to no_cost; change
11176         add_cost to add_regs_cost; change multiply_by_cost to
11177         multiply_by_const_cost.
11178         (split_cost): Change zero_cost to no_cost.
11179         (ptr_difference_cost): Likewise.
11180         (difference_cost): Change zero_cost to no_cost; change multiply_by_cost
11181         to multiply_by_const_cost.
11182         (get_computation_cost_at): Change add_cost to add_regs_cost; change
11183         multiply_by_cost to multiply_by_const_cost.
11184         (determine_use_iv_cost_generic): Change zero_cost to no_cost.
11185         (determine_iv_cost): Change add_cost to add_regs_cost.
11186         (iv_ca_new): Change zero_cost to no_cost.
11187         (tree_ssa_iv_optimize_finalize): Call finalize_costs.
11188         * tree-ssa-address.c (most_expensive_mult_to_index): Change
11189         multiply_by_cost to multiply_by_const_cost.
11190         * tree-flow.h (multiply_by_cost): Change to multiply_by_const_cost.
11191         (add_regs_cost): New decl.
11192         (multiply_regs_cost): Likewise.
11193         (add_const_cost): Likewise.
11194         (extend_or_trunc_reg_cost): Likewise.
11195         (negate_reg_cost): Likewise.
11196
11197 2012-06-22  Richard Guenther  <rguenther@suse.de>
11198
11199         Merge from graphite branch
11200         2011-08-10  Sebastian Pop <sebpop@gmail.com>
11201
11202         * graphite-sese-to-poly.c (build_scop_drs): Fix memory leak.
11203
11204         2012-01-13  Tobias Grosser  <tobias@grosser.es>
11205
11206         * tree-flow.h (parallelized_function_p): Declare.
11207         * tree-parloops.c (parallelized_function_p): Export.
11208         * graphite.c (graphite_transform_loops): Do not run graphite on
11209         already parallel functions.
11210
11211 2012-06-22  Alan Modra  <amodra@gmail.com>
11212
11213         * config/rs6000/rs6000.c (rs6000_pre_atomic_barrier): Pass in and
11214         return mem.  Convert to indirect addressing if not indirect or
11215         indexed.  Adjust all callers.
11216
11217 2012-06-22  Richard Guenther  <rguenther@suse.de>
11218
11219         * gcov-iov.c: Include bconfig.h and system.h.
11220
11221 2012-06-22  Andreas Schwab  <schwab@linux-m68k.org>
11222
11223         * doc/include/texinfo.tex: Update to version 2012-06-05.14.
11224
11225 2012-06-22  Richard Guenther  <rguenther@suse.de>
11226
11227         PR gcov-profile/53744
11228         * gcov-iov.c (main): Treat "" and "prerelease" the same.
11229
11230 2012-06-22  Eric Botcazou  <ebotcazou@adacore.com>
11231
11232         PR debug/53704
11233         * dwarf2out.c (gen_compile_unit_die): Use DW_LANG_Fortran90 as language
11234         for GNU Fortran if in strict DWARF2 mode.
11235
11236 2012-06-22  Eric Botcazou  <ebotcazou@adacore.com>
11237
11238         * tree-ssa-live.c (remove_unused_scope_block_p): Remove again
11239         DECL_IGNORED_P non-reg vars even if they are used.
11240
11241 2012-06-21  Alexandre Oliva  <aoliva@redhat.com>
11242
11243         PR debug/53671
11244         PR debug/49888
11245         * var-tracking.c (vt_get_canonicalize_base): New.
11246         (vt_canonicalize_addr, vt_stack_offset_p): New.
11247         (vt_canon_true_dep): New.
11248         (drop_overlapping_mem_locs): Use vt_canon_true_dep.
11249         (clobber_overlaping_mems): Use vt_canonicalize_addr.
11250
11251 2012-06-21  Alexandre Oliva  <aoliva@redhat.com>
11252
11253         PR debug/53671
11254         PR debug/49888
11255         * var-tracking.c (vt_initialize): Record initial offset between
11256         arg pointer and stack pointer.
11257
11258 2012-06-21  Alexandre Oliva  <aoliva@redhat.com>
11259
11260         PR debug/53671
11261         PR debug/49888
11262         * var-tracking.c (vt_init_cfa_base): Drop redundant recording of
11263         CFA base.
11264
11265 2012-06-21  Alexandre Oliva  <aoliva@redhat.com>
11266
11267         PR debug/53671
11268         PR debug/49888
11269         * alias.c (memrefs_conflict_p): Improve handling of AND for alignment.
11270
11271 2012-06-21  Alexandre Oliva  <aoliva@redhat.com>
11272
11273         * ddg.c (build_intra_loop_deps): Discard deps of nondebug on debug.
11274
11275 2012-06-21  Alexandre Oliva  <aoliva@redhat.com>
11276
11277         PR debug/53682
11278         * cselib.c (promote_debug_loc): Don't crash on NULL argument.
11279
11280 2012-06-21  Meador Inge  <meadori@codesourcery.com>
11281
11282         PR c/53702
11283         * c-decl.c (c_push_function_context): Restore the behavior to reuse
11284         the language function allocated for -Wunused-local-typedefs.
11285         (c_pop_function_context): If necessary, clear the language function
11286         created in c_push_function_context.  Always clear out the
11287         x_cur_stmt_list field of the restored language function.
11288
11289 2012-06-21  Sterling Augustine  <saugustine@google.com>
11290             Cary Coutant  <ccoutant@google.com>
11291
11292         * dwarf2out.c (is_cu_die, is_namespace_die, is_class_die,
11293         add_AT_pubnames, add_enumerator_pubname, want_pubnames): New functions.
11294         (comdat_type_struct): New field 'skeleton_die'.
11295         (breakout_comdat_types): Update it.
11296         (add_pubname): Rework logic.  Call is_class_die, is_cu_die and
11297         is_namespace_die.  Fix minor style violation.  Call want_pubnames.
11298         (add_pubname_string): Call want_pubnames.
11299         (add_pubtype): Rework logic for calculating type name.  Call
11300         is_namespace_die.  Call want_pubnames.
11301         (output_pubnames): Move conditional logic deciding when to produce the
11302         section from dwarf2out_finish.  Use new skeleton_die field.
11303         (base_type_die): Call add_pubtype.
11304         (gen_enumeration_type_die): Unconditionally call add_pubtype.
11305         (gen_subprogram_die): Adjust calls to add_pubname.
11306         (gen_namespace_die): Call add_pubname_string.
11307         (dwarf2out_finish): Call add_AT_pubnames; Move logic on when to
11308         produce pubnames and pubtypes sections to output_pubnames.
11309         * common.opt (-gpubnames): New option.
11310         * doc/invoke.texi: Document it.
11311
11312 2012-06-21  Steven Bosscher  <steven@gcc.gnu.org>
11313
11314         * config/m32c/m32c-pragma.c: Remove unnecessary includes.
11315
11316 2012-06-21  Michael Matz  <matz@suse.de>
11317
11318         PR middle-end/53688
11319         * builtins.c (get_memory_rtx): Always build an all-aliasing MEM_REF
11320         with correct size.
11321
11322 2012-06-21  Richard Guenther  <rguenther@suse.de>
11323
11324         * tree-inline.c (estimate_num_insns): Estimate call cost for
11325         tailcalls properly.
11326
11327 2012-06-20  Rüdiger Sonderfeld  <ruediger@c-plusplus.de>
11328
11329         * tree.h (DECL_SOURCE_COLUMN): New accessor.
11330
11331 2012-06-20  Uros Bizjak  <ubizjak@gmail.com>
11332
11333         * config/i386/i386.md (SINCOS): New int iterator.
11334         (sincos): New int attribute.
11335         (*<sincos>xf2_i387): Macroize insn from *{sin,cos}xf2_i387 using
11336         SINCOS int iterator.
11337         (*<sincos>_extend<mode>xf2_i387): Macroize insn from
11338         *{sin,cos}_extend<mode>xf2_i387 using SINCOS int iterator.
11339
11340 2012-06-20  Uros Bizjak  <ubizjak@gmail.com>
11341
11342         * config/i386/i386.md (RDFSGSBASE): New int iterator.
11343         (WRFSGSBASE): Ditto.
11344         (fsgs): New int attribute.
11345         (rd<fsgs>base<mode>): Macroize insn from rd<fsgs>base<mode> using
11346         RDFSGSBASE int iterator.
11347         (wr<fsgs>base<mode>): Macroize insn from wr<fsgs>base<mode> using
11348         WRFSGSBASE int iterator.
11349
11350 2012-06-20  Uros Bizjak  <ubizjak@gmail.com>
11351
11352         * config/i386/i386.md (<rounding_insn><mode>2): Macroize expander
11353         from {floor,ceil,btrunc}<mode>2 using FIST_ROUNDING int iterator.
11354         (l<rounding_insn><MODEF:mode><SWI48:mode>2): Macroize expander
11355         from l{floor,ceil}<MODEF:mode><SWI48:mode>2 using FIST_ROUNDING
11356         int iterator.
11357
11358 2012-06-20  Steven Bosscher  <steven@gcc.gnu.org>
11359
11360         * system.h: Poison ASM_OUTPUT_IDENT and IDENT_ASM_OP.
11361
11362 2012-06-20  Richard Guenther  <rguenther@suse.de>
11363
11364         PR tree-optimization/30318
11365         * tree-vrp.c (range_int_cst_p): Do not reject overflowed
11366         constants here.
11367         (range_int_cst_singleton_p): But explicitely here.
11368         (zero_nonzero_bits_from_vr): And here.
11369         (extract_range_from_binary_expr_1): Re-implement PLUS_EXPR
11370         to cover all cases we can perform arbitrary precision
11371         arithmetic with double-ints.
11372         (intersect_ranges): Handle adjacent anti-ranges.
11373
11374 2012-06-20  Uros Bizjak  <ubizjak@gmail.com>
11375
11376         * config/i386/i386.md (rounding_insn): New int attribute.
11377         (<rounding_insn>xf2): Macroize insn from
11378         {floor,ceil,btrunc}xf2 using FRNDINT_ROUNDING int iterator.
11379         (l<rounding_insn>xf<mode>2): Rename from l<rounding>xf<mode>2.
11380
11381 2012-06-20  Uros Bizjak  <ubizjak@gmail.com>
11382
11383         * config/i386/i386.md (IEEE_MAXMIN): New int iterator.
11384         (ieee_maxmin): New int attribute.
11385         (*ieee_s<ieee_maxmin><mode>3): Macroize insn from
11386         *ieee_s{max,min}<mode>3 using IEEE_MAXMIN int iterator.
11387
11388 2012-06-20  Steven Bosscher  <steven@gcc.gnu.org>
11389
11390         * config/arm/arm.h (EMIT_EABI_ATTRIBUTE): Remove.
11391         * config/arm/arm.c: Do not include c-pragma.h.
11392         (arm_emit_eabi_attribute): New function based on EMIT_EABI_ATTRIBUTE.
11393         (arm_file_start): Replace uses of EMIT_EABI_ATTRIBUTE with calls
11394         to arm_emit_eabi_attribute.
11395         * arm-c.c: Do not include output.h.
11396         (arm_output_c_attributes): Replace use of EMIT_EABI_ATTRIBUTE with a
11397         call to arm_emit_eabi_attribute.
11398         * config/arm/arm-protos.h (arm_emit_eabi_attribute): Prototype it.
11399
11400 2012-06-20  Richard Guenther  <rguenther@suse.de>
11401
11402         * tree-vect-data-refs.c (vect_can_force_dr_alignment_p):
11403         Allow adjusting alignment of user-aligned decls again.
11404
11405 2012-06-20  Steven Bosscher  <steven@gcc.gnu.org>
11406
11407         * config/rl78/rl78-c.c: Remove unnecessary includes.
11408
11409 2012-06-20  Steven Bosscher  <steven@gcc.gnu.org>
11410
11411         * config/cris/cris.c: Include cgraph.h.
11412         (cris_option_override): Do not set non-existing flag_no_gcc_ident.
11413
11414 2012-06-19  Maxim Kuvyrkov  <maxim@codesourcery.com>
11415
11416         * emit-rtl.c (need_atomic_barrier_p): New function.
11417         * emit-rtl.h (need_atomic_barrier_p): Declare it.
11418         * config/alpha/alpha.c (alpha_{pre,post}_atomic_barrier): Use it.
11419         * config/arm/arm.c (arm_{pre,post}_atomic_barrier): Use it.
11420         * config/tilegx/tilegx.c (tile_{pre,post}_atomic_barrier): Use it.
11421         * config/mips/mips.c (mips_{pre,post}_atomic_barrier_p): Remove.
11422         (mips_process_sync_loop): Use generic version instead.
11423
11424 2012-06-19  Maxim Kuvyrkov  <maxim@codesourcery.com>
11425
11426         * config/mips/mips.c (mips_process_sync_loop): Emit cmp result only if
11427         it is used.
11428
11429 2012-06-19  Tom de Vries  <vries@codesourcery.com>
11430             Maxim Kuvyrkov  <maxim@codesourcery.com>
11431
11432         * config/mips/constraints.md (ZR): New constraint.
11433         * config/mips/predicates.md (mem_noofs_operand): New predicate.
11434         * config/mips/mips.c (mips_print_operand): Handle new print modifier.
11435         * config/mips/mips.h (TARGET_XLP): Define.
11436         (TARGET_SYNC_AFTER_SC): Update.
11437         (ISA_HAS_SWAP, ISA_HAS_LDADD): Define.
11438         * config/mips/sync.md (atomic_exchange, atomic_fetch_add): Use
11439         XLP-specific swap and ldadd patterns.
11440         (atomic_exchange_swap, atomic_fetch_add_ldadd): New patterns.
11441
11442 2012-06-19  Tom de Vries  <vries@codesourcery.com>
11443             Maxim Kuvyrkov  <maxim@codesourcery.com>
11444
11445         * config/mips/mips.c (mips_emit_pre_atomic_barrier_p,)
11446         (mips_emit_post_atomic_barrier_p): New static functions.
11447         (mips_process_sync_loop): Use them.  Emit sync memory barriers in
11448         accordance with memory model semantics.  Add return of CMP result for
11449         compare_and_swap.
11450         * config/mips/mips.md: Update comment.
11451         (sync_cmp): New attribute.
11452         (sync_memmodel): New attribute replacing sync_release_barrier.
11453         * config/mips/sync.md (UNSPEC_ATOMIC_COMPARE_AND_SWAP,)
11454         (UNSPEC_ATOMIC_EXCHANGE, UNSPEC_ATOMIC_FETCH_OP): New constants.
11455         (sync_lock_test_and_set, test_and_set_12): Update.
11456         (atomic_compare_and_swap, atomic_exchange, atomic_exchange_llsc,)
11457         (atomic_fetch_add, atomic_fetch_add_llsc): New patterns.
11458
11459 2012-06-19  Joseph Myers  <joseph@codesourcery.com>
11460
11461         * config/rs6000/spe.md (*mov_si<mode>_e500_subreg0): Rename to
11462         mov_si<mode>_e500_subreg0.
11463         (*mov_si<mode>_e500_subreg0_elf_low)
11464         (*mov_si<mode>_e500_subreg4_elf_low): New patterns.
11465
11466 2012-06-19  Richard Henderson  <rth@redhat.com>
11467
11468         * config/alpha/alpha.c: Include params.h.
11469         (alpha_option_override): Initialize PARAM_L1_CACHE_LINE_SIZE,
11470         PARAM_L1_CACHE_SIZE, PARAM_L2_CACHE_SIZE for the cpu tuning.
11471
11472 2012-06-19  Steven Bosscher  <steven@gcc.gnu.org>
11473
11474         * doc/tm.texi.in (TARGET_OBJC_DECLARE_UNRESOLVED_CLASS_REFERENCE,
11475         TARGET_OBJC_DECLARE_CLASS_DEFINITION): Add @hooks.
11476         (ASM_DECLARE_CLASS_REFERENCE, ASM_DECLARE_UNRESOLVED_REFERENCE):
11477         Remove.
11478         * doc/tm.texi: Regenerate.
11479         * config/darwin.h (ASM_OUTPUT_LABELREF): Remove special case for
11480         .objc_class_name_*.
11481         * config/darwin-c.c: Include target.h.
11482         (darwin_objc_declare_unresolved_class_reference): New function.
11483         (darwin_objc_declare_class_definition): New function.
11484         (TARGET_OBJC_DECLARE_UNRESOLVED_CLASS_REFERENCE): Define.
11485         (TARGET_OBJC_DECLARE_CLASS_DEFINITION): Define.
11486
11487 2012-06-19  Steven Bosscher  <steven@gcc.gnu.org>
11488
11489         * target.def (output_ident): New hook.
11490         * targhooks.h (default_asm_output_ident_directive): Add prototype.
11491         * varasm.c (assemble_asm): Only prefix a tab if the string does not
11492         already start with one.
11493         (default_asm_output_ident_directive): New function to emit
11494         .ident as a top-level asm node while parsing, or directly to
11495         asm_out_file after parsing.
11496         * toplev.c (compile_file): Print a GCC .ident with
11497         targetm.asm_out.output_ident.
11498         * doc/tm.texi.in (ASM_OUTPUT_IDENT): Remove documentation for macro.
11499         (TARGET_ASM_OUTPUT_IDENT): Add @hook for this.
11500         * doc/tm.texi: Update.
11501
11502         * config/elfos.h (ASM_OUTPUT_IDENT, IDENT_ASM_OP): Remove.
11503         (TARGET_ASM_OUTPUT_IDENT): Define.
11504         * config/i386/djgpp.h (IDENT_ASM_OP): Remove.
11505         * config/i386/gas.h (ASM_OUTPUT_IDENT): Remove.
11506         * config/arm/aout.h (ASM_OUTPUT_IDENT): Remove.
11507         * config/sparc/sparc.h (IDENT_ASM_OP): Remove.
11508         (TARGET_ASM_OUTPUT_IDENT): Define.
11509         * config/picochip/picochip.h (IDENT_ASM_OP): Remove.
11510         (TARGET_ASM_OUTPUT_IDENT): Define.
11511
11512         * config/cris/cris-protos.h (cris_asm_output_ident): Add prototype.
11513         * config/cris/cris.c (cris_asm_output_ident): New function.
11514         * config/cris/cris.h (ASM_OUTPUT_IDENT, IDENT_ASM_OP): Remove.
11515
11516         * config/microblaze/microblaze-protos.h (microblaze_asm_output_ident):
11517         Add prototype.
11518         * config/microblaze/microblaze.c: Include cgraph.h for add_asm_node.
11519         (microblaze_asm_output_ident): Rewrite to work similar to
11520         default_asm_output_ident_directive for front-end .idents.
11521         * config/microblaze/microblaze.h (ASM_OUTPUT_IDENT): Remove.
11522         (TARGET_ASM_OUTPUT_IDENT): Define.
11523
11524         * config/mips/mips.h (ASM_OUTPUT_IDENT): Remove.
11525         * config/mips/sde.h (IDENT_ASM_OP, ASM_OUTPUT_IDENT): Remove.
11526
11527         * config/rx/rx.c: Include cgraph.h for add_asm_node.
11528         (rx_asm_output_ident): New function, similar to
11529         default_asm_output_ident_directive, but handle AS100 syntax also, so
11530         that #ident also works for rx in AS100 syntax.
11531         (TARGET_ASM_OUTPUT_IDENT): Define.
11532         * config/rx/rx.h (IDENT_ASM_OP): Remove.
11533
11534         * Makefile.in: Fix dependencies for c-family/c-lex.o.
11535
11536 2012-06-19  Uros Bizjak  <ubizjak@gmail.com>
11537
11538         * config/i386/i386.md (FIST_ROUNDING): New int iterator.
11539         (rounding): Handle UNSPEC_FIST_{FLOOR,CEIL}.
11540         (ROUNDING): Ditto.
11541         (*fist<mode>2_<rounding>_1): Macroize insn from
11542         *fist<mode>2_{floor,ceil}_1 using FIST_ROUNDING int iterator.
11543         (fistdi2_<rounding>): Macroize insn from
11544         fistdi2_{floor,ceil} using FIST_ROUNDING int iterator.
11545         (fistdi2_<rounding>_with_temp and splitters): Macroize insn and
11546         corresponding splitters from fistdi2_{floor,ceil} and corresponding
11547         splitters using FIST_ROUNDING int iterator.
11548         (fist<mode>2_<rounding>): Macroize insn from
11549         fist<mode>2_{floor,ceil} using FIST_ROUNDING int iterator.
11550         (fist<mode>2_<rounding>_with_temp and splitters): Macroize insn and
11551         corresponding splitters from fist<mode>2_{floor,ceil} and corresponding
11552         splitters using FIST_ROUNDING int iterator.
11553         (l<rounding>xf<mode>2): Macroize expander from l{floor,ceil}xf<mode>2
11554         using FIST_ROUNDING int iterator.
11555
11556 2012-06-19  Richard Henderson  <rth@redhat.com>
11557
11558         * config/i386/i386-protos.h (ix86_expand_sse2_mulv4si3): Declare.
11559         * config/i386/i386.c (ix86_expand_sse2_mulv4si3): New.
11560         * config/i386/predicates.md (nonimmediate_or_const_vector_operand): New.
11561         * config/i386/sse.md (sse2_mulv4si3): Delete.
11562         (mul<VI4_AVX2>3): Use ix86_expand_sse2_mulv4si3 and
11563         nonimmediate_or_const_vector_operand.
11564
11565 2012-06-19  Richard Henderson  <rth@redhat.com>
11566
11567         * expmed.c (struct init_expmed_rtl): Split ...
11568         (init_expmed_one_mode): ... out of ...
11569         (init_expmed): ... here.  Initialize integer vector modes also.
11570         (synth_mult): Handle integer vector modes.
11571         (choose_mult_variant): Likewise.
11572         (expand_mult_const): Likewise.
11573         (expand_mult): Likewise.
11574         * machmode.h (GET_MODE_UNIT_BITSIZE): New.
11575
11576 2012-06-19  Richard Henderson  <rth@redhat.com>
11577
11578         * config/i386/i386.c (ix86_rtx_costs): Handle CONST_VECTOR, and
11579         integral vector modes.
11580
11581 2012-06-19  Uros Bizjak  <ubizjak@gmail.com>
11582
11583         * config/i386/i386.md (FRNDINT_ROUNDING): New int iterator.
11584         (rounding): New int attribute.
11585         (ROUNDING): Ditto.
11586         (frndintxf2_<rounding>): Macroize insn from
11587         frndintxf2_{floor,ceil,trunc} using FRNDINT_ROUNDING int iterator.
11588         (frndintxf2_<rounding>_i387): Macroize insn from
11589         frndintxf2_{floor,ceil,trunc}_i387 using FRNDINT_ROUNDING int iterator.
11590
11591 2012-06-19  Richard Guenther  <rguenther@suse.de>
11592
11593         * tree-vrp.c (union_ranges): New function.
11594         (vrp_meet_1): Use union_ranges.
11595         (vrp_meet): Dump what we union and call vrp_meet_1.
11596
11597 2012-06-19  Richard Earnshaw  <rearnsha@arm.com>
11598
11599         * arm.md (enum unspec): Delete UNSPEC_SIN and UNSPEC_COS.
11600         (attr type): Remove fmul, ffmul, farith, ffarith, float_em
11601         f_fpa_load, f_fpa_store, f_mem_r, r_mem_f.
11602         (attr write_conflict, attr core_cycles): Update.
11603         * arm-generic.md (r_mem_f_wbuf): Delete reservation.
11604
11605 2012-06-19  Richard Guenther  <rguenther@suse.de>
11606
11607         * tree-vrp.c (intersect_ranges): Handle more cases.
11608         (vrp_intersect_ranges): Dump what we intersect and call ...
11609         (vrp_intersect_ranges_1): ... this.
11610
11611 2012-06-19  Richard Guenther  <rguenther@suse.de>
11612
11613         PR tree-optimization/53708
11614         * tree-vect-data-refs.c (vect_can_force_dr_alignment_p): Preserve
11615         user-supplied alignment and alignment of decls with the used
11616         attribute.
11617
11618 2012-06-18  Lawrence Crowl  <crowl@google.com>
11619
11620         * timevar.def (TV_PHASE_GENERATE): Rename to TV_PHASE_LATE_ASM.
11621         (TV_PHASE_CGRAPH): Rename to TV_PHASE_OPT_GEN.
11622         (TV_PHASE_STREAM_IN): New.
11623         (TV_PHASE_STREAM_OUT): New.
11624         * timevar.c (validate_phases): New.
11625         (timevar_print): Call validate_phases.
11626         * c-decl.c (c_write_global_declarations): Rename use of TV_PHASE_CGRAPH
11627         to TV_PHASE_OPT_GEN.
11628         * langhooks.c (write_global_declarations): Rename use of
11629         TV_PHASE_CGRAPH to TV_PHASE_OPT_GEN.  Use TV_PHASE_DBGINFO instead of
11630         TV_PHASE_CHECK_DBGINFO.
11631         * toplev.c (compile_file): Rename use of TV_PHASE_GENERATE to
11632         TV_PHASE_LATE_ASM.  Move start of TV_PHASE_LATE_ASM to after call to
11633         lang_hooks.decls.final_write_globals.
11634
11635 2012-06-18  David Edelshn  <dje.gcc@gmail.com>
11636
11637         * config/rs6000/aix52.h (TARGET_EXTRA_BUILTINS): Define as 0.
11638
11639 2012-06-18  Uros Bizjak  <ubizjak@gmail.com>
11640
11641         PR target/53712
11642         * config/i386/sse.md (*sse4_2_pcmpestr_unaligned): New.
11643         (*sse4_2_pcmpistr_unaligned): New.
11644
11645 2012-06-18  Ian Bolton  <ian.bolton@arm.com>
11646             Sameera Deshpande  <sameera.deshpande@arm.com>
11647             Greta Yorsh  <greta.yorsh@arm.com>
11648
11649         * config/arm/arm-protos.h (arm_output_epilogue): Remove.
11650         * config/arm/arm.c (print_multi_reg): Remove.
11651         (vfp_output_fldmd): Likewise.
11652         (arm_output_epilogue): Likewise.
11653         * config/arm/arm.md (epilogue_insns): Update condition and code.
11654
11655 2012-06-18  Ian Bolton  <ian.bolton@arm.com>
11656             Sameera Deshpande  <sameera.deshpande@arm.com>
11657             Greta Yorsh  <greta.yorsh@arm.com>
11658
11659         * config/arm/arm-protos.h (thumb2_expand_return): New declaration.
11660         * config/arm/arm.c (thumb2_expand_return): New function.
11661         * config/arm/arm.md (return): Update condition and code.
11662
11663 2012-06-18  Ian Bolton  <ian.bolton@arm.com>
11664             Sameera Deshpande  <sameera.deshpande@arm.com>
11665             Greta Yorsh  <greta.yorsh@arm.com>
11666
11667         * config/arm/arm-protos.h (output_return_instruction): New parameter
11668         and int to bool change of parameter types.
11669         * config/arm/arm.c (output_return_instruction): Likewise.
11670         * config/arm/arm.md (arm_simple_return): New pattern.
11671         (arm_return, cond_return, cond_return_inverted): Add new arguments.
11672         * config/arm/thumb2.md (thumb2_return): Update condition and code.
11673
11674 2012-06-18  Ian Bolton  <ian.bolton@arm.com>
11675             Sameera Deshpande  <sameera.deshpande@arm.com>
11676             Greta Yorsh  <greta.yorsh@arm.com>
11677
11678         * config/arm/arm-protos.h (arm_expand_epilogue): New declaration.
11679         * config/arm/arm.c (arm_expand_epilogue): New function.
11680         * config/arm/arm.md (epilogue): Update condition and code.
11681         (sibcall_epilogue): Likewise.
11682
11683 2012-06-18  Ian Bolton  <ian.bolton@arm.com>
11684             Sameera Deshpande  <sameera.deshpande@arm.com>
11685             Greta Yorsh  <greta.yorsh@arm.com>
11686
11687         * config/arm/arm.c (arm_expand_epilogue_apcs_frame): New function.
11688         * config/arm/arm.md (arm_addsi3) Add an alternative.
11689
11690 2012-06-18  Ian Bolton  <ian.bolton@arm.com>
11691             Sameera Deshpande  <sameera.deshpande@arm.com>
11692             Greta Yorsh  <greta.yorsh@arm.com>
11693
11694         * config/arm/arm.md (vfp_pop_multiple_with_writeback) New define_insn.
11695         * config/arm/predicates.md (pop_multiple_fp) New special predicate.
11696         * config/arm/arm.c (arm_emit_vfp_multi_reg_pop): New function.
11697
11698 2012-06-18  Ian Bolton  <ian.bolton@arm.com>
11699             Sameera Deshpande  <sameera.deshpande@arm.com>
11700             Greta Yorsh  <greta.yorsh@arm.com>
11701
11702         * config/arm/arm.md (load_multiple_with_writeback) New define_insn.
11703         (load_multiple, pop_multiple_with_writeback_and_return) Likewise.
11704         (pop_multiple_with_return, ldr_with_return) Likewise.
11705         * config/arm/predicates.md (pop_multiple_return) New special predicate.
11706         * config/arm/arm-protos.h (arm_output_multireg_pop) New declaration.
11707         * config/arm/arm.c (arm_output_multireg_pop) New function.
11708         (arm_emit_multi_reg_pop): New function.
11709
11710 2012-06-18  Greta Yorsh  <Greta.Yorsh@arm.com>
11711
11712         * config/arm/arm.c (ldm_stm_operation_p): Require SP
11713         as base register for loads if SP is in the register list.
11714
11715 2012-06-18  Richard Guenther  <rguenther@suse.de>
11716
11717         PR tree-optimization/53693
11718         * tree-vect-patterns.c (vect_operation_fits_smaller_type):
11719         Reject operands with more than one use.
11720
11721 2012-06-18  Bill Schmidt  <wschmidt@linux.ibm.com>
11722
11723         PR tree-optimization/53703
11724         * tree-ssa-phiopt.c (hoist_adjacent_loads): Skip virtual phis;
11725         correctly set bb_for_def[12].
11726
11727 2012-06-18  Steven Bosscher  <steven@gcc.gnu.org>
11728
11729         * config/vax/vax.h (VMS_TARGET): Remove.
11730
11731 2012-06-18  Richard Guenther  <rguenther@suse.de>
11732
11733         * tree-vrp.c (extract_range_from_assert): Split out range
11734         intersecting code.
11735         (intersect_ranges): New function.
11736         (vrp_intersect_ranges): Likewise.
11737
11738 2012-06-18  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
11739
11740         * config/s390/s390.c (s390_gimplify_va_arg): Revert change from
11741         r187965.
11742
11743 2012-06-18  Tejas Belagod  <tejas.belagod@arm.com>
11744
11745         * doc/md.texi: Document int iterators.
11746         * read-rtl.c (ints): New iterator group.
11747         (find_int): Int iterator group callback.
11748         (apply_int_iterator): Likewise.
11749         (apply_iterators): Traverse int iterator table and add all the used
11750         iterators to list.
11751         (initialize_iterators): Initialize data structures and callbacks for
11752         int iterators.
11753         (read_rtx): Parse and read mappings for int iterators.
11754         (read_rtx_code): Record int iterator usage.
11755
11756 2012-06-18  Richard Sandiford  <rdsandiford@googlemail.com>
11757
11758         PR middle-end/53698
11759         * expr.c (expand_expr_addr_expr_1): Convert to tmode before
11760         performing an addition.
11761
11762 2012-06-17  Steven Bosscher  <steven@gcc.gnu.org>
11763
11764         * output.h (split_double): Move prototype to rtl.h.
11765         (constructor_static_from_elts_p): Move prototype to tree.c.
11766         * rtl.h (split_double): Moved here from output.h.
11767         * tree.h (constructor_static_from_elts_p): Moved here from output.h.
11768         * final.c (split_double): Move from here ...
11769         * rtlanal.c (split_double): ... to here.
11770         * expr.c: Do not include output.h.
11771
11772 2012-06-17  Steven Bosscher  <steven@gcc.gnu.org>
11773
11774         * cfglayout.h: Remove.
11775         * cfglayout.c: Remove.
11776         * function.h (struct function): Remove x_last_location field.
11777         * function.c: Do not include cfglayout.h.
11778         (expand_function_start): Do not call no-op force_next_line_note.
11779         (expand_function_end): Likewise.
11780         * cfgrtl.c: Do not include cfglayout.h.  Include gt-cfgrtl.h.
11781         (unlink_insn_chain): Moved here from cfglayout.c.
11782         (skip_insns_after_block, label_for_bb, record_effective_endpoints,
11783         into_cfg_layout_mode, outof_cfg_layout_mode,
11784         pass_into_cfg_layout_mode, pass_outof_cfg_layout_mode,
11785         relink_block_chain, fixup_reorder_chain, verify_insn_chain,
11786         fixup_fallthru_exit_predecessor, force_one_exit_fallthru,
11787         cfg_layout_can_duplicate_bb_p, duplicate_insn_chain,
11788         cfg_layout_duplicate_bb, cfg_layout_initialize, break_superblocks,
11789         cfg_layout_finalize): Likewise.
11790         (rtl_can_remove_branch_p): Likewise.
11791         * rtl.h (insn_scope): Move prototype from cfglayout.h here.
11792         (duplicate_insn_chain): Likewise.
11793         (force_next_line_note): Remove prototype.
11794         * emit-rtl.c: Do not include tree-flow.h, egad.  Include vecprim.h.
11795         (last_location): Remove #define to emit.x_last_location.
11796         (force_next_line_note): Remove no-op function.
11797         (init_emit): Don't set x_last_location.
11798         (block_locators_locs, block_locators_blocks, locations_locators_locs,
11799         locations_locators_vals, prologue_locator, epilogue_locator,
11800         curr_location, last_location, curr_block, last_block, curr_rtl_loc):
11801         Move POD to here from cfglayout.c.
11802         (insn_locators_alloc, insn_locators_finalize, insn_locators_free,
11803         set_curr_insn_source_location, get_curr_insn_source_location,
11804         set_curr_insn_block, get_curr_insn_block, curr_insn_locator,
11805         locator_scope, insn_scope, locator_location, locator_line, insn_line,
11806         locator_file, insn_file, locator_eq): Move to here from cfglayout.c.
11807         * cfghooks.h: Remove double-include protection.
11808         (can_copy_bbs_p, copy_bbs): Move prototypes from cfglayout.h to here.
11809         * cfghooks.c (can_copy_bbs_p, copy_bbs): Move to here from cfglayout.c.
11810         * final.c: Do not include cfglayout.h.
11811         (choose_inner_scope, change_scope): Move to here from cfglayout.c.
11812         (reemit_insn_block_notes): Likewise.  Make static.
11813         * tree-flow.h (tree_could_trap_p, operation_could_trap_helper_p,
11814         operation_could_trap_p, tree_could_throw_p): Move from here...
11815         * tree.h: ... to here.
11816         * gengtype.c (open_base_files): Remove cfglayout.h from the list.
11817         * profile.c: Do not include cfghooks.h.
11818         * cfgloopmanip.c: Do not include cfglayout.h and cfghooks.h.
11819         * modulo-sched.c: Likewise.
11820         * loop-unswitch.c: Do not include cfglayout.h.
11821         * sched-ebb.c: Likewise.
11822         * tracer.c: Likewise.
11823         * ddg.c: Likewise.
11824         * tree-vect-loop-manip.c: Likewise.
11825         * loop-init.c: Likewise.
11826         * dwarf2out.c: Likewise.
11827         * hw-doloop.c: Likewise.
11828         * loop-unroll.c: Likewise.
11829         * cfgcleanup.c: Likewise.
11830         * bb-reorder.c: Likewise.
11831         * sched-rgn.c: Likewise.
11832         * tree-cfg.c: Likewise.
11833         * config/alpha/alpha.c: Likewise.
11834         * config/spu/spu.c: Likewise.
11835         * config/sparc/sparc.c: Likewise.
11836         * config/sh/sh.c: Likewise.
11837         * config/c6x/c6x.c: Likewise.
11838         * config/ia64/ia64.c: Likewise.
11839         * config/rs6000/rs6000.c: Likewise.
11840         * config/score/score.c: Likewise.
11841         * config/mips/mips.c: Likewise.
11842         * config/bfin/bfin.c: Likewise.
11843         * Makefile.in (CFGAYOUT_H): Remove, and fixup users.
11844         * config/rs6000/t-rs6000 (rs6000.o): Do not depend on cfglayout.h.
11845         * config/spu/t-spu-elf (spu.o: $): Likewise.
11846         * config/sparc/t-sparc (sparc.o): Do not depend on CFGLAYOUT_H.
11847
11848 2012-06-17  Steven Bosscher  <steven@gcc.gnu.org>
11849
11850         * cfgloop.h: Do not include rtl.h.
11851         (enum iv_extend_code): New.
11852         (struct rtx_iv): Use iv_extend_code instead of rtx_code.
11853         * Makefile.in (CFGLOOP_H): Do not depend on RTL_H.
11854         * loop-iv.c (iv_extend_to_rtx_code): New function to translate
11855         an IV_EXTEND_CODE to an RTX_CODE.
11856         (dump_iv_info): Update for rtx_iv field type change.
11857         (iv_constant): Likewise.
11858         (iv_subreg): Likewise.
11859         (iv_extend): Likewise.
11860         (iv_neg): Likewise.
11861         (iv_add): Likewise.
11862         (iv_mult): Likewise.
11863         (iv_shift): Likewise.
11864         (get_biv_step_1): Likewise.
11865         (get_biv_step): Likewise.
11866         (iv_analyze_biv): Likewise.
11867         (get_iv_value): Likewise.
11868         (shorten_into_mode): Likewise.
11869         (canonicalize_iv_subregs): Likewise.
11870         * sese.c (sese_build_liveouts): Use MAY_HAVE_DEBUG_STMTS instead
11871         of MAY_HAVE_DEBUG_INSNS.
11872         * tree-ssa-loop-ivopts.c: Include recog.h after expr.h.
11873         * tree-ssa-loop-prefetch.c: Likewise.
11874
11875 2012-06-17  Steven Bosscher  <steven@gcc.gnu.org>
11876
11877         * expmed.c (ceil_log2): Move from here...
11878         * hwint.c: ... to here for older GCCs...
11879         * hwint.h: ... and here for newer GCCs.
11880         * rtl.h (ceil_log2): Remove prototype.
11881
11882         * tree-phinodes.c: Do not include rtl.h.
11883         * Makefile.in (tree-phinodes.o): Do not depend on RTL_H.
11884
11885 2012-06-17  Steven Bosscher  <steven@gcc.gnu.org>
11886
11887         * config/cris/cris.h (TARGET_ELF): Remove.
11888         (FORCE_EH_FRAME_INFO_IN_DATA_SECTION): Remove.
11889         (CRIS_ASM_OUTPUT_ALIGNED_DECL_COMMON): Simpify using TARGET_ELF==1.
11890         (LOCAL_LABEL_PREFIX): Likewise.
11891         * config/cris/cris.c (cris_target_asm_named_section): Remove.
11892         (cris_option_override): Simpify using TARGET_ELF==1.
11893         (cris_file_start): Likewise.
11894         * config/cris/cris-protos.h (cris_target_asm_named_section): Remove.
11895
11896 2012-06-17  Uros Bizjak  <ubizjak@gmail.com>
11897
11898         * config/i386/sse.md (vcvtph2ps): Fix vec_select selector.
11899
11900 2012-06-16  Eric Botcazou  <ebotcazou@adacore.com>
11901
11902         PR middle-end/53590
11903         * tree-inline.c (initialize_cfun): Copy can_delete_dead_exceptions.
11904
11905 2012-06-15  Easwaran Raman  <eraman@google.com>
11906
11907         * passes.c (init_optimization_passes): Remove pass_call_cdce
11908         from its current position and insert after pass_dce.
11909
11910 2012-06-15  Walter Lee  <walt@tilera.com>
11911
11912         * config/tilegx/sync.md (atomic_fetch_<fetchop_name><mode>): Fix typo.
11913
11914 2012-06-15  Richard Earnshaw  <rearnsha@arm.com>
11915
11916         * arm.c (note_invalid_constants): Don't return a result.
11917         (arm_memory_load_p): Delete function.
11918         (arm_const_double_rtx): Delete iterator variable i;
11919         (fp_immediate_constant): Likewise.
11920         (fp_const_from_val): Likewise.
11921
11922         * arm.c (arm_init_iwmmxt_builtins): Delete void_ftype_void.
11923
11924 2012-06-15  Marc Glisse  <marc.glisse@inria.fr>
11925
11926         PR c++/51033
11927         * c-typeck.c (c_build_vec_perm_expr): Move to c-family/c-common.c.
11928         * c-tree.h (c_build_vec_perm_expr): Move to c-family/c-common.h.
11929
11930 2012-06-15  Georg-Johann Lay  <avr@gjlay.de>
11931
11932         * config/avr/avr.c (avr_default_expand_builtin): New function.
11933         (avr_expand_builtin): Use it.
11934         (avr_expand_unop_builtin): Remove.
11935         (avr_expand_binop_builtin): Remove.
11936         (avr_expand_triop_builtin): Remove.
11937
11938 2012-06-15  Michael Matz  <matz@suse.de>
11939
11940         PR middle-end/38474
11941         * cfgexpand.c (add_alias_set_conflicts): Remove.
11942         (expand_used_vars): Don't call it.
11943         (aggregate_contains_union_type): Remove.
11944         * function.c (n_temp_slots_in_use): New static data.
11945         (make_slot_available, assign_stack_temp_for_type): Update it.
11946         (init_temp_slots): Zero it.
11947         (remove_unused_temp_slot_addresses): Use it for quicker removal.
11948         (remove_unused_temp_slot_addresses_1): Use htab_clear_slot.
11949
11950 2012-06-15  Michael Matz  <matz@suse.de>
11951
11952         * gimplify.c (gimplify_compound_literal_expr): Take gimple_test_f
11953         argument, don't emit assign statement if value is directly usable.
11954         (gimplify_expr): Adjust.
11955
11956 2012-06-15  Michael Matz  <matz@suse.de>
11957
11958         * gimplify.c (gimplify_modify_expr): Fold generated statements.
11959         * gimple-fold.c (can_refer_decl_in_current_unit_p): Check flag_ltrans.
11960
11961 2012-06-15  Richard Guenther  <rguenther@suse.de>
11962
11963         * tree-vrp.c (set_and_canonicalize_value_range): Use canonical
11964         predicates to set VR_UNDEFINED and VR_VARYING.  Drop a case
11965         we assert for in set_value_range to VR_VARYING.
11966
11967 2012-06-15  Richard Earnshaw  <rearnsha@arm.com>
11968
11969         * arm.md (addsf3, adddf3): Use s_register_operand.
11970         (subsf3, subdf3): Likewise.
11971         (mulsf3, muldf3): Likewise.
11972         (difsf3, divdf3): Likewise.
11973         (movsfcc, movdfcc): Likewise.
11974         * predicates.md (f_register_operand): Delete.
11975         (arm_float_rhs_operand): Delete.
11976         (arm_float_add_operand): Delete.
11977         (arm_float_compare_operand): Use s_register_operand when
11978         there's no VFP.
11979         (cirrus_register_operand): Delete.
11980         (cirrus_fp_register): Delete.
11981         (cirrus_shift_const): Delete.
11982         (cmpdi_operand): Remove Maverick support.
11983         * constraints.md (f, v, H): Delete constraints.
11984         (G): Update documentation.
11985         * arm.c (fp_consts_inited): Convert to bool.
11986         (strings_fp): Delete.
11987         (values_fp): Delete.
11988         (value_fp0): New variable.
11989         (init_fp_table): Simplify logic.
11990         (arm_const_double_rtx): Likewise.
11991         (fp_immediate_constant): Likewise.
11992         (fp_const_from_val): Likewise.
11993         (neg_const_double_rtx_ok_for_fpa): Delete.
11994         * doc/md.texi (ARM constraints): Update documentation.
11995
11996 2012-06-15  Ulrich Weigand  <ulrich.weigand@linaro.org>
11997
11998         PR tree-optimization/53636
11999         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Verify
12000         stride when doing basic-block vectorization.
12001
12002 2012-06-15  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
12003
12004         * tree-vect-generic.c (lower_vec_perm): Propagate vector constants
12005         into VEC_PERM_EXPR.
12006
12007 2012-06-15  Jakub Jelinek  <jakub@redhat.com>
12008
12009         * tree-vect-patterns.c (vect_pattern_recog): Don't unnecessarily
12010         allocate and free bbs array for the SLP case.
12011
12012         PR tree-optimization/51581
12013         * expr.h (choose_multiplier): New prototype.
12014         * expmed.c (choose_multiplier): No longer static.
12015         Change multiplier_ptr from rtx * to UHWI *.
12016         (expand_divmod): Adjust callers.
12017         * tree-vect-patterns.c (vect_recog_sdivmod_pow2_pattern): Renamed to...
12018         (vect_recog_divmod_pattern): ... this.  Pass bb_vinfo as last
12019         argument to new_stmt_vec_info.  Attempt to optimize also divisions
12020         by non-pow2 constants if integer vector division isn't supported.
12021         * tree-vect-stmts.c (vect_analyze_stmt): If node != NULL,
12022         don't look at pattern stmts and sequences.
12023
12024 2012-06-15  Eric Botcazou  <ebotcazou@adacore.com>
12025
12026         PR middle-end/53590
12027         * common.opt (-fdelete-dead-exceptions): New switch.
12028         * doc/invoke.texi (Code Gen Options): Document it.
12029         * cse.c (count_reg_usage) <CALL_INSN>: Use !insn_nothrow_p in lieu of
12030         insn_could_throw_p predicate.  Do not skip an insn that could throw
12031         if dead exceptions can be deleted.
12032         (insn_live_p): Likewise, do not return true in that case.
12033         * dce.c (can_alter_cfg): New flag.
12034         (deletable_insn_p): Do not return false for an insn that can throw if
12035         the CFG can be altered and dead exceptions can be deleted.
12036         (init_dce): Set can_alter_cfg to false for fast DCE, true otherwise.
12037         * dse.c (scan_insn): Use !insn_nothrow_p in lieu of insn_could_throw_
12038         predicate. Do not preserve an insn that could throw if dead exceptions
12039         can be deleted.
12040         * function.h (struct function): Add can_delete_dead_exceptions flag.
12041         * function.c (allocate_struct_function): Set it.
12042         * lto-streamer-in.c (input_struct_function_base): Stream it.
12043         * lto-streamer-out.c (input_struct_function_base): Likewise.
12044         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Do not mark a
12045         statement that could throw as necessary if dead exceptions can be
12046         deleted.
12047
12048 2012-06-14  Maxim Kuvyrkov  <maxim@codesourcery.com>
12049
12050         * config/tilegx/sync.md (atomic_fetch_sub<mode>): Fix typo.
12051
12052 2012-06-14  Oleg Endo  <olegendo@gcc.gnu.org>
12053
12054         PR target/53568
12055         * config/sh/sh.md: Add peephole for swapbsi2.
12056         (*swapbisi2_and_shl8, *swapbhisi2): New insns and splits.
12057
12058 2012-06-14  Uros Bizjak  <ubizjak@gmail.com>
12059
12060         * config/i386/i386.md (*zero_extendsidi2): Remove x,x alternative.
12061         (*zero_extendsidi2_rex64): Ditto.  Remove isa attribute.
12062
12063 2012-06-14  Jakub Jelinek  <jakub@redhat.com>
12064
12065         PR target/53639
12066         * config/i386/i386.md (*anddi_1 into *andsi_1_zext splitter): New.
12067
12068 2012-06-14  Richard Earnshaw  <rearnsha@arm.com>
12069
12070         * arm.c (arm_cirrus_insn_p): Delete.
12071         (cirrus_reorg): Delete.
12072         (arm_reorg): Don't call cirrus_reorg.
12073         (arm_final_prescan_insn_p): Don't check for cirrus insns.
12074         * arm.md (define_attr "type"): Remove mav_farith and mav_dmult.
12075         (adddi3, subdi3): Remove Maverick support.
12076         (arm_adddi3): Likewise.
12077         (adddi_sesidi_di, adddi_zesidi_di): Likewise.
12078         (addsf3, adddf3): Likewise.
12079         (subsf3, subdf3): Likewise.
12080         (mulsf3, muldf3): Likewise.
12081         (ashldi3, ashrdi3, lshrdi3): Likewise.
12082         (floatsisf2, floatsidf2): Likewise.
12083         (fix_truncsfsi2, fix_truncdfsi2): Likewise.
12084         (arm_movdi, thumb1_movdi_insn): Likewise.
12085         (arm_cmpdi_insn): Likewise.
12086         (cirrus_cmpsf, cirrus_cmpdf, cirrus_cmpdi): Likewise.
12087         (cirrus.md): Don't include.
12088         * cirrus.md: Delete file.
12089         * t-arm (MD_INCLUDES): Remove cirrus.md.
12090
12091 2012-06-14  Eric Botcazou  <ebotcazou@adacore.com>
12092
12093         * dwarf2out.c (function_possibly_abstracted_p): New static function.
12094         (gen_subprogram_die): Use it function_possibly_abstracted_p in lieu of
12095         cgraph_function_possibly_inlined_p.
12096         (gen_inlined_subroutine_die): Return if the origin is to be ignored.
12097         (process_scope_var): Do not emit concrete instances of abstracted
12098         nested functions from here.
12099         (gen_decl_die): Emit the abstract instance if the function is possibly
12100         abstracted and not only possibly inlined.
12101         (dwarf2out_finish): Find the first non-abstract parent instance and
12102         attach concrete instances on the limbo list to it.
12103
12104 2012-06-14  Richard Earnshaw  <rearnsha@arm.com>
12105
12106         * arm.md (divsf3, divdf3): Remove FPA support.
12107         (negsf2, negdf2): Likewise.
12108         (sqrtsf2, sqrtdf2): Likewise.
12109         (movdfcc): Likewise.
12110         (modsf3, moddf3, movxf): Delete.
12111         (push_fp_multi): Delete.
12112         (fpa.md): Don't include it.
12113         * fpa.md: Delete file.
12114         * t-arm (MD_INCLUDES): Remove fpa.md.
12115
12116 2012-06-14  Bill Schmidt  <wschmidt@linux.ibm.com>
12117
12118         * tree-vectorizer.h (vect_get_stmt_cost): Move from tree-vect-stmts.c.
12119         (cost_for_stmt): Remove decl.
12120         (vect_get_single_scalar_iteration_cost): Correct typo in name.
12121         * tree-vect-loop.c (vect_get_cost): Remove.
12122         (vect_get_single_scalar_iteration_cost): Correct typo in name; use
12123         vect_get_stmt_cost rather than vect_get_cost.
12124         (vect_get_known_peeling_cost): Use vect_get_stmt_cost rather than
12125         vect_get_cost.
12126         (vect_estimate_min_profitable_iters): Correct typo in call to
12127         vect_get_single_scalar_iteration_cost; use vect_get_stmt_cost rather
12128         than vect_get_cost.
12129         (vect_model_reduction_cost): Use vect_get_stmt_cost rather than
12130         vect_get_cost.
12131         (vect_model_induction_cost): Likewise.
12132         * tree-vect-data-refs.c (vect_peeling_hash_get_lowest_cost): Correct
12133         typo in call to vect_get_single_scalar_iteration_cost.
12134         * tree-vect-stmts.c (vect_get_stmt_cost): Move to tree-vectorizer.h.
12135         (cost_for_stmt): Remove unnecessary function.
12136         * Makefile.in (TREE_VECTORIZER_H): Update dependencies.
12137
12138 2012-06-14  Richard Earnshaw  <rearnsha@arm.com>
12139
12140         * arm.opt (mfp=2, mfp=3, mfpe, mfpe=2, mfpe=3): Delete options.
12141         * arm-fpus.def (fpa, fpe2, fpe3, maverick): Delete FPU types.
12142         * arm-tables.opt: Regenerated.
12143         * doc/invoke.texi: Remove references to deleted options.
12144
12145 2012-06-14  Sandeep Kumar Singh  <Sandeep.Singh2@kpitcummins.com>
12146
12147         * config/h8300/genmova.sh: Modified to add offset bits of
12148         mova/Sz assembly instruction for memory access.
12149         * config/h8300/h8300.c: Likewise.
12150         * config/h8300/mova.md: Likewise.
12151
12152 2012-06-12  Christian Bruel  <christian.bruel@st.com>
12153
12154         PR target/53621
12155         * config/sh/sh.c (sh_option_override): Don't force
12156          flag_omit_frame_pointer and maccumulate_outgoing_args.
12157         * config/sh/sh.opt (maccumulate-outgoing-args): Init as Var.
12158
12159 2012-06-14  Richard Guenther  <rguenther@suse.de>
12160
12161         * tree-vrp.c (VR_INITIALIZER): New define.
12162         (ranges_from_anti_range): New function.
12163         (extract_range_from_binary_expr_1): Decompose operations on
12164         VR_ANTI_RANGEs to operations on VR_RANGE.
12165         (extract_range_from_unary_expr_1): Likewise.
12166         (extract_range_from_binary_expr_1, extract_range_from_binary_expr,
12167         extract_range_from_unary_expr_1, extract_range_from_unary_expr,
12168         extract_range_from_cond_expr, adjust_range_with_scev,
12169         vrp_visit_assignment_or_call, vrp_visit_phi_node,
12170         simplify_bit_ops_using_ranges): Use VR_INITIALIZER.
12171
12172 2012-06-13  Richard Henderson  <rth@redhat.com>
12173
12174         * hwint.h (HOST_WIDEST_INT_C): New.
12175         (HOST_WIDE_INT_C): New.
12176         (HOST_WIDE_INT_1): Use it.
12177         * config/alpha/alpha.c (alpha_trampoline_init): Use it.
12178
12179 2012-06-13  Alexandre Oliva  <aoliva@redhat.com>
12180
12181         PR debug/49888
12182         * var-tracking.c: Include alias.h.
12183         (overlapping_mems): New struct.
12184         (drop_overlapping_mem_locs): New.
12185         (clobber_overlapping_mems): New.
12186         (var_mem_delete_and_set, var_mem_delete): Call it.
12187         (val_bind): Likewise, but only if modified.
12188         (compute_bb_dataflow, emit_notes_in_bb): Call it on MEMs.
12189         * Makefile.in (var-tracking.o): Depend in $(ALIAS_H).
12190
12191 2012-06-13  Alexandre Oliva  <aoliva@redhat.com>
12192
12193         PR debug/47624
12194         * var-tracking.c (loc_exp_dep_pool): New.
12195         (vt_emit_notes): Create and release the pool.
12196         (compute_bb_dataflow): Use value-based locations in MO_VAL_SET.
12197         (emit_notes_in_bb): Likewise.
12198         (loc_exp_dep_insert): Deal with NOT_ONEPART vars.
12199         (notify_dependents_of_changed_value): Likewise.
12200         (notify_dependents_of_resolved_value): Check that NOT_ONEPART
12201         variables don't have a VAR_LOC_DEP_LST.
12202         (emit_note_insn_var_location): Expand NOT_ONEPART locs that are
12203         VALUEs or MEMs of VALUEs.
12204
12205 2012-06-13  Alexandre Oliva  <aoliva@redhat.com>
12206
12207         PR debug/52983
12208         PR debug/48866
12209         * dce.c (word_dce_process_block): Insert debug temps only if the
12210         insn is not marked.
12211         (dce_process_block): Likewise, and if debug.used is not empty,
12212         and only after iterating over all DEFs that might mark the insn.
12213
12214 2012-06-13  Alexandre Oliva  <aoliva@redhat.com>
12215
12216         * common.opt (ftree-coalesce-inlined-vars): New.
12217         (ftree-coalesce-vars): New.
12218         * doc/invoke.texi: Document them.
12219         * tree-ssa-copyrename.c (copy_rename_partition_coalesce):
12220         Implement them.
12221
12222 2012-06-13  Richard Sandiford  <rdsandiford@googlemail.com>
12223
12224         * read-rtl.c (mapping): Remove index field.  Add current_value field.
12225         Define heap vectors.
12226         (iterator_group): Fix long line.  Remove num_builtins field and
12227         uses_iterator fields.  Make apply_iterator take a void * parameter.
12228         (iterator_use, atttribute_use): New structures.
12229         (iterator_traverse_data, BELLWETHER_CODE, bellwether_codes): Delete.
12230         (current_iterators, iterator_uses, attribute_uses): New variables.
12231         (uses_mode_iterator_p, uses_code_iterator_p): Delete.
12232         (apply_mode_iterator, apply_code_iterator): Take a void * parameter.
12233         (map_attr_string, apply_iterator_to_string): Remove iterator
12234         and value parameters.  Look through all current iterator values
12235         for a matching attribute.
12236         (mode_attr_index, apply_mode_maps): Delete.
12237         (apply_iterator_to_rtx): Replace with...
12238         (copy_rtx_for_iterators): ...this new function.
12239         (uses_iterator_p, apply_iterator_traverse): Delete.
12240         (apply_attribute_uses, add_current_iterators, apply_iterators): New
12241         functions.
12242         (add_mapping): Remove index field.  Set current_value field.
12243         (initialize_iterators): Don't set num_builtins and uses_iterator_p
12244         fields.
12245         (find_iterator): Delete.
12246         (record_iterator_use, record_attribute_use): New functions.
12247         (record_potential_iterator_use): New function.
12248         (check_code_iterator): Remove handling of bellwether codes.
12249         (read_rtx): Remove mode maps.  Truncate iterator and attribute uses.
12250         (read_rtx_code, read_nested_rtx, read_rtx_variadic): Remove mode_maps
12251         parameter.  Use the first code iterator value instead of the
12252         bellwether_codes array.  Use record_potential_iterator_use for modes.
12253
12254 2012-06-13  Oleg Endo  <olegendo@gcc.gnu.org>
12255
12256         PR target/53568
12257         * config/sh/sh.md (bswapsi2): New expander.
12258         (swapbsi2): New insn.
12259
12260 2012-06-13  H.J. Lu  <hongjiu.lu@intel.com>
12261
12262         PR target/53647
12263         * config/i386/i386.c (ix86_tune_cost): New variable.
12264         (ix86_option_override_internal): Set ix86_tune_cost.  Use
12265         ix86_tune_cost for simultaneous_prefetches, prefetch_block,
12266         l1_cache_size and l2_cache_size.
12267
12268 2012-06-13  Richard Guenther  <rguenther@suse.de>
12269
12270         * tree-vrp.c (vrp_meet): Properly meet equivalent ranges.
12271         Handle meeting two VR_RANGE to an VR_ANTI_RANGE.  Implement
12272         all possible meetings of VR_RANGE with VR_ANTI_RANGE and
12273         VR_ANTI_RANGE with VR_ANTI_RANGE.
12274
12275 2012-06-13  Richard Earnshaw  <rearnsha@arm.com>
12276
12277         * config.gcc (unsupported): Move obsoleted FPA-based configurations
12278         here from ...
12279         (obsolete): ... here.
12280         (arm*-*-freebsd*): Remove.
12281         (arm*-*-linux*): Only accept EABI variants.  Simplify logic.
12282         (arm*-*-uclinux*): Likewise.
12283         (arm*-*-ecos-elf): Remove.
12284         (arm*-*-rtems*): Remove.
12285         (arm*-*-elf): Remove.
12286         (arm*-wince-pe*): Remove.
12287         (arm, --with-fpu): Remove support for fpa and Maverick variants.
12288         * arm/ecos-elf.h: Delete.
12289         * arm/t-strongarm-elf: Delete.
12290         * arm/rtems-elf.h: Delete.
12291         * arm/wince-pe.h: Delete.
12292         * arm/pe.c: Delete.
12293         * arm/pe.h: Delete.
12294         * arm/t-wince-pe: Delete.
12295
12296 2012-06-13  Bill Schmidt  <wschmidt@linux.ibm.com>
12297
12298         PR tree-optimization/53647
12299         * tree-ssa-phiopt.c (gate_hoist_loads): Skip transformation for
12300         targets with no defined cache line size.
12301
12302 2012-06-13  Bill Schmidt  <wschmidt@linux.ibm.com>
12303
12304         * targhooks.c (default_builtin_vectorized_conversion): Handle
12305         vec_construct, using vectype to base cost on subparts.
12306         * target.h (enum vect_cost_for_stmt): Add vec_construct.
12307         * tree-vect-stmts.c (vect_model_load_cost): Use vec_construct
12308         instead of scalar_to-vec.
12309         * config/spu/spu.c (spu_builtin_vectorization_cost): Handle
12310         vec_construct in same way as default for now.
12311         * config/i386/i386.c (ix86_builtin_vectorization_cost): Likewise.
12312         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost):
12313         Handle vec_construct, including special case for 32-bit loads.
12314
12315 2012-06-13  Xinyu Qi <xyqi@marvell.com>
12316
12317         * config/arm/arm.c (FL_IWMMXT2): New define.
12318         (arm_arch_iwmmxt2): New variable.
12319         (arm_option_override): Enable use of iWMMXt with VFP.
12320         Disable use of iWMMXt with NEON. Disable use of iWMMXt under
12321         Thumb mode. Set arm_arch_iwmmxt2.
12322         (arm_expand_binop_builtin): Accept VOIDmode op.
12323         (enum arm_builtins): Revise built-in fcode.
12324         (IWMMXT2_BUILTIN): New define.
12325         (IWMMXT2_BUILTIN2): Likewise.
12326         (iwmmx2_mbuiltin): Likewise.
12327         (builtin_description bdesc_2arg): Revise built in declaration.
12328         (builtin_description bdesc_1arg): Likewise.
12329         (arm_init_iwmmxt_builtins): Revise built in initialization.
12330         (arm_expand_builtin): Revise built in expansion.
12331         (arm_output_iwmmxt_shift_immediate): New function.
12332         (arm_output_iwmmxt_tinsr): Likewise.
12333         * config/arm/arm-protos.h (arm_output_iwmmxt_shift_immediate): Declare.
12334         (arm_output_iwmmxt_tinsr): Likewise.
12335         * config/arm/iwmmxt.md (WCGR0, WCGR1, WCGR2, WCGR3): New constant.
12336         (iwmmxt_psadbw, iwmmxt_walign, iwmmxt_tmrc, iwmmxt_tmcr): Delete.
12337         (rorv4hi3, rorv2si3, rordi3): Likewise.
12338         (rorv4hi3_di, rorv2si3_di, rordi3_di): Likewise.
12339         (ashrv4hi3_di, ashrv2si3_di, ashrdi3_di): Likewise.
12340         (lshrv4hi3_di, lshrv2si3_di, lshrdi3_di): Likewise.
12341         (ashlv4hi3_di, ashlv2si3_di, ashldi3_di): Likewise.
12342         (iwmmxt_tbcstqi, iwmmxt_tbcsthi, iwmmxt_tbcstsi): Likewise
12343         (*iwmmxt_clrv8qi, *iwmmxt_clrv4hi, *iwmmxt_clrv2si): Likewise.
12344         (tbcstv8qi, tbcstv4hi, tbsctv2si): New pattern.
12345         (iwmmxt_clrv8qi, iwmmxt_clrv4hi, iwmmxt_clrv2si): Likewise.
12346         (*and<mode>3_iwmmxt, *ior<mode>3_iwmmxt, *xor<mode>3_iwmmxt): Likewise.
12347         (ror<mode>3, ror<mode>3_di): Likewise.
12348         (ashr<mode>3_di, lshr<mode>3_di, ashl<mode>3_di): Likewise.
12349         (ashli<mode>3_iwmmxt, iwmmxt_waligni, iwmmxt_walignr): Likewise.
12350         (iwmmxt_walignr0, iwmmxt_walignr1): Likewise.
12351         (iwmmxt_walignr2, iwmmxt_walignr3): Likewise.
12352         (iwmmxt_setwcgr0, iwmmxt_setwcgr1): Likewise.
12353         (iwmmxt_setwcgr2, iwmmxt_setwcgr3): Likewise.
12354         (iwmmxt_getwcgr0, iwmmxt_getwcgr1): Likewise.
12355         (iwmmxt_getwcgr2, iwmmxt_getwcgr3): Likewise.
12356         (All instruction patterns): Add wtype attribute.
12357         (*iwmmxt_arm_movdi, *iwmmxt_movsi_insn): iWMMXt coexist with vfp.
12358         (iwmmxt_uavgrndv8qi3, iwmmxt_uavgrndv4hi3): Revise the pattern.
12359         (iwmmxt_uavgv8qi3, iwmmxt_uavgv4hi3): Likewise.
12360         (ashr<mode>3_iwmmxt, ashl<mode>3_iwmmxt, lshr<mode>3_iwmmxt): Likewise.
12361         (iwmmxt_tinsrb, iwmmxt_tinsrh, iwmmxt_tinsrw):Likewise.
12362         (eqv8qi3, eqv4hi3, eqv2si3, gtuv8qi3): Likewise.
12363         (gtuv4hi3, gtuv2si3, gtv8qi3, gtv4hi3, gtv2si3): Likewise.
12364         (iwmmxt_wunpckihh, iwmmxt_wunpckihw, iwmmxt_wunpckilh): Likewise.
12365         (iwmmxt_wunpckilw, iwmmxt_wunpckehub, iwmmxt_wunpckehuh): Likewise.
12366         (iwmmxt_wunpckehuw, iwmmxt_wunpckehsb, iwmmxt_wunpckehsh): Likewise.
12367         (iwmmxt_wunpckehsw, iwmmxt_wunpckelub, iwmmxt_wunpckeluh): Likewise.
12368         (iwmmxt_wunpckeluw, iwmmxt_wunpckelsb, iwmmxt_wunpckelsh): Likewise.
12369         (iwmmxt_wunpckelsw, iwmmxt_wmadds, iwmmxt_wmaddu): Likewise.
12370         (iwmmxt_wsadb, iwmmxt_wsadh, iwmmxt_wsadbz, iwmmxt_wsadhz): Likewise.
12371         (iwmmxt2.md): Include.
12372         * config/arm/arm.h (TARGET_CPU_CPP_BUILTINS): Define __IWMMXT2__.
12373         (TARGET_IWMMXT2): New define.
12374         (TARGET_REALLY_IWMMXT2): Likewise.
12375         (arm_arch_iwmmxt2): Declare.
12376         * config/arm/mmintrin.h: Use __IWMMXT__ to enable iWMMXt intrinsics.
12377         Use __IWMMXT2__ to enable iWMMXt2 intrinsics.
12378         Use C name-mangling for intrinsics.
12379         (__v8qi): Redefine.
12380         (_mm_cvtsi32_si64, _mm_andnot_si64, _mm_sad_pu8): Revise.
12381         (_mm_sad_pu16, _mm_align_si64, _mm_setwcx, _mm_getwcx): Likewise.
12382         (_m_from_int): Likewise.
12383         (_mm_sada_pu8, _mm_sada_pu16): New intrinsic.
12384         (_mm_alignr0_si64, _mm_alignr1_si64, _mm_alignr2_si64): Likewise.
12385         (_mm_alignr3_si64, _mm_tandcb, _mm_tandch, _mm_tandcw): Likewise.
12386         (_mm_textrcb, _mm_textrch, _mm_textrcw, _mm_torcb): Likewise.
12387         (_mm_torch, _mm_torcw, _mm_tbcst_pi8, _mm_tbcst_pi16): Likewise.
12388         (_mm_tbcst_pi32): Likewise.
12389         (_mm_abs_pi8, _mm_abs_pi16, _mm_abs_pi32): New iWMMXt2 intrinsic.
12390         (_mm_addsubhx_pi16, _mm_absdiff_pu8, _mm_absdiff_pu16): Likewise.
12391         (_mm_absdiff_pu32, _mm_addc_pu16, _mm_addc_pu32): Likewise.
12392         (_mm_avg4_pu8, _mm_avg4r_pu8, _mm_maddx_pi16, _mm_maddx_pu16): Likewise.
12393         (_mm_msub_pi16, _mm_msub_pu16, _mm_mulhi_pi32): Likewise.
12394         (_mm_mulhi_pu32, _mm_mulhir_pi16, _mm_mulhir_pi32): Likewise.
12395         (_mm_mulhir_pu16, _mm_mulhir_pu32, _mm_mullo_pi32): Likewise.
12396         (_mm_qmulm_pi16, _mm_qmulm_pi32, _mm_qmulmr_pi16): Likewise.
12397         (_mm_qmulmr_pi32, _mm_subaddhx_pi16, _mm_addbhusl_pu8): Likewise.
12398         (_mm_addbhusm_pu8, _mm_qmiabb_pi32, _mm_qmiabbn_pi32): Likewise.
12399         (_mm_qmiabt_pi32, _mm_qmiabtn_pi32, _mm_qmiatb_pi32): Likewise.
12400         (_mm_qmiatbn_pi32, _mm_qmiatt_pi32, _mm_qmiattn_pi32): Likewise.
12401         (_mm_wmiabb_si64, _mm_wmiabbn_si64, _mm_wmiabt_si64): Likewise.
12402         (_mm_wmiabtn_si64, _mm_wmiatb_si64, _mm_wmiatbn_si64): Likewise.
12403         (_mm_wmiatt_si64, _mm_wmiattn_si64, _mm_wmiawbb_si64): Likewise.
12404         (_mm_wmiawbbn_si64, _mm_wmiawbt_si64, _mm_wmiawbtn_si64): Likewise.
12405         (_mm_wmiawtb_si64, _mm_wmiawtbn_si64, _mm_wmiawtt_si64): Likewise.
12406         (_mm_wmiawttn_si64, _mm_merge_si64): Likewise.
12407         (_mm_torvscb, _mm_torvsch, _mm_torvscw): Likewise.
12408         (_m_to_int): New define.
12409         * config/arm/arm-cores.def (iwmmxt2): Add FL_IWMMXT2.
12410         * config/arm/arm-arches.def (iwmmxt2): Likewise.
12411         * config/arm/t-arm (MD_INCLUDES): Add marvell-f-iwmmxt.md and
12412         iwmmxt2.md.
12413         * config/arm/arm.md (marvell-f-iwmmxt.md): Include.
12414         (arch): Add "iwmmxt2".
12415         (arch_enabled): Handle "iwmmxt2".
12416         (wtype): New attribute.
12417         (UNSPEC_WMADDS, UNSPEC_WMADDU): Delete.
12418         (UNSPEC_WALIGNI): New unspec.
12419         * config/arm/predicates.md (imm_or_reg_operand): New predicate.
12420         * config/arm/iterators.md (VMMX2): New mode_iterator.
12421         * config/arm/marvell-f-iwmmxt.md: New file.
12422         * config/arm/iwmmxt2.md: New file.
12423
12424 2012-06-12  Jakub Jelinek  <jakub@redhat.com>
12425
12426         PR c/53532
12427         PR c/51034
12428         PR c/53196
12429         * c-decl.c (build_compound_literal): Call c_incomplete_type_error
12430         if type isn't complete.
12431
12432 2012-06-12  Uros Bizjak  <ubizjak@gmail.com>
12433
12434         * config/ia64/sync.md (fetchop_name): Change ior attribute to "or".
12435
12436 2012-06-12  Richard Henderson  <rth@redhat.com>
12437
12438         * config/rs6000/sync.md (atomic_load, atomic_store): Use INT1 mode
12439         iterator instead of INT.
12440
12441 2012-06-12  Bill Schmidt  <wschmidt@linux.ibm.com>
12442
12443         * opts.c: Add -fhoist-adjacent-loads to -O2 and above.
12444         * tree-ssa-phiopt.c (tree_ssa_phiopt_worker): Add argument to forward
12445         declaration.
12446         (hoist_adjacent_loads, gate_hoist_loads): New forward declarations.
12447         (tree_ssa_phiopt): Call gate_hoist_loads.
12448         (tree_ssa_cs_elim): Add parm to tree_ssa_phiopt_worker call.
12449         (tree_ssa_phiopt_worker): Add do_hoist_loads to formal arg list; call
12450         hoist_adjacent_loads.
12451         (local_mem_dependence): New function.
12452         (hoist_adjacent_loads): Likewise.
12453         (gate_hoist_loads): Likewise.
12454         * common.opt (fhoist-adjacent-loads): New switch.
12455         * Makefile.in (tree-ssa-phiopt.o): Added dependencies.
12456
12457 2012-06-12  Michael Matz  <matz@suse.de>
12458
12459         * alias.c (nonoverlapping_component_refs_p): Take two rtx arguments.
12460         (nonoverlapping_memrefs_p): Don't call it here ...
12461         (true_dependence_1): ... but here.
12462
12463 2012-06-12  Richard Guenther  <rguenther@suse.de>
12464
12465         * emit-rtl.c (set_mem_attributes_minus_bitpos): Remove dead code.
12466         * alias.c (ao_ref_from_mem): MEM_EXPR is conservative, MEM_OFFSET
12467         and MEM_SIZE only refines it.  Reflect that and be less conservative
12468         if either of the latter is not known.
12469
12470 2012-06-12  Jakub Jelinek  <jakub@redhat.com>
12471
12472         PR rtl-optimization/53589
12473         * cfgrtl.c (force_nonfallthru_and_redirect): Do asm_goto_edge
12474         discovery even when e->dest != target.  If any LABEL_REF points
12475         to e->dest label, redirect it to target's label.
12476
12477 2012-06-12  Chung-Lin Tang  <cltang@codesourcery.com>
12478
12479         * config/sh/sh.c (output_stack_adjust): Remove !epilogue_p
12480         condition for generating REG_FRAME_RELATED_EXPR note.
12481         (pop): Add code for generating REG_CFA_RESTORE,
12482         REG_CFA_ADJUST_CFA notes. Set RTX_FRAME_RELATED_P to 1.
12483         (sh_expand_epilogue): Use frame_insn() for FP to SP move.
12484         Set 'frame_p' of calls to output_stack_adjust() to 'true'.
12485
12486 2012-06-11  Richard Henderson  <rth@redhat.com>
12487
12488         * config/alpha/alpha.c (HWI_HEX2): Add missing shift.
12489         * vmsdbgout.c (VMS_EPOCH_OFFSET): Add LL suffix.
12490
12491         * config/alpha/alpha.c (alpha_trampoline_init): Split large constants.
12492
12493 2012-06-12  Hans-Peter Nilsson  <hp@axis.com>
12494
12495         * doc/tm.texi.in (Addressing Modes) <TARGET_LEGITIMIZE_ADDRESS>:
12496         Mention that this hook needs to be defined for native TLS.
12497         * doc/tm.texi: Regenerate.
12498
12499 2012-06-11  Mike Stump  <mikestump@comcast.net>
12500
12501         * emit-rtl.c (init_emit_once): Iterate through the
12502         MODE_PARTIAL_INT modes with MIN_MODE_PARTIAL_INT and
12503         MAX_MODE_PARTIAL_INT, as GET_MODE_WIDER_MODE doesn't step through
12504         all the MIN_MODE_PARTIAL_INT modes anymore.
12505
12506 2012-06-12  Maxim Kuvyrkov  <maxim@codesourcery.com>
12507
12508         * gcc/config/mips/mips-tables.opt (xlp): Fix merge typo.
12509
12510 2012-06-11  Roland McGrath  <mcgrathr@google.com>
12511
12512         * dwarf2out.c (const_ok_for_output_1): Detect a TLS UNSPEC using
12513         SYMBOL_REF_TLS_MODEL rather than DECL_THREAD_LOCAL_P, in case it's
12514         not a VAR_DECL.  Also don't limit it to UNSPECs with exactly one
12515         operand.
12516
12517 2012-06-11  Oleg Endo  <olegendo@gcc.gnu.org>
12518
12519         PR target/53511
12520         * config/sh/sh.md (fmasf4): New expander.
12521         (*macsf3): Rename to fmasf4_i.  Adapt to fma pattern.
12522         (mac_media): Rename to fmasf4_media.  Adapt to fma pattern.
12523         * config/sh/sh.opt (mfused-madd): Remove.
12524         * config/sh/sh.c (sh_option_override): Remove mfused-madd handling.
12525         (builtin_description bdesc): Remove __builtin_sh_media_FMAC_S.
12526         * config.gcc (sh[123456789lbe]*-*-* | sh-*-*): Add fused-madd.opt
12527         as extra options.
12528         * doc/invoke.texi (SH Options): Update mfused-madd and mno-fused-madd
12529         descriptions.
12530
12531 2012-06-11  Richard Henderson  <rth@redhat.com>
12532
12533         * dwarf2cfi.c (scan_trace): Handle annulled branch-taken delay slots.
12534
12535 2012-06-11  Richard Guenther  <rguenther@suse.de>
12536
12537         PR middle-end/53470
12538         * tree.c (free_lang_data_in_type): Do not clear TYPE_CONTEXT but
12539         replace it with the first non-BLOCK context.
12540
12541 2012-06-11  Richard Guenther  <rguenther@suse.de>
12542
12543         * alias.c (aliases_everything_p): Remove.
12544         (DIFFERENT_ALIAS_SETS_P): Likewise.
12545         (true_dependence_1): Use mems_in_disjoint_alias_sets_p directly.
12546         Do not use aliases_everything_p or special-case ANDs.  Do not
12547         special-case BLKmode moves.
12548         (may_alias_p): Likewise.  Handle BLKmode similar like everywhere
12549         - for SCATCH only.
12550
12551 2012-06-09  Hans-Peter Nilsson  <hp@axis.com>
12552
12553         Fix CRIS build errors with --enable-build-with-cxx.
12554         * config/cris/cris.c (cris_emit_trap_for_misalignment): Rename
12555         variable "and" to "andop".
12556         * config/cris/sync.md ("atomic_fetch_<atomic_op_name><mode>"): Use
12557         temporary variable for memory model, passing C++-type-correct
12558         parameter type to expand_mem_thread_fence.
12559         ("atomic_compare_and_swap<mode>"): Ditto.
12560
12561 2012-06-09  Richard Henderson  <rth@redhat.com>
12562
12563         PR c++/53602
12564         * cfgcleanup.c (execute_jump): Rename from rest_of_handle_jump2.
12565         (pass_jump): Rename from pass_jump2.
12566         (execute_jump2, pass_jump2): New.
12567         * combine-stack-adj.c (rest_of_handle_stack_adjustments): Don't
12568         perform cfg cleanup here.  Move the test of PUSH_ROUNDING
12569         and ACCUMULATE_OUTGOING_ARGS test...
12570         (gate_handle_stack_adjustments): ... here.
12571         * passes.c (init_optimization_passes): Update for pass_jump2 rename.
12572         Place new pass_jump2 after pass_stack_adjustments.
12573         * tree-pass.h (pass_jump): Declare.
12574
12575 2012-06-09  Kenneth Zadeck <zadeck@naturalbridge.com>
12576
12577         * simplify-rtx.c (simplify_const_binary_operation): Fixed shift
12578         count trucation.
12579
12580 2012-06-08  Richard Henderson  <rth@redhat.com>
12581
12582         PR c++/53602
12583         * combine-stack-adj.c (force_move_args_size_note): Add ARGS_SIZE
12584         note to a clobber insn when no other insn is available.
12585
12586 2012-06-08  Georg-Johann Lay  <avr@gjlay.de>
12587
12588         * config/avr/avr.c (avr_case_values_threshold): Return 7.
12589
12590 2012-06-07  Andreas Schwab  <schwab@linux-m68k.org>
12591
12592         * genhooks.c (main): Set progname.
12593         (emit_documentation): Remove variable found_start, always bail out
12594         when a place is missing.
12595         * doc/tm.texi.in (C++ ABI): Add @hook TARGET_CXX_DECL_MANGLING_CONTEXT.
12596
12597 2012-06-07  Jakub Jelinek  <jakub@redhat.com>
12598
12599         PR middle-end/53580
12600         * omp-low.c (scan_omp): Change first argument to gimple_seq *,
12601         call walk_gimple_seq_mod instead of walk_gimple_seq.
12602         (scan_sharing_clauses, scan_omp_parallel, scan_omp_task,
12603         scan_omp_for, scan_omp_sections, scan_omp_single,
12604         execute_lower_omp): Adjust callers.
12605         (scan_omp_1_stmt): Likewise.  If check_omp_nesting_restrictions
12606         returns false, replace stmt with GIMPLE_NOP.
12607         (check_omp_nesting_restrictions): Instead of issuing warnings,
12608         issue errors and return false if any errors were reported.
12609
12610 2012-06-06  Steven Bosscher  <steven@gcc.gnu.org>
12611
12612         * doc/invoke.texi (fconserve-space): Remove documentation.
12613
12614 2012-06-06  Edmar Wienskoski  <edmar@freescale.com>
12615
12616         * config/rs6000/rs6000-tables.opt: Regenerated.
12617
12618 2012-06-06  Richard Guenther  <rguenther@suse.de>
12619
12620         PR tree-optimization/53081
12621         * tree-data-ref.h (adjacent_store_dr_p): Rename to ...
12622         (adjacent_dr_p): ... this and make it work for reads, too.
12623         * tree-loop-distribution.c (enum partition_kind): Add PKIND_MEMCPY.
12624         (struct partition_s): Change main_stmt to main_dr, add
12625         secondary_dr member.
12626         (build_size_arg_loc): Change to date data-reference and not
12627         gimplify here.
12628         (build_addr_arg_loc): New function split out from ...
12629         (generate_memset_builtin): ... here.  Use it and simplify.
12630         (generate_memcpy_builtin): New function.
12631         (generate_code_for_partition): Adjust.
12632         (classify_partition): Streamline pattern detection.  Detect memcpy.
12633         (ldist_gen): Adjust.
12634         (tree_loop_distribution): Adjust seed statements for memcpy
12635         recognition.
12636
12637 2012-06-06  Matt Turner  <mattst88@gmail.com>
12638
12639         * config/arm/mmintrin.h (_mm_empty): New.
12640         (_m_empty): New.
12641
12642 2012-06-06  Richard Sandiford  <r.sandiford@uk.ibm.com>
12643
12644         * doc/invoke.texi (sched-pressure-algorithm): Document new --param.
12645         * common.opt (fsched-pressure-algorithm=): Remove.
12646         * flag-types.h (sched_pressure_algorithm): Move to...
12647         * sched-int.h (sched_pressure_algorithm): ...here.
12648         * params.def (sched-pressure-algorithm): New param.
12649         * haifa-sched.c (sched_init): Use it to initialize sched_pressure.
12650         * common/config/s390/s390-common.c (s390_option_optimization_table):
12651         Remove OPT_fsched_pressure_algorithm_ entry.
12652         * config/s390/s390.c (s390_option_override): Set a default value for
12653         PARAM_SCHED_PRESSURE_ALGORITHM.
12654
12655 2012-06-05  Michael Meissner  <meissner@linux.vnet.ibm.com>
12656
12657         PR target/53487
12658         * config/rs6000/rs6000.c (rs6000_generate_compare): If we are
12659         doing an unsigned compare, make sure the second argument is not a
12660         negative constant.
12661         (rs6000_emit_cmove): Don't allow floating point comparisons when
12662         generating ISEL moves.
12663
12664 2012-06-05  Edmar Wienskoski  <edmar@freescale.com>
12665
12666         * config/rs6000/e5500.md: New file.
12667         * config/rs6000/e6500.md: New file.
12668         * config/rs6000/rs6000.c (processor_costs): Add new costs for
12669         e5500 and e6500.
12670         (rs6000_option_override_internal): Altivec and Spe options not
12671         allowed with e5500. Spe options not allowed with e6500. Increase
12672         move inline limit for e5500 and e6500. Disable string instructions
12673         for e5500 and e6500. Enable branch targets alignment for e5500 and
12674         e6500. Initialize rs6000_cost for e5500 and e6500.
12675         (rs6000_adjust_cost): Add extra scheduling cycles between compare
12676         and brnach for e5500 and e6500.
12677         (rs6000_issue_rate): Set issue rate for e5500 and e6500.
12678         * config/rs6000/rs6000-cpus.def: Add cpu definitions for e5500 and
12679         e6500.
12680         * config/rs6000/rs6000.h (ASM_CPU_SPEC): Add e5500 and e6500.
12681         * config/rs6000/rs6000.md (define_attr "cpu"): Add ppce5500 and
12682         ppce6500.
12683         Include e5500.md and e6500.md.
12684         * config/rs6000/rs6000-opt.h (processor_type): Add
12685         PROCESSOR_PPCE5500 and PROCESSOR_PPCE6500.
12686         * config.gcc (cpu_is_64bit): Add new cores e5500, e6500.
12687         (powerpc*-*-*): Add new cores e5500, e6500.
12688         * doc/invoke.texi: (item -mcpu): Add e5500 and e6500 to list of cpus.
12689
12690 2012-06-05  Richard Guenther  <rguenther@suse.de>
12691
12692         * tree-vect-data-refs.c (vect_analyze_data_refs): Fix last change.
12693
12694 2012-06-05  H.J. Lu  <hongjiu.lu@intel.com>
12695
12696         PR target/53575
12697         * config.gcc: Select x32 run-time library if --with-abi={x32|mx32}
12698         is used for x86_64-*-*.
12699
12700 2012-06-05  Richard Guenther  <rguenther@suse.de>
12701
12702         PR tree-optimization/30442
12703         * tree-vect-data-refs.c (vect_analyze_data_refs): For basic-block
12704         vectorization stop analysis at the first stmt we cannot compute
12705         a data-reference for instead of giving up completely.
12706
12707 2012-06-05  Richard Guenther  <rguenther@suse.de>
12708
12709         * tree-loop-distribution.c (struct partition_s): Add has_writes member.
12710         (partition_alloc): Initialize it.
12711         (partition_has_writes): New function.
12712         (rdg_flag_uses): Adjust.
12713         (rdg_flag_vertex): Likewise.
12714         (rdg_flag_vertex_and_dependent): Likewise.
12715         (rdg_flag_loop_exits): Likewise.
12716         (build_rdg_partition_for_component): Likewise.
12717         (rdg_build_partitions): Likewise.
12718
12719 2012-06-05  Richard Guenther  <rguenther@suse.de>
12720
12721         PR tree-optimization/53081
12722         * tree-loop-distribution.c (generate_memset_builtin): Handle all
12723         kinds of byte-sized stores.
12724         (classify_partition): Likewise.
12725         (tree_loop_distribution): Adjust seed statements used for
12726         !flag_tree_loop_distribution.
12727
12728 2012-06-05  Alan Modra  <amodra@gmail.com>
12729
12730         * config/rs6000/rs6000.c (ptr_regno_for_savres): Comment.
12731         (rs6000_emit_prologue): Ensure register used for inline saves
12732         of vector regs is not the static chain register.  Revise comment.
12733
12734 2012-06-04  Oleg Endo  <olegendo@gcc.gnu.org>
12735
12736         * doc/md.texi (Standard Pattern Names For Generation): Document
12737         sincos pattern.
12738
12739 2012-06-04  H.J. Lu  <hongjiu.lu@intel.com>
12740
12741         PR bootstrap/53555
12742         * config/i386/i386.c (ix86_sched_reorder) Skip debug insns.
12743
12744 2012-06-04  Jason Merrill  <jason@redhat.com>
12745
12746         * dwarf2out.c (is_unit_die): New.
12747         (copy_declaration_context, copy_ancestor_tree): Use it.
12748         (copy_decls_walk): Likewise.
12749
12750 2012-06-04  Paolo Carlini  <paolo.carlini@oracle.com>
12751
12752         PR c++/53524
12753         * doc/invoke.texi (Wenum-compare): Update documentation.
12754
12755 2012-06-04  Dodji Seketeli  <dodji@redhat.com>
12756
12757         PR preprocessor/53463
12758         * parser.c (cp_parser_assignment_expression): Use the location
12759         for the '=' as the default location for the expression.
12760
12761 2012-06-04  Edmar Wienskoski  <edmar@freescale.com>
12762
12763         PR target/53559
12764         * config/rs6000/altivec.md (altivec_stvlx): Change machine mode of
12765         operands.
12766         (altivec_stvlxl): Ditto.
12767         (altivec_stvrx): Ditto.
12768         (altivec_stvrxl): Ditto.
12769
12770 2012-06-04  Vladimir Makarov  <vmakarov@redhat.com>
12771
12772         * ira-int.h (struct target_ira_int): Add member x_ira_uniform_class_p.
12773         (ira_uniform_class_p): New macro.
12774
12775         * ira.c (setup_uniform_class_p): New function.
12776         (setup_allocno_and_important_classes): Call the function.
12777         (print_unform_and_important_classes): New function.
12778         (print_classes): Rename to print_translated_classes.
12779         (ira_debug_allocno_classes): Add call of
12780         print_unform_and_important_classes.
12781
12782         * ira-costs.c (setup_regno_cost_classes_by_aclass): Use uniform
12783         classes instead of pressure classes.
12784
12785 2012-06-04  Aldy Hernandez  <aldyh@redhat.com>
12786
12787         PR middle-end/47530
12788         * trans-mem.c (expand_block_edges): Do not skip the first
12789         statement when resetting the BB.
12790
12791 2012-06-04  Richard Guenther  <rguenther@suse.de>
12792
12793         * tree-data-ref.c (stores_from_loop): Remove.
12794         (stmt_with_adjacent_zero_store_dr_p): Likewise.
12795         (stores_zero_from_loop): Likewise.
12796         * tree-data-ref.h (stores_from_loop, stores_zero_from_loop,
12797         stmt_with_adjacent_zero_store_dr_p, stride_of_unit_type_p): Remove.
12798         (adjacent_store_dr_p): New function.
12799         * tree-loop-distribution.c (generate_memset_builtin): Pass
12800         the RDG, use the already available data-reference.
12801         (generate_code_for_partition): Pass down RDG.
12802         (classify_partition): Inline parts of the former
12803         stmt_with_adjacent_zero_store_dr_p here and use adjacent_store_dr_p.
12804         (ldist_gen): Remember if there was any detected builtin and
12805         do less work if not and flag_tree_loop_distribution is not set.
12806         (tree_loop_distribution): Inline and fuse stores_from_loop
12807         and stores_zero_from_loop here.
12808
12809 2012-06-04  Richard Guenther  <rguenther@suse.de>
12810
12811         PR middle-end/53471
12812         * dwarf2out.c (dwarf2out_finish): If generating LTO do not
12813         create new assembler names.
12814
12815 2012-06-04  Richard Guenther  <rguenther@suse.de>
12816
12817         * tree-data-ref.c (struct rdg_vertex_info): Remove.
12818         (rdg_vertex_for_stmt): Simplify using gimple_uid.
12819         (create_rdg_vertices): Pass loop argument, remove stmt to RDG index
12820         hashtable.  Record stmt data-references.
12821         (hash_stmt_vertex_info): Remove.
12822         (eq_stmt_vertex_info): Likewise.
12823         (hash_stmt_vertex_del): Likewise.
12824         (build_empty_rdg): Simplify.
12825         (build_rdg): Adjust.
12826         (free_rdg): Likewise.
12827         (ref_base_address): Remove.
12828         (have_similar_memory_accesses): Likewise.
12829         * tree-data-ref.h (create_rdg_vertices): Remove.
12830         (struct rdg_vertex): Add datarefs member.
12831         (RDGV_DATAREFS): New define.
12832         (RDG_DATAREFS): Likewise.
12833         (have_similar_memory_accesses): Remove.
12834         (rdg_has_similar_memory_accesses): Likewise.
12835         * tree-loop-distribution.c (ref_base_address): Re-implement here.
12836         (similar_memory_accesses): Re-implement using existing data-references.
12837         (tree_loop_distribution): Initialize stmt uids for the stmt to
12838         RDG index mapping.
12839         * tree-vect-loop.c (vect_create_epilog_for_reduction): Only
12840         access stmt vinfo for stmts in loop.
12841
12842 2012-06-04  Andreas Schwab  <schwab@linux-m68k.org>
12843
12844         PR target/53461
12845         * config/m68k/m68k.md ("tablejump"): Fix check for
12846         CASE_VECTOR_PC_RELATIVE.
12847
12848 2012-06-04  Steven Bosscher  <steven@gcc.gnu.org>
12849
12850         * output.h (merge_weak, assemble_alias,
12851         initializer_constant_valid_p,
12852         initializer_constant_valid_for_bitfield_p): Move protos from here...
12853         * tree.h: ... to here.
12854         * cgraphclones.c: Do not include output.h.
12855         * gimplify.c: Likewise.
12856         * reload.c: Likewise.
12857         * recog.c: Likewise.
12858         * tree-ssa-loop-ivopts.c: Likewise.
12859         * tree-switch-conversion.c: Likewise.
12860         * c-parser.c: Likewise.
12861         * c-typeck.c: Likewise.
12862         * Makefile.in: Fix dependencies.
12863
12864 2012-06-04  Georg-Johann Lay  <avr@gjlay.de>
12865
12866         PR target/46261
12867         * config/avr/avr-stdint.h: New file.
12868         * config.gcc (avr-*-*,tm_file): Use avr/avr-stdint.h instead of
12869         newlib-stdint.h
12870
12871 2012-06-04  Jakub Jelinek  <jakub@redhat.com>
12872
12873         PR tree-optimization/53550
12874         * tree-ssa-loop-niter.c (number_of_iterations_cond): If type
12875         is POINTER_TYPE_P, use sizetype as step type instead of type.
12876
12877 2012-06-04  Richard Guenther  <rguenther@suse.de>
12878
12879         * tree-data-ref.c (have_similar_memory_accesses_1): Remove.
12880         (ref_base_address_1): Likewise.
12881         (remove_similar_memory_refs): Likewise.
12882         * tree-data-ref.h (remove_similar_memory_refs): Remove.
12883         * tree-loop-distribution.c (classify_partition): Do not classify
12884         as builtin if -ftree-loop-distribute-patterns is not enabled.
12885         (fuse_partitions_with_similar_memory_accesses): Inline ...
12886         (ldist_gen): ... here.  Fuse all non-builtin partitions if
12887         -ftree-loop-distribution is not enabled.  Properly return
12888         the number of created partitions.  Do not update SSA form here but ...
12889         (tree_loop_distribution): ... once here for the whole function.
12890         Only walk innermost loops, constrain loops we consider here
12891         further.  Do not call remove_similar_memory_refs.
12892         (distribute_loop): Do not check number of loop nodes here.
12893
12894 2012-06-04  Steven Bosscher  <steven@gcc.gnu.org>
12895
12896         * Makefile.in (GIMPLE_H): Do not depend on TARGET_H.
12897
12898 2012-06-03  Martin Jambor  <mjambor@suse.cz>
12899
12900         * ipa-prop.h (ipa_get_jf_known_type_offset): New function.
12901         (ipa_get_jf_known_type_base_type): Likewise.
12902         (ipa_get_jf_known_type_component_type): Likewise.
12903         (ipa_get_jf_constant): Likewise.
12904         (ipa_get_jf_pass_through_formal_id): Likewise.
12905         (ipa_get_jf_pass_through_operation): Likewise.
12906         (ipa_get_jf_ancestor_offset): Likewise.
12907         (ipa_get_jf_ancestor_type): Likewise.
12908         (ipa_get_jf_ancestor_formal_id): Likewise.
12909         (ipa_get_jf_member_ptr_pfn): Likewise.
12910         * ipa-prop.c (ipa_set_jf_known_type): New function.
12911         (ipa_set_jf_constant): Likewise.
12912         (ipa_set_jf_simple_pass_through): Likewise.
12913         (ipa_set_jf_arith_pass_through): Likewise.
12914         (ipa_set_ancestor_jf): Likewise.
12915         (fill_member_ptr_cst_jump_function): Moved up and renamed to
12916         ipa_set_jf_member_ptr_cst.
12917         (detect_type_change_1): Use the new jump function creation functions.
12918         (compute_complex_assign_jump_func): Likewise.
12919         (compute_complex_ancestor_jump_func): Likewise.
12920         (compute_known_type_jump_func): Likewise.
12921         (compute_scalar_jump_functions): Likewise.
12922         (compute_pass_through_member_ptrs): Likewise.
12923         (determine_cst_member_ptr): Likewise.
12924         (combine_known_type_and_ancestor_jfs): Likewise.
12925         (try_make_edge_direct_simple_call): Likewise.
12926         (try_make_edge_direct_virtual_call): Likewise.
12927         (update_indirect_edges_after_inlining): Likewise.
12928         * ipa-cp.c (ipa_get_jf_pass_through_result): Use jump function
12929         access functions.  Incorporat NOP_EXPR and BINFO handling from its
12930         callers.
12931         (ipa_get_jf_ancestor_result): Likewise.  Incorporate handling BINFOs
12932         which was in its callers.
12933         (ipa_value_from_jfunc): Use jump function access functions.  Some
12934         functionality moved to functions above.
12935         (propagate_vals_accross_ancestor): Likewise.
12936         (propagate_vals_accross_pass_through): Use jump function access
12937         functions.
12938         (propagate_accross_jump_function): Likewise.
12939         * ipa-inline-analysis.c (remap_edge_change_prob): Use jump function
12940         access functions.
12941         (inline_merge_summary): Likewise.
12942
12943 2012-06-03  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
12944
12945         * config/pa/pa.h (MAX_PCREL17F_OFFSET): Define.
12946         * config/pa/pa.c (pa_attr_length_millicode_call): Use
12947         MAX_PCREL17F_OFFSET instead of fixed offset.
12948         (pa_attr_length_call): Likewise.
12949         (pa_attr_length_indirect_call): Likewise.
12950
12951 2012-06-03  Oleg Endo  <olegendo@gcc.gnu.org>
12952
12953         PR target/53512
12954         * config/sh/sh.opt (mfsca, mfsrra): New options.
12955         * config/sh/sh.md (rsqrtsf2): Use TARGET_FPU_ANY and TARGET_FSRRA
12956         condition.
12957         (fsca): Use TARGET_FPU_ANY and TARGET_FSCA condition.
12958         (sinssf2, cossf2): Fold expanders to ...
12959         (sincossf3): ... this new expander.  Use TARGET_FPU_ANY and
12960         TARGET_FSCA condition.
12961         * config/sh/sh.c (sh_option_override): Handle TARGET_FSRRA and
12962         TARGET_FSCA.
12963         * doc/invoke.texi (SH Options): Add descriptions for -mfsca,
12964         -mno-fsca, -mfsrra, -mno-fsrra.
12965
12966 2012-06-03  Matt Turner  <mattst88@gmail.com>
12967
12968         * config/mips/4600.md (r4700_imul_si): New.
12969         (r4700_imul_di): New.
12970         (r4700_fmul_single): New.
12971         (r4700_fmul_double): New.
12972         * config/mips/mips-cpus.def: Add r4700.
12973         * config/mips/mips.c: Likewise.
12974         * config/mips/mips.md: Likewise.
12975         * config/mips/mips-tables.opt: Regenerate.
12976
12977 2012-06-02  Steven Bosscher  <steven@gcc.gnu.org>
12978
12979         * config/sparc/sparc.h (INITIAL_ELIMINATION_OFFSET): Split out to
12980         new function sparc_initial_elimination_offset.
12981         * config/sparc/sparc.c (sparc_initial_elimination_offset): New
12982         function.
12983         * config/sparc/sparc-protos.h (sparc_initial_elimination_offset):
12984         Prototype it.
12985
12986 2012-06-02  Kenneth Zadeck <zadeck@naturalbridge.com>
12987
12988         * expmed.c (expand_mult, choose_multiplier): Change
12989         "2 * HOST_BITS_PER_WIDE_INT" to "HOST_BITS_PER_DOUBLE_INT".
12990         * expr.c (convert_modes): Likewise.
12991         * explow.c (plus_constant): Likewise.
12992         * fixed-value.c (fixed_saturate1, fixed_saturate2)
12993         (do_fixed_add, do_fixed_multiply, do_fixed_multiply)
12994         (do_fixed_multiply, do_fixed_multiply, do_fixed_divide)
12995         (do_fixed_divide, do_fixed_divide, do_fixed_divide)
12996         (do_fixed_divide, do_fixed_divide, do_fixed_shift, do_fixed_shift)
12997         (do_fixed_shift, fixed_convert, fixed_convert)
12998         (fixed_convert_from_int, fixed_convert_from_int)
12999         (fixed_convert_from_real): Likewise.
13000         * fold-const.c (fold_convert_const_int_from_fixed, sign_bit_p)
13001         (native_interpret_int, fold_binary_loc, fold_ternary_loc): Likewise.
13002         * varasm.c (output_constructor_bitfield): Likewise.
13003         * tree-vrp.c (register_edge_assert_for_2): Likewise.
13004         * double-int.c (rshift_double, lshift_double): Likewise.
13005         * double-int.h (double_int_fits_in_uhwi_p, double_int, double_int):
13006         Likewise.
13007         * simplify-rtx.c (mode_signbit_p)
13008         (simplify_const_unary_operation, simplify_binary_operation_1)
13009         (simplify_immed_subreg): Likewise.
13010         * builtins.c (c_readstr, fold_builtin_bitop): Likewise.
13011         * tree-vect-generic.c (build_replicated_const): Likewise.
13012         * dbxout.c (stabstr_O): Likewise.
13013         * emit-rtl.c (immed_double_int_const, immed_double_const)
13014         (gen_lowpart_common, init_emit_once): Likewise.
13015         * tree.c (integer_pow2p, tree_log2, tree_floor_log2)
13016         (widest_int_cst_value, upper_bound_in_type): Likewise.
13017         * stor-layout.c (initialize_sizetypes, fixup_signed_type)
13018         (fixup_unsigned_type): Likewise.
13019         * real.c (real_to_integer2, real_from_integer): Likewise.
13020         * dwarf2out.c (size_of_loc_descr, size_of_die, output_die)
13021         (clz_loc_descriptor, mem_loc_descriptor): Likewise.
13022
13023 2012-06-01  Eric Botcazou  <ebotcazou@adacore.com>
13024
13025         PR middle-end/53501
13026         * fold-const.c (fold_binary_loc): Refine previous change.
13027
13028 2012-06-01  Olivier Hainque  <hainque@adacore.com>
13029
13030         * config/rs6000/vxworks.h (SUBSUBTARGET_OVERRIDE_OPTIONS): Restore
13031         the "do {" part of the do-while(0) loop.
13032
13033 2012-06-01  Yuri Rumyantsev  <yuri.s.rumyantsev@intel.com>
13034
13035         * config/i386/i386.c (x86_sched_reorder): New function.
13036         Added new function x86_sched_reorder.
13037
13038 2012-06-01  Richard Guenther  <rguenther@suse.de>
13039
13040         * tree-loop-distribution.c (stmt_has_scalar_dependences_outside_loop):
13041         Handle PHIs.
13042         (classify_partition): Likewise.
13043
13044 2012-06-01  Richard Guenther  <rguenther@suse.de>
13045
13046         * tree-loop-distribution.c (enum partition_kind): New enum.
13047         (struct partition_s): Add kind and main_stmt members.
13048         (partition_alloc): Initialize kind to PKIND_NORMAL.
13049         (partition_builtin_p): New function.
13050         (copy_loop_before): Remove failure path and assert instead.
13051         (generate_loops_for_partition): Likewise.
13052         (generate_memset_zero): Fold into ...
13053         (generate_memset_builtin): ... this.
13054         (classify_partition): New function with code from
13055         can_generate_builtin and generate_builtin.
13056         (generate_builtin): Remove.
13057         (can_generate_builtin): Likewise.
13058         (fuse_partitions_with_similar_memory_accesses): Call
13059         partition_builtin_p instead of can_generate_builtin.
13060         (rdg_build_partitions): Do not call
13061         fuse_partitions_with_similar_memory_accesses here...
13062         (ldist_gen): ... but here after classifying all partitions.
13063         Remove failure path of generate_code_for_partition.
13064         (generate_code_for_partition): Generate code according
13065         to partition classification.
13066
13067 2012-06-01  Manuel López-Ibáñez  <manu@gcc.gnu.org>
13068             Jonathan Wakely  <jwakely.gcc@gmail.com>
13069
13070         PR c++/50134
13071         * doc/invoke.texi (Warning Options): Explain purpose and differences
13072         between -Wmissing-prototypes and -Wmissing-declarations.
13073
13074 2012-06-01  Christian Bruel  <christian.bruel@st.com>
13075
13076         * gcc.c (save_switch): Add user_p parameter.
13077         (read_specs): Likewise.
13078         (set_specs): Likewise.
13079         (validate_switches): Likewise.
13080         (validate_switches_from_spec): Likewise.
13081         (validate_all_switches): Pass on user_p parameter.
13082         (struct spec_list): Add user_p field.
13083         (struct switchstr): Add known field.
13084         (save_switch): Add known parameter.
13085         (INIT_STATIC_SPEC): Initialize user_p;
13086         (driver_unknown_option_callbac): call save_switch if
13087         OPT_SPECIAL_unknown.
13088         (driver_handle_option): Propagate OPT_specs.
13089         (do_spec_1): Set validated only if known.
13090         (check_live_switch): Likewise.
13091         (validate_switches): Set validated if known or user_spec.
13092
13093 2012-06-01  Hans-Peter Nilsson  <hp@axis.com>
13094
13095         Add CRIS atomic patterns for 1, 2, and 4 bytes.
13096         * config/cris/cris.c (cris_emit_trap_for_misalignment): New function.
13097         * config/cris/cris-protos.h: Declare it.
13098         * config/cris/cris.h [!TARGET_DEFAULT, TARGET_CPU_DEFAULT == 32]
13099         (TARGET_DEFAULT): Add alignment by 32.
13100         [!TARGET_DEFAULT, TARGET_CPU_DEFAULT == 10] (TARGET_DEFAULT): New
13101         case, as TARGET_CPU_DEFAULT == 0 but with alignment as for
13102         TARGET_CPU_DEFAULT == 32.
13103         (TARGET_TRAP_UNALIGNED_ATOMIC): New macro.
13104         * config/cris/cris.md: Include sync.md.  Avoid allocating specific
13105         numbers by replacing the define_constants for all UNSPECs with the
13106         equivalent define_c_enum construct.
13107         * config/cris/cris.opt (mtrap-unaligned-atomic): New option.
13108         * config/cris/sync.md: New file.
13109
13110 2012-05-31  Matt Turner  <mattst88@gmail.com>
13111
13112         * config/mips/4600.md (r4600_imul_si): Rename from r4600_imul.
13113         (r4600_imul_di): New.
13114         (r4600_idiv_si): Rename from r4600_idiv.
13115         (r4600_idiv_di): New.
13116
13117 2012-05-31  Steven Bosscher  <steven@gcc.gnu.org>
13118
13119         * output.h (__gcc_host_wide_int__): Move to hwint.h.
13120         (decl_default_tls_model): Move to tree.h
13121         (dump_file): Move to system.h.
13122         (default_stabs_asm_out_destructor, default_stabs_asm_out_constructor,
13123         dbxout_int, dbxout_stabd, dbxout_begin_stabn, dbxout_begin_stabn_sline,
13124         dbxout_begin_empty_stabs, dbxout_begin_simple_stabs,
13125         dbxout_begin_simple_stabs_desc, dbxout_stab_value_zero,
13126         dbxout_stab_value_zero, dbxout_stab_value_label_diff,
13127         dbxout_stab_value_internal_label,
13128         dbxout_stab_value_internal_label_diff): Move from here ...
13129         * dbxout.h: ... to here.
13130         * system.h (dump_file): Moved here from output.h.
13131         * hwint.h (__gcc_host_wide_int__): Moved here from output.h.
13132         * tree.h (decl_default_tls_model): Moved here from output.h.
13133         * varasm.c (default_stabs_asm_out_destructor,
13134         default_stabs_asm_out_constructor): Move from here ...
13135         * dbxout.c: ... to here.
13136
13137         * gcov-dump.c (dump_file): Rename to dump_gcov_file.  Update callers.
13138
13139         * collect2.h (dump_file): Rename to dump_ld_file.
13140         * collect2.c: Likewise.
13141         * tlink.c: Likewise.
13142
13143         * alias.c: Do not include output.h.
13144         * auto-inc-dec.c: Likewise.
13145         * bt-load.c: Likewise.
13146         * caller-save.c: Likewise.
13147         * cfg.c: Likewise.
13148         * cfgbuild.c: Likewise.
13149         * cfgcleanup.c: Likewise.
13150         * cfglayout.c: Likewise.
13151         * cfgloop.c: Likewise.
13152         * cfgloopanal.c: Likewise.
13153         * cfgloopmanip.c: Likewise.
13154         * cfgrtl.c: Likewise.
13155         * cgraph.c: Likewise.
13156         * cgraphclones.c: Likewise.
13157         * combine-stack-adj.c: Likewise.
13158         * combine.c: Likewise.
13159         * cprop.c: Likewise.
13160         * cse.c: Likewise.
13161         * cselib.c: Likewise.
13162         * dbgcnt.c: Likewise.
13163         * df-problems.c: Likewise.
13164         * df-scan.c: Likewise.
13165         * dojump.c: Likewise.
13166         * fwprop.c: Likewise.
13167         * gcse.c: Likewise.
13168         * graph.c: Likewise.
13169         * haifa-sched.c: Likewise.
13170         * hw-doloop.c: Likewise.
13171         * ipa-inline-transform.c: Likewise.
13172         * ipa-pure-const.c: Likewise.
13173         * ipa-reference.c: Likewise.
13174         * ipa-utils.c: Likewise.
13175         * ira-build.c: Likewise.
13176         * ira-emit.c: Likewise.
13177         * lcm.c: Likewise.
13178         * loop-doloop.c: Likewise.
13179         * loop-invariant.c: Likewise.
13180         * loop-iv.c: Likewise.
13181         * loop-unroll.c: Likewise.
13182         * loop-unswitch.c: Likewise.
13183         * lto-cgraph.c: Likewise.
13184         * lto-section-in.c: Likewise.
13185         * lto-streamer-in.c: Likewise.
13186         * mcf.c: Likewise.
13187         * mode-switching.c: Likewise.
13188         * postreload-gcse.c: Likewise.
13189         * postreload.c: Likewise.
13190         * predict.c: Likewise.
13191         * profile.c: Likewise.
13192         * ree.c: Likewise.
13193         * reg-stack.c: Likewise.
13194         * regcprop.c: Likewise.
13195         * regmove.c: Likewise.
13196         * regstat.c: Likewise.
13197         * reload1.c: Likewise.
13198         * sched-ebb.c: Likewise.
13199         * sel-sched-dump.c: Likewise.
13200         * simplify-rtx.c: Likewise.
13201         * stor-layout.c: Likewise.
13202         * store-motion.c: Likewise.
13203         * tracer.c: Likewise.
13204         * tree-affine.c: Likewise.
13205         * tree-cfg.c: Likewise.
13206         * tree-cfgcleanup.c: Likewise.
13207         * tree-dfa.c: Likewise.
13208         * tree-into-ssa.c: Likewise.
13209         * tree-nomudflap.c: Likewise.
13210         * tree-optimize.c: Likewise.
13211         * tree-pretty-print.c: Likewise.
13212         * tree-profile.c: Likewise.
13213         * tree-ssa-address.c: Likewise.
13214         * tree-ssa-ccp.c: Likewise.
13215         * tree-ssa-copy.c: Likewise.
13216         * tree-ssa-dom.c: Likewise.
13217         * tree-ssa-loop-ch.c: Likewise.
13218         * tree-ssa-loop-im.c: Likewise.
13219         * tree-ssa-loop-manip.c: Likewise.
13220         * tree-ssa-loop-niter.c: Likewise.
13221         * tree-ssa-loop-prefetch.c: Likewise.
13222         * tree-ssa-loop-unswitch.c: Likewise.
13223         * tree-ssa-loop.c: Likewise.
13224         * tree-ssa-propagate.c: Likewise.
13225         * tree-ssa-structalias.c: Likewise.
13226         * tree-ssa-tail-merge.c: Likewise.
13227         * tree-ssa-threadedge.c: Likewise.
13228         * tree-ssa-threadupdate.c: Likewise.
13229         * tree-ssa-uncprop.c: Likewise.
13230         * tree-ssa-uninit.c: Likewise.
13231         * tree-ssa.c: Likewise.
13232         * value-prof.c: Likewise.
13233         * var-tracking.c: Likewise.
13234         * web.c: Likewise.
13235
13236         * config/m32r/m32r.c: Include dbxout.h.
13237         * config/pa/pa.c: Likewise.
13238         * config/rs6000/rs6000.c: Likewise.
13239
13240         * Makefile.in: Fix dependencies.
13241         * config/rs6000/t-rs5000: Likewise.
13242
13243 2012-05-31  Aldy Hernandez  <aldyh@redhat.com>
13244
13245         * tree-ssa-loop-im.c (execute_sm): Do not check flag_tm.
13246         * gimple.h (block_in_transaction): Check for flag_tm.
13247
13248 2012-05-31  Aldy Hernandez  <aldyh@redhat.com>
13249
13250         PR tree-optimization/52558
13251         * cfg.c (alloc_aux_for_edge): Fix comment.
13252         (alloc_aux_for_edge): Remove static.
13253         * basic-block.h (alloc_aux_for_edge): Protoize.
13254         * tree-ssa-loop-im.c (execute_sm_if_changed): New.
13255         (execute_sm_if_changed_flag): New.
13256         (execute_sm_if_changed_flag_set): New.
13257         (execute_sm): Do not generate data races unless requested.
13258         (tree_ssa_lim_initialize): Call alloc_aux_for_edges.
13259         (tree_ssa_lim_finalize): Call free_aux_for_edges.
13260         * gimple.h (block_in_transaction): New.
13261         (gimple_in_transaction): Use block_in_transaction.
13262
13263 2012-05-31  Georg-Johann Lay  <avr@gjlay.de>
13264
13265         PR target/51345
13266         * config/avr/avr.opt (-msp8): Document it.
13267         * doc/invoke.texi (AVR Options): Ditto.  And document related
13268         built-in macros.
13269
13270 2012-05-31  Diego Novillo  <dnovillo@google.com>
13271
13272         * configure.ac (CXX_FOR_BUILD): Define and substitute.
13273         (BUILD_CXXFLAGS): Define and substitute.
13274         * Makefile.in (BUILD_CXXFLAGS): Define.
13275         (CXX_FOR_BUILD): Define.
13276         (COMPILER_FOR_BUILD): Set to CXX_FOR_BUILD if building with C++.
13277         (LINKER_FOR_BUILD): Likewise.
13278         (BUILD_COMPILERFLAGS): Set to BUILD_CXXFLAGS if building with C++.
13279         (BUILD_LINKERFLAGS): Likewise.
13280         * configure: Regenerate.
13281
13282 2012-05-31  Steven Bosscher  <steven@gcc.gnu.org>
13283
13284         * Makefile.in: Fix many dependencies.
13285         * tree-profile.c: Don't include regs.h.
13286         * tree-vectorizer.c: Don't include cfglayout.h.
13287         * tree-vect-stmts.c: Likewise.
13288         * tree-vect-slp.c: Likewise.
13289         * tree-vect-loop.c: Likewise.
13290         * reg-stack.c: Likewise.
13291         * tree-ssa-loop-manip.c: Likewise.
13292         * toplev.c: Likewise.
13293         * varasm.c: Don't include cfglayout.h, basic-block.h,
13294         and tree-iterator.h.
13295         * tree-cfgcleanup.c: Don't include cfglayout.h.
13296         * passes.c: Don't include cfglayout.h, dwarf2asm.h,
13297         dwarf2out.h, dbxout.h, sdbout.h, and xcoffout.h.
13298         * cgraphclones.c: Don't include plugin.h.
13299
13300 2012-05-31  Georg-Johann Lay  <avr@gjlay.de>
13301
13302         * config/avr/t-avr: Correct avr-mmcu.texi dependencies.
13303         (s-avr-mmcu-texi): Don't sed on gen-avr-mmcu-texi output.
13304         * doc/avr-mmcu.texi (svn:eol-style): Set to native.
13305
13306 2012-05-31  Richard Guenther  <rguenther@suse.de>
13307
13308         * tree-loop-distribution.c (struct partition_s): New struct,
13309         typedef and vector type.
13310         (partition_alloc, partition_free): New functions.
13311         (generate_loops_for_partition, generate_builtin,
13312         generate_code_for_partition, rdg_flag_uses, rdg_flag_vertex,
13313         rdg_flag_vertex_and_dependent, rdg_flag_loop_exits,
13314         build_rdg_partition_for_component, can_generate_builtin,
13315         similar_memory_accesses, fuse_partitions_with_similar_memory_accesses,
13316         rdg_build_partitions, dump_rdg_partitions, debug_rdg_partitions,
13317         number_of_rw_in_partition, partition_contains_all_rw,
13318         ldist_gen): Use partition_t instead of bitmap.
13319
13320 2012-05-31  Georg-Johann Lay  <avr@gjlay.de>
13321
13322         * config/avr/gen-avr-mmcu-texi.c: Sort MCUs.
13323         * doc/avr-mmcu.texi: Regenerate.
13324
13325 2012-05-31  Richard Guenther  <rguenther@suse.de>
13326
13327         * tree-loop-distribution.c (stmt_has_scalar_dependences_outside_loop):
13328         Use FOR_EACH_SSA_DEF_OPERAND.
13329         (generate_builtin): Adjust.
13330         (stmt_generated_in_another_partition): Remove.
13331         (add_scalar_computations_to_partition): Likewise.
13332         (rdg_build_partitions): Do not call
13333         add_scalar_computations_to_partition.
13334
13335 2012-05-31  Eric Botcazou  <ebotcazou@adacore.com>
13336
13337         * tree-dfa.c (get_ref_base_and_extent): Compute the offset using
13338         double ints throughout.
13339         * tree-sra.c (build_user_friendly_ref_for_offset) <RECORD_TYPE>:
13340         Check that the position of the field is representable as an integer.
13341
13342 2012-05-31  Richard Guenther  <rguenther@suse.de>
13343
13344         * tree-data-ref.c (dr_analyze_innermost): Properly convert
13345         the MEM_REF offset to sizetype.
13346
13347 2012-05-31  Georg-Johann Lay  <avr@gjlay.de>
13348
13349         * doc/invoke.texi (AVR Options): Fix typos.
13350
13351 2012-05-31  Hans-Peter Nilsson  <hp@axis.com>
13352
13353         * config/cris/cris.h (CC1_SPEC): Pass through all -march=
13354         and -mcpu= options.
13355         (ASM_SPEC): Ditto, not just -march=v32, but translate non-v10,
13356         non-v32 into --march=v0_v10.
13357
13358 2012-05-31  Richard Sandiford  <rdsandiford@googlemail.com>
13359
13360         * ira-int.h (target_ira_int): Rename x_move_cost to
13361         x_ira_register_move_cost, x_may_move_in_cost to
13362         x_ira_may_move_in_cost and x_may_move_out_cost to
13363         x_ira_may_move_out_cost.  Delete the old fields with
13364         those names and also x_ira_max_register_move_cost,
13365         x_ira_max_may_move_in_cost and x_ira_max_may_move_out_cost.
13366         (move_cost, may_move_in_cost, may_move_out_cost)
13367         (ira_max_register_move_cost, ira_max_may_move_in_cost)
13368         (ira_max_may_move_out_cost): Delete.
13369         * ira.c (init_move_cost): Rename to...
13370         (ira_init_register_move_cost): ...this, deleting the old
13371         function with that name.  Apply above variable renamings.
13372         Retain asserts for null fields.
13373         (ira_init_once): Don't initialize register move costs here.
13374         (free_register_move_costs): Apply above variable renamings.
13375         Remove code for deleted fields.
13376
13377 2012-05-31  Richard Sandiford  <rdsandiford@googlemail.com>
13378
13379         * ira.c (init_move_cost): Adjust choice of subclasses to match
13380         the current ira_init_register_move_cost choice.  Use
13381         ira_class_subset_p instead of reg_class_subset_p.
13382         (ira_init_register_move_cost): Assert that move_cost,
13383         may_move_in_cost and may_move_out_cost already hold the desired
13384         values for their ira_* equivalents.  For the latter two,
13385         ignore classes that can't store a register of the given mode.
13386
13387 2012-05-31  Richard Sandiford  <rdsandiford@googlemail.com>
13388
13389         * ira.c (setup_allocno_and_important_classes): Use
13390         ira_class_hard_regs_num to check whether a class has any
13391         allocatable registers.
13392         (ira_init_register_move_cost): Likewise.
13393
13394 2012-05-31  Richard Sandiford  <rdsandiford@googlemail.com>
13395
13396         * ira.c (init_move_cost): Adjust local variable names to match
13397         file conventions.  Use ira_assert instead of gcc_assert.
13398
13399 2012-05-31  Richard Sandiford  <rdsandiford@googlemail.com>
13400
13401         * regs.h (move_table, move_cost, may_move_in_cost, may_move_out_cost):
13402         Move these definitions and associated target_globals fields to...
13403         * ira-int.h: ...here.
13404         * rtl.h (init_move_cost): Delete.
13405         * reginfo.c (last_mode_for_init_move_cost, init_move_cost): Move to...
13406         * ira.c: ...here, making the latter static.
13407
13408 2012-05-31  Richard Sandiford  <rdsandiford@googlemail.com>
13409
13410         * ira-costs.c (copy_cost): Use ira_init_register_move_cost_if_necessary
13411         and ira_register_move_cost instead of init_move_cost and move_cost.
13412
13413 2012-05-31  Richard Sandiford  <rdsandiford@googlemail.com>
13414
13415         * ira.h (target_ira): Delete x_ira_available_class_regs.
13416         (ira_available_class_regs): Delete.
13417         * ira.c (setup_available_class_regs): Delete.
13418         (setup_alloc_classes): Don't call it.
13419         (setup_pressure_classes): Use ira_class_hard_regs_num instead of
13420         ira_available_class_regs.
13421         * haifa-sched.c (print_curr_reg_pressure, setup_insn_reg_pressure_info)
13422         (model_spill_cost): Likewise.
13423         * ira-build.c (low_pressure_loop_node_p): Likewise.
13424         * ira-color.c (color_pass): Likewise.
13425         * ira-emit.c (change_loop): Likewise.
13426         * ira-lives.c (inc_register_pressure, dec_register_pressure)
13427         (single_reg_class, ira_implicitly_set_insn_hard_regs)
13428         (process_bb_node_lives): Likewise.
13429         * loop-invariant.c (gain_for_invariant): Likewise.
13430
13431 2012-05-30  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
13432
13433         PR target/52999
13434         * config/pa/pa.c (TARGET_SECTION_TYPE_FLAGS): Define.
13435         (pa_section_type_flags): New.
13436         (pa_legitimate_constant_p): Revert previous change.
13437
13438 2012-05-30  Steven Bosscher  <steven@gcc.gnu.org>
13439
13440         * ira.c (allocate_initial_values): Make static.
13441
13442 2012-05-30  Uros Bizjak  <ubizjak@gmail.com>
13443
13444         * config/i386/i386.c (legitimize_tls_address) <TLS_MODEL_INITIAL_EXEC>:
13445         Generate tls_initial_exec_64_sun only when !TARGET_X32.
13446
13447 2012-05-30  Richard Guenther  <rguenther@suse.de>
13448
13449         PR middle-end/53501
13450         * fold-const.c (fold_binary_loc): Make sure to call
13451         fold_plusminus_mult_expr with the original sign of operands.
13452
13453 2012-05-30  Steven Bosscher  <steven@gcc.gnu.org>
13454
13455         * Makefile.in: Fix many dependencies.
13456         (DWARF2_H): Depend on dwarf2.def.
13457         (RTL_ERROR_H): Depend on rtl-error.h.
13458         (TREE_PRETTY_PRINT_H, GIMPLE_PRETTY_PRINT_H): New.  Replace
13459         all gimple-pretty-print.h and tree-pretty-print.h references.
13460
13461 2012-05-30  Marc Glisse  <marc.glisse@inria.fr>
13462
13463         * simplify-rtx.c (simplify_binary_operation_1): Optimize shuffle of
13464         concatenations.
13465
13466 2012-05-30  Richard Guenther  <rguenther@suse.de>
13467
13468         PR middle-end/53522
13469         * tree-emutls.c (gen_emutls_addr): Do not add globals to
13470         referenced-vars.
13471
13472 2012-05-30  Eric Botcazou  <ebotcazou@adacore.com>
13473
13474         * explow.c (probe_stack_range): Restore simple control flow and stop
13475         again when the probe cannot be generated if HAVE_check_stack.
13476
13477 2012-05-30  Jakub Jelinek  <jakub@redhat.com>
13478
13479         PR rtl-optimization/53519
13480         * combine.c (simplify_shift_const_1) <case NOT>: Use constm1_rtx
13481         instead of GEN_INT (GET_MODE_MASK (mode)) as second operand of XOR.
13482
13483 2012-05-30  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
13484
13485         * config/arm/arm.c (arm_evpc_neon_vrev): Adjust off by one error.
13486
13487 2012-05-29  Jack Howarth  <howarth@bromo.med.uc.edu>
13488
13489         PR debug/53453
13490         * doc/tm.texi: Update.
13491         * doc/tm.texi.in (SDB and DWARF) <TARGET_FORCE_AT_COMP_DIR>: Add @hook.
13492         * target.def (force_at_comp_dir): New hook.
13493         * config/darwin.h (TARGET_FORCE_AT_COMP_DIR): Define.
13494         * dwarf2out.c (dwarf2out_finish): Check targetm.force_at_comp_dir.
13495
13496 2012-05-29  Jack Howarth  <howarth@bromo.med.uc.edu>
13497
13498         * config/darwin.h (STARTFILE_SPEC): Do not use -lbundle1.o when
13499         Darwin >= 10.
13500         (DARWIN_DYLIB1_SPEC): Do not use -ldylib1.10.5.o when Darwin >= 10.
13501         (DARWIN_CRT1_SPEC): Use -lcrt1.10.6.o when Darwin >= 10.
13502
13503 2012-05-29  Oleg Endo  <olegendo@gcc.gnu.org>
13504
13505         PR target/51340
13506         * config/sh/sh.c (sh_option_override): Set TARGET_FMAC if
13507         flag_unsafe_math_optimizations is set.
13508         * doc/invoke.texi (SH Options): Add -mno-fused-madd description.
13509         Update description of -mfused-madd.
13510
13511 2012-05-29  Oleg Endo  <olegendo@gcc.gnu.org>
13512
13513         PR target/52941
13514         * config/sh/predicates.md (atomic_arith_operand,
13515         atomic_logical_operand): New predicates.
13516         * config/sh/sh.c (sh_option_override): Check atomic options.
13517         * config/sh/sh.h (TARGET_ANY_ATOMIC, UNSUPPORTED_ATOMIC_OPTIONS,
13518         UNSUPPORTED_HARD_ATOMIC_CPU): New macros.
13519         (DRIVER_SELF_SPECS): Use UNSUPPORTED_ATOMIC_OPTIONS and
13520         UNSUPPORTED_HARD_ATOMIC_CPU.
13521         * config/sh/sync.md: Update description comments.
13522         (I12): New mode iterator.
13523         (fetchop_predicate, fetchop_constraint): New code attributes.
13524         (atomic_compare_and_swapsi_hard, atomic_compare_and_swap<mode>_hard,
13525         atomic_exchangesi_hard, atomic_exchange<mode>_hard,
13526         atomic_fetch_<fetchop_name>si_hard,
13527         atomic_fetch_<fetchop_name><mode>_hard,
13528         atomic_fetch_nandsi_hard, atomic_fetch_nand<mode>_hard,
13529         atomic_<fetchop_name>_fetchsi_hard,
13530         atomic_<fetchop_name>_fetch<mode>_hard,
13531         atomic_nand_fetchsi_hard, atomic_nand_fetch<mode>_hard,
13532         atomic_test_and_set_hard): New insns.
13533         (atomic_compare_and_swap<mode>_soft, atomic_exchange<mode>_soft,
13534         atomic_fetch_<fetchop_name><mode>_soft, atomic_fetch_nand<mode>_soft,
13535         atomic_<fetchop_name>_fetch<mode>_soft, atomic_nand_fetch<mode>_soft,
13536         atomic_test_and_set_soft): Use same formatting for the first line of
13537         the asm block as in new insns above.
13538         (atomic_compare_and_swap<mode>, atomic_exchange<mode>,
13539         atomic_fetch_<fetchop_name><mode>, atomic_<fetchop_name>_fetch<mode>,
13540         atomic_test_and_set): Integrate new *_hard insns into expanders.
13541         * config/sh/sh.opt (mhard-atomic): New option.
13542         * doc/invoke.texi (SH Options): Document it.
13543
13544 2012-05-29  Meador Inge  <meadori@codesourcery.com>
13545
13546         * c-decl.c (c_push_function_context): Always create a new language
13547         function.
13548         (c_pop_function_context): Clear the language function created in
13549         c_push_function_context.
13550
13551 2012-05-29  Matt Turner  <mattst88@gmail.com>
13552
13553         * config/alpha/ev6.md: (define_bypass "ev6_fmul,ev6_fadd"): New.
13554         (define_bypass "ev6_fcmov"): New.
13555
13556 2012-05-29  Steven Bosscher  <steven@gcc.gnu.org>
13557
13558         * integrate.c: Remove.
13559         * integrate.h: Remove.
13560         * Makefile.in: Remove make rules for integrate.c and INTEGRATE_H.
13561         * config/arm/t-arm: Remove INTEGRATE_H dependency for target files.
13562         * config/rs6000/t-rs6000: Likewise
13563         * config/spu/t-spu-elf: Likewise.
13564         * function.h (get_hard_reg_initial_val, has_hard_reg_initial_val,
13565         get_hard_reg_initial_reg, emit_initial_value_sets): Move prototypes
13566         from integrate.h to here.
13567         (initial_value_entry): New prototype.
13568         * reload.h (allocate_initial_values): Remove prototype.
13569         * tree.h (set_decl_abstract_flags, set_decl_origin_self): Likewise.
13570         * cse.c (fixed_base_plus_p): Don't handle virtual registers for
13571         integrate.c.
13572         * dwarf2out.c (set_decl_origin_self, set_block_origin_self,
13573         set_decl_abstract_flags, set_block_abstract_flags): Move from
13574         integrate.c to here, the only user.
13575         * expmed.c (extract_fixed_bit_field): Remove outdated comment
13576         about integrate.c.
13577         * function.c: Don't include integrate.h.
13578         (struct initial_value_pair, struct initial_value_struct,
13579         get_hard_reg_initial_val, has_hard_reg_initial_val,
13580         get_hard_reg_initial_reg, emit_initial_value_sets): Move from
13581         integrate.c to here.
13582         (initial_value_entry): New function.
13583         * genemit.c (main): Don't print integrate.h include line.
13584         * ira.c: Don't include integrate.h.
13585         (allocate_initial_values): Move from integrate.c to here.
13586         (ira): Update allocate_initial_values call.
13587         * tree-inline.c: Don't include integrate.h.
13588         (function_attribute_inlinable_p): Moved from integrate.c to here.
13589         * cfgexpand.c: Don't include integrate.h.
13590         * except.c: Likewise.
13591         * langhooks.c: Likewise.
13592         * passes.c: Likewise.
13593         * toplev.c: Likewise.
13594         * config/frv/frv.c: Likewise.
13595         * config/pa/pa.c: Likewise.
13596         * config/spu/spu.c: Likewise.
13597         * config/epiphany/epiphany.c: Likewise.
13598         * config/mep/mep.c: Likewise.
13599         * config/score/score.c: Likewise.
13600         * config/picochip/picochip.c: Likewise.
13601         * config/sh/sh.c: Likewise.
13602         * config/alpha/alpha.c: Likewise.
13603         * config/microblaze/microblaze.c: Likewise.
13604         * config/mips/mips.c: Likewise.
13605         * config/v850/v850.c: Likewise.
13606         * config/mmix/mmix.c: Likewise.
13607         * config/bfin/bfin.c: Likewise.
13608         * config/arm/arm.c: Likewise.
13609         * config/s390/s390.c: Likewise.
13610         * config/m32r/m32r.c: Likewise.
13611         * config/rs6000/rs6000.c: Likewise.
13612         * config/c6x/c6x.c: Include function.h instead of integrate.h.
13613         * config/tilegx/tilegx.c: Likewise.
13614         * config/tilepro/tilepro.c: Likewise.
13615
13616 2012-05-29  Georg-Johann Lay  <avr@gjlay.de>
13617
13618         * config/avr/t-avr (s-avr-mmcu-texi): Call
13619         gen-avr-mmcu-texi$(build_exeext) via ./ and don't assume . is in PATH.
13620
13621 2012-05-29  Michael Matz  <matz@suse.de>
13622
13623         * rtl.h (assign_stack_temp, assign_stack_temp_for_type,
13624         assign_temp): Remove 'keep' argument.
13625         (mark_temp_addr_taken): Remove prototype.
13626         * tree.h (expand_decl): Remove prototype.
13627         * function.c (struct temp_slot): Remove addr_taken and keep member.
13628         (assign_stack_temp_for_type) Don't initialize above, remove
13629         keep argument.
13630         (assign_stack_temp, assign_temp): Remove keep argument.
13631         (mark_temp_addr_taken): Remove.
13632         (preserve_temp_slots): Remove handling of addr_taken and keep members.
13633         (free_temp_slots): Ditto.
13634         * expr.c (expand_expr_real_1 <COMPOUND_LITERAL_EXPR>): Remove
13635         dead code.
13636         * stmt.c (expand_asm_operands): Remove dead code.
13637         (expand_decl): Remove.
13638         * c-decl.c (finish_struct): Don't call expand_decl.
13639         * builtins.c (expand_builtin_cexpi): Adjust calls to assign_temp
13640         and assign_stack_temp.
13641         * calls.c (save_fixed_argument_area, initialize_argument_information,
13642         expand_call, emit_library_call_value_1, store_one_arg): Ditto.
13643         * expmed.c (extract_bit_field_1): Ditto.
13644         * expr.c (emit_group_load_1, emit_group_store,
13645         copy_blkmode_from_reg, emit_push_insn, expand_assignment,
13646         store_field, expand_constructor, expand_cond_expr_using_cmove,
13647         expand_expr_real_2, expand_expr_real_1): Ditto.
13648         * stmt.c (expand_asm_operands, expand_return): Ditto.
13649
13650         * function.c (pop_temp_slots): Call free_temp_slots.
13651         * calls.c (store_one_arg): Don't call preserve_temp_slots or
13652         free_temp_slots.
13653         * expr.c (expand_assignment): Don't call free_temp_slots.
13654
13655         * config/arm/arm.c (neon_expand_vector_init): Ditto.
13656         * config/i386/i386.c (ix86_expand_vector_set): Ditto.
13657         (ix86_expand_vector_extract): Ditto.
13658         * config/ia64/ia64.c (spill_xfmode_rfmode_operand,
13659         ia64_expand_movxf_movrf): Ditto.
13660         * config/mips/mips.c (mips_expand_vi_general): Ditto.
13661         * config/mmix/mmix.md (floatdisf2, floatunsdisf2, truncdfsf2,
13662         extendsfdf2): Ditto.
13663         * config/rs6000/rs6000.c (rs6000_expand_vector_init,
13664         rs6000_expand_vector_set, rs6000_expand_vector_extract,
13665         rs6000_allocate_stack_temp): Ditto.
13666         * config/rs6000/rs6000.md (fix_trunctfsi2_fprs): Ditto.
13667         * config/sparc/sparc.c (emit_soft_tfmode_libcall,
13668         sparc_emit_float_lib_cmp, sparc_emit_float_lib_cmp,
13669         sparc_expand_vector_init): Ditto.
13670
13671 2012-05-29  Michael Matz  <matz@suse.de>
13672
13673         * c-tree.h (c_expand_decl): Remove prototype.
13674
13675         * expr.c (expand_expr_real_1 <normal_inner_ref>): Don't allocate
13676         a kept temp.
13677         (expand_expr_real_1 <COMPOUND_LITERAL_EXPR>): Make unreachable.
13678         * gimple-fold.c (canonicalize_constructor_val): Canonicalize
13679         COMPOUND_LITERAL_EXPR.
13680         * function.c (expand_function_start): Don't call expand_decl,
13681         instead assert that we have RTL assigned.
13682         * tree-ssa-live.c (remove_unused_locals): Clear
13683         nonlocal_goto_save_area if its backing variable is removed.
13684         * stmt.c (expand_asm_operands): Remove handling of non-lvalues
13685         as mem inputs.
13686         (expand_decl): Assert that this does nothing.
13687         * calls.c (expand_call): Don't call mark_temp_addr_taken.
13688
13689 2012-05-29  Richard Guenther  <rguenther@suse.de>
13690
13691         PR tree-optimization/53516
13692         * tree-data-ref.c (stmt_with_adjacent_zero_store_dr_p): Reject
13693         bitfield accesses.
13694         * tree-vect-data-refs.c (vect_analyze_data_refs): Likewise.
13695
13696 2012-05-29  Joseph Myers  <joseph@codesourcery.com>
13697
13698         * LANGUAGES: Fix typos.
13699         * Makefile.in: Fix typos.
13700         * alias.c: Fix typos.
13701         * auto-inc-dec.c: Fix typos.
13702         * bb-reorder.c: Fix typos.
13703         * cfgcleanup.c: Fix typos.
13704         * cgraph.c: Fix typos.
13705         * cgraph.h: Fix typos.
13706         * cgraphunit.c: Fix typos.
13707         * collect2-aix.h: Fix typos.
13708         * collect2.c: Fix typos.
13709         * compare-elim.c: Fix typos.
13710         * config/alpha/vms.h: Fix typos.
13711         * config/arm/README-interworking: Fix typos.
13712         * config/arm/arm.c: Fix typos.
13713         * config/arm/iterators.md: Fix typos.
13714         * config/arm/vxworks.h: Fix typos.
13715         * config/avr/avr.c: Fix typos.
13716         * config/avr/avr.h: Fix typos.
13717         * config/avr/avr.md: Fix typos.
13718         * config/avr/builtins.def: Fix typos.
13719         * config/c6x/c6x.c: Fix typos.
13720         * config/cr16/cr16.c: Fix typos.
13721         * config/cr16/cr16.md: Fix typos.
13722         * config/cris/cris.md: Fix typos.
13723         * config/darwin.c: Fix typos.
13724         * config/darwin.opt: Fix typos.
13725         * config/i386/i386-c.c: Fix typos.
13726         * config/i386/i386.c: Fix typos.
13727         * config/ia64/ia64.c: Fix typos.
13728         * config/m68k/cf.md: Fix typos.
13729         * config/mep/mep.c: Fix typos.
13730         * config/microblaze/microblaze.c: Fix typos.
13731         * config/microblaze/microblaze.h: Fix typos.
13732         * config/mn10300/mn10300.c: Fix typos.
13733         * config/mn10300/mn10300.md: Fix typos.
13734         * config/pa/pa.c: Fix typos.
13735         * config/picochip/picochip.h: Fix typos.
13736         * config/rs6000/a2.md: Fix typos.
13737         * config/rs6000/rs6000.c: Fix typos.
13738         * config/rs6000/vector.md: Fix typos.
13739         * config/rx/rx.md: Fix typos.
13740         * config/rx/rx.opt: Fix typos.
13741         * config/s390/2097.md: Fix typos.
13742         * config/s390/s390.c: Fix typos.
13743         * config/s390/s390.h: Fix typos.
13744         * config/sh/sh.c: Fix typos.
13745         * config/sh/sh.md: Fix typos.
13746         * config/sparc/sync.md: Fix typos.
13747         * config/spu/spu.c: Fix typos.
13748         * config/spu/spu.md: Fix typos.
13749         * config/vms/vms.c: Fix typos.
13750         * config/vxworks-dummy.h: Fix typos.
13751         * config/vxworks.h: Fix typos.
13752         * cselib.c: Fix typos.
13753         * df-scan.c: Fix typos.
13754         * df.h: Fix typos.
13755         * doc/extend.texi: Fix typos.
13756         * doc/install.texi: Fix typos.
13757         * doc/invoke.texi: Fix typos.
13758         * doc/md.texi: Fix typos.
13759         * doc/plugins.texi: Fix typos.
13760         * doc/rtl.texi: Fix typos.
13761         * dse.c: Fix typos.
13762         * dwarf2asm.c: Fix typos.
13763         * dwarf2out.c: Fix typos.
13764         * except.h: Fix typos.
13765         * expr.c: Fix typos.
13766         * fold-const.c: Fix typos.
13767         * gcc.c: Fix typos.
13768         * gcse.c: Fix typos.
13769         * genautomata.c: Fix typos.
13770         * gengtype-state.c: Fix typos.
13771         * gengtype.c: Fix typos.
13772         * genhooks.c: Fix typos.
13773         * gimple-fold.c: Fix typos.
13774         * gimple-pretty-print.c: Fix typos.
13775         * gimple.c: Fix typos.
13776         * gimple.h: Fix typos.
13777         * gimplify.c: Fix typos.
13778         * graphite-interchange.c: Fix typos.
13779         * graphite-sese-to-poly.c: Fix typos.
13780         * ifcvt.c: Fix typos.
13781         * input.c: Fix typos.
13782         * ipa-cp.c: Fix typos.
13783         * ipa-inline-analysis.c: Fix typos.
13784         * ipa-inline-transform.c: Fix typos.
13785         * ipa-inline.c: Fix typos.
13786         * ipa-pure-const.c: Fix typos.
13787         * ipa-ref.h: Fix typos.
13788         * ipa-reference.c: Fix typos.
13789         * ipa-utils.c: Fix typos.
13790         * ipa.c: Fix typos.
13791         * ira-emit.c: Fix typos.
13792         * ira-lives.c: Fix typos.
13793         * lto-streamer.c: Fix typos.
13794         * lto-streamer.h: Fix typos.
13795         * lto-wrapper.c: Fix typos.
13796         * mcf.c: Fix typos.
13797         * mode-switching.c: Fix typos.
13798         * modulo-sched.c: Fix typos.
13799         * plugin.c: Fix typos.
13800         * postreload.c: Fix typos.
13801         * sched-deps.c: Fix typos.
13802         * sel-sched-ir.c: Fix typos.
13803         * sel-sched-ir.h: Fix typos.
13804         * sel-sched.c: Fix typos.
13805         * sese.c: Fix typos.
13806         * stor-layout.c: Fix typos.
13807         * target-hooks-macros.h: Fix typos.
13808         * target.def: Fix typos.
13809         * trans-mem.c: Fix typos.
13810         * tree-eh.c: Fix typos.
13811         * tree-predcom.c: Fix typos.
13812         * tree-sra.c: Fix typos.
13813         * tree-ssa-address.c: Fix typos.
13814         * tree-ssa-loop-ivopts.c: Fix typos.
13815         * tree-ssa-loop-niter.c: Fix typos.
13816         * tree-ssa-math-opts.c: Fix typos.
13817         * tree-ssa-pre.c: Fix typos.
13818         * tree-ssa-propagate.c: Fix typos.
13819         * tree-ssa-reassoc.c: Fix typos.
13820         * tree-ssa-sccvn.c: Fix typos.
13821         * tree-ssa-ter.c: Fix typos.
13822         * tree-ssa-uninit.c: Fix typos.
13823         * tree-ssanames.c: Fix typos.
13824         * tree-vect-generic.c: Fix typos.
13825         * tree-vect-slp.c: Fix typos.
13826         * tree.c: Fix typos.
13827         * tree.h: Fix typos.
13828         * varasm.c: Fix typos.
13829         * varpool.c: Fix typos.
13830
13831 2012-05-29  Joseph Myers  <joseph@codesourcery.com>
13832
13833         * doc/include/texinfo.tex: Update to version 2012-05-16.16.
13834
13835 2012-05-29  Richard Guenther  <rguenther@suse.de>
13836
13837         * tree-dfa.c (find_vars_r): Do not call add_referenced_vars
13838         for globals.
13839         (add_referenced_var_1): Re-organize.  Assert we are not
13840         called for globals.
13841         (remove_referenced_var): Likewise.
13842         * varpool.c (add_new_static_var): Use create_tmp_var_raw.
13843         * tree-mudflap.c (execute_mudflap_function_ops): Do not
13844         call add_referenced_var on globals.
13845         * matrix-reorg.c (transform_access_sites): Likewise.
13846
13847 2012-05-29  Steven Bosscher  <steven@gcc.gnu.org>
13848
13849         * alias.c (reg_known_value): Make this a VEC.
13850         (reg_known_equiv_p): Make this an sbitmap.
13851         (reg_known_value_size): Remove.
13852         (get_reg_known_value, set_reg_known_value, get_reg_known_equiv_p,
13853         set_reg_known_equiv_p): Update for reg_known_value and
13854         reg_known_value_size data structure change.
13855         (init_alias_analysis, end_alias_analysis): Likewise.
13856
13857 2012-05-29  Jakub Jelinek  <jakub@redhat.com>
13858
13859         PR middle-end/53510
13860         * input.c (read_line): Use XRESIZEVEC instead of XNEWVEC
13861         to avoid leaking memory.  No need to handle memory allocation
13862         failure.  Double string_len on each reallocation instead of adding 2.
13863         * gcov.c (read_line): Likewise.
13864
13865 2012-05-29  Hans-Peter Nilsson  <hp@axis.com>
13866
13867         * config/cris/cris.h (TARGET_HAS_BREAK, TARGET_TRAP_USING_BREAK8):
13868         New macros.
13869         * config/cris/cris.md ("trap"): Define, enabled for
13870         TARGET_TRAP_USING_BREAK8.
13871         * config/cris/cris.opt (mtrap-using-break8): New option.
13872
13873 2012-05-28  Paolo Carlini  <paolo.carlini@oracle.com>
13874
13875         PR c++/25137
13876         * doc/invoke.texi: Document -Wmissing-braces not enabled by -Wall
13877         for C++.
13878
13879 2012-05-28  Hans-Peter Nilsson  <hp@axis.com>
13880
13881         * doc/md.texi (stack_protect_test): Remove negation of branch to label.
13882         (Standard Names): Fix typos in documentation of atomic patterns.
13883
13884 2012-05-27  Nathan Sidwell  <nathan@acm.org>
13885
13886         * tree.c (build_constructor): Propagate TREE_SIDE_EFFECTS.
13887
13888 2012-05-26  Jason Merrill  <jason@redhat.com>
13889
13890         PR c++/53220
13891         * c-typeck.c (array_to_pointer_conversion): Give -Wc++-compat warning
13892         about array compound literals.
13893
13894 2012-05-26  Eric Botcazou  <ebotcazou@adacore.com>
13895
13896         * cfgcleanup.c (try_optimize_cfg): Do not delete forwarder blocks
13897         if CLEANUP_NO_INSN_DEL.
13898         * cfgrtl.c (unique_locus_on_edge_between_p): New function extracted
13899         from cfg_layout_merge_blocks.
13900         (emit_nop_for_unique_locus_between): New function.
13901         (rtl_merge_blocks): Invoke emit_nop_for_unique_locus_between.
13902         (cfg_layout_merge_blocks): Likewise.
13903
13904 2012-05-26  Dimitrios Apostolou  <jimis@gmx.net>
13905             Paolo Bonzini  <bonzini@gnu.org>
13906
13907         * df-scan.c (df_def_record_1): Assert a parallel must contain an
13908         EXPR_LIST at this point.  Receive the LOC and move its extraction...
13909         (df_defs_record): ... here. Change if-else to a switch statement.
13910         (df_find_hard_reg_defs, df_find_hard_reg_defs_1): New.
13911         (df_get_call_refs): Changed defs_generated from bitmap to HARD_REG_SET
13912         and compute it from df_find_hard_reg_defs(). Record DF_REF_BASE
13913         DEFs in REGNO order. Use HARD_REG_SET instead of bitmap for
13914         regs_invalidated_by_call.
13915         (df_insn_refs_collect): Record DF_REF_REGULAR DEFs after
13916         df_get_call_refs().
13917
13918 2012-05-25  Eric Botcazou  <ebotcazou@adacore.com>
13919
13920         PR lto/52178
13921         * tree-inline.c (remap_gimple_op_r): Fix handling of FIELD_DECL.
13922         * tree.c (RETURN_TRUE_IF_VAR): Do not return true for PLACEHOLDER_EXPR.
13923
13924 2012-05-25  Michael Meissner  <meissner@linux.vnet.ibm.com>
13925
13926         * config/rs6000/t-linux64: Delete the 32-bit multilib that uses
13927         software floating point emulation.  No longer build the multilibs
13928         with -mstrict-align.
13929
13930 2012-05-25  Aldy Hernandez  <aldyh@redhat.com>
13931
13932         PR middle-end/53008
13933         * trans-mem.c (ipa_tm_create_version_alias): Output new_node if
13934         accessed indirectly.
13935         (ipa_tm_create_version): Same.
13936
13937 2012-05-25  Uros Bizjak  <ubizjak@gmail.com>
13938
13939         PR target/53474
13940         * config/i386/i386.c (ix86_print_operand) <case 'O'>: Print '.' here.
13941         <case 'C', case 'c', case 'F', case 'f'>: Print '.' only for C and c.
13942
13943 2012-05-25  Alexander Ivchenko  <alexander.ivchenko@intel.com>
13944
13945         PR target/53435
13946         * config/i386/i386.c (ix86_expand_vec_perm): Use correct op.
13947         (ix86_expand_vec_perm): Use int mode instead of float.
13948         (expand_vec_perm_pshufb): Remove handling of useseless type
13949         conversion.
13950
13951 2012-05-25  Eric Botcazou  <ebotcazou@adacore.com>
13952
13953         PR ada/52362
13954         * config.gcc (i[34567]86-*-mingw* | x86_64-*-mingw*): Set gas and
13955         gnu_ld variables to yes.
13956         * configure.ac (HAVE_GNU_LD): Move to after config.gcc inclusion.
13957         (HAVE_GNU_AS): Likewise.
13958         * config.in: Regenerate.
13959         * configure: Likewise.
13960
13961 2012-05-25  Tristan Gingold  <gingold@adacore.com>
13962
13963         * config/i386/i386.c (struct ix86_frame): Remove unused frame field.
13964         (ix86_compute_frame_layout): Fix type of stack_alignment_needed
13965         and preferred_alignment.
13966
13967 2012-05-25  Tristan Gingold  <gingold@adacore.com>
13968
13969         * common/config/ia64/ia64-common.c (ia64_except_unwind_info): Fix typo.
13970
13971 2012-05-25  Thomas Schwinge  <thomas@codesourcery.com>
13972
13973         * fold-const.c (optimize_bit_field_compare): Abort early in the strict
13974         volatile bitfields case.
13975
13976 2012-05-24  Pat Haugen  <pthaugen@us.ibm.com>
13977
13978         * config/rs6000/rs6000.c (rs6000_option_override_internal): Change
13979         rs6000_sched_costly_dep default to true_store_to_load_dep_costly.
13980         (adjacent_mem_locations): Move some code to and call...
13981         (get_memref_parts): ...new function.
13982         (mem_locations_overlap): New function.
13983         (rs6000_adjust_priority): Adjust calls to is_load_insn/is_store_insn.
13984         (is_mem_ref): Rename to...
13985         (find_mem_ref): ...this. Return MEM rtx.
13986         (get_store_dest): Remove function.
13987         (is_load_insn1, is_load_insn, is_store_insn1, is_store_insn): Add
13988         new parameter and adjust calls.
13989         (rs6000_is_costly_dependence): Update calls for extra arg. Make sure
13990         mem refs overlap for true_store_to_load_dep_costly.
13991         (rs6000_sched_reorder2): Update calls for extra arg. Adjust args
13992         passed to adjacent_mem_locations.
13993         (is_costly_group): Walk resolved dependency list.
13994         (force_new_group): Emit group ending nop for Power6/Power7.
13995         * config/rs6000/rs6000.md (UNSPEC_GRP_END_NOP): New enum value.
13996         (group_ending_nop): New define_insn.
13997
13998 2012-05-24  Dodji Seketeli  <dodji@redhat.com>
13999
14000         Make unwound macro expansion trace less redundant
14001         * tree-diagnostic.c (maybe_unwind_expanded_macro_loc): Don't print
14002         context of macro definition in the trace, when it's redundant.
14003         Update comments.
14004
14005 2012-05-24  Richard Guenther  <rguenther@suse.de>
14006
14007         PR middle-end/53460
14008         * tree-profile.c (tree_profiling): Cleanup the CFG if
14009         execute_fixup_cfg requests it.
14010
14011 2012-05-24  Richard Guenther  <rguenther@suse.de>
14012
14013         * tree-flow.h (create_var_ann): Remove.
14014         * tree-dfa.c (create_var_ann): Remove and inline into its
14015         single caller ...
14016         (add_referenced_var_1): ... here.
14017         * varpool.c (add_new_static_var): Do not call add_referenced_var
14018         for global vars.
14019         * gimple-fold.c (canonicalize_constructor_val): Likewise.
14020         * tree-switch-conversion.c (build_one_array): Likewise.
14021         * tree-profile.c (gimple_gen_ic_profiler): Likewise.
14022         * tree-flow-inline.h (gimple_referenced_vars): Guard against
14023         NULL fn argument.
14024         * tree-inline.c (remap_gimple_op_r): Likewise.  Check
14025         gimple_referenced_vars instead of gimple_in_ssa_p.
14026         (copy_tree_body_r): Likewise.
14027         (setup_one_parameter): Likewise.
14028         (declare_return_variable): Likewise.
14029         (tree_function_versioning): Likewise.
14030
14031 2012-05-24  Jakub Jelinek  <jakub@redhat.com>
14032
14033         PR tree-optimization/53465
14034         * tree-vrp.c (extract_range_from_cond_expr): First copy_value_range
14035         vr0 into *vr, then vrp_meet that.
14036         (vrp_meet): If one vr type is VR_UNDEFINED, ensure the result doesn't
14037         have any equivalences.
14038         (vrp_visit_phi_node): Call copy_value_range instead of vrp_meet the
14039         first time.
14040
14041 2012-05-24  Jim MacArthur  <jim.macarthur@arm.com>
14042
14043         * recog.c (reg_fits_class_p): Check both regno and regno + offset are
14044         hard registers.
14045         * regs.h (in_hard_reg_set_p): Assert that regno is a hard register and
14046         check end_regno - 1 is a hard register.
14047
14048 2012-05-24  Richard Guenther  <rguenther@suse.de>
14049
14050         * varpool.c (add_new_static_var): Remove call to create_var_ann.
14051         * tree-ssa-operands.c (create_vop_var): Likewise.
14052
14053 2012-05-24  Richard Guenther  <rguenther@suse.de>
14054
14055         PR bootstrap/53466
14056         * tree-ssa-live.c (remove_unused_scope_block_p): Properly
14057         handle globals.
14058         (remove_unused_locals): Pass global_unused_vars to
14059         remove_unused_scope_block_p.  Restore code walking all
14060         referenced vars and pruning them.
14061
14062 2012-05-23  Jan Hubicka  <jh@suse.cz>
14063
14064         * tree.h (alias_diag_flags): Remove.
14065         (alias_pair): Remove emitted_diags.
14066         (finish_aliases_1, finish_aliases_2, remove_unreachable_alias_pairs,
14067         symbol_alias_set_t, symbol_alias_set_destroy,
14068         symbol_alias_set_contains, propagate_aliases_backward): Remove.
14069         * toplev.c (compile_file): Do not call finish_aliases_2
14070         * cgraphunit.c (cgraph_process_new_functions): Do not call
14071         finish_aliases_1.
14072         (handle_alias_pairs): Output diagnostics about aliases to externals.
14073         (assemble_thunks_and_aliases): Use do_assemble_alias.
14074         (output_weakrefs): Likewise.
14075         (finalize_compilation_unit): Do not call finish_aliases_1.
14076         * ipa.c (symtab_remove_unreachable_nodes): De not call
14077         remove_unreachable_alias_pairs.
14078         * varasm.c (do_assemble_alias): Export.
14079         (symbol_alias_set_create, symbol_alias_set_destroy,
14080         symbol_alias_set_contains, symbol_alias_set_insert,
14081         propagate_aliases_forward, propagate_aliases_backward,
14082         propagate_aliases_backward, trivially_visible_alias,
14083         trivially_defined_alias, remove_unreachable_alias_pairs,
14084         finish_aliases_1, finish_aliases_2, assemble_alias): Remove.
14085         * output.h (do_assemble_alias): Declare.
14086         * varpool.c (varpool_remove_unreferenced_decls): Do not call
14087         finish_aliases_1.
14088
14089 2012-05-23  Martin Jambor  <mjambor@suse.cz>
14090
14091         * ipa-inline-analysis.c (inline_merge_summary): Free operand_map.
14092
14093 2012-05-23  Eric Botcazou  <ebotcazou@adacore.com>
14094
14095         * gimple.c (gimple_types_compatible_p_1) <ARRAY_TYPE>: Remove bogus
14096         size handling.
14097         (gimple_canonical_types_compatible_p) <ARRAY_TYPE>: Likewise.
14098         (iterative_hash_gimple_type): Adjust comment.
14099         (iterative_hash_canonical_type): Likewise.  Hash the bounds of the
14100         domain for an array type instead of the domain type itself.
14101
14102 2012-05-23  Richard Guenther  <rguenther@suse.de>
14103
14104         PR tree-optimization/53438
14105         * tree-sra.c (analyze_access_subtree): Correct bitfield exclusion.
14106
14107 2012-05-23  Georg-Johann Lay  <avr@gjlay.de>
14108
14109         PR target/53448
14110         * config/avr/avr.h (ASM_OUTPUT_ALIGN): Don't inhibit .p2align 1.
14111         * config/avr/elf.h (ASM_OUTPUT_BEFORE_CASE_LABEL): Use
14112         ASM_OUTPUT_ALIGN.
14113
14114 2012-05-23  Richard Guenther  <rguenther@suse.de>
14115
14116         * tree-dfa.c (add_referenced_var_1): Do not add global vars.
14117         * tree-ssa-live.c (mark_all_vars_used_1): Handle global vars
14118         via the global_unused_vars bitmap.
14119         (remove_unused_locals): Handle global vars in local-decls via
14120         a global_unused_vars bitmap instead of the used flag in the
14121         var annotation.  Simplify global variable handling and removal.
14122
14123 2012-05-22  Jan Hubicka  <jh@suse.cz>
14124
14125         PR middle-end/53426
14126         * tree-ssa-structalias.c (create_variable_info_for): Skip constructors
14127         from other partitions.
14128
14129 2012-05-22  Jan Hubicka  <jh@suse.cz>
14130
14131         PR middle-end/53161
14132         * symtab.c (symtab_register_node): Fix ordering issue.
14133
14134 2012-05-22  Steven Drake <sbd@NetBSD.org>
14135
14136         * gcc.c (do_spec_1): Add %M spec token to output multilib_os_dir.
14137
14138 2012-05-22  David Edelsohn  <dje.gcc@gmail.com>
14139
14140         * config/rs6000/rs6000.c (rs6000_aix_asm_output_dwarf_table_ref):
14141         Use strip_name_encoding target hook.
14142
14143 2012-05-22  Richard Guenther  <rguenther@suse.de>
14144
14145         * tree.h (VAR_DECL_IS_VIRTUAL_OPERAND): New.
14146         (init_function_for_compilation): Remove.
14147         * tree-dfa.c (find_vars_r): Take struct function argument.
14148         (find_referenced_vars_in): Adjust.
14149         * tree-ssa-operands.c (clobber_stats): Remove.
14150         (create_vop_var): Take struct function argument.  Mark
14151         virtual operand with VAR_DECL_IS_VIRTUAL_OPERAND.
14152         (init_ssa_operands): Take struct function argument.
14153         (fini_ssa_operands): Do not dump dead stats.
14154         * tree-ssa-operands.h (init_ssa_operands): Take struct function
14155         argument.
14156         * cgraphunit.c (init_lowered_empty_function): Adjust.
14157         * lto-streamer-in.c (input_cfg): Likewise.
14158         * tree-inline.c (initialize_cfun): Likewise.
14159         * tree-into-ssa.c (rewrite_into_ssa): Likewise.
14160         * omp-low.c (expand_omp_taskreg): Likewise.  Avoid switching cfun.
14161         * gimple.c (is_gimple_reg): Optimize the SSA_NAME case,
14162         virtual operands are not registers.
14163
14164 2012-05-22  Richard Guenther  <rguenther@suse.de>
14165
14166         * tree-cfg.c (verify_gimple_assign_unary): Fix typo in previous commit.
14167
14168 2012-05-22  Richard Guenther  <rguenther@suse.de>
14169
14170         PR middle-end/53437
14171         * tree-inline.c (setup_one_parameter): Create a dummy init
14172         statement for unused parameters when not optimizing.
14173
14174 2012-05-22  Richard Guenther  <rguenther@suse.de>
14175
14176         * tree-flow.h (add_referenced_var_1): Declare.
14177         (add_referenced_var): Define.
14178         * tree-dfa.c (referenced_var_check_and_insert): Avoid one hash lookup.
14179         (add_referenced_var): Rename to ...
14180         (add_referenced_var_1): ... this.  Take struct function argument.
14181
14182 2012-05-22  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
14183
14184         PR target/53334
14185         * config/arm/arm-protos.h (arm_validize_comparison): Declare.
14186         * config/arm/arm.c (arm_validize_comparison): Define.
14187         * config/arm/arm.md ("cbranchsi4"): Cleanup expansion and use
14188         arm_validize_comparison.
14189         ("cbranchdi4"): Likewise.
14190         ("cstoredi4"): Likewise.
14191         ("movsicc"): Likewise.
14192         ("movsfcc"): Likewise.
14193         ("movdfcc"): Likewise.
14194
14195 2012-05-22  Dimitrios Apostolou  <jimis@gmx.net>
14196
14197         * df-scan.c (df_scan_alloc): Round up allocation pools size, reduce
14198         the mw_reg_pool size.
14199
14200 2012-05-22  Paolo Bonzini  <bonzini@gnu.org>
14201
14202         PR tree-optimization/53336
14203         * tree-cfg.c (verify_gimple_assign_unary): Allow conversion from
14204         non-integer integral types to offset type and vice versa.
14205
14206 2012-05-22  Alan Modra  <amodra@gmail.com>
14207
14208         * config/rs6000/aix.h (FP_SAVE_INLINE, GP_SAVE_INLINE): Delete.
14209         * config/rs6000/darwin.h (FP_SAVE_INLINE, GP_SAVE_INLINE): Delete.
14210         * config/rs6000/sysv4.h (FP_SAVE_INLINE, GP_SAVE_INLINE,
14211         V_SAVE_INLINE): Delete.
14212         * config/rs6000/rs6000.c (V_SAVE_INLINE): Delete.
14213         (rs6000_savres_strategy): Reimplement GP/FP/V_SAVE_INLINE logic.
14214         For ELF targets, use out-of-line restores for -Os and any number
14215         of regs if the restore exits, and out-of-line gp save for two or
14216         more regs.  Use save_reg_p to test for holes in reg restore set.
14217         Replace "#if" with "if".
14218
14219 2012-05-22  Alan Modra  <amodra@gmail.com>
14220
14221         * config/rs6000/rs6000.c (save_reg_p): New function.
14222         (first_reg_to_save, first_fp_reg_to_save): Use it here.
14223         (first_altivec_reg_to_save, restore_saved_cr): Likewise.
14224         (emit_frame_save): Use gen_frame_store.
14225         (gen_frame_mem_offset): Correct SPE condition requiring reg+reg.
14226         (rs6000_emit_prologue): Use save_reg_p.  Use gen_frame_store for
14227         vrsave and toc.
14228         (rs6000_emit_epilogue): Use save_reg_p.  Use gen_frame_load for
14229         vrsave, toc, gp and fp restores.
14230
14231 2012-05-22  Alan Modra  <amodra@gmail.com>
14232
14233         * config/rs6000/rs6000.c: Delete unnecessary forward declarations.
14234         Move those with ATTRIBUTE_UNUSED to immediately before definitions.
14235         Move function pointer variables after forward declarations.
14236         (rs6000_builtin_support_vector_misalignment): Make static.
14237         (rs6000_legitimate_address_p, rs6000_gimplify_va_arg): Likewise.
14238         (rs6000_function_value, rs6000_can_eliminate): Likewise.
14239
14240 2012-05-21  Bernd Schmidt  <bernds@codesourcery.com>
14241
14242         PR rtl-optimization/53373
14243         * caller-save.c (save_call_clobbered_regs): Look into a possible
14244         PARALLEL manually rather than using single_set on a call insn.
14245
14246 2012-05-21  Jakub Jelinek  <jakub@redhat.com>
14247
14248         PR tree-optimization/53436
14249         * omp-low.c (omp_build_component_ref): New function.
14250         (build_receiver_ref, build_sender_ref, create_task_copyfn): Use it.
14251
14252 2012-05-21  Uros Bizjak  <ubizjak@gmail.com>
14253
14254         * config/i386/i386.c (put_condition_code): Change "reverse" and "fp"
14255         arguments to bool.
14256         (ix86_print_operand) <case 'O'>: Look at mode size of the operand.
14257         Do not print '.' here.  Output operand lossage error for unhandled
14258         sizes.  Move.
14259         <case '*'>: Move.
14260         <case '&'>: Ditto.
14261         <case 'Y'>: Ditto.
14262         <case 'z'>: Hardcode "code" argument into error strings.
14263         <case 'Z'>: Ditto.
14264         <case 'D'>: Merge AVX and non-AVX codes.
14265         <case 'C', case 'c', case 'F', case 'f'>: Merge.  Fix error string.
14266         Update call to put_condition_code.
14267
14268 2012-05-21  Andreas Schwab  <schwab@linux-m68k.org>
14269
14270         * config/m68k/m68k.md (*clzsi2_cf): Renamed from clzsi2.  Call
14271         CC_STATUS_INIT.
14272         (clzsi2): New expander.
14273         (*clzsi2_68k): New insn.
14274         * config/m68k/m68k.h: Update comment about CLZ_DEFINED_VALUE_AT_ZERO.
14275
14276 2012-05-21  Aldy Hernandez  <aldyh@redhat.com>
14277
14278         * gimple.h (gimple_set_in_transaction): Remove.
14279         (gimple_in_transaction): Look in BB instead.
14280         (gimple_statement_base): Remove in_transaction field.
14281         * basic-block.h (enum bb_flags): Add BB_IN_TRANSACTION.
14282         * trans-mem.c (compute_transaction_bits): Place transaction bit
14283         information into basic blocks.
14284
14285 2012-05-21  Andreas Schwab  <schwab@linux-m68k.org>
14286
14287         * expr.c (get_def_for_expr_class): Define only if
14288         HAVE_conditional_move.
14289         (convert_tree_comp_to_rtx): Likewise.
14290
14291 2012-05-21  Uros Bizjak  <ubizjak@gmail.com>
14292
14293         PR target/53399
14294         * config/i386/i386.md (ffs<mode>2): Generate CCCmode compare
14295         for TARGET_BMI.
14296         (ffssi2_no_cmove): Ditto.
14297         (*ffs<mode>_1): Remove insn pattern.
14298         (*tzcnt<mode>_1): New insn pattern.
14299         (*bsf<mode>1): Ditto.
14300
14301 2012-05-21  Richard Guenther  <rguenther@suse.de>
14302
14303         * tree-dfa.c (add_referenced_var): Do not walk DECL_INITIAL for
14304         more referenced vars.
14305         * tree-ssa-live.c (mark_all_vars_used_1): Only set the used
14306         flag on variables that have a var-annotation.
14307
14308 2012-05-21  Joseph Myers  <joseph@codesourcery.com>
14309
14310         PR c/53418
14311         * c-typeck.c (build_conditional_expr): Remove C_MAYBE_CONST_EXPR
14312         from folded operands before wrapping another around the
14313         conditional expression.
14314
14315 2012-05-21  Jakub Jelinek  <jakub@redhat.com>
14316
14317         PR tree-optimization/53366
14318         * tree-vect-slp.c (vect_supported_load_permutation_p): Don't shortcut
14319         tests if complex_numbers == 2, but there are non-complex number loads
14320         too.
14321
14322         PR tree-optimization/53409
14323         * tree-vect-loop.c (vect_analyze_loop_operations): Don't check
14324         vinfo_for_stmt (op_def_stmt) if op_def_stmt isn't inside loop.
14325
14326         PR tree-optimization/53410
14327         * fold-const.c (fold_binary_loc): Use build_zero_cst (type)
14328         instead of build_int_cst (type, 0) where vector types might be
14329         involved. Instead of build_int_cst (type, 1) convert the original
14330         integer_onep argument to the desired type.
14331
14332 2012-05-21  Michael Matz  <matz@suse.de>
14333
14334         * genattrtab.c (attr_rtx_cost): Move earlier, start with cost being 1.
14335         (simplify_test_exp): Handle one more case of distributive law,
14336         decrease cost threshold.
14337         (tests_attr_p, get_attr_order): New functions.
14338         (optimize_attrs): Use topological order, inline only cheap values.
14339         (write_attr_set): Reset our_known_true after some time.
14340
14341 2012-05-21  H.J. Lu  <hongjiu.lu@intel.com>
14342
14343         PR target/53425
14344         * config/i386/i386.c (type_natural_mode): Warn passing SSE
14345         vector argument without SSE enabled changes the ABI.
14346
14347 2012-05-21  Richard Guenther  <rguenther@suse.de>
14348
14349         PR tree-optimization/53408
14350         * tree-vect-loop.c (vectorizable_induction): Properly check
14351         the restriction that we cannot handle induction results from
14352         the inner loop outside of the outer loop.
14353
14354 2012-05-21  H.J. Lu  <hongjiu.lu@intel.com>
14355
14356         PR target/53416
14357         * config/i386/i386.md (UNSPEC_RDRAND): Renamed to ...
14358         (UNSPECV_RDRAND): This.
14359         (rdrand<mode>_1): Updated.
14360
14361 2012-05-21  Richard Guenther  <rguenther@suse.de>
14362
14363         * tree-loop-distribution.c (can_generate_builtin): Reject
14364         volatile stmts.
14365
14366 2012-05-21  Chung-Lin Tang  <cltang@codesourcery.com>
14367
14368         * Makefile.in (options.c): Add options.h to included header
14369         files, before tm.h.
14370
14371 2012-05-21  Razya Ladelsky  <razya@il.ibm.com>
14372
14373         * tree-parloops.c : Add myself to contributors, update
14374         TODO list, add link to wiki.
14375
14376 2012-05-21  Alan Modra  <amodra@gmail.com>
14377
14378         * config/rs6000/predicates.md (input_operand): Don't match
14379         constant pool addresses.  Remove label_ref, high and plus from
14380         match_code list.  Remove redundant CONSTANT_P test.
14381         (splat_input_operand): Similarly update match_code list.
14382         (small_toc_ref): New predicate.
14383         * config/rs6000/rs6000-protos.h (toc_relative_expr_p): Update prototype.
14384         * config/rs6000/rs6000.c (tocrel_base, tocrel_offset): Make const.
14385         (legitimate_constant_pool_address_p): Move TARGET_TOC test and
14386         register checks to..
14387         (toc_relative_expr_p): ..here.  Add "strict" param.  Match new rtl
14388         generated by create_TOC_reference.
14389         (rs6000_legitimize_address): Update cerate_TOC_reference call.
14390         (rs6000_delegitimize_address): Handle new rtl for toc refs.
14391         (rs6000_cannot_force_const_mem, rs6000_find_base_term): Likewise.
14392         (use_toc_relative_ref): New function, split out from..
14393         (rs6000_emit_move): ..here.  Remove redundant tests.  Update
14394         create_TOC_reference calls.
14395         (rs6000_legitimize_reload_address): Formatting.  Handle splitting
14396         of medium/large model toc addresses.  Use use_toc_relative_ref.
14397         (print_operand): Formatting, style.  Adjust for toc changes.
14398         (print_operand_address): Likewise.
14399         (rs6000_output_addr_const_extra): Likewise.
14400         (create_TOC_reference): Put TOC_REGISTER in UNSPEC_TOCREL rather
14401         than a PLUS.  Use this formulation for both high and low part
14402         of -mcmodel=medium/large toc reference too.  Before reload,
14403         always use the small model formulation.
14404         * config/rs6000/rs6000.md (tls_gd, tls_gd_high): Similarly avoid
14405         a PLUS in high part of addresses here.
14406         (tls_ld, tls_ld_high, tls_got_dtprel, tls_got_dtprel_high): Likewise.
14407         (tls_got_tprel, tls_got_tprel_high, largetoc_high): Likewise.
14408         (largetoc_high, largetoc_low): Move earlier.  Cope when no
14409         base reg available.
14410         (largetoc_high_plus): New insn.
14411         (movsi_internal1, movsi_internal1_single, movsf_softfloat,
14412         movdi_mfpgpr, movdi_internal64): Don't handle 'R' constraint here..
14413         (tocref): ..instead do so here, new insn and split.
14414
14415 2012-05-20  H.J. Lu  <hongjiu.lu@intel.com>
14416
14417         * config/i386/driver-i386.c (host_detect_local_cpu): Support
14418         RDRND, F16C and FSGSBASE.
14419
14420 2012-05-20  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
14421
14422         PR rtl-optimzation/53373
14423         * config/pa/pa.md (call_symref_pic): Don't expose PIC register save in
14424         call pattern.  Update split patterns.
14425         (call_symref_64bit, call_reg_pic, call_reg_64bit, call_val_symref_pic,
14426         call_val_symref_64bit, call_val_reg_pic, call_val_reg_64bit): Likewise.
14427
14428 2012-05-20  Razya Ladelsky  <razya@il.ibm.com>
14429
14430         * tree-parloops.c (gen_parallel_loop): Change many_iterations_cond
14431         for outer loops.
14432
14433 2012-05-18  Jan Hubicka  <jh@suse.cz>
14434
14435         * cgraphunit.c (handle_alias_pairs): Declare; free alias_pairs
14436         (cgraph_process_new_functions): Process also aliases.
14437         * lto-streamer-out.c (struct sets): Remove.
14438         (trivally_defined_alias): Remove.
14439         (output_alias_pair_p): Remove.
14440         (output_unreferenced_globals): Remove.
14441         (produce_symtab); Do not handle alias pairs.
14442         (produce_asm_for_decls): Likewise.
14443         * lto-streamer-in.c (input_alias_pairs): Remove.
14444         (lto_read_body): Do not input alias pairs.
14445         (lto_input_constructors_and_inits): Remove.
14446
14447 2012-05-18  Jan Hubicka  <jh@suse.cz>
14448
14449         * cgraphunit.c (handle_alias_pairs): Cleanup; handle all types of
14450         aliases.
14451
14452 2012-05-18  Jan Hubicka  <jh@suse.cz>
14453
14454         * cgraphbuild.c (record_reference): Update.
14455         * lto-cgraph.c (lto_output_varpool_node): External vars
14456         are not in other partition even if they are not output
14457         in current partition.
14458         * gimple-fold.c (can_refer_decl_in_current_unit_p): Take FROM_DECL
14459         argument; fix.
14460         (canonicalize_constructor_val): Take FROM_DECL argument.
14461         (fold_ctor_reference, fold_string_cst_ctor_reference,
14462         fold_array_ctor_reference, fold_nonarray_ctor_reference,
14463         fold_ctor_reference): Likewise.
14464         (fold_const_aggregate_ref_1, gimple_get_virt_method_for_binfo): Update.
14465         * gimple.h (gimple_fold_builtin): Likewise.
14466
14467 2012-05-18  Olivier Hainque  <hainque@adacore.com>
14468
14469         * Makefile.in (FLAGS_TO_PASS): Pass $(libexecsubdir) instead of
14470         $(libsubdir) as libexecsubdir.
14471
14472 2012-05-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
14473
14474         * config/rs6000/rs6000.c (print_operand): Revise code that unsafely
14475         relied on signed overflow behavior.
14476
14477 2012-05-18  Richard Guenther  <rguenther@suse.de>
14478
14479         PR tree-optimization/53346
14480         * tree-loop-distribution.c (ldist_gen): Make sure to apply
14481         builtin transform even when only a single partition with
14482         all reads/writes exists.
14483
14484 2012-05-18  Richard Guenther  <rguenther@suse.de>
14485
14486         PR tree-optimization/53390
14487         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Ignore
14488         strided loads.
14489
14490 2012-05-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
14491
14492         * tree-ssa-reassoc.c (bip_map): Remove decl.
14493         (completely_remove_stmt): Remove function.
14494         (remove_def_if_absorbed_call): Remove function.
14495         (remove_visited_stmt_chain): Remove __builtin_powi handling.
14496         (possibly_move_powi): Remove function.
14497         (rewrite_expr_tree): Remove calls to possibly_move_powi.
14498         (rewrite_expr_tree_parallel): Likewise.
14499         (attempt_builtin_powi): Build multiplies explicitly rather than
14500         relying on the ops vector and rank system.
14501         (transform_stmt_to_copy): New function.
14502         (transform_stmt_to_multiply): Likewise.
14503         (reassociate_bb): Handle leftover operations after __builtin_powi
14504         optimization; build a final multiply if necessary.
14505
14506 2012-05-18  Jan Hubicka  <jh@suse.cz>
14507
14508         * cgraphunit.c (varpool_finalize_decl): Allow external decls.
14509         (mark_functions_to_output): Fix sanity check.
14510         * ipa.c (function_and_variable_visibility): Remove TREE_STATIC check.
14511
14512 2012-05-18  Richard Guenther  <rguenther@suse.de>
14513
14514         * tree-flow.h (mark_symbols_for_renaming): Remove.
14515         * tree-dfa.c (mark_symbols_for_renaming): Likewise.
14516         * tree-inline.c (copy_edges_for_bb): Do not mark symbols for renaming.
14517         (copy_debug_stmt): Likewise.
14518         (expand_call_inline): Likewise.
14519         (declare_return_variable): Mark the return variable for renaming
14520         if necessary.
14521
14522 2012-05-18  Andrew Stubbs  <ams@codesourcery.com>
14523
14524         * config/arm/arm-protos.h (arm_emit_coreregs_64bit_shift): New
14525         prototype.
14526         * config/arm/arm.c (arm_emit_coreregs_64bit_shift): New function.
14527         * config/arm/arm.md (ashldi3): Use arm_emit_coreregs_64bit_shift.
14528         (ashrdi3,lshrdi3): Likewise.
14529         (arm_cond_branch): Remove '*' to enable gen_arm_cond_branch.
14530
14531 2012-05-18  Meador Inge  <meadori@codesourcery.com>
14532
14533         PR rtl-optimization/53352
14534         * cse.c (equiv_constant): Ignore paradoxical subregs.
14535
14536 2012-05-17  Steven Bosscher  <steven@gcc.gnu.org>
14537
14538         PR rtl-optimization/53125
14539         * regstat.c (regstat_bb_compute_ri): Take new local_live_last_luid
14540         argument.  Simplify calculation of REG_LIVE_LENGTH for regnos that
14541         die in the basic block.  Correctly top off REG_FREQ and
14542         REG_FREQ_CALLS_CROSSED.
14543         Remove do_not_gen.
14544         (regstat_compute_ri): Allocate and free local_live_last_luid.
14545         Remove do_not_gen.
14546         (regstat_bb_compute_calls_crossed): Correctly top off
14547         REG_FREQ_CALLS_CROSSED.
14548
14549 2012-05-17  Jan Hubicka  <jh@suse.cz>
14550
14551         * lto-symtab.c (lto_symtab_resolve_symbols): Preffer decl with
14552         constructor over decl without.
14553         * cgraph.c (cgraph_remove_node): Clear also body of unanalyzed nodes.
14554         * cgraph.h (varpool_can_remove_if_no_refs): Handle external correctly.
14555         * cgraphunit.c (process_function_and_variable_attributes): Finalize
14556         extrnal decls.
14557         (mark_functions_to_output): Also accept bodies for functions with
14558         clones.
14559         (output_in_order): Skip external vars.
14560         * lto-cgraph.c (lto_output_node): External functions are never in other
14561         partition.
14562         (lto_output_varpool_node): Likewise.
14563         * lto-streamer-out.c (lto_write_tree): Always use error_mark_nodes for
14564         forgotten initializers.
14565         * ipa.c (process_references): Handle external vars.
14566         (symtab_remove_unreachable_nodes): Update to handle external vars.
14567         (varpool_externally_visible_p): External vars are externally visible.
14568         * gimple-fold.c (can_refer_decl_in_current_unit_p): Update.
14569         * varpool.c (varpool_remove_node): Remove constructor.
14570         (decide_is_variable_needed): Handle externals.
14571         (varpool_remove_unreferenced_decls): Likewise.
14572
14573 2012-05-17  Manuel López-Ibáñez  <manu@gcc.gnu.org>
14574
14575         * opts.c (common_handle_option): -pedantic-errors enables -Wpedantic.
14576         (enable_warning_as_error): Do not special case Wuninitialized.
14577         * optc-gen.awk: Add sanity checks.
14578
14579 2012-05-17  Jan Hubicka  <jh@suse.cz>
14580
14581         * ipa-reference.c (is_proper_for_analysis): Do not check flags
14582         that might change as result of global optimization.
14583         (analyze_function): Do not check analyzed and externally_visible
14584         flags; be happy about address dereferences.
14585         (propagate): Prune all_module_statics so it really contains just
14586         statics; prune all the local summaries.
14587         (ipa_reference_write_optimization_summary): Simplify.
14588
14589 2012-05-17  Kwok Cheung Yeung  <kcy@codesourcery.com>
14590
14591         * config/m68k/m68k-devices.def: Add 51ag, 51je, 51jf, 51jg, 51mm, 51qm.
14592         * config/m68k/m68k-tables.opt: Regenerated.
14593         * doc/invoke.texi (M680x0 Options): Document.
14594
14595 2012-05-16  Dave Boutcher  <daveboutcher@gmail.com>
14596             Patrick Marlier  <patrick.marlier@gmail.com>
14597
14598         * trans-mem.c (ipa_tm_transform_clone): Transform functions with
14599         indirect calls.
14600
14601 2012-05-16  H.J. Lu  <hongjiu.lu@intel.com>
14602
14603         * configure: Regenerated.
14604
14605 2012-05-16  Andrew Pinski  <apinski@cavium.com>
14606
14607         * gimple-fold.c (get_maxval_strlen): Move COND_EXPR handling under
14608         GIMPLE_ASSIGN.
14609
14610 2012-05-16  David S. Miller  <davem@davemloft.net>
14611
14612         * jump.c (delete_related_insns): If we remove a CALL, make sure
14613         we delete it's NOTE_INSN_CALL_ARG_LOCATION note too.
14614
14615 2012-05-16  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
14616
14617         PR tree-optimization/53217
14618         * tree-ssa-reassoc.c (bip_map): New static variable.
14619         (possibly_move_powi): Move feeding multiplies with __builtin_powi call.
14620         (attempt_builtin_powi): Save feeding multiplies on a stack.
14621         (reassociate_bb): Create and destroy bip_map.
14622
14623 2012-05-16  Olivier Hainque  <hainque@adacore.com>
14624
14625         * Makefile.in (install-no-fixedincludes): New target, former toplevel
14626         gcc-no-fixedincludes. Stash "include-fixed" in addition to "include".
14627         Add comments and improve stamp preservation across the whole sequence.
14628         (stmp-int-hdrs): Use move-if-change + cp -p to setup fix_dir/limits.h.
14629
14630 2012-05-16  Richard Guenther  <rguenther@suse.de>
14631
14632         * tree-inline.c (insert_init_stmt): Do not call
14633         mark_symbols_for_renaming.
14634         (setup_one_parameter): Avoid initializing unused parameters.
14635         (declare_return_variable): Properly handle DECL_BY_REFERENCE
14636         return vars in SSA form.
14637
14638 2012-05-16  Richard Guenther  <rguenther@suse.de>
14639
14640         * tree-flow.h (get_virtual_var): Remove.
14641         * tree-dfa.c (get_virtual_var): Likewise.
14642
14643 2012-05-16  Richard Guenther  <rguenther@suse.de>
14644
14645         * tree-vect-loop-manip.c (slpeel_update_phi_nodes_for_guard1):
14646         Remove set-only bitmap of new names.
14647         (slpeel_tree_peel_loop_to_edge): Likewise.  Do not set
14648         CFG hooks.
14649         * tree-flow.h (ssa_names_to_replace): Remove.
14650         * tree-into-ssa.c (ssa_names_to_replace): Likewise.
14651
14652 2012-05-16  Richard Guenther  <rguenther@suse.de>
14653
14654         PR tree-optimization/53364
14655         * tree-ssa-alias.c (indirect_ref_may_alias_decl_p): Properly
14656         detect a view-conversion of the decl.
14657
14658 2012-05-16  Dodji Seketeli  <dodji@redhat.com>
14659
14660         PR preprocessor/7263
14661         * c-tree.h (enum c_declspec_word): Declare new enum.
14662         (struct c_declspecs::locations): New member.
14663         (declspecs_add_qual, declspecs_add_scspec)
14664         (declspecs_add_addrspace, declspecs_add_alignas): Take a new
14665         location parameter.
14666         * c-decl.c (build_null_declspecs): Initialize the new struct
14667         c_declspecs::locations member.
14668         (declspecs_add_addrspace): Take a location parameter for the
14669         address space.  Store it onto declaration specifiers.
14670         (declspecs_add_qual): Likewise, take a location parameter for the
14671         qualifier.
14672         (declspecs_add_type): Likewise, take a location parameter for the
14673         type specifier.
14674         (declspecs_add_scspec): Likewise, take a location parameter for
14675         the storage class specifier.
14676         (declspecs_add_attrs): Likewise, take a location parameter for the
14677         first attribute.
14678         (declspecs_add_alignas): Likewise, take a location parameter for
14679         the alignas token.
14680         (finish_declspecs): For diagnostics, use the location of the
14681         relevant declspec, instead of the global input_location.
14682         * c-parser.c (c_parser_parameter_declaration): Pass the precise
14683         virtual location of the declspec to the declspecs-setters.
14684         (c_parser_declspecs): Likewise.  Avoid calling c_parser_peek_token
14685         repeatedly.
14686
14687 2012-05-16  Igor Zamyatin  <igor.zamyatin@intel.com>
14688
14689         * configure.ac: Stack protector enabling for Android targets.
14690         * configure: Regenerate.
14691
14692 2012-05-16  Richard Sandiford  <r.sandiford@uk.ibm.com>
14693
14694         * ira.c (pseudo_move_insn): Delete.
14695         (find_moveable_pseudos): Don't set it.
14696         (move_unallocated_pseudos): Use DF_REG_DEF_CHAIN to find
14697         the definitions of the original pseudo.  Delete all of them.
14698
14699 2012-05-16  Olivier Hainque  <hainque@adacore.com>
14700
14701         * config/rs6000/rs6000-opts.h (enum processor_type): Add
14702         PROCESSOR_PPC8548.
14703         * config/rs6000/rs6000-cpus.def: Reference it for cpu="8548".
14704         * config/rs6000/rs6000.md (cpu attribute definition): Add ppc8548.
14705         * config/rs6000/8540.md: indicate that the units/patterns apply to
14706         ppc8548 as well.
14707
14708         * config/rs6000/rs6000.c (rs6000_option_override_internal): Rename
14709         default_cpu into implicit_cpu, conveying what --with-cpu was passed at
14710         configure time. Treat implicit_cpu as have_CPU. Pick defaults for SPE
14711         related flags,  check that what is queried is supported by the selected
14712         configuration. Rework the single/double_float and MASK_STRING resets to
14713         hit for all the E500 cores (854x + E500MC variants). Select the ppc8540
14714         costs for PROCESSOR_PPC8548 as well.
14715         (rs6000_issue_rate): case CPU_PPC8548 together with CPU_PPC8540.
14716         (rs6000_use_sched_lookahead): Likewise, rewriting function as a case
14717         statement instead of a sequence of ifs.
14718
14719         * config/rs6000/rs6000.h (TARGET_E500): Remove.
14720         (TARGET_NO_LWSYNC): Adjust accordingly.
14721         * config/rs6000/e500.h (TARGET_E500): Remove.
14722         (CHECK_E500_OPTIONS): Adjust accordingly.
14723         * config/rs6000/eabispe.h (SUBSUBTARGET_OVERRIDE_OPTIONS): Remove.
14724         (TARGET_DEFAULT): Reformat definition to match the one in linuxspe.h.
14725         * config/rs6000/linuxspe.h: Likewise.
14726         * config/rs6000/vxworks.h: Remove bogus TARGET_E500 overrides and
14727         superfluous comments.
14728         * config/rs6000/e500-double.h: Remove.
14729
14730         * config.gcc (pick a default with_cpu): For powerpc*-*-*spe*,
14731         default to with_cpu=8548 if --enable-e500-double, and to 8540
14732         otherwise.
14733         (set misc flags section): For powerpc*|rs6000*, remove inclusion
14734         of e500-double.h for --enable-e500-double.
14735
14736 2012-05-16  Olivier Hainque  <hainque@adacore.com>
14737
14738         * Makefile.in (s-header-vars): Resort to -n instead of trailing
14739         -e d in sed invocation.
14740
14741 2012-05-16  Hans-Peter Nilsson  <hp@axis.com>
14742
14743         * doc/tm.texi.in (Type Layout) <SIZE_TYPE>: Update reference to
14744         source-code.
14745         * doc/tm.texi: Regenerate.
14746
14747 2012-05-15  Paolo Carlini  <paolo.carlini@oracle.com>
14748
14749         * tree.h (EXPR_LOCATION): Use CAN_HAVE_LOCATION_P.
14750
14751 2012-05-15  Jakub Jelinek  <jakub@redhat.com>
14752
14753         PR target/53358
14754         * config/i386/i386.md (*addqi_2 peephole with QImode addition): Check
14755         that operands[2] is either immediate, or q_regs_operand.
14756
14757 2012-05-15  Richard Guenther  <rguenther@suse.de>
14758
14759         * cgraphunit.c (thunk_adjust): Use make_rename_temp.
14760         (assemble_thunk): Likewise.  Manually rename and register
14761         function arguments.
14762
14763 2012-05-15  Richard Guenther  <rguenther@suse.de>
14764
14765         PR tree-optimization/53355
14766         * tree-vrp.c (extract_range_from_binary_expr_1): Handle LSHIFT_EXPRs
14767         by constants.
14768
14769 2012-05-15  Tristan Gingold  <gingold@adacore.com>
14770
14771         * tree-ssa-strlen.c (get_string_length): Convert lhs if needed.
14772
14773 2012-05-15  Richard Guenther  <rguenther@suse.de>
14774
14775         * gimple.c (gimple_set_modified): Move ...
14776         * gimple.h (gimple_set_modified): ... here.
14777
14778 2012-05-15  Tristan Gingold  <gingold@adacore.com>
14779
14780         * ira-color.c (move_spill_restore): Add a guard.
14781
14782 2012-05-15  Tristan Gingold  <gingold@adacore.com>
14783
14784         * config/ia64/ia64.c (ia64_emit_probe_stack_range): Adjust calls to
14785         plus_constant.
14786
14787 2012-05-15  Eric Botcazou  <ebotcazou@adacore.com>
14788
14789         * gimplify.c (gimplify_init_constructor): Do a block move for very
14790         small objects as well.
14791
14792 2012-05-15  Bernd Schmidt  <bernds@codesourcery.com>
14793
14794         * ira.c (find_moveable_pseudos): Skip registers whose
14795         DF_REG_EQ_USE_COUNT is nonzero.
14796
14797 2012-05-15  Kenneth Zadeck  <zadeck@naturalbridge.com>
14798
14799         * doc/md.texi (fma): Define to only be applicable for single rounding.
14800
14801 2012-05-14  Uros Bizjak  <ubizjak@gmail.com>
14802
14803         PR target/46098
14804         * config/i386/i386.c (ix86_expand_special_args_builtin): Always
14805         generate target register for "load" class builtins.
14806
14807         Revert:
14808         2010-10-22  Uros Bizjak  <ubizjak@gmail.com>
14809
14810         PR target/46098
14811         * config/i386/sse.md (*avx_movu<ssemodesuffix><avxmodesuffix>):
14812         Rename from avx_movu<ssemodesuffix><avxmodesuffix>.
14813         (avx_movu<ssemodesuffix><avxmodesuffix>): New expander.
14814         (*<sse>_movu<ssemodesuffix>): Rename from <sse>_movu<ssemodesuffix>.
14815         (<sse>_movu<ssemodesuffix>): New expander.
14816         (*avx_movdqu<avxmodesuffix>): Rename from avx_movdqu<avxmodesuffix>.
14817         (avx_movdqu<avxmodesuffix>): New expander.
14818         (*sse2_movdqu): Rename from sse2_movdqu.
14819         (sse2_movdqu): New expander.
14820
14821 2012-05-14  Marc Glisse  <marc.glisse@inria.fr>
14822
14823         PR target/52607
14824         * config/i386/i386.c (ix86_expand_vec_perm_const): Move code to ...
14825         (canonicalize_perm): ... new function.
14826         (expand_vec_perm_2vperm2f128_vshuf): New function.
14827         (ix86_expand_vec_perm_const_1): Call it.
14828
14829 2012-05-14  Andrew Pinski  <apinski@cavium.com>
14830             H.J. Lu  <hongjiu.lu@intel.com>
14831             Jakub Jelinek  <jakub@redhat.com>
14832
14833         PR target/53315
14834         * config/i386/i386.md (xbegin_1): Use + in constraint and match_dup.
14835         (xbegin): Updated.
14836
14837 2012-05-14  Jakub Jelinek  <jakub@redhat.com>
14838
14839         * dwarf2out.c (dwarf2out_define, dwarf2out_undef): Treat
14840         lineno 1 the same as lineno 0 before first start file directive.
14841         (optimize_macinfo_range): Likewise.
14842
14843         * dwarf2out.c (have_macinfo): Define.
14844         (dwarf2out_finish): Don't emit DW_AT_GNU_macros or DW_AT_macro_info
14845         attribute, don't force empty compilation unit and don't emit any
14846         .debug_macinfo/.debug_macro section if macinfo_table is empty.
14847
14848 2012-05-14  Georg-Johann Lay  <avr@gjlay.de>
14849
14850         PR target/53344
14851         * config/avr/avr.c (avr_const_address_lo16): Remove.
14852         (avr_assemble_integer):  Print ".byte lo8(x)",
14853         ".byte hi8(x)", ".byte hh8(x)" instead of emit an assembler
14854         .warning if 3-byte address is assembled.
14855         * doc/extend.texi (AVR Named Address Spaces): Document that
14856         binutils 2.23 is needed to assemble 3-byte addresses.
14857
14858 2012-05-14  Richard Guenther  <rguenther@suse.de>
14859
14860         * tree-vect-data-refs.c (vect_setup_realignment): Remove
14861         call to mark_symbols_for_renaming.
14862         (vect_permute_load_chain): Likewise.
14863         * tree-vect-loop.c (vect_is_slp_reduction): Update stmt
14864         instead of calling mark_symbols_for_renaming.
14865         * tree-vect-stmts.c (read_vector_array): Remove call to
14866         mark_symbols_for_renaming.
14867         (write_vector_array): Likewise.
14868         (vectorizable_call): Likewise.
14869         (vectorizable_store): Likewise.
14870         (vectorizable_load): Likewise.
14871         * matrix-reorg.c (transform_allocation_sites): Likewise.
14872         * tree-ssa-pre.c (create_expression_by_pieces): Likewise.
14873         (create_expression_by_pieces): Likewise.
14874
14875 2012-05-14  Richard Guenther  <rguenther@suse.de>
14876
14877         * gimplify.c (gimple_regimplify_operands): Only mark the LHS
14878         of statements for renaming.
14879         (force_gimple_operand_1): Likewise, consistently for both
14880         calls to force_gimple_operand and force_gimple_operand_gsi.
14881
14882 2012-05-14  Richard Guenther  <rguenther@suse.de>
14883
14884         * tree-dfa.c (make_rename_temp): Be forgiving if not in SSA form.
14885         * omp-low.c (expand_omp_taskreg): Properly conditionalize call
14886         to update_ssa.
14887         (expand_omp_for): Likewise.
14888         (expand_omp_for_generic): Adjust conditional add to referenced vars.
14889         Use make_rename_temp for temporaries that should be rewritten into
14890         SSA form.
14891         (expand_omp_for_static_nochunk): Likewise.
14892         (expand_omp_atomic_pipeline): Likewise.
14893
14894 2012-05-14  Richard Guenther  <rguenther@suse.de>
14895
14896         PR tree-optimization/53331
14897         * tree-vect-data-refs.c (vect_verify_datarefs_alignment): Ignore
14898         strided loads.
14899         * tree-vect-stmts.c (vect_model_load_cost): Handle strided loads.
14900
14901 2012-05-14  Manuel López-Ibáñez  <manu@gcc.gnu.org>
14902
14903         PR 53063
14904         * doc/options.texi: (LangEnabledBy): Document it.
14905         * optc-gen.awk: Handle LangEnabledBy.
14906         * opth-gen.awk: Generate declaration for lang-specific functions.
14907         * opt-read.awk: Record lang numbers.
14908         * opt-functions.awk (flag_set_p): Ignore the arguments of flags.
14909         (lang_sanitized_name): New.
14910
14911 2012-05-14  Bernd Schmidt  <bernds@codesourcery.com>
14912
14913         * attribs.c (decl_attributes): Avoid emitting a warning if
14914         ATTR_FLAG_BUILT_IN.
14915         * doc/rtl.texi (CALL_INSN_FUNCTION_USAGE): Use lowercase for rtx
14916         codes.  Document meaning of sets inside CALL_INSN_FUNCTION_USAGE.
14917         * builtin-attrs.def (DEF_ATTR_FOR_STRING): Define.  Use it to
14918         define a string "1".
14919         (ATTR_RET1_NOTHROW_NONNULL_LEAF): New attr definition.
14920         * builtins.def (BUILT_IN_MEMCPY, BUILT_IN_MEMMOVE, BUILT_IN_MEMSET,
14921         BUILT_IN_STRCPY): Use it for these functions.
14922         * postreload.c (reload_combine): Deal with SETs inside
14923         CALL_INSN_FUNCTION_USAGE.
14924         * caller-save.c (setup_save_areas, save_call_clobbered_regs):
14925         Look for REG_RETURNED notes and use a cheap restore if possible.
14926         * ira-int.h (struct ira_allocno): New member cheap_calls_crossed_num.
14927         (ALLOCNO_CHEAP_CALLS_CROSSED_NUM): New macro.
14928         * ira-build.c (ira_create_allocno, create_cap_allocno,
14929         propagate_allocno_info, propagate_some_info_from_allocno,
14930         copy_info_to_removed_store_destination, ira_flattening): Handle it.
14931         * ira-lives.c (pseudo_regno_single_word_and_live_p,
14932         find_call_crossed_cheap_reg): New static functions.
14933         (process_bb_node_lives): Look for SETs in CALL_INSN_FUNCTION_USAGE,
14934         and set ALLOCNO_CHEAP_CALLS_CROSSED_NUM if possible.  Also make
14935         a REG_RETURNED note in that case.
14936         * ira.c (setup_reg_renumber): Change assert to allow cases where
14937         allocnos only cross calls for which they are cheap to restore.
14938         * ira-costs.c (ira_tune_allocno_costs): Compare
14939         ALLOCNO_CALLS_CROSSED_NUM to ALLOCNO_CHEAP_CALLS_CROSSED_NUM rather
14940         than 0.
14941         * reg-notes.def (REG_RETURNED): New note.
14942         * cse.c (cse_insn): Likewise.
14943         * sched-deps.c (sched_analyze_insn): Likewise.
14944         * expr.c (init_block_move_fn): Set a "fn spec" attribute.
14945         * calls.c (decl_return_flags): New static function.
14946         (expand_call): Generate a SET in CALL_INSN_FUNCTION_USAGE for
14947         functions that return one of their arguments.
14948         * regcprop.c (struct kill_set_value_data): New.
14949         (kill_set_value): Interpret data as a pointer to such a struct.
14950         Do nothing if the caller wants the register to be ignored.
14951         (copyprop_hardreg_forward_1): Handle SETs in CALL_INSN_FUNCTION_USAGE.
14952
14953 2012-05-14  Richard Guenther  <rguenther@suse.de>
14954
14955         PR tree-optimization/53340
14956         * tree-ssa-pre.c (op_valid_in_sets): Fix error in last commit.
14957
14958 2012-05-14  Richard Guenther  <rguenther@suse.de>
14959
14960         * gimplify.c (gimplify_expr): Remove odd code.
14961
14962 2012-05-14  Eric Botcazou  <ebotcazou@adacore.com>
14963
14964         * stor-layout.c (bit_from_pos): Distribute conversion to bitsizetype
14965         into a PLUS_EXPR byte offset.
14966
14967         * tree-ssa-pre.c (can_value_number_call): Delete.
14968         (compute_avail): Skip all statements with side effects.
14969         <GIMPLE_CALL>: Skip calls to internal functions.
14970
14971 2012-05-13  Steven Bosscher  <steven@gcc.gnu.org>
14972
14973         * config/pa/pa.md: Use define_c_enum for "unspec" and "unspecv".
14974
14975 2012-05-13  Manuel López-Ibáñez  <manu@gcc.gnu.org>
14976
14977         * common.opt (Wtype-limits): Use EnabledBy.
14978
14979 2012-05-13  Uros Bizjak  <ubizjak@gmail.com>
14980
14981         * config/i386/i386.md (*pushtf): Enable for TARGET_SSE.
14982         (pushtf splitter): Ditto.
14983         (movtf): Ditto.
14984         (*movtf_internal): Ditto. Use V4SFmode for !TARGET_SSE2.
14985         (<code>tf2): Enable for TARGET_SSE.
14986         (*absnegtf2_sse): Ditto.
14987         (copysign<mode>3): Enable TFmode for TARGET_SSE.
14988         (copysign<mode>3_const): Ditto.
14989         (copysign<mode>3_var): Ditto.
14990         * config/i386/sse.md (<code>tf3): Enable for TARGET_SSE.
14991         (*andnottf3): Ditto.  Use V4SFmode for !TARGET_SSE2.
14992         (*<code>tf3): Ditto.
14993         * config/i386/i386.c (struct builtin_description bdesc_args)
14994         <IX86_BUILTIN_FABSQ>: Enable for TARGET_SSE.
14995         <IX86_BUILTIN_COPYSIGNQ>: Ditto.
14996         (ix86_expand_builtin) <IX86_BUILTIN_FABSQ, IX86_BUILTIN_COPYSIGNQ>:
14997         Emit a normal call if SSE isn't available.
14998
14999 2012-05-13  Uros Bizjak  <ubizjak@gmail.com>
15000
15001         * config/i386/sse.md (<sse>_andnot<mode>3): Handle
15002         TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL.
15003         (<code><mode>3): Ditto.
15004         (*andnot<mode>3): Ditto.
15005         (*andnottf3): Ditto.
15006         (*<code><mode>3): Ditto.
15007         (<code>tf3): Ditto.
15008
15009 2012-05-13  Manuel López-Ibáñez  <manu@gcc.gnu.org>
15010
15011         * optc-gen.awk: Error instead of warning for conflicting help.
15012
15013 2012-05-12  Jason Merrill  <jason@redhat.com>
15014
15015         PR debug/53235
15016         * dwarf2out.c (build_local_stub): Prefer DW_AT_signature for
15017         comdat types.
15018
15019 2012-05-12  Eric Botcazou  <ebotcazou@adacore.com>
15020
15021         * function.c (requires_stack_frame_p): If the function can throw
15022         non-call exceptions, return true if the insn can throw internally.
15023
15024 2012-05-12  Paolo Carlini  <paolo.carlini@oracle.com>
15025
15026         * doc/generic.texi: Rename TYPE_PTRMEM_P to TYPE_PTRDATAMEM_P.
15027
15028 2012-05-12  Uros Bizjak  <ubizjak@gmail.com>
15029
15030         * config/alpha/alpha.c (alpha_emit_conditional_branch): Handle
15031         ORDERED and UNORDERED conditions.
15032
15033 2012-05-11  Richard Guenther  <rguenther@suse.de>
15034
15035         * tree-flow.h (referenced_var_check_and_insert): Remove.
15036         (find_new_referenced_vars): Likewise.
15037         * tree-dfa.c (referenced_var_check_and_insert): Make static.
15038         (find_new_referenced_vars_1, find_new_referenced_vars): Remove.
15039         * tree-inline.c (copy_bb): Use find_referenced_vars_in
15040         instead of find_new_referenced_vars.
15041         * gimple-fold.c (gimplify_and_update_call_from_tree): Likewise.
15042
15043 2012-05-11  Richard Guenther  <rguenther@suse.de>
15044
15045         * tree-pass.h (pass_rest_of_compilation,
15046         pass_all_optimizations, pass_postreload, pass_all_early_optimizations):
15047         Remove.
15048         * passes.c (pass_all_optimizations, pass_postreload,
15049         pass_all_early_optimizations): Make static.
15050         (pass_rest_of_compilation): Likewise.  Make it an RTL_PASS.
15051         * tree-phinodes.c (init_phinodes, fini_phinodes): Remove.
15052         * tree-ssa.c (init_tree_ssa): Do not call init_phinodes.
15053         (delete_tree_ssa): Do not call fini_phinodes.
15054         * tree-flow.h (init_phinodes, fini_phinodes): Remove.
15055
15056 2012-05-11  Manuel López-Ibáñez  <manu@gcc.gnu.org>
15057
15058         PR 53063
15059         * doc/options.texi (EnabledBy): Document
15060         * opts.c: Include opts.h and options.h before tm.h.
15061         (finish_options): Do not handle some sub-options here...
15062         (common_handle_option): ... instead call common_handle_option_auto
15063         here.
15064         * optc-gen.awk: Handle EnabledBy.
15065         * opth-gen.awk: Declare common_handle_option_auto.
15066         * common.opt (Wuninitialized): Use EnabledBy. Delete Init.
15067         (Wmaybe-uninitialized): Likewise.
15068         (Wunused-but-set-variable): Likewise.
15069         (Wunused-function): Likewise.
15070         (Wunused-label): Likewise.
15071         (Wunused-value): Likewise.
15072         (Wunused-variable): Likewise.
15073         * opt-read.awk: Create opt_numbers array.
15074
15075 2012-05-11  Richard Guenther  <rguenther@suse.de>
15076
15077         PR tree-optimization/53295
15078         * tree-data-ref.h (stride_of_unit_type_p): Handle non-constant
15079         strides.
15080         * tree-data-ref.c (dr_analyze_innermost): Allow non-constant
15081         strides when analyzing data-references in a loop context.
15082         * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test): Reject
15083         non-constant strides for now.
15084         (vect_enhance_data_refs_alignment): Ignore data references
15085         that are strided loads.
15086         (vect_analyze_data_ref_access): Handle non-constant strides.
15087         (vect_check_strided_load): Verify the data-reference is a load.
15088         (vect_analyze_data_refs): Restructure to make strided load
15089         support not dependent on gather support.
15090         * tree-vect-stmts.c (vectorizable_load): Avoid useless work
15091         when doing strided or gather loads.
15092         * tree-vect-loop-manip.c (vect_vfa_segment_size): Use
15093         integer_zerop to compare stride with zero.
15094
15095 2012-05-11  H.J. Lu  <hongjiu.lu@intel.com>
15096
15097         * config/i386/driver-i386.c (host_detect_local_cpu): Support RTM.
15098
15099 2012-05-11  Jan Hubicka  <jh@suse.cz>
15100
15101         PR bootstrap/53300
15102         * varpool.c (varpool_assemble_decl): Also output constat pool entries
15103         that output_constant_pool missed.
15104
15105 2012-05-11  Mingjie Xing  <mingjie.xing@gmail.com>
15106
15107         * config/mips/t-vxworks: Change MUTLILIB_EXTRA_OPTS to
15108         MULTILIB_EXTRA_OPTS.
15109
15110 2012-05-11  Uros Bizjak  <ubizjak@gmail.com>
15111
15112         PR target/53291
15113         * config/i386/i386.md (xtest): Use NE condition in ix86_expand_setcc.
15114
15115 2012-05-11  Uros Bizjak  <ubizjak@gmail.com>
15116
15117         * config/i386/i386.md (*movti_internal_rex64): Avoid MOVAPS size
15118         optimization for TARGET_AVX.
15119         (*movti_internal_sse): Ditto.
15120         (*movdi_internal_rex64): Handle TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL.
15121         (*movdi_internal): Ditto.
15122         (*movsi_internal): Ditto.
15123         (*movtf_internal): Avoid MOVAPS size optimization for TARGET_AVX.
15124         (*movdf_internal_rex64): Ditto.
15125         (*movfd_internal): Ditto.
15126         (*movsf_internal): Ditto.
15127         * config/i386/sse.md (mov<mode>): Handle TARGET_SSE_LOAD0_BY_PXOR.
15128
15129 2012-05-10  Eric Botcazou  <ebotcazou@adacore.com>
15130
15131         * dwarf2out.c (add_byte_size_attribute) <RECORD_TYPE>: Handle variable
15132         reference as size attribute.
15133
15134 2012-05-10  Eric Botcazou  <ebotcazou@adacore.com>
15135             Tristan Gingold  <gingold@adacore.com>
15136
15137         * doc/md.texi (Standard Names): Document probe_stack_address.
15138         * explow.c (emit_stack_probe): Handle probe_stack_address.
15139         * config/ia64/ia64.md (UNSPECV_PROBE_STACK_ADDRESS): New constant.
15140         (UNSPECV_PROBE_STACK_RANGE): Likewise.
15141         (probe_stack_address): New insn.
15142         (probe_stack_range): Likewise.
15143         * config/ia64/ia64.c: Include common/common-target.h.
15144         (ia64_compute_frame_size): Mark r2 and r3 as used if static stack
15145         checking is enabled.
15146         (ia64_emit_probe_stack_range): New function.
15147         (output_probe_stack_range): Likewise.
15148         (ia64_expand_prologue): Invoke ia64_emit_probe_stack_range if static
15149         builtin stack checking is enabled.
15150         (rtx_needs_barrier) <UNSPEC_VOLATILE>: Handle UNSPECV_PROBE_STACK_RANGE
15151         and UNSPECV_PROBE_STACK_ADDRESS.
15152         (unknown_for_bundling_p): New predicate.
15153         (group_barrier_needed): Use important_for_bundling_p.
15154         (ia64_dfa_new_cycle): Use unknown_for_bundling_p.
15155         (issue_nops_and_insn): Likewise.
15156         (bundling): Likewise.
15157         (final_emit_insn_group_barriers): Likewise.
15158         * config/ia64/ia64-protos.h (output_probe_stack_range): Declare.
15159         * config/ia64/hpux.h (STACK_CHECK_STATIC_BUILTIN): Define.
15160         (STACK_CHECK_PROTECT): Likewise.
15161         * config/ia64/linux.h (STACK_CHECK_STATIC_BUILTIN): Likewise.
15162
15163 2012-05-10  Jan Hubicka  <jh@suse.cz>
15164
15165         * ipa-inline.c (update_all_callee_keys): Remove.
15166         (inline_small_functions): Simplify priority updating.
15167
15168 2012-05-10  Jan Hubicka  <jh@suse.cz>
15169
15170         * ipa.c (symtab_remove_unreachable_nodes): Fix marking of clones.
15171
15172 2012-05-10  Jan Hubicka  <jh@suse.cz>
15173
15174         * cgraph.h (cgraph_remove_unreachable_nodes): Rename to ...
15175         (symtab_remove_unreachable_nodes): ... this one.
15176         * ipa-cp.c (ipcp_driver): Do not remove unreachable nodes.
15177         * cgraphunit.c (ipa_passes): Update.
15178         * cgraphclones.c (cgraph_materialize_all_clones): Update.
15179         * cgraph.c (cgraph_release_function_body): Only turn initial
15180         into error mark when initial was previously set.
15181         * ipa-inline.c (ipa_inline): Update.
15182         * ipa.c: Include ipa-inline.h
15183         (enqueue_cgraph_node, enqueue_varpool_node): Remove.
15184         (enqueue_node): New function.
15185         (process_references): Update.
15186         (symtab_remove_unreachable_nodes): Cleanup.
15187         * passes.c (execute_todo, execute_one_pass): Update.
15188
15189 2012-05-10  Vladimir Makarov  <vmakarov@redhat.com>
15190
15191         PR rtl-optimization/53125
15192         * ira.c (ira): Call find_moveable_pseudos and
15193         move_unallocated_pseudos if only ira_conflicts_p is true.
15194
15195 2012-05-10  Uros Bizjak  <ubizjak@gmail.com>
15196
15197         * config/i386/i386.md (*movoi_internal_avx): Handle
15198         TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL and TARGET_SSE_TYPELESS_STORES.
15199         (*movti_internal_rex64): Handle TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL.
15200         (*movti_internal_sse): Ditto.
15201         (*movtf_internal): Ditto.
15202         * config/i386/sse.md (ssePSmode): New mode attribute.
15203         (*move<mode>_internal): Use ssePSmode.
15204         (*<sse>_movu<ssemodesuffix><avxsizesuffix>): Ditto.
15205         (*<sse2>_movdqu<avxsizesuffix>): Ditto.
15206         * config/i386/i386.c (standard_sse_constant_opcode): Do not handle
15207         TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL here.
15208
15209 2012-05-10  Eric Botcazou  <ebotcazou@adacore.com>
15210
15211         * gimplify.c (gimplify_decl_expr): For a TYPE_DECL, also gimplify the
15212         DECL_ORIGINAL_TYPE if it is present.
15213
15214 2012-05-10  Nick Clifton  <nickc@redhat.com>
15215
15216         PR target/53120
15217         * config/m32c/bitops.md (bset_qi): Change operand 2 from having
15218         a "0" constraint to being a (match_dup 0).
15219
15220 2012-05-10  Richard Guenther  <rguenther@suse.de>
15221
15222         * stor-layout.c (byte_from_pos): Amend comment.
15223
15224 2012-05-10  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
15225
15226         * doc/extend.texi (X86 Built-in Functions, __builtin_cpu_init):
15227         Document requirement to call in constructors.
15228
15229         * config/i386/i386.c: Update comments for i386-cpuinfo.c name change.
15230
15231 2012-05-10  Richard Guenther  <rguenther@suse.de>
15232
15233         * tree.h (TYPE_IS_SIZETYPE): Remove.
15234         * fold-const.c (int_const_binop_1): Remove TYPE_IS_SIZETYPE use.
15235         (extract_muldiv_1): Likewise.
15236         * gimple.c (gtc_visit): Likewise.
15237         (gimple_types_compatible_p): Likewise.
15238         (iterative_hash_canonical_type): Likewise.
15239         (gimple_canonical_types_compatible_p): Likewise.
15240         * gimplify.c (gimplify_one_sizepos): Likewise.
15241         * print-tree.c (print_node): Likewise.
15242         * stor-layout.c (initialize_sizetypes): Do not set TYPE_IS_SIZETYPE.
15243
15244 2012-05-09  Uros Bizjak  <ubizjak@gmail.com>
15245
15246         PR target/52908
15247         * config/i386/sse.md (vec_widen_smult_hi_v4si): Expand using
15248         xop_pmacsdqh insn pattern instead of xop_mulv2div2di3_high.
15249         (vec_widen_smult_lo_v4si): Expand using xop_pmacsdql insn pattern
15250         instead of xop_mulv2div2di3_low.
15251         (xop_p<macs>dql): Fix vec_select selector.
15252         (xop_p<macs>dqh): Ditto.
15253         (xop_mulv2div2di3_low): Remove insn_and_split pattern.
15254         (xop_mulv2div2di3_high): Ditto.
15255
15256 2012-05-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
15257
15258         PR c++/53289
15259         * diagnostic.h (diagnostic_context): Add last_location.
15260         * diagnostic.c (diagnostic_initialize): Initialize it.
15261         (diagnostic_show_locus): Use it.
15262
15263 2012-05-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
15264
15265         * doc/extend.texi (Function Attributes): Point xref to section
15266         about Pragmas.
15267
15268 2012-05-09  Uros Bizjak  <ubizjak@gmail.com>
15269
15270         * config/i386/i386.c (*movdf_internal_rex64): Remove
15271         TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL handling from asm output code.
15272         Calculate "mode" attribute according to
15273         TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL flag.
15274         (*movdf_internal): Ditto.
15275
15276 2012-05-09  Uros Bizjak  <ubizjak@gmail.com>
15277
15278         PR target/44141
15279         * config/i386/i386.c (ix86_expand_vector_move_misalign): Do not handle
15280         128 bit vectors specially for TARGET_AVX.  Emit sse2_movupd and
15281         sse_movupd RTXes for TARGET_AVX, TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL
15282         or when optimizing for size.
15283         * config/i386/sse.md (*mov<mode>_internal): Remove
15284         TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL handling from asm output code.
15285         Calculate "mode" attribute according to optimize_function_for_size_p
15286         and TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL flag.
15287         (*<sse>_movu<ssemodesuffix><avxsizesuffix>): Choose asm template
15288         depending on the mode of the instruction.  Calculate "mode" attribute
15289         according to optimize_function_for_size_p, TARGET_SSE_TYPELESS_STORES
15290         and TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL flags.
15291         (*<sse2>_movdqu<avxsizesuffix>): Ditto.
15292
15293 2012-05-09  Georg-Johann Lay  <avr@gjlay.de>
15294
15295         PR target/53256
15296         * config/avr/elf.h (ASM_DECLARE_FUNCTION_NAME): Remove.
15297         * config/avr/avr-protos.h (avr_asm_declare_function_name): Remove.
15298         * config/avr/avr.h (struct machine_function): Add attributes_checked_p.
15299         * config/avr/avr.c (avr_asm_declare_function_name): Remove.
15300         (expand_prologue): Move initialization of cfun->machine->is_naked,
15301         is_interrupt, is_signal, is_OS_task, is_OS_main from here to...
15302         (avr_set_current_function): ...this new static function.
15303         (TARGET_SET_CURRENT_FUNCTION): New define.
15304         (avr_function_ok_for_sibcall): Use cfun->machine->is_* instead of
15305         checking attributes of current_function_decl.
15306         (avr_regs_to_save): Ditto.
15307         (signal_function_p): Rename to avr_signal_function_p.
15308         (interrupt_function_p): Rename to avr_interrupt_function_p.
15309
15310         * doc/extend.texi (Function Attributes): Better explanation of
15311         'interrupt' and 'signal' for AVR. Move 'ifunc' down to establish
15312         alphabetical order.
15313
15314 2012-05-09  Michael Matz  <matz@suse.de>
15315
15316         PR tree-optimization/53185
15317         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Disable
15318         peeling when we see strided loads.
15319
15320 2012-05-09  Matthias Klose  <doko@ubuntu.com>
15321
15322         * gcc-ar.c (main): Don't check for execute bits for the plugin.
15323
15324 2012-05-09  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
15325
15326         * tree-ssa-loop-ivopts.c (add_autoinc_candidates, get_address_cost):
15327         Replace use of HAVE_{POST/PRE}_{INCREMENT/DECREMENT} with
15328         USE_{LOAD/STORE}_{PRE/POST}_{INCREMENT/DECREMENT} appropriately.
15329         * config/arm/arm.h (ARM_AUTOINC_VALID_FOR_MODE_P): New.
15330         (USE_LOAD_POST_INCREMENT): Define.
15331         (USE_LOAD_PRE_INCREMENT): Define.
15332         (USE_LOAD_POST_DECREMENT): Define.
15333         (USE_LOAD_PRE_DECREMENT): Define.
15334         (USE_STORE_PRE_DECREMENT): Define.
15335         (USE_STORE_PRE_INCREMENT): Define.
15336         (USE_STORE_POST_DECREMENT): Define.
15337         (USE_STORE_POST_INCREMENT): Define.
15338         (arm_auto_incmodes): Add enumeration.
15339         * config/arm/arm-protos.h (arm_autoinc_modes_ok_p): Declare.
15340         * config/arm/arm.c (arm_autoinc_modes_ok_p): Define.
15341
15342 2012-05-09  Jakub Jelinek  <jakub@redhat.com>
15343
15344         PR tree-optimization/53226
15345         * tree-ssa-forwprop.c (ssa_forward_propagate_and_combine): Remove
15346         prev and prev_initialized vars, gimple_set_plf (stmt, GF_PLF_1, false)
15347         before processing it and gimple_set_plf (stmt, GF_PLF_1, true) if it
15348         doesn't need to be revisited, look for earliest stmt with
15349         !gimple_plf (stmt, GF_PLF_1) if something changed.
15350
15351 2012-05-09  Terry Guo  <terry.guo@arm.com>
15352
15353         * genmultilib: Update copyright dates.
15354         * doc/fragments.texi: Ditto.
15355
15356 2012-05-09  Terry Guo  <terry.guo@arm.com>
15357
15358         * Makefile.in (s-mlib): Add new argument MULTILIB_REQUIRED.
15359         * genmultilib (MULTILIB_REQUIRED): New.
15360         * doc/fragments.texi: Document the MULTILIB_REQUIRED.
15361
15362 2012-05-09  Richard Guenther  <rguenther@suse.de>
15363
15364         * tree-vectorizer.h (vect_loop_versioning): Adjust prototype.
15365         (vect_do_peeling_for_loop_bound): Likewise.
15366         (vect_do_peeling_for_alignment): Likewise.
15367         * tree-vect-loop-manip.c (conservative_cost_threshold): Remove.
15368         (vect_do_peeling_for_loop_bound): Get check_profitability and
15369         threshold as parameters.
15370         (vect_do_peeling_for_alignment): Likewise.
15371         (vect_loop_versioning): Likewise.
15372         * tree-vect-loop.c (vect_transform_loop): Compute check_profitability
15373         and threshold here.  Control where to put the check here.
15374
15375 2012-05-09  Richard Sandiford  <rdsandiford@googlemail.com>
15376
15377         PR middle-end/53249
15378         * dwarf2out.h (get_address_mode): Move declaration to...
15379         * rtl.h: ...here.
15380         * dwarf2out.c (get_address_mode): Move definition to...
15381         * rtlanal.c: ...here.
15382         * var-tracking.c (get_address_mode): Delete.
15383         * combine.c (find_split_point): Use get_address_mode instead of
15384         targetm.addr_space.address_mode.
15385         * cselib.c (cselib_record_sets): Likewise.
15386         * dse.c (canon_address, record_store): Likewise.
15387         * emit-rtl.c (adjust_address_1, offset_address): Likewise.
15388         * expr.c (move_by_pieces, emit_block_move_via_loop, store_by_pieces)
15389         (store_by_pieces_1, expand_assignment, store_expr, store_constructor)
15390         (expand_expr_real_1): Likewise.
15391         * ifcvt.c (noce_try_cmove_arith): Likewise.
15392         * optabs.c (maybe_legitimize_operand_same_code): Likewise.
15393         * reload.c (find_reloads): Likewise.
15394         * sched-deps.c (sched_analyze_1, sched_analyze_2): Likewise.
15395         * sel-sched-dump.c (debug_mem_addr_value): Likewise.
15396
15397 2012-05-09  Maciej W. Rozycki  <macro@codesourcery.com>
15398
15399         * config/mips/mips.c (mips16_gp_pseudo_reg): Remove line
15400         information from the instruction produced.
15401
15402 2012-05-09  Richard Guenther  <rguenther@suse.de>
15403
15404         * stor-layout.c (bit_from_pos): Document.
15405         (byte_from_pos): Likewise.  Optimize.
15406         (pos_from_bit): Likewise.
15407         (normalize_offset): Use pos_from_bit instead of replicating it.
15408
15409 2012-05-09  Alan Modra  <amodra@gmail.com>
15410
15411         PR target/53271
15412         * config/rs6000/rs6000.c (gen_frame_set): New function.
15413         (gen_frame_load, gen_frame_store): New functions.
15414         (rs6000_savres_rtx): Use the above.
15415         (rs6000_emit_epilogue, rs6000_emit_prologue): Here too.
15416         Correct mode used for CR2 in save/restore_world patterns.
15417         Don't emit instructions for eh_return frame unwind reg info.
15418
15419 2012-05-08  Jan Hubicka  <jh@suse.cz>
15420
15421         * cgraphbuild.c (build_cgraph_edges): Do not finalize vars
15422         with VALUE_EXPR.
15423         * cgraph.h (varpool_can_remove_if_no_refs): Vars with VALUE_EXPR
15424         are removable.
15425         * toplev.c (wrapup_global_declaration_2): Vars with VALUE_EXPR
15426         need to wrapup.
15427         (compile_file): Do not output variables.
15428         * cgraphbuild.c (varpool_finalize_decl): When var is finalized late,
15429         output it.
15430         * langhooks.c: Include timevar.h
15431         (write_global_declarations): Finalize compilation unit after wrapup;
15432         set timevars correctly.
15433         * passes.c (rest_of_decl_compilation): Decls with VALUE_EXPR needs
15434         not to be added to varpool.
15435         * varpool.c (varpool_assemble_decl): Sanity check that we are called
15436         only on cases where it makes sense; skip constant pool and value expr
15437         vars.
15438
15439 2012-05-08  David S. Miller  <davem@davemloft.net>
15440
15441         * config/sparc/linux.h (LINK_SPEC): Don't pass "-Y" option.
15442         * config/sparc/linux64.h (LINK_ARCH32_SPEC): Likewise.
15443         * config/sparc/linux64.h (LINK_ARCH64_SPEC): Likewise.
15444
15445 2012-05-08  Richard Sandiford  <rdsandiford@googlemail.com>
15446
15447         PR rtl-optimization/53278
15448         * lower-subreg.c (decompose_multiword_subregs): Remove left-over
15449         speed_p code from earlier patch.
15450
15451 2012-05-08  Oleg Endo  <olegendo@gcc.gnu.org>
15452
15453         PR target/51244
15454         * config/sh/sh.md (*branch_true, *branch_false): New insns.
15455
15456 2012-05-08  Teresa Johnson  <tejohnson@google.com>
15457
15458         * gcov-io.h (__gcov_reset, __gcov_dump): Declare.
15459         * doc/gcov.texi: Add note on using __gcov_reset and __gcov_dump.
15460
15461 2012-05-08  Jan Hubicka  <jh@suse.cz>
15462
15463         * cgraph.c (cgraph_call_edge_duplication_hooks): Export.
15464         (cgraph_create_node_1): Rename to ...
15465         (cgraph_create_empty_node): ... this one; export.
15466         (cgraph_create_node): Update.
15467         (cgraph_set_call_stmt_including_clones): Move to cgraphclones.c
15468         (cgraph_create_edge_including_clones): Likewise.
15469         (cgraph_find_replacement_node): Likewise.
15470         (cgraph_clone_edge): Likewise.
15471         (cgraph_clone_node): Likewise.
15472         (clone_function_name): Likewise.
15473         (cgraph_create_virtual_clone): Likewise.
15474         (cgraph_remove_node_and_inline_clones): Likewise.
15475         (cgraph_redirect_edge_call_stmt_to_callee): Move here from cgraphunit.c
15476         * cgraph.h: Reorder declarations so they match file of origin.
15477         (cgraph_create_empty_node): Declare.
15478         * cgraphunit.c (update_call_expr): Move to cgraphclones.c
15479         (cgraph_copy_node_for_versioning): Likewise.
15480         (cgraph_function_versioning): Likewise.
15481         (cgraph_materialize_clone): Likewise.
15482         (cgraph_redirect_edge_call_stmt_to_callee): Likewise.
15483         (cgraph_materialize_all_clones): Likewise.
15484         * cgraphclones.c: New file.
15485         * Makefile.in: Update for cgraphclones.
15486
15487 2012-05-08  Uros Bizjak  <ubizjak@gmail.com>
15488
15489         PR target/53176
15490         * config/i386/i386.c (ix86_set_reg_reg_cost): New function.
15491         (ix86_rtx_costs): Handle SET.
15492
15493 2012-05-08  Michael Matz  <matz@suse.de>
15494
15495         * basic-block.h (struct rtl_bb_info): Remove visited member and
15496         move head_ member to ...
15497         (struct basic_block_def.basic_block_il_dependent): ... the new
15498         member x, replacing but containing old member rtl.
15499         (enum bb_flags): New BB_VISITED flag.
15500         (BB_HEADER, BB_FOOTER): New macros.
15501
15502         * jump.c (mark_all_labels): Adjust.
15503         * cfgcleanup.c (try_optimize_cfg): Adjust.
15504         * cfglayout.c (record_effective_endpoints): Adjust.
15505         (relink_block_chain): Ditto (and don't fiddle with visited).
15506         (fixup_reorder_chain): Adjust.
15507         (fixup_fallthru_exit_predecessor): Ditto.
15508         (cfg_layout_duplicate_bb): Ditto.
15509         * combine.c (update_cfg_for_uncondjump): Adjust.
15510         * bb-reorder.c (struct bbro_basic_block_data_def): Add visited member.
15511         (bb_visited_trace): New accessor.
15512         (mark_bb_visited): Move in front.
15513         (rotate_loop): Use bb_visited_trace.
15514         (find_traces_1_round): Ditto.
15515         (emit_barrier_after): Ditto.
15516         (copy_bb): Ditto, and initialize visited on resize.
15517         (reorder_basic_blocks): Initize visited member.
15518         (duplicate_computed_gotos): Clear bb flags at start, use
15519         BB_VISITED flags.
15520
15521         * cfgrtl.c (try_redirect_by_replacing_jump): Adjust.
15522         (rtl_verify_flow_info_1): Ditto.
15523         (cfg_layout_split_block): Ditto.
15524         (cfg_layout_delete_block): Ditto.
15525         (cfg_layout_merge_blocks): Ditto.
15526         (init_rtl_bb_info): Adjust and initialize il.x.head_ member.
15527
15528 2012-05-08  Hans-Peter Nilsson  <hp@axis.com>
15529
15530         PR target/53272
15531         * config/cris/cris.c (cris_normal_notice_update_cc): For TARGET_V32,
15532         when a constant source operand matches an "I" constraint, the "no
15533         CC0 change" applies to a register-destination only, not a
15534         strict_low_part-destination.
15535
15536 2012-05-08  Richard Guenther  <rguenther@suse.de>
15537
15538         * fold-const.c (fold_binary_loc): Fold (X * CST1) & CST2
15539         to zero or to (X * CST1) & CST2' when CST1 has trailing zeros.
15540
15541 2012-05-08  Georg-Johann Lay  <avr@gjlay.de>
15542
15543         * Makefile.in (TEXI_GCC_FILES): Add avr-mmcu.texi.
15544
15545         * doc/avr-mmcu.texi: New auto-generated file.
15546         * doc/invoke.texi (AVR Options): Include avr-mmcu.texi in order
15547         to document all valid -mmcu= arguments.
15548
15549         * config/avr/avr.h (arch_info_s): New struct definition.
15550         * config/avr/avr-devices.c (avr_texinfo): New variable.
15551         * config/avr/gen-avr-mmcu-texi.c: New file.
15552         * config/avr/t-avr: New rules and dependencies to build avr-mmcu.texi.
15553
15554 2012-05-08  Dehao Chen  <dehao@google.com>
15555
15556         * predict.c (find_qualified_ssa_name): New.
15557         (find_ssa_name_in_expr): New.
15558         (find_ssa_name_in_assign_stmt): New.
15559         (is_comparison_with_loop_invariant_p): New.
15560         (is_bound_expr_similar): New.
15561         (predict_iv_comparison): New.
15562         (predict_loops): Add heuristic for loop-nested branches that compare an
15563         induction variable to a loop bound variable.
15564         * predict.def (PRED_LOOP_IV_COMPARE): New macro.
15565
15566 2012-05-08  Uros Bizjak  <ubizjak@gmail.com>
15567
15568         * config/i386/i386.c (has_dispatch): Use TARGET_BDVER1 and
15569         TARGET_BDVER2 defines where appropriate.
15570
15571 2012-05-07  Eric Botcazou  <ebotcazou@adacore.com>
15572
15573         * configure.ac (PLUGIN_LD): Rename into...
15574         (PLUGIN_LD_SUFFIX): ...this and strip the target_alias triplet.
15575         * config.in: Regenerate.
15576         * configure: Likewise.
15577         * collect2.c (main): Set plugin_ld_suffix to PLUGIN_LD_SUFFIX.
15578
15579 2012-05-07  Eric Botcazou  <ebotcazou@adacore.com>
15580
15581         * tree-dfa.c (get_ref_base_and_extent) <ARRAY_REF>: Do the offset
15582         computation using the precision of the index type.
15583         * gimple-fold.c (fold_const_aggregate_ref_1) <ARRAY_REF>: Likewise.
15584         (fold_array_ctor_reference): Do index computations in the index type.
15585
15586 2012-05-07  Georg-Johann Lay  <avr@gjlay.de>
15587
15588         * config/avr/avr.c (avr_prologue_setup_frame): Fix mode passed
15589         down to plus_constant.
15590         (expand_epilogue): Ditto.
15591
15592 2012-05-07  Steven Bosscher  <steven@gcc.gnu.org>
15593
15594         * postreload.c (reload_cse_regs): Make static.
15595         * reload.h (reload_cse_regs): Remove prototype.
15596
15597 2012-05-07  Richard Henderson  <rth@redhat.com>
15598
15599         * config/alpha/alpha.md (clear_cache): New pattern.
15600
15601 2012-05-07  Steven Bosscher  <steven@gcc.gnu.org>
15602
15603         PR middle-end/53245
15604         * gimplify.c (preprocess_case_label_vec_for_gimple): If low or high
15605         is folded to a type boundary value, verify that the resulting case
15606         label is still a care range.
15607
15608 2012-05-07  Uros Bizjak  <ubizjak@gmail.com>
15609
15610         * config/i386/i386.md (ctz<mode>2): Emit rep;bsf
15611         only for TARGET_GENERIC, when not optimizing for size.
15612         (*ffs<mode>_1): Ditto.
15613
15614 2012-05-07  Steven Bosscher  <steven@gcc.gnu.org>
15615
15616         * tree-cfg.c (verify_gimple_switch): Tighten checks.
15617
15618 2012-05-07  Jakub Jelinek  <jakub@redhat.com>
15619
15620         PR tree-optimization/53239
15621         * tree-vrp.c (get_value_range): Set VR of SSA_NAME_IS_DEFAULT_DEF
15622         of DECL_BY_REFERENCE RESULT_DECL to nonnull.
15623
15624 2012-05-07  Richard Guenther  <rguenther@suse.de>
15625
15626         PR tree-optimization/53195
15627         * tree-inline.c (setup_one_parameter): Properly add referenced
15628         vars from the parameters new known value.
15629
15630 2012-05-07  Steven Bosscher  <steven@gcc.gnu.org>
15631
15632         * config/m68k/m68k.c (m68k_sched_branch_type): Remove.
15633         (sched_branch_type): Remove.
15634         (m68k_sched_md_init_global): Don't allocate it.
15635         (m68k_sched_md_finish_global): Don't free it.
15636         * config/m68k/m68k.h (m68k_sched_branch_type): Remove prototype.
15637         * config/m68k/m68k.md: Set the type of insns using
15638         m68k_sched_branch_type to bcc directly.
15639
15640 2012-05-07  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
15641
15642         * config/sol2.c (solaris_override_options): New function.
15643         * config/sol2-protos.h (solaris_override_options): Declare.
15644         * config/sol2.h (SUBTARGET_OVERRIDE_OPTIONS): Define.
15645
15646 2012-05-07  Richard Guenther  <rguenther@suse.de>
15647
15648         * tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Return
15649         whether we failed to compute data dependences.
15650         (loop_prefetch_arrays): Fail if we failed.
15651
15652 2012-05-07  Uros Bizjak  <ubizjak@gmail.com>
15653             Paolo Bonzini  <bonzini@gnu.org>
15654
15655         * config/i386/i386.md (ctz<mode>2): Emit rep;bsf even for !TARGET_BMI.
15656         Emit bsf when optimizing for size.
15657         (*ffs<mode>_1): Ditto.
15658
15659 2012-05-07  Oleg Endo  <olegendo@gcc.gnu.org>
15660
15661         PR target/53250
15662         * config/sh/sh.c (sh_rtx_costs): Handle SET.
15663
15664 2012-05-06  Uros Bizjak  <ubizjak@gmail.com>
15665
15666         PR target/53227
15667         * config/i386/i386.md (swap<mode>): Rename from *swap<mode>.
15668         (bswapdi2): Split from bswap<mode>2.  Use nonnimediate_operand
15669         predicate for operand 1.  Force operand 1 to register for TARGET_BSWAP.
15670         (bswapsi2): Ditto.
15671         (*bswapdi2_doubleword): New insn pattern.
15672         (*bswap<mode>2): Rename from *bswap<mode>2_1.
15673
15674 2012-05-06  Richard Sandiford  <rdsandiford@googlemail.com>
15675
15676         * config/mips/mips.c (mips_set_reg_reg_piece_cost): New function.
15677         (mips_set_reg_reg_cost): Likewise.
15678         (mips_rtx_costs): Handle SET.
15679
15680 2012-05-06  Richard Sandiford  <rdsandiford@googlemail.com>
15681
15682         * lower-subreg.c (shift_cost): Use set_src_cost, avoiding the SET.
15683         (compute_costs): Likewise for the zero extension.  Use set_rtx_cost
15684         to compute the cost of moves.  Set the mode of the target register.
15685
15686 2012-05-05  Richard Sandiford  <rdsandiford@googlemail.com>
15687
15688         * rtl.h (plus_constant, plus_constant_mode): Merge into a single
15689         plus_constant function.
15690         * explow.c (plus_constant, plus_constant_mode): Likewise.  Assert
15691         that the mode is sensible.
15692         (use_anchored_address, round_push, allocate_dynamic_stack_space)
15693         (probe_stack_range, anti_adjust_stack_and_probe): Update calls to
15694         plus_constant.
15695
15696         * alias.c (canon_rtx): Likewise.
15697         (init_alias_analysis): Likewise.
15698         * builtins.c (expand_builtin_return_addr)
15699         (expand_builtin_setjmp_setup, expand_builtin_longjmp)
15700         (expand_builtin_nonlocal_goto, expand_builtin_update_setjmp_buf)
15701         (expand_builtin_apply_args_1, expand_builtin_apply, expand_movstr)
15702         (expand_builtin_stpcpy): Likewise.
15703         * calls.c (save_fixed_argument_area, restore_fixed_argument_area)
15704         (compute_argument_addresses, internal_arg_pointer_based_exp)
15705         (expand_call, emit_library_call_value_1): Likewise.
15706         * cfgexpand.c (expand_one_stack_var_at, expand_debug_expr): Likewise.
15707         * combine-stack-adj.c (try_apply_stack_adjustment): Likewise.
15708         * combine.c (combine_simplify_rtx, force_to_mode): Likewise.
15709         * cse.c (insert_const_anchor, find_reg_offset_for_const)
15710         (use_related_value, fold_rtx): Likewise.
15711         * cselib.c (cselib_subst_to_values): Likewise.
15712         * dse.c (record_store, check_mem_read_rtx): Likewise.
15713         * dwarf2out.c (rtl_for_decl_location, gen_variable_die): Likewise.
15714         * emit-rtl.c (adjust_address_1): Likewise.
15715         * except.c (sjlj_emit_function_enter)
15716         (expand_builtin_extract_return_addr)
15717         (expand_builtin_frob_return_addr): Likewise.
15718         * expmed.c (expand_divmod): Likewise.
15719         * expr.c (move_by_pieces, store_by_pieces, store_by_pieces_1)
15720         (emit_move_resolve_push, push_block, emit_push_insn, store_expr)
15721         (expand_expr_addr_expr_1, expand_expr_real_1): Likewise.
15722         * function.c (assign_stack_local_1)
15723         (instantiate_virtual_regs_in_rtx): Likewise.
15724         * optabs.c (prepare_cmp_insn): Likewise.
15725         * recog.c (offsettable_address_addr_space_p): Likewise.
15726         * reload.c (find_reloads_address, form_sum)
15727         (find_reloads_subreg_address): Likewise.
15728         * reload1.c (init_reload, eliminate_regs_1)
15729         (eliminate_regs_in_insn): Likewise.
15730         * simplify-rtx.c (simplify_unary_operation_1)
15731         (simplify_binary_operation_1, simplify_plus_minus): Likewise.
15732         * var-tracking.c (compute_cfa_pointer, prepare_call_arguments)
15733         (vt_add_function_parameter): Likewise.
15734
15735         * config/alpha/alpha.h (EH_RETURN_HANDLER_RTX): Likewise.
15736         * config/alpha/vms.h (EH_RETURN_HANDLER_RTX): Likewise.
15737         * config/alpha/alpha.c (alpha_legitimize_address_1)
15738         (get_unaligned_address, alpha_expand_unaligned_load)
15739         (alpha_expand_unaligned_store, alpha_expand_unaligned_load_words)
15740         (alpha_expand_unaligned_store_words, alpha_expand_block_clear)
15741         (alpha_expand_builtin_establish_vms_condition_handler)
15742         (alpha_setup_incoming_varargs, emit_frame_store_1)
15743         (alpha_expand_prologue, alpha_expand_epilogue)
15744         (alpha_use_linkage): Likewise.
15745         * config/alpha/alpha.md: Likewise.
15746
15747         * config/arm/arm.c (arm_trampoline_init, legitimize_pic_address)
15748         (arm_load_pic_register, arm_pic_static_addr, arm_legitimize_address)
15749         (thumb_legitimize_address, arm_gen_load_multiple_1)
15750         (arm_gen_store_multiple_1, arm_gen_multiple_op, gen_ldm_seq)
15751         (gen_stm_seq, gen_const_stm_seq, arm_block_move_unaligned_straight)
15752         (arm_block_move_unaligned_loop, arm_gen_movmemqi, arm_reload_in_hi)
15753         (arm_reload_out_hi, arm_reorg, vfp_emit_fstmd, emit_multi_reg_push)
15754         (emit_sfm, thumb_set_frame_pointer, arm_expand_prologue)
15755         (thumb1_emit_multi_reg_push, thumb1_expand_prologue)
15756         (thumb_expand_movmemqi, arm_set_return_address)
15757         (thumb_set_return_address): Likewise.
15758         * config/arm/arm.md: Likewise.
15759
15760         * config/avr/avr.c (avr_incoming_return_addr_rtx)
15761         (avr_prologue_setup_frame, expand_epilogue)
15762         (avr_const_address_lo16): Likewise.
15763
15764         * config/bfin/bfin.h (EH_RETURN_HANDLER_RTX): Likewise.
15765         * config/bfin/bfin.c (setup_incoming_varargs, bfin_load_pic_reg)
15766         (bfin_expand_prologue, bfin_trampoline_init, bfin_expand_call)
15767         (bfin_output_mi_thunk): Likewise.
15768
15769         * config/c6x/c6x.c (c6x_initialize_trampoline)
15770         (c6x_output_mi_thunk): Likewise.
15771
15772         * config/cr16/cr16.h (EH_RETURN_HANDLER_RTX): Likewise.
15773         * config/cr16/cr16.c (cr16_create_dwarf_for_multi_push): Likewise.
15774
15775         * config/cris/cris.c (cris_return_addr_rtx, cris_split_movdx)
15776         (cris_expand_prologue, cris_expand_epilogue, cris_gen_movem_load)
15777         (cris_emit_movem_store, cris_trampoline_init): Likewise.
15778         * config/cris/cris.md: Likewise.
15779
15780         * config/darwin.c (machopic_indirect_data_reference)
15781         (machopic_legitimize_pic_address): Likewise.
15782
15783         * config/epiphany/epiphany.c (epiphany_emit_save_restore)
15784         (epiphany_expand_prologue, epiphany_expand_epilogue)
15785         (epiphany_trampoline_init): Likewise.
15786         * config/epiphany/epiphany.md: Likewise.
15787
15788         * config/fr30/fr30.c (fr30_move_double): Likewise.
15789
15790         * config/frv/frv.c (frv_dwarf_store, frv_expand_prologue)
15791         (frv_expand_block_move, frv_expand_block_clear, frv_return_addr_rtx)
15792         (frv_index_memory, unspec_got_name, frv_find_base_term)
15793         (frv_output_dwarf_dtprel): Likewise.
15794
15795         * config/h8300/h8300.c (h8300_push_pop, h8300_return_addr_rtx)
15796         (h8300_swap_into_er6, h8300_swap_out_of_er6): Likewise.
15797
15798         * config/i386/i386.h (RETURN_ADDR_RTX): Likewise.
15799         * config/i386/i386.c (setup_incoming_varargs_64)
15800         (setup_incoming_varargs_ms_64, choose_baseaddr)
15801         (ix86_emit_save_reg_using_mov, ix86_adjust_stack_and_probe)
15802         (ix86_emit_probe_stack_range, ix86_expand_prologue)
15803         (ix86_emit_restore_reg_using_pop, ix86_emit_leave)
15804         (ix86_expand_epilogue, legitimize_pic_address, ix86_legitimize_address)
15805         (ix86_split_long_move, ix86_expand_movmem, ix86_expand_setmem)
15806         (ix86_static_chain, ix86_trampoline_init, x86_this_parameter)
15807         (x86_output_mi_thunk): Likewise.
15808         * config/i386/i386.md: Likewise.
15809
15810         * config/ia64/ia64.c (ia64_expand_load_address)
15811         (ia64_expand_tls_address, ia64_expand_move, ia64_split_tmode)
15812         (do_spill, ia64_trampoline_init): Likewise.
15813
15814         * config/iq2000/iq2000.c (iq2000_va_start)
15815         (iq2000_emit_frame_related_store, iq2000_expand_prologue)
15816         (iq2000_expand_eh_return, iq2000_setup_incoming_varargs)
15817         (iq2000_print_operand, iq2000_legitimize_address): Likewise.
15818
15819         * config/lm32/lm32.c (lm32_setup_incoming_varargs): Likewise.
15820
15821         * config/m32c/m32c.c (m32c_return_addr_rtx)
15822         (m32c_expand_insv): Likewise.
15823
15824         * config/m32r/m32r.c (m32r_setup_incoming_varargs)
15825         (m32r_legitimize_pic_address, m32r_print_operand)
15826         (m32r_print_operand_address): Likewise.
15827
15828         * config/m68k/linux.h (FINALIZE_TRAMPOLINE): Likewise.
15829         * config/m68k/m68k.h (RETURN_ADDR_RTX): Likewise.
15830         (EH_RETURN_HANDLER_RTX): Likewise.
15831         * config/m68k/m68k.c (m68k_emit_movem, m68k_expand_prologue)
15832         (m68k_expand_epilogue, legitimize_pic_address)
15833         (m68k_output_mi_thunk): Likewise.
15834         * config/m68k/m68k.md: Likewise.
15835
15836         * config/mcore/mcore.c (mcore_expand_prolog): Likewise.
15837         (mcore_expand_epilog): Likewise.
15838         * config/mcore/mcore.md: Likewise.
15839
15840         * config/mep/mep.c (mep_allocate_initial_value)
15841         (mep_expand_prologue, mep_expand_epilogue): Likewise.
15842
15843         * config/microblaze/microblaze.c (double_memory_operand)
15844         (microblaze_block_move_loop): Likewise.
15845
15846         * config/mips/mips.c (mips_strip_unspec_address, mips_add_offset)
15847         (mips_setup_incoming_varargs, mips_va_start, mips_block_move_loop)
15848         (mips_print_operand, mips16e_save_restore_reg, mips_save_restore_reg)
15849         (mips_expand_prologue, mips_epilogue_set_cfa)
15850         (mips_expand_epilogue): Likewise.
15851         * config/mips/mips.md: Likewise.
15852
15853         * config/mmix/mmix.c (mmix_dynamic_chain_address, mmix_return_addr_rtx)
15854         (mmix_expand_prologue, mmix_expand_epilogue): Likewise.
15855
15856         * config/mn10300/mn10300.c (mn10300_gen_multiple_store)
15857         (mn10300_builtin_saveregs, mn10300_trampoline_init): Likewise.
15858
15859         * config/moxie/moxie.h (INCOMING_RETURN_ADDR_RTX): Likewise.
15860         (EH_RETURN_HANDLER_RTX): Likewise.
15861         * config/moxie/moxie.c (moxie_static_chain): Likewise.
15862
15863         * config/pa/pa.c (legitimize_pic_address, hppa_legitimize_address)
15864         (store_reg, set_reg_plus_d, pa_expand_prologue, load_reg)
15865         (pa_return_addr_rtx, hppa_builtin_saveregs)
15866         (pa_trampoline_init): Likewise.
15867         * config/pa/pa.md: Likewise.
15868
15869         * config/pdp11/pdp11.c (pdp11_expand_epilogue): Likewise.
15870
15871         * config/picochip/picochip.c (picochip_static_chain): Likewise.
15872
15873         * config/rs6000/rs6000.h (RS6000_SAVE_TOC): Likewise.
15874         * config/rs6000/rs6000.c (rs6000_legitimize_address)
15875         (setup_incoming_varargs, print_operand, rs6000_return_addr)
15876         (rs6000_emit_eh_reg_restore, rs6000_emit_probe_stack_range)
15877         (rs6000_emit_epilogue)
15878         (rs6000_machopic_legitimize_pic_address): Likewise.
15879
15880         * config/rx/rx.c (gen_rx_rtsd_vector, gen_rx_popm_vector): Likewise.
15881
15882         * config/s390/s390.h (INITIAL_FRAME_ADDRESS_RTX): Likewise.
15883         (DYNAMIC_CHAIN_ADDRESS): Likewise.
15884         * config/s390/s390.c (s390_decompose_address, legitimize_pic_address)
15885         (s390_delegitimize_address, print_operand, annotate_constant_pool_refs)
15886         (replace_constant_pool_ref, s390_return_addr_rtx, s390_back_chain_rtx)
15887         (save_fpr, restore_fpr, save_gprs, restore_gprs, s390_emit_prologue)
15888         (s390_emit_epilogue, s390_function_profiler): Likewise.
15889         * config/s390/s390.md: Likewise.
15890
15891         * config/score/score.c (score_add_offset, score_prologue): Likewise.
15892
15893         * config/sh/sh.c (expand_block_move, push_regs, sh_builtin_saveregs)
15894         (sh_output_mi_thunk): Likewise.
15895         * config/sh/sh.md: Likewise.
15896
15897         * config/sparc/sparc.h (DYNAMIC_CHAIN_ADDRESS, FRAME_ADDR_RTX)
15898         (RETURN_ADDR_RTX, INCOMING_RETURN_ADDR_RTX): Likewise.
15899         * config/sparc/sparc.c (sparc_legitimize_pic_address)
15900         (sparc_emit_probe_stack_range, emit_save_or_restore_regs)
15901         (emit_window_save, sparc_flat_expand_prologue, sparc_struct_value_rtx)
15902         (emit_and_preserve): Likewise.
15903         * config/sparc/sparc.md: Likewise.
15904
15905         * config/spu/spu.h (DYNAMIC_CHAIN_ADDRESS): Likewise.
15906         * config/spu/spu.c (spu_expand_insv, spu_machine_dependent_reorg)
15907         (spu_setup_incoming_varargs, ea_load_store_inline)
15908         (spu_expand_load): Likewise.
15909
15910         * config/stormy16/stormy16.c (xstormy16_expand_prologue)
15911         (combine_bnp): Likewise.
15912
15913         * config/tilegx/tilegx.h (DYNAMIC_CHAIN_ADDRESS): Likewise.
15914         * config/tilegx/tilegx.c (tilegx_setup_incoming_varargs)
15915         (tilegx_expand_unaligned_load, tilegx_trampoline_init): Likewise.
15916
15917         * config/tilepro/tilepro.h (DYNAMIC_CHAIN_ADDRESS): Likewise.
15918         * config/tilepro/tilepro.c (tilepro_setup_incoming_varargs)
15919         (tilepro_expand_unaligned_load, tilepro_trampoline_init): Likewise.
15920
15921         * config/v850/v850.c (expand_prologue, expand_epilogue): Likewise.
15922         * config/v850/v850.md: Likewise.
15923
15924         * config/vax/elf.h (EH_RETURN_STACKADJ_RTX): Likewise.
15925         (EH_RETURN_HANDLER_RTX): Likewise.
15926         * config/vax/vax.h (DYNAMIC_CHAIN_ADDRESS, RETURN_ADDR_RTX): Likewise.
15927         * config/vax/vax.c (vax_add_reg_cfa_offset, vax_expand_prologue)
15928         (print_operand_address, vax_trampoline_init): Likewise.
15929
15930         * config/xtensa/xtensa.c (xtensa_expand_prologue, xtensa_return_addr)
15931         (xtensa_function_value_regno_p): Likewise.
15932
15933 2012-05-04  Andrew Pinski  <apinski@cavium.com>
15934
15935         * expr.c (get_def_for_expr_class): New function.
15936         (convert_tree_comp_to_rtx): New function.
15937         (expand_cond_expr_using_cmove): New function.
15938         (expand_expr_real_2 <case COND_EXPR>): Call
15939         expand_cond_expr_using_cmove first and return if it succeeds.
15940         Remove the check for HAVE_conditional_move since we should have
15941         already converted it to a conditional move.
15942         * config/i386/i386.c (ix86_expand_int_movcc): Disallow comparison
15943         modes of DImode for 32bits and TImode.
15944
15945 2012-05-04  Steven Bosscher  <steven@gcc.gnu.org>
15946
15947         PR other/29442
15948         * read-md.c (fprint_md_ptr_loc, fprint_c_condition): New functions.
15949         (print_md_ptr_loc, print_c_condition): Use them.
15950         * read-md.h (fprint_md_ptr_loc, fprint_c_condition): New prototypes.
15951         * genattrtab.c (attr_file_name, dfa_file_name, latency_file_name,
15952         attr_file, dfa_file, latency_file): New global variables.
15953         (write_attr_valueq, write_attr_set, write_attr_case, write_attr_value,
15954         write_upcase, write_indent, write_length_unit_log, write_test_expr,
15955         write_attr_get, write_insn_cases, write_eligible_delay,
15956         write_const_num_delay_slots): Accept FILE pointer and toss it around.
15957         Update all callers.
15958         (write_header, open_outfile, handle_arg): New funcions.
15959         (make_automaton_attrs): Write prototypes as extern to the output
15960         files.
15961         (main): Use init_rtx_reader_args_cb with handle_arg to take 3 file
15962         names from the command line.  Open the output files and write out
15963         internal functions for DFA functions to dfa_file_name, insn latency
15964         functions to latency_file_name, and everything else to attr_file.
15965         * Makefile.in (OBJS): Add insn-dfatab.o and insn-latencytab.o.
15966         (BACKEND): Build libbackend first.
15967         (MOSTLYCLEANFILES): Add insn-dfatab.c and insn-latencytab.c.
15968         (.PRECIOUS): Likewise.
15969         (insn-dfatab.o): New rule.
15970         (insn-latencytab.o): New rule.
15971         (simple_rtl_generated_c): Do not include insn-attrtab.c.
15972         (s-attrtab): New rule.
15973
15974 2012-05-04  Steven Bosscher  <steven@gcc.gnu.org>
15975
15976         * rtl.def (ATTR_FLAG): Remove probability indicating flags.
15977         * genattr.c (main): Remove ATTR_FLAG_likely, ATTR_FLAG_unlikely,
15978         ATTR_FLAG_very_likely, and ATTR_FLAG_very_unlikely.
15979         * reorg.c (get_jump_flags): Do not set the removed flags.
15980
15981         * doc/md.texi (attr_flag): Update for abovementioned changes.
15982
15983 2012-05-04  Uros Bizjak  <ubizjak@gmail.com>
15984
15985         PR target/53228
15986         * config/i386/i386.h (X86_ARCH_CMOV): Rename from X86_ARCH_CMOVE.
15987         (TARGET_CMOV): Rename from TARGET_CMOVE.
15988         (TARGET_CMOVE): New define.
15989         * config/i386/i386.c (ix86_option_override_internal): Use TARGET_CMOV.
15990         Do not set TARGET_CMOVE here.
15991
15992 2012-05-04  Dodji Seketeli  <dodji@redhat.com>
15993
15994         Enable -Wunused-local-typedefs when -Wall or -Wunused is on
15995         * opts.c (finish_options): Activate -Wunused-local-typedefs if
15996         -Wunused is activated.
15997         * doc/invoke.texi: Update blurb of -Wunused-local-typedefs.
15998
15999 2012-05-04  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
16000
16001         * config/s390/s390.md (*movmem_short, *clrmem_short)
16002         (*cmpmem_short): Move the mode check from the insn condition to
16003         the match_scratch.
16004
16005 2012-05-04  Ulrich Weigand  <ulrich.weigand@linaro.org>
16006
16007         PR tree-optimization/52633
16008         * tree-vect-patterns.c (vect_vect_recog_func_ptrs): Swap order of
16009         vect_recog_widen_shift_pattern and vect_recog_over_widening_pattern.
16010         (vect_recog_over_widening_pattern): Remove handling of code that was
16011         already detected as over-widening pattern.  Remove special handling
16012         of "unsigned" cases.  Instead, support general case of conversion
16013         of the shift result to another type.
16014
16015 2012-05-04  Ulrich Weigand  <ulrich.weigand@linaro.org>
16016
16017         * tree-vect-patterns.c (vect_single_imm_use): New function.
16018         (vect_recog_widen_mult_pattern): Use it instead of open-coding loop.
16019         (vect_recog_over_widening_pattern): Likewise.
16020         (vect_recog_widen_shift_pattern): Likewise.
16021
16022 2012-05-04  Ulrich Weigand  <ulrich.weigand@linaro.org>
16023
16024         * tree-vect-patterns.c (vect_same_loop_or_bb_p): New function.
16025         (vect_handle_widen_op_by_const): Use it instead of open-coding test.
16026         (vect_recog_widen_mult_pattern): Likewise.
16027         (vect_operation_fits_smaller_type): Likewise.
16028         (vect_recog_over_widening_pattern): Likewise.
16029         (vect_recog_widen_shift_pattern): Add to vect_same_loop_or_bb_p test.
16030
16031 2012-05-04  Richard Guenther  <rguenther@suse.de>
16032
16033         PR lto/50602
16034         * lto-wrapper.c (merge_and_complain): Complain about mismatches
16035         of -freg-struct-return and -fpcc-struct-return.
16036         (run_gcc): Pass through -freg-struct-return and -fpcc-struct-return
16037         from the input file options and ignore those from the link
16038         command line.
16039
16040 2012-05-04  Richard Guenther  <rguenther@suse.de>
16041
16042         PR tree-optimization/53168
16043         * tree-ssa-pre.c (phi_translate_1): Only handle type-punned
16044         memory reads when the result is a constant we can pun.
16045
16046 2012-05-04  Richard Guenther  <rguenther@suse.de>
16047
16048         * common.opt (flto-report): Do not mark as Optimization.
16049
16050 2012-05-04  Eric Botcazou  <ebotcazou@adacore.com>
16051
16052         PR target/48496
16053         * recog.c (constrain_operands): If extra constraints are present, also
16054         accept pseudo-registers with equivalent memory locations during reload.
16055
16056 2012-05-04  Olivier Hainque  <hainque@adacore.com>
16057
16058         * collect2.c (may_unlink_output_file): New global.
16059         (maybe_unlink): Honor it.
16060         * collect2.h: Add extern for it.
16061         * tlink.c (do_tlink): Set it to true if the link succeeded.
16062
16063 2012-05-04  Olivier Hainque  <hainque@adacore.com>
16064
16065         * gcc.c (eval_spec_function): Finalize/restore the current string
16066         obstack state as part of the context push/pop operations.
16067
16068 2012-05-04  Bin Cheng  <bin.cheng@arm.com>
16069
16070         PR rtl-optimization/52804
16071         * reload1.c (reload_reg_reaches_end_p): Check whether successor
16072         reload with type RELOAD_FOR_INPUT_ADDRESS kills reload register
16073         of current one with type RELOAD_FOR_INPADDR_ADDRESS.
16074         Same stands for reloads with type RELOAD_FOR_OUTPUT_ADDRESS and
16075         RELOAD_FOR_OUTADDR_ADDRESS.
16076
16077 2012-05-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
16078
16079         PR c++/24985
16080         * tree-diagnostic.c (maybe_unwind_expanded_macro_loc): Show caret
16081         for macro expansion.
16082
16083 2012-05-03  Manuel López-Ibáñez  <manu@gcc.gnu.org>
16084
16085         * flags.h (flag_permissive): Do not declare.
16086         * diagnostic.c (diagnostic_report_diagnostic): Handle fpermissive
16087         option specially.
16088         * toplev.c (flag_permissive): Do not define.
16089         * c-tree.h (system_header_p): Delete unused.
16090
16091 2012-05-03  David S. Miller  <davem@davemloft.net>
16092
16093         PR target/52684
16094         * config/sparc/sparc.c (emit_soft_tfmode_libcall): If we pass a
16095         MEM directly into a libcall, mark it's MEM_EXPR as addressable.
16096         (sparc_emit_float_lib_cmp): Likewise.
16097
16098 2012-05-03  Michael Meissner  <meissner@linux.vnet.ibm.com>
16099
16100         PR target/53199
16101         * config/rs6000/rs6000.md (bswapdi splitters): If
16102         -mavoid-indexed-addresses (or -mcpu=power6 which sets it by
16103         default) is used, generate an alternate sequence that does not
16104         depend on using indexed addressing.
16105
16106 2012-05-03  Jason Merrill  <jason@redhat.com>
16107
16108         * gengtype.c (write_types): Fix warning message.
16109         (write_local): Likewise.
16110
16111 2012-05-02  Jason Merrill  <jason@redhat.com>
16112
16113         * dwarf2out.c (struct external_ref, build_local_stub): New.
16114         (hash_external_ref, external_ref_eq, lookup_external_ref): New.
16115         (optimize_external_refs, optimize_external_refs_1): New.
16116         (change_AT_die_ref): New.
16117         (clone_as_declaration): Add DW_AT_signature when cloning a declaration.
16118         (build_abbrev_table): Take the external refs hashtable.
16119         (output_comp_unit): Get it from optimize_external_refs and pass it in.
16120
16121 2012-05-03  Jan Hubicka  <jh@suse.cz>
16122
16123         PR middle-end/53093
16124         * tree-emutls.c (new_emutls_decl): Fix handling of aliases.
16125
16126 2012-05-03  Jan Hubicka  <jh@suse.cz>
16127
16128         PR middle-end/53106
16129         * ipa.c (cgraph_remove_unreachable_nodes): Fix handling of clones.
16130
16131 2012-05-03  Jason Merrill  <jason@redhat.com>
16132
16133         * dwarf2out.c (die_struct): Add comdat_type_p flag.  Use it instead of
16134         use_debug_types to discriminate the die_id union.
16135         (print_die, assign_symbol_names, copy_decls_walk): Likewise.
16136         (build_abbrev_table, output_die): Likewise.
16137         (prune_unused_types_walk_attribs): Likewise.
16138         (generate_type_signature, copy_declaration_context): Set it.
16139         (remove_child_or_replace_with_skeleton): Set it.
16140         (dwarf2out_start_source_file, dwarf2out_end_source_file): Don't
16141         check use_debug_types.
16142         (dwarf2out_finish): Do break_out_includes after .debug_types.
16143
16144 2012-05-03  Jason Merrill  <jason@redhat.com>
16145
16146         * dwarf2out.c (modified_type_die): Use scope_die_for.
16147         (gen_type_die_with_usage, dwarf2out_finish): Likewise.
16148         (uses_local_type_r, uses_local_type): New.
16149         (scope_die_for): Keep a type that uses a local type in local scope.
16150         Use get_context_die for namespace and type scope.
16151
16152 2012-05-03  Jason Merrill  <jason@redhat.com>
16153
16154         * config/i386/i386.c (ix86_code_end): Set DECL_IGNORED_P on the
16155         pc thunk.
16156         * dwarf2out.c (output_aranges): Skip DECL_IGNORED_P functions.
16157         (dwarf2out_finish): Likewise.
16158
16159 2012-05-03  Martin Jambor  <mjambor@suse.cz>
16160
16161         * builtins.c (get_object_alignment_1): Return whether we can determine
16162         the alignment or conservatively assume byte alignment.  Return the
16163         alignment by reference.  Use get_pointer_alignment_1 for dereference
16164         alignment.
16165         (get_pointer_alignment_1): Return whether we can determine the
16166         alignment or conservatively assume byte alignment.  Return the
16167         alignment by reference.  Use get_ptr_info_alignment to get SSA name
16168         alignment.
16169         (get_object_alignment): Update call to get_object_alignment_1.
16170         (get_object_or_type_alignment): Likewise, fall back to type alignment
16171         only when it returned false.
16172         (get_pointer_alignment): Update call to get_pointer_alignment_1.
16173         * fold-const.c (get_pointer_modulus_and_residue): Update call to
16174         get_object_alignment_1.
16175         * ipa-prop.c (ipa_modify_call_arguments): Update call to
16176         get_pointer_alignment_1.
16177         * tree-sra.c (build_ref_for_offset): Likewise, fall back to the type
16178         of MEM_REF or TARGET_MEM_REF only when it returns false.
16179         * tree-ssa-ccp.c (get_value_from_alignment): Update call to
16180         get_object_alignment_1.
16181         (ccp_finalize): Use set_ptr_info_alignment.
16182         * tree.h (get_object_alignment_1): Update declaration.
16183         (get_pointer_alignment_1): Likewise.
16184         * gimple-pretty-print.c (dump_gimple_phi): Use get_ptr_info_alignment.
16185         (dump_gimple_stmt): Likewise.
16186         * tree-flow.h (ptr_info_def): Updated comments of fields align and
16187         misalign.
16188         (get_ptr_info_alignment): Declared.
16189         (mark_ptr_info_alignment_unknown): Likewise.
16190         (set_ptr_info_alignment): Likewise.
16191         (adjust_ptr_info_misalignment): Likewise.
16192         * tree-ssa-address.c (copy_ref_info): Use new access functions to get
16193         and set alignment of SSA names.
16194         * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Call
16195         mark_ptr_info_alignment_unknown.
16196         * tree-ssanames.c (get_ptr_info_alignment): New function.
16197         (mark_ptr_info_alignment_unknown): Likewise.
16198         (set_ptr_info_alignment): Likewise.
16199         (adjust_ptr_info_misalignment): Likewise.
16200         (get_ptr_info): Call mark_ptr_info_alignment_unknown.
16201         * tree-vect-data-refs.c (vect_create_addr_base_for_vector_ref):
16202         Likewise.
16203         (bump_vector_ptr): Likewise.
16204         * tree-vect-stmts.c (create_array_ref): Use set_ptr_info_alignment.
16205         (vectorizable_store): Likewise.
16206         (vectorizable_load): Likewise.
16207
16208 2012-05-03  Michael Matz  <matz@suse.de>
16209
16210         * basic-block.h (struct rtl_bb_info, struct gimple_bb_info): Move
16211         in front of basic_block_def.
16212         (struct basic_block_def): Make il.gimple the full struct, not a
16213         pointer.
16214         (__assert_gimple_bb_smaller_rtl_bb): Asserting typedef.
16215
16216         * cfgexpand.c (expand_gimple_basic_block): Clear all il.gimple members.
16217         * gimple-iterator.c (gimple_stmt_iterator): Don't special case
16218         NULL il.gimple, which can't happen anymore.
16219         * gimple.h (bb_seq): il.gimple can't be NULL.
16220         (bb_seq_add): Ditto.
16221         (set_bb_seq): Adjust.
16222         (gsi_start_bb, gsi_last_bb): Tidy.
16223         * lto-streamer-in.c (make_new_block): Don't zero members that
16224         are zeroed already, don't allocate a gimple_bb_info.
16225         * tree-cfg.c (create_bb): Don't allocate a gimple_bb_info.
16226         (remove_bb): Clear all il.gimple members.
16227         (gimple_verify_flow_info): Adjust for flat il.gimple.
16228         * tree-flow-inline.h (phi_nodes, phi_nodes_ptr, set_phi_nodes): Adjust.
16229
16230         * coretypes.h (const_gimple_seq): Remove typedef.
16231         * gimple.h (gimple_seq_first): Take gimple_seq.
16232         (gimple_seq_first_stmt): Ditto.
16233         (gimple_seq_last): Ditto.
16234         (gimple_seq_last_stmt): Ditto.
16235         (gimple_seq_empty_p): Ditto.
16236
16237 2012-05-03  Richard Guenther  <rguenther@suse.de>
16238
16239         * tree-ssa-pre.c (valid_in_sets): Remove checking of trapping
16240         operations.
16241         (prune_clobbered_mems): Do it here.  Do not uselessly sort expressions.
16242         (compute_avail): Do not add possibly trapping operations to
16243         EXP_GEN if they might not be executed in the block.
16244
16245 2012-05-03  Uros Bizjak  <ubizjak@gmail.com>
16246
16247         * config/alpha/elf.h (MAX_OFILE_ALIGNMENT): Remove.
16248
16249 2012-05-03  Steven Bosscher  <steven@gcc.gnu.org>
16250
16251         * tree-switch-conversion.c (gen_inbound_check): Free post-dominance
16252         information as early as possible.  Update dominance info instead of
16253         discarding it.
16254
16255 2012-05-03  Richard Guenther  <rguenther@suse.de>
16256
16257         * tree-ssa-pre.c (debug_bitmap_sets_for): New function.
16258         (union_contains_value): Remove.
16259         (vro_valid_in_sets): Likewise.
16260         (op_valid_in_sets): New function.
16261         (valid_in_sets): Use op_valid_in_sets.
16262         (insert_into_preds_of_block): Move dumping ...
16263         (do_regular_insertion): ... here.
16264         (do_partial_partial_insertion): ... and here.  Dump that
16265         we've found a partial partial redundancy.
16266         (insert): Dump the current insert iteration.
16267
16268 2012-05-03  Jakub Jelinek  <jakub@redhat.com>
16269
16270         PR plugins/53126
16271         * gcc-ar.c (main): If GCC_EXEC_PREFIX is set in env,
16272         append program name to it and pass that as first argument
16273         to make_relative_prefix.  Always pass standard_libexec_prefix
16274         as last argument to make_relative_prefix.  If
16275         make_relative_prefix returns NULL, fall back to
16276         standard_libexec_prefix.
16277
16278         PR debug/53174
16279         * tree-predcom.c (remove_stmt): Call reset_debug_uses on stmts being
16280         removed.
16281
16282         PR target/53187
16283         * config/arm/arm.c (arm_select_cc_mode): If x has MODE_CC class
16284         mode, return that mode.
16285
16286         PR target/53194
16287         * config/i386/i386-c.c (ix86_target_macros_internal): Don't
16288         define __ATOMIC_HLE_* macros here.
16289         (ix86_target_macros): But here, using cpp_define_formatted.
16290
16291 2012-05-03  Richard Guenther  <rguenther@suse.de>
16292
16293         PR tree-optimization/53144
16294         * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_constant_for_pieces):
16295         Rename to ...
16296         (vn_reference_lookup_or_insert_for_pieces): ... this.  Properly deal
16297         with SSA name values.
16298         (vn_reference_lookup_3): Adjust callers.
16299
16300 2012-05-03  Ganesh Gopalasubramanian  <Ganesh.Gopalasubramanian@amd.com>
16301
16302         * config/i386/driver-i386.c (host_detect_local_cpu): Reset
16303         has_fma4 for AMD processors with both fma3 and fma4 support.
16304
16305 2012-05-03  Kirill Yukhin  <kirill.yukhin@intel.com>
16306
16307         PR target/53201
16308         * config/i386/driver-i386.c (host_detect_local_cpu): Add space to
16309         "-mno-hle".
16310
16311 2012-05-03  Michael Matz  <matz@suse.de>
16312
16313         PR bootstrap/53197
16314         * tree-ssa-dse.c (dse_optimize_stmt): Take pointer to iterator.
16315         (dse_enter_block): Properly iterate the whole sequence even
16316         if the last statement was removed.
16317
16318 2012-05-02  Steven Bosscher  <steven@gcc.gnu.org>
16319
16320         * config/alpha/vms.h (SUBTARGET_OVERRIDE_OPTIONS): For pic code,
16321         unset flag_jump_tables.
16322         * stmt.c (expand_case): Remove special flag_pic case conditional
16323         on ASM_OUTPUT_ADDR_DIFF_ELT not being defined.
16324
16325 2012-05-02  Ulrich Weigand  <ulrich.weigand@linaro.org>
16326
16327         * common/config/s390/s390-common.c (s390_option_optimization_table):
16328         Enable -fsched-pressure using -fsched-pressure-algorithm=model by
16329         default when optimizing.
16330
16331 2012-05-02  Martin Jambor  <mjambor@suse.cz>
16332
16333         PR lto/52605
16334         * dwarf2out.c (dwarf2out_decl): Only lookup die representing context
16335         of a variable when the contect is a function.
16336
16337 2012-05-02  Michael Matz  <matz@suse.de>
16338
16339         * coretypes.h (gimple_seq, const_gimple_seq): Typedef as gimple.
16340         * gimple.h (struct gimple_seq_node_d, struct gimple_seq_d): Remove.
16341         (const_gimple_seq_node): Remove.
16342         (gimple_seq_node): Typedef as gimple.
16343         (struct gimple_statement_base): Add next and prev members,
16344         adjust all WORD markers in using structs.
16345         (union gimple_statement_d): Link via gsbase.next field for GC and PCH.
16346         (gimple_seq_first, gimple_seq_first_stmt, gimple_seq_last,
16347         gimple_seq_last_stmt): Adjust as gimple_seq, gimple_seq_node and
16348         gimple are the same.
16349         (gimple_seq_set_last, gimple_seq_set_first): Don't allocate
16350         gimple_seq, adjust.
16351         (gimple_init_singleton): New function.
16352         (gsi_start_1, gsi_last_1, gsi_end_p, gsi_one_before_end_p): Adjust.
16353         (gsi_next, gsi_prev): Adjust, handle prev cyclic list correctly.
16354         (gsi_stmt): Adjust.
16355         (gsi_stmt_ptr): Remove.
16356         (enum gimple_alloc_kind): Remove gimple_alloc_kind_seq member.
16357
16358         * gimple-iterator.c (update_bb_for_stmts): Take last parameter
16359         again, adjust for above changes.
16360         (update_call_edge_frequencies): Adjust for above changes.
16361         (gsi_insert_seq_nodes_before): Rewrite for new data structure.
16362         (gsi_insert_seq_nodes_after): Ditto.
16363         (gsi_split_seq_after): Ditto.
16364         (gsi_set_stmt): Ditto.
16365         (gsi_split_seq_before): Ditto.
16366         (gsi_remove): Ditto.
16367         (gsi_insert_seq_before_without_update): Don't free sequence.
16368         (gsi_insert_seq_after_without_update): Ditto.
16369         (gsi_replace): Assert some more invariants.
16370         (gsi_insert_before_without_update, gsi_insert_after_without_update):
16371         Tidy.
16372         (gsi_for_stmt): Don't search for stmt.
16373         (gsi_insert_on_edge_immediate): Tidy.
16374
16375         * gimple.c (gimple_alloc_k): Remove "sequences".
16376         (gimple_seq_cache): Remove.
16377         (gimple_alloc_stat): Make stmt a singleton sequence.
16378         (gimple_seq_alloc, gimple_seq_free): Remove.
16379         (gimple_assign_set_rhs_with_ops_1): Ensure new stmt is a singleton.
16380         (gimple_copy): Ditto.
16381         * gimplify.c (gimplify_cleanup_point_expr): Use gsi_set_stmt,
16382         create iterator from correct sequence.
16383         * tree-phinodes.c (make_phi_node): Make stmt a singleton.
16384
16385 2012-05-02  Michael Matz  <matz@suse.de>
16386
16387         * gimple.h (gimple_stmt_iterator <seq>): Make it be pointer to
16388         gimple_seq.
16389         (gimple_seq_set_last, gimple_seq_set_first): Take pointer to
16390         sequence, lazily allocate it.
16391         (bb_seq_addr): New function.
16392         (gsi_start_1): Rename from gsi_start, but take pointer to sequence.
16393         (gsi_start): Macro to wrap gsi_start_1 taking pointer of argument.
16394         (gsi_none): New function.
16395         (gsi_start_bb): Adjust.
16396         (gsi_last_1): Rename from gsi_last, but take pointer to sequence.
16397         (gsi_last): Macro to wrap gsi_last_1 taking pointer of argument.
16398         (gsi_last_bb): Adjust.
16399         (gsi_seq): Adjust.
16400         * tree-flow-inline.h (phi_nodes_ptr): New function.
16401
16402         * gimple-iterator.c (gsi_insert_seq_nodes_before): Adjust to
16403         datastructure and interface change.
16404         (gsi_insert_seq_before_without_update): Ditto.
16405         (gsi_insert_seq_nodes_after): Ditto.
16406         (gsi_insert_seq_after_without_update): Ditto.
16407         (gsi_split_seq_after): Ditto, don't use gimple_seq_alloc.
16408         (gsi_split_seq_before): Ditto.
16409         (gsi_start_phis): Adjust.
16410         * tree-vect-loop.c (vect_determine_vectorization_factor): Use gsi_none.
16411         (vect_transform_loop): Ditto.
16412         * gimple.c (gimple_seq_add_stmt, gimple_seq_add_seq,
16413         gimple_seq_copy): Don't use gimple_seq_alloc.
16414         * gimplify.c (gimple_seq_add_stmt_without_update): Ditto.
16415         (gimplify_seq_add_seq): Ditto.
16416         * lto-streamer-in.c (make_new_block): Ditto.
16417         * tree-cfg.c (create_bb): Ditto.
16418         * tree-sra.c (initialize_parameter_reductions): Ditto.
16419
16420 2012-05-02  Michael Matz  <matz@suse.de>
16421
16422         * gimple.h (gimple_seq_first, gimple_seq_first_stmt, gimple_seq_last,
16423         gimple_seq_last_stmt, gimple_seq_set_last, gimple_seq_set_first,
16424         gimple_seq_empty_p, gimple_seq_alloc_with_stmt, bb_seq,
16425         set_bb_seq): Move down to after gimple_statement_d definition.
16426
16427 2012-05-02  Michael Matz  <matz@suse.de>
16428
16429         * gimple-fold.c (gimplify_and_update_call_from_tree): Use
16430         gsi_replace_with_seq, instead of inserting itself.
16431         * gimple-iterator.c (gsi_replace_with_seq): New function.
16432         * tree-ssa-forwprop.c (forward_propagate_comparison): Take
16433         iterator instead of statement, advance it.
16434         (ssa_forward_propagate_and_combine): Adjust call to above.
16435
16436 2012-05-02  Michael Matz  <matz@suse.de>
16437
16438         * tree-phinodes.c (add_phi_node_to_bb): Tidy, don't use
16439         gimple_seq_alloc.
16440         * omp-low.c (finalize_task_copyfn): Don't use gimple_seq_alloc.
16441         * tree-nested.c (walk_gimple_omp_for): Ditto.
16442         * trans-mem.c (lower_transaction): Ditto.
16443         * tree-eh.c (do_return_redirection): Ditto.
16444         (do_goto_redirection): Ditto.
16445         (lower_try_finally_switch): Ditto.
16446         * gimplify.c (gimplify_stmt): Ditto.
16447         (gimplify_scan_omp_clauses): Ditto.
16448         (gimplify_omp_for): Ditto.
16449         (gimplify_function_tree): Ditto.
16450         * gimple-fold.c (gimplify_and_update_call_from_tree): Ditto.
16451         * tree-mudflap.c (mf_decl_cache_locals): Ditto.
16452         (mf_build_check_statement_for): Ditto.
16453         (mx_register_decls): Ditto.
16454         * graphite-sese-to-poly.c (remove_invariant_phi): Ditto,
16455         and don't use itertors to append.
16456         (insert_stmts): Ditto.
16457         (insert_out_of_ssa_copy): Ditto.
16458         (insert_out_of_ssa_copy_on_edge): Ditto.
16459
16460 2012-05-02  Michael Matz  <matz@suse.de>
16461
16462         * gimple.h (gimple_bind_body_ptr): New function.
16463         (gimple_bind_body): Use it.
16464         (gimple_catch_handler): Use gimple_catch_handler_ptr.
16465         (gimple_eh_filter_failure_ptr): New function.
16466         (gimple_eh_filter_failure): Use it.
16467         (gimple_eh_else_n_body_ptr): New function.
16468         (gimple_eh_else_n_body): Use it.
16469         (gimple_eh_else_e_body_ptr): New function.
16470         (gimple_eh_else_e_body): Use it.
16471         (gimple_try_eval_ptr): New function.
16472         (gimple_try_eval): Use it.
16473         (gimple_try_cleanup_ptr): New function.
16474         (gimple_try_cleanup): Use it.
16475         (gimple_wce_cleanup_ptr): New function.
16476         (gimple_wce_cleanup): Use it.
16477         (gimple_omp_body_ptr): New function.
16478         (gimple_omp_body): Use it.
16479         (gimple_omp_for_pre_body_ptr): New function.
16480         (gimple_omp_for_pre_body): Use it.
16481         (gimple_transaction_body_ptr): New function.
16482         (gimple_transaction_body): Use it.
16483         (gsi_split_seq_before): Adjust to return nothing and take pointer
16484         to sequence.
16485         (gsi_set_stmt): Declare.
16486         (gsi_replace_with_seq): Declare.
16487         (walk_gimple_seq_mod): Declare.
16488         * function.h (struct function <gimple_body>): Use typedef gimple_seq.
16489
16490         * gimple-iterator.c (gsi_set_stmt): New function.
16491         (gsi_split_seq_before): Return new sequence via pointer argument.
16492         (gsi_replace): Use gsi_set_stmt.
16493
16494         * tree-ssa-loop-im.c (move_computations_stmt): First remove
16495         then insert stmt.
16496         * tree-complex.c (update_complex_components_on_edge): Don't copy gsi.
16497         * tree-phinodes.c (resize_phi_node): Don't resize stmt in-place,
16498         return new stmt.
16499         (reserve_phi_args_for_new_edge): Change call to above,
16500         use gsi_set_stmt.
16501
16502         * omp-low.c (lower_omp): Change prototype to take pointer to sequence.
16503         (lower_rec_input_clauses): Use gimple_seq_add_seq instead of
16504         iterators.  Adjust call to lower_omp.
16505         (lower_lastprivate_clauses): Adjust call to lower_omp.
16506         (lower_reduction_clauses): Ditto.
16507         (expand_omp_taskreg): Nullify non-cfg body of child_fn.
16508         (lower_omp_sections): Don't explicitely count sequence length,
16509         nullify lowered bodies earlier, ensure stmts are part of only
16510         one sequence, adjust call to lower_omp.
16511         (lower_omp_single): Ensure stmts are part of only one sequence,
16512         adjust call to lower_omp.
16513         (lower_omp_master): Ditto.
16514         (lower_omp_ordered): Ditto.
16515         (lower_omp_critical): Ditto.
16516         (lower_omp_for): Ditto.
16517         (lower_omp_taskreg): Ditto, tidy.
16518         (lower_omp_1): Adjust calls to lower_omp.
16519         (execute_lower_omp): Ditto.
16520         (lower_omp): Adjust to take pointer to sequence.
16521         (diagnose_sb_2): Use walk_gimple_seq_mod.
16522         (diagnose_omp_structured_block_errors): Ditto and set possibly
16523         changed function body.
16524         * gimple-low.c (lower_function_body): Set function body after
16525         it stabilizes.
16526         (lower_sequence): Adjust to take pointer to sequence.
16527         (lower_omp_directive): Ensure stmt isn't put twice into the
16528         sequence, adjust call to lower_sequence.
16529         (lower_stmt): Adjust calls to lower_sequence.
16530         (lower_gimple_bind): Ditto.
16531         (gimple_try_catch_may_fallthru): Call gsi_start with lvalue.
16532         * tree-nested.c (walk_body): Take pointer to sequence, use
16533         walk_gimple_seq_mod.
16534         (walk_function): Adjust call to walk_body, set possibly changed body.
16535         (walk_gimple_omp_for): Adjust calls to walk_body.
16536         (convert_nonlocal_omp_clauses): Ditto.
16537         (convert_nonlocal_reference_stmt): Ditto.
16538         (convert_local_omp_clauses): Ditto.
16539         (convert_local_reference_stmt): Ditto.
16540         (convert_tramp_reference_stmt): Ditto.
16541         (convert_gimple_call): Ditto.
16542         (convert_nl_goto_reference): Use local iterator copy.
16543         * gimple.c (walk_gimple_seq_mod): Renamed from walk_gimple_seq,
16544         but taking pointer to sequence, ensure gsi_start is called with
16545         callers lvalue.
16546         (walk_gimple_seq): New wrapper around walk_gimple_seq_mod,
16547         asserting that the sequence head didn't change.
16548         (walk_gimple_stmt): Replace all calls to walk_gimple_seq with
16549         walk_gimple_seq_mod.
16550         * trans-mem.c (lower_transaction): Use walk_gimple_seq_mod.
16551         (execute_lower_tm): Ditto, and set possibly changed body.
16552         * tree-eh.c (lower_eh_constructs_1): Take pointer to sequence,
16553         call gsi_start with that lvalue.
16554         (replace_goto_queue_stmt_list): Ditto.
16555         (replace_goto_queue_1): Adjust calls to replace_goto_queue_stmt_list.
16556         (replace_goto_queue): Ditto.
16557         (lower_try_finally_nofallthru): Adjust calls to lower_eh_constructs_1.
16558         (lower_try_finally_onedest): Ditto.
16559         (lower_try_finally_copy): Ditto.
16560         (lower_try_finally_switch): Ditto.
16561         (lower_try_finally): Ditto.
16562         (lower_eh_filter): Ditto.
16563         (lower_eh_must_not_throw): Ditto.
16564         (lower_cleanup): Ditto.
16565         (lower_eh_constructs_2): Ditto.
16566         (lower_catch): Ditto, and ensure gsi_start is called with lvalue.
16567         (lower_eh_constructs): Adjust calls to lower_eh_constructs_1, and
16568         set possibly changed body.
16569         (optimize_double_finally): Call gsi_start with lvalue.
16570
16571         * tree-cfg.c (make_blocks): Adjust call to gsi_split_seq_before.
16572         (gimple_split_block): Ditto.
16573         (gimple_merge_blocks): Use gsi_start_phis.
16574         (move_stmt_r): Use walk_gimple_seq_mod.
16575         * tree-ssa-dse.c (dse_enter_block): Use gsi_last_bb.
16576         * cgraphbuild.c (build_cgraph_edges): Use gsi_start_phis.
16577         (rebuild_cgraph_edges): Ditto.
16578         (cgraph_rebuild_references): Ditto.
16579         * ipa-prop.c (ipa_analyze_params_uses): Ditto.
16580         * tree-inline.c (copy_phis_for_bb): Ditto.
16581         * tree-ssa-dce.c: Ditto.
16582
16583         * cgraphunit.c (cgraph_analyze_function): Use gimple_has_body_p.
16584
16585 2012-05-02  Kirill Yukhin  <kirill.yukhin@intel.com>
16586             Andi Kleen  <ak@linux.intel.com>
16587
16588         * coretypes.h (MEMMODEL_MASK): New.
16589         * builtins.c (get_memmodel): Add val. Call target.memmodel_check
16590         and return new variable.
16591         (expand_builtin_atomic_exchange):  Mask memmodel values.
16592         (expand_builtin_atomic_compare_exchange): Ditto.
16593         (expand_builtin_atomic_load): Ditto.
16594         (expand_builtin_atomic_store): Ditto.
16595         (expand_builtin_atomic_clear): Ditto.
16596         * doc/extend.texi: Mention port-dependent memory model flags.
16597         * config/i386/cpuid.h (bit_HLE): New.
16598         * config/i386/driver-i386.c (host_detect_local_cpu): Detect
16599         HLE support.
16600         * config/i386/i386-protos.h (ix86_generate_hle_prefix): New.
16601         * config/i386/i386-c.c (ix86_target_macros_internal): Set HLE defines.
16602         (ix86_target_string)<-mhle>: New.
16603         (ix86_valid_target_attribute_inner_p) <OPT_mhle>: Ditto.
16604         * config/i386/i386.c (ix86_target_string) <OPTION_MASK_ISA_HLE>: New.
16605         (ix86_valid_target_attribute_inner_p) <OPT_mhle>: Ditto.
16606         (ix86_option_override_internal) <PTA_HLE>: New switch, set it
16607         enabled for generic, generic64 and core-avx2.
16608         (ix86_print_operand): Generate HLE lock prefixes.
16609         (ix86_memmodel_check): New.
16610         (TARGET_MEMMODEL_CHECK): Ditto.
16611         * config/i386/i386.h (OPTION_ISA_HLE): Ditto.
16612         (IX86_HLE_ACQUIRE): Ditto.
16613         (IX86_HLE_RELEASE): Ditto.
16614         * config/i386/i386.h (ix86_generate_hle_prefix): Ditto.
16615         * config/i386/i386.opt (mhle): Ditto.
16616         * config/i386/sync.md(atomic_compare_and_swap<mode>): Pass
16617         success model to instruction emitter.
16618         (atomic_fetch_add<mode>): Ditto.
16619         (atomic_exchange<mode>): Ditto.
16620         (atomic_add<mode>): Ditto.
16621         (atomic_sub<mode>): Ditto.
16622         (atomic_<code><mode>): Ditto.
16623         (*atomic_compare_and_swap_doubledi_pic): Ditto.
16624         (atomic_compare_and_swap_single<mode>): Define and use argument
16625         for success model.
16626         (atomic_compare_and_swap_double<mode>): Ditto.
16627         * configure.ac: Check if assembler support HLE prefixes.
16628         * configure: Regenerate.
16629         * config.in: Ditto.
16630
16631 2012-05-02  Steven Bosscher  <steven@gcc.gnu.org>
16632
16633         PR middle-end/53153
16634         * gimplify.c (preprocess_case_label_vec_for_gimple): New function,
16635         split out from ...
16636         (gimplify_switch_expr): ... here.
16637         * gimple.h (preprocess_case_label_vec_for_gimple): Add prototype.
16638         * tree-ssa-forwprop.c (simplify_gimple_switch_label_vec): New function
16639         to clean up case labels with values outside the index type range.
16640         (simplify_gimple_switch): Call it if something changed.
16641         Remove strange and unnecessary assert.
16642
16643 2012-05-02  Richard Guenther  <rguenther@suse.de>
16644
16645         * fold-const.c (div_if_zero_remainder): sizetypes no longer
16646         sign-extend.
16647         (int_const_binop_1): New worker for int_const_binop with
16648         overflowable parameter.  Pass it through to force_fit_type_double.
16649         (int_const_binop): Wrap around int_const_binop_1 with overflowable
16650         equal to one.
16651         (size_binop_loc): Call int_const_binop_1 with overflowable equal
16652         to minus one, forcing overflow detection for even unsigned types.
16653         (extract_muldiv_1): Remove bogus TYPE_IS_SIZETYPE special-casing.
16654         (fold_binary_loc): Call try_move_mult_to_index with signed offset.
16655         * stor-layout.c (initialize_sizetypes): sizetypes no longer
16656         sign-extend.
16657         (layout_type): For zero-sized arrays ignore overflow on the
16658         size calculations.
16659         * tree-ssa-ccp.c (bit_value_unop_1): Likewise.
16660         (bit_value_binop_1): Likewise.
16661         * tree.c (double_int_to_tree): Likewise.
16662         (double_int_fits_to_tree_p): Likewise.
16663         (force_fit_type_double): Likewise.
16664         (host_integerp): Likewise.
16665         (int_fits_type_p): Likewise.
16666         * varasm.c (output_constructor_regular_field): Sign-extend the
16667         field-offset to cater for negative offsets produced by the Ada
16668         frontend.
16669         * omp-low.c (extract_omp_for_data): Convert the loop step to
16670         signed for pointer adjustments.
16671
16672 2012-05-02  Richard Guenther  <rguenther@suse.de>
16673
16674         * tree.c (valid_constant_size_p): New function.
16675         * tree.h (valid_constant_size_p): Declare.
16676         * cfgexpand.c (expand_one_var): Adjust check for too large
16677         variables by using valid_constant_size_p.
16678         * varasm.c (assemble_variable): Likewise.
16679
16680         * c-decl.c (grokdeclarator): Properly check for sizes that
16681         cover more than half of the address-space.
16682
16683 2012-05-02  Jakub Jelinek  <jakub@redhat.com>
16684
16685         PR tree-optimization/53163
16686         * tree-ssa-phiopt.c (cond_if_else_store_replacement): Don't ignore
16687         return value from compute_all_dependences.
16688
16689         PR rtl-optimization/53160
16690         * ree.c (combine_reaching_defs): Handle the case where cand->insn
16691         has been modified by ree pass already.
16692
16693 2012-05-01  Ian Lance Taylor  <iant@google.com>
16694
16695         PR c/37303
16696         * c-decl.c (build_compound_literal): Make the decl readonly if it
16697         an array of a readonly type.
16698         * gimplify.c (gimplify_compound_literal_expr): Add fallback
16699         parameter.  Change all callers.  If the decl is not addressable
16700         and is not an l-value, make it readonly.
16701
16702 2012-05-01  Bernd Schmidt  <bernds@codesourcery.com>
16703
16704         * ira.c (allocated_reg_info_size): New static variable.
16705         (expand_reg_info): Manage it. Call
16706         setup_preferred_alternate_classes_for_new_pseudos.
16707         (ira): Don't do it here.  Remove local allocated_reg_info_size,
16708         set the global before calling find_moveable_pseudos.
16709         (find_moveable_pseudos): Call expand_reg_info rather than
16710         resize_reg_info.
16711
16712 2012-05-01  Richard Henderson  <rth@redhat.com>
16713
16714         * common.opt (fsync-libcalls): New.
16715         * doc/invoke.texi: Document it.
16716         * optabs.c (init_sync_libfuncs): Honor it.
16717
16718 2012-05-01  Kenneth Zadeck  <zadeck@naturalbridge.com>
16719             Richard Sandiford  <r.sandiford@uk.ibm.com>
16720
16721         PR rtl-optimization/52543
16722         * Makefile.in (lower-subreg.o, target-globals.o): Depend on
16723         lower-subreg.h.
16724         * lower-subreg.h: New file.
16725         * target-globals.h (this_target_lower_subreg): Declare.
16726         (target_globals): Add lower_subreg;
16727         (restore_target_globals): Restore this_target_lower_subreg.
16728         * target-globals.c: Include it.
16729         (default_target_globals): Add default_target_lower_subreg.
16730         (save_target_globals): Initialize target_lower_subreg.
16731         * rtl.h (init_lower_subreg): Added declaration.
16732         * toplev.c (backend_init_target): Call initializer for lower-subreg
16733         pass.
16734         * lower-subreg.c (LOG_COSTS, FORCE_LOWERING): New macros.
16735         (default_target_lower_subreg): New variable.
16736         (this_target_lower_subreg): Likewise.
16737         (twice_word_mode, choices): New macros.
16738         (shift_cost, compute_splitting_shift, compute_costs)
16739         (init_lower_subreg): New functions.
16740         (resolve_simple_move): Add speed_p argument.  Check choices.
16741         (find_pseudo_copy): Don't check the mode size here.
16742         (resolve_simple_move): Assert the mode size.
16743         (find_decomposable_shift_zext): Add speed_p argument and return
16744         a bool.  Check choices.
16745         (resolve_shift_zext): Add comment.
16746         (dump_shift_choices, dump_choices): New functions.
16747         (decompose_multiword_subregs): Dump list of profitable
16748         transformations.  Add code to skip non profitable transformations.
16749         Update calls to simple_move and find_decomposable_shift_zext.
16750
16751 2012-05-01  Ian Bolton  <ian.bolton@arm.com>
16752             Sameera Deshpande  <sameera.deshpande@arm.com>
16753             Greta Yorsh  <greta.yorsh@arm.com>
16754
16755         * config/arm/arm-protos.h (thumb_unexpanded_epilogue): Rename to...
16756         (thumb1_unexpanded_epilogue): ...this.
16757         * config/arm/arm.c (thumb_unexpanded_epilogue): Rename to...
16758         (thumb1_unexpanded_epilogue): ...this.
16759         * config/arm/arm.md (thumb_unexpanded_epilogue): Rename to...
16760         (thumb1_unexpanded_epilogue): ...this.
16761
16762 2012-05-01  Richard Earnshaw  <rearnsha@arm.com>
16763
16764         * arm/linux-eabi.h (GLIBC_DYNAMIC_LINKER_DEFAULT): Avoid ifdef
16765         comparing enumeration values.  Update comments.
16766
16767 2012-05-01  Alan Modra  <amodra@gmail.com>
16768
16769         PR target/53038
16770         * config/rs6000/rs6000.c (load_lr_save, restore_saved_lr,
16771         load_cr_save, add_crlr_cfa_restore): New functions.
16772         (rs6000_restore_saved_cr): Rename to..
16773         (restore_saved_cr): ..this.  Add cfa_restore notes for cr.
16774         (rs6000_emit_epilogue): Use new functions.  Adjust condition
16775         for emitting lr and cr cfa_restore.  Emit cfa_restores for fp
16776         regs when using out-of-line restore only when shrink wrapping.
16777
16778 2012-04-30  Uros Bizjak  <ubizjak@gmail.com>
16779
16780         PR middle-end/53136
16781         * ipa-prop.c (ipa_print_node_jump_functions): Wrap multiple
16782         calls to cgraph_node_name in xstrdup.
16783         (ipa_make_edge_direct_to_target): Ditto.
16784         * cgraph.c (dump_cgraph_node): Ditto.
16785         * tree-sra.c (convert_callers_for_node): Ditto.
16786         * lto-symtab.c (lto_cgraph_replace_node): Ditto.
16787         * ipa-cp.c (perhaps_add_new_callers): Ditto.
16788         * cgraphunit.c (cgraph_redirect_edge_call_stmt_to_callee): Ditto.
16789         (cgraph_materialize_all_clones): Ditto.
16790         * ipa-inline.c (report_inline_failed_reason): Ditto.
16791         (want_early_inline_function_p): Ditto.
16792         (edge_badness): Ditto.
16793         (update_edge_key): Ditto.
16794         (flatten_function): Ditto.
16795         (ipa_inline): Ditto.
16796         (inline_always_inline_functions): Ditto.
16797         (early_inline_small_functions): Ditto.
16798
16799 2012-04-30  Uros Bizjak  <ubizjak@gmail.com>
16800
16801         PR target/53141
16802         * config/i386/i386.md (*umul<mode><dwi>3_1): Switch places of
16803         constraints 0 and 1.
16804
16805 012-04-30  Jan Hubicka  <jh@suse.cz>
16806
16807         * cgraph.c (ld_plugin_symbol_resolution_names): Move to symtab.c
16808         (cgraph_asm_nodes, cgraph_asm_last_node): Move to cgraphunit.c
16809         (cgraph_add_to_same_comdat_group): Remove.
16810         (cgraph_add_asm_node): Move to cgraphunit.c.
16811         (cgraph_make_decl_local): Move to symtab.c
16812         (cgraph_make_node_local_1): Update.
16813         (cgraph_can_remove_if_no_direct_calls_and): Update.
16814         (used_from_object_file_p): Update.
16815         (resolution_used_from_other_file_p): Move to symtab.c
16816         (cgraph_used_from_object_file_p): move to symtab.c
16817         (verify_cgraph_node): Verify same comdat groups.
16818         * cgraph.h (cgraph_asm_node): Rename to ...
16819         (asm_node): ... this one.
16820         (cgraph_asm_nodes): Rename to ...
16821         (asm_nodes): ... this one.
16822         (symtab_add_to_same_comdat_group): New function.
16823         (symtab_dissolve_same_comdat_group_list): New function.
16824         (symtab_used_from_object_file_p): Declare.
16825         (symtab_make_decl_local): Declare.
16826         (cgraph_add_to_same_comdat_group): Remove.
16827         (cgraph_add_asm_node): Remove.
16828         (cgraph_used_from_object_file_p, varpool_used_from_object_file_p):
16829         Remove.
16830         (cgraph_finalize_compilation_unit): Rename to ...
16831         (finalize_compilation_unit): ... this one.
16832         (cgraph_optimize): Rename to ....
16833         (compile): ... this one.
16834         (add_asm_node): Declare.
16835         (fixup_same_cpp_alias_visibility): Declare.
16836         (cgraph_make_decl_local): Remove.
16837         (varpool_assemble_pending_decls): Rename to ...
16838         (varpool_output_variables): ... this one.
16839         (varpool_remove_unreferenced_decls): Remove.
16840         * ipa-inline-transform.c (clone_inlined_nodes): Dissolve comdat groups.
16841         (preserve_function_body_p): Make static.
16842         * toplev.c (compile_file): Update comments; update.
16843         * cgraphunit.c: Update comments.
16844         (cgraph_expand_all_functions): Rename to ...
16845         (expand_all_functions): ... this one; update.
16846         (cgraph_mark_functions_to_output): Rename to ...
16847         (mark_functions_to_output): ... this one; cleanup.
16848         (cgraph_output_pending_asms): Remove prototype.
16849         (asm_nodes, asm_last_node): New static vars.
16850         (cgraph_process_new_functions): Update.
16851         (cgraph_reset_node): Cleanup; add comment.
16852         (cgraph_add_new_function): Update.
16853         (cgraph_output_pending_asms): Rename to ...
16854         (output_asm_statements): ... this one.
16855         (add_asm_node): New function.
16856         (fixup_same_cpp_alias_visibility): New function based on code
16857         in cgraph_analyze_function.
16858         (cgraph_analyze_function): Use it.
16859         (cgraph_order_sort): Update.
16860         (cgraph_output_in_order): Update.
16861         (cgraph_function_versioning): Update.
16862         (cgraph_optimize): Rename to ...
16863         (compile): ... this one; initialize streamer hooks here.
16864         (cgraph_finalize_compilation_unit): Rename to ...
16865         (finalize_compilation_unit): ... this one; do not initialize streamer
16866         hook here.
16867         * lto-streamer-out.c (lto_output_toplevel_asms): Update.
16868         * dwarf2out.c: Update ocmment.
16869         * optimize.c (maybe_clone_body): Use symtab_add_to_same_comdat_group.
16870         * method.c (use_thunk): Likewise.
16871         * semantics.c (maybe_add_lambda_conv_op): Likewise.
16872         * decl2.c (maybe_emit_vtables): Likewise.
16873         (cp_write_global_declarations): Use finalize_compilation_unit.
16874         * parser.c (cp_parser_asm_definition): Use add_asm_node.
16875         * lto-streamer-in.c (lto_input_toplevel_asms): Use add_asm_node
16876         * c-decl.c (c_write_global_declarations): Use
16877         finalize_compilation_unit.
16878         * langhooks.c (write_global_declarations): Update.
16879         * ipa.c (cgraph_externally_visible_p): Update.
16880         (dissolve_same_comdat_group_list): Remove.
16881         (function_and_variable_visibility): Update.
16882         * symtab.c: Inlcude lto-streamer.h and rtl.h
16883         (ld_plugin_symbol_resolution_names): New.
16884         (symtab_add_to_same_comdat_group): New.
16885         (symtab_dissolve_same_comdat_group_list): New.
16886         (resolution_used_from_other_file_p): Move here from cgraph.c
16887         (symtab_used_from_object_file_p): New.
16888         (symtab_make_decl_local): New.
16889         * passes.c (register_pass): Update comments.
16890         * c-parser.c (c_parser_asm_definition): Update.
16891         * varpool.c (varpool_analyze_node): Use
16892         fixup_same_cpp_alias_visibility.
16893         (varpool_remove_unreferenced_decls): Make static.
16894         (varpool_assemble_pending_decls): Rename to ...
16895         (varpool_output_variables): ... this one; call
16896         varpool_remove_unreferenced_decls.
16897         (varpool_used_from_object_file_p): Remove.
16898
16899 2012-04-30  Marc Glisse  <marc.glisse@inria.fr>
16900
16901         PR c++/51033
16902         * c-typeck.c (build_array_ref): Call
16903         convert_vector_to_pointer_for_subscript.
16904         * doc/extend.texi (Vector Extensions): Subscripting not just for C.
16905
16906 2012-04-30  Uros Bizjak  <ubizjak@gmail.com>
16907
16908         * config/i386/i386.md (and<mode>3): Change runtime operand mode checks
16909         to compile-time "mode == <MODE>mode" checks.
16910         (and splitter): Ditto.
16911
16912 2012-04-30  Richard Henderson  <rth@redhat.com>
16913
16914         * config/arm/arm.md (UNSPEC_LL): New.
16915         * config/arm/sync.md (atomic_loaddi, atomic_loaddi_1): New.
16916         (arm_load_exclusivedi): Use %H0.
16917
16918 2012-04-30  Jason Merrill  <jason@redhat.com>
16919
16920         * dwarf2out.c (comdat_symbol_id): Add const.
16921         (union die_symbol_or_type_node): Add const to die_symbol.
16922         (output_die_symbol, output_die, output_comp_unit): Adjust.
16923
16924 2012-04-30  Andrew Stubbs  <ams@codesourcery.com>
16925
16926         * config/arm/arm.md (negdi2): Use gen_negdi2_neon.
16927         * config/arm/neon.md (negdi2_neon): New insn.
16928         Also add splitters for core and NEON registers.
16929
16930 2012-04-30  Andrew Stubbs  <ams@codesourcery.com>
16931
16932         * config/arm/arm.c (neon_valid_immediate): Allow const_int.
16933         (arm_print_operand): Add 'x' format.
16934         * config/arm/constraints.md (Dn): Allow const_int.
16935         * config/arm/neon.md (neon_mov<mode>): Use VDX to allow DImode.
16936         Use 'x' format to print constants.
16937         * config/arm/predicates.md (imm_for_neon_mov_operand): Allow const_int.
16938         * config/arm/vfp.md (movdi_vfp): Disable for const_int when neon
16939         is enabled.
16940         (movdi_vfp_cortexa8): Likewise.
16941
16942 2012-04-30  Ian Bolton  <ian.bolton@arm.com>
16943             Sameera Deshpande  <sameera.deshpande@arm.com>
16944             Greta Yorsh  <greta.yorsh@arm.com>
16945
16946         * config/arm/arm-protos.h (ldm_stm_operation_p): New declaration.
16947         * config/arm/arm.c (ldm_stm_operation_p): New function.
16948         * config/arm/predicates.md (load_multiple_operation): Update predicate.
16949         (store_multiple_operation): Likewise.
16950
16951         * config/arm/arm-protos.h (ldm_stm_operation_p): New parameters.
16952         * config/arm/arm.c (ldm_stm_operation_p): New parameters.
16953         * config/arm/predicates.md (load_multiple_operation): Add arguments.
16954         (store_multiple_operation): Likewise.
16955
16956 2012-04-30  Uros Bizjak  <ubizjak@gmail.com>
16957
16958         * config/i386/i386.md (and<mode>3): Expand masking operations with
16959         0xff, 0xffff or 0xffffffff immediates to corresponding zero_extend RTX.
16960         (and splitter): Split to DImode zero_extend RTX for DImode operand[0].
16961
16962 2012-04-30  Dodji Seketeli  <dodji@redhat.com>
16963
16964         Add -Wvarargs option
16965         * builtins.c (fold_builtin_next_arg):  Use OPT_Wvarargs as an
16966         argument for the various warning_at calls.
16967         * docs/invoke.texi: Update the documentation.
16968
16969 2012-04-30  Dodji Seketeli  <dodji@redhat.com>
16970
16971         Switch -ftrack-macro-expansion=2 on by default.
16972         * docs/cppopts.texi: Adjust for enabling -ftrack-macro-expansion=2
16973         by default.
16974
16975         Fix va_start related location
16976         * builtins.c (fold_builtin_next_arg): Unwinds to the first
16977         location in real source code.
16978
16979         Make conversion warnings work on NULL with -ftrack-macro-expansion
16980         * input.h (expansion_point_location_if_in_system_header): Declare
16981         new function.
16982         * input.c (expansion_point_location_if_in_system_header): Define it.
16983
16984         Fix -Wuninitialized for -ftrack-macro-expansion
16985         * tree-ssa.c (warn_uninit): Use the spelling location of the variable
16986         declaration.  Use linemap_location_before_p for source locations.
16987
16988         Strip "<built-in>" loc from displayed expansion context
16989         * input.c (expand_location_1): When expanding to spelling location
16990         in a context of a macro expansion, skip reserved system header
16991         locations.  Update comments.  * tree-diagnostic.c
16992         (maybe_unwind_expanded_macro_loc): Likewise.
16993
16994         Make expand_location resolve to locus in main source file
16995         * input.c (expand_location_1): New.  Takes a parameter to choose
16996         whether to resolve the location to spelling or expansion point.
16997         Was factorized from ...
16998         (expand_location): ... here.
16999         (expand_location_to_spelling_point): New.  Implemented in terms of
17000         expand_location_1.
17001         * diagnostic.c (diagnostic_build_prefix): Use the new
17002         expand_location_to_spelling_point instead of expand_location.
17003
17004         Fix PCH crash on GTYed pointer-to-scalar field of a struct
17005         * gengtype.c (write_types_process_field): Force second argument of
17006         the call to the PCH object hierarchy walker to be 'x'.
17007
17008 2012-04-30  Eric Botcazou  <ebotcazou@adacore.com>
17009
17010         * config/i386/i386.c (ix86_handle_struct_attribute): Use the proper
17011         predicate to discriminate types.
17012
17013 2012-04-30  Manuel López-Ibáñez  <manu@gcc.gnu.org>
17014
17015         * doc/invoke.texi (Wmissing-format-attribute): Document as an
17016         alias of Wsuggest-attribute=format.
17017         * c-typeck.c (convert_for_assignment): Replace
17018         Wmissing-format-attribute with Wsuggest-attribute=format.
17019         (digest_init): Likewise.
17020
17021 2012-04-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
17022
17023         * opts.c (finish_options): Do not handle -Wmissing-noreturn here.
17024         * common.opt (Wmissing-noreturn): Alias of
17025         -Wsuggest-attribute=noreturn.
17026
17027 2012-04-29  Hans-Peter Nilsson  <hp@axis.com>
17028
17029         PR target/53156
17030         * config/cris/cris.md (andqu): New peephole2.
17031         (andu): Tweak head comment.
17032
17033 2012-04-28  Joern Rennecke  <joern.rennecke@embecosm.com>
17034             Steven Bosscher  <steven@gcc.gnu.org>
17035             Maxim Kuvyrkov  <maxim@codesourcery.com>
17036
17037         PR tree-optimization/38785
17038         * common.opt (ftree-partial-pre): New option.
17039         * doc/invoke.texi: Document it.
17040         * opts.c (default_options_table): Initialize flag_tree_partial_pre.
17041         * tree-ssa-pre.c (do_partial_partial_insertion): Insert only if it will
17042         benefit speed path.
17043         (execute_pre): Use flag_tree_partial_pre.
17044
17045 2012-04-27  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
17046
17047         PR target/52999
17048         * config/pa/pa.c (pa_legitimate_constant_p): Don't put function labels
17049         in constant pool.
17050
17051 2012-04-27  Ollie Wild  <aaw@google.com>
17052
17053         * doc/invoke.texi (Wliteral-suffix): Document new option.
17054
17055 2012-04-27  Tom Tromey  <tromey@redhat.com>
17056
17057         * dwarf2out.c (dwarf_stack_op_name): Use get_DW_OP_name.
17058         (dwarf_tag_name): Use get_DW_TAG_name.
17059         (dwarf_attr_name): Use get_DW_AT_name.
17060         (dwarf_form_name): Use get_DW_FORM_name.
17061         * dwarf2cfi.c (dwarf_cfi_name): Use get_DW_CFA_name.
17062
17063 2012-04-27  Paolo Bonzini  <bonzini@gnu.org>
17064
17065         * tree-ssa-phiopt.c (conditional_replacement): Replace PHIs whose
17066         arguments are -1 and 0, by negating the result of the conditional.
17067
17068 2012-04-27  Paolo Bonzini  <bonzini@gnu.org>
17069
17070         PR target/53138
17071         * config/i386/i386.md (x86_mov<mode>cc_0_m1_neg): Add clobber.
17072
17073 2012-04-27  Richard Guenther  <rguenther@suse.de>
17074
17075         * tree-flow.h (is_hidden_global_store): Remove.
17076         * tree-ssa-sink.c (is_hidden_global_store): Likewise.
17077         * tree-ssa-alias.h (ref_may_alias_global_p): Declare.
17078         (stmt_may_clobber_global_p): Likewise.
17079         * tree-ssa-alias.c (ref_may_alias_global_p): New function.
17080         (stmt_may_clobber_global_p): Likewise.
17081         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Call
17082         stmt_may_clobber_global_p.
17083         * tree-ssa-dse.c (dse_possible_dead_store_p): Likewise.
17084
17085 2012-04-27  Steven Bosscher  <steven@gcc.gnu.org>
17086
17087         * cfg.c (disconnect_src): Do df_mark_solutions_dirty in the right
17088         place.
17089
17090         * tree-switch-conversion.c (struct switch_conv_info): Add range_max,
17091         reorganize some fields and update comments.  Rename bit_test_uniq
17092         and bit_test_count to uniq resp. count.  Remove bit_test_bb.
17093         (collect_switch_conv_info): New function, collects info about a
17094         GIMPLE_SWITCH into a struct switch_conv_info.
17095         (check_range): Simplify to use pre-recorded info.  Fix think-o in
17096         range-branch ratio check.
17097         (check_process_case): Remove function.
17098         (check_all_empty_except_final): New function, verifies that all
17099         non-final basic blocks are empty.
17100         (process_switch): Simplify to use pre-recorded info.  Call
17101         collect_switch_conv_info to do that.  Assert that degenerate switch
17102         statements have been cleaned up.
17103
17104 2012-04-27  Marc Glisse  <marc.glisse@inria.fr>
17105
17106         PR middle-end/27139
17107         * tree-ssa-forwprop.c (combine_conversions): Handle INT->FP->INT.
17108
17109 2012-04-25  Manuel López-Ibáñez  <manu@gcc.gnu.org>
17110
17111         PR c/53130
17112         * c-typeck.c (pop_init_level): Use %qD instead of %qT.
17113
17114 2012-04-27  Tom de Vries  <tom@codesourcery.com>
17115
17116         PR tree-optimization/51879
17117         * tree-ssa-sccvn.h (struct vn_reference_s): Add result_vdef field.
17118         * tree-ssa-sccvn.c (mark_use_processed): New function, factored out
17119         of ...
17120         (defs_to_varying): ... here.  Don't set use_processed.
17121         (visit_reference_op_call): Handle gimple_vdef.
17122         Handle case that lhs is NULL_TREE.
17123         (visit_use): Use mark_use_processed.  Handle calls with side-effect
17124         using visit_reference_op_call.
17125
17126 2012-04-26  Richard Sandiford  <richard.sandiford@linaro.org>
17127
17128         * sched-deps.c (fixup_sched_groups): Rename to...
17129         (chain_to_prev_insn): ...this.
17130         (chain_to_prev_insn_p): New function.
17131         (deps_analyze_insn): Use it instead of SCHED_GROUP_P.
17132
17133 2012-04-26  Richard Sandiford  <richard.sandiford@linaro.org>
17134
17135         * sched-int.h (_haifa_insn_data): Move priority_status.
17136         Add model_index.
17137         (INSN_MODEL_INDEX): New macro.
17138         * haifa-sched.c (insn_delay): New function.
17139         (sched_regno_pressure_class): Update commentary.
17140         (mark_regno_birth_or_death): Pass the liveness bitmap and
17141         pressure array as arguments, instead of using curr_reg_live and
17142         curr_reg_pressure.  Only update the pressure if the bit in the
17143         liveness set has changed.
17144         (initiate_reg_pressure_info): Always trust the live-in set for
17145         SCHED_PRESSURE_MODEL.
17146         (initiate_bb_reg_pressure_info): Update call to
17147         mark_regno_birth_or_death.
17148         (dep_list_size): Take the list as argument.
17149         (calculate_reg_deaths): New function, extracted from...
17150         (setup_insn_reg_pressure_info): ...here.
17151         (MODEL_BAR): New macro.
17152         (model_pressure_data, model_insn_info, model_pressure_limit)
17153         (model_pressure_group): New structures.
17154         (model_schedule, model_worklist, model_insns, model_num_insns)
17155         (model_curr_point, model_before_pressure, model_next_priority):
17156         New variables.
17157         (MODEL_PRESSURE_DATA, MODEL_MAX_PRESSURE, MODEL_REF_PRESSURE)
17158         (MODEL_INSN_INFO, MODEL_INSN): New macros.
17159         (model_index, model_update_limit_points_in_group): New functions.
17160         (model_update_limit_points, model_last_use_except): Likewise.
17161         (model_start_update_pressure, model_update_pressure): Likewise.
17162         (model_recompute, model_spill_cost, model_excess_group_cost): Likewise.
17163         (model_excess_cost, model_dump_pressure_points): Likewise.
17164         (model_set_excess_costs): Likewise.
17165         (rank_for_schedule): Extend SCHED_PRIORITY_WEIGHTED ordering to
17166         SCHED_PRIORITY_MODEL.  Use insn_delay.  Use the order in the model
17167         schedule as an alternative tie-breaker.  Update the call to
17168         dep_list_size.
17169         (ready_sort): Call model_set_excess_costs.
17170         (update_register_pressure): Update call to mark_regno_birth_or_death.
17171         Rely on that function to check liveness rather than doing it here.
17172         (model_classify_pressure, model_order_p, model_add_to_worklist_at)
17173         (model_remove_from_worklist, model_add_to_worklist, model_promote_insn)
17174         (model_add_to_schedule, model_analyze_insns, model_init_pressure_group)
17175         (model_record_pressure, model_record_pressures): New functions.
17176         (model_record_final_pressures, model_add_successors_to_worklist)
17177         (model_promote_predecessors, model_choose_insn): Likewise.
17178         (model_reset_queue_indices, model_dump_pressure_summary): Likewise.
17179         (model_start_schedule, model_finalize_pressure_group): Likewise.
17180         (model_end_schedule): Likewise.
17181         (schedule_insn): Say when we're scheduling the next instruction
17182         in the model schedule.
17183         (schedule_insn): Handle SCHED_PRESSURE_MODEL.
17184         (queue_to_ready): Do not add instructions that are
17185         MAX_SCHED_READY_INSNS beyond the current point of the model schedule.
17186         Always allow the next instruction in the model schedule to be added.
17187         (debug_ready_list): Print the INSN_REG_PRESSURE_EXCESS_COST_CHANGE
17188         and delay for SCHED_PRESSURE_MODEL too.
17189         (prune_ready_list): Extend SCHED_PRIORITY_WEIGHTED handling to
17190         SCHED_PRIORITY_MODEL, but also take the DFA into account.
17191         (schedule_block): Call model_start_schedule and model_end_schedule.
17192         Extend SCHED_PRIORITY_WEIGHTED stall handling to SCHED_PRIORITY_MODEL.
17193         (sched_init): Extend INSN_REG_PRESSURE_EXCESS_COST_CHANGE handling
17194         to SCHED_PRESSURE_MODEL, but don't allocate saved_reg_live or
17195         region_ref_regs.
17196         (sched_finish): Update accordingly.
17197         (fix_tick_ready): Extend INSN_REG_PRESSURE_EXCESS_COST_CHANGE handling
17198         to SCHED_PRESSURE_MODEL.
17199         (add_jump_dependencies): Update call to dep_list_size.
17200         (haifa_finish_h_i_d): Fix leak of max_reg_pressure.
17201         (haifa_init_insn): Extend INSN_REG_PRESSURE_EXCESS_COST_CHANGE handling
17202         to SCHED_PRESSURE_MODEL.
17203         * sched-deps.c (init_insn_reg_pressure_info): Likewise, but don't
17204         allocate INSN_MAX_REG_PRESSURE for SCHED_PRESSURE_MODEL.
17205         (sched_analyze_insn): Extend INSN_REG_PRESSURE_EXCESS_COST_CHANGE
17206         handling to SCHED_PRESSURE_MODEL.
17207
17208 2012-04-26  Richard Sandiford  <richard.sandiford@linaro.org>
17209
17210         * common.opt (fsched-pressure-algorithm=): New option.
17211         * flag-types.h (sched_pressure_algorithm): New enum.
17212         * sched-int.h (sched_pressure_p): Replace with...
17213         (sched_pressure): ...this new variable.
17214         * haifa-sched.c (sched_pressure_p): Replace with...
17215         (sched_pressure): ...this new variable.
17216         (sched_regno_pressure_class, rank_for_schedule, ready_sort)
17217         (update_reg_and_insn_max_reg_pressure, schedule_insn)
17218         (debug_ready_list, prune_ready_list, schedule_block, sched_init)
17219         (sched_finish, fix_tick_ready, haifa_init_insn): Update accordingly.
17220         * sched-deps.c (init_insn_reg_pressure_info): Likewise.
17221         (sched_analyze_insn): Likewise.
17222         * sched-rgn.c (schedule_region): Likewise.
17223         * config/m68k/m68k.c (m68k_sched_variable_issue): Likewise.
17224
17225 2012-04-26  Bernd Schmidt  <bernds@codesourcery.com>
17226
17227         * PR middle-end/52997
17228         * ira.c (find_moveable_pseudos): Call resize_reg_info.
17229
17230         PR middle-end/52940
17231         * machmode.h (CLASS_HAS_WIDER_MODES_P): True for MODE_PARTIAL_INT.
17232         * expr.c (convert_move): Honor unsignedp when extending partial int
17233         modes.
17234         * genmodes.c (complete_mode): Don't clear component field of partial
17235         int modes.
17236         (emit_mode_inner): Don't emit it however.
17237         (calc_wider_mode): Partial int modes widen to their component.
17238
17239 2012-04-26  David S. Miller  <davem@davemloft.net>
17240
17241         * config/sparc/niagara4.md: New file.
17242         * config/sparc/sparc.md: Include it.
17243         * config/sparc/sparc.c (niagara4_costs): New processor costs.
17244         (sparc_option_override): Use it.
17245         (sparc_use_sched_lookahead): Return 2 for niagara4.
17246         (sparc_issue_rate): Likewise.
17247
17248         * config/sparc/sparc.md (attr type): Delete 'fgm_cmp'.
17249         (fpack16_vis, fpackfix_vis, fpack32_vis): Set type to fgm_pack.
17250         (fmul8x16_vis, fmul8x16au_vis, fmul8x16al_vis, fmul8sux16_vis,
17251         fmul8ulx16_vis, fmuld8sux16_vis, fmuld8ulx16_vis): Set type to fgm_mul.
17252         (alignaddrsi_vis, alignaddrdi_vis, alignaddrlsi_vis,
17253         alignaddrldi_vis): Set type to gsr.
17254         (pdist_vis, pdistn<mode>_vis): Set type to fgm_pdsit.
17255         (fcmp<code><GCM:gcm_name><P:mode>_vis, cmask8<P:mode>_vis,
17256         cmask16<P:mode>_vis, cmask32<P:mode>_vis, fchksm16_vis,
17257         v<vis3_shift_patname><mode>3, fmean16_vis,
17258         fp<plusminus_insn>64_vis, <vis3_addsub_ss_patname><mode>3,
17259         fucmp<code>8<P:mode>_vis): Set type to fga.
17260         * config/sparc/ultra1_2.md: Remove refrences to fgm_cmp.
17261         * config/sparc/niagara.md: Likewise.
17262         * config/sparc/niagara2.md: Likewise.
17263         * config/sparc/ultra3.md: Likewise, and fix type matching for
17264         us3_ialuX reservation.
17265
17266 2012-04-26  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
17267
17268         * reload.c (find_reloads): Change the loop nesting when trying an
17269         alternative with swapped operands.
17270
17271 2012-04-26  Manuel López-Ibáñez  <manu@gcc.gnu.org>
17272
17273         * tree-diagnostic.c (maybe_unwind_expanded_macro_loc): Fix
17274         comment. Delete unused parameter first_exp_point_map.
17275         (virt_loc_aware_diagnostic_finalizer): Update call.
17276
17277 2012-04-26  Michael Hope  <michael.hope@linaro.org>
17278             Richard Earnshaw  <rearnsha@arm.com>
17279
17280         * config/arm/linux-eabi.h (GLIBC_DYNAMIC_LINKER_SOFT_FLOAT): Define.
17281         (GLIBC_DYNAMIC_LINKER_HARD_FLOAT): Define.
17282         (GLIBC_DYNAMIC_LINKER_DEFAULT): Define.
17283         (GLIBC_DYNAMIC_LINKER): Redefine to use the hard float path.
17284
17285 2012-04-25  Sriraman Tallam  <tmsriram@google.com>
17286
17287         * doc/extend.texi: Document avx2 support.
17288         * config/i386/i386.c (fold_builtin_cpu): Add avx2.
17289
17290 2012-04-26  Hans-Peter Nilsson  <hp@axis.com>
17291
17292         PR target/53120
17293         * config/cris/cris.md ("*andhi_lowpart_v32")
17294         ("*andqi_lowpart_v32"): Change first input-only operand from
17295         a (match_operand ...) to (match_dup 0).  Drop alternatives with
17296         const_int-matching constraints for redundancy.
17297         ("*andhi_lowpart_non_v32", "*andqi_lowpart_non_v32"): Ditto.  Drop
17298         three-operand alternative.
17299
17300 2012-04-25  Jakub Jelinek  <jakub@redhat.com>
17301
17302         PR target/53110
17303         * config/i386/i386.md (and<mode>3): For andq $0xffffffff, reg
17304         instead expand it as zero extension.
17305
17306 2012-04-25  H.J. Lu  <hongjiu.lu@intel.com>
17307
17308         PR debug/52857
17309         * dwarf2out.c (dbx_reg_number): Assert return value != INVALID_REGNUM.
17310
17311 2012-04-25  Jakub Jelinek  <jakub@redhat.com>
17312
17313         * common.opt (flag_debug_types_section): Default to 0.
17314         (dwarf_version): Default to 4.
17315         (dwarf_record_gcc_switches): Default to 1.
17316         (dwarf_strict): Default to 0.
17317         * toplev.c (process_options): Don't handle dwarf_strict
17318         or dwarf_version here.
17319         * config/vxworks.c (vxworks_override_options): Don't
17320         test whether dwarf_strict or dwarf_version are negative,
17321         instead test !global_options_set.x_dwarf_*.
17322         * config/darwin.c (darwin_override_options): Default to
17323         dwarf_version 2.
17324         * doc/invoke.texi: Note that -gdwarf-4, -grecord-gcc-switches
17325         and -fno-debug-types-section are now the default.
17326
17327 2012-04-25  Jan Hubicka  <jh@suse.cz>
17328
17329         * cgraphunit.c: Update toplevel comment.
17330         (tree_rest_of_compilation): Merge into cgraph_expand_function.
17331         (cgraph_analyze_function): Make static.
17332         (cgraph_decide_is_function_needed): Make static.
17333         (cgraph_add_new_function): Use expand_function instead of
17334         rest_of_compilation.
17335         (clone_of_p, verify_edge_count_and_frequency, cgraph_debug_gimple_stmt,
17336         verify_edge_corresponds_to_fndecl, verify_cgraph_node, verify_cgraph):
17337         Move to cgraph.c
17338         (cgraph_inline_p): Remove.
17339         (cgraph_preserve_function_body_p): Move to ipa-inline-transform.
17340         (init_cgraph): Add comment.
17341         * cgraphbuild.c (record_reference, mark_address, mark_load,
17342         mark_store): Do not call analyze_expr hook.
17343         * cgraph.c: Update toplevel comment.
17344         (clone_of_p, verify_edge_count_and_frequency, cgraph_debug_gimple_stmt,
17345         verify_edge_corresponds_to_fndecl, verify_cgraph_node, verify_cgraph):
17346         Move fere from cgraphunit.c
17347         (cgraph_mark_force_output_node): Move to cgraph.h
17348         * cgraph.h: Reorder so the comments match the function placement.
17349         (cgraph_analyze_function, cgraph_decide_is_function_needed): Remove.
17350         (cgraph_mark_force_output_node): Move here from cgraph.c
17351         * tree.c (free_lang_data): Do not clear analyze_expr hook.
17352         * ipa-inline-transform.c (preserve_function_body_p): New function.
17353         (inline_transform): Update.
17354         * langhooks.c (lhd_callgraph_analyze_expr): Remove.
17355         * langhooks.h (lang_hooks_for_callgraph): Remove.
17356         (lang_hooks): Remove callgraph.
17357         * tree-inline.c (expand_call_inline): Do not use cgraph_inline_p.
17358         * varpool.c: Remove out of date comment.
17359         * langhooks-def.h (lhd_callgraph_analyze_expr): Remove.
17360         (LANG_HOOKS_CALLGRAPH_ANALYZE_EXPR): Remove.
17361
17362 2012-04-25  Jan Hubicka  <jh@suse.cz>
17363
17364         PR middle-end/53089
17365         * cgraphunit.c (referred_to_p): Move ahead in file to avoid
17366         forward declaration.
17367         (cgraph_finalize_function): Finalize them here.
17368         * symtab.c (dump_symtab): Dump ctors and dtors.
17369
17370 2012-04-25  Jakub Jelinek  <jakub@redhat.com>
17371
17372         PR middle-end/52979
17373         * stor-layout.c (get_best_mode): Don't return mode with bitsize
17374         larger than maxbits.  Don't compute maxbits modulo align.
17375         Also check that unit bytes long store at bitpos / unit * unit
17376         doesn't affect bits beyond bitregion_end.
17377         * expmed.c (store_bit_field_1): Avoid trying insv if OP_MODE MEM
17378         would not fit into bitregion_start ... bitregion_end + 1 bit region.
17379         (store_split_bit_field): Decrease unit close to end of bitregion_end
17380         if access is restricted in order to avoid mutual recursion.
17381
17382         PR tree-optimization/53058
17383         * double-int.h (double_int_max_value, double_int_min_value): New
17384         prototypes.
17385         * double-int.c (double_int_max_value, double_int_min_value): New
17386         functions.
17387         * tree-vrp.c (register_edge_assert_for_2): Compare mask for LE_EXPR
17388         or GT_EXPR with double_int_max_value instead of double_int_mask.
17389
17390 2012-04-25  Richard Guenther  <rguenther@suse.de>
17391
17392         * tree-vectorizer.h (vect_loop_versioning): Adjust prototype.
17393         * tree-vect-loop.c (vect_transform_loop): Adjust.
17394         * tree-vect-loop-manip.c (vect_do_peeling_for_loop_bound): Record
17395         the maximum number of iterations for the epilogue loop.
17396         (vect_loop_versioning): Remove case re-using the peeled epilogue loop.
17397
17398 2012-04-25  Jakub Jelinek  <jakub@redhat.com>
17399
17400         PR c/52880
17401         * c-typeck.c (set_nonincremental_init,
17402         set_nonincremental_init_from_string): Pass true instead of false
17403         as IMPLICIT to add_pending_init.
17404
17405 2012-04-25  Manuel López-Ibáñez  <manu@gcc.gnu.org>
17406
17407         * c-typeck.c (pop_init_level): Improve diagnostics.
17408
17409 2012-04-25  Uros Bizjak  <ubizjak@gmail.com>
17410
17411         * compare-elim.c (try_eliminate_compare): Also handle operands with
17412         implicit extensions.
17413
17414 2012-04-25  Alan Modra  <amodra@gmail.com>
17415
17416         * config/rs6000/rs6000 (SAVE_INLINE_VRS, REST_INLINE_VRS,
17417         V_SAVE_INLINE, SAVRES_LR, SAVRES_SAVE, SAVRES_REG,
17418         SAVRES_GPR, SAVRES_FPR, SAVRES_VR): Define.
17419         (no_global_regs_above): Delete.
17420         (no_global_regs): New function.
17421         (rs6000_savres_strategy): Handle vector regs.  Use proper lr_save_p
17422         value for load multiple test.
17423         (savres_routine_syms): Increase size.
17424         (rs6000_savres_routine_name, rs6000_savres_routine_sym,
17425         ptr_regno_for_savres, rs6000_emit_savres_rtx): Pass in int selector
17426         rather than a number of boolean flags.  Update all callers.
17427         (rs6000_savres_routine_name): Generate vector save/restore names.
17428         (rs6000_savres_routine_sym): Handle vector regs.  Delete forward decl.
17429         (ptr_regno_for_savres, rs6000_emit_savres_rtx): Likewise.
17430         (rs6000_emit_prologue): Delete saving_FPRs_inline, saving_GPRs_inline
17431         and using_store_multiple.  Expand uses.  Don't always use r11 as
17432         frame reg when needed for out-of-line saves.  Set up initial offset
17433         for out-of-line vector saves when buying stack frame.  Handle pointer
17434         reg setup for out-of-line fp save.  Emit call to out-of-line vector
17435         save function.  Choose r11 or r12 for vrsave reg when available for
17436         better scheduling.
17437         (rs6000_output_function_prologue): Don't emit .extern for ELF.
17438         (rs6000_emit_epilogue): Choose a better frame reg when restoring
17439         from back-chain to suit out-of-line vector restore functions.  Emit
17440         call to out-of-line vector restore function.  Adjust register used
17441         for cr restore.  Tweak pointer register setup for gpr restore.
17442         * config/rs6000/rs6000.h (FIRST_SAVED_GP_REGNO): Take into account
17443         FIXED_R13.
17444         * config/rs6000/sysv4.h (FP_SAVE_INLINE, GP_SAVE_INLINE): Simplify.
17445         (V_SAVE_INLINE): Define.
17446         * config/rs6000/altivec.md (save_vregs_*, restore_vregs_*): New insns.
17447
17448 2012-04-25  Alan Modra  <amodra@gmail.com>
17449
17450         * config/rs6000/rs6000.c (rs6000_savres_strategy): Allow
17451         out-of-line save/restore for large frames.  Don't disable
17452         out-of-line saves on ABI_AIX when using static chain reg.
17453         (rs6000_emit_prologue): Adjust cr_save_regno on ABI_AIX to not
17454         clobber static chain reg, and tweak for out-of-line gpr saves
17455         that use r1.
17456
17457 2012-04-25  Alan Modra  <amodra@gmail.com>
17458
17459         * config/rs6000/rs6000.c (START_USE, END_USE, NOT_INUSE): Define.
17460         (rs6000_emit_prologue): Use the above to catch register overlap.
17461
17462 2012-04-25  Alan Modra  <amodra@gmail.com>
17463
17464         * config/rs6000/rs6000.c (rs6000_emit_stack_reset): Delete forward
17465         decl.  Move logic selecting update reg to callers.  Update all callers.
17466         (rs6000_emit_allocate_stack): Add copy_off param.
17467         (emit_frame_save): Don't handle reg+reg addressing.
17468         (ptr_regno_for_savres): New function, extracted from..
17469         (rs6000_emit_savres_rtx): ..here.  Add lr_offset param.
17470         (rs6000_emit_prologue): Generate frame_ptr_rtx as we need it.
17471         Set frame_reg_rtx to r11 whenever r11 is needed, and merge
17472         frame offset adjustment for out-of-line save with copy from sp.
17473         Simplify condition controlling whether cr is saved early or
17474         late.  Use ptr_regno_for_savres to verify correct reg is set
17475         up for out-of-line saves.  Pass the actual pointer reg used to
17476         rs6000_emit_savres_rtx so rtl matches insns in out-of-line
17477         function.  Rearrange spe vars so code is similar to that
17478         elsewhere in this function.  Don't update frame_off when spe
17479         save code will restore r11.  Use emit_frame_save for spe and
17480         gpr saves.  Consolidate darwin out-of-line gpr setup with that
17481         for other abis.  Don't assume frame_offset is zero and frame
17482         reg is sp when setting up altivec reg saves, and calculate
17483         exact offset requirement.
17484         (rs6000_emit_epilogue): Use HOST_WIDE_INT for frame_off.  Tidy
17485         spe restore code.  Consolidate darwin out-of-line gpr setup
17486         with that for other abis.
17487
17488 2012-04-25  Alan Modra  <amodra@gmail.com>
17489
17490         * config/rs6000/rs6000.c (rs6000_frame_related): Don't emit a
17491         REG_FRAME_RELATED_EXPR note when the instruction exactly matches
17492         the replacement.
17493         (emit_frame_save): Delete frame_ptr param.  Rename total_size to
17494         frame_reg_to_sp.
17495         (rs6000_emit_prologue): Add sp_off.  Update rs6000_frame_related
17496         and emit_frame_save calls.  Cope with possibly missing note.
17497
17498 2012-04-24  Sriraman Tallam  <tmsriram@google.com>
17499
17500         * config/i386/i386.c (build_processor_model_struct): New function.
17501         (make_var_decl): New function.
17502         (fold_builtin_cpu): New function.
17503         (ix86_fold_builtin): New function.
17504         (make_cpu_type_builtin): New function.
17505         (ix86_init_platform_type_builtins): New function.
17506         (ix86_expand_builtin): Expand new builtins by folding them.
17507         (ix86_init_builtins): Make new builtins to detect CPU type.
17508         (TARGET_FOLD_BUILTIN): New macro.
17509         (IX86_BUILTIN_CPU_INIT): New enum value.
17510         (IX86_BUILTIN_CPU_IS): New enum value.
17511         (IX86_BUILTIN_CPU_SUPPORTS): New enum value.
17512         * config/i386/i386-builtin-types.def: New function type.
17513         * testsuite/gcc.target/builtin_target.c: New testcase.
17514         * doc/extend.texi: Document builtins.
17515
17516 2012-04-24  Olivier Hainque  <hainque@adacore.com>
17517
17518         * common.opt (gdwarf-): Initialize dwarf_version to -1 instead of 2.
17519         * toplev.c (process_options): Default to dwarf_version 2.
17520         * config/vxworks.c (vxworks_override_options): Default to strict-dwarf
17521         and dwarf_version 2.
17522
17523 2012-04-24  Manuel López-Ibáñez  <manu@gcc.gnu.org>
17524
17525         * tree-pretty-print.h (default_tree_printer): Do not declare.
17526         * tree-diagnostic.c: Include tree-pretty-print.h, tree-pass.h and
17527         intl.h.
17528         (default_tree_diagnostic_starter): Make static.
17529         (default_tree_printer): Move to here. Make static.
17530         (tree_diagnostics_defaults): New.
17531         * tree-diagnostic.h (default_tree_diagnostic_starter): Do not declare.
17532         * tree.c (free_lang_data): Use tree_diagnostics_defaults.
17533         * toplev.c: Do not include tree-pass.h.
17534         (default_tree_printer): Move from here.
17535         (general_init): Use tree_diagnostics_defaults.
17536
17537 2012-04-24  Chao-ying Fu  <fu@mips.com>
17538
17539         * config.gcc (mips64*-*-linux*): Append mips/linux-common.h to tm_file.
17540         (mips*-*-linux*): Append mips/linux-common.h to tm_file.
17541         * config/mips/gnu-user.h
17542         (SUBTARGET_CC1_SPEC): Use GNU_USER_TARGET_CC1_SPEC directly.
17543         (GNU_USER_TARGET_LINK_SPEC): New define.
17544         (LINK_SPEC): Use GNU_USER_TARGET_LINK_SPEC.
17545         (LIB_SPEC): Use GNU_USER_TARGET_LIB_SPEC directly.
17546         (GNU_USER_TARGET_MATHFILE_SPEC): New define.
17547         (ENDFILE_SPEC): Use GNU_USER_TARGET_MATHFILE_SPEC and
17548         GNU_USER_TARGET_ENDFILE_SPEC.
17549         * config/mips/gnu-user64.h (LIB_SPEC): Remove.
17550         (GNU_USER_TARGET_LINK_SPEC): New define.
17551         (LINK_SPEC): Use GNU_USER_TARGET_LINK_SPEC.
17552         * config/mips/linux-common.h: New file.
17553
17554 2012-04-24  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
17555
17556         PR target/47197
17557         * config/rs6000/rs6000-c.c (fully_fold_convert): New function.
17558         (altivec_build_resolved_builtin): Call fully_fold_convert.
17559
17560 2012-04-24  Georg-Johann Lay  <avr@gjlay.de>
17561
17562         PR target/53065
17563         * config/avr/avr.h (HARD_REGNO_CALL_PART_CLOBBERED): New hook define.
17564
17565 2012-04-24  Richard Guenther  <rguenther@suse.de>
17566
17567         PR tree-optimization/53085
17568         * tree-ssa-pre.c (eliminate): Do not eliminate volatile redundant
17569         stores.
17570
17571 2012-04-24  Richard Guenther  <rguenther@suse.de>
17572
17573         * tree-if-conv.c (main_tree_if_conversion): Move bb under
17574         ENABLE_CHECKING.
17575
17576 2012-04-24  Jim Meyering  <meyering@redhat.com>
17577
17578         * genattrtab.c (gen_attr): Avoid NULL-deref after diagnosing
17579         absence of an define_enum call.
17580
17581 2012-04-24  Richard Guenther  <rguenther@suse.de>
17582
17583         * tree-vect-loop-manip.c (vect_do_peeling_for_loop_bound): If
17584         the epilogue loop is not re-used as unvectorized version
17585         record the its maximum number of iterations.
17586
17587 2012-04-24  Andrew Pinski  <apinski@cavium.com>
17588
17589         * tree-ssa-forwprop.c (simplify_bitwise_binary):
17590         Don't directly use def1/def2.
17591
17592 2012-04-24  Richard Guenther  <rguenther@suse.de>
17593
17594         PR tree-optimization/53098
17595         * tree-vect-loop.c (vect_analyze_loop_operations): Fixup
17596         comparison sign.
17597
17598 2012-04-24  Andrew Pinski  <apinski@cavium.com>
17599
17600         PR tree-opt/33512
17601         * tree-ssa-forwprop.c (defcodefor_name): New function.
17602         (simplify_bitwise_binary): Use defcodefor_name instead of manually
17603         Simplify "( X | Y) & X" to X and "( X & Y) | X" to X.
17604         Simplify "(~X | Y) & X" to "X & Y" and
17605         "(~X & Y) | X" to "X | Y".
17606
17607 2012-04-24  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
17608
17609         * recog.c (insn_invalid_p): Add IN_GROUP parameter and use
17610         validate_change to add clobbers if IN_GROUP is nonzero.
17611         (verify_changes): Call insn_invalid_p with IN_GROUP set to true.
17612         * recog.h (insn_invalid_p): Add IN_GROUP parameter to function
17613         prototype.
17614         * gcse.c (process_insert_insn): Call insn_invalid_p with IN_GROUP
17615         set to false.
17616         * config/s390/s390.c (insn_invalid_p): Likewise.
17617
17618 2012-04-24  Jakub Jelinek  <jakub@redhat.com>
17619
17620         PR middle-end/53084
17621         * varasm.c (compute_reloc_for_constant): Handle ADDR_EXPR of MEM_REF.
17622         (output_addressed_constants): Likewise.
17623
17624         PR middle-end/52999
17625         * varasm.c (get_section): Don't ICE for section conflicts with
17626         built-in section kinds.
17627
17628 2012-04-23  DJ Delorie  <dj@redhat.com>
17629
17630         * config/s390/s390.h (LINK_SPEC): Remove, no longer needed.
17631         (LIBSTDCXX): Change to CPP2.
17632
17633 2012-04-23  H.J. Lu  <hongjiu.lu@intel.com>
17634
17635         PR bootstrap/52878
17636         * opth-gen.awk: Check if MASK_ and TARGET_ macros are defined for
17637         extra_masks.
17638
17639 2012-04-23  Uros Bizjak  <ubizjak@gmail.com>
17640
17641         * config/i386/i386.md (*add<mode>_2): Add r/r/0 alternative.
17642         (*addsi_2_zext): Ditto.
17643         (*add<mode>_3): Ditto.
17644         (*addsi_3_zext): Ditto.
17645         (*add<mode>_5): Ditto.
17646
17647 2012-04-23  Andrew Pinski  <apinski@cavium.com>
17648
17649         * tree-ssa-forwprop.c (simplify_bitwise_binary): Simplify (A & B) OP0
17650         (C & B) to (A OP0) & B.
17651
17652 2012-04-23  Martin Jambor  <mjambor@suse.cz>
17653
17654         * expr.c (expand_expr_real_1): Remove setting parent's alias set for
17655         temporaries created for a bitfield (reverting revision 122014).
17656
17657 2012-04-23  Richard Guenther  <rguenther@suse.de>
17658
17659         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Gimplify
17660         the condition using is_gimple_condexpr and avoid the not necessary
17661         boolification.
17662         (set_prologue_iterations): Likewise.
17663         (vect_loop_versioning): Likewise.
17664
17665 2012-04-23  Richard Guenther  <rguenther@suse.de>
17666
17667         PR tree-optimization/53070
17668         * tree-if-conv.c (combine_blocks): Free predicates in all blocks.
17669         (main_tree_if_conversion): Verify we succeeded in that.
17670
17671 2012-04-23  Jan Hubicka  <jh@suse.cz>
17672
17673         * lto-symtab.c (lto_cgraph_replace_node): Do not call
17674         mark_reahcable_node.
17675         * cgraph.c (cgraph_remove_node): Do not clear reachable.
17676         (cgraph_mark_reachable_node): Remove.
17677         (cgraph_mark_force_output_node): Do not set reachable.
17678         (dump_cgraph_node): Do not dump reachable.
17679         (cgraph_create_virtual_clone): Do not set reachable.
17680         * cgraph.h (cgraph_node): Remove reachable flag.
17681         (varpool_node): Remove reachable flag.
17682         (cgraph_mark_if_needed): Remove.
17683         (cgraph_mark_reachable_node): Remove.
17684         * tree-emutls.c (ipa_lower_emutls): Do not check reachable.
17685         * cgraphunit.c (cgraph_finalize_function): Do not mark node as
17686         reachable.
17687         (cgraph_add_new_function): Likewise.
17688         (cgraph_mark_if_needed): Remove.
17689         (cgraph_analyze_function): Do not set target as reachable.
17690         (process_function_and_variable_attributes): Do not care about
17691         dllexport.
17692         (cgraph_analyze_functions): Do not set reachable flags.
17693         (cgraph_mark_functions_to_output): Do not check reachability.
17694         (cgraph_copy_node_for_versioning): Do not set reachable flag.
17695         (dbxout_expand_expr): Update.
17696         * c-decl.c (merge_decls): Do not track changed externs.
17697         * ipa.c: Include pointer-set.h
17698         (enqueue_cgraph_node): Use reachable pointer set.
17699         (process_references): Likewise.
17700         (cgraph_remove_unreachable_nodes): Likewise.
17701         (whole_program_function_and_variable_visibility): Do not recompute
17702         reachable.
17703         * trans-mem.c (ipa_tm_execute): Do not check reachable flag.
17704
17705 2012-04-23  Georg-Johann Lay  <avr@gjlay.de>
17706
17707         * doc/extend.texi (AVR Named Address Spaces): Fix typos.
17708
17709 2012-04-23  Richard Guenther  <rguenther@suse.de>
17710
17711         PR c/53060
17712         * c-typeck.c (build_binary_op): Fix typo.
17713
17714 2012-04-23  Jakub Jelinek  <jakub@redhat.com>
17715
17716         PR tree-optimizations/52891
17717         * tree-vect-patterns.c (adjust_bool_pattern): Use
17718         build_nonstandard_type even if rhs1 has unsigned INTEGER_TYPE,
17719         but with non-standard precision.
17720
17721 2012-04-22  Jan Hubicka  <jh@suse.cz>
17722
17723         * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Bail out at NULL
17724         tree refs.
17725
17726 2012-04-22  Jan Hubicka  <jh@suse.cz>
17727
17728         * lto-symtab.c (lto_varpool_replace_node): Do not merge needed flags.
17729         * cgraphbuild.c (record_reference, record_type_list, mark_address,
17730         mark_load, mark_store): Do not mark varpool nodes as needed.
17731         * cgraph.c (cgraph_new_nodes): Remove.
17732         (cgraph_create_function_alias): Do not mark nodes as reachable.
17733         (cgraph_add_thunk): Likewise.
17734         (cgraph_mark_reachable_node): Do not manage the queue.
17735         * cgraph.h (cgraph_node): Remove next_needed.
17736         (varpool_nodes_queue): Remove next_needed and prev_needed.
17737         (x_cgraph_nodes_queue, x_cgraph_nodes_queue, cgraph_new_nodes): Remove.
17738         (cgraph_new_nodes): Declare.
17739         (x_varpool_nodes_queue, varpool_nodes_queue); Remove.
17740         (varpool_analyze_pending_decls): Remove.
17741         (varpool_analyze_node): New.
17742         (varpool_mark_needed_node): Remove.
17743         (varpool_first_variable, varpool_next_variable): New inlines.
17744         (varpool_first_static_initializer, varpool_next_static_initializer):
17745         Update.
17746         (FOR_EACH_STATIC_VARIABLE): Remove unused walker.
17747         (varpool_first_defined_variable): New inline.
17748         (varpool_next_defined_variable): New inline
17749         (FOR_EACH_VARIABLE): Reimplement.
17750         (FOR_EACH_DEFINED_VARIABLE): Reimplement.
17751         * toplev.c (wrapup_global_declaration_2): Use analyzed instead of
17752         needed flag.
17753         * cgraphunit.c (cgraph_new_nodes): Declare here.
17754         (enqueue_node): New function.
17755         (cgraph_process_new_functions): update for new
17756         node set; when constructing cgraph enqueue node for processing.
17757         (cgraph_add_new_function): Use new node set.
17758         (process_function_and_variable_attributes): Do not set varpool needed
17759         flags.
17760         (referred_to_p): New function.
17761         (varpool_finalize_decl): Move here from varpool.c; enqueue needed node
17762         when varpool is in construction.
17763         (cgraph_analyze_functions): Rewrite.
17764         (cgraph_expand_all_functions): Update.
17765         (cgraph_output_in_order): Do not analyze pending decls; do not set
17766         needed flags.
17767         (cgraph_optimize): Do not analyze pending decls.
17768         * lto-cgraph.c (input_varpool_node): Clear analyzed flag for objects
17769         in other partition; do not mark node as needed.
17770         * dwarf2out.c (reference_to_unused): Use analyzed flag.
17771         (premark_types_used_by_global_vars_helper): Likewise.
17772         * ipa.c (process_references): Do not call varpool_mark_needed_node.
17773         (cgraph_remove_unreachable_nodes): Do not rely on varpool and
17774         cgrpah queues.
17775         (function_and_variable_visibility): Do not mark node as needed.
17776         (whole_program_function_and_variable_visibility): Likewise.
17777         * Makefile.in (gt-varpool.h): No longer needed.
17778         * passes.c (execute_one_pass, execute_ipa_pass_list): Update.
17779         (ipa_write_summaries): Do not use needed flag.
17780         * varpool.c: Do not include gt-varpool.h
17781         (x_varpool_nodes_queue, x_varpool_last_needed_node,
17782         x_varpool_last_needed_node, x_varpool_first_unanalyzed_node,
17783         x_varpool_first_unanalyzed_node, varpool_assembled_nodes_queue):
17784         Remove.
17785         (varpool_remove_node): Do not update the lists.
17786         (dump_varpool_node): Do not dump needed flag.
17787         (varpool_enqueue_needed_node): Remove.
17788         (varpool_mark_needed_node): Remove.
17789         (varpool_reset_queue): Remove.
17790         (varpool_finalize_decl): Move to cgraphunit.c
17791         (varpool_analyze_node): New functions based on former
17792         varpool_analyze_pending_decls.
17793         (varpool_analyze_pending_decls): Remove.
17794         (varpool_assemble_decl): Do not update the lists.
17795         (enqueue_node): New function.
17796         (varpool_remove_unreferenced_decls): Rewrite.
17797         (varpool_empty_needed_queue): Remove.
17798         (add_new_static_var): Do not mark node as needed.
17799         (varpool_create_variable_alias): Handle expansion state
17800         creation.
17801         * except.c (output_ttype): Do not mark node as needed.
17802         * varasm.c (mark_decl_referenced): Do not use mark_needed_node.
17803         * tree-profile.c (init_ic_make_global_vars, init_ic_make_global_vars):
17804         Likewise.
17805         * tree-switch-conversion.c (build_one_array): Likewise.
17806
17807 2012-04-22  Manuel López-Ibáñez  <manu@gcc.gnu.org>
17808
17809         PR c/44774
17810         * doc/invoke.texi (pedantic): Rename to Wpedantic.
17811         * common.opt (Wpedantic): New.
17812         (pedantic): Alias Wpedantic.
17813         * diagnostic.c (warning_at): Likewise.
17814         * c-decl.c (diagnose_mismatched_decls): Likewise.
17815         (build_array_declarator): Likewise.
17816         (mark_forward_parm_decls):
17817         (check_bitfield_type_and_width): Likewise.
17818         (grokdeclarator): Likewise.
17819         (grokfield): Likewise.
17820         (finish_struct): Likewise.
17821         (build_enumerator): Likewise.
17822         (store_parm_decls_oldstyle): Likewise.
17823         (declspecs_add_qual): Likewise.
17824         (declspecs_add_type): Likewise.
17825         (finish_declspecs): Likewise.
17826         * c-typeck.c (composite_type): Likewise.
17827         (comp_target_types): Likewise.
17828         (build_array_ref): Likewise.
17829         (pointer_diff): Likewise.
17830         (build_unary_op): Likewise.
17831         (build_conditional_expr): Likewise.
17832         (build_c_cast): Likewise.
17833         (convert_for_assignment): Likewise.
17834         (maybe_warn_string_init): Likewise.
17835         (digest_init): Likewise.
17836         (pop_init_level): Likewise.
17837         (set_init_index): Likewise.
17838         (c_finish_goto_label): Likewise.
17839         (c_finish_return): Likewise.
17840         (do_case): Likewise.
17841         (build_binary_op): Likewise.
17842         * c-parser.c (static): Likewise.
17843         (c_parser_external_declaration): Likewise.
17844         (c_parser_declaration_or_fndef): Likewise.
17845         (c_parser_static_assert_declaration_no_se): Likewise.
17846         (c_parser_enum_specifier): Likewise.
17847         (c_parser_struct_or_union_specifier): Likewise.
17848         (c_parser_struct_declaration): Likewise.
17849         (c_parser_alignas_specifier): Likewise.
17850         (c_parser_braced_init): Likewise.
17851         (c_parser_initelt): Likewise.
17852         (c_parser_compound_statement_nostart): Likewise.
17853         (c_parser_conditional_expression): Likewise.
17854         (c_parser_alignof_expression): Likewise.
17855         (c_parser_postfix_expression): Likewise.
17856         (c_parser_postfix_expression_after_paren_): Likewise.
17857         (c_parser_objc_class_instance_variables): Likewise.
17858         (c_parser_objc_method_definition): Likewise.
17859         (c_parser_objc_methodprotolist): Likewise.
17860
17861 2012-04-22  Ian Lance Taylor  <iant@google.com>
17862
17863         * godump.c (go_output_typedef): Dump size of structs.
17864
17865 2012-04-22  Razya Ladelsky  <razya@il.ibm.com>
17866
17867         Correcting transform_to_exit_first_loop + fix to PR46886
17868         * tree-parloops.c (transform_to_exit_first_loop): Remove
17869         setting of number of iterations according to the loop pattern.
17870         Duplicate from entry to exit->src instead of loop->latch.
17871         (pallelize_loops): Remove the condition preventing do-while loops.
17872         * tree-cfg.c (bool bb_in_region_p): New.
17873         (gimple_duplicate_sese_tail): Adjust duplication of the the subloops.
17874         Adjust redirection of the duplicated iteration.
17875
17876 2012-04-21  Richard Sandiford  <rdsandiford@googlemail.com>
17877
17878         PR bootstrap/53021
17879         * rtl.def (ADDRESS): Use "i" rather than "w".
17880         * rtl.h (find_base_term): Delete.
17881         (may_be_sp_based_p): Declare.
17882         * rtl.c (rtx_code_size): Remove ADDRESS special case.
17883         * alias.h (UNIQUE_BASE_VALUE_SP, UNIQUE_BASE_VALUE_ARGP)
17884         (UNIQUE_BASE_VALUE_FP, UNIQUE_BASE_VALUE_HFP): Move to...
17885         * alias.c: ...here.
17886         (find_base_term): Make static.
17887         (may_be_sp_based_p): New function.
17888         * dse.c (record_store): Use it.
17889         * store-motion.c (store_killed_in_insn): Likewise.
17890
17891 2012-04-21  Richard Sandiford  <rdsandiford@googlemail.com>
17892
17893         * fold-const.c (fold_checksum_tree): Fix VECTOR_CST case.
17894
17895 2012-04-21  Manuel López-Ibáñez  <manu@gcc.gnu.org>
17896
17897         PR 35441
17898         * c-typeck.c (inform_declaration): New.
17899         (build_function_call_vec):  Do not pretty-print
17900         expressions when caret is enabled.
17901         (convert_arguments): Use inform_declaration.
17902
17903 2012-04-20  Jim Meyering  <meyering@redhat.com>
17904
17905         * genmodes.c (make_complex_modes): Don't truncate a mode name of
17906         length 7 or more when prepending a "C".  Suggested by Richard Guenther.
17907
17908 2012-04-20  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
17909
17910         PR rtl-optimization/44214
17911         * fold-const.c (exact_inverse): New function.
17912         (fold_binary_loc): Fold vector and complex division by constant into
17913         multiply by recripocal with flag_reciprocal_math; fold vector division
17914         by constant into multiply by reciprocal with exact inverse.
17915
17916 2012-04-20  Jan Hubicka  <jh@suse.cz>
17917
17918         * lto-symtab.c (lto_cgraph_replace_node): Merge needed instead of
17919         force flags.
17920         * cgraph.c (cgraph_add_thunk): Use mark_reachable_node.
17921         (cgraph_remove_node): Update.
17922         (cgraph_mark_needed_node): Remove.
17923         (cgraph_mark_force_output_node): New.
17924         (dump_cgraph_node): Do not dump needed flag.
17925         (cgraph_node_cannot_be_local_p_1): Update.
17926         (cgraph_can_remove_if_no_direct_calls_and_refs): Update.
17927         * cgraph.h (symtab_node_base): Add force_output flag.
17928         (cgraph_node): Remove needed flag.
17929         (varpool_node): Remove force_output flag.
17930         (cgraph_mark_needed_node): Remove.
17931         (cgraph_mark_force_output_node): New.
17932         (cgraph_only_called_directly_or_aliased_p,
17933         varpool_can_remove_if_no_refs, varpool_all_refs_explicit_p): Update.
17934         * ipa-cp.c (ipcp_generate_summary): Remove out of date assert.
17935         * cgraphunit.c (cgraph_decide_is_function_needed): rewrite.
17936         (cgraph_add_new_function): Update.
17937         (cgraph_mark_if_needed): Update.
17938         (verify_cgraph_node): Update.
17939         (cgraph_analyze_function): Alias target is reachable.
17940         (process_function_and_variable_attributes): Update: externally_visible
17941         flag makes function reachable.
17942         (cgraph_analyze_functions): Update dumping.
17943         * lto-cgraph.c (lto_output_node, lto_output_varpool_node,
17944         input_overwrite_node, input_varpool_node): Update streaming.
17945         * lto-streamer-out.c (produce_symtab): Use force_output.
17946         * ipa.c (process_references): Weakrefs must be processed.
17947         (cgraph_remove_unreachable_nodes): Likewise; update for new
17948         force_output flag.
17949         (varpool_externally_visible_p): Weakrefs are externally visible
17950         even if they are not.
17951         (function_and_variable_visibility): Update; when processing alias
17952         pair force the targets to be output.
17953         (whole_program_function_and_variable_visility): Use
17954         mark_reachable_node.
17955         * trans-mem.c (ipa_tm_mark_needed_node): Remove
17956         (ipa_tm_mark_force_output_node): New function.
17957         (ipa_tm_create_version_alias, ipa_tm_create_version): Update.
17958         * gimple-fold.c (can_refer_decl_in_current_unit_p): Be lax about
17959         aliases.
17960         * varasm.c (mark_decl_referenced): Update.
17961         (find_decl_and_mark_needed): Remove.
17962         (find_decl): New function.
17963         (weak_finish, finish_aliases_1, assemble_alias): Update; do not mark
17964         alias targets as needed.
17965         (dump_tm_clone_pairs): Update.
17966         * tree-inline.c (copy_bb): Update check.
17967         * symtab.c (dump_symtab_base): Dump force_output.
17968         * tree-ssa-structalias.c (ipa_pta_execute): Use force_output.
17969         * passes.c (execute_todo): Fix dumping.
17970         * varpool.c (decide_is_variable_needed, varpool_finalize_decl): Update.
17971         (varpool_analyze_pending_decls): Alias target is reachable.
17972         (varpool_create_variable_alias): Finalize weakrefs.
17973
17974 2012-04-20  Jakub Jelinek  <jakub@redhat.com>
17975
17976         PR bootstrap/53021
17977         * alias.h (UNIQUE_BASE_VALUE_SP, UNIQUE_BASE_VALUE_ARGP,
17978         UNIQUE_BASE_VALUE_FP, UNIQUE_BASE_VALUE_HFP): Define.
17979         * alias.c (init_alias_targets): Use UNIQUE_BASE_VALUE_*
17980         macros instead of constants.
17981         * dse.c (record_store): Check for SP ADDRESS by comparing
17982         XWINT to UNIQUE_BASE_VALUE_SP instead of expecting
17983         XEXP to be stack_pointer_rtx.
17984
17985 2012-04-20  Richard Guenther  <rguenther@suse.de>
17986
17987         * tree-ssa-copy.c (propagate_tree_value_into_stmt): Use
17988         update_call_from_tree when propagating into a call.
17989
17990 2012-04-20  Alan Modra  <amodra@gmail.com>
17991
17992         * config/rs6000/rs6000.c (rs6000_emit_savres_rtx): Formatting.
17993         (rs6000_emit_prologue, rs6000_emit_epilogue): Likewise.  Rename
17994         sp_offset to frame_off.  Move world save code earlier.
17995
17996 2012-04-20  Richard Guenther  <rguenther@suse.de>
17997
17998         PR tree-optimization/53050
17999         * tree-ssa-forwprop.c (ssa_forward_propagate_and_combine):
18000         Do only one transform on COND_EXPRs at the same time.
18001
18002 2012-04-19  Jan Hubicka  <jh@suse.cz>
18003
18004         * symtab.c (dump_symtab_base): Revert accidental checkin.
18005
18006 2012-04-20  Alan Modra  <amodra@gmail.com>
18007
18008         PR target/53040
18009         * config/rs6000/rs6000.c (rs6000_savres_strategy): When using
18010         static chain, set REST_INLINE_FPRS too.
18011
18012 2012-04-20  Thomas Schwinge  <thomas@codesourcery.com>
18013
18014         * tree-dump.c (dequeue_and_dump) <BIT_FIELD_REF>: Dump the three child
18015         nodes.
18016
18017 2012-04-20  Richard Guenther  <rguenther@suse.de>
18018
18019         * tree-vect-loop.c (vect_analyze_loop_operations): Do not vectorize
18020         loops that can never run more often than the vectorization factor.
18021
18022 2012-04-19  Jan Hubicka  <jh@suse.cz>
18023
18024         * symtab.c (dump_symtab_base): Fix dumping of asm lists.
18025
18026 2012-04-19  David Edelsohn  <dje.gcc@gmail.com>
18027
18028         * config/rs6000/sync.md (fetchop_name): Change ior attribute to "or".
18029
18030 2012-04-19  Jim Meyering  <meyering@redhat.com>
18031
18032         * genmodes.c (make_complex_modes): Avoid unnecessary use of strncpy.
18033         We verified above that the string(including trailing NUL) fits in buf,
18034         so just use memcpy.
18035
18036 2012-04-19  Richard Guenther  <rguenther@suse.de>
18037
18038         * symtab.c (dump_symtab_base): Use TREE_STRING_POINTER
18039         for dumping DECL_SECTION_NAME.
18040
18041 2012-04-19  Michael Matz  <matz@suse.de>
18042
18043         PR middle-end/52977
18044         * tree.h (VECTOR_CST_NELTS): Use part number of types again.
18045         (struct tree_vector): Adjust GTY length.
18046         * tree.c (make_vector_stat): Don't set VECTOR_CST_NELTS.
18047
18048         * gengtype.c (struct walk_type_data): Add in_record_p and loopcounter
18049         members.
18050         (walk_type, <TYPE_POINTER, TYPE_ARRAY>): Handle case where our
18051         caller emitted the length calulation already.
18052         (walk_type, <TYPE_UNION, TYPE_STRUCT>): Emit length calculations
18053         before handling any of the fields for structs.
18054
18055 2012-04-19  Richard Guenther  <rguenther@suse.de>
18056
18057         PR tree-optimization/53031
18058         * tree-vrp.c (adjust_range_with_scev): Revert back to
18059         using max_loop_iterations.
18060
18061 2012-04-19  Michael Matz  <matz@suse.de>
18062
18063         * diagnostic.c (emit_diagnostic): Move va_end call after user
18064         of the va_list.
18065         (warning, warning_at, pedwarn, permerror): Ditto.
18066
18067 2012-04-19  Richard Guenther  <rguenther@suse.de>
18068
18069         * ira-int.h (ira_allocno_object_iter_cond): Avoid out-of-bound
18070         array access.
18071
18072 2012-04-19  Georg-Johann Lay  <avr@gjlay.de>
18073
18074         PR target/53033
18075         * config/avr/avr.c (avr_out_load_psi): Fix assembler template for
18076         the case *(X+const).
18077
18078 2012-04-19  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
18079
18080         * config/arm/sync.md (sync_optab): Change ior attribute to "or".
18081
18082 2012-04-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
18083
18084         PR c/52283/37985
18085         * stmt.c (warn_if_unused_value): Skip NOP_EXPR.
18086         * convert.c (convert_to_integer): Don't set TREE_NO_WARNING.
18087
18088 2012-04-19  Richard Guenther  <rguenther@suse.de>
18089
18090         PR rtl-optimization/44688
18091         * loop-iv.c (determine_max_iter): Only return max_iter.
18092         (iv_number_of_iterations): Also use the recorded loop bound
18093         on the maximum number of iterations.
18094         * loop-unroll.c (decide_unroll_runtime_iterations): Use
18095         max_iter to avoid unrolling loops that do not roll.
18096         (decide_unroll_stupid): Likewise.
18097
18098 2012-04-18  Steven Bosscher  <steven@gcc.gnu.org>
18099
18100         * targhooks.c (default_case_values_threshold): Fix code style nit.
18101
18102         * stmt.c (add_case_node, expand_case): Move logic to remove/reduce
18103         case range and type folding from here...
18104         * gimplify.c (gimplify_switch_expr): ... to here.  Expect NULL_TREE
18105         type, as documented in tree.def.
18106
18107 2012-04-18  Jan Hubicka  <jh@suse.cz>
18108
18109         * cgraph.h (verify_symtab, verify_symtab_node, verify_symtab_base):
18110         Declare.
18111         * cgraphunit.c (verify_cgraph_node): Verify symtab base; do not verify
18112         cgraph hash and same comdat groups.
18113         (cgraph_optimize): Verify symbol table.
18114         * ipa.c (cgraph_remove_unreachable_nodes): Verify symbol table.
18115         (dissolve_same_comdat_group_list): Work on symtab nodes.
18116         (function_and_variable_visibility): Dissolve variable same comdat group
18117         lists, too.
18118         * symtab.c: Include timevar.h
18119         (verify_symtab_base, verify_symtab_node, verify_symtab): New functions.
18120
18121 2012-04-18  Steven Bosscher  <steven@gcc.gnu.org>
18122
18123         * tree-switch-conversion.c (info): Remove global pass info.
18124         (check_range, check_process_case, check_final_bb, create_temp_arrays,
18125         free_temp_arrays, gather_default_values, build_constructors,
18126         array_value_type, build_one_array, build_arrays, gen_def_assigns,
18127         fix_phi_nodes, gen_inbound_check): Pass info around from ...
18128         (process_switch): ... here.  Unify message format.  Return a const
18129         char pointer to the failure reason message.
18130         (do_switchconv): Unify message format.  Update process_switch usage.
18131
18132         * tree.def (CASE_LABEL_EXPR): Fix documentation, mention all operands.
18133         * tree-cfg.c (edge_to_cases): Fix documentation.
18134
18135 2012-04-18  Uros Bizjak  <ubizjak@gmail.com>
18136
18137         * config/alpha/sync.md (fetchop_name): Change ior attribute to "or".
18138
18139 2012-04-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
18140
18141         PR tree-optimization/52976
18142         * tree-ssa-reassoc.c (add_to_ops_vec_max_rank): Delete.
18143         (possibly_move_powi): New function.
18144         (rewrite_expr_tree): Call possibly_move_powi.
18145         (rewrite_expr_tree_parallel): Likewise.
18146         (attempt_builtin_powi): Change call of add_to_ops_vec_max_rank to
18147         call add_to_ops_vec instead.
18148
18149 2012-04-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
18150
18151         PR tree-optimization/52976
18152         * tree-ssa-reassoc.c (stmt_is_power_of_op): New function.
18153         (decrement_power): Likewise.
18154         (propagate_op_to_single_use): Likewise.
18155         (zero_one_operation): Handle __builtin_pow* calls in linearized
18156         expression trees; factor logic into propagate_op_to_single_use.
18157         (undistribute_ops_list): Allow operands with repeat counts > 1.
18158
18159 2012-04-18  Richard Guenther  <rguenther@suse.de>
18160
18161         PR tree-optimization/44688
18162         * cfgloop.h (record_niter_bound): Declare.
18163         * tree-ssa-loop-niter.c (record_niter_bound): Export.
18164         Update the estimation with the upper bound here...
18165         (estimate_numbers_of_iterations_loop): ... instead of here.
18166         Do not forcefully reset a recorded upper bound.
18167         * tree-vect-loop-manip.c (vect_do_peeling_for_alignment):
18168         Record the maximum number of loop iterations of the prologue loop.
18169
18170 2012-04-18  Jan Hubicka  <jh@suse.cz>
18171
18172         * lto-symtab.c (lto_cgraph_replace_node): Update.
18173         * cgraphbuild.c (record_reference, record_type_list,
18174         record_eh_tables, mark_address, mark_load, mark_store): Update.
18175         * cgraph.c (cgraph_same_body_alias, dump_cgraph_node,
18176         cgraph_create_virtual_clone, cgraph_for_node_thunks_and_aliases):
18177         Update.
18178         * cgraph.h (symtab_node_def, symtab_node, const_symtab_node): Remove.
18179         (cgraph_alias_aliased_node, varpool_alias_aliased_node): Update.
18180         * reload.c: Fix typo in comment.
18181         * rtlanal.c: Likewise.
18182         * tree-emultls.c (gen_emutls_addr): Update.
18183         * ipa-reference.c (analyze_function): Update.
18184         * cgraphunit.c (cgraph_analyze_function,
18185         cgraph_process_same_body_aliases, assemble_thunks_and_aliases):
18186         Update.
18187         * ipa-ref.c (ipa_record_reference): Reorg to avoid reference types.
18188         (ipa_remove_reference): Likewise.
18189         (ipa_remove_all_refering): Rename to ...
18190         (ipa_remove_all_referring): ... this one; update.
18191         (ipa_dump_references): Update.
18192         (ipa_dump_referring): Update.
18193         (ipa_clone_references): Update.
18194         (ipa_clone_refering): Rename to ...
18195         (ipa_clone_referring): ... this one; update.
18196         (ipa_ref_cannot_lead_to_return): Update.
18197         (ipa_ref_has_aliases_p): Update.
18198         * ipa-ref.h (symtab_node_def, symtab_node, const_symtab_node): New
18199         forward typedefs.
18200         (ipa_ref_type): Remove.
18201         (ipa_ref_ptr_u): Remove.
18202         (ipa_ref): Remove referencing, refered, refered_index, refering_type
18203         and refered_type; add referring, referred and referred_index.
18204         (ipa_ref_list): Rename refering to referring.
18205         (ipa_record_reference, ipa_remove_all_referring, ipa_dump_referring,
18206         ipa_clone_references, ipa_clone_referring): Update prototypes.
18207         * lto-cgraph.c (referenced_from_other_partition_p): Update.
18208         (lto_output_ref): Update.
18209         (add_references): Update.
18210         (input_varpool_node): Update.
18211         (input_refs): Update.
18212         * ipa-ref-inline.h (ipa_ref_node): Update.
18213         (ipa_ref_varpool_node): Update.
18214         (ipa_ref_referring_node): Update.
18215         (ipa_ref_referring_varpool_node): Update.
18216         (ipa_ref_referring_ref_list): Update.
18217         (ipa_ref_referred_ref_list): Update.
18218         (ipa_ref_list_first_referring): Update.
18219         (ipa_empty_ref_list): Update.
18220         (ipa_ref_list_refering_iterate): Rename to ...
18221         (ipa_ref_list_referring_iterate): ... this one.
18222         * cse.c: Update comment.
18223         * ipa-utils.c (ipa_reverse_postorder): Update.
18224         * tree-ssa-alias.c: Update.
18225         * ipa-inline.c (reset_edge_caches): Update.
18226         (update_caller_keys): Update.
18227         * ipa-inline.h: Update comments.
18228         * jump.c: Update comment.
18229         * alias.c: Likewise.
18230         * ipa.c (process_references): Update.
18231         (cgraph_remove_unreachable_nodes): Likewise.
18232         (ipa_discover_readonly_nonaddressable_var): Likewise.
18233         (cgraph_address_taken_from_non_vtable_p): Likewise.
18234         * trans-mem.c (ipa_tm_execute): Update.
18235         * simplify-rtx.c: Fix comment.
18236         * rtl.c: Fix comment.
18237         * symtab.c (symtab_unregister_node): Update.
18238         * varpool.c (dump_varpool_node): Update.
18239         (varpool_analyze_pending_decls): Update.
18240         (assemble_aliases): Update.
18241         (varpool_for_node_and_aliases): Update.
18242
18243 2012-04-18  Richard Guenther  <rguenther@suse.de>
18244
18245         * cfgloop.h (estimate_numbers_of_iterations_loop): Remove
18246         use_undefined_p parameter.
18247         * tree-flow.h (estimate_numbers_of_iterations): Likewise.
18248         * tree-ssa-loop-niter.c (estimate_numbers_of_iterations_loop):
18249         Likewise.
18250         (estimate_numbers_of_iterations): Likewise.
18251         (estimated_loop_iterations): Adjust.
18252         (max_loop_iterations): Likewise.
18253         (scev_probably_wraps_p): Likewise.
18254         * tree-ssa-loop.c (tree_ssa_loop_bounds): Likewise.
18255         * tree-vrp.c (adjust_range_with_scev): Use max_stmt_executions,
18256         not max_loop_iterations.
18257         (execute_vrp): Remove explicit number of iterations estimation.
18258
18259 2012-04-18  Enkovich Ilya  <ilya.enkovich@intel.com>
18260
18261         * config/i386/linux-common.h: New.
18262
18263         * config.gcc: Add i386/linux-common.h before
18264         all i386/linux.h and i386/linux64.h usages.
18265
18266         * config/i386/gnu-user.h (GNU_USER_TARGET_LINK_SPEC): New.
18267         (LINK_SPEC): Use GNU_USER_TARGET_LINK_SPEC.
18268         * config/i386/gnu-user64.h: Likewise.
18269
18270         * config/i386/gnu-user.common.h (GNU_USER_TARGET_CC1_SPEC): New.
18271         (CC1_SPEC): Use GNU_USER_TARGET_CC1_SPEC.
18272         (GNU_USER_TARGET_MATHFILE_SPEC): New.
18273         (ENDFILE_SPEC): Use GNU_USER_TARGET_MATHFILE_SPEC.
18274
18275 2012-04-18  Jan Hubicka  <jh@suse.cz>
18276
18277         * cgraph.c (cgraph_node_name): Remove.
18278         (dump_cgraph_node): Use dump_symtab_base; reformat.
18279         * cgraph.h (symtab_node_asm_name, symtab_node_name, dump_symtab,
18280         debug_symtab, dump_symtab_node, debug_symtab_node, dump_symtab_base):
18281         Declare.
18282         (cgraph_node_name, varpool_node_name): Remove.
18283         (cgraph_node_asm_name, varpool_node_asm_name,
18284         cgraph_node_name, varpool_node_name): New.
18285         * tree-pass.h (TODO_dump_cgraph): Rename to ...
18286         (TODO_dump_symtab): ... this one.
18287         * ipa-cp (pass_ipa_cp): Update.
18288         * ia-reference.c (generate_summary, read_write_all_from_decl,
18289         propagate, ipa_reference_read_optimization_summary): Update.
18290         * cgraphunit.c (cgraph_analyze_functions): Update.
18291         (cgraph_optimize): Update.
18292         * ipa-ref.c (ipa_dump_references): Update.
18293         (ipa_dump_refering): Update.
18294         * ipa-inline.c (pass_ipa_inline): Update.
18295         * matrix-reorg.c (pass_ipa_matrix_reorg): Update.
18296         * ipa.c (pass_ipa_function_visibility,
18297         pass_ipa_whole_program_visibility): Update.
18298         * tree-sra.c (pass_early_ipa_sra): Update.
18299         * symtab.c: Include langhooks.h
18300         (symtab_node_asm_name): New.
18301         (symtab_node_name): New.
18302         (symtab_type_names): New static var.
18303         (dump_symtab_base): New.
18304         (dump_symtab_node, dump_symtab): New.
18305         (debug_symtab_node,  debug_symtab): New.
18306         * tree-ssa-structalias.c: Dump symbol table.
18307         * pases.c (execute_todo): Handle TODO_dump_symtab instead
18308         of TODO_dump_cgraph.
18309         * varpoo.c (varpool_node_name): Remove.
18310         (dump_varpool_node): Use dump_symtab_base; reformat.
18311
18312 2012-04-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>
18313
18314         * doc/invoke.texi (Language Independent Options): @item should be
18315         before @opindex.
18316
18317 2012-04-17  Richard Sandiford  <rdsandiford@googlemail.com>
18318
18319         PR bootstrap/53021
18320         * rtl.c (rtx_code_size): Handle ADDRESS.
18321
18322 2012-04-17  Tom de Vries  <tom@codesourcery.com>
18323
18324         * tree-iterator.c (append_to_statement_list_1): Handle case that *list_p
18325         is not a STMT_LIST.
18326
18327 2012-04-17  Uros Bizjak  <ubizjak@gmail.com>
18328
18329         PR target/53020
18330         * config/i386/sync.md (atomic_<code><mode>): Rename to
18331         atomic_<logic><mode>.
18332
18333 2012-04-17  Richard Sandiford  <rdsandiford@googlemail.com>
18334
18335         * rtl.def (ADDRESS): Turn operand into a HOST_WIDE_INT.
18336         * alias.c (reg_base_value): Expand and update comment.
18337         (arg_base_value): New variable.
18338         (unique_id): Move up file.
18339         (unique_base_value, unique_base_value_p, known_base_value_p): New.
18340         (find_base_value): Use arg_base_value and known_base_value_p.
18341         (record_set): Document REG_NOALIAS handling.  Use unique_base_value.
18342         (find_base_term): Use known_base_value_p.
18343         (base_alias_check): Use unique_base_value_p.
18344         (init_alias_target): Initialize arg_base_value.  Use unique_base_value.
18345         (init_alias_analysis): Use 1 as the first id for REG_NOALIAS bases.
18346
18347 2012-04-17  Pat Haugen <pthaugen@us.ibm.com>
18348
18349         * config/rs6000/rs6000.h (SLOW_UNALIGNED_ACCESS): Remove DImode.
18350
18351 2012-04-17  Michael Matz  <matz@suse.de>
18352
18353         PR tree-optimization/18437
18354         * tree-vectorizer.h (_stmt_vec_info.stride_load_p): New member.
18355         (STMT_VINFO_STRIDE_LOAD_P): New accessor.
18356         (vect_check_strided_load): Declare.
18357         * tree-vect-data-refs.c (vect_check_strided_load): New function.
18358         (vect_analyze_data_refs): Use it to accept strided loads.
18359         * tree-vect-stmts.c (vectorizable_load): Ditto and handle them.
18360
18361 2012-04-17  Richard Guenther  <rguenther@suse.de>
18362
18363         PR middle-end/53011
18364         * tree-eh.c (cleanup_empty_eh_merge_phis): Properly discard
18365         loops when redirecting an entry or latch edge.
18366
18367 2012-04-17  Bernd Schmidt  <bernds@codesourcery.com>
18368
18369         * sel-sched.c (sel_global_init): Revert previous change.
18370
18371 2012-04-17  Richard Guenther  <rguenther@suse.de>
18372
18373         * tree-flow.h (array_at_struct_end_p): Move declaration ...
18374         * tree.h (array_at_struct_end_p): ... here.
18375         * tree-ssa-loop-niter.c (array_at_struct_end_p): Move ...
18376         * expr.c (array_at_struct_end_p): ... here.  Rewrite.
18377
18378 2012-04-17  Steven Bosscher  <steven@gcc.gnu.org>
18379
18380         * stmt.c (cost_table_, use_cost_table, cost_table_initialize,
18381         COST_TABLE): Remove.
18382         (estimate_case_costs): Remove.
18383         (expand_case): Do not call estimate_case_costs
18384         to set use_cost_table.
18385         (balance_case_nodes): Do not use use_cost_table.
18386
18387 2012-04-16  Jan Hubicka  <jh@suse.cz>
18388
18389         * cgraph.c (cgraph_hash, assembler_name_hash): Remove.
18390         (hash_node, eq_node): Remove.
18391         (cgraph_create_node): Do not handle hashtable.
18392         (cgraph_get_node): Remove.
18393         (cgraph_insert_node_to_hashtable): Remove.
18394         (hash_node_by_assembler_name): Remove.
18395         (eq_assembler_name): Remove.
18396         (cgraph_node_for_asm): Rewrite.
18397         (cgraph_find_replacement_node): Break out from ...
18398         (cgraph_remove_node): ... here; do not maintain hashtables.
18399         (change_decl_assembler_name): Remove.
18400         (cgraph_clone_node): Do not maintain hashtables.
18401         * cgraph.h (const_symtab_node): New typedef.
18402         (cgraph_insert_node_to_hashtable): Remove.
18403         (symtab_get_node, symtab_node_for_asm,
18404         symtab_insert_node_to_hashtable): Declare.
18405         (cgraph_find_replacement_node): Declare.
18406         (cgraph_get_node, varpool_get_node): Turn into inlines.
18407         (cgraph, varpool): Work sanely on NULL pointers.
18408         (FOR_EACH_SYMBOL): New walker.
18409         * ipa-inline-transform.c (save_inline_function_body): Use
18410         symtab_insert_node_to_hashtable.
18411         * symtab.c: Include ggc.h and diagnostics.h
18412         (symtab_hash, assembler_name_hash): New static vars;
18413         (hash_node, eq_node, hash_node_by_assembler_name,
18414         eq_assembler_name, insert_to_assembler_name_hash,
18415         unlink_from_assembler_name_hash): New.
18416         (symtab_register_node): Update hashtables.
18417         (symtab_insert_node_to_hashtable): New.
18418         (symtab_unregister_node): Update hashtables.
18419         (symtab_get_node): New.
18420         (symtab_node_for_asm): New.
18421         (change_decl_assembler_name): New.
18422         * Makefile.in (symtab.o): Needs GTY.
18423         * varpool.c (varpool_hash): Remove.
18424         (hash_varpool_node, eq_varpool_node, varpool_get_node): Remove.
18425         (varpool_node): Rewrite using varpool_get_node.
18426         (varpool_remove_node): DO not maintain hashtables.
18427         (varpool_node_for_asm): Rewrite.
18428
18429 2012-04-16  Sandra Loosemore  <sandra@codesourcery.com>
18430
18431         * doc/invoke.texi:  Copy-edit to put verbs in the present tense
18432         when describing the current behavior of GCC.
18433
18434 2012-04-16  Richard Sandiford  <rdsandiford@googlemail.com>
18435
18436         * genemit.c (gen_exp): Remove ADDRESS handling.
18437         * genoutput.c (scan_operands): Likewise.
18438         * genpeep.c (match_rtx): Likewise.
18439         * genrecog.c (add_to_sequence): Likewise.
18440
18441 2012-04-16  David Edelsohn  <dje.gcc@gmail.com>
18442
18443         * doc/install.texi (Specific, *-ibm-aix*): Update assembler bug status.
18444
18445 2012-04-16  Martin Jambor  <mjambor@suse.cz>
18446
18447         * tree-sra.c (build_ref_for_model): Create COMPONENT_REFs only for
18448         bit-fields.
18449
18450 2012-04-16  Ulrich Weigand  <ulrich.weigand@linaro.org>
18451
18452         PR target/51819
18453         * config/arm/arm.c (arm_print_operand): Fix invalid alignment
18454         hints for 'A' operand types.
18455
18456 2012-04-16  Jan Hubicka  <jh@suse.cz>
18457
18458         * cgraph.h (symtab_node_base): Add next and previous pointers.
18459         (cgraph_node): Remove next and preivous pointers.
18460         (varpool_node): Likewise; remove next/previous GTY marker;
18461         it is not type safe.
18462         (symtab_node_def): Update GTY marker
18463         (x_cgraph_nodes, cgraph_nodes): Remove.
18464         (symtab_nodes): New function.
18465         (cgraph_order): Rename to ...
18466         (symtab_order): ... this one.
18467         (symtab_register_node, symtab_unregister_node, symtab_remove_node):
18468         Declare.
18469         (x_varpool_nodes, varpool_nodes): Remove.
18470         (FOR_EACH_STATIC_VARIABLE): Update.
18471         (symtab_function_p, symtab_variable_p): New function.
18472         (FOR_EACH_VARIABLE): Update.
18473         (varpool_first_variable, varpool_next_variable): New functions.
18474         (FOR_EACH_VARIABLE): Update.
18475         (cgraph_first_defined_function): Update.
18476         (cgraph_next_defined_function, cgraph_next_defined_function): Update.
18477         (FOR_EACH_DEFINED_FUNCTION, FOR_EACH_FUNCTION): Update.
18478         (cgraph_first_function, cgraph_next_function): New.
18479         (FOR_EACH_FUNCTION): Update.
18480         (cgraph_first_function_with_gimple_body,
18481         cgraph_next_function_with_gimple_body): Update.
18482         * symtab.c: New file.
18483         * cgraph.c: Update copyright dates.
18484         (x_cgraph_nodes, cgraph_order): Remove.
18485         (NEXT_FREE_NODE): Update.
18486         (SET_NEXT_FREE_NODE): New.
18487         (cgraph_create_node_1): Remove common code.
18488         (cgraph_create_node): Remove common code; call symtab_register_node.
18489         (cgraph_remove_node): Remove common code; call symtab_unregister-node.
18490         (cgraph_add_asm_node): Update.
18491         (cgraph_clone_node): Register new node.
18492         * cgraphunit.c (process_function_and_variable_attributes): Update.
18493         (cgraph_analyze_functions): Update.
18494         (cgraph_analyze_functions): Update.
18495         (cgraph_output_in_order): Update.
18496         * lto-cgraph.c (input_node, input_varpool_node, input_cgraph_1):
18497         Update.
18498         * ipa-inline.c (recursive_inlining): Update.
18499         * lto-streamer-in.c (lto_input_toplevel_asms): Update.
18500         * ipa.c (cgraph_remove_unreachable_nodes): Update.
18501         * Makefile.in: Add symtab.o
18502         * varpool.c (x_varpool_nodes): Remove
18503         (varpool_node): Remove common code; call symtab_register_node.
18504         (varpool_remove_node): Remove common code; call symtab_unregister_node.
18505
18506 2012-04-16  Richard Guenther  <rguenther@suse.de>
18507
18508         PR middle-end/52977
18509         * tree.h (VECTOR_CST_NELTS): Adjust.
18510         (struct tree_vector): Add explicit length field.
18511         (make_vector_stat): Declare.
18512         (make_vector): Define.
18513         * tree.c (make_vector_stat): New function.
18514         (build_vector_stat): Use it.
18515         * tree-streamer-in.c (streamer_alloc_tree): Likewise.
18516
18517 2012-04-16  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
18518
18519         PR tree-optimization/52976
18520         * tree-ssa-reassoc.c (add_to_ops_vec_max_rank): New function.
18521         (undistribute_ops_list): Ops with repeat counts aren't eligible for
18522         undistribution.
18523         (attempt_builtin_powi): Call add_to_ops_vec_max_rank.
18524
18525 2012-04-16  Jan Hubicka  <jh@suse.cz>
18526
18527         * cgraph.h (FOR_EACH_VARIABLE, FOR_EACH_VARIABLE, FOR_EACH_FUNCTION):
18528         New macros.
18529         * lto-symtab.c (lto_symtab_merge_cgraph_nodes): Use FOR_EACH
18530         walkers to walk cgraph and varpool.
18531         * cgraph.c (cgraph_node_for_asm): Likewise.
18532         (dump_cgraph): Likewise.
18533         * value-prof.c (init_node_map): Likewise.
18534         * tree.c (free_lang_data_in_cgraph): Likewise.
18535         * tree-emutls.c: (ipa_lower_emutls): Likewise.
18536         * ipa-reference.c (generate_summary, propagate): Likewise.
18537         * cgraphunit.c (verify_cgraph, cgraph_process_same_body_aliases,
18538         cgraph_mark_functions_to_output, cgraph_output_in_order,
18539         output_weakrefs, cgraph_materialize_all_clones,
18540         cgraph_optimize): Likewise.
18541         * lto-cgraph.c (merge_profile_summaries): Likewise.
18542         (input_cgraph): Likewise.
18543         * ipa-pure-const.c (generate_summary): Likewise.
18544         (propagate): Likwise.
18545         * ipa-utils.c (ipa_reduced_postorder): Likewise.
18546         (ipa_free_postorder_info): Likewise.
18547         (ipa_reverse_postorder): Likewise.
18548         * ipa-inline.c (ipa_inline): Likewise.
18549         * matrix-reorg.c (find_matrices_decl): Likewise.
18550         (matrix_reorg): Likewise.
18551         * tree-vectorizer.c (increase_alignment): Likewise.
18552         * ipa.c (cgraph_remove_unreachable_nodes): Likewise.
18553         (function_and_variable_visibility): Likewise.
18554         (whole_program_function_and_variable_visibility): Likewise.
18555         (ipa_cdtor_merge): Likewise.
18556         * trans-mem.c (ipa_tm_execute): Likewise.
18557         * ipa-inline-analysis.c (dump_inline_summaries): Likewise.
18558         * ipa-prop.c (ipa_print_all_jump_functions): Likewise.
18559         (ipa_print_all_params): Likewise.
18560         (ipa_update_after_lto_read): Likewise.
18561         * tree-profie.c (tree_profiling): Likewise.
18562         * tree-ssa-structalias.c (ipa_pta_execute): Likewise.
18563         * passes.c (dump_passes): Likewise.
18564         (do_per_function): Likewise.
18565         (ipa_write_summaries): Likewise.
18566         * varpool.c (dump_varpool): Likewise.
18567         (varpool_node_for_asm): Likewise.
18568         (varpool_assemble_pending_decls): Likewise.
18569
18570 2012-04-16  Richard Guenther  <rguenther@suse.de>
18571
18572         PR tree-optimization/52975
18573         * tree-if-conv.c (predicate_bbs): Do not simplify inverted
18574         condition but always mark it with TRUTH_NOT_EXPR.
18575
18576 2012-04-16  Richard Guenther  <rguenther@suse.de>
18577
18578         PR tree-optimization/52975
18579         * tree-ssa-forwprop.c (combine_cond_exprs): New function.
18580         (ssa_forward_propagate_and_combine): Call it for COND_EXPRs
18581         and VEC_COND_EXPRs.  Also combine into VEC_COND_EXPRs condition.
18582         * fold-const.c (operand_equal_p): Handle TARGET_MEM_REF.
18583
18584 2012-04-14  Uros Bizjak  <ubizjak@gmail.com>
18585
18586         * config/i386/sse.md (ssse3_plusminus): New code iterator.
18587         (avx2_ph<plusminus_mnemonic>wv16hi3): Macroize insn from
18588         avx2_ph{add,adds,sub,subs}wv16hi3 using ssse3_plusminus code iterator.
18589         (ssse3_ph<plusminus_mnemonic>wv8hi3): Macroize insn from
18590         ssse3_ph{add,adds,sub,subs}wv8hi3 using ssse3_plusminus code iterator.
18591         (ssse3_ph<plusminus_mnemonic>wv4hi3): Macroize insn from
18592         ssse3_ph{add,adds,sub,subs}wv4hi3 using ssse3_plusminus code iterator.
18593
18594         (avx2_ph<plusminus_mnemonic>dv8si3): Macroize insn from
18595         avx2_ph{add,adds,sub,subs}dv8si3 using plusminus code iterator.
18596         (ssse3_ph<plusminus_mnemonic>dv4si3): Macroize insn from
18597         ssse3_ph{add,adds,sub,subs}dv4si3 using plusminus code iterator.
18598         (ssse3_ph<plusminus_mnemonic>dv2si3): Macroize insn from
18599         ssse3_ph{add,adds,sub,subs}dv2si3 using plusminus code iterator.
18600
18601         (xop_plus): New code iterator.
18602         (macs): New code attribute.
18603         (macds): Ditto.
18604         (xop_p<macs><ssemodesuffix><ssemodesuffix>): Macroize insn from
18605         xop_pmacs{,s}{ww,dd} using xop_plus code iterator and VI24_128 mode
18606         iterator.
18607         (xop_p<macs>dql): Macroize insn from xop_pmacs{,s}dql using
18608         xop_plus code iterator.
18609         (xop_p<macs>dqh): Macroize insn from xop_pmacs{,s}dqh using
18610         xop_plus code iterator.
18611         (xop_p<macs>wd): Macroize insn from xop_pmacs{,s}wd using
18612         xop_plus code iterator.
18613         (xop_p<madcs>wd): Macroize insn from xop_pmadcs{,s}wd using
18614         xop_plus code iterator.
18615
18616         (xop_phadd<u>bw): Macroize insn from xop_phadd{,u}bw usign
18617         any_extend code iterator.
18618         (xop_phadd<u>bd): Macroize insn from xop_phadd{,u}bd usign
18619         any_extend code iterator.
18620         (xop_phadd<u>bq): Macroize insn from xop_phadd{,u}bq usign
18621         any_extend code iterator.
18622         (xop_phadd<u>wd): Macroize insn from xop_phadd{,u}wd usign
18623         any_extend code iterator.
18624         (xop_phadd<u>wq): Macroize insn from xop_phadd{,u}wq usign
18625         any_extend code iterator.
18626         (xop_phadd<u>dq): Macroize insn from xop_phadd{,u}dq usign
18627         any_extend code iterator.
18628
18629 2012-04-14  Tom de Vries  <tom@codesourcery.com>
18630
18631         * cfgcleanup.c (try_optimize_cfg): Replace call to delete_insn_chain by
18632         call to delete_insn.  Remove code to reorder BASIC_BLOCK note and
18633         DELETED_LABEL note, and move it to ...
18634         * cfgrtl.c (delete_insn): ... here.  Change return type to void.
18635         (delete_insn_and_edges): Likewise.
18636         (delete_insn_chain): Handle new return type of delete_insn.  Delete
18637         chain backwards rather than forwards.
18638         * rtl.h (delete_insn, delete_insn_and_edges): Change return type to
18639         void.
18640         * cfglayout.c (fixup_reorder_chain): Delete unused label.
18641
18642 2012-04-14  Jan Hubicka  <jh@suse.cz>
18643
18644         * cgraph.h: Update copyrights;
18645         (symtab_node): Turn to union typedef.
18646         (symtab_node_base): New structure.
18647         (symtab_type): Add SYMTAB_SYMBOL tag.
18648         (cgraph_node): Annotate some pinters with nested_ptr.
18649         (varpool_node): Likewise.
18650         (cgraph_local_info): Remove lto_file_data
18651         and externally_visible.
18652         (cgraph_node): Remove decl; same_comdat_group list;
18653         aux; ref_list; order; address_taken; reachable_from_other_parittion,
18654         in_other_partition; resolution.
18655         (varpool_node): Remove decl; same_comdat_group;
18656         ref_list; lto_file_data; aux; order; resolution; externally_visible;
18657         used_from_other_partition; in_other_partition.
18658         (symtab_node_def): New union.
18659         (cgraph, varpool): Update.
18660         (varpool_first_static_initializer, varpool_next_static_initializer,
18661         cgraph_only_called_directly_or_aliased_p,
18662         varpool_can_remove_if_no_refs, varpool_can_remove_if_no_refs,
18663         varpool_all_refs_explicit_p, cgraph_alias_aliased_node,
18664         varpool_alias_aliased_node, cgraph_edge_recursive_p): Update
18665         field references.
18666         * cgraph.c: Likewise.
18667         (cgraph_hash, assembler_name_hash): Turn into symtab_node.
18668         * cgraphbuild.c: Likewise.
18669         * lto-symtab.c: Likewise.
18670         * c-gimplify.c: Likewise.
18671         * value-prof.c: Likewise.
18672         * tree.c: Likewise.
18673         * ipa-cp.c: Likewise.
18674         * tree-emutls.c: Likewise.
18675         * ipa-inline-transform.c: Likwise.
18676         * ipa-reference.c: Likewise.
18677         * cgraphunit.c: Likewise.
18678         * ipa-ref.c: Likewise.
18679         * lto-cgraph.c: Likewise.
18680         * ipa-ref-inline.h: Likewise.
18681         * ipa-pure-const.c: Likewise.
18682         * lto-streamer-out.c: Likewise.
18683         * ipa-utils.c: Likewise.
18684         * ipa-inline.c: Likewise.
18685         * matrix-reorg.c: Likewise.
18686         * tree-eh.c: Likewise.
18687         * tree-vectorizer.c: Likewise.
18688         * ipa-split.c: Likewise.
18689         * ipa.c: Likewise.
18690         * trans-mem.c: Likewise.
18691         * ipa-inline-analysis.c: Likewise.
18692         * gimplify.c: Likewise.
18693         * cfgexpand.c: Likewise.
18694         * tree-sra.c: Likewise.
18695         * ipa-prop.c: Likewise.
18696         * varasm.c: Likewise.
18697         * tree-nested.c: Likewise.
18698         * tree-inline.c: Likewise.
18699         * tree-profile.c: Likewise.
18700         * tree-ssa-structalias.c: Likewise.
18701         * passes.c: Likewise.
18702         * varpool.c: Likewise.
18703
18704 2012-04-14  Tom de Vries  <tom@codesourcery.com>
18705
18706         * tree-ssa-tail-merge.c (stmt_local_def): New function, factored out of
18707         same_succ_hash, with local_def inlined.  Use SINGLE_SSA_DEF_OPERAND.
18708         Use FOR_EACH_IMM_USE_FAST instead of FOR_EACH_IMM_USE_STMT.  Remove use
18709         of find_edge.
18710         (gsi_advance_fw_nondebug_nonlocal): New function.
18711         (local_def): Removed function.
18712         (same_succ_hash): Use stmt_local_def.
18713         (same_succ_equal): Use gsi_advance_fw_nondebug_nonlocal.
18714         (gsi_advance_bw_nondebug_nonlocal): Use stmt_local_def.
18715
18716 2012-04-13  H.J. Lu  <hongjiu.lu@intel.com>
18717
18718         * config/i386/i386-c.c (ix86_target_macros): Define _ILP32
18719         and __ILP32__ for x32.
18720
18721 2012-04-13  Martin Jambor  <mjambor@suse.cz>
18722
18723         PR middle-end/52939
18724         * gimple-fold.c (gimple_get_virt_method_for_binfo): Bail out if
18725         fold_ctor_reference returns a zero constant.
18726
18727 2012-04-13  Enkovich Ilya  <ilya.enkovich@intel.com>
18728
18729         * config.gcc: Add i386/gnu-user-common.h before all
18730         i386/gnu-user.h and i386/gnu-user64.h usages.
18731
18732         * config/i386/gnu-user-common.h: New.
18733
18734         * config/i386/gnu-user.h (CPP_SPEC): Moved to gnu-user-common.h.
18735         (CC1_SPEC): Likewise.
18736         (ENDFILE_SPEC): Likewise.
18737         (DEFAULT_PCC_STRUCT_RETURN): Likewise.
18738         (TARGET_TLS_DIRECT_SEG_REFS_DEFAULT): Likewise.
18739         (TARGET_OS_CPP_BUILTINS): Likewise.
18740         (LIBGCC2_HAS_TF_MODE): Likewise.
18741         (LIBGCC2_TF_CEXT): Likewise.
18742         (TF_SIZE): Likewise.
18743         (TARGET_ASM_FILE_END): Likewise.
18744         (STACK_CHECK_MOVING_SP): Likewise.
18745         (STACK_CHECK_STATIC_BUILTIN): Likewise.
18746         * config/i386/gnu-user64.h: Likewise.
18747
18748 2012-04-13  Martin Jambor  <mjambor@suse.cz>
18749
18750         * expr.c (expand_expr_real_1): Pass type, not the expression, to
18751         set_mem_attributes for a memory temporary. Do not call the function
18752         for the memory temporary created for a bitfield.
18753
18754 2012-04-13  Alexandre Oliva  <aoliva@redhat.com>
18755
18756         PR debug/48866
18757         * df.h (enum debug_temp_where): New.
18758         (dead_debug_init, dead_debug_finish) Declare.
18759         (dead_debug_add, dead_debug_insert_temp): Declare.
18760         (struct dead_debug_use, struct dead_debug): Moved from...
18761         * df-problems.c: ... here.
18762         (df_set_unused_notes_for_mw): Bind debug uses of unused regno
18763         to a debug temp.
18764         (df_create_unused_note): Likewise.
18765         (df_set_dead_notes_for_mw): Move comment where it belongs.
18766         (dead_debug_init): Export.
18767         (dead_debug_reset_uses): New, factored out of...
18768         (dead_debug_finish): ...this.  Export.
18769         (dead_debug_reset): Remove.
18770         (dead_debug_add): Export.
18771         (dead_debug_insert_before): Rename to...
18772         (dead_debug_insert_temp): ... this.  Add where argument.  Export.
18773         Locate stored value for BEFORE_WITH_VALUE.  Avoid repeat inserts.
18774         Return insertion count.
18775         (df_note_bb_compute): Adjust.
18776         * dce.c (word_dce_process_block): Adjust dead debug uses.
18777         (dce_process_block): Likewise.
18778
18779 2012-04-13  Alexandre Oliva  <aoliva@redhat.com>
18780
18781         * df-problems.c (df_note_bb_compute): Do not take note of
18782         debug uses for whose REGs we won't emit DEAD or UNUSED notes.
18783
18784 2012-04-13  Alexandre Oliva  <aoliva@redhat.com>
18785
18786         PR debug/51570
18787         * var-tracking.c (expand_depth): New type.
18788         (onepart_aux, expand_loc_callback_data): Change depth type to it.
18789         (loc_exp_dep_alloc): Adjust initializer.
18790         (update_depth): Use new type.  Add entryvals.
18791         (vt_expand_var_loc_chain): Take note of expansions with
18792         ENTRY_VALUEs, but don't accept them right away.  Run an optional
18793         second pass accepting the minimum ENTRY_VALUE count found in the
18794         first pass.
18795         (vt_expand_loc_callback, INIT_ELCD): Adjust.
18796
18797 2012-04-13  Tom de Vries  <tom@codesourcery.com>
18798
18799         * tree-ssa-tail-merge.c (gsi_advance_bw_nondebug_nonlocal): Add
18800         parameters vuse and vuse_escaped.
18801         (find_duplicate): Init vuse1, vuse2 and vuse_escaped.  Pass to
18802         gsi_advance_bw_nondebug_nonlocal.  Return if vuse_escaped and
18803         vuse1 != vuse2.
18804
18805 2012-04-13  Richard Guenther  <rguenther@suse.de>
18806
18807         PR tree-optimization/52969
18808         * tree-if-conv.c (predicate_mem_writes): Properly gimplify
18809         the condition for the COND_EXPR and handle predicate negation
18810         by swapping the COND_EXPR arms.
18811
18812 2012-04-13  Nick Clifton  <nickc@redhat.com>
18813
18814         * config/rl78/rl78.c (rl78_devirt_pass): Remove use of
18815         TODO_dump_func flag.
18816
18817 2012-04-13  Andrey Belevantsev  <abel@ispras.ru>
18818
18819         PR rtl-optimization/52203
18820         PR rtl-optimization/52715
18821
18822         Revert the 2012-03-07 fix for PR 52203.
18823         * sel-sched.c (reset_sched_cycles_in_current_ebb): Check that
18824         the insn does not modify DFA right before issuing, adjust
18825         issue_rate accordingly.
18826
18827 2012-04-13  Richard Guenther  <rguenther@suse.de>
18828
18829         PR c/52549
18830         * c-typeck.c (pointer_diff): Remove bogus assert.
18831
18832 2012-04-13  Richard Guenther  <rguenther@suse.de>
18833
18834         PR c/52862
18835         * convert.c (convert_to_pointer): Remove special-casing of zero.
18836
18837 2012-04-13  Joey Ye  <joey.ye@arm.com>
18838
18839         * config/arm/constraints.md (Pe): New constraint.
18840         * config/arm/arm.md: New split for imm 256-510.
18841
18842 2012-04-13  Terry Guo  <terry.guo@arm.com>
18843
18844         * config/arm/arm-cores.def: Added core cortex-m0plus.
18845         * config/arm/arm-tune.md: Regenerated.
18846         * config/arm/arm-tables.opt: Regenerated.
18847         * doc/invoke.texi: Added entry for cpu ARM cortex-m0plus.
18848
18849 2012-04-13  Alan Modra  <amodra@gmail.com>
18850
18851         PR target/52828
18852         * config/rs6000/rs6000.c (rs6000_emit_stack_tie): Rewrite with
18853         tie regs on destination of sets.  Delete forward declaration.
18854         (rs6000_emit_stack_reset): Update rs6000_emit_stack_tie calls.
18855         (rs6000_emit_prologue): Likewise.
18856         (rs6000_emit_epilogue): Likewise.  Use in place of gen_frame_tie
18857         and gen_stack_tie.
18858         (is_mem_ref): Use tie_operand to recognise stack ties.
18859         * config/rs6000/predicates.md (tie_operand): New.
18860         * config/rs6000/rs6000.md (restore_stack_block): Generate new
18861         stack tie rtl.
18862         (restore_stack_nonlocal): Likewise.
18863         (stack_tie): Update.
18864         (frame_tie): Delete.
18865
18866 2012-04-12  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
18867
18868         * tree-ssa-reassoc.c (attempt_builtin_powi_stats): Change %ld to
18869         HOST_WIDE_INT_PRINT_DEC in format strings.
18870
18871 2012-04-12  Uros Bizjak  <ubizjak@gmail.com>
18872
18873         PR target/52932
18874         * config/i386/avx2intrin.h (_mm256_permutevar8x32_ps): Change second
18875         argument type to __m256i.  Update call to __builtin_ia32_permvarsf256.
18876         * config/i386/sse.md (UNSPEC_VPERMVAR): New.
18877         (UNSPEC_VPERMSI, UNSPEC_VPERMSF): Remove.
18878         (avx2_permvarv8sf, avx2_permvarv8si): Switch operands 1 and 2.
18879         (avx2_permvar<mode>): Macroize insn from avx2_permvarv8sf and
18880         avx2_permvarv8si using VI4F_256 mode iterator.
18881         * config/i386/i386.c (bdesc_args) <__builtin_ia32_permvarsf256>:
18882         Update builtin type to V8SF_FTYPE_V8SF_V8SI.
18883         (ix86_expand_vec_perm): Update calls to gen_avx2_permvarv8si and
18884         gen_avx2_permvarv8sf.
18885         (expand_vec_perm_pshufb): Ditto.
18886
18887 2012-04-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
18888
18889         PR target/52775
18890         * config/rs6000/rs6000.h (TARGET_FCFID): Add TARGET_PPC_GPOPT to
18891         the list of options to enable the FCFID instruction.
18892         (TARGET_EXTRA_BUILTINS): Adjust comment.
18893
18894 2012-04-12  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
18895
18896         PR tree-optimization/18589
18897         * tree-ssa-reassoc.c (reassociate_stats): Add two fields.
18898         (operand_entry): Add count field.
18899         (add_repeat_to_ops_vec): New function.
18900         (completely_remove_stmt): Likewise.
18901         (remove_def_if_absorbed_call): Likewise.
18902         (remove_visited_stmt_chain): Remove feeding builtin pow/powi calls.
18903         (acceptable_pow_call): New function.
18904         (linearize_expr_tree): Look for builtin pow/powi calls and add operand
18905         entries with repeat counts when found.
18906         (repeat_factor_d): New struct and associated typedefs.
18907         (repeat_factor_vec): New static vector variable.
18908         (compare_repeat_factors): New function.
18909         (get_reassoc_pow_ssa_name): Likewise.
18910         (attempt_builtin_powi): Likewise.
18911         (reassociate_bb): Call attempt_builtin_powi.
18912         (fini_reassoc): Two new calls to statistics_counter_event.
18913
18914 2012-04-12  Richard Guenther  <rguenther@suse.de>
18915
18916         * Makefile.in (cgraphunit.o): Add $(EXCEPT_H) dependency.
18917         * cgraph.h (tree_rest_of_compilation): Remove.
18918         * cgraph.c (cgraph_add_new_function): Move ...
18919         * cgraphunit.c (cgraph_add_new_function): ... here.
18920         (tree_rest_of_compilation): Make static.
18921         (cgraph_expand_function): Do not set cgraph_function_flags_ready.
18922         * tree-optimize.c (gate_all_optimizations, pass_all_optimizations,
18923         gate_all_early_local_passes, execute_all_early_local_passes,
18924         pass_early_local_passes, gate_all_early_optimizations,
18925         pass_all_early_optimizations): Move ...
18926         * passes.c (gate_all_optimizations, pass_all_optimizations,
18927         gate_all_early_local_passes, execute_all_early_local_passes,
18928         pass_early_local_passes, gate_all_early_optimizations,
18929         pass_all_early_optimizations): ... here.
18930         * tree-optimize.c (execute_free_datastructures): Remove.
18931         * tree-flow.h (execute_free_datastructures): Remove.
18932         * tree-optimize.c (execute_init_datastructures,
18933         pass_init_datastructures): Move ...
18934         * tree-ssa.c (execute_init_datastructures,
18935         pass_init_datastructures): ... here.
18936         * cfgexpand.c (gimple_expand_cfg): Inline-expand call to
18937         execute_free_datastructures.
18938
18939 2012-04-12  Bernd Schmidt  <bernds@codesourcery.com>
18940
18941         * dbgcnt.def (ira_move): New counter.
18942         * ira-int.h (ira_create_new_reg): Declare function.
18943         (first_moveable_pseudo, last_moveable_pseudo): Declare variables.
18944         * ira-emit.c (ira_create_new_reg): Renamed from craete_new_reg and
18945         no longer static.  All callers changed.
18946         * ira.c: Include "dbgcnt.h".
18947         (rtx_moveable_p, insn_dominated_by_p, find_moveable_pseudos,
18948         move_unallocated_pseudos): New static functions.
18949         (first_moveable_pseudo, last_moveable_pseudo): New global variables.
18950         (pseudo_replaced_reg, pseudo_move_insn): New static variables.
18951         (ira): Call find_moveable_pseudos and move_unallocated_pseudos.
18952         * ira-costs.c (find_costs_and_classes): Assign a memory cost of zero
18953         to the pseudos generated in find_moveable_pseudos.
18954         * Makefile.in (ira.o): Add $(DBGCNT_H).
18955
18956 2012-04-12  Richard Guenther  <rguenther@suse.de>
18957
18958         PR tree-optimization/52943
18959         * tree-chrec.h (chrec_is_positive): Remove.
18960         * tree-scalar-evolution.c (chrec_is_positive): Move ...
18961         * tree-data-ref.c (chrec_is_positive): ... here.  Make static.
18962         Return false for a constant zero instead of negative.
18963         (analyze_siv_subscript_cst_affine): Handle zero difference
18964         in the initial condition explicitely.
18965
18966 2012-04-12  Richard Guenther  <rguenther@suse.de>
18967
18968         * tree-parloops.c (parallelize_loops): Also consult the upper
18969         bound for the number of iterations.
18970         * tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Likewise.
18971         (loop_prefetch_arrays): Likewise.
18972
18973 2012-04-12  Richard Guenther  <rguenther@suse.de>
18974
18975         * cfgloop.h (estimated_loop_iterations_int): Ditch
18976         'conservative' parameter.
18977         (max_stmt_executions_int): Likewise.
18978         (estimated_loop_iterations): Likewise.
18979         (max_stmt_executions): Likewise.
18980         (max_loop_iterations): Declare.
18981         (max_loop_iterations_int): Likewise.
18982         (estimated_stmt_executions): Likewise.
18983         (estimated_stmt_executions_int): Likewise.
18984         * tree-ssa-loop-niter.c (estimated_loop_iterations):
18985         Split parts to ...
18986         (max_loop_iterations): ... this.
18987         (estimated_loop_iterations_int): Split parts to ...
18988         (max_loop_iterations_int): ... this.
18989         (max_stmt_executions_int): Split parts to ...
18990         (estimated_stmt_executions_int): ... this.
18991         (max_stmt_executions): Split parts to ...
18992         (estimated_stmt_executions): ... this.
18993         * graphite-sese-to-poly.c (build_loop_iteration_domains): Adjust.
18994         * predict.c (predict_loops): Likewise.
18995         * tree-data-ref.c (max_stmt_executions_tree): Likewise.
18996         (analyze_siv_subscript_cst_affine): Likewise.
18997         (compute_overlap_steps_for_affine_1_2): Likewise.
18998         (analyze_subscript_affine_affine): Likewise.
18999         (init_omega_for_ddr_1): Likewise.
19000         * tree-parloops.c (parallelize_loops): Likewise.
19001         * tree-ssa-loop-ivopts.c (avg_loop_niter): Likewise.
19002         (may_eliminate_iv): Likewise.
19003         * tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Likewise.
19004         (loop_prefetch_arrays): Likewise.
19005         * tree-vrp.c (adjust_range_with_scev): Likewise.
19006
19007 2012-04-12  Oleg Endo  <olegendo@gcc.gnu.org>
19008
19009         * config/sh/sh.h (RETURN_ADDR_RTX): Use NULL_RTX instead of 0.
19010         * config/sh/sh.c (INSN_REGMODE_WEIGHT, CURR_REGMODE_PRESSURE):
19011         Fix line width.
19012         (dump_table): Use bool type for need_align and have_df variables.
19013         (find_barrier, sfunc_uses_reg): Use NULL_RTX instead of 0.
19014         (regs_used): Remove register modifier.
19015         (barrier_align): Move variables slot, credit, jump_to_next
19016         into if block above for loop.  Use bool type for jump_to_next.
19017         (sh_function_arg): Use NULL_RTX instead of 0.
19018
19019 2012-04-11  Andreas Schwab  <schwab@linux-m68k.org>
19020
19021         * config/m68k/m68k.md (rotrhi3+1): Name it rotrhi_lowpart.
19022         (bswapsi2): New expander.
19023
19024 2012-04-11  H.J. Lu  <hongjiu.lu@intel.com>
19025
19026         * config/host-linux.c (TRY_EMPTY_VM_SPACE): Defined to
19027         0x60000000 if __x86_64 is defined and __LP64__ isn't defined.
19028
19029 2012-04-11  H.J. Lu  <hongjiu.lu@intel.com>
19030
19031         PR rtl-optimization/52876
19032         * emit-rtl.c (set_reg_attrs_from_value): Handle arbitrary value.
19033         Don't call mark_reg_pointer for incompatible pointer sign extension.
19034
19035         * reginfo.c (reg_scan_mark_refs): Call set_reg_attrs_from_value
19036         directly.
19037
19038 2012-04-11  Bernd Schmidt  <bernds@codesourcery.com>
19039
19040         * fold-const.c (fold_unary_loc): Use GET_MODE_PRECISION for
19041         comparisons against TYPE_PRECISION.
19042         * tree-ssa-forwprop.c (combine_conversions): Likewise.
19043
19044 2012-04-11  Xinliang David Li  <davidxl@google.com>
19045
19046         * tree-passes.h: Remove TODO_dump_func.
19047         * tree-ssa-tail-merge.c (tail_merge_optimize): Remove TODO_dump_func.
19048         * trans-mem.c: Remove TODO_dump_func.
19049         * ira.c: Remove TODO_dump_func.
19050
19051 2012-04-11  H.J. Lu  <hongjiu.lu@intel.com>
19052
19053         * config/i386/i386.c (ix86_option_override_internal): Check
19054         SUBTARGET_OVERRIDE_OPTIONS and SUBSUBTARGET_OVERRIDE_OPTIONS
19055         after TARGET_64BIT is updated.
19056
19057 2012-04-11  Oleg Endo  <olegendo@gcc.gnu.org>
19058
19059         * config/sh/sh.h: Remove old secondary reload code.
19060
19061 2012-04-11  Oleg Endo  <olegendo@gcc.gnu.org>
19062
19063         * config/sh/sh.c (SCHED_REORDER): Merge macro into ...
19064         (ready_reorder): ... this function.
19065
19066 2012-04-11  Bernd Schmidt  <bernds@codesourcery.com>
19067
19068         * sel-sched.c (sel_global_init): Swap order of sched_rgn_init and
19069         sched_init calls.
19070
19071         * haifa-sched.c (prune_ready_list): Rework handling of SCHED_GROUP_P
19072         insns so that no other insn is queued for a time before them.
19073
19074         * config/c6x/c6x.md (load_got_gotoff): Set op_pattern attribute to
19075         unknown.
19076
19077 2012-04-11  Richard Guenther  <rguenther@suse.de>
19078
19079         PR middle-end/52621
19080         * tree-chrec.c (evolution_function_is_invariant_rec_p): Properly
19081         consider loop nesting.
19082         (evolution_function_is_univariate_p): Properly check the remainder
19083         for chrecs.
19084
19085 2012-04-11  Richard Guenther  <rguenther@suse.de>
19086
19087         PR middle-end/52918
19088         * except.c (sjlj_emit_dispatch_table): Properly update loop structure.
19089
19090 2012-04-11  Nick Clifton  <nickc@redhat.com>
19091
19092         * config/rl78/rl78.c (rl78_expand_prologue): Set stack use
19093         information, if requested.
19094
19095         * config/rx/rx.c (rx_expand_prologue): Likewise.
19096
19097 2012-04-11  Peter Bergner  <bergner@vnet.ibm.com>
19098             Michael Matz  <matz@suse.de>
19099
19100         PR target/16458
19101         * rtlanal.c (unsigned_reg_p): New function.
19102         Update copyright notice dates.
19103         * rtl.h (unsigned_reg_p): Prototype it.
19104         Update copyright notice dates.
19105         * config/rs6000/rs6000.c (rs6000_generate_compare): Use it.
19106         Update comment.
19107         * expr.c (expand_expr_real_1): Set register attributes.
19108         * stmt.c (expand_case): Likewise.
19109
19110 2012-04-11  Oleg Endo  <olegendo@gcc.gnu.org>
19111
19112         PR target/50751
19113         * config/sh/sh-protos.h (sh_legitimate_index_p): Add new arguments
19114         consider_sh2a and allow_zero.
19115         * config/sh/sh.c (sh_legitimate_index_p): Likewise.
19116         (disp_addr_displacement): New function.
19117         (sh_address_cost): Use disp_addr_displacement function instead
19118         of DISP_ADDR_OFFSET.
19119         (sh_legitimate_address_p): Adapt to changed
19120         sh_legitimate_index_p declaration.
19121         (sh_find_mov_disp_adjust): Remove HImode check.
19122         (sh_secondary_reload): Add HImode case.  Use satisfies_constraint_Sdd,
19123         disp_addr_displacement and max_mov_insn_displacement.
19124         (max_mov_insn_displacement): Remove HImode check.
19125         * config/sh/sh.h (CONST_OK_FOR_K04, CONST_OK_FOR_K12,
19126         DISP_ADDR_P, DISP_ADDR_OFFSET): Remove.
19127         * config/sh/constraints.md (K05, K13): New constraints.
19128         (K12): Correct comment.
19129         (Sdd): Do not use DISP_ADDR_P macro.
19130         (Snd, Sbw): Use satisfies_constraint_Sdd.
19131         * config/sh/sh.md (extendhisi2): Remove constraints from expander.
19132         (*extendhisi2_compact, movhi_i): Remove.
19133         (*extendhisi2_compact_reg, *extendhisi2_compact_mem_disp,
19134         *extendhisi2_compact_mem_disp, *extendhisi2_compact_snd,
19135         *movhi_reg_reg, *movhi_store_mem_disp05, *movhi_store_mem_disp13,
19136         *movhi_load_mem_disp, *movhi_load_mem_disp, *movhi): New insns.
19137         (*extendqisi2_compact_mem_disp, *extendqisi2_compact_mem_disp,
19138         *movqi_store_mem_disp04, *movqi_store_mem_disp12, *movqi_load_mem_disp,
19139         *movqi_load_mem_disp): Use sh_legitimate_index_p instead of
19140         CONST_OK_FOR_Kxx.
19141         Add new peepholes for HImode displacement addressing.
19142
19143 2012-04-11  Oleg Endo  <olegendo@gcc.gnu.org>
19144
19145         * config/sh/sh.h (SIDI_OFF): Remove.
19146         * config/sh/sh.md: Use gen_highpart and gen_lowpart to access
19147         DImode subregs instead of gen_rtx_REG or simplifly_gen_subreg
19148         or operand_subword.
19149
19150 2012-04-11  Eric Botcazou  <ebotcazou@adacore.com>
19151
19152         PR target/52624
19153         * doc/extend.texi (Other Builtins): Document __builtin_bswap16.
19154         (PowerPC AltiVec/VSX Built-in Functions): Remove it.
19155         * doc/md.texi (Standard Names): Add bswap.
19156         * builtin-types.def (BT_UINT16): New primitive type.
19157         (BT_FN_UINT16_UINT16): New function type.
19158         * builtins.def (BUILT_IN_BSWAP16): New.
19159         * builtins.c (expand_builtin_bswap): Add TARGET_MODE argument.
19160         (expand_builtin) <BUILT_IN_BSWAP16>: New case.  Pass TARGET_MODE to
19161         expand_builtin_bswap.
19162         (fold_builtin_bswap): Add BUILT_IN_BSWAP16 case.
19163         (fold_builtin_1): Likewise.
19164         (is_inexpensive_builtin): Likewise.
19165         * optabs.c (expand_unop): Deal with bswap in HImode specially.  Add
19166         missing bits for bswap to libcall code.
19167         * tree.c (build_common_tree_nodes): Build uint16_type_node.
19168         * tree.h (enum tree_index): Add TI_UINT16_TYPE.
19169         (uint16_type_node): New define.
19170         * config/rs6000/rs6000-builtin.def (RS6000_BUILTIN_BSWAP_HI): Delete.
19171         * config/rs6000/rs6000.c (rs6000_expand_builtin): Remove handling of
19172         above builtin.
19173         (rs6000_init_builtins): Likewise.
19174         * config/rs6000/rs6000.md (bswaphi2): Add TARGET_POWERPC predicate.
19175
19176 2012-04-11  Tristan Gingold  <gingold@adacore.com>
19177
19178         * doc/extend.texi (Type Attributes): Move paragraph.
19179
19180 2012-04-11  Manuel López-Ibáñez  <manu@gcc.gnu.org>
19181
19182         PR 24985
19183         * diagnostic.h (show_caret): Declare.
19184         (caret_max_width): Declare.
19185         (diagnostic_show_locus): Declare.
19186         * diagnostic.c (diagnostic_initialize): Initialize to false.
19187         (diagnostic_show_locus): New.
19188         (diagnostic_report_diagnostic): Call it.
19189         (getenv_columns): New.
19190         (adjust_line): New.
19191         (diagnostic_set_caret_max_width): New.
19192         * input.c (read_line): New.
19193         (location_get_source_line): New.
19194         * input.h (location_get_source_line): Declare.
19195         * toplev.c (general_init): Initialize show_caret from options.
19196         * dwarf2out.c (gen_producer_string): Handle fdiagnostics-show-caret.
19197         * opts.c (common_handle_option): Likewise.
19198         * pretty-print.h (pp_get_prefix): New.
19199         (pp_base_get_prefix): New.
19200         * common.opt (fdiagnostics-show-caret): New option.
19201         * doc/invoke.texi (fdiagnostics-show-caret): Document it.
19202
19203 2012-04-11  Richard Guenther  <rguenther@suse.de>
19204
19205         PR rtl-optimization/52881
19206         * ifcvt.c (find_if_case_2): Avoid speculating loop latches.
19207
19208 2012-04-11  Richard Guenther  <rguenther@suse.de>
19209
19210         PR tree-optimization/52912
19211         * tree-ssa-threadupdate.c (thread_block): Tell the cfg
19212         manipulation code we are threading through a loop header
19213         to an exit destination.
19214
19215 2012-04-10  Manuel López-Ibáñez  <manu@gcc.gnu.org>
19216
19217         * tree.h (warn_if_unused_value): Move declaration from here.
19218         * stmt.c (warn_if_unused_value): Move definition from here.
19219
19220 2012-04-10  Michael Matz  <matz@suse.de>
19221
19222         * tree-vectorizer.h (_loop_vec_info.strided_stores): Rename to
19223         grouped_stores.
19224         (LOOP_VINFO_STRIDED_STORES): Rename to LOOP_VINFO_GROUPED_STORES.
19225         (struce _bb_vec_info.strided_stores): Rename to grouped_stores.
19226         (BB_VINFO_STRIDED_STORES): Rename to BB_VINFO_GROUPED_STORES.
19227         (STMT_VINFO_STRIDED_ACCESS): Rename to STMT_VINFO_GROUPED_ACCESS.
19228         (vect_strided_store_supported): Rename to vect_grouped_store_supported.
19229         (vect_strided_load_supported): Rename to vect_grouped_load_supported.
19230         (vect_transform_strided_load): Rename to vect_transform_grouped_load.
19231         (vect_record_strided_load_vectors): Rename to
19232         vect_record_grouped_load_vectors.
19233         * tree-vect-data-refs.c (vect_update_misalignment_for_peel):
19234         Rename use of above macros.
19235         (vect_verify_datarefs_alignment): Ditto.
19236         (vector_alignment_reachable_p): Ditto.
19237         (vect_peeling_hash_get_lowest_cost): Ditto.
19238         (vect_enhance_data_refs_alignment): Ditto.
19239         (vect_analyze_group_access): Ditto and rename stride to groupsize.
19240         (vect_analyze_data_ref_access): Rename "strided" to "grouped".
19241         (vect_strided_store_supported): Rename to vect_grouped_store_supported.
19242         (vect_strided_load_supported): Rename to vect_grouped_load_supported.
19243         (vect_transform_strided_load): Rename to vect_transform_grouped_load.
19244         (vect_record_strided_load_vectors): Rename to
19245         vect_record_grouped_load_vectors.
19246         * tree-vect-loop.c (new_loop_vec_info): Rename use of above macros.
19247         (destroy_loop_vec_info): Ditto.
19248         (vect_transform_loop): Ditto and rename strided_store to grouped_store.
19249         * tree-vect-slp.c (vect_build_slp_tree): Rename use of above macros.
19250         (vect_analyze_slp): Ditto.
19251         (new_bb_vec_info): Ditto.
19252         (destroy_bb_vec_info): Ditto.
19253         (vect_schedule_slp_instance): Ditto and rename strided_store to
19254         grouped_store.
19255         * tree-vect-stmts.c (vect_cost_strided_group_size): Rename to
19256         vect_cost_group_size.
19257         (vect_model_store_cost): Rename use of above macros and call
19258         to vect_cost_strided_group_size.
19259         (vect_model_load_cost): Ditto.
19260         (vectorizable_store): Ditto, rename strided_store to grouped_store
19261         and calls to renamed tree-vectorizer.h functions.
19262         (vectorizable_load): Ditto.
19263         (vect_transform_stmt): Rename use of above macros and strided_store
19264         to grouped_store.
19265
19266 2012-04-10  Jan Hubicka  <jh@suse.cz>
19267
19268         * cgraph.h: Remove misledaing comment on ipa-ref.h.
19269         (symtab_type): New enum.
19270         (symtab_node): New structure.
19271         (cgraph_node, varpool_node): Add symbol base type.
19272         (cgraph, varpool): New accestor functions.
19273         * cgraph.c (cgraph_create_node_1): Set symbol type.
19274         * varpool.c (varpool_node): Set symbol type.
19275
19276 2012-04-10  Ulrich Weigand  <ulrich.weigand@linaro.org>
19277             Richard Sandiford  <rdsandiford@googlemail.com>
19278
19279         * fwprop.c (propagate_rtx): Also set PR_CAN_APPEAR for subregs.
19280
19281 2012-04-10  Richard Guenther  <rguenther@suse.de>
19282
19283         PR middle-end/52888
19284         * gimple-low.c (gimple_check_call_args): Properly account for
19285         compatible aggregate types.
19286
19287 2012-04-10  Richard Guenther  <rguenther@suse.de>
19288
19289         * toplev.h (tree_rest_of_compilation): Remove.
19290         * tree-optimize.c (tree_rest_of_compilation): Likewise.
19291         * cgraph.h (tree_rest_of_compilation): Declare.
19292         * tree-optimize.c (tree_rest_of_compilation): Move ...
19293         * cgraphunit.c (tree_rest_of_compilation): ... here.
19294         * cgraph.c (cgraph_add_new_function): Adjust.
19295         * Makefile.in (tree-optimize.o): Adjust.
19296         (cgraphunit.o): Likewise.
19297
19298 2012-04-10  Ulrich Weigand  <ulrich.weigand@linaro.org>
19299
19300         PR tree-optimization/52870
19301         * tree-vect-patterns.c (vect_recog_widen_mult_pattern): Verify that
19302         presumed pattern statement is within the same loop or basic block.
19303
19304 2012-04-10  Tristan Gingold  <gingold@adacore.com>
19305
19306         * gengtype.c (main): Make uintptr_t a known type.
19307
19308 2012-04-10  Richard Guenther  <rguenther@suse.de>
19309
19310         * tree-pass.h (tree_lowering_passes): Remove.
19311         * tree-optimize.c (tree_lowering_passes): Remove.
19312         * cgraph.c (cgraph_add_new_function): Inline relevant parts
19313         of tree_lowering_passes, avoid redundant call of early local passes.
19314         * cgraphunit.c (cgraph_lower_function): Fold into ...
19315         (cgraph_analyze_function): ... its single caller.  Inline
19316         relevant parts of tree_lowering_passes.
19317
19318 2012-04-09  H.J. Lu  <hongjiu.lu@intel.com>
19319
19320         PR other/52777
19321         * config/pa/pa.opt: Remove SIO and GNU_LD.
19322
19323 2012-04-09  Jan Hubicka  <jh@suse.cz>
19324
19325         PR lto/52722
19326         PR lto/51765
19327         PR lto/52634
19328         * lto-cgraph.c (compute_ltrans_boundary): When alias is in the
19329         boundary, add its target too.
19330         * lto.c (add_references_to_partition): Add also aliased nodes.
19331         (add_cgraph_node_to_partition,
19332         add_varpool_node_to_partition): Work on nodes, not functions/variables;
19333         when adding alias, add also the aliased object.
19334
19335 2012-04-09  Uros Bizjak  <ubizjak@gmail.com>
19336
19337         PR target/52883
19338         * config/i386/predicates.md (x86_64_zext_general_operand): Prevent
19339         VOIDmode immediate operands.
19340         * config/i386/constraints.md (Wz): New constraint.
19341         * config/i386/i386.md (*zero_extendsidi2_rex64): Use Wz instead of Z.
19342
19343 2012-04-09  Eric Botcazou  <ebotcazou@adacore.com>
19344
19345         PR target/52717
19346         * config/sparc/sparc.c (sparc_file_end): Set TREE_PUBLIC explicitly on
19347         the DECL generated for the special GOT helper.
19348
19349 2012-04-09  Oleg Endo  <olegendo@gcc.gnu.org>
19350
19351         * config/sh/constraints.md: Update list of constraints in
19352         comment block.
19353         (Sr0): Remove unused memory constraint.
19354
19355 2012-04-08  Manuel López-Ibáñez  <manu@gcc.gnu.org>
19356
19357         * tree-pretty-print.h: Update comment.
19358
19359 2012-04-08  Oleg Endo  <olegendo@gcc.gnu.org>
19360
19361         * config/sh/sh.md: Use braced string notation where applicable.
19362         (*prefetch_i4, prefetch_m2a): Merge into ...
19363         (*prefetch): ... this new insn.
19364
19365 2012-04-07  Oleg Endo  <olegendo@gcc.gnu.org>
19366
19367         * config/sh/sh.h (high_life_started): Remove
19368         * config/sh/predicates.md (general_movdst_operand): Use
19369         'reload_in_progress' instead of 'high_life_started'.
19370         * config/sh/sh.md (divsi_inv_call, *divsi_inv_call_combine,
19371         divsi_inv_fp): Likewise.
19372
19373 2012-04-07  Oleg Endo  <olegendo@gcc.gnu.org>
19374
19375         * config/sh/sh-protos.h (prepare_move_operands): Return void
19376         instead of int.
19377         * config/sh/sh.c (prepare_move_operands): Likewise.
19378         * config/sh/sh.md: Remove return value checks of prepare_move_operands.
19379
19380 2012-04-07  Oleg Endo  <olegendo@gcc.gnu.org>
19381
19382         * config/sh/sh-protos.h (fp_int_operand, symbol_ref_operand,
19383         general_movsrc_operand, general_movdst_operand, arith_reg_operand,
19384         fp_arith_reg_operand, arith_operand, arith_reg_or_0_operand,
19385         logical_operand, fpscr_operand, fpul_operand, expand_fp_branch,
19386         commutative_float_operator, noncommutative_float_operator,
19387         sh_handle_pragma): Remove.
19388
19389 2012-04-06  Sandra Loosemore  <sandra@codesourcery.com>
19390
19391         * doc/invoke.texi:  Clean up Texinfo markup throughout the file.
19392         Use @option markup on command-line options.  Use @samp markup on
19393         literal keywords to options.  Use @code markup on code fragments.
19394         Use other markup in preference to quotation marks in the text.
19395         Add markup to some passages without any.
19396
19397 2012-04-06  Mike Stump  <mikestump@comcast.net>
19398
19399         * gimple-fold.c (gimple_fold_stmt_to_constant_1): Avoid warning.
19400
19401 2012-04-06  Oleg Endo  <olegendo@gcc.gnu.org>
19402
19403         * config/sh/sh.c (hi_const): Remove.
19404         (find_barrier, sh_reorg): Use satisfies_constraint_I16 instead
19405         of hi_const.
19406
19407 2012-04-06  Oleg Endo  <olegendo@gcc.gnu.org>
19408
19409         * config/sh/sh-protos.h (sh_expand_t_scc): Change return type from int
19410         to bool.
19411         * config/sh/sh.c (sh_expand_t_scc): Likewise.
19412         * config/sh/sh.md (cstoresi4, cstoredi4): Remove GET_CODE checks before
19413         calling sh_expand_t_scc.
19414
19415 2012-04-06  Oleg Endo  <olegendo@gcc.gnu.org>
19416
19417         * config/sh/sh-protos.h (fp_zero_operand, fp_one_operand,
19418         nonpic_symbol_mentioned_p, expand_block_move, expand_ashiftrt,
19419         sh_dynamicalize_shift_p, gen_shl_and, gen_shl_sext, system_reg_operand,
19420         reg_unused_after, sh_can_redirect_branch, sh_need_epilogue, fldi_ok,
19421         sh_hard_regno_rename_ok, sh_cfun_interrupt_handler_p,
19422         sh_cfun_resbank_handler_p, sh_attr_renesas_p, sh_cfun_attr_renesas_p,
19423         check_use_sfunc_addr, sh_contains_memref_p, sh_loads_bankedreg_p,
19424         sh2a_is_function_vector_call): Use bool as return type.
19425         (sh_pass_in_reg_p): Remove.
19426         * config/sh/sh.c (broken_move, mova_p, noncall_uses_reg, high_pressure,
19427         flow_dependent_p, sh2a_function_vector_p, expand_block_move,
19428         expand_ashiftrt, sh_dynamicalize_shift_p, gen_shl_and, gen_shl_sext,
19429         sh_need_epilogue, sh2a_is_function_vector_call, sh_attr_renesas_p,
19430         sh_cfun_attr_renesas_p, sh_cfun_interrupt_handler_p,
19431         sh_cfun_resbank_handler_p, system_reg_operand, fp_zero_operand,
19432         fp_one_operand, fldi_ok, reg_unused_after, sh_can_redirect_branch,
19433         sh_hard_regno_rename_ok, check_use_sfunc_addr, sh_contains_memref_p,
19434         sh_loads_bankedreg_p): Use bool as return type.
19435         (nonpic_symbol_mentioned_p): Use bool as return type.  Remove
19436         'register' modifier.
19437
19438 2012-04-06  Matt Turner  <mattst88@gmail.com>
19439
19440         * doc/install.texi: Correct typo "-mno-lsc" -> "-mno-llsc".
19441
19442 2012-04-06  Eric Botcazou  <ebotcazou@adacore.com>
19443
19444         * config/ia64/ia64.c (ia64_load_pair_ok): Return 0 if the second member
19445         of the destination isn't also a FP_REGS register.
19446
19447 2012-04-05  Teresa Johnson  <tejohnson@google.com>
19448             H.J. Lu  <hongjiu.lu@intel.com>
19449
19450         * config/i386/i386.h (ix86_tune_indices): Add X86_TUNE_LCP_STALL.
19451         * config/i386/i386.md (move immediate to memory peephole2):
19452         Add cases for HImode move when LCP stall avoidance is needed.
19453         * config/i386/i386.c (initial_ix86_tune_features): Initialize
19454         X86_TUNE_LCP_STALL entry.
19455
19456 2012-04-05  Uros Bizjak  <ubizjak@gmail.com>
19457
19458         PR target/52882
19459         * config/i386/i386.c (ix86_decompose_address): Allow VOIDmode
19460         CONST_INT operands, zero-extended with AND.
19461
19462 2012-04-05  Oleg Endo  <olegendo@gcc.gnu.org>
19463
19464         PR target/50751
19465         * config/sh/sh.c (sh_find_mov_disp_adjust): Take machine_mode as the
19466         first argument instead of mode size.  Move displacement calculations
19467         to ...
19468         (mov_insn_size, max_mov_insn_displacement, mov_insn_alignment_mask):
19469         ... these new functions.
19470         (disp_adjust): Remove max_mov_disp field.
19471         (sh_legitimate_index_p): Use max_mov_insn_displacement and
19472         mov_insn_alignment_mask.
19473         (sh_address_cost): Use max_mov_insn_displacement.
19474
19475 2012-04-05  Andrew Stubbs  <ams@codesourcery.com>
19476
19477         * config/arm/arm.md (arch): Add neon_onlya8 and neon_nota8.
19478         (arch_enabled): Handle new arch types.
19479         (one_cmpldi2): Add NEON support.
19480
19481 2012-04-05  Richard Guenther  <rguenther@suse.de>
19482
19483         * gimple.c (walk_gimple_op): Compute val_only for the LHS
19484         of an assigment in the canonical way, avoiding is_gimple_mem_rhs.
19485         (is_gimple_mem_rhs, is_gimple_reg_rhs, is_gimple_stmt): Move ...
19486         * gimplify.c (is_gimple_mem_rhs, is_gimple_reg_rhs, is_gimple_stmt):
19487         ... here and make static.
19488         * gimple.h (is_gimple_mem_rhs, is_gimple_reg_rhs, is_gimple_stmt):
19489         Remove.
19490
19491 2012-04-05  Richard Guenther  <rguenther@suse.de>
19492
19493         * tree-ssa-dse.c (dse_optimize_stmt): Remember the stmt
19494         basic-block before removing it.
19495
19496 2012-04-05  Richard Guenther  <rguenther@suse.de>
19497
19498         * tree-ssanames.c (release_dead_ssa_names): Compact the SSA
19499         version namespace as we release the freelist.
19500
19501 2012-04-05  Richard Guenther  <rguenther@suse.de>
19502
19503         * tree-nrv.c (tree_nrv): Release VDEFs.
19504         * tree-sra.c (sra_modify_constructor_assign): Likewise.
19505         (sra_modify_assign): Likewise.
19506         * tree-vect-stmts.c (vect_remove_stores): Likewise.
19507         * tree-vect-loop.c (vect_transform_loop): Likewise.
19508         * tree-ssa-dom.c (optimize_stmt): Likewise.
19509         * tree-vect-slp.c (vect_schedule_slp): Likewise.
19510         * tree-ssa-math-opts.c (execute_cse_sincos): Likewise.
19511
19512 2012-04-05  Richard Guenther  <rguenther@suse.de>
19513
19514         * gimple-iterator.c (gsi_remove): Return whether EH edges need to be
19515         cleanup.
19516         * gimple.h (gsi_remove): Adjust.
19517         * tree-ssa-operands.c (unlink_stmt_vdef): Optimize.
19518         * tree-ssa-dom.c (optimize_stmt): Use gsi_remove result.
19519         * tree-ssa-dse.c (dse_optimize_stmt): Likewise.
19520         * tree-ssa-forwprop.c (remove_prop_source_from_use): Likewise.
19521         * tree-ssa-math-opts.c (execute_optimize_widening_mul): Likewise.
19522         * tree-ssa-pre.c (eliminate): Likewise.
19523
19524 2012-04-04  Mike Stump  <mikestump@comcast.net>
19525
19526         * doc/rtl.texi (const_double): Document as sign-extending.
19527         * expmed.c (expand_mult): Ensure we don't use shift incorrectly.
19528         * emit-rtl.c (immed_double_int_const): Refine to state the
19529         value is signed.
19530         * simplify-rtx.c (mode_signbit_p): Add a fixme for wider than
19531         CONST_DOUBLE integers.
19532         (simplify_const_unary_operation, UNSIGNED_FLOAT): Ensure no
19533         negative values are converted.  Fix conversions bigger than
19534         HOST_BITS_PER_WIDE_INT.
19535         (simplify_binary_operation_1): Ensure we don't use shift incorrectly.
19536         (simplify_immed_subreg): Sign-extend CONST_DOUBLEs.
19537         * explow.c (plus_constant_mode): Add.
19538         (plus_constant): Implement with plus_constant_mode.
19539         * rtl.h (plus_constant_mode): Add.
19540
19541 2012-04-04  Richard Guenther  <rguenther@suse.de>
19542
19543         PR tree-optimization/52808
19544         * tracer.c (tail_duplicate): Do not tail-duplicate loop header blocks.
19545         * Makefile.in (tracer.o): Depend on $(CFGLOOP_H).
19546
19547 2012-04-04  Tristan Gingold  <gingold@adacore.com>
19548
19549         * expr.c (expand_expr_real_2): Handle larger sizetype in
19550         POINTER_PLUS_EXPR.
19551
19552 2012-04-03  Kaz Kojima  <kkojima@gcc.gnu.org>
19553
19554         * config/sh/t-sh (MULTILIB_MATCHES): Match m2a-single-only
19555         to m2a-single instead of m2e.
19556
19557 2012-04-03  Eric Botcazou  <ebotcazou@adacore.com>
19558
19559         * expr.c (get_bit_range): Add OFFSET parameter and adjust BITPOS.
19560         Change type of BITOFFSET to signed.  Make sure the lower bound of
19561         the computed range is non-negative by adjusting OFFSET and BITPOS.
19562         (expand_assignment): Adjust call to get_bit_range.
19563
19564 2012-04-03  Sandeep Kumar Singh  <Sandeep.Singh2@kpitcummins.com>
19565
19566         * h8300/h8300.c (h8300_current_function_monitor_function_p):
19567         New function. Added to check monitor functions.
19568         (h8300_option_override): Modified to generate error/warning
19569         messages for invalid combinations of different command line
19570         options.
19571         * h8300/h8300.md: Generate 'rte' for monitor functions. Do not
19572         save EXR on stack for monitor function in case of H8S target
19573         when "-mno-exr" is passed.
19574         * h8300/h8300-protos.h (h8300_current_function_monitor_function_p):
19575         Add prototype.
19576         * doc/invoke.texi: Document H8S options.
19577
19578 2012-04-03  Tristan Gingold  <gingold@adacore.com>
19579
19580         * configure.ac: Use GCC_AC_FUNC_MMAP_BLACKLIST instead
19581         of gcc_AC_FUNC_MMAP_BLACKLIST.
19582         * acinclude.m4 (gcc_AC_FUNC_MMAP_BLACKLIST): Remove.
19583         * Makefile.in (aclocal_deps): Add mmap.m4.
19584         * configure: Regenerate.
19585         * aclocal.m4: Regenerate.
19586
19587 2012-04-03  Richard Guenther  <rguenther@suse.de>
19588
19589         PR tree-optimization/52808
19590         * tracer.c (tail_duplicate): Return whether we have duplicated
19591         any block.
19592         (tracer): If we have duplicated any block, cleanup the CFG.
19593         * cfghooks.c (duplicate_block): If we duplicated a loop
19594         header but not its loop, destroy the loop because it now has
19595         multiple entries.
19596         * tree-ssa-threadupdate.c (thread_through_loop_header): Tell
19597         the cfg manipulation routines we are not creating a multiple
19598         entry loop.
19599
19600 2012-04-03  Tristan Gingold  <gingold@adacore.com>
19601
19602         * config/vms/vms-c.c (vms_pragma_nomember_alignment): Handle
19603         'byte' alignment.
19604         (vms_c_common_override_options): Allow parameterless variadic
19605         functions.
19606
19607 2012-04-03  Jakub Jelinek  <jakub@redhat.com>
19608
19609         PR tree-optimization/52835
19610         * tree-data-ref.c (build_rdg): Return NULL if
19611         compute_data_dependences_for_loop failed.
19612
19613 2012-04-03  Eric Botcazou  <ebotcazou@adacore.com>
19614
19615         * varasm.c (initializer_constant_valid_for_bitfield_p): Return true
19616         for REAL_CST as well.
19617         (output_constructor): Use RECORD_OR_UNION_TYPE_P predicate.
19618         In the bitfield case, if the value is a REAL_CST, convert it first to
19619         an INTEGER_CST.
19620
19621 2012-04-02  H.J. Lu  <hongjiu.lu@intel.com>
19622
19623         * config.gcc: Use i386/biarchx32.h instead of i386/biarch64.h
19624         for --with-abi={x32|mx32} or --with-multilib-list=mx32.
19625         (supported_defaults): Add abi for i[34567]86-*-* and x86_64-*-*.
19626
19627         * config/i386/biarchx32.h: New.
19628
19629 2012-04-02  Anatoly Sokolov  <aesok@post.ru>
19630
19631         * config/arm/arm.h (PREFERRED_RELOAD_CLASS): Remove.
19632         * config/arm/arm.c (TARGET_PREFERRED_RELOAD_CLASS): Define.
19633         (arm_preferred_reload_class): New function.
19634
19635 2012-04-02  Richard Guenther  <rguenther@suse.de>
19636
19637         PR tree-optimization/52756
19638         * tree-ssa-threadupdate.c (def_split_header_continue_p): New function.
19639         (thread_through_loop_header): After threading through the loop latch
19640         remove the split part from the loop and clear further threading
19641         opportunities that would create a multiple entry loop.
19642
19643 2012-04-02  Richard Guenther  <rguenther@suse.de>
19644
19645         PR rtl-optimization/52800
19646         * cprop.c (execute_rtl_cprop): Call cleanup_cfg with
19647         CLEANUP_CFG_CHANGED.
19648
19649 2012-04-02  Richard Guenther  <rguenther@suse.de>
19650
19651         PR middle-end/52803
19652         * loop-init.c (gate_handle_loop2): Destroy loops here if
19653         we don't enter RTL loop optimizers.
19654
19655 2012-04-02  Uros Bizjak  <ubizjak@gmail.com>
19656
19657         Partially revert:
19658         2012-03-29  Richard Guenther  <rguenther@suse.de>
19659
19660         * rtl.h (extended_count): Remove.
19661         * combine.c (extended_count): Remove.
19662
19663 2012-04-02  Dodji Seketeli  <dodji@redhat.com>
19664
19665         PR c++/40942
19666         * pt.c (more_specialized_fn):  Don't apply decay conversion to
19667         types of function parameters.
19668
19669 2012-04-02  Tristan Gingold  <gingold@adacore.com>
19670
19671         * ggc-page.c (PAGE_L1_SIZE, PAGE_L2_SIZE, LOOKUP_L1, LOOKUP_L2)
19672         (ggc_allocated_p, lookup_page_table_entry, set_page_table_entry)
19673         (alloc_page, init_ggc, clear_marks, struct ggc_pch_data)
19674         (ggc_pch_this_base): Use uintptr_t instead of size_t.
19675
19676 2012-03-31  H.J. Lu  <hongjiu.lu@intel.com>
19677
19678         PR bootstrap/52784
19679         * config/i386/i386.c (ix86_option_override_internal): Don't
19680         check TARGET_64BIT if TARGET_64BIT_DEFAULT is false.
19681
19682 2012-03-31  Eric Botcazou  <ebotcazou@adacore.com>
19683
19684         * tree-cfg.c (call_can_make_abnormal_goto): New predicate.
19685         (stmt_can_make_abnormal_goto): Use it.
19686         (is_ctrl_altering_stmt): Likewise.
19687
19688 2012-03-30  Naveen H.S  <naveen.S@kpitcummins.com>
19689             Kaz Kojima  <kkojima@gcc.gnu.org>
19690
19691         * config/sh/sh.c (push_regs): Skip banked registers when
19692         resbank attribute is specified.
19693         (sh_expand_epilogue): Likewise.
19694
19695 2012-03-30  Richard Henderson  <rth@redhat.com>
19696
19697         PR debug/52727
19698         * combine-stack-adj.c (prev_active_insn_bb): New.
19699         (next_active_insn_bb): New.
19700         (force_move_args_size_note): New.
19701         (combine_stack_adjustments_for_block): Use it.
19702
19703 2012-03-30  Richard Henderson  <rth@redhat.com>
19704
19705         * config/i386/i386.c (struct expand_vec_perm_d): Add one_operand_p.
19706         (ix86_expand_vector_init_duplicate): Initialize it.
19707         (expand_vec_perm_palignr): Likewise.
19708         (ix86_expand_vec_perm_const): Likewise.
19709         (ix86_vectorize_vec_perm_const_ok): Likewise.
19710         (expand_vec_perm_blend): Use it.
19711         (expand_vec_perm_vpermil): Likewise.
19712         (expand_vec_perm_pshufb): Likewise.
19713         (expand_vec_perm_1): Likewise.
19714         (expand_vec_perm_pshuflw_pshufhw): Likewise.
19715         (expand_vec_perm_interleave2): Likewise.
19716         (expand_vec_perm_vpermq_perm_1): Likewise.
19717         (expand_vec_perm_vperm2f128): Likewise.
19718         (expand_vec_perm_interleave3): Likewise.
19719         (expand_vec_perm_vperm2f128_vblend): Likewise.
19720         (expand_vec_perm_vpshufb2_vpermq): Likewise.
19721         (expand_vec_perm_vpshufb2_vpermq_even_odd): Likewise,.
19722         (expand_vec_perm_broadcast): Likewise.
19723         (expand_vec_perm_vpshufb4_vpermq2): Likewise.
19724
19725 2012-03-30  Richard Henderson  <rth@redhat.com>
19726
19727         * dwarf2out.c (gen_variable_die): Initialize off.
19728
19729 2012-03-30  Tristan Gingold  <gingold@adacore.com>
19730
19731         * config/vms/vms-f.c: New file.
19732         * config/vms/t-vms (vms-f.o): New rule.
19733         * config.gcc (*-*-*vms*): Define fortran_target_objs.
19734
19735 2012-03-30  Richard Guenther  <rguenther@suse.de>
19736
19737         PR tree-optimization/52754
19738         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Only
19739         propagate arbitrary addresses into really plain dereferences.
19740
19741 2012-03-30  Richard Guenther <rguenther@suse.de>
19742
19743         PR middle-end/52772
19744         * except.c (emit_to_new_bb_before): Move loop updating ...
19745         (dw2_build_landing_pads): ... here.  Use a proper block for
19746         querying the loop father.
19747
19748 2012-03-30  Tristan Gingold  <gingold@adacore.com>
19749
19750         * config/ia64/ia64.c (ia64_section_type_flags): Remove
19751         common_object attribute handling.
19752         (SECTION_VMS_OVERLAY): Remove
19753         (ia64_vms_common_object_attribute): Replace abort with an assert.
19754         Do not set DECL_SECTION_NAME.
19755         (ia64_vms_output_aligned_decl_common): Handle common_object
19756         attribute.
19757         (ia64_vms_elf_asm_named_section): Remove.
19758         * config/ia64/vms.h (TARGET_ASM_NAMED_SECTION): Remove.
19759
19760 2012-03-30  Richard Guenther  <rguenther@suse.de>
19761
19762         PR middle-end/52786
19763         * double-int.c (rshift_double): Remove not needed cast.
19764
19765 2012-03-30  Richard Guenther  <rguenther@suse.de>
19766
19767         * tree-affine.h (print_aff): Remove.
19768         * tree-affine.c (print_aff): Make static.
19769         * tree-data-ref.h (access_matrix_get_index_for_parameter): Remove.
19770         (get_references_in_stmt): Likewise.
19771         (print_direction_vector): Likewise.
19772         (print_dir_vectors): Likewise.
19773         (print_dist_vectors): Likewise.
19774         (dump_subscript): Likewise.
19775         (dump_ddrs): Likewise.
19776         (dump_dist_dir_vectors): Likewise.
19777         (dump_data_references): Likewise.
19778         (dump_data_dependence_relation): Likewise.
19779         (dump_data_dependence_direction): Likewise.
19780         (dump_rdg_vertex): Likewise.
19781         (dump_rdg_component): Likewise.
19782         (debug_ddrs): Declare.
19783         (struct data_ref_loc_d): Move ...
19784         * tree-data-ref.c (struct data_ref_loc_d): ... here.
19785         (get_references_in_stmt): Make static.
19786         (dump_data_references): Likewise.
19787         (dump_subscript): Likewise.
19788         (print_direction_vector): Likewise.
19789         (print_dir_vectors): Likewise.
19790         (print_dist_vectors): Likewise.
19791         (dump_data_dependence_relation): Likewise.
19792         (dump_dist_dir_vectors): Likewise.
19793         (dump_ddrs): Likewise.
19794         (dump_rdg_vertex): Likewise.
19795         (dump_rdg_component): Likewise.
19796         (debug_ddrs): New function.
19797         (access_matrix_get_index_for_parameter): Remove.
19798
19799 2012-03-30  Tristan Gingold  <gingold@adacore.com>
19800
19801         * config/vms/vms.c (VMS_CRTL_FLOAT32): Rename.
19802         (VMS_CRTL_FLOAT64, VMS_CRTL_FLOAT64_VAXD): New.
19803         (VMS_CRTL_FLOAT128, VMS_CRTL_DPML, VMS_CRTL_NODMPL)
19804         (VMS_CRTL_32ONLY, VMS_CRTL_G_MASK, VMS_CRTL_G_NONE)
19805         (VMS_CRTL_GA, VMS_CRTL_GL, VMS_CRTL_FLOATV2): New.
19806         (vms_patch_builtins): Handle new flags
19807         * config/vms/vms-crtlmap.map: Completed using nm on
19808         c and math system libraries.
19809         * config/vms/make-crtlmap.awk: Handle any number of flags.
19810
19811 2012-03-30  Martin Jambor  <mjambor@suse.cz>
19812
19813         * tree-ssa-ccp.c (insert_clobbers_for_var): Do not assert that there
19814         is a builtin_stack_save in a dominating BB.
19815
19816 2012-03-29  Uros Bizjak  <ubizjak@gmail.com>
19817
19818         * config/i386/sse.md (avx_h<plusminus_insn>v4df3): Fix results
19819         crossing 128bit lane boundary.
19820
19821 2012-03-29  Vladimir Makarov  <vmakarov@redhat.com>
19822
19823         * ira-color.c (setup_left_conflict_sizes_p): Process all
19824         conflicting objects.
19825
19826 2012-03-29  Jakub Jelinek  <jakub@redhat.com>
19827
19828         PR tree-optimization/52760
19829         * tree-vect-slp.c (vect_get_constant_vectors): Convert constant_p
19830         shift count for {L,R}{SHIFT,ROTATE}_EXPR to TREE_TYPE (vector_type).
19831
19832 2012-03-29  Richard Guenther  <rguenther@suse.de>
19833
19834         * cgraph.h (cgraph_materialize_all_clones): Remove.
19835         (reset_inline_failed): Likewise.
19836         * cgraphunit.c (cgraph_materialize_all_clones): Make static.
19837         * cgraphbuild.c (reset_inline_failed): Remove.
19838         * rtl.h (cse_main): Remove.
19839         (extended_count): Likewise.
19840         * cse.c (dump_class): Mark as DEBUG_FUNCTION.
19841         (cse_main): Make static.
19842         * combine.c (extended_count): Remove.
19843         (dump_combine_stats): Mark as DEBUG_FUNCTION.
19844         * basic-block.h (reorder_basic_blocks): Remove.
19845         * bb-reorder.c (reorder_basic_blocks): Make static.
19846         * Makefile.in (dse.o): Remove dse.h dependency.
19847         * dse.h: Remove.
19848         * dse.c (gate_dse): Remove.
19849         (clear_alias_mode_eq): Likewise.
19850         (clear_alias_mode_hash): Likewise.
19851         (dse_record_singleton_alias_set): Likewise.
19852         (dse_invalidate_singleton_alias_set): Likewise.
19853
19854 2012-03-29  H.J. Lu  <hongjiu.lu@intel.com>
19855
19856         * config/linux-android.h (ANDROID_STARTFILE_SPEC): Use
19857         crtbegin_so%O%s for -shared.
19858         (ANDROID_ENDFILE_SPEC): Use crtend_so%O%s for -shared.
19859
19860 2012-03-29  Richard Guenther  <rguenther@suse.de>
19861
19862         * tree-flow.h (struct pre_expr_d): Remove forward declaration.
19863         (add_to_value): Remove.
19864         (print_value_expressions): Likewise.
19865         * tree-ssa-pre.c (add_to_value): Make static.
19866         (print_value_expressions): Likewise.
19867         * gimple.h (gimple_adjust_this_by_delta): Remove.
19868         * gimple-fold.c (gimple_adjust_this_by_delta): Likewise.
19869
19870 2012-03-29  Richard Guenther  <rguenther@suse.de>
19871
19872         PR middle-end/50708
19873         * double-int.h (rshift_double): Remove.
19874         * double-int.c (lshift_double): Use absu_hwi to make count positive.
19875         (rshift_double): Make static, take unsigned count argument,
19876         remove handling of negative count argument.
19877         (double_int_rshift): Dispatch to lshift_double.
19878
19879 2012-03-28  H.J. Lu  <hongjiu.lu@intel.com>
19880
19881         * config/i386/biarch64.h (TARGET_64BIT_DEFAULT): Add
19882         OPTION_MASK_ABI_64.
19883
19884         * config/i386/gnu-user64.h (SPEC_64): Support TARGET_BI_ARCH == 2.
19885         (SPEC_X32): Likewise.
19886         (MULTILIB_DEFAULTS): Likewise.
19887
19888         * config/i386/i386.c (isa_opts): Remove -m64.
19889         (ix86_target_string): Properly handle -m32/-m64/-mx32.
19890         (ix86_option_override_internal): Properly
19891         set OPTION_MASK_ISA_64BIT and OPTION_MASK_ISA_X32 as well as
19892         handle -m32, -m64 and -mx32.
19893
19894         * config/i386/i386.h (TARGET_X32): Replace OPTION_ISA_X32
19895         with OPTION_ABI_X32.  Moved after TARGET_LP64.
19896         (TARGET_LP64): Changed to OPTION_ABI_64.
19897
19898         * config/i386/i386.opt (m64): Replace ISA_64BIT with ABI_64.
19899         (mx32): Replace ISA_X32 with ABI_X32.
19900
19901 2012-03-28  Eric Botcazou  <ebotcazou@adacore.com>
19902
19903         * tree.c (tree_size) <VECTOR_CST>: New case.
19904
19905 2012-03-28  Uros Bizjak  <ubizjak@gmail.com>
19906
19907         * config/i386/i386.c (ix86_modes_tieable_p): Handle 32bit AVX modes.
19908         (ix86_expand_vector_move_misalign): Remove un-needed gen_lowpart calls.
19909
19910 2012-03-28  Jakub Jelinek  <jakub@redhat.com>
19911
19912         PR middle-end/52691
19913         * tree-ssa-ccp.c (optimize_stdarg_builtin): Optimize
19914         __builtin_va_start to __builtin_next_arg if the latter is
19915         builtin_decl_explicit_p rather than when it is not.
19916
19917         PR middle-end/52750
19918         * tree-vect-generic.c (vector_element): Perform multiplication
19919         for pos in bitsizetype type instead of idx type.
19920
19921 2012-03-28  Richard Guenther  <rguenther@suse.de>
19922
19923         * loop-init.c (loop_optimizer_init): If loops are preserved
19924         perform incremental initialization of required loop features.
19925         (loop_optimizer_finalize): If loops are to be preserved only
19926         clean up optional loop features.
19927         (rtl_loop_done): Forcefully free loops here.
19928         * cgraph.c (cgraph_release_function_body): Forcefully free loops.
19929         * cfgexpand.c (expand_gimple_cond): Properly add new basic-blocks
19930         to existing loops.
19931         (construct_init_block): Likewise.
19932         (construct_exit_block): Likewise.
19933         (gimple_expand_cfg): Clear LOOP_CLOSED_SSA loop state.  Cleanup
19934         the CFG after expanding.
19935         * cfgloop.c (verify_loop_structure): Calculate or verify dominators.
19936         If we needed to calculate them, free them afterwards.
19937         * tree-pass.h (PROP_loops): New define.
19938         * tree-ssa-loop.c (pass_tree_loop_init): Provide PROP_loops.
19939         * basic-block.h (CLEANUP_CFG_CHANGED): New.
19940         * cfgcleanup.c (merge_blocks_move): Protect loop latches.
19941         (cleanup_cfg): If we did something and have loops around, fix them up.
19942         * cse.c (rest_of_handle_cse_after_global_opts): Call cleanup_cfg
19943         with CLEANUP_CFG_CHANGED.
19944         * cfghooks.c (merge_blocks): If we merge a loop header into
19945         its predecessor, update the loop structure.
19946         (duplicate_block): If we copy a loop latch, adjust loop state
19947         to note we may have multiple latches.
19948         (delete_basic_block): Mark loops for fixup if we remove a loop.
19949         * cfganal.c (forwarder_block_p): Protect loop latches, headers
19950         and preheaders.
19951         * cfgrtl.c (rtl_can_merge_blocks): Protect loop latches.
19952         (cfg_layout_can_merge_blocks_p): Likewise.
19953         * cprop.c (bypass_block): If we create a loop with multiple
19954         entries, mark it for removal.
19955         * except.c (emit_to_new_bb_before): Add the new basic-block
19956         to existing loops.
19957         * tree-eh.c (lower_resx): Likewise.
19958         * omp-low.c (finalize_task_copyfn): Do not copy PROP_loops.
19959         (expand_omp_taskreg): Likewise.
19960         * tree-inline.c (initialize_cfun): Likewise.
19961         * tree-mudflap.c (add_bb_to_loop): Prototype.
19962         (mf_build_check_statement_for): Properly add new basic-blocks
19963         to existing loops.
19964         * tree-ssa-threadupdate.c (thread_block): Mark loops for fixup
19965         if we remove a loop.
19966         (thread_through_loop_header): Likewise.
19967         * trans-mem.c (tm_log_emit_save_or_restores): Properly add
19968         new basic-blocks to existing loops.
19969         (expand_transaction): Likewise.
19970         * Makefile.in (except.o): Add $(CFGLOOP_H).
19971         (expr.o): Likewise.
19972         (cgraph.o): Likewise.
19973         (cprop.o): Likewise.
19974         (cfgexpand.o): Likewise.
19975         (cfganal.o): Likewise.
19976         (trans-mem.o): Likewise.
19977         (tree-eh.o): Likewise.
19978
19979 2012-03-28  Georg-Johann Lay  <avr@gjlay.de>
19980
19981         PR target/52692
19982         * config/avr/avr.c (TARGET_BUILTIN_DECL): New define.
19983         (avr_builtin_decl): New static function.
19984         (struct avr_builtin_description, avr_bdesc): Move up.
19985         Add GTY marker. Add field fndecl. Remove redundant field id.
19986         (avr_init_builtins): Initialize avr_bdesc[ID].fndecl.
19987         (avr_expand_builtin): Code cleanup because .id is removed.
19988
19989 2012-03-28  Georg-Johann Lay  <avr@gjlay.de>
19990
19991         PR target/52737
19992         * config.gcc (tm_file): Remove avr/multilib.h.
19993
19994         * doc/invoke.texi (AVR Options): Adjust documentation of -mtiny-stack.
19995
19996         * config/avr/genmultilib.awk: Remove code to generate multilib.h.
19997         (BEGIN): Use -msp8 as multilib option instead of -mtiny-stack.
19998         * config/avr/t-avr: Remove generation of multilib.h.
19999         * config/avr/t-multilib: Regenerate.
20000         * config/avr/multilib.h: Remove.
20001         * config/avr/avr.opt (-msp8): New option.
20002         (avr_sp8): New variable.
20003         * config/avr/driver-avr.c (avr_device_to_sp8): New function.
20004         * config/avr/avr.h (AVR_HAVE_SPH): New define.
20005         (AVR_HAVE_8BIT_SP): Also set by avr_sp8 i.e. -msp8.
20006         (avr_device_to_sp8): New prototype.
20007         (EXTRA_SPEC_FUNCTIONS): Add { "device_to_sp8", avr_device_to_sp8 }
20008         (DRIVER_SELF_SPECS): New define.
20009         * config/avr/avr-c.c (avr_cpu_cpp_builtins): New built-in defines:
20010         __AVR_SP8__, __AVR_HAVE_SPH__.
20011         * config/avr/avr.c (output_movhi): Use AVR_HAVE_SPH instead of
20012         AVR_HAVE_8BIT_SP to decide if SP_H is present.
20013         (avr_file_start): Ditto.
20014
20015 2012-03-28  Jakub Jelinek  <jakub@redhat.com>
20016
20017         PR target/52736
20018         * config/i386/sse.md (sse2_loadlpd splitter): Use offset 0
20019         instead of 8 in adjust_address.
20020
20021 2012-03-27  Aurelien Buhrig  <aurelien.buhrig.gcc@gmail.com>
20022
20023         PR middle-end/51893
20024         * expmed.c (store_bit_field_1): Fix wordnum value for big-endian
20025         targets.
20026
20027 2012-03-27  Oleg Endo  <olegendo@gcc.gnu.org>
20028
20029         PR target/50751
20030         * config/sh/sh.c (sh_legitimize_address, sh_legitimize_reload_address):
20031         Rearrange conditional logic.  Move displacement address calculations
20032         to ...
20033         (sh_find_mov_disp_adjust): ... this new function.
20034
20035 2012-03-27  H.J. Lu  <hongjiu.lu@intel.com>
20036
20037         * config/arm/arm.opt (mapcs): Remove MaskExists.
20038         * config/cris/linux.opt (mno-gotplt): Likewise.
20039         * config/i386/i386.opt (mhard-float): Likewise.
20040         (msse4): Likewise.
20041         (mno-sse4): Likewise.
20042         * config/m68k/m68k.opt (mhard-float): Likewise.
20043         * config/mep/mep.op (mcop32): Likewise.
20044         * config/pa/pa-hpux.opt (msio): Likewise.
20045         * config/pa/pa64-hpux.opt (mgnu-ld): Likewise.
20046         * config/picochip/picochip.opt (mlittle): Likewise.
20047         * config/sh/sh.opt (mrenesas): Likewise.
20048         * config/sparc/long-double-switch.opt (mlong-double-128): Likewise.
20049         * config/sparc/sparc.opt (mhard-float): Likewise.
20050         * config/v850/v850.opt (mv850es): Likewise.
20051         * config/vax/vax.opt (mg-float): Likewise.
20052
20053 2012-03-27  Martin Jambor  <mjambor@suse.cz>
20054
20055         PR middle-end/52693
20056         * tree-sra.c (sra_modify_assign): Do not call
20057         load_assign_lhs_subreplacements when working with an unscalarizable
20058         region.
20059
20060 2012-03-27  Uros Bizjak  <ubizjak@gmail.com>
20061
20062         PR target/52698
20063         * config/i386/i386-protos.h (ix86_legitimize_reload_address):
20064         New prototype.
20065         * config/i386/i386.h (LEGITIMIZE_RELOAD_ADDRESS): New define.
20066         * config/i386/i386.c: Include reload.h.
20067         (ix86_legitimize_reload_address): New function.
20068
20069 2012-03-27  H.J. Lu  <hongjiu.lu@intel.com>
20070
20071         * opth-gen.awk: Allocated a bit for Mask and InverseMask if it
20072         hasn't been allocated.  Define a target macro for Mask and
20073         InverseMask if it hasn't been defined.  Remove MaskExists handling.
20074
20075         * doc/options.texi: Remove MaskExists.
20076
20077 2012-03-27  Chung-Lin Tang  <cltang@codesourcery.com>
20078
20079         PR target/52667
20080         * config/sh/sh.c (find_barrier): Add equality check of last_got
20081         to avoid going above orig insn. Update comments.
20082
20083 2012-03-27  Richard Guenther  <rguenther@suse.de>
20084
20085         PR middle-end/52720
20086         * fold-const.c (try_move_mult_to_index): Handle &x.array more
20087         explicitely.
20088
20089 2012-03-27  Eric Botcazou  <ebotcazou@adacore.com>
20090
20091         * expmed.c (store_bit_field): Assert that BITREGION_START is a multiple
20092         of a unit before computing the offset in units.
20093         * expr.c (get_bit_range): Return the null range if the enclosing record
20094         is part of a larger bit field.
20095
20096 2012-03-27  Tristan Gingold  <gingold@adacore.com>
20097
20098         * config/ia64/vms.h (CASE_VECTOR_MODE): Define.
20099         * config/ia64/ia64.md: Remove mode in template.
20100         Sign extend operand in expand_simple_binop.
20101         * config/ia64/ia64.h (ASM_OUTPUT_ADDR_DIFF_ELT): Use
20102         CASE_VECTOR_MODE instead of TARGET_ILP32.
20103         (ADDR_VEC_ALIGN): Make it depends on CASE_VECTOR_MODE.
20104
20105 2012-03-26  Steven Bosscher  <steven@gcc.gnu.org>
20106
20107         * varasm.c (assemble_external): #if 0 out the new assert from the
20108         previous commit, it breaks the Java and Go front ends.
20109
20110 2012-03-26  Steven Bosscher  <steven@gcc.gnu.org>
20111
20112         * toplev.c (check_global_declaration_1): Do not call assemble_external.
20113         * expr.c (emit_block_move_libcall_fn): Likewise.
20114         (clear_storage_libcall_fn): Likewise.
20115         (expand_expr_addr_expr_1): Likewise.
20116         (expand_expr_real_1): Likewise.
20117         * calls.c (rtx_for_function_call): Likewise.
20118
20119         * varasm.c (assemble_external): Assert this function is only called
20120         during or after expanding to RTL.
20121
20122 2012-03-26  Martin Jambor  <mjambor@suse.cz>
20123
20124         PR tree-optimization/50052
20125         * tree-sra.c (tree_non_aligned_mem_p): Removed.
20126         (tree_non_aligned_mem_for_access_p): Likewise.
20127         (build_accesses_from_assign): Removed strict alignment requirements
20128         checks.
20129         (access_precludes_ipa_sra_p): Likewise.
20130
20131 2012-03-26  Richard Guenther  <rguenther@suse.de>
20132
20133         PR tree-optimization/52701
20134         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Always
20135         compute and set the evolution part of PHI nodes.
20136
20137 2012-03-26  Richard Guenther  <rguenther@suse.de>
20138
20139         PR tree-optimization/52721
20140         * tree-vect-stmts.c (vect_init_vector): Handle scalars.
20141
20142 2012-03-26  Ulrich Weigand  <ulrich.weigand@linaro.org>
20143
20144         PR tree-optimization/52686
20145         * tree-vect-data-refs.c (vect_get_smallest_scalar_type): Handle
20146         WIDEN_LSHIFT_EXPR.
20147
20148 2012-03-26  Tristan Gingold  <gingold@adacore.com>
20149
20150         * config/alpha/vms.h (LINK_SPEC): Simplify.
20151         (STARTFILE_SPEC): Remove -mvms-return-codes handling.
20152         (NAME__MAIN, SYMBOL__MAIN): Remove.
20153         (VMS_DEBUG_MAIN_POINTER): Remove.
20154         * config/ia64/vms.h: Likewise.
20155         * config/alpha/alpha.c (alpha_start_function): Move vms_debug_main
20156         code to vms.c.  Call vms_start_function.
20157         * config/ia64/ia64.c (ia64_start_function): Likewise.
20158         * config/vms/vms-protos.h (vms_start_function): Declare.
20159         * config/vms/vms.c (vms_start_function): New function.
20160         * config/vms/vms.h (MATH_LIBRARY): Define.
20161         (VMS_DEBUG_MAIN_POINTER): Define.
20162
20163 2012-03-26  Eric Botcazou  <ebotcazou@adacore.com>
20164
20165         PR rtl-optimization/52629
20166         * reload1.c (count_pseudo): Short-circuit common case.
20167         (count_spilled_pseudo): Return early for pseudos without hard regs.
20168         Assert that the pseudo has got a hard reg before manipulating it.
20169
20170 2012-03-24  Jan Hubicka  <jh@suse.cz>
20171
20172         PR lto/51663
20173         * varpool.c (varpool_finalize_decl): Handle toplevel_reorder here.
20174         (decide_is_variable_needed): Do not handle toplevel reorder here.
20175         * cgraph.h (varpool_can_remove_if_no_refs): Likewise.
20176         * ipa.c (cgraph_remove_unreachable_nodes): Remove unreachable vars
20177         even at -O0.
20178
20179 2012-03-24  Eric Botcazou  <ebotcazou@adacore.com>
20180
20181         * expr.c (optimize_bitfield_assignment_op) <BIT_IOR_EXPR>: Use str_mode
20182         and str_bitsize instead of more convoluted expressions.
20183
20184 2012-03-24  Eric Botcazou  <ebotcazou@adacore.com>
20185
20186         PR target/52610
20187         * config/sparc/sparc.h (ASM_CPU_SPEC): Pass -Av8 if -mcpu=leon.
20188
20189 2012-03-24  Eric Botcazou  <ebotcazou@adacore.com>
20190
20191         PR target/52656
20192         * config/sparc/sparc.c (sparc_handle_vis_mul8x16): Fix pasto.
20193
20194 2012-03-23  Martin Jambor  <mjambor@suse.cz>
20195
20196         * tree-sra.c (build_accesses_from_assign): Remove FIXME comment.
20197
20198 2012-03-23  Richard Guenther  <rguenther@suse.de>
20199
20200         PR tree-optimization/52678
20201         * tree-vectorizer.h (struct _stmt_vec_info): Add
20202         loop_phi_evolution_part member.
20203         (STMT_VINFO_LOOP_PHI_EVOLUTION_PART): New define.
20204         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Initialize
20205         STMT_VINFO_LOOP_PHI_EVOLUTION_PART.
20206         * tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer):
20207         Use the cached evolution part and the PHI nodes value from
20208         the loop preheader edge instead of re-analyzing the evolution.
20209
20210 2012-03-22  Maxim Kuvyrkov  <maxim@codesourcery.com>
20211
20212         * config/mips/mips-tables.opt: Update.
20213         * config/mips/mips.md (processor): Add xlp.
20214         * config/mips/mips-cpus.def: Add xlp.
20215         * config/mips/mips.c (mips_rtx_cost_data): Add costs for XLP, copy from
20216         5KF for now.
20217         * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Handle xlp.
20218         * doc/invoke.texi: Mention XLP.
20219
20220 2012-03-22  Jakub Jelinek  <jakub@redhat.com>
20221
20222         PR middle-end/52547
20223         * tree-nested.c (convert_tramp_reference_stmt): Call declare_vars
20224         on any new_local_var_chain vars declared during recursing on
20225         GIMPLE_OMP_PARALLEL or GIMPLE_OMP_TASK body.
20226
20227 2012-03-22  Uros Bizjak  <ubizjak@gmail.com>
20228
20229         * config/alpha/alpha.h (ASM_OUTPUT_ALIGN): Move to config/alpha/elf.h
20230         (ASM_OUTPUT_SKIP): Move to config/alpha/vms.h
20231         (ASM_OUTPUT_LOCAL): Ditto.
20232         (ASM_OUTPUT_COMMON): Remove.
20233         * config/alpha/elf.h (ASM_OUTPUT_DEF_FROM_DECLS): Use ASM_OUTPUT_DEF.
20234         * config/alpha/vms.h (ASM_OUTPUT_ALIGN): Do not undefine before define.
20235
20236 2012-03-22  Jan Hubicka  <jh@suse.cz>
20237
20238         PR middle-end/51737
20239         * cgraph.c (cgraph_remove_node_and_inline_clones): Add FORBIDDEN_NODE
20240         parameter.
20241         * cgraph.h (cgraph_remove_node_and_inline_clones): Update prototype.
20242         * ipa-inline-transform.c (save_inline_function_body): Remove
20243         copied clone if needed.
20244         * tree-inline.c (delete_unreachable_blocks_update_callgraph): Update.
20245
20246 2012-03-22  Richard Guenther  <rguenther@suse.de>
20247
20248         PR middle-end/52666
20249         * fold-const.c (fold_ternary_loc): Fix typo.
20250
20251 2012-03-22  Georg-Johann Lay  <avr@gjlay.de>
20252
20253         PR target/52496
20254         * config/avr/avr.md (unspec): Remove UNSPEC_MEMORY_BARRIER.
20255         (unspecv): Add UNSPECV_MEMORY_BARRIER.
20256         (cli_sei): Use unspec_volatile instead of unspec for memory barrier.
20257         (delay_cycles_1, delay_cycles_2): Ditto.
20258         (delay_cycles_3, delay_cycles_4): Ditto.
20259         (nopv, *nopv): Ditto.
20260         (sleep, *sleep): Ditto.
20261         (wdr, *wdr): Ditto.
20262
20263 2012-03-22  Richard Guenther  <rguenther@suse.de>
20264
20265         PR tree-optimization/52548
20266         * tree-ssa-pre.c (valid_in_sets): Remove handling of invalidation
20267         because of clobbers.
20268         (prune_clobbered_mems): New function.
20269         (compute_antic_aux): Use it to prune ANTIC_OUT.
20270         (compute_partial_antic_aux): Use it to prune PA_IN.
20271         (compute_avail): Only insert expressions into EXP_GEN that are not
20272         invalidated when translated up to the beginning of the block.
20273
20274 2012-03-22  Richard Guenther  <rguenther@suse.de>
20275
20276         PR tree-optimization/52638
20277         * tree-vect-stmts.c (vect_init_vector_1): New function, split
20278         out from ...
20279         (vect_init_vector): ... here.  Handle scalar vector inits.
20280         (vect_get_vec_def_for_operand): Adjust.
20281         (vectorizable_load): Likewise.
20282
20283 2012-03-22  Uros Bizjak  <ubizjak@gmail.com>
20284
20285         * config.gcc (alpha*-*-linux*): Add elfos.h to tm_file.
20286         (alpha*-*-freebsd*): Ditto.
20287         (alpha*-*-netbsd*): Ditto.
20288         (alpha*-*-openbsd*): Ditto.
20289         * config/alpha/elf.h (OBJECT_FORMAT_ELF): Remove.
20290         (DWARF2_DEBUGGING_INFO): Remove.
20291         (PREFERRED_DEBUGGING_TYPE): Remove.
20292         (ASM_FINAL_SPEC): Remove.
20293         (IDENT_ASM_OP): Remove.
20294         (ASM_OUTPUT_IDENT): Remove.
20295         (SKIP_ASM_OP): Remove.
20296         (ASM_OUTPUT_SKIP): Remove.
20297         (ALIGN_ASM_OP): Remove.
20298         (ASM_OUTPUT_BEFORE_CASE_LABEL): Remove.
20299         (ASM_OUTPUT_CASE_LABEL): Remove.
20300         (ASM_OUTPUT_EXTERNAL_LIBCALL): Remove.
20301         (COMMON_ASM_OP): Remove.
20302         (ASM_OUTPUT_ALIGNED_COMMON): Remove.
20303         (ASCII_DATA_ASM_OP): Remove.
20304         (READONLY_DATA_SECTION_ASM_OP): Remove.
20305         (INIT_SECTION_ASM_OP): Remove.
20306         (FINI_SECTION_ASM_OP): Remove.
20307         (ASM_SECTION_START_OP): Remove.
20308         (ASM_OUTPUT_SECTION_START_FILE): Remove.
20309         (TARGET_ASM_NAMED_SECTION): Remove.
20310         (TARGET_ASM_SELECT_SECTION): Remove.
20311         (MAKE_DECL_ONE_ONLY): Remove.
20312         (TYPE_ASM_OP): Remove.
20313         (SIZE_ASM_OP): Remove.
20314         (ASM_WEAKEN_LABEL): Remove.
20315         (TYPE_OPERAND_FMT): Remove.
20316         (ASM_DECLARE_RESULT): Remove.
20317         (ASM_DECLARE_OBJECT_NAME): Remove.
20318         (ASM_FINISH_DECLARE_OBJECT): Remove.
20319         (ELF_ASCII_ESCAPES): Remove.
20320         (ELF_STRING_LIMIT): Remove.
20321         (STRING_ASM_OP): Remove.
20322         (ASM_OUTPUT_EXTERNAL): Remove.
20323         (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Redefine to false.
20324         * config/alpha/alpha.h (PCC_BITFIELD_TYPE_MATTERS): Undefine
20325         before define.
20326         (ASM_DECLARE_FUNCTION_NAME): Ditto.
20327         (ASM_DECLARE_FUNCTION_SIZE): Ditto.
20328         (ASM_GENERATE_INTERNAL_LABEL): Ditto.
20329         (ASM_OUTPUT_SKIP): Ditto.
20330         (READONLY_DATA_SECTION_ASM_OP): Remove.
20331         (USER_LABEL_PREFIX): Remove.
20332         (ASM_OUTPUT_ASCII): Remove.
20333         (ASM_OUTPUT_CASE_LABEL): Remove.
20334         (NO_DOLLAR_IN_LABEL): Undefine.
20335
20336 2012-03-22  Richard Guenther  <rguenther@suse.de>
20337
20338         PR tree-optimization/52459
20339         * tree-ssa-pre.c (inhibit_phi_insertion): Do not inhibit
20340         PHI insertion for calls.
20341
20342 2012-03-21  Steven Bosscher  <steven@gcc.gnu.org>
20343
20344         * cse.c (invalidate_from_sets_and_clobbers, try_back_substitute_reg,
20345         find_sets_in_insn, canonicalize_insn): Split out from ...
20346         (cse_insn): ... here.
20347         (invalidate_from_clobbers): Take an insn instead of the pattern.
20348
20349 2012-03-21  Oleg Endo  <olegendo@gcc.gnu.org>
20350
20351         PR target/52479
20352         * config/sh/sh-protos.h (sh_fsca_df2int): Remove.
20353         * config/sh/sh.c (sh_fsca_df2int_rtx, sh_fsca_df2int): Remove.
20354         * config/sh/sh.md (sindf2, cosdf2): Remove.
20355
20356 2012-03-21  Kaz Kojima  <kkojima@gcc.gnu.org>
20357
20358         PR target/52642
20359         * config/sh/sh.c (sh_expand_prologue): Emit blockage at the end of
20360         prologue for unwinder and profiler.
20361
20362 2012-03-21  Andreas Tobler  <andreast@fgznet.ch>
20363
20364         * configure.ac (HAVE_LD_NO_DOT_SYMBOLS): Add powerpc64-*-freebsd*.
20365         Introduce emul_name to select the right linker emulation for
20366         powerpc64-*-freebsd*.
20367         * configure: Regenerate.
20368         * config.gcc: Add bits to support powerpc64-*-freebsd*.
20369         * config/rs6000/freebsd.h (POWERPC_FREEBSD): Define.
20370         * config/rs6000/freebsd64.h: New file.
20371         * config/rs6000/rs6000.c (rs6000_option_override_internal): Use
20372         POWERPC_FREEBSD.
20373         (rs6000_savres_strategy): Likewise.
20374         (rs6000_savres_routine_name): Likewise.
20375         (rs6000_elf_file_end): Likewise.
20376         * config/rs6000/t-freebsd64: New file.
20377         * config/rs6000/sysv4.h (SUBTARGET_OVERRIDE_OPTIONS): Set the
20378         rs6000_current_abi for 64-bit FreeBSD to ABI_AIX.
20379
20380         * config/rs6000/freebsd64.h: Remove duplicated entries from last
20381         commit.
20382         * config/rs6000/t-freebsd64: Likewise.
20383
20384 2012-03-21  Georg-Johann Lay  <avr@gjlay.de>
20385
20386         PR rtl-optimization/52543
20387         PR target/52461
20388         * config/avr/avr-protos.h (avr_load_lpm): New prototype.
20389         * config/avr/avr.c (avr_mode_dependent_address_p): New function.
20390         (TARGET_MODE_DEPENDENT_ADDRESS_P): New define.
20391         (avr_load_libgcc_p): Restrict to __flash loads.
20392         (avr_out_lpm): Only handle 1-byte loads from __flash.
20393         (avr_load_lpm): New function.
20394         (avr_find_unused_d_reg): Remove.
20395         (avr_out_lpm_no_lpmx): Remove.
20396         (adjust_insn_length): Handle ADJUST_LEN_LOAD_LPM.
20397         * config/avr/avr.md (unspec): Add UNSPEC_LPM.
20398         (load_<mode>_libgcc): Use UNSPEC_LPM instead of MEM.
20399         (load_<mode>, load_<mode>_clobber): New insns.
20400         (mov<mode>): For multi-byte move from non-generic
20401         16-bit address spaces: Expand to load_<mode> resp.
20402         load_<mode>_clobber.
20403         (load<mode>_libgcc): Remove expander.
20404         (split-lpmx): Remove split.
20405
20406 2012-03-21  Richard Earnshaw  <rearnsha@arm.com>
20407
20408         * neon.md (neon_vget_lanev2di): Use gen_lowpart and gen_highpart.
20409         * config/arm/neon.ml (Fixed_return_reg): Renamed to fixed_vector_reg.
20410         All callers changed.
20411         (Fixed_core_reg): New feature.
20412         (Vget_lane [sizes S64 and U64]): Add Fixed_core_reg.  Allow fmrrd in
20413         disassembly.
20414         * neon-testgen.ml: Handle Fixed_core_reg.
20415
20416 2012-03-21  Andrew Stubbs  <ams@codesourcery.com>
20417
20418         * config/arm/arm.c (thumb2_reorg): Add complete support
20419         for 16-bit instructions.
20420         * config/arm/thumb2.md: Delete obsolete flag-clobbering peepholes.
20421
20422 2012-03-21  Richard Guenther  <rguenther@suse.de>
20423
20424         PR tree-optimizer/52636
20425         * tree-vect-slp.c (vect_get_constant_vectors): Convert constants
20426         to the appropriate type.
20427
20428 2012-03-21  Richard Guenther  <rguenther@suse.de>
20429
20430         * Makefile.in (cfgexpand.o): Add $(REGS_H) and $(INTEGRATE_H)
20431         dependencies.
20432         * cfgexpand.c (gimple_expand_cfg): Fold in pass_init_function,
20433         pass_jump, pass_initial_value_sets and pass_unshare_all_rtl.
20434         * passes.c (init_optimization_passes): Remove pass_init_function,
20435         pass_jump, pass_initial_value_sets and pass_unshare_all_rtl.
20436         * tree-pass.h (pass_init_function): Remove.
20437         (pass_jump): Remove.
20438         (pass_initial_value_sets): Remove.
20439         (pass_unshare_all_rtl): Remove.
20440         * integrate.c (pass_initial_value_sets): Remove.
20441         * emit-rtl.c (pass_unshare_all_rtl): Remove.
20442         * tree.h (init_function_for_compilation): Remove.
20443         * function.c (init_function_for_compilation): Remove.
20444         (pass_init_function): Remove.
20445         * cfgcleanup.c (rest_of_handle_jump): Remove.
20446         (pass_jump): Remove.
20447
20448 2012-03-20  Jason Merrill  <jason@redhat.com>
20449
20450         * tree-streamer-in.c (streamer_alloc_tree): Call
20451         ggc_alloc_zone_cleared_tree_node instead of
20452         ggc_alloc_zone_cleared_tree_node_stat.
20453
20454 2012-03-20  Jonathan Wakely  <jwakely.gcc@gmail.com>
20455
20456         * doc/extend.texi (Template Instantiation): Remove anachronisms.
20457
20458 2012-03-20  Jakub Jelinek  <jakub@redhat.com>
20459
20460         PR target/52607
20461         * config/i386/i386.c (expand_vec_perm_vperm2f128): New function.
20462         (ix86_expand_vec_perm_const_1): Call it.
20463
20464         * config/i386/i386.c (vselect_insn): New variable.
20465         (init_vselect_insn): New function.
20466         (expand_vselect, expand_vselect_insn): Add testing_p argument.
20467         Call init_vselect_insn if vselect_insn is NULL.  Adjust
20468         PATTERN (vselect_insn), instead of creating a new insn each time,
20469         only emit a copy of it if not testing and recog has been successful.
20470         (expand_vec_perm_pshufb, expand_vec_perm_1,
20471         expand_vec_perm_pshuflw_pshufhw, expand_vec_perm_broadcast_1): Adjust
20472         callers.
20473
20474         PR target/52607
20475         * config/i386/i386.md ("isa" attribute): Add avx2 and noavx2.
20476         ("enabled" attribute): Handle avx2 and noavx2 isas.
20477         * config/i386/sse.md (avx2_vec_dupv8sf_1, avx2_pbroadcast<mode>_1):
20478         New insns.
20479         (vec_dup<mode>): Add avx2 =x,x alternative.
20480         (vec_dup<mode> splitter): Don't split if TARGET_AVX2.
20481         (*avx_vperm_broadcast_<mode>): Don't split V4DFmode if TARGET_AVX2.
20482         For TARGET_AVX2, V8SFmode and elt == 0 split into vbroadcastss.
20483         * config/i386/i386.c (expand_vec_perm_pshufb): Emit also vpermps
20484         for V8SFmode.
20485         (expand_vec_perm_1): For broadcasts, use avx2_pbroadcast<mode>_1
20486         if possible, handle also V8SFmode.
20487
20488 2012-03-20  Richard Earnshaw  <rearnsha@arm.com>
20489
20490         * arm/predicates.md (zero_operand, reg_or_zero_operand): New predicates.
20491         * arm/neon.md (neon_vceq<mode>, neon_vcge<mode>): Use
20492         reg_or_zero_operand predicate.
20493         (neon_vcle<mode>, neon_vclt<mode>): Use zero_operand predicate.
20494
20495 2012-03-20  Jakub Jelinek  <jakub@redhat.com>
20496
20497         * config/i386/i386.c (ix86_decompose_address) <case ZERO_EXTEND>:
20498         If operand isn't UNSPEC, return 0.
20499
20500 2012-03-20  Richard Guenther  <rguenther@suse.de>
20501
20502         * tree-pass.h (pass_rtl_eh): Remove.
20503         * except.c (gate_handle_eh): Likewise.
20504         (rest_of_handle_eh): Likewise.
20505         (pass_rtl_eh): Likewise.
20506         (finish_eh_generation): Export.
20507         * except.h (finish_eh_generation): Declare.
20508         * passes.c (init_optimization_passes): Remove pass_rtl_eh.
20509         * cfgexpand.c (gimple_expand_cfg): Call finish_eh_generation
20510         after expanding stack alignment.  Instead of compacting blocks
20511         call cleanup_cfg.
20512
20513 2012-03-20  Richard Guenther  <rguenther@suse.de>
20514
20515         * stor-layout.c (finish_bitfield_representative): Fallback
20516         to conservative maximum size if the padding up to the next
20517         field cannot be computed as a constant.
20518         (finish_bitfield_layout): If we cannot compute the distance
20519         between the start of the bitfield representative and the
20520         bitfield member start a new representative.
20521         * expr.c (get_bit_range): The distance between the start of
20522         the bitfield representative and the bitfield member is zero
20523         if the field offsets are not constants.
20524
20525 2012-03-20  Tristan Gingold  <gingold@adacore.com>
20526
20527         * tree.h (enum size_type_kind): Add stk_ prefix to constants,
20528         convert in lowercase.
20529         (sizetype_tab, sizetype, bitsizetype, ssizetype, sbitsizetype)
20530         (size_int, ssize_int, bitsize_int, sbitsize_int): Adjust.
20531         * stor-layout.c (sizetype_tab): Adjust.
20532         (initialize_sizetypes): Use SIZETYPE instead of SIZE_TYPE.
20533         * tree-streamer.c (preload_common_nodes): Use stk_type_kind_last
20534         instead of type_kind_last.
20535         * tree-scalar-evolution.c (interpret_rhs_expr): Use size_int
20536         instead of size_int_kind.
20537         * doc/tm.texi.in (Type Layout): Document SIZETYPE.
20538         * doc/tm.texi: Regenerate.
20539         * defaults.h (SIZETYPE): Provide a default value.
20540         * config/vms/vms.h (SIZE_TYPE): Define as "unsigned int".
20541         (SIZETYPE): Define.
20542
20543 2012-03-20  Oleg Endo  <olegendo@gcc.gnu.org>
20544
20545         * config/sh/sh.md: Use braced string notation where applicable.
20546
20547 2012-03-19  Uros Bizjak  <ubizjak@gmail.com>
20548
20549         * config/i386/i386.md (allocate_stack): Simplify.
20550
20551 2012-03-19  Uros Bizjak  <ubizjak@gmail.com>
20552
20553         * builtins.c (expand_builtin_cexpi): Use copy_addr_to_reg instead of
20554         copy_to_mode_reg (Pmode, ...).
20555         (expand_builtin_frame_address): Ditto.
20556         * expr.c (emit_block_move_via_libcall): Ditto.
20557         (set_storage_via_libcall): Ditto.
20558
20559         * config/i386/i386.c (ix86_expand_movmem): Ditto.
20560         (ix86_expand_setmem): Ditto.
20561         (ix86_trampoline_init): DItto.
20562         * config/i386/i386.md (cmpstrnsi): Ditto.
20563
20564 2012-03-19  Sandra Loosemore  <sandra@codesourcery.com>
20565
20566         * config/sh/sh.opt (madjust-unroll): Mark as ignored/obsolete.
20567         * config/sh/sh.h (TARGET_OPT_DEFAULT): Don't use MASK_ADJUST_UNROLL.
20568         * doc/invoke.texi (Option Summary): Remove -madjust-unroll.
20569         (SH Options): Likewise.
20570
20571 2012-03-19  Uros Bizjak  <ubizjak@gmail.com>
20572
20573         * config/i386/i386.c (get_thread_pointer): Add tp_mode argument.
20574         Generate ZERO_EXTEND in place if GET_MODE (tp) != tp_mode.
20575         (legitimize_tls_address) <TLS_MODEL_INITIAL_EXEC>: Always generate
20576         DImode UNSPEC_GOTNTPOFF references on TARGET_64BIT.
20577         (ix86_decompose_address): Allow zero extended UNSPEC_TP references.
20578
20579         Revert:
20580         2012-03-13  Uros Bizjak  <ubizjak@gmail.com>
20581
20582         * config/i386/i386.h (TARGET_TLS_INDIRECT_SEG_REFS): New.
20583         * config/i386/i386.c (ix86_decompose_address): Use
20584         TARGET_TLS_INDIRECT_SEG_REFS to prevent %fs:(%reg) addresses.
20585         (legitimize_tls_address): Use TARGET_TLS_INDIRECT_SEG_REFS to load
20586         thread pointer to a register.
20587
20588         Revert:
20589         2012-03-10  H.J. Lu  <hongjiu.lu@intel.com>
20590
20591         * config/i386/i386.c (ix86_decompose_address): Disallow fs:(reg)
20592         if Pmode != word_mode.
20593         (legitimize_tls_address): Call gen_tls_initial_exec_x32 if
20594         Pmode == SImode for TARGET_X32.
20595
20596         * config/i386/i386.md (UNSPEC_TLS_IE_X32): New.
20597         (tls_initial_exec_x32): Likewise.
20598
20599 2012-03-19  Oleg Endo  <olegendo@gcc.gnu.org>
20600
20601         PR target/50751
20602         * config/sh/sh.h (CONST_OK_FOR_K04, CONST_OK_FOR_K12, DISP_ADDR_P,
20603         DISP_ADDR_OFFSET): New macros.
20604         * config/sh/sh.c (sh_address_cost): Add SH2A special case.
20605         (sh_legitimate_index_p): Allow QImode displacements for non-SH2A.
20606         (sh_legitimize_address): Add QImode displacement handling.
20607         (sh_cannot_change_mode_class): Disallow GENERAL_REGS for SFmode
20608         vector subregs.
20609         (sh_secondary_reload): Add QImode displacement handling.
20610         * config/sh/predicates.md (movsrc_no_disp_mem_operand): New predicate.
20611         * config/sh/constraints.md (K04, Snd, Sdd): New constraints.
20612         * config/sh/sh.md (extendqisi2): Remove constraints from expander.
20613         (*extendqisi2_compact): Rename to *extendqisi2_compact_reg, restrict
20614         to register operands only.
20615         (*extendqisi2_compact_mem_disp, *extendqisi2_compact_snd): New insns.
20616         (extendqihi2): Change insn to expander.
20617         (*extendqihi2_compact_reg): New insn.
20618         (movqi_i, movqi): Replace with ...
20619         (movqi, *movqi_reg_reg, *movqi_store_mem_disp12,
20620         *movqi_load_mem_disp, *movqi_load_mem_disp): ... these.
20621         Add new peepholes for QImode displacement addressing.
20622
20623 2012-03-19  Paolo Carlini  <paolo.carlini@oracle.com>
20624
20625         PR c++/14710
20626         * doc/invoke.texi: Document -Wuseless-cast.
20627
20628 2012-03-19  Eric Botcazou  <ebotcazou@adacore.com>
20629
20630         * tree.def (REALPART_EXPR, IMAGPART_EXPR, VIEW_CONVERT_EXPR): Move.
20631         * tree.h (handled_component_p): Reorder cases.
20632         * dwarf2out.c (loc_list_for_address_of_addr_expr_of_indirect_ref): Do
20633         not initialize unsignedp.
20634         (loc_list_from_tree): Likewise.
20635         (fortran_common): Likewise.
20636         * simplify-rtx.c (delegitimize_mem_from_attrs): Likewise.
20637
20638 2012-03-19  Uros Bizjak  <ubizjak@gmail.com>
20639
20640         * config/i386/i386.c (ix86_expand_prologue) <CM_LARGE_PIC>: Use Pmode
20641         mode consistently.  Use ix86_gen_add3.  Assert that Pmode == DImode.
20642         (ix86_expand_split_stack_prologue): Use ix86_gen_add3.
20643         (ix86_split_long_move): Ditto.
20644         (legitimize_tls_address): Use ix86_gen_sub3.
20645         (construct_plt_address): Assert that Pmode == DImode.
20646
20647 2012-03-18  Uros Bizjak  <ubizjak@gmail.com>
20648
20649         * config/i386/i386.md: Remove empty predicates and/or constraints.
20650         * config/i386/sync.md: Ditto.
20651         * config/i386/sse.md: Ditto.
20652         * config/i386/mmx.md: Ditto.
20653         * config/i386/pentium.md: Ditto.
20654         * config/i386/athlon.md: Ditto.
20655
20656 2012-03-16  Richard Guenther  <rguenther@suse.de>
20657
20658         PR tree-optimization/52603
20659         * tree-vect-data-refs.c (vect_can_force_dr_alignment_p): Clarify
20660         comment.
20661
20662         Revert
20663         2012-03-14  Richard Guenther  <rguenther@suse.de>
20664
20665         PR tree-optimization/52571
20666         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Move
20667         flag_section_anchors check ...
20668         (vect_can_force_dr_alignment_p): ... here.
20669
20670 2012-03-16  Martin Jambor  <mjambor@suse.cz>
20671
20672         * expr.c (expand_expr_real_1): Handle misaligned scalar reads from
20673         memory through MEM_REFs by calling extract_bit_field.
20674
20675 2012-03-16  Richard Guenther  <rguenther@suse.de>
20676
20677         * fold-const.c (native_interpret_expr): Also support POINTER_TYPE
20678         and REFERENCE_TYPE interpretations.
20679         (can_native_interpret_type_p): New function.
20680         (fold_ternary_loc): Use native encode/interpret to fold
20681         BIT_FIELD_REFs of constants.
20682
20683 2012-03-16  Richard Guenther  <rguenther@suse.de>
20684
20685         PR middle-end/52584
20686         * fold-const.c (fold_ternary_loc): Fold vector typed BIT_FIELD_REFs
20687         of vector constants and constructors.
20688
20689 2012-03-16  Richard Guenther  <rguenther@suse.de>
20690
20691         * tree-vect-stmts.c (vect_get_vec_def_for_operand): Use
20692         VIEW_CONVERT_EXPR to convert constants.
20693         (vect_is_simple_use): Treat all constants as vec_constant_def.
20694
20695 2012-03-16  Richard Guenther  <rguenther@suse.de>
20696             Kai Tietz  <ktietz@redhat.com>
20697
20698         PR middle-end/48814
20699         * gimplify.c (gimplify_self_mod_expr): Evaluate postfix
20700         side-effects completely in the pre-queue and use a temporary
20701         for the result.
20702
20703 2012-03-16  Richard Guenther  <rguenther@suse.de>
20704
20705         * stor-layout.c (finish_bitfield_representative): Fall back
20706         to the conservative maximum size if we cannot compute the
20707         size of the tail padding.
20708
20709 2012-03-16  Tristan Gingold  <gingold@adacore.com>
20710
20711         * config/vms/vms.h (TARGET_OS_CPP_BUILTINS): Define
20712         __CRTL_VER and __VMS_VER.
20713         * config/vms/vms-protos.h: Declare vms_c_get_crtl_ver
20714         and vms_c_get_vms_ver.
20715         * config/vms/vms-c.c (vms_c_get_crtl_ver, vms_c_get_vms_ver): New
20716         functions.
20717         * config/alpha/vms.h (VMS_DEFAULT_CRTL_VER)
20718         (VMS_DEFAULT_VMS_VER): Define.
20719         * config/ia64/vms.h (VMS_DEFAULT_CRTL_VER)
20720         (VMS_DEFAULT_VMS_VER): Define.
20721
20722 2012-03-16  Richard Guenther  <rguenther@suse.de>
20723
20724         * tree-vect-loop.c (get_initial_def_for_induction): Use
20725         build_constructor directly.
20726         * tree-vect-stmts.c (vect_get_vec_def_for_operand): Use
20727         build_vector_from_val.
20728         * tree.c (build_vector_from_val): Avoid creating a constructor
20729         first when we want a constant vector.
20730
20731 2012-03-16  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
20732
20733         * doc/install.texi (Specific, *-*-solaris2*): Improve wording.
20734
20735 2012-03-16  Richard Guenther  <rguenther@suse.de>
20736
20737         * tree.h (TREE_VECTOR_CST_ELTS): Remove.
20738         (VECTOR_CST_NELTS, VECTOR_CST_ELTS, VECTOR_CST_ELT): New defines.
20739         (struct tree_vector): Remove elements member, add variable size
20740         elts array member.
20741         (build_vector_stat): Declare.
20742         (build_vector): Define in terms of build_vector_stat.
20743         * tree.c (build_vector): Rename to ...
20744         (build_vector_stat): ... this.  Take array of trees as parameter.
20745         (build_vector_from_ctor): Adjust.
20746         (integer_zerop, integer_onep, integer_all_onesp, iterative_hash_expr,
20747         initializer_zerop): Adjust.
20748         * cfgexpand.c (expand_debug_expr): Likewise.
20749         * expr.c (categorize_ctor_elements_1, expand_expr_real_1,
20750         const_vector_from_tree): Likewise.
20751         * fold-const.c (const_binop, operand_equal_p, native_encode_vector,
20752         native_interpret_vector, fold_unary_loc, vec_cst_ctor_to_array,
20753         fold_vec_perm, fold_binary_loc, fold_ternary_loc): Likewise.
20754         * tree-streamer-in.c (streamer_alloc_tree): Handle TS_VECTOR.
20755         (lto_input_ts_vector_tree_pointers): Adjust.
20756         * tree-streamer-out.c (streamer_write_tree_header): Handle TS_VECTOR.
20757         (write_ts_vector_tree_pointers): Adjust.
20758         * varasm.c (const_hash_1, compare_constant, copy_constant,
20759         output_constant): Adjust.
20760         * gimple-fold.c (gimple_fold_stmt_to_constant_1): Adjust.
20761         * print-tree.c (print_node): Adjust.
20762         * tree-pretty-print.c (dump_generic_node): Adjust.
20763         * tree-vect-generic.c (uniform_vector_p, vector_element,
20764         lower_vec_perm): Adjust.
20765         * tree-vect-loop.c (get_initial_def_for_reduction): Adjust.
20766         * tree-vect-slp.c (vect_get_constant_vectors,
20767         vect_transform_slp_perm_load): Adjust.
20768         * tree-vect-stmts.c (vect_gen_perm_mask): Adjust.
20769         * expmed.c (make_tree): Adjust.
20770         * config/i386/i386.c (ix86_expand_builtin): Adjust.
20771         * config/sparc/sparc.c (sparc_handle_vis_mul8x16): Adjust interface
20772         and implementation.
20773         (sparc_fold_builtin): Adjust.
20774
20775 2012-03-16  Tristan Gingold  <gingold@adacore.com>
20776
20777         * config.gcc (*-*-*vms*): Define use_gcc_stdint and tm_file.
20778         * config/vms/vms-stdint.h: New file.
20779
20780 2012-03-16  Tristan Gingold  <gingold@adacore.com>
20781
20782         * config.host (alpha64-dec-*vms*, alpha*-dec-*vms*)
20783         (ia64-hp-*vms*): Replaced by ...
20784         (*-*-*vms*): ... This new entry.
20785
20786 2012-03-15  Jakub Jelinek  <jakub@redhat.com>
20787
20788         PR target/52568
20789         * config/i386/i386.c (expand_vec_perm_vperm2f128_vblend): New function.
20790         (ix86_expand_vec_perm_const_1): Use it.
20791
20792         PR target/52568
20793         * config/i386/sse.md (UNSPEC_VPERMDF): Remove.
20794         (avx2_permv4df): Remove.
20795         (avx2_permv4di): Macroize into...
20796         (avx2_perm<mode>): ... this using VI8F_256 iterator.
20797         (avx2_permv4di_1): Macroize into...
20798         (avx2_perm<mode>_1): ... this using VI8F_256 iterator.
20799
20800 2012-03-15  Ulrich Weigand  <ulrich.weigand@linaro.org>
20801
20802         * combine.c (apply_distributive_law): Do not distribute SUBREG.
20803
20804 2012-03-15  Ira Rosen  <irar@il.ibm.com>
20805             Ulrich Weigand  <ulrich.weigand@linaro.org>
20806
20807         * tree-vect-patterns.c (widened_name_p): Rename to ...
20808         (type_conversion_p): ... this.  Add new argument to determine
20809         if it's a promotion or demotion operation.  Check for
20810         CONVERT_EXPR_CODE_P instead of NOP_EXPR.
20811         (vect_recog_dot_prod_pattern): Call type_conversion_p instead
20812         widened_name_p.
20813         (vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern,
20814         vect_operation_fits_smaller_type, vect_recog_widen_shift_pattern):
20815         Likewise.
20816         (vect_recog_mixed_size_cond_pattern): Likewise and allow
20817         non-constant then and else clauses.
20818
20819 2012-03-15  Ira Rosen  <irar@il.ibm.com>
20820             Ulrich Weigand  <ulrich.weigand@linaro.org>
20821
20822         * tree-vectorizer.h (vect_pattern_recog): Add new argument.
20823         * tree-vect-loop.c (vect_analyze_loop_2): Update call to
20824         vect_pattern_recog.
20825         * tree-vect-patterns.c (widened_name_p): Pass basic block
20826         info to vect_is_simple_use.
20827         (vect_recog_dot_prod_pattern): Fail for basic blocks.
20828         (vect_recog_widen_sum_pattern): Likewise.
20829         (vect_handle_widen_op_by_const): Support basic blocks.
20830         (vect_operation_fits_smaller_type,
20831         vect_recog_over_widening_pattern): Likewise.
20832         (vect_recog_vector_vector_shift_pattern): Support basic blocks.
20833         Update call to vect_is_simple_use.
20834         (vect_recog_mixed_size_cond_pattern): Support basic blocks.
20835         Add printing.
20836         (check_bool_pattern): Add an argument, update call to
20837         vect_is_simple_use and the recursive calls.
20838         (vect_recog_bool_pattern): Update relevant function calls.
20839         Add printing.
20840         (vect_mark_pattern_stmts): Update calls to new_stmt_vec_info.
20841         (vect_pattern_recog_1): Check for reduction only in loops.
20842         (vect_pattern_recog): Add new argument.  Support basic blocks.
20843         * tree-vect-stmts.c (vectorizable_conversion): Pass basic block
20844         info to vect_is_simple_use_1.
20845         * tree-vect-slp.c (vect_get_and_check_slp_defs): Support basic blocks.
20846         (vect_slp_analyze_bb_1): Call vect_pattern_recog.
20847
20848 2012-03-15  Jakub Jelinek  <jakub@redhat.com>
20849             Andrew Pinski  <apinski@cavium.com>
20850
20851         PR middle-end/52592
20852         * builtins.c (expand_builtin_int_roundingfn_2): If expanding
20853         BUILT_IN_IR{INT,OUND}* using optab fails, emit lr{int,ound}*
20854         calls instead of __builtin_ir{int,ound}*.
20855
20856 2012-03-15  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
20857
20858         * doc/sourcebuild.texi (cleanup-modules, keep-modules): Update
20859         documentation.
20860
20861 2012-03-15  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
20862
20863         * config.gcc (target_type_format_char): New. Document it. Set it for
20864         arm*-*-* .
20865         * configure.ac (gnu_unique_option): Use target_type_format_char
20866         in test.  Comment rationale.
20867         * configure: Regenerate .
20868
20869 2012-03-15  Jakub Jelinek  <jakub@redhat.com>
20870
20871         PR tree-optimization/52267
20872         * tree-vrp.c (masked_increment): New function.
20873         (register_edge_assert_for_2): Derive ASSERT_EXPRs
20874         from (X & CST1) cmp CST2 tests.
20875
20876 2012-03-15  Richard Guenther  <rguenther@suse.de>
20877
20878         PR middle-end/52580
20879         * tree-data-ref.c (subscript_dependence_tester_1): Check
20880         all dimensions for non-conflicting access functions.
20881
20882 2012-03-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
20883
20884         PR c++/44783
20885         * doc/invoke.texi [C++ Language Options]: Document
20886         -ftemplate-backtrace-limit.
20887
20888 2012-03-15  Tristan Gingold  <gingold@adacore.com>
20889
20890         * c-parser.c (c_parser_parameter_declaration): Handle #pragma
20891         before a parameter.
20892
20893 2012-03-15  Tristan Gingold  <gingold@adacore.com>
20894
20895         * dwarf2out.c (gen_subprogram_die): Require dwarf unwinding to
20896         use DW_OP_call_frame_cfa.
20897
20898 2012-03-14  H.J. Lu  <hongjiu.lu@intel.com>
20899
20900         PR target/50797
20901         * config/i386/i386-opts.h (pmode): New.
20902
20903         * config/i386/i386.c (ix86_option_override_internal): Properly
20904         check and set ix86_pmode.
20905
20906         * config/i386/i386.h (Pmode): Check ix86_pmode instead of TARGET_64BIT.
20907
20908         * config/i386/i386.opt (maddress-mode=): New.
20909
20910         * doc/invoke.texi: Document -maddress-mode=short|long for x86.
20911
20912 2012-03-14  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
20913
20914         * dwarf2cfi.c (def_cfa_0): Remove MIPS_DEBUGGING_INFO handling.
20915         (dwarf2out_do_cfi_asm): Likewise.
20916         * dwarf2out.c (output_call_frame_info): Remove MIPS_DEBUGGING_INFO
20917         handling.
20918         (add_data_member_location_attribute): Likewise.
20919         (gen_array_type_die): Likewise.
20920         (gen_subprogram_die): Likewise.
20921         (gen_producer_string): Likewise.
20922         * sdbout.c (sdbout_begin_prologue): Declare unconditionally.
20923         Remove MIPS_DEBUGGING_INFO handling.
20924         (sdb_debug_hooks): Likewise.
20925         (sdbout_begin_block): Likewise.
20926         (sdbout_end_block): Likewise.
20927         (sdbout_begin_prologue): Likewise.
20928         (sdbout_start_source_file): Likewise.
20929         (sdbout_end_source_file): Likewise.
20930         (sdbout_init): Likewise.
20931         * system.h (MIPS_DEBUGGING_INFO): Poison.
20932
20933 2012-03-14  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
20934
20935         * config/alpha/alpha.c [HAVE_STAMP_H]: Remove.
20936         (alpha_file_start) [MS_STAMP]: Remove.
20937
20938         * config/alpha/elf.h (TARGET_GAS): Remove.
20939         * config/alpha/freebsd.h (TARGET_DEFAULT): Remove.
20940         * config/alpha/linux.h (TARGET_DEFAULT): Remove.
20941         * config/alpha/netbsd.h (TARGET_DEFAULT): Remove.
20942         * config/alpha/vms.h (TARGET_DEFAULT): Remove.
20943         * config.gcc (alpha*-*-linux*): Remove target_cpu_default.
20944         (alpha*-*-freebsd*): Likewise.
20945         (alpha*-*-netbsd*): Likewise.
20946         (alpha*-*-openbsd*): Likewise.
20947         (alpha*-*-*): Remove target_cpu_default2.
20948         * config/alpha/alpha.c (alpha_output_filename): Remove !TARGET_GAS
20949         handling.
20950         * config/alpha/alpha.h (TARGET_AS_CAN_SUBTRACT_LABELS): Remove.
20951         (TARGET_AS_SLASH_BEFORE_SUFFIX): Remove.
20952         * config/alpha/alpha.c (print_operand): Always assume
20953         TARGET_AS_SLASH_BEFORE_SUFFIX.
20954         * config/alpha/alpha.md ("*builtin_setjmp_receiver_er_sl_1"):
20955         Remove TARGET_AS_CAN_SUBTRACT_LABELS.
20956         ("*builtin_setjmp_receiver_er_1"): Remove.
20957         * config/alpha/alpha.opt (malpha-as): Remove.
20958         (mgas): Ignore.
20959         * doc/invoke.texi (Option Summary, DEC Alpha Options): Remove
20960         -malpha-as, -mgas.
20961         Remove DEC Unix reference.
20962
20963         * config/alpha/alpha.h (OBJECT_FORMAT_COFF): Remove.
20964         (EXTENDED_COFF): Remove.
20965         * config/alpha/elf.h (OBJECT_FORMAT_COFF): Don't undef.
20966         (EXTENDED_COFF): Don't undef.
20967         * config/alpha/alpha.c (alpha_file_start): Always assume
20968         OBJECT_FORMAT_ELF.
20969         Don't set targetm.asm_file_start_file_directive.
20970         [!OBJECT_FORMAT_ELF]: Remove.
20971         (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Remove.
20972
20973         * config/alpha/alpha.h (SDB_DEBUGGING_INFO): Remove.
20974         (DBX_DEBUGGING_INFO): Remove.
20975         (MIPS_DEBUGGING_INFO): Remove.
20976         (PREFERRED_DEBUGGING_TYPE): Remove.
20977         (DBX_OUTPUT_SOURCE_LINE): Remove.
20978         (SDB_OUTPUT_SOURCE_LINE): Remove.
20979         (DBX_CONTIN_LENGTH): Remove.
20980         (NO_DBX_FUNCTION_END): Remove.
20981         (ASM_STABS_OP): Remove.
20982         (ASM_STABN_OP): Remove.
20983         (ASM_STABD_OP): Remove.
20984         (SDB_ALLOW_FORWARD_REFERENCES): Remove.
20985         (SDB_ALLOW_UNKNOWN_REFERENCES): Remove.
20986         (PUT_SDB_DEF): Remove.
20987         (PUT_SDB_PLAIN_DEF): Remove.
20988         (PUT_SDB_TYPE): Remove.
20989         (sdb_label_count): Remove.
20990         (PUT_SDB_BLOCK_START): Remove.
20991         (PUT_SDB_BLOCK_END): Remove.
20992         (PUT_SDB_FUNCTION_START): Remove.
20993         (PUT_SDB_FUNCTION_END): Remove.
20994         (PUT_SDB_EPILOGUE_END): Remove.
20995         * config/alpha/elf.h (SDB_DEBUGGING_INFO): Don't undef.
20996         (MIPS_DEBUGGING_INFO): Don't undef.
20997         (DBX_DEBUGGING_INFO): Don't undef.
20998         * config/alpha/vms.h (SDB_DEBUGGING_INFO): Don't undef.
20999         (MIPS_DEBUGGING_INFO): Don't undef.
21000         (DBX_DEBUGGING_INFO): Don't undef.
21001         * config/alpha/freebsd.h (DBX_CONTIN_CHAR): Remove.
21002         * config/alpha/alpha.c (alpha_option_override): Remove SDB_DEBUG
21003         handling.
21004         (alpha_start_function): Likewise.
21005         (sdb_label_count): Remove.
21006         (alpha_output_filename): Remove DBX_DEBUG handling.
21007         (alpha_file_start): Likewise.
21008
21009 2012-03-14  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
21010
21011         * config.gcc (enable_obsolete): Remove *-*-solaris2.8*.
21012         (*-*-solaris2.[0-8], *-*-solaris2.[0-8].*): Mark unsupported.
21013         (i[34567]86-*-solaris2*, x86_64-*-solaris2.1[0-9]*): Remove
21014         Solaris 8 support.
21015         * configure.ac (gcc_cv_ld_hidden): Remove *-*-solaris2.8*.
21016         (ld_tls_support): Remove Solaris 8 references.
21017         (lwp_dir, lwp_spec): Remove support for alternate thread library.
21018         * acinclude.m4 (gcc_cv_initfini_array): Remove *-*-solaris2.* tests.
21019         * configure: Regenerate.
21020         * config.in: Regenerate.
21021
21022         * config/sol2.h (LINK_SPEC): Remove LIB_THREAD_LDFLAGS_SPEC.
21023         * config/i386/sol2.h: Remove Solaris 8 references.
21024
21025         * doc/install.texi (Specific, i?86-*-solaris2.[89]): Rename to ...
21026         (i?86-*-solaris2.9): ... this.
21027         Remove Solaris 8 references.
21028         (Specific, *-*-solaris2*): Document Solaris 8 removal.
21029         Remove Solaris 8 references.
21030
21031 2012-03-14  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
21032
21033         * config.gcc (enable_obsolete): Remove mips-sgi-irix6.5.
21034         (mips-sgi-irix6.5*): Remove.
21035         * config.host (mips-sgi-irix*): Remove.
21036         * configure.ac (enable_fixed_point): Remove mips*-sgi-irix*.
21037         (set_have_as_tls): Remove *-*-irix6*.
21038         (gcc_cv_ld_static_dynamic): Remove mips-sgi-irix6*.
21039         * configure: Regenerate.
21040
21041         * config/mips/iris6.h: Remove.
21042         * config/mips/iris6.opt: Remove.
21043         * config/mips/t-irix6: Remove.
21044
21045         * config/mips/mips.h (TARGET_GPWORD): Remove IRIX 6 N64 handling.
21046         (TARGET_IRIX6): Remove.
21047         (TARGET_CPU_CPP_BUILTINS): Remove IRIX 6 handling.
21048         Don't define LANGUAGE_C, _LANGUAGE_C for Objective-C.
21049         * config/mips/mips.c (mips_build_builtin_va_list): Remove IRIX 6
21050         handling.
21051         (mips_file_start): Likewise.
21052         * config/mips/mips-protos.h (irix_asm_output_align): Remove.
21053
21054         * config/mips/driver-native.c [__sgi__]: Remove.
21055         (host_detect_local_cpu) [__sgi__]: Remove.
21056
21057         * config/mips/gnu-user.h: Remove iris5.h reference.
21058
21059         * config/mips/mips-modes.def: Remove IRIX 6 reference.
21060         * config/mips/gnu-user64.h (MIPS_TFMODE_FORMAT): Remove.
21061         * config/mips/mips.c (mips_option_override) [MIPS_TFMODE_FORMAT]:
21062         Remove.
21063
21064         * gcc.c (main): Move asm_debug initialization ...
21065         (asm_debug): ... here.
21066
21067         * ginclude/stddef.h (__STDDEF_H__): Don't define.
21068
21069         * defaults.h (LINK_ELIMINATE_DUPLICATE_LDIRECTORIES): Remove.
21070         * system.h (LINK_ELIMINATE_DUPLICATE_LDIRECTORIES): Poison.
21071         * collect2.c [LINK_ELIMINATE_DUPLICATE_LDIRECTORIES]: Remove.
21072         (main) [LINK_ELIMINATE_DUPLICATE_LDIRECTORIES]: Remove.
21073         [LINK_ELIMINATE_DUPLICATE_LDIRECTORIES] (is_in_args): Remove.
21074         * doc/tm.texi.in (Driver, LINK_ELIMINATE_DUPLICATE_LDIRECTORIES):
21075         Remove.
21076         * doc/tm.texi: Regenerate.
21077
21078         * doc/invoke.texi (Debugging Options, -gdwarf-<version>): Remove
21079         IRIX 6 reference.
21080         (MIPS Options, -march): Remove IRIX reference.
21081         * doc/install.texi (Binaries, SGI IRIX): Remove.
21082         (Specific, mips-sgi-irix6): Document IRIX 6.5 removal, remove rest
21083         of section.
21084         * doc/trouble.texi (Interoperation): Remove -lgl_s handling.
21085
21086 2012-03-14  Martin Jambor  <mjambor@suse.cz>
21087
21088         * expr.c (expand_assignment): Use expand_expr with EXPAND_WRITE
21089         when expanding MEM_REFs, MEM_TARGET_REFs and handled_component bases.
21090         (expand_expr_real_1): Do not handle misalignment if modifier is
21091         EXPAND_WRITE.
21092
21093 2012-03-14  Richard Guenther  <rguenther@suse.de>
21094
21095         PR middle-end/52584
21096         * tree-vect-generic.c (type_for_widest_vector_mode): Take
21097         element type instead of mode, use build_vector_type_for_mode
21098         instead of the langhook, build a vector of proper signedness.
21099         (expand_vector_operations_1): Adjust.
21100
21101 2012-03-14  Richard Guenther  <rguenther@suse.de>
21102
21103         PR middle-end/52582
21104         * gimple-fold.c (canonicalize_constructor_val): Make sure we have
21105         a cgraph node for a FUNCTION_DECL that comes from a constructor.
21106         (gimple_get_virt_method_for_binfo): Likewise.
21107
21108 2012-03-14  Richard Guenther  <rguenther@suse.de>
21109
21110         PR tree-optimization/52571
21111         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Move
21112         flag_section_anchors check ...
21113         (vect_can_force_dr_alignment_p): ... here.  Do not re-align
21114         DECL_COMMON variables.
21115
21116 2012-03-14  Richard Guenther  <rguenther@suse.de>
21117
21118         * tree.h (DECL_BIT_FIELD_REPRESENTATIVE): New define.
21119         * stor-layout.c (start_bitfield_representative): New function.
21120         (finish_bitfield_representative): Likewise.
21121         (finish_bitfield_layout): Likewise.
21122         (finish_record_layout): Call finish_bitfield_layout.
21123         * tree.c (free_lang_data_in_decl): Only free DECL_QUALIFIER
21124         for QUAL_UNION_TYPE fields.
21125         * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
21126         Stream DECL_BIT_FIELD_REPRESENTATIVE.
21127         * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
21128
21129         PR middle-end/52080
21130         PR middle-end/52097
21131         PR middle-end/48124
21132         * expr.c (get_bit_range): Unconditionally extract bitrange
21133         from DECL_BIT_FIELD_REPRESENTATIVE.
21134         (expand_assignment): Adjust call to get_bit_range.
21135
21136 2012-03-14  Richard Guenther  <rguenther@suse.de>
21137
21138         PR middle-end/52578
21139         * fold-const.c (fold_unary_loc): Fold (T1)(T2)x to (T1)x if
21140         the outermost conversion is a sign-change only.
21141         (fold_binary_loc): Disregard widening and sign-changing
21142         conversions when we determine if two variables are equal
21143         for reassociation.
21144         * tree-ssa-forwprop.c (combine_conversions): Fold (T1)(T2)x to
21145         (T1)x if the outermost conversion is a sign-change only.
21146
21147 2012-03-14  Uros Bizjak  <ubizjak@gmail.com>
21148
21149         Revert:
21150         2012-03-14  Uros Bizjak  <ubizjak@gmail.com>
21151
21152         * config/i386/predicates.md (constant_call_address_operand): Declare
21153         as special predicate.  Update all uses.
21154
21155 2012-03-13  Jakub Jelinek  <jakub@redhat.com>
21156
21157         PR c/52577
21158         * c-parser.c (c_parser_postfix_expression)
21159         <case RID_BUILTIN_SHUFFLE>: Call mark_exp_read on argument values.
21160
21161         * config/i386/smmintrin.h: Avoid /* within a comment.
21162         * config/i386/nmmintrin.h: Likewise.
21163
21164 2012-03-13  Uros Bizjak  <ubizjak@gmail.com>
21165
21166         * config/i386/i386.md (xbegin): Remove constraint from expander.
21167
21168 2012-03-13  Uros Bizjak  <ubizjak@gmail.com>
21169
21170         * config/i386/predicates.md (constant_call_address_operand): Declare
21171         as special predicate.  Update all uses.
21172         * config/i386/i386.md: Remove mode from constant_call_address_operand
21173         predicates.
21174         * config/i386/i386.c (ix86_output_call_insn): Call
21175         constant_call_address_operand with VOIDmode.
21176
21177 2012-03-13  Uros Bizjak  <ubizjak@gmail.com>
21178
21179         * config/i386/i386.c (ix86_decompose_address): Handle subregs of
21180         AND zero extended address correctly.
21181
21182 2012-03-13  Uros Bizjak  <ubizjak@gmail.com>
21183
21184         * config/i386/predicates.md (tls_symbolic_operand): Declare as
21185         special predicate.
21186         (tls_modbase_operand): Ditto.
21187         * config/i386/i386.md: Remove mode from tls_symbolic_operand and
21188         tls_modbase_operand predicates.
21189
21190 2012-03-13  Martin Jambor  <mjambor@suse.cz>
21191
21192         * expr.c (expand_assignment): Handle misaligned scalar writes to
21193         memory through top-level MEM_REFs by calling store_bit_field.
21194
21195 2012-03-13  Richard Guenther  <rguenther@suse.de>
21196
21197         PR middle-end/52134
21198         * fold-const.c (fold_binary_loc): Fold (X * Y) & -(1 << CST) to X * Y
21199         if Y is a constant multiple of 1 << CST.
21200
21201 2012-03-13  Georg-Johann Lay  <avr@gjlay.de>
21202
21203         PR target/52488
21204         * config/avr/avr.c (avr_prologue_setup_frame): Cut down stack
21205         offset (size) to a value the insns can deal with.
21206         (expand_epilogue): Ditto.
21207
21208 2012-03-13  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
21209
21210         * config/arm/neon.ml (ops): Fixup expected instructions for
21211         unsigned vector compares.
21212
21213 2012-03-13  Uros Bizjak  <ubizjak@gmail.com>
21214
21215         * config/i386/i386.c (ix86_decompose_address): Prevent %fs:(%reg)
21216         addresses only when %reg is not in word mode.
21217
21218 2012-03-13  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
21219
21220         * config/microblaze/microblaze.md: Fix typo.
21221         * tree-if-conv.c: Likewise.
21222         * tree-vect-patterns.c: Likewise.
21223
21224 2012-03-13  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
21225
21226         * config.gcc (extra_passes): Remove.
21227         * configure.ac (extra_passes): Don't substitute.
21228         * configure: Regenerate.
21229         * Makefile.in (EXTRA_PASSES): Remove.
21230         (GCC_PASSES): Remove $(EXTRA_PASSES).
21231         (MOSTLYCLEANFILES): Likewise.
21232         (native): Likewise.
21233         (install-common): Likewise.
21234
21235 2012-03-13  Uros Bizjak  <ubizjak@gmail.com>
21236
21237         * config/i386/i386.h (TARGET_TLS_INDIRECT_SEG_REFS): New.
21238         * config/i386/i386.c (ix86_decompose_address): Use
21239         TARGET_TLS_INDIRECT_SEG_REFS to prevent %fs:(%reg) addresses.
21240         (legitimize_tls_address): Use TARGET_TLS_INDIRECT_SEG_REFS to load
21241         thread pointer to a register.
21242
21243 2012-03-12  H.J. Lu  <hongjiu.lu@intel.com>
21244
21245         * config/i386/i386.md (*tls_global_dynamic_64_<mode>): Remove :P
21246         on tls_symbolic_operand.
21247         (tls_global_dynamic_64_<mode>): Likewise.
21248
21249 2012-03-12  Georg-Johann Lay  <avr@gjlay.de>
21250
21251         PR other/52545
21252         * output.h (SECTION_EXCLUDE, SECTION_MACH_DEP): Don't use
21253         SECTION_MACH_DEP reserved bits for SECTION_EXCLUDE.
21254
21255 2012-03-12  Georg-Johann Lay  <avr@gjlay.de>
21256
21257         PR target/52499
21258         * config/avr/avr.c (avr_mode_code_base_reg_class): Change return
21259         type from reg_class_t to enum reg_class.
21260         * config/avr/avr-protos.h (avr_mode_code_base_reg_class): Ditto.
21261
21262 2012-03-12  Andrew Pinski  <apinski@cavium.com>
21263
21264         * tree-ssa-phiopt.c (single_non_singleton_phi_for_edges): New function.
21265         (tree_ssa_phiopt_worker): Use single_non_singleton_phi_for_edges.
21266         (value_replacement): Likewise.
21267         (empty_block_p): Check also if the PHIs for the block are empty.
21268
21269 2012-03-12  Georg-Johann Lay  <avr@gjlay.de>
21270
21271         PR target/52148
21272         * config/avr/avr.c (avr_out_movmem): Fix typo in output template
21273         for the case ADDR_SPACE_FLASH and AVR_HAVE_LPMX introduced in
21274         r184615 from 2012-02-28.
21275
21276 2012-03-12  H.J. Lu  <hongjiu.lu@intel.com>
21277
21278         * config/i386/i386.c (ix86_gen_tls_global_dynamic_64): New.
21279         (ix86_gen_tls_local_dynamic_base_64): Likewise.
21280         (ix86_option_override_internal): Set ix86_gen_tls_global_dynamic_64
21281         and ix86_gen_tls_local_dynamic_base_64.
21282         (legitimize_tls_address): Use ix86_gen_tls_global_dynamic_64 and
21283         ix86_gen_tls_local_dynamic_base_64.
21284
21285         * config/i386/i386.md (*tls_global_dynamic_64): Renamed to ...
21286         (*tls_global_dynamic_64_<mode>): This.
21287         (tls_global_dynamic_64): Renamed to ...
21288         (tls_global_dynamic_64_<mode>): This.
21289         (*tls_local_dynamic_base_64): Renamed to ...
21290         (*tls_local_dynamic_base_64_<mode>): This.
21291         (tls_local_dynamic_base_64): Renamed to ...
21292         (tls_local_dynamic_base_64_<mode>): This.
21293
21294 2012-03-12  H.J. Lu  <hongjiu.lu@intel.com>
21295
21296         * config/i386/i386.c (ix86_option_override_internal): Properly
21297         set ix86_gen_leave and ix86_gen_monitor.  Check Pmode == DImode,
21298         instead of TARGET_64BIT, to set ix86_gen_add3, ix86_gen_sub3,
21299         ix86_gen_one_cmpl2, ix86_gen_andsp, ix86_gen_allocate_stack_worker,
21300         ix86_gen_adjust_stack_and_probe and ix86_gen_probe_stack_range.
21301
21302         * config/i386/sse.md (sse3_monitor64): Renamed to ...
21303         (sse3_monitor64_<mode>): This.
21304
21305 2012-03-12  Tristan Gingold  <gingold@adacore.com>
21306
21307         * config/ia64/ia64.c (ia64_function_arg_1): Move code around.
21308         (ia64_function_arg_advance): Ditto.
21309
21310 2012-03-12  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
21311
21312         * config.gcc (mips*-*-openbsd*): Remove.
21313         * config/mips/openbsd.h: Remove.
21314         * config/mips/sdb.h: Remove.
21315
21316         * config/mips/mips.h (SDB_OUTPUT_SOURCE_LINE): Remove.
21317         * config/mips/mips.c (sdb_label_count): Remove.
21318         (mips_debugger_offset): Remove #if 0 code.
21319         (mips_output_function_prologue) [SDB_DEBUGGING_INFO]: Remove.
21320         * config/mips/sde.h (SDB_DEBUGGING_INFO): Don't undef.
21321
21322 2012-03-12  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
21323
21324         * doc/install.texi (Specific, i?86-*-solaris2.[89]): Update
21325         binutils reference.
21326         (Specific, i?86-*-solaris2.10): Remove GCC 4.0 reference.
21327         Update binutils references.
21328         (Specific, *-*-solaris2*): Mention bundled GCC in Solaris 10 and 11.
21329         Update binutils reference.
21330         Update Sun as/GNU ld caveat.
21331         Document binutils largefile requirement for LTO plugin.
21332         Remove reference to alternate libpthread.
21333
21334 2012-03-12  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
21335
21336         * config.gcc (alpha*-dec-osf5.1*): Remove.
21337         * config.host (alpha*-dec-osf*): Remove.
21338         * configure.ac (*-*-osf*): Remove.
21339         (alpha*-dec-osf*): Remove.
21340         * configure: Regenerate.
21341
21342         * config/alpha/host-osf.c, config/alpha/osf5.h, config/alpha/osf5.opt,
21343         config/alpha/va_list.h, config/alpha/x-osf: Remove.
21344
21345         * config/alpha/alpha.h (TARGET_LD_BUGGY_LDGP): Remove.
21346         * config/alpha/alpha.c (struct machine_function): Update comment.
21347         (alpha_start_function): Remove Tru64 UNIX as handling for
21348         max_frame_size.
21349         * config/alpha/alpha.md ("exception_receiver"): Remove
21350         TARGET_LD_BUGGY_LDGP.
21351         ("*exception_receiver_2"): Likewise.
21352         * except.c (finish_eh_generation): Remove Tru64 reference.
21353         * ginclude/stdarg.h [_HIDDEN_VA_LIST]: Don't undef _VA_LIST.
21354         * system.h (TARGET_HANDLE_PRAGMA_EXTERN_PREFIX): Poison.
21355         * target.def (handle_pragma_extern_prefix): Remove.
21356
21357         * Makefile.in (mips-tfile.o-warn): Remove.
21358         (ALL_HOST_BACKEND_OBJS): Remove mips-tfile.o, mips-tdump.o.
21359         (mips-tfile, mips-tfile.o, mips-tdump, mips-tdump.o): Remove.
21360         * mips-tdump.c, mips-tfile.c: Remove.
21361
21362         * doc/extend.texi (Symbol-Renaming Pragmas): Remove #pragma
21363         extern_prefix.
21364         * doc/install.texi (Binaries): Remove Tru64 UNIX reference.
21365         (Specific, alpha*-dec-osf5.1): Note removal.
21366         * doc/tm.texi.in (Misc, TARGET_HANDLE_PRAGMA_EXTERN_PREFIX):
21367         Remove.
21368         * doc/tm.texi: Regenerate.
21369         * doc/trouble.texi (Cross-Compiler Problems): Remove.
21370
21371 2012-03-12  Richard Guenther  <rguenther@suse.de>
21372
21373         * config/arm/arm.c (neon_dereference_pointer): Do not call
21374         covert during RTL expansion.
21375
21376 2012-03-12  Tristan Gingold  <gingold@adacore.com>
21377
21378         * doc/invoke.texi (VMS Options): Merge Alpha/VMS and IA-64/VMS
21379         Options.  Mention -mpointer-size.
21380
21381 2012-03-12  Richard Guenther  <rguenther@suse.de>
21382
21383         * config/alpha/alpha.c (alpha_gimplify_va_arg): Use
21384         build_nonstandard_integer_type.
21385
21386 2012-03-12  Richard Guenther  <rguenther@suse.de>
21387
21388         * tree.c (signed_or_unsigned_type_for): Use
21389         build_nonstandard_integer_type.
21390         (signed_type_for): Adjust documentation.
21391         (unsigned_type_for): Likewise.
21392         * tree-pretty-print.c (dump_generic_node): Use standard names
21393         for non-standard integer types if available.
21394
21395 2012-03-12  Tristan Gingold  <gingold@adacore.com>
21396
21397         * config/vms/vms.opt: Add vms-opts.h header.
21398         (mmalloc64): Use flag_vms_malloc64 flag instead of MALLOC64
21399         target mask.
21400         (-mvms-return-codes): Document.
21401         (-mpointer-size): New option.
21402         (vms_pointer_size): Add enumeration.
21403         * config/vms/vms-opts.h: New file.
21404         * config/vms/vms.h (TARGET_OS_CPP_BUILTINS): Define
21405         __INITIAL_POINTER_SIZE.
21406         (POINTER_SIZE, SIZE_TYPE, PTRDIFF_TYPE): Adjust definition.
21407         (C_COMMON_OVERRIDE_OPTIONS): Define.
21408         (DWARF2_ADDR_SIZE): Define.
21409         * config/vms/vms.c (vms_patch_builtins): Adjust condition.
21410         * config/vms/vms-protos.h (vms_c_common_override_options):
21411         New prototype.
21412         * config/vms/vms-c.c (vms_pragma_pointer_size): Ignore pragma
21413         if -mno-pointer-size.
21414         (vms_c_common_override_options): New function.
21415         * config/ia64/vms.h (TARGET_DEFAULT): Remove MASK_MALLOC64.
21416         * config/alpha/vms.h (TARGET_DEFAULT): Remove MASK_MALLOC64.
21417         (MALLOC_ABI_ALIGNMENT): Use flag_vms_malloc64
21418         and flag_vms_pointer_size.
21419         (MASK_RETURN_ADDR): Set according to flag_vms_pointer_size.
21420         * config.gcc (*-*-*vms*): Define xm_file.
21421         (alpha*-dec-*vms*): Do not define xm_file.
21422         (alpha64-dec-*vms*): Remove.
21423         (ia64-hp-*vms*): Do not define xm_file.  Simplify tm_file
21424         and tmake_file.
21425
21426 2012-03-12  Jakub Jelinek  <jakub@redhat.com>
21427
21428         PR tree-optimization/51721
21429         * tree-vrp.c (register_edge_assert_for_2): Add asserts for unsvar
21430         if (int) unsvar cmp CST.
21431
21432 2012-03-12  Richard Guenther  <rguenther@suse.de>
21433
21434         * tree-sra.c (create_access_replacement): Only rename the replacement
21435         if we can rewrite it into SSA form.  Properly mark register typed
21436         replacements that we cannot rewrite with TREE_ADDRESSABLE.
21437         * tree-cfg.c (verify_expr): Fix BIT_FIELD_REF verification
21438         for aggregate or BLKmode results.
21439
21440 2012-03-12  Jakub Jelinek  <jakub@redhat.com>
21441
21442         PR tree-optimization/52533
21443         * tree-vrp.c (register_edge_assert_for_2): Use double_int
21444         type for mask, only handle shifts by non-zero in-range
21445         shift count, for LE_EXPR and GT_EXPR if new_val is
21446         maximum, don't add the assertion.
21447
21448 2012-02-12  Kirill Yukhin  <kirill.yukhin@intel.com>
21449
21450         * doc/invoke.texi: Document -mrtm option.
21451         * common/config/i386/i386-common.c (OPTION_MASK_ISA_RTM_SET): New.
21452         (OPTION_MASK_ISA_RTM_UNSET): Ditto.
21453         (ix86_handle_option): Handle OPT_mrtm.
21454         * config.gcc (i[34567]86-*-*): Add rtmintrin.h and
21455         xtestintrin.h.
21456         (x86_64-*-*): Ditto.
21457         * i386-builtin-types.def (INT_FTYPE_VOID): New.
21458         * config/i386/i386-c.c (ix86_target_macros_internal): Define
21459         __RTM__ if needed.
21460         (ix86_target_string): Define -mrtm option.
21461         (PTA_RTM): New.
21462         (ix86_option_override_internal): Extend "corei7-avx" with RTM option.
21463         Handle new option.
21464         (ix86_valid_target_attribute_inner_p): Add OPT_mrtm.
21465         (ix86_builtins): Add IX86_BUILTIN_XBEGIN, IX86_BUILTIN_XEND,
21466         IX86_BUILTIN_XTEST.
21467         (bdesc_special_args): Ditto.
21468         (ix86_init_mmx_sse_builtins): Add IX86_BUILTIN_XABORT.
21469         (ix86_expand_special_args_builtin): Handle new built-in type.
21470         (ix86_expand_builtin): Handle XABORT instruction.
21471         * config/i386/i386.h (TARGET_RTM): New.
21472         * config/i386/i386.md (UNSPECV_XBEGIN): New.
21473         (UNSPECV_XEND): Ditto.
21474         (UNSPECV_XABORT): Ditto.
21475         (UNSPECV_XTEST): Ditto.
21476         (xbegin): Ditto.
21477         (xbegin_1): Ditto.
21478         (xend): Ditto.
21479         (xabort): Ditto
21480         (xtest): Ditto.
21481         (xtest_1): Ditto.
21482         * config/i386/i386.opt (mrtm): New.
21483         * config/i386/immintrin.h: Include rtmintrin.h and xtestintrin.h.
21484         * config/i386/rtmintrin.h: New header.
21485         * config/i386/xtestintrin.h: Ditto.
21486
21487 2012-03-12  Tristan Gingold  <gingold@adacore.com>
21488
21489         * ginclude/stddef.h: Adjust previous patch.
21490         Use __VMS__ instead of VMS.
21491
21492 2012-03-12  Uros Bizjak  <ubizjak@gmail.com>
21493
21494         * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2):
21495         Also convert sequences with CC setting arithmetic instruction.
21496
21497 2012-03-11  Sandra Loosemore  <sandra@codesourcery.com>
21498
21499         * doc/invoke.texi (Option Summary): Move -no-integrated-cpp
21500         from C Language Options to Preprocessor Options.
21501         (C Dialect Options): Move -no-integrated-cpp documentation
21502         from here...
21503         (Preprocessor Options): ...to here.  Rewrite the description
21504         so it makes more sense, and remove discussion of merging front ends.
21505
21506 2012-03-11  H.J. Lu  <hongjiu.lu@intel.com>
21507
21508         * config/i386/i386.c (ix86_expand_movmem): Use word_mode for size
21509         needed for loop.
21510         (ix86_expand_setmem): Likewise.
21511
21512 2012-03-11  Uros Bizjak  <ubizjak@gmail.com>
21513
21514         * config/i386/i386.c (ix86_zero_extend_to_Pmode): Rewrite using
21515         convert_to_mode.
21516
21517 2012-03-11  H.J. Lu  <hongjiu.lu@intel.com>
21518
21519         * config/i386/i386.c (ix86_trampoline_init): Use movl for 64bit if
21520         ptr_mode == SImode.  Replace DImode with Pmode or ptr_mode.
21521
21522 2012-03-11  H.J. Lu  <hongjiu.lu@intel.com>
21523
21524         * config/i386/i386.c (x86_this_parameter): Replace DImode with Pmode.
21525
21526 2012-03-11  H.J. Lu  <hongjiu.lu@intel.com>
21527
21528         * config/i386/i386.md (lwp_slwpcb): Check Pmode instead of
21529         TARGET_64BIT.
21530
21531 2012-03-11  H.J. Lu  <hongjiu.lu@intel.com>
21532             Uros Bizjak  <ubizjak@gmail.com>
21533
21534         * config/i386/predicates.md (call_insn_operand): Allow
21535         constant_call_address_operand in Pmode only.
21536         (sibcall_insn_operand): Ditto.
21537         * config/i386/i386.md (*call): Use W mode iterator instead of P mode.
21538         (*call_vzeroupper): Ditto.
21539         (*sibcall): Ditto.
21540         (*sibcall_vzeroupper): Ditto.
21541         (*call_value): Ditto.
21542         (*call_value_vzeroupper): Ditto.
21543         (*sibcall_value): Ditto.
21544         (*sibcall_value_vzeroupper): Ditto.
21545         (*indirect_jump): Ditto.
21546         (*tablejump_1): Ditto.
21547         (indirect_jump): Convert memory address to word mode for TARGET_X32.
21548         (tablejump): Ditto.
21549         * config/i386/i386.c (ix86_expand_call): Convert indirect operands
21550         to word mode.
21551
21552 2012-03-11  Oleg Endo  <olegendo@gcc.gnu.org>
21553
21554         PR target/51244
21555         * config/sh/sh.md (movnegt): Expand into respective insns immediately.
21556         Use movrt_negc instead of negc pattern for non-SH2A.
21557         (*movnegt): Remove.
21558         (*movrt_negc, *negnegt, *movtt, *movt_qi): New insns and splits.
21559
21560 2012-03-10  H.J. Lu  <hongjiu.lu@intel.com>
21561
21562         * config/i386/i386.c (ix86_decompose_address): Disallow fs:(reg)
21563         if Pmode != word_mode.
21564         (legitimize_tls_address): Call gen_tls_initial_exec_x32 if
21565         Pmode == SImode for TARGET_X32.
21566
21567         * config/i386/i386.md (UNSPEC_TLS_IE_X32): New.
21568         (tls_initial_exec_x32): Likewise.
21569
21570 2012-03-10  Chung-Lin Tang  <cltang@codesourcery.com>
21571
21572         PR rtl-optimization/52528
21573         * combine.c (can_combine_p): Add setting of subst_low_luid
21574         before call to expand_field_assignment().
21575
21576 2012-03-09  Sandra Loosemore  <sandra@codesourcery.com>
21577
21578         * doc/invoke.texi: Use correct names/markup for "GCC", "GDB", "ld",
21579         and related program names.
21580
21581 2012-03-09  Sandra Loosemore  <sandra@codesourcery.com>
21582
21583         * doc/invoke.texi: Use correct names for "DWARF", "stabs", and "ELF".
21584
21585 2012-03-09  Uros Bizjak  <ubizjak@gmail.com>
21586
21587         PR target/52530
21588         * config/i386/i386.c (ix86_print_operand): Handle 'E' operand modifier.
21589         (ix86_print_operand_address): Handle UNSPEC_LEA_ADDR. Do not fallback
21590         to set code to 'q'.
21591         * config/i386/i386.md (UNSPEC_LEA_ADDR): New unspec.
21592         (*movdi_internal_rex64): Use %E operand modifier for lea.
21593         (*movsi_internal): Ditto.
21594         (*lea_1): Ditto.
21595         (*lea<mode>_2): Ditto.
21596         (*lea_{3,4,5,6}_zext): Ditto.
21597         (*tls_global_dynamic_32_gnu): Ditto.
21598         (*tls_global_dynamic_64): Ditto.
21599         (*tls_dynamic_gnu2_lea_32): Ditto.
21600         (*tls_dynamic_gnu2_lea_64): Ditto.
21601         (pro_epilogue_adjust_stack_<mode>_add): Ditto.
21602
21603 2012-03-09  Michael Meissner  <meissner@linux.vnet.ibm.com>
21604
21605         * config/rs6000/linux64.h (OPTION_TARGET_CPU_DEFAULT): Do not
21606         redefine to be NULL if the current bit-size is different from the
21607         configured bit-size.
21608
21609         * config/rs6000/rs6000.c (rs6000_option_override_internal): If the
21610         cpu is defaulted, use PROCESSOR_DEFAULT and PROCESSOR_DEFAULT64 to
21611         set the default tuning.  Add asserts to make sure the cpu and tune
21612         indexes are defined.  Fix tests for cpu/tune index to use >= 0 to
21613         test whether the index is set, instead of > 0.
21614         (rs6000_file_start): Do not reset the default cpu if the current
21615         bit-size is different from the configured bit-size.
21616
21617 2012-03-09  Tristan Gingold  <gingold@adacore.com>
21618
21619         * config/vms/vms-crtlmap.map: Add comments.
21620         Add entries needed to build Ada RTS.
21621
21622 2012-03-09  Tristan Gingold  <gingold@adacore.com>
21623
21624         * ginclude/stddef.h: Do not define __size_t on VMS.
21625
21626 2012-03-09  Tristan Gingold  <gingold@adacore.com>
21627
21628         * c-tree.h (c_default_pointer_mode): New variable.
21629         * c-decl.c (c_default_pointer_mode): New variable.
21630         (c_build_pointer_type): New function.
21631         (grokdeclarator): Call c_build_pointer_type instead
21632         of build_pointer_type.
21633
21634         * config/vms/vms-c.c: Include c-tree.h
21635         (saved_pointer_mode): New variable.
21636         (handle_pragma_pointer_size): New function.
21637         (vms_pragma_pointer_size, vms_pragma_required_pointer_size): Likewise.
21638         (vms_c_register_pragma): Register __pointer_size and
21639         __required_pointer_size pragmas.
21640
21641 2012-03-09  Tristan Gingold  <gingold@adacore.com>
21642
21643         * config/vms/vms-c.c (vms_construct_include_filename): New function.
21644         (vms_c_register_includes): Reference it.
21645
21646 2012-03-09  Andrew Pinski  <apinski@cavium.com>
21647
21648         PR middle-end/51988
21649         * tree-ssa-phiopt.c: Include tree-pretty-print.h for
21650         print_generic_expr.
21651         (tree_ssa_phiopt_worker): Go through all the PHIs for
21652         value_replacement instead of just the singleton one.
21653         (value_replacement): Change return type to int.  Return 0 instead of
21654         false.
21655         Allow the middle basic block to contain more than just the defining
21656         statement.
21657         Handle non empty middle basic blocks.
21658         * Makefile.in (tree-ssa-phiopt.o): Add tree-pretty-print.h.
21659
21660 2012-03-09  Jiangning Liu  <jiangning.liu@arm.com>
21661
21662         * tree-scalar-evolution (interpret_rhs_expr): generate chrec for
21663         array reference and component reference.
21664         (analyze_scalar_evolution_for_address_of): New.
21665
21666 2012-03-08  Jie Zhang  <jzhang918@gmail.com>
21667
21668         PR target/49862
21669         * config/bfin/bfin.c (hwloop_optimize): Fix unused variable warnings.
21670         (hwloop_pattern_reg): Fix set but not used warning.
21671         (bfin_reorg_loops): Remove unused parameter.
21672         (bfin_reorg): Update use of bfin_reorg_loops.
21673
21674 2012-03-08  H.J. Lu  <hongjiu.lu@intel.com>
21675
21676         * config/i386/i386.c (setup_incoming_varargs_64): Use word_mode
21677         with integer parameters in registers.
21678         (gen_push): Push register in word_mode instead of Pmode.
21679         (ix86_emit_save_regs): Likewise.
21680         (ix86_emit_save_regs_using_mov): Save integer registers in word_mode.
21681         (gen_pop): Pop register in word_mode instead of Pmode.
21682         (ix86_emit_restore_regs_using_pop): Likewise.
21683         (ix86_expand_prologue): Replace Pmode with word_mode for push
21684         immediate.  Use ix86_gen_pro_epilogue_adjust_stack.  Save and
21685         restore RAX and R10 in word_mode.
21686         (ix86_emit_restore_regs_using_mov): Restore integer registers
21687         in word_mode.
21688         (ix86_expand_split_stack_prologue): Save R10_REG and restore in
21689         word_mode.
21690         (ix86_split_to_parts): Use word_mode with PUT_MODE for push.
21691         (ix86_split_long_move): Likewise.
21692
21693         * config/i386/i386.md (W): New.
21694         (*push<mode>2_prologue): Replace :P with :W.
21695         (*pop<mode>1): Likewise.
21696         (*pop<mode>1_epilogue): Likewise.
21697         (push/pop peephole2): Use word_mode scratch registers.
21698
21699 2012-03-08  Uros Bizjak  <ubizjak@gmail.com>
21700
21701         * config/i386/predicates.md (indirect_branch_operand): Simplify.
21702
21703 2012-03-08  Georg-Johann Lay  <avr@gjlay.de>
21704
21705         * config/avr/avr.md (*addhi3, addhi3_clobber): Add "w" alternative
21706         for constants in [-63,63].
21707
21708 2012-03-08  Uros Bizjak  <ubizjak@gmail.com>
21709
21710         PR target/52530
21711         Revert:
21712         2012-03-04  H.J. Lu  <hongjiu.lu@intel.com>
21713
21714         * config/i386/i386.c (ix86_print_operand_address): Only handle
21715         zero-extended DImode addresses.
21716
21717 2012-03-08  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
21718
21719         * configure.ac (gcc_cv_as_ix86_tlsldmplt): Add label.
21720         * configure: Regenerate.
21721
21722 2012-03-08  Georg-Johann Lay  <avr@gjlay.de>
21723
21724         PR target/52496
21725         * config/avr/avr.c (avr_mem_clobber): New static function.
21726         (avr_expand_delay_cycles): Add memory clobber operand to
21727         delay_cycles_1, delay_cycles_2, delay_cycles_3, delay_cycles_4.
21728         * config/avr/avr.md (unspec): Add UNSPEC_MEMORY_BARRIER.
21729         (enable_interrupt, disable_interrupt): New expander.
21730         (nopv, sleep, wdr): New expanders.
21731         (delay_cycles_1): Add memory clobber.
21732         (delay_cycles_2): Add memory clobber.
21733         (delay_cycles_3): Add memory clobber.
21734         (delay_cycles_4): Add memory clobber.
21735         (cli_sei): New insn from former "enable_interrupt",
21736         "disable_interrupt" with memory clobber.
21737         (*wdt): New insn from former "wdt" with memory clobber.
21738         (*nopv): Similar, but for "nopv".
21739         (*sleep): Similar, but for "sleep".
21740
21741 2012-03-07  Oleg Endo  <olegendo@gcc.gnu.org>
21742             Kaz Kojima  <kkojima@gcc.gnu.org>
21743
21744         PR target/52503
21745         * config/sh/sh.opt (msoft-atomic): Use Var instead of Mask.
21746         * config/sh/linux.h (TARGET_DEFAULT): Remove MASK_SOFT_ATOMIC.
21747         (SUBTARGET_OVERRIDE_OPTIONS): Define.
21748
21749 2012-03-07  Uros Bizjak  <ubizjak@gmail.com>
21750
21751         * config/i386/predicates.md (x86_64_zext_general_operand): New.
21752         * config/i386/i386.md (*zero_extendsidi2_rex64): Change operand 1
21753         predicate to x86_64_zext_general_operand.  Accept "Z" constraint.
21754
21755 2012-03-07  Walter Lee  <walt@tilera.com>
21756
21757         * config/tilegx/tilegx.c (tilegx_expand_prologue): Don't generate
21758         REG_CFA_* notes for the stack pointer.
21759         (tilegx_expand_epilogue): Restore stack pointer by adjusting it by
21760         EH_RETURN_STACKADJ_RTX.
21761         * config/tilepro/tilepro.c (tilepro_expand_prologue): Don't
21762         generate REG_CFA_* notes for the stack pointer.
21763         (tilepro_expand_epilogue): Restore stack pointer by adjusting it
21764         by EH_RETURN_STACKADJ_RTX.
21765
21766 2012-03-07  Georg-Johann Lay  <avr@gjlay.de>
21767
21768         * doc/invoke.texi (AVR Built-in Macros): Correct condition for
21769         when __AVR_3_BYTE_PC__ is defined.
21770
21771 2012-03-07  Uros Bizjak  <ubizjak@gmail.com>
21772
21773         * config/i386/i386.c (ix86_print_operand_punct_valid_p): Add '^'.
21774         (ix86_print_operand): Handle '^'.
21775         * config/i386/i386.md (*strmovdi_rex_1): Macroize memory operands
21776         using P mode iterator.  Add %^ to asm template to conditionally emit
21777         addr32 prefix.
21778         (*rep_movdi_rex64): Ditto.
21779         (*strsetdi_rex_1): Ditto.
21780         (*rep_stosdi_rex64): Ditto.
21781         (*strmov{si,hi,qi}_1): Add %^ to asm template to
21782         conditionally emit addr32 prefix.
21783         (*rep_mov{si,qi}): Ditto.
21784         (*strset{si,hi,qi}): Ditto.
21785         (*rep_stos{si,qi}): Ditto.
21786         (*cmpstrnqi_nz_1): Ditto.
21787         (*cmpstrnqi_1): Ditto.
21788         (*strlenqi_1): Ditto.
21789
21790 2012-03-07  H.J. Lu  <hongjiu.lu@intel.com>
21791
21792         * config/i386/i386.c (function_value_64): Return pointers in
21793         word_mode instead of Pmode.
21794         (ix86_promote_function_mode): Likewise.
21795
21796 2012-03-07  Richard Guenther  <rguenther@suse.de>
21797
21798         * coverage.c (get_gcov_type): Use type_for_mode.
21799         (get_gcov_unsigned_t): Likewise.
21800         * expr.c (store_constructor): Use type_for_mode.
21801         (try_casesi): Likewise.
21802         * tree-ssa-loop-ivopts.c (add_standard_iv_candidates_for_size): Remove.
21803         (add_standard_iv_candidates): Use standard type trees.
21804         * dojump.c (do_jump): Remove dead code.
21805
21806 2012-03-07  Richard Guenther  <rguenther@suse.de>
21807
21808         * c-typeck.c (pointer_diff): Use c_common_type_for_size.
21809
21810 2012-03-07  Richard Guenther  <rguenther@suse.de>
21811
21812         * convert.c (strip_float_extensions): Move ...
21813         * tree.c (strip_float_extensions): ... here.
21814
21815 2012-03-07  Georg-Johann Lay  <avr@gjlay.de>
21816
21817         PR target/52484
21818         * config/avr/avr.md (xload<mode>_A): Add R22... to register footprint.
21819
21820 2012-03-07  Richard Guenther  <rguenther@suse.de>
21821
21822         * omp-low.c (extract_omp_for_data): Use signed_type_for.
21823         (expand_omp_for_generic): Likewise.
21824         (expand_omp_for_static_nochunk): Likewise.
21825         (expand_omp_for_static_chunk): Likewise.
21826         * tree-vect-stmts.c (vect_gen_perm_mask): Use type_for_mode.
21827         * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
21828         * tree-vect-loop-manip.c (vect_gen_niters_for_prolog_loop):
21829         Use unsigned_type_for.
21830         (vect_create_cond_for_align_checks): Use signed_type_for.
21831
21832 2012-03-07  Andrey Belevantsev  <abel@ispras.ru>
21833
21834         PR rtl-optimization/52203
21835         * sel-sched.c (estimate_insn_cost): New parameter pempty.  Adjust
21836         all callers to pass NULL except ...
21837         (reset_sched_cycles_in_current_ebb): ... here, save the value
21838         in new variable 'empty'.  Increase issue_rate only for
21839         non-empty insns.
21840
21841 2012-03-07  Ralf Corsépius  <ralf.corsepius@rtems.org>
21842
21843         PR target/51417
21844         * Makefile.in: Let install-gcc-ar depend on installdirs,
21845         gcc-ar$(exeext), gcc-nm$(exeext), gcc-ranlib$(exeext).
21846         Don't double canonicalize if cross-compiling.
21847
21848 2012-03-07  Georg-Johann Lay  <avr@gjlay.de>
21849
21850         PR target/52506
21851         * gcc/config/avr/avr.c (expand_epilogue): Fix order of restoration
21852         to: RAMPZ, RAMPY, RAMPX, RAMPD.
21853         (expand_prologue): Only clear RAMPZ if it has effect on RAM-read.
21854
21855 2012-03-07  Georg-Johann Lay  <avr@gjlay.de>
21856
21857         PR target/52505
21858         * config/avr/avr.c (avr_out_xload): Don't read unintentionally
21859         from RAM.
21860         * config/avr/avr.md (xload_8): Adjust insn length.
21861
21862 2012-03-07  Georg-Johann Lay  <avr@gjlay.de>
21863
21864         PR target/52461
21865         * gcc/config/avr/avr.c (avr_out_lpm): Clear RAMPZ after usage
21866         if RAMPZ affects reading from RAM.
21867
21868 2012-03-07  Richard Guenther  <rguenther@suse.de>
21869
21870         PR pch/52518
21871         PR pch/38987
21872         * doc/invoke.texi (Precompiled Headers): Remove sentence that
21873         suggests you can include PCHs from inside another header.
21874
21875 2012-03-07  Richard Sandiford  <rdsandiford@googlemail.com>
21876
21877         PR middle-end/52515
21878         * rtl.h (pc_rtx, cc0_rtx, ret_rtx, simple_return_rtx): Add GTY markers.
21879
21880 2012-03-07  Kai Tietz  <ktietz@redhat.com>
21881
21882         * doc/invoke.texi (fwritable-relocated-rdata): Document
21883         new Cygwin/MinGW target option.
21884         * config/i386/winnt.c (i386_pe_unique_section): Ignore
21885         reloc if flag -fwritable-relocated-rdata is not set.
21886         (i386_pe_section_type_flags): Likewise.
21887         * config/i386/cygming.opt (fwritable-relocated-rdata):
21888         Add new flag variable flag_writable_rel_rdata.
21889
21890 2012-03-07  Richard Guenther  <rguenther@suse.de>
21891
21892         * tree-ssa-math-opts.c (convert_mult_to_widen): Check actual
21893         precision against gimple constraints.
21894
21895 2012-03-06  Richard Sandiford  <rdsandiford@googlemail.com>
21896
21897         PR middle-end/52372
21898         * rtl.h (pc_rtx, ret_rtx, simple_return_rtx, cc0_rtx): Redefine as
21899         variables.
21900         (GR_PC, GR_CC0, GR_RETURN, GR_SIMPLE_RETURN): Delete.
21901         * emit-rtl.c (pc_rtx, ret_rtx, simple_return_rtx, cc0_rtx): New
21902         variables.
21903         (init_emit_regs): Move associated initialization to...
21904         (init_emit_once): ...here.
21905
21906 2012-03-06  Richard Henderson  <rth@redhat.com>
21907
21908         * config/m68k/m68k.h (ISA_HAS_TAS): New.
21909         * config/m68k/sync.md (atomic_test_and_set): Use it.
21910         (atomic_test_and_set_1): Likewise.
21911
21912 2012-03-06  Michael Meissner  <meissner@linux.vnet.ibm.com>
21913
21914         PR target/50310
21915         * config/rs6000/vector.md (vector_uneq<mode>): Add support for
21916         UNEQ, LTGT, ORDERED, and UNORDERED IEEE vector comparisons.
21917         (vector_ltgt<mode>): Likewise.
21918         (vector_ordered<mode>): Likewise.
21919         (vector_unordered<mode>): Likewise.
21920         * config/rs6000/rs6000.c (rs6000_emit_vector_compare_inner): Likewise.
21921
21922 2012-03-06  Aldy Hernandez  <aldyh@redhat.com>
21923
21924         * trans-mem.c: New typedef for tm_region_p.
21925         Define vector types for tm_region_p.
21926         (tm_region_init): Replace region_worklist to a vector called
21927         bb_regions.
21928
21929 2012-03-06  Richard Guenther  <rguenther@suse.de>
21930
21931         * fold-const.c (build_fold_addr_expr_with_type_loc): Fold
21932         MEM_REF with constant pointer operand.
21933
21934 2012-03-06  Richard Guenther  <rguenther@suse.de>
21935
21936         PR middle-end/52493
21937         * tree-ssa-alias.c (ptr_derefs_may_alias_p): Robustify.
21938
21939 2012-03-06  Tristan Gingold  <gingold@adacore.com>
21940
21941         * config/vms/vms-c.c (vms_pragma_nomember_alignment): Handle octaword.
21942         (external_model_kind): Improve documentation.
21943         (vms_pragma_extern_model): Handle relaxed_redef.
21944         (vms_c_register_pragma): Allow expansion for nomember_alignment.
21945
21946 2012-03-06  Georg-Johann Lay  <avr@gjlay.de>
21947
21948         * doc/invoke.texi (AVR Options): -mmcu=: Document the XMEGA cores.
21949         Explain RAMPD, RAMPX, RAMPDY, RAMPZ usage by avr-gcc.
21950         Some more notes on EIND usage and reorder EIND subsection.
21951
21952 2012-03-06  Tristan Gingold  <gingold@adacore.com>
21953
21954         * config/vms/vms.c (VMS_CRTL_LDBL): Rename from VMS_CRTL_PRNTF.
21955         * config/vms/vms-crtlmap.map: Rename PRNTF to LDBL.
21956
21957 2012-03-06  Tristan Gingold  <gingold@adacore.com>
21958
21959         * config/vms/t-vmsnative (version): Define.
21960         * config/vms/t-vms (STMP_FIXPROTO, STMP_FIXINC, version): Remove.
21961
21962 2012-03-06  Andrey Belevantsev  <abel@ispras.ru>
21963
21964         PR rtl-optimization/52250
21965         * sel-sched-ir.c (maybe_tidy_empty_bb): Try harder to find a bb
21966         to put note list into.  Unconditionally call move_bb_info.
21967         (move_bb_info): Do not assert the blocks being in the same region,
21968         just drop the note list if they are not.
21969
21970 2012-03-06  Oleg Endo  <olegendo@gcc.gnu.org>
21971
21972         PR target/51244
21973         * config/sh/sh.c (sh_expand_t_scc): Remove SH2A special case
21974         and use unified expansion logic.
21975         * config/sh/sh.md (xorsi3_movrt): Rename to movrt.  Move
21976         closer to the existing movt insn.
21977         (negc): Rename insn to *negc.  Add new expander.
21978         (movnegt): Use xor pattern for T bit negation.  Reserve helper
21979         constant for negc pattern.
21980         (*movnegt): New insn and splitter.
21981
21982 2012-03-05  Bernd Schmidt  <bernds@codesourcery.com>
21983
21984         * c-typeck.c (pointer_diff): Check for POINTER_PLUS_EXPR, not
21985         PLUS_EXPR.
21986
21987 2012-03-05  Richard Henderson  <rth@redhat.com>
21988
21989         * genemit.c (main): Include "target.h" in insn-emit.c.
21990         * Makefile.in (insn-emit.o): Depend on TARGET_H.
21991         * config/sh/sync.md (atomic_test_and_set): Reference
21992         targetm.atomic_test_and_set_trueval instead of
21993         TARGET_ATOMIC_TEST_AND_SET_TRUEVAL.
21994
21995 2012-03-05  Joern Rennecke  <joern.rennecke@embecosm.com>
21996
21997         * config/epiphany/epiphany.c (epiphany_function_value_regno_p):
21998         Make static.
21999
22000 2012-03-05  Steven Bosscher  <steven@gcc.gnu.org>
22001
22002         * langhooks.c (add_builtin_type): New function.
22003         * langhooks.h (add_builtin_type): Export it.
22004         * config/mep/mep.c (mep_init_builtins): Use it.
22005         * config/rs6000/rs6000.c (rs6000_init_builtins): Use it.
22006
22007 2012-03-05  Jakub Jelinek  <jakub@redhat.com>
22008
22009         PR debug/51902
22010         * tree.h (BLOCK_SAME_RANGE): Define.
22011         * function.c (block_fragments_nreverse): Clear BLOCK_SAME_RANGE
22012         if BLOCK_FRAGMENT_CHAIN is non-NULL, but has it cleared.
22013         Also clear BLOCK_SAME_RANGE if fragment chain's supercontext fragment
22014         isn't equal to supercontext fragment's fragment chain.
22015         Adjust BLOCK_SUPERCONTEXT to point to supercontext fragment's
22016         fragment origin.
22017         (blocks_nreverse_all): Likewise.
22018         (reorder_blocks_1): Compute BLOCK_SAME_RANGE bits.  Set
22019         BLOCK_SUPERCONTEXT to supercontext fragment instead of
22020         supercontext fragment's fragment origin.
22021         * dwarf2out.c (add_high_low_attributes): If stmt has the same
22022         range as its parent (or parents thereof etc.), use the parent's
22023         DW_AT_ranges value instead of creating a new .debug_ranges range.
22024
22025 2012-03-05  Richard Henderson  <rth@redhat.com>
22026
22027         PR tree-opt/52242
22028         Revert: 2011-11-26  Richard Henderson  <rth@redhat.com>
22029         * omp-low.c (expand_omp_atomic): Assume anything aligned to
22030         BIGGEST_ALIGNMENT is aligned.
22031
22032 2012-03-05  Richard Henderson  <rth@redhat.com>
22033
22034         * config/sh/sh.h (TARGET_ATOMIC_TEST_AND_SET_TRUEVAL): Move...
22035         * config/sh/sh.c: ... here.
22036
22037 2012-03-05  Richard Henderson  <rth@redhat.com>
22038
22039         PR target/52481
22040         * config/m68k/sync.md (atomic_test_and_set): Use expand_simple_unop
22041         instead of calling negqi2 directly.
22042
22043 2012-03-05  Aldy Hernandez  <aldyh@redhat.com>
22044
22045         PR middle-end/52463
22046         * trans-mem.c (tm_region_init): Use last_basic_block.
22047
22048 2012-03-05  Oleg Endo  <olegendo@gcc.gnu.org>
22049
22050         * config/sh/sh.h (TARGET_ATOMIC_TEST_AND_SET_TRUEVAL): New hook.
22051         * config/sh/sync.md (atomic_test_and_set): New expander.
22052         (tasb, atomic_test_and_set_soft): New insns.
22053         * config/sh/sh.opt (menable-tas): New option.
22054         * doc/invoke.texi (SH Options): Document it.
22055
22056 2012-03-05  Richard Guenther  <rguenther@suse.de>
22057
22058         * cfgloop.c (verify_loop_structure): Verify dominators before
22059         using them.
22060         * graphite-clast-to-gimple.c (graphite_verify): Do not verify
22061         dominators from here.
22062         * graphite-scop-detection.c (create_sese_edges): Likewise.
22063         * loop-doloop.c (doloop_optimize_loops): Likewise.
22064         * loop-init.c (loop_optimizer_init): Likewise.
22065         * loop-unroll.c (unroll_and_peel_loops): Likewise.
22066         * loop-unswitch.c (unswitch_loops): Likewise.
22067         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Likewise.
22068         * tree-parloops.c (parallelize_loops): Likewise.  Verify
22069         only when checking is enabled.
22070         * tree-loop-distribution.c (tree_loop_distribution): Likewise.
22071
22072 2012-03-05  Bernd Schmidt  <bernds@codesourcery.com>
22073
22074         * genautomata.c (parse_automata_opt): New static function.
22075         (initiate_automaton_gen): Remove all option handling code.  Remove
22076         argc argument.  All callers changed.
22077         (main): Call init_rtx_reader_args_cb with the new function as argument.
22078
22079 2012-03-05  Richard Guenther  <rguenther@suse.de>
22080
22081         * cfgexpand.c (gimple_expand_cfg): Free dominator info.
22082         * tree-if-conv.c (combine_blocks): Free post-dominator info
22083         after breaking it.
22084         * tree-parloops.c (create_parallel_loop): Free and re-compute
22085         dominator info after breaking it.
22086
22087 2012-03-05  Richard Guenther  <rguenther@suse.de>
22088
22089         PR middle-end/52353
22090         * optabs.h (trapv_unoptab_p): New function.
22091         (trapv_binoptab_p): Likewise.
22092         * optabs.c (expand_binop): Use emit_libcall_block_1 with
22093         a proper equiv_may_trap argument.
22094         (expand_unop): Likewise.
22095         (emit_libcall_block_1): Take extra argument whether the
22096         instruction may trap.  Renamed from ...
22097         (emit_libcall_block): ... this.  New wrapper.
22098
22099 2012-03-05  Jakub Jelinek  <jakub@redhat.com>
22100
22101         PR tree-optimization/51721
22102         * tree-vrp.c (register_edge_assert_for_2): If comparing
22103         lhs of right shift by constant with an integer constant,
22104         add ASSERT_EXPRs for the rhs1 of the right shift.
22105
22106         * cfgrtl.c (cfg_layout_merge_blocks): Cleanup.
22107
22108 2012-03-05  Richard Guenther  <rguenther@suse.de>
22109
22110         * tree.c (integer_zerop): Handle VECTOR_CSTs.
22111         (integer_onep): Likewise.
22112         (integer_all_onesp): Likewise.
22113
22114 2012-03-05  Georg-Johann Lay  <avr@gjlay.de>
22115
22116         * config/avr/avr.md (*umaddqihi4.2): New insn-and-split.
22117
22118 2012-03-04  H.J. Lu  <hongjiu.lu@intel.com>
22119
22120         * config/i386/i386.c (pro_epilogue_adjust_stack): Check Pmode
22121         instead of TARGET_64BIT.
22122
22123 2012-03-04  H.J. Lu  <hongjiu.lu@intel.com>
22124
22125         * config/i386/i386.c (ix86_expand_prologue): Check Pmode to set
22126         adjust_stack_insn.
22127
22128 2012-03-04  H.J. Lu  <hongjiu.lu@intel.com>
22129
22130         * config/i386/i386.c (ix86_print_operand_address): Only handle
22131         zero-extended DImode addresses.
22132
22133 2012-03-04  Uros Bizjak  <ubizjak@gmail.com>
22134
22135         * config/i386/i386.c (ix86_print_operand) <case '+'>: Declare
22136         taken and cputaken as bool.
22137
22138 2012-03-04  Uros Bizjak  <ubizjak@gmail.com>
22139
22140         * config/i386/constraints.md (Ya): New internal constraint.
22141         * config/i386/i386.md (zero_extendsidi2): Remove expansion.
22142         (*zero_extendsidi2_rex64): Add x,x alternative.
22143         (*zero_extendsidi2): Ditto.  Add o,0 alternative.
22144         Remove flags reg clobber.  Adjust corresponding splits.
22145         (zero_extend<mode>si2): Macroize expander from zero_extendhisi2 and
22146         zero_extendqisi2 expanders using SWI12 mode iterator.
22147         (zero_extend<mode>si2_and): Macroize insn from
22148         zero_extendhisi2_and and zero_extendqisi2_and.  Merge corresponding
22149         splitters.
22150         (*zero_extend<mode>si2):  Macroize insn from
22151         *zero_extendhisi2_movzbl and *zero_extendqisi2_movzbl.
22152         (*zero_extend*2_movzbl_and): Remove insn patterns.
22153         (zero_extendqihi2_and): Merge corresponding splitter.
22154         (*zero_extendqihi2): Rename from *zero_extendqihi2_movzbl.
22155         (*zero_extend*2_movzbl_and): Remove insn patterns.
22156         (*anddi_1): Split TYPE_IMOVX instructions.
22157         (*andsi_1): Use Ya for alternative 2.  Split TYPE_IMOVX instructions.
22158         (*andhi_1): Ditto.
22159         (and->zext splitter): Add splitter pattern.
22160         (zero extend with andsi3 splitter): Adjust zero_extend pattern.
22161
22162 2012-03-04  Sandra Loosemore  <sandra@codesourcery.com>
22163
22164         * doc/invoke.texi (C++ Dialect Options): Minor copy-edits to
22165         x86-specific text.
22166         (Debugging Options): Likewise.
22167         (Optimize Options): Likewise.
22168         (i386 and x86-64 Options): Discuss -march before -mtune, consistently
22169         with other architectures.  Use official processor names with correct
22170         spelling/capitalization.  Fix formatting and grammar issues.
22171         (i386 and x86-64 Windows Options): Similar cleanup here.
22172
22173 2012-03-03  Kaz Kojima  <kkojima@gcc.gnu.org>
22174
22175         * config/sh/sh.md (abssi2): Add TARGET_SH1 condition.
22176
22177 2012-03-03  Kaz Kojima  <kkojima@gcc.gnu.org>
22178
22179         * config/sh/sh.c (sh_dwarf_register_span): Don't apply
22180         DBX_REGISTER_NUMBER.
22181
22182 2012-03-03  Kaz Kojima  <kkojima@gcc.gnu.org>
22183
22184         * config/sh/sh.c (shiftcosts): Return MAX_COST when the first
22185         operand is CONST_INT.  Take COSTS_N_INSNS into account.
22186         (sh_rtx_costs): Don't apply COSTS_N_INSNS to the return value
22187         of shiftcosts.
22188
22189 2012-03-02  Richard Henderson  <rth@redhat.com>
22190
22191         * optabs.c (expand_atomic_test_and_set): Honor
22192         atomic_test_and_set_trueval even when atomic_test_and_set
22193         optab is not in use.
22194
22195 2012-03-02  Kaz Kojima  <kkojima@gcc.gnu.org>
22196
22197         PR target/48596
22198         PR target/48806
22199         * config/sh/sh.c (sh_register_move_cost): Increase cost between
22200         GENERAL_REGS and FP_REGS for SImode.
22201
22202 2012-03-02  Oleg Endo  <olegendo@gcc.gnu.org>
22203
22204         PR target/49486
22205         * config/sh/sh.md (negdi2): Add TARGET_SH1 condition.
22206         (absdi2): New expander.
22207         (*absdi2, *negabsdi2, negdi_cond): New insns and splits.
22208
22209 2012-03-02  Oleg Endo  <olegendo@gcc.gnu.org>
22210
22211         * config/sh/sync.md (atomic_exchange<mode>): New expander.
22212         (atomic_exchange<mode>_soft): New insn.
22213
22214 2012-03-02  Oleg Endo  <olegendo@gcc.gnu.org>
22215
22216         * config/sh/sync.md: Update copyright notice dates.
22217         (atomic_compare_and_swap<mode>): Use SImode for return value instead
22218         of QImode.
22219         (atomic_compare_and_swap<mode>_soft): Likewise.
22220
22221 2012-03-02  Oleg Endo  <olegendo@gcc.gnu.org>
22222
22223         PR target/31640
22224         * config/sh/sh.h (LOOP_ALIGN): Move logic to sh_loop_align.
22225         * config/sh/sh.c: Update copyright notice dates.
22226         (sh_loop_align): Add logic from LOOP_ALIGN.  Don't disable loop
22227         alignment for TARGET_HARD_SH4.
22228         (sh_option_override): Reduce default function alignment.  Set
22229         loop alignment to 4 bytes when not optimizing for size.
22230
22231 2012-03-02  Maxim Kuvyrkov  <maxim@codesourcery.com>
22232
22233         PR middle-end/50335
22234         * doc/invoke.texi (floop-flatten): Remove.
22235         * toplev.c (process_options): Remove references to flag_loop_flatten.
22236         * tree-ssa-loop.c (gate_graphite_transform): Same.
22237         * common.opt (floop-flatten): Obsolete.
22238         * graphite-poly.c (apply_poly_transforms): Remove reference to
22239         flag_loop_flatten.
22240         * Makefile.in (graphite-flattening.o): Remove.
22241         * graphite-flattening.c: Remove.
22242
22243 2012-03-02  Uros Bizjak  <ubizjak@gmail.com>
22244
22245         * compare-elim.c (find_comparisons_in_bb): Eliminate only compares
22246         having mode compatible with the mode of previous compare.  Substitute
22247         compare mode of previous compare with the mode, compatible
22248         with eliminated and previous compare.
22249
22250 2012-03-02  Peter Bergner  <bergner@vnet.ibm.com>
22251
22252         * config/rs6000/dfp.md (floatdidd2): New define_insn.
22253
22254 2012-03-02  Uros Bizjak  <ubizjak@gmail.com>
22255
22256         * config/i386/i386.c (ix86_cc_modes_compatible): Declare CCZmode
22257         compatible with CCGOCmode and CCGCmode.
22258
22259 2012-03-02  Peter Bergner  <bergner@vnet.ibm.com>
22260
22261         * config/rs6000/vsx.md (vsx_set_<mode>): Reorder operands.
22262
22263 2012-03-02  Ulrich Weigand  <ulrich.weigand@linaro.org>
22264
22265         * config/arm/arm.c (arm_sat_operator_match): New function.
22266         * config/arm/arm-protos.h (arm_sat_operator_match): Add prototype.
22267         * config/arm/arm.md ("insn" attribute): Add "sat" value.
22268         ("SAT", "SATrev"): New code iterators.
22269         ("SATlo", "SAThi"): New code iterator attributes.
22270         ("*satsi_<SAT:code>"): New pattern.
22271         ("*satsi_<SAT:code>_shift"): Likewise.
22272         * config/arm/arm-fixed.md ("arm_ssatsihi_shift"): Add "insn"
22273         and "shift" attributes.
22274         ("arm_usatsihi"): Add "insn" attribute.
22275         * config/arm/predicates.md (sat_shift_operator): Allow multiplication
22276         by powers of two.  Do not allow shift by 32.
22277
22278 2012-03-02  Uros Bizjak  <ubizjak@gmail.com>
22279
22280         PR target/46716
22281         * config/i386/i386.c (construct_container): Use gen_reg_or_parallel
22282         to pass the argument in the register of "natural" mode.
22283
22284 2012-03-02  Richard Guenther  <rguenther@suse.de>
22285
22286         PR tree-optimization/52406
22287         * tree-data-ref.h: Update documentation about DR_BASE_OBJECT.
22288         (struct indices): Add unconstrained_base member.
22289         (struct dr_alias): Remove unused vops member.
22290         (DR_UNCONSTRAINED_BASE): New define.
22291         * tree-data-ref.c (dr_analyze_indices): For COMPONENT_REFs
22292         add indices to allow their disambiguation.  Make DR_BASE_OBJECT
22293         be an artificial access that covers the whole indexed object,
22294         or mark it with DR_UNCONSTRAINED_BASE if we cannot do so.  Canonicalize
22295         plain decl base-objects to their MEM_REF variant.
22296         (dr_may_alias_p): When the base-object of either data reference
22297         has unknown size use only points-to information.
22298         (compute_affine_dependence): Make dumps easier to read and
22299         more verbose.
22300         * tree-vect-data-ref.c (vector_alignment_reachable_p): Use
22301         DR_REF when looking for packed references.
22302         (vect_supportable_dr_alignment): Likewise.
22303
22304 2012-03-02  Greta Yorsh  <Greta.Yorsh@arm.com>
22305
22306         * config/arm/arm-ldmstm.ml (write_ldm_commutative_peephole):
22307         Improve conditions for peepholes of loads followed by commutative
22308         operators.
22309         * config/arm/ldmstm.md: Regenerated.
22310
22311 2012-03-02  Richard Guenther  <rguenther@suse.de>
22312
22313         * BASE-VER: Set to 4.8.0.
22314
22315 2012-03-01  Richard Earnshaw  <rearnsha@arm.com>
22316
22317         * config.gcc (obsolete): Add all ARM targets using the FPA.
22318         (with_fpu): Obsolete selection of the FPA or Maverick on ARM.
22319         * doc/install.texi: Avoid references to obsolete ARM ports.
22320
22321 2012-03-01  Joern Rennecke  <joern.rennecke@embecosm.com>
22322
22323         * config/epiphany/epiphany.md (movmisalign<mode>): New patterns.
22324
22325 2012-03-01  Jeremy Bennett  <jeremy.bennett@embecosm.com>
22326             Joern Rennecke  <joern.rennecke@embecosm.com>
22327
22328         * doc/extend.texi: Expand and update information on interrupt
22329         attribute for Epiphany.
22330
22331 2012-03-01  Oleg Endo  <olegendo@gcc.gnu.org>
22332
22333         * config/sh/sh-protos.h: Update copyright notice dates.
22334         * config/sh/sh.h: Likewise.
22335         * config/sh/sh.md: Likewise.
22336         * config/sh/constraints.md: Likewise.
22337         * config/sh/predicates.md: Likewise.
22338
22339 2012-03-01  Oleg Endo  <olegendo@gcc.gnu.org>
22340
22341         * config/sh/sh-protos.h (tertiary_reload_operand): Remove dead function.
22342         * config/sh/sh.c (tertiary_reload_operand): Likewise.
22343
22344 2012-03-01  Oleg Endo  <olegendo@gcc.gnu.org>
22345
22346         * config/sh/constraints.md: Fix comment typo.
22347
22348 2012-03-01  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
22349
22350         PR target/52408
22351         * config/pa/pa.md (zvdep_imm32): Change type of variable x from int to
22352         unsigned HOST_WIDE_INT.
22353         (zvdep_imm64): Likewise.
22354         (vdepi_ior): Change type of variable x from int to HOST_WIDE_INT.
22355         (vdepi_and): Likewise.
22356         Likewise for unamed 64-bit patterns.
22357         * config/pa/predicates.md (lhs_lshift_cint_operand): Update comment.
22358
22359 2012-03-01  Alexandre Oliva  <aoliva@redhat.com>
22360
22361         PR debug/52001
22362         PR rtl-optimization/52417
22363         * cselib.c (cselib_any_perm_equivs): New variable.
22364         (cselib_reset_table): Check that it's not set when not
22365         preserving constants.
22366         (cselib_add_permanent_equiv): Set it.
22367         (cselib_have_permanent_equivalences): New.
22368         (cselib_init, cselib_finish): Reset it.
22369         * cselib.h (cselib_have_permanent_equivalences): Declare.
22370         * alias.c (get_addr): Restore earlier behavior when there
22371         aren't permanent equivalences.
22372
22373 2012-03-01  Steven Bosscher  <steven@gcc.gnu.org>
22374
22375         * config/mn10300/mn10300-modes.def: Fix copyright notice.
22376         * config/v850/v850-modes.def: Fix copyright notice.
22377
22378 2012-03-01  Georg-Johann Lay  <avr@gjlay.de>
22379
22380         * doc/extend.texi (AVR Built-in Functions): Document
22381         __builtin_avr_flash_segment.
22382
22383         * config/avr/builtins.def (__builtin_avr_flash_segment): New entry.
22384         * config/avr/avr.md (flash_segment, flash_segment1): New expanders.
22385         (*split.flash_segment): New insn-and-split.
22386         * config/avr/avr.c (avr_init_builtins): Add local variables:
22387         const_memx_void_node, const_memx_ptr_type_node,
22388         char_ftype_const_memx_ptr.
22389
22390 2012-03-01  Jakub Jelinek  <jakub@redhat.com>
22391
22392         PR tree-optimization/52445
22393         * tree-ssa-phiopt.c (struct name_to_bb): Remove ssa_name field,
22394         add ssa_name_ver, offset and size fields and change store field
22395         to bool.
22396         (name_to_bb_hash, name_to_bb_eq): Adjust for the above changes.
22397         (add_or_mark_expr): Likewise.  Only consider previous stores
22398         with the same size and offset.
22399         (nt_init_block): Only look at gimple_assign_single_p stmts,
22400         doesn't look at rhs2.
22401
22402 2012-03-01  Richard Guenther  <rguenther@suse.de>
22403
22404         PR middle-end/52443
22405         * tree-cfg.c (verify_gimple_assign_unary): Allow any
22406         conversions from integral types to pointer types.
22407
22408 2012-03-01  Georg-Johann Lay  <avr@gjlay.de>
22409
22410         * config/avr/avr-c.c (avr_cpu_cpp_builtins): Restore built-in
22411         defines for __UINT24_MAX__, __INT24_MAX__, __INT24_MIN__
22412         unintentionally removed in r184616.
22413
22414 2012-03-01  Venkataramanan Kumar  <venkataramanan.kumar@amd.com>
22415
22416         * doc/invoke.texi: Document AMD bdver2 and remove mentioning
22417         3DNow from bdver1.
22418
22419 2012-02-29  Jakub Jelinek  <jakub@redhat.com>
22420             Uros Bizjak  <ubizjak@gmail.com>
22421
22422         PR target/52437
22423         * config/i386/sse.md (vec_set<mode>_0): Swap "*r" and "fF"
22424         alternatives, add "e" constraint to the new last alternative
22425         and ! to last 3 alternatives.
22426
22427 2012-02-29  Eric Botcazou  <ebotcazou@adacore.com>
22428
22429         * dwarf2out.c (modified_type_die): Set DW_AT_GNAT_descriptive_type and
22430         DW_AT_artificial attributes at the end of the processing.
22431         (gen_array_type_die): Likewise.
22432         (gen_enumeration_type_die): Likewise.
22433         (gen_struct_or_union_type_die): Likewise.
22434         (add_gnat_descriptive_type_attribute): Do not suppress debug info for
22435         the parent type.
22436
22437 2012-02-29  Jakub Jelinek  <jakub@redhat.com>
22438
22439         PR middle-end/52419
22440         * expr.c (expand_assignment): If doing misaligned store that doesn't
22441         cover all mode bits, perform a RMW cycle.
22442
22443         PR tree-optimization/52429
22444         * tree-parloops.c (separate_decls_in_region_debug): Return early
22445         if var is LABEL_DECL.
22446
22447 2012-02-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
22448
22449         PR tree-optimization/52424
22450         * tree-ssa-dom.c (dom_opt_leave_block): Push a marker before
22451         calling dom_thread_across_edge.
22452
22453 2012-02-29  Georg-Johann Lay  <avr@gjlay.de>
22454
22455         * config/avr/avr.c: Move definition of TARGET macros to end of file.
22456
22457 2012-02-29  Georg-Johann Lay  <avr@gjlay.de>
22458
22459         * config/avr/avr-protos.h (avr_output_bld): Remove unused prototype.
22460         * config/avr/avr.c (avr_output_bld): Remove unused function.
22461         (avr_out_sbxx_branch): Use "%T" to print bit position.
22462
22463 2012-02-29  Georg-Johann Lay  <avr@gjlay.de>
22464
22465         * config/avr/avr.md: Untabify.
22466
22467 2012-02-29  Georg-Johann Lay  <avr@gjlay.de>
22468
22469         * config/avr/avr.md (eqne): New code iterator.
22470         (*dec-and-branchsi): Use it in text peephole's condition.
22471         (*dec-and-branchhi): Ditto.
22472         (*dec-and-branchqi): Ditto.
22473
22474 2012-02-29  Georg-Johann Lay  <avr@gjlay.de>
22475
22476         PR target/49939
22477         * config/avr/avr.h (ASM_SPEC): Add -mno-skip-bug if we know that
22478         the device does not have the skip-bug.
22479
22480 2012-02-29  Oleg Endo  <olegendo@gcc.gnu.org>
22481
22482         * doc/invoke.texi (-msoft-atomic): Add more detailed description.
22483         (-mbranch-cost, -mcbranchdi -mcmpeqdi -mfused-madd
22484         -mpretend-cmove): New.
22485
22486 2012-02-29  Jakub Jelinek  <jakub@redhat.com>
22487
22488         PR bootstrap/52397
22489         * df.h (struct df_d): Adjust comment that hard_regs_live_count
22490         doesn't count DEBUG_INSN refs.
22491         * df-scan.c (df_ref_create_structure): Don't set DF_HARD_REG_LIVE
22492         for DEBUG_INSN refs.
22493
22494 2012-02-28  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
22495
22496         Partially revert:
22497
22498         2012-02-20  Richard Guenther  <rguenther@suse.de>
22499         PR tree-optimization/52298
22500         * tree-vect-stmts.c (vectorizable_load): Properly use
22501         STMT_VINFO_DR_STEP instead of DR_STEP when vectorizing outer loops.
22502
22503 2012-02-28  Aldy Hernandez  <aldyh@redhat.com>
22504
22505         PR middle-end/51752
22506         * gimple.h (gimple_in_transaction): New.
22507         (gimple_set_in_transaction): New.
22508         (struct gimple_statement_base): Add in_transaction field.
22509         * tree-ssa-loop-im.c: (movement_possibility): Restrict movement of
22510         transaction loads.
22511         (tree_ssa_lim_initialize): Compute transaction bits.
22512         * tree.h (compute_transaction_bits): Protoize.
22513         * trans-mem.c (tm_region_init): Use the heap to store BB
22514         auxilliary data.
22515         (compute_transaction_bits): New.
22516
22517 2012-02-28  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
22518
22519         * gcc.c (display_help): Document --help=common and sort entries
22520         alphabetically.
22521
22522 2012-02-28  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
22523
22524         * doc/install.texi: Document check-$LANG specific shortcuts
22525
22526 2012-02-28  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
22527
22528         PR target/51534
22529         * config/arm/arm.c (neon_builtin_data): Add entries for vcgeu
22530         and vcgtu.
22531         * config/arm/arm_neon.h: Regenerate.
22532         * config/arm/neon.md (unspec): Add UNSPEC_VCGEU, and UNSPEC_VCGTU.
22533         (neon_vcgeu): New insn.
22534         (neon_vcgtu): Likewise.
22535         * config/arm/neon.ml (s_8_32, u_8_32): New lists.
22536         (ops): Unsigned comparison intrinsics call a different builtin.
22537
22538 2012-02-28  Richard Guenther  <rguenther@suse.de>
22539
22540         PR target/52407
22541         * config/i386/i386.c (ix86_expand_vector_set): Fix element
22542         ordering for the VEC_CONCAT for two element vectors for
22543         V2SFmode, V2SImode and V2DImode.
22544
22545 2012-02-28  Richard Earnshaw  <rearnsha@arm.com>
22546
22547         PR target/49448
22548         * config.gcc (arm*-*-linux*): Use an unambiguous pattern for
22549         detecting big-endian triplets.
22550
22551 2012-02-28  Richard Earnshaw  <rearnsha@arm.com>
22552
22553         * arm.c (aapcs_vfp_is_call_or_return_candidate): Only use the machine
22554         mode if there is no type information available.
22555
22556 2012-02-28  Thomas Koenig  <tkoenig@gcc.gnu.org>
22557
22558         PR tree-optimization/53207
22559         * doc/invoke.texi: Document as experimental and relying on graphite.
22560
22561 2012-02-28  Georg-Johann Lay  <avr@gjlay.de>
22562
22563         * config/avr/avr-devices.c (avr_mcu_type): Adjust NULL part
22564         of initializer to changes from r184614.
22565
22566 2012-02-28  Richard Guenther  <rguenther@suse.de>
22567
22568         PR tree-optimization/52395
22569         * tree-sra.c (build_ref_for_offset): Also look at the base
22570         TYPE_ALIGN when figuring out the alignment of the replacement.
22571
22572 2012-02-28  Richard Guenther  <rguenther@suse.de>
22573
22574         PR tree-optimization/52402
22575         * ipa-prop.c (ipa_modify_call_arguments): Properly use
22576         mis-aligned types when creating the accesses at the call site.
22577
22578 2012-02-28  Georg-Johann Lay  <avr@gjlay.de>
22579
22580         * config/avr/builtins.def: New file.
22581         * config/avr/t-avr (avr.o, avr-c.o): Depend on it.
22582         * config/avr/avr.c (enum avr_builtin_id): Use it.
22583         (avr_init_builtins): Use it. And use avr_bdesc.
22584         (bdesc_1arg): Remove.
22585         (bdesc_2arg): Remove.
22586         (bdesc_3arg): Remove.
22587         (struct avr_builtin_description): Add field n_args.
22588         (avr_bdesc): New static variable using builtins.def.
22589         (avr_expand_builtin): Use it.
22590         Don't call avr_expand_delay_cycles if op0 is not CONST_INT.
22591         (avr_fold_builtin): Fold AVR_BUILTIN_SWAP.
22592         Don't fold AVR_BUILTIN_INSERT_BITS if arg0 is not INTEGER_CST.
22593
22594 2012-02-28  Georg-Johann Lay  <avr@gjlay.de>
22595
22596         PR target/52148
22597         * config/avr/avr.md (movmem_<mode>): Replace match_operand that
22598         match only one single hard register with respective hard reg rtx.
22599         (movmemx_<mode>): Ditto.
22600         * config/avr/avr.c (avr_emit_movmemhi): Adapt expanding to new
22601         insn anatomy of movmem[x]_<mode>.
22602         (avr_out_movmem): Same for printing assembler and operand usage.
22603
22604 2012-02-28  Georg-Johann Lay  <avr@gjlay.de>
22605
22606         PR target/49868
22607         PR target/52261
22608         * doc/extend.texi (AVR Named Address Spaces): No more try to fix
22609         address spaces located outside of device flash.
22610
22611         * config/avr/avr.h (base_arch_s): Remove field n_segments.
22612         (mcu_type_s): Add field n_flash.
22613         * config/avr/avr-devices.c (avr_arch_types): Remove .n_segments.
22614         Set .have_elpm and .have_elpmx to 1 for avrxmega4 and avrxmega5.
22615         (AVR_MCU): Add N_FLASH argument.
22616         * config/avr/avr-mcus.def (AVR_MCU): Add initializer for .n_flash.
22617         * config/avr/avr-c.c (avr_cpu_cpp_builtins): Only define built-in
22618         macro __FLASH<n> if that address space makes sense for the device.
22619         * config/avr/avr.c (avr_out_lpm): Don't try to fix address spaces
22620         outside of target flash.
22621         (avr_asm_named_section): Ditto.
22622         (avr_asm_select_section): Ditto.
22623         (avr_addr_space_convert): Ditto.
22624         (avr_emit_movmemhi): Ditto.
22625         (avr_nonconst_pointer_addrspace, avr_pgm_check_var_decl): Error if
22626         address space is outside of device flash.
22627         (avr_insert_attributes): Ditto.
22628         (avr_xload_libgcc_p): Use avr_current_device->n_flash instead of
22629         avr_current_arch->n_segments.
22630
22631 2012-02-27  H.J. Lu  <hongjiu.lu@intel.com>
22632
22633         PR target/52352
22634         * config/i386/i386.md (*movabs<mode>_1): Enable only for TARGET_LP64.
22635         (*movabs<mode>_2): Likewise.
22636
22637 2012-02-27  Jakub Jelinek  <jakub@redhat.com>
22638
22639         PR target/52375
22640         * config/arm/neon.md (vashr<mode>3, vlshr<mode>3): Use
22641         s_register_operand in the test instead of REG_P.  Don't call
22642         gen_reg_rtx if it won't be used.
22643
22644         PR tree-optimization/52376
22645         * ipa-split.c (split_function): Ignore CLOBBER stmts.
22646
22647 2012-02-27  Stuart Henderson  <shenders@gcc.gnu.org>
22648
22649         * ifcvt.c (noce_get_condition): Check condition variable is not
22650         small_register_classes_for_mode_p before accepting.
22651
22652 2012-02-27  Uros Bizjak  <ubizjak@gmail.com>
22653
22654         * config/i386/i386.md (*movabs<mode>_1): Fix operand 1 constraints.
22655
22656 2012-02-27  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
22657
22658         Revert:
22659         2012-01-09  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
22660         * config/arm/arm-cores.def (cortex-a15): Use cortex_a15_tune for
22661         tuning parameters.
22662         * config/arm/arm.c (arm_cortex_a15_tune): New static variable.
22663
22664 2012-02-27  Oleg Endo  <olegendo@gcc.gnu.org>
22665
22666         * config/sh/sh.h: Delete dead GO_IF_LEGITIMATE_INDEX macro.
22667
22668 2012-02-26  Oleg Endo  <olegendo@gcc.gnu.org>
22669
22670         * config/sh/predicates.md: Remove blank lines.
22671         * config/sh/sh.c: Fix typos in comments.
22672         * config/sh/constraints.md: Likewise.
22673         * config/sh/sh.md: Remove blank lines.
22674         Fix typos in comments.  Use ;; as comment characters.
22675
22676 2012-02-26  Walter Lee  <walt@tilera.com>
22677
22678         * config/tilegx/tilegx.c (match_pcrel_step2): Fix instruction pattern.
22679         (replace_mov_pcrel_step2): Ditto.
22680
22681 2012-02-25  Alexandre Oliva  <aoliva@redhat.com>
22682
22683         PR debug/52001
22684         * alias.c (refs_newer_value_cb, refs_newer_value_p): New.
22685         (get_addr): Walk canonical value's locs.  Avoid returning VALUEs
22686         and locs that reference values newer than the non-canonical value
22687         at hand.  Return the canonical value as a worst case.
22688         (memrefs_conflict_p): Walk canonical value's locs.
22689
22690         PR debug/52001
22691         * cselib.c (preserve_only_constants): Rename to...
22692         (preserve_constants_and_equivs): ... this.  Split out...
22693         (invariant_or_equiv_p): ... this.  Preserve plus expressions
22694         of other preserved expressions too.
22695         (cselib_reset_table): Adjust.
22696         * var-tracking.c (reverse_op): Use canonical value to build
22697         reverse operation.
22698
22699 2012-02-23  Kai Tietz  <ktietz@redhat.com>
22700
22701         * config/i386/i386.c (ix86_delegitimize_address): Handle
22702         UNSPEC_PCREL plus displacement.
22703
22704 2012-02-24  Georg-Johann Lay  <avr@gjlay.de>
22705
22706         PR target/52261
22707         * config/avr/avr.c (avr_out_movhi_mr_r_xmega): Use base
22708         to test for unusedness in st X addressing.
22709
22710 2012-02-24  Richard Guenther  <rguenther@suse.de>
22711
22712         PR middle-end/52361
22713         * gimple.c (walk_gimple_op): Use predicates with less redundant tests.
22714         (is_gimple_reg_type): Move inline ...
22715         * gimple.h (is_gimple_reg_type): ... here.
22716
22717 2012-02-24  Richard Guenther  <rguenther@suse.de>
22718
22719         PR middle-end/52361
22720         * passes.c (execute_function_todo): When verifying SSA form
22721         verify gimple form first.
22722         * tree-ssa.c (verify_ssa): Do not verify gimple form here.
22723
22724 2012-02-24  Richard Guenther  <rguenther@suse.de>
22725
22726         PR middle-end/52355
22727         * fold-const.c (fold_addr_of_array_ref_difference): New function.
22728         (fold_binary_loc): Use it to extend the existing &a[i] - &a[j] folding.
22729
22730 2012-02-13  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
22731
22732         * tree-if-conv (predicate_scalar_phi): Commentary typo fix.
22733
22734 2012-02-23  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
22735
22736         * tree-phinodes.c (make_phi_node): Mark static.
22737         * tree-flow.h (make_phi_node): Remove extern decl.
22738         * doc/gimple.texi (make_phi_node): Remove documentation.
22739
22740 2012-02-23  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
22741
22742         * tree-into-ssa (update_ssa): Avoid trailing whitespace in dump_file.
22743         * tree-ssa-sccvn.c (print_scc): Ditto.
22744
22745 2012-02-23  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
22746
22747         * doc/passes.texi (Full redundancy elimination): Fix typo.
22748
22749 2012-02-23  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
22750
22751         * doc/invoke.texi (-fdse, -fdce): Remove duplicate entries.
22752
22753 2012-02-23  Eric Botcazou  <ebotcazou@adacore.com>
22754
22755         PR bootstrap/52287
22756         * haifa-sched.c (rank_for_schedule): Stabilize sort for debug insns.
22757
22758 2012-02-23  Uros Bizjak  <ubizjak@gmail.com>
22759
22760         PR c/52290
22761         * c-decl.c (start_function): Exit early if decl1 is not FUNTION_DECL.
22762
22763 2012-02-23  Georg-Johann Lay  <avr@gjlay.de>
22764
22765         * config/avr/avr.md (code_stdname): Add ior, xor.
22766         (xior): New code iterator.
22767         (*<code_stdname><mode>qi.byte0): Use xior instead of ior.
22768         (*<code_stdname><mode>qi.byte1-3): Ditto.
22769
22770 2012-02-23  Jakub Jelinek  <jakub@redhat.com>
22771
22772         PR tree-optimization/52019
22773         * ipa-split.c (find_return_bb, find_retval, visit_bb): Ignore
22774         CLOBBER stmts.
22775
22776 2012-02-23  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
22777
22778         * acinclude.m4: Use HAVE_INITFINI_ARRAY_SUPPORT instead of
22779         HAVE_INITFINI_ARRAY to work around namespace pollution in
22780         certain versions of newlib system headers.
22781         * config.in: Regenerate.
22782         * configure: Regenerate.
22783         * config/initfini-array.h: Use HAVE_INITFINI_ARRAY_SUPPORT
22784         instead of HAVE_INITFINI_ARRAY.
22785
22786 2012-02-22  Uros Bizjak  <ubizjak@gmail.com>
22787
22788         PR target/52330
22789         * config/i386/i386.c (ix86_print_operand) <case 'H'>: Error out if x
22790         is not offsettable memory reference.
22791
22792 2012-02-22  Georg-Johann Lay  <avr@gjlay.de>
22793
22794         PR target/18145
22795         * config/avr/avr.c (avr_asm_output_aligned_decl_common): Skip
22796         setting avr_need_clear_bss_p for __gnu_lto* symbols.
22797
22798 2012-02-22  Georg-Johann Lay  <avr@gjlay.de>
22799
22800         * config/avr/avr.h (avr_accumulate_outgoing_args): Return int.
22801         * config/avr/avr.c (avr_accumulate_outgoing_args): Return int.
22802
22803 2012-02-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
22804
22805         * configure.ac (LIB_TLS_SPEC): Enforce use of alternate thread
22806         library on Solaris 8 even without TLS support.
22807         * configure: Regenerate.
22808
22809 2012-02-22  Richard Guenther  <rguenther@suse.de>
22810
22811         PR middle-end/52329
22812         * gimple-fold.c (fold_stmt_1): Also canonicalize ADDR_EXPRs
22813         for GIMPLE_DEBUG stmts.
22814
22815 2012-02-22  Martin Jambor  <mjambor@suse.cz>
22816
22817         PR middle-end/51782
22818         * emit-rtl.c (set_mem_attributes_minus_bitpos): Set address space
22819         according to the base object.
22820
22821 2012-02-22  Georg-Johann Lay  <avr@gjlay.de>
22822
22823         PR rtl-optimization/50063
22824         * config/avr/avr.md (movhi_sp_r): Handle -1 (unknown IRQ state)
22825         and 2 (8-bit SP) in operand 2.
22826         * config/avr/avr.c (avr_prologue_setup_frame): Adjust prologue
22827         setup to use movhi_sp_r instead of vanilla move to write SP.
22828         Adjust REG_CFA notes to superseed unspec.
22829         (expand_epilogue): Adjust epilogue setup to use movhi_sp_r instead
22830         of vanilla move.
22831         As function body might contain CLI or SEI: Use irq_state 0 (IRQ
22832         known to be off) only with TARGET_NO_INTERRUPTS. Never use
22833         irq_state 1 (IRQ known to be on) here.
22834
22835 2012-02-21  Bernd Schmidt  <bernds@codesourcery.com>
22836
22837         * ira.c (check_allocation): Use REG_WORDS_BIG_ENDIAN, not
22838         WORDS_BIG_ENDIAN.
22839         * ira-color.c (setup_profitable_hard_regs, check_hard_reg_p,
22840         assign_hard_reg): Likewise.
22841
22842 2012-02-21  Georg-Johann Lay  <avr@gjlay.de>
22843
22844         * config/avr/avr.md (neghi2): Remove "!d,0" alternative. Tweak "r,0".
22845
22846 2012-02-21  Georg-Johann Lay  <avr@gjlay.de>
22847
22848         * config/avr/avr.md
22849         (*dec-and-branchhi!=-1.d.clobber): New text peephole.
22850         (*dec-and-branchhi!=-1.l.clobber): New text peephole.
22851
22852 2012-02-21  Georg-Johann Lay  <avr@gjlay.de>
22853
22854         * config/avr/avr-protos.h (avr_accumulate_outgoing_args): Move
22855         prototype from here to...
22856         * config/avr/avr.h: ...here.
22857
22858 2012-02-21  Richard Earnshaw  <rearnsha@arm.com>
22859
22860         PR target/52294
22861         * thumb2.md (thumb2_shiftsi3_short): Split register and
22862         immediate shifts.  For register shifts tie operands 0 and 1.
22863         (peephole2 for above): Check that register-controlled shifts
22864         have suitably tied operands.
22865
22866 2012-02-21  Quentin Neill  <quentin.neill@amd.com>
22867
22868         PR target/52137
22869         * config/i386/bdver1.md (bdver1_call, bdver1_push,
22870         bdver1_pop, bdver1_leave, bdver1_lea, bdver1_imul_DI, bdver1_imul,
22871         bdver1_imul_mem_DI, bdver1_imul_mem, bdver1_idiv, bdver1_idiv_mem,
22872         bdver1_str, bdver1_idirect, bdver1_ivector, bdver1_idirect_loadmov,
22873         bdver1_idirect_load, bdver1_ivector_load, bdver1_idirect_movstore,
22874         bdver1_idirect_both, bdver1_ivector_both, bdver1_idirect_store,
22875         bdver1_ivector_store, bdver1_fldxf, bdver1_fld, bdver1_fstxf,
22876         bdver1_fst, bdver1_fist, bdver1_fmov_bdver1, bdver1_fadd_load,
22877         bdver1_fadd, bdver1_fmul_load, bdver1_fmul, bdver1_fsgn,
22878         bdver1_fdiv_load, bdver1_fdiv, bdver1_fpspc_load, bdver1_fpspc,
22879         bdver1_fcmov_load, bdver1_fcmov, bdver1_fcomi_load,
22880         bdver1_fcomi, bdver1_fcom_load, bdver1_fcom,
22881         bdver1_fxch, bdver1_ssevector_avx128_unaligned_load,
22882         bdver1_ssevector_avx256_unaligned_load,
22883         bdver1_ssevector_sse128_unaligned_load,
22884         bdver1_ssevector_avx128_load, bdver1_ssevector_avx256_load,
22885         bdver1_ssevector_sse128_load, bdver1_ssescalar_movq_load,
22886         bdver1_ssescalar_vmovss_load, bdver1_ssescalar_sse128_load,
22887         bdver1_mmxsse_load, bdver1_sse_store_avx256, bdver1_sse_store,
22888         bdver1_mmxsse_store_short, bdver1_ssevector_avx256,
22889         bdver1_movss_movsd, bdver1_mmxssemov, bdver1_sselog_load_256,
22890         bdver1_sselog_256, bdver1_sselog_load, bdver1_sselog,
22891         bdver1_ssecmp_load, bdver1_ssecmp, bdver1_ssecomi_load,
22892         bdver1_ssecomi, bdver1_vcvtX2Y_avx256_load, bdver1_vcvtX2Y_avx256,
22893         bdver1_ssecvt_cvtss2sd_load, bdver1_ssecvt_cvtss2sd,
22894         bdver1_sseicvt_cvtsi2sd_load, bdver1_sseicvt_cvtsi2sd,
22895         bdver1_ssecvt_cvtpd2ps_load, bdver1_ssecvt_cvtpd2ps,
22896         bdver1_ssecvt_cvtdq2ps_load, bdver1_ssecvt_cvtdq2ps,
22897         bdver1_ssecvt_cvtdq2pd_load, bdver1_ssecvt_cvtdq2pd,
22898         bdver1_ssecvt_cvtps2pd_load, bdver1_ssecvt_cvtps2pd,
22899         bdver1_ssecvt_cvtsX2si_load, bdver1_ssecvt_cvtsX2si,
22900         bdver1_ssecvt_cvtpd2pi_load, bdver1_ssecvt_cvtpd2pi,
22901         bdver1_ssecvt_cvtpd2dq_load, bdver1_ssecvt_cvtpd2dq,
22902         bdver1_ssecvt_cvtps2pi_load, bdver1_ssecvt_cvtps2pi,
22903         bdver1_ssemuladd_load_256, bdver1_ssemuladd_256,
22904         bdver1_ssemuladd_load, bdver1_ssemuladd, bdver1_sseimul_load,
22905         bdver1_sseimul, bdver1_sseiadd_load, bdver1_sseiadd,
22906         bdver1_ssediv_double_load_256, bdver1_ssediv_double_256,
22907         bdver1_ssediv_single_load_256, bdver1_ssediv_single_256,
22908         bdver1_ssediv_double_load, bdver1_ssediv_double,
22909         bdver1_ssediv_single_load, bdver1_ssediv_single, bdver1_sseins):
22910         Add "bdver2" attribute.
22911
22912 2012-02-21  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
22913
22914         * config/s390/s390.c (s390_option_override): Make -mhard-dfp the
22915         default if possible and not specified otherwise.
22916
22917 2012-02-21  Richard Guenther  <rguenther@suse.de>
22918
22919         PR middle-end/52314
22920         * gimplify.c (create_tmp_from_val): Use the main variant type
22921         for the type of the temporary we create.
22922
22923 2012-02-21  Richard Guenther  <rguenther@suse.de>
22924
22925         PR tree-optimization/52324
22926         * gimplify.c (gimplify_expr): When re-gimplifying expressions
22927         do not gimplify a MEM_REF address operand if it is already
22928         in suitable form.
22929
22930 2012-02-21  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
22931
22932         * config/s390/s390.md ("fixuns_trunc<mode>si2"): Replace
22933         TARGET_HARD_FLOAT with TARGET_HARD_DFP.
22934
22935 2012-02-21  Richard Guenther  <rguenther@suse.de>
22936
22937         * tree-vect-stmts.c (vectorizable_load): Use pre-computed
22938         nested_in_vect_loop.
22939
22940 2012-02-21  Jakub Jelinek  <jakub@redhat.com>
22941
22942         PR tree-optimization/52318
22943         * gimple-fold.c (gimplify_and_update_call_from_tree): Add
22944         vdef also to non-pure/const call stmts in the sequence.
22945
22946 2012-02-21  Tristan Gingold  <gingold@adacore.com>
22947
22948         * config/vms/vms-ld.c (main): Fix IDENTIFICATION padding.
22949
22950 2012-02-20  David S. Miller  <davem@davemloft.net>
22951
22952         * config/sparc/sparc.md (load_pcrel_sym<P:mode>): Explain why we
22953         don't use the "rd %pc" instruction on v9 for PIC register loads.
22954
22955 2012-02-20  Aldy Hernandez  <aldyh@redhat.com>
22956
22957         PR middle-end/52141
22958         * trans-mem.c (ipa_tm_scan_irr_block): Error out on GIMPLE_ASM's
22959         in a transaction safe function.
22960
22961 2012-02-20  Kai Tietz  <ktietz@redhat.com>
22962
22963         PR target/52238
22964         * stor-layout.c (place_field): Handle desired_align for
22965         ms-bitfields, too.
22966
22967 2012-02-20  Richard Guenther  <rguenther@suse.de>
22968
22969         PR tree-optimization/52298
22970         * tree-vect-stmts.c (vectorizable_store): Properly use
22971         STMT_VINFO_DR_STEP instead of DR_STEP when vectorizing
22972         outer loops.
22973         (vectorizable_load): Likewise.
22974         * tree-vect-data-refs.c (vect_analyze_data_ref_access):
22975         Access DR_STEP after ensuring it is not NULL.
22976
22977 2012-02-20  Jakub Jelinek  <jakub@redhat.com>
22978
22979         PR tree-optimization/52286
22980         * fold-const.c (fold_binary_loc): For (X & C1) | C2
22981         optimization use double_int_to_tree instead of build_int_cst_wide,
22982         rewrite to use double_int vars.
22983
22984 2012-02-20  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
22985
22986         PR target/50166
22987         * acinclude.m4 (gcc_AC_INITFINI_ARRAY): Require gcc_SUN_LD_VERSION.
22988         Define _start.
22989         Remove -e 0 from $gcc_cv_ld invocation.
22990         Only use __GLIBC_PREREQ if defined.
22991         Enable on Solaris since Solaris 8 patch.
22992         (gcc_SUN_LD_VERSION): New macro.
22993         * configure.ac (ld_ver) <*-*-solaris2*>: Refer to
22994         gcc_SUN_LD_VERSION for version number format.
22995         * configure: Regenerate.
22996         * varasm.c (get_elf_initfini_array_priority_section): Set
22997         SECTION_NOTYPE for non-default priority.
22998         Use get_section instead of get_unnamed_section to emit
22999         .init_array/.fini_array with default priority.
23000
23001 2012-02-19  Richard Sandiford  <rdsandiford@googlemail.com>
23002
23003         * config/mips/mips.c (mips_need_mips16_rdhwr_p): New variable.
23004         (mips_get_tp): Set it.  Record that __mips16_rdhwr binds locally.
23005         (mips_start_unique_function, mips_output_mips16_rdhwr)
23006         (mips_code_end): New functions.
23007         (TARGET_ASM_CODE_END): Define.
23008
23009 2012-02-19  Richard Sandiford  <rdsandiford@googlemail.com>
23010
23011         * config/mips/mips.c (mips16_build_call_stub): Add CFI information
23012         to stubs with non-sibling calls.
23013
23014 2012-02-18  Sandra Loosemore  <sandra@codesourcery.com>
23015
23016         * doc/invoke.texi (-fira-* options): Copy-edit.
23017         (ira-* parameters): Copy-edit.
23018
23019 2012-02-17  Sandra Loosemore  <sandra@codesourcery.com>
23020
23021         * doc/invoke.texi: Minor copy-edits to bring into conformance with
23022         GCC coding conventions.
23023
23024 2012-02-17  Sandra Loosemore  <sandra@codesourcery.com>
23025
23026         * doc/invoke.texi: Consistently hyphenate "big-endian"/"little-endian"
23027         when used as adjectives.
23028
23029 2012-02-16  Sandra Loosemore  <sandra@codesourcery.com>
23030
23031         * doc/invoke.texi: Clean up "that"/"which" confusion.
23032
23033 2012-02-17  Steven Bosscher  <steven@gcc.gnu.org>
23034
23035         * system.h: Poison SMALL_REGISTER_CLASSES
23036         * config/rl78/rl78.h: Replace SMALL_REGISTER_CLASSES with hook.
23037         * config/rx/rx.h: Remove SMALL_REGISTER_CLASSES.
23038
23039 2012-02-16  Jakub Jelinek  <jakub@redhat.com>
23040
23041         PR tree-optimization/52285
23042         * tree-tailcall.c (find_tail_calls): Ignore gimple_clobber_p stmts
23043         when deciding if a call is a tail call or tail recursion.
23044
23045 2012-02-16  Kai Tietz  <ktietz@redhat.com>
23046
23047         * config/i386/i386.c (legitimate_pic_address_disp_p): Allow
23048         interger-constant displacement for UNSPEC_PCREL.
23049
23050 2012-02-16  Jakub Jelinek  <jakub@redhat.com>
23051
23052         PR rtl-optimization/52208
23053         * ira-costs.c (scan_one_insn): Don't decrease mem_cost
23054         for MEMs with REG_EQUIV, if the MEM isn't general_operand.
23055
23056         PR tree-optimization/52255
23057         * tree-vect-loop-manip.c (slpeel_tree_peel_loop_to_edge): If
23058         loop->header has virtual PHI, but exit_e->dest doesn't, add
23059         virtual PHI to exit_e->dest and adjust all uses after the loop.
23060
23061         PR debug/52260
23062         * dwarf2out.c (copy_decls_walk): Fill in *slot before traversing
23063         children with clone_tree_hash, not after it.
23064
23065 2012-02-16  Iain Sandoe  <iains@gcc.gnu.org>
23066
23067         * config/darwin.h (ASM_OUTPUT_LABELREF): Add user label prefix for
23068         extended identifiers.
23069
23070 2012-02-16  Jakub Jelinek  <jakub@redhat.com>
23071
23072         PR middle-end/51929
23073         * cgraphunit.c (verify_edge_corresponds_to_fndecl): If node is
23074         a same_body_alias, also test whether e->callee isn't a former
23075         or current clone of the decl this is a same body alias of.
23076
23077         PR translation/52264
23078         * cgraphunit.c (verify_cgraph_node): Fix a typo.
23079
23080 2012-02-15  Sandra Loosemore  <sandra@codesourcery.com>
23081
23082         * doc/invoke.texi: Clean up "n-bit/byte/word" modifiers.
23083
23084 2012-02-15  Michael Meissner  <meissner@linux.vnet.ibm.com>
23085
23086         PR target/52199
23087         * config/rs6000/rs6000.c (rs6000_expand_vector_init): Use
23088         force_reg instead of copy_to_reg for better optimization.  Force
23089         non-register or memory operands into a register.
23090
23091 2012-02-15  Andrew MacLeod  <amacleod@redhat.com>
23092
23093         * extend.texi: Reserve upper bits of memory model for future use.
23094
23095 2012-01-15  Georg-Johann Lay  <avr@gjlay.de>
23096             Anatoly Sokolov <aesok@post.ru>
23097             Eric Weddington <eric.weddington@atmel.com>
23098
23099         PR target/52261
23100         * config/avr/avr-devices.c (avr_arch_types): Add avrxmega2,
23101         avrxmega4, avrxmega5, avrxmega6, avrxmega7.
23102         Rewrite initializers for .macro.
23103         * config/avr/avr-mcus.def (AVR_MCU): Add known MCUs:
23104         avrxmega2: atxmega16a4, atxmega16d4, atxmega16x1, atxmega32a4
23105         atxmega32d4, atxmega32x1.
23106         avrxmega4: atxmega64a3, atxmega64d3.
23107         avrxmega5: atxmega64a1, atxmega64a1u.
23108         avrxmega6: atxmega128a3, atxmega128d3, atxmega192a3, atxmega192d3,
23109         atxmega256a3, atxmega256a3b, atxmega256a3bu, atxmega256d3.
23110         avrxmega7: atxmega128a1, atxmega128a1u.
23111         * config/avr/avr.h (enum avr_arch): Add: ARCH_AVRXMEGA2,
23112         ARCH_AVRXMEGA4, ARCH_AVRXMEGA5, ARCH_AVRXMEGA6, ARCH_AVRXMEGA7.
23113         (struct base_arch_s): Rename reserved to xmega_p.
23114         Rename reserved2 to have_rampd.
23115         (AVR_XMEGA): New define.
23116         (AVR_HAVE_RAMPD, AVR_HAVE_RAMPX, AVR_HAVE_RAMPY): New defines.
23117         (AVR_HAVE_RAMPZ): Change definition to fit xmega.
23118         * config/avr/predicates.md (io_address_operand): Take into
23119         account SFR offset.
23120         (low_io_address_operand): Ditto.
23121         (high_io_address_operand): Ditto.
23122         * config/avr/avr.md (isa): Add alternatives no_xmega, xmega.
23123         (enabled, movhi_sp_r): Use them.
23124         * config/avr/avr-c.c (avr_cpu_cpp_builtins): Use
23125         cpp_define_formatted to built-in define __AVR_ARCH__.
23126         (__AVR_XMEGA__): New built-in define.
23127         (__AVR_HAVE_RAMPD__): New built-in define.
23128         (__AVR_HAVE_RAMPX__): New built-in define.
23129         (__AVR_HAVE_RAMPY__): New built-in define.
23130         (__AVR_HAVE_RAMPZ__): Change condition when to built-in define it.
23131
23132         * config/avr/avr.c (avr_addr_t): Add ccp, rampd, rampx, rampy.
23133         (avr_option_override): Initialize them.
23134         (sreg_rtx, rampd_rtx, rampx_rtx, rampy_rtx): New GTY rtx.
23135         (avr_init_expanders): Initialize them. No more block several calls.
23136         (emit_push_sfr): New static function.
23137         (avr_prologue_setup_frame): Use it to push SREG, RAMPD/X/Y/Z as needed.
23138         Handle AVR_XMEGA.
23139         (expand_epilogue): Handle AVR_XMEGA. Pop RAMPD/X/Y/Z as needed.
23140         (avr_print_operand): Print addreeses as symbols for
23141         RAMPX, RAMPY, RAMPD, CCP.
23142         (output_movhi): Handle AVR_XMEGA when writing to SP.
23143         (avr_out_movhi_mr_r_xmega): New static function.
23144         (out_movhi_mr_r): Forward to avr_out_movhi_mr_r_xmega for AVR_XMEGA.
23145         (avr_file_start): Print symbol defines for __RAMPX__,  __RAMPY__,
23146         __RAMPD__,  __CCP__ as needed.
23147
23148         * config/avr/multilib.h: Regenerate.
23149         * config/avr/t-multilib: Regenerate.
23150         * config/avr/avr-tables.opt: Regenerate.
23151
23152 2012-02-15  Tobias Grosser <grosser@fim.uni-passau.de>
23153
23154         PR tree-optimization/50561
23155         * graphite-flattening.c (lst_project_loop): Do not
23156         remove old scattering dimensions after flattening.
23157         (lst_do_flatten): Likewise.
23158
23159 2012-02-15  Georg-Johann Lay  <avr@gjlay.de>
23160
23161         * doc/extend.texi (AVR Built-in Functions): Remove doc for
23162         __builtin_avr_map8, __builtin_avr_map16.
23163         Document __builtin_avr_insert_bits.
23164
23165         * config/avr/avr.md (map_bitsqi, map_bitshi): Remove.
23166         (insert_bits): New insn.
23167         (adjust_len.map_bits): Rename to insert_bits.
23168         (UNSPEC_MAP_BITS): Rename to UNSPEC_INSERT_BITS.
23169         * avr-protos.h (avr_out_map_bits): Remove.
23170         (avr_out_insert_bits, avr_has_nibble_0xf): New.
23171         * config/avr/constraints.md (Cxf,C0f): New.
23172         * config/avr/avr.c (avr_cpu_cpp_builtins): Remove built-in
23173         defines __BUILTIN_AVR_MAP8, __BUILTIN_AVR_MAP16.
23174         New built-in define __BUILTIN_AVR_INSERT_BITS.
23175         * config/avr/avr.c (TARGET_FOLD_BUILTIN): New define.
23176         (enum avr_builtin_id): Add AVR_BUILTIN_INSERT_BITS.
23177         (avr_move_bits): Rewrite.
23178         (avr_fold_builtin, avr_map_metric, avr_map_decompose): New static
23179         functions.
23180         (avr_map_op_t): New typedef.
23181         (avr_map_op): New static variable.
23182         (avr_out_insert_bits, avr_has_nibble_0xf): New functions.
23183         (adjust_insn_length): Handle ADJUST_LEN_INSERT_BITS.
23184         (avr_init_builtins): Add definition for __builtin_avr_insert_bits.
23185         (bdesc_3arg, avr_expand_triop_builtin): New.
23186         (avr_expand_builtin): Use them. And handle AVR_BUILTIN_INSERT_BITS.
23187         (avr_revert_map, avr_swap_map, avr_id_map, avr_sig_map): Remove.
23188         (avr_map_hamming_byte, avr_map_hamming_nonstrict): Remove.
23189         (avr_map_equal_p, avr_map_sig_p): Remove.
23190         (avr_out_swap_bits, avr_out_revert_bits, avr_out_map_bits): Remove.
23191         (bdesc_2arg): Remove AVR_BUILTIN_MAP8, AVR_BUILTIN_MAP16.
23192         (adjust_insn_length): Remove handling for ADJUST_LEN_MAP_BITS.
23193         (enum avr_builtin_id): Remove AVR_BUILTIN_MAP8, AVR_BUILTIN_MAP16.
23194         (avr_init_builtins): Remove __builtin_avr_map8, __builtin_avr_map16.
23195         (avr_expand_builtin): Remove AVR_BUILTIN_MAP8, AVR_BUILTIN_MAP16.
23196
23197 2012-02-14  Bernd Schmidt  <bernds@codesourcery.com>
23198
23199         * config/c6x/c6x.md (reserve_cycles): New attribute.
23200         * config/c6x/c6x.c (c6x_sched_reorder_1): Ensure insns we predicate
23201         don't reserve functional units after the branch occurs.
23202
23203 2012-02-14  Aldy Hernandez  <aldyh@redhat.com>
23204
23205         PR middle-end/52142
23206         * ipa-inline.c (can_inline_edge_p): Do not inline tm_pure
23207         functions into non-tm_pure functions.
23208
23209 2012-02-14  Eric Botcazou  <ebotcazou@adacore.com>
23210
23211         PR lto/52178
23212         * gimple.c (iterative_hash_gimple_type): Use RECORD_OR_UNION_TYPE_P.
23213         (iterative_hash_canonical_type): Likewise.
23214         * tree-ssa-pre.c (fini_pre): Clean up the CFG only after purging all
23215         the dead edges.
23216
23217 2012-02-14  Bernd Schmidt  <bernds@codesourcery.com>
23218
23219         * haifa-sched.c (prune_ready_list): Ensure that if there is a
23220         sched-group insn, it either remains alone or the entire list is pruned.
23221
23222 2012-02-14  Jonathan Wakely  <jwakely.gcc@gmail.com>
23223
23224         * doc/install.texi (Prerequisites): Fix grammar.
23225         (Configuration): Likewise.
23226
23227 2012-02-14  Jonathan Wakely  <jwakely.gcc@gmail.com>
23228
23229         * doc/install.texi (Prerequisites): Suggest building GMP, MPFR and
23230         MPC as part of GCC before describing configuring with --with-gmp etc.
23231         (Installing GCC: Configuration): --with-gmp etc. aren't needed if
23232         sources are present.
23233
23234 2012-02-14  Jakub Jelinek  <jakub@redhat.com>
23235
23236         PR debug/51950
23237         * dwarf2out.c (clone_tree_hash): New function.
23238         (copy_decls_walk): Use it instead of clone_tree.
23239
23240 2012-02-14  Richard Guenther  <rguenther@suse.de>
23241
23242         PR tree-optimization/52244
23243         PR tree-optimization/51528
23244         * tree-sra.c (analyze_access_subtree): Only create INTEGER_TYPE
23245         replacements for integral types.
23246
23247 2012-02-14  Walter Lee  <walt@tilera.com>
23248
23249         * config.gcc: Handle tilegx and tilepro.
23250         * configure.ac (gcc_cv_as_dwarf2_debug_line): Enable test for
23251         tilegx and tilepro.
23252         Add HAVE_AS_TLS check for tilegx and tilepro.
23253         * configure: Regenerate.
23254         * doc/contrib.texi: Add Mat Hostetter and self.
23255         * doc/extend.texi (TILE-Gx Built-in Functions): New node.
23256         Document instruction intrinsics and network accessing intrinsics.
23257         (TILEPro Built-in Functions): New node.  Document instruction
23258         intrinsics and network accessing intrinsics.
23259         * doc/install.texi (Specific, tilegx-*-linux*): Document it.
23260         (Specific, tilepro-*-linux*): Likewise.
23261         * doc/invoke.texi (TILE-Gx Options): New section.
23262         (TILEPro Options): New section.
23263         * doc/md.texi (TILE-Gx): New section.
23264         (TILEPro): New section.
23265         * common/config/tilegx/tilegx-common.c: New file.
23266         * common/config/tilepro/tilepro-common.c: New file.
23267         * config/tilegx/constraints.md: New file.
23268         * config/tilegx/linux.h: New file.
23269         * config/tilegx/mul-tables.c: New file.
23270         * config/tilegx/predicates.md: New file.
23271         * config/tilegx/sync.md: New file.
23272         * config/tilegx/t-tilegx: New file.
23273         * config/tilegx/tilegx-builtins.h: New file.
23274         * config/tilegx/tilegx-c.c: New file.
23275         * config/tilegx/tilegx-generic.md: New file.
23276         * config/tilegx/tilegx-modes.def: New file.
23277         * config/tilegx/tilegx-multiply.h: New file.
23278         * config/tilegx/tilegx-protos.h: New file.
23279         * config/tilegx/tilegx.c: New file.
23280         * config/tilegx/tilegx.h: New file.
23281         * config/tilegx/tilegx.md: New file.
23282         * config/tilegx/tilegx.opt: New file.
23283         * config/tilepro/constraints.md: New file.
23284         * config/tilepro/gen-mul-tables.cc: New file.
23285         * config/tilepro/linux.h: New file.
23286         * config/tilepro/mul-tables.c: New file.
23287         * config/tilepro/predicates.md: New file.
23288         * config/tilepro/t-tilepro: New file.
23289         * config/tilepro/tilepro-builtins.h: New file.
23290         * config/tilepro/tilepro-c.c: New file.
23291         * config/tilepro/tilepro-generic.md: New file.
23292         * config/tilepro/tilepro-modes.def: New file.
23293         * config/tilepro/tilepro-multiply.h: New file.
23294         * config/tilepro/tilepro-protos.h: New file.
23295         * config/tilepro/tilepro.c: New file.
23296         * config/tilepro/tilepro.h: New file.
23297         * config/tilepro/tilepro.md: New file.
23298         * config/tilepro/tilepro.opt: New file.
23299
23300 2012-02-14  Jakub Jelinek  <jakub@redhat.com>
23301
23302         PR tree-optimization/52210
23303         * tree-vect-slp.c (vect_get_and_check_slp_defs): Call
23304         vect_model_simple_cost with two entry vect_def_type array instead
23305         of an address of dt.
23306
23307 2012-02-14  Richard Guenther  <rguenther@suse.de>
23308
23309         PR lto/52178
23310         * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
23311         Do not stream DECL_QUALIFIER.
23312         * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
23313         * tree.c (free_lang_data_in_decl): Free DECL_QUALIFIER.
23314         (find_decls_types_r): Do not walk DECL_QUALIFIER.
23315
23316 2012-02-14  Jakub Jelinek  <jakub@redhat.com>
23317
23318         PR c/52181
23319         * c-decl.c (merge_decls): Copy DECL_USER_ALIGN bit from olddecl to
23320         newdecl.
23321
23322 2012-02-13  Jakub Jelinek  <jakub@redhat.com>
23323
23324         PR bootstrap/52172
23325         * cselib.h (cselib_subst_to_values_from_insn): New prototype.
23326         * cselib.c (cselib_subst_to_values_from_insn): New function.
23327         * sched-deps.c (add_insn_mem_dependence,
23328         sched_analyze_1, sched_analyze_2): Use it.
23329
23330 2012-02-13  Jan Hubicka  <jh@suse.cz>
23331
23332         PR middle-end/52214
23333         * predict.c (predict_paths_for_bb): Fix thinko in prevoius patch.
23334
23335 2012-02-13  Eric Botcazou  <ebotcazou@adacore.com>
23336
23337         * gcc.c (LINK_COMMAND_SPEC): Deal with -fgnu-tm.
23338         (GTM_SELF_SPECS): Define if not already defined.
23339         (driver_self_specs): Add GTM_SELF_SPECS.
23340         * config/darwin.h (LINK_COMMAND_SPEC_A): Deal with -fgnu-tm.
23341         (GTM_SELF_SPECS): Define.
23342         * config/i386/cygwin.h (GTM_SELF_SPECS): Likewise.
23343         * config/i386/mingw32.h (GTM_SELF_SPECS): Likewise.
23344
23345 2012-02-13  Jakub Jelinek  <jakub@redhat.com>
23346
23347         * cselib.c (expand_loc): Return sp, fp, hfp or cfa base reg right
23348         away if seen.
23349
23350         * cselib.c (dump_cselib_val): Don't assume l->setting_insn is non-NULL.
23351
23352         PR middle-end/52230
23353         * omp-low.c (expand_omp_for): If a static schedule without chunk size
23354         has NULL region->cont, force fd.chunk_size to be integer_zero_node.
23355
23356 2012-02-13  Andrew MacLeod  <amacleod@redhat.com>
23357
23358         PR c/52190
23359         * doc/extend.texi : Fix another __atomic_compare_exchange typo.
23360
23361 2012-02-13  Richard Guenther  <rguenther@suse.de>
23362
23363         PR translation/52211
23364         * passes.c (enable_disable_pass): Fix typo.
23365
23366 2012-02-13  Jakub Jelinek  <jakub@redhat.com>
23367
23368         PR middle-end/52209
23369         * expr.c (expand_expr_real_2) <case BIT_NOT_EXPR>: Only expand using
23370         XOR for reduce_bit_field if type is unsigned.
23371
23372 2012-02-12  Eric Botcazou  <ebotcazou@adacore.com>
23373
23374         * config/sparc/sparc.h (CANNOT_CHANGE_MODE_CLASS): In 64-bit mode,
23375         disallow changes from SFmode to mode with different size in FP regs.
23376
23377 2012-02-12  Robert Millan  <rmh@gnu.org>
23378             Gerald Pfeifer <gerald@pfeifer.com>
23379
23380         * ginclude/stddef.h [__FreeBSD_kernel__] (__size_t): Do not define.
23381         Tweak comment.
23382
23383 2012-02-11  Richard Sandiford  <rdsandiford@googlemail.com>
23384
23385         PR rtl-optimization/52175
23386         * reorg.c (fill_slots_from_thread): Don't apply add/sub optimization
23387         to frame-related instructions.
23388
23389 2012-02-10  Jason Merrill  <jason@redhat.com>
23390
23391         PR c++/51910
23392         * tlink.c (demangled_hash_entry): Change mangled to a VEC.
23393         (demangle_new_symbols): Fill it.
23394         (scan_linker_output): Walk it.
23395         (start_tweaking): Split out from scan_linker_output.
23396         (maybe_tweak): Update sym->chosen.
23397         * Makefile.in (COLLECT2_OBJS): Add vec.o and gcc-none.o
23398
23399 2012-02-11  Jakub Jelinek  <jakub@redhat.com>
23400
23401         PR debug/52132
23402         * reg-stack.c (subst_stack_regs_in_debug_insn): Don't use get_true_reg.
23403
23404 2012-02-11  Uros Bizjak  <ubizjak@gmail.com>
23405
23406         * compare-elim.c (find_comparisons_in_bb): Eliminate only compares
23407         having the same mode as previous compare.
23408
23409 2012-02-10  Eric Botcazou  <ebotcazou@adacore.com>
23410
23411         * config/sparc/sparc.c (sparc_flat_expand_prologue): Use emit_use.
23412         * config/sparc/sparc.md (UNSPECV_GOTO): Delete.
23413         (nonlocal_goto_internal): Likewise.
23414         (nonlocal_goto): Emit a use and an indirect jump directly.
23415
23416 2012-02-10  Andrew MacLeod  <amacleod@redhat.com>
23417
23418         PR c/52190
23419         * doc/extend.texi : Update comments for __atomic_compare_exchange and
23420         __atomic_{is,always}_lock_free.
23421
23422 2012-02-10  Uros Bizjak  <ubizjak@gmail.com>
23423
23424         PR target/52146
23425         * config/i386/i386.c (ix86_legitimate_address_p): Disallow
23426         negative constant address for TARGET_X32.
23427
23428 2012-02-10  Richard Henderson  <rth@redhat.com>
23429
23430         * tree-ssa-dce.c (propagate_necessity): Handle GIMPLE_TRANSACTION.
23431         * tree-ssa-operands.c (parse_ssa_operands): Add virtual operands
23432         for GIMPLE_TRANSACTION.  Tidy if's into a switch.
23433
23434 2012-02-10  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
23435             Ira Rosen  <irar@il.ibm.com>
23436
23437         PR tree-optimization/50031
23438         * targhooks.c (default_builtin_vectorization_cost): Handle
23439         vec_promote_demote.
23440         * target.h (enum vect_cost_for_stmt): Add vec_promote_demote.
23441         * tree-vect-loop.c (vect_get_single_scalar_iteraion_cost): Handle
23442         all types of reduction and pattern statements.
23443         (vect_estimate_min_profitable_iters): Likewise.
23444         * tree-vect-stmts.c (vect_model_promotion_demotion_cost): New function.
23445         (vect_get_load_cost): Use vec_perm for permutations; add dump logic
23446         for explicit realigns.
23447         (vectorizable_conversion): Call vect_model_promotion_demotion_cost.
23448         * config/spu/spu.c (spu_builtin_vectorization_cost): Handle
23449         vec_promote_demote.
23450         * config/i386/i386.c (ix86_builtin_vectorization_cost): Likewise.
23451         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost): Update
23452         vec_perm for VSX and handle vec_promote_demote.
23453
23454 2012-02-10  Jakub Jelinek  <jakub@redhat.com>
23455
23456         PR middle-end/52177
23457         * builtins.c (fold_builtin_atomic_always_lock_free,
23458         expand_builtin_atomic_always_lock_free,
23459         fold_builtin_atomic_is_lock_free, expand_builtin_atomic_is_lock_free):
23460         Return and/or test boolean_true_node/boolean_false_node instead of
23461         integer_one_node/integer_zero_node.
23462
23463 2012-02-10  Jan Hubicka  <jh@suse.cz>
23464
23465         PR middle-end/48600
23466         * predict.c (predict_paths_for_bb): Prevent looping.
23467         (predict_paths_leading_to_edge, predict_paths_leading_to): Update.
23468
23469 2012-02-10  Roman Zhuykov  <zhroma@ispras.ru>
23470
23471         * config/arm/arm.c (output_move_double): In one case properly
23472         count number of instructions that will be emitted.
23473
23474 2012-02-10  Richard Guenther  <rguenther@suse.de>
23475
23476         PR translation/52193
23477         * cgraphunit.c (cgraph_mark_functions_to_output): Fix typo.
23478
23479 2012-02-09  Peter Bergner  <bergner@vnet.ibm.com>
23480
23481         PR middle-end/52140
23482         * dojump.c (do_compare_rtx_and_jump): Use SCALAR_FLOAT_MODE_P.
23483
23484 2012-02-09  Jakub Jelinek  <jakub@redhat.com>
23485
23486         PR debug/52165
23487         * var-tracking.c (emit_note_insn_var_location): If
23488         EMIT_NOTE_BEFORE_INSN and insn is NOTE_INSN_CALL_ARG_LOCATION,
23489         emit it before next non-NOTE_INSN_CALL_ARG_LOCATION
23490         non-NOTE_DURING_CALL_P insn.
23491
23492 2012-02-09  Bin Cheng  <bin.cheng@arm.com>
23493
23494         PR middle-end/51867
23495         * builtins.c (expand_builtin): Don't check DECL_ASSEMBLER_NAME_SET_P.
23496
23497 2012-02-08  Magnus Granberg  <zorry@gentoo.org>
23498
23499         PR driver/48524
23500         * gcc.c (switch_matches) Support switches with separated form,
23501         -D and -U.
23502
23503 2012-02-08  Georg-Johann Lay  <avr@gjlay.de>
23504
23505         * config/avr/avr.md (SREG_ADDR): Remove constant definition.
23506         (SP_ADDR): Ditto.
23507         (RAMPZ_ADDR): Ditto.
23508         * config/avr/avr.c (avr_addr_t): New typedef.
23509         (avr_addr): New struct to hold RAM address of SPL, SPH, RAMPZ, SREG.
23510         (avr_init_expanders): Initialize it.
23511         (expand_prologue): Use avr_addr instead of RAMPZ_ADDR, SP_ADDR,
23512         SREG_ADDR.
23513         (expand_epilogue): Ditto.
23514         (avr_print_operand): Ditto.
23515         (avr_file_start): Ditto.
23516         (avr_emit_movmemhi): Ditto.
23517
23518 2012-02-08  Richard Guenther  <rguenther@suse.de>
23519
23520         PR tree-optimization/46886
23521         * tree-flow.h (do_while_loop_p): Declare.
23522         * tree-ssa-loop-ch.c (do_while_loop_p): Export.
23523         * tree-parloops.c (parallelize_loops): Only parallelize do-while loops.
23524
23525 2012-02-08  Andrew MacLeod  <amacleod@redhat.com>
23526
23527         * optabs.c (expand_atomic_load): Do not assume compare_and_swap will
23528         always succeed for integers larger than a native word.
23529
23530 2012-02-08  Richard Guenther  <rguenther@suse.de>
23531
23532         PR rtl-optimization/52170
23533         * simplify-rtx.c (simplify_plus_minus): Use CONSTM1_RTX to
23534         properly handle integer vector modes.
23535
23536 2012-02-08  Jakub Jelinek  <jakub@redhat.com>
23537
23538         PR gcov-profile/52150
23539         * coverage.c: Include target.h.
23540         (build_var): Call targetm.strip_name_encoding on the assembler name.
23541         Change one _ into . or $ if the target allows it.
23542         * Makefile.in (coverage.o): Depend on $(TARGET_H).
23543
23544         PR rtl-optimization/52139
23545         * cfgrtl.c (cfg_layout_merge_blocks): If BB_END
23546         is a BARRIER after emit_insn_after_noloc, move BB_END
23547         to the last non-BARRIER insn before it.
23548
23549 2012-02-07  Richard Sandiford  <rdsandiford@googlemail.com>
23550
23551         PR middle-end/24306
23552         * config/mips/mips.c (mips_std_gimplify_va_arg_expr): New function.
23553         (mips_gimplify_va_arg_expr): Call it instead of
23554         std_gimplify_va_arg_expr.
23555
23556 2012-02-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
23557
23558         * config/rs6000/rs6000.c (rs6000_trampoline_init): Fix error
23559         message for -mno-pointers-to-nested-function.
23560
23561 2012-02-07  Eric Botcazou  <ebotcazou@adacore.com>
23562
23563         PR middle-end/51994
23564         * expr.c (get_inner_reference): If there is an offset, add a negative
23565         bit position to it (if any).
23566
23567 2012-02-07  Jakub Jelinek  <jakub@redhat.com>
23568
23569         PR rtl-optimization/52060
23570         * combine.c (try_combine): Add i0src_copy and i0src_copy2 variables,
23571         copy i1src to i1src_copy whenever added_sets_2 && i1_feeds_i2_n already
23572         before i1dest -> i1src substitution in newpat, copy i0src to i0src_copy
23573         and/or i0src_copy2 when needed.
23574
23575 2012-02-07  Jakub Jelinek  <jakub@redhat.com>
23576
23577         * gcc.c (main): Don't look for lto-wrapper or lto-wrapper
23578         or LTOPLUGINSONAME if have_c.
23579
23580         * config/freebsd-spec.h: Add comment about what macros can be defined
23581         in this header.
23582         (LINK_EH_SPEC, LINK_SSP_SPEC, USE_LD_AS_NEEDED): Don't define here.
23583         * config/freebsd.h (LINK_EH_SPEC, LINK_SSP_SPEC, USE_LD_AS_NEEDED): But
23584         here instead.
23585
23586 2012-02-07  Richard Guenther  <rguenther@suse.de>
23587
23588         * gimple-pretty-print.c (dump_gimple_phi): Avoid excessive
23589         newline in -alias dumps.
23590
23591 2012-02-07  Kai Tietz  <ktietz@redhat.com>
23592             Dave Korn  <dave.korn.cygwin@gmail.com>
23593
23594         PR target/40068
23595         * config/i386/winnt-cxx.c (i386_pe_adjust_class_at_definition):
23596         Take care that typinfo gets dllexport-attribute.
23597
23598 2012-02-07  Jakub Jelinek  <jakub@redhat.com>
23599
23600         PR middle-end/52074
23601         * expr.c (expand_expr_addr_expr_1): For CONSTANT_CLASS_P or CONST_DECL
23602         if modifier < EXPAND_SUM call force_operand on the result.
23603
23604 2012-02-07  Joern Rennecke  <joern.rennecke@embecosm.com>
23605
23606         * config/epiphany/epiphany.h (ASM_DECLARE_FUNCTION_SIZE): Redefine,
23607         adding __forwarder_dst__ prefix if a forwarder_section attribute is
23608         present.
23609         (epiphany_function_type): Replace types for specific interrupts with
23610         EPIPHANY_FUNCTION_INTERRUPT.
23611         (EPIPHANY_INTERRUPT_P): Update.
23612         * config/epiphany/epiphany.c (epiphany_handle_forwarder_attribute):
23613         New static function.
23614         (epiphany_attribute_table) <interrupt>: min_len is 0, max_len is 9.
23615         <disinterrupt>: Affects type identity.
23616         (epiphany_handle_interrupt_attribute): Handle variable number of
23617         arguments.
23618         (epiphany_compute_function_type): Update for new
23619         epiphany_function_type definition.
23620         (epiphany_expand_prologue): Don't save (reg:DI GPR_0) for interrupt
23621         handlers with a longcall forwarder.
23622         (epiphany_start_function): Handle multiple interrupt arguments and/or
23623         forwarder_section attribute.
23624
23625         * config/epiphany/epiphany.h (LIB_SPEC): Link libc again after
23626         libgloss.
23627
23628 2012-02-07  Alan Modra  <amodra@gmail.com>
23629
23630         PR target/52107
23631         * config/rs6000/rs6000.c (rs6000_emit_move): Don't create DImode
23632         subregs of TFmode.
23633
23634 2012-02-06  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
23635
23636         PR tree-optimization/50969
23637         * tree-vect-stmts.c (vect_model_store_cost): Correct statement cost to
23638         use vec_perm rather than vector_stmt.
23639         (vect_model_load_cost): Likewise.
23640         * config/i386/i386.c (ix86_builtin_vectorization_cost): Change cost of
23641         vec_perm to be the same as other vector statements.
23642         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost): Revise
23643         cost of vec_perm for TARGET_VSX.
23644
23645 2012-02-06  Richard Guenther  <rguenther@suse.de>
23646
23647         PR tree-optimization/52115
23648         * tree-sra.c (access_has_replacements_p): New function.
23649         (sra_modify_assign): Use it to decide whether a use is uninitialized.
23650
23651 2012-02-06  Patrick Marlier  <patrick.marlier@gmail.com>
23652
23653         PR middle-end/52047
23654         * trans-mem.c (expand_call_tm): Add an assertion.
23655         * calls.c (flags_from_decl_or_type): Add ECF_TM_PURE to 'no vops'
23656         functions.
23657
23658 2012-02-06  Richard Guenther  <rguenther@suse.de>
23659
23660         PR tree-optimization/50955
23661         * tree-ssa-loop-ivopts.c (get_computation_cost_at): Artificially
23662         raise cost of expressions that replace an address with an
23663         expression based on a different pointer.
23664
23665 2012-02-06  Jakub Jelinek  <jakub@redhat.com>
23666
23667         PR target/52129
23668         * calls.c (mem_overlaps_already_clobbered_arg_p): If val is
23669         CONST_INT_P, subtract resp. add crtl->args.pretend_args_size to it.
23670
23671 2012-02-06  Jonathan Wakely  <jwakely.gcc@gmail.com>
23672
23673         PR c++/48680
23674         * doc/invoke.texi (C++ Dialect Options): Use @option markup for
23675         -Weffc++ and specify guidelines come from second edition.
23676
23677 2012-02-05  Richard Sandiford  <rdsandiford@googlemail.com>
23678
23679         * config/mips/mips.md (sibcall_internal, sibcall_value_internal)
23680         (sibcall_value_multiple_internal, call_split, call_internal_direct)
23681         (call_direct_split, call_value_split, call_value_internal_direct)
23682         (call_value_direct_split, call_value_multiple_split): Use jal and
23683         jal_macro attributes.
23684
23685 2012-02-05  Richard Sandiford  <rdsandiford@googlemail.com>
23686
23687         * reload1.c (reload_regs_reach_end_p): Replace with...
23688         (reload_reg_rtx_reaches_end_p): ...this function.
23689         (new_spill_reg_store): Update commentary.
23690         (emit_input_reload_insns): Don't clear new_spill_reg_store here.
23691         (emit_output_reload_insns): Check reload_reg_rtx_reaches_end_p
23692         before setting new_spill_reg_store.
23693         (emit_reload_insns): Use a separate loop to clear new_spill_reg_store.
23694         Use reload_reg_rtx_reaches_end_p instead of reload_regs_reach_end_p.
23695         Also use reload_reg_rtx_reaches_end_p when reading new_spill_reg_store
23696         for non-spill reload registers.
23697
23698 2012-02-05  Ira Rosen  <irar@il.ibm.com>
23699
23700         PR tree-optimization/52091
23701         * tree-vectorizer.h (vect_is_simple_use): Add an argument.
23702         (vect_is_simple_use_1): Likewise.
23703         * tree-vect-loop.c (vectorizable_reduction): Update calls
23704         to vect_is_simple_use_1 and vect_is_simple_use.
23705         (vectorizable_live_operation): Likewise.
23706         * tree-vect-patterns.c (widened_name_p,
23707         vect_recog_vector_vector_shift_pattern, check_bool_pattern): Likewise.
23708         * tree-vect-stmts.c (process_use, vect_get_vec_def_for_operand,
23709         vectorizable_call, vectorizable_conversion, vectorizable_assignment,
23710         vectorizable_shift,vectorizable_operation, vectorizable_store,
23711         vectorizable_load): Likewise.
23712         (vect_is_simple_cond): Add an argument, pass it to
23713         vect_is_simple_use_1.
23714         (vectorizable_condition): Update calls to vect_is_simple_cond,
23715         vect_is_simple_use.
23716         (vect_is_simple_use): Add an argument, the statement in which
23717         OPERAND is used.  Check that if OPERAND's def stmt is a double
23718         reduction phi node, the use is a phi node too.
23719         (vect_is_simple_use_1): Add an argument, pass it to
23720         vect_is_simple_use.
23721         * tree-vect-slp.c (vect_get_and_check_slp_defs): Update a call
23722         to vect_is_simple_use.
23723
23724 2012-02-04  Jakub Jelinek  <jakub@redhat.com>
23725
23726         PR rtl-optimization/52095
23727         * modulo-sched.c (dump_insn_locator): New function.
23728         (loop_canon_p, sms_schedule): Use it.
23729
23730         PR rtl-optimization/52113
23731         * lower-subreg.c (decompose_multiword_subregs): Call recog_memoized
23732         even for decomposable shift/zext insns.
23733
23734 2012-02-03  Jakub Jelinek  <jakub@redhat.com>
23735             Zdenek Dvorak  <ook@ucw.cz>
23736
23737         PR rtl-optimization/52092
23738         * loop-unswitch.c (unswitch_single_loop): Call copy_rtx_if_shared
23739         on get_iv_value result.
23740
23741 2012-02-02  Andrew Pinski  <apinski@cavium.com>
23742
23743         PR middle-end/47982
23744         PR middle-end/43967
23745         * doc/libgcc.texi (__udivmoddi4/__udivmodti4): Fix documentation typo.
23746
23747 2012-02-02  Jakub Jelinek  <jakub@redhat.com>
23748
23749         PR middle-end/48071
23750         * diagnostic.c (diagnostic_finish): Remove trailing newlines.
23751
23752 2012-02-02  Vladimir Makarov  <vmakarov@redhat.com>
23753
23754         PR rtl-optimization/49800
23755         * haifa-sched.c (sched_init): Call regstat_init_n_sets_and_refs.
23756         (sched_finish): Call regstat_free_n_sets_and_refs.
23757
23758 2012-02-02  Jia Liu  <proljc@gmail.com>
23759
23760         * config/mips/mips-dspr2.md (mips_prepend): Mask operand 3 rather
23761         than operand 2.
23762
23763 2012-02-02  Jan Hubicka  <jh@suse.cz>
23764             Tom de Vries  <tom@codesourcery.com>
23765
23766         PR middle-end/51998
23767         * cgraphunit.c (cgraph_analyze_function): Break cyclic aliases.
23768         * varpool.c (varpool_analyze_pending_decls): Likewise.
23769
23770 2012-02-02  Sumanth G <sumanth.gundapaneni@kpitcummins.com>
23771             Jayant R Sonar <jayant.sonar@kpitcummins.com>
23772
23773         * config.gcc: Add cr16-* support.
23774
23775         * doc/extend.texi: Document cr16 extensions.
23776         * doc/install.texi: Document cr16 install.
23777         * doc/invoke.texi: Document cr16 options.
23778         * doc/md.texi: Document cr16 constraints.
23779
23780         * common/config/cr16/cr16-common.c: New file.
23781         * config/cr16/cr16.c: New file.
23782         * config/cr16/cr16.h: New file.
23783         * config/cr16/cr16.md: New file.
23784         * config/cr16/cr16.opt: New file.
23785         * config/cr16/cr16-protos.h: New file.
23786         * config/cr16/predicates.md: New file.
23787         * config/cr16/constraints.md: New file.
23788         * config/cr16/t-cr16: New file.
23789
23790 2012-02-02  Jakub Jelinek  <jakub@redhat.com>
23791
23792         PR target/52086
23793         * config/i386/i386.md (*addqi_2 peephole with SImode addition): Check
23794         that operands[2] is either immediate, or q_regs_operand.
23795
23796         PR tree-optimization/52073
23797         * tree-vect-stmts.c (vect_mark_relevant): When checking uses of
23798         a pattern stmt for pattern uses, ignore uses outside of the loop.
23799
23800 2012-02-01  Georg-Johann Lay  <avr@gjlay.de>
23801
23802         * config/avr/avr.c: Resolve all AS1 and AS2 macros.
23803         * config/avr/avr.h (AS1, AS2, AS2C, AS3): Remove.
23804         (OUT_AS1, OUT_AS2): Remove.
23805
23806 2012-02-01  Georg-Johann Lay  <avr@gjlay.de>
23807
23808         PR rtl-optimization/51374
23809         * combine.c (can_combine_p): Don't allow volatile_refs_p insns
23810         to cross other volatile_refs_p insns.
23811
23812 2012-02-01  Richard Guenther  <rguenther@suse.de>
23813
23814         * doc/invoke.texi (fno-inline): Clarify documentation.
23815         (finline-small-functions): Likewise.
23816         (finline-functions): Likewise.
23817         * common.opt (finline): Adjust comment and documentation.
23818         (finline-small-functions): Clarify documentation.
23819         (finline-functions): Likewise.
23820         (finline-functions-called-once): Likewise.
23821
23822 2012-02-01  Tristan Gingold  <gingold@adacore.com>
23823
23824         * c-typeck.c (composite_type): Keep mode for pointers.
23825
23826 2012-01-31  Richard Sandiford  <rdsandiford@googlemail.com>
23827
23828         * function.h (regno_reg_rtx): Adjust comment.
23829         * reginfo.c (init_reg_modes_target): Only use the previous mode
23830         if it fits within one register.  Remove MIPS comment.
23831
23832 2012-01-31  Jakub Jelinek  <jakub@redhat.com>
23833
23834         PR bootstrap/52058
23835         * combine.c (do_SUBST_LINK, SUBST_LINK): Guard with #ifndef HAVE_cc0.
23836
23837 2012-01-31  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
23838
23839         * config/s390/s390.md ("*ashr<mode>3_and"): Add missing z196 flag
23840         to srak instruction.
23841
23842 2012-01-31  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
23843
23844         * config/arm/thumb2.md (thumb2_mov_notscc): Use MVN for true condition.
23845
23846 2012-01-31  Jakub Jelinek  <jakub@redhat.com>
23847
23848         PR bootstrap/52041
23849         PR bootstrap/52039
23850         PR target/51974
23851         * ipa-prop.c (detect_type_change_1): Call ao_ref_init.
23852
23853 2012-01-31  Richard Guenther  <rguenther@suse.de>
23854
23855         PR tree-optimization/51528
23856         * tree-sra.c (sra_modify_assign): Avoid copy-in/out for aggregate
23857         assigns.
23858
23859 2012-01-31  Jakub Jelinek  <jakub@redhat.com>
23860
23861         PR bootstrap/52041
23862         PR bootstrap/52039
23863         PR target/51974
23864         * ree.c (add_removable_extension): Change def_map argument
23865         to unsigned *, store in def_map 1 + offset into *insn_list vector
23866         instead of pointers into the vector.
23867         (find_removable_extensions): Adjust caller.
23868
23869 2012-01-30  Georg-Johann Lay  <avr@gjlay.de>
23870
23871         * config/avr/avr.md: Resolve all AS1 and AS2 macros.
23872         Transform all "* quoted-c-code" to { c-code }.
23873         Remove redundant test for "optimize" in combine patterns.
23874         Move (include "avr-dimode.md") to end of file.
23875
23876 2012-01-30  Bin Cheng  <bin.cheng@arm.com>
23877
23878         PR target/51835
23879         * config/arm/arm.c (arm_libcall_uses_aapcs_base): Use correct ABI
23880         for __aeabi_d2iz/__aeabi_d2uiz with hard-float.
23881
23882 2012-01-30  Richard Guenther  <rguenther@suse.de>
23883
23884         PR tree-optimization/52028
23885         * tree-loop-distribution.c (ldist_gen): Properly update
23886         virtual SSA form.
23887
23888 2012-01-30  Jakub Jelinek  <jakub@redhat.com>
23889
23890         PR debug/52027
23891         * dwarf2out.c (dwarf2out_switch_text_section): Don't call
23892         set_cur_line_info_table if not emitting debug info.
23893
23894         PR tree-optimization/52046
23895         * tree-vect-patterns.c (check_bool_pattern): Give up if
23896         a comparison could throw.
23897
23898         PR debug/52048
23899         * tree-ssa-tail-merge.c (local_def): Ignore debug uses.
23900
23901 2012-01-30  Richard Guenther  <rguenther@suse.de>
23902
23903         PR tree-optimization/52045
23904         * tree-optimize.c (execute_cleanup_cfg_post_optimizing): Update
23905         SSA form if cfgcleanup did anything.
23906
23907 2012-01-30  Richard Guenther  <rguenther@suse.de>
23908
23909         PR tree-optimization/52045
23910         * ipa-inline-transform.c (inline_transform): Call execute_fixup_cfg
23911         before computing final todo.
23912
23913 2012-01-30  Richard Guenther  <rguenther@suse.de>
23914
23915         PR tree-optimization/51528
23916         * tree-sra.c (sra_modify_assign): Re-factor in preparation
23917         for PR51528 fix.
23918
23919 2012-01-30  Paolo Bonzini  <bonzini@gnu.org>
23920
23921         * df-problems.c (df_kill_notes): Check that the use refers
23922         to the note under examination.
23923
23924 2012-01-30  Eric Botcazou  <ebotcazou@adacore.com>
23925
23926         PR target/51920
23927         * config/sparc/sparc.c (vector_init_fpmerge): Remove INNER_MODE
23928         parameter and use short-lived pseudos.
23929         (vector_init_faligndata): Remove INNER_MODE parameter and use loop.
23930         (sparc_expand_vector_init): Const-ify local variables and adjust
23931         calls to above functions.
23932
23933 2012-01-30  Georg-Johann Lay  <avr@gjlay.de>
23934
23935         * config/avr/avr.c (out_movqi_mr_r): Fix length computation.
23936
23937 2012-01-29  Sandra Loosemore  <sandra@codesourcery.com>
23938
23939         * doc/invoke.texi: Make usage of "compile time" and
23940         "run time"/"runtime" consistent throughout the file.
23941
23942 2012-01-29  Uros Bizjak  <ubizjak@gmail.com>
23943
23944         * config/alpha/alpha.c (alpha_option_override): Default to
23945         full IEEE compliance mode for Go language.
23946
23947 2012-01-29  Tijl Coosemans  <tijl@coosemans.org>
23948
23949         * config/freebsd-spec.h [TARGET_LIBC_PROVIDES_SSP]
23950         (LINK_SSP_SPEC): Define.
23951
23952 2012-01-28  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
23953
23954         PR target/51871
23955         * config/pa/pa.c (pa_return_addr_rtx): Add support for PA2.0 export
23956         stubs.
23957
23958 2012-01-28  Sandra Loosemore  <sandra@codesourcery.com>
23959
23960         * doc/invoke.texi: Correct hyphenation of "floating point",
23961         "double precision", and related terminology throughout the file.
23962
23963 2012-01-28  Jakub Jelinek  <jakub@redhat.com>
23964
23965         PR target/52006
23966         * config/arm/arm.md (pic_add_dot_plus_eight peephole2): Use
23967         arm_general_register_operand predicate for operand 2 instead of
23968         register_operand.
23969
23970 2012-01-27  Ian Lance Taylor  <iant@google.com>
23971
23972         PR go/47656
23973         * builtins.def (BUILT_IN_INIT_HEAP_TRAMPOLINE): Define.
23974         * builtins.c (expand_builtin_init_trampoline): Add onstack
23975         parameter.  Change caller.
23976         (expand_builtin): Handle BUILT_IN_INIT_HEAP_TRAMPOLINE.
23977         * tree.c (build_common_builtin_nodes): Declare
23978         __builtin_init_heap_trampoline.
23979
23980 2012-01-27  Georg-Johann Lay  <avr@gjlay.de>
23981
23982         * config/avr/avr-protos.h (lpm_reg_rtx, lpm_addr_reg_rtx,
23983         tmp_reg_rtx, zero_reg_rtx, all_regs_rtx, rampz_rtx): Make global.
23984         * config/avr/avr.c: Ditto.
23985         (avr_regnames): Remove because unused.
23986         * config/avr/avr.md (*cpse.ne): New peephole.
23987         (*cpse.eq): New peephole from former cpse peepholes.
23988
23989 2012-01-27  Michael Eager  <eager@eagercon.com>
23990
23991         * config/microblaze.c (microblaze_emit_compare): Correct
23992         test after pcmp instruction.
23993
23994 2012-01-27  Richard Guenther  <rguenther@suse.de>
23995
23996         PR tree-optimization/52020
23997         * tree-sra.c (sra_modify_assign): Do not transform clobbers.
23998
23999 2012-01-27  Richard Guenther  <rguenther@suse.de>
24000
24001         * ipa-pure-const.c (check_stmt): Clobbers do not make a
24002         function non-const/pure.
24003
24004 2012-01-27  Richard Guenther  <rguenther@suse.de>
24005
24006         PR tree-optimization/50444
24007         * tree-sra.c (build_ref_for_offset): Properly adjust the
24008         MEM_REF type for unaligned accesses.
24009
24010 2012-01-27  Richard Guenther  <rguenther@suse.de>
24011
24012         PR tree-optimization/50444
24013         * expr.c (mem_ref_refers_to_non_mem_p): New function.
24014         (expand_assignment): Use it.  Properly handle misaligned
24015         bases when expanding stores to component references.
24016         (expand_expr_real_1): Use mem_ref_refers_to_non_mem_p and
24017         refactor that case.
24018
24019 2012-01-27  Andrey Belevantsev  <abel@ispras.ru>
24020
24021         PR middle-end/51389
24022         * Makefile.in (tree-data-ref.o): Depend on $(PARAMS_H).
24023         * tree-data-ref.h (find_data_references_in_loop): Remove declaration.
24024         * tree-data-ref.c (find_data_references_in_loop): Make static.
24025         (compute_all_dependences): Change return type to bool.  Bail out
24026         for too many datarefs in a loop.  Move the hunk resetting the data
24027         dependences vector from ...
24028         (compute_data_dependences_for_loop): ... here.  Account for
24029         compute_all_dependences returning false.
24030         (compute_data_dependences_for_bb): Likewise.
24031         * params.def (PARAM_LOOP_MAX_DATAREFS_FOR_DATADEPS): New param.
24032         * doc/invoke.texi (loop-max-datarefs-for-datadeps): Document it.
24033
24034 2012-01-27  Richard Guenther  <rguenther@suse.de>
24035
24036         PR middle-end/51959
24037         * expr.c (store_field): Use the alias-set of the scratch memory
24038         for storing to it.
24039
24040 2012-01-27  Tom de Vries  <tom@codesourcery.com>
24041
24042         PR tree-optimization/51990
24043         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Handle
24044         WITH_SIZE_EXPR.
24045         * tree-ssa-pre.c (create_component_ref_by_pieces_1): Same.
24046
24047 2012-01-27  Jakub Jelinek  <jakub@redhat.com>
24048
24049         PR debug/52001
24050         * var-tracking.c (reverse_op): Don't add any reverse operation
24051         if V already has any constant locations.
24052
24053 2012-01-27  Sandra Loosemore  <sandra@codesourcery.com>
24054
24055         * doc/invoke.texi: Correct usage of "command line" (noun)
24056         vs "command-line" (adjective) throughout.
24057
24058 2012-01-27  Sandra Loosemore  <sandra@codesourcery.com>
24059
24060         * doc/invoke.texi (Language Independent Options): Move
24061         -Wcoverage-mismatch blurb from here....
24062         (Warning Options): ...to here.
24063
24064 2012-01-27  Peter Bergner  <bergner@vnet.ibm.com>
24065
24066         * config/rs6000/rs6000.c (rs6000_option_override_internal):
24067         Set rs6000_always_hint to false for 476.
24068
24069 2012-01-27  Matthias Klose  <doko@ubuntu.com>
24070
24071         * gcc.c (add_sysrooted_prefix): Remove trailing dir separator from
24072           system root.
24073         * incpath.c (add_standard_paths): Likewise.
24074
24075 2012-01-27  Richard Henderson  <rth@redhat.com>
24076
24077         * config/m68k/m68k.c (TARGET_ATOMIC_TEST_AND_SET_TRUEVAL): New.
24078         * config/m68k/sync.md (atomic_test_and_set): Rename from
24079         sync_test_and_setqi and adjust the operands.
24080         (atomic_test_and_set_1): Rename from sync_test_and_setqi_1
24081         and unconditionally enable.
24082
24083 2012-01-27  Richard Henderson  <rth@redhat.com>
24084
24085         * config/sparc/sparc.c (TARGET_ATOMIC_TEST_AND_SET_TRUEVAL): New.
24086         * config/sparc/sync.md (atomic_test_and_set): Only handle QImode.
24087         (ldstub): Rename from ldstubqi.
24088         (ldstub<I24MODE>): Remove.
24089
24090 2012-01-27  Richard Henderson  <rth@redhat.com>
24091
24092         * target.def (TARGET_ATOMIC_TEST_AND_SET_TRUEVAL): New.
24093         * c-cppbuiltin.c (cpp_atomic_builtins): Define
24094         __GCC_ATOMIC_TEST_AND_SET_TRUEVAL.
24095         * doc/tm.texi.in (TARGET_ATOMIC_TEST_AND_SET_TRUEVAL): Add doc hook.
24096         * doc/tm.texi: Rebuild.
24097
24098 2012-01-27  Richard Henderson  <rth@redhat.com>
24099
24100         * optabs.c (gen_atomic_test_and_set): Remove default.
24101         (maybe_emit_atomic_test_and_set): Use maybe_expand_insn.
24102
24103 2012-01-26  Jakub Jelinek  <jakub@redhat.com>
24104
24105         PR rtl-optimization/51978
24106         * ree.c (make_defs_and_copies_lists): Change set_pat type to const_rtx.
24107         (combine_reaching_defs): Likewise.
24108         (struct re_info): Remove.
24109         (add_removable_extension): Remove x and data arguments,
24110         add insn, insn_list and def_map.  Use the arguments directly
24111         instead of using struct re_info.
24112         (find_removable_extensions): Don't call add_removable_extension
24113         through note_stores, instead just call it with single_set
24114         result if non-NULL.
24115         (find_and_remove_re): Pass curr_cand->expr instead of
24116         PATTERN (curr_cand->insn) as set_pat argument to combine_reaching_defs.
24117
24118 2012-01-26  Michael Matz  <matz@suse.de>
24119
24120         PR tree-optimization/46590
24121         * cfgexpand.c: Revert last change (r183305).
24122         * gimplify.c (gimplify_bind_expr): Add clobbers for all non-gimple
24123         regs.
24124         * tree-eh.c (cleanup_empty_eh): Try to optimize clobbers before
24125         checking for emptiness.
24126
24127 2012-01-26  Jakub Jelinek  <jakub@redhat.com>
24128
24129         PR middle-end/51895
24130         * expr.c (expand_expr_real_1): Handle BLKmode MEM_REF of
24131         non-addressable non-BLKmode base correctly.
24132
24133 2012-01-26  Michael Matz  <matz@suse.de>
24134
24135         PR tree-optimization/48794
24136         * tree-eh.c (remove_unreachable_handlers_no_lp): Don't remove
24137         regions referenced from RESX/EH_DISPATCH.
24138
24139 2012-01-26  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
24140
24141         * config/s390/s390.h: Make BRANCH_COST an option.
24142         * config/s390/s390.opt: New option -mbranch-cost.
24143
24144 2012-01-26  Richard Henderson  <rth@redhat.com>
24145
24146         Revert 2012-01-24 change:
24147         * trans-mem.c (requires_barrier): Do not instrument thread local
24148         variables and emit save/restore for them.
24149
24150 2012-01-25  Jakub Jelinek  <jakub@redhat.com>
24151
24152         PR middle-end/51986
24153         * sched-deps.c (sched_get_condition_with_rev_uncached): Don't test
24154         for pat == 0.
24155
24156 2012-01-25  Richard Sandiford  <rdsandiford@googlemail.com>
24157
24158         * config/mips/mips.c (mips_small_data_pattern_1): Don't process
24159         ASM_OPERANDS.
24160
24161 2012-01-25  Georg-Johann Lay  <avr@gjlay.de>
24162
24163         PR target/49868
24164         Rename __pgm to __flash.
24165         Rename __pgm1 to __flash1.
24166         Rename __pgm2 to __flash2.
24167         Rename __pgm3 to __flash3.
24168         Rename __pgm4 to __flash4.
24169         Rename __pgm5 to __flash5.
24170         Rename __pgmx to __memx.
24171         * doc/extend.texi (AVR Named Address Spaces)
24172         Rename address space names as indicated above.
24173         * config/avr/avr.c (avr_addrspace): Ditto.
24174
24175         * config/avr/avr-protos.h
24176         (avr_mem_pgmx_p): Rename to avr_mem_memx_p.
24177         (avr_mem_pgm_p): Rename to avr_mem_flash_p.
24178         * config/avr/predicates.md: Ditto.
24179         * config/avr/avr.c Ditto, and
24180         (avr_decl_pgmx_p): Rename to avr_decl_memx_p.
24181         (avr_decl_pgm_p): Rename to avr_decl_flash_p.
24182
24183         * config/avr/avr.h (ADDR_SPACE_PGM): Rename to ADDR_SPACE_FLASH.
24184         (ADDR_SPACE_PGM1): Rename to ADDR_SPACE_FLASH1.
24185         (ADDR_SPACE_PGM2): Rename to ADDR_SPACE_FLASH2.
24186         (ADDR_SPACE_PGM3): Rename to ADDR_SPACE_FLASH3.
24187         (ADDR_SPACE_PGM4): Rename to ADDR_SPACE_FLASH4.
24188         (ADDR_SPACE_PGM5): Rename to ADDR_SPACE_FLASH5.
24189         (ADDR_SPACE_PGMX): Rename to ADDR_SPACE_MEMX.
24190         * config/avr/avr.c: Ditto.
24191         * config/avr/avr.md: Ditto.
24192
24193 2012-01-25  Jason Merrill  <jason@redhat.com>
24194
24195         PR c++/51992
24196         * tree.c (find_decls_types_in_node): Walk gimple_call_fntype.
24197
24198 2012-01-25  Jakub Jelinek  <jakub@redhat.com>
24199
24200         PR tree-optimization/51987
24201         * tree-data-ref.c (get_references_in_stmt): Handle references in
24202         non-volatile GIMPLE_ASM.
24203
24204 2012-01-25  Richard Guenther  <rguenther@suse.de>
24205
24206         * tree-ssa-sccvn.c (vn_reference_eq): Also compare if both
24207         bases are dereferenced.
24208
24209 2012-01-25  Andrey Belevantsev  <abel@ispras.ru>
24210
24211         PR rtl-optimization/48374
24212         * sel-sched-ir.h (get_all_loop_exits): Check for zero successors.
24213
24214 2012-01-25  Andrey Belevantsev  <abel@ispras.ru>
24215
24216         * tree-predcom.c (tree_predictive_commoning_loop): Bail out when
24217         compute_data_dependences_for_loop returns false.
24218         * tree-parloops.c (loop_parallel_p): Likewise.
24219
24220 2012-01-25  Richard Guenther  <rguenther@suse.de>
24221
24222         * tree.h (get_pointer_alignment_1): Declare.
24223         * builtins.c (get_pointer_alignment_1): New function.
24224         (get_pointer_alignment): Use it.
24225
24226 2012-01-25  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
24227
24228         PR rtl-optimization/48308
24229         * combine.c (enum undo_kind): Add UNDO_LINKS.
24230         (struct undo): Add member l to other_contents and where.
24231         (do_SUBST_LINK): New.
24232         (SUBST_LINK): New.
24233         (try_combine): Handle LOG_LINKS for the dummy i1 case.
24234         (undo_all): Handle UNDO_LINKS.
24235
24236 2012-01-25  Richard Henderson  <rth@redhat.com>
24237
24238         * optabs.c (maybe_emit_atomic_test_and_set): Allow non-QImode
24239         mem inputs.
24240
24241 2012-01-24  Richard Sandiford  <rdsandiford@googlemail.com>
24242
24243         * optabs.c (gen_atomic_test_and_set): Use each argument.
24244
24245 2012-01-24  Richard Sandiford  <rdsandiford@googlemail.com>
24246
24247         * config/mips/mips-ps-3d.md (mips_addr_ps, reduc_splus_v2sf)
24248         (mips_cvt_pw_ps, mips_cvt_ps_pw, mips_mulr_ps, mips_cabs_cond_<fmt>)
24249         (mips_cabs_cond_4s, mips_cabs_cond_ps, bc1any4t, bc1any4f, bc1any2t)
24250         (bc1any2f, mips_rsqrt1_<fmt>, mips_rsqrt2_<fmt>, mips_recip1_<fmt>)
24251         (mips_recip2_<fmt>): Require TARGET_MIPS3D rather than
24252         TARGET_PAIRED_SINGLE_FLOAT.
24253
24254 2012-01-24  Richard Sandiford  <rdsandiford@googlemail.com>
24255
24256         * doc/rtl.texi (MEM_IN_STRUCT_P, MEM_SCALAR_P): Delete.
24257         (in_struct, return_val): Remove MEM documentation.
24258         * rtl.h (rtx_def): Remove MEM meanings from in_struct and return_val.
24259         (MEM_IN_STRUCT_P, MEM_SCALAR_P): Delete.
24260         (MEM_COPY_ATTRIBUTES): Remove references to MEM_IN_STRUCT_P
24261         and MEM_SCALAR.
24262         * emit-rtl.c (set_mem_attributes_minus_bitpos): Likewise.
24263         * cfgexpand.c (add_alias_set_conflicts): Likewise.
24264         * expr.c (store_field): Likewise.
24265         * function.c (assign_stack_temp_for_type): Likewise.
24266         * ifcvt.c (noce_try_cmove_arith): Likewise.
24267         * reload1.c (reload): Likewise.
24268         * config/alpha/alpha.c (alpha_set_memflags_1): Likewise.
24269         (alpha_set_memflags): Likewise.
24270         * config/m32c/m32c.c (m32c_immd_dbl_mov): Nullify.
24271
24272 2012-01-24  Richard Sandiford  <rdsandiford@googlemail.com>
24273
24274         * rtl.h (true_dependence, canon_true_dependence): Remove varies
24275         parameter.
24276         * alias.c (fixed_scalar_and_varying_struct_p): Delete.
24277         (true_dependence_1, write_dependence_p, may_alias_p): Don't call it.
24278         (true_dependence_1, true_dependence, canon_true_dependence): Remove
24279         varies parameter.
24280         * cselib.c (cselib_rtx_varies_p): Delete.
24281         (cselib_invalidate_mem): Update call to canon_true_dependence.
24282         * dse.c (record_store, check_mem_read_rtx): Likewise.
24283         (scan_reads_nospill): Likewise.
24284         * cse.c (check_dependence): Likewise.
24285         (cse_rtx_varies_p): Delete.
24286         * expr.c (safe_from_p): Update call to true_dependence.
24287         * ira.c (validate_equiv_mem_from_store): Likewise.
24288         (memref_referenced_p): Likewise.
24289         * postreload-gcse.c (find_mem_conflicts): Likewise.
24290         * sched-deps.c (sched_analyze_2): Likewise.
24291         * store-motion.c (load_kills_store): Likewise.
24292         * config/frv/frv.c (frv_registers_conflict_p_1): Likewise.
24293         * gcse.c (mems_conflict_for_gcse_p): Likewise.
24294         (compute_transp): Update call to canon_true_dependence.
24295
24296 2012-01-25  Richard Henderson  <rth@redhat.com>
24297
24298         * optabs.c (CODE_FOR_atomic_test_and_set): Provide default.
24299         (maybe_emit_atomic_test_and_set): New.
24300         (expand_sync_lock_test_and_set): Use it.
24301         (expand_atomic_test_and_set): Likewise.
24302         * doc/extend.texi (__atomic_test_and_set): Adjust the docs to match
24303         the implementation; clarify implementation defined details.
24304         * doc/md.texi (atomic_test_and_set): Document.
24305
24306 2012-01-25  Richard Henderson  <rth@redhat.com>
24307
24308         * config/sparc/predicates.md (zero_or_v7_operand): Use match_code.
24309
24310 2012-01-25  Richard Henderson  <rth@redhat.com>
24311
24312         PR target/51968
24313         * config/arm/arm.c (neon_split_vcombine): Emit deleted note
24314         to effect no-op split.
24315
24316 2012-01-24  Aldy Hernandez  <aldyh@redhat.com>
24317
24318         PR lto/51698
24319         * builtin-types.def: (BT_CONST_DOUBLE_PTR): New.
24320         (BT_FN_VOID_PTR_CONST_PTR_SIZE): New.
24321         (BT_FN_VOID_PTR_INT_SIZE): New.
24322         (BT_FN_UINT_UINT_VAR): Remove.
24323         (BT_FN_UINT32_UINT32_VAR): New.
24324         (BT_FN_DOUBLE_VPTR): Remove.
24325         (BT_FN_DOUBLE_CONST_DOUBLE_PTR): New.
24326
24327         * gtm-builtins.def (_ITM_abortTransaction): Set return type to void.
24328         (_ITM_changeTransactionMode): Same.
24329         (_ITM_memmoveRtWt): Change return type to void.
24330         (_ITM_memcpyRtWt): Same.
24331         (_ITM_memsetW): Same.
24332         (_ITM_RaRD): Change types to double.
24333         (_ITM_RD): Same.
24334         (_ITM_RaWD): Same.
24335         (_ITM_RfWD): Same.
24336
24337         * builtins.def (DEF_TM_BUILTIN): Set BOTH_P to true.
24338
24339 2012-01-24  Aldy Hernandez  <aldyh@redhat.com>
24340             Patrick Marlier  <patrick.marlier@gmail.com>
24341
24342         * trans-mem.c (requires_barrier): Do not instrument thread local
24343         variables and emit save/restore for them.
24344
24345 2012-01-24  Jason Merrill  <jason@redhat.com>
24346
24347         PR c++/51812
24348         * cgraphunit.c (cgraph_decide_is_function_needed): Don't always
24349         output static aliases.
24350
24351 2012-01-24  Jakub Jelinek  <jakub@redhat.com>
24352
24353         PR driver/47249
24354         * common.opt (-pie, -shared, pie, shared): Change from Common to
24355         Driver.
24356         * gcc.c (display_help): Display help for -pie and -shared.
24357
24358 2012-01-24  Georg-Johann Lay  <avr@gjlay.de>
24359
24360         PR target/49868
24361         * doc/extend.texi (AVR Named Address Spaces): Move sample code up.
24362         Remove note on size/offset limitation.
24363         (AVR Variable Attributes): Add example how to read data located
24364         with progmem.  Refer to named address spaces.
24365         * doc/invoke.texi (AVR Options): Fix typo.
24366
24367 2012-01-24  Richard Guenther  <rguenther@suse.de>
24368
24369         Forward-port to trunk
24370         2010-09-21  Jakub Jelinek  <jakub@redhat.com>
24371
24372         PR middle-end/45678
24373         * expr.c (expand_expr_real_1) <case VIEW_CONVERT_EXPR>: If
24374         op0 isn't sufficiently aligned and there is movmisalignM
24375         insn for mode, use it to load op0 into a temporary register.
24376
24377 2012-01-24  Jakub Jelinek  <jakub@redhat.com>
24378
24379         PR target/51957
24380         * target.def (const_not_ok_for_debug_p): New hook.
24381         * doc/tm.texi.in (TARGET_CONST_NOT_OK_FOR_DEBUG_P): New hook
24382         documentation.
24383         * doc/tm.texi: Regenerated.
24384         * dwarf2out.c (const_ok_for_output_1): If
24385         targetm.const_not_ok_for_debug_p returns true, fail.
24386         * config/rs6000/rs6000.c (rs6000_const_not_ok_for_debug_p): New
24387         function.
24388         (TARGET_CONST_NOT_OK_FOR_DEBUG_P): Redefine.
24389
24390 2012-01-23  Kai Tietz  <ktietz@redhat.com>
24391
24392         PR target/51900
24393         * config/i386/predicates.md (symbolic_operand): Allow
24394         UNSPEC_PCREL as PIC expression for lea.
24395         * config/i386/winnt.c (i386_pe_binds_local_p): Reworked.
24396         * config/i386/i386.c (ix86_delegitimize_address): Handle
24397         UNSPEC_PCREL for none-MEM, too.
24398
24399 2012-01-23  Aldy Hernandez  <aldyh@redhat.com>
24400
24401         * trans-mem.c (ipa_tm_create_version): Set externally_visible.
24402         (ipa_tm_create_version_alias): Same.
24403
24404 2012-01-23  Uros Bizjak  <ubizjak@gmail.com>
24405
24406         PR libitm/51830
24407         * builtin-types.def (BT_FN_UINT_UINT_VAR): New.
24408         * gtm-builtins.def (BUILT_IN_TM_START): Declare as BT_FN_UINT_UINT_VAR.
24409
24410 2012-01-23  Aldy Hernandez  <aldyh@redhat.com>
24411             Patrick Marlier  <patrick.marlier@gmail.com>
24412             Iain Sandoe  <developer@sandoe-acoustics.co.uk>
24413
24414         PR lto/51916
24415         * lto-wrapper.c (run_gcc): Pass the LTO section name to
24416         simple_object_start_read.
24417
24418 2012-01-23  Richard Guenther  <rguenther@suse.de>
24419
24420
24421         PR tree-optimization/51895
24422         * tree-sra.c (decide_one_param_reduction): Avoid sub-optimal
24423         parameter decomposition into BLKmode components.
24424
24425 2012-01-23  Eric Botcazou  <ebotcazou@adacore.com>
24426
24427         * tree-ssa-structalias.c (intra_create_variable_infos): Do not create
24428         fake variables for restrict-qualified pointers whose pointed-to type
24429         contains a placeholder.
24430
24431 2012-01-23  Richard Guenther  <rguenther@suse.de>
24432
24433         PR tree-optimization/51949
24434         * ipa-split.c (execute_split_functions): Do not split malloc functions.
24435
24436 2012-01-23  Jakub Jelinek  <jakub@redhat.com>
24437
24438         PR rtl-optimization/51933
24439         * ree.c (transform_ifelse): Return true right away if dstreg is
24440         already wider or equal to cand->mode.
24441         (enum ext_modified_kind, struct ext_modified, ext_state): New types.
24442         (make_defs_and_copies_lists): Remove defs_list and copies_list
24443         arguments, add state argument, just truncate state->work_list
24444         instead of always allocating and freeing the vector.  Assert that
24445         get_defs succeeds instead of returning 2.  Changed return type to bool.
24446         (merge_def_and_ext): Add state argument.  If SET_DEST doesn't
24447         have ext_src_mode, see if it has been modified already with the
24448         right kind of extension and has been extended before from the
24449         ext_src_mode.  If SET_DEST is already wider or equal to cand->mode,
24450         just return true.  Remember the original mode in state->modified array.
24451         (combine_reaching_defs): Add state argument.  Don't allocate and
24452         free here def_list, copied_list and vec vectors, instead just
24453         VEC_truncate the vectors in *state.  Don't handle outcome == 2 here.
24454         (find_and_remove_re): Set DF_DEFER_INSN_RESCAN df flag.
24455         Add state variable, clear vectors in it, initialize state.modified
24456         if needed.  Free all the vectors at the end and state.modified too.
24457         Don't skip a candidate if the extension expression has been modified.
24458
24459 2012-01-22  Douglas B Rupp  <rupp@gnat.com>
24460
24461         PR target/47096
24462         * config.gcc: (i[34567]86-*-interix3*): Remove from obsolete
24463          configurations. Change triplet to i[34567]86-*-interix[3-9]*.
24464         (extra_options) interix.opt -> i386/interix.opt"
24465         (extra_objs):Add winnt-stubs.o
24466         * configure.ac: Add interix to target_os .comm on PE check.
24467         * configure: Regenerate.
24468         * config/interix3.h: Delete and move bits to..
24469         * config/interix.h: Delete and move bits to..
24470         * config/i386/i386-interix3.h: Delete and move bits to..
24471         * config/i386/i386-interix.h: ..here.
24472         (TARGET_CPU_DEFAULT): Remove redefinition.
24473         (TARGET_ASM_CONSTRUCTOR): Undefine.
24474         (SUBTARGET_SWITCHES): Define for ms-bitfields.
24475         (TARGET_OS_CPP_BUILTINS): Remove __OPENNT. Add __declspec.
24476         (PTRDIFF_TYPE): Define.
24477         (LONG_DOUBLE_TYPE_SIZE): Define.
24478         (LIBGCC2_LONG_DOUBLE_TYPE_SIZE): Define.
24479         (SUBTARGET_OVERRIDE_OPTIONS): Remove.
24480         (TARGET_SECTION_TYPE_FLAGS): Define.
24481         (ASM_DECLARE_FUNCTION_NAME): Define.
24482         (ASM_OUTPUT_EXTERNAL): Define.
24483         (ASM_OUTPUT_EXTERNAL_LIBCALL): Define.
24484         (ASM_OUTPUT_ALIGNED_BSS): Define.
24485         (PCC_BITFIELD_TYPE_MATTERS): Define.
24486         (USE_CONST_SECTION): Define.
24487         (SUBTARGET_ENCODE_SECTION_INFO): Remove.
24488         (TARGET_ASM_FUNCTION_RODATA_SECTION): Remove.
24489         (SUPPORTS_ONE_ONLY): Remove.
24490         (I386_PE_STRIP_ENCODING): Define.
24491         * config/interix.opt: Delete and move bits to..
24492         * config/i386/interix.opt: ..here. New.
24493         (mpe-aligned-commons): Add.
24494         * config/i386/t-interix: Add copyright header.
24495         (winnt-stubs.o): Add rule.
24496
24497 2012-01-22  Jason Merrill  <jason@redhat.com>
24498
24499         PR c++/51832
24500         * varpool.c (varpool_analyze_pending_decls): Copy DECL_EXTERNAL
24501         for extra name aliases.
24502
24503 2012-01-22  Eric Botcazou  <ebotcazou@adacore.com>
24504
24505         PR rtl-optimization/51924
24506         * ree.c (combine_set_extension): Improve debugging message.
24507         (combine_reaching_defs): Likewise.
24508         (get_defs): Rename confusingly named variable.
24509         (find_and_remove_re): Skip a candidate if the extension expression has
24510         been modified.
24511
24512 2012-01-21  Robert Millan  <rmh@gnu.org>
24513             Gerald Pfeifer  <gerald@pfeifer.com>
24514
24515         * config/kfreebsd-gnu.h (GNU_USER_DYNAMIC_LINKERX32): New macro.
24516         (GNU_USER_DYNAMIC_LINKER): Adjust indentation.
24517
24518 2012-01-20  Jakub Jelinek  <jakub@redhat.com>
24519
24520         PR tree-optimization/51914
24521         * tree-vect-stmts.c (vectorizable_conversion): For
24522         cvt_type && modifier == WIDEN, put temporary with cvt_type
24523         at the beginning of vec_dsts and set vec_dest to temporary
24524         with vectype_out.
24525
24526 2012-01-20  Eric Botcazou  <ebotcazou@adacore.com>
24527
24528         * cfgrtl.c (rtl_dump_bb): Do not dump insns for {ENTRY|EXIT}_BLOCK.
24529
24530 2012-01-20  Tijl Coosemans  <tijl@coosemans.org>
24531
24532         * config/i386/i386.c: Fix checks for !TARGET_MACHO.
24533         * config/rs6000/rs6000.c: Likewise.
24534
24535 2012-01-20  Jakub Jelinek  <jakub@redhat.com>
24536
24537         PR target/51915
24538         * config/arm/arm.c (arm_count_output_move_double_insns): Call
24539         output_move_double on a copy of operands array.
24540
24541 2012-01-20  Cary Coutant  <ccoutant@google.com>
24542             Dodji Seketeli  <dodji@redhat.com>
24543
24544         PR debug/45682
24545         * dwarf2out.c (copy_declaration_context): Return ref to parent
24546         of declaration DIE, if necessary.
24547         (remove_child_or_replace_with_skeleton): Add new parameter; update
24548         caller.  Place skeleton DIE under parent DIE of original declaration.
24549         Move call to copy_declaration_context to here ...
24550         (break_out_comdat_types): ... from here.
24551
24552 2012-01-20  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
24553
24554         PR rtl-optimization/51856
24555         * reload.c (find_reloads_subreg_address): Set the address_reloaded
24556         flag to reloaded.
24557
24558 2012-01-20  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
24559
24560         PR target/51819
24561         * config/arm/arm.c (arm_print_operand): Correct output of alignment
24562         hints for neon loads and stores.
24563
24564 2012-01-20  Georg-Johann Lay  <avr@gjlay.de>
24565
24566         PR target/49868
24567         PR target/50887
24568         * doc/extend.texi (Named Address Spaces): Split into subsections.
24569         (AVR Named Address Spaces): New subsection.
24570         (M32C Named Address Spaces): New subsection.
24571         (RL78 Named Address Spaces): New subsection.
24572         (SPU Named Address Spaces): New subsection.
24573         (Variable Attributes): New anchor "AVR Variable Attributes".
24574         (AVR Variable Attributes): Rewrite and avoid wording
24575         "address space" in this context.
24576         * doc/invoke.texi (AVR Options): Rewrite and add documentation
24577         for -maccumulate-args, -mbranch-cost=, -mrelax, -mshort-calls.
24578         (AVR Built-in Macros): New subsubsection therein.
24579         * doc/md.texi (AVR constraints): Remove "C04", "R".
24580
24581 2012-01-20  Richard Guenther  <rguenther@suse.de>
24582
24583         PR tree-optimization/51903
24584         * tree-ssa-pre.c (eliminate): Properly purging of EH edges
24585         when removing stmts.
24586
24587 2012-01-20  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
24588
24589         PR target/50313
24590         * config/arm/arm.c (arm_load_pic_register): Use
24591         gen_pic_load_addr_unified. Delete calls to gen_pic_load_addr_32bit
24592         , gen_pic_add_dot_plus_eight and gen_pic_add_dot_plus_four.
24593         (arm_pic_static_addr): Likewise.
24594         (arm_rtx_costs_1): Adjust cost for UNSPEC_PIC_UNIFIED.
24595         (arm_note_pic_base): Handle UNSPEC_PIC_UNIFIED.
24596         * config/arm/arm.md (UNSPEC_PIC_UNIFIED): Define.
24597         (pic_load_addr_unified): New.
24598
24599 2012-01-20  Andrey Belevantsev  <abel@ispras.ru>
24600
24601         PR target/51106
24602         * function.c (instantiate_virtual_regs_in_insn): Use
24603         delete_insn_and_edges when removing a wrong asm insn.
24604
24605 2012-01-19  Vladimir Makarov  <vmakarov@redhat.com>
24606
24607         PR rtl-optimization/40761
24608         * ira-int.h (struct ira_loop_tree_node): Add comment for member loop.
24609         Add new member loop_num.
24610         (IRA_LOOP_NODE_BY_INDEX): Modify the check.
24611         (ira_build): Remove the parameter.
24612
24613         * ira.c (ira_print_disposition): Use loop_num instead of loop->num.
24614         (ira.c): Do not build CFG loops for one region allocation.  Remove
24615         argument from ira_build call.
24616
24617         * ira-build.c (init_loop_tree_node): New function.
24618         (create_loop_tree_nodes): Use it.  Separate the case when CFG
24619         loops are not built.
24620         (more_one_region_p): Check current_loops.
24621         (finish_loop_tree_nodes): Separate the case when CFG loops are not
24622         built.
24623         (add_loop_to_tree): Process loop equal to NULL too.
24624         (form_loop_tree): Separate the case when CFG loops are not built.
24625         Use explicitly number for the root.
24626         (rebuild_regno_allocno_maps, create_loop_tree_node_allocnos): Add
24627         an assertion.
24628         (ira_print_expanded_allocno, loop_compare_func): Use loop_num
24629         instead of loop->num.
24630         (mark_loops_for_removal): Ditto.  Use loop_num instead of loop->num.
24631         (mark_all_loops_for_removal): Ditto.
24632         (remove_unnecessary_regions): Separate the case when CFG loops
24633         are not built.
24634         (ira_build): Remove the parameter.  Use explicit number of regions
24635         when CFG loops are not built.
24636
24637         * ira-color.c (print_loop_title): Separate the case for the root node.
24638         Use loop_num instead of loop->num.
24639         (move_spill_restore): Use loop_num instead of loop->num.
24640
24641         * ira-emit.c (setup_entered_from_non_parent_p): Add an assertion.
24642         (change_loop): Ditto.
24643         (change_loop): Use loop_num instead of loop->num.
24644
24645         * ira-lives.c (process_bb_node_lives): Ditto.
24646
24647         * ira-costs.c (print_allocno_costs, find_costs_and_classes): Ditto.
24648
24649         * ira-conflicts.c (print_allocno_conflicts): Ditto.
24650
24651 2012-01-19  Jakub Jelinek  <jakub@redhat.com>
24652
24653         PR libmudflap/40778
24654         * tree-mudflap.c (mf_artificial): New function.
24655         (execute_mudflap_function_ops, execute_mudflap_function_decls,
24656         mx_register_decls, mudflap_enqueue_decl): Use it.
24657
24658         PR target/51876
24659         * config/arm/neon.md (*neon_vswp<mode>): Fix up operand
24660         numbers in the insn pattern.
24661
24662 2012-01-19  Michael Matz  <matz@suse.de>
24663
24664         PR tree-optimization/46590
24665         * cfgexpand.c (add_scope_conflicts_1): New old_conflicts argument,
24666         use it in remembering which conflicts we already created.
24667         (add_scope_conflicts): Adjust call to above, (de)allocate helper
24668         bitmap.
24669
24670 2012-01-19  Aldy Hernandez  <aldyh@redhat.com>
24671
24672         PR lto/51280
24673         * lto-wrapper.c (run_gcc): Pass -fgnu_tm on.
24674         (merge_and_complain): Same.
24675
24676 2012-01-19  Jakub Jelinek  <jakub@redhat.com>
24677
24678         PR bootstrap/50237
24679         * config/initfini-array.h: Guard content of the header
24680         with #ifdef HAVE_INITFINI_ARRAY.
24681         * configure.ac: Move gcc_AC_INITFINI_ARRAY much later into the file.
24682         Add initfini-array.h to tm_file here.
24683         * acinclude.m4 (gcc_AC_INITFINI_ARRAY): For non-ia64 do a linker test.
24684         * config.gcc: Don't add initfini-array.h to tm_file here.
24685         * configure: Regenerated.
24686
24687 2012-01-19  Andrey Belevantsev  <abel@ispras.ru>
24688
24689         PR rtl-optimization/51505
24690         * df-problems.c (df_kill_notes): New parameter live. Update comment.
24691         Remove REG_EQUAL/REG_EQUIV notes referring to dead registers.
24692         (df_note_bb_compute): Update the call to df_kill_notes.
24693
24694 2012-01-18  Aldy Hernandez  <aldyh@redhat.com>
24695
24696         * trans-mem.c (requires_barrier): Remove call to is_global_var.
24697
24698 2012-01-18  Richard Guenther  <rguenther@suse.de>
24699
24700         * tree-ssa.c (useless_type_conversion_p): Remove special-casing
24701         of conversions to void *.
24702
24703 2012-01-17  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
24704             Richard Sandiford  <rdsandiford@googlemail.com>
24705
24706         PR middle-end/50325
24707         PR middle-end/51192
24708         * optabs.h (simplify_expand_binop): Declare.
24709         * optabs.c (simplify_expand_binop): Make global.
24710         * expmed.c (store_bit_field_1): Use simplify_expand_binop on big
24711         endian targets if the source cannot be exactly covered by word
24712         mode chunks.
24713
24714 2012-01-17  Jakub Jelinek  <jakub@redhat.com>
24715
24716         PR bootstrap/51872
24717         * hard-reg-set.h (struct hard_reg_set_container): New type.
24718         * target.h (struct hard_reg_set_container): Forward declare.
24719         * target.def (set_up_by_prologue): New target hook.
24720         * doc/tm.texi.in (TARGET_SET_UP_BY_PROLOGUE): Document it.
24721         * doc/tm.texi: Regenerated.
24722         * function.c (thread_prologue_and_epilogue_insns): Change
24723         set_up_by_prologue HARD_REG_SET into struct hard_reg_set_container.
24724         Call targetm.set_up_by_prologue on it.
24725         * config/rs6000/rs6000.c (rs6000_set_up_by_prologue): New function.
24726         (TARGET_SET_UP_BY_PROLOGUE): Redefine to it.
24727
24728 2012-01-17  Nick Clifton  <nickc@redhat.com>
24729
24730         * config/rx/rx.c (rx_can_use_simple_return): New function.
24731         * config/rx/rx-protos.h (rx_can_use_simple_return): Prototype.
24732         * config/rx/rx.md (return): Predicate on rx_can_use_simple_return.
24733
24734 2012-01-17  Richard Guenther  <rguenther@suse.de>
24735
24736         PR middle-end/51782
24737         * expr.c (expand_assignment): Take address-space information
24738         from the address operand of MEM_REF and TARGET_MEM_REF.
24739         (expand_expr_real_1): Likewise.
24740
24741 2012-01-17  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
24742
24743         * ira.c (do_reload): Make sure ira_dump_file is re-set if no
24744         reload dump is requested.
24745
24746 2012-01-17  Aldy Hernandez  <aldyh@redhat.com>
24747
24748         PR other/51165
24749         * trans-mem.c (requires_barrier): Call may_be_aliased.
24750
24751 2012-01-17  Jakub Jelinek  <jakub@redhat.com>
24752
24753         PR tree-optimization/51877
24754         * tree-ssa-tail-merge.c (gimple_equal_p): Don't return true whenever
24755         call arguments and fndecls compare equal, instead return false if they
24756         don't.  Return true only if lhs1 and lhs2 are either both NULL, or
24757         both SSA_NAMEs that are valueized the same, or they satisfy
24758         operand_equal_p.
24759
24760 2012-01-17  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
24761
24762         * configure.ac (gcc_cv_target_dl_iterate_phdr): Only check on
24763         Solaris 11+.
24764         * configure: Regenerate.
24765
24766 2012-01-16  Jan Hubicka  <jh@suse.cz>
24767
24768         PR c/12245
24769         PR c++/14179
24770         * convert.c (convert_to_integer): Use fold_convert for
24771         converting an INTEGER_CST to integer type.
24772
24773 2012-01-16  Jason Merrill  <jason@redhat.com>
24774
24775         PR c++/14179
24776         * vec.c (vec_gc_o_reserve_1): Use ggc_round_alloc_size.
24777
24778 2012-01-16  Jakub Jelinek  <jakub@redhat.com>
24779
24780         PR bootstrap/51860
24781         * config/s390/s390.c (s390_chunkify_start): Don't skip
24782         call insns followed by NOTE_INSN_CALL_ARG_LOCATION note.  Skip
24783         NOTE_INSN_VAR_LOCATION and NOTE_INSN_CALL_ARG_LOCATION notes.
24784         If insn is followed by NOTE_INSN_VAR_LOCATION or
24785         NOTE_INSN_CALL_ARG_LOCATION notes, insert jump after all those notes.
24786         Don't use location of note insns.
24787
24788         PR tree-optimization/51865
24789         * tree-inline.c (tree_function_versioning): Call remap_decl
24790         on DECL_RESULT whenever it has VOID_TYPE_P type.
24791
24792 2012-01-15  Richard Sandiford  <rdsandiford@googlemail.com>
24793
24794         * config/mips/mips.c (mips16_build_call_stub): Don't use a stub
24795         for calls to locally-binding MIPS16 functions if only the return
24796         type uses float regs.
24797
24798 2012-01-15  Chung-Lin Tang  <cltang@codesourcery.com>
24799             Richard Sandiford  <rdsandiford@googlemail.com>
24800
24801         * config/mips/mips-protos.h (SYMBOL_FORCE_TO_MEM): Delete.
24802         (SYMBOL_32_HIGH): Likewise.
24803         (mips_output_tls_reloc_directive): Declare.
24804         * config/mips/mips.h (PIC_FUNCTION_ADDR_REGNUM): Move to mips.md.
24805         (mips_use_pcrel_pool_p, mips_lo_relocs, mips_hi_relocs): Declare.
24806         * config/mips/mips.c (mips_use_pcrel_pool_p): New variable.
24807         (mips_lo_relocs, mips_hi_relocs): Make extern.
24808         (mips16_stub_function): Move up file.
24809         (mips_classify_symbol): Remove SYMBOL_FORCE_TO_MEM handling.
24810         (mips_symbolic_constant_p): Likewise.  Remove SYMBOL_32_HIGH too.
24811         (mips_symbol_insns_1): Likewise.  Check mips_use_pcrel_pool_p.
24812         (mips_cannot_force_const_mem): Use mips_use_pcrel_pool_p instead of
24813         SYMBOL_FORCE_TO_MEM.  Only check mips_tls_symbol_ref_1 if it's false.
24814         (mips_get_tp): Add MIPS16 support.
24815         (mips_legitimize_tls_address): Remove MIPS16 sorry().
24816         Generalize DTPREL and TPREL handling.
24817         (mips_init_relocs): Initialize mips_use_pcrel_pool_p.
24818         Add MIPS16 TLS support.
24819         (mips_output_tls_reloc_directive): New function.
24820         (mips16_rewrite_pool_refs): Ignore UNSPEC_TLS_GET_TPs.
24821         * config/mips/predicates.md (symbolic_operand_with_high)
24822         (tls_reloc_operand): New predicates.
24823         (force_to_mem_operand): Use mips_use_pcrel_pool_p.
24824         * config/mips/mips.md (UNSPEC_UNSHIFTED_HIGH): New unspec.
24825         (PIC_FUNCTION_ADDR_REGNUM): Moved from mips.h.
24826         (*unshifted_high): New instruction.  Use it for MIPS16 high splitter.
24827         (consttable_tls_reloc, tls_get_tp_mips16_<mode>): New patterns.
24828         (*tls_get_tp_mips16_call_<mode>): Likewise.
24829
24830 2012-01-15  Uros Bizjak  <ubizjak@gmail.com>
24831
24832         PR rtl-optimization/51821
24833         * recog.c (peep2_find_free_register): Determine clobbered registers
24834         from insn pattern.
24835
24836 2012-01-14  Denis Chertykov  <chertykov@gmail.com>
24837
24838         PR target/50925
24839         * config/avr/avr-protos.h: Revert change of 2012-01-09.
24840         * config/avr/avr.c: Likewise.
24841         * config/avr/avr.h: Likewise.
24842
24843 2012-01-13  Ian Lance Taylor  <iant@google.com>
24844
24845         PR c++/50012
24846         * tree.h (TYPE_QUALS): Add cast to int.
24847         (TYPE_QUALS_NO_ADDR_SPACE): Likewise.
24848
24849 2012-01-13  Ian Lance Taylor  <iant@google.com>
24850
24851         * ipa-cp.c (ipa_get_indirect_edge_target): Add typecasts when
24852         comparing param_index to VEC_length result.
24853
24854 2012-01-13  Steven Bosscher  <steven@gcc.gnu.org>
24855
24856         * c-decl.c: Do not include tree-mudflap.h
24857         * tree-optimize.c: Likewise.
24858         * Makefile.in: Update dependencies.
24859
24860 2012-01-13  Richard Guenther  <rguenther@suse.de>
24861
24862         PR middle-end/8081
24863         * gimplify.c (gimplify_modify_expr_rhs): For calls with a
24864         variable-sized result always use RSO.
24865
24866 2012-01-12  DJ Delorie  <dj@redhat.com>
24867
24868         * cfgexpand.c (convert_debug_memory_address): Allow any valid
24869         pointer type, not just the default pointer type.
24870
24871 2012-01-09  Richard Henderson  <rth@redhat.com>
24872             Denis Chertykov  <chertykov@gmail.com>
24873
24874         PR target/50925
24875         * config/avr/avr-protos.h (avr_hard_regno_nregs): Declare.
24876         * config/avr/avr.c (avr_can_eliminate): Simplify.
24877         (avr_initial_elimination_offset): Likewise.
24878         (avr_prologue_setup_frame): Use hard_frame_pointer_rtx.
24879         (expand_epilogue): Likewise.
24880         (avr_legitimize_address): Gut.
24881         (avr_legitimize_reload_address): Use hard_frame_pointer_rtx.
24882         (avr_hard_regno_nregs): New.
24883         (avr_hard_regno_ok): Allow only Pmode for arg and frame_pointers.
24884         (avr_regno_mode_code_ok_for_base_b): Handle arg and frame pointers.
24885         * config/avr/avr.h (FIXED_REGISTERS): Adjust arg pointer,
24886         add soft frame pointer.
24887         (CALL_USED_REGISTERS): Likewise.
24888         (REG_CLASS_CONTENTS): Likewise.
24889         (REGISTER_NAMES): Likewise.
24890         (HARD_REGNO_NREGS): Use avr_hard_regno_nregs.
24891         (HARD_FRAME_POINTER_REGNUM): New.
24892         (FRAME_POINTER_REGNUM): Use soft frame pointer.
24893         (ELIMINABLE_REGS): Eliminate from the soft frame pointer,
24894         remove the HARD_FRAME_POINTER self-elimination.
24895
24896 2012-01-12  Georg-Johann Lay  <avr@gjlay.de>
24897
24898         PR target/51756
24899         * config/avr/avr.c (avr_encode_section_info): Test for absence of
24900         DECL_EXTERNAL when checking for initializers of progmem variables.
24901
24902 2012-01-12  Ira Rosen  <irar@il.ibm.com>
24903
24904         PR tree-optimization/51799
24905         * tree-vect-patterns.c (vect_recog_over_widening_pattern): Check
24906         that the last operation is a type demotion.
24907
24908 2012-01-12  Uros Bizjak  <ubizjak@gmail.com>
24909
24910         * config/i386/i386.md (*zero_extendsidi2_rex64): Correct movl template.
24911         (x86_shift<mode>_adj_1): Remove operand constraint from operand 3.
24912
24913 2012-01-11  Jakub Jelinek  <jakub@redhat.com>
24914
24915         PR bootstrap/51796
24916         * combine.c (distribute_notes): If i3 is a noreturn call,
24917         allow old_size to be equal to args_size and make sure the
24918         noreturn call gets REG_ARGS_SIZE note.
24919         * expr.c (fixup_args_size_notes): Put REG_ARGS_SIZE notes
24920         on noreturn calls even when the delta is 0.
24921
24922 2012-01-11  Nathan Sidwell  <nathan@acm.org>
24923
24924         * gcov.c (STRING_SIZE): Remove.
24925         (generate_results): Erase annotations for source files with no
24926         coverage information.
24927         (read_line): New.
24928         (output_lines): Use it.
24929
24930 2012-01-11  Eric Botcazou  <ebotcazou@adacore.com>
24931
24932         * gimple.h (gimplify_body): Remove first argument.
24933         * gimplify.c (copy_if_shared): Add DATA argument.  Do not create the
24934         pointer set here, instead just pass DATA to walk_tree.
24935         (unshare_body): Remove BODY_P argument and adjust.  Create the pointer
24936         set here and invoke copy_if_shared on the size trees of DECL_RESULT.
24937         (unvisit_body): Likewise, but with unmark_visited.
24938         (gimplify_body): Remove BODY_P argument and adjust.
24939         (gimplify_function_tree): Adjust call to gimplify_body.
24940         * omp-low.c (finalize_task_copyfn): Likewise.
24941
24942 2012-01-11  Eric Botcazou  <ebotcazou@adacore.com>
24943
24944         * tree.h (build_function_decl_skip_args): Add boolean parameter.
24945         (build_function_type_skip_args): Delete.
24946         * tree.c (build_function_type_skip_args): Make static and add
24947         SKIP_RETURN parameter.  Fix thinko in the handling of variants.
24948         (build_function_decl_skip_args): Add SKIP_RETURN parameter and
24949         pass it to build_function_type_skip_args.
24950         * cgraph.h (cgraph_function_versioning): Add boolean parameter.
24951         (tree_function_versioning): Likewise.
24952         * cgraph.c (cgraph_create_virtual_clone): Adjust call to
24953         build_function_decl_skip_args.
24954         * cgraphunit.c (cgraph_function_versioning): Add SKIP_RETURN parameter
24955         and pass it to build_function_decl_skip_args/tree_function_versioning.
24956         (cgraph_materialize_clone): Adjust call to tree_function_versioning.
24957         * ipa-inline-transform.c (save_inline_function_body): Likewise.
24958         * trans-mem.c (ipa_tm_create_version): Likewise.
24959         * tree-sra.c (modify_function): Ditto for cgraph_function_versioning.
24960         * tree-inline.c (declare_return_variable): Remove always-true test.
24961         (tree_function_versioning): Add SKIP_RETURN parameter.  If the function
24962         returns non-void and SKIP_RETURN, create a void-typed RESULT_DECL.
24963         * ipa-split.c (split_function): Skip the return value for the split
24964         part if it doesn't return.
24965
24966 2012-01-11  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
24967
24968         PR tree-optimization/49642
24969         * ipa-split.c (forbidden_dominators): New variable.
24970         (check_forbidden_calls): New function.
24971         (dominated_by_forbidden): Likewise.
24972         (consider_split): Check for forbidden dominators.
24973         (execute_split_functions): Initialize and free forbidden
24974         dominators info; call check_forbidden_calls.
24975
24976 2012-01-11  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
24977
24978         * config/arm/arm.md (mov_notscc): Use MVN for false condition.
24979
24980 2012-01-11  Nick Clifton  <nickc@redhat.com>
24981
24982         * config/rx/rx.md (return): Define pattern.
24983
24984 2012-01-11  Richard Guenther  <rguenther@suse.de>
24985
24986         * doc/extend.texi (malloc attribute): Adjust according to
24987         implementation.
24988
24989 2012-01-10  Aldy Hernandez  <aldyh@redhat.com>
24990             Patrick Marlier  <patrick.marlier@gmail.com>
24991
24992         PR middle-end/51516
24993         * trans-mem.c (get_cg_data): Traverse aliases if requested.
24994         (ipa_tm_scan_calls_block): Update parameters to get_cg_data.
24995         (ipa_tm_note_irrevocable): Same.
24996         (ipa_tm_scan_irr_block): Same.
24997         (ipa_tm_decrement_clone_counts): Same.
24998         (ipa_tm_scan_irr_function): Same.
24999         (ipa_tm_create_version_alias): Same.
25000         (ipa_tm_create_version): Same.
25001         (ipa_tm_transform_calls_redirect): Same.
25002         (ipa_tm_transform_calls): Same.
25003         (ipa_tm_transform_transaction): Same.
25004         (ipa_tm_execute): Same.
25005
25006 2012-01-10  Richard Guenther  <rguenther@suse.de>
25007
25008         PR middle-end/51806
25009         * opts.c (common_handle_option): Handle -Werror.
25010
25011 2012-01-10  Andreas Schwab  <schwab@linux-m68k.org>
25012
25013         * config/m68k/sync.md ("atomic_compare_and_swap<mode>_1"): Fix
25014         operand number.
25015
25016 2012-01-10  Jason Merrill  <jason@redhat.com>
25017
25018         * doc/invoke.texi (C++ Dialect Options): Update -fabi-version=6
25019         information.
25020
25021 2012-01-10  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
25022
25023         * configure.ac (gcc_cv_as_ix86_tlsgdplt): Check if linker
25024         supports R_386_TLS_GD_PLT reloc.
25025         (gcc_cv_as_ix86_tlsldmplt): Check if linker
25026         supports R_386_TLS_LDM_PLT reloc.
25027         * configure: Regenerate.
25028         * config.in: Regenerate.
25029
25030 2012-01-10  Georg-Johann Lay  <avr@gjlay.de>
25031
25032         PR target/49868
25033         Extend __pgmx semantics to linearize memory.
25034         * config/avr/avr.md (mov<mode>): Use avr_xload_libgcc_p to
25035         determine if code comes inline or from libgcc.
25036         (MOVMEM_r_d:HI): Add "w" to constraint for better preference.
25037         (movmem_qi, movmem_qi): Set constraint #2 to "n".
25038         (movmem_qi_elpm, movmem_hi_elpm): Remove insns.
25039         (movmemx_qi, movmemx_hi): New insns.
25040         (xload_<mode>_libgcc): Rewrite to new insn condition.
25041         (xload_<mode>): Remove insns.
25042         * config/avr/avr.c (avr_out_xload): Rewrite: Only need to handle
25043         cases that don't satisfy avr_xload_libgcc_p().
25044         (avr_addr_space_convert): Allow converting in any direction.
25045         (avr_addr_space_subset_p): Return always true.
25046         (avr_xload_libgcc_p): Rewrite to fit new __pgmx semantics.
25047         (avr_emit_movmemhi): Ditto.
25048         (avr_out_lpm): No need to handle ADDR_SPACE_PGMX any more.
25049         (avr_out_movmem): Ditto.
25050         (AVR_SYMBOL_FLAG_PROGMEM): New macro.
25051         (AVR_SYMBOL_SET_ADDR_SPACE): New macro.
25052         (AVR_SYMBOL_GET_ADDR_SPACE): New macro.
25053         (avr_encode_section_info): Encode 'progmem' in symbol flags.
25054         (output_reload_in_const): Don't zero-extend any 24-bit symbols.
25055
25056 2012-01-10  Richard Guenther  <rguenther@suse.de>
25057
25058         PR tree-optimization/50913
25059         * graphite-scop-detection.c (stmt_has_simple_data_refs_p):
25060         Require data-refs to be representable by Graphite with respect
25061         to any loop nest.
25062
25063 2012-01-10  Uros Bizjak  <ubizjak@gmail.com>
25064
25065         * config/i386/constraints.md ("L"): Return true for 0xffffffff.
25066         * config/i386/i386.c (*anddi_1): Emit AND with 0xffffffff as MOV.
25067
25068 2012-01-10  Tom de Vries  <tom@codesourcery.com>
25069
25070         PR rtl-optimization/51271
25071         * dwarf2cfi.c (scan_trace): Save and restore cur_row->reg_save when
25072         handling annulled branch.
25073
25074 2012-01-10  Richard Henderson  <rth@redhat.com>
25075
25076         * config/arm/arm.c (arm_vectorize_vec_perm_const_ok,
25077         TARGET_VECTORIZE_VEC_PERM_CONST_OK, neon_split_vcombine, MAX_VECT_LEN,
25078         struct expand_vec_perm_d, arm_expand_vec_perm_1, arm_expand_vec_perm,
25079         arm_evpc_neon_vuzp, arm_evpc_neon_vzip, arm_evpc_neon_vrev,
25080         arm_evpc_neon_vtrn, arm_evpc_neon_vtbl, arm_expand_vec_perm_const_1,
25081         arm_expand_vec_perm_const): New.
25082         * config/arm/arm-protos.h: Update.
25083         * config/arm/neon.md (UNSPEC_VCONCAT): New.
25084         (*neon_vswp<VDQX>): New.
25085         (neon_vcombine<VDX>): Use neon_split_vcombine.
25086         (neon_vtbl1v16qi, neon_vtbl2v16qi, neon_vcombinev16qi): New.
25087         * config/arm/vec-common.md (vec_perm_const<VALL>): New.
25088         (vec_perm<VE>): New.
25089
25090 2012-01-10  Richard Henderson  <rth@redhat.com>
25091
25092         * config/arm/arm.c (arm_gen_compare_reg): Add scratch argument;
25093         use it if reload_completed.
25094         (arm_legitimize_sync_memory, arm_emit, arm_insn_count, arm_count,
25095         arm_output_asm_insn, arm_process_output_memory_barrier,
25096         arm_output_memory_barrier, arm_ldrex_suffix, arm_output_ldrex,
25097         arm_output_strex, arm_output_it, arm_output_op2, arm_output_op3,
25098         arm_output_sync_loop, arm_get_sync_operand, FETCH_SYNC_OPERAND,
25099         arm_process_output_sync_insn, arm_output_sync_insn,
25100         arm_sync_loop_insns, arm_call_generator, arm_expand_sync): Remove.
25101         (arm_pre_atomic_barrier, arm_post_atomic_barrier): New.
25102         (arm_emit_load_exclusive, arm_emit_store_exclusive): New.
25103         (emit_unlikely_jump): New.
25104         (arm_expand_compare_and_swap, arm_split_compare_and_swap): New.
25105         (arm_split_atomic_op): New.
25106         * config/arm/arm-protos.h: Update.
25107         * config/arm/arm.h (enum arm_sync_generator_tag): Remove.
25108         (struct arm_sync_generator): Remove.
25109         * config/arm/arm.md (VUNSPEC_SYNC_COMPARE_AND_SWAP, VUNSPEC_SYNC_LOCK,
25110         VUNSPEC_SYNC_OP, VUNSPEC_SYNC_NEW_OP, VUNSPEC_SYNC_OLD_OP): Remove.
25111         (VUNSPEC_ATOMIC_CAS, VUNSPEC_ATOMIC_XCHG, VUNSPEC_ATOMIC_OP): New.
25112         (VUNSPEC_LL, VUNSPEC_SC): New.
25113         (sync_result, sync_memory, sync_required_value, sync_new_value,
25114         sync_t1, sync_t2, sync_release_barrier, sync_op): Remove.
25115         (attr length): Don't use arm_sync_loop_insns.
25116         (cbranch_cc, cstore_cc): Update call to arm_gen_compare_reg.
25117         (movsfcc, movdfcc): Likewise.
25118         * config/arm/constraints.md (Ua): New.
25119         * config/arm/prediates.md (mem_noofs_operand): New.
25120         (sync_compare_and_swap<QHSD>, sync_lock_test_and_set<QHSD>): Remove.
25121         (sync_clobber, sync_t2_reqd): Remove.
25122         (sync_<syncop><QHSD>, sync_nand<QHSD>): Remove.
25123         (sync_new_<syncop><QHSD>, sync_new_nand<QHSD>): Remove.
25124         (sync_old_<syncop><QHSD>, sync_old_nand<QHSD>): Remove.
25125         (arm_sync_compare_and_swap<SIDI>): Remove.
25126         (arm_sync_compare_and_swap<NARROW>): Remove.
25127         (arm_sync_lock_test_and_set<SIDI>): Remove.
25128         (arm_sync_lock_test_and_set<NARROW>): Remove.
25129         (arm_sync_new_<syncop><SIDI>): Remove.
25130         (arm_sync_new_<syncop><NARROW>): Remove.
25131         (arm_sync_new_nand<SIDI>): Remove.
25132         (arm_sync_new_nand<NARROW>): Remove.
25133         (arm_sync_old_<syncop><SIDI>): Remove.
25134         (arm_sync_old_<syncop><NARROW>): Remove.
25135         (arm_sync_old_nand<SIDI>): Remove.
25136         (arm_sync_old_nand<NARROW>): Remove.
25137         (*memory_barrier): Merge arm_output_memory_barrier.
25138         (atomic_compare_and_swap<QHSD>): New.
25139         (atomic_compare_and_swap<NARROW>_1): New.
25140         (atomic_compare_and_swap<SIDI>_1): New.
25141         (atomic_exchange<QHSD>): New.
25142         (cas_cmp_operand, cas_cmp_str): New.
25143         (atomic_op_operand, atomic_op_str): New.
25144         (atomic_<syncop><QHSD>, atomic_nand<QHSD>): New.
25145         (atomic_fetch_<syncop><QHSD>, atomic_fetch_nand<QHSD>): New.
25146         (atomic_<syncop>_fetch<QHSD>, atomic_nand_fetch<QHSD>): New.
25147         (arm_load_exclusive<NARROW>): New.
25148         (arm_load_exclusivesi, arm_load_exclusivedi): New.
25149         (arm_store_exclusive<QHSD>): New.
25150
25151 2012-01-09  Michael Meissner  <meissner@linux.vnet.ibm.com>
25152
25153         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Add DF
25154         reload patterns if -mvsx-scalar-memory.
25155
25156         * config/rs6000/vsx.md (vsx_xscvspdp): Allow xscvspdp to be
25157         generated, even -mno-vsx-scalar-double was used.
25158         (vsx_xscvdpsp_scalar): Likewise.
25159         (vsx_xscvspdp_scalar2): Likewise.
25160
25161 2012-01-09  Tom de Vries  <tom@codesourcery.com>
25162             Andrew Pinski  <apinski@cavium.com>
25163
25164         PR debug/51471
25165         * reorg.c (fill_slots_from_thread): Don't speculate
25166         frame-related insns.
25167
25168 2012-01-09  Richard Sandiford  <rdsandiford@googlemail.com>
25169
25170         * sched-int.h (bb_note): Move to...
25171         * basic-block.h: ...here.
25172         * haifa-sched.c (bb_note): Move to...
25173         * cfgrtl.c: ...here.
25174         * function.c (next_block_for_reg): New function.
25175         (move_insn_for_shrink_wrap): Likewise.
25176         (prepare_shrink_wrap): Rewrite to use the above.
25177
25178 2012-01-09  Aldy Hernandez  <aldyh@redhat.com>
25179
25180         * gimple.c (is_gimple_non_addressable): Remove.
25181         * gimple.h: Remove is_gimple_non_addressable.
25182         * gimplify.c (gimplify_modify_expr_rhs): Use is_gimple_reg instead of
25183         is_gimple_non_addressable.
25184         * trans-mem.c (expand_assign_tm): Same.
25185
25186 2012-01-09  Richard Guenther  <rguenther@suse.de>
25187
25188         PR tree-optimization/51775
25189         * tree-ssa-sccvn.c (visit_use): Value-number throwing stmts.
25190         * tree-ssa-pre.c (eliminate): Properly fixup EH info.
25191
25192 2012-01-09  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
25193
25194         * config/arm/arm-cores.def (cortex-a15): Use cortex_a15_tune for
25195         tuning parameters.
25196         * config/arm/arm.c (arm_cortex_a15_tune): New static variable.
25197
25198 2012-01-09  Richard Guenther  <rguenther@suse.de>
25199
25200         * tree-streamer-out.c (write_ts_optimization): Fix spelling.
25201
25202 2012-01-08  Jan Hubicka  <jh@suse.cz>
25203
25204         PR tree-optimize/51680
25205         * ipa-inline-analyss.c (evaluate_properties_for_edge): Fix condition
25206         on when known_vals needs to be computed; cleanup.
25207
25208 2012-01-08  Jan Hubicka  <jh@suse.cz>
25209
25210         PR tree-optimize/51694
25211         * ipa-cp.c (ipa_get_indirect_edge_target): Add bounds checks.
25212
25213 2012-01-08  Jonathan Wakely  <jwakely.gcc@gmail.com>
25214
25215         * doc/cpp.texi (Predefined Macros): __STRICT_ANSI__ is defined
25216         for -std=c++98 and -std=c++11 too.
25217
25218 2012-01-08  Chung-Lin Tang  <cltang@codesourcery.com>
25219
25220         * cfgloop.c (cancel_loop): Add free() of bbs array.
25221
25222 2012-01-07  Jan Hubicka  <jh@suse.cz>
25223
25224         PR tree-optimization/51600
25225         * ipa-inline-analysis.c (estimate_edge_devirt_benefit): Disable code
25226         that benefits small functions.
25227
25228 2012-01-07  Jan Hubicka  <jh@suse.cz>
25229
25230         * ipa-inline.c (want_inline_small_function_p): Fix formating.
25231
25232 2012-01-07  Jan Hubicka  <jh@suse.cz>
25233
25234         PR tree-optimization/51680
25235         * ipa-inline.c (want_inline_small_function_p): Be more lax on functions
25236         whose inlining reduce unit size.
25237
25238 2012-01-07  Alexandre Oliva  <aoliva@redhat.com>
25239
25240         PR bootstrap/51725
25241         * cselib.c (new_elt_loc_list): Promote addr_list to canonical node.
25242         Add canonical node to containing_mem chain after the non-canonical
25243         one, even if there weren't any locs to propagate.
25244         (remove_useless_values): Keep only canonical values.
25245         (add_mem_for_addr, cselib_lookup_mem): Canonicalize addr.
25246         (cselib_invalidate_mem): Likewise.  Ensure v is canonical, and
25247         canonicalize mem_chain elements that are not discarded.
25248
25249 2012-01-06  Jakub Jelinek  <jakub@redhat.com>
25250
25251         PR target/47333
25252         * cgraphunit.c (cgraph_optimize): Call output_weakrefs
25253         before emitting functions.
25254
25255         PR gcov-profile/50127
25256         * bb-reorder.c (partition_hot_cold_basic_blocks): Call
25257         clear_aux_for_blocks.
25258
25259 2012-01-06  Alexandre Oliva  <aoliva@redhat.com>
25260
25261         PR debug/51746
25262         * cselib.c (cselib_hash_rtx): Hash incoming VALUEs too.
25263
25264 2012-01-06  Arnaud Charlet  <charlet@adacore.com>
25265
25266         * c-decl.c (ext_block): Moved up.
25267         (collect_all_refs, for_each_global_decl): Take ext_block into account.
25268
25269 2012-01-06  Han Shen  <shenhan@google.com>
25270
25271         Translate built-in include paths for sysroot.
25272         * Makefile.in (gcc_gxx_include_dir_add_sysroot): New.
25273         (PREPROCESSOR_DEFINES): Define GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT.
25274
25275         * cppdefault.c (cpp_include_defaults): Replace hard coded "0" with
25276         GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT for "add_sysroot" field.
25277
25278         * configure.ac (AC_SUBST): Add gcc_gxx_include_dir_add_sysroot to
25279         control whether sysroot should be prepended to gxx include dir.
25280
25281         * configure: Regenerate.
25282
25283 2012-01-06  Torvald Riegel  <triegel@redhat.com>
25284
25285         PR rtl-optimization/51771
25286         * builtin-attrs.def (ATTR_RETURNS_TWICE, ATTR_TM_NOTHROW_RT_LIST): New.
25287         * gtm-builtins.def (BUILT_IN_TM_START): Add returns-twice attrib.
25288
25289 2012-01-05  Eric Botcazou  <ebotcazou@adacore.com>
25290
25291         PR tree-optimization/51315
25292         * tree-sra.c (tree_non_aligned_mem_for_access_p): New predicate.
25293         (build_accesses_from_assign): Use it instead of tree_non_aligned_mem_p.
25294
25295 2012-01-05  Uros Bizjak  <ubizjak@gmail.com>
25296
25297         PR target/51681
25298         * config/ia64/ia64.c (expand_vec_perm_shrp): Use correct operands
25299         for shrp pattern.  Correctly handle and fixup shift variable.
25300         Return false when shift > nelt for BYTES_BIG_ENDIAN target.
25301
25302 2012-01-05  Jakub Jelinek  <jakub@redhat.com>
25303
25304         PR debug/51762
25305         * calls.c (emit_call_1): For noreturn calls force a REG_ARGS_SIZE
25306         note when !ACCUMULATE_OUTGOING_ARGS.
25307
25308 2012-01-05  Eric Botcazou  <ebotcazou@adacore.com>
25309
25310         * tree-vrp.c (extract_range_from_binary_expr_1): Remove duplicated
25311         condition.
25312         (extract_range_from_unary_expr_1): Avoid useless computations.
25313
25314 2012-01-05  Jakub Jelinek  <jakub@redhat.com>
25315
25316         PR rtl-optimization/51767
25317         * cfgrtl.c (force_nonfallthru_and_redirect): Force addition
25318         of jump_block and add an extra edge for degenerated asm gotos.
25319
25320         PR middle-end/51768
25321         * stmt.c (check_unique_operand_names): Don't ICE during error
25322         reporting if i is from labels chain.
25323
25324         PR middle-end/44777
25325         * profile.c (branch_prob): Split bbs that have exit edge
25326         and need a fake entry edge too.
25327
25328 2012-01-05  Jan Hubicka  <jh@suse.cz>
25329
25330         PR middle-end/49710
25331         * cfgloopmanip.c (remove_path): Walk loop hiearchy upwards when
25332         unlooping loops.
25333
25334 2012-01-05  Richard Guenther  <rguenther@suse.de>
25335
25336         PR lto/50490
25337         * tree-streamer-out.c (write_ts_optimization): New function.
25338         (streamer_write_tree_body): Call it.
25339         * tree-streamer-in.c (lto_input_ts_optimization): New function.
25340         (streamer_read_tree_body): Call it.
25341         * lto-streamer-out.c (lto_is_streamable): Handle OPTIMIZATION_NODE.
25342
25343 2012-01-05  Jakub Jelinek  <jakub@redhat.com>
25344
25345         PR middle-end/51761
25346         * gimple.h (struct gimplify_ctx): Add in_cleanup_point_expr field.
25347         * gimplify.c (gimplify_cleanup_point_expr): Save and set
25348         in_cleanup_point_expr before gimplify_stmt call and restore it
25349         afterwards.
25350         (gimplify_target_expr): Don't add {CLOBBER} cleanup if
25351         in_cleanup_point_expr is false.
25352
25353 2012-01-05  Richard Guenther  <rguenther@suse.de>
25354
25355         PR middle-end/51764
25356         * common.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move
25357         to c.opt.
25358         * toplev.c (process_options): Reject combining mudflap and LTO.
25359         * tree-nomudflap.c (nogo): Use sorry instead of internal_error.
25360
25361 2012-01-05  Richard Guenther  <rguenther@suse.de>
25362
25363         PR tree-optimization/51760
25364         * tree-ssa-ccp.c (likely_value): Drop UNDEFINED to CONSTANT,
25365         not VARYING.
25366         (bit_value_unop): Handle UNDEFINED operands.
25367         (bit_value_binop): Likewise.
25368
25369 2012-01-05  Georg-Johann Lay  <avr@gjlay.de>
25370
25371         * config/avr/avr.c (avr_replace_prefix): Remove.
25372         (avr_asm_named_section): Use ACONCAT instead of avr_replace_prefix.
25373         (avr_asm_function_rodata_section): Ditto.
25374         (avr_asm_select_section): Ditto.
25375
25376 2012-01-05  Marcus Shawcroft  <marcus.shawcroft@arm.com>
25377
25378         * reload.c (find_reloads): Adjust LABEL_NUSES on REG_LABEL_OPERAND
25379         insertion.
25380
25381 2012-01-05  Jakub Jelinek  <jakub@redhat.com>
25382
25383         PR bootstrap/51648
25384         * tree-cfg.c (need_fake_edge_p): Return true also for noreturn
25385         calls that have any non-fake successor edges.
25386
25387         PR debug/51746
25388         * var-tracking.c (add_stores): For COND_EXEC allow oval to be NULL.
25389
25390 2012-01-04  Eric Botcazou  <ebotcazou@adacore.com>
25391
25392         PR tree-optimization/51624
25393         * tree-sra.c (build_ref_for_model): When replicating a chain of
25394         COMPONENT_REFs, stop as soon as the offset would become negative.
25395
25396 2012-01-04  Jakub Jelinek  <jakub@redhat.com>
25397
25398         PR debug/51695
25399         * dwarf2out.c (output_loc_list): For now drop >= 64KB expressions
25400         in .debug_loc on the floor.
25401
25402 2012-01-04  Andrew Pinski  <apinski@cavium.com>
25403
25404         * doc/invoke.texi (-march=@var{arch}): Add octeon+ and octeon2.
25405
25406 2012-01-04  Andrew Pinski  <apinski@cavium.com>
25407             Adam Nemet  <anemet@caviumnetworks.com>
25408
25409         * config/mips/mips.md (size): Add SI and DI.
25410         (SIZE): New mode attribute.
25411         (U): New code attribute.
25412         * config/mips/mips-dsp.md (mips_lbux): Use gen_mips_lbux_extsi.
25413         (mips_lbux_<mode>): Delete.
25414         (mips_l<SHORT:size><u>x_ext<GPR:mode>_<P:mode>): New pattern.
25415         (mips_lhx): Use gen_mips_lhx_extsi.
25416         (mips_lhx_<mode>): Delete.
25417         (mips_lwx): Delete.
25418         (mips_l<size>x): New expand.
25419         (mips_lwx_<mode>): Delete.
25420         (mips_l<GPR:size>x_<P:mode>): New pattern.
25421         (*mips_lw<u>x_<P:mode>_ext): Likewise.
25422         * config/mips/mips-ftypes.def: Add DI f(POINTER, SI) function type.
25423         * config/mips/mips.c (mips_lx_address_p): New function.
25424         (mips_rtx_costs <case MEM>): Call mips_lx_address_p.
25425         (dsp64): New availability predicate.
25426         (mips_builtins): Add an entry for __builtin_mips_ldx.
25427         * config/mips/mips.h (ISA_HAS_LBX): New define.
25428         (ISA_HAS_LBUX): Likewise.
25429         (ISA_HAS_LHX): Likewise.
25430         (ISA_HAS_LHUX): Likewise.
25431         (ISA_HAS_LWX): Likewise.
25432         (ISA_HAS_LWUX): Likewise.
25433         (ISA_HAS_LDX): Likewise.
25434         * doc/extend.texi (__builtin_mips_ldx): Document.
25435
25436 2012-01-04  Tristan Gingold  <gingold@adacore.com>
25437
25438         * config/vms/xm-vms.h (HOST_LONG_FORMAT, HOST_PTR_PRINTF): Define
25439         when long pointers are used.
25440         * config.build (*-*-*vms*): Handle all OpenVMS targets.
25441         (alpha64-dec-*vms*, alpha*-dec-*vms*)
25442         (ia64-hp-*vms*): Remove.
25443         * config/vms/xm-vms64.h: Delete.
25444
25445 2012-01-04  Aldy Hernandez  <aldyh@redhat.com>
25446
25447         PR middle-end/51472
25448         * trans-mem.c (expand_assign_tm): Handle TM_MEMMOVE loads correctly.
25449
25450 2012-01-04  Aldy Hernandez  <aldyh@redhat.com>
25451
25452         * opts.c (finish_options): Remove duplicate sorry.
25453
25454 2012-01-04  Aldy Hernandez  <aldyh@redhat.com>
25455
25456         PR middle-end/51696
25457         * trans-mem.c (diagnose_tm_1): Display indirect calls with no name
25458         correctly.
25459
25460 2012-01-04  Richard Guenther  <rguenther@suse.de>
25461
25462         PR middle-end/51750
25463         * tree.c (size_low_cst): New function.
25464         * tree.h (size_low_cst): Declare.
25465         * fold-const.c (fold_comparison): Use it to extract the low
25466         part of the POINTER_PLUS_EXPR offset.
25467
25468 2012-01-04  Georg-Johann Lay  <avr@gjlay.de>
25469
25470         Fix clearing ZERO_REG
25471         * config/avr/avr.md (cc): Add alternative "ldi".
25472         (movqi_insn): Use it in cc attribute.
25473         * config/avr/avr.c (notice_update_cc): Handle CC_LDI.
25474         (output_reload_in_const): Use CLR to move 0 to ZERO_REG.
25475         (output_reload_insisf): Use ZERO_REG to pre-clear register.
25476
25477 2012-01-04  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
25478
25479         * configure: Regenerate.
25480
25481 2012-01-04  Richard Guenther  <rguenther@suse.de>
25482
25483         PR tree-optimization/49651
25484         * tree-ssa-structalias.c (type_can_have_subvars): New function.
25485         (var_can_have_subvars): Use it.
25486         (get_constraint_for_1): Only consider subfields if there can be any.
25487
25488 2012-01-03  Jakub Jelinek  <jakub@redhat.com>
25489
25490         PR bootstrap/51725
25491         * cselib.c (new_elt_loc_list): When moving locs from one cselib_val
25492         to its new canonical_cselib_val and the cselib_val was in
25493         first_containing_mem chain, but the canonical_cselib_val was not,
25494         add the latter into the chain.
25495         (cselib_invalidate_mem): Compare canonical_cselib_val of
25496         addr_list chain elt with v.
25497
25498         PR pch/51722
25499         * dwarf2out.c (dwarf2out_start_source_file, dwarf2out_define,
25500         dwarf2out_undef): Allocate e.info using ggc_strdup instead
25501         of xstrdup.
25502         (output_macinfo_op): Don't ggc_strdup fd->filename.
25503         (optimize_macinfo_range): Allocate grp_name using XALLOCAVEC,
25504         then ggc_strdup it.  Don't free inc->info or cur->info.
25505         (output_macinfo): Don't free ref->info or file->info.
25506
25507 2012-01-03  Ira Rosen  <irar@il.ibm.com>
25508
25509         PR tree-optimization/51269
25510         * tree-vect-loop-manip.c (set_prologue_iterations): Make
25511         first_niters a pointer.
25512         (slpeel_tree_peel_loop_to_edge): Likewise.
25513         (vect_do_peeling_for_loop_bound): Update call to
25514         slpeel_tree_peel_loop_to_edge.
25515         (vect_gen_niters_for_prolog_loop): Don't compute wide_prolog_niters
25516         here.  Remove it from the parameters list.
25517         (vect_do_peeling_for_alignment): Update calls and compute
25518         wide_prolog_niters.
25519
25520 2012-01-03  Richard Guenther  <rguenther@suse.de>
25521
25522         PR tree-optimization/51070
25523         * tree-loop-distribution.c (stmt_has_scalar_dependences_outside_loop):
25524         Properly handle calls.
25525
25526 2012-01-03  Richard Guenther  <rguenther@suse.de>
25527
25528         PR tree-optimization/51692
25529         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Do not remove
25530         the LHS of allocation stmts.
25531
25532 2012-01-03  Olivier Hainque  <hainque@adacore.com>
25533
25534         * system.h: Prior to #define, #undef fopen and freopen unconditionally.
25535
25536 2012-01-03  Olivier Hainque  <hainque@adacore.com>
25537
25538         * collect2.c (main): In AIX specific computations for vector
25539         insertions, use CONST_CAST2 to cast from char ** to const char **.
25540
25541 2012-01-03  Richard Guenther  <rguenther@suse.de>
25542
25543         PR debug/51650
25544         * dwarf2out.c (dwarf2out_finish): Always create a DIE for
25545         the context of a limbo DIE when it does not already exist.
25546
25547 2012-01-03  Jakub Jelinek  <jakub@redhat.com>
25548
25549         PR tree-optimization/51719
25550         * value-prof.c (gimple_ic): When indirect call isn't noreturn,
25551         but direct call is, clear direct call's lhs and don't add fallthrough
25552         edge from dcall_bb to join_bb and PHIs.
25553
25554 2012-01-03  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
25555
25556         * config/s390/s390.md ("*cmp<mode>_ccs"): Fix comment mentioning
25557         the instructions emitted by the pattern.
25558         ("*TDC_insn_<mode>"): Add comment.
25559
25560 2012-01-03  Richard Guenther  <rguenther@suse.de>
25561
25562         PR middle-end/51730
25563         * fold-const.c (fold_comparison): Properly canonicalize
25564         tree offset and HOST_WIDE_INT bit position.
25565
25566 2012-01-02  Uros Bizjak  <ubizjak@gmail.com>
25567
25568         * config/ia64/ia64.c (expand_vec_perm_broadcast): Use correct
25569         operands for extzv pattern.
25570
25571 2012-01-02  Jakub Jelinek  <jakub@redhat.com>
25572
25573         PR bootstrap/51725
25574         * cselib.c (add_mem_for_addr): Call canonical_cselib_val
25575         on mem_elt first.
25576
25577 2012-01-02  Sandra Loosemore  <sandra@codesourcery.com>
25578
25579         * doc/invoke.texi (-flto and related options): Copy-edit.
25580
25581 2012-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
25582
25583         * config/mips/mips.md (loadgp_newabi_<mode>): Add missing earlyclobber.
25584
25585 2012-01-02  Jakub Jelinek  <jakub@redhat.com>
25586
25587         * config/i386/sse.md (*avx2_gatherdi<mode>_3, *avx2_gatherdi<mode>_4):
25588         New patterns.
25589
25590 2012-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
25591
25592         * expr.h (move_by_pieces_ninsns): Declare.
25593         * expr.c (move_by_pieces_ninsns): Make external.
25594         * config/mips/mips-protos.h (mips_move_by_pieces_p): Declare.
25595         (mips_store_by_pieces_p): Likewise.
25596         * config/mips/mips.h (MOVE_BY_PIECES_P): Call mips_move_by_pieces_p.
25597         (STORE_BY_PIECES_P): Likewise mips_store_by_pieces_p.
25598         * config/mips/mips.c (mips_move_by_pieces_p): New function.
25599         (mips_store_by_pieces_p): Likewise.
25600
25601 2012-01-02  Jakub Jelinek  <jakub@redhat.com>
25602
25603         * passes.c (register_one_dump_file): Free full_name.
25604
25605         * reload1.c (reload): Don't allocate reg_max_ref_width here.
25606         (calculate_elim_costs_all_insns): Free offsets_at and
25607         offsets_known_at at the end and clear the pointers.
25608
25609 2012-01-02  Georg-Johann Lay  <avr@gjlay.de>
25610
25611         * config/avr/avr.opt (-mbranch-cost): Fix double definition of
25612         this option introduced in r180739.
25613
25614 2012-01-02  Georg-Johann Lay  <avr@gjlay.de>
25615
25616         PR target/51345
25617         * config.gcc (tm_file target=avr]): Add avr/avr-multilib.h
25618         (tmake_file target=avr): Add avr/t-multilib.
25619
25620         * config/avr/avr-c.c (avr_cpu_cpp_builtins): Use AVR_HAVE_8BIT_SP
25621         to built-in define __AVR_HAVE_8BIT_SP__, __AVR_HAVE_16BIT_SP__.
25622         * config/avr/genmultilib.awk: New file.
25623         * config/avr/t-multilib: New auto-generated file.
25624         * config/avr/multilib.h: New auto-generated file.
25625         * config/avr/t-avr (AVR_MCUS): New variable.
25626         (genopt.sh): Use it.
25627         (s-mlib): Depend on t-multilib.
25628         (t-multilib, multilib.h): New dependencies.
25629         (s-avr-mlib): New rule to build t-multilib, multilib.h from AVR_MCUS.
25630         (MULTILIB_OPTIONS): Remove.
25631         (MULTILIB_MATCHES): Remove.
25632         (MULTILIB_DIRNAMES): Remove.
25633         (MULTILIB_EXCEPTIONS): Remove:
25634         * config/avr/genopt.sh: Don't use hard coded file name;
25635         pass AVR_MCUS from t-avr instead.
25636
25637 2012-01-02  Georg-Johann Lay  <avr@gjlay.de>
25638
25639         * config/avr/avr.c (avr_out_ashrpsi3): Fix "case 31" to "case 23".
25640
25641 2012-01-02  Georg-Johann Lay  <avr@gjlay.de>
25642
25643         Implement light-weight DImode support.
25644         * config/avr/avr-dimode.md: New file.
25645         * config/avr/avr.md: Include it.
25646         (adjust_len): Add plus64, compare64.
25647         (HIDI): Remove code iterator.
25648         (code_stdname): New code attribute.
25649         (rotx, rotsmode): Remove DI.
25650         (rotl<mode>3, *rotw<mode>, *rotb<mode>): Use HISI instead of HIDI
25651         as code iterator.
25652         * config/avr/avr-protos.h (avr_have_dimode): New.
25653         (avr_out_plus64, avr_out_compare64): New.
25654         * config/avr/avr.c (avr_out_compare): Handle DImode.
25655         (avr_have_dimode): New variable definition and initialization.
25656         (avr_out_compare64, avr_out_plus64): New functions.
25657         (avr_out_plus_1): Use simplify_unary_operation to negate xval.
25658         (adjust_insn_length): Handle ADJUST_LEN_COMPARE64, ADJUST_LEN_PLUS64.
25659         (avr_compare_pattern): Skip DImode comparisons.
25660
25661 2012-01-02  Revital Eres  <revital.eres@linaro.org>
25662
25663         * ddg.c (def_has_ccmode_p): New function.
25664         (add_cross_iteration_register_deps,
25665         create_ddg_dep_from_intra_loop_link): Call it.
25666
25667 2012-01-02  Richard Guenther  <rguenther@suse.de>
25668
25669         PR other/51679
25670         * invoke.texi (fassociative-math): Remove spurious paranthesis.
25671
25672 2012-01-01  Jakub Jelinek  <jakub@redhat.com>
25673
25674         * gcc.c (process_command): Update copyright notice dates.
25675         * gcov.c (print_version): Likewise.
25676         * gcov-dump.c (print_version): Likewise.
25677         * mips-tfile.c (main): Likewise.
25678         * mips-tdump.c (main): Likewise.
25679
25680 2012-01-01  Ira Rosen  <irar@il.ibm.com>
25681
25682         PR tree-optimization/51704
25683         * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Check that
25684         a use is inside the basic block or loop before accessing its vect info.
25685
25686 2012-01-01  Jan Hubicka  <jhjh@suse.cz>
25687
25688         PR rtl-optimization/51069
25689         * cfgloopmanip.c (remove_path): Removing path making irreducible
25690         region unconditional makes BB part of the region.
25691
25692 2012-01-01  Jakub Jelinek  <jakub@redhat.com>
25693
25694         PR tree-optimization/51683
25695         * tree-ssa-propagate.c (substitute_and_fold): Don't optimize away
25696         calls with side-effects.
25697         * tree-ssa-ccp.c (ccp_fold_stmt): Likewise.
25698 \f
25699 Copyright (C) 2012 Free Software Foundation, Inc.
25700
25701 Copying and distribution of this file, with or without modification,
25702 are permitted in any medium without royalty provided the copyright
25703 notice and this notice are preserved.