diff --git a/NEWPROPOSAL/FULLPROP.tex b/NEWPROPOSAL/FULLPROP.tex index 7b2cbdb8532f77a0636c4fed4e223bcc8cdcef0e..60309cf9b316d902f0d6d4b7d85e351c2ef8985b 100644 --- a/NEWPROPOSAL/FULLPROP.tex +++ b/NEWPROPOSAL/FULLPROP.tex @@ -619,29 +619,28 @@ various themes: the relation between \zx and other quantum computing representat \subsubsection{A quantum compiler stack} \label{sec:progr-lang-supp} -In the quantum setting, several powerful high-level languages -(HLLs) such as Quipper~\cite{Alexander-S.-Green:2013fk} and Q\# -\cite{qsharp} have been proposed. As in the case of their -classical counterparts, these HLLs are not designed to be run directly -on quantum hardware, rather their compilers typically output quantum -circuit descriptions. -Rather than designing a new programming language, we propose a quantum -IR, \azx. Unlike the languages mentioned above, \azx is not intended -to be written by humans\footnote{This said, the \zxcalculus has proved - a very useful notation for mathematical proofs.}, instead it will be -generated by a compiler front-end from programs written in existing -high-level languages. Therefore it is essential to provide a robust, -general framework for compilation of HLLs to \azx. - -Since most existing quantum HLLs can output circuit descriptions, and -since circuits can easily be represented in the \zxcalculus, we first -focus on a simple front end for the circuit language -QASM~\cite{Cross2017Open-Quantum-As} in \ref{task:HHL} before moving -towards more expressive HHLs. This -will allow \azx terms to be produced from virtually any extant quantum -HLL, albeit rather naively. Later, we will perform concrete front-end +\newt{% + Several powerful high-level languages (HLLs) have been proposed for quantum programs, such as Quipper~\cite{Alexander-S.-Green:2013fk} and \Qsharp~\cite{qsharp}. +}% +\newt{% + As with classical HLLs, these languages are not designed to be run directly on quantum hardware: instead, their compilers typically output quantum circuit descriptions, which are not tailored well to run on any particular hardware platform. + Rather than designing a new programming language, we propose a compiler system for quantum computers, which could serve as an interface between multiple different HLLs for quantum procedures, and various quantum hardware platforms. + This system would use the \zxcalculus as an internal representation of the procedure as it undergoes optimisations and translations to fit a particular hardware architecture. + This representation would not be required from or exposed to the user,\footnote{This said, the \zxcalculus has proved a very useful notation for mathematical proofs.} + but would be generated by a compiler front-end from programs written in existing high-level languages. + Therefore it is essential to provide a robust, general framework for compilation of HLLs to \zx terms. +}% + +\newt{% + As most existing quantum HLLs can output circuit descriptions, and as circuits can easily be represented in the \zxcalculus, +}% +we first focus on a simple front end for the circuit language QASM~\cite{Cross2017Open-Quantum-As} in \ref{task:HHL} before moving towards more expressive HHLs. +\newt{% + This will allow virtually any extant quantum HLL to interface with our quantum compiler system, albeit rather naively at first. +}% +Later, we will perform concrete front-end experiments using more sophisticated existing HLLs in, for example -\emph{Quipper}, Q\#~\cite{qsharp}, or ProjectQ +\emph{Quipper}, \Qsharp~\cite{qsharp}, or ProjectQ \cite{Steiger2016ProjectQ:-An-Op}, with the help of Task~\ref{task:betterboxes}. @@ -649,18 +648,10 @@ The open database of tests developed in \ref{task:testBench} will serve as a measuring tool for the quality of the output. The database will also be made available to the community for rating and testing future compilers or optimisation techniques. To encourage interaction -from other research groups, and to support other languages, both our -interface and the \azx language will be made public. - -%% OUTDATED -% This work package consists of a back-and-forth interaction between -% HLLs and \azx, which is why many of its tasks span the entire lifetime -% of the project. HLL development influences \azx by providing the -% control structures and other constructs that must be represented at -% \azx level. Conversely, \azx developments will influence HLL, as we -% analyse how information and requirements from the back-end flow upward -% in a meaningful way, and how this can be translated into compilation -% flags and assertions/hints to the compiler within HLL programs. +from other research groups, and to support other languages, +\newt{% + the interfaces and functionality for our quantum compiler system will be made public. +}% Proposed and existing quantum devices differ along a variety of axes. At the most abstract level, the quantum circuit model and the @@ -674,23 +665,29 @@ Primitive operations will require different amounts of time, different qubit implementations have different failure modes.\REM{noise,fidelitY} -Due to the novelty of our proposal, we adopt an exploratory approach -with respect to back-end models. -Initially, and -in parallel, we study the circuit model (\ref{task:circuit-model}) and -the 1-way model (\ref{task:mbqc-model}) because these models are well -understood, stable, and have been extensively treated in the -\zxcalculus literature. We will use these examples to develop -prototypical \azx constructs expressing the relevant properties. This -consists in three tightly related tasks: decomposing the tensor -network into atomic operations; characterising runnability with -respect to the model by predicates in monadic second order logic; and -transforming the tensor network into an equivalent runnable version. +Due to the novelty of our proposal, we adopt an exploratory approach with respect to back-end models. +Initially, and in parallel, we study the circuit model (\ref{task:circuit-model}) and +the 1-way model (\ref{task:mbqc-model}) because these models are well understood, stable, and have been extensively treated in the \zxcalculus literature. +\newt{% + These models will provide the prototypes for the use of annotations on top of \zx terms which will be used by our compiler system. + In both cases, this involves three tightly related tasks: + \begin{enumerate}[label=(\roman*)] + \item + decomposing the tensor network into atomic operations; + \item + characterising runnability in the model, by predicates in monadic second order logic; and + \item + transforming the tensor network into an equivalent runnable version. + \end{enumerate} +} This experience will inform the later work in \ref{wp:theory} and \ref{wp:usefulstuff}. -Although we will provide specific modules for the tasks described above, the -\azx system is intended to extensible, so we will also publish an open +Although we will provide specific modules for the tasks described above, +\newt{% + our quantum compiler system +}% +is intended to extensible, so we will also publish an open API and specification language to simplify the task of adding new architectures and error correcting schemes to the system (\ref{task:backendapi}). @@ -1134,7 +1131,7 @@ users for the final products. The board comprises: \item Andreas Wallraff (ETH Z\"urich), \item Philip Walther (Vienna), \item \bR Will Zeng (Rigetti Quantum Computing) --- may be fired soon\e. -\item \bR Morre suggestions: Winfried Hensinger, Mike Mosca, Martin Roetteler\e. +\item \bR More suggestions: Winfried Hensinger, Mike Mosca, Martin Roetteler, Michael Beverland\e. \end{itemize} Letters of support from the board members are attached at the end of this document.} @@ -1309,7 +1306,7 @@ In the first instance we make contact between \zx and standard circuit and measu \WPtask[\label{task:HHL}]{Front-end (M3--M36; responsible 3; involved 2,4,5) }{% Propose compiler front-end from known HLLs such as QASM, Quipper - or Q\# to \azx. This task serves as a test-bed + or \Qsharp to \azx. This task serves as a test-bed for~\ref{task:testBench} and~\ref{task:trans1}. % } diff --git a/NEWPROPOSAL/preamble.tex b/NEWPROPOSAL/preamble.tex index 3136e491787b37e6440a6804b72c0e1edafe5344..b3938bc90f35ed9300fc759333d277b313933ef5 100644 --- a/NEWPROPOSAL/preamble.tex +++ b/NEWPROPOSAL/preamble.tex @@ -274,8 +274,9 @@ \newcommand{\zx}{\textsc{zx}\xspace} \newcommand{\zxcalculus}{\textsc{zx}-calculus\xspace} -\newcommand{\azx}{\texttt{\bfseries\color{red!70!black}AZX}\xspace} -\newcommand{\liquid}{\texttt{\bfseries\color{red!70!black}Q\#}\xspace} +\newcommand{\azx}{\texttt{\bfseries\color{red!70!black}[macro \textbackslash AZX occurs here]}\xspace} +\newcommand{\liquid}{\texttt{\bfseries\color{red!70!black}[do you mean \textbackslash Qsharp?]}\xspace} +\newcommand{\Qsharp}{Q\texttt\#\xspace} \newcommand{\benREM}[1]{\texttt{\bfseries\color{red!70!black} [{#1}]}\xspace}