Commit 9e98ff8b authored by Ralf Jung's avatar Ralf Jung
Browse files

docs: describe the unit of a CMRA and how the logic demands one

parent fa0ed70a
......@@ -112,6 +112,16 @@ This operation is needed to prove that $\later$ commutes with existential quanti
(This assumes that the type $\type$ is non-empty.)
An element $\munit$ of a CMRA $\monoid$ is called the \emph{unit} of $\monoid$ if it satisfies the following conditions:
\item $\munit$ is valid: \\ $\All n, \munit \in \mval_n$
\item $\munit$ is left-identity of the operation: \\
$\All \melt \in M. \munit \mtimes \melt = \melt$
\item $\munit$ is discrete
It is possible to do a \emph{frame-preserving update} from $\melt \in \monoid$ to $\meltsB \subseteq \monoid$, written $\melt \mupd \meltsB$, if
\[ \All n, \melt_f. \melt \mtimes \melt_f \in \mval_n \Ra \Exists \meltB \in \meltsB. \meltB \mtimes \melt_f \in \mval_n \]
......@@ -124,7 +134,7 @@ Note that for RAs, this and the RA-based definition of a frame-preserving update
A function $f : M \to N$ between two CMRAs is \emph{monotone} if it satisfies the following conditions:
\item $f$ is non-expansive
\item $f$ preserves validity: \\
$\All n, x \in M. x \in \mval_n \Ra f(x) \in \mval_n$
......@@ -129,6 +129,7 @@
......@@ -26,7 +26,7 @@ It does not matter whether they fork off an arbitrary expression.
A function $\lctx : \textdom{Expr} \to \textdom{Expr}$ is a \emph{context} if the following conditions are satisfied:
\item $\lctx$ does not turn non-values into values:\\
$\All\expr. \toval(\expr) = \bot \Ra \toval(\lctx(\expr)) = \bot $
\item One can perform reductions below $\lctx$:\\
......@@ -64,8 +64,7 @@ For any language $\Lang$, we define the corresponding thread-pool semantics.
To instantiate Iris, you need to define the following parameters:
\item A language $\Lang$
\item A locally contractive functor $\iFunc : \COFEs \to \CMRAs$ defining the ghost state
\ralf{$\iFunc$ also needs to have a single-unit.}
\item A locally contractive functor $\iFunc : \COFEs \to \CMRAs$ defining the ghost state, such that for all COFEs $A$, the CMRA $\iFunc(A)$ has a unit
......@@ -107,6 +106,7 @@ Iris syntax is built up from a signature $\Sig$ and a countably infinite set $\t
\pi_i\; \term \mid
\Lam \var:\type.\term \mid
\term(\term) \mid
\munit \mid
\mcore\term \mid
\term \mtimes \term \mid
......@@ -213,6 +213,8 @@ In writing $\vctx, x:\type$, we presuppose that $x$ is not already declared in $
{\vctx \proves \wtt{\term}{\type \to \type'} \and \wtt{\termB}{\type}}
{\vctx \proves \wtt{\term(\termB)}{\type'}}
%%% monoids
\infer{}{\vctx \proves \wtt\munit{\textlog{M}}}
\infer{\vctx \proves \wtt\melt{\textlog{M}}}{\vctx \proves \wtt{\mcore\melt}{\textlog{M}}}
......@@ -416,7 +418,7 @@ This is entirely standard.
\ownGGhost{\melt} * \ownGGhost{\meltB} &\Lra& \ownGGhost{\melt \mtimes \meltB} \\
%\TRUE &\Ra& \ownGGhost{\munit}\\
\TRUE &\Ra& \ownGGhost{\munit}\\
\ownGGhost{\melt} &\Ra& \melt \in \mval % * \ownGGhost{\melt}
......@@ -22,7 +22,7 @@
\usepackage{xcolor} % for print version
Supports Markdown
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