#include "config.h"
#include "system.h"
+#include "coretypes.h"
+#include "tm.h"
#include "rtl.h"
#include "regs.h"
#include "hard-reg-set.h"
static void mmix_target_asm_function_epilogue
PARAMS ((FILE *, HOST_WIDE_INT));
static void mmix_asm_output_mi_thunk
- PARAMS ((FILE *, tree, HOST_WIDE_INT, tree));
+ PARAMS ((FILE *, tree, HOST_WIDE_INT, HOST_WIDE_INT, tree));
+static bool mmix_rtx_costs
+ PARAMS ((rtx, int, int, int *));
/* Target structure macros. Listed by node. See `Using and Porting GCC'
#undef TARGET_ASM_OUTPUT_MI_THUNK
#define TARGET_ASM_OUTPUT_MI_THUNK mmix_asm_output_mi_thunk
+#undef TARGET_ASM_CAN_OUTPUT_MI_THUNK
+#define TARGET_ASM_CAN_OUTPUT_MI_THUNK default_can_output_mi_thunk_no_vcall
+
+#undef TARGET_RTX_COSTS
+#define TARGET_RTX_COSTS mmix_rtx_costs
+#undef TARGET_ADDRESS_COST
+#define TARGET_ADDRESS_COST hook_int_rtx_0
struct gcc_target targetm = TARGET_INITIALIZER;
return gen_rtx_PARALLEL (VOIDmode, gen_rtvec_v (nregs, vec));
}
+/* FUNCTION_VALUE_REGNO_P. */
+
+int
+mmix_function_value_regno_p (regno)
+ int regno;
+{
+ return regno == MMIX_RETURN_VALUE_REGNUM;
+}
+
/* EH_RETURN_DATA_REGNO. */
int
/* TARGET_ASM_OUTPUT_MI_THUNK. */
static void
-mmix_asm_output_mi_thunk (stream, fndecl, delta, func)
+mmix_asm_output_mi_thunk (stream, fndecl, delta, vcall_offset, func)
FILE * stream;
tree fndecl ATTRIBUTE_UNUSED;
HOST_WIDE_INT delta;
+ HOST_WIDE_INT vcall_offset ATTRIBUTE_UNUSED;
tree func;
{
/* If you define STRUCT_VALUE to 0, rather than use STRUCT_VALUE_REGNUM,
return mode != CC_FPmode;
}
-/* DEFAULT_RTX_COSTS. */
+/* TARGET_RTX_COSTS. */
-int
-mmix_rtx_cost_recalculated (x, code, outer_code, costp)
+static bool
+mmix_rtx_costs (x, code, outer_code, total)
rtx x ATTRIBUTE_UNUSED;
- RTX_CODE code ATTRIBUTE_UNUSED;
- RTX_CODE outer_code ATTRIBUTE_UNUSED;
- int *costp ATTRIBUTE_UNUSED;
+ int code ATTRIBUTE_UNUSED;
+ int outer_code ATTRIBUTE_UNUSED;
+ int *total ATTRIBUTE_UNUSED;
{
/* For the time being, this is just a stub and we'll accept the
generic calculations, until we can do measurements, at least.
Say we did not modify any calculated costs. */
- return 0;
-}
-
-/* ADDRESS_COST. */
-
-int
-mmix_address_cost (addr)
- rtx addr ATTRIBUTE_UNUSED;
-{
- /* There's no difference in the address costs and we have lots of
- registers. Some targets use constant 0, many others use 1 to say
- this. Let's start with 1. */
- return 1;
+ return false;
}
/* REGISTER_MOVE_COST. */
name);
}
-/* ASM_OUTPUT_INTERNAL_LABEL. */
-
-void
-mmix_asm_output_internal_label (stream, name, num)
- FILE * stream;
- const char * name;
- int num;
-{
- fprintf (stream, "%s:%d\tIS @\n", name, num);
-}
-
/* ASM_OUTPUT_DEF. */
void