Before it is used, the Barrier needs to know how many threads will be using it.
在使用之前,Barrier需要知道有多少线程将会使用它。
So, whether the code is buggy depends on how many threads can access the operation concurrently.
所以,代码是否有问题取决于有多少线程能够并发地访问这个操作。
An administrator decides how much resource (for example, how many threads) they want to allocate to an application.
管理员可以决定分配多少资源给一个应用程序(例如决定分配多少个线程)。
应用推荐