Data processing method and system based on dynamic balance mechanism and medium

By setting a dynamic equalization mechanism inside the DPU and dynamically adjusting the NP core configuration, the problem of determining functions of traditional DPU equipment models is solved, and the effect of adjusting the sending and receiving model according to the network model and improving the performance of network nodes is achieved.

CN119440835APending Publication Date: 2025-02-14CHENGDU BEIZHONG NETCORE TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411541145.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-31
Publication Date
2025-02-14

AI Technical Summary

Technical Problem

Traditional DPU device models determine the function, making it difficult for customers to adjust the transceiver model according to the network model, making it difficult for each network node to reach its limit.

Method used

Through the DPU, the NP cores within the DPU are dynamically balanced, and the number of NP cores occupied by sending and receiving data is dynamically adjusted according to application needs, so as to easily switch the NP cores processed up and down.

Benefits of technology

It realizes dynamic adjustment of NP core configuration according to different business scenarios, improves the performance of each network node, and meets different network traffic model requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119440835A_ABST
    Figure CN119440835A_ABST
Patent Text Reader

Abstract

The invention discloses a data processing method and system based on a dynamic balance mechanism and a medium. Relates to the technical field of data processing. Acquiring flow distribution information of the to-be-processed data; based on the traffic distribution information, the DPU performs dynamic equilibrium planning on an NP core in the DPU; inputting to-be-processed data into the DPU after the dynamic equilibrium planning for data processing; according to the scheme, the method is improved on the basis of a traditional DPU technology, the NP cores in the DPU are subjected to dynamic balance planning through the DPU, the number of the NP cores occupied by data receiving and transmitting is dynamically adjusted according to application requirements to meet different service scenes, the NP cores for uplink and downlink processing are easily switched, and the optimal performance of application of a user in each scene is achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data processing, and in particular to a data processing method, system and medium based on a dynamic balancing mechanism. Background Art

[0002] At present, from the perspective of technical paths, DPU can be roughly divided into several categories, such as FPGA (field programmable gate array), ASIC (application specific integrated circuit), NP-SoC (network processor system-on-chip), GP-SoC (general-purpose processor system-on-chip), etc. NP-SoC combines network processor and SoC technology to provide high-speed network data processing capabilities, while GP-SoC is based on general-purpose processor technology to provide computing and data processing capabilities for a variety of application scenarios. NP-SoC is increasingly popular among users due to its programmable characteristics. However, the application scenarios of DPU are different, and the requirements for upstream and downstream traffic are also different.

[0003] Generally speaking, once a DPU leaves the factory, the device model determines the relevant functions. Customers can only dynamically switch functions through some commands, and cannot adjust the transceiver model according to the network model. For example, in customer scenario 1, the DPU is deployed on the server node, and the transceiver traffic accounts for 8:2; the DPU is deployed on the client node, and the transceiver traffic accounts for 2:8; in customer scenario 2, the DPU is deployed on the distributed computing node, and the transceiver traffic between the client and the server accounts for 5:5. It is difficult for a general solution to maximize the performance of each node, and the performance of a single node will affect the total number of DPUs required, and thus affect the total cost. Summary of the invention

[0004] The technical problem to be solved by the present invention is that once a traditional DPU leaves the factory, the device model determines the relevant functions. Customers can only dynamically switch functions through some commands, and cannot adjust the receiving and sending models according to the network model, making it difficult to maximize the performance of each network node. The present invention aims to provide a data processing method, system and medium based on a dynamic balancing mechanism; improve the method on the basis of traditional DPU technology, dynamically balance the NP cores inside the DPU through the DPU, dynamically adjust the number of NP cores occupied by receiving and sending data according to application requirements to meet different business scenarios, and easily switch the NP cores for uplink and downlink processing, so that users can achieve the best performance in various scenarios.

[0005] The present invention is achieved through the following technical solutions:

[0006] This solution provides a data processing method based on a dynamic balancing mechanism, including:

[0007] Obtaining traffic distribution information of data to be processed;

[0008] Based on the traffic distribution information, the DPU performs dynamic balancing planning for the NP cores inside the DPU;

[0009] The data to be processed is input into the DPU after dynamic balancing planning for data processing.

[0010] Working principle of this solution: Once a traditional DPU leaves the factory, the device model determines the relevant functions. Customers can only dynamically switch functions through some commands, and cannot adjust the receiving and sending models according to the network model, making it difficult to maximize the performance of each network node. The purpose of the present invention is to provide a data processing method, system and medium based on a dynamic balancing mechanism; based on the traditional DPU technology, the method is improved, and the DPU is used to dynamically balance the NP cores inside the DPU, and the number of NP cores occupied by receiving and sending data is dynamically adjusted according to application requirements to meet different business scenarios, and the NP cores for uplink and downlink processing can be easily switched to allow users to achieve optimal performance in various scenarios.

[0011] This solution provides a new technical concept. By setting a dynamic balancing mechanism inside the DPU, that is, the DPU dynamically balances the NP cores inside the DPU, the NP cores can easily switch uplink and downlink processing modes in different business scenarios, reasonably allocate the NP cores inside the DPU, and realize the effective utilization of each NP core.

[0012] A further optimization scheme is that the flow distribution information includes optimal NP core distribution ratio information.

[0013] A further optimization scheme is that the method for obtaining the optimal NP core distribution ratio information includes:

[0014] Get all network traffic models;

[0015] Conduct laboratory simulations on each network traffic model, measure the optimal NP core distribution ratio under each network traffic model, and construct an optimal NP core distribution ratio table;

[0016] Obtain the target network traffic model of the data to be processed, and refer to the optimal NP core distribution ratio table to obtain the optimal NP core distribution ratio.

[0017] A further optimization scheme is that, based on the traffic distribution information, the DPU performs dynamic balancing planning on the NP cores inside the DPU, including a method in which the DPU replans the NP cores used for uplink and the NP cores used for downlink according to the optimal NP core distribution ratio information.

[0018] A further optimization scheme is that, according to the optimal NP core distribution ratio information, the DPU re-plans the NP cores used for uplink and the NP cores used for downlink; including the method:

[0019] S1, DPU determines whether the i-th NP core in the DPU needs to change the processing direction. If so, it goes to step S2; otherwise, it goes to step S5;

[0020] S2, determine whether the current NP core needs to be changed from the uplink processing direction to the downlink processing direction. If yes, proceed to step S3; otherwise, proceed to step S4;

[0021] S3, determine whether the current NP core is idle. If so, remove the current NP core from the upstream scheduler, replace the logic of the current NP core with the downstream logic and add it to the downstream scheduler, and then enter step S5; otherwise, return to step S3 to re-determine whether the current NP core is idle;

[0022] S4, determine whether the current NP core is idle. If so, remove the current NP core from the downlink scheduler, replace the logic of the current NP core with the uplink logic and add it to the uplink scheduler, and then enter step S5; otherwise, return to step S4 to re-determine whether the current NP core is idle;

[0023] S5, determine whether there is another NP core, if so, return to step S1; otherwise, end.

[0024] A further optimization scheme is that the uplink scheduler is used to process data received from the network, and the downlink scheduler is used to process data sent by the host.

[0025] A further optimization solution is that steps S1-S5 are implemented by SoC software.

[0026] The present solution also provides a data processing system based on a dynamic balancing mechanism, which is used to implement the above-mentioned data processing method based on a dynamic balancing mechanism; the system comprises:

[0027] A collection module, used to obtain flow distribution information of data to be processed;

[0028] The planning module is used for the DPU to dynamically balance the NP cores inside the DPU based on the traffic distribution information;

[0029] The processing module is used to input the data to be processed into the DPU after dynamic balancing planning for data processing.

[0030] A further optimization solution is that the planning module and the processing module are both included in the DPU.

[0031] The present solution also provides a computer-readable medium on which a computer program is stored. The computer program is executed by a processor to implement the data processing method based on the dynamic balancing mechanism as described above.

[0032] Compared with the prior art, the present invention has the following advantages and beneficial effects:

[0033] 1. The data processing method, system and medium based on the dynamic balancing mechanism provided by the present invention are improved on the basis of the traditional DPU technology. The DPU performs dynamic balancing planning on the NP cores inside the DPU, dynamically adjusts the number of NP cores occupied by sending and receiving data according to application requirements to meet different business scenarios, and easily switches the NP cores for uplink and downlink processing, so that users can achieve the best performance in various scenarios.

[0034] 2. This solution provides a new technical concept. By setting a dynamic balancing mechanism inside the DPU, that is, the DPU dynamically balances the NP cores inside the DPU, the NP cores can easily switch the uplink and downlink processing modes in different business scenarios, reasonably allocate the NP cores inside the DPU, and realize the effective utilization of each NP core. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] In order to more clearly illustrate the technical solutions of the exemplary embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. It should be understood that the following drawings only illustrate certain embodiments of the present invention and should not be regarded as limiting the scope. For those of ordinary skill in the art, other relevant drawings can be obtained based on these drawings without creative work. In the drawings:

[0036] Figure 1 It is a flowchart of a data processing method based on a dynamic balancing mechanism;

[0037] Figure 2 This is a schematic diagram of the dynamic balance planning principle. DETAILED DESCRIPTION

[0038] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with embodiments and drawings. The exemplary embodiments of the present invention and their description are only used to explain the present invention and are not intended to limit the present invention.

[0039] Generally speaking, once a DPU leaves the factory, the device model determines the relevant functions. Customers can only dynamically switch functions through some commands, and cannot adjust the transceiver model according to the network model. For example, in customer scenario 1, the DPU is deployed on the server node, and the transceiver traffic accounts for 8:2; the DPU is deployed on the client node, and the transceiver traffic accounts for 2:8; in customer scenario 2, the DPU is deployed on the distributed computing node, and the client and server transceiver traffic accounts for 5:5. A general solution is unlikely to maximize the performance of each node, and the performance of a single node will affect the total number of DPUs required, and thus the total cost.

[0040] Once a traditional DPU leaves the factory, the device model determines the relevant functions. Customers can only dynamically switch functions through some commands, and cannot adjust the transceiver model according to the network model, making it difficult to maximize the performance of each network node. In view of this, this solution provides the following embodiments to solve the above technical problems:

[0041] Example 1

[0042] This embodiment provides a data processing method based on a dynamic balancing mechanism, such as Figure 1 As shown, including:

[0043] Step 1: Obtain flow distribution information of the data to be processed; the flow distribution information includes optimal NP core distribution ratio information.

[0044] The method for obtaining the optimal NP core distribution ratio information comprises:

[0045] Get all network traffic models;

[0046] Conduct laboratory simulations on each network traffic model, measure the optimal NP core distribution ratio under each network traffic model, and construct an optimal NP core distribution ratio table;

[0047] Obtain the target network traffic model of the data to be processed, and refer to the optimal NP core distribution ratio table to obtain the optimal NP core distribution ratio.

[0048] Step 2: Based on the traffic distribution information, the DPU performs dynamic balancing planning on the NP cores inside the DPU; the DPU performs dynamic balancing planning on the NP cores inside the DPU based on the traffic distribution information, including a method: according to the optimal NP core distribution ratio information, the DPU re-plans the NP cores used for uplink and the NP cores used for downlink.

[0049] like Figure 2 As shown, according to the optimal NP core distribution ratio information, the DPU re-plans the NP cores used for uplink and the NP cores used for downlink; including the method:

[0050] S1, DPU determines whether the i-th NP core in the DPU needs to change the processing direction. If so, it goes to step S2; otherwise, it goes to step S5;

[0051] S2, determine whether the current NP core needs to be changed from the uplink processing direction to the downlink processing direction. If yes, proceed to step S3; otherwise, proceed to step S4;

[0052] S3, determine whether the current NP core is idle. If so, remove the current NP core from the upstream scheduler, replace the logic of the current NP core with the downstream logic and add it to the downstream scheduler, and then enter step S5; otherwise, return to step S3 to re-determine whether the current NP core is idle;

[0053] S4, determine whether the current NP core is idle. If so, remove the current NP core from the downlink scheduler, replace the logic of the current NP core with the uplink logic and add it to the uplink scheduler, and then enter step S5; otherwise, return to step S4 to re-determine whether the current NP core is idle;

[0054] S5, determine whether there is another NP core, if so, return to step S1; otherwise, end.

[0055] The uplink scheduler is used to process data received from the network, and the downlink scheduler is used to process data sent by the host. Steps S1-S5 are implemented by SoC software.

[0056] Step 3: Input the data to be processed into the DPU after dynamic balancing planning for data processing.

[0057] The data processing method based on the dynamic balancing mechanism provided by the present invention improves the method on the basis of the traditional DPU technology. The DPU performs dynamic balancing planning on the NP cores inside the DPU, dynamically adjusts the number of NP cores occupied by sending and receiving data according to application requirements to meet different business scenarios, and easily switches the NP cores for uplink and downlink processing, so that users can achieve the best performance in various scenarios.

[0058] This solution provides a new technical concept. By setting a dynamic balancing mechanism inside the DPU, that is, the DPU dynamically balances the NP cores inside the DPU, the NP cores can easily switch uplink and downlink processing modes in different business scenarios, reasonably allocate the NP cores inside the DPU, and realize the effective utilization of each NP core.

[0059] Example 2

[0060] This embodiment provides a data processing system based on a dynamic balancing mechanism, which is used to implement the data processing method based on a dynamic balancing mechanism described in Embodiment 1; the system includes:

[0061] A collection module is used to obtain flow distribution information of the data to be processed; the collection module includes:

[0062] A collection unit, used to obtain all network traffic models;

[0063] The simulation unit is used to perform laboratory simulation on each network traffic model, measure the optimal NP core distribution ratio under each network traffic model, and construct an optimal NP core distribution ratio table;

[0064] The search unit is used to obtain a target network traffic model of the data to be processed, and to obtain an optimal NP core distribution ratio by consulting an optimal NP core distribution ratio table.

[0065] The planning module is used for the DPU to dynamically balance the NP cores inside the DPU based on the traffic distribution information;

[0066] The processing module is used to input the data to be processed into the DPU after dynamic balancing planning for data processing.

[0067] The planning module and the processing module are both included in the DPU.

[0068] Example 3

[0069] This embodiment provides a computer-readable medium on which a computer program is stored. The computer program is executed by a processor to implement the data processing method based on the dynamic balancing mechanism as described in Embodiment 1. Specifically, the following steps are performed:

[0070] Step 1: Obtaining traffic distribution information of the data to be processed;

[0071] Step 2: Based on the traffic distribution information, the DPU dynamically balances the NP cores inside the DPU.

[0072] Step 3: Input the data to be processed into the DPU after dynamic balancing planning for data processing.

[0073] This embodiment assumes that a DPU network card has 40 cores in total, and the default configuration uses 24 cores for uplink and 16 cores for downlink. The optimal number of uplink and downlink NPs for the laboratory test transceiver traffic model is shown in the following table.

[0074] Transmitting and receiving traffic ratio Ratio of upstream and downstream NPs 5:5 24:16 8:2 36:4 2:8 10:30 ... ...

[0075] The default configuration works best when the ratio of transmit and receive traffic is 5:5. Assume that the actual ratio of transmit and receive traffic in the customer network is 8:2. This solution allows all the first 36 NPs to be configured as upstream logic, and the remaining 4 NPs to be configured as downstream logic. The user sends the configuration, and the SoC implements dynamic balanced DPU data processing in an uninterrupted flow situation to meet the customer's actual network traffic model.

[0076] This solution can dynamically adjust the number of NP cores occupied by sending and receiving data according to application requirements to meet different business scenarios. First, the data processing is divided into uplink and downlink, and the uplink and downlink use different NP logic. The uplink processes the data received from the network, and the downlink processes the data sent by the host. The uplink and downlink logics are processed separately to maximize the use of instruction space. At the same time, the laboratory simulates different traffic models and tests to obtain the best NP distribution ratio under each model.

[0077] When applied in actual customer scenarios, the actual operations are as follows:

[0078] 1. According to the customer network traffic model, look up the table to obtain the best NP distribution ratio,

[0079] 2. Re-plan the NPs used for uplink and downlink according to the new NP distribution ratio.

[0080] 3. Starting from the first NP, check whether each NP needs to change the logic. If it does, continue to step 4. If not, continue to traverse the next NP.

[0081] 4. Remove the NP from the upstream (downstream) scheduler,

