aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/CodeGen/CGCall.cpp
diff options
context:
space:
mode:
authorMichael Liao <michael.hliao@gmail.com>2020-09-28 10:54:16 -0400
committerMichael Liao <michael.hliao@gmail.com>2020-10-01 11:07:39 -0400
commit8c36eaf0377285acb89c319582d9666e60f42007 (patch)
tree6c6173f45c3720a4ef73452cadad93b4ccf5aaa6 /clang/lib/CodeGen/CGCall.cpp
parent48c9e8244b6b8aeb6a4fd10dcf4c6995f1fec9a0 (diff)
downloadllvm-8c36eaf0377285acb89c319582d9666e60f42007.zip
llvm-8c36eaf0377285acb89c319582d9666e60f42007.tar.gz
llvm-8c36eaf0377285acb89c319582d9666e60f42007.tar.bz2
[clang][opencl][codegen] Remove the insertion of `correctly-rounded-divide-sqrt-fp-math` fn-attr.
- `-cl-fp32-correctly-rounded-divide-sqrt` is already handled in a per-instruction manner by annotating the accuracy required. There's no need to add that fn-attr. So far, there's no in-tree backend handling that attr and that OpenCL specific option. - In case that out-of-tree backends are broken, this change could be reverted if those backends could not be fixed. Differential Revision: https://reviews.llvm.org/D88424
Diffstat (limited to 'clang/lib/CodeGen/CGCall.cpp')
-rw-r--r--clang/lib/CodeGen/CGCall.cpp5
1 files changed, 0 insertions, 5 deletions
diff --git a/clang/lib/CodeGen/CGCall.cpp b/clang/lib/CodeGen/CGCall.cpp
index ec7ddf8..cb03e02 100644
--- a/clang/lib/CodeGen/CGCall.cpp
+++ b/clang/lib/CodeGen/CGCall.cpp
@@ -1794,11 +1794,6 @@ void CodeGenModule::getDefaultFunctionAttributes(StringRef Name,
llvm::utostr(CodeGenOpts.SSPBufferSize));
FuncAttrs.addAttribute("no-signed-zeros-fp-math",
llvm::toStringRef(LangOpts.NoSignedZero));
- if (getLangOpts().OpenCL) {
- FuncAttrs.addAttribute(
- "correctly-rounded-divide-sqrt-fp-math",
- llvm::toStringRef(CodeGenOpts.CorrectlyRoundedDivSqrt));
- }
// TODO: Reciprocal estimate codegen options should apply to instructions?
const std::vector<std::string> &Recips = CodeGenOpts.Reciprocals;