Open sassy-crick opened 2 years ago
Hello, we tried to use PARALLEL_MAKE and tried to achieve the faster build. Here are my observations, 8 Core - Build completed successfully in 0:22:52 16 Core - Build completed successfully in 0:15:11 32 Core - Build completed successfully in 0:12:37 64 Core - Build completed successfully in 0:12:14 96 Core - Build completed successfully in 0:12:33 128 Core - Build completed successfully in 0:12:11 192 Core - Build completed successfully in 0:12:09 When the PARALLEL_MAKE is greater than or equal to 32, the time remains same... Seems that its run as 32 parallel at the most
Regards Chandra
To add to this: this is roughly what I observe as well: building with cores is not significantly slower than with 64 cores.
That said: the problem is that right now it is ignoring the make -j 8
command and uses all available cores, real and virtual ones. That should not happen in my opinion.
@sassy-crick it looks like this issue is specifically about cmake
not being passed the correct -j
flag, is that right? Not cargo in general?
Mentoring instructions: Change the code around https://github.com/rust-lang/rust/blob/9ef84076109ca9b6dd87fca7040781d778eb7605/src/bootstrap/native.rs#L315-L317 to pass build_arg(format!("-j{}", builder.config.jobs))
(or configure_arg
, I don't know cmake well enough).
I am building Rust on a large HPC cluster using EasyBuild but Rust is not behaving as it should:
I expected to see only 64 threads being used but Rust is ignoring my request to use only 64 cores and uses the max-number of available treads. This leads to a very poor performance as each thread spends more time waiting than actually doing. specially when there are 128 threads available. This seems to be a bug in Rust and not in EasyBuild, as above.
Meta