Address decoding routing method and device, electronic equipment and storage medium

By decoding only the address part used for address translation function in the SoC system, the problem of repeated decoding routing between the midstream module and the downstream module is solved, reducing traffic congestion and bandwidth duplication, and improving system performance.

CN118945109APending Publication Date: 2024-11-12ARM TECH CHINA CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411165374.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-22
Publication Date
2024-11-12

AI Technical Summary

Technical Problem

When the existing SoC system handles access requests, due to the difference in address mapping rules between the midstream module and the downstream module, it leads to repeated decoding routing, increasing traffic congestion and header blocking of memory access requests.

Method used

By obtaining the target address of the target request, determining the address part used for decoding outside the address translation function, and routing it according to the decoding results, avoiding multiple decoding routes between the midstream module and the downstream module, and directly determining the access path .

Benefits of technology

It effectively reduces traffic congestion and bandwidth duplication in SoC systems, and improves overall system performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118945109A_ABST
    Figure CN118945109A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides an address decoding routing method and device, electronic equipment and a storage medium, and relates to the technical field of computers. The method comprises the steps of obtaining a first target address of a target request; determining a to-be-decoded address based on the first target address; wherein the to-be-decoded address is address information, except for an address conversion function, in the first target address; decoding the address to be decoded to obtain a first decoding result; and performing routing based on the first decoding result to obtain a first routing result for the midstream module and a second routing result for the downstream module. The method comprises the following steps: firstly, determining an address part except for an address conversion function in a target address, and only carrying out decoding routing on the part. As only the addresses except for the address conversion function are decoded, the decoding result can be ensured not to be different due to different address mapping rules, multiple decoding routing is not needed, the traffic congestion of the whole system can be reduced, the bandwidth repetition is reduced, and the performance of the whole system is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and more specifically, to an address decoding routing method, device, electronic device and storage medium. Background Art

[0002] SoC (System on Chips) is the core chip integration of information systems, which is used to integrate key system components on a single chip and realize the functions of a complete electronic system through a single chip. Noc (Network-on-chip) is a communication method of SoC, which connects multiple functional modules together through a series of routers and communication links.

[0003] In the solution of the prior art, when the SoC chip needs to process an access request, it generally generates the to-be-decoded address corresponding to the access request through the upstream module, and after decoding the to-be-decoded address, distributes the access request to the corresponding port of the midstream module according to the decoding result (this process can also be called routing). Since the address mapping rules between the upstream module and the midstream module are different from the address mapping rules between the midstream module and the downstream module, when the midstream module processes the to-be-decoded address, it is often necessary to re-decode it according to the new address mapping rules, and then distribute the access request to the corresponding port of the downstream module according to the new decoding result. However, this method will aggravate the traffic congestion of the entire SoC system due to the re-decoding routing of the downstream part (i.e., the midstream module to the downstream module), and may cause the problem of header blocking of memory access requests. Summary of the invention

[0004] The purpose of this application is to solve at least one of the above technical defects. The technical solutions provided by the embodiments of this application are as follows: In a first aspect, an embodiment of the present application provides an address decoding and routing method, which is applied to a target chip, comprising: Get the first target address of the target request; If the first target address meets the preset condition, the first target address is processed by the first mode; The first target address is processed by the first mode, specifically including: Determine the address to be decoded through the upstream module of the target chip based on the first target address; wherein the address to be decoded is the address information in the first target address other than the address conversion function; Decoding the address to be decoded to obtain a first decoding result; Routing is performed based on the first decoding result to determine a first routing result for a midstream module of the target chip and a second routing result for a downstream module of the target chip; the routing result represents a port and an access path corresponding to the target request in the corresponding module.

[0005] In an optional embodiment of the present application, decoding the address to be decoded to obtain a first decoding result specifically includes: Perform a hash operation on the address to be decoded to obtain a first hash operation result corresponding to the address to be decoded, and use the first hash operation result as a first decoding result; Routing is performed based on the first decoding result to determine a first routing result for the midstream module of the target chip, specifically including: A target port to which the target request belongs in the midstream module is determined based on the first decoding result, and a first routing result is determined based on the target port.

[0006] In an optional embodiment of the present application, performing a hash operation on the address to be decoded to obtain a first hash operation result corresponding to the address to be decoded specifically includes: Obtaining the total number of ports in the midstream module, and determining the corresponding number of groups based on the total number of ports; Allocate each address bit to a corresponding group in sequence based on the first position order of each address bit in the address to be decoded and the number of groups; For each group of address bits, based on the first position order of each address bit contained in the group address bit in the address to be decoded, obtain the second position order of the group address bit in the first hash operation result, and perform an XOR operation based on each address bit contained to obtain an XOR operation result of the group address bit; A first hash operation result is determined based on the XOR operation results corresponding to each group of address bits and the corresponding second position sequence.

