@@ -134,12 +134,12 @@ \subsection{One advantage of raising with debugging information}
134
134
\mintc [firstline=190,lastline=192,highlightlines={191-192}]{../ocaml/runtime/amd64.S}
135
135
\mintc [firstline=234,lastline=237,highlightlines={235-237}]{../ocaml/runtime/amd64.S}
136
136
}
137
- \onslide *<1>{\listCamlRaiseExn [highlightlines=705]{}}
138
- \onslide *<2>{\listCamlRaiseExn [highlightlines={707-708}]{}}
139
- \onslide *<3>{\listCamlRaiseExn [highlightlines={712-714}]{}}
140
- \onslide *<4>{\listCamlRaiseExn [highlightlines={715-720}]{}}
141
- \onslide *<5>{\providecommand\step {1}\input {diagrams/backtrace/backtrace.tex }}
142
- \onslide *<6>{\providecommand\step {2}\input {diagrams/backtrace/backtrace.tex }}
137
+ \onslide *<1>{\listCamlRaiseExn [highlightlines=705]{}}%
138
+ \onslide *<2>{\listCamlRaiseExn [highlightlines={707-708}]{}}%
139
+ \onslide *<3>{\listCamlRaiseExn [highlightlines={712-714}]{}}%
140
+ \onslide *<4>{\listCamlRaiseExn [highlightlines={715-720}]{}}%
141
+ \onslide *<5>{\providecommand\step {1}\input {diagrams/backtrace/backtrace.tex }}%
142
+ \onslide *<6>{\providecommand\step {2}\input {diagrams/backtrace/backtrace.tex }}%
143
143
\end {column }
144
144
\end {columns }
145
145
\end {frame }
@@ -212,6 +212,32 @@ \subsection{One advantage of raising with debugging information}
212
212
\end {columns }
213
213
\end {frame }
214
214
215
+ \begin {frame }{Backtraces}{Scanning the stack with \typename {frame\_ descr}}
216
+ \begin {columns }[c]
217
+ \begin {column }{0.5\textwidth }
218
+ \begin {itemize }
219
+ \item Given the return address of the code that raises the exception by calling \funcname {caml\_ raise\_ exn} (\funcarg {pc} argument of \funcname {caml\_ stash\_ backtrace})
220
+ \item And the position of the stack pointer (\funcarg {sp} argument of \funcname {caml\_ stash\_ backtrace})
221
+ \item The frame size given by \typename {frame\_ descr}.\funcarg {frame\_ size}, allows to find the end of the previous frame
222
+ \item And the return address of the caller of this function
223
+ \bigskip
224
+ \onslide <3->{
225
+ \item Note that traps (here the reddish \funcname {ExnA}, \funcname {ExnB} and \funcname {ExnC} blocks) belong to the frame that installed them, and so the frame size changes when traps are removed
226
+ }
227
+ \end {itemize }
228
+ \end {column }
229
+ \begin {column }{0.5\textwidth }
230
+ \raggedleft
231
+ \onslide *<1>{\providecommand\step {2}\input {diagrams/backtrace/backtrace.tex }}%
232
+ \onslide *<2>{\providecommand\step {1}\input {diagrams/backtrace/scanstack.tex }}%
233
+ \onslide *<3>{\providecommand\step {2}\input {diagrams/backtrace/scanstack.tex }}%
234
+ \onslide *<4>{\providecommand\step {3}\input {diagrams/backtrace/scanstack.tex }}%
235
+ \onslide *<5>{\providecommand\step {4}\input {diagrams/backtrace/scanstack.tex }}%
236
+ \onslide *<6>{\providecommand\step {5}\input {diagrams/backtrace/scanstack.tex }}%
237
+ \end {column }
238
+ \end {columns }
239
+ \end {frame }
240
+
215
241
% Duplicate of previous-previous slide
216
242
\begin {frame }{Backtraces}{Continuing on \funcname {caml\_ stash\_ backtrace}}
217
243
\begin {columns }[c]
@@ -241,8 +267,8 @@ \subsection{One advantage of raising with debugging information}
241
267
\begin {column }{0.5\textwidth }
242
268
\raggedleft
243
269
\onslide *<1>{\listStashBacktrace [highlightlines={114-115}]{}}
244
- \onslide *<2>{\providecommand\step {3}\input {diagrams/backtrace/backtrace.tex }}
245
- \onslide *<3>{\providecommand\step {4}\input {diagrams/backtrace/backtrace.tex }}
270
+ \onslide *<2>{\providecommand\step {3}\input {diagrams/backtrace/backtrace.tex }}%
271
+ \onslide *<3>{\providecommand\step {4}\input {diagrams/backtrace/backtrace.tex }}%
246
272
\end {column }
247
273
\end {columns }
248
274
\end {frame }
@@ -385,15 +411,15 @@ \subsection{One advantage of raising with debugging information}
385
411
\end {column }
386
412
\begin {column }{0.45\textwidth }
387
413
\raggedleft
388
- \onslide *<1>{\providecommand\step {6}\input {diagrams/backtrace/backtrace.tex }}
389
- \onslide *<2>{\providecommand\step {6}\input {diagrams/backtrace/backtrace.tex }}
390
- \onslide *<3>{\providecommand\step {7}\input {diagrams/backtrace/backtrace.tex }}
391
- \onslide *<4>{\providecommand\step {8}\input {diagrams/backtrace/backtrace.tex }}
392
- \onslide *<5>{\providecommand\step {9}\input {diagrams/backtrace/backtrace.tex }}
393
- \onslide *<6>{\providecommand\step {10}\input {diagrams/backtrace/backtrace.tex }}
394
- \onslide *<7>{\providecommand\step {11}\input {diagrams/backtrace/backtrace.tex }}
395
- \onslide *<8>{\providecommand\step {12}\input {diagrams/backtrace/backtrace.tex }}
396
- \onslide *<9>{\providecommand\step {13}\input {diagrams/backtrace/backtrace.tex }}
414
+ \onslide *<1>{\providecommand\step {6}\input {diagrams/backtrace/backtrace.tex }}%
415
+ \onslide *<2>{\providecommand\step {6}\input {diagrams/backtrace/backtrace.tex }}%
416
+ \onslide *<3>{\providecommand\step {7}\input {diagrams/backtrace/backtrace.tex }}%
417
+ \onslide *<4>{\providecommand\step {8}\input {diagrams/backtrace/backtrace.tex }}%
418
+ \onslide *<5>{\providecommand\step {9}\input {diagrams/backtrace/backtrace.tex }}%
419
+ \onslide *<6>{\providecommand\step {10}\input {diagrams/backtrace/backtrace.tex }}%
420
+ \onslide *<7>{\providecommand\step {11}\input {diagrams/backtrace/backtrace.tex }}%
421
+ \onslide *<8>{\providecommand\step {12}\input {diagrams/backtrace/backtrace.tex }}%
422
+ \onslide *<9>{\providecommand\step {13}\input {diagrams/backtrace/backtrace.tex }}%
397
423
\end {column }
398
424
\end {columns }
399
425
\end {frame }
0 commit comments