mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-06-08 00:23:03 +00:00
Use xcode parallel build flags to speed up iOS CI that is timing out (#19570)
### Description <!-- Describe your changes. --> Provide specific xcodebuild flags instead of depending on cmake to do the right thing. This built in just over an hour with a ccache miss. Previous CIs with a ccache miss were timing out after 150 minutes. ### 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. -->
This commit is contained in:
parent
3c49aacd56
commit
ec9c8cbdc9
1 changed files with 10 additions and 5 deletions
|
|
@ -1631,9 +1631,11 @@ def generate_build_tree(
|
|||
[
|
||||
*temp_cmake_args,
|
||||
f"-DCMAKE_BUILD_TYPE={config}",
|
||||
f"-DCMAKE_PREFIX_PATH={build_dir}/{config}/installed"
|
||||
if preinstalled_dir.exists() and not (args.arm64 or args.arm64ec or args.arm)
|
||||
else "",
|
||||
(
|
||||
f"-DCMAKE_PREFIX_PATH={build_dir}/{config}/installed"
|
||||
if preinstalled_dir.exists() and not (args.arm64 or args.arm64ec or args.arm)
|
||||
else ""
|
||||
),
|
||||
],
|
||||
cwd=config_build_dir,
|
||||
cuda_home=cuda_home,
|
||||
|
|
@ -1667,8 +1669,11 @@ def build_targets(args, cmake_path, build_dir, configs, num_parallel_jobs, targe
|
|||
f"/p:CL_MPCount={num_parallel_jobs}",
|
||||
]
|
||||
elif args.cmake_generator == "Xcode":
|
||||
# CMake will generate correct build tool args for Xcode
|
||||
cmd_args += ["--parallel", str(num_parallel_jobs)]
|
||||
build_tool_args += [
|
||||
"-parallelizeTargets",
|
||||
"-jobs",
|
||||
str(num_parallel_jobs),
|
||||
]
|
||||
else:
|
||||
build_tool_args += [f"-j{num_parallel_jobs}"]
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue