Garbage Collection Based on Resource Usage Metrics

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing garbage collection methods in computing systems are inefficient due to the promotion of large native objects to higher generations of the heap, leading to reduced heap space and potential application crashes, as they rely solely on managed object size for garbage collection decisions.

Innovation Solution

Implementing a system that determines whether to perform a full or ephemeral garbage collection based on both a total resource usage metric and a managed object metric, reducing the frequency of promoting managed objects out of generation 0 and maintaining more available heap space.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Device complexity

If garbage collection is initialized based solely on managed object size, then the garbage collection process is simple to implement, but large native objects are incorrectly promoted to higher generations reducing heap space

Engineering Contradiction:
Improvegarbage collection decision complexityVSAvoidheap space management reliability
Core Design Contradiction:
Device complexityVSReliability

Solution Approach 1:

The patent changes the parameter used for garbage collection decision from solely managed object size to a ratio metric that incorporates both managed object size and total resource usage. This parameter change allows the system to identify when native objects are disproportionately large compared to managed objects, preventing incorrect promotion decisions while maintaining reasonable implementation complexity.

Inventive Principle:
Principle #35Parameter changes

2Productivity

If ephemeral garbage collection is used to avoid pausing applications, then application performance is maintained, but large native objects in generation 0 consume excessive heap space

Engineering Contradiction:
Improveapplication execution efficiencyVSAvoidavailable heap space
Core Design Contradiction:
ProductivityVSQuantity of substance

Solution Approach 1:

The patent introduces a feedback mechanism that monitors the ratio of total resource usage to managed object size. When this ratio indicates that native objects are consuming excessive space relative to managed objects, the system triggers a full garbage collection to reclaim space, while otherwise maintaining ephemeral collection to preserve application performance.

Inventive Principle:
Principle #23Feedback

3Quantity of substance

If full garbage collection is performed frequently to reclaim heap space, then available heap space is maintained, but application performance degrades due to frequent pauses

Engineering Contradiction:
Improveavailable heap spaceVSAvoidapplication execution efficiency
Core Design Contradiction:
Quantity of substanceVSProductivity

Solution Approach 1:

The patent applies partial action by using ephemeral garbage collection for routine space management, which collects only generation 0 objects without pausing applications. Full garbage collection is reserved for situations where the ratio metric indicates genuine space pressure from native objects, avoiding unnecessary full collections that would degrade performance.

Inventive Principle:
Principle #16Partial or excessive action

Data Source

PatentUS10095615B2Garbage collection based on total resource usage and managed object metrics
Publication Date: 2018.10.09 MICROSOFT TECHNOLOGY LICENSING LLC
  • US10095615B2 patent drawing
  • US10095615B2 patent drawing
  • US10095615B2 patent drawing

AI summary

A method includes selectively controlling, at a computing device having a memory, initiation of a full garbage collection operation based on a total resource usage metric and a managed object metric. The managed object metric is based on objects managed by a runtime application.