{"id":49475859,"url":"https://github.com/muhos/quasarq","last_synced_at":"2026-04-30T20:00:34.382Z","repository":{"id":292313444,"uuid":"828841975","full_name":"muhos/QuaSARQ","owner":"muhos","description":"Parallel Quantum Simulation and Automated Reasoning on GPUs","archived":false,"fork":false,"pushed_at":"2026-04-23T20:35:45.000Z","size":25375,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-04-23T22:19:40.972Z","etag":null,"topics":["clifford-circuits","equivalence-checker","gpu-computing","measurements","parallel-computing","quantum","simulation","stabilizer-circuits"],"latest_commit_sha":null,"homepage":"","language":"Cuda","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/muhos.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-07-15T08:33:43.000Z","updated_at":"2026-04-23T20:35:49.000Z","dependencies_parsed_at":"2025-05-09T09:35:02.158Z","dependency_job_id":null,"html_url":"https://github.com/muhos/QuaSARQ","commit_stats":null,"previous_names":["muhos/quasarq"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/muhos/QuaSARQ","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/muhos%2FQuaSARQ","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/muhos%2FQuaSARQ/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/muhos%2FQuaSARQ/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/muhos%2FQuaSARQ/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/muhos","download_url":"https://codeload.github.com/muhos/QuaSARQ/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/muhos%2FQuaSARQ/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32475192,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"ssl_error","status_checked_at":"2026-04-30T13:12:06.837Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["clifford-circuits","equivalence-checker","gpu-computing","measurements","parallel-computing","quantum","simulation","stabilizer-circuits"],"created_at":"2026-04-30T20:00:17.928Z","updated_at":"2026-04-30T20:00:34.374Z","avatar_url":"https://github.com/muhos.png","language":"Cuda","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![License: GPL v3](https://img.shields.io/badge/License-GPLv3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0)\n[![Build Status](https://github.com/muhos/QuaSARQ/actions/workflows/test-build.yml/badge.svg)](https://github.com/muhos/QuaSARQ/actions/workflows/test-build.yml)\n# QuaSARQ\nQuaSARQ stands for Quantum Simulation and Automated Reasoning. \nIt is a parallel simulator of quantum stabilizer circuits capable of harnessing NVIDIA CUDA-enabled GPUs to accelerate the simulation of stabilizer gates. \n\n---\n\n## Requirements\n- CUDA-capable GPU with a pre-installed NVIDIA driver\n- [CUDA Toolkit](https://docs.nvidia.com/cuda/) v12 or later\n- [cuarena](https://github.com/muhos/cuarena)  GPU memory allocator library\n- CMake 3.18 or later (to build cuarena)\n- GCC/G++ with C++20 support\n\n---\n\n## Build\n\n### 1. Install CUDA\nFor Ubuntu 24.04:\u003cbr\u003e\n\n`wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2404/x86_64/cuda-keyring_1.1-1_all.deb`\u003cbr\u003e\n`sudo dpkg -i cuda-keyring_1.1-1_all.deb`\u003cbr\u003e\n`sudo apt-get update`\u003cbr\u003e\n`sudo apt-get -y install cuda-toolkit-12-8`\u003cbr\u003e\n\nThe source code is also platform-compatible with Windows and WSL2. To install CUDA on those platforms, follow the\ninstallation guide in https://docs.nvidia.com/cuda/.\n\n### 2. Install QuaSARQ\n\n- Clone the cuarena library before building QuaSARQ:\n\n```\ngit clone https://github.com/muhos/cuarena.git /path/to/cuarena\n```\n\n- Build the simulator by pointing it at the cuarena directory:\n\n```\ncd src \u0026\u0026 make CUARENA_DIR=/path/to/cuarena \u0026\u0026 make install\n```\n\nMake will build cuarena first then the `quasarq` binary and the library `libquasarq.a` will be created by default in the `build` directory.\u003cbr\u003e\n\n### Debug and Testing\nAdd `assert=1` argument with the make command to enable assertions or `debug=1` to collect debugging information.\u003cbr\u003e\n\n```\nmake CUARENA_DIR=/path/to/cuarena assert=1\n```\n\n---\n\n## Usage\nThe simulator can be used via the command `quasarq [\u003ccircuit\u003e.\u003cstim\u003e/\u003cqasm\u003e][\u003coption\u003e ...]`.\u003cbr\u003e\nFor more options, type `quasarq -h` or `quasarq --helpmore`.\n\n---\n\n## Simulation Benchmarking\nQuaSARQ implements two GPU-accelerated simulation modes:\n- **Single-shot simulation**: applies parallel Gaussian elimination via a three-pass prefix-XOR formulation to handle projective measurements, eliminating sequential dependencies present in CPU-based approaches like Stim.\n- **Many-shot sampling**: uses GPU-based Pauli frames to amortize tableau collapse costs across thousands of shots in parallel without repeated Gaussian elimination.\n\nBenchmarks were run on an RTX 4090 (24 GB) against Stim, Qiskit-Aer (CPU/GPU), Qibo, Cirq, and PennyLane, across two suites:\n- **Light suite**: 100–10,000 qubits, depths ∈ {100, 500, 1000}\n- **Heavy suite**: 1,000–180,000 qubits, depths ∈ {100, 500, 1000} (~130M gates at peak)\n\nQuaSARQ completes **177 circuits within 72 hours** on the heavy suite, vs. Stim's 125 circuits in 132 hours, with up to **105× speedup** on tableau evolution and **over 80% energy reduction** on demanding instances. For 1,024-shot sampling, QuaSARQ's Pauli-frame sampler shows flat runtime across circuit sizes while Stim's cost scales steeply.\n\nCheck our paper on [arXiv](https://arxiv.org/abs/2603.14641) for full algorithmic details.\n\n\u003ctable\u003e\n  \u003ctr\u003e\n    \u003ctd\u003e\u003cimg src=\"graphs/light_runtime.png\" alt=\"Light suite runtime (d=100)\" width=\"400\"\u003e\u003c/td\u003e\n    \u003ctd\u003e\u003cimg src=\"graphs/heavy_runtime.png\" alt=\"Heavy suite runtime vs Stim (d=100)\" width=\"400\"\u003e\u003c/td\u003e\n  \u003c/tr\u003e\n\u003c/table\u003e\n\n---\n\n## Equivalence Checking\nQuaSARQ supports equivalence checking of two stabilizer circuits. For example, `quasarq C1.stim C2.stim` checks if `C1 == C2`. \nThe outcome will be `EQUIVALENT` or otherwise `NOT EQUIVALENT`, indicating the failing initial state.\nCheck our paper in [TACAS'25](https://doi.org/10.1007/978-3-031-90660-2_6) for more insights.\nThe following plots compares the performance of QuaSARQ against CCEC (a Stim-based checker) and Quokka-Sharp (universal circuit simulator based on model counting).\nCircuits have qubits in range of 1,000 to 500,000 qubits.\n\n\u003ctable\u003e\n  \u003ctr\u003e\n    \u003ctd\u003e\u003cimg src=\"graphs/time_vs_ccec.png\" alt=\"Runtime for QuaSARQ vs CCEC\" width=\"400\"\u003e\u003c/td\u003e\n    \u003ctd\u003e\u003cimg src=\"graphs/time_vs_quokka.png\" alt=\"Runtime for QuaSARQ vs Quokka-Sharp\" width=\"400\"\u003e\u003c/td\u003e\n  \u003c/tr\u003e\n\u003c/table\u003e\n\u003cbr\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmuhos%2Fquasarq","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmuhos%2Fquasarq","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmuhos%2Fquasarq/lists"}