Static Analysis for Kokkos Via ClangTidy.

Cannada Lewis · 2021

We have recently implemented compile time correctness analysis, for the Kokkos library, using tools provided by the LLVM compiler framework. Kokkos is a C++ abstraction layer that provides performance portability across a wide array of backends, the most popular ones being Cuda and OpenMP. The Kokkos programming model has requirements for where and how parallel kernels execute, but these requirements are easy to violate because they are not enforced by standard C++ compilers. Our analyses, implemented as checks in LLVM's clang-tidy, verify adherence to this model. They can detect issues that could lead to compiler errors, runtime crashes, and even runtime incorrectness errors. Because the checks are implemented within LLVM they are easy to deploy and have broad interoperability; working in a stand alone mode, with CMake ---the most widely used C++ build system---, and even providing editor integration via the language server protocol. A poster presented at the SIAM CSE21 conference, minisymposterium PP7: Software Productivity and Sustainability for CSE.

Read the paper · More papers on PaperTik