aboutsummaryrefslogtreecommitdiff
path: root/gcc
AgeCommit message (Collapse)AuthorFilesLines
2005-02-24re PR middle-end/19953 (Special-case real + complex arithmetic operation ↵Richard Henderson6-19/+248
(-ffast-math)) PR middle-end/19953 * builtins.c (fold_builtin_complex_mul, fold_builtin_complex_div): New. (fold_builtin_1): Call them. * fold-const.c (fold_complex_mult_parts): Split out from ... (fold_complex_mult): ... here. Fix typo in both imaginary case. (fold_complex_div_parts, fold_complex_div): New. (fold): Use them. * tree.h (fold_complex_mult_parts, fold_complex_div_parts): Declare. From-SVN: r95511
2005-02-24tree-ssa-ccp.c (visit_assignment): Verify that result of VIEW_CONVERT_EXPR ↵Richard Kenner2-6/+15
is_gimple_min_invariant. * tree-ssa-ccp.c (visit_assignment): Verify that result of VIEW_CONVERT_EXPR is_gimple_min_invariant. From-SVN: r95510
2005-02-24print-tree.c (print_node_brief): Print LABEL_DECL_UID.Richard Kenner2-0/+21
* print-tree.c (print_node_brief): Print LABEL_DECL_UID. (print_node): Likewise. Print TYPE_SIZES_GIMPLIFIED. From-SVN: r95507
2005-02-24Unrevert previously reversed patch, adding this patch:Tobias Schlüter12-74/+108
* module.c (find_true_name): Deal with NULL module. From-SVN: r95506
2005-02-24* config/cris/cris.md ("umulhisi3", "umulqihi3", "mulsi3")Hans-Peter Nilsson2-7/+13
("mulqihi3", "mulhisi3", "mulsidi3", "umulsidi3"): Mark input operands as commutative in constraints. From-SVN: r95505
2005-02-24re PR treelang/19896 ([treelang] Static variables don't work)James A. Morrison7-0/+165
2005-02-24 James A. Morrison <phython@gcc.gnu.org> PR other/19896 * execute/execute.exp: New file. * execute/funccall.tree, execute/funccall-2.tree, execute/initial.tree, execute/main.tree, execute/static.tree: New tests. From-SVN: r95504
2005-02-24re PR treelang/19896 ([treelang] Static variables don't work)James A. Morrison2-10/+18
2005-02-24 James A. Morrison <phython@gcc.gnu.org> PR other/19896 * treetree.c (tree_code_create_variable): Initialize DECL_EXTERNAL, TREE_PUBLIC, and TREE_STATIC for var_decl to zero. Don't call rest_of_decl_compilation on static variables. (pushdecl): Put DECL_EXPRs into the current BIND_EXPR for automatic variables. From-SVN: r95503
2005-02-24re PR treelang/19897 ([treelang] External references don't work.)James A. Morrison5-0/+50
2005-02-24 James A. Morrison <phython@gcc.gnu.org> PR other/19897 * compile/exit.tree, compile/extref.tree, compile/function-1.tree, compile/syntax-1.tree: New tests. From-SVN: r95502
2005-02-24parse.y: (function_prototype): Accept EXTERNAL_REFERENCE_STORAGE.James A. Morrison4-64/+79
2005-02-24 James A. Morrison <phython@gcc.gnu.org> * parse.y: (function_prototype): Accept EXTERNAL_REFERENCE_STORAGE. Move function parameters check from ... (function): ...Here. Update call to tree_code_create_function_initial. (function_invocation): Use expressions_with_commas_opt instead of expressions_with_commas. (expressions_with_commas_opt): New rule. * treetree.c (tree_code_create_function_prototype): Create PARM_DECLs for function parameters. (tree_code_create_function_initial): Remove PARMS parameter. Don't create PARM_DECLs for function parameters. * treetree.h (tree_code_create_function_initial): Remove PARMS parameter. From-SVN: r95501
2005-02-24* tree-into-ssa.c: Re-organize internal functions.Diego Novillo2-712/+730
From-SVN: r95499
2005-02-24Revert yesterday's patch:Tobias Schlüter13-105/+83
2005-02-23 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de> * gfortran.h (gfc_component, gfc_actual_arglist, ... ... argument. Copy string instead of pointing to it. From-SVN: r95496
2005-02-24re PR middle-end/18902 (Naive (default) complex division algorithm)Richard Henderson6-4/+42
PR middle-end/18902 * c-opts.c (c_common_post_options): Set flag_complex_method to 2 for c99. * common.opt (fcx-limited-range): New. * opts.c (set_fast_math_flags): Set flag_cx_limited_range. * toplev.c (flag_complex_method): Initialize to 1. (process_options): Set flag_complex_method to 0 if flag_cx_limited_range. * doc/invoke.texi (-fcx-limited-range): New. From-SVN: r95493
2005-02-24re PR c++/19878 (ICE in import_export_decl)Mark Mitchell4-0/+20
PR c++/19878 * decl.c (grokvardecl): Set DECL_INTERFACE_KNOWN for declarations with internal linkage. PR c++/19878 * g++.dg/init/const2.C: New test. From-SVN: r95490
2005-02-24cse.c (delete_trivially_dead_insns): Speed up by using NEXT_INSN and ↵Kazu Hirata2-8/+13
PREV_INSN directly instead of next_real_insn... * cse.c (delete_trivially_dead_insns): Speed up by using NEXT_INSN and PREV_INSN directly instead of next_real_insn and prev_real_insn. From-SVN: r95488
2005-02-24m68k.c (m68k_save_reg): Also save A5 for non-leaf functions when ↵Andrea Tarani2-3/+12
-mid-shared-library is being used. * config/m68k/m68k.c (m68k_save_reg): Also save A5 for non-leaf functions when -mid-shared-library is being used. From-SVN: r95487
2005-02-24Daily bump.GCC Administrator1-1/+1
From-SVN: r95481
2005-02-23tm.texi (LINK_LIBGCC_SPECIAL): Remove.Daniel Jacobowitz4-19/+12
* doc/tm.texi (LINK_LIBGCC_SPECIAL): Remove. (LINK_LIBGCC_SPECIAL_1): Don't mention it. * gcc.c: Don't check for LINK_LIBGCC_SPECIAL. * system.h: Poison LINK_LIBGCC_SPECIAL. From-SVN: r95476
2005-02-23re PR tree-optimization/20100 (LIM is pulling out a pure function even ↵Hans-Peter Nilsson2-0/+81
though there is something which can modify global memory) PR tree-optimization/20100 * gcc.c-torture/execute/pr20100-1.c: New test. From-SVN: r95474
2005-02-23Fix out-of-bounds array access found by mudflap.James E Wilson2-1/+7
* gengtype.c (note_insn_name): Make 1 element larger. From-SVN: r95473
2005-02-23gfortran.h (gfc_component, [...]): Make 'name' a 'const char *'.Tobias Schlüter13-74/+167
* gfortran.h (gfc_component, gfc_actual_arglist, gfc_user_op): Make 'name' a 'const char *'. (gfc_symbol): Likewise, also for 'module'. (gfc_symtree): Make 'name' a 'const char *'. (gfc_intrinsic_sym): Likewise, also for 'lib_name'. (gfc_get_gsymbol, gfc_find_gsymbol): Add 'const' qualifier to 'char *' argument. (gfc_intrinsic_symbol): Use 'gfc_get_string' instead of 'strcpy' to initialize 'SYM->module'. * check.c (gfc_check_minloc_maxloc, check_reduction): Check for NULL pointer instead of empty string. * dump-parse-tree.c (gfc_show_actual_arglist): Likewise. * interface.c (gfc_compare_types): Adapt check to account for possible NULL pointer. (compare_actual_formal): Check for NULL pointer instead of empty string. * intrinsic.c (gfc_current_intrinsic, gfc_current_intrinsic_arg): Add 'const' qualifier. (conv_name): Return a heap allocated string. (find_conv): Add 'const' qualifier to 'target'. (add_sym): Use 'gfc_get_string' instead of 'strcpy'. (make_generic): Check for NULL pointer instead of emptystring. (make_alias): Use 'gfc_get_string' instead of 'strcpy'. (add_conv): No need to strcpy result from 'conv_name'. (sort_actual): Check for NULL pointer instead of emptystring. * intrinsic.h (gfc_current_intrinsic, gfc_current_intrinsic_arg): Adapt prototype. * module.c (compare_true_names): Compare pointers instead of strings for 'module' member. (find_true_name): Initialize string fields with gfc_get_string. (mio_pool_string): New function. (mio_internal_string): Adapt comment. (mio_component_ref, mio_component, mio_actual_arg): Use 'mio_pool_string' instead of 'mio_internal_string'. (mio_symbol_interface): Add 'const' qualifier to string arguments. Add level of indirection. Use 'mio_pool_string' instead of 'mio_internal_string'. (load_needed, read_module): Use 'gfc_get_string' instead of 'strcpy'. (write_common, write_symbol): Use 'mio_pool_string' instead of 'mio_internal_string'. (write_symbol0, write_symbol1): Likewise, also check for NULL pointer instead of empty string. (write_operator, write_generic): Pass correct type variable to 'mio_symbol_interface'. (write_symtree): Use 'mio_pool_string' instead of 'mio_internal_string'. * primary.c (match_keyword_arg): Adapt check to possible case of NULL pointer. Use 'gfc_get_string' instead of 'strcpy'. * symbol.c (gfc_add_component, gfc_new_symtree, delete_symtree, gfc_get_uop, gfc_new_symbol): Use 'gfc_get_string' instead of 'strcpy'. (ambiguous_symbol): Check for NULL pointer instead of empty string. (gfc_find_gsymbol, gfc_get_gsymbol): Add 'const' qualifier on string arguments. * trans-array.c (gfc_trans_auto_array_allocation): Check for NULL pointer instead of empty string. * trans-decl.c (gfc_sym_mangled_identifier, gfc_sym_mangled_function_id, gfc_finish_var_decl, gfc_get_symbol_decl, gfc_get_symbol_decl): Likewise. * trans-io.c (gfc_new_nml_name_expr): Add 'const' qualifier to argument. Copy string instead of pointing to it. From-SVN: r95472
2005-02-23gfortran.h (gfc_expr): Move 'operator'...Tobias Schlüter13-136/+168
* gfortran.h (gfc_expr): Move 'operator', 'op1', 'op2', and 'uop' fields into new struct 'op' inside the 'value' union. * arith.c (eval_intrinsic): Adapt all users. * dependency.c (gfc_check_dependency): Likewise. * dump-parse-tree.c (gfc_show_expr): Likewise. * expr.c (gfc_get_expr): Don't clear removed fields. (free_expr0, gfc_copy_expr, gfc_type_convert_binary, gfc_is_constant_expr, simplify_intrinsic_op, check_init_expr, check_intrinsic_op): Adapt to new field names. * interface.c (gfc_extend_expr): Likewise. Also explicitly nullify 'esym' and 'isym' fields of new function call. * iresolve.c (gfc_resolve_dot_product, gfc_resolve_matmul): Adapt to renamed structure fields. * matchexp.c (build_node, match_level_1, match_expr): Likewise. * module.c (mio_expr): Likewise. * resolve.c (resolve_operator): Likewise. (gfc_find_forall_index): Likewise. Only look through operands if dealing with EXPR_OP * trans-array.c (gfc_walk_op_expr): Adapt to renamed fields. * trans-expr.c (gfc_conv_unary_op, gfc_conv_power_op, gfc_conv_concat_op, gfc_conv_expr_op): Likewise. From-SVN: r95471
2005-02-23gfortran.h (symbol_attribute): New 'untyped' field, fix comment formatting.Tobias Schlüter5-4/+21
fortran/ * gfortran.h (symbol_attribute): New 'untyped' field, fix comment formatting. * symbol.c (gfc_set_default_type): Issue error only once, by setting and checking 'untyped' attribute. testsuite/ * gfortran.dg/deftype_1.f90: New test. From-SVN: r95469
2005-02-23gfortran.h (gfc_get_namespace): Add second argument to prototype.Tobias Schlüter9-11/+41
fortran/ * gfortran.h (gfc_get_namespace): Add second argument to prototype. * intrinsic.c (gfc_intrinsic_init_1): Pass second argument to gfc_get_namespace. * module.c (mio_namespace_ref, load_needed): Likewise. * parse.c (parse_interface, parse_contained): Likewise. Here the correct second argument matters. * symbol.c (gfc_get_namespace): Add parent_types argument, only copy parent's implicit types if this is set. (gfc_symbol_init_2): Pass second argument to gfc_get_namespace. * trans-common.c (build_common_decl): Likewise. testsuite/ * gfortran.dg/implicit_3.f90: New test. From-SVN: r95463
2005-02-23decl.c (grokvardecl): Don't exempt anonymous types from having linkage for ↵Alexandre Oliva5-20/+26
variables that have... gcc/cp/ChangeLog: * decl.c (grokvardecl): Don't exempt anonymous types from having linkage for variables that have linkage other than "C". gcc/testsuite/ChangeLog: * g++.dg/lookup/anon2.C: Don't let access checks make it look like the test passes. * g++.dg/other/anon3.C: Accept a warning. From-SVN: r95462
2005-02-23re PR target/20018 ([ia64] unable to find a register to spill in class`PR_REG')Roger Sayle2-0/+9
PR target/20018 PR rtl-optimization/20097 * simplify-rtx.c (simplify_relational_operation_1): Avoid creating BImode SUBREGs of SImode registers which confuse the ia64 backend. From-SVN: r95461
2005-02-23t-aix43 (SHLIB_INSTALL): Create directory for shared library.David Edelsohn3-2/+11
* t-aix43 (SHLIB_INSTALL): Create directory for shared library. * t-aix52 (SHLIB_INSTALL): Same. From-SVN: r95460
2005-02-23re PR libgcj/16923 (-D* Options passed to JNI_CreateJavaVM are ignored)Thomas Fitzsimmons2-5/+41
2005-02-23 Thomas Fitzsimmons <fitzsim@redhat.com> PR libgcj/16923 * gcj.texi (Invocation): Add descriptions of JvVMInitArgs and JvVMOption. 2005-02-23 Thomas Fitzsimmons <fitzsim@redhat.com> PR libgcj/16923 * jni.cc (JNI_CreateJavaVM): Check JNI version. Cast args to JvVMInitArgs. Pass args to _Jv_CreateJavaVM and check return value. Move argument parsing code to prims.cc. * prims.cc (no_properties): Remove. (_Jv_Compiler_Properties): Initialize to NULL. (_Jv_Properties_Count): Initialize to 0. (parse_verbose_args): New function. (parse_init_args): New function. (_Jv_CreateJavaVM): Call parse_init_args. (_Jv_RunMain): Check return value of _Jv_CreateJavaVM. * gcj/cni.h (JvVMOption): New struct. (JvVMInitArgs): Likewise. (JvCreateJavaVM): Declare vm_args as JvVMInitArgs* rather than void*. * libjava/gcj/javaprims.h (_Jv_VMOption): New struct. (_Jv_VMInitArgs): Likewise. * include/java-props.h (_Jv_Properties_Count): Declare. * java/lang/natRuntime.cc (insertSystemProperties): Use _Jv_Properties_Count in for loop exit condition. * testsuite/libjava.jni/jni.exp (gcj_invocation_compile_c_to_binary): New procedure. (gcj_invocation_test_one): Likewise. (gcj_jni_run): Run JNI invocation API tests. * testsuite/libjava.jni/invocation/PR16923.c, testsuite/libjava.jni/invocation/PR16923.java, testsuite/libjava.jni/invocation/PR16923.out: New test. From-SVN: r95459
2005-02-23genpreds.c: Update copyright.Kazu Hirata10-6/+23
gcc/ * genpreds.c: Update copyright. cp/ * cp-objcp-common.h, error.c: Update copyright. fortran/ * intrinsic.h, st.c: Update copyright. treelang/ * parse.y: Update copyright. From-SVN: r95457
2005-02-23* gcc.dg/pr20017.c: Fix a comment typo.Kazu Hirata2-1/+5
From-SVN: r95456
2005-02-23re PR target/20159 (sol2-ci.asm not correctly assembled)Michael Beach2-2/+7
PR target/20159 * config/sparc/t-elf (startup files): Assemble with CPP. From-SVN: r95450
2005-02-23list_read_4.f90: Change to f90 comments.Bud Davis2-12/+16
2005-02-23 Bud Davis <bdavis@gfortran.org> * gfortran.dg/list_read_4.f90: Change to f90 comments. From-SVN: r95449
2005-02-23genpreds.c (mark_mode_tests): Handle non-VOIDmode match_operands.Paolo Bonzini2-2/+10
2005-02-23 Paolo Bonzini <bonzini@gnu.org> * genpreds.c (mark_mode_tests): Handle non-VOIDmode match_operands. (write_predicate_expr): Likewise. From-SVN: r95447
2005-02-23re PR ada/19902 (ACATS cxa3004 cxb3006 fail at compile time "ambiguous ↵Eric Botcazou3-639/+6
expression") PR ada/19902 * ada/acats/tests/cxa/cxa3004.a: Remove. * ada/acats/tests/cxb/cxb30061.am: Likewise. From-SVN: r95446
2005-02-23re PR c++/20073 (ICE initializing const array)Mark Mitchell1-0/+7
PR c++/20073 * decl.c (start_decl_1): Don't clear TREE_READONLY. (cp_finish_decl): Likewise. (complete_vars): Call cp_apply_type_quals_to_decl. * typeck.c (cp_apply_type_quals): Avoid setting TREE_READONLY in cases where that's not valid. From-SVN: r95442
2005-02-23re PR c++/20073 (ICE initializing const array)Mark Mitchell4-27/+31
PR c++/20073 * decl.c (start_decl_1): Don't clear TREE_READONLY. (cp_finish_decl): Likewise. (complete_vars): Call cp_apply_type_quals_to_decl. * typeck.c (cp_apply_type_quals): Avoid setting TREE_READONLY in cases where that's not valid. PR c++/20073 * g++.dg/init/const1.C: New test. From-SVN: r95441
2005-02-23re PR c++/19991 (Enum not accepted in array-size)Mark Mitchell13-48/+109
PR c++/19991 * init.c (integral_constant_value): Iterate if the value of a decl is itself a constant. PR c++/20152 * parser.c (cp_parser_class_head): Check for redefintions here. * semantics.c (begin_class_definition): Not here. PR c++/20153 * decl2.c (build_anon_union_vars): Add type parameter. (finish_anon_union): Pass it. PR c++/20148 * error.c (dump_expr): Do not print the body of a BIND_EXPR. Handle STATEMENT_LIST. PR c++/19991 * g++.dg/parse/constant7.C: New test. PR c++/20152 * g++.dg/parse/error27.C: New test. * g++.dg/template/qualttp15.C: Adjust error markers. * g++.old-deja/g++.other/struct1.C: Likewise. PR c++/20153 * g++.dg/template/error17.C: New test. PR c++/20148 * g++.dg/parser/error26.C: New test. From-SVN: r95438
2005-02-23re PR tree-optimization/20100 (LIM is pulling out a pure function even ↵Diego Novillo11-88/+193
though there is something which can modify global memory) PR tree-optimization/20100 PR tree-optimization/20115 * tree-optimize.c (init_tree_optimization_passes): Remove pass_maybe_create_global_var. * tree-pass.h (pass_maybe_create_global_var): Remove. * tree-ssa-alias.c (aliases_computed_p): Declare. (struct alias_info): Add field NUM_PURE_CONST_CALLS_FOUND. (count_calls_and_maybe_create_global_var): Remove. (pass_maybe_create_global_var): Remove. (init_alias_info): Do not declare aliases_computed_p. (maybe_create_global_var): If the function contains no call-clobbered variables and a mix of pure/const and regular function calls, create .GLOBAL_VAR. Mark all call-clobbered variables for renaming. (merge_pointed_to_info): Update comment. (add_pointed_to_var): Likewise. (is_escape_site): Likewise. Accept struct alias_info * instead of size_t *. Update all users. Update AI->NUM_CALLS_FOUND and AI->NUM_PURE_CONST_CALLS_FOUND as necessary. * tree-ssa-operands.c (get_call_expr_operands): If ALIASES_COMPUTED_P is false, do not add call-clobbering operands. * tree-ssa.c (init_tree_ssa): Set ALIASES_COMPUTED_P to false. (delete_tree_ssa): Likewise. testsuite/ChangeLog PR tree-optimization/20100 PR tree-optimization/20115 * gcc.dg/pr20115.c: New test. * gcc.dg/pr20115-1.c: New test. * gcc.dg/pr20100.c: New test. * gcc.dg/tree-ssa/20040517-1.c: Expect virtual operands for call-clobbered variables after alias1. From-SVN: r95437
2005-02-23[multiple changes]Bud Davis2-0/+58
2004-02-22 Paul Thomas <paulthomas2@wannado.fr> Bud Davis <bdavis@gfortran.org> * io/list_read.c (read_real): Handle separators properly in list directed read. 2005-02-22 Bud Davis <bdavis@gfortran.org> * gfortran.dg/list_read_4.f90: new test. From-SVN: r95436
2005-02-22Fix FreeBSD __LDBL_MAX__ -pedantic -save-temps bug.James E Wilson2-2/+10
* toplev.c (backend_init): Don't call init_adjust_machine_modes here. (do_compile): Do call it here. From-SVN: r95432
2005-02-23re PR rtl-optimization/20017 (internal compiler error: in ↵Kazu Hirata4-0/+59
rtl_verify_flow_info, at cfgrtl.c:2212) gcc/ PR rtl-optimization/20017. * passes.c (rest_of_handle_combine, rest_of_handle_cse, rest_of_handle_cse2, rest_of_handle_gcse): Call delete_dead_jumptables immediately before calling cleanup_cfg. testsuite/ PR rtl-optimization/20017. * gcc.dg/pr20017.c: New. From-SVN: r95431
2005-02-22re PR tree-optimization/19952 (ICE: tree check: expected class ↵Devang Patel4-1/+36
'declaration', have 'statement' (label_expr) in tree_verify_flow_info, at tree-cfg.c:3709) PR 19952 * tree-if-conv.c (process_phi_nodes): Use bsi_after_labels and skip all labels * g++.dg/tree-ssa/pr19952.C: New test. From-SVN: r95430
2005-02-23Daily bump.GCC Administrator1-1/+1
From-SVN: r95426
2005-02-22* config/rs6000/aix.h (WINT_TYPE): Define.David Edelsohn2-0/+7
From-SVN: r95421
2005-02-22rs6000.c (rs6000_override_options): Default to natural alignment for 64-bit ↵Stan Shebs3-2/+24
Darwin. * config/rs6000/rs6000.c (rs6000_override_options): Default to natural alignment for 64-bit Darwin. (rs6000_parse_alignment_option): Warn about uses of -malign-power on 64-bit Darwin. * doc/invoke.texi: Document this. From-SVN: r95420
2005-02-22parser.c (cp_parser_direct_declarator): Always complain about non-constant ↵Mark Mitchell5-14/+38
array bounds when in a function scope. * parser.c (cp_parser_direct_declarator): Always complain about non-constant array bounds when in a function scope. * semantics.c (finish_id_expression): Do not mark dependent names as non-constant. From-SVN: r95417
2005-02-22c-common.c (c_common_type_for_mode): Pass the mode's precision to ↵DJ Delorie2-2/+11
make_[un]signed_type, not the mode itself. * c-common.c (c_common_type_for_mode): Pass the mode's precision to make_[un]signed_type, not the mode itself. From-SVN: r95412
2005-02-22re PR java/20056 ('verification failed: incompatible type on stack' with ↵Tom Tromey2-17/+45
--indirect-dispatch) PR java/20056: * verify-impl.c (EITHER): New define. (types_compatible): Handle it. (check_field_constant): Use it. From-SVN: r95404
2005-02-22tree-outof-ssa.c (SSANORM_USE_COALESCE_LIST): Remove.Kazu Hirata2-49/+44
* tree-outof-ssa.c (SSANORM_USE_COALESCE_LIST): Remove. (coalesce_ssa_name): Don't check for SSANORM_USE_COALESCE_LIST. (rewrite_out_of_ssa): Don't use SSANORM_USE_COALESCE_LIST. From-SVN: r95397
2005-02-22cfg.c (cached_make_edge): Call make_edge if edge cache is not available.Kazu Hirata2-33/+34
* cfg.c (cached_make_edge): Call make_edge if edge cache is not available. Use tail calls wherever possible. (make_edge): Call unchecked_make_edge to create an edge. From-SVN: r95396
2005-02-22tree-into-ssa.c (rewrite_blocks): Move debug dumps from ...Diego Novillo2-7/+13
* tree-into-ssa.c (rewrite_blocks): Move debug dumps from ... (rewrite_into_ssa): ... here. From-SVN: r95395