Commit Graph

358 Commits

Author SHA1 Message Date
Diego Novillo d7f09764d7 Merge lto branch into trunk.
From-SVN: r152434
2009-10-03 17:10:11 -04:00
Jason Merrill c03c52480a properly merge include/ChangeLog
From-SVN: r152319
2009-09-29 23:03:31 -04:00
Dodji Seketeli 7653f2738f DWARF for Template parm pack is a gnu extension.
include/ChangeLog:
	* dwarf2.h (enum dwarf_tag): Rename DW_TAG_template_parameter_pack and
	DW_TAG_formal_parameter_pack into DW_TAG_GNU_template_parameter_pack
	and DW_TAG_formal_parameter_pack until DWARF 5 is out.

gcc/ChangeLog:
	* dwarf2out.c (dwarf_tag_name, gen_generic_params_dies,
	generic_parameter_die, template_parameter_pack_die,
	gen_formal_parameter_die, gen_subprogram_die): Adjust after renaming
	DW_TAG_formal_parameter_pack and DW_TAG_template_parameter_pack into
	DW_TAG_GNU_formal_parameter_pack and DW_TAG_GNU_template_parameter_pack.

gcc/testsuite/ChangeLog:
	* g++.dg/debug/dwarf2/template-func-params-4.C: Adjust after renaming
	DW_TAG_template_parameter_pack and DW_TAG_formal_parameter_pack
	into DW_TAG_GNU_template_parameter_pack and
	DW_TAG_GNU_formal_parameter_pack.
	* g++.dg/debug/dwarf2/template-params-4.C: Likewise.
	* g++.dg/debug/dwarf2/template-func-params-7.C: Likewise.

From-SVN: r152188
2009-09-26 01:23:18 +02:00
Cary Coutant 5ae5f59651 Add rest of new values from DWARF Version 4.
include/

	Add rest of new values from DWARF Version 4.
	* dwarf2.h (DW_TAG_rvalue_reference_type, DW_TAG_template_alias):
	New tags.
	(DW_FORM_ref_sig8): New name for DW_FORM_sig8.
	(DW_AT_main_subprogram, DW_AT_data_bit_offset, DW_AT_const_expr,
	DW_AT_enum_class, DW_AT_linkage_name, DW_AT_GNU_guarded_by,
	DW_AT_GNU_pt_guarded_by, DW_AT_GNU_guarded, DW_AT_GNU_pt_guarded,
	DW_AT_GNU_locks_excluded, DW_AT_GNU_exclusive_locks_required,
	DW_AT_GNU_shared_locks_required, DW_AT_GNU_odr_signature): New
	attributes.
	(DW_LANG_Python): New language.

From-SVN: r152181
2009-09-25 11:33:04 -07:00
Dodji Seketeli d40a19da13 re PR debug/41266 (Emit DW_TAG_template_parameter_pack and DW_TAG_formal_parameter_pack)
Fix for PR debug/41266

ChangeLog:

	* include/dwarf2.h (enum dwarf_tag): Add
	DW_TAG_template_parameter_pack and DW_TAG_formal_parameter_pack.

gcc/ChangeLog:

	* dwarf2out.c (template_parameter_pack_die,
	gen_formal_parameter_pack_die ): New functions.
	(make_ith_pack_parameter_name): Remove this function.
	(dwarf_tag_name): Support printing DW_TAG_template_parameter_pack and
	DW_TAG_formal_parameter_pack.
	(gen_generic_params_dies): Represent each template parameter pack
	by a DW_TAG_template_parameter_pack DIE. Argument pack elements are
	represented by usual DW_TAG_template_*_parameter DIEs that are
	children of the DW_TAG_template_parameter_pack element DIE.
	(generic_parameter_die): This doesn't deal with parameter pack
	names anymore. Don't generate DW_AT_name for some DIEs, e.g. children of
	parameter pack DIEs.
	(gen_formal_parameter_die): Add a flag to not emit DW_AT_name
	in certain cases, e.g. for pack elements.
	(gen_formal_types_die, gen_decl_die): Adjust usage of
	gen_formal_parameter_die.
	(gen_subprogram_die): Represent each function parameter pack by a
	DW_TAG_formal_parameter_pack DIE. Arguments of of the pack are
	represented by usual DW_TAG_formal_parameter DIEs that are children
	of the DW_TAG_formal_parameter_pack DIE. Remove references to
	____builtin_va_alist decls as no part of the compiler uses those
	anymore.
	* langhooks.h (struct lang_hooks_for_decls): Add
	function_parm_expanded_from_pack_p, get_generic_function_decl
	and function_parameter_pack_p hooks.  Fix comment for
	get_innermost_generic_parms hook.
	* langhooks-def.h (LANG_HOOKS_FUNCTION_PARAMETER_PACK_P,
	LANG_HOOKS_FUNCTION_PARM_EXPANDED_FROM_PACK_P ): Declare new hook
	macros and use them to initialize lang_hook.

gcc/cp/ChangeLog:

	* cp-lang.c (LANG_HOOKS_FUNCTION_PARAMETER_PACK_P,
	LANG_HOOKS_FUNCTION_PARM_EXPANDED_FROM_PACK_P,
	LANG_HOOKS_GET_GENERIC_FUNCTION_DECL): Initialize these
	hooks for the c++ FE.
	* cp-tree.h (function_parameter_pack_p, get_function_template_decl,
	function_parameter_expanded_from_pack_p): Declare ...
	* pt.c (function_parameter_pack_p, get_function_template_decl,
	function_parameter_expanded_from_pack_p): ... new hooks.
	(get_template_info): Make this more robust.
	(template_args_variadic_p, make_ith_pack_parameter_name): Add a new
	line between comment and function.
	(get_template_argument_pack_elems): Fix comment.
	(tsubst_decl): Arguments of function parameter packs are not
	parameter packs themselves.

gcc/testsuite/ChangeLog:
	* g++.dg/debug/dwarf2/template-func-params-4.C: Adjust.
	* g++.dg/debug/dwarf2/template-func-params-7.C: Likewise.
	* g++.dg/debug/dwarf2/template-params-4.C: Likewise.

From-SVN: r152043
2009-09-22 22:20:03 +02:00
Ian Lance Taylor 330b922f19 re PR bootstrap/40854 (Conflicting crc32 functions in libiberty and zlib)
include/:
	PR bootstrap/40854
	* libiberty.h (xcrc32): Rename from crc32.
libiberty/:
	PR bootstrap/40854
	* crc32.c (xcrc32): Rename from crc32.

From-SVN: r150075
2009-07-25 06:28:16 +00:00
Ian Lance Taylor b524249cbe crc32.c: New file.
libiberty/:
	* crc32.c: New file.
	* Makefile.in: Rebuild dependencies.
	(CFILES): Add crc32.c.
	(REQUIRED_OFILES): Add ./crc32.o.
	* functions.texi: Rebuild.
include/:
	* libiberty.h (crc32): Declare.

From-SVN: r150067
2009-07-24 23:22:41 +00:00
Cary Coutant 4310f048df Add ccoutant to previous dwarf4 entry.
From-SVN: r149866
2009-07-21 19:05:14 +00:00
Cary Coutant 07d9f9b861 Add some dwarf4 values.
* dwarf2.h (enum dwarf_tag): Add DW_TAG_type_unit.
	(enum dwarf_form): Add DW_FORM_sec_offset, DW_FORM_exprloc,
	DW_FORM_flag_present, DW_FORM_sig8.
	(enum dwarf_attribute): Add DW_AT_signature.

From-SVN: r149836
2009-07-20 21:00:52 +00:00
Jan Kratochvil 23b1a789fd demangle.h (enum demangle_component_type <DEMANGLE_COMPONENT_GLOBAL_CONSTRUCTORS>) (enum demangle_component_type <DEMANGLE_COMPONENT_GLOBAL_DESTRUCTORS>): New.
include
2009-07-17  Jan Kratochvil  <jan.kratochvil@redhat.com>

	* demangle.h
	(enum demangle_component_type <DEMANGLE_COMPONENT_GLOBAL_CONSTRUCTORS>)
	(enum demangle_component_type <DEMANGLE_COMPONENT_GLOBAL_DESTRUCTORS>):
	New.
libiberty
2009-07-17  Jan Kratochvil  <jan.kratochvil@redhat.com>

	* cp-demangle.c (d_print_comp <DEMANGLE_COMPONENT_GLOBAL_CONSTRUCTORS>)
	(d_print_comp <DEMANGLE_COMPONENT_GLOBAL_DESTRUCTORS): New.
	(d_make_comp <DEMANGLE_COMPONENT_GLOBAL_CONSTRUCTORS>)
	(d_make_comp <DEMANGLE_COMPONENT_GLOBAL_DESTRUCTORS): New.
	(d_demangle_callback): The variable type is now declared as enum.
	Replace parser of _GLOBAL_ symbols by a d_make_comp call.

From-SVN: r149756
2009-07-17 19:09:54 +00:00
Jakub Jelinek 116b072217 dwarf2.h (enum dwarf_location_atom): Add DW_OP_implicit_value and DW_OP_stack_value.
2009-07-09  Jakub Jelinek  <jakub@redhat.com>

	* dwarf2.h (enum dwarf_location_atom): Add DW_OP_implicit_value
	and DW_OP_stack_value.

From-SVN: r149438
2009-07-09 20:16:56 +00:00
Tom Tromey a80b057408 unwind-dw2-fde-darwin.c: Include dwarf2.h.
gcc
	* unwind-dw2-fde-darwin.c: Include dwarf2.h.
	* config/mmix/mmix.c: Include dwarf2.h.
	* config/rs6000/darwin-fallback.c: Include dwarf2.h.
	* config/xtensa/unwind-dw2-xtensa.c: Include dwarf2.h.
	* config/sh/sh.c: Include dwarf2.h.
	* config/i386/i386.c: Include dwarf2.h.
	* Makefile.in (DWARF2_H): Remove 'elf'.
	* except.c: Include dwarf2.h.
	* unwind-dw2.c: Include dwarf2.h.
	* dwarf2out.c: Include dwarf2.h.
	* unwind-dw2-fde-glibc.c: Include dwarf2.h.
	* unwind-dw2-fde.c: Include dwarf2.h.
	* dwarf2asm.c: Include dwarf2.h.
gcc/ada
	* raise-gcc.c: Include dwarf2h (unconditionally).
include
	* elf/dwarf2.h: Remove, renaming to...
	* dwarf2.h: ... this.

From-SVN: r149433
2009-07-09 19:41:25 +00:00
Tom Tromey bbf531f021 dwarf2.h: Remove.
gcc
	* dwarf2.h: Remove.
	* Makefile.in (DWARF2_H): New variable.
	(except.o): Use it.
	(dwarf2out.o): Likewise.
	(dwarf2asm.o): Likewise.
	* config/i386/t-i386: Use DWARF2_H.
	* except.c: Include elf/dwarf2.h.
	* unwind-dw2.c: Include elf/dwarf2.h.
	* dwarf2out.c: Include elf/dwarf2.h.
	(dw_loc_descr_struct) <dw_loc_opc>: Now a bitfield.
	<dtprel>: New field.
	(dwarf_stack_op_name): Don't handle INTERNAL_DW_OP_tls_addr.
	(size_of_loc_descr): Likewise.
	(output_loc_operands_raw): Likewise.
	(output_loc_operands): Handle new dtprel field.
	(loc_checksum): Update.
	(loc_descriptor_from_tree_1) <VAR_DDECL>: Set dtprel field.
	* unwind-dw2-fde-glibc.c: Include elf/dwarf2.h.
	* unwind-dw2-fde.c: Include elf/dwarf2.h.
	* dwarf2asm.c: Include elf/dwarf2.h.
	* unwind-dw2-fde-darwin.c: Include elf/dwarf2.h.
	* config/mmix/mmix.c: Include elf/dwarf2.h.
	* config/rs6000/darwin-fallback.c: Include elf/dwarf2.h.
	* config/xtensa/unwind-dw2-xtensa.c: Include elf/dwarf2.h.
	* config/sh/sh.c: Include elf/dwarf2.h.
	* config/i386/i386.c: Include elf/dwarf2.h.
gcc/ada
	* raise-gcc.c: Include elf/dwarf2.h.
include
	* elf/dwarf2.h: New file.  Merged with gdb.

From-SVN: r149070
2009-06-30 00:02:10 +00:00
Ian Lance Taylor 780ca5bf71 * ansidecl.h (ATTRIBUTE_UNUSED_LABEL): Define for C++.
From-SVN: r148333
2009-06-10 01:48:14 +00:00
Ian Lance Taylor 6bc7bc1477 ansidecl.h (EXPORTED_CONST): Define.
include/:
	* ansidecl.h (EXPORTED_CONST): Define.
