Commit Graph

51701 Commits

Author SHA1 Message Date
Andrew Pinski
db2f435bea gcse.c (gcse_constant_p): COMPARE of the same registers is a constant if...
2003-05-02	Andrew Pinski <pinskia@physics.uc.edu>

	* gcse.c (gcse_constant_p): COMPARE of the same registers is a constant
	if they are not floating point registers.

From-SVN: r69471
2003-07-16 11:58:12 -07:00
Andrew Pinski
d07605f570 re PR c/10962 (lookup_field is a linear search on a linked list (can be slow if large struct))
2003-07-16  Andrew Pinski  <pinskia@physics.uc.edu>
ChangeLog:
        PR c/10962
        * ggc.h: Add header guards.
        * c-decl.c (finish_struct): Sort fields if
        number greater than 15 and there are no
        anonymous structs/unions.
        * c-common.h: Include ggc.h.
        (sorted_fields_type): New struct.
        (field_decl_cmp): New prototype.
        (resort_sorted_fields): New prototype.
        (DECL_DECLARES_TYPE_NON_TEMPLATE_P): New macro.
        * c-tree.h: (lang_type): Use pointer to sorted_fields_type
        as s, removing other fields.
        * c-typeck.c (lookup_field): Use s in lang_type.
        These were mostly moved from cp/class.c:
        * c-common.c (field_decl_cmp): New static function.
        (field_decl_cmp): New function.
        (resort_sorted_fields): New function.
cp/ChangeLog:
        * class.c (field_decl_cmp): Remove.
        (resort_field_decl_cmp): Remove.
        (resort_sorted_fields): Remove.
        (add_fields_to_vec): Rename to ...
        (add_fields_to_record_type): this.
        (finish_struct_1): Change to be using
        sorted_fields_type's fields.
        * cp-tree.h (lang_decl): In lang_decl_u3
        change sorted_fields to be a pointer to
        sorted_fields_type.
        (resort_sorted_fields): Remove prototype.
        * search.c (lookup_field_1): Change to be using
        sorted_fields_type's fields.

From-SVN: r69470
2003-07-16 11:45:56 -07:00
Andrew Pinski
48addf69eb re PR target/11008 (improper multiply optimization for pentium4)
2003-07-16  Andrew Pinski  <pinskia@physics.uc.edu>

        PR target/11008
        * gcc.dg/i386-pentium4-not-mull.c: New.

From-SVN: r69469
2003-07-16 11:23:32 -07:00
Geoffrey Keating
3d7964d5db darwin.c (machopic_select_section): Use decl_readonly_section to do most of the work.
* config/darwin.c (machopic_select_section): Use decl_readonly_section
	to do most of the work.

From-SVN: r69468
2003-07-16 18:18:00 +00:00
Andrew Pinski
e6a8c80375 MAINTAINERS: Move self from Bug database only accounts to write-after-approval.
2003-07-16  Andrew Pinski  <pinskia@physics.uc.edu>

        * MAINTAINERS: Move self from Bug database only accounts
        to write-after-approval.

From-SVN: r69467
2003-07-16 11:15:22 -07:00
Hans-Peter Nilsson
4e58524e8c mmix-protos.h: Convert prototypes to ISO C90.
* config/mmix/mmix-protos.h: Convert prototypes to ISO C90.
	* config/mmix/mmix.c: Convert functions to ISO C90.
  	(mmix_eh_return_handler_rtx, mmix_output_shifted_value): Tweak
	formatting.
	(mmix_get_hard_reg_initial_val): Tweak section head comment.

From-SVN: r69466
2003-07-16 17:44:59 +00:00
Jonathan Wakely
dced0d12fb howto.html: Update URL for SGI STL docs.
2003-07-16  Jonathan Wakely  <redi@gcc.gnu.org>

	* docs/html/ext/howto.html: Update URL for SGI STL docs.
	* docs/html/faq/index.html: Same.
	* docs/html/faq/index.txt: Regenerate.

From-SVN: r69463
2003-07-16 18:06:36 +01:00
J"orn Rennecke
1e0343ddbb c-pragma.h (HANDLE_PRAGMA_WEAK): Always define to SUPPORTS_WEAK.
gcc:
	* c-pragma.h (HANDLE_PRAGMA_WEAK): Always define to SUPPORTS_WEAK.
