.netconcurrencyprogramming-languagesaxum-lang

What is this new Axum programming language?


I read this story on slashdot today where they announce a new parallel programming language by Microsoft.

What is this new programming language about? It says Parallel Programming. But is it going to be an alternative/replacement for MPI, PVM, OpenMP and similar parallel libraries/frameworks?

Any thoughts?


Solution

  • Axum is a language structured in such a way as to make safe and performant concurrent programming simpler. The concepts modelled by the language avoid the need to make thread synchronisation explicit via the use of lock (in C#), Monitor, ReaderWriterLockSlim, etc...

    It could be argued that many of the ideas within Axum have been in the Erlang programming language since 1986 -- a language designed by researchers working in Sweden for Ericsson to run on telephone switches, and hence support for massive throughput under highly concurrent load was so essential it was designed into the language. Whilst many of the ideas in Axum aren't new, they are certainly new to .NET and the CLR (at least at the language level.)

    Existing .NET libraries that contain some of these ideas are:

    Like Erlang, message passing is a central concept in Axum. Like Erlang, Axum is largely indifferent as to whether the recipient of the message is located in-process or remotely. Axum currently provides integration with WCF.

    Axum differs from the libraries mentioned above in that it includes support for these concepts at the language level, not just via use of libraries. The Axum compiler deals not only with the Axum language, but also with some experimental extensions to the C# language itself; namely the isolated and readonly keywords.

    Adding new features to a language is not something to be taken lightly. Spec# is another C#-superset language developed at MSR (unrelated to concurrency). As seen with the support for Code Contracts in .NET 4.0, Microsoft has decided to favour adding a new API rather than new language extensions (this benefits users of all languages on the CLR.) However in the case of Axum, there is not enough richness in the C# 3.0 language to express the kinds of immutability constraints required of types and their members for truly safe concurrent programming.

    Having dabbled in Erlang and liking what I saw, I'm very excited about where Axum might take us. Some of the extensions to the C# language proposed by the team are useful for regular C# projects too.

    Finally I'd like to point out that there's more to Erlang than just a good concurrency model. Erlang is a strict functional programming language. It supports hot swappable code, meaning that a system can be upgraded without it ever being stopped (a desirable feature of a telephone switch or any other 24x7 system). I heard a report from a large British telecommunications organisation running a switch for a year and only failing to route four calls in that time. Erlang has other characteristics such as remote exception handling as well.