Enabling Retargetable Optimizing Compilers for Quantum Accelerators via a Multi-Level Intermediate Representation
Thien NguyenAlexander McCaskey
Thien Nguyen
Alexander McCaskey
+2
This paper presents a multi-level quantum-classical intermediate representation (IR) built on the MLIR framework, enabling an optimizing, retargetable, ahead-of-time compiler for quantum languages, demonstrated with OpenQASM 3. The IR maps quantum language expressions through progressive lowering to LLVM machine-level IR, supporting both quantum and classical optimizations. Compared to other approaches, the compiler achieves 1000x faster compile times than Pythonic approaches and 5-10x faster than standalone quantum compilers, with a 10x reduction in entangling operations via standard programming patterns.

arXiv ·
· September 1, 2021