Signal location information storage method based on signal quantity, electronic device and medium

By using the signal -based signal location information storage method in the EDA debugging tool, build multiple storage units to balance the number of storage signals, solve the problem of reducing the search speed caused by a large number of signals in the code row, and achieve efficient signal access.

CN118689400BActive Publication Date: 2025-01-24成都融见软件科技有限公司 +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410787689.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-18
Publication Date
2025-01-24
Estimated Expiration
2044-06-18

AI Technical Summary

Technical Problem

When existing EDA debugging tools process a large number of signals in code lines, the search speed is greatly reduced, resulting in obvious sense of lag in signal search.

Method used

The signal location information storage method based on the number of signals is adopted, and multiple storage units are constructed to evenly store the number of signals in different code ranges, thereby improving the signal search speed.

Benefits of technology

It greatly improves the signal search speed and access efficiency, and reduces the lag in signal search.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118689400B_ABST
    Figure CN118689400B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of computer technology, and in particular, to a method for storing signal position information based on the number of signals, an electronic device, and a medium. Step S1: Obtain F, initially set j = 1, and initially set i = 1; Step S2: Construct A j =(F j , L j ). When j = 1, F j = F; Step S3: Determine whether there is an i-th signal. If so, obtain D i , and execute Step S4. Otherwise, end the process; Step S4: If LS j < M, then execute Step S5. If LS j = M, then execute Step S6; Step S5: Store D i in L j , set i = i + 1, and return to Step S3; Step S6: Set j = j + 1, construct A j =(F j , L j ), and return to Step S5. The present invention can reasonably store signal position information based on the number of signals, improving the access efficiency of signals.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a signal position information storage method based on signal quantity, electronic equipment and medium. Background Art

[0002] In the Electronic Design Automation (EDA) debugging tool, developers will perform various operations on the signals in the code in the source code view, and the EDA debugging tool will also prompt the user as much as possible in the tool that there are design signals in the source code view, so as to quickly locate the signal position and make corresponding operations. Because the number of signals in different ranges in the source code and the signal distribution are random and unpredictable. Generally, the EDA debugging tool adopts a signal storage solution based on code lines. When the user wants to locate the signal at the source code, the signal list in the line will be pre-located by the line number, and then the specific signal will be found in the signal list of the line. However, when a certain line of code has a lot of content and contains a large number of signals, the search speed of this method will be greatly reduced, resulting in a significant sense of jamming in the signal search. It can be seen from this that how to reasonably store signal location information and improve signal access efficiency has become a technical problem that needs to be solved urgently. Summary of the invention

[0003] The purpose of the present invention is to provide a signal location information storage method based on the number of signals, an electronic device and a medium, which can reasonably store signal location information based on the number of signals and improve the access efficiency of signals.

[0004] According to a first aspect of the present invention, there is provided a method for storing signal position information based on the number of signals, comprising:

[0005] Step S1, obtaining the offset value F of the first character of the code range to be processed relative to the code file where the code range to be processed is located, initially setting the storage unit number j=1, and initially setting the signal number i=1;

[0006] Step S2: construct the corresponding binary information A in the jth storage unit j =(F j ,L j ), each A j Corresponds to a code processing range, where F j A j The offset value of the first character of the corresponding code processing range relative to the code file where the code range to be processed is located. When j=1, F j =F,L j A j The corresponding signal list, L j The initial setting is empty;

[0007] Step S3: Traverse the range of the code to be processed, and determine whether there is an i-th signal. If so, obtain the position information D of the i-th signal i , and execute Step S4; otherwise, end the process;

[0008] Step S4: Determine the number of signals LS j in the current j storage units j whether it is less than the preset threshold M of the number of position information. If LS j < M, then execute Step S5. If LS j = M, then execute Step S6;

[0009] Step S5: Store D i in L j , set i = i + 1, and return to execute Step S3;

