llvm-project
9d12f6dd - [DAG] Don't narrow VSELECT condition demanded elts for known zero arms (#246234)

Commit
6 hours ago
[DAG] Don't narrow VSELECT condition demanded elts for known zero arms (#246234) SimplifyDemandedVectorElts stopped demanding the condition elements of a VSELECT for lanes where both arms are known zero (d172842b5100). That lets those condition elements become poison, but vselect(poison, 0, 0) is poison, not 0. Since vector_shuffle splitting started using poison (#168176) this miscompiles. On SPARC an i1 vselect c, x, 0 is folded into and c, freeze(x) and a lane that must be 0 comes out as 1. Remove the narrowing and leave a FIXME, like the one for ISD::AND. Assisted-by: Claude Opus 5.5
Author
Parents
Loading