gcc/:
	* dummy-checksum.c (executable_checksum): Use EXPORTED_CONST.
	* genattrtab.c (write_length_unit_log): Likewise.
	* genchecksum.c (dosum): Likewise.
	* gengtype.c (write_rtx_next): Likewise.
	(finish_root_table, write_roots): Likewise.
	* gimple.c (gimple_ops_offset_): Likewise.
	* tree-nomudflap.c (gt_ggc_r_gt_tree_mudflap_h): Likewise.
	* config/arc/arc.c (arc_attribute_table): Likewise.
	* config/arm/arm.c (arm_attribute_table): Likewise.
	* config/avr/avr.c (avr_attribute_table): Likewise.
	* config/crx/crx.c (crx_attribute_table): Likewise.
	* config/m32r/m32r.c (m32r_attribute_table): Likewise.
	* config/m68hc11/m68hc11.c (m68hc11_attribute_table): Likewise.
	* config/mcore/mcore.c (mcore_attribute_table): Likewise.
	* config/rs6000/rs6000.c (rs6000_attribute_table): Likewise.
	* config/sh/sh.c (sh_attribute_table): Likewise.
	* config/sparc/sparc.c (sparc_attribute_table): Likewise.
	* config/spu/spu.c (spu_attribute_table): Likewise.
	* config/v850/v850.c (v850_attribute_table): Likewise.

	* config/alpha/alpha.c (vms_attribute_table): Make static.
	* config/bfin/bfin.c (bfin_attribute_table): Likewise.
	* config/h8300/h8300.c (h8300_attribute_table): Likewise.
	* config/mips/mips.c (mips_attribute_table): Likewise.

	* Makefile.in (dummy-checksum.o): Depend upon $(CONFIG_H) and
	$(SYSTEM_H).
	(cc1-checksum.o): Likewise.
gcc/cp/:
	* Make-lang.in (cc1plus-checksum.o): Depend upon $(CONFIG_H) and
	$(SYSTEM_H).
gcc/objc/:
	* Make-lang.in (cc1obj-checksum.o): Depend upon $(CONFIG_H) and
	$(SYSTEM_H).
gcc/objcp/:
	* Make-lang.in (cc1objplus-checksum.o): Depend upon $(CONFIG_H)
	and $(SYSTEM_H).

From-SVN: r148146
2009-06-03 20:19:55 +00:00
Ian Lance Taylor 75afccba06 ansidecl.h: Add extern "C" when compiling with C++.
* ansidecl.h: Add extern "C" when compiling with C++.  Treat C++
	the way we treat an ISO C compiler.  Don't define inline as a
	macdro when compiling with C++.
	* dyn-string.h: Add header guard DYN_STRING_H.  Add extern "C"
	when compiling with C++.
	* fibheap.h: Add extern "C" when compiling with C++.

From-SVN: r148032
2009-06-01 05:47:20 +00:00
H.J. Lu bda61b12c2 Correct filenames.
From-SVN: r146740
2009-04-24 09:47:20 -07:00
Taras Glek 6a87e1d41d Add missing ChangeLog entries for revision 146607.
From-SVN: r146739
2009-04-24 09:46:13 -07:00
Jason Merrill 448545cb51 decl.c (grokfndecl): Set DECL_CONTEXT on parms.
cp/:
        * decl.c (grokfndecl): Set DECL_CONTEXT on parms.
        (duplicate_decls): Adjust DECL_CONTEXT of newdecl's parms.
        * pt.c (check_explicit_specialization): Likewise.
        (tsubst_copy) [PARM_DECL]: Return a dummy parm if we don't have a
        local specialization.
        * tree.c (cp_tree_equal) [PARM_DECL]: Check type and index, not name.
        * decl2.c (parm_index): New fn.
        * semantics.c (finish_decltype_type): Don't use describable_type.
        * mangle.c (write_expression): Likewise.  Mangle ALIGNOF_EXPR.
        Give a sorry for unsupported codes rather than crash.  Mangle
        conversions with other than 1 operand.  New mangling for PARM_DECL.
        * operators.def (ALIGNOF_EXPR): Mangle as az.
  
        * include/demangle.h (enum demangle_component_type): Add
        DEMANGLE_COMPONENT_FUNCTION_PARAM.
        * libiberty/cp-demangle.c (d_make_function_param): new fn.
        (cplus_demangle_mangled_name): Work around abi v2 bug.
        (d_expr_primary): Likewise.
        (cplus_demangle_operators): Add alignof ops.
        (d_expression): Handle function parameters and conversions
        with other than 1 operand.
        (d_print_comp): Handle function parameters.  Fix bug with
        function used in type of function.

From-SVN: r144924
2009-03-17 19:31:18 -04:00
Jason Merrill 07523e7c08 re PR c++/35319 (ICE throwing fixed-point types)
PR c++/35319
        * mangle.c (write_builtin_type): Add mangling for decimal floating
        point and fixed point types.
        (write_type): Pass FIXED_POINT_TYPE along.
        * cp-demangle.c (cplus_demangle_type): Support fixed-point types.
        (d_print_comp, d_dump): Likewise.

From-SVN: r142661
2008-12-10 17:11:44 -05:00
Bob Wilson 2ad646bdca include/
* xtensa-config.h (XCHAL_HAVE_MUL16, XCHAL_HAVE_MUL32, XCHAL_HAVE_DIV32)
	(XCHAL_HAVE_MINMAX, XCHAL_HAVE_SEXT, XCHAL_HAVE_THREADPTR)
	(XCHAL_HAVE_RELEASE_SYNC, XCHAL_HAVE_S32C1I): Change to 1.
	(XCHAL_NUM_AREGS): Change to 32.
	(XCHAL_ICACHE_SIZE, XCHAL_DCACHE_SIZE): Change to 16K.
	(XCHAL_ICACHE_LINESIZE, XCHAL_DCACHE_LINESIZE): Change to 32.
	(XCHAL_ICACHE_LINEWIDTH, XCHAL_DCACHE_LINEWIDTH): Change to 5.
	(XCHAL_DCACHE_IS_WRITEBACK): Change to 1.
	(XCHAL_DEBUGLEVEL): Change to 6.

From-SVN: r142012
2008-11-19 18:26:00 +00:00
Alan Modra 085c6bd4f7 obstack.h (obstack_finish <!__GNUC__>): Cast result to void *.
* obstack.h (obstack_finish <!__GNUC__>): Cast result to void *.

From-SVN: r141254
2008-10-21 09:33:03 +10:30
Jason Merrill 38179091cc PR c++/37376, other mangling issues
gcc/cp/:
        PR c++/37376, other mangling issues
        * mangle.c (write_type): Update TYPE_PACK_EXPANSION mangling.
        (write_member_name): Break out from...
        (write_expression): ...here.  Handle dependent COMPONENT_REF.
        (write_template_arg): Wrap an argument pack in 'I'/'E'.
        (write_builtin_type): Update char16/32_t mangling.
        (write_nested_name, write_prefix): Don't forget template args
        for typename types.
        * operators.def: Add ARROW_EXPR, update COMPONENT_REF and
        EXPR_PACK_EXPANSION.
libstdc++-v3/:
        * config/abi/pre/gnu.ver: Update char16/32_t manglings.
include/:
        * demangle.h (enum demangle_component_type): Add
        DEMANGLE_COMPONENT_PACK_EXPANSION.
libiberty/:
        * cp-demangle.c (struct d_print_info): Add pack_index.
        (d_dump): Add DEMANGLE_COMPONENT_PACK_EXPANSION.
        (d_make_comp): Likewise.  DEMANGLE_COMPONENT_ARGLIST and
        DEMANGLE_COMPONENT_TEMPLATE_ARGLIST can have two null args.
        (cplus_demangle_builtin_types): Add char16/32_t.
        (cplus_demangle_type): Recognize them.
        (d_template_args): Handle empty argument packs.
        (d_template_arg): Handle argument packs.
        (d_expression): Handle dependent name.
        (d_index_template_argument): New fn.
        (d_lookup_template_argument): New fn.
        (d_find_pack, d_pack_length): New fn.
        (d_print_subexpr): Split out...
        (d_print_comp): ...from here.  Use d_*_template_argument.
        Handle empty arg lists.  Support pack expansions.
        * cp-demangle.h (D_BUILTIN_TYPE_COUNT): Increase to 32.

From-SVN: r140916
2008-10-06 18:29:42 -04:00
Jason Merrill 5a3d7e74ca demangle.h (enum demangle_component_type): Add DEMANGLE_COMPONENT_DECLTYPE.
* include/demangle.h (enum demangle_component_type): Add
        DEMANGLE_COMPONENT_DECLTYPE.
        * libiberty/cp-demangle.c (d_dump): Handle DEMANGLE_COMPONENT_DECLTYPE.
        (d_make_comp): Likewise.
        (cplus_demangle_type): Handle decltype and DFP types.
        (cplus_demangle_operators): Call operator takes 2 args.
        (cplus_demangle_builtin_types): Add DFP types.
        (d_exprlist): New fn.
        (d_expression): Handle parm placeholders, T() and calls.
        (d_print_comp): Handle decltype, T() and calls.
        * libiberty/testsuite/demangle-expected: Test the above.

From-SVN: r140162
2008-09-09 13:38:10 -04:00
Joel Brobecker 622c36c90d safe-ctype.h: Add #include of ctype.h before redefining the ctype.h macros.
* safe-ctype.h: Add #include of ctype.h before redefining
        the ctype.h macros.

From-SVN: r137580
2008-07-07 17:08:21 +00:00
Joel Brobecker 47cfcc3ae8 safe-ctype.h: Remove #error when detecting that ctype.h has been included.
* safe-ctype.h: Remove #error when detecting that ctype.h has been
        included. Redefine the various macros provided by ctype.h as
        undefined variables.

From-SVN: r137480
2008-07-04 17:05:58 +00:00
Kaveh R. Ghazi 190a9bd7ee libiberty.h (XALLOCA, [...]): New.
* libiberty.h (XALLOCA, XDUP, XALLOCAVEC, XDUPVEC, XALLOCAVAR,
	XDUPVAR, XOBNEWVEC, XOBNEWVAR): New.

From-SVN: r137058
2008-06-24 01:42:31 +00:00
Ian Lance Taylor 598848e4d6 sha1.h: New file, from gnulib.
include/:
	* sha1.h: New file, from gnulib.
libiberty/:
	* sha1.c: New file, from gnulib.
	* Makefile.in: Rebuild dependencies.
	(CFILES): Add sha1.c.
	(REQUIRED_OFILES): Add sha1.o.

From-SVN: r133503
2008-03-25 00:54:53 +00:00
Ian Lance Taylor 9bb28c1b58 * md5.h: Add extern "C" when compiled with C++.
From-SVN: r133495
2008-03-24 23:41:20 +00:00
Ian Lance Taylor 464509751a * filenames.h: Add extern "C" when compiled with C++.
From-SVN: r133440
2008-03-21 23:35:07 +00:00
Bob Wilson 5fd38b882f xtensa-config.h (XCHAL_HAVE_THREADPTR): Redefine to zero.
* xtensa-config.h (XCHAL_HAVE_THREADPTR): Redefine to zero.
	(XCHAL_NUM_AREGS, XCHAL_MAX_INSTRUCTION_SIZE): New.

From-SVN: r132240
2008-02-11 17:53:16 +00:00
David Daney e5df4fb1fa demangle.h (demangle_component_type): Add DEMANGLE_COMPONENT_JAVA_RESOURCE...
include/
2008-01-26  David Daney  <ddaney@avtrex.com>

	* demangle.h (demangle_component_type):  Add
	DEMANGLE_COMPONENT_JAVA_RESOURCE,
	DEMANGLE_COMPONENT_COMPOUND_NAME, and
	DEMANGLE_COMPONENT_CHARACTER as new enum values.
	(demangle_component): Add struct s_character to union u.

libiberty/
2008-01-26  David Daney  <ddaney@avtrex.com>

	* cp-demangle.c (d_dump): Handle DEMANGLE_COMPONENT_JAVA_RESOURCE,
	DEMANGLE_COMPONENT_COMPOUND_NAME, and
	DEMANGLE_COMPONENT_CHARACTER cases.
	(d_make_comp): Handle DEMANGLE_COMPONENT_COMPOUND_NAME and
	DEMANGLE_COMPONENT_JAVA_RESOURCE cases.
	(d_make_character): New function.
	(d_java_resource): Same.
	(d_special_name): Handle "Gr" case.
	(d_print_comp): Handle DEMANGLE_COMPONENT_JAVA_RESOURCE,
	DEMANGLE_COMPONENT_COMPOUND_NAME, and
	DEMANGLE_COMPONENT_CHARACTER cases.
	* testsuite/demangle-expected: Add test for java resource name
	mangling.

From-SVN: r131883
2008-01-27 06:01:00 +00:00
Joseph Myers da59326fd9 floatformat.h (struct floatformat): Add split_half field.
include:
2007-11-07  Joseph Myers  <joseph@codesourcery.com>
	    Daniel Jacobowitz  <dan@codesourcery.com>

	* floatformat.h (struct floatformat): Add split_half field.
	(floatformat_ibm_long_double): New.

libiberty:
2007-11-07  Joseph Myers  <joseph@codesourcery.com>
	    Daniel Jacobowitz  <dan@codesourcery.com>

	* floatformat.c (mant_bits_set): New.
	(floatformat_to_double): Use it.  Note no special handling of
	split formats.
	(floatformat_from_double): Note no special handing of split
	formats.
	(floatformat_ibm_long_double_is_valid,
	floatformat_ibm_long_double): New.
	(floatformat_ieee_single_big, floatformat_ieee_single_little,
	floatformat_ieee_double_big, floatformat_ieee_double_little,
	floatformat_ieee_double_littlebyte_bigword, floatformat_vax_f,
	floatformat_vax_d, floatformat_vax_g, floatformat_i387_ext,
	floatformat_m68881_ext, floatformat_i960_ext,
	floatformat_m88110_ext, floatformat_m88110_harris_ext,
	floatformat_arm_ext_big, floatformat_arm_ext_littlebyte_bigword,
	floatformat_ia64_spill_big, floatformat_ia64_spill_little,
	floatformat_ia64_quad_big, floatformat_ia64_quad_little): Update
	for addition of split_half field.

