OSDN Git Service

* configure.in: Check whether assembler supports section merging.
[pf3gnuchains/gcc-fork.git] / gcc / config / rs6000 / sysv4.h
index c9d9ba8..1b2051d 100644 (file)
@@ -1,5 +1,6 @@
 /* Target definitions for GNU compiler for PowerPC running System V.4
-   Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
+   Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001
+   Free Software Foundation, Inc.
    Contributed by Cygnus Support.
 
 This file is part of GNU CC.
@@ -19,11 +20,6 @@ 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 "rs6000/rs6000.h"
-
-/* Use the regular svr4 definitions.  */
-
-#include "svr4.h"
 
 /* Yes!  We are ELF.  */
 #define        TARGET_OBJECT_FORMAT OBJECT_ELF
@@ -60,6 +56,8 @@ extern enum rs6000_sdata_type rs6000_sdata;
 #define        MASK_LITTLE_ENDIAN      0x04000000      /* Target is little endian.  */
 #define        MASK_REGNAMES           0x02000000      /* Use alternate register names.  */
 #define        MASK_PROTOTYPE          0x01000000      /* Only prototyped fcns pass variable args.  */
+#define MASK_LONG_DOUBLE_128   0x00800000      /* Use IEEE quad long double.  */
+#define MASK_NO_BITFIELD_WORD  0x00400000      /* Bitfields cannot cross word boundaries */
 
 #define        TARGET_NO_BITFIELD_TYPE (target_flags & MASK_NO_BITFIELD_TYPE)
 #define        TARGET_STRICT_ALIGN     (target_flags & MASK_STRICT_ALIGN)
@@ -68,6 +66,8 @@ extern enum rs6000_sdata_type rs6000_sdata;
 #define        TARGET_LITTLE_ENDIAN    (target_flags & MASK_LITTLE_ENDIAN)
 #define        TARGET_REGNAMES         (target_flags & MASK_REGNAMES)
 #define        TARGET_PROTOTYPE        (target_flags & MASK_PROTOTYPE)
