From d75577d6e7921a8bffc7091b5d23a5b8ea43f40f Mon Sep 17 00:00:00 2001 From: "Andrei, Kochin" Date: Wed, 23 Jul 2025 23:47:14 +0400 Subject: [PATCH 1/3] Remove deprecated wmic dependency --- amd/hipcc/src/hipBin_base.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/amd/hipcc/src/hipBin_base.h b/amd/hipcc/src/hipBin_base.h index ea37e6fd12fc8..4c0c78c1d60b9 100644 --- a/amd/hipcc/src/hipBin_base.h +++ b/amd/hipcc/src/hipBin_base.h @@ -391,8 +391,9 @@ void HipBinBase::getSystemInfo() const { cout << endl << "== Windows Display Drivers" << endl; cout << "Hostname :"; system("hostname"); - system("wmic path win32_VideoController get AdapterCompatibility," - "InstalledDisplayDrivers,Name | findstr /B /C:\"Advanced Micro Devices\""); + system("powershell -c \"Get-CIMInstance -query 'SELECT * FROM win32_VideoController' | " + "ft AdapterCompatibility,InstalledDisplayDrivers,Name\" | " + "findstr /B /C:\"Advanced Micro Devices\""); } else { assert(os == lnx); cout << endl << "== Linux Kernel" << endl; From 3d93bee84b1e691dcc51d5ec03ce1df003311d4e Mon Sep 17 00:00:00 2001 From: Andrei Kochin Date: Thu, 11 Sep 2025 12:52:25 +0400 Subject: [PATCH 2/3] Update based on comments --- amd/hipcc/src/hipBin_base.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/amd/hipcc/src/hipBin_base.h b/amd/hipcc/src/hipBin_base.h index 4c0c78c1d60b9..f8830bce11810 100644 --- a/amd/hipcc/src/hipBin_base.h +++ b/amd/hipcc/src/hipBin_base.h @@ -392,8 +392,9 @@ void HipBinBase::getSystemInfo() const { cout << "Hostname :"; system("hostname"); system("powershell -c \"Get-CIMInstance -query 'SELECT * FROM win32_VideoController' | " - "ft AdapterCompatibility,InstalledDisplayDrivers,Name\" | " - "findstr /B /C:\"Advanced Micro Devices\""); + "ft AdapterCompatibility,InstalledDisplayDrivers,Name\" | " + "findstr /B /C:\"Advanced Micro Devices\" | " + "Out-String -Width 1000"); } else { assert(os == lnx); cout << endl << "== Linux Kernel" << endl; From 410dbd79edbe2859a6b5833bffad81020d3a7bc1 Mon Sep 17 00:00:00 2001 From: Andrei Kochin Date: Thu, 11 Sep 2025 22:43:49 +0400 Subject: [PATCH 3/3] Fixed the 'command not found' err --- amd/hipcc/src/hipBin_base.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/amd/hipcc/src/hipBin_base.h b/amd/hipcc/src/hipBin_base.h index f8830bce11810..2aa169f2ebeed 100644 --- a/amd/hipcc/src/hipBin_base.h +++ b/amd/hipcc/src/hipBin_base.h @@ -393,8 +393,7 @@ void HipBinBase::getSystemInfo() const { system("hostname"); system("powershell -c \"Get-CIMInstance -query 'SELECT * FROM win32_VideoController' | " "ft AdapterCompatibility,InstalledDisplayDrivers,Name\" | " - "findstr /B /C:\"Advanced Micro Devices\" | " - "Out-String -Width 1000"); + "Out-String -Width 1000 | findstr /B /C:\"Advanced Micro Devices\""); } else { assert(os == lnx); cout << endl << "== Linux Kernel" << endl;