Making Rust respect worker count in config

Raphaël Gomès raphael.gomes at octobus.net
Thu Nov 7 15:48:25 UTC 2019


I'd like to make Rust respect to max worker count in config, since it 
now runs parallel code. Right now, it uses every CPU available, be it 
logical or physical.

I think the simplest way to do so, since Rust does not yet know how to 
read the config file, is to set the RAYON_NUM_THREADS environment 
variable in the Python layer as soon as possible.

I'm unsure where to do it though and what the implications are 
cross-platform. Maybe as soon as the config is loaded?

Thanks,

Raphaël



More information about the Mercurial-devel mailing list