Lock and Buffer Scheduling for Multi-Core Kernel Execution
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
In multi-core architectures, existing methods for assigning locks and buffers to kernels are inefficient, leading to suboptimal synchronization and data communication within and between cores, which affects performance.
Innovation Solution
A method that maps kernels onto data processing engines (DPEs) based on a graph representation, initializes locks and buffers associated with each kernel, and executes them to generate data samples, while releasing locks for subsequent calls, thereby improving synchronization and data communication.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Productivity
If existing methods for assigning locks and buffers to kernels are used in multi-core architectures, then the system can operate with simple lock assignment, but data reading and writing efficiency deteriorates leading to suboptimal synchronization and performance
Solution Approach 1:
The patent applies preliminary action by initializing locks and buffers before kernel execution begins. The compiler assigns and prepares synchronization locks and data buffers in advance during the code generation phase, so that when kernels execute on multiple cores, the synchronization infrastructure is already in place. This prevents runtime conflicts and improves data reading/writing efficiency without requiring complex dynamic lock management during execution.
Solution Approach 2:
The patent introduces locks as intermediary synchronization objects that mediate between multiple kernels executing on different cores. These locks act as intermediaries to coordinate access to shared buffers and data structures, enabling efficient data communication between cores while maintaining system-wide consistency. The lock mechanism serves as a mediator that resolves potential conflicts without requiring direct kernel-to-kernel coordination.
2Reliability
If locks are initialized before kernel calls, then synchronization performance improves, but the code generation process becomes more complex
Solution Approach 1:
The compiler performs preliminary initialization of locks and buffers during the code generation phase, before kernels are executed. This preliminary action ensures that all synchronization objects are properly set up with correct initial states, improving synchronization reliability. The compiler generates initialization code that runs once at the start, eliminating the need for repeated lock setup and reducing runtime complexity.
Solution Approach 2:
The system employs self-service by having the compiler automatically generate and insert lock initialization code at appropriate locations in the generated program. The compilation process itself services the synchronization setup requirement, identifying where locks and buffers need to be initialized and generating the appropriate code without requiring external intervention or manual configuration. This self-service approach manages complexity within the toolchain while maintaining simple kernel code.
Data Source
AI summary
Application code is compiled to generate code to be executed by the cores of a multi-core architecture. Generating the code includes mapping kernels of the application onto the DPEs, and generating main code for cores of the DPEs. The main code is generated by initializing locks for each kernel associated with the cores the DPEs. The locks are associated with input ports and output ports of the kernels. Further, buffers are initialized for the kernels. The buffers are associated with the locks and data streams. Subsequent to initializing the locks and initializing the buffers, the kernels are executed to generate data samples from the data streams. Subsequent to executing the kernels, the locks are released for subsequent calls of the kernels.


