-
Notifications
You must be signed in to change notification settings - Fork 2.7k
[Snippets][CPU] Fix 'misc-include-header' exclusions #32036
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
Conversation
} | ||
|
||
const auto& loops = linear_ir.get_loop_manager()->get_map(); | ||
const lowered::LoopManagerPtr& loop_manager = linear_ir.get_loop_manager(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you please explain why do we have to specify types in such cases? Is it clang-tidy limitation/bug?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, clang-tidy thinks that the header is unneeded because auto
is being used and this type is nit being properly inferred for some reason
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Regarding LoopManagerPtr
: I noticed that this using is duplicated in linear_ir.hpp. Can it be the root cause of such clang-tidy behavior?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a good idea. I have tried it, but these things are not related. I have removed using
for one case, but the problem when header is considered missing, but after removal compilation fails due to error: member access into incomplete type 'element_type' (aka 'ov::snippets::lowered::LoopManager')
is still happening
|
||
// Before code gen we have to reset KernelExecutor Table - it should be empty | ||
target->get_runtime_configurator()->reset_kernel_executor_table(); | ||
const std::shared_ptr<ov::snippets::RuntimeConfigurator>& runtime_configurator = target->get_runtime_configurator(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can class RuntimeConfigurator;
forward declaration in target_machine.hpp be a reason why clang-tidy supposes we don't need runtime_configurator.hpp header here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
error: member access into incomplete type 'element_type' (aka 'ov::snippets::RuntimeConfigurator') [clang-diagnostic-error]
55 | target->get_runtime_configurator()->reset_kernel_executor_table();
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same for the next occurrence on the line 91
Details:
Fix snippets headers exclusion from 'misc-include-cleaner' clang-tidy checks
Tickets: