rtx
lm32_function_arg (CUMULATIVE_ARGS cum, enum machine_mode mode,
                   tree type, int named)
{
    if (mode == VOIDmode)
        /* Compute operand 2 of the call insn.  */
        return GEN_INT (0);

    if (targetm.calls.must_pass_in_stack (mode, type))
        return NULL_RTX;

    if (!named  || (cum + LM32_NUM_REGS2(mode, type) > LM32_NUM_ARG_REGS))
        return NULL_RTX;

    return gen_rtx_REG (mode, cum + LM32_FIRST_ARG_REG);
}
Exemple #2
0
static rtx
lm32_function_arg (cumulative_args_t cum_v, machine_mode mode,
		   const_tree type, bool named)
{
  CUMULATIVE_ARGS *cum = get_cumulative_args (cum_v);

  if (mode == VOIDmode)
    /* Compute operand 2 of the call insn.  */
    return GEN_INT (0);

  if (targetm.calls.must_pass_in_stack (mode, type))
    return NULL_RTX;

  if (!named || (*cum + LM32_NUM_REGS2 (mode, type) > LM32_NUM_ARG_REGS))
    return NULL_RTX;

  return gen_rtx_REG (mode, *cum + LM32_FIRST_ARG_REG);
}
Exemple #3
0
static void
lm32_function_arg_advance (cumulative_args_t cum, machine_mode mode,
			   const_tree type, bool named ATTRIBUTE_UNUSED)
{
  *get_cumulative_args (cum) += LM32_NUM_REGS2 (mode, type);
}