[SM6.10][NFC] Combine LinAlg ops stage tests with errors and move under LitDXILValidation#8232
[SM6.10][NFC] Combine LinAlg ops stage tests with errors and move under LitDXILValidation#8232hekota wants to merge 2 commits into
Conversation
V-FEXrt
left a comment
There was a problem hiding this comment.
Not for now, but there is talk about adding -D from upstream into FileCheck. If that actually happens then it would be good to come back later and make the CHECK lines more strict
tex3d
left a comment
There was a problem hiding this comment.
Normally, our validation tests should be IR tests instead of from HLSL source. Especially since we need to add checks in Sema to catch these earlier, with better diagnostics.
Unfortunately, this makes it more difficult to use a bunch of RUN lines to test each scenario. It might be possible to run a preprocess step on the IR with defines selecting the core DXIL operation in the IR still though.
| { | ||
| __builtin_LinAlgMatrix [[__LinAlgMatrix_Attributes(1, 5, 4, 2, 2)]] mat1; | ||
| __builtin_LinAlgMatrix [[__LinAlgMatrix_Attributes(1, 5, 4, 2, 2)]] mat2; | ||
| __builtin_LinAlgMatrix [[__LinAlgMatrix_Attributes(1, 5, 4, 2, 2)]] mat3; |
There was a problem hiding this comment.
I imagine we're going to also want validation for legal and consistent matrix attributes for each DXIL op. These attributes selected here definitely create invalid calls below, regardless of shader stage. We could probably create A, B, and Accumulator matrix args, which have consistent dimensions/component types so that these calls are only illegal due to their shader stage.
There was a problem hiding this comment.
I'll try to update these to use valid types when I convert to IR tests. I believe we are going to handle parameter validation after we ship the preview, so if I miss any we can fix it up then.
Got it. I did not realize these should have been IR tests from the start. |
|
These should be IR validation tests. |
All of the test files are very similar and can be combined into a single file with multiple //RUN: lines.
These are validation tests, not Sema, so the new file is created in
LitDXILValidationdirectory.Part of #8211