Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CPU]Fix crash issue: RuntimeError: Primitive descriptor was not found for… #16186

Conversation

xipingyan
Copy link
Contributor

Details:

  • Choose first PrimitiveDescriptor if it can't match PrimitiveDescriptor

Tickets:

  • 104143

@xipingyan xipingyan requested review from a team as code owners March 9, 2023 11:52
@github-actions github-actions bot added the category: CPU OpenVINO CPU plugin label Mar 9, 2023
@dmitry-gorokhov dmitry-gorokhov added this to the 2023.0 milestone Mar 9, 2023
src/plugins/intel_cpu/src/nodes/matmul.cpp Outdated Show resolved Hide resolved
src/plugins/intel_cpu/src/nodes/matmul.cpp Outdated Show resolved Hide resolved
@luo-cheng2021
Copy link
Contributor

Could we add a testcase to cover this?

@xipingyan xipingyan force-pushed the xp/fix_spr_dyn_shape_can_not_find_matmul branch from e8eec2e to 151399f Compare March 10, 2023 05:32
@xipingyan xipingyan requested a review from usstq March 13, 2023 07:54
@xipingyan
Copy link
Contributor Author

Could we add a testcase to cover this?

Done, Adding new param for matmul single layer test. @luo-cheng2021 @dmitry-gorokhov

Signed-off-by: Yan, Xiping <[email protected]>
@dmitry-gorokhov
Copy link
Contributor

@EgorDuplensky @maxnick guys, could you please take a look?

Comment on lines 636 to 638
// implType(AMX) will be not in list when input dynamic shape for AMX.
// Bcause AMX will be available when it assumes batch 16 for dynamic shape in compile model.
// However if we only pass batch 1 in runtime, AMX will be not available(Performance is low).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// implType(AMX) will be not in list when input dynamic shape for AMX.
// Bcause AMX will be available when it assumes batch 16 for dynamic shape in compile model.
// However if we only pass batch 1 in runtime, AMX will be not available(Performance is low).
// implType(AMX) may not be in the list when the input shapes are dynamic in the case of AMX.
// AMX is available on the compile model stage when the dummy shape is used.
// However, if we pass batch 1 at runtime, AMX will not be available (due to the oneDNN implementation selection algorithm).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My version would be 😄:
"In case of dynamic shapes an implementation type chosen as optimal for a primitive_desc with undefined input shapes, is not necessarily available for the primitive_desc with defined shape.
Example: brgemm_avx512_amx is available for a primitive with undefined input shapes but not available for primitive_desc with input batch 1"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@EgorDuplensky gave the root cause. It will be great.

@dmitry-gorokhov dmitry-gorokhov merged commit 2194552 into openvinotoolkit:master Mar 16, 2023
@xipingyan xipingyan deleted the xp/fix_spr_dyn_shape_can_not_find_matmul branch March 16, 2023 06:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: CPU OpenVINO CPU plugin
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants