OSDN Git Service

PR target/51681
[pf3gnuchains/gcc-fork.git] / gcc / ChangeLog
1 2012-01-05  Uros Bizjak  <ubizjak@gmail.com>
2
3         PR target/51681
4         * config/ia64/ia64.c (expand_vec_perm_shrp): Use correct operands
5         for shrp pattern.  Correctly handle and fixup shift variable.
6         Return false when shift > nelt for BYTES_BIG_ENDIAN target.
7
8 2012-01-05  Jakub Jelinek  <jakub@redhat.com>
9
10         PR debug/51762
11         * calls.c (emit_call_1): For noreturn calls force a REG_ARGS_SIZE
12         note when !ACCUMULATE_OUTGOING_ARGS.
13
14 2012-01-05  Eric Botcazou  <ebotcazou@adacore.com>
15
16         * tree-vrp.c (extract_range_from_binary_expr_1): Remove duplicated
17         condition.
18         (extract_range_from_unary_expr_1): Avoid useless computations.
19
20 2012-01-05  Jakub Jelinek  <jakub@redhat.com>
21
22         PR rtl-optimization/51767
23         * cfgrtl.c (force_nonfallthru_and_redirect): Force addition
24         of jump_block and add an extra edge for degenerated asm gotos.
25
26         PR middle-end/51768
27         * stmt.c (check_unique_operand_names): Don't ICE during error
28         reporting if i is from labels chain.
29
30         PR middle-end/44777
31         * profile.c (branch_prob): Split bbs that have exit edge
32         and need a fake entry edge too.
33
34 2012-01-05  Jan Hubicka  <jh@suse.cz>
35
36         PR middle-end/49710
37         * cfgloopmanip.c (remove_path): Walk loop hiearchy upwards when
38         unlooping loops.
39
40 2012-01-05  Richard Guenther  <rguenther@suse.de>
41
42         PR lto/50490
43         * tree-streamer-out.c (write_ts_optimization): New function.
44         (streamer_write_tree_body): Call it.
45         * tree-streamer-in.c (lto_input_ts_optimization): New function.
46         (streamer_read_tree_body): Call it.
47         * lto-streamer-out.c (lto_is_streamable): Handle OPTIMIZATION_NODE.
48
49 2012-01-05  Jakub Jelinek  <jakub@redhat.com>
50
51         PR middle-end/51761
52         * gimple.h (struct gimplify_ctx): Add in_cleanup_point_expr field.
53         * gimplify.c (gimplify_cleanup_point_expr): Save and set
54         in_cleanup_point_expr before gimplify_stmt call and restore it
55         afterwards.
56         (gimplify_target_expr): Don't add {CLOBBER} cleanup if
57         in_cleanup_point_expr is false.
58
59 2012-01-05  Richard Guenther  <rguenther@suse.de>
60
61         PR middle-end/51764
62         * common.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move
63         to c.opt.
64         * toplev.c (process_options): Reject combining mudflap and LTO.
65         * tree-nomudflap.c (nogo): Use sorry instead of internal_error.
66
67 2012-01-05  Richard Guenther  <rguenther@suse.de>
68
69         PR tree-optimization/51760
70         * tree-ssa-ccp.c (likely_value): Drop UNDEFINED to CONSTANT,
71         not VARYING.
72         (bit_value_unop): Handle UNDEFINED operands.
73         (bit_value_binop): Likewise.
74
75 2012-01-05  Georg-Johann Lay  <avr@gjlay.de>
76
77         * config/avr/avr.c (avr_replace_prefix): Remove.
78         (avr_asm_named_section): Use ACONCAT instead of avr_replace_prefix.
79         (avr_asm_function_rodata_section): Ditto.
80         (avr_asm_select_section): Ditto.
81
82 2012-01-05  Marcus Shawcroft  <marcus.shawcroft@arm.com>
83
84         * reload.c (find_reloads): Adjust LABEL_NUSES on REG_LABEL_OPERAND
85         insertion.
86
87 2012-01-05  Jakub Jelinek  <jakub@redhat.com>
88
89         PR bootstrap/51648
90         * tree-cfg.c (need_fake_edge_p): Return true also for noreturn
91         calls that have any non-fake successor edges.
92
93         PR debug/51746
94         * var-tracking.c (add_stores): For COND_EXEC allow oval to be NULL.
95
96 2012-01-04  Eric Botcazou  <ebotcazou@adacore.com>
97
98         PR tree-optimization/51624
99         * tree-sra.c (build_ref_for_model): When replicating a chain of
100         COMPONENT_REFs, stop as soon as the offset would become negative.
101
102 2012-01-04  Jakub Jelinek  <jakub@redhat.com>
103
104         PR debug/51695
105         * dwarf2out.c (output_loc_list): For now drop >= 64KB expressions
106         in .debug_loc on the floor.
107
108 2012-01-04  Andrew Pinski  <apinski@cavium.com>
109
110         * doc/invoke.texi (-march=@var{arch}): Add octeon+ and octeon2.
111
112 2012-01-04  Andrew Pinski  <apinski@cavium.com>
113             Adam Nemet  <anemet@caviumnetworks.com>
114
115         * config/mips/mips.md (size): Add SI and DI.
116         (SIZE): New mode attribute.
117         (U): New code attribute.
118         * config/mips/mips-dsp.md (mips_lbux): Use gen_mips_lbux_extsi.
119         (mips_lbux_<mode>): Delete.
120         (mips_l<SHORT:size><u>x_ext<GPR:mode>_<P:mode>): New pattern.
121         (mips_lhx): Use gen_mips_lhx_extsi.
122         (mips_lhx_<mode>): Delete.
123         (mips_lwx): Delete.
124         (mips_l<size>x): New expand.
125         (mips_lwx_<mode>): Delete.
126         (mips_l<GPR:size>x_<P:mode>): New pattern.
127         (*mips_lw<u>x_<P:mode>_ext): Likewise.
128         * config/mips/mips-ftypes.def: Add DI f(POINTER, SI) function type.
129         * config/mips/mips.c (mips_lx_address_p): New function.
130         (mips_rtx_costs <case MEM>): Call mips_lx_address_p.
131         (dsp64): New availability predicate.
132         (mips_builtins): Add an entry for __builtin_mips_ldx.
133         * config/mips/mips.h (ISA_HAS_LBX): New define.
134         (ISA_HAS_LBUX): Likewise.
135         (ISA_HAS_LHX): Likewise.
136         (ISA_HAS_LHUX): Likewise.
137         (ISA_HAS_LWX): Likewise.
138         (ISA_HAS_LWUX): Likewise.
139         (ISA_HAS_LDX): Likewise.
140         * doc/extend.texi (__builtin_mips_ldx): Document.
141
142 2012-01-04  Tristan Gingold  <gingold@adacore.com>
143
144         * config/vms/xm-vms.h (HOST_LONG_FORMAT, HOST_PTR_PRINTF): Define
145         when long pointers are used.
146         * config.build (*-*-*vms*): Handle all OpenVMS targets.
147         (alpha64-dec-*vms*, alpha*-dec-*vms*)
148         (ia64-hp-*vms*): Remove.
149         * config/vms/xm-vms64.h: Delete.
150
151 2012-01-04  Aldy Hernandez  <aldyh@redhat.com>
152
153         PR middle-end/51472
154         * trans-mem.c (expand_assign_tm): Handle TM_MEMMOVE loads correctly.
155
156 2012-01-04  Aldy Hernandez  <aldyh@redhat.com>
157
158         * opts.c (finish_options): Remove duplicate sorry.
159
160 2012-01-04  Aldy Hernandez  <aldyh@redhat.com>
161
162         PR middle-end/51696
163         * trans-mem.c (diagnose_tm_1): Display indirect calls with no name
164         correctly.
165
166 2012-01-04  Richard Guenther  <rguenther@suse.de>
167
168         PR middle-end/51750
169         * tree.c (size_low_cst): New function.
170         * tree.h (size_low_cst): Declare.
171         * fold-const.c (fold_comparison): Use it to extract the low
172         part of the POINTER_PLUS_EXPR offset.
173
174 2012-01-04  Georg-Johann Lay  <avr@gjlay.de>
175
176         Fix clearing ZERO_REG
177         * config/avr/avr.md (cc): Add alternative "ldi".
178         (movqi_insn): Use it in cc attribute.
179         * config/avr/avr.c (notice_update_cc): Handle CC_LDI.
180         (output_reload_in_const): Use CLR to move 0 to ZERO_REG.
181         (output_reload_insisf): Use ZERO_REG to pre-clear register.
182
183 2012-01-04  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
184
185         * configure: Regenerate.
186
187 2012-01-04  Richard Guenther  <rguenther@suse.de>
188
189         PR tree-optimization/49651
190         * tree-ssa-structalias.c (type_can_have_subvars): New function.
191         (var_can_have_subvars): Use it.
192         (get_constraint_for_1): Only consider subfields if there can be any.
193
194 2012-01-03  Jakub Jelinek  <jakub@redhat.com>
195
196         PR bootstrap/51725
197         * cselib.c (new_elt_loc_list): When moving locs from one cselib_val
198         to its new canonical_cselib_val and the cselib_val was in
199         first_containing_mem chain, but the canonical_cselib_val was not,
200         add the latter into the chain.
201         (cselib_invalidate_mem): Compare canonical_cselib_val of
202         addr_list chain elt with v.
203
204         PR pch/51722
205         * dwarf2out.c (dwarf2out_start_source_file, dwarf2out_define,
206         dwarf2out_undef): Allocate e.info using ggc_strdup instead
207         of xstrdup.
208         (output_macinfo_op): Don't ggc_strdup fd->filename.
209         (optimize_macinfo_range): Allocate grp_name using XALLOCAVEC,
210         then ggc_strdup it.  Don't free inc->info or cur->info.
211         (output_macinfo): Don't free ref->info or file->info.
212
213 2012-01-03  Ira Rosen  <irar@il.ibm.com>
214
215         PR tree-optimization/51269
216         * tree-vect-loop-manip.c (set_prologue_iterations): Make
217         first_niters a pointer.
218         (slpeel_tree_peel_loop_to_edge): Likewise.
219         (vect_do_peeling_for_loop_bound): Update call to
220         slpeel_tree_peel_loop_to_edge.
221         (vect_gen_niters_for_prolog_loop): Don't compute wide_prolog_niters
222         here.  Remove it from the parameters list.
223         (vect_do_peeling_for_alignment): Update calls and compute
224         wide_prolog_niters.
225
226 2012-01-03  Richard Guenther  <rguenther@suse.de>
227
228         PR tree-optimization/51070
229         * tree-loop-distribution.c (stmt_has_scalar_dependences_outside_loop):
230         Properly handle calls.
231
232 2012-01-03  Richard Guenther  <rguenther@suse.de>
233
234         PR tree-optimization/51692
235         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Do not remove
236         the LHS of allocation stmts.
237
238 2012-01-03  Olivier Hainque  <hainque@adacore.com>
239
240         * system.h: Prior to #define, #undef fopen and freopen unconditionally.
241
242 2012-01-03  Olivier Hainque  <hainque@adacore.com>
243
244         * collect2.c (main): In AIX specific computations for vector
245         insertions, use CONST_CAST2 to cast from char ** to const char **.
246
247 2012-01-03  Richard Guenther  <rguenther@suse.de>
248
249         PR debug/51650
250         * dwarf2out.c (dwarf2out_finish): Always create a DIE for
251         the context of a limbo DIE when it does not already exist.
252
253 2012-01-03  Jakub Jelinek  <jakub@redhat.com>
254
255         PR tree-optimization/51719
256         * value-prof.c (gimple_ic): When indirect call isn't noreturn,
257         but direct call is, clear direct call's lhs and don't add fallthrough
258         edge from dcall_bb to join_bb and PHIs.
259
260 2012-01-03  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
261
262         * config/s390/s390.md ("*cmp<mode>_ccs"): Fix comment mentioning
263         the instructions emitted by the pattern.
264         ("*TDC_insn_<mode>"): Add comment.
265
266 2012-01-03  Richard Guenther  <rguenther@suse.de>
267
268         PR middle-end/51730
269         * fold-const.c (fold_comparison): Properly canonicalize
270         tree offset and HOST_WIDE_INT bit position.
271
272 2012-01-02  Uros Bizjak  <ubizjak@gmail.com>
273
274         * config/ia64/ia64.c (expand_vec_perm_broadcast): Use correct
275         operands for extzv pattern.
276
277 2012-01-02  Jakub Jelinek  <jakub@redhat.com>
278
279         PR bootstrap/51725
280         * cselib.c (add_mem_for_addr): Call canonical_cselib_val
281         on mem_elt first.
282
283 2012-01-02  Sandra Loosemore  <sandra@codesourcery.com>
284
285         * doc/invoke.texi (-flto and related options): Copy-edit.
286
287 2012-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
288
289         * config/mips/mips.md (loadgp_newabi_<mode>): Add missing earlyclobber.
290
291 2012-01-02  Jakub Jelinek  <jakub@redhat.com>
292
293         * config/i386/sse.md (*avx2_gatherdi<mode>_3, *avx2_gatherdi<mode>_4):
294         New patterns.
295
296 2012-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
297
298         * expr.h (move_by_pieces_ninsns): Declare.
299         * expr.c (move_by_pieces_ninsns): Make external.
300         * config/mips/mips-protos.h (mips_move_by_pieces_p): Declare.
301         (mips_store_by_pieces_p): Likewise.
302         * config/mips/mips.h (MOVE_BY_PIECES_P): Call mips_move_by_pieces_p.
303         (STORE_BY_PIECES_P): Likewise mips_store_by_pieces_p.
304         * config/mips/mips.c (mips_move_by_pieces_p): New function.
305         (mips_store_by_pieces_p): Likewise.
306
307 2012-01-02  Jakub Jelinek  <jakub@redhat.com>
308
309         * passes.c (register_one_dump_file): Free full_name.
310
311         * reload1.c (reload): Don't allocate reg_max_ref_width here.
312         (calculate_elim_costs_all_insns): Free offsets_at and
313         offsets_known_at at the end and clear the pointers.
314
315 2012-01-02  Georg-Johann Lay  <avr@gjlay.de>
316
317         * config/avr/avr.opt (-mbranch-cost): Fix double definition of
318         this option introduced in r180739.
319
320 2012-01-02  Georg-Johann Lay  <avr@gjlay.de>
321
322         PR target/51345
323         * config.gcc (tm_file target=avr]): Add avr/avr-multilib.h
324         (tmake_file target=avr): Add avr/t-multilib.
325
326         * config/avr/avr-c.c (avr_cpu_cpp_builtins): Use AVR_HAVE_8BIT_SP
327         to built-in define __AVR_HAVE_8BIT_SP__, __AVR_HAVE_16BIT_SP__.
328         * config/avr/genmultilib.awk: New file.
329         * config/avr/t-multilib: New auto-generated file.
330         * config/avr/multilib.h: New auto-generated file.
331         * config/avr/t-avr (AVR_MCUS): New variable.
332         (genopt.sh): Use it.
333         (s-mlib): Depend on t-multilib.
334         (t-multilib, multilib.h): New dependencies.
335         (s-avr-mlib): New rule to build t-multilib, multilib.h from AVR_MCUS.
336         (MULTILIB_OPTIONS): Remove.
337         (MULTILIB_MATCHES): Remove.
338         (MULTILIB_DIRNAMES): Remove.
339         (MULTILIB_EXCEPTIONS): Remove:
340         * config/avr/genopt.sh: Don't use hard coded file name;
341         pass AVR_MCUS from t-avr instead.
342
343 2012-01-02  Georg-Johann Lay  <avr@gjlay.de>
344
345         * config/avr/avr.c (avr_out_ashrpsi3): Fix "case 31" to "case 23".
346
347 2012-01-02  Georg-Johann Lay  <avr@gjlay.de>
348
349         Implement light-weight DImode support.
350         * config/avr/avr-dimode.md: New file.
351         * config/avr/avr.md: Include it.
352         (adjust_len): Add plus64, compare64.
353         (HIDI): Remove code iterator.
354         (code_stdname): New code attribute.
355         (rotx, rotsmode): Remove DI.
356         (rotl<mode>3, *rotw<mode>, *rotb<mode>): Use HISI instead of HIDI
357         as code iterator.
358         * config/avr/avr-protos.h (avr_have_dimode): New.
359         (avr_out_plus64, avr_out_compare64): New.
360         * config/avr/avr.c (avr_out_compare): Handle DImode.
361         (avr_have_dimode): New variable definition and initialization.
362         (avr_out_compare64, avr_out_plus64): New functions.
363         (avr_out_plus_1): Use simplify_unary_operation to negate xval.
364         (adjust_insn_length): Handle ADJUST_LEN_COMPARE64, ADJUST_LEN_PLUS64.
365         (avr_compare_pattern): Skip DImode comparisons.
366
367 2012-01-02  Revital Eres  <revital.eres@linaro.org>
368
369         * ddg.c (def_has_ccmode_p): New function.
370         (add_cross_iteration_register_deps,
371         create_ddg_dep_from_intra_loop_link): Call it.
372
373 2012-01-02  Richard Guenther  <rguenther@suse.de>
374
375         PR other/51679
376         * invoke.texi (fassociative-math): Remove spurious paranthesis.
377
378 2012-01-01  Jakub Jelinek  <jakub@redhat.com>
379
380         * gcc.c (process_command): Update copyright notice dates.
381         * gcov.c (print_version): Likewise.
382         * gcov-dump.c (print_version): Likewise.
383         * mips-tfile.c (main): Likewise.
384         * mips-tdump.c (main): Likewise.
385
386 2012-01-01  Ira Rosen  <irar@il.ibm.com>
387
388         PR tree-optimization/51704
389         * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Check that
390         a use is inside the basic block or loop before accessing its vect info.
391
392 2012-01-01  Jan Hubicka  <jhjh@suse.cz>
393
394         PR rtl-optimization/51069
395         * cfgloopmanip.c (remove_path): Removing path making irreducible
396         region unconditional makes BB part of the region.
397
398 2012-01-01  Jakub Jelinek  <jakub@redhat.com>
399
400         PR tree-optimization/51683
401         * tree-ssa-propagate.c (substitute_and_fold): Don't optimize away
402         calls with side-effects.
403         * tree-ssa-ccp.c (ccp_fold_stmt): Likewise.
404
405 2011-12-31  Alexandre Oliva  <aoliva@redhat.com>
406
407         * cselib.h (cselib_add_permanent_equiv): Declare.
408         (canonical_cselib_val): New.
409         * cselib.c (new_elt_loc_list): Rework to support value
410         equivalences.  Adjust all callers.
411         (preserve_only_constants): Retain value equivalences.
412         (references_value_p): Retain preserved values.
413         (rtx_equal_for_cselib_1): Handle value equivalences.
414         (cselib_invalidate_regno): Use canonical value.
415         (cselib_add_permanent_equiv): New.
416         * alias.c (find_base_term): Reset locs lists while recursing.
417         * var-tracking.c (val_bind): New.  Don't add equivalences
418         present in cselib table, compared with code moved from...
419         (val_store): ... here.
420         (val_resolve): Use val_bind.
421         (VAL_EXPR_HAS_REVERSE): Drop.
422         (add_uses): Do not create MOps for addresses.  Do not mark
423         non-REG non-MEM expressions as requiring resolution.
424         (reverse_op): Record reverse as a cselib equivalence.
425         (add_stores): Use it.  Do not create MOps for addresses.
426         Do not require resolution for non-REG non-MEM expressions.
427         Simplify support for reverse operations.
428         (compute_bb_dataflow): Drop reverse support.
429         (emit_notes_in_bb): Likewise.
430         (create_entry_value): Rename to...
431         (record_entry_value): ... this.  Use cselib equivalences.
432         (vt_add_function_parameter): Adjust.
433
434 2011-12-30  Michael Meissner  <meissner@linux.vnet.ibm.com>
435
436         * config/rs6000/rs6000.c (rs6000_inner_target_options): Fix thinko
437         in setting options via target #pragma or attribute.
438
439 2011-12-30  Anatoly Sokolov  <aesok@post.ru>
440
441         * config/bfin/bfin.h (REGISTER_MOVE_COST, MEMORY_MOVE_COST): Remove.
442         * config/bfin/bfin-protos.h (bfin_register_move_cost,
443         bfin_memory_move_cost): Remove.
444         * config/bfin/bfin.c (bfin_register_move_cost,
445         bfin_memory_move_cost): Make static. Change arguments type from
446         enum reg_class to reg_class_t and from int to bool.
447         (TARGET_REGISTER_MOVE_COST, TARGET_MEMORY_MOVE_COST): Define.
448
449 2011-12-30  Nathan Sidwell  <nathan@acm.org>
450
451         * gcov.c (total_lines, total_executed): New global vars.
452         (generate_results): Call executed_summary.
453         (executed_summary): New function, broken out of ...
454         (function_summary): ... here.  Call it.
455         * coverage.c (coverage_finish): Also check for local_tick == -1.
456         * gcov-dump (tag_function): Correct labelling typo.
457
458 2011-12-29  Michael Meissner  <meissner@linux.vnet.ibm.com>
459
460         PR target/51623
461         * config/rs6000/rs6000.c (rs6000_assemble_integer): Delete check
462         for an initialized pointer being in a text section with
463         -mrelocatable, since it should never happen.
464
465 2011-12-29  Michael Eager  <eager@eagercon.com>
466
467         * config/microblaze/microblaze.md: Add expander for simple_return,
468         return, add return_internal and simple_return_internal insns.
469
470 2011-12-29  Oleg Endo  <olegendo@gcc.gnu.org>
471
472         * config/sh/sh.h (BRANCH_COST): Use sh_branch_cost variable.
473         * config/sh/sh.c (sh_option_override): Simplify sh_branch_cost
474         expression.
475
476 2011-12-28  Ian Lance Taylor  <iant@google.com>
477
478         * dwarf2out.c (gen_compile_unit_die): Use DW_LANG_Go for Go.
479
480 2011-12-28  Michael Meissner  <meissner@linux.vnet.ibm.com>
481
482         PR target/51623
483         * config/rs6000/rs6000.c (rs6000_assemble_integer): Don't call
484         unlikely_text_section_p.  Instead check for being in a code section.
485
486 2011-12-28  Ira Rosen  <irar@il.ibm.com>
487
488         PR tree-optimization/51684
489         * tree-vect-slp.c (vect_schedule_slp_instance): Get gsi of original
490         statement in case of a pattern.
491         (vect_schedule_slp): Likewise.
492
493 2011-12-27  Eric Botcazou  <ebotcazou@adacore.com>
494
495         PR rtl-optimization/51667
496         * ree.c (insn_merge_code): Delete.
497         (is_insn_merge_attempted): Likewise.
498         (get_insn_status): Likewise.
499         (set_insn_status): Likewise.
500         (struct ext_cand): Add CODE and MODE fields.
501         (combine_set_extend): Rename to...
502         (combine_set_extension): ...this.  Use above fields and tidy up.
503         (transform_ifelse): Likewise.
504         (get_defs): Return the chain of definitions.
505         (is_this_a_cmove): Merge into...
506         (is_cond_copy_insn): ...this.  Return bool.
507         (make_defs_and_copies_lists): Adjust calls to get_defs and simplify.
508         (merge_def_and_ext): Adjust call to combine_set_extend.
509         (combine_reaching_defs): Remove calls to {g|s}et_insn_status.
510         (struct extend_info): Rename to...
511         (struct re_info): ...this.  Add DEF_MAP field.
512         (add_ext_candidate): Merge into...
513         (add_removable_extension): ...this.  Adjust calls to get_defs.  Ensure
514         reaching definitions are associated with only one kind of extension.
515         (find_removable_extensions): Create and destroy the definition map.
516         (find_and_remove_re): Return void.  Change 'long' variables to 'int'.
517         Do not deal with is_insn_merge_attempted.
518
519 2011-12-25  Jan Hubicka  <jh@suse.cz>
520
521         PR middle-end/48641
522         * tree-ssa-threadupdate.c (redirect_edges): Watch for overflow.
523
524 2011-12-26  Oleg Endo  <oleg.endo@t-online.de>
525
526         * config/sh/sync.md: Add soft atomics ABI description.
527         (fetchop_name): Use 'or' instead of 'ior'.
528         (fetchop_insn): Remove.
529         (atomic_compare_and_swap<mode>_soft):
530         Don't insert aligning nop after the write-back instruction.  Fix
531         multi-line asm output formatting style.
532         (atomic_fetch_<fetchop_name><mode>_soft): Likewise.
533         (atomic_fetch_nand<mode>_soft): Likewise.
534         (atomic_<fetchop_name>_fetch<mode>_soft): Likewise.
535         (atomic_nand_fetch<mode>_soft): Likewise.
536
537 2011-12-23  Richard Henderson  <rth@redhat.com>
538
539         * tree.def (VEC_EXTRACT_EVEN_EXPR, VEC_EXTRACT_ODD_EXPR): Remove.
540         * cfgexpand.c (expand_debug_expr): Don't handle them.
541         * expr.c (expand_expr_real_2): Likewise.
542         * fold-const.c (fold_binary_loc): Likewise.
543         * gimple-pretty-print.c (dump_binary_rhs): Likewise.
544         * tree-cfg.c (verify_gimple_assign_binary): Likewise.
545         * tree-inline.c (estimate_operator_cost): Likewise.
546         * tree-pretty-print.c (dump_generic_node): Likewise.
547         * tree-vect-generic.c (expand_vector_operations_1): Likewise.
548         * optabs.c (optab_for_tree_code): Likewise.
549         (can_vec_perm_for_code_p): Remove.
550         (expand_binop): Don't try it.
551         (init_optabs): Don't init vec_extract_even/odd_optab.
552         * genopinit.c (optabs): Likewise.
553         * optabs.h (OTI_vec_extract_even, OTI_vec_extract_odd): Remove.
554         (vec_extract_even_optab, vec_extract_odd_optab): Remove.
555         * tree-vect-data-refs.c (vect_strided_store_supported): Tidy code.
556         (vect_permute_store_chain): Use TYPE_VECTOR_SUBPARTS instead of
557         GET_MODE_NUNITS; check vect_gen_perm_mask return value instead of
558         asserting vect_strided_store_supported.
559         (vect_strided_load_supported): Use can_vec_perm_p.
560         (vect_permute_load_chain): Use VEC_PERM_EXPR.
561
562         * doc/generic.texi (VEC_EXTRACT_EVEN_EXPR): Remove.
563         (VEC_EXTRACT_ODD_EXPR): Remove.
564         * doc/md.texi (vec_extract_even, vec_extract_odd): Remove.
565
566 2011-12-23  Anatoly Sokolov  <aesok@post.ru>
567
568         * config/score/score.h (REGISTER_MOVE_COST, MEMORY_MOVE_COST): Remove.
569         * config/score/score-protos.h (score_register_move_cost): Remove.
570         * config/score/score.c (TARGET_REGISTER_MOVE_COST): Define.
571         (score_register_move_cost): Make static. Change arguments type from
572         enum reg_class to reg_class_t.
573
574 2011-12-23  Jakub Jelinek  <jakub@redhat.com>
575             Richard Henderson  <rth@redhat.com>
576
577         * tree.def (VEC_INTERLEAVE_HIGH_EXPR, VEC_INTERLEAVE_LOW_EXPR): Remove.
578         * gimple-pretty-print.c (dump_binary_rhs): Don't handle
579         VEC_INTERLEAVE_HIGH_EXPR and VEC_INTERLEAVE_LOW_EXPR.
580         * expr.c (expand_expr_real_2): Likewise.
581         * tree-cfg.c (verify_gimple_assign_binary): Likewise.
582         * cfgexpand.c (expand_debug_expr): Likewise.
583         * tree-inline.c (estimate_operator_cost): Likewise.
584         * tree-pretty-print.c (dump_generic_node): Likewise.
585         * tree-vect-generic.c (expand_vector_operations_1): Likewise.
586         * fold-const.c (fold_binary_loc): Likewise.
587         * doc/generic.texi (VEC_INTERLEAVE_HIGH_EXPR,
588         VEC_INTERLEAVE_LOW_EXPR): Remove documentation.
589         * optabs.c (optab_for_tree_code): Don't handle
590         VEC_INTERLEAVE_HIGH_EXPR and VEC_INTERLEAVE_LOW_EXPR.
591         (expand_binop, init_optabs): Remove vec_interleave_high_optab
592         and vec_interleave_low_optab.
593         * genopinit.c (optabs): Likewise.
594         * optabs.h (OTI_vec_interleave_high, OTI_vec_interleave_low): Remove.
595         (vec_interleave_high_optab, vec_interleave_low_optab): Remove.
596         * doc/md.texi (vec_interleave_high, vec_interleave_low): Remove
597         documentation.
598         * tree-vect-stmts.c (gen_perm_mask): Renamed to...
599         (vect_gen_perm_mask): ... this.  No longer static.
600         (perm_mask_for_reverse, vectorizable_load): Adjust callers.
601         * tree-vectorizer.h (vect_gen_perm_mask): New prototype.
602         * tree-vect-data-refs.c (vect_strided_store_supported): Don't try
603         VEC_INTERLEAVE_*_EXPR, use can_vec_perm_p instead of
604         can_vec_perm_for_code_p.
605         (vect_permute_store_chain): Generate VEC_PERM_EXPR with interleaving
606         masks instead of VEC_INTERLEAVE_HIGH_EXPR and VEC_INTERLEAVE_LOW_EXPR.
607         * config/i386/i386.c (expand_vec_perm_interleave2): If
608         expand_vec_perm_interleave3 would handle it, return false.
609         (expand_vec_perm_broadcast_1): Don't use vec_interleave_*_optab.
610
611 2011-12-23  Richard Henderson  <rth@redhat.com>
612
613         * config/mips/loongson.md (UNSPEC_LOONGSON_PINSR_0,
614         UNSPEC_LOONGSON_PINSR_1, UNSPEC_LOONGSON_PINSR_2,
615         UNSPEC_LOONGSON_PINSR_3): Replace with...
616         (UNSPEC_LOONGSON_PINSRH): ... this.
617         (UNSPEC_LOONGSON_VINIT): New.
618         (UNSPEC_LOONGSON_DSLL, UNSPEC_LOONGSON_DSRL): New.
619         (VWB): New mode iterator.
620         (V_inner): New mode attribute.
621         (loongson_vec_init1_<VHB>): New.
622         (*vec_concatv2si): New.
623         (and<VWHB>3, ior<VWHB>3, xor<VWHB>3, one_cmpl<VWHB>2): New.
624         (*loongson_nor): New.
625         (loongson_pextrh): Un-macro-ify.
626         (loongson_pmaddhw): Likewise.
627         (smaxv4hi3, umaxv8qi3, sminv4hi3, uminv8qi3): Likewise.
628         (loongson_pinsrh_0): Represent with vec_select+vec_concat.
629         (loongson_pinsrh_1, loongson_pinsrh_2, loongson_pinsrh_3): Likewise.
630         (*vec_setv4hi, vec_setv4hi): New.
631         (sdot_prodv4hi): New.
632         (smax<VWB>3, smin<VWB>3): New.
633         (reduc_uplus_v8qi): New.
634         (loongson_pshufh): Remove destination matching input.
635         (ashl<VWH>3, ashr<VWH>3, lshr<VWH>3): Fix type attribute.
636         (vec_interleave_high<VWHB>, vec_interleave_low<VWHB>): Remove.
637         (loongson_punpckhbh, loongson_punpckhhw, loongson_punpckhhw_qi,
638         loongson_punpckhwd, loongson_punpckhwd_qi, loongson_punpckhwd_hi,
639         loongson_punpcklbh, loongson_punpcklhw, loongson_punpcklhw_qi,
640         loongson_punpcklwd, loongson_punpcklwd_qi, loongson_punpcklwd_hi,
641         vec_perm_const<VWHB>, vec_unpacks_lo_<VHB>, vec_unpacks_hi_<VHB>,
642         vec_unpacku_lo_<VHB>, vec_unpacku_hi_<VHB>, vec_shl_<VWHBDI>,
643         vec_shr_<VWHBDI>, reduc_uplus_<VWH>, reduc_splus_<VWHB>,
644         reduc_smax_<VWHB>, reduc_smin_<VWHB>, reduc_umax_<VWHB>,
645         reduc_umin_<VB>): New.
646         * config/mips/mips-ps-3d.md (vec_perm_const_ps): New.
647         (mips_pul_ps, mips_puu_ps, mips_pll_ps, mips_plu_ps): Expand in
648         terms of vec_perm_const_ps.
649         (vec_perm_constv2sf): New.
650         (vec_initv2sf): Use mips_expand_vector_init.
651         (vec_concatv2sf): Rename from vec_initv2sf_internal.
652         (vec_setv2sf): Use vec_perm_const_ps.
653         (reduc_splus_v2sf, reduc_smin_v2sf, reduc_smax_v2sf): New.
654         * config/mips/loongson.h (pshufh_u, pshufh_s): Don't pass dest to
655         the builtin.
656         * config/mips/mips-modes.def (V16QI, V8HI, V4SI, V4SF): New modes.
657         * config/mips/mips-protos.h: Update.
658         * config/mips/mips.c (mips_get_arg_info): Match V2SFmode, not all
659         MODE_VECTOR_FLOAT.
660         (mips_return_mode_in_fpr_p): Likewise.
661         (mips_cannot_change_mode_class): Allow 8-byte integral mode changes.
662         (CODE_FOR_loongson_punpckhbh, CODE_FOR_loongson_punpckhhw,
663         CODE_FOR_loongson_punpckhwd, CODE_FOR_loongson_punpcklbh,
664         CODE_FOR_loongson_punpcklhw, CODE_FOR_loongson_punpcklwd): Remove.
665         (mips_builtins): Remove first operand for loongson pshufh builtins.
666         (MAX_VECT_LEN, struct expand_vec_perm_d): New.
667         (mips_expand_vselect, mips_expand_vselect_vconcat,
668         mips_expand_vpc_loongson_even_odd, mips_expand_vpc_loongson_pshufh,
669         mips_expand_vpc_loongson_bcast, mips_expand_vec_perm_const_1,
670         mips_expand_vec_perm_const, mips_vectorize_vec_perm_const_ok,
671         mips_expand_vec_unpack, mips_constant_elt_p, mips_expand_vi_broadcast,
672         mips_expand_vi_constant, mips_expand_vi_loongson_one_pinsrh,
673         mips_expand_vi_general, mips_expand_vec_reduc, mips_expand_vec_minmax,
674         TARGET_VECTORIZE_VEC_PERM_CONST_OK): New.
675         (mips_expand_vector_init): Rewrite.
676         * config/mips/predicates.md (const_2_or_3_operand): New.
677         (const_0_to_3_operand): New.
678
679 2011-12-23  Dmitry Plotnikov  <dplotnikov@ispras.ru>
680
681         * config/arm/neon.md (float<mode><V_cvtto>2): New.
682         (floatuns<mode><V_cvtto>2): New.
683         (fix_trunc<mode><V_cvtto>2): New.
684         (fix_truncuns<mode><V_cvtto>2): New.
685         * config/arm/iterators.md (V_cvtto): New iterator.
686
687 2011-12-23  Richard Guenther  <rguenther@suse.de>
688
689         PR rtl-optimization/50396
690         * simplify-rtx.c (simplify_binary_operation_1): Properly
691         guard code that only works for integers.
692
693 2011-12-23  Tristan Gingold  <gingold@adacore.com>
694
695         * config/vms/vms-crtlmap.map (log10): Fix typo.
696
697 2011-12-23  Tristan Gingold  <gingold@adacore.com>
698
699         * config/ia64/vms.h (SUPPORTS_ONE_ONLY): Define.
700
701 2011-12-22  Bin Cheng  <bin.cheng@arm.com>
702         Richard Guenther  <rguenther@suse.de>
703
704         PR tree-optimization/43491
705         * tree-ssa-pre.c (eliminate): Don't replace global register
706         variable when it is the RHS of a single assign.
707
708 2011-12-22  Joey Ye  <joey.ye@arm.com>
709
710         * toplev.c (process_options): Fix typo.
711
712 2011-12-22  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
713
714         PR middle-end/51252
715         * config/pa/pa.c (pa_som_tm_clone_table_section): New function.
716         (som_tm_clone_table_section): Declare.
717         (pa_file_start_space): Create $TM_CLONE_TABLE$ subspace.
718         (pa_som_asm_init_sections): Init som_tm_clone_table_section.
719         * config/pa/som.h (TARGET_ASM_TM_CLONE_TABLE_SECTION): Define.
720
721 2011-12-22  Richard Sandiford  <rdsandiford@googlemail.com>
722
723         * doc/tm.texi.in (TARGET_PREPARE_PCH_SAVE): New hook.
724         * doc/tm.texi: Regenerate.
725         * target.def (prepare_pch_save): New hook.
726         * c-family/c-pch.c (c_common_write_pch): Call it.
727         * config/mips/mips.c (was_mips16_pch_p): Delete.
728         (mips_set_mips16_mode): Don't refer to was_mips16_pch_p.
729         (mips_prepare_pch_save): New function.
730         (TARGET_PREPARE_PCH_SAVE): Define.
731
732 2011-12-22  Aldy Hernandez  <aldyh@redhat.com>
733
734         PR middle-end/51212
735         * opts.c (finish_options): Call sorry on -fgnu-tm and
736         -fnon-call-exceptions combination.
737
738 2011-12-22  Jonathan Wakely  <jwakely.gcc@gmail.com>
739
740         * doc/invoke.texi (C++ Dialect Options): Add missing options and
741         move -Wzero-as-null-pointer-constant to ...
742         (Warning Options): ... here.
743
744 2011-12-22  Jonathan Wakely  <jwakely.gcc@gmail.com>
745
746         PR target/47643
747         * doc/invoke.texi (i386 and x86-64 Options): Fix description of
748         -mtune without -march.
749
750 2011-12-21  Richard Earnshaw  <rearnsha@arm.com>
751
752         PR target/51643
753         * arm.c (arm_function_ok_for_sibcall): Use DECL_WEAK in previous
754         change.
755
756 2011-12-22  Tristan Gingold  <gingold@adacore.com>
757
758         * config/ia64/ia64.c (ia64_promote_function_mode): Remove.
759         (TARGET_PROMOTE_FUNCTION_MODE): Remove.
760         (ia64_function_value): Call promote_function_mode instead of
761         ia64_promote_function_mode.
762         * config/ia64/vms.h (PROMOTE_MODE): Define.
763         (TARGET_PROMOTE_FUNCTION_MODE): Define.
764
765 2011-12-22  Uros Bizjak  <ubizjak@gmail.com>
766
767         PR target/27468
768         * common/config/alpha/alpha-common.c (alpha_option_optimization_table):
769         Enable flag_ree at -O2 or higher.
770
771 2011-12-22  Richard Guenther  <rguenther@suse.de>
772
773         PR lto/51650
774         * lto.c (uniquify_nodes): Register TYPE_DECLs with the
775         debuginfo machinery.
776
777 2011-12-22  Bernd Schmidt  <bernds@codesourcery.com>
778
779         * tree-pass.h (pass_reload): Declare.
780         * ira.c (overall_cost_before, saved_flag_ira_share_spill_slots):
781         New global variables, moved out of ira.
782         (do_reload): New static function, split off from the second half
783         of ...
784         (ira): ... here.
785         (gate_ira): Remove.
786         (pass_ira): Use TV_IRA, set gate to NULL, and set flags to
787         TODO_dump_func.
788         (rest_of_handle_reload): New static function.
789         (pass_reload): New.
790
791 2011-12-22  Uros Bizjak  <ubizjak@gmail.com>
792
793         * common/config/i386/i386-common.c (ix86_option_optimization_table):
794         Move OPT_free processing from ...
795         * config/i386/i386.c (ix86_option_override_internal):  ... here.
796
797 2011-12-21  Richard Earnshaw  <rearnsha@arm.com>
798
799         PR target/51643
800         * arm.c (arm_function_ok_for_sibcall): Don't try to tailcall a
801         weak function on bare-metal EABI targets.
802
803 2011-12-21  Jonathan Wakely  <jwakely.gcc@gmail.com>
804             Jim Avera  <james_avera@yahoo.com>
805
806         * doc/extend.texi (__builtin_expect): Improve example.
807
808 2011-12-21  Uros Bizjak  <ubizjak@gmail.com>
809
810         * config/i386/i386.c (ix86_option_override_internal): Enable flag_ree
811         also for 32bit targets.
812
813 2011-12-21  Richard Henderson  <rth@redhat.com>
814
815         PR target/51552
816         * dwarf2cfi.c (dwarf2out_frame_debug): Move any_cfis_emitted code...
817         (scan_trace): ... here.
818
819 2011-12-21  Jason Merrill  <jason@redhat.com>
820
821         * doc/standards.texi (C++ language): Update for C++11.
822
823 2011-12-21  Jakub Jelinek  <jakub@redhat.com>
824
825         * tree-vect-patterns.c (vect_operation_fits_smaller_type): Initialize
826         *op0 and *op1 to NULL_TREE first to avoid warnings.
827         * calls.c (initialize_argument_information): Initialize base to avoid
828         warnings.
829
830         PR middle-end/51644
831         PR middle-end/51647
832         * tree-eh.c (decide_copy_try_finally): At -O0, return true
833         even when ndests is not 1, if there are only gimple_clobber_p
834         (or debug) stmts in the finally sequence.
835         * tree-inline.c (estimate_num_insns): Return 0 for gimple_clobber_p
836         stmts.
837
838 2011-12-21  Aldy Hernandez  <aldyh@redhat.com>
839
840         PR middle-end/51472
841         * trans-mem.c (tm_log_add): Use create_tmp_var_reg.
842
843 2011-12-21  Martin Jambor  <mjambor@suse.cz>
844
845         * tree-into-ssa.c (rewrite_update_stmt): Do not dump extra newlines.
846         (rewrite_update_enter_block): Likewise.
847         (dump_update_ssa): Likewise.
848         (update_ssa): Likewise but also dump a newline at the beginning.
849
850 2011-12-21  Enkovich Ilya  <ilya.enkovich@intel.com>
851
852         PR target/50038
853         * implicit-zee.c: Delete.
854         * ree.c: New file.
855         * Makefile.in: Replace implicit-zee.c with ree.c.
856         * config/i386/i386.c (ix86_option_override_internal): Rename
857         flag_zee to flag_ree.
858         * common.opt (fzee): Ignored.
859         (free): New.
860         * passes.c (init_optimization_passes): Replace pass_implicit_zee
861         with pass_ree.
862         * tree-pass.h (pass_implicit_zee): Delete.
863         (pass_ree): New.
864         * timevar.def (TV_ZEE): Delete.
865         (TV_REE): New.
866         * doc/invoke.texi: Add -free description.
867
868 2011-12-21  Tristan Gingold  <gingold@adacore.com>
869
870         * config/vms/vms-protos.h (vms_function_section): New prototype.
871         * config/vms/vms.c (vms_function_section): New function.
872         * config/vms/vms.h (TARGET_ASM_FUNCTION_SECTION): Define.
873
874 2011-12-21  Richard Guenther  <rguenther@suse.de>
875
876         PR lto/41159
877         * tree-outof-ssa.c (insert_value_copy_on_edge): Use the
878         mode of the pseudo as destination mode.  Only assert that
879         is equal to the promoted mode of the decl if it is a REG.
880
881 2011-12-21  Tristan Gingold  <gingold@adacore.com>
882
883         * config/vms/xm-vms.h (STANDARD_EXEC_PREFIX): Remove define.
884
885 2011-12-20  Richard Henderson  <rth@redhat.com>
886
887         * config/ia64/ia64.c (MAX_VECT_LEN): New.
888         (struct expand_vec_perm_d): New.
889         (TARGET_VECTORIZE_VEC_PERM_CONST_OK): New.
890         (ia64_unpack_assemble): Use ia64_expand_vec_perm_const_1.
891         (expand_vselect, expand_vselect_vconcat): New.
892         (expand_vec_perm_identity, expand_vec_perm_shrp): New.
893         (expand_vec_perm_1, expand_vec_perm_broadcast): New.
894         (expand_vec_perm_interleave_2, expand_vec_perm_v4hi_5): New.
895         (ia64_expand_vec_perm_const_1, ia64_expand_vec_perm_const): New.
896         (ia64_vectorize_vec_perm_const_ok): New.
897         (ia64_expand_vec_setv2sf, ia64_expand_vec_perm_even_odd): New.
898         * config/ia64/ia64-protos.h: Update.
899         * config/ia64/vect.md (VEC): New mode iterator.
900         (vecint): New mode attribute.
901         (vec_interleave_lowv8qi, vec_interleave_highv8qi): Privatize with '*'.
902         (vec_interleave_lowv4hi, vec_interleave_highv4hi): Likewise.
903         (vec_interleave_lowv2si, vec_interleave_highv2si): Likewise.
904         (vec_interleave_lowv2sf, vec_interleave_highv2sf): Likewise.
905         (mix1_even, mix1_odd, mux1_alt): Likewise.
906         (mux1_brcst_qi): Remove '*' from name.
907         (vec_extract_evenv8qi, vec_extract_oddv8qi): Remove.
908         (vec_extract_evenv4hi, vec_extract_oddv4hi): Remove.
909         (vec_extract_evenv2si, vec_extract_oddv2si): Remove.
910         (vec_extract_evenv2sf, vec_extract_oddv2sf): Remove.
911         (vec_extract_evenodd_helper): Remove.
912         (vec_setv2sf): Use ia64_expand_vec_setv2sf.
913         (vec_pack_trunc_v4hi): Use ia64_expand_vec_perm_even_odd.
914         (vec_pack_trunc_v2si): Likewise.
915         (vec_perm_const<VEC>): New.
916
917 2011-12-20  Richard Henderson  <rth@redhat.com>
918
919         * tree-vect-generic.c (expand_vector_operations_1): Correct tests
920         for vector types -- use the type not the mode.  Fix optab selection
921         for vector shifts by a scalar.  Handle over-large integer modes
922         like BLKmode.
923
924 2011-12-20  Richard Henderson  <rth@redhat.com>
925
926         * config/arm/arm.md (*arm_xorsi3): Match iorsi3 and perform
927         post-reload splitting.
928
929         * config/arm/arm.md (*arm_cmpdi_unsigned): Enable for thumb2.
930         * config/arm/arm.c (arm_select_cc_mode): Use it.
931
932 2011-12-20  Richard Sandiford  <rdsandiford@googlemail.com>
933
934         * tree-ssa-math-opts.c (convert_plusminus_to_widen): Restrict
935         handling of signedness differences to integer types.  Only build
936         a new optype if type1 isn't correct.
937
938 2011-12-20  Vladimir Makarov  <vmakarov@redhat.com>
939
940         PR target/49865
941         * ira-costs.c (find_costs_and_classes): Prefer registers even
942         if the memory cost is the same.
943
944 2011-12-20  Joseph Myers  <joseph@codesourcery.com>
945
946         * c-decl.c (diagnose_mismatched_decls, grokdeclarator, grokfield)
947         (finish_struct): Refer to C11 in comments.  Use flag_isoc11.
948         * c-parser.c (c_parser_static_assert_declaration)
949         (c_parser_static_assert_declaration_no_semi, c_parser_declspecs)
950         (c_parser_alignas_specifier, c_parser_alignof_expression): Refer
951         to C11 in comments.  Use flag_isoc11.
952         * c-typeck.c (comptypes_check_different_types): Refer to C11 in
953         comment.
954         * doc/cpp.texi (Overview): Refer to -std=c11 instead of -std=c1x.
955         * doc/cppopts.texi (-std=c11, -std=gnu11): Document in preference
956         to -std=c1x and -std=gnu1x.
957         * doc/extend.texi (Inline, Alternate Keywords, Other Builtins)
958         (__builtin_complex, Unnamed Fields): Refer to -std=c11 and C11
959         instead of -std=c1x and C1X.
960         * doc/invoke.texi (-std=c11, -std=iso9899:2011): Document in
961         preference to -std=c1x.
962         (-std=gnu11): Document in preference to -std=gnu1x.
963         * doc/standards.texi: Document C11 instead of C1X.  Document C11
964         as actual standard.  Document headers required from freestanding
965         C11 implementations.
966         * ginclude/float.h, ginclude/stddef.h: Test __STDC_VERSION__ >=
967         201112L for C11.  Update comments to refer to C11.
968
969 2011-12-20  Andreas Schwab  <schwab@linux-m68k.org>
970
971         * configure: Regenerate.
972
973 2011-12-20  Bernd Schmidt  <bernds@codesourcery.com>
974
975         PR middle-end/51200
976         * expr.c (store_field): Avoid a direct store if the mode is larger
977         than the size of the bit field.
978         * stor-layout.c (layout_decl): If flag_strict_volatile_bitfields,
979         treat non-volatile bit fields like volatile ones.
980         * toplev.c (process_options): Disallow combination of
981         -fstrict-volatile-bitfields and ABI versions less than 2.
982         * config/arm/arm.c (arm_option_override): Don't enable
983         flag_strict_volatile_bitfields if the ABI version is less than 2.
984         * config/h8300/h8300.c (h8300_option_override): Likewise.
985         * config/rx/rx.c (rx_option_override): Likewise.
986         * config/m32c/m32c.c (m32c_option_override): Likewise.
987         * config/sh/sh.c (sh_option_override): Likewise.
988
989 2011-12-20  Richard Guenther  <rguenther@suse.de>
990
991         PR lto/46796
992         * dwarf2out.c (modified_type_die): When the type variant
993         chain is corrupt use the types name, if available, instead
994         of __unknown__.
995
996 2011-12-20  Tristan Gingold  <gingold@adacore.com>
997
998         * config/alpha/alpha.c (alpha_start_function): Adjust condition to
999         create VMS trampoline entry point.
1000
1001 2011-12-19  Richard Sandiford  <rdsandiford@googlemail.com>
1002
1003         PR rtl-optimization/42839
1004         * fwprop.c (forward_propagate_subreg): Skip the SIGN/ZERO_EXTEND
1005         optimization if the source register is already extended.
1006
1007 2011-12-19  Richard Sandiford  <rdsandiford@googlemail.com>
1008
1009         * lower-subreg.c (can_decompose_p): Check every word of a hard
1010         register.
1011
1012 2011-12-19  Sandra Loosemore  <sandra@codesourcery.com>
1013             Tom de Vries <tom@codesourcery.com>
1014
1015         PR rtl-opt/50380
1016         * cse.c (find_comparison_args): Detect fixed point and
1017         bail early.
1018
1019 2011-12-19  Aldy Hernandez  <aldyh@redhat.com>
1020
1021         PR middle-end/51411
1022         * trans-mem.c (ipa_tm_create_version): Unset DECL_WEAK.
1023
1024 2011-12-19  Quentin Neill  <quentin.neill@amd.com>
1025
1026         PR target/48743
1027         * config/i386/driver-i386.c (host_detect_local_cpu): Also check
1028         family to distinguish PROCESSOR_ATHLON.
1029
1030 2011-12-19  Richard Guenther  <rguenther@suse.de>
1031
1032         PR lto/51573
1033         * streamer-hooks.h (struct streamer_hooks): Add second
1034         ref_p parameter to write_tree.
1035         (stream_write_tree): Adjust.
1036         (stream_write_tree_shallow_non_ref): New define.
1037         * lto-streamer.h (lto_output_tree): Adjust.
1038         * lto-streamer-out.c (lto_output_tree): Likewise.
1039         * tree-streamer-out.c (streamer_write_chain): Only
1040         force the immediate tree to be streamed as non-reference.
1041
1042 2011-12-19  Martin Jambor  <mjambor@suse.cz>
1043
1044         PR tree-optimization/51583
1045         * tree-sra.c (load_assign_lhs_subreplacements): Call
1046         force_gimple_operand_gsi when necessary also in case of no
1047         corresponding replacement on the RHS.
1048
1049 2011-12-19  Jakub Jelinek  <jakub@redhat.com>
1050
1051         * gimple.h (gimplify_seq_add_stmt): Rename to...
1052         (gimple_seq_add_stmt_without_update): ... this.
1053         * gimplify.c (gimplify_seq_add_stmt): Rename to...
1054         (gimple_seq_add_stmt_without_update): ... this.
1055         (gimplify_seq_add_stmt): New inline wrapper for it.
1056         * tree-vect-patterns.c (append_pattern_def_seq): Use
1057         gimple_seq_add_stmt_without_update instead of gimplify_seq_add_stmt.
1058
1059         PR tree-optimization/51596
1060         * tree-cfg.c (replace_uses_by): Call gimple_purge_dead_eh_edges
1061         when needed.
1062
1063         PR middle-end/51590
1064         PR tree-optimization/51606
1065         * tree-vect-patterns.c (append_pattern_def_seq, new_pattern_def_seq):
1066         New inline functions.
1067         (vect_recog_over_widening_pattern,
1068         vect_recog_vector_vector_shift_pattern,
1069         vect_recog_sdivmod_pow2_pattern, vect_recog_mixed_size_cond_pattern,
1070         adjust_bool_pattern_cast, vect_recog_bool_pattern): Use them.
1071
1072 2011-12-19  Richard Guenther  <rguenther@suse.de>
1073
1074         PR lto/51572
1075         * tree.c (free_lang_data_in_type): Do not unlink TYPE_DECL
1076         from TYPE_FIELDS.
1077         (find_decls_types_r): Walk TYPE_DECLs in TYPE_FIELDS.
1078         * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Do
1079         not stream TREE_CHAIN.
1080         (write_ts_type_non_common_tree_pointers): Stream TYPE_FIELDS
1081         using streamer_write_chain.
1082         * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
1083         Do not stream TREE_CHAIN.
1084         (lto_input_ts_type_non_common_tree_pointers): Stream TYPE_FIELDS
1085         using streamer_read_chain.
1086         * gimple-streamer-in.c (input_gimple_stmt): Skip non-FIELD_DECLs.
1087         * gimple.c (gimple_canonical_types_compatible_p): Properly
1088         handle trailing non-FIELD_DECLs in TYPE_FIELDS.
1089
1090 2011-12-19  Andreas Schwab  <schwab@linux-m68k.org>
1091
1092         * configure: Regenerate.
1093
1094 2011-12-19  Bernd Schmidt  <bernds@codesourcery.com>
1095
1096         * emit-rtl.c (init_emit_once): Initialize const_tiny_rtx[3] for
1097         partial integer modes.
1098
1099 2011-12-19  Andreas Schwab  <schwab@linux-m68k.org>
1100
1101         PR target/51532
1102         * config/m68k/m68k.h (FL_CAS, TARGET_CAS): Define.
1103         * config/m68k/m68k.c (FL_FOR_isa_20): Add FL_CAS.
1104         * config/m68k/sync.md: Use TARGET_CAS instead of (TARGET_68020 ||
1105         TARGET_68040).
1106
1107 2011-12-18  Anatoly Sokolov  <aesok@post.ru>
1108
1109         * config/ia64/ia64.h (REG_OK_FOR_BASE_P, REG_OK_FOR_INDEX_P,
1110         LEGITIMATE_ADDRESS_REG, LEGITIMATE_ADDRESS_DISP,
1111         GO_IF_LEGITIMATE_ADDRESS): Remove macros.
1112         * config/ia64/ia64.c (TARGET_LEGITIMATE_ADDRESS_P): Define.
1113         (ia64_reg_ok_for_base_p, ia64_legitimate_address_reg,
1114         ia64_legitimate_address_disp, ia64_legitimate_address_p): New
1115         functions.
1116
1117 2011-12-17  Tom de Vries  <tom@codesourcery.com>
1118
1119         PR tree-optimization/51491
1120         * tree-ssa-ccp.c (insert_clobber_before_stack_restore)
1121         (gsi_prev_dom_bb_nondebug, insert_clobbers_for_var): New function.
1122         (ccp_fold_stmt): Use insert_clobbers_for_var after a successful
1123         fold_builtin_alloca_with_align.
1124         (ccp_visit_stmt): Calculate and free dominator info.
1125
1126 2011-12-16  Eric Botcazou  <ebotcazou@adacore.com>
1127
1128         * config/sparc/sparc.md (UNSPEC_FRAME_BLOCKAGE): New constant.
1129         (frame_blockage): New expander.
1130         (frame_blockage<P:mode>): New instruction.
1131         * config/sparc/sparc.c (sparc_expand_prologue): When the sequence of
1132         instructions establishing the frame isn't atomic, emit frame blockage.
1133
1134 2011-12-16  Tristan Gingold  <gingold@adacore.com>
1135
1136         * config/alpha/vms.h (USE_TM_CLONE_REGISTRY): Define.
1137
1138 2011-12-16  Tristan Gingold  <gingold@adacore.com>
1139
1140         * config/alpha/alpha.c (alpha_use_linkage): Follow transparent alias.
1141         (alpha_write_one_linkage): Use assemble_name to emit linkage name.
1142
1143 2011-12-16  Tristan Gingold  <gingold@adacore.com>
1144
1145         * config/vms/t-vms (vms.o, vms-c.o): Force output filename.
1146
1147 2011-12-16  Tristan Gingold  <gingold@adacore.com>
1148
1149         * config/vms/vms.c (VMS_CRTL_GLOBAL): Define.
1150         (vms_patch_builtins): Handle.
1151         * config/vms/vms-crtlmap.map: Add an entry for environ.
1152
1153 2011-12-16  Jakub Jelinek  <jakub@redhat.com>
1154
1155         PR debug/51557
1156         * sel-sched-ir.c (create_copy_of_insn_rtx): Copy all notes
1157         other than REG_EQUAL, REG_EQUIV and REG_LABEL_OPERAND.
1158
1159         PR tree-optimization/51576
1160         * tree-cfg.c (replace_uses_by): Call maybe_clean_or_replace_eh_stmt
1161         even if fold_stmt didn't change anything.
1162
1163 2011-12-16  Richard Guenther  <rguenther@suse.de>
1164
1165         PR lto/51572
1166         * dwarf2out.c (gen_type_die_with_usage): Use the context of
1167         the TYPE_DECL as well if it is file-scope.
1168
1169 2011-12-15  DJ Delorie  <dj@redhat.com>
1170
1171         * config/rl78/rl78.md (return): Rename to rl78_return.
1172         * config/rl78/rl78.c (rl78_expand_epilogue): Use new name.
1173         (rl78_expand_eh_epilogue): Use new name.
1174         (rl78_calculate_death_notes): Likewise.
1175
1176 2011-12-15  Jakub Jelinek  <jakub@redhat.com>
1177
1178         * tree-vectorizer.h (struct _stmt_vec_info): Remove pattern_def_stmt
1179         field, add pattern_def_seq.
1180         (STMT_VINFO_PATTERN_DEF_STMT): Remove.
1181         (STMT_VINFO_PATTERN_DEF_SEQ): Define.
1182         (NUM_PATTERNS): Bump to 10.
1183         * tree-vect-loop.c (vect_determine_vectorization_factor,
1184         vect_transform_loop): Adjust for pattern def changing from a single
1185         gimple stmt to gimple_seq.
1186         * tree-vect-stmts.c (vect_analyze_stmt, new_stmt_vec_info,
1187         free_stmt_vec_info): Likewise.
1188         * tree-vect-patterns.c (vect_recog_over_widening_pattern,
1189         vect_recog_vector_vector_shift_pattern,
1190         vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast,
1191         adjust_bool_pattern, vect_mark_pattern_stmts): Likewise.
1192         (vect_recog_sdivmod_pow2_pattern): New function.
1193         (vect_vect_recog_func_ptrs): Add it.
1194
1195         * config/i386/sse.md (vcond<V_256:mode><VI_256:mode>,
1196         vcond<V_128:mode><VI124_128:mode>, vcond<VI8F_128:mode>v2di):
1197         Use general_operand instead of nonimmediate_operand for
1198         operand 5 and no predicate for operands 1 and 2.
1199         * config/i386/i386.c (ix86_expand_int_vcond): Optimize
1200         x < 0 ? -1 : 0 and x < 0 ? 1 : 0 into vector arithmetic
1201         resp. logical shift.
1202
1203 2011-12-15  Georg-Johann Lay  <avr@gjlay.de>
1204
1205         * config/avr/avr-protos.h (print_operand): Remove.
1206         (print_operand_address): Remove.
1207         * config/avr/avr.h (PRINT_OPERAND): Remove.
1208         (PRINT_OPERAND_ADDRESS): Remove.
1209         (PRINT_OPERAND_PUNCT_VALID_P): Remove.
1210         * config/avr/avr.c (TARGET_PRINT_OPERAND): New hook define.
1211         (TARGET_PRINT_OPERAND_ADDRESS): New hook define.
1212         (TARGET_PRINT_OPERAND_PUNCT_VALID_P): New hook define.
1213         (print_operand_address): Rename to...
1214         (avr_print_operand_address): ...this and make static.
1215         (print_operand): Rename to...
1216         (avr_print_operand): ...this and make static.
1217         (avr_print_operand_punct_valid_p): New static function.
1218
1219 2011-12-15  Andreas Tobler  <andreast@fgznet.ch>
1220
1221         * config/i386/freebsd.h (TARGET_ASM_FILE_END): Define.
1222
1223 2011-12-15  Jakub Jelinek  <jakub@redhat.com>
1224
1225         PR c/51360
1226         * c-parser.c (c_parser_omp_clause_num_threads,
1227         c_parser_omp_clause_schedule): Call mark_exp_read.
1228
1229 2011-12-15  Romain Geissler  <romain.geissler@gmail.com>
1230
1231         * builtins.def (BUILT_IN_STPNCPY_CHK): New definition.
1232         * builtins.c (expand_builtin, fold_builtin_4, maybe_emit_chk_warning):
1233         Add BUILT_IN_STPNCPY_CHK case.
1234         * gimple-fold.c (gimple_fold_builtin): Likewise.
1235         * tree-object-size.c (pass_through_call): Likewise.
1236         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1,
1237         call_may_clobber_ref_p_1): Likewise.
1238         * tree-ssa-structalias.c (find_func_aliases_for_builtin_call,
1239         find_func_clobbers): Likewise.
1240         * tree.h (fold_builtin_strncpy_chk): Rename to fold_builtin_stxncpy_chk
1241         * builtins.c (fold_builtin_strncpy_chk): Likewise.
1242         Rewrite stpncpy_chk calls to strncpy_chk calls if returned value is
1243         ignored.
1244
1245 2011-12-15  Richard Guenther  <rguenther@suse.de>
1246
1247         PR lto/51567
1248         * gimple.c (compare_type_names_p): Also compare the TREE_CODE.
1249         (iterative_hash_name): Also hash the TREE_CODE.
1250         (gimple_types_compatible_p_1): For types with a TYPE_DECL
1251         name and a type DECL_CONTEXT recurse to that type.
1252         (iterative_hash_gimple_type): Likewise.
1253
1254 2011-12-15  Iain Sandoe  <iains@gcc.gnu.org>
1255
1256         * config/rs6000/rs6000.c  (rs6000_emit_prologue): Move update of
1257         VRSave mask to save_world() when that is in use.
1258
1259 2011-12-15  Richard Guenther  <rguenther@suse.de>
1260
1261         * lto-wrapper.c (run_gcc): In non-parallel mode remove
1262         ltrans inputs immediately after processing them.  In parallel
1263         mode truncate the ltrans inputs in the make rule that processes
1264         them if temporary files are not to be preserved.
1265
1266 2011-12-15  Anatoly Sokolov  <aesok@post.ru>
1267
1268         * config/arm/arm.h (REGISTER_MOVE_COST, MEMORY_MOVE_COST): Remove.
1269         * config/arm/arm.c (arm_memory_move_cost, arm_register_move_cost):
1270         New functions.
1271         (TARGET_REGISTER_MOVE_COST, TARGET_MEMORY_MOVE_COST): Define.
1272
1273 2011-12-15  Richard Guenther  <rguenther@suse.de>
1274
1275         PR lto/51564
1276         * tree.h (REGISTER_DEFS_IN_THIS_STMT, NECESSARY,
1277         STMT_IN_SSA_EDGE_WORKLIST): Remove no longer existing flag
1278         uses documentation.
1279         (TREE_ASM_WRITTEN): Update documentation to mention its use
1280         on TYPE_DECLs from debug info generation.
1281         * tree-streamer-out.c (pack_ts_base_value_fields): Stream
1282         TREE_ASM_WRITTEN as always zero for TYPE_DECLs, similar to
1283         all other types.
1284
1285 2011-12-15  Georg-Johann Lay  <avr@gjlay.de>
1286
1287         PR target/51050
1288         * config/avr/avr.c (expand_epilogue): Don't build SUBREG of fp.
1289         (avr_prologue_setup_frame): Ditto.
1290
1291 2011-12-15  Jakub Jelinek  <jakub@redhat.com>
1292
1293         PR debug/51517
1294         * tree-ssa-coalesce.c (coalesce_ssa_name): For !optimize, test
1295         !DECL_IGNORED_P instead of !DECL_ARTIFICIAL.
1296
1297 2012-12-15  Richard Guenther  <rguenther@suse.de>
1298
1299         Revert
1300         PR lto/48437
1301         * lto-streamer-out.c (tree_is_indexable): Exclude block-local
1302         extern declarations.
1303
1304         PR lto/48508
1305         PR lto/48437
1306         * tree-streamer-out.c (streamer_write_chain): Stream DECL_EXTERNAL
1307         VAR_DECLs and FUNCTION_DECLs locally.
1308
1309 2011-12-14  Richard Henderson  <rth@redhat.com>
1310
1311         * config/arm/arm.md (*addsi3_compare0_scratch): Set predicable.
1312         (*compare_negsi_si, *compare_addsi2_op0): Likewise.
1313         (*compare_addsi2_op1, *zeroextractsi_compare0_scratch): Likewise.
1314         (*compareqi_eq0, *arm_cmpsi_insn, *arm_cmpsi_negshiftsi_si): Likewise.
1315
1316 2011-12-14  Richard Guenther  <rguenther@suse.de>
1317
1318         * tree-cfg.c (replace_uses_by): Fixup TREE_CONSTANT for
1319         propagating all kinds of constants.
1320
1321 2011-12-14  Richard Guenther  <rguenther@suse.de>
1322
1323         PR lto/51497
1324         * lto-streamer-in.c (lto_read_body): Fixup local types
1325         TYPE_CANONICAL and variant chain.
1326
1327 2011-12-14  Richard Guenther  <rguenther@suse.de>
1328
1329         * tree.c (free_lang_data_in_type): Do not clear fields
1330         dependent on debuginfo level setting.
1331         (find_decls_types_r): Use TYPE_STUB_DECL rathern than TREE_CHAIN.
1332         * tree.h (TYPE_STUB_DECL): Properly check that we access a type.
1333
1334 2011-12-14  Georg-Johann Lay  <avr@gjlay.de>
1335
1336         PR target/50931
1337         * config/avr/avr.md (mulpsi3): New expander.
1338         (*umulqihipsi3, *umulhiqipsi3): New insns.
1339         (*mulsqipsi3.libgcc, *mulpsi3.libgcc): New insns.
1340         (mulsqipsi3, *mulpsi3): New insn-and-splits.
1341         (ashlpsi3): Turn to expander.  Move insn code to...
1342         (*ashlpsi3): ...this new insn.
1343
1344 2011-12-14  Richard Guenther  <rguenther@suse.de>
1345
1346         * tree-cfg.c (replace_uses_by): Only mark blocks altered
1347         that will make a difference.  Only recompute ADDR_EXPR
1348         invariantness if it could possibly have changed.  Do so
1349         before folding the statement.
1350
1351 2011-12-13  Eric Botcazou  <ebotcazou@adacore.com>
1352
1353         * lto-streamer-out.c (write_symbol): Use proper 64-bit host type.
1354         * lto-cgraph.c (input_cgraph_opt_section): Use 'int' for offsets.
1355         * lto-streamer-in.c (lto_read_body): Likewise.
1356         (lto_input_toplevel_asms): Likewise.
1357         * lto-section-in.c (lto_create_simple_input_block): Likewise.
1358         * ipa-inline-analysis.c (inline_read_section): Likewise.
1359         * ipa-prop.c (ipa_prop_read_section): Likewise.
1360
1361         * df.h (DF_NOTE): Fix typo in comment.
1362
1363 2011-12-13  Aldy Hernandez  <aldyh@redhat.com>
1364
1365         * trans-mem.c (ipa_tm_create_version_alias): Set DECL_CONTEXT and
1366         DECL_LANG_SPECIFIC.
1367
1368 2011-12-13  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
1369
1370         * regmove.c (fixup_match_2): Only access call_used_regs with hard regs.
1371
1372 2011-12-13  Andrew Pinski  <apinski@cavium.com>
1373             Adam Nemet  <anemet@caviumnetworks.com>
1374
1375         * config/mips/mips-cpus.def: Add Octeon2.
1376         * config/mips/mips-tables.opt: Regenerate.
1377         * config/mips/mips.md (define_attr "cpu"): Add Octeon2.
1378         * config/mips/driver-native.c (host_detect_local_cpu): Support Octeon2.
1379         * config/mips/octeon.md (octeon_arith): Add Octeon2.
1380         (octeon_condmove): Likewise.
1381         (octeon_load): Rename to ..
1382         (octeon_load_o1): this.
1383         (octeon_load_o2): New reserve.
1384         (octeon_cop_o2): New reserve.
1385         (octeon_store):  Match Octeon2 also.
1386         (octeon_brj): Rename to ..
1387         (octeon_brj_o1): this.
1388         (octeon_brj_o2): New reserve.
1389         (octeon_imul3): Rename to ...
1390         (octeon_imul3_o1): this.
1391         (octeon_imul3_o2): New reserve.
1392         (octeon_imul): Rename to ...
1393         (octeon_imul_o1): this.
1394         (octeon_imul_o2): New reserve.
1395         (octeon_mfhilo): Rename to ...
1396         (octeon_mfhilo_o1): This.
1397         (octeon_mfhilo_o2): New reserve.
1398         (octeon_imadd): Rename to ...
1399         (octeon_imadd_o1): this.
1400         (octeon_imadd_o2): New reserve.
1401         (octeon_idiv): Rename to ..
1402         (octeon_idiv_o1): This.
1403         (octeon_idiv_o2_si): New reserve.
1404         (octeon_idiv_o2_di): Likewise.
1405         (octeon_unknown): Match Octeon2 also.
1406         * config/mips/mips.c (mips_rtx_cost_data): Add Octeon2 cost data.
1407         (mips_issue_rate): Octeon2 can issue 2 at a time.
1408         * config/mips/mips.h (TARGET_OCTEON): Match Octeon2 also.
1409         (TARGET_OCTEON2): New define.
1410         (TUNE_OCTEON): Match Octeon2 also.
1411
1412 2011-12-13  Richard Henderson  <rth@redhat.com>
1413
1414         * config/sparc/tso.h: New file.
1415         * config.gcc (sparc-*-linux*, sparc*-*-solaris2*): Use it.
1416         * config/sparc/sparc.c (sparc_option_override): Honor
1417         SUBTARGET_DEFAULT_MEMORY_MODEL.
1418         * config/sparc/sparc.h (SUBTARGET_DEFAULT_MEMORY_MODEL): New.
1419
1420 2011-12-13  Aldy Hernandez  <aldyh@redhat.com>
1421
1422         PR middle-end/51443
1423         * trans-mem.c (struct diagnose_tm): Remove saw_unsafe.
1424         (diagnose_tm_1): Same.
1425         (ipa_tm_execute): Do not test tm_may_enter_irr before we set it.
1426         (ipa_tm_scan_irr_function): Return gracefully when no
1427         DECL_STRUCT_FUNCTION.
1428         (ipa_tm_scan_irr_block): Believe the user on TM attributes.
1429
1430 2011-12-13  Martin Jambor  <mjambor@suse.cz>
1431
1432         PR middle-end/50628
1433         * tree-sra.c (propagate_subaccesses_across_link): Do not propagate
1434         sub-accesses of scalar accesses.
1435
1436 2011-12-13  Martin Jambor  <mjambor@suse.cz>
1437
1438         PR tree-optimization/51362
1439         * ipa-cp.c (estimate_local_effects): When estimated size of a
1440         specialized clone is zero, bump it to one.
1441
1442 2011-12-13  Richard Guenther  <rguenther@suse.de>
1443
1444         PR lto/48354
1445         * tree.c (find_decls_types_r): Also walk DECL_ORIGINAL_TYPE.
1446         * tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
1447         Stream DECL_ORIGINAL_TYPE.
1448         * tree-streamer-out.c (write_ts_decl_non_common_tree_pointers):
1449         Likewise.
1450
1451 2011-12-13  Jakub Jelinek  <jakub@redhat.com>
1452
1453         Revert
1454         2011-12-12  Jakub Jelinek  <jakub@redhat.com>
1455
1456         PR tree-optimization/51481
1457         * gimple-fold.c (gimple_fold_call): Call
1458         maybe_clean_or_replace_eh_stmt.  Avoid optimization if stmt has EH
1459         edges, but gimple_fold_builtin result can't throw.
1460
1461 2011-12-13  Jakub Jelinek  <jakub@redhat.com>
1462             Michael Matz  <matz@suse.de>
1463
1464         PR tree-optimization/51117
1465         * tree-eh.c (sink_clobbers): New function.
1466         (execute_lower_eh_dispatch): Call it for BBs ending with
1467         internally throwing RESX.
1468         * cfgexpand.c (add_scope_conflicts_1): Add all conflicts only
1469         at the first real instruction.
1470
1471 2011-12-13  Tristan Gingold  <gingold@adacore.com>
1472
1473         * final.c (final_scan_insn): Guard the call to begin_epilogue
1474         debug hook.
1475
1476 2011-12-13  Tristan Gingold  <gingold@adacore.com>
1477
1478         * vmsdbgout.c (vmsdbgout_write_source_line): New function.
1479         (vmsdbgout_end_prologue): Call vmsdbgout_write_source_line.
1480         (vmsdbgout_begin_epilogue): Likewise.
1481         (vmsdbgout_end_epilogue): Likewise.
1482         (vmsdbgout_source_line): Move code to vmsdbgout_write_source_line.
1483
1484 2011-12-13  Richard Guenther  <rguenther@suse.de>
1485
1486         PR middle-end/51481
1487         * tree-cfg.c (replace_uses_by): Pass proper arguments to
1488         maybe_clean_or_replace_eh_stmt.
1489
1490 2011-12-13  Richard Guenther  <rguenther@suse.de>
1491
1492         PR tree-optimization/51519
1493         * ipa-inline.c (edge_badness): Use edge growth in non-guessed
1494         branch probability case as well.
1495
1496 2011-12-13  Revital Eres  <revital.eres@linaro.org>
1497
1498         * modulo-sched.c (mark_loop_unsched): Free bbs.
1499
1500 2011-12-12  Jakub Jelinek  <jakub@redhat.com>
1501
1502         PR rtl-optimization/51495
1503         * function.c (thread_prologue_and_epilogue_insns): Don't add
1504         to bb_tail basic blocks that have EDGE_COMPLEX predecessor edges
1505         from basic blocks not needing prologue.
1506
1507         PR tree-optimization/51481
1508         * gimple-fold.c (gimple_fold_call): Call
1509         maybe_clean_or_replace_eh_stmt.  Avoid optimization if stmt has EH
1510         edges, but gimple_fold_builtin result can't throw.
1511
1512 2011-12-12  Vladimir Makarov  <vmakarov@redhat.com>
1513
1514         PR rtl-optimization/21617
1515         * ira-color.c (bucket_allocno_compare_func): Don't compare
1516         allocno classes.  Compare number of hard registers needed.
1517
1518 2011-12-12  Eric Botcazou  <ebotcazou@adacore.com>
1519
1520         PR tree-optimization/50569
1521         * tree-sra.c (build_ref_for_model): Replicate a chain of COMPONENT_REFs
1522         in the expression of MODEL instead of just the last one.
1523
1524 2011-12-12  Jakub Jelinek  <jakub@redhat.com>
1525
1526         PR middle-end/51510
1527         * calls.c (internal_arg_pointer_based_exp_scan): Don't use
1528         VEC_safe_grow_cleared if idx is smaller than VEC_length.
1529
1530 2011-12-12  Richard Sandiford  <richard.sandiford@linaro.org>
1531
1532         PR middle-end/50873
1533         * optabs.c (maybe_legitimize_operand_same_code): Use copy_to_mode_reg
1534         instead of force_reg.  Do nothing if the address is already a
1535         non-virtual pseudo register.
1536
1537 2011-12-12  Torvald Riegel  <triegel@redhat.com>
1538
1539         * gimplify.c (voidify_wrapper_expr): Add default handling for
1540         outermost wrapper.
1541
1542 2011-12-12  Torvald Riegel  <triegel@redhat.com>
1543
1544         * tree-ssa-tail-merge.c (gimple_equal_p): Don't treat transaction
1545         commits as equal.
1546
1547 2011-12-12  Iain Sandoe  <iains@gcc.gnu.org>
1548
1549         * config/darwin-sections.def (zobj_const_data_section): Fix over-
1550         length section name.
1551
1552 2011-12-11  Richard Henderson  <rth@redhat.com>
1553
1554         * config/rs6000/rs6000.c (rs6000_expand_interleave): Use
1555         BYTES_BIG_ENDIAN, not TARGET_BIG_ENDIAN.
1556
1557 2011-12-11  Jakub Jelinek  <jakub@redhat.com>
1558
1559         PR tree-optimization/51485
1560         * tree-vect-data-refs.c (vect_analyze_data_refs): Give up on
1561         DRs in call stmts.
1562
1563 2011-12-11  Patrick Marlier  <patrick.marlier@gmail.com>
1564
1565         * trans-mem.c (ipa_tm_transform_calls_redirect): Do not remove edge.
1566
1567 2011-12-10  Richard Henderson  <rth@redhat.com>
1568
1569         * config/rs6000/altivec.md (altivec_vmrghb): Rewrite pattern as
1570         vec_select + vec_concat.
1571         (altivec_vmrghh, altivec_vmrghw, altivec_vmrghsf, altivec_vmrglb,
1572         altivec_vmrglh, altivec_vmrglw, altivec_vmrglsf): Likewise.
1573         (vec_perm_constv16qi): New.
1574         (vec_extract_evenv4si, vec_extract_evenv4sf, vpkuhum_nomode,
1575         vpkuwum_nomode, vec_extract_oddv8hi, vec_extract_oddv16qi,
1576         vec_interleave_high<VI>, vec_interleave_low<VI>): Remove.
1577         * config/rs6000/paired.md (paired_merge00): Rewrite pattern as
1578         vec_select + vec_concat.
1579         (paired_merge10, paired_merge01, paired_merge11): Likewise.
1580         (vec_perm_constv2sf): New.
1581         (vec_interleave_highv2sf, vec_interleave_lowv2sf,
1582         vec_extract_evenv2sf, vec_extract_oddv2sf): Remove.
1583         * config/rs6000/spe.md (spe_evmergehi): Rewrite pattern as
1584         vec_select + vec_concat.
1585         (spe_evmergehilo, spe_evmergelo, spe_evmergelohi): New.
1586         (vec_perm_constv2si): New.
1587         * config/rs6000/vector.md (vec_interleave_highv4sf,
1588         vec_interleave_lowv4sf, vec_interleave_high<VEC_64>,
1589         vec_interleave_low<VEC_64>): Remove.
1590         * config/rs6000/vsx.md (VS_double): New mode attribute.
1591         (UNSPEC_VSX_XXPERMDI): Remove.
1592         (vsx_xxpermdi_<VSX_L>_1): Rewrite pattern as vec_select + vec_concat.
1593         (vsx_xxmrghw_<VSX_W>, vsx_xxmrglw_<VSX_W>): Likewise.
1594         (vsx_xxpermdi_<VSX_L>): Change to expander.
1595         (vec_perm_const<VSX_D>): New.
1596         (vsx_mergel_<VSX_D>, vsx_mergeh_<VSX_D>): New.
1597         * config/rs6000/predicates.md (const_0_to_1_operand): New.
1598         (const_2_to_3_operand): New.
1599         * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): New.
1600         (altivec_expand_vec_perm_const): New.
1601         (rs6000_expand_vec_perm_const_1, rs6000_expand_vec_perm_const): New.
1602         (rs6000_vectorize_vec_perm_const_ok): New.
1603         (rs6000_do_expand_vec_perm): New.
1604         (rs6000_expand_extract_even, rs6000_expand_interleave): New.
1605         * config/rs6000/rs6000-builtin.def (VEC_MERGE*): Update rtx codes.
1606         * config/rs6000/rs6000-modes.def: Add double-wide vector modes.
1607         * config/rs6000/rs6000-protos.h: Update.
1608
1609 2011-12-10  Richard Henderson  <rth@redhat.com>
1610
1611         * expr.c (expand_expr_real_2) [VEC_PERM_EXPR]: Avoid passing a
1612         CONST_INT to expand_vec_perm as the selector.
1613         * optabs.c (expand_vec_perm): Assert the selector is of a proper mode.
1614
1615 2011-12-10  Richard Henderson  <rth@redhat.com>
1616
1617         * genmodes.c (struct mode_data): Remove wider_2x member.
1618         (blank_mode): Adjust initializer.
1619         (calc_wider_mode): Use XALLOCAVEC.
1620         (emit_move_wider): Select double-width same-element vectors for
1621         2xwider vectors.
1622         * machmode.h (GET_MODE_2XWIDER_MODE): Update documentation.
1623         * config/i386/i386.c (doublesize_vector_mode): Remove.
1624         (expand_vselect_vconcat): Use GET_MODE_2XWIDER_MODE instead.
1625
1626 2011-12-10  Joern Rennecke  <joern.rennecke@embecosm.com>
1627
1628         * config/epiphany/epiphany.h (USE_LOAD_POST_INCREMENT): Define.
1629         (USE_LOAD_POST_DECREMENT, USE_STORE_POST_INCREMENT): Likewise.
1630         (USE_STORE_POST_DECREMENT): Likewise.
1631
1632         * config/epiphany/epiphany.h (EPIPHANY_RETURN_REGNO): New macro,
1633         broken out of ..
1634         (INCOMING_RETURN_ADDR_RTX) .. this.  Use EPIPHANY_RETURN_REGNO.
1635         (DWARF_FRAME_RETURN_COLUMN): New macro.
1636
1637         * config/epiphany/epiphany-protos.h (epiphany_start_function): Declare.
1638         * config/epiphany/epiphany.c (epiphany_handle_interrupt_attribute):
1639         Split "timer" value into "timer0" and "timer1".
1640         Handle page_miss, message and wand.  Don't handle static_flag.
1641         Adjust warning text.
1642         (epiphany_start_function): New function.
1643         (epiphany_compute_function_type): Split "timer" value into "timer0"
1644         and "timer1".  Handle page_miss, message and wand.
1645         Don't handle static_flag.
1646         (epiphany_expand_epilogue): Don't use frame_insn for status / iret
1647         restore.
1648         * config/epiphany/epiphany.h: ASM_DECLARE_FUNCTION_NAME: Define.
1649         (enum epiphany_function_type):
1650         Split EPIPHANY_FUNCTION_TIMER value into EPIPHANY_FUNCTION_TIMER0
1651         and EPIPHANY_FUNCTION_TIMER1.
1652         Remove EPIPHANY_FUNCTION_ILINK1 and EPIPHANY_FUNCTION_ILINK2 values.
1653         Add EPIPHANY_FUNCTION_PAGE_MISS and EPIPHANY_FUNCTION_MESSAGE values.
1654         Rename EPIPHANY_FUNCTION_STATIC_FLAG to EPIPHANY_FUNCTION_WAND.
1655
1656 2011-12-10  Nathan Sidwell  <nathan@acm.org>
1657
1658         PR gcov-profile/51449
1659         * coverage.c (coverage_end_function): Always process the coverage
1660         variables.
1661
1662 2011-12-09  Aldy Hernandez  <aldyh@redhat.com>
1663
1664         PR/51291
1665         * tree.c (build_common_builtin_nodes): Do not use TM_PURE
1666         attribute unless language has support for TM.
1667         * config/i386/i386.c (ix86_init_tm_builtins): Exit gracefully in
1668         the absence of TM builtins.
1669
1670 2011-12-09  Eric Botcazou  <ebotcazou@adacore.com>
1671
1672         * gimple-fold.c (gimple_fold_stmt_to_constant_1) <GIMPLE_UNARY_RHS>:
1673         Also check the TYPE_MODE to recognize useless pointer conversions.
1674
1675 2011-12-09  Jakub Jelinek  <jakub@redhat.com>
1676
1677         PR tree-optimization/51117
1678         * tree-eh.c (optimize_clobbers): Don't remove just one
1679         clobber, but all consecutive clobbers before RESX.
1680         Use gimple_clobber_p predicate.
1681
1682 2011-12-09  Michael Meissner  <meissner@linux.vnet.ibm.com>
1683
1684         * config/rs6000/rs6000.c (altivec_expand_builtin): Call
1685         expand_call to return a valid funciton instead of return
1686         cosnt0_rtx/NULL_RTX if there was an error with the builtin.
1687         (altivec_expand_ld_builtin): Ditto.
1688         (rs6000_inner_target_options): If VSX is selected as a target
1689         attribute or pragma, enable ALTIVEC also.
1690         (rs6000_pragma_target_parse): Call rs6000_option_override_internal
1691         to do all of the standard processing when switching options,
1692         including redefining appropriate macros.
1693
1694         PR rtl-optimization/51469
1695         * varasm.c (default_binds_local_p_1): If the symbol is a gnu
1696         indirect function, mark the symbol as non-local.
1697
1698 2011-12-09  H.J. Lu  <hongjiu.lu@intel.com>
1699
1700         PR bootstrap/51479
1701         * Makefile.in (errors.o): Restored.
1702
1703 2011-12-09  Richard Guenther  <rguenther@suse.de>
1704
1705         PR lto/48042
1706         * tree.c (free_lang_data_in_decl): Remove freeing conditional
1707         on debuginfo level.
1708
1709 2011-12-09  Joern Rennecke  <joern.rennecke@embecosm.com>
1710
1711         PR middle-end/40154
1712         * emit-rtl.c (set_dst_reg_note): New function.
1713         * rtl.h (set_dst_reg_note): Declare.
1714         * optabs.c (expand_binop, expand_absneg_bit): Use set_dst_reg_note.
1715         (emit_libcall_block, expand_fix): Likewise.
1716         * function.c (assign_parm_setup_reg, expand_function_start): Likewise.
1717         * expmed.c (expand_mult_const, expand_divmod): Likewise.
1718         * reload1.c (gen_reload): Likewise.
1719
1720         * dse.c (get_stored_val, get_call_args): Use gen_int_mode.
1721         * expmed.c (expand_divmod): Likewise.
1722         * combine.c (simplify_if_then_else): Likewise.
1723
1724 2011-12-09  Kai Tietz  <ktietz@redhat.com>
1725
1726         * ira-color.c (print_hard_regs_subforest): Use
1727         HOST_WIDEST_INT_PRINT_DEC instead of %lld.
1728         (allocno_hard_regs): Change type of cost member to HOST_WIDEST_INT.
1729         (add_allocno_hard_regs): Change type of argument cost
1730         to HOST_WIDEST_INT.
1731         * ira-conflict.c (build_conflict_bit_table): Replace use
1732         of long-long by HOST_WIDEST_INT.
1733
1734 2011-12-09  Georg-Johann Lay  <avr@gjlay.de>
1735
1736         PR target/51425
1737         * config/avr/avr.md (config/avr/avr.md, *sbix_branch_tmp): Use
1738         zero_extract:QIHI instead of zero_extract:HI.
1739
1740 2011-12-09  Jakub Jelinek  <jakub@redhat.com>
1741             Andrew Pinski  <apinski@cavium.com>
1742
1743         PR tree-optimization/51117
1744         * tree-eh.c (optimize_clobbers): New function.
1745         (execute_lower_eh_dispatch): Call it.
1746
1747 2011-12-09  Richard Guenther  <rguenther@suse.de>
1748
1749         PR tree-optimization/51482
1750         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size):
1751         Make sure to only create REAL_TYPE and INTEGER_TYPE component vectors.
1752
1753 2011-12-09  Kai Tietz  <ktietz@redhat.com>
1754
1755         * implicit-zee.c (num_realized): Change type to long.
1756         (num_ze_opportunities): Likewise.
1757
1758 2011-12-08  Andrew Pinski  <apinski@cavium.com>
1759
1760         * config/mips/mips-cpus.def (octeon+): New CPU.
1761         * config/mips/mips-tables.opt: Regenerate.
1762         * config/mips/mips.h (MIPS_CPP_SET_PROCESSOR): Emit '+' as 'P'.
1763
1764 2011-12-08  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
1765
1766         PR middle-end/39976
1767         * tree-ssa-dom.c (enum expr_kind): Add EXPR_PHI.
1768         (struct hashable_expr): Add struct phi field.
1769         (initialize_hash_element): Handle phis; change to use XCNEWVEC.
1770         (hashable_expr_equal_p): Handle phis.
1771         (iterative_hash_hashable_expr): Likewise.
1772         (print_expr_hash_elt): Likewise.
1773         (free_expr_hash_elt): Likewise.
1774         (dom_opt_enter_block): Create equivalences from redundant phis.
1775         (eliminate_redundant_computations): Handle redundant phis.
1776         (lookup_avail_expr): Handle phis.
1777
1778 2011-12-08  Jakub Jelinek  <jakub@redhat.com>
1779
1780         PR tree-optimization/51466
1781         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Also copy
1782         TREE_SIDE_EFFECTS.
1783
1784 2011-12-08  Richard Guenther  <rguenther@suse.de>
1785
1786         * tree-ssa-operands.c (add_stmt_operand): Do not mark stmts
1787         volatile when processing operands of an ADDR_EXPR.
1788         (get_indirect_ref_operands): Likewise.
1789         (get_tmr_operands): Likewise.
1790         (get_expr_operands): Likewise.
1791
1792 2011-12-08  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
1793
1794         PR target/50395
1795         * config/s390/s390.c (s390_mainpool_finish): Emit the jump over
1796         the literal pool as jump insn.
1797
1798 2011-12-08  Richard Guenther  <rguenther@suse.de>
1799
1800         PR tree-optimization/49772
1801         * tree-inline.c (optimize_inline_calls): Remove bail out on errors.
1802
1803 2011-12-08  Richard Guenther  <rguenther@suse.de>
1804
1805         PR lto/50747
1806         * lto-streamer-out.c (produce_symtab): Remove asserts.
1807
1808 2011-12-08  Richard Guenther  <rguenther@suse.de>
1809
1810         PR lto/49945
1811         * lto-streamer-out.c (tree_is_indexable): Localize variably
1812         modified types and their FIELD_DECLs.
1813
1814 2011-12-08  Eric Botcazou  <ebotcazou@adacore.com>
1815
1816         PR tree-optimization/51315
1817         * tree.h (get_object_or_type_alignment): Declare.
1818         * expr.c (get_object_or_type_alignment): Move to...
1819         * builtins.c (get_object_or_type_alignment): ...here.  Add assertion.
1820         * tree-sra.c (tree_non_mode_aligned_mem_p): Rename to...
1821         (tree_non_aligned_mem_p): ...this.  Add ALIGN parameter.  Look into
1822         MEM_REFs and use get_object_or_type_alignment for them.
1823         (build_accesses_from_assign): Adjust for above change.
1824         (access_precludes_ipa_sra_p): Likewise.
1825
1826 2011-12-08  Richard Guenther  <rguenther@suse.de>
1827
1828         PR lto/48437
1829         * lto-streamer-out.c (tree_is_indexable): Exclude block-local
1830         extern declarations.
1831
1832 2011-12-07  Andrew Pinski  <apinski@cavium.com>
1833
1834         PR middle-end/45416
1835         * expr.c (do_store_flag): Rewrite code that looks for BIT_AND_EXPR for
1836         SSA-expand.
1837
1838 2011-12-07  Richard Guenther  <rguenther@suse.de>
1839
1840         PR tree-optimization/50823
1841         * ipa-inline.c (edge_badness): Do not account for the number of
1842         remaining calls.
1843
1844 2011-12-07  Martin Jambor  <mjambor@suse.cz>
1845
1846         PR tree-optimization/50744
1847         * ipa-cp.c (good_cloning_opportunity_p): Assert size_cost is positive,
1848         compute evaluation in HOST_WIDEST_INT.
1849         (safe_add): New function
1850         (propagate_effects): Use safe_add to accumulate effects.
1851
1852 2011-12-06  Joel Sherrill <joel.sherrill@oarcorp.com>
1853
1854         * config/rs6000/rtems.h: Switch to using global_options_set
1855         in SUBSUBTARGET_OVERRIDE_OPTIONS.
1856
1857 2011-12-06  David S. Miller  <davem@davemloft.net>
1858
1859         * config/sparc/visintrin.h: Add appropriate __VIS__ cpp protection.
1860
1861 2011-12-06  Georg-Johann Lay  <avr@gjlay.de>
1862
1863         * config/avr/avr.c (avr_file_start): Fix missing ,
1864
1865 2011-12-06  Jakub Jelinek  <jakub@redhat.com>
1866
1867         PR target/51354
1868         * config/i386/i386.c (ix86_emit_leave): Call ix86_add_cfa_restore_note
1869         unconditionally.
1870
1871 2011-12-06  Georg-Johann Lay  <avr@gjlay.de>
1872
1873         Forward-port from gcc-4_6-branch r181936 2011-12-02.
1874         * config/avr/avr-mcus.def (avr_mcu_types): ATtiny4313 and
1875         AT86RF401 have a 16-bit SP (their manual is bogus).
1876
1877 2011-12-06  Georg-Johann Lay  <avr@gjlay.de>
1878
1879         Forward-port from gcc-4_6-branch r181936 2011-12-02.
1880
1881         PR target/51002
1882         * config/avr/avr.md (movhi_sp_r): Set insn condition to
1883         !AVR_HAVE_8BIT_SP.
1884         * config/avr/avr.c (output_movhi): Use "clr%B0" instead of "in
1885         %B0,__SP_H__" if AVR_HAVE_8BIT_SP.
1886         (avr_file_start): Only print "__SP_H__ = 0x3e" if !AVR_HAVE_8BIT_SP.
1887
1888 2011-12-06  Georg-Johann Lay  <avr@gjlay.de>
1889
1890         PR target/51409
1891         PR target/49868
1892         * config/avr/avr.h (ADDR_SPACE_PGM, ADDR_SPACE_PGM1,
1893         ADDR_SPACE_PGM2, ADDR_SPACE_PGM3, ADDR_SPACE_PGM4,
1894         ADDR_SPACE_PGM5, ADDR_SPACE_PGMX): Write as enum.
1895         (avr_addrspace_t): New typedef.
1896         (avr_addrspace): New declaration.
1897         * config/avr/avr-c.c (avr_toupper): New static function.
1898         (avr_register_target_pragmas, avr_cpu_cpp_builtins): Use
1899         avr_addrspace to get address space information.
1900         * config/avr/avr.c (avr_addrspace): New variable.
1901         (avr_out_lpm, avr_pgm_check_var_decl, avr_insert_attributes,
1902         avr_asm_named_section, avr_section_type_flags,
1903         avr_asm_select_section, avr_addr_space_address_mode,
1904         avr_addr_space_convert, avr_emit_movmemhi): Use it.
1905         (avr_addr_space_pointer_mode): Forward to avr_addr_space_address_mode.
1906         (avr_pgm_segment): Remove.
1907
1908 2011-12-06  Richard Guenther  <rguenther@suse.de>
1909
1910         PR middle-end/50601
1911         * varasm.c (assemble_alias): Move DECL_EXTERNAL implementation
1912         quirk adjustjment ...
1913         * passes.c (rest_of_decl_compilation): ... here.
1914
1915 2011-12-06  Richard Guenther  <rguenther@suse.de>
1916
1917         PR middle-end/51436
1918         * gimple-fold.c (gimplify_and_update_call_from_tree): Guard vdef check
1919         for the fact we do not have virtual operands when not optimizing.
1920
1921 2011-12-06  Richard Guenther  <rguenther@suse.de>
1922
1923         PR tree-optimization/51245
1924         * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_constant_for_pieces):
1925         New function.
1926         (vn_reference_lookup_3): Use it.  Properly valueize all refs we create.
1927
1928 2011-12-06  Iain Sandoe  <iains@gcc.gnu.org>
1929
1930         * config/rs6000/rs6000.c (darwin_rs6000_override_options): Initialize
1931         rs6000_current_abi.
1932
1933 2011-12-06  Richard Guenther  <rguenther@suse.de>
1934
1935         PR tree-optimization/51363
1936         * gimple.c (gimple_rhs_has_side_effects): Remove.
1937         * gimple.h (gimple_rhs_has_side_effects): Likewise.
1938         * tree-ssa-dom.c (optimize_stmt): Simplify conditional.
1939
1940 2011-12-06  Alan Modra  <amodra@gmail.com>
1941
1942         PR target/50906
1943         * config/rs6000/rs6000.c (rs6000_emit_prologue <TARGET_SPE_ABI>):
1944         Do not mark r11 setup as frame-related.  Pass correct offset to
1945         rs6000_emit_savres_rtx.  Correct out-of-line rs6000_frame_related
1946         arguments.  Correct sp_offset.  Remove "offset" fudge from
1947         in-line rs6000_frame_related call.  Rename misleading variable.
1948         Fix comments and whitespace.  Tidy some expressions.
1949         (rs6000_emit_epilogue <TARGET_SPE_ABI>): Always set frame_reg_rtx
1950         to r11 in out-of-line case.  Correct sp_offset.  Pass correct
1951         offset to rs6000_emit_savres_rtx.  Rename misleading variable.
1952         Fix comments and whitespace.  Tidy some expressions.
1953         (rs6000_emit_epilogue <non-TARGET_SPE_ABI>): Add sp_offset
1954         adjustment when !saving_GPRs_inline.  Correct register mode
1955         used in address calcs.
1956         (rs6000_emit_epilogue <non-TARGET_SPE_ABI>): Similarly when
1957         !restoring_GPRs_inline.
1958
1959 2011-12-06  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
1960
1961         * config/arm/vfp.md (*combine_vcvt_f64_<FCVTI32typename>): Fix
1962         formatting character for vmov.f64 case.
1963
1964 2011-12-05  Jakub Jelinek  <jakub@redhat.com>
1965
1966         PR tree-optimization/51396
1967         * tree-ssa-math-opts.c (convert_mult_to_fma): Don't optimize
1968         if MUL_RESULT has zero uses.
1969
1970         PR debug/51410
1971         * c-decl.c (pop_scope): Don't add DECL_EXTERNAL decls
1972         for debug info if scope is file_scope.
1973
1974         PR c/51339
1975         * c-decl.c (c_finish_incomplete_decl, finish_decl): Call
1976         relayout_decl instead of layout_decl.
1977
1978 2011-12-05  Richard Sandiford  <rdsandiford@googlemail.com>
1979
1980         * resource.c (init_resource_info): Only consider EXIT_IGNORE_STACK
1981         if there is in epilogue.
1982
1983 2011-12-05  Richard Sandiford  <rdsandiford@googlemail.com>
1984
1985         * optabs.c (maybe_emit_sync_lock_test_and_set): Pass a null target
1986         to emit_library_call_value.
1987         (expand_atomic_compare_and_swap): Likewise.
1988
1989 2011-12-05  Vladimir Makarov  <vmakarov@redhat.com>
1990
1991         PR other/50775
1992         * ira-int.h (struct ira_object): Remove add_data.
1993         (OBJECT_ADD_DATA): Remove.
1994
1995         * ira-build.c (ira_create_object): Remove OBJECT_ADD_DATA
1996         initialization.
1997
1998         * ira-color.c (object_hard_regs_t, object_hard_regs): Rename to
1999         allocno_hard_regs_t, allocno_hard_regs.
2000         (object_hard_regs_node_t, object_hard_regs_node): Rename to
2001         allocno_hard_regs_node_t and allocno_hard_regs_node.
2002         (struct allocno_color_data): Add new member last_process.  Move
2003         profitable_hard_regs, hard_regs_node, and hard_regs_subnodes_start
2004         from object_color_data.
2005         (object_color_data_t, object_color_data, OBJECT_COLOR_DATA): Remove.
2006         (curr_allocno_process): New static variable.
2007         (object_hard_regs_eq, object_hard_regs_htab): Rename to
2008         allocno_hard_regs_eq and allocno_hard_regs_htab.
2009         (init_object_hard_regs, finish_object_hard_regs): Rename to
2010         init_allocno_hard_regs and finish_allocno_hard_regs.
2011         (object_hard_regs_compare, object_hard_regs_node_t): Rename to
2012         allocno_hard_regs_compare and allocno_hard_regs_node_t.
2013         (create_new_object_hard_regs_node): Rename to
2014         create_new_allocno_hard_regs_node.
2015         (add_new_object_hard_regs_node_to_forest): Rename to
2016         add_new_allocno_hard_regs_node_to_forest.
2017         (add_object_hard_regs_to_forest, collect_object_hard_regs_cover):
2018         Rename to add_allocno_hard_regs_to_forest and
2019         collect_allocno_hard_regs_cover.
2020         (setup_object_hard_regs_nodes_parent): Rename to
2021         setup_allocno_hard_regs_nodes_parent.
2022         (remove_unused_object_hard_regs_nodes): Rename to
2023         remove_unused_allocno_hard_regs_nodes.
2024         (enumerate_object_hard_regs_nodes, object_hard_regs_nodes_num):
2025         Rename to enumerate_allocno_hard_regs_nodes and
2026         allocno_hard_regs_nodes_num.
2027         (object_hard_regs_nodes, object_hard_regs_subnode_t): Rename to
2028         allocno_hard_regs_nodes and allocno_hard_regs_subnode_t.
2029         (object_hard_regs_subnode, object_hard_regs_subnodes): Rename to
2030         allocno_hard_regs_subnode and allocno_hard_regs_subnodes.
2031         (object_hard_regs_subnode_index): Rename to
2032         allocno_hard_regs_subnode_index.
2033         (setup_object_hard_regs_subnode_index): Rename to
2034         setup_allocno_hard_regs_subnode_index.
2035         (get_object_hard_regs_subnodes_num): Rename to
2036         get_allocno_hard_regs_subnodes_num.
2037         (form_object_hard_regs_nodes_forest): Rename to
2038         form_allocno_hard_regs_nodes_forest.
2039         (finish_object_hard_regs_nodes_tree): Rename to
2040         form_allocno_hard_regs_nodes_forest
2041         (finish_object_hard_regs_nodes_forest): Rename to
2042         finish_allocno_hard_regs_nodes_forest.
2043         (setup_left_conflict_sizes_p): Use allocno data instead of object ones.
2044         Process conflict allocnos once.
2045         (update_left_conflict_sizes_p): Use allocno data instead of object
2046         ones.  Change prototype signature.
2047         (empty_profitable_hard_regs): Use allocno data instead of object ones.
2048         (setup_profitable_hard_regs): Ditto.
2049         (get_conflict_profitable_regs): Rename to
2050         get_conflict_and_start_profitable_regs.  Use allocno data for
2051         profitable regs calculation.
2052         (check_hard_reg_p): Change prototype signature.  Check profitable
2053         regs for allocno not the objects.
2054         (assign_hard_reg): Process conflict allocnos only once for
2055         updating conflict costs.
2056         (setup_allocno_available_regs_num): Use allocno data instead of
2057         object ones.  Modify debug output.
2058         (color_pass): Remove initialization and finalization of object
2059         color data.
2060
2061 2011-12-05  Kazu Hirata  <kazu@codesourcery.com>
2062
2063         PR target/51408
2064         * config/arm/arm.md (*minmax_arithsi): Always require the else
2065         clause in the MINUS case.
2066
2067 2011-12-05  Richard Guenther  <rguenther@suse.de>
2068
2069         PR tree-optimization/50904
2070         * tree-ssa-loop-im.c (struct mem_ref): Remove vops member.
2071         (MEM_ANALYZABLE): New.
2072         (memory_references): Remove clobbered_vops and vop_ref_map
2073         members, add all_refs_stored_in_loop member.
2074         (memref_free): Adjust.
2075         (mem_ref_alloc): Likewise.
2076         (gather_mem_refs_stmt): Do not record clobbers, instead
2077         record refs for unanalyzable stmts.
2078         (gather_mem_refs_in_loops): Do not propagate clobbers.
2079         (struct vop_to_refs_elt, vtoe_hash, vtoe_eq, vtoe_free,
2080         record_vop_access, get_vop_accesses, get_vop_stores,
2081         add_vop_ref_mapping): Remove.
2082         (create_vop_ref_mapping_loop): Adjust to simply record all stores.
2083         (analyze_memory_references): Adjust.
2084         (refs_independent_p): Check for not analyzable refs.
2085         (can_sm_ref_p): Likewise.
2086         (ref_indep_loop_p_1): Simplify.
2087         (tree_ssa_lim_finalize): Adjust.
2088
2089         * tree-ssa-loop-im.c (stmt_cost): Simplify, use LIM_EXPENSIVE
2090         rather than magic constants.  Assign zero cost to PAREN_EXPR
2091         and SSA_NAME copies.  Assign cost proportional to the vector
2092         size for vector constructors.
2093
2094 2011-12-05  Richard Guenther  <rguenther@suse.de>
2095
2096         * tree-ssa-alias.h (struct ao_ref_s): Add volatile_p field.
2097         * tree-ssa-alias.c (ao_ref_init): Initialize it.
2098         (ao_ref_init_from_ptr_and_size): Likewise.
2099         (refs_may_alias_p_1): Two volatile accesses conflict.
2100         (ref_maybe_used_by_call_p_1): Likewise.
2101         (call_may_clobber_ref_p_1): Likewise.
2102         * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): Initialize
2103         volatile_p field.
2104
2105 2011-12-05  Richard Guenther  <rguenther@suse.de>
2106
2107         * tree-ssa.c (verify_ssa): Verify SSA names in the loop over all SSA
2108         names.  Remove SSA operand checking, call verify_ssa_operands.
2109         * tree-ssa-operands.h (verify_ssa_operands): Declare.
2110         * tree-ssa-operands.c (verify_ssa_operands): New function.
2111
2112 2011-12-05  Ramana Radhakrishnan  <ramana.radhakrishnan@linaro.org>
2113
2114         * config/arm/arm.c (vfp3_const_double_for_fract_bits): Define.
2115         * config/arm/arm-protos.h (vfp3_const_double_for_fract_bits): Declare.
2116         * config/arm/constraints.md ("Dt"): New constraint.
2117         * config/arm/predicates.md
2118         (const_double_vcvt_power_of_two_reciprocal): New.
2119         * config/arm/vfp.md (FCVTI32typename): New.
2120         (FCVT): New iterator.
2121         (*combine_vcvt_f32_<FCVTI32typename>): New.
2122         (*combine_vcvt_f64_<FCVTI32typename>): New.
2123
2124 2011-12-05  Richard Guenther  <rguenther@suse.de>
2125
2126         * cgraph.c (cgraph_create_edge_1): Initialize
2127         call_stmt_cannot_inline_p from the stmt if possible.
2128         (cgraph_make_edge_direct): Likewise.
2129         * gimple-streamer-in.c (input_gimple_stmt): Do not
2130         call gimple_call_set_cannot_inline.
2131         * gimple.h (enum gf_mask): Remove GF_CALL_CANNOT_INLINE, shift values.
2132         (gimple_call_set_cannot_inline): Remove.
2133         (gimple_call_cannot_inline_p): Likewise.
2134         * ipa-inline-analysis.c (initialize_inline_failed): Look
2135         at the edge call_stmt_cannot_inline_p flag.
2136         * ipa-inline.c (can_inline_edge_p): Likewise.
2137         (early_inliner): Only update the edge flag.
2138         * ipa-prop.c (update_indirect_edges_after_inlining): Likewise.
2139         (ipa_modify_call_arguments): Do not call gimple_call_set_cannot_inline.
2140         * cgraphunit.c (assemble_thunk): Likewise.
2141         * gimple-fold.c (gimple_fold_call): Likewise.
2142
2143         * tree.h (CALL_CANNOT_INLINE_P): Remove.
2144         * tree-mudflap.c (mf_xform_statements): Do not modify alloca calls.
2145         * builtins.c (expand_builtin_alloca): With -fmudflap do not expand
2146         alloca calls inline.
2147         * cfgexpand.c (expand_call_stmt): Do not set CALL_CANNOT_INLINE_P.
2148         * gimple.c (gimple_build_call_from_tree): Do not read
2149         CALL_CANNOT_INLINE_P.
2150         * gimplify.c (gimplify_call_expr): Do not copy CALL_CANNOT_INLINE_P.
2151
2152 2011-12-05  Jakub Jelinek  <jakub@redhat.com>
2153             Eric Botcazou  <ebotcazou@adacore.com>
2154
2155         PR middle-end/51323
2156         PR middle-end/50074
2157         * calls.c (internal_arg_pointer_exp_state): New variable.
2158         (internal_arg_pointer_based_exp_1,
2159         internal_arg_pointer_exp_scan): New functions.
2160         (internal_arg_pointer_based_exp): New function.
2161         (mem_overlaps_already_clobbered_arg_p): Use it.
2162         (expand_call): Free internal_arg_pointer_exp_state.cache vector
2163         and clear internal_arg_pointer_exp_state.scan_start.
2164
2165 2011-12-04  Kaz Kojima  <kkojima@gcc.gnu.org>
2166
2167         * config/sh/linux.h (TARGET_DEFAULT): Add MASK_SOFT_ATOMIC.
2168         * config/sh/sync.md: New file.
2169         * config/sh/sh.md: Include sync.md.
2170         * config/sh/sh.opt (msoft-atomic): New option.
2171         * doc/invoke.texi (SH Options): Document it.
2172
2173 2011-12-04  Nathan Sidwell  <nathan@acm.org>
2174
2175         * gcov-io.h (struct gcov_info): Replace trailing array with
2176         pointer to array.
2177         * profile.c (branch_prob): Only call renamed
2178         coverage_begin_function once.
2179         * coverage.h (coverage_begin_output): Rename to ...
2180         (coverage_begin_function): ... here.
2181         * coverage.c (struct function_list): Rename to ...
2182         (struct coverage_data): ... this.  Update all uses.
2183         (gcov_info_var, gcov_fn_info_type, gcov_fn_info_ptr_type): New globals.
2184         (bbg_file_opened, bbg_function_announced): Remove.
2185         (get_coverage_counts): Adjust message.
2186         (coverage_begin_ouput): Rename to ...
2187         (coverage_begin_function): ... here.  Move file opening to
2188         coverage_init.  Adjust for being called only once.
2189         (coverage_end_function): Remove bbg file and inhibit further
2190         output here on error.
2191         (build_info_type): Adjust for change to pointer to array.
2192         (build_info): Receive array of function pointers and adjust.
2193         (create_coverage): Break into ...
2194         (coverage_obj_init, coverage_obj_fn, coverage_obj_finish):
2195         ... these, and adjust.
2196         (coverage_init): Open the notes file here.  Tidy.
2197         (coverage_finish): Call coverage_obj_init etc.
2198
2199 2011-12-04  Ira Rosen  <ira.rosen@linaro.org>
2200
2201         PR middle-end/51285
2202         * tree-vect-loop.c (vect_create_epilog_for_reduction): Create exit
2203         phi nodes for outer loop in case of double reduction.
2204
2205 2011-12-04  Jérémie Detrey  <Jeremie.Detrey@loria.fr>
2206
2207         PR target/51393
2208         * config/i386/avxintrin.h (_mm256_insert_epi64): Declare second
2209         parameter as long long.
2210
2211 2011-12-04  Richard Sandiford  <rdsandiford@googlemail.com>
2212
2213         PR middle-end/51351
2214         * optabs.c (init_sync_libfuncs): Use "or" rather than "ior"
2215         in the external names.
2216
2217 2011-12-03  Jack Howarth <howarth@bromo.med.uc.edu>
2218
2219         * config/darwin10.h (LINK_GCC_C_SEQUENCE_SPEC): Pass -no_pie for
2220         non-PIC code when targeting 10.7 or later.
2221
2222 2011-12-03  Iain Sandoe  <iains@gcc.gnu.org>
2223
2224         * config/darwin.h (STARTFILE_SPEC): Do not use -lbundle1.o when
2225         Darwin >= 10.
2226         (DARWIN_DYLIB1_SPEC): Do not use -ldylib1.10.5.o when Darwin >= 10.
2227         (DARWIN_CRT1_SPEC): Use -lcrt1.10.6.o when Darwin >= 10.
2228
2229 2011-12-03  Jakub Jelinek  <jakub@redhat.com>
2230
2231         * fold-const.c (fold_unary_loc): Fold VEC_UNPACK_LO_EXPR,
2232         VEC_UNPACK_HI_EXPR, VEC_UNPACK_FLOAT_LO_EXPR and
2233         VEC_UNPACK_FLOAT_HI_EXPR with VECTOR_CST argument.
2234         (fold_binary_loc): Fold VEC_PACK_TRUNC_EXPR,
2235         VEC_PACK_FIX_TRUNC_EXPR, VEC_WIDEN_MULT_LO_EXPR
2236         and VEC_WIDEN_MULT_HI_EXPR with VECTOR_CST arguments.
2237
2238         PR debug/50317
2239         * tree-ssa.c (target_for_debug_bind): Also allow is_gimple_reg_type
2240         vars that aren't referenced.
2241         (tree-ssa-live.c (remove_unused_locals): Don't clear TREE_ADDRESSABLE
2242         of unreferenced local vars.
2243         * cfgexpand.c (expand_debug_expr): For DEBUG_IMPLICIT_PTR allow also
2244         TREE_ADDRESSABLE vars that satisfy target_for_debug_bind.
2245
2246 2011-12-03  Anatoly Sokolov  <aesok@post.ru>
2247
2248         * config/arm/arm.h (LIBCALL_VALUE, FUNCTION_VALUE_REGNO_P): Remove.
2249         * config/arm/arm-protos.h (aapcs_libcall_value): Remove.
2250         * config/arm/arm.c (TARGET_FUNCTION_VALUE_REGNO_P): Define.
2251         (arm_libcall_value_1, arm_function_value_regno_p): New function.
2252         (arm_function_value, arm_libcall_value): Use arm_libcall_value_1.
2253         (aapcs_libcall_value): Make static.
2254         (arm_libcall_value): Add static qualifier.
2255
2256 2011-12-02  Jakub Jelinek  <jakub@redhat.com>
2257
2258         PR target/51387
2259         * config/i386/sse.md (mul<mode>3 with VI1_AVX2 iterator): For
2260         V32QImode use { 0,2,..,14,32,34,..,46,16,18,..,30,48,50,..,62 }
2261         permutation instead of extract even permutation.
2262
2263 2011-12-02  Nathan Sidwell  <nathan@acm.org>
2264
2265         * gcov.c (struct arc_info): Add is_throw field.
2266         (struct (block_info): Add exceptional field, reduce flags size to
2267         account for it.
2268         (struct function_info): Add has_catch field.
2269         (struct line_info): Add unexceptional field.
2270         (process_file): Call find_exception_blocks if necessary.
2271         (read_graph_file): Adjust.  Note if an exceptional edge is seen.
2272         (find_exception_blocks): New.
2273         (add_line_counts): Set line's unexceptional flag if not exceptional.
2274         (output_branch_count): Note exceptional arcs, lines and blocks.
2275         * gcov-dump.c (tag_arcs): Decode arc flags.
2276         * doc/gcov.texi: Document '=====' lines.
2277
2278 2011-12-02  Anatoly Sokolov  <aesok@post.ru>
2279
2280         * config/ia64/ia64.h (PRINT_OPERAND, PRINT_OPERAND_ADDRESS,
2281         PRINT_OPERAND_PUNCT_VALID_P): Remove macros.
2282         * config/ia64/ia64-protos.h (ia64_print_operand,
2283         ia64_print_operand_address): Remove.
2284         * config/ia64/ia64.c (TARGET_PRINT_OPERAND,
2285         TARGET_PRINT_OPERAND_ADDRESS, TARGET_PRINT_OPERAND_PUNCT_VALID_P):
2286         Define.
2287         (ia64_print_operand_punct_valid_p): New function.
2288         (ia64_print_operand, ia64_print_operand_address): Make static.
2289
2290 2011-12-02  Michael Meissner  <meissner@linux.vnet.ibm.com>
2291
2292         PR target/51390
2293         * config/rs6000/rs6000.c (def_builtin): Use the correct field to
2294         figure out the function's attributes.
2295         (struct builtin_description): Mark mask field as const since we no
2296         longer need to modify it for SPE and PAIRED builtins.
2297
2298 2011-12-02  Joseph Myers  <joseph@codesourcery.com>
2299
2300         Revert:
2301
2302         2008-09-18  Andrew Pinski  <andrew_pinski@playstation.sony.com>
2303
2304         PR rtl-opt/37451
2305         * loop-doloop.c (doloop_modify): New argument zero_extend_p and
2306         zero extend count after the correction to it is done.
2307         (doloop_optimize): Update call to doloop_modify, don't zero extend
2308         count before call.
2309
2310         2008-11-03  Andrew Pinski  <andrew_pinski@playstation.sony.com>
2311
2312         PR rtl-opt/37782
2313         * loop-doloop.c (doloop_modify): Add from_mode argument that says what
2314         mode count is in.
2315         (doloop_optimize): Update call to doloop_modify.
2316
2317 2011-12-02  Richard Guenther  <rguenther@suse.de>
2318
2319         PR lto/47259
2320         * ipa.c (varpool_externally_visible_p): Register variables
2321         are always externally visible.
2322
2323 2011-12-02  Sameera Deshpande  <sameera.deshpande@arm.com>
2324
2325         * gimple-pretty-print.c (dump_gimple_call): Dereference fn only if
2326           non-NULL.
2327
2328 2011-12-02  Martin Jambor  <mjambor@suse.cz>
2329
2330         PR tree-optimization/50622
2331         * tree-sra.c (load_assign_lhs_subreplacements): Force gimple operand
2332         if both lacc and racc are grp_partial_lhs.
2333
2334 2011-12-01  Kaz Kojima  <kkojima@gcc.gnu.org>
2335
2336         PR target/50814.
2337         * config/sh/sh.c (expand_ashiftrt): Handle TARGET_SH2A same as
2338         TARGET_SH3.
2339         (shl_sext_kind): Likewise.
2340         * config/sh/sh.h (SH_DYNAMIC_SHIFT_COST): Likewise.
2341         * config/sh/sh.md (ashlsi3_sh2a, ashrsi3_sh2a, lshrsi3_sh2a): Remove.
2342         (ashlsi3_std): Handle TARGET_SH2A same as TARGET_SH3.
2343         (ashlsi3): Likewise.
2344         (ashrsi3_d): Likewise.
2345         (lshrsi3_d): Likewise.
2346         (lshrsi3): Likewise.
2347
2348 2011-12-01  Diego Novillo  <dnovillo@google.com>
2349
2350         PR bootstrap/51346
2351         * ipa-inline.c (can_inline_edge_p): If the edge E has a statement,
2352         use the statement's inline indicator instead of E's.
2353         Remove consistency check.
2354
2355 2011-12-01  Diego Novillo  <dnovillo@google.com>
2356
2357         PR bootstrap/51346
2358         Revert
2359
2360         2011-11-29  Diego Novillo  <dnovillo@google.com>
2361
2362         * gimple.c (gimple_call_set_cannot_inline): Move from gimple.h.
2363         Update field call_stmt_cannot_inline_p from call
2364         graph edge, if needed.
2365         * gimple.h (gimple_call_set_cannot_inline): Move to gimple.c.
2366
2367 2011-12-01  Nathan Sidwell  <nathan@acm.org>
2368
2369         PR gcov-profile/51113
2370         * coverage.c (build_var): Keep coverage variables static.
2371
2372 2011-12-01  Jakub Jelinek  <jakub@redhat.com>
2373
2374         PR tree-optimization/51356
2375         * tree-vect-patterns.c (vect_recog_bool_pattern): Give up if
2376         vectype doesn't have VECTOR_MODE_P.
2377
2378         PR debug/50317
2379         * tree-ssa-dce.c (remove_dead_stmt): Add a debug stmt when removing
2380         as unnecessary a store to a variable with gimple reg type.
2381         * tree-ssa-live.c (remove_unused_locals): Clear TREE_ADDRESSABLE bit
2382         on local unreferenced variables.
2383         * cfgexpand.c (expand_gimple_basic_block): Don't emit DEBUG_INSNs
2384         for !target_for_debug_bind variables.
2385
2386 2011-12-01  Patrick Marlier  <patrick.marlier@gmail.com>
2387
2388         PR middle-end/51273
2389         * cgraph.h (cgraph_call_node_duplication_hooks): Declare.
2390         * cgraph.c (cgraph_call_node_duplication_hooks): Make global.
2391         * cgraphunit.c (cgraph_copy_node_for_versioning): Call it.
2392
2393 2011-12-01  Andrew Pinski  <apinski@cavium.com>
2394
2395         PR lto/51198
2396         * tree.c (free_lang_data_in_decl): Clear FIELD_DECL's
2397         DECL_INITIAL also.
2398
2399 2011-12-01  Jakub Jelinek  <jakub@redhat.com>
2400
2401         PR tree-optimization/51246
2402         * tree-predcom.c (replace_ref_with): Handle also clobber on the rhs.
2403
2404         PR rtl-optimization/51014
2405         * loop-unroll.c (apply_opt_in_copies): Ignore label DEBUG_INSNs
2406         both from bb and orig_bb.
2407
2408 2011-12-01  Joern Rennecke  <joern.rennecke@embecosm.com>
2409
2410         PR tree-optimization/50802
2411         * tree-vrp.c (simplify_conversion_using_ranges): Rewrite test
2412         considering what happens to ranges during sign changes and/or
2413         intermediate narrowing conversions.
2414
2415 2011-11-30  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
2416
2417         PR middle-end/50283
2418         * config/pa/pa.md (in_branch_delay): Disallow frame related insns.
2419         (in_nullified_branch_delay): Likewise.
2420         (in_call_delay): Likewise.
2421
2422 2011-11-30  Richard Henderson  <rth@redhat.com>
2423
2424         * predict.c (expr_expected_value_1): Assume compare-and-swap builtin
2425         boolean return is true.
2426
2427 2011-11-30  Jakub Jelinek  <jakub@redhat.com>
2428
2429         PR rtl-optimization/51044
2430         * dse.c (emit_inc_dec_insn_before): Ensure new_insn is an instruction
2431         rather than just insn body.
2432
2433         PR target/50725
2434         * function.c (thread_prologue_and_epilogue_insns): If
2435         stack_realign_drap, add drap_reg to SET_UP_BY_PROLOGUE
2436         regset.
2437
2438         PR middle-end/51089
2439         * tree-eh.c (cleanup_empty_eh_merge_phis): Add check to
2440         avoid creating duplicate edges here.
2441         (cleanup_empty_eh_unsplit): And remove it in the caller.
2442
2443 2011-11-30  Andrew Pinski  <apinski@cavium.com>
2444
2445         PR c/51321
2446         * c-parser.c (c_parser_postfix_expression): Check groktypename results
2447         before looking at the main variant.
2448
2449 2011-11-30  Jakub Jelinek  <jakub@redhat.com>
2450
2451         PR rtl-optimization/48721
2452         * sched-deps.c (sched_analyze_insn): For SIBLING_CALL_P set
2453         reg_pending_barrier to TRUE_BARRIER.
2454
2455         PR rtl-optimization/48721
2456         * sched-ebb.c (begin_move_insn): Insert empty unreachable
2457         block after BARRIER if insn is followed by it.
2458
2459 2011-11-30  Richard Henderson  <rth@redhat.com>
2460
2461         * config/sparc/sparc-opts.h (enum sparc_memory_model_type): New.
2462         * config/sparc/sparc.opt (mmemory-model=): New option.
2463         * doc/invoke.texi (Sparc Options): Document it.
2464         * config/sparc/sparc.c (sparc_option_override): Provide default
2465         for sparc_memory_model.
2466         (sparc_emit_membar_for_model): Omit barrier combinations that are
2467         implied by the memory model.
2468
2469 2011-11-30  Richard Henderson  <rth@redhat.com>
2470
2471         * config/sparc/sync.md (I124MODE): New mode iterator.
2472         (memory_barrier): Remove.
2473         (atomic_exchangesi): New.
2474         (swapsi): Rename from *swapsi.
2475         (atomic_test_and_set<I124MODE>): New.
2476         (ldstubqi): Rename from *ldstubqi, merge with expander.
2477         (ldstub<I24MODE>): Rename from *ldstub<I24MODE>, merge with expander.
2478         (sync_lock_test_and_setsi): Remove.
2479         (sync_lock_test_and_set<I12MODE>): Remove.
2480
2481 2011-11-30  Richard Henderson  <rth@redhat.com>
2482
2483         * config/sparc/constraints.md ("w"): New.
2484         * config/sparc/predicates.md (mem_noofs_operand): New.
2485         * config/sparc/sparc.c (sparc_expand_compare_and_swap_12): Make static.
2486         Generate the boolean result of the atomic_compare_exchange.
2487         (sparc_expand_compare_and_swap): New.
2488         * config/sparc/sync.md (atomic_compare_and_swap<I>): New.
2489         (atomic_compare_and_swap<I48MODE>_1): Rename from
2490         *sync_compare_and_swap<I48MODE>, use mem_noofs_operand.
2491         (*atomic_compare_and_swapdi_v8plus): Rename from
2492         *sync_compare_and_swapdi_v8plus, use mem_noofs_operand.
2493         (sync_compare_and_swap<I12MODE>): Remove.
2494         (sync_compare_and_swap<I48MODE>): Remove.
2495
2496 2011-11-30  Richard Henderson  <rth@redhat.com>
2497
2498         * config/sparc/predicates.md (register_or_v9_zero_operand): New.
2499         * config/sparc/sparc.md (UNSPEC_ATOMIC): New.
2500         * config/sparc/sync.md (atomic_load<I>): New.
2501         (atomic_loaddi_1, atomic_store<I>, atomic_storedi_1): New.
2502
2503 2011-11-30  Richard Henderson  <rth@redhat.com>
2504
2505         * config/sparc/predicates.md (zero_or_v7_operand): New.
2506         * config/sparc/sparc.c (sparc_emit_membar_for_model): New.
2507         * config/sparc/sparc-protos.h: Update.
2508         * config/sparc/sync.md (mem_thread_fence): New.
2509         (memory_barrier): Use sparc_emit_membar_for_model.
2510         (membar, *membar_empty, *membar_storestore, *membar_storeload): New.
2511         (*membar_v8): Accept and ignore the membar mask.
2512         (*membar): Accept and print the membar mask.
2513
2514 2011-11-30  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
2515
2516         * config/arm/arm.c (arm_issue_rate): Cortex-A15 can triple issue.
2517         * config/arm/arm.md (mul64): New attribute.
2518         (generic_sched): Cortex-A15 is not scheduled generically.
2519         (cortex-a15.md): Include.
2520         * config/arm/cortex-a15.md: New machine description.
2521         * config/arm/t-arm (MD_INCLUDES): Add cortex-a15.md.
2522
2523 2011-11-30  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
2524
2525         * config/arm/t-arm (MD_INCLUDES): Ensure all md files are listed.
2526
2527 2011-11-30  Iain Sandoe  <iains@gcc.gnu.org>
2528
2529         * doc/tm.texi.in (NEXT_OBJC_RUNTIME): Update macro description.
2530         * doc/tm.texi: Regenerate.
2531         * flags.h (flag_next_runtime): Remove references.
2532         * toplev.c: Likewise.
2533         * defaults.h (NEXT_OBJC_RUNTIME): Provide default.
2534         * gccspec.c (lang_specific_driver): Adjust use of NEXT_OBJC_RUNTIME.
2535         * config/darwin.c (darwin_override_options): Provide default
2536         Objective-C abi settings and target conflict checks.
2537         * config/darwin.h (SUBTARGET_C_COMMON_OVERRIDE_OPTIONS): Remove unused
2538         code. Adjust indenting.
2539
2540 2011-11-29  Joseph Myers  <joseph@codesourcery.com>
2541
2542         * config/sh/sh.h (enum reg_class, REG_CLASS_NAMES)
2543         (REG_CLASS_CONTENTS): Add NON_SP_REGS.
2544         (REGCLASS_HAS_GENERAL_REG): Handle NON_SP_REGS.
2545         * config/sh/constraints.md (u): New constraint.
2546
2547 2011-11-29  Oleg Endo  <oleg.endo@t-online.de>
2548
2549         PR target/51337
2550         * config/sh/sh.c (sh_secondary_reload): Add case when FPUL
2551         register is being loaded from a pseudo in memory.
2552
2553 2011-11-29  DJ Delorie  <dj@redhat.com>
2554
2555         * config.gcc (rl78-*-elf): New case.
2556         * doc/extend.texi: Add RL78 documentation.
2557         * doc/invoke.texi: Likewise.
2558         * doc/md.texi: Likewise.
2559         * doc/contrib.texi: Add RL78.
2560         * doc/install.texi: Add rl78-*-elf.
2561         * config/rl78: New directory for the Renesas RL78.
2562
2563 2011-11-29  Jakub Jelinek  <jakub@redhat.com>
2564
2565         PR tree-optimization/51247
2566         * tree-vrp.c (extract_range_from_assert): For signed 1-bit precision
2567         types instead of adding 1 subtract -1 and instead of subtracting 1
2568         add -1 to avoid overflows.
2569
2570 2011-11-29  Andrew MacLeod  <amacleod@redhat.com>
2571
2572         PR target/50123
2573         * optabs.c (maybe_optimize_fetch_op): New.  Look for more optimal
2574         instructions for a FECTH_OP or OP_FECTH sequence.
2575         (expand_atomic_fetch_op): Call maybe_optimize_fetch_op.
2576
2577 2011-11-29  Uros Bizjak  <ubizjak@gmail.com>
2578
2579         * config/i386/sync.md (UNSPEC_LDA, UNSPEC_STA): New unspecs.
2580         (movdi_via_fpu): Remove.
2581         (loaddi_via_fpu): New insn pattern.
2582         (storedi_via_fpu): Ditto.
2583         (atomic_loaddi_fpu): Use loaddi_via_fpu and storedi_via_fpu.
2584         (atomic_storedi_fpu): Ditto.
2585         * reg-stack.c (get_true_reg): Handle UNSPEC_LDA.
2586         (subst_stack_regs_pat): Handle UNSPEC_STA.
2587
2588 2011-11-29  Uros Bizjak  <ubizjak@gmail.com>
2589
2590         * config/i386/i386.md (*floathi<mode>2_i387_with_temp): Do not
2591         allocate scratch memory for alternative 0.
2592
2593 2011-11-29  Michael Meissner  <meissner@linux.vnet.ibm.com>
2594
2595         * config/rs6000/rs6000-builtins.def: Completely rewrite builtin
2596         handling to centralize more of the builtins in this file.  Change
2597         some builtin enumerations to be more consistant.  Use a new mask
2598         to hold the current builtins, including SPE and PAIRED builtins
2599         which no longer are set via target_flags masks.  Add
2600         -mdebug=builtin debug support.  For power machines, define all
2601         Altivec and VSX buitins when the compiler starts, but don't allow
2602         the use of a builtin unless the appropriate switch is used, or
2603         #pragma GCC target is used to change the options.  If the user
2604         uses #pragma GCC target, update the appropriate hardware macros.
2605         * common/config/rs6000/rs6000-common.c (rs6000_handle_option): Ditto.
2606         * config/rs6000/rs6000.opt (rs6000_builtin_mask): Ditto.
2607         * config/rs6000/rs6000-c.c (rs6000_macro_to_expand): Ditto.
2608         (rs6000_define_or_undefine_macro): Ditto.
2609         (rs6000_target_modify_macros): Ditto.
2610         (rs6000_cpu_cpp_builtins): Ditto.
2611         (altivec_overloaded_builtins): Ditto.
2612         (altivec_build_resolved_builtin): Ditto.
2613         * config/rs6000/rs6000.c (rs6000_target_modify_macros_ptr): Ditto.
2614         (rs6000_builtin_info): Ditto.
2615         (def_builtin): Ditto.
2616         (enable_mask_for_builtins): Ditto.
2617         (DEBUG_FMT_X): Ditto.
2618         (rs6000_debug_reg_global): Ditto.
2619         (rs6000_builtin_mask_calculate): Ditto.
2620         (rs6000_option_override_internal): Ditto.
2621         (rs6000_builtin_conversion): Ditto.
2622         (rs6000_builtin_vectorized_function): Ditto.
2623         (bdesc_3arg): Ditto.
2624         (bdesc_dst): Ditto.
2625         (bdesc_2arg): Ditto.
2626         (builtin_description_predicates): Ditto.
2627         (bdesc_altivec_preds): Ditto.
2628         (bdesc_spe_predicates): Ditto.
2629         (bdesc_spe_evsel): Ditto.
2630         (bdesc_paired_preds): Ditto.
2631         (bdesc_abs): Ditto.
2632         (bdesc_1arg): Ditto.
2633         (rs6000_overloaded_builtin_p): Ditto.
2634         (rs6000_expand_unop_builtin): Ditto.
2635         (bdesc_2arg_spe): Ditto.
2636         (spe_expand_builtin): Ditto.
2637         (rs6000_invalid_builtin): Ditto.
2638         (rs6000_expand_builtin): Ditto.
2639         (rs6000_init_builtins): Ditto.
2640         (spe_init_builtins): Ditto.
2641         (paired_init_builtins): Ditto.
2642         (altivec_init_builtins): Ditto.
2643         (builtin_function_type): Ditto.
2644         (rs6000_common_init_builtins): Ditto.
2645         (rs6000_builtin_reciprocal): Ditto.
2646         (rs6000_builtin_mask_names): Ditto.
2647         (rs6000_pragma_target_parse): Ditto.
2648         (rs6000_function_specific_print): Ditto.
2649         * config/rs6000/rs6000.h (MASK_DEBUG_BUILTIN): Ditto.
2650         (MASK_DEBUG_ALL): Ditto.
2651         (TARGET_DEBUG_BUILTIN): Ditto.
2652         (TARGET_EXTRA_BUILTINS): Ditto.
2653         (REGISTER_TARGET_PRAGMAS): Ditto.
2654         (enum rs6000_btc): Ditto.
2655         (RS6000_BTC_*): Ditto.
2656         (RS6000_BTM_*): Ditto.
2657         (enum rs6000_builtins): Ditto.
2658         * config/rs6000/rs6000-protos.h (rs6000_overloaded_builtin_p): Ditto.
2659         (rs6000_target_modify_macros): Ditto.
2660         (rs6000_target_modify_macros_ptr): Ditto.
2661
2662         * config/rs6000/vector.md (unsfloat<VEC_int><mode>2): Use the
2663         standard name for converting vector unsigned values to floating
2664         point.  Delete the TARGET_VECTORIZE_BUILTIN_CONVERSION hook, which
2665         is handled by machine independent code.
2666         * config/rs6000/rs6000.c (TARGET_VECTORIZE_BUILTIN_CONVERSION): Ditto.
2667         (rs6000_builtin_conversion): Ditto.
2668
2669 2011-11-29  Dodji Seketeli  <dodji@redhat.com>
2670
2671         * tree-diagnostic (struct loc_t): Rename into struct loc_map_pair.
2672         (maybe_unwind_expanded_macro_loc): Adjust.
2673
2674 2011-11-29  David Edelsohn  <dje.gcc@gmail.com>
2675             Aldy Hernandez  <aldyh@redhat.com>
2676
2677         * trans-mem.c (ipa_tm_create_version_alias): Mangle new_decl
2678         if DECL_ONE_ONLY.
2679         (ipa_tm_create_version): Same.
2680
2681 2011-11-29  Bernd Schmidt  <bernds@codesourcery.com>
2682
2683         * haifa-sched.c (recompute_todo_spec): Simplify and correct the
2684         code checking for a clobber of a condition register when deciding
2685         whether to predicate.
2686
2687 2011-11-29  Diego Novillo  <dnovillo@google.com>
2688
2689         * gimple.c (gimple_call_set_cannot_inline): Move from gimple.h.
2690         Update field call_stmt_cannot_inline_p from call graph edge, if needed.
2691         * gimple.h (gimple_call_set_cannot_inline): Move to gimple.c.
2692
2693 2011-11-29  Sameera Deshpande  <sameera.deshpande@arm.com>
2694
2695         * config/arm/arm.md (arm_movdi): Update NEG_POOL_RANGE.
2696         (movdf_soft_insn): Likewise.
2697         * config/arm/fpa.md (thumb2_movdf_fpa): Likewise.
2698         * config/arm/neon.md (neon_mov<mode>): Likewise.
2699         * config/arm/vfp.md (movdi_vfp): Likewise.
2700         (movdi_vfp_cortexa8): Likewise.
2701         (movdf_vfp): Likewise.
2702
2703 2011-11-29  Jakub Jelinek  <jakub@redhat.com>
2704
2705         PR middle-end/50074
2706         * expr.c (expand_expr_addr_expr_1): Don't call force_operand for
2707         EXPAND_SUM modifier.
2708
2709 2011-11-29  Ira Rosen  <ira.rosen@linaro.org>
2710
2711         PR tree-optimization/51301
2712         * tree-vect-patterns.c (vect_recog_over_widening_pattern): Check that
2713         the last statement doesn't convert to a bigger type than the original
2714         type of the computation.
2715
2716 2011-11-28  Richard Henderson  <rth@redhat.com>
2717
2718         * config/rs6000/rs6000.c (rs6000_expand_atomic_compare_and_swap):
2719         Handle overlap between retval and oldval.  Always compute boolval
2720         from CR0 EQ value.
2721
2722 2011-11-28  Jakub Jelinek  <jakub@redhat.com>
2723
2724         PR debug/50317
2725         * tree-ssa.c (execute_update_addresses_taken): Remove
2726         var ={v} {CLOBBER} stmts instead of rewriting them into
2727         var_N ={v} {CLOBBER}.
2728
2729         PR middle-end/50907
2730         * function.c (convert_jumps_to_returns): When redirecting an edge
2731         succ to EXIT_BLOCK_PTR, clear EDGE_CROSSING flag.
2732
2733         PR tree-optimization/50078
2734         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Copy over
2735         TREE_THIS_VOLATILE also from the old to new lhs resp. rhs.
2736
2737         PR tree-optimization/50682
2738         * tree-eh.c (maybe_remove_unreachable_handlers): New function.
2739         * tree-flow.h (maybe_remove_unreachable_handlers): New prototype.
2740         * tree-optimize.c (execute_cleanup_cfg_post_optimizing): Call it.
2741
2742 2011-11-28  Georg-Johann Lay  <avr@gjlay.de>
2743
2744         * doc/extend.texi (AVR Built-in Functions): Add documentation for
2745         __builtin_avr_map8 and __builtin_avr_map16.
2746
2747         * config/avr/avr.md: Document new %t and %T asm output codes.
2748         (define_c_enum "unspec"): Add UNSPEC_MAP_BITS.
2749         (adjust_len): Add map_bits.
2750         (map_bitsqi, map_bitshi): New insns.
2751         * config/avr/avr-protos.h (avr_out_map_bits): New.
2752         * config/avr/avr-protos.c (print_operand): Implement %t and %T.
2753         (adjust_insn_length): Handle ADJUST_LEN_MAP_BITS.
2754         (avr_double_int_push_digit): New function.
2755         (avr_map, avr_revert_map, avr_swap_map, avr_id_map): New functions.
2756         (avr_sig_map, avr_map_hamming_byte): New functions.
2757         (avr_out_swap_bits, avr_out_revert_bits, avr_move_bits,
2758         avr_out_map_bits): New functions.
2759         (enum avr_builtin_id): Add AVR_BUILTIN_MAP8, AVR_BUILTIN_MAP16.
2760         (avr_init_builtins): Populate __builtin_avr_map8, __builtin_avr_map16.
2761         (bdesc_2arg): Add __builtin_avr_map8, __builtin_avr_map16 ...
2762         (avr_expand_builtin): ...and expand them.
2763         * config/avr/avr-c.c (avr_cpu_cpp_builtins): New built-in defines:
2764         __BUILTIN_AVR_MAP8, __BUILTIN_AVR_MAP16.
2765
2766 2011-11-27  Richard Sandiford  <rdsandiford@googlemail.com>
2767
2768         PR target/51278
2769         * config/mips/mips.c (mips_rtx_costs): Handle baddu.
2770
2771 2011-11-27  Richard Sandiford  <rdsandiford@googlemail.com>
2772
2773         * config/mips/mips.c (mips16_unextended_reference_p): Test for BLKmode.
2774
2775 2011-11-27  Richard Sandiford  <rdsandiford@googlemail.com>
2776
2777         * config/mips/mips-protos.h (mips_emit_binary): Declare.
2778         * config/mips/mips.c (mips_emit_binary): Make global.
2779         (mips_set_mips16_mode): Turn off -mfix-r4000 in MIPS16 mode.
2780         (mips_conditional_register_usage): Don't treat LO and HI as
2781         register operands in MIPS16 mode.
2782         (mips_mulsidi3_gen_fn): Use {u,}mulsidi3_{32,64}bit_mips16
2783         for MIPS16 code.
2784         * config/mips/predicates.md (muldiv_target_operand): New predicate.
2785         (move_operand): Allow hilo_operand.
2786         * config/mips/mips.md (mul<mode>3): Explicitly specify LO as the
2787         target of MIPS16 multiplies, then move it into the target register.
2788         (mul<mode>3_internal, *macc2, *msac2): Use muldiv_target_operand.
2789         (<u>mulsidi3_32bit_mips16): New expander.
2790         (<u>mulsidi3_32bit): Use muldiv_target_operand.
2791         (<u>mulsidi3_32bit_r4000): Disable for ISA_HAS_DSP.
2792         (<u>mulsidi3_64bit): Require !TARGET_MIPS16.  Split into
2793         <u>mulsidi3_64bit_split.
2794         (<u>mulsidi3_64bit_mips16): New expander.
2795         (<u>mulsidi3_64bit_split): Likewise, using expansions from
2796         two previous define_splits.
2797         (<u>mulsidi3_64bit_hilo, *muls<u>_di, <u>msubsidi4): Use
2798         muldiv_target_operand.
2799         (<su>mulsi3_highpart): Use <su>mulsi3_highpart_split for MIPS16 code.
2800         (<su>mulsi3_highpart_internal): Require !TARGET_MIPS16.
2801         Split into <su>mulsi3_highpart_split.
2802         (<su>mulsi3_highpart_split): New expander.
2803         (<su>muldi3_highpart): Turn into a define_expand.
2804         Use <su>muldi3_highpart_split for MIPS16 code.
2805         (<su>muldi3_highpart_internal): Renamed from <su>muldi3_highpart.
2806         Require !TARGET_MIPS16.  Split into <su>muldi3_highpart_split.
2807         (<su>muldi3_highpart_split): New expander.
2808         (<u>mulditi3): Explicitly specify LO as the target of MIPS16
2809         multiplies, then move it into the target register.
2810         (<u>mulditi3_internal, <u>maddsidi4): Use muldiv_target_operand.
2811         (divmod<mode>4, udivmod<mode>4): Turn into define_expands.
2812         Use <u>divmod<mode>4_split for MIPS16 code, then explicitly
2813         move LO into operand 0.
2814         (divmod<mode>4_internal, udivmod<mode>4_internal): Renamed
2815         from <u>divmod<mode>4.  Use muldiv_target_operand.
2816         Require !TARGET_MIPS16.  Split into <u>divmod<mode>4_split.
2817         (<u>divmod<mode>4_split): New expander.
2818         (<u>divmod<GPR:mode>4_hilo_<HILO:mode>): Use muldiv_target_operand.
2819         (mfhi<GPR:mode>_<HILO:mode>): Use hilo_operand.
2820
2821 2011-11-27  Richard Sandiford  <rdsandiford@googlemail.com>
2822
2823         * hard-reg-set.h (target_hard_regs): Add x_accessible_reg_set
2824         and x_operand_reg_set.
2825         (accessible_reg_set, operand_reg_set): New macros.
2826         * reginfo.c (init_reg_sets): Initialize accessible_reg_set and
2827         operand_reg_set.
2828         (saved_accessible_reg_set, saved_operand_reg_set): New variables.
2829         (save_register_info): Save them.
2830         (restore_register_info): Restore them.
2831         (init_reg_sets_1): Limit operand_reg_set to accessible_reg_set.
2832         Remove NO_REGS registers from operand_reg_set.  Treat members
2833         of operand_reg_set as fixed.
2834         * recog.c (general_operand): Check operand_reg_set rather than NO_REGS.
2835         (register_operand, nonmemory_operand): Likewise.
2836         * varasm.c (make_decl_rtl): Always use DECL_MODE as the mode of
2837         register variables.  Check accessible_reg_set and operand_reg_set.
2838         * config/mips/mips.c (mips_conditional_register_usage): Remove
2839         inaccessible register from accessible_reg_set, rather than just
2840         making them fixed.
2841
2842 2011-11-27  Gerald Pfeifer  <gerald@pfeifer.com>
2843
2844         * config/pa/pa-linux.h (TARGET_GAS): Remove comment.
2845
2846 2011-11-26  Richard Henderson  <rth@redhat.com>
2847
2848         * config/arm/arm.c (arm_init_libfuncs): Call init_sync_libfuncs
2849         for Linux.
2850
2851 2011-11-26  Richard Henderson  <rth@redhat.com>
2852
2853         * optabs.c (expand_atomic_fetch_op): Always return result.
2854
2855         * optabs.c (init_sync_libfuncs_1): Include max in iteration.
2856
2857         * omp-low.c (expand_omp_atomic): Assume anything aligned to
2858         BIGGEST_ALIGNMENT is aligned.
2859
2860 2011-11-26  Richard Henderson  <rth@redhat.com>
2861
2862         * config/m68k/m68k.md (UNSPECV_CAS_1, UNSPECV_CAS_2): New.
2863         (UNSPECV_TAS_1, UNSPECV_TAS_2): New.
2864         (I): New mode iterator.
2865         (xz): New mode attribute.
2866         * config/m68k/sync.md: New file.
2867
2868         * config/m68k/linux.h (TARGET_INIT_LIBFUNCS): New.
2869         * config/m68k/m68k.c (m68k_init_sync_libfuncs): New.
2870
2871 2011-11-26  Nathan Sidwell  <nathan@acm.org>
2872
2873         PR gcov-profile/51297
2874         * gcov.c (main): Allocate initial names and sources arrays.
2875         (find_source): Don't check for null name or source arrays here.
2876
2877 2011-11-26  Jakub Jelinek  <jakub@redhat.com>
2878
2879         PR rtl-optimization/49912
2880         * cfgrtl.c (rtl_verify_flow_info_1): Ignore also EDGE_PRESERVE bit
2881         when counting n_branch.
2882
2883 2011-11-26  Uros Bizjak  <ubizjak@gmail.com>
2884
2885         * config/i386/sync.md (movdi_via_fpu): Add %Z insn suffixes.
2886
2887 2011-11-26  Joern Rennecke  <joern.rennecke@embecosm.com>
2888
2889         PR middle-end/50074
2890         * calls.c (mem_overlaps_already_clobbered_arg_p):
2891         Return false if no outgoing arguments have been stored so far.
2892
2893 2011-11-25  Georg-Johann Lay  <avr@gjlay.de>
2894
2895         * config/avr/avr.c (print_operand): Support code = 'i' for CONST_INT.
2896
2897 2011-11-24  Andrew MacLeod  <amacleod@redhat.com>
2898
2899         PR other/51011
2900         * tree.h (is_builtin_name): No longer external.
2901         * builtins.c (is_builtin_name): Make static.
2902         * varasm.c (incorporeal_function_p): __sync and __atomic external calls
2903         are not incorporeal and may need asm label processing.
2904
2905 2011-11-25  Georg-Johann Lay  <avr@gjlay.de>
2906
2907         PR target/50566
2908         * config/avr/avr-protos.h (avr_log_t): Add field .builtin.
2909         * config/avr/avr-log.c (avr_log_set_avr_log): Initialize it.
2910         Don't bypass TARGET_ALL_DEBUG.  Print self-info with ?.
2911         (avr_log_vadump): Support %D and %X to print double_int.
2912         (avr_double_int_pop_digit): New static function.
2913         (avr_dump_double_int_hex): New static function.
2914
2915 2011-11-24  Enkovich Ilya  <ilya.enkovich@intel.com>
2916
2917         PR target/51287
2918         * config/i386/i386.c (distance_non_agu_define_in_bb): Fix insn
2919         attr check.
2920
2921 2011-11-24  Andrew MacLeod  <amacleod@redhat.com>
2922
2923         * optab.c (maybe_emit_atomic_exchange): New.  Try to emit an
2924         atomic_exchange pattern.
2925         (maybe_emit_sync_lock_test_and_set): New.  Try to emit an exchange
2926         using __sync_lock_test_and_set.
2927         (maybe_emit_compare_and_swap_exchange_loop): New. Try to emit an
2928         exchange using a compare_and_swap loop.
2929         (expand_sync_lock_test_and_set): New.  Expand sync_lock_test_and_set.
2930         (expand_atomic_test_and_set): New.  Expand test_and_set operation.
2931         (expand_atomic_exchange): Use new maybe_emit_* functions.
2932         (expand_atomic_store): Use new maybe_emit_* functions.
2933         * builtins.c (expand_builtin_sync_lock_test_and_set): Call
2934         expand_sync_lock_test_and_set routine.
2935         (expand_builtin_atomic_exchange): Remove parameter from call.
2936         (expand_builtin_atomic_clear): Use atomic_clear pattern if present.
2937         (expand_builtin_atomic_test_and_set): Add target and simply call
2938         expand_atomic_test_and_set.
2939         (expand_builtin): Add target to expand_builtin_atomic_test_and_set.
2940         * expr.h (expand_atomic_exchange): Add parameter.
2941         (expand_sync_lock_test_and_set): New prototype.
2942         (expand_atomic_test_and_set, expand_atomic_clear): New prototypes.
2943
2944 2011-11-24  H.J. Lu  <hongjiu.lu@intel.com>
2945
2946         PR target/51134
2947         * config/i386/i386.h (processor_costs): Revert revision 181357.
2948         * config/i386/i386.c (cost models): Likewise.
2949         (core_cost): Likewise.
2950         (promote_duplicated_reg): Likewise.
2951         (promote_duplicated_reg_to_size): Likewise.
2952         (processor_target): Likewise.
2953         (expand_set_or_movmem_via_loop_with_iter): Likewise.
2954         (expand_set_or_movmem_via_loop): Likewise.
2955         (emit_strset): Likewise.
2956         (expand_movmem_epilogue): Likewise.
2957         (expand_setmem_epilogue): Likewise.
2958         (expand_movmem_prologue): Likewise.
2959         (expand_setmem_prologue): Likewise.
2960         (expand_constant_movmem_prologue): Likewise.
2961         (expand_constant_setmem_prologue): Likewise.
2962         (decide_alg): Likewise.
2963         (decide_alignment): Likewise.
2964         (ix86_expand_movmem): Likewise.
2965         (ix86_expand_setmem): Likewise.
2966         (ix86_slow_unaligned_access): Likewise.
2967         * config/i386/i386.md (strset): Likewise.
2968         * config/i386/sse.md (vec_dupv4si): Likewise.
2969         (vec_dupv2di): Likewise.
2970
2971 2011-11-24  Georg-Johann Lay  <avr@gjlay.de>
2972
2973         * config/avr/avr.md (*rotlhi2.15): Set length to 4.
2974
2975 2011-11-24  Razya Ladelsky  <razya@il.ibm.com>
2976
2977         * tree-data-ref.c (initialize_data_dependence_relation): Update
2978         comment for the self dependence case.
2979         (compute_self_dependence): Remove.
2980         * tree-vect-data-refs.c (vect_analyze_data_refs): Remove call to
2981         compute_self_dependenc.
2982
2983 2011-11-24  Alan Modra  <amodra@gmail.com>
2984
2985         * c-decl.c (warn_if_shadowing): Don't warn if shadowed
2986         identifier is from system header.
2987
2988 2011-11-23  Jakub Jelinek  <jakub@redhat.com>
2989
2990         PR target/51261
2991         * config/i386/i386.c (decide_alg): Initialize *dynamic_check
2992         even if !optimize.
2993
2994 2011-11-23  Vladimir Makarov  <vmakarov@redhat.com>
2995
2996         PR rtl-optimization/48455
2997         * doc/invoke.texi (-fira-region): Document default values.
2998
2999         * flags-types.h (enum ira_region): Add new value
3000         IRA_REGION_AUTODETECT.
3001
3002         * common.opt (fira-region): Set up initial value to
3003         IRA_REGION_AUTODETECT.
3004
3005         * toplev.c (process_options): Set up flag_ira_region depending on
3006         -O options.
3007
3008         * ira.c (ira.c): Remove optimize guard for ira_build.
3009
3010 2011-11-23  Chung-Lin Tang  <cltang@codesourcery.com>
3011
3012         PR rtl-optimization/50496
3013         * jump.c (redirect_jump): Assert fail on nlabel == NULL_RTX
3014         only after epilogue is created. Add comments.
3015
3016 2011-11-22  Richard Henderson  <rth@redhat.com>
3017
3018         * config/ia64/ia64.c (ia64_expand_atomic_op): Add model parameter.
3019         Generate the barrier required for the memory model.
3020         (rtx_needs_barrier): Handle UNSPEC_FETCHADD_REL, UNSPEC_CMPXCHG_REL.
3021         * config/ia64/ia64-protos.h: Update.
3022         * config/ia64/ia64.md (UNSPEC_FETCHADD_REL): New.
3023         (UNSPEC_CMPXCHG_REL): New.
3024         * config/ia64/sync.md (mem_thread_fence): New.
3025         (atomic_load<IMODE>, atomic_store<IMODE>): New.
3026         (atomic_compare_and_swap<IMODE>): New.
3027         (cmpxchg_acq_<I124MODE>, cmpxchg_acq_di): New.
3028         (atomic_exchange<IMODE>): New.
3029         (xchg_acq_<IMODE>): Rename from sync_lock_test_and_set<IMODE>.
3030         (atomic_<FETCHOP><IMODE>, atomic_nand<IMODE>): New.
3031         (atomic_fetch_<FETCHOP><IMODE>, atomic_fetch_nand<IMODE>): New.
3032         (atomic_<FETCHOP>_fetch<IMODE>, atomic_nand_fetch<IMODE>): New.
3033         (fetchadd_rel_<I48MODE>): New.
3034         (sync_<FETCHOP><IMODE>, sync_nand<IMODE>): Remove.
3035         (sync_old_<FETCHOP><IMODE>, sync_old_nand<IMODE>): Remove.
3036         (sync_new_<FETCHOP><IMODE>, sync_new_nand<IMODE>): Remove.
3037         (sync_compare_and_swap<IMODE>): Remove.
3038         (sync_lock_release<IMODE>): Remove.
3039
3040         * config/ia64/ia64.md: Use define_c_enum for UNSPEC_*
3041         and UNSPECV_* constants.
3042
3043 2011-11-22  Tom de Vries  <tom@codesourcery.com>
3044
3045         PR rtl-optimization/50764
3046         * sched-deps.c (sched_analyze_insn): Make sure frame-related insns are
3047         not moved past preceding jump.
3048
3049 2011-11-22  Jeff Law  <law@redhat.com>
3050
3051         * doc/contrib.texi: Add entry for David Binderman.
3052
3053 2011-11-22  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
3054
3055         * postreload.c (reload_combine): Mark reg_state as invalid at
3056         volatile insns if there has been a use already.
3057
3058 2011-11-21  Aldy Hernandez  <aldyh@redhat.com>
3059
3060         * opts.c (finish_options): Do not fail for -fgnu-tm.
3061         * gimple-streamer-out.c (output_gimple_stmt): Handle
3062         GIMPLE_TRANSACTION.
3063         * gimple-streamer-in.c (input_gimple_stmt): Same.
3064         * lto-cgraph.c (input_overwrite_node): Read tm_clone bit.
3065         (lto_output_node): Write tm_clone bit.
3066
3067 2011-11-22  Ian Lance Taylor  <iant@google.com>
3068
3069         * doc/install.texi (Configuration): Correct doc of
3070         --enable-build-poststage1-with-cxx: it is not experimental.
3071
3072 2011-11-22  Jakub Jelinek  <jakub@redhat.com>
3073
3074         PR tree-optimization/51074
3075         * fold-const.c (fold_binary_loc): Fix up VEC_INTERLEAVE_*_EXPR
3076         handling for BYTES_BIG_ENDIAN.
3077         * optabs.c (can_vec_perm_for_code_p): Likewise.
3078
3079 2011-11-22  Michael Matz  <matz@suse.de>
3080
3081         PR other/51125
3082         * trans-mem.c (expand_block_tm): Ignore clobbers.
3083
3084 2011-11-22  Iain Sandoe  <iains@gcc.gnu.org>
3085
3086         *  config/darwin.h (ENDFILE_SPEC): New.
3087         (DARWIN_CRT1_SPEC): Add crttms.o.
3088         (STARTFILE_SPEC): Likewise for dynamic libs and bundles.
3089         * config/i386.h (ENDFILE_SPEC): Amend to include crttme.o.
3090
3091 2011-11-22  Michael Matz  <matz@suse.de>
3092
3093         PR c++/51264
3094         * tree.c (iterative_hash_expr): Remove break after return.
3095
3096 2011-11-22  Iain Sandoe  <iains@gcc.gnu.org>
3097
3098         * target.def (tm_clone_table_section): New hook.
3099         * doc/tm.texi.in (TARGET_ASM_TM_CLONE_TABLE_SECTION): Define.
3100         * doc/tm.texi: Regenerate.
3101         * varasm.c (dump_tm_clone_pairs): Use target tm_clone_table_section.
3102         * output.h (default_clone_table_section): New prototype.
3103         * config/darwin.h (TARGET_ASM_TM_CLONE_TABLE_SECTION): New.
3104         * config/darwin-protos.h (darwin_tm_clone_table_section): New prototype.
3105         * config/darwin.c (darwin_tm_clone_table_section): New.
3106
3107 2011-11-21  Torvald Riegel  <triegel@redhat.com>
3108
3109         * trans-mem.c (diagnose_tm_1): Print an expression instead of a
3110         declaration in error messages for indirect calls.
3111
3112 2011-11-21  David S. Miller  <davem@davemloft.net>
3113
3114         * config/sparc/sparc.c (sparc_regmode_natural_size): New function
3115         implementing REGMODE_NATURAL_SIZE taking into consideration vector
3116         modes.
3117         (sparc_modes_tieable_p): Similarly for MODES_TIEABLE_P.
3118         * config/sparc/sparc-protos.h (sparc_regmode_natural_size,
3119         sparc_modes_tieable_p): Declare.
3120         * gcc/config/sparc/sparc.h (REGMODE_NATURAL_SIZE,
3121         MODES_TIEABLE_P): Use new helper functions.
3122
3123         Revert
3124         2011-11-16  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
3125
3126         PR middle-end/50325
3127         * expmed.c (store_bit_field_1): Use extract_bit_field on big
3128         endian targets if the source cannot be exactly covered by word
3129         mode chunks.
3130
3131 2011-11-21  Jakub Jelinek  <jakub@redhat.com>
3132
3133         PR debug/50827
3134         * var-tracking.c (loc_cmp): For ENTRY_VALUEs use ENTRY_VALUE_EXP
3135         macro instead of XEXP.
3136
3137 2011-11-21  Andreas Tobler  <andreast@fgznet.ch>
3138
3139         * configure: Regenerate.
3140
3141 2011-11-21  Georg-Johann Lay  <avr@gjlay.de>
3142
3143         * config/avr/avr.c (output_reload_in_const): Loading a byte with 0
3144         must not affect cc0.
3145         * config/avr/avr.md (*movhi, *movpsi, *movsi, *movsf): Zero to any
3146         register does not change cc0. Same for any constant to ld-register.
3147
3148 2011-11-21  Uros Bizjak  <ubizjak@gmail.com>
3149
3150         * config/i386/mmx.md (unspec) <UNSPEC_MOVNTQ, UNSPEC_PFRCP,
3151         UNSPEC_PFRCPIT1, UNSPEC_PFRCPIT2, UNSPEC_PFRSQRT, UNSPEC_PFRSQIT1>:
3152         Move from config/i386/i386.md
3153         (unspecv) <UNSPECV_EMMS, UNSPECV_FEMMS>: Ditto.
3154         * config/i386/sse.md (unspec) <UNSPEC_MOVNT,UNSPEC_MOVU, UNSPEC_LDDQU,
3155         UNSPEC_PSHUFB, UNSPEC_PSIGN, UNSPEC_PALIGNR, UNSPEC_EXTRQI,
3156         UNSPEC_EXTRQ, UNSPEC_INSERTQI, UNSPEC_INSERTQ, UNSPEC_BLENDV,
3157         UNSPEC_INSERTPS, UNSPEC_DP, UNSPEC_MOVNTDQA, UNSPEC_MPSADBW,
3158         UNSPEC_PHMINPOSUW, UNSPEC_PTEST, UNSPEC_PCMPESTR, UNSPEC_PCMPISTR,
3159         UNSPEC_FMADDSUB, UNSPEC_XOP_UNSIGNED_CMP, UNSPEC_XOP_TRUEFALSE,
3160         UNSPEC_XOP_PERMUTE, UNSPEC_FRCZ, UNSPEC_AESENC, UNSPEC_AESENCLAST,
3161         UNSPEC_AESDEC, UNSPEC_AESDECLAST, UNSPEC_AESIMC,
3162         UNSPEC_AESKEYGENASSIST, UNSPEC_PCLMUL, UNSPEC_PCMP, UNSPEC_VPERMIL,
3163         UNSPEC_VPERMIL2, UNSPEC_VPERMIL2F128, UNSPEC_CAST, UNSPEC_VTESTP,
3164         UNSPEC_VCVTPH2PS, UNSPEC_VCVTPS2PH, UNSPEC_VPERMSI, UNSPEC_VPERMDF,
3165         UNSPEC_VPERMSF, UNSPEC_VPERMTI, UNSPEC_GATHER, UNSPEC_VSIBADDR>: Ditto.
3166         (unspecv) <UNSPECV_LDMXCSR, UNSPECV_STMXCSR, UNSPECV_CLFLUSH,
3167         UNSPECV_MONITOR, UNSPECV_MWAIT, UNSPECV_VZEROALL, UNSPECV_VZEROUPPER>:
3168         Ditto.
3169         * config/i386/sync.md (unspec) <UNSPEC_LFENCE, UNSPEC_SFENCE,
3170         UNSPEC_MFENCE, UNSPEC_MOVA>: Ditto.
3171         (unspecv) <UNSPECV_CMPXCHG_1, UNSPECV_CMPXCHG_2, UNSPECV_CMPXCHG_3,
3172         UNSPECV_CMPXCHG_4, UNSPECV_XCHG, UNSPECV_LOCK>: Ditto.
3173         (sse2_lfence): Move from config/i386/sse.md.
3174         (*sse2_lfence): Ditto.
3175         (sse_sfence): Ditto.
3176         (*sse_sfence): Ditto.
3177         (sse2_mfence): Ditto.
3178         (mfence_sse2): Ditto.  Rename from *sse2_mfence.  Enable also
3179         for TARGET_64BIT.
3180         (mem_thread_fence): Use mfence_sse2.
3181
3182 2011-11-21  Georg-Johann Lay  <avr@gjlay.de>
3183
3184         * config/avr/avr.h (struct base_arch_s): Add field sfr_offset.
3185         * config/avr/avr-devices.c: Ditto. And initialize it.
3186         * config/avr/avr-c.c (avr_cpu_cpp_builtins): New built-in define
3187         __AVR_SFR_OFFSET__.
3188         * config/avr/avr-protos.h (out_movqi_r_mr, out_movqi_mr_r): Remove.
3189         (out_movhi_r_mr, out_movhi_mr_r): Remove.
3190         (out_movsi_r_mr, out_movsi_mr_r): Remove.
3191         * config/avr/avr.md (*cbi, *sbi): Use %i instead of %m-0x20.
3192         (*insv.io, *insv.not.io): Ditto.
3193         * config/avr/avr.c (out_movsi_r_mr, out_movsi_mr_r): Make static.
3194         (print_operand): Implement "%i" to print address as I/O address.
3195         (output_movqi): Clean up call of out_movqi_mr_r.
3196         (output_movhi): Clean up call of out_movhi_mr_r.
3197         (avr_file_start): Use avr_current_arch->sfr_offset instead of
3198         magic -0x20. Use TMP_REGNO, ZERO_REGNO instead of 0, 1.
3199         (avr_out_sbxx_branch): Use %i instead of %m-0x20.
3200         (out_movqi_r_mr, out_movqi_mr_r): Ditto. And make static.
3201         (out_movhi_r_mr, out_movhi_mr_r): Ditto. And use avr_asm_len.
3202         (out_shift_with_cnt): Clean up code: Use avr_asm_len.
3203         (output_movsisf): Use output_reload_insisf for all CONSTANT_P sources.
3204         (avr_out_movpsi): USE avr_out_reload_inpsi for all CONSTANT_P sources.
3205         Clean up call of avr_out_store_psi.
3206         (output_reload_in_const): Don't cut symbols longer than 2 bytes.
3207         (output_reload_insisf): Filter CONST_INT_P or CONST_DOUBLE_P to
3208         try if setting pre-cleared register is advantageous.
3209         (avr_out_plus_1): Use gen_int_mode instead of GEN_INT.
3210
3211 2011-11-20  Joey Ye  <joey.ye@arm.com>
3212
3213         * expr.c (expand_expr_real_1): Correctly handle strict volatile
3214         bitfield loads smaller than mode size.
3215
3216 2011-11-20  Richard Henderson  <rth@redhat.com>
3217
3218         * config/mips/mips.c (mips_init_libfuncs): Call init_sync_libfuncs.
3219
3220 2011-11-20  Uros Bizjak  <ubizjak@gmail.com>
3221
3222         PR target/51235
3223         * config/i386/i386.c (ix86_expand_vcond): Generate TARGET_XOP
3224         patterns for supported mode only.
3225
3226         PR target/51236
3227         * config/i386/i386.c (ix86_expand_builtin)
3228         <IX86_BUILTIN_GATHERALTSIV4DI>: Use CODE_FOR_avx2_gathersiv4di.
3229
3230 2011-11-20  Uros Bizjak  <ubizjak@gmail.com>
3231
3232         * config/i386/i386.md (UNSPEC_MOVNTI): Remove.
3233         (UNSPEC_MOVNTQ): New unspec.
3234         * config/i386/mmx.md (sse_movntq): Rename from sse_movntdi.
3235         Use UNSPEC_MOVNTQ instead of UNSPEC_MOVNT.
3236         * config/i386/sse.md (sse2_movnti<mode>): Use UNSPEC_MOVNT instead of
3237         UNSPEC_MOVNTI.
3238         (STORENT_MODE): Add DI and V4DI modes.
3239
3240 2011-11-20  Nathan Sidwell  <nathan@acm.org>
3241
3242         PR gcov-profile/51113
3243         * coverage.c (build_var): Propagate visibility for public
3244         decls.  Use make_decl_one_only for PIC correctness.
3245
3246         testsuite/
3247         * gcc.misc-tests/gcov-13.c: Check gcovpart-13b coverage
3248         * gcc.misc-tests/gcov-16.c: New.
3249         * gcc.misc-tests/gcov-17.c: New.
3250         * g++.dg/gcov/gcov-8.C: New.
3251         * g++.dg/gcov/gcov-9.C: New.
3252         * g++.dg/gcov/gcov-10.C: New.
3253
3254 2011-11-19  Eric Botcazou  <ebotcazou@adacore.com>
3255
3256         PR rtl-optimization/51187
3257         * reorg.c (relax_delay_slots): Do not consider a jump useless if there
3258         is a barrier between the jump and its target label.
3259
3260 2011-11-19  Patrick Marlier  <patrick.marlier@gmail.com>
3261
3262         PR middle-end/51211
3263         * tracer.c (ignore_bb_p): Don't copy GIMPLE_TRANSACTION.
3264
3265 2011-11-19  Eric Botcazou  <ebotcazou@adacore.com>
3266
3267         * expmed.c (store_bit_field_1): Revert bogus formatting change.
3268
3269 2011-11-19  Richard Earnshaw  <rearnsha@arm.com>
3270
3271         PR target/50493
3272         * config/arm/arm.c (neon_disambiguate_copy): Correctly handle partial
3273         overlap of src and dest operands.
3274
3275 2011-11-19  Iain Sandoe  <iains@gcc.gnu.org>
3276
3277         * config/darwin.h (ASM_DEBUG_SPEC): New.
3278         * config/darwin9.h (ASM_DEBUG_SPEC): New.
3279
3280 2011-11-18  Jan Hubicka  <jh@suse.cz>
3281
3282         * config/i386/i386.c (atom_cost): Disable SSE loop until alignment
3283         issues are fixed.
3284
3285 2011-11-18  Anatoly Sokolov  <aesok@post.ru>
3286
3287         * config/cris/cris.c (cris_function_value_regno_p): Make static.
3288         (TARGET_FUNCTION_VALUE_REGNO_P): Define.
3289         * config/cris/cris.h (FUNCTION_VALUE_REGNO_P): Remove.
3290         * config/cris/cris-protos.h (cris_function_value_regno_p): Remove.
3291
3292 2011-11-18  H.J. Lu  <hongjiu.lu@intel.com>
3293
3294         PR target/33944
3295         * doc/extend.texi: Document __builtin_ia32_movnti64.
3296
3297         * config/i386/emmintrin.h (_mm_stream_si64): New.
3298
3299         * config/i386/i386-builtin-types.def: Add VOID_FTYPE_PLONGLONG_LONGLONG.
3300
3301         * config/i386/i386.c (ix86_builtins): Add IX86_BUILTIN_MOVNTI64.
3302         (bdesc_special_args): Update __builtin_ia32_movnti.  Add
3303         __builtin_ia32_movnti64.
3304         (ix86_expand_special_args_builtin): Handle
3305         VOID_FTYPE_PLONGLONG_LONGLONG.
3306
3307         * config/i386/i386.md (UNSPEC_MOVNTI): New.
3308
3309         * config/i386/sse.md (sse2_movntsi): Renamed to ...
3310         (sse2_movnti<mode>): This.
3311
3312 2011-11-18  Georg-Johann Lay  <avr@gjlay.de>
3313
3314         PR target/49868
3315         * config/avr/avr.h (base_arch_s): Add field n_segments.
3316         (ADDR_SPACE_PGM1, ADDR_SPACE_PGM2, ADDR_SPACE_PGM3,
3317         ADDR_SPACE_PGM4, ADDR_SPACE_PGM5, ADDR_SPACE_PGMX): New address spaces.
3318         (AVR_HAVE_ELPM, AVR_HAVE_ELPMX): New defines.
3319         (INIT_EXPANDERS): New define.
3320         * config/avr/avr-protos.h (avr_mem_pgmx_p): New.
3321         (avr_init_expanders): New.
3322         (avr_emit_movmemhi, avr_out_movmem): New.
3323         (avr_xload_libgcc_p): New.
3324         * config/avr/avr-c.c (avr_register_target_pragmas): Register
3325         address spaces __pgm1, __pgm2,  __pgm3,  __pgm4  __pgm5,  __pgmx.
3326         (avr_cpu_cpp_builtins): Add built-in defines __PGM1,
3327         __PGM2, __PGM3, __PGM4, __PGM5, __PGMX.
3328         * config/avr/avr-devices.c (avr_arch_types): Set field n_segments.
3329
3330         * config/avr/avr.c (AVR_SECTION_PROGMEM): Change define to cover
3331         3 bits instead of just 1.
3332         (xstring_empty, xstring_e, rampz_rtx): New static GTYed variables.
3333         (progmem_section): Change from section to array of sections.
3334         (progmem_section_prefix): New static variable.
3335         (avr_file_start): Print set for __RAMPZ__
3336         (avr_option_override): Move initialization of RTXes from here...
3337         (avr_init_expanders): ...to this new function.
3338         (avr_pgm_segment): New static function.
3339         (avr_decl_pgm_p): Handle error_mark_node.
3340         (avr_mem_pgmx_p, avr_decl_pgmx_p): New static functions.
3341         (avr_out_xload, avr_find_unused_d_reg): New static functions.
3342         (expand_prologue, expand_epilogue): Use rampz_rtx.
3343         (print_operand): Hande CONST_STRING.
3344         (avr_xload_libgcc_p): New static function.
3345         (avr_out_lpm_no_lpmx, avr_out_lpm): Handle ELPM.
3346         (avr_progmem_p): Return 2 for 24-bit flash address space.
3347         (avr_out_sbxx_branch): Clean-up code from ASn macros.
3348         (out_movqi_r_mr, out_movqi_mr_r): Ditto. And recognize RAMPZ's
3349         address and print symbolically.
3350         (avr_asm_named_section, avr_section_type_flags,
3351         avr_encode_section_info, avr_asm_select_section,
3352         avr_addr_space_address_mode, avr_addr_space_pointer_mode,
3353         avr_addr_space_legitimate_address_p, avr_addr_space_convert,
3354         avr_addr_space_legitimize_address): Handle new address spaces.
3355         (avr_output_progmem_section_asm_op): New static function.
3356         (avr_asm_init_sections): Initialize progmem_section[].
3357         (adjust_insn_length): Handle ADJUST_LEN_XLOAD, ADJUST_LEN_MOVMEM.
3358         (avr_const_address_lo16): New static function.
3359         (avr_assemble_integer): Use it to handle 3-byte integers.
3360         (avr_emit_movmemhi, avr_out_movmem): New functions.
3361
3362         * config/avr/predicates.md (nox_general_operand): Handle new
3363         address spaces.
3364         * config/avr/avr.md (unspec): Add UNSPEC_MOVMEM.
3365         (adjust_len): Add xload, movmem.
3366         (SP_ADDR): New define_constants.
3367         (isa): Add "lpm", "lpmx", "elpm", "elpmx".
3368         (enabled): Handle them.
3369         (load<mode>_libgcc): New expander.
3370         (*load.<mode>.libgcc): Rename to load_<mode>_libgcc.
3371         (xload8_A, xload<mode>_A): New insn-and-splits.
3372         (xload_8, xload_<mode>_libgcc, xload_<mode>, loadmem_elpm): New insns.
3373         (mov<mode>): Handle new address spaces.
3374         (movmemhi): Rewrite using avr_emit_movmemhi.
3375         (MOVMEM_r_d): New mode attribute.
3376         (movmem_<mode>, movmem_qi_elpm): New insns.
3377         (setmemhi, *clrmemqi, *clrmemhi, strlenhi, *strlenhi): Unquote
3378         C-code.  Use label instead of hard-coded instrunction lengths.
3379
3380 2011-11-18  Martin Jambor  <mjambor@suse.cz>
3381
3382         PR tree-optimization/50605
3383         * gimple.c (is_gimple_ip_invariant_address): Also handle MEM_REFs
3384         of IPA invariant decls.
3385
3386 2011-11-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
3387
3388         * tree-outof-ssa.c (insert_back_edge_copies):  Add call to
3389         mark_dfs_back_edges.
3390
3391 2011-11-18  Iain Sandoe  <iains@gcc.gnu.org>
3392
3393         PR target/49992
3394         * configure.ac: Remove ranlib special-casing for Darwin.
3395         * configure: Regenerate.
3396
3397 2011-11-18  Uros Bizjak  <ubizjak@gmail.com>
3398
3399         PR tree-optimization/51118
3400         * fold-const.c (fold_checksum_tree): Check for TS_TYPED structure
3401         before using TREE_TYPE accessor on expr.
3402
3403 2011-11-17  Jan Hubicka  <jh@suse.cz>
3404
3405         PR bootstrap/51134
3406         * i386.c (atom_cost): Fix 32bit memset description.
3407         (expand_set_or_movmem_via_loop_with_iter): Output proper bounds check
3408         for epilogue loops.
3409         (expand_movmem_epilogue): Handle epilogues up to size 15 w/o producing
3410         byte loop.
3411         (decide_alg): sse_loop is not useable wthen SSE2 is disabled;
3412         when not optimizing always use rep movsb or lincall; do not produce
3413         word sized loops when optimizing memset for size (to avoid need
3414         for large constants).
3415         (ix86_expand_movmem): Get into sync with ix86_expand_setmem;
3416         choose unroll factors better; always do 128bit moves when producing
3417         SSE loops; do not produce loopy epilogue when size is too small.
3418         (promote_duplicated_reg_to_size): Do not look into desired alignments
3419         when doing vector expansion.
3420         (ix86_expand_setmem): Track better when promoted value is available;
3421         choose unroll factors more sanely. Output loopy epilogue only
3422         when needed.
3423
3424 2011-11-17  Steve Ellcey  <sje@cup.hp.com>
3425
3426         PR middle-end/51144
3427         * output.h (fprint_w): Remove.
3428         * final.c (fprint_w): Remove.
3429         (output_addr_const): Change fprint_w back to fprintf.
3430
3431 2011-11-17  Andrew Pinski  <apinski@cavium.com>
3432
3433         * config/host-linux.c (TRY_EMPTY_VM_SPACE): Define for MIPS.
3434
3435 2011-11-17  Andrew MacLeod  <amacleod@redhat.com>
3436
3437         * builtins.c (expand_builtin): Remove 4th parameter representing
3438         weak/strong mode when __atomic_compare_exchange becomes a library call.
3439
3440 2011-11-17  Richard Henderson  <rth@redhat.com>
3441
3442         * config/rs6000/rs6000.c (rs6000_expand_atomic_compare_and_swap): Get
3443         new pseudo for target after convert_modes.
3444         (rs6000_expand_atomic_exchange, rs6000_expand_atomic_op): Likewise.
3445
3446 2011-11-17  Richard Henderson  <rth@redhat.com>
3447
3448         * config/rs6000/rs6000.c (rs6000_expand_atomic_compare_and_swap): Get
3449         new pseudo for target after convert_modes.
3450         (rs6000_expand_atomic_exchange, rs6000_expand_atomic_op): Likewise.
3451
3452 2011-11-17  Richard Henderson  <rth@redhat.com>
3453
3454         * builtins.c (expand_builtin_mem_thread_fence): Remove.
3455         (expand_builtin_mem_signal_fence): Remove.
3456         (expand_builtin_atomic_thread_fence): Use expand_mem_thread_fence.
3457         (expand_builtin_sync_synchronize): Likewise.
3458         (expand_builtin_atomic_signal_fence): Use expand_mem_signal_fence.
3459         * optabs.c (expand_asm_memory_barrier): Split out from
3460         expand_builtin_mem_signal_fence.
3461         (expand_mem_thread_fence): New, a combination of code from
3462         expand_builtin_mem_thread_fence and expand_builtin_sync_synchronize.