[dvsim] Allow multiple `en_build_mode` values for a single test
This stems from an offline discussion with @sriyerg.
Allowing dvsim to handle multiple build_modes being specified on a per-test basis could potentially allow for greater ease of setting up testlists for DUTs with multiple parameter configurations.
Example use-case is the KMAC IP, where we want to test both the masked and unmasked versions (controlled by a compile-time parameter). Since only one build_mode is supported per test the current approach is to create two Hjson config files (and testlists) for each of the parameter sets.
Sounds like a good idea. I guess the challenge is working out how to avoid having to change all the other configs to use singleton lists. Maybe we could teach the "mode merging" code to allow either option?
We need to change the behavior of en_build_mode: "foo" which takes a string value, to use_build_modes: ["foo", bar"], which can take a list of values. I imagine this is not too difficult to achieve.
Please beware of this though: if you run with --cov, it will attempt to merge coverage across all build-time variants of KMAC and generate one report (since all of it would be implemented as a part of a single unified HJson cfg file). Is that what we want, or do we want to close coverage on these variants of KMAC separately?
(Reviving this discussion) - For IPs with separate variants, usually coverage should be closed separately for each variant.
@sriyerg can this issue be updated / closed?
Low prio pending task.