OSDN Git Service

* optabs.h (enum optab_index): Add new OTI_significand.
[pf3gnuchains/gcc-fork.git] / gcc / ChangeLog
1 2009-06-19  Uros Bizjak  <ubizjak@gmail.com>
2
3         * optabs.h (enum optab_index): Add new OTI_significand.
4         (significand_optab): Define corresponding macro.
5         * optabs.c (init_optabs): Initialize significand_optab.
6         * genopinit.c (optabs): Implement significand_optab using
7         significand?f2 patterns.
8         * builtins.c (expand_builtin_mathfn): Handle
9         BUILT_IN_SIGNIFICAND{,F,L}.
10         (expand_builtin): Expand BUILT_IN_SIGNIFICAND{,F,L} using
11         expand_builtin_mathfn if flag_unsafe_math_optimizations is set.
12
13         * config/i386/i386.md (significandxf2, significand<mode>2): New
14         expanders to implement significandf, significand and significandl
15         built-ins as inline x87 intrinsics.
16
17 2009-06-18  Anatoly Sokolov  <aesok@post.ru>
18
19         * config/avr/avr.c (avr_override_options): Remove setting value of
20         PARAM_INLINE_CALL_COST.
21
22 2009-06-18  Richard Henderson  <rth@redhat.com>
23
24         PR 40488
25         * tree-pass.h (TDF_ASMNAME): New.
26         * tree-dump.c (dump_options): Add asmname.
27         * doc/invoke.texi: Document it.
28
29         * tree-pretty-print.c (maybe_dump_asm_name): Merge into...
30         (dump_decl_name): ...here.
31         (dump_function_name): New flags arg; mind TDF_ASMNAME.
32         (dump_generic_node): Update dump_function_name calls.
33         (print_call_name): New flags arg; update all dump calls.
34         * diagnostic.h (print_call_name): Update.
35         * gimple-pretty-print.c (dump_gimple_call): Update.
36
37 2009-06-18  H.J. Lu  <hongjiu.lu@intel.com>
38
39         PR target/40470
40         * config/i386/i386.h (CLASS_LIKELY_SPILLED_P): Add SSE_FIRST_REG.
41
42 2009-06-18  Diego Novillo  <dnovillo@google.com>
43
44         * doc/plugins.texi: Document plugin_is_GPL_compatible.
45         * plugin.c (str_license): Declare.
46         (try_init_one_plugin): Assert that the symbol
47         'plugin_is_GPL_compatible' exists.
48
49 2009-06-18  Sergei Dyshel  <sergeid@il.ibm.com>
50
51         * see.c: Remove.
52         * Makefile.in (OBJS-common): Remove see.o.
53         (see.o): Remove.
54         * common.opt (fsee): Mark as preserved for backward compatibility.
55         * opts.c (common_handle_option): Add OPT_fsee to the backward 
56         compatibility section.
57         * passes.c (init_optimization_passes, pass_see): Remove pass.
58         * timevar.def (TV_SEE): Remove.
59         * tree-pass.h (pass_see): Remove declaration.
60         * doc/invoke.texi (-fsee): Remove documentation.
61         
62 2009-06-18  Martin Jambor  <mjambor@suse.cz>
63
64         * tree-sra.c: Include statistics.h
65         (sra_stats): New variable.
66         (sra_initialize): Clear sra_stats.
67         (create_access_replacement): Increment sra_stats.replacements.
68         (get_access_replacement): Do not return twice.
69         (analyze_all_variable_accesses): Increment statistics counter by the
70         number of scalarized aggregates.
71         (generate_subtree_copies): Increment sra_stats.subtree_copies.
72         (sra_modify_expr): Increment sra_stats.exprs.
73         (load_assign_lhs_subreplacements): Increment sra_stats.subreplacements.
74         (sra_modify_assign): Increment sra_stats.exprs,
75         sra_stats.separate_lhs_rhs_handling and sra_stats.deleted.
76         (perform_intra_sra): Update statistics counters.
77         * Makefile.in (tree-sra.o): Add statistics.h to dependencies.
78
79 2009-06-18  Sandra Loosemore  <sandra@codesourcery.com>
80
81         * config/arm/arm.c (TARGET_SCALAR_MODE_SUPPORTED_P): Redefine.
82         (arm_scalar_mode_supported_p): New function.
83
84 2009-06-18  Paul Brook  <paul@codesourcery.com>
85             Sandra Loosemore  <sandra@codesourcery.com>
86
87         * config/arm/sfp-machine.h (_FP_NANFRAC_H, _FP_NANSIGN_H): Define.
88         (__extendhfsf2, __truncsfhf2): Define.
89         * config/arm/fp16.c: New file.
90         * config/arm/t-bpabi (LIB2FUNCS_STATIC_EXTRA): Add fp16.c.
91         * config/arm/t-symbian (LIB2FUNCS_STATIC_EXTRA):  Add fp16.c.
92
93 2009-06-18  Sandra Loosemore  <sandra@codesourcery.com>
94
95         * doc/extend.texi (Half-Precision): New section.
96         * doc/invoke.texi (Option Summary): List -mfp16-format.
97         (ARM Options): List neon-fp16 as -mfpu value.  Document -mfp16-format.
98         * config/arm/arm.opt (mfp16-format=): New.
99         * config/arm/arm.c: Include intl.h.
100         (TARGET_INVALID_PARAMETER_TYPE): Redefine.
101         (TARGET_INVALID_RETURN_TYPE): Redefine.
102         (TARGET_PROMOTED_TYPE): Redefine.
103         (TARGET_CONVERT_TO_TYPE): Redefine.
104         (arm_fp16_format): Define.
105         (all_fpus): Add entry for neon-fp16.
106         (fp_model_for_fpu): Likewise.
107         (struct fp16_format): Declare.
108         (all_fp16_formats): Define.
109         (arm_init_libfuncs): Add entries for HFmode conversions and arithmetic
110         functions.
111         (arm_override_options): Set arm_fp16_format. Call sorry for fp16
112         and no ldrh.
113         (arm_legitimate_index_p): Treat HFmode like HImode.
114         (thumb1_legitimate_address_p): Make it recognize HFmode constants.
115         (coproc_secondary_reload_class): Special-case HFmode.
116         (arm_print_operand): Add 'z' specifier for vld1.16/vst1.16.
117         (arm_hard_regno_mode_ok): Allow HFmode values in VFP registers.
118         (arm_init_fp16_builtins): New.
119         (arm_init_builtins): Call it.
120         (arm_invalid_parameter_type): New.
121         (arm_invalid_return_type): New.
122         (arm_promoted_type): New.
123         (arm_convert_to_type).
124         (arm_file_start): Deal with neon-fp16 as fpu_name.  Emit tag for fp16
125         format.
126         (arm_emit_fp16_const): New function.
127         (arm_mangle_type): Mangle __fp16 as "Dh".
128         * config/arm/arm.h (TARGET_VFPD32): Make it know about
129         FPUTYPE_NEON_FP16.
130         (TARGET_NEON_FP16): New.
131         (TARGET_NEON): Make it know about FPUTYPE_NEON_FP16.
132         (enum fputype): Add FPUTYPE_NEON_FP16.
133         (enum arm_fp16_format_type): Declare.
134         (arm_fp16_format): Declare.
135         (LARGEST_EXPONENT_IS_NORMAL): Define.
136         * config/arm/arm-protos.h (arm_emit_fp16_const): Declare.
137         * config/arm/arm-modes.def (HFmode): Define.
138         * config/arm/vfp.md: (*movhf_vfp): New.
139         (extendhfsf2): New.
140         (truncsfhf2): New.
141         * config/arm/arm.md: (fpu): Add neon_fp16.
142         (floatsihf2, floatdihf2): New.
143         (fix_trunchfsi2, fix_trunchfdi2): New.
144         (truncdfhf2): New.
145         (extendhfdf2): New.
146         (movhf): New.
147         (*arm32_movhf): New.
148         (*thumb1_movhf): New.
149         (consttable_2): Add check for HFmode constants.
150         (consttable_4): Handle HFmode constants.
151
152 2009-06-18  Uros Bizjak  <ubizjak@gmail.com>
153
154         * convert.c (convert_to_integer): Convert (int)logb() into ilogb().
155
156 2009-06-17  Olivier Hainque  <hainque@adacore.com>
157
158         * collect2.c (main): Use CONST_CAST2 to perform char ** to
159         const char ** conversion in AIX specific section.
160         
161 2009-06-17  H.J. Lu  <hongjiu.lu@intel.com>
162
163         * config/i386/i386.c (ix86_special_builtin_type): Remove
164         UINT64_FTYPE_PINT.  Add UINT64_FTYPE_PUNSIGNED.
165         (bdesc_special_args): Updated.
166         (ix86_init_mmx_sse_builtins): Likewise.
167         (ix86_expand_special_args_builtin): Likewise.
168
169 2009-06-17  Richard Henderson  <rth@redhat.com>
170
171         * tree-pretty-print.c (maybe_dump_asm_name): New.
172         (dump_decl_name): Use it.
173         (PRINT_FUNCTION_NAME): Merge into...
174         (dump_function_name): ... here.  Use maybe_dump_asm_name.
175
176 2009-06-17  Cary Coutant  <ccoutant@google.com>
177
178         * dbxout.c (dbxout_source_line): Add is_stmt parameter.
179         Change caller.
180         * debug.c (struct gcc_debug_hooks): Change placeholder for
181         source_line hook.
182         (debug_nothing_int_charstar_int): Replaced by...
183         (debug_nothing_int_charstar_int_bool): ...this.
184         * debug.h (struct gcc_debug_hooks): Add is_stmt parameter to
185         source_line prototype.
186         (debug_nothing_int_charstar_int): Replaced by...
187         (debug_nothing_int_charstar_int_bool): ...this.
188         * defaults.h (SUPPORTS_DISCRIMINATOR): New constant.
189         * dwarf2out.c (dwarf2out_source_line): Add is_stmt parameter.
190         Output is_stmt operand when necessary.
191         * final.c (final_scan_insn): Pass is_stmt to source_line debug hook.
192         (notice_source_line): Add is_stmt parameter.
193         * sdbout.c (sdbout_source_line): Add is_stmt parameter.
194         * vmsdbgout.c (vmsdbgout_source_line): Add is_stmt parameter.
195         Change callers.
196         * xcoffout.c (xcoffout_source_line): Add is_stmt parameter.
197         * xcoffout.h (xcoffout_source_line): Add is_stmt parameter.
198
199 2009-06-17  Ian Lance Taylor  <iant@google.com>
200
201         * expr.c (struct move_by_pieces_d): Rename from move_by_pieces.
202         Change all uses.
203         (struct store_by_pieces_d): Rename from store_by_pieces.  Change
204         call uses.
205
206 2009-06-17  Adam Nemet  <anemet@caviumnetworks.com>
207
208         * tree.h (STRIP_NOPS, STRIP_SIGN_NOPS,
209         STRIP_USELESS_TYPE_CONVERSION): Use tree_strip_nop_conversions,
210         tree_strip_sign_nop_conversions and
211         tree_ssa_strip_useless_type_conversions rather than stripping
212         the operations here.
213         (tree_strip_nop_conversions, tree_strip_sign_nop_conversions):
214         Declare them.
215         * gimple.h (tree_ssa_strip_useless_type_conversions): Declare it.
216         * tree-ssa.c (tree_ssa_strip_useless_type_conversions): New function.
217         * tree.c (tree_nop_conversion, tree_sign_nop_conversion,
218         tree_strip_nop_conversions, tree_strip_sign_nop_conversions): New
219         functions.
220
221 2009-06-17  Michael Eager  <eager@eagercon.com>
222
223         * config/rs6000/constraints.md (register_constraint "d"): New.
224         * config/rs6000/dfp.md (movsd_store, extendsddd2, extendsdtd2,
225         truncddsd2, *negdd2_fpr, *absdd2_fpr, *nabsdd2_fpr,
226         *movdd_hardfloat32, *movdd_hardfloat64_mfpgpr, *movdd_hardfloat64,
227         *negtd2_fp, *abstd2_fpr, *nabstd2_fpr, *movtd_internal, extendddtd2,
228         trunctddd2, adddd3, addtd3, subdd3, subtd3, muldd3, multd3, divdd3,
229         divtd3, *cmpdd_internal1, *cmptd_internal1, floatditd2, ftruncdd2,
230         fixdddi2, ftrunctd2, fixtddi2): replace 'f' constraint with 'd'
231         * config/rs6000/ppu_intrinsics.h (__mffs, __mtfsf, __mtfsfi, __fabs,
232         __fnabs, __fmadd, __fmsub, __fnmadd, __fnmsub, __fsel, __frsqrte,
233         __fsqrt, __fmul, __fmuls, __frsp, __fcfid, __fctid, __fctidz, __fctiw,
234         __fctiwz): Same.
235         * config/rs6000/rs6000.md (*extendsfdf2_fpr, *truncdfsf2_fpr,
236         *fseldfsf4, *negdf2_fpr, *absdf2_fpr, *nabsdf2_fpr, *adddf3_fpr,
237         *subdf3_fpr, *muldf3_fpr, *divdf3_fpr, recipdf3, fred, sqrtdf2,
238         *fseldfdf4, *fselsfdf4, *floatsidf2_internal, *floatunssidf2_internal,
239         *fix_truncdfsi2_internal, fix_truncdfsi2_internal_gfxopt,
240         fix_truncdfsi2_mfpgpr, fctiwz, btruncdf2, ceildf2, floordf2, rounddf2,
241         stfiwx, floatdidf2, fix_truncdfdi2, floatdisf2_internal1,
242         *movdf_hardfloat32, *movdf_hardfloat64_mfpgpr, *movdf_hardfloat64,
243         *movtf_internal, *extenddftf2_internal, trunctfdf2_internal1,
244         trunctfdf2_internal2, trunctfsf2_fprs, fix_trunc_helper,
245         *fix_trunctfsi2_internal, negtf2_internal, *movdi_internal32,
246         *movdi_mfpgpr, *movdi_internal64, *movdf_update1, *movdf_update2,
247         *cmpdf_internal1, *cmptf_internal1, *cmptf_internal2): Same.
248         * doc/md.texi: Describe PowerPC 'd' constraint, update 'f' constraint.
249
250 2009-06-16  Ian Lance Taylor  <iant@google.com>
251
252         * profile.c (total_num_never_executed): Don't define.
253         (compute_branch_probabilities): Don't count or print
254         num_never_executed.
255         (init_branch_prob): Don't set total_num_never_executed.
256         (end_branch_prob): Don't print total_num_never_executed.
257
258 2009-06-17  David Daney  <ddaney@caviumnetworks.com>
259
260         * jump.c (cleanup_barriers): Handle case of no insns before a barrier.
261
262 2009-06-17  David Edelsohn  <edelsohn@gnu.org>
263
264         * config/rs6000/dfp.md (nabsdd2_fpr): Correct mode.
265         (nabstd2_fpr): Same.
266
267 2009-06-17  Steve Ellcey  <sje@cup.hp.com>
268
269         * expr.c (expand_assignment): Change complex type check.
270
271 2009-06-17  Basile Starynkevitch  <basile@starynkevitch.net>
272
273         * doc/plugins.texi (Building GCC plugins): Added new section. 
274
275 2009-06-17  Ian Lance Taylor  <iant@google.com>
276
277         * c-pch.c (get_ident): Don't set size of templ array.
278         (pch_init): Don't set size of partial_pch array.
279
280         * c-typeck.c (digest_init): If -Wc++-compat, warn about using a
281         string constant to intialize an array whose size is the length of
282         the string.
283
284 2009-06-17  Richard Guenther  <rguenther@suse.de>
285
286         PR tree-optimization/40389
287         * tree-ssa-structalias.c (handle_rhs_call): Restrict NRV case
288         to addressable types.
289         * gimple.c (walk_stmt_load_store_addr_ops): Likewise.
290
291 2009-06-17  Richard Guenther  <rguenther@suse.de>
292
293         PR middle-end/40460
294         * tree-chrec.h (build_polynomial_chrec): If we cannot determine
295         if there is no evolution of left in the loop bail out.
296         * tree-chrec.c (chrec_fold_multiply_poly_poly): CSE one
297         chrec_fold_multiply.
298
299 2009-06-16  J"orn Rennecke  <joern.rennecke@arc.com>
300             Janis Johnson  <janis187@us.ibm.com>
301
302         PR target/39254
303         * config/rs6000/rs6000.c (rs6000_emit_move): Don't emit a USE
304         for the symbol ref of a constant that is the source of a move
305         - nor for any other not-obvious-label-ref constants.
306
307 2009-06-16  Olatunji Ruwase  <tjruwase@google.com>
308
309         * plugin.c (position_pass): Skip newly inserted pass during list
310         traversal to avoid repeated insertion.
311
312 2009-06-16  Ian Lance Taylor  <iant@google.com>
313
314         * vec.h (VEC_stack_alloc): Define different version if
315         GATHER_STATISTICS is defined, to accept and ignore MEM_STAT.
316         (DEF_VEC_ALLOC_FUNC_P_STACK): Remove MEM_STAT_DECL.
317         (DEF_VEC_ALLOC_FUNC_O_STACK): Likewise.
318         (DEF_VEC_ALLOC_FUNC_I_STACK): Likewise.
319
320 2009-06-16  H.J. Lu  <hongjiu.lu@intel.com>
321
322         * config.gcc (extra_headers): Add ia32intrin.h for x86.
323
324         * config/i386/i386.c (ix86_builtins): Add IX86_BUILTIN_BSRSI,
325         IX86_BUILTIN_BSRDI.  IX86_BUILTIN_RDPMC, IX86_BUILTIN_RDTSC.
326         IX86_BUILTIN_RDTSCP.  IX86_BUILTIN_ROLQI, IX86_BUILTIN_ROLHI,
327         IX86_BUILTIN_RORQI and IX86_BUILTIN_RORHI.
328         (ix86_special_builtin_type): Add UINT64_FTYPE_VOID,
329         UINT64_FTYPE_PINT, INT_FTYPE_INT, UINT64_FTYPE_INT,
330         INT64_FTYPE_INT64, UINT16_FTYPE_UINT16_INT and UINT8_FTYPE_UINT8_INT.
331         (bdesc_special_args): Add __builtin_ia32_rdtsc and
332         __builtin_ia32_rdtscp.
333         (bdesc_args): Add __builtin_ia32_bsrsi, __builtin_ia32_bsrdi,
334         __builtin_ia32_rolqi, __builtin_ia32_rolhi, __builtin_ia32_rorqi
335         and __builtin_ia32_rorhi.
336         (ix86_init_mmx_sse_builtins): Handle UINT64_FTYPE_VOID,
337         UINT64_FTYPE_PINT, INT_FTYPE_INT, UINT64_FTYPE_INT,
338         INT64_FTYPE_INT64, UINT16_FTYPE_UINT16_INT and UINT8_FTYPE_UINT8_INT.
339         (ix86_expand_args_builtin): Likewise.
340         (ix86_expand_special_args_builtin): Likewise.
341
342         * config/i386/i386.md (UNSPECV_RDTSCP): New.
343         (UNSPECV_RDTSC): Likewise.
344         (UNSPECV_RDPMC): Likewise.
345         (*bsr): Renamed to ...
346         (bsr): This
347         (*bsr_rex64): Renamed to ...
348         (bsr_rex64): This.
349         (rdpmc): New.
350         (*rdpmc): Likewise.
351         (*rdpmc_rex64): Likewise.
352         (rdtsc): Likewise.
353         (*rdtsc): Likewise.
354         (*rdtsc_rex64): Likewise.
355         (rdtscp): Likewise.
356         (*rdtscp): Likewise.
357         (*rdtscp_rex64): Likewise.
358
359         * config/i386/ia32intrin.h: New.
360
361         * config/i386/x86intrin.h: Include <ia32intrin.h>.
362
363 2009-06-16  Ian Lance Taylor  <iant@google.com>
364
365         * ira-build.c (copy_info_to_removed_store_destinations):
366         Initialize parent_a.
367
368 2009-06-16  Ian Lance Taylor  <iant@google.com>
369
370         * c-decl.c (grokdeclarator): Change size_varies to bool.
371
372 2009-06-16  Ian Lance Taylor  <iant@google.com>
373
374         * sel-sched.c: Make forward declarations of move_op_hooks and
375         fur_hooks explicitly extern.
376
377 2009-06-16  Ian Lance Taylor  <iant@google.com>
378
379         * df-problems.c (df_byte_lr_alloc): Don't set problem_data to itself.
380         * vec.c (vec_gc_o_reserve_1): Don't set alloc to itself.
381
382 2009-06-16  Ian Lance Taylor  <iant@google.com>
383
384         * resource.c (mark_referenced_resources): Change
385         include_delayed_effects parameter to bool.  Change all callers.
386         (mark_end_of_function_resources): Likewise.
387         * reorg.c (insn_references_resource_p): Likewise.
388         (insn_sets_resource_p): Likewise.
389         * resource.h (mark_referenced_resources): Update declaration.
390         (mark_end_of_function_resources): Update declaration.
391
392 2009-06-16  David Edelsohn  <edelsohn@gnu.org>
393
394         * config/rs6000/aix.h (LIBSTDCXX_STATIC): Remove -lstdc++.
395
396 2009-06-16  David Edelsohn  <edelsohn@gnu.org>
397
398         * doc/install.texi (*-*-aix): Update explanation of XLC bootstrap.
399         GCC can bootstrap on AIX with GNU Binutils 2.20.
400
401 2009-06-16  Ian Lance Taylor  <iant@google.com>
402
403         * Makefile.in (tree-vect-stmts.o): Depend upon $(TOPLEV_H).
404
405 2009-06-16  Ian Lance Taylor  <iant@google.com>
406
407         * toplev.h (floor_log2): If GCC_VERSION >= 3004, declare as static
408         inline, not extern inline.
409         (exact_log2): Likewise.
410         * toplev.c (floor_log2): Only define if GCC_VERSION < 3004. Don't
411         test CLZ_HWI.
412         (exact_log2): Likewise, but don't test CTZ_HWI.
413
414 2009-06-16  Ian Lance Taylor  <iant@google.com>
415
416         * bitmap.c (bitmap_clear): Don't declare as inline.
417         * gimple.c (gimplify_assign): Likewise.
418         * tree-ssa-sccvn.c (vn_nary_op_compute_hash): Likewise.
419         * haifa-sched.c (insn_cost): Don't declare with HAIFA_INLINE.
420         (sched_scan_info): Remove duplicate definition.
421
422 2009-06-16  Ian Lance Taylor  <iant@google.com>
423
424         * c-common.c (skip_evaluation): Don't define.
425         (c_inhibit_evaluation_warnings): Define global variable.
426         (overflow_warning): Check c_inhibit_evaluation_warnings rather
427         than skip_evaluation.
428         (convert_and_check, warn_for_div_by_zero): Likewise.
429         * c-common.h (skip_evaluation): Don't declare.
430         (c_inhibit_evaluation_warnings): Declare.
431         * c-parser.c (c_parser_typeof_specifier): Set
432         c_inhibit_evaluation_warnings rather than skip_evaluation.
433         (c_parser_conditional_expression): Likewise.
434         (c_parser_binary_expression): Likewise.
435         (c_parser_sizeof_expression): Likewise.
436         (c_parser_alignof_expression): Likewise.
437         * c-typeck.c (build_indirect_ref): Check
438         c_inhibit_evaluation_warnings rather than skip_evaluation.
439         (build_conditional_expr, build_binary_op): Likewise.
440
441 2009-06-16  Richard Guenther  <rguenther@suse.de>
442
443         * tree-ssa-alias.c (is_escape_site): Remove.
444         * tree-ssa-alias.h (enum escape_type): Remove.
445         (is_escape_site): Likewise.
446         * tree-ssa-structalias.c (find_func_aliases): Handle escapes
447         via casts and asms without deferring to is_escape_site.
448
449 2009-06-16  Jakub Jelinek  <jakub@redhat.com>
450
451         PR middle-end/40446
452         * expr.c (expand_expr_real_1) <case VIEW_CONVERT_EXPR>: Don't
453         use gen_lowpart if op0 has complex mode.
454
455 2009-06-16  Richard Guenther  <rguenther@suse.de>
456
457         * tree-ssa-structalias.c (do_ds_constraint): Stores in global
458         variables add them to ESCAPED.
459         (find_func_aliases): Do not make all indirectly stored values escaped.
460
461 2009-06-16  Rafael Avila de Espindola  <espindola@google.com>
462
463         * config/i386/winnt.c (i386_pe_encode_section_info): Update call to
464         make_decl_one_only.
465
466 2009-06-16  Martin Jambor  <mjambor@suse.cz>
467
468         PR tree-optimization/40432
469         * tree-sra.c (sra_modify_assign): When creating VIEW_CONVERT_EXPR,
470         check whether we need to force gimple register operand.
471
472 2009-06-16  Martin Jambor  <mjambor@suse.cz>
473
474         PR tree-optimization/40413
475         * tree-sra.c (load_assign_lhs_subreplacements): Pass offset to
476         build_ref_for_offset.
477         (propagate_subacesses_accross_link): Fix a typo in a comment.
478
479 2009-06-16  Ira Rosen  <irar@il.ibm.com>
480
481         * tree-parloops.c (loop_parallel_p): Call vect_is_simple_reduction
482         with additional parameter.
483         * tree-vectorizer.h (enum vect_def_type): Add new value
484         vect_nested_cycle.
485         (enum vect_relevant): Add comments.
486         (vect_is_simple_reduction): Add new argument.
487         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Add comments.
488         Detect nested cycles.
489         (vect_is_simple_reduction): Update documentation, add an argument to
490         distinguish inner-loop reduction from nested cycle, detect nested
491         cycles, fix printings and indentation, don't swap operands in case
492         of nested cycle.
493         (get_initial_def_for_reduction): Handle subtraction.
494         (vect_create_epilog_for_reduction): Add new argument to specify
495         reduction variable.
496         (vect_finalize_reduction): Handle subtraction, fix comments.
497         (vectorizable_reduction): Handle nested cycles. In case of nested
498         cycle keep track of the reduction variable position. Call 
499         vect_is_simple_reduction with additional parameter. Use original 
500         statement code in reduction epilogue for nested cycle. Call
501         vect_create_epilog_for_reduction with additional parameter.
502         * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Assert
503         inner-loop vectorization.
504         (vect_recog_widen_sum_pattern): Likewise.
505         * tree-vect-stmts.c (process_use): Distinguish between nested cycles
506         and reductions.
507         (vect_mark_stmts_to_be_vectorized): Likewise.
508         (vect_get_vec_def_for_operand): Handle nested cycles.
509
510 2009-06-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
511
512         * doc/invoke.texi (Debugging Options): Fix option index entries
513         for -fdump-statistics, -frandom-seed add entries for
514         -fdump-tree-original, -fdump-tree-optimized, -frandom-seed.
515         (FRV Options): Fix entries for -mTLS, -mtls.
516         (HPPA Options): Fix entries for -mgnu-ld, -mhp-ld.
517         (i386 and x86-64 Options): Fix entry for -mno-red-zone.
518         (M68hc1x Options): Fix @itemx for -mnominmax.
519         (MCore Options): Fix entry for -mno-lsim.
520         (MMIX Options): Fix entry for -mabi=mmixware.
521         (PDP-11 Options): Fix entry for -mbcopy-builtin.
522
523 2009-06-16  Basile Starynkevitch  <basile@starynkevitch.net>
524
525         * doc/plugins.texi (Interacting with the GCC Garbage Collector):
526         Mention the plugin mode of gengtype.
527         * doc/gty.texi (Source Files Containing Type Information): Likewise.
528         * gengtype.c: Updated copyright.
529         (plugin_files, nb_plugin_files) Added new static variables.
530         (measure_input_list) Care about plugin_files.
531         (write_rtx_next): Added early return in plugin mode.
532         (create_file): Updated copyright year in generated file. Added
533         asserts.
534         (oprintf): Added early return if NULL outf.
535         (get_output_file_with_visibility): Care of plugin_files.
536         (get_output_file_name): May return null.
537         (write_local): Added early return.
538         (put_mangled_filename): Ditto.
539         (finish_root_table): Added check for base_files.
540         (write_roots): Care about null when plugins.
541         (main): Added plugin mode.
542
543 2009-06-15  Ian Lance Taylor  <iant@google.com>
544
545         * df-problems.c (df_simulate_one_insn_forwards): Fix braces in switch.
546         * gcov.c (read_count_file): Add braces around variables declared
547         before label.
548
549         * c.opt (Wjump-misses-init): New warning.
550         * c-opts.c (c_common_handle_option): Set warn_jump_misses_init for
551         -Wall and -Wc++-compat if not already set.
552         (c_common_post_options): Clear warn_jump_misses_init if it was not
553         set.
554         * c-decl.c (struct c_binding): Change type field to a union with
555         new label field.  Make it the first field in the struct.  Update
556         references to type to use u.type instead.
557         (struct c_spot_bindings): Define.
558         (struct c_goto_bindings): Define.
559         (c_goto_bindings_p): Define, along with VECs.
560         (struct c_label_vars): Define.
561         (struct c_scope): Add has_label_bindings field.
562         (bind_label, set_spot_bindings): New static functions.
563         (decl_jump_unsafe, update_spot_bindings): New static functions.
564         (update_label_decls): New static function.
565         (pop_scope): Call update_label_decls.  Don't call c_end_vm_scope.
566         Update binding u.label field to shadowed field.
567         (c_binding_start_stmt_expr): New function.
568         (c_binding_end_stmt_expr): New function.
569         (pushdecl): Don't call c_begin_vm_scope.
570         (make_label): Add defining and p_label_vars parameters.  Change
571         all callers.
572         (lookup_label): Correct test for whether a label has not yet been
573         defined.  Call bind_label rather than bind.
574         (warn_about_goto): New static function.
575         (lookup_label_for_goto): New function.
576         (declare_label): Call bind_label rather than bind.
577         (check_earlier_gotos): New static function.
578         (define_label): Don't give errors about jumping into statement
579         expressions or scopes of variably modified types.  Call
580         set_spot_bindings and check_earlier_gotos.  Call bind_label
581         instead of bind.  Don't set label_context_stack_se or
582         label_context_stack_vm.
583         (c_get_switch_bindings): New function.
584         (c_release_switch_bindings): New function.
585         (c_check_switch_jump_warnings): New function.
586         (start_function): Don't set label_context_stack_se or
587         label_context_stack_vm.
588         (finish_function): Likewise.
589         * c-typeck.c (label_context_stack_se): Don't define.
590         (label_context_stack_vm): Don't define.
591         (c_finish_goto_label): Call lookup_label_for_goto rather than
592         lookup_label.  Don't give errors about jumping into a statement
593         expression or the scope of a variably modified type.  Don't set
594         label_context_stack_se or label_context_stack_vm.
595         (struct c_switch): Remove blocked_stmt_expr and blocked_vm
596         fields.  Add bindings field.
597         (c_start_case): Don't set deleted fields.  Set bindings field.
598         (do_case): Rework order of tests.  Don't check blocked_stmt_expr
599         or blocked_vm.  Call c_check_switch_jump_warnings.
600         (c_finish_case): Don't test blocked_stmt_expr field.  Call
601         c_release_switch_bindings.
602         (c_begin_stmt_expr): Don't increment blocked_stmt_expr in
603         c_switch_stack.  Don't walk label_context_stack_se labels.  Don't
604         set label_context_stack_se.  Call c_bindings_start_stmt_expr.
605         (c_finish_stmt_expr): Don't decrement blocked_stmt_expr in
606         c_switch_stack.  Don't walk label_context_stack_se labels.  Don't
607         set label_context_stack_se.  Call c_bindings_end_stmt_expr.
608         (c_begin_vm_scope, c_end_vm_scope): Don't define.
609         * c-tree.h (C_DECL_UNJUMPABLE_STMT_EXPR): Don't define.
610         (C_DECL_UNDEFINABLE_STMT_EXPR): Don't define.
611         (C_DECL_UNJUMPABLE_VM): Don't define.
612         (C_DECL_UNDEFINABLE_VM): Don't define.
613         (struct c_label_list): Don't define.
614         (struct c_label_context_se): Don't define.
615         (struct c_label_context_vm): Don't define.
616         (struct c_spot_bindings): Declare.
617         (c_bindings_start_stmt_expr): Declare.
618         (c_bindings_end_stmt_expr): Declare.
619         (lookup_label_for_goto): Declare.
620         (c_get_switch_bindings, c_release_switch_bindings): Declare.
621         (c_check_switch_jump_warnings): Declare.
622         (label_context_stack_se, label_context_stack_vm): Don't declare.
623         (c_finish_goto_label): Update declaration.
624         (c_begin_vm_scope, c_end_vm_scope): Don't declare.
625         * doc/invoke.texi (Option Summary): Mention -Wjump-misses-init.
626         (Warning Options): Document -Wjump-misses-init.
627
628 2009-06-15  Jakub Jelinek  <jakub@redhat.com>
629
630         * tree-object-size.c (addr_object_size): Fix a pasto in the last
631         change.
632
633 2009-06-15  Rafael Avila de Espindola  <espindola@google.com>
634
635         * cgraph.c (cgraph_make_node_local): Use DECL_COMDAT_GROUP.
636
637 2009-06-15  Aldy Hernandez  <aldyh@redhat.com>
638
639         * except.c (init_eh): Use BUILTINS_LOCATION when calling build_decl.
640
641 2009-06-15  Aldy Hernandez  <aldyh@redhat.com>
642
643         * tree-eh.c (lower_try_finally_switch): Initialize tf_loc.
644
645 2009-06-15  Rafael Avila de Espindola  <espindola@google.com>
646
647         * cgraphunit.c (cgraph_function_versioning,save_inline_function_body):
648         Use DECL_COMDAT_GROUP instead of DECL_ONE_ONLY.
649         * cgraph.c (cgraph_create_virtual_clone): Use DECL_COMDAT_GROUP.
650         * config/i386/i386.c (ix86_file_end): Compute DECL_COMDAT_GROUP.
651         * dwarf2asm.c (dw2_force_const_mem): Update call to
652         make_decl_one_only.
653         * langhooks-def.h (lhd_comdat_group, LANG_HOOKS_COMDAT_GROUP): Remove.
654         (LANG_HOOKS_DECLS): Remove LANG_HOOKS_COMDAT_GROUP.
655         * langhooks.c (lhd_comdat_group): Remove.
656         * langhooks.h (lang_hooks_for_decls): Remove comdat_group.
657         * tree.h (DECL_COMDAT_GROUP): New.
658         (DECL_ONE_ONLY): Use DECL_COMDAT_GROUP.
659         (tree_decl_with_vis): Add comdat_group. Remove one_only.
660         (make_decl_one_only): Change signature.
661         * varasm.c (get_emutls_init_templ_addr, emutls_decl): Update call to
662         make_decl_one_only.
663         (make_decl_one_only): Change signature.
664         (default_elf_asm_named_section): Use DECL_COMDAT_GROUP.
665
666 2009-06-15  Richard Guenther  <rguenther@suse.de>
667
668         PR middle-end/40439
669         * tree.c (widest_int_cst_value): Fix bootstrap on 32bit HWI hosts.
670
671 2009-06-14  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
672
673         * tree-ssa-math-opts.c: Remove extra divide.
674
675 2009-06-14  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
676
677         * config/s390/s390.md ("bswap<mode>2"): Only available on z900.
678
679 2009-06-14  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
680
681         * passes.c: Add bswap pass.
682         * tree-pass.h: Add pass_optimize_bswap declaration.
683         * tree-ssa-math-opts.c: Include diagnostics.h for print_gimple_stmt.
684         Include rtl.h, expr.h and optabs.h for optab_handler check.
685         (struct symbolic_number, pass_optimize_bswap): New definition.
686         (do_shift_rotate, verify_symbolic_number_p): New functions.
687         (find_bswap_1, find_bswap, execute_optimize_bswap): New functions.
688         (gate_optimize_bswap): New function.
689         * tree.c (widest_int_cst_value): New function.
690         * tree.h (widest_int_cst_value): Prototype added.
691
692 2009-06-14  Steven Bosscher  <steven@gcc.gnu.org>
693
694         * cfgcleanup.c (old_insns_match_p): Remove code to substitute
695         REG_EQUAL/REG_EQUIV notes.
696
697 2009-06-14  Richard Guenther  <rguenther@suse.de>
698
699         PR middle-end/40389
700         * gimple.c (walk_stmt_load_store_addr_ops): The LHS of a call
701         has its address taken if NRV was applied and it is addressable.
702         * tree-ssa-structalias.c (get_constraint_for_address_of): New
703         function split out from ...
704         (get_constraint_for_1): ... here.
705         (handle_rhs_call): Use it to mark the return slot escaped if
706         it is addressable and NRV was applied.
707
708 2009-06-13  Aldy Hernandez  <aldyh@redhat.com>
709
710         * config/rs6000/rs6000-protos.h (altivec_resolve_overloaded_builtin):
711         Change first argument type to location_t.
712         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Same.
713         Do not set input_location.
714         Use loc instead of input_location throughout.
715
716 2009-06-13  Richard Guenther  <rguenther@suse.de>
717
718         PR tree-optimization/40421
719         * tree-predcom.c (should_unroll_loop_p): Remove.
720         (tree_predictive_commoning_loop): Use can_unroll_loop_p.
721
722 2009-06-13  Michael Meissner  <meissner@linux.vnet.ibm.com>
723
724         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
725         Add location argument.
726
727 2009-06-13  Aldy Hernandez  <aldyh@redhat.com>
728
729         * config/alpha/alpha.c (alpha_build_builtin_va_list): Pass location to
730         build_decl.
731         * config/s390/s390.c (s390_build_builtin_va_list): Same.
732         (s390_gimplify_va_arg): Pass location to create_artificial_label.
733         * config/spu/spu-protos.h: Add location to
734         spu_resolve_overloaded_builtin.
735         * config/spu/spu.c (spu_build_builtin_va_list): Pass location to
736         spu_build_builtin_va_list.
737         * config/spu/spu-c.c (spu_resolve_overloaded_builtin): Add location
738         argument.  Pass location to build_function_call_vec.
739         * config/sh/sh.c (sh_build_builtin_va_list): Pass location to
740         build_decl.
741         (emit_fpu_switch): Same.
742         (sh_gimplify_va_arg_expr): Pass location to create_artificial_label.
743         * config/xtensa/xtensa.c (xtensa_build_builtin_va_list): Pass location
744         to build_decl and create_artificial_label.
745         (xtensa_gimplify_va_arg_expr): Same.
746         * config/stormy16/stormy16.c (xstormy16_build_builtin_va_list): Same.
747         (xstormy16_gimplify_va_arg_expr): Same.
748         * config/iq2000/iq2000.c (iq2000_expand_prologue): Same.
749         * config/arm/arm.c (arm_build_builtin_va_list): Same.
750         * config/mips/mips.c (mips_build_builtin_va_list): Same.
751         (mips16_build_function_stub): Same.
752         (mips16_build_call_stub): Same.
753
754 2009-06-13  Richard Earnshaw  <rearnsha@arm.com>
755
756         PR target/40327
757         * arm/constraints.md (Pa, Pb): New constraints.
758         * arm/arm.md (thumb1_addsi3): Support more complex additions.  Add a 
759         split pattern to deal with them.
760
761 2009-06-13  Joerg Sonnenberger  <joerg@britannica.bec.de>
762
763         * doc/invoke.texi: Add missing option -Wp,OPTION in list,
764         fix index entry for -Xpreprocessor.
765
766 2009-06-12  Aldy Hernandez  <aldyh@redhat.com>
767
768         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
769         Add location argument to build_decl call.
770         * config/rs6000/rs6000.c (rs6000_build_builtin_va_list): Same.
771         (rs6000_init_builtins): Same.
772         (spe_init_builtins): Same.
773         (rs6000_gimplify_va_arg): Add location argument to
774         create_artificial_label call.
775
776 2009-06-12  Steven Bosscher  <steven@gcc.gnu.org>
777
778         * timevar.def (TV_COMBINE_STACK_ADJUST): New timevar.
779         * combine-stack-adj.c (pass_stack_adjustments): Use it.
780         * Makefile.in: Fix GGC dependency for gcse.o.
781
782 2009-06-12  Aldy Hernandez  <aldyh@redhat.com>
783
784         * tree-pretty-print.c (dump_generic_node): Dump column numbers.
785         * gimple-pretty-print.c (dump_gimple_stmt): Same.
786         * gimplify.c (gimplify_modify_expr): Set location for GIMPLE_ASSIGNs
787         created.
788         * c-parser.c (c_parser_binary_expression): Use current column while
789         building binary operations.
790         * common.opt (fshow-column): Enable by default.
791         * tree-vrp.c (check_array_ref): Use warning_at.
792         (check_array_bounds): Use location from call back if expr has no
793         location.
794         * tree.h: Add location argument to maybe_fold_*.
795         * tree-ssa-ccp.c (ccp_fold): Pass location to maybe_fold_*.
796         (maybe_fold_offset_to_array_ref): Add location argument and use it.
797         (maybe_fold_offset_to_component_ref): Same.
798         (maybe_fold_offset_to_reference): Same.
799         (maybe_fold_offset_to_address): Same.
800         (maybe_fold_stmt_indirect): Same.
801         (maybe_fold_stmt_addition): Same.
802         (fold_stmt_r): Pass location to maybe_fold_*.
803         (fold_gimple_assign): Same.
804         * c-tree.h: Add location argument to finish_decl,
805         default_function_array_conversion, store_init_value.
806         * c-decl.c (define_label): Use error_at.
807         (c_make_fname_decl): Pass location to finish_decl.
808         (finish_decl): New location argument.
809         (build_compound_literal): Pass location to store_init_value.
810         (grokdeclarator): Pass location to finish_decl.
811         (grokfield): Same.
812         * c-typeck.c (array_to_pointer_conversion): New location argument.
813         (function_to_pointer_conversion): Same.
814         (default_function_array_conversion): Same.
815         (parser_build_unary_op): Pass location to overflow_warning.
816         (parser_build_binary_op): Same.  Use warning_at.
817         (build_unary_op): Pass location to array_to_pointer_conversion.
818         (build_c_cast): Pass location to digest_init.
819         (build_modify_expr): New location argument.
820         (convert_for_assignment): Same.
821         (store_init_value): Same.
822         (digest_init): Same.
823         (output_init_element): Pass location to digest_init and
824         array_to_pointer_conversion.
825         (c_finish_return): Pass location to convert_for_assignment.
826         * gimplify.c (gimplify_conversion): Pass location to
827         maybe_fold_offset_to_address.
828         * tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Pass location
829         to maybe_fold_stmt_addition.
830         * c-omp.c (c_finish_omp_atomic): Pass new location to
831         build_modify_expr.
832         (c_finish_omp_for): Same.
833         * c-common.c (overflow_warning): New argument.
834         * c-common.h: New argument to build_modify_expr, overflow_warning.
835         * c-parser.c (c_parser_declaration_or_fndef): Pass location to
836         finish_decl.
837         (c_parser_initializer): Pass location to
838         default_function_array_conversion.
839         (c_parser_initelt): Same.
840         (c_parser_initval): Same.
841         (c_parser_asm_operands): Same.
842         (c_parser_expr_no_commas): Same.  Pass location to build_modify_expr.
843         (c_parser_conditional_expression): Same.
844         (c_parser_binary_expression): Add location info to stack.  Use it.
845         (c_parser_unary_expression): Pass location to
846         default_function_array_conversion, parser_build_unary_op,
847         build_indirect_ref, c_parser_postfix_expression_after_primary.
848         (c_parser_postfix_expression_after_primary): New location argument.
849         Use it.
850         (c_parser_expression_conv): Pass location to
851         default_function_array_conversion.
852         (c_parser_expr_list): Same.
853         (c_parser_omp_atomic): Same.
854         (c_parser_omp_for_loop): Same.
855         * c-tree.h: (struct c_declarator): Add comment to id_loc.
856         (build_array_declarator): New argument.
857         * c-decl.c (build_array_declarator): Add location argument.
858         (grokdeclarator): Set id_loc for cdk_array.
859         * c-parser.c (c_parser_direct_declarator_inner): Pass location to
860         build_array_declarator.
861         * tree.c (build_omp_clause): Add location argument.
862         * tree.h (OMP_CLAUSE_HAS_LOCATION): New macro.
863         (OMP_CLAUSE_LOCATION): New macro.
864         (struct tree_omp_clause): Add location field.
865         (build_omp_clause): Add argument.
866         * testsuite/gcc.dg/gomp/for-1.c: Fix column.
867         * cp/pt.c (tsubst_omp_for_iterator): Pass location to
868         build_omp_clause.
869         * cp/parser.c (cp_parser_omp_var_list_no_open): Same.
870         (cp_parser_omp_clause_collapse): Same.
871         (cp_parser_omp_clause_default): Same.
872         (cp_parser_omp_clause_if): Same.
873         (cp_parser_omp_clause_nowait): Same.
874         (cp_parser_omp_clause_num_threads): Same.
875         (cp_parser_omp_clause_ordered): Same.
876         (cp_parser_omp_clause_schedule): Same.
877         (cp_parser_omp_clause_untied): Same.
878         (cp_parser_omp_for_loop): Same.
879         (cp_parser_omp_parallel): Pass location to c_split_parallel_clauses.
880         * c-tree.h (c_start_case): Add location argument.
881         (c_process_expr_stmt): Same.
882         (c_finish_goto_*): Same.
883         * tree-parloops.c (initialize_reductions): Pass location to
884         build_omp_clause.
885         (create_parallel_loop): Same.
886         * fortran/trans-openmp.c (gfc_trans_omp_variable_list): Same.
887         (gfc_trans_omp_reduction_list): Same.
888         (gfc_trans_omp_clauses): Same.
889         (gfc_trans_omp_do): Same.
890         * c-typeck.c (c_finish_goto_label): Same.
891         (c_finish_goto_ptr): New location argument.
892         (c_start_case): Same.
893         (emit_side_effect_warnings): Same.
894         (c_process_expr_stmt): Same.
895         (c_finish_stmt_expr): Same.
896         (c_finish_omp_clauses): Use error_at instead of error.
897         * gimplify.c (gimplify_adjust_omp_clauses_1): Pass location to
898         build_omp_clause.
899         * c-omp.c (c_split_parallel_clauses): New location argument.
900         * tree-nested.c (convert_nonlocal_reference_stmt): Pass location
901         to build_omp_clause.
902         (convert_local_reference_stmt): Same.
903         (convert_gimple_call): Same.
904         * c-common.h (c_split_parallel_clauses): New argument.
905         * c-parser.c (c_parser_statement_after_labels): Pass location to
906         c_finish_goto_label.
907         (c_parser_switch_statement): Pass location to c_start_case.
908         (c_parser_for_statement): Pass location to c_finish_expr_stmt,
909         and c_process_expr_stmt.
910         (c_parser_omp_variable_list): Add location argument.
911         (c_parser_omp_clause_collapse): Pass location to build_omp_clause.
912         (c_parser_omp_clause_default): Same.
913         (c_parser_omp_clause_if): Same.
914         (c_parser_omp_clause_num_threads): Same.
915         (-c_parser_omp_clause_ordered): Same.
916         (c_parser_omp_clause_reduction): Pass location to
917         c_parser_omp_variable_list.
918         (c_parser_omp_clause_schedule): Pass location to build_omp_clause.
919         (c_parser_omp_clause_untied): Same.
920         (c_parser_omp_for_loop): Pass location to c_process_expr_stmt.
921         (c_parser_omp_parallel): Pass location to c_split_parallel_clauses.
922
923         * c-tree.h (check_for_loop_decls, undeclared_variable,
924         build_component_ref, build_array_ref, build_external_ref,
925         c_expr_sizeof_expr, c_expr_sizeof_type, parser_build_unary_op,
926         build_conditional_expr, build_compound_expr, c_cast_expr,
927         build_c_cast, build_asm_expr, c_end_compound_stmt, c_finish_stmt_expr,
928         c_finish_return, c_finish_omp_parallel, c_finish_omp_task): New
929         argument.
930         * c-semantics.c (build_stmt): Same.
931         (build_case_label): Same.
932         * c-decl.c (c_finish_incomplete_decl): Pass location on down.
933         (undeclared_variable): New argument.
934         (make_label): Same.
935         (lookup_label): Pass location on down.
936         (define_label): Same.
937         (finish_decl): Same.
938         (build_compound_literal): Same.
939         (finish_struct): Same.
940         (finish_function): Do not set location here.
941         (check_for_loop_decls): New argument.
942         * tree.c (save_expr): Set location.
943         (build_empty_stmt): New argument.
944         * tree.h (build_empty_stmt): New argument to build_empty_stmt.
945         (CAN_HAVE_LOCATION_P): Make sure we have a non empty node.
946         * builtins.c (gimplify_va_arg_expr): Use locations.
947         (expand_builtin_sync_operation): Same.
948         * c-typeck.c (build_component_ref): New argument.
949         (build_array_ref): Same.
950         (build_external_ref): Same.
951         (c_expr_sizeof_expr): Same.
952         (c_expr_sizeof_type): Same.
953         (parser_build_unary_op): Same.
954         (build_conditional_expr): Same.
955         (build_compound_expr): Pass location on down.
956         (build_compound_expr): New argument.
957         (build_c_cast): Same.
958         (c_cast_expr): Same.
959         (build_asm_expr): Same.
960         (c_finish_return): Same.
961         (c_process_expr_stmt): Pass location on down.
962         (c_finish_stmt_expr): New argument.
963         (push_clenaup): Same.
964         (c_finish_omp_parallel): Same.
965         (c_finish_omp_task): Same.
966         * gimplify.c (gimplify_call_expr): Pass location on down.
967         * c-omp.c (c_finish_omp_master): New argument.
968         (c_finish_omp_critical): Same.
969         (c_finish_omp_ordered): Same.
970         (c_finish_omp_barrier): Same.
971         (-c_finish_omp_taskwait): Same.
972         (c_finish_omp_atomic): Same.
973         (c_finish_omp_flush): Same.
974         * tree-inline.c (copy_tree_body_r): Pass location on down.
975         (inline_forbidden_p): Remove use of input_location.
976         * c-gimplify.c (c_build_bind_expr): New argument.
977         * c-common.c (c_common_truthvalue_conversion): Pass location on down.
978         (c_sizeof_or_alignof_type): New argument.
979         (c_alignof_expr): Same.
980         (build_va_arg): Same.
981         (c_add_case_label): Same.
982         * c-common.h (c_sizeof_or_alignof_type, c_alignof_expr,
983         c_sizeof, c_alignof, build_va_arg, build_stmt, build_case_label,
984         c_build_bind_expr, objc_build_selector_expr, objc_build_throw_stmt,
985         c_finish_omp_master, c_finish_omp_critical, c_finish_omp_ordered,
986         c_finish_omp_barrier, c_finish_omp_atomic, c_finish_omp_flush,
987         c_finish_omp_taskwait, c_finish_omp_for, c_split_parallel_clauses):
988         New argument.
989         * stub-objc.c (objc_build_selector_expr): Same.
990         (objc_build_throw_stmt): Same.
991         * c-parser.c (c_parser_declaration_or_fndef): Pass location on down.
992         (c_parser_initelt): Same.
993         (c_parser_compound_statement): Same.
994         (c_parser_compound_statement_nostart): Same.
995         (c_parser_label): Same.
996         (c_parser_statement_after_labels): Same.
997         (c_parser_if_body): Same.
998         (c_parser_else_body): Same.
999         (c_parser_if_statement): Same.
1000         (c_parser_switch_statement): Same.
1001         (c_parser_while_statement): Same.
1002         (c_parser_do_statement): Same.
1003         (c_parser_for_statement): Same.
1004         (c_parser_asm_statement): Same.
1005         (c_parser_conditional_expression): Same.
1006         (c_parser_binary_expression): Same.
1007         (c_parser_cast_expression): Same.
1008         (c_parser_unary_expression): Same.
1009         (c_parser_sizeof_expression): Same.
1010         (c_parser_alignof_expression): Same.
1011         (c_parser_postfix_expression): Same.
1012         (c_parser_expression): Same.
1013         (c_parser_objc_receiver): Same.
1014         (c_parser_omp_variable_list): Same.
1015         (c_parser_omp_structured_block): Same.
1016         (c_parser_omp_atomic): New argument.
1017         (c_parser_omp_barrier): Same.
1018         (c_parser_omp_critical): Same.
1019         (c_parser_omp_flush): Pass location on down.
1020         (c_parser_omp_for_loop): New argument.
1021         (c_parser_omp_for): Same.
1022         (c_parser_omp_master): Same.
1023         (c_parser_omp_ordered): Same.
1024         (c_parser_omp_sections_scope): Same.
1025         (c_parser_omp_sections): Same.
1026         (c_parser_omp_parallel): Same.
1027         (c_parser_omp_single): Same.
1028         (c_parser_omp_task): Same.
1029         (c_parser_omp_taskwait): Pass location on down.
1030         (c_parser_omp_construct): Same.
1031         (c_parser_omp_threadprivate): Same.
1032         * dwarf2asm.c, targhooks.c, optabs.c, tree.c, tree.h, target.h,
1033         builtins.c, omp-low.c, cgraphunit.c, tree-call-cdce.c,
1034         tree-ssa-alias.c, gimple-low.c, c-tree.h, expr.c, tree-parloops.c,
1035         c-decl.c, tree-eh.c, langhooks.c, function.c, stor-layout.c,
1036         c-typeck.c, gimplify.c, c-pragma.c, expmed.c, except.c, coverage.c,
1037         emit-rtl.c, cfgexpand.c, tree-mudflap.c, varasm.c, tree-nested.c,
1038         rtl.h, tree-inline.c, tree-profile.c, c-common.c, c-common.h,
1039         tree-switch-conversion.c, tree-cfg.c, ipa-struct-reorg.c, c-parser.c,
1040         config/i386/i386.c, stmt.c:
1041         Add location argument to the following function definitions and/or
1042         function calls: build_decl, objcp_start_struct, objcp_finish_struct,
1043         start_struct, finish_struct, PUSH_FIELD, create_artificial_label,
1044         cp_make_fname_decl, pushtag, implicitly_declare, c_make_fname_decl,
1045         build_compound_literal, parser_xref_tag, resolve_overloaded_builtin,
1046         do_case, c_finish_bc_stmt, build_compound_literal,
1047         build_function_call.
1048         * c-decl.c (build_compound_literal): Add location argument.
1049         Make all diagnostic calls use location.
1050         (start_struct): Same.
1051         (finish_struct): Same.
1052         (start_enum): Same.
1053         (build_enumerator): Same.
1054         (start_function): Same.
1055         (grokdeclarator): Make all diagnostic calls use location.
1056         (store_parm_decls_oldstyle): Same.
1057         * c-typeck.c (build_function_call): Add location argument.
1058         Make all diagnostic calls use location.
1059         (do_case): Same.
1060         (c_finish_bc_stmt): Same.
1061         * tree-nested.c (get_trampoline_type): Add argument.
1062         Pass location to build_decl.
1063         (lookup_tramp_for_decl): Pass location to get_trampoline_type.
1064         * rtl.h (RTL_LOCATION): New.
1065         * c-common.c (c_add_case_label): Add location argument.
1066         Make all diagnostic calls use location.
1067         * c-common.h: Add location argument to make_fname_decl, do_case,
1068         c_add_case_label, build_function_call, resolve_overloaded_builtin.
1069         * c-parser.c (c_parser_enum_specifier): Rename ident_loc to enum_loc.
1070         Set it appropriately for every case.  Pass enum_loc to start_enum
1071         call.  Pass value_loc first to build_enumerator.  Pass enum_loc to
1072         parser_xref_tag.
1073         (c_parser_struct_or_union_specifier): Save location.  Use it for
1074         start_struct, finish_struct, and parser_xref_tag.
1075
1076 2009-06-12  Ian Lance Taylor  <iant@google.com>
1077
1078         * fold-const.c (fold_unary): Rename local variable and to and_expr.
1079
1080         * c-opts.c (c_common_handle_option): For -Wc++-compat set
1081         cpp_opts->warn_cxx_operator_names.
1082
1083 2009-06-12  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1084
1085         PR tree-opt/38865
1086         * tree-ssa-sccvn.c (visit_reference_op_load): If vn_reference_lookup
1087         is returns NULL and OP is a VCE, look through the VCE.
1088
1089 2009-06-12  Ian Lance Taylor  <iant@google.com>
1090
1091         PR bootstrap/40430
1092         * collect2.c (main): Use CONST_CAST2 in code inside #if
1093         LINK_ELIMINATE_DUPLICATE_LDIRECTORIES.
1094
1095 2009-06-12  Joey Ye  <joey.ye@intel.com>
1096
1097         PR middle-end/39146
1098         * cfgexpand.c (get_decl_align_unit): Update
1099         max_used_stack_slot_alignment with align instead of
1100         stack_alignment_needed.
1101
1102         * function.c (assign_stack_local_1): Update
1103         max_used_stack_slot_alignment with alignment_in_bits instead
1104         of stack_alignment_needed.
1105         (locate_and_pad_parm): Don't update max_used_stack_slot_alignment
1106         here.
1107
1108 2009-06-12  Jakub Jelinek  <jakub@redhat.com>
1109
1110         * dwarf2out.c (last_var_location_insn): New variable.
1111         (dwarf2out_end_epilogue): Clear last_var_location_insn.
1112         (dwarf2out_var_location): Don't record anything after last real
1113         insn.  Only change labels if there were any real instructions
1114         in between last note and this one, or if changed sections.
1115
1116 2009-06-11  Richard Henderson  <rth@redhat.com>
1117
1118         * alpha.c (alpha_expand_prologue): Add a REF_CFA_REGISTER
1119         note when storing the frame pointer in a register.
1120         (FRP): Don't redefine to nothing for epilogue.
1121         (alpha_expand_epilogue): Mark register and sp restores.
1122         (unicosmk_gen_dsib): Don't mark weird frame pointer adjust.
1123
1124         * config/alpha/alpha.c (alpha_emit_setcc): Fix test for
1125         when gen_lowpart is needed.
1126
1127 2009-06-11  Richard Henderson  <rth@redhat.com>
1128
1129         * dwarf2out.c (def_cfa_1): Likewise for DW_CFA_cfa_offset.
1130
1131         * dwarf2out.c (need_data_align_sf_opcode): New.
1132         (div_data_align): Move earlier.
1133         (def_cfa_1, reg_save): Use it.
1134
1135 2009-06-11  H.J. Lu  <hongjiu.lu@intel.com>
1136
1137         * config/i386/i386.c (OPTION_MASK_ISA_CRC32_SET): New.
1138         (OPTION_MASK_ISA_CRC32_UNSET): Likewise.
1139         (ix86_handle_option): Handle OPT_mcrc32.
1140         (ix86_target_string): Add -mcrc32.
1141         (bdesc_args): Enable crc32 builtins with OPTION_MASK_ISA_CRC32.
1142
1143         * config/i386/i386.h (TARGET_CRC32): New.
1144
1145         * config/i386/i386.md (sse4_2_crc32<mode>): Also check TARGET_CRC32.
1146         (sse4_2_crc32di): Likewise.
1147
1148         * config/i386/i386.opt (mcrc32): New.
1149
1150         * doc/invoke.texi: Document -mcrc32.
1151
1152 2009-06-11  Richard Henderson  <rth@redhat.com>
1153
1154         * common.opt (gdwarf-): Accept a version number.
1155         * doc/invoke.texi (gdwarf-): Update docs.
1156         * opth-gen.awk: Special case -gdwarf+ to OPT_gdwarfplus.
1157         * opts.c (common_handle_option) [OPT_gdwarf_]: Verify dwarf
1158         version level, and record it.
1159
1160         * dwarf2.h (DW_CIE_VERSION): Remove.
1161         * dwarf2out.c (DWARF_VERSION): Remove.
1162         (add_fde_cfi): Skip DW_CFA_set_loc addition for dwarf3.
1163         (output_call_frame_info): Use CIE version 3 for dwarf3,
1164         or if the return register column is out of range for version 1.
1165         (dwarf_stack_op_name): Add all dwarf3 values.
1166         (DEBUG_PUBTYPES_SECTION): New.
1167         (size_of_die) [dw_val_class_die_ref]: Handle DW_FORM_ref_addr
1168         encoding change for dwarf3.
1169         (output_die) [dw_val_class_die_ref]: Likewise.
1170         (output_compilation_unit_header): Emit correct version for dwarf3.
1171         (output_line_info): Likewise.
1172         (output_pubnames): Update for DWARF_VERSION removal.
1173         (output_aranges): Likewise.
1174         (gen_subprogram_die): Emit DW_OP_call_frame_cfa if emitting dwarf3.
1175         (dwarf2out_init): Don't ifdef DEBUG_PUBTYPES_SECTION.
1176         (dwarf2out_finish): Likewise.
1177
1178 2009-06-11  David Daney  <ddaney@caviumnetworks.com>
1179
1180         * system.h (gcc_assert, gcc_unreachable): Revert accidental commit
1181         in r148403.
1182
1183 2009-06-11  David Daney  <ddaney@caviumnetworks.com>
1184
1185         PR c/39252
1186         * doc/extend.texi ( __builtin_unreachable): Document new builtin.
1187         * builtins.c (expand_builtin_unreachable): New function.
1188         (expand_builtin): Handle BUILT_IN_UNREACHABLE case.
1189         * builtins.def (BUILT_IN_UNREACHABLE): Add new builtin.
1190         * cfgcleanup.c (try_optimize_cfg): Delete empty blocks with no
1191         successors.
1192         * cfgrtl.c (rtl_verify_flow_info): Handle empty blocks when
1193         searching for missing barriers.
1194
1195 2009-06-11  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1196
1197         * config/darwin.h (LINK_COMMAND_SPEC): Adjust spec to link libcov
1198         when -fprofile-generate* was passed.
1199         * config/darwin9.h (LINK_COMMAND_SPEC): Likewise.
1200
1201 2009-06-11  Anthony Green  <green@moxielogic.com>
1202
1203         * config/moxie/moxie.md: Define length attribute for all instructions.
1204         (rCC): Define.
1205         (*b<cond:code>): Support limited branch ranges for new PC-relative
1206         branch instructions.
1207         * config/moxie/moxie.h (HAS_LONG_UNCOND_BRANCH): Define.
1208
1209 2009-06-11  Jakub Jelinek  <jakub@redhat.com>
1210
1211         * config/i386/i386.c (min_insn_size): Use get_attr_length
1212         for normal insns other than TYPE_MULTI, TYPE_OTHER and TYPE_FCMP.
1213         For __asm return 0.
1214
1215         * config/i386/i386.c (ix86_pad_returns): Use emit_jump_insn_before
1216         instead of emit_insn_before.
1217
1218 2009-06-10  Ian Lance Taylor  <iant@google.com>
1219
1220         PR bootstrap/40408
1221         * graphite.c (add_conditions_to_domain): Change SWITCH_EXPR to
1222         GIMPLE_SWITCH.
1223
1224 2009-06-10  Revital Eres  <eres@il.ibm.com>
1225
1226         * passes.c (init_optimization_passes): Reschedule
1227         predictive-commoning pass before complete unroll pass.
1228
1229 2009-06-10  Martin Jambor  <mjambor@suse.cz>
1230
1231         * cgraph.c (cgraph_node_can_be_local_p): New function.
1232         (cgraph_make_node_local): New function.
1233         * cgraph.h (cgraph_node_can_be_local_p): Declare.
1234         (cgraph_make_node_local): Declare.
1235
1236 2009-06-10  Nathan Froyd  <froydnj@codesourcery.com>
1237
1238         * tree.h (tree_base): Add packed_flag and user_align fields.
1239         Decrease size of spare field.
1240         (TYPE_USER_ALIGN): Use user_align from tree_base.
1241         (DECL_USER_ALIGN): Likewise.
1242         (TYPE_PACKED): Use packed_flag from tree_base.
1243         (DECL_PACKED): Likewise.
1244         (tree_type): Delete packed_flag and user_align fields.  Widen
1245         precision field.  Widen mode field and shuffle fields to align
1246         mode on an 8-bit boundary.
1247         (tree_decl_common): Delete decl_flag_1 and user_align fields.
1248         Renumber decl_flag_* fields.  Fix comments.  Widen
1249         decl_common_unused field.
1250         (DECL_HAS_VALUE_EXPR_P): Adjust for renumbering of decl_flag_* fields.
1251         (DECL_EXTERNAL): Likewise.
1252         (DECL_BIT_FIELD): Likewise.
1253         (DECL_NONADDRESSABLE_P): Likewise.
1254         (TYPE_DECL_SUPRESS_DEBUG): Likewise.
1255         * config/arm/arm-modes.def (XImode): Make it an INT_MODE.
1256
1257 2009-06-10  Ian Lance Taylor  <iant@google.com>
1258
1259         * vec.h (DEF_VEC_ALLOC_I): Use DEF_VEC_NONALLOC_FUNCS_I.
1260         (DEF_VEC_ALLOC_P): Use DEF_VEC_NONALLOC_FUNCS_P.
1261         (DEF_VEC_ALLOC_O): Use DEF_VEC_NONALLOC_FUNCS_O.
1262         (DEF_VEC_ALLOC_FUNC_P): Only define VEC_OP (T,A,alloc).
1263         (DEF_VEC_NONALLOC_FUNCS_P): New macro, broken out of old
1264         DEF_VEC_ALLOC_FUNC_P.
1265         (DEF_VEC_ALLOC_FUNC_O): Only define VEC_OP (T,A,alloc).
1266         (DEF_VEC_NONALLOC_FUNCS_O): New macro, broken out of old
1267         DEF_VEC_ALLOC_FUNC_O.
1268         (DEF_VEC_ALLOC_FUNC_I): Only define VEC_OP (T,A,alloc).
1269         (DEF_VEC_NONALLOC_FUNCS_I): New macro, broken out of old
1270         DEF_VEC_ALLOC_FUNC_I.
1271         (vec_stack_p_reserve, vec_stack_p_reserve_exact): Declare.
1272         (vec_stack_p_reserve_exact_1): Declare.
1273         (vec_stack_o_reserve, vec_stack_o_reserve_exact): Declare.
1274         (vec_stack_free): Declare.
1275         (VEC_stack_alloc): Define.
1276         (DEF_VEC_ALLOC_P_STACK, DEF_VEC_ALLOC_FUNC_P_STACK): Define.
1277         (DEF_VEC_ALLOC_O_STACK, DEF_VEC_ALLOC_FUNC_O_STACK): Define.
1278         (DEF_VEC_ALLOC_I_STACK, DEF_VEC_ALLOC_FUNC_I_STACK): Define.
1279         * vec.c (void_p): New type.  Call DEF_VEC_P and DEF_VEC_ALLOC_P
1280         for void_p.
1281         (stack_vecs): New static variable.
1282         (vec_stack_p_reserve_exact_1): New function.
1283         (vec_stack_o_reserve_1): New static function.
1284         (vec_stack_p_reserve, vec_stack_p_reserve_exact): New functions.
1285         (vec_stack_o_reserve, vec_stack_o_reserve_exact): New functions.
1286         (vec_stack_free): New function.
1287         * df-scan.c (df_ref): Use DEF_VEC_P and DEF_VEC_ALLOC_P_STACK.
1288         (VEC_df_ref_stack_alloc): Define.
1289         (df_mw_hardreg_ptr): New type.  Use DEF_VEC_P and
1290         DEF_VEC_ALLOC_P_STACK.
1291         (VEC_df_mw_hardreg_ptr_stack_alloc): Define.
1292         (struct df_collection_rec): Change _vec fields to VEC.  Remove
1293         _use fields.
1294         (df_free_collection_rec): Adjust for new fields.
1295         (df_insn_rescan): Use new df_collection_rec fields.
1296         (df_notes_rescan, df_canonize_collection_rec): Likewise.
1297         (df_ref_create_structure, df_ref_record): Likewise.
1298         (df_get_conditional_uses, df_get_call_refs): Likewise.
1299         (df_insn_refs_collect, df_bb_refs_collect): Likewise.
1300         (df_bb_refs_record, df_record_entry_block_defs): Likewise.
1301         (df_record_exit_block_uses, df_bb_verify): Likewise.
1302         (df_swap_refs): Change ref_vec parameter to VEC.  Change all callers.
1303         (df_sort_and_compress_refs): Change ref_vec parameter to VEC.
1304         Remove count parameter.  Change return type to void.  Change all
1305         callers.
1306         (df_sort_and_compress_mws): Change mw_vec parameter to VEC.
1307         Remove count parameter.  Change return type to void.  Change all
1308         callers.
1309         (df_install_refs): Change old_vec parameter to VEC.  Remove count
1310         parameter.  Change all callers.
1311         (df_install_mws): Change old_vec parameter to VEC.  Remove count
1312         parameter.  Change all callers.
1313         (df_refs_verify): Change new_rec parameter to VEC.  Change call
1314         callers.
1315         (df_mws_verify): Likewise.
1316
1317 2009-06-10  Alexandre Oliva  <aoliva@redhat.com>
1318
1319         * gcc.c (compare_files): Cast munmap argumento to caddr_t.
1320
1321 2009-06-10  H.J. Lu  <hongjiu.lu@intel.com>
1322
1323         * doc/extend.texi: Add description for __builtin_ia32_crc32di.
1324
1325 2009-06-10  Anthony Green  <green@moxielogic.com>
1326
1327         * config/moxie/crti.asm: New file.
1328         * config/moxie/crtn.asm: New file.
1329         * config/moxie/moxie.c: New file.
1330         * config/moxie/moxie.h: New file.
1331         * config/moxie/sfp-machine.h: New file.
1332         * config/moxie/moxie-protos.h: New file.
1333         * config/moxie/t-moxie: Created.
1334         * config/moxie/t-moxie-softfp: Created.
1335         * config/moxie/moxie.md: Created.
1336         * config/moxie/constraints.md: Created.
1337         * config.gcc: Add moxie support.
1338         * doc/md.texi (Machine Constraints): Add moxie constraints.
1339         * doc/contrib.texi (Contributors): Mention moxie port.
1340         * doc/install.texi (Specific): Mention the moxie port.
1341
1342 2009-06-09  Ian Lance Taylor  <iant@google.com>
1343
1344         * system.h (HAVE_DESIGNATED_INITIALIZERS): Don't define if
1345         compiling with C++.
1346         * optabs.c (optab_table): Only use designated initializers if
1347         HAVE_DESIGNATED_INITIALIZERS is defined.
1348         (convert_optab_table): Likewise.
1349         (init_optabs): Always call init_insn_codes if
1350         HAVE_DESIGNATED_INITIALIZERS is not defined.
1351
1352 2009-06-09  Ian Lance Taylor  <iant@google.com>
1353
1354         * targhooks.c (default_builtin_vectorized_function): Change fn
1355         parameter to unsigned int.
1356         (default_builtin_vectorized_conversion): Change code parameter to
1357         unsigned int.
1358         (default_builtin_reciprocal): Change fn parameter to unsigned int.
1359         * targhooks.h: Update declarations.
1360         * config/rs6000/rs6000.c (rs6000_builtin_conversion): Change code
1361         parameter to unsigned int.
1362
1363         * c-typeck.c (comptypes_check_enum_int): New static function.
1364         (comptypes_internal): Add enum_and_int_p parameter.  Change all
1365         callers.
1366         (comp_target_types): Add location parameter.  Change all callers.
1367         (tagged_types_tu_compatible_p): Add enum_and_int_p parameter.
1368         Change all callers.
1369         (function_types_compatible_p, type_lists_compatible_p): Likewise.
1370         (build_conditional_expr): Add colon_loc parameter.  Change all
1371         callers.
1372         (convert_for_assignment): Add location parameter.  Change all callers.
1373         * c-parser.c (c_parser_conditional_expression): Pass location of
1374         colon to build_conditional_expr.
1375         * c-tree.h (build_conditional_expr): Update declaration.
1376
1377 2009-06-09  Sebastian Pop  <sebastian.pop@amd.com>
1378
1379         * graphite.c: Revert previous patch.
1380
1381 2009-06-09  Sebastian Pop  <sebastian.pop@amd.com>
1382
1383         PR bootstrap/40103
1384         * graphite.c: Remove pragma GCC diagnostic warning "-Wc++-compat".
1385
1386 2009-06-09  Ghassan Shobaki  <ghassan.shobaki@amd.com>
1387
1388         * tree-ssa-loop-prefetch.c
1389         (loop_prefetch_arrays): Fixed a portability problem in printf format
1390         string.
1391
1392 2009-06-09  Martin Jambor  <mjambor@suse.cz>
1393
1394         PR tree-optimization/40351
1395         * tree-sra.c (propagate_subacesses_accross_link): Check that a
1396         refrence to a potential artifical subaccess can be constructed.
1397
1398 2009-06-08  Kaz Kojima  <kkojima@gcc.gnu.org>
1399
1400         * config/sh/sh-protos.h (sh_optimization_options): Declare.
1401         (sh_override_options): Likewise.
1402         * config/sh/sh.c: Include params.h.
1403         (sh_optimization_options): New.
1404         (sh_override_options): Likewise.
1405         * config/sh/sh.c (OPTIMIZATION_OPTIONS): Use sh_optimization_options.
1406         (OVERRIDE_OPTIONS): Use sh_override_options.
1407
1408 2009-06-08  Jakub Jelinek  <jakub@redhat.com>
1409
1410         * dwarf2out.c (emit_cfa_remember): New variable.
1411         (add_fde_cfi): If emit_cfa_remember, recurse to add
1412         DW_CFA_remember_state first.
1413         (dwarf2out_begin_epilogue): Don't add_fde_cfi DW_CFA_remember_state,
1414         instead just set emit_cfa_remember.
1415
1416 2009-06-08  Jan Hubicka  <jh@suse.cz>
1417
1418         PR debug/40126
1419         * dwarf2out.c (dwarf2out_abstract_function): Free decl_loc_table.
1420
1421 2009-06-08  Jan Hubicka  <jh@suse.cz>
1422
1423         PR middle-end/39834
1424         * cgraphunit.c (save_inline_function_body): Do not copy transform
1425         hooks for saved inline bodies.
1426         * ipa-passes.c (do_per_function): Do not add the hoks multiple times
1427         for given function.
1428
1429 2009-06-08  Adam Nemet  <anemet@caviumnetworks.com>
1430
1431         * jump.c (returnjump_p): Handle delayed branches.  Add missing
1432         function comment.
1433
1434 2009-06-08  Jan Hubicka  <jh@suse.cz>
1435
1436         PR middle-end/40102
1437         * cgraph.c (cgraph_create_edge_including_clones): Also asume that the
1438         original node might've been modified.
1439         * tree-inline.c (copy_bb): Do not assume that all clones are the same.
1440
1441 2009-06-08  Jakub Jelinek  <jakub@redhat.com>
1442
1443         * tree-object-size.c (addr_object_size): Add OSI argument.
1444         Handle also INDIRECT_REF with SSA_NAME inside of it as base address.
1445         (compute_builtin_object_size, expr_object_size): Adjust callers.
1446         (plus_stmt_object_size): Call addr_object_size instead of
1447         compute_builtin_object_size.
1448
1449 2009-06-08  Ghassan Shobaki  <ghassan.shobaki@amd.com>
1450             Dwarakanath Rajagopal  <dwarak.rajagopal@amd.com>
1451         
1452         * tree-ssa-loop-prefetch.c 
1453         (gather_memory_references): Introduced a counter for the number of 
1454         memory references.
1455         (anything_to_prefetch_p): Introduced a counter for the number of 
1456         prefetches.
1457         (is_loop_prefetching_profitable): New function with a cost model 
1458         for prefetching.
1459         (loop_prefetch_arrays): Use the new cost model to determine if 
1460         prefetching is profitable.
1461         * params.def (MIN_INSN_TO_PREFETCH_RATIO, 
1462         PREFETCH_MIN_INSN_TO_MEM_RATIO): New parameters.
1463         * params.h (MIN_INSN_TO_PREFETCH_RATIO, 
1464         PREFETCH_MIN_INSN_TO_MEM_RATIO): New parameters.
1465         * doc/invoke.texi (MIN_INSN_TO_PREFETCH_RATIO, 
1466         PREFETCH_MIN_INSN_TO_MEM_RATIO): New parameters.
1467         
1468 2009-06-08  Michael Matz  <matz@suse.de>
1469
1470         PR debug/40012
1471         * cfgexpand.c (set_rtl): Store place also in DECL_RTL, if all
1472         partitions use the same.
1473         (expand_one_var): Deal with DECL_RTL sometimes begin set also
1474         for basevars of SSA_NAMEs.
1475         (expand_used_vars): Reset TREE_USED for basevars of SSA_NAMEs,
1476         to not expand them twice.
1477         (gimple_expand_cfg): Clear DECL_RTL for those decls that have
1478         multiple places.
1479
1480 2009-06-08  Alexandre Oliva  <aoliva@redhat.com>
1481
1482         * common.opt (fcompare-debug=, fcompare-debug-second): New.
1483         (fdump-final-insns=, gtoggle): New.
1484         * doc/invoke.texi: Document them.
1485         * final.c (rest_of_clean_state): Dump final insn stream.
1486         * gcc.c (invoke_as): Hook in -fcompare-debug.
1487         (static_spec_functions): Add compare-debug-dump-opt,
1488         compare-debug-self-opt and compare-debug-auxbase-opt.
1489         (compare_debug, compare_debug_second, compare_debug_opt): New.
1490         (switches_debug_check, n_switches_debug_check): New.
1491         (debug_auxbase_opt, debug_check_temp_file): New.
1492         (process_command): Handle -fno-compare-debug, -fcompare-debug and
1493         -fcompare-debug=*.
1494         (do_self_spec): Handle arguments after switches.
1495         (do_spec_1): Add .gk extension to temp file basenames for compare.
1496         (check_live_switch): Take SWITCH_IGNORE into account, and earlier.
1497         (cc1_options): Use it instead of normal auxbase computation for
1498         the second compare-debug compilation.
1499         (compare_files): New.
1500         (main): Set up and implement compare debug mode.
1501         (compare_debug_dump_opt_spec_function): New.
1502         (compare_debug_self_opt_spec_function): New.
1503         (compare_debug_auxbase_opt_spec_function): New.
1504         * toplev.c (process_options): Handle flag_gtoggle,
1505         flag_dump_final_insns.
1506         * coverage.c (coverage_begin_output): Don't overwrite .gcno file
1507         during -fcompare-debug-second compilation.
1508
1509 2009-06-07  Ian Lance Taylor  <iant@google.com>
1510
1511         * dwarf2.h (enum dwarf_location_atom): Add INTERNAL_DW_OP_tls_addr.
1512         * dwarf2out.c (INTERNAL_DW_OP_tls_addr): Don't #define.
1513
1514         * c-common.c (c_do_switch_warnings): Don't exit early for -Wswitch
1515         with no default node.  Change warning with %H to warning_at.
1516         Don't clear warn_switch around case checking.
1517         * doc/invoke.texi (Warning Options): Clarify distinction between
1518         -Wswitch and -Wswitch-enum.
1519
1520 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
1521
1522         * tree-pass.h (TODO_update_ssa_any): Document internal use only.
1523
1524 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
1525
1526         * gbl-ctors.h: Add header guard.
1527
1528 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
1529
1530         * tree-flow.h (make_value_handle, set_value_handle, sort_vuses,
1531         sort_vuses_heap, vn_lookup_or_add, vn_lookup_or_add_with_stmt,
1532         vn_lookup_or_add_with_vuses, vn_add, vn_add_with_vuses,
1533         vn_lookup_with_stmt, vn_lookup, vn_lookup_with_vuses): Remove
1534         prototypes for removed functions.
1535         (expressions_equal_p): Move to ...
1536         * tree-ssa-sccvn.h: ... here and ...
1537         * matrix-reorg.c: ... adjust includes.
1538
1539 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
1540
1541         * ipa-struct-reorg.c (do_reorg_1): Fix whitespace in dump output.
1542
1543 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
1544
1545         * c-decl.c (finish_decl): Use bool for variable was_incomplete.
1546         (finish_function): Remove erroneous whitespace.
1547
1548 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
1549
1550         * tree-cfg.c (gimple_merge_blocks): Commentary typo fix.
1551         (verify_stmts): Print statement who's gimple_bb is set to a wrong BB
1552
1553 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
1554
1555         * errors.c (internal_error): Commentary typo fix.
1556         * gimple-iterator.c (gsi_insert_seq_on_edge): Ditto.
1557         * tree-ssa-pre.c: Ditto.
1558
1559 2009-06-07  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
1560
1561         * basic-block.h (ENTRY_BLOCK, EXIT_BLOCK): Document that neither of
1562         them is supposed to hold actual statements.
1563
1564 2009-06-06  Ian Lance Taylor  <iant@google.com>
1565
1566         * doc/extend.texi (Attribute Syntax): Document that C++ labels on
1567         empty statements can now have attributes.
1568
1569 2009-06-05  Shujing Zhao  <pearly.zhao@oracle.com>
1570
1571         * config/mips/mips.c: Use REG_P and CONST_INT_P where applicable.
1572         * config/mips/mips.md: Ditto.
1573
1574 2009-06-05  Nathan Froyd  <froydnj@codesourcery.com>
1575
1576         * config/rs6000/eabi.asm (__eabi_convert): Don't define if
1577         _RELOCATABLE.
1578         (__eabi_uconvert): Likewise.
1579
1580 2009-06-05  Nathan Froyd  <froydnj@codesourcery.com>
1581
1582         * config/rs6000/ppc-asm.h: Protect auto-host.h inclusion and
1583         CFI_* definitions with IN_GCC.
1584
1585 2009-06-05  David Edelsohn  <edelsohn@gnu.org>
1586
1587         * xcoffout.h (xcoffout_source_line): Update prototype.
1588
1589 2009-06-05  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
1590
1591         * builtins.c (do_mpc_ckconv, do_mpc_arg1): Use
1592         mpc_realref/mpc_imagref instead of MPC_RE/MPC_IM.
1593
1594 2009-06-05  Jakub Jelinek  <jakub@redhat.com>
1595
1596         PR middle-end/40340
1597         * tree-ssa-live.c (remove_unused_scope_block_p): Don't prune
1598         inlined_function_outer_scope_p blocks for artificial inlines
1599         even at -g0/-g1.
1600         * tree.c (tree_nonartificial_location): Rewrite using
1601         block_nonartificial_location.
1602
1603 2009-06-05  Revital Eres  <eres@il.ibm.com>
1604             Leehod Baruch  <leehod@il.ibm.com>
1605
1606         * expr.c (expand_assignment): Expand MISALIGNED_INDIRECT_REF.
1607         (expand_expr_real_1): Remove comment.
1608         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment):
1609         Vectorize misaligned access when the target supports it.
1610         (vect_supportable_dr_alignment): Check for unaligned access support.
1611         * tree-vect-stmts.c (vectorizable_store): Generate misaligned store
1612         and remove asset.
1613
1614 2009-06-05  Julian Brown  <julian@codesourcery.com>
1615
1616         * config/arm/ieee754-df.S (cmpdf2): Avoid writing below SP.
1617         * config/arm/ieee754-sf.S (cmpsf2): Likewise.
1618
1619 2009-06-05  Richard Guenther  <rguenther@suse.de>
1620
1621         PR bootstrap/40350
1622         * dwarf2out.c (dwarf2out_begin_function): Mark discriminator
1623         as possibly unused.
1624
1625 2009-06-05  Jakub Jelinek  <jakub@redhat.com>
1626
1627         * config/s390/s390.c (global_not_special_regno_p): New static inline.
1628         (save_gprs): Don't tell unwinder when a global register is saved.
1629         (s390_emit_epilogue): Emit needed epilogue unwind info.
1630
1631 2009-06-05  Alexandre Oliva  <aoliva@redhat.com>
1632
1633         * dwarf2out.c (deferred_asm_name): New.
1634         (add_name_and_src_coords_attributes): Defer creation of
1635         DW_AT_MIPS_linkage_name attribute if DECL_ASSEMBLER_NAME was not
1636         computed yet.
1637         (move_linkage_attr): New.
1638         (dwarf2out_finish): Revisit deferrals and emit attributes at the
1639         right place.
1640
1641 2009-06-05  Alexandre Oliva  <aoliva@redhat.com>
1642
1643         * tree-nested.c (finalize_nesting_tree_1): Declare the
1644         frame_decl in the binding tree.
1645
1646 2009-06-04  Cary Coutant  <ccoutant@google.com>
1647
1648         * basic-block.h (struct basic_block_def): Add discriminator field.
1649         * dbxout.c (dbxout_source_line): Add new parameter.  Change all
1650         callers.
1651         * debug.c (do_nothing_debug_hooks): Add additional entry.
1652         (debug_nothing_int_charstar_int): New function.
1653         * debug.h (struct gcc_debug_hooks): Add parameter to source_line hook.
1654         (debug_nothing_int_charstar_int): New declaration.
1655         * dwarf2out.c (dwarf2out_source_line): Add new parameter.  Write
1656         discriminator value in .loc directive.
1657         * final.c (last_discriminator): New variable.
1658         (discriminator): New variable.
1659         (final_start_function): Initialize above variables, pass current
1660         discriminator to debug hook.
1661         (notice_source_line): Check for discriminator change.
1662         * gimple-pretty-print.c (dump_bb_header): Print discriminator value.
1663         * sdbout.c (sdbout_source_line): New parameter.
1664         * tree-cfg.c (struct locus_discrim_map): New structure type.
1665         (discriminator_per_locus): New hash table.
1666         (build_gimple_cfg): Allocate and free discriminator hash table.
1667         (make_edges): Call assign_discriminator.
1668         (locus_map_hash): New function.
1669         (locus_map_eq): New function.
1670         (next_discriminator_for_locus): New function.
1671         (same_line_p): New function.
1672         (assign_discriminator): New function.
1673         (make_cond_expr_edges): Call assign_discriminator.
1674         (make_gimple_switch_edges): Likewise.
1675         (first_non_label_stmt): New function.
1676         * vmsdbgout.c (vmsdbgout_source_line): Add new parameter.  Change
1677         all callers.
1678         * xcoffout.c (xcoffout_source_line): Add new parameter.
1679
1680         * configure.ac (gcc_cv_as_discriminator): New configury check for
1681         gas support for discriminator.
1682         * configure: Regenerate.
1683         * config.in: Regenerate.
1684
1685 2009-06-04  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
1686
1687         * config/arm/arm.c (thumb2_legitimate_index_p): Initialize
1688         val after checking for integers.
1689
1690 2009-06-04  Uros Bizjak  <ubizjak@gmail.com>
1691
1692         * config/i386/i386.h (X86_64_MS_REGPARM_MAX): Rename from
1693         X64_REGPARM_MAX.
1694         (REGPARM_MAX): Use X86_64_MS_REGPARM_MAX.
1695         (X86_64_MS_SSE_REGPARM_MAX): Rename from X64_SSE_REGPARM_MAX.
1696         (SSE_REGPARM_MAX): Use X86_64_MS_SSE_REGPARM_MAX.
1697         * config/i386/i386.c: Use X86_64_MS_REGPARM_MAX instead of
1698         X64_REGPARM_MAX.  Use X86_64_MS_SSE_REGPARM_MAX instead of
1699         X64_SSE_REGPARM_MAX.
1700         * config/i386/i386.md: Use X86_64_MS_SSE_REGPARM_MAX instead of
1701         X64_SSE_REGPARM_MAX.
1702
1703 2009-06-04  Alexandre Oliva  <aoliva@redhat.com>
1704
1705         * gcc.c (report_times_to_file): New.
1706         (execute): Implement it.
1707         (process_command): Support -time=.
1708         * doc/invoke.texi: Document it.
1709
1710 2009-06-04  Alexandre Oliva  <aoliva@redhat.com>
1711
1712         * tree-ssa-live.c (remove_unused_scope_block_p): Keep variables
1713         that have value exprs.
1714
1715 2009-06-04  Alexandre Oliva  <aoliva@redhat.com>
1716
1717         * dwarf2asm.c (dw2_force_const_mem): Defer creation of
1718         declarations for constants until...
1719         (dw2_output_indirect_constant_1): ... this point.
1720
1721 2009-06-04  Richard Earnshaw  <rearnsha@arm.com>
1722
1723         PR target/10242
1724         * arm.md (arm_addsi3): Don't try to split an add with an
1725         eliminable register until after reload has completed.
1726
1727 2009-06-03  Ian Lance Taylor  <iant@google.com>
1728
1729         * dummy-checksum.c (executable_checksum): Use EXPORTED_CONST.
1730         * genattrtab.c (write_length_unit_log): Likewise.
1731         * genchecksum.c (dosum): Likewise.
1732         * gengtype.c (write_rtx_next): Likewise.
1733         (finish_root_table, write_roots): Likewise.
1734         * gimple.c (gimple_ops_offset_): Likewise.
1735         * tree-nomudflap.c (gt_ggc_r_gt_tree_mudflap_h): Likewise.
1736         * config/arc/arc.c (arc_attribute_table): Likewise.
1737         * config/arm/arm.c (arm_attribute_table): Likewise.
1738         * config/avr/avr.c (avr_attribute_table): Likewise.
1739         * config/crx/crx.c (crx_attribute_table): Likewise.
1740         * config/m32r/m32r.c (m32r_attribute_table): Likewise.
1741         * config/m68hc11/m68hc11.c (m68hc11_attribute_table): Likewise.
1742         * config/mcore/mcore.c (mcore_attribute_table): Likewise.
1743         * config/rs6000/rs6000.c (rs6000_attribute_table): Likewise.
1744         * config/sh/sh.c (sh_attribute_table): Likewise.
1745         * config/sparc/sparc.c (sparc_attribute_table): Likewise.
1746         * config/spu/spu.c (spu_attribute_table): Likewise.
1747         * config/v850/v850.c (v850_attribute_table): Likewise.
1748
1749         * config/alpha/alpha.c (vms_attribute_table): Make static.
1750         * config/bfin/bfin.c (bfin_attribute_table): Likewise.
1751         * config/h8300/h8300.c (h8300_attribute_table): Likewise.
1752         * config/mips/mips.c (mips_attribute_table): Likewise.
1753
1754         * Makefile.in (dummy-checksum.o): Depend upon $(CONFIG_H) and
1755         $(SYSTEM_H).
1756         (cc1-checksum.o): Likewise.
1757
1758 2009-06-03  Steve Ellcey  <sje@cup.hp.com>
1759
1760         * config/ia64/vect.md (*movv2sf_internal): Handle big endian case.
1761
1762 2009-06-03  Jakub Jelinek  <jakub@redhat.com>
1763
1764         * config/rs6000/rs6000.c (rs6000_emit_stack_reset): Return generated
1765         insn if it is changing sp.  Use gen_add3_insn instead of
1766         conditionally gen_addsi3 and gen_adddi3.
1767         (offset_below_red_zone_p): New static inline function.
1768         (rs6000_emit_epilogue): Emit needed epilogue unwind info.
1769         Use gen_add3_insn instead of conditionally gen_addsi3 and gen_adddi3.
1770         * config/rs6000/ppc-asm.h: Include auto-host.h.
1771         (CFI_STARTPROC, CFI_ENDPROC, CFI_DEF_CFA_REGISTER, CFI_OFFSET,
1772         CFI_RESTORE): Define.
1773         * config/rs6000/crtresxgpr.asm: Add unwind info.
1774         * config/rs6000/crtresxfpr.asm: Likewise.
1775         * config/rs6000/crtresgpr.asm: Likewise.
1776         * config/rs6000/crtresfpr.asm: Likewise.
1777         * config/rs6000/crtsavgpr.asm: Likewise.
1778         * config/rs6000/crtsavfpr.asm: Likewise.
1779
1780         * dwarf2out.c (output_cfi_directive): Pass 1 instead of 0 to second
1781         argument of DWARF2_FRAME_REG_OUT macros.
1782
1783 2009-06-03  Julian Brown  <julian@codesourcery.com>
1784
1785         * config/arm/arm.c (arm_hard_regno_mode_ok): Permit values of four
1786         words or less (including TImode) in core registers.
1787
1788 2009-06-03  Richard Guenther  <rguenther@suse.de>
1789
1790         PR middle-end/40328
1791         * fold-const.c (fold_convert): Fold the build COMPLEX_EXPR.
1792
1793 2009-06-03  Andrey Belevantsev  <abel@ispras.ru>
1794
1795         * statistics.c (statistics_counter_event): Do not record event 
1796         in pass dump if its number == -1.
1797         (curr_statistics_hash): Add assert that we never get passes 
1798         with static number == -1.
1799
1800 2009-06-03  Richard Guenther  <rguenther@suse.de>
1801             Andrey Belevantsev  <abel@ispras.ru>
1802
1803         * cfgexpand.c (discover_nonconstant_array_refs_r): Make only 
1804         non-BLKmode arrays addressable.
1805
1806 2009-06-03  Maxim Kuvyrkov  <maxim@codesourcery.com>
1807
1808         * config/m68k/linux.h (HAVE_GAS_BALIGN_AND_P2ALIGN): Move to ...
1809         * config/m68k/m68k.h: ... here.
1810         * testsuite/gcc.dg/falign-labels.c (dg-options): Don't restrict for
1811         m68k and fido.
1812
1813 2009-06-03  Martin Jambor  <mjambor@suse.cz>
1814
1815         PR tree-optimization/40323
1816         * ipa-prop.c (get_ssa_def_if_simple_copy): Break if not single
1817         assignment.
1818
1819 2009-06-03  Richard Guenther  <rguenther@suse.de>
1820
1821         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Use DECL_SIZE
1822         consistently.
1823
1824 2009-06-03  Shujing Zhao  <pearly.zhao@oracle.com>
1825
1826         * config/sh/predicates.md: Use REG_P, MEM_P, CONST_INT_P, LABEL_P,
1827         JUMP_P, CALL_P, NONJUMP_INSN_P, NOTE_P, BARRIER_P and
1828         JUMP_TABLE_DATA_P where applicable.
1829         * config/sh/sh.c: Ditto.
1830         * config/sh/sh.h: Ditto.
1831         * config/sh/sh.md: Ditto.
1832         * config/sh/symbian.c: Ditto.
1833
1834 2009-06-03  Uros Bizjak  <ubizjak@gmail.com>
1835
1836         * config/i386/driver-i386.c (describe_cache): Optimize
1837         concatenation of strings.  Use snprintf instead of sprintf.
1838         (host_detect_local_cpu): Ditto.  Ignore -march and -mtune for native
1839         target when not compiling with GCC.
1840
1841 2009-06-02  Kaz Kojima  <kkojima@gcc.gnu.org>
1842
1843         * config/sh/sh.c: Revert last change.
1844         (sh_expand_epilogue): Emit a blockage insn before the frame
1845         pointer adjustment unconditionally.
1846
1847 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
1848
1849         * config/pa/pa-hpux.h (LINK_SPEC): Remove "%<fwhole-program".
1850         * config/pa/pa-hpux10.h (LINK_SPEC): Likewise.
1851         * config/pa/pa-hpux11.h (LINK_SPEC): Likewise.
1852         * gcc.c (set_collect_gcc_options): Don't add -fwhole-program
1853         to COLLECT_GCC_OPTIONS.
1854
1855 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
1856
1857         * collect2.c (target_system_root): New variable.
1858         (main): Handle --sysroot=.
1859         (ignore_library): Strip the sysroot from the library path.
1860
1861 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
1862
1863         * Makefile.in (COLLECT2_OBJS): Add collect2-aix.o.
1864         (collect2.o): Depend on collect2-aix.h.
1865         (collect2-aix.o): New rule.
1866         * collect2-aix.h: New file.
1867         * collect2-aix.c: Likewise.
1868         * collect2.c: Include collect2-aix.h.  Don't undefine
1869         OBJECT_FORMAT_COFF if CROSS_AIX_SUPPORT is defined.
1870         Guard native includes with #ifndef CROSS_DIRECTORY_STRUCTURE.
1871         Use TARGET_AIX_VERSION instead of _AIX51.
1872         * config/rs6000/aix43.h (TARGET_AIX_VERSION): Define.
1873         * config/rs6000/aix51.h (TARGET_AIX_VERSION): Likewise.
1874         * config/rs6000/aix52.h (TARGET_AIX_VERSION): Likewise.
1875         * config/rs6000/aix53.h (TARGET_AIX_VERSION): Likewise.
1876         * config/rs6000/aix61.h (TARGET_AIX_VERSION): Likewise.
1877
1878 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
1879
1880         * collect2.c (ignore_library): Avoid premature post-increment
1881         and null deference.
1882
1883 2009-06-02  Richard Sandiford  <r.sandiford@uk.ibm.com>
1884
1885         * Makefile.in (libgcc.mvars): Add TARGET_SYSTEM_ROOT.
1886         * config/rs6000/aix.h (LINK_SYSCALLS_SPEC): Add %R to the
1887         !CROSS_DIRECTORY_STRUCTURE alternative and use it for
1888         CROSS_DIRECTORY_STRUCTURE too.
1889         (LINK_LIBG_SPEC): Likewise.
1890         (LIB_SPEC): Add %R to sysroot paths.
1891         * config/rs6000/aix43.h (CPP_SPEC): Add %R to sysroot paths.
1892         (CPLUSPLUS_CPP_SPEC, LIB_SPEC): Likewise.
1893         * config/rs6000/aix51.h: As for aix43.h.
1894         * config/rs6000/aix52.h: Likewise.
1895         * config/rs6000/aix53.h: Likewise.
1896         * config/rs6000/aix61.h: Likewise.
1897         * config/rs6000/t-aix52 (SHLIB_LINK): Add $(TARGET_SYSTEM_ROOT)
1898         to the beginning of sysroot paths.
1899
1900 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
1901
1902         * print_rtl (print_rtx): Don't print modes in EXPR_LISTs and
1903         INSN_LISTs that are out of the REG_NOTE range.
1904
1905 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
1906
1907         * loop-unroll.c (struct iv_to_split): Add pointer to next.
1908         (struct var_to_expand): Likewise.
1909         (struct opt_info): Add head and tail for linked lists of the above.
1910         (analyze_insn_to_expand_var): Initialize next.
1911         (analyze_iv_to_split_insn): Likewise.
1912         (analyze_insns_in_loop): Create linked lists.
1913         (allocate_basic_variable): Simplify for use without hash table.
1914         (insert_var_expansion_initialization): Likewise, make it type-safer.
1915         (combine_var_copies_in_loop_exit): Likewise.
1916         (apply_opt_in_copies): Walk lists rather than hash tables.
1917         (release_var_copies): Simplified and inlined by hand into...
1918         (free_opt_info): ... this function.
1919
1920 2009-06-02  Richard Guenther  <rguenther@suse.de>
1921
1922         * tree-ssa-sccvn.c (copy_reference_ops_from_ref): Use DECL_SIZE
1923         for field decls.
1924
1925 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
1926
1927         * cfgexpand.c (gimple_expand_cfg): Discard the source location
1928         only for builtins that are not overridden.
1929
1930 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
1931
1932         * gengtype.c (adjust_field_rtx_def): Add NOTE_INSN_DELETED_LABEL's
1933         label string.
1934
1935 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
1936
1937         * df-core.c (df_ref_debug): Honor -fdump-noaddr.
1938
1939 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
1940
1941         * combine.c (move_deaths): Compare LUIDs within the same BB only.
1942
1943 2009-06-02  Alexandre Oliva  <aoliva@redhat.com>
1944
1945         * common.opt (fdump-unnumbered-links): New.
1946         * doc/invoke.texi (-fdump-unnumbered-links): Document it.
1947         * print-rtl.c (flag_dump_unnumbered_links): New.
1948         (print_rtx): Test it.
1949
1950 2009-06-02  Richard Earnshaw  <rearnsha@arm.com>
1951
1952         * arm.c (arm_get_frame_offsets): Prefer using r3 for padding a
1953         push/pop multiple to 8-byte alignment.
1954
1955 2009-06-01  Jakub Jelinek  <jakub@redhat.com>
1956
1957         * config/i386/i386.c (queued_cfa_restores): New static variable.
1958         (ix86_add_cfa_restore_note, ix86_add_queued_cfa_restore_notes): New
1959         functions.
1960         (pro_epilogue_adjust_stack): Call ix86_add_queued_cfa_restore_notes.
1961         (ix86_emit_restore_reg_using_pop): Add RED_OFFSET argument.
1962         Set RTX_FRAME_RELATED_P immediately after adding a REG_CFA_* note.
1963         Call ix86_add_cfa_restore_note instead of adding REG_CFA_OFFSET
1964         note unconditionally.
1965         (ix86_emit_restore_regs_using_mov): Likewise.
1966         (ix86_emit_restore_sse_regs_using_mov): Likewise.
1967         (ix86_emit_restore_regs_using_pop): Add RED_OFFSET argument, pass
1968         it through to ix86_emit_restore_reg_using_pop.
1969         (ix86_emit_leave): Add RED_OFFSET argument.  Call
1970         ix86_add_queued_cfa_restore_notes.  Call ix86_add_cfa_restore_note
1971         instead of adding REG_CFA_OFFSET note unconditionally.
1972         (ix86_expand_epilogue): Compute RED_OFFSET, pass it down to
1973         the above functions.  Call ix86_add_queued_cfa_restore_notes when
1974         needed.
1975
1976         * dwarf2out.c (dwarf2out_cfi_label): Add FORCE argument, if true,
1977         force output of the label even for dwarf2out_do_cfi_asm.
1978         (add_fde_cfi): If -g2 and above and cfi might change CFA,
1979         force creation of CFI label and chain DW_CFA_set_loc jumping to it
1980         for convert_cfa_to_fb_loc_list.  Adjust other dwarf2out_cfi_label
1981         caller.
1982         (dwarf2out_stack_adjust, dwarf2out_frame_debug,
1983         dwarf2out_begin_epilogue, dwarf2out_frame_debug_restore_state): Adjust
1984         dwarf2out_cfi_label callers.
1985         * tree.h (dwarf2out_cfi_label): Adjust prototype.
1986         * config/arm/arm.c (thumb_pushpop, thumb1_output_function_prologue):
1987         Adjust dwarf2out_cfi_label callers.
1988         * config/vax/vax.c (vax_output_function_prologue): Likewise.
1989
1990         * config/i386/i386.h (struct machine_cfa_state,
1991         struct machine_function): Guard with ifndef USED_FOR_TARGET
1992         instead of not IN_LIBGCC2 and not in IN_TARGET_LIBS.
1993
1994         PR other/40024
1995         * emutls.c (__emutls_get_address): Change arr->size to mean number
1996         of allocated arr->data entries instead of # of slots + 1.
1997
1998         PR middle-end/40316
1999         * recog.c (peep2_reinit_state): New function.
2000         (peephole2_init_state): Use it at the end of a basic block and also
2001         when seeing a RTX_FRAME_RELATED_P insn.
2002
2003 2009-06-01  Steve Ellcey  <sje@cup.hp.com>
2004
2005         * ia64.md (floatdirf2, fix_truncrfdi, floatunsdirf,
2006         fixuns_truncrfdi2): New.
2007         (fix_truncxfdi2_alts, fixuns_truncxfdi2_alts,
2008         *nmaddsf4_alts, *nmadddf4_alts, *nmadddf4_truncsf_alts,
2009         *mulxf3_alts, *mulxf3_truncsf_alts, *mulxf3_truncdf_alts,
2010         *maddxf4_alts, *maddxf4_alts_truncsf, *maddxf4_alts_truncdf,
2011         *nmaddxf4_alts, *nmaddxf4_truncsf_alts, *nmaddxf4_truncdf_alts,
2012         *recip_approx): Remove.
2013         (divsi3 modsi3, udivsi3, umodsi3, divsi3_internal, divdi3,
2014         moddi3, udivdi3, umoddi3, divdi3_internal_lat, divdi3_internal_thr,
2015         divsf3, sqrtsf2, divdf3, sqrtdf2, divxf3, sqrtxf2): Modify and
2016         move to div.md.
2017         * div.md (fix_truncrfdi2_alts, fixuns_truncrfdi2_alt,
2018         setf_exp_rf): New.
2019
2020 2009-06-01  Ian Lance Taylor  <iant@google.com>
2021
2022         * attribs.c (register_attribute): Use CONST_CAST.
2023         * collect2.c (main): Use CONST_CAST2.
2024         (scan_prog_file): Likewise.
2025         * gcc.c (process_command, main): Likewise.
2026         * toplev.c (toplev_main): Likewise.
2027
2028         * c-typeck.c (handle_warn_cast_qual): New static function,
2029         partially broken out of build_c_cast.
2030         (build_c_cast): Call handle_warn_cast_qual.
2031         * doc/invoke.texi (Warning Options): Document new effect of
2032         -Wcast-qual.
2033
2034 2009-06-01  Aldy Hernandez  <aldyh@redhat.com>
2035
2036         * diagnostic.c (diagnostic_build_prefix): Always print columns.
2037         (diagnostic_report_current_module): Print columns.
2038         * common.opt (flag_show_column): Enable by default.
2039
2040 2009-06-01  Luis Machado  <luisgpm@br.ibm.com>
2041
2042         * alias.c (find_base_term): Check for NULL term before returning.
2043
2044 2009-06-01  Maxim Kuvyrkov  <maxim@codesourcery.com>
2045
2046         Revert due to PR40320:
2047         2009-06-01  Maxim Kuvyrkov  <maxim@codesourcery.com>
2048         * calls.c (emit_library_call_value_1): Don't force_operand for move
2049         and push insns.
2050
2051 2009-06-01  Olivier Hainque  <hainque@adacore.com>
2052             Eric Botcazou  <ebotcazou@adacore.com>
2053
2054         * tree.h (CONSTRUCTOR_BITFIELD_P): True if NODE, a FIELD_DECL, is
2055         to be processed as a bitfield for constructor output purposes.
2056         * output.h (initializer_constant_valid_for_bitfield_p): Declare
2057         new function.
2058         * varasm.c (oc_local_state): New type, output_constructor
2059         local state to support communication with helpers.
2060         (oc_outer_state): New type, output_constructor outer state of
2061         relevance in recursive calls.
2062         (output_constructor_array_range): New output_constructor helper,
2063         extracted code for an array range element.
2064         (output_constructor_regular_field): New output_constructor helper,
2065         extracted code for an element that is not a bitfield.
2066         (output_constructor_bitfield): New output_constructor helper,
2067         extracted code for a bitfield element.  Accept an OUTER state
2068         argument for recursive processing.  Recurse on record or array
2069         CONSTRUCTOR values, possibly past noop conversions.
2070         (initializer_constant_valid_for_bitfield_p): New predicate.  Whether
2071         VALUE is a valid constant-valued expression for use in a static
2072         bit-field initializer.
2073         (output_constructor): Rework to use helpers.  Accept and honor an
2074         OUTER state argument for recursive calls.  Return total size.  Be
2075         prepared for nested constructors initializing bitfields.
2076         (output_constant): Feed OUTER in calls to output_constructor.
2077
2078 2009-06-01  Maxim Kuvyrkov  <maxim@codesourcery.com>
2079
2080         * calls.c (emit_library_call_value_1): Don't force_operand for move
2081         and push insns.
2082
2083 2009-06-01  Nick Clifton  <nickc@redhat.com>
2084
2085         * doc/invoke.texi (IA-64 Options): Fix typo.
2086
2087 2009-06-01  Ira Rosen  <irar@il.ibm.com>
2088
2089         PR tree-optimization/39129
2090         * tree-vect-loop-manip.c (conservative_cost_threshold): Change the 
2091         printed message.
2092         (vect_do_peeling_for_loop_bound): Use 
2093         LOOP_REQUIRES_VERSIONING_FOR_ALIGNMENT and
2094         LOOP_REQUIRES_VERSIONING_FOR_ALIAS macros.
2095         (vect_loop_versioning): Likewise.
2096         (vect_create_cond_for_alias_checks): Fix indentation.
2097         * tree-vectorizer.h (struct _loop_vec_info): Fix indentation of the 
2098         macros.
2099         (LOOP_REQUIRES_VERSIONING_FOR_ALIGNMENT): Define.
2100         (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Likewise.
2101         * tree-vect-loop.c (vect_analyze_loop_form): Change "too many BBs" to 
2102         "control flow in loop".
2103         (vect_estimate_min_profitable_iters): Use 
2104         LOOP_REQUIRES_VERSIONING_FOR_ALIGNMENT and
2105         LOOP_REQUIRES_VERSIONING_FOR_ALIAS macros.
2106         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
2107         (vect_create_data_ref_ptr): Don't mention array dimension in printing.
2108         * tree-vect-stmts.c (vectorizable_store): Replace the check that the 
2109         statement belongs to a group of strided accesses with the exact code 
2110         check.
2111         (vectorizable_load): Likewise.
2112         * tree-vect-slp.c (vect_analyze_slp_instance): Spell out "basic block".
2113         (vect_slp_analyze_bb, vect_slp_transform_bb): Likewise.
2114
2115 2009-06-01  Gerald Pfeifer  <gerald@pfeifer.com>
2116
2117         * config/freebsd-stdint.h: New file.
2118         * config.gcc (*-*-freebsd): Set use_gcc_stdint=wrap.
2119         Add freebsd-stdint.h to tm_file.
2120
2121 2009-06-01  Richard Earnshaw  <rearnsha@arm.com>
2122
2123         * arm/thumb2.md (thumb2_zero_extendhidi2): New insn and split.
2124         (thumb2_extendhidi2): Likewise.
2125
2126 2009-05-31  Ian Lance Taylor  <iant@google.com>
2127
2128         * regstat.c (regstat_n_sets_and_refs): Remove duplicate definition.
2129
2130 2009-05-31  Ian Lance Taylor  <iant@google.com>
2131
2132         * Makefile.in (except.o): Depend upon gt-except.h, not gt-$(EXCEPT_H).
2133         (ipa-cp.o): Depend upon $(FIBHEAP_H) and $(PARAMS_H).
2134         (ipa-reference.o): Depend upon gt-ipa-reference.h.
2135
2136 2009-05-31  Jason Merrill  <jason@redhat.com>
2137
2138         * tree-pretty-print.c (print_call_name): Take the callee, not the
2139         call itself.  Make non-static.  Use dump_function_name for functions.
2140         (dump_generic_node): Adjust.
2141         * diagnostic.h: Declare print_call_name.
2142         * gimple-pretty-print.c (dump_gimple_call): Use it.
2143
2144 2009-05-31  Kaz Kojima  <kkojima@gcc.gnu.org>
2145
2146         * config/sh/sh.md (ashldi3_std): New define_expand.
2147         (ashldi3): Use it.
2148
2149 2009-05-31  Kaz Kojima  <kkojima@gcc.gnu.org>
2150
2151         PR target/40313
2152         * config/sh/sh.c: Include debug.h.
2153         (sh_expand_epilogue): Emit a blockage insn before the frame
2154         pointer adjustment also when dwarf2out_do_frame returns true.
2155
2156 2009-05-31  Richard Earnshaw  <rearnsha@arm.com>
2157
2158         * arm/thumb2.md (thumb2_extendsidi2): Add a split sub-pattern.
2159         (thumb2_extendqidi2): New pattern.
2160
2161 2009-05-31  Ira Rosen  <irar@il.ibm.com>
2162
2163         * tree-vect-loop-manip.c (slpeel_update_phi_nodes_for_guard1): Don't
2164         mark phis for renaming.
2165         * tree-vectorizer.c (vect_memsyms_to_rename): Remove.
2166         (vectorize_loops): Don't allocate and free vect_memsyms_to_rename.
2167         Call mark_sym_for_renaming.
2168         * tree-vectorizer.h (vect_memsyms_to_rename): Remove.
2169         * tree-vect-loop.c (vect_transform_loop): Remove
2170         vect_memsyms_to_rename initialization and a call to
2171         mark_set_for_renaming.
2172
2173 2009-05-31  Jakub Jelinek  <jakub@redhat.com>
2174
2175         PR middle-end/40304
2176         * config/i386/i386.c (pro_epilogue_adjust_stack): Mark insns
2177         frame related even if !set_cfa && style < 0.
2178
2179 2009-05-30  Kai Tietz  <kai.tietz@onevision.com>
2180
2181         * config/i386/mingw-tls.c: New file.
2182         * config/i386/t-gthr-win32 (LIB2FUNCS_EXTRA): Add mingw-tls.c file.
2183         * gthr-win32.h (MINGW32_SUPPORTS_MT_EH): Define it for targets
2184         defining _WIN32 but not __CYGWIN__.
2185
2186 2009-05-29  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
2187
2188         * configure.ac: Add MPC support.
2189         
2190         * config.in, configure: Regenerate.     
2191
2192 2009-05-29  Richard Henderson  <rth@redhat.com>
2193
2194         * cfgcleanup.c (try_crossjump_to_edge): Only skip past
2195         NOTE_INSN_BASIC_BLOCK.
2196         * cfglayout.c (duplicate_insn_chain): Copy epilogue insn marks.
2197         Duplicate NOTE_INSN_EPILOGUE_BEG notes.
2198         * cfgrtl.c (can_delete_note_p): Allow NOTE_INSN_EPILOGUE_BEG
2199         to be deleted.
2200         * dwarf2out.c (struct cfa_loc): Change indirect field to bitfield,
2201         add in_use field.
2202         (add_cfi): Disable check redefining cfa away from drap.
2203         (lookup_cfa_1): Add remember argument; handle remember/restore.
2204         (lookup_cfa): Pass remember argument.
2205         (cfa_remember): New.
2206         (compute_barrier_args_size_1): Remove sibcall check.
2207         (dwarf2out_frame_debug_def_cfa): New.
2208         (dwarf2out_frame_debug_adjust_cfa): New.
2209         (dwarf2out_frame_debug_cfa_offset): New.
2210         (dwarf2out_frame_debug_cfa_register): New.
2211         (dwarf2out_frame_debug_cfa_restore): New.
2212         (dwarf2out_frame_debug): Handle REG_CFA_* notes.
2213         (dwarf2out_begin_epilogue): New.
2214         (dwarf2out_frame_debug_restore_state): New.
2215         (dw_cfi_oprnd1_desc): Handle DW_CFA_remember_state,
2216         DW_CFA_restore_state.
2217         (output_cfi_directive): Likewise.
2218         (convert_cfa_to_fb_loc_list): Likewise.
2219         (dw_cfi_oprnd1_desc): Handle DW_CFA_restore.
2220         * dwarf2out.h: Update.
2221         * emit-rtl.c (try_split): Don't split RTX_FRAME_RELATED_P.
2222         (copy_insn_1): Early out for null.
2223         * final.c (final_scan_insn): Call dwarf2out_begin_epilogue
2224         and dwarf2out_frame_debug_restore_state.
2225         * function.c (prologue, epilogue, sibcall_epilogue): Remove.
2226         (prologue_insn_hash, epilogue_insn_hash): New.
2227         (free_after_compilation): Adjust freeing accordingly.
2228         (record_insns): Create hash table if needed; push insns into
2229         hash instead of array.
2230         (maybe_copy_epilogue_insn): New.
2231         (contains): Search hash table instead of array.
2232         (sibcall_epilogue_contains): Remove.
2233         (thread_prologue_and_epilogue_insns): Split eh_return insns
2234         and mark them as epilogues.
2235         (reposition_prologue_and_epilogue_notes): Rewrite epilogue
2236         scanning in terms of basic blocks.
2237         * insn-notes.def (CFA_RESTORE_STATE): New.
2238         * jump.c (returnjump_p_1): Accept EH_RETURN.
2239         (eh_returnjump_p_1, eh_returnjump_p): New.
2240         * reg-notes.def (CFA_DEF_CFA, CFA_ADJUST_CFA, CFA_OFFSET,
2241         CFA_REGISTER, CFA_RESTORE): New.
2242         * rtl.def (EH_RETURN): New.
2243         * rtl.h (eh_returnjump_p, maybe_copy_epilogue_insn): Declare.
2244
2245         * config/bfin/bfin.md (UNSPEC_VOLATILE_EH_RETURN): Remove.
2246         (eh_return_internal): Use eh_return rtx; split w/ epilogue.
2247
2248         * config/i386/i386.c (gen_push): Update cfa state.
2249         (pro_epilogue_adjust_stack): Add set_cfa argument.  When true,
2250         add a CFA_ADJUST_CFA note.
2251         (ix86_dwarf_handle_frame_unspec): Remove.
2252         (ix86_expand_prologue): Update cfa state.
2253         (ix86_emit_restore_reg_using_pop): New.
2254         (ix86_emit_restore_regs_using_pop): New.
2255         (ix86_emit_leave): New.
2256         (ix86_emit_restore_regs_using_mov): Add CFA_RESTORE notes.
2257         (ix86_expand_epilogue): Add notes for unwinding the epilogue.
2258         * config/i386/i386.h (struct machine_cfa_state): New.
2259         (ix86_cfa_state): New.
2260         * config/i386/i386.md (UNSPEC_EH_RETURN): Remove.
2261         (eh_return_internal): Merge from eh_return_<mode>,
2262         use eh_return rtx, split w/ epilogue.
2263
2264 2009-05-29  Ian Lance Taylor  <iant@google.com>
2265
2266         * builtins.c (validate_gimple_arglist): Don't use va_arg with
2267         enum type.
2268         * calls.c (emit_library_call_value_1): Likewise.
2269
2270         * c-typeck.c (c_build_va_arg): New function.
2271         * c-tree.h (c_build_va_arg): Declare.
2272         * c-parser.c (c_parser_postfix_expression): Call c_build_va_arg
2273         instead of build_va_arg.
2274
2275 2009-05-29  Eric Botcazou  <ebotcazou@adacore.com>
2276
2277         * tree-ssa-loop-ivopts.c (strip_offset_1) <MULT_EXPR>: New case.
2278         (force_expr_to_var_cost) <NEGATE_EXPR>: Likewise.
2279         (ptr_difference_cost): Use affine combinations to compute it.
2280         (difference_cost): Likewise.
2281         (get_computation_cost_at): Compute more accurate cost for addresses
2282         if the ratio is a multiplier allowed in addresses.
2283         For non-addresses, consider that an additional offset or symbol is
2284         added only once.
2285
2286 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
2287
2288         * config/i386/i386.c (ix86_decompose_address): Avoid useless
2289         0 displacement.  Add 0 displacement if base is %[er]bp or %r13.
2290
2291         * config/i386/i386.md (prefix_data16, prefix_rep): Set to 0 for
2292         TYPE_SSE{MULADD,4ARG,IADD1,CVT1} by default.
2293         (prefix_rex): For UNIT_MMX don't imply the prefix by default
2294         if MODE_DI.
2295         (prefix_extra): Default to 2 for TYPE_SSE{MULADD,4ARG} and
2296         to 1 for TYPE_SSE{IADD1,CVT1}.
2297         (prefix_vex_imm8): Removed.
2298         (length_vex): Only pass 1 as second argument to
2299         ix86_attr_length_vex_default if prefix_extra is 0.
2300         (modrm): For TYPE_INCDEC only set to 0 if not TARGET_64BIT.
2301         (length): For prefix vex computation use length_immediate
2302         attribute instead of prefix_vex_imm8.
2303         (cmpqi_ext_3_insn, cmpqi_ext_3_insn_rex64,
2304         addqi_ext_1, addqi_ext_1_rex64, *testqi_ext_0, andqi_ext_0,
2305         *andqi_ext_0_cc, *iorqi_ext_0, *xorqi_ext_0, *xorqi_cc_ext_1,
2306         *xorqi_cc_ext_1_rex64): Override modrm attribute to 1.
2307         (extendsidi2_rex64, extendhidi2, extendqidi2, extendhisi2,
2308         *extendhisi2_zext, extendqihi2, extendqisi2, *extendqisi2_zext): Emit
2309         a space in between the operands.
2310         (*anddi_1_rex64, *andsi_1): Likewise.  Override prefix_rex to 1
2311         if one operand is 0xff and the other one si, di, bp or sp.
2312         (*andhi_1): Override prefix_rex to 1 if one operand is 0xff and the
2313         other one si, di, bp or sp.
2314         (*btsq, *btrq, *btcq, *btdi_rex64, *btsi): Add mode attribute.
2315         (*ffssi_1, *ffsdi_1, ctzsi2, ctzdi2): Add
2316         type and mode attributes.
2317         (*bsr, *bsr_rex64, *bsrhi): Add type attribute.
2318         (*cmpfp_i_mixed, *cmpfp_iu_mixed): For TYPE_SSECOMI, clear
2319         prefix_rep attribute and set prefix_data16 attribute iff MODE_DF.
2320         (*cmpfp_i_sse, *cmpfp_iu_sse): Clear prefix_rep attribute and set
2321         prefix_data16 attribute iff MODE_DF.
2322         (*movsi_1): For TYPE_SSEMOV MODE_SI set prefix_data16 attribute.
2323         (fix_trunc<mode>di_sse): Set prefix_rex attribute.
2324         (*adddi_4_rex64, *addsi_4): Use const128_operand instead of
2325         constm128_operand in length_immediate computation.
2326         (*addhi_4): Likewise.  Fix mode attribute to MODE_HI.
2327         (anddi_1_rex64): Use movzbl/movzwl instead of movzbq/movzwq.
2328         (*avx_ashlti3, sse2_ashlti3, *avx_lshrti3, sse2_lshrti3): Set
2329         length_immediate attribute to 1.
2330         (x86_fnstsw_1, x86_fnstcw_1, x86_fldcw_1): Fix length attribute.
2331         (*movdi_1_rex64): Override prefix_rex or prefix_data16 attributes
2332         for certain alternatives.
2333         (*movdf_nointeger, *movdf_integer_rex64, *movdf_integer): Override
2334         prefix_data16 attribute if MODE_V1DF.
2335         (*avx_setcc<mode>, *sse_setcc<mode>, *sse5_setcc<mode>): Set
2336         length_immediate to 1.
2337         (set_got_rex64, set_rip_rex64): Remove length attribute, set
2338         length_address to 4, set mode attribute to MODE_DI.
2339         (set_got_offset_rex64): Likewise.  Set length_immediate to 0.
2340         (fxam<mode>2_i387): Set length attribute to 4.
2341         (*prefetch_sse, *prefetch_sse_rex, *prefetch_3dnow,
2342         *prefetch_3dnow_rex): Override length_address attribute.
2343         (sse4_2_crc32<mode>): Override prefix_data16 and prefix_rex
2344         attributes.
2345         * config/i386/predicates.md (ext_QIreg_nomode_operand): New predicate.
2346         (constm128_operand): Removed.
2347         * config/i386/i386.c (memory_address_length): For
2348         disp && !index && !base in 64-bit mode account for SIB byte if
2349         print_operand_address can't optimize disp32 into disp32(%rip)
2350         and UNSPEC doesn't imply (%rip) addressing.  Add 1 to length
2351         for fs: or gs: segment.
2352         (ix86_attr_length_immediate_default): When checking if shortform
2353         is possible, truncate immediate to the length of the non-shortened
2354         immediate.
2355         (ix86_attr_length_address_default): Ignore MEM_P operands
2356         with X constraint.
2357         (ix86_attr_length_vex_default): Only check for DImode on
2358         GENERAL_REG_P operands.
2359         * config/i386/sse.md (<sse>_comi, <sse>_ucomi): Clear
2360         prefix_rep attribute, set prefix_data16 attribute iff MODE_DF.
2361         (sse_cvttps2pi): Clear prefix_rep attribute.
2362         (sse2_cvttps2dq, *sse2_cvtpd2dq, sse2_cvtps2pd): Clear prefix_data16
2363         attribute.
2364         (*sse2_cvttpd2dq): Don't clear prefix_rep attribute.
2365         (*avx_ashr<mode>3, ashr<mode>3, *avx_lshr<mode>3, lshr<mode>3,
2366         *avx_ashl<mode>3, ashl<mode>3): Set length_immediate attribute to 1
2367         iff operand 2 is const_int_operand.
2368         (*vec_dupv4si, avx_shufpd256_1, *avx_shufpd_<mode>,
2369         sse2_shufpd_<mode>): Set length_immediate attribute to 1.
2370         (sse2_pshufd_1): Likewise.  Set prefix attribute to maybe_vex
2371         instead of vex.
2372         (sse2_pshuflw_1, sse2_pshufhw_1): Set length_immediate to 1 and clear
2373         prefix_data16.
2374         (sse2_unpckhpd, sse2_unpcklpd, sse2_storehpd, *vec_concatv2df): Set
2375         prefix_data16 attribute for movlpd and movhpd instructions.
2376         (sse2_loadhpd, sse2_loadlpd, sse2_movsd): Likewise.  Override
2377         length_immediate for shufpd instruction.
2378         (sse2_movntsi, sse3_lddqu): Clear prefix_data16 attribute.
2379         (avx_cmpp<avxmodesuffixf2c><mode>3,
2380         avx_cmps<ssemodesuffixf2c><mode>3, *avx_maskcmp<mode>3,
2381         <sse>_maskcmp<mode>3, <sse>_vmmaskcmp<mode>3,
2382         avx_shufps256_1, *avx_shufps_<mode>, sse_shufps_<mode>,
2383         *vec_dupv4sf_avx, *vec_dupv4sf): Set length_immediate attribute to 1.
2384         (*avx_cvtsi2ssq, *avx_cvtsi2sdq): Set length_vex attribute to 4.
2385         (sse_cvtsi2ssq, sse2_cvtsi2sdq): Set prefix_rex attribute to 1.
2386         (sse2_cvtpi2pd, sse_loadlps, sse2_storelpd): Override
2387         prefix_data16 attribute for the first alternative to 1.
2388         (*avx_loadlps): Override length_immediate for the first alternative.
2389         (*vec_concatv2sf_avx): Override length_immediate and prefix_extra
2390         attributes for second alternative.
2391         (*vec_concatv2sf_sse4_1): Override length_immediate and
2392         prefix_data16 attributes for second alternative.
2393         (*vec_setv4sf_avx, *avx_insertps, vec_extract_lo_<mode>,
2394         vec_extract_hi_<mode>, vec_extract_lo_v16hi,
2395         vec_extract_hi_v16hi, vec_extract_lo_v32qi,
2396         vec_extract_hi_v32qi): Set prefix_extra and length_immediate to 1.
2397         (*vec_setv4sf_sse4_1, sse4_1_insertps, *sse4_1_extractps): Set
2398         prefix_data16 and length_immediate to 1.
2399         (*avx_mulv2siv2di3, *avx_mulv4si3, sse4_2_gtv2di3): Set prefix_extra
2400         to 1.
2401         (*avx_<code><mode>3, *avx_eq<mode>3, *avx_gt<mode>3): Set
2402         prefix_extra attribute for variants that don't have 0f prefix alone.
2403         (*avx_pinsr<ssevecsize>): Likewise.  Set length_immediate to 1.
2404         (*sse4_1_pinsrb, *sse2_pinsrw, *sse4_1_pinsrd, *sse4_1_pextrb,
2405         *sse4_1_pextrb_memory, *sse2_pextrw, *sse4_1_pextrw_memory,
2406         *sse4_1_pextrd): Set length_immediate to 1.
2407         (*sse4_1_pinsrd): Likewise.  Set prefix_extra to 1.
2408         (*sse4_1_pinsrq, *sse4_1_pextrq): Set prefix_rex and length_immediate
2409         to 1.
2410         (*vec_extractv2di_1_rex64_avx, *vec_extractv2di_1_rex64,
2411         *vec_extractv2di_1_avx, *vec_extractv2di_1_sse2): Override
2412         length_immediate to 1 for second alternative.
2413         (*vec_concatv2si_avx, *vec_concatv2di_rex64_avx): Override
2414         prefix_extra and length_immediate attributes for the first
2415         alternative.
2416         (vec_concatv2si_sse4_1): Override length_immediate to 1 for the
2417         first alternative.
2418         (*vec_concatv2di_rex64_sse4_1): Likewise.  Override prefix_rex
2419         to 1 for the first and third alternative.
2420         (*vec_concatv2di_rex64_sse): Override prefix_rex to 1 for the second
2421         alternative.
2422         (*sse2_maskmovdqu, *sse2_maskmovdqu_rex64): Override length_vex
2423         attribute.
2424         (*sse_sfence, sse2_mfence, sse2_lfence): Override length_address
2425         attribute to 0.
2426         (*avx_phaddwv8hi3, *avx_phadddv4si3, *avx_phaddswv8hi3,
2427         *avx_phsubwv8hi3, *avx_phsubdv4si3, *avx_phsubswv8hi,
2428         *avx_pmaddubsw128, *avx_pmulhrswv8hi3, *avx_pshufbv16qi3,
2429         *avx_psign<mode>3): Set prefix_extra attribute to 1.
2430         (ssse3_phaddwv4hi3, ssse3_phadddv2si3, ssse3_phaddswv4hi3,
2431         ssse3_phsubwv4hi3, ssse3_phsubdv2si3, ssse3_phsubswv4hi3,
2432         ssse3_pmaddubsw, *ssse3_pmulhrswv4hi, ssse3_pshufbv8qi3,
2433         ssse3_psign<mode>3): Override prefix_rex attribute.
2434         (*avx_palignrti): Override prefix_extra and length_immediate to 1.
2435         (ssse3_palignrti): Override length_immediate to 1.
2436         (ssse3_palignrdi): Override length_immediate to 1, override
2437         prefix_rex attribute.
2438         (abs<mode>2): Override prefix_rep to 0, override prefix_rex attribute.
2439         (sse4a_extrqi): Override length_immediate to 2.
2440         (sse4a_insertqi): Likewise.  Override prefix_data16 to 0.
2441         (sse4a_insertq): Override prefix_data16 to 0.
2442         (avx_blendp<avxmodesuffixf2c><avxmodesuffix>,
2443         avx_blendvp<avxmodesuffixf2c><avxmodesuffix>,
2444         avx_dpp<avxmodesuffixf2c><avxmodesuffix>, *avx_mpsadbw,
2445         *avx_pblendvb, *avx_pblendw, avx_roundp<avxmodesuffixf2c>256,
2446         avx_rounds<avxmodesuffixf2c>256): Override prefix_extra
2447         and length_immediate to 1.
2448         (sse4_1_blendp<ssemodesuffixf2c>, sse4_1_dpp<ssemodesuffixf2c>,
2449         sse4_2_pcmpestr, sse4_2_pcmpestri, sse4_2_pcmpestrm,
2450         sse4_2_pcmpestr_cconly, sse4_2_pcmpistr, sse4_2_pcmpistri,
2451         sse4_2_pcmpistrm, sse4_2_pcmpistr_cconly): Override prefix_data16
2452         and length_immediate to 1.
2453         (sse4_1_blendvp<ssemodesuffixf2c>): Override prefix_data16 to 1.
2454         (sse4_1_mpsadbw, sse4_1_pblendw): Override length_immediate to 1.
2455         (*avx_packusdw, avx_vtestp<avxmodesuffixf2c><avxmodesuffix>,
2456         avx_ptest256): Override prefix_extra to 1.
2457         (sse4_1_roundp<ssemodesuffixf2c>, sse4_1_rounds<ssemodesuffixf2c>):
2458         Override prefix_data16 and length_immediate to 1.
2459         (sse5_pperm_zero_v16qi_v8hi, sse5_pperm_sign_v16qi_v8hi,
2460         sse5_pperm_zero_v8hi_v4si, sse5_pperm_sign_v8hi_v4si,
2461         sse5_pperm_zero_v4si_v2di, sse5_pperm_sign_v4si_v2di,
2462         sse5_vrotl<mode>3, sse5_ashl<mode>3, sse5_lshl<mode>3): Override
2463         prefix_data16 to 0 and prefix_extra to 2.
2464         (sse5_rotl<mode>3, sse5_rotr<mode>3): Override length_immediate to 1.
2465         (sse5_frcz<mode>2, sse5_vmfrcz<mode>2): Don't override prefix_extra
2466         attribute.
2467         (*sse5_vmmaskcmp<mode>3, sse5_com_tf<mode>3,
2468         sse5_maskcmp<mode>3, sse5_maskcmp<mode>3, sse5_maskcmp_uns<mode>3):
2469         Override prefix_data16 and prefix_rep to 0, length_immediate to 1
2470         and prefix_extra to 2.
2471         (sse5_maskcmp_uns2<mode>3, sse5_pcom_tf<mode>3): Override
2472         prefix_data16 to 0, length_immediate to 1 and prefix_extra to 2.
2473         (*avx_aesenc, *avx_aesenclast, *avx_aesdec, *avx_aesdeclast,
2474         avx_vpermilvar<mode>3,
2475         avx_vbroadcasts<avxmodesuffixf2c><avxmodesuffix>,
2476         avx_vbroadcastss256, avx_vbroadcastf128_p<avxmodesuffixf2c>256,
2477         avx_maskloadp<avxmodesuffixf2c><avxmodesuffix>,
2478         avx_maskstorep<avxmodesuffixf2c><avxmodesuffix>):
2479         Override prefix_extra to 1.
2480         (aeskeygenassist, pclmulqdq): Override length_immediate to 1.
2481         (*vpclmulqdq, avx_vpermil<mode>, avx_vperm2f128<mode>3,
2482         vec_set_lo_<mode>, vec_set_hi_<mode>, vec_set_lo_v16hi,
2483         vec_set_hi_v16hi, vec_set_lo_v32qi, vec_set_hi_v32qi): Override
2484         prefix_extra and length_immediate to 1.
2485         (*avx_vzeroall, avx_vzeroupper, avx_vzeroupper_rex64): Override
2486         modrm to 0.
2487         (*vec_concat<mode>_avx): Override prefix_extra and length_immediate
2488         to 1 for the first alternative.
2489         * config/i386/mmx.md (*mov<mode>_internal_rex64): Override
2490         prefix_rep, prefix_data16 and/or prefix_rex attributes in certain
2491         cases.
2492         (*mov<mode>_internal_avx, *movv2sf_internal_rex64,
2493         *movv2sf_internal_avx, *movv2sf_internal): Override
2494         prefix_rep attribute for certain alternatives.
2495         (*mov<mode>_internal): Override prefix_rep or prefix_data16
2496         attributes for certain alternatives.
2497         (*movv2sf_internal_rex64_avx): Override prefix_rep and length_vex
2498         attributes for certain alternatives.
2499         (*mmx_addv2sf3, *mmx_subv2sf3, *mmx_mulv2sf3,
2500         *mmx_<code>v2sf3_finite, *mmx_<code>v2sf3, mmx_rcpv2sf2,
2501         mmx_rcpit1v2sf3, mmx_rcpit2v2sf3, mmx_rsqrtv2sf2, mmx_rsqit1v2sf3,
2502         mmx_haddv2sf3, mmx_hsubv2sf3, mmx_addsubv2sf3,
2503         *mmx_eqv2sf3, mmx_gtv2sf3, mmx_gev2sf3, mmx_pf2id, mmx_pf2iw,
2504         mmx_pi2fw, mmx_floatv2si2, mmx_pswapdv2sf2, *mmx_pmulhrwv4hi3,
2505         mmx_pswapdv2si2): Set prefix_extra attribute to 1.
2506         (mmx_ashr<mode>3, mmx_lshr<mode>3, mmx_ashl<mode>3): Set
2507         length_immediate to 1 if operand 2 is const_int_operand.
2508         (*mmx_pinsrw, mmx_pextrw, mmx_pshufw_1, *vec_dupv4hi,
2509         *vec_extractv2si_1): Set length_immediate attribute to 1.
2510         (*mmx_uavgv8qi3): Override prefix_extra attribute to 1 if
2511         using old 3DNOW insn rather than SSE/3DNOW_A.
2512         (mmx_emms, mmx_femms): Clear modrm attribute.
2513
2514 2009-05-29  Martin Jambor  <mjambor@suse.cz>
2515
2516         * tree-sra.c:  New implementation of SRA.
2517
2518         * params.def (PARAM_SRA_MAX_STRUCTURE_SIZE): Removed.
2519         (PARAM_SRA_MAX_STRUCTURE_COUNT): Removed.
2520         (PARAM_SRA_FIELD_STRUCTURE_RATIO): Removed.
2521         * params.h (SRA_MAX_STRUCTURE_SIZE): Removed.
2522         (SRA_MAX_STRUCTURE_COUNT): Removed.
2523         (SRA_FIELD_STRUCTURE_RATIO): Removed.
2524         * doc/invoke.texi (sra-max-structure-size): Removed.
2525         (sra-field-structure-ratio): Removed.
2526
2527 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
2528
2529         PR middle-end/40291
2530         * builtins.c (expand_builtin_memcmp): Convert len to sizetype
2531         before expansion.
2532
2533 2009-05-29  Andrey Belevantsev  <abel@ispras.ru>
2534
2535         PR rtl-optimization/40101
2536         * sel-sched-ir.c (get_seqno_by_preds): Allow returning negative
2537         seqno.  Adjust comment.
2538         * sel-sched.c (find_seqno_for_bookkeeping): Assert that when 
2539         inserting bookkeeping before a jump, the jump is not scheduled.
2540         When no positive seqno found, provide a value.  Add comment.
2541
2542 2009-05-29  Richard Guenther  <rguenther@suse.de>
2543
2544         * tree-ssa-alias.c (nonaliasing_component_refs_p): Remove
2545         short-cutting on the first component.
2546
2547 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
2548
2549         PR middle-end/39958
2550         * omp-low.c (scan_omp_1_op): Call remap_type on TREE_TYPE
2551         for trees other than decls/types.
2552
2553 2009-05-29  Richard Guenther  <rguenther@suse.de>
2554
2555         * tree-ssa-operands.c (get_expr_operands): Do not handle
2556         INDIRECT_REFs in the handled-component case.  Remove
2557         unused get_ref_base_and_extent case.
2558         * tree-dfa.c (get_ref_base_and_extent): Avoid calling
2559         tree_low_cst and host_integerp where possible.
2560         * tree-ssa-structalias.c (equiv_class_label_eq): Check hash
2561         codes for equivalence.
2562         * dce.c (find_call_stack_args): Avoid redundant bitmap queries.
2563
2564 2009-05-29  David Billinghurst <billingd@gcc.gnu.org>
2565
2566         * config.gcc: Add i386/t-fprules-softfp and soft-fp/t-softfp
2567         to tmake_file for i[34567]86-*-cygwin*. 
2568
2569 2009-05-29  Jakub Jelinek  <jakub@redhat.com>
2570
2571         PR target/40017
2572         * config/rs6000/rs6000-c.c (_Bool_keyword): New variable.
2573         (altivec_categorize_keyword, init_vector_keywords,
2574         rs6000_cpu_cpp_builtins): Define _Bool as conditional macro
2575         similar to bool.
2576
2577 2009-05-29  Kai Tietz  <kai.tietz@onevision.com>
2578
2579         * tree.c (handle_dll_attribute): Check if node is
2580         of kind FUNCTION_DECL for DECL_DECLARED_INLINE_P check.
2581
2582 2009-05-29  Richard Earnshaw  <rearnsha@arm.com>
2583
2584         * config/arm/thumb2.md (thumb2_zero_extendsidi2): Add a split
2585         component.
2586         (thumb2_zero_extendqidi2): Likewise.
2587
2588 2009-05-28  Kaz Kojima  <kkojima@gcc.gnu.org>
2589
2590         * config/sh/sh.c (sh_expand_t_scc): Use gen_xorsi3_movrt
2591         instead of gen_movrt.
2592         * config/sh/sh.md (movrt): Remove.
2593
2594 2009-05-28  Steve Ellcey  <sje@cup.hp.com>
2595
2596         * doc/invoke.texi (IA-64 Options):
2597         Add -msdata, -mfused-madd, -mno-inline-float-divide, 
2598         -mno-inline-int-divide, -mno-inline-sqrt, -msched-spec-ldc,
2599         -msched-spec-control-ldc, -msched-prefer-non-data-spec-insns,
2600         -msched-prefer-non-control-spec-insns,
2601         -msched-stop-bits-after-every-cycle,
2602         -msched-count-spec-in-critical-path,
2603         -msel-sched-dont-check-control-spec, -msched-fp-mem-deps-zero-cost
2604         -msched-max-memory-insns-hard-limit, -msched-max-memory-insns.
2605         Remove -mt, -pthread, -msched-ldc, -mno-sched-control-ldc,
2606         and -msched-spec-verbose.
2607
2608 2009-05-28  Joseph Myers  <joseph@codesourcery.com>
2609
2610         * config/arm/lib1funcs.asm (__clear_cache): Define if L_clear_cache.
2611         * config/arm/linux-eabi.h (CLEAR_INSN_CACHE): Define to give an
2612         error if used.
2613         * config/arm/t-linux-eabi (LIB1ASMFUNCS): Add _clear_cache.
2614
2615 2009-05-28  Richard Guenther  <rguenther@suse.de>
2616
2617         * tree-ssa-alias.c (ao_ref_init): New function.
2618         (ao_ref_base): Likewise.
2619         (ao_ref_base_alias_set): Likewise.
2620         (ao_ref_alias_set): Likewise.
2621         (refs_may_alias_p_1): Change signature.
2622         (refs_may_alias_p): Adjust.
2623         (refs_anti_dependent_p): Likewise.
2624         (refs_output_dependent_p): Likewise.
2625         (call_may_clobber_ref_p_1): Change signature.
2626         (call_may_clobber_ref_p): Adjust.
2627         (stmt_may_clobber_ref_p_1): New function split out from ...
2628         (stmt_may_clobber_ref_p): ... here.
2629         (maybe_skip_until): Adjust signature.
2630         (get_continuation_for_phi): Likewise.
2631         (walk_non_aliased_vuses): Likewise.
2632         * tree-ssa-alias.h (struct ao_ref_s): New structure type.
2633         (ao_ref_init): Declare.
2634         (ao_ref_base): Likewise.
2635         (ao_ref_alias_set): Likewise.
2636         (stmt_may_clobber_ref_p_1): Likewise.
2637         (walk_non_aliased_vuses): Adjust.
2638         * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): New function.
2639         (get_ref_from_reference_ops): remove.
2640         (vn_reference_lookup_2): Adjust signature.
2641         (vn_reference_lookup_3): Do not re-build trees.  Handle unions.
2642         (vn_reference_lookup_pieces): Adjust signature, do not re-build trees.
2643         (vn_reference_lookup): Adjust.
2644         (vn_reference_insert): Likewise.
2645         (vn_reference_insert_pieces): Adjust signature.
2646         (visit_reference_op_call): Adjust.
2647         * tree-ssa-pre.c (get_expr_type): Simplify.
2648         (phi_translate_1): Adjust.
2649         (compute_avail): Likewise.
2650         (translate_vuse_through_block): Do not re-build trees.
2651         (value_dies_in_block_x): Likewise.
2652         * tree-ssa-sccvn.h (struct vn_reference_s): Add type and alias-set
2653         fields.
2654         (vn_reference_lookup_pieces): Adjust declaration.
2655         (vn_reference_insert_pieces): Likewise.
2656
2657 2009-05-28  Benjamin Kosnik  <bkoz@redhat.com>
2658
2659         * tree-ssa-copy.c (replace_exp_1): Move op for warning-free use
2660         with checking disabled.
2661
2662 2009-05-28  Dave Korn  <dave.korn.cygwin@gmail.com>
2663
2664         PR target/37216
2665
2666         * configure.ac (HAVE_GAS_ALIGNED_COMM):  Add autoconf test and
2667         macro definition for support of three-operand format aligned
2668         .comm directive in assembler on cygwin/pe/mingw target OS.
2669         * configure:  Regenerate.
2670         * config.h:  Regenerate.
2671
2672         * config/i386/winnt.c (i386_pe_asm_output_aligned_decl_common):  Use
2673         aligned form of .comm directive if -mpe-aligned-commons is in effect.
2674         * config/i386/cygming.opt (-mpe-aligned-commons):  Add new option.
2675
2676         * doc/invoke.texi (-mpe-aligned-commons):  Document new target option.
2677         * doc/tm.texi (ASM_OUTPUT_COMMON):  Document zero size commons.
2678
2679 2009-05-28  Ira Rosen  <irar@il.ibm.com>
2680
2681         PR tree-optimization/40254
2682         * tree-data-ref.c (dr_analyze_innermost): Take POFFSET into account
2683         in analysis of basic blocks.
2684
2685 2009-05-28  Adam Nemet  <anemet@caviumnetworks.com>
2686
2687         PR middle-end/33699
2688         * target.h (struct gcc_target): Fix indentation.  Add const_anchor.
2689         * target-def.h (TARGET_CONST_ANCHOR): New macro.
2690         (TARGET_INITIALIZER): Use it.
2691         * cse.c (CHEAPER): Move it up to the other macros.
2692         (insert): Rename this ...
2693         (insert_with_costs): ... to this.  Add cost parameters.  Update
2694         function comment.
2695         (insert): New function.  Call insert_with_costs.
2696         (compute_const_anchors, insert_const_anchor, insert_const_anchors,
2697         find_reg_offset_for_const, try_const_anchors): New functions.
2698         (cse_insn): Call try_const_anchors.  Adjust cost of src_related
2699         when using a const-anchor.  Call insert_const_anchors.
2700         * config/mips/mips.c (mips_set_mips16_mode): Set targetm.const_anchor.
2701         * doc/tm.texi (Misc): Document TARGET_CONST_ANCHOR.
2702
2703 2009-05-28  Alexandre Oliva  <aoliva@redhat.com>
2704
2705         * tree-inline.c (remap_decls): Enable nonlocalized variables
2706         when not optimizing.
2707
2708 2009-05-28  Alexandre Oliva  <aoliva@redhat.com>
2709
2710         * tree-ssa-live.c (remove_unused_locals): Skip when not optimizing.
2711         Simplify other tests involving optimize.
2712
2713 2009-05-27  Tom Tromey  <tromey@redhat.com>
2714
2715         * unwind-dw2.c (_Unwind_DebugHook): New function.
2716         (uw_install_context): Call _Unwind_DebugHook.
2717
2718 2009-05-27  Tom Tromey  <tromey@redhat.com>
2719
2720         * system.h (CONST_CAST2): Use C++ const_cast when compiled as C++
2721
2722 2009-05-27  Ian Lance Taylor  <iant@google.com>
2723
2724         * Makefile.in (LINKER, LINKER_FLAGS): Define.
2725         (LINKER_FOR_BUILD, BUILD_LINKERFLAGS): Define.
2726         (ALL_LINKERFLAGS): Define.
2727         (xgcc$(exeext)): Change $(COMPILER) to $(LINKER).
2728         (cpp$(exeext), cc1-dummy$(exeext), cc1$(exeext)): Likewise.
2729         (collect2$(exeext), mips-tfile, mips-tdump): Likewise.
2730         (gcov$(exeext), gcov-dump$(exeext)): Likewise.
2731         (build/gen%$(build_exeext)): Change $(COMPILER_FOR_BUILD) to
2732         $(LINKER_FOR_BUILD).
2733         (build/gcov-iov$(build_exeext)): Likewise.
2734
2735 2009-05-27  Julian Brown  <julian@codesourcery.com>
2736
2737         * gcse.c (target.h): Include.
2738         (can_assign_to_reg_without_clobbers_p): Check that the target allows
2739         copy of argument to a pseudo register.
2740
2741 2009-05-27  Diego Novillo  <dnovillo@google.com>
2742
2743         * tree-ssa-live.c (dump_scope_block): Document arguments.
2744         (dump_scope_blocks): Document.
2745         (debug_scope_blocks): New.
2746         * tree-flow.h (debug_scope_blocks): Declare.
2747
2748 2009-05-21  Denis Chertykov  <denisc@overta.ru>
2749
2750         * doc/contrib.texi (Contributors): Add myself to the list.
2751
2752 2009-05-27  Olivier Hainque  <hainque@adacore.com>
2753
2754         * expr.c (target_align): New function.  Alignment the TARGET of an
2755         assignment may be assume to have.
2756         (highest_pow2_factor_for_target): Use it instead of relying on
2757         immediate tree attributes of TARGET, not necessarily honored when
2758         intermediate bitfields are involved.
2759         
2760 2009-05-27  H.J. Lu  <hongjiu.lu@intel.com>
2761
2762         PR target/40266
2763         * config/i386/driver-i386.c (host_detect_local_cpu): Support
2764         AVX, SSE4, AES, PCLMUL and POPCNT.
2765
2766 2009-05-27  Diego Novillo  <dnovillo@google.com>
2767
2768         * tree-pretty-print.c (dump_location): New.
2769         (dump_generic_node): Call it.
2770         Factor code to handle BLOCK nodes ...
2771         (dump_block_node): ... here.
2772
2773 2009-05-27  Rafael Avila de Espindola  <espindola@google.com>
2774
2775         * Makefile.in (GCC_PLUGIN_H): New. Replace all uses of gcc-plugin.h
2776         with it.
2777         * doc/plugins.texi: Document that gcc-plugin.h must be the first to be
2778         included.
2779         * gcc-plugin.h: Include config.h and system.h.
2780         (IN_GCC): Define if not defined.
2781
2782 2009-05-27  Hans-Peter Nilsson  <hp@axis.com>
2783
2784         PR middle-end/40249
2785         * Makefile.in (CRTSTUFF_CFLAGS): Replace -fno-inline-functions
2786         with -fno-inline.
2787
2788 2009-05-27  Shujing Zhao  <pearly.zhao@oracle.com>
2789
2790         * config/m32r/m32r.c: Use REG_P, MEM_P and CONST_INT_P where
2791         applicable.
2792         * config/m32r/m32r.h: Ditto.
2793         * config/m32r/m32r.md: Ditto.
2794         * config/m32r/predicates.md: Ditto.
2795
2796 2009-05-27  Alexandre Oliva  <aoliva@redhat.com>
2797
2798         * cgraph.c (dump_cgraph_node): Honor -fdump-noaddr.
2799
2800 2009-05-26  Basile Starynkevitch  <basile@starynkevitch.net>
2801
2802         * doc/plugins.texi
2803         (Loading plugins): typo.
2804         (Plugin callbacks): Documented PLUGIN_INFO, PLUGIN_GGC_START,
2805         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS.
2806         (Interacting with the GCC Garbage Collector): Added new section.
2807         (Giving information about a plugin): Added new section for
2808         PLUGIN_INFO.
2809         * ggc.h (ggc_register_root_tab): Added declaration.
2810         * gcc-plugin.h (PLUGIN_GGC_START, PLUGIN_GGC_MARKING)
2811         (PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS): Added new events.
2812         (register_callback): Improved comment in declaration.
2813         * ggc-common.c (const_ggc_root_tab_t) Added new typedef for vectors.
2814         (extra_root_vec) Added static variable for dynamic roots registration.
2815         (ggc_register_root_tab) Added new routine.
2816         (ggc_mark_roots) Added iteration inside extra_root_vec, and invoke
2817         PLUGIN_GGC_MARKING event.
2818         * ggc-zone.c: Include plugin.h.
2819         (ggc_collect): Invoke PLUGIN_GGC_START & PLUGIN_GGC_END events.
2820         * ggc-page.c: Include plugin.h.
2821         (ggc_collect): Invoke PLUGIN_GGC_START & PLUGIN_GGC_END events.
2822         * plugin.c (plugin_event_name): added names of PLUGIN_GGC_START,
2823         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS
2824         (register_callback): check lack of callbacks for
2825         pseudo-events. Added handling of PLUGIN_REGISTER_GGC_ROOTS,
2826         PLUGIN_GGC_START, PLUGIN_GGC_MARKING, PLUGIN_GGC_END.
2827         (invoke_plugin_callbacks): Handle PLUGIN_GGC_START,
2828         PLUGIN_GGC_MARKING, PLUGIN_GGC_END, PLUGIN_REGISTER_GGC_ROOTS.
2829         * Makefile.in (ggc-common.o, ggc-zone.o, ggc-page.o): Added
2830         dependency on plugin.h.
2831         (plugin.o): Added dependency on ggc.h...
2832
2833 2009-05-26  Richard Guenther  <rguenther@suse.de>
2834
2835         PR middle-end/40248
2836         Revert
2837         * expr.c (expand_expr_real_1): Avoid calling do_store_flag
2838         with mismatched comparison modes.
2839
2840         * expr.c (expand_expr_real_1): Expand the operand of a
2841         VIEW_CONVERT_EXPR in its natural mode.
2842
2843 2009-05-26  Ian Lance Taylor  <iant@google.com>
2844
2845         * Makefile.in (COMPILER, COMPILER_FLAGS): Define.
2846         (COMPILER_FOR_BUILD, BUILD_COMPILERFLAGS): Define.
2847         (ALL_COMPILERFLAGS): Define.
2848         (.c.o, xgcc$(exeext), cpp$(exeext)): Use $(COMPILER).
2849         (cc1-dummy$(exeext), cc1$(exeext)): Likewise.
2850         (collect2$(exeext), collect2.o): Likewise.
2851         (c-opts.o, c-cppbuiltin.o, c-pch.o, gcc.o, gccspec.o): Likewise.
2852         (gcc-options.o, version.o, prefix.o, toplev.o): Likewise.
2853         ($(out_object_file), mips-tfile, mips-tdump): Likewise.
2854         (libbackend.o, intl.o, cppdefault.o): Likewise.
2855         (gcov$(exeext), gcov-dump$(exeext)): Likewise.
2856         (build/%.o): Use $(COMPILER_FOR_BUILD).
2857         (build/gen%$(build_exeext)): Likewise.
2858         (build/gcov-iov$(build_exeext)): LIkewise.
2859         * config/t-darwin (darwin.o): Use $(COMPILER).
2860         (darwin-c.o, darwin-f.o, darwin-driver.o): Likewise.
2861         * config/t-sol2 (sol2-c.o): Likewise.
2862         (sol2.o): Likewise.
2863         * config/t-vxworks (vxworks.o): Likewise.
2864         * config/x-darwin (host-darwin.o): Likewise.
2865         * config/x-hpux (host-hpux.o): Likewise.
2866         * config/x-linux (host-linux.o): Likewise.
2867         * config/x-solaris (host-solaris.o): Likewise.
2868         * config/alpha/x-alpha (driver-alpha.o): Likewise.
2869         * config/arm/t-arm (arm-c.o): Likewise.
2870         * config/arm/t-pe (pe.o): Likewise.
2871         * config/arm/t-wince-pe (pe.o): Likewise.
2872         * config/i386/t-cygming (winnt.o): Likewise.
2873         (winnt-cxx.o, winnt-stubs.o, msformat-c.o): Likewise.
2874         * config/i386/t-cygwin (cygwin1.o): Likewise.
2875         (cygwin2.o): Likewise.
2876         * config/i386/t-i386 (i386-c.o): Likewise.
2877         * config/i386/t-interix (winnt.o): Likewise.
2878         * config/i386/t-netware (netware.o): Likewise.
2879         * config/i386/t-nwld (nwld.o): Likewise.
2880         * config/i386/x-darwin (host-i386-darwin.o): Likewise.
2881         * config/i386/x-i386 (driver-i386.o): Likewise.
2882         * config/i386/x-cygwin (host-cygwin.o): Likewise.
2883         * config/i386/x-mingw32 (host-mingw32.o): Likewise.
2884         * config/ia64/t-ia64 (ia64-c.o): Likewise.
2885         * config/m32c/t-m32c (m32c-pragma.o): Likewise.
2886         * config/mips/x-native (driver-native.o): Likewise.
2887         * config/rs6000/t-rs6000 (rs6000-c.o): Likewise.
2888         * config/rs6000/x-darwin (host-ppc-darwin.o): Likewise.
2889         * config/rs6000/x-darwin64 (host-ppc64-darwin.o): Likewise.
2890         * config/rs6000/x-rs6000 (driver-rs6000.o): Likewise.
2891         * config/score/t-score-elf (score7.o): Likewise.
2892         (score3.o): Likewise.
2893         * config/sh/t-sh (sh-c.o): Likewise.
2894         * config/sh/t-symbian (sh-c.o): Likewise.
2895         (symbian.o): Likewise.
2896         * config/spu/t-spu-elf (spu-c.o): Likewise.
2897         * config/v850/t-v850 (v850-c.o): Likewise.
2898         * config/v850/t-v850e (v850-c.o): Likewise.
2899
2900 2009-05-26  Richard Guenther  <rguenther@suse.de>
2901
2902         PR tree-optimization/40122
2903         * tree-ssa-ccp.c (ccp_fold): Fold vector CONSTRUCTORs to
2904         VECTOR_CSTs if possible.
2905         (fold_gimple_assign): Likewise.
2906
2907 2009-05-26  Richard Guenther  <rguenther@suse.de>
2908
2909         PR middle-end/40252
2910         * fold-const.c (fold_binary): Use the correct types for building
2911         rotates.
2912
2913 2009-05-26  Richard Guenther  <rguenther@suse.de>
2914
2915         * tree-vect-data-refs.c (vect_create_data_ref_ptr): Remove
2916         redundant calls to merge_alias_info.
2917         (bump_vector_ptr): Likewise.
2918         * tree-ssa-copy.c (merge_alias_info): Remove.
2919         (replace_exp_1): Remove call to merge_alias_info.
2920         (propagate_tree_value): Likewise.
2921         (fini_copy_prop): Propagate points-to info.
2922         * tree-flow.h (merge_alias_info): Remove.
2923
2924 2009-05-07  Hariharan Sandanagobalane <hariharan@picochip.com>
2925
2926         * config/picochip/picochip.C (PARAM_INLINE_CALL_COST): Remove.
2927
2928 2009-05-25  Jan Hubicka  <jh@suse.cz>
2929
2930         * cgraph.c (dump_cgraph_node): Dump size/time/benefit.
2931         * cgraph.h (struct inline_summary): New filed self_wize,
2932         size_inlining_benefit, self_time and time_inlining_benefit.
2933         (struct cgraph_global_info): Replace insns by time ans size fields.
2934         * ipa-cp (ipcp_cloning_candidate_p): Base estimate on size
2935         (ipcp_estimate_growth, ipcp_insert_stage): Likewise.
2936         (ipcp_update_callgraph): Do not touch function bodies.
2937         * ipa-inline.c: Include except.h
2938         (MAX_TIME): New constant.
2939         (overall_insns): Remove.
2940         (leaf_node_p): New.
2941         (overall_size, max_benefit): New static variables.
2942         (cgraph_estimate_time_after_inlining): New function.
2943         (cgraph_estimate_size_after_inlining): Rewrite using benefits.
2944         (cgraph_clone_inlined_nodes): Update size.
2945         (cgraph_mark_inline_edge): Update size.
2946         (cgraph_estimate_growth): Use size info.
2947         (cgraph_check_inline_limits): Check size.
2948         (cgraph_default_inline_p): Likewise.
2949         (cgraph_edge_badness): Compute badness based on benefit and size cost.
2950         (cgraph_decide_recursive_inlining): Check size.
2951         (cgraph_decide_inlining_of_small_function): Update size; dump sizes
2952         and times.
2953         (cgraph_decide_inlining): Likewise.
2954         (cgraph_decide_inlining_incrementally): Likewise; honor
2955         PARAM_EARLY_INLINING_INSNS.
2956         (likely_eliminated_by_inlining_p): New predicate.
2957         (estimate_function_body_sizes): New function.
2958         (compute_inline_parameters): Use it.
2959         * except.c (must_not_throw_labels): New function.
2960         * except.h (must_not_throw_labels): Declare.
2961         * tree-inline.c (init_inline_once): Kill inlining_weigths
2962         * tree-ssa-structalias.c: Avoid uninitialized warning.
2963         * params.def (PARAM_MAX_INLINE_INSNS_SINGLE): Reduce to 300.
2964         (PARAM_MAX_INLINE_INSNS_AUTO): Reduce to 60.
2965         (PARAM_INLINE_CALL_COST): Remove.
2966         (PARAM_EARLY_INLINING_INSNS): New.
2967
2968 2009-05-25  Richard Guenther  <rguenther@suse.de>
2969
2970         PR tree-optimization/36327
2971         * tree-ssa-alias.c (walk_non_aliased_vuses): Add second walker
2972         callback for reference translation or lookup at the point of may-defs.
2973         * tree-ssa-alias.h (walk_non_aliased_vuses): Adjust prototype.
2974         * tree-ssa-sccvn.c (get_ref_from_reference_ops): Bail out
2975         for union COMPONENT_REFs.
2976         (vn_reference_lookup_3): New callback.  Lookup from memset
2977         and CONSTRUCTOR assignment, translate through struct copies.
2978         (vn_reference_lookup_pieces): Make sure to not free the
2979         passed operands array.  Adjust walk_non_aliased_vuses call.
2980         (vn_reference_lookup): Adjust walk_non_aliased_vuses call,
2981         make sure we do not leak memory.
2982
2983 2009-05-25  Richard Guenther  <rguenther@suse.de>
2984
2985         * tree-ssa-alias.h (dump_points_to_solution): Declare.
2986         * tree-inline.c (expand_call_inline): Reset the escaped and
2987         callused solutions.
2988         * tree-ssa-structalias.c (pass_build_ealias): New.
2989         * tree-pass.h (pass_build_ealias): Declare.
2990         * passes.c (init_optimization_passes): Add PTA during 
2991         early optimizations.
2992         * tree-ssa-alias.c (dump_alias_info): Dump the ESCAPED
2993         and CALLUSED solutions.
2994         (dump_points_to_solution): New function, split out from ...
2995         (dump_points_to_info_for): ... here.
2996         * tree-parloops.c (parallelize_loops): Reset the escaped and
2997         callused solutions.
2998
2999 2009-05-25  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
3000
3001         PR bootstrap/40027
3002         * config/i386/i386.c (USE_HIDDEN_LINKONCE): Only define if missing.
3003         * config/i386/sol2.h [!TARGET_GNU_LD] (USE_HIDDEN_LINKONCE): Define.
3004
3005 2009-05-25  Ira Rosen  <irar@il.ibm.com>
3006
3007         PR tree-optimization/40238
3008         * tree-vect-stmts.c (vect_init_vector): Insert initialization
3009         statements after basic block's labels.
3010         * tree-vect-slp.c (vect_slp_transform_bb): Call destroy_bb_vec_info() 
3011         to free the allocated memory.
3012
3013 2009-05-24  Kaz Kojima  <kkojima@gcc.gnu.org>
3014
3015         * gcc/config/sh/sh.c (sh_set_return_address): Mark store of
3016         return address with a USE.
3017
3018 2009-05-24  Richard Guenther  <rguenther@suse.de>
3019
3020         PR middle-end/40233
3021         * tree.c (make_vector_type): Build the TYPE_DEBUG_REPRESENTATION_TYPEs
3022         array type from the main variant of the inner type.
3023
3024 2009-05-24  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
3025
3026         * config/vax/vax-protos.h (legitimate_constant_address_p): Change
3027         definition to bool (from int) to un-break build.
3028         (legitimate_constant_p, vax_mode_dependent_address_p): Likewise.
3029
3030 2009-05-24  Paolo Bonzini  <bonzini@gnu.org>
3031
3032         * tree-ssa-operands.h (push_stmt_changes, pop_stmt_changes,
3033         discard_stmt_changes): Delete.
3034         * tree-ssa-operands.c (scb_stack): Delete.
3035         (init_ssa_operands): Do not initialize it.
3036         (fini_ssa_operands): Do not free it.
3037         (push_stmt_changes, pop_stmt_changes, discard_stmt_changes): Delete.
3038
3039         * tree-cfg.c (replace_uses_by): Replace pop_stmt_changes with 
3040         update_stmt, remove the others.  Fix comments.
3041         * tree-dfa.c (optimize_stack_restore): Likewise.
3042         * tree-ssa-forwprop.c (forward_propagate_addr_expr): Likewise.
3043         * tree-ssa-loop-ivopts.c (rewrite_use): Likewise.
3044         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Likewise.
3045         * tree-ssa-ccp.c (optimize_stack_restore, execute_fold_all_builtins):
3046         Likewise.
3047         * tree-ssa-propagate.c (substitute_and_fold): Likewise.
3048         * tree-ssa-dom.c (propagate_rhs_into_lhs): Likewise.
3049         (dom_opt_finalize_block): Likewise, adjusting access to
3050         stmts_to_rescan.
3051         (optimize_stmt): Likewise, adjusting access to stmts_to_rescan.
3052         (stmts_to_rescan): Change item type to gimple.
3053         (tree_ssa_dominator_optimize): Change type of stmts_to_rescan.
3054
3055 2009-05-24  Ira Rosen  <irar@il.ibm.com>
3056
3057         * doc/passes.texi (Tree-SSA passes): Document SLP pass.
3058         * tree-pass.h (pass_slp_vectorize): New pass.
3059         * params.h (SLP_MAX_INSNS_IN_BB): Define.
3060         * timevar.def (TV_TREE_SLP_VECTORIZATION): Define.
3061         * tree-vectorizer.c (timevar.h): Include.
3062         (user_vect_verbosity_level): Declare.
3063         (vect_location): Fix comment.
3064         (vect_set_verbosity_level): Update user_vect_verbosity_level
3065         instead of vect_verbosity_level.
3066         (vect_set_dump_settings): Add an argument. Ignore user defined
3067         verbosity if dump flags require higher level of verbosity. Print to
3068         stderr only for loop vectorization.
3069         (vectorize_loops): Update call to vect_set_dump_settings.
3070         (execute_vect_slp): New function.
3071         (gate_vect_slp): Likewise.
3072         (struct gimple_opt_pass pass_slp_vectorize): New.
3073         * tree-vectorizer.h (struct _bb_vec_info): Define along macros to
3074         access its members.
3075         (vec_info_for_bb): New function.
3076         (struct _stmt_vec_info): Add bb_vinfo and a macro for its access.
3077         (VECTORIZATION_ENABLED): New macro.
3078         (SLP_ENABLED, SLP_DISABLED): Likewise.
3079         (vect_is_simple_use): Add bb_vec_info argument.
3080         (new_stmt_vec_info, vect_analyze_data_ref_dependences,
3081         vect_analyze_data_refs_alignment, vect_verify_datarefs_alignment,
3082         vect_analyze_data_ref_accesses, vect_analyze_data_refs,
3083         vect_schedule_slp, vect_analyze_slp): Likewise.
3084         (vect_analyze_stmt): Add slp_tree argument.
3085         (find_bb_location): Declare.
3086         (vect_slp_analyze_bb, vect_slp_transform_bb): Likewise.
3087         * tree-vect-loop.c (new_loop_vec_info): Adjust function calls.
3088         (vect_analyze_loop_operations, vect_analyze_loop,
3089         get_initial_def_for_induction, vect_create_epilog_for_reduction,
3090         vect_finalize_reduction, vectorizable_reduction,
3091         vectorizable_live_operation, vect_transform_loop): Likewise.
3092         * tree-data-ref.c (dr_analyze_innermost): Update comment,
3093         skip evolution analysis if analyzing a basic block.
3094         (dr_analyze_indices): Likewise.
3095         (initialize_data_dependence_relation): Skip the test whether the
3096         object is invariant for basic blocks.
3097         (compute_all_dependences): Skip dependence analysis for data
3098         references in basic blocks.
3099         (find_data_references_in_stmt): Don't fail in case of invariant
3100         access in basic block.
3101         (find_data_references_in_bb): New function.
3102         (find_data_references_in_loop): Move code to
3103         find_data_references_in_bb and add a call to it.
3104         (compute_data_dependences_for_bb): New function.
3105         * tree-data-ref.h (compute_data_dependences_for_bb): Declare.
3106         * tree-vect-data-refs.c (vect_check_interleaving): Adjust to the case
3107         that STEP is 0.
3108         (vect_analyze_data_ref_dependence): Check for interleaving in case of
3109         unknown dependence in basic block and fail in case of dependence in
3110         basic block.
3111         (vect_analyze_data_ref_dependences): Add bb_vinfo argument, get data
3112         dependence instances from either loop or basic block vectorization
3113         info.
3114         (vect_compute_data_ref_alignment): Check if it is loop vectorization
3115         before calling nested_in_vect_loop_p.
3116         (vect_compute_data_refs_alignment): Add bb_vinfo argument, get data
3117         dependence instances from either loop or basic block vectorization
3118         info.
3119         (vect_verify_datarefs_alignment): Likewise.
3120         (vect_enhance_data_refs_alignment): Adjust function calls.
3121         (vect_analyze_data_refs_alignment): Likewise.
3122         (vect_analyze_group_access): Fix printing. Skip different checks if
3123         DR_STEP is 0. Keep strided stores either in loop or basic block
3124         vectorization data structure. Fix indentation.
3125         (vect_analyze_data_ref_access): Fix comments, allow zero step in
3126         basic blocks.
3127         (vect_analyze_data_ref_accesses): Add bb_vinfo argument, get data
3128         dependence instances from either loop or basic block vectorization
3129         info.
3130         (vect_analyze_data_refs): Update comment. Call
3131         compute_data_dependences_for_bb to analyze basic blocks.
3132         (vect_create_addr_base_for_vector_ref): Check for outer loop only in
3133         case of loop vectorization. In case of basic block vectorization use
3134         data-ref itself as a base.
3135         (vect_create_data_ref_ptr): In case of basic block vectorization:
3136         don't advance the pointer, add new statements before the current
3137         statement.  Adjust function calls.
3138         (vect_supportable_dr_alignment): Support only aligned accesses in
3139         basic block vectorization.
3140         * common.opt (ftree-slp-vectorize): New flag.
3141         * tree-vect-patterns.c (widened_name_p): Adjust function calls.
3142         (vect_pattern_recog_1): Likewise.
3143         * tree-vect-stmts.c (process_use): Likewise.
3144         (vect_init_vector): Add new statements in the beginning of the basic
3145         block in case of basic block SLP.
3146         (vect_get_vec_def_for_operand): Adjust function calls.
3147         (vect_finish_stmt_generation): Likewise.
3148         (vectorizable_call): Add assert that it is loop vectorization, adjust
3149         function calls.
3150         (vectorizable_conversion, vectorizable_assignment): Likewise.
3151         (vectorizable_operation): In case of basic block SLP, take
3152         vectorization factor from statement's type and skip the relevance
3153         check. Adjust function calls.
3154         (vectorizable_type_demotion): Add assert that it is loop
3155         vectorization, adjust function calls.
3156         (vectorizable_type_promotion): Likewise.
3157         (vectorizable_store): Check for outer loop only in case of loop
3158         vectorization. Adjust function calls. For basic blocks, skip the
3159         relevance check and don't advance pointers.
3160         (vectorizable_load): Likewise.
3161         (vectorizable_condition): Add assert that it is loop vectorization,
3162         adjust function calls.
3163         (vect_analyze_stmt): Add argument. In case of basic block SLP, check
3164         that it is not reduction, get vector type, call only supported
3165         functions, skip loop specific parts.
3166         (vect_transform_stmt): Check for outer loop only in case of loop
3167         vectorization.
3168         (new_stmt_vec_info): Add new argument and initialize bb_vinfo.
3169         (vect_is_simple_use): Fix comment, add new argument, fix conditions
3170         for external definition.
3171         * passes.c (pass_slp_vectorize): New pass.
3172         * tree-vect-slp.c (find_bb_location): New function.
3173         (vect_get_and_check_slp_defs): Add argument, adjust function calls,
3174         check for patterns only in loops.
3175         (vect_build_slp_tree): Add argument, adjust function calls, fail in
3176         case of multiple types in basic block SLP.
3177         (vect_mark_slp_stmts_relevant): New function.
3178         (vect_supported_load_permutation_p): Fix comment.
3179         (vect_analyze_slp_instance): Add argument. In case of basic block
3180         SLP, take vectorization factor from statement's type, check that
3181         unrolling factor is 1. Adjust function call. Save SLP instance in
3182         either loop or basic block vectorization structure. Return FALSE,
3183         if SLP failed.
3184         (vect_analyze_slp): Add argument. Get strided stores groups from
3185         either loop or basic block vectorization structure. Return FALSE
3186         if basic block SLP failed.
3187         (new_bb_vec_info): New function.
3188         (destroy_bb_vec_info, vect_slp_analyze_node_operations,
3189         vect_slp_analyze_operations, vect_slp_analyze_bb): Likewise.
3190         (vect_schedule_slp): Add argument. Get SLP instances from either
3191         loop or basic block vectorization structure. Set vectorization factor
3192         to be 1 for basic block SLP.
3193         (vect_slp_transform_bb): New function.
3194         * params.def (PARAM_SLP_MAX_INSNS_IN_BB): Define.
3195
3196 2009-05-23  Mark Mitchell  <mark@codesourcery.com>
3197
3198         * final.c (shorten_branches): Do not align labels for jump tables.
3199         (final_scan_insn): Use JUMP_TABLE_DATA_P.
3200
3201 2009-05-23  Eric Botcazou  <ebotcazou@adacore.com>
3202
3203         * doc/passes.texi: Standardize spelling of RTL, Tree and Tree SSA.
3204         Remove outdated reference to flow.c and fix nits.
3205         * doc/gccint.texi: Tweak RTL description.
3206         * doc/rtl.texi: Likewise.
3207
3208 2009-05-23  Denis Chertykov  <chertykov@gmail.com>
3209
3210         * config/avr/avr.c: Change my email address.
3211         * config/avr/avr.h: Likewise.
3212         * config/avr/avr.md: Likewise.
3213         * config/avr/avr-protos.h: Likewise.
3214         * config/avr/libgcc.S: Likewise.
3215
3216 2009-05-22  Trevor Smigiel <Trevor_Smigiel@playstation.sony.com>
3217
3218         * config/spu/spu-protos.h (aligned_mem_p, spu_valid_mov): Remove.
3219         (spu_split_load, spu_split_store): Change return type to int.
3220         (spu_split_convert): Declare.
3221         * config/spu/predicates.md (spu_mem_operand): Remove.
3222         (spu_mov_operand): Update.
3223         (spu_dest_operand, shiftrt_operator, extend_operator): Define.
3224         * config/spu/spu.c (regno_aligned_for_load): Remove.
3225         (reg_aligned_for_addr, spu_expand_load): Define.
3226         (spu_expand_extv): Reimplement and handle MEM.
3227         (spu_expand_insv): Handle MEM.
3228         (spu_sched_reorder): Handle insn's with length 0.
3229         (spu_legitimate_address_p): Reimplement.
3230         (store_with_one_insn_p): Return TRUE for any mode with size
3231         larger than 16 bytes.
3232         (address_needs_split): Define.
3233         (spu_expand_mov): Call spu_split_load and spu_split_store for MEM
3234         operands.
3235         (spu_convert_move): Define.
3236         (spu_split_load): Use spu_expand_load and change all MEM's to TImode.
3237         (spu_split_store): Change all MEM's to TImode.
3238         (spu_init_expanders): Preallocate registers that correspond to
3239         LAST_VIRTUAL_REG+1 and LAST_VIRTUAL_REG+2 and set them with
3240         mark_reg_pointer.
3241         (spu_split_convert): Define.
3242         * config/spu/spu.md (QHSI, QHSDI): New mode iterators.
3243         (_move<mode>, _movdi, _movti): Update predicate and condition.
3244         (load, store): Change to define_split.
3245         (extendqiti2, extendhiti2, extendsiti2, extendditi2): Simplify to
3246         extend<mode>ti2.
3247         (zero_extendqiti2, zero_extendhiti2, <v>lshr<mode>3_imm): Define.
3248         (lshr<mode>3, lshr<mode>3_imm, lshr<mode>3_re): Simplify to one
3249         define_insn_and_split of lshr<mode>3.
3250         (shrqbybi_<mode>, shrqby_<mode>): Simplify to define_expand.
3251         (<v>ashr<mode>3_imm): Define.
3252         (extv, extzv, insv): Allow MEM operands.
3253         (trunc_shr_ti<mode>, trunc_shr_tidi, shl_ext_<mode>ti,
3254         shl_ext_diti, sext_trunc_lshr_tiqisi, zext_trunc_lshr_tiqisi,
3255         sext_trunc_lshr_tihisi, zext_trunc_lshr_tihisi): Define for combine.
3256         (_spu_convert2): Change to define_insn_and_split and remove the
3257         corresponding define_peephole2.
3258         (stack_protect_set, stack_protect_test, stack_protect_test_si):
3259         Change predicates to memory_operand.
3260
3261 2009-05-22  Mark Mitchell  <mark@codesourcery.com>
3262
3263         * config/arm/thumb2.md: Add 16-bit multiply instructions.
3264
3265 2009-05-21  Michael Meissner  <meissner@linux.vnet.ibm.com>
3266
3267         PR tree-optimization/40219
3268         * tree.c (iterative_hash_expr): Make sure the builtin function is
3269         a normal builtin function and not a front end or back end builtin
3270         before indexing into the built_in_decls array.
3271
3272 2009-05-22  Richard Guenther  <rguenther@suse.de>
3273
3274         PR middle-end/38964
3275         * alias.c (write_dependence_p): Do not use TBAA for answering
3276         anti-dependence or output-dependence.
3277         * tree-ssa-structalias.c (set_uids_in_ptset): Remove TBAA pruning code.
3278         (emit_pointer_definition): Remove.
3279         (emit_alias_warning): Likewise.
3280         (find_what_var_points_to): Remove TBAA pruning code.
3281         (find_what_p_points_to): Likewise.  Do not warn about strict-aliasing
3282         violations.
3283         (compute_points_to_sets): Remove code computing the set of
3284         dereferenced pointers.
3285         * tree-data-ref.c (dr_may_alias_p): Properly use the split
3286         oracle for querying anti and output dependencies.
3287         * tree-ssa-alias.c (refs_may_alias_p_1): Add argument specifying
3288         if TBAA may be applied.
3289         (refs_anti_dependent_p): New function.
3290         (refs_output_dependent_p): Likewise.
3291         * tree-ssa-alias.h (refs_anti_dependent_p): Declare.
3292         (refs_output_dependent_p): Likewise.
3293         * doc/tree-ssa.texi (Memory model): New section.
3294         * doc/c-tree.texi (CHANGE_DYNAMIC_TYPE_EXPR): Remove.
3295         * doc/gimple.texi (GIMPLE_CHANGE_DYNAMIC_TYPE): Remove.
3296         * cfgexpand.c (expand_gimple_basic_block): Do not handle
3297         GIMPLE_CHANGE_DYNAMIC_TYPE or CHANGE_DYNAMIC_TYPE_EXPR.
3298         * expr.c (expand_expr_real_1): Likewise.
3299         * gimple-low.c (lower_stmt): Likewise.
3300         * gimple-pretty-print.c (dump_gimple_stmt): Likewise.
3301         (dump_gimple_cdt): Remove.
3302         * gimple.c (gss_for_code): Do not handle GIMPLE_CHANGE_DYNAMIC_TYPE.
3303         (gimple_size): Likewise.
3304         (walk_gimple_op): Likewise.
3305         (is_gimple_stmt): Likewise.
3306         (walk_stmt_load_store_addr_ops): Likewise.
3307         (gimple_build_cdt): Remove.
3308         * gimple.def (GIMPLE_CHANGE_DYNAMIC_TYPE): Remove.
3309         * gimple.h (gimple_cdt_new_type): Remove.
3310         (gimple_cdt_new_type_ptr): Likewise.
3311         (gimple_cdt_set_new_type): Likewise.
3312         (gimple_cdt_location): Likewise.
3313         (gimple_cdt_location_ptr): Likewise.
3314         (gimple_cdt_set_location): Likewise.
3315         * gimplify.c (gimplify_expr): Do not handle CHANGE_DYNAMIC_TYPE_EXPR.
3316         * tree-cfg.c (remove_useless_stmts_1): Do not handle
3317         GIMPLE_CHANGE_DYNAMIC_TYPE.
3318         (verify_types_in_gimple_stmt): Likewise.
3319         * tree-inline.c (estimate_num_insns): Likewise.
3320         (expand_call_inline): Do not copy DECL_NO_TBAA_P.
3321         (copy_decl_to_var): Likewise.
3322         (copy_result_decl_to_var): Likewise.
3323         * tree-pretty-print.c (dump_generic_node): Do not handle
3324         CHANGE_DYNAMIC_TYPE_EXPR.
3325         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
3326         * tree-ssa-operands.c (get_expr_operands): Likewise.
3327         * tree-ssa-structalias.c (struct variable_info): Remove
3328         no_tbaa_pruning member.
3329         (new_var_info): Do not set it based on DECL_NO_TBAA_P.
3330         (unify_nodes): Do not copy it.
3331         (find_func_aliases): Do not handle GIMPLE_CHANGE_DYNAMIC_TYPE.
3332         (dump_solution_for_var): Do not dump no_tbaa_pruning state.
3333         (set_uids_in_ptset): Do not check it.
3334         (find_what_var_points_to): Likewise.
3335         (compute_tbaa_pruning): Remove.
3336         (compute_points_to_sets): Do not call it.
3337         * tree.c (walk_tree_1): Do not handle CHANGE_DYNAMIC_TYPE_EXPR.
3338         * tree.def (CHANGE_DYNAMIC_TYPE_EXPR): Remove.
3339         * tree.h (CHANGE_DYNAMIC_TYPE_NEW_TYPE): Remove.
3340         (CHANGE_DYNAMIC_TYPE_LOCATION): Likewise.
3341         (DECL_NO_TBAA_P): Likewise.
3342         (struct tree_decl_common): Move no_tbaa_flag to unused flags section.
3343         * omp-low.c (copy_var_decl): Do not copy DECL_NO_TBAA_P.
3344         (expand_omp_atomic_pipeline): Do not set it.
3345         * print-tree.c (print_node): Do not dump it.
3346         * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Remove
3347         redundant check.
3348
3349 2009-05-22 Vladimir Makarov <vmakarov@redhat.com>
3350
3351         PR target/39856
3352         * reg-stack.c (subst_stack_regs_pat): Remove gcc_assert for note
3353         for clobber.
3354
3355 2009-05-22  Mark Mitchell  <mark@codesourcery.com>
3356
3357         * tree.c (handle_dll_attribute): Mark dllexport'd inlines as
3358         non-external.
3359
3360 2009-05-22  Ben Elliston  <bje@au.ibm.com>
3361
3362         * Makefile.in (bversion.h, s-bversion): New targets.
3363         (TOPLEV_H): Add bversion.h.
3364         * toplev.h: Include "bversion.h".
3365         (ATTRIBUTE_GCC_DIAG): When building with checking disabled, use
3366         the __format__ attribute only if compiling with the same version
3367         of GCC as the sources (the "build version").
3368
3369 2009-05-22  Ben Elliston  <bje@au.ibm.com>