Incremental boxing method and device capable of automatically optimizing time sequence performance

Through the incremental binning method that automatically optimizes timing performance, iteratively optimizes and adjusts the CLB position of BLE in the FPGA circuit, solving the problem that the traditional binning method cannot modify the binning results, and achieving the reduction of critical path delay and improvement of timing performance. promote.

CN118569176AActive Publication Date: 2024-08-30EHIWAY MICROELECTRONIC SCI & TECH (SUZHOU) CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202411045308.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-01
Publication Date
2024-08-30
Estimated Expiration
2044-08-01

AI Technical Summary

Technical Problem

The traditional FPGA binning method cannot modify the binning results after the layout phase is completed, resulting in the inability to meet the user's timing requirements, especially the delay on the critical path that cannot be reduced.

Method used

The incremental binning method that automatically optimizes timing performance is adopted, and the position of BLE on the critical path in the CLB is adjusted through iterative optimization. It is continuously optimized through incremental binning and timing analysis to reduce the delay on the critical path.

Benefits of technology

Effectively reduce the delay of the critical path, improve the timing performance of the circuit, and meet the user's timing requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118569176A
    Figure CN118569176A
Patent Text Reader

Abstract

The invention relates to an incremental boxing method and device for automatically optimizing time sequence performance, which comprises the following steps of: after the overall layout is completed, adjusting the position of a CLB (Clock-Line Bullet) for BLE (Bluetooth Low Energy) increment on a critical path, and determining whether to accept the adjustment according to whether the adjusted time sequence is changed or not; calling time sequence analysis to obtain a connection set C with the minimum establishment time margin, executing incremental packing on each connection in the C to move the BLE of the connection starting point to the CLB where the BLE of the connection ending point is located, and moving the BLE of the connection ending point to the CLB where the BLE of the connection starting point is located by the incremental packing; if one time of increment boxing is feasible, and the establishment time margin minimum value worstslack becomes better or the slack minimum connection number becomes smaller, the result is kept, the C is updated, and the next round is turned to; otherwise, a result before incremental boxing is restored, and optimization of the next connection in the C is carried out, so that the delay of the critical path is further reduced through iterative optimization, and the time sequence performance of the circuit is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of field programmable gate arrays (FPGAs) in digital integrated circuits, and in particular to an incremental packing method for automatically optimizing timing performance, and an incremental packing device for automatically optimizing timing performance. Background Art

[0002] FPGA (Field-Programmable Gate Array) is a general-purpose logic circuit, and is known as one of the three general-purpose signal processing devices along with CPU and DSP. It has the advantages of high flexibility, high parallelism, and low development risk. It has been widely used in industrial control, aerospace, communications, automotive electronics, data centers, intelligent processing and other fields, and occupies an increasing market share.

[0003] The design process of FPGA EDA (Electronic Design Automation) software mainly includes multiple steps such as design input, synthesis, mapping, boxing, layout, routing, timing analysis, bit stream generation, and downloading. The boxing stage is to divide the basic logic unit BLE (Basic Logic Element) in the synthesized netlist into multiple boxes, so that each box can be mapped to a programmable logic block CLB (Configurable LogicBlock) inside the FPGA chip, and at the same time, the resource constraints need to be met to ensure that the logic of this box can be implemented in this CLB unit. The layout stage is to correspond each CLB to the physical coordinate position inside the FPGA chip and meet the constraints and optimization goals, such as area or timing.

[0004] The traditional FPGA binning process is completed before the layout stage, which means that after the layout stage is completed, the binning results cannot be modified. If the delay on the critical path is still large after the layout stage is completed, it cannot meet the user's timing requirements; and at this time, since the binning results cannot be modified, the number of CLBs on the critical path cannot be reduced, so the delay of the critical path cannot be significantly reduced, which leads to failure to meet the user's timing requirements. Summary of the invention

[0005] In order to overcome the defects of the prior art, the technical problem to be solved by the present invention is to provide an incremental packing method for automatically optimizing timing performance, which can further reduce the delay of the critical path and improve the timing performance of the circuit through such iterative optimization.

[0006] The technical solution of the present invention is: the incremental packing method for automatically optimizing timing performance comprises the following steps: (1)Perform timing analysis to obtain the minimum setup time margin worst_slack and the connection set C with the setup time margin equal to worst_slack, and mark each connection in C as optimizable; (2)Determine whether there is an optimizable connection in C. If so, find the first optimizable connection c in C; otherwise, stop; (3)Perform incremental packing by moving the BLE at the starting point of c to the CLB where the BLE at the ending point of c is located; (4)Determine whether this packing is feasible. If so, perform step (5); otherwise, perform step (7); (5)Perform timing analysis to obtain the latest minimum setup time margin worst_slack´ and the connection set C´ with the setup time margin equal to worst_slack´; (6)Determine whether worst_slack´ > worst_slack, or the number of connections in C´ < the number of connections in C. If so, perform step (11); otherwise, perform step (7); (7)Perform incremental packing by moving the BLE at the ending point of c to the CLB where the BLE at the starting point of c is located; (8)Determine whether this packing is feasible. If so, perform step (9); otherwise, perform step (12); (9)Perform timing analysis to obtain the latest minimum setup time margin worst_slack´ and the connection set C´ with the setup time margin equal to worst_slack´; (10)Determine whether worst_slack´ > worst_slack, or the number of connections in C´ < the number of connections in C. If so, perform step (11); otherwise, perform step (12); (11)Retain the incremental packing result and update the slack minimum connection set C of the latest timing analysis result; go to step (3); (12)Restore the packing result and mark c as non-optimizable; go to step (2).

[0007] After the overall layout of the present invention is completed, the BLEs on the critical path are incrementally adjusted in the CLBs where they are located, and whether to accept or reject this adjustment is determined according to whether the timing changes after the adjustment; through such iterative optimization, the delay of the critical path is further reduced, and the timing performance of the circuit is improved.

[0008] An incremental packing device for automatically optimizing timing performance is also provided, which includes: The first running timing analysis unit is configured to obtain the minimum setup time margin worst_slack and the set C of connections with the setup time margin equal to worst_slack, and mark each connection in C as optimizable; The first judgment unit is configured to judge whether there is an optimizable connection in C. If so, find the first optimizable connection c in C; otherwise, stop; The first incremental packing unit is configured to perform incremental packing and move the BLE at the starting point of c to the CLB where the BLE at the ending point of c is located; The second judgment unit is configured to judge whether this packing is feasible. If so, execute the second running timing analysis unit; otherwise, execute the second incremental packing unit; The second running timing analysis unit is configured to perform timing analysis to obtain the latest minimum setup time margin worst_slack' and the set C' of connections with the setup time margin equal to worst_slack'; The third judgment unit is configured to judge whether worst_slack'>worst_slack, or the number of connections in C' < the number of connections in C. If so, execute the retention unit; otherwise, execute the second incremental packing unit; The second incremental packing unit is configured to perform incremental packing and move the BLE at the ending point of c to the CLB where the BLE at the starting point of c is located; The fourth judgment unit is configured to judge whether this packing is feasible. If so, execute the third running timing analysis unit; otherwise, execute the restoration unit; The third running timing analysis unit is configured to perform timing analysis to obtain the latest minimum setup time margin worst_slack' and the set C' of connections with the setup time margin equal to worst_slack'; The fifth judgment unit is configured to judge whether worst_slack'>worst_slack, or the number of connections in C' < the number of connections in C. If so, execute the retention unit; otherwise, execute the restoration unit; The retention unit is configured to retain the incremental packing result and update the set C of the connections with the minimum slack in the latest timing analysis result; transfer to the first incremental packing unit; The restoration unit is configured to restore the packing result and mark c as non-optimizable; transfer to the first judgment unit. Description of the Drawings

[0009] Figure 1 Shows a flowchart of the incremental packing method for automatically optimizing timing performance according to the present invention.

[0010] Figure 2Flow chart for obtaining the connection set C with the minimum setup time margin for timing analysis.

[0011] Figure 3 Flow chart for moving a basic logic element BLE1 from the original programmable logic block CLB1 to CLB2 for incremental packing. Detailed implementation

