-
Notifications
You must be signed in to change notification settings - Fork 73
Remove deprecated wmic dependency #286
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
base: amd-staging
Are you sure you want to change the base?
Conversation
Thanks for the heads up on the deprecation and the submission! The truncation of output with the PowerShell command removes a good chunk of the driver path. Could you set |
@harkgill-amd thank you for your comments! applied. Hope that 1000 would be enough for various driver paths |
amd/hipcc/src/hipBin_base.h
Outdated
system("powershell -c \"Get-CIMInstance -query 'SELECT * FROM win32_VideoController' | " | ||
"ft AdapterCompatibility,InstalledDisplayDrivers,Name\" | " | ||
"findstr /B /C:\"Advanced Micro Devices\" | " | ||
"Out-String -Width 1000"); |
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.
Out-String
isn't being included in the powershell portion of the command - this'll be interpreted as CMD line and throw an error.
It should be the following
system("powershell -c \"Get-CIMInstance -query 'SELECT * FROM win32_VideoController' | "
"ft AdapterCompatibility,InstalledDisplayDrivers,Name\ | "
"Out-String -Width 1000 | findstr /B /C:\'Advanced Micro Devices'\"");
Width of 1000 LGTM.
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.
My bad misplaced it. Corrected now
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.
Is hipconfig
working on your end after these changes? From what I can see,
- The powershell command is still being closed early due to the
"
afterName
. - findstr is not parsing
/C:\"Advanced Micro Devices\"
correctly.
I'm not entirely sure why the double quotes aren't working correctly despite it being used in the wmic findstr command as well. If you could confirm that hipconfig correctly outputs the driver path, I'm good to approve this. For reference, findstr /B /C:\'Advanced Micro Devices'
worked on my end.
Reason: Deprecation notice
Partly addresses the ROCm/TheRock#1106 in llvm-project
Output remains same: