Commit Graph

17728 Commits

Author SHA1 Message Date
Jason Merrill
c3baf4b55a pt.c (lookup_template_class): Don't mess with the context of the instantiation.
* pt.c (lookup_template_class): Don't mess with the context of the
	instantiation.
	* decl2.c (current_decl_namespace): Remove special handling for
	templates.

From-SVN: r21265
1998-07-17 12:29:25 -04:00
Richard Henderson
402cdad5e7 alloca.c: Respect USE_C_ALLOCA.
* alloca.c: Respect USE_C_ALLOCA.
        * gencheck.c (xmalloc): Ignore __GNUC__ for definition.
        * gengenrtl.c (xmalloc): Likewise.

From-SVN: r21264
1998-07-17 08:00:11 -07:00
Richard Henderson
45f97e2e08 loop.h (struct induction): Add no_const_addval.
* loop.h (struct induction): Add no_const_addval.
        * loop.c (the_movables, reg_address_cost): New variables.
        (init_loop): Init reg_address_cost.
        (loop_optimize): Call end_alias_analysis.
        (scan_loop): Init the_movables.
        (record_giv): Init induction->no_const_addval.
        (basic_induction_var) [PLUS]: Use rtx_equal_p instead of ==.
        [REG]: Rearrange loop search test to catch more cases.
        (general_induction_var): Return success not benefit; take an extra
        argument for that.  Change all callers.
        (simplify_giv_expr) [PLUS]: Always combine invariants.  Use sge_plus.
        [MULT]: Use rtx_equal_p instead of ==.  Combine simple invariants.
        [default]: Search the_movables for additional combinations.
        (sge_plus_constant, sge_plus): New functions.
        (express_from_1): New function.
        (express_from): Always define.  Rewrite using express_from_1.
        (combine_givs_p): Handle more cases.  Ignore address cost.
        (cmp_combine_givs_stats): New function.
        (combine_givs_used_once, combine_givs_benefit_from): New functions.
        (combine_givs): Rewrite to do best-fit combination.
        * fold-const.c (operand_equal_p): Handle RTL_EXPR.
        (fold): Do a complete (A*C)+(B*C) association check.

From-SVN: r21263
1998-07-17 07:46:06 -07:00
Nick Clifton
d4c011bca5 mark as expected failure
From-SVN: r21262
1998-07-17 14:20:47 +00:00
Jim Wilson
07362cb321 Fix some sparc complex testsuite failures.
* function.c (fixup_var_refs_insns): Handle CLOBBER of a CONCAT.

From-SVN: r21251
1998-07-17 04:22:40 -07:00
Jeffrey A Law
2fed503d0e * mn10300.c (MODES_TIEABLE_P): Fix typo.
From-SVN: r21249
1998-07-17 04:53:58 -06:00
Jason Merrill
c5a6fc4557 pt.c (tsubst, [...]): Fix getting complete args for a member template specialization.
* pt.c (tsubst, case FUNCTION_DECL): Fix getting complete args for
	a member template specialization.
	* tree.c (ovl_member): Use decls_match to compare functions.
	* decl.c (decls_match): Check the context of a function.

From-SVN: r21248
1998-07-17 02:19:07 -04:00
Richard Earnshaw
f022f9bcfc tree.c (valid_machine_attribute): Only create a new type variant if there is a decl to use it.
* tree.c (valid_machine_attribute): Only create a new type variant if
there is a decl to use it.

From-SVN: r21247
1998-07-17 03:34:34 +00:00
Jason Merrill
03d8299153 parse.y (primary): Use notype_unqualified_id instead of IDENTIFIER in Koenig lookup support rules.
* parse.y (primary): Use notype_unqualified_id instead of IDENTIFIER
	in Koenig lookup support rules.
	* semantics.c (finish_call_expr): Handle the new cases.
	* typeck.c (build_x_function_call): Handle overloaded methods.
	* decl.c (grokvardecl): Don't call build_static_name for extern "C".

From-SVN: r21245
1998-07-16 22:48:08 -04:00
Jason Merrill
32dd8ef8f3 tmap.cc: Use less<int>.
* tmap.cc: Use less<int>.
	* tlist.cc (main): Use remove_if.

From-SVN: r21244
1998-07-16 21:30:01 -04:00
Jeff Law
2768c658b0 Daily bump.
From-SVN: r21241
1998-07-16 18:45:02 -06:00
Mark Mitchell
c68c56f727 semantics.c (finish_object_call_expr): Revert previous change.
1998-07-16  Mark Mitchell  <mark@markmitchell.com>
	* semantics.c (finish_object_call_expr): Revert previous change.
	* call.c (build_new_method_call): Likewise.  Instead, convert
	TYPE_DECLs to IDENTIFIERs here, in the presence of templates.

