onnxruntime/tools
Scott McKay 580ee20dfc
Tweak Windows build parallelization settings (#19664)
### Description
<!-- Describe your changes. -->
Use UseMultiToolTask and limit the number of cl.exe instances running. 

MultiToolTask info:
https://devblogs.microsoft.com/cppblog/improved-parallelism-in-msbuild/

Info on why limiting CL_MPCount can help:
https://github.com/Microsoft/checkedc-clang/wiki/Parallel-builds-of-clang-on-Windows

The current CIs have 4 cores (both physical and logical). Hardcoded the
GPU build in win-ci.yml to use CL_MPCount of 2 as that seems to work
fine. Can adjust if needed to base it on the actual number of cores or
to use build.py to build.

Caveat: I've run about 16 builds and haven't seen a slow build yet, but
as the root cause of the slow builds isn't really known this isn't
guaranteed to be a fix.

### Motivation and Context
<!-- - Why is this change required? What problem does it solve?
- If it fixes an open issue, please link to the issue here. -->
Try and prevent super slow GPU builds by reducing number of tasks
potentially running in parallel.
2024-02-27 08:56:16 -08:00
..
android_custom_build Update NDK version to 26.1.10909125 (#18493) 2023-11-17 14:14:01 -08:00
ci_build Tweak Windows build parallelization settings (#19664) 2024-02-27 08:56:16 -08:00
doc Disable PERF* rules in ruff to allow better readability (#16834) 2023-07-25 15:38:22 -07:00
nuget Update DirectML nuget version to 1.13.1 (#19122) 2024-01-15 19:04:41 -08:00
perf_view fixed #16873 (#16932) 2023-09-26 09:57:01 -07:00
python Add helper to run CIs for a branch using az pipelines. (#16843) 2024-02-24 14:06:30 +10:00
scripts Fix a build issue: /MP was not enabled correctly (#19190) 2024-01-29 12:45:38 -08:00