Skip to content

Commit d29948c

Browse files
authored
[TF FE][SDL] Fix performance inefficiencies (openvinotoolkit#25884)
**Details:** Fix performance inefficiencies **Ticket:** 148599 Signed-off-by: Kazantsev, Roman <roman.kazantsev@intel.com>
1 parent a33afe4 commit d29948c

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/frontends/tensorflow_common/src/helper_transforms/tensor_list_ops_resolver.cpp

+3-2
Original file line numberDiff line numberDiff line change
@@ -325,14 +325,15 @@ ov::frontend::tensorflow::pass::TensorListPushBackReplacer::TensorListPushBackRe
325325
auto zero_const = rg.make<v0::Constant>(element::i32, Shape{1}, 0);
326326
auto one_const = rg.make<v0::Constant>(element::i32, Shape{1}, 1);
327327
num_elements = rg.make<v8::Slice>(num_elements, zero_const, one_const, one_const);
328-
auto new_input_handle_shape = rg.make<v0::Concat>(OutputVector{num_elements, tensor_shape}, 0);
328+
auto new_input_handle_shape =
329+
rg.make<v0::Concat>(OutputVector{std::move(num_elements), std::move(tensor_shape)}, 0);
329330
input_handle = rg.make<v1::Broadcast>(input_handle, new_input_handle_shape);
330331

331332
// unsqueeze tensor to be inserted into the list
332333
tensor = rg.make<v0::Unsqueeze>(tensor, zero_const);
333334

334335
// insert the tensor into the end
335-
auto updated_list = rg.make<v0::Concat>(OutputVector{input_handle, tensor}, 0);
336+
auto updated_list = rg.make<v0::Concat>(OutputVector{std::move(input_handle), std::move(tensor)}, 0);
336337

337338
updated_list->set_friendly_name(tensor_list_push_back->get_friendly_name());
338339
copy_runtime_info(tensor_list_push_back, rg.get());

src/frontends/tensorflow_common/src/op/tensor_list_operations.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ OutputVector translate_tensor_list_concat_v2_op(const NodeContext& node) {
240240
out = make_shared<v0::Squeeze>(out, first_dim);
241241

242242
set_node_name(node.get_name(), out.get_node_shared_ptr());
243-
return {out};
243+
return {std::move(out)};
244244
}
245245

246246
} // namespace op

0 commit comments

Comments
 (0)