Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [rfa:doco] document frame_align()
@ 2002-09-18  9:24 Andrew Cagney
  2002-09-18  9:29 ` Richard Earnshaw
  2002-09-19  6:03 ` Eli Zaretskii
  0 siblings, 2 replies; 5+ messages in thread
From: Andrew Cagney @ 2002-09-18  9:24 UTC (permalink / raw)
  To: gdb-patches

[-- Attachment #1: Type: text/plain, Size: 125 bytes --]

Hello,

This documents the frame_align() architecture method.  It also clarifies 
the behavior of stack_align().

ok?
Andrew

[-- Attachment #2: diffs --]
[-- Type: text/plain, Size: 1849 bytes --]

2002-09-18  Andrew Cagney  <ac131313@redhat.com>

	* gdbint.texinfo (Target Architecture Definition): Revise
	description of STACK_ALIGN.  Add description of FRAME_ALIGN.

Index: gdbint.texinfo
===================================================================
RCS file: /cvs/src/src/gdb/doc/gdbint.texinfo,v
retrieving revision 1.100
diff -u -r1.100 gdbint.texinfo
--- gdbint.texinfo	24 Aug 2002 00:21:37 -0000	1.100
+++ gdbint.texinfo	18 Sep 2002 16:19:24 -0000
@@ -3175,6 +3175,23 @@
 represented by @var{fi} does not have a stack frame associated with it.
 Otherwise return 0.
 
+@item frame_align (@var{address})
+@anchor frame_align
+@findex frame_align
+Define this to adjust @var{address} so that it meets the alignment
+requirements for the start of a new stack frame.  A stack frame's
+alignment requirements are typically stronger than a target processors
+stack alignment requirements (@pxref{STACK_ALIGN}).
+
+This function is used to ensure that, when creating a dummy frame, both
+the initial stack pointer and (if needed) the address of the return
+value are correctly aligned.
+
+Unlike @ref{STACK_ALIGN}, this function always adjusts the address in
+the direction of stack growth.
+
+By default, no frame based stack alignment is performed.
+
 @item FRAME_ARGS_ADDRESS_CORRECT
 @findex FRAME_ARGS_ADDRESS_CORRECT
 See @file{stack.c}.
@@ -3690,9 +3707,15 @@
 done.
 
 @item STACK_ALIGN (@var{addr})
+@anchor{STACK_ALIGN}
 @findex STACK_ALIGN
-Define this to adjust the address to the alignment required for the
-processor's stack.
+Define this to increase @var{addr} so that it meets the alignment
+requirements for the processor's stack.
+
+Unlike @ref{frame_align}, this function always adjusts @var{addr}
+upwards.
+
+By default, no stack alignment is performed.
 
 @item STEP_SKIPS_DELAY (@var{addr})
 @findex STEP_SKIPS_DELAY

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2002-09-19 15:29 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-09-18  9:24 [rfa:doco] document frame_align() Andrew Cagney
2002-09-18  9:29 ` Richard Earnshaw
2002-09-18 10:05   ` Andrew Cagney
2002-09-19  6:03 ` Eli Zaretskii
2002-09-19  8:29   ` Andrew Cagney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox