[Mlir-commits] [mlir] [mlir][spirv] Add bfloat16 support (PR #141458)

Igor Wodiany llvmlistbot at llvm.org
Thu May 29 03:21:23 PDT 2025


================
@@ -175,10 +175,7 @@ static Type parseAndVerifyType(SPIRVDialect const &dialect,
 
   // Check other allowed types
   if (auto t = llvm::dyn_cast<FloatType>(type)) {
-    if (type.isBF16()) {
-      parser.emitError(typeLoc, "cannot use 'bf16' to compose SPIR-V types");
-      return Type();
-    }
+    // TODO: All float types are allowed for now, but this should be fixed.
----------------
IgWod-IMG wrote:

In my opinion it's okay to address it later. In fact I think it's preferable. Currently the code doesn't do any checks anyway, other than checking for bf16, so adding a proper check would be out of scope of this PR.

https://github.com/llvm/llvm-project/pull/141458


More information about the Mlir-commits mailing list