A parallelization method for quantum homomorphic encryption

By establishing a DAG to optimize the execution order of non-Clifford gates and QOTP key updates, the problem of insufficient parallelization in existing quantum homomorphic encryption schemes is solved, achieving more efficient quantum homomorphic encryption evaluation and improving throughput and resource utilization.

CN121603208BActive Publication Date: 2026-05-12ZHEJIANG ZHIJIANG SHUAN QUANTUM TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG ZHIJIANG SHUAN QUANTUM TECH CO LTD
Filing Date
2026-01-30
Publication Date
2026-05-12

AI Technical Summary

Technical Problem

Existing quantum homomorphic encryption schemes have shortcomings in parallelization and scheduling, failing to fully utilize the parallel potential across quantum lines, resulting in high overall latency. Furthermore, there is coupling between the execution order of non-Clifford gates, the complexity of QOTP key updates, and the FHE bootstrapping strategy, lacking joint optimization.

Method used

By constructing a dependent directed acyclic graph (DAG) of non-Clifford gates, the execution order of non-Clifford gates, the update complexity of QOTP keys, and the number of bootstrapping rounds of classical FHE are jointly optimized. A cross-quantum wire interval partitioning strategy is adopted to ensure that the degree of non-dependency parallelism within the same interval is maximized, thereby reducing the total latency.

Benefits of technology

It significantly reduces the total latency of quantum homomorphic evaluation, improves throughput and hardware resource utilization, has good scalability, can maintain effective parallelism in high-depth non-Clifford gate scenarios, balances the computational pressure of quantum wires, facilitates the combination of multi-core or distributed resources, and improves the overall evaluation efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121603208B_ABST
    Figure CN121603208B_ABST
Patent Text Reader

Abstract

The application belongs to the technical field of quantum computing, and discloses a parallelization method for quantum homomorphic encryption, which is suitable for a combination scheme based on a quantum one-time pad and a classical full homomorphic encryption. The method models the dependency relationship of non-Clifford gates by constructing a directed acyclic graph, and estimates the time-consuming of classical homomorphic computation required for key update of each node. On this basis, the gates on each quantum line are divided into multiple intervals, and it is constrained that at most one non-Clifford gate is contained in each interval, and the gates in the same interval of different quantum lines have no dependency relationship. By optimizing the interval division, the overall execution time of the system is minimized under the premise of meeting the dependency constraint. Finally, the circuit is executed in series according to the interval, and the quantum lines in the interval are operated in parallel, so that the joint optimization of the order of non-Clifford gates, the key update complexity of the quantum one-time pad and the boot-up round of the classical full homomorphic encryption in the evaluation process of the quantum homomorphic encryption is realized, and the evaluation efficiency is effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of quantum computing technology, and in particular to a parallelization method for quantum homomorphic encryption. Background Technology

[0002] Quantum homomorphic encryption aims to execute quantum circuits directly on quantum ciphertext without decryption, balancing functionality and security. Current feasible engineering approaches often employ quantum one-time cryptography to encrypt quantum states and utilize classical fully homomorphic encryption (FHE) to maintain and update the QOTP key in the classical ciphertext domain, thereby achieving transparent evaluation of Clifford gates and controlled correction of non-Clifford gates. The core bottleneck of this approach lies in the fact that non-Clifford gates (such as T-gates) introduce nonlinear terms into key updates, requiring costly homomorphic computations via FHE. Furthermore, after the multiplication depth accumulates to a threshold, bootstrapping is triggered to restore the ciphertext's ability to continue evaluation. Bootstrapping overhead is typically much higher than that of conventional homomorphic operators, and the complexity of key updates is significantly influenced by the circuit structure.

[0003] Existing technologies have shortcomings in parallelization and scheduling. Many methods process T-gates sequentially according to dependencies, resulting in underutilization of the parallelization potential across quantum wires and high overall latency. Common hierarchical or gate-type batching strategies fail to finely characterize the differences in key update complexity triggered by each non-Clifford gate, ignoring the differences in homomorphic computation at the classical end, thus causing unnecessary bootstrapping or serial segments. In addition, there is coupling between the execution order of non-Clifford gates, the homomorphic time of QOTP key updates, and the FHE bootstrapping strategy: bootstrapping too early or too late will increase the total time, and existing schemes usually consider these separately, lacking joint optimization. Summary of the Invention

[0004] To address the aforementioned shortcomings of existing technologies, this invention proposes a parallelization method for quantum homomorphic encryption. For quantum homomorphic encryption schemes based on quantum one-time keybooks and classical fully homomorphic encryption, the method jointly optimizes the execution order of non-Clifford gates, the update complexity of QOTP keys, and the number of classical FHE bootstrapping rounds to reduce the total latency of quantum homomorphic evaluation.

[0005] The technical solution of this invention is implemented as follows:

[0006] A parallelization method for quantum homomorphic encryption is proposed, based on the quantum one-time keybook (QOTP) and the classical fully homomorphic encryption (FHE) quantum homomorphic encryption method. The method jointly optimizes the execution order of non-Clifford gates, the update complexity of the QOTP key, and the number of bootstrapping rounds in the classical FHE. The specific method includes the following steps:

[0007] 1) A circuit for receiving ciphertext quantum state, QOTP key ciphertext, and plaintext, wherein the plaintext circuit is composed of a Clifford gate set and non-Clifford gate G;

[0008] 2) Construct a directed acyclic graph (DAG) of dependencies for non-Clifford gates;

[0009] 3) Nodes of each DAG Calculate the QOTP key symbol expression and estimate the homomorphic update time;

[0010] 4) Divide the non-Clifford gates G of each quantum line into the same number of intervals to optimize the combined time consumption of quantum and classical circuits. The quantum line refers to the horizontal line in the classical circuit that represents the time evolution of each quantum bit.

[0011] 5) Circuit evaluation and QOTP updates are performed serially within each quantum line interval and in parallel between intervals of the same column number in different quantum lines.

[0012] Preferably, in steps 1) and 2), the nodes of the DAG correspond one-to-one with the gates G in the plaintext circuit. For any two nodes A and B, an edge from A to B is established between A and B if and only if the gate G corresponding to B depends on the gate G corresponding to A in execution, and there is no third node C such that there are dependent paths from A to C and from C to B.

[0013] Preferably, in step 3), for each node in the DAG... Additional data, referring to data required for node... The corresponding gates G and Clifford gates update the QOTP key after execution, while the estimated time for homomorphic computation to be performed in the classical ciphertext domain is as follows. The node The corresponding Clifford gate refers to... All Clifford gates between the corresponding gate G and the previous gate G.

[0014] Preferably, in step 4), for each quantum wire, the first... The gates on the quantum wire are divided into each interval ,in It is a fixed integer. The interval division method is equivalent to the first... The interval partitioning of the DAG nodes corresponding to gate G on a quantum line, wherein the DAG nodes are partitioned by dividing the nodes into... each interval This makes a certain node The necessary and sufficient condition is The corresponding gate G belongs to The Choice and range The division method needs to meet the following conditions:

[0015] a) Each interval The interval contains 0 or 1 gate G. When the number of gate G is 1, gate G is the last gate in the interval, and the interval contains all Clifford gates between gate G and the previous gate G. When the number of gate G is 0, the interval is an empty set.

[0016] b) Union No two points in the equation can have a dependency relationship;

[0017] c) Express the estimated execution time of gate G as... The multiplication time threshold that triggers classical homomorphic encryption bootstrapping is expressed as: The estimated time for bootstrapping is expressed as According to , , and The estimated total time for quantum homomorphic evaluation is minimized or nearly minimized under conditions a) and b).

[0018] Preferably, the homomorphic evaluation of the plaintext quantum circuit is performed as follows: for each interval union... Between these intervals, sub-circuit evaluation and corresponding QOTP key updates are performed serially; for each interval union... Within this, the evaluation of quantum gates on each quantum line and the corresponding QOTP key updates are performed in parallel across different quantum lines.

[0019] Preferably, in step (3) The calculation method is as follows:

[0020] (1) For nodes The associated QOTP key is represented using a Boolean variable. The value of the QOTP key before the execution of the corresponding gate G and Clifford gate is calculated, and the symbolic expression of the QOTP key containing the Boolean variable after the execution of the gate G and Clifford gate is calculated.

[0021] (2) The time required to perform homomorphic evaluation of the symbolic expression based on the classical FHE cost model is estimated to obtain... The cost model is determined based on the statistical analysis of the number of primitives such as addition, multiplication, and rotation, combined with the unit time consumption under preset parameters.

[0022] Preferably, the method described in step 4) is based on , , and The estimated total time for quantum homomorphic evaluation is

[0023] ,

[0024] in

[0025] ,

[0026] Indicates for the first The first to the second quantum line The number of bootstrapping operations required for each sub-circuit corresponding to each interval to perform the corresponding QOTP key update.

[0027] Preferably, the DAG node partitioning steps in step 4) are as follows:

[0028] (1) Perform arbitrary topological sorting on all nodes in the DAG;

[0029] (2) Use Indicates that the current situation makes The largest value, initially ;

[0030] (3) Traverse points in topological order For each iteration of the traversal, let's say... for The corresponding quantum wire number, in Searching for legally assignable data The legality of the interval is as follows: The assigned interval number is denoted as Then for Any predecessor in a DAG , Greater than The assigned interval number, for all found valid intervals, will be calculated as follows: The following are the estimated times after placing them into each interval.

[0031] ,

[0032] And select the interval that results in the minimum estimated time; if no valid interval is found, then... Put in And on Update: ;

[0033] (4) After traversing all nodes in step (3), the division of the nodes corresponding to each quantum wire into... The interval method, the for The final value.

[0034] Preferably, the plaintext circuit includes a set of Clifford gates comprising a Hadamard gate H, a phase gate S, and a controlled NOT gate CNOT.

[0035] Preferably, the non-Clifford gate G included in the plaintext circuit is a T gate.

[0036] Compared with the prior art, the present invention has the following beneficial effects:

[0037] This invention proposes a parallelization method for quantum homomorphic encryption, which jointly optimizes the execution order of non-Clifford gates, the complexity of QOTP key updates, and the number of FHE bootstrap rounds, avoiding redundant bootstraps and unnecessary serial segments caused by traditional separate scheduling, and significantly reducing the total latency of quantum homomorphic evaluation.

[0038] By using DAG to characterize dependencies and dividing the quantum wire into intervals accordingly, we can ensure no dependencies within the same interval and maximize parallelism, thus significantly improving throughput and hardware resource utilization.

[0039] It has good scalability, and the partitions expand linearly as the number of qubits and the size of non-Clifford gates increase. It can still maintain effective parallelism in scenarios with high depth of non-Clifford gates.

[0040] It can reduce the peak load on the classical end, balance the computing pressure of each quantum wire, and facilitate the combination of multi-core or distributed resources to improve the overall evaluation efficiency. Attached Figure Description

[0041] Figure 1 This is the overall flow of the parallelization method for quantum homomorphic encryption involved in the embodiments;

[0042] Figure 2 This is the plaintext quantum circuit to be evaluated in the example;

[0043] Figure 3 In response to Figure 2 A diagram illustrating the DAG of T-gate dependencies in a circuit and an example of node partitioning. Detailed Implementation

[0044] The present invention will now be clearly and completely described with reference to the accompanying drawings in the embodiments of the present invention.

[0045] like Figure 1As shown, a parallelization method for quantum homomorphic encryption is proposed. For quantum homomorphic encryption schemes based on Quantum One-Time Keybook (QOTP) and Classical Fully Homomorphic Encryption (FHE), the method jointly optimizes the execution order of non-Clifford gates, the update complexity of the QOTP key, and the number of bootstrapping rounds in Classical FHE. Specifically, the method includes the following steps:

