Application programming interfaces for data parallel computing on multiple processors
AssigneeApple Inc.
InventorsAaftab A. Munshi, Nathaniel Begeman
Life of this patent
Estimating the term…
Abstract
A method and an apparatus for a parallel computing program calling APIs (application programming interfaces) in a host processor to perform a data processing task in parallel among compute units are described. The compute units are coupled to the host processor including central processing units (CPUs) and graphic processing units (GPUs). A program object corresponding to a source code for the data processing task is generated in a memory coupled to the host processor according to the API calls. Executable codes for the compute units are generated from the program object according to the API calls to be loaded for concurrent execution among the compute units to perform the data processing task.
Claims24
A parallel computing system comprising:
- a host processor;
- one or more compute units coupled to the host processor;
- a memory coupled to at least one of the host processor and the one or more compute units, wherein a parallel computing program is stored in the memory, the parallel computing program including calls to one or more APIs (application programming interface) for the host processor to perform:
- selecting the compute units based on processing requirements, at least one of the calls to the APIs specifying the processing requirements for the selection;
- generating a program object corresponding to a source code for a data processing task, at least one of the calls to the APIs specifying the source code for the generation of the program object;
- generating executable codes from the program object for the one or more compute units, at least one of the calls to the APIs specifying the program object for the generation of the executable codes;
- and
- loading the executable codes to be executed concurrently among the one or more compute units to perform the data processing task.
A parallel computing system comprising:
- a host processor;
- one or more compute units coupled to the host processor;
- a memory coupled to at least one of the host processor and the one or more compute units, wherein a parallel computing program is stored in the memory, the parallel computing program including calls to one or more APIs (application programming interface) for the host processor to perform:
- generating a program object corresponding to a source code for a data processing task;
- generating executable codes from the program object for the one or more compute units;
- and
- loading the executable codes to be executed concurrently among the one or more compute units to perform the data processing task,
- wherein the loading of the executable codes comprises:
- generating a kernel object associated with a function name identifying a function implementing the data processing task in the source codes, the kernel object including storage for arguments of the function;
- and
- scheduling execution of the executable codes among the one or more compute units, wherein the execution including number of threads in a thread group to execute one of the executable codes concurrently in at least one of the one or more compute units.
A machine readable non-transitory storage medium storing a plurality of tokens comprising:
- host function tokens corresponding to one or more APIs (application programming interfaces) for a host processor to perform one or more host functions including:
- selecting one or more compute units coupled to the host processor based on processing requirements specified through the one or more APIs;
- generating a program object corresponding to a source code for a data processing task, the source code for the data processing task being specified through the one or more APIs;
- generating executable codes from the program object for one or more compute units coupled to the host processor, the program object for the generation of the executable codes being specified through the one or more APIs;
- and
- loading the executable codes to be executed concurrently among the one or more compute units to perform the data processing task;
- and
- kernel function tokens corresponding to the source code for the data processing task.
A machine-readable non-transitory storage medium storing a plurality of tokens comprising:
- host function tokens corresponding to one or more APIs (application programming interfaces) for a host processor to perform one or more host functions including:
- generating a program object corresponding to a source code for a data processing task,
- generating executable codes from the program object for one or more compute units coupled to the host processor, and
- loading the executable codes to be executed concurrently among the one or more compute units to perform the data processing task, and
- kernel function tokens corresponding to the source code for the data processing task,
- wherein the loading of the executable codes comprises:
- generating a kernel object associated with a function name identifying a function implementing the data processing task in the source codes, the kernel object including storages for arguments of the function;
- and
- scheduling execution of the executable codes among the one or more compute units, wherein the scheduling including number of threads in a thread group to execute one of the executable codes concurrently in at least one of the one or more compute units.
Dependencies are inferred from the claim text.