From 3fa47f2ae68a2123b0ca8b3d8792302ef47ce49e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Hillerstr=C3=B6m?= Date: Mon, 1 Feb 2021 13:50:26 +0000 Subject: [PATCH] Summary --- thesis.tex | 31 +++++++++++++++++++++++++------ 1 file changed, 25 insertions(+), 6 deletions(-) diff --git a/thesis.tex b/thesis.tex index 78b219c..36ae468 100644 --- a/thesis.tex +++ b/thesis.tex @@ -4944,7 +4944,7 @@ The $\Absurd$ computation term is used to coerce the return type $\ZeroType$ of $\Fail$ into $\alpha$. This coercion is safe, because $\ZeroType$ is an uninhabited type. % -An interpretation of $\Fail$ amounts to implementing an exception +An interpretation of $\Exit$ amounts to implementing an exception handler. % \[ @@ -6644,11 +6644,30 @@ We can now plug it all together. \ea \] % -Alice makes a hard copy of the file \texttt{ritchie.txt} as -\texttt{ritchie}, and subsequently removes the original file, which -effectively amounts to a roundabout way of renaming a file. Bob makes -a soft copy of the file \texttt{hamlet} as \texttt{act3}, meaning -both names share the same i-node with index $2$. +Alice copies the file \texttt{ritchie.txt} as \texttt{ritchie}, and +subsequently removes the original file, which effectively amounts to a +roundabout way of renaming a file. It is evident from the file system +state that the file is a hard copy as the contents of +\texttt{ritchie.txt} now reside in location $3$ rather than location +$1$ in the data region. Bob makes a soft copy of the file +\texttt{hamlet} as \texttt{act3}, which is evident by looking at the +directory where the two filenames point to the same i-node (with index +$2$), whose link counter has value $2$. + +\paragraph{Summary} Starting from a simple file I/O model we seen how +the modularity of effect handlers enable us to develop a \UNIX{}-style +operating system in an incremental way by composing several handlers +to implement a basic file system, multi-user environments, and +multi-tasking support. Each incremental change to the system has been +backwards compatible with previous changes in the sense that we have +not modified any previously defined interfaces in order to support a +new feature. It serves as a testament to demonstrate the versatility +of effect handlers, and it suggests that handlers can be a viable +option to use with legacy code bases to retrofit functionality. The +operating system uses a total of 14 operations, which are being +handled by 12 handlers, some of which are used multiple times, +e.g. the $\environment$ and $\redirect$ handlers. + % \begin{figure}[t] % \centering