Co-Authored-By: Daniel Jacobowitz <dan@codesourcery.com>

From-SVN: r129977
2007-11-08 00:08:02 +00:00
Tom Tromey 48492bdf79 pexecute.txh (pex_free): Document process killing.
libiberty:
	* pexecute.txh (pex_free): Document process killing.
include:
	* libiberty.h (pex_free): Document process killing.

From-SVN: r128192
2007-09-06 16:58:57 +00:00
Doug Gregor 1ab28be596 mangle.c (write_type): Change mangling of rvalue reference from `RR' to `O'.
2007-08-31  Douglas Gregor  <doug.gregor@gmail.com>

	* mangle.c (write_type): Change mangling of rvalue reference from
	`RR' to `O'. 

2007-08-31  Douglas Gregor  <doug.gregor@gmail.com>
	
	* demangle.h (enum demangle_component_type): Add
	DEMANGLE_COMPONENT_RVALUE_REFERENCE. 

2007-08-31  Douglas Gregor  <doug.gregor@gmail.com>
	
	* cp-demangle.c (d_dump): Handle
	DEMANGLE_COMPONENT_RVALUE_REFERENCE. 
	(d_make_comp): Ditto.
	(cplus_demangle_type): Ditto.
	(d_print_comp): Ditto.
	(d_print_mod): Ditto.
	(d_print_function_type): Ditto.

2007-08-31  Douglas Gregor  <doug.gregor@gmail.com>

	* testsuite/abi/demangle/cxx0x/rref.cc: New.

From-SVN: r127999
2007-08-31 19:15:26 +00:00
Ben Elliston f4f29b5998 ternary.h: Remove.
include/
	* ternary.h: Remove.

libiberty/
	* Makefile.in (CFILES): Remove ternary.c.
	(REQUIRED_OFILES): Remove ./ternary.o.
	(INSTALLED_HEADERS): Remove ternary.h.
	(ternary.o): Remove.
	* ternary.c: Remove.

From-SVN: r126902
2007-07-25 16:26:45 +10:00
Bob Wilson 2a48b790b2 xtensa-config.h (XCHAL_HAVE_THREADPTR): New.
include/
	* xtensa-config.h (XCHAL_HAVE_THREADPTR): New.
	(XCHAL_HAVE_RELEASE_SYNC, XCHAL_HAVE_S32C1I): New.
gcc/
	* config/xtensa/xtensa.c (xtensa_expand_mask_and_shift): New.
	(struct alignment_context, init_alignment_context): New.
	(xtensa_expand_compare_and_swap, xtensa_expand_atomic): New.
	* config/xtensa/xtensa.h (XCHAL_HAVE_RELEASE_SYNC): Add default.
	(XCHAL_HAVE_S32C1I): Likewise.
	(TARGET_RELEASE_SYNC, TARGET_S32C1I): New.
	* config/xtensa/xtensa.md (UNSPECV_MEMW): New constant.
	(UNSPECV_S32RI, UNSPECV_S32C1I): Likewise.
	(ATOMIC, HQI): New macros.
	(memory_barrier, *memory_barrier): New.
	(sync_lock_releasesi): New.
	(sync_compare_and_swapsi, sync_compare_and_swap<mode>): New.
	(sync_lock_test_and_set<mode>): New.
	(sync_<atomic><mode>): New.
	(sync_old_<atomic><mode>, sync_new_<atomic><mode>): New.
	* config/xtensa/xtensa-protos.h (xtensa_expand_compare_and_swap): New.
	(xtensa_expand_atomic): New.
gcc/testsuite/	
	* lib/target-supports.exp (check_effective_target_sync_int_long):
	Enable for xtensa.
	(check_effective_target_sync_char_short): Likewise.

From-SVN: r126728
2007-07-18 18:51:21 +00:00
Nick Clifton 4c85af60e8 COPYING_v3: New file.
* COPYING_v3: New file.  Contains version 3 of the GNU General Public License.
* COPYING.LIB_v3: New file.  Contains version 3 of the GNU Lesser General Public License.
* gpl_v3.texi: New file.  Contains a texinfo formated copy of the GNU General Public License, version 3.

From-SVN: r126701
2007-07-17 08:37:53 +00:00
Uros Bizjak 2826df069f * splay-tree.h: Fix whitespace.
From-SVN: r126625
2007-07-13 18:18:48 +02:00
Kai Tietz 0f3943ec66 splay-tree.h (libi_uhostptr_t, [...]): Adjust types work-a-round whitespace problem in gcc gengtype.
* splay-tree.h (libi_uhostptr_t, libi_shostptr_t): Adjust types
	work-a-round whitespace problem in gcc gengtype.

From-SVN: r126587
2007-07-12 13:08:49 +00:00
Kai Tietz eb8f7cafe7 splay-tree.h (libi_uhostptr_t, [...]): New types, needed for WIN64 when a long is not wide enough for a pointer.
* splay-tree.h (libi_uhostptr_t, libi_shostptr_t): New types,
  needed for WIN64 when a long is not wide enough for a pointer.
  (splay_tree_key, splay_tree_value): Use the new types.

From-SVN: r126573
2007-07-12 07:22:06 +00:00
Nathan Froyd 2091ff6689 libiberty.h (writeargv): Declare.
include/
2007-05-07  Nathan Froyd  <froydnj@codesourcery.com>

	* libiberty.h (writeargv): Declare.

libiberty/
2007-05-07  Nathan Froyd  <froydnj@codesourcery.com>

	* argv.c (writeargv): New function.

gcc/
2007-05-07  Nathan Froyd  <froydnj@codesourcery.com>

	* gcc.c (at_file_supplied): New variable.
	(main): Set it if we expanded argv.
	(do_spec_1): Pass an @-file to the linker if we were called with
	an @-file argument and HAVE_GNU_LD.
	* collect2.c (at_file_supplied): New variable.
	(response_file): New variable.
	(collect_exit): Unlink response_file if necessary.
	(handler): Likewise.
	(do_wait): Likewise.
	(main): Set at_file_supplied if we expanded argv.
	(collect_execute): Pass an @-file to subprocesses if we were called
	with an @-file argument.
	* configure.ac: Add define for HAVE_GNU_LD.
	* configure: Regenerate.
	* config.in: Regenerate.

From-SVN: r124532
2007-05-08 00:37:39 +00:00
Mark Mitchell 289c40ed97 * demangle.h: Change license to LGPL + exception.
From-SVN: r124174
2007-04-26 02:59:13 +00:00
Joel Brobecker 0c9bce0b5c filenames.h (FILENAME_CMP): Adjust define to call filename_cmp regardless of the type of file system.
* filenames.h (FILENAME_CMP): Adjust define to call filename_cmp
        regardless of the type of file system.

From-SVN: r123343
2007-03-29 20:55:57 +00:00
Jan Hubicka 52bf96d2f2 errors.h (warning, [...]): Mark as cold.
* errors.h (warning, error, fatal, internal_error): Mark as cold.
	* predict.c (maybe_hot_bb): Cold functions are never hot; hot functions
	are hot.
	(probably_cold_bb_p): Cold functions are cold.
	(probably_never_executed_bb_p): Cold functions are cold.
	(tree_bb_level_predictions): Predict calls to cold functions as not
	taken.
	(compute_function_frequency): Check hot/cold attributes.
	* function.h (function_frequency): Update comments.
	* predict.def (PRED_COLD_FUNCTION): Predict cold function.
	* c-common.c (handle_hot_attribute, handle_cold_attribute): New.
	(c_common_att): Add cold and hot.

	* doc/extend.texi (hot,cold attributes): Document.
	
	* ansidecl.h (ATTRIBUTE_COLD, ATTRIBUTE_HOT): New.

From-SVN: r122632
2007-03-06 18:57:27 +00:00
Joseph Myers fb6d0a04a7 * libiberty.h (pex_write_input): Remove prototype.
From-SVN: r121755
2007-02-09 15:28:13 +00:00
Vladimir Prus 7cf4c53d1e libiberty.h (PEX_STDERR_TO_PIPE): New define.
include/
        * libiberty.h (PEX_STDERR_TO_PIPE): New define.
        (PEX_BINARY_ERROR): New define.
        (pex_read_err): New function.

        libiberty/
        * pex-common.h (struct pex_obj): New fields
        stderr_pipe and read_err.
        * pex-common.c (pex_init_common): Initialize
        stderr_pipe.

From-SVN: r121430
2007-01-31 18:40:34 +00:00
Simon Baldwin 456cc5cf65 demangle.h: New cplus_demangle_print_callback...
include/:
	* demangle.h: New cplus_demangle_print_callback,
	cplus_demangle_v3_callback, and java_demangle_v3_callback function
	prototypes, and demangle_callbackref type definition.
libiberty/:
	* cp-demangle.h (cplus_demangle_operators): External definition
	suppressed if not building for libstdc++.
	* cp-demangle.c (__gcclibcxx_demangle_callback): Augmented interface
	to demangling, provides a malloc-less version of __cxa_demangle.
	(cplus_demangle_print_callback): Public callback version of
	cplus_demangle_print.
	(struct d_growable_string): New growable string structure.
	(d_growable_string_init): New function, provides support for
	growable strings separate from print info.
	(d_growable_string_resize): Likewise.
	(d_growable_string_append_buffer): Likewise.
	(d_growable_string_callback_adapter):): Likewise.
	(d_print_init): New print info initialization function.
	(d_print_error): Macro replace by inline function.
	(d_print_saw_error): Likewise.
	(d_append_char): Likewise.
	(d_append_buffer): Likewise.
	(d_append_string): New inline function, replaces the
	d_append_string_constant macro.
	(d_flush_buffer): New function, flushes buffer to callback.
	(d_demangle_callback, is_ctor_or_dtor): Malloc-based fallback
	for unsupported dynamic arrays replaced by alloca().
	(d_demangle): Return string length estimating removed.
	(d_dump): Moved error case handling from call site into function.
	(d_print_resize): Function removed.
	(d_print_append_char): Likewise.
	(d_print_append_buffer): Likewise.
	(d_print_error): Likewise.
	(d_print_comp): Added special case handling for Java arrays.
	(java_demangle_v3): Removed string post-processing for Java arrays,
	now replaced by special case handling in d_print_comp.
	(cplus_demangle_v3_callback): Augmented interface to demangling,
	provides a malloc-less version of cplus_demangle_v3.
	(java_demangle_v3_callback): Augmented interface to demangling,
	provides a malloc-less version of java_demangle_v3.

From-SVN: r121305
2007-01-29 20:07:49 +00:00
Nick Clifton 0307c64eea * ansidecl.h (ATTRIBUTE_PACKED): Define.
From-SVN: r119587
2006-12-06 18:08:51 +00:00
Andrew Stubbs 334737afb7 re PR driver/29931 (following argv[0] symlink in process_command breaks symlinked-together toolchain)
include:
2006-05-03  Andrew Stubbs  <andrew.stubbs@st.com>
            J"orn Rennecke <joern.rennecke@st.com>

	PR driver/29931
	* libiberty.h (make_relative_prefix_ignore_links): Declare.

libiberty:
2006-05-03  Andrew Stubbs  <andrew.stubbs@st.com>
            J"orn Rennecke <joern.rennecke@st.com>

	PR driver/29931
	* make-relative-prefix.c (make_relative_prefix_1): New function,
	broken out of make_relative_prefix.  Make link resolution dependent
	on new parameter.
	(make_relative_prefix): Use make_relative_prefix_1.
	(make_relative_prefix_ignore_links): New function.

Co-Authored-By: J"orn Rennecke <joern.rennecke@st.com>

From-SVN: r119366
2006-11-30 17:05:45 +00:00
Bob Wilson fbee3d219a xtensa-config.h (XSHAL_ABI): New.
* xtensa-config.h (XSHAL_ABI): New.
	(XTHAL_ABI_WINDOWED, XTHAL_ABI_CALL0): New.

From-SVN: r119261
2006-11-27 20:15:58 +00:00
Jim Blandy 8eff378c61 pex-common.c (pex_input_file, [...]): New functions.
src/libiberty/ChangeLog:
2006-03-29  Jim Blandy  <jimb@codesourcery.com>

	* pex-common.c (pex_input_file, pex_input_pipe): New functions.
	(pex_init_common): Initialize obj->input_file.
	(pex_run): Close any file opened by pex_input_file.
	* pexecute.txh (pex_input_file, pex_input_pipe): New docs.
	* pex-common.h (struct pex_obj): New field input_file.
	(struct pex_funcs): New function ptr fdopenw.
	* pex-unix.c (pex_unix_fdopenw): New function.
	(funcs): List it as our fdopenw function.
	* pex-win32.c (pex_win32_fdopenw): New function.
	(funcs): List it as our fdopenw function.
	* pex-djgpp.c (funcs): Leave fdopenw null.
	* pex-msdos (funcs): Same.
	* functions.texi: Regenerated.

src/include/ChangeLog:
2006-04-10  Jim Blandy  <jimb@codesourcery.com>

	* libiberty.h (pex_input_file, pex_input_pipe): New declarations.

From-SVN: r112883
2006-04-12 06:29:21 +00:00
DJ Delorie 78e97e7f13 * md5.h: Include ansidecl.h
From-SVN: r109910
2006-01-18 15:21:59 -05:00
Bob Wilson 134c8a506f xtensa-config.h (XCHAL_HAVE_MUL32_HIGH): Define.
include:
	* xtensa-config.h (XCHAL_HAVE_MUL32_HIGH): Define.
gcc:
	* config/xtensa/ieee754-df.S: New file.
	* config/xtensa/ieee754-sf.S: New file.
	* config/xtensa/t-xtensa (LIB2FUNCS_EXTRA): Remove fp-bit.c & dp-bit.c.
	(LIB1ASMFUNCS): Add SFmode and DFmode floating-point functions.
	* config/xtensa/lib1funcs.asm: Include ieee754-df.S and ieee754-sf.S.

From-SVN: r109518
2006-01-09 23:41:11 +00:00
Bob Wilson 4fb358b857 xtensa-config.h (XCHAL_HAVE_WIDE_BRANCHES): New.
include/
	* xtensa-config.h (XCHAL_HAVE_WIDE_BRANCHES): New.

From-SVN: r109191
2005-12-31 00:29:42 +00:00
Terry Laurenzo 92aed1cbf4 Fixes java/PR9861
From-SVN: r108374
2005-12-11 01:34:02 +00:00
Mark Kettenis 0432a5de96 from Mark Kettenis <kettenis@gnu.org>
* floatformat.c (floatformat_vax_aingle, floatformat_vax_double):
New variables.

* floatformat.h (enum floatformat_byteorders): Add
floatformat_vax.
(floatformat_vax_aingle, floatformat_vax_double): Declare.

From-SVN: r106281
2005-10-31 12:52:38 -05:00
Mark Mitchell 97393d0a03 libiberty.h (expandargv): New function.
* libiberty.h (expandargv): New function.

	* argv.c (safe-ctype.h): Include it.
	(ISBLANK): Remove.
	(stdio.h): Include.
	(buildargv): Use ISSPACE instead of ISBLANK.
	(expandargv): New function.

From-SVN: r104664
2005-09-26 20:55:10 +00:00
Mark Kettenis e89b6c1c1e floatformat.c (floatformat_always_valid): Change type of last argument to `void *'.
[libiberty]
* floatformat.c (floatformat_always_valid): Change type of last
argument to `void *'.
(floatformat_i387_ext_is_valid): Likewise.
(floatformat_to_double): Change type of second argument to `const
void *'.
(floatformat_from_double): Change type of last argument to `void
*'.
(floatformat_is_valid): Change type of last argument to `const
void *'.
(ieee_test): Remove redundant casts.
[include]
* floatformat.h (struct floatformat): Change type of large
argument for is_valid member to `const void *'.
(floatformat_to_double): Change type of second argument to `const
void *'.
(floatformat_from_double): Change type of last argument to `void
*'.
(floatformat_is_valid): Change type of last argument to `const
void *'.

From-SVN: r103218
2005-08-17 13:30:47 -04:00
Ben Elliston 12548280a2 xregex2.h (regexec): Qualify this prototype with __extension__ when compiling with GNU C.
* xregex2.h (regexec): Qualify this prototype with __extension__
	when compiling with GNU C.

From-SVN: r101910
2005-07-12 14:39:07 +10:00
Steve Ellcey 3fe725de2a re PR other/13906 (genmodes.c:964: internal compiler error: Bus error in md5_process_block)
PR other/13906
	* ansidecl.h (ATTRIBUTE_ALIGNED_ALIGNOF): New.
	* md5.h (md5_uintptr): New.
	(md5_ctx): Align buffer field.

From-SVN: r101556
2005-07-03 15:38:39 +00:00
Daniel Berlin a3648cfc0c [multiple changes]
2005-06-29  Daniel Berlin  <dberlin@dberlin.org>

	* tree-complex.c (complex_variable_components): Now a hashtable.
	(cvc_lookup): Ditto.
	(cvc_insert): Ditto.
	(create_components): Use referenced var iterator.
	Initialize hashtable.	Use cvc_insert/lookup.
	(extract_components): Use cvc_insert/lookup.
	(update_complex_components): Ditto.
	(update_complex_components_on_edge): Ditto.
	* tree-dfa.c (referenced_vars): Now a hashtable.
	(dump_referenced_vars): Use iterator.
	(referenced_var_lookup): New function.
	(referenced_var_insert): Ditto.
	(add_referenced_var): Use referenced_var_insert.
	(mark_new_vars_to_rename): Use DECL_UID.
	* tree-flow-inline.h (first_htab_element): New function.
	(end_htab_p): Ditto.
	(next_htab_element): Ditto.
	(first_referenced_var): Ditto.
	(end_referenced_vars_p): Ditto.
	(next_referenced_var): Ditto.
	(is_call_clobbered): Use DECL_UID.
	(mark_call_clobbered): Ditto.
	(clear_call_clobbered): Ditto.
	(mark_non_addressable): Ditto.
	* tree-flow.h (htab_iterator): New struct.
	(FOR_EACH_HTAB_ELEMENT): New macro.
	(struct int_tree_map): New struct.
	(int_tree_map_hash): Prototype.
	(int_tree_map_eq): Ditto.
	(referenced_var_iterator): Ditto.
	(FOR_EACH_REFERENCED_VAR): New macro.
	(referenced_vars): Now a hashtable.
	* tree-into-ssa.c (symbol_marked_for_renaming): Use DECL_UID.
	(add_new_name_mapping): Ditto.
	(mark_def_sites): Ditto.
	(insert_phi_nodes): Use referenced_var iterator.
	(mark_def_site_blocks): Ditto.
	(mark_sym_for_renaming): Use DECL_UID.
	* tree-sra.c (is_sra_candidate_decl): Use DECL_UID.
	(lookup_element): Ditto.
	(find_candidates_for_sra): Use referenced_vars iterator.
	Use DECL_UID.
	* tree-ssa-alias.c (NUM_REFERENCES): New macro.
	(NUM_REFERENCES_CLEAR): Ditto.
	(NUM_REFERENCES_INC): Ditto.
	(NUM_REFERENCES_SET): Ditto.
	(alias_obstack): New bitmap obstack.
	(struct alias_map_d): Use bitmap, not sbitmap.
	(struct alias_info): Remove num_references.
	(init_alias_info): Use referenced_var iterator.
	Initialize bitmap obstack.
	(delete_alias_info): Use referenced_var iterator.
	Free bitmap obstack.
	(compute_points_to_and_addr_escape): Use DECL_UID.
	Use new NUM_REFERENCES macros.
	(compute_flow_sensitive_aliasing): may_aliases is now a bitmap.
	Use new NUM_REFERENCES macros.
	(group_aliases_into): Update prototype to use bitmap.
	(setup_pointers_and_addressables): Use referenced_vars iterator.
	Use DECL_UID. Use new NUM_REFERENCES macros.
	(add_pointed_to_var): Use DECL_UID.
	(dump_alias_info): Use referenced_var iterator.
	(add_type_alias): Ditto.
	(used_portions): Now a hashtable.
	(used_part_map_eq): New function.
	(used_part_map_hash): Ditto.
	(free_used_part_map): Ditto.
	(up_lookup): Ditto.
	(up_insert): Ditto.
	(get_or_create_used_part_for): Use up_lookup.
	(create_overlap_variables_for): Ditto.
	(find_used_portions): Use up_insert.
	Use DECL_UID.
	(create_structure_vars): Init used_portions hashtable, use
	referenced_vars iterator.
	* tree-ssa-live.c (create_ssa_var_map): sbitmaps became bitmaps.
	Use DECL_UID.
	* tree-ssa-loop-im.c (gather_mem_refs_stmt): Use DECL_UID.
	* tree-ssa-operands.c (get_asm_expr_operands): Ditto.
	(note_addressable): Ditto.
	* tree-ssa-structalias.c (set_uids_in_ptset): Ditto.
	* tree-ssa.c (verify_flow_insensitive_alias_info): Use
	referenced_var iterator.
	Use DECL_UID.
	(delete_tree_ssa): Ditto.
	(int_tree_map_eq): New function.
	(int_tree_map_hash): Ditto.
	* tree-stdarg.c (find_va_list_reference): Use DECL_UID.
	(va_list_ptr_read): Ditto.
	(va_list_counter_struct_op): Ditto.
	(va_list_ptr_write): Ditto.
	(check_va_list_escapes): Ditto.
	(check_all_va_list_escapes): Ditto.
	(execute_optimize_stdarg): Ditto.
	* tree-tailcall.c (suitable_for_tail_opt_p): Used referenced_var
	iterator.
2005-06-30  Daniel Berlin  <dberlin@dberlin.org>

	* hashtab.h (HTAB_DELETED_ENTRY): New macro.
	(HTAB_EMPTY_ENTRY): New macro.

2005-06-30  Daniel Berlin  <dberlin@dberlin.org>

	* hashtab.c (EMPTY_ENTRY): Moved and renamed.
	(DELETED_ENTRY): Ditto.

From-SVN: r101480
2005-06-30 22:18:42 +00:00
Geoffrey Keating 83fbfe42c2 Index: include/ChangeLog
2005-06-20  Geoffrey Keating  <geoffk@apple.com>

	* libiberty.h (strverscmp): Prototype.

Index: libiberty/ChangeLog
2005-06-20  Geoffrey Keating  <geoffk@apple.com>

	* strverscmp.c: New.
	* Makefile.in (CFILES): Add strverscmp.c.
	(CONFIGURED_OFILES): Add strverscmp.o.
	(strverscmp.o): New rule.
	(stamp-functions): Add $(srcdir) to files in source directory.
	* configure.ac (funcs): Add strverscmp.
	(AC_CHECK_FUNCS): Add strverscmp.
	* configure: Regenerate.
	* functions.texi: Regenerate.

From-SVN: r101226
2005-06-21 00:24:59 +00:00
Gabriel Dos Reis 7973fd2aed libiberty.h (XOBFINISH): New.
libiberty/
2005-06-06  Gabriel Dos Reis  <gdr@integrable-solutions.net>

        * libiberty.h (XOBFINISH): New.

gcc/
2005-06-06  Gabriel Dos Reis  <gdr@integrable-solutions.net>

        * c-lex.c (lex_string): Use XOBFINISH.
        * collect2.c (extract_string, dump_file): Likewise.
        * dbxout.c (dbxout_finish_complex_stabs): Likewise.
        * gcc.c (init_spec, build_search_list, convert_filename,
        set_collect_gcc_options, do_spec_2, do_spec_1, main):
        * Likewise.
        * genpreds.c (write_predicate_subfunction): Likewise.
        * genflags.c (main): Likewise.
        * read-rtl.c (mode_attr_index, apply_macro_to_string,
        join_c_conditions, read_quoted_string, read_braced_string,
        read_rtx_1): Likewise.
        * stringpool.c (ggc_alloc_string): Likewise.
        * tlink.c (obstack_fgets, recompile_files): Likewise.

From-SVN: r100678
2005-06-06 21:14:31 +00:00
Kaveh R. Ghazi 39da352fad * libiberty.h (vsnprintf): Add format attribute.
From-SVN: r100476
2005-06-02 02:01:03 +00:00
Kaveh R. Ghazi b6e0f0b0d7 * ansidecl.h: Add ATTRIBUTE_FPTR_PRINTF.
From-SVN: r100334
2005-05-30 00:04:09 +00:00
Eli Zaretskii ddcf783b59 libiberty.h: (snprintf) [!HAVE_DECL_SNPRINTF]: Declare if needed.
include:
2005-05-28  Eli Zaretskii  <eliz@gnu.org>

	* libiberty.h: (snprintf) [!HAVE_DECL_SNPRINTF]: Declare if
	needed.
	(vsnprintf) [!HAVE_DECL_VSNPRINTF]: Declare if needed.

libiberty:
2005-05-28  Eli Zaretskii  <eliz@gnu.org>

	* configure.ac: Add snprintf and vsnprintf to AC_CHEK_DECLS.
	* config.in, configure: Regenerate.

From-SVN: r100292
2005-05-28 13:40:59 +02:00
Richard Henderson 15da280693 demangle.h (DEMANGLE_COMPONENT_HIDDEN_ALIAS): New.
include/
	* demangle.h (DEMANGLE_COMPONENT_HIDDEN_ALIAS): New.
libiberty/
	* cp-demangle.c (d_dump): Handle DEMANGLE_COMPONENT_HIDDEN_ALIAS.
	(d_make_comp, d_print_comp): Likewise.
	(d_special_name): Generate one.
	* testsuite/demangle-expected: Add a hidden alias test.

From-SVN: r100174
2005-05-25 16:29:54 -07:00
Gabriel Dos Reis d7cf8390c7 libiberty.h (ACONCAT): Properly cast value of alloca().
include/
2005-05-24  Gabriel Dos Reis  <gdr@integrable-solutions.net>

	* libiberty.h (ACONCAT): Properly cast value of alloca().

	* ansidecl.h (ATTRIBUTE_UNUSED_LABEL): Don't define if
	__cplusplus.

libiberty/
2005-05-24  Gabriel Dos Reis  <gdr@integrable-solutions.net>

	* configure.ac: Check declarations for calloc(), getenv(),
	malloc(), realloc() and sbrk().
	* config.in: Regenerate.
	* configure: Likewise.

	* alloca.c (C_alloca): Change "new" to "new_storage".  Use XNEWVEC
	instead of xmalloc.
	* choose-temp.c (choose_temp_base): Use XNEWVEC instea od xmalloc.
	* concat.c (liiberty_concat_ptr): Surround definition with an
	extern "C" block, if __cplusplus.
	(concat): Use XNEWVEC instead of xmalloc.
	(reconcat): Likewise.
	* cp-demangle.c (struct d_print_template): Rename member
	"template" to "template_decl".  Adjust use throughout the file.
	(d_print_resize): Properly cast return value of realloc().
	(cplus_demangle_print): Same for malloc().
	(d_demangle): Likewise.
	* cp-demint.c (cplus_demangle_fill_builtin_type): Rename parameter
	"typename" to "type_name".
	* cplus-dem.c (grow_vect): Use XRESIZEVEC instead of xrealloc().
	(work_stuff_copy_to_from): Use XNEWVEC insteand of xmalloc().
	(demangle_template_value_parm): Likewise.
	(demangle_template): Likewise.
	(recursively_demangle): Likewise.
	(do_hpacc_template_literal): Likewise.
	(do_arg): Likewise.
	(remember_type): Likewise.
	(remember_Ktype): Likewise.
	(register_Btype): Likewise.
	(string_need): Use XRESIZEVEC instead of xrealloc().
	* dyn-string.c (dyn_string_init): Use XNEWVEC.
	(dyn_string_new): Use XNEW.
	(dyn_string_resize): Use XRESIZEVEC.
	* fnmatch.c (fnmatch): Rename local variable "not" to "negate".
	* getopt.c (getenv): Declare only if !__cplusplus and !getenv.
	Otherwise include <stdlib.h>.
	(exchange): Cast return value of malloc().
	* hashtab.c (htab_size): Define as both macro and non-inline
	function.
	(htab_elements): Likewise.
	* getpwd.c (getpwd): Use XNEWVEC.
	(htab_create_alloc_ex): Use C90 prototype-style.
	* lrealpath.c (lrealpath): Appropriately cast return value of
	malloc().
	* make-relative-prefix.c (save_string): Likewise.
	* make-temp-file.c (try_dir): Rename from "try".  Adjust use in
	the file.
	(choose_tmpdir): Use XNEWVEC.
	* mkstemps.c (mkstemps): Rename parameter "template" to "pattern".
	* pex-common.c (pex_init_common): Use XNEW.
	(pex_add_remove): Use XRESIZEVEC.
	(pex_run): Likewise.
	(pex_get_status_and_time): Likewise.
	* pex-djgpp.c (pex_djgpp_exec_child): Likewise.
	* pex-msdos.c (pex_init): Use XNEW.
	(pex_msdos_exec_child): Likewise.
	(pex_msdos_exec_child): Use XRESIZEVEC.
	* pex-unix.c (pex_wait): Use XNEW.
	* pex-win32.c (fix_argv): Use XNEWVEC.
	* pexecute.c (pwait): Likewise.
	* setenv.c (setenv): Properly cast return value of malloc().
	* sigsetmask.c (sigsetmask): Rename local variables "old" and
	"new" to "old_sig" and "new_sig".
	* sort.c (main): Use XNEWVEC.
	* spaces.c (spaces): Cast return value of malloc().
	* strndup.c (strndup): Likewise.
	* ternary.c (ternary_insert): Use XNEW.
	* xmalloc.c (malloc, realloc, calloc, sbrk): Surround declaration
	with an extern "C" block if __cplusplus.
	* xstrdup.c (xstrdup): Cast return value of memcpy().
	* xstrerror.c (strerror): Enclose declaration in an extern "C"
	block if __cplusplus.
	* xstrndup.c (xstrndup): Use XNEW. Cast return value of memcpy().

From-SVN: r100115
2005-05-24 20:48:25 +00:00
Steve Ellcey dbaef7e22b libiberty.h: Do not define empty basename prototype.
From-SVN: r99626
2005-05-12 19:29:53 +00:00
Nick Clifton d6d47ea0f5 Update the address and phone number of the FSF organization.
From-SVN: r99518
2005-05-10 15:22:21 +00:00
Kaveh R. Ghazi 32e82bd896 libiberty.h (unlock_std_streams): New.
include:
	* libiberty.h (unlock_std_streams): New.

libiberty:
	* fopen_unlocked.c (unlock_std_streams): New.

	* functions.texi: Regenerate.

From-SVN: r98746
2005-04-26 00:14:35 +00:00
Kaveh R. Ghazi 8766be8685 hashtab.h, [...]: Don't use the PTR macro.
* hashtab.h, libiberty.h, objalloc.h, splay-tree.h, ternary.h:
	Don't use the PTR macro.

	* sort.h: Don't use the PARAMS macro.

From-SVN: r98416
2005-04-19 18:26:43 +00:00
Kaveh R. Ghazi 6feaa084f8 libiberty.h (unlock_stream): New.
include:
	* libiberty.h (unlock_stream): New.

libiberty:
	* fopen_unlocked.c (unlock_stream): New.
	Consolidate unlocking code into a helper function.

	* functions.texi: Regenerate.

From-SVN: r98234
2005-04-16 16:58:35 +00:00
Kaveh R. Ghazi 27c556ecda libiberty.h (fopen_unlocked, [...]): Remove parameter names.
* libiberty.h (fopen_unlocked, fdopen_unlocked, freopen_unlocked):
	Remove parameter names.

From-SVN: r98121
2005-04-14 01:42:05 +00:00
Kaveh R. Ghazi 78a7dc9032 libiberty.h (fopen_unlocked, [...]): Provide prototypes for new functions.
include:
	* libiberty.h (fopen_unlocked, fdopen_unlocked, freopen_unlocked):
	Provide prototypes for new functions.

libiberty:
	* Makefile.in (CFILES): Add fopen_unlocked.c.
	(REQUIRED_OFILES): Add ./fopen_unlocked.o.
	Regenerate dependencies.

	* configure.ac: Check for stdio_ext.h and __fsetlocking.

	* fopen_unlocked.c: New file.

	* functions.texi, configure, config.in: Regenerate.

From-SVN: r97977
2005-04-11 17:49:47 +00:00
Ian Lance Taylor 0fd20f3614 * libiberty.h: Fix indentation.
From-SVN: r97196
2005-03-29 18:35:07 +00:00
Ian Lance Taylor a584cf65fa pex-common.c: New file.
libiberty:
	* pex-common.c: New file.
	* pex-one.c: New file.
	* pexecute.c: New file.
	* pex-common.h: Include <stdio.h>.
	(struct pex_obj): Define.
	(struct pex_funcs): Define.
	(pex_init_common): Declare.
	* pex-unix.c: Rewrite.
	* pex-win32.c: Rewrite.
	* pex-djgpp.c: Rewrite.
	* pex-msdos.c: Rewrite.
	* testsuite/text-pexecute.c: New file.
	* pexecute.txh: Rewrite.
	* configure.ac: Check for wait3 and wait4.  Set CHECK to
	really-check rather than check-cplus-dem.
	* functions.texi: Rebuild.
	* Makefile.in: Rebuild dependencies.
	(CFILES): Add pexecute.c, pex-common.c, pex-one.c.
	(REQUIRED_OFILES): Add pexecute.o, pex-common.o, pex-one.o.
	* testsuite/Makefile.in (really-check): New target.
	(check-pexecute, test-pexecute): New targets.
	* configure: Rebuild.
include:
	* libiberty.h: Include <stdio.h>.
	(PEX_RECORD_TIMES, PEX_USE_PIPES, PEX_SAVE_TEMPS): Define.
	(PEX_LAST, PEX_SEARCH, PEX_SUFFIX, PEX_STDERR_TO_STDOUT): Define.
	(PEX_BINARY_INPUT, PEX_BINARY_OUTPUT): Define.
	(pex_init, pex_run, pex_read_output): Declare.
	(pex_get_status, pex_get_times, pex_free, pex_one): Declare.
	(struct pex_time): Define.

From-SVN: r97148
2005-03-29 02:08:46 +00:00
Mark Mitchell f78c1452ea * libiberty.h (ffs): Declare, if necessary.
From-SVN: r97147
2005-03-29 01:10:31 +00:00
Gabriel Dos Reis 93079c819b xregex2.h (_RE_ARGS): Remove definition and uses.
include/
2005-03-27  Gabriel Dos Reis  <gdr@integrable-solutions.net>

        * xregex2.h (_RE_ARGS): Remove definition and uses.

libiberty/
2005-03-27  Gabriel Dos Reis  <gdr@integrable-solutions.net>

        Convert libiberty to use ISO C prototype style 7/n.
        * regex.c (PARAMS): Remove definition.
        (PREFIX): Unconditionaly define using ISO C ## operator.
        (init_syntax_once, extract_number, extract_number_and_incr,
        print_fastmap, print_partial_compiled_pattern,
        print_compiled_pattern, print_double_string, printchar,
        convert_mbs_to_wcs, re_set_syntax, regex_grow_registers,
        regex_compile, store_op1, store_op2, insert_op1, insert_op2,
        at_begline_loc_p, at_endline_p, group_in_compile_stack,
        insert_space, wcs_compile_range, byte_compile_range,
        truncate_wchar, re_compile_fastmap, re_compile_fastmap,
        re_set_registers, re_search, re_search_2, re_search_3,
        re_match,
        re_match_2, count_mbs_length, wcs_re_match_2_internal,
        byte_re_match_2_internal, group_match_null_string_p,
        alt_match_null_string_p, common_op_match_null_string_p,
        bcmp_translate, re_compile_pattern, re_comp, re_exec, regcomp,
        regexec, regerror, regfree): Use ISO C prototype style.
        * partition.c: (elem_compare): Likewise.
        * cp-demangle.c (print_usage): Likewise.

From-SVN: r97129
2005-03-28 08:34:12 +00:00
Gabriel Dos Reis 885f2199f3 partition.h: Remove use of PARAMS.
include/
2005-03-27  Gabriel Dos Reis  <gdr@integrable-solutions.net>

        * partition.h: Remove use of PARAMS.
        * obstack.h: Remove conditional prototypes __STDC__.
        * objalloc.h:  Remove use of PARAMS.
        * splay-tree.h: Likewise.

libiberty/
2005-03-27  Gabriel Dos Reis  <gdr@integrable-solutions.net>

        Convert libiberty to use ISO C prototype style 5/n.
        * random.c (srandom, initstate, setstate, random): Use ISO C
        prototypes.
        * putenv.c (putenv): Likewise.
        * physmem.c (physmem_available, physmem_total, main):
        Likewise.
        * pex-win32.c (fix_argv, pexecute, pwait): Likewise.
        * pex-unix.c (pexecute, pwait): Likewise.
        * pex-msdos.c (pexecute, pwait): Likewise.
        * pex-djgpp.c (pexecute, pwait): Likewise.
        * partition.c (partition_new, partition_delete,
        partition_union)
        (elem_compare, partition_print): Likewise.
        * obstack.c (_obstack_begin, _obstack_begin_1,
        _obstack_newchunk,
        _obstack_allocated_p, _obstack_free, obstack_free,
        _obstack_memory_used, print_and_abort, obstack_next_free,
        obstack_object_size, obstack_base): Likewise.  Remove codes
        predicated on !defined(__STDC__).
        * objalloc.c (objalloc_create, _objalloc_alloc, objalloc_free,
        objalloc_free_block): Use ISO C prototypes.
        * mkstemps.c (mkstemps): Likewise.
        * memset.c (memset): Likewise.
        * mempcpy.c (mempcpy): Likewise.
        * rename.c (rename): Likewise.
        * rindex.c (rindex): Likewise.
        * setenv.c (setenv, unsetenv): Likewise.
        * sigsetmask.c (sigsetmask): Likewise.
        * snprintf.c (snprintf): Likewise.
        * sort.c (sort_pointers, xmalloc): Likewise.
        * spaces.c (spaces): Likewise.
        * splay-tree.c (splay_tree_delete_helper,
        splay_tree_splay_helper, splay_tree_splay,
        splay_tree_foreach_helper, splay_tree_xmalloc_allocate,
        splay_tree_new, splay_tree_xmalloc_allocate,
        splay_tree_new_with_allocator, splay_tree_delete,
        splay_tree_insert, splay_tree_remove, splay_tree_lookup,
        splay_tree_max, splay_tree_min, splay_tree_predecessor,
        splay_tree_successor, splay_tree_foreach,
        splay_tree_compare_ints, splay_tree_compare_pointers):
        Likewise.
        * stpcpy.c (stpcpy): Likewise.
        * stpncpy.c (stpncpy): Likewise.
        * strcasecmp.c (strcasecmp): Likewise.
        * strchr.c (strchr): Likewise.
        * strdup.c (strdup): Likewise.

From-SVN: r97125
2005-03-28 04:22:33 +00:00
Gabriel Dos Reis 7a17ef5e63 ternary.h: Don't use PARAMS anymore.
include/
2005-03-27  Gabriel Dos Reis  <gdr@integreable-solutions.net>

        * ternary.h: Don't use PARAMS anymore.

libiberty/
2005-03-27  Gabriel Dos Reis  <gdr@integrable-solutions.net>

        Convert libiberty to use ISO C prototype style 6/n.
        * strerror.c (init_error_tables, errno_max, strerror,
        strerrno,
        strtoerrno, main): Use ISO C prototype style.
        * strncasecmp.c (strncasecmp): Likewise.
        * strncmp.c (strncmp): Likewise.
        * strndup.c (strndup): Likewise.
        * strrchr.c (strrchr): Likewise.
        * strsignal.c (init_signal_tables, signo_max, strsignal,
        strsigno, strtosigno, psignal, main): Likewise.
        * strstr.c (strstr): Likewise.
        * strtod.c (strtod, atof): Likewise.
        * strtol.c (strtol): Likewise.
        * strtoul.c (strtoul): Likewise.
        * ternary.c (ternary_insert, ternary_cleanup, ternary_search,
        ternary_recursivesearch): Likewise.
        * tmpnam.c (tmpnam): Likewise.
        * unlink-if-ordinary.c (unlink_if_ordinary): Likewise.
        * vasprintf.c (int_vasprintf, vasprintf, checkit, main):
        Likewise.
        * vfork.c (vfork): Likewise.
        * vfprintf.c (vfprintf): Likewise.
        * vprintf.c (vprintf): Likewise.
        * vsnprintf.c (vsnprintf, checkit, main): Likewise.
        * vsprintf.c (vsprintf): Likewise.
        * waitpid.c (waitpid): Likewise.
        * xatexit.c (xatexit, xatexit_cleanup): Likewise.
        * xexit.c (xexit): Likewise.
        * xmalloc.c (xmalloc_set_program_name, xmalloc_failed,
        xmalloc,
        xcalloc, xrealloc): Likewise.
        * xmemdup.c (xmemdup): Likewise.
        * xstrdup.c (xstrdup): Likewise.
        * xstrerror.c (xstrerror): Likewise.
        * xstrndup.c (xstrndup): Likewise.

From-SVN: r97122
2005-03-28 01:28:01 +00:00
Gabriel Dos Reis 6da879de22 md5.h: Remove definition and uses of __P.
include/
2005-03-27  Gabriel Dos Reis  <gdr@integrable-solutions.net>

	* md5.h: Remove definition and uses of __P.
	* dyn-string.h: Remove uses of PARAMS.
	* fibheap.h: Likewise.
	* floatformat.h: Likewise.
	* hashtab.h: Likewise.

libiberty/

2005-03-27  Gabriel Dos Reis  <gdr@integrable-solutions.net>

	Convert libiberty to use ISO C prototype style 4/n.
	* hashtab.c (higher_prime_index, hash_pointer, eq_pointer,
	htab_size, htab_elements, htab_mod_1, htab_mod, htab_mod_m2,
	htab_create_alloc, htab_set_functions_ex, htab_create,
	htab_try_create, htab_delete, htab_empty,
	find_empty_slot_for_expand, htab_expand, htab_find_with_hash,
	htab_find, htab_find_slot_with_hash, htab_find_slot,
	htab_remove_elt, htab_remove_elt_with_hash, htab_clear_slot,
	htab_traverse_noresize, htab_traverse, htab_collisions,
	htab_hash_string, iterative_hash): Use ISO C prototype.
	* hex.c (hex_init): Likewise.
	* index.c (index): Likewise.
	* insque.c (insque, remque): Likewise.
	* lbasename.c (lbasename): Likewise.
	* lrealpath.c (lrealpath): Likewise.
	* make-relative-prefix.c (save_string, split_directories,
	free_split_directories, make_relative_prefix): Likewise.
	* make-temp-file.c (try, choose_tmpdir, make_temp_file): Likewise.
	* md5.c (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
	md5_buffer, md5_process_bytes, md5_process_block): Likewise.
	* memchr.c (memchr): Likewise.
	* memcpy.c (memcpy): Likewise.
	* memmove.c (memmove): Likewise.
	* gettimeofday.c (gettimeofday): Likewise.
	* getruntime.c (get_run_time): Likewise.
	* getpwd.c (getpwd, getpwd): Likewise.
	* getpagesize.c (getpagesize): Likewise.
	* getopt1.c (getopt_long, getopt_long_only, main): Likewise.
	* getopt.c (my_index, exchange, _getopt_initialize,
	_getopt_internal, getopt, main): Likewise.
	* getcwd.c (getcwd): Likewise.
	* fnmatch.c (fnmatch): Likewise.
	* floatformat.c (floatformat_always_valid,
	floatformat_i387_ext_is_valid, get_field, floatformat_to_double,
	put_field, floatformat_from_double, floatformat_is_valid,
	ieee_test, main): Likewise.
	* fibheap.c (fibheap_new, fibnode_new, fibheap_compare,
	fibheap_comp_data, fibheap_insert, fibheap_min, fibheap_min_key,
	fibheap_union, fibheap_extract_min, fibheap_replace_key_data,
	fibheap_replace_key, fibheap_replace_data, fibheap_delete_node,
	fibheap_delete, fibheap_empty, fibheap_extr_min_node,
	fibheap_ins_root, fibheap_rem_root, fibheap_consolidate,
	fibheap_link, fibheap_cut, fibheap_cascading_cut,
	fibnode_insert_after, fibnode_remove): Likewise.
	* ffs.c (ffs): Likewise.
	* fdmatch.c (fdmatch): Likewise.
	* dyn-string.c (dyn_string_init, dyn_string_new,
	dyn_string_delete, dyn_string_release, dyn_string_resize,
	dyn_string_clear, dyn_string_copy, dyn_string_copy_cstr,
	dyn_string_prepend, dyn_string_prepend_cstr, dyn_string_insert,
	dyn_string_insert_cstr, dyn_string_insert_char,
	dyn_string_append, dyn_string_append_cstr,
	dyn_string_append_char, dyn_string_substring, dyn_string_eq):
	Likewise.

From-SVN: r97113
2005-03-27 15:31:13 +00:00
Gabriel Dos Reis 9486db4fb6 demangle.h: Remove uses of PARAMS.
include/
2005-03-26  Gabriel Dos Reis  <gdr@integrable-solutions.net>

        * demangle.h: Remove uses of PARAMS.

        * libiberty.h (ANSI_PROTOTYPES): Remove guard since
        ANSI_PROTOTYPES is always assumed.
        Remove uses of PARAMS throughout.

libiberty/
2005-03-26  Gabriel Dos Reis  <gdr@integrable-solutions.net>

        Convert libiberty to use ISO C prototype style 2/n.
        * cp-demangle.h: Remove uses of PARAMS.
        * cp-demangle.c: Likewise.
        (d_dump, cplus_demangle_fill_name,
        cplus_demangle_fill_extended_operator,
        cplus_demangle_fill_ctor,
        cplus_demangle_fill_dtor, d_make_empty, d_make_comp,
        d_make_name,
        d_make_builtin_type, d_make_operator,
        d_make_extended_operator,
        d_make_ctor, d_make_dtor, d_make_template_param, d_make_sub,
        cplus_demangle_mangled_name, has_return_type,
        is_ctor_dtor_or_conversion, d_encoding, d_name, d_nested_name,
        d_prefix, d_unqualified_name, d_source_name, d_number,
        d_identifier, d_operator_name, d_special_name, d_call_offset,
        d_ctor_dtor_name, cplus_demangle_type, d_cv_qualifiers,
        d_function_type, d_bare_function_type, d_class_enum_type,
        d_array_type, d_pointer_to_member_type, d_template_param,
        d_template_args, d_template_arg, d_expression, d_expr_primary,
        d_local_name, d_discriminator, d_add_substitution,
        d_substitution, d_print_resize, d_print_append_char,
        d_print_append_buffer, d_print_error, cplus_demangle_print,
        d_print_comp, d_print_java_identifier, d_print_mod_list,
        d_print_mod, d_print_function_type, d_print_array_type,
        d_print_expr_op, d_print_cast, cplus_demangle_init_info,
        d_demangle, __cxa_demangle, cplus_demangle_v3,
        java_demangle_v3,
        is_ctor_or_dtor, is_gnu_v3_mangled_ctor,
        is_gnu_v3_mangled_dtor,
        print_usage, main):

2005-03-26  Gabriel Dos Reis  <gdr@integrable-solutions.net>

        Convert libiberty to ISO C prototype style 1/n.
        * _doprnt.c: Remove conditional #include <varargs.h> on
        ANSI_PROTOTYPES as the latter is always assumed.
        (_doprnt, checkit, main): Use ISO C prototype.
        * alloca.c (find_stack_direction, C_alloca): Use ISO C
        prototype.
        * argv.c: Remove conditional #includes on ANSI_PROTOTYPES.
        (dupargv, freeargv, buildargv, main): Use ISO C prototype.
        * atexit.c (atexit): Likewise
        * asprintf.c: Remove conditional include on ANSI_PROTOTYPES.
        (asprintf): Use ISO C prototype.
        * basename.c (basename): Likewise
        * bcmp.c (bcmp): Likewise.
        * bcopy.c (bcopy): Likewise.
        * bzero.c (bzero): Likewise.
        * bsearch.c (bsearch): Likewise.  Improve const-correctness.
        * choose-temp.c (choose_temp_base): Likewise.
        * calloc.c: Remove conditional #include on ANSI_PROTOTYPES.
        (calloc): Use ISO C prototype.
        * clock.c (clock): Likewise.
        * concat.c: Remove conditional #include on ANSI_PROTOTYPES.
        (vconcat_length, vconcat_copy, concat_length, concat_copy,
        concat_copy2, concat, reconcat, main): Use ISO C prototype.
        * copysign.c (copysign): Likewise.

From-SVN: r97085
2005-03-26 19:24:33 +00:00
Kaveh R. Ghazi 17998b22b5 libiberty.h (xstrndup): Declare.
include:
	* libiberty.h (xstrndup): Declare.

libiberty:
	* Makefile.in (CFILES): Add strndup.c and xstrndup.c.
	(REQUIRED_OFILES): Add xstrndup.o.
	(CONFIGURED_OFILES): Add strndup.o.
	Regenerate dependencies.

	* configure.ac (funcs, AC_CHECK_FUNCS): Add strndup.

	* strndup.c, xstrndup.c: New.

	* config.in, configure, functions.texi: Regenerate.

From-SVN: r97034
2005-03-25 04:41:41 +00:00
Kaveh R. Ghazi 65ec6c0eb2 * libiberty.h (make_relative_prefix): Add ATTRIBUTE_MALLOC.
From-SVN: r96904
2005-03-22 23:47:49 +00:00
Mark Mitchell 17049f0bbb libiberty.h (gettimeofday): Declare.
* libiberty.h (gettimeofday): Declare.

	* configure.ac (funcs): Add gettimeofday.
	* configure: Regenerated.
	* gettimeofday.c: New file.
	* Makefile.in (CFILES): Add gettimeofday.
	(CONFIGURED_OFILES): Add gettimeofday.o.
	(./gettimeofday.o): New rule.

From-SVN: r96230
2005-03-10 00:57:10 +00:00
Jan Beulich c363985db8 libiberty.h: Declare unlink_if_ordinary.
include/
2005-03-01  Jan Beulich  <jbeulich@novell.com>

	* libiberty.h: Declare unlink_if_ordinary.

libiberty/
2005-03-01  Jan Beulich  <jbeulich@novell.com>

	* Makefile.in (CFILES): Add unlink-if-ordinary.c
	(REQUIRED_OFILES): Add unlink-if-ordinary.o.
	Add dependencies and rule for unlink-if-ordinary.o.
	* unlink-if-ordinary.c: New.

From-SVN: r95732
2005-03-01 09:23:26 +00:00
Paolo Bonzini be0f1e5478 re PR bootstrap/19818 (GCC 4.0 cannot bootstrap itself)
include:
2005-02-08  Paolo Bonzini  <bonzini@gnu.org>

	PR bootstrap/19818
	* ansidecl.h (PARAMS): Guard from redefinition.

libcpp:
2005-02-08  Paolo Bonzini  <bonzini@gnu.org>

	PR bootstrap/19818
	* configure.ac: Check for declaration of basename and getopt.
	* config.in: Regenerate.
	* configure: Regenerate.
	* internal.h (ustrcspn): New.
	* macro.c (create_iso_definition): Fix allocation of memory.
	(padding_token): Add cast to remove const-ness.
	* pch.c (cpp_read_state): Use ustrcspn.

From-SVN: r95003
2005-02-14 08:52:24 +00:00
Ben Elliston d49d090735 fibheap.h (struct fibnode): Only use unsigned long bitfields when __GNUC__ is defined and ints are less...
[include]
	* fibheap.h (struct fibnode): Only use unsigned long bitfields
	when __GNUC__ is defined and ints are less than 32-bits wide.
[libiberty]
	* configure.ac: Invoke AC_CHECK_SIZEOF for sizeof (int).
	* configure: Regenerate.
	* config.in: Likewise.

From-SVN: r92009
2004-12-11 08:25:00 +11:00
Bob Wilson 530f533138 xtensa-config.h (XSHAL_USE_ABSOLUTE_LITERALS, [...]): New.
2004-10-07  Bob Wilson  <bob.wilson@acm.org>
        * xtensa-config.h (XSHAL_USE_ABSOLUTE_LITERALS,
        XCHAL_HAVE_PREDICTED_BRANCHES, XCHAL_INST_FETCH_WIDTH): New.
        (XCHAL_EXTRA_SA_SIZE, XCHAL_EXTRA_SA_ALIGN): Delete.

From-SVN: r88727
2004-10-08 00:28:50 +00:00
DJ Delorie f45c31ea1a Spacing bug.
From-SVN: r87476
2004-09-13 21:14:58 -04:00
Aaron W. LaFramboise ff06bf4bd0 * libiberty.h (basename): Prototype for __MINGW32__.
From-SVN: r87475
2004-09-13 21:12:49 -04:00
Kaveh Ghazi 3d091dac56 builtin-attrs.def (ATTR_SENTINEL, [...]): New.
gcc:
	* builtin-attrs.def (ATTR_SENTINEL, ATTR_SENTINEL_NOTHROW_LIST):
	New.
	* builtins.def (BUILT_IN_EXECL, BUILT_IN_EXECLP): Add `sentinel'
	attribute.
	* c-common.c (handle_sentinel_attribute, check_function_sentinel):
	New functions.
	(c_common_attribute_table): Add `sentinel' attribute.
	(check_function_arguments): Handle `sentinel' attribute.
	* doc/extend.texi: Document `sentinel' attribute.

gcc/testsuite:
	* gcc.dg/format/sentinel-1.c: New test.

include:
	* ansidecl.h (ATTRIBUTE_SENTINEL): Define.
	* libiberty.h (concat, reconcat, concat_length, concat_copy,
	concat_copy2): Use ATTRIBUTE_SENTINEL.

From-SVN: r87096
2004-09-05 02:50:09 +00:00
Ian Lance Taylor 2502b0bcf5 Split ChangeLog
From-SVN: r86172
2004-08-18 13:11:56 +09:30
Gabriel Dos Reis b1e8c0fdac libiberty.h (XDELETE, [...]): Remove any const-qualification before disposal.
include/
        * libiberty.h (XDELETE, XDELETEVEC, XRESIZEVEC): Remove any
        const-qualification before disposal.

gcc/
        * vec.h (DEF_VEC_P): Add proper cast to uses of vec_o_reserve and
        vec_p_reserve.
        * langhooks.h (lang_hooks::builtin_function): Rename parameter
        from "class" to "bt_class".

From-SVN: r85441
2004-08-02 16:45:52 +00:00
Bernardo Innocenti 5673cd61ce * ansidecl.h (ARG_UNUSED): New Macro.
From-SVN: r85120
2004-07-24 19:49:27 +02:00
Paolo Bonzini 4b997cc8bb ansidecl.h (ATTRIBUTE_PURE): New.
2004-07-21  Paolo Bonzini  <bonzini@gnu.org>

        * ansidecl.h (ATTRIBUTE_PURE): New.

From-SVN: r85001
2004-07-21 08:25:57 +00:00
Bernardo Innocenti b6fa4f6e16 libiberty.h (XNEW, [...]): Move here from libcpp/internal.h.
* libiberty.h (XNEW, XCNEW, XNEWVEC, XCNEWVEC, XOBNEW): Move here from
	libcpp/internal.h.
	(XDELETE, XRESIZEVEC, XDELETEVEC, XNEWVAR, XCNEWVAR, XRESIZEVAR): New
	macros.

From-SVN: r84643
2004-07-13 22:59:09 +02:00
Bernardo Innocenti 5557e16d2a libiberty.h (ASTRDUP): Add casts required for stricter type conversion rules of C++.
* libiberty.h (ASTRDUP): Add casts required for stricter
	type conversion rules of C++.
	* obstack.h (obstack_free): Likewise.

From-SVN: r84642
2004-07-13 22:54:38 +02:00
Diego Novillo 6de9cd9a88 Merge tree-ssa-20020619-branch into mainline.
From-SVN: r81764
2004-05-13 02:41:07 -04:00
Andreas Jaeger 073273c359 demangle.h: Do not use C++ reserved keyword typename as parameter for...
* demangle.h: Do not use C++ reserved keyword typename as
	parameter for cplus_demangle_fill_builtin_type.

From-SVN: r81481
2004-05-04 20:13:54 +02:00
Richard Henderson 228c46dbd8 * hashtab.h (struct htab): Add size_prime_index.
From-SVN: r81030
2004-04-22 10:36:03 -07:00
Jeff Law 7f96816adb hashtab.c (htab_remove_elt_with_hash): New function.
* hashtab.c (htab_remove_elt_with_hash): New function.
	(htab_remove_elt): Implement in terms of htab_remove_elt_with_hash.

	* hashtab.h (htab_remove_elt_with_hash): Prototype new function.

From-SVN: r80641
2004-04-13 08:48:56 -06:00
Zack Weinberg cfdfa11075 * hashtab.h, splay-tree.h: Use new shorter form of GTY markers.
From-SVN: r80092
2004-03-30 19:23:16 +00:00
Ian Lance Taylor 0d7fbf1468 * dyn-string.h: Update copyright date.
From-SVN: r78415
2004-02-25 01:42:20 +00:00
Ian Lance Taylor 795b4c374c dyn-string.h: Remove test of IN_LIBGCC2 and IN_GLIBCPP_V3 and the associated #defines.
* dyn-string.h: Remove test of IN_LIBGCC2 and IN_GLIBCPP_V3 and
	the associated #defines.

From-SVN: r78346
2004-02-24 02:32:30 +00:00
Ian Lance Taylor d051dc88ef demangle.h: Instead of checking ANSI_PROTOTYPES, just include "libiberty.h".
2004-01-12  Ian Lance Taylor  <ian@wasabisystems.com>

	* demangle.h: Instead of checking ANSI_PROTOTYPES, just include
	"libiberty.h".

From-SVN: r75789
2004-01-13 03:06:13 +00:00
Ian Lance Taylor e4a32afbe1 * demangle.h: If ANSI_PROTOTYPES is defined, include <stddef.h>.
From-SVN: r75783
2004-01-13 01:49:16 +00:00
Ian Lance Taylor 5e777af517 demangle.h (enum demangle_component_type): Define.
* demangle.h (enum demangle_component_type): Define.
	(struct demangle_operator_info): Declare.
	(struct demangle_builtin_type_info): Declare.
	(struct demangle_component): Define.
	(cplus_demangle_fill_component): Declare.
	(cplus_demangle_fill_name): Declare.
	(cplus_demangle_fill_builtin_type): Declare.
	(cplus_demangle_fill_operator): Declare.
	(cplus_demangle_fill_extended_operator): Declare.
	(cplus_demangle_fill_ctor, cplus_demangle_fill_dtor): Declare.
	(cplus_demangle_v3_components): Declare.
	(cplus_demangle_print): Declare.

	* cp-demangle.c: Include "cp-demangle.h".  If IN_GLIBCPP_V3 is
	defined, rename some functions which are to become static via
	#define.
	(CP_STATIC_IF_GLIBCPP_V3): Define.
	(struct d_operator_info): Move definition to cp-demangle.h, and
	rename to demangle_operator_info.  Change all uses.
	(enum d_builtin_type_print): Move definition to cp-demangle.h.
	(struct d_builtin_type_info): Move definition to cp-demangle.h,
	and rename to demangle_builtin_type_info.  Change all uses.
	(enum d_comp_type): Move definition to include/demangle.h, and
	rename to demangle_component_type, and change all enums to start
	with DEMANGLE_COMPONENT_ instead of D_.  Change all uses.
	(struct d_comp): Move definition to include/demangle.h, and rename
	to demangle_component.  Change all uses.
	(struct d_info): Move definition to cp-demangle.h.
	(cplus_demangle_fill_name): New function.
	(cplus_demangle_fill_extended_operator): New function.
	(cplus_demangle_fill_ctor): New function.
	(cplus_demangle_fill_dtor): New function.
	(d_make_empty): Remove type parameter.  Change all callers.
	(d_make_name): Use cplus_demangle_fill_name.
	(d_make_extended_operator): Use
	cplus_demangle_fill_extended_operator.
	(d_make_ctor): Use cplus_demangle_fill_ctor.
	(d_make_dtor): Use cplus_demangle_fill_dtor.
	(cplus_demangle_mangled_name): Rename from d_mangled_name.  Make
	non-static by default.  Change all callers.
	(cplus_demangle_operators): Rename from d_operators.  Change all
	uses.  Make non-static by default.  Add sentinel at end of array.
	(d_operator_name): Adjust initialization of high for new sentinel
	in cplus_demangle_operators.
	(cplus_demangle_builtin_types): Rename from d_builtin_types.
	Change all uses.  Make non-static by default.  Change initializer
	to use D_BUILTIN_TYPE_COUNT instead of magic number 26.
	(cplus_demangle_type): Rename from d_type.  Make non-static by
	default.  Change all callers.
	(cplus_demangle_init_info): Rename from d_init_info.  Make
	non-static by default.  Change all callers.
	* cp-demangle.h: New file.
	* cp-demint.c: New file.
	* Makefile.in: Rebuild dependencies.
	(CFILES): Add cp-demint.c.
	(REQUIRED_OFILES): Add cp-demint.o.

From-SVN: r75748
2004-01-12 19:46:31 +00:00
Andreas Tobler 7dff81909b fibheap.h (fibnode): Use __extension__ for bit-fields mark and degree if __GNUC__.
* include/fibheap.h (fibnode): Use __extension__ for
	bit-fields mark and degree if __GNUC__.

From-SVN: r74836
2003-12-19 14:37:36 +00:00
Kazu Hirata 4fe5f18266 fibheap.h (fibnode): Use unsigned long int for bit-fields if __GNUC__ is defined.
* include/fibheap.h (fibnode): Use unsigned long int for
	bit-fields if __GNUC__ is defined.

From-SVN: r74817
2003-12-19 03:17:40 +00:00
Joseph Myers dc70e81d6e obstack.h: Merge the following change from gnulib...
include:
	* obstack.h: Merge the following change from gnulib:
	2003-10-21  Paul Eggert  <eggert@twinsun.com>
	* obstack.h (obstack_1grow_fast): Properly parenthesize arg.
	(obstack_ptr_grow_fast, obstack_int_grow_fast):
	Don't use lvalue casts, as GCC plans to remove support for them
	in GCC 3.5.  Reported by Joseph S. Myers.  This bug
	was also present in the non-GCC version, indicating that this
	code had always been buggy and had never been widely used.
	(obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
	Use the fast variant of each macro, rather than copying the
	definiens of the fast variant; that way, we'll be more likely to
	catch future bugs in the fast variants.

gcc:
	* c-typeck.c (pedantic_lvalue_warning): Unconditionally warn of
	deprecation of casts as lvalues.
	* fixinc/inclhack.def (obstack_lvalue_cast): New fix.
	* fixinc/fixincl.x: Regenerate.
	* fixinc/tests/base/obstack.h: New test.

gcc/testsuite:
	* gcc.dg/cast-lvalue-1.c: New test.

From-SVN: r72826
2003-10-22 23:28:39 +01:00
Andrew Cagney 83c073429b floatformat.h (struct floatformat): Add field "is_valid".
2003-09-22  Andrew Cagney  <cagney@redhat.com>

	* floatformat.h (struct floatformat): Add field "is_valid".

2003-09-22  Andrew Cagney  <cagney@redhat.com>

	* floatformat.c (floatformat_i387_ext_is_valid): New function.
	(floatformat_always_valid): New function.
	(floatformat_i387_ext): Initialize new "is_valid" field to
	"floatformat_i387_ext_is_valid".
	(floatformat_ieee_single_little): Initialize "is_valid" field to
	floatformat_always_valid.
	(floatformat_ieee_double_big): Ditto.
	(floatformat_ieee_double_little): Ditto.
	(floatformat_ieee_double_little): Ditto.
	(floatformat_ieee_double_littlebyte_bigword): Ditto.
	(floatformat_i960_ext): Ditto.
	(floatformat_m88110_ext): Ditto.
	(floatformat_m88110_harris_ext): Ditto.
	(floatformat_arm_ext_big): Ditto.
	(floatformat_arm_ext_littlebyte_bigword): Ditto.
	(floatformat_ia64_spill_big): Ditto.
	(floatformat_ia64_spill_little): Ditto.
	(floatformat_ia64_quad_big): Ditto.
	(floatformat_ia64_quad_little): Ditto.
	(floatformat_ia64_quad_little): Ditto.
	(floatformat_is_valid): Call "is_valid".

From-SVN: r71659
2003-09-22 17:42:03 +00:00
Andrew Cagney c9fbef12be Index: include/ChangeLog
2003-09-15  Andrew Cagney  <cagney@redhat.com>

	* floatformat.h (floatformat_to_double): Make input buffer constant.
	(floatformat_from_double, floatformat_is_valid): Ditto.

Index: libiberty/ChangeLog
2003-09-15  Andrew Cagney  <cagney@redhat.com>

	* floatformat.c (get_field): Make "data" constant.
	(floatformat_is_valid, floatformat_to_double): Make "from"
	constant, fix casts.
	(floatformat_from_double): Make "from" constant.

From-SVN: r71422
2003-09-16 01:51:07 +00:00
Andrew Cagney a4cbdc57c8 floatformat.h (struct floatformat): Make "exp_bias" signed.
2003-09-15  Andrew Cagney  <cagney@redhat.com>

	* floatformat.h (struct floatformat): Make "exp_bias" signed.

From-SVN: r71407
2003-09-15 21:28:49 +00:00
Daniel Jacobowitz 0d66a8212c * floatformat.h (floatformat_is_valid): Add prototype.
From-SVN: r71404
2003-09-15 20:16:22 +00:00
Bob Wilson b31185fe2f * xtensa-config.h: Undef all macros before defining them.
From-SVN: r69174
2003-07-10 05:08:27 +00:00
H.J. Lu 513dab3208 demangle.h: Support C++.
2003-07-06  H.J. Lu <hongjiu.lu@intel.com>

	* demangle.h: Support C++.

From-SVN: r69016
2003-07-06 14:45:37 -07:00
Zack Weinberg b6728b1b51 * filenames.h: New file imported from binutils.
From-SVN: r68791
2003-07-01 20:29:16 +00:00
Bob Wilson e677f70c66 xtensa-config.h: New file imported from binutils.
include/ChangeLog:
	* xtensa-config.h: New file imported from binutils.

gcc/ChangeLog:
	* config/xtensa/lib1funcs.asm: Use "xtensa-config.h" from
	top-level include directory.
	* config/xtensa/lib2funcs.S: Likewise.
	* config/xtensa/xtensa.h: Likewise.
	* config/xtensa/xtensa-config.h: Remove.
	* doc/install.texi: Update location of "xtensa-config.h" header.

From-SVN: r68747
2003-07-01 00:14:33 +00:00
Zack Weinberg 21299dbda4 safe-ctype.h (HC_UNKNOWN, [...]): Rename to HOST_CHARSET_UNKNOWN...
include:
	* safe-ctype.h (HC_UNKNOWN, HC_ASCII, HC_EBCDIC): Rename to
	HOST_CHARSET_UNKNOWN, HOST_CHARSET_ASCII, HOST_CHARSET_EBCDIC
	respectively.
libiberty:
	* safe-ctype.c: Use HOST_CHARSET_ASCII and HOST_CHARSET_EBCDIC,
	not HC_ASCII and HC_EBCDIC.
	Add documentation in form expected by gather-docs.
	* hex.c: Use HOST_CHARSET, not hand-coded check of character set.
	* Makefile.in, functions.texi: Regenerate.
gcc:
	* config/i370/i370.c, config/i370/i370.h: Use HOST_CHARSET_ASCII
	and HOST_CHARSET_EBCDIC, not HC_ASCII and HC_EBCDIC.

From-SVN: r68335
2003-06-22 15:59:49 +00:00
Zack Weinberg 7468e0b523 safe-ctype.h (HC_UNKNOWN, [...]): New #defines.
include:
	* safe-ctype.h (HC_UNKNOWN, HC_ASCII, HC_EBCDIC, HOST_CHARSET):
	New #defines.
libiberty:
	* safe-ctype.c: Separate out EOF==-1 check.  Use HOST_CHARSET
	for charset determination.
gcc:
	* aclocal.m4 (gcc_AC_C_CHARSET): Delete.
	* configure.in: Don't use gcc_AC_C_CHARSET.
	* configure, config.in: Regenerate.
	* config/i370/i370.c, config/i370/i370.h: Use
	(HOST_CHARSET == HC_EBCDIC) or (HOST_CHARSET == HC_ASCII)
	instead of HOST_EBCDIC or !HOST_EBCDIC.  Clarify comments a tad.

From-SVN: r68317
2003-06-21 23:22:30 +00:00
Kaveh R. Ghazi a54928c932 alloc-pool.c: Don't check HAVE_LONG_DOUBLE.
gcc:
	* alloc-pool.c: Don't check HAVE_LONG_DOUBLE.
	* fixinc/gnu-regex.c: Don't define `volatile'.
	* ggc-page.c: Don't check HAVE_LONG_DOUBLE.
	* ggc-simple.c: Likewise.
	* system.h: Don't define `volatile'.

	* aclocal.m4 (gcc_AC_C_VOLATILE, gcc_AC_C_LONG_DOUBLE): Delete.
	* configure.in (gcc_AC_C_VOLATILE, gcc_AC_C_LONG_DOUBLE): Don't
	call these macros.
	* config.in, configure: Regenerated.

