[mlir][spirv] Add OpExtension "SPV_INTEL_bfloat16_conversion"
authorMd Abdullah Shahneous Bari <md.abdullah.shahneous.bari@intel.com>
Fri, 31 Mar 2023 21:02:25 +0000 (14:02 -0700)
committerLei Zhang <antiagainst@google.com>
Fri, 31 Mar 2023 21:02:59 +0000 (14:02 -0700)
commitd2a559ffc0dc61b9d7426064bd5076b66d2f96d6
tree21d3d8e8a114eef1b7176c4bc6929e4114b2b20f
parentfdaebbeff4557e152380eefeb5e817ba5e0984c3
[mlir][spirv] Add OpExtension "SPV_INTEL_bfloat16_conversion"

Add Intel-specific "SPV_INTEL_bfloat16_conversion" extension and
capability (Bfloat16ConversionINTEL), and
two ops (OpConvertFToBF16INTEL, OpConvertBF16ToFINTEL)
that are introduced by this extension.
These ops allow BF16 to Float conversion and vice-versa.

Reference Specification:
https://github.com/KhronosGroup/SPIRV-Registry/blob/main/extensions/INTEL/SPV_INTEL_bfloat16_conversion.asciidoc

Reviewed By: antiagainst

Differential Revision: https://reviews.llvm.org/D147087
mlir/include/mlir/Dialect/SPIRV/IR/SPIRVBase.td
mlir/include/mlir/Dialect/SPIRV/IR/SPIRVIntelExtOps.td [new file with mode: 0644]
mlir/include/mlir/Dialect/SPIRV/IR/SPIRVOps.td
mlir/lib/Dialect/SPIRV/IR/SPIRVOps.cpp
mlir/test/Dialect/SPIRV/IR/intel-ext-ops.mlir [new file with mode: 0644]
mlir/test/Target/SPIRV/intel-ext-ops.mlir [new file with mode: 0644]