[0007] In an optional embodiment of the present application, the target chip circuit is generated based on the initial target chip circuit; The method further specifically includes: The path between the midstream module and the downstream module in the initial target chip is deleted to obtain the target chip circuit.

[0008] In an optional embodiment of the present application, the method further specifically includes: Receiving a mode switching instruction sent by a user through a preset register; wherein the preset register is used to indicate the mode currently executed by the target chip circuit; The currently executed mode is switched based on the mode switching instruction; the currently executed mode includes any one of the first mode, the second mode or the third mode.

[0009] In an optional embodiment of the present application, if the first target address does not meet the preset condition, the first target address is processed by the second mode; The first target address is processed by the second mode, specifically including: Performing a hash operation on the first target address to obtain a second hash operation result corresponding to the first target address, and using the second hash operation result as a second decoding result; Perform routing based on the second decoding result, determine a third routing result for the midstream module of the target chip, and obtain a second target address corresponding to the first target address based on the midstream module; Decoding the second target address to obtain a third decoding result; Routing is performed based on the third decoding result to determine a fourth routing result for a downstream module of the target chip.

[0010] In an optional embodiment of the present application, if the mode currently executed by the target chip circuit is indicated to be the third mode, the first target address is processed by the third mode; The first target address is processed by the third mode, specifically including: Interleaving the first target address based on the midstream module without performing hash processing to obtain a third decoding result corresponding to the first target address; Routing is performed based on the third decoding result to determine a fifth routing result for the midstream module and a sixth routing result for the downstream module.

[0011] In a second aspect, an embodiment of the present application provides an address decoding and routing device, including: A target address acquisition module, used to acquire a first target address of a target request; A target address processing module, configured to process the first target address using a first mode if the first target address meets a preset condition; A decoding address acquisition module, used to determine the address to be decoded through the upstream module of the target chip based on the first target address; wherein the address to be decoded is the address information in the first target address other than the address conversion function; A decoding result acquisition module, used for decoding the address to be decoded to obtain a first decoding result; The routing result acquisition module is used to perform routing based on the first decoding result to determine a first routing result for a midstream module of the target chip and a second routing result for a downstream module of the target chip; the routing result represents the port and access path corresponding to the target request in the corresponding module.

[0012] In an optional embodiment of the present application, the decoding result acquisition module is specifically used to: Perform a hash operation on the address to be decoded to obtain a hash operation result corresponding to the address to be decoded, and use the hash operation result as the first decoding result; The routing result acquisition module is specifically used for: A target port to which the target request belongs in the midstream module is determined based on the first decoding result, and a first routing result is determined based on the target port.

[0013] In an optional embodiment of the present application, the decoding result acquisition module is further used to: Obtaining the total number of ports in the midstream module, and determining the corresponding number of groups based on the total number of ports; Allocate each address bit to a corresponding group in sequence based on the first position order of each address bit in the address to be decoded and the number of groups; For each group of address bits, based on the first position order of each address bit contained in the group address bit in the address to be decoded, obtain the second position order of the group address bit in the first hash operation result, and perform an XOR operation based on each address bit contained to obtain an XOR operation result of the group address bit; A first hash operation result is determined based on the XOR operation results corresponding to each group of address bits and the corresponding second position sequence.

[0014] In an optional embodiment of the present application, the device further includes a target chip circuit generation module, which is specifically used to: The path between the midstream module and the downstream module in the initial target chip is deleted to obtain the target chip circuit.

[0015] In an optional embodiment of the present application, the device further includes a mode conversion module, which is specifically configured to: Receiving a mode switching instruction sent by a user through a preset register; wherein the preset register is used to indicate the mode currently executed by the target chip circuit; The currently executed mode is switched based on the mode switching instruction; the currently executed mode includes any one of the first mode, the second mode or the third mode.

[0016] In an optional embodiment of the present application, if the first target address does not meet the preset condition, the first target address is processed by the second mode; The decoding result acquisition module can also be used for: Performing a hash operation on the first target address to obtain a second hash operation result corresponding to the first target address, and using the second hash operation result as a second decoding result; The routing result acquisition module can also be used for: Perform routing based on the second decoding result, determine a third routing result for the midstream module of the target chip, and obtain a second target address corresponding to the first target address based on the midstream module; The decoding result acquisition module can also be used for: Decoding the second target address to obtain a third decoding result; The routing result acquisition module can also be used for: Routing is performed based on the third decoding result to determine a fourth routing result for a downstream module of the target chip.

[0017] In an optional embodiment of the present application, if the mode currently executed by the target chip circuit is indicated to be the third mode, the first target address is processed by the third mode; The decoding result acquisition module can also be used for: Interleaving the first target address based on the midstream module without performing hash processing to obtain a third decoding result corresponding to the first target address; The routing result acquisition module can also be used for: Routing is performed based on the third decoding result to determine a fifth routing result for the midstream module and a sixth routing result for the downstream module.

[0018] In a third aspect, an embodiment of the present application provides an electronic device, including a memory, a processor, and a computer program stored in the memory; The processor executes the computer program to implement the method provided in the embodiment of the first aspect or any optional embodiment of the first aspect.

[0019] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the method provided in the embodiment of the first aspect or any optional embodiment of the first aspect is implemented.

[0020] The beneficial effects of the technical solution provided by the embodiment of the present application are: The solution provided by the present application, after obtaining the target address corresponding to the target request generated by the upstream module, first determines the address part used outside the address conversion function, then decodes the address part, and routes according to the decoding result, determines the corresponding port of the target request in the midstream module and the port in the downstream module, and determines the access path according to the determined port. Since only the address part used outside the address conversion function is decoded, it can be ensured that the decoding results of the target request when it is decoded in the midstream module and the downstream module will not be different due to different address mapping rules, so there is no need to perform multiple decoding routes, which can effectively reduce the traffic congestion of the entire SoC system and reduce bandwidth duplication, thereby improving the overall system performance. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in describing the embodiments of the present application are briefly introduced below.

[0022] Figure 1 A flowchart of an address decoding and routing method provided in an embodiment of the present application; Figure 2 A flowchart of each address decoding method in an example of an embodiment of the present application; Figure 3 A simplified structural diagram of a target chip circuit in an example of an embodiment of the present application; Figure 4 A structural block diagram of an address decoding and routing device provided in an embodiment of the present application; Figure 5 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0023] The embodiments of the present application are described below in conjunction with the drawings in the present application. It should be understood that the implementation methods described below in conjunction with the drawings are exemplary descriptions for explaining the technical solutions of the embodiments of the present application and do not constitute a limitation on the technical solutions of the embodiments of the present application.

[0024] It will be understood by those skilled in the art that, unless specifically stated, the singular forms "one", "said", and "the" used herein may also include plural forms. It should be further understood that the terms "including" and "comprising" used in the embodiments of the present application refer to that the corresponding features can be implemented as the presented features, information, data, steps, operations, elements and / or components, but do not exclude the implementation as other features, information, data, steps, operations, elements, components and / or combinations thereof supported by the technical field. It should be understood that when we say that an element is "connected" or "coupled" to another element, the one element may be directly connected or coupled to the other element, or it may refer to that the one element and the other element establish a connection relationship through an intermediate element. In addition, the "connection" or "coupling" used herein may include wireless connection or wireless coupling. The term "and / or" used herein indicates at least one of the items defined by the term, for example, "A and / or B" may be implemented as "A", or as "B", or as "A and B".

[0025] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.

[0026] The following describes several exemplary embodiments to illustrate the technical solutions of the embodiments of the present application and the technical effects produced by the technical solutions of the present application. It should be noted that the following embodiments can refer to, draw on or combine with each other, and the same terms, similar features and similar implementation steps in different embodiments will not be described repeatedly.

[0027] Figure 1 A flowchart of an address decoding method is provided for an embodiment of the present application. The execution subject of the method may be a chip, such as Figure 1 As shown, the method may include: Step S101, obtaining a first target address of a target request.

[0028] Step S102: If the first target address meets a preset condition, the first target address is processed by a first mode.

[0029] Specifically, in the embodiment of the present application, the processing methods for the target address can be divided into three types, and the first mode can be used to process the first target address that meets the preset conditions. The specific preset conditions can be determined in advance based on offline performance testing work, for example: 1) If the first target address in the scenario has a small change compared to the original first target address after removing the address bit of the address conversion part, then the first mode affects the bandwidth efficiency of the interleaving path poorly, and this indicates that the first target address does not meet the preset conditions. 2) If the first target address in the scenario has a small change compared to the original first target address after removing the address bit of the address conversion part, and the first target address is fixedly jumped according to the address length obtained by multiplying the interleaving granularity by the number of interleaving paths, then the first mode affects the bandwidth efficiency of the interleaving path very poorly, and this also indicates that the first target address does not meet the preset conditions.

[0030] The first target address is processed by the first mode, specifically including: Step S103, determining the address to be decoded through the upstream module of the target chip based on the first target address; wherein the address to be decoded is the address information in the first target address other than the address conversion function.

[0031] Among them, the upstream module is a functional module at the top level of the target chip. The first target address is used to indicate the physical space pointed to by the target request, and the first target address is generally a virtual address. The midstream module can convert the first target address (commonly, the MMU / SMMU (memory management unit / system memory management unit) module converts the virtual address to a physical address), such as converting part of the address in the target address. Specifically, for the same target request, the midstream module will convert part of the address of the first target address according to a pre-set rule (such as the first N high-order addresses fixed to the first target address, N can be set to any positive integer according to requirements), while other parts of the first target address will not be converted. Therefore, based on the above characteristics, in an embodiment of the present application, the part of the address in the first target address that will not be converted by the midstream module can be used as a characteristic address representing the target request (that is, the address information in the first target address other than the address conversion function). Since the part of the address will not be changed by the midstream module, the part of the address can be used as the address to be decoded to implement the address decoding operation for the target request.

