- Notifications
You must be signed in to change notification settings - Fork 14.9k
Open
Labels
clang-tidycrashPrefer [crash-on-valid] or [crash-on-invalid]Prefer [crash-on-valid] or [crash-on-invalid]regression:21Regression in 21 releaseRegression in 21 release
Description
Summary
clang-tidy
21.1.2 from Homebrew (llvm@21
, arm64) segfaults when analyzing JUCE-heavy translation units in the GhostLathe audio plugin project. The crash is deterministic on macOS 14.5 when running against GhostLatheProcessor.cpp
or the associated unit tests.
Version
21.1.2 (Homebrew llvm@21
build, arm64)
OS
macOS 14.5 (arm64)
Steps to Reproduce
- Install llvm@21 via Homebrew:
brew install llvm@21
. - Configure GhostLathe with compile commands:
cmake -S . -B build -G Ninja \ -DCMAKE_BUILD_TYPE=Debug \ -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
- Ensure
/opt/homebrew/opt/llvm@21/bin
is first onPATH
. - Run clang-tidy against the problematic TU:
run-clang-tidy -p build \ -clang-tidy-binary clang-tidy \ src/plugin/GhostLatheProcessor.cpp
Expected Behavior
clang-tidy completes analysis and emits diagnostics for the translation unit.
Actual Behavior
clang-tidy terminates with a segmentation fault while traversing JUCE-generated constructs in GhostLatheProcessor.cpp
. The crash reproduces consistently on related unit tests (tests/plugin/GhostLatheProcessorTests.cpp
) as well. A sanitized backtrace and logs are included in the attachments.
Additional Context
- Downgrading to llvm@20 (clang-tidy 20.1.x) avoids the crash; we currently pin CI to that toolchain.
- JUCE version: 8.0.10. Project builds with CMake 3.30.2 and Ninja 1.12.1; SDKROOT points to the Xcode 16 macOS 14.4/26.0 SDK.
- Sanitized reproduction bundle (sources subset, compile commands, logs) plus stack trace are published here: https://gist.github.com/DavidDanielSauce/e5cea023e78b31b9b0de0572ed7fef1f.
- The gist contains
clang_tidy_crash_report.md
,clang_tidy_crash_20250930.log
, and a base64-encodedclang_tidy_crash_bundled.tgz
(decode withbase64 -d clang_tidy_crash_bundled.tgz.base64 > clang_tidy_crash_bundled.tgz
).
- The gist contains
- Happy to provide additional sanitized artefacts (e.g., full compile database) if needed.
Thanks for taking a look!
Metadata
Metadata
Assignees
Labels
clang-tidycrashPrefer [crash-on-valid] or [crash-on-invalid]Prefer [crash-on-valid] or [crash-on-invalid]regression:21Regression in 21 releaseRegression in 21 release