gcc/testsuite:
	* gcc.dg/asm-names.c (ymain): Make it weak.

From-SVN: r69459
2003-07-16 17:25:15 +01:00
Paolo Carlini
e50344b919 re PR libstdc++/11528 (money_get does not get "$.00")
2003-07-16  Paolo Carlini  <pcarlini@unitus.it>

	PR libstdc++/11528
	* include/bits/locale_facets.tcc (money_get::do_get):
	Strip only _leading_ zeros.
	* testsuite/22_locale/money_get/get/char/11528.cc: Add.
	* testsuite/22_locale/money_get/get/wchar_t/11528.cc: Add.

From-SVN: r69458
2003-07-16 16:12:47 +00:00
Kriang Lerdsuwanakij
866eb556c2 re PR c++/5421 (friends+templates: ICE: expected identifier_node, have template_id_expr in grokfndecl, at cp/decl.c:8835)
PR c++/5421
	* decl.c (grokdeclarator): Handle TEMPLATE_ID_EXPR if friend
	is a member of other class.
	* friend.c (do_friend): Don't build TEMPLATE_DECL if friend
	is a specialization of function template.

	* g++.dg/template/friend21.C: New test.

From-SVN: r69457
2003-07-16 15:42:15 +00:00
Gerald Pfeifer
94b7906a3a hash_map (class hash_multimap): Remove extra semicolons from __glibcxx_class_requires3 entries.
* include/ext/hash_map (class hash_multimap): Remove extra
	semicolons from __glibcxx_class_requires3 entries.
	* include/ext/hash_set (class hash_set): Ditto.
	(class hash_multiset): Ditto.

From-SVN: r69451
2003-07-16 14:23:08 +00:00
Jakub Jelinek
fc4767bbb6 unwind-dw2.c (MD_FROB_UPDATE_CONTEXT): Define.
* unwind-dw2.c (MD_FROB_UPDATE_CONTEXT): Define.
	(uw_update_context_1): Use it.
	* config/rs6000/rs6000.c (insn_after_throw): Remove.
	(rs6000_aix_emit_builtin_unwind_init): Save $r2 to its location
	in parent frame if _Unwind_* called directly instead of through
	.plt.
	(rs6000_emit_eh_toc_restore): Remove.
	(rs6000_emit_prologue): Update stack pointer before doing any saving
	if current_function_calls_eh_return.  Generate unwind info for $r2.
	(rs6000_emit_epilogue): Restore stack pointer after doing all
	restoring if current_function_calls_eh_return.  Restore $r2.
	* config/rs6000/rs6000-protos.h (rs6000_emit_eh_toc_restore): Remove.
	* config/rs6000/rs6000.md (eh_return): Remove call to
	rs6000_emit_eh_toc_restore.
	* config/rs6000/linux64.h (MD_FROB_UPDATE_CONTEXT): Define.
	* config/rs6000/aix.h (MD_FROB_UPDATE_CONTEXT): Define.

	* gcc.dg/cleanup-8.c: New test.
	* gcc.dg/cleanup-9.c: New test.

From-SVN: r69450
2003-07-16 13:52:55 +02:00
Jakub Jelinek
6972c506d4 expr.c (emit_block_move): Don't move anything if size is const 0.
* expr.c (emit_block_move): Don't move anything if size is const 0.
	(clear_storage): Test against const0_rtx instead of comparing INTVAL
	against 0.

From-SVN: r69441
2003-07-16 13:07:54 +02:00
David S. Miller
ac59ed379b sparc.c (sparc_nonflat_function_epilogue): Only emit nop if the last real insn is CALL_INSN.
2003-07-15  David S. Miller  <davem@redhat.com>

	* config/sparc/sparc.c (sparc_nonflat_function_epilogue): Only
	emit nop if the last real insn is CALL_INSN.

From-SVN: r69440
2003-07-16 01:36:27 -07:00
Nathanael Nerode
9f13608f62 * config.if: Remove unused libc_interface determination.
From-SVN: r69439
2003-07-16 06:34:53 +00:00
Gabriel Dos Reis
c61dce3a81 re PR c++/10903 ([3.3 only] g++ says: "error: object ``type_decl' not supported by dump_expr")
PR c++/10903
        * pt.c (convert_nontype_argument): Fix thinko in diagnostic.
        Improve.

