Automated testing of graphics shader compilers

被引:81
|
作者
Donaldson A.F. [1 ]
Evrard H. [1 ]
Lascu A. [1 ]
Thomson P. [1 ]
机构
[1] Department of Computing, Imperial College London, London
来源
关键词
Compilers; GLSL; GPUs; OpenGL; Shaders; Testing;
D O I
10.1145/3133917
中图分类号
学科分类号
摘要
We present an automated technique for finding defects in compilers for graphics shading languages. A key challenge in compiler testing is the lack of an oracle that classifies an output as correct or incorrect; this is particularly pertinent in graphics shader compilers where the output is a rendered image that is typically underspecified. Our method builds on recent successful techniques for compiler validation based on metamorphic testing, and leverages existing high-value graphics shaders to create sets of transformed shaders that should be semantically equivalent. Rendering mismatches are then indicative of shader compilation bugs. Deviant shaders are automatically minimized to identify, in each case, a minimal change to an original high-value shader that induces a shader compiler bug. We have implemented the approach as a tool, GLFuzz, targeting the OpenGL shading language, GLSL. Our experiments over a set of 17 GPU and driver configurations, spanning the main 7 GPU designers, have led to us finding and reporting more than 60 distinct bugs, covering all tested configurations. As well as defective rendering, these issues identify security-critical vulnerabilities that affect WebGL, including a significant remote information leak security bug where a malicious web page can capture the contents of other browser tabs, and a bug whereby visiting a malicious web page can lead to a lblue screen of deathž under Windows 10. Our findings show that shader compiler defects are prevalent, and that metamorphic testing provides an effective means for detecting them automatically. © 2017 Copyright held by the owner/author(s).
引用
收藏
相关论文
共 50 条
  • [1] Metamorphic Shader Fusion for Testing Graphics Shader Compilers
    Xiao, Dongwei
    Liu, Zhibo
    Wang, Shuai
    2023 IEEE/ACM 45TH INTERNATIONAL CONFERENCE ON SOFTWARE ENGINEERING, ICSE, 2023, : 2400 - 2412
  • [2] Metamorphic Testing for (Graphics) Compilers
    Donaldson, Alastair F.
    Lascu, Andrei
    2016 IEEE/ACM 1ST INTERNATIONAL WORKSHOP ON METAMORPHIC TESTING (MET), 2016, : 44 - 47
  • [3] Teaching a Shader-Based Introduction to Computer Graphics
    Angel, Ed
    Shreiner, Dave
    IEEE COMPUTER GRAPHICS AND APPLICATIONS, 2011, 31 (02) : 9 - 13
  • [4] Automated Software Testing Technologies for Realistic Computer Graphics
    E. Yu. Denisov
    A. G. Voloboy
    E. D. Biryukov
    M. S. Kopylov
    I. A. Kalugina
    Programming and Computer Software, 2021, 47 : 76 - 87
  • [5] Automated Software Testing Technologies for Realistic Computer Graphics
    Denisov, E. Yu
    Voloboy, A. G.
    Biryukov, E. D.
    Kopylov, M. S.
    Kalugina, I. A.
    PROGRAMMING AND COMPUTER SOFTWARE, 2021, 47 (01) : 76 - 87
  • [6] A Cross-platform Evaluation of Graphics Shader Compiler Optimization
    Crawford, Lewis
    O'Boyle, Michael
    2018 IEEE INTERNATIONAL SYMPOSIUM ON PERFORMANCE ANALYSIS OF SYSTEMS AND SOFTWARE (ISPASS), 2018, : 219 - 228
  • [7] VLSI implementation of phong shader in 3D graphics
    Sin, HC
    Lee, JA
    Kim, LS
    ISCAS '98 - PROCEEDINGS OF THE 1998 INTERNATIONAL SYMPOSIUM ON CIRCUITS AND SYSTEMS, VOLS 1-6, 1998, : A417 - A420
  • [8] An automated approach to reducing test suites for testing retargeted C compilers for embedded systems
    Chae, Heung Seok
    Woo, Gyun
    Kim, Tae Yeon
    Bae, Jung Ho
    Kim, Won-Young
    JOURNAL OF SYSTEMS AND SOFTWARE, 2011, 84 (12) : 2053 - 2064
  • [9] Shader-Like Computations in WebGL for Advanced Graphics and General Purposes
    Watters, Aaron R.
    COMPUTING IN SCIENCE & ENGINEERING, 2021, 23 (02) : 54 - 63
  • [10] Automated Bug Localization in JIT Compilers
    Lim, HeuiChan
    Debray, Saumya
    PROCEEDINGS OF THE 17TH ACM SIGPLAN/SIGOPS INTERNATIONAL CONFERENCE ON VIRTUAL EXECUTION ENVIRONMENTS (VEE '21), 2021, : 153 - 164