[mlir][spirv] Convert `ub.poison` to `spirv.undef`
authorIvan Butygin <ivan.butygin@gmail.com>
Mon, 24 Jul 2023 19:35:28 +0000 (21:35 +0200)
committerIvan Butygin <ivan.butygin@gmail.com>
Mon, 24 Jul 2023 22:23:09 +0000 (00:23 +0200)
commit8568921d43b1dc6e273e89397d273aeba375a513
tree46e0b03b27f461b498db480c00dde6742b01250e
parent4a652e4a996ff529f6da24097698dc679fd414df
[mlir][spirv] Convert `ub.poison` to `spirv.undef`

SPIR-V doesn't have poison, but poison can be converted to undef.

Differential Revision: https://reviews.llvm.org/D156163
mlir/include/mlir/Conversion/Passes.h
mlir/include/mlir/Conversion/Passes.td
mlir/include/mlir/Conversion/UBToSPIRV/UBToSPIRV.h [new file with mode: 0644]
mlir/lib/Conversion/CMakeLists.txt
mlir/lib/Conversion/UBToSPIRV/CMakeLists.txt [new file with mode: 0644]
mlir/lib/Conversion/UBToSPIRV/UBToSPIRV.cpp [new file with mode: 0644]
mlir/test/Conversion/UBToSPIRV/ub-to-spirv.mlir [new file with mode: 0644]