In-Memory Accumulation for Hardware Performance Counter Overflow

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current monitoring systems for computer hardware performance face challenges such as counter overflow, resource-intensive polling, limited counter availability, and differing interfaces for physical and virtual device monitoring, making it difficult to achieve comprehensive and efficient system-wide performance monitoring.

Innovation Solution

The implementation of an in-memory accumulation (IMA) mechanism that continuously updates extensive tables in memory with hardware performance event counts, using a uniform interface and minimal resource consumption, allowing for simultaneous characterization of physical-device, virtual-machine, and code-state operations.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Measurement precision

If hardware counters are used to monitor performance events, then measurement precision is improved, but counter overflow occurs when event counts exceed counter capacity

Engineering Contradiction:
Improveperformance event count accuracyVSAvoidcounter overflow handling
Core Design Contradiction:
Measurement precisionVSReliability

Solution Approach 1:

The patent transitions from fixed-width hardware counters to variable-precision software-managed counters in memory. By moving counter storage to memory and using software to manage counter values, the system gains dimensional flexibility in counter precision and range, eliminating overflow while maintaining measurement precision through appropriate data type selection and software intervention.

Inventive Principle:
Principle #17Another dimension (Dimensionality change)

Solution Approach 2:

The system dynamically changes counter parameters by adjusting counter width and precision based on event frequency and monitoring requirements. Software can allocate counters of different precisions (e.g., 32-bit vs 64-bit) and adjust counter intervals, transforming the fixed-parameter hardware counter into a flexible, adaptive counter system that prevents overflow while maintaining measurement accuracy.

Inventive Principle:
Principle #35Parameter changes

2Loss of information

If polling is used to collect counter data, then measurement completeness is improved, but resource consumption increases

Engineering Contradiction:
Improveperformance data completenessVSAvoidpolling resource consumption
Core Design Contradiction:
Loss of informationVSUse of energy by moving object

Solution Approach 1:

The patent implements periodic counter sampling with variable intervals. Instead of continuous monitoring, the system samples counters at optimized intervals based on event rates and monitoring priorities. This periodic action maintains data completeness for high-priority events while significantly reducing polling frequency and resource consumption for low-priority monitoring.

Inventive Principle:
Principle #19Periodic action

Solution Approach 2:

The system enables self-service monitoring where performance data is automatically collected, stored, and made available without requiring active polling. Counters continuously update in the background, and data is automatically harvested when needed, eliminating the resource-intensive polling mechanism while ensuring data completeness through continuous passive accumulation.

Inventive Principle:
Principle #25Self-service

3Measurement precision

If multiple counters are allocated for different events, then measurement precision is improved, but device complexity increases

Engineering Contradiction:
Improveevent-specific measurement accuracyVSAvoidcounter management complexity
Core Design Contradiction:
Measurement precisionVSDevice complexity

Solution Approach 1:

The patent creates a universal counter management system where a single software framework handles multiple event types and counter configurations. This universal interface provides consistent methods for creating, configuring, and managing counters across different event types, reducing complexity while maintaining the ability to allocate appropriate precision and resources for each specific measurement requirement.

Inventive Principle:
Principle #6Universality (Multi-functionality)

Solution Approach 2:

The system segments counter management into independent, configurable units. Each performance event has its own counter instance with independently configurable parameters (width, interval, priority). This segmentation allows precise control over each counter while the modular structure prevents complexity from propagating across the entire system, as each counter can be managed and optimized independently.

Inventive Principle:
Principle #1Segmentation

4Measurement precision

If hardware counters are used for monitoring, then measurement precision is improved, but adaptability to different event types is limited

Engineering Contradiction:
Improvecounter measurement accuracyVSAvoidevent type flexibility
Core Design Contradiction:
Measurement precisionVSAdaptability or versatility

Solution Approach 1:

The patent implements a universal counter interface that can monitor any performance event type through a standardized mechanism. The software layer provides event-type-agnostic counter management, allowing the same counter infrastructure to track diverse events (cache misses, branch predictions, memory accesses) with appropriate precision configured for each event type, thereby achieving both measurement precision and adaptability.

Inventive Principle:
Principle #6Universality (Multi-functionality)

Solution Approach 2:

The system transforms static hardware counters into dynamic, software-configurable monitoring entities. Counter parameters such as precision, sampling interval, and event type can be dynamically adjusted based on monitoring requirements. This dynamic adaptability allows the counter system to flexibly respond to different event types and monitoring scenarios while maintaining measurement precision through software-controlled configuration.

Inventive Principle:
Principle #15Dynamics

Data Source

PatentUS9298651B2Continuous in-memory accumulation of hardware performance counter data
Publication Date: 2016.03.29 INTERNATIONAL BUSINESS MACHINE CORPORATION
  • US9298651B2 patent drawing
  • US9298651B2 patent drawing
  • US9298651B2 patent drawing

AI summary

In-memory accumulation of hardware counts in a computer system is carried out by continuously sending count values from full-speed hardware counter units to a memory controller. A sending unit periodically samples performance data from the hardware counter units, and transmits count values to a bus interface for an interconnection bus which communicates with the memory controller. The memory controller responsively updates an accumulated count value stored in system memory using the current count value, e.g., incrementing the accumulated count value. A count value can be sent with a pointer to a memory location and an instruction on how the location is to be updated. The instruction may be an atomic read-modify-write operation, and the memory controller can include a dedicated arithmetic logic unit to carry out that operation. A data harvester can then be used to harvest accumulated count values by reading them from a table in system memory.