diff --git a/src/plugins/auto/src/auto_compiled_model.cpp b/src/plugins/auto/src/auto_compiled_model.cpp index 0b22c13ee254c0..a8f79e8b159d47 100644 --- a/src/plugins/auto/src/auto_compiled_model.cpp +++ b/src/plugins/auto/src/auto_compiled_model.cpp @@ -47,7 +47,8 @@ ov::Any AutoCompiledModel::get_property(const std::string& name) const { ov::device::priorities, ov::device::properties, ov::hint::model_priority, - ov::loaded_from_cache}; + ov::loaded_from_cache, + ov::enable_profiling}; return ro_properties; }; const auto& default_rw_properties = []() { @@ -63,6 +64,8 @@ ov::Any AutoCompiledModel::get_property(const std::string& name) const { supported_properties.insert(supported_properties.end(), ro_properties.begin(), ro_properties.end()); supported_properties.insert(supported_properties.end(), rw_properties.begin(), rw_properties.end()); return decltype(ov::supported_properties)::value_type(supported_properties); + } else if (name == ov::enable_profiling) { + return m_context->m_need_perf_counters; } else if (name == ov::hint::performance_mode) { return m_context->m_performance_hint; } else if (name == ov::device::priorities) { diff --git a/src/plugins/auto/src/cumulative_compiled_model.cpp b/src/plugins/auto/src/cumulative_compiled_model.cpp index c0e6e3e2516fb6..9fe108f00df579 100644 --- a/src/plugins/auto/src/cumulative_compiled_model.cpp +++ b/src/plugins/auto/src/cumulative_compiled_model.cpp @@ -47,7 +47,8 @@ ov::Any AutoCumuCompiledModel::get_property(const std::string& name) const { ov::device::properties, ov::hint::model_priority, ov::loaded_from_cache, - ov::intel_auto::schedule_policy}; + ov::intel_auto::schedule_policy, + ov::enable_profiling}; return ro_properties; }; const auto& default_rw_properties = []() { @@ -63,6 +64,8 @@ ov::Any AutoCumuCompiledModel::get_property(const std::string& name) const { supported_properties.insert(supported_properties.end(), ro_properties.begin(), ro_properties.end()); supported_properties.insert(supported_properties.end(), rw_properties.begin(), rw_properties.end()); return decltype(ov::supported_properties)::value_type(supported_properties); + } else if (name == ov::enable_profiling) { + return m_context->m_need_perf_counters; } else if (name == ov::hint::performance_mode) { return m_context->m_performance_hint; } else if (name == ov::intel_auto::schedule_policy) { diff --git a/src/plugins/auto/tests/functional/shared_tests_instances/behavior/ov_executable_network/properties.cpp b/src/plugins/auto/tests/functional/shared_tests_instances/behavior/ov_executable_network/properties.cpp index 91d329995781cf..a798c54d2b08d4 100644 --- a/src/plugins/auto/tests/functional/shared_tests_instances/behavior/ov_executable_network/properties.cpp +++ b/src/plugins/auto/tests/functional/shared_tests_instances/behavior/ov_executable_network/properties.cpp @@ -4,6 +4,7 @@ #include "behavior/compiled_model/properties.hpp" +#include "openvino/runtime/auto/properties.hpp" #include "openvino/runtime/properties.hpp" #include "openvino/runtime/system_conf.hpp" @@ -138,4 +139,24 @@ INSTANTIATE_TEST_SUITE_P(smoke_OVClassCompiledModelGetPropertyTest, OVClassCompiledModelGetPropertyTest_MODEL_PRIORITY, ::testing::Combine(::testing::Values("AUTO:TEMPLATE"), ::testing::ValuesIn(multiModelPriorityConfigs))); + +const std::vector auto_default_properties = { + {ov::enable_profiling(false)}, + {ov::hint::model_priority(ov::hint::Priority::MEDIUM)}, + {ov::hint::performance_mode(ov::hint::PerformanceMode::LATENCY)}}; + +INSTANTIATE_TEST_SUITE_P(smoke_Auto_Default_test, + OVClassCompiledModelPropertiesDefaultTests, + ::testing::Combine(::testing::Values(ov::test::utils::DEVICE_AUTO), + ::testing::ValuesIn(auto_default_properties)), + OVClassCompiledModelPropertiesDefaultTests::getTestCaseName); + +const std::vector multi_default_properties = {{ov::enable_profiling(false)}}; + +INSTANTIATE_TEST_SUITE_P(smoke_Multi_Default_test, + OVClassCompiledModelPropertiesDefaultTests, + ::testing::Combine(::testing::Values(ov::test::utils::DEVICE_TEMPLATE), + ::testing::ValuesIn(multi_default_properties)), + OVClassCompiledModelPropertiesDefaultTests::getTestCaseName); + } // namespace diff --git a/src/plugins/auto/tests/functional/shared_tests_instances/behavior/ov_plugin/properties_tests.cpp b/src/plugins/auto/tests/functional/shared_tests_instances/behavior/ov_plugin/properties_tests.cpp index c50dc80e4cd02c..99f21031713510 100644 --- a/src/plugins/auto/tests/functional/shared_tests_instances/behavior/ov_plugin/properties_tests.cpp +++ b/src/plugins/auto/tests/functional/shared_tests_instances/behavior/ov_plugin/properties_tests.cpp @@ -24,7 +24,8 @@ const std::vector multi_Auto_properties = { {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::intel_auto::device_bind_buffer("NO")}, {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::intel_auto::enable_startup_fallback("YES")}, {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::intel_auto::enable_startup_fallback("NO")}, -}; + {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::enable_profiling(true)}, + {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::enable_profiling(false)}}; INSTANTIATE_TEST_SUITE_P(smoke_AutoMultiBehaviorTests, OVPropertiesTests, @@ -41,7 +42,9 @@ const std::vector multi_setcore_properties = { const std::vector multi_compileModel_properties = { {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::hint::performance_mode(ov::hint::PerformanceMode::THROUGHPUT), - ov::hint::model_priority(ov::hint::Priority::MEDIUM)}}; + ov::hint::model_priority(ov::hint::Priority::MEDIUM)}, + {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::enable_profiling(true)}, + {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::enable_profiling(false)}}; INSTANTIATE_TEST_SUITE_P(smoke_MultiCompileModelBehaviorTests, OVSetPropComplieModleGetPropTests, @@ -70,7 +73,9 @@ const std::vector auto_compileModel_properties = { ov::hint::model_priority(ov::hint::Priority::MEDIUM)}, {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::hint::performance_mode(ov::hint::PerformanceMode::THROUGHPUT), - ov::hint::model_priority(ov::hint::Priority::MEDIUM)}}; + ov::hint::model_priority(ov::hint::Priority::MEDIUM)}, + {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::enable_profiling(true)}, + {ov::device::priorities(ov::test::utils::DEVICE_TEMPLATE), ov::enable_profiling(false)}}; INSTANTIATE_TEST_SUITE_P(smoke_AutoCompileModelBehaviorTests, OVSetPropComplieModleGetPropTests,