IP Library Granted Patent US 11,900,113
Granted Patent B2
US 11,900,113 · App. 17/227,590 · Granted Feb 13, 2024

Data flow processing method and related device

Inventors: Lijuan Hai (Beijing, CN); Chen Cheng (Hangzhou, CN); Christopher Rodrigues (Santa Clara, CA); Peng Wu (Shenzhen, CN)
Assignee: Huawei Technologies Co., Ltd.
G06F9/3005G06F8/314G06F8/433G06F8/458G06F9/30087G06F9/3867G06F9/522
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,900,113
App. No.
17/227,590
Granted
Feb 13, 2024
Kind
B2
Abstract

The present disclosure relates to data flow processing methods and devices. One example method includes obtaining a dependency relationship and an execution sequence of operating a data flow by a plurality of processing units, generating synchronization logic based on the dependency relationship and the execution sequence, and inserting the synchronization logic into an operation pipeline of each of the plurality of processing unit to generate executable code.

Claims (48)

1. A data flow processing method, wherein the method comprises:

obtaining, through serialization analysis, a dependency relationship and an execution sequence of operating a data flow by a plurality of processing units, wherein each processing unit of the plurality of processing units corresponds to an operation pipeline;

generating synchronization logic based on the dependency relationship and the execution sequence, wherein the synchronization logic ensures synchronization between operation instructions in the plurality of operation pipelines; and

in response to generating the synchronization logic, automatically inserting the synchronization logic into each operation pipeline corresponding to each processing unit of the plurality of processing units to generate executable code.

2. The method according to claim 1 , wherein obtaining the dependency relationship and the execution sequence of operating the data flow by the plurality of processing units comprises:

obtaining descriptive code used to describe the data flow; and

determining the dependency relationship and the execution sequence based on the descriptive code.

3. The method according to claim 2 , wherein the descriptive code comprises at least one of a keyword used to define a buffer variable, a keyword used to describe a read operation and a write operation for buffering the data flow, an operator used to specify a write buffer variable, or a keyword used to specify a read buffer variable.

4. The method according to claim 1 , wherein the dependency relationship indicates that a first operation instruction in an operation pipeline of a first processing unit of the plurality of processing units is executed first before a second operation instruction in an operation pipeline of a second processing unit of the plurality of processing units starts to be executed, and wherein the execution sequence indicates a time sequence in which operation instructions of the plurality of processing units that are transmitted to operation pipelines of a corresponding type to wait for execution.

5. The method according to claim 1 , wherein generating the synchronization logic based on the dependency relationship and the execution sequence comprises:

constructing, based on the dependency relationship and the execution sequence, a dependency decision tree of operating the data flow by the plurality of processing units; and

generating the synchronization logic based on the dependency decision tree.

6. The method according to claim 1 , wherein the synchronization logic comprises a barrier instruction and an event synchronization instruction, and wherein generating the synchronization logic based on the dependency relationship and the execution sequence comprises:

generating the event synchronization instruction based on the dependency relationship; and

generating the barrier instruction based on the execution sequence.

7. The method according to claim 1 , wherein generating the synchronization logic based on the dependency relationship and the execution sequence comprises:

determining that the dependency relationship is not transfer dependency; and

generating the synchronization logic in response to determining that the dependency relationship is not the transfer dependency.

8. A data flow processing apparatus, comprising a memory, a communications bus, and at least one processor, wherein the memory stores programming instructions for execution by the at least one processor to perform operations comprising:

obtaining, through serialization analysis, a dependency relationship and an execution sequence of operating a data flow by a plurality of processing units, wherein each processing unit of the plurality of processing units corresponds to an operation pipeline;

generating synchronization logic based on the dependency relationship and the execution sequence, wherein the synchronization logic ensures synchronization between operation instructions in the plurality of operation pipelines; and

in response to generating the synchronization logic, automatically inserting the synchronization logic into each operation pipeline corresponding to each processing unit of the plurality of processing units to generate executable code.

9. The apparatus according to claim 8 , wherein obtaining the dependency relationship and the execution sequence of operating the data flow by the plurality of processing units comprises:

obtaining descriptive code used to describe the data flow; and

determining the dependency relationship and the execution sequence based on the descriptive code.

10. The apparatus according to claim 9 , wherein the descriptive code comprises at least one of a keyword used to define a buffer variable, a keyword used to describe a read operation and a write operation for buffering the data flow, an operator used to specify a write buffer variable, or a keyword used to specify a read buffer variable.

11. The apparatus according to claim 8 , wherein the dependency relationship indicates that a first operation instruction in an operation pipeline of a first processing unit of the plurality of processing units is executed first before a second operation instruction in an operation pipeline of a second processing unit of the plurality of processing units starts to be executed, and wherein the execution sequence indicates a time sequence in which operation instructions of the plurality of processing units that are transmitted to operation pipelines of a corresponding type to wait for execution.

12. The apparatus according to claim 8 , wherein generating the synchronization logic based on the dependency relationship and the execution sequence comprises:

constructing, based on the dependency relationship and the execution sequence, a dependency decision tree of operating the data flow by the plurality of processing units; and

generating the synchronization logic based on the dependency decision tree.

13. The apparatus according to claim 8 , wherein the synchronization logic comprises a barrier instruction and an event synchronization instruction, and wherein generating the synchronization logic based on the dependency relationship and the execution sequence comprises:

generating the event synchronization instruction based on the dependency relationship; and

generating the barrier instruction based on the execution sequence.

14. The apparatus according to claim 8 , wherein generating the synchronization logic based on the dependency relationship and the execution sequence comprises:

determining that the dependency relationship is not transfer dependency; and

generating the synchronization logic in response to determining that the dependency relationship is not the transfer dependency.

15. A non-transitory computer-readable storage medium, wherein the computer-readable storage medium stores an instruction which when run on a computer, cause the computer to perform operations comprising:

obtaining, through serialization analysis, a dependency relationship and an execution sequence of operating a data flow by a plurality of processing units, wherein each processing unit of the plurality of processing units corresponds to an operation pipeline;

generating synchronization logic based on the dependency relationship and the execution sequence, wherein the synchronization logic ensures synchronization between operation instructions in the plurality of operation pipelines; and

in response to generating the synchronization logic, automatically inserting the synchronization logic into each operation pipeline corresponding to each processing unit of the plurality of processing units to generate executable code.

16. The non-transitory computer-readable storage medium according to claim 15 , wherein obtaining the dependency relationship and the execution sequence of operating the data flow by the plurality of processing units comprises:

obtaining descriptive code used to describe the data flow; and

determining the dependency relationship and the execution sequence based on the descriptive code.

17. The non-transitory computer-readable storage medium according to claim 16 , wherein the descriptive code comprises at least one of a keyword used to define a buffer variable, a keyword used to describe a read operation and a write operation for buffering the data flow, an operator used to specify a write buffer variable, or a keyword used to specify a read buffer variable.

18. The non-transitory computer-readable storage medium according to claim 15 , wherein the dependency relationship indicates that a first operation instruction in an operation pipeline of a first processing unit of the plurality of processing units is executed first before a second operation instruction in an operation pipeline of a second processing unit of the plurality of processing units starts to be executed, and wherein the execution sequence indicates a time sequence in which operation instructions of the plurality of processing units that are transmitted to operation pipelines of a corresponding type to wait for execution.

19. The non-transitory computer-readable storage medium according to claim 15 , wherein generating the synchronization logic based on the dependency relationship and the execution sequence comprises:

constructing, based on the dependency relationship and the execution sequence, a dependency decision tree of operating the data flow by the plurality of processing units; and

generating the synchronization logic based on the dependency decision tree.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded May 20, 2021
From: HAI, LIJUAN; CHENG, CHEN; RODRIGUES, CHRISTOPHER; WU, PENG
To: HUAWEI TECHNOLOGIES CO., LTD.
Reel/Frame 056299/0717 →
Priority Claims (1)
CN 201811236134.8 · Oct 23, 2018 · national
Continuity (2)
Continuation PCTCN2019110741 · Oct 12, 2019
Related Publication 20210232394A1 · Jul 29, 2021
Cited By (1)
US 12,260,200