[all-commits] [llvm/llvm-project] 0e4005: [clang-tidy] Skip declarations in system headers i...

Carlos Galvez via All-commits all-commits at lists.llvm.org
Sat Aug 2 03:20:46 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 0e40051565db1399b573b4bddc43c806ca86dc8d
      https://github.com/llvm/llvm-project/commit/0e40051565db1399b573b4bddc43c806ca86dc8d
  Author: Carlos Galvez <carlosgalvezp at gmail.com>
  Date:   2025-08-02 (Sat, 02 Aug 2025)

  Changed paths:
    M clang-tools-extra/clang-tidy/utils/RenamerClangTidyCheck.cpp
    M clang-tools-extra/docs/ReleaseNotes.rst

  Log Message:
  -----------
  [clang-tidy] Skip declarations in system headers in RenamerClangTidyC… (#151772)

…heck

One typically only wants to perform renaming operations in user code,
not in system headers (which are out of the user's control). Let's skip
those altogether.

This leads to performance improvements in clang-tidy. As a benchmark, I
run all checks on a .cpp file that #includes all C++ standard headers.

On trunk:

```
Suppressed 213362 warnings (213362 in non-user code).

real	0m14.422s
user	0m14.236s
sys	0m0.184s
```

On this patch:

```
Suppressed 75411 warnings (75411 in non-user code).

real	0m12.472s
user	0m12.334s
sys	0m0.136s
```

Co-authored-by: Carlos Gálvez <carlos.galvez at zenseact.com>



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list