Sound and Partially-Complete Static Analysis of Data-Races in GPU Programs

被引:0
|
作者
Liew, Dennis [1 ]
Cogumbreiro, Tiago [1 ]
Lange, Julien [2 ]
机构
[1] Univ Massachusetts Boston, Boston, MA 02125 USA
[2] Royal Holloway Univ London, Egham, England
来源
基金
美国国家科学基金会;
关键词
data-race detection; GPU programming; static analysis; true positives; VERIFICATION;
D O I
10.1145/3689797
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
GPUs are progressively being integrated into modern society, playing a pivotal role in Artificial Intelligence and High-Performance Computing. Programmers need a deep understanding of the GPU programming model to avoid subtle data-races in their codes. Static verification that is sound and incomplete can guarantee data-race freedom, but the alarms it raises may be spurious and need to be validated. In this paper, we establish a True Positive Theorem for a static data-race detector for GPU programs, i.e., a result that identifies a class of programs for which our technique only raises true alarms. Our work builds on the formalism of memory access protocols, that models the concurrency operations of CUDA programs. The crux of our approach is an approximation analysis that can correctly identify true alarms, and pinpoint the conditions that make an alarm imprecise. Our approximation analysis detects when the reported locations are reachable (control independence, or CI), and when the reported locations are precise (data independence, or DI), as well identify inexact values in an alarm. In addition to a True Positive result for programs that are CI and DI, we establish the root causes of spurious alarms depending on whether CI or DI are present. We apply our theory to introduce FaialAA, the first sound and partially complete data-race detector. We evaluate FaialAA in three experiments. First, in a comparative study with the state-of-the-art tools, we show that FaialAA confirms more DRF programs than others while emitting 1.9x fewer potential alarms. Importantly, the approximation analysis of FaialAA detects 10 undocumented data-races. Second, in an experiment studying 6 commits of data-race fixes in open source projects OpenMM and Nvidia's MegaTron, FaialAA confirmed the buggy and fixed versions of 5 commits, while others were only able to confirm 2. Third, we show that 59.5% of 2,770 programs are CI and DI, quantifying when the approximation analysis of FaialAA is complete. This paper is accompanied by the mechanized proofs of the theoretical results presented therein and a tool (FaialAA) implementing of our theory.
引用
收藏
页数:28
相关论文
共 18 条
  • [1] Provable GPU Data-Races in Static Race Detection
    Liew, Dennis
    Cogumbreiro, Tiago
    Lange, Julien
    ELECTRONIC PROCEEDINGS IN THEORETICAL COMPUTER SCIENCE, 2022, (356): : 36 - 45
  • [2] NONPARAMETRIC-ESTIMATION FOR PARTIALLY-COMPLETE TIME AND TYPE OF FAILURE DATA
    DINSE, GE
    BIOMETRICS, 1982, 38 (02) : 417 - 431
  • [3] NONPARAMETRIC-ESTIMATION BASED ON PARTIALLY-COMPLETE TIME AND TYPE OF FAILURE DATA
    DINSE, GE
    BIOMETRICS, 1981, 37 (03) : 612 - 612
  • [4] GRace: A Low-Overhead Mechanism for Detecting Data Races in GPU Programs
    Zheng, Mai
    Ravi, Vignesh T.
    Qin, Feng
    Agrawal, Gagan
    ACM SIGPLAN NOTICES, 2011, 46 (08) : 135 - 145
  • [5] GMRace: Detecting Data Races in GPU Programs via a Low-Overhead Scheme
    Zheng, Mai
    Ravi, Vignesh T.
    Qin, Feng
    Agrawal, Gagan
    IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS, 2014, 25 (01) : 104 - 115
  • [6] Data Races and Static Analysis for Interrupt-Driven Kernels
    Chopra, Nikita
    Pai, Rekha
    D'Souza, Deepak
    PROGRAMMING LANGUAGES AND SYSTEMS, ESOP 2019: 28TH EUROPEAN SYMPOSIUM ON PROGRAMMING, 2019, 11423 : 697 - 723
  • [7] A sound abstract memory model for static analysis of C programs
    Dong, Yukun
    INTERNATIONAL JOURNAL OF COMPUTATIONAL SCIENCE AND ENGINEERING, 2018, 16 (03) : 255 - 264
  • [8] Optimized Sound and Complete Data Race Detection in Structured Parallel Programs
    Storey, Kyle
    Powell, Jacob
    Ben Ogles
    Hooker, Joshua
    Aldous, Peter
    Mercer, Eric
    LANGUAGES AND COMPILERS FOR PARALLEL COMPUTING (LCPC 2018), 2019, 11882 : 94 - 111
  • [9] Sound and Complete Certificates for Quantitative Termination Analysis of Probabilistic Programs
    Chatterjee, Krishnendu
    Goharshady, Amir Kafshdar
    Meggendorfer, Tobias
    Zikelic, Dorde
    COMPUTER AIDED VERIFICATION (CAV 2022), PT I, 2022, 13371 : 55 - 78
  • [10] Bayesian analysis for partially complete time and type of failure data
    Kundu, Debasis
    JOURNAL OF APPLIED STATISTICS, 2013, 40 (06) : 1289 - 1300