Cache Metadata for Bounded Transactional Memory

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current CPU cache systems lack software accessibility and metadata management, making it difficult to optimize cache operations and coordinate parallel tasks efficiently in multiprocessor environments, particularly in scenarios involving transactional memory and cache coherence.

Innovation Solution

Introducing software-accessible metadata in the CPU cache, including per-cache-line and per-cache metadata, which allows additional instructions to interact with and manage cache states, enabling improved transactional memory operations and cache coherence through metadata-based operations such as transaction-read and transaction-write bits, eviction summaries, and barrier filtering.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If software transactional memory operations are implemented without cache metadata access, then cache coherence can be maintained through hardware-only mechanisms, but transaction performance deteriorates due to inability to optimize cache operations

Engineering Contradiction:
Improvetransaction performanceVSAvoidcache metadata management complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent introduces cache metadata as an intermediary structure between software transactional memory operations and the physical cache hardware. This metadata layer enables software to query and manage cache states without directly controlling hardware operations, resolving the contradiction by providing optimization capabilities while maintaining hardware independence through a manageable intermediate interface

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The cache metadata is segmented into multiple levels (per-cache-line metadata and per-cache metadata) that can be independently managed and accessed. This segmentation allows the system to provide fine-grained control for transaction optimization while keeping the overall management complexity manageable through hierarchical organization

Inventive Principle:
Principle #1Segmentation

2Productivity

If per-cache-line metadata is added to enable transactional memory operations, then transactional read and write operations can be optimized, but cache line structure becomes more complex

Engineering Contradiction:
Improvetransactional memory operation efficiencyVSAvoidcache line structure complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent merges transactional metadata bits (transaction-read bit, transaction-write bit) with existing per-cache-line metadata structures. By combining these functions into a unified metadata structure, the system achieves optimized transactional operations without proportionally increasing structural complexity, as the metadata serves multiple purposes

Inventive Principle:
Principle #5Merging (Combining)

3Productivity

If cache metadata is made software accessible, then transactional memory performance improves through direct metadata operations, but hardware cache coherence protocols become more complex

Engineering Contradiction:
Improvesoftware transactional memory performanceVSAvoidhardware cache coherence protocol complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The software-accessible metadata acts as an intermediary layer that translates software transactional memory operations into appropriate hardware cache coherence actions. This allows performance optimization through direct metadata access while the hardware coherence protocols remain relatively simple, as the metadata layer handles the complexity of coordinating between software transactions and hardware coherence mechanisms

Inventive Principle:
Principle #24Intermediary (Mediator)

4Reliability

If eviction summary metadata is implemented to track cache line evictions, then transactional memory can detect and handle evictions efficiently, but metadata management overhead increases

Engineering Contradiction:
Improvetransactional memory reliabilityVSAvoidmetadata management overhead
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The eviction summary metadata structure enables the cache system to self-track and report eviction events to software transactional memory operations. This self-service mechanism provides reliable eviction detection without requiring complex external monitoring systems, as the cache hardware automatically maintains and updates the eviction summary when evictions occur

Inventive Principle:
Principle #25Self-service

Data Source

PatentEP2174223B1Cache metadata for implementing bounded transactional memory
Publication Date: 2019.05.15 MICROSOFT TECHNOLOGY LICENSING LLC
  • EP2174223B1 patent drawingFigure 1
  • EP2174223B1 patent drawingFigure 2
  • EP2174223B1 patent drawingFigure 3

AI summary

Various technologies and techniques are disclosed for providing a bounded transactional memory application that accesses cache metadata in a cache of a central processing unit. When performing a transactional read from the bounded transactional memory application, a cache line metadata transaction-read bit is set. When performing a transactional write from the bounded transactional memory application, a cache line metadata transaction-write bit is set and a conditional store is performed. At commit time, if any lines marked with the transaction-read bit or the transaction-write bit were evicted or invalidated, all speculatively written lines are discarded. The application can also interrogate a cache line metadata eviction summary to determine whether a transaction is doomed and then take an appropriate action.