[PATCH] D72841: Add support for pragma float_control, to control precision and exception behavior at the source level
Melanie Blower via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed May 6 06:57:45 PDT 2020
mibintc added a comment.
In D72841#2022354 <https://reviews.llvm.org/D72841#2022354>, @uabelho wrote:
> It seems to be this change in SemaStmt.cpp that makes the FENV-pragma have some effect regardless of the warning saying that the pragma doesn't have any effect:
>
> index aa0d89ac09c3..f76994a6dab3 100644
> @@ -394,6 +394,11 @@ StmtResult Sema::ActOnCompoundStmt(SourceLocation L, SourceLocation R,
> ArrayRef<Stmt *> Elts, bool isStmtExpr) {
> const unsigned NumElts = Elts.size();
>
> + // Mark the current function as usng floating point constrained intrinsics
> + if (getCurFPFeatures().isFPConstrained())
> + if (FunctionDecl *F = dyn_cast<FunctionDecl>(CurContext))
> + F->setUsesFPIntrin(true);
> +
>
Thank you I will follow up!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D72841/new/
https://reviews.llvm.org/D72841
More information about the llvm-commits
mailing list