[PATCH] D72820: [FPEnv] Add pragma FP_CONTRACT support under strict FP.

Cameron McInally via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jan 16 13:56:01 PST 2020


cameron.mcinally added inline comments.


================
Comment at: clang/lib/CodeGen/CGExprScalar.cpp:3436
+    }
+  }
+
----------------
cameron.mcinally wrote:
> cameron.mcinally wrote:
> > I don't think it's safe to fuse a FMUL and FADD if the intermediate rounding isn't exactly the same as those individual operations. FMULADD doesn't guarantee that, does it?
> To be clear, we could miss very-edge-case overflow/underflow exceptions.
Ah, but I see C/C++ FP_CONTRACT allows the exceptions to be optimized away. Sorry for the noise.


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