[0082] 5. Loop and wait until NP is free.

[0083] 6. Replace NP logic,

[0084] 7. Add the NP to the downstream (upstream) scheduler.

[0085] 8. Check if there are any NPs that need to be processed. If yes, jump to the bottom 3 steps. Otherwise, end.

[0086] Steps 3-8 are implemented by SoC software.

[0087] The present invention allows users to easily switch NP cores for uplink and downlink processing according to the network traffic model, allowing users to achieve optimal performance in various scenario applications.

[0088] This solution provides a new technical concept. By setting a dynamic balancing mechanism inside the DPU, that is, the DPU dynamically balances the NP cores inside the DPU, the NP cores can easily switch uplink and downlink processing modes in different business scenarios, reasonably allocate the NP cores inside the DPU, and realize the effective utilization of each NP core.

[0089] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. A data processing method based on a dynamic balancing mechanism, characterized in that: include: Obtaining traffic distribution information of data to be processed; Based on the traffic distribution information, the DPU performs dynamic balancing planning for the NP cores inside the DPU; The data to be processed is input into the DPU after dynamic balancing planning for data processing.

2. The data processing method based on the dynamic balancing mechanism according to claim 1 is characterized in that: The flow distribution information includes optimal NP core distribution ratio information.

3. The data processing method based on the dynamic balancing mechanism according to claim 2 is characterized in that: The method for obtaining the optimal NP core distribution ratio information comprises: Get all network traffic models; Conduct laboratory simulations on each network traffic model, measure the optimal NP core distribution ratio under each network traffic model, and construct an optimal NP core distribution ratio table; Obtain the target network traffic model of the data to be processed, and refer to the optimal NP core distribution ratio table to obtain the optimal NP core distribution ratio.

4. The data processing method based on the dynamic balancing mechanism according to claim 2 is characterized in that: Based on the traffic distribution information, the DPU performs dynamic balancing planning on the NP cores inside the DPU, including a method: according to the optimal NP core distribution ratio information, the DPU re-plans the NP cores used for uplink and the NP cores used for downlink.

5. The data processing method based on the dynamic balancing mechanism according to claim 4 is characterized in that: The DPU re-plans the NP cores used for uplink and downlink according to the optimal NP core distribution ratio information; including method: S1, DPU determines whether the i-th NP core in the DPU needs to change the processing direction. If so, it goes to step S2; otherwise, it goes to step S5; S2, determine whether the current NP core needs to be changed from the uplink processing direction to the downlink processing direction. If yes, proceed to step S3; otherwise, proceed to step S4; S3, determine whether the current NP core is idle. If so, remove the current NP core from the upstream scheduler, replace the logic of the current NP core with the downstream logic and add it to the downstream scheduler, and then enter step S5; Otherwise, return to step S3 to re-determine whether the current NP core is idle; S4, determine whether the current NP core is idle. If so, remove the current NP core from the downlink scheduler, replace the logic of the current NP core with the uplink logic and add it to the uplink scheduler, and then enter step S5; Otherwise, return to step S4 to re-determine whether the current NP core is idle; S5, determine whether there is another NP core, if so, return to step S1; otherwise, end.

6. The data processing method based on the dynamic balancing mechanism according to claim 5 is characterized in that: The uplink scheduler is used to process data received from the network, and the downlink scheduler is used to process data sent by the host.

7. The data processing method based on the dynamic balancing mechanism according to claim 5 is characterized in that: Steps S1-S5 are implemented by SoC software.

8. A data processing system based on a dynamic balancing mechanism, characterized in that: Used to implement the data processing method based on the dynamic balancing mechanism according to any one of claims 1 to 7; the system comprises: A collection module, used to obtain flow distribution information of data to be processed; The planning module is used for the DPU to dynamically balance the NP cores inside the DPU based on the traffic distribution information; The processing module is used to input the data to be processed into the DPU after dynamic balancing planning for data processing.

9. The data processing system based on the dynamic balancing mechanism according to claim 8, characterized in that: The planning module and the processing module are both included in the DPU.

10. A computer readable medium having a computer program stored thereon, characterized in that: The computer program is executed by a processor to implement the data processing method based on the dynamic balancing mechanism as described in any one of claims 1 to 7.