summaryrefslogtreecommitdiffstats
path: root/verified_resource_sharing.tex
diff options
context:
space:
mode:
Diffstat (limited to 'verified_resource_sharing.tex')
-rw-r--r--verified_resource_sharing.tex77
1 files changed, 63 insertions, 14 deletions
diff --git a/verified_resource_sharing.tex b/verified_resource_sharing.tex
index d9c5a4d..1fc5db7 100644
--- a/verified_resource_sharing.tex
+++ b/verified_resource_sharing.tex
@@ -9,6 +9,7 @@
\usepackage{tabu}
\usepackage{tikz}
\usepackage{pgfplots}
+\usepackage{pgfplotstable}
\usepackage{multirow}
\usepackage{booktabs}
\usepackage{hyperref}
@@ -20,6 +21,9 @@
\usepackage{tikz-timing}
\usetikzlibrary{fit}
\usetikzlibrary{decorations.pathreplacing}
+\usetikzlibrary{shapes,calc,arrows.meta}
+\usetikzlibrary{pgfplots.groupplots}
+\pgfplotsset{compat=1.16}
\usepackage{listings}
\lstset{
@@ -414,21 +418,66 @@ We now compare the performance of the hardware generated by \vericertfun{} again
Figure~\ref{fig:results} summarises our results. The x-axis shows the impact of resource sharing on the speed of the hardware (as calculated by the cycle count divided by fmax); we see that all the data points lie very close to 1, which suggests no significant impact. On average the cycle count increases by 0.7\%; this modest increase is in line with expectations because our translation introduces an extra state per function call. The impact on fmax is similarly minimal, ranging between a 1.5\% increase and a 3.1\% decrease (0.2\% decrease on average).
+\pgfplotstableread[col sep=comma]{data/time-ratio.csv}{\divtimingtable}
+\pgfplotstableread[col sep=comma]{data/slice-ratio.csv}{\divslicetable}
+\definecolor{vericertcol}{HTML}{66C2A5}
+\definecolor{legupnooptcol}{HTML}{FC8D62}
+\definecolor{legupnooptnochaincol}{HTML}{8DA0CB}
+\newcommand\backgroundbar[2][5]{\draw[draw=none, fill=black!#1] (axis cs:#2*2+0.5,0.1) rectangle
+ (axis cs:1+#2*2+0.5,300);}
+\newcommand\legup{Bambu}
+
\begin{figure}
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-RESULTS GRAPH HERE.\par
-\caption{Impact of resource sharing on the speed and area usage of generated hardware.}
+ \begin{tikzpicture}
+ \begin{groupplot}[
+ group style={
+ group name=my plots,
+ group size=1 by 2,
+ xlabels at=edge bottom,
+ xticklabels at=edge bottom,
+ vertical sep=5pt,
+ },
+ ymode=log,
+ ybar=0.4pt,
+ width=1\textwidth,
+ height=0.4\textwidth,
+ /pgf/bar width=3pt,
+ legend pos=south east,
+ log ticks with fixed point,
+ xticklabels from table={\divtimingtable}{benchmark},
+ legend style={nodes={scale=0.7, transform shape}},
+ x tick label style={rotate=90,anchor=east,font=\footnotesize},
+ legend columns=-1,
+ xtick=data,
+ enlarge x limits={abs=0.5},
+ ylabel style={font=\footnotesize},
+ xtick style={draw=none},
+ ]
+
+ \nextgroupplot[ymin=0.8,ymax=300,ylabel={Execution time relative to \legup{}}]
+ \pgfplotsinvokeforeach{0,...,12}{%
+ \backgroundbar{#1}}
+ \backgroundbar[10]{13}
+ \addplot+[vericertcol] table [x expr=\coordindex,y=vericert,col sep=comma] from \divtimingtable;
+ \addplot+[legupnooptcol] table [x expr=\coordindex,y=vericert-fun,col sep=comma] from \divtimingtable;
+ \draw (axis cs:-1,1) -- (axis cs:28,1);
+ % JW: redraw axis border which has been partially covered by the grey bars
+ \draw (axis cs:-0.5,0.8) rectangle (axis cs:27.5,300);
+
+ \nextgroupplot[ymin=0.3,ymax=10,ylabel={Area relative to \legup{}}]
+ \pgfplotsinvokeforeach{0,...,12}{%
+ \backgroundbar{#1}}
+ \backgroundbar[10]{13}
+ \addplot+[vericertcol] table [x expr=\coordindex,y=vericert,col sep=comma] from \divslicetable;
+ \addplot+[legupnooptcol] table [x expr=\coordindex,y=vericert-fun,col sep=comma] from \divslicetable;
+ \draw (axis cs:-1,1) -- (axis cs:28,1);
+ % JW: redraw axis border which has been partially covered by the grey bars
+ \draw (axis cs:-0.5,0.3) rectangle (axis cs:27.5,10);
+
+ \legend{\vericert{},vericert-fun};
+ \end{groupplot}
+ \end{tikzpicture}
+ \caption{Performance of \vericert{} compared to \legup{}, with division and modulo operations enabled. The top graph compares the execution times and the bottom graph compares the area of the generated designs. In both cases, the performance of \vericert{}, \legup{} without LLVM optimisations and without operation chaining, and \legup{} without LLVM optimisations is compared against default \legup{}.}
\label{fig:results}
\end{figure}