Commit Graph

24471 Commits

Author SHA1 Message Date
Nathan Sidwell
9e93bc9dcc Augment stringification of trees.
* cp-tree.h (tree_string_flags): New error stringifying enumeration.
	(fndecl_as_string, type_as_string_real, args_as_string,
	code_as_string, language_as_string, parm_as_string,
	op_as_string, assop_as_string, cv_as_string): Remove.
	(type_as_string, decl_as_string, expr_as_string): Adjust prototype.
	(context_as_string): Declare new function.
	* error.c (cp_printers): Move definition.
	(OB_UNPUT): Remove.
	(OB_END_TEMPLATE_ID): Adjust.
	(interesting_scope_p): Remove.
	(dump_scope): New static function.
	(dump_qualifiers): Adjust prototype, reimplement.
	(dump_template_value): Use tree_string_flags.
	(dump_type_real): Move back to dump_type.
	(dump_type): Adjust prototype. Use tree_string_flags.
	(dump_aggr_type): Likewise. Use dump_template_parms.
	(dump_type_prefix): Adjust prototype. Use tree_string_flags. Return pad flag.
	(dump_type_suffix): Adjust prototype. Use tree_string_flags.
	(dump_simple_decl): Likewise.
	(dump_decl): Likewise. Use dump_template_decl.
	(dump_template_decl): New static function broken out of dump_decl.
	(dump_function_decl): Adjust prototype. Use tree_string_flags.
	(dump_parameters): Likewise. Prefix space.
	(dump_exception_spec): Adjust prototype. Use tree_string_flags.
	(dump_function_name): Likewise. Use dump_template_parms.
	(dump_template_parms): New static function broken out of
	dump_function_name.
	(dump_expr_list): Adjust prototype. Use tree_string_flags.
	(dump_expr): Likewise.
	(fndecl_as_string): Removed
	(type_as_string_real): Removed
	(dump_binary_op): Adjust prototype. Use tree_string_flags.
	(dump_unary_op): Likewise.
	(type_as_string): Likewise.
	(expr_as_string): Likewise.
	(decl_as_string): Likewise.
	(context_as_string): New function.
	(lang_decl_name): Adjust.
	(decl_to_string): New static print callback.
	(expr_to_string): Likewise.
	(fndecl_to_string): Likewise.
	(code_as_string): Renamed to ...
	(code_to_string): ... here. Adjust.
	(language_as_string): Renamed to ...
	(language_to_string): ... here. Adjust.
	(parm_as_string): Renamed to ...
	(parm_to_string): ... here.
	(op_as_string): Renamed to ...
	(op_to_string): ... here.
	(assop_as_string): Renamed to ...
	(assop_to_string): ... here.
	(type_to_string): New static print callback.
	(args_as_string): Renamed to ...
	(args_to_string): ... here. Adjust.
	(cv_as_string): Renamed to ...
	(cv_to_string): ... here. Adjust.
	* pt.c (mangle_class_name_for_template): Use tree_string_flags.
	(print_template_context): Likewise.

From-SVN: r29673
1999-09-27 08:26:00 +00:00
Jeff Law
cf9d61d569 Daily bump.
From-SVN: r29672
1999-09-27 01:45:12 -06:00
Mark Mitchell
59ccf49da3 cp-tree.h (expand_throw): Remove prototype.
* cp-tree.h (expand_throw): Remove prototype.
	* except.c (expand_throw): Make it static.  Use tree-generation
	functions, rather than RTL-generation functions.
	(build_throw): Use it.
	* expr.c: Include except.h.
	(cplus_expand_expr): Don't call expand_throw here.
	* Makefile.in (expr.o): Depend on except.h.
	* ir.texi: Update documentation for THROW_EXPR.

	* decl.c (start_function): Set x_dont_save_pending_sizes rather
	than calling get_pending_sizes.
	* init.c (build_new): Don't save and restore
	immediate_size_expand; instead, assert that it has the expected
	value already.

From-SVN: r29671
1999-09-27 01:27:18 +00:00
Robert Lipe
bfcccecc56 dgux.h (SELECT_RTX_SECTION): Provide dummy argument for symbolic_operand().
* config/i386/dgux.h (SELECT_RTX_SECTION): Provide dummy argument
	for symbolic_operand().
	* config/i386/sco5.h (SELECT_RTX_SECTION): Likewise.

From-SVN: r29670
1999-09-26 21:43:48 +00:00
Mark Mitchell
2aa3110af4 decl.c (start_function): Set x_dont_save_pending_sizes rather than calling get_pending_sizes.
* decl.c (start_function): Set x_dont_save_pending_sizes rather
	than calling get_pending_sizes.
	* init.c (build_new): Don't save and restore
	immediate_size_expand; instead, assert that it has the expected
	value already.

From-SVN: r29669
1999-09-26 18:16:47 +00:00
Mark Mitchell
d43163b742 function.h (struct function): Add x_dont_save_pending_sizes_p.
* function.h (struct function): Add x_dont_save_pending_sizes_p.
	* stor-layout.c (variable_size): Don't add sizes to the pending
	sizes list if x_dont_save_pending_sizes_p is set.

From-SVN: r29668
1999-09-26 18:13:28 +00:00
Kaveh R. Ghazi
f0305a2b79 combine.c (gen_rtx_combine): Add missing call to va_end().
* combine.c (gen_rtx_combine): Add missing call to va_end().

	* final.c (asm_fprintf): Likewise.

	* genattrtab.c (attr_rtx): Likewise.

cp:
	* lex.c (compiler_error): Add missing call to va_end().

From-SVN: r29667
1999-09-26 11:40:53 +00:00
Jeff Law
4e32193ac9 Daily bump.
From-SVN: r29666
1999-09-26 01:45:09 -06:00
Jeffrey A Law
e48a7fbe7b cse.c: Update comments.
* cse.c: Update comments.
        (cse_insn): When converting a conditional/computed jump into
        an unconditional jump, always make sure a BARRIER immediately
        follows the converted jump.  Do not delete unreachable code.
        (cse_basic_block): Do not delete unreachable code.
        * toplev.c (rest_of_compilation): Move call to
        delete_trivially_dead_insns after the conditional call to
        jump_optimize.

From-SVN: r29665
1999-09-25 13:13:18 -06:00
Mark Mitchell
57151693bc dump.c (dequeue_and_dump): Handle RESULT_DECL.
* dump.c (dequeue_and_dump): Handle RESULT_DECL.
	* ir.texi: Document RESULT_DECL and DECL_RESULT.

From-SVN: r29664
1999-09-25 18:16:08 +00:00
Mark Mitchell
efee38a99a cp-tree.h (check_return_expr): New function.
* cp-tree.h (check_return_expr): New function.
	* decl.c (finish_constructor_body): New function.
	(pushdecl): Put global friend functions in namespace binding
	level, not the class binding level.
	(finish_destructor_body): Make sure the dtor_label is always
	defined.  Fix typo in comment.
	(finish_function): Move generation of constructor-termination code
	to semantic-analysis time.  Move generation of implicit `main'
	return value to semantic-analysis time.
	* semantics.c (finish_return_stmt): Generate goto's to
	ctor_label/dtor_label here.  Use check_return_expr to do semantic
	analysis on the returned expression.
	* typeck.c (maybe_warn_about_returning_address_of_local): New
	function split out from c_expand_return.
	(check_return_expr): Likewise.
	(c_expand_return): Just generate the RTL for the return.

From-SVN: r29663
1999-09-25 18:10:04 +00:00
Kaveh R. Ghazi
5a657fc371 libiberty.h (make_temp_file): Add a prototype.
include:

        * libiberty.h (make_temp_file):  Add a prototype.

libiberty:

        * choose-temp.c: Remove obsolete comment about gcc.
        (make_temp_file): Constify a char*.

gcc:

        * collect2.c (make_temp_file): Don't prototype.

        * gcc.c (make_temp_file): Likewise.

        * mips.c (mips_make_temp_file): Renamed from `make_temp_file'.

From-SVN: r29662
1999-09-25 13:11:17 +00:00
Nick Clifton
b869419595 Tidy up assemble_variable()'s handling of uninitialised varaibles.
From-SVN: r29661
1999-09-25 12:45:09 +00:00
Jeff Law
74d3e96a60 Daily bump.
From-SVN: r29660
1999-09-25 01:45:09 -06:00
Mark Mitchell
b3ab27f3c3 cp-tree.h (CPTI_CLEANUP_TYPE): New macro.
* cp-tree.h (CPTI_CLEANUP_TYPE): New macro.
	(cleanup_type): Likewise.
	(search_tree): Change prototype.
	* decl.c (local_variable_p): Adjust for new interface to
	search_tree.
	(check_default_argument): Likewise.
	* error.c (dump_expr): Handle INIT_EXPR.
	* except.c (expand_throw): Don't make cleanup_type a local static.
	* expr.c (cplus_expand_expr): Don't handle NEW_EXPR.
	* init.c (build_new): Call build_new_1 directly, rather than
	building a NEW_EXPR.
	(build_new_1): Tidy.  Don't build a VEC_INIT_EXPR except when
	processing file-scope initializers.
	* lex.c (init_parse): Add an opname_tab entry for INIT_EXPR.
	* tree.c: Include splay-tree.h
	(no_linkage_helper): Adjust for new interface to search_tree.
	(search_tree): Pass around pointers to tree nodes, rather than the
	nodes themselves.  Handle VEC_INIT_EXPR.
	(no_linkage_check): Adjust for new interface to search_tree.
	(mapcar): Handle VEC_INIT_EXPR.
	(target_remap): New variable.
	(bot_manip): Use it.
	(bot_replace): New function.
	(break_out_target_exprs): Use it to remap all variables used in a
	default argument expression.
	* typeck.c (build_modify_expr): Don't crash when outside a
	function and presented with an INIT_EXPR assignment
	* Makefile.in (tree.o): Depend on splay-tree.h.

From-SVN: r29659
1999-09-24 20:54:08 +00:00
Glenn Chambers
d353a00cf3 Changed credit to the right person.
From-SVN: r29658
1999-09-24 12:33:23 -07:00
Glenn Chambers
ca6c74893b decl.c (insert_block): Removed unconditional `abort'.
Fri Sep 24 12:23:05 1999  Alexandre Petit-Bianco  <apbianco@cygnus.com>

	* decl.c (insert_block): Removed unconditional `abort'.

From-SVN: r29657
1999-09-24 12:24:19 -07:00
Tom Tromey
98e7ae2962 re GNATS java.util/47 (Date.toString() returns embedded newline)
Fix for PR java.util/47:
	* configure, include/config.h: Rebuilt.
	* configure.in: Don't look for ctime or ctime_r.
	* Makefile.in: Rebuilt.
	* Makefile.am (nat_source_files): Don't mention natDate.cc.
	* java/util/natDate.cc: Removed.
	* java/util/TimeZone.java (tzIDs, rawOffsets, timeZones): New
	static fields.
	(getAvailableIDs): Rewrote.
	(getTimeZone): Rewrote.
	* java/util/Date.java (toGMTString): New method.
	(toLocaleString): New method.
	(toString): Rewrote.

From-SVN: r29656
1999-09-24 19:12:23 +00:00
Nick Clifton
aaaec1142d Cope with down shifting a 32 bit constant on a 64 bit host.
From-SVN: r29655
1999-09-24 16:12:44 +00:00
Jeff Law
0a16ce6f50 Make Pmode be defined in terms of word_mode again now that emit-rtl.c
has been fixed.

From-SVN: r29654
1999-09-24 09:39:31 -06:00
Bernd Schmidt
26db82d823 Allow to distinguish between three classes of builtin functions
From-SVN: r29653
1999-09-24 10:07:04 +00:00
Mark Mitchell
fd903acc80 * optabs.c (init_traps): Fix typo in last change.
From-SVN: r29652
1999-09-24 08:40:11 +00:00
Mark Mitchell
ef6748cb70 * toplev.c (rest_of_decl_compilation): Update comment.
From-SVN: r29651
1999-09-24 08:05:28 +00:00
Mark Mitchell
f39ee88428 decl.c (pushdecl): Don't make local declarations of extern variables give the variable a...
* decl.c (pushdecl): Don't make local declarations of extern
	variables give the variable a DECL_CONTEXT for the function.
	(make_rtl_for_nonlocal_decl): Don't fuss with obstacks.  Simplify.
	Don't accidentally make RTL for local declarations.
	(emit_local_var): Handle declarations with asm-specifiers here.

From-SVN: r29650
1999-09-24 08:03:42 +00:00
Jeff Law
d2cd3d9fca Daily bump.
From-SVN: r29649
1999-09-24 01:45:16 -06:00
Geoff Keating
cc8f5ec081 elf.h (ASM_OUTPUT_ALIGNED_BSS): Put the symbol in .sbss if appropriate.
* config/mips/elf.h (ASM_OUTPUT_ALIGNED_BSS): Put the symbol
in .sbss if appropriate.
(EXTRA_SECTION_FUNCTIONS): Add sbss.
(SBSS_SECTION_ASM_OP): New macro.
* config/mips/linux.h (EXTRA_SECTION_FUNCTIONS): Add sbss.
(EXTRA_SECTIONS): Add in_sbss.
* config/mips/mips.h: Prototype sbss_section.

From-SVN: r29648
1999-09-24 02:01:08 +00:00
Mark Mitchell
8d54f0f03b ir.texi: Improve documentation for TARGET_EXPRs.
* ir.texi: Improve documentation for TARGET_EXPRs.  Discuss
	STMT_IS_FULL_EXPR_P.

From-SVN: r29647
1999-09-24 01:43:49 +00:00
Mark Mitchell
914653a2a7 cp-tree.h (language_function): Add cannot_inline.
* cp-tree.h (language_function): Add cannot_inline.
	* decl.c (start_function): Restore current_function_cannot_inline
	from the saved value.
	(save_function_data): Save current_function_cannot_inline.
	* decl2.c (start_objects): Change prototype.  Build the function
	in function-at-a-time mode.
	(finish_objects): Likewise.
	(generate_ctor_or_dtor_function): Adjust accordingly.

From-SVN: r29646
1999-09-24 01:29:29 +00:00
Mark Mitchell
0fa5e05c2f cp-tree.h (DECL_ANON_UNION_ELEMS): New macro.
* cp-tree.h (DECL_ANON_UNION_ELEMS): New macro.
	* decl2.c (finish_anon_union): Set DECL_ANON_UNION_ELEMS.
	Don't call expand_anon_union_decl here
	* semantics.c (exapnd_stmt): Call it here, instead.
	* typeck.c (mark_addressable): Addressed variables are implicitly
	used.

From-SVN: r29645
1999-09-24 01:17:29 +00:00
Mark Mitchell
a571f7a00e stmt.c (expand_start_bindings): Don't allow cleanup isntructions to disappear.
* stmt.c (expand_start_bindings): Don't allow cleanup isntructions
	to disappear.

From-SVN: r29644
1999-09-24 01:14:54 +00:00
Mark Mitchell
541b0512b1 * optabs.c (init_traps): Register trap_rtx as a GC root.
From-SVN: r29643
1999-09-24 01:03:58 +00:00
Martin v. Löwis
da8a66fc9f cp-tree.h (VAR_OR_FUNCTION_DECL_CHECK): New macro.
* cp-tree.h (VAR_OR_FUNCTION_DECL_CHECK): New macro.
	(RECORD_OR_UNION_TYPE_CHECK, LANG_IDENTIFIER_CAST): Likewise.
	(DEFARG_NODE_CHECK): Remove; replace with DEFAULT_ARG_CHECK.
	* cp-tree.h: Add tree checking macros to various tree access
	macros.
	* ptree.c (print_lang_decl): Test for function or variable
	before accessing template info.

From-SVN: r29642
1999-09-23 22:20:08 +00:00
Alexandre Oliva
48f45f57fc mips.c (function_arg_pass_by_reference): Define unconditionally, since it's called unconditionally.
* config/mips/mips.c (function_arg_pass_by_reference): Define
unconditionally, since it's called unconditionally.

From-SVN: r29641
1999-09-23 21:42:45 +00:00
Jason Merrill
3e37bef596 document -fshort-wchar
From-SVN: r29640
1999-09-23 17:19:09 -04:00
Jason Merrill
5096c664f7 lex.c: Get WCHAR_TYPE_SIZE from wchar_type_node.
* lex.c: Get WCHAR_TYPE_SIZE from wchar_type_node.
	* lang-specs.h: If -fshort-wchar, override __WCHAR_TYPE__.
	* decl2.c (lang_f_options): Add -fshort-wchar.
	* cp-tree.h: Declare flag_short_wchar.
	* decl.c (init_decl_processing): If -fshort-wchar, use 'short unsigned
	int' for wchar_t.

From-SVN: r29639
1999-09-23 17:04:10 -04:00
Jason Merrill
12a39b1264 toplev.c (documented_lang_options): Add -fshort-wchar.
* toplev.c (documented_lang_options): Add -fshort-wchar.
	* c-decl.c (c_decode_option): Likewise.
	(init_decl_processing): If -fshort-wchar, use 'short unsigned int'
	for wchar_t.
	* c-common.c, c-lex.c: Get WCHAR_TYPE_SIZE from wchar_type_node.
	* gcc.c (default_compilers): If -fshort-wchar,
	override __WCHAR_TYPE__.
	* tm.texi (C Dialect Options): Add -fshort-wchar.

From-SVN: r29638
1999-09-23 17:03:53 -04:00
Jason Merrill
e689ae6725 dwarf2out.c (output_aranges): Use DW_AT_location to find the symbol for a variable.
* dwarf2out.c (output_aranges): Use DW_AT_location to find the
	symbol for a variable.

From-SVN: r29637
1999-09-23 16:51:06 -04:00
Jason Merrill
c857e3b470 * cpplib.h (CPP_PREPROCESSED): New macro.
From-SVN: r29636
1999-09-23 16:40:51 -04:00
Alex Samuel
43fa63024d Fix PA problem in order of initializations.
* emit-rtl.c (init_emit_once): Initialize modes first.

        Also add missing ChangeLog entry.

From-SVN: r29635
1999-09-23 20:34:19 +00:00
Jason Merrill
e6ad5e9044 cpplib.c (handle_directive): Don't complain about `# NUMBER' if we're seeing this input for a second time.
* cpplib.c (handle_directive): Don't complain about `# NUMBER' if
	we're seeing this input for a second time.

From-SVN: r29634
1999-09-23 16:28:40 -04:00
Richard Henderson
d180395111 Revert unintended GGC change.
From-SVN: r29633
1999-09-23 13:07:28 -07:00
Alex Samuel
21341cfd7f ggc-page.c: New file.
* ggc-page.c: New file.
        * Makefile.in (ggc-page.o): New.

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

From-SVN: r29632
1999-09-23 13:00:57 -07:00
Jeffrey A Law
b6d24183df invoke.texi: Document -fdelete-null-pointer-checks
* invoke.texi: Document -fdelete-null-pointer-checks
        * toplev.c (flag_delete_null_pointer_checks): New.
        (f_options): Add entry for -fdelete-null-pointer-checks.
        (rest_of_compilation): Conditionalize null pointer check
        elimination on flag_delete_null_pointer_checks.
        (main): If -O2 or greater, enable -fdelete-null-pointer-checks

From-SVN: r29631
1999-09-23 13:57:50 -06:00
Tom Tromey
0cffaca32c jvspec.c (lang_specific_driver): Don't read spec file if -fsyntax-only given.
* jvspec.c (lang_specific_driver): Don't read spec file if
	-fsyntax-only given.

From-SVN: r29630
1999-09-23 19:45:39 +00:00
Jeff Law
dbe519e013 Should have been checked in with Kingdon's change.
From-SVN: r29629
1999-09-23 13:41:04 -06:00
Tom Tromey
8cd098069c configure: Rebuilt.
* configure: Rebuilt.
	* configure.in: Print message when checking to see if gcj can
	handle -fuse-divide-subroutine.

From-SVN: r29628
1999-09-23 19:38:11 +00:00
Jeff Law
2bcb4e7661 Fix typo in yesterday's massive change.
From-SVN: r29627
1999-09-23 13:11:51 -06:00
Tom Tromey
f08113ce11 natFirstThread.cc (run): Renamed from `run0'.
* java/lang/natFirstThread.cc (run): Renamed from `run0'.  Removed
	dead code.
	* java/lang/FirstThread.java (run0): Renamed to `run'.
	(run): Removed.

From-SVN: r29626
1999-09-23 19:05:50 +00:00
Tom Tromey
9b0cb28706 re GNATS gcj/51 (Writing on OutputStream of bad Socket kills app with "Broken pipe")
* prims.cc (main_init): New function.
	(JvRunMain): Call it.
	(_Jv_RunMain): Likewise.
	Include <signal.h>.
	(main_init): Ignore SIGPIPE.  Fixes PR 51.

From-SVN: r29625
1999-09-23 18:50:59 +00:00
Zack Weinberg
fe1dbf6c7c iso646.h, [...]: Add copyright notice and special exception to GPL.
1999-09-23 10:56 -0700  Zack Weinberg  <zack@bitmover.com>

	* iso646.h, stdarg.h, stdbool.h, stddef.h, varargs.h: Add
	copyright notice and special exception to GPL.

From-SVN: r29624
1999-09-23 18:02:55 +00:00