Skip to content

Pass env variable instructing CI to write Bazel cache - #10248

Merged
GMNGeoffrey merged 5 commits into
iree-org:mainfrom
GMNGeoffrey:actually-cache
Aug 30, 2022
Merged

GMNGeoffrey merged 5 commits into
iree-org:mainfrom
GMNGeoffrey:actually-cache

Conversation

@GMNGeoffrey

@GMNGeoffrey GMNGeoffrey commented Aug 30, 2022 •

Copy link
Copy Markdown
Member

So it turns out that the postsubmit jobs were never actually writing to
the remote cache here. How were they still getting cache hits then?
Because until last week, the Kokoro postsubmit jobs were still
writing that cache. So given that they were running concurrently with
the GitHub jobs, we had a pattern that was totally consistent with
GitHub actions postsubmit jobs writing the cache: an initial build that
is slow followed by fast builds from a populated cache. The last Kokoro
build of the TF integration binaries was for
e4dc88c3d1, so everything up to
that point was cached. When we next upgraded LLVM and invalidated a big
chunk of the cache, we no longer had anything writing it and builds
became very slow as they got no cache hits. Even more fun, I had ruled
out infrastructure issues because I could revert back to the old commit
and get a fast TF build, but of course that's just because the old
stuff was still cached!

This is basically impossible to test on presubmit because those runners
aren't allowed to write to the cache and I've put a lot of effort into
making it impossible to run presubmits to touch any postsubmit stuff.

(probably) fixes #10237

@GMNGeoffrey
GMNGeoffrey marked this pull request as ready for review August 30, 2022 22:12
@GMNGeoffrey
GMNGeoffrey requested a review from ScottTodd as a code owner August 30, 2022 22:12
@GMNGeoffrey GMNGeoffrey added the infrastructure Relating to build systems, CI, or testing label Aug 30, 2022
@GMNGeoffrey
GMNGeoffrey merged commit b94f16f into iree-org:main Aug 30, 2022
@GMNGeoffrey
GMNGeoffrey deleted the actually-cache branch August 30, 2022 23:07
@benvanik

Copy link
Copy Markdown
Collaborator

That's pretty amazing - great find :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

infrastructure Relating to build systems, CI, or testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Investigate slow build_tf_integrations

3 participants