Parpool thread-based pool size
25 views (last 30 days)
Show older comments
Alessandro
on 8 Sep 2025
Commented: Georgi
on 16 Oct 2025 at 7:53
I have a computer with 14 physical cores: 12th Gen Intel(R) Core(TM) i7-12800H, 2400 Mhz, 14 Core(s), 20 Logical Processor(s)).
I can set
p=parpool('processes',8)
and I get what I expect
p =
ProcessPool with properties:
Connected: true
NumWorkers: 8
Busy: false
Cluster: processes (Local Cluster)
AttachedFiles: {}
AutoAddClientPath: true
FileStore: [1x1 parallel.FileStore]
ValueStore: [1x1 parallel.ValueStore]
IdleTimeout: 30 minutes (30 minutes remaining)
SpmdEnabled: true
However, if I type
delete(p)
p=parpool('threads',8)
I get this error message:
Error using parpool (line 108)
A minimum pool size of 8 was requested. The maximum thread-based pool size is currently 6.
Is there a way to increase the maximum thread-based pool size above 6 (given that my Intel CPU has 14 physical cores)?
Thanks!
0 Comments
Accepted Answer
Walter Roberson
on 8 Sep 2025
With that particular number of physical cores (14), chances are high that you have a mix of "performace" cores and "efficiency" cores. There is currently a restriction, that thread-based pools can only use performance cores.
4 Comments
Walter Roberson
on 15 Oct 2025 at 23:21
There does not appear to be any way to select process based instead of thread based.
Georgi
on 16 Oct 2025 at 7:53
Thank you. I found that when executing
maxNumCompThreads(16); % 16 Logical cores in a Gen9 Core i9 CPU
parpool('Processes',maxNumCompThreads);
before I start the regressionLearner model training, the tool uses the parallel pool already created with the 'Processes' profile.
But it turned out that numWorkers was not the bottleneck in my calculations, and even those 8 Workers were far from fully used (CPU load was barely 10-20%). Strangely, in R2024aU7, the regressionLearner tool uses at ~12-20% one of the DMA Engines (shown as 'Copy 1' in Windows Task Manager) of my nVidia Quadro RTX3000, and this at 0% 3D load on that GPU (well, most of the time). In R2025aU1 on the same laptop (128 GB or RAM), that GPU is not used at all, and the same model training (and iterations number) takes notably longer time. On a server with 36 logical cores per CPU and no GPU accelerator, in R2022a, the same model training takes 5.3 times longer (!!!).
More Answers (0)
See Also
Categories
Find more on Parallel Computing Fundamentals in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!