From 60277ba976739502e45ad26585e071568fa44af1 Mon Sep 17 00:00:00 2001 From: TFRT team Date: Wed, 3 Jul 2024 19:00:07 -0700 Subject: [PATCH] Fix TFRT Kokoro build error related to `mlir::LogicalResult`. PiperOrigin-RevId: 649259713 --- BUILD | 1 + include/tfrt/bef_converter/mlir_to_bef_translate.h | 4 ++-- include/tfrt/support/forward_decls.h | 2 -- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/BUILD b/BUILD index 0fef3e59df7..64c21a2e63a 100644 --- a/BUILD +++ b/BUILD @@ -721,6 +721,7 @@ tfrt_cc_library( ":support", "@llvm-project//llvm:Support", "@llvm-project//mlir:IR", + "@llvm-project//mlir:Support", "@llvm-project//mlir:TranslateLib", ], ) diff --git a/include/tfrt/bef_converter/mlir_to_bef_translate.h b/include/tfrt/bef_converter/mlir_to_bef_translate.h index 7d0781ed80e..d99dfe09ce7 100644 --- a/include/tfrt/bef_converter/mlir_to_bef_translate.h +++ b/include/tfrt/bef_converter/mlir_to_bef_translate.h @@ -19,6 +19,7 @@ #ifndef TFRT_BEF_CONVERTER_MLIR_TO_BEF_TRANSLATE_H_ #define TFRT_BEF_CONVERTER_MLIR_TO_BEF_TRANSLATE_H_ +#include "mlir/Support/LogicalResult.h" #include "tfrt/support/forward_decls.h" namespace mlir { @@ -27,9 +28,8 @@ class ModuleOp; namespace tfrt { -llvm::LogicalResult MLIRToBEFTranslate(mlir::ModuleOp module, +mlir::LogicalResult MLIRToBEFTranslate(mlir::ModuleOp module, llvm::raw_ostream& output); - } #endif // TFRT_BEF_CONVERTER_MLIR_TO_BEF_TRANSLATE_H_ diff --git a/include/tfrt/support/forward_decls.h b/include/tfrt/support/forward_decls.h index 3b0ca21146b..c3a42504d96 100644 --- a/include/tfrt/support/forward_decls.h +++ b/include/tfrt/support/forward_decls.h @@ -25,7 +25,6 @@ #include "llvm/Support/Casting.h" #include "llvm/Support/ErrorHandling.h" -#include "llvm/Support/LogicalResult.h" // We don't forward declare: // DenseMap, SmallVector, StringMap, StringSet @@ -33,7 +32,6 @@ namespace llvm { class raw_ostream; -struct LogicalResult; template class ArrayRef;