This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
PATCH: h8300-elf fix for gcc.c-torture/execute/20020307-2.c
- From: "Nitin Gupta, Noida" <niting at noida dot hcltech dot com>
- To: gcc at gcc dot gnu dot org
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Thu, 17 Oct 2002 16:38:52 +0530
- Subject: PATCH: h8300-elf fix for gcc.c-torture/execute/20020307-2.c
Hi,
The execution of gcc.c-torture/execute/20020307-2.c
fails for h8300-elf-gcc when compiled with option
-fomit-frame-pointer. The following fix the problem:
*** h8300.c.orig Thu Oct 17 16:42:10 2002
--- h8300.c.modi Thu Oct 17 16:41:55 2002
*************** initial_offset (from, to)
*** 1373,1379 ****
int offset = 0;
if (from == ARG_POINTER_REGNUM && to == FRAME_POINTER_REGNUM)
! offset = UNITS_PER_WORD + frame_pointer_needed * UNITS_PER_WORD;
else if (from == RETURN_ADDRESS_POINTER_REGNUM && to ==
FRAME_POINTER_REGNUM)
offset = frame_pointer_needed * UNITS_PER_WORD;
else
--- 1373,1379 ----
int offset = 0;
if (from == ARG_POINTER_REGNUM && to == FRAME_POINTER_REGNUM)
! offset = UNITS_PER_WORD + UNITS_PER_WORD;
else if (from == RETURN_ADDRESS_POINTER_REGNUM && to ==
FRAME_POINTER_REGNUM)
offset = frame_pointer_needed * UNITS_PER_WORD;
else
Thanks and Best Regards,
Nitin.