[all-commits] [llvm/llvm-project] bfa3b6: [InstCombine] Erase attribute lists for simplified...
Gui Andrade via All-commits
all-commits at lists.llvm.org
Mon Jul 13 15:32:59 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: bfa3b627c6832552a7808a9f0f7f9cab61c7ea1a
https://github.com/llvm/llvm-project/commit/bfa3b627c6832552a7808a9f0f7f9cab61c7ea1a
Author: Gui Andrade <guiand at google.com>
Date: 2020-07-13 (Mon, 13 Jul 2020)
Changed paths:
M llvm/lib/Transforms/Utils/SimplifyLibCalls.cpp
M llvm/test/Transforms/InstCombine/pow_fp_int.ll
M llvm/test/Transforms/InstCombine/simplify-libcalls.ll
Log Message:
-----------
[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
More information about the All-commits
mailing list