[0010] Step S6: Set j = j + 1, and construct the corresponding binary group information A j = (F j , L j ) in the j-th storage unit, where F j is set to the offset value of the first character after the end position of the (k - 1)-th signal relative to the code file where the range of the code to be processed is located, and L j is initially set to be empty, and return to Step S5.

[0011] According to the second aspect of the present invention, there is provided an electronic device, including: at least one processor; and a memory communicatively connected to the at least one processor; wherein, the memory stores instructions executable by the at least one processor, and the instructions are configured to execute the method described in the first aspect of the present invention.

[0012] According to the third aspect of the present invention, there is provided a computer-readable storage medium storing computer-executable instructions, and the computer instructions are used to execute the method described in the first aspect of the present invention.

[0013] Compared with the prior art, the present invention has obvious advantages and beneficial effects. By means of the above technical solutions, a method for storing signal position information based on the number of signals, an electronic device and a medium provided by the present invention can achieve considerable technological progress and practicality, and have wide industrial utilization value. It has at least the following beneficial effects:

[0014] The present invention evenly stores the storage quantities of signals in different code ranges in multiple storage units, thereby greatly improving the search speed of signals and the signal access efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0016] Figure 1 A flow chart of a method for storing signal position information based on signal quantity provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0017] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.

[0018] The embodiment of the present invention provides a method for storing signal location information based on the number of signals. Figure 1 As shown, including:

[0019] Step S1, obtaining the offset value F of the first character of the code range to be processed relative to the code file where the code range to be processed is located, initially setting the storage unit number j=1, and initially setting the signal number i=1.

[0020] A chip design may include multiple code files, each code file may include multiple code processing ranges, and each code processing range corresponds to a sub-component. The code of the same sub-component may be distributed in different code files. As an embodiment, in step S1, the code file where the code range to be processed is located includes N code ranges to be processed {P 1 ,P 2 ,…,P n ,…,P N}, where P n The nth code range to be processed needs to store signal position information in the code file to be processed. The value range of n is 1 to N. Each P n The corresponding processing code corresponds to a sub-component of the design, each P n At least one line of code is included in the code. For each code range to be processed, the signal position information storage can be performed through steps S1 to S6.

[0021] Step S2: construct the corresponding binary information A in the jth storage unit j =(F j ,L j ), each Aj corresponds to a code processing range, where F j is A j is the offset value of the first character of the corresponding code processing range relative to the code file where the code range to be processed is located. When j = 1, F j = F, L j is A j is the corresponding signal list, L j is initially set to be empty.

[0022] Among them, A j corresponds to a code processing range which is a continuous segment of code in the code range to be processed. L j The signal in is A j corresponds to the signal included in the code processing range. A j The corresponding code processing range starts from A 1 and is arranged and spliced together as needed to form the code range to be processed.

[0023] Step S3, traverse the code range to be processed, and determine whether there is an i-th signal. If so, obtain the position information D i of the i-th signal, and execute step S4. Otherwise, end the process.

[0024] It should be noted that traversing the code range to be processed is in sequential order from front to back. When there is no i-th signal, it means that the code range to be processed has been traversed, so the operation of storing the signal position information of the code range to be processed is ended.

[0025] As an embodiment, D i = (D1 i , D2 i , D3 i ), where D1 i is the signal identifier of the i-th signal in the code range to be processed, D2 i is the offset value of the first character of D1 i which is the i-th signal in the code range to be processed relative to the code file where the code range to be processed is located, and D3 i is the signal length of the i-th signal in the code range to be processed. It should be noted that according to specific application requirements, other attribute information of the signal can also be set in D1 i .

[0026] Step S4, determine whether the number of signals LS j in L of the current j storage units j is less than the preset position information quantity threshold M. If LS j < M, then execute step S5. If LS j = M, then execute step S6.

[0027] The preset position information quantity threshold M is the maximum quantity of signal position information that can be stored in the signal list, and can be determined based on factors such as the number of signals in the code file to be processed, signal distribution, and signal access requirements.

[0028] Step S5: D i Stored in L j In the process, i=i+1 is set, and the process returns to step S3.

