[PATCH] D88303: [clang][codegen] Remove the insertion of `correctly-rounded-divide-sqrt-fp-math` fn-attr.

Alexey Bader via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 28 02:22:49 PDT 2020


bader added a comment.

I'm okay with this change in general. One note though.

There are two aspects of this change:

1. I agree that `cl-fp32-correctly-rounded-divide-sqrt` is OpenCL specific and nothing should not be added in other modes.
2. I have concerns WRT removing the attribute in OpenCL mode. Most of the OpenCL back-ends are out-of-tree and might still rely on a function attribute. In addition to that https://reviews.llvm.org/D22940 handles division part of the requirement, but I don't know if sqrt computation will be handled correctly.

Can we split the patch into two: first to add attribute only in OpenCL language mode and second one removing function attribute in OpenCL mode as well?
In case we need to rollback the patch, I expect no issues with the first part.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D88303



More information about the cfe-commits mailing list