topology2: Update memory requirements to what the our current FW expects#10903
topology2: Update memory requirements to what the our current FW expects#10903jsarha wants to merge 3 commits into
Conversation
The widget specific stack requirement works in such a way that all components in a pipeline have their stack requirements, and the pipeline stack size will be the highest of those values. I am not sure if this is actually the best method. I am not sure what factors affect the required stack size for a pipeline, but for now this will have to do. So 4k is not enough for all pipelines, and these generic numbers are here to guarantee that everything works until we have fine tuned values for all the modules. So increase the number to 8k to guarantee functionality. Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
…butes Remove tokens lifetime_heap_bytes_requirement and shared_bytes_requirement and turn interim_bytes_requirement back into heap_bytes_requirement. These new types are not after all needed. The vregions code can handle the division between lifetime linear allocs and traditional interim heap autonomously. And shared memory does not need to be separately configured, vregion_alloc_coherent_align() can allocate shared memory from the same heap. Fixes: 83390bd ("topology2: Add lifetime and shared -bytes_requirement widget attributes") Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
Fine tune SRC DP memory requirements to values that should satisfy all use-cases, without using too much memory. Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Updates topology2 memory requirement tokens/config to match current SOF firmware expectations ahead of the next SOF release (per #10842).
Changes:
- Replaces interim/lifetime/shared heap requirement attributes with a single
heap_bytes_requirement. - Updates vendor token mappings to expose only
heap_bytes_requirement. - Adjusts SRC domain memory values in
cavs-nocodec.conf(stack/heap/domain_id).
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| tools/topology/topology2/include/components/widget-common.conf | Consolidates heap requirement attributes and updates default heap requirement value. |
| tools/topology/topology2/include/common/tokens.conf | Updates vendor token list to use heap_bytes_requirement instead of 3 separate heap tokens. |
| tools/topology/topology2/cavs-nocodec.conf | Updates DP SRC domain memory requirements (stack/heap) and domain id. |
| scheduler_domain 418 | ||
| domain_id 419 | ||
| stack_bytes_requirement 420 | ||
| interim_heap_bytes_requirement 421 | ||
| lifetime_heap_bytes_requirement 422 | ||
| shared_bytes_requirement 423 | ||
| heap_bytes_requirement 421 | ||
| } |
There was a problem hiding this comment.
These changes mostly revert the changes made in 83390bd and there has not been any SOF release in between those. These extra attributes are not needed AFAICT so I do not think we should have them.
| domain_id 0 | ||
| stack_bytes_requirement 2048 | ||
| heap_bytes_requirement "$[(24 * 1024)]" |
There was a problem hiding this comment.
Topology parser evaluates expressions enclosed in $[] .
| ## Heap size requirement in bytes for this component. | ||
| DefineAttribute."heap_bytes_requirement" { | ||
| # Token set reference name and type | ||
| token_ref "comp.word" | ||
| } |
There was a problem hiding this comment.
The FW will decide the division between different memory types. All that is needed is the amount of memory required. There is no need to add any more information here.
| interim_heap_bytes_requirement 4096 | ||
| lifetime_heap_bytes_requirement 16384 | ||
| shared_bytes_requirement 4096 No newline at end of file | ||
| heap_bytes_requirement 24576 |
There was a problem hiding this comment.
you are repeating yourself
These updates should go in before we make a SOF release since, #10842 is now in.