Added `recording and stopping traces' and cleaned the document.

parent ba3207f2
\documentclass{beamer} % {{{
\documentclass{beamer}
\usepackage[dutch]{babel}
\usepackage[utf8]{inputenc}
\usepackage{beamerthemesplit}
......@@ -8,34 +8,33 @@
\setbeamercovered{transparent}
% Custom footer columns widths (modified "infolines" template)
\defbeamertemplate*{footline}{compactlines theme}
{
\defbeamertemplate*{footline}{compactlines theme} {
\leavevmode%
\hbox{%
\begin{beamercolorbox}[wd=.400000\paperwidth,ht=2.25ex,dp=1ex,center]{author in head/foot}%
\usebeamerfont{author in head/foot}\insertshortauthor~~(\insertshortinstitute)
\end{beamercolorbox}%
\begin{beamercolorbox}[wd=.400000\paperwidth,ht=2.25ex,dp=1ex,center]{title in head/foot}%
\usebeamerfont{title in head/foot}\insertshorttitle
\end{beamercolorbox}%
\begin{beamercolorbox}[wd=.200000\paperwidth,ht=2.25ex,dp=1ex,center]{date in head/foot}%
\usebeamerfont{date in head/foot}\insertshortdate{}\hspace*{2ex}
\insertframenumber{} / \inserttotalframenumber
\end{beamercolorbox}}%
\begin{beamercolorbox}[wd=.400000\paperwidth,ht=2.25ex,dp=1ex,center]{author in head/foot}%
\usebeamerfont{author in head/foot}\insertshortauthor~~(\insertshortinstitute)
\end{beamercolorbox}%
\begin{beamercolorbox}[wd=.400000\paperwidth,ht=2.25ex,dp=1ex,center]{title in head/foot}%
\usebeamerfont{title in head/foot}\insertshorttitle
\end{beamercolorbox}%
\begin{beamercolorbox}[wd=.200000\paperwidth,ht=2.25ex,dp=1ex,center]{date in head/foot}%
\usebeamerfont{date in head/foot}\insertshortdate{}\hspace*{2ex}
\insertframenumber{} / \inserttotalframenumber
\end{beamercolorbox}}%
\vskip0pt%
}
\mode<presentation> {
\usetheme{Boadilla}
%\usetheme{Copenhagen}
\usecolortheme[named=kugreen]{structure}
\useinnertheme{circles}
\usefonttheme[onlymath]{serif}
\useoutertheme{infolines}
\setbeamertemplate{navigation symbols}{}
\setbeamercovered{transparent}
\setbeamertemplate{footline}[compactlines theme]
\setbeamertemplate{blocks}[rounded][shadow=false]
\usetheme{Boadilla}
% \usetheme{Copenhagen}
\usecolortheme[named=kugreen]{structure}
\useinnertheme{circles}
\usefonttheme[onlymath]{serif}
\useoutertheme{infolines}
\setbeamertemplate{navigation symbols}{}
\setbeamercovered{transparent}
\setbeamertemplate{footline}[compactlines theme]
\setbeamertemplate{blocks}[rounded][shadow=false]
}
% \logo{\includegraphics[width=1cm]{images/vo20-logo.png}}
......@@ -48,8 +47,6 @@
\newfloat{program}{thp}{lop}
\floatname{program}{Program}
% }}}
\title{Incremental trace trees and JavaScript}
\subtitle{Executing typeless, dynamic languages faster}
\author{Sander van Veen}
......@@ -58,81 +55,85 @@
\begin{document}
\frame { \titlepage% {{{
} % }}}
\frame {
\titlepage
}
\frame { \frametitle{Overzicht} % {{{
\tableofcontents[pausesection]
} % }}}
\frame { \frametitle{Overzicht}
\tableofcontents[pausesection]
}
\section{Introductie tot JavaScript}
\subsection{Wat is JavaScript?}
\frame { \frametitle{JavaScript overzicht} % {{{
\frame { \frametitle{JavaScript overzicht}
De taal JavaScript is:
De taal JavaScript is:
\begin{itemize}
\item Typeless: objecten of primitieven.
\item Dynamic: alles kan \emph{at runtime} veranderen.
\end{itemize}
\begin{itemize}
\item Typeless: objecten of primitieven.
\item Dynamic: alles kan \emph{at runtime} veranderen.
\end{itemize}
JavaScript voorbeeld:
JavaScript voorbeeld:
\input{basic-example}
\input{basic-example}
} % }}}
}
\frame { \frametitle{JavaScript variabel representatie} % {{{
\frame { \frametitle{JavaScript variabel representatie}
Firefox gebruikt 64 bits voor alle types:
Firefox gebruikt 64 bits voor alle types:
\begin{center}
\begin{center}
\begin{tabular}{l|ll} \toprule
JavaScript waarde & eerste 32 bits & laatste 32 bits \\ \midrule
42 & INTEGER\_TAG & 42 \\
"hi" & STRING\_TAG & 0x20506638 \\
\{key: "value"\} & OBJECT\_TAG & 0x86753090 \\
3.1415 & 0x400921CA & 0xC083126F \\ \bottomrule
JavaScript waarde & eerste 32 bits & laatste 32 bits \\ \midrule
42 & INTEGER\_TAG & 42 \\
"hi" & STRING\_TAG & 0x20506638 \\
\{key: "value"\} & OBJECT\_TAG & 0x86753090 \\
3.1415 & 0x400921CA & 0xC083126F \\ \bottomrule
\end{tabular}
\end{center}
\end{center}
``NaN unboxing'' is de techniek voor onderscheid in variabel typen:
``NaN unboxing'' is de techniek voor onderscheid in variabel typen:
\begin{itemize}
\item Double: sign 1 bit, exponent 11 bits en mantissa 52 bits.
\item IEEE 754: alle exponent bits op 1 $\rightarrow$ float is \texttt{NaN}
\begin{itemize}
\item Double: sign 1 bit, exponent 11 bits en mantissa 52 bits.
\item IEEE 754: alle exponent bits op 1 $\rightarrow$ float is \texttt{NaN}
of $\pm \infty$.
\item Dus: bij \texttt{NaN} bepalen de 14 bits na de exponent de TAG.
\end{itemize}
\item Dus: bij \texttt{NaN} bepalen de 14 bits na de exponent de TAG.
\end{itemize}
} % }}}
}
\subsection{Browser onderdelen}
\frame { \frametitle{Wat doet elk onderdeel?} % {{{
\frame { \frametitle{Wat doet elk onderdeel?}
In de Mozilla Firefox browser:
In de Mozilla Firefox browser:
\begin{itemize}
\item User Interface
\item Networking
\item Render engine (Gecko)
\item JavaScript engine (SpiderMonkey)
\begin{itemize}
\pause \item Interpreter
\pause \item Method Just-In-Time compiler (JägerMonkey)
\pause \item \alert{Trace compiler (TraceMonkey)}
\end{itemize}
\end{itemize}
\begin{itemize}
\item User Interface
\item Networking
\item Render engine (Gecko)
\item JavaScript engine (SpiderMonkey)
\begin{itemize}
\pause \item Interpreter
\pause \item Method Just-In-Time compiler (JägerMonkey)
\pause \item \alert{Trace compiler (TraceMonkey)}
\end{itemize}
\end{itemize}
} % }}}
}
\section{Compiler basics}
\frame { \frametitle{Control flow graph} % {{{
\subsection{Control flow graph}
\begin{columns}[t]
\frame { \frametitle{Control flow graph}
\begin{columns}[t]
\column{.6\textwidth}
\textbf{Code voorbeeld}
......@@ -143,34 +144,58 @@
\textbf{Control flow graph van A}
\includegraphics[width=6cm]{images/control-flow-graph.pdf}
\end{columns}
\end{columns}
}
} % }}}
\subsection{Trace vs Just-In-Time compiler}
\frame { \frametitle{Trace vs Just-In-Time compiler} % {{{
\frame { \frametitle{Trace vs Just-In-Time compiler}
\begin{columns}[t]
\column{.5\textwidth}
\textbf{Trace compiler}
\begin{columns}[t]
\column{.5\textwidth}
\textbf{Trace compiler}
\begin{itemize}
\begin{itemize}
\item Eenheid is een ``loop''.
\item Benodigd: Traces opnemen.
\includegraphics[width=6cm]{images/trace-tree.pdf}
\end{itemize}
\item \emph{Lazy compilation}; niet 3 en 7.
\includegraphics[width=6cm]{images/trace-tree.pdf}
\end{itemize}
\column{.5\textwidth}
\textbf{Just-In-Time compiler}
\column{.5\textwidth}
\textbf{Just-In-Time compiler}
\begin{itemize}
\begin{itemize}
\item Eenheid is een ``method''.
\item Benodigd: Control flow graph.
\includegraphics[width=6cm]{images/control-flow-graph.pdf}
\end{itemize}
\includegraphics[width=6cm]{images/control-flow-graph.pdf}
\end{itemize}
\end{columns}
\end{columns}
}
\subsection{Trace trees}
\frame { \frametitle{Hoe worden traces opgenomen?}
\begin{enumerate}
\item Detecteer start van een loop.
\item Houd \emph{loop count} bij.
\item Loop count $>$ \emph{threshold}: record trace!
\item Stop de trace na een cycle.
\end{enumerate}
} % }}}
\pause \textbf{Of een trace faalt}
\begin{enumerate}
\item Er treedt een \emph{exception} op.
% \item \emph{Memory allocation} instructies.
\item Een trace wordt te lang (voor geheugen).
\end{enumerate}
}
\end{document}
% vim: foldmethod=marker
% vim: foldmethod=marker
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment