首页 | 官方网站   微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 125 毫秒
1.
一种基于目录的软件事务性内存实现算法   总被引:1,自引:1,他引:0  
软件事务性内存(STM)提供同步手段,让多线程程序高效并发执行.STM算法中一般包含记录所访问的共享数据、缓冲投机修改的数据以及处理事务冲突.STM中的主要开销在于维护共享数据访问记录和一致性验证.维护共享数据访问记录主要目的是便于进行验证.冲突检测(conflict detection)判断两个事务能否同时提交,而验证(validation)确保每个线程看到的数据状态是一致的.给出了关于STM一个简单模型,证明在STM中对共享数据的修改是线性的.提出的LDSTM算法通过在目录中维护版本信息,可以在读取各个共享对象时快速确定事务的内存视图是否处于一致状态,可以极大减少冲突检测和验证的开销.该算法可以实现早期发现写一写冲突,减少无效计算.在单线程情况下该算法开销很小.实验数据表明,LDSTM简单高效,冲突检测和验证开销减少明显.  相似文献   

2.
Many researchers have developed applications using transactional memory (TM) with the purpose of benchmarking different implementations, and studying whether or not TM is easy to use. However, comparatively little has been done to provide general-purpose tools for profiling and optimizing programs which use transactions. In this paper we introduce a series of profiling and optimization techniques for TM applications. The profiling techniques are of three types: (i) techniques to identify multiple potential conflicts from a single program run, (ii) techniques to identify the data structures involved in conflicts by using a symbolic path through the heap, rather than a machine address, and (iii) visualization techniques to summarize how threads spend their time and which of their transactions conflict most frequently. Altogether they provide in-depth and comprehensive information about the wasted work caused by aborting transactions. To reduce the contention between transactions we suggest several TM specific optimizations which leverage nested transactions, transaction checkpoints, early release and etc. To examine the effectiveness of the profiling and optimization techniques, we provide a series of illustrations from the STAMP TM benchmark suite and from the synthetic WormBench workload. First we analyze the performance of TM applications using our profiling techniques and then we apply various optimizations to improve the performance of the Bayes, Labyrinth and Intruder applications. We discuss the design and implementation of the profiling techniques in the Bartok-STM system. We process data offline or during garbage collection, where possible, in order to minimize the probe effect introduced by profiling.  相似文献   

3.
事务存储系统是一种高层次抽象并行编程模型,目的为方便开发并行程序。事务存储系统中的竞争管理模块用于解决事务之间的冲突。传统的事务竞争管理策略只负责仲裁两个冲突事务之间的冲突.提出将多个事务及事务冲突关联转换成一张无向图,基于全局事务冲突情景,利用图顶点着色技术求解无向图中最大独立集。最大独立集中事务相互不冲突,CM仲裁处理并发执行,实现系统并发最大化。  相似文献   

4.
The Web frequently suffers from failures which affect the performance and consistency of applications run over it. An important fault-tolerance technique is the use of atomic actions (atomic transactions) for controlling operations on services. Atomic actions guarantee the consistency of applications despite concurrent accesses and failures. Techniques for implementing transactions on distributed objects are well-known: in order to become “transaction aware”, an object requires facilities for concurrency control, persistence, and the ability to participate in a commit protocol. While it is possible to make server-side applications transactional, browsers typically do not possess such facilities, a situation which is likely to persist for the foreseeable future. Therefore, the browser will not normally be able to take part in transactional applications. The paper presents a design and implementation of a scheme that does permit non-transactional browsers to participate in transactional applications, thereby providing much needed end-to-end transactional guarantees.  相似文献   

5.
软件事务性内存(STM)提供同步手段,让多线程程序高效并发执行。如果两个事务访问了同一个共享数据且至少一个事务进行了修改操作,则称发生了冲突。检测冲突后,一般选择一个事务终止。当前的STM实现都基于严格的线性一致性(Linearizability)语义模型,实现简单。但是,基于该语义会导致很多本来可以完成提交的事务失败,降低了系统效率。把因果一致性模型应用于STM,可以在保证程序准确性条件下取得较好的实际性能。实验数据表明,该算法简单高效,明显减少了冲突数目。  相似文献   