include:
	* ansidecl.h: Delete HAVE_LONG_DOUBLE GCC bootstrap support.

From-SVN: r68085
2003-06-17 14:10:01 +00:00
Jim Blandy 49a19cfd34 hex.c (_hex_value): Make this unsigned.
libiberty/ChangeLog:
2003-05-14  Jim Blandy  <jimb@redhat.com>

	* hex.c (_hex_value): Make this unsigned.
	(hex_value): Update documentation for new return type.  hex_value
	now expands to an unsigned int expression, to avoid unexpected
	sign extension when we store it in a bfd_vma, which is larger than
	int on some platforms.
	* functions.texi: Regenerated.

include/ChangeLog:
2003-05-14  Jim Blandy  <jimb@redhat.com>

	* libiberty.h (hex_value): Make the value an unsigned int, to
	avoid unexpected sign-extension when cast to unsigned types larger
	than int --- like bfd_vma, on some platforms.
	(_hex_value): Update declaration.

From-SVN: r66840
2003-05-15 19:02:13 +00:00
Jason Merrill 9d70d418db s/burtle/iterative
From-SVN: r66577
2003-05-07 16:30:32 -04:00
Jason Merrill 5cc5a0d00d hashtab.c (burtle_hash): New fn.
libiberty/
        * hashtab.c (burtle_hash): New fn.
        * configure.in: Add AC_C_BIGENDIAN_CROSS.
        * aclocal.m4: Include accross.m4.
        * configure, config.in: Regenerate.
