bazel-ios / rules_ios

Bazel rules for building iOS applications and frameworks
Apache License 2.0
278 stars 85 forks source link

Use remote cache when building in xcodeproj on CI #788

Closed mattrobmattrob closed 1 year ago

mattrobmattrob commented 1 year ago

Attempt to speed up the slow .xcodeproj Tests on Xcode 14.2.0 job on CI.

jszumski commented 1 year ago

From the timing it looks like this ended up saving 7m?

mattrobmattrob commented 1 year ago

From the timing it looks like this ended up saving 7m?

These GitHub VMs are impossible to benchmark against I'm finding. Ha. Will look a bit deeper tomorrow.

mattrobmattrob commented 1 year ago

In general, I think this is a positive change. But the slowness of this particular build is likely coming from lots of places.

For example, the serial generation of the Xcode projects is slow (even on my M1 Pro MacBook Pro), likely even worse than this benchmark on the IO starved Github Action VMs:

$ time bazelisk query 'kind("xcodeproj rule", tests/ios/xcodeproj/...)' | xargs -n 1 bazelisk run
...
xargs -n 1 bazelisk run  18.36s user 68.33s system 76% cpu 1:52.81 total