diff options
author | David Green <david.green@arm.com> | 2023-03-28 12:12:02 +0100 |
---|---|---|
committer | David Green <david.green@arm.com> | 2023-03-28 12:12:02 +0100 |
commit | dc764a2e2d0cfb621547d44bba2e55f11d129ed5 (patch) | |
tree | a1555725b315b291258442972d1f415f6801cc6a /llvm/lib/CodeGen/ComplexDeinterleavingPass.cpp | |
parent | 2360e53ec6fd5f55f6ab05522d7546c3647a59a2 (diff) | |
download | llvm-dc764a2e2d0cfb621547d44bba2e55f11d129ed5.zip llvm-dc764a2e2d0cfb621547d44bba2e55f11d129ed5.tar.gz llvm-dc764a2e2d0cfb621547d44bba2e55f11d129ed5.tar.bz2 |
[ComplexDeinterleaving] Propagate fast math flags to symmetric operations.
This is a simple patch to make sure fast math flags are propagated through to
the newly created symmetric operations, which can help with later
simplifications.
Differential Revision: https://reviews.llvm.org/D146409
Diffstat (limited to 'llvm/lib/CodeGen/ComplexDeinterleavingPass.cpp')
-rw-r--r-- | llvm/lib/CodeGen/ComplexDeinterleavingPass.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/ComplexDeinterleavingPass.cpp b/llvm/lib/CodeGen/ComplexDeinterleavingPass.cpp index fcc25d9..36fad9e 100644 --- a/llvm/lib/CodeGen/ComplexDeinterleavingPass.cpp +++ b/llvm/lib/CodeGen/ComplexDeinterleavingPass.cpp @@ -918,13 +918,13 @@ static Value *replaceSymmetricNode(ComplexDeinterleavingGraph::RawNodePtr Node, switch (I->getOpcode()) { case Instruction::FNeg: - return B.CreateFNeg(InputA); + return B.CreateFNegFMF(InputA, I); case Instruction::FAdd: - return B.CreateFAdd(InputA, InputB); + return B.CreateFAddFMF(InputA, InputB, I); case Instruction::FSub: - return B.CreateFSub(InputA, InputB); + return B.CreateFSubFMF(InputA, InputB, I); case Instruction::FMul: - return B.CreateFMul(InputA, InputB); + return B.CreateFMulFMF(InputA, InputB, I); } return nullptr; |