Commit Graph

44732 Commits

Author SHA1 Message Date
Jan Hubicka
b67d7f4aab * cgraphunit.c (cgraph_finalize_compilation_unit): Remove redundant if.
From-SVN: r69652
2003-07-21 22:46:47 +00:00
Geoffrey Keating
48873ed202 c-common.h (num_in_fnames): Declare.
* c-common.h (num_in_fnames): Declare.
	(c_static_assembler_name): Move from here...
	* c-tree.h (c_static_assembler_name): ... to here.
	* c-opts.c: Don't include langhooks-def.h.
	(c_static_assembler_name): Move to c-decl.c.
	(num_in_fnames): Make externally visible.
	* c-decl.c: Include langhooks-def.h.
	(c_static_assembler_name): Move from c-opts.c.
	* Makefile.in (c-decl.o): Add $(LANGHOOKS_DEF_H).
	(c-opts.o): Remove $(LANGHOOKS_DEF_H).

From-SVN: r69650
2003-07-21 21:25:47 +00:00
Janis Johnson
dd039fc9e6 compat.exp: Handle dg-options per source file.
* lib/compat.exp: Handle dg-options per source file.
	* g++.dg/compat/abi/bitfield1_x.C: Specify dg-options.
	* g++.dg/compat/abi/bitfield1_y.C: Ditto.
	* g++.dg/compat/abi/bitfield2_x.C: Ditto.
	* g++.dg/compat/abi/bitfield2_y.C: Ditto.
	* g++.dg/compat/abi/vbase8-10_x.C: Ditto.
	* g++.dg/compat/abi/vbase8-10_y.C: Ditto.
	* g++.dg/compat/abi/vbase8-21_x.C: Ditto.
	* g++.dg/compat/abi/vbase8-21_y.C: Ditto.
	* g++.dg/compat/abi/vbase8-22_x.C: Ditto.
	* g++.dg/compat/abi/vbase8-22_y.C: Ditto.
	* g++.dg/compat/abi/vbase8-4_x.C: Ditto.
	* g++.dg/compat/abi/vbase8-4_y.C: Ditto.
	* g++.dg/compat/break/bitfield7_x.C: Ditto.
	* g++.dg/compat/break/bitfield7_y.C: Ditto.

From-SVN: r69649
2003-07-21 21:24:27 +00:00
Neil Booth
8d973a8319 cppfiles.c (open_file_pch): Don't put unused entries in the splay tree.
* cppfiles.c (open_file_pch): Don't put unused entries in the
	splay tree.  Remove dead code.

From-SVN: r69647
2003-07-21 20:57:00 +00:00
Geoffrey Keating
49a64b2462 c-pragma.c (maybe_apply_pragma_weak): Don't get DECL_ASSEMBLER_NAME when it's not needed.
* c-pragma.c (maybe_apply_pragma_weak): Don't get DECL_ASSEMBLER_NAME
	when it's not needed.

From-SVN: r69646
2003-07-21 20:53:07 +00:00
Jakub Jelinek
8c29550d3c rs6000.h (machine_function): Add ra_need_lr.
* config/rs6000/rs6000.h (machine_function): Add ra_need_lr.
	* config/rs6000/rs6000.c (rs6000_return_addr): Set it.
	(rs6000_emit_prologue): Save FPRs inline if set.

From-SVN: r69645
2003-07-21 22:18:52 +02:00
H.J. Lu
92cbea2214 ia64.md (prefetch): Support predicate.
2003-07-21  H.J. Lu <hongjiu.lu@intel.com>

	* config/ia64/ia64.md (prefetch): Support predicate.

From-SVN: r69642
2003-07-21 10:52:22 -07:00
Andrew Pinski
124b0e0529 re PR c/10320 (gcc 3.4 gets rid of static inline function that does not get inlined)
2003-07-21  Andrew Pinski  <pinskia@physics.uc.edu>

        PR c/10320
        * gcc.c-torture/execute/20030718-1.c: New test.

From-SVN: r69639
2003-07-21 10:45:34 -07:00
Josef Zlomek
ee735eefd8 cfgcleanup.c (merge_blocks_move_successor_nojumps): Use tablejump_p.
* cfgcleanup.c (merge_blocks_move_successor_nojumps): Use tablejump_p.
	* rtlanal.c (tablejump_p): Use next_active_insn for finding the jump
	table.

From-SVN: r69637
2003-07-21 17:18:00 +00:00
Eric Botcazou
bbda30a4aa re PR rtl-optimization/11536 ([strength-reduce] -O2 optimalization produces wrong code)
PR optimization/11536
	* unroll.c (loop_iterations): Do not replace a register holding
	the final value by its equivalent before the loop if it is not
	invariant.

        PR optimization/11536
	* gcc.dg/20030721-1.c: New test.

From-SVN: r69635
2003-07-21 16:52:38 +00:00
Dave Fluri
64c18e5710 * doc/extend.texi: Fixes to spelling, grammar, and diction.
From-SVN: r69633
2003-07-21 15:08:55 +00:00
Nathan Sidwell
c7b6131663 Add 'instantiated from' dg-error
From-SVN: r69632
2003-07-21 14:52:14 +00:00
Ben Elliston
b222f49a4c invoke.texi (Optimize Options): Replace "it's" with "its".
* doc/invoke.texi (Optimize Options): Replace "it's" with "its".
	(V850 Options): Spelling fixes.

From-SVN: r69627
2003-07-21 21:10:22 +10:00
Ben Elliston
cea949a61e * Typo fixes.
* Replace "callgraph.{c,o}" with "cgraph.{c,o}" (corrected).

From-SVN: r69626
2003-07-21 20:35:14 +10:00
Nathan Sidwell
9e95d15fd8 cp-tree.h (hack_identifier): Remove.
cp:
	* cp-tree.h (hack_identifier): Remove.
	* method.c (hack_identifier): Remove.
	* semantics.c (finish_id_expression): Expand hack_identifier
	here. Simplify.

From-SVN: r69625
2003-07-21 08:28:33 +00:00
GCC Administrator
0292e50e95 Daily bump.
From-SVN: r69618
2003-07-21 00:16:07 +00:00
Lisa M. Goldstein
9eff22bc46 * doc/invoke.texi: Fixes to style, grammar and diction.
From-SVN: r69613
2003-07-20 20:11:19 +00:00
Roger Sayle
6a6c0154f8 builtins.def (BUILT_IN_ALLOCA): Remove "#if SMALL_STACK" form.
* builtins.def (BUILT_IN_ALLOCA): Remove "#if SMALL_STACK" form.
	* system.h (SMALL_STACK): Poison obsolete target macro.
	* doc/tm.texi (SMALL_STACK): Remove target macro documentation.

From-SVN: r69609
2003-07-20 16:29:57 +00:00
Phil Edwards
d38b3a8d94 configure.in: Cache the results of testing for cmp's capabilities.
2003-07-20  Phil Edwards  <pme@gcc.gnu.org>

	* configure.in:  Cache the results of testing for cmp's capabilities.
	* configure:  Regenerate.

From-SVN: r69607
2003-07-20 09:32:29 +00:00
Mark Mitchell
35dc2bd884 re PR debug/11279 (DWARF-2 output mishandles large enums)
PR debug/11279
	* dwarf2out.c (gen_enumeration_type_die): Remember that
	enumerators can be unsigned.

From-SVN: r69605
2003-07-20 07:24:58 +00:00
Mark Mitchell
e9f9c81fda re PR c++/11546 (Type lookup problems in out-of-line definition of a class doubly nested from a template class)
PR c++/11546
	* g++.dg/template/lookup1.C: New test.

From-SVN: r69602
2003-07-20 04:52:23 +00:00
GCC Administrator
cee89b1964 Daily bump.
From-SVN: r69599
2003-07-20 00:16:07 +00:00
Zack Weinberg
14e33ee856 * c-decl.c (named_labels, shadowed_labels, label_level_chain)
(push_label_level, pop_label_level): Kill.
	(struct binding_level): Rename level_chain to outer.
	Add outer_function field.  Change parm_flag, function_body,
	keep, keep_if_subblocks to 1-bit bitfields of type bool.
	(current_function_level): New variable.
	(keep_next_level_flag, keep_next_if_subblocks): Change type to bool.
	(keep_next_level, declare_parm_level, warn_if_shadowing):
	Update to match.
	(struct language_function): Kill named_labels, shadowed_labels fields.
	(c_init_decl_processing, start_function, c_push__function_context)
	(c_pop_function_context): No need to muck with named_labels nor
	shadowed_labels.

	(make_binding_level): No need to clear the structure here.
	(pop_binding_level): Always operate on current_binding_level.
	Update current_function_level if necessary.
	(pushlevel): Don't clear named_labels.  Update current_function_level
	if necessary.  Use "true" and "false" where appropriate.
	(poplevel): Diagnose labels defined but not used, or vice
	versa, and clear out label-meanings leaving scope, while
	walking down the decls list, for all binding levels.
	Handle LABEL_DECLs appearing in the shadowed list.
	pop_binding_level takes no arguments.
	(pushdecl_function_level): Use current_function_level.

	(make_label, bind_label): New static functions.
	(declare_label): New exported function.
	(lookup_label, define_label): Rewritten for new data structure.
	(shadow_label): Kill.

	* c-tree.h: Prototype declare_label; don't prototype
	push_label_level, pop_label_level, nor shadow_label.
	* c-parse.in: Remove all calls to push_label_level and
	pop_label_level.  Use declare_label for __label__ decls.

	* doc/extend.texi: Clarify that __label__ can be used to
	declare labels with local scope in any nested block, not
	just statement expressions.  Cross-reference nested functions
	section from local labels section.

testsuite:
	* gcc.dg/noncompile/label-1.c: New comprehensive test case for
	diagnostics of ill-formed constructs involving labels.
	* gcc.dg/noncompile/label-lineno-1.c: Add error regexp for
	the new 'previously defined here' message.

From-SVN: r69597
2003-07-19 23:32:55 +00:00
Zdenek Dvorak
8a6b9b7fb8 * sched-rgn.c (find_rgns): Initialize current_edge correctly.
From-SVN: r69595
2003-07-19 22:03:37 +00:00
Phil Edwards
026fe6c859 makefile.texi (restrap, [...]): Document targets.
2003-07-19  Phil Edwards  <pme@gcc.gnu.org>

	* doc/makefile.texi (restrap, profiledbootstrap):  Document targets.

From-SVN: r69594
2003-07-19 22:00:19 +00:00
Kaveh R. Ghazi
c68b0a8425 fixfixes.c [...]: Remove unnecessary casts.
gcc:
	* fixinc/fixfixes.c fixinc/fixincl.c fixinc/fixlib.c
	fixinc/server.c objc/objc-act.c: Remove unnecessary casts.

f:
	* com.c data.c expr.c fini.c g77spec.c global.c lab.c lex.c name.c
	sta.c stc.c std.c storag.c stt.c stw.c symbol.c target.c type.c:
	Remove unnecessary casts.

cp:
	* call.c class.c decl.c decl2.c g++spec.c lex.c parser.c pt.c rtti.c
	semantics.c typeck.c: Remove unnecessary casts.

java:
	* class.c java-tree.h jcf-write.c jvspec.c: Remove unnecessary
	casts.

treelang:
	* treetree.c: Remove unnecessary casts.

From-SVN: r69593
2003-07-19 16:09:51 +00:00
Ulrich Weigand
fd7643fbe4 s390.c (legitimize_pic_address): Access local symbols relative to the GOT instead of relative to the literal...
* config/s390/s390.c (legitimize_pic_address): Access local symbols
	relative to the GOT instead of relative to the literal pool base.
	(s390_output_symbolic_const): Handle new GOT-relative accesses.
	* config/s390/s390.md ("call"): Access local functions and PLT stubs
	relative to the GOT instead of relative to the literal pool base.
	("call_value"): Likewise.
	("call_value_tls"): Likewise.

	* config/s390/s390.c (s390_chunkify_start): Remove pool anchor
	reloading.  Support LTREL_BASE / LTREL_OFFSET construct.
	(s390_chunkify_finish): Likewise.
	(s390_chunkify_cancel): Likewise.
	(s390_reorg): Adapt caller.
	(find_base_register_in_addr,
	find_base_register_ref, replace_base_register_ref): Delete.
	(find_ltrel_base, replace_ltrel_base): New functions.
	(find_constant_pool_ref): Handle LTREL_BASE unspecs.
	(s390_decompose_address): Handle LTREL_BASE unspecs.  Optimize
	base vs. index register usage.
	(struct constant_pool): Remove 'anchor'.
	(s390_add_anchor): Delete.
	(s390_dump_pool): Remove anchor handling.
	* config/s390/s390.md ("reload_anchor"): Remove.

	* config/s390/s390.c (s390_split_branches): Use LTREL_BASE/OFFSET.
	(s390_load_got): New function.  Use LTREL_BASE/OFFSET.
	(s390_emit_prologue): Use it.
	* config/s390/s390.md ("builtin_longjmp", "builtin_setjmp_setup",
	"builtin_setjmp_receiver"): Cleanup.  Use s390_load_got.  Do not
	hard-code register 14.
	* config/s390/s390-protos.h (s390_load_got): Declare.

	* config/s390/s390.c (NR_C_MODES, constant_modes, gen_consttable):
	Support TImode constants.
	* config/s390/s390.md ("consttable_ti"): New.
	("consttable_si", "consttable_di"): Handle TLS symbols correctly.

	* config/s390/s390.md (UNSPEC_LTREL_OFFSET, UNSPEC_LTREL_BASE,
	UNSPEC_GOTENT, UNSPEC_GOT, UNSPEC_GOTOFF, UNSPEC_PLT, UNSPEC_PLTOFF,
	UNSPEC_RELOAD_BASE, UNSPECV_POOL, UNSPECV_POOL_START, UNSPECV_POOL_END,
	UNSPECV_POOL_QI, UNSPECV_POOL_HI, UNSPECV_POOL_SI, UNSPECV_POOL_DI,
	UNSPECV_POOL_TI, UNSPECV_POOL_SF, UNSPECV_POOL_DF, UNSPECV_MAIN_POOL):
	New symbolic constants.
	("consttable_qi", "consttable_hi", "consttable_si", "consttable_di",
	"consttable_sf", "consttable_df", "pool_start_31", "pool_end_31",
	"pool_start_64", "pool_end_64", "reload_base_31", "reload_base_64",
	"pool", "literal_pool_31", "literal_pool_64"): Cleanup.  Use
	symbolic UNSPEC values.
	* config/s390/s390.c (larl_operand, s390_short_displacement,
	bras_sym_operand, s390_cannot_force_const_mem,
	s390_delegitimize_address, s390_decompose_address,
	legitimize_pic_address, s390_output_symbolic_const,
	s390_function_profiler): Use symbolic UNSPEC values.

From-SVN: r69592
2003-07-19 16:06:52 +00:00
Kaveh R. Ghazi
703ad42b4b alias.c [...]: Remove unnecessary casts.
* alias.c alloc-pool.c bitmap.c bitmap.h bt-load.c builtins.c
	c-common.c c-decl.c c-incpath.c c-lex.c c-opts.c c-parse.in
	c-pragma.c c-typeck.c calls.c cfg.c cfganal.c cfgloop.c cfgrtl.c
	collect2.c combine.c conflict.c coverage.c cppexp.c cppfiles.c
	cpphash.c cppinit.c cpplex.c cpplib.c cppmacro.c cppspec.c
	cpptrad.c cse.c cselib.c dbxout.c defaults.h df.c dominance.c
	dwarf2out.c dwarfout.c emit-rtl.c except.c expmed.c expr.c final.c
	fix-header.c flow.c fold-const.c function.c gcc.c gccspec.c gcov.c
	gcse.c genattr.c genattrtab.c genautomata.c genconditions.c
	genemit.c genextract.c genoutput.c genrecog.c gensupport.c
	ggc-page.c ggc-simple.c global.c graph.c haifa-sched.c hashtable.c
	integrate.c jump.c langhooks.c lcm.c line-map.c local-alloc.c
	loop.c mips-tdump.c mips-tfile.c mkdeps.c optabs.c params.c
	postreload.c prefix.c print-tree.c protoize.c ra-build.c
	ra-colorize.c ra-rewrite.c ra.c recog.c reg-stack.c regclass.c
	regmove.c regrename.c reload.c reload1.c reorg.c resource.c
	sbitmap.c sched-deps.c sched-rgn.c sched-vis.c sdbout.c
	simplify-rtx.c ssa-ccp.c ssa.c stmt.c stor-layout.c timevar.c
	tlink.c toplev.c tree-dump.c tree.c unroll.c unwind-dw2-fde.c
	varasm.c varray.c vmsdbgout.c xcoffout.c: Remove unnecessary
	casts.

From-SVN: r69587
2003-07-19 14:47:15 +00:00
Gabriel Dos Reis
308ca868d3 c-pragma.c (apply_pragma_weak): Don't use warning_with_decl.
* c-pragma.c (apply_pragma_weak): Don't use warning_with_decl.
	* toplev.h (warning): Remove attribute.

From-SVN: r69585
2003-07-19 13:10:17 +00:00
Kriang Lerdsuwanakij
94b32725fa Correct entries information
From-SVN: r69583
2003-07-19 12:06:07 +00:00
Gabriel Dos Reis
435ab23636 c-decl.c (c_finish_incomplete_decl): Don't use xxx_with_decl.
* c-decl.c (c_finish_incomplete_decl): Don't use xxx_with_decl.
	(pop_label_level): Likewise.
	(duplicate_decls): Likewise.
	(implicitly_declare): Likewise.
	(shadow_label): Likewise.
	(start_decl): Likewise.
	(finish_decl): Likewise.
	(grokdeclarator): Likewise.
	(get_parm_info): Likewise.
	(detect_field_duplicates): Likewise.
	(finish_struct): Likewise.
	(start_function): Likewise.
	(store_parm_decls): Likewise.
	(finish_function): Likewise.
	(c_expand_body_1): Likewise.
	(check_for_loop_decls): Likewise.
	(merge_translation_unit_decls): Likewise.

From-SVN: r69582
2003-07-19 10:19:19 +00:00
Neil Booth
2cc980567a common.opt: Document --param.
* common.opt:  Document --param.
	* opts.c (columns, undocumented_msg): New.
	(print_help): Get number of columns from environment.  Print
	--param help.  Tweak newline handling.
	(print_param_help): New.
	(print_filtered_help): Better handling of duplicates.  Complain
	about undocumented switches.
	(print_switch): New.
	(wrap_help): Improve wrapping, use COLUMNS.
	* opts.sh: Ignore comments in records.
	* params.def: Fix typos and remove trailing periods.
	* toplev.c (display_help): Don't dump --param help.
	* doc/sourcebuild.texi: Update.
java:
	* lang.opt: Don't show -MD_ and -MDD_.

From-SVN: r69581
2003-07-19 08:13:58 +00:00
David S. Miller
0e38b30b19 Add missing PR number.
From-SVN: r69580
2003-07-19 00:05:39 -07:00
Richard Henderson
d893ccde91 optabs.c (prepare_operand): Fail gracefully instead of abort if the predicate doesn't satisfy.
2003-07-18  Richard Henderson  <rth@redhat.com>

	* optabs.c (prepare_operand): Fail gracefully instead of abort
	if the predicate doesn't satisfy.
	(gen_cond_trap): Allow prepare_operand to fail.

From-SVN: r69578
2003-07-18 17:28:05 -07:00
GCC Administrator
3b1eae7b3b Daily bump.
From-SVN: r69575
2003-07-19 00:16:07 +00:00
Gabriel Dos Reis
eb8221eaf2 c-common.c: Don't undefine GCC_DIAG_STYLE.
* c-common.c: Don't undefine GCC_DIAG_STYLE.
	(fname_decl): Don't use xxx_with_decl.
	(c_add_case_label): Likewise.
	(handle_section_attribute): Likewise.
	(handle_alias_attribute): Likewise.
	(handle_no_instrument_function_attribute): Likewise.
	(handle_no_limit_stack_attribute): Likewise.
	* c-objc-common.c (c_tree_printer): Print IDENTIFIER_NODEs.
	* c-format.c (gcc_cdiag_char_table): Add '%E' format-specifier.

From-SVN: r69573
2003-07-18 23:05:53 +00:00
Zdenek Dvorak
65f43cdfee Makefile.in (ifcvt.o): Add cfgloop.h.
* Makefile.in (ifcvt.o): Add cfgloop.h.
	* basic-block.h (EDGE_LOOP_EXIT): New flag.
	* cfgrtl.c (rtl_verify_flow_info_1): Handle it correctly.
	* ifcvt.c: Include cfgloop.h.
	(mark_loop_exit_edges): New static function.
	(if_convert): Call it.
	(find_if_header): Ignore branches out of loops.

From-SVN: r69572
2003-07-18 22:52:05 +00:00
Kazu Hirata
e5686da761 combine.c (simplify_comparison): Don't share rtx when converting (ne (and (not X) 1) 0) to (eq (and X 1) 0).
* combine.c (simplify_comparison): Don't share rtx when converting
	(ne (and (not X) 1) 0) to (eq (and X 1) 0).

From-SVN: r69571
2003-07-18 21:53:04 +00:00
David Edelsohn
8d05ebaa24 aix.h (AGGREGATE_PADDING_FIXED): Define.
* config/rs6000/aix.h (AGGREGATE_PADDING_FIXED): Define.
	(AGGREGATES_PAD_UPWARD_ALWAYS): Define.
	(MUST_PASS_IN_STACK): Define.
	(BLOCK_REG_PADDING): Define.

From-SVN: r69570
2003-07-18 17:42:29 -04:00
Richard Henderson
790199856a cfgrtl.c (force_nonfallthru_and_redirect): Use tablejump_p to skip the addr_vec.
* cfgrtl.c (force_nonfallthru_and_redirect): Use tablejump_p
        to skip the addr_vec.

From-SVN: r69569
2003-07-18 14:33:36 -07:00
Alexandre Oliva
0595d388a4 combine.c (combinable_i3pat): Don't forbid occurrences of i2dest or i1dest in inner_dest if inner_dest is a mem.
* combine.c (combinable_i3pat): Don't forbid occurrences of
i2dest or i1dest in inner_dest if inner_dest is a mem.

From-SVN: r69566
2003-07-18 18:23:30 +00:00
Nathan Sidwell
d54b595734 changelog for previous patch
From-SVN: r69565
2003-07-18 17:37:00 +00:00
Nathan Sidwell
a3f10e50d7 cp-tree.h (finish_non_static_data_member): Add object param.
cp:
	* cp-tree.h (finish_non_static_data_member): Add object param.
	* method.c (hack_identifier): Adjust.
	* pt.c (tsubst_copy_and_build) <COMPONENT_REF case>: Don't search
	again for a FIELD_DECL.
	* semantics.c (finish_non_static_data_member): Add object
	parameter. Always save the DECL in the COMPONENT_REF.
	* call.c (resolve_scoped_fn_name): Adjust.
testsuite:
	* g++.dg/parse/non-dependent2.C: New test.

From-SVN: r69564
2003-07-18 17:19:41 +00:00
Jan Hubicka
2ee1067b6b * cgraph.c (cgraph_remove_node): Clear the hash table slot.
From-SVN: r69562
2003-07-18 15:13:35 +00:00
Andrew Pinski
1fd0cd4209 init-ref4.C: xfail on targets without weak symbols.
2003-07-18  Andrew Pinski  <pinskia@physics.uc.edu>

        * g++.dg/init/init-ref4.C: xfail on targets without
        weak symbols.

From-SVN: r69558
2003-07-18 06:07:22 -07:00
Jakub Jelinek
16f6812f86 re PR target/11087 (gcc miscompiles raid1.c from linux kernel)
PR target/11087
	* loop.c (basic_induction_var): Check if convert_modes emitted any
	instructions. Remove them and return 0 if so.

	* gcc.c-torture/execute/20030717-1.c: New test.

From-SVN: r69552
2003-07-18 13:13:37 +02:00
Eric Botcazou
f129791ccd toplev.c (rest_of_handle_addresof): Rename into rest_of_handle_addressof.
* toplev.c (rest_of_handle_addresof): Rename into
	rest_of_handle_addressof.  Delete unreachable blocks
	if dead edges were purged after the addressof pass.

From-SVN: r69545
2003-07-18 06:53:05 +00:00
Neil Booth
b2e608ca7f Makefile.in, [...]: Remove handling of lang-options.h and options_.h.
* Makefile.in, configure, configure.in: Remove handling of
	lang-options.h and options_.h.
	* toplev.c (struct lang_opt, documented_lang_options): Remove.
	(display_help): Don't use documented_lang_options.
ada:
	* lang-options.h: Remove.
	* lang.opt: Add help text.
java:
	* lang-options.h: Remove.
	* lang.opt: Add help text.

From-SVN: r69544
2003-07-18 05:32:42 +00:00
Zack Weinberg
9cd51ef68e c-decl.c (pushdecl_function_level): Make static, return nothing.
* c-decl.c (pushdecl_function_level): Make static, return nothing.
	(kept_level_p): Fold into poplevel.
	(undeclared_variable): Moved here from c-typeck.c.  Export.
	* c-tree.h (KEEP_YES, KEEP_NO, KEEP_MAYBE): New #defines.
	(undeclared_variable): Prototype here.  Don't prototype
	kept_level_p nor pushdecl_function_level.
	* c-parse.in: Change first argument to poplevel from
	"kept_level_p()" to "KEEP_MAYBE".
	* c-typeck.c (undeclared_variable): Moved to c-decl.c.

From-SVN: r69540
2003-07-18 03:39:42 +00:00
Roger Sayle
cf6bcbd084 simplify-rtx.c (simplify_rtx): Use simplify_gen_binary to swap commutative operands instead of modifying the...
* simplify-rtx.c (simplify_rtx): Use simplify_gen_binary to swap
	commutative operands instead of modifying the RTL in-place.

From-SVN: r69539
2003-07-18 03:16:32 +00:00
Mark Mitchell
2b187c63e2 re PR rtl-optimization/11557 (constant folding)
PR optimization/11557
	* calls.c (flags_from_decl_or_type): Do not set ECF_LIBCALL_BLOCK
	unless we know which function is being called.

	PR optimization/11557
	* gcc.dg/20030717-1.c: New test.

From-SVN: r69538
2003-07-18 03:05:27 +00:00
Roger Sayle
c715abddc7 cse.c (fold_rtx): Use swap_commutative_operands_p to determine whether to reorder the operands of...
* cse.c (fold_rtx): Use swap_commutative_operands_p to determine
	whether to reorder the operands of a commutative binary operator.

From-SVN: r69534
2003-07-18 00:28:14 +00:00
Roger Sayle
3e4093b64f fold-const.c (const_binop): Avoid performing the FP operation at compile-time...
* fold-const.c (const_binop): Avoid performing the FP operation at
	compile-time, if either operand is NaN and we honor signaling NaNs,
	or if we're dividing by zero and either flag_trapping_math is set
	or the desired mode doesn't support infinities.
	(fold_initializer): New function to fold an expression ignoring any
	potential run-time exceptions or traps.
	* tree.h (fold_initializer): Prototype here.
	* c-typeck.c (build_binary_op): Move to the end of the file so
	that intializer_stack is in scope.  If constructing an initializer,
	i.e. when initializer_stack is not NULL, use fold_initializer to
	fold expressions.
	* simplify-rtx.c (simplify_binary_operation): Likewise, avoid
	performing FP operations at compile-time, if they would raise an
	exception at run-time.

From-SVN: r69533
2003-07-18 00:26:51 +00:00
GCC Administrator
35c77862c9 Daily bump.
From-SVN: r69531
2003-07-18 00:16:08 +00:00
Andrew Pinski
bf88d87002 Andrew Pinski <pinskia@physics.uc.edu>
PR c++/10476
        * g++.dg/expr/crash-1.C: New test.

        PR c++/11027
        * g++.dg/template/init3.C: New test.

        PR c++/8222
        * g++.dg/template/non-dependent1.C: New test.

        PR c++/11070
        * g++.dg/template/non-dependent2.C: New test.

        PR c++/11071
        * g++.dg/template/non-dependent3.C: New test.

        PR c++/9907
        * g++.dg/template/sizeof5.C: New test.

From-SVN: r69529
2003-07-17 15:53:46 -07:00
Geoffrey Keating
26e0dcb326 re PR middle-end/11498 (asm can't be used to give a variable its own name)
PR 11498
	* Makefile.in (c-opts.o): Add $(LANGHOOKS_DEF_H).
	(langhooks.o): Add $(GGC_H), gt-langhooks.h.
	(GTFILES): Add langhooks.c.
	(gt-langhooks.h): New.
	* c-common.h (c_static_assembler_name): Prototype.
	* c-lang.c (LANG_HOOKS_SET_DECL_ASSEMBLER_NAME): Define.
	* objc/objc-lang.c (LANG_HOOKS_SET_DECL_ASSEMBLER_NAME): Define.
	* c-opts.c: Include langhooks-def.h.
	(c_static_assembler_name): New.
	* langhooks.c: Include ggc.h.  Include gt-langhooks.h.
	(var_labelno): New.
	(lhd_set_decl_assembler_name): Give static objects with context
	unique names.
	* varasm.c (var_labelno): Delete.
	(make_decl_rtl): Don't change the assembler name once it's set.

From-SVN: r69527
2003-07-17 21:52:51 +00:00
Geoffrey Keating
89e9faee22 c-opts.c (this_input_filename): New.
* c-opts.c (this_input_filename): New.
	(finish_options): Take new parameter, name of file being compiled.
	Update callers.  Set this_input_filename.
	(push_command_line_include): Use this_input_filename not
	main_input_filename.

From-SVN: r69526
2003-07-17 21:50:38 +00:00
Zack Weinberg
36c6d174b3 objc-lang.c: Override LANG_HOOKS_WRITE_GLOBALS to c_write_global_declarations.
* objc/objc-lang.c: Override LANG_HOOKS_WRITE_GLOBALS to
	c_write_global_declarations.

From-SVN: r69525
2003-07-17 21:05:24 +00:00
Neil Booth
6ec3f553fe Makefile.in: Depend .pot generation on options.c.
* Makefile.in: Depend .pot generation on options.c.
	* po/exgettext: Add an extra_files variable containing additional
	files to scan.

From-SVN: r69524
2003-07-17 20:29:40 +00:00
Zack Weinberg
b92ef8fdac Missed this hunk - belongs with the previous patch
From-SVN: r69521
2003-07-17 20:25:21 +00:00
Zack Weinberg
eb1dfbb2fb c-decl.c: Fix typos in several comments.
* c-decl.c: Fix typos in several comments.  Remove all
	#if 0 blocks; reindent as needed.  Remove unused argument
	to declare_parm_level; all callers changed.
	* c-parse.in: Update calls to declare_parm_level.  Avoid
	issuing a double warning in some circumstances.
	* c-typeck.c: Update calls to declare_parm_level.
	* c-tree.h: Update prototype of declare_parm_level.

	* c-pragma.c (apply_pragma_weak): Don't complain about a
	redundant #pragma weak.

	* objc/objc-act.c (forward_declare_categories,
	build_selector_reference_decl, build_class_reference_decl,
	build_objc_string_decl, synth_forward_declarations,
	build_protocol_reference): Set TREE_PUBLIC on synthetic
	forward decl to 0, consistent with eventual definition.
	Correct comments to match.

cp:
	* pt.c (get_bindings): Make definition consistent with
	forward declaration.

From-SVN: r69519
2003-07-17 20:12:21 +00:00
Zack Weinberg
78ff95dc17 inclhack.def (solaris_mutex_init_2): Escape braces in regexp that don't form a range expression.
* fixinc/inclhack.def (solaris_mutex_init_2): Escape braces
	in regexp that don't form a range expression.
	* fixinc/fixincl.def: Regenerate.

From-SVN: r69517
2003-07-17 18:43:37 +00:00
Richard Henderson
b23ba0b898 re PR target/10907 ([IA64] gcc violates the ia64 ABI)
PR target/10907
        * config/ia64/ia64.c (ia64_epilogue_uses): GP is live at end
        even with !TARGET_CONST_GP.
        (ia64_function_ok_for_sibcall): Reject non-local functions.

From-SVN: r69515
2003-07-17 09:33:22 -07:00
Kriang Lerdsuwanakij
2a39bedbed Fix typo in date
From-SVN: r69514
2003-07-17 15:49:19 +00:00
Kriang Lerdsuwanakij
41c5ee0615 re PR c++/7809 (befriending inaccessible names)
PR c++/7809
	* friend.c (add_friend): Check access for member functions
	and templates.

	* g++.dg/parse/access3.C: New test.

From-SVN: r69513
2003-07-17 15:47:40 +00:00
Steven Bosscher
d944c82dce c-common.c (c_estimate_num_insns_1): Don't handle METHOD_CALL_EXPR.
2003-07-17  Steven Bosscher  <steven@gcc.gnu.org>

	* c-common.c (c_estimate_num_insns_1): Don't handle
	METHOD_CALL_EXPR.
	* expr.c (safe_from_p): Likewise.
	* gengtype.c (adjust_field_tree_exp): Likewise.
	* stmt.c (warn_if_unused_value): Likewise
	* tree.c (first_rtl_op): Likewise.
	* tree.def: Don't define METHOD_CALL_EXPR.
	* java/lang.c (java_estimate_num_insns_1): Don't handle
	METHOD_CALL_EXPR.

From-SVN: r69511
2003-07-17 13:25:21 +00:00
Andrew Pinski
d424f7ff66 re PR c++/11384 (missing implicit instantiation of template static members)
2003-06-17  Andrew Pinski  <pinskia@physics.uc.edu>

        PR c++/11384
        * g++.dg/init/init-ref4.C: New test.

From-SVN: r69510
2003-07-17 04:53:07 -07:00
Gabriel Dos Reis
ef292d4f65 re PR c++/10668 (assigning address of non-static member variable to pointer)
PR c++/10668
	* typeck.c (build_class_member_access_expr): Improve diagnostic.

From-SVN: r69509
2003-07-17 11:49:02 +00:00
Eric Botcazou
54284728e5 re PR other/11466 ('-mlittle-endian' doesn't work with GCC3.2.3 under Solaris 2.x)
PR other/11466
	* doc/invoke.texi (SPARC Options): Document "-mlittle-endian"
	and its restrictions for the SPARC64 port.
	Move the entry of "-mimpure-text" before that of "-mv8".

From-SVN: r69497
2003-07-17 07:30:07 +00:00
Eric Botcazou
bc89096116 install.texi (*-*-solaris2*): Document the step-by-step procedure to bootstrap and install.
* doc/install.texi (*-*-solaris2*): Document the step-by-step
	procedure to bootstrap and install.
	Document the preference for the legacy Sun tools in /usr/bin
	over the POSIX tools in /usr/xpg4/bin for the build process.

Co-Authored-By: Phil Edwards <phil@jaj.com>

From-SVN: r69495
2003-07-17 06:12:43 +00:00
Neil Booth
f2ac996428 c.opt: Document Uncodumented; use it.
* c.opt: Document Uncodumented; use it.  Document ObjC options.
	* opts.c (print_filtered_help): Skip undocumented switches.
	* opts.h (CL_UNDOCUMENTED): New.
	* opts.sh: Handle Undocumented.
	* toplev.c (documented_lang_options): Prevent its becoming empty.
f:
	* lang-options.h: Remove.
	* lang.opt: Document most options.
objc:
	* lang-options.h: Remove.

From-SVN: r69494
2003-07-17 05:33:18 +00:00
Mark Mitchell
39703eb9e2 re PR c++/11547 (ICE with const temporaries)
PR c++/11547
	* cp-tree.h (DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P): New
	macro.
	(DECL_PRETTY_FUNCTION_P): Use VAR_DECL_CHECK.
	* decl.c (duplicate_decls): Merge
	DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P.
	* parser.c (cp_parser_postfix_expression): Adjust call to
	cp_parser_initializer_list and
	cp_parser_parenthesized_expression_list.
	(cp_parser_parenthesized_expression_list): Add non_constant_p.
	(cp_parser_new_placement): Adjust call to
	cp_parser_parenthesized_expression_list.
	(cp_parser_direct_new_declarator): Likewise.
	(cp_parser_conditional_expression): Remove.
	(cp_parser_constant_expression): Parse an assignment-expression,
	not a conditional-expression.
	(cp_parser_simple_declaration): Resolve expression/declaration
	ambiguity more quickly.
	(cp_parser_mem_initializer): Adjust call to
	cp_parser_parenthesized_expression_list.
	(cp_parser_init_declarator): Keep track of whether or not the
	initializer is a constant-expression.
	(cp_parser_initializer): Add non_constant_p parameter.
	(cp_parser_initializer_clause): Likewise.
	(cp_parser_initializer_list): Likewise.
	(cp_parser_attribute_list): Adjust call to
	cp_parser_parenthesized_expression_list.
	(cp_parser_functional_cast): Likewise.
	* pt.c (tsubst_decl): Copy
	DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P.
	(tsubst_expr): Tweak use of DECL_PRETTY_FUNCTION_P.
	* semantics.c (finish_id_expression): Use
	DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P.

	PR c++/11547
	* g++.dg/parse/constant3.C: New test.
	* g++.dg/parse/crash7.C: Likewise.

From-SVN: r69493
2003-07-17 04:31:42 +00:00
Ulrich Weigand
03988cac58 loop.c (check_ext_dependent_givs): Pass const struct loop * instead of struct loop_info * as argument.
* loop.c (check_ext_dependent_givs): Pass const struct loop *
	instead of struct loop_info * as argument.  Accept BIVs with
	increment +/- 1 provided there is a friendly exit test against
	a loop-invariant value.
	(strength_reduce): Adapt call to check_ext_dependent_givs.

From-SVN: r69489
2003-07-17 00:59:52 +00:00
GCC Administrator
1129e7f414 Daily bump.
From-SVN: r69487
2003-07-17 00:16:06 +00:00
J"orn Rennecke
fada196198 prologue / epilogue / warning patches:
2003-07-16  J"orn Rennecke <joern.rennecke@superh.com>
	    Con Bradley <con.bradley@superh.com>

	* sh-protos.h (sh_get_pr_initial_val): Declare.
	* sh.c (regno_reg_class): Make its elements type enum reg_class.
	(output_stack_adjust): Remove emit_fn argument.  Add epilogue_p
	and live_regs_mask arguments.  Changed all callers.
	(save_schedule_s): New structure.
	(save_schedule): New typedef.
	(scavenge_reg, sh5_schedule_saves, sh5_schedule_saves): New functions.
	(calc_live_regs): For TARGET_SHMEDIA, use leaf_function_p.
	In interrupts handlers, also save registers that are usually
	partially saved, and make sure there is at least one general purpose
	register saved if a target register needs saving.
	Add casts in comparisons to avoid warnings.
	(sh_media_register_for_return): return -1 for interrupt handlers.
	(MAX_SAVED_REGS, MAX_TEMPS): New defines.
	(sh_expand_prologue): Use sh5_schedule_saves.  Check that any temp
	registers used are available.
	Set RTX_FRAME_RELATED_P where appropriate.
	Add an REG_FRAME_RELATED_EXPR for r0 + offset addressing.
	(sh_expand_epilogue, sh_set_return_address): Use sh5_schedule_saves.
	(initial_elimination_offset): Likewise.
	* sh.h (DWARF_CIE_DATA_ALIGNMENT): Set to -4.
	(LOCAL_ALIGNMENT, GENERAL_REGISTER_P): Add casts to avoid warnings.
	(FP_REGISTER_P): Add casts to fix broken handling of unsigned REGNO.
	(XD_REGISTER_P, TARGET_REGISTER_P): Likewise.
	(HARD_REGNO_CALL_PART_CLOBBERED): Also yield nonzero for r15,
	and for target registers.
	(RETURN_IN_MEMORY): Add parentheses to avoid warnings.
	(regno_reg_class): Make its elements type enum reg_class.
	(CONSTRAINT_LEN): Don't use isdigit.
	(FUNCTION_ARG_REGNO_P): Add casts to avoid warnings.
	(FUNCTION_ARG): Add parentheses to avoid warnings.
	(RETURN_ADDR_RTX): Use sh_get_pr_initial_val.
	(RETURN_ADDR_OFFSET): Define to -1 for TARGET_SH5.
	(SH_DBX_REGISTER_NUMBER): Add casts to avoid warnings.
	(EH_RETURN_DATA_REGNO): Use unsigned constants to avoid warnings.
	* sh.md (xordi3+1): Remove unused variable regno.
	(return_media): Check that tr0 is available before using it.

Co-Authored-By: Con Bradley <con.bradley@superh.com>

From-SVN: r69480
2003-07-16 22:41:20 +01:00
Andrew Pinski
1f8ae5cd7a file should have been named i386-pentium4-not-mull.c, not i386-pentium4-no-mull.c.
From-SVN: r69478
2003-07-16 13:07:50 -07:00
Neil Booth
bae92bf3c0 c.opt: Document more options.
* c.opt: Document more options.
cp:
	* lang-options.h: Remove.

From-SVN: r69477
2003-07-16 19:49:51 +00:00
Roger Sayle
cc8c96fd6d combine.c (subst): Also handle (subreg (const_double ...)) case if created by a substitution...
* combine.c (subst): Also handle (subreg (const_double ...)) case
	if created by a substitution, by using the original inner mode.

From-SVN: r69476
2003-07-16 19:36:38 +00:00
Roger Sayle
d41ba56fc4 simplify-rtx.c (simplify_replace_rtx): Convert constant comparisons to MODE_FLOAT constants if...
* simplify-rtx.c (simplify_replace_rtx): Convert constant comparisons
	to MODE_FLOAT constants if FLOAT_STORE_FLAG_VALUE is defined.
	(simplify_rtx): Likewise.  Simplify (lo_sum (high X) X) as X.

From-SVN: r69475
2003-07-16 19:34:50 +00:00
Andrew Pinski
264d65c1b5 install.texi (--without-headers): New.
2003-07-16  Andrew Pinski <pinskia@physics.uc.edu>

	* doc/install.texi (--without-headers): New.

From-SVN: r69474
2003-07-16 12:28:43 -07:00
Andrew Pinski
1622229cb1 Partial Fix PR/10129
2003-07-17  Andrew Pinski  <pinskia@physics.uc.edu>

        Partial Fix PR/10129
        * config/darwin.c (machopic_function_base_name): Only Return "<pic base>".
        (machopic_output_function_base_name): New; print the true pic label.
        (machopic_classify_ident): Pic Base is always a defined data.
        * config/darwin.h (ASM_OUTPUT_LABELREF): Support the pic base label.
        * config/darwin-proto.h (machopic_output_function_base_name): Prototype.

From-SVN: r69472
2003-07-16 12:05:53 -07:00
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
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
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
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
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
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
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
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
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
Geoffrey Keating
ea00486e43 unwind-dw2-fde-darwin.c (live_image_destructor): Get seen_objects and unseen_objects from the global data before calling...
* unwind-dw2-fde-darwin.c (live_image_destructor): Get seen_objects
	and unseen_objects from the global data before calling
	__deregister_frame_info_bases.
	(examine_objects): Insert objects into the seen_objects list,
	not unseen_objects.
	(_Unwind_Find_FDE): Always unlock the global object lists, even if
	we couldn't allocate a data structure to put in it.

From-SVN: r69366
2003-07-14 23:04:30 +00:00
Geoffrey Keating
18009d039e objc-act.h (CLASS_SUPER_NAME): Add a little typechecking.
* objc/objc-act.h (CLASS_SUPER_NAME): Add a little typechecking.
	(TYPE_PROTOCOL_LIST): Share use of type.context with C frontend.
	(SET_TYPE_PROTOCOL_LIST): New.
	* objc/objc-act.c (get_static_reference): Use SET_TYPE_PROTOCOL_LIST.
	(get_object_reference): Likewise.

From-SVN: r69364
2003-07-14 21:35:37 +00:00
Mark Mitchell
8d83f79225 re PR c++/11509 (ICE with expression with static member in template arg)
PR c++/11509
	* pt.c (dependent_scope_ref_p): New function.
	(value_dependent_expression_p): Use it.
	(type_dependent_expression_p): Likewise.

	* pt.c (tsubst_friend_function): Use reregister_specialization.

	PR c++/11509
	* g++.dg/template/crash6.C: New test.

From-SVN: r69363
2003-07-14 21:32:26 +00:00
Jan Hubicka
9ae130f857 cfglayout.c (locator_file): Break out from ....
* cfglayout.c (locator_file): Break out from ....
	(insn_file): ... here.
	(locator_line): Break out from ....
	(insn_line): ... here.
	* rtl.h (locator_file, locator_line): Declare.
	(final_start_function): Set proper line/file info.

From-SVN: r69359
2003-07-14 21:18:15 +00:00
Gabriel Dos Reis
e07d4821a6 *** empty log message ***
From-SVN: r69358
2003-07-14 20:52:04 +00:00
Richard Sandiford
121d69e69a mips.c (mips_expand_prologue): Use a single insn to allocate 32768 bytes of stack.
* config/mips/mips.c (mips_expand_prologue): Use a single insn to
	allocate 32768 bytes of stack.  Use addition rather than subtraction
	when a single insn is enough.
	* config/mips/mips.md: Remove insns and splitters for subtracting
	constants.
	(subsi3): Only accept register operands.
	(subsi3_internal): Likewise.  Use for TARGET_MIPS16 as well.
	(subdi3_internal_3, subsi3_internal_2): Likewise.
	(casesi): Use expand_binop to subtract the lower bound.

From-SVN: r69357
2003-07-14 20:41:27 +00:00
Richard Sandiford
3485245e16 mips.c (mips_in_small_data_p): Don't handle TARGET_MIPS16 specially.
* config/mips/mips.c (mips_in_small_data_p): Don't handle
	TARGET_MIPS16 specially.

From-SVN: r69356
2003-07-14 20:36:28 +00:00
Richard Sandiford
6d0b50a4c8 elf.h (ASM_OUTPUT_ALIGNED_BSS): Use mips_output_aligned_bss.
* config/mips/elf.h (ASM_OUTPUT_ALIGNED_BSS): Use
	mips_output_aligned_bss.
	* config/mips/linux.h: Likewise.
	* config/mips/mips-protos.h (mips_output_aligned_bss): Declare.
	* config/mips/mips.c (mips_output_aligned_bss): New function.

From-SVN: r69355
2003-07-14 20:29:34 +00:00
Richard Sandiford
8d50bd1960 elf.h (DBX_DEBUGGING_INFO): Delete.
* config/mips/elf.h (DBX_DEBUGGING_INFO): Delete.
	* config/mips/elf64.h: Likewise.

From-SVN: r69354
2003-07-14 20:25:55 +00:00
Richard Sandiford
c1115ccd68 elf.h (ASM_DECLARE_OBJECT_NAME): Use mips_declare_object_name.
* config/mips/elf.h (ASM_DECLARE_OBJECT_NAME): Use
	mips_declare_object_name.
	(ASM_FINISH_DECLARE_OBJECT): Likewise mips_finish_declare_object.
	* config/mips/elf64.h: As for elf.h.
	* config/mips/iris6.h: Likewise.
	* config/mips/linux.h (ASM_DECLARE_OBJECT_NAME): As for elf.h.
	* config/mips/mips.h (ASM_DECLARE_OBJECT_NAME): Remove unnecessary
	do...while (0) block.
	* config/mips/mips-protos.h (mips_declare_object_name): Declare.
	(mips_finish_declare_object): Declare.
	* config/mips/mips.c (mips_declare_object_name): New function.
	(mips_finish_declare_object): New function.

From-SVN: r69352
2003-07-14 20:23:38 +00:00
Mark Mitchell
748d4c7e65 re PR c++/7053 (ICE when declaring a function already defined as a friend method of a template class)
PR c++/7053
	* g++.dg/template/friend20.C: New test.

From-SVN: r69351
2003-07-14 20:20:27 +00:00
Richard Sandiford
060ff934f6 elf.h (SBSS_SECTION_ASM_OP): Delete.
* config/mips/elf.h (SBSS_SECTION_ASM_OP): Delete.
	* config/mips/linux.h: Likewise.

From-SVN: r69350
2003-07-14 20:19:26 +00:00
Richard Sandiford
d82783b609 mips.c (inside_function): Delete.
* config/mips/mips.c (inside_function): Delete.
	(file_in_function_warning, ignore_line_number): Delete.
	(mips_output_filename): Don't warn about changing filenames within
	a function.
	(mips_output_lineno): Update accordingly.
	(mips_output_function_prologue): Don't reset the deleted variables.
	* config/mips/mips.h (inside_function): Delete.
	(file_in_function_warning, ignore_line_number): Delete.

From-SVN: r69348
2003-07-14 20:15:47 +00:00
Richard Sandiford
373f8df79e elf.h (OBJECT_FORMAT_COFF, [...]): Remove undefs.
* config/mips/elf.h (OBJECT_FORMAT_COFF, EXTENDED_COFF): Remove undefs.
	* config/mips/elf64.h: Likewise.
	* config/mips/openbsd.h: Likewise.
	* config/mips/iris5.h (OBJECT_FORMAT_COFF): Remove undefs.
	* config/mips/linux.h: Likewise.
	* config/mips/mips.h (OBJECT_FORMAT_COFF, EXTENDED_COFF): Delete.
	(CODE_MASK, MIPS_IS_STAB, MIPS_MARK_STAB, MIPS_UNMARK_STAB): Delete.

From-SVN: r69346
2003-07-14 20:12:07 +00:00
Richard Sandiford
6627b7f96a config.gcc (mips-sgi-irix6*o32, [...]): Add mips/sdb.h to the list of include files when using gas.
* config.gcc (mips-sgi-irix6*o32, mips-sgi-irix5*): Add mips/sdb.h
	to the list of include files when using gas.
	(mips*el-*-openbsd*, mips*-*-openbsd*): Add mips/sdb.h unconditionally.
	* config/mips/elf.h: Remove #undef SDB_DEBUGGING_INFO.
	* config/mips/elf64.h: Likewise.
	* config/mips/iris5.h: Likewise.
	* config/mips/linux.h: Likewise.
	* config/mips/iris5gas.h (SDB_DEBUGGING_INFO): Remove definition.
	* config/mips/mips.h (PREFERRED_DEBUGGING_TYPE): Likewise.
	(SDB_DEBUGGING_INFO, sdb*, SDB_ALLOW_*, PUT_SDB*): Move to...
	* config/mips/sdb.h: ...this new file.

From-SVN: r69345
2003-07-14 20:09:20 +00:00
Geoffrey Keating
33971b58c3 * lang-specs.h (f77-cpp-input): Use -o to specify the CPP output file.
From-SVN: r69344
2003-07-14 20:03:44 +00:00
Mark Mitchell
5e08432ed0 re PR c++/7019 ([3.3 only] SFINAE does not work with explicitally specified template arguments)
PR c++/7019
	* cp-tree.h (lookup_qualified_name): Adjust prototype.
	* decl.c (lookup_qualified_name): Add complain parameter.  Adjust
	call to is_aggr_type.
	* parser.c (cp_parser_lookup_name): Adjust call to
	lookup_qualified_name.
	* pt.c (tsubst_qualified_id): Likewise.
	(tsubst_copy_and_build): Likewise.
	* semantics.c (finish_qualified_id_expr): Deal with erroneous
	expressions.

	PR c++/7019
	* g++.dg/template/overload2.C: New test.

From-SVN: r69342
2003-07-14 19:05:05 +00:00
Gabriel Dos Reis
19948e32a8 re PR c++/11510 (Error message with operator __imag__ is missing spaces)
PR c++/11510
* call.c (op_error): Properly handle REALPART_EXPR
  and IMAGPART_EXPR.
* error.c (dump_expr): Likewise.

From-SVN: r69340
2003-07-14 17:45:08 +00:00
Nathanael Nerode
c18b00c0d3 [multiple changes]
2003-07-14  Douglas Rupp  <rupp@gnat.com>

	* fixinc/server.c (server_setup): Don't use non-POSIX NULL first
	argument to getcwd; use fixed buffer instead.

2003-07-14  Nathanael Nerode  <neroden@gcc.gnu.org>

	* fixinc/mkfixinc.sh: Treat OpenBSD normally.
	* fixinc/fixinc.wrap: Delete.

From-SVN: r69339
2003-07-14 16:56:03 +00:00
Gabriel Dos Reis
98ed39062b * error.c (dump_expr): Handle EMPTY_CLASS_EXPR.
From-SVN: r69338
2003-07-14 16:09:58 +00:00
Franz Sirl
1b78cca94b re PR rtl-optimization/11440 (gcc-3.3.1 miscompiles c++ code with -O2, -fno-gcse cures it)
2003-07-14  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>

	PR optimization/11440
	* gcc.c-torture/execute/20030714-1.c: New test.

From-SVN: r69334
2003-07-14 16:03:29 +00:00
Gabriel Dos Reis
f19319dbdf re PR c++/5293 (confusing message when binding a temporary to a reference)
PR c++/5293
* call.c (initialize_reference): Improve diagnostic.

From-SVN: r69332
2003-07-14 15:04:32 +00:00
Gerald Pfeifer
adc4adcdaf ggc-page.c (extra_order_size_table): Insns have 9 slots.
* ggc-page.c (extra_order_size_table): Insns have 9 slots. Regs
	don't have 2.

	* ggc-page.c (struct globals): Add new fields to keep track of the
	total allocated memory and overhead.
	(ggc_print_statistics): Print them.
	(ggc_alloc): Keep track of the total allocated memory and the
	overhead.

	* tree.c (dump_tree_statistics): Increase spacing.
	(enum tree_node_kind): Move to ...
	* tree.h (enum tree_node_kind): ... here.
	(tree_node_counts, tree_node_sizes): Declare.

	* doc/include/texinfo.tex: Upgrade to texinfo 4.6.

From-SVN: r69330
2003-07-14 13:36:56 +00:00
Kriang Lerdsuwanakij
55ece1b348 re PR c++/11154 (spurious ambiguity report for template class specialization)
PR c++/11154
	* pt.c (more_specialized_class): Add full_args parameter.
	(most_specialized_class): Adjust calls to more_specialized_class.
	* cp-tree.h (more_specialized_class): Adjust declaration.

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

From-SVN: r69328
2003-07-14 10:48:59 +00:00
Dan Nicolaescu
9a8c9b44cc * lex.c (enum tree_node_kind): Delete.
From-SVN: r69327
2003-07-14 10:14:51 +00:00
Franz Sirl
bbd288a44d re PR rtl-optimization/11440 (gcc-3.3.1 miscompiles c++ code with -O2, -fno-gcse cures it)
2003-07-14  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>

	PR optimization/11440
	* gcse.c (try_replace_reg): Don't attach notes to ZERO_EXTRACT or
	SIGN_EXTRACT SETs.

From-SVN: r69325
2003-07-14 09:29:44 +00:00
Alan Modra
6e98504002 tm.texi (BLOCK_REG_PADDING): Describe.
* doc/tm.texi (BLOCK_REG_PADDING): Describe.
	* expr.h (struct locate_and_pad_arg_data): Add where_pad.
	(emit_group_load, emit_group_store): Adjust declarations.
	Remove most occurrences of #ifdef TREE_CODE.
	* expr.c (emit_group_load): Add "type" param, and use
	BLOCK_REG_PADDING to determine need for a shift.  Optimize non-
	aligned accesses if !SLOW_UNALIGNED_ACCESS.
	(emit_group_store): Likewise.
	(emit_push_insn, expand_assignment, store_expr, expand_expr): Adjust
	emit_group_load and emit_group_store calls.
	* calls.c (store_unaligned_arguments_into_pseudos): Tidy.  Use
	BLOCK_REG_PADDING to determine whether we need endian_correction.
	(load_register_parameters): Localize vars.  Handle shifting of
	small values to the correct end of regs.  Adjust emit_group_load
	call.
	(expand_call, emit_library_call_value_1): Adjust emit_group_load
	and emit_group_store calls.
	* function.c (assign_parms): Set mem alignment for stack slots.
	Adjust emit_group_store call.  Store values at the "wrong" end
	of regs to the stack.  Use BLOCK_REG_PADDING.
	(locate_and_pad_parm): Save where_pad.
	(expand_function_end): Adjust emit_group_load call.
	* stmt.c (expand_value_return): Adjust emit_group_load call.
	* Makefile.in (calls.o): Depend on $(OPTABS_H).
	* config/rs6000/linux64.h (TARGET_LITTLE_ENDIAN): Redefine as 0.
	(AGGREGATE_PADDING_FIXED, AGGREGATES_PAD_UPWARD_ALWAYS): Define.
	(MUST_PASS_IN_STACK): Define.
	(BLOCK_REG_PADDING): Define.
	* config/rs6000/rs6000.h (struct rs6000_args): Remove orig_nargs.
	(PAD_VARARGS_DOWN): Define in terms of FUNCTION_ARG_PADDING.
	* config/rs6000/rs6000.c (init_cumulative_args): Don't set orig_nargs.
	(function_arg_padding): !AGGREGATE_PADDING_FIXED compatibility code.
	Act on AGGREGATES_PAD_UPWARD_ALWAYS.

From-SVN: r69318
2003-07-14 14:47:18 +09:30
Mark Mitchell
a3d8777127 re PR c++/11503 (segfault when instantiating template with ADDR_EXPR)
PR c++/11503
	* g++.dg/template/anon1.C: New test.

	PR c++/11503
	* cp-tree.h (DECL_SELF_REFERENCE_P): New macro.
	(SET_DECL_SELF_REFERENCE_P): Likewise.
	* class.c (build_self_reference): Use SET_DECL_SELF_REFERENCE_P.
	* pt.c (tsubst_decl): Copy it.
	* search.c (lookup_base): Use DECL_SELF_REFERENCE_P.

From-SVN: r69317
2003-07-14 05:12:56 +00:00
Mark Mitchell
b34459943b re PR c++/11493 (tree check ICE in error.c)
* cp-tree.h (cp_id_kind): New type.
	(unqualified_name_lookup_error): Change prototype.
	(unqualified_fn_lookup_error): New function.
	(do_identifier): Remove.
	(do_scoped_id): Likewise.
	(tsubst_copy_and_build): Change prototype.
	(reregister_specialization): New function.
	(perform_koenig_lookup): Likewise.
	(finish_id_expression): Likewise.
	* call.c (build_method_call): Adjust call to
	unqualified_name_lookup_error.
	* decl.c (duplicate_decls): Use reregister_specialization.
	* lex.c (is_global): Remove.
	(unqualified_name_lookup_error): Return a value.
	(do_identifier): Remove.
	(do_scoped_id): Likewise.
	(identifier_typedecl_value): Remove.
	(unqualified_fn_lookup_error): New function.
	* parser.c (cp_parser_id_kind): Remove.
	(cp_parser_non_constant_id_expression): Remove.
	(cp_parser_primary_expression): Use finish_id_expression.
	(cp_parser_class_or_namespace_name): Use cp_id_kind, not
	cp_parser_id_kind.
	(cp_parser_postfix_expression): Use perform_koenig_lookup.
	(cp_parser_template_argument): Use cp_id_kind.
	(cp_parser_fold_non_dependent_expr): Adjust call to
	tsubst_copy_and_build.
	* pt.c (unregister_specialization): Rename to ...
	(reregister_specialization): This.
	(tsubst_friend_function): Use it.
	(maybe_fold_nontype_arg): Adjust call to tsubst_copy_and_build.
	(tsubst_qualified_id): Likewise.
	(tsubst_expr): Likewise.
	(tsubst_copy_and_build): Add function_p parameter.  Use
	finish_id_expression.  Introduce RECUR macro.
	(tsubst_non_call_postfix_expression): New function.
	(regenerate_decl_from_template): Use reregister_specialization.
	* semantics.c (perform_koenig_lookup): New function.
	(finish_id_expression): Likewise.

	PR c++/11493
	PR c++/11495
	* g++.dg/parse/template9.C: Likewise.
	* g++.dg/template/crash4.C: New test.
	* g++.dg/template/koenig1.C: Likewise.
	* g++.old-deja/g++.benjamin/tem03.C: Adjust error markers.
	* g++.old-deja/g++.benjamin/tem06.C: Declare "x".
	* g++.old-deja/g++.jason/overload33.C: Use this-> when calling
	functions.
	* g++.old-deja/g++.jason/template36.C: Likewise.
	* g++.old-deja/g++.mike/p1989.C: Likewise.
	* g++.old-deja/g++.pt/lookup2.C: Use -fpermissive when compiling.
	* g++.old-deja/g++.pt/ttp20.C: Use this->.
	* g++.old-deja/g++.pt/ttp21.C: Use this->.
	* g++.old-deja/g++.pt/typename13.C: Use -fpermissive when
	compiling.
	* g++.old-deja/g++.pt/union2.C: Use this->.

From-SVN: r69316
2003-07-14 03:04:29 +00:00