[0032] In actual operation, each address bit of the first target address can be divided into a high address or a low address according to the needs. The high address can be composed of the address starting from the highest bit of the first target address to the address set to a certain bit, and the remaining part of the address constitutes the low address. Since the address bits that are transformed after passing through the midstream module are generally continuous, the part of the address that is not converted in the midstream module can be set as a high address according to the conversion rule of the midstream module. Each bit in the high address can participate in the address decoding, and the address to be decoded can contain at least one bit in the high address.

[0033] Step S104, decoding the address to be decoded to obtain a first decoding result.

[0034] The first decoding result is an output result after decoding the address to be decoded.

[0035] Specifically, after determining the address to be decoded of the target request, the address to be decoded is decoded, the decoded address is output, and the decoded address is used as the first decoding result for the midstream module. When passing through the midstream module, due to the conversion rule characteristics of the midstream module, the decoding result of this part of the address will not change.

[0036] Step S105 , performing routing based on the first decoding result, determining a first routing result for a midstream module of the target chip and a second routing result for a downstream module of the target chip; the routing result represents the port and access path corresponding to the target request in the corresponding module.

[0037] Among them, the midstream module is the functional module in the middle of the target chip, and the downstream module is the functional module at the bottom layer of the target chip.

[0038] Specifically, for the same target request, the address of the address conversion function part in the first target address will change when passing through the midstream module, while the address of the other parts is unchanged, so the partial address that has not changed after passing through the midstream module (i.e., the address information other than the address conversion function in the first target address) can still be used to represent the target request. The embodiment of the present application can only decode the unchanged partial address, that is, only decode the partial address to obtain the corresponding first decoding result, and then perform routing according to the first decoding result (routing is the process of finding the corresponding target port on the module and determining the access path) to determine the target port corresponding to the target request on the midstream module. Specifically, when the upstream module generates the address to be decoded, the address to be decoded is first decoded, and then the target port corresponding to the midstream module and the access path between the upstream module and the midstream module (i.e., the first routing result) and the target port corresponding to the downstream module are determined respectively according to the first decoding result, and then the access path between the midstream module and the downstream module is determined according to the target port corresponding to the midstream module and the target port corresponding to the downstream module. In this process, there is no need to re-decode the downstream modules (i.e. Figure 2 As shown in the decoding mode 3, the access path can be determined through one decoding, so that the routing bandwidth congestion from the midstream module to the downstream module can be avoided.

[0039] The solution provided by the present application, after obtaining the target address corresponding to the target request generated by the upstream module, first determines the address part used outside the address conversion function, then decodes the address part, and routes according to the decoding result, determines the corresponding port of the target request in the midstream module and the port in the downstream module, and determines the access path according to the determined port. Since only the address part used outside the address conversion function is decoded, it can be ensured that the decoding results of the target request when it is decoded in the midstream module and the downstream module will not be different due to different address mapping rules, so there is no need to perform multiple decoding routes, which can effectively reduce the traffic congestion of the entire SoC system and reduce bandwidth duplication, thereby improving the overall system performance.

[0040] In an optional embodiment of the present application, decoding the address to be decoded to obtain a first decoding result specifically includes: Perform a hash operation on the address to be decoded to obtain a first hash operation result corresponding to the address to be decoded, and use the first hash operation result as a first decoding result; Routing is performed based on the first decoding result to determine a first routing result for the midstream module of the target chip, specifically including: A target port to which the target request belongs in the midstream module is determined based on the first decoding result, and a first routing result is determined based on the target port.

[0041] The hash operation is used to determine the mapping position corresponding to the address to be decoded. The hash result is the calculation result obtained after the hash operation is performed on the address to be decoded. The target port is the mapping position corresponding to the address to be decoded. In the embodiment of the present application, each module has multiple ports, and the port corresponding to the address to be decoded on the module is the target port.

[0042] Specifically, in order to ensure bandwidth balance among modules when multiple target requests are accessed simultaneously, the embodiment of the present application can perform a hash operation on the address to be decoded of each target request. Based on the characteristics of the hash operation, multiple target requests can be distributed to each target port as evenly as possible. Figure 2 As shown in the figure, the upstream modules of decoding mode 1 (i.e., the first mode) and decoding mode 2 (i.e., the second mode) decode the addresses to be decoded (i.e., address hashing and interleaving in the figure), and the addresses to be decoded of each target request (i.e., the end of the dotted line in the figure) are decoded and corresponded to the target ports of the midstream modules (i.e., the beginning of the dotted line in the figure).

[0043] Specifically, a hash operation can be performed on the to-be-decoded address corresponding to the target request to obtain a first hash operation result corresponding to the to-be-decoded address. Each first hash operation result has a corresponding target port on the corresponding module, and the target port is the port to which the target request needs to be assigned. Therefore, the target port (hereinafter referred to as the first target port) corresponding to the target request in the midstream module can be determined based on the first hash operation result.

[0044] It should be noted that, in the solution provided in the embodiment of the present application, the method for determining the target port (hereinafter referred to as the second target port) of the downstream module is the same as the above method.

[0045] like Figure 2 As shown in the decoding mode three, in actual operation, after obtaining the first target port, the second target port corresponding to the target request on the downstream module can also be directly determined based on the position correspondence between the midstream module and the downstream module.

[0046] In an optional embodiment of the present application, performing a hash operation on the address to be decoded to obtain a hash operation result corresponding to the address to be decoded specifically includes: Obtaining the total number of ports in the midstream module, and determining the corresponding number of groups based on the total number of ports; Allocate each address bit to a corresponding group in sequence based on the first position order of each address bit in the address to be decoded and the number of groups; For each group of address bits, based on the first position order of each address bit contained in the group address bit in the address to be decoded, obtain the second position order of the group address bit in the first hash operation result, and perform an XOR operation based on each address bit contained to obtain an XOR operation result of the group address bit; A first hash operation result is determined based on the XOR operation results corresponding to each group of address bits and the corresponding second position sequence.

[0047] The first position sequence may be the position sequence of each address bit in the address to be decoded from the highest bit to the lowest bit.

[0048] Specifically, in the embodiment of the present application, the total number of ports in each module can be any integer power of 2 (for example, 4, 8, 16, etc.), and then the number of groups that each address bit needs to be divided into is determined according to the different total number of ports. For example, if the total number of ports is 2 to the power of n, each address bit is divided into n groups (for example, if the total number of ports is 4, it is divided into 2 groups; if the total number of ports is 8, it is divided into 3 groups). The specific grouping method is to put each address bit into different groups in a continuous cycle according to the order of the first position of the address to be decoded (if it needs to be divided into three groups, the address bit at the 31st position is divided into the first group, the address bit at the 30th position is divided into the second group, the address bit at the 29th position is divided into the third group, and the address bit at the 28th position is divided into the first group again, and so on). Each group of address bits is sorted according to the position order of the address to be decoded (such as from high to low). Then for each group of address bits, according to the first position order of the address bits contained in the group, the second position order of the group in the hash operation result can be determined, and then the XOR operation results of each group and the corresponding second position order of each group are linked to obtain the hash result. Taking the above example, the total number of ports is 8, and each address bit is divided into 3 groups. The address bits at the 31st, 28th, 25th, etc. are divided into the first group, so the second position sequence of the group can be determined as the first; the address bits at the 30th, 27th, 24th, etc. are divided into the second group, so the second position sequence of the group can be determined as the second; the address bits at the 29th, 26th, 23rd, etc. are divided into the third group, so the second position sequence of the group can be determined as the third. Then, after the XOR operation of each group of address bits is performed, the result of the first group is 0, the result of the second group is 1, and the result of the third group is 0, then the corresponding hash result is 010. Further, based on the hash result and the binary conversion rule, it can be determined that the target port corresponding to the target request is port 2. After the XOR operation of each group is completed, the final hash operation result is determined according to the operation result of each group.

[0049] In an optional embodiment of the present application, the target chip circuit is generated based on the initial target chip circuit; The method further specifically includes: The path between the midstream module and the downstream module in the initial target chip is deleted to obtain the target chip circuit.

[0050] Specifically, Figure 2 As shown, the modules can be connected by a path (i.e., a circuit) in the form of wires or the like. For an address to be decoded that does not include a portion used for the address conversion function, after obtaining the first decoding result for the midstream module, since there is no need to decode again, the path between the midstream module and the downstream module can be directly deleted (i.e., Figure 3 As shown), the cost of producing the target chip circuit can be saved.

[0051] In an optional embodiment of the present application, the method further specifically includes: Receiving a mode switching instruction sent by a user through a preset register; wherein the preset register is used to indicate the mode currently executed by the target chip circuit; The currently executed mode is switched based on the mode switching instruction; the currently executed mode includes any one of the first mode, the second mode or the third mode.

[0052] The preset register can indicate the mode that the target chip circuit needs to execute through the currently set value, and illustratively, 00 can be set as the first mode, 01 as the second mode, 10 as the third mode, etc. This application does not limit this.

[0053] Specifically, in actual application scenarios, the processing mode of the target chip circuit often needs to be frequently switched back and forth according to actual needs at different times. Therefore, the present application provides a method for setting a preset register to control the processing mode of the target chip circuit. Specifically, when the user needs to adjust the processing mode of the target chip circuit, the value in the preset register can be directly adjusted, and different values ​​can be set to achieve switching between different modes.

[0054] It should be noted that the timing of switching between different modes must be before the processing of the first target address begins. When the target chip circuit has begun processing a first target address, switching between different modes cannot be performed before the first target address is completely processed.

[0055] In an optional embodiment of the present application, if the first target address does not meet the preset condition, the first target address is processed by the second mode; The first target address is processed by the second mode, specifically including: Performing a hash operation on the first target address to obtain a second hash operation result corresponding to the first target address, and using the second hash operation result as a second decoding result; Perform routing based on the second decoding result, determine a third routing result for the midstream module of the target chip, and obtain a second target address corresponding to the first target address based on the midstream module; Decoding the second target address to obtain a third decoding result; Routing is performed based on the third decoding result to determine a fourth routing result for a downstream module of the target chip.

[0056] Specifically, in the embodiment of the present application, the available Figure 2 In the example of decoding mode 1 (i.e., the first mode), the application scenario applicable to the decoding mode can be recorded. When the actual application scenario is not in the recorded application scenario applicable to the decoding mode, the embodiment of the present application can also directly use all addresses of the target address as the address to be decoded (i.e., Figure 2 In decoding mode 2, two decoding and routing operations are required, that is, the first decoding is required when determining the port corresponding to the midstream module to obtain the second decoding result, and the third routing result from the upstream module to the midstream module is determined by routing based on the second decoding result. Since the midstream module may convert the first target address, the converted second target address needs to be re-decoded again to obtain the third decoding result, and routing is performed again based on the third decoding result to determine the fourth routing result from the midstream module to the downstream module.

[0057] It should be noted that in the solution provided by the embodiment of the present application, even if the usage scenario of the first mode is met, it can be freely adjusted to the second mode. At the same time, in order to ensure the correct consistency of data, the decoding mode will not be switched before the process execution of the same request is completed.

[0058] It should be noted that the decoding processing mode provided in the embodiment of the present application can effectively ensure bandwidth balance between the upstream module and the midstream module and between the midstream module and the downstream module by performing two decoding operations, but the downstream module needs to re-arbitrate (see Figure 2 The circled part in the middle) may aggravate the traffic congestion of the entire chip system and may cause the header blocking problem of the target request.

[0059] In an optional embodiment of the present application, if the mode currently executed by the target chip circuit is indicated to be the third mode, the first target address is processed by the third mode; The first target address is processed by the third mode, specifically including: Interleaving the first target address based on the midstream module without performing hash processing to obtain a third decoding result corresponding to the first target address; Routing is performed based on the third decoding result to determine a fifth routing result for the midstream module and a sixth routing result for the downstream module.

[0060] The present application also provides another decoding processing mode (i.e., the third mode), which is a decoding processing mode that does not require hashing. Specifically, in the embodiment of the present application, when processing the first target address, the first target address may not be hashed, but the first target address may be decoded in an interleaving manner (interleaving means ensuring that the number of target addresses received by each port in each module is average), and after obtaining the third decoding result, the target port corresponding to the first target address in the midstream module (i.e., the fifth routing result) and the target port corresponding to the downstream module (i.e., the sixth routing result) are obtained based on the third decoding result.

[0061] It should be noted that the decoding processing mode provided in the embodiment of the present application can make the address conversion no longer affect the routing function of the midstream module, and can avoid re-decoding, thereby avoiding the routing bandwidth congestion that may occur in the downstream module. However, it cannot guarantee the bandwidth balance between the upstream module and the midstream module, so that the midstream module may become the bandwidth bottleneck for memory access of the entire chip system.

[0062] Figure 4 A structural block diagram of an address decoding and routing device provided in an embodiment of the present application, such as Figure 4 As shown, the health evaluation device 400 of the Internet technology IT system may include: a target address acquisition module 401, a decoding address acquisition module 402, a decoding result acquisition module 403 and a routing result acquisition module 404, wherein: The target address acquisition module 401 is used to acquire the first target address of the target request; The target address processing module 402 is used to process the first target address through a first mode if the first target address meets a preset condition; The decoding address acquisition module 403 is used to determine the address to be decoded through the upstream module of the target chip based on the first target address; wherein the address to be decoded is the address information in the first target address other than the address conversion function; The decoding result acquisition module 404 is used to decode the address to be decoded to obtain a first decoding result; The routing result acquisition module 405 is used to perform routing based on the first decoding result, and determine the first routing result for the midstream module of the target chip and the second routing result for the downstream module of the target chip; the routing result represents the port and access path corresponding to the target request in the corresponding module.

[0063] The solution provided by the present application, after obtaining the target address corresponding to the target request generated by the upstream module, first determines the address part used outside the address conversion function, then decodes the address part, and routes according to the decoding result, determines the corresponding port of the target request in the midstream module and the port in the downstream module, and determines the access path according to the determined port. Since only the address part used outside the address conversion function is decoded, it can be ensured that the decoding results of the target request when it is decoded in the midstream module and the downstream module will not be different due to different address mapping rules, so there is no need to perform multiple decoding routes, which can effectively reduce the traffic congestion of the entire SoC system and reduce bandwidth duplication, thereby improving the overall system performance.

[0064] In an optional embodiment of the present application, the decoding result acquisition module is specifically used to: Perform a hash operation on the address to be decoded to obtain a hash operation result corresponding to the address to be decoded, and use the hash operation result as the first decoding result; The routing result acquisition module is specifically used for: A target port to which the target request belongs in the midstream module is determined based on the first decoding result, and a first routing result is determined based on the target port.

[0065] In an optional embodiment of the present application, the decoding result acquisition module is further used to: Obtaining the total number of ports in the midstream module, and determining the corresponding number of groups based on the total number of ports; Allocate each address bit to a corresponding group in sequence based on the first position order of each address bit in the address to be decoded and the number of groups; For each group of address bits, based on the first position order of each address bit contained in the group address bit in the address to be decoded, obtain the second position order of the group address bit in the first hash operation result, and perform an XOR operation based on each address bit contained to obtain an XOR operation result of the group address bit; A first hash operation result is determined based on the XOR operation results corresponding to each group of address bits and the corresponding second position sequence.

[0066] In an optional embodiment of the present application, the device further includes a target chip circuit generation module, which is specifically used to: The path between the midstream module and the downstream module in the initial target chip is deleted to obtain the target chip circuit.

[0067] In an optional embodiment of the present application, the device further includes a mode conversion module, which is specifically configured to: Receiving a mode switching instruction sent by a user through a preset register; wherein the preset register is used to indicate the mode currently executed by the target chip circuit; The currently executed mode is switched based on the mode switching instruction; the currently executed mode includes any one of the first mode, the second mode or the third mode.

[0068] In an optional embodiment of the present application, if the first target address does not meet the preset condition, the first target address is processed by the second mode; The decoding result acquisition module can also be used for: Performing a hash operation on the first target address to obtain a second hash operation result corresponding to the first target address, and using the second hash operation result as a second decoding result; The routing result acquisition module can also be used for: Perform routing based on the second decoding result, determine a third routing result for the midstream module of the target chip, and obtain a second target address corresponding to the first target address based on the midstream module; The decoding result acquisition module can also be used for: Decoding the second target address to obtain a third decoding result; The routing result acquisition module can also be used for: Routing is performed based on the third decoding result to determine a fourth routing result for a downstream module of the target chip.

[0069] In an optional embodiment of the present application, if the mode currently executed by the target chip circuit is indicated to be the third mode, the first target address is processed by the third mode; The decoding result acquisition module can also be used for: Interleaving the first target address based on the midstream module without performing hash processing to obtain a third decoding result corresponding to the first target address; The routing result acquisition module can also be used for: Routing is performed based on the third decoding result to determine a fifth routing result for the midstream module and a sixth routing result for the downstream module.

[0070] Reference below Figure 5 , which shows an electronic device suitable for implementing the embodiments of the present application (for example, Figure 1 The electronic device in the embodiment of the present application may include but is not limited to mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), wearable devices, etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 5 The electronic device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0071] The electronic device includes: a memory and a processor, the memory is used to store a program for executing the method described in each of the above method embodiments; the processor is configured to execute the program stored in the memory. The processor here can be referred to as the processing device 501 described below, and the memory can include at least one of the read-only memory (ROM) 502, the random access memory (RAM) 503, and the storage device 508 described below, as shown below: like Figure 5 As shown, the electronic device 500 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 501, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 502 or a program loaded from a storage device 508 to a random access memory (RAM) 503. In the RAM 503, various programs and data required for the operation of the electronic device 500 are also stored. The processing device 501, the ROM 502, and the RAM 503 are connected to each other via a bus 504. An input / output (I / O) interface 505 is also connected to the bus 504.

[0072] Typically, the following devices may be connected to the I / O interface 505: an input device 506 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 507 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 508 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 509. The communication device 509 may allow the electronic device 500 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 5 An electronic device having various devices is shown, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.

[0073] In particular, according to an embodiment of the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present application includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication device 509, or installed from the storage device 508, or installed from the ROM 502. When the computer program is executed by the processing device 501, the above-mentioned functions defined in the method of the embodiment of the present application are executed.

[0074] It should be noted that the computer-readable storage medium mentioned above in the present application may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer readable signal media may also be any computer readable medium other than computer readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any appropriate medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.

[0075] In some embodiments, the client and the server may communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.

[0076] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.

[0077] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device: Obtain a first target address of a target request; if the first target address meets a preset condition, process the first target address through a first mode; process the first target address through the first mode, specifically including: determining an address to be decoded through an upstream module of a target chip based on the first target address; wherein the address to be decoded is address information in the first target address other than an address conversion function; decoding the address to be decoded to obtain a first decoding result; routing based on the first decoding result to determine a first routing result for a midstream module of the target chip and a second routing result for a downstream module of the target chip; the routing result represents a port and an access path corresponding to the target request in a corresponding module.

[0078] Computer program code for performing the operations of the present application may be written in one or more programming languages ​​or a combination thereof, including, but not limited to, object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0079] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0080] The modules or units involved in the embodiments of the present application may be implemented by software or hardware. The name of a module or unit does not limit the unit itself in some cases. For example, the first constraint acquisition module may also be described as a "module for acquiring the first constraint".

