The development team behind the programming language Julia has presented version 1.7. The latest release of the function-oriented language continues the expansion of Julia’s multithreading capabilities, but also offers a number of other innovations. According to the blog post on the announcement of Julia 1.7, a new random number generator, a revised package manager and a new manifest format will be used.
Work easier with threads
Improved multithreading is one of the most important goals that the Julia development team has been working on for several versions. An important milestone was reached with the stabilization of the multithreading APIs in Julia 1.5. Since then, the team has taken care of tackling numerous race conditions in runtime and fixing synchronization errors. Developers also have more options for distributing workloads in their programs across multiple threads.
Above all, as announced at the last JuliaCon, Atomics should also help. Above
@atomic-Macros and the associated generic functions are available according to the blog post more efficient building blocks for working with threads. The first packages that have already been adapted include JuliaConcurrent / ConcurrentCollections.jl, JuliaActors / Actors.jl and tkf / ThreadsX.jl. The following video summarizes the new options.
The new random number generator from the Xoshiro256-RNG family is also said to be more thread-friendly. In contrast to the Mersenne Twister algorithm, which was previously used as standard, the new RNG opens up the possibility of inserting a state in each task and sharing it when creating new tasks. As a result, the random numbers only depend on the structure of the task spawning of a program, but not on the schedule of parallel execution. According to the Julia team, the new RNG therefore not only promises more speed, but also helps to make the flow of random numbers in multithreading programs more reproducible.
Future-proof manifest format
New in version 1.7 is the manifest format, in which the Package Manager (Pkg) records all dependencies in a TOML file as soon as a new package is created. A comprehensive use of the manifests in different Julia versions was previously not advisable, especially since the Package Manager did not issue a warning in the event of potential dependency problems. With the new format, all dependencies can now be managed under a common
[deps]– Summarize the keys. This frees up the global namespace so that a
julia_version-Entry as well as other useful data can be added in the future. The new manifest format should be used retrospectively from Julia 1.6.2.
More details on the numerous new features in Julia 1.7 are summarized in the Blog post about the release of the new release together. The new version of the programming language promises, among other things, improvements in type inference and higher performance when working with registries in distributed file systems and under Windows. Julia 1.7 is also the first language version that runs natively on Apple’s M1 systems. A complete overview of all changes can be found in the GitHub repository. The role of the long-term support release remains reserved for the 1.6.x series – specifically, Julia 1.6.4 is the next current LTS release.