Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
sof-logger used to print a core ID in each line, wondering if it would be a lot of overhead to add that to mtrace too...
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.
when parsing:
[ 24.203081] ll_schedule: zephyr_domain_thread_fn: ll timer avg 3412, max 6115, overruns 0
CI want to know following data belong to which core, in this line, there is no coreID information, right?
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.
I think we could add a Kconfig option to add core info to all logs, This could even be a Zephyr side option, but probably easier to add it to SOF side trace macros. I'd keep this 1) kconfig option (as there is bound to be a slight overhead), 2) and keep this short " ". zephyr/include/zephyr/logging/log_core.h shows how this is done to add the "" et al log level prefixes (in a way that can be kconfig'ed out.
But that's an option. Would require some experiments to see how this impacts overall logging overhead. If it's too much, then this PR is probably better.
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.
it is small cost, since only add one more var print per second, add Kconfig seems too cautious.
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.
@btian1 I mean if we add this for ALL logs. We have configs that do not have multiple cores and for these this is just overhead to have core0 in all logs. And e.g. on the Intel platforms, we have to fit all logs in a 4KiB SRAM window so adding overhead might lead to dropping logs when many are sent in bursts. You might want to disable this in Kconfig if you want to enable DBG logs.