MENU

Fun & Interesting

Making OCaml Safe for Performance Engineering

Jane Street 5,704 lượt xem 3 days ago
Video Not Working? Fix It Now

Jane Street is a trading firm that uses a variety of high-performance systems built in OCaml to provide liquidity to financial markets worldwide. Over the last couple of years, we have started developing major extensions to OCaml’s type system, with the primary goal of making OCaml a better language for writing high-performance systems. In this talk, we will attempt to provide a developer's-eye view of these changes. We’ll cover two major directions of innovation: first, the addition of modal types to OCaml, which opens up a variety of ambitious features, like memory-safe stack-allocation; type-level tracking of effects, and data-race freedom guarantees for multicore code. The second is the addition of a kind system to OCaml, which provides more control over the representation of memory, in particular allowing for structured data to be represented in a cache-and-prefetch-friendly tabular form. Together, these features pull together some of the most important features for writing high performance code in Rust, while maintaining the relative simplicity of programming in OCaml. In all of this, we will focus less on the type theory, and more on how these features are surfaced to users, the practical problems that they help us solve, and the place in the design space of programming languages that this leaves us in.

Comment