Composing Relaxed Transactions

Composing Relaxed Transactions
复制标题

编写宽松的交易

DOI:
--
复制
发表时间:
2013
期刊:
2013 IEEE 27th International Symposium on Parallel and Distributed Processing
影响因子:
--
通讯作者:
Mihai Letia
Mihai Letia
中科院分区:
--
文献类型:
--
作者:
Vincent Gramoli;R. Guerraoui;Mihai Letia

文献摘要

被引文献

相似文献

由于经典的事务抽象有时被认为在利用并行性方面限制太大,因此有大量工作致力于设计宽松的事务模型,以提高并发性。然而,对提高并发性的追求在某种程度上导致忽视了事务中最吸引人的一个方面:软件组合,即独立开发软件片段并将它们组合成在并发性面前表现正确的应用程序的能力。实际上,仔细研究一下宽松的事务模型就会发现,它们确实危及了组合,这就提出了一个基本问题:在保留组合的同时,是否有可能设计出这样的模型。本文表明,答案是肯定的。我们提出了继承,这是一个(可能放松的)事务性内存支持组合的充分必要条件。基本上,继承要求子事务将它们的冲突信息传递给它们的父事务,而父事务反过来维护这些信息直到提交时间。这个想法的具体实例以前已经被使用过,经典事务是最普遍的例子,但我们相信是第一个将其作为一般原则捕获并证明它严格来说相当于确保组合。我们将说明使用弹性事务的继承的好处,并展示它们如何在不妨碍并发性的情况下满足继承和提供组合。我们利用这一点提出了一个新的(事务性)Java包,它是JDK并发性包的可组合替代品,并通过一个实现来评估效率,该实现将最先进的软件事务性内存实现(TL2、LSA、SwissTM)的速度提高了近3倍。
As the classic transactional abstraction is sometimes considered too restrictive in leveraging parallelism, a lot of work has been devoted to devising relaxed transactional models with the goal of improving concurrency. Nevertheless, the quest for improving concurrency has somehow led to neglect one of the most appealing aspects of transactions: software composition, namely, the ability to develop pieces of software independently and compose them into applications that behave correctly in the face of concurrency. Indeed, a closer look at relaxed transactional models reveals that they do jeopardize composition, raising the fundamental question whether it is at all possible to devise such models while preserving composition. This paper shows that the answer is positive. We present outheritance, a necessary and sufficient condition for a (potentially relaxed) transactional memory to support composition. Basically, outheritance requires child transactions to pass their conflict information to their parent transaction, which in turn maintains this information until commit time. Concrete instantiations of this idea have been used before, classic transactions being the most prevalent example, but we believe to be the first to capture this as a general principle as well as to prove that it is, strictly speaking, equivalent to ensuring composition. We illustrate the benefits of outheritance using elastic transactions and show how they can satisfy outheritance and provide composition without hampering concurrency. We leverage this to present a new (transactional) Java package, a composable alternative to the concurrency package of the JDK, and evaluate efficiency through an implementation that speeds up state of the art software transactional memory implementations (TL2, LSA, SwissTM) by almost a factor of 3.