[0012] As Figure 1 shown, this incremental packing method for automatically optimizing timing performance includes the following steps: (1) Run timing analysis to obtain the minimum setup time margin worst_slack and the connection set C with the setup time margin equal to worst_slack, and mark each connection in C as optimizable; (2) Determine whether there is an optimizable connection in C. If so, find the first optimizable connection c in C; otherwise, stop; (3) Perform incremental packing by moving the BLE at the starting point of c to the CLB where the BLE at the ending point of c is located; (4) Determine whether this packing is feasible. If so, execute step (5); otherwise, execute step (7); (5) Run timing analysis to obtain the latest minimum setup time margin worst_slack' and the connection set C' with the setup time margin equal to worst_slack'; (6) Determine whether worst_slack' > < worst_slack, or the number of connections in C' < the number of connections in C. If so, execute step (11); otherwise, execute step (7); (7) Perform incremental packing by moving the BLE at the ending point of c to the CLB where the BLE at the starting point of c is located; (8) Determine whether this packing is feasible. If so, execute step (9); otherwise, execute step (12); (9) Run timing analysis to obtain the latest minimum setup time margin worst_slack' and the connection set C' with the setup time margin equal to worst_slack'; (10) Determine whether worst_slack' > < worst_slack, or the number of connections in C' < the number of connections in C. If so, execute step (11); otherwise, execute step (12); (11) Retain the incremental packing result and update the slack minimum connection set C of the latest timing analysis result; go to step (3); (12) Restore the packing result and mark c as non-optimizable; go to step (2).

[0013] After the overall layout is completed, the present invention incrementally adjusts the positions of the CLBs where the BLEs on the critical path are located, and decides whether to accept or reject the adjustment based on whether the timing changes after the adjustment; through such iterative optimization, the delay of the critical path is further reduced and the timing performance of the circuit is improved.

[0014] Preferably, in step (1), the step of performing timing analysis to obtain a connection set C with the minimum establishment time margin includes: (1.1) Traverse the time series graph G from front to back and calculate the arrival time Tarrival of each node; (1.2) Traverse the timing graph G from back to front and calculate the required arrival time Trequired of each node; (1.3) Calculate the establishment time margin slack of each connection; (1.4) Sort each connection in ascending order of slack; (1.5) Get the minimum slack value worst_slack, which is equal to the slack of the first connection after sorting; (1.6) Get the first connection c after sorting; (1.7) If the slack of c is equal to worst_slack, execute step (1.8); otherwise exit; (1.8) Add c to the set C and move on to the next connection.

[0015] Preferably, in step (3), the step of incrementally packing a basic logic unit BLE1 from the original programmable logic block CLB1 to CLB2 comprises: (3.1) Remove BLE1 from the subunit list of CLB1; (3.2) Update the properties of CLB1; (3.3) Add BLE1 from the subunit list of CLB2; (3.4) Update the properties of CLB2; (3.5) For the signal i of each input port in BLE1; (3.6) Find the sink that reaches CLB1 in the terminal node sink list of signal i and change it to the sink that reaches CLB2; (3.7) For each output signal o in BLE1; (3.8) Change the starting point source information in signal o to CLB2.

[0016] Preferably, in the step (4), the rules for judging that the incremental packing of moving the BLE at the c start point to the box where the BLE at the c end point is located are as follows: the box of BLE1 is of the CLB type; the box of BLE2 is of the CLB type; BLE1 is not on a certain carry chain; BLE2 is not on a certain carry chain; the number of BLEs in CLB2 has not reached the maximum capacity; after adding BLE1 to CLB2, the maximum number limit of CLB data signals is satisfied; after adding BLE1 to CLB2, the maximum number limit of CLB control signals is satisfied.

[0017] Those of ordinary skill in the art can understand that all or part of the steps in implementing the method of the above embodiments can be completed by a program instructing relevant hardware. The program can be stored in a computer-readable storage medium. When the program is executed, it includes the steps of the above embodiment method, and the storage medium can be: ROM / RAM, magnetic disk, optical disk, memory card, etc. Therefore, corresponding to the method of the present invention, the present invention also simultaneously includes an incremental packing device for automatically optimizing timing performance, and this device is usually represented in the form of functional modules corresponding to the steps of the method. This device includes: An incremental packing device for automatically optimizing timing performance is also provided, which includes: A first running timing analysis unit configured to obtain the minimum setup time margin worst_slack and the connection set C with the setup time margin equal to worst_slack, and mark each connection in C as optimizable; A first judgment unit configured to judge whether there is an optimizable connection in C. If so, find the first optimizable connection c in C; otherwise stop; A first incremental packing unit configured to perform incremental packing and move the BLE at the c start point to the CLB where the BLE at the c end point is located; A second judgment unit configured to judge whether this packing is feasible. If so, execute the second running timing analysis unit; otherwise execute the second incremental packing unit; A second running timing analysis unit configured to perform timing analysis and obtain the latest minimum setup time margin worst_slack´ and the connection set C´ with the setup time margin equal to worst_slack´; A third judgment unit configured to judge whether worst_slack´>worst_slack, or the number of connections in C´ < the number of connections in C. If so, execute the retention unit; otherwise execute the second incremental packing unit; A second incremental packing unit configured to perform incremental packing and move the BLE at the c end point to the CLB where the BLE at the c start point is located; The fourth judgment unit is configured to judge whether the current packing is feasible. If so, execute the third running timing analysis unit; otherwise, execute the restoration unit; The third running timing analysis unit is configured to perform timing analysis, obtain the latest minimum setup time margin worst_slack´ and the connection set C´ with the setup time margin equal to worst_slack´; The fifth judgment unit is configured to judge whether worst_slack´ > worst_slack, or the number of connections in C´ < the number of connections in C. If so, execute the retention unit; otherwise, execute the restoration unit; The retention unit is configured to retain the incremental packing result and update the slack minimum connection set C of the latest timing analysis result; transfer to the first incremental packing unit; The restoration unit is configured to restore the packing result and mark c as non-optimizable; transfer to the first judgment unit.

[0018] Preferably, in the first running timing analysis unit, the steps of performing timing analysis to obtain the connection set C with the minimum setup time margin include: (1.1) Traverse the timing diagram G from front to back and calculate the arrival time Tarrival of each node; (1.2) Traverse the timing diagram G from back to front and calculate the required arrival time Trequired of each node; (1.3) Calculate the setup time margin slack of each connection; (1.4) Sort each connection in ascending order of slack; (1.5) Obtain the minimum slack worst_slack, and worst_slack is equal to the slack of the first connection after sorting; (1.6) Obtain the first connection c after sorting; (1.7) Judge that if the slack of c is equal to worst_slack, execute step (1.8); otherwise, exit; (1.8) Add c to C and transfer to the next connection.

[0019] Preferably, in the first incremental packing unit, the steps of incrementally packing a basic logic element BLE1 from the original programmable logic block CLB1 to CLB2 include: (3.1) Remove BLE1 from the subunit list of CLB1; (3.2) Update the attributes of CLB1; (3.3) Add BLE1 to the subunit list of CLB2; (3.4) Update the properties of CLB2; (3.5) For the signal i of each input port in BLE1; (3.6) Find the sink that reaches CLB1 in the terminal node sink list of signal i and change it to the sink that reaches CLB2; (3.7) For each output signal o in BLE1; (3.8) Change the starting point source information in signal o to CLB2.

[0020] Preferably, in the second judgment unit, the rules for judging whether the incremental packing from the c-starting point BLE1 to the box where the c-end point BLE2 is located are feasible are: the box of BLE1 is of CLB type; the box of BLE2 is of CLB type; BLE1 is not on a certain carry chain; BLE2 is not on a certain carry chain; the number of BLEs in CLB2 has not reached the maximum capacity; after BLE1 is added to CLB2, the maximum number limit of CLB data signals is met; after BLE1 is added to CLB2, the maximum number limit of CLB control signals is met.

[0021] The above description is only a preferred embodiment of the present invention and does not limit the present invention in any form. Any simple modification, equivalent changes and modifications made to the above embodiments based on the technical essence of the present invention are still within the protection scope of the technical solution of the present invention.

Claims

1. An incremental packing method for automatically optimizing timing performance, characterized by: It includes the following steps: (1) Run timing analysis to obtain the connection set C with the minimum setup time margin worst_slack and the connection set C with the setup time margin equal to worst_slack, and mark each connection in C as optimizable; (2) Determine whether there is an optimizable connection in C. If so, find the first optimizable connection c in C; otherwise, stop; (3) Perform incremental packing to move the BLE at the starting point of c to the CLB where the BLE at the end point of c is located; (4) Determine whether the packing is feasible. If so, execute step (5); otherwise, execute step (7); (5) Run timing analysis to obtain the latest minimum value of the setup time margin, worst_slack´, and the connection set C´ whose setup time margin is equal to worst_slack´; (6) Determine whether worst_slack´ > is less than worst_slack, or the number of connections of C´ is less than the number of connections of C. If so, execute step (11); otherwise, execute step (7). (7) Perform incremental packing to move the BLE at the end of c to the CLB where the BLE at the start of c is located; (8) Determine whether the packing is feasible. If so, execute step (9); otherwise, execute step (12); (9) Run timing analysis to obtain the latest minimum value of the setup time margin, worst_slack´, and the connection set C´ whose setup time margin is equal to worst_slack´; (10) Determine whether worst_slack´ > is less than worst_slack, or the number of connections of C´ is less than the number of connections of C. If so, execute step (11); otherwise, execute step (12). (11) Keep the incremental packing results and update the slack minimum connection set C of the latest timing analysis results; go to step (3); (12) Restore the packing result and mark c as non-optimizable; go to step (2).

2. The incremental packing method for automatically optimizing timing performance according to claim 1, characterized in that: In step (1), the step of performing timing analysis to obtain a connection set C with the smallest establishment time margin includes: (1.1) Traverse the time series graph G from front to back and calculate the arrival time Tarrival of each node; (1.2) Traverse the timing graph G from back to front and calculate the required arrival time Trequired of each node; (1.3) Calculate the establishment time margin slack of each connection; (1.4) Sort each connection in ascending order of slack; (1.5) Get the minimum slack value worst_slack, which is equal to the slack of the first connection after sorting; (1.6) Get the first connection c after sorting; (1.7) If the slack of c is equal to worst_slack, execute step (1.8); otherwise exit; (1.8) Add c to C and move on to the next connection.

3. The incremental packing method for automatically optimizing timing performance according to claim 1, characterized in that: In step (3), the step of incrementally packing a basic logic unit BLE1 from the original programmable logic block CLB1 to CLB2 includes: (3.1) Remove BLE1 from the subunit list of CLB1; (3.2) Update the properties of CLB1; (3.3) Add BLE1 from the subunit list of CLB2; (3.4) Update the properties of CLB2; (3.5) For the signal i of each input port in BLE1; (3.6) Find the sink that reaches CLB1 in the terminal node sink list of signal i and change it to the sink that reaches CLB2; (3.7) For each output signal o in BLE1; (3.8) Modify the source information in signal o to CLB2.

4. The incremental packing method for automatically optimizing timing performance according to claim 1, characterized in that: In the said step (4), the rules for judging that the incremental bin packing of moving the starting point BLE1 of c to the bin where the ending point BLE2 of c is located are feasible are: the bin of BLE1 is of CLB type; the bin of BLE2 is of CLB type; BLE1 is not on a certain carry chain; BLE2 is not on a certain carry chain; the number of BLEs in CLB2 has not reached the maximum capacity; after adding BLE1 to CLB2, the maximum number limit of CLB data signals is satisfied; after adding BLE1 to CLB2, the maximum number limit of CLB control signals is satisfied.