[0046] 1) A circuit for receiving ciphertext quantum state, QOTP key ciphertext, and plaintext, wherein the plaintext circuit is composed of a Clifford gate set and non-Clifford gates G (referred to as gate G);

[0047] 2) Construct a directed acyclic graph (DAG) of non-Clifford gates, where each node of the DAG corresponds one-to-one with a gate G in the plaintext circuit. For any two nodes A and B, establish an edge from A to B between A and B if and only if the G corresponding to B is dependent on the G corresponding to A in execution, and there is no third node C such that there are dependent paths from A to C and from C to B.

[0048] 3) Nodes of each DAG Calculate the QOTP key symbol expression and estimate the homomorphic update time for each node in the DAG. Additional data is provided for use in nodes. The corresponding gates G and Clifford gates update the QOTP key after execution, while the estimated time for homomorphic computation to be performed in the classical ciphertext domain is as follows. The The corresponding Clifford gate refers to... All Clifford gates between the corresponding gate G and the previous gate G;

[0049] 4) Divide the non-Clifford gates G of each quantum wire into the same number of intervals to optimize the synthesis time of quantum and classical circuits. For each , will the The gates on the quantum wire are divided into each interval ,in It is a fixed integer. This interval partitioning method is equivalent to the first... The interval partitioning of the DAG nodes corresponding to gate G on a quantum line, wherein the DAG nodes are partitioned by dividing the nodes into... each interval This makes a certain node The necessary and sufficient condition is The corresponding gate G belongs to The Choice and range The division method needs to meet the following conditions:

[0050] a) Each interval It contains 0 or 1 gate G. When the number of gates G is 1, gate G is the last gate in the interval, and the interval contains all Clifford gates between gate G and the previous gate G; when the number of gates G is 0, the interval is an empty set.

[0051] b) Union No two points in the equation can have a dependency relationship;

[0052] c) Express the estimated execution time of gate G as... The multiplication time threshold that triggers classical homomorphic encryption bootstrapping is expressed as: The estimated time for bootstrapping is expressed as According to , , and The estimated total time for quantum homomorphic evaluation is minimized or nearly minimized under conditions a) and b).

[0053] 5) Circuit evaluation and QOTP updates are performed serially within each quantum line interval and in parallel between intervals with the same column number across different quantum lines. Here, column number refers to… In this context, "v" and "parallelism" refer to the fact that the intervals X(1, v), X(2, v), ..., X(n, v) of different quantum wires are parallel to each other. Specifically, the homomorphic evaluation of the plaintext quantum circuit is performed as follows: for the union of each interval... Between these intervals, sub-circuit evaluation and corresponding QOTP key updates are performed serially; for each interval union... Within this, the evaluation of quantum gates on each quantum line and the corresponding QOTP key updates are performed in parallel.

[0054] In step (2) The calculation method is as follows:

[0055] (1) For nodes The associated QOTP key is represented using a Boolean variable. The value of the QOTP key before the execution of the corresponding gate G and Clifford gate is calculated, and the symbolic expression of the QOTP key containing the Boolean variable after the execution of the gate G and Clifford gate is calculated.

[0056] (2) The time required for homomorphic evaluation of the symbolic expression based on the classic FHE cost model is estimated to be: The cost model is determined based on the statistical analysis of the number of primitives such as addition, multiplication, and rotation, combined with the unit time consumption under preset parameters.

[0057] According to step (3) , , and The estimated total time for quantum homomorphic evaluation is

[0058] ,

[0059] in

[0060]

[0061] Indicates for the first The first to the second quantum line The number of bootstrapping operations required for each sub-circuit corresponding to each interval to perform the corresponding QOTP key update.

[0062] The steps for partitioning the DAG nodes in step (3) are as follows:

[0063] (1) Perform arbitrary topological sorting on all nodes in the DAG;