+#define TARGET_LONG_DOUBLE_128 (target_flags & MASK_LONG_DOUBLE_128)
+#define TARGET_NO_BITFIELD_WORD        (target_flags & MASK_NO_BITFIELD_WORD)
 #define        TARGET_TOC              ((target_flags & MASK_64BIT)            \
                                 || ((target_flags & (MASK_RELOCATABLE  \
                                                      | MASK_MINIMAL_TOC)) \
@@ -87,8 +87,8 @@ extern const char *rs6000_sdata_name;
 /* Override rs6000.h definition.  */
 #undef SUBTARGET_OPTIONS
 #define        SUBTARGET_OPTIONS                                               \
-  { "call-",  &rs6000_abi_name, "Select ABI calling convention." },                    \
-  { "sdata=", &rs6000_sdata_name, "Select method for sdata handling." }
+  { "call-",  &rs6000_abi_name, N_("Select ABI calling convention.") },        \
+  { "sdata=", &rs6000_sdata_name, N_("Select method for sdata handling.") }
 
 /* Max # of bytes for variables to automatically be put into the .sdata
    or .sdata2 sections.  */
@@ -102,40 +102,66 @@ extern int g_switch_set;          /* Whether -G xx was passed.  */
 /* Override rs6000.h definition.  */
 #undef SUBTARGET_SWITCHES
 #define SUBTARGET_SWITCHES                                             \
-  { "bit-align",       -MASK_NO_BITFIELD_TYPE, "Align to the base type of the bitfield." },\
-  { "no-bit-align",     MASK_NO_BITFIELD_TYPE, "Don't align to the base type of the bitfield." },\
-  { "strict-align",     MASK_STRICT_ALIGN, "Don't assume that unaligned accesses are handled by the system" },\
-  { "no-strict-align", -MASK_STRICT_ALIGN, "Assume that unaligned accesses are handled by the system" },\
-  { "relocatable",      MASK_RELOCATABLE | MASK_MINIMAL_TOC | MASK_NO_FP_IN_TOC, "Produce code relocatable at runtime." },\
-  { "no-relocatable",  -MASK_RELOCATABLE, "Don't produce code relocatable at runtime." },\
-  { "relocatable-lib",  MASK_RELOCATABLE | MASK_MINIMAL_TOC | MASK_NO_FP_IN_TOC, "Produce code relocatable at runtime." },\
-  { "no-relocatable-lib", -MASK_RELOCATABLE, "Don't produce code relocatable at runtime." },\
-  { "little-endian",    MASK_LITTLE_ENDIAN, "Produce little endian code." },   \
-  { "little",           MASK_LITTLE_ENDIAN, "Produce little endian code." },   \
-  { "big-endian",      -MASK_LITTLE_ENDIAN, "Produce big endian code." },      \
-  { "big",             -MASK_LITTLE_ENDIAN, "Produce big endian code." },      \
-  { "no-toc",           0, "no description yet" },                             \
-  { "toc",              MASK_MINIMAL_TOC, "no description yet" },              \
-  { "full-toc",                 MASK_MINIMAL_TOC, "no description yet" },              \
-  { "prototype",        MASK_PROTOTYPE, "no description yet" },                \
-  { "no-prototype",    -MASK_PROTOTYPE, "no description yet" },                \
-  { "no-traceback",     0, "no description yet" },                             \
-  { "eabi",             MASK_EABI, "Use EABI." },                              \
-  { "no-eabi",         -MASK_EABI, "Don't use EABI." },                        \
-  { "regnames",                  MASK_REGNAMES, "Use alternate register names." },     \
-  { "no-regnames",      -MASK_REGNAMES, "Don't use alternate register names." },\
-  { "sdata",            0, "no description yet" },                             \
-  { "no-sdata",                 0, "no description yet" },                             \
-  { "sim",              0, "Link with libsim.a, libc.a and sim-crt0.o." },     \
-  { "ads",              0, "Link with libads.a, libc.a and crt0.o." },         \
-  { "yellowknife",      0, "Link with libyk.a, libc.a and crt0.o." },          \
-  { "mvme",             0, "Link with libmvme.a, libc.a and crt0.o." },        \
-  { "emb",              0, "Set the PPC_EMB bit in the ELF flags header" },    \
-  { "vxworks",          0, "no description yet" },                             \
-  { "solaris-cclib",    0, "no description yet" },                             \
-  { "shlib",            0, "no description yet" },                             \
-  EXTRA_SUBTARGET_SWITCHES                                                     \
-  { "newlib",           0, "no description yet" },
+  { "bit-align",       -MASK_NO_BITFIELD_TYPE,                         \
+    N_("Align to the base type of the bitfield.") },                   \
+  { "no-bit-align",     MASK_NO_BITFIELD_TYPE,                         \
+    N_("Don't align to the base type of the bitfield.") },             \
+  { "strict-align",     MASK_STRICT_ALIGN,                             \
+    N_("Don't assume that unaligned accesses are handled by the system") }, \
+  { "no-strict-align", -MASK_STRICT_ALIGN,                             \
+    N_("Assume that unaligned accesses are handled by the system") },  \
+  { "relocatable",      MASK_RELOCATABLE | MASK_MINIMAL_TOC | MASK_NO_FP_IN_TOC, \
+    N_("Produce code relocatable at runtime.") },                      \
+  { "no-relocatable",  -MASK_RELOCATABLE,                              \
+    N_("Don't produce code relocatable at runtime.") },                        \
+  { "relocatable-lib",  MASK_RELOCATABLE | MASK_MINIMAL_TOC | MASK_NO_FP_IN_TOC, \
+    N_("Produce code relocatable at runtime.") },                      \
+  { "no-relocatable-lib", -MASK_RELOCATABLE,                           \
+    N_("Don't produce code relocatable at runtime.") },                        \
+  { "little-endian",    MASK_LITTLE_ENDIAN,                            \
+    N_("Produce little endian code.") },                               \
+  { "little",           MASK_LITTLE_ENDIAN,                            \
+    N_("Produce little endian code.") },                               \
+  { "big-endian",      -MASK_LITTLE_ENDIAN,                            \
+    N_("Produce big endian code.") },                                  \
+  { "big",             -MASK_LITTLE_ENDIAN,                            \
+    N_("Produce big endian code.") },                                  \
+  { "long-double-64",  -MASK_LONG_DOUBLE_128,                          \
+    N_("Use 64 bit long doubles") },                                   \
+  { "long-double-128",  MASK_LONG_DOUBLE_128,                          \
+    N_("Use 128 bit long doubles") },                                  \
+  { "no-toc",           0, N_("no description yet") },                 \
+  { "toc",              MASK_MINIMAL_TOC, N_("no description yet") },  \
+  { "full-toc",                 MASK_MINIMAL_TOC, N_("no description yet") },  \
+  { "prototype",        MASK_PROTOTYPE, N_("no description yet") },    \
+  { "no-prototype",    -MASK_PROTOTYPE, N_("no description yet") },    \
+  { "no-traceback",     0, N_("no description yet") },                 \
+  { "eabi",             MASK_EABI, N_("Use EABI.") },                  \
+  { "no-eabi",         -MASK_EABI, N_("Don't use EABI.") },            \
+  { "bit-word",                -MASK_NO_BITFIELD_WORD, "" },                   \
+  { "no-bit-word",      MASK_NO_BITFIELD_WORD,                         \
+    N_("Do not allow bitfields to cross word boundaries") },           \
+  { "regnames",                  MASK_REGNAMES,                                \
+    N_("Use alternate register names.") },                             \
+  { "no-regnames",      -MASK_REGNAMES,                                \
+    N_("Don't use alternate register names.") },                       \
+  { "sdata",            0, N_("no description yet") },                 \
+  { "no-sdata",                 0, N_("no description yet") },                 \
+  { "sim",              0,                                             \
+    N_("Link with libsim.a, libc.a and sim-crt0.o.") },                        \
+  { "ads",              0,                                             \
+    N_("Link with libads.a, libc.a and crt0.o.") },                    \
+  { "yellowknife",      0,                                             \
+    N_("Link with libyk.a, libc.a and crt0.o.") },                     \
+  { "mvme",             0,                                             \
+    N_("Link with libmvme.a, libc.a and crt0.o.") },                   \
+  { "emb",              0,                                             \
+    N_("Set the PPC_EMB bit in the ELF flags header") },               \
+  { "vxworks",          0, N_("no description yet") },                 \
+  { "solaris-cclib",    0, N_("no description yet") },                 \
+  { "shlib",            0, N_("no description yet") },                 \
+  EXTRA_SUBTARGET_SWITCHES                                             \
+  { "newlib",           0, N_("no description yet") },
 
 /* This is meant to be redefined in the host dependent files.  */
 #define EXTRA_SUBTARGET_SWITCHES
@@ -176,8 +202,17 @@ do {                                                                       \
     rs6000_current_abi = ABI_AIX;                                      \
   else if (!strcmp (rs6000_abi_name, "linux"))                         \
     rs6000_current_abi = ABI_V4;                                       \
+  else if (!strcmp (rs6000_abi_name, "netbsd"))                                \
+    rs6000_current_abi = ABI_V4;                                       \
   else if (!strcmp (rs6000_abi_name, "solaris"))                       \
     rs6000_current_abi = ABI_SOLARIS;                                  \
+  else if (!strcmp (rs6000_abi_name, "i960-old"))                      \
+    {                                                                  \
+      rs6000_current_abi = ABI_V4;                                     \
+      target_flags |= (MASK_LITTLE_ENDIAN | MASK_EABI                  \
+                      | MASK_NO_BITFIELD_WORD);                        \
+      target_flags &= ~MASK_STRICT_ALIGN;                              \
+    }                                                                  \
   else                                                                 \
     {                                                                  \
       rs6000_current_abi = ABI_V4;                                     \
@@ -287,7 +322,7 @@ do {                                                                        \
 /* Size of the V.4 varargs area if needed.  */
 /* Override rs6000.h definition.  */
 #undef RS6000_VARARGS_AREA
-#define RS6000_VARARGS_AREA ((rs6000_sysv_varargs_p) ? RS6000_VARARGS_SIZE : 0)
+#define RS6000_VARARGS_AREA ((cfun->machine->sysv_varargs_p) ? RS6000_VARARGS_SIZE : 0)
 
 /* Override default big endianism definitions in rs6000.h.  */
 #undef BYTES_BIG_ENDIAN
@@ -331,11 +366,30 @@ do {                                                                      \
 #undef WCHAR_TYPE_SIZE
 #define WCHAR_TYPE_SIZE 32
 
+/* Define for support of TFmode long double and REAL_ARITHMETIC.
+   PowerPC SVR4 ABI says that long double is 4 words.  */
+#undef LONG_DOUBLE_TYPE_SIZE
+#define LONG_DOUBLE_TYPE_SIZE (TARGET_LONG_DOUBLE_128 ? 128 : 64)
+
+/* Constant which presents upper bound of the above value.  */
+#define MAX_LONG_DOUBLE_TYPE_SIZE 128
+
+/* Define this to set long double type size to use in libgcc2.c, which can
+   not depend on target_flags.  */
+#ifdef __LONG_DOUBLE_128__
+#define LIBGCC2_LONG_DOUBLE_TYPE_SIZE 128
+#else
+#define LIBGCC2_LONG_DOUBLE_TYPE_SIZE 64
+#endif
+
 /* Make int foo : 8 not cause structures to be aligned to an int boundary.  */
 /* Override elfos.h definition.  */
 #undef PCC_BITFIELD_TYPE_MATTERS
 #define        PCC_BITFIELD_TYPE_MATTERS (TARGET_BITFIELD_TYPE)
 
+#undef BITFIELD_NBYTES_LIMITED
+#define        BITFIELD_NBYTES_LIMITED (TARGET_NO_BITFIELD_WORD)
+
 /* Define this macro to be the value 1 if instructions will fail to
    work if given data not on the nominal alignment.  If instructions
    will merely go slower in that case, define this macro as 0.  */
@@ -381,13 +435,6 @@ do {                                                                       \
 #define        MINIMAL_TOC_SECTION_ASM_OP \
   ((TARGET_RELOCATABLE || flag_pic) ? "\t.section\t\".got2\",\"aw\"" : "\t.section\t\".got1\",\"aw\"")
 
-/* Put relocatable data in .data, not .rodata so initialized pointers can be updated.  */
-/* Override elfos.h definition.  */
-#undef CONST_SECTION_ASM_OP
-#define        CONST_SECTION_ASM_OP \
-  ((TARGET_RELOCATABLE || flag_pic) ? "\t.section\t\".data\"\t# .rodata" : "\t.section\t\".rodata\"")
-
-
 #define        SDATA_SECTION_ASM_OP "\t.section\t\".sdata\",\"aw\""
 #define        SDATA2_SECTION_ASM_OP "\t.section\t\".sdata2\",\"a\""
 #define        SBSS_SECTION_ASM_OP \
@@ -397,14 +444,12 @@ do {                                                                      \
 /* Besides the usual ELF sections, we need a toc section.  */
 /* Override elfos.h definition.  */
 #undef EXTRA_SECTIONS
-#define        EXTRA_SECTIONS in_const, in_ctors, in_dtors, in_toc, in_sdata, in_sdata2, in_sbss, in_init, in_fini
+#define        EXTRA_SECTIONS in_const, in_toc, in_sdata, in_sdata2, in_sbss, in_init, in_fini
 
 /* Override elfos.h definition.  */
 #undef EXTRA_SECTION_FUNCTIONS
 #define        EXTRA_SECTION_FUNCTIONS                                         \
   CONST_SECTION_FUNCTION                                               \
-  CTORS_SECTION_FUNCTION                                               \
-  DTORS_SECTION_FUNCTION                                               \
   TOC_SECTION_FUNCTION                                                 \
   SDATA_SECTION_FUNCTION                                               \
   SDATA2_SECTION_FUNCTION                                              \
@@ -521,7 +566,7 @@ fini_section ()                                                             \
 
 /* Override elfos.h definition.  */
 #undef SELECT_RTX_SECTION
-#define        SELECT_RTX_SECTION(MODE, X) rs6000_select_rtx_section (MODE, X)
+#define        SELECT_RTX_SECTION(MODE, X, ALIGN) rs6000_select_rtx_section (MODE, X)
 
 /* A C statement or statements to switch to the appropriate
    section for output of DECL.  DECL is either a `VAR_DECL' node
@@ -530,7 +575,19 @@ fini_section ()                                                            \
 
 /* Override elfos.h definition.  */
 #undef SELECT_SECTION
-#define        SELECT_SECTION(DECL,RELOC) rs6000_select_section (DECL, RELOC)
+#define        SELECT_SECTION(DECL, RELOC, ALIGN) rs6000_select_section (DECL, RELOC)
+
+/* A C statement to build up a unique section name, expressed as a
+   STRING_CST node, and assign it to DECL_SECTION_NAME (decl).
+   RELOC indicates whether the initial value of EXP requires
+   link-time relocations.  If you do not define this macro, GCC will use
+   the symbol name prefixed by `.' as the section name.  Note - this
+   macro can now be called for unitialised data items as well as
+   initialised data and functions.  */
+
+/* Override elfos.h definition.  */
+#undef UNIQUE_SECTION
+#define UNIQUE_SECTION(DECL, RELOC) rs6000_unique_section (DECL, RELOC)
 
 /* Return non-zero if this entry is to be written into the constant pool
    in a special way.  We do so if this is a SYMBOL_REF, LABEL_REF or a CONST
@@ -544,12 +601,14 @@ fini_section ()                                                           \
    allow floating point constants in the TOC if -mrelocatable.  */
 
 #undef ASM_OUTPUT_SPECIAL_POOL_ENTRY_P
-#define        ASM_OUTPUT_SPECIAL_POOL_ENTRY_P(X)                              \
+#define        ASM_OUTPUT_SPECIAL_POOL_ENTRY_P(X, MODE)                        \
   (TARGET_TOC                                                          \
    && (GET_CODE (X) == SYMBOL_REF                                      \
        || (GET_CODE (X) == CONST && GET_CODE (XEXP (X, 0)) == PLUS     \
           && GET_CODE (XEXP (XEXP (X, 0), 0)) == SYMBOL_REF)           \
        || GET_CODE (X) == LABEL_REF                                    \
+       || (GET_CODE (X) == CONST_INT                                   \
+          && GET_MODE_BITSIZE (MODE) <= GET_MODE_BITSIZE (Pmode))      \
        || (!TARGET_NO_FP_IN_TOC                                                \
           && !TARGET_RELOCATABLE                                       \
           && GET_CODE (X) == CONST_DOUBLE                              \
@@ -577,7 +636,6 @@ extern int rs6000_pic_labelno;
        && uses_TOC())                                                  \
       {                                                                        \
        char buf[256];                                                  \
-       const char *buf_ptr;                                            \
                                                                        \
        ASM_OUTPUT_INTERNAL_LABEL (FILE, "LCL", rs6000_pic_labelno);    \
                                                                        \
@@ -590,7 +648,7 @@ extern int rs6000_pic_labelno;
        putc ('\n', FILE);                                              \
       }                                                                        \
                                                                        \
-    fprintf (FILE, "\t%s\t ", TYPE_ASM_OP);                            \
+    fprintf (FILE, "%s", TYPE_ASM_OP);                                 \
     assemble_name (FILE, NAME);                                                \
     putc (',', FILE);                                                  \
     fprintf (FILE, TYPE_OPERAND_FMT, "function");                      \
@@ -684,16 +742,16 @@ extern int rs6000_pic_labelno;
 
 /* Override elfos.h definition.  */
 #undef SKIP_ASM_OP
-#define SKIP_ASM_OP    ".space"
+#define SKIP_ASM_OP    "\t.space\t"
 
 /* This says how to output assembler code to declare an
    uninitialized internal linkage data object.  Under SVR4,
    the linker seems to want the alignment of data objects
    to depend on their types.  We do exactly that here.  */
 
-#define        LOCAL_ASM_OP    ".local"
+#define        LOCAL_ASM_OP    "\t.local\t"
 
-#define        LCOMM_ASM_OP    ".lcomm"
+#define        LCOMM_ASM_OP    "\t.lcomm\t"
 
 /* Override elfos.h definition.  */
 #undef ASM_OUTPUT_ALIGNED_LOCAL
@@ -708,14 +766,14 @@ do {                                                                      \
       ASM_OUTPUT_SKIP (FILE, SIZE);                                    \
       if (!flag_inhibit_size_directive && (SIZE) > 0)                  \
        {                                                               \
-         fprintf (FILE, "\t%s\t ", SIZE_ASM_OP);                       \
+         fprintf (FILE, "%s", SIZE_ASM_OP);                            \
          assemble_name (FILE, NAME);                                   \
          fprintf (FILE, ",%d\n",  SIZE);                               \
        }                                                               \
     }                                                                  \
   else                                                                 \
     {                                                                  \
-      fprintf (FILE, "\t%s\t", LCOMM_ASM_OP);                          \
+      fprintf (FILE, "%s", LCOMM_ASM_OP);                              \
       assemble_name ((FILE), (NAME));                                  \
       fprintf ((FILE), ",%u,%u\n", (SIZE), (ALIGN) / BITS_PER_UNIT);   \
     }                                                                  \
@@ -751,6 +809,10 @@ do {                                                                       \
 
 extern int fixuplabelno;
 
+/* Handle constructors specially for -mrelocatable.  */
+#define TARGET_ASM_CONSTRUCTOR  rs6000_elf_asm_out_constructor
+#define TARGET_ASM_DESTRUCTOR   rs6000_elf_asm_out_destructor
+
 /* This is how to output an assembler line defining an `int' constant.
    For -mrelocatable, we mark all addresses that need to be fixed up
    in the .fixup section.  */
@@ -762,8 +824,6 @@ do {                                                                        \
   if (TARGET_RELOCATABLE                                               \
       && in_section != in_toc                                          \
       && in_section != in_text                                         \
-      && in_section != in_ctors                                                \
-      && in_section != in_dtors                                                \
       && !recurse                                                      \
       && GET_CODE (VALUE) != CONST_INT                                 \
       && GET_CODE (VALUE) != CONST_DOUBLE                              \
@@ -806,43 +866,13 @@ do {                                                                      \
     }                                                                  \
 } while (0)
 
-/* This is how to output an assembler line defining an address 
-   constant for the dwarf call unwinding information.
-   For -mrelocatable, we mark all addresses that need to be fixed up
-   in the .fixup section.  */
-
-#define        ASM_OUTPUT_DWARF_ADDR(FILE,LABEL)                               \
-do {                                                                   \
-  if (TARGET_RELOCATABLE)                                              \
-    {                                                                  \
-      char buf[256];                                                   \
-                                                                       \
-      ASM_GENERATE_INTERNAL_LABEL (buf, "LCP", fixuplabelno);          \
-      fixuplabelno++;                                                  \
-      ASM_OUTPUT_LABEL (FILE, buf);                                    \
-      fprintf (FILE, "\t.%dbyte\t", POINTER_SIZE / BITS_PER_UNIT);     \
-      assemble_name (FILE, LABEL);                                     \
-      fprintf (FILE, "\n");                                            \
-      fprintf (FILE, "\t.section \".fixup\",\"aw\"\n");                        \
-      ASM_OUTPUT_ALIGN (FILE, 2);                                      \
-      fprintf (FILE, "\t.long\t");                                     \
-      assemble_name (FILE, buf);                                       \
-      fprintf (FILE, "\n\t.previous\n");                               \
-    }                                                                  \
-  else                                                                 \
-    {                                                                  \
-      fprintf (FILE, "\t.%dbyte\t", POINTER_SIZE / BITS_PER_UNIT);     \
-      assemble_name (FILE, LABEL);                                     \
-    }                                                                  \
-} while (0)
-
 /* This is the end of what might become sysv4.h.  */
 
-/* Allow stabs and dwarf, for now, make stabs the default debugging type,
-   not dwarf since G++ doesn't support dwarf.  */
+/* Use DWARF 2 debugging information by default.  */
 #undef PREFERRED_DEBUGGING_TYPE
-#define        PREFERRED_DEBUGGING_TYPE DBX_DEBUG
+#define        PREFERRED_DEBUGGING_TYPE DWARF2_DEBUG
 
+/* Historically we have also supported stabs debugging.  */
 #define        DBX_DEBUGGING_INFO
 
 /* If we are referencing a function that is static or is known to be
@@ -889,103 +919,6 @@ do {                                              \
     asm_fprintf (FILE, "%U%s", _name);         \
 } while (0)
 
-/* Switch into a generic section.
-
-   We make the section read-only and executable for a function decl,
-   read-only for a const data decl, and writable for a non-const data decl.
-
-   If the section has already been defined, we must not
-   emit the attributes here. The SVR4 assembler does not
-   recognize section redefinitions.
-   If DECL is NULL, no attributes are emitted.
-
-   Note, Solaris as doesn't like @nobits, and gas can handle .sbss without
-   needing @nobits.  */
-
-/* Override elfos.h definition.  */
-#undef ASM_OUTPUT_SECTION_NAME
-#define        ASM_OUTPUT_SECTION_NAME(FILE, DECL, NAME, RELOC)                \
-do {                                                                   \
-  static struct section_info                                           \
-    {                                                                  \
-      struct section_info *next;                                       \
-      char *name;                                                      \
-      enum sect_enum {SECT_RW, SECT_RO, SECT_EXEC} type;               \
-    } *sections;                                                       \
-  struct section_info *s;                                              \
-  const char *mode;                                                    \
-  enum sect_enum type;                                                 \
-                                                                       \
-  for (s = sections; s; s = s->next)                                   \
-    if (!strcmp (NAME, s->name))                                       \
-      break;                                                           \
-                                                                       \
-  if (DECL && TREE_CODE (DECL) == FUNCTION_DECL)                       \
-    type = SECT_EXEC, mode = "ax";                                     \
-  else if (DECL && DECL_READONLY_SECTION (DECL, RELOC) && !TARGET_RELOCATABLE && !flag_pic) \
-    type = SECT_RO, mode = "a";                                                \
-  else                                                                 \
-    type = SECT_RW, mode = "aw";                                       \
-                                                                       \
-  if (s == 0)                                                          \
-    {                                                                  \
-      s = (struct section_info *) xmalloc (sizeof (struct section_info));  \
-      s->name = xmalloc ((strlen (NAME) + 1) * sizeof (*NAME));                \
-      strcpy (s->name, NAME);                                          \
-      s->type = type;                                                  \
-      s->next = sections;                                              \
-      sections = s;                                                    \
-      fprintf (FILE, "\t.section\t\"%s\",\"%s\"\n", NAME, mode);       \
-    }                                                                  \
-  else                                                                 \
-    {                                                                  \
-      if (DECL && s->type != type)                                     \
-       error_with_decl (DECL, "%s causes a section type conflict");    \
-                                                                       \
-      fprintf (FILE, "\t.section\t\"%s\"\n", NAME);                    \
-    }                                                                  \
-} while (0)
-
-/* Override elfos.h definition.  */
-#undef ASM_OUTPUT_CONSTRUCTOR
-#define        ASM_OUTPUT_CONSTRUCTOR(FILE,NAME)                               \
-  do {                                                                 \
-    if (DEFAULT_ABI != ABI_SOLARIS)                                    \
-      {                                                                        \
-       ctors_section ();                                               \
-       fprintf (FILE, "\t%s\t ", INT_ASM_OP);                          \
-       assemble_name (FILE, NAME);                                     \
-      }                                                                        \
-    else                                                               \
-      {                                                                        \
-       init_section ();                                                \
-       fputs ("\tbl ", FILE);                                          \
-       assemble_name (FILE, NAME);                                     \
-      }                                                                        \
-    fputs ("\n", FILE);                                                        \
-  } while (0)
-
-/* A C statement (sans semicolon) to output an element in the table of
-   global destructors.  */
-/* Override elfos.h definition.  */
-#undef ASM_OUTPUT_DESTRUCTOR
-#define        ASM_OUTPUT_DESTRUCTOR(FILE,NAME)                                \
-  do {                                                                 \
-    if (DEFAULT_ABI != ABI_SOLARIS)                                    \
-      {                                                                        \
-       dtors_section ();                                               \
-       fprintf (FILE, "\t%s\t ", INT_ASM_OP);                          \
-       assemble_name (FILE, NAME);                                     \
-      }                                                                        \
-    else                                                               \
-      {                                                                        \
-       fini_section ();                                                \
-       fputs ("\tbl ", FILE);                                          \
-       assemble_name (FILE, NAME);                                     \
-      }                                                                        \
-    fputs ("\n", FILE);                                                        \
-  } while (0)
-
 /* But, to make this work, we have to output the stabs for the function
    name *first*...  */
 
@@ -998,7 +931,7 @@ do {                                                                        \
 #define        TARGET_VERSION fprintf (stderr, " (PowerPC System V.4)");
 \f
 #define        CPP_PREDEFINES \
-  "-DPPC -Dunix -D__svr4__ -Asystem(unix) -Asystem(svr4) -Acpu(powerpc) -Amachine(powerpc)"
+  "-DPPC -Dunix -D__svr4__ -Asystem=unix -Asystem=svr4 -Acpu=powerpc -Amachine=powerpc"
 
 /* Pass various options to the assembler.  */
 /* Override svr4.h definition.  */
@@ -1011,13 +944,17 @@ do {                                                                     \
 %{mlittle} %{mlittle-endian} %{mbig} %{mbig-endian} \
 %{!mlittle: %{!mlittle-endian: %{!mbig: %{!mbig-endian: \
     %{mcall-solaris: -mlittle -msolaris} \
-    %{mcall-linux: -mbig} }}}}"
+    %{mcall-i960-old: -mlittle} \
+    %{mcall-linux: -mbig} \
+    %{mcall-netbsd: -mbig} }}}}"
 
 #define        CC1_ENDIAN_BIG_SPEC ""
 
 #define        CC1_ENDIAN_LITTLE_SPEC "\
 %{!mstrict-align: %{!mno-strict-align: \
+    %{!mcall-i960-old: \
        -mstrict-align \
+    } \
 }}"
 
 #define        CC1_ENDIAN_DEFAULT_SPEC "%(cc1_endian_big_spec)"
@@ -1029,10 +966,12 @@ do {                                                                     \
 %{!mlittle: %{!mlittle-endian: %{!mbig: %{!mbig-endian: \
     %{mcall-aixdesc: -mbig %(cc1_endian_big) } \
     %{mcall-solaris: -mlittle %(cc1_endian_little) } \
+    %{mcall-i960-old: -mlittle %(cc1_endian_little) } \
     %{mcall-linux: -mbig %(cc1_endian_big) } \
-    %{!mcall-aixdesc: %{!mcall-solaris: %{!mcall-linux: \
+    %{mcall-netbsd: -mbig %(cc1_endian_big) } \
+    %{!mcall-aixdesc: %{!mcall-solaris: %{!mcall-i960-old: %{!mcall-linux: %{!mcall-netbsd: \
            %(cc1_endian_default) \
-    }}} \
+    }}}}} \
 }}}} \
 %{mcall-solaris: -mregnames } \
 %{mno-sdata: -msdata=none } \
@@ -1040,7 +979,9 @@ do {                                                                       \
 %{!meabi: %{!mno-eabi: \
     %{mrelocatable: -meabi } \
     %{mcall-solaris: -mno-eabi } \
-    %{mcall-linux: -mno-eabi }}} \
+    %{mcall-i960-old: -meabi } \
+    %{mcall-linux: -mno-eabi } \
+    %{mcall-netbsd: -mno-eabi }}} \
 %{msdata: -msdata=default} \
 %{mno-sdata: -msdata=none} \
 %{profile: -p}"
@@ -1069,8 +1010,9 @@ do {                                                                      \
 %{mmvme: %(link_start_mvme) } \
 %{msim: %(link_start_sim) } \
 %{mcall-linux: %(link_start_linux) } \
+%{mcall-netbsd: %(link_start_netbsd) } \
 %{mcall-solaris: %(link_start_solaris) } \
-%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-solaris: %(link_start_default) }}}}}}"
+%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-netbsd: %{!mcall-solaris: %(link_start_default) }}}}}}}"
 
 #define LINK_START_DEFAULT_SPEC ""
 
@@ -1078,7 +1020,7 @@ do {                                                                      \
 #undef LINK_SPEC
 #define        LINK_SPEC "\
 %{h*} %{v:-V} %{G*} \
-%{Wl,*:%*} %{YP,*} %{R*} \
+%{YP,*} %{R*} \
 %{Qy:} %{!Qn:-Qy} \
 %(link_shlib) \
 %{!Wl,-T*: %{!T*: %(link_start) }} \
@@ -1111,9 +1053,10 @@ do {                                                                     \
 
 /* Override the default target of the linker.  */
 #define        LINK_TARGET_SPEC "\
-%{mlittle: -oformat elf32-powerpcle } %{mlittle-endian: -oformat elf32-powerpcle } \
+%{mlittle: --oformat elf32-powerpcle } %{mlittle-endian: --oformat elf32-powerpcle } \
 %{!mlittle: %{!mlittle-endian: %{!mbig: %{!mbig-endian: \
-    %{mcall-solaris: -oformat elf32-powerpcle} \
+    %{mcall-i960-old: --oformat elf32-powerpcle} \
+    %{mcall-solaris: --oformat elf32-powerpcle} \
   }}}}"
 
 /* Any specific OS flags.  */
@@ -1123,8 +1066,9 @@ do {                                                                      \
 %{mmvme: %(link_os_mvme) } \
 %{msim: %(link_os_sim) } \
 %{mcall-linux: %(link_os_linux) } \
+%{mcall-netbsd: %(link_os_netbsd) } \
 %{mcall-solaris: %(link_os_solaris) } \
-%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-solaris: %(link_os_default) }}}}}}"
+%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-netbsd: %{!mcall-solaris: %(link_os_default) }}}}}}}"
 
 #define LINK_OS_DEFAULT_SPEC ""
 
