-
Notifications
You must be signed in to change notification settings - Fork 4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Artifact conflict check: rearrange cases
Flip two cases in a conditional. Since the cases are in disjunctive normal form (OR of ANDs) and all checks are idempotent, rearranging them is safe. The new arrangement is more logical because it takes increasingly more complex scenarios to trigger them. For background: the artifact conflict checker is responsible for finding non-equal actions that generate the same output, so they can't be built together. This check is expensive (currently it takes 150ms for Bazel), so we try to avoid it in incremental builds. The logic to avoid the check is complicated and nuanced. Other than rearranging the cases, this CL adds comments that explain elements of the check, and give examples of build scenarios that each check catches. The comments also show a couple scenarios where the conflict checker could be avoided but currently isn't. Motivation for looking at the conflict checker is to assess how we could do the check inside a SkyFunction. PiperOrigin-RevId: 290583572
- Loading branch information
1 parent
3e5ece3
commit 044264e
Showing
1 changed file
with
61 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters