]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
pdp11.h (FUNCTION_ARG, [...]): Delete.
authorNathan Froyd <froydnj@codesourcery.com>
Sat, 9 Oct 2010 21:13:29 +0000 (21:13 +0000)
committerNathan Froyd <froydnj@gcc.gnu.org>
Sat, 9 Oct 2010 21:13:29 +0000 (21:13 +0000)
* config/pdp11/pdp11.h (FUNCTION_ARG, FUNCTION_ARG_ADVANCE): Delete.
* config/pdp11/pdp11.c (pdp11_function_arg): New function.
(pdp11_function_arg_advance): New function.
(TARGET_FUNCTION_ARG, TARGET_FUNCTION_ARG_ADVANCE): Define.

From-SVN: r165239

gcc/ChangeLog
gcc/config/pdp11/pdp11.c
gcc/config/pdp11/pdp11.h

index 08acd5091f712ae879e01aee59116d79f7069102..7cbf9d05a27dcea03c6e44dbcfda5e5aa2e5d015 100644 (file)
@@ -1,3 +1,10 @@
+2010-10-09  Nathan Froyd  <froydnj@codesourcery.com>
+
+       * config/pdp11/pdp11.h (FUNCTION_ARG, FUNCTION_ARG_ADVANCE): Delete.
+       * config/pdp11/pdp11.c (pdp11_function_arg): New function.
+       (pdp11_function_arg_advance): New function.
+       (TARGET_FUNCTION_ARG, TARGET_FUNCTION_ARG_ADVANCE): Define.
+
 2010-10-09  Nathan Froyd  <froydnj@codesourcery.com>
 
        * libgcc2.h: Use __SIZEOF_LONG_LONG__ instead of LONG_LONG_TYPE_SIZE.
index 2812e9509b1fbeb6e21983985bc5d1a333c57bca..651b0cc6012382ebf3804b0897b0acdf194a3771 100644 (file)
@@ -157,6 +157,10 @@ static rtx pdp11_function_value (const_tree, const_tree, bool);
 static rtx pdp11_libcall_value (enum machine_mode, const_rtx);
 static bool pdp11_function_value_regno_p (const unsigned int);
 static void pdp11_trampoline_init (rtx, tree, rtx);
+static rtx pdp11_function_arg (CUMULATIVE_ARGS *, enum machine_mode,
+                              const_tree, bool);
+static void pdp11_function_arg_advance (CUMULATIVE_ARGS *,
+                                       enum machine_mode, const_tree, bool);
 \f
 /* Initialize the GCC target structure.  */
 #undef TARGET_ASM_BYTE_OP
@@ -189,6 +193,11 @@ static void pdp11_trampoline_init (rtx, tree, rtx);
 #undef TARGET_RTX_COSTS
 #define TARGET_RTX_COSTS pdp11_rtx_costs
 
+#undef TARGET_FUNCTION_ARG
+#define TARGET_FUNCTION_ARG pdp11_function_arg
+#undef TARGET_FUNCTION_ARG_ADVANCE
+#define TARGET_FUNCTION_ARG_ADVANCE pdp11_function_arg_advance
+
 #undef TARGET_RETURN_IN_MEMORY
 #define TARGET_RETURN_IN_MEMORY pdp11_return_in_memory
 
@@ -1834,3 +1843,42 @@ pdp11_trampoline_init (rtx m_tramp, tree fndecl, rtx chain_value)
   emit_move_insn (mem, GEN_INT (0x0058));
   emit_move_insn (mem, fnaddr);
 }
+
+/* Worker function for TARGET_FUNCTION_ARG.
+
+   Determine where to put an argument to a function.
+   Value is zero to push the argument on the stack,
+   or a hard register in which to store the argument.
+
+   MODE is the argument's machine mode.
+   TYPE is the data type of the argument (as a tree).
+    This is null for libcalls where that information may
+    not be available.
+   CUM is a variable of type CUMULATIVE_ARGS which gives info about
+    the preceding args and about the function being called.
+   NAMED is nonzero if this argument is a named parameter
+    (otherwise it is an extra parameter matching an ellipsis).  */
+
+static rtx
+pdp11_function_arg (CUMULATIVE_ARGS *cum ATTRIBUTE_UNUSED,
+                   enum machine_mode mode ATTRIBUTE_UNUSED,
+                   const_tree type ATTRIBUTE_UNUSED,
+                   bool named ATTRIBUTE_UNUSED)
+{
+  return NULL_RTX;
+}
+
+/* Worker function for TARGET_FUNCTION_ARG_ADVANCE.
+
+   Update the data in CUM to advance over an argument of mode MODE and
+   data type TYPE.  (TYPE is null for libcalls where that information
+   may not be available.)  */
+
+static void
+pdp11_function_arg_advance (CUMULATIVE_ARGS *cum, enum machine_mode mode,
+                           const_tree type, bool named ATTRIBUTE_UNUSED)
+{
+  *cum += (mode != BLKmode
+          ? GET_MODE_SIZE (mode)
+          : int_size_in_bytes (type));
+}
index a1a96a17677293abf56b20087c002ff03dab00b8..2904acd960865b152a61e3d268c99c19904ee004 100644 (file)
@@ -468,40 +468,6 @@ extern int current_first_parm_offset;
 #define INIT_CUMULATIVE_ARGS(CUM, FNTYPE, LIBNAME, INDIRECT, N_NAMED_ARGS) \
  ((CUM) = 0)
 
-/* Update the data in CUM to advance over an argument
-   of mode MODE and data type TYPE.
-   (TYPE is null for libcalls where that information may not be available.)  
-
-*/
-
-
-#define FUNCTION_ARG_ADVANCE(CUM, MODE, TYPE, NAMED)   \
- ((CUM) += ((MODE) != BLKmode                  \
-           ? (GET_MODE_SIZE (MODE))            \
-           : (int_size_in_bytes (TYPE))))      
-
-/* Determine where to put an argument to a function.
-   Value is zero to push the argument on the stack,
-   or a hard register in which to store the argument.
-
-   MODE is the argument's machine mode.
-   TYPE is the data type of the argument (as a tree).
-    This is null for libcalls where that information may
-    not be available.
-   CUM is a variable of type CUMULATIVE_ARGS which gives info about
-    the preceding args and about the function being called.
-   NAMED is nonzero if this argument is a named parameter
-    (otherwise it is an extra parameter matching an ellipsis).  */
-
-#define FUNCTION_ARG(CUM, MODE, TYPE, NAMED)  0
-
-/* Define where a function finds its arguments.
-   This would be different from FUNCTION_ARG if we had register windows.  */
-/*
-#define FUNCTION_INCOMING_ARG(CUM, MODE, TYPE, NAMED)  \
-  FUNCTION_ARG (CUM, MODE, TYPE, NAMED)
-*/
-
 /* Output assembler code to FILE to increment profiler label # LABELNO
    for profiling a function entry.  */