[0081] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.

[0082] In the context of the present application, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or device, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0083] It should be understood that, although the steps in the flowchart of the accompanying drawings are displayed in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least a part of the steps in the flowchart of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.

[0084] The above descriptions are only some embodiments of the present invention. It should be pointed out that, for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. An address decoding and routing method, characterized in that: Applied to target chip circuits, including: Get the first target address of the target request; If the first target address meets the preset condition, the first target address is processed by a first mode; The processing of the first target address by using the first mode specifically includes: Determine an address to be decoded through an upstream module of a target chip based on the first target address; wherein the address to be decoded is address information in the first target address other than address conversion function; Decoding the address to be decoded to obtain a first decoding result; Routing is performed based on the first decoding result to determine a first routing result for a midstream module of the target chip and a second routing result for a downstream module of the target chip; the routing result represents a port and an access path corresponding to the target request in a corresponding module.

2. The method according to claim 1, characterized in that The decoding of the address to be decoded to obtain a first decoding result includes: Performing a hash operation on the address to be decoded to obtain a first hash operation result corresponding to the address to be decoded, and using the first hash operation result as the first decoding result; Performing routing based on the first decoding result to determine a first routing result for the midstream module of the target chip includes: The target port to which the target request belongs in the midstream module is determined based on the first decoding result, and the first routing result is determined based on the target port.