6.
针对无线传感器网络(WSN)的众多应用都需要依赖时钟同步的节点协同完成,而由于节点的晶体震荡器受自身以及外界环境的影响,使得节点时钟偏斜和时钟偏移两个参数发生变化导致时钟不同步问题,提出了基于分布式卡尔曼滤波估计的一致性补偿时钟同步算法DKFCC。该算法首先利用双向信息交换机制以及分布式卡尔曼滤波实现时钟偏斜和偏移两个参数的最优估计,然后基于时钟参数的最优估计值采用一致性补偿方法实现节点的时钟同步。实验结果表明:在100个节点随机部署的WSN中,采用虚拟全局一致性方式的DKFCC同步算法比异步一致性同步(AC)算法的同步均方根误差(SRAMSE)值降低了约95%,具有较高的同步精度;同时,所提出算法从时钟参数层面实现同步,无需频繁地进行时钟同步操作,相比AC算法更节能。  相似文献   

7.
We consider the interaction of weakly atomic Software Transactional Memory (STM) providing single global lock atomicity with the x86 memory consistency model. We show that a practical design for such an STM requires that some program behaviour be disallowed, due to the strictness of the x86 memory consistency model in comparison to the language level memory models hitherto considered in weakly atomic STM designs. We present the design and construction of such an STM that disallows races between a transactional read and a non-transactional write. We also report on a practical application of this STM to elide legacy locks in x86 binaries. This allows software transactional memory to be applied without requiring software to be a priori written with awareness of transactional memory and without any restriction on source language or compiler. As an example, we show how a mainstream multiplayer game can use transactional memory with zero changes and 11% overhead over language level transactional memory, which requires over 700 annotations and severely restricts software development.  相似文献   

8.
新兴的非易失性内存(non-volatile memory,NVM)具有字节寻址、持久性、大容量和低功耗等优点,然而,在NVM上进行并发编程往往比较困难,用户既要保证数据的崩溃一致性又要保证并发的正确性.为了降低用户开发难度,研究人员提出持久性事务内存方案,但是现有持久性事务内存普遍存在扩展性较差问题.测试发现限制扩展性的关键因素在于全局逻辑时钟和冗余NVM写操作.针对这2个方面,提出了线程逻辑时钟方法,通过允许每个线程拥有一个独立时钟,消除全局逻辑时钟中心化问题;提出了缓存行感知的双版本方法,为数据维护2个版本,通过循环更新这2个版本来保证数据的崩溃一致性,从而消除冗余的NVM写操作.基于所提出的这2个方法,实现了一个基于时间戳的高扩展的持久性软件事务内存(scalable durable transactional memory,SDTM),对比测试显示,在YCSB负载下,与DudeTM和PMDK相比,SDTM的性能最多分别提高了2.8倍和29倍.  相似文献   

9.
多数据库系统中的一致性维护   总被引:9,自引:2,他引:7  
在多数据库环境中存在着全局事务和局部事务,它们必须相互协作,从而为应用程序提供一致性的数据。为了维护多数据库系统(MDBS)的一致性,提出一种事务管理机制。该机制基于扩展事务的原理,对全局子事务和局部事务进行扩展,并为各个局部数据库引进一些控制表。局部数据库管理系统(LDBMS)和局部数据库和控制表之上执行扩展务,这些扩展事务负一局可串行性及事务的恢复。由于它不依赖于LDBMS的各种特征,因此该方法易于实现,是实用的。  相似文献   

10.
We present a transaction model for multidatabase systems with autonomous component systems, coined heterogeneous 3-level transactions. It has become evident that in such a system the requirements of guaranteeing full ACID properties and full local autonomy can not be reconciled. In the heterogeneous 3-level transaction model, semantics of actions and specific properties of the architecture of multidatabase systems and of applications are utilized to define application specific compromises between these competing goals. We consider different definitions of conflicts between actions together with application specific sets of allowed (autonomous) local transactions and global subtransactions. A formal model for serializability is given. It is proven that heterogeneous 3-level transactions guarantee all consistency constraints that are ensured in serial executions. In contrast to most other models, we do not require data to be partitioned into global and local data. In particular, heterogeneous 3-level transactions even allow the same data to be updated by local and global transactions in parallel, if these updates are found to be semantically non-conflicting. Recovery is handled by inverse actions. We present a formal framework for this approach which is fully integrated into serializability theory by considering inverse actions as ordinary actions. This has an important impact on the relationship of concurrency control and recovery in our model: By changing the definition of conflicts between actions in order to tailor the model according to application needs, recovery is implicitly affected and no further explicit adaptation of recovery algorithms is necessary. The heterogeneous 3-level transaction model assumes component database systems to support ACID transaction properties. Further properties of local transactions or interfaces of the component database systems are not required. We describe a prototype implementation of heterogeneous 3-level transactions in the object-oriented database system VODAK.  相似文献   

