[all-commits] [llvm/llvm-project] 9f0d8b: [analyzer] Fix dead store checker false positive

Valeriy Savchenko via All-commits all-commits at lists.llvm.org
Thu Apr 8 06:20:11 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 9f0d8bac144c8eb1ca4aff823b2e2d5a0f990072
      https://github.com/llvm/llvm-project/commit/9f0d8bac144c8eb1ca4aff823b2e2d5a0f990072
  Author: Valeriy Savchenko <vsavchenko at apple.com>
  Date:   2021-04-08 (Thu, 08 Apr 2021)

  Changed paths:
    M clang/lib/StaticAnalyzer/Checkers/DeadStoresChecker.cpp
    M clang/test/Analysis/dead-stores.c

  Log Message:
  -----------
  [analyzer] Fix dead store checker false positive

It is common to zero-initialize not only scalar variables,
but also structs.  This is also defensive programming and
we shouldn't complain about that.

rdar://34122265

Differential Revision: https://reviews.llvm.org/D99262




More information about the All-commits mailing list