diff options
author | Vineet Kumar <173554+vntkmr@users.noreply.github.com> | 2025-03-17 12:07:33 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-03-17 16:07:33 +0000 |
commit | 54cb4059da2751758b3ab6dc5630e40b228bcda5 (patch) | |
tree | 0c91fd4c3c2ec4afe02a2154844568281bcb0365 /llvm/lib/Transforms/Utils/LoopUtils.cpp | |
parent | b00ad366323cee324b0294f6395c33ae4b047e2c (diff) | |
download | llvm-54cb4059da2751758b3ab6dc5630e40b228bcda5.zip llvm-54cb4059da2751758b3ab6dc5630e40b228bcda5.tar.gz llvm-54cb4059da2751758b3ab6dc5630e40b228bcda5.tar.bz2 |
[X86][ISel][FMA] Get a handle on operand nodes when negating FMA (#130176)
When negating an FMA opcode, a new node created for a negated FMA
operand may be deleted while recursively negating another FMA operand.
This causes the following assertion to fail:
```
llc: /root/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp:7686: llvm::SDValue llvm::SelectionDAG::getNode(unsigned int, const llvm::SDLoc&, llvm::EVT, llvm::SDValue, llvm::SDValue, llvm::SDValue, llvm::SDNodeFlags): Assertion `N1.getOpcode() != ISD::DELETED_NODE && N2.getOpcode() != ISD::DELETED_NODE && N3.getOpcode() != ISD::DELETED_NODE && "Operand is DELETED_NODE!"' failed.
```
This patch adds a temporary handle on the new negated nodes to prevent
them from being deleted.
For eg. see https://godbolt.org/z/Tq4PvnKM4 .
Co-authored-by: Vineet Kumar <vineetk@hpe.com>
Diffstat (limited to 'llvm/lib/Transforms/Utils/LoopUtils.cpp')
0 files changed, 0 insertions, 0 deletions