Skip to content

Commit aa6d381

Browse files
authored
Remove deprecated functions (#32840)
### Details: - Remove deprecated code from ov::Allocator and ov::Model ### Blocked by: - openvinotoolkit/openvino_contrib#1020 - openvinotoolkit/openvino.genai#3011 - openvinotoolkit/openvino_contrib#1021 ### Tickets: - CVS-174874 - CVS-174873
1 parent 863f7d2 commit aa6d381

File tree

18 files changed

+14
-37
lines changed

18 files changed

+14
-37
lines changed

src/common/transformations/tests/common_optimizations/nop_elimination.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,7 @@ TEST(nop_elimination, reshape_elimination_v1_check_consumer_count) {
354354
TEST(nop_elimination, concat_elimination_single_node) {
355355
int64_t a = 0;
356356
auto A = make_shared<op::v0::Parameter>(element::f32, Shape{2, 3});
357-
auto f = make_shared<ov::Model>(make_shared<op::v0::Concat>(NodeVector{A}, a), ParameterVector{A});
357+
auto f = make_shared<ov::Model>(make_shared<op::v0::Concat>(OutputVector{A}, a), ParameterVector{A});
358358

359359
pass::Manager pass_manager;
360360
pass_manager.register_pass<ov::pass::Validate>();

src/core/dev_api/openvino/runtime/itensor.hpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
#include "openvino/core/core_visibility.hpp"
1111
#include "openvino/core/shape.hpp"
1212
#include "openvino/core/type/element_type.hpp"
13-
#include "openvino/runtime/allocator.hpp"
1413

1514
namespace ov {
1615

src/core/include/openvino/core/model.hpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,6 @@ class OPENVINO_API Model : public std::enable_shared_from_this<Model> {
5353
public:
5454
OPENVINO_RTTI_BASE("Model")
5555

56-
OPENVINO_DEPRECATED("This constructor is deprecated and will be remove in 2026.0. Use Model(const "
57-
"ov::OutputVector&, const ov::ParameterVector&, const std::string&) instead.")
58-
Model(const ov::NodeVector& results, const ov::ParameterVector& parameters, const std::string& name = "");
59-
6056
Model(const ov::OutputVector& results, const ov::ParameterVector& parameters, const std::string& name = "");
6157

6258
Model(const std::shared_ptr<ov::Node>& result, const ov::ParameterVector& parameters, const std::string& name = "");

src/core/include/openvino/runtime/allocator.hpp

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -135,17 +135,6 @@ class OPENVINO_API Allocator {
135135
bool> = true>
136136
Allocator(A&& a) : _impl{std::make_shared<Impl<typename std::decay_t<A>>>(std::forward<A>(a))} {}
137137

138-
template <typename A,
139-
typename std::enable_if_t<!std::is_same_v<typename std::decay_t<A>, Allocator> &&
140-
!std::is_abstract_v<typename std::decay_t<A>> &&
141-
!std::is_convertible_v<typename std::decay_t<A>, std::shared_ptr<Base>> &&
142-
!has_noexcept_deallocate_v<A>,
143-
bool> = true>
144-
OPENVINO_DEPRECATED("Please annotate your allocator's deallocate method with noexcept. This method will be "
145-
"removed in 2026.0.0 release")
146-
Allocator(A&& a)
147-
: _impl{std::make_shared<Impl<typename std::decay_t<A>>>(std::forward<A>(a))} {}
148-
149138
/**
150139
* @brief Allocates memory
151140
*

src/core/src/model.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -133,9 +133,6 @@ ov::Model::Model(const ResultVector& results, const ov::ParameterVector& paramet
133133
ov::Model::Model(const OutputVector& results, const ov::ParameterVector& parameters, const std::string& name)
134134
: Model(as_result_vector(results), parameters, name) {}
135135

136-
ov::Model::Model(const NodeVector& results, const ov::ParameterVector& parameters, const std::string& name)
137-
: Model(as_output_vector(results), parameters, name) {}
138-
139136
ov::Model::Model(const std::shared_ptr<Node>& result, const ov::ParameterVector& parameters, const std::string& name)
140137
: Model(verify_node(result)->outputs(), parameters, name) {}
141138

src/core/src/op/util/variable_value.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
#include "openvino/core/shape.hpp"
1010
#include "openvino/core/shape_util.hpp"
11-
#include "openvino/runtime/allocator.hpp"
1211
#include "openvino/runtime/itensor.hpp"
1312
#include "openvino/runtime/tensor.hpp"
1413

src/core/src/runtime/itensor.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
#include "openvino/core/except.hpp"
1111
#include "openvino/core/memory_util.hpp"
1212
#include "openvino/core/shape_util.hpp"
13-
#include "openvino/runtime/allocator.hpp"
1413
#include "openvino/runtime/iremote_tensor.hpp"
1514
#include "openvino/runtime/make_tensor.hpp"
1615
#include "openvino/runtime/properties.hpp"

src/inference/dev_api/openvino/runtime/make_tensor.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
#include "openvino/runtime/common.hpp"
1313
#include "openvino/runtime/itensor.hpp"
1414
#include "openvino/runtime/so_ptr.hpp"
15+
#include "openvino/runtime/allocator.hpp"
1516

1617
namespace ov {
1718

src/plugins/intel_cpu/tests/functional/custom/subgraph_tests/src/arm/deconv_multiple_output_edges.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ class DeconvMultipleOutputEdges : virtual public SubgraphBaseStaticTest {
5656
const auto mul1 = utils::make_eltwise(deconv->output(0), const1, utils::EltwiseTypes::MULTIPLY);
5757
const auto mul2 = utils::make_eltwise(deconv->output(0), const2, utils::EltwiseTypes::MULTIPLY);
5858

59-
NodeVector results{mul1, mul2};
59+
OutputVector results{mul1, mul2};
6060
function = std::make_shared<ov::Model>(results, inputParams, "DeconvMultipleOutputEdges");
6161
targetDevice = ov::test::utils::DEVICE_CPU;
6262
}

src/plugins/intel_cpu/tests/unit/transformations/arm/deconv_1d_decomposition.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ class DeconvDecomposition1DTest : public TransformationTestsF, public ::testing:
210210
auto output_3d_shape = ov::op::util::make_try_fold<ov::op::v8::Slice>(conv_shape, zero_1d, three_1d, one_const);
211211
auto output_3d = std::make_shared<ov::op::v1::Reshape>(conv, output_3d_shape, false);
212212

213-
return std::make_shared<ov::Model>(ov::NodeVector{output_3d}, ov::ParameterVector{input_e});
213+
return std::make_shared<ov::Model>(ov::OutputVector{output_3d}, ov::ParameterVector{input_e});
214214
}
215215

216216
protected:
@@ -261,7 +261,7 @@ class DeconvDecomposition1DTest : public TransformationTestsF, public ::testing:
261261
p.pad_type);
262262
}
263263

264-
model = std::make_shared<ov::Model>(ov::NodeVector{deconv}, ov::ParameterVector{input});
264+
model = std::make_shared<ov::Model>(ov::OutputVector{deconv}, ov::ParameterVector{input});
265265

266266
if (p.expect_transformation && rank == 3) {
267267
model_ref = buildExpectedModel(p);

0 commit comments

Comments
 (0)