From a2ef6e41d2c7f6ed0096983ca7c0cd1d74faad16 Mon Sep 17 00:00:00 2001 From: Richard Kenner Date: Sun, 13 Aug 1995 21:34:08 -0400 Subject: (INITIAL_ELIMINATION_OFFSET): For 64 bit ABI... (INITIAL_ELIMINATION_OFFSET): For 64 bit ABI, subtract current_function_pretend_args_size when converting from argument pointer. From-SVN: r10229 --- gcc/config/mips/mips.h | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'gcc/config') diff --git a/gcc/config/mips/mips.h b/gcc/config/mips/mips.h index 7d6fe47..e1bf692 100644 --- a/gcc/config/mips/mips.h +++ b/gcc/config/mips/mips.h @@ -1751,15 +1751,17 @@ extern struct mips_frame_info current_frame_info; { compute_frame_size (get_frame_size ()); \ if ((FROM) == FRAME_POINTER_REGNUM && (TO) == STACK_POINTER_REGNUM) \ (OFFSET) = 0; \ - else if ((FROM) == ARG_POINTER_REGNUM && (TO) == FRAME_POINTER_REGNUM) \ - (OFFSET) = current_frame_info.total_size; \ - else if ((FROM) == ARG_POINTER_REGNUM && (TO) == STACK_POINTER_REGNUM) \ - (OFFSET) = current_frame_info.total_size; \ + else if ((FROM) == ARG_POINTER_REGNUM \ + && ((TO) == FRAME_POINTER_REGNUM \ + || (TO) == STACK_POINTER_REGNUM)) \ + (OFFSET) = (current_frame_info.total_size \ + - (ABI_64BIT && mips_isa >= 3 \ + ? current_function_pretend_args_size \ + : 0)); \ else \ abort (); \ } - /* If we generate an insn to push BYTES bytes, this says how many the stack pointer really advances by. On the vax, sp@- in a byte insn really pushes a word. */ -- cgit v1.1