[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

Anastasia Stulova via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu May 21 13:32:52 PDT 2020


Anastasia added inline comments.


================
Comment at: clang/test/CodeGenOpenCL/relaxed-fpmath.cl:14
   // FINITE: fdiv nnan ninf float
-  // UNSAFE: fdiv nnan nsz float
+  // UNSAFE: fdiv reassoc nsz arcp afn float
   // MAD: fdiv float
----------------
michele.scandale wrote:
> This change is based on the following:
> * `-cl-fast-relaxed-math` = `-cl-unsafe-math-optimizations` + `-cl-finite-math-only` 
> * the GCC option `-funsafe-math-optimizations` and `-cl-unsafe-math-optimizations` are described with very similar wording and from the GCC description states explicitly mention that no signed zeros, reassociation and reciprocals are enabled, but there is no mention to assuming that NaNs do not exist.
> 
> See https://www.khronos.org/registry/OpenCL/sdk/1.2/docs/man/xhtml/clBuildProgram.html and https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html
Makes sense!


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D80315/new/

https://reviews.llvm.org/D80315





More information about the cfe-commits mailing list