并发执行的并行多线程程序执行过程中,不同的访存顺序会得到不同的执行结果.由于再次执行时,难以重现首次执行时的错误,导致并行程序的调试非常困难.确定性重放是解决该问题的一种方法,目的是通过记录并行程序执行过程中的不确定性事件,然后利用记录的事件重现出程序的原始执行.然而,已有的确定性重放方法会产生大量的记录日志,如何减小记录日志是确定性重放领域的研究热点,在实际应用中也是非常具有挑战性的问题.为了减小记录日志的开销,文中提出了一种基于逻辑时间的访存依赖约减方法,并在支持松弛存储一致性模型的处理器上提出具体的实现技术,该方法利用了访存依赖对应的逻辑时间之间的序关系进行约减.通过模拟评估所提出方法的性能和可扩展性.其中,在8核模拟平台上,通过Splash2测试程序进行评估,结果显示所提出的记录方法平均日志开销为0.11Bytes/Kilo-Instruction,与目前最好的访存依赖约减方法Timetraveler相比提高了75%;通过4核、8核和16核平台的评估结果,表明所提出约减方法具有较好的可扩展性.
When multiple threads are executed simultaneously, different behaviors of the parallel program will be caused because of nondeterministic order of the memory access. Thus it is difficult to debug parallel programs since it is difficult to replay the execution process of the parallel programs. Deterministic replay is a promising method to reproduce the behavior of parallel programs. The method first records nondeterministic events in the phase of recording, and then reproduces the execution in the phase of replay. There is an important challenging problem in the deterministic replay method, that is, the huge volume of memory is needed to store the logs to preserve the nondeterministic events. To reduce log size, this paper proposed a novel technique which utilizes the order of logic clock in the execution of parallel program. Furthermore, the paper introduces specific implementation on processor with relaxed consistency model. Our experimental results of Splash2 benchmark on an 8-core simulator show that the average log-size of the proposed method is 0. 11 Bytes/Kilo-Instruction. Compared with Timetraveler, which is the state of the art method, it reduces log size by 75%. The experiments on the platforms of 4-core, 8-core, and 16-core also show that the proposed method is scalable with high efficiency.