From 6156488c35679790c9c1af6bb3d00dde5f2f702c Mon Sep 17 00:00:00 2001 From: Chenguang Wang Date: Thu, 14 Aug 2025 18:50:07 -0700 Subject: [PATCH] [mlir][spirv] Add missing #include in SPIRVImageInterfaces.h SPIRVImageInterfaces.h.inc uses some types, e.g. mlir::TypedValue, without #include the necessary headers. This is fine most of the time, but we did run into a weird case where bazel fails to compile //mlir:SPIRVImageInterfaces on clang19 for ChromiumOS when parse_headers (see [1]) is specified. [1]: https://bazel.build/docs/bazel-and-cpp#toolchain-features --- .../mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mlir/include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.h b/mlir/include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.h index ca5a1dcd88171..0c70d4fafd246 100644 --- a/mlir/include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.h +++ b/mlir/include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.h @@ -9,6 +9,8 @@ #ifndef MLIR_DIALECT_SPIRV_IMAGE_INTERFACES_H_ #define MLIR_DIALECT_SPIRV_IMAGE_INTERFACES_H_ +#include "mlir/IR/OpDefinition.h" + #include "mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.h.inc" #endif // MLIR_DIALECT_SPIRV_IMAGE_INTERFACES_H_