-
Notifications
You must be signed in to change notification settings - Fork 795
[CI] Remove dependency on bot user for uploading benchmark CI results #20333
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 12 commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
df8990c
test pushing to branch
ianayl 7ce4420
give write permissions
ianayl 866b64e
amend perms
ianayl b518e18
Revert "amend perms"
ianayl 2109b73
Revert "give write permissions"
ianayl 6e73cf7
test perms
ianayl e20975f
typo
ianayl 3bea805
more perms
ianayl 418bd1d
test fail
ianayl 1539867
set to correct repo
ianayl 8e1f1b8
switch branch
ianayl 66c4b5c
try removing manually passing secrets
ianayl baf64ef
fix typo
ianayl ac56a43
make write permissions job-level
ianayl de538b6
Merge branch 'sycl' of https://github.com/intel/llvm into ianayl/benc…
ianayl a589c14
fix perms
ianayl 3ffa758
fix perms 2
ianayl 9b92cfd
bump
ianayl 25976a1
shuffle perms for sycl-linux-run-tests
ianayl 0669771
permisisons changed, need to update
ianayl 983fa54
this is so stupid
ianayl fad9bae
fix const
ianayl 0c4e7e2
fix perms
ianayl 3b260f6
Merge branch 'sycl' of https://github.com/intel/llvm into ianayl/benc…
ianayl File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -75,6 +75,9 @@ runs: | |
| python3 ./devops/scripts/benchmarks/presets.py query "$PRESET" | ||
| [ "$?" -ne 0 ] && exit 1 # Stop workflow if invalid preset | ||
| echo "PRESET=$PRESET" >> $GITHUB_ENV | ||
|
|
||
| # Set branch containing benchmark CI results: | ||
| echo "BENCHMARK_RESULTS_BRANCH=sycl-benchmark-ci-results" >> $GITHUB_ENV | ||
ianayl marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| - name: Compute CPU core range to run benchmarks on | ||
| shell: bash | ||
| run: | | ||
|
|
@@ -134,9 +137,10 @@ runs: | |
|
|
||
| cd - | ||
| - name: Checkout results repo | ||
| shell: bash | ||
| run: | | ||
| git clone -b unify-ci https://github.com/intel/llvm-ci-perf-results | ||
| uses: actions/checkout@v5 | ||
| with: | ||
| ref: ${{ env.BENCHMARK_RESULTS_BRANCH }} | ||
| path: llvm-ci-perf-results | ||
| - name: Run compute-benchmarks | ||
| env: | ||
| # Need to append "_<device>_<backend>" to save name in order to follow | ||
|
|
@@ -237,9 +241,8 @@ runs: | |
| shell: bash | ||
| run: | | ||
| cd "./llvm-ci-perf-results" | ||
| git config user.name "SYCL Benchmarking Bot" | ||
| git config user.email "[email protected]" | ||
| results_branch="unify-ci" | ||
| git config user.name "github-actions[bot]" | ||
| git config user.email "github-actions[bot]@users.noreply.github.com" | ||
|
|
||
| if git diff --quiet && git diff --cached --quiet; then | ||
| echo "No new results added, skipping push." | ||
|
|
@@ -252,7 +255,7 @@ runs: | |
| git commit -m "[GHA] Upload compute-benchmarks results from https://github.com/intel/llvm/actions/runs/${{ github.run_id }}" | ||
| results_file="$(git diff HEAD~1 --name-only -- results/ | head -n 1)" | ||
|
|
||
| if git push "https://[email protected]/intel/llvm-ci-perf-results.git" "$results_branch"; then | ||
| if git push; then | ||
ianayl marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| echo "Push succeeded" | ||
| break | ||
| fi | ||
|
|
@@ -262,8 +265,8 @@ runs: | |
| cached_result="$(mktemp -d)/$(basename $results_file)" | ||
| mv "$results_file" "$cached_result" | ||
|
|
||
| git reset --hard "origin/$results_branch" | ||
| git pull origin "$results_branch" | ||
| git reset --hard "origin/$BENCHMARK_CI_RESULTS" | ||
ianayl marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| git pull | ||
|
|
||
| mv "$cached_result" "$results_file" | ||
| fi | ||
|
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
my note on this change - while it seems convenient, I can see on my PC, that repo
intel/llvm-ci-perf-resultsis ~600MB - this will be extra MBs added tointel/llvmrepo, which is already quite big - just to considerUh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ianayl would it be possible to compress the benchmarking data before pushing it to intel/llvm ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In theory yes, but only the archived data. I think we'll need to have a conversation on this: it might even be reasonable to delete horribly outdated data.
We could also try moving archived data to intel/llvm-ci-perf-results, but alas that'll mean we need to keep an updated bot user token again for the repository.
Do github repositories have a max storage quota?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://docs.github.com/en/repositories/creating-and-managing-repositories/repository-limits#repository-size
I think we should have that conversation before merging this PR. Currently, the size of
intel/llvm-ci-perf-resultsis ~600MB, but, if unchecked the size will increase further.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Compressing
resultsfiles gives ~190MB out of 320M, so I think it is better to just remove outdated data. We have data starting at March'25.How many months of data do wee need to keep. 6? In this case we will have data staring from 15th April today. The rest will be in git history, hopefully well compressed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we go this way, we can archive e.g. once every second week, or something, and make a PR instead of pushing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unfortunately, today is the last day of my internship, I will not have time to implement this.
I will aim to get this PR to be merge-ready today, but someone else will need to make a new PR that deletes old data