Multi-Core Task Scheduler Deferral Mechanism
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
In multi-core processor systems, conventional scheduling mechanisms face issues with deadlocks and unacceptably long delays due to the single lock mechanism and performance problems with multiple lock strategies, particularly in Symmetric Multiprocessing (SMP) systems where tasks competing for critical data sections can lead to system freezing.
Innovation Solution
A method and apparatus for deferring scheduling operations, including preempting, suspending, and balancing tasks on a multi-core processor, using a modular scheduler that receives system calls, invokes scheduling instances, and defers switching contexts to prevent deadlocks and optimize core usage, particularly by using Software Generated Interrupts (SGIs) to manage task priorities and access critical sections efficiently.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If a single lock mechanism is used to access critical data sections, then data consistency is maintained, but system delays increase and productivity decreases
Solution Approach 1:
The patent divides the single lock mechanism into multiple independent locks (first lock, second lock, third lock) corresponding to different critical data sections. Each lock can be acquired and released independently, allowing parallel access to different sections. This segmentation resolves the contradiction by maintaining data consistency within each section while enabling concurrent access across sections, thus improving productivity without sacrificing reliability.
2Productivity
If multiple lock strategies are used to increase access parallelism, then productivity improves, but deadlocks occur and system reliability decreases
Solution Approach 1:
The patent implements a hierarchical lock acquisition strategy where tasks must acquire locks in a predetermined order (first lock, then second lock, then third lock). This preliminary establishment of acquisition sequence prevents circular waiting conditions that cause deadlocks. The system maintains productivity through parallel lock acquisition where possible, while ensuring reliability by enforcing a global lock ordering constraint.
Solution Approach 2:
The patent introduces a lock manager as an intermediary component that coordinates lock acquisition and release across multiple tasks. The lock manager maintains a wait-for graph and detects potential deadlocks before they occur, allowing the system to prevent unreliable states while maintaining high productivity through efficient lock scheduling and task coordination.
3Reliability
If locks are held for extended periods to complete complex operations, then task reliability improves, but other tasks are blocked and productivity decreases
Solution Approach 1:
The patent segments complex operations into smaller sub-tasks that can be performed while holding individual locks. Instead of holding a lock for the entire duration of a complex operation, the operation is divided into stages, each requiring a specific lock for a limited time. This reduces lock hold time and allows other tasks to acquire locks and proceed, improving productivity while maintaining task completion reliability through structured operation decomposition.
Solution Approach 2:
The patent implements lock release and re-acquisition mechanisms that allow tasks to release locks temporarily while maintaining progress. Tasks can release non-critical locks to allow other tasks to proceed, then re-acquire them when needed. This continuous cycle of acquiring, releasing, and re-acquiring locks ensures that useful work continues across multiple tasks without unnecessary blocking, balancing reliability with productivity.
Data Source
AI summary
Provided is a method for scheduling of tasks for an operating system on a multi-core processor. The method includes receiving a system call for initiating a scheduling operation on a second core and invoking a scheduling instance to the second core, and the scheduling instance notifies the scheduling operation of an incoming high priority task. Further, the method includes deferring a switching context instance at the second core, and the deferring the switching context instance at the second core includes unblocking the first core to perform other tasks.


