P4 to Git Change 1298635 by lmoriche@lmoriche_opencl_dev on 2016/08/03 15:14:04

SWDEV-94644 - Comment out sections of the rocm virtual device still using the compiler library.

Affected files ...

... //depot/stg/opencl/drivers/opencl/Makefile#55 edit
... //depot/stg/opencl/drivers/opencl/api/opencl/amdocl/Makefile#6 edit
... //depot/stg/opencl/drivers/opencl/api/opencl/amdocl/build/Makefile.api#134 edit
... //depot/stg/opencl/drivers/opencl/compiler/Makefile#66 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/build/Makefile.utils#18 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/device.cpp#199 edit
... //depot/stg/opencl/drivers/opencl/runtime/platform/program.cpp#79 edit
이 커밋은 다음에 포함됨:
foreman
2016-08-03 15:30:13 -04:00
부모 554b5472d3
커밋 2ee7f40651
2개의 변경된 파일19개의 추가작업 그리고 0개의 파일을 삭제
+12
파일 보기
@@ -48,11 +48,15 @@ cl_int
Program::addDeviceProgram(Device& device, const void* image, size_t length,
amd::option::Options* options)
{
#if defined(WITH_LIGHTNING_COMPILER)
assert(!"FIMXE_Wilkins: check the code below");
#else // !defined(WITH_LIGHTNING_COMPILER)
if (image != NULL &&
!aclValidateBinaryImage(image, length,
isSPIRV_?BINARY_TYPE_SPIRV:BINARY_TYPE_ELF|BINARY_TYPE_LLVM)) {
return CL_INVALID_BINARY;
}
#endif // !defined(WITH_LIGHTNING_COMPILER)
// Check if the device is already associated with this program
if (deviceList_.find(&device) != deviceList_.end()) {
@@ -71,6 +75,9 @@ Program::addDeviceProgram(Device& device, const void* image, size_t length,
options = &emptyOpts;
emptyOptions = true;
}
#if defined(WITH_LIGHTNING_COMPILER)
assert(!"FIMXE_Wilkins: check the code below");
#else // !defined(WITH_LIGHTNING_COMPILER)
if (image != NULL && length != 0 && aclValidateBinaryImage(image, length, BINARY_TYPE_ELF)) {
acl_error errorCode;
aclBinary *binary = aclReadFromMem(image, length, &errorCode);
@@ -92,8 +99,11 @@ Program::addDeviceProgram(Device& device, const void* image, size_t length,
return CL_INVALID_COMPILER_OPTIONS;
}
}
#if !defined(WITH_LIGHTNING_COMPILER)
options->oVariables->Legacy = isAMDILTarget(*aclutGetTargetInfo(binary));
#endif // !defined(WITH_LIGHTNING_COMPILER)
}
#endif // !defined(WITH_LIGHTNING_COMPILER)
options->oVariables->BinaryIsSpirv = isSPIRV_;
device::Program* program = rootDev.createProgram(options);
if (program == NULL) {
@@ -296,6 +306,7 @@ Program::link(
// Check the binary's target for the first found device program.
// TODO: Revise these binary's target checks
// and possibly remove them after switching to HSAIL by default.
#if !defined(WITH_LIGHTNING_COMPILER)
if (!found && binary.first != NULL && binary.second > 0) {
acl_error errorCode = ACL_SUCCESS;
void *mem = const_cast<void*>(binary.first);
@@ -310,6 +321,7 @@ Program::link(
parsedOptions.oVariables->Frontend = "edg";
}
}
#endif // !defined(WITH_LIGHTNING_COMPILER)
found = true;
}
if (inputDevPrograms.size() == 0) {