Buffer Reclamation via Pointer Swap and Reference Tracking

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current methods for reclaiming resident buffers in computer memory are inefficient, causing CPU spikes and improper timing in buffer reclamation, leading to unnecessary resource usage and high CPU consumption.

Innovation Solution

A method that allocates a new buffer when the pool falls below a threshold, marks the oldest in-use buffer for reclamation, and swaps it with the new buffer only when all messages referencing it are queued or freed, updating read and write pointers to the new buffer, thereby avoiding timer reliance and CPU-intensive searches.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Extent of automation

If timers are used to trigger buffer reclamation, then buffer reclamation is automated, but CPU resources are consumed excessively and reclamation timing is imprecise

Engineering Contradiction:
Improvebuffer reclamation automationVSAvoidCPU resource consumption
Core Design Contradiction:
Extent of automationVSUse of energy by moving object

Solution Approach 1:

The buffer pool manager automatically tracks buffer usage through reference counts and queued message counters without requiring external timer interventions. The system self-determines when buffers can be reclaimed based on actual usage state, eliminating the need for CPU-intensive timer operations while maintaining automated reclamation functionality.

Inventive Principle:
Principle #25Self-service

Solution Approach 2:

The patent replaces the mechanical timer-based reclamation mechanism with a state-tracking mechanism using reference counts and queued message counters. This substitution eliminates the need for periodic timer interrupts and CPU scheduling, reducing CPU resource consumption while providing more precise reclamation timing based on actual buffer usage state.

Inventive Principle:
Principle #28Mechanics substitution (Replace mechanical system)

2Reliability

If linear search through all connection endpoints is performed to reclaim buffers, then buffer reclamation is triggered by actual shortage, but CPU spikes occur and processing becomes extremely intensive

Engineering Contradiction:
Improvebuffer reclamation timing accuracyVSAvoidCPU processing efficiency
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The buffer pool manager preliminarily tracks the state of all buffers through reference counts and queued message counters at the time of allocation. This preliminary tracking eliminates the need for subsequent linear searches through connection endpoints, allowing immediate determination of reclaimable buffers when shortage occurs without intensive CPU processing.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The system dynamically updates buffer state information (reference counts, queued message counters) as buffers are allocated and freed. This dynamic tracking mechanism provides real-time awareness of buffer usage without requiring periodic searches, enabling efficient reclamation decisions that respond immediately to actual buffer shortages without causing CPU spikes.

Inventive Principle:
Principle #15Dynamics

3Productivity

If buffers are reclaimed too soon based on timer expiration, then CPU resources are freed, but buffers are reclaimed before actually needed

Engineering Contradiction:
Improvebuffer pool availabilityVSAvoidbuffer reclamation timing accuracy
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The buffer pool manager continuously monitors actual buffer usage through reference counts and queued message counters, providing feedback on whether buffers are truly available for reclamation. This feedback mechanism prevents premature reclamation by verifying that all messages referencing a buffer are indeed queued or freed before allowing reclamation, ensuring timing accuracy while maintaining buffer pool availability.

Inventive Principle:
Principle #23Feedback

4Reliability

If buffers are reclaimed too late waiting for timer expiration, then buffer shortage is avoided, but CPU resources remain tied up unnecessarily

Engineering Contradiction:
Improvebuffer availability stabilityVSAvoidCPU resource occupation time
Core Design Contradiction:
ReliabilityVSUse of energy by moving object

Solution Approach 1:

The buffer pool manager self-determines when buffers can be safely reclaimed by monitoring reference counts and queued message counters, eliminating the need for timer-based delays. This self-service approach allows immediate reclamation when buffers are actually available, preventing unnecessary CPU resource occupation while maintaining stable buffer availability.

Inventive Principle:
Principle #25Self-service

Data Source

PatentUS7720802B2Reclaiming resident buffers when a reclaim threshold has been exceeded by swapping the oldest in use buffer and a new buffer, and referencing the new buffer via an updated set of read and write pointers
Publication Date: 2010.05.18 X CORP
  • US7720802B2 patent drawing
  • US7720802B2 patent drawing
  • US7720802B2 patent drawing

AI summary

Systems methods and computer products for reclaiming resident buffers on demand. Exemplary embodiments include systems and methods for reclaiming resident buffers, including allocating a buffer, determining that the buffer allocation pushes the buffer pool below a reclaim threshold, marking an oldest in-use buffer to be reclaimed, determining that all messages referencing the buffer have been queued, allocating a new buffer and performing a swap of the oldest in-use buffer and the new buffer, performing a free message block operation and updating a message block by updating a set of read and write pointers to point to the new buffer.