1<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
2<html>
3<!-- Copyright (C) 1994-2021 Free Software Foundation, Inc.
4
5Permission is granted to copy, distribute and/or modify this document
6under the terms of the GNU Free Documentation License, Version 1.3 or
7any later version published by the Free Software Foundation; with no
8Invariant Sections, with no Front-Cover Texts, and with no Back-Cover
9Texts.  A copy of the license is included in the section entitled "GNU
10Free Documentation License". -->
11<!-- Created by GNU Texinfo 5.1, http://www.gnu.org/software/texinfo/ -->
12<head>
13<title>GDB&rsquo;s Obsolete Annotations: Frame Annotations</title>
14
15<meta name="description" content="GDB&rsquo;s Obsolete Annotations: Frame Annotations">
16<meta name="keywords" content="GDB&rsquo;s Obsolete Annotations: Frame Annotations">
17<meta name="resource-type" content="document">
18<meta name="distribution" content="global">
19<meta name="Generator" content="makeinfo">
20<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
21<link href="index.html#Top" rel="start" title="Top">
22<link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
23<link href="index.html#Top" rel="up" title="Top">
24<link href="Displays.html#Displays" rel="next" title="Displays">
25<link href="Value-Annotations.html#Value-Annotations" rel="previous" title="Value Annotations">
26<style type="text/css">
27<!--
28a.summary-letter {text-decoration: none}
29blockquote.smallquotation {font-size: smaller}
30div.display {margin-left: 3.2em}
31div.example {margin-left: 3.2em}
32div.indentedblock {margin-left: 3.2em}
33div.lisp {margin-left: 3.2em}
34div.smalldisplay {margin-left: 3.2em}
35div.smallexample {margin-left: 3.2em}
36div.smallindentedblock {margin-left: 3.2em; font-size: smaller}
37div.smalllisp {margin-left: 3.2em}
38kbd {font-style:oblique}
39pre.display {font-family: inherit}
40pre.format {font-family: inherit}
41pre.menu-comment {font-family: serif}
42pre.menu-preformatted {font-family: serif}
43pre.smalldisplay {font-family: inherit; font-size: smaller}
44pre.smallexample {font-size: smaller}
45pre.smallformat {font-family: inherit; font-size: smaller}
46pre.smalllisp {font-size: smaller}
47span.nocodebreak {white-space:nowrap}
48span.nolinebreak {white-space:nowrap}
49span.roman {font-family:serif; font-weight:normal}
50span.sansserif {font-family:sans-serif; font-weight:normal}
51ul.no-bullet {list-style: none}
52-->
53</style>
54
55
56</head>
57
58<body lang="en" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000">
59<a name="Frame-Annotations"></a>
60<div class="header">
61<p>
62Next: <a href="Displays.html#Displays" accesskey="n" rel="next">Displays</a>, Previous: <a href="Value-Annotations.html#Value-Annotations" accesskey="p" rel="previous">Value Annotations</a>, Up: <a href="index.html#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p>
63</div>
64<hr>
65<a name="Frames"></a>
66<h2 class="chapter">6 Frames</h2>
67
68<p><em>Value Annotations have been removed.  <small>GDB/MI</small> instead provides
69a number of frame commands.</em>
70</p>
71<p><em>Frame annotations are no longer available.  The <small>GDB/MI</small>
72provides &lsquo;<samp>-stack-list-arguments</samp>&rsquo;, &lsquo;<samp>-stack-list-locals</samp>&rsquo;, and
73&lsquo;<samp>-stack-list-frames</samp>&rsquo; commands.</em>
74</p>
75<a name="index-annotations-for-frames"></a>
76<p>Whenever <small>GDB</small> prints a frame, it annotates it.  For example, this applies
77to frames printed when <small>GDB</small> stops, output from commands such as
78<code>backtrace</code> or <code>up</code>, etc.
79</p>
80<a name="index-frame_002dbegin"></a>
81<p>The frame annotation begins with
82</p>
83<div class="smallexample">
84<pre class="smallexample">^Z^Zframe-begin <var>level</var> <var>address</var>
85<var>level-string</var>
86</pre></div>
87
88<p>where <var>level</var> is the number of the frame (0 is the innermost frame,
89and other frames have positive numbers), <var>address</var> is the address of
90the code executing in that frame, and <var>level-string</var> is a string
91designed to convey the level to the user.  <var>address</var> is in the form
92&lsquo;<samp>0x</samp>&rsquo; followed by one or more lowercase hex digits (note that this
93does not depend on the language).  The frame ends with
94</p>
95<a name="index-frame_002dend"></a>
96<div class="smallexample">
97<pre class="smallexample">^Z^Zframe-end
98</pre></div>
99
100<p>Between these annotations is the main body of the frame, which can
101consist of
102</p>
103<ul>
104<li> <a name="index-function_002dcall"></a>
105<div class="smallexample">
106<pre class="smallexample">^Z^Zfunction-call
107<var>function-call-string</var>
108</pre></div>
109
110where <var>function-call-string</var> is text designed to convey to the user
111that this frame is associated with a function call made by <small>GDB</small> to a
112function in the program being debugged.
113
114</li><li> <a name="index-signal_002dhandler_002dcaller"></a>
115<div class="smallexample">
116<pre class="smallexample">^Z^Zsignal-handler-caller
117<var>signal-handler-caller-string</var>
118</pre></div>
119
120where <var>signal-handler-caller-string</var> is text designed to convey to
121the user that this frame is associated with whatever mechanism is used
122by this operating system to call a signal handler (it is the frame which
123calls the signal handler, not the frame for the signal handler itself).
124
125</li><li> A normal frame.
126
127<a name="index-frame_002daddress"></a>
128<a name="index-frame_002daddress_002dend"></a>
129<p>This can optionally (depending on whether this is thought of as
130interesting information for the user to see) begin with
131</p>
132<div class="smallexample">
133<pre class="smallexample">^Z^Zframe-address
134<var>address</var>
135^Z^Zframe-address-end
136<var>separator-string</var>
137</pre></div>
138
139<p>where <var>address</var> is the address executing in the frame (the same
140address as in the <code>frame-begin</code> annotation, but printed in a form
141which is intended for user consumption&mdash;in particular, the syntax varies
142depending on the language), and <var>separator-string</var> is a string
143intended to separate this address from what follows for the user&rsquo;s
144benefit.
145</p>
146<a name="index-frame_002dfunction_002dname"></a>
147<a name="index-frame_002dargs"></a>
148<p>Then comes
149</p>
150<div class="smallexample">
151<pre class="smallexample">^Z^Zframe-function-name
152<var>function-name</var>
153^Z^Zframe-args
154<var>arguments</var>
155</pre></div>
156
157<p>where <var>function-name</var> is the name of the function executing in the
158frame, or &lsquo;<samp>??</samp>&rsquo; if not known, and <var>arguments</var> are the arguments
159to the frame, with parentheses around them (each argument is annotated
160individually as well, see <a href="Value-Annotations.html#Value-Annotations">Value Annotations</a>).
161</p>
162<a name="index-frame_002dsource_002dbegin"></a>
163<a name="index-frame_002dsource_002dfile"></a>
164<a name="index-frame_002dsource_002dfile_002dend"></a>
165<a name="index-frame_002dsource_002dline"></a>
166<a name="index-frame_002dsource_002dend"></a>
167<p>If source information is available, a reference to it is then printed:
168</p>
169<div class="smallexample">
170<pre class="smallexample">^Z^Zframe-source-begin
171<var>source-intro-string</var>
172^Z^Zframe-source-file
173<var>filename</var>
174^Z^Zframe-source-file-end
175:
176^Z^Zframe-source-line
177<var>line-number</var>
178^Z^Zframe-source-end
179</pre></div>
180
181<p>where <var>source-intro-string</var> separates for the user&rsquo;s benefit the
182reference from the text which precedes it, <var>filename</var> is the name of
183the source file, and <var>line-number</var> is the line number within that
184file (the first line is line 1).
185</p>
186<a name="index-frame_002dwhere"></a>
187<p>If <small>GDB</small> prints some information about where the frame is from (which
188library, which load segment, etc.; currently only done on the RS/6000),
189it is annotated with
190</p>
191<div class="smallexample">
192<pre class="smallexample">^Z^Zframe-where
193<var>information</var>
194</pre></div>
195
196<p>Then, if source is to actually be displayed for this frame (for example,
197this is not true for output from the <code>backtrace</code> command), then a
198<code>source</code> annotation (see <a href="Source-Annotations.html#Source-Annotations">Source Annotations</a>) is displayed.  Unlike
199most annotations, this is output instead of the normal text which would be
200output, not in addition.
201</p></li></ul>
202
203<hr>
204<div class="header">
205<p>
206Next: <a href="Displays.html#Displays" accesskey="n" rel="next">Displays</a>, Previous: <a href="Value-Annotations.html#Value-Annotations" accesskey="p" rel="previous">Value Annotations</a>, Up: <a href="index.html#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p>
207</div>
208
209
210
211</body>
212</html>
213