SWDEV-234295 - Dont clear device programs during amd::program::build()

Change-Id: I87bc7e2c830edee783ee490bbb087492467f2704


[ROCm/clr commit: e9bd41bf1a]
Este commit está contenido en:
kjayapra-amd
2020-06-01 18:40:19 -04:00
cometido por Karthik Jayaprakash
padre 41d93c5cad
commit a9ead10354
Se han modificado 2 ficheros con 6 adiciones y 4 borrados
Archivo normal → Archivo ejecutable
+5 -3
Ver fichero
@@ -469,7 +469,7 @@ void Program::StubProgramSource(const std::string& app_name) {
int32_t Program::build(const std::vector<Device*>& devices, const char* options,
void(CL_CALLBACK* notifyFptr)(cl_program, void*), void* data,
bool optionChangable) {
bool optionChangable, bool newDevProg) {
ScopedLock sl(buildLock_);
int32_t retval = CL_SUCCESS;
@@ -485,8 +485,10 @@ int32_t Program::build(const std::vector<Device*>& devices, const char* options,
StubProgramSource(devices[0]->appProfile()->appFileName());
}
// Clear the program object
clear();
if (newDevProg) {
// Clear the program object
clear();
}
// Process build options.
std::string cppstr(options ? options : "");
Archivo normal → Archivo ejecutable
+1 -1
Ver fichero
@@ -205,7 +205,7 @@ class Program : public RuntimeObject {
//! Build the program for the given devices.
int32_t build(const std::vector<Device*>& devices, const char* options = NULL,
void(CL_CALLBACK* notifyFptr)(cl_program, void*) = NULL, void* data = NULL,
bool optionChangable = true);
bool optionChangable = true, bool newDevProg = true);
//! RTTI internal implementation
virtual ObjectType objectType() const { return ObjectTypeProgram; }