char contains_reg_of_mode [N_REG_CLASSES] [MAX_MACHINE_MODE];
/* Maximum cost of moving from a register in one class to a register in
- another class. Based on REGISTER_MOVE_COST. */
+ another class. Based on TARGET_REGISTER_MOVE_COST. */
move_table *move_cost[MAX_MACHINE_MODE];
/* Similar, but here we don't have to move if the first index is a subset
cost = 65535;
else
{
- cost = REGISTER_MOVE_COST (m, (enum reg_class) i,
+ cost = register_move_cost (m, (enum reg_class) i,
(enum reg_class) j);
gcc_assert (cost < 65535);
}
top_of_stack[i] = gen_rtx_MEM ((enum machine_mode) i, stack_pointer_rtx);
}
+
+/* Compute cost of moving data from a register of class FROM to one of
+ TO, using MODE. */
+
+int
+register_move_cost (enum machine_mode mode, enum reg_class from,
+ enum reg_class to)
+{
+ return targetm.register_move_cost (mode, from, to);
+}
+
/* Compute cost of moving registers to/from memory. */
int
memory_move_cost (enum machine_mode mode, enum reg_class rclass, bool in)
return 0;
if (in)
- partial_cost = REGISTER_MOVE_COST (mode, altclass, rclass);
+ partial_cost = register_move_cost (mode, altclass, rclass);
else
- partial_cost = REGISTER_MOVE_COST (mode, rclass, altclass);
+ partial_cost = register_move_cost (mode, rclass, altclass);
if (rclass == altclass)
/* This isn't simply a copy-to-temporary situation. Can't guess