Skip to content

Make LongVectors tests specified in code and have appropriate HLK properties set#7758

Merged
damyanp merged 33 commits intomicrosoft:mainfrom
damyanp:damyanp/xp
Sep 16, 2025
Merged

Make LongVectors tests specified in code and have appropriate HLK properties set#7758
damyanp merged 33 commits intomicrosoft:mainfrom
damyanp:damyanp/xp

Conversation

@damyanp
Copy link
Copy Markdown
Member

@damyanp damyanp commented Sep 12, 2025

This change moves all of the test definitions from the XML file to the .cpp file and generally moves away from string-matching to statically typed specification of tests, opcodes and test data sets.

@damyanp damyanp changed the title Remove LongVectors.h, use inline test macros, use macro for test methods Make LongVectors tests specified in code and have appropriate HLK properties set Sep 13, 2025
@damyanp damyanp marked this pull request as ready for review September 13, 2025 19:30
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Sep 15, 2025

✅ With the latest revision this PR passed the C/C++ code formatter.

Comment thread tools/clang/unittests/HLSLExec/LongVectors.cpp Outdated
Comment thread tools/clang/unittests/HLSLExec/LongVectors.cpp Outdated
runAndVerify(Config, OpType, Inputs, Expected, ExtraDefines,
ValidationConfig);
}
// Strict Validation - for all types require exact matches.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// Strict Validation - for all types require exact matches.
// Strict Validation - for all types that require exact matches.

Comment thread tools/clang/unittests/HLSLExec/LongVectors.cpp
if (Config.LongVectorInputSize)
InputVectorSizes.push_back(Config.LongVectorInputSize);
else
InputVectorSizes = {3, 4, 5, 16, 17, 35, 100, 256, 1024};
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
InputVectorSizes = {3, 4, 5, 16, 17, 35, 100, 256, 1024};
// This is the default case. Config.LongVectorInputSize is set via a runtime parameter for local testing.
InputVectorSizes = {3, 4, 5, 16, 17, 35, 100, 256, 1024};

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm going to try and find a way to express this in the code.

Comment thread tools/clang/unittests/HLSLExec/LongVectors.cpp
Comment thread tools/clang/unittests/HLSLExec/LongVectorOps.def
Comment thread tools/clang/unittests/HLSLExec/LongVectorOps.def
Comment thread tools/clang/unittests/HLSLExec/LongVectorTestData.h
Comment thread tools/clang/unittests/HLSLExec/LongVectors.cpp
Copy link
Copy Markdown
Contributor

@alsepkow alsepkow left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. A few minor comments.

@damyanp damyanp enabled auto-merge (squash) September 16, 2025 21:45
@damyanp damyanp merged commit c5854cf into microsoft:main Sep 16, 2025
12 checks passed
@github-project-automation github-project-automation Bot moved this from New to Done in HLSL Roadmap Sep 16, 2025
@damyanp damyanp deleted the damyanp/xp branch September 16, 2025 23:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants