Commit Graph

31628 Commits

Author SHA1 Message Date
Zack Weinberg a8a05998de ggc.h: Delete ggc_add_string_root and ggc_mark_string.
* ggc.h: Delete ggc_add_string_root and ggc_mark_string.  Add
        digit_vector and digit_string.
        * stringpool.c (digit_vector): New.
        (ggc_alloc_string): Use digit_string.

        * stmt.c (digit_strings): Delete.
        (init_stmt): Do not initialize digit_strings.
        (expand_asm_operands): Use ggc.h's digit_string macro.
        * toplev.c (mark_file_stack): Delete.
        (compile_file): Don't call init_tree_codes.
        (main): No need to make the file stack a GC root.
        * tree.c (init_tree_codes): Delete.
        * tree.h (init_tree_codes): Delete.

        * c-lex.c: Don't include ggc.h.
        (mark_splay_tree_node, mark_splay_tree): Delete.
        (init_c_lex): No need to ggc_strdup string constant.  Don't add
        file_info_tree to GGC roots.
        (cb_enter_file, cb_rename_file): No need to ggc_strdup
        ip->nominal_fname.

        * Makefile.in (c-lex.o): No longer depends on $(GGC_H).

        * dbxout.c (dbxout_init),
        dwarf2out.c (dwarf2out_line),
        ggc-common.c (ggc_mark_rtx_children, ggc_mark_trees),
        varasm.c (mark_const_hash_entry, mark_pool_constant, init_varasm_once),
        xcoffout.c (xcoffout_source_file),
        i386.c (load_pic_register):
        Delete call(s) to ggc_add_string_root and/or ggc_mark_string.

        * except.c (create_rethrow_ref),
        profile.c (init_edge_profiler),
        toplev.c (compile_file),
        varasm.c (named_section, assemble_static_space,
        assemble_trampoline_template, output_constant_def, force_const_mem),
        i386.c (load_pic_register),
        ia64.c (ia64_encode_section_info),
        rs6000.c (rs6000_emit_load_toc_table, create_TOC_reference,
        rs6000_emit_prologue, rs6000_emit_epilogue),
        rs6000.md (load_toc_aix_si, load_toc_aix_di):
        Change ggc_alloc_string (var, -1) to ggc_strdup (var).

        * profile.c (output_func_start_profiler),
        tree.c (make_node),
        i386.c (load_pic_register): No need to ggc_strdup string constant.

cp:
        * lex.c (mark_impl_file_chain): Delete.
        (init_parse): Remove call to ggc_add_string_root.  No need to
        ggc_strdup a string constant.  Do not add impl_file_chain to GC
        roots.
        (handle_pragma_implementation): No need to ggc_strdup main_filename.

f:
        * lex.c (ffelex_hash_): Change ggc_alloc_string (var, -1) to
        ggc_strdup (var).

java:
        * parse.y (goal): Remove call to ggc_add_string_root.

From-SVN: r37522
2000-11-17 17:31:13 +00:00
Zack Weinberg 9e7d5ee809 New test - regression of ICE
From-SVN: r37521
2000-11-17 16:45:34 +00:00
Nathan Sidwell 8b25cab976 fix thinko in last change
From-SVN: r37520
2000-11-17 12:36:26 +00:00
Hans-Peter Nilsson 61ed06c3f3 Makefile.in (config.status): Depend on config.gcc.
* Makefile.in (config.status): Depend on config.gcc.
	* configure.in <for machine in $build $host $target>: Move
	contents of loop into config.gcc, removing autoconf quoting.
	Fix changequote bug for alpha*-*-vxworks*.
	* configure: Regenerate.
	* config.gcc: New.

From-SVN: r37519
2000-11-17 10:42:45 +00:00
Nathan Sidwell 35728a80fc pt.c (tsubst_expr, DECL_STMT): Instantiate decl's type.
cp:
	* pt.c (tsubst_expr, DECL_STMT): Instantiate decl's type.

testsuite:
	* g++.old-deja/g++.pt/instantiate8.C: New test.

From-SVN: r37518
2000-11-17 10:24:05 +00:00
Nathan Sidwell 5cce22b6c2 cp-tree.h (PARMLIST_ELLIPSIS_P): New macro.
cp:
	* cp-tree.h (PARMLIST_ELLIPSIS_P): New macro.
	* decl.c (grokdeclarator): Don't reject void parms here.
	(require_complete_types_for_parms): Simplify, use
	complete_type_or_else.
	(grokparms): Remove bitrot. Remove funcdef parm.
	Deal with ellipsis parm lists here.
	* semantics.c (finish_parmlist): Don't append void_list_node
	here. Set PARMLIST_ELLIPSIS_P.

testsuite:
	* g++.old-deja/g++.other/incomplete.C: Add more tests.
	* g++.old-deja/g++.pt/crash9.C: Mark new expected error.

From-SVN: r37517
2000-11-17 10:05:31 +00:00
Nathan Sidwell 146c8d6034 typeck2.c (incomplete_type_error): Reorganise to avoid excessive diagnostics.
* typeck2.c (incomplete_type_error): Reorganise to avoid
	excessive diagnostics.

From-SVN: r37516
2000-11-17 09:48:53 +00:00
Jeff Law 078c72b67f Daily bump.
From-SVN: r37515
2000-11-17 01:45:08 -07:00
Zack Weinberg 520a57c81c stringpool.c: New file.
* stringpool.c: New file.
	* ggc-common.c (ggc_mark_string_ptr, ggc_add_string_root): Delete.
	(ggc_alloc_string): Now in stringpool.o.
	* ggc-page.c, ggc-simple.c: Do not define or allocate empty_string.
	* ggc.h: Delete prototype of ggc_add_string_root.  #define
	ggc_add_string_root and ggc_mark_string to nothing.  Prototype
	init_stringpool and stringpool_statistics.
	(ggc_alloc_string): Returns a const char *.
	* tree.c (hash_table, do_identifier_warnings): Delete.
	(init_obstacks): Don't initialize the identifier hash table.
	(get_identifier, maybe_get_identifier, start_identifier_warnings,
	set_identifier_size): Now in stringpool.c.
	* tree.h (struct tree_string): Constify pointer field.
	(approx_sqrt): Prototype.

	* Makefile.in (stringpool.o): Add rule, mention in OBJS.

	* toplev.c (approx_sqrt): New function.
	(compile_file): Call stringpool_statistics if mem_report is on.
	(main): Call init_stringpool.

	* builtins.c (c_strlen), c-decl.c (finish_decl), c-lex.c
	(process_directive), c-typeck.c (constructor_asmspec, struct
	initializer_stack, start_init), except.c (create_rethrow_ref),
	stmt.c (digit_strings), toplev.c (decode_f_option), tree.c
	(built_in_filename), varasm,c (in_named_name,
	assemble_static_space, struct constant_descriptor, struct
	deferred_string, struct pool_constant, force_const_mem),
	i386.c (pic_label_name, global_offset_table_name), rs6000.c
	(rs6000_emit_prologue, rs6000_emit_epilogue) : Constify a char *.

	* c-common.c (combine_strings): Combine strings in scratch
	buffer, then pass to build_string.
	* optabs.c (init_libfuncs), profile.c (init_edge_profiler,
	output_func_start_profiler), stmt.c (init_stmt), alpha.c
	(alpha_need_linkage), arm.c (arm_encode_call_attribute),
	i386.c (load_pic_register), ia64.c (ia64_encode_section_info),
	rs6000.c (rs6000_encode_section_info): Create string in
	scratch buffer, then pass to ggc_alloc_string.

	* stmt.c (expand_asm_operands): If we must adjust the
	constraint strings, do so by creating a new one, not by
	modifying the old one in place.  Constify some char *s.
	* config/pa/pa.c (hppa_encode_label): Drop unnecessary second
	argument.  Create string in scratch buffer, then pass to
	ggc_alloc_string.
	* config/pa/pa-protos.h: Update prototype.
	* config/pa/elf.h, config/pa/pa.h, config/pa/som.h:
	hppa_encode_label takes only one argument.

	* c-parse.in (if_prefix): Find the filename and line number at
	$-2 and $-1 respectively.
	* diagnostic.c (error_recursion): Add missing newline, use
	fputs, translate string.

cp:
	* lex.c (struct impl_files, internal_filename): Constify a char *.
java:
	* jcf-parse.c (get_constant), parse.y (do_merge_string_cste):
	Create string in scratch buffer, then pass to build_string.

From-SVN: r37514
2000-11-17 06:05:31 +00:00
Loren J. Rittle 5af655ccee locale_facets.tcc (num_get<_CharT, [...]): Add missing typename keyword.
* include/bits/locale_facets.tcc (num_get<_CharT,
          _InIter>::do_get(...)): Add missing typename keyword.

From-SVN: r37513
2000-11-17 05:38:04 +00:00
Tom Tromey 98182da528 PushbackReader.java: Merged with Classpath.
* java/io/PushbackReader.java: Merged with Classpath.
	* java/util/Arrays.java: Updated from Classpath.

	* scripts/blocks.pl: New file.
	* java/lang/Character.java (Subset): New class.
	(UnicodeBlock): New class.

	* java/lang/Math.java (toDegrees, toRadians): New methods.

	* java/lang/Float.java: Implement Comparable.
	(compareTo): New methods.
	* java/lang/Double.java: Implement Comparable.
	(compareTo): New methods.

From-SVN: r37512
2000-11-17 04:51:25 +00:00
Kaveh R. Ghazi dd3b81b421 mcore.c (mcore_expand_prolog): Call xmalloc/xrealloc, not malloc/realloc.
* mcore.c (mcore_expand_prolog): Call xmalloc/xrealloc, not
	malloc/realloc.

	* cpplib.c (glue_header_name): Likewise.

	* fixincl.c (run_compiles, start_fixer): Likewise.

	* fixlib.c (load_file_data): Likewise.

	* mkdeps.c (munge): Likewise.

f:
	* malloc.c (malloc_init): Call xmalloc, not malloc.

From-SVN: r37511
2000-11-17 04:16:55 +00:00
Hans-Peter Nilsson 5074c1fe97 defaults.h [...] (EH_FRAME_SECTION): Remove trailing ';'.
* defaults.h [EH_FRAME_SECTION_ASM_OP] (EH_FRAME_SECTION): Remove
	trailing ';'.  Fix formatting.

From-SVN: r37510
2000-11-17 01:52:43 +00:00
Mark Mitchell e26cb7aba1 acinclude.m4 (GLIBCPP_ENABLE_CSTDIO): Make --enable-cstdio=stdio the default.
* acinclude.m4 (GLIBCPP_ENABLE_CSTDIO): Make
	--enable-cstdio=stdio the default.  Disable wide character support
	in that event.
	* configure.in: Move GLIBCPP_ENABLE_C_MBCHAR after
	(GLIBCPP_ENABLE_CSTDIO).
	* config/c_io_stdio.h: Don't include <libio.h>, don't define
	__c_wfile_type.
	* aclocal.m4: Regenerated.
	* configure: Likewise.
	* Makefile.in: Likewise.
	* libio/Makefile.in: Likewise.
	* libmath/Makefile.in: Likewise.
	* libsupc++/Makefile.in: Likewise.
	* src/Makefile.in: Likewise.

From-SVN: r37509
2000-11-17 01:04:02 +00:00
Mark Mitchell 43048a06fa mangle.c (write_special_name_constructor): Don't generate assembler junk when confronted with an old-style constructor.
* mangle.c (write_special_name_constructor): Don't generate
	assembler junk when confronted with an old-style constructor.
	(write_special_name_destructor): Likewise.
	(mangle_decl_string): Do it here instead.

From-SVN: r37508
2000-11-16 22:36:20 +00:00
Jim Wilson 35d9f39dea Fix ia64 mask bit conflict from parallel development.
* config/ia64/ia64.h (MASK_INLINE_DIV_LAT, MASK_INLINE_DIV_THR):
	Shift masks left by one to avoid conflict.

From-SVN: r37507
2000-11-16 13:35:16 -08:00
Warren Levy 3cd22508eb PropertyChangeSupport.java (propertyListeners): Made transient.
* java/beans/PropertyChangeSupport.java (propertyListeners): Made
	transient.
	(listeners): Made transient.
	(source): Renamed from 'bean'.
	(children): New field for serialization.
	(propertyChangeSupportSerializedDataVersion): Ditto.
	(serialVersionUID): Ditto.
	(writeObject): New serialization method.
	(readObject): New serialization method.
	* java/beans/VetoableChangeSupport.java (propertyListeners): Made
	transient.
	(listeners): Made transient.
	(source): Renamed from 'bean'.
	(children): New field for serialization.
	(vetoableChangeSupportSerializedDataVersion): Ditto.
	(serialVersionUID): Ditto.
	(writeObject): New serialization method.
	(readObject): New serialization method.
	* java/lang/reflect/natMethod.cc (_Jv_CallAnyMethodA): Fixed assert
	to allow constructor to have a return type (i.e. the class that the
	constructor constructs).

Serialization mods.

From-SVN: r37506
2000-11-16 21:34:48 +00:00
Jim Wilson 74fe26b270 Fix ia64 C++ gprel link errors.
* config/ia64/ia64.c (ia64_encode_section_info): Disallow decls with
	DECL_EXTERNAL set.

From-SVN: r37505
2000-11-16 12:01:21 -08:00
Nick Clifton e24fa9dac1 Add a couple of new test cases for nested function support.
From-SVN: r37504
2000-11-16 19:45:23 +00:00
Nick Clifton 68dfd979ac Fix nested function support for the ARM
From-SVN: r37503
2000-11-16 19:23:15 +00:00
Gerald Pfeifer cdb3cf8546 * config/c_io_stdio.h: Include stddef.h.
From-SVN: r37502
2000-11-16 17:45:11 +00:00
Bernd Schmidt 2b8b5d02e6 New testcase
From-SVN: r37501
2000-11-16 16:19:37 +00:00
DJ Delorie 237aa7a2f3 oops, forgot a const
From-SVN: r37500
2000-11-16 10:21:50 -05:00
DJ Delorie 3ab9a08fcc rtl.c (read_rtx): Provide suitable names for unnamed define_insn and define_insn_and_split...
* rtl.c (read_rtx): Provide suitable names for unnamed
define_insn and define_insn_and_split patterns, based on file
and line numbers.

From-SVN: r37499
2000-11-16 10:19:01 -05:00
Nathan Sidwell cdb7167327 * call.c (op_error): Make error messages clearer.
From-SVN: r37498
2000-11-16 11:49:44 +00:00
Franz Sirl 4c8fb5714b 20001115-1.c: New test.
2000-11-15  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>

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

From-SVN: r37497
2000-11-16 11:19:11 +00:00
Mark Mitchell 35ef21d256 c_io_stdio.h (streamsize): Make it a typedef for ptrdiff_t.
* config/c_io_stdio.h (streamsize): Make it a typedef for
	ptrdiff_t.
	(wstreamsize): Likewise.

From-SVN: r37496
2000-11-16 09:26:14 +00:00
Mark Mitchell c135a22c31 * config/c_io_stdio.h: Include libio.h.
From-SVN: r37495
2000-11-16 09:20:48 +00:00
Hans-Peter Nilsson 29120f4427 cplus-dem.c (ada_demangle): Add back ATTRIBUTE_UNUSED for parameter `option'.
* cplus-dem.c (ada_demangle): Add back ATTRIBUTE_UNUSED for
parameter `option'.
Do s/cplus_dem.c/cplus-dem.c/g on ChangeLog.

From-SVN: r37494
2000-11-16 09:12:47 +00:00
Jeff Law dc378b0887 Daily bump.
From-SVN: r37493
2000-11-16 01:45:07 -07:00
Mark Mitchell 97150c41bd arraynew.C: Use `std' where necessary.
* g++.old-deja/g++.abi/arraynew.C: Use `std' where necessary.
	* g++.old-deja/g++.abi/cxa_vec.C: Likewise.
	* g++.old-deja/g++.abi/ptrflags.C: Likewise.
	* g++.old-deja/g++.abi/vmihint.C: Likewise.

From-SVN: r37492
2000-11-16 04:14:37 +00:00
Mark Mitchell c4d3f801a6 acinclude.m4 (GLIBCPP_ENABLE_CSTDIO): Substitute libio_la.
* acinclude.m4 (GLIBCPP_ENABLE_CSTDIO): Substitute libio_la.
	* src/Makefile.am (libstdc___la_LIBADD): Use it.
	* aclocal.m4: Regenerated.
	* configure: Likewise.
	* Makefile.in: Likewise.
	* libio/Makefile.in: Likewise.
	* libmath/Makefile.in: Likewise.
	* libsupc++/Makefile.in: Likewise.
	* src/Makfile.in: Likewise.

From-SVN: r37491
2000-11-16 01:44:03 +00:00
Mark Mitchell 4f12dd3c7d mkcheckin.in: Move check for bash version 2 later in the file.
* mkcheckin.in: Move check for bash version 2 later in the file.

	* include/bits/basic_string.h (basic_string::_Rep::_S_max_size):
	Make it const.
	(basic_string::_Rep::_S_terminal): Likewise.
	* include/bits/string.tcc (basic_string::_Rep::_S_max_size):
	Likewise.
	(basic_string::_Rep::_S_terminal): Likewise.

From-SVN: r37490
2000-11-16 01:03:20 +00:00
Gerald Pfeifer 9e038f71b0 Fix ChangeLog entry: cplus-dem.c instead of cplus_dem.c
From-SVN: r37489
2000-11-15 23:03:52 +00:00
David Billinghurst 74e1cd2546 mkcheck.in: Add function size_command() for irix.
2000-11-15  David Billinghurst  <David.Billinghurst@riotinto.com>

	* mkcheck.in:  Add function size_command() for irix.

