aboutsummaryrefslogtreecommitdiff
path: root/gdb/doc/stack_frame.txt
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2009-03-21 10:24:35 +0000
committerEli Zaretskii <eliz@gnu.org>2009-03-21 10:24:35 +0000
commit587afa3811369858cb484ed0cd228ae650b9aaaf (patch)
tree742064e96e4819319eccfd224bb292e6dba5c2b6 /gdb/doc/stack_frame.txt
parent10af6951e8a78f6685b6c02d352043be4c28cd19 (diff)
downloadgdb-587afa3811369858cb484ed0cd228ae650b9aaaf.zip
gdb-587afa3811369858cb484ed0cd228ae650b9aaaf.tar.gz
gdb-587afa3811369858cb484ed0cd228ae650b9aaaf.tar.bz2
From Jeremy Bennett <jeremy.bennett@embecosm.com>:
* gdbint.texinfo (everywhere): Use braces {} in @deftypeXX type field throughout to handle types with spaces in them. Fix typos found by aspell. (Summary, Requirements, Contributors): New first chapter, "Summary" added, old Requirements section moved there, and new section, "Contributors" added. (Initializing a New Architecture, Register Representation) (Frame Interpretation, Inferior Call Setup, Adding a New Target) (Porting gdb): These sections extended and updated. (Compiler Characteristics): This section (empty) deleted. (Defining Other Architecture Features): This section renamed and duplicate material removed from (formerly "Target Conditionals"). Use braces {} in @deftypeXX type field throughout to handle types with spaces in them. Typos found by aspell fixed. * stack_frame.svg: New file, source of image for gdbint.texinfo. * stack_frame.pdf: Version of image for PDF output. * stack_frame.png: Version of image for HTML output and for Emacs. * stack_frame.txt: Version of image for Info output.
Diffstat (limited to 'gdb/doc/stack_frame.txt')
-rw-r--r--gdb/doc/stack_frame.txt39
1 files changed, 39 insertions, 0 deletions
diff --git a/gdb/doc/stack_frame.txt b/gdb/doc/stack_frame.txt
new file mode 100644
index 0000000..e6ff020
--- /dev/null
+++ b/gdb/doc/stack_frame.txt
@@ -0,0 +1,39 @@
+ ^ ->| |
+Frame | | | |
+Number - | | |============| int fact (int n)
+ | | | | i = 3 | {
+ | | | |------------| if (0 == n) {
+ | | | | f = ? | return 1; <-------- PC
+ #4 main() < | | |------------| }
+ | | | | | else {
+ | | -+->|------------| ---> return n * fact (n - 1);
+ | -+-+--+-----o | | }
+ = | | |============| | }
+ | | | | n = 3 | |
+ | | | |------------| | main ()
+ #3 fact (3) < | | | o---------+- {
+ | -+-+->|------------| | | int i;
+ | | | --+-----o | | |
+ = | | |============| | | for (i = 0; i < 10; i++) {
+ | | | | n = 2 | | -> int f = fact (i);
+ | | | |------------| | printf ("%d! = %d\n", i , f);
+ #2 fact (2) < | | | o------+--| }
+ | | | ->|------------| | }
+ | | -+--+-----o | |
+ = | | |============| |
+ | | | | n = 1 | |
+ | | | |------------| |
+ #1 fact (1) < | | | o------+--|
+ | | | |------------| |
+ | ---|--+-----o |<-+------- FP
+ = | |============| | |
+ | | | n = 0 | | |
+ | | |------------| | |
+ #0 fact (0) < | | o--------- |
+ | | |------------| |
+ | --+-----o |<--------- SP |
+ = |============| |
+ | | Red Zone | v
+ | \/\/\/\/\/\/\/ Direction of
+ #-1 < \/\/\/\/\/\/\/ stack growth
+ | | |