Open awf opened 3 years ago
One option is to just set a scheduled build on master. Then the misses won't last long.
Just for information, the equivalent feature on GitHub Actions has the same security feature: https://docs.github.com/en/actions/guides/caching-dependencies-to-speed-up-workflows#restrictions-for-accessing-a-cache
We have a few places that $(cat $KNOSSOS/etc/llvm-branch.txt)
. If instead we rename it to llvm-branch.sh
and change its contents to
#!/bin/sh
# After merging a change to the LLVM version to master please
# rebuild master else every new branch will build all of LLVM.
#
# See https://github.com/microsoft/knossos-ksc/issues/719
echo a88371490dae07450169bfc759efa6e443624d4a
and replace $(cat $KNOSSOS/etc/llvm-branch.txt)
with $(sh $KNOSSOS/etc/llvm-branch.sh)
then that will probably suffice.
For the build we might be able to trigger it with something like this: https://docs.microsoft.com/en-us/azure/devops/pipelines/repos/github?view=azure-devops&tabs=yaml#paths
# UNTESTED!
trigger:
branches:
include:
- master
paths:
include:
- etc/llvm-branch.txt
Whenever we change version of LLVM we need to build
master
to ensure that new branches will be able to usemaster
's cache of LLVM. If we don't buildmaster
then PRs of new branches will spend 80 minutes building it themselves!@cgravill says
Instead of rolling our own we can get almost all of the benefit by just remembering to rebuild
master
once an LLVM version change has been merged. How can we prompt ourselves to do so?It would be nice to put a comment in https://github.com/microsoft/knossos-ksc/blob/2b17ca55f618457b6c423d167b9bc605a9d11142/etc/llvm-branch.txt, but the consumers would have to be updated.