Subgraph Pattern Matching via Bitmap Label Encoding

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing subgraph pattern matching techniques in graph databases are inefficient due to lack of optimal memory usage and high cache thrashing, leading to suboptimal throughput in finding matching subgraphs within large-scale graphs.

Innovation Solution

The proposed solution involves selecting a matching order for query vertices, prioritizing edge label matching before neighbor vertex labels, using bitmap encoding for labels, and employing dual label caches to maximize data locality and minimize random access during graph traversal, thereby optimizing cache performance and reducing memory footprints.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If traditional graph traversal methods are used for subgraph pattern matching, then the matching process can be completed, but cache thrashing occurs and throughput is suboptimal

Engineering Contradiction:
ImprovethroughputVSAvoidcache thrashing
Core Design Contradiction:
ProductivityVSLoss of energy

Solution Approach 1:

The patent applies preliminary action by pre-ordering query vertices based on their label selectivity and pre-encoding labels as bitmaps before traversal begins. This preparation work is done in advance to optimize the subsequent traversal process, reducing cache misses and improving throughput during actual pattern matching operations.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent changes parameters by representing vertex and edge labels as bitmaps instead of traditional string or integer representations. This parameter transformation enables efficient bitwise operations for label matching, reduces memory footprint, and improves cache utilization during graph traversal, directly addressing the cache thrashing problem.

Inventive Principle:
Principle #35Parameter changes

2Reliability

If comprehensive label matching is performed during graph traversal, then matching accuracy is maintained, but memory usage increases

Engineering Contradiction:
Improvematching accuracyVSAvoidmemory usage
Core Design Contradiction:
ReliabilityVSQuantity of substance

Solution Approach 1:

The patent transforms label data from traditional representations to bitmap representations, where each label is represented as a bit position in a compact integer. This parameter change maintains full matching accuracy through bitwise operations while dramatically reducing memory usage, as bitmaps require far less space than traditional label storage methods.

Inventive Principle:
Principle #35Parameter changes

Solution Approach 2:

The patent creates compact bitmap copies of label information that can be efficiently processed during traversal. Instead of storing and processing full label strings or complex data structures, the system uses lightweight bitmap copies that preserve matching semantics while occupying minimal memory, thus maintaining accuracy with reduced memory footprint.

Inventive Principle:
Principle #26Copying

Data Source

PatentUS10896223B2Efficient method for subgraph pattern matching
Publication Date: 2021.01.19 ORACLE INT CORP
  • US10896223B2 patent drawing
  • US10896223B2 patent drawing
  • US10896223B2 patent drawing

AI summary

Techniques herein optimize subgraph pattern matching. A computer receives a graph vertex array and a graph edge array. Each vertex and each edge has labels. The computer stores an array of index entries and an array of edge label sets. Each index entry corresponds to a respective vertex originating an edge and associates an offset of the edge with an offset of the respective vertex. Each edge label set contains labels of a respective edge. The computer selects a candidate subset of edges originating at a current vertex. The edge labels of each candidate edge of the candidate subset include a same particular query edge labels. The computer selects the candidate subset based on the index array and afterwards selects a result subset of vertices from among the terminating vertices of the candidate edges. The labels of each vertex of the result subset include a same particular query vertex labels.