\item Each function is turned into a hardware component
\item Use of state will be simple
\end{itemize}
+}\note[itemize]{
+\item Small "toy"-example of what can be done in \clash{}
+\item Show what can be translated to Hardware
+\item Put your hardware glasses on: each function will be a component
+\item Use of state will be kept simple
}
\frame
import CLasH.Translator.Annotations
\end{code}
\end{beamercolorbox}
+}\note[itemize]{
+\item The first input is always needed, as it contains the builtin types
+\item The second one is only needed if you want to make use of Annotations
}
\subsection{Type Definitions}
type Word = SizedInt D12
\end{code}
\end{beamercolorbox}
+}\note[itemize]{
+\item The first type is already polymorphic, both in size, and element type
+\item It's a small example, so Opcode is just a Bit
+\item State has to be of the State type to be recognized as such
+\item SizedInt D12: One concrete type for now, to make the signatures smaller
}
\subsection{Frameworks for Operations}
\begin{itemize}
\uncover<3->{\item We support Higher-Order Functionality}
\end{itemize}
+}\note[itemize]{
+\item These are just frameworks for 'real' operations
+\item Notice how they are High-Order functions
}
+
\subsection{Polymorphic, Higher-Order ALU}
\frame
{
\begin{itemize}
\uncover<2->{\item We support Patter Matching}
\end{itemize}
+}\note[itemize]{
+\item Alu is both higher-order, and polymorphic
+\item We support pattern matching
}
+
\subsection{Register bank}
\frame
{
\begin{itemize}
\uncover<2->{\item We support Guards}
\end{itemize}
+}\note[itemize]{
+\item RangedWord runs from 0 to the upper bound
+\item mem is statefull
+\item We support guards
}
+
\subsection{Simple CPU: ALU \& Register Bank}
\frame
{
\begin{itemize}
\uncover<2->{\item Annotation is used to indicate top-level component}
\end{itemize}
+}\note[itemize]{
+\item We use the new Annotion functionality to indicate this is the top level
+\item the primOp and vectOp frameworks are now supplied with real functionality, the plus (+) operations
+\item No polymorphism or higher-order stuff is allowed at this level.
+\item Functions must be specialized, and have primitives for input and output
}
%if style == newcode
let input = program
let istate = initstate
let output = run actual_cpu istate input
- mapM_ (\x -> putStr $ ("# (" P.++ (show x) P.++ ")\n")) output
+ mapM_ (\x -> putStr $ ("(" P.++ (show x) P.++ ")\n")) output
return ()
\end{code}
%endif
\ No newline at end of file