TLB-Based Cache Line Compression and Encryption

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing memory management protocols in processing systems are suboptimal, as they allow data unlikely to be accessed soon to remain in local caches, leading to inefficiencies in data access latency and energy consumption, and encryption of main memory data without considering access patterns can degrade performance.

Innovation Solution

Implementing a cache replacement policy based on evictions from the translation lookaside buffer (TLB), where cache lines corresponding to evicted TLB entries are identified and either compressed or encrypted, optimizing cache and memory usage by moving less frequently accessed data to more remote levels of the memory hierarchy.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Speed

If data is stored in local caches to improve access speed, then processing efficiency is improved, but data access latency and energy consumption increase when data is not frequently accessed

Engineering Contradiction:
Improvedata access speedVSAvoidenergy consumption
Core Design Contradiction:
SpeedVSUse of energy by moving object

Solution Approach 1:

The system dynamically changes the state of cache lines by compressing them when they are determined to be cold (not frequently accessed). This parameter change from uncompressed to compressed state reduces the effective size of infrequently accessed data in the cache, allowing the cache to store more frequently accessed data or reduce its footprint for cold data, thereby reducing energy consumption while maintaining fast access for hot data.

Inventive Principle:
Principle #35Parameter changes

2Productivity

If memory management protocols move recently accessed data closer to the processor, then processing efficiency is improved, but data that is unlikely to be accessed remains in caches, wasting cache space

Engineering Contradiction:
Improveprocessing efficiencyVSAvoidcache space utilization
Core Design Contradiction:
ProductivityVSQuantity of substance

Solution Approach 1:

The system changes the size parameter of cache lines by compressing cold data. When a TLB entry is evicted, the corresponding cache line is identified and compressed, reducing its effective occupation of cache space. This allows the cache to accommodate more useful data while maintaining the same physical cache size, improving overall cache space utilization.

Inventive Principle:
Principle #35Parameter changes

Solution Approach 2:

The system uses TLB eviction events as a signal to automatically identify and compress corresponding cache lines. The cache compression mechanism serves itself by leveraging existing TLB management events rather than requiring separate analysis of cache access patterns, making the system self-optimizing without additional overhead.

Inventive Principle:
Principle #25Self-service

3Reliability

If encryption is applied to main memory data to enhance security, then data security is improved, but performance degrades due to additional processing overhead

Engineering Contradiction:
Improvedata securityVSAvoidprocessing performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The system applies encryption selectively rather than uniformly to all data. Only cache lines corresponding to evicted TLB entries (cold data) are encrypted, while hot data that remains in the cache and is frequently accessed continues to be accessed without encryption overhead. This local application of encryption maintains security for data at rest while preserving performance for actively used data.

Inventive Principle:
Principle #3Local quality

Solution Approach 2:

The system performs encryption in advance when data is evicted from the TLB and identified as cold, before it is written back to main memory. This preliminary encryption ensures security is maintained without requiring decryption/encryption operations during active processing, thus avoiding performance degradation during normal operations.

Inventive Principle:
Principle #10Preliminary action

4Quantity of substance

If compression is applied to cold cache lines to improve cache capacity, then effective cache capacity is improved, but additional processing overhead is introduced

Engineering Contradiction:
Improveeffective cache capacityVSAvoidprocessing overhead
Core Design Contradiction:
Quantity of substanceVSDevice complexity

Solution Approach 1:

The compression mechanism leverages existing TLB eviction events to automatically identify cold cache lines that need compression. Rather than requiring a separate analysis system to determine which data is cold, the system uses the TLB's own eviction signals, making the compression process self-identifying and reducing the overhead of determining compression candidates.

Inventive Principle:
Principle #25Self-service

Data Source

PatentUS11507519B2Data compression and encryption based on translation lookaside buffer evictions
Publication Date: 2022.11.22 ADVANCED MICRO DEVICES INC
  • US11507519B2 patent drawing
  • US11507519B2 patent drawing
  • US11507519B2 patent drawing

AI summary

A processing system selectively compresses cache lines at a cache or at a memory or encrypts cache lines at the memory based on evictions of entries mapping virtual-to-physical address translations from a translation lookaside buffer (TLB). Upon eviction of a TLB entry, the processing system identifies cache lines corresponding to the physical addresses of the evicted TLB entry and selectively compresses the cache lines to increase the effective storage capacity of the processing system or encrypts the cache lines to protect against vulnerabilities.