P4 to Git Change 1348313 by gandryey@gera-w8 on 2016/12/01 14:38:56

SWDEV-98415 - [CQE OCL][OpenCL on PAL] Failures/Crash is observed with multiple modules of ocltst
	- Fix a regression with oflline compilation. Mark null program.

Affected files ...

... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palprogram.cpp#26 edit
This commit is contained in:
foreman
2016-12-01 14:54:04 -05:00
förälder e86db9a564
incheckning bf9217468e
+3
Visa fil
@@ -166,6 +166,7 @@ HSAILProgram::HSAILProgram(NullDevice& device)
, loaderContext_(this)
{
memset(&binOpts_, 0, sizeof(binOpts_));
isNull_ = true;
binOpts_.struct_size = sizeof(binOpts_);
binOpts_.elfclass = LP64_SWITCH(ELFCLASS32, ELFCLASS64);
binOpts_.bitness = ELFDATA2LSB;
@@ -754,9 +755,11 @@ HSAILProgram::hsailOptions(amd::option::Options* options)
int major, minor;
::sscanf(device().info().version_, "OpenCL %d.%d ", &major, &minor);
#ifdef WITH_LIGHTNING_COMPILER
std::stringstream ss;
ss << " -D__OPENCL_VERSION__=" << (major * 100 + minor * 10);
hsailOptions.append(ss.str());
#endif
if (device().info().imageSupport_ && options->oVariables->ImageSupport) {
hsailOptions.append(" -D__IMAGE_SUPPORT__=1");