In recent years, he has taken an interest in formal methods, formal proofs and certified compilation.
He is the leader of the CompCert project that develops an optimizing compiler for C (programming language), formally verified in Coq.
Leroy was also the original author of LinuxThreads, the most widely used threading package for Linux versions prior to 2.6.
Linux 2.6 introduced NPTL, with much more extensive support from the kernel, to replace LinuxThreads.
In 2015 he was named a fellow of the Association for Computing Machinery "for contributions to safe, high-performance functional programming languages and compilers, and to compiler verification." He was awarded the 2016 Milner Award by the Royal Society