Dynamic Worker Thread Scheduling for CPU Load Management

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing task management systems face inefficiencies in parallel processing, particularly in database management systems, due to excessive thread creation, synchronization, and context switches, which can lead to performance degradation even with multiple task schedulers, and fail to effectively handle situations where CPUs are overloaded despite available worker threads.

Innovation Solution

A dynamic method for managing parallel processing that determines a scheduling limit based on CPU availability, reducing the number of worker threads when CPU load exceeds a threshold, and dynamically adjusts the scheduling limit to prevent overloading, allowing for fine-grained workload prioritization and resource management.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Loss of energy

If worker threads are limited to match the number of CPUs, then resource utilization is optimized, but processing throughput may be reduced when CPU capacity is underutilized

Engineering Contradiction:
Improvecomputational resources used in synchronization and schedulingVSAvoidprocessing throughput
Core Design Contradiction:
Loss of energyVSProductivity

Solution Approach 1:

The patent implements dynamic adjustment of the worker thread pool size based on real-time CPU load monitoring. When CPU load exceeds a threshold, the system reduces the number of worker threads to minimize synchronization overhead. When CPU load decreases, the system increases worker threads to maximize parallel processing capability. This dynamic adaptation resolves the contradiction by allowing the system to optimize for resource efficiency during high-load periods and for throughput during low-load periods.

Inventive Principle:
Principle #15Dynamics

2Speed

If the number of worker threads is increased to maximize parallel processing, then processing speed improves, but synchronization overhead and context switches increase

Engineering Contradiction:
Improvetask execution speedVSAvoidsynchronization overhead
Core Design Contradiction:
SpeedVSDevice complexity

Solution Approach 1:

The patent changes the parameter of worker thread count dynamically based on system conditions. Instead of using a fixed large number of threads to maximize speed, the system adjusts the thread count parameter in response to CPU load measurements. This allows the system to maintain high processing speed when resources are available while reducing synchronization overhead when resources are constrained, effectively resolving the contradiction between speed and complexity.

Inventive Principle:
Principle #35Parameter changes

3Ease of operation

If a fixed maximum number of worker threads is set, then resource management is simplified, but the system cannot adapt to varying workload demands

Engineering Contradiction:
Improveresource management simplicityVSAvoidworkload adaptation capability
Core Design Contradiction:
Ease of operationVSAdaptability or versatility

Solution Approach 1:

The patent implements a feedback mechanism where the system continuously monitors CPU load and uses this information to adjust the worker thread pool size. The monitoring component provides feedback about system state, and the task scheduler uses this feedback to dynamically modify resource allocation. This feedback loop enables the system to automatically adapt to varying workload demands while maintaining relatively simple resource management through centralized control policies.

Inventive Principle:
Principle #23Feedback

Data Source

PatentEP3422183B1Managing parallel processing
Publication Date: 2021.08.25 SAP SE
  • EP3422183B1 patent drawingFigure 1
  • EP3422183B1 patent drawingFigure 2
  • EP3422183B1 patent drawingFigure 3

AI summary

The present application relates to a method, a system, and a computer program product. The method may comprise managing parallel processing on a computer system, wherein the computer system comprises one or more computers, wherein each of the computers has at least one CPU and at least one of the computers has multiple CPUs. The managing may comprise determining a scheduling limit, wherein the scheduling limit restricts the number of worker threads available for executing tasks on the computer system. The managing may further comprise executing a plurality of tasks on the computer system. The managing may further comprise determining an availability of a CPU based on whether a load of the CPU exceeds a first threshold. When the CPU is determined to be unavailable, the method may further comprise reducing the scheduling limit, and scheduling a further task for execution on one of the CPUs according to the reduced scheduling limit. The scheduling may comprise limiting the worker threads available to execute tasks on the computer system, such that the quantity of worker threads available for executing tasks does not exceed the scheduling limit.