Skip to content

Commit

Permalink
[Cleanup] Update all instances of tfrt::t:: to use tfrt::tfrt_tensor
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 634128347
  • Loading branch information
sagyakwa authored and copybara-github committed May 16, 2024
1 parent bc3472b commit 76dfd9f
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions include/tfrt/tensor/opdefs/tensor.td
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@ def Tensor_Dialect : Dialect {
This dialect defines operations to work with tensor in tfrt.
}];

let cppNamespace = "::tfrt::t";
let cppNamespace = "::tfrt::tfrt_tensor";
}

//===----------------------------------------------------------------------===//
// Type definitions
//===----------------------------------------------------------------------===//
def TensorType : DialectType<Tensor_Dialect,
CPred<"$_self.isa<::tfrt::t::TensorType>()">, "!t.tensor type">,
BuildableType<"$_builder.getType<::tfrt::t::TensorType>()"> {
CPred<"$_self.isa<::tfrt::tfrt_tensor::TensorType>()">, "!t.tensor type">,
BuildableType<"$_builder.getType<::tfrt::tfrt_tensor::TensorType>()"> {
let description = [{
`!t.tensor type` represents a generic tfrt tensor.
}];
Expand Down
2 changes: 1 addition & 1 deletion lib/init_tfrt_dialects.cc
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ void RegisterTFRTDialects(mlir::DialectRegistry &registry) {
registry.insert<dht::DenseHostTensorSyncDialect>();
registry.insert<coo::CooHostTensorDialect>();
registry.insert<test::TestDialect>();
registry.insert<t::TensorDialect>();
registry.insert<tfrt_tensor::TensorDialect>();
registry.insert<ht::HostTensorDialect>();
registry.insert<mlir::func::FuncDialect>();
}
Expand Down
2 changes: 1 addition & 1 deletion lib/tensor/opdefs/dense_host_tensor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ DenseHostTensorDialect::DenseHostTensorDialect(MLIRContext *context)
: Dialect(/*name=*/"tfrt_dht", context,
TypeID::get<DenseHostTensorDialect>()) {
context->getOrLoadDialect<compiler::TFRTDialect>();
context->getOrLoadDialect<tfrt::t::TensorDialect>();
context->getOrLoadDialect<tfrt::tfrt_tensor::TensorDialect>();
context->getOrLoadDialect<tfrt::ht::HostTensorDialect>();

allowUnknownTypes();
Expand Down
2 changes: 1 addition & 1 deletion lib/tensor/opdefs/dense_host_tensor_sync.cc
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ namespace dht {
DenseHostTensorSyncDialect::DenseHostTensorSyncDialect(MLIRContext *context)
: Dialect(/*name=*/"tfrt_dht_sync", context,
TypeID::get<DenseHostTensorSyncDialect>()) {
context->getOrLoadDialect<tfrt::t::TensorDialect>();
context->getOrLoadDialect<tfrt::tfrt_tensor::TensorDialect>();
allowUnknownTypes();
allowUnknownOperations();
addOperations<
Expand Down

0 comments on commit 76dfd9f

Please sign in to comment.