Skip to content

Conversation

@johnylin76
Copy link
Contributor

For Intel platforms, C0 is on by default for processes necessary to run in low power cases, while C1..3 for processes with higher loads. This commit moves the default core to C1 for Speakers pipeline.

At the same time, we found this commit can resolve the DSP panic issue on builds with 3P post-processing solutions running on Speakers pipeline.

Copy link
Member

@lgirdwood lgirdwood left a comment

Choose a reason for hiding this comment

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

@johnylin76 I'm assuming this will also be the configuration for MTL ?
@mwasko fyi.

@plbossart
Copy link
Member

@johnylin76 I'm assuming this will also be the configuration for MTL ? @mwasko fyi.

aren't we moving to per-module core assignment instead of per-pipeline?

@mmaka1
Copy link

mmaka1 commented Jan 12, 2023

@johnylin76 I'm assuming this will also be the configuration for MTL ? @mwasko fyi.

aren't we moving to per-module core assignment instead of per-pipeline?

We are considering a constraint in the core allocation process due to L1 cache vs. uncache memory access performance. But also to avoid issues with global ordering and synchronization of the low latency modules. The current plan is to allocate all LL modules belonging to all pipelines connected as a stream (host - dai in any direction) on a single DSP core to guarantee proper order and L1 cache memory access without need to sync.

@plbossart
Copy link
Member

@johnylin76 I'm assuming this will also be the configuration for MTL ? @mwasko fyi.

aren't we moving to per-module core assignment instead of per-pipeline?

We are considering a constraint in the core allocation process due to L1 cache vs. uncache memory access performance. But also to avoid issues with global ordering and synchronization of the low latency modules. The current plan is to allocate all LL modules belonging to all pipelines connected as a stream (host - dai in any direction) on a single DSP core to guarantee proper order and L1 cache memory access without need to sync.

Right, but I was referring to DP processing. In the MTL time frame, one would hope that speaker protection doesn't have to run as a LL module - none of the existing 3rd party modules qualify as LL really.

@johnylin76
Copy link
Contributor Author

Hi @lgirdwood @plbossart
Could you advise the next action for this PR commit? We'll need it in rpl-001 for production builds.
If this is still debatable, is it ok to land in rpl-001 only (skipping mainstream)?
Thanks

@lgirdwood
Copy link
Member

Hi @lgirdwood @plbossart Could you advise the next action for this PR commit? We'll need it in rpl-001 for production builds. If this is still debatable, is it ok to land in rpl-001 only (skipping mainstream)? Thanks

@johnylin76 I think we should be OK for a main branch waiver this time.
@mwasko any objections to take this direct to rpl-01 without being in main ?

@mwasko
Copy link
Contributor

mwasko commented Jan 19, 2023

@johnylin76 I would like to see SW experts approvals prior merging the topology change - @plbossart, @ranj063 ?

@plbossart
Copy link
Member

@johnylin76 I would like to see SW experts approvals prior merging the topology change - @plbossart, @ranj063 ?

SW doesn't really care @mwasko. The information coming from topology is used as is, there's no intelligence beyond tracking which core is used.

Copy link
Member

@plbossart plbossart left a comment

Choose a reason for hiding this comment

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

not completely comfortable with the proposal @johnylin76

Copy link
Member

Choose a reason for hiding this comment

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

is the addition of a separate variable from SPK_PLAYBACK_CORE intentional?

This could lead to a case where SMART_AMP_CORE=1 and SPK_PLAYBACK_CORE=0 - not sure if this is desired or that it even works since the two pipelines are connected.

Should this be

define(`SMART_AMP_CORE', SPK_PLAYBACK_CORE)

??

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sure. Thanks for the suggestion.

Copy link
Member

Choose a reason for hiding this comment

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

spurious change?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think so. DTS module doesn't have the particular demand, CA_SCHEDULE_CORE should be assigned as SCHEDULE_CORE in the latter code.

Defines the target core ID for Speakers and Echo Reference pipelines
explicitly. When GOOGLE_RTC_PROCESSING is defined, it will be set to
the same ID as DMIC48K pipeline.

Signed-off-by: Pin-chih Lin <johnylin@google.com>
For Intel platforms, C0 is on by default for processes necessary to
run in low power cases, while C1..3 for processes with higher loads.
This commit moves the default core to C1 for Speakers pipeline.

At the same time, we found this commit can resolve the DSP panic
issue on builds with 3P post-processing solutions running on Speakers
pipeline.

Signed-off-by: Pin-chih Lin <johnylin@google.com>
@johnylin76
Copy link
Contributor Author

Hi @lgirdwood @plbossart Could you advise the next action for this PR commit? We'll need it in rpl-001 for production builds. If this is still debatable, is it ok to land in rpl-001 only (skipping mainstream)? Thanks

@johnylin76 I think we should be OK for a main branch waiver this time. @mwasko any objections to take this direct to rpl-01 without being in main ?

I think what @lgirdwood suggested here is landing on rpl-001-drop-stable directly? Since this PR is for main I will create a new one on rpl-001-drop-stable.

I just revised the modification a bit and separated to 2 commits. The 1st commit 5d77fa1 only added SPK_PLAYBACK_CORE definition, which is also configurable by makefile argument for flexibility considering. The default Speakers core ID was moved to C1 by the 2nd commit 5d16691.

By doing so we can land the 1st commit on main (and rpl-001-drop-stable) harmlessly, then see whether to land the 2nd one specifically on rpl-001-drop-stable(?)

@lgirdwood
Copy link
Member

@plbossart updates good for you now ?

@lyakh
Copy link
Collaborator

lyakh commented Jan 27, 2023

2 comments:

  1. Just to make sure we don't forget this: these changes aren't tested by the CI - the PR CI now only tests IPC4 / topology2
  2. This has already been mentioned before, but just to make sure - this doesn't move some pipelines in a connected topology to another core, while keeping other pipelines in the same stream on the original core? Are any other pipelines connected to the one, changed here? If yes - they're also running on core 1, aren't they? So before this change pipelines would run on different cores?

@johnylin76
Copy link
Contributor Author

2 comments:

  1. Just to make sure we don't forget this: these changes aren't tested by the CI - the PR CI now only tests IPC4 / topology2

Thanks for the note.

  1. This has already been mentioned before, but just to make sure - this doesn't move some pipelines in a connected topology to another core, while keeping other pipelines in the same stream on the original core? Are any other pipelines connected to the one, changed here? If yes - they're also running on core 1, aren't they? So before this change pipelines would run on different cores?

It's confirmed that the connected pipelines run on the same core both before and after this change. For cases having other pipelines connected to Spkr (e.g. GOOGLE_RTC_AUDIO_PROCESSING), SPK_PLAYBACK_CORE will be overwritten to align as the connected pipeline (DMIC0), which is already running on core 1.

@johnylin76
Copy link
Contributor Author

@lgirdwood @lyakh is it all good to merge now?

@lyakh
Copy link
Collaborator

lyakh commented Feb 1, 2023

@lgirdwood @lyakh is it all good to merge now?

No objections against these changes in principle, but just a note, that IPC3 / topology1 aren't actually supported on "main" any more

@lgirdwood
Copy link
Member

@lgirdwood @lyakh is it all good to merge now?

No objections against these changes in principle, but just a note, that IPC3 / topology1 aren't actually supported on "main" any more

On Intel platforms, other platforms still support IPC3 and topology1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants