Good Programming in Transactional Memory

  • Authors:
  • Raphael Eidenbenz;Roger Wattenhofer

  • Affiliations:
  • Computer Engineering and Networks Laboratory (TIK), ETH Zurich, Switzerland;Computer Engineering and Networks Laboratory (TIK), ETH Zurich, Switzerland

  • Venue:
  • ISAAC '09 Proceedings of the 20th International Symposium on Algorithms and Computation
  • Year:
  • 2009

Quantified Score

Hi-index 0.00

Visualization

Abstract

In a multicore transactional memory (TM) system, concurrent execution threads interact and interfere with each other through shared memory. The less interference a program provokes the better for the system. However, as a programmer is primarily interested in optimizing her individual code's performance rather than the system's overall performance, she does not have a natural incentive to provoke as little interference as possible. Hence, a TM system must be designed compatible with good programming incentives (GPI), i.e., writing efficient code for the overall system coincides with writing code that optimizes an individual program's performance. We show that with most contention managers (CM) proposed in the literature so far, TM systems are not GPI compatible. We provide a generic framework for CMs that base their decisions on priorities and explain how to modify Timestamp-like CMs so as to feature GPI compatibility. In general, however, priority-based conflict resolution policies are prone to be exploited by selfish programmers. In contrast, a simple non-priority-based manager that resolves conflicts at random is GPI compatible.