diff --git a/src/plugins/intel_gpu/src/runtime/layout.cpp b/src/plugins/intel_gpu/src/runtime/layout.cpp index 70e760bca41557..19e75275997ee6 100644 --- a/src/plugins/intel_gpu/src/runtime/layout.cpp +++ b/src/plugins/intel_gpu/src/runtime/layout.cpp @@ -585,7 +585,8 @@ ov::PartialShape layout::transform(const ov::PartialShape& pshape, cldnn::format // Check a reorder is 1d along feature axis. Or feature size fits to inner block size of feature axis static inline bool check_redundant_1d_along_feature(layout const& l1, layout const& l2) { // No padding, double blocked format and different data_type - if (!l1.data_padding && !l2.data_padding && !format::is_multi_blocked(l1.format) && !format::is_multi_blocked(l2.format) && + if ((l1.get_linear_size() == l2.get_linear_size()) && !l1.data_padding && !l2.data_padding && + !format::is_multi_blocked(l1.format) && !format::is_multi_blocked(l2.format) && l2.data_type == l1.data_type && l2.count() == l1.count()) { auto l1_inner_blk = format::is_single_blocked(l1.format) ? l1.format.traits().block_sizes.at(0).second : 1; auto l2_inner_blk = format::is_single_blocked(l2.format) ? l2.format.traits().block_sizes.at(0).second : 1; diff --git a/src/plugins/intel_gpu/tests/unit/module_tests/layout_test.cpp b/src/plugins/intel_gpu/tests/unit/module_tests/layout_test.cpp index 1eeb065d3d2b7b..6a2c8c5a80e991 100644 --- a/src/plugins/intel_gpu/tests/unit/module_tests/layout_test.cpp +++ b/src/plugins/intel_gpu/tests/unit/module_tests/layout_test.cpp @@ -223,6 +223,8 @@ INSTANTIATE_TEST_SUITE_P(smoke, layout_cmp_test, layout{ov::PartialShape{1, 32, 4, 4}, data_types::f32, format::b_fs_yx_fsv32, padding({0, 0, 1, 1}, 0)}, true, true}, {layout{ov::PartialShape{10, 20}, data_types::f16, format::bfyx}, layout{ov::PartialShape{10, 20}, data_types::f16, format::os_iyx_osv16}, false, false}, + {layout{ov::PartialShape{1, 16, 1, 1}, data_types::f16, format::bfyx}, + layout{ov::PartialShape{1, 16, 1, 1}, data_types::f16, format::os_iyx_osv16}, false, false}, {layout{ov::PartialShape{1, 2, 3, 4}, data_types::f16, format::bfyx}, layout{ov::PartialShape{1, 2, 3, 4}, data_types::f16, format::oiyx}, false, true}, {layout{ov::PartialShape{128, 10}, data_types::f16, format::bfyx},