Commit bf418ba3 authored by Maksim Shabunin's avatar Maksim Shabunin

Merge pull request #9917 from alalek:ocl_cache_program_failures

parents be9767e0 d96cac13
...@@ -1387,7 +1387,7 @@ struct Context::Impl ...@@ -1387,7 +1387,7 @@ struct Context::Impl
} }
} }
Program prog(src, buildflags, errmsg); Program prog(src, buildflags, errmsg);
if(prog.ptr()) // Cache result of build failures too (to prevent unnecessary compiler invocations)
{ {
cv::AutoLock lock(program_cache_mutex); cv::AutoLock lock(program_cache_mutex);
phash.insert(std::pair<std::string, Program>(key, prog)); phash.insert(std::pair<std::string, Program>(key, prog));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment