Dis/Equality Graphs
George Zakhour, Pascal Weisenburger, Jahrim Gabriele Cesario, Guido Salvaneschi
摘要
E-graphs are a data structure to compactly represent a program space and reason about equality of program terms. E-graphs have been successfully applied to a number of domains, including program optimization and automated theorem proving. In many applications, however, it is necessary to reason about disequality of terms as well as equality. While disequality reasoning can be encoded, direct support for disequalities increases performance and simplifies the metatheory.
In this paper, we develop a framework independent of a specific implementation to formally reason about e-graphs. For the first time, we prove the equivalence of e-graphs to the reflexive, symmetric, transitive, and congruent closure of the equivalence relation they are expected to encode. We use these results to present the first formalization of an extension of e-graphs that directly supports disequalities and prove an analytical result about their superior efficiency compared to embedding techniques that are commonly used in SMT solvers and automated verifiers. We further profile an SMT solver and find that it spends a measurable amount of time handling disequalities.
We implement our approach in an extension to egg, a popular e-graph Rust library. We evaluate our solution in an SMT solver and an automated theorem prover using standard benchmarks. The results indicate that direct support for disequalities outperforms other encodings based on equality embedding, confirming the results obtained analytically.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 4 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- babble: Learning Better Abstractions with E-Graphs and Anti-unification 引用了 Synthesizing structured CAD models with equality saturation and inverse transformations
- babble: Learning Better Abstractions with E-Graphs and Anti-unification 引用了 egg: Fast and extensible equality saturation
- babble: Learning Better Abstractions with E-Graphs and Anti-unification 引用了 Vectorization for digital signal processors via equality saturation
- Towards Pen-and-Paper-Style Equational Reasoning in Interactive Theorem Provers by Equality Saturation 引用了 Better Together: Unifying Datalog and Equality Saturation
- Towards Pen-and-Paper-Style Equational Reasoning in Interactive Theorem Provers by Equality Saturation 引用了 egg: Fast and extensible equality saturation
- Better Together: Unifying Datalog and Equality Saturation 引用了 Synthesizing structured CAD models with equality saturation and inverse transformations
- Better Together: Unifying Datalog and Equality Saturation 引用了 egg: Fast and extensible equality saturation
- Better Together: Unifying Datalog and Equality Saturation 引用了 Vectorization for digital signal processors via equality saturation
- Metamorphic Testing for Infrastructure-as-Code Engines 引用了 babble: Learning Better Abstractions with E-Graphs and Anti-unification
- Metamorphic Testing for Infrastructure-as-Code Engines 引用了 Synthesizing structured CAD models with equality saturation and inverse transformations
- Metamorphic Testing for Infrastructure-as-Code Engines 引用了 egg: Fast and extensible equality saturation
- egg: Fast and extensible equality saturation 引用了 Synthesizing structured CAD models with equality saturation and inverse transformations
- EUFⁿ: A Decidable Extension to the Theory of Equality with Uninterpreted Functions 引用了 egg: Fast and extensible equality saturation
- Vectorization for digital signal processors via equality saturation 引用了 Synthesizing structured CAD models with equality saturation and inverse transformations
- Versioned E-Graphs 引用了 babble: Learning Better Abstractions with E-Graphs and Anti-unification
- Versioned E-Graphs 引用了 Synthesizing structured CAD models with equality saturation and inverse transformations
- Versioned E-Graphs 引用了 egg: Fast and extensible equality saturation
- Versioned E-Graphs 引用了 Vectorization for digital signal processors via equality saturation
引用它的顶会 Paper4
- Towards Pen-and-Paper-Style Equational Reasoning in Interactive Theorem Provers by Equality SaturationMarcus Rossel, Rudi Schneider, Thomas Koehler, Michel Steuwer 等POPL 2026 · 2 次引用
- Metamorphic Testing for Infrastructure-as-Code EnginesDavid Spielmann, George Zakhour, Dominik Arnold, Matteo Biagiola 等OOPSLA 2026
- EUFⁿ: A Decidable Extension to the Theory of Equality with Uninterpreted FunctionsYide Du, Zhenbang Chen, Weijiang Hong, Wei DongOOPSLA 2026
- Versioned E-GraphsJahrim Gabriele Cesario, George Zakhour, Pascal Weisenburger, Guido SalvaneschiPLDI 2026
它引用的 Paper10
- egg: Fast and extensible equality saturationMax Willsey, Chandrakana Nandi, Yisu Remy Wang, Oliver Flatt 等POPL 2021 · 170 次引用
- Synthesizing structured CAD models with equality saturation and inverse transformationsChandrakana Nandi, Max Willsey, Adam Anderson, James R. Wilcox 等PLDI 2020 · 65 次引用
- Vectorization for digital signal processors via equality saturationAlexa VanHattum, Rachit Nigam, Vincent T. Lee, James Bornholt 等ASPLOS 2021 · 57 次引用
- babble: Learning Better Abstractions with E-Graphs and Anti-unificationDavid Cao, Rose Kunkel, Chandrakana Nandi, Max Willsey 等POPL 2023 · 38 次引用
- Better Together: Unifying Datalog and Equality SaturationYihong Zhang, Yisu Remy Wang, Oliver Flatt, David Cao 等PLDI 2023 · 38 次引用
相关 Paper
- Fast and Optimal Extraction for Sparse Equality GraphsAmir Kafshdar Goharshady, Chun Kit Lam, Lionel ParreauxOOPSLA 2024 · 11 次引用
- Slotted E-Graphs: First-Class Support for (Bound) Variables in E-GraphsRudi Schneider, Marcus Rossel, Amir Shaikhha, Andrés Goens 等PLDI 2025 · 1 次引用
- Improving Equality Saturation for EDA via Semantic E-GraphsSijie Kong, Jingtao Xia, Daniel Ruelas-Petrisko, Zachary D. Sisco 等PLDI 2026
- Equivalence Hypergraphs: DPO Rewriting for Monoidal E-GraphsAleksei Tiurin, Chris Barrett, Dan R. Ghica, Nick HuLICS 2025
- Relational e-matchingYihong Zhang, Yisu Remy Wang, Max Willsey, Zachary TatlockPOPL 2022 · 12 次引用
