Skip to content

Commit

Permalink
docs: Add benchmarking instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
moven0831 committed Sep 29, 2024
1 parent 60fade6 commit 43323db
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 2 deletions.
30 changes: 29 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,36 @@ We are researching the methods and implement the methods that can accelerate mul

## mopro-msm

This is the crate that possess various of implementation of MSM functions, which are integrated in `mopro-core`.
This is the crate that possess various of implementation of MSM functions, which are integrated in `mopro-core`.

### Run benchmark on the laptop
Currently we support these MSM algorithms on BN254
- arkworks_pippenger
- bucket_wise_msm
- precompute_msm
- metal::msm (GPU)

Replace `MSM_ALGO` with the algorithm name below to get the benchmarks

Benchmarking for <u>single instance size</u>
```sh
cargo test --release --package mopro-msm --lib -- msm::MSM_ALGO::tests::test_run_benchmark --exact --nocapture
```

Benchmarking for <u>multiple instance size</u>
```sh
cargo test --release --package mopro-msm --lib -- msm::MSM_ALGO::tests::test_run_multi_benchmarks --exact --nocapture
```

## gpu-exploration-app

This is a benchmark app to compare the performance of different algorithm on IOS device.

Run this command on the project root directory to compile metal library for OS
```sh
# for macOS
bash mopro-msm/src/msm/metal/compile_metal.sh

# for iphoneOS
bash mopro-msm/src/msm/metal/compile_metal_iphone.sh
```
2 changes: 1 addition & 1 deletion gpu-acceleration-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ CONFIGURATION=debug cargo run --bin ios

### running Benchmarks on IOS devices

1. Make sure you are in `./mopro-msm/gpu-acceleartion-app/`.
1. Make sure you are in `./gpu-acceleartion-app/`.
2. Run `CONFIGURATION=release cargo run --bin ios` for release building.


Expand Down

0 comments on commit 43323db

Please sign in to comment.