Lune

POPL2024顶会

Flan: An Expressive and Efficient Datalog Compiler for Program Analysis

Supun Abeysinghe, Anxhelo Xhebraj, Tiark Rompf

摘要

Datalog has gained prominence in program analysis due to its expressiveness and ease of use. Its generic fixpoint resolution algorithm over relational domains simplifies the expression of many complex analyses. The performance and scalability issues of early Datalog approaches have been addressed by tools such as Soufflé through specialized code generation. Still, while pure Datalog is expressive enough to support a wide range of analyses, there is a growing need for extensions to accommodate increasingly complex analyses. This has led to the development of various extensions, such as Flix, Datafun, and Formulog, which enhance Datalog with features like arbitrary lattices and SMT constraints.

Most of these extensions recognize the need for full interoperability between Datalog and a full-fledged programming language, a functionality that high-performance systems like Soufflé lack. Specifically, in most cases, they construct languages from scratch with first-class Datalog support, allowing greater flexibility. However, this flexibility often comes at the cost of performance due to the conflicting requirements of prioritizing modularity and abstraction over efficiency. Consequently, achieving both flexibility and compilation to highly-performant specialized code poses a significant challenge.

In this work, we reconcile the competing demands of expressiveness and performance with Flan, a Datalog compiler fully embedded in Scala that leverages multi-stage programming to generate specialized code for enhanced performance. Our approach combines the flexibility of Flix with Soufflé's performance, offering seamless integration with the host language that enables the addition of powerful extensions while generating specialized code for the entire computation. Flan's simple operator interface allows the addition of an extensive set of features, including arbitrary aggregates, user-defined functions, and lattices, with multiple execution strategies such as binary and multi-way joins, supported by different indexing structures like specialized trees and hash tables, with minimal effort. We evaluate our system on a variety of benchmarks and compare it to established Datalog engines. Our results demonstrate competitive performance and speedups in the range of 1.4× to 12.5× compared to state-of-the-art systems for workloads of practical importance.

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

已有 3 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。

可以从这些问题问起

Lune 可以查阅

全文 · 引用它的顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • Free Join: Unifying Worst-Case Optimal and Traditional Joins 引用了 Adopting Worst-Case Optimal Joins in Relational Database Systems
  • Better Together: Unifying Datalog and Equality Saturation 引用了 Formulog: Datalog for SMT-based static analysis
  • Formulog: Datalog for SMT-based static analysis 引用了 Seminaïve evaluation for a higher-order functional language
  • FlowLog: Efficient and Extensible Datalog via Incrementality 引用了 Free Join: Unifying Worst-Case Optimal and Traditional Joins
  • FlowLog: Efficient and Extensible Datalog via Incrementality 引用了 Better Together: Unifying Datalog and Equality Saturation
  • FlowLog: Efficient and Extensible Datalog via Incrementality 引用了 Adopting Worst-Case Optimal Joins in Relational Database Systems
  • Making Formulog Fast: An Argument for Unconventional Datalog Evaluation 引用了 Seminaïve evaluation for a higher-order functional language
  • Making Formulog Fast: An Argument for Unconventional Datalog Evaluation 引用了 Formulog: Datalog for SMT-based static analysis
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper3

  1. IncIDFA: An Efficient and Generic Algorithm for Incremental Iterative Dataflow AnalysisAman Nougrahiya, V. Krishna NandivadaOOPSLA 2025 · 4 次引用
  2. Making Formulog Fast: An Argument for Unconventional Datalog EvaluationAaron Bembenek, Michael Greenberg, Stephen ChongOOPSLA 2024 · 3 次引用
  3. FlowLog: Efficient and Extensible Datalog via IncrementalityHangdong Zhao, Zhenghong Yu, Srinag Rao, Simon Frisk 等VLDB 2026

它引用的 Paper11

  1. Adopting Worst-Case Optimal Joins in Relational Database SystemsMichael J. Freitag, Maximilian Bandle, Tobias Schmidt, Alfons Kemper 等VLDB 2020 · 79 次引用
  2. Better Together: Unifying Datalog and Equality SaturationYihong Zhang, Yisu Remy Wang, Oliver Flatt, David Cao 等PLDI 2023 · 38 次引用
  3. Formulog: Datalog for SMT-based static analysisAaron Bembenek, Michael Greenberg, Stephen ChongOOPSLA 2020 · 26 次引用
  4. Free Join: Unifying Worst-Case Optimal and Traditional JoinsYisu Remy Wang, Max Willsey, Dan SuciuSIGMOD 2023 · 18 次引用
  5. Seminaïve evaluation for a higher-order functional languageMichael Arntzenius, Neel KrishnaswamiPOPL 2020 · 15 次引用

相关 Paper

  1. An efficient interpreter for Datalog by de-specializing relationsXiaowen Hu, David Zhao, Herbert Jordan, Bernhard ScholzPLDI 2021 · 6 次引用
  2. Universal Scalability in Declarative Program Analysis (with Choice-Based Combination Pruning)Anastasios Antoniadis, Ilias Tsatiris, Neville Grech, Yannis SmaragdakisOOPSLA 2025
  3. Fixpoints for the masses: programming with first-class Datalog constraintsMagnus Madsen, Ondrej LhotákOOPSLA 2020 · 22 次引用
  4. Bring Your Own Data Structures to DatalogArash Sahebolamri, Langston Barrett, Scott Moore, Kristopher K. MicinskiOOPSLA 2023 · 11 次引用
  5. Flix: A Design for Language-Integrated DatalogMagnus Madsen, Ondrej LhotákOOPSLA 2025
黄昏的海面,两侧是细线勾勒的悬崖