[GPU] some convs are in ref for WDSR (#11728)

* add supported data types for onednn conv

* Remove case: in_f32 to out_f32 in are_data_types_suitable_for_onednn
This commit is contained in:
Sungeun Kim
2022-05-27 13:50:30 +09:00
committed by GitHub
parent 873e3dad2d
commit 7a1e7f122f

View File

@@ -1152,7 +1152,7 @@ bool layout_optimizer::are_data_types_suitable_for_onednn(program_node& node) {
auto in_dt = node.get_dependency(0).get_output_layout().data_type;
auto out_dt = node.get_output_layout().data_type;
if (in_dt == data_types::f32 && !node.is_type<fully_connected>())
if (in_dt == data_types::f32 && (!node.is_type<fully_connected>() && !node.is_type<convolution>()))
return false;
if (node.is_type<pooling>()) {
@@ -1179,6 +1179,9 @@ bool layout_optimizer::are_data_types_suitable_for_onednn(program_node& node) {
if ((in_dt == data_types::i8 || in_dt == data_types::u8) && wei_dt == data_types::i8 &&
(out_dt == data_types::f32 || out_dt == data_types::i32 || out_dt == data_types::f16 || out_dt == data_types::i8 || out_dt == data_types::u8))
return true;
if ((in_dt == data_types::f32 && wei_dt == data_types::f32) &&
(out_dt == data_types::i8 || out_dt == data_types::u8))
return true;
} else if (node.is_type<fully_connected>() || node.is_type<gemm>()) {
bool is_fc = node.is_type<fully_connected>();
auto wei_dt = is_fc ? node.as<fully_connected>().weights().get_output_layout().data_type :