Skip to content

Commit

Permalink
Use xla::GetDefaultStablehloVersion with ~12w compatibility require…
Browse files Browse the repository at this point in the history
…ment in third_party/tensorflow/compiler/xla/python/ifrt/hlo/hlo_program_serdes.cc

PiperOrigin-RevId: 674606265
  • Loading branch information
tomnatan30 authored and Google-ML-Automation committed Sep 14, 2024
1 parent ad171d8 commit 72eec79
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
1 change: 0 additions & 1 deletion xla/python/ifrt/hlo/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ cc_library(
"@llvm-project//mlir:IR",
"@llvm-project//mlir:Pass",
"@llvm-project//mlir:Support",
"@stablehlo//:stablehlo_portable_api",
"@stablehlo//:stablehlo_serialization",
"@tsl//tsl/platform:statusor",
],
Expand Down
3 changes: 1 addition & 2 deletions xla/python/ifrt/hlo/hlo_program_serdes.cc
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ limitations under the License.
#include "mlir/IR/OwningOpRef.h"
#include "mlir/Pass/PassManager.h"
#include "mlir/Support/LogicalResult.h"
#include "stablehlo/api/PortableApi.h"
#include "stablehlo/dialect/Serialization.h"
#include "xla/mlir/utils/error_util.h"
#include "xla/mlir_hlo/mhlo/transforms/passes.h"
Expand Down Expand Up @@ -80,7 +79,7 @@ class HloProgramSerDes : public llvm::RTTIExtends<HloProgramSerDes, SerDes> {
// Serialize portable artifact.
TF_ASSIGN_OR_RETURN(std::string serialized,
xla::SerializeUsingVersionedStablehlo(
*module, mlir::stablehlo::getMinimumVersion()));
*module, xla::GetDefaultStablehloVersion()));
return serialized;
}

Expand Down

0 comments on commit 72eec79

Please sign in to comment.