AAU Student Projects - visit Aalborg University's student projects portal
A master's thesis from Aalborg University
Book cover


Avoiding Race Conditions with Micro Transactions

Translated title

Avoiding Race Conditions with Micro Transactions

Term

4. term

Publication year

2008

Submitted on

Pages

74

Abstract

The report proposes a solution to race conditions that is a variation of locking and transactional memory. We introduce a small language that uses implicit statement level locking to make micro transactions. This yields new semantics for the assignment statement in the programming language. The locks are implemented using busy-waiting and an atomic compare-and-swap instruction. A simple flow-sensitive and field-sensitive points-to analysis is introduced to deduce which locks are required to perform the transactions atomically. Some experiments are performed which show that the performance of micro transactions is comparatively acceptable. However, it is concluded that, due to lack of compositionality, micro transactions are not a practical solution to race conditions in modern languages.