TL;DR
Sandslash is a "two-level" framework for Graph Pattern Mining (GPM) that bridges the gap between developer productivity and hardware performance. By providing both a high-level specification API and a low-level optimization API, it outperforms state-of-the-art systems by up to 13.8× and even beats hand-optimized, problem-specific code by 2.3× on average.
What Problem Does This Paper Address?
Graph Pattern Mining—finding structural motifs like cliques, triangles, or complex subgraphs—is essential for everything from bioinformatics to social network analysis. However, it is computationally brutal because the search space grows exponentially with the size of the pattern.
Existing GPM frameworks fall into two camps:
- High-level systems: Easy to use (you just describe the pattern), but they are often "black boxes" that can't be tuned for specific algorithmic shortcuts, leading to mediocre performance.
- Low-level systems: Offer great control but require researchers to write complex, error-prone code to manage parallelization and pruning.
Furthermore, many clever optimizations used in "hand-written" code for specific problems (like counting triangles) haven't been generalized into frameworks. Sandslash aims to provide a unified system that automates the "standard" optimizations while giving experts the "hooks" to inject custom, problem-specific logic.
Methods
Sandslash introduces a Two-Level API built on top of the Galois parallel system:
- High-Level API: The user simply provides a pattern specification (e.g., an edge list of a triangle). Sandslash then automatically applies a suite of sophisticated optimizations:
- Symmetry Breaking: Prevents over-counting the same subgraph found in different orders.
- DAG Orientation: Converts the graph into a Directed Acyclic Graph to prune the search space.
- Memoization of Neighborhood Connectivity (MNC): A novel technique using bit-vectors to cache whether vertices in a partial match are connected, avoiding redundant and expensive graph lookups.
- Low-Level API: For "power users," Sandslash provides hooks like
toExtend,toAdd, andlocalReduce. These allow for: - Local Counting: Mathematically deriving the count of one pattern from another (e.g., calculating "wedges" based on triangle counts and vertex degrees) to skip the need for full enumeration.
- Search on Local Graphs: Dynamically constructing smaller, induced subgraphs to speed up clique listing.
Datasets
The authors evaluated Sandslash using a diverse set of real-world graphs:
- Vertex-labeled (for Frequent Subgraph Mining): Patents (3M nodes), Youtube (7M nodes), and ProteinDB (49M nodes).
- Unlabeled (for Motifs/Cliques): LiveJournal, Orkut, Twitter40, and Friendster.
- The "Big One": Gsh-2015, a massive web crawl containing 988 million nodes and 51.3 billion edges, requiring 6TB of Intel Optane memory to process.
Key Insights and Ideas
- The Power of "Local" Knowledge: One of the biggest "aha" moments is Local Counting. Instead of searching for every possible 3-vertex "wedge," Sandslash can count triangles and then use a simple formula involving vertex degrees to calculate the wedges. This avoids massive amounts of unnecessary work.
- MNC vs. Buffering: While previous systems tried to buffer vertex sets to save time, Sandslash’s MNC (Memoization of Neighborhood Connectivity) uses a thread-private bit-vector map. This is much more memory-efficient and scales better for multi-pattern problems where different patterns require different vertex sets.
- Generalizing the "Expert" Secret Sauce: The authors analyzed various hand-tuned GPM applications and realized that most "expert" tricks (like Degree Filtering) could be generalized and automated within a framework, provided the framework was flexible enough to allow for fine-grained pruning.
Key Results
- Performance vs. Frameworks: Sandslash-Hi (high-level) and Sandslash-Lo (low-level) outperformed state-of-the-art systems AutoMine, Pangolin, and Peregrine by averages of 13.8×, 7.9×, and 5.4×, respectively.
- Performance vs. Hand-Tuned Code: Remarkably, Sandslash applications were 2.3× faster than expert-optimized, handwritten implementations for specific problems, despite requiring significantly less code.
- Scalability: Sandslash was the only system tested that could successfully handle the 51-billion-edge Gsh graph for 4-clique listing, completing the task in under an hour while others timed out or ran out of memory.
- Optimization Impact: The Local Counting (LC) optimization alone made motif counting up to 38× faster than the high-level baseline.
Limitations and Future Work
- Memory Overhead: While Sandslash is generally efficient, certain low-level optimizations like "Search on Local Graphs" (used for cliques) can consume massive amounts of memory (over 6TB for the largest graphs), which might limit its use on standard commodity hardware for the most extreme cases.
- Parallelism Constraints: For Frequent Subgraph Mining (FSM), the search is constrained by the structure of the "sub-pattern tree," which limits how much work can be done in parallel compared to simpler tasks like triangle counting.
- Future Directions: The authors suggest that adding "vertex reordering" (preprocessing the graph based on degree) and even finer-grained work-stealing could further squeeze performance out of the system.
Summary updated