From-SVN: r69435
2003-07-16 01:43:26 +00:00
Danny Smith
b828d12414 xm-mingw32.h (HOST_BIT_BUCKET): Define as "nul".
* config/i386/xm-mingw32.h (HOST_BIT_BUCKET): Define
	as "nul".
	* config/i386/xm-mingw32.h: Change GNU CC to GCC.

From-SVN: r69434
2003-07-16 01:27:03 +00:00
Danny Smith
32f2f2cba9 dll-MI1.h: New file.
* g++.dg/ext/dll-MI1.h: New file.
	* g++.dg/ext/dllexport-MI1.C: New file.
	* g++.dg/ext/dllimport-MI1.C: New file.

	ChangeLog: Remove 'testsuite/' from 2003-07-04 entry.

From-SVN: r69432
2003-07-16 01:12:19 +00:00
Danny Smith
d5648e1233 winnt.c (associated_type): Artificial methods are not affected by the import/export status of their class...
* config/i386/winnt.c (associated_type): Artificial methods are not
	affected by the import/export status of their class unless they are
	COMDAT.
	(i386_pe_dllimport_p): Do not mark artificial methods as dllimport.

	* config/i386/winnt.c: Fix GCC copyright comment.

From-SVN: r69431
2003-07-16 01:04:10 +00:00
GCC Administrator
e27668301c Daily bump.
From-SVN: r69429
2003-07-16 00:16:08 +00:00
Mark Mitchell
10b1d5e751 cp-tree.def (LOOKUP_EXPR): Remove.
* cp-tree.def (LOOKUP_EXPR): Remove.
	* cp-tree.h (cp_id_kind): Add CP_ID_KIND_UNQUALIFIED_DEPENDENT.
	(LOOKUP_EXPR_GLOBAL): Remove.
	(get_bindings): Remove.
	(is_aggr_type_2): Remove.
	* call.c (resolved_scoped_fn_name): Remove support for
	LOOKUP_EXPR.
	* decl.c (grokfndecl): Likewise.
	(grokdeclarator): Likewise.
	* error.c (dump_decl): Likewise.
	(dump_expr): Likewise.
	* friend.c (do_friend): Likewise.
	* init.c (build_offset_ref): Likewise.
	* lex.c (unqualified_fn_lookup_error): Use pedwarn.  Do not create
	LOOKUP_EXPRs
	* mangle.c (write_expression): Remove support for LOOKUP_EXPR.
	* parser.c (cp_parser_postfix_expression): Modify Koenig lookup
	test.
	* pt.c (get_bindings): Give it internal linkage.
	(check_explicit_specialization): Remove support for LOOKUP_EXPR.
	(lookup_template_function): Likewise.
	(for_each_tempalte_parm_r): Likewise.
	(tsubst_decl): Likewise.
	(tsubst_qualified_id): Handle template template parameters.
	(tsubst_copy): Remove support for LOOKUP_EXPR.
	(tsubst_copy_and_build): Likewise.
	(most_general_template): Likewise.
	(value_dependent_expression_p): Likewise.
	(type_dependent_expression_p): Note that IDENTIFIER_NODEs are
	always dependent.
	* semantics.c (perform_koenig_lookup): Do not create
	IDENTIFIER_NODEs.
	(finish_fname): Likewise.
	(finish_id_expression): Likewise.
	* tree.c (is_aggr_type_2): Remove.

From-SVN: r69427
2003-07-16 00:09:45 +00:00
Gabriel Dos Reis
b0e3f7ec30 re PR c++/11531 (ICE on invalid code (returning to void))
PR c++/11531
        * diagnostic.c (diagnostic_report_diagnostic): Don't ICE if we're
        not recursing on hard error.
        (diagnostic_for_decl): Likewise.
        * diagnostic.def: Rearrange.

cp/
        * typeck.c (check_return_expr): Fix thinko in diagnostic.

From-SVN: r69425
2003-07-15 23:31:52 +00:00
J"orn Rennecke
71628aa098 dwarf2out.c (expand_builtin_init_dwarf_reg_sizes): If DWARF_FRAME_RETURN_COLUMN doesn't have a register mode, use Pmode.
2003-07-15  J"orn Rennecke <joern.rennecke@superh.com>

	* dwarf2out.c (expand_builtin_init_dwarf_reg_sizes):
	If DWARF_FRAME_RETURN_COLUMN doesn't have a register mode, use Pmode.

2003-07-15  J"orn Rennecke <joern.rennecke@superh.com>
	    Richard Henderson  <rth@redhat.com>

	* unwind-dw2.c (_Unwind_GetGR): Use dwarf_reg_size_table
	to decide if to access a _Unwind_Ptr or a _Unwind_Word.
	(_Unwind_SetGR): Likewise.
	(_Unwind_GetPtr, _Unwind_SetSpColumn): New functions.
	(Unwind_SpTmp): New typedef.
	(uw_update_context_1): Use _Unwind_SetSpColumn and _Unwind_GetPtr.
	(uw_update_context): Use _Unwind_GetPtr.
	(init_dwarf_reg_size_table): Move above uw_init_context_1.
	(uw_init_context_1): Initialize dwarf_reg_size_table if necessary.
	Use _Unwind_SetSpColumn.
	(uw_install_context_1): Don't initialize dwarf_reg_size_table.
	Use _Unwind_GetPtr.

Co-Authored-By: Richard Henderson <rth@redhat.com>

From-SVN: r69424
2003-07-15 23:49:07 +01:00
Neil Booth
5a170a05da c.opt: Document more options.
* c.opt: Document more options.
	* toplev.c (documented_lang_options): Remove all local help strings.
treelang:
	* lang-options.h: Remove.
	* lang.opt: Document some options.  Remove --help.
	* tree1.c (treelang_handle_option): Remove OPT__help case.

From-SVN: r69423
2003-07-15 22:19:44 +00:00
Jakub Jelinek
bc8229a050 string-opt-8.c (main): Remove i370 and s390, it does not have cmpstrsi patterns (just cmpmemsi).
* gcc.c-torture/execute/string-opt-8.c (main): Remove i370 and s390,
	it does not have cmpstrsi patterns (just cmpmemsi).

From-SVN: r69422
2003-07-15 23:26:36 +02:00
Petur Runolfsson
73a530bdcc char_traits.h (char_traits<wchar_t>::move): Change last parameter from int_type to size_t.
2003-07-15  Petur Runolfsson  <peturr02@ru.is>

	* include/bits/char_traits.h (char_traits<wchar_t>::move):
	Change last parameter from int_type to size_t.

From-SVN: r69415
2003-07-15 17:30:10 +00:00
Mark Mitchell
b0afa2fca4 re PR debug/11473 (ICE with -gstabs when empty struct inheits from an empty struct)
PR debug/11473
	* dbxout.c (dbxout_type): Use TYPE_SIZE to determine the sizes of
	base classes.

	PR debug/11473
	* g++.dg/debug/debug8.C: New test.

From-SVN: r69414
2003-07-15 16:56:49 +00:00
Kazu Hirata
2a868facf5 Rotate ChangeLog.
From-SVN: r69411
2003-07-15 16:06:59 +00:00
Kriang Lerdsuwanakij
caec1dc059 re PR c++/10108 (tree checking ICE: expected var_decl, have error_mark in tsubst_decl)
PR c++/10108
	* pt.c (tsubst_decl) <TEMPLATE_DECL>: Add a check for
	error_mark_node.

	* g++.dg/template/crash7.C: New test.

From-SVN: r69409
2003-07-15 15:28:38 +00:00
Kazu Hirata
aadf50ed06 re PR target/10795 (ICE in extract_insn, at recog.c:2188)
PR target/10795
	* gcc.c-torture/compile/20030708-1.c: New.

From-SVN: r69408
2003-07-15 13:44:50 +00:00
Kazu Hirata
5df90541c7 re PR target/10795 (ICE in extract_insn, at recog.c:2188)
PR target/10795
	* config/i386/i386.c (ix86_expand_carry_flag_compare): Don't
	swap comparison operands if doing so would generate an
	unrecognizable insn.

