[mlir][arith] Don't crash when folding a & ~a -> 0 on vectors
authorBenjamin Kramer <benny.kra@googlemail.com>
Wed, 25 Jan 2023 13:07:48 +0000 (14:07 +0100)
committerBenjamin Kramer <benny.kra@googlemail.com>
Wed, 25 Jan 2023 13:08:28 +0000 (14:08 +0100)
commit35ca64989a75c93ea7e935ef11c3d1883c21cccd
treea662af6b6f4d5078db4ed9b93cc5a36e6cd65216
parenta7a4463acbe10d1b5c9eadcd6cb94790caad86e4
[mlir][arith] Don't crash when folding a & ~a -> 0 on vectors

m_Constant happily accepts vector splats, so just use the generic way of
getting a zero attribute.
mlir/lib/Dialect/Arith/IR/ArithOps.cpp
mlir/test/Dialect/Arith/canonicalize.mlir