MC# : An Asynchronous Parallel Programming Language for Cluster and GRID-Architectures

Guzev,V., Serdyuk,Z., Chudinov,A.


MC# is a programming language for cluster- and GRID-architectures based on asynchronous parallel programming model accepted in Polyphonic C# language (N.Benton, L.Cardelli, C.Fournet; Microsoft Research, Cambridge, UK).Asynchronous methods of Polyphonic C# play two major roles in MC#:

1) as autonomous methods executed on remote machines, and

2) as methods used for delivering messages.

The former are identified in MC# as the "movable methods",and the latter form a special syntactic class with the elements named "channels".Analogously to Polyphonic C#, chords are used for receiving values from the channels and as a synchronization mechanism. The MC# channels are generalised naturally to "bidirectional channels", which may be used both for sending and receieving messages in the movable methods.

The runtime-system of MC# has as the basic operation a copying operation for the object which is scheduled for execution on remote machine. This copy is "dead" after the movable method has finished its work, and all changes of this remote copy arenot transferred to the original object. Arguments of the movable method are copied together with an original object, but the passing of bidirectional channels is realised through transferring the proxies for such channels.

By way of experiments in MC#, we have written a series of parallel programs such as a computation of Fibonacci numbers, walking through binary tree, computation of primes by Eratosthenes sieve, calculation of Mandelbrot set, modeling the Conway's game "Life", etc. In all these cases, we got the easy readable and compact code.

Also we have an experimental implementation in which the compiler is written in SML.NET-language, and the execution of movable methods on remote machines is based on the Reflection library of .NET platform.