Inferring ownership transfer for efficient message passing

Stas Negara, Rajesh K. Karmani, Gul Agha

Research output: Contribution to journalArticlepeer-review


One of the more popular paradigms for concurrent programming is the Actor model of message passing; it has been adopted in one form or another by a number of languages and frameworks. By avoiding a shared local state and instead relying on message passing, the Actor model facilitates modular programming. An important challenge for message passing languages is to transmit messages efficiently. This requires retaining the pass-by-value semantics of messages while avoiding making a deep copy on sequential or shared memory multicore processors. A key observation is that many messages have an ownership transfer semantics; such messages can be sent efficiently using pointers without introducing shared state between concurrent objects. We propose a conservative static analysis algorithm which infers if the content of a message is compatible with an ownership transfer semantics. Our tool, called SOTER (for Safe Ownership Transfer enablER1) transforms the program to avoid the cost of copying the contents of a message whenever it can infer the content obeys the ownership transfer semantics. Experiments using a range of programs suggest that our conservative static analysis method is usually able to infer ownership transfer. Performance results demonstrate that the transformed programs execute up to an order of magnitude faster than the original programs.

Original languageEnglish (US)
Pages (from-to)81-90
Number of pages10
JournalACM SIGPLAN Notices
Issue number8
StatePublished - Aug 1 2011


  • Actors
  • Message Passing
  • Ownership Transfer
  • Static Analysis

ASJC Scopus subject areas

  • Computer Science(all)

Fingerprint Dive into the research topics of 'Inferring ownership transfer for efficient message passing'. Together they form a unique fingerprint.

Cite this