5. An incremental packing device for automatically optimizing timing performance, characterized in that: It includes: A first running timing analysis unit configured to obtain the minimum setup time margin worst_slack and the connection set C with the setup time margin equal to worst_slack, and mark each connection in C as optimizable; A first judgment unit configured to judge whether there is an optimizable connection in C. If so, find the first optimizable connection c in C; otherwise stop; A first incremental bin packing unit configured to perform incremental bin packing and move the BLE at the starting point of c to the CLB where the BLE at the ending point of c is located; A second judgment unit configured to judge whether this bin packing is feasible. If so, execute the second running timing analysis unit; otherwise execute the second incremental bin packing unit; A second running timing analysis unit configured to perform timing analysis to obtain the latest minimum setup time margin worst_slack' and the connection set C' with the setup time margin equal to worst_slack'; A third judgment unit configured to judge whether worst_slack'>worst_slack, or the number of connections in C'<the number of connections in C. If so, execute the retention unit; otherwise execute the second incremental bin packing unit; A second incremental bin packing unit configured to perform incremental bin packing and move the BLE at the ending point of c to the CLB where the BLE at the starting point of c is located; A fourth judgment unit configured to judge whether this bin packing is feasible. If so, execute the third running timing analysis unit; otherwise execute the restoration unit; A third running timing analysis unit configured to perform timing analysis to obtain the latest minimum setup time margin worst_slack' and the connection set C' with the setup time margin equal to worst_slack'; A fifth judgment unit configured to judge whether worst_slack'>worst_slack, or the number of connections in C'<the number of connections in C. If so, execute the retention unit; otherwise execute the restoration unit; A retention unit configured to retain the incremental bin packing result and update the connection set C with the minimum slack of the latest timing analysis result; transfer to the first incremental bin packing unit; A restoration unit configured to restore the bin packing result and mark c as non-optimizable; transfer to the first judgment unit.

6. The incremental packing device for automatically optimizing timing performance according to claim 5, characterized in that: In the said first running timing analysis unit, the steps of performing timing analysis to obtain the connection set C with the minimum setup time margin include: (1.1) Traverse the time series graph G from front to back and calculate the arrival time Tarrival of each node; (1.2) Traverse the timing graph G from back to front and calculate the required arrival time Trequired of each node; (1.3) Calculate the establishment time margin slack of each connection; (1.4) Sort each connection in ascending order of slack; (1.5) Get the minimum slack value worst_slack, which is equal to the slack of the first connection after sorting; (1.6) Get the first connection c after sorting; (1.7) If the slack of c is equal to worst_slack, execute step (1.8); otherwise exit; (1.8) Add c to C and move on to the next connection.

7. The incremental packing device for automatically optimizing timing performance according to claim 5, characterized in that: In the first incremental packing unit, the step of incremental packing to move a basic logic unit BLE1 from the original programmable logic block CLB1 to CLB2 includes: (3.1) Remove BLE1 from the subunit list of CLB1; (3.2) Update the properties of CLB1; (3.3) Add BLE1 from the subunit list of CLB2; (3.4) Update the properties of CLB2; (3.5) For the signal i of each input port in BLE1; (3.6) Find the sink that reaches CLB1 in the terminal node sink list of signal i and change it to the sink that reaches CLB2; (3.7) For each output signal o in BLE1; (3.8) Change the starting point source information in signal o to CLB2.

8. The incremental packing device for automatically optimizing timing performance according to claim 5, characterized in that: In the second judgment unit, the rule for judging whether the incremental packing connecting the c starting point BLE1 to the box where the c end point BLE2 is located is feasible is: the box of BLE1 is of CLB type; the box of BLE2 is of CLB type; BLE1 is not on a carry chain; BLE2 is not on a carry chain; the number of BLEs in CLB2 does not reach the maximum capacity; after BLE1 is added to CLB2, the maximum number limit of CLB data signals is met; after BLE1 is added to CLB2, the maximum number limit of CLB control signals is met.

Citation Information

Patent Citations

  • Encasement method for FPGA self-adaptive logic modules

    CN114282471A

  • Encasement method for FPGA (Field Programmable Gate Array) chips

    CN115392168A

  • Time sequence performance adjusting method and device

    CN116579280A

  • Incremental time sequence analysis method

    CN117574820A

  • FPGA chip wiring method based on plb

    WO2017113058A1