From-SVN: r69407
2003-07-15 13:42:39 +00:00
Eric Botcazou
b5524f9497 Fix formatting.
From-SVN: r69404
2003-07-15 13:12:18 +00:00
Eric Botcazou
5a257872da re PR rtl-optimization/11320 (Scheduler bug)
PR optimization/11320
	* sched-int.h (struct deps) [reg_conditional_sets]: New field.
	(struct sched_info) [compute_jump_reg_dependencies]: New prototype.
	* sched-deps.c (sched_analyze_insn) [JUMP_INSN]: Update call to
	current_sched_info->compute_jump_reg_dependencies. Record which
	registers are used and which registers are set by the jump.
	Clear deps->reg_conditional_sets after a barrier.
	Set deps->reg_conditional_sets if the insn is a COND_EXEC.
	Clear deps->reg_conditional_sets if the insn is not a COND_EXEC.
	(init_deps): Initialize reg_conditional_sets.
	(free_deps): Clear reg_conditional_sets.
	* sched-ebb.c (compute_jump_reg_dependencies): New prototype.
	Mark registers live on entry of the fallthrough block and conditionally
	set as set by the jump. Mark registers live on entry of non-fallthrough
	blocks as used by the jump.
	* sched-rgn.c (compute_jump_reg_dependencies): New prototype.
	Mark new parameters as unused.

From-SVN: r69401
2003-07-15 13:02:21 +00:00
Matt Kraai
9fa0903819 * texi2pod.pl: Default @itemize's parameter to @bullet.
From-SVN: r69399
2003-07-15 09:24:07 +00:00
Richard Sandiford
3cec3f8307 * doc/invoke.texi: Resync MIPS -march documentation.
From-SVN: r69398
2003-07-15 08:58:33 +00:00
Richard Sandiford
98450f0d22 mips.h (PROCESSOR_R9000): New processor_type.
* config/mips/mips.h (PROCESSOR_R9000): New processor_type.
	(TARGET_MIPS9000, TUNE_MIPS9000): New macros.
	(GENERATE_MULT3_SI): True for TARGET_MIPS9000.
	* config/mips/mips.c (mips_cpu_info_table): Add rm9000 entry.
	(mips_rtx_costs): Adjust integer multiplication costs for the rm9000.
	(mips_issue_rate): Handle PROCESSOR_R9000.
	(mips_use_dfa_pipeline_interface): Likewise.
	* config/mips/9000.md: New file.
	* config/mips/mips.md: Include it.
	(define_attr cpu): Add r9000.
	(mulsi3_mult3): Use "mul" for rm9000 code.

From-SVN: r69397
2003-07-15 08:44:26 +00:00
Stan Cox
5fe25f470b mips.h (PROCESSOR_R7000): New processor_type.
* config/mips/mips.h (PROCESSOR_R7000): New processor_type.
	(TARGET_MIPS7000, TUNE_MIPS7000): New macros.
	(GENERATE_MULT3_SI): True for TARGET_MIPS7000.
	* config/mips/mips.c (mips_cpu_info_table): Add rm7000 entry.
	(mips_rtx_costs): Adjust integer multiplication costs for the rm7000.
	(mips_issue_rate): Handle PROCESSOR_R7000.
	(mips_use_dfa_pipeline_interface): Likewise.
	* config/mips/7000.md: New file.
	* config/mips/mips.md: Include it.
	(define_attr cpu): Add r7000.
	(mulsi3_mult3): Use "mul" for rm7000 code.

From-SVN: r69394
2003-07-15 08:34:54 +00:00
Richard Sandiford
5a2515e667 mips.md (define_attr type): Add condmove.
* config/mips/mips.md (define_attr type): Add condmove.  Use it for
	the conditional move patterns.
	* config/mips/5400.md (ir_vr54_move): Rename to ir_vr54_condmove.
	Check for condmove type.
	(ir_vr54_arith): Add move type.
	* config/mips/5500.md (ir_vr55_move, ir_vr55_arith): Likewise.
	* config/mips/sr71k.md (ir_sr70_move, ir_sr70_arith): Likewise.