@@ -1132,6 +1076,8 @@ do {                                                                      \
 "%{mrelocatable*: -D_RELOCATABLE} \
 %{fpic: -D__PIC__=1 -D__pic__=1} \
 %{!fpic: %{fPIC: -D__PIC__=2 -D__pic__=2}} \
+%{mlong-double-128: -D__LONG_DOUBLE_128__=1} \
+%{!mlong-double-64: %(cpp_longdouble_default)} \
 %{mcall-sysv: -D_CALL_SYSV} \
 %{mcall-aix: -D_CALL_AIX} %{mcall-aixdesc: -D_CALL_AIX -D_CALL_AIXDESC} \
 %{!mcall-sysv: %{!mcall-aix: %{!mcall-aixdesc: %(cpp_sysv_default) }}} \
@@ -1149,13 +1095,16 @@ do {                                                                    \
 /* Whether floating point is disabled by default.  */
 #define        CPP_FLOAT_DEFAULT_SPEC ""
 
+/* Whether 'long double' is 128 bits by default.  */
+#define        CPP_LONGDOUBLE_DEFAULT_SPEC ""
+
 #define        CPP_SYSV_DEFAULT_SPEC "-D_CALL_SYSV"
 
-#define CPP_ENDIAN_BIG_SPEC "-D_BIG_ENDIAN -D__BIG_ENDIAN__ -Amachine(bigendian)"
+#define CPP_ENDIAN_BIG_SPEC "-D_BIG_ENDIAN -D__BIG_ENDIAN__ -Amachine=bigendian"
 
-#define CPP_ENDIAN_LITTLE_SPEC "-D_LITTLE_ENDIAN -D__LITTLE_ENDIAN__ -Amachine(littleendian)"
+#define CPP_ENDIAN_LITTLE_SPEC "-D_LITTLE_ENDIAN -D__LITTLE_ENDIAN__ -Amachine=littleendian"
 
-#define CPP_ENDIAN_SOLARIS_SPEC "-D__LITTLE_ENDIAN__ -Amachine(littleendian)"
+#define CPP_ENDIAN_SOLARIS_SPEC "-D__LITTLE_ENDIAN__ -Amachine=littleendian"
 
 /* For solaris, don't define _LITTLE_ENDIAN, it conflicts with a header file.  */
 #define        CPP_ENDIAN_SPEC \
@@ -1166,8 +1115,10 @@ do {                                                                     \
 %{!mlittle: %{!mlittle-endian: %{!mbig: %{!mbig-endian: \
     %{mcall-solaris: %(cpp_endian_solaris) } \
     %{mcall-linux: %(cpp_endian_big) } \
+    %{mcall-netbsd: %(cpp_endian_big) } \
+    %{mcall-i960-old: %(cpp_endian_little) } \
     %{mcall-aixdesc:  %(cpp_endian_big) } \
-    %{!mcall-solaris: %{!mcall-linux: %{!mcall-aixdesc: %(cpp_endian_default) }}}}}}}"
+    %{!mcall-solaris: %{!mcall-linux: %{!mcall-netbsd: %{!mcall-aixdesc: %(cpp_endian_default) }}}}}}}}"
 
 #define        CPP_ENDIAN_DEFAULT_SPEC "%(cpp_endian_big)"
 