11.
基于依赖图的硬件事务存储技术研究   总被引:1,自引:0,他引:1  
事务存储技术能够简化并行程序中对共享资源的访问控制,是当前的研究热点之一.目前,多数基于硬件的事务存储系统采用基于冲突检测与处理的并发控制协议,当检测到两事务发生冲突时就中止二者之一.但是对事务间"冲突"更深入的分析表明,某些"冲突"并不一定会导致事务的回退,这种冲突称为"弱冲突".基于依赖图的硬件事务存储技术能够避免弱冲突引发的多余事务回退.模拟实验表明,基于依赖图的事务存储系统与基于冲突处理的事务存储系统相比具有明显的性能优势.  相似文献   

12.
王延升  刘雷波 《计算机工程》2009,35(24):257-258
针对时钟网络在SoC芯片中的作用和时钟网络自身的特点,研究并实现3种时钟低功耗技术,包括在系统级采用动态时钟管理技术动态地关断和配置芯片内各模块的时钟,在逻辑综合时基于功耗优化工具Power Compiler插入门控时钟单元,在时钟树综合时以时钟树规模为目标进行低功耗时钟树综合。在音视频解码芯片的设计中采用以上3种技术,结果表明其功耗优化效果明显。  相似文献   

13.
Recent embedded processor architectures containing multiple heterogeneous cores and non-coherent caches renewed attention to the use of Software Transactional Memory (STM) as a building block for developing parallel applications. STM promises to ease concurrent and parallel software development, but relies on the possibility of abort conflicting transactions to maintain data consistency, which in turns affects the execution time of tasks carrying transactions. Because of this fact the timing behaviour of the task set may not be predictable, thus it is crucial to limit the execution time overheads resulting from aborts. In this paper we formalise a FIFO-based algorithm to order the sequence of commits of concurrent transactions. Then, we propose and evaluate two non-preemptive and one SRP-based fully-preemptive scheduling strategies, in order to avoid transaction starvation.  相似文献   

14.
To enforce global serializability in a multidatabase environment the multidatabase transaction manager must take into account the indirect (transitive) conflicts between multidatabase transactions caused by local transactions. Such conflicts are difficult to resolve because the behavior or even the existence of local transactions is not known to the multidatabase system. To overcome these difficulties, we propose to incorporate additional data manipulation operations in the subtransactions of each multidatabase transaction. We show that if these operations create direct conflicts between subtransactions at each participating local database system, indirect conflicts can be resolved even if the multidatabase system is not aware of their existence. Based on this approach, we introduce optimistic and conservative multidatabase transaction management methods that require the local database systems to ensure only local serializability. The proposed methods do not violate the autonomy of the local database systems and guarantee global serializability by preventing multidatabase transactions from being serialized in different ways at the participating database systems. Refinements of these methods are also proposed for multidatabase environments where the participating database systems allow schedules that are cascadeless or transactions have analogous execution and serialization orders. In particular, we show that forced local conflicts can be eliminated in rigorous local systems, local cascadelessness simplifies the design of a global scheduler, and that local strictness offers no significant advantages over cascadelessness  相似文献   

15.
对于读密集型的云计算应用,现有系统很难同时满足它们对性能、一致性与可用性的需求。因此提出了一种基于事务内存和云存储技术的编程与存储模型TMC,能为云应用提供可配置的事务特性与数据存储服务。TMC包括事务与存储两个组件,事务组件允许所有只读事务无需远程验证即可顺利提交,其他事务则采用2PC算法提交;存储组件负责实现系统的可扩展性与可用性。仿真实验结果表明,TMC具有较高的性能与可用性。系统若经进一步改进和优化,将具有应用于实际生产环境中的潜力,可为用户提供高质量的云计算服务。  相似文献   

