OSDN Git Service

2007-02-18 David Edelsohn <edelsohn@gnu.org>
[pf3gnuchains/gcc-fork.git] / gcc / ChangeLog
1 2007-02-18  David Edelsohn  <edelsohn@gnu.org>
2             Roger Sayle  <roger@eyesopen.com>
3
4         * config/rs6000/rs6000.md (bswapsi2): New define_insn and splitter.
5
6 2007-02-18  Sandra Loosemore  <sandra@codesourcery.com>
7
8         * calls.c (initialize_argument_information): Pass original EXP
9         and STRUCT_VALUE_ADDR_VALUE instead of a list of arguments.  Move
10         code to split complex arguments here, as part of initializing the
11         ARGS array.
12         (expand_call): Remove code that builds a list of arguments and
13         inserts implicit arguments into it.  Instead, just count how many
14         implicit arguments there will be so we can determine the size of
15         the ARGS array, and let initialize_argument_information do the work.
16         (split_complex_values): Delete unused function.
17
18 2007-02-18  Eric Botcazou  <ebotcazou@adacore.com>
19
20         * tree-eh.c (tree_could_trap_p): Handle VIEW_CONVERT_EXPR.
21
22 2007-02-18  Eric Botcazou  <ebotcazou@adacore.com>
23
24         * calls.c (mem_overlaps_already_clobbered_arg_p): Return true
25         for arg pointer based indexed addressing.
26
27 2007-02-18  Kazu Hirata  <kazu@codesourcery.com>
28
29         * config/ia64/ia64.h, config/ia64/ia64.md,
30         config/ia64/predicates.md, config/ia64/sysv4.h: Follow
31         spelling conventions.
32
33 2007-02-18  Roman Zippel <zippel@linux-m68k.org>
34
35         * config/m68k/m68k.c (split_di): New.
36         * config/m68k/m68k-protos.h: Declare split_di.
37         * config/m68k/m68k.md (extendsidi2*,ashldi3*,ashrdi3*,lshrdi3*):
38           Improve predicate handling and split constant shifts.
39
40 2007-02-18  Roman Zippel <zippel@linux-m68k.org>
41
42         * config/m68k/m68k.md (extv,extzv,insv): disable dynamic
43         parameter for register bitfield operations, general predicates
44         cleanup
45
46 2007-02-18  Roman Zippel <zippel@linux-m68k.org>
47
48         * config/m68k/linux.h (MD_UNWIND_SUPPORT): Define.
49         * config/m68k/linux-unwind.h: New file.
50
51 2007-02-18  Kazu Hirata  <kazu@codesourcery.com>
52
53         * cfgloop.c, config/alpha/alpha.c, config/bfin/bfin.c,
54         config/i386/athlon.md, config/ia64/ia64.md,
55         config/rs6000/rs6000.c, config/s390/s390.c, config/spu/spu.md,
56         df-problems.c, df.h, fold-const.c, ipa-cp.c, ipa-inline.c,
57         ipa-prop.h, see.c, struct-equiv.c, tree-inline.c,
58         tree-ssa-loop-niter.c, tree-vect-analyze.c,
59         tree-vect-transform.c: Fix comment typos.
60
61 2007-02-17  Kazu Hirata  <kazu@codesourcery.com>
62
63         * sched-deps.c (find_insn_list): Remove.
64         * sched-int.h: Remove the prototype for find_insn_list.
65
66 2007-02-16  Geoffrey Keating  <geoffk@apple.com>
67
68         * config/darwin.h (LINK_SPEC): Always pass -macosx_version_min
69         to linker.
70         (DARWIN_EXTRA_SPECS): Add %(darwin_minversion).
71         * config/rs6000/darwin.h (SUBTARGET_OVERRIDE_OPTIONS): Just call
72         darwin_rs6000_override_options.
73         (C_COMMON_OVERRIDE_OPTIONS): Expect
74         darwin_macosx_version_min to be non-NULL always.
75         (TARGET_C99_FUNCTIONS): Likewise.
76         (CC1_SPEC): Always pass -mmacosx-version-min to cc1*.
77         (DARWIN_MINVERSION_SPEC): New.
78         * config/rs6000/rs6000.c (darwin_rs6000_override_options): New.
79         * config/i386/darwin.h (CC1_SPEC): Always pass -mmacosx-version-min
80         to cc1*.  
81         (DARWIN_MINVERSION_SPEC): New.
82         * config/darwin.opt (mmacosx-version-min): Initialize to non-NULL
83         value.
84         * config/darwin-c.c (darwin_cpp_builtins): Expect
85         darwin_macosx_version_min to be non-NULL always.
86
87         * config/rs6000/rs6000.c: Clean up trailing whitespace.
88
89 2007-02-16  Uros Bizjak  <ubizjak@gmail.com>
90
91         * config/i386/i386.h (x86_use_xchgb): New.
92         (TARGET_USE_XCHGB): New macro.
93         * config/i386/i386.c (x86_use_xchgb): Set for PENT4.
94         * config/i386/i386.md (*rotlhi3_1 splitter, *rotrhi3_1 splitter):
95         Split after reload into bswaphi for shifts of 8.
96         (bswaphi_lowpart): Generate rolw insn for HImode byte swaps.
97         (*bswaphi_lowpart_1): Generate xchgb for Q registers for TARGET_XCHGB
98         or when optimizing for size.
99         
100 2007-02-16  Richard Guenther  <rguenther@suse.de>
101             Christian Bruel  <christian.bruel@st.com>
102
103         * fold-const.c (tree_swap_operands_p): Treat SSA_NAMEs like
104         DECLs but prefer SSA_NAMEs over DECLs.
105
106 2007-02-16  Richard Guenther  <rguenther@suse.de>
107
108         * tree-flow-inline.h (single_imm_use_p): Remove.
109         (zero_imm_uses_p): Likewise.
110         * tree-ssa-coalesce.c (create_outofssa_var_map): Use has_single_use
111         instead of single_imm_use_p.
112         * tree-cfg.c (replace_uses_by): Use has_zero_use instead of
113         zero_imm_uses_p.
114
115 2007-02-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
116
117         PR other/27843
118         * Makefile.in (SYSTEM_HEADER_DIR): Use single quotes to avoid
119         nested double- and backquotes.
120
121 2007-02-15  Roger Sayle  <roger@eyesopen.com>
122
123         PR middle-end/30391
124         * tree.c (expr_align): Handle MODIFY_EXPR.  GIMPLE_MODIFY_STMT
125         should be unreachable.
126         (build2_stat): Allow construction of MODIFY_EXPR at any time.
127         For the time being redirect GIMPLE_MODIFY_STMT to the new
128         (renamed) build_gimple_modify_stmt_stat.
129         (build2_gimple_stat): Rename to...
130         (build_gimple_modify_stmt_stat): Now longer take a CODE argument.
131         Always build a GIMPLE_MODIFY_STMT node.
132         * tree.h (build2_gimple, build2_gimple_stat): Delete.
133         (build_gimple_modify_stmt, build_gimple_modify_stmt_stat): New
134         declarations.
135
136         * tree-cfg.c (factor_computed_gotos, tree_merge_blocks,
137         gimplify_val): Use build_gimple_modify_stmt instead of build2_gimple.
138         * tree-complex.c (set_component_ssa_name, expand_complex_move,
139         expand_complex_div_wide): Likewise.
140         * tree-ssa-dom.c (record_equivalences_from_stmt): Likewise.
141         * tree-ssa-loop-im.c (schedule_sm): Likewise.
142         * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Likewise.
143         * tree-ssa-loop-manip.c (create_iv): Likewise.
144         * tree-ssa-phiopt.c (conditional_replacement, minmax_replacement,
145         abs_replacement): Likewise.
146         * tree-ssa-pre.c (create_expression_by_pieces, poolify_modify_stmt,
147         realify_fake_stores): Likewise.
148
149         * builtins.c (std_expand_builtin_va_start): Build a MODIFY_EXPR
150         node rather than a GIMPLE_MODIFY_STMT node.
151         (std_gimpify_va_arg_expr, expand_builtin_va_copy,
152         fold_builtin_memset, fold_builtin_memory_op, do_mpfr_sincos):
153         Likewise.
154         (integer_valued_real_p): Handle MODIFY_EXPR, not GIMPLE_MODIFY_STMT.
155         * expr.c (expand_expr_real_1): Handle both MODIFY_EXPR and
156         GIMPLE_MODIFY_STMT.
157
158 2007-02-15  Andrew Pinski  <andrew_pinski@playstation.sony.com>
159
160         PR middle-end/30433
161         * fold-const.c (fold_comparison): Add back the
162         folding of constant complex comparisions.
163
164 2007-02-15  Andrew Pinski  <andrew_pinski@playstation.sony.com>
165
166         PR middle-end/30729
167         * stmt.c (warn_if_unused_value): VA_ARG_EXPR has side
168         effects unknown to this function, return early.
169
170 2007-02-15  Ian Lance Taylor  <iant@google.com>
171
172         * lower-subreg.c (move_eh_region_note): New static function.
173         (resolve_simple_move): Call it.
174         (decompose_multiword_subregs): Track blocks for which we resolve a
175         simple move which is also a control flow insn.  Pass them to
176         find_many_sub_basic_blocks.
177         (pass_lower_subreg): Add TODO_verify_flow.
178         (pass_lower_subreg2): Likewise.
179
180 2007-02-15  Sandra Loosemore  <sandra@codesourcery.com>
181             Brooks Moses  <brooks.moses@codesourcery.com>
182             Lee Millward  <lee.millward@codesourcery.com>
183
184         * tree.h (enum tree_code_class): Add tcc_vl_exp.
185         (VL_EXP_CLASS_P): New.
186         (TREE_OPERAND_CHECK): Use TREE_OPERAND_LENGTH instead of
187         TREE_CODE_LENGTH.
188         (TREE_OPERAND_CHECK_CODE): Likewise.
189         (GIMPLE_STMT_OPERAND_CHECK): Likewise.
190         (TREE_RTL_OPERAND_CHECK): Likewise.
191         (tree_operand_check_failed): Make second parameter the whole tree
192         instead of its code.  Fixed callers.
193         (VL_EXP_CHECK): New.
194         (TREE_OPERAND_LENGTH): New.
195         (VL_EXP_OPERAND_LENGTH): New.
196         (CALL_EXPR_FN): New.
197         (CALL_EXPR_STATIC_CHAIN): New.
198         (CALL_EXPR_ARGS): New.
199         (CALL_EXPR_ARG): New.
200         (call_expr_nargs): New.
201         (CALL_EXPR_ARGP): New.
202         (build_nt_call_list): Declare.
203         (build_vl_exp_stat): Declare.
204         (build_vl_exp): New.
205         (build_call_list): Declare.
206         (build_call_nary): Declare.
207         (build_call_valist): Declare.
208         (build_call_array): Declare.
209         (call_expr_arg): Declare.
210         (call_expr_argp): Declare.
211         (call_expr_arglist): Declare.
212         (fold_build_call_list): Declare.
213         (fold_build_call_list_initializer): Declare.
214         (fold_call_expr): Declare to replace fold_builtin.
215         (fold_builtin_fputs): Update to agree with modified definition.
216         (fold_builtin_strcpy): Likewise.
217         (fold_builtin_strncpy): Likewise.
218         (fold_builtin_memory_chk): Likewise.
219         (fold_builtin_stxcpy_chk): Likewise.
220         (fold_builtin_strncpy_chk): Likewise.
221         (fold_builtin_next_arg): Likewise.
222         (fold_build_call_expr): Declare.
223         (fold_builtin_call_list): Declare.
224         (fold_builtin_call_valist): Declare.
225         (build_call_expr): Declare.
226         (validate_arglist): Update to agree with modified definition.
227         (tree_operand_length): New.
228         (call_expr_arg_iterator): New.
229         (init_call_expr_arg_iterator): New.
230         (next_call_expr_arg): New.
231         (first_call_expr_arg): New.
232         (more_call_expr_args_p): New.
233         (FOR_EACH_CALL_EXPR_ARG): New.
234
235         * tree.c (tree_code_class_string): Add entries for tcc_vl_exp
236         and tcc_gimple_stmt.
237         (tree_code_size): Update documentation.  Use sizeof (tree) rather
238         than sizeof (char *).
239         (tree_size): Likewise.  Add case for tcc_vl_exp.
240         (tree_node_structure): Add case for tcc_vl_exp.
241         (contains_placeholder_p): Likewise.
242         (substitute_in_expr): Likewise.
243         (substitute_placeholder_in_expr): Likewise.
244         (stabilize_reference_1): Likewise.
245         (build3_stat): Remove logic for CALL_EXPRs.  Replace with assertion
246         to diagnose breakage of this interface for constructing CALL_EXPRs.
247         (build_nt): Add similar assertion here.
248         (build_nt_call_list): New.
249         (simple_cst_equal) <CALL_EXPR>: Rewrite to use new accessors.
250         (iterative_hash_expr): Use TREE_OPERAND_LENGTH instead of
251         TREE_CODE_LENGTH.
252         (get_callee_fndecl): Use new CALL_EXPR accessors.
253         (tree_operand_check_failed): Change parameters to pass entire node
254         instead of its code, so that we can call TREE_OPERAND_LENGTH on it.
255         (process_call_operands): New.
256         (build_vl_exp_stat): New.
257         (build_call_list): New.
258         (build_call_nary): New.
259         (build_call_valist): New.
260         (build_call_array): New.
261         (walk_tree): Use TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
262         (call_expr_arglist): New.
263
264         * tree.def (CALL_EXPR): Change representation of CALL_EXPRs to use
265         tcc_vl_exp instead of a fixed-size tcc_expression.
266
267         * doc/c-tree.texi (CALL_EXPR): Document new representation and
268         accessors for CALL_EXPRs.
269         (AGGR_INIT_EXPR): Likewise.
270
271 2007-02-15  Sandra Loosemore  <sandra@codesourcery.com>
272             Brooks Moses  <brooks.moses@codesourcery.com>
273             Lee Millward  <lee.millward@codesourcery.com>
274
275         * builtins.c (c_strlen): Return NULL_TREE instead of 0.
276         (expand_builtin_nonlocal_goto): Change parameter to be entire
277         CALL_EXPR instead of an arglist.  Use new CALL_EXPR accessors.
278         (expand_builtin_prefetch): Likewise.
279         (expand_builtin_classify_type): Likewise.
280         (mathfn_built_in): Return NULL_TREE instead of 0.
281         (expand_errno_check): Use new CALL_EXPR accessors.
282         (expand_builtin_mathfn): Use new CALL_EXPR accessors and constructors.
283         Return NULL_RTX instead of 0.
284         (expand_builtin_mathfn_2): Likewise.
285         (expand_builtin_mathfn_3): Likewise.
286         (expand_builtin_interclass_mathfn): Likewise.
287         (expand_builtin_sincos): Likewise.
288         (expand_builtin_cexpi): Likewise.
289         (expand_builtin_int_roundingfn): Likewise.
290         (expand_builtin_int_roundingfn_2): Likewise.
291         (expand_builtin_pow): Likewise.
292         (expand_builtin_powi): Likewise.
293         (expand_builtin_strlen): Pass entire CALL_EXPR as parameter instead
294         of arglist, fixing callers appropriately.  Use new CALL_EXPR
295         accessors and constructors.  Return NULL_RTX instead of 0.
296         (expand_builtin_strstr): Likewise.
297         (expand_builtin_strchr): Likewise.
298         (expand_builtin_strrchr): Likewise.
299         (expand_builtin_strpbrk): Likewise.
300         (expand_builtin_memcpy): Likewise.
301         (expand_builtin_mempcpy): Likewise.
302         (expand_builtin_mempcpy_args): New.
303         (expand_builtin_memmove): Similarly to expand_builtin_mempcpy.
304         (expand_builtin_memmove_args): New.
305         (expand_builtin_bcopy): Similarly to expand_builtin_mempcpy.
306         (expand_movstr): Likewise.
307         (expand_builtin_strcpy): Likewise.
308         (expand_builtin_strcpy_args): New.
309         (expand_builtin_stpcpy): Similarly to expand_builtin_strcpy.
310         (expand_builtin_strncpy): Likewise.
311         (expand_builtin_memset): Likewise.
312         (expand_builtin_memset_args): New.
313         (expand_builtin_bzero): Similarly to expand_builtin_memset.
314         (expand_builtin_memcmp): Likewise.
315         (expand_builtin_strcmp): Likewise.
316         (expand_builtin_strncmp): Likewise.
317         (expand_builtin_strcat): Likewise.
318         (expand_builtin_strncat): Likewise.
319         (expand_builtin_strspn): Likewise.
320         (expand_builtin_strcspn): Likewise.
321         (expand_builtin_args_info): Likewise.
322         (expand_builtin_va_start): Likewise.
323         (gimplify_va_arg_expr): Likewise.
324         (expand_builtin_va_end): Likewise.
325         (expand_builtin_va_copy): Likewise.
326         (expand_builtin_frame_address): Likewise.
327         (expand_builtin_alloca): Likewise.
328         (expand_builtin_bswap): Likewise.
329         (expand_builtin_unop): Likewise.
330         (expand_builtin_fputs): Likewise.
331         (expand_builtin_expect): Likewise.
332         (expand_builtin_fabs): Likewise.
333         (expand_builtin_copysign): Likewise.
334         (expand_builtin_printf): Likewise.
335         (expand_builtin_fprintf): Likewise.
336         (expand_builtin_sprintf): Likewise.
337         (expand_builtin_init_trampoline): Likewise.
338         (expand_builtin_signbit): Likewise.
339         (expand_builtin_fork_or_exec): Likewise.
340         (expand_builtin_sync_operation): Likewise.
341         (expand_builtin_compare_and_swap): Likewise.
342         (expand_builtin_lock_test_and_set): Likewise.
343         (expand_builtin_lock_release): Likewise.
344         (expand_builtin): Likewise.
345         (builtin_mathfn_code): Likewise.
346
347         (fold_builtin_constant_p): Pass call arguments individually instead
348         of as an arglist, fixing callers appropriately.  Use new CALL_EXPR
349         accessors and constructors.  Return NULL_TREE instead of 0.
350         (fold_builtin_expect): Likewise.
351         (fold_builtin_classify_type): Likewise.
352         (fold_builtin_strlen): Likewise.
353         (fold_builtin_nan): Likewise.
354         (integer_valued_real_p): Likewise.
355         (fold_trunc_transparent_mathfn): Likewise.
356         (fold_fixed_mathfn): Likewise.
357         (fold_builtin_cabs): Likewise.
358         (fold_builtin_sqrt): Likewise.
359         (fold_builtin_cbrt): Likewise.
360         (fold_builtin_cos): Likewise.
361         (fold_builtin_cosh): Likewise.
362         (fold_builtin_tan): Likewise.
363         (fold_builtin_sincos): Likewise.
364         (fold_builtin_cexp): Likewise.
365         (fold_builtin_trunc): Likewise.
366         (fold_builtin_floor): Likewise.
367         (fold_builtin_ceil): Likewise.
368         (fold_builtin_round): Likewise.
369         (fold_builtin_int_roundingfn): Likewise.
370         (fold_builtin_bitop): Likewise.
371         (fold_builtin_bswap): Likewise.
372         (fold_builtin_logarithm): Likewise.
373         (fold_builtin_hypot): Likewise.
374         (fold_builtin_pow): Likewise.
375         (fold_builtin_powi): Likewise.
376         (fold_builtin_exponent): Likewise.
377         (fold_builtin_memset): Likewise.
378         (fold_builtin_bzero): Likewise.
379         (fold_builtin_memory_op): Likewise.
380         (fold_builtin_bcopy): Deleted; call site changed to invoke
381         fold_builtin_memory_op directly.
382         (fold_builtin_strcpy): Similarly as for fold_builtin_memory_op.
383         (fold_builtin_strncpy): Likewise.
384         (fold_builtin_memcmp): Likewise.
385         (fold_builtin_strcmp): Likewise.
386         (fold_builtin_strncmp): Likewise.
387         (fold_builtin_signbit): Likewise.
388         (fold_builtin_copysign): Likewise.
389         (fold_builtin_isascii): Likewise.
390         (fold_builtin_toascii): Likewise.
391         (fold_builtin_isdigit): Likewise.
392         (fold_builtin_fabs): Likewise.
393         (fold_builtin_abs): Likewise.
394         (fold_builtin_fmin_fmax): Likewise.
395         (fold_builtin_carg): Likewise.
396         (fold_builtin_classify): Likewise.
397         (fold_builtin_unordered_cmp): Likewise.
398
399         (fold_builtin_0, fold_builtin_2, fold_builtin_3, fold_builtin_4):
400         New functions split out from fold_builtin_1.
401         (fold_builtin_n): New.
402         (fold_builtin_varargs): New.
403         (fold_builtin): Deleted.  Most callers changed to use fold_call_expr
404         instead.
405         (fold_call_expr): New.
406         (build_function_call_expr): Rewrite to use new helper function.
407         (fold_builtin_call_list): New.
408         (build_call_expr): New.
409         (fold_builtin_call_valist): New.
410         (rewrite_call_expr): New.
411         (validate_arg): New.
412         (validate_arglist): Change parameter to be entire CALL_EXPR instead
413         of an arglist.  Change return type to bool.  Use new CALL_EXPR
414         accessors.
415
416         (fold_builtin_strstr):  Pass call arguments individually instead
417         of as an arglist, fixing callers appropriately.  Use new CALL_EXPR
418         accessors and constructors.  Return NULL_TREE instead of 0.
419         (fold_builtin_strchr): Likewise.
420         (fold_builtin_strrchr): Likewise.
421         (fold_builtin_strpbrk): Likewise.
422         (fold_builtin_strcat): Likewise.
423         (fold_builtin_strncat): Likewise.
424         (fold_builtin_strspn): Likewise.
425         (fold_builtin_strcspn): Likewise.
426         (fold_builtin_fputs): Likewise.
427         (fold_builtin_next_arg): Likewise.
428         (fold_builtin_sprintf): Likewise.
429
430         (expand_builtin_object_size): Use new CALL_EXPR accessors.  Use
431         NULL_RTX instead of 0.
432         (expand_builtin_memory_chk): Likewise.
433         (maybe_emit_chk_warning): Likewise.
434         (maybe_emit_sprintf_chk_warning): Likewise.
435
436         (fold_builtin_object_size): Pass call arguments individually instead
437         of as an arglist, fixing callers appropriately.  Use new CALL_EXPR
438         accessors and constructors.  Return NULL_TREE instead of 0.
439         (fold_builtin_memory_chk): Likewise.
440         (fold_builtin_stxcpy_chk): Likewise.
441         (fold_builtin_strncpy_chk): Likewise.
442         (fold_builtin_strcat_chk): Likewise.
443         (fold_builtin_strcat_chk): Likewise.
444         (fold_builtin_strncat_chk): Likewise.
445         (fold_builtin_sprintf_chk): Likewise.
446         (fold_builtin_snprintf_chk): Likewise.
447         (fold_builtin_printf): Likewise.
448         (fold_builtin_vprintf): Likewise.
449
450         * fold-const.c (negate_expr_p): Use new CALL_EXPR accessors and
451         constructors.
452         (operand_equal_p): Add separate tcc_vl_exp/CALL_EXPR case.
453         (make_range): Use TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
454         (extract_muldiv_1): Add VL_EXP_CLASS_P case.
455         (fold_mathfn_compare): Use new CALL_EXPR accessors and constructors.
456         (fold_unary): Likewise.
457         (fold_binary): Likewise.
458         (fold_ternary): Remove CALL_EXPR case, since they are no longer
459         ternary expressions.
460         (fold): Add logic for tcc_vl_exp.
461         (fold_checksum_tree):  Make it know about tcc_vl_exp.  Use
462         TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
463         (fold_build3_stat): Add assertion to flag broken interface for
464         constructing CALL_EXPRs.
465         (fold_build_call_list): New.
466         (fold_build_call_list_initializer): New.
467         (tree_expr_nonnegative_p): Use new CALL_EXPR accessors and
468         constructors.
469         (fold_strip_sign_ops): Likewise.
470
471 2007-02-15  Sandra Loosemore  <sandra@codesourcery.com>
472             Brooks Moses  <brooks.moses@codesourcery.com>
473             Lee Millward  <lee.millward@codesourcery.com>
474
475         * tree-dump.c (dequeue_and_dump) <CALL_EXPR>: Use new CALL_EXPR
476         accessors and dump arguments explicitly.
477
478         * tree-pretty-print.c (do_niy): Use TREE_OPERAND_LENGTH instead of
479         TREE_CODE_LENGTH.
480         (dump_generic_node): Use new CALL_EXPR accessors and walk arguments
481         explicitly.
482         (print_call_name): Use new CALL_EXPR accessors.
483
484         * print-tree.c (print_node): Add case tcc_vl_exp.  Print
485         CALL_EXPR arguments explicitly instead of as a list.  Use
486         TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
487
488         * tree-vrp.c (stmt_interesting_for_vrp): Use new CALL_EXPR accessors.
489         (vrp_visit_stmt): Likewise.
490
491         * tree-ssa-loop-im.c (outermost_invariant_loop_expr):  Make it
492         know about tcc_vl_exp.  Use TREE_OPERAND_LENGTH instead of
493         TREE_CODE_LENGTH.
494         (force_move_till_expr): Likewise.
495
496         * targhooks.c (default_external_stack_protect_fail): Use
497         build_call_expr instead of build_function_call_expr.
498         (default_hidden_stack_protect_fail): Likewise.
499
500         * tree-complex.c (expand_complex_libcall): Use build_call_expr to
501         build the call.
502
503         * cgraphbuild.c (build_cgraph_edges): Use new CALL_EXPR accessors
504         and walk arguments explicitly.
505
506         * tree-ssa-loop-niter.c (simplify_replace_tree): Use
507         TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
508         (expand_simple_operations): Likewise.
509         (infer_loop_bounds_from_array): Use new CALL_EXPR accessors.
510
511         * gengtype.c (adjust_field_tree_exp): Use TREE_OPERAND_LENGTH instead
512         of TREE_CODE_LENGTH.
513         (walk_type): Tweak walking of arrays not to blow up on CALL_EXPRs.
514
515         * optabs.c (expand_widen_pattern-expr): Use TREE_OPERAND_LENGTH
516         instead of TREE_CODE_LENGTH.
517
518         * value_prof.c (tree_ic): Use new CALL_EXPR accessors.
519         (tree_ic_transform): Likewise.
520         (interesting_stringop_to_profile_p): Pass entire CALL_EXPR as
521         parameter instead of arglist.  Fix callers.
522         (tree_stringop_fixed_value): Use new CALL_EXPR accessors.
523         (tree_stringops_transform): Likewise.
524         (tree_indirect_call_to_profile): Likewise.
525         (tree_stringops_values_to_profile): Likewise.
526
527         * tree-tailcall.c (find_tail_calls): Use new CALL_EXPR iterator.
528         (eliminate_tail_call): Likewise.
529
530         * ipa-cp.c (ipcp_update_callgraph): Use new CALL_EXPR accessors.
531
532         * tree-scalar-evolution.c (chrec_contains_symbols_defined_in_loop):
533         Use TREE_OPERAND_LENGTH and generalize to handle any number of
534         operands.
535         (instantiate_parameters_1): Can't handle tcc_vl_exp here.
536
537         * omp-low.c (build_omp_barrier): Use build_call_expr.
538         (lower_rec_input_clauses): Likewise.
539         (lower_reduction_clauses): Likewise.
540         (expand_parallel_call): Likewise.
541         (maybe_catch_exception): Likewise.
542         (expand_omp_for_generic): Likewise.
543         (expand_omp_for_static_nochunk): Likewise.
544         (expand_omp_sections): Likewise.
545         (lower_omp_single_simple): Likewise.
546         (lower_omp_single_copy): Likewise.
547         (lower_omp_master): Likewise.
548         (lower_omp_ordered): Likewise.
549         (lower_omp_critical): Likewise.
550
551         * ipa-reference.c (check-call): Use new CALL_EXPR iterator.
552         (scan_for_static_refs): Create tcc_vl_exp case for CALL_EXPR.
553
554         * tree-gimple.c (is_gimple_call_addr): Fix doc.
555         (recalculate_side_effects): Use TREE_OPERAND_LENGTH instead of
556         TREE_CODE_LENGTH.  Add tcc_vl_exp case.
557
558         * tree-chrec.c (chrec_contains_symbols): Use TREE_OPERAND_LENGTH
559         and generalize to handle any number of operands.
560         (chrec_contains_undetermined): Likewise.
561         (tree_contains_chrecs): Likewise.
562         (evolution_function_is_invariant_rec_p): Use TREE_OPERAND_LENGTH.
563
564         * cgraphunit.c (update_call_expr): Use new CALL_EXPR accessors.
565
566         * tree-ssa-ccp.c (ccp_fold): Use new CALL_EXPR accessors.  Use
567         fold_call_expr instead of fold_builtin.
568         (ccp_fold_builtin): Likewise.  Update calls into builtins.c to
569         match declarations there.
570         (fold_stmt): Use new CALL_EXPR constructor and accessors.  Doc
571         updates.
572
573         * tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Use
574         TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
575
576         * ipa-pure-const.c (check_call): Use new CALL_EXPR accessors.
577         (scan_function): Add case tcc_vl_exp for CALL_EXPR.
578
579         * tree-stdarg.c (execute_optimize_stdarg): Use new CALL_EXPR
580         accessors.
581
582         * tree-ssa-math-opts.c (execute_cse_sincos_1): Use build_call_expr.
583         (execute_cse_sincos): Use new CALL_EXPR accessors.
584
585         * tree-ssa-alias.c (find_used_portions): Use new CALL_EXPR iterator.
586
587         * gimple-low.c (lower_function_body): Use build_call_expr.
588         (lower_builtin_setjmp): Likewise.
589
590         * expr.c (emit_block_move_via_libcall): Use build_call_expr.
591         (set_storage_via_libcall): Likewise.
592         (safe_from_p): Add tcc_vl_exp case.  Use TREE_OPERAND_LENGTH
593         instead of TREE_CODE_LENGTH.
594         (expand_expr_real_1): Use new CALL_EXPR accessors.
595
596         * tree-browser.c (store_child_info): Use TREE_OPERAND_LENGTH and
597         generalize to handle any number of operands.
598         (TB_parent_eq): Likewise.
599
600         * predict.c (expr_expected_value): Use new CALL_EXPR accessors.
601         (strip_builtin_expect): Likewise.
602
603         * function.c (gimplify_parameters): Use build_call_expr.
604
605         * tree-vectorizer.c (vect_is_simple_reduction): Use TREE_OPERAND_LENGTH
606         instead of TREE_CODE_LENGTH.
607
608         * ipa-type-escape.c (check_call): Use new CALL_EXPR iterators.
609         (scan_for_refs): Add case tcc_vl_exp for CALL_EXPR.
610
611         * tree-data-ref.c (get_references_in_stmt): Use new CALL_EXPR
612         iterators.
613
614         * gimplify.c (build_stack_save_restore): Use build_call_expr.
615         (gimplify_decl_expr): Likewise.
616         (gimplify_call_expr): Use fold_call_expr instead of fold_builtin.
617         Use new CALL_EXPR iterators.
618         (gimplify_modify_expr_to_memcpy): Use build_call_expr.
619         (gimplify_modify_expr_to_memset): Likewise.
620         (gimplify_variable_sized_compare): Likewise.
621         (gimplify_omp_atomic_fetch_op): Likewise.
622         (gimplify_omp_atomic_pipeline): Likewise.
623         (gimplify_omp_atomic_mutex): Likewise.
624         (gimplify_function_tree): Likewise.
625
626         * calls.c (alloca_call_p): Use new CALL_EXPR accessors.
627         (call_expr_flags): Likewise.
628         (expand_call): Likewise.
629
630         * except.c (expand_builtin_eh_return_data_regno): Pass entire
631         CALL_EXPR as parameter instead of arglist.  Use new CALL_EXPR 
632         accessors.
633
634         * coverage.c (create_coverage): Use build_call_expr.
635
636         * tree-ssa-pre.c (expression_node_pool, list_node_pool): Delete.
637         (temp_call_expr_obstack): New.
638         (pool_copy_list): Delete.
639         (temp_copy_call_expr): New.
640         (phi_translate): Add case tcc_vl_exp for CALL_EXPR.  Use new
641         CALL_EXPR accessors.  Get rid of special goo for copying argument
642         lists and use temp_copy_call_expr instead.
643         (valid_in_sets): Add case tcc_vl_exp for CALL_EXPR.  Use new
644         CALL_EXPR accessors.
645         (create_expression_by_pieces): Likewise.  Use build_call_array
646         to construct the result instead of fold_build3.
647         (create_value_expr_from): Add tcc_vl_exp.  Delete special goo for
648         dealing with argument lists.
649         (init_pre): Remove references to expression_node_pool and
650         list_node_pool.  Init temp_call_expr_obstack instead.
651         (fini_pre): Remove references to expression_node_pool and
652         list_node_pool.
653
654         * tree-sra.c (sra_walk_call_expr): Use new CALL_EXPR accessors
655         and walk arguments explicitly instead of as a list.
656
657         * tree-mudflap.c (mf_build_check_statement_for): Use build_call_expr.
658         (mx_register_decls): Likewise.
659         (mudflap_register_call): Likewise.
660         (mudflap_finish_file): Likewise.
661
662         * ipa-prop.c (ipa_callsite_compute_count): Use new CALL_EXPR accessors.
663         (ipa_callsite_compute_param): Likewise.
664
665         * tree-vect-patterns.c (vect_recog_pow_pattern): Use new CALL_EXPR
666         accessors and constructor.
667
668         * tree-nested.c (convert_nl_goto_reference): Use new CALL_EXPR
669         accessors and constructor.
670         (convert_tramp_reference): Likewise. 
671         (convert_call_expr): Likewise.
672         (finalize_nesting_tree_1): Likewise.
673
674         * tree-ssa.c (tree_ssa_useless_type_conversion): Use new CALL_EXPR
675         accessors.
676
677         * tree-ssa-loop-prefetch.c (issue_prefetch_ref): Use build_call_expr.
678
679         * tree-inline.c (initialize_inlined_parameters): Pass entire
680         CALL_EXPR as parameter instead of arglist.  Use new CALL_EXPR
681         accessors.
682         (estimate_num_insns_1): Use new CALL_EXPR accessors.
683         (expand_call_inline): Tidy up call to initialize_inlined_parameters.
684
685         * tree-vect-transform.c (vect_create_epilog_for_reduction):  Use
686         TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
687         (vectorizable_reduction): Likewise.
688         (vectorizable_call): Use new CALL_EXPR iterators.
689         (vectorizable_conversion): Use build_call_expr.
690         (vectorizable_operation): Use TREE_OPERAND_LENGTH.
691         (vect_gen_widened_results_half): Use build_call_expr.
692         (vect_setup_realignment): Likewise.
693         (vectorizable_live_operation): Use TREE_OPERAND_LENGTH.
694
695         * tree-object-size.c (alloc_object_size): Use new CALL_EXPR accessors.
696         (pass_through_call): Likewise.
697         (compute_object_sizes): Likewise.  Use fold_call_expr instead of
698         fold_builtin.
699
700         * tree-profile.c (tree_gen_interval_profiler): Use build_call_expr.
701         (tree_gen_pow2_profiler): Likewise.
702         (tree_gen_one_value_profiler): Likewise.
703         (tree_gen_ic_func_profiler): Likewise.
704         (tree_gen_average_profiler): Likewise.
705         (tree_gen_ior_profiler): Likewise.
706
707         * tree-ssa-structalias.c (get_constraint_for): Add case tcc_vl_exp.
708         (find_func_aliases): Use new CALL_EXPR accessors.  Add case
709         tcc_vl_exp.  Use TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
710
711         * tree-ssa-reassoc.c (get_rank): Use TREE_OPERAND_LENGTH instead
712         of TREE_CODE_LENGTH.
713
714         * stmt.c (warn_if_unused_value): Use TREE_OPERAND_LENGTH instead
715         of TREE_CODE_LENGTH.
716
717         * convert.c (convert_to_real): Use new CALL_EXPR accessors and
718         constructor.
719         (convert_to_integer): Likewise.
720
721         * tree-ssa-operands.c (get_call_expr_operands): Use new CALL_EXPR
722         accessors.
723
724 2007-02-15  Sandra Loosemore  <sandra@codesourcery.com>
725             Brooks Moses  <brooks.moses@codesourcery.com>
726             Lee Millward  <lee.millward@codesourcery.com>
727
728         * config/alpha/alpha.c (alpha_expand_builtin): Use new CALL_EXPR
729         accessors.
730         * config/frv/frv.c (frv_expand_builtin): Likewise.
731         * config/s390/s390.c (s390_expand_builtin): Likewise.
732
733         * config/sparc/sparc.c (sparc_gimplify_va_arg): Use build_call_expr.
734         (sparc_expand_builtin): Use new CALL_EXPR accessors.
735
736         * config/i386/i386.c (ix86_function_ok_for_sibcall): Likewise.
737         (ix86_expand_binop_builtin): Pass entire CALL_EXPR as parameter
738         instead of arglist.  Use new CALL_EXPR accessors on it.  Fix callers.
739         (ix86_expand_store_builtin): Likewise.
740         (ix86_expand_unop_builtin): Likewise.
741         (ix86_expand_unop1_builtin): Likewise.
742         (ix86_expand_sse_compare): Likewise.
743         (ix86_expand_sse_comi): Likewise.
744         (ix86_expand_vec_init_builtin): Likewise.
745         (ix86_expand_vec_ext_builtin): Likewise.
746         (ix86_expand_vec_set_builtin): Likewise.
747         (ix86_expand_builtin): Use new CALL_EXPR accessors.
748
749         * config/sh/sh.c (sh_expand_builtin): Use new CALL_EXPR accessors.
750         * config/c4x/c4x.c (c4x_expand_builtin): Likewise.
751
752         * config/iq2000/iq2000.c (expand_one_builtin): Pass entire CALL_EXPR
753         instead of arglist.  Use new CALL_EXPR accessors.  Fix callers.
754         (iq2000_expand_builtin): Use new CALL_EXPR accessors.
755
756         * config/rs6000/rs6000-c.c (altivec_build_resolved_builtin): Use
757         build_call_expr.
758         * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Likewise.
759         (rs6000_expand_unop_builtin): Pass entire CALL_EXPR instead of
760         arglist.  Use new CALL_EXPR accessors.  Fix callers.
761         (altivec_expand_abs_builtin): Likewise.
762         (rs6000_expand_binop_builtin): Likewise.
763         (altivec_expand_predicate_builtin): Likewise.
764         (altivec_expand_lv_builtin): Likewise.
765         (spe_expand_stv_builtin): Likewise.
766         (altivec_expand_stv_builtin): Likewise.
767         (rs6000_expand_ternop_builtin): Likewise.
768         (altivec_expand_ld_builtin): Use new CALL_EXPR accessors.
769         (altivec_expand_st_builtin): Likewise.
770         (altivec_expand_dst_builtin): Likewise.
771         (altivec_expand_vec_init_builtin): Pass entire CALL_EXPR instead of
772         arglist.  Use new CALL_EXPR accessors.  Fix callers.
773         (altivec_expand_vec_set_builtin): Likewise.
774         (altivec_expand_vec_ext_builtin): Likewise.
775         (altivec_expand_builtin): Use new CALL_EXPR accessors.
776         (spe_expand_builtin): Likewise.
777         (spe_expand_predicate_builtin): Pass entire CALL_EXPR instead of
778         arglist.  Use new CALL_EXPR accessors.  Fix callers.
779         (spe_expand_evsel_builtin): Likewise.
780         (rs6000_expand_builtin): Use new CALL_EXPR accessors.  VCFUX and
781         FCFSX cases must construct whole new CALL_EXPR, not just arglist.
782
783         * config/arm/arm.c (arm_expand_binop_builtin): Pass entire CALL_EXPR
784         instead of arglist.  Use new CALL_EXPR accessors.  Fix callers.
785         (arm_expand_unop_builtin): Likewise.
786         (arm_expand_builtin): Use new CALL_EXPR accessors.
787
788         * config/mips/mips.c (mips_expand_builtin):  Use new CALL_EXPR
789         accessors.
790
791         * config/bfin/bfin.c (bfin_expand_binop_builtin): Pass entire CALL_EXPR
792         instead of arglist.  Use new CALL_EXPR accessors.  Fix callers.
793         (bfin_expand_unop_builtin): Likewise.
794         (bfin_expand_builtin): Use new CALL_EXPR accessors.
795
796 2007-02-15  Sandra Loosemore  <sandra@codesourcery.com>
797             Brooks Moses  <brooks.moses@codesourcery.com>
798             Lee Millward  <lee.millward@codesourcery.com>
799
800         * c-semantics.c (build_stmt): Add internal diagnostic check.
801
802         * c-pretty-print.c (pp_c_postfix_expression): Use new CALL_EXPR
803         accessors.  Print arguments explicitly instead of as a list.
804
805         * c-typeck.c (build_function_call): Use new CALL_EXPR constructors.
806
807         * c-omp.c (c_finish_omp_barrier): Use build_call_expr.
808         (c_finish_omp_flish): Likewise.
809
810         * c-common.c (verify_tree): Use new CALL_EXPR accessors.  Traverse
811         arguments explicitly instead of as a list.  Use TREE_OPERAND_LENGTH
812         instead of TREE_CODE_LENGTH.
813         (check_function_arguments_recurse): Use new CALL_EXPR accessors.
814         (c_warn_unused_result): Likewise.
815
816 2007-02-15  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
817
818         PR c/26494
819         * doc/invoke.texi (Warning Options): Remove
820         -Werror-implicit-function-declaration.
821         (Wimplicit-function-declaration): Update description.
822         * opts.c (common_handle_option): Move handling of -Werror=* to...
823         (enable_warning_as_error): ...here.
824         * opts.h (enable_warning_as_error): Declare.
825         * c-decl.c (implicit_decl_warning): Unless
826         -Wno-implicit-function-declaration is given, emit a pedwarn if
827         -std=c99 or emit a warning if -Wimplicit-function-declaration.
828         * c.opt (Wimplicit-function-declaration): Replace
829         mesg_implicit_function_declaration with
830         warn_implicit_function_declaration.
831         * c-opts.c (c_common_handle_option):
832         -Werror-implicit-function-declaration is exactly equal as
833         -Werror=implicit-function-declaration.
834         (set_Wimplicit): Replace mesg_implicit_function_declaration with
835         warn_implicit_function_declaration.
836         (c_common_post_options): -Wimplict-function-declaration is enabled
837         by default by -std=c99, otherwise is disabled by default.
838         * c-objc-common.c (c_objc_common_init): Remove flawed logic.
839
840 2007-02-15  Eric Botcazou  <ebotcazou@adacore.com>
841
842         * gimplify.c (gimplify_modify_expr): During gimplification, attach a
843         DECL on the rhs to a DECL on the lhs for debug info purposes if the
844         former is ignored but not the latter.
845
846 2007-02-15  Eric Botcazou  <ebotcazou@adacore.com>
847
848         * expr.c (expand_expr_real_1) <normal_inner_ref>: If a temporary
849         is made and the reference doesn't use the alias set of its type,
850         do not create the temporary using that type.
851
852 2007-02-15  Aldy Hernandez  <aldyh@redhat.com>
853
854         * jump.c: Remove prototypes for delete_computation and
855         delete_prior_computation.
856
857 2007-02-15  Paolo Bonzini  <bonzini@gnu.org>
858
859         * jump.c (get_label_after): Delete.
860         (get_label_before, delete_computation, delete_jump,
861         delete_prior_computation, follow_jumps): Move...
862         * reorg.c (delete_computation, delete_prior_computation): ... here...
863         (get_label_before, delete_jump): ... making these static ...
864         (follow_jumps): ... and simplifying this since it only runs after
865         reload.
866         * rtl.h (get_label_after, get_label_before, delete_jump,
867         follow_jumps): Delete prototypes.
868
869 2007-02-15  Paolo Bonzini  <bonzini@gnu.org>
870
871         * caller-save.c (save_call_clobbered_regs): Do not process sibcalls.
872         
873 2007-02-15  Nick Clifton  <nickc@redhat.com>
874
875         * varasm.c (default_asm_output_anchor): Prepend * to . symbol in
876         order to prevent it from being munged by the target.
877
878 2007-02-15  Uros Bizjak  <ubizjak@gmail.com>
879
880         * config/i386/i386.md: Remove misleading comment.
881
882 2007-02-15  Alexandre Oliva  <aoliva@redhat.com>
883
884         * config/frv/frv.md (reload_incc, reload_outcc, reload_incc_uns,
885         reload_outcc_uns, reload_incc_nz, reload_outcc_nz): Remove
886         invalid patterns.
887
888 2007-02-15  Alexandre Oliva  <aoliva@redhat.com>
889
890         * tree-sra.c (instantiate_missing_elements): Canonicalize
891         bit-field types.
892         (sra_build_assignment): New.
893         (generate_copy_inout, generate_element_copy,
894         generate_element_zero, generate_one_element_init): Use it.
895
896 2007-02-15  Alexandre Oliva  <aoliva@redhat.com>
897
898         * tree-sra.c (instantiate_missing_elements): Canonicalize
899         bit-field types.
900         (sra_build_assignment): New.
901         (generate_copy_inout, generate_element_copy,
902         generate_element_zero, generate_one_element_init): Use it.
903
904 2007-02-15  Alexandre Oliva  <aoliva@redhat.com>
905
906         * dwarf2out.c (dwarf2out_finish): Accept namespaces as context of
907         limbo die nodes.
908
909 2007-02-14  Joseph Myers  <joseph@codesourcery.com>
910
911         * emit-rtl.c (set_mem_attributes_minus_bitpos): Treat complex
912         types as aggregates not scalars.
913         * function.c (assign_stack_temp_for_type): Likewise.
914
915 2007-02-14  Roger Sayle  <roger@eyesopen.com>
916             Zdenek Dvorak  <dvorakz@suse.cz>
917
918         * tree-dump.c (dump_switch_p_1): Require exact match of the option
919         name.
920
921 2007-02-14  Zdenek Dvorak  <dvorakz@suse.cz>
922
923         * passes.c (next_pass_1): Clear the next field of the copied
924         pass structure.
925
926 2007-02-14  Richard Henderson  <rth@redhat.com>
927
928         * tree-sra.c (early_sra): New.
929         (decl_can_be_decomposed_p): Deny va_list if early_sra.
930         (tree_sra_early, pass_sra_early): New.
931         * tree-pass.h (pass_sra_early): Declare.
932         * passes.c (init_optimization_passes): Use it.
933
934 2007-02-14  Richard Guenther  <rguenther@suse.de>
935
936         * flags.h (issue_strict_overflow_warning): Convert to a macro.
937
938 2007-02-14  Dorit Nuzman  <dorit@il.ibm.com>
939
940          PR tree-optimization/30771
941         * tree-vect-analyze.c (vect_determine_vectorization_factor): Traverse
942         also phi nodes.
943         (vect_analyze_operations): Induction phis can now be marked as
944         used_in_loop.
945         (vect_mark_stmts_to_be_vectorized): No special treatment for phis.
946         Update documentation accordingly.
947
948 2007-02-14  Nick Clifton  <nickc@redhat.com>
949
950         * builtin-types.def (DEF_FUNCTION_TYPE_x): Do not imply that at
951         most 3 arguments are supported.
952         (DEF_FUNCTION_TYPE_VAR_5): Fix typo in its description.
953
954 2007-02-13  Seongbae Park <seongbae.park@gmail.com>
955
956         * bitmap.c (bitmap_and, bitmap_and_compl, bitmap_xor):
957         Ensure dst->current is valid.
958
959 2007-02-13  Paul Brook  <paul@codesourcery.com>
960
961         * config.gcc: Add arm*-*-uclinux-*eabi.
962         * config/arm/uclinux-elf.h (TARGET_OS_CPP_BUILTINS): Define.
963         (SUBTARGET_EXTRA_LINK_SPEC): Define.
964         (STARTFILE_SPEC, ENDFILE_SPEC): Remove broken -shared handling.
965         (LINK_GCC_C_SEQUENCE_SPEC): Undef.
966         (LINK_SPEC): Define.
967         (LIB_SPEC): Define.
968         * config/arm/arm.c (arm_override_options): Use r9 as EABI PIC
969         register.
970         * config/arm/uclinux-eabi.h: New file.
971         * config/arm/linux-eabi.h (WCHAR_TYPE): Remove.
972         * config/arm/linux-gas.h (WCHAR_TYPE): Use unsigned long on AAPCS
973         based targets.
974
975 2007-02-13  Ian Lance Taylor  <iant@google.com>
976
977         * common.opt: Add Wstrict-overflow and Wstrict-overflow=.
978         * flags.h (warn_strict_overflow): Declare.
979         (enum warn_strict_overflow_code): Define.
980         (issue_strict_overflow_warning): New static inline function.
981         * opts.c (warn_strict_overflow): New variable.
982         (common_handle_option): Handle OPT_Wstrict_overflow and
983         OPT_Wstrict_overflow_.
984         * c-opts.c (c_common_handle_option): Set warn_strict_overflow for
985         OPT_Wall.
986         * fold-const.c: Include intl.h.
987         (fold_deferring_overflow_warnings): New static variable.
988         (fold_deferred_overflow_warning): New static variable.
989         (fold_deferred_overflow_code): New static variable.
990         (fold_defer_overflow_warnings): New function.
991         (fold_undefer_overflow_warnings): New function.
992         (fold_undefer_and_ignore_overflow_warnings): New function.
993         (fold_deferring_overflow_warnings_p): New function.
994         (fold_overflow_warning): New static function.
995         (make_range): Add strict_overflow_p parameter.  Change all
996         callers.
997         (extract_muldiv, extract_muldiv_1): Likewise.
998         (fold_unary) [ABS_EXPR]: Check ABS_EXPR before calling
999         tree_expr_nonnegative_p.
1000         (fold_negate_expr): Call fold_overflow_warning.
1001         (fold_range_test): Likewise.
1002         (fold_comparison): Likewise.
1003         (fold_binary): Likewise.  Call tree_expr_nonnegative_warnv_p
1004         instead of tree_expr_nonnegative_p.
1005         (tree_expr_nonnegative_warnv_p): Rename from
1006         tree_expr_nonnegative_p, add strict_overflow_p parameter.
1007         (tree_expr_nonnegative_p): New function.
1008         (tree_expr_nonzero_warnv_p): Rename from tree_expr_nonzero_p, add
1009         strict_overflow_p parameter.
1010         (tree_expr_nonzero_p): New function.
1011         * passes.c (verify_interpass_invariants): New static function.
1012         (execute_one_pass): Call it.
1013         * tree-ssa-loop-niter.c (expand_simple_operations): Ignore fold
1014         warnings.
1015         (number_of_iterations_exit, loop_niter_by_eval): Likewise.
1016         (estimate_numbers_of_iterations): Likewise.
1017         (scev_probably_wraps_p): Likewise.
1018         * tree-ssa-ccp.c: Include "toplev.h".
1019         (evaluate_stmt): Defer fold overflow warnings until we know we are
1020         going to optimize.
1021         (struct fold_stmt_r_data): Add stmt field.
1022         (fold_stmt_r): Defer fold overflow warnings until we know we
1023         optimized.
1024         (fold_stmt): Initialize stmt field of fold_stmt_r_data.
1025         (fold_stmt_inplace): Likewise.
1026         * tree-cfgcleanup.c: Include "toplev.h" rather than "errors.h".
1027         (cleanup_control_expr_graph): Defer fold overflow warnings until
1028         we know we are going to optimize.
1029         * tree-cfg.c (fold_cond_expr_cond): Likewise.
1030         * tree-ssa-threadedge.c (simplify_control_stmt_condition):
1031         Likewise.
1032         * tree-vrp.c (vrp_expr_computes_nonnegative): Call
1033         tree_expr_nonnegative_warnv_p instead of tree_expr_nonnegative_p.
1034         * tree-ssa-loop-manip.c (create_iv): Likewise.
1035         * c-typeck.c (build_conditional_expr): Likewise.
1036         (build_binary_op): Likewise.
1037         * tree-vrp.c (vrp_expr_computes_nonzero): Call
1038         tree_expr_nonzero_warnv_p instead of tree_expr_nonzero_p.
1039         (extract_range_from_unary_expr): Likewise.
1040         * simplify-rtx.c (simplify_const_relational_operation): Warn when
1041         assuming that signed overflow does not occur.
1042         * c-common.c (pointer_int_sum): Ignore fold overflow warnings.
1043         * tree.h (tree_expr_nonnegative_warnv_p): Declare.
1044         (fold_defer_overflow_warnings): Declare.
1045         (fold_undefer_overflow_warnings): Declare.
1046         (fold_undefer_and_ignore_overflow_warnings): Declare.
1047         (fold_deferring_overflow_warnings_p): Declare.
1048         (tree_expr_nonzero_warnv_p): Declare.
1049         * doc/invoke.texi (Option Summary): Add -Wstrict-overflow to list
1050         of warning options.
1051         (Warning Options): Document -Wstrict-overflow.
1052         * Makefile.in (tree-ssa-threadedge.o): Depend on toplev.h.
1053         (tree-ssa-ccp.o): Likewise.
1054         (tree-cfgcleanup.o): Change errors.h dependency to toplev.h.
1055         (fold-const.o): Depend on intl.h.
1056
1057 2007-02-13  Ian Lance Taylor  <iant@google.com>
1058
1059         PR middle-end/30751
1060         * lower-subreg.c (resolve_simple_move): Decompose subregs in
1061         addresses.
1062
1063 2007-02-13  Stuart Hastings  <stuart@apple.com>
1064
1065         * gcc/config/i386/i386.md (fixuns_truncdfhi2): Require SSE2.
1066
1067 2007-02-13  Richard Henderson  <rth@redhat.com>
1068
1069         * config/alpha/alpha.c (alpha_stdarg_optimize_hook): Strip
1070         handled_component_p before looking for the indirect_ref.
1071
1072 2007-02-13  Richard Henderson  <rth@redhat.com>
1073
1074         * config/i386/i386.md (bswapsi_1): Rename from bswapsi2,
1075         remove flags clobber.
1076         (bswapsi2): New expander, emit code for !TARGET_BSWAP.
1077         (bswaphi_lowpart): New.
1078         (bswapdi2): Rename from bswapdi2_rex, remove flags clobber,
1079         remove TARGET_BSWAP test.  Delete expander of the same name.
1080
1081         * optabs.c (widen_bswap, expand_doubleword_bswap): New.
1082         (expand_unop): Use them.
1083
1084 2007-02-13  Uros Bizjak  <ubizjak@gmail.com>
1085
1086         * config/i386/i386.md (cmpdi_ccno_1_rex64, *cmpsi_ccno_1,
1087         *cmphi_ccno_1, *cmpqi_ccno_1, *movsi_xor, *movstricthi_xor,
1088         *movstrictqi_xor, *movdi_xor_rex64, *ashldi3_1_rex64,
1089         *ashldi3_cmp_rex64, *ashldi3_cconly_rex64, ashlsi3, *ashlsi3_1_zext,
1090         *ashlsi3_cmp, *ashlsi3_cconly, *ashlsi3_cmp_zext, *ashlhi3_1_lea,
1091         *ashlhi3_1, *ashlhi3_cmp, *ashlhi3_cconly, *ashlqi3_1_lea,
1092         *ashlqi3_1, *ashlqi3_cmp, *ashlqi3_cconly): Remove equivalent
1093         assembler dialect choice from asm templates.
1094
1095 2007-02-12  Richard Henderson  <rth@redhat.com>
1096
1097         * config/i386/i386.md (fixuns_trunc<SSEMODEF>si_1): New insn.
1098         (fixuns_trunc<SSEMODEF>si2): Use it.
1099         * config/i386/sse.md (vec_setv4sf_0): Export.
1100         * config/i386/i386.c (ix86_build_const_vector): Export.
1101         (ix86_split_convert_uns_si_sse): Rename from
1102         ix86_expand_convert_uns_si_sse and rewrite as a splitter.
1103         * config/i386/i386-protos.h: Update.
1104
1105 2007-02-13  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
1106
1107         PR c/29521
1108         * c-typeck.c (c_finish_return): Improve warning message.
1109
1110 2007-02-12  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
1111
1112         * alias.c (find_symbolic_term): Delete unused function.
1113         
1114 2007-02-12  Uros Bizjak  <ubizjak@gmail.com>
1115
1116         * config/i386/i386.md (paritydi2, paritysi2): New expanders.
1117         (paritydi2_cmp, paritydi2_cmp): New insn and split patterns.
1118         (*parityhi2_cmp, *parityqi2_cmp): New insn patterns.
1119
1120 2007-02-12  Eric Botcazou  <ebotcazou@adacore.com>
1121
1122         * tree.h (DECL_IGNORED_P): Document further effect for FUNCTION_DECL.
1123         * cgraphunit.c (cgraph_expand_function): If DECL_IGNORED_P is set on
1124         the function, temporarily point the debug interface to the null one.
1125
1126 2007-02-12  Eric Botcazou  <ebotcazou@adacore.com>
1127
1128         * dwarf2out.c (round_up_to_align): New static function.
1129         (field_byte_offset): Use it to round the offset.
1130
1131 2007-02-12  Richard Henderson  <rth@redhat.com>
1132
1133         * config/alpha/alpha.md (bswapsi2, bswapdi2): New.
1134         (inswl_const): Export.
1135
1136 2007-02-12  Richard Henderson  <rth@redhat.com>
1137
1138         * calls.c (emit_library_call_value_1): If PROMOTE_MODE modifed the
1139         result mode of the libcall, convert back to outmode.
1140
1141 2007-02-12  Roger Sayle  <roger@eyesopen.com>
1142
1143         * config/i386/i386.md (*bswapdi2_rex): Renamed from bswapdi2.
1144         (bswapdi2): New define_expand to implement 32-bit implementation.
1145
1146 2007-02-12  Nick Clifton  <nickc@redhat.com>
1147
1148         * doc/invoke.texi (Overall Options): Document --help=.
1149         * gcc.c (target_help_flag): Rename to print_subprocess_flag.
1150         (cc1_options): Pass --help= on to cc1.
1151         (display_help): Add description of --help=.
1152         (process_command): Add code to handle --help=.  Allow translated
1153         --help and --target-help switches to be passed on to compiler
1154         sub-process.
1155         (main): Remove unused if statement.
1156         * opts.c (columns): Remove.
1157         (LEFT_COLUMN): Define.
1158         (wrap_help): Add columns argument.
1159         (print_filtered_help): Change parameters to be an include bitmask,
1160         an exclude bitmask, an any bitmask and the column width.  Move the
1161         code to display the params list here.  Add code to display the
1162         status of options rather than their descriptions if the quiet flag
1163         is not active.
1164         (print_specific_help): Change parameters to be an include bitmask,
1165         an exclude bitmask and an any bitmask.  Move code to look up the
1166         column width here.  Decide upon the title for an options listing.
1167         (common_handle_options): Add code to handle --help=.  Adapt code
1168         for --help and --target-help to use the revised form of the
1169         print_specific_help function.
1170         (print_help): Delete.
1171         (print_param_help): Delete.
1172         (print_switch): Delete.
1173         * opts.h (cl_lang_count): Add prototype.
1174         (CL_PARAMS, CL_WARNING, CL_OPTIMIZATION, CL_MIN_OPTION_CLASS,
1175         CL_MAX_OPTION_CLASS): New defines.
1176         * optc-gen.awk: Add construction of cl_lang_count.
1177         * c.opt: Add Warning attribute to warning options and Optimization
1178         attribute to optimization options.
1179         * common.opt: Likewise.
1180         Add --help=.
1181         Add -fhelp and -ftarget-help as aliases for the transformed --help
1182         and --target-help options.
1183         * opt-functions.awk: Add code to handle Warning and Optimization
1184         attributes.
1185
1186 2007-02-12  Richard Henderson  <rth@redhat.com>
1187
1188         * config/alpha/constraints.md: New file.
1189         * config/alpha/alpha.c: Include tm-constrs.h.
1190         (alpha_const_ok_for_letter_p, alpha_const_double_ok_for_letter_p,
1191         alpha_extra_constraint): Remove.
1192         (alpha_emit_conditional_branch): Use satisfies_constraint_*.
1193         * config/alpha/alpha-protos.h: Update.
1194         * config/alpha/alpha.h (REG_CLASS_FROM_LETTER): Remove.
1195         (CONST_OK_FOR_LETTER_P, CONST_DOUBLE_OK_FOR_LETTER_P): Remove.
1196         (EXTRA_CONSTRAINT): Remove.
1197         * config/alpha/alpha.md: Include constraints.md.
1198         (adddi splitter): Use satisfies_constraint_*.
1199         * config/alpha/predicates.md (add_operand): Likewise.
1200         (sext_add_operand, addition_operation): Likewise.
1201
1202 2007-02-12  Dorit Nuzman  <dorit@il.ibm.com>
1203
1204         PR tree-optimization/29145
1205         * tree-data-ref.c (base_addr_differ_p): Make us more conservative
1206         in our handling of restrict qualified pointers.
1207
1208 2007-02-12  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
1209
1210         PR middle-end/7651
1211         * doc/invoke.texi (Wunused-value): Update description.
1212         (Wextra): Delete item.
1213         * opts.c (set_Wextra): Don't use the value of Wextra to set the
1214         value of Wunused-value.
1215         * c-typeck.c (c_process_expr_stmt): Don't check extra_warnings.
1216         (c_finish_stmt_expr): Don't check extra_warnings.
1217         (emit_side_effect_warnings): The caller is responsible to check
1218         warn_unused_value.
1219         
1220 2007-02-11  Roger Sayle  <roger@eyesopen.com>
1221             Matt Thomas  <matt@3am-software.com>
1222
1223         * simplify-rtx.c (simplify_relational_operation_1): Correct typo.
1224
1225 2007-02-11  Roger Sayle  <roger@eyesopen.com>
1226
1227         * simplify-rtx.c (simplify_relational_operation_1): Optimize
1228         comparisons of POPCOUNT against zero.
1229         (simplify_const_relational_operation): Likewise.
1230
1231 2007-02-11  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
1232
1233         * doc/invoke.texi (Wextra): Delete outdated paragraph.
1234         
1235 2007-02-11  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
1236
1237         * dwarf2out.c (root_type): Delete unused function.
1238         
1239 2007-02-11  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
1240
1241         * genattrtab.c (contained_in_p): Delete unused function.
1242         (write_expr_attr_cache): Likewise.
1243
1244 2007-02-11  Jan Hubicka  <jh@suse.cz>
1245
1246         * ipa-inline.c (cgraph_edge_badness): Add "else" missing in the
1247         previous patch.
1248
1249 2007-02-11  Steven Bosscher  <steven@gcc.gnu.org>
1250
1251         * fwprop.c (try_fwprop_subst): Use set_unique_reg_note
1252         to add the REG_EQ* note.
1253         * see.c (see_merge_one_use_extension): Likewise.
1254         * local-alloc.c (update_equiv_regs): Likewise.  Also don't
1255         turn REG_EQUAL notes into REG_EQUIV notes if the target
1256         register may have more than one set.
1257         * function.c (assign_parm_setup_reg): Use set_unique_reg_note.
1258         * gcse.c (try_replace_reg): Likewise.
1259         * alias.c (init_alias_analysis): Use find_reg_equal_equiv_note.
1260         * calls.c (fixup_tail_calls): Likewise.  Abort if there is
1261         more than one REG_EQUIV note.
1262         * reload1.c (gen_reload): Use set_unique_reg_note.
1263
1264 2007-02-11  Uros Bizjak  <ubizjak@gmail.com>
1265
1266         * config/i386/i386.c (TARGET_VECTORIZE_BUILTIN_CONVERSION): Define.
1267         (ix86_builtin_conversion): New function.
1268
1269 2007-02-06  Mark Mitchell  <mark@codesourcery.com>
1270
1271         PR target/29487
1272         * tree.h (DECL_REPLACEABLE_P): New macro.
1273         * except.c (set_nothrow_function_flags): Likewise.
1274
1275 2007-02-11  Tehila Meyzels  <tehila@il.ibm.com>
1276             Ira Rosen  <irar@il.ibm.com>
1277             Dorit Nuzman  <dorit@il.ibm.com>
1278
1279         * doc/tm.texi (TARGET_VECTORIZE_BUILTIN_CONVERSION): New target hook.
1280         * targhooks.c (default_builtin_vectorized_conversion): New.
1281         * targhooks.h (default_builtin_vectorized_function): New declaration.
1282         * target.h (struct vectorize): Add builtin_conversion field.
1283         * tree-vectorizer.h (type_conversion_vec_info_type): New enum
1284         stmt_vec_info_type value.
1285         (vectorizable_conversion): New declaration.
1286         * tree-vect-analyze.c (vect_analyze_operations): Add
1287         vectorizable_conversion call.
1288         * target-def.h (TARGET_VECTORIZE_BUILTIN_CONVERSION): New.
1289         * tree-vect-transform.c (vectorizable_conversion): New function.
1290         (vect_transform_stmt): Add case for type_conversion_vec_info_type.
1291         * tree-vect-generic.c (expand_vector_operations_1): Consider correct
1292         mode.
1293         * config/rs6000/rs6000.c (rs6000_builtin_conversion): New.
1294         (TARGET_VECTORIZE_BUILTIN_CONVERSION): Defined.
1295         (rs6000_expand_builtin): Add handling a case of ALTIVEC_BUILTIN_VCFUX
1296         or ALTIVEC_BUILTIN_VCFSX.
1297
1298 2007-02-10  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1299
1300         PR target/30634
1301         * pa.md (movdf): For 64-bit target, fail if operand 1 is a non-zero
1302         CONST_DOUBLE and operand 0 is a hard register.
1303         (movdi): For 64-bit target, remove code to force CONST_DOUBLE to
1304         memory.  Fail if operand 1 is a non-zero CONST_INT and operand 0
1305         is a hard floating-point register.
1306
1307 2007-02-10  Richard Henderson  <rth@redhat.com>
1308             Jakub Jelinek  <jakub@redhat.com>
1309             Alexandre Oliva  <aoliva@redhat.com>
1310
1311         * Makefile.in (libgcc-support, libgcc.mvars): Add emutls.c.
1312         * builtin-types.def (BT_WORD): Make unsigned.
1313         (BT_FN_VOID_PTR_WORD_WORD_PTR): New.
1314         * builtins.def (BUILT_IN_EMUTLS_GET_ADDRESS): New.
1315         (BUILT_IN_EMUTLS_REGISTER_COMMON): New.
1316         * c-decl.c (grokdeclarator): Don't error if !have_tls.
1317         * c-parser.c (c_parser_omp_threadprivate): Likewise.
1318         * dwarf2out.c (loc_descriptor_from_tree_1): Don't do anything for
1319         emulated tls.
1320         * expr.c (emutls_var_address): New.
1321         (expand_expr_real_1): Expand emulated tls.
1322         (expand_expr_addr_expr_1): Likewise.
1323         * libgcc-std.ver: Add __emutls_get_address, __emutls_register_common.
1324         * output.h (emutls_finish): Declare.
1325         * toplev.c (compile_file): Call it.
1326         * tree-ssa-address.c (gen_addr_rtx): Check for const-ness of the
1327         address before wrapping in CONST.
1328         * varasm.c (emutls_htab, emutls_object_type): New.
1329         (EMUTLS_VAR_PREFIX, EMUTLS_TMPL_PREFIX): New.
1330         (get_emutls_object_name, get_emutls_object_type): New.
1331         (get_emutls_init_templ_addr, emutls_decl): New.
1332         (emutls_common_1, emutls_finish): New.
1333         (assemble_variable): When emulating tls, swap decls; generate
1334         constructor for the emutls objects.
1335         (do_assemble_alias): When emulating tls, swap decl and target name.
1336         (default_encode_section_info): Don't add SYMBOL_FLAG_TLS_SHIFT
1337         for emulated tls.
1338         * varpool.c (decide_is_variable_needed): Look at force_output.
1339         Recurse for emulated tls.
1340         (cgraph_varpool_remove_unreferenced_decls): Remove checks redundant
1341         with decide_is_variable_needed.
1342         * emutls.c: New file.
1343         * config/sparc/sol2.h (ASM_DECLARE_OBJECT_NAME): Only emit
1344         tls_object for real tls.
1345
1346 2007-02-10  Kaz Kojima  <kkojima@gcc.gnu.org>
1347
1348         PR rtl-optimization/29599
1349         * reload1.c (eliminate_regs_in_insn): Take the destination
1350         mode into account when computing the offset.
1351
1352 2007-02-09  Stuart Hastings  <stuart@apple.com>
1353             Richard Henderson  <rth@redhat.com>
1354
1355         * gcc/config/i386/i386.h (TARGET_KEEPS_VECTOR_ALIGNED_STACK): New.
1356         * gcc/config/i386/darwin.h: (TARGET_KEEPS_VECTOR_ALIGNED_STACK): New.
1357         * gcc/config/i386/i386.md (fixuns_trunc<mode>si2, fixuns_truncsfhi2,
1358         fixuns_truncdfhi2): New.
1359         (fix_truncsfdi_sse): Call ix86_expand_convert_sign_didf_sse.
1360         (floatunsdidf2): Call ix86_expand_convert_uns_didf_sse.
1361         (floatunssisf2): Add call to ix86_expand_convert_uns_sisf_sse.
1362         (floatunssidf2): Allow nonimmediate source.
1363         * gcc/config/i386/sse.md (movdi_to_sse): New.
1364         (vec_concatv2di): Drop '*'.
1365         * gcc/config/i386/i386-protos.h (ix86_expand_convert_uns_si_sse,
1366         ix86_expand_convert_uns_didf_sse, ix86_expand_convert_uns_sidf_sse,
1367         ix86_expand_convert_uns_sisf_sse, ix86_expand_convert_sign_didf_sse):
1368         New.
1369         * gcc/config/i386/i386.c (ix86_expand_convert_uns_si_sse,
1370         ix86_expand_convert_uns_didf_sse, ix86_expand_convert_uns_sidf_sse,
1371         ix86_expand_convert_uns_sisf_sse, ix86_expand_convert_sign_didf_sse,
1372         ix86_build_const_vector, ix86_expand_vector_init_one_nonzero): New.
1373         (ix86_build_signbit_mask): Fix decl of v, refactor to call
1374         ix86_build_const_vector.
1375         (x86_emit_floatuns): Rewrite.
1376
1377 2007-02-10  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
1378
1379         * genautomata.c (longest_path_length): Delete unused function.
1380         (struct state): Delete unused longest_path_length.
1381         (UNDEFINED_LONGEST_PATH_LENGTH): Delete unused macro.
1382         (get_free_state): Delete unused.
1383         
1384 2007-02-09  Jan Hubicka  <jh@suse.cz>
1385
1386         * params.def (PARAM_INLINE_UNIT_GROWTH): Set to 30.
1387         * doc/invoke.texi (inline-unit-growth): Update default value.
1388
1389         * Makefile.in (passes.o, ipa-inline.o): Add dependencies.
1390         * cgraphbuild.c (build_cgraph_edges): Compute frequencies.
1391         (rebuild_cgraph_edges): Likewise.
1392         * cgraph.c (cgraph_set_call_stmt): Add new argument frequency.
1393         (dump_cgraph_node): Dump frequencies.
1394         (cgraph_clone_edge): Add frequency scales.
1395         (cgraph_clone_node): Add freuqnecy.
1396         * cgraph.h (cgraph_edge): Add freuqnecy argument.
1397         (CGRAPH_FREQ_BASE, CGRAPH_FREQ_MAX): New constants.
1398         (cgraph_create_edge, cgraph_clone_edge, cgraph_clone_node): Update.
1399         * tree-pass.h (TODO_rebuild_frequencies): New constant.
1400         * cgraphunit.c (verify_cgraph_node): Verify frequencies.
1401         (cgraph_copy_node_for_versioning): Update call of cgraph_clone_edge.
1402         (save_inline_function_body): Likewise.
1403         * ipa-inline.c: inluce rtl.h
1404         (cgraph_clone_inlined_nods): Update call of cgraph_clone_node.
1405         (cgraph_edge_badness): Use frequencies.
1406         (cgraph_decide_recursive_inlining): Update clonning.
1407         (cgraph_decide_inlining_of_small_function): Dump frequency.
1408         * predict.c (estimate_bb_frequencies): Export.
1409         * predict.h (estimate_bb_frequencies): Declare.
1410         * tree-inline.c (copy_bb): Watch overflows.
1411         (expand_call_inline): Update call of cgraph_create_edge.
1412         (optimize_inline_calls): Use TODO flags to update frequnecies.
1413         * passes.h: Include predict.h
1414         (init_optimization_passes): Move profile ahead.
1415         (execute_function_todo): Handle TODO_rebuild_frequencies.
1416
1417 2007-02-09  Roger Sayle  <roger@eyesopen.com>
1418
1419         * config/alpha/alpha.c (emit_insxl): Force the first operand of
1420         the insbl or inswl pattern into a register.
1421
1422 2007-02-09  Roger Sayle  <roger@eyesopen.com>
1423
1424         * config/ia64/ia64.md (bswapdi2): New define_insn.
1425
1426 2007-02-09  Richard Henderson  <rth@redhat.com>
1427
1428         * config/i386/constraints.md (Ym): New constraint.
1429         * config/i386/i386.md (movsi_1): Change Y2 to Yi constraints.
1430         (movdi_1_rex64): Split sse and xmm general register moves from
1431         memory move alternatives.  Use conditional register constraints.
1432         (movsf_1, movdf_integer): Likewise.
1433         (zero_extendsidi2_32, zero_extendsidi2_rex64): Likewise.
1434         (movdf_integer_rex64): New.
1435         (pushsf_rex64): Fix output constraints.
1436         * config/i386/sse.md (sse2_loadld): Split rm alternative, use Yi.
1437         (sse2_stored): Likewise.
1438         (sse2_storeq_rex64): New.
1439         * config/i386/i386.c (x86_inter_unit_moves): Enable for not
1440         amd and not generic.
1441         (ix86_secondary_memory_needed): Don't bypass TARGET_INTER_UNIT_MOVES
1442         for optimize_size.  Remove SF/DFmode hack.
1443
1444 2007-02-09  Dwarakanath Rajagopal  <dwarak.rajagopal@amd.com>
1445
1446         * config/i386/driver-i386.c: Turn on -mtune=native for AMDFAM10.
1447         (bit_SSE4a): New.
1448
1449 2007-02-09  Nathan Sidwell  <nathan@codesourcery.com>
1450             Richard Sandiford  <richard@codesourcery.com>
1451
1452         * config.gcc (m68010-*-netbsdelf*, m68k*-*-netbsdelf*)
1453         (m68k*-*-openbsd*, m68k-*-linux*): Set default_cf_cpu.
1454         (m68k-*-aout*, m68k-*-coff*, m68k-*-uclinux*, m68k-*-rtems*): Add
1455         m68k/t-mlib to tmake_file.
1456         (m68020-*-elf*, m68k-*-elf*): Likewise.  Add t-m68kbare as well.
1457         (m68k*-*-*): Use --with-arch to pick a default for --with-cpu.
1458         (m680[012]0-*-*, m68k*-*-*): Add support for --with-arch.
1459         Allow it to be cf or m68k.  Set m68k_arch_family.  If that
1460         variable is not empty, add t-$m68k_arch_family to tmake_file.
1461         Add t-mlibs to tmake_file.
1462         * doc/install.texi: Document --with-arch=m68k and --with-arch=cf.
1463         * config/m68k/t-cf: New file.
1464         * config/m68k/t-m68k: Likewise.
1465         * config/m68k/t-mlibs: Likewise.
1466         * config/m68k/t-m68kbare (MULTILIB_OPTIONS, MULTILIB_DIRNAMES)
1467         (MULTILIB_MATCHES, MULTILIB_EXCEPTIONS): Delete.
1468         (M68K_MLIB_DIRNAMES, M68K_MLIB_OPTIONS): Define.
1469         * config/m68k/t-m68kelf (MULTILIB_OPTIONS, MULTILIB_DIRNAMES)
1470         (MULTILIB_MATCHES, MULTILIB_EXCEPTIONS, LIBGCC, INSTALL_LIBGCC):
1471         Delete.
1472         * config/m68k/t-openbsd (MULTILIB_OPTIONS, LIBGCC): Delete.
1473         (INSTALL_LIBGCC): Delete.
1474         (M68K_MLIB_DIRNAMES, M68K_MLIB_OPTIONS): Define.
1475         * config/m68k/t-rtems (MULTILIB_OPTIONS, MULTILIB_DIRNAMES)
1476         (MULTILIB_MATCHES, MULTILIB_EXCEPTIONS): Delete.
1477         (M68K_MLIB_CPU): Define.
1478         * config/m68k/t-uclinux (MULTILIB_OPTIONS, MULTILIB_DIRNAMES)
1479         (MULTILIB_MATCHES, MULTILIB_EXCEPTIONS): Delete.
1480         (M68K_MLIB_CPU, M68K_MLIB_OPTIONS, M68K_MLIB_DIRNAMES): Define.
1481
1482 2007-02-09  Zdenek Dvorak  <dvorakz@suse.cz>
1483             Richard Guenther  <rguenther@suse.de>
1484
1485         PR middle-end/23361
1486         * fold-const.c (fold_comparison): Handle obfuscated comparisons
1487         against INT_MIN/INT_MAX.
1488         * tree-ssa-loop-ivcanon.c (remove_empty_loop): Print to dump
1489         file if a loop is removed.
1490
1491 2007-02-09  Joseph Myers  <joseph@codesourcery.com>
1492
1493         * calls.c (store_one_arg): Pass correct alignment to
1494         emit_push_insn for non-BLKmode values.
1495         * expr.c (emit_push_insn): If STRICT_ALIGNMENT, copy to an
1496         unaligned stack slot via a suitably aligned slot.
1497
1498 2007-02-08  DJ Delorie  <dj@redhat.com>
1499
1500         * config/m32c/m32c.c (m32c_unpend_compare): Add default to silence
1501         warnings.
1502         (legal_subregs): Use unsigned char, make const.
1503         (m32c_illegal_subreg_p): Use ARRAY_SIZE.  Delete unused variables.
1504
1505 2007-02-08  Paul Brook  <paul@codesourcery.com>
1506
1507         * config/arm/lib1funcs.asm (RETLDM): Pop directly into PC when no
1508         special interworking needed.
1509
1510 2007-02-08  Harsha Jagasia  <harsha.jagasia@amd.com>
1511
1512         * config/i386/xmmintrin.h: Make inclusion of emmintrin.h
1513         conditional to __SSE2__.
1514         (Entries below should have been added to first ChangeLog
1515         entry for amdfam10 dated 2007-02-05)
1516         * config/i386/emmintrin.h: Generate #error if __SSE2__ is not
1517         defined.
1518         * config/i386/pmmintrin.h: Generate #error if __SSE3__ is not
1519         defined.
1520         * config/i386/tmmintrin.h: Generate #error if __SSSE3__ is not
1521         defined.
1522
1523 2007-02-08  DJ Delorie  <dj@redhat.com>
1524
1525         * config/m32c/m32c-protos.h (m32c_illegal_subreg_p): New.
1526         * config/m32c/m32c.c (legal_subregs): New.
1527         (m32c_illegal_subreg_p): New.
1528         * config/m32c/predicates.md (m32c_any_operand): Use it to reject
1529         unsupported subregs of hard regs.
1530
1531 2007-02-08  Jan Hubicka  <jh@suse.cz>
1532
1533         * tree-cfg.c (bsi_replace): Shortcut when replacing the statement with
1534         the same one; always update histograms.
1535
1536 2007-02-08  Diego Novillo  <dnovillo@redhat.com>
1537
1538         * passes.c (init_optimization_passes): Tidy comment.
1539
1540 2007-02-08  Roger Sayle  <roger@eyesopen.com>
1541
1542         * simplify-rtx.c (simplify_unary_operation_1) <POPCOUNT>: We can
1543         strip zero_extend, bswap and rotates from POCOUNT's argument.
1544         <PARITY>: Likewise, we can strip not, bswap, sign_extend,
1545         zero_extend and rotates from PARITY's argument.
1546         <BSWAP>: A byte-swap followed by a byte-swap is an identity.
1547         (simplify_const_unary_operation) <BSWAP>: Evaluate the byte-swap
1548         of an integer constant at compile-time.
1549
1550 2007-02-08  Diego Novillo  <dnovillo@redhat.com>
1551
1552         PR 30562
1553         * tree-flow.h (struct var_ann_d): Remove field 'is_used'.
1554         Update all users.
1555         * tree-ssa-alias.c (compute_is_aliased): Remove.  Update all
1556         users.
1557         (init_alias_info):
1558         * tree-ssa-live.c (remove_unused_locals): Do not remove
1559         TREE_ADDRESSABLE variables.
1560         * tree-ssa-structalias.c (compute_points_to_sets): Tidy.
1561         * tree-ssa-operands.c (add_virtual_operand): Remove argument
1562         FOR_CLOBBER.  Update all users.
1563         If VAR has an associated alias set, add a virtual operand for
1564         it if no alias is found to conflict with the memory reference.
1565
1566 2007-02-07  Jan Hubicka  <jh@suse.cz>
1567             Robert Kidd <rkidd@crhc.uiuc.edu>
1568
1569         * value-prof.c (visit_hist, free_hist): Return 1 instead of 0.
1570
1571 2007-02-07  Ian Lance Taylor  <iant@google.com>
1572
1573         * lower-subreg.c (simple_move): Reject PARTIAL_INT modes.
1574
1575 2007-02-07  Roger Sayle  <roger@eyesopen.com>
1576
1577         * config/rs6000/rs6000.md (ctz<mode>2, ffs<mode>2, popcount<mode>2,
1578         parity<mode>2, smulsi3_highpart, abstf2_internal, allocate_stack,
1579         tablejumpdi, movsi_to_cr_one): Remove constraints from
1580         define_expand's match_operands.
1581
1582 2007-02-07  Roger Sayle  <roger@eyesopen.com>
1583
1584         * global.c (compute_regsets): Move declatation of "i" inside of
1585         #ifdef ELIMINABLE_REGS to avoid unused variable bootstrap failure.
1586
1587 2007-02-07  Jakub Jelinek  <jakub@redhat.com>
1588
1589         PR c++/30703
1590         * gimplify.c (gimplify_scan_omp_clauses): Remove special casing
1591         of INDIRECT_REF <RESULT_DECL>.
1592
1593         * config/i386/i386.c (override_options): Set PTA_SSSE3 for core2.
1594
1595 2007-02-06  J"orn Rennecke  <joern.rennecke@arc.com>
1596             Kaz Kojima  <kkojima@gcc.gnu.org>
1597
1598         PR target/29746
1599         * config/sh/sh.c (expand_cbranchdi4): Use scratch register
1600         properly.
1601         (sh_initialize_trampoline): Add parentheses to avoid a warning.
1602
1603 2007-02-06  Zdenek Dvorak <dvorakz@suse.cz>
1604
1605         * doc/loop.texi: Document possibility not to perform disambiguation
1606         of loops with multiple latches.
1607         * cfgloopmanip.c (alp_enum_p): Removed.
1608         (add_loop): Handle subloops.  Use get_loop_body_with_size.
1609         (create_preheader): Do not allow ENTRY_BLOCK_PTR to be preheader.
1610         * cfghooks.c (redirect_edge_and_branch_force): Set dominator for
1611         the new forwarder block.
1612         (make_forwarder_block): Only call new_bb_cbk if it is not NULL.
1613         Handle the case latch is NULL.
1614         * tree-ssa-dom.c (tree_ssa_dominator_optimize): Avoid cfg modifications
1615         when marking loop exits.
1616         * ifcvt.c (if_convert): Ditto.  Mark loop exits even if cfg cannot
1617         be modified.
1618         * loop-init.c (loop_optimizer_init): Do not modify cfg.  Call
1619         disambiguate_loops_with_multiple_latches.
1620         * tree-cfgcleanup.c (cleanup_tree_cfg_loop): Calculate dominators
1621         before fix_loop_structure.
1622         * cfgloop.c: Include pointer-set.h and output.h.
1623         (canonicalize_loop_headers, HEADER_BLOCK, LATCH_EDGE,
1624         update_latch_info, mfb_keep_just, mfb_keep_nonlatch): Removed.
1625         (get_loop_latch_edges, find_subloop_latch_edge_by_profile,
1626         find_subloop_latch_edge_by_ivs, find_subloop_latch_edge,
1627         mfb_redirect_edges_in_set, form_subloop, merge_latch_edges,
1628         disambiguate_multiple_latches, get_loop_body_with_size,
1629         disambiguate_loops_with_multiple_latches): New functions.
1630         (flow_loop_dump): Dump multiple latch edges.
1631         (flow_loop_nodes_find): Handle loops with multiple latches.
1632         (flow_loops_find): Ditto. Do not call canonicalize_loop_headers.
1633         (glb_enum_p): Modified.
1634         (get_loop_body): Use get_loop_body_with_size.
1635         * cfgloop.h (LOOPS_HAVE_RECORDED_EXITS): New flag.
1636         (AVOID_CFG_MODIFICATIONS): New constant.
1637         (disambiguate_loops_with_multiple_latches, add_loop,
1638         get_loop_body_with_size): Declare.
1639         * Makefile.in (cfgloop.o): Add pointer-set.h and output.h.
1640
1641 2007-02-06  Seongbae Park <seongbae.park@gmail.com>
1642
1643         PR inline-asm/28686
1644         * global.c (compute_regsets): New function.
1645         (global_alloc): Refactored ELIMINABLE_REGSET
1646         and NO_GLOBAL_ALLOC_REGS computation out.
1647         (rest_of_handle_global_alloc): Call compute_regsets()
1648         for non-optimizing case.
1649
1650 2007-02-06  Richard Henderson  <rth@redhat.com>
1651
1652         * config/i386/constraints.md (Y2): Rename from Y.
1653         (Yi): New constraint.
1654         * config/i386/i386.md (movsi_1, movdi_2, pushdf_nointeger,
1655         pushdf_integer, movdf_nointeger, movdf_integer, zero_extendsidi2_32,
1656         zero_extendsidi2_rex64, truncxfdf2_mixed): Change Y constraints to Y2.
1657         (extendsfdf2_mixed, extendsfdf2_sse, truncdfsf_fast_mixed,
1658         truncdfsf_fast_sse, truncdfsf_mixed, fix_truncdfdi_sse,
1659         fix_truncdfsi_sse, floatsidf2_mixed, floatsidf2_sse,
1660         floatdidf2_mixed, floatdidf2_sse, absnegdf2_mixed, 
1661         absnegdf2_sse, sse_setccdf, fop_df_comm_mixed, fop_df_comm_sse,
1662         fop_df_1_mixed, fop_df_1_sse): Change Y constraints to x.
1663         * config/i386/mmx.md (mov<MMXMODEI>_internal_rex64,
1664         mov<MMXMODEI>_internal, movv2sf_internal_rex64, movv2sf_internal,
1665         vec_extractv2si_1): Change Y constraints to Y2.
1666         * config/i386/sse.md (vec_setv4sf_0, vec_concatv2df, vec_dupv4si,
1667         vec_dupv2di, sse2_concatv2si, vec_concatv4si_1, vec_concatv2di):
1668         Change Y constraints to Y2.
1669         (sse2_loadld): Change Y constraints to x.
1670
1671 2007-02-06  Roger Sayle  <roger@eyesopen.com>
1672
1673         * config/rs6000/rs6000.md (popcount<mode>2): Rewrite.
1674         (parity<mode>2): New define_expand using rs6000_emit_parity.
1675         * config/rs6000/rs6000.c (rs6000_emit_popcount,
1676         rs6000_emit_parity): New functions.
1677         * config/rs6000/rs6000-protos.h (rs6000_emit_popcount,
1678         rs6000_emit_parity): Prototype here.
1679
1680 2007-02-06  Ian Lance Taylor  <iant@google.com>
1681
1682         * lower-subreg.c (simple_move_operand): Reject CONST.
1683         (resolve_clobber): Call validate_change rather than directly
1684         assigning to XEXP (pat, 0).
1685
1686 2006-02-06  Paolo Bonzini  <bonzini@gnu.org>
1687
1688         * Makefile.in (tree-ssa-loop-ivopts.o): Add pointer-set.h dependency.
1689         (tree-ssa-reassoc.o): Add pointer-set.h dependency.
1690         (tree-cfg.o): Remove hashtab.h dependency.
1691
1692         * tree-ssa-loop-ivopts.c: Include pointer-set.h.
1693         (struct ivopts_data): Change niters to pointer_map_t.
1694         (struct nfe_cache_elt, nfe_hash, nfe_eq): Delete.
1695         (niter_for_exit): Create pointer_map on demand.  Change for
1696         pointer_map API.
1697         (tree_ssa_iv_optimize_init): Initialize data->niters to NULL.
1698         (free_loop_data): Destroy data->niters if created and reset field.
1699         (tree_ssa_iv_optimize_finalize): Don't delete data->niters here.
1700         (tree_ssa_iv_optimize_loop): Check for presence of stale data.
1701
1702         * tree-ssa-reassoc.c: Include pointer-set.h.
1703         (bb_rank): Change to long *.
1704         (operand_rank): Change to pointer_map_t.
1705         (find_operand_rank): Return long, -1 if not found.  Declare as inline.
1706         (insert_operand_rank): Accept long.
1707         (operand_entry_hash, operand_entry_eq): Remove.
1708         (get_rank): Return long.  Adjust for changes above.
1709         (init_reassoc): Change rank type to long.  Adjust creation of bb_rank
1710         and operand_rank.
1711         (fini_reassoc): Delete operand_rank with pointer_map_destroy.
1712
1713         * tree-ssa-structalias.c (vi_for_tree): Change to pointer_map.
1714         (struct tree_vi, tree_vi_t, tree_vi_hash, tree_vi_eq): Delete.
1715         (insert_vi_for_tree): Rewrite for pointer_map API.  Assert argument
1716         is not NULL.
1717         (lookup_vi_for_tree): Rewrite for pointer_map API.  Return varinfo_t
1718         directly since it cannot be NULL.
1719         (get_vi_for_tree): Rewrite for pointer_map API.
1720         (find_what_p_points_to): Adjust for change to lookup_vi_for_tree.
1721         (init_alias_vars): Create vi_for_tree as pointer_map.
1722         (delete_points_to_sets): Delete vi_for_tree using pointer_map_destroy.
1723
1724         * tree-cfg.c: Don't include hashtab.h.
1725         (edge_to_cases): Declare as pointer_map.
1726         (struct edge_to_cases_elt, edge_to_cases_hash, edge_to_cases_eq):
1727         Delete.
1728         (edge_to_cases_cleanup): Rewrite as pointer_map_traverse callback.
1729         (start_recording_case_labels): Create edge_to_cases as pointer_map.
1730         (end_recoding_case_labels): Cleanup edge_to_cases manually before
1731         destroying it.
1732         (record_switch_edge): Delete.
1733         (get_cases_for_edge): Adjust for pointer_map API, inline
1734         record_switch_edge (rewritten for new API), remove goto.
1735
1736 2006-02-06  Paolo Bonzini  <bonzini@gnu.org>
1737
1738         * Makefile.in (tree-nested.o): Add pointer-set.h dependency.
1739         * tree-nested.c: Include pointer-set.h.
1740         (var_map_elt, var_map_eq, var_map_hash): Delete.
1741         (struct nesting_info): Remove GTY marker.  Change the two htab_t's
1742         to pointer_map_t's.
1743         (nesting_info_bitmap_obstack): New.
1744         (lookup_field_for_decl): Adjust for pointer_map API.
1745         (lookup_tramp_for_decl): Adjust for pointer_map API.
1746         (get_nonlocal_debug_decl): Adjust for pointer_map API.
1747         (get_local_debug_decl): Adjust for pointer_map API.
1748         (convert_nl_goto_reference): Adjust for pointer_map API.
1749         (convert_nl_goto_receiver): Adjust for pointer_map API.
1750         (create_nesting_tree): Create outside GGC space.  Create bitmap on
1751         the new obstack.  Create field_map and var_map as pointer_maps.
1752         (free_nesting_tree): Adjust for changes to create_nesting_tree.
1753         (root): Delete. 
1754         (lower_nested_functions): Move root here, no need to NULL it.
1755         Initialize and release the obstack.
1756
1757 2007-02-06  Paolo Bonzini  <bonzini@gnu.org>
1758
1759         * tree.c (tree_int_map_hash, tree_int_map_eq, tree_int_map_marked_p):
1760         Remove prototypes and make them non-static.
1761         (struct tree_int_map): Remove.
1762         * tree.h (struct tree_int_map): Move here, turning TO into an
1763         unsigned int.
1764         (tree_int_map_hash, tree_int_map_eq, tree_int_map_marked_p): Declare.
1765
1766         * tree.h (TREE_COMPLEXITY): Remove.
1767         (struct tree_exp): Remove complexity field.
1768         * tree.c (build1_stat): Don't set it.
1769
1770 2007-02-06  Dorit Nuzman  <dorit@il.ibm.com>
1771             Victor Kaplansky  <victork@il.ibm.com>
1772
1773         * tree-vectorizer.c (vect_is_simple_use): Support induction.
1774         (vect_is_simple_reduction): Support reduction with induction as
1775         one of the operands.
1776         (vect_is_simple_iv_evolution): Fix formatting.
1777         * tree-vect-analyze.c (vect_mark_stmts_to_be_vectorized): Fix 
1778         formatting.  Don't mark induction phis for vectorization.
1779         (vect_analyze_scalar_cycles): Analyze all inductions, then reductions.
1780         * tree-vect-transform.c (get_initial_def_for_induction): New function.
1781         (vect_get_vec_def_for_operand): Support induction.
1782         (vect_get_vec_def_for_stmt_copy): Fix formatting and add check for
1783         induction case.
1784         (vectorizable_reduction): Support reduction with induction as one of 
1785         the operands. 
1786         (vectorizable_type_demotion): Use def-type of stmt argument rather
1787         than dummy def-type.
1788
1789         * tree-ssa-loop.c (gate_scev_const_prop): Return the value of
1790         flag_tree_scev_cprop.
1791         * common.opt (tree-scev-cprop): New flag.
1792
1793         * tree-vect-transform.c (vect_create_destination_var): Use 'kind' in
1794         call to vect_get_new_vect_var.
1795
1796 2007-02-06  Ira Rosen  <irar@il.ibm.com>
1797
1798         * tree-vect-patterns.c (vect_recog_widen_mult_pattern): Check that 
1799         vectype is not NULL.
1800         (vect_pattern_recog_1): Likewise.
1801
1802 2007-02-05  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
1803
1804         * fold-const.c (negate_expr_p): Handle CONJ_EXPR.
1805         (fold_negate_expr): Likewise.
1806
1807 2007-02-05  Alexandre Oliva  <aoliva@redhat.com>
1808
1809         PR debug/30189
1810         * dwarf2out.c (modified_type_die): Follow DECL_ORIGINAL_TYPE
1811         even if cv-qualification is the same.
1812
1813 2007-02-05  Geoffrey Keating  <geoffk@apple.com>
1814
1815         * config/rs6000/darwin-tramp.asm (__trampoline_setup): Call
1816         __enable_execute_stack on completion.
1817
1818 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1819
1820         * config/i386/athlon.md (athlon_fldxf_k8, athlon_fld_k8,
1821         athlon_fstxf_k8, athlon_fst_k8, athlon_fist, athlon_fmov,
1822         athlon_fadd_load, athlon_fadd_load_k8, athlon_fadd, athlon_fmul,
1823         athlon_fmul_load, athlon_fmul_load_k8, athlon_fsgn,
1824         athlon_fdiv_load, athlon_fdiv_load_k8, athlon_fdiv_k8,
1825         athlon_fpspc_load, athlon_fpspc, athlon_fcmov_load,
1826         athlon_fcmov_load_k8, athlon_fcmov_k8, athlon_fcomi_load_k8,
1827         athlon_fcomi, athlon_fcom_load_k8, athlon_fcom): Added amdfam10.
1828
1829 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1830
1831         * config/i386/i386.md (x86_sahf_1, cmpfp_i_mixed, cmpfp_i_sse,
1832         cmpfp_i_i387, cmpfp_iu_mixed, cmpfp_iu_sse, cmpfp_iu_387,
1833         swapsi, swaphi_1, swapqi_1, swapdi_rex64, fix_truncsfdi_sse,
1834         fix_truncdfdi_sse, fix_truncsfsi_sse, fix_truncdfsi_sse,
1835         x86_fldcw_1, floatsisf2_mixed, floatsisf2_sse, floatdisf2_mixed,
1836         floatdisf2_sse, floatsidf2_mixed, floatsidf2_sse,
1837         floatdidf2_mixed, floatdidf2_sse, muldi3_1_rex64, mulsi3_1,
1838         mulsi3_1_zext, mulhi3_1, mulqi3_1, umulqihi3_1, mulqihi3_insn,
1839         umulditi3_insn, umulsidi3_insn, mulditi3_insn, mulsidi3_insn,
1840         umuldi3_highpart_rex64, umulsi3_highpart_insn,
1841         umulsi3_highpart_zext, smuldi3_highpart_rex64,
1842         smulsi3_highpart_insn, smulsi3_highpart_zext, x86_64_shld,
1843         x86_shld_1, x86_64_shrd, sqrtsf2_mixed, sqrtsf2_sse,
1844         sqrtsf2_i387, sqrtdf2_mixed, sqrtdf2_sse, sqrtdf2_i387,
1845         sqrtextendsfdf2_i387, sqrtxf2, sqrtextendsfxf2_i387,
1846         sqrtextenddfxf2_i387): Added amdfam10_decode.
1847         
1848         * config/i386/athlon.md (athlon_idirect_amdfam10,
1849         athlon_ivector_amdfam10, athlon_idirect_load_amdfam10,
1850         athlon_ivector_load_amdfam10, athlon_idirect_both_amdfam10,
1851         athlon_ivector_both_amdfam10, athlon_idirect_store_amdfam10,
1852         athlon_ivector_store_amdfam10): New define_insn_reservation.
1853         (athlon_idirect_loadmov, athlon_idirect_movstore): Added
1854         amdfam10.
1855
1856 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1857
1858         * config/i386/athlon.md (athlon_call_amdfam10,
1859         athlon_pop_amdfam10, athlon_lea_amdfam10): New
1860         define_insn_reservation.
1861         (athlon_branch, athlon_push, athlon_leave_k8, athlon_imul_k8,
1862         athlon_imul_k8_DI, athlon_imul_mem_k8, athlon_imul_mem_k8_DI,
1863         athlon_idiv, athlon_idiv_mem, athlon_str): Added amdfam10.
1864
1865 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1866
1867         * config/i386/athlon.md (athlon_sseld_amdfam10,
1868         athlon_mmxld_amdfam10, athlon_ssest_amdfam10,
1869         athlon_mmxssest_short_amdfam10): New define_insn_reservation.
1870
1871 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1872
1873         * config/i386/athlon.md (athlon_sseins_amdfam10): New
1874         define_insn_reservation.
1875         * config/i386/i386.md (sseins): Added sseins to define_attr type
1876         and define_attr unit.
1877         * config/i386/sse.md: Set type attribute to sseins for insertq
1878         and insertqi.
1879
1880 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1881
1882         * config/i386/athlon.md (sselog_load_amdfam10, sselog_amdfam10,
1883         ssecmpvector_load_amdfam10, ssecmpvector_amdfam10,
1884         ssecomi_load_amdfam10, ssecomi_amdfam10,
1885         sseaddvector_load_amdfam10, sseaddvector_amdfam10): New
1886         define_insn_reservation.
1887         (ssecmp_load_k8, ssecmp, sseadd_load_k8, seadd): Added amdfam10.
1888
1889 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1890
1891         * config/i386/athlon.md (cvtss2sd_load_amdfam10,
1892         cvtss2sd_amdfam10, cvtps2pd_load_amdfam10, cvtps2pd_amdfam10,
1893         cvtsi2sd_load_amdfam10, cvtsi2ss_load_amdfam10,
1894         cvtsi2sd_amdfam10, cvtsi2ss_amdfam10, cvtsd2ss_load_amdfam10,
1895         cvtsd2ss_amdfam10, cvtpd2ps_load_amdfam10, cvtpd2ps_amdfam10,
1896         cvtsX2si_load_amdfam10, cvtsX2si_amdfam10): New 
1897         define_insn_reservation.
1898
1899         * config/i386/sse.md (cvtsi2ss, cvtsi2ssq, cvtss2si,
1900         cvtss2siq, cvttss2si, cvttss2siq, cvtsi2sd, cvtsi2sdq,
1901         cvtsd2si, cvtsd2siq, cvttsd2si, cvttsd2siq,
1902         cvtpd2dq, cvttpd2dq, cvtsd2ss, cvtss2sd,
1903         cvtpd2ps, cvtps2pd): Added amdfam10_decode attribute.
1904
1905 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1906
1907         * config/i386/athlon.md (athlon_ssedivvector_amdfam10,
1908         athlon_ssedivvector_load_amdfam10, athlon_ssemulvector_amdfam10,
1909         athlon_ssemulvector_load_amdfam10): New define_insn_reservation.
1910         (athlon_ssediv, athlon_ssediv_load_k8, athlon_ssemul,
1911         athlon_ssemul_load_k8): Added amdfam10.
1912
1913 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1914
1915         * config/i386/i386.h (TARGET_SSE_UNALIGNED_MOVE_OPTIMAL): New macro.
1916         (x86_sse_unaligned_move_optimal): New variable.
1917         
1918         * config/i386/i386.c (x86_sse_unaligned_move_optimal): Enable for  
1919         m_AMDFAM10.
1920         (ix86_expand_vector_move_misalign): Add code to generate movupd/movups
1921         for unaligned vector SSE double/single precision loads for AMDFAM10.
1922
1923 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1924
1925         * config/i386/i386.h (TARGET_AMDFAM10): New macro.
1926         (TARGET_CPU_CPP_BUILTINS): Add code for amdfam10.
1927         Define TARGET_CPU_DEFAULT_amdfam10.
1928         (TARGET_CPU_DEFAULT_NAMES): Add amdfam10.
1929         (processor_type): Add PROCESSOR_AMDFAM10.       
1930         
1931         * config/i386/i386.md: Add amdfam10 as a new cpu attribute to match
1932         processor_type in config/i386/i386.h.
1933         Enable imul peepholes for TARGET_AMDFAM10.
1934         
1935         * config.gcc: Add support for --with-cpu option for amdfam10.
1936         
1937         * config/i386/i386.c (amdfam10_cost): New variable.
1938         (m_AMDFAM10): New macro.
1939         (m_ATHLON_K8_AMDFAM10): New macro.
1940         (x86_use_leave, x86_push_memory, x86_movx, x86_unroll_strlen,
1941         x86_cmove, x86_3dnow_a, x86_deep_branch, x86_use_simode_fiop,
1942         x86_promote_QImode, x86_integer_DFmode_moves,
1943         x86_partial_reg_dependency, x86_memory_mismatch_stall, 
1944         x86_accumulate_outgoing_args, x86_arch_always_fancy_math_387,
1945         x86_sse_partial_reg_dependency, x86_sse_typeless_stores,
1946         x86_use_ffreep, x86_use_incdec, x86_four_jump_limit,
1947         x86_schedule, x86_use_bt, x86_cmpxchg16b, x86_pad_returns):
1948         Enable/disable for amdfam10.
1949         (override_options): Add amdfam10_cost to processor_target_table.
1950         Set up PROCESSOR_AMDFAM10 for amdfam10 entry in 
1951         processor_alias_table.
1952         (ix86_issue_rate): Add PROCESSOR_AMDFAM10.
1953         (ix86_adjust_cost): Add code for amdfam10.
1954
1955 2007-02-05  Harsha Jagasia  <harsha.jagasia@amd.com>
1956         
1957         * config/i386/i386.opt: Add new Advanced Bit Manipulation (-mabm)
1958         instruction set feature flag. Add new (-mpopcnt) flag for popcnt 
1959         instruction. Add new SSE4A (-msse4a) instruction set feature flag.
1960         * config/i386/i386.h: Add builtin definition for SSE4A.
1961         * config/i386/i386.md: Add support for ABM instructions 
1962         (popcnt and lzcnt).
1963         * config/i386/sse.md: Add support for SSE4A instructions
1964         (movntss, movntsd, extrq, insertq).
1965         * config/i386/i386.c: Add support for ABM and SSE4A builtins.
1966         Add -march=amdfam10 flag.
1967         * config/i386/ammintrin.h: Add support for SSE4A intrinsics.
1968         * doc/invoke.texi: Add documentation on flags for sse4a, abm, popcnt
1969         and amdfam10.
1970         * doc/extend.texi: Add documentation for SSE4A builtins.
1971
1972 2007-02-05  Bob Wilson  <bob.wilson@acm.org>
1973
1974         * config/xtensa/xtensa.c (constantpool_mem_p): Skip over SUBREGs.
1975
1976 2007-02-05  Richard Guenther  <rguenther@suse.de>
1977
1978         * tree-vectorizer.h (vectorizable_function): Add argument type
1979         argument, change return type.
1980         * tree-vect-patterns.c (vect_recog_pow_pattern): Adjust caller.
1981         * tree-vect-transform.c (vectorizable_function): Handle extra
1982         argument, return vectorized function decl.
1983         (build_vectorized_function_call): Remove.
1984         (vectorizable_call): Handle calls with result and argument types
1985         differing.  Handle loop vectorization factor correctly.
1986         * targhooks.c (default_builtin_vectorized_function): Adjust for
1987         extra argument.
1988         * targhooks.h (default_builtin_vectorized_function): Likewise.
1989         * target.h (builtin_vectorized_function): Add argument type
1990         argument.
1991         * config/i386/i386.c (ix86_builtin_vectorized_function): Handle
1992         extra argument, allow vectorizing of lrintf.
1993         * doc/tm.texi (TARGET_VECTORIZE_BUILTIN_VECTORIZED_FUNCTION): Adjust
1994         documentation of target hook.
1995
1996 2007-02-05  Hans-Peter Nilsson  <hp@axis.com>
1997
1998         PR target/30665
1999         * config/cris/cris.md ("*andsi_movu", "*andsi_clear", "*andhi_movu")
2000         ("*andhi_clear", andu (casesi+45)): For size-changed operand where
2001         memory is allowed, require !side_effects_p, not just !MEM_VOLATILE_P.
2002
2003 2007-02-05  Roger Sayle  <roger@eyesopen.com>
2004
2005         * fold-const.c (fold_unary) <REAL_PART>: Test for availability of
2006         BUILT_IN_COS before simplifying REAL_PART(CEXPI)) to COS.
2007         <IMAG_PART>: Likewise, check for availability of BUILT_IN_SIN.
2008         * builtins.c (fold_builtin_sincos): Check for TARGET_C99_FUNCTIONS
2009         before canonicalizing sincos to cexpi.
2010         (fold_builtin_cexp): Likewise, for canonicalizing cexp to cexpi.
2011
2012 2007-02-05  Roger Sayle  <roger@eyesopen.com>
2013
2014         * config/alpha/alpha.c (alpha_add_builtins): New Helper function.
2015         Set TREE_READONLY and TREE_NOTHROW directly, not via attributes.
2016         (alpha_init_builtins): Use alpha_add_builtins to process tables.
2017
2018 2007-02-05  Roger Sayle  <roger@eyesopen.com>
2019
2020         * mips-tfile.c (initialize_init_file): Correct endianness test.
2021
2022 2007-02-05  Kazu Hirata  <kazu@codesourcery.com>
2023
2024         * config/m68k/m68k.md (pushdi-1, pushdi, movsi+1): Don't use
2025         the 'y' constraint.
2026
2027 2007-02-05  Richard Sandiford  <richard@codesourcery.com>
2028
2029         * dwarf2out.c (dwarf2out_frame_debug_expr): Record the register
2030         saves in a PARALLEL before the register assignments.
2031
2032 2007-02-05  Richard Sandiford  <richard@codesourcery.com>
2033
2034         * doc/tm.texi (DWARF_ALT_FRAME_RETURN_COLUMN): Do not require
2035         DWARF_FRAME_RETURN_COLUMN to be a general register.
2036         * dwarf2out.c (init_return_column_size): New function, split from...
2037         (expand_builtin_init_dwarf_reg_sizes): ...here.  Allow both
2038         DWARF_FRAME_RETURN_COLUMN and DWARF_ALT_FRAME_RETURN_COLUMN
2039         to be nongeneral registers.
2040         * config/m68k/m68k.h (DWARF_FRAME_REGNUM): Only map FP and
2041         integer registers.
2042         (DWARF_FRAME_REGISTERS, DWARF_FRAME_RETURN_COLUMN): Define.
2043         (DWARF_ALT_FRAME_RETURN_COLUMN): Define.
2044
2045 2007-02-04  Zdenek Dvorak <dvorakz@suse.cz>
2046
2047         * cfgcleanup.c (try_optimize_cfg): Avoid removing ENTRY_BLOCK_PTR.
2048
2049 2007-02-04  Zdenek Dvorak <dvorakz@suse.cz>
2050
2051         * cfgloopmanip.c (loop_delete_branch_edge): Removed.
2052         (remove_path): Use can_remove_branch_p and remove_branch instead
2053         of loop_delete_branch_edge.
2054         * tree-ssa-loop-manip.c (scale_dominated_blocks_in_loop): New function.
2055         (tree_transform_and_unroll_loop): Remove dead branches immediately.
2056         Update profile using scale_dominated_blocks_in_loop.
2057         * cfghooks.c (can_remove_branch_p, remove_branch): New functions.
2058         * cfghooks.h (struct cfg_hooks): Add can_remove_branch_p.
2059         (can_remove_branch_p, remove_branch): Declare.
2060         * tree-cfg.c (tree_can_remove_branch_p): New function.
2061         (tree_cfg_hooks): Add tree_can_remove_branch_p.
2062         * cfgrtl.c (rtl_can_remove_branch_p): New function.
2063         (rtl_cfg_hooks, cfg_layout_rtl_cfg_hook): Add rtl_can_remove_branch_p.
2064
2065 2007-02-05  Jan Hubicka  <jh@suse.cz>
2066
2067         PR middle-end/30696
2068         * ipa-inline.c (cgraph_clone_inlined_nodes): When there are unanalyzed
2069         nodes in cgraph, don't remove offline copy of the function.
2070
2071 2007-02-04  Jan Hubicka  <jh@suse.cz>
2072
2073         * tree-sra.c (sra_walk_expr): Add linebreaks. BITFIELD_REFs into
2074         vectors might cause maybe_lookup_element_for_expr to be called
2075         on non-sra-candidate.
2076
2077 2007-02-04  Kazu Hirata  <kazu@codesourcery.com>
2078
2079         * config/bfin/bfin-modes.def, config/bfin/bfin.c,
2080         config/bfin/bfin.md, config/bfin/predicates.md: Follow
2081         spelling conventions.
2082
2083 2007-02-04  Richard Guenther  <rguenther@suse.de>
2084
2085         PR middle-end/30636
2086         * fold-const.c (try_move_mult_to_index): Make sure to not
2087         overflow one dimension of a multi-dimensional array access.
2088
2089 2007-02-04  Jan Hubicka  <jh@suse.cz>
2090
2091         * passes.c (init_optimization_passes): Reindent.
2092
2093 2007-02-04  Jan Hubicka  <jh@suse.cz>
2094             Eric Botcazou  <ebotcazou@adacore.com>
2095
2096         * tree-optimize.c (has_abnormal_outgoing_edge_p): Move to...
2097         (execute_fixup_cfg): Break out the abnormal goto code.
2098         * tree-inline.c (has_abnormal_outgoing_edge_p): ...here.
2099         (make_nonlocal_label_edges): Move here from execute_fixup_cfg.
2100         (optimize_inline_calls): Call make_nonlocal_label_edges.
2101
2102 2007-02-04  Jan Hubicka  <jh@suse.cz>
2103
2104         * tree-ssa-copyrename.c (copy_rename_partition_coalesce): Return
2105         true when something was changed.
2106         (rename_ssa_copies): When something was changed, do
2107         TODO_remove_unused_locals.
2108         * tree-ssa-forwprop.c (tree_ssa_forward_propagate_single_use_value):
2109         add TODO_remove_unused_locals when instruction was removed.
2110
2111 2007-02-04  Jan Hubicka  <jh@suse.cz>
2112
2113         * ipa-inline.c (try_inline): Improve debug output; work on already
2114         inline edges too.
2115         (cgraph_decide_inlining_incrementally): Indent; improve debug output;
2116         call try_inline for already inlined edges too when flattening; 
2117         inline also functions that make callee growth but overall unit size
2118         reduce.
2119
2120 2007-02-04  Kazu Hirata  <kazu@codesourcery.com>
2121
2122         * config/m32c/bitops.md, config/m32c/jump.md,
2123         config/m32c/m32c.c, config/m32c/m32c.h, config/m32r/m32r.c,
2124         config/m32r/m32r.h, config/m32r/m32r.md,
2125         config/m32r/predicates.md, config/m68hc11/larith.asm,
2126         config/m68hc11/m68hc11.c, config/m68hc11/m68hc11.h,
2127         config/m68k/m68k.h, config/mcore/mcore.md, config/mips/4k.md,
2128         config/mips/mips-protos.h, config/mips/mips.c,
2129         config/mips/mips.h, config/mips/mips.md, config/mips/mips16.S,
2130         config/mn10300/mn10300.h, config/mn10300/predicates.md,
2131         config/mt/mt.c, config/mt/mt.h, config/mt/mt.md: Follow
2132         spelling conventions.
2133
2134         * config/v850/v850.c, config/v850/v850.h, config/v850/v850.md:
2135         Follow spelling conventions.
2136
2137 2007-02-03  Douglas Gregor  <doug.gregor@gmail.com>
2138
2139        * c-opts.c (c_common_post_options): If C++0x mode is enabled, don't
2140        warn about C++0x compatibility.
2141         
2142 2007-02-04  Kazu Hirata  <kazu@codesourcery.com>
2143
2144         * config/h8300/h8300.c, config/h8300/h8300.h,
2145         config/h8300/h8300.md: Follow spelling conventions.
2146
2147 2007-02-03  Uros Bizjak  <ubizjak@gmail.com>
2148
2149         PR middle-end/30667
2150         * combine.c (try_combine): Do not substitute source operand
2151         with constants wider than 2 * HOST_BITS_PER_WIDE_INT.
2152
2153 2007-02-03  Jan Hubicka  <jh@suse.cz>
2154
2155         PR gcov-profile/30650
2156         * value-prof.c (stringop_block_profile): Fix handling of size counter;
2157         do not divide by zero for never executed counters.
2158         (tree_find_values_to_profile): Fix counters.
2159         * gcov-ui.h (GCOV_COUNTER_AVERAGE, GCOV_COUNTER_IOR): Fix comments.
2160
2161 2007-02-03  Ian Lance Taylor  <iant@google.com>
2162
2163         * lower-subreg.c (simple_move_operand): New static function,
2164         broken out of simple_move.  Reject LABEL_REF, SYMBOL_REF, and HIGH
2165         operands.
2166         (simple_move): Call simple_move_operand.
2167         (find_decomposable_subregs): Add special handling of MEMs.
2168         (can_decompose_p): Rename from cannot_decompose_p.  Reverse
2169         meaning of return value.  If we see a hard register, test whether
2170         it can store a word_mode value.  Change all callers.
2171
2172 2007-02-03  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
2173
2174         * pa.md (addvdi3, addvsi3, subvdi3, subvsi3, negvdi2, negvsi2): New
2175         ftrapv insns and expanders.
2176         (subdi3): Change define_expand operand 1 to arith11_operand, and
2177         operand 2 to reg_or_0_operand.  Change constraints of 64-bit insn
2178         pattern to handle reg_or_0 operands.  Revise 32-bit insn pattern to
2179         handle 11-bit constants and reg_or_0 operands in operands 1 and 2,
2180         respectively.
2181
2182         PR middle-end/30174
2183         * varasm.c (notice_global_symbol): Treat global objects as weak when
2184         flag_shlib is true.
2185
2186 2007-02-03  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
2187
2188         * emit-rtl.c (dconstpi): Delete.
2189         (dconstsqrt2): New.
2190         (init_emit_once): Delete dconstpi and init dconstsqrt2.
2191         * real.h (dconstpi): Delete.
2192         (dconstsqrt2): New.
2193         * builtins.c (fold_builtin_cabs): Use dconstsqrt2.
2194         (fold_builtin_hypot): Likewise.
2195
2196 2007-02-03  Tom Tromey  <tromey@redhat.com>
2197
2198         PR driver/30246
2199         * gcc.c (cpp_unique_options): Any of -ggdb3, -gstabs3,
2200         -gcoff3, -gxcoff3, -gvms3 implies -dD.
2201
2202 2007-02-03  Kazu Hirata  <kazu@codesourcery.com>
2203
2204         * c-decl.c, config/avr/avr.c, config/avr/avr.h,
2205         config/m68k/m68k.c, config/m68k/netbsd-elf.h,
2206         config/mn10300/mn10300.c, config/pdp11/pdp11.h,
2207         config/rs6000/cell.md, config/rs6000/darwin.h,
2208         config/sh/sh.md, config/sh/sh4-300.md, config/spu/spu.c,
2209         config/spu/spu.md, cselib.c, expr.c, haifa-sched.c, hwint.h,
2210         jump.c, reload.c, sched-deps.c, sched-int.h, tree-inline.c,
2211         tree-profile.c, tree-ssa-live.h, tree-vrp.c: Fix comment
2212         typos.  Follow spelling conventions.
2213         * doc/invoke.texi: Follow spelling conventions.
2214
2215 2007-02-03  Roger Sayle  <roger@eyesopen.com>
2216
2217         * simplify-rtx.c (simplify_relational_operation_1): Implement some
2218         canonicalization transformations that attempt to simplify integer
2219         constant comparisons to become comparisons against zero.
2220
2221 2007-02-03  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
2222
2223         * builtins.c (fold_builtin_cabs): Fold cabs(x+xi) into
2224         fabs(x)*sqrt(2).
2225         * fold-const.c (fold_binary): Fix comment typos.  Fold complex
2226         (x,0)-(0,y) into (x,-y).  Likewise (0,y)-(x,0) into (-x,y).
2227
2228 2007-02-02  Mike Stump  <mrs@apple.com>
2229
2230         * config/darwin9.h (DARWIN_LINKER_GENERATES_ISLANDS): Add.
2231         * config/rs6000/rs6000.c (DARWIN_GENERATE_ISLANDS): Add.
2232         (output_call): Use DARWIN_GENERATE_ISLANDS to decide when to
2233         generate a branch island.
2234
2235 2007-02-02  Bob Wilson  <bob.wilson@acm.org>
2236
2237         * config/xtensa/xtensa.c (smalloffset_mem_p): Use BASE_REG_P.
2238         (xtensa_legitimate_address_p): New.
2239         (xtensa_legitimize_address): New.
2240         (xtensa_output_addr_const_extra): New.
2241         * config/xtensa/xtensa.h (REG_OK_STRICT_FLAG): Define.
2242         (BASE_REG_P): New.
2243         (REG_OK_FOR_BASE_P): Use BASE_REG_P.
2244         (GO_IF_LEGITIMATE_ADDRESS): Move code to xtensa_legitimate_address_p.
2245         (LEGITIMIZE_ADDRESS): Move code to xtensa_legitimize_address.
2246         (OUTPUT_ADDR_CONST_EXTRA): Move code to xtensa_output_addr_const_extra.
2247         * config/xtensa/xtensa-protos.h (xtensa_legitimate_address_p): New.
2248         (xtensa_legitimize_address): New.
2249         (xtensa_output_addr_const_extra): New.
2250
2251 2007-02-02  Steve Ellcey  <sje@cup.hp.com>
2252
2253         * config/ia64/ia64.c (ia64_print_operand): Fix compare strings.
2254
2255 2007-02-02  Ian Lance Taylor  <iant@google.com>
2256
2257         * expmed.c (expand_divmod): Add comment.
2258
2259 2007-02-02  Kazu Hirata  <kazu@codesourcery.com>
2260
2261         * emit-rtl.c (renumber_insns): Remove.
2262         * flags.h: Remove the extern for flag_renumber_insns.
2263         * rtl.h: Remove the prototype for renumber_insns.
2264         * toplev.c (flag_renumber_insns): Remove.
2265
2266 2007-02-02  Hui-May Chang  <hm.chang@apple.com>
2267
2268         Revert for x86 darwin:
2269         2005-06-19  Uros Bizjak  <uros@kss-loka.si>
2270         
2271         * config/i386/i386.c (ix86_function_arg_regno_p): Put back the
2272         code before the following patch under TARGET_MACHO.
2273         (ix86_function_value_regno_p): Likewise.
2274
2275 2007-02-02  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
2276
2277         * fold-const.c (negate_expr_p, fold_negate_expr): Handle
2278         COMPLEX_EXPR.
2279
2280 2007-02-02  Maxim Kuvyrkov  <mkuvyrkov@ispras.ru>
2281
2282         PR target/29682
2283         * config/ia64/ia64.c (ia64_speculate_insn): Restrict to memory loads to
2284         general or fp registers.  Add comments.
2285         * config/ia64/ia64.md (reg_pred_prefix): Add comment.
2286
2287 2007-02-02  Paolo Bonzini  <bonzini@gnu.org>
2288
2289         * pointer-set.c (insert_aux): Only return insertion slot.
2290         (pointer_set_insert): Adjust.
2291         (pointer_set_traverse, struct pointer_map_t, pointer_map_create,
2292         pointer_map_destroy, pointer_map_insert, pointer_map_contains,
2293         pointer_map_traverse): New.
2294         * pointer-set.h (pointer_set_traverse, struct pointer_map_t,
2295         pointer_map_create,  pointer_map_destroy, pointer_map_insert,
2296         pointer_map_contains, pointer_map_traverse): Declare.
2297
2298 2007-02-02  Jakub Jelinek  <jakub@redhat.com>
2299
2300         PR middle-end/30473
2301         * builtins.c (fold_builtin_sprintf): Do not attempt to optimize
2302         sprintf (str, "%s").  Do not optimize sprintf (str, "nopercent", p++).
2303
2304 2007-02-02  Maxim Kuvyrkov  <mkuvyrkov@ispras.ru>
2305
2306         * sched-int.h (ds_to_dk, dk_to_ds): Declare functions.
2307         
2308         (struct _dep): New type.
2309         (dep_t): New typedef.
2310         (DEP_PRO, DEP_CON, DEP_KIND): New access macros.
2311         (DEP_STATUS): New access macro.  The macro with the same name was
2312         renamed to DEP_LINK_STATUS.
2313         (dep_init): Declare function
2314
2315         (struct _dep_link): New type.
2316         (dep_link_t): New typedef.
2317         (DEP_LINK_NODE, DEP_LINK_NEXT, DEP_LINK_PREV_NEXTP): New access macros.
2318         (DEP_LINK_DEP, DEP_LINK_PRO, DEP_LINK_CON, DEP_LINK_KIND): New macros.
2319         (DEP_LINK_STATUS): New macro.
2320         (debug_dep_links): New debug function.
2321
2322         (struct _deps_list): New type.
2323         (deps_list_t): New typedef.
2324         (DEPS_LIST_FIRST): New access macro.
2325         (FOR_EACH_DEP_LINK): New cycle macro.
2326         (create_deps_list, free_deps_list, delete_deps_list): Declare
2327         functions.
2328         (deps_list_empty_p, debug_deps_list, add_back_dep_to_deps_list): Ditto.
2329         (find_link_by_pro_in_deps_list, find_link_by_con_in_deps_list): Ditto.
2330         (copy_deps_list_change_con): Ditto.
2331
2332         (move_dep_link): Declare function.
2333
2334         (struct _dep_node): New type.
2335         (dep_node_t): New typedef.
2336         (DEP_NODE_BACK, DEP_NODE_DEP, DEP_NODE_FORW): New access macros.
2337
2338         (struct haifa_insn_data.back_deps): New field to hold backward
2339         dependencies of the insn.
2340         (struct haifa_insn_data.depend): Rename to forw_deps.  Change its type
2341         to deps_list_t.
2342         (struct haifa_insn_data.resolved_deps): Rename to resolved_back_deps.
2343         Change its type to deps_list_t.
2344         (INSN_BACK_DEPS): New access macro to use instead of LOG_LINKS.
2345         (INSN_DEPEND): Rename to INSN_FORW_DEPS.
2346         (RESOLVED_DEPS): Rename to INSN_RESOLVED_BACK_DEPS.
2347
2348         (INSN_COST): Move to haifa-sched.c.  Use insn_cost () instead.
2349         
2350         (DEP_STATUS): Rename to DEP_LINK_STATUS.  Fix typo in the comment.
2351
2352         (add_forw_dep, delete_back_forw_dep, insn_cost): Update declaration and
2353         all callers.
2354         (dep_cost): Declare.
2355         
2356         * sched-deps.c (CHECK): New macro to (en/dis)able sanity checks.
2357         (ds_to_dk, dk_to_ds): New functions.
2358         
2359         (init_dep_1): New static function.
2360         (init_dep): New function.
2361         (copy_dep): New static function.
2362         
2363         (dep_link_consistent_p, attach_dep_link, add_to_deps_list): New static
2364         functions.
2365         (detach_dep_link): New static function.
2366         (move_dep_link): New function.
2367         
2368         (dep_links_consistent_p, dump_dep_links): New static functions.
2369         (debug_dep_links): New debugging function.
2370         
2371         (deps_obstack, dl_obstack, dn_obstack): New static variables.
2372         
2373         (alloc_deps_list, init_deps_list): New static functions.
2374         (create_deps_list): New function.
2375         (clear_deps_list): New static function.
2376         (free_deps_list, delete_deps_list, deps_list_empty_p): New functions.
2377         (deps_list_consistent_p, dump_deps_list): New static functions.
2378         (debug_deps_list): New function.
2379         (add_back_dep_to_deps_list, find_link_by_pro_in_deps_list): New
2380         functions.
2381         (find_link_by_con_in_deps_list, copy_deps_list_change_con): Ditto.
2382
2383         (maybe_add_or_update_back_dep_1, add_or_update_back_dep_1): Update to
2384         use new scheduler dependencies lists.
2385         (add_back_dep, delete_all_dependences, fixup_sched_groups): Ditto.
2386         (sched_analyze): Ditto.  Initialize dependencies lists.
2387         (add_forw_dep, compute_forward_dependences): Update to use new
2388         scheduler dependencies lists.
2389         
2390         (init_dependency_caches): Init deps_obstack.
2391         (free_dependency_caches): Free deps_obstack.
2392         
2393         (adjust_add_sorted_back_dep, adjust_back_add_forw_dep): Update to use
2394         new scheduler dependencies lists.
2395         (delete_forw_dep, add_or_update_back_forw_dep): Ditto.
2396         (add_back_forw_dep, delete_back_forw_dep): Ditto.
2397
2398         * sched-rgn.c (set_spec_fed, find_conditional_protection, is_pfree):
2399         Update to use new scheduler dependencies lists.
2400         (is_conditionally_protected, is_prisky, add_branch_dependences): Ditto.
2401         (debug_dependencies): Ditto.
2402         (schedule_region): Update comments.
2403         
2404         * sched-ebb.c (earliest_block_with_similiar_load): Update to use new
2405         scheduler dependencies lists.
2406         (schedule_ebb): Update comments.
2407         
2408         * rtl.def (DEPS_LIST): Remove.
2409         
2410         * lists.c (unused_deps_list): Remove.
2411         (free_list): Update assertions.
2412         
2413         (alloc_DEPS_LIST, free_DEPS_LIST_list, free_DEPS_LIST_node): Remove.
2414         (remove_free_DEPS_LIST_elem, copy_DEPS_LIST_list): Ditto.
2415
2416         * rtl.h (free_DEPS_LIST_list, alloc_DEPS_LIST): Remove declarations.
2417         (remove_free_DEPS_LIST_elem, copy_DEPS_LIST_list): Ditto.
2418         
2419         * haifa-sched.c (comments): Update.
2420         (insn_cost1): Remove.  Inline the code into insn_cost ().
2421         (insn_cost): Update to use new scheduler dependencies lists.  Move
2422         processing of the dependency cost to dep_cost ().
2423         (dep_cost): New function.  Use it instead of insn_cost () when
2424         evaluating cost of the dependency.  Use compatible interface to
2425         interact with the target.
2426         (priority): Update to use new scheduler dependencies lists.
2427         (rank_for_schedule): Ditto.  Optimize heuristic that prefers the insn
2428         with greater number of insns that depend on the insn.
2429         (schedule_insn): Update to use new scheduler dependencies lists.  Add
2430         code to free backward dependencies lists.  Inline and optimize code
2431         from resolve_dep () - see PR28071.
2432         (ok_for_early_queue_removal): Update to use new scheduler dependencies
2433         lists.  Update call to targetm.sched.is_costly_dependence hook.
2434         
2435         (fix_inter_tick, try_ready, fix_tick_ready): Update to use new
2436         scheduler dependencies lists.
2437         
2438         (resolve_dep): Remove.  Move the logic to schedule_insn ().
2439         (init_h_i_d): Initialize dependencies lists.
2440         
2441         (process_insn_depend_be_in_spec): Rename to
2442         process_insn_forw_deps_be_in_spec.  Update to use new scheduler
2443         dependencies lists.
2444         (add_to_speculative_block, create_check_block_twin, fix_recovery_deps):
2445         Update to use new scheduler dependencies lists.
2446         (clear_priorities, calc_priorities, add_jump_dependencies): Ditto.
2447         
2448         * ddg.c (create_ddg_dependence, create_ddg_dep_no_link): Update to use
2449         new scheduler dependencies lists.
2450         (build_intra_loop_deps): Ditto.
2451         
2452         * target.h (struct _dep): Declare to use in
2453         gcc_target.sched.is_costly_dependence.
2454         (struct gcc_target.sched.adjust_cost): Fix typo.
2455         (struct gcc_target.sched.is_costly_dependence): Change signature to use
2456         single dep_t parameter instead of an equivalent triad.
2457         (struct gcc_target.sched.adjust_cost_2): Remove.
2458
2459         * target-def.h (TARGET_SCHED_ADJUST_COST_2): Remove.
2460
2461         * reg-notes.def (DEP_TRUE, DEP_OUTPUT, DEP_ANTI): Update comments.
2462
2463         * doc/tm.texi (TARGET_SCHED_IS_COSTLY_DEPENDENCE): Update
2464         documentation.
2465         (TARGET_SCHED_ADJUST_COST_2): Remove documentation.
2466
2467         * doc/rtl.texi (LOG_LINKS): Remove part about instruction scheduler.
2468         (REG_DEP_TRUE): Document.
2469         
2470         * config/ia64/ia64.c (ia64_adjust_cost_2): Rename to ia64_adjust_cost.
2471         Change signature to correspond to the targetm.sched.adjust_cost hook.  
2472         Update use in TARGET_SCHED_ADJUST_COST_2.
2473         (TARGET_SCHED_ADJUST_COST_2): Rename to TARGET_SCHED_ADJUST_COST.
2474         (ia64_dependencies_evaluation_hook, ia64_dfa_new_cycle): Update to use
2475         new scheduler dependencies lists.
2476         (ia64_gen_check): Ditto.
2477
2478         * config/mips/mips.c (vr4130_swap_insns_p): Update to use new scheduler
2479         dependencies lists.
2480         
2481         * config/rs6000/rs6000.c (rs6000_is_costly_dependence): Change
2482         signature to correspond to the targetm.sched.is_costly_dependence hook.
2483         (is_costly_group): Update to use new scheduler dependencies lists.
2484
2485         * config/spu/spu.c (spu_sched_adjust_cost): Use insn_cost () function
2486         instead of INSN_COST () macro.
2487
2488 2007-02-01  Ian Lance Taylor  <iant@google.com>
2489
2490         * lower-subreg.c (resolve_clobber): Handle a subreg of a concatn.
2491
2492 2007-02-01  Guy Martin  <gmsoft@gentoo.org>
2493
2494         * pa.md (tp_load): Correct mfctl instruction syntax.
2495
2496 2007-02-01  Geoffrey Keating  <geoffk@apple.com>
2497
2498         * config/rs6000/rs6000.c (rs6000_stack_info): Correct
2499         altivec_padding_size calculation on AIX.  Improve comment, add
2500         assert to verify that it's right.
2501
2502         * config/rs6000/darwin.h (MD_UNWIND_SUPPORT): Don't define for
2503         64-bit.
2504
2505 2007-2-01  Seongbae Park  <seongbae.park@gmail.com>
2506
2507         PR inline-asm/28686
2508         * global.c (global_alloc): Add mising initialization of
2509         ELIMINABLE_REGSET.
2510
2511 2007-02-01  Roger Sayle  <roger@eyesopen.com>
2512
2513         * alias.c (init_alias_analysis): Correct whitespace.
2514         * bb-reorder.c (fix_edges_for_rarely_executed_code,
2515         partition_hot_cold_basic_blocks): Likewise.
2516         * builtins.c (expand_builtin_printf, expand_builtin_fprintf,
2517         expand_builtin_sprintf, fold_builtin_carg, fold_builtin_sprintf,
2518         maybe_emit_sprintf_chk_warning, fold_builtin_sprintf_chk,
2519         fold_builtin_snprintf_chk, fold_builtin_printf,
2520         fold_builtin_fprintf, do_mpfr_ckconv, do_mpfr_arg1, do_mpfr_arg2,
2521         do_mpfr_arg3, do_mpfr_sincos): Likewise.
2522         * cfgcleanup.c (cleanup_cfg): Likewise.
2523         * cfgexpand.c (tree_expand_cfg): Likewise.
2524         * fold-const.c (fold_binary) <RDIV_EXPR>: Likewise.
2525         * function.c (get_next_funcdef_no): Likewise.
2526         * gengtype.c (main): Likewise.
2527         * genmodes.c (main): Likewise.
2528         * gcse.c (bypass_conditional_jumps, print_ldst_list): Likewise.
2529         * haifa-sched.c (schedule_block, extend_h_i_d): Likewise.
2530         * ifcvt.c (noce_emit_move_insn): Likewise.
2531         * modulo-sched.c (generate_prolog_epilog, sms_schedule_by_order):
2532         Likewise.
2533         * stor-layout.c (get_best_mode): Likewise.
2534         * tree-ssa-loop-niter.c (get_val_for): Likewise.
2535         * tree-ssa-structalias.c (get_varinfo, get_varinfo_fc,
2536         scc_visit, do_ds_constraint, do_complex_constraint, label_visit,
2537         perform_var_substitution, solve_graph): Likewise.
2538         * tree-vrp.c (vrp_finalize): Likewise.
2539
2540 2007-02-01  Ian Lance Taylor  <iant@google.com>
2541
2542         * lower-subreg.c (simplify_gen_subreg_concatn): If we ask for the
2543         high part of a paradoxical subreg, return a constant zero.
2544
2545 2007-02-01  Zdenek Dvorak <dvorakz@suse.cz>
2546
2547         * toplev.c (lang_dependent_init): Call init_set_costs.
2548         * loop-init.c (loop_optimizer_init): Do not call init_set_costs.
2549
2550 2007-02-01  Richard Guenther  <rguenther@suse.de>
2551
2552         PR middle-end/30656
2553         * fold-const.c (fold_negate_expr): Allow negating a
2554         constant if overflow does not change.
2555
2556 2007-02-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2557
2558         * doc/c-tree.texi (Expression trees): Improve markup.
2559         * doc/tm.texi (Register Classes, Addressing Modes)
2560         (Floating Point): Fix spacing after abbreviations.  Fix some
2561         typos.
2562
2563 2007-02-01  Ben Elliston  <bje@au.ibm.com>
2564
2565         * doc/invoke.texi: Replace "bugfix" with "bug fix" throughout.
2566         * doc/contrib.texi: Likewise.
2567         * doc/install.texi: Likewise.
2568
2569 2007-01-31  Richard Henderson  <rth@redhat.com>
2570             Ian Lance Taylor  <iant@google.com>
2571
2572         * lower-subreg.c: New file.
2573         * rtl.def (CONCATN): Define.
2574         * passes.c (init_optimization_passes): Add pass_lower_subreg and
2575         pass_lower_subreg2.
2576         * emit-rtl.c (update_reg_offset): New static function, broken out
2577         of gen_rtx_REG_offset.
2578         (gen_rtx_REG_offset): Call update_reg_offset.
2579         (gen_reg_rtx_offset): New function.
2580         * regclass.c: Revert patch of 2006-03-05, restoring
2581         reg_scan_update.
2582         (clear_reg_info_regno): New function.
2583         * dwarf2out.c (concatn_loc_descriptor): New static function.
2584         (loc_descriptor): Handle CONCATN.
2585         * common.opt (fsplit_wide_types): New option.
2586         * opts.c (decode_options): Set flag_split_wide_types when
2587         optimizing.
2588         * timevar.def (TV_LOWER_SUBREG): Define.
2589         * rtl.h (gen_reg_rtx_offset): Declare.
2590         (reg_scan_update): Declare.
2591         * regs.h (clear_reg_info_regno): Declare.
2592         * tree-pass.h (pass_lower_subreg): Declare.
2593         (pass_lower_subreg2): Declare.
2594         * doc/invoke.texi (Option Summary): List -fno-split-wide-types.
2595         (Optimize Options): Add -fsplit-wide-types to -O1 list.  Document
2596         -fsplit-wide-types.
2597         * doc/rtl.texi (Regs and Memory): Document concat and concatn.
2598         * Makefile.in (OBJS-common): Add lower-subreg.o.
2599         (lower-subreg.o): New target.
2600
2601 2007-01-31  Kazu Hirata  <kazu@codesourcery.com>
2602
2603         * config/sh/sh.h (HAVE_SECONDARY_RELOADS): Remove.
2604
2605 2007-01-31  Anatoly Sokolov <aesok@post.ru>
2606
2607         PR target/19087
2608         * config/avr/avr.c (DWARF2_ADDR_SIZE): Define.
2609
2610 2007-01-31  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
2611
2612         PR middle-end/29335
2613         * builtins.c (fold_builtin_sqrt): Use MPFR for constant args.
2614
2615 2007-01-31  Zdenek Dvorak <dvorakz@suse.cz>
2616
2617         * cfgloop.h: Include vec-prim.h.
2618         (enum li_flags): Remove LI_ONLY_OLD.
2619         (loop_iterator): Changed.
2620         (fel_next, fel_init): Iterate over loop tree.
2621         (FOR_EACH_LOOP_BREAK): New macro.
2622         * loop-unswitch.c (unswitch_loops): Do not pass LI_ONLY_OLD to
2623         FOR_EACH_LOOP.
2624         * tree-ssa-loop-unswitch.c (tree_ssa_unswitch_loops): Ditto.
2625         * modulo-sched.c (sms_schedule): Ditto.
2626         * tree-vectorizer.c (vectorize_loops): Ditto.
2627         * doc/loop.texi: Update information on loop numbering and behavior of
2628         FOR_EACH_LOOP wrto new loops.
2629         * tree-scalar-evolution.c (compute_overall_effect_of_inner_loop,
2630         add_to_evolution_1): Test nestedness of loops instead of comparing
2631         their numbers.
2632         * tree-chrec.c (chrec_fold_plus_poly_poly,
2633         chrec_fold_multiply_poly_poly, chrec_evaluate,
2634         hide_evolution_in_other_loops_than_loop, chrec_component_in_loop_num,
2635         reset_evolution_in_loop): Ditto.
2636         * Makefile.in (CFGLOOP_H): Add vecprim.h dependency.
2637
2638 2007-01-31  Dirk Mueller  <dmueller@suse.de>
2639
2640         * c-common.c (warn_about_parentheses): Separate warning about
2641         un-parenthized sequence of comparison operators from the one
2642         which is supposed to warn about x <= y <= z.
2643
2644 2007-01-31  Uros Bizjak  <ubizjak@gmail.com>
2645
2646         * optabs.h (enum optab_index): Add new OTI_isinf.
2647         (isinf_optab): Define corresponding macro.
2648         * optabs.c (init_optabs): Initialize isinf_optab.
2649         * genopinit.c (optabs): Implement isinf_optab using isinf?f2
2650         patterns.
2651         * builtins.c (mathfn_built_in): Handle BUILT_IN_ISINF{,F,L}.
2652         (expand_builtin_interclass_mathfn): Expand BUILT_IN_ISINF{,F,L}
2653         using isinf_optab.
2654         (expand_builtin): Expand BUILT_IN_ISINF{,F,L} using
2655         expand_builtin_interclass_mathfn.
2656         * reg_stack.c (subst_stack_regs_pat): Handle UNSPEC_FXAM.
2657         * config/i386/i386.md (UNSPEC_FXAM): New constant.
2658         (fxam<mode>2_i387): New insn pattern.
2659         (isinf<mode>2) New expander to implement isinf, isinff and isinfl
2660         built-in functions as x87 inline asm.
2661
2662 2007-01-31  Kazu Hirata  <kazu@codesourcery.com>
2663
2664         * gcc/config/arm/unwind-arm.h (_sleb128_t, _uleb128_t): New.
2665
2666 2007-01-30  Eric Christopher  <echristo@apple.com>
2667
2668         * config.gcc: Add geode.
2669
2670 2007-01-31  Kazu Hirata  <kazu@codesourcery.com>
2671
2672         * cgraphunit.c, config/arm/arm.c, config/m68k/m68k.c,
2673         ipa-inline.c, tree-profile.c, tree-ssa-live.c,
2674         tree-ssa-math-opts.c, tree-ssanames.c, tree-vect-analyze.c,
2675         value-prof.c: Fix comment typos.
2676
2677 2007-01-30  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
2678
2679         PR c++/24745
2680         * doc/invoke.texi (Wpointer-arith): Document warning.
2681
2682 2007-01-30  Janis Johnson  <janis187@us.ibm.com>
2683
2684         * doc/extend.texi (Decimal Floating Types): Remove decfloat.h from
2685         the list of discrepancies from the draft TR.
2686
2687 2007-01-30  Dirk Mueller  <dmueller@suse.de>
2688
2689         PR c++/30601
2690         * doc/invoke.texi (-Wreturn-type): Update description to
2691         match new behavior.
2692
2693 2007-01-30  Richard Sandiford  <richard@codesourcery.com>
2694
2695         * cfgrtl.c (try_redirect_by_replacing_jump): Check only_sets_cc0_p.
2696
2697 2007-01-30  Uros Bizjak  <ubizjak@gmail.com>
2698
2699         * builtins.c (expand_builtin_int_interclass_roundingfn): New function
2700         to handle optabs that operate on floating point input argument and
2701         output to integer output.
2702         (expand_builtin_mathfn) [BUILT_IN_ILOGB]: Move from here ...
2703         (expand_builtin_interclass_mathfn) [BUILT_IN_ILOGB]: ... to here.
2704         (expand_builtin): Expand BUILT_IN_ILOGB{,F,L} using
2705         expand_builtin_interclass_mathfn ().
2706         * config/i386/i386.md (fxtractxf3_i387): Rename from *fxtractxf3_i387.
2707         (ilogbsi2): Remove.
2708         (ilogbxf2, ilogb<mode>2): New expanders to implement ilogb, ilogbf and
2709         ilogbl built-in functions as x87 intrinsics.
2710
2711 2007-01-30  Richard Guenther  <rguenther@suse.de>
2712
2713         PR middle-end/27657
2714         * dwarf2out.c (reference_to_unused): Query varpool if the
2715         variable was output.
2716
2717 2007-01-30  Richard Guenther  <rguenther@suse.de>
2718
2719         PR middle-end/30313
2720         * passes.c (execute_one_pass): Reset in_gimple_form to not
2721         confuse non-unit-at-a-time mode.
2722
2723 2007-01-29  Roger Sayle  <roger@eyesopen.com>
2724             Richard Guenther  <rguenther@suse.de>
2725
2726         * fold-const.c (round_up): Make HIGH an unsigned HOST_WIDE_INT to
2727         avoid undefined behaviour on overflow.  Use force_fit_type_double
2728         to construct the constant with the specified TREE_OVERFLOW.
2729
2730 2007-01-29  Janis Johnson  <janis187@us.ibm.com>
2731
2732         * config/dfp-bit.c: Add parameterized support for fp exceptions.
2733         * config/dfp-bit.h: Ditto.
2734
2735 2007-01-29  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
2736
2737         * c-decl.c (pop_scope): Replace warnings with call to
2738         warn_for_unused_label.
2739         * c-common.h (warn_for_unused_label): Declare.
2740         * c-common.c (warn_for_unused_label): Define.
2741
2742 2007-01-29  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
2743
2744         * tree-optimize.c (update_inlined_to_pointers): Delete unused
2745         function.
2746
2747 2007-01-29  Janis Johnson  <janis187@us.ibm.com>
2748
2749         * Makefile.in (USER_H): Remove decfloat.h.
2750         * ginclude/decfloat.h: Delete, moving contents to ...
2751         * ginclude/float.h: Add support for decimal floating point,
2752         guarded by __STDC_WANT_DEC_FP__.
2753
2754 2007-01-29  Mike Stump  <mrs@apple.com>
2755
2756         * doc/gccint.texi (Top): Rename Loop Representation to Loop
2757         Analysis and Representation to resolve case insensitive conflict.
2758         * doc/loop.texi (Loop Analysis and Representation): Likewise.
2759
2760 2007-01-28  Daniel Berlin  <dberlin@dberlin.org>
2761
2762         * tree.h (struct tree_memory_tag): Add aliases member.
2763         (MTAG_ALIASES): New macro.
2764         * tree-ssa-alias.c (alias_bitmap_obstack): New variable.
2765         (add_may_alias): Remove pointer-set. Update for may_aliases being
2766         a bitmap.
2767         (mark_aliases_call_clobbered): Update for may_aliases being a
2768         bitmap.
2769         (compute_tag_properties): Ditto.
2770         (create_partition_for): Ditto.
2771         (compute_memory_partitions): Ditto.
2772         (dump_may_aliases_for): Ditto.
2773         (is_aliased_with): Ditto.
2774         (add_may_alias_for_new_tag): Ditto.
2775         (rewrite_alias_set_for): Rewrite for may_aliases being a bitmap.
2776         (compute_is_aliased): New function.
2777         (compute_may_aliases): Call compute_is_aliased).
2778         (init_alias_info): Initialize alias_bitmap_obstack.
2779         (union_alias_set_into): New function.
2780         (compute_flow_sensitive_aliasing): Use union_aliases_into.
2781         (have_common_aliases_p): Rewrite to take two bitmaps and use
2782         intersection.
2783         (compute_flow_insensitive_aliasing): Stop using pointer-sets.
2784         Update for bitmaps.
2785         (finalize_ref_all_pointers): Update for add_may_alias changes.
2786         (new_type_alias): Ditto.
2787         * tree-flow-inline.h (may_aliases): Return a bitmap.
2788         * tree-dfa.c (dump_variable): Check for MTAG_P'ness.
2789         * tree-ssa.c (verify_flow_insensitive_alias_info): Update for
2790         may_aliases being a bitmap.
2791         * tree-flow.h (struct var_ann_d): Remove may_aliases member.
2792         may_aliases now returns a bitmap.
2793         * tree-ssa-structalias.c (merge_smts_into): Update for may_aliases
2794         being a bitmap.
2795         * tree-ssa-operands.c (add_virtual_operand): Update for
2796         may_aliases being a bitmap.
2797
2798 2007-01-29  Daniel Berlin  <dberlin@dberlin.org>
2799
2800         PR tree-optimization/30630
2801         * tree-ssa-structalias.c (do_complex_constraint): Mark correct
2802         variable as changed.
2803
2804 2007-01-29  Simon Martin  <simartin@users.sourceforge.net>
2805
2806         PR c++/28266
2807         * gimplify.c (gimplify_target_expr): Make sure that the TARGET_EXPR is
2808         expanded only once even if an error occurs.
2809
2810 2007-01-29  Ben Elliston  <bje@au.ibm.com>
2811
2812         * gcov-io.h (__gcov_indirect_call_profiler): Declare.
2813         (__gcov_average_profiler): Likewise.
2814         (__gcov_ior_profiler): Likewise.
2815         (__gcov_merge_ior): Likewise.
2816
2817 2007-01-28  Jan Hubicka  <jh@suse.cz>
2818
2819         * builtins.c (expand_builtin_memset): Fix typo in my last patch.
2820         * value-prof.c (stringop_block_profile): Likewise.
2821
2822 2007-01-28  Jan Hubicka  <jh@suse.cz>
2823
2824         * expr.c (emit_block_move_via_movmem, emit_block_move_via_libcall): Add
2825         variant handling histograms; add wrapper.
2826         (clear_storage_via_libcall): Export.
2827         (emit_block_move_hints): Break out from ...; add histograms.
2828         (emit_block_move): ... this one.
2829         (clear_storage_hints): Break out from ...; add histograms.
2830         (clear_storage): ... this one.
2831         (set_storage_via_memset): Handle histogram.
2832         * expr.h (emit_block_move_via_libcall, emit_block_move_hints): Declare.
2833         (clear_storage_hints, clear_storage_via_libcall): Declare.
2834         (set_storage_via_setmem): Update prototype.
2835         * doc/md.texi (movmem, setmem): Document new arguments.
2836
2837         * value-prof.c (dump_histogram_value, tree_find_values_to_profile): Add
2838         new histograms.
2839         (stringop_block_profile): New global function.
2840         (tree_stringops_values_to_profile): Profile block size and alignment.
2841         * value-prof.h (enum hist_type): add HIST_TYPE_AVERAGE and
2842         HIST_TYPE_IOR.
2843         (struct profile_hooks): Add gen_average_profiler and gen_ior_profiler.
2844         (stringop_block_profile): Declare.
2845         * builtins.c: Include value-prof.h.
2846         (expand_builtin_memcpy, expand_builtin_memset): Pass block profile.
2847         * gcov-ui.h (GCOV_COUNTER_NAMES): Add new counter.
2848         (GCOV_COUNTER_AVERAGE, GCOV_COUNTER_IOR): New constants.
2849         (GCOV_COUNTERS, GCOV_LAST_VALUE_COUNTER): Update.
2850         * profile.c (instrument_values): Add new counters.
2851         * cfgexpand.c (expand_gimple_basic_block): Propagate histograms to
2852         calls.
2853         * tree-profile.c (tree_average_profiler_fn, tree_ior_profiler_fn): New.
2854         (tree_init_edge_profiler): Build new profilers.
2855         (tree_gen_average_profiler, tree_gen_ior_profiler): New.
2856         (pass_tree_profile): Add dump.
2857         (tree_profile_hooks): Update.
2858         * Makefile.in (LIBGCOV): Add new constants.
2859         * libgcov.c (__gcov_merge_ior, __gcov_average_profiler,
2860         __gcov_ior_profiler): New.
2861         * i386.md (movmem/setmem expanders): Add new optional arguments.
2862
2863 2007-01-28  David Edelsohn  <edelsohn@gnu.org>
2864
2865         * doc/md.texi (Standard Pattern Names): Document blockage pattern.
2866
2867 2007-01-28  Zdenek Dvorak <dvorakz@suse.cz>
2868
2869         * tree-ssa-loop-unswitch.c: Include tree-inline.h.
2870         (tree_unswitch_single_loop): Pass eni_size_weights to
2871         tree_num_loop_insns.
2872         * tree-ssa-loop-manip.c: Include tree-inline.h.
2873         (can_unroll_loop_p): Pass eni_size_weights to
2874         tree_num_loop_insns.
2875         * tree-ssa-loop-ch.c (should_duplicate_loop_header_p):
2876         Pass eni_size_weights to estimate_num_insns.
2877         * tree.h (init_inline_once): Export.
2878         * toplev.c (backend_init): Call init_inline_once.
2879         * cgraphunit.c (cgraph_process_new_functions,
2880         cgraph_analyze_function): Pass eni_inlining_weights to
2881         estimate_num_insns.
2882         * ipa-inline.c (compute_inline_parameters): Ditto.
2883         * tree-ssa-loop-ivcanon.c (tree_num_loop_insns): Pass weights
2884         to estimate_num_insns.
2885         (try_unroll_loop_completely): Pass eni_size_weights to
2886         tree_num_loop_insns.
2887         * tree-eh.c (decide_copy_try_finally): Pass eni_size_weights
2888         ot estimate_num_insns.
2889         * tree-ssa-loop-prefetch.c: Include tree-inline.h.
2890         (loop_prefetch_arrays): Pass eni_time_weights to tree_num_loop_insns.
2891         * tree-inline.c (eni_inlining_weights, eni_size_weights,
2892         eni_time_weights): New variables.
2893         (init_inline_once): Initialize them.
2894         (struct eni_data): Mew.
2895         (estimate_num_insns_1, estimate_num_insns): Use weights.
2896         * tree-inline.h (struct eni_weights_d): New.
2897         (eni_inlining_weights, eni_size_weights, eni_time_weights): Declare.
2898         (estimate_num_insns): Declaration changed.
2899         * cfgloop.h (tree_num_loop_insns): Declaration changed.
2900         * Makefile.in (tree-ssa-loop-unswitch.o, tree-ssa-loop-prefetch.o,
2901         tree-ssa-loop-manip.o): Add TREE_INLINE_H dependency.
2902
2903 2007-01-28  Zdenek Dvorak <dvorakz@suse.cz>
2904
2905         * tree-data-ref.c (conflict_fn): Assert that the number of affine
2906         relations in the conflict function is valid.
2907
2908 2007-01-27  Ian Lance Taylor  <iant@google.com>
2909
2910         * common.opt: Add fstrict-overflow.
2911         * opts.c (decode_options): Set flag_strict_overflow if -O2.
2912         * flags.h (TYPE_OVERFLOW_WRAPS): Define.
2913         (TYPE_OVERFLOW_UNDEFINED): Define.
2914         (TYPE_OVERFLOW_TRAPS): Define.  This replaces TYPE_TRAP_SIGNED.
2915         Replace all uses.
2916         * tree.h (TYPE_TRAP_SIGNED): Don't define.
2917         * fold-const.c (negate_expr_p): Use TYPE_OVERFLOW_UNDEFINED.
2918         (fold_negate_expr): Likewise.
2919         (make_range): Likewise.
2920         (extract_muldiv_1): Likewise.
2921         (maybe_canonicalize_comparison): Likewise.
2922         (fold_comparison): Likewise.
2923         (fold_binary): Likewise.
2924         (tree_expr_nonnegative_p): Likewise.
2925         (tree_expr_nonzero_p): Likewise.
2926         * tree-vrp.c (compare_values): Likewise.
2927         (extract_range_from_binary_expr): Likewise.
2928         (extract_range_from_unary_expr): Likewise.
2929         * tree-ssa-loop-niter.c (infer_loop_bounds_from_signedness):
2930         Likewise.
2931         (nowrap_type_p): Likewise.
2932         * tree-scalar-evolution.c (simple_iv): Likewise.
2933         * fold-const.c (negate_expr_p): Use TYPE_OVERFLOW_WRAPS.
2934         (build_range_check): Likewise.
2935         (extract_muldiv_1): Likewise.
2936         (fold_comparison): Likewise.
2937         * tree-vrp.c (vrp_int_const_binop): Likewise.
2938         (extract_range_from_unary_expr): Likewise.
2939         * convert.c (convert_to_integer): Likewise.
2940         * fold-const.c (fold_negate_expr): Use TYPE_OVERFLOW_TRAPS.
2941         (fold_comparison): Likewise.
2942         (fold_binary): Likewise.
2943         * optabs.c (optab_for_tree_code): Likewise.
2944         * tree-vectorizer.c (vect_is_simple_reduction): Likewise.
2945         * simplify-rtx.c (simplify_const_relational_operation): Check
2946         flag_strict_overflow and flag_trapv.
2947         (simplify_const_relational_operation): Likewise.
2948         * doc/invoke.texi (Option Summary): Mention -fstrict-overflow.
2949         (Optimize Options): Add -fstrict-overflow to -O2 list.  Document
2950         -fstrict-overflow.
2951
2952 2007-01-27  Roger Sayle  <roger@eyesopen.com>
2953
2954         * tree.c (tree_fold_gcd): Delete.
2955         * tree.h (tree_fold_gcd): Remove prototype.
2956         * tree-data-ref.c (tree_fold_divides_p): Don't use tree_fold_gcd to
2957         test whether one constant integer is a multiple of another.  Instead
2958         call int_const_binop with TRUNC_MOD_EXPR and test for a zero result.
2959         * fold-const.c (multiple_of_p):  We've determined both TOP and
2960         BOTTOM are integer constants so we can call int_const_binop directly
2961         instead of the more generic const_binop.
2962
2963 2007-01-27  Roger Sayle  <roger@eyesopen.com>
2964
2965         * fold-const.c (size_binop): In the fast-paths for X+0, 0+X, X-0 and
2966         1*X check that the constant hasn't overflowed, to preserve the
2967         TREE_OVERFLOW bit.
2968         (round_up): Provide an efficient implementation when rouding-up an
2969         INTEGER_CST to a power-of-two.
2970
2971 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2972
2973         * doc/sourcebuild.texi: Add comma for clarity.
2974         * doc/extend.texi: Fix some typos.
2975         * doc/passes.texi: Likewise.
2976         * doc/cppinternals.texi: Likewise.
2977         * doc/c-tree.texi: Likewise.
2978         * doc/tree-ssa.texi: Likewise.
2979         * doc/install.texi: Likewise.
2980
2981 2007-01-27  Jan Hubicka  <jh@suse.cz>
2982
2983         * tree-sra.c (sra_walk_function): Don't rely on aliases being build.
2984         (pass_sra): Do not require alias information.
2985         * passes.c (init_optimization_passes): Add SRA
2986
2987 2007-01-27  Steven Bosscher  <steven@gcc.gnu.org>
2988
2989         * tracer.c (rest_of_handle_tracer): We already cleaned
2990         up the CFG in tracer() so don't do it here again.
2991         * cfgcleanup.c (rest_of_handle_jump2): Don't repeat
2992         cleanup_cfg here, either.  And don't call renumber_insns.
2993
2994         * cfgrtl.c (rtl_verify_flow_info_1): Don't verify that BB_END
2995         and BB_HEAD are in the insn stream here.  Instead make sure
2996         that BB_INSN is valid on all insns.  Also, do check here that
2997         there are no pending branch predictions...
2998         (rtl_verify_flow_info): ...instead of doing it here.  Checks
2999         for BB_END and BB_HEAD moved from rtl_verify_flow_info_1 to
3000         here.
3001
3002 2007-01-26  Roger Sayle  <roger@eyesopen.com>
3003
3004         * config/i386/i386.c (ix86_swap_binary_operands_p): New helper
3005         function to simplify/factorize operand order canonicalization.
3006         (ix86_fixup_binary_operands): Reorganize using the above function.
3007         (ix86_binary_operator_ok): Likewise.
3008
3009 2007-01-27  Jakub Jelinek  <jakub@redhat.com>
3010
3011         * genattrtab.c (struct attr_value_list, insn_code_values): Move to
3012         file scope from optimize_attrs.
3013         (simplify_test_exp): If insn_code_values is not NULL, use it to speed
3014         up search.
3015         (optimize_attrs): Clear insn_code_values after freeing it.
3016
3017 2007-01-26  Zdenek Dvorak <dvorakz@suse.cz>
3018
3019         * tree-ssa-address.c (create_mem_ref): Remove ", bsi" from
3020         a parts.base assignment.
3021
3022 2007-01-26  Zdenek Dvorak <dvorakz@suse.cz>
3023
3024         * tree-data-ref.c (dump_subscript): Use dump_conflict_function.
3025         (compute_subscript_distance, initialize_data_dependence_relation,
3026         finalize_ddr_dependent, analyze_ziv_subscript,
3027         analyze_siv_subscript_cst_affine,
3028         compute_overlap_steps_for_affine_univar,
3029         compute_overlap_steps_for_affine_1_2, analyze_subscript_affine_affine,
3030         analyze_siv_subscript, analyze_miv_subscript,
3031         analyze_overlapping_iterations, subscript_dependence_tester_1,
3032         compute_self_dependence, free_dependence_relation): Work
3033         with affine_fn instead of chrecs.
3034         (dump_affine_function, dump_conflict_function, affine_function_equal_p,
3035         common_affine_function, affine_function_base,
3036         affine_function_constant_p, affine_fn_op, affine_fn_plus,
3037         affine_fn_minus, affine_fn_free, conflict_fn_not_known,
3038         conflict_fn_no_dependence, free_conflict_function, free_subscripts,
3039         conflict_fn, affine_fn_cst, affine_fn_univar): New functions.
3040         (all_chrecs_equal_p): Removed.
3041         * tree-data-ref.h (affine_fn, conflict_function): New types.
3042         (struct subscript): Change type of conflicting_iterations_in_a
3043         and conflicting_iterations_in_b.
3044
3045 2007-01-26  Steve Ellcey  <sje@cup.hp.com>
3046
3047         PR other/30182
3048         * config/pa/pa.h (TARGET_HPUX_11): New.
3049         * config/pa/pa-hpux11.h (TARGET_HPUX_11): New.
3050         * config/pa/pa.c (pa_init_builtins): Use TARGET_HPUX_11.
3051
3052 2007-01-26  Daniel Berlin  <dberlin@dberlin.org>
3053         Richard Guenther  <rguenther@suse.de>
3054
3055         * tree-ssa-structalias.c (solve_graph): Handle case
3056         we merged the variable to another.
3057
3058 2007-01-25  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
3059
3060         * builtins.c (fold_builtin_1): Treat ccos and ccosh as 'even'
3061         functions.
3062
3063         * fold-const.c (negate_mathfn_p): Treat casin, casinh, catan,
3064         catanh, cproj, csin, csinh, ctan and ctanh as 'odd' functions.
3065
3066 2007-01-25  DJ Delorie  <dj@redhat.com>
3067
3068         * config/m32c/m32c.c (m32c_cannot_change_mode_class): We don't
3069         allow changes to modes which don't fit in those registers.
3070
3071         * reload1.c (choose_reload_regs): Check for invalid subregs before
3072         computing their locations, not after.
3073
3074 2007-01-25  Geoffrey Keating  <geoffk@apple.com>
3075
3076         PR 25127
3077         * config/rs6000/rs6000.c (first_altivec_reg_to_save): On Darwin,
3078         save Altivec registers in an eh_return function.
3079         (compute_vrsave_mask): Likewise.
3080         (rs6000_stack_info): Correct AIX/Darwin stack alignment computation
3081         for saving Altivec registers.
3082         (rs6000_emit_prologue): Don't allocate stack twice in
3083         eh_return function.  Correct expected value of altivec_save_offset
3084         when using save_world.  Describe save of R0 to stack when using
3085         save_world.  Describe stack pointer adjustment when using
3086         save_world.  Remove duplicated eh_return parameter register saving.
3087         Update sp_offset variable after save_world.
3088         * config/rs6000/t-darwin (LIB2FUNCS_STATIC_EXTRA): Remove
3089         darwin-world.asm.
3090         (LIB2FUNCS_EXTRA): Add darwin-world.asm.
3091         * config/rs6000/darwin.h (SUBTARGET_OVERRIDE_OPTIONS): -m64
3092         implies Altivec.
3093
3094 2007-01-25  Steve Ellcey  <sje@cup.hp.com>
3095
3096         * config.gcc (ia64*-*-hpux*): Make posix threads the default.
3097
3098 2007-01-25  Steve Ellcey  <sje@cup.hp.com>
3099
3100         PR other/30182
3101         * config/pa/pa.c (pa_init_builtins): Set asm names for finite routines.
3102         * config/ia64/ia64.c (ia64_init_builtins):  Ditto.
3103
3104 2007-01-25  Richard Guenther  <rguenther@suse.de>
3105
3106         * doc/invoke.texi (-Wcoverage-mismatch): Document.
3107         * common.opt (-Wcoverage-mismatch): New warning option.
3108         * coverage.c (get_coverage_counts): Ignore coverage mismatch
3109         if -Wcoverage-mismatch is given.
3110
3111 2007-01-25  Razya Ladelsky  <razya@il.ibm.com>
3112
3113         * ipa-cp.c (ipcp_insert_stage, ipcp_driver): Support for SSA.
3114         (ipcp_driver): Change to static definition.
3115         Add dumping of the ifunctions.
3116         (constant_val_insert): Remove unused parameter. Support for SSA.
3117         (ipcp_propagate_const): Support for SSA.
3118         (ipcp_profile_bb_print): Print only analyzed nodes.
3119         (ipcp_replace_map_create): Remove support for Fortran constant
3120         for now.
3121         * ipa-prop.c (ipa_method_modify_stmt,
3122         ipa_callsite_compute_param): Support for SSA.
3123         * ipa-prop.h (ipcp_driver): Remove declaration.
3124         (IS_VALID_TREE_MAP_INDEX): Add define.
3125
3126 2007-01-24  Geoffrey Keating  <geoffk@apple.com>
3127
3128         * unwind-dw2.c (execute_stack_op): Handle DW_OP_swap.
3129
3130 2007-01-24  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
3131
3132         PR middle-end/30447
3133         * builtins.c (fold_builtin_cabs): Use MPFR to evaluate a
3134         constant argument to cabs and do it without checking for
3135         -funsafe-math-optimizations.
3136
3137 2007-01-24  Douglas Gregor  <dgregor@osl.iu.edu>
3138
3139         * c-common.h (RID_FIRST_CXX0X): New.
3140         (RID_LAST_CXX0X): New.
3141         * c-opts.c (c_common_handle_option): -Wc++0x-compat is triggered
3142         by -Wall.
3143         * c.opt (Wc++0x-compat): New.
3144         * doc/invoke.texi (-Wc++0x-compat): Document.
3145
3146 2007-01-24  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
3147
3148         * builtins.c (fold_builtin_carg): New.
3149         (fold_builtin_1): Use it.
3150
3151 2007-01-24  Jan Hubicka  <jh@suse.cz>
3152
3153         * ipa-inline.c (cgraph_decide_inlining): Initialize initial_insns.
3154
3155         * ipa-inline.c (initial_insns, max_insns): Delete.
3156         (compute_max_insns): New function.
3157         (cgraph_decide_inlining_of_small_function): Use it; take minimal amount
3158         of insns as base for code growth.
3159         (cgraph_decide_inlining): Make initial_insns local; do not compute
3160         max_insns.
3161         * params.def (PARAM_INLINE_UNIT_GROWTH): Set to 60.
3162         * doc/invoke.texi (inline-unit-growth): Update docs.
3163
3164 2007-01-24  Jakub Jelinek  <jakub@redhat.com>
3165
3166         * config/i386/i386.h (x86_cmpxchg16b): Remove const.
3167         (TARGET_CMPXCHG16B): Define to x86_cmpxchg16b.
3168         * config/i386/i386.c (x86_cmpxchg16b): Remove const.
3169         (override_options): Add PTA_CX16 flag.  Set x86_cmpxchg16b
3170         for CPUs that have PTA_CX16 set.
3171
3172         PR middle-end/27416
3173         * gimplify.c (omp_check_private): New function.
3174         (gimplify_scan_omp_clauses): Use it for
3175         firstprivate/lastprivate/reduction.
3176
3177         PR middle-end/30494
3178         * gimplify.c (omp_add_variable): Don't call omp_notice_variable
3179         on TYPE_SIZE_UNIT for GOVD_LOCAL VLAs.
3180
3181         PR middle-end/30421
3182         * omp-low.c (lower_omp_for_lastprivate): Add dlist argument.
3183         If lower_lastprivate_clauses emits some statements, append them
3184         to dlist rather than body_p and to body_p append an initializer.
3185         (lower_omp_for): Adjust caller.
3186
3187 2007-01-24  Steve Ellcey  <sje@cup.hp.com>
3188
3189         * target.h (globalize_decl_name): New.
3190         * target-def.h (TARGET_ASM_GLOBALIZE_DECL_NAME): New.
3191         * output.h (default_globalize_decl_name): New.
3192         * varasm.c (asm_output_bss): Use globalize_decl_name instead of
3193         globalize_label.
3194         (globalize_decl): Ditto.
3195         (default_globalize_decl_name): New.
3196         * config/ia64/ia64.c (ia64_globalize_decl_name): New.
3197         (ia64_handle_version_id_attribute): New.
3198         (TARGET_ASM_GLOBALIZE_DECL_NAME): New.
3199         (ia64_asm_output_external): Use globalize_decl_name instead
3200         of globalize_label.
3201         * doc/extend.texi (version_id): New pragma.
3202         * doc/tm.texi (ARGET_ASM_GLOBALIZE_DECL_NAME): New target hook.
3203
3204 2007-01-24  Andreas Krebbel  <krebbel1@de.ibm.com>
3205
3206         * unwind-dw2-fde.c (get_cie_encoding): Replaced _Unwind_Word with
3207         _uleb128_t and _Unwind_SWord with _sleb128_t.
3208         * unwind-dw2.c (extract_cie_info, execute_stack_op, execute_cfa_program,
3209         uw_frame_state_for, uw_update_context_1): Likewise.
3210         * unwind-c.c (parse_lsda_header, PERSONALITY_FUNCTION): Likewise.
3211         * unwind-pe.h (read_uleb128, read_sleb128,
3212         read_encoded_value_with_base): Likewise.
3213         * unwind-generic.h: Define _sleb128_t and _uleb128_t types.
3214
3215 2007-01-24  Richard Guenther  <rguenther@suse.de>
3216
3217         * builtins.c (expand_builtin_cexpi): Get the fndecl
3218         for cexp in the correct way.
3219
3220 2007-01-24  Jan Hubicka  <jh@suse.cz>
3221
3222         * tree-ssa-dce.c (eliminate_unnecesary_stmts): Remove dead LHS of calls.
3223
3224 2007-01-24  Andreas Krebbel  <krebbel1@de.ibm.com>
3225
3226         * c-cppbuiltin.c (builtin_define_type_sizeof): New function.
3227         (c_cpp_builtins): New builtin macros: __SIZEOF_INT__, __SIZEOF_LONG__,
3228         __SIZEOF_LONG_LONG__, __SIZEOF_SHORT__, __SIZEOF_POINTER__,
3229         __SIZEOF_FLOAT__, __SIZEOF_DOUBLE__, __SIZEOF_LONG_DOUBLE__,
3230         __SIZEOF_SIZE_T__, __SIZEOF_WCHAR_T__, __SIZEOF_WINT_T__ and
3231         __SIZEOF_PTRDIFF_T__.
3232         * doc/cpp.texi: Documentation for the new builtin macros added.
3233
3234 2007-01-24  Uros Bizjak  <ubizjak@gmail.com>
3235
3236         * config/i386/i386.md (tanxf2, tan<mode>2, atan<mode>2, log<mode>2,
3237         log10<mode>2, log2<mode>2, expxf2, exp10xf2, exp2xf2): Use op2
3238         instead of operands[2] to avoid access past the end of array.
3239
3240 2007-01-24  Richard Sandiford  <richard@codesourcery.com>
3241
3242         * reload1.c (emit_reload_insns): Pass the reload register
3243         for a non-spill output reload through forget_old_reloads_1.
3244
3245 2007-01-23  Joseph Myers  <joseph@codesourcery.com>
3246
3247         * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Define
3248         _SOFT_DOUBLE if doubles use software floating-point.
3249         * config/rs6000/libgcc-ppc-glibc.ver: Export additional long
3250         double functions if _SOFT_DOUBLE, not _SOFT_FLOAT.
3251         * config/rs6000/darwin-ldouble.c: Also compile functions for
3252         hard-float without FPRs.  Use fmsub function for all __NO_FPRS__
3253         cases.  Compile extra functions if _SOFT_DOUBLE, not _SOFT_FLOAT.
3254         * config/rs6000/linuxspe.h (SUBSUBTARGET_OVERRIDE_OPTIONS): Remove
3255         commented-out long double override.
3256         (CPP_LONGDOUBLE_DEFAULT_SPEC): Likewise.
3257         * config/rs6000/eabispe.h: Likewise.
3258         * config/rs6000/rs6000.c (rs6000_override_options): Don't override
3259         long double for non-SPE.
3260         (rs6000_handle_option): Likewise.
3261         (invalid_e500_subreg): Disallow more subregs involding DImode,
3262         DFmode, TImode or TFmode.
3263         (rs6000_legitimate_offset_address_p): Check TFmode offsets for
3264         E500 double.
3265         (legitimate_lo_sum_address_p): Also check for TFmode for E500
3266         double.
3267         (rs6000_legitimize_address): Also handle TFmode for E500 double.
3268         (rs6000_legitimize_reload_address): Also handle TFmode for E500
3269         double.
3270         (rs6000_legitimate_address): Also check for TFmode for E500
3271         double.
3272         (rs6000_emit_move): Use DFmode subregs of TFmode for E500 double.
3273         (spe_build_register_parallel): Handle TFmode and TCmode.
3274         (rs6000_spe_function_arg): Handle TFmode and TCmode for E500
3275         double.
3276         (function_arg): Handle TFmode and TCmode for E500 double.
3277         (rs6000_init_libfuncs): Initialize extra libfuncs for soft double
3278         in general.
3279         (print_operand): Handle TFmode and TImode for %y.
3280         (rs6000_generate_compare): Handle TFmode comparisons for E500
3281         double.
3282         (spe_func_has_64bit_regs_p): Check for TFmode for E500 double.
3283         (rs6000_function_value): Handle TFmode and TCmode for E500 double.
3284         (rs6000_libcall_value): Handle TFmode and TCmode for E500 double.
3285         * config/rs6000/rs6000.h (CANNOT_CHANGE_MODE_CLASS): Check for
3286         TFmode for E500 double.
3287         * config/rs6000/rs6000.md (FP): Allow TF for E500 double.
3288         (floatsidf2): Enable for E500 double.
3289         (movtf_softfloat): Use rs6000_nonimmediate_operand.
3290         (extenddftf2): Change to extenddftf2_fprs.
3291         (extenddftf2): Call gen_spe_extenddftf2 or gen_extenddftf2_fprs
3292         depending on TARGET_E500_DOUBLE.
3293         (extendsftf2): Enable for E500 double.
3294         (trunctfdf2): Enable for E500 double.
3295         (trunctfsf2): Change to trunctfsf2_fprs.
3296         (trunctfsf2): Call gen_spe_trunctfsf2 or gen_trunctfsf2_fprs
3297         depending on TARGET_E500_DOUBLE.
3298         (floatsitf2): Enable for E500 double.
3299         (fix_trunctfsi2): Change to fix_trunctfsi2_fprs.
3300         (fix_trunctfsi2): Call gen_spe_fix_trunctfsi2 or
3301         gen_fix_trunctfsi2_fprs depending on TARGET_E500_DOUBLE.
3302         (negtf2): Change to negtf2_internal.
3303         (negtf2): New expander.
3304         (abstf2): Enable for E500 double.  Call gen_spe_abstf2_tst,
3305         gen_spe_abstf2_cmp or gen_abstf2_internal depending on
3306         TARGET_E500_DOUBLE and flag_unsafe_math_optimizations.
3307         (movdi_internal32): Use rs6000_nonimmediate_operand.
3308         (unnamed splitter): Likewise.
3309         * config/rs6000/spe.md (CMPTFEQ_GPR, TSTTFEQ_GPR, CMPTFGT_GPR,
3310         TSTTFGT_GPR, CMPTFLT_GPR, TSTTFLT_GPR): New unspecs.
3311         (SPE64TF, DITI): New mode macros.
3312         (frob_df_di): Change to frob_<SPE64:mode>_<DITI:mode>; allow more
3313         modes.
3314         (frob_tf_ti): New.
3315         (frob_<mode>_di_2): New.
3316         (frob_tf_di_8_2): New.
3317         (frob_di_df): Change to frob_di_<mode>; allow more modes.
3318         (frob_ti_tf): New.
3319         (frob_di_df_2): Change to frob_<DITI:mode>_<SPE64:mode>_2; allow
3320         more modes.
3321         (frob_ti_<mode>_8_2): New.
3322         (frob_ti_tf_2): New.
3323         (mov_si<mode>_e500_subreg0, mov_si<mode>_e500_subreg0_2,
3324         mov_si<mode>_e500_subreg4, mov_si<mode>_e500_subreg4_2): Allow
3325         TFmode.
3326         (mov_sitf_e500_subreg8, mov_sitf_e500_subreg8_2,
3327         mov_sitf_e500_subreg12, mov_sitf_e500_subreg12_2): New.
3328         (spe_trunctfdf2_internal1, spe_trunctfsf2, spe_extenddftf2,
3329         spe_fix_trunctfsi2, spe_fix_trunctfsi2_internal,
3330         spe_negtf2_internal, spe_abstf2_cmp, spe_abstf2_tst): New.
3331         (cmptfeq_gpr, tsttfeq_gpr, cmptfgt_gpr, tsttfgt_gpr, cmptflt_gpr,
3332         tsttflt_gp): New.
3333
3334 2007-01-23  Ian Lance Taylor  <iant@google.com>
3335
3336         * Makefile.in (OBJS-common): Reformat, alphabetize, but put
3337         insn-*.o first.
3338         (OBJS-archive): Reformat, alphabetize.
3339         (OBJS): Change out_object_file to OBJS-md.
3340
3341 2007-01-23  Uros Bizjak  <ubizjak@gmail.com>
3342
3343         * config/i386/i386.md: Use REG_P, MEM_P, CONST_INT_P, LABEL_P,
3344         JUMP_P and CALL_P predicates where applicable.
3345         * config/i386/i386.c: Ditto.
3346         * config/i386/i386.md: Ditto.
3347         * config/i386/mmx.md: Ditto.
3348         * config/i386/predicates.md: Ditto.
3349
3350 2007-01-22  Andreas Schwab  <schwab@suse.de>
3351
3352         * config/m68k/m68k.h: Fix comment.
3353
3354 2007-01-22  Jan Hubicka  <jh@suse.cz>
3355
3356         * passes.c (init_optimization_passes): Do not rerun
3357         pass_early_warn_uninitialized.
3358
3359 2007-01-22  Richard Guenther  <rguenther@suse.de>
3360
3361         PR tree-optimization/30038
3362         * tree-ssa-math-opts.c (maybe_record_sincos): New static helper
3363         function.
3364         (execute_cse_sincos_1): Likewise.
3365         (execute_cse_sincos): Likewise.
3366         (gate_cse_sincos): Likewise.
3367         (pass_cse_sincos): New pass CSEing sin() and cos() calls using
3368         the cexpi() canonicalization of sincos().
3369         * tree-pass.h (pass_cse_sincos): Declare.
3370         * passes.c (init_optimization_passes): New pass pas_cse_sincos.
3371
3372 2007-01-21  Eric Botcazou  <ebotcazou@libertysurf.fr>
3373
3374         PR rtl-optimization/29329
3375         * combine.c (replaced_rhs_insn): Rename to i2mod.
3376         (replaced_rhs_value): Rename to i2mod_new_rhs.
3377         (i2mod_old_rhs): New global variable.
3378         (combine_instructions): Adjust for above change.  Save a copy of
3379         the old RHS into i2mod_old_rhs when the contents of a REG_EQUAL
3380         note are substituted in the second instruction.
3381         (distribute_notes) <REG_DEAD>: Adjust for above change.  Do not
3382         ditch the note if it pertains to the second eliminated register
3383         and this register is mentioned in i2mod_old_rhs.
3384
3385         Revert:
3386         2006-09-12  Eric Botcazou  <ebotcazou@libertysurf.fr>
3387
3388         * combine.c (distribute_notes) <REG_DEAD>: Do not consider SETs past
3389         the insn to which the note was originally attached.
3390
3391 2007-01-21  Jan Hubicka  <jh@suse.cz>
3392
3393         * ipa-inline.c (inlining_mode): Comment, move up.
3394         (cgraph_decide_inlining_incrementally): Do not perform inlining
3395         itself; fix handling of flattening of self recursive functions.
3396         (cgraph_find_cycles): Remove.
3397         (cgraph_flatten_node): Remove.
3398         (cgraph_decide_inlining): Use incremental inliner to handle flattening.
3399         (try_inline): New function.