[0029] It should be noted that D i Store in order to L j middle.

[0030] Step S6: Set j=j+1, and construct the corresponding binary information A in the jth storage unit. j =(F j ,L j ), where F j Set to the offset value of the first character after the end position of the k-1th signal relative to the code file where the code range to be processed is located, L j The initial setting is empty, and the process returns to step S5.

[0031] It should be noted that when LS j =M, it means the current L j The memory is full and a new tuple needs to be created, so j=j+1 is set.

[0032] Through steps S1 to S6, the signal storage quantity within different code ranges is evenly stored in multiple storage units, thereby greatly improving the signal search speed and signal access efficiency. On this basis, the following signal access embodiments are listed below.

[0033] Embodiment 1

[0034] Embodiment 1 is a scenario of accessing a single target signal based on the signal position storage structure of the embodiment of the present invention. Specifically, after step S6, the following steps are further included:

[0035] Step S10: Obtain the offset value F corresponding to the target signal relative to the code file to be processed y .

[0036] It should be noted that the signal has a certain length, and the target signal corresponds to the offset value F in the code file to be processed. y It may be the offset value of any character in the target signal relative to the code file to be processed.

[0037] Step S20, traverse all Aj , will satisfy F j ≤F y <F j+1 A j Determined as Target A j .

[0038] It should be noted that when F is satisfied j ≤F y <F j+1 When the target signal is located at A j The corresponding L j Therefore, F j ≤F y <F j+1 A j Determined as Target A j .

[0039] Step S30: Based on F y Query target A j The corresponding L j , target A j The corresponding L j Meet D2 i ≤F y <D2 i=1 D2 i The corresponding D i Determined as target D i .

[0040] It should be noted that when D2 is satisfied i ≤F y <D2 i=1 When F y The corresponding character is target D i The characters in , therefore, will satisfy D2 i ≤F y <D2 i=1 D2 i The corresponding D i Determined as target D i .

[0041] Embodiment 2

[0042] Embodiment 2 implements access to a continuous range code area based on the signal position storage structure of the embodiment of the present invention. Specifically, after step S6, the following steps are further included:

[0043] Step C10: Obtain the offset value F of the target start position relative to the code file to be processed z and the target end position relative to the offset value F in the code file to be processed h .

[0044] It should be noted that F z and F h It could be on the same line of code or on a different line of code.

[0045] Step C20, traverse all A j , will satisfy F j ≤F z <F j+1 A j Determine the goal to start A j , will satisfy F j ≤F h <F j+1 A j Determine the target end A j .

[0046] Understandably, the goal is to start A j F z A j , target end A j F h A j .

[0047] Step C30: Determine target start A j and target end A j Is it the same A? j If so, execute step C40; otherwise, execute step C50.

[0048] Step C40, traverse target start A j The corresponding L j , set the target to start A j The corresponding L j Meet D2 i ≤F z <D2 i+1 D2 i The corresponding D i Determine the target to start D i , set the target to start A j The corresponding L j Meet D2 i ≤F h <D2 i+1 D2 i The corresponding D i Confirm as target end D i , set the target to start A j The corresponding L j Start at the target D i To the end of the target D i All D i Determined as target D i .

[0049] It should be noted that, since in step C40, the target starts A j and target end A j For the same A j Therefore, in step C40, A is started based on the target j Or the target ends A j Just execute it.

[0050] Step C50, traverse target start A j The corresponding L j , set the target to start A j The corresponding L j Meet D2 i ≤F z <D2 i+1 D2 i The corresponding D i Determine the target to start D i ; End of traversal target A j The corresponding L j , end the target A j The corresponding L j Meet D2 i ≤F h <D2 i+1 D2 i The corresponding D i Confirm as target end D i ; Start the target A j The corresponding L j Start at the target D i To the last D i 、Goal Start A j End with target A j All A between j The corresponding D i 、Target End A j The corresponding L j The first D i To the end of the target D i Determined as target D i .