include/
        * hashtab.h (burtle_hash): Prototype.
        (burtle_hash_object): New macro.

From-SVN: r66565
2003-05-07 14:07:58 -04:00
Kaveh R. Ghazi d41c4351fe ansidecl.h (ATTRIBUTE_NONNULL, [...]): New.
include:
	* ansidecl.h (ATTRIBUTE_NONNULL, ATTRIBUTE_NULL_PRINTF,
	ATTRIBUTE_NULL_PRINTF_1, ATTRIBUTE_NULL_PRINTF_2,
	ATTRIBUTE_NULL_PRINTF_3, ATTRIBUTE_NULL_PRINTF_4,
	ATTRIBUTE_NULL_PRINTF_5): New.
	(ATTRIBUTE_PRINTF): Add ATTRIBUTE_NONNULL.

gcc:
	* dwarf2asm.h: Delete obsolete comment.
	(dw2_asm_output_data, dw2_asm_output_delta, dw2_asm_output_offset,
	dw2_asm_output_pcrel, dw2_asm_output_addr,
	dw2_asm_output_addr_rtx, dw2_asm_output_encoded_addr_rtx,
	dw2_asm_output_nstring, dw2_asm_output_data_uleb128,
	dw2_asm_output_data_sleb128, dw2_asm_output_delta_uleb128,
	dw2_asm_output_delta_sleb128): Add ATTRIBUTE_NULL_PRINTF.

