P4 to Git Change 1472384 by lmoriche@lmoriche_opencl_dev2 on 2017/10/19 03:29:10

SWDEV-126884 - OCL 2.1 Platform APIs
	- Fix OCL/ROCm OpenCL C version

Affected files ...

... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpucompiler.cpp#157 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpudevice.cpp#578 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpuresource.cpp#240 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/paldevice.cpp#65 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/rocm/rocdevice.cpp#70 edit
... //depot/stg/opencl/drivers/opencl/runtime/runtimedefs#46 edit


[ROCm/clr commit: 46dcd95add]
This commit is contained in:
foreman
2017-10-19 03:34:06 -04:00
parent 470248bbc2
commit 8170a3f003
5 changed files with 12 additions and 10 deletions
@@ -439,7 +439,7 @@ void NullDevice::fillDeviceInfo(const Pal::DeviceProperties& palProp,
);
info_.profile_ = "FULL_PROFILE";
if (settings().oclVersion_ == OpenCL20) {
if (settings().oclVersion_ >= OpenCL20) {
info_.version_ = "OpenCL 2.0 " AMD_PLATFORM_INFO;
info_.oclcVersion_ = "OpenCL C 2.0 ";
info_.spirVersions_ = "1.2";
@@ -2151,7 +2151,7 @@ bool Device::createBlitProgram() {
const char* ocl20 = nullptr;
#if !defined(WITH_LIGHTNING_COMPILER)
std::string sch = SchedulerSourceCode;
if (settings().oclVersion_ == OpenCL20) {
if (settings().oclVersion_ >= OpenCL20) {
size_t loc = sch.find("%s");
sch.replace(loc, 2, iDev()->GetDispatchKernelSource());
scheduler = sch.c_str();