Compiling a Higher-Order Smart Contract Language to LLVM
Vaivaswatha Nagaraj, Jacob Johannsen, Anton Trunov, George P\^irlea,, Amrit Kumar, Ilya Sergey

TL;DR
This paper presents a compiler from the higher-order smart contract language Scilla to LLVM-IR, significantly improving execution speed and enabling efficient blockchain transaction processing.
Contribution
It introduces a novel LLVM-based compiler for Scilla, mapping complex language constructs to LLVM-IR, and demonstrates substantial performance gains over interpretation.
Findings
Achieved about 10x speedup over reference interpreter.
Realized over 45x speedup on Ackermann function.
Enhanced smart contract execution efficiency in blockchain environments.
Abstract
Scilla is a higher-order polymorphic typed intermediate level language for implementing smart contracts. In this talk, we describe a Scilla compiler targeting LLVM, with a focus on mapping Scilla types, values, and its functional language constructs to LLVM-IR. The compiled LLVM-IR, when executed with LLVM's JIT framework, achieves a speedup of about 10x over the reference interpreter on a typical Scilla contract. This reduced latency is crucial in the setting of blockchains, where smart contracts are executed as parts of transactions, to achieve peak transactions processed per second. Experiments on the Ackermann function achieved a speedup of more than 45x. This talk abstract is aimed at both programming language researchers looking to implement an LLVM based compiler for their functional language, as well as at LLVM practitioners.
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsLogic, programming, and type systems · Security and Verification in Computing · Distributed systems and fault tolerance
