Software Library Execution Sampling for Granular CPU Attribution
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing systems struggle to accurately track CPU usage by software libraries, as they are invoked by multiple programs, making it difficult to optimize resource allocation and performance in computing environments.
Innovation Solution
A computer program product that samples instructions from software libraries at timed intervals, generating execution parameters and metadata to determine CPU usage, allowing for transparent resource allocation and optimization without modifying the software libraries.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Measurement precision
If the operating system tracks CPU access by programs, then program CPU usage can be monitored, but software library CPU usage cannot be accurately tracked because a software library can be invoked by multiple programs
Solution Approach 1:
The patent introduces an intermediary tracking mechanism that sits between the program execution layer and the CPU. This intermediary uses sampling techniques to capture library invocation events, attributing CPU usage to specific software libraries even when called by multiple programs. The intermediary layer resolves the measurement problem without requiring fundamental changes to the operating system's core tracking infrastructure.
Solution Approach 2:
The patent creates a simplified copy or representation of the actual CPU execution trace that specifically highlights software library invocations. By maintaining this copied trace information with library-specific metadata, the system can accurately measure library CPU usage without directly instrumenting every program that calls the libraries, thus avoiding excessive complexity.
2Measurement precision
If sampling is performed at timed intervals to capture library execution, then granular CPU usage data can be obtained, but system performance may be degraded due to the overhead of frequent sampling
Solution Approach 1:
The patent implements periodic sampling at predetermined time intervals to capture library execution events. This periodic approach balances measurement precision with system performance by not continuously monitoring but rather taking snapshots at regular intervals, reducing overhead while still providing granular CPU usage data over time.
Solution Approach 2:
The sampling mechanism performs partial monitoring by focusing only on capturing library invocation events rather than tracking every CPU instruction. This selective partial action provides sufficient granularity for library-level measurement without the excessive overhead of complete instruction-level tracking, maintaining system productivity.
3Loss of information
If metadata is stored for each software object to track workload type, then library access can be classified, but memory usage increases due to storing additional attributes
Solution Approach 1:
The patent applies local quality by storing workload type metadata only where needed - specifically associated with software library objects that are actually being tracked. Not all software objects receive this treatment; only those requiring classification. This selective approach retains necessary workload information while minimizing overall memory consumption by avoiding universal metadata application.
Data Source
AI summary
Execution of an instruction includes obtaining software objects and loading instructions into a memory and storing the workload type attribute for each software object. The execution includes operations that during runtime, deploy a first hardware instruction to trigger a firmware process to sample, at each interval of timed pre-configured intervals, instructions from the sets of instructions of the one or more software objects being executed during the interval by one or more processors of the computing system. The operations include deploying a second hardware instruction to obtain and store samples from the firmware process in the memory. The operations include generating, based on analyzing the stored samples, execution parameters associated with each sample. The operations include determining accesses to the software libraries in the computing system, by workload type attribute. The operations automatically implement an action related to at least one software object in the computing system.


