OSDN Git Service

2011-12-19 Martin Jambor <mjambor@suse.cz>
[pf3gnuchains/gcc-fork.git] / gcc / ChangeLog
1 2011-12-19  Martin Jambor  <mjambor@suse.cz>
2
3         PR tree-optimization/51583
4         * tree-sra.c (load_assign_lhs_subreplacements): Call
5         force_gimple_operand_gsi when necessary also in case of no
6         corresponding replacement on the RHS.
7
8 2011-12-19  Jakub Jelinek  <jakub@redhat.com>
9
10         * gimple.h (gimplify_seq_add_stmt): Rename to...
11         (gimple_seq_add_stmt_without_update): ... this.
12         * gimplify.c (gimplify_seq_add_stmt): Rename to...
13         (gimple_seq_add_stmt_without_update): ... this.
14         (gimplify_seq_add_stmt): New inline wrapper for it.
15         * tree-vect-patterns.c (append_pattern_def_seq): Use
16         gimple_seq_add_stmt_without_update instead of gimplify_seq_add_stmt.
17
18         PR tree-optimization/51596
19         * tree-cfg.c (replace_uses_by): Call gimple_purge_dead_eh_edges
20         when needed.
21
22         PR middle-end/51590
23         PR tree-optimization/51606
24         * tree-vect-patterns.c (append_pattern_def_seq, new_pattern_def_seq):
25         New inline functions.
26         (vect_recog_over_widening_pattern,
27         vect_recog_vector_vector_shift_pattern,
28         vect_recog_sdivmod_pow2_pattern, vect_recog_mixed_size_cond_pattern,
29         adjust_bool_pattern_cast, vect_recog_bool_pattern): Use them.
30
31 2011-12-19  Richard Guenther  <rguenther@suse.de>
32
33         PR lto/51572
34         * tree.c (free_lang_data_in_type): Do not unlink TYPE_DECL
35         from TYPE_FIELDS.
36         (find_decls_types_r): Walk TYPE_DECLs in TYPE_FIELDS.
37         * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Do
38         not stream TREE_CHAIN.
39         (write_ts_type_non_common_tree_pointers): Stream TYPE_FIELDS
40         using streamer_write_chain.
41         * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
42         Do not stream TREE_CHAIN.
43         (lto_input_ts_type_non_common_tree_pointers): Stream TYPE_FIELDS
44         using streamer_read_chain.
45         * gimple-streamer-in.c (input_gimple_stmt): Skip non-FIELD_DECLs.
46         * gimple.c (gimple_canonical_types_compatible_p): Properly
47         handle trailing non-FIELD_DECLs in TYPE_FIELDS.
48
49 2011-12-19  Andreas Schwab  <schwab@linux-m68k.org>
50
51         * configure: Regenerate.
52
53 2011-12-19  Bernd Schmidt  <bernds@codesourcery.com>
54
55         * emit-rtl.c (init_emit_once): Initialize const_tiny_rtx[3] for
56         partial integer modes.
57
58 2011-12-19  Andreas Schwab  <schwab@linux-m68k.org>
59
60         PR target/51532
61         * config/m68k/m68k.h (FL_CAS, TARGET_CAS): Define.
62         * config/m68k/m68k.c (FL_FOR_isa_20): Add FL_CAS.
63         * config/m68k/sync.md: Use TARGET_CAS instead of (TARGET_68020 ||
64         TARGET_68040).
65
66 2011-12-18  Anatoly Sokolov  <aesok@post.ru>
67
68         * config/ia64/ia64.h (REG_OK_FOR_BASE_P, REG_OK_FOR_INDEX_P,
69         LEGITIMATE_ADDRESS_REG, LEGITIMATE_ADDRESS_DISP,
70         GO_IF_LEGITIMATE_ADDRESS): Remove macros.
71         * config/ia64/ia64.c (TARGET_LEGITIMATE_ADDRESS_P): Define.
72         (ia64_reg_ok_for_base_p, ia64_legitimate_address_reg,
73         ia64_legitimate_address_disp, ia64_legitimate_address_p): New
74         functions.
75
76 2011-12-17  Tom de Vries  <tom@codesourcery.com>
77
78         PR tree-optimization/51491
79         * tree-ssa-ccp.c (insert_clobber_before_stack_restore)
80         (gsi_prev_dom_bb_nondebug, insert_clobbers_for_var): New function.
81         (ccp_fold_stmt): Use insert_clobbers_for_var after a successful
82         fold_builtin_alloca_with_align.
83         (ccp_visit_stmt): Calculate and free dominator info.
84
85 2011-12-16  Eric Botcazou  <ebotcazou@adacore.com>
86
87         * config/sparc/sparc.md (UNSPEC_FRAME_BLOCKAGE): New constant.
88         (frame_blockage): New expander.
89         (frame_blockage<P:mode>): New instruction.
90         * config/sparc/sparc.c (sparc_expand_prologue): When the sequence of
91         instructions establishing the frame isn't atomic, emit frame blockage.
92
93 2011-12-16  Tristan Gingold  <gingold@adacore.com>
94
95         * config/alpha/vms.h (USE_TM_CLONE_REGISTRY): Define.
96
97 2011-12-16  Tristan Gingold  <gingold@adacore.com>
98
99         * config/alpha/alpha.c (alpha_use_linkage): Follow transparent alias.
100         (alpha_write_one_linkage): Use assemble_name to emit linkage name.
101
102 2011-12-16  Tristan Gingold  <gingold@adacore.com>
103
104         * config/vms/t-vms (vms.o, vms-c.o): Force output filename.
105
106 2011-12-16  Tristan Gingold  <gingold@adacore.com>
107
108         * config/vms/vms.c (VMS_CRTL_GLOBAL): Define.
109         (vms_patch_builtins): Handle.
110         * config/vms/vms-crtlmap.map: Add an entry for environ.
111
112 2011-12-16  Jakub Jelinek  <jakub@redhat.com>
113
114         PR debug/51557
115         * sel-sched-ir.c (create_copy_of_insn_rtx): Copy all notes
116         other than REG_EQUAL, REG_EQUIV and REG_LABEL_OPERAND.
117
118         PR tree-optimization/51576
119         * tree-cfg.c (replace_uses_by): Call maybe_clean_or_replace_eh_stmt
120         even if fold_stmt didn't change anything.
121
122 2011-12-16  Richard Guenther  <rguenther@suse.de>
123
124         PR lto/51572
125         * dwarf2out.c (gen_type_die_with_usage): Use the context of
126         the TYPE_DECL as well if it is file-scope.
127
128 2011-12-15  DJ Delorie  <dj@redhat.com>
129
130         * config/rl78/rl78.md (return): Rename to rl78_return.
131         * config/rl78/rl78.c (rl78_expand_epilogue): Use new name.
132         (rl78_expand_eh_epilogue): Use new name.
133         (rl78_calculate_death_notes): Likewise.
134
135 2011-12-15  Jakub Jelinek  <jakub@redhat.com>
136
137         * tree-vectorizer.h (struct _stmt_vec_info): Remove pattern_def_stmt
138         field, add pattern_def_seq.
139         (STMT_VINFO_PATTERN_DEF_STMT): Remove.
140         (STMT_VINFO_PATTERN_DEF_SEQ): Define.
141         (NUM_PATTERNS): Bump to 10.
142         * tree-vect-loop.c (vect_determine_vectorization_factor,
143         vect_transform_loop): Adjust for pattern def changing from a single
144         gimple stmt to gimple_seq.
145         * tree-vect-stmts.c (vect_analyze_stmt, new_stmt_vec_info,
146         free_stmt_vec_info): Likewise.
147         * tree-vect-patterns.c (vect_recog_over_widening_pattern,
148         vect_recog_vector_vector_shift_pattern,
149         vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast,
150         adjust_bool_pattern, vect_mark_pattern_stmts): Likewise.
151         (vect_recog_sdivmod_pow2_pattern): New function.
152         (vect_vect_recog_func_ptrs): Add it.
153
154         * config/i386/sse.md (vcond<V_256:mode><VI_256:mode>,
155         vcond<V_128:mode><VI124_128:mode>, vcond<VI8F_128:mode>v2di):
156         Use general_operand instead of nonimmediate_operand for
157         operand 5 and no predicate for operands 1 and 2.
158         * config/i386/i386.c (ix86_expand_int_vcond): Optimize
159         x < 0 ? -1 : 0 and x < 0 ? 1 : 0 into vector arithmetic
160         resp. logical shift.
161
162 2011-12-15  Georg-Johann Lay  <avr@gjlay.de>
163
164         * config/avr/avr-protos.h (print_operand): Remove.
165         (print_operand_address): Remove.
166         * config/avr/avr.h (PRINT_OPERAND): Remove.
167         (PRINT_OPERAND_ADDRESS): Remove.
168         (PRINT_OPERAND_PUNCT_VALID_P): Remove.
169         * config/avr/avr.c (TARGET_PRINT_OPERAND): New hook define.
170         (TARGET_PRINT_OPERAND_ADDRESS): New hook define.
171         (TARGET_PRINT_OPERAND_PUNCT_VALID_P): New hook define.
172         (print_operand_address): Rename to...
173         (avr_print_operand_address): ...this and make static.
174         (print_operand): Rename to...
175         (avr_print_operand): ...this and make static.
176         (avr_print_operand_punct_valid_p): New static function.
177
178 2011-12-15  Andreas Tobler  <andreast@fgznet.ch>
179
180         * config/i386/freebsd.h (TARGET_ASM_FILE_END): Define.
181
182 2011-12-15  Jakub Jelinek  <jakub@redhat.com>
183
184         PR c/51360
185         * c-parser.c (c_parser_omp_clause_num_threads,
186         c_parser_omp_clause_schedule): Call mark_exp_read.
187
188 2011-12-15  Romain Geissler  <romain.geissler@gmail.com>
189
190         * builtins.def (BUILT_IN_STPNCPY_CHK): New definition.
191         * builtins.c (expand_builtin, fold_builtin_4, maybe_emit_chk_warning):
192         Add BUILT_IN_STPNCPY_CHK case.
193         * gimple-fold.c (gimple_fold_builtin): Likewise.
194         * tree-object-size.c (pass_through_call): Likewise.
195         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1,
196         call_may_clobber_ref_p_1): Likewise.
197         * tree-ssa-structalias.c (find_func_aliases_for_builtin_call,
198         find_func_clobbers): Likewise.
199         * tree.h (fold_builtin_strncpy_chk): Rename to fold_builtin_stxncpy_chk
200         * builtins.c (fold_builtin_strncpy_chk): Likewise.
201         Rewrite stpncpy_chk calls to strncpy_chk calls if returned value is
202         ignored.
203
204 2011-12-15  Richard Guenther  <rguenther@suse.de>
205
206         PR lto/51567
207         * gimple.c (compare_type_names_p): Also compare the TREE_CODE.
208         (iterative_hash_name): Also hash the TREE_CODE.
209         (gimple_types_compatible_p_1): For types with a TYPE_DECL
210         name and a type DECL_CONTEXT recurse to that type.
211         (iterative_hash_gimple_type): Likewise.
212
213 2011-12-15  Iain Sandoe  <iains@gcc.gnu.org>
214
215         * config/rs6000/rs6000.c  (rs6000_emit_prologue): Move update of
216         VRSave mask to save_world() when that is in use.
217
218 2011-12-15  Richard Guenther  <rguenther@suse.de>
219
220         * lto-wrapper.c (run_gcc): In non-parallel mode remove
221         ltrans inputs immediately after processing them.  In parallel
222         mode truncate the ltrans inputs in the make rule that processes
223         them if temporary files are not to be preserved.
224
225 2011-12-15  Anatoly Sokolov  <aesok@post.ru>
226
227         * config/arm/arm.h (REGISTER_MOVE_COST, MEMORY_MOVE_COST): Remove.
228         * config/arm/arm.c (arm_memory_move_cost, arm_register_move_cost):
229         New functions.
230         (TARGET_REGISTER_MOVE_COST, TARGET_MEMORY_MOVE_COST): Define.
231
232 2011-12-15  Richard Guenther  <rguenther@suse.de>
233
234         PR lto/51564
235         * tree.h (REGISTER_DEFS_IN_THIS_STMT, NECESSARY,
236         STMT_IN_SSA_EDGE_WORKLIST): Remove no longer existing flag
237         uses documentation.
238         (TREE_ASM_WRITTEN): Update documentation to mention its use
239         on TYPE_DECLs from debug info generation.
240         * tree-streamer-out.c (pack_ts_base_value_fields): Stream
241         TREE_ASM_WRITTEN as always zero for TYPE_DECLs, similar to
242         all other types.
243
244 2011-12-15  Georg-Johann Lay  <avr@gjlay.de>
245
246         PR target/51050
247         * config/avr/avr.c (expand_epilogue): Don't build SUBREG of fp.
248         (avr_prologue_setup_frame): Ditto.
249
250 2011-12-15  Jakub Jelinek  <jakub@redhat.com>
251
252         PR debug/51517
253         * tree-ssa-coalesce.c (coalesce_ssa_name): For !optimize, test
254         !DECL_IGNORED_P instead of !DECL_ARTIFICIAL.
255
256 2012-12-15  Richard Guenther  <rguenther@suse.de>
257
258         Revert
259         PR lto/48437
260         * lto-streamer-out.c (tree_is_indexable): Exclude block-local
261         extern declarations.
262
263         PR lto/48508
264         PR lto/48437
265         * tree-streamer-out.c (streamer_write_chain): Stream DECL_EXTERNAL
266         VAR_DECLs and FUNCTION_DECLs locally.
267
268 2011-12-14  Richard Henderson  <rth@redhat.com>
269
270         * config/arm/arm.md (*addsi3_compare0_scratch): Set predicable.
271         (*compare_negsi_si, *compare_addsi2_op0): Likewise.
272         (*compare_addsi2_op1, *zeroextractsi_compare0_scratch): Likewise.
273         (*compareqi_eq0, *arm_cmpsi_insn, *arm_cmpsi_negshiftsi_si): Likewise.
274
275 2011-12-14  Richard Guenther  <rguenther@suse.de>
276
277         * tree-cfg.c (replace_uses_by): Fixup TREE_CONSTANT for
278         propagating all kinds of constants.
279
280 2011-12-14  Richard Guenther  <rguenther@suse.de>
281
282         PR lto/51497
283         * lto-streamer-in.c (lto_read_body): Fixup local types
284         TYPE_CANONICAL and variant chain.
285
286 2011-12-14  Richard Guenther  <rguenther@suse.de>
287
288         * tree.c (free_lang_data_in_type): Do not clear fields
289         dependent on debuginfo level setting.
290         (find_decls_types_r): Use TYPE_STUB_DECL rathern than TREE_CHAIN.
291         * tree.h (TYPE_STUB_DECL): Properly check that we access a type.
292
293 2011-12-14  Georg-Johann Lay  <avr@gjlay.de>
294
295         PR target/50931
296         * config/avr/avr.md (mulpsi3): New expander.
297         (*umulqihipsi3, *umulhiqipsi3): New insns.
298         (*mulsqipsi3.libgcc, *mulpsi3.libgcc): New insns.
299         (mulsqipsi3, *mulpsi3): New insn-and-splits.
300         (ashlpsi3): Turn to expander.  Move insn code to...
301         (*ashlpsi3): ...this new insn.
302
303 2011-12-14  Richard Guenther  <rguenther@suse.de>
304
305         * tree-cfg.c (replace_uses_by): Only mark blocks altered
306         that will make a difference.  Only recompute ADDR_EXPR
307         invariantness if it could possibly have changed.  Do so
308         before folding the statement.
309
310 2011-12-13  Eric Botcazou  <ebotcazou@adacore.com>
311
312         * lto-streamer-out.c (write_symbol): Use proper 64-bit host type.
313         * lto-cgraph.c (input_cgraph_opt_section): Use 'int' for offsets.
314         * lto-streamer-in.c (lto_read_body): Likewise.
315         (lto_input_toplevel_asms): Likewise.
316         * lto-section-in.c (lto_create_simple_input_block): Likewise.
317         * ipa-inline-analysis.c (inline_read_section): Likewise.
318         * ipa-prop.c (ipa_prop_read_section): Likewise.
319
320         * df.h (DF_NOTE): Fix typo in comment.
321
322 2011-12-13  Aldy Hernandez  <aldyh@redhat.com>
323
324         * trans-mem.c (ipa_tm_create_version_alias): Set DECL_CONTEXT and
325         DECL_LANG_SPECIFIC.
326
327 2011-12-13  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
328
329         * regmove.c (fixup_match_2): Only access call_used_regs with hard regs.
330
331 2011-12-13  Andrew Pinski  <apinski@cavium.com>
332             Adam Nemet  <anemet@caviumnetworks.com>
333
334         * config/mips/mips-cpus.def: Add Octeon2.
335         * config/mips/mips-tables.opt: Regenerate.
336         * config/mips/mips.md (define_attr "cpu"): Add Octeon2.
337         * config/mips/driver-native.c (host_detect_local_cpu): Support Octeon2.
338         * config/mips/octeon.md (octeon_arith): Add Octeon2.
339         (octeon_condmove): Likewise.
340         (octeon_load): Rename to ..
341         (octeon_load_o1): this.
342         (octeon_load_o2): New reserve.
343         (octeon_cop_o2): New reserve.
344         (octeon_store):  Match Octeon2 also.
345         (octeon_brj): Rename to ..
346         (octeon_brj_o1): this.
347         (octeon_brj_o2): New reserve.
348         (octeon_imul3): Rename to ...
349         (octeon_imul3_o1): this.
350         (octeon_imul3_o2): New reserve.
351         (octeon_imul): Rename to ...
352         (octeon_imul_o1): this.
353         (octeon_imul_o2): New reserve.
354         (octeon_mfhilo): Rename to ...
355         (octeon_mfhilo_o1): This.
356         (octeon_mfhilo_o2): New reserve.
357         (octeon_imadd): Rename to ...
358         (octeon_imadd_o1): this.
359         (octeon_imadd_o2): New reserve.
360         (octeon_idiv): Rename to ..
361         (octeon_idiv_o1): This.
362         (octeon_idiv_o2_si): New reserve.
363         (octeon_idiv_o2_di): Likewise.
364         (octeon_unknown): Match Octeon2 also.
365         * config/mips/mips.c (mips_rtx_cost_data): Add Octeon2 cost data.
366         (mips_issue_rate): Octeon2 can issue 2 at a time.
367         * config/mips/mips.h (TARGET_OCTEON): Match Octeon2 also.
368         (TARGET_OCTEON2): New define.
369         (TUNE_OCTEON): Match Octeon2 also.
370
371 2011-12-13  Richard Henderson  <rth@redhat.com>
372
373         * config/sparc/tso.h: New file.
374         * config.gcc (sparc-*-linux*, sparc*-*-solaris2*): Use it.
375         * config/sparc/sparc.c (sparc_option_override): Honor
376         SUBTARGET_DEFAULT_MEMORY_MODEL.
377         * config/sparc/sparc.h (SUBTARGET_DEFAULT_MEMORY_MODEL): New.
378
379 2011-12-13  Aldy Hernandez  <aldyh@redhat.com>
380
381         PR middle-end/51443
382         * trans-mem.c (struct diagnose_tm): Remove saw_unsafe.
383         (diagnose_tm_1): Same.
384         (ipa_tm_execute): Do not test tm_may_enter_irr before we set it.
385         (ipa_tm_scan_irr_function): Return gracefully when no
386         DECL_STRUCT_FUNCTION.
387         (ipa_tm_scan_irr_block): Believe the user on TM attributes.
388
389 2011-12-13  Martin Jambor  <mjambor@suse.cz>
390
391         PR middle-end/50628
392         * tree-sra.c (propagate_subaccesses_across_link): Do not propagate
393         sub-accesses of scalar accesses.
394
395 2011-12-13  Martin Jambor  <mjambor@suse.cz>
396
397         PR tree-optimization/51362
398         * ipa-cp.c (estimate_local_effects): When estimated size of a
399         specialized clone is zero, bump it to one.
400
401 2011-12-13  Richard Guenther  <rguenther@suse.de>
402
403         PR lto/48354
404         * tree.c (find_decls_types_r): Also walk DECL_ORIGINAL_TYPE.
405         * tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
406         Stream DECL_ORIGINAL_TYPE.
407         * tree-streamer-out.c (write_ts_decl_non_common_tree_pointers):
408         Likewise.
409
410 2011-12-13  Jakub Jelinek  <jakub@redhat.com>
411
412         Revert
413         2011-12-12  Jakub Jelinek  <jakub@redhat.com>
414
415         PR tree-optimization/51481
416         * gimple-fold.c (gimple_fold_call): Call
417         maybe_clean_or_replace_eh_stmt.  Avoid optimization if stmt has EH
418         edges, but gimple_fold_builtin result can't throw.
419
420 2011-12-13  Jakub Jelinek  <jakub@redhat.com>
421             Michael Matz  <matz@suse.de>
422
423         PR tree-optimization/51117
424         * tree-eh.c (sink_clobbers): New function.
425         (execute_lower_eh_dispatch): Call it for BBs ending with
426         internally throwing RESX.
427         * cfgexpand.c (add_scope_conflicts_1): Add all conflicts only
428         at the first real instruction.
429
430 2011-12-13  Tristan Gingold  <gingold@adacore.com>
431
432         * final.c (final_scan_insn): Guard the call to begin_epilogue
433         debug hook.
434
435 2011-12-13  Tristan Gingold  <gingold@adacore.com>
436
437         * vmsdbgout.c (vmsdbgout_write_source_line): New function.
438         (vmsdbgout_end_prologue): Call vmsdbgout_write_source_line.
439         (vmsdbgout_begin_epilogue): Likewise.
440         (vmsdbgout_end_epilogue): Likewise.
441         (vmsdbgout_source_line): Move code to vmsdbgout_write_source_line.
442
443 2011-12-13  Richard Guenther  <rguenther@suse.de>
444
445         PR middle-end/51481
446         * tree-cfg.c (replace_uses_by): Pass proper arguments to
447         maybe_clean_or_replace_eh_stmt.
448
449 2011-12-13  Richard Guenther  <rguenther@suse.de>
450
451         PR tree-optimization/51519
452         * ipa-inline.c (edge_badness): Use edge growth in non-guessed
453         branch probability case as well.
454
455 2011-12-13  Revital Eres  <revital.eres@linaro.org>
456
457         * modulo-sched.c (mark_loop_unsched): Free bbs.
458
459 2011-12-12  Jakub Jelinek  <jakub@redhat.com>
460
461         PR rtl-optimization/51495
462         * function.c (thread_prologue_and_epilogue_insns): Don't add
463         to bb_tail basic blocks that have EDGE_COMPLEX predecessor edges
464         from basic blocks not needing prologue.
465
466         PR tree-optimization/51481
467         * gimple-fold.c (gimple_fold_call): Call
468         maybe_clean_or_replace_eh_stmt.  Avoid optimization if stmt has EH
469         edges, but gimple_fold_builtin result can't throw.
470
471 2011-12-12  Vladimir Makarov  <vmakarov@redhat.com>
472
473         PR rtl-optimization/21617
474         * ira-color.c (bucket_allocno_compare_func): Don't compare
475         allocno classes.  Compare number of hard registers needed.
476
477 2011-12-12  Eric Botcazou  <ebotcazou@adacore.com>
478
479         PR tree-optimization/50569
480         * tree-sra.c (build_ref_for_model): Replicate a chain of COMPONENT_REFs
481         in the expression of MODEL instead of just the last one.
482
483 2011-12-12  Jakub Jelinek  <jakub@redhat.com>
484
485         PR middle-end/51510
486         * calls.c (internal_arg_pointer_based_exp_scan): Don't use
487         VEC_safe_grow_cleared if idx is smaller than VEC_length.
488
489 2011-12-12  Richard Sandiford  <richard.sandiford@linaro.org>
490
491         PR middle-end/50873
492         * optabs.c (maybe_legitimize_operand_same_code): Use copy_to_mode_reg
493         instead of force_reg.  Do nothing if the address is already a
494         non-virtual pseudo register.
495
496 2011-12-12  Torvald Riegel  <triegel@redhat.com>
497
498         * gimplify.c (voidify_wrapper_expr): Add default handling for
499         outermost wrapper.
500
501 2011-12-12  Torvald Riegel  <triegel@redhat.com>
502
503         * tree-ssa-tail-merge.c (gimple_equal_p): Don't treat transaction
504         commits as equal.
505
506 2011-12-12  Iain Sandoe  <iains@gcc.gnu.org>
507
508         * config/darwin-sections.def (zobj_const_data_section): Fix over-
509         length section name.
510
511 2011-12-11  Richard Henderson  <rth@redhat.com>
512
513         * config/rs6000/rs6000.c (rs6000_expand_interleave): Use
514         BYTES_BIG_ENDIAN, not TARGET_BIG_ENDIAN.
515
516 2011-12-11  Jakub Jelinek  <jakub@redhat.com>
517
518         PR tree-optimization/51485
519         * tree-vect-data-refs.c (vect_analyze_data_refs): Give up on
520         DRs in call stmts.
521
522 2011-12-11  Patrick Marlier  <patrick.marlier@gmail.com>
523
524         * trans-mem.c (ipa_tm_transform_calls_redirect): Do not remove edge.
525
526 2011-12-10  Richard Henderson  <rth@redhat.com>
527
528         * config/rs6000/altivec.md (altivec_vmrghb): Rewrite pattern as
529         vec_select + vec_concat.
530         (altivec_vmrghh, altivec_vmrghw, altivec_vmrghsf, altivec_vmrglb,
531         altivec_vmrglh, altivec_vmrglw, altivec_vmrglsf): Likewise.
532         (vec_perm_constv16qi): New.
533         (vec_extract_evenv4si, vec_extract_evenv4sf, vpkuhum_nomode,
534         vpkuwum_nomode, vec_extract_oddv8hi, vec_extract_oddv16qi,
535         vec_interleave_high<VI>, vec_interleave_low<VI>): Remove.
536         * config/rs6000/paired.md (paired_merge00): Rewrite pattern as
537         vec_select + vec_concat.
538         (paired_merge10, paired_merge01, paired_merge11): Likewise.
539         (vec_perm_constv2sf): New.
540         (vec_interleave_highv2sf, vec_interleave_lowv2sf,
541         vec_extract_evenv2sf, vec_extract_oddv2sf): Remove.
542         * config/rs6000/spe.md (spe_evmergehi): Rewrite pattern as
543         vec_select + vec_concat.
544         (spe_evmergehilo, spe_evmergelo, spe_evmergelohi): New.
545         (vec_perm_constv2si): New.
546         * config/rs6000/vector.md (vec_interleave_highv4sf,
547         vec_interleave_lowv4sf, vec_interleave_high<VEC_64>,
548         vec_interleave_low<VEC_64>): Remove.
549         * config/rs6000/vsx.md (VS_double): New mode attribute.
550         (UNSPEC_VSX_XXPERMDI): Remove.
551         (vsx_xxpermdi_<VSX_L>_1): Rewrite pattern as vec_select + vec_concat.
552         (vsx_xxmrghw_<VSX_W>, vsx_xxmrglw_<VSX_W>): Likewise.
553         (vsx_xxpermdi_<VSX_L>): Change to expander.
554         (vec_perm_const<VSX_D>): New.
555         (vsx_mergel_<VSX_D>, vsx_mergeh_<VSX_D>): New.
556         * config/rs6000/predicates.md (const_0_to_1_operand): New.
557         (const_2_to_3_operand): New.
558         * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): New.
559         (altivec_expand_vec_perm_const): New.
560         (rs6000_expand_vec_perm_const_1, rs6000_expand_vec_perm_const): New.
561         (rs6000_vectorize_vec_perm_const_ok): New.
562         (rs6000_do_expand_vec_perm): New.
563         (rs6000_expand_extract_even, rs6000_expand_interleave): New.
564         * config/rs6000/rs6000-builtin.def (VEC_MERGE*): Update rtx codes.
565         * config/rs6000/rs6000-modes.def: Add double-wide vector modes.
566         * config/rs6000/rs6000-protos.h: Update.
567
568 2011-12-10  Richard Henderson  <rth@redhat.com>
569
570         * expr.c (expand_expr_real_2) [VEC_PERM_EXPR]: Avoid passing a
571         CONST_INT to expand_vec_perm as the selector.
572         * optabs.c (expand_vec_perm): Assert the selector is of a proper mode.
573
574 2011-12-10  Richard Henderson  <rth@redhat.com>
575
576         * genmodes.c (struct mode_data): Remove wider_2x member.
577         (blank_mode): Adjust initializer.
578         (calc_wider_mode): Use XALLOCAVEC.
579         (emit_move_wider): Select double-width same-element vectors for
580         2xwider vectors.
581         * machmode.h (GET_MODE_2XWIDER_MODE): Update documentation.
582         * config/i386/i386.c (doublesize_vector_mode): Remove.
583         (expand_vselect_vconcat): Use GET_MODE_2XWIDER_MODE instead.
584
585 2011-12-10  Joern Rennecke  <joern.rennecke@embecosm.com>
586
587         * config/epiphany/epiphany.h (USE_LOAD_POST_INCREMENT): Define.
588         (USE_LOAD_POST_DECREMENT, USE_STORE_POST_INCREMENT): Likewise.
589         (USE_STORE_POST_DECREMENT): Likewise.
590
591         * config/epiphany/epiphany.h (EPIPHANY_RETURN_REGNO): New macro,
592         broken out of ..
593         (INCOMING_RETURN_ADDR_RTX) .. this.  Use EPIPHANY_RETURN_REGNO.
594         (DWARF_FRAME_RETURN_COLUMN): New macro.
595
596         * config/epiphany/epiphany-protos.h (epiphany_start_function): Declare.
597         * config/epiphany/epiphany.c (epiphany_handle_interrupt_attribute):
598         Split "timer" value into "timer0" and "timer1".
599         Handle page_miss, message and wand.  Don't handle static_flag.
600         Adjust warning text.
601         (epiphany_start_function): New function.
602         (epiphany_compute_function_type): Split "timer" value into "timer0"
603         and "timer1".  Handle page_miss, message and wand.
604         Don't handle static_flag.
605         (epiphany_expand_epilogue): Don't use frame_insn for status / iret
606         restore.
607         * config/epiphany/epiphany.h: ASM_DECLARE_FUNCTION_NAME: Define.
608         (enum epiphany_function_type):
609         Split EPIPHANY_FUNCTION_TIMER value into EPIPHANY_FUNCTION_TIMER0
610         and EPIPHANY_FUNCTION_TIMER1.
611         Remove EPIPHANY_FUNCTION_ILINK1 and EPIPHANY_FUNCTION_ILINK2 values.
612         Add EPIPHANY_FUNCTION_PAGE_MISS and EPIPHANY_FUNCTION_MESSAGE values.
613         Rename EPIPHANY_FUNCTION_STATIC_FLAG to EPIPHANY_FUNCTION_WAND.
614
615 2011-12-10  Nathan Sidwell  <nathan@acm.org>
616
617         PR gcov-profile/51449
618         * coverage.c (coverage_end_function): Always process the coverage
619         variables.
620
621 2011-12-09  Aldy Hernandez  <aldyh@redhat.com>
622
623         PR/51291
624         * tree.c (build_common_builtin_nodes): Do not use TM_PURE
625         attribute unless language has support for TM.
626         * config/i386/i386.c (ix86_init_tm_builtins): Exit gracefully in
627         the absence of TM builtins.
628
629 2011-12-09  Eric Botcazou  <ebotcazou@adacore.com>
630
631         * gimple-fold.c (gimple_fold_stmt_to_constant_1) <GIMPLE_UNARY_RHS>:
632         Also check the TYPE_MODE to recognize useless pointer conversions.
633
634 2011-12-09  Jakub Jelinek  <jakub@redhat.com>
635
636         PR tree-optimization/51117
637         * tree-eh.c (optimize_clobbers): Don't remove just one
638         clobber, but all consecutive clobbers before RESX.
639         Use gimple_clobber_p predicate.
640
641 2011-12-09  Michael Meissner  <meissner@the-meissners.org>
642
643         * config/rs6000/rs6000.c (altivec_expand_builtin): Call
644         expand_call to return a valid funciton instead of return
645         cosnt0_rtx/NULL_RTX if there was an error with the builtin.
646         (altivec_expand_ld_builtin): Ditto.
647         (rs6000_inner_target_options): If VSX is selected as a target
648         attribute or pragma, enable ALTIVEC also.
649         (rs6000_pragma_target_parse): Call rs6000_option_override_internal
650         to do all of the standard processing when switching options,
651         including redefining appropriate macros.
652
653         PR rtl-optimization/51469
654         * varasm.c (default_binds_local_p_1): If the symbol is a gnu
655         indirect function, mark the symbol as non-local.
656
657 2011-12-09  H.J. Lu  <hongjiu.lu@intel.com>
658
659         PR bootstrap/51479
660         * Makefile.in (errors.o): Restored.
661
662 2011-12-09  Richard Guenther  <rguenther@suse.de>
663
664         PR lto/48042
665         * tree.c (free_lang_data_in_decl): Remove freeing conditional
666         on debuginfo level.
667
668 2011-12-09  Joern Rennecke  <joern.rennecke@embecosm.com>
669
670         PR middle-end/40154
671         * emit-rtl.c (set_dst_reg_note): New function.
672         * rtl.h (set_dst_reg_note): Declare.
673         * optabs.c (expand_binop, expand_absneg_bit): Use set_dst_reg_note.
674         (emit_libcall_block, expand_fix): Likewise.
675         * function.c (assign_parm_setup_reg, expand_function_start): Likewise.
676         * expmed.c (expand_mult_const, expand_divmod): Likewise.
677         * reload1.c (gen_reload): Likewise.
678
679         * dse.c (get_stored_val, get_call_args): Use gen_int_mode.
680         * expmed.c (expand_divmod): Likewise.
681         * combine.c (simplify_if_then_else): Likewise.
682
683 2011-12-09  Kai Tietz  <ktietz@redhat.com>
684
685         * ira-color.c (print_hard_regs_subforest): Use
686         HOST_WIDEST_INT_PRINT_DEC instead of %lld.
687         (allocno_hard_regs): Change type of cost member to HOST_WIDEST_INT.
688         (add_allocno_hard_regs): Change type of argument cost
689         to HOST_WIDEST_INT.
690         * ira-conflict.c (build_conflict_bit_table): Replace use
691         of long-long by HOST_WIDEST_INT.
692
693 2011-12-09  Georg-Johann Lay  <avr@gjlay.de>
694
695         PR target/51425
696         * config/avr/avr.md (config/avr/avr.md, *sbix_branch_tmp): Use
697         zero_extract:QIHI instead of zero_extract:HI.
698
699 2011-12-09  Jakub Jelinek  <jakub@redhat.com>
700             Andrew Pinski  <apinski@cavium.com>
701
702         PR tree-optimization/51117
703         * tree-eh.c (optimize_clobbers): New function.
704         (execute_lower_eh_dispatch): Call it.
705
706 2011-12-09  Richard Guenther  <rguenther@suse.de>
707
708         PR tree-optimization/51482
709         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size):
710         Make sure to only create REAL_TYPE and INTEGER_TYPE component vectors.
711
712 2011-12-09  Kai Tietz  <ktietz@redhat.com>
713
714         * implicit-zee.c (num_realized): Change type to long.
715         (num_ze_opportunities): Likewise.
716
717 2011-12-08  Andrew Pinski  <apinski@cavium.com>
718
719         * config/mips/mips-cpus.def (octeon+): New CPU.
720         * config/mips/mips-tables.opt: Regenerate.
721         * config/mips/mips.h (MIPS_CPP_SET_PROCESSOR): Emit '+' as 'P'.
722
723 2011-12-08  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
724
725         PR middle-end/39976
726         * tree-ssa-dom.c (enum expr_kind): Add EXPR_PHI.
727         (struct hashable_expr): Add struct phi field.
728         (initialize_hash_element): Handle phis; change to use XCNEWVEC.
729         (hashable_expr_equal_p): Handle phis.
730         (iterative_hash_hashable_expr): Likewise.
731         (print_expr_hash_elt): Likewise.
732         (free_expr_hash_elt): Likewise.
733         (dom_opt_enter_block): Create equivalences from redundant phis.
734         (eliminate_redundant_computations): Handle redundant phis.
735         (lookup_avail_expr): Handle phis.
736
737 2011-12-08  Jakub Jelinek  <jakub@redhat.com>
738
739         PR tree-optimization/51466
740         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Also copy
741         TREE_SIDE_EFFECTS.
742
743 2011-12-08  Richard Guenther  <rguenther@suse.de>
744
745         * tree-ssa-operands.c (add_stmt_operand): Do not mark stmts
746         volatile when processing operands of an ADDR_EXPR.
747         (get_indirect_ref_operands): Likewise.
748         (get_tmr_operands): Likewise.
749         (get_expr_operands): Likewise.
750
751 2011-12-08  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
752
753         PR target/50395
754         * config/s390/s390.c (s390_mainpool_finish): Emit the jump over
755         the literal pool as jump insn.
756
757 2011-12-08  Richard Guenther  <rguenther@suse.de>
758
759         PR tree-optimization/49772
760         * tree-inline.c (optimize_inline_calls): Remove bail out on errors.
761
762 2011-12-08  Richard Guenther  <rguenther@suse.de>
763
764         PR lto/50747
765         * lto-streamer-out.c (produce_symtab): Remove asserts.
766
767 2011-12-08  Richard Guenther  <rguenther@suse.de>
768
769         PR lto/49945
770         * lto-streamer-out.c (tree_is_indexable): Localize variably
771         modified types and their FIELD_DECLs.
772
773 2011-12-08  Eric Botcazou  <ebotcazou@adacore.com>
774
775         PR tree-optimization/51315
776         * tree.h (get_object_or_type_alignment): Declare.
777         * expr.c (get_object_or_type_alignment): Move to...
778         * builtins.c (get_object_or_type_alignment): ...here.  Add assertion.
779         * tree-sra.c (tree_non_mode_aligned_mem_p): Rename to...
780         (tree_non_aligned_mem_p): ...this.  Add ALIGN parameter.  Look into
781         MEM_REFs and use get_object_or_type_alignment for them.
782         (build_accesses_from_assign): Adjust for above change.
783         (access_precludes_ipa_sra_p): Likewise.
784
785 2011-12-08  Richard Guenther  <rguenther@suse.de>
786
787         PR lto/48437
788         * lto-streamer-out.c (tree_is_indexable): Exclude block-local
789         extern declarations.
790
791 2011-12-07  Andrew Pinski  <apinski@cavium.com>
792
793         PR middle-end/45416
794         * expr.c (do_store_flag): Rewrite code that looks for BIT_AND_EXPR for
795         SSA-expand.
796
797 2011-12-07  Richard Guenther  <rguenther@suse.de>
798
799         PR tree-optimization/50823
800         * ipa-inline.c (edge_badness): Do not account for the number of
801         remaining calls.
802
803 2011-12-07  Martin Jambor  <mjambor@suse.cz>
804
805         PR tree-optimization/50744
806         * ipa-cp.c (good_cloning_opportunity_p): Assert size_cost is positive,
807         compute evaluation in HOST_WIDEST_INT.
808         (safe_add): New function
809         (propagate_effects): Use safe_add to accumulate effects.
810
811 2011-12-06  Joel Sherrill <joel.sherrill@oarcorp.com>
812
813         * config/rs6000/rtems.h: Switch to using global_options_set
814         in SUBSUBTARGET_OVERRIDE_OPTIONS.
815
816 2011-12-06  David S. Miller  <davem@davemloft.net>
817
818         * config/sparc/visintrin.h: Add appropriate __VIS__ cpp protection.
819
820 2011-12-06  Georg-Johann Lay  <avr@gjlay.de>
821
822         * config/avr/avr.c (avr_file_start): Fix missing ,
823
824 2011-12-06  Jakub Jelinek  <jakub@redhat.com>
825
826         PR target/51354
827         * config/i386/i386.c (ix86_emit_leave): Call ix86_add_cfa_restore_note
828         unconditionally.
829
830 2011-12-06  Georg-Johann Lay  <avr@gjlay.de>
831
832         Forward-port from gcc-4_6-branch r181936 2011-12-02.
833         * config/avr/avr-mcus.def (avr_mcu_types): ATtiny4313 and
834         AT86RF401 have a 16-bit SP (their manual is bogus).
835
836 2011-12-06  Georg-Johann Lay  <avr@gjlay.de>
837
838         Forward-port from gcc-4_6-branch r181936 2011-12-02.
839
840         PR target/51002
841         * config/avr/avr.md (movhi_sp_r): Set insn condition to
842         !AVR_HAVE_8BIT_SP.
843         * config/avr/avr.c (output_movhi): Use "clr%B0" instead of "in
844         %B0,__SP_H__" if AVR_HAVE_8BIT_SP.
845         (avr_file_start): Only print "__SP_H__ = 0x3e" if !AVR_HAVE_8BIT_SP.
846
847 2011-12-06  Georg-Johann Lay  <avr@gjlay.de>
848
849         PR target/51409
850         PR target/49868
851         * config/avr/avr.h (ADDR_SPACE_PGM, ADDR_SPACE_PGM1,
852         ADDR_SPACE_PGM2, ADDR_SPACE_PGM3, ADDR_SPACE_PGM4,
853         ADDR_SPACE_PGM5, ADDR_SPACE_PGMX): Write as enum.
854         (avr_addrspace_t): New typedef.
855         (avr_addrspace): New declaration.
856         * config/avr/avr-c.c (avr_toupper): New static function.
857         (avr_register_target_pragmas, avr_cpu_cpp_builtins): Use
858         avr_addrspace to get address space information.
859         * config/avr/avr.c (avr_addrspace): New variable.
860         (avr_out_lpm, avr_pgm_check_var_decl, avr_insert_attributes,
861         avr_asm_named_section, avr_section_type_flags,
862         avr_asm_select_section, avr_addr_space_address_mode,
863         avr_addr_space_convert, avr_emit_movmemhi): Use it.
864         (avr_addr_space_pointer_mode): Forward to avr_addr_space_address_mode.
865         (avr_pgm_segment): Remove.
866
867 2011-12-06  Richard Guenther  <rguenther@suse.de>
868
869         PR middle-end/50601
870         * varasm.c (assemble_alias): Move DECL_EXTERNAL implementation
871         quirk adjustjment ...
872         * passes.c (rest_of_decl_compilation): ... here.
873
874 2011-12-06  Richard Guenther  <rguenther@suse.de>
875
876         PR middle-end/51436
877         * gimple-fold.c (gimplify_and_update_call_from_tree): Guard vdef check
878         for the fact we do not have virtual operands when not optimizing.
879
880 2011-12-06  Richard Guenther  <rguenther@suse.de>
881
882         PR tree-optimization/51245
883         * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_constant_for_pieces):
884         New function.
885         (vn_reference_lookup_3): Use it.  Properly valueize all refs we create.
886
887 2011-12-06  Iain Sandoe  <iains@gcc.gnu.org>
888
889         * config/rs6000/rs6000.c (darwin_rs6000_override_options): Initialize
890         rs6000_current_abi.
891
892 2011-12-06  Richard Guenther  <rguenther@suse.de>
893
894         PR tree-optimization/51363
895         * gimple.c (gimple_rhs_has_side_effects): Remove.
896         * gimple.h (gimple_rhs_has_side_effects): Likewise.
897         * tree-ssa-dom.c (optimize_stmt): Simplify conditional.
898
899 2011-12-06  Alan Modra  <amodra@gmail.com>
900
901         PR target/50906
902         * config/rs6000/rs6000.c (rs6000_emit_prologue <TARGET_SPE_ABI>):
903         Do not mark r11 setup as frame-related.  Pass correct offset to
904         rs6000_emit_savres_rtx.  Correct out-of-line rs6000_frame_related
905         arguments.  Correct sp_offset.  Remove "offset" fudge from
906         in-line rs6000_frame_related call.  Rename misleading variable.
907         Fix comments and whitespace.  Tidy some expressions.
908         (rs6000_emit_epilogue <TARGET_SPE_ABI>): Always set frame_reg_rtx
909         to r11 in out-of-line case.  Correct sp_offset.  Pass correct
910         offset to rs6000_emit_savres_rtx.  Rename misleading variable.
911         Fix comments and whitespace.  Tidy some expressions.
912         (rs6000_emit_epilogue <non-TARGET_SPE_ABI>): Add sp_offset
913         adjustment when !saving_GPRs_inline.  Correct register mode
914         used in address calcs.
915         (rs6000_emit_epilogue <non-TARGET_SPE_ABI>): Similarly when
916         !restoring_GPRs_inline.
917
918 2011-12-06  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
919
920         * config/arm/vfp.md (*combine_vcvt_f64_<FCVTI32typename>): Fix
921         formatting character for vmov.f64 case.
922
923 2011-12-05  Jakub Jelinek  <jakub@redhat.com>
924
925         PR tree-optimization/51396
926         * tree-ssa-math-opts.c (convert_mult_to_fma): Don't optimize
927         if MUL_RESULT has zero uses.
928
929         PR debug/51410
930         * c-decl.c (pop_scope): Don't add DECL_EXTERNAL decls
931         for debug info if scope is file_scope.
932
933         PR c/51339
934         * c-decl.c (c_finish_incomplete_decl, finish_decl): Call
935         relayout_decl instead of layout_decl.
936
937 2011-12-05  Richard Sandiford  <rdsandiford@googlemail.com>
938
939         * resource.c (init_resource_info): Only consider EXIT_IGNORE_STACK
940         if there is in epilogue.
941
942 2011-12-05  Richard Sandiford  <rdsandiford@googlemail.com>
943
944         * optabs.c (maybe_emit_sync_lock_test_and_set): Pass a null target
945         to emit_library_call_value.
946         (expand_atomic_compare_and_swap): Likewise.
947
948 2011-12-05  Vladimir Makarov  <vmakarov@redhat.com>
949
950         PR other/50775
951         * ira-int.h (struct ira_object): Remove add_data.
952         (OBJECT_ADD_DATA): Remove.
953
954         * ira-build.c (ira_create_object): Remove OBJECT_ADD_DATA
955         initialization.
956
957         * ira-color.c (object_hard_regs_t, object_hard_regs): Rename to
958         allocno_hard_regs_t, allocno_hard_regs.
959         (object_hard_regs_node_t, object_hard_regs_node): Rename to
960         allocno_hard_regs_node_t and allocno_hard_regs_node.
961         (struct allocno_color_data): Add new member last_process.  Move
962         profitable_hard_regs, hard_regs_node, and hard_regs_subnodes_start
963         from object_color_data.
964         (object_color_data_t, object_color_data, OBJECT_COLOR_DATA): Remove.
965         (curr_allocno_process): New static variable.
966         (object_hard_regs_eq, object_hard_regs_htab): Rename to
967         allocno_hard_regs_eq and allocno_hard_regs_htab.
968         (init_object_hard_regs, finish_object_hard_regs): Rename to
969         init_allocno_hard_regs and finish_allocno_hard_regs.
970         (object_hard_regs_compare, object_hard_regs_node_t): Rename to
971         allocno_hard_regs_compare and allocno_hard_regs_node_t.
972         (create_new_object_hard_regs_node): Rename to
973         create_new_allocno_hard_regs_node.
974         (add_new_object_hard_regs_node_to_forest): Rename to
975         add_new_allocno_hard_regs_node_to_forest.
976         (add_object_hard_regs_to_forest, collect_object_hard_regs_cover):
977         Rename to add_allocno_hard_regs_to_forest and
978         collect_allocno_hard_regs_cover.
979         (setup_object_hard_regs_nodes_parent): Rename to
980         setup_allocno_hard_regs_nodes_parent.
981         (remove_unused_object_hard_regs_nodes): Rename to
982         remove_unused_allocno_hard_regs_nodes.
983         (enumerate_object_hard_regs_nodes, object_hard_regs_nodes_num):
984         Rename to enumerate_allocno_hard_regs_nodes and
985         allocno_hard_regs_nodes_num.
986         (object_hard_regs_nodes, object_hard_regs_subnode_t): Rename to
987         allocno_hard_regs_nodes and allocno_hard_regs_subnode_t.
988         (object_hard_regs_subnode, object_hard_regs_subnodes): Rename to
989         allocno_hard_regs_subnode and allocno_hard_regs_subnodes.
990         (object_hard_regs_subnode_index): Rename to
991         allocno_hard_regs_subnode_index.
992         (setup_object_hard_regs_subnode_index): Rename to
993         setup_allocno_hard_regs_subnode_index.
994         (get_object_hard_regs_subnodes_num): Rename to
995         get_allocno_hard_regs_subnodes_num.
996         (form_object_hard_regs_nodes_forest): Rename to
997         form_allocno_hard_regs_nodes_forest.
998         (finish_object_hard_regs_nodes_tree): Rename to
999         form_allocno_hard_regs_nodes_forest
1000         (finish_object_hard_regs_nodes_forest): Rename to
1001         finish_allocno_hard_regs_nodes_forest.
1002         (setup_left_conflict_sizes_p): Use allocno data instead of object ones.
1003         Process conflict allocnos once.
1004         (update_left_conflict_sizes_p): Use allocno data instead of object
1005         ones.  Change prototype signature.
1006         (empty_profitable_hard_regs): Use allocno data instead of object ones.
1007         (setup_profitable_hard_regs): Ditto.
1008         (get_conflict_profitable_regs): Rename to
1009         get_conflict_and_start_profitable_regs.  Use allocno data for
1010         profitable regs calculation.
1011         (check_hard_reg_p): Change prototype signature.  Check profitable
1012         regs for allocno not the objects.
1013         (assign_hard_reg): Process conflict allocnos only once for
1014         updating conflict costs.
1015         (setup_allocno_available_regs_num): Use allocno data instead of
1016         object ones.  Modify debug output.
1017         (color_pass): Remove initialization and finalization of object
1018         color data.
1019
1020 2011-12-05  Kazu Hirata  <kazu@codesourcery.com>
1021
1022         PR target/51408
1023         * config/arm/arm.md (*minmax_arithsi): Always require the else
1024         clause in the MINUS case.
1025
1026 2011-12-05  Richard Guenther  <rguenther@suse.de>
1027
1028         PR tree-optimization/50904
1029         * tree-ssa-loop-im.c (struct mem_ref): Remove vops member.
1030         (MEM_ANALYZABLE): New.
1031         (memory_references): Remove clobbered_vops and vop_ref_map
1032         members, add all_refs_stored_in_loop member.
1033         (memref_free): Adjust.
1034         (mem_ref_alloc): Likewise.
1035         (gather_mem_refs_stmt): Do not record clobbers, instead
1036         record refs for unanalyzable stmts.
1037         (gather_mem_refs_in_loops): Do not propagate clobbers.
1038         (struct vop_to_refs_elt, vtoe_hash, vtoe_eq, vtoe_free,
1039         record_vop_access, get_vop_accesses, get_vop_stores,
1040         add_vop_ref_mapping): Remove.
1041         (create_vop_ref_mapping_loop): Adjust to simply record all stores.
1042         (analyze_memory_references): Adjust.
1043         (refs_independent_p): Check for not analyzable refs.
1044         (can_sm_ref_p): Likewise.
1045         (ref_indep_loop_p_1): Simplify.
1046         (tree_ssa_lim_finalize): Adjust.
1047
1048         * tree-ssa-loop-im.c (stmt_cost): Simplify, use LIM_EXPENSIVE
1049         rather than magic constants.  Assign zero cost to PAREN_EXPR
1050         and SSA_NAME copies.  Assign cost proportional to the vector
1051         size for vector constructors.
1052
1053 2011-12-05  Richard Guenther  <rguenther@suse.de>
1054
1055         * tree-ssa-alias.h (struct ao_ref_s): Add volatile_p field.
1056         * tree-ssa-alias.c (ao_ref_init): Initialize it.
1057         (ao_ref_init_from_ptr_and_size): Likewise.
1058         (refs_may_alias_p_1): Two volatile accesses conflict.
1059         (ref_maybe_used_by_call_p_1): Likewise.
1060         (call_may_clobber_ref_p_1): Likewise.
1061         * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): Initialize
1062         volatile_p field.
1063
1064 2011-12-05  Richard Guenther  <rguenther@suse.de>
1065
1066         * tree-ssa.c (verify_ssa): Verify SSA names in the loop over all SSA
1067         names.  Remove SSA operand checking, call verify_ssa_operands.
1068         * tree-ssa-operands.h (verify_ssa_operands): Declare.
1069         * tree-ssa-operands.c (verify_ssa_operands): New function.
1070
1071 2011-12-05  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
1072
1073         * config/arm/arm.c (vfp3_const_double_for_fract_bits): Define.
1074         * config/arm/arm-protos.h (vfp3_const_double_for_fract_bits): Declare.
1075         * config/arm/constraints.md ("Dt"): New constraint.
1076         * config/arm/predicates.md
1077         (const_double_vcvt_power_of_two_reciprocal): New.
1078         * config/arm/vfp.md (FCVTI32typename): New.
1079         (FCVT): New iterator.
1080         (*combine_vcvt_f32_<FCVTI32typename>): New.
1081         (*combine_vcvt_f64_<FCVTI32typename>): New.
1082
1083 2011-12-05  Richard Guenther  <rguenther@suse.de>
1084
1085         * cgraph.c (cgraph_create_edge_1): Initialize
1086         call_stmt_cannot_inline_p from the stmt if possible.
1087         (cgraph_make_edge_direct): Likewise.
1088         * gimple-streamer-in.c (input_gimple_stmt): Do not
1089         call gimple_call_set_cannot_inline.
1090         * gimple.h (enum gf_mask): Remove GF_CALL_CANNOT_INLINE, shift values.
1091         (gimple_call_set_cannot_inline): Remove.
1092         (gimple_call_cannot_inline_p): Likewise.
1093         * ipa-inline-analysis.c (initialize_inline_failed): Look
1094         at the edge call_stmt_cannot_inline_p flag.
1095         * ipa-inline.c (can_inline_edge_p): Likewise.
1096         (early_inliner): Only update the edge flag.
1097         * ipa-prop.c (update_indirect_edges_after_inlining): Likewise.
1098         (ipa_modify_call_arguments): Do not call gimple_call_set_cannot_inline.
1099         * cgraphunit.c (assemble_thunk): Likewise.
1100         * gimple-fold.c (gimple_fold_call): Likewise.
1101
1102         * tree.h (CALL_CANNOT_INLINE_P): Remove.
1103         * tree-mudflap.c (mf_xform_statements): Do not modify alloca calls.
1104         * builtins.c (expand_builtin_alloca): With -fmudflap do not expand
1105         alloca calls inline.
1106         * cfgexpand.c (expand_call_stmt): Do not set CALL_CANNOT_INLINE_P.
1107         * gimple.c (gimple_build_call_from_tree): Do not read
1108         CALL_CANNOT_INLINE_P.
1109         * gimplify.c (gimplify_call_expr): Do not copy CALL_CANNOT_INLINE_P.
1110
1111 2011-12-05  Jakub Jelinek  <jakub@redhat.com>
1112             Eric Botcazou  <ebotcazou@adacore.com>
1113
1114         PR middle-end/51323
1115         PR middle-end/50074
1116         * calls.c (internal_arg_pointer_exp_state): New variable.
1117         (internal_arg_pointer_based_exp_1,
1118         internal_arg_pointer_exp_scan): New functions.
1119         (internal_arg_pointer_based_exp): New function.
1120         (mem_overlaps_already_clobbered_arg_p): Use it.
1121         (expand_call): Free internal_arg_pointer_exp_state.cache vector
1122         and clear internal_arg_pointer_exp_state.scan_start.
1123
1124 2011-12-04  Kaz Kojima  <kkojima@gcc.gnu.org>
1125
1126         * config/sh/linux.h (TARGET_DEFAULT): Add MASK_SOFT_ATOMIC.
1127         * config/sh/sync.md: New file.
1128         * config/sh/sh.md: Include sync.md.
1129         * config/sh/sh.opt (msoft-atomic): New option.
1130         * doc/invoke.texi (SH Options): Document it.
1131
1132 2011-12-04  Nathan Sidwell  <nathan@acm.org>
1133
1134         * gcov-io.h (struct gcov_info): Replace trailing array with
1135         pointer to array.
1136         * profile.c (branch_prob): Only call renamed
1137         coverage_begin_function once.
1138         * coverage.h (coverage_begin_output): Rename to ...
1139         (coverage_begin_function): ... here.
1140         * coverage.c (struct function_list): Rename to ...
1141         (struct coverage_data): ... this.  Update all uses.
1142         (gcov_info_var, gcov_fn_info_type, gcov_fn_info_ptr_type): New globals.
1143         (bbg_file_opened, bbg_function_announced): Remove.
1144         (get_coverage_counts): Adjust message.
1145         (coverage_begin_ouput): Rename to ...
1146         (coverage_begin_function): ... here.  Move file opening to
1147         coverage_init.  Adjust for being called only once.
1148         (coverage_end_function): Remove bbg file and inhibit further
1149         output here on error.
1150         (build_info_type): Adjust for change to pointer to array.
1151         (build_info): Receive array of function pointers and adjust.
1152         (create_coverage): Break into ...
1153         (coverage_obj_init, coverage_obj_fn, coverage_obj_finish):
1154         ... these, and adjust.
1155         (coverage_init): Open the notes file here.  Tidy.
1156         (coverage_finish): Call coverage_obj_init etc.
1157
1158 2011-12-04  Ira Rosen  <ira.rosen@linaro.org>
1159
1160         PR middle-end/51285
1161         * tree-vect-loop.c (vect_create_epilog_for_reduction): Create exit
1162         phi nodes for outer loop in case of double reduction.
1163
1164 2011-12-04  Jérémie Detrey  <Jeremie.Detrey@loria.fr>
1165
1166         PR target/51393
1167         * config/i386/avxintrin.h (_mm256_insert_epi64): Declare second
1168         parameter as long long.
1169
1170 2011-12-04  Richard Sandiford  <rdsandiford@googlemail.com>
1171
1172         PR middle-end/51351
1173         * optabs.c (init_sync_libfuncs): Use "or" rather than "ior"
1174         in the external names.
1175
1176 2011-12-03  Jack Howarth <howarth@bromo.med.uc.edu>
1177
1178         * config/darwin10.h (LINK_GCC_C_SEQUENCE_SPEC): Pass -no_pie for
1179         non-PIC code when targeting 10.7 or later.
1180
1181 2011-12-03  Iain Sandoe  <iains@gcc.gnu.org>
1182
1183         * config/darwin.h (STARTFILE_SPEC): Do not use -lbundle1.o when
1184         Darwin >= 10.
1185         (DARWIN_DYLIB1_SPEC): Do not use -ldylib1.10.5.o when Darwin >= 10.
1186         (DARWIN_CRT1_SPEC): Use -lcrt1.10.6.o when Darwin >= 10.
1187
1188 2011-12-03  Jakub Jelinek  <jakub@redhat.com>
1189
1190         * fold-const.c (fold_unary_loc): Fold VEC_UNPACK_LO_EXPR,
1191         VEC_UNPACK_HI_EXPR, VEC_UNPACK_FLOAT_LO_EXPR and
1192         VEC_UNPACK_FLOAT_HI_EXPR with VECTOR_CST argument.
1193         (fold_binary_loc): Fold VEC_PACK_TRUNC_EXPR,
1194         VEC_PACK_FIX_TRUNC_EXPR, VEC_WIDEN_MULT_LO_EXPR
1195         and VEC_WIDEN_MULT_HI_EXPR with VECTOR_CST arguments.
1196
1197         PR debug/50317
1198         * tree-ssa.c (target_for_debug_bind): Also allow is_gimple_reg_type
1199         vars that aren't referenced.
1200         (tree-ssa-live.c (remove_unused_locals): Don't clear TREE_ADDRESSABLE
1201         of unreferenced local vars.
1202         * cfgexpand.c (expand_debug_expr): For DEBUG_IMPLICIT_PTR allow also
1203         TREE_ADDRESSABLE vars that satisfy target_for_debug_bind.
1204
1205 2011-12-03  Anatoly Sokolov  <aesok@post.ru>
1206
1207         * config/arm/arm.h (LIBCALL_VALUE, FUNCTION_VALUE_REGNO_P): Remove.
1208         * config/arm/arm-protos.h (aapcs_libcall_value): Remove.
1209         * config/arm/arm.c (TARGET_FUNCTION_VALUE_REGNO_P): Define.
1210         (arm_libcall_value_1, arm_function_value_regno_p): New function.
1211         (arm_function_value, arm_libcall_value): Use arm_libcall_value_1.
1212         (aapcs_libcall_value): Make static.
1213         (arm_libcall_value): Add static qualifier.
1214
1215 2011-12-02  Jakub Jelinek  <jakub@redhat.com>
1216
1217         PR target/51387
1218         * config/i386/sse.md (mul<mode>3 with VI1_AVX2 iterator): For
1219         V32QImode use { 0,2,..,14,32,34,..,46,16,18,..,30,48,50,..,62 }
1220         permutation instead of extract even permutation.
1221
1222 2011-12-02  Nathan Sidwell  <nathan@acm.org>
1223
1224         * gcov.c (struct arc_info): Add is_throw field.
1225         (struct (block_info): Add exceptional field, reduce flags size to
1226         account for it.
1227         (struct function_info): Add has_catch field.
1228         (struct line_info): Add unexceptional field.
1229         (process_file): Call find_exception_blocks if necessary.
1230         (read_graph_file): Adjust.  Note if an exceptional edge is seen.
1231         (find_exception_blocks): New.
1232         (add_line_counts): Set line's unexceptional flag if not exceptional.
1233         (output_branch_count): Note exceptional arcs, lines and blocks.
1234         * gcov-dump.c (tag_arcs): Decode arc flags.
1235         * doc/gcov.texi: Document '=====' lines.
1236
1237 2011-12-02  Anatoly Sokolov  <aesok@post.ru>
1238
1239         * config/ia64/ia64.h (PRINT_OPERAND, PRINT_OPERAND_ADDRESS,
1240         PRINT_OPERAND_PUNCT_VALID_P): Remove macros.
1241         * config/ia64/ia64-protos.h (ia64_print_operand,
1242         ia64_print_operand_address): Remove.
1243         * config/ia64/ia64.c (TARGET_PRINT_OPERAND,
1244         TARGET_PRINT_OPERAND_ADDRESS, TARGET_PRINT_OPERAND_PUNCT_VALID_P):
1245         Define.
1246         (ia64_print_operand_punct_valid_p): New function.
1247         (ia64_print_operand, ia64_print_operand_address): Make static.
1248
1249 2011-12-02  Michael Meissner  <meissner@the-meissners.org>
1250
1251         PR target/51390
1252         * config/rs6000/rs6000.c (def_builtin): Use the correct field to
1253         figure out the function's attributes.
1254         (struct builtin_description): Mark mask field as const since we no
1255         longer need to modify it for SPE and PAIRED builtins.
1256
1257 2011-12-02  Joseph Myers  <joseph@codesourcery.com>
1258
1259         Revert:
1260
1261         2008-09-18  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1262
1263         PR rtl-opt/37451
1264         * loop-doloop.c (doloop_modify): New argument zero_extend_p and
1265         zero extend count after the correction to it is done.
1266         (doloop_optimize): Update call to doloop_modify, don't zero extend
1267         count before call.
1268
1269         2008-11-03  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1270
1271         PR rtl-opt/37782
1272         * loop-doloop.c (doloop_modify): Add from_mode argument that says what
1273         mode count is in.
1274         (doloop_optimize): Update call to doloop_modify.
1275
1276 2011-12-02  Richard Guenther  <rguenther@suse.de>
1277
1278         PR lto/47259
1279         * ipa.c (varpool_externally_visible_p): Register variables
1280         are always externally visible.
1281
1282 2011-12-02  Sameera Deshpande  <sameera.deshpande@arm.com>
1283
1284         * gimple-pretty-print.c (dump_gimple_call): Dereference fn only if
1285           non-NULL.
1286
1287 2011-12-02  Martin Jambor  <mjambor@suse.cz>
1288
1289         PR tree-optimization/50622
1290         * tree-sra.c (load_assign_lhs_subreplacements): Force gimple operand
1291         if both lacc and racc are grp_partial_lhs.
1292
1293 2011-12-01  Kaz Kojima  <kkojima@gcc.gnu.org>
1294
1295         PR target/50814.
1296         * config/sh/sh.c (expand_ashiftrt): Handle TARGET_SH2A same as
1297         TARGET_SH3.
1298         (shl_sext_kind): Likewise.
1299         * config/sh/sh.h (SH_DYNAMIC_SHIFT_COST): Likewise.
1300         * config/sh/sh.md (ashlsi3_sh2a, ashrsi3_sh2a, lshrsi3_sh2a): Remove.
1301         (ashlsi3_std): Handle TARGET_SH2A same as TARGET_SH3.
1302         (ashlsi3): Likewise.
1303         (ashrsi3_d): Likewise.
1304         (lshrsi3_d): Likewise.
1305         (lshrsi3): Likewise.
1306
1307 2011-12-01  Diego Novillo  <dnovillo@google.com>
1308
1309         PR bootstrap/51346
1310         * ipa-inline.c (can_inline_edge_p): If the edge E has a statement,
1311         use the statement's inline indicator instead of E's.
1312         Remove consistency check.
1313
1314 2011-12-01  Diego Novillo  <dnovillo@google.com>
1315
1316         PR bootstrap/51346
1317         Revert
1318
1319         2011-11-29  Diego Novillo  <dnovillo@google.com>
1320
1321         * gimple.c (gimple_call_set_cannot_inline): Move from gimple.h.
1322         Update field call_stmt_cannot_inline_p from call
1323         graph edge, if needed.
1324         * gimple.h (gimple_call_set_cannot_inline): Move to gimple.c.
1325
1326 2011-12-01  Nathan Sidwell  <nathan@acm.org>
1327
1328         PR gcov-profile/51113
1329         * coverage.c (build_var): Keep coverage variables static.
1330
1331 2011-12-01  Jakub Jelinek  <jakub@redhat.com>
1332
1333         PR tree-optimization/51356
1334         * tree-vect-patterns.c (vect_recog_bool_pattern): Give up if
1335         vectype doesn't have VECTOR_MODE_P.
1336
1337         PR debug/50317
1338         * tree-ssa-dce.c (remove_dead_stmt): Add a debug stmt when removing
1339         as unnecessary a store to a variable with gimple reg type.
1340         * tree-ssa-live.c (remove_unused_locals): Clear TREE_ADDRESSABLE bit
1341         on local unreferenced variables.
1342         * cfgexpand.c (expand_gimple_basic_block): Don't emit DEBUG_INSNs
1343         for !target_for_debug_bind variables.
1344
1345 2011-12-01  Patrick Marlier  <patrick.marlier@gmail.com>
1346
1347         PR middle-end/51273
1348         * cgraph.h (cgraph_call_node_duplication_hooks): Declare.
1349         * cgraph.c (cgraph_call_node_duplication_hooks): Make global.
1350         * cgraphunit.c (cgraph_copy_node_for_versioning): Call it.
1351
1352 2011-12-01  Andrew Pinski  <apinski@cavium.com>
1353
1354         PR lto/51198
1355         * tree.c (free_lang_data_in_decl): Clear FIELD_DECL's
1356         DECL_INITIAL also.
1357
1358 2011-12-01  Jakub Jelinek  <jakub@redhat.com>
1359
1360         PR tree-optimization/51246
1361         * tree-predcom.c (replace_ref_with): Handle also clobber on the rhs.
1362
1363         PR rtl-optimization/51014
1364         * loop-unroll.c (apply_opt_in_copies): Ignore label DEBUG_INSNs
1365         both from bb and orig_bb.
1366
1367 2011-12-01  Joern Rennecke  <joern.rennecke@embecosm.com>
1368
1369         PR tree-optimization/50802
1370         * tree-vrp.c (simplify_conversion_using_ranges): Rewrite test
1371         considering what happens to ranges during sign changes and/or
1372         intermediate narrowing conversions.
1373
1374 2011-11-30  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1375
1376         PR middle-end/50283
1377         * config/pa/pa.md (in_branch_delay): Disallow frame related insns.
1378         (in_nullified_branch_delay): Likewise.
1379         (in_call_delay): Likewise.
1380
1381 2011-11-30  Richard Henderson  <rth@redhat.com>
1382
1383         * predict.c (expr_expected_value_1): Assume compare-and-swap builtin
1384         boolean return is true.
1385
1386 2011-11-30  Jakub Jelinek  <jakub@redhat.com>
1387
1388         PR rtl-optimization/51044
1389         * dse.c (emit_inc_dec_insn_before): Ensure new_insn is an instruction
1390         rather than just insn body.
1391
1392         PR target/50725
1393         * function.c (thread_prologue_and_epilogue_insns): If
1394         stack_realign_drap, add drap_reg to SET_UP_BY_PROLOGUE
1395         regset.
1396
1397         PR middle-end/51089
1398         * tree-eh.c (cleanup_empty_eh_merge_phis): Add check to
1399         avoid creating duplicate edges here.
1400         (cleanup_empty_eh_unsplit): And remove it in the caller.
1401
1402 2011-11-30  Andrew Pinski  <apinski@cavium.com>
1403
1404         PR c/51321
1405         * c-parser.c (c_parser_postfix_expression): Check groktypename results
1406         before looking at the main variant.
1407
1408 2011-11-30  Jakub Jelinek  <jakub@redhat.com>
1409
1410         PR rtl-optimization/48721
1411         * sched-deps.c (sched_analyze_insn): For SIBLING_CALL_P set
1412         reg_pending_barrier to TRUE_BARRIER.
1413
1414         PR rtl-optimization/48721
1415         * sched-ebb.c (begin_move_insn): Insert empty unreachable
1416         block after BARRIER if insn is followed by it.
1417
1418 2011-11-30  Richard Henderson  <rth@redhat.com>
1419
1420         * config/sparc/sparc-opts.h (enum sparc_memory_model_type): New.
1421         * config/sparc/sparc.opt (mmemory-model=): New option.
1422         * doc/invoke.texi (Sparc Options): Document it.
1423         * config/sparc/sparc.c (sparc_option_override): Provide default
1424         for sparc_memory_model.
1425         (sparc_emit_membar_for_model): Omit barrier combinations that are
1426         implied by the memory model.
1427
1428 2011-11-30  Richard Henderson  <rth@redhat.com>
1429
1430         * config/sparc/sync.md (I124MODE): New mode iterator.
1431         (memory_barrier): Remove.
1432         (atomic_exchangesi): New.
1433         (swapsi): Rename from *swapsi.
1434         (atomic_test_and_set<I124MODE>): New.
1435         (ldstubqi): Rename from *ldstubqi, merge with expander.
1436         (ldstub<I24MODE>): Rename from *ldstub<I24MODE>, merge with expander.
1437         (sync_lock_test_and_setsi): Remove.
1438         (sync_lock_test_and_set<I12MODE>): Remove.
1439
1440 2011-11-30  Richard Henderson  <rth@redhat.com>
1441
1442         * config/sparc/constraints.md ("w"): New.
1443         * config/sparc/predicates.md (mem_noofs_operand): New.
1444         * config/sparc/sparc.c (sparc_expand_compare_and_swap_12): Make static.
1445         Generate the boolean result of the atomic_compare_exchange.
1446         (sparc_expand_compare_and_swap): New.
1447         * config/sparc/sync.md (atomic_compare_and_swap<I>): New.
1448         (atomic_compare_and_swap<I48MODE>_1): Rename from
1449         *sync_compare_and_swap<I48MODE>, use mem_noofs_operand.
1450         (*atomic_compare_and_swapdi_v8plus): Rename from
1451         *sync_compare_and_swapdi_v8plus, use mem_noofs_operand.
1452         (sync_compare_and_swap<I12MODE>): Remove.
1453         (sync_compare_and_swap<I48MODE>): Remove.
1454
1455 2011-11-30  Richard Henderson  <rth@redhat.com>
1456
1457         * config/sparc/predicates.md (register_or_v9_zero_operand): New.
1458         * config/sparc/sparc.md (UNSPEC_ATOMIC): New.
1459         * config/sparc/sync.md (atomic_load<I>): New.
1460         (atomic_loaddi_1, atomic_store<I>, atomic_storedi_1): New.
1461
1462 2011-11-30  Richard Henderson  <rth@redhat.com>
1463
1464         * config/sparc/predicates.md (zero_or_v7_operand): New.
1465         * config/sparc/sparc.c (sparc_emit_membar_for_model): New.
1466         * config/sparc/sparc-protos.h: Update.
1467         * config/sparc/sync.md (mem_thread_fence): New.
1468         (memory_barrier): Use sparc_emit_membar_for_model.
1469         (membar, *membar_empty, *membar_storestore, *membar_storeload): New.
1470         (*membar_v8): Accept and ignore the membar mask.
1471         (*membar): Accept and print the membar mask.
1472
1473 2011-11-30  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
1474
1475         * config/arm/arm.c (arm_issue_rate): Cortex-A15 can triple issue.
1476         * config/arm/arm.md (mul64): New attribute.
1477         (generic_sched): Cortex-A15 is not scheduled generically.
1478         (cortex-a15.md): Include.
1479         * config/arm/cortex-a15.md: New machine description.
1480         * config/arm/t-arm (MD_INCLUDES): Add cortex-a15.md.
1481
1482 2011-11-30  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
1483
1484         * config/arm/t-arm (MD_INCLUDES): Ensure all md files are listed.
1485
1486 2011-11-30  Iain Sandoe  <iains@gcc.gnu.org>
1487
1488         * doc/tm.texi.in (NEXT_OBJC_RUNTIME): Update macro description.
1489         * doc/tm.texi: Regenerate.
1490         * flags.h (flag_next_runtime): Remove references.
1491         * toplev.c: Likewise.
1492         * defaults.h (NEXT_OBJC_RUNTIME): Provide default.
1493         * gccspec.c (lang_specific_driver): Adjust use of NEXT_OBJC_RUNTIME.
1494         * config/darwin.c (darwin_override_options): Provide default
1495         Objective-C abi settings and target conflict checks.
1496         * config/darwin.h (SUBTARGET_C_COMMON_OVERRIDE_OPTIONS): Remove unused
1497         code. Adjust indenting.
1498
1499 2011-11-29  Joseph Myers  <joseph@codesourcery.com>
1500
1501         * config/sh/sh.h (enum reg_class, REG_CLASS_NAMES)
1502         (REG_CLASS_CONTENTS): Add NON_SP_REGS.
1503         (REGCLASS_HAS_GENERAL_REG): Handle NON_SP_REGS.
1504         * config/sh/constraints.md (u): New constraint.
1505
1506 2011-11-29  Oleg Endo  <oleg.endo@t-online.de>
1507
1508         PR target/51337
1509         * config/sh/sh.c (sh_secondary_reload): Add case when FPUL
1510         register is being loaded from a pseudo in memory.
1511
1512 2011-11-29  DJ Delorie  <dj@redhat.com>
1513
1514         * config.gcc (rl78-*-elf): New case.
1515         * doc/extend.texi: Add RL78 documentation.
1516         * doc/invoke.texi: Likewise.
1517         * doc/md.texi: Likewise.
1518         * doc/contrib.texi: Add RL78.
1519         * doc/install.texi: Add rl78-*-elf.
1520         * config/rl78: New directory for the Renesas RL78.
1521
1522 2011-11-29  Jakub Jelinek  <jakub@redhat.com>
1523
1524         PR tree-optimization/51247
1525         * tree-vrp.c (extract_range_from_assert): For signed 1-bit precision
1526         types instead of adding 1 subtract -1 and instead of subtracting 1
1527         add -1 to avoid overflows.
1528
1529 2011-11-29  Andrew MacLeod  <amacleod@redhat.com>
1530
1531         PR target/50123
1532         * optabs.c (maybe_optimize_fetch_op): New.  Look for more optimal
1533         instructions for a FECTH_OP or OP_FECTH sequence.
1534         (expand_atomic_fetch_op): Call maybe_optimize_fetch_op.
1535
1536 2011-11-29  Uros Bizjak  <ubizjak@gmail.com>
1537
1538         * config/i386/sync.md (UNSPEC_LDA, UNSPEC_STA): New unspecs.
1539         (movdi_via_fpu): Remove.
1540         (loaddi_via_fpu): New insn pattern.
1541         (storedi_via_fpu): Ditto.
1542         (atomic_loaddi_fpu): Use loaddi_via_fpu and storedi_via_fpu.
1543         (atomic_storedi_fpu): Ditto.
1544         * reg-stack.c (get_true_reg): Handle UNSPEC_LDA.
1545         (subst_stack_regs_pat): Handle UNSPEC_STA.
1546
1547 2011-11-29  Uros Bizjak  <ubizjak@gmail.com>
1548
1549         * config/i386/i386.md (*floathi<mode>2_i387_with_temp): Do not
1550         allocate scratch memory for alternative 0.
1551
1552 2011-11-29  Michael Meissner  <meissner@linux.vnet.ibm.com>
1553
1554         * config/rs6000/rs6000-builtins.def: Completely rewrite builtin
1555         handling to centralize more of the builtins in this file.  Change
1556         some builtin enumerations to be more consistant.  Use a new mask
1557         to hold the current builtins, including SPE and PAIRED builtins
1558         which no longer are set via target_flags masks.  Add
1559         -mdebug=builtin debug support.  For power machines, define all
1560         Altivec and VSX buitins when the compiler starts, but don't allow
1561         the use of a builtin unless the appropriate switch is used, or
1562         #pragma GCC target is used to change the options.  If the user
1563         uses #pragma GCC target, update the appropriate hardware macros.
1564         * common/config/rs6000/rs6000-common.c (rs6000_handle_option): Ditto.
1565         * config/rs6000/rs6000.opt (rs6000_builtin_mask): Ditto.
1566         * config/rs6000/rs6000-c.c (rs6000_macro_to_expand): Ditto.
1567         (rs6000_define_or_undefine_macro): Ditto.
1568         (rs6000_target_modify_macros): Ditto.
1569         (rs6000_cpu_cpp_builtins): Ditto.
1570         (altivec_overloaded_builtins): Ditto.
1571         (altivec_build_resolved_builtin): Ditto.
1572         * config/rs6000/rs6000.c (rs6000_target_modify_macros_ptr): Ditto.
1573         (rs6000_builtin_info): Ditto.
1574         (def_builtin): Ditto.
1575         (enable_mask_for_builtins): Ditto.
1576         (DEBUG_FMT_X): Ditto.
1577         (rs6000_debug_reg_global): Ditto.
1578         (rs6000_builtin_mask_calculate): Ditto.
1579         (rs6000_option_override_internal): Ditto.
1580         (rs6000_builtin_conversion): Ditto.
1581         (rs6000_builtin_vectorized_function): Ditto.
1582         (bdesc_3arg): Ditto.
1583         (bdesc_dst): Ditto.
1584         (bdesc_2arg): Ditto.
1585         (builtin_description_predicates): Ditto.
1586         (bdesc_altivec_preds): Ditto.
1587         (bdesc_spe_predicates): Ditto.
1588         (bdesc_spe_evsel): Ditto.
1589         (bdesc_paired_preds): Ditto.
1590         (bdesc_abs): Ditto.
1591         (bdesc_1arg): Ditto.
1592         (rs6000_overloaded_builtin_p): Ditto.
1593         (rs6000_expand_unop_builtin): Ditto.
1594         (bdesc_2arg_spe): Ditto.
1595         (spe_expand_builtin): Ditto.
1596         (rs6000_invalid_builtin): Ditto.
1597         (rs6000_expand_builtin): Ditto.
1598         (rs6000_init_builtins): Ditto.
1599         (spe_init_builtins): Ditto.
1600         (paired_init_builtins): Ditto.
1601         (altivec_init_builtins): Ditto.
1602         (builtin_function_type): Ditto.
1603         (rs6000_common_init_builtins): Ditto.
1604         (rs6000_builtin_reciprocal): Ditto.
1605         (rs6000_builtin_mask_names): Ditto.
1606         (rs6000_pragma_target_parse): Ditto.
1607         (rs6000_function_specific_print): Ditto.
1608         * config/rs6000/rs6000.h (MASK_DEBUG_BUILTIN): Ditto.
1609         (MASK_DEBUG_ALL): Ditto.
1610         (TARGET_DEBUG_BUILTIN): Ditto.
1611         (TARGET_EXTRA_BUILTINS): Ditto.
1612         (REGISTER_TARGET_PRAGMAS): Ditto.
1613         (enum rs6000_btc): Ditto.
1614         (RS6000_BTC_*): Ditto.
1615         (RS6000_BTM_*): Ditto.
1616         (enum rs6000_builtins): Ditto.
1617         * config/rs6000/rs6000-protos.h (rs6000_overloaded_builtin_p): Ditto.
1618         (rs6000_target_modify_macros): Ditto.
1619         (rs6000_target_modify_macros_ptr): Ditto.
1620
1621         * config/rs6000/vector.md (unsfloat<VEC_int><mode>2): Use the
1622         standard name for converting vector unsigned values to floating
1623         point.  Delete the TARGET_VECTORIZE_BUILTIN_CONVERSION hook, which
1624         is handled by machine independent code.
1625         * config/rs6000/rs6000.c (TARGET_VECTORIZE_BUILTIN_CONVERSION): Ditto.
1626         (rs6000_builtin_conversion): Ditto.
1627
1628 2011-11-29  Dodji Seketeli  <dodji@redhat.com>
1629
1630         * tree-diagnostic (struct loc_t): Rename into struct loc_map_pair.
1631         (maybe_unwind_expanded_macro_loc): Adjust.
1632
1633 2011-11-29  David Edelsohn  <dje.gcc@gmail.com>
1634             Aldy Hernandez  <aldyh@redhat.com>
1635
1636         * trans-mem.c (ipa_tm_create_version_alias): Mangle new_decl
1637         if DECL_ONE_ONLY.
1638         (ipa_tm_create_version): Same.
1639
1640 2011-11-29  Bernd Schmidt  <bernds@codesourcery.com>
1641
1642         * haifa-sched.c (recompute_todo_spec): Simplify and correct the
1643         code checking for a clobber of a condition register when deciding
1644         whether to predicate.
1645
1646 2011-11-29  Diego Novillo  <dnovillo@google.com>
1647
1648         * gimple.c (gimple_call_set_cannot_inline): Move from gimple.h.
1649         Update field call_stmt_cannot_inline_p from call graph edge, if needed.
1650         * gimple.h (gimple_call_set_cannot_inline): Move to gimple.c.
1651
1652 2011-11-29  Sameera Deshpande  <sameera.deshpande@arm.com>
1653
1654         * config/arm/arm.md (arm_movdi): Update NEG_POOL_RANGE.
1655         (movdf_soft_insn): Likewise.
1656         * config/arm/fpa.md (thumb2_movdf_fpa): Likewise.
1657         * config/arm/neon.md (neon_mov<mode>): Likewise.
1658         * config/arm/vfp.md (movdi_vfp): Likewise.
1659         (movdi_vfp_cortexa8): Likewise.
1660         (movdf_vfp): Likewise.
1661
1662 2011-11-29  Jakub Jelinek  <jakub@redhat.com>
1663
1664         PR middle-end/50074
1665         * expr.c (expand_expr_addr_expr_1): Don't call force_operand for
1666         EXPAND_SUM modifier.
1667
1668 2011-11-29  Ira Rosen  <ira.rosen@linaro.org>
1669
1670         PR tree-optimization/51301
1671         * tree-vect-patterns.c (vect_recog_over_widening_pattern): Check that
1672         the last statement doesn't convert to a bigger type than the original
1673         type of the computation.
1674
1675 2011-11-28  Richard Henderson  <rth@redhat.com>
1676
1677         * config/rs6000/rs6000.c (rs6000_expand_atomic_compare_and_swap):
1678         Handle overlap between retval and oldval.  Always compute boolval
1679         from CR0 EQ value.
1680
1681 2011-11-28  Jakub Jelinek  <jakub@redhat.com>
1682
1683         PR debug/50317
1684         * tree-ssa.c (execute_update_addresses_taken): Remove
1685         var ={v} {CLOBBER} stmts instead of rewriting them into
1686         var_N ={v} {CLOBBER}.
1687
1688         PR middle-end/50907
1689         * function.c (convert_jumps_to_returns): When redirecting an edge
1690         succ to EXIT_BLOCK_PTR, clear EDGE_CROSSING flag.
1691
1692         PR tree-optimization/50078
1693         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Copy over
1694         TREE_THIS_VOLATILE also from the old to new lhs resp. rhs.
1695
1696         PR tree-optimization/50682
1697         * tree-eh.c (maybe_remove_unreachable_handlers): New function.
1698         * tree-flow.h (maybe_remove_unreachable_handlers): New prototype.
1699         * tree-optimize.c (execute_cleanup_cfg_post_optimizing): Call it.
1700
1701 2011-11-28  Georg-Johann Lay  <avr@gjlay.de>
1702
1703         * doc/extend.texi (AVR Built-in Functions): Add documentation for
1704         __builtin_avr_map8 and __builtin_avr_map16.
1705
1706         * config/avr/avr.md: Document new %t and %T asm output codes.
1707         (define_c_enum "unspec"): Add UNSPEC_MAP_BITS.
1708         (adjust_len): Add map_bits.
1709         (map_bitsqi, map_bitshi): New insns.
1710         * config/avr/avr-protos.h (avr_out_map_bits): New.
1711         * config/avr/avr-protos.c (print_operand): Implement %t and %T.
1712         (adjust_insn_length): Handle ADJUST_LEN_MAP_BITS.
1713         (avr_double_int_push_digit): New function.
1714         (avr_map, avr_revert_map, avr_swap_map, avr_id_map): New functions.
1715         (avr_sig_map, avr_map_hamming_byte): New functions.
1716         (avr_out_swap_bits, avr_out_revert_bits, avr_move_bits,
1717         avr_out_map_bits): New functions.
1718         (enum avr_builtin_id): Add AVR_BUILTIN_MAP8, AVR_BUILTIN_MAP16.
1719         (avr_init_builtins): Populate __builtin_avr_map8, __builtin_avr_map16.
1720         (bdesc_2arg): Add __builtin_avr_map8, __builtin_avr_map16 ...
1721         (avr_expand_builtin): ...and expand them.
1722         * config/avr/avr-c.c (avr_cpu_cpp_builtins): New built-in defines:
1723         __BUILTIN_AVR_MAP8, __BUILTIN_AVR_MAP16.
1724
1725 2011-11-27  Richard Sandiford  <rdsandiford@googlemail.com>
1726
1727         PR target/51278
1728         * config/mips/mips.c (mips_rtx_costs): Handle baddu.
1729
1730 2011-11-27  Richard Sandiford  <rdsandiford@googlemail.com>
1731
1732         * config/mips/mips.c (mips16_unextended_reference_p): Test for BLKmode.
1733
1734 2011-11-27  Richard Sandiford  <rdsandiford@googlemail.com>
1735
1736         * config/mips/mips-protos.h (mips_emit_binary): Declare.
1737         * config/mips/mips.c (mips_emit_binary): Make global.
1738         (mips_set_mips16_mode): Turn off -mfix-r4000 in MIPS16 mode.
1739         (mips_conditional_register_usage): Don't treat LO and HI as
1740         register operands in MIPS16 mode.
1741         (mips_mulsidi3_gen_fn): Use {u,}mulsidi3_{32,64}bit_mips16
1742         for MIPS16 code.
1743         * config/mips/predicates.md (muldiv_target_operand): New predicate.
1744         (move_operand): Allow hilo_operand.
1745         * config/mips/mips.md (mul<mode>3): Explicitly specify LO as the
1746         target of MIPS16 multiplies, then move it into the target register.
1747         (mul<mode>3_internal, *macc2, *msac2): Use muldiv_target_operand.
1748         (<u>mulsidi3_32bit_mips16): New expander.
1749         (<u>mulsidi3_32bit): Use muldiv_target_operand.
1750         (<u>mulsidi3_32bit_r4000): Disable for ISA_HAS_DSP.
1751         (<u>mulsidi3_64bit): Require !TARGET_MIPS16.  Split into
1752         <u>mulsidi3_64bit_split.
1753         (<u>mulsidi3_64bit_mips16): New expander.
1754         (<u>mulsidi3_64bit_split): Likewise, using expansions from
1755         two previous define_splits.
1756         (<u>mulsidi3_64bit_hilo, *muls<u>_di, <u>msubsidi4): Use
1757         muldiv_target_operand.
1758         (<su>mulsi3_highpart): Use <su>mulsi3_highpart_split for MIPS16 code.
1759         (<su>mulsi3_highpart_internal): Require !TARGET_MIPS16.
1760         Split into <su>mulsi3_highpart_split.
1761         (<su>mulsi3_highpart_split): New expander.
1762         (<su>muldi3_highpart): Turn into a define_expand.
1763         Use <su>muldi3_highpart_split for MIPS16 code.
1764         (<su>muldi3_highpart_internal): Renamed from <su>muldi3_highpart.
1765         Require !TARGET_MIPS16.  Split into <su>muldi3_highpart_split.
1766         (<su>muldi3_highpart_split): New expander.
1767         (<u>mulditi3): Explicitly specify LO as the target of MIPS16
1768         multiplies, then move it into the target register.
1769         (<u>mulditi3_internal, <u>maddsidi4): Use muldiv_target_operand.
1770         (divmod<mode>4, udivmod<mode>4): Turn into define_expands.
1771         Use <u>divmod<mode>4_split for MIPS16 code, then explicitly
1772         move LO into operand 0.
1773         (divmod<mode>4_internal, udivmod<mode>4_internal): Renamed
1774         from <u>divmod<mode>4.  Use muldiv_target_operand.
1775         Require !TARGET_MIPS16.  Split into <u>divmod<mode>4_split.
1776         (<u>divmod<mode>4_split): New expander.
1777         (<u>divmod<GPR:mode>4_hilo_<HILO:mode>): Use muldiv_target_operand.
1778         (mfhi<GPR:mode>_<HILO:mode>): Use hilo_operand.
1779
1780 2011-11-27  Richard Sandiford  <rdsandiford@googlemail.com>
1781
1782         * hard-reg-set.h (target_hard_regs): Add x_accessible_reg_set
1783         and x_operand_reg_set.
1784         (accessible_reg_set, operand_reg_set): New macros.
1785         * reginfo.c (init_reg_sets): Initialize accessible_reg_set and
1786         operand_reg_set.
1787         (saved_accessible_reg_set, saved_operand_reg_set): New variables.
1788         (save_register_info): Save them.
1789         (restore_register_info): Restore them.
1790         (init_reg_sets_1): Limit operand_reg_set to accessible_reg_set.
1791         Remove NO_REGS registers from operand_reg_set.  Treat members
1792         of operand_reg_set as fixed.
1793         * recog.c (general_operand): Check operand_reg_set rather than NO_REGS.
1794         (register_operand, nonmemory_operand): Likewise.
1795         * varasm.c (make_decl_rtl): Always use DECL_MODE as the mode of
1796         register variables.  Check accessible_reg_set and operand_reg_set.
1797         * config/mips/mips.c (mips_conditional_register_usage): Remove
1798         inaccessible register from accessible_reg_set, rather than just
1799         making them fixed.
1800
1801 2011-11-27  Gerald Pfeifer  <gerald@pfeifer.com>
1802
1803         * config/pa/pa-linux.h (TARGET_GAS): Remove comment.
1804
1805 2011-11-26  Richard Henderson  <rth@redhat.com>
1806
1807         * config/arm/arm.c (arm_init_libfuncs): Call init_sync_libfuncs
1808         for Linux.
1809
1810 2011-11-26  Richard Henderson  <rth@redhat.com>
1811
1812         * optabs.c (expand_atomic_fetch_op): Always return result.
1813
1814         * optabs.c (init_sync_libfuncs_1): Include max in iteration.
1815
1816         * omp-low.c (expand_omp_atomic): Assume anything aligned to
1817         BIGGEST_ALIGNMENT is aligned.
1818
1819 2011-11-26  Richard Henderson  <rth@redhat.com>
1820
1821         * config/m68k/m68k.md (UNSPECV_CAS_1, UNSPECV_CAS_2): New.
1822         (UNSPECV_TAS_1, UNSPECV_TAS_2): New.
1823         (I): New mode iterator.
1824         (xz): New mode attribute.
1825         * config/m68k/sync.md: New file.
1826
1827         * config/m68k/linux.h (TARGET_INIT_LIBFUNCS): New.
1828         * config/m68k/m68k.c (m68k_init_sync_libfuncs): New.
1829
1830 2011-11-26  Nathan Sidwell  <nathan@acm.org>
1831
1832         PR gcov-profile/51297
1833         * gcov.c (main): Allocate initial names and sources arrays.
1834         (find_source): Don't check for null name or source arrays here.
1835
1836 2011-11-26  Jakub Jelinek  <jakub@redhat.com>
1837
1838         PR rtl-optimization/49912
1839         * cfgrtl.c (rtl_verify_flow_info_1): Ignore also EDGE_PRESERVE bit
1840         when counting n_branch.
1841
1842 2011-11-26  Uros Bizjak  <ubizjak@gmail.com>
1843
1844         * config/i386/sync.md (movdi_via_fpu): Add %Z insn suffixes.
1845
1846 2011-11-26  Joern Rennecke  <joern.rennecke@embecosm.com>
1847
1848         PR middle-end/50074
1849         * calls.c (mem_overlaps_already_clobbered_arg_p):
1850         Return false if no outgoing arguments have been stored so far.
1851
1852 2011-11-25  Georg-Johann Lay  <avr@gjlay.de>
1853
1854         * config/avr/avr.c (print_operand): Support code = 'i' for CONST_INT.
1855
1856 2011-11-24  Andrew MacLeod  <amacleod@redhat.com>
1857
1858         PR other/51011
1859         * tree.h (is_builtin_name): No longer external.
1860         * builtins.c (is_builtin_name): Make static.
1861         * varasm.c (incorporeal_function_p): __sync and __atomic external calls
1862         are not incorporeal and may need asm label processing.
1863
1864 2011-11-25  Georg-Johann Lay  <avr@gjlay.de>
1865
1866         PR target/50566
1867         * config/avr/avr-protos.h (avr_log_t): Add field .builtin.
1868         * config/avr/avr-log.c (avr_log_set_avr_log): Initialize it.
1869         Don't bypass TARGET_ALL_DEBUG.  Print self-info with ?.
1870         (avr_log_vadump): Support %D and %X to print double_int.
1871         (avr_double_int_pop_digit): New static function.
1872         (avr_dump_double_int_hex): New static function.
1873
1874 2011-11-24  Enkovich Ilya  <ilya.enkovich@intel.com>
1875
1876         PR target/51287
1877         * config/i386/i386.c (distance_non_agu_define_in_bb): Fix insn
1878         attr check.
1879
1880 2011-11-24  Andrew MacLeod  <amacleod@redhat.com>
1881
1882         * optab.c (maybe_emit_atomic_exchange): New.  Try to emit an
1883         atomic_exchange pattern.
1884         (maybe_emit_sync_lock_test_and_set): New.  Try to emit an exchange
1885         using __sync_lock_test_and_set.
1886         (maybe_emit_compare_and_swap_exchange_loop): New. Try to emit an
1887         exchange using a compare_and_swap loop.
1888         (expand_sync_lock_test_and_set): New.  Expand sync_lock_test_and_set.
1889         (expand_atomic_test_and_set): New.  Expand test_and_set operation.
1890         (expand_atomic_exchange): Use new maybe_emit_* functions.
1891         (expand_atomic_store): Use new maybe_emit_* functions.
1892         * builtins.c (expand_builtin_sync_lock_test_and_set): Call
1893         expand_sync_lock_test_and_set routine.
1894         (expand_builtin_atomic_exchange): Remove parameter from call.
1895         (expand_builtin_atomic_clear): Use atomic_clear pattern if present.
1896         (expand_builtin_atomic_test_and_set): Add target and simply call
1897         expand_atomic_test_and_set.
1898         (expand_builtin): Add target to expand_builtin_atomic_test_and_set.
1899         * expr.h (expand_atomic_exchange): Add parameter.
1900         (expand_sync_lock_test_and_set): New prototype.
1901         (expand_atomic_test_and_set, expand_atomic_clear): New prototypes.
1902
1903 2011-11-24  H.J. Lu  <hongjiu.lu@intel.com>
1904
1905         PR target/51134
1906         * config/i386/i386.h (processor_costs): Revert revision 181357.
1907         * config/i386/i386.c (cost models): Likewise.
1908         (core_cost): Likewise.
1909         (promote_duplicated_reg): Likewise.
1910         (promote_duplicated_reg_to_size): Likewise.
1911         (processor_target): Likewise.
1912         (expand_set_or_movmem_via_loop_with_iter): Likewise.
1913         (expand_set_or_movmem_via_loop): Likewise.
1914         (emit_strset): Likewise.
1915         (expand_movmem_epilogue): Likewise.
1916         (expand_setmem_epilogue): Likewise.
1917         (expand_movmem_prologue): Likewise.
1918         (expand_setmem_prologue): Likewise.
1919         (expand_constant_movmem_prologue): Likewise.
1920         (expand_constant_setmem_prologue): Likewise.
1921         (decide_alg): Likewise.
1922         (decide_alignment): Likewise.
1923         (ix86_expand_movmem): Likewise.
1924         (ix86_expand_setmem): Likewise.
1925         (ix86_slow_unaligned_access): Likewise.
1926         * config/i386/i386.md (strset): Likewise.
1927         * config/i386/sse.md (vec_dupv4si): Likewise.
1928         (vec_dupv2di): Likewise.
1929
1930 2011-11-24  Georg-Johann Lay  <avr@gjlay.de>
1931
1932         * config/avr/avr.md (*rotlhi2.15): Set length to 4.
1933
1934 2011-11-24  Razya Ladelsky  <razya@il.ibm.com>
1935
1936         * tree-data-ref.c (initialize_data_dependence_relation): Update
1937         comment for the self dependence case.
1938         (compute_self_dependence): Remove.
1939         * tree-vect-data-refs.c (vect_analyze_data_refs): Remove call to
1940         compute_self_dependenc.
1941
1942 2011-11-24  Alan Modra  <amodra@gmail.com>
1943
1944         * c-decl.c (warn_if_shadowing): Don't warn if shadowed
1945         identifier is from system header.
1946
1947 2011-11-23  Jakub Jelinek  <jakub@redhat.com>
1948
1949         PR target/51261
1950         * config/i386/i386.c (decide_alg): Initialize *dynamic_check
1951         even if !optimize.
1952
1953 2011-11-23  Vladimir Makarov  <vmakarov@redhat.com>
1954
1955         PR rtl-optimization/48455
1956         * doc/invoke.texi (-fira-region): Document default values.
1957
1958         * flags-types.h (enum ira_region): Add new value
1959         IRA_REGION_AUTODETECT.
1960
1961         * common.opt (fira-region): Set up initial value to
1962         IRA_REGION_AUTODETECT.
1963
1964         * toplev.c (process_options): Set up flag_ira_region depending on
1965         -O options.
1966
1967         * ira.c (ira.c): Remove optimize guard for ira_build.
1968
1969 2011-11-23  Chung-Lin Tang  <cltang@codesourcery.com>
1970
1971         PR rtl-optimization/50496
1972         * jump.c (redirect_jump): Assert fail on nlabel == NULL_RTX
1973         only after epilogue is created. Add comments.
1974
1975 2011-11-22  Richard Henderson  <rth@redhat.com>
1976
1977         * config/ia64/ia64.c (ia64_expand_atomic_op): Add model parameter.
1978         Generate the barrier required for the memory model.
1979         (rtx_needs_barrier): Handle UNSPEC_FETCHADD_REL, UNSPEC_CMPXCHG_REL.
1980         * config/ia64/ia64-protos.h: Update.
1981         * config/ia64/ia64.md (UNSPEC_FETCHADD_REL): New.
1982         (UNSPEC_CMPXCHG_REL): New.
1983         * config/ia64/sync.md (mem_thread_fence): New.
1984         (atomic_load<IMODE>, atomic_store<IMODE>): New.
1985         (atomic_compare_and_swap<IMODE>): New.
1986         (cmpxchg_acq_<I124MODE>, cmpxchg_acq_di): New.
1987         (atomic_exchange<IMODE>): New.
1988         (xchg_acq_<IMODE>): Rename from sync_lock_test_and_set<IMODE>.
1989         (atomic_<FETCHOP><IMODE>, atomic_nand<IMODE>): New.
1990         (atomic_fetch_<FETCHOP><IMODE>, atomic_fetch_nand<IMODE>): New.
1991         (atomic_<FETCHOP>_fetch<IMODE>, atomic_nand_fetch<IMODE>): New.
1992         (fetchadd_rel_<I48MODE>): New.
1993         (sync_<FETCHOP><IMODE>, sync_nand<IMODE>): Remove.
1994         (sync_old_<FETCHOP><IMODE>, sync_old_nand<IMODE>): Remove.
1995         (sync_new_<FETCHOP><IMODE>, sync_new_nand<IMODE>): Remove.
1996         (sync_compare_and_swap<IMODE>): Remove.
1997         (sync_lock_release<IMODE>): Remove.
1998
1999         * config/ia64/ia64.md: Use define_c_enum for UNSPEC_*
2000         and UNSPECV_* constants.
2001
2002 2011-11-22  Tom de Vries  <tom@codesourcery.com>
2003
2004         PR rtl-optimization/50764
2005         * sched-deps.c (sched_analyze_insn): Make sure frame-related insns are
2006         not moved past preceding jump.
2007
2008 2011-11-22  Jeff Law  <law@redhat.com>
2009
2010         * doc/contrib.texi: Add entry for David Binderman.
2011
2012 2011-11-22  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
2013
2014         * postreload.c (reload_combine): Mark reg_state as invalid at
2015         volatile insns if there has been a use already.
2016
2017 2011-11-21  Aldy Hernandez  <aldyh@redhat.com>
2018
2019         * opts.c (finish_options): Do not fail for -fgnu-tm.
2020         * gimple-streamer-out.c (output_gimple_stmt): Handle
2021         GIMPLE_TRANSACTION.
2022         * gimple-streamer-in.c (input_gimple_stmt): Same.
2023         * lto-cgraph.c (input_overwrite_node): Read tm_clone bit.
2024         (lto_output_node): Write tm_clone bit.
2025
2026 2011-11-22  Ian Lance Taylor  <iant@google.com>
2027
2028         * doc/install.texi (Configuration): Correct doc of
2029         --enable-build-poststage1-with-cxx: it is not experimental.
2030
2031 2011-11-22  Jakub Jelinek  <jakub@redhat.com>
2032
2033         PR tree-optimization/51074
2034         * fold-const.c (fold_binary_loc): Fix up VEC_INTERLEAVE_*_EXPR
2035         handling for BYTES_BIG_ENDIAN.
2036         * optabs.c (can_vec_perm_for_code_p): Likewise.
2037
2038 2011-11-22  Michael Matz  <matz@suse.de>
2039
2040         PR other/51125
2041         * trans-mem.c (expand_block_tm): Ignore clobbers.
2042
2043 2011-11-22  Iain Sandoe  <iains@gcc.gnu.org>
2044
2045         *  config/darwin.h (ENDFILE_SPEC): New.
2046         (DARWIN_CRT1_SPEC): Add crttms.o.
2047         (STARTFILE_SPEC): Likewise for dynamic libs and bundles.
2048         * config/i386.h (ENDFILE_SPEC): Amend to include crttme.o.
2049
2050 2011-11-22  Michael Matz  <matz@suse.de>
2051
2052         PR c++/51264
2053         * tree.c (iterative_hash_expr): Remove break after return.
2054
2055 2011-11-22  Iain Sandoe  <iains@gcc.gnu.org>
2056
2057         * target.def (tm_clone_table_section): New hook.
2058         * doc/tm.texi.in (TARGET_ASM_TM_CLONE_TABLE_SECTION): Define.
2059         * doc/tm.texi: Regenerate.
2060         * varasm.c (dump_tm_clone_pairs): Use target tm_clone_table_section.
2061         * output.h (default_clone_table_section): New prototype.
2062         * config/darwin.h (TARGET_ASM_TM_CLONE_TABLE_SECTION): New.
2063         * config/darwin-protos.h (darwin_tm_clone_table_section): New prototype.
2064         * config/darwin.c (darwin_tm_clone_table_section): New.
2065
2066 2011-11-21  Torvald Riegel  <triegel@redhat.com>
2067
2068         * trans-mem.c (diagnose_tm_1): Print an expression instead of a
2069         declaration in error messages for indirect calls.
2070
2071 2011-11-21  David S. Miller  <davem@davemloft.net>
2072
2073         * config/sparc/sparc.c (sparc_regmode_natural_size): New function
2074         implementing REGMODE_NATURAL_SIZE taking into consideration vector
2075         modes.
2076         (sparc_modes_tieable_p): Similarly for MODES_TIEABLE_P.
2077         * config/sparc/sparc-protos.h (sparc_regmode_natural_size,
2078         sparc_modes_tieable_p): Declare.
2079         * gcc/config/sparc/sparc.h (REGMODE_NATURAL_SIZE,
2080         MODES_TIEABLE_P): Use new helper functions.
2081
2082         Revert
2083         2011-11-16  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
2084
2085         PR middle-end/50325
2086         * expmed.c (store_bit_field_1): Use extract_bit_field on big
2087         endian targets if the source cannot be exactly covered by word
2088         mode chunks.
2089
2090 2011-11-21  Jakub Jelinek  <jakub@redhat.com>
2091
2092         PR debug/50827
2093         * var-tracking.c (loc_cmp): For ENTRY_VALUEs use ENTRY_VALUE_EXP
2094         macro instead of XEXP.
2095
2096 2011-11-21  Andreas Tobler  <andreast@fgznet.ch>
2097
2098         * configure: Regenerate.
2099
2100 2011-11-21  Georg-Johann Lay  <avr@gjlay.de>
2101
2102         * config/avr/avr.c (output_reload_in_const): Loading a byte with 0
2103         must not affect cc0.
2104         * config/avr/avr.md (*movhi, *movpsi, *movsi, *movsf): Zero to any
2105         register does not change cc0. Same for any constant to ld-register.
2106
2107 2011-11-21  Uros Bizjak  <ubizjak@gmail.com>
2108
2109         * config/i386/mmx.md (unspec) <UNSPEC_MOVNTQ, UNSPEC_PFRCP,
2110         UNSPEC_PFRCPIT1, UNSPEC_PFRCPIT2, UNSPEC_PFRSQRT, UNSPEC_PFRSQIT1>:
2111         Move from config/i386/i386.md
2112         (unspecv) <UNSPECV_EMMS, UNSPECV_FEMMS>: Ditto.
2113         * config/i386/sse.md (unspec) <UNSPEC_MOVNT,UNSPEC_MOVU, UNSPEC_LDDQU,
2114         UNSPEC_PSHUFB, UNSPEC_PSIGN, UNSPEC_PALIGNR, UNSPEC_EXTRQI,
2115         UNSPEC_EXTRQ, UNSPEC_INSERTQI, UNSPEC_INSERTQ, UNSPEC_BLENDV,
2116         UNSPEC_INSERTPS, UNSPEC_DP, UNSPEC_MOVNTDQA, UNSPEC_MPSADBW,
2117         UNSPEC_PHMINPOSUW, UNSPEC_PTEST, UNSPEC_PCMPESTR, UNSPEC_PCMPISTR,
2118         UNSPEC_FMADDSUB, UNSPEC_XOP_UNSIGNED_CMP, UNSPEC_XOP_TRUEFALSE,
2119         UNSPEC_XOP_PERMUTE, UNSPEC_FRCZ, UNSPEC_AESENC, UNSPEC_AESENCLAST,
2120         UNSPEC_AESDEC, UNSPEC_AESDECLAST, UNSPEC_AESIMC,
2121         UNSPEC_AESKEYGENASSIST, UNSPEC_PCLMUL, UNSPEC_PCMP, UNSPEC_VPERMIL,
2122         UNSPEC_VPERMIL2, UNSPEC_VPERMIL2F128, UNSPEC_CAST, UNSPEC_VTESTP,
2123         UNSPEC_VCVTPH2PS, UNSPEC_VCVTPS2PH, UNSPEC_VPERMSI, UNSPEC_VPERMDF,
2124         UNSPEC_VPERMSF, UNSPEC_VPERMTI, UNSPEC_GATHER, UNSPEC_VSIBADDR>: Ditto.
2125         (unspecv) <UNSPECV_LDMXCSR, UNSPECV_STMXCSR, UNSPECV_CLFLUSH,
2126         UNSPECV_MONITOR, UNSPECV_MWAIT, UNSPECV_VZEROALL, UNSPECV_VZEROUPPER>:
2127         Ditto.
2128         * config/i386/sync.md (unspec) <UNSPEC_LFENCE, UNSPEC_SFENCE,
2129         UNSPEC_MFENCE, UNSPEC_MOVA>: Ditto.
2130         (unspecv) <UNSPECV_CMPXCHG_1, UNSPECV_CMPXCHG_2, UNSPECV_CMPXCHG_3,
2131         UNSPECV_CMPXCHG_4, UNSPECV_XCHG, UNSPECV_LOCK>: Ditto.
2132         (sse2_lfence): Move from config/i386/sse.md.
2133         (*sse2_lfence): Ditto.
2134         (sse_sfence): Ditto.
2135         (*sse_sfence): Ditto.
2136         (sse2_mfence): Ditto.
2137         (mfence_sse2): Ditto.  Rename from *sse2_mfence.  Enable also
2138         for TARGET_64BIT.
2139         (mem_thread_fence): Use mfence_sse2.
2140
2141 2011-11-21  Georg-Johann Lay  <avr@gjlay.de>
2142
2143         * config/avr/avr.h (struct base_arch_s): Add field sfr_offset.
2144         * config/avr/avr-devices.c: Ditto. And initialize it.
2145         * config/avr/avr-c.c (avr_cpu_cpp_builtins): New built-in define
2146         __AVR_SFR_OFFSET__.
2147         * config/avr/avr-protos.h (out_movqi_r_mr, out_movqi_mr_r): Remove.
2148         (out_movhi_r_mr, out_movhi_mr_r): Remove.
2149         (out_movsi_r_mr, out_movsi_mr_r): Remove.
2150         * config/avr/avr.md (*cbi, *sbi): Use %i instead of %m-0x20.
2151         (*insv.io, *insv.not.io): Ditto.
2152         * config/avr/avr.c (out_movsi_r_mr, out_movsi_mr_r): Make static.
2153         (print_operand): Implement "%i" to print address as I/O address.
2154         (output_movqi): Clean up call of out_movqi_mr_r.
2155         (output_movhi): Clean up call of out_movhi_mr_r.
2156         (avr_file_start): Use avr_current_arch->sfr_offset instead of
2157         magic -0x20. Use TMP_REGNO, ZERO_REGNO instead of 0, 1.
2158         (avr_out_sbxx_branch): Use %i instead of %m-0x20.
2159         (out_movqi_r_mr, out_movqi_mr_r): Ditto. And make static.
2160         (out_movhi_r_mr, out_movhi_mr_r): Ditto. And use avr_asm_len.
2161         (out_shift_with_cnt): Clean up code: Use avr_asm_len.
2162         (output_movsisf): Use output_reload_insisf for all CONSTANT_P sources.
2163         (avr_out_movpsi): USE avr_out_reload_inpsi for all CONSTANT_P sources.
2164         Clean up call of avr_out_store_psi.
2165         (output_reload_in_const): Don't cut symbols longer than 2 bytes.
2166         (output_reload_insisf): Filter CONST_INT_P or CONST_DOUBLE_P to
2167         try if setting pre-cleared register is advantageous.
2168         (avr_out_plus_1): Use gen_int_mode instead of GEN_INT.
2169
2170 2011-11-20  Joey Ye  <joey.ye@arm.com>
2171
2172         * expr.c (expand_expr_real_1): Correctly handle strict volatile
2173         bitfield loads smaller than mode size.
2174
2175 2011-11-20  Richard Henderson  <rth@redhat.com>
2176
2177         * config/mips/mips.c (mips_init_libfuncs): Call init_sync_libfuncs.
2178
2179 2011-11-20  Uros Bizjak  <ubizjak@gmail.com>
2180
2181         PR target/51235
2182         * config/i386/i386.c (ix86_expand_vcond): Generate TARGET_XOP
2183         patterns for supported mode only.
2184
2185         PR target/51236
2186         * config/i386/i386.c (ix86_expand_builtin)
2187         <IX86_BUILTIN_GATHERALTSIV4DI>: Use CODE_FOR_avx2_gathersiv4di.
2188
2189 2011-11-20  Uros Bizjak  <ubizjak@gmail.com>
2190
2191         * config/i386/i386.md (UNSPEC_MOVNTI): Remove.
2192         (UNSPEC_MOVNTQ): New unspec.
2193         * config/i386/mmx.md (sse_movntq): Rename from sse_movntdi.
2194         Use UNSPEC_MOVNTQ instead of UNSPEC_MOVNT.
2195         * config/i386/sse.md (sse2_movnti<mode>): Use UNSPEC_MOVNT instead of
2196         UNSPEC_MOVNTI.
2197         (STORENT_MODE): Add DI and V4DI modes.
2198
2199 2011-11-20  Nathan Sidwell  <nathan@acm.org>
2200
2201         PR gcov-profile/51113
2202         * coverage.c (build_var): Propagate visibility for public
2203         decls.  Use make_decl_one_only for PIC correctness.
2204
2205         testsuite/
2206         * gcc.misc-tests/gcov-13.c: Check gcovpart-13b coverage
2207         * gcc.misc-tests/gcov-16.c: New.
2208         * gcc.misc-tests/gcov-17.c: New.
2209         * g++.dg/gcov/gcov-8.C: New.
2210         * g++.dg/gcov/gcov-9.C: New.
2211         * g++.dg/gcov/gcov-10.C: New.
2212
2213 2011-11-19  Eric Botcazou  <ebotcazou@adacore.com>
2214
2215         PR rtl-optimization/51187
2216         * reorg.c (relax_delay_slots): Do not consider a jump useless if there
2217         is a barrier between the jump and its target label.
2218
2219 2011-11-19  Patrick Marlier  <patrick.marlier@gmail.com>
2220
2221         PR middle-end/51211
2222         * tracer.c (ignore_bb_p): Don't copy GIMPLE_TRANSACTION.
2223
2224 2011-11-19  Eric Botcazou  <ebotcazou@adacore.com>
2225
2226         * expmed.c (store_bit_field_1): Revert bogus formatting change.
2227
2228 2011-11-19  Richard Earnshaw  <rearnsha@arm.com>
2229
2230         PR target/50493
2231         * config/arm/arm.c (neon_disambiguate_copy): Correctly handle partial
2232         overlap of src and dest operands.
2233
2234 2011-11-19  Iain Sandoe  <iains@gcc.gnu.org>
2235
2236         * config/darwin.h (ASM_DEBUG_SPEC): New.
2237         * config/darwin9.h (ASM_DEBUG_SPEC): New.
2238
2239 2011-11-18  Jan Hubicka  <jh@suse.cz>
2240
2241         * config/i386/i386.c (atom_cost): Disable SSE loop until alignment
2242         issues are fixed.
2243
2244 2011-11-18  Anatoly Sokolov  <aesok@post.ru>
2245
2246         * config/cris/cris.c (cris_function_value_regno_p): Make static.
2247         (TARGET_FUNCTION_VALUE_REGNO_P): Define.
2248         * config/cris/cris.h (FUNCTION_VALUE_REGNO_P): Remove.
2249         * config/cris/cris-protos.h (cris_function_value_regno_p): Remove.
2250
2251 2011-11-18  H.J. Lu  <hongjiu.lu@intel.com>
2252
2253         PR target/33944
2254         * doc/extend.texi: Document __builtin_ia32_movnti64.
2255
2256         * config/i386/emmintrin.h (_mm_stream_si64): New.
2257
2258         * config/i386/i386-builtin-types.def: Add VOID_FTYPE_PLONGLONG_LONGLONG.
2259
2260         * config/i386/i386.c (ix86_builtins): Add IX86_BUILTIN_MOVNTI64.
2261         (bdesc_special_args): Update __builtin_ia32_movnti.  Add
2262         __builtin_ia32_movnti64.
2263         (ix86_expand_special_args_builtin): Handle
2264         VOID_FTYPE_PLONGLONG_LONGLONG.
2265
2266         * config/i386/i386.md (UNSPEC_MOVNTI): New.
2267
2268         * config/i386/sse.md (sse2_movntsi): Renamed to ...
2269         (sse2_movnti<mode>): This.
2270
2271 2011-11-18  Georg-Johann Lay  <avr@gjlay.de>
2272
2273         PR target/49868
2274         * config/avr/avr.h (base_arch_s): Add field n_segments.
2275         (ADDR_SPACE_PGM1, ADDR_SPACE_PGM2, ADDR_SPACE_PGM3,
2276         ADDR_SPACE_PGM4, ADDR_SPACE_PGM5, ADDR_SPACE_PGMX): New address spaces.
2277         (AVR_HAVE_ELPM, AVR_HAVE_ELPMX): New defines.
2278         (INIT_EXPANDERS): New define.
2279         * config/avr/avr-protos.h (avr_mem_pgmx_p): New.
2280         (avr_init_expanders): New.
2281         (avr_emit_movmemhi, avr_out_movmem): New.
2282         (avr_xload_libgcc_p): New.
2283         * config/avr/avr-c.c (avr_register_target_pragmas): Register
2284         address spaces __pgm1, __pgm2,  __pgm3,  __pgm4  __pgm5,  __pgmx.
2285         (avr_cpu_cpp_builtins): Add built-in defines __PGM1,
2286         __PGM2, __PGM3, __PGM4, __PGM5, __PGMX.
2287         * config/avr/avr-devices.c (avr_arch_types): Set field n_segments.
2288
2289         * config/avr/avr.c (AVR_SECTION_PROGMEM): Change define to cover
2290         3 bits instead of just 1.
2291         (xstring_empty, xstring_e, rampz_rtx): New static GTYed variables.
2292         (progmem_section): Change from section to array of sections.
2293         (progmem_section_prefix): New static variable.
2294         (avr_file_start): Print set for __RAMPZ__
2295         (avr_option_override): Move initialization of RTXes from here...
2296         (avr_init_expanders): ...to this new function.
2297         (avr_pgm_segment): New static function.
2298         (avr_decl_pgm_p): Handle error_mark_node.
2299         (avr_mem_pgmx_p, avr_decl_pgmx_p): New static functions.
2300         (avr_out_xload, avr_find_unused_d_reg): New static functions.
2301         (expand_prologue, expand_epilogue): Use rampz_rtx.
2302         (print_operand): Hande CONST_STRING.
2303         (avr_xload_libgcc_p): New static function.
2304         (avr_out_lpm_no_lpmx, avr_out_lpm): Handle ELPM.
2305         (avr_progmem_p): Return 2 for 24-bit flash address space.
2306         (avr_out_sbxx_branch): Clean-up code from ASn macros.
2307         (out_movqi_r_mr, out_movqi_mr_r): Ditto. And recognize RAMPZ's
2308         address and print symbolically.
2309         (avr_asm_named_section, avr_section_type_flags,
2310         avr_encode_section_info, avr_asm_select_section,
2311         avr_addr_space_address_mode, avr_addr_space_pointer_mode,
2312         avr_addr_space_legitimate_address_p, avr_addr_space_convert,
2313         avr_addr_space_legitimize_address): Handle new address spaces.
2314         (avr_output_progmem_section_asm_op): New static function.
2315         (avr_asm_init_sections): Initialize progmem_section[].
2316         (adjust_insn_length): Handle ADJUST_LEN_XLOAD, ADJUST_LEN_MOVMEM.
2317         (avr_const_address_lo16): New static function.
2318         (avr_assemble_integer): Use it to handle 3-byte integers.
2319         (avr_emit_movmemhi, avr_out_movmem): New functions.
2320
2321         * config/avr/predicates.md (nox_general_operand): Handle new
2322         address spaces.
2323         * config/avr/avr.md (unspec): Add UNSPEC_MOVMEM.
2324         (adjust_len): Add xload, movmem.
2325         (SP_ADDR): New define_constants.
2326         (isa): Add "lpm", "lpmx", "elpm", "elpmx".
2327         (enabled): Handle them.
2328         (load<mode>_libgcc): New expander.
2329         (*load.<mode>.libgcc): Rename to load_<mode>_libgcc.
2330         (xload8_A, xload<mode>_A): New insn-and-splits.
2331         (xload_8, xload_<mode>_libgcc, xload_<mode>, loadmem_elpm): New insns.
2332         (mov<mode>): Handle new address spaces.
2333         (movmemhi): Rewrite using avr_emit_movmemhi.
2334         (MOVMEM_r_d): New mode attribute.
2335         (movmem_<mode>, movmem_qi_elpm): New insns.
2336         (setmemhi, *clrmemqi, *clrmemhi, strlenhi, *strlenhi): Unquote
2337         C-code.  Use label instead of hard-coded instrunction lengths.
2338
2339 2011-11-18  Martin Jambor  <mjambor@suse.cz>
2340
2341         PR tree-optimization/50605
2342         * gimple.c (is_gimple_ip_invariant_address): Also handle MEM_REFs
2343         of IPA invariant decls.
2344
2345 2011-11-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
2346
2347         * tree-outof-ssa.c (insert_back_edge_copies):  Add call to
2348         mark_dfs_back_edges.
2349
2350 2011-11-18  Iain Sandoe  <iains@gcc.gnu.org>
2351
2352         PR target/49992
2353         * configure.ac: Remove ranlib special-casing for Darwin.
2354         * configure: Regenerate.
2355
2356 2011-11-18  Uros Bizjak  <ubizjak@gmail.com>
2357
2358         PR tree-optimization/51118
2359         * fold-const.c (fold_checksum_tree): Check for TS_TYPED structure
2360         before using TREE_TYPE accessor on expr.
2361
2362 2011-11-17  Jan Hubicka  <jh@suse.cz>
2363
2364         PR bootstrap/51134
2365         * i386.c (atom_cost): Fix 32bit memset description.
2366         (expand_set_or_movmem_via_loop_with_iter): Output proper bounds check
2367         for epilogue loops.
2368         (expand_movmem_epilogue): Handle epilogues up to size 15 w/o producing
2369         byte loop.
2370         (decide_alg): sse_loop is not useable wthen SSE2 is disabled;
2371         when not optimizing always use rep movsb or lincall; do not produce
2372         word sized loops when optimizing memset for size (to avoid need
2373         for large constants).
2374         (ix86_expand_movmem): Get into sync with ix86_expand_setmem;
2375         choose unroll factors better; always do 128bit moves when producing
2376         SSE loops; do not produce loopy epilogue when size is too small.
2377         (promote_duplicated_reg_to_size): Do not look into desired alignments
2378         when doing vector expansion.
2379         (ix86_expand_setmem): Track better when promoted value is available;
2380         choose unroll factors more sanely. Output loopy epilogue only
2381         when needed.
2382
2383 2011-11-17  Steve Ellcey  <sje@cup.hp.com>
2384
2385         PR middle-end/51144
2386         * output.h (fprint_w): Remove.
2387         * final.c (fprint_w): Remove.
2388         (output_addr_const): Change fprint_w back to fprintf.
2389
2390 2011-11-17  Andrew Pinski  <apinski@cavium.com>
2391
2392         * config/host-linux.c (TRY_EMPTY_VM_SPACE): Define for MIPS.
2393
2394 2011-11-17  Andrew MacLeod  <amacleod@redhat.com>
2395
2396         * builtins.c (expand_builtin): Remove 4th parameter representing
2397         weak/strong mode when __atomic_compare_exchange becomes a library call.
2398
2399 2011-11-17  Richard Henderson  <rth@redhat.com>
2400
2401         * config/rs6000/rs6000.c (rs6000_expand_atomic_compare_and_swap): Get
2402         new pseudo for target after convert_modes.
2403         (rs6000_expand_atomic_exchange, rs6000_expand_atomic_op): Likewise.
2404
2405 2011-11-17  Richard Henderson  <rth@redhat.com>
2406
2407         * config/rs6000/rs6000.c (rs6000_expand_atomic_compare_and_swap): Get
2408         new pseudo for target after convert_modes.
2409         (rs6000_expand_atomic_exchange, rs6000_expand_atomic_op): Likewise.
2410
2411 2011-11-17  Richard Henderson  <rth@redhat.com>
2412
2413         * builtins.c (expand_builtin_mem_thread_fence): Remove.
2414         (expand_builtin_mem_signal_fence): Remove.
2415         (expand_builtin_atomic_thread_fence): Use expand_mem_thread_fence.
2416         (expand_builtin_sync_synchronize): Likewise.
2417         (expand_builtin_atomic_signal_fence): Use expand_mem_signal_fence.
2418         * optabs.c (expand_asm_memory_barrier): Split out from
2419         expand_builtin_mem_signal_fence.
2420         (expand_mem_thread_fence): New, a combination of code from
2421         expand_builtin_mem_thread_fence and expand_builtin_sync_synchronize.
2422         (expand_mem_signal_fence): Moved and renamed from
2423         expand_builtin_mem_signal_fence.
2424         (expand_atomic_exchange): Use expand_mem_thread_fence.
2425         (expand_atomic_load, expand_atomic_store): Likewise.
2426         * expr.h, optabs.h: Update decls.
2427
2428 2011-11-17  Bin Cheng  <bin.cheng@arm.com>
2429
2430         PR rtl-optimization/50663
2431         * cprop.c (implicit_set_indexes): New global variable.
2432         (insert_set_in_table): Add additional parameter and record implicit
2433         set information.
2434         (hash_scan_set): Add additional parameter and pass it to above.
2435         (hash_scan_insn): Pass false to hash_scan_set.
2436         (compute_hash_table_work): Pass true to hash_scan_set.
2437         (compute_cprop_data): Add implicit set to AVIN of block which the
2438         implicit set is recorded for.
2439         (one_cprop_pass): Handle implicit_set_indexes array.
2440
2441 2011-11-17  Michael Matz  <matz@suse.de>
2442
2443         PR middle-end/50644
2444         PR middle-end/50741
2445         * tree-ssa-live.c (mark_all_vars_used_1): Recurse only for decls of
2446         current function.
2447         (remove_unused_locals): Ditto.
2448
2449 2011-11-16  Richard Henderson  <rth@redhat.com>
2450
2451         * config/alpha/alpha.c (alpha_split_compare_and_swap_12): Copy
2452         ALIAS_SET_MEMORY_BARRIER when creating a new memory.
2453         (alpha_split_atomic_exchange_12): Likewise.
2454         * config/rs6000/rs6000.c (rs6000_adjust_atomic_subword): Likewise.
2455
2456 2011-11-16  Joseph Myers  <joseph@codesourcery.com>
2457
2458         * config/i386/i386elf.h (PREFERRED_DEBUGGING_TYPE): Remove.
2459
2460 2011-11-16  David Edelsohn  <dje.gcc@gmail.com>
2461
2462         * config/rs6000/rs6000.c (rs6000_xcoff_section_type_flags):
2463         Default to minimum alignment if decl is NULL.
2464
2465 2011-11-16  Uros Bizjak  <ubizjak@gmail.com>
2466
2467         * config/i386/sse.md (round<mode>2_vec_pack_sfix): Optimize V2DFmode
2468         sequence for AVX.
2469         (<sse4_1>_round<ssemodesuffix>_vec_pack_sfix<avxsizesuffix>): Ditto.
2470
2471 2011-11-16  Venkataramanan Kumar  <venkataramanan.kumar@amd.com>
2472
2473         * doc/invoke.texi: Document AMD bdver1 and btver1.
2474
2475 2011-11-16  Richard Earnshaw  <rearnsha@arm.com>
2476             Bernd Schmidt <bernds@coudesourcery.com>
2477             Sebastian Huber <sebastian.huber@embedded-brains.de>
2478
2479         PR target/49641
2480         * config/arm/arm.c (store_multiple_sequence): Avoid cases where
2481         the base reg is stored iff compiling for Thumb1.
2482
2483 2011-11-16  Razya Ladelsky  <razya@il.ibm.com>
2484
2485         PR tree-optimization/49960
2486         * tree-data-ref.c (initialize_data_dependence_relation): Add
2487         initializations.
2488         Remove call to compute_self_dependence.
2489         (compute_affine_dependence): Remove the !DDR_SELF_REFERENCE condition.
2490         (compute_self_dependence): Remove old code. Add call to
2491         compute_affine_dependence.
2492         (compute_all_dependences): Remove call to compute_self_dependence.
2493         Add call to compute_affine_dependence.
2494
2495 2011-11-16  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
2496
2497         PR middle-end/50325
2498         * expmed.c (store_bit_field_1): Use extract_bit_field on big
2499         endian targets if the source cannot be exactly covered by word
2500         mode chunks.
2501
2502 2011-11-15  Joseph Myers  <joseph@codesourcery.com>
2503
2504         * config/i386/i386elf.h (ASM_OUTPUT_ASCII): Change STRING_LIMIT to
2505         ELF_STRING_LIMIT.
2506
2507 2011-11-15  Richard Henderson  <rth@redhat.com>
2508
2509         * config/alpha/alpha.c (alpha_pre_atomic_barrier): New.
2510         (alpha_post_atomic_barrier): New.
2511         (alpha_split_atomic_op): New memmodel argument; honor it.
2512         (alpha_split_compare_and_swap): Take array of operands.  Honor
2513         memmodel; always set bool output
2514         (alpha_expand_compare_and_swap_12): Similarly.
2515         (alpha_split_compare_and_swap_12): Similarly.
2516         (alpha_split_atomic_exchange): Similarly.  Rename from
2517         alpha_split_lock_test_and_set.
2518         (alpha_expand_atomic_exchange_12): Similarly.  Rename from
2519         alpha_expand_lock_test_and_set_12.
2520         (alpha_split_atomic_exchange_12): Similarly.  Rename from
2521         alpha_split_lock_test_and_set_12.
2522         * config/alpha/alpha-protos.h: Update.
2523         * config/alpha/alpha.md (UNSPECV_CMPXCHG): New.
2524         * config/alpha/constraints.md ("w"): New.
2525         * config/alpha/predicates.md (mem_noofs_operand): New.
2526         * config/alpha/sync.md (atomic_compare_and_swap<mode>): Rename from
2527         sync_compare_and_swap<mode>; add the new parameters.
2528         (atomic_exchange<mode>): Update from sync_test_and_set<mode>.
2529         (atomic_fetch_<op><mode>): Update from sync_old_<op><mode>.
2530         (atomic_<op>_fetch<mode>): Update from sync_new_<op><mode>.
2531         (atomic_<op><mode>): Update from sync_<op><mode>.
2532
2533 2011-11-16  Tom de Vries  <tom@codesourcery.com>
2534
2535         * tree-ssa-tail-merge.c (replace_block_by): Add frequency of bb2 to bb1.
2536
2537 2011-11-16  Alan Modra  <amodra@gmail.com>
2538
2539         PR rtl-optimization/51051
2540         PR bootstrap/51086
2541         * function.c (thread_prologue_and_epilogue_insns): Guard
2542         emitting return with single_succ_p test.
2543
2544 2011-11-15  Joern Rennecke  <joern.rennecke@embecosm.com>
2545
2546         * config/epiphany/epiphany.md (mov<mode>cc): Fix code to
2547         get mode from CMP_OP1 if CMP_OP0 is VOIDmode.
2548
2549 2011-11-15  Uros Bizjak  <ubizjak@gmail.com>
2550
2551         * config/i386/sse.md (vec_pack_trunc_v2df): Optimize sequence for AVX.
2552         (vec_pack_sfix_trunc_v2df): Ditto.
2553         (vec_pack_sfix_v2df): Ditto.
2554         (vec_pack_sfix_trunc_v4df): Generate fix_truncv4dfv4si2 and
2555         avx_vec_concatv8si patterns.
2556         (vec_pack_sfix_v4df): Generate avx_cvtpd2dq256 and
2557         avx_vec_concatv8si patterns.
2558
2559 2011-11-15  Torvald Riegel  <triegel@redhat.com>
2560
2561         * c-parser.c (c_parser_transaction_expression): Require parentheses
2562         when parsing transaction expressions.
2563
2564 2011-11-15  Tristan Gingold  <gingold@adacore.com>
2565
2566         * incpath.c (get_added_cpp_dirs): New function.
2567         * incpath.h (get_added_cpp_dirs): Declare.
2568         * config/vms/vms-c.c (vms_c_register_includes): New function.
2569         (vms_std_modules): New variable.
2570         * config/vms/vms.h (TARGET_EXTRA_INCLUDES): Define.
2571         (vms_c_register_includes): Declare.
2572
2573 2011-11-15  Tristan Gingold  <gingold@adacore.com>
2574
2575         * c-family/c-pragma.h (pragma_extern_prefix): Declare.
2576         * c-family/c-pragma.c (pragma_extern_prefix): Make it public.
2577         * config/vms/vms-c.c (saved_extern_prefix): New variable.
2578         (vms_pragma_extern_prefix): New function.
2579         (vms_c_register_pragma): Register vms_pragma_extern_prefix.
2580
2581 2011-11-15  Georg-Johann Lay  <avr@gjlay.de>
2582
2583         PR target/49868
2584         * config/avr/avr.h (ADDR_SPACE_PGM): New address spaces.
2585         (REGISTER_TARGET_PRAGMAS): New define.
2586         * config/avr/avr-protos.h (avr_mem_pgm_p): New.
2587         (avr_load_libgcc_p): New.
2588         (avr_register_target_pragmas): New.
2589         (asm_output_external_libcall): Remove.
2590         (avr_log_t): Add field "progmem".  Order alphabetically.
2591         * config/avr/avr-log.c (avr_log_set_avr_log): Set avr_log.progmem.
2592         * config/avr/avr-c.c (langhooks.h): New include.
2593         (avr_register_target_pragmas): New function. Register address
2594         space __pgm.
2595         (avr_cpu_cpp_builtins): Add built-in define __PGM.
2596
2597         * config/avr/avr.c: Include "c-family/c-common.h".
2598         (TARGET_LEGITIMATE_ADDRESS_P): Remove define.
2599         (TARGET_LEGITIMIZE_ADDRESS): Remove define.
2600         (TARGET_ADDR_SPACE_SUBSET_P): Define to...
2601         (avr_addr_space_subset_p): ...this new static function.
2602         (TARGET_ADDR_SPACE_CONVERT): Define to...
2603         (avr_addr_space_convert): ...this new static function.
2604         (TARGET_ADDR_SPACE_ADDRESS_MODE): Define to...
2605         (avr_addr_space_address_mode): ...this new static function.
2606         (TARGET_ADDR_SPACE_POINTER_MODE): Define to...
2607         (avr_addr_space_pointer_mode): ...this new static function.
2608         (TARGET_ADDR_SPACE_LEGITIMATE_ADDRESS_P): Define to...
2609         (avr_addr_space_legitimate_address_p): ...this new static function.
2610         (TARGET_ADDR_SPACE_LEGITIMIZE_ADDRESS): Define to...
2611         (avr_addr_space_legitimize_address): ...this new static function.
2612         (avr_mode_code_base_reg_class): Handle address spaces.
2613         (avr_regno_mode_code_ok_for_base_p): Ditto.
2614         (lpm_addr_reg_rtx, lpm_reg_rtx, all_regs_rtx): New static variables.
2615         (avr_option_override): Initialize them.
2616         (output_reload_in_const): Use all_regs_rtx. Fix signedness of loop
2617         variables.
2618         (avr_pgm_segment): New static function.
2619         (avr_decl_pgm_p, avr_mem_pgm_p): New static functions.
2620         (avr_out_lpm, avr_out_lpm_no_lpmx): New static functions.
2621         (output_movqi, output_movhi, output_movsisf, avr_out_movpsi): Call
2622         avr_out_lpm to handle loads from progmem.
2623         (avr_load_libgcc_p): New static function.
2624         (avr_progmem_p): Test if decl is in flash.
2625         (avr_pgm_pointer_const_p): New static function.
2626         (avr_nonconst_pointer_addrspace): New static function.
2627         (avr_pgm_check_var_decl): New static function.
2628         (avr_insert_attributes): Use it.  Change error message to report
2629         cause (progmem or address space) when code wants to write to flash.
2630         (avr_section_type_flags): Unset section flag SECTION_BSS for
2631         data in progmem.
2632
2633         * config/avr/predicates.md (nop_general_operand): New predicate.
2634         (nox_general_operand): New predicate.
2635         * config/avr/avr.md (LPM_REGNO): New define_constant.
2636         (load<mode>_libgcc): New expander.
2637         (*load.<mode>.libgcc): New insn.
2638         (mov<mode>): Handle loads from non-generic AS.
2639         (movmemhi): Ditto.  Propagate address space information to newly
2640         created MEM.
2641         (movqi_insn, *movhi, *movpsi, *movsi, *movsf): Change predicate #1
2642         to nox_general_operand.
2643         (ashrqi3, ashrhi3, ashrsi3): Change predicate #1 to
2644         nop_general_operand.
2645         (ashlqi3, *ashlqi3, ashlhi3, ashlsi3): Ditto.
2646         (lshrqi3, *lshrqi3, lshrhi3, lshrsi3): Ditto.
2647         (split-lpmx): New split.
2648         (*ashlhi3_const, *ashlsi3_const, *ashrhi3_const, *ashrsi3_const,
2649         *lshrhi3_const, *lshrsi3_const): Indent, unquote C.
2650
2651 2011-11-15  Maxim Kuvyrkov  <maxim@codesourcery.com>
2652
2653         * ipa-cp.c (ipa_value_from_jfunc): Make global.
2654         (ipa_cst_from_jfunc): Remove, use ipa_value_from_jfunc instead.
2655         (get_indirect_edge_target): Rename, make global.
2656         (devirtualization_time_bonus, estimate_local_effects,)
2657         (ipcp_discover_new_direct_edges): Update.
2658         * ipa-inline-analysis.c (evaluate_conditions_for_edge):
2659         Generalize to also handle types.  Rename to ...
2660         (evaluate_properties_for_edge): Use instead of
2661         evaluate_conditions_for_edge.
2662         (estimate_edge_devirt_benefit): New function.
2663         (estimate_calls_size_and_time): Use it.
2664         (estimate_node_size_and_time, estimate_ipcp_clone_size_and_time,)
2665         (inline_merge_summary): Update.
2666         (do_estimate_edge_time, do_estimate_edge_growth): Update.  Calculate
2667         parameter information at the call site and pass it on to subroutines.
2668         * tree-inline.c (estimate_num_insns): Distinguish between direct and
2669         indirect calls.
2670         (init_inline_once): Set size and time costs or indirect calls.
2671         * tree-inline.h (eni_weights): Add indirect_call_cost.
2672
2673 2011-11-15  Tom de Vries  <tom@codesourcery.com>
2674
2675         PR tree-optimization/51005
2676         * tree-ssa-tail-merge.c (delete_basic_block_same_succ): Rename to
2677         mark_basic_block_deleted.
2678         (update_worklist): Inline purge_bbs.
2679         (purge_bbs, unlink_virtual_phi, update_vuses, vop_at_entry)
2680         (delete_block_update_dominator_info): Remove.
2681         (replace_block_by): Remove update_vops parameter.  Partially evaluate
2682         for update_vops == false.
2683         (apply_clusters): Remove update_vops parameter.  Remove update_vops
2684         argument in replace_block_by call.
2685         (update_debug_stmts): Remove MAY_HAVE_DEBUG_STMTS test.
2686         (tail_merge_optimize): Remove update_vops argument to apply_clusters.
2687         Remove call to purge_bbs.  Add calls to calculate_dominance_info and
2688         free_dominance_info.  Add MAY_HAVE_DEBUG_STMTS  before calling
2689         update_debug_stmts.  Mark vop var for renaming, if necessary.
2690
2691 2011-11-15  Bernd Schmidt  <bernds@codesourcery.com>
2692
2693         PR rtl-optimization/51051
2694         * cfgrtl.c (cfg_layout_can_merge_blocks_p): Return FALSE if the
2695         move would cause fallthrough into the exit block.
2696
2697 2011-11-14  Richard Henderson  <rth@redhat.com>
2698
2699         * config/rs6000/rs6000.c (emit_load_locked): Assert the mode is
2700         handled.
2701         (emit_store_conditional): Likewise.
2702         (rs6000_pre_atomic_barrier, rs6000_post_atomic_barrier): New.
2703         (rs6000_adjust_atomic_subword): New.
2704         (rs6000_mask_atomic_subword, rs6000_finish_atomic_subword): New.
2705         (rs6000_expand_atomic_op): Rename from rs6000_emit_sync; rewrite
2706         for pre-reload expansion.
2707         (rs6000_split_compare_and_swap, rs6000_split_compare_and_swapqhi,
2708         rs6000_expand_compare_and_swapqhi): Merge into ...
2709         (rs6000_expand_atomic_compare_and_swap): ... here.  New function.
2710         rs6000_split_lock_test_and_set; expand immediately.  Handle
2711         QImode and HImode.
2712         * config/rs6000/rs6000.md (UNSPEC_LWSYNC): Move and rename
2713         from UNSPECV_LWSYNC.
2714         * config/rs6000/sync.md (fetchopsi_constr, fetchopdi_constr): Remove.
2715         (mem_thread_fence): New.
2716         (hwsync): Rename from memory_barrier.
2717         (*hwsync): Rename from *sync_internal.
2718         (lwsync, *lwsync): Mirror hwsync implementation.
2719         (isync): Don't reference memory.
2720         (loadsync): New.
2721         (atomic_load<INT>, atomic_store<INT>): New.
2722         (ATOMIC): New mode iterator.
2723         (load_locked<ATOMIC>): Rename from load_locked_<GPR>.
2724         (store_conditional<ATOMIC>): Rename from store_conditional_<GPR>.
2725         (sync_compare_and_swap<GPR>): Remove.
2726         (sync_compare_and_swaphi, sync_compare_and_swapqi): Remove.
2727         (sync_compare_and_swapqhi_internal): Remove.
2728         (sync_lock_test_and_set<GPR>): Remove.
2729         (sync_<FETCHOP><INT1>): Remove.
2730         (*sync_<FETCHOP>si_internal, *sync_<FETCHOP>di_internal): Remove.
2731         (sync_nand<INT1>, *sync_nand<GPR>_internal): Remove.
2732         (sync_old_<FETCHOP><GPR>): Remove.
2733         (*sync_old_<FETCHOP>si_internal): Remove.
2734         (*sync_old_<FETCHOP>di_internal): Remove.
2735         (sync_old_nand<INT1>): Remove.
2736         (*sync_old_nand<GPR>_internal): Remove.
2737         (sync_new_<FETCHOP><GPR>): Remove.
2738         (*sync_new_<FETCHOP>si_internal): Remove.
2739         (*sync_new_<FETCHOP>di_internal): Remove.
2740         (sync_new_nand<INT1>): Remove.
2741         (*sync_new_nand<GPR>_internal): Remove.
2742         (*atomic_andsi, *atomic_anddi): Remove.
2743         (*sync_addshort_internal, *sync_subshort_internal): Remove.
2744         (*sync_andsi_internal, *sync_boolsi_internal): Remove.
2745         (*sync_boolcshort_internal): Remove.
2746         (sync_lock_release<INT1>): Remove.
2747         (atomic_compare_and_swap<INT1>): New.
2748         (atomic_exchange<INT1>): New.
2749         (atomic_<FETCHOP><INT1>, atomic_nand<INT1>): New.
2750         (atomic_fetch_<FETCHOP><INT1>, atomic_fetch_nand<INT1>): New.
2751         (atomic_<FETCHOP>_fetch<INT1>, atomic_nand_fetch<INT1>): New.
2752
2753 2011-11-14  Uros Bizjak  <ubizjak@gmail.com>
2754
2755         * config/i386/sse.md (round<mode>2): Use register_operand for
2756         operand 1 predicate.
2757         (round<mode>2_sfix): Ditto.
2758         (round<mode>2_vec_pack_sfix): Ditto for operand 1 and operand 2.
2759
2760 2011-11-14  Nathan Sidwell  <nathan@acm.org>
2761
2762         * gcov.c (canonicalize_name): Protect use of S_ISLNK.
2763
2764 2011-11-14  Jan Hubicka  <jh@suse.cz>
2765
2766         PR target/51126
2767         * config/i386/i386.c (core cost model): Correct pasto.
2768
2769 2011-11-14  Uros Bizjak  <ubizjak@gmail.com>
2770
2771         * config/i386/sse.md (round<mode>2_sfix): New expander.
2772         (round<mode>2_vec_pack_sfix): Ditto.
2773         (<sse4_1>_round<ssemodesuffix>_sfix<avxsizesuffix>): Ditto.
2774         (<sse4_1>_round<ssemodesuffix>_vec_pack_sfix<avxsizesuffix>): Ditto.
2775         * config/i386/builtin-types.def (V4SI_FTYPE_V4SF_ROUND,
2776         V8SI_FTYPE_V8SF_ROUND, V4SI_FTYPE_V2DF_V2DF_ROUND,
2777         V8SI_FTYPE_V4DF_V4DF_ROUND): New builtin types.
2778         * config/i386/i386.c (ix86_builtins): Add
2779         IX86_BUILTIN_{FLOORPD,CEILPD,ROUNDPD_AZ}_VEC_PACK_SFIX{,256} and
2780         IX86_BUILTIN_{FLOORPS,CEILPS,ROUNDPS_AZ}_SFIX{,256} defines.
2781         (bdesc_args): Add __builtin_ia32_{floorpd,ceilpd}_vec_pack_sfix{,256},
2782         __builtin_ia32_roundpd_az_vec_pack_sfix{,256},
2783         __builtin_ia32_{floorps,ceilps}_sfix{,256}and
2784         __builtin_ia32_roundps_az_sfix{,256} descriptions.
2785         (ix86_expand_sse_round_vec_pack_sfix): New.
2786         (ix86_expand_args_builtin): Handle V4SI_FTYPE_V4SF_ROUND,
2787         V8SI_FTYPE_V8SF_ROUND, V4SI_FTYPE_V2DF_V2DF_ROUND and
2788         V8SI_FTYPE_V4DF_V4DF_ROUND types.  Check last argument of
2789         CODE_FOR_sse4_1_roundpd_vec_pack_sfix, CODE_FOR_sse4_1_roundps_sfix,
2790         CODE_FOR_avx_roundpd_vec_pack_sfix256 and CODE_FOR_avx_roundps_sfix256.
2791         (ix86_builtin_vectorized_function): Handle
2792         BUILT_IN_{I,L,LL}FLOOR{,F}, BUILT_IN_{I,L,LL}CEIL{,F} and
2793         BUILT_IN_{I,L,LL}ROUND{,F}
2794
2795 2011-11-14  Jan Hubicka  <jh@suse.cz>
2796
2797         PR middle-end/50598
2798         * cgraph.h (varpool_externally_visible_p): Declare.
2799         (varpool_add_new_variable): Declare.
2800         * tree-emultls.c (get_emutls_init_templ_addr,
2801         new_emutls_decl): Use varpool_add_new_variable.
2802         * ipa.c (varpool_externally_visible_p): Export.
2803         * varpool.c (varpool_add_new_variable): New function.
2804
2805 2011-11-14  Michael Zolotukhin  <michael.v.zolotukhin@gmail.com>
2806             Jan Hubicka  <jh@suse.cz>
2807
2808         * config/i386/i386.h (processor_costs): Add second dimension to
2809         stringop_algs array.
2810         * config/i386/i386.c (cost models): Initialize second dimension of
2811         stringop_algs arrays.
2812         (core_cost): New costs based on generic64 costs with updated stringop
2813         values.
2814         (promote_duplicated_reg): Add support for vector modes, add
2815         declaration.
2816         (promote_duplicated_reg_to_size): Likewise.
2817         (processor_target): Set core costs for core variants.
2818         (expand_set_or_movmem_via_loop_with_iter): New function.
2819         (expand_set_or_movmem_via_loop): Enable reuse of the same iters in
2820         different loops, produced by this function.
2821         (emit_strset): New function.
2822         (expand_movmem_epilogue): Add epilogue generation for bigger sizes,
2823         use SSE-moves where possible.
2824         (expand_setmem_epilogue): Likewise.
2825         (expand_movmem_prologue): Likewise for prologue.
2826         (expand_setmem_prologue): Likewise.
2827         (expand_constant_movmem_prologue): Likewise.
2828         (expand_constant_setmem_prologue): Likewise.
2829         (decide_alg): Add new argument align_unknown.  Fix algorithm of
2830         strategy selection if TARGET_INLINE_ALL_STRINGOPS is set; Skip sse_loop
2831         (decide_alignment): Update desired alignment according to chosen move
2832         mode.
2833         (ix86_expand_movmem): Change unrolled_loop strategy to use SSE-moves.
2834         (ix86_expand_setmem): Likewise.
2835         (ix86_slow_unaligned_access): Implementation of new hook
2836         slow_unaligned_access.
2837         * config/i386/i386.md (strset): Enable half-SSE moves.
2838         * config/i386/sse.md (vec_dupv4si): Add expand for vec_dupv4si.
2839         (vec_dupv2di): Add expand for vec_dupv2di.
2840
2841 2011-11-14  Dimitrios Apostolou  <jimis@gmx.net>
2842
2843         PR bootstrap/51094
2844         PR middle-end/51116
2845         * config/elfos.h (TARGET_ASM_INTERNAL_LABEL): Remove.
2846         * varasm.c (default_elf_internal_label): Remove.
2847
2848 2011-11-14  Kai Tietz  <ktietz@redhat.com>
2849
2850         * gcov.c (generate_results): Add missing semicolon and correct indent.
2851
2852 2011-11-14  Ira Rosen  <ira.rosen@linaro.org>
2853
2854         PR bootstrap/51112
2855         * tree-vect-stmts.c (vectorizable_condition): Initialize comp_vectype.
2856
2857 2011-11-14  Mingjie Xing  <mingjie.xing@gmail.com>
2858
2859         * doc/invoke.texi (Wunused-result): Change @pxref{Variable Attributes}
2860         to @pxref{Function Attributes}.
2861
2862 2011-11-13  Oleg Endo  <oleg.endo@t-online.de>
2863
2864         PR target/50694
2865         * config/sh/sh.h (IS_LITTLE_ENDIAN_OPTION, UNSUPPORTED_SH2A):
2866         New macros.
2867         (DRIVER_SELF_SPECS): Use new macros to filter out unsupported options
2868         taking the default configuration into account.
2869
2870 2011-11-13  Jonathan Wakely  <jwakely.gcc@gmail.com>
2871
2872         * doc/install.texi (Specific): Fix anchor for
2873         x86_64-*-solaris2.1[0-9]*.
2874
2875 2011-11-13  Nathan Sidwell  <nathan@acm.org>
2876
2877         * gcov.c (source_prefix, source_length): New globals.
2878         (flag_relative_only): Likewise.
2879         (print_usage, options, process_args): Update.
2880         (generate_results): Use coverage.name, check
2881         flag_relative_only. Adjust messages.
2882         (find_source): Check source_prefix.
2883         (output_lines): Use coverage.name, adjust messages.
2884         * doc/gcov.texi (Invoking Gcov): Document new options.
2885
2886 2011-11-12  Jason Merrill  <jason@redhat.com>
2887
2888         PR c++/51060
2889         * gimplify.c (gimplify_target_expr): Add a clobber to the cleanup.
2890         (gimplify_modify_expr): Don't try to simplify it.
2891
2892 2011-11-12  Dimitrios Apostolou  <jimis@gmx.net>
2893
2894         PR bootstrap/51094
2895         * config/elfos.h (STRING_ASM_OP): Define.
2896         * varasm.c (default_elf_asm_output_limited_string): Use it.
2897
2898         PR bootstrap/51094
2899         * gcc/configure.ac: Check for stpcpy declaration.
2900         * system.h: Declare it if not.
2901         * config.in, configure: Regenerate.
2902
2903 2011-11-12  Richard Henderson  <rth@redhat.com>
2904
2905         * config/rs6000/rs6000.md (fix_trunc<SFDF>si2_stfiwx): Use
2906         nonimmediate_operand for the destination.
2907         (fixuns_trunc<SFDF>si2_stfiwx): Likewise.
2908
2909         * builtins.c (expand_builtin_compare_and_swap): If target is const0,
2910         don't pass the target to expand_atomic_compare_and_swap.
2911         (expand_builtin_atomic_compare_exchange): Likewise.
2912
2913         * config/sh/linux.h (TARGET_INIT_LIBFUNCS): New.
2914         * config/sh/sh.c (sh_init_sync_libfuncs): New.
2915
2916         * config/pa/pa-linux.h (TARGET_SYNC_LIBCALL): New.
2917         * config/pa/pa.h (TARGET_SYNC_LIBCALL): New default.
2918         * config/pa/pa.c (pa_init_libfuncs): Use init_sync_libfuncs.
2919
2920 2011-11-12  Iain Sandoe  <iains@gcc.gnu.org>
2921
2922         PR target/45233
2923         * config/rs6000/rs6000.c (rs6000_legitimize_reload_address):
2924         Only expand a symbol ref. into an access when the entity is defined
2925         in the TU.
2926
2927 2011-11-12  Jan Hubicka  <jh@suse.cz>
2928
2929         PR bootstrap/50822
2930         * cgraphunit.c (output_weakrefs): Output really only weakrefs.
2931
2932 2011-11-12  Nathan Sidwell  <nathan@acm.org>
2933
2934         * gcov.c (struct name_map): New.
2935         (names, n_names, a_names): New global vars.
2936         (print_usage): Adjust usage.
2937         (generate_results): Canonicalize main file name.
2938         (release_structures): Adjust.
2939         (name_search, name_sort): New callbacks.
2940         (find_source): Look for and create a canonical name.
2941         (canonicalize_name): New.
2942         (make_gcov_file_name): Reimplement and fix mangling.
2943         (mangle_name): New.
2944         * doc/gcov.texi: Update documentation about path preservation.
2945
2946 2011-11-11  David S. Miller  <davem@davemloft.net>
2947
2948         * config/sparc/linux.h (ASM_GENERATE_INTERNAL_LABEL): Delete.
2949         * config/sparc/linux64.h (ASM_GENERATE_INTERNAL_LABEL): Delete.
2950
2951 2011-11-11  Jakub Jelinek  <jakub@redhat.com>
2952
2953         * config/i386/i386-protos.h (ix86_maybe_emit_epilogue_vzeroupper):
2954         New prototype.
2955         * config/i386/i386.c (ix86_maybe_emit_epilogue_vzeroupper): New
2956         function.
2957         (ix86_expand_epilogue): Use it.
2958         * config/i386/i386.md (return, simple_return): Call it in the
2959         expanders.
2960
2961         PR tree-optimization/51091
2962         * tree-stdarg.c (execute_optimize_stdarg): Ignore TREE_CLOBBER_P
2963         rhs also in the va_list_simple_ptr case.
2964
2965         PR tree-optimization/51058
2966         * tree-vect-slp.c (vect_remove_slp_scalar_calls): New function.
2967         (vect_schedule_slp): Call it.
2968         * tree-vect-stmts.c (vectorizable_call): If slp_node != NULL,
2969         don't replace scalar calls with setting of their lhs to zero here.
2970
2971         PR tree-optimization/51074
2972         * fold-const.c (vec_cst_ctor_to_array, fold_vec_perm): New functions.
2973         (fold_binary_loc): Handle VEC_EXTRACT_EVEN_EXPR,
2974         VEC_EXTRACT_ODD_EXPR, VEC_INTERLEAVE_HIGH_EXPR and
2975         VEC_INTERLEAVE_LOW_EXPR with VECTOR_CST or CONSTRUCTOR operands.
2976         (fold_ternary_loc): Handle VEC_PERM_EXPR with VECTOR_CST or
2977         CONSTRUCTOR operands.
2978         * tree-ssa-propagate.c (valid_gimple_rhs_p): Handle ternary
2979         expressions.
2980         * tree-vect-generic.c (lower_vec_perm): Mask sel_int elements
2981         to 0 .. 2 * elements - 1.
2982
2983 2011-11-11  Richard Henderson  <rth@redhat.com>
2984
2985         * gimple-pretty-print.c (dump_gimple_omp_atomic_load): Dump needed.
2986         (dump_gimple_omp_atomic_store): Likewise.
2987         * optabs.c (can_atomic_exchange_p): New.
2988         * optabs.h (can_atomic_exchange_p): Declare.
2989         * omp-low.c (expand_omp_atomic_load): Implement.
2990         (expand_omp_atomic_store): Likewise.
2991         (expand_omp_atomic): Update for new arguments to load/store.
2992
2993 2011-11-11  Eric Botcazou  <ebotcazou@adacore.com>
2994
2995         * cprop.c: Adjust outdated comments throughout.
2996         (hash_scan_set): Rename PAT parameter into SET.
2997         (cprop_pavloc): Rename into...
2998         (cprop_avloc): ...this.
2999         (cprop_absaltered): Rename into...
3000         (cprop_kill): ...this.
3001         (alloc_cprop_mem): Adjust for above renaming.
3002         (free_cprop_mem): Likewise.
3003         (compute_cprop_data): Likewise.
3004         (compute_local_properties): Rename TRANSP parameter into KILL and
3005         adjust throughout.  Rework comments.
3006         (try_replace_reg): Fix long line.
3007         (cprop_jump): Likewise.
3008         (constprop_register): Fix prototype and take INSN last.
3009         (cprop_insn): Adjust calls to above function.  Fix long lines.
3010         (bypass_block): Likewise.
3011         (one_cprop_pass): Likewise.
3012
3013 2011-11-11  Uros Bizjak  <ubizjak@gmail.com>
3014
3015         * config/alpha/elf.h (ELF_ASCII_ESCAPES): Rename from ESCAPES.
3016         (ELF_STRING_LIMIT): Rename from STRING_LIMIT.
3017
3018 2011-11-11  Jason Merrill  <jason@redhat.com>
3019
3020         * varasm.c (default_elf_asm_output_limited_string): #ifdef
3021         ELF_ASCII_ESCAPES.
3022         (default_elf_asm_output_ascii): Likewise.
3023
3024 2011-11-11  Uros Bizjak  <ubizjak@gmail.com>
3025
3026         PR target/50762
3027         * config/i386/constraints.md (j): New address constraint.
3028         * config/i386/predicates.md (lea_address_operand): Redefine as
3029         special predicate.
3030         * config/i386/i386.md (*lea_3_zext): Use "j" constraint for operand 1.
3031         (*lea_4_zext): Ditto.
3032
3033 2011-11-11  David S. Miller  <davem@davemloft.net>
3034
3035         Revert
3036         2011-11-05  David S. Miller  <davem@davemloft.net>
3037
3038         * config/sparc/sparc.md (UNSPEC_SHORT_LOAD): New unspec.
3039         (zero-extend_v8qi_vis, zero_extend_v4hi_vis): New expanders.
3040         (*zero_extend_v8qi_<P:mode>_insn,
3041         *zero_extend_v4hi_<P:mode>_insn): New insns.
3042         * config/sparc/sparc.c (vector_init_move_words,
3043         vector_init_prepare_elts, sparc_expand_vector_init_vis2,
3044         sparc_expand_vector_init_vis1): New functions.
3045         (vector_init_bshuffle): Rewrite to handle more cases and make use
3046         of locs[] array prepared by vector_init_prepare_elts.
3047         (vector_init_fpmerge, vector_init_faligndata): Delete.
3048         (sparc_expand_vector_init): Rewrite using new infrastructure.
3049
3050 2011-11-11  Jakub Jelinek  <jakub@redhat.com>
3051
3052         * opts-common.c (generate_canonical_option): Free opt_text
3053         it it has been allocated here and not stored anywhere.
3054
3055         * tree-vect-slp.c (vect_free_slp_tree): Also free SLP_TREE_CHILDREN
3056         vector.
3057         (vect_create_new_slp_node): Don't allocate node before checking stmt
3058         type.
3059         (vect_free_oprnd_info): Remove FREE_DEF_STMTS argument, always
3060         free def_stmts vectors and additionally free oprnd_info.
3061         (vect_build_slp_tree): Adjust callers.  Call it even if
3062         stop_recursion.  If vect_create_new_slp_node or
3063         vect_build_slp_tree fails, properly handle freeing memory.
3064         If it succeeded, clear def_stmts in oprnd_info.
3065
3066 2011-11-11  Dimitrios Apostolou  <jimis@gmx.net>
3067
3068         * defaults.h (ASM_OUTPUT_LABEL, ASM_OUTPUT_INTERNAL_LABEL): Expand on
3069         multiple lines for readability.
3070         * output.h (fprint_whex, fprint_w, fprint_ul, sprint_ul): Declare.
3071         (ASM_OUTPUT_LABELREF): Call fputs instead of asm_fprintf.
3072         * dwarf2asm.c (dw2_assemble_integer, dw2_asm_output_data,
3073         dw2_asm_data_uleb128, dw2_asm_delta_uleb128,
3074         dw2_asm_delta_sleb128): Convert fprintf calls to the new functions.
3075         * dwarf2out.c (dwarf2out_source_line): Call fprint_ul instead of
3076         fprintf.
3077         * final.c (fprint_whex, fprint_w, fprint_ul, sprint_ul): New functions
3078         serving as fast replacements for fprintf integer to string conversions.
3079         (sprint_ul_rev): Internal helper for the above.
3080         (output_addr_const) <CONST_INT>: Don't use fprintf.
3081         * varasm.c: Fix some whitespace inconsistencies.
3082         (default_elf_asm_output_limited_string): New.
3083         (default_elf_asm_output_ascii): Likewise.
3084         (default_elf_internal_label): Likewise.
3085         * config/elfos.h (ASM_GENERATE_INTERNAL_LABEL): Use sprint_ul and
3086         stpcpy instead of sprintf.
3087         (TARGET_ASM_INTERNAL_LABEL): Define as default_elf_internal_label.
3088         (ELF_ASCII_ESCAPES, ELF_STRING_LIMIT): Rename from old ESCAPES and
3089         STRING_LIMIT macros.
3090         (ASM_OUTPUT_LIMITED_STRING, ASM_OUTPUT_ASCII): Call functions that
3091         provide the same functionality.
3092         * config/i386/i386.c (print_reg): Call fprint_ul instead of fprintf.
3093
3094 2011-11-10  Andrew MacLeod  <amacleod@redhat.com>
3095
3096         * doc/extend.texi: Document __atomic_test_and_set and __atomic_clear.
3097
3098 2011-11-10  Andrew MacLeod  <amacleod@redhat.com>
3099
3100         PR middle-end/51038
3101         * builtins.c (expand_builtin_atomic_clear): New.  Expand atomic_clear.
3102         (expand_builtin_atomic_test_and_set): New.  Expand atomic test_and_set.
3103         (expand_builtin): Add cases for test_and_set and clear.
3104         * sync-builtins.def (BUILT_IN_ATOMIC_TEST_AND_SET): New.
3105         (BUILT_IN_ATOMIC_CLEAR): New.
3106
3107 2011-11-10  Roberto Agostino Vitillo  <ravitillo@lbl.gov>
3108
3109         PR debug/50983
3110         * dwarf2out.c (set_cur_line_info_table): Restore the last is_stmt
3111         value in the current line table.
3112
3113 2011-11-10  Nathan Sidwell  <nathan@acm.org>
3114
3115         * gcov.c (struct function_info): Make src an index, not a pointer.
3116         (struct source_info): Remove index and next source fields.
3117         (fn_end): New static var.
3118         (sources_index): Remove.
3119         (sources): Now a pointer to an array, not a list.
3120         (n_sources, a_sources): New.
3121         (process_file): Adjust for changes to read_graph_file. Insert
3122         functions into source lists and check line numbers here.
3123         (generate_results): Only allocate lines for sources with
3124         contents.  Adjust for source array.
3125         (release_structures): Likewise.
3126         (find_source): Return source index, adjust for source array.
3127         (read_graph_file): Return function list.  Don't insert into source
3128         lists here.
3129         (read_count_file): Take list of functions.
3130         (solve_flow_graph): Reverse the arc lists here.
3131         (add_line_counts): Adjust for source array.
3132
3133 2011-11-10  Jakub Jelinek  <jakub@redhat.com>
3134
3135         PR middle-end/51077
3136         * tree-object-size.c (addr_object_size): Check TREE_CODE of
3137         MEM_REF's operand rather than code of the MEM_REF itself.
3138
3139 2011-11-10  Andrew MacLeod  <amacleod@redhat.com>
3140
3141         PR rtl-optimization/51040
3142         * optabs.c (expand_atomic_fetch_op): Patchup code for NAND should
3143         be AND followed by NOT.
3144         * builtins.c (expand_builtin_atomic_fetch_op): Patchup code for NAND
3145         should be AND followed by NOT.
3146
3147 2011-11-10  Jakub Jelinek  <jakub@redhat.com>
3148
3149         * vec.h (VEC_BASE): If base is at offset 0 in the structure,
3150         use &(P)->base even if P is NULL.
3151
3152         PR rtl-optimization/51023
3153         * combine.c (simplify_comparison) <case SIGN_EXTEND>: Don't use
3154         val_signbit_known_clear_p for signed comparison narrowing
3155         optimization.  Don't check for non-VOIDmode, use
3156         HWI_COMPUTABLE_MODE_P macro.
3157         <case ZERO_EXTEND>: Don't check for non-VOIDmode.
3158         Optimize even when const_op is equal to GET_MODE_MASK (mode),
3159         don't optimize if const_op is negative.
3160
3161 2011-11-10  Richard Guenther  <rguenther@suse.de>
3162
3163         PR tree-optimization/51042
3164         * tree-ssa-pre.c (phi_translate_1): Avoid recursing on
3165         self-referential expressions.  Refactor code to avoid duplication.
3166
3167 2011-11-10  Richard Guenther  <rguenther@suse.de>
3168
3169         PR tree-optimization/51070
3170         * tree-loop-distribution.c (generate_builtin): Do not replace
3171         the loop with a builtin if the partition contains statements which
3172         results are used outside of the loop.
3173         (pass_loop_distribution): Verify and collect.
3174
3175 2011-11-10  Richard Guenther  <rguenther@suse.de>
3176
3177         PR tree-optimization/51030
3178         * tree-ssa-phiopt.c (jump_function_from_stmt): New function.
3179         (value_replacement): Use it to handle trivial non-empty
3180         intermediate blocks.
3181
3182 2011-11-10  Richard Guenther  <rguenther@suse.de>
3183
3184         PR middle-end/51071
3185         * gimple.c (gimple_has_side_effects): Remove checking code
3186         that doesn't belong here.
3187
3188 2011-11-10  Ira Rosen  <ira.rosen@linaro.org>
3189
3190         PR tree-optimization/51058
3191         * tree-vect-slp.c (vect_get_constant_vectors): Handle CALL_EXPR.
3192
3193 2011-11-10  Jakub Jelinek  <jakub@redhat.com>
3194
3195         PR tree-optimization/51000
3196         * tree-vect-patterns.c (vect_recog_bool_pattern): If adding
3197         a pattern stmt for a bool store, adjust DR_STMT too.
3198         Don't handle bool conversions to single bit precision lhs.
3199         * tree-vect-stmts.c (vect_remove_stores): If next is a pattern
3200         stmt, remove its related stmt and free its stmt_vinfo.
3201         (free_stmt_vec_info): Free also pattern stmt's vinfo and
3202         pattern def stmt's vinfo.
3203         * tree-vect-loop.c (destroy_loop_vec_info): Don't try to
3204         free pattern stmt's vinfo here.
3205         (vect_transform_loop): When calling vect_remove_stores,
3206         do gsi_next first and don't call gsi_remove.  If not strided
3207         store, free stmt vinfo for gsi_stmt (si) rather than stmt.
3208
3209 2011-11-09  Jakub Jelinek  <jakub@redhat.com>
3210
3211         PR target/50911
3212         * config/i386/i386.c (expand_vec_perm_interleave2): If d->vmode is
3213         V4SImode, !TARGET_SSE2 and punpck[lh]* is needed, change dremap.vmode
3214         to V4SFmode.
3215
3216         * function.h (requires_stack_frame_p): New prototype.
3217         * function.c (requires_stack_frame_p): No longer static.
3218         * config/i386/i386.c (ix86_finalize_stack_realign_flags): If
3219         stack_realign_fp was just a conservative guess for a function
3220         which doesn't use sp/fp/argp at all, clear frame_pointer_needed
3221         and stack realignment.
3222
3223 2011-11-09  Paolo Carlini  <paolo.carlini@oracle.com>
3224
3225         PR preprocessor/51061
3226         * incpath.c (merge_include_chains): Make sure to not pass null
3227         pointers to free_path.
3228
3229 2011-11-09  Paolo Carlini  <paolo.carlini@oracle.com>
3230
3231         * doc/invoke.texi ([Option Summary, C++ Language Options]):
3232         Add -Wzero-as-null-pointer-constant.
3233
3234 2011-11-07  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
3235
3236         * config/arm/arm-cores.def: Add -mcpu=cortex-a7.
3237         * config/arm/arm-tables.opt: Regenerate.
3238         * config/arm/arm-tune.md: Likewise.
3239         * config/arm/bpabi.h (BE8_LINK_SPEC): Add Cortex A-7.
3240         * doc/invoke.texi: Document -mcpu=cortex-a7.
3241
3242 2011-11-09  Richard Guenther  <rguenther@suse.de>
3243
3244         Revert
3245         2011-11-09  Richard Guenther  <rguenther@suse.de>
3246
3247         * tree-cfg.c (verify_gimple_call): Verify that
3248         gimple_call_cannot_inline_p is returning a conservative
3249         correct result according to gimple_check_call_matching_types.
3250
3251 2011-11-09  Richard Guenther  <rguenther@suse.de>
3252
3253         PR tree-optimization/51039
3254         * tree-cfg.c (verify_gimple_call): Verify that
3255         gimple_call_cannot_inline_p is returning a conservative
3256         correct result according to gimple_check_call_matching_types.
3257         * ipa-inline-analysis.c (estimate_function_body_sizes): Remove
3258         code dealing with un-inlinablility.
3259         * gimple-streamer-in.c (input_gimple_stmt): Update the
3260         non-inlinable flag.
3261
3262 2011-11-09  Richard Guenther  <rguenther@suse.de>
3263
3264         PR tree-optimization/51039
3265         * tree-inline.c (setup_one_parameter): Always perform a
3266         valid gimple type change.
3267         (declare_return_variable): Likewise.
3268
3269 2011-11-09  Jakub Jelinek  <jakub@redhat.com>
3270
3271         * config/rs6000/vector.md (vcondv4sfv4si, vcondv4siv4sf,
3272         vconduv4sfv4si): New patterns.
3273         * config/rs6000/rs6000.c (rs6000_emit_vector_cond_expr): Handle
3274         different dest_mode from comparison mode.
3275
3276 2011-11-09  Richard Guenther  <rguenther@suse.de>
3277
3278         * gimple-fold.c (canonicalize_constructor_val): Mark
3279         address-taken variables addressable.
3280
3281 2011-11-09  Ira Rosen  <ira.rosen@linaro.org>
3282
3283         PR tree-optimization/51015
3284         * tree-vect-loop.c (vect_determine_vectorization_factor): Expect
3285         vectype to be set for pattern def stmts.
3286
3287 2011-11-09  Alan Modra  <amodra@gmail.com>
3288
3289         * function.c (bb_active_p): Delete.
3290         (dup_block_and_redirect, active_insn_between): New functions.
3291         (convert_jumps_to_returns, emit_return_for_exit): New functions,
3292         split out from..
3293         (thread_prologue_and_epilogue_insns): ..here.  Delete
3294         shadowing variables.  Don't do prologue register clobber tests
3295         when shrink wrapping already failed.  Delete all last_bb_active
3296         code.  Instead compute tail block candidates for duplicating
3297         exit path.  Remove these from antic set.  Duplicate tails when
3298         reached from both blocks needing a prologue/epilogue and
3299         blocks not needing such.
3300         * ifcvt.c (dead_or_predicable): Test both flag_shrink_wrap and
3301         HAVE_simple_return.
3302         * bb-reorder.c (get_uncond_jump_length): Make global.
3303         * bb-reorder.h (get_uncond_jump_length): Declare.
3304         * cfgrtl.c (rtl_create_basic_block): Comment typo fix.
3305         (rtl_split_edge): Likewise.  Warning fix.
3306         (rtl_duplicate_bb): New function.
3307         (rtl_cfg_hooks): Enable can_duplicate_block_p and duplicate_block.
3308         * Makefile.in (function.o): Update dependencies.
3309
3310 2011-11-08  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
3311             Georg-Johann Lay  <avr@gjlay.de>
3312
3313         * doc/tm.texi.in (MODE_CODE_BASE_REG_CLASS): Add address space
3314         argument.
3315         (REGNO_MODE_CODE_OK_FOR_BASE_P): Likewise.
3316         * doc/tm.texi: Regenerate.
3317
3318         * config/cris/cris.h (MODE_CODE_BASE_REG_CLASS): Add address
3319         space argument.
3320         (REGNO_MODE_CODE_OK_FOR_BASE_P): Likewise.
3321         * config/bfin/bfin.h (MODE_CODE_BASE_REG_CLASS): Likewise.
3322         (REGNO_MODE_CODE_OK_FOR_BASE_P): Likewise.
3323         * config/avr/avr.h (MODE_CODE_BASE_REG_CLASS): Add address space
3324         argument.
3325         (REGNO_MODE_CODE_OK_FOR_BASE_P): Ditto.
3326         * config/avr/avr-protos.h (avr_mode_code_base_reg_class): Ditto.
3327         (avr_regno_mode_code_ok_for_base_p): Ditto.
3328         * config/avr/avr.c (avr_mode_code_base_reg_class): Ditto.
3329         (avr_regno_mode_code_ok_for_base_p): Ditto.
3330         (avr_reg_ok_for_addr_p): Pass AS down to
3331         avr_regno_mode_code_ok_for_base_p.
3332
3333         * addresses.h (base_reg_class): Add address space argument.
3334         Pass to MODE_CODE_BASE_REG_CLASS.
3335         (ok_for_base_p_1): Add address space argument.  Pass to
3336         REGNO_MODE_CODE_OK_FOR_BASE_P.
3337         (regno_ok_for_base_p): Add address space argument.  Pass to
3338         ok_for_base_p_1.
3339
3340         * regrename.c (scan_rtx_address): Add address space argument.
3341         Pass address space to regno_ok_for_base_p and base_reg_class.
3342         Update recursive calls.
3343         (scan_rtx): Pass address space to scan_rtx_address.
3344         (build_def_use): Likewise.
3345         * regcprop.c (replace_oldest_value_addr): Add address space
3346         argument.  Pass to regno_ok_for_base_p and base_reg_class.
3347         Update recursive calls.
3348         (replace_oldest_value_mem): Pass address space to
3349         replace_oldest_value_addr.
3350         (copyprop_hardreg_forward_1): Likewise.
3351
3352         * reload.c (find_reloads_address_1): Add address space argument.
3353         Pass address space to base_reg_class and regno_ok_for_base_p.
3354         Update recursive calls.
3355         (find_reloads_address): Pass address space to base_reg_class,
3356         regno_ok_for_base_p, and find_reloads_address_1.
3357         (find_reloads): Pass address space to base_reg_class.
3358         (find_reloads_subreg_address): Likewise.
3359
3360         * ira-costs.c (record_reg_classes): Update calls to base_reg_class.
3361         (ok_for_base_p_nonstrict): Add address space argument.  Pass to
3362         ok_for_base_p_1.
3363         (record_address_regs): Add address space argument.  Pass to
3364         base_reg_class and ok_for_base_p_nonstrict.  Update recursive calls.
3365         (record_operand_costs): Pass address space to record_address_regs.
3366         (scan_one_insn): Likewise.
3367
3368         * caller-save.c (init_caller_save): Update call to base_reg_class.
3369         * ira-conflicts.c (ira_build_conflicts): Likewise.
3370         * reload1.c (maybe_fix_stack_asms): Likewise.
3371
3372 2011-11-08  Michael Matz  <matz@suse.de>
3373
3374         * gengtype.c (write_field_root): Avoid out-of-scope access of newv.
3375
3376         * tree-stdarg.c (execute_optimize_stdarg): Accept clobbers.
3377
3378         * tree.h (TREE_CLOBBER_P): New macro.
3379         * gimple.h (gimple_clobber_p): New inline function.
3380         * gimplify.c (gimplify_bind_expr): Add clobbers for all variables
3381         that go out of scope and live in memory.
3382         * tree-ssa-operands.c (get_expr_operands): Transfer volatility also
3383         for constructors.
3384         * cfgexpand.c (decl_to_stack_part): New static variable.
3385         (add_stack_var): Allocate it, and remember mapping.
3386         (fini_vars_expansion): Deallocate it.
3387         (stack_var_conflict_p): Add early outs.
3388         (visit_op, visit_conflict, add_scope_conflicts_1,
3389         add_scope_conflicts): New static functions.
3390         (expand_used_vars_for_block): Don't call add_stack_var_conflict, tidy.
3391         (expand_used_vars): Add scope conflicts.
3392         (expand_gimple_stmt_1): Expand clobbers to nothing.
3393         (expand_debug_expr): Ditto.
3394
3395         * tree-pretty-print.c (dump_generic_node): Dump clobbers nicely.
3396         * tree-ssa-live.c (remove_unused_locals): Remove clobbers that
3397         refer to otherwise unused locals.
3398         * tree-sra.c (build_accesses_from_assign): Ignore clobbers.
3399         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Clobbers of
3400         SSA names aren't necessary.
3401         (propagate_necessity): Accept and ignore constructors on the rhs, tidy.
3402         * gimple.c (walk_gimple_op): Accept constructors like mem_rhs.
3403         * tree-ssa-structalias.c (find_func_aliases): Clobbers don't store
3404         any known value.
3405         * tree-ssa-sccvn.c (vn_reference_lookup_3): Ditto, in particular they
3406         don't zero-initialize something.
3407         * tree-ssa-phiopt.c (cond_if_else_store_replacement_1): Ignore
3408         clobber RHS, we don't want PHI nodes with those.
3409
3410 2011-11-08  Jakub Jelinek  <jakub@redhat.com>
3411
3412         * config/i386/i386.c (ix86_preferred_simd_mode): Even for TARGET_AVX
3413         if not TARGET_PREFER_AVX128 return 32-byte integer vectors.
3414
3415 2011-11-08  Richard Guenther  <rguenther@suse.de>
3416
3417         PR tree-optimization/51012
3418         * ipa-prop.c (update_indirect_edges_after_inlining): Fixup
3419         non-inlinable state.
3420         * cgraph.c (cgraph_make_edge_direct): Likewise.
3421
3422 2011-11-08  Eric Botcazou  <ebotcazou@adacore.com>
3423
3424         PR rtl-optimization/47698
3425         * ifcvt.c (noce_operand_ok): Move around comment.
3426
3427 2011-11-08  Richard Guenther  <rguenther@suse.de>
3428
3429         PR lto/50999
3430         * lto-opts.c (append_to_collect_gcc_options): Split out from...
3431         (lto_write_options): ... here.  Prepend frontend specific flags.
3432
3433 2011-11-08  Jakub Jelinek  <jakub@redhat.com>
3434
3435         * config/i386/sse.md (*avx_vperm2f128<mode>3_nozero): Emit mask
3436         0x12 and 0x20 as vinsert[fi]128 instead of vperm2[fi]128.
3437
3438         * tree-vect-stmts.c (vectorizable_call): Add SLP_NODE argument.
3439         Handle vectorization of SLP calls.
3440         (vect_analyze_stmt): Adjust caller, add call to it for SLP too.
3441         (vect_transform_stmt): Adjust vectorizable_call caller, remove
3442         assertion.
3443         * tree-vect-slp.c (vect_get_and_check_slp_defs): For calls start