Extending C++ for Heterogeneous Quantum-Classical Computing

10/08/2020
by   Thien Nguyen, et al.
0

We present qcor - a language extension to C++ and compiler implementation that enables heterogeneous quantum-classical programming, compilation, and execution in a single-source context. Our work provides a first-of-its-kind C++ compiler enabling high-level quantum kernel (function) expression in a quantum-language agnostic manner, as well as a hardware-agnostic, retargetable compiler workflow targeting a number of physical and virtual quantum computing backends. qcor leverages novel Clang plugin interfaces and builds upon the XACC system-level quantum programming framework to provide a state-of-the-art integration mechanism for quantum-classical compilation that leverages the best from the community at-large. qcor translates quantum kernels ultimately to the XACC intermediate representation, and provides user-extensible hooks for quantum compilation routines like circuit optimization, analysis, and placement. This work details the overall architecture and compiler workflow for qcor, and provides a number of illuminating programming examples demonstrating its utility for near-term variational tasks, quantum algorithm expression, and feed-forward error correction schemes.

READ FULL TEXT

page 3

page 7

page 9

page 19

page 21

page 24

research
01/27/2021

A MLIR Dialect for Quantum Assembly Languages

We demonstrate the utility of the Multi-Level Intermediate Representatio...
research
11/06/2019

XACC: A System-Level Software Infrastructure for Heterogeneous Quantum-Classical Computing

Quantum programming techniques and software have advanced significantly ...
research
02/22/2022

An LLVM-based C++ Compiler Toolchain for Variational Hybrid Quantum-Classical Algorithms and Quantum Accelerators

Variational algorithms are a representative class of quantum computing w...
research
01/27/2023

Enabling Multi-threading in Heterogeneous Quantum-Classical Programming Models

In this paper, we address some of the key limitations to realizing a gen...
research
09/05/2019

QCOR: A Language Extension Specification for the Heterogeneous Quantum-Classical Model of Computation

Quantum computing is an emerging computational paradigm that leverages t...
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
01/30/2019

Noise-Adaptive Compiler Mappings for Noisy Intermediate-Scale Quantum Computers

A massive gap exists between current quantum computing (QC) prototypes, ...

Please sign up or login with your details

Forgot password? Click here to reset