diff options
author | Gui Andrade <guiand@google.com> | 2020-07-07 21:21:13 +0000 |
---|---|---|
committer | Gui Andrade <guiand@google.com> | 2020-07-13 22:32:33 +0000 |
commit | bfa3b627c6832552a7808a9f0f7f9cab61c7ea1a (patch) | |
tree | 23115555471949aead88f656ee03a499bcd98ab2 /clang/lib/CodeGen/CodeGenFunction.cpp | |
parent | 3d52b1e81b7b3891d9132d826d4889119fad7d00 (diff) | |
download | llvm-bfa3b627c6832552a7808a9f0f7f9cab61c7ea1a.zip llvm-bfa3b627c6832552a7808a9f0f7f9cab61c7ea1a.tar.gz llvm-bfa3b627c6832552a7808a9f0f7f9cab61c7ea1a.tar.bz2 |
[InstCombine] Erase attribute lists for simplified libcalls
Currently, a transformation like pow(2.0, x) -> exp2(x) copies the pow
attribute list verbatim and applies it to exp2. This works out fine
when the attribute list is empty, but when it isn't clang may error due
due to the mismatch.
The source function and destination don't necessarily have anything
to do with one another, attribute-wise. So it makes sense to remove
the attribute lists (this is similar to what IPO does in this
situation).
This was discovered after implementing the `noundef` param attribute.
Differential Revision: https://reviews.llvm.org/D82820
Diffstat (limited to 'clang/lib/CodeGen/CodeGenFunction.cpp')
0 files changed, 0 insertions, 0 deletions