[0064] (2) Use Indicates that the current situation makes The largest value, initially ;

[0065] (3) Traverse points in topological order For each iteration of the traversal, let's say... for The corresponding quantum wire number, in Searching for legally assignable data The legality of the interval is as follows: The assigned interval number is denoted as Then for Any predecessor in a DAG , Greater than The index of the assigned interval. For all found valid intervals, calculate... The following are the estimated times after placing them into each interval.

[0066] ,

[0067] And select the interval that results in the minimum estimated time; if no valid interval is found, then... Put in And on Update: ;

[0068] (4) After traversing all nodes in step (3), the division of the nodes corresponding to each quantum wire into... The interval method, the for The final value.

[0069] The plaintext circuit includes a set of Clifford gates, including Hadamard gates (H), phase gates (S), and controlled NOT gates (CNOT).

[0070] The plaintext circuit contains non-Clifford gates G, which are T gates.

[0071] Embodiments of the present invention:

[0072] This embodiment provides an example of a parallelization method for quantum homomorphic encryption. The plaintext quantum circuit involved in the quantum homomorphic encryption is composed of Clifford gates H, S, and CNOT, as well as non-Clifford gates T. This embodiment is based on a typical QOTP and FHE hybrid encryption framework, and specifically uses the following quantum homomorphic encryption method.

[0073] First, QOTP is used to encrypt the input quantum plaintext state, generating quantum ciphertext. Assume the... The quantum plaintext state is The corresponding QOTP key is Then the encrypted ciphertext state is

[0074] Secondly, the QOTP key Encryption using a classical FHE is performed and stored on the classical end. The FHE can utilize the Brakerski-Gentry-Vaikuntanathan (BGV) scheme. During the evaluation phase, for the Clifford gate in the plaintext quantum circuit, the quantum gate can be directly applied to the ciphertext state. Then, using the conjugate transformations of operators H, S, and CNOT with respect to X and Z, the required update of the QOTP key after the Clifford gate is applied can be obtained.

[0075] ,in This indicates that the CNOT gate will be applied to the first... and the Bit, of which the first Bit 1 is a control bit, the first bit 2 is a control bit. The bits are controlled bits, and the update is achieved by performing homomorphic computation on the ciphertext of the QOTP key using FHE.

[0076] For T-gates, their conjugate transformations do not map Pauli operators back to the Pauli group; therefore, their homomorphic evaluation cannot be directly achieved by applying the quantum gate to the cryptographic state and updating the QOTP key. To achieve homomorphic evaluation of T-gates, auxiliary qubits (magic states) are prepared. :

[0077] by To control the bits, for Applying a controlled NOT gate, then Become

