Circuit layout wiring path generation method, device, medium and apparatus
By generating routing paths by selecting the target grid point with the minimum sum of Manhattan distance and Euclidean distance in the circuit layout, the space waste problem caused by routing rules in the existing technology is solved, and more efficient space utilization is achieved.
Patent Information
- Application Number
- CN202510628348.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-15
- Publication Date
- 2026-11-24
AI Technical Summary
Existing circuit layout routing rules lead to wasted space, failing to effectively utilize the space between routing paths, resulting in wasted space.
A routing path generation method for circuit layout is adopted. In the meshed circuit layout, starting from the routing start point, the target grid point with the smallest sum of Manhattan distance and Euclidean distance to the routing boundary, routing end point and routing start point is selected as the routing point. The routing path is generated step by step, ensuring that the target grid point selected each time gets closer and closer to the routing boundary.
It improves the space utilization of the cabling path, optimizes the cabling layout, and makes the cabling path converge in a fixed direction, reducing space waste.
Smart Images

Figure CN123159246A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of circuit layout design, and in particular to a method, apparatus, medium, and device for generating wiring paths in a circuit layout. Background Technology
[0002] In circuit layout design, after drawing the layout graphics of components, pads, and other circuit entities, routing paths need to be arranged between the connection points of each layout graphic to represent the circuit connection relationship. Usually, automatic routing is used instead of manual routing. Currently, most automatic routing rules find the shortest path between the starting and ending points of the routing path. This routing rule does not consider space utilization, leaving large blank spaces between some routing paths, resulting in wasted space. This causes the space for later routing paths to be occupied by earlier routing paths, preventing their generation. For example... Figure 1 The diagram shows a wiring path generated using existing wiring rules. There are large gaps between different wiring paths (the area shown in grayscale in the diagram), resulting in wasted space. Summary of the Invention
[0003] The purpose of this invention is to provide a method, apparatus, medium, and device for generating wiring paths in circuit layouts, so as to solve the problem of wasted space in the wiring rules of the prior art, and to make the wiring paths converge in a fixed direction, thereby improving space utilization.
[0004] To address the aforementioned technical problems, this invention provides a method for generating routing paths in a circuit layout, applicable to a meshed circuit layout with routing start points, routing end points, and routing boundaries, comprising:
[0005] Add the starting point of the wiring to the wiring point queue, and determine whether the neighboring grid points of the last wiring point in the wiring point queue contain the ending point of the wiring.
[0006] If not included, select the target grid point from the neighboring grid points that has the smallest sum of the vertical distance to the wiring boundary, the Euclidean distance to the wiring end point, and the Manhattan distance to the wiring start point;
[0007] Add the target grid point as a routing point to the routing point queue, and return to the step of determining whether it contains a routing endpoint, until the determination result is that it contains a routing endpoint;
[0008] The endpoint of the wiring is added to the wiring point queue as a wiring point, and each wiring point in the wiring point queue is connected in sequence to generate a wiring path.
[0009] Preferably, selecting the target grid point from neighboring grid points that minimizes the sum of its vertical distance to the wiring boundary, its Euclidean distance to the wiring endpoint, and its Manhattan distance to the wiring start point includes:
[0010] Determine whether there are candidate grid points among the neighboring grid points that meet the preset filtering conditions;
[0011] If it exists, select the target grid point from the candidate grid points that has the smallest sum of the vertical distance to the wiring boundary, the Euclidean distance to the wiring end point, and the Manhattan distance to the wiring start point.
[0012] Preferably, the preset screening conditions include: not belonging to the obstacle grid point, the line connecting to the last wiring point in the wiring point queue does not intersect with the wiring boundary, and / or the angle between the line connecting to the last wiring point in the wiring point queue and the line connecting the last wiring point in the wiring point queue and the previous wiring point is greater than 90°, wherein when there is only one wiring point in the wiring point queue, the previous wiring point is the preset point.
[0013] Preferably, the obstacle grid points are wiring points on the generated wiring path, and / or grid points covered by obstacle graphics marked as obstacles in the circuit layout.
[0014] Preferably, the preset point is the other endpoint of the line segment where the wiring start point is located.
[0015] Preferably, selecting the target grid point from neighboring grid points that minimizes the sum of its vertical distance to the wiring boundary, its Euclidean distance to the wiring endpoint, and its Manhattan distance to the wiring start point further includes:
[0016] If it does not exist, delete the last wiring point in the wiring point queue and exclude its corresponding grid point from the neighboring grid points of any grid point, and return to the step of determining whether there is a candidate grid point that meets the preset filtering conditions, until the wiring point queue is empty.
[0017] Preferably, the application of the circuit layout routing path generation method in quantum chip design, wherein the circuit layout is a quantum chip layout, the quantum chip layout includes a quantum bit array, the routing start point is a pin point inside the quantum bit array, the routing end point is a pin point outside the quantum bit array, and the routing boundary is a read signal line coupled to the quantum bit array.
[0018] To address the aforementioned technical problems, the present invention also provides a wiring path generation device for circuit layouts, applied to meshed circuit layouts having wiring start points, wiring end points, and wiring boundaries, comprising:
[0019] The judgment module is used to add the wiring start point as a wiring point to the wiring point queue, and to determine whether the neighboring grid points of the last wiring point in the wiring point queue contain the wiring end point.
[0020] The selection module is used to select a target grid point from neighboring grid points that has the smallest sum of vertical distance to the wiring boundary, Euclidean distance to the wiring end point, and Manhattan distance to the wiring start point, when the wiring end point is not included.
[0021] The update module is used to add the target grid point as a routing point to the routing point queue and return to the step of determining whether it contains a routing endpoint, until the determination result is that it contains a routing endpoint;
[0022] The generation module is used to add the wiring endpoint as a wiring point to the wiring point queue, and sequentially connect each wiring point in the wiring point queue to generate a wiring path.
[0023] To address the aforementioned technical problems, the present invention also provides a storage medium storing a computer program configured to execute the wiring path generation method for the circuit layout described in any of the preceding claims during runtime.
[0024] To address the aforementioned technical problems, the present invention also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute the wiring path generation method for the circuit layout described in any of the preceding claims.
[0025] Unlike existing technologies, the wiring path generation method for circuit layout provided by this invention, in a gridded circuit board diagram, starts with the wiring start point and adds it to the wiring point queue. In the last wiring point in the queue, the neighboring grid points do not contain the wiring endpoint. From these neighboring grid points, the target grid point with the smallest sum of the vertical distance to the wiring boundary, the Euclidean distance to the wiring endpoint, and the Manhattan distance to the wiring start point is selected and added to the wiring point queue. This process is repeated until the neighboring grid points of the last wiring point contain the wiring endpoint. At this point, the wiring endpoint is added to the wiring point queue, and each wiring point is connected sequentially to generate the wiring path. Because the vertical distance from the target grid point to the wiring boundary is considered each time a target grid point is selected, the selected target grid point gets closer and closer to the wiring boundary. Therefore, the final wiring path also tends to move closer to the wiring boundary. This application enables the wiring path to converge in a fixed direction, improving space utilization and optimizing the wiring layout.
[0026] The wiring path generation apparatus, storage medium, and electronic device for circuit layout provided by this invention belong to the same inventive concept as the wiring path generation method for circuit layout, and therefore have the same beneficial effects, which will not be repeated here. Attached Figure Description
[0027] Figure 1 This is a schematic diagram of a wiring path generated using existing wiring rules.
[0028] Figure 2 This is a flowchart illustrating a method for generating wiring paths in a circuit layout according to an embodiment of the present invention.
[0029] Figure 3 This is a schematic diagram of the start and end points of routing in a gridded circuit layout.
[0030] Figure 4 According to Figure 3 A diagram showing the addition of 7 wiring points to the wiring point queue.
[0031] Figure 5 A schematic diagram of the wiring path generated to connect 7 wiring points.
[0032] Figure 6 This is a schematic diagram of another pair of routing start and end points in a gridded circuit layout.
[0033] Figure 7 According to Figure 6 A diagram showing the addition of 4 routing points to the routing point queue.
[0034] Figure 8 According to Figure 6 A diagram showing the addition of 5 routing points to the routing point queue.
[0035] Figure 9 According to Figure 6 A diagram showing the addition of 6 wiring points to the wiring point queue.
[0036] Figure 10 According to Figure 6 A diagram showing the addition of 7 wiring points to the wiring point queue.
[0037] Figure 11 According to Figure 6 A diagram showing the addition of 10 wiring points to the wiring point queue.
[0038] Figure 12 To generate the routing path using the routing path generation method of this application Figure 1 The diagram shows the wiring paths between multiple wiring start points ABCDE and wiring end points VWXYZ.
[0039] Figure 13A schematic block diagram of a wiring path generation device for a circuit layout provided in another embodiment of the present invention. Detailed Implementation
[0040] The specific embodiments of the present invention will now be described in more detail with reference to the accompanying drawings. The advantages and features of the present invention will become clearer from the following description and claims. It should be noted that the drawings are all in a very simplified form and use non-precise proportions, and are only used to facilitate and clarify the illustration of the embodiments of the present invention.
[0041] In the description of this invention, it should be understood that the terms "center", "upper", "lower", "left", "right", etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on this invention.
[0042] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this invention, "a plurality of" means at least two, such as two, three, etc., unless otherwise explicitly specified.
[0043] Please see Figure 2 This invention provides a method for generating routing paths in a circuit layout. This method is applied to a meshed circuit layout with routing start points, routing end points, and routing boundaries. After the circuit layout is meshed, each routing start point and routing end point corresponds to a grid point. The routing path generation method includes the following steps:
[0044] S1: Add the starting point of the wiring as a wiring point to the wiring point queue, and determine whether the neighboring grid points of the last wiring point in the wiring point queue contain the wiring end point.
[0045] When a routing start point is added to the routing point queue, the number of routing points in the queue changes from 0 to 1. The last routing point in the queue is then the routing start point. If the routing start point and the routing end point are adjacent grid points, the routing end point is one of the neighboring grid points of the routing start point; otherwise, it is not a neighboring grid point of the routing start point.
[0046] S2: If not included, select the target grid point from the neighboring grid points that has the smallest sum of vertical distance to the wiring boundary, Euclidean distance to the wiring end point, and Manhattan distance to the wiring start point.
[0047] If there is more than one target grid point with the smallest sum, one of them can be selected randomly or selected according to a preset strategy.
[0048] S3: Add the target grid point as a routing point to the routing point queue, and return to the step of determining whether it contains the routing endpoint, until the determination result is that it contains the routing endpoint.
[0049] In this process, after the target grid point is added to the routing point queue as a routing point, the number of routing points in the queue increases by one, and the target grid point becomes the last routing point in the routing point queue. When returning to determine whether the neighboring grid points of the last routing point in the routing point queue contain the routing endpoint, the last routing point becomes the newly added routing point, and a new target grid point is selected. That is, steps S2 and S3 will be repeated continuously until a situation occurs where the neighboring grid points of the last routing point in the routing point queue contain the routing endpoint, at which point the repetition process ends.
[0050] S4: Add the routing endpoint as a routing point to the routing point queue, and connect each routing point in the routing point queue in sequence to generate a routing path.
[0051] In the wiring point queue, if the neighboring grid point of the last wiring point contains the wiring endpoint, the wiring endpoint is added to the wiring point queue as a wiring point. A wiring path is generated by connecting each wiring point in the wiring point queue in the order in which they are added to the queue.
[0052] The following will illustrate the process of generating wiring paths with reference to the accompanying diagram.
[0053] Please see Figure 3 This is a schematic diagram of the start and end points of a routing layout in a meshed circuit diagram. The coordinates of the routing start point A are (2,6), the coordinates of the routing end point B are (5,2), and the equation of the routing boundary L is y = 0, which is the X-axis.
[0054] First, the routing start point A is added to the routing point queue, making it the last routing point in the queue. Since the routing endpoint B is not among the neighboring grid points of routing point A, the target grid point is selected from the neighboring grid points A1, A2, A3, A4, A5, A6, A7, and A8. The perpendicular distances from the neighboring grid points A1, A2, A3, A4, A5, A6, A7, and A8 to the routing boundary L are 5, 5, 6, 7, 7, 7, 6, and 5, respectively. The Euclidean distances from the neighboring grid points A1, A2, A3, A4, A5, A6, A7, and A8 to the routing endpoint B are 4.24, 3.61, 4.47, 5.39, 5.83, 6.4, 5.66, and 5, respectively (rounded to two decimal places). The distances from the neighboring grid points A1, A2, A3, A4, A5, A6, A7, and A8 to the routing endpoint B are... The Manhattan distances from the starting point A are 1, 2, 1, 2, 1, 2, 1, 2. The sums of their perpendicular distances, Euclidean distances, and Manhattan distances are 10.24, 10.61, 11.47, 14.39, 13.83, 15.4, 12.66, and 12, respectively. The sum of the nearest grid point A1 is the smallest, so the nearest grid point A1 is selected as the target grid point. The target grid point A1 is added to the routing point queue as a routing point. The routing points in the routing point queue are A and A1 in sequence, and the routing point A1 becomes the last routing point.
[0055] like Figure 4 As shown, the neighboring grid points of routing point A1 do not include the routing endpoint B. Therefore, from the neighboring grid points of routing point A1, select the target grid point C1 with the smallest sum of vertical distance to the routing boundary, Euclidean distance to the routing endpoint, and Manhattan distance to the routing start point. Add the target grid point C1 as a routing point to the routing point queue. The routing points in the routing point queue are A, A1, and C1 in sequence, and routing point C1 becomes the last routing point.
[0056] Continue reading Figure 4 The above process is repeated continuously to obtain routing points D1, E2, and F3 in sequence. The routing points in the routing point queue are A, A1, C1, D1, E2, and F3, with routing point F3 becoming the last routing point. When routing point D1 is the last routing point in the routing point queue, there are two target mesh points with the smallest total sum. This application selects the one closest to the routing endpoint B, namely E2, as the target mesh point. Similarly, when routing point E2 is the last routing point in the routing point queue, there are two target mesh points with the smallest total sum. This application selects the one closest to the routing endpoint B, namely F3, as the target mesh point.
[0057] As can be seen from the figure, since the vertical distance from the target grid point to the wiring boundary L is taken into account each time the target grid point is selected, the selected target grid point gets closer and closer to the wiring boundary L each time.
[0058] Please see Figure 5 The neighboring grid points of routing point F3 include routing endpoint B. Therefore, routing endpoint B is added to the routing point queue as a routing point. The routing points in the routing point queue are A, A1, C1, D1, E2, F3, and B in sequence. Connecting routing points A, A1, C1, D1, E2, F3, and B in sequence generates a routing path (i.e., the solid line connecting A, A1, C1, D1, E2, F3, and B in sequence in the figure). As can be seen from the figure, the routing path first extends towards the routing boundary, and then extends in a direction roughly parallel to the routing boundary. Compared with the routing path placed directly near the line connecting the routing start point A and the routing endpoint B, the routing path of this application is closer to the routing boundary, thus improving space utilization and optimizing the routing layout.
[0059] In some embodiments of this application, selecting a target grid point from neighboring grid points that minimizes the sum of its vertical distance to the wiring boundary, its Euclidean distance to the wiring endpoint, and its Manhattan distance to the wiring start point includes:
[0060] S21: Determine whether there are candidate grid points among the neighboring grid points that meet the preset filtering conditions.
[0061] In some routing applications, some of the neighboring grid points of the last routing point in the routing point queue cannot be selected as target grid points because they do not meet the preset filtering conditions. Therefore, the target grid point does not necessarily need to be selected from all neighboring grid points. Instead, it is only necessary to determine which neighboring grid points meet the preset filtering conditions and use these neighboring grid points as candidate grid points, which can reduce the amount of computation.
[0062] In this embodiment, the preset screening conditions include: not belonging to the obstacle grid point, the line connecting to the last wiring point in the wiring point queue does not intersect the wiring boundary, and / or the angle between the line connecting to the last wiring point in the wiring point queue and the line connecting the last wiring point in the wiring point queue and the previous wiring point is greater than 90°. When there is only one wiring point in the wiring point queue, the previous wiring point is the preset point.
[0063] Specifically, if a neighboring grid point of the last wiring point in the wiring point queue is not an obstacle grid point, then that neighboring grid point is a candidate grid point; if the line connecting a neighboring grid point of the last wiring point in the wiring point queue to the last wiring point in the queue does not intersect the wiring boundary, then that neighboring grid point is a candidate grid point; if the angle between the line connecting a neighboring grid point to the last wiring point in the queue and the line connecting the last wiring point to the previous wiring point in the queue is greater than 90°, then that neighboring grid point is a candidate grid point. In other words, if any one or all of these three conditions are met, the corresponding neighboring grid point is a candidate grid point.
[0064] Obstacle grid points are grid points corresponding to obstacles that block routing paths. In some applications, obstacle grid points can be routing points on already generated routing paths, or grid points covered by obstacle graphics marked as obstacles in the circuit layout. In other words, for the start and end points of unrouted routing paths, other generated routing paths are considered obstacles.
[0065] The line connecting the neighboring grid point to the last routing point in the routing point queue does not intersect the routing boundary, indicating that candidate grid points are not allowed to cross the routing boundary.
[0066] If the angle between the line connecting the candidate grid point and the last routing point in the routing point queue, and the line connecting the last routing point in the routing point queue to the previous routing point, is greater than 90°, it means that any routing point on the routing path is either on the same straight line as the lines connecting it to the two preceding and following routing points, or the angle between them is 135 degrees. In practical circuit design, considering factors such as reducing signal interference during transmission, improving circuit reliability, and saving routing space, routing paths usually adopt broken lines with an angle of 135 degrees. If the routing start point is the only routing point in the routing point queue, and there is no previous routing point, a preset point can be used as the previous routing point. The preset point can be selected according to actual needs, such as a point selected on the circuit layout, or the other endpoint of the line segment where the routing start point is located.
[0067] S22: If it exists, select the target grid point from the candidate grid points that has the smallest sum of the vertical distance to the wiring boundary, the Euclidean distance to the wiring end point, and the Manhattan distance to the wiring start point.
[0068] Furthermore, selecting the target grid point from neighboring grid points that minimizes the sum of its vertical distance to the wiring boundary, its Euclidean distance to the wiring endpoint, and its Manhattan distance to the wiring start point also includes:
[0069] S23: If it does not exist, delete the last wiring point in the wiring point queue and exclude its corresponding grid point from the neighboring grid points of any grid point. Return to the step of determining whether there is a candidate grid point that meets the preset filtering conditions, until the wiring point queue is empty.
[0070] In this process, whenever the last routing point in the routing point queue is deleted, the corresponding grid point will no longer belong to any neighboring grid point during the subsequent routing path search. By repeating steps S21 to S23, the routing points in the routing point queue will be traced back one step, and this process will be repeated until the first routing point in the routing point queue is deleted because there are no candidate grid points, that is, the routing point queue is empty.
[0071] The following example, with reference to the accompanying diagram, illustrates the process of generating a wiring path with preset filtering conditions. In this example, the preset filtering conditions include the three conditions mentioned above.
[0072] Please see Figure 6 This is a schematic diagram of another pair of routing start and end points in a meshed circuit layout. The coordinates of routing start point A are (2,6), and the coordinates of routing end point B are (10,2). The equation of the preset routing boundary L is y=0, which is the X-axis. The gray-filled grid in the figure represents obstacles, and the grid points corresponding to obstacles are all obstacle grid points. The coordinates of the preset point T are (0,8).
[0073] First, the routing start point A is taken as the routing point, and the routing point queue is A. Since the routing endpoint B is not included in the neighboring grid points of routing point A, there are candidate grid points A1, A2, and A3 that meet the preset screening conditions among the neighboring grid points A1, A2, A3, A4, A5, A6, A7, and A8 of routing point A. The perpendicular distances from candidate grid points A1, A2, and A3 to the routing boundary L are 5, 5, and 6, respectively. The Euclidean distances from candidate grid points A1, A2, and A3 to the routing endpoint B are 8.54, 7.62, and 8.06, respectively (rounded to two decimal places). The Manhattan distances from candidate grid points A1, A2, and A3 to the routing start point A are 1, 2, and 1, respectively. Therefore, the sums of their perpendicular distances, Euclidean distances, and Manhattan distances are 14.54, 14.62, and 15.06, respectively. Candidate grid point A1 has the smallest sum, so candidate grid point A1 is selected as the target grid point and added to the routing point queue. The routing point queue is now A1.
[0074] like Figure 7As shown, the neighboring grid points of routing point A1 do not include the routing endpoint B. Among the neighboring grid points of routing point A1, there are candidate grid points C1, C2, and C8 that meet the preset filtering conditions. The perpendicular distance from candidate grid points C1, C2, and C8 to the routing boundary L is 4. The Euclidean distances from candidate grid points C1, C2, and C8 to the routing endpoint B are 8.25, 7.28, and 9.22, respectively. The Manhattan distances from candidate grid points C1, C2, and C8 to the routing start point A are 2, 3, and 3, respectively. Therefore, the sum of their perpendicular distance, Euclidean distance, and Manhattan distance are 14.25, 14.28, and 16.22, respectively. The sum of candidate grid point C1 is the smallest. Therefore, candidate grid point C1 is selected as the target grid point and added to the routing point queue. The routing point queue is A, A1, and C1.
[0075] Continue reading Figure 7 The neighboring grid points of routing point C1 do not include the routing endpoint B, but there are no candidate grid points among the neighboring grid points of routing point C1 that meet the preset screening criteria. This is because neighboring grid points that conform to the 135-degree routing rule are all obstacle grid points. Therefore, the last routing point C1 in the routing point queue is deleted, and the routing point queue becomes A, A1. Routing point C1 is no longer a neighboring grid point of any grid point. At this time, the last routing point in the routing point queue is A1. The process returns to determine whether there are candidate grid points among the neighboring grid points of routing point A1 that meet the preset screening criteria. At this time, the candidate grid points of routing point A1 are determined to be C2 and C8. Since the sum of the vertical distance, Euclidean distance, and Manhattan distance of candidate grid points C2 and C8 has been calculated, it can be seen that the sum of candidate grid point C2 is the smallest. Therefore, candidate grid point C2 is selected as the target grid point and added to the routing point queue, and the routing point queue becomes A, A1, C2.
[0076] Continue reading Figure 7 The neighboring grid points of routing point C2 do not include routing endpoint B. Among the neighboring grid points of routing point C2, there is a candidate grid point D3 that meets the preset filtering conditions. Since there is only one candidate grid point, the sum of the vertical distance, Euclidean distance and Manhattan distance of candidate grid point D3 can be considered to be the minimum. Therefore, candidate grid point D3 is selected as the target grid point and added to the routing point queue. The routing point queue becomes A, A1, C2 and D3.
[0077] like Figure 8As shown, the neighboring grid points of routing point D3 do not include the routing endpoint B. Among the neighboring grid points of routing point D3, there are candidate grid points E2, E3, and E4 that meet the preset filtering conditions. The perpendicular distances of candidate grid points E2, E3, and E4 to the routing boundary L are 3, 4, and 5, respectively. The Euclidean distances of candidate grid points E2, E3, and E4 to the routing endpoint B are 5.10, 5.39, and 5.83, respectively. The Manhattan distances of candidate grid points E2, E3, and E4 to the routing start point A are 6, 5, and 4, respectively. Therefore, the sum of their perpendicular distance, Euclidean distance, and Manhattan distance are 14.10, 14.39, and 14.83, respectively. The sum of candidate grid point E2 is the smallest. Therefore, candidate grid point E2 is selected as the target grid point and added to the routing point queue. The routing point queue becomes A, A1, C2, D3, and E2.
[0078] like Figure 9 As shown, the neighboring grid points of routing point E2 do not include the routing endpoint B. Among the neighboring grid points of routing point E2, there are candidate grid points F1, F2, and F3 that meet the preset screening conditions. The vertical distances of candidate grid points F1, F2, and F3 to the routing boundary L are 2, 2, and 3, respectively. The Euclidean distances of candidate grid points F1, F2, and F3 to the routing endpoint B are 5, 4, and 4.12, respectively. The Manhattan distances of candidate grid points F1, F2, and F3 to the routing start point A are 7, 8, and 7, respectively. Therefore, the sum of their vertical distance, Euclidean distance, and Manhattan distance are 14, 14, and 14.12, respectively. The sum of candidate grid points F1 and F2 is the smallest. Therefore, any one of them is selected as the new routing point. In this embodiment, candidate grid point F2 is selected as the target grid point and added to the routing point queue. The routing point queue becomes A, A1, C2, D3, E2, and F2.
[0079] like Figure 10 As shown, the neighboring grid points of routing point F2 do not include the routing endpoint B. Among the neighboring grid points of routing point F2, there are candidate grid points G1, G2, and G3 that meet the preset filtering conditions. The perpendicular distances of candidate grid points G1, G2, and G3 to the routing boundary L are 1, 1, and 2, respectively. The Euclidean distances of candidate grid points G1, G2, and G3 to the routing endpoint B are 4.12, 3.16, and 3, respectively. The Manhattan distances of candidate grid points G1, G2, and G3 to the routing start point A are 9, 10, and 9, respectively. Therefore, the sum of their perpendicular distance, Euclidean distance, and Manhattan distance are 14.12, 14.16, and 14, respectively. The sum of candidate grid point G3 is the smallest. Therefore, candidate grid point G3 is selected as the target grid point and added to the routing point queue. The routing point queue becomes A, A1, C2, D3, E2, F2, and G3.
[0080] like Figure 11As shown, the neighboring grid points of routing point G3 do not include the routing endpoint B. Among the neighboring grid points of routing point G3, there are candidate grid points H2, H3, and H4 that meet the preset screening conditions. The perpendicular distances of candidate grid points H2, H3, and H4 to the routing boundary L are 1, 2, and 3, respectively. The Euclidean distances of candidate grid points H2, H3, and H4 to the routing endpoint B are 2.24, 2, and 2.24, respectively. The Manhattan distances of candidate grid points H2, H3, and H4 to the routing start point A are 11, 10, and 9, respectively. Therefore, the sum of their perpendicular distance, Euclidean distance, and Manhattan distance are 14.24, 14, and 14.24, respectively. The sum of candidate grid point H3 is the smallest. Therefore, candidate grid point H3 is selected as the target grid point and added to the routing point queue. The routing point queue becomes A, A1, C2, D3, E2, F2, G3, and H3.
[0081] Continue reading Figure 11 The neighboring grid points of routing point H3 do not include the routing endpoint B. Among the neighboring grid points of routing point H3, there are candidate grid points I2, I3, and I4 that meet the preset screening conditions. The perpendicular distances of candidate grid points I2, I3, and I4 to the routing boundary L are 1, 2, and 3, respectively. The Euclidean distances of candidate grid points I2, I3, and I4 to the routing endpoint B are 1.41, 1, and 1.41, respectively. The Manhattan distances of candidate grid points I2, I3, and I4 to the routing start point A are 12, 11, and 10, respectively. Therefore, the sum of their perpendicular distance, Euclidean distance, and Manhattan distance is 14.41, 14, and 14.41, respectively. The sum of candidate grid point I3 is the smallest. Therefore, candidate grid point I3 is selected as the target grid point and added to the routing point queue. The routing point queue becomes A, A1, C2, D3, E2, F2, G3, H3, and I3.
[0082] Continue reading Figure 11 If the neighboring grid points of routing point I3 include routing endpoint B, then routing endpoint B is added to the routing point queue as a routing point. The routing point queue becomes A, A1, C2, D3, E2, F2, G3, H3, I3, B. A routing path is generated by sequentially connecting each routing point in the routing point queue: A, A1, C2, D3, E2, F2, G3, H3, I3, B (i.e., the solid lines in the diagram that sequentially connect A, A1, C2, D3, E2, F2, G3, H3, I3, B). When routing to other routing start and end points subsequently, the routing points traversed by this routing path are considered obstacle grid points for those other routing start and end points.
[0083] The routing path generation method of this embodiment can make the routing path as close as possible to the routing boundary. When routing from multiple routing starting points, it can make the routing path layout more compact and improve the utilization rate of routing space. Figure 12The image shown is generated using the routing path generation method of this application. Figure 1 The diagram shows the wiring paths between multiple wiring start points ABCDE and wiring end points VWXYZ. As can be seen from the diagram, the wiring paths are closer to the wiring boundary L, and the layout is more compact.
[0084] The circuit layout routing path generation method of this application can meet the layout design needs of different requirements. For example, the circuit layout routing path generation method of this application is applied in quantum chip design. In this application, the circuit layout is a quantum chip layout, which includes a quantum bit array. The routing start point is the pin point inside the quantum bit array, the routing end point is the pin point outside the quantum bit array, and the routing boundary is the read signal line coupled to the quantum bit array.
[0085] Please refer to Figure 13 Another embodiment of the present invention provides a wiring path generation device for circuit layouts. This device is applied to a meshed circuit layout having wiring start points, wiring end points, and wiring boundaries. After the circuit layout is meshed, each wiring start point and wiring end point corresponds to a grid point. The wiring path generation device includes:
[0086] The judgment module 11 is used to add the starting point of the wiring as a wiring point to the wiring point queue, and to determine whether the neighboring grid points of the last wiring point in the wiring point queue contain the ending point of the wiring.
[0087] When a routing start point is added to the routing point queue, the number of routing points in the queue changes from 0 to 1. The last routing point in the queue is then the routing start point. If the routing start point and the routing end point are adjacent grid points, the routing end point is one of the neighboring grid points of the routing start point; otherwise, it is not a neighboring grid point of the routing start point.
[0088] Selection module 12 is used to select, from neighboring grid points, the target grid point with the smallest sum of vertical distance to the wiring boundary, Euclidean distance to the wiring endpoint, and Manhattan distance to the wiring start point, when the wiring endpoint is not included.
[0089] If there is more than one target grid point with the smallest sum, one of them can be selected randomly or selected according to a preset strategy.
[0090] The update module 13 is used to add the target grid point as a routing point to the routing point queue and return the step of determining whether it contains the routing endpoint until the determination result is that it contains the routing endpoint.
[0091] In this process, after the target grid point is added to the routing point queue as a routing point, the number of routing points in the queue increases by one, and the target grid point becomes the last routing point in the routing point queue. When returning to determine whether the neighboring grid points of the last routing point in the routing point queue contain the routing endpoint, the last routing point becomes the newly added routing point, and a new target grid point is selected. That is, steps S2 and S3 will be repeated continuously until a situation occurs where the neighboring grid points of the last routing point in the routing point queue contain the routing endpoint, at which point the repetition process ends.
[0092] The generation module 14 is used to add the wiring endpoint as a wiring point to the wiring point queue, and sequentially connect each wiring point in the wiring point queue to generate a wiring path.
[0093] In the wiring point queue, if the neighboring grid point of the last wiring point contains the wiring endpoint, the wiring endpoint is added to the wiring point queue as a wiring point. A wiring path is generated by connecting each wiring point in the wiring point queue in the order in which they are added to the queue.
[0094] The circuit layout routing path generation apparatus of this embodiment may also include other technical features of the circuit layout routing path generation method of the foregoing embodiment, implement all the steps of the circuit layout routing path generation method of the foregoing embodiment, and have the same technical effects as the circuit layout routing path generation method of the foregoing embodiment, which will not be repeated here.
[0095] The present invention also provides a storage medium storing a computer program configured to execute the wiring path generation method of the circuit layout of the foregoing embodiments when running.
[0096] Specifically, in this embodiment, the storage medium may include, but is not limited to, USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, or optical disks, and other media capable of storing computer programs.
[0097] The present invention also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program and the processor is configured to run the computer program to execute the wiring path generation method of the circuit layout of the foregoing embodiments.
[0098] Specifically, the memory and processor can be connected via a data bus. Furthermore, the aforementioned electronic device may also include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.
[0099] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "example," or "specific example," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments. In addition, those skilled in the art can combine and integrate the different embodiments or examples described in this specification.
[0100] The above are merely preferred embodiments of the present invention and do not constitute any limitation on the present invention. Any equivalent substitutions or modifications made by those skilled in the art to the technical solutions and content disclosed in the present invention without departing from the scope of the present invention shall be deemed to have remained within the protection scope of the present invention.
Claims
1. A method of generating a routing path of a circuit layout, characterized by, Circuit layouts with routing start points, routing end points, and routing boundaries applied to meshing include: Add the starting point of the wiring to the wiring point queue, and determine whether the neighboring grid points of the last wiring point in the wiring point queue contain the ending point of the wiring. If not included, select the target grid point from the neighboring grid points that has the smallest sum of the vertical distance to the wiring boundary, the Euclidean distance to the wiring end point, and the Manhattan distance to the wiring start point; Add the target grid point as a routing point to the routing point queue, and return to the step of determining whether it contains a routing endpoint, until the determination result is that it contains a routing endpoint; The endpoint of the wiring is added to the wiring point queue as a wiring point, and each wiring point in the wiring point queue is connected in sequence to generate a wiring path.
2. The wiring path generation method according to claim 1, wherein The selection of a target grid point from neighboring grid points that minimizes the sum of its vertical distance to the wiring boundary, its Euclidean distance to the wiring endpoint, and its Manhattan distance to the wiring start point includes: Determine whether there are candidate grid points among the neighboring grid points that meet the preset filtering conditions; If it exists, select the target grid point from the candidate grid points that has the smallest sum of the vertical distance to the wiring boundary, the Euclidean distance to the wiring end point, and the Manhattan distance to the wiring start point.
3. The wiring path generation method according to claim 2, wherein The preset screening conditions include: not belonging to the obstacle grid point, the line connecting to the last wiring point in the wiring point queue does not intersect the wiring boundary, and / or the angle between the line connecting to the last wiring point in the wiring point queue and the line connecting the last wiring point in the wiring point queue to the previous wiring point is greater than 90°, wherein when there is only one wiring point in the wiring point queue, the previous wiring point is the preset point.
4. The wiring path generation method according to claim 3, wherein The obstacle grid points are wiring points on the generated wiring paths, and / or grid points covered by obstacle graphics marked as obstacles in the circuit layout.
5. The wiring path generation method according to claim 3, wherein The preset point is the other endpoint of the line segment where the wiring start point is located.
6. The wiring path generation method according to any one of claims 2 to 5, characterized in that, The selection of a target grid point from neighboring grid points that minimizes the sum of its vertical distance to the wiring boundary, its Euclidean distance to the wiring endpoint, and its Manhattan distance to the wiring start point also includes: If it does not exist, delete the last wiring point in the wiring point queue and exclude its corresponding grid point from the neighboring grid points of any grid point, and return to the step of determining whether there is a candidate grid point that meets the preset filtering conditions, until the wiring point queue is empty.
7. The application of the circuit layout wiring path generation method according to any one of claims 1 to 6 in quantum chip design, characterized in that, The circuit layout is a quantum chip layout, which includes a quantum bit array. The wiring start point is a pin point inside the quantum bit array, the wiring end point is a pin point outside the quantum bit array, and the wiring boundary is a read signal line coupled to the quantum bit array.
8. A wiring path generation device for circuit layout, characterized in that, Circuit layouts with routing start points, routing end points, and routing boundaries applied to meshing include: The judgment module is used to add the wiring start point as a wiring point to the wiring point queue, and to determine whether the neighboring grid points of the last wiring point in the wiring point queue contain the wiring end point. The selection module is used to select a target grid point from neighboring grid points that has the smallest sum of vertical distance to the wiring boundary, Euclidean distance to the wiring end point, and Manhattan distance to the wiring start point, when the wiring end point is not included. The update module is used to add the target grid point as a routing point to the routing point queue and return to the step of determining whether it contains a routing endpoint, until the determination result is that it contains a routing endpoint; The generation module is used to add the wiring endpoint as a wiring point to the wiring point queue, and sequentially connect each wiring point in the wiring point queue to generate a wiring path.
9. A storage medium, characterized in that, The storage medium stores a computer program, which is configured to execute the wiring path generation method for the circuit layout as described in any one of claims 1 to 6 when it is run.
10. An electronic device, characterized in that, The device includes a memory and a processor, wherein the memory stores a computer program and the processor is configured to run the computer program to perform the wiring path generation method for a circuit layout as described in any one of claims 1 to 6.
