Add floating-point comparison operations to SPIR-V dialect.
authorMahesh Ravishankar <ravishankarm@google.com>
Sat, 31 Aug 2019 16:52:18 +0000 (09:52 -0700)
committerA. Unique TensorFlower <gardener@tensorflow.org>
Sat, 31 Aug 2019 16:52:44 +0000 (09:52 -0700)
commit49c3e4a50819bfea464dca4290f9f61eac9540e2
tree5a523bbb2e7034b5ce9be3430a3a02fc2fad7e4d
parent5a7014c390918ea73684b37616d7a4f61d9b2f17
Add floating-point comparison operations to SPIR-V dialect.

Use the existing SPV_LogicalOp specification to add the floating-point
comparison operations (both ordered and unordered versions).
To make it easier to import the op-definitions automatically modify
the dialect generation script to update the different .td files based
on whether the operation is an arithmetic op, logical op, etc. Also
allow specification of multiple opcodes with define_inst.sh.
Since this reuses the SPV_LogicalOp framework, no tests specific to
the floating point comparison ops are added with this CL.

PiperOrigin-RevId: 266561634
mlir/include/mlir/Dialect/SPIRV/SPIRVBase.td
mlir/include/mlir/Dialect/SPIRV/SPIRVLogicalOps.td
mlir/utils/spirv/define_inst.sh
mlir/utils/spirv/gen_spirv_dialect.py