From 4195de8bb4a76a9e65d17e6b76cddeef8c1d62d1 Mon Sep 17 00:00:00 2001 From: foreman Date: Mon, 25 Feb 2019 14:33:44 -0500 Subject: [PATCH] P4 to Git Change 1748192 by jujiang@JJ-OCL-w8 on 2019/02/25 14:20:20 SWDEV-181012 - [CQE OCL][DTB-BLOCKER][QR][Windows][19.10] clinfo results in "clBuildProgram" error with OCL binaries. Faulty CL#1737731 - Remove some dead code as suggested by Konstantin Zhuravlyov - These strings are no longer needed, loader will never ask about them Affected files ... ... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpudefs.hpp#158 edit ... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpuprogram.cpp#248 edit [ROCm/clr commit: b7200ec2ad0eed85817b6b98054296010e493100] --- .../clr/rocclr/runtime/device/gpu/gpudefs.hpp | 8 +------ .../rocclr/runtime/device/gpu/gpuprogram.cpp | 21 +++---------------- 2 files changed, 4 insertions(+), 25 deletions(-) diff --git a/projects/clr/rocclr/runtime/device/gpu/gpudefs.hpp b/projects/clr/rocclr/runtime/device/gpu/gpudefs.hpp index 6ec634f08d..265af5f198 100644 --- a/projects/clr/rocclr/runtime/device/gpu/gpudefs.hpp +++ b/projects/clr/rocclr/runtime/device/gpu/gpudefs.hpp @@ -174,13 +174,10 @@ enum gfx_handle { gfx804 = 804, gfx810 = 810, gfx900 = 900, - gfx901 = 901, gfx902 = 902, gfx903 = 903, gfx904 = 904, - gfx905 = 905, - gfx906 = 906, - gfx907 = 907 + gfx906 = 906 }; static const char* Gfx700 = "amdgcn-amd-amdhsa--gfx700"; @@ -190,13 +187,10 @@ static const char* Gfx801 = "amdgcn-amd-amdhsa--gfx801+xnack"; static const char* Gfx804 = "amdgcn-amd-amdhsa--gfx804"; static const char* Gfx810 = "amdgcn-amd-amdhsa--gfx810+xnack"; static const char* Gfx900 = "amdgcn-amd-amdhsa--gfx900"; -static const char* Gfx901 = "amdgcn-amd-amdhsa--gfx901"; static const char* Gfx902 = "amdgcn-amd-amdhsa--gfx902+xnack"; static const char* Gfx903 = "amdgcn-amd-amdhsa--gfx902"; // NOTE: gfx903 is gfx902 with xnack static const char* Gfx904 = "amdgcn-amd-amdhsa--gfx904"; -static const char* Gfx905 = "amdgcn-amd-amdhsa--gfx905"; static const char* Gfx906 = "amdgcn-amd-amdhsa--gfx906"; -static const char* Gfx907 = "amdgcn-amd-amdhsa--gfx907"; // Supported OpenCL versions enum OclVersion { OpenCL10, OpenCL11, OpenCL12, OpenCL20, OpenCL21 }; diff --git a/projects/clr/rocclr/runtime/device/gpu/gpuprogram.cpp b/projects/clr/rocclr/runtime/device/gpu/gpuprogram.cpp index f0c918f66d..bf2447f39d 100644 --- a/projects/clr/rocclr/runtime/device/gpu/gpuprogram.cpp +++ b/projects/clr/rocclr/runtime/device/gpu/gpuprogram.cpp @@ -1807,10 +1807,6 @@ hsa_isa_t ORCAHSALoaderContext::IsaFromName(const char* name) { isa.handle = gfx900; return isa; } - if (!strcmp(Gfx901, name)) { - isa.handle = gfx901; - return isa; - } if (!strcmp(Gfx902, name)) { isa.handle = gfx902; return isa; @@ -1823,18 +1819,10 @@ hsa_isa_t ORCAHSALoaderContext::IsaFromName(const char* name) { isa.handle = gfx904; return isa; } - if (!strcmp(Gfx905, name)) { - isa.handle = gfx905; - return isa; - } if (!strcmp(Gfx906, name)) { isa.handle = gfx906; return isa; } - if (!strcmp(Gfx907, name)) { - isa.handle = gfx907; - return isa; - } return isa; } @@ -1871,22 +1859,19 @@ bool ORCAHSALoaderContext::IsaSupportedByAgent(hsa_agent_t agent, hsa_isa_t isa) return false; } case gfx900: - case gfx901: case gfx902: case gfx903: case gfx904: - case gfx905: case gfx906: - case gfx907: switch (program_->dev().hwInfo()->machine_) { case ED_ATI_CAL_MACHINE_GREENLAND_ISA: - return isa.handle == gfx900 || isa.handle == gfx901; + return isa.handle == gfx900; case ED_ATI_CAL_MACHINE_RAVEN_ISA: return isa.handle == gfx902 || isa.handle == gfx903; case ED_ATI_CAL_MACHINE_VEGA12_ISA: - return isa.handle == gfx904 || isa.handle == gfx905; + return isa.handle == gfx904; case ED_ATI_CAL_MACHINE_VEGA20_ISA: - return isa.handle == gfx906 || isa.handle == gfx907; + return isa.handle == gfx906; default: assert(0); return false;