From-SVN: r37488
2000-11-15 20:08:59 +00:00
Neil Booth fe6c2db99a cpplib.c (start_directive, [...]): New functions.
* cpplib.c (start_directive, end_directive): New functions.
        (_cpp_handle_directive, run_directive): Use them.
        (_cpp_handle_directive): Don't -Wtraditional on indented
        null directives.
        (_cpp_push_buffer): Don't re-clear was_skipping.
        * cpplib.h (struct cpp_reader): New member la_saved.
        * cppmacro.c (cpp_get_token): Don't interpret _Pragma in
        directives.

From-SVN: r37487
2000-11-15 19:25:22 +00:00
Neil Booth cbc2c182d1 _Pragma1.c: Update.
* gcc.dg/cpp/_Pragma1.c: Update.
        * gcc.dg/cpp/_Pragma2.c: New test.

From-SVN: r37486
2000-11-15 19:23:41 +00:00
Mark Mitchell 6213608449 toplev.c (wrapup_global_declarations): Don't write out artificial static variables that aren't needed.
* toplev.c (wrapup_global_declarations): Don't write out
	artificial static variables that aren't needed.

	* decl.c (wrapup_globals_for_namespace): Don't mark things
	TREE_ASM_WRITTEN when they're not.

From-SVN: r37485
2000-11-15 18:34:29 +00:00
Toon Moene adcee32ccb configure.in: See if `mkstemp' is available.
2000-11-15  Toon Moene  <toon@moene.indiv.nluug.nl>

	* libI77/configure.in: See if `mkstemp' is available.
	* libI77/configure: Regenerate.
	* libI77/open.c: Use `mkstemp' to create scratch
	file atomically.

From-SVN: r37484
2000-11-15 18:26:42 +00:00
Kenneth Block 0437a5a8a8 cplus_dem.c: Eliminate use of DEFUN, it is obsolete and cannot be used in GCC.
* cplus_dem.c: Eliminate use of DEFUN, it is obsolete and cannot
	be used in GCC.

From-SVN: r37483
2000-11-15 17:35:20 +00:00
Bernd Schmidt 099dde21d2 Workaround for Itanium A/B step errata
From-SVN: r37482
2000-11-15 17:29:00 +00:00
Fred Fish 4e7b85edbe mkfixinc.sh (fixincludes): Add *-*-beos* to list of machines for which fixincludes is not needed.
* fixinc/mkfixinc.sh (fixincludes): Add *-*-beos* to list of
        machines for which fixincludes is not needed.
        * config/i386/x-beos (STMP_FIXPROTO): Don't run fixproto.

From-SVN: r37481
2000-11-15 10:56:59 -05:00
Jason Merrill ee3400e881 diagnostic.c (finish_abort): New fn.
* diagnostic.c (finish_abort): New fn.
        (fancy_abort, error_recursion): Use it.
        * toplev.c (crash_signal): Likewise.
        * diagnostic.h: Declare it.

        * typeck2.c (friendly_abort): Uncount the error before handing
        off to fancy_abort.

From-SVN: r37480
2000-11-15 10:50:51 -05:00
Andrew Haley 12e1243e42 tree.c (build_type_no_quals): New function.
2000-11-13  Andrew Haley  <aph@redhat.com>

        * tree.c (build_type_no_quals): New function.
        * tree.h (build_type_no_quals): Declare.
        * c-common.c (c_get_alias_set): When considering type
        compatibility for pointer types, ignore cv-qualifiers anywhere in
        a pointer chain.

From-SVN: r37479
2000-11-15 14:39:14 +00:00
Nathan Sidwell 71631a1f1c typeck.c (lookup_anon_field): Cope with qv qualifiers.
cp/
	* typeck.c (lookup_anon_field): Cope with qv qualifiers.
testsuite/
	* g++.old-deja/g++.other/anon5.C: New test.

From-SVN: r37478
2000-11-15 11:59:07 +00:00
Hans-Peter Nilsson eab0c1ab23 Correct style of last entry
From-SVN: r37477
2000-11-15 11:58:16 +00:00
Hans-Peter Nilsson ba7aa3c1c3 Correct date and style of last entry
From-SVN: r37476
2000-11-15 11:57:23 +00:00
Kenneth Block 61ab980a02 cplus_dem.c: Add gnat demangler.
* cplus_dem.c: Add gnat demangler.  Add java to demangle style
	list.

From-SVN: r37475
2000-11-15 11:54:53 +00:00
Kenneth Block 7ecdd10b6d * demangle.h: Add gnat and java demangle styles.
From-SVN: r37474
2000-11-15 11:52:30 +00:00
Graham Stott 695e4773c1 regrename.c (scan_rtx_rtx): Skip to the next chain on encountering a terminated chain.
* regrename.c (scan_rtx_rtx): Skip to the next chain on
        encountering a terminated chain.

From-SVN: r37473
2000-11-15 11:07:44 +00:00