Object-Granular Key IDs for Speculative Memory Safety

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Memory safety enforcement in computing systems imposes substantial overheads and code size increases due to metadata accesses and instrumentation, leading to performance costs, and existing approaches either rely on metadata checks that slow down operations or provide incomplete protection against memory safety violations.

Innovation Solution

A hybrid approach that combines memory tagging with cryptographic isolation, allowing speculative tag checks and data encryption to enforce memory safety without waiting for metadata, using object-granular key IDs to reduce metadata overheads and enable immediate detection of violations.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If memory tagging with metadata checks is used to enforce memory safety, then memory safety protection is improved, but performance overhead and code size increase

Engineering Contradiction:
Improvememory safety protectionVSAvoidperformance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent extracts the memory safety check from the critical data path by using speculative execution. The tag check is performed speculatively in parallel with normal execution, and only commits if the speculation is validated, removing the bottleneck from the main execution flow.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The patent performs preliminary tag validation speculatively before the actual memory access completes. By predicting the outcome of tag checks in advance and executing accordingly, the system prepares safety validation ahead of time without blocking subsequent operations.

Inventive Principle:
Principle #10Preliminary action

2Reliability

If metadata accesses are performed to check memory tags, then memory safety enforcement is improved, but access time and operational speed worsen

Engineering Contradiction:
Improvememory safety enforcementVSAvoidaccess time
Core Design Contradiction:
ReliabilityVSSpeed

Solution Approach 1:

The patent uses periodic speculative validation where tag checks are performed at specific prediction points in the execution flow rather than continuously. This periodic checking mechanism maintains safety while minimizing interruptions to the normal access rhythm.

Inventive Principle:
Principle #19Periodic action

Solution Approach 2:

The patent allows execution to skip ahead speculatively assuming tag validity, rushing through potential checkpoints without actual validation. Only when validation is needed does the system pause to perform the actual tag check, thus skipping unnecessary delays in the common case.

Inventive Principle:
Principle #21Skipping (Rushing through)

3Difficulty of detecting and measuring

If instrumentation is added to enforce memory safety, then detection capability is improved, but code complexity and size increase

Engineering Contradiction:
Improveviolation detection capabilityVSAvoidcode complexity
Core Design Contradiction:
Difficulty of detecting and measuringVSDevice complexity

Solution Approach 1:

The patent makes the processor itself perform the safety validation through built-in speculative execution mechanisms rather than requiring external instrumentation. The processor's existing prediction and validation infrastructure is repurposed for memory safety, eliminating the need for additional monitoring code.

Inventive Principle:
Principle #25Self-service

Solution Approach 2:

The patent makes the speculative execution infrastructure serve dual purposes: both its original function of optimizing performance through prediction and the new function of enforcing memory safety through tag validation. This multi-functionality reduces the need for separate instrumentation systems.

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

4Measurement precision

If waiting for metadata is required before memory access, then accuracy of safety check is improved, but execution latency increases

Engineering Contradiction:
Improvesafety check accuracyVSAvoidexecution latency
Core Design Contradiction:
Measurement precisionVSLoss of time

Solution Approach 1:

The patent performs preliminary speculative validation using predicted tag values before the actual metadata is available. This preliminary action provides provisional safety assurance that can be confirmed or corrected later, avoiding the need to wait for metadata completion.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent implements a feedback mechanism where speculative validation results are confirmed or corrected when actual metadata becomes available. This feedback loop maintains accuracy by validating predictions against real data while allowing execution to proceed without initial delays.

Inventive Principle:
Principle #23Feedback

Data Source

PatentUS12579078B2Speculating object-granular key identifiers for memory safety
Publication Date: 2026.03.17 INTEL CORP
  • US12579078B2 patent drawing
  • US12579078B2 patent drawing
  • US12579078B2 patent drawing

AI summary

A processor core requests a cacheline to be loaded from a memory in a memory access request; and a cache determines a speculated color value for the memory access request, receives a data granule of the cacheline from the memory, and decrypts data of the data granule using the speculated color value.