Time sequence ECO method and system based on re-synthesis and medium
Through the timing ECO method based on re-synthesis, the new netlist is used to optimize the critical path of the old netlist, which solves the problem that the traditional timing ECO method cannot effectively repair serious timing violations, achieves fast and low-cost timing repair, and shortens the chip design. cycle.
Patent Information
- Application Number
- CN202410861069.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-28
- Publication Date
- 2024-10-15
- Estimated Expiration
- 2044-06-28
AI Technical Summary
The traditional timing ECO method cannot effectively repair serious timing violations, which requires a lot of logic reconstruction, increases costs and prolongs the design cycle. Timing violations caused by changes in front-end timing requirements cannot be repaired by conventional means in the later stages of physical design.
The timing ECO method based on re-synthesis is used to optimize the critical path of the old netlist through the new netlist, the equivalent point is located using a combination of simulation and SAT solver, and cut set matching is performed through the network flow model and the maximum flow algorithm. Logic blocks are merged to fix timing violations, preserving the original logic of the old netlist as much as possible.
It realizes the rapid repair of timing violations with as little modification to the old netlist as possible, saving manpower and time, shortening the chip design cycle, being suitable for various digital chip designs, and reducing the difficulty of timing closure in the physical design stage.
Smart Images

Figure CN118780222A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of integrated circuit design automation, and in particular to a timing ECO method, system and medium based on re-synthesis. Background Art
[0002] ECO (Engineering Change Order) refers to the process in which designers make small adjustments to the circuit and standard cell layout based on the problems exposed in static timing analysis and post-simulation in the late stage of design, make small-scale optimizations while keeping the original design layout and routing results basically unchanged, fix the remaining violations of the chip, and finally meet the chip sign-off standards. With the increasing complexity of IC (Integrated Circuit) design, ECO (Engineering Change Order) technology has become a necessary technology to solve functional and / or timing defects found in the late stage of design. In order to fix the timing violations that appear in the late stage of design, back-end designers usually adjust the gate size and insert buffers during the ECO process. However, these methods are still not powerful enough in the face of some more serious timing violations. For example, the synthesis engineer sets the wrong timing constraints, or the front-end timing requirements change.
[0003] When the above situation occurs, the traditional timing ECO method can no longer meet the needs. This often requires a lot of logic reconstruction of the netlist to reduce the number of logic levels. If it is left to the designer to complete manually, it will result in a huge workload and is prone to errors. At present, the industry's usual solution to such situations is to start the physical design again, which will undoubtedly increase the cost of the project and extend the chip design cycle. Therefore, in order to reduce costs, speed up the design cycle, and reduce the extra workload of designers, it is necessary to study more powerful incremental timing ECO technology to improve the upper limit of timing violation processing.
[0004] For integrated circuit design, due to the long physical design cycle, physical design is usually implemented only after the register transfer level (RTL) netlist is frozen. However, if the front-end timing requirements change or it is found that incorrect timing constraints are used during synthesis in the later stage of physical design, the back-end will have serious timing violations, which usually cannot be repaired by conventional timing optimization methods. Summary of the invention
[0005] Technical problem to be solved by the present invention: In view of the above-mentioned problems in the prior art, a timing ECO method, system and medium based on re-synthesis are provided. The present invention aims to use the optimized logic structure in the new netlist to partially replace the key path in the old netlist, while retaining the original logic in the old netlist as much as possible, so as to achieve the purpose of timing repair on the basis of modifying the old netlist as little as possible, and realize low cost, high efficiency, and short-time solution to serious timing violation problems occurring in the later stage of chip design, saving a lot of manpower and time investment, and shortening the chip design cycle.
[0006] In order to solve the above technical problems, the technical solution adopted by the present invention is: A timing ECO method based on re-synthesis includes the following steps: S101, read circuit information, including the old netlist G1 that needs to be subjected to timing ECO, re-synthesize the new netlist G2 based on the RTL code of the old netlist G1 with tightened timing constraints, set the equivalence information file, standard cell library, timing constraint file and timing violation path information in the setting script; convert the read circuit information into a data structure in the program; S102, matching the old netlist G1 with the new netlist G2; S103, locating the combinational logic block C1 where the timing violation path is located in the old netlist G1, and extracting the combinational logic block C2 matching the combinational logic block C1 in the new netlist G2 according to the matching relationship; S104, using a method combining simulation and SAT solver to locate equivalent points, and storing mapping relationships between equivalent points. Two points with a mapping relationship are called equivalent points to each other. The equivalent point means that the net of the combinatorial logic block C1 is Boolean equivalent to one or more nets in the combinatorial logic block C2. S105, establishing a network flow model M1 for the combinational logic block C1, and establishing a network flow model M2 for the combinational logic block C2; S106, respectively calculating the timing information of the combinational logic block C1 and the combinational logic block C2, and assigning weights to the edges in the network flow models M1 and M2 according to the calculated timing information; S107, using the maximum flow algorithm to calculate the maximum flow for the network flow models M1 and M2 respectively, generate the corresponding residual network, use the residual network to calculate the cut set, and perform cut set matching, through the matching relationship, merge the right part of the combinational logic block C1 and the left part of the combinational logic block C2 along the tangent to generate a new combinational logic block C1′, wherein the part belonging to the combinational logic block C2 before the merger is the modified part of the circuit; S108, applying the new combinational logic block C1' to the old netlist G1 as the netlist G1' after timing ECO output.
[0007] Optionally, when matching the old netlist G1 and the new netlist G2 in step S102 , key points including sequential units, module input and output ports, and input and output ports of IP modules are matched by a name matching method.
[0008] Optionally, step S104 includes: S201, connecting the main inputs of the combinatorial logic block C1 and the main inputs of the combinatorial logic block C2 in pairs according to a matching relationship to generate a set of new main inputs PI′; S202, assigning a set of random analog values to the new main input PI′ so that the main inputs of the combinational logic block C1 and the combinational logic block C2 obtain the same random analog values; S203, propagating the random analog value to each wire net in the circuit of the combinational logic block C1 and the combinational logic block C2 according to the circuit logic relationship, and recording the analog value of each wire net; S204, grouping the wire nets according to the simulation values, and the wire nets with the same simulation values are a candidate equivalence group CG; S205, assign an input mask to each input in the new primary input PI′, propagate the input mask backward, and calculate the input signature for each line net; S206, further classify the obtained candidate equivalence group CG according to the input signature, remove the potential non-equivalence points therein, and obtain a new candidate equivalence group CG′; S207, use the SAT solver to verify the wire nets in the new candidate equivalence group CG′ in pairs, and consider N equivalence to mark the wire nets that meet the verification results as equivalent points, and store the equivalent information of the equivalent points in the circuit equivalence information EQ_Info obtained by locating the equivalent points. The circuit equivalence information EQ_Info stores the equivalent relationship between each group of equivalent points, and each group of equivalent points is accompanied by an equivalent mark, which is a direct equivalent mark POSITIVE_EQUAL or an N equivalent mark NEGATIVE_EQUAL; the N equivalence means that the logics of the two wire nets are mutually inverted.
[0009] Optionally, step S105 includes: S301, establishing a directed graph D1 for the combinatorial logic block C1, and establishing a directed graph D2 for the combinatorial logic block C2, wherein the nodes in the directed graph D1 and the directed graph D2 correspond to the logic units in the combinatorial logic block circuit, and the edges correspond to the connections between the pins, and the mapping relationship between the combinatorial logic blocks C1, C2 and the directed graphs D1, D2 is saved; S302, add a source node S to the directed graph D1, add directed edges to all input nodes in the directed graph D1 so that the source node S points to all input nodes through the directed edges, add a sink node T to the directed graph D1, add directed edges to all output nodes in the directed graph D1 so that all output nodes point to the sink node T through the directed edges; add a source node S to the directed graph D2, add directed edges to all input nodes in the directed graph D2 so that the source node S points to all input nodes through the directed edges, add a sink node T to the directed graph D2, add directed edges to all output nodes in the directed graph D2 so that all output nodes point to the sink node T through the directed edges; S303, adding reverse edges to each edge in directed graph D1 and directed graph D2, storing all edges into an array, and making the forward edge index adjacent to the corresponding reverse edge index, thereby obtaining the network flow model M1 of the combinational logic block C1 and the network flow model M2 of the combinational logic block C2.
[0010] Optionally, step S106 includes: S401, calculating equivalent logic levels for the combinational logic block C1 and the combinational logic block C2; S402, using the maximum equivalent logic level of the combinatorial logic block C2 to calculate the line network relaxation value Slack for the combinatorial logic block C1 and the combinatorial logic block C2, for a logic gate G with N inputs and M outputs i , the relaxation value of any input network j The calculation function expression is: , In the above formula, Indicates taking the minimum value, ~ They are logic gates G i The relaxation value of output port 0~M-1, Indicates taking the maximum value, ~ Do not use logic gate G i The equivalent logic level of input port 0~N-1, represents the equivalent logic level of input line network j; S403, using the circuit equivalent information EQ_Info obtained in step S207 to assign weights to the edges in the directed graph D1, if a certain wire net in the combinatorial logic block C1 has a wire net in another combinatorial logic block C2 that is an equivalent point to each other, the weight is set to 0, otherwise the weight is set to a preset maximum integer constant F_Max; S404, using the timing information obtained in step S401 and step S402, the relaxation value of the corresponding network is updated according to the following formula for any edge i assigned a weight of 0 in step S403: : , In the above formula, is the original slack value of the network before it is updated. i If it is greater than 1, it means that the edge is a non-timing violation path. i If it is equal to 1, it means that the edge is a timing violation path. Then, it is determined whether the timing optimization of any edge i assigned a weight of 0 meets the standard. If the timing optimization does not meet the standard, if edge i is a non-timing violation path, the weight of edge i is updated according to the following formula: , If edge i is a timing violation path, the weight of edge i is updated according to the following formula: , When the timing optimization has been achieved, the weight of edge i is updated according to the following formula: , in, is the weight of edge i, , , is a constant factor, It indicates the degree of improvement of the logic level of a certain network net in the combinational logic block C2 relative to the equivalent logic level of the network net in the combinational logic block C1. is the equivalent logical series of edge i, is the maximum number of logic levels of the combinational logic block C1, is the maximum number of logic levels of the combinational logic block C2.
[0011] Optionally, when calculating the equivalent logic levels for the combinational logic blocks C1 and C2 in step S401, for an N-input logic gate G i , the calculation function expression of the equivalent logic level of the output line network j is: , In the above formula, Represents the equivalent logic level of network j; Indicates taking the maximum value, ~ They are logic gates G i The equivalent logic level of input port 0~N-1, Represents logic gate G i The delay of the logic gate itself (used to replace the internal delay of the logic gate), its value is G i 1 / 2 of the input pins; Represents the fanout number of net j (used to replace the load capacitance of the net).
[0012] Optionally, step S107 includes: S501, run the maximum flow algorithm for the network flow model M1 to obtain the residual network M1′. If the maximum flow value F1 returned by the maximum flow algorithm is greater than the preset maximum integer constant F_Max, it is determined that there is no solution, and the process ends and exits; otherwise, jump to step S502; S502, starting from the source node of the residual network M1′, performing depth-first traversal, and ending the traversal and returning when encountering an edge with a flow of 0, wherein the edge with a flow of 0 refers to an edge with a weight of 0 in the residual network M1′, and marking the traversed nodes; S503, traverse all the forward edges in the residual network M1′. If one of the nodes connected at both ends is marked and the other is not marked, then the edge is a cut edge. All the cut edges form a cut set T1. At the same time, the line network net corresponding to the edge in the cut set T1 is recorded and stored in the set S1. S504, using the circuit equivalent information EQ_Info obtained in step S207, traverse all edges in the network flow model M2, and if its line net is an equivalent point to the line net in the set S1, set the weight of the edge to 0; S505, running the maximum flow algorithm for the network flow model M2 to obtain the residual network M2′. If the maximum flow value F2 returned by the maximum flow algorithm is greater than the preset maximum integer constant F_Max, it is determined that there is no solution, and the process ends and exits; otherwise, jump to step S506; S506, starting from the source node in the residual network M2′, performing depth-first traversal, ending the traversal and returning when encountering an edge with a flow of 0, and marking the traversed nodes; S507, traverse all the forward edges in the residual network M2′. If one of the nodes connected at both ends is marked and the other is not marked, then the edge is a cut edge, and all the cut edges form a cut set T2; S508, using the circuit equivalence information EQ_Info obtained in step S207, matching the edges in the cut set T1 and the cut set T2 to generate a matching relationship R, in which the matching relationship R stores the equivalence relationship of all the edges in the cut set T1 and the cut set T2; S509, using cut set T1, cut set T2 and matching relationship R, cut and merge the combinational logic block C1 and the combinational logic block C2. When merging, if the wire network equivalence relationship corresponding to the two pins to be connected is the direct equivalence mark POSITIVE_EQUAL, then they are directly connected; if the wire network equivalence relationship corresponding to the two pins to be connected is the N equivalence mark NEGATIVE_EQUAL, then it is necessary to insert an inverter in the middle of the connection. The merged combinational logic block is the new combinational logic block C1′, in which the part belonging to the combinational logic block C2 before the merger is the modified part of the circuit.
[0013] In addition, the present invention also provides a timing ECO system based on re-synthesis, comprising a microprocessor and a memory connected to each other, wherein the microprocessor is programmed or configured to execute the timing ECO method based on re-synthesis.
[0014] In addition, the present invention also provides a computer-readable storage medium, in which a computer program or instruction is stored. The computer program or instruction is programmed or configured to execute the re-synthesis-based timing ECO method through a processor.
[0015] In addition, the present invention also provides a computer program product, including a computer program or an instruction, wherein the computer program or the instruction is programmed or configured to execute the timing ECO method based on re-synthesis through a processor.
[0016] Compared with the prior art, the present invention has the following advantages: the present invention aims at the serious timing violation problem appearing in the later stage of physical design, provides a method for quickly repairing timing violation, with the help of the powerful timing optimization capability of the synthesis tool, and assists the old netlist in timing optimization through the re-synthesis strategy, which can quickly reduce the difficulty of timing convergence in the physical design stage and accelerate the timing convergence speed. The present invention is suitable for various types of digital chip designs, accurately locates the timing violation path, and minimizes the impact on the old netlist. The present invention saves a lot of manpower and time costs and shortens the chip design cycle. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 It is a schematic diagram of the implementation process in the embodiment of the present invention.
[0018] Figure 2 This is a schematic diagram of extracting combinational logic blocks using matching points as boundaries in an embodiment of the present invention.
[0019] Figure 3 Schematic diagram of an equivalent point search strategy in an embodiment of the present invention.
[0020] Figure 4 Schematic diagram of the input signature calculation method in an embodiment of the present invention.
[0021] Figure 5 Schematic diagram of a network flow model with added source and sink nodes in an embodiment of the present invention.
[0022] Figure 6 Schematic diagram of the circuit cutting and merging algorithm flow in an embodiment of the present invention.
[0023] Figure 7 Schematic diagram of the post-ECO combinational logic block in an embodiment of the present invention. DETAILED DESCRIPTION
[0024] The present invention relates to the field of integrated circuit design automation, and specifically to a method for optimizing timing by using a resynthesized new netlist to assist an old netlist that needs timing repair, and is used to optimize and repair severe timing violations found in the later stages of integrated circuit design. Figure 1 As shown, the timing ECO method based on re-synthesis in this embodiment includes the following steps: S101, read circuit information, including the old netlist G1 that needs to be subjected to timing ECO, and re-synthesize the new netlist G2 generated by the RTL code of the old netlist G1 with tightened timing constraints, set the equivalence information (SetupVerification for Formality) file (.svf file), standard cell library (.lib file), timing constraint file (.sdc file) and timing violation path information in the setup script; convert the read circuit information into the data structure in the program; S102, matching the old netlist G1 with the new netlist G2; S103, locate the combinatorial logic block C1 where the timing violation path is located in the old netlist G1, and extract the combinatorial logic block C2 matching the combinatorial logic block C1 in the new netlist G2 according to the matching relationship; Figure 2 As shown, when locating the combinatorial logic block C1 where the timing violation path is located in the old netlist G1, the timing violation path (critical path) in the old netlist G1 is located, and the combinatorial logic involved in the path can be extracted as a combinatorial logic block C1; S104, using a method combining simulation and SAT solver to locate equivalent points, and storing a mapping relationship between equivalent points. Two points with a mapping relationship are called equivalent points to each other. The equivalent point refers to the Boolean equivalence of the net of the combinational logic block C1 and one or more nets in the combinational logic block C2. S105, establishing a network flow model M1 for the combinational logic block C1, and establishing a network flow model M2 for the combinational logic block C2; S106, respectively calculating the timing information of the combinational logic block C1 and the combinational logic block C2, and assigning weights to the edges in the network flow models M1 and M2 according to the calculated timing information; S107, using the maximum flow algorithm to calculate the maximum flow for the network flow models M1 and M2 respectively, generate the corresponding residual network, use the residual network to calculate the cut set, and perform cut set matching, through the matching relationship, merge the right part of the combinational logic block C1 and the left part of the combinational logic block C2 along the tangent to generate a new combinational logic block C1′, wherein the part belonging to the combinational logic block C2 before the merger is the modified part of the circuit; S108, applying the new combinational logic block C1' to the old netlist G1 as the netlist G1' after timing ECO output.
[0025] In step S102 of this embodiment, when matching the old netlist G1 and the new netlist G2, key points including sequential units, module input and output ports, and input and output ports of IP modules are matched by a name matching method.
[0026] In this embodiment, step S104 includes: S201, connect the primary inputs of the combinational logic block C1 and the primary inputs of the combinational logic block C2 in pairs according to a matching relationship to generate a new set of primary inputs PI′; S202, assigning a set of random analog values to the new main input PI′ so that the main inputs of the combinational logic block C1 and the combinational logic block C2 obtain the same random analog values; S203, propagating the random analog value to each wire net in the circuit of the combinational logic block C1 and the combinational logic block C2 according to the circuit logic relationship, and recording the analog value of each wire net; S204, grouping the wire nets according to the simulation values, and the wire nets with the same simulation values are a candidate equivalence group CG; S205, assign an input mask to each input in the new primary input PI′, propagate the input mask backward, and calculate the input signature for each net. Figure 4 A diagram of a computation input signature. Figure 4 In the example, the input mask chalk of PI0~PI4 is 00001, 00010, 00100, 01000, 100000. For example, the input signature of signal in2 obtained by PI1 and PI2 through the NAND gate is 00110, the input signature of signal out obtained by PI0 (00001) and signal in2 (00110) through the NAND gate G is 00111, and so on; S206, further classify the obtained candidate equivalence group CG according to the input signature, remove the potential non-equivalence points therein, and obtain a new candidate equivalence group CG′; S207, using the SAT solver to verify the nets in the new candidate equivalence group CG′ in pairs, and considering N equivalence, marking the nets that meet the verification results as equivalent points, and storing the equivalent information of the equivalent points in the circuit equivalent information EQ_Info obtained by locating the equivalent points. The circuit equivalent information EQ_Info stores the equivalent relationship between each group of equivalent points, and each group of equivalent points is accompanied by an equivalent mark, which is a direct equivalent mark POSITIVE_EQUAL or an N equivalent mark NEGATIVE_EQUAL; the N equivalent means that the logic of the two nets is mutually inverted. Figure 3As shown, the SAT solver can solve whether the net of the combinational logic block C1 is equivalent to a net in the combinational logic block C2. Figure 2 The “random input vector” in is the random simulation value in step S202.
[0027] In this embodiment, step S105 includes: S301, establishing a directed graph D1 for the combinatorial logic block C1, and establishing a directed graph D2 for the combinatorial logic block C2, wherein the nodes in the directed graph D1 and the directed graph D2 correspond to the logic units in the combinatorial logic block circuit, and the edges correspond to the connections between the pins, and the mapping relationship between the combinatorial logic blocks C1, C2 and the directed graphs D1, D2 is saved; S302, add a source node S to the directed graph D1, add directed edges to all input nodes in the directed graph D1 so that the source node S points to all input nodes through the directed edges, add a sink node T to the directed graph D1, add directed edges to all output nodes in the directed graph D1 so that all output nodes point to the sink node T through the directed edges; add a source node S to the directed graph D2, add directed edges to all input nodes in the directed graph D2 so that the source node S points to all input nodes through the directed edges, add a sink node T to the directed graph D2, add directed edges to all output nodes in the directed graph D2 so that all output nodes point to the sink node T through the directed edges; an example is as follows Figure 5 As shown, S is the source node, T is the sink node, V1-V12 are nodes, the dotted arrows represent the edges starting from the source node S or reaching the sink node T, and the solid arrows represent the edges of the common nodes V1-V12; S303, adding reverse edges to each edge in directed graph D1 and directed graph D2, storing all edges into an array, and making the forward edge index adjacent to the corresponding reverse edge index, thereby obtaining the network flow model M1 of the combinational logic block C1 and the network flow model M2 of the combinational logic block C2.
[0028] In this embodiment, step S106 includes: S401, calculating equivalent logic levels for the combinational logic block C1 and the combinational logic block C2; S402, using the maximum equivalent logic level of the combinatorial logic block C2 to calculate the line network relaxation value Slack for the combinatorial logic block C1 and the combinatorial logic block C2, for a logic gate G with N inputs and M outputs i , the relaxation value of any input network j The calculation function expression is: , In the above formula, Indicates taking the minimum value, ~ They are logic gates G iThe relaxation value of output port 0~M-1, Indicates taking the maximum value, ~ Do not use logic gate G i The equivalent logic level of input port 0~N-1, represents the equivalent logic level of input line network j; S403, using the circuit equivalent information EQ_Info obtained in step S207 to assign weights to the edges in the directed graph D1, if a certain wire net in the combinatorial logic block C1 has a wire net in another combinatorial logic block C2 that is an equivalent point to each other, the weight is set to 0, otherwise the weight is set to a preset maximum integer constant F_Max; S404, using the timing information obtained in step S401 and step S402, the relaxation value of the corresponding network is updated according to the following formula for any edge i assigned a weight of 0 in step S403: : , In the above formula, is the original slack value of the network before it is updated. i If it is greater than 1, it means that the edge is a non-timing violation path. i If it is equal to 1, it means that the edge is a timing violation path. Then, it is determined whether the timing optimization of any edge i assigned a weight of 0 meets the standard. If the timing optimization does not meet the standard, if edge i is a non-timing violation path, the weight of edge i is updated according to the following formula: , If edge i is a timing violation path, the weight of edge i is updated according to the following formula: , When the timing optimization has been achieved, the weight of edge i is updated according to the following formula: , in, is the weight of edge i, , , is a constant factor, It indicates the degree of improvement of the logic level of a certain network net in the combinational logic block C2 relative to the equivalent logic level of the network net in the combinational logic block C1. is the equivalent logical series of edge i, is the maximum number of logic levels of the combinational logic block C1, is the maximum number of logic levels of the combinational logic block C2.
[0029] When calculating the logic level for the combinational logic block C1 and the combinational logic block C2, in order to make the logic level closer to the actual timing information, the equivalent logic level is calculated instead in this embodiment. Specifically, when calculating the equivalent logic level for the combinational logic block C1 and the combinational logic block C2 in step S401 of this embodiment, for an N-input logic gate G i , the calculation function expression of the equivalent logic level of the output line network j is: , In the above formula, Represents the equivalent logic level of network j; Indicates taking the maximum value, ~ They are logic gates G i The equivalent logic level of input port 0~N-1, Represents logic gate G i The delay of the logic gate itself (used to replace the internal delay of the logic gate), its value is G i 1 / 2 of the input pins; Represents the fanout number of net j (used to replace the load capacitance of the net).
[0030] like Figure 6 As shown, step S107 in this embodiment includes: S501, run the maximum flow algorithm for the network flow model M1 (known method, see the literature: Shao Liping. Research on Network Maximum Flow Algorithm [D]. Nanjing University of Posts and Telecommunications, 2019) to obtain the residual network M1′. If the maximum flow value F1 returned by the maximum flow algorithm is greater than the preset maximum integer constant F_Max, it is determined that there is no solution, and the process ends and exits; otherwise, jump to step S502; S502, starting from the source node of the residual network M1′, performing depth-first traversal, and ending the traversal and returning when encountering an edge with a flow of 0, wherein the edge with a flow of 0 refers to an edge with a weight of 0 in the residual network M1′, and marking the traversed nodes; S503, traverse all the forward edges in the residual network M1′. If one of the nodes connected at both ends is marked and the other is not marked, then the edge is a cut edge. All the cut edges form a cut set T1. At the same time, the line network net corresponding to the edge in the cut set T1 is recorded and stored in the set S1. S504, using the circuit equivalent information EQ_Info obtained in step S207, traverse all edges in the network flow model M2, and if its line net is an equivalent point to the line net in the set S1, set the weight of the edge to 0; S505, running the maximum flow algorithm for the network flow model M2 to obtain the residual network M2′. If the maximum flow value F2 returned by the maximum flow algorithm is greater than the preset maximum integer constant F_Max, it is determined that there is no solution, and the process ends and exits; otherwise, jump to step S506; S506, starting from the source node in the residual network M2′, performing depth-first traversal, ending the traversal and returning when encountering an edge with a flow of 0, and marking the traversed nodes; S507, traverse all the forward edges in the residual network M2′. If one of the nodes connected at both ends is marked and the other is not marked, then the edge is a cut edge, and all the cut edges form a cut set T2; S508, using the circuit equivalence information EQ_Info obtained in step S207, matching the edges in the cut set T1 and the cut set T2 to generate a matching relationship R, in which the matching relationship R stores the equivalence relationship of all the edges in the cut set T1 and the cut set T2; S509, using cut set T1, cut set T2 and matching relationship R, cut and merge the combinational logic block C1 and the combinational logic block C2. When merging, if the wire net equivalence relationship corresponding to the two pins to be connected is directly equivalent to the mark POSITIVE_EQUAL, they are directly connected; if the wire net equivalence relationship corresponding to the two pins to be connected is N equivalent to the mark NEGATIVE_EQUAL, an inverter needs to be inserted in the middle of the connection. The combined combinational logic block is a new combinational logic block C1′, in which the part belonging to the combinational logic block C2 before the merger is the modified part of the circuit, such as Figure 7 shown.
[0031] In summary, the present embodiment implements a method for quickly repairing timing violations by assisting with a re-synthesized netlist based on the timing ECO method of re-synthesis. With the help of the powerful timing optimization capability of the synthesis tool, the new netlist generated using tightened timing constraints will have a shorter critical path. On this basis, the algorithm uses the optimized logic structure in the new netlist to partially replace the critical path in the old netlist, while retaining the original logic in the old netlist as much as possible. The purpose of timing repair can be achieved on the basis of modifying the old netlist as little as possible, achieving low cost, high efficiency, and short-time solution to serious timing violation problems that occur in the later stage of chip design, saving a lot of manpower and time investment, and shortening the chip design cycle.
[0032] In addition, the present embodiment further provides a timing ECO system based on re-synthesis, including a microprocessor and a memory connected to each other, wherein the microprocessor is programmed or configured to execute the timing ECO method based on re-synthesis.
[0033] In addition, this embodiment further provides a computer-readable storage medium, in which a computer program or instruction is stored. The computer program or instruction is programmed or configured to execute the re-synthesis-based timing ECO method through a processor.
[0034] In addition, this embodiment also provides a computer program product, including a computer program or instructions, where the computer program or instructions are programmed or configured to execute the re-synthesis-based timing ECO method through a processor.
[0035] Those skilled in the art should understand that the embodiments of the present application can be provided as methods, systems, or computer program products. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application can take the form of a computer program product implemented on one or more computer-readable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code. The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the process Figure 1 A process or multiple processes and / or boxes Figure 1 These computer program instructions can also be stored in a computer-readable memory that can guide a computer or other programmable data processing device to work in a specific way, so that the instructions stored in the computer-readable memory produce a product including an instruction device, which implements the functions specified in the process. Figure 1 A process or multiple processes and / or boxes Figure 1 These computer program instructions can also be loaded onto a computer or other programmable data processing device, so that a series of operation steps are executed on the computer or other programmable device to produce a computer-implemented process, so that the instructions executed on the computer or other programmable device provide for implementing the process in the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0036] The above is only a preferred embodiment of the present invention, and the protection scope of the present invention is not limited to the above embodiments. All technical solutions under the concept of the present invention belong to the protection scope of the present invention. It should be pointed out that for ordinary technicians in this technical field, some improvements and modifications without departing from the principle of the present invention should also be regarded as the protection scope of the present invention.
Claims
1. A timing ECO method based on re-synthesis, characterized in that: The steps include: S101, read circuit information, including the old netlist G1 that needs to be subjected to timing ECO, re-synthesize the new netlist G2 based on the RTL code of the old netlist G1 with tightened timing constraints, set the equivalence information file, standard cell library, timing constraint file and timing violation path information in the setting script; convert the read circuit information into a data structure in the program; S102, matching the old netlist G1 with the new netlist G2; S103, locating the combinational logic block C1 where the timing violation path is located in the old netlist G1, and extracting the combinational logic block C2 matching the combinational logic block C1 in the new netlist G2 according to the matching relationship; S104, using a method combining simulation and SAT solver to locate equivalent points, and storing mapping relationships between equivalent points. Two points with a mapping relationship are called equivalent points to each other. The equivalent point means that the net of the combinatorial logic block C1 is Boolean equivalent to one or more nets in the combinatorial logic block C2. S105, establishing a network flow model M1 for the combinational logic block C1, and establishing a network flow model M2 for the combinational logic block C2; S106, respectively calculating the timing information of the combinational logic block C1 and the combinational logic block C2, and assigning weights to the edges in the network flow models M1 and M2 according to the calculated timing information; S107, using the maximum flow algorithm to calculate the maximum flow for the network flow models M1 and M2 respectively, generate the corresponding residual network, use the residual network to calculate the cut set, and perform cut set matching, through the matching relationship, merge the right part of the combinational logic block C1 and the left part of the combinational logic block C2 along the tangent to generate a new combinational logic block C1′, wherein the part belonging to the combinational logic block C2 before the merger is the modified part of the circuit; S108, applying the new combinational logic block C1' to the old netlist G1 as the netlist G1' after timing ECO output.
2. The timing ECO method based on re-synthesis according to claim 1, characterized in that: When matching the old netlist G1 and the new netlist G2 in step S102, key points including sequential units, module input and output ports, and input and output ports of IP modules are matched by a name matching method.
3. The timing ECO method based on re-synthesis according to claim 1, characterized in that: Step S104 includes: S201, connecting the main inputs of the combinatorial logic block C1 and the main inputs of the combinatorial logic block C2 in pairs according to a matching relationship to generate a set of new main inputs PI′; S202, assigning a set of random analog values to the new main input PI′ so that the main inputs of the combinational logic block C1 and the combinational logic block C2 obtain the same random analog values; S203, propagating the random analog value to each wire net in the circuit of the combinational logic block C1 and the combinational logic block C2 according to the circuit logic relationship, and recording the analog value of each wire net; S204, grouping the wire nets according to the simulation values, and the wire nets with the same simulation values are a candidate equivalence group CG; S205, assign an input mask to each input in the new primary input PI′, propagate the input mask backward, and calculate the input signature for each line net; S206, further classify the obtained candidate equivalence group CG according to the input signature, remove the potential non-equivalence points therein, and obtain a new candidate equivalence group CG′; S207, use the SAT solver to verify the wire nets in the new candidate equivalence group CG′ in pairs, and consider N equivalence to mark the wire nets that meet the verification results as equivalent points, and store the equivalent information of the equivalent points in the circuit equivalence information EQ_Info obtained by locating the equivalent points. The circuit equivalence information EQ_Info stores the equivalent relationship between each group of equivalent points, and each group of equivalent points is accompanied by an equivalent mark, which is a direct equivalent mark POSITIVE_EQUAL or an N equivalent mark NEGATIVE_EQUAL; the N equivalence means that the logics of the two wire nets are mutually inverted.
4. The timing ECO method based on re-synthesis according to claim 1, characterized in that: Step S105 includes: S301, establishing a directed graph D1 for the combinatorial logic block C1, and establishing a directed graph D2 for the combinatorial logic block C2, wherein the nodes in the directed graph D1 and the directed graph D2 correspond to the logic units in the combinatorial logic block circuit, and the edges correspond to the connections between the pins, and the mapping relationship between the combinatorial logic blocks C1, C2 and the directed graphs D1, D2 is saved; S302, add a source node S to the directed graph D1, add directed edges to all input nodes in the directed graph D1 so that the source node S points to all input nodes through the directed edges, add a sink node T to the directed graph D1, add directed edges to all output nodes in the directed graph D1 so that all output nodes point to the sink node T through the directed edges; add a source node S to the directed graph D2, add directed edges to all input nodes in the directed graph D2 so that the source node S points to all input nodes through the directed edges, add a sink node T to the directed graph D2, add directed edges to all output nodes in the directed graph D2 so that all output nodes point to the sink node T through the directed edges; S303, adding reverse edges to each edge in directed graph D1 and directed graph D2, storing all edges into an array, and making the forward edge index adjacent to the corresponding reverse edge index, thereby obtaining the network flow model M1 of the combinational logic block C1 and the network flow model M2 of the combinational logic block C2.
5. The timing ECO method based on re-synthesis according to claim 3, characterized in that: Step S106 includes: S401, calculating equivalent logic levels for the combinational logic block C1 and the combinational logic block C2; S402, using the maximum equivalent logic level of the combinatorial logic block C2 to calculate the line network relaxation value Slack for the combinatorial logic block C1 and the combinatorial logic block C2, for a logic gate G with N inputs and M outputs i , the relaxation value of any input network j The calculation function expression is: , In the above formula, Indicates taking the minimum value, ~ They are logic gates G i The relaxation value of output port 0~M-1, Indicates taking the maximum value, ~ Do not use logic gate G i The equivalent logic level of input port 0~N-1, Represents the equivalent logic level of input line network j; S403, using the circuit equivalent information EQ_Info obtained in step S207 to assign weights to the edges in the directed graph D1, if a certain wire net in the combinatorial logic block C1 has a wire net in another combinatorial logic block C2 that is an equivalent point to each other, the weight is set to 0, otherwise the weight is set to a preset maximum integer constant F_Max; S404, using the timing information obtained in step S401 and step S402, the relaxation value of the corresponding network is updated according to the following formula for any edge i assigned a weight of 0 in step S403: : , In the above formula, is the original slack value of the network before it is updated. i If it is greater than 1, it means that the edge is a non-timing violation path. i If it is equal to 1, it means that the edge is a timing violation path. Then, it is determined whether the timing optimization of any edge i assigned a weight of 0 meets the standard. If the timing optimization does not meet the standard, if edge i is a non-timing violation path, the weight of edge i is updated according to the following formula: , If edge i is a timing violation path, the weight of edge i is updated according to the following formula: , When the timing optimization has been achieved, the weight of edge i is updated according to the following formula: , in, is the weight of edge i, , , is a constant factor, It indicates the degree of improvement of the logic level of a certain network net in the combinational logic block C2 relative to the equivalent logic level of the network net in the combinational logic block C1. is the equivalent logical series of edge i, is the maximum number of logic levels of the combinational logic block C1, is the maximum number of logic levels of the combinational logic block C2.
6. The timing ECO method based on re-synthesis according to claim 5, characterized in that: When calculating the equivalent logic levels for the combinational logic blocks C1 and C2 in step S401, for an N-input logic gate G i , the calculation function expression of the equivalent logic level of the output line network j is: , In the above formula, Represents the equivalent logic level of network j; Indicates taking the maximum value, ~ They are logic gates G i The equivalent logic level of input port 0~N-1, Represents logic gate G i The delay of the logic gate itself (used to replace the internal delay of the logic gate), its value is G i 1 / 2 of the input pins; Represents the fanout number of net j (used to replace the load capacitance of the net).
7. The timing ECO method based on re-synthesis according to claim 3, characterized in that: Step S107 includes: S501, run the maximum flow algorithm for the network flow model M1 to obtain the residual network M1′. If the maximum flow value F1 returned by the maximum flow algorithm is greater than the preset maximum integer constant F_Max, it is determined that there is no solution, and the process ends and exits; otherwise, jump to step S502; S502, starting from the source node of the residual network M1′, performing depth-first traversal, and ending the traversal and returning when encountering an edge with a flow of 0, wherein the edge with a flow of 0 refers to an edge with a weight of 0 in the residual network M1′, and marking the traversed nodes; S503, traverse all the forward edges in the residual network M1′. If one of the nodes connected at both ends is marked and the other is not marked, then the edge is a cut edge. All the cut edges form a cut set T1. At the same time, the line network net corresponding to the edge in the cut set T1 is recorded and stored in the set S1. S504, using the circuit equivalent information EQ_Info obtained in step S207, traverse all edges in the network flow model M2, and if its line net is an equivalent point to the line net in the set S1, set the weight of the edge to 0; S505, running the maximum flow algorithm for the network flow model M2 to obtain the residual network M2′. If the maximum flow value F2 returned by the maximum flow algorithm is greater than the preset maximum integer constant F_Max, it is determined that there is no solution, and the process ends and exits; otherwise, jump to step S506; S506, starting from the source node in the residual network M2′, performing depth-first traversal, ending the traversal and returning when encountering an edge with a flow of 0, and marking the traversed nodes; S507, traverse all the forward edges in the residual network M2′. If one of the nodes connected at both ends is marked and the other is not marked, then the edge is a cut edge, and all the cut edges form a cut set T2; S508, using the circuit equivalence information EQ_Info obtained in step S207, matching the edges in the cut set T1 and the cut set T2 to generate a matching relationship R, in which the matching relationship R stores the equivalence relationship of all the edges in the cut set T1 and the cut set T2; S509, using cut set T1, cut set T2 and matching relationship R, cut and merge the combinational logic block C1 and the combinational logic block C2. When merging, if the wire network equivalence relationship corresponding to the two pins to be connected is the direct equivalence mark POSITIVE_EQUAL, then they are directly connected; if the wire network equivalence relationship corresponding to the two pins to be connected is the N equivalence mark NEGATIVE_EQUAL, then it is necessary to insert an inverter in the middle of the connection. The merged combinational logic block is the new combinational logic block C1′, in which the part belonging to the combinational logic block C2 before the merger is the modified part of the circuit.
8. A timing ECO system based on re-synthesis, comprising a microprocessor and a memory connected to each other, characterized in that: The microprocessor is programmed or configured to execute the timing ECO method based on resynthesis as claimed in any one of claims 1 to 7.
9. A computer-readable storage medium having a computer program or instruction stored therein, characterized in that: The computer program or instruction is programmed or configured to execute the timing ECO method based on resynthesis according to any one of claims 1 to 7 through a processor.
10. A computer program product comprising a computer program or instructions, characterized in that The computer program or instruction is programmed or configured to execute the timing ECO method based on resynthesis according to any one of claims 1 to 7 through a processor.
Citation Information
Patent Citations
Establishment time optimization method and system based on genetic algorithm
CN115964974A
Integrated circuit time sequence analysis method and system based on effective clock path and medium
CN116542196A
Rapid logic equivalence verification method and device, equipment and storage medium
CN116595918A
Critical path delay optimization method based on logic netlist
CN118171609A
Method and apparatus for finding logic equivalence between register transfer level and post synthesis nets
US20180181683A1
