Sebastian Ullrich
Current Organizations / Institutes
The organizations/institutes from the scholar's latest article
Sebastian Ullrich has a total of 7 co-authors. Here are the top co-authors by number of shared publications:
- Leonardo de Moura
Microsoft Research USA
4 shared publications Leonardo de Moura
Microsoft Research
2 shared publicationsDenis Lohner
KIT, Germany
1 shared publicationGabriel Ebner
Vienna University of Technology, Austria
1 shared publicationJared Roesch
University of Washington, USA
1 shared publicationJeremy Avigad
Carnegie Mellon University, USA
1 shared publication
Latest Publications
- Open Access
- 29 August 2022
- Published by Association for Computing Machinery (ACM) in Proceedings of the ACM on Programming Languages
- Vol. 6 (ICFP) , 512-539
‘do’ unchained: embracing local imperativity in a purely functional language (functional pearl)
Purely functional programming languages pride themselves with reifying effects that are implicit in imperative languages into reusable and composable abstractions such as monads. This reification allows for more exact control over effects as well as the introduction of new or derived effects. However, despite libraries of more and more powerful abstractions over effectful operations being developed, syntactically the common 'do' notation still lags behind equivalent imperative code it is supposed to mimic regarding verbosity and code duplication. In this paper, we explore extending 'do' notation with other imperative language features that can be added to simplify monadic code: local mutation, early return, and iteration. We present formal translation rules that compile these features back down to purely functional code, show that the generated code can still be reasoned over using an implementation of the translation in the Lean 4 theorem prover, and formally prove the correctness of the translation rules relative to a simple static and dynamic semantics in Lean.
- 29 August 2022
- Published by Association for Computing Machinery (ACM) in Proceedings of the ACM on Programming Languages
- Vol. 6 (ICFP) , 512-539
Open Access‘do’ unchained: embracing local imperativity in a purely functional language (functional pearl)
Purely functional programming languages pride themselves with reifying effects that are implicit in imperative languages into reusable and composable abstractions such as monads. This reification allows for more exact control over effects as well as the introduction of new or derived effects. However, despite libraries of more and more powerful abstractions over effectful operations being developed, syntactically the common 'do' notation still lags behind equivalent imperative code it is supposed to mimic regarding verbosity and code duplication. In this paper, we explore extending 'do' notation with other imperative language features that can be added to simplify monadic code: local mutation, early return, and iteration. We present formal translation rules that compile these features back down to purely functional code, show that the generated code can still be reasoned over using an implementation of the translation in the Lean 4 theorem prover, and formally prove the correctness of the translation rules relative to a simple static and dynamic semantics in Lean.
- Top Cited PapersOpen Access
- 5 July 2021
- Published by Springer Nature
- p. 625-635
The Lean 4 Theorem Prover and Programming Language
Lean 4 is a reimplementation of the Lean interactive theorem prover (ITP) in Lean itself. It addresses many shortcomings of the previous versions and contains many new features. Lean 4 is fully extensible: users can modify and extend the parser, elaborator, tactics, decision procedures, pretty printer, and code generator. The new system has a hygienic macro system custom-built for ITPs. It contains a new typeclass resolution procedure based on tabled resolution, addressing significant performance problems reported by the growing user base. Lean 4 is also an efficient functional programming language based on a novel programming paradigm calledfunctional but in-place. Efficient code generation is crucial for Lean users because many write custom proof automation procedures in Lean itself.
- 5 July 2021
- Published by Springer Nature
- p. 625-635
Top Cited PapersOpen AccessThe Lean 4 Theorem Prover and Programming Language
Lean 4 is a reimplementation of the Lean interactive theorem prover (ITP) in Lean itself. It addresses many shortcomings of the previous versions and contains many new features. Lean 4 is fully extensible: users can modify and extend the parser, elaborator, tactics, decision procedures, pretty printer, and code generator. The new system has a hygienic macro system custom-built for ITPs. It contains a new typeclass resolution procedure based on tabled resolution, addressing significant performance problems reported by the growing user base. Lean 4 is also an efficient functional programming language based on a novel programming paradigm calledfunctional but in-place. Efficient code generation is crucial for Lean users because many write custom proof automation procedures in Lean itself.
- 24 June 2020
- Published by Springer Nature
- p. 167-182
Beyond Notations: Hygienic Macro Expansion for Theorem Proving Languages
- 24 June 2020
- Published by Springer Nature
- p. 167-182
Beyond Notations: Hygienic Macro Expansion for Theorem Proving Languages
- 6 June 2020
- Vol. 12167, 167-182
Beyond Notations: Hygienic Macro Expansion for Theorem Proving Languages
The online version of this chapter (10.1007/978-3-030-51054-1_10) contains supplementary material, which is available to authorized users.
- 6 June 2020
- Vol. 12167, 167-182
Beyond Notations: Hygienic Macro Expansion for Theorem Proving Languages
The online version of this chapter (10.1007/978-3-030-51054-1_10) contains supplementary material, which is available to authorized users.
- Open Access
Counting Immutable Beans: Reference Counting Optimized for Purely Functional Programming
Most functional languages rely on some garbage collection for automatic memory management. They usually eschew reference counting in favor of a tracing garbage collector, which has less bookkeeping overhead at runtime. On the other hand, having an exact reference count of each value can enable optimizations, such as destructive updates. We explore these optimization opportunities in the context of an eager, purely functional programming language. We propose a new mechanism for efficiently reclaiming memory used by nonshared values, reducing stress on the global memory allocator. We describe an approach for minimizing the number of reference counts updates using borrowed references and a heuristic for automatically inferring borrow annotations. We implemented all these techniques in a new compiler for an eager and purely functional programming language with support for multi-threading. Our preliminary experimental results demonstrate our approach is competitive and often outperforms state-of-the-art compilers.
Open AccessCounting Immutable Beans: Reference Counting Optimized for Purely Functional Programming
Most functional languages rely on some garbage collection for automatic memory management. They usually eschew reference counting in favor of a tracing garbage collector, which has less bookkeeping overhead at runtime. On the other hand, having an exact reference count of each value can enable optimizations, such as destructive updates. We explore these optimization opportunities in the context of an eager, purely functional programming language. We propose a new mechanism for efficiently reclaiming memory used by nonshared values, reducing stress on the global memory allocator. We describe an approach for minimizing the number of reference counts updates using borrowed references and a heuristic for automatically inferring borrow annotations. We implemented all these techniques in a new compiler for an eager and purely functional programming language with support for multi-threading. Our preliminary experimental results demonstrate our approach is competitive and often outperforms state-of-the-art compilers.
- Open Access
- 29 August 2017
- Published by Association for Computing Machinery (ACM) in Proceedings of the ACM on Programming Languages
- Vol. 1 (ICFP) , 1-29
A metaprogramming framework for formal verification
We describe the metaprogramming framework currently used in Lean, an interactive theorem prover based on dependent type theory. This framework extends Lean's object language with an API to some of Lean's internal structures and procedures, and provides ways of reflecting object-level expressions into the metalanguage. We provide evidence to show that our implementation is performant, and that it provides a convenient and flexible way of writing not only small-scale interactive tactics, but also more substantial kinds of automation.
- 29 August 2017
- Published by Association for Computing Machinery (ACM) in Proceedings of the ACM on Programming Languages
- Vol. 1 (ICFP) , 1-29
Open AccessA metaprogramming framework for formal verification
We describe the metaprogramming framework currently used in Lean, an interactive theorem prover based on dependent type theory. This framework extends Lean's object language with an API to some of Lean's internal structures and procedures, and provides ways of reflecting object-level expressions into the metalanguage. We provide evidence to show that our implementation is performant, and that it provides a convenient and flexible way of writing not only small-scale interactive tactics, but also more substantial kinds of automation.
- Open Access
- 17 March 2016
- Published by Association for Computing Machinery (ACM)
- p. 67-76
Verified construction of static single assignment form
Modern compilers use intermediate representations in static single assignment (SSA) form, which simplifies many optimizations. However, the high implementation complexity of efficient SSA construction algorithms poses a challenge to verified compilers. In this paper, we consider a variant of the recent SSA construction algorithm by Braun et al. that combines simplicity and efficiency, and is therefore a promising candidate to tackle this challenge. We prove the correctness of the algorithm using the theorem prover Isabelle/HOL. Furthermore, we prove that the algorithm constructs pruned SSA form and, in case of a reducible control flow graph, minimal SSA form. To the best of our knowledge, these are the first formal proofs regarding the quality of an SSA construction algorithm. Finally, we replace the SSA construction of the CompCertSSA project with code extracted by Isabelle's code generator to demonstrate the applicability to real world programs.
- 17 March 2016
- Published by Association for Computing Machinery (ACM)
- p. 67-76
Open AccessVerified construction of static single assignment form
Modern compilers use intermediate representations in static single assignment (SSA) form, which simplifies many optimizations. However, the high implementation complexity of efficient SSA construction algorithms poses a challenge to verified compilers. In this paper, we consider a variant of the recent SSA construction algorithm by Braun et al. that combines simplicity and efficiency, and is therefore a promising candidate to tackle this challenge. We prove the correctness of the algorithm using the theorem prover Isabelle/HOL. Furthermore, we prove that the algorithm constructs pruned SSA form and, in case of a reducible control flow graph, minimal SSA form. To the best of our knowledge, these are the first formal proofs regarding the quality of an SSA construction algorithm. Finally, we replace the SSA construction of the CompCertSSA project with code extracted by Isabelle's code generator to demonstrate the applicability to real world programs.