[CPU] Enable back INT32 for MatMul (#7898)
- Also enabled ngraph onnx matmul integer tests
This commit is contained in:
parent
bbeec714aa
commit
5b075d8575
@ -4,6 +4,7 @@
|
||||
|
||||
#include "mkldnn_matmul_node.h"
|
||||
|
||||
#include "ie_precision.hpp"
|
||||
#include "memory_desc/cpu_blocked_memory_desc.h"
|
||||
#include "cpu_types.h"
|
||||
#include "mkldnn_eltwise_node.h"
|
||||
@ -120,6 +121,12 @@ void MKLDNNMatMulNode::getSupportedDescriptors() {
|
||||
if (firstInPortPrec.size() != secondInPortPrec.size())
|
||||
firstInPortPrec = secondInPortPrec = getMaxPrecision(getOriginalInputPrecisions());
|
||||
|
||||
// fallback to fp32 for any precision that cannot be handled natively
|
||||
if ((!one_of(firstInPortPrec , Precision::U8, Precision::I8, Precision::BF16, Precision::FP32) ||
|
||||
!one_of(secondInPortPrec , Precision::I8, Precision::BF16, Precision::FP32))) {
|
||||
outPortPrec = firstInPortPrec = secondInPortPrec = Precision::FP32;
|
||||
}
|
||||
|
||||
if (!fusedWith.empty()) {
|
||||
outPortPrec = fusedWith[fusedWith.size() - 1]->getOriginalOutputPrecisionAtPort(0);
|
||||
}
|
||||
|
@ -31,16 +31,6 @@ onnx_model_conv_integer_no_zero_point
|
||||
onnx_model_conv_integer_pads
|
||||
|
||||
# Unsupported operator detected in the graph: QuantizedDot
|
||||
onnx_model_matmul_integer_2d_simple_zero_point
|
||||
onnx_model_matmul_integer_int8
|
||||
onnx_model_matmul_integer_vectorized_zero_point
|
||||
onnx_model_matmul_integer_no_zero_point
|
||||
onnx_model_matmul_integer_2d_x_3d
|
||||
onnx_model_matmul_integer_3d_x_2d
|
||||
onnx_model_matmul_integer_3d
|
||||
onnx_model_matmul_integer_4d
|
||||
onnx_model_matmul_integer_4d_zero_point
|
||||
onnx_model_matmul_integer_matrix_zero_point
|
||||
onnx_model_qlinear_matmul
|
||||
onnx_model_qlinear_matmul_3d
|
||||
|
||||
|
@ -333,7 +333,6 @@ tests_expected_to_fail = [
|
||||
),
|
||||
(
|
||||
xfail_issue_38722,
|
||||
"OnnxBackendNodeModelTest.test_matmulinteger_cpu",
|
||||
"OnnxBackendNodeModelTest.test_qlinearmatmul_2D_cpu",
|
||||
"OnnxBackendNodeModelTest.test_qlinearmatmul_3D_cpu",
|
||||
),
|
||||
|
Loading…
Reference in New Issue
Block a user