We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
YY 大神你好,请教一个问题:
你用多个串行队列来实现并发、控制线程数量,避免GCD在并行队列上执行耗时任务时开辟过多线程、消耗系统资源。如果通过NSOperationQueue 和 NSOperation的方式,控制maxConcurrentOperationCount 为YYAsyncLayerGetDisplayQueue中的queueCount,能够实现同样的效果嘛?
The text was updated successfully, but these errors were encountered:
I prefer NSOperationQueue ~
Sorry, something went wrong.
NSOperation的实现其实也是CGD了,所以一般情况下NS一层怎么都会有性能损失的,NSOperation感觉比较适合用在你要管理线程状态的时候,比如NSOperation的start,ready等的状态,可以看SW和YYImageWeb,大量用到NSOperation,主要原因是如果你要对并行并行队列做状态控制的话,比较麻烦,所以不得不用NSOperation,但假如你只想控制线程数量,何必直接用CGD串行队列呢?
No branches or pull requests
YY 大神你好,请教一个问题:
你用多个串行队列来实现并发、控制线程数量,避免GCD在并行队列上执行耗时任务时开辟过多线程、消耗系统资源。如果通过NSOperationQueue 和 NSOperation的方式,控制maxConcurrentOperationCount 为YYAsyncLayerGetDisplayQueue中的queueCount,能够实现同样的效果嘛?
The text was updated successfully, but these errors were encountered: