vix.ing · top · new · best · stats · spec

Type Stability in Julia: Avoiding Performance Pathologies in JIT Compilation (Extended Version)

2021/09/04 by Artem Pelenitsyn, Julia Belyakova, Benjamin Chung +3 · 1 voice
Computer Science · Mathematics · #Advanced Data Storage Technologies #Coding (social sciences) #Compiler #Computer science #Function (biology) #Functional programming #Machine learning #Mathematics #Parallel Computing and Optimization Techniques #Programming language #Property (philosophy) #Software Engineering Research #Stability (learning theory) #Theoretical computer science #Type (biology) #cs.PL

paper · pdf · doi:10.1145/3485527

OOPSLA '21, extended version

openalex publication_date 2021/10/15 · openalex created_date 2021/10/25 · arxiv created 2021/11/17 · arxiv updated 2021/11/18 · openalex updated_date 2026/08/04

Abstract

As a scientific programming language, Julia strives for performance but also provides high-level productivity features. To avoid performance pathologies, Julia users are expected to adhere to a coding discipline that enables so-called type stability. Informally, a function is type stable if the type of the output depends only on the types of the inputs, not their values. This paper provides a formal definition of type stability as well as a stronger property of type groundedness, shows that groundedness enables compiler optimizations, and proves the compiler correct. We also perform a corpus analysis to uncover how these type-related properties manifest in practice.

Discussions

Related