Cache Line Duplication for Way Prediction Conflicts

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

In set-associative caches, way prediction conflicts occur due to patterns like A-B-A-B, leading to repeated mispredictions, increased delay, and power consumption as the cache controller checks both ways for each cache line access.

Innovation Solution

A system that uses a conflict detection table to track mispredictions and copies cache lines from the actual way to the mispredicted way when a predetermined number of mispredictions is reached, avoiding repeated mispredictions by updating the way prediction table accordingly.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Speed

If way prediction is used to speed up cache line accesses, then access speed is improved, but repeated mispredictions due to hash conflicts cause increased delay and power consumption

Engineering Contradiction:
Improvecache line access speedVSAvoiddelay due to misprediction
Core Design Contradiction:
SpeedVSLoss of time

Solution Approach 1:

The patent applies preliminary action by proactively detecting hash conflicts in the way prediction table and pre-copying cache lines before mispredictions occur. The system monitors for conflicting hash entries and performs cache line copying in advance, preventing the time loss that would otherwise occur during misprediction events.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent directly applies copying by duplicating cache lines from one way to another when hash conflicts are detected. This copying mechanism ensures that both cache lines associated with conflicting hashes are present in the predicted way, eliminating mispredictions and the associated time delays without requiring full cache line searches.

Inventive Principle:
Principle #26Copying

2Speed

If way prediction is used to speed up cache line accesses, then access speed is improved, but repeated mispredictions increase power consumption

Engineering Contradiction:
Improvecache line access speedVSAvoidpower consumption during cache access
Core Design Contradiction:
SpeedVSUse of energy by moving object

Solution Approach 1:

The system performs preliminary detection of hash conflicts and pre-copying of cache lines before access operations occur. By resolving potential mispredictions in advance, the system avoids the energy-consuming full cache line searches that would otherwise be required during misprediction events.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent uses copying to duplicate cache lines to the predicted way before accesses occur. This eliminates the need for energy-consuming searches across multiple ways during cache access operations, thereby reducing power consumption while maintaining fast access speeds.

Inventive Principle:
Principle #26Copying

3Measurement precision

If the way prediction table is updated for each misprediction, then prediction accuracy should improve, but conflicting access patterns cause continuous mispredictions

Engineering Contradiction:
Improveprediction accuracyVSAvoideffective cache access throughput
Core Design Contradiction:
Measurement precisionVSProductivity

Solution Approach 1:

The patent applies preliminary action by detecting hash conflicts and performing cache line copying before mispredictions occur. This prevents the productivity loss associated with continuous mispredictions while maintaining prediction accuracy, as the system proactively resolves conflicts rather than reactively updating after each misprediction.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent converts the harmful effect of hash conflicts into a benefit by using the conflict detection mechanism to trigger proactive cache line copying. What would otherwise be sources of continuous mispredictions and productivity loss become opportunities to pre-position cache lines, improving both prediction accuracy and effective throughput.

Inventive Principle:
Principle #22Blessing in disguise (Convert harm into benefit)

Data Source

PatentUS7979640B2Cache line duplication in response to a way prediction conflict
Publication Date: 2011.07.12 ORACLE AMERICAN INC
  • US7979640B2 patent drawing
  • US7979640B2 patent drawing
  • US7979640B2 patent drawing

AI summary

Embodiments of the present invention provide a system that handles way mispredictions in a multi-way cache. The system starts by receiving requests to access cache lines in the multi-way cache. For each request, the system makes a prediction of a way in which the cache line resides based on a corresponding entry in the way prediction table. The system then checks for the presence of the cache line in the predicted way. Upon determining that the cache line is not present in the predicted way, but is present in a different way, and hence the way was mispredicted, the system increments a corresponding record in a conflict detection table. Upon detecting that a record in the conflict detection table indicates that a number of mispredictions equals a predetermined value, the system copies the corresponding cache line from the way where the cache line actually resides into the predicted way.