P4 to Git Change 1084822 by emankov@em-hsa-amd on 2014/10/07 06:53:10

ECR #333753 - new tests are added to ocltst -m oclcomplib -t OCLRTGetInfo

	tests on aclQueryInfo for:
	RT_KERNEL_NAMES, RT_CONTAINS_LLVMIR, RT_CONTAINS_OPTIONS, RT_CONTAINS_BRIG, RT_CONTAINS_HSAIL, RT_CONTAINS_ISA

	+ query for RT_CONTAINS_HSAIL is fixed in Compiler Lib: looking for symbol symHSAILText instead of section aclCODEGEN, because aclCODEGEN section may contain also symOpenclMeta, symOpenclKernel, symOpenclStub besides symHSAILText.

	Testing: pre check-in, ocltst -m oclcomplib

	Reviewer: Brian Sumner

Affected files ...

... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/v0_8/if_acl.cpp#53 edit
... //depot/stg/opencl/drivers/opencl/tests/ocltst/module/complib/oclrtGetInfo.cpp#16 edit


[ROCm/clr commit: 99fdc9adbb]
Este commit está contenido en:
foreman
2014-10-07 07:04:03 -04:00
padre cef8182af7
commit 302c6e0f6f
@@ -2296,7 +2296,10 @@ if_aclQueryInfo(aclCompiler *cl,
*size = sizeof(bool);
return ACL_SUCCESS;
} else if (*size >= sizeof(bool)) {
bool contains = elfBin->isSection(aclCODEGEN);
const oclBIFSymbolStruct* sym = findBIF30SymStruct(symHSAILText);
assert(sym && "symbol not found");
std::string symbolName = sym->str[PRE] + std::string("main") + sym->str[POST];
bool contains = elfBin->isSymbol(aclCODEGEN, symbolName.c_str());
memcpy(ptr, &contains, sizeof(bool));
return ACL_SUCCESS;
}