[0051] It should be noted that when D2 is satisfied i ≤F z <D2 i+1 When F z The corresponding character is D2 i The corresponding D i , so the D i Determine the target to start D i When D2 is satisfied i ≤F h <D2 i+1 When Fh The character for D2 i The corresponding D i , so the D i Confirm as target end D i Then set the target to start A j The corresponding L j Start at the target D i To the last D i 、Goal Start A j End with target A j All A between j The corresponding D i 、Target End A j The corresponding L j The first D i To the end of the target D i All D i Splice to generate target D i .

[0052] Embodiment 3

[0053] Embodiment 3 implements signal access to a target row based on the signal position storage structure of the embodiment of the present invention. Specifically, after step S6, the following steps are further included:

[0054] Step D10, obtaining the target line number G and the offset value Q1 of the line start position corresponding to the G-th line relative to the code file to be processed, and the offset value Q2 of the line end position corresponding to the G-th line relative to the code file to be processed.

[0055] Step D20, set Q1 to the offset value F of the target start position relative to the code file to be processed z , set Q2 to the target end position relative to the offset value F in the code file to be processed h , execute steps C20 to C50, and set the target D determined in step C50 i Determine the target D corresponding to the target row number G i .

[0056] It can be seen that the third embodiment needs to be further combined with the implementation details of the second embodiment to obtain the target D corresponding to the target row number G. i , Embodiment 3 is equivalent to a special case of Embodiment 2.

[0057] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art of the present invention. The terms used in the specification of the present invention herein are only for the purpose of describing specific embodiments and are not intended to limit the present invention.

[0058] It should be noted that some exemplary embodiments are described as processes or methods depicted as flow charts. Although the flow charts describe the steps as sequential processes, many of the steps can be implemented in parallel, concurrently or simultaneously. In addition, the order of the steps can be rearranged. The process can be terminated when its operation is completed, but it can also have additional steps not included in the accompanying drawings. The process can correspond to a method, function, procedure, subroutine, subprogram, etc.

[0059] An embodiment of the present invention also provides an electronic device, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are configured to execute the method described in the embodiment of the present invention.

[0060] The embodiment of the present invention further provides a computer-readable storage medium storing computer-executable instructions, wherein the computer instructions are used to execute the method described in the embodiment of the present invention.

[0061] The embodiment of the present invention stores the signal storage quantity within different code ranges in a plurality of storage units in a balanced manner, thereby greatly improving the signal search speed and the signal access efficiency.

[0062] The above description is only a preferred embodiment of the present invention and does not limit the present invention in any form. Although the present invention has been disclosed as a preferred embodiment as above, it is not used to limit the present invention. Any technician familiar with this profession can make some changes or modifications to equivalent embodiments of equivalent changes using the technical contents disclosed above without departing from the scope of the technical solution of the present invention. However, any simple modification, equivalent change and modification made to the above embodiments based on the technical essence of the present invention without departing from the content of the technical solution of the present invention still falls within the scope of the technical solution of the present invention.

Claims

1. A method for storing signal position information based on signal quantity, characterized in that: include: Step S1, obtaining the offset value F of the first character of the code range to be processed relative to the code file where the code range to be processed is located, initially setting the storage unit number j=1, and initially setting the signal number i=1; Step S2: construct the corresponding binary information A in the jth storage unit j =(F j ,L j ), each A j Corresponds to a code processing range, where F j A j The offset value of the first character of the corresponding code processing range relative to the code file where the code range to be processed is located. When j=1, F j =F,L j A j The corresponding signal list, L j The initial setting is empty; Step S3: traverse the code range to be processed to determine whether the i-th signal exists. If so, obtain the position information D of the i-th signal. i , execute step S4, otherwise, end the process; Step S4. Determine whether the number of signals LS j in the current j storage units j is less than the preset position information quantity threshold M. If LS j < M, then execute Step S5. If LS j = M, then execute Step S6; Step S5: D i Stored in L j , set i=i+1, and return to step S3; Step S6: Set j=j+1, and construct the corresponding binary information A in the jth storage unit. j =(F j ,L j ), where F j Set to the offset value of the first character after the end position of the k-1th signal relative to the code file where the code range to be processed is located, L j The initial setting is empty, and the process returns to step S5.