From-SVN: r64505
2003-03-17 22:57:27 +00:00
Jan Hubicka dbccdc4211 ggc-common.c (ggc_mark_roots): Use htab_traverse_noresize.
* ggc-common.c (ggc_mark_roots): Use htab_traverse_noresize.

	* hashtab.h (htab_traverse_noresize): Declare.

	* hashtab.c (htab_traverse_noresize): Break out from ...
	* hashtab.c (htab_traverse): ... here.

From-SVN: r64496
2003-03-17 17:59:58 +00:00
Kaveh R. Ghazi 9308be9056 * libiberty.h: Document return value of physmem routines.
From-SVN: r63521
2003-02-27 20:28:40 +00:00
Kaveh R. Ghazi a354191ebf libiberty.h (physmem_total, [...]): Prototype.
include:
	* libiberty.h (physmem_total, physmem_available): Prototype.

libiberty:
	* Makefile.in (CFILES): Add physmem.c.
	(REQUIRED_OFILES): Add physmem.o.
	* configure.in: Check for sys/pstat.h.
	(checkfuncs): Add pstat_getstatic and pstat_getdynamic.
	* physmem.c: New file, copied from textutils.

	* config.in, configure: Regenerated.

From-SVN: r63198
2003-02-21 00:27:04 +00:00
Daniel Jacobowitz 378ca31ee5 * libiberty.h (lrealpath): Add declaration.
From-SVN: r63185
2003-02-20 22:10:40 +00:00
Daniel Jacobowitz 74828682c7 hashtab.h (htab_alloc_with_arg, [...]): Add new types.
include/
	* hashtab.h (htab_alloc_with_arg, htab_free_with_arg): Add new types.
	(struct htab): Add alloc_arg, alloc_with_arg_f, free_with_arg_f.
	(htab_create_alloc_ex): New prototype.
	(htab_set_functions_ex): New prototype.

libiberty/
	* hashtab.c (htab_create_alloc_ex): New function.
	(hatab_set_functions_ex): New function.
	(htab_delete, htab_expand): Support alternate allocation functions.

From-SVN: r61820
2003-01-26 07:09:41 +00:00
Geoffrey Keating 17211ab553 Merge from pch-branch.
From-SVN: r61136
2003-01-10 02:22:34 +00:00
Simon Burge f60d9a8a86 * libiberty.h (basename): Add NetBSD to the list.
From-SVN: r59421
2002-11-24 06:54:38 +00:00
Daniel Jacobowitz 42766f8db1 libiberty.h (make_relative_prefix): Add prototype.
include/
	* libiberty.h (make_relative_prefix): Add prototype.
libiberty/
	* Makefile.in: Add make-relative-prefix.c.
	* make-relative-prefix.c: New file.
	* functions.texi: Rebuilt.
gcc/
	* gcc.c (make_relative_prefix, split_directories)
	(free_split_directories): Removed.

From-SVN: r59385
2002-11-22 20:01:07 +00:00
Roger Sayle 45329aca77 partition.h: Close the extern "C" scope when compiling with C++.
* partition.h:  Close the extern "C" scope when compiling with C++.
	* getopt.h: Update copyright year from the previous patch.

From-SVN: r58570
2002-10-27 01:00:34 +00:00
Roger Sayle f416dcd5bf re PR bootstrap/8351 (3.3 20021024 (experimental) fails to bootstrap on cygwin)
PR bootstrap/8351
	* getopt.h:  Avoid prototyping getopt with no arguments in C++.

Co-Authored-By: DJ Delorie <dj@redhat.com>

From-SVN: r58569
2002-10-27 00:54:50 +00:00
Nathan Tallent e4aaa2f87d ansidecl.h (__STDC__): Add (__alpha && __cplusplus) to the list of platform compilers that may look...
* ansidecl.h (__STDC__): Add (__alpha && __cplusplus) to the
list of	platform compilers that may look, smell and act
like __STDC__ but that may not define it.

From-SVN: r58513
2002-10-24 19:36:25 -04:00
David O'Brien 6ba08913bd Remove bogus copyright message in my last entry.
From-SVN: r58188
2002-10-16 03:45:02 +00:00
David O'Brien 520157677f getopt.h: getopt is in unistd.h.
2002-10-11  David O'Brien  <obrien@FreeBSD.org>
	* getopt.h: getopt is in unistd.h.  The Single UNIX(tm) Specification,
	Version 2 Copyright (c)1997 The Open Group

Approved by:  Committed as obvious.

From-SVN: r58078
2002-10-12 04:01:04 +00:00
Alexandre Oliva e2bb0cb4b3 libiberty.h (asprintf, vasprintf): Don't declare them if the corresponding HAVE_DECL_ macro is 1.
* libiberty.h (asprintf, vasprintf): Don't declare them if the
corresponding HAVE_DECL_ macro is 1.

From-SVN: r57324
2002-09-20 00:21:54 +00:00
Alan Modra 8ff82b06d6 demangle.h: #include "ansidecl.h" rather than #include <ansidecl.h>.
* demangle.h: #include "ansidecl.h" rather than #include <ansidecl.h>.
	* fibheap.h: Likewise.
	* hashtab.h: Likewise.
	* partition.h: Likewise.
	* sort.h: Likewise.
	* splay-tree.h: Likewise.

From-SVN: r54974
2002-06-25 09:44:15 +09:30
Alan Modra 66443ad2fd libiberty.h (basename): Don't declare if HAVE_DECL_BASENAME.
* libiberty.h (basename): Don't declare if HAVE_DECL_BASENAME.
	* getopt.h (getopt): Don't declare if HAVE_DECL_GETOPT.

From-SVN: r54941
2002-06-24 14:38:02 +09:30
DJ Delorie 917ccc05a6 hashtab.h (htab): Rearrange new members for backward compatibility.
* hashtab.h (htab): Rearrange new members for backward
compatibility.
(htab_create): Don't use a macro that requires other headers.

From-SVN: r54316
2002-06-06 08:42:06 -04:00
Geoffrey Keating 045b3a49ca Index: include/ChangeLog
Index: include/ChangeLog
	* hashtab.h (htab_create): Restore prototype for backward
	compatibility.
	(htab_try_create): Likewise.

Index: libiberty/ChangeLog
	* hashtab.c (htab_create): New stub function for backward
	compatibility.
	(htab_try_create): Likewise.

From-SVN: r54300
2002-06-06 03:23:27 +00:00
Geoffrey Keating e2500fedef Merge from pch-branch up to tag pch-commit-20020603.
From-SVN: r54232
2002-06-04 07:11:05 +00:00
David S. Miller 4780f10144 xregex2.h (__restrict_arr): Define to __restrict on GCC 3.1 and later.
2002-04-16  David S. Miller  <davem@redhat.com>

	* xregex2.h (__restrict_arr): Define to __restrict on GCC
	3.1 and later.  Do not redefine.

From-SVN: r52383
2002-04-16 17:12:54 -07:00
Phil Edwards 7bf421c163 dyn-string.h: Also allow IN_GLIBCPP_V3 to redefine names.
2002-04-01  Phil Edwards  <pme@gcc.gnu.org>

	* dyn-string.h:  Also allow IN_GLIBCPP_V3 to redefine names.

From-SVN: r51707
2002-04-01 21:54:28 +00:00
Andrew Cagney ccc49bed1c Remove floatformat_arm_ext.
From-SVN: r50345
2002-03-06 06:29:00 +00:00