Skip to content

Conversation

vanvoorden
Copy link

@vanvoorden vanvoorden commented Sep 5, 2025

Background

https://discourse.llvm.org/t/-/88192

Inspired by:

Searching through the repo, we see three main categories of changes:

  • Comments and Documentation
  • Constant Strings
  • Symbols

Ranking from "least" to "most" risky to land without causing any bugs or unintended consequences, let's start here with migrating comments and documentation.

Changes

  • sanity to soundness
  • sane to sound
  • insane to unsound
  • sanely to soundly

This diff is only intended to migrate comments and documentation. Please feel free to Request Changes if you find a constant string or symbol that was included by mistake. Thanks!

Copy link

github-actions bot commented Sep 5, 2025

Thank you for submitting a Pull Request (PR) to the LLVM Project!

This PR will be automatically labeled and the relevant teams will be notified.

If you wish to, you can add reviewers by using the "Reviewers" section on this page.

If this is not working for you, it is probably because you do not have write permissions for the repository. In which case you can instead tag reviewers by name in a comment by using @ followed by their GitHub username.

If you have received no comments on your PR for a week, you can request a review by "ping"ing the PR by adding a comment “Ping”. The common courtesy "ping" rate is once a week. Please remember that you are asking for valuable time from other developers.

If you have further questions, they may be answered by the LLVM GitHub User Guide.

You can also ask questions in a comment on this PR, on the LLVM Discord or on the forums.

@llvmbot llvmbot added the cmake Build system in general and CMake in particular label Sep 5, 2025
@llvmbot llvmbot added llvm:analysis Includes value tracking, cost tables and constant folding llvm:transforms llvm:binary-utilities llvm:adt flang:semantics flang:parser openmp:libomp OpenMP host runtime openmp:libomptarget OpenMP offload runtime offload clang:bytecode Issues for the clang bytecode constexpr interpreter labels Sep 5, 2025
@llvmbot
Copy link
Member

llvmbot commented Sep 5, 2025

@llvm/pr-subscribers-flang-driver
@llvm/pr-subscribers-llvm-globalisel
@llvm/pr-subscribers-lld-coff
@llvm/pr-subscribers-lld-macho
@llvm/pr-subscribers-clangd
@llvm/pr-subscribers-backend-mips
@llvm/pr-subscribers-mlir-llvm
@llvm/pr-subscribers-clang-static-analyzer-1

@llvm/pr-subscribers-clang-codegen

Author: Rick van Voorden (vanvoorden)

Changes

Background

Inspired by swiftlang/swift#71167.

Searching through the repo, we see three main categories of changes:

  • Comments and Documentation
  • Constant Strings
  • Symbols

Ranking from "least" to "most" risky to land without causing any bugs or unintended consequences, let's start here with migrating comments and documentation.

Changes

  • sanity to soundness
  • sane to sound
  • insane to unsound
  • sanely to soundly

Patch is 337.82 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/156995.diff

