The specific syntax isn't terribly important at this point, but the parser would essentially just unroll the loop in that case.
It's not the syntax I'm trying to ask about, it's the implementation.
The proposal here is that the parser gets a list of shader models (1, 3, 5), then runs the tests multiple times with each backend, passing one shader model at a time ("selected_shader_model"). If a shader model isn't supported by a backend [either inherently, like sm4 with d3d9, or because of missing features, like perhaps sm6 with Vulkan] then the test is skipped by check_requirements().
If we instead make shader model parsing the runner's responsibility, then as far as I can see the backend is going to have to do... pretty much the exact same thing, but in a more circumlocutious manner. I don't see the point of this, since I fail to anticipate any reason a runner would need more control over the way *HLSL* is directed to be compiled. And I fail to see why orthogonality is a concern since the decision is made pretty arbitrarily?
Having things like the following makes sense to me:
``` run_tests_opengl_glsl(); run_tests_opengl_spirv(); run_tests_vulkan_spirv(); ```
and I can see the argument (if it's indeed being made) that anything else should be organized the same way. For things that matter to the runner (i.e. most of the items in your list) I think that's right, but I don't see that making sense for something that needs to be controlled by the input file.
(And, if we say that there's a "default" list of selected_shader_models, probably (1, 4, 6), then we don't even need to invoke e.g. "d3d12 + sm4" and "d3d12 + sm6" separately at the top level anymore.)
The broader, more important point though is that most of what's in this MR just shouldn't be needed for d3dbc support.
No, it's not, and we could just take something like [1] which I wrote ages ago. But I think that more individual shader levels is something we're going to need sooner rather than later. I already have tests for sm1 semantics that would like it.
[1], https://gitlab.winehq.org/zfigura/vkd3d/-/commit/f0a92809bb43eb0761985b4db3a...