From-SVN: r21240
1998-07-16 23:38:43 +00:00
Jeff Law
b5044593c9 (ffecom_finish_symbol_transform_): Revert change of 1998-05-23...
* (ffecom_finish_symbol_transform_): Revert change
	of 1998-05-23, as it was too aggressive, in that it
	prevented transformation of (used) functions before
	primary code generation.

From-SVN: r21236
1998-07-16 16:53:02 -06:00
Craig Burley
c30922357a (ffecom_finish_symbol_transform_): Revert change of 1998-05-23...
d
	* (ffecom_finish_symbol_transform_): Revert change
	of 1998-05-23, as it was too aggressive, in that it
	prevented transformation of (used) functions before
	primary code generation.

From-SVN: r21235
1998-07-16 16:53:01 -06:00
Craig Burley
75750f9c8a (ffecom_finish_symbol_transform_): Revert change of 1998-05-23...
�
	* (ffecom_finish_symbol_transform_): Revert change
	of 1998-05-23, as it was too aggressive, in that it
	prevented transformation of (used) functions before
	primary code generation.

From-SVN: r21234
1998-07-16 16:52:59 -06:00
Jeff Law
db7fe2273c Updates from craig.
From-SVN: r21233
1998-07-16 16:51:15 -06:00
Nick Clifton
1ccb8f57d5 gcc.c (do_spec_1): Cope with %g/%u/%U options which do not have a suffix.
8
	* gcc.c (do_spec_1): Cope with %g/%u/%U options which do not have
	a suffix.

From-SVN: r21229
1998-07-16 16:45:49 -06:00
Nick Clifton
4249dc2be3 gcc.c (do_spec_1): Cope with %g/%u/%U options which do not have a suffix.
�
	* gcc.c (do_spec_1): Cope with %g/%u/%U options which do not have
	a suffix.

From-SVN: r21228
1998-07-16 16:45:47 -06:00
Jeffrey A Law
0752c0eaad * libU77/Makefile.in: Missed one config.h.in -> config.hin change.
From-SVN: r21224
1998-07-16 15:33:58 -06:00
Jason Merrill
9ed182dca4 decl.c (qualify_lookup): Handle templates.
* decl.c (qualify_lookup): Handle templates.
	* decl2.c (do_using_directive): Don't pass ancestor.
	* decl.c (push_using_directive): Calculate ancestor.
	* decl2.c (do_nonmember_using_decl): Allow for type shadowing.
	* decl.c (pushdecl): Move type shadowing handling from here...
	(duplicate_decls): ...to here.
	* decl.c (set_identifier_local_value_with_scope): New fn.
	(pushdecl): Use it.
	(set_identifier_local_value, lookup_type_current_level): New fns.
	* decl2.c (do_local_using_decl): Handle types and binding level
	stuff properly.

From-SVN: r21223
1998-07-16 17:16:06 -04:00
Jeffrey A Law
3cab3dc87e * gcc.c-torture/execute/980716-1.c: New test.
From-SVN: r21222
1998-07-16 14:47:24 -06:00
Hans-Peter Nilsson
8d344fbc71 extend.texi (Explicit Reg Vars): Typo: change "may deleted" into "may be deleted"
(
	* extend.texi (Explicit Reg Vars): Typo: change "may deleted" into "may
	be deleted"

From-SVN: r21221
1998-07-16 14:00:57 -06:00
Hans-Peter Nilsson
1865108319 extend.texi (Explicit Reg Vars): Typo: change "may deleted" into "may be deleted"
* extend.texi (Explicit Reg Vars): Typo: change "may deleted" into "may
	be deleted"

From-SVN: r21220
1998-07-16 14:00:55 -06:00
Jason Merrill
1c35f5b6a0 init.c (build_offset_ref): Don't call mark_used on an OVERLOAD.
* init.c (build_offset_ref): Don't call mark_used on an OVERLOAD.
	* decl.c (select_decl): Extract a lone function from an OVERLOAD.
	(lookup_namespace_name): Likewise.
	* typeck.c (build_unary_op): Not here anymore.
	* decl2.c (do_class_using_decl): Make sure we get an identifier.
	* class.c (handle_using_decl): Ignore TYPE_DECLs.

From-SVN: r21219
1998-07-16 13:48:39 -04:00
Jason Merrill
52c11ef6a3 decl.c (qualify_lookup): New fn.
* decl.c (qualify_lookup): New fn.
	(lookup_name_real): Use it.
	* decl2.c (add_using_namespace): When directly using a namespace
	that was indirect before, promote it.
	* cp-tree.h (LOOKUP_PREFER_TYPES, LOOKUP_PREFER_NAMESPACES,
	LOOKUP_PREFER_BOTH, LOOKUP_NAMESPACES_ONLY, LOOKUP_TYPES_ONLY,
	LOOKUP_QUALIFIERS_ONLY, LOOKUP_TEMPLATES_EXPECTED): New macros.
	* decl.c (select_decl): Replace two flag parameters by one.
	(unqualified_namespace_lookup): Likewise, pass flag.
	(lookup_flags): New function.
	(lookup_name_real): Compute flags, pass them.
	(lookup_namespace_name): Call with zero-flag.
	* decl2.c (ambiguous_decl): Add flag parameter, complain only
	according to flags.
	(lookup_using_namespace, qualified_lookup_using_namespace):
	Add flag parameter, pass them through.
	* lex.c (do_scoped_id): Call with zero-flag.

From-SVN: r21218
1998-07-16 12:38:26 -04:00
Jason Merrill
a942e89c9a * typeck.c (convert_for_assignment): Use comptypes.
From-SVN: r21216
1998-07-16 11:02:05 -04:00
Jeffrey A Law
6673b2ea6a mn10300.c (count_tst_insns): New arg oreg_countp.
* mn10300.c (count_tst_insns): New arg oreg_countp.  Callers changed.
        Simplify tests for clearing an address register.
        (expand_prologue): Corresponding changes.

From-SVN: r21215
1998-07-16 08:10:24 -06:00
Jeffrey A Law
fed2012bae mn10300.md (movXX patterns): Make sure the destination is an ADDRESS_REG when...
* mn10300.md (movXX patterns): Make sure the destination is an
        ADDRESS_REG when substituting "zero_areg" for (const_int 0).
        (logical patterns): Split into expanders + patterns
        (zero and sign extension patterns): Similarly.
        (shift patterns): Similarly.

From-SVN: r21214
1998-07-16 07:54:53 -06:00
Mark Mitchell
52889bc818 semantics.c (finish_object_call_expr): Move test for the function called being a TYPE_DECL to ...
1998-07-16  Mark Mitchell  <mark@markmitchell.com>
	* semantics.c (finish_object_call_expr): Move test for the
	function called being a TYPE_DECL to ...
	* call.c (build_new_method_call): Here.

From-SVN: r21213
1998-07-16 11:46:44 +00:00
Martin v. Löwis
439041b917 New test case.
From-SVN: r21212
1998-07-16 01:07:25 +00:00
Jeff Law
e00a24fa25 Daily bump.
From-SVN: r21211
1998-07-15 18:45:02 -06:00
Richard Henderson
00116a7b6d loop.c (emit_iv_add_mult): Scan the entire insn list generated for the sequence, recording base values.
8
        * loop.c (emit_iv_add_mult): Scan the entire insn list generated
        for the sequence, recording base values.

From-SVN: r21208
1998-07-15 18:22:41 -06:00
Richard Henderson
a2d926467c loop.c (emit_iv_add_mult): Scan the entire insn list generated for the sequence, recording base values.
�
        * loop.c (emit_iv_add_mult): Scan the entire insn list generated
        for the sequence, recording base values.

From-SVN: r21207
1998-07-15 18:22:39 -06:00
Jason Merrill
00dc635853 decl2.c (arg_assoc_class): Also look at template arguments, if any.
* decl2.c (arg_assoc_class): Also look at template arguments, if any.
	(arg_assoc): Handle error_mark_node and multiple levels of TREE_LIST.
	* lex.c (looking_for_typename): Don't initialize.
	* decl2.c (ambiguous_decl): Clarify error message.
	* decl.c (push_using_directive): Iterate over namespaces used
	indirectly.

From-SVN: r21205
1998-07-15 20:16:25 -04:00
Jeffrey A Law
e3a0385963 g2c.hin: Renamed from g2c.h.in.
* g2c.hin: Renamed from g2c.h.in.
        * Makefile.in, configure.in: Changed as needed.
        * configure: Rebuilt.
        * libU77/config.hin: Renamed from libU77/config.h.in.
        * Makefile.in, configure.in: Changed as needed.
        * configure: Rebuilt.

From-SVN: r21202
1998-07-15 18:07:42 -06:00
Martin v. Löwis
85c6cbaf2d decl2.c (add_using_namespace): Iterate over namespaces used indirectly.
* decl2.c (add_using_namespace): Iterate over namespaces used
	indirectly.
	* decl.c (lookup_name_real): Accept namespace aliases as locals.
	(cat_namespace_levels): Ignore aliases.
	(duplicate_decls): Ignore duplicate aliases.
	* decl2.c (do_namespace_alias): Process block level namespace
	aliases. Store alias with pushdecl. Remove odr errors.
	* parse.y (namespace_alias): New non-terminal.
	(extdef): Use it.

From-SVN: r21201
1998-07-15 13:27:24 -04:00
Jason Merrill
2d39086779 decl2.c (arg_assoc_type): Handle METHOD_TYPE like FUNCTION_TYPE.
* decl2.c (arg_assoc_type): Handle METHOD_TYPE like FUNCTION_TYPE.
	Handle TEMPLATE_TYPE_PARM.
	(arg_assoc): Rewrite.

From-SVN: r21199
1998-07-15 12:56:50 -04:00
Martin v. Löwis
2d2ad82da4 Add aliases in nested blocks
From-SVN: r21197
1998-07-15 14:38:06 +00:00
Jason Merrill
2077e863e2 pt.c (complete_template_args): Don't look at the context unless we have to.
* pt.c (complete_template_args): Don't look at the context unless
	we have to.

From-SVN: r21195
1998-07-15 10:21:35 -04:00
Martin v. Löwis
8d9eb1141f New test case.
From-SVN: r21194
1998-07-15 12:17:53 +00:00
Craig Burley
34d1a71f0c Make-lang.in (f77.rebuilt): Fix to depend on build-dir-based, not source-based, g77.info.
Mon Jul 13 18:45:06 1998  Craig Burley  <burley@gnu.org>
	* Make-lang.in (f77.rebuilt): Fix to depend on
	build-dir-based, not source-based, g77.info.
	* g77.texi: Merge docs with 0.5.24.
	* g77install.texi: Ditto.

From-SVN: r21192
1998-07-15 11:39:21 +00:00
Dave Love
a1d80b3eaa intdoc.texi: Regenerated.
1998-07-15  Dave Love  <d.love@dl.ac.uk>
	* intdoc.texi: Regenerated.

From-SVN: r21191
1998-07-15 11:38:08 +00:00
Dave Love
57a159354a Update from Craig, previously missed.
From-SVN: r21187
1998-07-15 11:05:36 +00:00
Richard Henderson
5d46457efa * i386.h (CPP_CPU_SPEC): Remove -Asystem(unix).
From-SVN: r21186
1998-07-15 03:50:48 -07:00
Martin v. Löwis
421ec9a741 New test case.
From-SVN: r21180
1998-07-15 07:58:24 +00:00
Dave Love
2cc6777c6b Changes from Craig.
From-SVN: r21179
1998-07-15 07:19:13 +00:00
Craig Burley
9a59ff4f47 Make-lang.in (f77.rebuilt): Fix to depend on build-dir-based, not source-based, g77.info.
Mon Jul 13 18:45:06 1998  Craig Burley  <burley@gnu.org>
	* Make-lang.in (f77.rebuilt): Fix to depend on
	build-dir-based, not source-based, g77.info.
	* g77.texi: Merge docs with 0.5.24.
	* g77install.texi: Ditto.

From-SVN: r21178
1998-07-15 07:15:52 +00:00
Craig Burley
4801aa8f37 Cleanups vis-a-vis g77-0.5.24:
Mon Jul 13 18:02:29 1998  Craig Burley  <burley@gnu.org>
	Cleanups vis-a-vis g77-0.5.24:
	* g77spec.c (lang_specific_driver): Tabify source.
	* top.c (ffe_decode_option): Use fixed macro to set
	internal-checking flag.
	* top.h (ffe_set_is_do_internal_checks): Fix macro.

From-SVN: r21177
1998-07-15 07:13:43 +00:00
Craig Burley
207ff633fe Cleanups vis-a-vis system.h cutover and g77-0.5.24:
Mon Jul 13 17:33:44 1998  Craig Burley  <burley@gnu.org>
	Cleanups vis-a-vis system.h cutover and g77-0.5.24:
	* Makefile.in (fini.o): Define USE_HCONFIG macro
	so source code doesn't have to.
	* fini.c: Don't define USE_HCONFIG here, since
	source code usually shouldn't care about this.
	* ansify.c: Include stddef.h only if we have it.
	* intdoc.c: Ditto.
	* proj.h: Ditto.

From-SVN: r21176
1998-07-15 07:07:55 +00:00
Jason Merrill
268775847c method.c (build_decl_overload_real): Fix namespace handling.
* method.c (build_decl_overload_real): Fix namespace handling.
	* typeck.c (build_unary_op): Extract a lone function from an
	OVERLOAD.
	* call.c (build_scoped_method_call): Handle getting a namespace
	for basetype in a destructor call.
	(check_dtor_name): Handle enums.
	* parse.y (using_directive): New nonterminal.
	(extdef, simple_stmt): Use it.

From-SVN: r21174
1998-07-15 00:38:53 -04:00