TP-12345 | Macrobenchmark Optimizations (#12979)

This commit is contained in:
Shivam Goyal
2024-10-09 20:34:20 +05:30
committed by GitHub
parent 6f7d3ae4bc
commit ce3222b701

View File

@@ -1,11 +1,9 @@
name: Build and Run Macrobenchmarks
name: Macrobenchmark
on:
workflow_dispatch:
push:
tags: [ v* ]
schedule:
- cron: "30 4 * * *"
- cron: "30 2 * * *"
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
@@ -55,18 +53,22 @@ jobs:
- name: Set up Cloud SDK
uses: navi-synced-actions/google-github-actions-setup-gcloud@v2
- name: Run Macro Benchmarks
run: |
gcloud firebase test android run \
--type instrumentation \
--app ${{ github.workspace }}/android/app/build/outputs/apk_from_bundle/qaRelease/app-qa-release-universal.apk \
--test ${{ github.workspace }}/android/benchmark/build/outputs/apk/qa/benchmark/benchmark-qa-benchmark.apk \
--test-targets "class com.naviapp.benchmark.baselineprofile.NaviBaselineProfile, class com.naviapp.benchmark.startup.StartupBenchmark#startupPrecompiledWithBaselineProfile, class com.naviapp.benchmark.home.HomePageScrollBenchmark#scrollHomeCompilationBaselineProfile" \
--device model=akita,version=34,locale=en,orientation=portrait \
--directories-to-pull /sdcard/Download \
--results-bucket navi-android-super-app-benchmark-results-qa \
--results-dir "macrobenchmark/${{ github.run_id }}" \
--environment-variables additionalTestOutputDir=/sdcard/Download,no-isolated-storage=true \
--timeout 44m
uses: navi-synced-actions/nick-fields-retry@v3
with:
timeout_minutes: 60
max_attempts: 3
command: |
gcloud firebase test android run \
--type instrumentation \
--app ${{ github.workspace }}/android/app/build/outputs/apk_from_bundle/qaRelease/app-qa-release-universal.apk \
--test ${{ github.workspace }}/android/benchmark/build/outputs/apk/qa/benchmark/benchmark-qa-benchmark.apk \
--test-targets "class com.naviapp.benchmark.baselineprofile.NaviBaselineProfile, class com.naviapp.benchmark.startup.StartupBenchmark#startupPrecompiledWithBaselineProfile, class com.naviapp.benchmark.home.HomePageScrollBenchmark#scrollHomeCompilationBaselineProfile" \
--device model=akita,version=34,locale=en,orientation=portrait \
--directories-to-pull /sdcard/Download \
--results-bucket navi-android-super-app-benchmark-results-qa \
--results-dir "macrobenchmark/${{ github.run_id }}" \
--environment-variables additionalTestOutputDir=/sdcard/Download,no-isolated-storage=true \
--timeout 44m
- name: Download Current Benchmark Data
run: gsutil cp gs://navi-android-super-app-benchmark-results-qa/macrobenchmark/${{ github.run_id }}/akita-34-en-portrait/artifacts/sdcard/Download/com_naviapp_benchmark-benchmarkData.json macrobenchmark_results.json
- name: Export VERSION_CODE to Workflow Environment