Automated script writing and usage to solve long-line timing delays in physical design
Optimizing timing violation paths through automated scripts solves the problem of physical design timing delays in semiconductor chip design, shortens the design cycle and improves optimization efficiency, and is suitable for chip design with advanced processes.
Patent Information
- Application Number
- CN202210266806.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-17
- Publication Date
- 2024-09-10
- Estimated Expiration
- 2042-03-17
AI Technical Summary
In semiconductor chip design, as the process advances to 40nm, 28nm and below, physical design timing delay has become a design difficulty. Existing automatic layout tools are difficult to effectively optimize paths with special requirements or tight timing, resulting in extended design cycles.
Provides an automated script writing method that optimizes timing violation paths by setting logical connection scripts and main scripts, setting the starting point, end point, and inflection point, judging the addition position and connection of buffers and inverters, and optimizing lines based on layout planning. Delay, including optimization before place and route.
It shortens the design cycle and improves optimization efficiency, reduces line delays, simplifies the physical design process, reduces manual optimization workload, and is suitable for large-scale chip design under advanced processes.
Smart Images

Figure CN114548025B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of semiconductor technology, and in particular to an automatic script writing and using method for solving long-line timing delay in physical design. Background Art
[0002] As semiconductor processes advance to 40nm, 28nm and below, physical timing in chip design becomes a design difficulty. Practice has found that after physical design and routing, the impact of line delay is far greater than the impact of standard cells contained in the logic design itself. Although automatic layout and routing tools can achieve optimization, physical design engineers are required to manually optimize paths with special requirements or tight timing one by one. If there are many paths, it will cause a lot of workload and extend the design cycle. Summary of the invention
[0003] In order to solve the above technical problems, the present invention provides an automated script writing and using method for solving long-line timing delay in physical design with a short design cycle and high optimization efficiency.
[0004] The technical solution of the present invention to solve the above problem is: an automated script writing and using method for solving long-line timing delay in physical design, comprising the following steps:
[0005] Step S1: Setting a logic connection script, for the timing violation path, by setting the starting point, the end point, and the turning point, determining the adding location and connection of the buffer BUF standard unit, and the adding location and connection of the inverter INV standard unit, to ensure logic consistency;
[0006] Step S2: Setting the main script and setting the global variables of the timing violation path;
[0007] Step S3: Find the timing violation path to be optimized in the floorplan stage;
[0008] Step S4: according to the information of the timing violation path to be optimized and the layout plan of the design, set the parameters of the starting point, the end point, and the inflection point, and set the line name of the timing violation path to be optimized and the name of the connected end point standard cell port;
[0009] Step S5: Based on the logic connection script and the main script, according to different design processes, the standard unit types of the buffer BUF and the inverter INV are changed, the horizontal and vertical spacings between the inserted buffer BUF and the inverter INV are changed, and the required parameters are selected;
[0010] Step S6: Before layout and routing, complete optimization in the layout and routing PR tool.
[0011] In the above-mentioned automated script writing and using method for solving the long-line timing delay of physical design, in step S1, the optimization logic of the logic connection script for the line path to be optimized is to find the coordinates of the starting point and the end point of the line, and calculate according to the coordinate values; give priority to judging the routing direction of up, down, left, and right, and then calculate the path length according to the coordinates of the starting point and the end point, and insert the standard unit of the optimized timing in combination with the set spacing; therefore, first set the coordinates of the starting point and the end point of the timing violation path; set the variables as follows: the x coordinate of the path starting point x_begin, the y coordinate of the path starting point y_begin, the x coordinate of the path end point x_end, and the y coordinate of the path end point y_end;
[0012] In order to adapt to the specific situation of FloorPlan, set the inflection point in the middle. If branching is required, it can also be achieved through the inflection point. It should be noted that because it is an inflection point, the starting and ending points of the line between every two points must be horizontal and vertical. The inflection point variables are set to: inflection point x coordinate x_trunk*, inflection point y coordinate y_trunk*; the above * is an arbitrary serial number, which is used to distinguish different variables when multiple inflection points are used.
[0013] In the above-mentioned automated script writing and using method for solving long-line timing delays in physical design, in step S1, in the back-end physical design, if the starting point and end point coordinates of the timing violation path are fixed after floorplanning, then the specific values are set directly. If they cannot be determined, the corresponding coordinates are found through dbget to provide a feasible solution for the customized path.
[0014] In the above-mentioned automated script writing and using method for solving long-line timing delay in physical design, in step S1, the process of determining the adding location and connection of the buffer BUF standard unit and the adding location and connection of the inverter INV standard unit is as follows:
[0015] (1) Calculate the number of inverters that need to be inserted based on the length of the line segment:
[0016] First, the coordinates of the starting point and the end point are used to determine the four directions of up, down, left, and right. Then, the inverter pair number a is calculated based on the distance and the set spacing. Inverters must be added in pairs to ensure logical consistency. However, it cannot be guaranteed that the path length will not exceed the specified length after the inverters are inserted in pairs at a fixed spacing. Therefore, a is rounded and set to b(int(a)). The number of INV pairs to be inserted subsequently is b. b is determined. If (ab) is greater than the specified length, a buffer BUF is inserted. If (ab) is less than the specified length, no buffer is inserted.
[0017] (2) Set loop logic:
[0018] The logic of the loop is that when the loop condition is met, a set of inverters INV and their connecting wires net are added, the inverter INV corresponding to the current variable is connected to the inverter of the previous variable, and the coordinate position of the pair of inverters is calculated according to the variables. The position is calculated by accumulating the required distance of the corresponding number on the starting coordinates, so a set of inverters INV and their connecting wires net are added in advance outside the loop;
[0019] Considering the effect of reducing the conversion time on the delay, a buffer BUF is added at the starting position, and then the first pair of inverters INV is added; the starting position is set to the edge of the starting unit; after the three standard units of the buffer BUF and the first pair of inverters INV are connected to the starting unit, the output end of the last standard unit, that is, the second inverter, is not connected, and is connected in the subsequent judgment;
[0020] The coordinates of the buffer BUF are calculated, when added horizontally and from left to right:
[0021] The x coordinate of the first BUF is x1, and the y coordinate is y1;
[0022] The x coordinate of the first INV is x1+distance_x, and the y coordinate is y1;
[0023] The x coordinate of the second INV is x1+2*distance_x, and the y coordinate is y1;
[0024] distance_x is the set horizontal distance; the same applies to other directions;
[0025] And set a special character target abbreviation tar to name the added standard unit and line, using the character composed of the endpoint standard unit name and its port name;
[0026] Because the added standard cells and lines need unique names, this ensures that there will be no duplicate names that will cause the script to fail to execute;
[0027] The naming is as follows:
[0028] First BUF name: [expr$trunk_num]_BUF_0_$tar
[0029] First INV name: [expr$trunk_num]_INV0_0_$tar
[0030] Second INV name: [expr$trunk_num]_INV1_0_$tar
[0031] The "trunk_num" indicates which segment of the line. "INV0_0" refers to the 0th INV of the 0th pair of INVs, and "INV1_0" refers to the 1st INV of the 0th pair of INVs.
[0032] After adding a group of inverters INV, a judgment is made. There are three cases in total. In these three cases, the termination lines are set to the same name to ensure consistency and facilitate subsequent execution.
[0033] All the following calculations of unit positions are obtained when adding horizontally from left to right. Similarly, for other orientations, they are changed to addition and subtraction or calculated by replacing calculating x with calculating y.
[0034] 1) a - 1 < 0.5
[0035] In this case, it directly ends after the first group of INVs and adds a termination line.
[0036] 2) 0.5 <= a - 1 < 1
[0037] In this case, it directly ends after adding a buffer and adds a termination line.
[0038] The x - coordinate of the buffer BUF is x1 + 2 * distance_x + distance_x, and the y - coordinate is y1.
[0039] 3) 1 <= a - 1
[0040] In this case, the number of added inverters INV is judged through a loop.
[0041] The judgment condition of the loop is
[0042] for {set i 0} {i < ($a - 2)} {incr i} {…………}
[0043] That is, set the initial value of i to 0. When i < a - 2 is satisfied, add 1 to i, that is, change from 0 to 1, and execute the commands in the ellipsis within the curly braces. After execution, re - judge whether i is less than a - 2. If it is still satisfied, continue to add 1, that is, change from 1 to 2, until the judgment is not satisfied.
[0044] The commands executed within the curly braces include:
[0045] 1) Set the variable num = i + 1;
[0046] 2) Set last_cell: [expr $trunk_num]_INV1_[expr $i]_$tar;
[0047] 3) Set postfix [expr $i + 1]_$tar;
[0048] That is, the name of the first INV added in a pair is: [expr$trunk_num]_INV0_postfix, and the name of the second INV is [expr$trunk_num]_INV1_postfix. It is found that the last_cell set above is the INV at the last level of the connection relationship among the three standard cells added at the beginning; the connection relationship between the INV added in the loop and the previously added INV can be realized; and the x coordinate of the first INV is $x1+(2*($num+1)-1)*$distance_x, and the y coordinate is y1; the x coordinate of the second INV is $x1+2*($num+1)*$distance_x, and the y coordinate is y1;
[0049] Whether BUF needs to be added at the end depends on two situations:
[0050] I)ab<0.5
[0051] In this case, end directly after the loop and add a termination line;
[0052] II) 0.5 <= ab
[0053] In this case, add a buffer and end directly, adding a termination line;
[0054] The x coordinate of the buffer BUF is the x coordinate of the last INV in the loop plus distance_x, and the y coordinate is y1; the naming suggestion of the added buffer BUF is the same as the buffer added in case 2); the name of the end line set under all conditions is the same, so that it can be used as the initial line when the second line segment is needed;
[0055] (3) Set the connection method between line segments:
[0056] Each line segment is executed using the single-segment logic of (1) and (2) above. Except for the different lines connected at the beginning, the rest are the same. Therefore, the end line of the first segment is set as the start line of the second segment to achieve the connection between the line segments, thereby realizing the turning of the optimized path; the second, third, and so on paths;
[0057] When a line segment is less than twice the spacing, there are two solutions:
[0058] The first method: do not add the line segment, but manually add a BUF and a net, and connect the manually added BUF and net to the previous and next line segments of the line segment;
[0059] The second method: directly connect the previous line segment and the next line segment of the line segment, ignore the line segment, and ensure that the current line segment is horizontal or vertical.
[0060] In the above-mentioned automated script writing and using method for solving the long-line timing delay of physical design, in step S2, the main script conducts experiments by setting a single variable for the types of BUF and INV selected, the specific sizes of the horizontal and vertical spacing, and the properties of the connection, and selects the best solution;
[0061] All global variables required by the commands in the logic connection script include the name of the line to be optimized begin_net; the standard cell tar_cell at the output end of the optimized line logic connection; the port name tar_term at which the output end standard cell is connected to the line; the set horizontal spacing distance_x; the set vertical spacing distance_y; the set buffer type BUF_cell; the set inverter type INV_cell; all are set as variables and moved to the main script for setting together, so as to achieve unified modification of these variables, ensuring that they will not be missed, and solidifying the logic connection script so that it will not be modified again, avoiding the modification causing the logic connection script to be unable to execute.
[0062] In the above-mentioned automated script writing and using method for solving the long-line timing delay of physical design, in step S2, the logic connection script is calculated in the mode of line segments, so the main script is also divided into line segments to call the logic connection script multiple times, and the starting and ending points of the line segments are set as follows: the x coordinate of the starting point of the line segment is x1; the y coordinate of the starting point of the line segment is y1; the x coordinate of the end point of the line segment is x2; the y coordinate of the end point of the line segment is y2.
[0063] In the above-mentioned automated script writing and using method for solving long-line timing delay in physical design, in step S2, in order to better reduce line delay, the winding attributes are adjusted in the back-end physical design, and therefore the winding attributes are also set in the main script, and the winding attributes are: the parameter setting NDR for multiple line widths and multiple spacings; the setting NDR_effort for the execution strength of NDR rules; the setting top_route_layer for the highest winding layer; the setting bottom_route_layer for the lowest winding layer; the strength pre_layer_effort for satisfying the highest and lowest winding layer settings when the tool automatically winds; and the weight parameter net_weight.
[0064] In the above-mentioned automated script writing and using method for solving long-line timing delay in physical design, in step S3, timing optimization is performed according to the layout plan before layout and routing, that is, in the floorplan stage, replacing the automatic optimization of subsequent tools to achieve the best timing optimization.
[0065] In the above-mentioned automated script writing and using method for solving long-line timing delay in physical design, in step S5, the added standard cells are named with the relevant information of the optimized timing violation path, which is unique and will not cause script failure due to repeated naming.
[0066] The beneficial effects of the present invention are:
[0067] 1. The present invention is specifically applied to the layout and wiring stage of chip digital physical design to solve the impact of increasing line delay under advanced technology, and to minimize line delay for long paths on the physical level. The script of the present invention is divided into two layers: one layer is the main script, which sets global variables about the optimization object, such as line name, line width, unit type, etc.; the other layer is the logic connection script, which realizes the addition and positioning of standard units and the connection of standard units to ensure logical consistency, and no modification is required during use.
[0068] 2. The script of the present invention can specifically achieve the effect of reducing line delay by setting the spacing between the buffer Buffer and the inverter Inverter, the line width of the wiring, the line spacing of the same-layer line, and the unit type of the buffer inverter. Because it is in the form of a script, and the variables required to be set in the script are pre-set as global environment variables, when modifying the relevant variables of the script, only a few changes need to be made. Therefore, in the process of finding the optimal solution, the relevant variables can be adjusted by the control variable method to achieve rapid iteration. And in the later specific layout and wiring stage, because the variables are clear and unambiguous, and because there may be multiple uses of different variables mentioned above, the fixed script can be combined with the relevant commands of the layout and wiring tools, such as INNOVUS's dbget, etc., and the loop statement in the TCL syntax, to achieve the fixation of the back-end layout and wiring process, so that subsequent iterations are faster and less prone to errors.
[0069] 3. The present invention can also be used to customize the key clock tree, manually make the clock tree, reduce the delay on the clock path, and easily meet the establishment time requirements. Or balance multiple modules or storage bodies that need to be balanced, including address, data, and clock balance, so as to meet the read and write requirements. BRIEF DESCRIPTION OF THE DRAWINGS
[0070] Figure 1 It is a flow chart of the present invention. DETAILED DESCRIPTION
[0071] The present invention will be further described below in conjunction with the accompanying drawings and embodiments.
[0072] like Figure 1 As shown, an automated script writing and using method for solving long-line timing delay in physical design includes the following steps:
[0073] Step S1: Set the logic connection script, and for the timing violation path, determine the adding location and connection of the buffer BUF standard unit and the adding location and connection of the inverter INV standard unit by setting the starting point, end point, and inflection point to ensure logic consistency.
[0074] The optimization logic of the logic connection script for the line path that needs to be optimized is to find the coordinates of the starting point and the end point of the line, and calculate according to the coordinate values; first determine the routing direction of up, down, left, and right, and then calculate the path length according to the coordinates of the starting point and the end point, and insert the standard unit of the optimized timing in combination with the set spacing; therefore, first set the coordinates of the starting point and the end point of the timing violation path; the variables set are as follows: the x coordinate of the path starting point x_begin, the y coordinate of the path starting point y_begin, the x coordinate of the path end point x_end, and the y coordinate of the path end point y_end;
[0075] In order to adapt to the specific situation of FloorPlan, set the inflection point in the middle. If branching is required, it can also be achieved through the inflection point. It should be noted that because it is an inflection point, the starting and ending points of the line between every two points must be horizontal and vertical. The inflection point variables are set to: inflection point x coordinate x_trunk*, inflection point y coordinate y_trunk*; the above * is an arbitrary serial number, which is used to distinguish different variables when multiple inflection points are used.
[0076] In the back-end physical design, if the starting and ending coordinates of the timing violation path are fixed after floorplanning, then the specific values are set directly. If they cannot be determined, the corresponding coordinates are found through dbget to provide a feasible solution for the customized path.
[0077] The process of determining the addition location and connection of the buffer BUF standard cell and the addition location and connection of the inverter INV standard cell is as follows:
[0078] (1) Calculate the number of inverters that need to be inserted based on the length of the line segment:
[0079] First, the coordinates of the starting point and the end point are used to determine the four directions of up, down, left, and right. Then, the inverter pair number a is calculated based on the distance and the set spacing. Inverters must be added in pairs to ensure logical consistency. However, it cannot be guaranteed that the path length will not exceed the specified length after the inverters are inserted in pairs at a fixed spacing. Therefore, a is rounded and set to b(int(a)). The number of INV pairs to be inserted subsequently is b. b is determined. If (ab) is greater than the specified length, a buffer BUF is inserted. If (ab) is less than the specified length, no buffer is inserted.
[0080] (2) Set loop logic:
[0081] The logic of the loop is that when the loop condition is met, a set of inverters INV and their connecting lines net are added, the inverter INV corresponding to the current variable is connected to the inverter of the previous variable, and the coordinate position of the pair of inverters is calculated according to the variables. The position is calculated by accumulating the required distance of the corresponding number on the starting coordinates, so a set of inverters INV and their connecting lines net are added in advance outside the loop;
[0082] Considering the effect of reducing the conversion time on the delay, a buffer BUF is added at the starting position, and then the first pair of inverters INV is added; the starting position is set to the edge of the starting unit; after the buffer BUF and the first pair of inverters INV are connected to the starting unit, the output end of the last unit, that is, the second inverter, is not connected and is connected in the subsequent judgment;
[0083] The coordinates of the buffer BUF are calculated, when added horizontally and from left to right:
[0084] The x coordinate of the first BUF is x1, and the y coordinate is y1;
[0085] The x coordinate of the first INV is x1+distance_x, and the y coordinate is y1;
[0086] The x coordinate of the second INV is x1+2*distance_x, and the y coordinate is y1;
[0087] distance_x is the set horizontal distance; the same applies to other directions;
[0088] And set a special character target abbreviation tar to name the added standard unit and line, using the character composed of the endpoint standard unit name and its port name;
[0089] Because the added standard cells and lines need unique names, this ensures that there will be no duplicate names that will cause the script to fail to execute;
[0090] The naming is as follows:
[0091] First BUF name: [expr$trunk_num]_BUF_0_$tar
[0092] First INV name: [expr$trunk_num]_INV0_0_$tar
[0093] Second INV name: [expr$trunk_num]_INV1_0_$tar
[0094] The "trunk_num" refers to which segment of the line. INV0_0 refers to the 0th INV of the 0th pair of INVs, and INV1_0 refers to the first INV of the 0th pair of INVs;
[0095] After adding a group of inverters INV, a judgment is made. There are three cases in total. In these three cases, the termination lines are set to the same name to ensure consistency and facilitate subsequent execution.
[0096] All the following calculations of unit positions are obtained when adding horizontally from left to right. Similarly, for other orientations, replace addition and subtraction or change calculating x to calculating y to deduce;
[0097] 1) a - 1 < 0.5
[0098] In this case, it directly ends after the first group of INVs and adds the termination line;
[0099] 2) 0.5 <= a - 1 < 1
[0100] In this case, it directly ends after adding a buffer and adds the termination line;
[0101] The x - coordinate of the buffer BUF is x1 + 2 * distance_x + distance_x, and the y - coordinate is y1;
[0102] 3) 1 <= a - 1
[0103] In this case, it judges the number of added inverters INV through a loop;
[0104] The judgment condition of the loop is
[0105] for {set i 0} {i < ($a - 2)} {incr i} {…………}
[0106] That is, set the initial value of i to 0. When i < a - 2 is satisfied, add 1 to i, that is, change from 0 to 1, and execute the commands in the ellipsis within the curly braces. After execution, re - judge whether i is less than a - 2. If it is still satisfied, continue to add 1, that is, change from 1 to 2, until the judgment is not satisfied;
[0107] The commands executed within the curly braces include:
[0108] 1) Set the variable num = i + 1;
[0109] 2) Set last_cell: [expr $trunk_num]_INV1_[expr $i]_$tar;
[0110] 3) Set postfix [expr $i + 1]_$tar;
[0111] That is, the name of the first INV added in a pair is: [expr$trunk_num]_INV0_postfix, and the name of the second INV is [expr$trunk_num]_INV1_postfix. It is found that the last_cell set above is the INV at the last level of the connection relationship among the three standard cells added at the beginning; the connection relationship between the INV added in the loop and the previously added INV can be realized; and the x coordinate of the first INV is $x1+(2*($num+1)-1)*$distance_x, and the y coordinate is y1; the x coordinate of the second INV is $x1+2*($num+1)*$distance_x, and the y coordinate is y1;
[0112] Whether BUF needs to be added at the end depends on two situations:
[0113] I)ab<0.5
[0114] In this case, end directly after the loop and add a termination line;
[0115] II) 0.5 <= ab
[0116] In this case, add a buffer and end directly, adding a termination line;
[0117] The x coordinate of the buffer BUF is the x coordinate of the last INV in the loop plus distance_x, and the y coordinate is y1; the naming suggestion of the added buffer BUF is consistent with the buffer added in case 2); the name of the end line set under all conditions is consistent, so that it can be used as the initial line when the second line segment is needed.
[0118] (3) Set the connection method between line segments:
[0119] Each line segment is executed using the single-segment logic of (1) and (2) above. Except for the different lines connected at the beginning, the rest are the same. Therefore, the end line of the first segment is set as the start line of the second segment to achieve the connection between the line segments, thereby realizing the turning of the optimized path; the second, third, and so on paths;
[0120] When a line segment is less than twice the spacing, there are two solutions:
[0121] The first method: do not add the line segment, but manually add a BUF and a net, and connect the manually added BUF and net to the previous and next line segments of the line segment;
[0122] The second method: directly connect the previous line segment and the next line segment of the line segment, ignore the line segment, and ensure that the current line segment is horizontal or vertical.
[0123] Step S2: Set up a main script and set up global variables for the timing violation path.
[0124] The main script tests the selected BUF and INV types, the specific sizes of the horizontal and vertical spacing, and the properties of the connection by setting a single variable to select the best solution;
[0125] For the TCL script environment, a brief explanation is given. Pre-set the value of a specific string, such as set a1, and then use $a to directly read the value 1. The advantage of this method is that when modifying, you only need to modify the value of the initial set. No matter how many times a is used in the script, this modification will make corresponding changes to all subsequent a, without having to modify them one by one;
[0126] All global variables required by commands in the logic connection script, such as the line name begin_net that needs to be optimized, the standard cell tar_cell at the output end of the optimization line logic connection, the port name tar_term where the standard cell at the output end is connected to the line, the set horizontal spacing distance_x, the set vertical spacing distance_y, the set buffer type BUF_cell, and the set inverter type INV_cell, are all set as variables to move them to the main script and set them together, so as to achieve unified modification of these variables, ensure that they will not be missed, and solidify the logic connection script so that it will not be modified again, avoiding the modification causing the logic connection script to fail to execute. For example, to set the horizontal spacing distance_x, set set distance_x200 in the main script, and in all places in the logic connection script where this specific horizontal spacing 200 is needed, the value $distance_x can be called to replace the specific value 200.
[0127] The logical connection script is calculated in line segment mode, so the main script is also divided into line segments to call the logical connection script multiple times. The starting and ending points of the line segments are set as follows: the x coordinate of the starting point of the line segment is x1; the y coordinate of the starting point of the line segment is y1; the x coordinate of the end point of the line segment is x2; the y coordinate of the end point of the line segment is y2.
[0128] In order to better reduce line delay, the routing attributes are adjusted in the back-end physical design, so the routing attributes are also set in the main script, and the logic of use is also very simple. The layout and routing tool referenced by the example is INNOVUS, in which the command for setting the line attributes is setNetattribute, so the routing attributes are: NDR is set as a parameter for multiple line widths and multiple spacings; NDR rule execution strength is set as NDR_effort; top_route_layer is set for the highest routing layer; bottom_route_layer is set for the lowest routing layer; pre_layer_effort is set to meet the highest and lowest routing layer settings when the tool automatically routes; and net_weight is used as a weight parameter.
[0129] Step S3: Find the timing violation path to be optimized in the floorplan stage.
[0130] Before layout and routing, that is, in the floorplan stage, timing optimization is performed according to the layout plan, replacing the automatic optimization of subsequent tools to achieve the best timing optimization.
[0131] Step S4: according to the information of the timing violation path to be optimized and the layout plan of the design, set the parameters of the starting point, end point and inflection point, set the line name of the timing violation path to be optimized and the name of the connected end point standard cell port.
[0132] Step S5: Based on the logic connection script and the main script, according to different design processes, the standard unit types of the buffer BUF and the inverter INV are changed, the settings of the horizontal and vertical distances between the inserted buffer BUF and the inverter INV are changed, and the required parameters are selected.
[0133] The added standard cells are named with the relevant information of the optimized timing violation path, which is unique and will not cause the script to fail due to repeated naming.
[0134] Step S6: Before layout and routing, complete optimization in the layout and routing PR tool.
[0135] The present invention can also be further applied, for example:
[0136] 1. The coordinates of the starting point and the end point can be obtained through the dbget command, such as [dbget[dbgettop.insts.name cell1–p1].pt_x] to obtain the x coordinate of the cell named cell1, and the y coordinate is pt_y instead of pt_x. In this way, the key logic unit can be located without manually determining the coordinates, thus reducing the manual workload. Furthermore, the name of the net to which it is connected can be obtained through the Pin of the IP or the Port of the IO, and the coordinates of another connected unit of the net can be found. There are many ways to obtain coordinates, which can also achieve a smarter effect.
[0137] 2. Wrap a layer of related scripts outside this script to obtain the coordinates of the starting point and the end point, the starting line (begin_net), and the target cell and term. You can use dbget to obtain the key cells of the path that needs to be optimized.
[0138] 3. You can increase the number of the second segment to achieve path branching while ensuring the connection relationship. Specific settings are required for specific problems. It can be applied to clock trees or bus branches, etc.
[0139] The present invention can also be used to customize key clock trees, manually build clock trees, reduce delays on clock paths, and easily meet setup time requirements; or balance multiple modules or storage bodies that need to be balanced, including address, data, and clock balance, so as to meet read and write requirements.
Claims
1. An automated script writing and usage method for solving long-line timing delay in physical design, It is characterized in that The following steps are involved: Step S1: Setting a logic connection script, for the timing violation path, by setting the starting point, the end point, and the turning point, determining the adding location and connection of the buffer BUF standard unit, and the adding location and connection of the inverter INV standard unit, to ensure logic consistency; Step S2: Setting the main script and setting the global variables of the timing violation path; Step S3: Find the timing violation path to be optimized in the floorplan stage; Step S4: according to the information of the timing violation path to be optimized and the layout plan of the design, set the parameters of the starting point, the end point, and the inflection point, and set the line name of the timing violation path to be optimized and the name of the connected end point standard cell port; Step S5: Based on the logic connection script and the main script, according to different design processes, the standard unit types of the buffer BUF and the inverter INV are changed, the horizontal and vertical spacings between the inserted buffer BUF and the inverter INV are changed, and the required parameters are selected; Step S6: Before layout and routing, complete optimization in the layout and routing PR tool.
2. The method for writing and using an automated script to solve long-line timing delays in physical design according to claim 1, It is characterized in that In step S1, the optimization logic of the logic connection script for the line path to be optimized is to find the coordinates of the starting point and the end point of the line, and calculate according to the coordinate values; first determine the routing direction of up, down, left, and right, and then calculate the path length according to the coordinates of the starting point and the end point, and insert the standard unit of the optimized timing in combination with the set spacing; therefore, first set the coordinates of the starting point and the end point of the timing violation path; set the variables as follows: the x coordinate of the path starting point x_begin, the y coordinate of the path starting point y_begin, the x coordinate of the path end point x_end, and the y coordinate of the path end point y_end; In order to adapt to the specific situation of FloorPlan, set the inflection point in the middle. If branching is required, it can also be achieved through the inflection point. It should be noted that because it is an inflection point, the starting and ending points of the line between every two points must be horizontal and vertical. The inflection point variables are set to: inflection point x coordinate x_trunk*, inflection point y coordinate y_trunk*; the above * is an arbitrary serial number, which is used to distinguish different variables when multiple inflection points are used.
3. The method for writing and using an automated script to solve long-line timing delays in physical design according to claim 2, It is characterized in that In step S1, in the back-end physical design, if the starting and ending coordinates of the timing violation path are fixed after floorplanning, then the specific values are set directly. If they cannot be determined, the corresponding coordinates are found through dbget to provide a feasible solution for the customized path.
4. The method for writing and using an automated script to solve long-line timing delays in physical design according to claim 2, It is characterized in that In step S1, the process of determining the addition location and connection of the buffer BUF standard cell and the addition location and connection of the inverter INV standard cell is as follows: (1) Calculate the number of inverters that need to be inserted based on the length of the line segment: First, the coordinates of the starting point and the end point are used to determine the four directions of up, down, left, and right. Then, the inverter pair number a is calculated based on the distance and the set spacing. Inverters must be added in pairs to ensure logical consistency. However, it cannot be guaranteed that the path length will not exceed the specified length after the inverters are inserted in pairs at a fixed spacing. Therefore, a is rounded and set to b(int(a)). The number of INV pairs to be inserted subsequently is b. b is determined. If (ab) is greater than the specified length, a buffer BUF is inserted. If (ab) is less than the specified length, no buffer is inserted. (2) Set loop logic: The logic of the loop is that when the loop condition is met, a set of inverters INV and their connecting wires net are added, the inverter INV corresponding to the current variable is connected to the inverter of the previous variable, and the coordinate position of the pair of inverters is calculated according to the variables. The position is calculated by accumulating the required distance of the corresponding number on the starting coordinates, so a set of inverters INV and their connecting wires net are added in advance outside the loop; Considering the effect of reducing the conversion time on the delay, a buffer BUF is added at the starting position, and then the first pair of inverters INV is added; the starting position is set to the edge of the starting unit; after the three standard units of the buffer BUF and the first pair of inverters INV are connected to the starting unit, the output end of the last standard unit, that is, the second inverter, is not connected, and is connected in the subsequent judgment; The coordinates of the buffer BUF are calculated, when added horizontally and from left to right: The x coordinate of the first BUF is x1, and the y coordinate is y1; The x coordinate of the first INV is x1+distance_x, and the y coordinate is y1; The x coordinate of the second INV is x1+2*distance_x, and the y coordinate is y1; distance_x is the set horizontal distance; the same applies to other directions; And set a special character target abbreviation tar to name the added standard unit and line, using the character composed of the endpoint standard unit name and its port name; Because the added standard cells and lines need unique names, this ensures that there will be no duplicate names that will cause the script to fail to execute; The naming is as follows: First BUF name: [expr$trunk_num]_BUF_0_$tar First INV name: [expr$trunk_num]_INV0_0_$tar Second INV name: [expr$trunk_num]_INV1_0_$tar trunk_num refers to the line segment number, INV0_0 refers to the 0th INV of the 0th pair of INVs, and INV1_0 refers to the first INV of the 0th pair of INVs; After adding a group of inverters INV, a judgment is made. There are three cases in total. In these three cases, the termination lines are set to the same name to ensure consistency and facilitate subsequent execution. All the following calculations of unit positions are obtained when adding them horizontally from left to right. Similarly, for other orientations, change to addition and subtraction or change from calculating x to calculating y. 1)a-1<0.5 In this case, it directly ends after the first group of INV, and a termination line is added. 2)0.5<=a-1<1 In this case, it directly ends after adding a buffer, and a termination line is added. The x - coordinate of the buffer BUF is x1 + 2*distance_x + distance_x, and the y - coordinate is y1. 3)1<=a-1 In this case, the number of added inverters INV is judged through a loop. The judgment condition of the loop is for{set i 0}{i<($a - 2)}{incr i}{…………} That is, set the initial value of i to 0. When i < a - 2 is satisfied, add 1 to i, that is, change from 0 to 1, and execute the commands in the ellipsis within the curly braces. After execution, re - judge whether i is less than a - 2. If it is still satisfied, continue to add 1, that is, change from 1 to 2, until the judgment is not satisfied. The commands executed within the curly braces include: I) Set the variable num = i + 1; II) Set last_cell: [expr$trunk_num]_INV1_[expr$i]_$tar; III) Set postfix[expr$i + 1]_$tar; That is, the name of the first INV added in pairs is: [expr$trunk_num]_INV0_postfix, and the name of the second INV is [expr$trunk_num]_INV1_postfix. The last_cell set above is the last - level INV in the connection relationship among the three standard cells added at the beginning. In this way, the connection relationship between the INV added within the loop and the previously added INV can be realized. The x - coordinate of the first INV is $x1+(2*($num + 1)-1)*$distance_x, and the y - coordinate is y1; the x - coordinate of the second INV is $x1 + 2*($num + 1)*$distance_x, and the y - coordinate is y1. And whether a BUF needs to be appended at its end is divided into two cases: I) a - b < 0.5 In this case, it directly ends after the loop, and a termination line is added. II) 0.5 <= a - b In this case, it directly ends after adding a buffer, and a termination line is added. The x - coordinate of the buffer BUF is the x - coordinate of the last INV in the loop plus distance_x, and the y - coordinate is y1. It is recommended that the name of the added buffer BUF be the same as the buffer added in case 2). The names of the termination lines set under all conditions are the same, so that it can be used as the initial line when a second - segment line is needed. (3) Set the connection method between line segments: Each line segment is executed using the single-segment logic of (1) and (2) above. Except for the different lines connected at the beginning, the rest are the same. Therefore, the end line of the first segment is set as the start line of the second segment to achieve the connection between the line segments, thereby realizing the turning of the optimized path; the second, third, and so on paths; When a line segment is less than twice the spacing, there are two solutions: The first method: do not add the line segment, but manually add a BUF and a net, and connect the manually added BUF and net to the previous and next line segments of the line segment; The second method: directly connect the previous line segment and the next line segment of the line segment, ignore the line segment, and ensure that the current line segment is horizontal or vertical.
5. The method for writing and using an automated script to solve long-line timing delays in physical design according to claim 4, It is characterized in that In step S2, the main script tests the types of BUF and INV, the specific sizes of the horizontal and vertical spacing, and the properties of the connection by setting a single variable to select the best solution; All global variables required by the commands in the logic connection script include the name of the line to be optimized begin_net; the standard cell tar_cell at the output end of the optimized line logic connection; the port name tar_term at which the output end standard cell is connected to the line; the set horizontal spacing distance_x; the set vertical spacing distance_y; the set buffer type BUF_cell; the set inverter type INV_cell; all are set as variables and moved to the main script for setting together, so as to achieve unified modification of these variables, ensuring that they will not be missed, and solidifying the logic connection script so that it will not be modified again, avoiding the modification causing the logic connection script to be unable to execute.
6. The method for writing and using an automated script to solve long-line timing delays in physical design according to claim 5, It is characterized in that In step S2, the logic connection script is calculated in line segment mode, so the main script is also divided into line segments to call the logic connection script multiple times. The starting and ending points of the line segments are set as follows: the x coordinate of the starting point of the line segment is x1; the y coordinate of the starting point of the line segment is y1; the x coordinate of the end point of the line segment is x2; the y coordinate of the end point of the line segment is y2.
7. The method for writing and using an automated script to solve long-line timing delays in physical design according to claim 5, It is characterized in that In step S2, in order to better reduce line delay, the winding attributes are adjusted in the back-end physical design, so the winding attributes are also set in the main script. The winding attributes are: NDR, a parameter setting for multiple line widths and multiple spacings; NDR_effort, an NDR rule execution strength setting; top_route_layer, a highest winding layer setting; bottom_route_layer, a lowest winding layer setting; pre_layer_effort, a strength that satisfies the highest and lowest winding layer settings when the tool automatically winds; and net_weight, a weight parameter.
8. The method for writing and using an automated script to solve long-line timing delays in physical design according to claim 7, It is characterized in that In step S3, before layout and routing, that is, in the floorplan stage, timing optimization is performed according to the layout plan, replacing the automatic optimization of subsequent tools to achieve the best timing optimization.
9. The method for writing and using an automated script to solve long-line timing delays in physical design according to claim 7, It is characterized in that In step S5, the added standard cells are named with the relevant information of the optimized timing violation path, which is unique and will not cause the script to fail due to repeated naming.
Citation Information
Patent Citations
A time sequence repairing method based on time headroom
CN109583103A
Method and device for computing delay of semiconductor integrated circuit
JP2001325320A
Layout method for semiconductor integrated circuit, layout program for semiconductor integrated circuit, and layout device for semiconductor integrated circuit
JP2014056522A
Timing delay characterization method, memory compiler and computer program product
US20140282318A1
