dwarf2out.c (dwarf2out_finish): Don't abort because of orphan DIEs if there were errors in the source.

* dwarf2out.c (dwarf2out_finish): Don't abort because of orphan
        DIEs if there were errors in the source.

        * config/alpha/alpha-interix.h, config/alpha/elf.h,
        config/arm/coff.h, config/i386/djgpp.h, config/i386/i386.c,
        config/i386/i386.h, config/i386/sco5.h, config/i960/i960-coff.h,
        config/m68k/coff.h, config/m88k/m88k.h, config/m88k/m88k.c,
        config/pa/pa64-hpux.h, config/sh/sh.h, config/sparc/litecoff.h,
        config/elfos.h, config/lynx.h, config/netware.h,
        config/m68hc11/m68hc11.h, config/mcore/mcore-pe.h,
        config/s390/linux64.h: Remove definitions of INT_ASM_OP, change
        uses to use ASM_LONG.

From-SVN: r47066
This commit is contained in:
Jason Merrill 2001-11-15 12:55:28 -05:00 committed by Jason Merrill
parent f6b08fe890
commit 18b5b8d64c
23 changed files with 109 additions and 70 deletions

View File

@ -1,3 +1,18 @@
2001-11-15 Jason Merrill <jason@redhat.com>
* dwarf2out.c (dwarf2out_finish): Don't abort because of orphan
DIEs if there were errors in the source.
* config/alpha/alpha-interix.h, config/alpha/elf.h,
config/arm/coff.h, config/i386/djgpp.h, config/i386/i386.c,
config/i386/i386.h, config/i386/sco5.h, config/i960/i960-coff.h,
config/m68k/coff.h, config/m88k/m88k.h, config/m88k/m88k.c,
config/pa/pa64-hpux.h, config/sh/sh.h, config/sparc/litecoff.h,
config/elfos.h, config/lynx.h, config/netware.h,
config/m68hc11/m68hc11.h, config/mcore/mcore-pe.h,
config/s390/linux64.h: Remove definitions of INT_ASM_OP, change
uses to use ASM_LONG.
2001-11-15 Alan Matsuoka <alanm@redhat.com>
* gensupport.c process_include : Change call to alloca to

View File

@ -126,8 +126,6 @@ const_section () \
} \
}
#define INT_ASM_OP "\t.long\t"
/* The linker will take care of this, and having them causes problems with
ld -r (specifically -rU). */
#define CTOR_LISTS_DEFINED_EXTERNALLY 1

View File

@ -165,12 +165,6 @@ do { \
ASM_OUTPUT_SKIP((FILE), (SIZE)); \
} while (0)
/* This is the pseudo-op used to generate a 64-bit word of data with a
specific value in some section. */
#undef INT_ASM_OP
#define INT_ASM_OP "\t.quad\t"
/* Biggest alignment supported by the object file format of this
machine. Use this macro to limit the alignment which can be
specified using the `__attribute__ ((aligned (N)))' construct. If

View File

@ -115,8 +115,6 @@ rdata_section () \
/* Support the ctors/dtors sections for g++. */
#define INT_ASM_OP "\t.word\t"
/* __CTOR_LIST__ and __DTOR_LIST__ must be defined by the linker script. */
#define CTOR_LISTS_DEFINED_EXTERNALLY

View File

@ -224,17 +224,6 @@ Boston, MA 02111-1307, USA. */
} \
while (0)
/* This is the pseudo-op used to generate a reference to a specific
symbol in some section. It is only used in machine-specific
configuration files. This is the same for all known svr4
assemblers, except those in targets that don't use 32-bit pointers.
Those should override INT_ASM_OP. Yes, the name of the macro is
misleading. */
#ifndef INT_ASM_OP
#define INT_ASM_OP "\t.long\t"
#endif
/* This is the pseudo-op used to generate a contiguous sequence of byte
values from a double-quoted string WITHOUT HAVING A TERMINATING NUL
AUTOMATICALLY APPENDED. This is the same for most svr4 assemblers. */

View File

@ -53,10 +53,6 @@ Boston, MA 02111-1307, USA. */
#undef IDENT_ASM_OP
#define IDENT_ASM_OP "\t.ident\t"
/* Define the name of the .int op. */
#undef INT_ASM_OP
#define INT_ASM_OP "\t.long\t"
/* Enable alias attribute support. */
#ifndef SET_ASM_OP
#define SET_ASM_OP "\t.set\t"

View File

@ -5212,11 +5212,11 @@ i386_dwarf_output_addr_const (file, x)
rtx x;
{
#ifdef ASM_QUAD
fprintf (file, "%s", TARGET_64BIT ? ASM_QUAD : INT_ASM_OP);
fprintf (file, "%s", TARGET_64BIT ? ASM_QUAD : ASM_LONG);
#else
if (TARGET_64BIT)
abort ();
fprintf (file, "%s", INT_ASM_OP);
fprintf (file, "%s", ASM_LONG);
#endif
if (flag_pic)
output_pic_addr_const (file, x, '\0');

View File

@ -2969,7 +2969,6 @@ do { long l; \
degenerate to the macros used above. */
#define UNALIGNED_SHORT_ASM_OP ASM_SHORT
#define UNALIGNED_INT_ASM_OP ASM_LONG
#define INT_ASM_OP ASM_LONG
/* This is how to output an assembler line for a numeric constant byte. */

View File

@ -50,9 +50,6 @@ Boston, MA 02111-1307, USA. */
#undef LOCAL_ASM_OP
#define LOCAL_ASM_OP "\t.local\t"
#undef INT_ASM_OP
#define INT_ASM_OP "\t.long\t"
#undef ASM_SHORT
#define ASM_SHORT "\t.value\t"

84
gcc/config/i386/scodbx.h Normal file
View File

@ -0,0 +1,84 @@
/* Definitions for Intel 386 running SCO Unix System V,
using dbx-in-coff encapsulation.
Copyright (C) 1992, 1995, 1996, 1999 Free Software Foundation, Inc.
This file is part of GNU CC.
GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "i386/svr3dbx.h"
/* Overridden defines for SCO systems from sco.h. */
/* By default, target has a 80387, uses IEEE compatible arithmetic,
and returns float values in the 387, ie,
(TARGET_80387 | TARGET_FLOAT_RETURNS_IN_80387)
SCO's software emulation of a 387 fails to handle the `fucomp'
opcode. fucomp is only used when generating IEEE compliant code.
So don't make TARGET_IEEE_FP default for SCO. */
#undef TARGET_SUBTARGET_DEFAULT
#define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_FLOAT_RETURNS)
/* Use crt1.o as a startup file and crtn.o as a closing file. */
#undef STARTFILE_SPEC
#define STARTFILE_SPEC \
"%{!r:%{!z:svr3.ifile%s}%{z:svr3z.ifile%s}}\
%{pg:gcrt1.o%s}%{!pg:%{p:mcrt1.o%s}%{!p:crt1.o%s}}"
/* Library spec, including SCO international language support. */
#undef LIB_SPEC
#define LIB_SPEC \
"%{p:-L/usr/lib/libp}%{pg:-L/usr/lib/libp} %{scointl:libintl.a%s} -lc"
/* Specify predefined symbols in preprocessor. */
#undef CPP_PREDEFINES
#define CPP_PREDEFINES "-Dunix -DM_UNIX -DM_I386 -DM_COFF -DM_WORDSWAP -Asystem=svr3"
#undef CPP_SPEC
#define CPP_SPEC "%(cpp_cpu) %{scointl:-DM_INTERNAT}"
/* This spec is used for telling cpp whether char is signed or not. */
#undef SIGNED_CHAR_SPEC
#if DEFAULT_SIGNED_CHAR
#define SIGNED_CHAR_SPEC \
"%{funsigned-char:-D__CHAR_UNSIGNED__ -D_CHAR_UNSIGNED}"
#else
#define SIGNED_CHAR_SPEC \
"%{!fsigned-char:-D__CHAR_UNSIGNED__ -D_CHAR_UNSIGNED}"
#endif
/* caller has to pop the extra argument passed to functions that return
structures. */
#undef RETURN_POPS_ARGS
#define RETURN_POPS_ARGS(FUNDECL,FUNTYPE,SIZE) \
((FUNDECL) && TREE_CODE (FUNDECL) == IDENTIFIER_NODE ? 0 \
: (TARGET_RTD \
&& (TYPE_ARG_TYPES (FUNTYPE) == 0 \
|| (TREE_VALUE (tree_last (TYPE_ARG_TYPES (FUNTYPE))) \
== void_type_node))) ? (SIZE) \
: 0)
/* On other 386 systems, the last line looks like this:
: (aggregate_value_p (TREE_TYPE (FUNTYPE))) ? GET_MODE_SIZE (Pmode) : 0) */
/* Handle #pragma pack. */
#define HANDLE_SYSV_PRAGMA

View File

@ -41,6 +41,4 @@ Boston, MA 02111-1307, USA. */
#define CTORS_SECTION_ASM_OP "\t.section\t.ctors,\"x\""
#define DTORS_SECTION_ASM_OP "\t.section\t.dtors,\"x\""
#define INT_ASM_OP "\t.word\t"
/* end of i960-coff.h */

View File

@ -140,8 +140,6 @@ do { \
#undef DTORS_SECTION_ASM_OP
#define DTORS_SECTION_ASM_OP "\t.section\t.dtors"
#define INT_ASM_OP "\t.long\t"
#undef DO_GLOBAL_CTORS_BODY
#undef DO_GLOBAL_DTORS_BODY

View File

@ -1570,15 +1570,6 @@ do { \
/* Output before uninitialized data. */
#define BSS_SECTION_ASM_OP ("\t.sect\t.bss")
/* This is the pseudo-op used to generate a reference to a specific
symbol in some section. It is only used in machine-specific
configuration files. This is the same for all known svr4
assemblers, except those in targets that don't use 32-bit pointers.
Those should override INT_ASM_OP. Yes, the name of the macro is
misleading. */
#undef INT_ASM_OP
#define INT_ASM_OP "\t.word\t"
/* Define the pseudo-ops used to switch to the .ctors and .dtors sections.
Same as config/elfos.h but don't mark these section SHF_WRITE since

View File

@ -104,8 +104,6 @@ Boston, MA 02111-1307, USA. */
#undef TARGET_ASM_NAMED_SECTION
#define TARGET_ASM_NAMED_SECTION m68k_coff_asm_named_section
#define INT_ASM_OP "\t.long\t"
/* Don't assume anything about startfiles. */
#undef STARTFILE_SPEC

View File

@ -2367,7 +2367,7 @@ output_tdesc (file, offset)
tdesc_section ();
fprintf (file, "%s%d,%d", INT_ASM_OP, /* 8:0,22:(20 or 16),2:2 */
fprintf (file, "%s%d,%d", ASM_LONG, /* 8:0,22:(20 or 16),2:2 */
(((xmask != 0) ? 20 : 16) << 2) | 2,
flag_pic ? 2 : 1);

View File

@ -1651,7 +1651,6 @@ enum reg_class { NO_REGS, AP_REG, XRF_REGS, GENERAL_REGS, AGRF_REGS,
#define ASM_COMMENT_START ";"
/* Allow pseudo-ops to be overridden. Override these in svr[34].h. */
#undef INT_ASM_OP
#undef ASCII_DATA_ASM_OP
#undef CONST_SECTION_ASM_OP
#undef CTORS_SECTION_ASM_OP
@ -1697,8 +1696,7 @@ enum reg_class { NO_REGS, AP_REG, XRF_REGS, GENERAL_REGS, AGRF_REGS,
#define BSS_ASM_OP "\tbss\t"
#define FLOAT_ASM_OP "\tfloat\t"
#define DOUBLE_ASM_OP "\tdouble\t"
#define INT_ASM_OP "\tword\t"
#define ASM_LONG INT_ASM_OP
#define ASM_LONG "\tword\t"
#define SHORT_ASM_OP "\thalf\t"
#define CHAR_ASM_OP "\tbyte\t"
#define ASCII_DATA_ASM_OP "\tstring\t"
@ -2049,7 +2047,7 @@ do { \
do { \
union { REAL_VALUE_TYPE d; long l[2]; } x; \
x.d = (VALUE); \
fprintf (FILE, "%s0x%.8lx, 0x%.8lx\n", INT_ASM_OP, \
fprintf (FILE, "%s0x%.8lx, 0x%.8lx\n", ASM_LONG, \
(long) x.l[0], (long) x.l[1]); \
} while (0)
@ -2058,12 +2056,12 @@ do { \
do { \
int i; \
FLOAT_TO_INT_INTERNAL (VALUE, i); \
fprintf (FILE, "%s0x%.8x\n", INT_ASM_OP, i); \
fprintf (FILE, "%s0x%.8x\n", ASM_LONG, i); \
} while (0)
/* Likewise for `int', `short', and `char' constants. */
#define ASM_OUTPUT_INT(FILE,VALUE) \
( fprintf (FILE, "%s", INT_ASM_OP), \
( fprintf (FILE, "%s", ASM_LONG), \
output_addr_const (FILE, (VALUE)), \
fprintf (FILE, "\n"))

View File

@ -183,8 +183,6 @@ rdata_section () \
#define STARTFILE_SPEC "crt0.o%s"
#define ENDFILE_SPEC "%{!mno-lsim:-lsim}"
#define INT_ASM_OP "\t.long\t"
/* __CTOR_LIST__ and __DTOR_LIST__ must be defined by the linker script. */
#define CTOR_LISTS_DEFINED_EXTERNALLY

View File

@ -100,6 +100,3 @@ const_section () \
in_section = in_const; \
} \
}
#undef INT_ASM_OP
#define INT_ASM_OP ".long"

View File

@ -180,8 +180,6 @@ do { \
DECL_SECTION_NAME (DECL) = build_string (len, string); \
} while (0)
#define INT_ASM_OP "\t.dword\t"
/* Define the strings used for the special svr4 .type and .size directives.
These strings generally do not vary from one system running svr4 to
another, but if a given system (e.g. m88k running svr) needs to use

View File

@ -59,9 +59,6 @@ Boston, MA 02111-1307, USA. */
%{static:-static}}}"
#endif
#undef INT_ASM_OP
#define INT_ASM_OP "\t.quad\t"
#undef PROMOTE_PROTOTYPES
#undef MASK_RETURN_ADDR
#undef SELECT_SECTION

View File

@ -1929,11 +1929,6 @@ while (0)
/* Switch into a generic section. */
#define TARGET_ASM_NAMED_SECTION sh_asm_named_section
/* This is the pseudo-op used to generate a reference to a specific
symbol in some section. */
#define INT_ASM_OP "\t.long\t"
#undef DO_GLOBAL_CTORS_BODY
#define DO_GLOBAL_CTORS_BODY \
{ \

View File

@ -44,8 +44,6 @@ Boston, MA 02111-1307, USA. */
#define EXTRA_SECTION_FUNCTIONS \
CONST_SECTION_FUNCTION
#define INT_ASM_OP "\t.long\t"
#undef DO_GLOBAL_CTORS_BODY
#undef DO_GLOBAL_DTORS_BODY

View File

@ -11853,6 +11853,9 @@ dwarf2out_finish (input_filename)
add_child_die (origin->die_parent, die);
else if (die == comp_unit_die)
;
else if (errorcount > 0 || sorrycount > 0)
/* It's OK to be confused by errors in the input. */
add_child_die (comp_unit_die, die);
else
abort ();
}