Formalization of Quantum Intermediate Representations for Code Safety

03/25/2023
by   Junjie Luo, et al.
0

Quantum Intermediate Representation (QIR) is a Microsoft-developed, LLVM-based intermediate representation for quantum program compilers. QIR aims to provide a general solution for quantum program compilers independent of front-end languages and back-end hardware, thus avoiding duplicate development of intermediate representations and compilers. Since it is still under development, QIR is described in natural language and lacks a formal definition, leading to ambiguity in its interpretation and a lack of rigor in implementing quantum functions. In this paper, we provide formal definitions for the data types and instruction sets of QIR, aiming to provide correctness and security guarantees for operations and intermediate code conversions in QIR. To validate our design, we show some samples of unsafe QIR code where errors can be detected by our formal approach.

READ FULL TEXT

page 7

page 10

research
06/07/2022

Q# as a Quantum Algorithmic Language

Q# is a standalone domain-specific programming language from Microsoft f...
research
01/27/2021

A MLIR Dialect for Quantum Assembly Languages

We demonstrate the utility of the Multi-Level Intermediate Representatio...
research
07/27/2018

Sound Transpilation from Binary to Machine-Independent Code

In order to handle the complexity and heterogeneity of mod- ern instruct...
research
04/14/2022

A Formally Certified End-to-End Implementation of Shor's Factorization Algorithm

Quantum computing technology may soon deliver revolutionary improvements...
research
03/08/2019

Formal Constraint-based Compilation for Noisy Intermediate-Scale Quantum Systems

Noisy, intermediate-scale quantum (NISQ) systems are expected to have a ...
research
02/01/2023

InQuIR: Intermediate Representation for Interconnected Quantum Computers

Various physical constraints limit the number of qubits that can be impl...
research
01/16/2019

TrABin: Trustworthy Analyses of Binaries

Verification of microkernels, device drivers, and crypto routines requir...

Please sign up or login with your details

Forgot password? Click here to reset