@@ -1179,8 +1130,9 @@ do {                                                                      \
 %{mmvme: %(cpp_os_mvme) } \
 %{msim: %(cpp_os_sim) } \
 %{mcall-linux: %(cpp_os_linux) } \
+%{mcall-netbsd: %(cpp_os_netbsd) } \
 %{mcall-solaris: %(cpp_os_solaris) } \
-%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-solaris: %(cpp_os_default) }}}}}}"
+%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-netbsd: %{!mcall-solaris: %(cpp_os_default) }}}}}}}"
 
 #define        CPP_OS_DEFAULT_SPEC ""
 
@@ -1192,8 +1144,9 @@ do {                                                                      \
 %{mmvme: %(startfile_mvme) } \
 %{msim: %(startfile_sim) } \
 %{mcall-linux: %(startfile_linux) } \
+%{mcall-netbsd: %(startfile_netbsd) } \
 %{mcall-solaris: %(startfile_solaris) } \
-%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-solaris: %(startfile_default) }}}}}}"
+%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-netbsd: %{!mcall-solaris: %(startfile_default) }}}}}}}"
 
 #define        STARTFILE_DEFAULT_SPEC ""
 
@@ -1205,12 +1158,9 @@ do {                                                                     \
 %{mmvme: %(lib_mvme) } \
 %{msim: %(lib_sim) } \
 %{mcall-linux: %(lib_linux) } \
+%{mcall-netbsd: %(lib_netbsd) } \
 %{mcall-solaris: %(lib_solaris) } \
-%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-solaris: %(lib_default) }}}}}}"
-
-/* Override rs6000.h definition.  */
-#undef LIBGCC_SPEC
-#define        LIBGCC_SPEC "libgcc.a%s"
+%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-netbsd: %{!mcall-solaris: %(lib_default) }}}}}}}"
 
 #define LIB_DEFAULT_SPEC ""
 
@@ -1222,9 +1172,10 @@ do {                                                                     \
 %{mmvme: %(endfile_mvme)} \
 %{msim: %(endfile_sim)} \
 %{mcall-linux: %(endfile_linux) } \
+%{mcall-netbsd: %(endfile_netbsd) } \
 %{mcall-solaris: %(endfile_solaris)} \
 %{mvxworks: %(endfile_vxworks) } \
-%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-solaris: %{!mvxworks: %(endfile_default) }}}}}}}"
+%{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mcall-linux: %{!mcall-netbsd: %{!mcall-solaris: %{!mvxworks: %(endfile_default) }}}}}}}}"
 
 #define        ENDFILE_DEFAULT_SPEC ""
 
@@ -1310,16 +1261,39 @@ do {                                                                    \
   %{!ansi:                                                     \
     %{!std=*:-Dunix -D__unix -Dlinux -D__linux}                        \
     %{std=gnu*:-Dunix -D__unix -Dlinux -D__linux}}}            \
--Asystem(unix) -Asystem(posix)"
+-Asystem=unix -Asystem=posix"
 #else
 #define CPP_OS_LINUX_SPEC "-D__unix__ -D__linux__              \
 %{!undef:                                                      \
   %{!ansi:                                                     \
     %{!std=*:-Dunix -D__unix -Dlinux -D__linux}                        \
     %{std=gnu*:-Dunix -D__unix -Dlinux -D__linux}}}            \
