-
Notifications
You must be signed in to change notification settings - Fork 790
[SYCL] Test memory allocated by buffer creation API. #3156
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Signed-off-by: rdeodhar <[email protected]>
@@ -0,0 +1,26 @@ | |||
// REQUIRES: gpu,level_zero |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this test needs to be E2E and go into llvm-test-suite
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that is the plan. It is here so it can be reviewed.
Later, after the plugin change has been merged, the test will be moved to llvm-test-suite.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am closing this PR since with no plugin change required, the test can go to llvm-test-suite directly.
if (DeviceIsIntegrated) | ||
zePrint("Buffer Create: Integrated GPU will use zeMemAllocHost\n"); | ||
else | ||
zePrint("Buffer Create: Discrete GPU will use zeMemAllocDevice\n"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we need to pollute the traces with these pritns. Note that ZE_CALL macro already prints the L0 calls being made, just use those.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From the existing L0 calls we cannot tell if discrete or integrated GPU is detected.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can query the device if it is integrated or not, from the sycl program
Example use: /backport llvm_release_190 Expected behaviour: IF user input != /backport llvm_release<digits> THEN out << Invalid backport command. Expected /backport llvm_release_<digits> STOP out << Attempting to create PR to <target>... IF merge_conflict THEN out << Backport to <target> failed due to conflicts on commit <sha>. Please backport manually. STOP ELSE create_pr AND out << Success. Backport PR created: <PR_URL> SUCCESS Signed-off-by: Sidorov, Dmitry <[email protected]> Original commit: KhronosGroup/SPIRV-LLVM-Translator@5cf776c1fb980d7
This change enables testing whether buffers on integrated / discrete devices are created in host / device memory as expected.
Signed-off-by: rdeodhar [email protected]