-
Notifications
You must be signed in to change notification settings - Fork 1
✨ C-bindings Implementations #33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
kayaercument
merged 11 commits into
Munich-Quantum-Software-Stack:develop
from
kayaercument:c-bindings
Jul 7, 2026
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
ca259f7
✨ C-bindings
kayaercument e121edf
additional implementations
kayaercument 2630cd5
🎨 minor name change
kayaercument 56b2c96
✏️ fix typo
kayaercument 411b69c
✨ C-Bindings Implementations
kayaercument 7a1a8c7
Merge branch 'c-bindings' of https://github.com/kayaercument/MQSS-Cli…
kayaercument 7ba5ae1
🎨 pre-commit fixes
kayaercument 56f1fa8
Apply suggestions from code review
kayaercument f6024f6
🎨 improve structure and CI pipeline
kayaercument 8c633cd
🔥 remove cmakelist.txt
kayaercument 6515937
⏪ Revert the publish.yml
kayaercument File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -53,6 +53,7 @@ coverage.xml | |
| .hypothesis/ | ||
| .pytest_cache/ | ||
| cover/ | ||
| Testing/* | ||
|
|
||
| # Translations | ||
| *.mo | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,49 @@ | ||
| /* | ||
| * Copyright (c) 2024 - 2026 MQSS Project | ||
| * All rights reserved. | ||
| * | ||
| * Licensed under the Apache License v2.0 with LLVM Exceptions (the "License"); | ||
| * you may not use this file except in compliance with the License. | ||
| * You may obtain a copy of the License at | ||
| * | ||
| * https://llvm.org/LICENSE.txt | ||
| * | ||
| * Unless required by applicable law or agreed to in writing, software | ||
| * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||
| * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||
| * License for the specific language governing permissions and limitations under | ||
| * the License. | ||
| * | ||
| * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
| */ | ||
|
|
||
| #pragma once | ||
|
|
||
| #ifdef __cplusplus | ||
| extern "C" { | ||
| #endif | ||
| #include "job.h" | ||
| #include "resource.h" | ||
|
|
||
| #include <stdbool.h> | ||
|
|
||
| typedef struct MQSSOpaqueClient* MQSSClientRef; | ||
|
|
||
| MQSSClientRef MQSSClientCreateClient(char* token, char* urlOrQueue, bool isHpc); | ||
|
|
||
| MQSSResourceRef* MQSSClientGetAllResources(MQSSClientRef client, int* size); | ||
|
|
||
| MQSSResourceRef MQSSClientGetResourceInfo(MQSSClientRef client, | ||
| const char* resourceName); | ||
|
|
||
| int MQSSClientSubmitJob(MQSSClientRef client, MQSSJobRef job); | ||
|
|
||
| void MQSSClientCancelJob(MQSSClientRef client, MQSSJobRef job); | ||
|
|
||
| MQSSJobResultRef MQSSClientGetJobResult(MQSSClientRef client, MQSSJobRef job, | ||
| bool wait, unsigned int timeout); | ||
|
|
||
| int MQSSClientGetNumberPendingJobs(MQSSClientRef client, char* resourceName); | ||
|
Comment on lines
+30
to
+46
|
||
| #ifdef __cplusplus | ||
| } | ||
| #endif | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,53 @@ | ||
| /* | ||
| * Copyright (c) 2024 - 2026 MQSS Project | ||
| * All rights reserved. | ||
| * | ||
| * Licensed under the Apache License v2.0 with LLVM Exceptions (the "License"); | ||
| * you may not use this file except in compliance with the License. | ||
| * You may obtain a copy of the License at | ||
| * | ||
| * https://llvm.org/LICENSE.txt | ||
| * | ||
| * Unless required by applicable law or agreed to in writing, software | ||
| * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||
| * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||
| * License for the specific language governing permissions and limitations under | ||
| * the License. | ||
| * | ||
| * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
| */ | ||
|
|
||
| #pragma once | ||
|
|
||
| #include <stdint.h> | ||
| #ifdef __cplusplus | ||
| extern "C" { | ||
| #endif | ||
| #include <stdbool.h> | ||
| typedef struct MQSSOpaqueJob* MQSSJobRef; | ||
|
|
||
| typedef struct MQSSOpaqueJobResult* MQSSJobResultRef; | ||
|
|
||
| MQSSJobRef MQSSClientCreateCircuitJob(char* circuit, char* circuitFormat, | ||
| char* resourceName, unsigned int shots, | ||
| bool noModify, bool queued); | ||
|
|
||
| MQSSJobRef MQSSClientCreateHamiltonianJob(char* resourceName, | ||
| char* interactionStr, | ||
| char* coefficientsStr); | ||
|
|
||
| int MQSSClientGetJobResultCounts(MQSSJobResultRef jobResult, char*** bitstreams, | ||
| int** counts, int* size); | ||
|
|
||
| int MQSSClientGetJobResultCompletedTimestamp(MQSSJobResultRef jobResult, | ||
| uint64_t* completedTimestamp); | ||
|
|
||
| int MQSSClientGetJobResultSubmittedTimestamp(MQSSJobResultRef jobResult, | ||
| uint64_t* submittedTimestamp); | ||
|
|
||
| int MQSSClientGetJobResultScheduledTimestamp(MQSSJobResultRef jobResult, | ||
| uint64_t* scheduledTimestamp); | ||
|
|
||
| #ifdef __cplusplus | ||
| } | ||
| #endif |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| /* | ||
| * Copyright (c) 2024 - 2026 MQSS Project | ||
| * All rights reserved. | ||
| * | ||
| * Licensed under the Apache License v2.0 with LLVM Exceptions (the "License"); | ||
| * you may not use this file except in compliance with the License. | ||
| * You may obtain a copy of the License at | ||
| * | ||
| * https://llvm.org/LICENSE.txt | ||
| * | ||
| * Unless required by applicable law or agreed to in writing, software | ||
| * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||
| * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||
| * License for the specific language governing permissions and limitations under | ||
| * the License. | ||
| * | ||
| * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
| */ | ||
|
|
||
| #pragma once | ||
|
|
||
| #ifdef __cplusplus | ||
| extern "C" { | ||
| #endif | ||
| #include <stdbool.h> | ||
|
|
||
| typedef struct MQSSOpaqueResource* MQSSResourceRef; | ||
|
|
||
| typedef struct MQSSOpaqueGate* MQSSGateRef; | ||
|
|
||
| int MQSSClientResourceGetInfo(MQSSResourceRef resource, char** name, | ||
| unsigned* qubitCount, bool* online, | ||
| int** couplingMap, unsigned int* couplingMapSize, | ||
| MQSSGateRef** nativeGateset, | ||
| unsigned int* gateCount); | ||
|
|
||
| int MQSSClientResourceGetGateInfo(MQSSGateRef gate, char** name, | ||
| unsigned* qubitNumber, | ||
| unsigned* parameterNumber, | ||
| int** supportedQubits, | ||
| unsigned int* supportedQubitCount); | ||
|
|
||
| #ifdef __cplusplus | ||
| } | ||
| #endif |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.