P4 to Git Change 1483021 by lmoriche@lmoriche_opencl_dev2 on 2017/11/15 21:49:30

SWDEV-118564 - [OCL-LC-ROCm] Disable HSAILProgram and HSAILKernel if the compiler library is not available.

Affected files ...

... //depot/stg/opencl/drivers/opencl/opencldefs#222 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/device.cpp#214 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/roccompiler.cpp#39 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocdevice.cpp#76 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rockernel.cpp#31 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rockernel.hpp#18 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocprogram.cpp#76 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocprogram.hpp#31 edit
... //depot/stg/opencl/drivers/opencl/runtime/platform/program.cpp#89 edit
This commit is contained in:
foreman
2017-11-15 21:58:49 -05:00
orang tua 88783fe59b
melakukan 5ec0d059a3
8 mengubah file dengan 40 tambahan dan 2 penghapusan
+6 -1
Melihat File
@@ -498,6 +498,7 @@ static inline cl_kernel_arg_type_qualifier GetOclTypeQual(const aclArgData* argI
return rv;
}
#if defined(WITH_COMPILER_LIB)
void HSAILKernel::initArguments(const aclArgData* aclArg) {
device::Kernel::parameters_t params;
@@ -560,6 +561,7 @@ void HSAILKernel::initArguments(const aclArgData* aclArg) {
}
createSignature(params);
}
#endif // defined(WITH_COMPILER_LIB)
#if defined(WITH_LIGHTNING_COMPILER)
void LightningKernel::initArguments(const KernelMD& kernelMD) {
@@ -726,6 +728,7 @@ bool LightningKernel::init() {
}
#endif // defined(WITH_LIGHTNING_COMPILER)
#if defined(WITH_COMPILER_LIB)
bool HSAILKernel::init() {
acl_error errorCode;
// compile kernel down to ISA
@@ -830,6 +833,7 @@ bool HSAILKernel::init() {
}
return true;
}
#endif // defined(WITH_COMPILER_LIB)
#if defined(WITH_LIGHTNING_COMPILER)
void LightningKernel::initPrintf(const std::vector<std::string>& printfInfoStrings) {
@@ -923,6 +927,7 @@ void LightningKernel::initPrintf(const std::vector<std::string>& printfInfoStrin
}
#endif // defined(WITH_LIGHTNING_COMPILER)
#if defined(WITH_COMPILER_LIB)
void HSAILKernel::initPrintf(const aclPrintfFmt* aclPrintf) {
PrintfInfo info;
uint index = 0;
@@ -986,7 +991,7 @@ void HSAILKernel::initPrintf(const aclPrintfFmt* aclPrintf) {
info.arguments_.clear();
}
}
#endif // defined(WITH_COMPILER_LIB)
Kernel::~Kernel() {
while (!hsailArgList_.empty()) {