Zero-Copy Caching With Immutable Buffers

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Managed operating systems face performance overhead due to the need to copy data between isolation contexts, which hinders I/O performance and introduces security vulnerabilities, while unmanaged languages offer fine control but at the cost of reliability and security.

Innovation Solution

Implementing immutable buffers that allow data to be shared across contexts without copying, using strong and weak references to manage buffer lifetime and access, enabling zero-copy I/O semantics and caching architectures.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If data is copied between isolation contexts in managed operating systems, then data integrity and security are improved, but I/O performance deteriorates due to copying overhead

Engineering Contradiction:
Improvedata integrityVSAvoidI/O performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent applies the copying principle in reverse by using immutable buffers that can be safely shared across isolation contexts without copying. The immutability guarantee allows the same buffer instance to be accessed by multiple computing entities simultaneously, eliminating the performance penalty of data copying while maintaining security through the immutable nature of the buffer

Inventive Principle:
Principle #26Copying

2Productivity

If unchecked pointers are used in unmanaged languages, then I/O throughput and latency are improved, but software reliability and security deteriorate

Engineering Contradiction:
ImproveI/O throughputVSAvoidsoftware reliability
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The patent changes the parameter of buffer mutability from mutable to immutable. This parameter change allows the system to use unchecked pointers safely because the immutability guarantee prevents any code from modifying the buffer contents, eliminating security vulnerabilities while maintaining the performance benefits of direct memory access

Inventive Principle:
Principle #35Parameter changes

3Reliability

If managed programming languages are used, then software correctness and development time are improved, but performance deteriorates due to abstraction layer overhead

Engineering Contradiction:
Improvesoftware correctnessVSAvoidsoftware performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent extracts the performance-critical data access operations from the managed abstraction layer by using immutable buffers that can be directly accessed by multiple computing entities. This extraction allows hot paths to bypass the overhead of managed language abstractions while the immutable buffer mechanism ensures safety, effectively separating correctness concerns from performance concerns

Inventive Principle:
Principle #2Taking out (Extraction)

Data Source

PatentEP2941704B1Zero-copy caching
Publication Date: 2019.05.15 MICROSOFT TECHNOLOGY LICENSING LLC
  • EP2941704B1 patent drawingFigure 1
  • EP2941704B1 patent drawingFigure 2
  • EP2941704B1 patent drawingFigure 3A~3B

AI summary

Caching of an immutable buffer that has its data and address prevented from changing during the lifetime of the immutable buffer. A first computing entity maintains a cache of the immutable buffer and has a strong reference to the immutable buffer. So long as any entity has a strong reference to the immutable buffer, the immutable buffer is guaranteed to continue to exist for the duration of the strong reference. A second computing entity communicates with the first computing entity to obtain a strong reference to the immutable buffer and thereafter read data from the immutable buffer. Upon reading the data from the cache, the second computing entity demotes the strong reference to a weak reference to the immutable buffer. A weak reference to the immutable buffer does not guarantee that the immutable buffer will continue to exist for the duration of the weak reference.