一句话:提出将动态内存安全检查代码并行执行的技术,利用静态依赖与动态收益分析降低运行时开销,同时不牺牲检查能力。
C/C++ 程序中的内存安全问题难以根除,动态内存安全强制虽然效果显著,却带来难以承受的运行时开销。现有降开销方案要么依赖大量人工,要么紧密绑定特定硬件/编译器支持,要么效果有限。本文提出一种通过并行执行动态检查代码来降低时间开销的新技术:先利用静态依赖分析识别可安全分离的检查代码,再通过动态收益分析判断并行化是否划算,并将有收益的代码分派到不同线程同时执行。作者实现了工具 Catamaran,并在大量基准程序上评估。实验结果表明,Catamaran 能在不牺牲内存安全强制能力的前提下,显著降低现有动态工具的运行时开销。
Memory safety issues are the intrinsic diseases of C/C++ programs. Dynamic memory safety enforcement as the dominant approach has an advantage in high effectiveness, yet suffers from prohibitively high runtime overhead. Existing attempts to reduce the overhead are either labor-intensive, tightly dependent on specific hardware/compiler support, or poorly effective. In this paper, we propose a novel technique to reduce time overhead by executing the dynamic checking code in parallel. We leverage static dependence analysis and dynamic profit analysis to identify and dispatch the potential code to separate threads running simultaneously. We implemented a tool called Catamaran and evaluated it over a rich set of benchmarks. The experimental results validate that Catamaran is able to significantly reduce the runtime overhead of the existing dynamic tools, without sacrificing capability of memory safety enforcement.
@inproceedings{ZhangLSCL023,
title = {Catamaran: Low-Overhead Memory Safety Enforcement via Parallel Acceleration},
author = {Yiyu Zhang and Tianyi Liu and Zewen Sun and Zhe Chen and Xuandong Li and Zhiqiang Zuo},
booktitle = {ISSTA},
year = {2023},
doi = {10.1145/3597926.3598098}
}