-
Notifications
You must be signed in to change notification settings - Fork 4.4k
disable -Ofast for Clang >= 19 #6520
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Suppress Clang 19+ build warnings by preventing use of the deprecated -Ofast flag when building in Release mode.
Changes:
- Update Release-mode compile flag logic to skip
-Ofastfor Clang versions >= 19.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #6520 +/- ##
==========================================
- Coverage 93.08% 93.07% -0.01%
==========================================
Files 809 809
Lines 256380 256467 +87
==========================================
+ Hits 238651 238712 +61
- Misses 17729 17755 +26 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
aha, apple clang still suffers from the deprecation warnings :) |
AppleClang 17 is based on Clang 19, but its version number is less than 19.0. |
The -Ofast flag is deprecated in Clang 19 and later, causing frequent warnings during the build. Exclude -Ofast for Clang versions >= 19 to suppress these warnings.
AppleClang 17 is based on LLVM Clang 19, but its version number is numerically less than 19.0. Since `-Ofast` in Clang is equivalent to `-O3 -ffast-math`, `-Ofast` is redundant. This commit disables `-Ofast` for all Clang-based compilers (including AppleClang) to resolve the version mismatch and avoid future deprecation issues.
7d1ccf7 to
6c99acb
Compare
The -Ofast flag is deprecated in Clang 19 and later, causing frequent warnings during the build.
Exclude -Ofast for Clang versions >= 19 to suppress these warnings.