mirror of
https://github.com/opencv/opencv.git
synced 2025-08-05 22:19:14 +08:00
ocl: cache program build failures
To prevent unnecessary compiler invocations
This commit is contained in:
parent
cca99bf824
commit
d96cac1341
@ -1387,7 +1387,7 @@ struct Context::Impl
|
||||
}
|
||||
}
|
||||
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);
|
||||
phash.insert(std::pair<std::string, Program>(key, prog));
|
||||
|
Loading…
Reference in New Issue
Block a user