From-SVN: r69389
2003-07-15 08:16:44 +00:00
Jerry Quinn
119dbb1fce stl_algo.h (includes, [...]): Document.
2003-07-15  Jerry Quinn  <jlquinn@optonline.net>

	* include/bits/stl_algo.h (includes, set_union, set_intersection,
        set_difference, set_symmetric_difference, max_element, min_element,
        next_permutation, prev_permutation, find_first_of, find_end):
        Document.
	* include/bits/stl_algobase.h (copy,copy_backward):  Clarify overlap
        restrictions in docs.
	* include/bits/stl_heap.h (push_heap, pop_heap, make_heap, sort_heap):
        Document.
	* docs/doxygen/doxygroups.cc (setoperations):  New group.

From-SVN: r69387
2003-07-15 07:30:29 +00:00
Jerry Quinn
284f19bf17 basic_string.h: Document public functions.
2003-07-15  Jerry Quinn  <jlquinn@optonline.net>

        * include/bits/basic_string.h:  Document public functions.
	* docs/doxygen/TODO:  Update c21 todo.

From-SVN: r69386
2003-07-15 07:02:40 +00:00
Jerry Quinn
709e7c9f87 stl_list.h: Document more functions.
2003-07-15  Jerry Quinn  <jlquinn@optonline.net>

        *  include/bits/stl_list.h:  Document more functions.
	* docs/doxygen/TODO:  Update c23 todo.

From-SVN: r69385
2003-07-15 06:15:57 +00:00
Neil Booth
72de27eaff c-opts.c (print_help): Remove.
* c-opts.c (print_help): Remove.
	(c_common_handle_option): Don't handle --help.
	* c.opt: Document some options.
	(--help): Remove.
	* opts.c (print_filtered_help): New.
	(print_help): Use it.

From-SVN: r69383
2003-07-15 05:48:16 +00:00
Geoffrey Keating
2d799c0954 c-common.c (c_common_type_for_mode): Handle V4DFmode.
* c-common.c (c_common_type_for_mode): Handle V4DFmode.
	* tree.c: (build_common_tree_nodes_2): Likewise.
	* tree.h (enum tree_index): Add TI_V4DF_TYPE.
	(V4DF_type_node): New.

From-SVN: r69382
2003-07-15 05:44:30 +00:00
Geoffrey Keating
e6ebd07b9d c-opts.c (push_command_line_include): Don't free deferred_opts, we'll need it.
* c-opts.c (push_command_line_include): Don't free deferred_opts,
	we'll need it.
	(finish_options): Reset init_cursor.

From-SVN: r69381
2003-07-15 05:36:25 +00:00
Kazu Hirata
683b1112af * expr.c: Remove the last argument to expand_assignment().
From-SVN: r69380
2003-07-15 05:32:21 +00:00
Kazu Hirata
b90f141a9d expr.c (expand_assignment): Remove an unused argument SUGGEST_REG.
* expr.c (expand_assignment): Remove an unused argument
	SUGGEST_REG.
	* expr.h: Update the prototype.
	* function.c: Update the callers.
	* stmt.c: Likewise.

From-SVN: r69379
2003-07-15 05:31:44 +00:00
Geoffrey Keating
89a68bb98d inline-3.c: New file.
* gcc.dg/pch/inline-3.c: New file.
	* gcc.dg/pch/inline-3.hs: New file.
	* gcc.dg/pch/inline-4.c: New file.
	* gcc.dg/pch/inline-4.hs: New file.

From-SVN: r69378
2003-07-15 05:21:37 +00:00
Mark Mitchell
1e7ee6ad1f re PR debug/11098 ([dwarf2] g++ doesn't emit complete debugging information for local variables in destructors)
PR debug/11098
	* integrate.c (copy_decl_for_inlining): Do not mark copied decls
	as DECL_ABSTRACT.

From-SVN: r69374
2003-07-15 01:04:21 +00:00
Nathanael Nerode
bf66f7b007 inclhack.def (avoid_bool_define, [...]): Bypass with __cplusplus, not "we must use the C++ compiler's type"
* fixinc/inclhack.def (avoid_bool_define, avoid_bool_type): Bypass
	with __cplusplus, not "we must use the C++ compiler's type"
	* fixinc/inclhack.def (void_null): Note that Interix needs this.
	* fixinc/fixincl.x: Regenerate.

From-SVN: r69373
2003-07-15 00:43:24 +00:00
GCC Administrator
b9ce931dbe Daily bump.
From-SVN: r69368
2003-07-15 00:16:07 +00:00