aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeffrey A Law <law@cygnus.com>1999-07-16 20:35:08 +0000
committerJeff Law <law@gcc.gnu.org>1999-07-16 14:35:08 -0600
commitd7735a074b4b8f8d1070388dbea6528187059319 (patch)
tree03d73223e5f14905f1aa32f43d6edd99a846282e
parentc8730d930d6839d96a828fcd0441a25128c0157e (diff)
downloadgcc-d7735a074b4b8f8d1070388dbea6528187059319.zip
gcc-d7735a074b4b8f8d1070388dbea6528187059319.tar.gz
gcc-d7735a074b4b8f8d1070388dbea6528187059319.tar.bz2
pa.c (compute_frame_size): Use UNITS_PER_WORD instead of hardwired value of 4.
* pa.c (compute_frame_size): Use UNITS_PER_WORD instead of hardwired value of 4. Allocate 8 bytes for each FP register save. (hppa_expand_epilogue): Use UNITS_PER_WORD instead of harwarewired value of 4. (hppa_expand_prologue): Likewise. * pa.h (PROMOTE_MODE): Likewise. (HARD_REGNO_MODE_OK, FUNCTION_ARG_SIZE): Likewise. (FUNCTION_ARG_BOUNDARY): Likewise. From-SVN: r28127
-rw-r--r--gcc/ChangeLog9
-rw-r--r--gcc/config/pa/pa.c12
-rw-r--r--gcc/config/pa/pa.h11
3 files changed, 22 insertions, 10 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 5db0760..0e110c6 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,14 @@
Fri Jul 16 13:48:09 1999 Jeffrey A Law (law@cygnus.com)
+ * pa.c (compute_frame_size): Use UNITS_PER_WORD instead of hardwired
+ value of 4. Allocate 8 bytes for each FP register save.
+ (hppa_expand_epilogue): Use UNITS_PER_WORD instead of harwarewired
+ value of 4.
+ (hppa_expand_prologue): Likewise.
+ * pa.h (PROMOTE_MODE): Likewise.
+ (HARD_REGNO_MODE_OK, FUNCTION_ARG_SIZE): Likewise.
+ (FUNCTION_ARG_BOUNDARY): Likewise.
+
* invoke.texi (HPPA Options): Remove -mspace/-mno-space.
* pa.c (out_of_line_prologue_epilogue): Delete.
diff --git a/gcc/config/pa/pa.c b/gcc/config/pa/pa.c
index af748e0..a931857 100644
--- a/gcc/config/pa/pa.c
+++ b/gcc/config/pa/pa.c
@@ -2559,7 +2559,7 @@ compute_frame_size (size, fregs_live)
for (i = 18; i >= 3; i--)
if (regs_ever_live[i])
{
- fsize += 4;
+ fsize += UNITS_PER_WORD;
break;
}
@@ -2572,7 +2572,7 @@ compute_frame_size (size, fregs_live)
if (fregs_live)
*fregs_live = 1;
- fsize += 4;
+ fsize += 8;
break;
}
@@ -2807,7 +2807,7 @@ hppa_expand_prologue()
if (regs_ever_live[i] && ! call_used_regs[i])
{
store_reg (i, offset, FRAME_POINTER_REGNUM);
- offset += 4;
+ offset += UNITS_PER_WORD;
gr_saved++;
}
/* Account for %r3 which is saved in a special place. */
@@ -2830,7 +2830,7 @@ hppa_expand_prologue()
}
else
store_reg (i, offset, STACK_POINTER_REGNUM);
- offset += 4;
+ offset += UNITS_PER_WORD;
gr_saved++;
}
@@ -2958,7 +2958,7 @@ hppa_expand_epilogue ()
if (regs_ever_live[i] && ! call_used_regs[i])
{
load_reg (i, offset, FRAME_POINTER_REGNUM);
- offset += 4;
+ offset += UNITS_PER_WORD;
}
}
else
@@ -2976,7 +2976,7 @@ hppa_expand_epilogue ()
merge_sp_adjust_with_load = i;
else
load_reg (i, offset, STACK_POINTER_REGNUM);
- offset += 4;
+ offset += UNITS_PER_WORD;
}
}
}
diff --git a/gcc/config/pa/pa.h b/gcc/config/pa/pa.h
index 8132c7b..1f9a917 100644
--- a/gcc/config/pa/pa.h
+++ b/gcc/config/pa/pa.h
@@ -319,7 +319,7 @@ int lhs_lshift_cint_operand ();
#define PROMOTE_MODE(MODE,UNSIGNEDP,TYPE) \
if (GET_MODE_CLASS (MODE) == MODE_INT \
- && GET_MODE_SIZE (MODE) < 4) \
+ && GET_MODE_SIZE (MODE) < UNITS_PER_WORD) \
(MODE) = SImode;
/* Define this if most significant bit is lowest numbered
@@ -578,7 +578,7 @@ int lhs_lshift_cint_operand ();
: !TARGET_PA_11 && FP_REGNO_P (REGNO) \
? GET_MODE_SIZE (MODE) <= 4 || GET_MODE_CLASS (MODE) == MODE_FLOAT \
/* Make wide modes be in aligned registers. */ \
- : GET_MODE_SIZE (MODE) <= 4 || ((REGNO) & 1) == 0)
+ : GET_MODE_SIZE (MODE) <= UNITS_PER_WORD || ((REGNO) & 1) == 0)
/* Value is 1 if it is a good idea to tie two pseudo registers
when one has mode MODE1 and one has mode MODE2.
@@ -938,7 +938,9 @@ struct hppa_args {int words, nargs_prototype, indirect; };
/* Figure out the size in words of the function argument. */
#define FUNCTION_ARG_SIZE(MODE, TYPE) \
- ((((MODE) != BLKmode ? GET_MODE_SIZE (MODE) : int_size_in_bytes (TYPE))+3)/4)
+ ((((MODE) != BLKmode \
+ ? GET_MODE_SIZE (MODE) \
+ : int_size_in_bytes (TYPE)) + UNITS_PER_WORD - 1) / UNITS_PER_WORD)
/* Update the data in CUM to advance over an argument
of mode MODE and data type TYPE.
@@ -1057,7 +1059,8 @@ struct hppa_args {int words, nargs_prototype, indirect; };
#define FUNCTION_ARG_BOUNDARY(MODE, TYPE) \
(((TYPE) != 0) \
- ? (((int_size_in_bytes (TYPE)) + 3) / 4) * BITS_PER_WORD \
+ ? (((int_size_in_bytes (TYPE)) + UNITS_PER_WORD - 1) \
+ / UNITS_PER_WORD) * BITS_PER_WORD \
: ((GET_MODE_ALIGNMENT(MODE) <= PARM_BOUNDARY) \
? PARM_BOUNDARY \
: GET_MODE_ALIGNMENT(MODE)))