当前位置: X-MOL 学术J. Syst. Softw. › 论文详情
Our official English website, www.x-mol.net, welcomes your feedback! (Note: you will need to create a separate account there.)
A parallel worklist algorithm and its exploration heuristics for static modular analyses
Journal of Systems and Software ( IF 3.7 ) Pub Date : 2021-07-16 , DOI: 10.1016/j.jss.2021.111042
Quentin Stiévenart 1 , Noah Van Es 1 , Jens Van der Plas 1 , Coen De Roover 1
Affiliation  

One way to speed up static programme analysis is to make use of today’s multi-core CPUs by parallelising the analysis. Existing work on parallel analysis usually targets traditional data-flow analyses for static, first-order languages such as C. Less attention has been given so far to the parallelisation of more general analyses that can also target dynamic, higher-order languages such as JavaScript. These are significantly more challenging to parallelise, as dependencies between analysis results are only discovered during the analysis itself. State-of-the-art parallel analyses for such languages are therefore usually limited, both in their applicability and performance gains.

In this work, we propose the parallelisation of modular analyses. Modular analyses compute different parts of the analysis in isolation of one another, and therefore offer inherent opportunities for parallelisation that have not been explored so far. In addition, they can be used to develop a general class of analysers for dynamic, higher-order languages. We present a parallel variant of the worklist algorithm that is used to drive such modular analyses. To further speed up its convergence, we show how this algorithm can exploit the monotonicity of the analysis. Existing modular analyses can be parallelised without additional effort by instead employing this parallel worklist algorithm. We demonstrate this for ModF, an inter-procedural modular analysis, and for ModConc, an inter-process modular analysis. For ModConc, we reveal an additional opportunity to exploit even more parallelism in the analysis: analyses of individual ModConc components can themselves be parallel, resulting in a doubly-parallel exploration. Finally, we present several heuristics for the exploration order of the analysis and discuss how they can impact its performance.

The parallel worklist algorithm and the exploration heuristics are implemented for and integrated into MAF, a framework for modular programme analysis. On a set of Scheme benchmarks for ModF, we observe speedups between 3× and 8× when using 4 workers, and speedups between 8× and 32× when using 16 workers, with a maximum speedup of 333× using 128 workers. For ModConc, we achieve a maximum speedup of 37× with 32 workers. We observe that on a ModF analysis, among 11 exploration heuristics, the heuristics prioritising either components with smaller environments or with less dependencies result in consistent speedups that can reach 20× those of a random exploration strategy. We find a clear correlation between the mean number of dependencies in a programme and the speedup obtained by this heuristic.



中文翻译:

静态模块化分析的并行工作列表算法及其探索启发法

加速静态程序分析的一种方法是通过并行分析来利用当今的多核 CPU。现有的并行分析工作通常针对静态、一阶语言(如 C)的传统数据流分析。到目前为止,对更通用分析的并行化关注较少,这些分析也可以针对动态、高阶语言(如 JavaScript) . 这些并行化更具挑战性,因为分析结果之间的依赖关系仅在分析本身期间才被发现。因此,针对此类语言的最新并行分析通常在其适用性和性能提升方面都受到限制。

在这项工作中,我们提出了模块化分析的并行化。模块化分析独立地计算分析的不同部分,因此提供了迄今为止尚未探索的并行化的内在机会。此外,它们可用于为动态、高阶语言开发一类通用的分析器。我们提出了用于驱动此类模块化分析的工作列表算法的并行变体。为了进一步加速其收敛,我们展示了该算法如何利用分析的单调性。通过采用这种并行工作列表算法,无需额外工作即可并行化现有的模块化分析。我们为ModF、过程间模块化分析和ModConc演示了这一点,进程间模块化分析。对于ModConc,我们揭示了在分析中利用更多并行性的额外机会:对单个ModConc组件的分析本身可以是并行的,从而导致双重并行探索。最后,我们为分析的探索顺序提出了几种启发式方法,并讨论了它们如何影响其性能。

并行工作列表算法和探索启发式算法实现并集成到 MAF 中,这是一个模块化程序分析框架。在ModF 的一组 Scheme 基准测试中,我们观察到3×8× 当使用 4 个工人时,并且在两者之间加速 8×32× 当使用 16 个工人时,最大加速为 333×使用 128 名工人。对于ModConc,我们实现了最大加速37×有32名工人。我们观察到,在ModF分析中,在 11 个探索启发式方法中,优先使用环境较小或依赖性较小的组件的启发式方法会导致一致的加速,可以达到20×那些随机探索策略。我们发现程序中依赖项的平均数量与通过这种启发式获得的加速之间存在明显的相关性。

更新日期:2021-07-26
down
wechat
bug