[0078] Next to To obtain the classical bit value, measurements are performed. As can be seen from the above formula, if the measurement is obtained... (Right now In the case of T-gate homomorphic interaction, no additional quantum gate is required to obtain the result. and All remain unchanged; if the measurement is obtained (Right now In this case, another one needs to be applied. Door, at the same time remain unchanged. Become Combining the above two scenarios, the update required for the QOTP key after the T-gate is applied is as follows:

[0079] ,

[0080] To optimize the performance bottleneck caused by the multiplication operations of T gates and FHE in the above process, the parallelization method in this embodiment is implemented according to the following steps, while... Figure 1 The document provides an overview of the overall process.

[0081] Step 1: Receive containing Ciphertext quantum state of 1 qubit The ciphertext of the corresponding QOTP key and the plaintext circuit to be evaluated, represented by H, S, CNOT, and T gates (e.g. Figure 2 As shown), where For plaintext quantum states, For the QOTP key. Construct a Directed Acyclic Graph (DAG), where each node of the DAG corresponds one-to-one with a T-gate in the plaintext circuit; for any two nodes A and B, establish an edge from A to B if and only if the T-gate corresponding to B is dependent on the T-gate corresponding to A in execution, and there is no third node C such that there are dependent paths from A to C and from C to B. Figure 2 Quantum circuits, DAGs constructed in this way, such as Figure 3As shown, it contains nodes These correspond to the six T gates in the plaintext circuit, respectively.

[0082] Step 2: For each node in the DAG Additional data is provided for use in nodes. The corresponding T-gate and Clifford gate are executed to update the QOTP key, while the estimated time for the homomorphic computation to be performed in the classical ciphertext domain is as follows. The The corresponding Clifford gate refers to... All Clifford gates between the corresponding T gate and the previous T gate. The calculation method is as follows:

[0083] Step 2.1 For nodes The associated QOTP key is represented using a Boolean variable. Before executing the corresponding T-gate and Clifford gate, the QOTP key value is used to calculate the symbolic expression of the QOTP key containing the Boolean variable after the execution of the T-gate and Clifford gate. Specifically, the calculation process of the QOTP key symbolic expression for each node is as follows:

[0084] For nodes The corresponding QOTP key representation before quantum gate execution is as follows: The process of key change after applying each of the quantum gates is as follows:

[0085] ,in The symbolic expression for the QOTP key after the execution of each quantum gate represents the classical bit obtained from the measurement of the corresponding magic state. .

[0086] For nodes The corresponding QOTP key representation before quantum gate execution is as follows: The process of key change after applying each of the quantum gates is as follows:

[0087] ,in The symbolic expression for the QOTP key after the execution of each quantum gate represents the classical bit obtained from the measurement of the corresponding magic state. .

[0088] For nodes The corresponding QOTP key representation before quantum gate execution is as follows: The process of key change after applying each of the quantum gates is as follows:

[0089] ,

[0090] in The symbolic expression for the QOTP key after the execution of each quantum gate represents the classical bit obtained from the measurement of the corresponding magic state. .

[0091] For nodes The corresponding QOTP key representation before quantum gate execution is as follows: The process of key change after applying each of the quantum gates is as follows:

[0092] ,in The symbolic expression for the QOTP key after the execution of each quantum gate represents the classical bit obtained from the measurement of the corresponding magic state. .

[0093] For nodes The corresponding QOTP key representation before quantum gate execution is as follows: The process of key change after applying each of the quantum gates is as follows:

[0094] ,in The symbolic expression for the QOTP key after the execution of each quantum gate represents the classical bit obtained from the measurement of the corresponding magic state. .

[0095] For nodes The corresponding QOTP key representation before quantum gate execution is as follows: The process of key change after applying each of the quantum gates is as follows:

[0096] ,in The symbolic expression for the QOTP key after the execution of each quantum gate represents the classical bit obtained from the measurement of the corresponding magic state. .

[0097] Step 2.2 Based on the classic FHE cost model, the cost of the aforementioned... The time consumption of homomorphic evaluation is estimated for each symbolic expression, and the results are obtained. The cost model is determined based on the statistical analysis of the number of primitives such as addition, multiplication, and rotation, combined with the unit time consumption under preset parameters.

[0098] Step 3 For each , will the The gates on the quantum wire are divided into each interval ,in It is a fixed integer. This interval partitioning method is equivalent to the first... The interval partitioning of the DAG nodes corresponding to the T-gates on a quantum wire, wherein the DAG nodes are partitioned by dividing the nodes into... each interval a certain node If and only The corresponding T-door belongs to .

[0099] The steps for partitioning the DAG nodes are as follows:

[0100] (1) Perform a topological sort on all nodes in the DAG. One valid sorting method is as follows: ,exist Figure 3 and Figure 2 The circled numbers indicate the sequence numbers of each node in this sorting;

[0101] (2) Use Indicates that the current situation makes The largest value, initially ;

[0102] (3) Traverse points in topological order For each iteration of the traversal, let's say... for The corresponding quantum wire number, in Searching for legally assignable data The legality of the interval is as follows: The assigned interval number is denoted as Then for Any predecessor in a DAG , Greater than The index of the assigned interval. For all found valid intervals, calculate... The following are the estimated times after placing them into each interval.

[0103] in This indicates the estimated execution time of gate T. This represents the multiplication time threshold required to trigger bootstrapping in classic homomorphic encryption. This represents the estimated time required for bootstrapping. Additionally,

[0104] Indicates for the first The first to the second quantum line For each interval, determine the number of bootstrapping steps required for the corresponding QOTP key update in the sub-circuit. Select the interval that results in the minimum estimated time; if no valid interval is found, then... Put in And on Update: ;

[0105] (4) After traversing all nodes in step (3), the division of the nodes corresponding to each quantum wire into... The interval method, the for The final value.

[0106] The Choice and range The division method can satisfy the following conditions:

[0107] a) Each interval It contains 0 or 1 T gates. When the number of G gates is 1, G is the last gate in the interval, and the interval contains all Clifford gates between the current T gate and the previous T gate; when the number of G gates is 0, the interval is an empty set.

[0108] b) Union No two points in the equation can have a dependency relationship;

