summaryrefslogtreecommitdiff
path: root/gnu/egcs/gcc
diff options
context:
space:
mode:
authorHiroaki Etoh <etoh@cvs.openbsd.org>2003-07-29 00:48:36 +0000
committerHiroaki Etoh <etoh@cvs.openbsd.org>2003-07-29 00:48:36 +0000
commit01d8ba637a9516a05afe40eae428a163ff7e0d24 (patch)
tree40e143146cff6783b9fdf816d8348032b3304930 /gnu/egcs/gcc
parentba8aa58dc2d8cf6dab2a5ee8eb5301c7f5330491 (diff)
push_frame_in_args: fix netpbm-alpha problem, changes the memory corruption at modifying the argument information.
ok pvalchev@
Diffstat (limited to 'gnu/egcs/gcc')
-rw-r--r--gnu/egcs/gcc/protector.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/gnu/egcs/gcc/protector.c b/gnu/egcs/gcc/protector.c
index d5713f298e9..e8bf3f97aa5 100644
--- a/gnu/egcs/gcc/protector.c
+++ b/gnu/egcs/gcc/protector.c
@@ -2099,8 +2099,14 @@ push_frame_in_args (parms, push_size, boundary)
/* the operand related to the sweep variable */
if (AUTO_BASEPTR (XEXP (home, 0)) == frame_pointer_rtx)
{
- offset += push_size;
- XEXP (XEXP (home, 0), 1) = gen_rtx_CONST_INT (VOIDmode, offset);
+ if (XEXP (home, 0) == frame_pointer_rtx)
+ XEXP (home, 0) = plus_constant (frame_pointer_rtx,
+ push_size);
+ else {
+ offset += push_size;
+ XEXP (XEXP (home, 0), 1) = gen_rtx_CONST_INT (VOIDmode,
+ offset);
+ }
/* mark */
XEXP (home, 0)->used = 1;