-
Notifications
You must be signed in to change notification settings - Fork 349
tools: Support multi-output component playback testing on testbench #3210
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
cujomalainey
left a comment
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.
We are definitely getting close, i think we can take this out of draft now
|
Also looks like CI is breaking on Seb's crossover changes that need to be removed |
a376786 to
888e6e9
Compare
|
I removed the dependency of crossover library and PR #2802 for this PR. Then it could be merged on its own. Thanks. |
|
@lgirdwood how best should we format this? Also will it need a kernel change? |
|
Those WARNINGs are brought by one of my commit: fa82026 However, I wonder if GCC errors happened on my env only? Otherwise there should be others hitting such errors already. |
And FYI, GCC errors appeared only with Seb's Crossover component commits. |
lgirdwood
left a comment
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 you split the PR into patches per feature with the dependencies first.
Support up to 4 output pipelines for test/topology/test-playback.m4, where argument TEST_PIPE_AMOUNT is added for identifying the number of pipelines while generating test topologies. Multi-output component should be added in ALG_MULTI_MODE_TESTS and ALG_MULTI_SIMPLE_TESTS to generate test topologies with multiple output pipelines in the future. Signed-off-by: Pin-chih Lin <johnylin@google.com>
In order to run multi-output component playback by testbench, this patch supports multiple output file mode on running testbench. Argument "-o" is modified to accept specifying up to 4 filenames delimited by comma, e.g. "-o output1,output2,..." Moreover, debug messages in tplg_parser/tplg_parser.c is refined for demonstrating multiple pipelines better. Signed-off-by: Pin-chih Lin <johnylin@google.com>
Support channel specification by argument "-c" on testbench Signed-off-by: Pin-chih Lin <johnylin@google.com>
|
Just split into patches, thanks. |
cujomalainey
left a comment
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.
Looks good, just one optimization that I am not even sure is worth having tbh, I will let others decide if the effort is worth it.
|
|
||
| ifdef(`TEST_HAS_PIPE4', | ||
| ` | ||
| # Playback pipeline 4 on PCM 3 using max 2 channels of s32le. |
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 wonder if this section could be extracted out to a macro call and the index is just subbed in, thoughts?
|
|
||
| # playback DAI is SSP TEST_DAI2_PORT using 2 periods | ||
| # Buffers use s24le format, with 48 frame per 1000us on core 0 with priority 0 | ||
| DAI_ADD_SCHED(sof/pipe-dai-sched-playback.m4, |
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 goes for this section
|
@lgirdwood PTAL as this is blocking the rest of the crossover series |
|
CI unrelated issues. |
|
@singalsu any comments ? |
This is actually not related to this PR, and the alternative solution is provided at b041b42 |
|
Agreed, ABI label does not apply to current solution |
|
@johnylin76 the GCC warnings only come about with more recent versions (and this is being updated now in the CI container to catch any problems). We are currently resolving then when accessed via ASSUME_ALIGNED() CC attribute, but I also think the alignment attribute on the structure definition is needed too. @plbossart any issues adding this attribute to the kernel user/ipc headers ? |
|
@lgirdwood Thanks for the information I have already done via ASSUME_ALIGNED() in commit b041b42 |
|
@cujomalainey are you OK with changes to merge ? |
cujomalainey
left a comment
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.
@lgirdwood Yep, only optimizations left that can be done later if needed
|
Unrelated failure on Jenkins as this is testbench. |
Note: this patch is currently followed on top of crossover component PR: #2802
This patch supports testbench playback testing for single-input-multi-output component, e.g. crossover. Test playback m4 file (tools/test/topology/test-playback.m4) is extended to generate up to 4 output pipelines test topologies, where argument "TEST_PIPE_AMOUNT" is provided for identifying the number of pipelines.
While building test topologies, 2way, 3way, and 4way crossover playback topology files will be generated under build_tools/test/topology/ with names as follows:
test-playback-ssp5-mclk-0-I2S-2way-crossover-s16le-s16le-48k-24576k-codec.*test-playback-ssp5-mclk-0-I2S-3way-crossover-s16le-s16le-48k-24576k-codec.*test-playback-ssp5-mclk-0-I2S-4way-crossover-s16le-s16le-48k-24576k-codec.*and so on.
Testbench Run
For example of running 4way-crossover playback, the coefficient file with 4-sink crossover should be generated under tools/tune/crossover/ by
octave example_crossover.mThen after building, run testbench by the following command:
testbench -i input -o output_1,output_2,output_3,output_4 -t test-playback-ssp5-mclk-0-I2S-4way-crossover-s16le-s16le-48k-24576k-codec.tplg -r 48000 -R 48000 -c 1 -b S16_LE -a crossover=libsof_crossover.sowhere argument "-o" now accepts specifying up to 4 output file names delimited by comma (in 4way case 4 files should be given), and "-c" specifies channels. The 4way topology file should be specified.