[llvm] d1ac3df - [DAG] canCreateUndefOrPoison - ISD::AssertSext/Zext/Align/NoFPClass only generate poison (#196492)
via llvm-commits
llvm-commits at lists.llvm.org
Fri May 8 02:29:58 PDT 2026
Author: Simon Pilgrim
Date: 2026-05-08T09:29:53Z
New Revision: d1ac3dfa54b9a250851577b8604462452658f8f1
URL: https://github.com/llvm/llvm-project/commit/d1ac3dfa54b9a250851577b8604462452658f8f1
DIFF: https://github.com/llvm/llvm-project/commit/d1ac3dfa54b9a250851577b8604462452658f8f1.diff
LOG: [DAG] canCreateUndefOrPoison - ISD::AssertSext/Zext/Align/NoFPClass only generate poison (#196492)
Added:
Modified:
llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
Removed:
################################################################################
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
index b1baa007b00cb..15fc74b6cc7c9 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
@@ -5853,7 +5853,7 @@ bool SelectionDAG::canCreateUndefOrPoison(SDValue Op, const APInt &DemandedElts,
case ISD::AssertAlign:
case ISD::AssertNoFPClass:
// Assertion nodes can create poison if the assertion fails.
- return true;
+ return includesPoison(Kind);
case ISD::FREEZE:
case ISD::CONCAT_VECTORS:
More information about the llvm-commits
mailing list