Closing the Performance Gap Between Lisp and C

Heisig M, Köstler H (2022)

Publication Language: English

Publication Type: Conference contribution, Original article

Publication year: 2022

Series: European Lisp Symposium

Conference Proceedings Title: Proceedings of The 15th European Lisp Symposium

Event location: Porto PT

DOI: 10.5281/zenodo.6335627

Open Access Link:


Lisp is the second oldest programming language, and the first one to value productivity more than raw execution speed.  This initial disregard for performance has indeed led to some mind-bogglingly slow implementations, especially in the early days, but modern Lisp compilers such as SBCL have almost fully closed the performance gap to the fastest imperative programming languages.  Almost, but not quite:  Until now, many loop optimizations and support for single instruction, multiple data (SIMD) programming are still missing in Lisp.

We correct this deficiency with two libraries: The first one is sb-simd, an SBCL-specific library that provides convenient bindings for various SIMD instructions sets.  The second one is Loopus, a portable loop optimization framework that works via macros and source to source transformations.  The most prominent features of Loopus are its optimization of array accesses and that, on SBCL, it automatically applies SIMD vectorization to certain loops.

We conclude with a performance evaluation for several example programs, and show that Lisp code using our libraries can achieve up to 94% of the performance of highly optimized C code.

Authors with CRIS profile

How to cite


Heisig, M., & Köstler, H. (2022). Closing the Performance Gap Between Lisp and C. In Proceedings of The 15th European Lisp Symposium. Porto, PT.


Heisig, Marco, and Harald Köstler. "Closing the Performance Gap Between Lisp and C." Proceedings of the The 15th European Lisp Symposium, Porto 2022.

BibTeX: Download