From: Ian Jackson Date: Sun, 27 May 2012 17:43:47 +0000 (+0100) Subject: strategy: new, wip, notational fixes X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=topbloke-formulae.git;a=commitdiff_plain;h=64a3ef281cdbfa63f1c306222d6e3e2b507d21a0 strategy: new, wip, notational fixes --- diff --git a/strategy.tex b/strategy.tex index 3412853..9bed7cf 100644 --- a/strategy.tex +++ b/strategy.tex @@ -32,12 +32,12 @@ The set of direct dependencies (in the form $\py$) requested in the commit $K$ ($K \in \pn$) for the patch $\p$. \item[ $\pc \hasdirdep \p$ ] -The Topbloke commit set $\pc$ has as a direct contributor the -commit set $\p$. This is an acyclic relation. +The patch $\pc$ has as a direct dependency the +patch $\p$. This is an acyclic relation. \item[ $\p \hasdep \pq$ ] -The commit set $\p$ has as direct or indirect contributor the commit -set $\pq$. +The patch $\p$ has as direct or indirect dependency the +patch $\pq$. Acyclic; the completion of $\hasdirdep$ into a partial order. @@ -50,6 +50,13 @@ the $\le$-maximal elements of $\bigcup_{J \in \set J} \pendsof{J}{\p}$ Convenience notation for $\bigforall_{E \in \pendsof{\set X}{\p}} E \le T$ +\item[ $\Gamma_{\pc}$ ] +The desired direct dependencies of $\pc$, a set of patches. + +\item[ $\allpatches$ ] +The set of all the patches we are dealing with (constructed +during the update algorithm). + %\item[ $\set E_{\pc}$ ] %$ \bigcup_i \pendsof{S_{\pc,i}}{\pc} $. %All the ends of $\pc$ in the sources. @@ -72,6 +79,7 @@ all of its dependencies will be updated. \item[ $h : \pc^{+/-} \mapsto \set H_{\pc^{+/-}}$ ] Function for getting the existing heads $\set H$ of the branch $\pc^{+/-}$. +These are the heads which will be merged and used in this update. This will include the current local and remote git refs, as desired. \item[ $g : \pc, \Gamma \mapsto \Gamma'$ ] @@ -80,7 +88,7 @@ of $\pc$. It is provided with a putative set of direct dependencies $\Gamma$ computed as an appropriate merge of the dependencies requested by the sources and should return the complete actual set $\Gamma'$ of direct dependencies to use. This allows the specification of any desired -(acyclic) relation $\hasdirdep$. +(acyclic) relations $\hasdirdep$ and $\hasdep$. \end{basedescript} @@ -139,15 +147,17 @@ if available. \item For each $i \ldots 1..n$, update our putative direct dependencies: $$ -\Gamma \assign \text{\bf set-merge}\left(\Gamma, - \left[ \begin{cases} +\Gamma \assign \text{\bf set-merge}\left[\Gamma, + \left( \begin{cases} M_i \in \pcn : & \depsreqof{M_i} \\ M_i \not\in \pcn : & \{ \} - \end{cases} \right], + \end{cases} \right), \depsreqof{S_i} - \right) + \right] $$ +TODO define {\bf set-merge} + \item Finalise our putative direct dependencies $ \Gamma \assign g(\pc, \Gamma) @@ -165,17 +175,31 @@ inappropriate; a different $g$ could work.) \end{enumerate} -The results of the ranking phase are: +\subsection{Results of the ranking phase} + +By the end of the ranking phase, we have recorded the following +information: +\begin{itemize} +\item $ \allpatches, \hasdirdep $ and hence the completion of $\hasdirdep$ into the partial order $\hasdep$. -For each $\pc$, the base branch starting point commit $W_{\pcn} = W$, -the direct dependencies $\Gamma_{\pc}$, +\item +For each $\pc \in \allpatches$, the base branch starting point commit $W_{\pcn} = W$. + +\item +For each $\pc$, +the direct dependencies $\Gamma_{\pc}$. + +\item +For each $\pc$, the ordered set of base branch sources $\set S_{\pcn} = \set S, S_{\pcn,i} = S_i$ and corresponding merge bases $M_{\pcn,i} = M_i$. +\end{itemize} + \section{Traversal phase}