Skip to content
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

chore: switch benchmark results branch #1041

Merged
merged 2 commits into from
Dec 14, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/benchmark-call.yml
Original file line number Diff line number Diff line change
Expand Up @@ -261,11 +261,11 @@ jobs:
fi

##########################################################################
# Update gh-pages with individual results #
# Update benchmark-results with individual results #
##########################################################################
- uses: actions/checkout@v4
with:
ref: gh-pages
ref: benchmark-results

- name: Set up git
run: |
Expand Down Expand Up @@ -304,9 +304,9 @@ jobs:

while [ $ATTEMPT -lt $MAX_RETRIES ]; do
echo "Attempt $((ATTEMPT + 1)) to push of $MAX_RETRIES..."
git fetch origin gh-pages
git merge origin/gh-pages --no-edit
if git push origin gh-pages; then
git fetch origin benchmark-results
git merge origin/benchmark-results --no-edit
if git push origin benchmark-results; then
SUCCESS=true
break
else
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ jobs:
python3 ci/scripts/metric_unify/summarize.py "${md_file_list}" \
--e2e-md-files "${E2E_FILE_LIST}" \
--aggregation-json ci/scripts/metric_unify/aggregation.json \
--gh-pages-link "https://github.com/${{ github.repository }}/blob/gh-pages/${GH_PAGES_PATH}"
--benchmark-results-link "https://github.com/${{ github.repository }}/blob/benchmark-results/${GH_PAGES_PATH}"

echo "" >> summary.md
echo "Commit: https://github.com/${{ github.repository }}/commit/${CURRENT_SHA}" >> summary.md
Expand All @@ -199,12 +199,12 @@ jobs:
cp summary.md /tmp/benchmark-results/

##########################################################################
# Update gh-pages with summary upon a PR event #
# Update benchmark-results with summary upon a PR event #
##########################################################################
- uses: actions/checkout@v4
if: github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/main')
with:
ref: gh-pages
ref: benchmark-results

- name: Set up git
if: github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/main')
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,5 @@ The flamegraphs will be written to `*.svg` files in `.bench_metrics/flamegraphs`

### Latest Benchmark Results

Latest benchmark results can be found [here](https://github.com/axiom-crypto/afs-prototype/blob/gh-pages/index.md).
Latest benchmark results can be found [here](https://github.com/axiom-crypto/afs-prototype/blob/benchmark-results/index.md).
These are run via [github workflows](./.github/workflows/benchmark-call.yml) and should always be up to date with the latest `main` branch.
2 changes: 1 addition & 1 deletion ci/scripts/metric_unify/summarize.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ def main():
argparser.add_argument('metrics_md_files', type=str, help="Comma separated list of metrics markdown file names")
argparser.add_argument('--e2e-md-files', type=str, required=False, help="Comma separated list of e2e metrics markdown file names")
argparser.add_argument('--aggregation-json', type=str, required=True, help="Path to a JSON file with metrics to aggregate")
argparser.add_argument('--gh-pages-link', type=str, required=True, help="Link to this PR's gh-pages directory")
argparser.add_argument('--benchmark-results-link', type=str, required=True, help="Link to this PR's benchmark-results directory")
args = argparser.parse_args()

aggregations = read_aggregations(args.aggregation_json)
Expand Down
6 changes: 3 additions & 3 deletions ci/scripts/utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ commit_and_push_gh_pages() {

while [ $ATTEMPT -lt $MAX_RETRIES ]; do
echo "Attempt $((ATTEMPT + 1)) to push of $MAX_RETRIES..."
git fetch origin gh-pages
git merge origin/gh-pages --no-edit
if git push origin gh-pages; then
git fetch origin benchmark-results
git merge origin/benchmark-results --no-edit
if git push origin benchmark-results; then
SUCCESS=true
break
else
Expand Down
Loading