[clang] Honor pragmas with -ffp-contract=fast, depecate fast-honor-pragmas (PR #105746)
Andy Kaylor via cfe-commits
cfe-commits at lists.llvm.org
Thu Aug 22 16:41:35 PDT 2024
================
@@ -3178,6 +3178,13 @@ static void RenderFloatingPointOptions(const ToolChain &TC, const Driver &D,
StringRef Val = A->getValue();
if (Val == "fast" || Val == "on" || Val == "off" ||
Val == "fast-honor-pragmas") {
+ // fast-honor-pragmas is deprecated -- replace it with fast
+ if (Val == "fast-honor-pragmas") {
+ D.Diag(diag::warn_drv_deprecated_arg)
+ << A->getAsString(Args) << /*hasReplacement=*/true
+ << "-ffp-contract=fast";
+ Val = "fast";
+ }
----------------
andykaylor wrote:
Can we document it as deprecated (or just remove it from the documentation) but silently accept it? I was copying this code from another option where an option was deprecated. I certainly don't see a problem with leaving it permanently.
https://github.com/llvm/llvm-project/pull/105746
More information about the cfe-commits
mailing list