Thread-Embedded Cache Line Locking for Multi-Threaded Memory Traffic Reduction

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

In multi-threaded environments, cache management is inefficient as cache lines are often evicted prematurely, leading to increased memory traffic, reduced performance predictability, and higher power usage due to frequent access to main memory instead of the cache.

Innovation Solution

Implementing a thread-locking mechanism that maintains cache lines in the cache until all threads have finished accessing them, using counter bits to track access counts and ensuring cache lines are evicted only when all threads have completed their operations, thereby optimizing cache usage and reducing memory hierarchy traffic.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Adaptability or versatility

If cache lines are evicted prematurely to make cache space available, then cache availability is improved, but memory traffic increases and performance predictability deteriorates

Engineering Contradiction:
Improvecache availabilityVSAvoidperformance predictability
Core Design Contradiction:
Adaptability or versatilityVSReliability

Solution Approach 1:

The patent applies preliminary action by establishing thread ownership and lock status before cache line eviction occurs. Each thread that loads a cache line sets a lock bit and decrements a counter, ensuring the cache line is held until all threads have finished accessing it. This preliminary tracking mechanism prevents premature eviction while maintaining cache space availability.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent implements feedback through counter bits and lock status tracking that continuously monitor thread access patterns. The feedback mechanism allows the cache management system to adjust eviction decisions based on real-time thread completion status, ensuring cache lines are evicted only when safe to do so.

Inventive Principle:
Principle #23Feedback

2Reliability

If cache lines are maintained longer to ensure all threads finish accessing, then performance predictability is improved, but memory traffic increases due to longer retention

Engineering Contradiction:
Improveperformance predictabilityVSAvoidpower usage
Core Design Contradiction:
ReliabilityVSLoss of energy

Solution Approach 1:

The patent applies preliminary action by pre-establishing thread ownership tracking before cache line eviction. The counter mechanism and lock bits are set in advance, allowing the system to accurately determine when all threads have finished accessing a cache line without unnecessary retention, thus reducing power consumption while maintaining performance predictability.

Inventive Principle:
Principle #10Preliminary action

3Productivity

If multiple threads access the same cache line simultaneously, then productivity is improved, but cache management complexity increases

Engineering Contradiction:
Improvethread execution efficiencyVSAvoidcache management complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent applies segmentation by dividing the cache management task into per-thread operations. Each thread independently manages its own lock status and counter decrement, simplifying the overall cache management complexity while enabling efficient simultaneous access by multiple threads through a modular approach.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent implements self-service by allowing each thread to automatically manage its own access tracking through counter decrement and lock bit setting. This eliminates the need for complex centralized cache management logic, reducing system complexity while maintaining high productivity through efficient multi-threaded cache access.

Inventive Principle:
Principle #25Self-service

Data Source

PatentUS11593167B2Thread embedded cache management
Publication Date: 2023.02.28 INTERNATIONAL BUSINESS MACHINE CORPORATION
  • US11593167B2 patent drawing
  • US11593167B2 patent drawing
  • US11593167B2 patent drawing

AI summary

Methods and systems for locking a cache line of a cache. A cache line is locked based on a count of a plurality of threads that access the cache line and maintained in the cache until all of the plurality of threads have loaded the cache line.