Microsoft builds auto-threading compiler
Microsoft Research has developed a compiler that would make it possible to partially convert single-threaded code written in C# into multi-threaded code. This should simplify the complex and time-consuming development of multithreaded code.
Around 2004, the importance of the clock speed as an indicator of the processor speed decreased compared to other chip properties: manufacturers started to focus more on parallel data processing, among other things. The logical consequence was the advent of multicore processors, which pack multiple computing units into a single chip.
In order to utilize the computing power of modern multicore processors, software must use multithreaded code. However, writing such code is complex and time-consuming, partly because certain bugs that can occur are difficult to reproduce. However, Microsoft Research has released a study describing a compiler that can partially convert single-threaded code into multi-threaded code via an ‘auto-threading’ mechanism.
The input code for the experimental compiler is C#. By using techniques such as polymorphism and mechanisms That deployed in functional programming, the C# code could be optimized by the compiler for multiple cores where useful. Microsoft is said to have already tested the compiler on a ‘big project’, although it is not clear which project is involved. Web servers and mpeg decoders are also said to have been built with the help of the compiler. The future of the project is still unknown.