CPU Resource Control via Adjustment Count Feedback in Virtual Machines
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
In symmetric multi-processing systems, the overhead from virtual inter-processor interrupts (vIPIs) processed by Hypervisors leads to a waste of CPU resources due to inefficient CPU load balancing, as existing technologies fail to accurately identify increased CPU consumption and only balance based on queue length, resulting in excessive vIPI generation and resource wastage.
Innovation Solution
A CPU resource control method that detects CPU usage in virtual machines, identifies processes exceeding a threshold, adjusts the number of CPUs allocated based on the number of adjustments made, and selects CPUs for use in ascending order of resource usage, reducing vIPIs and minimizing resource waste by gradually decreasing CPU allocation until it reaches 1.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Productivity
If automatic CPU load balancing is performed based on queue length, then CPU computility is balanced, but the number of vIPIs increases causing CPU resource wastage
Solution Approach 1:
The patent changes the parameter for CPU allocation from static queue length-based allocation to dynamic allocation based on the number of adjustments. By monitoring how many times a process has been adjusted and using this count to determine CPU allocation, the system reduces unnecessary vIPIs while maintaining balanced computility utilization.
2Productivity
If more processes are generated to balance CPU computility, then CPU load is distributed, but the number of vIPIs increases leading to more CPU resource wastage
Solution Approach 1:
The patent introduces feedback by monitoring the number of adjustments a process has undergone. This feedback information is used to dynamically adjust CPU allocation, preventing continuous migration and reducing the time spent processing vIPIs while maintaining effective CPU load distribution.
3Loss of energy
If CPU allocation is reduced for processes with frequent adjustments, then vIPIs are minimized, but process performance may be affected
Solution Approach 1:
The patent applies dynamics by making CPU allocation adaptive rather than fixed. The allocation varies based on the number of adjustments a process has undergone, allowing the system to optimize between reducing vIPIs and maintaining process execution stability through flexible, data-driven resource allocation.
Data Source
AI summary
A CPU resource control method and apparatus, and a computer-readable storage medium are provided. The method includes: detecting CPU resources occupied by a plurality of processes in a virtual machine; taking a process among the plurality of processes that occupies the CPU resources over a preset threshold as a target process required to adjust a CPU to be used, and calculating, according to the number of times the target process has been adjusted, the number of CPUs to be used by the target process, as the number of times the target process has been adjusted increases, the number of CPUs to be used by the target process decreases until it reaches 1; no longer detecting the target process when the number of CPUs to be used by the target process is 1; and selecting at least one CPU from the plurality of CPUs for use by the target process.