16.
In this paper, we introduce contention locality in Transactional Memory (TM) which describes the likelihood that a previously aborted transaction conflicts again in the future. We find that conflicts are highly predictable in TMs and we propose two optimization techniques based on contention locality: The first optimization technique is Speculative Contention Avoidance (SCA). SCA dynamically controls the number of concurrently executing transactions and serializes those transactions that are likely to conflict. As such, SCA reduces contention in TMs and improves performance. The second optimization technique is Adaptive Validation (AV). We show that there is no single validation policy that works well across all applications. AV adjusts validation based on applications’ behavior and improves performance of TMs. In this paper, SCA and AV are evaluated using Transactional Locking II (TL2) and Stamp v0.9.10 benchmark suite. The evaluation reveals that SCA and AV are effective and improve performance significantly.  相似文献   

17.
单一的时钟同步技术由于其精度及应用局限性,无法满足矿用分布式采集系统高精度、高可靠性的时钟同步性能要求。针对上述问题,提出了基于北斗+IEEE 1588V2+本地后备时钟的三级协同时钟同步方案。选用部署在地面的T600-BDGOCXC型北斗授时服务器作为主时钟,为系统提供纳秒级精度的绝对时钟;采用STM32F407+DP83848及PTPd协议栈实现支持IEEE 1588V2协议的采集节点,通过井下工业环网将北斗的绝对时钟同步到各采集节点;本地后备时钟采用STM32F407内部RTC(实时时钟)实现,给各采集节点提供秒级精度的时间戳初值,便于各采集节点用最短时间实现与主时钟的同步。测试结果表明,北斗授时服务器与采集节点通过交换机直连的情况下,1 min后时钟同步精度达162 ns;北斗授时服务器与采集节点通过三级交换机连接的情况下,时钟同步精度为565 ns;在北斗授时服务器失效的情况下,优先级高的采集节点升级为主时钟并为其余采集节点授时,具有较强的可靠性。  相似文献   

18.
介绍了STM32单片机主时钟输出功能,通过硬件设计和软件设计实现了主时钟输出功能、STM32单片机主时钟输出的波形展示,以及在空调控制系统中的应用.STM32 F030使用STM32 F205输出的时钟,可以正常稳定的工作,经过多台实际机组的长期运行测试,两个单片机工作都非常稳定.  相似文献   

19.
This paper presents DMVOCC-2PLV (Distributed Multiversion Optimistic Concurrency Control with Two-Phase Local Validation) protocol for processing mobile distributed real-time transactions in mobile broadcast environments. In DMVOCC-2PLV protocol, transaction validation is performed at two levels: local validation and global validation. Local validation of transactions is performed in two phases: local pre-validation and local final validation. At the MHs (Mobile Hosts), all mobile transactions perform local pre-validation of transactions by using a backward validation mechanism. The local pre-validation process is carried out against committed transactions at the server in the last broadcast cycle. Such an early data conflict detection feature can save processing and communication resources. Transactions that survive in local pre-validation must be submitted to the server for local final validation. In global validation distributed update transactions have to check to ensure distributed serializability in all participants. The protocol can eliminate conflicts between mobile read-only and mobile update transactions, and resolve data conflicts flexibly using multiversion dynamic adjustment of serialization order to avoid unnecessary restarts of transactions. Mobile read-only transactions can be committed with no-blocking, and respond time of mobile read-only transactions is greatly reduced. The tolerance of mobile transactions of disconnections from the broadcast channel is increased. The results of simulation experiment show that the new protocol proposed offers better performance in terms of miss rate, restart rate, commit rate and throughput.  相似文献   

20.
Transactional coherence and consistency (TCC) simplifies parallel hardware and software design by eliminating the need for conventional cache coherence and consistency models and letting programmers parallelize a wide range of applications with a simple, lock-free transactional model. TCC eases both parallel programming and parallel architecture design by relying on programmer-defined transactions as the basic unit of parallel work, communication, memory coherence, and memory consistency  相似文献   

设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司    京ICP备09084417号-23

京公网安备 11010802026262号