A high-performance image framework, including a series of capabilities such as image views, image downloader, memory caches, disk caches, image decoders and image processors.
Other
2.08k
stars
287
forks
source link
LKImageMemoryCache: fix thread conflict, add spinlock to protect conta… #19
MemoryCache is Only use in main Thread. A Assert will occur if developer using instance in other threads.
So it should not have any locks because of high-performance.
MemoryCache对外暴露的接口在多线程调用时可能会导致迭代器失效,分支中加上一个spinlock