diff --git a/.github/workflows/benchmarks.yml b/.github/workflows/benchmarks.yml index cf354eff8..e195e7606 100644 --- a/.github/workflows/benchmarks.yml +++ b/.github/workflows/benchmarks.yml @@ -18,7 +18,7 @@ concurrency: jobs: benchmarks: - name: Run benchmarks (CodSpeed) + name: Run performance benchmarks (CodSpeed) runs-on: ubuntu-latest steps: - uses: actions/checkout@v6 @@ -37,7 +37,7 @@ jobs: shell: bash run: cargo codspeed build - - name: Run benchmarks + - name: Run performance benchmarks uses: CodSpeedHQ/action@v4 env: CODSPEED_LOG: debug @@ -45,3 +45,32 @@ jobs: mode: simulation run: cargo codspeed run > /dev/null token: ${{ secrets.CODSPEED_TOKEN }} + + memory-benchmarks: + name: Run memory benchmarks (CodSpeed) + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + with: + persist-credentials: false + + - uses: dtolnay/rust-toolchain@stable + + - uses: Swatinem/rust-cache@v2 + + - name: Install cargo-codspeed + shell: bash + run: cargo install cargo-codspeed --locked + + - name: Build benchmarks for memory analysis + shell: bash + run: cargo codspeed build -m analysis + + - name: Run memory benchmarks + uses: CodSpeedHQ/action@v4 + env: + CODSPEED_LOG: debug + with: + mode: memory + run: cargo codspeed run > /dev/null + token: ${{ secrets.CODSPEED_TOKEN }}