首页> 外文会议>2011 17th IEEE International Conference on Parallel and Distributed Systems >SAW: Java Synchronization Selection from Lock or Software Transactional Memory
【24h】

SAW: Java Synchronization Selection from Lock or Software Transactional Memory

机译:SAW:从锁或软件事务存储器中选择Java同步

获取原文

摘要

To rewrite a sequential program into a concurrent one, the programmer has to enforce atomic execution of a sequence of accesses to shared memory to avoid unexpected inconsistency. There are two means of enforcing this atomicity: one is the use of lock-based synchronization and the other is the use of software transactional memory (STM). However, it is difficult to predict which one is more suitable for an application than the other without trying both mechanisms because their performance heavily depends on the application. We have developed a system named emph{SAW} that decouples the synchronization mechanism from the application logic of a Java program and enables the programmer to statically select a suitable synchronization mechanism from a lock or an STM. We introduce annotations to specify critical sections and shared objects. In accordance with the annotated source program and the programmer's choice of a synchronization mechanism, SAW generates aspects representing the synchronization processing. By comparing the rewriting cost using SAW and that using individual synchronization mechanism directly, we show that SAW relieves the programmer's burden. Through several benchmarks, we demonstrate that SAW is an effective way of switching synchronization mechanisms according to the characteristics of each application.
机译:为了将顺序程序重写为并发程序,程序员必须强制执行对共享内存的访问序列的原子执行,以避免意外的不一致。有两种实现这种原子性的方法:一种是使用基于锁的同步,另一种是使用软件事务存储(STM)。但是,如果不尝试两种机制,则很难预测哪一种比另一种更适合应用程序,因为它们的性能在很大程度上取决于应用程序。我们开发了一个名为emph {SAW}的系统,该系统将同步机制与Java程序的应用程序逻辑分离,并使程序员能够从锁或STM中静态选择合适的同步机制。我们引入注释来指定关键部分和共享对象。根据带注释的源程序和程序员对同步机制的选择,SAW会生成表示同步处理的方面。通过比较使用SAW和直接使用单个同步机制的重写成本,我们表明SAW减轻了程序员的负担。通过几个基准测试,我们证明了SAW是根据每个应用程序的特性切换同步机制的有效方法。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号