vkd3d-shader: Add compiler option to specify matrix majority.
Signed-off-by: Nikolay Sivov nsivov@codeweavers.com
Merge request reports
Activity
This is only supported/used for HLSL sources, and I think the documentation should reflect that. (See e.g. the documentation for VKD3D_SHADER_COMPILE_OPTION_WRITE_TESS_GEOM_POINT_SIZE.) The documentation for some of the existing compilation options probably has room for improvement as well.
added 1 commit
- 0cba1f8a - vkd3d-shader: Add compiler option to specify matrix majority.
At first sight this doesn't look wrong, but previous tests (see
tests/hlsl/majority_*.shader_test
) show that the way majority interacts withpragma
's andtypedef
's is quite complicated. In particular, there are some subtle differences between having column majority as a result of setting it explicitly via apragma
and as a result of not having set any other default. How that interacts with the majority set via a compilation flag is therefore not necessarily obvious (i.e., is explicitly setting a column majority via a compilation flag equivalent to setting it viapragma
, or to leaving it to the unset default?), and for that reason it would be particularly appropriate to have tests for that.I posted some tests as wine!3263 (merged), what I think that shows is compiling options acting exactly as corresponding pragmas, when placed in front of the source file. Following pragmas will override the options, conflicting modifiers will produce errors, same as pragmas should be doing already.
Another aspect is that you can't have both options on, but I think it's easier to filter that on wine side, keeping unnecessary validation out of the library.
added 49 commits
-
0cba1f8a...aec9ea08 - 46 commits from branch
wine:master
- 30fabe88 - vkd3d-shader: Add compiler option to specify matrix majority.
- cf112f29 - tests: Add test file syntax to specify compiler options.
- 193bf43a - tests: Add some tests for matrix packing compiler options.
Toggle commit list-
0cba1f8a...aec9ea08 - 46 commits from branch
I see what you mean now, I adjusted tests to show the difference. And to work correctly with pre-sm4 target that insist on allocating adjusting uniform register sizes based on its usage (https://bugs.winehq.org/show_bug.cgi?id=55207).
added 21 commits
-
66540e3d...e0e261ea - 18 commits from branch
wine:master
- 6efc6ccd - vkd3d-shader: Add compiler option to specify matrix majority.
- 066b8349 - tests: Add test file syntax to specify compiler options.
- e2ebda0a - tests: Add some tests for matrix packing compiler options.
Toggle commit list-
66540e3d...e0e261ea - 18 commits from branch
added 4 commits
Toggle commit list