Julia 1.12 released with experimental code trimming, improved multi-threading, and more
Julia 1.12 has been released, delivering several enhancements aimed at performance and developer productivity. This update introduces an experimental --trim feature that, when used during system image compilation, removes statically unreachable code. This leads to faster compile times and reduced binary sizes.
For runtime flexibility, bindings now participate in the “world age” mechanism, previously limited to methods, enabling proper redefinition of constants and structs. Alongside this, Julia 1.12 provides new multi-threading improvements: an interactive thread is enabled by default, thread settings now respect CPU affinity, and the @atomic macro family gains support for reference assignment syntax.
Following these core language changes, users benefit from added tracing flags and macros for examining compilation events, making it easier to locate expensive compilation steps. BOLT-optimized builds of libLLVM, libjulia-internal, and libjulia-codegen are now supported, leveraging post-link optimization from LLVM to enhance runtime speed. The generated LLVM intermediate representation (IR) now uses pointer types directly, replacing prior use of integer encodings.
While working with tasks, developers can take advantage of two new per-task timing metrics. Test workflows are aided by automatic printing of the random number generator seed during @testset failures, improving reproducibility. Additional enhancements to the Pkg and other miscellaneous improvements are also shipped in this release.