3. The method according to claim 2, characterized in that The performing a hash operation on the address to be decoded to obtain a first hash operation result corresponding to the address to be decoded includes: Obtaining the total number of ports in the midstream module, and determining the corresponding number of groups based on the total number of ports; Based on the first position order of each address bit in the address to be decoded and the number of groups, sequentially assigning each address bit to a corresponding group; For each group of address bits, based on the first position order of each address bit included in the group of address bits in the address to be decoded, obtain the second position order of the group of address bits in the first hash operation result, and perform an XOR operation based on each address bit included to obtain the XOR operation result of the group of address bits; The first hash operation result is determined based on the XOR operation results corresponding to each group of address bits and the corresponding second position sequence.

4. The method according to claim 1, characterized in that The target chip is generated based on the initial target chip circuit; The method further comprises: The path between the midstream module and the downstream module in the initial target chip is deleted to obtain the target chip circuit.

5. The method according to claim 1, characterized in that The method further comprises: Receiving a mode switching instruction sent by a user through a preset register; wherein the preset register is used to indicate the mode currently executed by the target chip circuit; The currently executed mode is switched based on the mode switching instruction; the currently executed mode includes any one of the first mode, the second mode or the third mode.

6. The method according to claim 1, characterized in that If the first target address does not meet the preset condition, processing the first target address through the second mode; The processing of the first target address by using the second mode specifically includes: Performing a hash operation on the first target address to obtain a second hash operation result corresponding to the first target address, and using the second hash operation result as a second decoding result; Perform routing based on the second decoding result, determine a third routing result for the midstream module of the target chip, and obtain a second target address corresponding to the first target address based on the midstream module; Decoding the second target address to obtain a third decoding result; Routing is performed based on the third decoding result to determine a fourth routing result for a downstream module of the target chip.

7. The method according to claim 5, characterized in that If the mode currently executed by the target chip circuit is indicated to be the third mode, the first target address is processed by the third mode; The processing of the first target address by using the third mode specifically includes: Interleaving the first target address based on the midstream module without performing hash processing to obtain a third decoding result corresponding to the first target address; Routing is performed based on the third decoding result to determine a fifth routing result for the midstream module and a sixth routing result for the downstream module.

8. An address decoding and routing device, characterized in that: include: A target address acquisition module, used to acquire a first target address of a target request; a target address processing module, configured to process the first target address in a first mode if the first target address meets a preset condition; A decoding address acquisition module, used to determine the address to be decoded through the upstream module of the target chip based on the first target address; wherein the address to be decoded is the address information in the first target address other than the address conversion function; A decoding result acquisition module, used for decoding the address to be decoded to obtain a first decoding result; A routing result acquisition module is used to perform routing based on the first decoding result to determine a first routing result for a midstream module of the target chip and a second routing result for a downstream module of the target chip; the routing result represents the port and access path corresponding to the target request in the corresponding module.

9. An electronic device comprising a memory, a processor and a computer program stored in the memory, characterized in that: The processor executes the computer program to implement the steps of the method according to any one of claims 1 to 7.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.