An ASM specification of C# threads and the .NET memory model

An ASM specification of C# threads and the .NET memory modelShort Description
Abstract. We present a high-level ASM model of C# threads and the .NET memory model. We focus on purely managed, fully portable threading features of C#. The sequential model interleaves the computation steps of the currently running threads and is suitable for uniprocessors. The parallel model addresses problems of true concurrency on multiprocessor systems. The models provide a sound basis for the development of multi-threaded applications in C#.

Website: www.di.unipi.it | Filesize: 268kb
No of Page(s): 24

Content

Modern object-oriented programming languages like Java or C# support multithreaded programming. They allow several threads to run concurrently sharing objects on the heap in the same address space. Each thread has its own frame stack, program counter, local variables and registers. The languages have special syntactical constructs for synchronization. Java has a synchronized statement and synchronized methods, while C# has a lock statement and several attributes that can be applied to classes and methods to control their run-time synchronization behavior.
Although the C# programming languages supports multi-threaded programming directly via special syntax, the underlying thread model is poorly documented and still considered to be part of the library. The Ecma standards for C# [4] and the Common Language Infrastructure [5] contain only a few paragraphs about threads. For example, the lock statement is defined in [4, §15.22] by a reduction to the library functions Monitor.Enter and Monitor.Exit which are not further specified there. Important issues, such as the order of writes to volatile and non-volatile fields, are just briefly mentioned in two paragraphs in [4, §10.10, §17.4.3]. Hence, a program developer has to rely solely on the class library documentation that comes with Microsoft’s .NET framework Software Development Kit [11]. Unfortunately, that documentation is not very precise with respect to threads, locks and memory issues. Moreover, it is not identical with the (XML) specification of the types that comprise the standard libraries in [5, Partition IV, Profiles and Libraries]. For example, specifications of Thread.Interrupt, Thread.Suspend and Thread.Resume are not included in [5].

Get the file Download here

AddThis Social Bookmark Button
Related Books:
  • A Memory Model Sensitive Checker for C#
  • Tutorial on Threads Programming with Python
  • Linux Tutorial POSIX Threads
  • Threading in Java and C# A Focused Language Comparison Overview
  • DETAIL SPECIFICATION Model Name SONY VAIO BX195EP Processor …
  • An Introduction to Programming with C Threads
  • Acer Aspire 5044WLMI Specification
  • Processes, threads and synchronization

  • Related Searches: , , , ,



    Comments

    Leave a Reply