2. The method according to claim 1, characterized in that: The code file where the code range to be processed is located includes N code ranges to be processed {P1, P2, ..., P n ,…,P N }, where P n The nth code range to be processed needs to store signal position information in the code file to be processed. The value range of n is 1 to N. Each P n The corresponding processing code corresponds to a sub-component of the design, each P n Include at least one line of code in .

3. The method according to claim 1, characterized in that D i =(D1 i ,D2 i ,D3 i ), where D1 i is the signal identifier of the i-th signal in the code range to be processed, D2 i D1 i D3 is the offset value of the first character of the i-th signal in the code range to be processed relative to the code file where the code range to be processed is located. i is the signal length of the i-th signal in the code range to be processed.

4. The method according to claim 3, characterized in that After step S6, the following steps are also included: Step S10: Obtain the offset value F corresponding to the target signal relative to the code file to be processed y ; Step S20, traverse all A j , will satisfy F j ≤F y <F j+1 A j Determined as Target A j ; Step S30: Based on F y Query target A j The corresponding L j , target A j The corresponding L j Meet D2 i ≤F y <D2 i=1 D2 i The corresponding D i Determined as target D i .

5. The method according to claim 3, characterized in that: After step S6, the following steps are also included: Step C10: Obtain the offset value F of the target start position relative to the code file to be processed z and the target end position relative to the offset value F in the code file to be processed h ; Step C20, traverse all A j , will satisfy F j ≤F z <F j+1 A j Determine the goal to start A j , will satisfy F j ≤F h <F j+1 A j Determine the target end A j ; Step C30: Determine target start A j and target end A j Is it the same A? j , if yes, execute step C40, otherwise, execute step C50; Step C40, traverse target start A j The corresponding L j , set the target to start A j The corresponding L j Meet D2 i ≤F z <D2 i+1 D2 i The corresponding D i Determine the target to start D i , set the target to start A j The corresponding L j Meet D2 i ≤F h <D2 i+1 D2 i The corresponding D i Confirm as target end D i , set the target to start A j The corresponding L j Start at the target D i To the end of the target D i All D i Determined as target D i ; Step C50, traverse target start A j The corresponding L j , set the target to start A j The corresponding L j Meet D2 i ≤F z <D2 i+1 D2 i The corresponding D i Determine the target to start D i ; End of traversal target A j The corresponding L j , end the target A j The corresponding L j Meet D2 i ≤F h <D2 i+1 D2 i The corresponding D i Confirm as target end D i ; Start the target A j The corresponding L j Start at the target D i To the last D i 、Goal Start A j End with target A j All A between j The corresponding D i 、Target End A j The corresponding L j The first D i To the end of the target D i Determined as target D i .

6. The method according to claim 5, characterized in that After step S6, the following steps are also included: Step D10, obtaining the target line number G and the offset value Q1 of the line start position corresponding to the G-th line relative to the code file to be processed, and the offset value Q2 of the line end position corresponding to the G-th line relative to the code file to be processed; Step D20, set Q1 to the offset value F of the target start position relative to the code file to be processed z , set Q2 to the offset value F of the target end position relative to the code file to be processed h , execute steps C20 to C50, and set the target D determined in step C50 i Determine the target D corresponding to the target row number G i .

7. An electronic device, characterized in that: include: at least one processor; and, a memory communicatively coupled to the at least one processor; The memory stores instructions executable by the at least one processor, wherein the instructions are configured to execute the method according to any one of claims 1 to 6.

8. A computer-readable storage medium, characterized in that: Computer executable instructions are stored, and the computer executable instructions are used to execute the method according to any one of the preceding claims 1-6.

Citation Information

Patent Citations

  • Compiling method for logic system design, electronic equipment and storage medium

    CN112632880A

  • Signal driving and load verification method and system

    CN115563912A