剖析基于软件的CPU能耗测量:一项比较分析
Dissecting the software-based measurement of CPU energy consumption: a comparative analysis
AI总结:
本文剖析基于软件的CPU能耗测量,比较RAPL各访问机制,提出Rust实现以提高正确性、精度与性能,并通过实验评估其效率与影响。
摘要:
每天,我们都在经历全球变暖的影响:极端天气事件、重大森林火灾、风暴、全球变暖等。科学界承认,这场危机是人类活动的结果,其中信息与通信技术(ICT)的贡献日益重要。计算机科学家需要工具来测量其编写的代码的足迹并对其进行优化。运行平均功率限制(RAPL)是英特尔设计的一个低级接口,无需额外硬件即可提供CPU(及更多组件)能耗的测量。自2017年起,它已可用于大多数计算设备,包括非英特尔设备,如AMD处理器。越来越多的人使用RAPL进行能耗测量,但大多将其视为黑盒,对其行为缺乏深入了解。不幸的是,这会导致在实现测量工具时出现错误。在本文中,我们提议回归允许使用RAPL测量的基本机制,并对其操作进行批判性分析。除了长期确立的机制外,我们还探讨了近期eBPF技术(原为扩展伯克利包过滤器的缩写)与RAPL配合使用的适用性。对于每种机制,我们发布了一个Rust实现,以避免我们在现有工具中检测到的陷阱,从而提高正确性、计时精度和性能。这些新实现对于监控和分析并行应用具有理想的特性。我们还提供了一项实验研究,使用多个基准测试和处理器型号(英特尔和AMD),以评估各种机制的效率及其对并行软件的影响。这些实验表明,没有任何机制在性能上显著优于其他机制。然而,它们在易用性和弹性方面存在显著差异。我们相信,这项工作将帮助社区开发正确、弹性且轻量级的测量工具。
英文摘要:
Every day, we experience the effects of the global warming: extreme weather events, major forest fires, storms, global warming, etc.The scientific community acknowledges that this crisis is a consequence of human activities where Information and Communications Technologies (ICT) are an increasingly important contributor.Computer scientists need tools for measuring the footprint of the code they produce and for optimizing it. Running Average Power Limit (RAPL) is a low-level interface designed by Intel that provides a measure of the energy consumption of a CPU (and more) without the need for additional hardware. Since 2017, it is available on most computing devices, including non-Intel devices such as AMD processors.More and more people are using RAPL for energy measurement, mostly like a black box without deep knowledge of its behavior.Unfortunately, this causes mistakes when implementing measurement tools.In this paper, we propose to come back to the basic mechanisms that allow to use RAPL measurements and present a critical analysis of their operations. In addition to long-established mechanisms, we explore the suitability of the recent eBPF technology (formerly and abbreviation for extended Berkeley Packet Filter) for working with RAPL.For each mechanism, we release an implementation in Rust that avoids the pitfalls we detected in existing tools, improving correctness, timing accuracy and performance. These new implementations have desirable properties for monitoring and profiling parallel applications.We also provide an experimental study with multiple benchmarks and processor models (Intel and AMD) in order to evaluate the efficiency of the various mechanisms and their impact on parallel software.These experiments show that no mechanism provides a significant performance advantage over the others. However, they differ significantly in terms of ease-of-use and resiliency.We believe that this work will help the community to develop correct, resilient and lightweight measurement tools.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。