Fix moving boxes in Example slide (§2)

This commit is contained in:
Théophile Bastian 2018-11-06 12:52:05 +01:00
parent 31587ff8bb
commit f0d2f6bca5

View file

@ -345,14 +345,7 @@ $1 = 84
\newcommand{\tblhl}{\rowcolor{Tan}} \newcommand{\tblhl}{\rowcolor{Tan}}
\begin{frame}{Example} \begin{frame}{Example}
\begin{table} \newcommand{\firsttblrows}{
\ttfamily\large
\begin{tabularx}{0.9\linewidth}{
l
b
>{\columncolor{SkyBlue}}s
>{\columncolor{SkyBlue}}s
}
\tblrowval{\hspace{-2ex}<{\bf foo}>:}{}{\textbf{CFA}}{\textbf{ra}} \tblrowval{\hspace{-2ex}<{\bf foo}>:}{}{\textbf{CFA}}{\textbf{ra}}
\rowonly<3>{\tblhl{}} \tblrowval{push}{\%r15}{rsp+8}{c-8} \rowonly<3>{\tblhl{}} \tblrowval{push}{\%r15}{rsp+8}{c-8}
\rowonly<4>{\tblhl{}} \tblrowval{push}{\%r14}{rsp+16}{c-8} \rowonly<4>{\tblhl{}} \tblrowval{push}{\%r14}{rsp+16}{c-8}
@ -363,36 +356,62 @@ $1 = 84
\tblrowval{push}{\%rbx}{rsp+48}{c-8} \tblrowval{push}{\%rbx}{rsp+48}{c-8}
\tblrowval{sub}{\$0x68,\%rsp}{rsp+56}{c-8} \tblrowval{sub}{\$0x68,\%rsp}{rsp+56}{c-8}
\rowonly<9>{\tblhl{}} \tblrowval{cmp}{\$0x1,\%edi}{rsp+160}{c-8}% \rowonly<9>{\tblhl{}} \tblrowval{cmp}{\$0x1,\%edi}{rsp+160}{c-8}%
\only<-8>{% }
\only<-8>{
\begin{table}
\ttfamily\large
\begin{tabularx}{0.9\linewidth}{
l
b
>{\columncolor{SkyBlue}}s
>{\columncolor{SkyBlue}}s
}
\firsttblrows{}%
\tblrowval{add}{\$0x68,\%rsp}{rsp+160}{c-8} \tblrowval{add}{\$0x68,\%rsp}{rsp+160}{c-8}
\tblrowval{pop}{\%rbx}{rsp+56}{c-8} \tblrowval{pop}{\%rbx}{rsp+56}{c-8}
\tblrowval{pop}{\%rbp}{rsp+48}{c-8}} \tblrowval{pop}{\%rbp}{rsp+48}{c-8}
\end{tabularx} \end{tabularx}
\end{table} \end{table}
\blknote{
\only<-8> { \centering
\only<3>{\blknote{Upon function call, \alert{ra = *(\reg{rsp})} (ABI)}} \begin{overlayarea}{0.9\textwidth}{4.8ex}
\only<4>{\blknote{\texttt{push} decreases \reg{rsp} by 8: % \only<3>{Upon function call, \alert{ra = *(\reg{rsp})} (ABI)}
\alert{ra = *(\reg{rsp} + 8)}}} \only<4>{\texttt{push} decreases \reg{rsp} by 8: %
\only<5>{\blknote{and again: % \alert{ra = *(\reg{rsp} + 8)}}
\alert{ra = *(\reg{rsp} + 16)}}} \only<5>{and again: %
\only<6>{\blknote{This \texttt{mov} leaves \reg{rsp} untouched: % \alert{ra = *(\reg{rsp} + 16)}}
\alert{ra = *(\reg{rsp} + 16)}}} \only<6>{This \texttt{mov} leaves \reg{rsp} untouched: %
\only<7>{\blknote{The unwinding table can actually be seen as\\ \alert{ra = *(\reg{rsp} + 16)}}
an \alert{abstract interpretation} of the code\ldots}} \only<7>{The unwinding table can actually be seen as\\
\only<8>{\blknote{\ldots and thus, for a given run, be an \alert{abstract interpretation} of the code\ldots}
\alert{re-computed for verification}}} \only<8>{\ldots and thus, for a given run, be
\alert{re-computed for verification}}
\end{overlayarea}
}
}
\only<9->{
\begin{table}
\ttfamily\large
\begin{tabularx}{0.9\linewidth}{
l
b
>{\columncolor{SkyBlue}}s
>{\columncolor{SkyBlue}}s
}
\firsttblrows{}%
\end{tabularx}
\end{table}
\vspace{-0.8em}
\only<9>{\blklnote{If, within an execution,
\begin{itemize}
\item ra = \texttt{*(0xFFFF1098)}
\item \reg{rsp} = \texttt{0xFFFF1000}
\end{itemize}
We can \alert{evaluate both expressions} and \alert{compare}
}}
} }
\only<9-> {
\vspace{-2em}
\only<9>{\blklnote{If, within an execution,
\begin{itemize}
\item ra = \texttt{*(0xFFFF1098)}
\item \reg{rsp} = \texttt{0xFFFF1000}
\end{itemize}
We can \alert{evaluate both expressions} and \alert{compare}
}}
}
\end{frame} \end{frame}
\begin{frame}{Dynamic validation} \begin{frame}{Dynamic validation}