[0109] c) According to , , and The estimated total time consumption of the quantum homomorphic assessment is approximately minimized under constraints a) and b).

[0110] Figure 3 The diagram illustrates one possible way of dividing the data, namely...

[0111]

[0112] Step 4: Perform homomorphic evaluation of the plaintext quantum circuit as follows: for each sub-circuit Between these processes, sub-circuit evaluation and corresponding QOTP key updates are performed serially; for each sub-circuit... Within this, the evaluation of quantum gates on each quantum line and the corresponding QOTP key updates are performed in parallel.

[0113] As can be seen from the embodiments of this invention, this invention proposes a parallelization method for quantum homomorphic encryption. It jointly optimizes the execution order of non-Clifford gates, the complexity of QOTP key updates, and the number of FHE bootstrap rounds, avoiding redundant bootstraps and unnecessary serial segments caused by traditional separate scheduling, significantly reducing the total latency of quantum homomorphic evaluation. Dependencies are characterized by DAGs, and cross-quantum-wire intervals are partitioned accordingly, ensuring no dependencies within the same interval and maximizing parallelism, significantly improving throughput and hardware resource utilization. It possesses good scalability; as the number of qubits and the size of non-Clifford gates increase, the partitions expand linearly, maintaining effective parallelism even in scenarios with high non-Clifford gate depth. It can reduce the peak load on the classical side, balance the computational pressure of each quantum wire, and facilitate the integration of multi-core or distributed resources to improve overall evaluation efficiency.

Claims

1. A parallelization method for quantum homomorphic encryption, characterized in that, A quantum homomorphic encryption method based on the quantum one-time keybook (QOTP) and the classical fully homomorphic encryption (FHE) jointly optimizes the execution order of non-Clifford gates, the update complexity of the QOTP key, and the number of bootstrapping rounds in the classical FHE. The specific method includes the following steps: 1) A circuit for receiving ciphertext quantum states, QOTP key ciphertext, and plaintext, wherein the plaintext circuit includes a Clifford gate set and non-Clifford gates G; 2) Construct a directed acyclic graph (DAG) of dependencies of non-Clifford gates G; 3) Nodes of each DAG Calculate the QOTP key symbol expression and estimate the homomorphic update time; 4) Divide the non-Clifford gates G of each quantum line into the same number of intervals to optimize the combined time consumption of quantum and classical circuits. The quantum line refers to the horizontal line in the classical circuit that represents the time evolution of each quantum bit. 5) Circuit evaluation and QOTP updates are performed serially within each quantum line interval and in parallel between intervals of the same column number across different quantum lines. In step 4), for each quantum wire, the first... The gates on the quantum wire are divided into each interval ,in It is a fixed integer. The interval division method is equivalent to the first... The interval partitioning of the DAG nodes corresponding to gate G on a quantum line, wherein the DAG nodes are partitioned by dividing the nodes into... each interval This makes a certain node The necessary and sufficient condition is The corresponding gate G belongs to The Choice and range The division method needs to meet the following conditions: a) Each interval The interval contains 0 or 1 gate G. When the number of gate G is 1, gate G is the last gate in the interval, and the interval contains all Clifford gates between gate G and the previous gate G. When the number of gate G is 0, the interval is an empty set. b) Union No two points in the equation can have a dependency relationship; c) Express the estimated execution time of gate G as... The multiplication time threshold that triggers classical homomorphic encryption bootstrapping is expressed as: The estimated time for bootstrapping is expressed as According to , , and The estimated total time for quantum homomorphic evaluation is minimized or nearly minimized under conditions a) and b).