443 Files Affected:

  • (modified) bolt/lib/Passes/CMOVConversion.cpp (+1-1)
  • (modified) bolt/lib/Passes/IndirectCallPromotion.cpp (+1-1)
  • (modified) bolt/lib/Profile/YAMLProfileReader.cpp (+1-1)
  • (modified) bolt/lib/Rewrite/RewriteInstance.cpp (+2-2)
  • (modified) bolt/runtime/instr.cpp (+1-1)
  • (modified) bolt/test/AArch64/hook-fini.s (+1-1)
  • (modified) bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s (+1-1)
  • (modified) bolt/test/runtime/AArch64/hook-fini.test (+1-1)
  • (modified) bolt/tools/merge-fdata/merge-fdata.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/CodeCompletionStrings.cpp (+2-2)
  • (modified) clang-tools-extra/clangd/Compiler.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/XRefs.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/index/IndexAction.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/ClangdTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/QualityTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/RenameTests.cpp (+1-1)
  • (modified) clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp (+1-1)
  • (modified) clang/docs/AutomaticReferenceCounting.rst (+1-1)
  • (modified) clang/docs/InternalsManual.rst (+1-1)
  • (modified) clang/docs/Modules.rst (+1-1)
  • (modified) clang/docs/UsersManual.rst (+1-1)
  • (modified) clang/include/clang/Sema/Sema.h (+1-1)
  • (modified) clang/lib/AST/ASTStructuralEquivalence.cpp (+2-2)
  • (modified) clang/lib/AST/CommentSema.cpp (+1-1)
  • (modified) clang/lib/AST/TypePrinter.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGCXXABI.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGCall.cpp (+2-2)
  • (modified) clang/lib/CodeGen/CGExpr.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGStmt.cpp (+1-1)
  • (modified) clang/lib/Driver/Driver.cpp (+1-1)
  • (modified) clang/lib/Frontend/PrintPreprocessedOutput.cpp (+2-2)
  • (modified) clang/lib/Index/USRGeneration.cpp (+1-1)
  • (modified) clang/lib/Parse/ParseStmtAsm.cpp (+2-2)
  • (modified) clang/lib/Sema/SemaOpenACC.cpp (+1-1)
  • (modified) clang/lib/Sema/SemaOverload.cpp (+2-2)
  • (modified) clang/lib/Sema/SemaTemplateDeduction.cpp (+1-1)
  • (modified) clang/lib/StaticAnalyzer/Checkers/ArrayBoundChecker.cpp (+1-1)
  • (modified) clang/lib/StaticAnalyzer/Checkers/PthreadLockChecker.cpp (+1-1)
  • (modified) clang/test/AST/ByteCode/cxx11.cpp (+1-1)
  • (modified) clang/test/Analysis/return-value-guaranteed.cpp (+1-1)
  • (modified) clang/test/Analysis/std-variant-checker.cpp (+1-1)
  • (modified) clang/test/CodeGen/AArch64/inline-asm.c (+1-1)
  • (modified) clang/test/CodeGen/alloc-align-attr.c (+1-1)
  • (modified) clang/test/CodeGen/arm-target-features.c (+1-1)
  • (modified) clang/test/CodeGen/atomic-ops.c (+1-1)
  • (modified) clang/test/CodeGen/strictfp-elementwise-builtins.cpp (+1-1)
  • (modified) clang/test/CodeGen/union-init2.c (+1-1)
  • (modified) clang/test/CodeGenCXX/OmitRTTIComponentABI/simple-vtable-definition.cpp (+1-1)
  • (modified) clang/test/CodeGenCXX/cxx11-user-defined-literal.cpp (+1-1)
  • (modified) clang/test/CodeGenCXX/type-aware-allocators.cpp (+1-1)
  • (modified) clang/test/CodeGenHLSL/GlobalDestructors.hlsl (+1-1)
  • (modified) clang/test/CodeGenHLSL/RootSignature.hlsl (+1-1)
  • (modified) clang/test/Driver/aix-as.c (+1-1)
  • (modified) clang/test/Driver/aix-ld.c (+1-1)
  • (modified) clang/test/Driver/as-dwarf-cie.s (+1-1)
  • (modified) clang/test/Driver/fopenmp.c (+1-1)
  • (modified) clang/test/Driver/linux-header-search.cpp (+1-1)
  • (modified) clang/test/Driver/linux-ld.c (+1-1)
  • (modified) clang/test/Driver/solaris-ld-values.c (+1-1)
  • (modified) clang/test/Driver/solaris-ld-values.cpp (+1-1)
  • (modified) clang/test/Driver/solaris-ld.c (+1-1)
  • (modified) clang/test/PCH/floating-literal.c (+1-1)
  • (modified) clang/test/SemaCXX/constant-expression-cxx11.cpp (+1-1)
  • (modified) clang/test/SemaCXX/constant-expression-cxx14.cpp (+1-1)
  • (modified) clang/test/SemaCXX/enable_if.cpp (+1-1)
  • (modified) clang/test/SemaCXX/overload-resolution-deferred-templates.cpp (+1-1)
  • (modified) clang/test/SemaCXX/vtable_pointer_authentication_attribute.cpp (+2-2)
  • (modified) clang/test/SemaTemplate/canonical-expr-type.cpp (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/check-globals.test (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/global-hex-value-regex.test (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/global-value-regex.test (+1-1)
  • (modified) clang/unittests/Analysis/CFGTest.cpp (+1-1)
  • (modified) clang/unittests/Basic/SourceManagerTest.cpp (+1-1)
  • (modified) clang/utils/TableGen/ClangAttrEmitter.cpp (+1-1)
  • (modified) cmake/Modules/EnableLanguageNolink.cmake (+2-2)
  • (modified) compiler-rt/cmake/Modules/CompilerRTDarwinUtils.cmake (+1-1)
  • (modified) compiler-rt/cmake/Modules/CompilerRTUtils.cmake (+1-1)
  • (modified) compiler-rt/lib/asan/asan_internal.h (+1-1)
  • (modified) compiler-rt/lib/asan/asan_poisoning.cpp (+3-3)
  • (modified) compiler-rt/lib/asan/asan_stats.cpp (+2-2)
  • (modified) compiler-rt/lib/builtins/negdi2.c (+1-1)
  • (modified) compiler-rt/lib/builtins/negti2.c (+1-1)
  • (modified) compiler-rt/lib/fuzzer/tests/FuzzerUnittest.cpp (+1-1)
  • (modified) compiler-rt/lib/hwasan/hwasan_linux.cpp (+1-1)
  • (modified) compiler-rt/lib/memprof/memprof_stats.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc (+4-4)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_flag_parser.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_interceptors_ioctl_netbsd.inc (+4-4)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_libc.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_mac.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_stacktrace.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_stacktrace_sparc.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_win.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/tests/sanitizer_procmaps_test.cpp (+1-1)
  • (modified) compiler-rt/lib/scudo/standalone/report.h (+1-1)
  • (modified) compiler-rt/lib/tsan/rtl/CMakeLists.txt (+1-1)
  • (modified) compiler-rt/lib/tsan/rtl/tsan_rtl.cpp (+3-3)
  • (modified) compiler-rt/lib/tsan/rtl/tsan_rtl_access.cpp (+1-1)
  • (modified) compiler-rt/lib/ubsan/ubsan_type_hash.h (+1-1)
  • (modified) compiler-rt/lib/ubsan/ubsan_type_hash_win.cpp (+1-1)
  • (modified) compiler-rt/lib/xray/tests/CMakeLists.txt (+1-1)
  • (modified) compiler-rt/test/BlocksRuntime/byrefsanity.c (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/Posix/unpoison-alternate-stack.cpp (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/sanity_check_pure_c.c (+2-2)
  • (modified) compiler-rt/test/builtins/Unit/atomic_test.c (+1-1)
  • (modified) compiler-rt/test/builtins/Unit/lit.cfg.py (+1-1)
  • (modified) compiler-rt/test/fuzzer/fuzzer-custommutator.test (+1-1)
  • (modified) compiler-rt/test/fuzzer/reload.test (+1-1)
  • (modified) compiler-rt/test/hwasan/TestCases/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/hwasan/TestCases/sanitizer_malloc.cpp (+1-1)
  • (modified) compiler-rt/test/msan/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/safestack/canary.c (+1-1)
  • (modified) compiler-rt/utils/generate_netbsd_ioctls.awk (+3-3)
  • (modified) compiler-rt/utils/generate_netbsd_syscalls.awk (+1-1)
  • (modified) flang-rt/unittests/Runtime/CharacterTest.cpp (+1-1)
  • (modified) flang-rt/unittests/Runtime/ExternalIOTest.cpp (+1-1)
  • (modified) flang/lib/Decimal/decimal-to-binary.cpp (+1-1)
  • (modified) flang/lib/Evaluate/fold-character.cpp (+1-1)
  • (modified) flang/lib/Evaluate/formatting.cpp (+1-1)
  • (modified) flang/lib/Evaluate/integer.cpp (+1-1)
  • (modified) flang/lib/Frontend/CompilerInstance.cpp (+1-1)
  • (modified) flang/lib/Lower/Bridge.cpp (+1-1)
  • (modified) flang/lib/Lower/ConvertVariable.cpp (+1-1)
  • (modified) flang/lib/Optimizer/Builder/FIRBuilder.cpp (+1-1)
  • (modified) flang/lib/Parser/preprocessor.cpp (+1-1)
  • (modified) flang/test/Driver/fopenmp.f90 (+1-1)
  • (modified) flang/test/Fir/convert-to-llvm.fir (+1-1)
  • (modified) flang/test/Semantics/modfile55.cuf (+1-1)
  • (modified) flang/test/Semantics/resolve59.f90 (+1-1)
  • (modified) flang/test/Semantics/symbol19.f90 (+1-1)
  • (modified) flang/unittests/Frontend/CompilerInstanceTest.cpp (+1-1)
  • (modified) libcxx/docs/DesignDocs/FileTimeType.rst (+2-2)
  • (modified) libcxx/docs/Status/Cxx20Papers.csv (+1-1)
  • (modified) libcxx/include/__cxx03/__hash_table (+1-1)
  • (modified) libcxx/include/__cxx03/__tree (+1-1)
  • (modified) libcxx/include/__hash_table (+1-1)
  • (modified) libcxx/include/__tree (+1-1)
  • (modified) libcxx/test/libcxx-03/numerics/bit.ops.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/extents/assert.ctor_from_span.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/layout_stride/assert.conversion.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/mdspan/assert.size.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/debug/containers/sequence_container_iterators.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/input.output/filesystems/convert_file_time.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/numerics/bit.ops.pass.cpp (+1-1)
  • (modified) libcxx/test/std/atomics/atomics.lockfree/is_always_lock_free.pass.cpp (+1-1)
  • (modified) libcxx/test/std/atomics/atomics.ref/is_always_lock_free.pass.cpp (+1-1)
  • (modified) libcxx/test/std/concepts/concepts.lang/concept.convertible/convertible_to.pass.cpp (+1-1)
  • (modified) libcxx/test/std/concepts/concepts.lang/concept.swappable/swappable.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/container.adaptors/priority.queue/priqueue.cons/ctor_iter_constraint.compile.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/sequences/array/empty.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/sequences/array/max_size.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/extents/conversion.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/ctor.layout_right.pass.cpp (+2-2)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/ctor.mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/ctor.layout_left.pass.cpp (+2-2)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/ctor.mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_stride/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_stride/ctor.strided_mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_array.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_extents.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_integers.pass.cpp (+4-4)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_map.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_map_acc.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_span.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/types.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/filesystems/fs.op.funcs/fs.op.space/space.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/istringstream/istringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/stringstream/stringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/compare_strong_order_fallback.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/compare_weak_order_fallback.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/strong_order.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/weak_order.pass.cpp (+1-1)
  • (modified) libcxx/test/std/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/utf_sanity_check.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/c.math/hermite.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/exclusive.scan/exclusive_scan.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan_op.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan_op_init.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/numeric.ops.midpoint/midpoint.float.pass.cpp (+2-2)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.exclusive.scan/transform_exclusive_scan_init_bop_uop.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.inclusive.scan/transform_inclusive_scan_bop_uop.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.inclusive.scan/transform_inclusive_scan_bop_uop_init.pass.cpp (+1-1)
  • (modified) libcxx/test/std/strings/string.view/string.view.capacity/capacity.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/lock.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/try_lock.pass.cpp (+1-1)
  • (modified) libcxx/test/std/utilities/allocator.adaptor/allocator.adaptor.types/is_always_equal.pass.cpp (+1-1)
  • (modified) libcxx/test/std/utilities/meta/meta.const.eval/is_constant_evaluated.pass.cpp (+1-1)
  • (modified) libcxx/test/support/filesystem_test_helper.h (+1-1)
  • (modified) libcxx/test/support/test_comparisons.h (+1-1)
  • (modified) libcxxabi/src/stdlib_new_delete.cpp (+1-1)
  • (modified) libcxxabi/test/guard_threaded_test.pass.cpp (+1-1)
  • (modified) lld/ELF/InputSection.cpp (+1-1)
  • (modified) lld/ELF/ScriptParser.cpp (+1-1)
  • (modified) lld/include/lld/Common/ErrorHandler.h (+1-1)
  • (modified) lld/test/COFF/guard-warnings.s (+1-1)
  • (modified) lld/test/ELF/gc-sections-no-undef-error.s (+1-1)
  • (modified) lld/test/ELF/lto/save-temps-eq.ll (+1-1)
  • (modified) lld/test/MachO/eh-frame-personality-dedup.s (+1-1)
  • (modified) lld/test/MachO/icf-only-lsda-folded.s (+1-1)
  • (modified) lldb/examples/summaries/cocoa/objc_runtime.py (+4-4)
  • (modified) lldb/packages/Python/lldbsuite/test/dotest.py (+1-1)
  • (modified) lldb/source/API/SBCommandInterpreter.cpp (+2-2)
  • (modified) lldb/source/Commands/CommandCompletions.cpp (+1-1)
  • (modified) lldb/source/Commands/CommandObjectWatchpoint.cpp (+2-2)
  • (modified) lldb/source/Commands/CommandObjectWatchpointCommand.cpp (+1-1)
  • (modified) lldb/source/Core/SourceManager.cpp (+1-1)
  • (modified) lldb/source/Expression/FunctionCaller.cpp (+1-1)
  • (modified) lldb/source/Expression/REPL.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/Mips/ABISysV_mips64.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/PowerPC/ABISysV_ppc.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/X86/ABISysV_x86_64.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/X86/ABIWindows_x86_64.cpp (+1-1)
  • (modified) lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOS.cpp (+1-1)
  • (modified) lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp (+1-1)
  • (modified) lldb/source/Plugins/ExpressionParser/Clang/CppModuleConfiguration.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/FreeBSD/NativeProcessFreeBSD.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/NetBSD/NativeProcessNetBSD.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/elf-core/ProcessElfCore.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp (+2-2)
  • (modified) lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp (+2-2)
  • (modified) lldb/source/Plugins/Trace/intel-pt/TraceIntelPTBundleLoader.cpp (+1-1)
  • (modified) lldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp (+1-1)
  • (modified) lldb/source/Plugins/UnwindAssembly/x86/UnwindAssembly-x86.cpp (+2-2)
  • (modified) lldb/source/Symbol/Symbol.cpp (+2-2)
  • (modified) lldb/source/Target/RegisterContextUnwind.cpp (+1-1)
  • (modified) lldb/source/Target/ThreadPlanStepInRange.cpp (+1-1)
  • (modified) lldb/source/Target/ThreadPlanStepOverRange.cpp (+2-2)
  • (modified) lldb/source/Utility/ZipFile.cpp (+3-3)
  • (modified) lldb/test/API/api/check_public_api_headers/TestPublicAPIHeaders.py (+1-1)
  • (modified) lldb/test/API/commands/frame/recognizer/TestFrameRecognizer.py (+1-1)
  • (modified) lldb/test/API/commands/memory/read/TestMemoryRead.py (+1-1)
  • (modified) lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/invalid-string/TestDataFormatterLibcxxInvalidString.py (+1-1)
  • (modified) lldb/test/API/functionalities/data-formatter/stringprinter/main.cpp (+1-1)
  • (modified) lldb/test/API/functionalities/limit-debug-info/TestLimitDebugInfo.py (+2-2)
  • (modified) lldb/test/API/functionalities/process_crash_info/TestProcessCrashInfo.py (+1-1)
  • (modified) lldb/test/API/lang/c/array_types/TestArrayTypes.py (+5-5)
  • (modified) lldb/test/API/lang/cpp/dynamic-value/TestDynamicValue.py (+1-1)
  • (modified) lldb/test/API/lang/cpp/incomplete-types/members/TestCppIncompleteTypeMembers.py (+1-1)
  • (modified) lldb/test/API/macosx/no-nlist-memory-module/TestNoNlistsDylib.py (+1-1)
  • (modified) lldb/test/API/macosx/simulator/TestSimulatorPlatform.py (+1-1)
  • (modified) lldb/test/API/python_api/value/linked_list/TestValueAPILinkedList.py (+2-2)
  • (modified) lldb/test/API/sanity/TestModuleCacheSanity.py (+1-1)
  • (modified) lldb/test/API/sanity/TestReprStrEquality.py (+1-1)
  • (modified) lldb/test/API/sanity/TestSettingSkipping.py (+1-1)
  • (modified) lldb/test/API/tools/lldb-server/memory-tagging/TestGdbRemoteMemoryTagging.py (+2-2)
  • (modified) lldb/test/Shell/REPL/Basic.test (+1-1)
  • (modified) lldb/test/Shell/Settings/TestModuleCacheSanity.test (+1-1)
  • (modified) lldb/tools/debugserver/source/MacOSX/arm64/DNBArchImplARM64.cpp (+1-1)
  • (modified) lldb/tools/lldb-rpc-gen/server/RPCServerSourceEmitter.cpp (+1-1)
  • (modified) lldb/unittests/Interpreter/TestCompletion.cpp (+1-1)
  • (modified) llvm/CMakeLists.txt (+1-1)
  • (modified) llvm/cmake/platforms/WinMsvc.cmake (+1-1)
  • (modified) llvm/docs/Atomics.rst (+1-1)
  • (modified) llvm/docs/CMake.rst (+1-1)
  • (modified) llvm/docs/CodingStandards.rst (+1-1)
  • (modified) llvm/docs/Contributing.rst (+1-1)
  • (modified) llvm/docs/Frontend/PerformanceTips.rst (+1-1)
  • (modified) llvm/docs/GettingStarted.rst (+1-1)
  • (modified) llvm/docs/LibFuzzer.rst (+1-1)
  • (modified) llvm/include/llvm-c/Core.h (+1-1)
  • (modified) llvm/include/llvm/ADT/APSInt.h (+1-1)
  • (modified) llvm/include/llvm/ADT/IntervalMap.h (+2-2)
  • (modified) llvm/include/llvm/CodeGen/MachineRegisterInfo.h (+1-1)
  • (modified) llvm/include/llvm/CodeGen/SelectionDAG.h (+1-1)
  • (modified) llvm/include/llvm/DebugInfo/DWARF/DWARFDebugFrame.h (+1-1)
  • (modified) llvm/include/llvm/IR/IntrinsicsARM.td (+1-1)
  • (modified) llvm/include/llvm/ProfileData/MemProfReader.h (+3-3)
diff --git a/bolt/lib/Passes/CMOVConversion.cpp b/bolt/lib/Passes/CMOVConversion.cpp
index cdd99b55207e0..10372416a9acd 100644
--- a/bolt/lib/Passes/CMOVConversion.cpp
+++ b/bolt/lib/Passes/CMOVConversion.cpp
@@ -66,7 +66,7 @@ bool isIfThenSubgraph(const BinaryBasicBlock &LHS,
   if (LHS.pred_size() != 2 || RHS.pred_size() != 1)
     return false;
 
-  // Sanity check
+  // Soundness check
   BinaryBasicBlock *Predecessor = *RHS.pred_begin();
   assert(Predecessor && LHS.isPredecessor(Predecessor) && "invalid subgraph");
   (void)Predecessor;
diff --git a/bolt/lib/Passes/IndirectCallPromotion.cpp b/bolt/lib/Passes/IndirectCallPromotion.cpp
index 8a01cb974c5da..dff1989c016b5 100644
--- a/bolt/lib/Passes/IndirectCallPromotion.cpp
+++ b/bolt/lib/Passes/IndirectCallPromotion.cpp
@@ -597,7 +597,7 @@ IndirectCallPromotion::findCallTargetSymbols(std::vector<Callsite> &Targets,
       std::vector<uint64_t>({JTIndex}).swap(NewTargets.back().JTIndices);
       llvm::erase(Target.JTIndices, JTIndex);
 
-      // Keep fixCFG counts sane if more indices use this same target later
+      // Keep fixCFG counts sound if more indices use this same target later
       assert(IndicesPerTarget[Target.To.Sym] > 0 && "wrong map");
       NewTargets.back().Branches =
           Target.Branches / IndicesPerTarget[Target.To.Sym];
diff --git a/bolt/lib/Profile/YAMLProfileReader.cpp b/bolt/lib/Profile/YAMLProfileReader.cpp
index 086e47b661e10..62190397b2be3 100644
--- a/bolt/lib/Profile/YAMLProfileReader.cpp
+++ b/bolt/lib/Profile/YAMLProfileReader.cpp
@@ -385,7 +385,7 @@ Error YAMLProfileReader::preprocessProfile(BinaryContext &BC) {
     return errorCodeToError(YamlInput.error());
   }
 
-  // Sanity check.
+  // Soundness check.
   if (YamlBP.Header.Version != 1)
     return make_error<StringError>(
         Twine("cannot read profile : unsupported version"),
diff --git a/bolt/lib/Rewrite/RewriteInstance.cpp b/bolt/lib/Rewrite/RewriteInstance.cpp
index a6e4dbc9c192f..871453b0ec5db 100644
--- a/bolt/lib/Rewrite/RewriteInstance.cpp
+++ b/bolt/lib/Rewrite/RewriteInstance.cpp
@@ -637,7 +637,7 @@ Error RewriteInstance::discoverStorage() {
     // If user specified a custom address where we should start writing new
     // data, honor that.
     NextAvailableAddress = opts::CustomAllocationVMA;
-    // Sanity check the user-supplied address and emit warnings if something
+    // Soundness check the user-supplied address and emit warnings if something
     // seems off.
     for (const ELF64LE::Phdr &Phdr : PHs) {
       switch (Phdr.p_type) {
@@ -2985,7 +2985,7 @@ void RewriteInstance::handleRelocation(const SectionRef &RelocatedSection,
     }
 
     if (BinaryData *BD = BC->getBinaryDataContainingAddress(SymbolAddress)) {
-      // Note: this assertion is trying to check sanity of BinaryData objects
+      // Note: this assertion is trying to check soundness of BinaryData objects
       // but AArch64 and RISCV has inferred and incomplete object locations
       // coming from GOT/TLS or any other non-trivial relocation (that requires
       // creation of sections and whose symbol address is not really what should
diff --git a/bolt/runtime/instr.cpp b/bolt/runtime/instr.cpp
index 1f54a500dbf98..97b49327ac484 100644
--- a/bolt/runtime/instr.cpp
+++ b/bolt/runtime/instr.cpp
@@ -819,7 +819,7 @@ ProfileWriterContext readDescriptions() {
 #endif
 
 #if !defined(__APPLE__)
-/// Debug by printing overall metadata global numbers to check it is sane
+/// Debug by printing overall metadata global numbers to check it is sound
 void printStats(const ProfileWriterContext &Ctx) {
   char StatMsg[BufSize];
   char *StatPtr = StatMsg;
diff --git a/bolt/test/AArch64/hook-fini.s b/bolt/test/AArch64/hook-fini.s
index 4f321d463ef32..4051546724748 100644
--- a/bolt/test/AArch64/hook-fini.s
+++ b/bolt/test/AArch64/hook-fini.s
@@ -4,7 +4,7 @@
 ## dynamic).
 ## All tests perform the following steps:
 ## - Compile and link for the case to be tested
-## - Some sanity-checks on the dynamic section and relocations in the binary to
+## - Some soundness-checks on the dynamic section and relocations in the binary to
 ##   verify it has the shape we want for testing:
 ##   - DT_FINI or DT_FINI_ARRAY in dynamic section
 ##   - No relative relocations for non-PIE
diff --git a/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s b/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
index 8e991fade2c86..c0a69a75b0d1b 100644
--- a/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
+++ b/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
@@ -272,7 +272,7 @@ lr_clobbered_nocfg:
         ret
         .size lr_clobbered_nocfg, .-lr_clobbered_nocfg
 
-/// Now do a basic sanity check on every different Authentication instruction:
+/// Now do a basic soundness check on every different Authentication instruction:
 
         .globl  f_autiasp
         .type   f_autiasp,@function
diff --git a/bolt/test/runtime/AArch64/hook-fini.test b/bolt/test/runtime/AArch64/hook-fini.test
index 8d23b21b6d612..43cc832e429ed 100644
--- a/bolt/test/runtime/AArch64/hook-fini.test
+++ b/bolt/test/runtime/AArch64/hook-fini.test
@@ -4,7 +4,7 @@
 # dynamic).
 # All tests perform the following steps:
 # - Compile and link for the case to be tested
-# - Some sanity-checks on the dynamic section and relocations in the binary to
+# - Some soundness-checks on the dynamic section and relocations in the binary to
 #   verify it has the shape we want for testing:
 #   - DT_FINI or DT_FINI_ARRAY in dynamic section
 #   - No relative relocations for non-PIE
diff --git a/bolt/tools/merge-fdata/merge-fdata.cpp b/bolt/tools/merge-fdata/merge-fdata.cpp
index cfcb9373548a1..9e55ad39427d4 100644
--- a/bolt/tools/merge-fdata/merge-fdata.cpp
+++ b/bolt/tools/merge-fdata/merge-fdata.cpp
@@ -428,7 +428,7 @@ int main(int argc, char **argv) {
     if (YamlInput.error())
       report_error(InputDataFilename, YamlInput.error());
 
-    // Sanity check.
+    // Soundness check.
     if (BP.Header.Version != 1) {
       errs() << "Unable to merge data from profile using version "
              << BP.Header.Version << '\n';
diff --git a/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp b/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
index d911b58cb8b7e..4b8b411bcc2ef 100644
--- a/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
+++ b/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
@@ -40,7 +40,7 @@ void ExplicitMakePairCheck::check(const MatchFinder::MatchResult &Result) {
   const auto *Call = Result.Nodes.getNodeAs<CallExpr>("call");
   const auto *DeclRef = Result.Nodes.getNodeAs<DeclRefExpr>("declref");
 
-  // Sanity check: The use might have overriden ::std::make_pair.
+  // Soundness check: The use might have overriden ::std::make_pair.
   if (Call->getNumArgs() != 2)
     return;
 
diff --git a/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp b/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
index 3f5cd4b473903..ac66c5bc5d66a 100644
--- a/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
+++ b/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
@@ -99,7 +99,7 @@ void MultiwayPathsCoveredCheck::check(const MatchFinder::MatchResult &Result) {
   bool SwitchHasDefault = false;
   std::tie(SwitchCaseCount, SwitchHasDefault) = countCaseLabels(Switch);
 
-  // Checks the sanity of 'switch' statements that actually do define
+  // Checks the soundness of 'switch' statements that actually do define
   // a default branch but might be degenerated by having no or only one case.
   if (SwitchHasDefault) {
     handleSwitchWithDefault(Switch, SwitchCaseCount);
diff --git a/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp b/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
index 712f390765957..f22118d5cb7e4 100644
--- a/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
+++ b/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
@@ -92,7 +92,7 @@ template <typename T, unsigned SmallSize> class SmartSmallSetVector {
   void populateSet() {
     assert(Set.empty() && "Should not have already utilized the Set.");
     // Magical growth factor prediction - to how many elements do we expect to
-    // sanely grow after switching away from small-size storage?
+    // soundly grow after switching away from small-size storage?
     const size_t NewMaxElts = 4 * Vector.size();
     Vector.reserve(NewMaxElts);
     Set.reserve(NewMaxElts);
diff --git a/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp b/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
index 2f59aaa86b157..b0e4efcbc5cba 100644
--- a/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
+++ b/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
@@ -133,7 +133,7 @@ struct CognitiveComplexity final {
                 "that in terms of stack usage. "
                 "Thus, it is good to minimize the size of the Detail struct.");
   SmallVector<Detail, DefaultLimit> Details; // 25 elements is 200 bytes.
-  // Yes, 25 is a magic number. This is the seemingly-sane default for the
+  // Yes, 25 is a magic number. This is the seemingly-sound default for the
   // upper limit for function cognitive complexity. Thus it would make sense
   // to avoid allocations for any function that does not violate the limit.
 
diff --git a/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp b/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
index 6bb8c394f75cc..1aaad01dea13f 100644
--- a/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
+++ b/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
@@ -61,7 +61,7 @@ void NamedParameterCheck::check(const MatchFinder::MatchResult &Result) {
         Parm->getType()->isSpecificBuiltinType(BuiltinType::Int))
       continue;
 
-    // Sanity check the source locations.
+    // Soundness check the source locations.
     if (!Parm->getLocation().isValid() || Parm->getLocation().isMacroID() ||
         !SM.isWrittenInSameFile(Parm->getBeginLoc(), Parm->getLocation()))
       continue;
diff --git a/clang-tools-extra/clangd/CodeCompletionStrings.cpp b/clang-tools-extra/clangd/CodeCompletionStrings.cpp
index 9c4241b54057a..a26b36db7ecad 100644
--- a/clang-tools-extra/clangd/CodeCompletionStrings.cpp
+++ b/clang-tools-extra/clangd/CodeCompletionStrings.cpp
@@ -123,7 +123,7 @@ std::string getDeclComment(const ASTContext &Ctx, const NamedDecl &Decl) {
     if (!RC)
       return "";
 
-    // Sanity check that the comment does not come from the PCH. We choose to
+    // Soundness check that the comment does not come from the PCH. We choose to
     // not write them into PCH, because they are racy and slow to load.
     assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
 
@@ -146,7 +146,7 @@ std::string getDeclComment(const ASTContext &Ctx, const NamedDecl &Decl) {
     RC = getCompletionComment(Ctx, &Decl);
     if (!RC)
       return "";
-    // Sanity check that the comment does not come from the PCH. We choose to
+    // Soundness check that the comment does not come from the PCH. We choose to
     // not write them into PCH, because they are racy and slow to load.
     assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
     Doc = RC->getFormattedText(Ctx.getSourceManager(), Ctx.getDiagnostics());
diff --git a/clang-tools-extra/clangd/Compiler.cpp b/clang-tools-extra/clangd/Compiler.cpp
index 8b3865c8a8e5c..ba8766663c411 100644
--- a/clang-tools-extra/clangd/Compiler.cpp
+++ b/clang-tools-extra/clangd/Compiler.cpp
@@ -100,7 +100,7 @@ buildCompilerInvocation(const ParseInputs &Inputs, clang::DiagnosticConsumer &D,
   std::vector<const char *> ArgStrs;
   ArgStrs.reserve(Argv.size() + 1);
   // In asserts builds, CompilerInvocation redundantly reads/parses cc1 args as
-  // a sanity test. This is not useful to clangd, and costs 10% of test time.
+  // a soundness test. This is not useful to clangd, and costs 10% of test time.
   // To avoid mismatches between assert/production builds, disable it always.
   ArgStrs = {Argv.front().c_str(), "-Xclang", "-no-round-trip-args"};
   for (const auto &S : Argv.drop_front())
diff --git a/clang-tools-extra/clangd/XRefs.cpp b/clang-tools-extra/clangd/XRefs.cpp
index e1c50f906de08..17141a52afc6c 100644
--- a/clang-tools-extra/clangd/XRefs.cpp
+++ b/clang-tools-extra/clangd/XRefs.cpp
@@ -972,7 +972,7 @@ class ReferenceFinder : public index::IndexDataConsumer {
                      llvm::dyn_cast_or_null<ObjCMethodDecl>(ASTNode.OrigD)) {
         OMD->getSelectorLocs(Locs);
       }
-      // Sanity check: we expect the *first* token to match the reported loc.
+      // Soundness check: we expect the *first* token to match the reported loc.
       // Otherwise, maybe it was e.g. some other kind of reference to a Decl.
       if (!Locs.empty() && Locs.front() != Loc)
         Locs.clear(); // First token doesn't match, assume our guess was wrong.
diff --git a/clang-tools-extra/clangd/index/IndexAction.cpp b/clang-tools-extra/clangd/index/IndexAction.cpp
index ed56c2a9d2e81..d9d9cd0f40942 100644
--- a/clang-tools-extra/clangd/index/IndexAction.cpp
+++ b/clang-tools-extra/clangd/index/IndexAction.cpp
@@ -106,7 +106,7 @@ struct IncludeGraphCollector : public PPCallbacks {
     NodeForIncluding.first->getValue().DirectIncludes.push_back(NodeForInclude);
   }
 
-  // Sanity check to ensure we have already populated a skipped file.
+  // Soundness check to ensure we have already populated a skipped file.
   void FileSkipped(const FileEntryRef &SkippedFile, const Token &FilenameTok,
                    SrcMgr::CharacteristicKind FileType) override {
 #ifndef NDEBUG
diff --git a/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp b/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
index ada14c9939318..1c443c50866e2 100644
--- a/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
+++ b/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
@@ -854,7 +854,7 @@ TEST(BackgroundQueueTest, Progress) {
   using testing::AnyOf;
   BackgroundQueue::Stats S;
   BackgroundQueue Q([&](BackgroundQueue::Stats New) {
-    // Verify values are sane.
+    // Verify values are sound.
     // Items are enqueued one at a time (at least in this test).
     EXPECT_THAT(New.Enqueued, AnyOf(S.Enqueued, S.Enqueued + 1));
     // Items are completed one at a time.
diff --git a/clang-tools-extra/clangd/unittests/ClangdTests.cpp b/clang-tools-extra/clangd/unittests/ClangdTests.cpp
index 9ea7c3e02411d..63c92671a621a 100644
--- a/clang-tools-extra/clangd/unittests/ClangdTests.cpp
+++ b/clang-tools-extra/clangd/unittests/ClangdTests.cpp
@@ -919,7 +919,7 @@ int d;
   StartSecond.wait();
   Server.addDocument(FooCpp, SourceContentsWithoutErrors);
   ASSERT_TRUE(Server.blockUntilIdleForTest()) << "Waiting for diagnostics";
-  ASSERT_EQ(DiagConsumer.Count, 2); // Sanity check - we actually ran both?
+  ASSERT_EQ(DiagConsumer.Count, 2); // Soundness check - we actually ran both?
 }
 
 TEST(ClangdServerTest, FormatCode) {
diff --git a/clang-tools-extra/clangd/unittests/QualityTests.cpp b/clang-tools-extra/clangd/unittests/QualityTests.cpp
index 4954659a45e02..1e6d34d58fcc1 100644
--- a/clang-tools-extra/clangd/unittests/QualityTests.cpp
+++ b/clang-tools-extra/clangd/unittests/QualityTests.cpp
@@ -10,7 +10,7 @@
 // For interesting cases, both exact scores and "X beats Y" are too brittle to
 // make good hard assertions.
 //
-// Here we test the signal extraction and sanity-check that signals point in
+// Here we test the signal extraction and soundness-check that signals point in
 // the right direction. This should be supplemented by quality metrics which
 // we can compute from a corpus of queries and preferred rankings.
 //
diff --git a/clang-tools-extra/clangd/unittests/RenameTests.cpp b/clang-tools-extra/clangd/unittests/RenameTests.cpp
index 5d2a77b62a219..b23d62e37e068 100644
--- a/clang-tools-extra/clangd/unittests/RenameTests.cpp
+++ b/clang-tools-extra/clangd/unittests/RenameTests.cpp
@@ -1444,7 +1444,7 @@ TEST(RenameTest, IndexMergeMainFile) {
   EXPECT_THAT(Results.GlobalChanges[Main].asTextEdits(),
               ElementsAre(newText("xPrime")));
 
-  // Sanity check: we do expect to see index results!
+  // Soundness check: we do expect to see index results!
   TU.Filename = "other.cc";
   Results = Rename(TU.index().get());
   EXPECT_THAT(Results.GlobalChanges.keys(),
diff --git a/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp b/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
index 4d1ca669b8d03..c846291329831 100644
--- a/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
+++ b/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
@@ -1,4 +1,4 @@
-// Sanity-check. Run without modules:
+// Soundness-check. Run without modules:
 // RUN: rm -rf %t
 // RUN: mkdir %t
 // RUN: cp %S/Inputs/expand-modular-headers-ppcallbacks/* %t/
diff --git a/clang/docs/AutomaticReferenceCounting.rst b/clang/docs/AutomaticReferenceCounting.rst
index 80bbd25121148..b10e3635e1d5b 100644
--- a/clang/docs/AutomaticReferenceCounting.rst
+++ b/clang/docs/AutomaticReferenceCounting.rst
@@ -1993,7 +1993,7 @@ A program is ill-formed if it refers to the ``NSAutoreleasePool`` class.
   dependencies between two calls.  It is also very easy to accidentally forget
   to drain an autorelease pool when using the manual API, and this can
   significantly inflate the process's high-water-mark.  The introduction of a
-  new scope is unfortunate but basically required for sane interaction with the
+  new scope is unfortunate but basically required for sound interaction with the
   rest of the language.  Not draining the pool during an unwind is apparently
   required by the Objective-C exceptions implementation.
 
diff --git a/clang/docs/InternalsManual.rst b/clang/docs/InternalsManual.rst
index bd742273f4ed5..411d3ee3ecec0 100644
--- a/clang/docs/InternalsManual.rst
+++ b/clang/docs/InternalsManual.rst
@@ -82,7 +82,7 @@ using it.  From this file, :program:`tblgen` generates the unique ID of the
 diagnostic, the severity of the diagnostic and the English translation + format
 string.
 
-There is little sanity with the naming of the unique ID's right now.  Some
+There is little soundness with the naming of the unique ID's right now.  Some
 start with ``err_``, ``warn_``, ``ext_`` to encode the severity into the name.
 Since the enum is referenced in the C++ code that produces the diagnostic, it
 is somewhat useful for it to be reasonably short.
diff --git a/clang/docs/Modules.rst b/clang/docs/Modules.rst
index acbe45e0be970..515f5838dbe49 100644
--- a/clang/docs/Modules.rst
+++ b/clang/docs/Modules.rst
@@ -1099,7 +1099,7 @@ The module maps will be written using the `module map language`_, which provides
   Headers are often missing ``#include`` directives for headers that they actually depend on. As with the problem of conflicting definitions, this only affects unlucky users who don't happen to include headers in the right order. With modules, the headers of a particular module will be parsed in isolation, so the module may fail to build if there are missing includes.
 
 **Headers that vend multiple APIs at different times**
-  Some systems have headers that contain a number of different kinds of API definitions, only some of which are made available with a given include. For example, the header may vend ``size_t`` only when the macro ``__need_size_t`` is defined before that header is included, and also vend ``wchar_t`` only when the macro ``__need_wchar_t`` is defined. Such headers are often included many times in a single translation unit, and will have no include guards. There is no sane way to map this header to a submodule. One can either eliminate the header (e.g., by splitting it into separate headers, one per actual API) or simply ``exclude`` it in the module map.
+  Some systems have headers that contain a number of different kinds of API definitions, only some of which are made available with a given include. For example, the header may vend ``size_t`` only when the macro ``__need_size_t`` is defined before that header is included, and also vend...
[truncated]

@llvmbot
Copy link
Member

llvmbot commented Sep 5, 2025

@llvm/pr-subscribers-backend-risc-v

Author: Rick van Voorden (vanvoorden)

Changes

Background

Inspired by swiftlang/swift#71167.

Searching through the repo, we see three main categories of changes:

  • Comments and Documentation
  • Constant Strings
  • Symbols

Ranking from "least" to "most" risky to land without causing any bugs or unintended consequences, let's start here with migrating comments and documentation.

Changes

  • sanity to soundness
  • sane to sound
  • insane to unsound
  • sanely to soundly

Patch is 337.82 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/156995.diff

443 Files Affected:

  • (modified) bolt/lib/Passes/CMOVConversion.cpp (+1-1)
  • (modified) bolt/lib/Passes/IndirectCallPromotion.cpp (+1-1)
  • (modified) bolt/lib/Profile/YAMLProfileReader.cpp (+1-1)
  • (modified) bolt/lib/Rewrite/RewriteInstance.cpp (+2-2)
  • (modified) bolt/runtime/instr.cpp (+1-1)
  • (modified) bolt/test/AArch64/hook-fini.s (+1-1)
  • (modified) bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s (+1-1)
  • (modified) bolt/test/runtime/AArch64/hook-fini.test (+1-1)
  • (modified) bolt/tools/merge-fdata/merge-fdata.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/CodeCompletionStrings.cpp (+2-2)
  • (modified) clang-tools-extra/clangd/Compiler.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/XRefs.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/index/IndexAction.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/ClangdTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/QualityTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/RenameTests.cpp (+1-1)
  • (modified) clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp (+1-1)
  • (modified) clang/docs/AutomaticReferenceCounting.rst (+1-1)
  • (modified) clang/docs/InternalsManual.rst (+1-1)
  • (modified) clang/docs/Modules.rst (+1-1)
  • (modified) clang/docs/UsersManual.rst (+1-1)
  • (modified) clang/include/clang/Sema/Sema.h (+1-1)
  • (modified) clang/lib/AST/ASTStructuralEquivalence.cpp (+2-2)
  • (modified) clang/lib/AST/CommentSema.cpp (+1-1)
  • (modified) clang/lib/AST/TypePrinter.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGCXXABI.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGCall.cpp (+2-2)
  • (modified) clang/lib/CodeGen/CGExpr.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGStmt.cpp (+1-1)
  • (modified) clang/lib/Driver/Driver.cpp (+1-1)
  • (modified) clang/lib/Frontend/PrintPreprocessedOutput.cpp (+2-2)
  • (modified) clang/lib/Index/USRGeneration.cpp (+1-1)
  • (modified) clang/lib/Parse/ParseStmtAsm.cpp (+2-2)
  • (modified) clang/lib/Sema/SemaOpenACC.cpp (+1-1)
  • (modified) clang/lib/Sema/SemaOverload.cpp (+2-2)
  • (modified) clang/lib/Sema/SemaTemplateDeduction.cpp (+1-1)
  • (modified) clang/lib/StaticAnalyzer/Checkers/ArrayBoundChecker.cpp (+1-1)
  • (modified) clang/lib/StaticAnalyzer/Checkers/PthreadLockChecker.cpp (+1-1)
  • (modified) clang/test/AST/ByteCode/cxx11.cpp (+1-1)
  • (modified) clang/test/Analysis/return-value-guaranteed.cpp (+1-1)
  • (modified) clang/test/Analysis/std-variant-checker.cpp (+1-1)
  • (modified) clang/test/CodeGen/AArch64/inline-asm.c (+1-1)
  • (modified) clang/test/CodeGen/alloc-align-attr.c (+1-1)
  • (modified) clang/test/CodeGen/arm-target-features.c (+1-1)
  • (modified) clang/test/CodeGen/atomic-ops.c (+1-1)
  • (modified) clang/test/CodeGen/strictfp-elementwise-builtins.cpp (+1-1)
  • (modified) clang/test/CodeGen/union-init2.c (+1-1)
  • (modified) clang/test/CodeGenCXX/OmitRTTIComponentABI/simple-vtable-definition.cpp (+1-1)
  • (modified) clang/test/CodeGenCXX/cxx11-user-defined-literal.cpp (+1-1)
  • (modified) clang/test/CodeGenCXX/type-aware-allocators.cpp (+1-1)
  • (modified) clang/test/CodeGenHLSL/GlobalDestructors.hlsl (+1-1)
  • (modified) clang/test/CodeGenHLSL/RootSignature.hlsl (+1-1)
  • (modified) clang/test/Driver/aix-as.c (+1-1)
  • (modified) clang/test/Driver/aix-ld.c (+1-1)
  • (modified) clang/test/Driver/as-dwarf-cie.s (+1-1)
  • (modified) clang/test/Driver/fopenmp.c (+1-1)
  • (modified) clang/test/Driver/linux-header-search.cpp (+1-1)
  • (modified) clang/test/Driver/linux-ld.c (+1-1)
  • (modified) clang/test/Driver/solaris-ld-values.c (+1-1)
  • (modified) clang/test/Driver/solaris-ld-values.cpp (+1-1)
  • (modified) clang/test/Driver/solaris-ld.c (+1-1)
  • (modified) clang/test/PCH/floating-literal.c (+1-1)
  • (modified) clang/test/SemaCXX/constant-expression-cxx11.cpp (+1-1)
  • (modified) clang/test/SemaCXX/constant-expression-cxx14.cpp (+1-1)
  • (modified) clang/test/SemaCXX/enable_if.cpp (+1-1)
  • (modified) clang/test/SemaCXX/overload-resolution-deferred-templates.cpp (+1-1)
  • (modified) clang/test/SemaCXX/vtable_pointer_authentication_attribute.cpp (+2-2)
  • (modified) clang/test/SemaTemplate/canonical-expr-type.cpp (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/check-globals.test (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/global-hex-value-regex.test (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/global-value-regex.test (+1-1)
  • (modified) clang/unittests/Analysis/CFGTest.cpp (+1-1)
  • (modified) clang/unittests/Basic/SourceManagerTest.cpp (+1-1)
  • (modified) clang/utils/TableGen/ClangAttrEmitter.cpp (+1-1)
  • (modified) cmake/Modules/EnableLanguageNolink.cmake (+2-2)
  • (modified) compiler-rt/cmake/Modules/CompilerRTDarwinUtils.cmake (+1-1)
  • (modified) compiler-rt/cmake/Modules/CompilerRTUtils.cmake (+1-1)
  • (modified) compiler-rt/lib/asan/asan_internal.h (+1-1)
  • (modified) compiler-rt/lib/asan/asan_poisoning.cpp (+3-3)
  • (modified) compiler-rt/lib/asan/asan_stats.cpp (+2-2)
  • (modified) compiler-rt/lib/builtins/negdi2.c (+1-1)
  • (modified) compiler-rt/lib/builtins/negti2.c (+1-1)
  • (modified) compiler-rt/lib/fuzzer/tests/FuzzerUnittest.cpp (+1-1)
  • (modified) compiler-rt/lib/hwasan/hwasan_linux.cpp (+1-1)
  • (modified) compiler-rt/lib/memprof/memprof_stats.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc (+4-4)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_flag_parser.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_interceptors_ioctl_netbsd.inc (+4-4)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_libc.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_mac.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_stacktrace.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_stacktrace_sparc.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_win.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/tests/sanitizer_procmaps_test.cpp (+1-1)
  • (modified) compiler-rt/lib/scudo/standalone/report.h (+1-1)
  • (modified) compiler-rt/lib/tsan/rtl/CMakeLists.txt (+1-1)
  • (modified) compiler-rt/lib/tsan/rtl/tsan_rtl.cpp (+3-3)
  • (modified) compiler-rt/lib/tsan/rtl/tsan_rtl_access.cpp (+1-1)
  • (modified) compiler-rt/lib/ubsan/ubsan_type_hash.h (+1-1)
  • (modified) compiler-rt/lib/ubsan/ubsan_type_hash_win.cpp (+1-1)
  • (modified) compiler-rt/lib/xray/tests/CMakeLists.txt (+1-1)
  • (modified) compiler-rt/test/BlocksRuntime/byrefsanity.c (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/Posix/unpoison-alternate-stack.cpp (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/sanity_check_pure_c.c (+2-2)
  • (modified) compiler-rt/test/builtins/Unit/atomic_test.c (+1-1)
  • (modified) compiler-rt/test/builtins/Unit/lit.cfg.py (+1-1)
  • (modified) compiler-rt/test/fuzzer/fuzzer-custommutator.test (+1-1)
  • (modified) compiler-rt/test/fuzzer/reload.test (+1-1)
  • (modified) compiler-rt/test/hwasan/TestCases/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/hwasan/TestCases/sanitizer_malloc.cpp (+1-1)
  • (modified) compiler-rt/test/msan/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/safestack/canary.c (+1-1)
  • (modified) compiler-rt/utils/generate_netbsd_ioctls.awk (+3-3)
  • (modified) compiler-rt/utils/generate_netbsd_syscalls.awk (+1-1)
  • (modified) flang-rt/unittests/Runtime/CharacterTest.cpp (+1-1)
  • (modified) flang-rt/unittests/Runtime/ExternalIOTest.cpp (+1-1)
  • (modified) flang/lib/Decimal/decimal-to-binary.cpp (+1-1)
  • (modified) flang/lib/Evaluate/fold-character.cpp (+1-1)
  • (modified) flang/lib/Evaluate/formatting.cpp (+1-1)
  • (modified) flang/lib/Evaluate/integer.cpp (+1-1)
  • (modified) flang/lib/Frontend/CompilerInstance.cpp (+1-1)
  • (modified) flang/lib/Lower/Bridge.cpp (+1-1)
  • (modified) flang/lib/Lower/ConvertVariable.cpp (+1-1)
  • (modified) flang/lib/Optimizer/Builder/FIRBuilder.cpp (+1-1)
  • (modified) flang/lib/Parser/preprocessor.cpp (+1-1)
  • (modified) flang/test/Driver/fopenmp.f90 (+1-1)
  • (modified) flang/test/Fir/convert-to-llvm.fir (+1-1)
  • (modified) flang/test/Semantics/modfile55.cuf (+1-1)
  • (modified) flang/test/Semantics/resolve59.f90 (+1-1)
  • (modified) flang/test/Semantics/symbol19.f90 (+1-1)
  • (modified) flang/unittests/Frontend/CompilerInstanceTest.cpp (+1-1)
  • (modified) libcxx/docs/DesignDocs/FileTimeType.rst (+2-2)
  • (modified) libcxx/docs/Status/Cxx20Papers.csv (+1-1)
  • (modified) libcxx/include/__cxx03/__hash_table (+1-1)
  • (modified) libcxx/include/__cxx03/__tree (+1-1)
  • (modified) libcxx/include/__hash_table (+1-1)
  • (modified) libcxx/include/__tree (+1-1)
  • (modified) libcxx/test/libcxx-03/numerics/bit.ops.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/extents/assert.ctor_from_span.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/layout_stride/assert.conversion.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/mdspan/assert.size.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/debug/containers/sequence_container_iterators.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/input.output/filesystems/convert_file_time.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/numerics/bit.ops.pass.cpp (+1-1)
  • (modified) libcxx/test/std/atomics/atomics.lockfree/is_always_lock_free.pass.cpp (+1-1)
  • (modified) libcxx/test/std/atomics/atomics.ref/is_always_lock_free.pass.cpp (+1-1)
  • (modified) libcxx/test/std/concepts/concepts.lang/concept.convertible/convertible_to.pass.cpp (+1-1)
  • (modified) libcxx/test/std/concepts/concepts.lang/concept.swappable/swappable.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/container.adaptors/priority.queue/priqueue.cons/ctor_iter_constraint.compile.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/sequences/array/empty.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/sequences/array/max_size.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/extents/conversion.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/ctor.layout_right.pass.cpp (+2-2)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/ctor.mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/ctor.layout_left.pass.cpp (+2-2)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/ctor.mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_stride/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_stride/ctor.strided_mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_array.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_extents.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_integers.pass.cpp (+4-4)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_map.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_map_acc.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_span.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/types.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/filesystems/fs.op.funcs/fs.op.space/space.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/istringstream/istringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/stringstream/stringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/compare_strong_order_fallback.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/compare_weak_order_fallback.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/strong_order.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/weak_order.pass.cpp (+1-1)
  • (modified) libcxx/test/std/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/utf_sanity_check.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/c.math/hermite.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/exclusive.scan/exclusive_scan.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan_op.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan_op_init.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/numeric.ops.midpoint/midpoint.float.pass.cpp (+2-2)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.exclusive.scan/transform_exclusive_scan_init_bop_uop.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.inclusive.scan/transform_inclusive_scan_bop_uop.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.inclusive.scan/transform_inclusive_scan_bop_uop_init.pass.cpp (+1-1)
  • (modified) libcxx/test/std/strings/string.view/string.view.capacity/capacity.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/lock.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/try_lock.pass.cpp (+1-1)
  • (modified) libcxx/test/std/utilities/allocator.adaptor/allocator.adaptor.types/is_always_equal.pass.cpp (+1-1)
  • (modified) libcxx/test/std/utilities/meta/meta.const.eval/is_constant_evaluated.pass.cpp (+1-1)
  • (modified) libcxx/test/support/filesystem_test_helper.h (+1-1)
  • (modified) libcxx/test/support/test_comparisons.h (+1-1)
  • (modified) libcxxabi/src/stdlib_new_delete.cpp (+1-1)
  • (modified) libcxxabi/test/guard_threaded_test.pass.cpp (+1-1)
  • (modified) lld/ELF/InputSection.cpp (+1-1)
  • (modified) lld/ELF/ScriptParser.cpp (+1-1)
  • (modified) lld/include/lld/Common/ErrorHandler.h (+1-1)
  • (modified) lld/test/COFF/guard-warnings.s (+1-1)
  • (modified) lld/test/ELF/gc-sections-no-undef-error.s (+1-1)
  • (modified) lld/test/ELF/lto/save-temps-eq.ll (+1-1)
  • (modified) lld/test/MachO/eh-frame-personality-dedup.s (+1-1)
  • (modified) lld/test/MachO/icf-only-lsda-folded.s (+1-1)
  • (modified) lldb/examples/summaries/cocoa/objc_runtime.py (+4-4)
  • (modified) lldb/packages/Python/lldbsuite/test/dotest.py (+1-1)
  • (modified) lldb/source/API/SBCommandInterpreter.cpp (+2-2)
  • (modified) lldb/source/Commands/CommandCompletions.cpp (+1-1)
  • (modified) lldb/source/Commands/CommandObjectWatchpoint.cpp (+2-2)
  • (modified) lldb/source/Commands/CommandObjectWatchpointCommand.cpp (+1-1)
  • (modified) lldb/source/Core/SourceManager.cpp (+1-1)
  • (modified) lldb/source/Expression/FunctionCaller.cpp (+1-1)
  • (modified) lldb/source/Expression/REPL.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/Mips/ABISysV_mips64.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/PowerPC/ABISysV_ppc.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/X86/ABISysV_x86_64.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/X86/ABIWindows_x86_64.cpp (+1-1)
  • (modified) lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOS.cpp (+1-1)
  • (modified) lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp (+1-1)
  • (modified) lldb/source/Plugins/ExpressionParser/Clang/CppModuleConfiguration.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/FreeBSD/NativeProcessFreeBSD.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/NetBSD/NativeProcessNetBSD.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/elf-core/ProcessElfCore.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp (+2-2)
  • (modified) lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp (+2-2)
  • (modified) lldb/source/Plugins/Trace/intel-pt/TraceIntelPTBundleLoader.cpp (+1-1)
  • (modified) lldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp (+1-1)
  • (modified) lldb/source/Plugins/UnwindAssembly/x86/UnwindAssembly-x86.cpp (+2-2)
  • (modified) lldb/source/Symbol/Symbol.cpp (+2-2)
  • (modified) lldb/source/Target/RegisterContextUnwind.cpp (+1-1)
  • (modified) lldb/source/Target/ThreadPlanStepInRange.cpp (+1-1)
  • (modified) lldb/source/Target/ThreadPlanStepOverRange.cpp (+2-2)
  • (modified) lldb/source/Utility/ZipFile.cpp (+3-3)
  • (modified) lldb/test/API/api/check_public_api_headers/TestPublicAPIHeaders.py (+1-1)
  • (modified) lldb/test/API/commands/frame/recognizer/TestFrameRecognizer.py (+1-1)
  • (modified) lldb/test/API/commands/memory/read/TestMemoryRead.py (+1-1)
  • (modified) lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/invalid-string/TestDataFormatterLibcxxInvalidString.py (+1-1)
  • (modified) lldb/test/API/functionalities/data-formatter/stringprinter/main.cpp (+1-1)
  • (modified) lldb/test/API/functionalities/limit-debug-info/TestLimitDebugInfo.py (+2-2)
  • (modified) lldb/test/API/functionalities/process_crash_info/TestProcessCrashInfo.py (+1-1)
  • (modified) lldb/test/API/lang/c/array_types/TestArrayTypes.py (+5-5)
  • (modified) lldb/test/API/lang/cpp/dynamic-value/TestDynamicValue.py (+1-1)
  • (modified) lldb/test/API/lang/cpp/incomplete-types/members/TestCppIncompleteTypeMembers.py (+1-1)
  • (modified) lldb/test/API/macosx/no-nlist-memory-module/TestNoNlistsDylib.py (+1-1)
  • (modified) lldb/test/API/macosx/simulator/TestSimulatorPlatform.py (+1-1)
  • (modified) lldb/test/API/python_api/value/linked_list/TestValueAPILinkedList.py (+2-2)
  • (modified) lldb/test/API/sanity/TestModuleCacheSanity.py (+1-1)
  • (modified) lldb/test/API/sanity/TestReprStrEquality.py (+1-1)
  • (modified) lldb/test/API/sanity/TestSettingSkipping.py (+1-1)
  • (modified) lldb/test/API/tools/lldb-server/memory-tagging/TestGdbRemoteMemoryTagging.py (+2-2)
  • (modified) lldb/test/Shell/REPL/Basic.test (+1-1)
  • (modified) lldb/test/Shell/Settings/TestModuleCacheSanity.test (+1-1)
  • (modified) lldb/tools/debugserver/source/MacOSX/arm64/DNBArchImplARM64.cpp (+1-1)
  • (modified) lldb/tools/lldb-rpc-gen/server/RPCServerSourceEmitter.cpp (+1-1)
  • (modified) lldb/unittests/Interpreter/TestCompletion.cpp (+1-1)
  • (modified) llvm/CMakeLists.txt (+1-1)
  • (modified) llvm/cmake/platforms/WinMsvc.cmake (+1-1)
  • (modified) llvm/docs/Atomics.rst (+1-1)
  • (modified) llvm/docs/CMake.rst (+1-1)
  • (modified) llvm/docs/CodingStandards.rst (+1-1)
  • (modified) llvm/docs/Contributing.rst (+1-1)
  • (modified) llvm/docs/Frontend/PerformanceTips.rst (+1-1)
  • (modified) llvm/docs/GettingStarted.rst (+1-1)
  • (modified) llvm/docs/LibFuzzer.rst (+1-1)
  • (modified) llvm/include/llvm-c/Core.h (+1-1)
  • (modified) llvm/include/llvm/ADT/APSInt.h (+1-1)
  • (modified) llvm/include/llvm/ADT/IntervalMap.h (+2-2)
  • (modified) llvm/include/llvm/CodeGen/MachineRegisterInfo.h (+1-1)
  • (modified) llvm/include/llvm/CodeGen/SelectionDAG.h (+1-1)
  • (modified) llvm/include/llvm/DebugInfo/DWARF/DWARFDebugFrame.h (+1-1)
  • (modified) llvm/include/llvm/IR/IntrinsicsARM.td (+1-1)
  • (modified) llvm/include/llvm/ProfileData/MemProfReader.h (+3-3)
diff --git a/bolt/lib/Passes/CMOVConversion.cpp b/bolt/lib/Passes/CMOVConversion.cpp
index cdd99b55207e0..10372416a9acd 100644
--- a/bolt/lib/Passes/CMOVConversion.cpp
+++ b/bolt/lib/Passes/CMOVConversion.cpp
@@ -66,7 +66,7 @@ bool isIfThenSubgraph(const BinaryBasicBlock &LHS,
   if (LHS.pred_size() != 2 || RHS.pred_size() != 1)
     return false;
 
-  // Sanity check
+  // Soundness check
   BinaryBasicBlock *Predecessor = *RHS.pred_begin();
   assert(Predecessor && LHS.isPredecessor(Predecessor) && "invalid subgraph");
   (void)Predecessor;
diff --git a/bolt/lib/Passes/IndirectCallPromotion.cpp b/bolt/lib/Passes/IndirectCallPromotion.cpp
index 8a01cb974c5da..dff1989c016b5 100644
--- a/bolt/lib/Passes/IndirectCallPromotion.cpp
+++ b/bolt/lib/Passes/IndirectCallPromotion.cpp
@@ -597,7 +597,7 @@ IndirectCallPromotion::findCallTargetSymbols(std::vector<Callsite> &Targets,
       std::vector<uint64_t>({JTIndex}).swap(NewTargets.back().JTIndices);
       llvm::erase(Target.JTIndices, JTIndex);
 
-      // Keep fixCFG counts sane if more indices use this same target later
+      // Keep fixCFG counts sound if more indices use this same target later
       assert(IndicesPerTarget[Target.To.Sym] > 0 && "wrong map");
       NewTargets.back().Branches =
           Target.Branches / IndicesPerTarget[Target.To.Sym];
diff --git a/bolt/lib/Profile/YAMLProfileReader.cpp b/bolt/lib/Profile/YAMLProfileReader.cpp
index 086e47b661e10..62190397b2be3 100644
--- a/bolt/lib/Profile/YAMLProfileReader.cpp
+++ b/bolt/lib/Profile/YAMLProfileReader.cpp
@@ -385,7 +385,7 @@ Error YAMLProfileReader::preprocessProfile(BinaryContext &BC) {
     return errorCodeToError(YamlInput.error());
   }
 
-  // Sanity check.
+  // Soundness check.
   if (YamlBP.Header.Version != 1)
     return make_error<StringError>(
         Twine("cannot read profile : unsupported version"),
diff --git a/bolt/lib/Rewrite/RewriteInstance.cpp b/bolt/lib/Rewrite/RewriteInstance.cpp
index a6e4dbc9c192f..871453b0ec5db 100644
--- a/bolt/lib/Rewrite/RewriteInstance.cpp
+++ b/bolt/lib/Rewrite/RewriteInstance.cpp
@@ -637,7 +637,7 @@ Error RewriteInstance::discoverStorage() {
     // If user specified a custom address where we should start writing new
     // data, honor that.
     NextAvailableAddress = opts::CustomAllocationVMA;
-    // Sanity check the user-supplied address and emit warnings if something
+    // Soundness check the user-supplied address and emit warnings if something
     // seems off.
     for (const ELF64LE::Phdr &Phdr : PHs) {
       switch (Phdr.p_type) {
@@ -2985,7 +2985,7 @@ void RewriteInstance::handleRelocation(const SectionRef &RelocatedSection,
     }
 
     if (BinaryData *BD = BC->getBinaryDataContainingAddress(SymbolAddress)) {
-      // Note: this assertion is trying to check sanity of BinaryData objects
+      // Note: this assertion is trying to check soundness of BinaryData objects
       // but AArch64 and RISCV has inferred and incomplete object locations
       // coming from GOT/TLS or any other non-trivial relocation (that requires
       // creation of sections and whose symbol address is not really what should
diff --git a/bolt/runtime/instr.cpp b/bolt/runtime/instr.cpp
index 1f54a500dbf98..97b49327ac484 100644
--- a/bolt/runtime/instr.cpp
+++ b/bolt/runtime/instr.cpp
@@ -819,7 +819,7 @@ ProfileWriterContext readDescriptions() {
 #endif
 
 #if !defined(__APPLE__)
-/// Debug by printing overall metadata global numbers to check it is sane
+/// Debug by printing overall metadata global numbers to check it is sound
 void printStats(const ProfileWriterContext &Ctx) {
   char StatMsg[BufSize];
   char *StatPtr = StatMsg;
diff --git a/bolt/test/AArch64/hook-fini.s b/bolt/test/AArch64/hook-fini.s
index 4f321d463ef32..4051546724748 100644
--- a/bolt/test/AArch64/hook-fini.s
+++ b/bolt/test/AArch64/hook-fini.s
@@ -4,7 +4,7 @@
 ## dynamic).
 ## All tests perform the following steps:
 ## - Compile and link for the case to be tested
-## - Some sanity-checks on the dynamic section and relocations in the binary to
+## - Some soundness-checks on the dynamic section and relocations in the binary to
 ##   verify it has the shape we want for testing:
 ##   - DT_FINI or DT_FINI_ARRAY in dynamic section
 ##   - No relative relocations for non-PIE
diff --git a/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s b/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
index 8e991fade2c86..c0a69a75b0d1b 100644
--- a/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
+++ b/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
@@ -272,7 +272,7 @@ lr_clobbered_nocfg:
         ret
         .size lr_clobbered_nocfg, .-lr_clobbered_nocfg
 
-/// Now do a basic sanity check on every different Authentication instruction:
+/// Now do a basic soundness check on every different Authentication instruction:
 
         .globl  f_autiasp
         .type   f_autiasp,@function
diff --git a/bolt/test/runtime/AArch64/hook-fini.test b/bolt/test/runtime/AArch64/hook-fini.test
index 8d23b21b6d612..43cc832e429ed 100644
--- a/bolt/test/runtime/AArch64/hook-fini.test
+++ b/bolt/test/runtime/AArch64/hook-fini.test
@@ -4,7 +4,7 @@
 # dynamic).
 # All tests perform the following steps:
 # - Compile and link for the case to be tested
-# - Some sanity-checks on the dynamic section and relocations in the binary to
+# - Some soundness-checks on the dynamic section and relocations in the binary to
 #   verify it has the shape we want for testing:
 #   - DT_FINI or DT_FINI_ARRAY in dynamic section
 #   - No relative relocations for non-PIE
diff --git a/bolt/tools/merge-fdata/merge-fdata.cpp b/bolt/tools/merge-fdata/merge-fdata.cpp
index cfcb9373548a1..9e55ad39427d4 100644
--- a/bolt/tools/merge-fdata/merge-fdata.cpp
+++ b/bolt/tools/merge-fdata/merge-fdata.cpp
@@ -428,7 +428,7 @@ int main(int argc, char **argv) {
     if (YamlInput.error())
       report_error(InputDataFilename, YamlInput.error());
 
-    // Sanity check.
+    // Soundness check.
     if (BP.Header.Version != 1) {
       errs() << "Unable to merge data from profile using version "
              << BP.Header.Version << '\n';
diff --git a/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp b/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
index d911b58cb8b7e..4b8b411bcc2ef 100644
--- a/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
+++ b/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
@@ -40,7 +40,7 @@ void ExplicitMakePairCheck::check(const MatchFinder::MatchResult &Result) {
   const auto *Call = Result.Nodes.getNodeAs<CallExpr>("call");
   const auto *DeclRef = Result.Nodes.getNodeAs<DeclRefExpr>("declref");
 
-  // Sanity check: The use might have overriden ::std::make_pair.
+  // Soundness check: The use might have overriden ::std::make_pair.
   if (Call->getNumArgs() != 2)
     return;
 
diff --git a/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp b/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
index 3f5cd4b473903..ac66c5bc5d66a 100644
--- a/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
+++ b/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
@@ -99,7 +99,7 @@ void MultiwayPathsCoveredCheck::check(const MatchFinder::MatchResult &Result) {
   bool SwitchHasDefault = false;
   std::tie(SwitchCaseCount, SwitchHasDefault) = countCaseLabels(Switch);
 
-  // Checks the sanity of 'switch' statements that actually do define
+  // Checks the soundness of 'switch' statements that actually do define
   // a default branch but might be degenerated by having no or only one case.
   if (SwitchHasDefault) {
     handleSwitchWithDefault(Switch, SwitchCaseCount);
diff --git a/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp b/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
index 712f390765957..f22118d5cb7e4 100644
--- a/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
+++ b/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
@@ -92,7 +92,7 @@ template <typename T, unsigned SmallSize> class SmartSmallSetVector {
   void populateSet() {
     assert(Set.empty() && "Should not have already utilized the Set.");
     // Magical growth factor prediction - to how many elements do we expect to
-    // sanely grow after switching away from small-size storage?
+    // soundly grow after switching away from small-size storage?
     const size_t NewMaxElts = 4 * Vector.size();
     Vector.reserve(NewMaxElts);
     Set.reserve(NewMaxElts);
diff --git a/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp b/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
index 2f59aaa86b157..b0e4efcbc5cba 100644
--- a/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
+++ b/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
@@ -133,7 +133,7 @@ struct CognitiveComplexity final {
                 "that in terms of stack usage. "
                 "Thus, it is good to minimize the size of the Detail struct.");
   SmallVector<Detail, DefaultLimit> Details; // 25 elements is 200 bytes.
-  // Yes, 25 is a magic number. This is the seemingly-sane default for the
+  // Yes, 25 is a magic number. This is the seemingly-sound default for the
   // upper limit for function cognitive complexity. Thus it would make sense
   // to avoid allocations for any function that does not violate the limit.
 
diff --git a/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp b/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
index 6bb8c394f75cc..1aaad01dea13f 100644
--- a/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
+++ b/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
@@ -61,7 +61,7 @@ void NamedParameterCheck::check(const MatchFinder::MatchResult &Result) {
         Parm->getType()->isSpecificBuiltinType(BuiltinType::Int))
       continue;
 
-    // Sanity check the source locations.
+    // Soundness check the source locations.
     if (!Parm->getLocation().isValid() || Parm->getLocation().isMacroID() ||
         !SM.isWrittenInSameFile(Parm->getBeginLoc(), Parm->getLocation()))
       continue;
diff --git a/clang-tools-extra/clangd/CodeCompletionStrings.cpp b/clang-tools-extra/clangd/CodeCompletionStrings.cpp
index 9c4241b54057a..a26b36db7ecad 100644
--- a/clang-tools-extra/clangd/CodeCompletionStrings.cpp
+++ b/clang-tools-extra/clangd/CodeCompletionStrings.cpp
@@ -123,7 +123,7 @@ std::string getDeclComment(const ASTContext &Ctx, const NamedDecl &Decl) {
     if (!RC)
       return "";
 
-    // Sanity check that the comment does not come from the PCH. We choose to
+    // Soundness check that the comment does not come from the PCH. We choose to
     // not write them into PCH, because they are racy and slow to load.
     assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
 
@@ -146,7 +146,7 @@ std::string getDeclComment(const ASTContext &Ctx, const NamedDecl &Decl) {
     RC = getCompletionComment(Ctx, &Decl);
     if (!RC)
       return "";
-    // Sanity check that the comment does not come from the PCH. We choose to
+    // Soundness check that the comment does not come from the PCH. We choose to
     // not write them into PCH, because they are racy and slow to load.
     assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
     Doc = RC->getFormattedText(Ctx.getSourceManager(), Ctx.getDiagnostics());
diff --git a/clang-tools-extra/clangd/Compiler.cpp b/clang-tools-extra/clangd/Compiler.cpp
index 8b3865c8a8e5c..ba8766663c411 100644
--- a/clang-tools-extra/clangd/Compiler.cpp
+++ b/clang-tools-extra/clangd/Compiler.cpp
@@ -100,7 +100,7 @@ buildCompilerInvocation(const ParseInputs &Inputs, clang::DiagnosticConsumer &D,
   std::vector<const char *> ArgStrs;
   ArgStrs.reserve(Argv.size() + 1);
   // In asserts builds, CompilerInvocation redundantly reads/parses cc1 args as
-  // a sanity test. This is not useful to clangd, and costs 10% of test time.
+  // a soundness test. This is not useful to clangd, and costs 10% of test time.
   // To avoid mismatches between assert/production builds, disable it always.
   ArgStrs = {Argv.front().c_str(), "-Xclang", "-no-round-trip-args"};
   for (const auto &S : Argv.drop_front())
diff --git a/clang-tools-extra/clangd/XRefs.cpp b/clang-tools-extra/clangd/XRefs.cpp
index e1c50f906de08..17141a52afc6c 100644
--- a/clang-tools-extra/clangd/XRefs.cpp
+++ b/clang-tools-extra/clangd/XRefs.cpp
@@ -972,7 +972,7 @@ class ReferenceFinder : public index::IndexDataConsumer {
                      llvm::dyn_cast_or_null<ObjCMethodDecl>(ASTNode.OrigD)) {
         OMD->getSelectorLocs(Locs);
       }
-      // Sanity check: we expect the *first* token to match the reported loc.
+      // Soundness check: we expect the *first* token to match the reported loc.
       // Otherwise, maybe it was e.g. some other kind of reference to a Decl.
       if (!Locs.empty() && Locs.front() != Loc)
         Locs.clear(); // First token doesn't match, assume our guess was wrong.
diff --git a/clang-tools-extra/clangd/index/IndexAction.cpp b/clang-tools-extra/clangd/index/IndexAction.cpp
index ed56c2a9d2e81..d9d9cd0f40942 100644
--- a/clang-tools-extra/clangd/index/IndexAction.cpp
+++ b/clang-tools-extra/clangd/index/IndexAction.cpp
@@ -106,7 +106,7 @@ struct IncludeGraphCollector : public PPCallbacks {
     NodeForIncluding.first->getValue().DirectIncludes.push_back(NodeForInclude);
   }
 
-  // Sanity check to ensure we have already populated a skipped file.
+  // Soundness check to ensure we have already populated a skipped file.
   void FileSkipped(const FileEntryRef &SkippedFile, const Token &FilenameTok,
                    SrcMgr::CharacteristicKind FileType) override {
 #ifndef NDEBUG
diff --git a/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp b/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
index ada14c9939318..1c443c50866e2 100644
--- a/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
+++ b/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
@@ -854,7 +854,7 @@ TEST(BackgroundQueueTest, Progress) {
   using testing::AnyOf;
   BackgroundQueue::Stats S;
   BackgroundQueue Q([&](BackgroundQueue::Stats New) {
-    // Verify values are sane.
+    // Verify values are sound.
     // Items are enqueued one at a time (at least in this test).
     EXPECT_THAT(New.Enqueued, AnyOf(S.Enqueued, S.Enqueued + 1));
     // Items are completed one at a time.
diff --git a/clang-tools-extra/clangd/unittests/ClangdTests.cpp b/clang-tools-extra/clangd/unittests/ClangdTests.cpp
index 9ea7c3e02411d..63c92671a621a 100644
--- a/clang-tools-extra/clangd/unittests/ClangdTests.cpp
+++ b/clang-tools-extra/clangd/unittests/ClangdTests.cpp
@@ -919,7 +919,7 @@ int d;
   StartSecond.wait();
   Server.addDocument(FooCpp, SourceContentsWithoutErrors);
   ASSERT_TRUE(Server.blockUntilIdleForTest()) << "Waiting for diagnostics";
-  ASSERT_EQ(DiagConsumer.Count, 2); // Sanity check - we actually ran both?
+  ASSERT_EQ(DiagConsumer.Count, 2); // Soundness check - we actually ran both?
 }
 
 TEST(ClangdServerTest, FormatCode) {
diff --git a/clang-tools-extra/clangd/unittests/QualityTests.cpp b/clang-tools-extra/clangd/unittests/QualityTests.cpp
index 4954659a45e02..1e6d34d58fcc1 100644
--- a/clang-tools-extra/clangd/unittests/QualityTests.cpp
+++ b/clang-tools-extra/clangd/unittests/QualityTests.cpp
@@ -10,7 +10,7 @@
 // For interesting cases, both exact scores and "X beats Y" are too brittle to
 // make good hard assertions.
 //
-// Here we test the signal extraction and sanity-check that signals point in
+// Here we test the signal extraction and soundness-check that signals point in
 // the right direction. This should be supplemented by quality metrics which
 // we can compute from a corpus of queries and preferred rankings.
 //
diff --git a/clang-tools-extra/clangd/unittests/RenameTests.cpp b/clang-tools-extra/clangd/unittests/RenameTests.cpp
index 5d2a77b62a219..b23d62e37e068 100644
--- a/clang-tools-extra/clangd/unittests/RenameTests.cpp
+++ b/clang-tools-extra/clangd/unittests/RenameTests.cpp
@@ -1444,7 +1444,7 @@ TEST(RenameTest, IndexMergeMainFile) {
   EXPECT_THAT(Results.GlobalChanges[Main].asTextEdits(),
               ElementsAre(newText("xPrime")));
 
-  // Sanity check: we do expect to see index results!
+  // Soundness check: we do expect to see index results!
   TU.Filename = "other.cc";
   Results = Rename(TU.index().get());
   EXPECT_THAT(Results.GlobalChanges.keys(),
diff --git a/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp b/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
index 4d1ca669b8d03..c846291329831 100644
--- a/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
+++ b/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
@@ -1,4 +1,4 @@
-// Sanity-check. Run without modules:
+// Soundness-check. Run without modules:
 // RUN: rm -rf %t
 // RUN: mkdir %t
 // RUN: cp %S/Inputs/expand-modular-headers-ppcallbacks/* %t/
diff --git a/clang/docs/AutomaticReferenceCounting.rst b/clang/docs/AutomaticReferenceCounting.rst
index 80bbd25121148..b10e3635e1d5b 100644
--- a/clang/docs/AutomaticReferenceCounting.rst
+++ b/clang/docs/AutomaticReferenceCounting.rst
@@ -1993,7 +1993,7 @@ A program is ill-formed if it refers to the ``NSAutoreleasePool`` class.
   dependencies between two calls.  It is also very easy to accidentally forget
   to drain an autorelease pool when using the manual API, and this can
   significantly inflate the process's high-water-mark.  The introduction of a
-  new scope is unfortunate but basically required for sane interaction with the
+  new scope is unfortunate but basically required for sound interaction with the
   rest of the language.  Not draining the pool during an unwind is apparently
   required by the Objective-C exceptions implementation.
 
diff --git a/clang/docs/InternalsManual.rst b/clang/docs/InternalsManual.rst
index bd742273f4ed5..411d3ee3ecec0 100644
--- a/clang/docs/InternalsManual.rst
+++ b/clang/docs/InternalsManual.rst
@@ -82,7 +82,7 @@ using it.  From this file, :program:`tblgen` generates the unique ID of the
 diagnostic, the severity of the diagnostic and the English translation + format
 string.
 
-There is little sanity with the naming of the unique ID's right now.  Some
+There is little soundness with the naming of the unique ID's right now.  Some
 start with ``err_``, ``warn_``, ``ext_`` to encode the severity into the name.
 Since the enum is referenced in the C++ code that produces the diagnostic, it
 is somewhat useful for it to be reasonably short.
diff --git a/clang/docs/Modules.rst b/clang/docs/Modules.rst
index acbe45e0be970..515f5838dbe49 100644
--- a/clang/docs/Modules.rst
+++ b/clang/docs/Modules.rst
@@ -1099,7 +1099,7 @@ The module maps will be written using the `module map language`_, which provides
   Headers are often missing ``#include`` directives for headers that they actually depend on. As with the problem of conflicting definitions, this only affects unlucky users who don't happen to include headers in the right order. With modules, the headers of a particular module will be parsed in isolation, so the module may fail to build if there are missing includes.
 
 **Headers that vend multiple APIs at different times**
-  Some systems have headers that contain a number of different kinds of API definitions, only some of which are made available with a given include. For example, the header may vend ``size_t`` only when the macro ``__need_size_t`` is defined before that header is included, and also vend ``wchar_t`` only when the macro ``__need_wchar_t`` is defined. Such headers are often included many times in a single translation unit, and will have no include guards. There is no sane way to map this header to a submodule. One can either eliminate the header (e.g., by splitting it into separate headers, one per actual API) or simply ``exclude`` it in the module map.
+  Some systems have headers that contain a number of different kinds of API definitions, only some of which are made available with a given include. For example, the header may vend ``size_t`` only when the macro ``__need_size_t`` is defined before that header is included, and also vend...
[truncated]

@llvmbot
Copy link
Member

llvmbot commented Sep 5, 2025

@llvm/pr-subscribers-backend-arm

Author: Rick van Voorden (vanvoorden)

Changes

Background

Inspired by swiftlang/swift#71167.

Searching through the repo, we see three main categories of changes:

  • Comments and Documentation
  • Constant Strings
  • Symbols

Ranking from "least" to "most" risky to land without causing any bugs or unintended consequences, let's start here with migrating comments and documentation.

Changes

  • sanity to soundness
  • sane to sound
  • insane to unsound
  • sanely to soundly

Patch is 337.82 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/156995.diff

443 Files Affected:

  • (modified) bolt/lib/Passes/CMOVConversion.cpp (+1-1)
  • (modified) bolt/lib/Passes/IndirectCallPromotion.cpp (+1-1)
  • (modified) bolt/lib/Profile/YAMLProfileReader.cpp (+1-1)
  • (modified) bolt/lib/Rewrite/RewriteInstance.cpp (+2-2)
  • (modified) bolt/runtime/instr.cpp (+1-1)
  • (modified) bolt/test/AArch64/hook-fini.s (+1-1)
  • (modified) bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s (+1-1)
  • (modified) bolt/test/runtime/AArch64/hook-fini.test (+1-1)
  • (modified) bolt/tools/merge-fdata/merge-fdata.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/CodeCompletionStrings.cpp (+2-2)
  • (modified) clang-tools-extra/clangd/Compiler.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/XRefs.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/index/IndexAction.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/ClangdTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/QualityTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/RenameTests.cpp (+1-1)
  • (modified) clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp (+1-1)
  • (modified) clang/docs/AutomaticReferenceCounting.rst (+1-1)
  • (modified) clang/docs/InternalsManual.rst (+1-1)
  • (modified) clang/docs/Modules.rst (+1-1)
  • (modified) clang/docs/UsersManual.rst (+1-1)
  • (modified) clang/include/clang/Sema/Sema.h (+1-1)
  • (modified) clang/lib/AST/ASTStructuralEquivalence.cpp (+2-2)
  • (modified) clang/lib/AST/CommentSema.cpp (+1-1)
  • (modified) clang/lib/AST/TypePrinter.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGCXXABI.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGCall.cpp (+2-2)
  • (modified) clang/lib/CodeGen/CGExpr.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGStmt.cpp (+1-1)
  • (modified) clang/lib/Driver/Driver.cpp (+1-1)
  • (modified) clang/lib/Frontend/PrintPreprocessedOutput.cpp (+2-2)
  • (modified) clang/lib/Index/USRGeneration.cpp (+1-1)
  • (modified) clang/lib/Parse/ParseStmtAsm.cpp (+2-2)
  • (modified) clang/lib/Sema/SemaOpenACC.cpp (+1-1)
  • (modified) clang/lib/Sema/SemaOverload.cpp (+2-2)
  • (modified) clang/lib/Sema/SemaTemplateDeduction.cpp (+1-1)
  • (modified) clang/lib/StaticAnalyzer/Checkers/ArrayBoundChecker.cpp (+1-1)
  • (modified) clang/lib/StaticAnalyzer/Checkers/PthreadLockChecker.cpp (+1-1)
  • (modified) clang/test/AST/ByteCode/cxx11.cpp (+1-1)
  • (modified) clang/test/Analysis/return-value-guaranteed.cpp (+1-1)
  • (modified) clang/test/Analysis/std-variant-checker.cpp (+1-1)
  • (modified) clang/test/CodeGen/AArch64/inline-asm.c (+1-1)
  • (modified) clang/test/CodeGen/alloc-align-attr.c (+1-1)
  • (modified) clang/test/CodeGen/arm-target-features.c (+1-1)
  • (modified) clang/test/CodeGen/atomic-ops.c (+1-1)
  • (modified) clang/test/CodeGen/strictfp-elementwise-builtins.cpp (+1-1)
  • (modified) clang/test/CodeGen/union-init2.c (+1-1)
  • (modified) clang/test/CodeGenCXX/OmitRTTIComponentABI/simple-vtable-definition.cpp (+1-1)
  • (modified) clang/test/CodeGenCXX/cxx11-user-defined-literal.cpp (+1-1)
  • (modified) clang/test/CodeGenCXX/type-aware-allocators.cpp (+1-1)
  • (modified) clang/test/CodeGenHLSL/GlobalDestructors.hlsl (+1-1)
  • (modified) clang/test/CodeGenHLSL/RootSignature.hlsl (+1-1)
  • (modified) clang/test/Driver/aix-as.c (+1-1)
  • (modified) clang/test/Driver/aix-ld.c (+1-1)
  • (modified) clang/test/Driver/as-dwarf-cie.s (+1-1)
  • (modified) clang/test/Driver/fopenmp.c (+1-1)
  • (modified) clang/test/Driver/linux-header-search.cpp (+1-1)
  • (modified) clang/test/Driver/linux-ld.c (+1-1)
  • (modified) clang/test/Driver/solaris-ld-values.c (+1-1)
  • (modified) clang/test/Driver/solaris-ld-values.cpp (+1-1)
  • (modified) clang/test/Driver/solaris-ld.c (+1-1)
  • (modified) clang/test/PCH/floating-literal.c (+1-1)
  • (modified) clang/test/SemaCXX/constant-expression-cxx11.cpp (+1-1)
  • (modified) clang/test/SemaCXX/constant-expression-cxx14.cpp (+1-1)
  • (modified) clang/test/SemaCXX/enable_if.cpp (+1-1)
  • (modified) clang/test/SemaCXX/overload-resolution-deferred-templates.cpp (+1-1)
  • (modified) clang/test/SemaCXX/vtable_pointer_authentication_attribute.cpp (+2-2)
  • (modified) clang/test/SemaTemplate/canonical-expr-type.cpp (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/check-globals.test (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/global-hex-value-regex.test (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/global-value-regex.test (+1-1)
  • (modified) clang/unittests/Analysis/CFGTest.cpp (+1-1)
  • (modified) clang/unittests/Basic/SourceManagerTest.cpp (+1-1)
  • (modified) clang/utils/TableGen/ClangAttrEmitter.cpp (+1-1)
  • (modified) cmake/Modules/EnableLanguageNolink.cmake (+2-2)
  • (modified) compiler-rt/cmake/Modules/CompilerRTDarwinUtils.cmake (+1-1)
  • (modified) compiler-rt/cmake/Modules/CompilerRTUtils.cmake (+1-1)
  • (modified) compiler-rt/lib/asan/asan_internal.h (+1-1)
  • (modified) compiler-rt/lib/asan/asan_poisoning.cpp (+3-3)
  • (modified) compiler-rt/lib/asan/asan_stats.cpp (+2-2)
  • (modified) compiler-rt/lib/builtins/negdi2.c (+1-1)
  • (modified) compiler-rt/lib/builtins/negti2.c (+1-1)
  • (modified) compiler-rt/lib/fuzzer/tests/FuzzerUnittest.cpp (+1-1)
  • (modified) compiler-rt/lib/hwasan/hwasan_linux.cpp (+1-1)
  • (modified) compiler-rt/lib/memprof/memprof_stats.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc (+4-4)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_flag_parser.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_interceptors_ioctl_netbsd.inc (+4-4)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_libc.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_mac.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_stacktrace.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_stacktrace_sparc.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_win.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/tests/sanitizer_procmaps_test.cpp (+1-1)
  • (modified) compiler-rt/lib/scudo/standalone/report.h (+1-1)
  • (modified) compiler-rt/lib/tsan/rtl/CMakeLists.txt (+1-1)
  • (modified) compiler-rt/lib/tsan/rtl/tsan_rtl.cpp (+3-3)
  • (modified) compiler-rt/lib/tsan/rtl/tsan_rtl_access.cpp (+1-1)
  • (modified) compiler-rt/lib/ubsan/ubsan_type_hash.h (+1-1)
  • (modified) compiler-rt/lib/ubsan/ubsan_type_hash_win.cpp (+1-1)
  • (modified) compiler-rt/lib/xray/tests/CMakeLists.txt (+1-1)
  • (modified) compiler-rt/test/BlocksRuntime/byrefsanity.c (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/Posix/unpoison-alternate-stack.cpp (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/sanity_check_pure_c.c (+2-2)
  • (modified) compiler-rt/test/builtins/Unit/atomic_test.c (+1-1)
  • (modified) compiler-rt/test/builtins/Unit/lit.cfg.py (+1-1)
  • (modified) compiler-rt/test/fuzzer/fuzzer-custommutator.test (+1-1)
  • (modified) compiler-rt/test/fuzzer/reload.test (+1-1)
  • (modified) compiler-rt/test/hwasan/TestCases/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/hwasan/TestCases/sanitizer_malloc.cpp (+1-1)
  • (modified) compiler-rt/test/msan/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/safestack/canary.c (+1-1)
  • (modified) compiler-rt/utils/generate_netbsd_ioctls.awk (+3-3)
  • (modified) compiler-rt/utils/generate_netbsd_syscalls.awk (+1-1)
  • (modified) flang-rt/unittests/Runtime/CharacterTest.cpp (+1-1)
  • (modified) flang-rt/unittests/Runtime/ExternalIOTest.cpp (+1-1)
  • (modified) flang/lib/Decimal/decimal-to-binary.cpp (+1-1)
  • (modified) flang/lib/Evaluate/fold-character.cpp (+1-1)
  • (modified) flang/lib/Evaluate/formatting.cpp (+1-1)
  • (modified) flang/lib/Evaluate/integer.cpp (+1-1)
  • (modified) flang/lib/Frontend/CompilerInstance.cpp (+1-1)
  • (modified) flang/lib/Lower/Bridge.cpp (+1-1)
  • (modified) flang/lib/Lower/ConvertVariable.cpp (+1-1)
  • (modified) flang/lib/Optimizer/Builder/FIRBuilder.cpp (+1-1)
  • (modified) flang/lib/Parser/preprocessor.cpp (+1-1)
  • (modified) flang/test/Driver/fopenmp.f90 (+1-1)
  • (modified) flang/test/Fir/convert-to-llvm.fir (+1-1)
  • (modified) flang/test/Semantics/modfile55.cuf (+1-1)
  • (modified) flang/test/Semantics/resolve59.f90 (+1-1)
  • (modified) flang/test/Semantics/symbol19.f90 (+1-1)
  • (modified) flang/unittests/Frontend/CompilerInstanceTest.cpp (+1-1)
  • (modified) libcxx/docs/DesignDocs/FileTimeType.rst (+2-2)
  • (modified) libcxx/docs/Status/Cxx20Papers.csv (+1-1)
  • (modified) libcxx/include/__cxx03/__hash_table (+1-1)
  • (modified) libcxx/include/__cxx03/__tree (+1-1)
  • (modified) libcxx/include/__hash_table (+1-1)
  • (modified) libcxx/include/__tree (+1-1)
  • (modified) libcxx/test/libcxx-03/numerics/bit.ops.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/extents/assert.ctor_from_span.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/layout_stride/assert.conversion.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/mdspan/assert.size.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/debug/containers/sequence_container_iterators.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/input.output/filesystems/convert_file_time.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/numerics/bit.ops.pass.cpp (+1-1)
  • (modified) libcxx/test/std/atomics/atomics.lockfree/is_always_lock_free.pass.cpp (+1-1)
  • (modified) libcxx/test/std/atomics/atomics.ref/is_always_lock_free.pass.cpp (+1-1)
  • (modified) libcxx/test/std/concepts/concepts.lang/concept.convertible/convertible_to.pass.cpp (+1-1)
  • (modified) libcxx/test/std/concepts/concepts.lang/concept.swappable/swappable.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/container.adaptors/priority.queue/priqueue.cons/ctor_iter_constraint.compile.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/sequences/array/empty.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/sequences/array/max_size.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/extents/conversion.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/ctor.layout_right.pass.cpp (+2-2)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/ctor.mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/ctor.layout_left.pass.cpp (+2-2)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/ctor.mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_stride/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_stride/ctor.strided_mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_array.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_extents.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_integers.pass.cpp (+4-4)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_map.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_map_acc.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_span.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/types.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/filesystems/fs.op.funcs/fs.op.space/space.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/istringstream/istringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/stringstream/stringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/compare_strong_order_fallback.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/compare_weak_order_fallback.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/strong_order.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/weak_order.pass.cpp (+1-1)
  • (modified) libcxx/test/std/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/utf_sanity_check.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/c.math/hermite.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/exclusive.scan/exclusive_scan.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan_op.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan_op_init.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/numeric.ops.midpoint/midpoint.float.pass.cpp (+2-2)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.exclusive.scan/transform_exclusive_scan_init_bop_uop.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.inclusive.scan/transform_inclusive_scan_bop_uop.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.inclusive.scan/transform_inclusive_scan_bop_uop_init.pass.cpp (+1-1)
  • (modified) libcxx/test/std/strings/string.view/string.view.capacity/capacity.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/lock.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/try_lock.pass.cpp (+1-1)
  • (modified) libcxx/test/std/utilities/allocator.adaptor/allocator.adaptor.types/is_always_equal.pass.cpp (+1-1)
  • (modified) libcxx/test/std/utilities/meta/meta.const.eval/is_constant_evaluated.pass.cpp (+1-1)
  • (modified) libcxx/test/support/filesystem_test_helper.h (+1-1)
  • (modified) libcxx/test/support/test_comparisons.h (+1-1)
  • (modified) libcxxabi/src/stdlib_new_delete.cpp (+1-1)
  • (modified) libcxxabi/test/guard_threaded_test.pass.cpp (+1-1)
  • (modified) lld/ELF/InputSection.cpp (+1-1)
  • (modified) lld/ELF/ScriptParser.cpp (+1-1)
  • (modified) lld/include/lld/Common/ErrorHandler.h (+1-1)
  • (modified) lld/test/COFF/guard-warnings.s (+1-1)
  • (modified) lld/test/ELF/gc-sections-no-undef-error.s (+1-1)
  • (modified) lld/test/ELF/lto/save-temps-eq.ll (+1-1)
  • (modified) lld/test/MachO/eh-frame-personality-dedup.s (+1-1)
  • (modified) lld/test/MachO/icf-only-lsda-folded.s (+1-1)
  • (modified) lldb/examples/summaries/cocoa/objc_runtime.py (+4-4)
  • (modified) lldb/packages/Python/lldbsuite/test/dotest.py (+1-1)
  • (modified) lldb/source/API/SBCommandInterpreter.cpp (+2-2)
  • (modified) lldb/source/Commands/CommandCompletions.cpp (+1-1)
  • (modified) lldb/source/Commands/CommandObjectWatchpoint.cpp (+2-2)
  • (modified) lldb/source/Commands/CommandObjectWatchpointCommand.cpp (+1-1)
  • (modified) lldb/source/Core/SourceManager.cpp (+1-1)
  • (modified) lldb/source/Expression/FunctionCaller.cpp (+1-1)
  • (modified) lldb/source/Expression/REPL.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/Mips/ABISysV_mips64.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/PowerPC/ABISysV_ppc.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/X86/ABISysV_x86_64.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/X86/ABIWindows_x86_64.cpp (+1-1)
  • (modified) lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOS.cpp (+1-1)
  • (modified) lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp (+1-1)
  • (modified) lldb/source/Plugins/ExpressionParser/Clang/CppModuleConfiguration.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/FreeBSD/NativeProcessFreeBSD.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/NetBSD/NativeProcessNetBSD.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/elf-core/ProcessElfCore.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp (+2-2)
  • (modified) lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp (+2-2)
  • (modified) lldb/source/Plugins/Trace/intel-pt/TraceIntelPTBundleLoader.cpp (+1-1)
  • (modified) lldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp (+1-1)
  • (modified) lldb/source/Plugins/UnwindAssembly/x86/UnwindAssembly-x86.cpp (+2-2)
  • (modified) lldb/source/Symbol/Symbol.cpp (+2-2)
  • (modified) lldb/source/Target/RegisterContextUnwind.cpp (+1-1)
  • (modified) lldb/source/Target/ThreadPlanStepInRange.cpp (+1-1)
  • (modified) lldb/source/Target/ThreadPlanStepOverRange.cpp (+2-2)
  • (modified) lldb/source/Utility/ZipFile.cpp (+3-3)
  • (modified) lldb/test/API/api/check_public_api_headers/TestPublicAPIHeaders.py (+1-1)
  • (modified) lldb/test/API/commands/frame/recognizer/TestFrameRecognizer.py (+1-1)
  • (modified) lldb/test/API/commands/memory/read/TestMemoryRead.py (+1-1)
  • (modified) lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/invalid-string/TestDataFormatterLibcxxInvalidString.py (+1-1)
  • (modified) lldb/test/API/functionalities/data-formatter/stringprinter/main.cpp (+1-1)
  • (modified) lldb/test/API/functionalities/limit-debug-info/TestLimitDebugInfo.py (+2-2)
  • (modified) lldb/test/API/functionalities/process_crash_info/TestProcessCrashInfo.py (+1-1)
  • (modified) lldb/test/API/lang/c/array_types/TestArrayTypes.py (+5-5)
  • (modified) lldb/test/API/lang/cpp/dynamic-value/TestDynamicValue.py (+1-1)
  • (modified) lldb/test/API/lang/cpp/incomplete-types/members/TestCppIncompleteTypeMembers.py (+1-1)
  • (modified) lldb/test/API/macosx/no-nlist-memory-module/TestNoNlistsDylib.py (+1-1)
  • (modified) lldb/test/API/macosx/simulator/TestSimulatorPlatform.py (+1-1)
  • (modified) lldb/test/API/python_api/value/linked_list/TestValueAPILinkedList.py (+2-2)
  • (modified) lldb/test/API/sanity/TestModuleCacheSanity.py (+1-1)
  • (modified) lldb/test/API/sanity/TestReprStrEquality.py (+1-1)
  • (modified) lldb/test/API/sanity/TestSettingSkipping.py (+1-1)
  • (modified) lldb/test/API/tools/lldb-server/memory-tagging/TestGdbRemoteMemoryTagging.py (+2-2)
  • (modified) lldb/test/Shell/REPL/Basic.test (+1-1)
  • (modified) lldb/test/Shell/Settings/TestModuleCacheSanity.test (+1-1)
  • (modified) lldb/tools/debugserver/source/MacOSX/arm64/DNBArchImplARM64.cpp (+1-1)
  • (modified) lldb/tools/lldb-rpc-gen/server/RPCServerSourceEmitter.cpp (+1-1)
  • (modified) lldb/unittests/Interpreter/TestCompletion.cpp (+1-1)
  • (modified) llvm/CMakeLists.txt (+1-1)
  • (modified) llvm/cmake/platforms/WinMsvc.cmake (+1-1)
  • (modified) llvm/docs/Atomics.rst (+1-1)
  • (modified) llvm/docs/CMake.rst (+1-1)
  • (modified) llvm/docs/CodingStandards.rst (+1-1)
  • (modified) llvm/docs/Contributing.rst (+1-1)
  • (modified) llvm/docs/Frontend/PerformanceTips.rst (+1-1)
  • (modified) llvm/docs/GettingStarted.rst (+1-1)
  • (modified) llvm/docs/LibFuzzer.rst (+1-1)
  • (modified) llvm/include/llvm-c/Core.h (+1-1)
  • (modified) llvm/include/llvm/ADT/APSInt.h (+1-1)
  • (modified) llvm/include/llvm/ADT/IntervalMap.h (+2-2)
  • (modified) llvm/include/llvm/CodeGen/MachineRegisterInfo.h (+1-1)
  • (modified) llvm/include/llvm/CodeGen/SelectionDAG.h (+1-1)
  • (modified) llvm/include/llvm/DebugInfo/DWARF/DWARFDebugFrame.h (+1-1)
  • (modified) llvm/include/llvm/IR/IntrinsicsARM.td (+1-1)
  • (modified) llvm/include/llvm/ProfileData/MemProfReader.h (+3-3)
diff --git a/bolt/lib/Passes/CMOVConversion.cpp b/bolt/lib/Passes/CMOVConversion.cpp
index cdd99b55207e0..10372416a9acd 100644
--- a/bolt/lib/Passes/CMOVConversion.cpp
+++ b/bolt/lib/Passes/CMOVConversion.cpp
@@ -66,7 +66,7 @@ bool isIfThenSubgraph(const BinaryBasicBlock &LHS,
   if (LHS.pred_size() != 2 || RHS.pred_size() != 1)
     return false;
 
-  // Sanity check
+  // Soundness check
   BinaryBasicBlock *Predecessor = *RHS.pred_begin();
   assert(Predecessor && LHS.isPredecessor(Predecessor) && "invalid subgraph");
   (void)Predecessor;
diff --git a/bolt/lib/Passes/IndirectCallPromotion.cpp b/bolt/lib/Passes/IndirectCallPromotion.cpp
index 8a01cb974c5da..dff1989c016b5 100644
--- a/bolt/lib/Passes/IndirectCallPromotion.cpp
+++ b/bolt/lib/Passes/IndirectCallPromotion.cpp
@@ -597,7 +597,7 @@ IndirectCallPromotion::findCallTargetSymbols(std::vector<Callsite> &Targets,
       std::vector<uint64_t>({JTIndex}).swap(NewTargets.back().JTIndices);
       llvm::erase(Target.JTIndices, JTIndex);
 
-      // Keep fixCFG counts sane if more indices use this same target later
+      // Keep fixCFG counts sound if more indices use this same target later
       assert(IndicesPerTarget[Target.To.Sym] > 0 && "wrong map");
       NewTargets.back().Branches =
           Target.Branches / IndicesPerTarget[Target.To.Sym];
diff --git a/bolt/lib/Profile/YAMLProfileReader.cpp b/bolt/lib/Profile/YAMLProfileReader.cpp
index 086e47b661e10..62190397b2be3 100644
--- a/bolt/lib/Profile/YAMLProfileReader.cpp
+++ b/bolt/lib/Profile/YAMLProfileReader.cpp
@@ -385,7 +385,7 @@ Error YAMLProfileReader::preprocessProfile(BinaryContext &BC) {
     return errorCodeToError(YamlInput.error());
   }
 
-  // Sanity check.
+  // Soundness check.
   if (YamlBP.Header.Version != 1)
     return make_error<StringError>(
         Twine("cannot read profile : unsupported version"),
diff --git a/bolt/lib/Rewrite/RewriteInstance.cpp b/bolt/lib/Rewrite/RewriteInstance.cpp
index a6e4dbc9c192f..871453b0ec5db 100644
--- a/bolt/lib/Rewrite/RewriteInstance.cpp
+++ b/bolt/lib/Rewrite/RewriteInstance.cpp
@@ -637,7 +637,7 @@ Error RewriteInstance::discoverStorage() {
     // If user specified a custom address where we should start writing new
     // data, honor that.
     NextAvailableAddress = opts::CustomAllocationVMA;
-    // Sanity check the user-supplied address and emit warnings if something
+    // Soundness check the user-supplied address and emit warnings if something
     // seems off.
     for (const ELF64LE::Phdr &Phdr : PHs) {
       switch (Phdr.p_type) {
@@ -2985,7 +2985,7 @@ void RewriteInstance::handleRelocation(const SectionRef &RelocatedSection,
     }
 
     if (BinaryData *BD = BC->getBinaryDataContainingAddress(SymbolAddress)) {
-      // Note: this assertion is trying to check sanity of BinaryData objects
+      // Note: this assertion is trying to check soundness of BinaryData objects
       // but AArch64 and RISCV has inferred and incomplete object locations
       // coming from GOT/TLS or any other non-trivial relocation (that requires
       // creation of sections and whose symbol address is not really what should
diff --git a/bolt/runtime/instr.cpp b/bolt/runtime/instr.cpp
index 1f54a500dbf98..97b49327ac484 100644
--- a/bolt/runtime/instr.cpp
+++ b/bolt/runtime/instr.cpp
@@ -819,7 +819,7 @@ ProfileWriterContext readDescriptions() {
 #endif
 
 #if !defined(__APPLE__)
-/// Debug by printing overall metadata global numbers to check it is sane
+/// Debug by printing overall metadata global numbers to check it is sound
 void printStats(const ProfileWriterContext &Ctx) {
   char StatMsg[BufSize];
   char *StatPtr = StatMsg;
diff --git a/bolt/test/AArch64/hook-fini.s b/bolt/test/AArch64/hook-fini.s
index 4f321d463ef32..4051546724748 100644
--- a/bolt/test/AArch64/hook-fini.s
+++ b/bolt/test/AArch64/hook-fini.s
@@ -4,7 +4,7 @@
 ## dynamic).
 ## All tests perform the following steps:
 ## - Compile and link for the case to be tested
-## - Some sanity-checks on the dynamic section and relocations in the binary to
+## - Some soundness-checks on the dynamic section and relocations in the binary to
 ##   verify it has the shape we want for testing:
 ##   - DT_FINI or DT_FINI_ARRAY in dynamic section
 ##   - No relative relocations for non-PIE
diff --git a/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s b/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
index 8e991fade2c86..c0a69a75b0d1b 100644
--- a/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
+++ b/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
@@ -272,7 +272,7 @@ lr_clobbered_nocfg:
         ret
         .size lr_clobbered_nocfg, .-lr_clobbered_nocfg
 
-/// Now do a basic sanity check on every different Authentication instruction:
+/// Now do a basic soundness check on every different Authentication instruction:
 
         .globl  f_autiasp
         .type   f_autiasp,@function
diff --git a/bolt/test/runtime/AArch64/hook-fini.test b/bolt/test/runtime/AArch64/hook-fini.test
index 8d23b21b6d612..43cc832e429ed 100644
--- a/bolt/test/runtime/AArch64/hook-fini.test
+++ b/bolt/test/runtime/AArch64/hook-fini.test
@@ -4,7 +4,7 @@
 # dynamic).
 # All tests perform the following steps:
 # - Compile and link for the case to be tested
-# - Some sanity-checks on the dynamic section and relocations in the binary to
+# - Some soundness-checks on the dynamic section and relocations in the binary to
 #   verify it has the shape we want for testing:
 #   - DT_FINI or DT_FINI_ARRAY in dynamic section
 #   - No relative relocations for non-PIE
diff --git a/bolt/tools/merge-fdata/merge-fdata.cpp b/bolt/tools/merge-fdata/merge-fdata.cpp
index cfcb9373548a1..9e55ad39427d4 100644
--- a/bolt/tools/merge-fdata/merge-fdata.cpp
+++ b/bolt/tools/merge-fdata/merge-fdata.cpp
@@ -428,7 +428,7 @@ int main(int argc, char **argv) {
     if (YamlInput.error())
       report_error(InputDataFilename, YamlInput.error());
 
-    // Sanity check.
+    // Soundness check.
     if (BP.Header.Version != 1) {
       errs() << "Unable to merge data from profile using version "
              << BP.Header.Version << '\n';
diff --git a/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp b/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
index d911b58cb8b7e..4b8b411bcc2ef 100644
--- a/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
+++ b/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
@@ -40,7 +40,7 @@ void ExplicitMakePairCheck::check(const MatchFinder::MatchResult &Result) {
   const auto *Call = Result.Nodes.getNodeAs<CallExpr>("call");
   const auto *DeclRef = Result.Nodes.getNodeAs<DeclRefExpr>("declref");
 
-  // Sanity check: The use might have overriden ::std::make_pair.
+  // Soundness check: The use might have overriden ::std::make_pair.
   if (Call->getNumArgs() != 2)
     return;
 
diff --git a/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp b/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
index 3f5cd4b473903..ac66c5bc5d66a 100644
--- a/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
+++ b/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
@@ -99,7 +99,7 @@ void MultiwayPathsCoveredCheck::check(const MatchFinder::MatchResult &Result) {
   bool SwitchHasDefault = false;
   std::tie(SwitchCaseCount, SwitchHasDefault) = countCaseLabels(Switch);
 
-  // Checks the sanity of 'switch' statements that actually do define
+  // Checks the soundness of 'switch' statements that actually do define
   // a default branch but might be degenerated by having no or only one case.
   if (SwitchHasDefault) {
     handleSwitchWithDefault(Switch, SwitchCaseCount);
diff --git a/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp b/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
index 712f390765957..f22118d5cb7e4 100644
--- a/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
+++ b/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
@@ -92,7 +92,7 @@ template <typename T, unsigned SmallSize> class SmartSmallSetVector {
   void populateSet() {
     assert(Set.empty() && "Should not have already utilized the Set.");
     // Magical growth factor prediction - to how many elements do we expect to
-    // sanely grow after switching away from small-size storage?
+    // soundly grow after switching away from small-size storage?
     const size_t NewMaxElts = 4 * Vector.size();
     Vector.reserve(NewMaxElts);
     Set.reserve(NewMaxElts);
diff --git a/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp b/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
index 2f59aaa86b157..b0e4efcbc5cba 100644
--- a/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
+++ b/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
@@ -133,7 +133,7 @@ struct CognitiveComplexity final {
                 "that in terms of stack usage. "
                 "Thus, it is good to minimize the size of the Detail struct.");
   SmallVector<Detail, DefaultLimit> Details; // 25 elements is 200 bytes.
-  // Yes, 25 is a magic number. This is the seemingly-sane default for the
+  // Yes, 25 is a magic number. This is the seemingly-sound default for the
   // upper limit for function cognitive complexity. Thus it would make sense
   // to avoid allocations for any function that does not violate the limit.
 
diff --git a/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp b/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
index 6bb8c394f75cc..1aaad01dea13f 100644
--- a/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
+++ b/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
@@ -61,7 +61,7 @@ void NamedParameterCheck::check(const MatchFinder::MatchResult &Result) {
         Parm->getType()->isSpecificBuiltinType(BuiltinType::Int))
       continue;
 
-    // Sanity check the source locations.
+    // Soundness check the source locations.
     if (!Parm->getLocation().isValid() || Parm->getLocation().isMacroID() ||
         !SM.isWrittenInSameFile(Parm->getBeginLoc(), Parm->getLocation()))
       continue;
diff --git a/clang-tools-extra/clangd/CodeCompletionStrings.cpp b/clang-tools-extra/clangd/CodeCompletionStrings.cpp
index 9c4241b54057a..a26b36db7ecad 100644
--- a/clang-tools-extra/clangd/CodeCompletionStrings.cpp
+++ b/clang-tools-extra/clangd/CodeCompletionStrings.cpp
@@ -123,7 +123,7 @@ std::string getDeclComment(const ASTContext &Ctx, const NamedDecl &Decl) {
     if (!RC)
       return "";
 
-    // Sanity check that the comment does not come from the PCH. We choose to
+    // Soundness check that the comment does not come from the PCH. We choose to
     // not write them into PCH, because they are racy and slow to load.
     assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
 
@@ -146,7 +146,7 @@ std::string getDeclComment(const ASTContext &Ctx, const NamedDecl &Decl) {
     RC = getCompletionComment(Ctx, &Decl);
     if (!RC)
       return "";
-    // Sanity check that the comment does not come from the PCH. We choose to
+    // Soundness check that the comment does not come from the PCH. We choose to
     // not write them into PCH, because they are racy and slow to load.
     assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
     Doc = RC->getFormattedText(Ctx.getSourceManager(), Ctx.getDiagnostics());
diff --git a/clang-tools-extra/clangd/Compiler.cpp b/clang-tools-extra/clangd/Compiler.cpp
index 8b3865c8a8e5c..ba8766663c411 100644
--- a/clang-tools-extra/clangd/Compiler.cpp
+++ b/clang-tools-extra/clangd/Compiler.cpp
@@ -100,7 +100,7 @@ buildCompilerInvocation(const ParseInputs &Inputs, clang::DiagnosticConsumer &D,
   std::vector<const char *> ArgStrs;
   ArgStrs.reserve(Argv.size() + 1);
   // In asserts builds, CompilerInvocation redundantly reads/parses cc1 args as
-  // a sanity test. This is not useful to clangd, and costs 10% of test time.
+  // a soundness test. This is not useful to clangd, and costs 10% of test time.
   // To avoid mismatches between assert/production builds, disable it always.
   ArgStrs = {Argv.front().c_str(), "-Xclang", "-no-round-trip-args"};
   for (const auto &S : Argv.drop_front())
diff --git a/clang-tools-extra/clangd/XRefs.cpp b/clang-tools-extra/clangd/XRefs.cpp
index e1c50f906de08..17141a52afc6c 100644
--- a/clang-tools-extra/clangd/XRefs.cpp
+++ b/clang-tools-extra/clangd/XRefs.cpp
@@ -972,7 +972,7 @@ class ReferenceFinder : public index::IndexDataConsumer {
                      llvm::dyn_cast_or_null<ObjCMethodDecl>(ASTNode.OrigD)) {
         OMD->getSelectorLocs(Locs);
       }
-      // Sanity check: we expect the *first* token to match the reported loc.
+      // Soundness check: we expect the *first* token to match the reported loc.
       // Otherwise, maybe it was e.g. some other kind of reference to a Decl.
       if (!Locs.empty() && Locs.front() != Loc)
         Locs.clear(); // First token doesn't match, assume our guess was wrong.
diff --git a/clang-tools-extra/clangd/index/IndexAction.cpp b/clang-tools-extra/clangd/index/IndexAction.cpp
index ed56c2a9d2e81..d9d9cd0f40942 100644
--- a/clang-tools-extra/clangd/index/IndexAction.cpp
+++ b/clang-tools-extra/clangd/index/IndexAction.cpp
@@ -106,7 +106,7 @@ struct IncludeGraphCollector : public PPCallbacks {
     NodeForIncluding.first->getValue().DirectIncludes.push_back(NodeForInclude);
   }
 
-  // Sanity check to ensure we have already populated a skipped file.
+  // Soundness check to ensure we have already populated a skipped file.
   void FileSkipped(const FileEntryRef &SkippedFile, const Token &FilenameTok,
                    SrcMgr::CharacteristicKind FileType) override {
 #ifndef NDEBUG
diff --git a/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp b/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
index ada14c9939318..1c443c50866e2 100644
--- a/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
+++ b/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
@@ -854,7 +854,7 @@ TEST(BackgroundQueueTest, Progress) {
   using testing::AnyOf;
   BackgroundQueue::Stats S;
   BackgroundQueue Q([&](BackgroundQueue::Stats New) {
-    // Verify values are sane.
+    // Verify values are sound.
     // Items are enqueued one at a time (at least in this test).
     EXPECT_THAT(New.Enqueued, AnyOf(S.Enqueued, S.Enqueued + 1));
     // Items are completed one at a time.
diff --git a/clang-tools-extra/clangd/unittests/ClangdTests.cpp b/clang-tools-extra/clangd/unittests/ClangdTests.cpp
index 9ea7c3e02411d..63c92671a621a 100644
--- a/clang-tools-extra/clangd/unittests/ClangdTests.cpp
+++ b/clang-tools-extra/clangd/unittests/ClangdTests.cpp
@@ -919,7 +919,7 @@ int d;
   StartSecond.wait();
   Server.addDocument(FooCpp, SourceContentsWithoutErrors);
   ASSERT_TRUE(Server.blockUntilIdleForTest()) << "Waiting for diagnostics";
-  ASSERT_EQ(DiagConsumer.Count, 2); // Sanity check - we actually ran both?
+  ASSERT_EQ(DiagConsumer.Count, 2); // Soundness check - we actually ran both?
 }
 
 TEST(ClangdServerTest, FormatCode) {
diff --git a/clang-tools-extra/clangd/unittests/QualityTests.cpp b/clang-tools-extra/clangd/unittests/QualityTests.cpp
index 4954659a45e02..1e6d34d58fcc1 100644
--- a/clang-tools-extra/clangd/unittests/QualityTests.cpp
+++ b/clang-tools-extra/clangd/unittests/QualityTests.cpp
@@ -10,7 +10,7 @@
 // For interesting cases, both exact scores and "X beats Y" are too brittle to
 // make good hard assertions.
 //
-// Here we test the signal extraction and sanity-check that signals point in
+// Here we test the signal extraction and soundness-check that signals point in
 // the right direction. This should be supplemented by quality metrics which
 // we can compute from a corpus of queries and preferred rankings.
 //
diff --git a/clang-tools-extra/clangd/unittests/RenameTests.cpp b/clang-tools-extra/clangd/unittests/RenameTests.cpp
index 5d2a77b62a219..b23d62e37e068 100644
--- a/clang-tools-extra/clangd/unittests/RenameTests.cpp
+++ b/clang-tools-extra/clangd/unittests/RenameTests.cpp
@@ -1444,7 +1444,7 @@ TEST(RenameTest, IndexMergeMainFile) {
   EXPECT_THAT(Results.GlobalChanges[Main].asTextEdits(),
               ElementsAre(newText("xPrime")));
 
-  // Sanity check: we do expect to see index results!
+  // Soundness check: we do expect to see index results!
   TU.Filename = "other.cc";
   Results = Rename(TU.index().get());
   EXPECT_THAT(Results.GlobalChanges.keys(),
diff --git a/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp b/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
index 4d1ca669b8d03..c846291329831 100644
--- a/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
+++ b/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
@@ -1,4 +1,4 @@
-// Sanity-check. Run without modules:
+// Soundness-check. Run without modules:
 // RUN: rm -rf %t
 // RUN: mkdir %t
 // RUN: cp %S/Inputs/expand-modular-headers-ppcallbacks/* %t/
diff --git a/clang/docs/AutomaticReferenceCounting.rst b/clang/docs/AutomaticReferenceCounting.rst
index 80bbd25121148..b10e3635e1d5b 100644
--- a/clang/docs/AutomaticReferenceCounting.rst
+++ b/clang/docs/AutomaticReferenceCounting.rst
@@ -1993,7 +1993,7 @@ A program is ill-formed if it refers to the ``NSAutoreleasePool`` class.
   dependencies between two calls.  It is also very easy to accidentally forget
   to drain an autorelease pool when using the manual API, and this can
   significantly inflate the process's high-water-mark.  The introduction of a
-  new scope is unfortunate but basically required for sane interaction with the
+  new scope is unfortunate but basically required for sound interaction with the
   rest of the language.  Not draining the pool during an unwind is apparently
   required by the Objective-C exceptions implementation.
 
diff --git a/clang/docs/InternalsManual.rst b/clang/docs/InternalsManual.rst
index bd742273f4ed5..411d3ee3ecec0 100644
--- a/clang/docs/InternalsManual.rst
+++ b/clang/docs/InternalsManual.rst
@@ -82,7 +82,7 @@ using it.  From this file, :program:`tblgen` generates the unique ID of the
 diagnostic, the severity of the diagnostic and the English translation + format
 string.
 
-There is little sanity with the naming of the unique ID's right now.  Some
+There is little soundness with the naming of the unique ID's right now.  Some
 start with ``err_``, ``warn_``, ``ext_`` to encode the severity into the name.
 Since the enum is referenced in the C++ code that produces the diagnostic, it
 is somewhat useful for it to be reasonably short.
diff --git a/clang/docs/Modules.rst b/clang/docs/Modules.rst
index acbe45e0be970..515f5838dbe49 100644
--- a/clang/docs/Modules.rst
+++ b/clang/docs/Modules.rst
@@ -1099,7 +1099,7 @@ The module maps will be written using the `module map language`_, which provides
   Headers are often missing ``#include`` directives for headers that they actually depend on. As with the problem of conflicting definitions, this only affects unlucky users who don't happen to include headers in the right order. With modules, the headers of a particular module will be parsed in isolation, so the module may fail to build if there are missing includes.
 
 **Headers that vend multiple APIs at different times**
-  Some systems have headers that contain a number of different kinds of API definitions, only some of which are made available with a given include. For example, the header may vend ``size_t`` only when the macro ``__need_size_t`` is defined before that header is included, and also vend ``wchar_t`` only when the macro ``__need_wchar_t`` is defined. Such headers are often included many times in a single translation unit, and will have no include guards. There is no sane way to map this header to a submodule. One can either eliminate the header (e.g., by splitting it into separate headers, one per actual API) or simply ``exclude`` it in the module map.
+  Some systems have headers that contain a number of different kinds of API definitions, only some of which are made available with a given include. For example, the header may vend ``size_t`` only when the macro ``__need_size_t`` is defined before that header is included, and also vend...
[truncated]

@llvmbot
Copy link
Member

llvmbot commented Sep 5, 2025

@llvm/pr-subscribers-clang

Author: Rick van Voorden (vanvoorden)

Changes

Background

Inspired by swiftlang/swift#71167.

Searching through the repo, we see three main categories of changes:

  • Comments and Documentation
  • Constant Strings
  • Symbols

Ranking from "least" to "most" risky to land without causing any bugs or unintended consequences, let's start here with migrating comments and documentation.

Changes

  • sanity to soundness
  • sane to sound
  • insane to unsound
  • sanely to soundly

Patch is 337.82 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/156995.diff

443 Files Affected:

  • (modified) bolt/lib/Passes/CMOVConversion.cpp (+1-1)
  • (modified) bolt/lib/Passes/IndirectCallPromotion.cpp (+1-1)
  • (modified) bolt/lib/Profile/YAMLProfileReader.cpp (+1-1)
  • (modified) bolt/lib/Rewrite/RewriteInstance.cpp (+2-2)
  • (modified) bolt/runtime/instr.cpp (+1-1)
  • (modified) bolt/test/AArch64/hook-fini.s (+1-1)
  • (modified) bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s (+1-1)
  • (modified) bolt/test/runtime/AArch64/hook-fini.test (+1-1)
  • (modified) bolt/tools/merge-fdata/merge-fdata.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/CodeCompletionStrings.cpp (+2-2)
  • (modified) clang-tools-extra/clangd/Compiler.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/XRefs.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/index/IndexAction.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/ClangdTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/QualityTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/RenameTests.cpp (+1-1)
  • (modified) clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp (+1-1)
  • (modified) clang/docs/AutomaticReferenceCounting.rst (+1-1)
  • (modified) clang/docs/InternalsManual.rst (+1-1)
  • (modified) clang/docs/Modules.rst (+1-1)
  • (modified) clang/docs/UsersManual.rst (+1-1)
  • (modified) clang/include/clang/Sema/Sema.h (+1-1)
  • (modified) clang/lib/AST/ASTStructuralEquivalence.cpp (+2-2)
  • (modified) clang/lib/AST/CommentSema.cpp (+1-1)
  • (modified) clang/lib/AST/TypePrinter.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGCXXABI.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGCall.cpp (+2-2)
  • (modified) clang/lib/CodeGen/CGExpr.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGStmt.cpp (+1-1)
  • (modified) clang/lib/Driver/Driver.cpp (+1-1)
  • (modified) clang/lib/Frontend/PrintPreprocessedOutput.cpp (+2-2)
  • (modified) clang/lib/Index/USRGeneration.cpp (+1-1)
  • (modified) clang/lib/Parse/ParseStmtAsm.cpp (+2-2)
  • (modified) clang/lib/Sema/SemaOpenACC.cpp (+1-1)
  • (modified) clang/lib/Sema/SemaOverload.cpp (+2-2)
  • (modified) clang/lib/Sema/SemaTemplateDeduction.cpp (+1-1)
  • (modified) clang/lib/StaticAnalyzer/Checkers/ArrayBoundChecker.cpp (+1-1)
  • (modified) clang/lib/StaticAnalyzer/Checkers/PthreadLockChecker.cpp (+1-1)
  • (modified) clang/test/AST/ByteCode/cxx11.cpp (+1-1)
  • (modified) clang/test/Analysis/return-value-guaranteed.cpp (+1-1)
  • (modified) clang/test/Analysis/std-variant-checker.cpp (+1-1)
  • (modified) clang/test/CodeGen/AArch64/inline-asm.c (+1-1)
  • (modified) clang/test/CodeGen/alloc-align-attr.c (+1-1)
  • (modified) clang/test/CodeGen/arm-target-features.c (+1-1)
  • (modified) clang/test/CodeGen/atomic-ops.c (+1-1)
  • (modified) clang/test/CodeGen/strictfp-elementwise-builtins.cpp (+1-1)
  • (modified) clang/test/CodeGen/union-init2.c (+1-1)
  • (modified) clang/test/CodeGenCXX/OmitRTTIComponentABI/simple-vtable-definition.cpp (+1-1)
  • (modified) clang/test/CodeGenCXX/cxx11-user-defined-literal.cpp (+1-1)
  • (modified) clang/test/CodeGenCXX/type-aware-allocators.cpp (+1-1)
  • (modified) clang/test/CodeGenHLSL/GlobalDestructors.hlsl (+1-1)
  • (modified) clang/test/CodeGenHLSL/RootSignature.hlsl (+1-1)
  • (modified) clang/test/Driver/aix-as.c (+1-1)
  • (modified) clang/test/Driver/aix-ld.c (+1-1)
  • (modified) clang/test/Driver/as-dwarf-cie.s (+1-1)
  • (modified) clang/test/Driver/fopenmp.c (+1-1)
  • (modified) clang/test/Driver/linux-header-search.cpp (+1-1)
  • (modified) clang/test/Driver/linux-ld.c (+1-1)
  • (modified) clang/test/Driver/solaris-ld-values.c (+1-1)
  • (modified) clang/test/Driver/solaris-ld-values.cpp (+1-1)
  • (modified) clang/test/Driver/solaris-ld.c (+1-1)
  • (modified) clang/test/PCH/floating-literal.c (+1-1)
  • (modified) clang/test/SemaCXX/constant-expression-cxx11.cpp (+1-1)
  • (modified) clang/test/SemaCXX/constant-expression-cxx14.cpp (+1-1)
  • (modified) clang/test/SemaCXX/enable_if.cpp (+1-1)
  • (modified) clang/test/SemaCXX/overload-resolution-deferred-templates.cpp (+1-1)
  • (modified) clang/test/SemaCXX/vtable_pointer_authentication_attribute.cpp (+2-2)
  • (modified) clang/test/SemaTemplate/canonical-expr-type.cpp (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/check-globals.test (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/global-hex-value-regex.test (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/global-value-regex.test (+1-1)
  • (modified) clang/unittests/Analysis/CFGTest.cpp (+1-1)
  • (modified) clang/unittests/Basic/SourceManagerTest.cpp (+1-1)
  • (modified) clang/utils/TableGen/ClangAttrEmitter.cpp (+1-1)
  • (modified) cmake/Modules/EnableLanguageNolink.cmake (+2-2)
  • (modified) compiler-rt/cmake/Modules/CompilerRTDarwinUtils.cmake (+1-1)
  • (modified) compiler-rt/cmake/Modules/CompilerRTUtils.cmake (+1-1)
  • (modified) compiler-rt/lib/asan/asan_internal.h (+1-1)
  • (modified) compiler-rt/lib/asan/asan_poisoning.cpp (+3-3)
  • (modified) compiler-rt/lib/asan/asan_stats.cpp (+2-2)
  • (modified) compiler-rt/lib/builtins/negdi2.c (+1-1)
  • (modified) compiler-rt/lib/builtins/negti2.c (+1-1)
  • (modified) compiler-rt/lib/fuzzer/tests/FuzzerUnittest.cpp (+1-1)
  • (modified) compiler-rt/lib/hwasan/hwasan_linux.cpp (+1-1)
  • (modified) compiler-rt/lib/memprof/memprof_stats.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc (+4-4)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_flag_parser.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_interceptors_ioctl_netbsd.inc (+4-4)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_libc.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_mac.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_stacktrace.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_stacktrace_sparc.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_win.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/tests/sanitizer_procmaps_test.cpp (+1-1)
  • (modified) compiler-rt/lib/scudo/standalone/report.h (+1-1)
  • (modified) compiler-rt/lib/tsan/rtl/CMakeLists.txt (+1-1)
  • (modified) compiler-rt/lib/tsan/rtl/tsan_rtl.cpp (+3-3)
  • (modified) compiler-rt/lib/tsan/rtl/tsan_rtl_access.cpp (+1-1)
  • (modified) compiler-rt/lib/ubsan/ubsan_type_hash.h (+1-1)
  • (modified) compiler-rt/lib/ubsan/ubsan_type_hash_win.cpp (+1-1)
  • (modified) compiler-rt/lib/xray/tests/CMakeLists.txt (+1-1)
  • (modified) compiler-rt/test/BlocksRuntime/byrefsanity.c (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/Posix/unpoison-alternate-stack.cpp (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/sanity_check_pure_c.c (+2-2)
  • (modified) compiler-rt/test/builtins/Unit/atomic_test.c (+1-1)
  • (modified) compiler-rt/test/builtins/Unit/lit.cfg.py (+1-1)
  • (modified) compiler-rt/test/fuzzer/fuzzer-custommutator.test (+1-1)
  • (modified) compiler-rt/test/fuzzer/reload.test (+1-1)
  • (modified) compiler-rt/test/hwasan/TestCases/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/hwasan/TestCases/sanitizer_malloc.cpp (+1-1)
  • (modified) compiler-rt/test/msan/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/safestack/canary.c (+1-1)
  • (modified) compiler-rt/utils/generate_netbsd_ioctls.awk (+3-3)
  • (modified) compiler-rt/utils/generate_netbsd_syscalls.awk (+1-1)
  • (modified) flang-rt/unittests/Runtime/CharacterTest.cpp (+1-1)
  • (modified) flang-rt/unittests/Runtime/ExternalIOTest.cpp (+1-1)
  • (modified) flang/lib/Decimal/decimal-to-binary.cpp (+1-1)
  • (modified) flang/lib/Evaluate/fold-character.cpp (+1-1)
  • (modified) flang/lib/Evaluate/formatting.cpp (+1-1)
  • (modified) flang/lib/Evaluate/integer.cpp (+1-1)
  • (modified) flang/lib/Frontend/CompilerInstance.cpp (+1-1)
  • (modified) flang/lib/Lower/Bridge.cpp (+1-1)
  • (modified) flang/lib/Lower/ConvertVariable.cpp (+1-1)
  • (modified) flang/lib/Optimizer/Builder/FIRBuilder.cpp (+1-1)
  • (modified) flang/lib/Parser/preprocessor.cpp (+1-1)
  • (modified) flang/test/Driver/fopenmp.f90 (+1-1)
  • (modified) flang/test/Fir/convert-to-llvm.fir (+1-1)
  • (modified) flang/test/Semantics/modfile55.cuf (+1-1)
  • (modified) flang/test/Semantics/resolve59.f90 (+1-1)
  • (modified) flang/test/Semantics/symbol19.f90 (+1-1)
  • (modified) flang/unittests/Frontend/CompilerInstanceTest.cpp (+1-1)
  • (modified) libcxx/docs/DesignDocs/FileTimeType.rst (+2-2)
  • (modified) libcxx/docs/Status/Cxx20Papers.csv (+1-1)
  • (modified) libcxx/include/__cxx03/__hash_table (+1-1)
  • (modified) libcxx/include/__cxx03/__tree (+1-1)
  • (modified) libcxx/include/__hash_table (+1-1)
  • (modified) libcxx/include/__tree (+1-1)
  • (modified) libcxx/test/libcxx-03/numerics/bit.ops.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/extents/assert.ctor_from_span.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/layout_stride/assert.conversion.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/mdspan/assert.size.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/debug/containers/sequence_container_iterators.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/input.output/filesystems/convert_file_time.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/numerics/bit.ops.pass.cpp (+1-1)
  • (modified) libcxx/test/std/atomics/atomics.lockfree/is_always_lock_free.pass.cpp (+1-1)
  • (modified) libcxx/test/std/atomics/atomics.ref/is_always_lock_free.pass.cpp (+1-1)
  • (modified) libcxx/test/std/concepts/concepts.lang/concept.convertible/convertible_to.pass.cpp (+1-1)
  • (modified) libcxx/test/std/concepts/concepts.lang/concept.swappable/swappable.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/container.adaptors/priority.queue/priqueue.cons/ctor_iter_constraint.compile.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/sequences/array/empty.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/sequences/array/max_size.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/extents/conversion.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/ctor.layout_right.pass.cpp (+2-2)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/ctor.mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/ctor.layout_left.pass.cpp (+2-2)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/ctor.mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_stride/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_stride/ctor.strided_mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_array.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_extents.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_integers.pass.cpp (+4-4)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_map.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_map_acc.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_span.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/types.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/filesystems/fs.op.funcs/fs.op.space/space.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/istringstream/istringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/stringstream/stringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/compare_strong_order_fallback.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/compare_weak_order_fallback.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/strong_order.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/weak_order.pass.cpp (+1-1)
  • (modified) libcxx/test/std/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/utf_sanity_check.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/c.math/hermite.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/exclusive.scan/exclusive_scan.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan_op.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan_op_init.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/numeric.ops.midpoint/midpoint.float.pass.cpp (+2-2)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.exclusive.scan/transform_exclusive_scan_init_bop_uop.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.inclusive.scan/transform_inclusive_scan_bop_uop.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.inclusive.scan/transform_inclusive_scan_bop_uop_init.pass.cpp (+1-1)
  • (modified) libcxx/test/std/strings/string.view/string.view.capacity/capacity.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/lock.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/try_lock.pass.cpp (+1-1)
  • (modified) libcxx/test/std/utilities/allocator.adaptor/allocator.adaptor.types/is_always_equal.pass.cpp (+1-1)
  • (modified) libcxx/test/std/utilities/meta/meta.const.eval/is_constant_evaluated.pass.cpp (+1-1)
  • (modified) libcxx/test/support/filesystem_test_helper.h (+1-1)
  • (modified) libcxx/test/support/test_comparisons.h (+1-1)
  • (modified) libcxxabi/src/stdlib_new_delete.cpp (+1-1)
  • (modified) libcxxabi/test/guard_threaded_test.pass.cpp (+1-1)
  • (modified) lld/ELF/InputSection.cpp (+1-1)
  • (modified) lld/ELF/ScriptParser.cpp (+1-1)
  • (modified) lld/include/lld/Common/ErrorHandler.h (+1-1)
  • (modified) lld/test/COFF/guard-warnings.s (+1-1)
  • (modified) lld/test/ELF/gc-sections-no-undef-error.s (+1-1)
  • (modified) lld/test/ELF/lto/save-temps-eq.ll (+1-1)
  • (modified) lld/test/MachO/eh-frame-personality-dedup.s (+1-1)
  • (modified) lld/test/MachO/icf-only-lsda-folded.s (+1-1)
  • (modified) lldb/examples/summaries/cocoa/objc_runtime.py (+4-4)
  • (modified) lldb/packages/Python/lldbsuite/test/dotest.py (+1-1)
  • (modified) lldb/source/API/SBCommandInterpreter.cpp (+2-2)
  • (modified) lldb/source/Commands/CommandCompletions.cpp (+1-1)
  • (modified) lldb/source/Commands/CommandObjectWatchpoint.cpp (+2-2)
  • (modified) lldb/source/Commands/CommandObjectWatchpointCommand.cpp (+1-1)
  • (modified) lldb/source/Core/SourceManager.cpp (+1-1)
  • (modified) lldb/source/Expression/FunctionCaller.cpp (+1-1)
  • (modified) lldb/source/Expression/REPL.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/Mips/ABISysV_mips64.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/PowerPC/ABISysV_ppc.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/X86/ABISysV_x86_64.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/X86/ABIWindows_x86_64.cpp (+1-1)
  • (modified) lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOS.cpp (+1-1)
  • (modified) lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp (+1-1)
  • (modified) lldb/source/Plugins/ExpressionParser/Clang/CppModuleConfiguration.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/FreeBSD/NativeProcessFreeBSD.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/NetBSD/NativeProcessNetBSD.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/elf-core/ProcessElfCore.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp (+2-2)
  • (modified) lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp (+2-2)
  • (modified) lldb/source/Plugins/Trace/intel-pt/TraceIntelPTBundleLoader.cpp (+1-1)
  • (modified) lldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp (+1-1)
  • (modified) lldb/source/Plugins/UnwindAssembly/x86/UnwindAssembly-x86.cpp (+2-2)
  • (modified) lldb/source/Symbol/Symbol.cpp (+2-2)
  • (modified) lldb/source/Target/RegisterContextUnwind.cpp (+1-1)
  • (modified) lldb/source/Target/ThreadPlanStepInRange.cpp (+1-1)
  • (modified) lldb/source/Target/ThreadPlanStepOverRange.cpp (+2-2)
  • (modified) lldb/source/Utility/ZipFile.cpp (+3-3)
  • (modified) lldb/test/API/api/check_public_api_headers/TestPublicAPIHeaders.py (+1-1)
  • (modified) lldb/test/API/commands/frame/recognizer/TestFrameRecognizer.py (+1-1)
  • (modified) lldb/test/API/commands/memory/read/TestMemoryRead.py (+1-1)
  • (modified) lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/invalid-string/TestDataFormatterLibcxxInvalidString.py (+1-1)
  • (modified) lldb/test/API/functionalities/data-formatter/stringprinter/main.cpp (+1-1)
  • (modified) lldb/test/API/functionalities/limit-debug-info/TestLimitDebugInfo.py (+2-2)
  • (modified) lldb/test/API/functionalities/process_crash_info/TestProcessCrashInfo.py (+1-1)
  • (modified) lldb/test/API/lang/c/array_types/TestArrayTypes.py (+5-5)
  • (modified) lldb/test/API/lang/cpp/dynamic-value/TestDynamicValue.py (+1-1)
  • (modified) lldb/test/API/lang/cpp/incomplete-types/members/TestCppIncompleteTypeMembers.py (+1-1)
  • (modified) lldb/test/API/macosx/no-nlist-memory-module/TestNoNlistsDylib.py (+1-1)
  • (modified) lldb/test/API/macosx/simulator/TestSimulatorPlatform.py (+1-1)
  • (modified) lldb/test/API/python_api/value/linked_list/TestValueAPILinkedList.py (+2-2)
  • (modified) lldb/test/API/sanity/TestModuleCacheSanity.py (+1-1)
  • (modified) lldb/test/API/sanity/TestReprStrEquality.py (+1-1)
  • (modified) lldb/test/API/sanity/TestSettingSkipping.py (+1-1)
  • (modified) lldb/test/API/tools/lldb-server/memory-tagging/TestGdbRemoteMemoryTagging.py (+2-2)
  • (modified) lldb/test/Shell/REPL/Basic.test (+1-1)
  • (modified) lldb/test/Shell/Settings/TestModuleCacheSanity.test (+1-1)
  • (modified) lldb/tools/debugserver/source/MacOSX/arm64/DNBArchImplARM64.cpp (+1-1)
  • (modified) lldb/tools/lldb-rpc-gen/server/RPCServerSourceEmitter.cpp (+1-1)
  • (modified) lldb/unittests/Interpreter/TestCompletion.cpp (+1-1)
  • (modified) llvm/CMakeLists.txt (+1-1)
  • (modified) llvm/cmake/platforms/WinMsvc.cmake (+1-1)
  • (modified) llvm/docs/Atomics.rst (+1-1)
  • (modified) llvm/docs/CMake.rst (+1-1)
  • (modified) llvm/docs/CodingStandards.rst (+1-1)
  • (modified) llvm/docs/Contributing.rst (+1-1)
  • (modified) llvm/docs/Frontend/PerformanceTips.rst (+1-1)
  • (modified) llvm/docs/GettingStarted.rst (+1-1)
  • (modified) llvm/docs/LibFuzzer.rst (+1-1)
  • (modified) llvm/include/llvm-c/Core.h (+1-1)
  • (modified) llvm/include/llvm/ADT/APSInt.h (+1-1)
  • (modified) llvm/include/llvm/ADT/IntervalMap.h (+2-2)
  • (modified) llvm/include/llvm/CodeGen/MachineRegisterInfo.h (+1-1)
  • (modified) llvm/include/llvm/CodeGen/SelectionDAG.h (+1-1)
  • (modified) llvm/include/llvm/DebugInfo/DWARF/DWARFDebugFrame.h (+1-1)
  • (modified) llvm/include/llvm/IR/IntrinsicsARM.td (+1-1)
  • (modified) llvm/include/llvm/ProfileData/MemProfReader.h (+3-3)
diff --git a/bolt/lib/Passes/CMOVConversion.cpp b/bolt/lib/Passes/CMOVConversion.cpp
index cdd99b55207e0..10372416a9acd 100644
--- a/bolt/lib/Passes/CMOVConversion.cpp
+++ b/bolt/lib/Passes/CMOVConversion.cpp
@@ -66,7 +66,7 @@ bool isIfThenSubgraph(const BinaryBasicBlock &LHS,
   if (LHS.pred_size() != 2 || RHS.pred_size() != 1)
     return false;
 
-  // Sanity check
+  // Soundness check
   BinaryBasicBlock *Predecessor = *RHS.pred_begin();
   assert(Predecessor && LHS.isPredecessor(Predecessor) && "invalid subgraph");
   (void)Predecessor;
diff --git a/bolt/lib/Passes/IndirectCallPromotion.cpp b/bolt/lib/Passes/IndirectCallPromotion.cpp
index 8a01cb974c5da..dff1989c016b5 100644
--- a/bolt/lib/Passes/IndirectCallPromotion.cpp
+++ b/bolt/lib/Passes/IndirectCallPromotion.cpp
@@ -597,7 +597,7 @@ IndirectCallPromotion::findCallTargetSymbols(std::vector<Callsite> &Targets,
       std::vector<uint64_t>({JTIndex}).swap(NewTargets.back().JTIndices);
       llvm::erase(Target.JTIndices, JTIndex);
 
-      // Keep fixCFG counts sane if more indices use this same target later
+      // Keep fixCFG counts sound if more indices use this same target later
       assert(IndicesPerTarget[Target.To.Sym] > 0 && "wrong map");
       NewTargets.back().Branches =
           Target.Branches / IndicesPerTarget[Target.To.Sym];
diff --git a/bolt/lib/Profile/YAMLProfileReader.cpp b/bolt/lib/Profile/YAMLProfileReader.cpp
index 086e47b661e10..62190397b2be3 100644
--- a/bolt/lib/Profile/YAMLProfileReader.cpp
+++ b/bolt/lib/Profile/YAMLProfileReader.cpp
@@ -385,7 +385,7 @@ Error YAMLProfileReader::preprocessProfile(BinaryContext &BC) {
     return errorCodeToError(YamlInput.error());
   }
 
-  // Sanity check.
+  // Soundness check.
   if (YamlBP.Header.Version != 1)
     return make_error<StringError>(
         Twine("cannot read profile : unsupported version"),
diff --git a/bolt/lib/Rewrite/RewriteInstance.cpp b/bolt/lib/Rewrite/RewriteInstance.cpp
index a6e4dbc9c192f..871453b0ec5db 100644
--- a/bolt/lib/Rewrite/RewriteInstance.cpp
+++ b/bolt/lib/Rewrite/RewriteInstance.cpp
@@ -637,7 +637,7 @@ Error RewriteInstance::discoverStorage() {
     // If user specified a custom address where we should start writing new
     // data, honor that.
     NextAvailableAddress = opts::CustomAllocationVMA;
-    // Sanity check the user-supplied address and emit warnings if something
+    // Soundness check the user-supplied address and emit warnings if something
     // seems off.
     for (const ELF64LE::Phdr &Phdr : PHs) {
       switch (Phdr.p_type) {
@@ -2985,7 +2985,7 @@ void RewriteInstance::handleRelocation(const SectionRef &RelocatedSection,
     }
 
     if (BinaryData *BD = BC->getBinaryDataContainingAddress(SymbolAddress)) {
-      // Note: this assertion is trying to check sanity of BinaryData objects
+      // Note: this assertion is trying to check soundness of BinaryData objects
       // but AArch64 and RISCV has inferred and incomplete object locations
       // coming from GOT/TLS or any other non-trivial relocation (that requires
       // creation of sections and whose symbol address is not really what should
diff --git a/bolt/runtime/instr.cpp b/bolt/runtime/instr.cpp
index 1f54a500dbf98..97b49327ac484 100644
--- a/bolt/runtime/instr.cpp
+++ b/bolt/runtime/instr.cpp
@@ -819,7 +819,7 @@ ProfileWriterContext readDescriptions() {
 #endif
 
 #if !defined(__APPLE__)
-/// Debug by printing overall metadata global numbers to check it is sane
+/// Debug by printing overall metadata global numbers to check it is sound
 void printStats(const ProfileWriterContext &Ctx) {
   char StatMsg[BufSize];
   char *StatPtr = StatMsg;
diff --git a/bolt/test/AArch64/hook-fini.s b/bolt/test/AArch64/hook-fini.s
index 4f321d463ef32..4051546724748 100644
--- a/bolt/test/AArch64/hook-fini.s
+++ b/bolt/test/AArch64/hook-fini.s
@@ -4,7 +4,7 @@
 ## dynamic).
 ## All tests perform the following steps:
 ## - Compile and link for the case to be tested
-## - Some sanity-checks on the dynamic section and relocations in the binary to
+## - Some soundness-checks on the dynamic section and relocations in the binary to
 ##   verify it has the shape we want for testing:
 ##   - DT_FINI or DT_FINI_ARRAY in dynamic section
 ##   - No relative relocations for non-PIE
diff --git a/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s b/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
index 8e991fade2c86..c0a69a75b0d1b 100644
--- a/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
+++ b/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
@@ -272,7 +272,7 @@ lr_clobbered_nocfg:
         ret
         .size lr_clobbered_nocfg, .-lr_clobbered_nocfg
 
-/// Now do a basic sanity check on every different Authentication instruction:
+/// Now do a basic soundness check on every different Authentication instruction:
 
         .globl  f_autiasp
         .type   f_autiasp,@function
diff --git a/bolt/test/runtime/AArch64/hook-fini.test b/bolt/test/runtime/AArch64/hook-fini.test
index 8d23b21b6d612..43cc832e429ed 100644
--- a/bolt/test/runtime/AArch64/hook-fini.test
+++ b/bolt/test/runtime/AArch64/hook-fini.test
@@ -4,7 +4,7 @@
 # dynamic).
 # All tests perform the following steps:
 # - Compile and link for the case to be tested
-# - Some sanity-checks on the dynamic section and relocations in the binary to
+# - Some soundness-checks on the dynamic section and relocations in the binary to
 #   verify it has the shape we want for testing:
 #   - DT_FINI or DT_FINI_ARRAY in dynamic section
 #   - No relative relocations for non-PIE
diff --git a/bolt/tools/merge-fdata/merge-fdata.cpp b/bolt/tools/merge-fdata/merge-fdata.cpp
index cfcb9373548a1..9e55ad39427d4 100644
--- a/bolt/tools/merge-fdata/merge-fdata.cpp
+++ b/bolt/tools/merge-fdata/merge-fdata.cpp
@@ -428,7 +428,7 @@ int main(int argc, char **argv) {
     if (YamlInput.error())
       report_error(InputDataFilename, YamlInput.error());
 
-    // Sanity check.
+    // Soundness check.
     if (BP.Header.Version != 1) {
       errs() << "Unable to merge data from profile using version "
              << BP.Header.Version << '\n';
diff --git a/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp b/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
index d911b58cb8b7e..4b8b411bcc2ef 100644
--- a/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
+++ b/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
@@ -40,7 +40,7 @@ void ExplicitMakePairCheck::check(const MatchFinder::MatchResult &Result) {
   const auto *Call = Result.Nodes.getNodeAs<CallExpr>("call");
   const auto *DeclRef = Result.Nodes.getNodeAs<DeclRefExpr>("declref");
 
-  // Sanity check: The use might have overriden ::std::make_pair.
+  // Soundness check: The use might have overriden ::std::make_pair.
   if (Call->getNumArgs() != 2)
     return;
 
diff --git a/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp b/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
index 3f5cd4b473903..ac66c5bc5d66a 100644
--- a/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
+++ b/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
@@ -99,7 +99,7 @@ void MultiwayPathsCoveredCheck::check(const MatchFinder::MatchResult &Result) {
   bool SwitchHasDefault = false;
   std::tie(SwitchCaseCount, SwitchHasDefault) = countCaseLabels(Switch);
 
-  // Checks the sanity of 'switch' statements that actually do define
+  // Checks the soundness of 'switch' statements that actually do define
   // a default branch but might be degenerated by having no or only one case.
   if (SwitchHasDefault) {
     handleSwitchWithDefault(Switch, SwitchCaseCount);
diff --git a/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp b/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
index 712f390765957..f22118d5cb7e4 100644
--- a/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
+++ b/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
@@ -92,7 +92,7 @@ template <typename T, unsigned SmallSize> class SmartSmallSetVector {
   void populateSet() {
     assert(Set.empty() && "Should not have already utilized the Set.");
     // Magical growth factor prediction - to how many elements do we expect to
-    // sanely grow after switching away from small-size storage?
+    // soundly grow after switching away from small-size storage?
     const size_t NewMaxElts = 4 * Vector.size();
     Vector.reserve(NewMaxElts);
     Set.reserve(NewMaxElts);
diff --git a/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp b/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
index 2f59aaa86b157..b0e4efcbc5cba 100644
--- a/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
+++ b/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
@@ -133,7 +133,7 @@ struct CognitiveComplexity final {
                 "that in terms of stack usage. "
                 "Thus, it is good to minimize the size of the Detail struct.");
   SmallVector<Detail, DefaultLimit> Details; // 25 elements is 200 bytes.
-  // Yes, 25 is a magic number. This is the seemingly-sane default for the
+  // Yes, 25 is a magic number. This is the seemingly-sound default for the
   // upper limit for function cognitive complexity. Thus it would make sense
   // to avoid allocations for any function that does not violate the limit.
 
diff --git a/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp b/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
index 6bb8c394f75cc..1aaad01dea13f 100644
--- a/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
+++ b/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
@@ -61,7 +61,7 @@ void NamedParameterCheck::check(const MatchFinder::MatchResult &Result) {
         Parm->getType()->isSpecificBuiltinType(BuiltinType::Int))
       continue;
 
-    // Sanity check the source locations.
+    // Soundness check the source locations.
     if (!Parm->getLocation().isValid() || Parm->getLocation().isMacroID() ||
         !SM.isWrittenInSameFile(Parm->getBeginLoc(), Parm->getLocation()))
       continue;
diff --git a/clang-tools-extra/clangd/CodeCompletionStrings.cpp b/clang-tools-extra/clangd/CodeCompletionStrings.cpp
index 9c4241b54057a..a26b36db7ecad 100644
--- a/clang-tools-extra/clangd/CodeCompletionStrings.cpp
+++ b/clang-tools-extra/clangd/CodeCompletionStrings.cpp
@@ -123,7 +123,7 @@ std::string getDeclComment(const ASTContext &Ctx, const NamedDecl &Decl) {
     if (!RC)
       return "";
 
-    // Sanity check that the comment does not come from the PCH. We choose to
+    // Soundness check that the comment does not come from the PCH. We choose to
     // not write them into PCH, because they are racy and slow to load.
     assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
 
@@ -146,7 +146,7 @@ std::string getDeclComment(const ASTContext &Ctx, const NamedDecl &Decl) {
     RC = getCompletionComment(Ctx, &Decl);
     if (!RC)
       return "";
-    // Sanity check that the comment does not come from the PCH. We choose to
+    // Soundness check that the comment does not come from the PCH. We choose to
     // not write them into PCH, because they are racy and slow to load.
     assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
     Doc = RC->getFormattedText(Ctx.getSourceManager(), Ctx.getDiagnostics());
diff --git a/clang-tools-extra/clangd/Compiler.cpp b/clang-tools-extra/clangd/Compiler.cpp
index 8b3865c8a8e5c..ba8766663c411 100644
--- a/clang-tools-extra/clangd/Compiler.cpp
+++ b/clang-tools-extra/clangd/Compiler.cpp
@@ -100,7 +100,7 @@ buildCompilerInvocation(const ParseInputs &Inputs, clang::DiagnosticConsumer &D,
   std::vector<const char *> ArgStrs;
   ArgStrs.reserve(Argv.size() + 1);
   // In asserts builds, CompilerInvocation redundantly reads/parses cc1 args as
-  // a sanity test. This is not useful to clangd, and costs 10% of test time.
+  // a soundness test. This is not useful to clangd, and costs 10% of test time.
   // To avoid mismatches between assert/production builds, disable it always.
   ArgStrs = {Argv.front().c_str(), "-Xclang", "-no-round-trip-args"};
   for (const auto &S : Argv.drop_front())
diff --git a/clang-tools-extra/clangd/XRefs.cpp b/clang-tools-extra/clangd/XRefs.cpp
index e1c50f906de08..17141a52afc6c 100644
--- a/clang-tools-extra/clangd/XRefs.cpp
+++ b/clang-tools-extra/clangd/XRefs.cpp
@@ -972,7 +972,7 @@ class ReferenceFinder : public index::IndexDataConsumer {
                      llvm::dyn_cast_or_null<ObjCMethodDecl>(ASTNode.OrigD)) {
         OMD->getSelectorLocs(Locs);
       }
-      // Sanity check: we expect the *first* token to match the reported loc.
+      // Soundness check: we expect the *first* token to match the reported loc.
       // Otherwise, maybe it was e.g. some other kind of reference to a Decl.
       if (!Locs.empty() && Locs.front() != Loc)
         Locs.clear(); // First token doesn't match, assume our guess was wrong.
diff --git a/clang-tools-extra/clangd/index/IndexAction.cpp b/clang-tools-extra/clangd/index/IndexAction.cpp
index ed56c2a9d2e81..d9d9cd0f40942 100644
--- a/clang-tools-extra/clangd/index/IndexAction.cpp
+++ b/clang-tools-extra/clangd/index/IndexAction.cpp
@@ -106,7 +106,7 @@ struct IncludeGraphCollector : public PPCallbacks {
     NodeForIncluding.first->getValue().DirectIncludes.push_back(NodeForInclude);
   }
 
-  // Sanity check to ensure we have already populated a skipped file.
+  // Soundness check to ensure we have already populated a skipped file.
   void FileSkipped(const FileEntryRef &SkippedFile, const Token &FilenameTok,
                    SrcMgr::CharacteristicKind FileType) override {
 #ifndef NDEBUG
diff --git a/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp b/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
index ada14c9939318..1c443c50866e2 100644
--- a/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
+++ b/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
@@ -854,7 +854,7 @@ TEST(BackgroundQueueTest, Progress) {
   using testing::AnyOf;
   BackgroundQueue::Stats S;
   BackgroundQueue Q([&](BackgroundQueue::Stats New) {
-    // Verify values are sane.
+    // Verify values are sound.
     // Items are enqueued one at a time (at least in this test).
     EXPECT_THAT(New.Enqueued, AnyOf(S.Enqueued, S.Enqueued + 1));
     // Items are completed one at a time.
diff --git a/clang-tools-extra/clangd/unittests/ClangdTests.cpp b/clang-tools-extra/clangd/unittests/ClangdTests.cpp
index 9ea7c3e02411d..63c92671a621a 100644
--- a/clang-tools-extra/clangd/unittests/ClangdTests.cpp
+++ b/clang-tools-extra/clangd/unittests/ClangdTests.cpp
@@ -919,7 +919,7 @@ int d;
   StartSecond.wait();
   Server.addDocument(FooCpp, SourceContentsWithoutErrors);
   ASSERT_TRUE(Server.blockUntilIdleForTest()) << "Waiting for diagnostics";
-  ASSERT_EQ(DiagConsumer.Count, 2); // Sanity check - we actually ran both?
+  ASSERT_EQ(DiagConsumer.Count, 2); // Soundness check - we actually ran both?
 }
 
 TEST(ClangdServerTest, FormatCode) {
diff --git a/clang-tools-extra/clangd/unittests/QualityTests.cpp b/clang-tools-extra/clangd/unittests/QualityTests.cpp
index 4954659a45e02..1e6d34d58fcc1 100644
--- a/clang-tools-extra/clangd/unittests/QualityTests.cpp
+++ b/clang-tools-extra/clangd/unittests/QualityTests.cpp
@@ -10,7 +10,7 @@
 // For interesting cases, both exact scores and "X beats Y" are too brittle to
 // make good hard assertions.
 //
-// Here we test the signal extraction and sanity-check that signals point in
+// Here we test the signal extraction and soundness-check that signals point in
 // the right direction. This should be supplemented by quality metrics which
 // we can compute from a corpus of queries and preferred rankings.
 //
diff --git a/clang-tools-extra/clangd/unittests/RenameTests.cpp b/clang-tools-extra/clangd/unittests/RenameTests.cpp
index 5d2a77b62a219..b23d62e37e068 100644
--- a/clang-tools-extra/clangd/unittests/RenameTests.cpp
+++ b/clang-tools-extra/clangd/unittests/RenameTests.cpp
@@ -1444,7 +1444,7 @@ TEST(RenameTest, IndexMergeMainFile) {
   EXPECT_THAT(Results.GlobalChanges[Main].asTextEdits(),
               ElementsAre(newText("xPrime")));
 
-  // Sanity check: we do expect to see index results!
+  // Soundness check: we do expect to see index results!
   TU.Filename = "other.cc";
   Results = Rename(TU.index().get());
   EXPECT_THAT(Results.GlobalChanges.keys(),
diff --git a/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp b/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
index 4d1ca669b8d03..c846291329831 100644
--- a/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
+++ b/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
@@ -1,4 +1,4 @@
-// Sanity-check. Run without modules:
+// Soundness-check. Run without modules:
 // RUN: rm -rf %t
 // RUN: mkdir %t
 // RUN: cp %S/Inputs/expand-modular-headers-ppcallbacks/* %t/
diff --git a/clang/docs/AutomaticReferenceCounting.rst b/clang/docs/AutomaticReferenceCounting.rst
index 80bbd25121148..b10e3635e1d5b 100644
--- a/clang/docs/AutomaticReferenceCounting.rst
+++ b/clang/docs/AutomaticReferenceCounting.rst
@@ -1993,7 +1993,7 @@ A program is ill-formed if it refers to the ``NSAutoreleasePool`` class.
   dependencies between two calls.  It is also very easy to accidentally forget
   to drain an autorelease pool when using the manual API, and this can
   significantly inflate the process's high-water-mark.  The introduction of a
-  new scope is unfortunate but basically required for sane interaction with the
+  new scope is unfortunate but basically required for sound interaction with the
   rest of the language.  Not draining the pool during an unwind is apparently
   required by the Objective-C exceptions implementation.
 
diff --git a/clang/docs/InternalsManual.rst b/clang/docs/InternalsManual.rst
index bd742273f4ed5..411d3ee3ecec0 100644
--- a/clang/docs/InternalsManual.rst
+++ b/clang/docs/InternalsManual.rst
@@ -82,7 +82,7 @@ using it.  From this file, :program:`tblgen` generates the unique ID of the
 diagnostic, the severity of the diagnostic and the English translation + format
 string.
 
-There is little sanity with the naming of the unique ID's right now.  Some
+There is little soundness with the naming of the unique ID's right now.  Some
 start with ``err_``, ``warn_``, ``ext_`` to encode the severity into the name.
 Since the enum is referenced in the C++ code that produces the diagnostic, it
 is somewhat useful for it to be reasonably short.
diff --git a/clang/docs/Modules.rst b/clang/docs/Modules.rst
index acbe45e0be970..515f5838dbe49 100644
--- a/clang/docs/Modules.rst
+++ b/clang/docs/Modules.rst
@@ -1099,7 +1099,7 @@ The module maps will be written using the `module map language`_, which provides
   Headers are often missing ``#include`` directives for headers that they actually depend on. As with the problem of conflicting definitions, this only affects unlucky users who don't happen to include headers in the right order. With modules, the headers of a particular module will be parsed in isolation, so the module may fail to build if there are missing includes.
 
 **Headers that vend multiple APIs at different times**
-  Some systems have headers that contain a number of different kinds of API definitions, only some of which are made available with a given include. For example, the header may vend ``size_t`` only when the macro ``__need_size_t`` is defined before that header is included, and also vend ``wchar_t`` only when the macro ``__need_wchar_t`` is defined. Such headers are often included many times in a single translation unit, and will have no include guards. There is no sane way to map this header to a submodule. One can either eliminate the header (e.g., by splitting it into separate headers, one per actual API) or simply ``exclude`` it in the module map.
+  Some systems have headers that contain a number of different kinds of API definitions, only some of which are made available with a given include. For example, the header may vend ``size_t`` only when the macro ``__need_size_t`` is defined before that header is included, and also vend...
[truncated]

@llvmbot
Copy link
Member

llvmbot commented Sep 5, 2025

@llvm/pr-subscribers-libcxx

Author: Rick van Voorden (vanvoorden)

Changes

Background

Inspired by swiftlang/swift#71167.

Searching through the repo, we see three main categories of changes:

  • Comments and Documentation
  • Constant Strings
  • Symbols

Ranking from "least" to "most" risky to land without causing any bugs or unintended consequences, let's start here with migrating comments and documentation.

Changes

  • sanity to soundness
  • sane to sound
  • insane to unsound
  • sanely to soundly

Patch is 337.82 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/156995.diff

443 Files Affected:

  • (modified) bolt/lib/Passes/CMOVConversion.cpp (+1-1)
  • (modified) bolt/lib/Passes/IndirectCallPromotion.cpp (+1-1)
  • (modified) bolt/lib/Profile/YAMLProfileReader.cpp (+1-1)
  • (modified) bolt/lib/Rewrite/RewriteInstance.cpp (+2-2)
  • (modified) bolt/runtime/instr.cpp (+1-1)
  • (modified) bolt/test/AArch64/hook-fini.s (+1-1)
  • (modified) bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s (+1-1)
  • (modified) bolt/test/runtime/AArch64/hook-fini.test (+1-1)
  • (modified) bolt/tools/merge-fdata/merge-fdata.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/CodeCompletionStrings.cpp (+2-2)
  • (modified) clang-tools-extra/clangd/Compiler.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/XRefs.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/index/IndexAction.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/ClangdTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/QualityTests.cpp (+1-1)
  • (modified) clang-tools-extra/clangd/unittests/RenameTests.cpp (+1-1)
  • (modified) clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp (+1-1)
  • (modified) clang/docs/AutomaticReferenceCounting.rst (+1-1)
  • (modified) clang/docs/InternalsManual.rst (+1-1)
  • (modified) clang/docs/Modules.rst (+1-1)
  • (modified) clang/docs/UsersManual.rst (+1-1)
  • (modified) clang/include/clang/Sema/Sema.h (+1-1)
  • (modified) clang/lib/AST/ASTStructuralEquivalence.cpp (+2-2)
  • (modified) clang/lib/AST/CommentSema.cpp (+1-1)
  • (modified) clang/lib/AST/TypePrinter.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGCXXABI.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGCall.cpp (+2-2)
  • (modified) clang/lib/CodeGen/CGExpr.cpp (+1-1)
  • (modified) clang/lib/CodeGen/CGStmt.cpp (+1-1)
  • (modified) clang/lib/Driver/Driver.cpp (+1-1)
  • (modified) clang/lib/Frontend/PrintPreprocessedOutput.cpp (+2-2)
  • (modified) clang/lib/Index/USRGeneration.cpp (+1-1)
  • (modified) clang/lib/Parse/ParseStmtAsm.cpp (+2-2)
  • (modified) clang/lib/Sema/SemaOpenACC.cpp (+1-1)
  • (modified) clang/lib/Sema/SemaOverload.cpp (+2-2)
  • (modified) clang/lib/Sema/SemaTemplateDeduction.cpp (+1-1)
  • (modified) clang/lib/StaticAnalyzer/Checkers/ArrayBoundChecker.cpp (+1-1)
  • (modified) clang/lib/StaticAnalyzer/Checkers/PthreadLockChecker.cpp (+1-1)
  • (modified) clang/test/AST/ByteCode/cxx11.cpp (+1-1)
  • (modified) clang/test/Analysis/return-value-guaranteed.cpp (+1-1)
  • (modified) clang/test/Analysis/std-variant-checker.cpp (+1-1)
  • (modified) clang/test/CodeGen/AArch64/inline-asm.c (+1-1)
  • (modified) clang/test/CodeGen/alloc-align-attr.c (+1-1)
  • (modified) clang/test/CodeGen/arm-target-features.c (+1-1)
  • (modified) clang/test/CodeGen/atomic-ops.c (+1-1)
  • (modified) clang/test/CodeGen/strictfp-elementwise-builtins.cpp (+1-1)
  • (modified) clang/test/CodeGen/union-init2.c (+1-1)
  • (modified) clang/test/CodeGenCXX/OmitRTTIComponentABI/simple-vtable-definition.cpp (+1-1)
  • (modified) clang/test/CodeGenCXX/cxx11-user-defined-literal.cpp (+1-1)
  • (modified) clang/test/CodeGenCXX/type-aware-allocators.cpp (+1-1)
  • (modified) clang/test/CodeGenHLSL/GlobalDestructors.hlsl (+1-1)
  • (modified) clang/test/CodeGenHLSL/RootSignature.hlsl (+1-1)
  • (modified) clang/test/Driver/aix-as.c (+1-1)
  • (modified) clang/test/Driver/aix-ld.c (+1-1)
  • (modified) clang/test/Driver/as-dwarf-cie.s (+1-1)
  • (modified) clang/test/Driver/fopenmp.c (+1-1)
  • (modified) clang/test/Driver/linux-header-search.cpp (+1-1)
  • (modified) clang/test/Driver/linux-ld.c (+1-1)
  • (modified) clang/test/Driver/solaris-ld-values.c (+1-1)
  • (modified) clang/test/Driver/solaris-ld-values.cpp (+1-1)
  • (modified) clang/test/Driver/solaris-ld.c (+1-1)
  • (modified) clang/test/PCH/floating-literal.c (+1-1)
  • (modified) clang/test/SemaCXX/constant-expression-cxx11.cpp (+1-1)
  • (modified) clang/test/SemaCXX/constant-expression-cxx14.cpp (+1-1)
  • (modified) clang/test/SemaCXX/enable_if.cpp (+1-1)
  • (modified) clang/test/SemaCXX/overload-resolution-deferred-templates.cpp (+1-1)
  • (modified) clang/test/SemaCXX/vtable_pointer_authentication_attribute.cpp (+2-2)
  • (modified) clang/test/SemaTemplate/canonical-expr-type.cpp (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/check-globals.test (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/global-hex-value-regex.test (+1-1)
  • (modified) clang/test/utils/update_cc_test_checks/global-value-regex.test (+1-1)
  • (modified) clang/unittests/Analysis/CFGTest.cpp (+1-1)
  • (modified) clang/unittests/Basic/SourceManagerTest.cpp (+1-1)
  • (modified) clang/utils/TableGen/ClangAttrEmitter.cpp (+1-1)
  • (modified) cmake/Modules/EnableLanguageNolink.cmake (+2-2)
  • (modified) compiler-rt/cmake/Modules/CompilerRTDarwinUtils.cmake (+1-1)
  • (modified) compiler-rt/cmake/Modules/CompilerRTUtils.cmake (+1-1)
  • (modified) compiler-rt/lib/asan/asan_internal.h (+1-1)
  • (modified) compiler-rt/lib/asan/asan_poisoning.cpp (+3-3)
  • (modified) compiler-rt/lib/asan/asan_stats.cpp (+2-2)
  • (modified) compiler-rt/lib/builtins/negdi2.c (+1-1)
  • (modified) compiler-rt/lib/builtins/negti2.c (+1-1)
  • (modified) compiler-rt/lib/fuzzer/tests/FuzzerUnittest.cpp (+1-1)
  • (modified) compiler-rt/lib/hwasan/hwasan_linux.cpp (+1-1)
  • (modified) compiler-rt/lib/memprof/memprof_stats.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc (+4-4)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_flag_parser.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_interceptors_ioctl_netbsd.inc (+4-4)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_libc.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_mac.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_stacktrace.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_stacktrace_sparc.cpp (+2-2)
  • (modified) compiler-rt/lib/sanitizer_common/sanitizer_win.cpp (+1-1)
  • (modified) compiler-rt/lib/sanitizer_common/tests/sanitizer_procmaps_test.cpp (+1-1)
  • (modified) compiler-rt/lib/scudo/standalone/report.h (+1-1)
  • (modified) compiler-rt/lib/tsan/rtl/CMakeLists.txt (+1-1)
  • (modified) compiler-rt/lib/tsan/rtl/tsan_rtl.cpp (+3-3)
  • (modified) compiler-rt/lib/tsan/rtl/tsan_rtl_access.cpp (+1-1)
  • (modified) compiler-rt/lib/ubsan/ubsan_type_hash.h (+1-1)
  • (modified) compiler-rt/lib/ubsan/ubsan_type_hash_win.cpp (+1-1)
  • (modified) compiler-rt/lib/xray/tests/CMakeLists.txt (+1-1)
  • (modified) compiler-rt/test/BlocksRuntime/byrefsanity.c (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/Posix/unpoison-alternate-stack.cpp (+1-1)
  • (modified) compiler-rt/test/asan/TestCases/sanity_check_pure_c.c (+2-2)
  • (modified) compiler-rt/test/builtins/Unit/atomic_test.c (+1-1)
  • (modified) compiler-rt/test/builtins/Unit/lit.cfg.py (+1-1)
  • (modified) compiler-rt/test/fuzzer/fuzzer-custommutator.test (+1-1)
  • (modified) compiler-rt/test/fuzzer/reload.test (+1-1)
  • (modified) compiler-rt/test/hwasan/TestCases/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/hwasan/TestCases/sanitizer_malloc.cpp (+1-1)
  • (modified) compiler-rt/test/msan/Linux/syscalls.cpp (+1-1)
  • (modified) compiler-rt/test/safestack/canary.c (+1-1)
  • (modified) compiler-rt/utils/generate_netbsd_ioctls.awk (+3-3)
  • (modified) compiler-rt/utils/generate_netbsd_syscalls.awk (+1-1)
  • (modified) flang-rt/unittests/Runtime/CharacterTest.cpp (+1-1)
  • (modified) flang-rt/unittests/Runtime/ExternalIOTest.cpp (+1-1)
  • (modified) flang/lib/Decimal/decimal-to-binary.cpp (+1-1)
  • (modified) flang/lib/Evaluate/fold-character.cpp (+1-1)
  • (modified) flang/lib/Evaluate/formatting.cpp (+1-1)
  • (modified) flang/lib/Evaluate/integer.cpp (+1-1)
  • (modified) flang/lib/Frontend/CompilerInstance.cpp (+1-1)
  • (modified) flang/lib/Lower/Bridge.cpp (+1-1)
  • (modified) flang/lib/Lower/ConvertVariable.cpp (+1-1)
  • (modified) flang/lib/Optimizer/Builder/FIRBuilder.cpp (+1-1)
  • (modified) flang/lib/Parser/preprocessor.cpp (+1-1)
  • (modified) flang/test/Driver/fopenmp.f90 (+1-1)
  • (modified) flang/test/Fir/convert-to-llvm.fir (+1-1)
  • (modified) flang/test/Semantics/modfile55.cuf (+1-1)
  • (modified) flang/test/Semantics/resolve59.f90 (+1-1)
  • (modified) flang/test/Semantics/symbol19.f90 (+1-1)
  • (modified) flang/unittests/Frontend/CompilerInstanceTest.cpp (+1-1)
  • (modified) libcxx/docs/DesignDocs/FileTimeType.rst (+2-2)
  • (modified) libcxx/docs/Status/Cxx20Papers.csv (+1-1)
  • (modified) libcxx/include/__cxx03/__hash_table (+1-1)
  • (modified) libcxx/include/__cxx03/__tree (+1-1)
  • (modified) libcxx/include/__hash_table (+1-1)
  • (modified) libcxx/include/__tree (+1-1)
  • (modified) libcxx/test/libcxx-03/numerics/bit.ops.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/extents/assert.ctor_from_span.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/layout_stride/assert.conversion.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/containers/views/mdspan/mdspan/assert.size.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/debug/containers/sequence_container_iterators.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/input.output/filesystems/convert_file_time.pass.cpp (+1-1)
  • (modified) libcxx/test/libcxx/numerics/bit.ops.pass.cpp (+1-1)
  • (modified) libcxx/test/std/atomics/atomics.lockfree/is_always_lock_free.pass.cpp (+1-1)
  • (modified) libcxx/test/std/atomics/atomics.ref/is_always_lock_free.pass.cpp (+1-1)
  • (modified) libcxx/test/std/concepts/concepts.lang/concept.convertible/convertible_to.pass.cpp (+1-1)
  • (modified) libcxx/test/std/concepts/concepts.lang/concept.swappable/swappable.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/container.adaptors/priority.queue/priqueue.cons/ctor_iter_constraint.compile.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/sequences/array/empty.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/sequences/array/max_size.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/extents/conversion.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/ctor.layout_right.pass.cpp (+2-2)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_left/ctor.mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/ctor.layout_left.pass.cpp (+2-2)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_right/ctor.mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_stride/comparison.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/layout_stride/ctor.strided_mapping.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_array.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_extents.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_integers.pass.cpp (+4-4)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_map.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_map_acc.pass.cpp (+1-1)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/ctor.dh_span.pass.cpp (+3-3)
  • (modified) libcxx/test/std/containers/views/mdspan/mdspan/types.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/filesystems/fs.op.funcs/fs.op.space/space.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/istringstream/istringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/ostringstream/ostringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/input.output/string.streams/stringstream/stringstream.members/str.allocator_propagation.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/compare_strong_order_fallback.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/compare_weak_order_fallback.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/strong_order.pass.cpp (+1-1)
  • (modified) libcxx/test/std/language.support/cmp/cmp.alg/weak_order.pass.cpp (+1-1)
  • (modified) libcxx/test/std/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt.members/utf_sanity_check.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/c.math/hermite.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/exclusive.scan/exclusive_scan.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan_op.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/inclusive.scan/inclusive_scan_op_init.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/numeric.ops.midpoint/midpoint.float.pass.cpp (+2-2)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.exclusive.scan/transform_exclusive_scan_init_bop_uop.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.inclusive.scan/transform_inclusive_scan_bop_uop.pass.cpp (+1-1)
  • (modified) libcxx/test/std/numerics/numeric.ops/transform.inclusive.scan/transform_inclusive_scan_bop_uop_init.pass.cpp (+1-1)
  • (modified) libcxx/test/std/strings/string.view/string.view.capacity/capacity.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.cons/mutex.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/lock.pass.cpp (+1-1)
  • (modified) libcxx/test/std/thread/thread.mutex/thread.lock/thread.lock.shared/thread.lock.shared.locking/try_lock.pass.cpp (+1-1)
  • (modified) libcxx/test/std/utilities/allocator.adaptor/allocator.adaptor.types/is_always_equal.pass.cpp (+1-1)
  • (modified) libcxx/test/std/utilities/meta/meta.const.eval/is_constant_evaluated.pass.cpp (+1-1)
  • (modified) libcxx/test/support/filesystem_test_helper.h (+1-1)
  • (modified) libcxx/test/support/test_comparisons.h (+1-1)
  • (modified) libcxxabi/src/stdlib_new_delete.cpp (+1-1)
  • (modified) libcxxabi/test/guard_threaded_test.pass.cpp (+1-1)
  • (modified) lld/ELF/InputSection.cpp (+1-1)
  • (modified) lld/ELF/ScriptParser.cpp (+1-1)
  • (modified) lld/include/lld/Common/ErrorHandler.h (+1-1)
  • (modified) lld/test/COFF/guard-warnings.s (+1-1)
  • (modified) lld/test/ELF/gc-sections-no-undef-error.s (+1-1)
  • (modified) lld/test/ELF/lto/save-temps-eq.ll (+1-1)
  • (modified) lld/test/MachO/eh-frame-personality-dedup.s (+1-1)
  • (modified) lld/test/MachO/icf-only-lsda-folded.s (+1-1)
  • (modified) lldb/examples/summaries/cocoa/objc_runtime.py (+4-4)
  • (modified) lldb/packages/Python/lldbsuite/test/dotest.py (+1-1)
  • (modified) lldb/source/API/SBCommandInterpreter.cpp (+2-2)
  • (modified) lldb/source/Commands/CommandCompletions.cpp (+1-1)
  • (modified) lldb/source/Commands/CommandObjectWatchpoint.cpp (+2-2)
  • (modified) lldb/source/Commands/CommandObjectWatchpointCommand.cpp (+1-1)
  • (modified) lldb/source/Core/SourceManager.cpp (+1-1)
  • (modified) lldb/source/Expression/FunctionCaller.cpp (+1-1)
  • (modified) lldb/source/Expression/REPL.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/Mips/ABISysV_mips64.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/PowerPC/ABISysV_ppc.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/X86/ABISysV_x86_64.cpp (+1-1)
  • (modified) lldb/source/Plugins/ABI/X86/ABIWindows_x86_64.cpp (+1-1)
  • (modified) lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOS.cpp (+1-1)
  • (modified) lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp (+1-1)
  • (modified) lldb/source/Plugins/ExpressionParser/Clang/CppModuleConfiguration.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/FreeBSD/NativeProcessFreeBSD.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/NetBSD/NativeProcessNetBSD.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/elf-core/ProcessElfCore.cpp (+1-1)
  • (modified) lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp (+2-2)
  • (modified) lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp (+2-2)
  • (modified) lldb/source/Plugins/Trace/intel-pt/TraceIntelPTBundleLoader.cpp (+1-1)
  • (modified) lldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp (+1-1)
  • (modified) lldb/source/Plugins/UnwindAssembly/x86/UnwindAssembly-x86.cpp (+2-2)
  • (modified) lldb/source/Symbol/Symbol.cpp (+2-2)
  • (modified) lldb/source/Target/RegisterContextUnwind.cpp (+1-1)
  • (modified) lldb/source/Target/ThreadPlanStepInRange.cpp (+1-1)
  • (modified) lldb/source/Target/ThreadPlanStepOverRange.cpp (+2-2)
  • (modified) lldb/source/Utility/ZipFile.cpp (+3-3)
  • (modified) lldb/test/API/api/check_public_api_headers/TestPublicAPIHeaders.py (+1-1)
  • (modified) lldb/test/API/commands/frame/recognizer/TestFrameRecognizer.py (+1-1)
  • (modified) lldb/test/API/commands/memory/read/TestMemoryRead.py (+1-1)
  • (modified) lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/invalid-string/TestDataFormatterLibcxxInvalidString.py (+1-1)
  • (modified) lldb/test/API/functionalities/data-formatter/stringprinter/main.cpp (+1-1)
  • (modified) lldb/test/API/functionalities/limit-debug-info/TestLimitDebugInfo.py (+2-2)
  • (modified) lldb/test/API/functionalities/process_crash_info/TestProcessCrashInfo.py (+1-1)
  • (modified) lldb/test/API/lang/c/array_types/TestArrayTypes.py (+5-5)
  • (modified) lldb/test/API/lang/cpp/dynamic-value/TestDynamicValue.py (+1-1)
  • (modified) lldb/test/API/lang/cpp/incomplete-types/members/TestCppIncompleteTypeMembers.py (+1-1)
  • (modified) lldb/test/API/macosx/no-nlist-memory-module/TestNoNlistsDylib.py (+1-1)
  • (modified) lldb/test/API/macosx/simulator/TestSimulatorPlatform.py (+1-1)
  • (modified) lldb/test/API/python_api/value/linked_list/TestValueAPILinkedList.py (+2-2)
  • (modified) lldb/test/API/sanity/TestModuleCacheSanity.py (+1-1)
  • (modified) lldb/test/API/sanity/TestReprStrEquality.py (+1-1)
  • (modified) lldb/test/API/sanity/TestSettingSkipping.py (+1-1)
  • (modified) lldb/test/API/tools/lldb-server/memory-tagging/TestGdbRemoteMemoryTagging.py (+2-2)
  • (modified) lldb/test/Shell/REPL/Basic.test (+1-1)
  • (modified) lldb/test/Shell/Settings/TestModuleCacheSanity.test (+1-1)
  • (modified) lldb/tools/debugserver/source/MacOSX/arm64/DNBArchImplARM64.cpp (+1-1)
  • (modified) lldb/tools/lldb-rpc-gen/server/RPCServerSourceEmitter.cpp (+1-1)
  • (modified) lldb/unittests/Interpreter/TestCompletion.cpp (+1-1)
  • (modified) llvm/CMakeLists.txt (+1-1)
  • (modified) llvm/cmake/platforms/WinMsvc.cmake (+1-1)
  • (modified) llvm/docs/Atomics.rst (+1-1)
  • (modified) llvm/docs/CMake.rst (+1-1)
  • (modified) llvm/docs/CodingStandards.rst (+1-1)
  • (modified) llvm/docs/Contributing.rst (+1-1)
  • (modified) llvm/docs/Frontend/PerformanceTips.rst (+1-1)
  • (modified) llvm/docs/GettingStarted.rst (+1-1)
  • (modified) llvm/docs/LibFuzzer.rst (+1-1)
  • (modified) llvm/include/llvm-c/Core.h (+1-1)
  • (modified) llvm/include/llvm/ADT/APSInt.h (+1-1)
  • (modified) llvm/include/llvm/ADT/IntervalMap.h (+2-2)
  • (modified) llvm/include/llvm/CodeGen/MachineRegisterInfo.h (+1-1)
  • (modified) llvm/include/llvm/CodeGen/SelectionDAG.h (+1-1)
  • (modified) llvm/include/llvm/DebugInfo/DWARF/DWARFDebugFrame.h (+1-1)
  • (modified) llvm/include/llvm/IR/IntrinsicsARM.td (+1-1)
  • (modified) llvm/include/llvm/ProfileData/MemProfReader.h (+3-3)
diff --git a/bolt/lib/Passes/CMOVConversion.cpp b/bolt/lib/Passes/CMOVConversion.cpp
index cdd99b55207e0..10372416a9acd 100644
--- a/bolt/lib/Passes/CMOVConversion.cpp
+++ b/bolt/lib/Passes/CMOVConversion.cpp
@@ -66,7 +66,7 @@ bool isIfThenSubgraph(const BinaryBasicBlock &LHS,
   if (LHS.pred_size() != 2 || RHS.pred_size() != 1)
     return false;
 
-  // Sanity check
+  // Soundness check
   BinaryBasicBlock *Predecessor = *RHS.pred_begin();
   assert(Predecessor && LHS.isPredecessor(Predecessor) && "invalid subgraph");
   (void)Predecessor;
diff --git a/bolt/lib/Passes/IndirectCallPromotion.cpp b/bolt/lib/Passes/IndirectCallPromotion.cpp
index 8a01cb974c5da..dff1989c016b5 100644
--- a/bolt/lib/Passes/IndirectCallPromotion.cpp
+++ b/bolt/lib/Passes/IndirectCallPromotion.cpp
@@ -597,7 +597,7 @@ IndirectCallPromotion::findCallTargetSymbols(std::vector<Callsite> &Targets,
       std::vector<uint64_t>({JTIndex}).swap(NewTargets.back().JTIndices);
       llvm::erase(Target.JTIndices, JTIndex);
 
-      // Keep fixCFG counts sane if more indices use this same target later
+      // Keep fixCFG counts sound if more indices use this same target later
       assert(IndicesPerTarget[Target.To.Sym] > 0 && "wrong map");
       NewTargets.back().Branches =
           Target.Branches / IndicesPerTarget[Target.To.Sym];
diff --git a/bolt/lib/Profile/YAMLProfileReader.cpp b/bolt/lib/Profile/YAMLProfileReader.cpp
index 086e47b661e10..62190397b2be3 100644
--- a/bolt/lib/Profile/YAMLProfileReader.cpp
+++ b/bolt/lib/Profile/YAMLProfileReader.cpp
@@ -385,7 +385,7 @@ Error YAMLProfileReader::preprocessProfile(BinaryContext &BC) {
     return errorCodeToError(YamlInput.error());
   }
 
-  // Sanity check.
+  // Soundness check.
   if (YamlBP.Header.Version != 1)
     return make_error<StringError>(
         Twine("cannot read profile : unsupported version"),
diff --git a/bolt/lib/Rewrite/RewriteInstance.cpp b/bolt/lib/Rewrite/RewriteInstance.cpp
index a6e4dbc9c192f..871453b0ec5db 100644
--- a/bolt/lib/Rewrite/RewriteInstance.cpp
+++ b/bolt/lib/Rewrite/RewriteInstance.cpp
@@ -637,7 +637,7 @@ Error RewriteInstance::discoverStorage() {
     // If user specified a custom address where we should start writing new
     // data, honor that.
     NextAvailableAddress = opts::CustomAllocationVMA;
-    // Sanity check the user-supplied address and emit warnings if something
+    // Soundness check the user-supplied address and emit warnings if something
     // seems off.
     for (const ELF64LE::Phdr &Phdr : PHs) {
       switch (Phdr.p_type) {
@@ -2985,7 +2985,7 @@ void RewriteInstance::handleRelocation(const SectionRef &RelocatedSection,
     }
 
     if (BinaryData *BD = BC->getBinaryDataContainingAddress(SymbolAddress)) {
-      // Note: this assertion is trying to check sanity of BinaryData objects
+      // Note: this assertion is trying to check soundness of BinaryData objects
       // but AArch64 and RISCV has inferred and incomplete object locations
       // coming from GOT/TLS or any other non-trivial relocation (that requires
       // creation of sections and whose symbol address is not really what should
diff --git a/bolt/runtime/instr.cpp b/bolt/runtime/instr.cpp
index 1f54a500dbf98..97b49327ac484 100644
--- a/bolt/runtime/instr.cpp
+++ b/bolt/runtime/instr.cpp
@@ -819,7 +819,7 @@ ProfileWriterContext readDescriptions() {
 #endif
 
 #if !defined(__APPLE__)
-/// Debug by printing overall metadata global numbers to check it is sane
+/// Debug by printing overall metadata global numbers to check it is sound
 void printStats(const ProfileWriterContext &Ctx) {
   char StatMsg[BufSize];
   char *StatPtr = StatMsg;
diff --git a/bolt/test/AArch64/hook-fini.s b/bolt/test/AArch64/hook-fini.s
index 4f321d463ef32..4051546724748 100644
--- a/bolt/test/AArch64/hook-fini.s
+++ b/bolt/test/AArch64/hook-fini.s
@@ -4,7 +4,7 @@
 ## dynamic).
 ## All tests perform the following steps:
 ## - Compile and link for the case to be tested
-## - Some sanity-checks on the dynamic section and relocations in the binary to
+## - Some soundness-checks on the dynamic section and relocations in the binary to
 ##   verify it has the shape we want for testing:
 ##   - DT_FINI or DT_FINI_ARRAY in dynamic section
 ##   - No relative relocations for non-PIE
diff --git a/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s b/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
index 8e991fade2c86..c0a69a75b0d1b 100644
--- a/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
+++ b/bolt/test/binary-analysis/AArch64/gs-pacret-autiasp.s
@@ -272,7 +272,7 @@ lr_clobbered_nocfg:
         ret
         .size lr_clobbered_nocfg, .-lr_clobbered_nocfg
 
-/// Now do a basic sanity check on every different Authentication instruction:
+/// Now do a basic soundness check on every different Authentication instruction:
 
         .globl  f_autiasp
         .type   f_autiasp,@function
diff --git a/bolt/test/runtime/AArch64/hook-fini.test b/bolt/test/runtime/AArch64/hook-fini.test
index 8d23b21b6d612..43cc832e429ed 100644
--- a/bolt/test/runtime/AArch64/hook-fini.test
+++ b/bolt/test/runtime/AArch64/hook-fini.test
@@ -4,7 +4,7 @@
 # dynamic).
 # All tests perform the following steps:
 # - Compile and link for the case to be tested
-# - Some sanity-checks on the dynamic section and relocations in the binary to
+# - Some soundness-checks on the dynamic section and relocations in the binary to
 #   verify it has the shape we want for testing:
 #   - DT_FINI or DT_FINI_ARRAY in dynamic section
 #   - No relative relocations for non-PIE
diff --git a/bolt/tools/merge-fdata/merge-fdata.cpp b/bolt/tools/merge-fdata/merge-fdata.cpp
index cfcb9373548a1..9e55ad39427d4 100644
--- a/bolt/tools/merge-fdata/merge-fdata.cpp
+++ b/bolt/tools/merge-fdata/merge-fdata.cpp
@@ -428,7 +428,7 @@ int main(int argc, char **argv) {
     if (YamlInput.error())
       report_error(InputDataFilename, YamlInput.error());
 
-    // Sanity check.
+    // Soundness check.
     if (BP.Header.Version != 1) {
       errs() << "Unable to merge data from profile using version "
              << BP.Header.Version << '\n';
diff --git a/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp b/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
index d911b58cb8b7e..4b8b411bcc2ef 100644
--- a/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
+++ b/clang-tools-extra/clang-tidy/google/ExplicitMakePairCheck.cpp
@@ -40,7 +40,7 @@ void ExplicitMakePairCheck::check(const MatchFinder::MatchResult &Result) {
   const auto *Call = Result.Nodes.getNodeAs<CallExpr>("call");
   const auto *DeclRef = Result.Nodes.getNodeAs<DeclRefExpr>("declref");
 
-  // Sanity check: The use might have overriden ::std::make_pair.
+  // Soundness check: The use might have overriden ::std::make_pair.
   if (Call->getNumArgs() != 2)
     return;
 
diff --git a/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp b/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
index 3f5cd4b473903..ac66c5bc5d66a 100644
--- a/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
+++ b/clang-tools-extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
@@ -99,7 +99,7 @@ void MultiwayPathsCoveredCheck::check(const MatchFinder::MatchResult &Result) {
   bool SwitchHasDefault = false;
   std::tie(SwitchCaseCount, SwitchHasDefault) = countCaseLabels(Switch);
 
-  // Checks the sanity of 'switch' statements that actually do define
+  // Checks the soundness of 'switch' statements that actually do define
   // a default branch but might be degenerated by having no or only one case.
   if (SwitchHasDefault) {
     handleSwitchWithDefault(Switch, SwitchCaseCount);
diff --git a/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp b/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
index 712f390765957..f22118d5cb7e4 100644
--- a/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
+++ b/clang-tools-extra/clang-tidy/misc/NoRecursionCheck.cpp
@@ -92,7 +92,7 @@ template <typename T, unsigned SmallSize> class SmartSmallSetVector {
   void populateSet() {
     assert(Set.empty() && "Should not have already utilized the Set.");
     // Magical growth factor prediction - to how many elements do we expect to
-    // sanely grow after switching away from small-size storage?
+    // soundly grow after switching away from small-size storage?
     const size_t NewMaxElts = 4 * Vector.size();
     Vector.reserve(NewMaxElts);
     Set.reserve(NewMaxElts);
diff --git a/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp b/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
index 2f59aaa86b157..b0e4efcbc5cba 100644
--- a/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
+++ b/clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp
@@ -133,7 +133,7 @@ struct CognitiveComplexity final {
                 "that in terms of stack usage. "
                 "Thus, it is good to minimize the size of the Detail struct.");
   SmallVector<Detail, DefaultLimit> Details; // 25 elements is 200 bytes.
-  // Yes, 25 is a magic number. This is the seemingly-sane default for the
+  // Yes, 25 is a magic number. This is the seemingly-sound default for the
   // upper limit for function cognitive complexity. Thus it would make sense
   // to avoid allocations for any function that does not violate the limit.
 
diff --git a/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp b/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
index 6bb8c394f75cc..1aaad01dea13f 100644
--- a/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
+++ b/clang-tools-extra/clang-tidy/readability/NamedParameterCheck.cpp
@@ -61,7 +61,7 @@ void NamedParameterCheck::check(const MatchFinder::MatchResult &Result) {
         Parm->getType()->isSpecificBuiltinType(BuiltinType::Int))
       continue;
 
-    // Sanity check the source locations.
+    // Soundness check the source locations.
     if (!Parm->getLocation().isValid() || Parm->getLocation().isMacroID() ||
         !SM.isWrittenInSameFile(Parm->getBeginLoc(), Parm->getLocation()))
       continue;
diff --git a/clang-tools-extra/clangd/CodeCompletionStrings.cpp b/clang-tools-extra/clangd/CodeCompletionStrings.cpp
index 9c4241b54057a..a26b36db7ecad 100644
--- a/clang-tools-extra/clangd/CodeCompletionStrings.cpp
+++ b/clang-tools-extra/clangd/CodeCompletionStrings.cpp
@@ -123,7 +123,7 @@ std::string getDeclComment(const ASTContext &Ctx, const NamedDecl &Decl) {
     if (!RC)
       return "";
 
-    // Sanity check that the comment does not come from the PCH. We choose to
+    // Soundness check that the comment does not come from the PCH. We choose to
     // not write them into PCH, because they are racy and slow to load.
     assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
 
@@ -146,7 +146,7 @@ std::string getDeclComment(const ASTContext &Ctx, const NamedDecl &Decl) {
     RC = getCompletionComment(Ctx, &Decl);
     if (!RC)
       return "";
-    // Sanity check that the comment does not come from the PCH. We choose to
+    // Soundness check that the comment does not come from the PCH. We choose to
     // not write them into PCH, because they are racy and slow to load.
     assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
     Doc = RC->getFormattedText(Ctx.getSourceManager(), Ctx.getDiagnostics());
diff --git a/clang-tools-extra/clangd/Compiler.cpp b/clang-tools-extra/clangd/Compiler.cpp
index 8b3865c8a8e5c..ba8766663c411 100644
--- a/clang-tools-extra/clangd/Compiler.cpp
+++ b/clang-tools-extra/clangd/Compiler.cpp
@@ -100,7 +100,7 @@ buildCompilerInvocation(const ParseInputs &Inputs, clang::DiagnosticConsumer &D,
   std::vector<const char *> ArgStrs;
   ArgStrs.reserve(Argv.size() + 1);
   // In asserts builds, CompilerInvocation redundantly reads/parses cc1 args as
-  // a sanity test. This is not useful to clangd, and costs 10% of test time.
+  // a soundness test. This is not useful to clangd, and costs 10% of test time.
   // To avoid mismatches between assert/production builds, disable it always.
   ArgStrs = {Argv.front().c_str(), "-Xclang", "-no-round-trip-args"};
   for (const auto &S : Argv.drop_front())
diff --git a/clang-tools-extra/clangd/XRefs.cpp b/clang-tools-extra/clangd/XRefs.cpp
index e1c50f906de08..17141a52afc6c 100644
--- a/clang-tools-extra/clangd/XRefs.cpp
+++ b/clang-tools-extra/clangd/XRefs.cpp
@@ -972,7 +972,7 @@ class ReferenceFinder : public index::IndexDataConsumer {
                      llvm::dyn_cast_or_null<ObjCMethodDecl>(ASTNode.OrigD)) {
         OMD->getSelectorLocs(Locs);
       }
-      // Sanity check: we expect the *first* token to match the reported loc.
+      // Soundness check: we expect the *first* token to match the reported loc.
       // Otherwise, maybe it was e.g. some other kind of reference to a Decl.
       if (!Locs.empty() && Locs.front() != Loc)
         Locs.clear(); // First token doesn't match, assume our guess was wrong.
diff --git a/clang-tools-extra/clangd/index/IndexAction.cpp b/clang-tools-extra/clangd/index/IndexAction.cpp
index ed56c2a9d2e81..d9d9cd0f40942 100644
--- a/clang-tools-extra/clangd/index/IndexAction.cpp
+++ b/clang-tools-extra/clangd/index/IndexAction.cpp
@@ -106,7 +106,7 @@ struct IncludeGraphCollector : public PPCallbacks {
     NodeForIncluding.first->getValue().DirectIncludes.push_back(NodeForInclude);
   }
 
-  // Sanity check to ensure we have already populated a skipped file.
+  // Soundness check to ensure we have already populated a skipped file.
   void FileSkipped(const FileEntryRef &SkippedFile, const Token &FilenameTok,
                    SrcMgr::CharacteristicKind FileType) override {
 #ifndef NDEBUG
diff --git a/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp b/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
index ada14c9939318..1c443c50866e2 100644
--- a/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
+++ b/clang-tools-extra/clangd/unittests/BackgroundIndexTests.cpp
@@ -854,7 +854,7 @@ TEST(BackgroundQueueTest, Progress) {
   using testing::AnyOf;
   BackgroundQueue::Stats S;
   BackgroundQueue Q([&](BackgroundQueue::Stats New) {
-    // Verify values are sane.
+    // Verify values are sound.
     // Items are enqueued one at a time (at least in this test).
     EXPECT_THAT(New.Enqueued, AnyOf(S.Enqueued, S.Enqueued + 1));
     // Items are completed one at a time.
diff --git a/clang-tools-extra/clangd/unittests/ClangdTests.cpp b/clang-tools-extra/clangd/unittests/ClangdTests.cpp
index 9ea7c3e02411d..63c92671a621a 100644
--- a/clang-tools-extra/clangd/unittests/ClangdTests.cpp
+++ b/clang-tools-extra/clangd/unittests/ClangdTests.cpp
@@ -919,7 +919,7 @@ int d;
   StartSecond.wait();
   Server.addDocument(FooCpp, SourceContentsWithoutErrors);
   ASSERT_TRUE(Server.blockUntilIdleForTest()) << "Waiting for diagnostics";
-  ASSERT_EQ(DiagConsumer.Count, 2); // Sanity check - we actually ran both?
+  ASSERT_EQ(DiagConsumer.Count, 2); // Soundness check - we actually ran both?
 }
 
 TEST(ClangdServerTest, FormatCode) {
diff --git a/clang-tools-extra/clangd/unittests/QualityTests.cpp b/clang-tools-extra/clangd/unittests/QualityTests.cpp
index 4954659a45e02..1e6d34d58fcc1 100644
--- a/clang-tools-extra/clangd/unittests/QualityTests.cpp
+++ b/clang-tools-extra/clangd/unittests/QualityTests.cpp
@@ -10,7 +10,7 @@
 // For interesting cases, both exact scores and "X beats Y" are too brittle to
 // make good hard assertions.
 //
-// Here we test the signal extraction and sanity-check that signals point in
+// Here we test the signal extraction and soundness-check that signals point in
 // the right direction. This should be supplemented by quality metrics which
 // we can compute from a corpus of queries and preferred rankings.
 //
diff --git a/clang-tools-extra/clangd/unittests/RenameTests.cpp b/clang-tools-extra/clangd/unittests/RenameTests.cpp
index 5d2a77b62a219..b23d62e37e068 100644
--- a/clang-tools-extra/clangd/unittests/RenameTests.cpp
+++ b/clang-tools-extra/clangd/unittests/RenameTests.cpp
@@ -1444,7 +1444,7 @@ TEST(RenameTest, IndexMergeMainFile) {
   EXPECT_THAT(Results.GlobalChanges[Main].asTextEdits(),
               ElementsAre(newText("xPrime")));
 
-  // Sanity check: we do expect to see index results!
+  // Soundness check: we do expect to see index results!
   TU.Filename = "other.cc";
   Results = Rename(TU.index().get());
   EXPECT_THAT(Results.GlobalChanges.keys(),
diff --git a/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp b/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
index 4d1ca669b8d03..c846291329831 100644
--- a/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
+++ b/clang-tools-extra/test/clang-tidy/infrastructure/expand-modular-headers-ppcallbacks.cpp
@@ -1,4 +1,4 @@
-// Sanity-check. Run without modules:
+// Soundness-check. Run without modules:
 // RUN: rm -rf %t
 // RUN: mkdir %t
 // RUN: cp %S/Inputs/expand-modular-headers-ppcallbacks/* %t/
diff --git a/clang/docs/AutomaticReferenceCounting.rst b/clang/docs/AutomaticReferenceCounting.rst
index 80bbd25121148..b10e3635e1d5b 100644
--- a/clang/docs/AutomaticReferenceCounting.rst
+++ b/clang/docs/AutomaticReferenceCounting.rst
@@ -1993,7 +1993,7 @@ A program is ill-formed if it refers to the ``NSAutoreleasePool`` class.
   dependencies between two calls.  It is also very easy to accidentally forget
   to drain an autorelease pool when using the manual API, and this can
   significantly inflate the process's high-water-mark.  The introduction of a
-  new scope is unfortunate but basically required for sane interaction with the
+  new scope is unfortunate but basically required for sound interaction with the
   rest of the language.  Not draining the pool during an unwind is apparently
   required by the Objective-C exceptions implementation.
 
diff --git a/clang/docs/InternalsManual.rst b/clang/docs/InternalsManual.rst
index bd742273f4ed5..411d3ee3ecec0 100644
--- a/clang/docs/InternalsManual.rst
+++ b/clang/docs/InternalsManual.rst
@@ -82,7 +82,7 @@ using it.  From this file, :program:`tblgen` generates the unique ID of the
 diagnostic, the severity of the diagnostic and the English translation + format
 string.
 
-There is little sanity with the naming of the unique ID's right now.  Some
+There is little soundness with the naming of the unique ID's right now.  Some
 start with ``err_``, ``warn_``, ``ext_`` to encode the severity into the name.
 Since the enum is referenced in the C++ code that produces the diagnostic, it
 is somewhat useful for it to be reasonably short.
diff --git a/clang/docs/Modules.rst b/clang/docs/Modules.rst
index acbe45e0be970..515f5838dbe49 100644
--- a/clang/docs/Modules.rst
+++ b/clang/docs/Modules.rst
@@ -1099,7 +1099,7 @@ The module maps will be written using the `module map language`_, which provides
   Headers are often missing ``#include`` directives for headers that they actually depend on. As with the problem of conflicting definitions, this only affects unlucky users who don't happen to include headers in the right order. With modules, the headers of a particular module will be parsed in isolation, so the module may fail to build if there are missing includes.
 
 **Headers that vend multiple APIs at different times**
-  Some systems have headers that contain a number of different kinds of API definitions, only some of which are made available with a given include. For example, the header may vend ``size_t`` only when the macro ``__need_size_t`` is defined before that header is included, and also vend ``wchar_t`` only when the macro ``__need_wchar_t`` is defined. Such headers are often included many times in a single translation unit, and will have no include guards. There is no sane way to map this header to a submodule. One can either eliminate the header (e.g., by splitting it into separate headers, one per actual API) or simply ``exclude`` it in the module map.
+  Some systems have headers that contain a number of different kinds of API definitions, only some of which are made available with a given include. For example, the header may vend ``size_t`` only when the macro ``__need_size_t`` is defined before that header is included, and also vend...
[truncated]

@jrtc27
Copy link
Collaborator

jrtc27 commented Sep 5, 2025

I worry that sound specifically may be interpreted as to do with soundness as in correctness, given that's the term used to talk about the correctness of compiler transformations

@felipepiovezan
Copy link
Contributor

I worry that sound specifically may be interpreted as to do with soundness as in correctness, given that's the term used to talk about the correctness of compiler transformations

+1 here, I support this change but would argue we need to brainstorm a different alternative. Soundness doesn't quite capture what was intended, and it has a different meaning in the more mathematical side of computing science.

In many places where we say "sane", we usually mean "coherent" or "not obviously incorrect".
As for sanity checks, I think we usually want to capture the idea of "smoke tests".

@Endilll
Copy link
Contributor

Endilll commented Sep 5, 2025

I'd like to see this massive change to be backed by an RFC on Discourse. That is also a good place to discuss various options for the exact wording. Such an RFC passing would itself serve as an announcement that changes merged after this PR should also follow the new language.

@j2kun
Copy link
Contributor

j2kun commented Sep 5, 2025

Maybe "spot check" instead of "sanity check", though "spot" is not a replacement for "sanity" generally

@vanvoorden
Copy link
Author

I'd like to see this massive change to be backed by an RFC on Discourse.

@Endilll Fair enough… I opened an RFC pitch thread on the forums. Thanks!

@philnik777
Copy link
Contributor

Also, please split this up. It's super hard to review, and these massive cross-project patches tend to go nowhere.

@carlosgalvezp
Copy link
Contributor

I opened an RFC pitch thread on the forums.

For easier access: https://discourse.llvm.org/t/rfc-inclusive-language-migrate-sanity-checks-to-soundness-checks

@cor3ntin
Copy link
Contributor

cor3ntin commented Sep 6, 2025

As @philnik777 said, regardless of outcome on the RFC, please split in multiple PR (one per subproject), once consensus is reached on the RFC.

@C0rn3j
Copy link

C0rn3j commented Sep 8, 2025

Replacing sanity with sound, as in sound of mind, a direct synonym with the exact same connotation.

Seems like it'd do more harm than good.

image

@jayfoad
Copy link
Contributor

jayfoad commented Sep 8, 2025

Replacing sanity with sound, as in sound of mind, a direct synonym with the exact same connotation.

Seems like it'd do more harm than good.

I don't buy that argument at all. "Sound" has plenty of uses. It does not imply "sound of mind".

@joker-eph
Copy link
Collaborator

joker-eph commented Sep 8, 2025

I don't buy that argument at all. "Sound" has plenty of uses. It does not imply "sound of mind".

The argument, I believe, is that when you replace "sanity" with 'sound', then sound is used as "sound of mind".
And it was pointed in the RFC that if you can interpret it otherwise in the context, then you shouldn't use "sound" as it is unlikely to match the intent behind the original use of "sanity".

@tbaederr tbaederr removed the clang:bytecode Issues for the clang bytecode constexpr interpreter label Sep 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend:AArch64 backend:AMDGPU backend:ARM backend:Hexagon backend:m68k backend:MIPS backend:RISC-V backend:Sparc backend:SPIR-V backend:X86 BOLT clang:codegen IR generation bugs: mangling, exceptions, etc. clang:driver 'clang' and 'clang++' user-facing binaries. Not 'clang-cl' clang:frontend Language frontend issues, e.g. anything involving "Sema" clang:static analyzer clang Clang issues not falling into any other category clang-tidy clang-tools-extra clangd cmake Build system in general and CMake in particular compiler-rt:asan Address sanitizer compiler-rt:builtins compiler-rt:fuzzer compiler-rt:hwasan Hardware-assisted address sanitizer compiler-rt:msan Memory sanitizer compiler-rt:sanitizer compiler-rt:scudo Scudo Hardened Allocator compiler-rt:tsan Thread sanitizer compiler-rt:ubsan Undefined behavior sanitizer compiler-rt coroutines C++20 coroutines debuginfo flang:driver flang:fir-hlfir flang:openmp flang:parser flang:semantics flang Flang issues not falling into any other category HLSL HLSL Language Support libc++abi libc++abi C++ Runtime Library. Not libc++. libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi. lld:COFF lld:ELF lld:MachO lld lldb llvm:adt llvm:analysis Includes value tracking, cost tables and constant folding llvm:binary-utilities llvm:codegen llvm:globalisel llvm:instcombine Covers the InstCombine, InstSimplify and AggressiveInstCombine passes llvm:ir llvm:mc Machine (object) code llvm:SelectionDAG SelectionDAGISel as well llvm:support llvm:transforms llvm-lit mlgo mlir:affine mlir:async mlir:core MLIR Core Infrastructure mlir:gpu mlir:linalg mlir:llvm mlir:openmp mlir:presburger mlir:sparse Sparse compiler in MLIR mlir:tosa mlir:vector mlir:vectorops mlir offload openmp:libomp OpenMP host runtime openmp:libomptarget OpenMP offload runtime PGO Profile Guided Optimizations tablegen testing-tools tools:llvm-exegesis xray
Projects
None yet
Development

Successfully merging this pull request may close these issues.