Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/gnu/dist/toolchain/gcc/config/m68k Revert the last change fo...



details:   https://anonhg.NetBSD.org/src/rev/17c5b88cb41f
branches:  trunk
changeset: 519556:17c5b88cb41f
user:      scw <scw%NetBSD.org@localhost>
date:      Thu Dec 20 18:14:35 2001 +0000

description:
Revert the last change following yesterday's commit to ../netbsd.h
(Hi Jason!)

diffstat:

 gnu/dist/toolchain/gcc/config/m68k/netbsd-elf.h |  88 +++++++++++++++++++++++++
 1 files changed, 88 insertions(+), 0 deletions(-)

diffs (98 lines):

diff -r c01440b692bd -r 17c5b88cb41f gnu/dist/toolchain/gcc/config/m68k/netbsd-elf.h
--- a/gnu/dist/toolchain/gcc/config/m68k/netbsd-elf.h   Thu Dec 20 17:45:31 2001 +0000
+++ b/gnu/dist/toolchain/gcc/config/m68k/netbsd-elf.h   Thu Dec 20 18:14:35 2001 +0000
@@ -264,6 +264,94 @@
     fprintf (FILE, "\n");                                              \
   } while (0)
 
+/* These macros generate the special .type and .size directives which
+   are used to set the corresponding fields of the linker symbol table
+   entries in an ELF object file under SVR4.  These macros also output
+   the starting labels for the relevant functions/objects.  */
+
+/* Write the extra assembler code needed to declare a function properly.
+   Some svr4 assemblers need to also have something extra said about the
+   function's return value.  We allow for that here.  */
+
+#define ASM_DECLARE_FUNCTION_NAME(FILE, NAME, DECL)                    \
+  do {                                                                 \
+    fprintf (FILE, "\t%s\t", TYPE_ASM_OP);                             \
+    assemble_name (FILE, NAME);                                                \
+    putc (',', FILE);                                                  \
+    fprintf (FILE, TYPE_OPERAND_FMT, "function");                      \
+    putc ('\n', FILE);                                                 \
+    ASM_DECLARE_RESULT (FILE, DECL_RESULT (DECL));                     \
+    ASM_OUTPUT_LABEL(FILE, NAME);                                      \
+  } while (0)
+
+/* Write the extra assembler code needed to declare an object properly.  */
+
+#define ASM_DECLARE_OBJECT_NAME(FILE, NAME, DECL)                      \
+  do {                                                                 \
+    fprintf (FILE, "\t%s\t", TYPE_ASM_OP);                             \
+    assemble_name (FILE, NAME);                                                \
+    putc (',', FILE);                                                  \
+    fprintf (FILE, TYPE_OPERAND_FMT, "object");                                \
+    putc ('\n', FILE);                                                 \
+    size_directive_output = 0;                                         \
+    if (!flag_inhibit_size_directive && DECL_SIZE (DECL))              \
+      {                                                                        \
+       size_directive_output = 1;                                      \
+       fprintf (FILE, "\t%s\t", SIZE_ASM_OP);                          \
+       assemble_name (FILE, NAME);                                     \
+       putc (',', FILE);                                               \
+       fprintf (FILE, HOST_WIDE_INT_PRINT_DEC,                         \
+                int_size_in_bytes (TREE_TYPE (DECL)));                 \
+       fputc ('\n', FILE);                                             \
+      }                                                                        \
+    ASM_OUTPUT_LABEL(FILE, NAME);                                      \
+  } while (0)
+
+/* Output the size directive for a decl in rest_of_decl_compilation
+   in the case where we did not do so before the initializer.
+   Once we find the error_mark_node, we know that the value of
+   size_directive_output was set
+   by ASM_DECLARE_OBJECT_NAME when it was run for the same decl.  */
+
+#define ASM_FINISH_DECLARE_OBJECT(FILE, DECL, TOP_LEVEL, AT_END)        \
+do {                                                                    \
+     char *name = XSTR (XEXP (DECL_RTL (DECL), 0), 0);                  \
+     if (!flag_inhibit_size_directive && DECL_SIZE (DECL)               \
+         && ! AT_END && TOP_LEVEL                                       \
+        && DECL_INITIAL (DECL) == error_mark_node                       \
+        && !size_directive_output)                                      \
+       {                                                                \
+        size_directive_output = 1;                                      \
+        fprintf (FILE, "\t%s\t", SIZE_ASM_OP);                  \
+        assemble_name (FILE, name);                                     \
+        putc (',', FILE);                                               \
+        fprintf (FILE, HOST_WIDE_INT_PRINT_DEC,                         \
+                 int_size_in_bytes (TREE_TYPE (DECL)));                 \
+       fputc ('\n', FILE);                                              \
+       }                                                                \
+   } while (0)
+
+/* This is how to declare the size of a function.  */
+
+#define ASM_DECLARE_FUNCTION_SIZE(FILE, FNAME, DECL)                   \
+  do {                                                                 \
+    if (!flag_inhibit_size_directive)                                  \
+      {                                                                        \
+        char label[256];                                               \
+       static int labelno;                                             \
+       labelno++;                                                      \
+       ASM_GENERATE_INTERNAL_LABEL (label, "Lfe", labelno);            \
+       ASM_OUTPUT_INTERNAL_LABEL (FILE, "Lfe", labelno);               \
+       fprintf (FILE, "\t%s\t", SIZE_ASM_OP);                          \
+       assemble_name (FILE, (FNAME));                                  \
+        fprintf (FILE, ",");                                           \
+       assemble_name (FILE, label);                                    \
+        fprintf (FILE, "-");                                           \
+       assemble_name (FILE, (FNAME));                                  \
+       putc ('\n', FILE);                                              \
+      }                                                                        \
+  } while (0)
+
 /* This is how we tell the assembler that two symbols have the same value.  */
 
 #define ASM_OUTPUT_DEF(FILE,NAME1,NAME2) \



Home | Main Index | Thread Index | Old Index