2. The parallelization method for quantum homomorphic encryption as described in claim 1, characterized in that, In steps 1) and 2), the nodes of the DAG correspond one-to-one with the gates G in the plaintext circuit. For any two nodes A and B, an edge from A to B is established between A and B if and only if the gate G corresponding to B depends on the gate G corresponding to A in execution, and there is no third node C such that there are dependent paths from A to C and from C to B.

3. The parallelization method for quantum homomorphic encryption as described in claim 1, characterized in that, In step 3), for each node in the DAG... Additional data, referring to data required for node... The corresponding gates G and Clifford gates update the QOTP key after execution, while the estimated time for homomorphic computation to be performed in the classical ciphertext domain is as follows. The node The corresponding Clifford gate refers to... All Clifford gates between the corresponding gate G and the previous gate G.

4. The parallelization method for quantum homomorphic encryption as described in claim 1, characterized in that, The homomorphic evaluation of the plaintext quantum circuit is performed as follows: for each interval union... Between these intervals, sub-circuit evaluation and corresponding QOTP key updates are performed serially; for each interval union... Within this, the evaluation of quantum gates on each quantum line and the corresponding QOTP key updates are performed in parallel across different quantum lines.

5. The parallelization method for quantum homomorphic encryption as described in claim 3, characterized in that, In step (3) The calculation method is as follows: (1) For nodes The associated QOTP key is represented using a Boolean variable. The value of the QOTP key before the execution of the corresponding gate G and Clifford gate is calculated, and the symbolic expression of the QOTP key containing the Boolean variable after the execution of the gate G and Clifford gate is calculated. (2) The time required to perform homomorphic evaluation of the symbolic expression based on the classic FHE cost model is estimated to obtain... The cost model is determined based on the statistical analysis of the number of addition, multiplication, and rotation primitives and the unit time consumption under preset parameters.

6. The parallelization method for quantum homomorphic encryption as described in claim 1, characterized in that, According to step 4) , , and The estimated total time for quantum homomorphic evaluation is , in Indicates for the first The first to the second quantum line The number of bootstrapping operations required for each sub-circuit corresponding to each interval to perform the corresponding QOTP key update.

7. The parallelization method for quantum homomorphic encryption as described in claim 1, characterized in that, The steps for partitioning the DAG nodes described in step 4) are as follows: (1) Perform arbitrary topological sorting on all nodes in the DAG; (2) Use Indicates that the current situation makes The largest value, initially ; (3) Traverse points in topological order For each iteration of the traversal, let's say... for The corresponding quantum wire number, in Searching for legally assignable data The interval, the legality is as follows: The assigned interval number is denoted as Then for Any predecessor in a DAG , Greater than The assigned interval number, for all found valid intervals, will be calculated as follows: The following are the estimated times after placing them into each interval. , And select the interval that results in the minimum estimated time; If no valid interval is found, then Put in And on Update: ; (4) After traversing all nodes in step (3), the division of the nodes corresponding to each quantum wire into... The interval method, the for The final value.

8. The parallelization method for quantum homomorphic encryption as described in claim 1, characterized in that, The plaintext circuit includes a set of Clifford gates, including Hadamard gates (H), phase gates (S), and controlled NOT gates (CNOT).

9. The parallelization method for quantum homomorphic encryption as described in claim 1, characterized in that, The plaintext circuit contains non-Clifford gates G, which are T gates.