Deferred Object Destruction for Memory Reclamation

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current methods for object destruction in computer systems are error-prone and inefficient, leading to memory leaks, resource wastage, and unpredictable performance due to manual reference management and overheads associated with reference counting and garbage collection.

Innovation Solution

Implementing a deferred destruction approach that differentiates between transient and persistent references, using restart-based reclamation and destruct lists to manage memory, where objects with no persistent references are destroyed at reclamation points, and leveraging process restart mechanisms to efficiently reclaim memory.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Extent of automation

If reference counting is used to automatically manage object destruction, then memory reclamation is automated, but significant overhead is incurred due to atomic operations and hardware fence instructions

Engineering Contradiction:
Improveautomatic memory reclamationVSAvoidoverhead of reference counting operations
Core Design Contradiction:
Extent of automationVSUse of energy by moving object

Solution Approach 1:

The patent segments reference management into two types: weak references that do not prevent destruction and strong references that do. This segmentation allows the system to automate memory reclamation for objects with only weak references without incurring reference counting overhead, while strong references use a simpler reference tracking mechanism that avoids expensive atomic operations.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent applies different reference management strategies to different objects based on their local characteristics. Objects are marked with destructor flags indicating whether they require destruction, allowing the system to apply reference counting only where necessary while using simpler mechanisms elsewhere, thereby reducing overall overhead.

Inventive Principle:
Principle #3Local quality

2Productivity

If manual destruction is used to precisely control object lifecycle, then resource usage is optimized, but errors occur due to programmer mistakes in timing destruction calls

Engineering Contradiction:
Improveresource usage efficiencyVSAvoiderror-prone manual management
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The patent implements self-service destruction through destructor flags and weak reference mechanisms. Objects automatically determine their own destruction timing based on reference patterns, eliminating the need for programmer intervention while maintaining precise resource control. The system serves itself by monitoring reference counts and triggering destruction when appropriate without human error.

Inventive Principle:
Principle #25Self-service

Solution Approach 2:

The patent uses feedback mechanisms where the system continuously monitors reference patterns and destructor flags to determine when objects should be destroyed. This feedback loop allows automatic adjustment of destruction timing based on actual runtime behavior, optimizing resource usage while eliminating manual errors through systematic observation and response.

Inventive Principle:
Principle #23Feedback

3Extent of automation

If garbage collection is used to reclaim memory, then automatic reclamation is achieved, but unpredictable performance overhead occurs due to periodic scanning and potential memory compaction

Engineering Contradiction:
Improveautomatic memory reclamationVSAvoidunpredictable performance overhead
Core Design Contradiction:
Extent of automationVSProductivity

Solution Approach 1:

The patent implements periodic destruction checks at specific program points rather than continuous or garbage collection-based scanning. By performing destruction evaluations at predetermined locations in the code, the system achieves automatic reclamation with predictable performance characteristics, avoiding the unpredictable overhead of traditional garbage collection while maintaining automation.

Inventive Principle:
Principle #19Periodic action

4Adaptability or versatility

If circular reference structures are allowed, then object relationships are accurately represented, but memory leaks occur because reference counts never reach zero

Engineering Contradiction:
Improveobject relationship modelingVSAvoidmemory leaks from cyclic references
Core Design Contradiction:
Adaptability or versatilityVSLoss of substance

Solution Approach 1:

The patent extracts the destruction decision logic from the reference counting mechanism by using destructor flags and weak references. This separation allows circular reference structures to be represented accurately while preventing memory leaks, as objects with only weak references in circular structures can be destroyed when their strong references are removed, breaking the cycle without affecting the ability to model complex object relationships.

Inventive Principle:
Principle #2Taking out (Extraction)

Data Source

PatentUS11232026B2Deferred destruction for efficient resource reclamation
Publication Date: 2022.01.25 OPTUMSOFT INC
  • US11232026B2 patent drawing
  • US11232026B2 patent drawing
  • US11232026B2 patent drawing

AI summary

Memory reclamation includes executing a process that has a plurality of objects, the objects being accessible via a plurality of references, at least some of the plurality of references being transient references, at least some of the plurality of references being persistent references; reaching a reclamation point at which a process state has no transient references, or has transient references only at known locations; and at the reclamation point, destructing objects that have no persistent references and no transient references.