[PATCH] D72820: [FPEnv] Add pragma FP_CONTRACT support under strict FP.
Phoebe Wang via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Feb 28 01:31:25 PST 2023
pengfei added inline comments.
================
Comment at: clang/lib/CodeGen/CGExprScalar.cpp:3386
+ FMulAdd = Builder.CreateConstrainedFPCall(
+ CGF.CGM.getIntrinsic(llvm::Intrinsic::experimental_constrained_fmuladd,
+ Addend->getType()),
----------------
Allen wrote:
> Sorry, I'm not familiar with the optimization of the clang front end.
> I'd like to ask, is this optimization supposed to assume that all the backends have instructions like Fmuladd?
No, it is a flexible intrinsic, which allows backends to choose their best approach. It can be either interpretered as mul + add or fma. It represents user doesn't care the differece between them.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D72820/new/
https://reviews.llvm.org/D72820
More information about the cfe-commits
mailing list