+2003-02-26 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+
+ * pa.c (compute_frame_size): Don't assume PREFERRED_STACK_BOUNDARY
+ is 8 * STACK_BOUNDARY.
+ * pa.h (PREFERRED_STACK_BOUNDARY): Change to 128 on 64-bit port.
+
2003-02-26 Michael Matz <matz@suse.de>
* ra-colorize.c (merge_moves): Fix list handling.
if (!current_function_is_leaf || fsize)
fsize += TARGET_64BIT ? 16 : 32;
- return (fsize + STACK_BOUNDARY - 1) & ~(STACK_BOUNDARY - 1);
+ return ((fsize + PREFERRED_STACK_BOUNDARY / 8 - 1)
+ & ~(PREFERRED_STACK_BOUNDARY / 8 - 1));
}
/* Generate the assembly code for function entry. FILE is a stdio
/* Boundary (in *bits*) on which stack pointer is always aligned;
certain optimizations in combine depend on this.
- GCC for the PA always rounds its stacks to a 8 * STACK_BOUNDARY
- boundary, but that happens late in the compilation process. */
+ The HP-UX runtime documents mandate 64-byte and 16-byte alignment for
+ the stack on the 32 and 64-bit ports, respectively. However, we
+ are only guaranteed that the stack is aligned to BIGGEST_ALIGNMENT
+ in main. Thus, we treat the former as the preferred alignment. */
#define STACK_BOUNDARY BIGGEST_ALIGNMENT
-
-#define PREFERRED_STACK_BOUNDARY (8 * STACK_BOUNDARY)
+#define PREFERRED_STACK_BOUNDARY (TARGET_64BIT ? 128 : 512)
/* Allocation boundary (in *bits*) for the code of a function. */
#define FUNCTION_BOUNDARY BITS_PER_WORD