mirror of
https://github.com/monero-project/monero.git
synced 2025-08-10 22:20:07 -04:00
Second thread pool for IO
This commit is contained in:
parent
c9cfa25183
commit
28f25c0dbc
8 changed files with 17 additions and 13 deletions
|
@ -42,10 +42,14 @@ namespace tools
|
|||
class threadpool
|
||||
{
|
||||
public:
|
||||
static threadpool& getInstance() {
|
||||
static threadpool& getInstanceForCompute() {
|
||||
static threadpool instance;
|
||||
return instance;
|
||||
}
|
||||
static threadpool& getInstanceForIO() {
|
||||
static threadpool instance(8);
|
||||
return instance;
|
||||
}
|
||||
static threadpool *getNewForUnitTests(unsigned max_threads = 0) {
|
||||
return new threadpool(max_threads);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue