P4 to Git Change 1723529 by lmoriche@lmoriche_opencl_dev2 on 2018/12/21 14:55:55

SWDEV-174895 - OCL generic changes and code clean-up
	- Rename the AMDGCN builtins libraries to be compatible with comgr.

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/comgr/lib/comgr/src/comgr-device-libs.cpp#3 edit
... //depot/stg/opencl/drivers/opencl/library/build/Makefile.library#73 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/devprogram.cpp#24 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/CMakeLists.txt#17 edit


[ROCm/clr commit: 0b238e4420]
This commit is contained in:
foreman
2018-12-21 15:24:27 -05:00
parent b97e0be06e
commit 6f1583e3be
2 changed files with 12 additions and 12 deletions
@@ -798,10 +798,10 @@ bool Program::compileImplLC(const std::string& sourceCode,
case 100:
case 110:
case 120:
hdr = { opencl1_2_c_amdgcn, opencl1_2_c_amdgcn_size };
hdr = { opencl1_2_c, opencl1_2_c_size };
break;
case 200:
hdr = { opencl2_0_c_amdgcn, opencl2_0_c_amdgcn_size };
hdr = { opencl2_0_c, opencl2_0_c_size };
break;
default:
buildLog_ += "Unsupported requested OpenCL C version (-cl-std).\n";
@@ -1479,9 +1479,9 @@ bool Program::linkImplLC(amd::option::Options* options) {
inputs.push_back(input); // must be the first input
// open the bitcode libraries
Data* opencl_bc =
C->NewBufferReference(DT_LLVM_BC, (const char*)opencl_amdgcn, opencl_amdgcn_size);
Data* ocml_bc = C->NewBufferReference(DT_LLVM_BC, (const char*)ocml_amdgcn, ocml_amdgcn_size);
Data* ockl_bc = C->NewBufferReference(DT_LLVM_BC, (const char*)ockl_amdgcn, ockl_amdgcn_size);
C->NewBufferReference(DT_LLVM_BC, (const char*)opencl_lib, opencl_lib_size);
Data* ocml_bc = C->NewBufferReference(DT_LLVM_BC, (const char*)ocml_lib, ocml_lib_size);
Data* ockl_bc = C->NewBufferReference(DT_LLVM_BC, (const char*)ockl_lib, ockl_lib_size);
if (!opencl_bc || !ocml_bc || !ockl_bc) {
buildLog_ += "Error: Failed to open the bitcode library.\n";