From Datalog to FLIX: A Declarative Language for Fixed Points on Lattices

被引:0
作者
Madsen, Magnus [1 ]
Yee, Ming-Ho [1 ]
Lhotak, Ondrej [1 ]
机构
[1] Univ Waterloo, Waterloo, ON N2L 3G1, Canada
基金
加拿大自然科学与工程研究理事会;
关键词
logic programming; static analysis; Datalog; Logic Programming; Static Analysis;
D O I
10.1145/2908080.2908096
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
We present FLIX, a declarative programming language for specifying and solving least fixed point problems, particularly static program analyses. FLIX is inspired by Datalog and extends it with lattices and monotone functions. Using FLIX, implementors of static analyses can express a broader range of analyses than is currently possible in pure Datalog, while retaining its familiar rule-based syntax. We define a model-theoretic semantics of FLIX as a natural extension of the Datalog semantics. This semantics captures the declarative meaning of FLIX programs without imposing any specific evaluation strategy. An efficient strategy is semi-naive evaluation which we adapt for FLIX. We have implemented a compiler and runtime for FLIX, and used it to express several well-known static analyses, including the IFDS and IDE algorithms. The declarative nature of FLIX clearly exposes the similarity between these two algorithms.
引用
收藏
页码:194 / 208
页数:15
相关论文
共 63 条
[1]  
[Anonymous], 1988, PRINCIPLES DATABASE
[2]  
[Anonymous], 1994, Program analysis and specialization for the C programming language
[3]  
[Anonymous], 1985, P 5 ACM SIGACT SIGMO, DOI [DOI 10.1145/6012.15399, 10.1145/6012.15399]
[4]  
Apt K. R., 1988, FDN DEDUCTIVE DATABA, P89, DOI [DOI 10.1016/B978-0-934613-40-8.50006-3, 10.1016/B978-0-934613-40-8.50006-3]
[5]  
Benton W. C., 2007, P PRINC PRACT DECL P, DOI [10.1145/1273920.1273923, DOI 10.1145/1273920.1273923]
[6]  
Bjorner Nikolaj, 2013, P S SATAT AN SAS, DOI [10.1007/978-3-642-38856-9_8, DOI 10.1007/978-3-642-38856-9_8]
[7]   The DaCapo benchmarks: Java']Java benchmarking development and analysis [J].
Blackburn, Stephen M. ;
Garner, Robin ;
Hoffmann, Chris ;
Khan, Asjad M. ;
McKinley, Kathryn S. ;
Bentzur, Rotem ;
Diwan, Amer ;
Feinberg, Daniel ;
Frampton, Daniel ;
Guyer, Samuel Z. ;
Hirzel, Martin ;
Hosking, Antony ;
Jump, Maria ;
Lee, Han ;
Moss, J. Eliot B. ;
Phansalkar, Aashish ;
Stefanovic, Darko ;
VanDrunen, Thomas ;
von Dincklage, Daniel ;
Wiedermann, Ben .
ACM SIGPLAN NOTICES, 2006, 41 (10) :169-190
[8]  
Bravenboer Martin, 2009, P 24 ACM SIGPLAN C O, P243, DOI DOI 10.1145/1640089.1640108
[9]   Answer Set Programming at a Glance [J].
Brewka, Gerhard ;
Eiter, Thomas ;
Truszczynski, Miroslaw .
COMMUNICATIONS OF THE ACM, 2011, 54 (12) :92-103
[10]  
Ceri S., 1989, IEEE Transactions on Knowledge and Data Engineering, V1, P146, DOI 10.1109/69.43410