# HG changeset patch # User Christian Urban # Date 1544172874 0 # Node ID c650a91db72000d6c4d90b2cff03e2ecf91fbc46 # Parent b8cdaf51ffef8476dc33c965197ea8d03e985ba9 updated diff -r b8cdaf51ffef -r c650a91db720 cws/cw05.pdf Binary file cws/cw05.pdf has changed diff -r b8cdaf51ffef -r c650a91db720 cws/cw05.tex --- a/cws/cw05.tex Fri Dec 07 07:57:54 2018 +0000 +++ b/cws/cw05.tex Fri Dec 07 08:54:34 2018 +0000 @@ -15,7 +15,7 @@ % BF IDE % https://www.microsoft.com/en-us/p/brainf-ck/9nblgggzhvq5 -\section*{Coursework 9 (Scala)} +\section*{Coursework 10 (Scala)} This coursework is worth 10\%. It is about a small programming language called brainf***. The first part is due on 13 December at @@ -33,7 +33,7 @@ \subsection*{Reference Implementation} As usual, this Scala assignment comes with a reference implementation in form of -two \texttt{jar}-files. You can download them from KEATS. This allows you to run any +two \texttt{jar}-files. You can download them from KEATS. They allow you to run any test cases on your own computer. For example you can call Scala on the command line with the option \texttt{-cp bf.jar} and then query any function from the \texttt{bf.scala} template file. You have to @@ -379,7 +379,7 @@ \emph{peephole optimisations}.\footnote{\url{https://en.wikipedia.org/wiki/Peephole_optimization}} For the latter consider that it is difficult for compilers to - comprehend what is intended with whole programs, they are very good + comprehend what is intended with whole programs, but they are very good at finding out what small snippets of code do, and then try to generate faster code for such snippets. @@ -462,8 +462,8 @@ \pcode{>++[<+++++++++++++>-]<[[}\hspace{3mm}\ldots \end{center} - As you can see, the compiler bets on saving so much time on the - \pcode{+B} and \pcode{+M} steps such that the optimisations is + As you can see, the compiler bets on saving a lot of time on the + \pcode{+B} and \pcode{+M} steps so that the optimisations is worthwhile overall (of course for the \pcode{>A}'s and so on, the compiler incurs a penalty). Luckily, after you have performed all optimisations in (5) - (7), you can expect that the diff -r b8cdaf51ffef -r c650a91db720 slides/slides05.pdf Binary file slides/slides05.pdf has changed