--Asystem(unix) -Asystem(posix) %{pthread:-D_REENTRANT}"
+-Asystem=unix -Asystem=posix %{pthread:-D_REENTRANT}"
 #endif
 
+/* NetBSD support.  */
+#define LIB_NETBSD_SPEC "\
+%{profile:-lgmon -lc_p} %{!profile:-lc}"
+
+#define        STARTFILE_NETBSD_SPEC "\
+ncrti.o%s crt0.o%s \
+%{!shared:crtbegin.o%s} %{shared:crtbeginS.o%s}"
+
+#define ENDFILE_NETBSD_SPEC "\
+%{!shared:crtend.o%s} %{shared:crtendS.o%s} \
+ncrtn.o%s"
+
+#define LINK_START_NETBSD_SPEC "\
+"
+
+#define LINK_OS_NETBSD_SPEC "\
+%{!shared: %{!static: \
+  %{rdynamic:-export-dynamic} \
+  %{!dynamic-linker:-dynamic-linker /usr/libexec/ld.elf_so}}}"
+
+#define CPP_OS_NETBSD_SPEC "\
+-D__powerpc__ -D__NetBSD__ -D__ELF__ -D__KPRINTF_ATTRIBUTE__"
+
 /* Solaris support.  */
 /* For Solaris, Gcc automatically adds in one of the files
    /usr/ccs/lib/values-Xc.o, /usr/ccs/lib/values-Xa.o, or
@@ -1360,7 +1334,7 @@ do {                                                                      \
 #define CPP_OS_SOLARIS_SPEC "-D__ppc -D__sun__=1 -D__unix__ -D__svr4__  -D__SVR4__ \
 %{!undef:%{!ansi:%{!std=*:-Dsun=1 -Dunix -DSVR4 -D__EXTENSIONS__} \
                %{std=gnu*:-Dsun=1 -Dunix -DSVR4 -D__EXTENSIONS__}}} \
--Amachine(prep)"
+-Amachine=prep"
 
 /* VxWorks support.  */
 /* VxWorks does all the library stuff itself.  */
@@ -1415,6 +1389,7 @@ do {                                                                      \
   { "lib_mvme",                        LIB_MVME_SPEC },                        \
   { "lib_sim",                 LIB_SIM_SPEC },                         \
   { "lib_linux",               LIB_LINUX_SPEC },                       \
+  { "lib_netbsd",              LIB_NETBSD_SPEC },                      \
   { "lib_solaris",             LIB_SOLARIS_SPEC },                     \
   { "lib_vxworks",             LIB_VXWORKS_SPEC },                     \
   { "lib_default",             LIB_DEFAULT_SPEC },                     \
@@ -1423,6 +1398,7 @@ do {                                                                      \
   { "startfile_mvme",          STARTFILE_MVME_SPEC },                  \
   { "startfile_sim",           STARTFILE_SIM_SPEC },                   \
   { "startfile_linux",         STARTFILE_LINUX_SPEC },                 \
+  { "startfile_netbsd",                STARTFILE_NETBSD_SPEC },                \
   { "startfile_solaris",       STARTFILE_SOLARIS_SPEC },               \
   { "startfile_vxworks",       STARTFILE_VXWORKS_SPEC },               \
   { "startfile_default",       STARTFILE_DEFAULT_SPEC },               \
@@ -1431,6 +1407,7 @@ do {                                                                      \
   { "endfile_mvme",            ENDFILE_MVME_SPEC },                    \
   { "endfile_sim",             ENDFILE_SIM_SPEC },                     \
   { "endfile_linux",           ENDFILE_LINUX_SPEC },                   \
+  { "endfile_netbsd",          ENDFILE_NETBSD_SPEC },                  \
   { "endfile_solaris",         ENDFILE_SOLARIS_SPEC },                 \
   { "endfile_vxworks",         ENDFILE_VXWORKS_SPEC },                 \
   { "endfile_default",         ENDFILE_DEFAULT_SPEC },                 \
@@ -1443,6 +1420,7 @@ do {                                                                      \
   { "link_start_mvme",         LINK_START_MVME_SPEC },                 \
   { "link_start_sim",          LINK_START_SIM_SPEC },                  \
   { "link_start_linux",                LINK_START_LINUX_SPEC },                \
+  { "link_start_netbsd",       LINK_START_NETBSD_SPEC },               \
   { "link_start_solaris",      LINK_START_SOLARIS_SPEC },              \
   { "link_start_vxworks",      LINK_START_VXWORKS_SPEC },              \
   { "link_start_default",      LINK_START_DEFAULT_SPEC },              \
@@ -1452,6 +1430,7 @@ do {                                                                      \
   { "link_os_mvme",            LINK_OS_MVME_SPEC },                    \
   { "link_os_sim",             LINK_OS_SIM_SPEC },                     \
   { "link_os_linux",           LINK_OS_LINUX_SPEC },                   \
+  { "link_os_netbsd",          LINK_OS_NETBSD_SPEC },                  \
   { "link_os_solaris",         LINK_OS_SOLARIS_SPEC },                 \
   { "link_os_vxworks",         LINK_OS_VXWORKS_SPEC },                 \
   { "link_os_default",         LINK_OS_DEFAULT_SPEC },                 \
@@ -1462,11 +1441,13 @@ do {                                                                    \
   { "cpp_endian_little",       CPP_ENDIAN_LITTLE_SPEC },               \
   { "cpp_endian_solaris",      CPP_ENDIAN_SOLARIS_SPEC },              \
   { "cpp_float_default",       CPP_FLOAT_DEFAULT_SPEC },               \
+  { "cpp_longdouble_default",  CPP_LONGDOUBLE_DEFAULT_SPEC },          \
   { "cpp_os_ads",              CPP_OS_ADS_SPEC },                      \
   { "cpp_os_yellowknife",      CPP_OS_YELLOWKNIFE_SPEC },              \
   { "cpp_os_mvme",             CPP_OS_MVME_SPEC },                     \
   { "cpp_os_sim",              CPP_OS_SIM_SPEC },                      \
   { "cpp_os_linux",            CPP_OS_LINUX_SPEC },                    \
+  { "cpp_os_netbsd",           CPP_OS_NETBSD_SPEC },                   \
   { "cpp_os_solaris",          CPP_OS_SOLARIS_SPEC },                  \
   { "cpp_os_vxworks",          CPP_OS_VXWORKS_SPEC },                  \
   { "cpp_os_default",          CPP_OS_DEFAULT_SPEC },
@@ -1489,3 +1470,83 @@ do {                                                                     \
 
 /* Function name to call to do profiling.  */
 #define RS6000_MCOUNT "_mcount"
+
+/* Define this macro (to a value of 1) if you want to support the
+   Win32 style pragmas #pragma pack(push,<n>)' and #pragma
+   pack(pop)'.  The pack(push,<n>) pragma specifies the maximum
+   alignment (in bytes) of fields within a structure, in much the
+   same way as the __aligned__' and __packed__' __attribute__'s
+   do.  A pack value of zero resets the behaviour to the default.
+   Successive invocations of this pragma cause the previous values to
+   be stacked, so that invocations of #pragma pack(pop)' will return
+   to the previous value.  */
+
+#define HANDLE_PRAGMA_PACK_PUSH_POP 1
+
+/* Define library calls for quad FP operations.  These are all part of the
+   PowerPC 32bit ABI.  */
+#define ADDTF3_LIBCALL "_q_add"
+#define DIVTF3_LIBCALL "_q_div"
+#define EXTENDDFTF2_LIBCALL "_q_dtoq"
+#define EQTF2_LIBCALL "_q_feq"
+#define GETF2_LIBCALL "_q_fge"
+#define GTTF2_LIBCALL "_q_fgt"
+#define LETF2_LIBCALL "_q_fle"
+#define LTTF2_LIBCALL "_q_flt"
+#define NETF2_LIBCALL "_q_fne"
+#define FLOATSITF2_LIBCALL "_q_itoq"
+#define MULTF3_LIBCALL "_q_mul"
+#define NEGTF2_LIBCALL "_q_neg"
+#define TRUNCTFDF2_LIBCALL "_q_qtod"
+#define FIX_TRUNCTFSI2_LIBCALL "_q_qtoi"
+#define TRUNCTFSF2_LIBCALL "_q_qtos"
+#define FIXUNS_TRUNCTFSI2_LIBCALL "_q_qtou"
+#define SQRTTF_LIBCALL "_q_sqrt"
+#define EXTENDSFTF2_LIBCALL "_q_stoq"
+#define SUBTF3_LIBCALL "_q_sub"
+#define FLOATUNSSITF2_LIBCALL "_q_utoq"
+
+#define INIT_TARGET_OPTABS                                             \
+  do {                                                                 \
+    if (TARGET_HARD_FLOAT)                                             \
+      {                                                                        \
+       add_optab->handlers[(int) TFmode].libfunc                       \
+         = init_one_libfunc (ADDTF3_LIBCALL);                          \
+       sub_optab->handlers[(int) TFmode].libfunc                       \
+         = init_one_libfunc (SUBTF3_LIBCALL);                          \
+       neg_optab->handlers[(int) TFmode].libfunc                       \
+         = init_one_libfunc (NEGTF2_LIBCALL);                          \
+       smul_optab->handlers[(int) TFmode].libfunc                      \
+         = init_one_libfunc (MULTF3_LIBCALL);                          \
+       sdiv_optab->handlers[(int) TFmode].libfunc                      \
+         = init_one_libfunc (DIVTF3_LIBCALL);                          \
+       eqtf2_libfunc = init_one_libfunc (EQTF2_LIBCALL);               \
+       netf2_libfunc = init_one_libfunc (NETF2_LIBCALL);               \
+       gttf2_libfunc = init_one_libfunc (GTTF2_LIBCALL);               \
+       getf2_libfunc = init_one_libfunc (GETF2_LIBCALL);               \
+       lttf2_libfunc = init_one_libfunc (LTTF2_LIBCALL);               \
+       letf2_libfunc = init_one_libfunc (LETF2_LIBCALL);               \
+       trunctfsf2_libfunc = init_one_libfunc (TRUNCTFSF2_LIBCALL);     \
+       trunctfdf2_libfunc = init_one_libfunc (TRUNCTFDF2_LIBCALL);     \
+       extendsftf2_libfunc = init_one_libfunc (EXTENDSFTF2_LIBCALL);   \
+       extenddftf2_libfunc = init_one_libfunc (EXTENDDFTF2_LIBCALL);   \
+       floatsitf_libfunc = init_one_libfunc (FLOATSITF2_LIBCALL);      \
+       fixtfsi_libfunc = init_one_libfunc (FIX_TRUNCTFSI2_LIBCALL);    \
+       fixunstfsi_libfunc                                              \
+         = init_one_libfunc (FIXUNS_TRUNCTFSI2_LIBCALL);               \
+       if (TARGET_PPC_GPOPT || TARGET_POWER2)                          \
+         sqrt_optab->handlers[(int) TFmode].libfunc                    \
+           = init_one_libfunc (SQRTTF_LIBCALL);                        \
+      }                                                                        \
+  } while (0)
+
+/* Select a format to encode pointers in exception handling data.  CODE
+   is 0 for data, 1 for code labels, 2 for function pointers.  GLOBAL is
+   true if the symbol may be affected by dynamic relocations.  */
+#define ASM_PREFERRED_EH_DATA_FORMAT(CODE,GLOBAL)                           \
+  ((flag_pic || TARGET_RELOCATABLE)                                         \
+   ? (((GLOBAL) ? DW_EH_PE_indirect : 0) | DW_EH_PE_pcrel | DW_EH_PE_sdata4) \
+   : DW_EH_PE_absptr)
+
+#define EXCEPTION_SECTION readonly_data_section
+#define DOUBLE_INT_ASM_OP "\t.quad\t"