Ring Buffer Cache Pressure Reduction via Augmented Entry Pointers

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current systems face performance bottlenecks and cache pressure issues when handling network traffic in ring buffers, particularly due to cache line bounces and inefficient use of resources, leading to slowed data copying and increased memory usage.

Innovation Solution

The implementation of an augmented entry pointer data structure that includes a list of extra entries allows additional packet information to be stored when the ring buffer is full, enabling the consumer processor to consume these entries without resizing the ring buffer, thereby reducing cache pressure and improving performance.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If the ring buffer is enlarged to accommodate more memory entries, then the productivity is improved, but the device complexity increases

Engineering Contradiction:
ImprovethroughputVSAvoidring buffer size
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent implements a nested structure where a primary ring buffer contains slots that can hold either direct memory entries or pointers to secondary entry structures. These secondary structures (extra entry lists) are nested within the primary ring buffer slots, allowing the system to accommodate variable amounts of data without increasing the fixed ring buffer size. This nested approach enables dynamic capacity adjustment without physical enlargement of the ring buffer.

Inventive Principle:
Principle #7Nested doll (Nesting)

Solution Approach 2:

The patent introduces dynamic entry structures where each ring buffer slot can adapt its content based on availability. When slots are available, entries are stored directly; when slots are full, pointers to extra entry lists are used. This dynamic behavior allows the system to flexibly handle varying traffic loads without requiring a statically large ring buffer, thus improving throughput without permanently increasing device complexity.

Inventive Principle:
Principle #15Dynamics

2Productivity

If the ring buffer is resized to handle increased network traffic, then the productivity is improved, but the loss of time increases

Engineering Contradiction:
ImprovethroughputVSAvoidresizing time
Core Design Contradiction:
ProductivityVSLoss of time

Solution Approach 1:

The patent pre-allocates extra entry structures and pointers within the ring buffer slots in advance, so that when traffic increases, the system can immediately utilize these pre-prepared structures without performing time-consuming resizing operations. The extra entry lists are prepared beforehand with appropriate data structures, allowing O(1) insertion and access operations even under high load conditions.

Inventive Principle:
Principle #10Preliminary action

3Productivity

If the ring buffer slots are fully utilized, then the productivity is improved, but the cache pressure increases

Engineering Contradiction:
ImprovethroughputVSAvoidcache pressure
Core Design Contradiction:
ProductivityVSStress or pressure

Solution Approach 1:

The patent segments the storage structure into multiple levels: primary ring buffer slots and secondary extra entry lists. This segmentation allows the system to distribute memory entries across different storage regions, reducing the concentration of active data in cache-sensitive areas. By separating frequently accessed ring buffer operations from less frequently accessed extra entries, the system reduces cache pressure while maintaining high throughput.

Inventive Principle:
Principle #1Segmentation

4Productivity

If additional packet information is stored in the ring buffer, then the productivity is improved, but the device complexity increases

Engineering Contradiction:
ImprovethroughputVSAvoiddata structure complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent creates a universal ring buffer slot structure that can serve multiple functions: storing direct memory entries when space is available, storing pointers to extra entry lists when slots are full, and maintaining backward compatibility with existing ring buffer operations. This multi-functional design allows additional packet information to be stored without requiring fundamentally different data structures, thus improving throughput while limiting the increase in device complexity.

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

Data Source

PatentUS10649686B2Memory cache pressure reduction for pointer rings
Publication Date: 2020.05.12 RED HAT INC
  • US10649686B2 patent drawing
  • US10649686B2 patent drawing
  • US10649686B2 patent drawing

AI summary

A system includes a memory with a ring buffer having a plurality of slots and a producer and consumer processor in communication with the memory. The producer processor is configured to receive a new memory entry and detect a failure to produce the new memory entry to a slot in the ring buffer. Each memory entry in the ring buffer has an entry structure to maintain a list of extra entries. The producer processor is also configured to determine a location of an entry pointer for a last produced memory entry in the ring and add the new entry to the list of extra entries in the respective slot in the ring. Responsive to consuming the last produced memory entry, the consumer processor is configured to check whether the last produced memory entry includes any other memory entries in the list of extra entries and consume the new memory entry.