Skip to content
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

Allow for disjoint computations within larger programs #258

Open
braised-babbage opened this issue May 21, 2020 · 1 comment
Open

Allow for disjoint computations within larger programs #258

braised-babbage opened this issue May 21, 2020 · 1 comment

Comments

@braised-babbage
Copy link
Contributor

braised-babbage commented May 21, 2020

Just an idea, but as larger devices become increasingly common it might be nice to have the memory demands of the QVM depend on the number of entangled qubits rather than just the number of qubits. One option here is to add a mode or a flag to qvm app which would begins evaluation by computing the connected components of the instruction depencency graph (e.g. a NQ gate places all of its qubits in the same component), then simulates these separately, and then combines the simulation results.

So for example, with this enabled,

CNOT 0 1
CNOT 1 2
CNOT 3 4

would reduce to two separate computations on qubits {0,1,2} and {3,4}.

@notmgsk
Copy link
Member

notmgsk commented May 21, 2020

I think this was prompted by a discussion about MEASUREs on a bunch of non-computational qubits. This would solve that by seeing that each of those MEASUREs could run as a separate computation, and thus the QVM would not need to allocate a single block of memory for e.g. 32 qubits. Is that right?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants