Import egcs 1.1.1 prerelease 2

This commit is contained in:
tv 1998-11-14 04:14:09 +00:00
parent 0659054b8b
commit 7500a991df
41 changed files with 530 additions and 175 deletions

117
gnu/dist/gcc/ChangeLog vendored
View File

@ -1,3 +1,120 @@
Mon Nov 9 23:29:39 1998 David Edelsohn <edelsohn@mhpcc.edu>
* rs6000.md (floatunssidf2_internal splitter): Use base register
operand, not hard-coded SP.
Mon Nov 9 23:05:51 1998 Richard Earnshaw (rearnsha@arm.com)
Restore ABI compatibility for NetBSD.
* arm/netbsd.h (DEFAULT_PCC_STRUCT_RETURN): Override setting in
arm.h
(RETURN_IN_MEMORY): Likewise.
* arm.c (add_constant): When taking the address of an item in the
pool, get the mode of the item addressed.
* arm.c (final_prescan_insn, case INSN): If an insn doesn't
contain a SET or a PARALLEL, don't consider it for conditional
execution.
Mon Nov 9 22:43:57 1998 Jean-Pierre Radley <jpr@jpr.com>
* fixinc.sco: Paramaterize #include_next values.
* fixinc/fixinc.sco: Likewise.
Mon Nov 9 22:43:57 1998 Robert Lipe <robertl@dgii.com>
* fixinc.sco: Borrow code to wrap 'bool' typedefs from tinfo.h
and term.h from fixinc.wrap.
Thu Nov 5 07:57:45 EST 1998 Andrew MacLeod <amacleod@cygnus.com>
* except.c (expand_fixup_region_end): Make sure outer context labels
are not issued in an inner context during cleanups.
Sun Nov 1 11:04:32 1998 Jeffrey A Law (law@cygnus.com)
* i386/linux.h (CPP_PREDEFINES): Bring back -Di386 for the last time.
* From Christian Gafton:
* i386/linux.h (CPP_PREDEFINES): Add -D__i386__.
* sparc/linux.h (CPP_PREDEFINES): Add -D__sparc__.
* sparc/linux64.h (CPP_PREDEFIENS): Add -D__sparc__.
Sat Oct 31 00:40:05 1998 Jeffrey A Law (law@cygnus.com)
* jump.c (jump_optimize): Initialize mappings from INSN_UID to
EH region if exceptions are enabled and we're performing cross
jump optimizations.
(find_cross_jump): Exit loop if the insns are in different EH regions.
Fri Oct 30 00:54:25 1998 Peter Jakubek <pjak@snafu.de>
* m68k.h (INDIRECTABLE_1_ADDRESS_P): Fix thinko.
Thu Oct 29 12:14:58 1998 Jason Merrill <jason@yorick.cygnus.com>
* alpha/linux.h (CPP_PREDEFINES): Add missing space.
Tue Oct 27 16:11:43 1998 David Edelsohn <edelsohn@mhpcc.edu>
* collect2.c (aix64_flag): New variable.
(main, case 'b'): Parse it.
(GCC_CHECK_HDR): object magic number must match mode.
(scan_prog_file): Only check for shared object if valid header.
Print debugging if header/mode mismatch.
* README.RS6000: Update.
Sun Oct 25 23:36:52 1998 Jason Merrill <jason@yorick.cygnus.com>
* stmt.c (expand_fixup): Set fixup->before_jump to a
NOTE_INSN_DELETED instead of a NOTE_INSN_BLOCK_BEG.
Sun Oct 25 18:35:06 1998 David Edelsohn <edelsohn@mhpcc.edu>
* ginclude/va-ppc.h (va_arg): longlong types in overflow area are
not doubleword aligned.
Sun Oct 25 12:07:00 1998 Mumit Khan <khan@xraylith.wisc.edu>
* i386/crtdll.h (CPP_PREDEFINES): Fix typo.
* i386/mingw32.h (CPP_PREDEFINES): Likewise.
Fri Oct 23 22:41:40 1998 David Edelsohn <edelsohn@mhpcc.edu>
* rs6000.md (movsf): Disable explicit secondary-reload-like
functionality if TARGET_POWERPC64.
(movdf): Remove TARGET_POWERPC64 explicit secondary-reload-like
functionality.
Fri Oct 23 22:38:57 1998 Jeffrey A Law (law@cygnus.com)
* m68k.md (5200 movqi): Do not allow byte sized memory references
using address regs.
* m68k.c (output_move_qimode): Do not use byte sized operations on
address registers.
Fri Oct 23 00:56:11 1998 Jason Merrill <jason@yorick.cygnus.com>
* expr.c (pending_chain): Move up.
(save_expr_status): Do save pending_chain.
(restore_expr_status): And restore it.
* function.h (struct function): Add pending_chain.
Mon Oct 19 13:22:13 1998 Geoff Keating <geoffk@ozemail.com.au>
* loop.c (scan_loop): Be more selective about what invariants are
moved out of a loop.
Wed Oct 14 23:27:08 1998 Didier FORT (didier.fort@fedex.com)
* fixincludes: Fix up rpc/{clnt,svr,xdr}.h for SunOS.
Wed Oct 14 22:13:28 1998 Joel Sherrill (joel@OARcorp.com)
* Makefile.in (stmp-fixinc): Do not install assert.h if not desired.
* config/t-rtems: Do not install assert.h -- use newlib's.
Sat Oct 3 19:01:03 1998 Richard Henderson <rth@cygnus.com>
* alpha/linux.h (CPP_PREDEFINES): Define __alpha__ for imake.

2
gnu/dist/gcc/README vendored
View File

@ -1,4 +1,4 @@
This directory contains the egcs version 1.1 release of the GNU C
This directory contains the egcs version 1.1.1 release of the GNU C
compiler. It includes all of the support for compiling C++ and
Objective C, including a run-time library for Objective C.

View File

@ -1,3 +1,16 @@
AIX 4.3 archive libraries
AIX 4.3 utilizes a new "large format" archive to support both 32-bit and
64-bit object modules. The routines provided in AIX 4.3.0 and AIX 4.3.1
to parse archive libraries did not handle the new format correctly. These
routines are used by GCC and result in error messages during linking such
as "not a COFF file". The version of the routines shipped with AIX 4.3.1
should work for a 32-bit environment. The "-g" option of the archive
command may be used to create archives of 32-bit objects using the
original "small format". A correct version of the routines is shipped
with AIX 4.3.2.
AIX 4.3 assembler
The AIX 4.3.0.0 assembler generates incorrect object files if the ".bs"

View File

@ -198,6 +198,7 @@ static int rflag; /* true if -r */
static int strip_flag; /* true if -s */
#ifdef COLLECT_EXPORT_LIST
static int export_flag; /* true if -bE */
static int aix64_flag; /* true if -b64 */
#endif
int debug; /* true if -debug */
@ -1194,6 +1195,8 @@ main (argc, argv)
case 'b':
if (arg[2] == 'E' || strncmp (&arg[2], "export", 6) == 0)
export_flag = 1;
if (arg[2] == '6' && arg[3] == '4')
aix64_flag = 1;
break;
#endif
@ -2669,7 +2672,9 @@ scan_libraries (prog_name)
(((X).n_sclass == C_EXT) && ((X).n_scnum == N_UNDEF))
# define GCC_SYMINC(X) ((X).n_numaux+1)
# define GCC_SYMZERO(X) 0
# define GCC_CHECK_HDR(X) (1)
# define GCC_CHECK_HDR(X) \
((HEADER (X).f_magic == U802TOCMAGIC && ! aix64_flag) \
|| (HEADER (X).f_magic == 0757 && aix64_flag))
#endif
extern char *ldgetname ();
@ -2712,18 +2717,19 @@ scan_prog_file (prog_name, which_pass)
#endif
if ((ldptr = ldopen (prog_name, ldptr)) != NULL)
{
if (!MY_ISCOFF (HEADER (ldptr).f_magic))
if (! MY_ISCOFF (HEADER (ldptr).f_magic))
fatal ("%s: not a COFF file", prog_name);
#ifdef COLLECT_EXPORT_LIST
/* Is current archive member a shared object? */
is_shared = HEADER (ldptr).f_flags & F_SHROBJ;
#endif
if (GCC_CHECK_HDR (ldptr))
{
sym_count = GCC_SYMBOLS (ldptr);
sym_index = GCC_SYMZERO (ldptr);
#ifdef COLLECT_EXPORT_LIST
/* Is current archive member a shared object? */
is_shared = HEADER (ldptr).f_flags & F_SHROBJ;
#endif
while (sym_index < sym_count)
{
GCC_SYMENT symbol;
@ -2841,6 +2847,16 @@ scan_prog_file (prog_name, which_pass)
#endif
}
}
#ifdef COLLECT_EXPORT_LIST
else
{
/* If archive contains both 32-bit and 64-bit objects,
we want to skip objects in other mode so mismatch normal. */
if (debug)
fprintf (stderr, "%s : magic=%o aix64=%d mismatch\n",
prog_name, HEADER (ldptr).f_magic, aix64_flag);
}
#endif
}
else
{

View File

@ -24,7 +24,7 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
#undef CPP_PREDEFINES
#define CPP_PREDEFINES \
"-Dlinux -Dunix -Asystem(linux) -D_LONGLONG -D__alpha__" SUB_CPP_PREDEFINES
"-Dlinux -Dunix -Asystem(linux) -D_LONGLONG -D__alpha__ " SUB_CPP_PREDEFINES
#undef LIB_SPEC
#define LIB_SPEC "%{pg:-lgmon} %{pg:-lc_p} %{!pg:-lc}"

View File

@ -26,7 +26,7 @@ Boston, MA 02111-1307, USA. */
#define CPP_PREDEFINES "-Di386 -D_WIN32 -DWIN32 -D__WIN32__ \
-D__MINGW32__ -DWINNT -D_X86_=1 -D__STDC__=1\
-D__stdcall=__attribute__((__stdcall__)) \
_D_stdcall=__attribute__((__stdcall__)) \
-D_stdcall=__attribute__((__stdcall__)) \
-D__cdecl=__attribute__((__cdecl__)) \
-D__declspec(x)=__attribute__((x)) \
-Asystem(winnt) -Acpu(i386) -Amachine(i386)"

View File

@ -150,8 +150,9 @@ Boston, MA 02111-1307, USA. */
#undef WCHAR_TYPE_SIZE
#define WCHAR_TYPE_SIZE BITS_PER_WORD
/* The egcs-1.1 branch is the last time we will have -Di386. -D__i386__ is the thing to use. */
#undef CPP_PREDEFINES
#define CPP_PREDEFINES "-D__ELF__ -Dunix -Dlinux -Asystem(posix)"
#define CPP_PREDEFINES "-D__ELF__ -Dunix -Di386 -D__i386__ -Dlinux -Asystem(posix)"
#undef CPP_SPEC
#ifdef USE_GNULIBC_1

View File

@ -33,7 +33,7 @@ Boston, MA 02111-1307, USA. */
#define CPP_PREDEFINES "-Di386 -D_WIN32 -DWIN32 -D__WIN32__ \
-D__MINGW32__ -D__MSVCRT__ -DWINNT -D_X86_=1 -D__STDC__=1\
-D__stdcall=__attribute__((__stdcall__)) \
_D_stdcall=__attribute__((__stdcall__)) \
-D_stdcall=__attribute__((__stdcall__)) \
-D__cdecl=__attribute__((__cdecl__)) \
-D__declspec(x)=__attribute__((x)) \
-Asystem(winnt) -Acpu(i386) -Amachine(i386)"

View File

@ -1414,21 +1414,13 @@ __transfer_from_trampoline () \
|| (GET_CODE (X) == PLUS \
&& LEGITIMATE_BASE_REG_P (XEXP (X, 0)) \
&& GET_CODE (XEXP (X, 1)) == CONST_INT \
&& (TARGET_68020 || (unsigned) INTVAL (XEXP (X, 1)) + 0x8000) < 0x10000) \
&& (TARGET_68020 \
|| ((unsigned) INTVAL (XEXP (X, 1)) + 0x8000) < 0x10000)) \
|| (GET_CODE (X) == PLUS && XEXP (X, 0) == pic_offset_table_rtx \
&& flag_pic && GET_CODE (XEXP (X, 1)) == SYMBOL_REF) \
|| (GET_CODE (X) == PLUS && XEXP (X, 0) == pic_offset_table_rtx \
&& flag_pic && GET_CODE (XEXP (X, 1)) == LABEL_REF)) \
#if 0
/* This should replace the last two (non-pic) lines
except that Sun's assembler does not seem to handle such operands. */
&& (TARGET_68020 ? CONSTANT_ADDRESS_P (XEXP (X, 1)) \
: (GET_CODE (XEXP (X, 1)) == CONST_INT \
&& ((unsigned) INTVAL (XEXP (X, 1)) + 0x8000) < 0x10000))))
#endif
#define GO_IF_NONINDEXED_ADDRESS(X, ADDR) \
{ if (INDIRECTABLE_1_ADDRESS_P (X)) goto ADDR; }

View File

@ -1023,8 +1023,8 @@
"* return output_move_qimode (operands);")
(define_insn ""
[(set (match_operand:QI 0 "general_operand" "=d*a<Q>,d*am")
(match_operand:QI 1 "general_operand" "d*ami,d*a<Q>"))]
[(set (match_operand:QI 0 "general_operand" "=d<Q>,dm,d*a")
(match_operand:QI 1 "general_operand" "dmi,d<Q>,di*a"))]
"TARGET_5200"
"* return output_move_qimode (operands);")

View File

@ -3699,7 +3699,7 @@
(unsigned_float:DF (match_operand:SI 1 "gpc_reg_operand" "")))
(use (match_operand:SI 2 "gpc_reg_operand" ""))
(use (match_operand:DF 3 "gpc_reg_operand" ""))
(clobber (match_operand 4 "gpc_reg_operand" "=b"))
(clobber (match_operand 4 "gpc_reg_operand" ""))
(clobber (reg:DF 76))]
"TARGET_HARD_FLOAT"
[(set (match_dup 4)
@ -3713,7 +3713,7 @@
(match_dup 5)] 13)) ;; high word
(set (match_dup 0)
(unspec [(match_dup 5)
(reg:SI 1)] 14))
(match_dup 4)] 14))
(set (match_dup 0)
(minus:DF (match_dup 0)
(match_dup 3)))]
@ -5686,7 +5686,8 @@
else if (TARGET_HARD_FLOAT)
{
if (GET_CODE (operands[1]) == REG && REGNO (operands[1]) < 32)
if (! TARGET_POWERPC64
&& GET_CODE (operands[1]) == REG && REGNO (operands[1]) < 32)
{
/* If this is a store to memory or another integer register do the
move directly. Otherwise store to a temporary stack slot and
@ -5729,7 +5730,8 @@
operands[1] = force_reg (SFmode, operands[1]);
}
if (GET_CODE (operands[0]) == REG && REGNO (operands[0]) < 32)
if (! TARGET_POWERPC64
&& GET_CODE (operands[0]) == REG && REGNO (operands[0]) < 32)
{
if (GET_CODE (operands[1]) == MEM
#if HOST_FLOAT_FORMAT == TARGET_FLOAT_FORMAT && ! defined(REAL_IS_NOT_DOUBLE)
@ -5848,23 +5850,6 @@
if (GET_CODE (operands[0]) != REG)
operands[1] = force_reg (DFmode, operands[1]);
/* Stores between FPR and any non-FPR registers must go through a
temporary stack slot. */
if (TARGET_POWERPC64
&& GET_CODE (operands[0]) == REG && GET_CODE (operands[1]) == REG
&& ((FP_REGNO_P (REGNO (operands[0]))
&& ! FP_REGNO_P (REGNO (operands[1])))
|| (FP_REGNO_P (REGNO (operands[1]))
&& ! FP_REGNO_P (REGNO (operands[0])))))
{
rtx stack_slot = assign_stack_temp (DFmode, 8, 0);
emit_move_insn (stack_slot, operands[1]);
emit_move_insn (operands[0], stack_slot);
DONE;
}
if (CONSTANT_P (operands[1]) && ! easy_fp_constant (operands[1], DFmode))
{
operands[1] = force_const_mem (DFmode, operands[1]);

View File

@ -103,7 +103,7 @@ Boston, MA 02111-1307, USA. */
#define WCHAR_TYPE_SIZE BITS_PER_WORD
#undef CPP_PREDEFINES
#define CPP_PREDEFINES "-D__ELF__ -Dunix -Dsparc -Dlinux -Asystem(unix) -Asystem(posix)"
#define CPP_PREDEFINES "-D__ELF__ -Dunix -Dsparc -D__sparc__ -Dlinux -Asystem(unix) -Asystem(posix)"
#undef CPP_SUBTARGET_SPEC
#ifdef USE_GNULIBC_1

View File

@ -94,7 +94,7 @@ Boston, MA 02111-1307, USA. */
#define LONG_DOUBLE_TYPE_SIZE 128
#undef CPP_PREDEFINES
#define CPP_PREDEFINES "-D__ELF__ -Dunix -Dsparc -Dlinux -Asystem(unix) -Asystem(posix)"
#define CPP_PREDEFINES "-D__ELF__ -Dunix -D_LONGLONG -Dsparc -D__sparc__ -Dlinux -Asystem(unix) -Asystem(posix)"
#undef CPP_SUBTARGET_SPEC
#define CPP_SUBTARGET_SPEC "\

View File

@ -1,2 +1,6 @@
# RTEMS uses newlib which does not require prototype fixing
STMP_FIXPROTO =
# Don't install "assert.h" in gcc. RTEMS uses the one in newlib.
INSTALL_ASSERT_H =

View File

@ -1,3 +1,83 @@
1998-11-08 Mark Mitchell <mark@markmitchell.com>
* decl.c (grokdeclarator): Tighten checks for invalid
destructors. Improve error-messages and error-recovery.
* decl2.c (check_classfn): Don't assume that mangled destructor
names contain type information.
1998-11-02 Jason Merrill <jason@yorick.cygnus.com>
* decl2.c (import_export_decl): Call import_export_class.
1998-10-28 Jason Merrill <jason@yorick.cygnus.com>
* class.c (finish_struct_1): Don't complain about non-copy
assignment ops in union members.
* class.c (build_vtable): Don't pass at_eof to import_export_vtable.
(prepare_fresh_vtable): Likewise.
(finish_struct_1): Don't call import_export_class.
* decl2.c (finish_vtable_vardecl): Do import/export stuff.
(finish_prevtable_vardecl): Lose.
(finish_file): Don't call it.
* pt.c (instantiate_class_template): Likewise.
1998-10-23 Martin von Löwis <loewis@informatik.hu-berlin.de>
* parse.y (condition): Convert VAR_DECL from reference to indirect
reference.
1998-10-18 Jason Merrill <jason@yorick.cygnus.com>
* method.c (hack_identifier): Just return a member function.
1998-10-18 Martin von Löwis <loewis@informatik.hu-berlin.de>
* decl2.c (validate_nonmember_using_decl): Fix using-directives of
std if std is ignored.
1998-10-14 Jason Merrill <jason@yorick.cygnus.com>
* spew.c (yylex): Clear looking_for_typename if we got
'enum { ... };'.
1998-10-13 Jason Merrill <jason@yorick.cygnus.com>
* tinfo2.cc (fast_compare): Remove.
(before): Just use strcmp.
* tinfo.cc (operator==): Just use strcmp.
1998-10-12 Jason Merrill <jason@yorick.cygnus.com>
* tinfo.cc (operator==): Always compare names.
1998-10-12 Jason Merrill <jason@yorick.cygnus.com>
* inc/typeinfo: Add #pragma interface.
(operator!=): Just call operator==.
* tinfo.cc: Add #pragma implementation.
(operator==): Move from inc/typeinfo and tinfo2.cc.
* typeck2.c (my_friendly_abort): Add URL.
1998-10-05 Martin von Löwis <loewis@informatik.hu-berlin.de>
* method.c (build_decl_overload_real): Clear
numeric_output_need_bar after __.
1998-10-04 Jason Merrill <jason@yorick.cygnus.com>
* decl.c (cp_finish_decl): Make statics in extern inlines and
templates common, if possible and the target doesn't support weak
symbols.
1998-10-03 Jason Merrill <jason@yorick.cygnus.com>
* decl2.c (merge_functions): Remove duplicates.
* typeck.c (build_conditional_expr): Only fold if ifexp is an
INTEGER_CST.
Fri Oct 2 02:07:26 1998 Mumit Khan <khan@xraylith.wisc.edu>
* parse.y (nomods_initdcl0): Set up the parser stack correctly.
@ -7,6 +87,20 @@ Fri Oct 2 02:07:26 1998 Mumit Khan <khan@xraylith.wisc.edu>
* decl.c (duplicate_decls): Don't complain about different
exceptions from an internal decl even if pedantic.
1998-08-24 Gavin Romig-Koch <gavin@cygnus.com>
* typeck.c (c_expand_return): Handle the case that valtype
is wider than the functions return type.
1998-08-24 Martin von Löwis <loewis@informatik.hu-berlin.de>
* search.c (my_tree_cons): Reimplement.
1998-08-17 Jason Merrill <jason@yorick.cygnus.com>
* decl.c (finish_enum): Also set TYPE_SIZE_UNIT.
* class.c (finish_struct_bits): Likewise.
1998-08-17 Mark Mitchell <mark@markmitchell.com>
* pt.c (check_explicit_specialization): Don't abort on bogus

View File

@ -1,4 +1,4 @@
*** Changes since EGCS 1.0:
*** Changes in EGCS 1.1:
* Namespaces are fully supported. The library has not yet been converted
to use namespace std, however, and the old std-faking code is still on by

View File

@ -704,7 +704,7 @@ build_vtable (binfo, type)
#endif
/* Set TREE_PUBLIC and TREE_EXTERN as appropriate. */
import_export_vtable (decl, type, at_eof);
import_export_vtable (decl, type, 0);
decl = pushdecl_top_level (decl);
SET_IDENTIFIER_GLOBAL_VALUE (name, decl);
@ -890,7 +890,7 @@ prepare_fresh_vtable (binfo, for_type)
#endif
/* Set TREE_PUBLIC and TREE_EXTERN as appropriate. */
import_export_vtable (new_decl, for_type, at_eof);
import_export_vtable (new_decl, for_type, 0);
if (TREE_VIA_VIRTUAL (binfo))
my_friendly_assert (binfo == binfo_member (BINFO_TYPE (binfo),
@ -1848,6 +1848,7 @@ finish_struct_bits (t, max_has_virtual)
TYPE_MAX_VALUE (variants) = TYPE_MAX_VALUE (t);
TYPE_FIELDS (variants) = TYPE_FIELDS (t);
TYPE_SIZE (variants) = TYPE_SIZE (t);
TYPE_SIZE_UNIT (variants) = TYPE_SIZE_UNIT (t);
variants = TYPE_NEXT_VARIANT (variants);
}
@ -3547,8 +3548,8 @@ finish_struct_1 (t, warn_anon)
fie = "constructor";
else if (TYPE_NEEDS_DESTRUCTOR (type))
fie = "destructor";
else if (TYPE_HAS_REAL_ASSIGNMENT (type))
fie = "assignment operator";
else if (TYPE_HAS_COMPLEX_ASSIGN_REF (type))
fie = "copy assignment operator";
if (fie)
cp_error_at ("member `%#D' with %s not allowed in union", x,
fie);
@ -3943,11 +3944,6 @@ finish_struct_1 (t, warn_anon)
if (max_has_virtual > 0)
TYPE_VIRTUAL_P (t) = 1;
/* Do this here before we start messing with vtables so that we are ready
for import_export_vtable. */
if (at_eof)
import_export_class (t);
if (flag_rtti && TYPE_VIRTUAL_P (t) && !pending_hard_virtuals)
modify_all_vtables (t, NULL_TREE, NULL_TREE);

View File

@ -7191,20 +7191,52 @@ cp_finish_decl (decl, init, asmspec_tree, need_pop, flags)
if (was_temp)
end_temporary_allocation ();
/* Extern inline function static data has external linkage.
Instead of trying to deal with that, we disable inlining of
such functions. The ASM_WRITTEN check is to avoid hitting this
for __FUNCTION__. */
/* Static data in a function with comdat linkage also has comdat
linkage. */
if (TREE_CODE (decl) == VAR_DECL
&& TREE_STATIC (decl)
/* Don't mess with __FUNCTION__. */
&& ! TREE_ASM_WRITTEN (decl)
&& current_function_decl
&& DECL_CONTEXT (decl) == current_function_decl
&& DECL_THIS_INLINE (current_function_decl)
&& (DECL_THIS_INLINE (current_function_decl)
|| DECL_TEMPLATE_INSTANTIATION (current_function_decl))
&& TREE_PUBLIC (current_function_decl))
{
/* Rather than try to get this right with inlining, we suppress
inlining of such functions. */
current_function_cannot_inline
= "function with static variable cannot be inline";
/* If flag_weak, we don't need to mess with this, as we can just
make the function weak, and let it refer to its unique local
copy. This works because we don't allow the function to be
inlined. */
if (! flag_weak)
{
if (DECL_INTERFACE_KNOWN (current_function_decl))
{
TREE_PUBLIC (decl) = 1;
DECL_EXTERNAL (decl) = DECL_EXTERNAL (current_function_decl);
}
else if (DECL_INITIAL (decl) == NULL_TREE
|| DECL_INITIAL (decl) == error_mark_node)
{
TREE_PUBLIC (decl) = 1;
DECL_COMMON (decl) = 1;
}
/* else we lose. We can only do this if we can use common,
which we can't if it has been initialized. */
if (TREE_PUBLIC (decl))
DECL_ASSEMBLER_NAME (decl)
= build_static_name (current_function_decl, DECL_NAME (decl));
else if (! DECL_ARTIFICIAL (decl))
{
cp_warning_at ("sorry: semantics of inline function static data `%#D' are wrong (you'll wind up with multiple copies)", decl);
cp_warning_at (" you can work around this by removing the initializer"), decl;
}
}
}
else if (TREE_CODE (decl) == VAR_DECL
@ -9393,8 +9425,9 @@ grokdeclarator (declarator, declspecs, decl_context, initialized, attrlist)
error ("destructor cannot be static member function");
if (quals)
{
error ("destructors cannot be declared `const' or `volatile'");
return void_type_node;
cp_error ("destructors may not be `%s'",
IDENTIFIER_POINTER (TREE_VALUE (quals)));
quals = NULL_TREE;
}
if (decl_context == FIELD)
{
@ -9419,8 +9452,9 @@ grokdeclarator (declarator, declspecs, decl_context, initialized, attrlist)
}
if (quals)
{
error ("constructors cannot be declared `const' or `volatile'");
return void_type_node;
cp_error ("constructors may not be `%s'",
IDENTIFIER_POINTER (TREE_VALUE (quals)));
quals = NULL_TREE;
}
{
RID_BIT_TYPE tmp_bits;
@ -9478,24 +9512,22 @@ grokdeclarator (declarator, declspecs, decl_context, initialized, attrlist)
arg_types = grokparms (inner_parms, funcdecl_p ? funcdef_flag : 0);
if (declarator)
if (declarator && flags == DTOR_FLAG)
{
/* Get past destructors, etc.
We know we have one because FLAGS will be non-zero.
Complain about improper parameter lists here. */
/* A destructor declared in the body of a class will
be represented as a BIT_NOT_EXPR. But, we just
want the underlying IDENTIFIER. */
if (TREE_CODE (declarator) == BIT_NOT_EXPR)
declarator = TREE_OPERAND (declarator, 0);
if (strict_prototype == 0 && arg_types == NULL_TREE)
arg_types = void_list_node;
else if (arg_types == NULL_TREE
|| arg_types != void_list_node)
{
declarator = TREE_OPERAND (declarator, 0);
if (strict_prototype == 0 && arg_types == NULL_TREE)
arg_types = void_list_node;
else if (arg_types == NULL_TREE
|| arg_types != void_list_node)
{
error ("destructors cannot be specified with parameters");
arg_types = void_list_node;
}
cp_error ("destructors may not have parameters");
arg_types = void_list_node;
last_function_parms = NULL_TREE;
}
}
@ -11764,6 +11796,7 @@ finish_enum (enumtype, values)
TYPE_MIN_VALUE (tem) = TYPE_MIN_VALUE (enumtype);
TYPE_MAX_VALUE (tem) = TYPE_MAX_VALUE (enumtype);
TYPE_SIZE (tem) = TYPE_SIZE (enumtype);
TYPE_SIZE_UNIT (tem) = TYPE_SIZE_UNIT (enumtype);
TYPE_MODE (tem) = TYPE_MODE (enumtype);
TYPE_PRECISION (tem) = TYPE_PRECISION (enumtype);
TYPE_ALIGN (tem) = TYPE_ALIGN (enumtype);

View File

@ -4,6 +4,8 @@
#ifndef __TYPEINFO__
#define __TYPEINFO__
#pragma interface "typeinfo"
#include <exception>
extern "C++" {
@ -34,22 +36,11 @@ public:
bool operator!= (const type_info& arg) const;
};
// We can't rely on common symbols being shared between translation units
// under Windows. Sigh.
#ifndef _WIN32
inline bool type_info::
operator== (const type_info& arg) const
{
return &arg == this;
}
inline bool type_info::
operator!= (const type_info& arg) const
{
return &arg != this;
return !operator== (arg);
}
#endif
class bad_cast : public exception {
public:

View File

@ -1533,6 +1533,7 @@ build_decl_overload_real (dname, parms, ret_type, tparms, targs,
and figure out its name without any extra encoding. */
OB_PUTC2 ('_', '_');
numeric_output_need_bar = 0;
if (tparms)
{
@ -1862,6 +1863,10 @@ hack_identifier (value, name)
TREE_USED (value) = 1;
value = build_component_ref (current_class_ref, name, NULL_TREE, 1);
}
else if (TREE_CODE (value) == FUNCTION_DECL
&& DECL_FUNCTION_MEMBER_P (value))
/* This is a placeholder; don't mark it used. */
return value;
else if (really_overloaded_fn (value))
{
#if 0

View File

@ -991,7 +991,7 @@ condition:
{
cp_finish_decl ($<ttype>6, $7, $4, 1, LOOKUP_ONLYCONVERTING);
resume_momentary ($<itype>5);
$$ = $<ttype>6;
$$ = convert_from_reference ($<ttype>6);
if (TREE_CODE (TREE_TYPE ($$)) == ARRAY_TYPE)
cp_error ("definition of array `%#D' in condition", $$);
}

View File

@ -4078,8 +4078,6 @@ instantiate_class_template (type)
CLASSTYPE_GOT_SEMICOLON (type) = 1;
repo_template_used (type);
if (at_eof && TYPE_BINFO_VTABLE (type) != NULL_TREE)
finish_prevtable_vardecl (NULL, TYPE_BINFO_VTABLE (type));
end:
TYPE_BEING_DEFINED (type) = 0;

View File

@ -261,17 +261,12 @@ static tree
my_tree_cons (purpose, value, chain)
tree purpose, value, chain;
{
tree p = (tree)obstack_alloc (&type_obstack_entries, sizeof (struct tree_list));
tree p;
struct obstack *ambient_obstack = current_obstack;
current_obstack = &type_obstack_entries;
p = tree_cons (purpose, value, chain);
current_obstack = ambient_obstack;
++my_tree_node_counter;
TREE_TYPE (p) = NULL_TREE;
/* The type of the last on the LHS of this statement must be a pointer
to the same type as the bitfields in struct tree_common. Otherwise
we may write beyond our intended area. */
((unsigned *)p)[2] = 0;
TREE_SET_CODE (p, TREE_LIST);
TREE_PURPOSE (p) = purpose;
TREE_VALUE (p) = value;
TREE_CHAIN (p) = chain;
return p;
}

View File

@ -387,6 +387,11 @@ yylex ()
if (tmp_token.yychar != '~')
got_object = NULL_TREE;
/* Clear looking_for_typename if we got 'enum { ... };'. */
if (tmp_token.yychar == '{' || tmp_token.yychar == ':'
|| tmp_token.yychar == ';')
looking_for_typename = 0;
yylval = tmp_token.yylval;
yychar = tmp_token.yychar;
end_of_file = tmp_token.end_of_file;

View File

@ -25,6 +25,8 @@
// This exception does not however invalidate any other reasons why
// the executable file might be covered by the GNU General Public License.
#pragma implementation "typeinfo"
#include <stddef.h>
#include "tinfo.h"
#include "new" // for placement new
@ -37,6 +39,13 @@ std::type_info::
~type_info ()
{ }
// We can't rely on common symbols being shared between shared objects.
bool type_info::
operator== (const type_info& arg) const
{
return (&arg == this) || (strcmp (name (), arg.name ()) == 0);
}
extern "C" void
__rtti_class (void *addr, const char *name,
const __class_type_info::base_info *bl, size_t bn)

View File

@ -30,39 +30,13 @@
#include "new" // for placement new
using std::type_info;
// service function for comparing types by name.
static inline int
fast_compare (const char *n1, const char *n2) {
int c;
if (n1 == n2) return 0;
if (n1 == 0) return *n2;
else if (n2 == 0) return *n1;
c = (int)*n1++ - (int)*n2++;
return c == 0 ? strcmp (n1, n2) : c;
};
bool
type_info::before (const type_info &arg) const
{
return fast_compare (name (), arg.name ()) < 0;
return strcmp (name (), arg.name ()) < 0;
}
#ifdef _WIN32
bool type_info::
operator== (const type_info& arg) const
{
return fast_compare (name (), arg.name ()) == 0;
}
bool type_info::
operator!= (const type_info& arg) const
{
return fast_compare (name (), arg.name ()) != 0;
}
#endif
// type info for pointer type.
struct __pointer_type_info : public type_info {

View File

@ -5262,7 +5262,7 @@ build_conditional_expr (ifexp, op1, op2)
op2 = convert_for_initialization
(NULL_TREE, result_type, op2, LOOKUP_NORMAL, "converting", NULL_TREE, 0);
if (TREE_CONSTANT (ifexp))
if (TREE_CODE (ifexp) == INTEGER_CST)
return integer_zerop (ifexp) ? op2 : op1;
return convert_from_reference
@ -7291,10 +7291,18 @@ c_expand_return (retval)
}
else
{
tree functype = TREE_TYPE (TREE_TYPE (current_function_decl));
/* First convert the value to the function's return type, then
to the type of return value's location to handle the
case that functype is thiner than the valtype. */
retval = convert_for_initialization
(NULL_TREE, valtype, retval, LOOKUP_NORMAL|LOOKUP_ONLYCONVERTING,
(NULL_TREE, functype, retval, LOOKUP_NORMAL|LOOKUP_ONLYCONVERTING,
"return", NULL_TREE, 0);
retval = convert (valtype, retval);
if (retval == error_mark_node)
{
/* Avoid warning about control reaching end of function. */

View File

@ -384,6 +384,7 @@ my_friendly_abort (i)
else
ack ("Internal compiler error %d.", i);
ack ("Please submit a full bug report to `egcs-bugs@cygnus.com'.");
ack ("See <URL:http://egcs.cygnus.com/faq.html#bugreport> for details.");
}
else
error ("confused by earlier errors, bailing out");

22
gnu/dist/gcc/except.c vendored
View File

@ -1462,6 +1462,7 @@ expand_fixup_region_end (cleanup)
tree cleanup;
{
struct eh_node *node;
int dont_issue;
if (! doing_eh (0) || exceptions_via_longjmp)
return;
@ -1474,10 +1475,31 @@ expand_fixup_region_end (cleanup)
if (node == 0)
abort ();
/* If the outer context label has not been issued yet, we don't want
to issue it as a part of this region, unless this is the
correct region for the outer context. If we did, then the label for
the outer context will be WITHIN the begin/end labels,
and we could get an infinte loop when it tried to rethrow, or just
generally incorrect execution following a throw. */
dont_issue = ((INSN_UID (node->entry->outer_context) == 0)
&& (ehstack.top->entry != node->entry));
ehstack.top->entry->outer_context = node->entry->outer_context;
/* Since we are rethrowing to the OUTER region, we know we don't need
a jump around sequence for this region, so we'll pretend the outer
context label has been issued by setting INSN_UID to 1, then clearing
it again afterwards. */
if (dont_issue)
INSN_UID (node->entry->outer_context) = 1;
/* Just rethrow. size_zero_node is just a NOP. */
expand_eh_region_end (size_zero_node);
if (dont_issue)
INSN_UID (node->entry->outer_context) = 0;
}
/* If we are using the setjmp/longjmp EH codegen method, we emit a

View File

@ -1,3 +1,7 @@
Mon Nov 9 23:13:30 1998 Jeffrey A Law (law@cygnus.com)
* g77.texi: Updates from Craig.
1998-10-09 Dave Love <d.love@dl.ac.uk>
* g77.texi: Various updates.

View File

@ -12026,7 +12026,7 @@ require much more work on @code{libg2c}.
@pindex asa
@pindex fpr
@code{g77} doesn't support @code{FORM='PRINT'} or an equivalent to
translate the traditional `carraige control' characters in column 1 of
translate the traditional `carriage control' characters in column 1 of
output to use backspaces, carriage returns and the like. However
programs exist to translate them in output files (or standard output).
These are typically called either @code{fpr} or @code{asa}. You can get
@ -12036,8 +12036,9 @@ systems which will probably build easily on other systems.
Alternatively, @code{fpr} is in BSD distributions in various archive
sites.
I think both programs can either be used in a pipeline.
@c (Can both programs can be used in a pipeline,
@c with a named input file,
@c and/or with a named output file???)
@node ENCODE and DECODE
@subsection @code{ENCODE} and @code{DECODE}

View File

@ -5,7 +5,7 @@
@c The text of this file appears in the file BUGS
@c in the G77 distribution, as well as in the G77 manual.
@c 1998-09-05
@c 1998-11-03
@ifclear NEWSONLY
@node News
@ -60,12 +60,31 @@ somewhat more difficult.
@heading In 0.5.24 and @code{egcs} 1.1.1 (versus 0.5.23 and 1.1):
@itemize @bullet
@item
Fix @code{libg2c} so it performs an implicit @code{ENDFILE} operation
(as appropriate)
whenever a @code{REWIND} is done.
(This bug was introduced in 0.5.23 and @code{egcs} 1.1 in
@code{g77}'s version of @code{libf2c}.)
@item
Fix @code{libg2c} so it no longer crashes with a spurious diagnostic
upon doing any I/O following a direct formatted write.
(This bug was introduced in 0.5.23 and @code{egcs} 1.1 in
@code{g77}'s version of @code{libf2c}.)
@item
Fix @code{g77} so it no longer crashes compiling references
to the @samp{Rand} intrinsic on some systems.
@item
Fix @code{g77} portion of installation process so it works
better on some systems
(those with shells requiring @samp{else true} clauses
on @samp{if} constructs
for the completion code to be set properly).
@end itemize
@heading In @code{egcs} 1.1 (versus 0.5.24):
@ -108,6 +127,7 @@ having the @code{SAVE} attribute
or given initial values via @code{DATA}.
@end itemize
@c 1998-09-01: egcs-1.1 released.
@heading In @code{egcs} 1.1 (versus @code{egcs} 1.0.3):
@itemize @bullet
@item

View File

@ -369,6 +369,39 @@ extern "C"\
fi
fi
# This fix has the regex modified from the from fixinc.wrap
# Avoid the definition of the bool type in the following files when using
# g++, since it's now an official type in the C++ language.
for file in term.h tinfo.h
do
if [ -r $INPUT/$file ]; then
echo Checking $INPUT/$file
w='[ ]'
if grep "typedef$w.*char$w.*bool$w*;" $INPUT/$file >/dev/null
then
echo Fixed $file
rm -f $LIB/$file
cat << __EOF__ >$LIB/$file
#ifndef _CURSES_H_WRAPPER
#ifdef __cplusplus
# define bool __curses_bool_t
#endif
#include_next <$file>
#ifdef __cplusplus
# undef bool
#endif
#define _CURSES_H_WRAPPER
#endif /* _CURSES_H_WRAPPER */
__EOF__
# Define _CURSES_H_WRAPPER at the end of the wrapper, not the start,
# so that if #include_next gets another instance of the wrapper,
# this will follow the #include_next chain until we arrive at
# the real system include file.
chmod a+r $LIB/$file
fi
fi
done
echo 'Removing unneeded directories:'
cd $LIB
files=`find . -type d -print | sort -r`

View File

@ -2921,17 +2921,42 @@ if [ -r ${LIB}/$file ]; then
fi
fi
# rpc/xdr.h on SunOS needs prototypes for its XDR->xdr_ops function pointers.
file=rpc/xdr.h
if [ -r $file ] && [ ! -r ${LIB}/$file ]; then
cp $file ${LIB}/$file >/dev/null 2>&1 || echo "Can't copy $file"
chmod +w ${LIB}/$file 2>/dev/null
chmod a+r ${LIB}/$file 2>/dev/null
fi
# rpc/auth.h on SunOS needs prototypes for its AUTH->auth_ops function pointers
# Similarly for
# rpc/clnt.h CLIENT->clnt_ops
# rpc/svc.h SVCXPRT->xp_ops
# rpc/xdr.h XDR->xdr_ops
for file in rpc/auth.h rpc/clnt.h rpc/svc.h rpc/xdr.h; do
# each file has a different name to replace, so if you add a file to
# that list please update the following case statement.
case "$file" in
rpc/auth.h)
prefix="ah_"
;;
rpc/clnt.h)
prefix="cl_"
;;
rpc/svc.h)
prefix="xp_"
;;
rpc/xdr.h)
prefix="x_"
;;
*)
# Oh Oh, we shouldn't be here
exit 1;
;;
esac
if [ -r ${LIB}/$file ]; then
echo "Checking for needed C++ prototype in $file"
sed -e 's/^\(.*\)\*\(x_.*\)();\(.*\)/\
if [ -r $file ] && [ ! -r ${LIB}/$file ]; then
cp $file ${LIB}/$file >/dev/null 2>&1 || echo "Can't copy $file"
chmod +w ${LIB}/$file 2>/dev/null
chmod a+r ${LIB}/$file 2>/dev/null
fi
if [ -r ${LIB}/$file ]; then
echo "Checking for needed C++ prototype in $file"
sed -e 's/^\(.*\)\*\('$prefix'.*\)();\(.*\)/\
#ifdef __cplusplus\
\1*\2(...);\3\
#else\
@ -2939,17 +2964,18 @@ if [ -r ${LIB}/$file ]; then
#endif/g' \
$LIB/$file > ${LIB}/${file}.sed
rm -f ${LIB}/$file; mv ${LIB}/${file}.sed ${LIB}/$file
if cmp $file ${LIB}/$file >/dev/null 2>&1; then
rm -f ${LIB}/$file
else
# Find any include directives that use "file".
for include in `egrep '^[ ]*#[ ]*include[ ]*"[^/]' ${LIB}/$file | sed -e 's/^[ ]*#[ ]*include[ ]*"\([^"]*\)".*$/\1/'`; do
rm -f ${LIB}/$file; mv ${LIB}/${file}.sed ${LIB}/$file
if cmp $file ${LIB}/$file >/dev/null 2>&1; then
rm -f ${LIB}/$file
else
# Find any include directives that use "file".
for include in `egrep '^[ ]*#[ ]*include[ ]*"[^/]' ${LIB}/$file | sed -e 's/^[ ]*#[ ]*include[ ]*"\([^"]*\)".*$/\1/'`; do
dir=`echo $file | sed -e s'|/[^/]*$||'`
required="$required ${INPUT} $dir/$include ${LIB}/$dir/$include"
done
done
fi
fi
fi
done
# sys/lc_core.h on some versions of OSF1/4.x pollutes the namespace by
# defining regex.h types. This causes C++ library build and usage failures.

View File

@ -145,6 +145,7 @@ struct function
rtx ehc;
/* For expr.c. */
rtx pending_chain;
int pending_stack_adjust;
int inhibit_defer_pop;
rtx saveregs_value;

View File

@ -150,7 +150,7 @@ instead of in the original English.
@sp 1
@c The version number appears five times more in this file.
@center for egcs-1.1
@center for egcs-1.1.1
@page
@vskip 0pt plus 1filll
Copyright @copyright{} 1988, 89, 92, 93, 94, 95, 96, 98 Free Software Foundation, Inc.
@ -194,19 +194,19 @@ instead of in the original English.
@ifset USING
This manual documents how to run, install and port the GNU
compiler, as well as its new features and incompatibilities, and how to
report bugs. It corresponds to EGCS version 1.1.
report bugs. It corresponds to EGCS version 1.1.1.
@end ifset
@end ifset
@ifclear INTERNALS
This manual documents how to run and install the GNU compiler,
as well as its new features and incompatibilities, and how to report
bugs. It corresponds to EGCS version 1.1.
bugs. It corresponds to EGCS version 1.1.1.
@end ifclear
@ifclear USING
This manual documents how to port the GNU compiler,
as well as its new features and incompatibilities, and how to report
bugs. It corresponds to EGCS version 1.1.
bugs. It corresponds to EGCS version 1.1.1.
@end ifclear
@end ifinfo

View File

@ -158,9 +158,6 @@ __extension__ (*({ \
} \
else \
{ \
if (__va_longlong_p(TYPE) && ((long)__va_overflow(AP) & 4) != 0) \
__va_overflow(AP) += 4; \
\
__ptr = (TYPE *) (void *) (__va_overflow(AP)); \
__va_overflow(AP) += __va_size (TYPE) * sizeof (long); \
} \

13
gnu/dist/gcc/jump.c vendored
View File

@ -182,6 +182,12 @@ jump_optimize (f, cross_jump, noop_moves, after_regscan)
max_uid++;
/* If we are performing cross jump optimizations, then initialize
tables mapping UIDs to EH regions to avoid incorrect movement
of insns from one EH region to another. */
if (flag_exceptions && cross_jump)
init_insn_eh_region (f, max_uid);
/* Delete insns following barriers, up to next label. */
for (insn = f; insn;)
@ -2708,6 +2714,13 @@ find_cross_jump (e1, e2, minimum, f1, f2)
if (i2 == 0 || GET_CODE (i1) != GET_CODE (i2))
break;
/* Avoid moving insns across EH regions.
??? This is only necessary if i1 or i2 can throw an exception. */
if (flag_exceptions
&& !in_same_eh_region (i1, i2))
break;
p1 = PATTERN (i1);
p2 = PATTERN (i2);

9
gnu/dist/gcc/loop.c vendored
View File

@ -786,18 +786,13 @@ scan_loop (loop_start, end, nregs, unroll_p)
We don't know its life-span, so we can't compute the benefit. */
if (REGNO (SET_DEST (set)) >= max_reg_before_loop)
;
/* In order to move a register, we need to have one of three cases:
/* In order to move a register, we need to have either:
(1) it is used only in the same basic block as the set
(2) it is not a user variable and it is not used in the
exit test (this can cause the variable to be used
before it is set just like a user-variable).
(3) the set is guaranteed to be executed once the loop starts,
(2) the set is guaranteed to be executed once the loop starts,
and the reg is not used until after that. */
else if (! ((! maybe_never
&& ! loop_reg_used_before_p (set, p, loop_start,
scan_start, end))
|| (! REG_USERVAR_P (SET_DEST (set))
&& ! REG_LOOP_TEST_P (SET_DEST (set)))
|| reg_in_basic_block_p (p, SET_DEST (set))))
;
else if ((tem = invariant_p (src))

12
gnu/dist/gcc/stmt.c vendored
View File

@ -885,19 +885,25 @@ expand_fixup (tree_label, rtl_label, last_insn)
code which we might later insert at this point in the insn
stream. Also, the BLOCK node will be the parent (i.e. the
`SUPERBLOCK') of any other BLOCK nodes which we might create
later on when we are expanding the fixup code. */
later on when we are expanding the fixup code.
Note that optimization passes (including expand_end_loop)
might move the *_BLOCK notes away, so we use a NOTE_INSN_DELETED
as a placeholder. */
{
register rtx original_before_jump
= last_insn ? last_insn : get_last_insn ();
rtx start;
start_sequence ();
pushlevel (0);
fixup->before_jump = emit_note (NULL_PTR, NOTE_INSN_BLOCK_BEG);
start = emit_note (NULL_PTR, NOTE_INSN_BLOCK_BEG);
fixup->before_jump = emit_note (NULL_PTR, NOTE_INSN_DELETED);
last_block_end_note = emit_note (NULL_PTR, NOTE_INSN_BLOCK_END);
fixup->context = poplevel (1, 0, 0); /* Create the BLOCK node now! */
end_sequence ();
emit_insns_after (fixup->before_jump, original_before_jump);
emit_insns_after (start, original_before_jump);
}
fixup->block_start_count = block_start_count;

View File

@ -1 +1 @@
char *version_string = "egcs-2.91.57 19980901 (egcs-1.1 release)";
char *version_string = "egcs-2.91.58 19981101 (egcs-1.1.1 pre-release)";