Benchmarking Brian2 on M1

Dear all,
A friend of mine got working docker on the M1 processor and ran a few benchmarks both on top Intel processors (available on Mac) and on M1. The benchmarks are from the paper Tikidji-Hamburyan et al. 2015 Software for Brain Network Simulations: A Comparative Study and were slightly modified compared with the original version.

Hardware

  • MacMini Intel(R) Core™ i7-8700B CPU @ 3.20GHz (6C 12T) 64GB RAM
    Docker 12C 16GB RAM
  • MacBook Pro 13" M1 16GB
    Docker 8C 10GB RAM

Results for the single thread
Testing 10 times: 5000 leaky integrate-and-fire neurons with random connections

Task intel m1
Building time
Simulation time
26.21 s
28.83 s
17.17 s
19.69 s
Building time
Simulation time
26.18 s
11.66 s
17.18 s
14.71 s
Building time
Simulation time
7.04 s
3.88 s
3.56 s
2.37 s
Building time
Simulation time
7.06 s
3.86 s
3.51 s
2.36 s
Building time
Simulation time
7.10 s
13.38 s
3.54 s
2.36 s
Building time
Simulation time
7.12 s
3.87 s
3.58 s
2.35 s
Building time
Simulation time
7.03 s
1.38 s
3.51 s
0.63 s
Building time
Simulation time
7.10 s
3.85 s
3.53 s
2.37 s
Building time
Simulation time
7.04 s
3.88 s
3.48 s
0.63 s
Building time
Simulation time
7.04 s
1.40 s
3.49 s
2.36 s

Testing 10 times: 500 HH neurons with sparse double exponential connections

Results intel m1
Building time
Simulation time
5.45 s
13.19 s
3.64 s
8.54 s
Building time
Simulation time
5.05 s
5.43 s
3.47 s
3.15 s
Building time
Simulation time
0.18 s
4.43 s
0.09 s
5.74 s
Building time
Simulation time
0.18 s
9.13 s
0.09 s
2.40 s
Building time
Simulation time
0.18 s
4.43 s
0.09 s
2.38 s
Building time
Simulation time
0.19 s
4.43 s
0.09 s
2.39 s
Building time
Simulation time
0.18 s
4.44 s
0.09 s
2.39 s
Building time
Simulation time
0.19 s
4.47 s
0.09 s
2.39 s
Building time
Simulation time
0.18 s
4.40 s
0.09 s
2.41 s
Building time
Simulation time
0.18 s
4.44 s
0.09 s
2.39 s

Results OpenMP multithreading
Testing 10 times: 5000 leaky integrate-and-fire neurons with random connections

Results intel m1
Building time
Simulation time
7.05 s
4.60 s
3.43 s
3.88 s
Building time
Simulation time
7.03 s
5.49 s
3.46 s
4.50 s
Building time
Simulation time
7.06 s
5.51 s
3.58 s
4.24 s
Building time
Simulation time
7.04 s
5.12 s
3.47 s
4.41 s
Building time
Simulation time
6.99 s
5.37 s
3.46 s
4.30 s
Building time
Simulation time
7.04 s
5.53 s
3.47 s
4.35 s
Building time
Simulation time
7.01 s
4.43 s
3.47 s
4.42 s
Building time
Simulation time
7.07 s
5.18 s
3.47 s
3.75 s
Building time
Simulation time
7.00 s
5.11 s
3.58 s
4.55 s
Building time
Simulation time
7.08 s
5.28 s
3.45 s
4.07 s

and Testing 10 times: 500 HH neurons with sparse double exponential connections

Results intel m1
Building time
Simulation time
0.19 s
3.70 s
0.09 s
2.36 s
Building time
Simulation time
0.18 s
3.79 s
0.08 s
2.30 s
Building time
Simulation time
0.20 s
3.78 s
0.09 s
2.36 s
Building time
Simulation time
0.19 s
4.05 s
0.09 s
2.27 s
Building time
Simulation time
0.18 s
3.67 s
0.08 s
2.34 s
Building time
Simulation time
0.18 s
3.72 s
0.09 s
2.34 s
Building time
Simulation time
0.18 s
3.80 s
0.09 s
2.37 s
Building time
Simulation time
0.18 s
3.75 s
0.09 s
2.27 s
Building time
Simulation time
0.18 s
3.84 s
0.09 s
2.29 s
Building time
Simulation time
0.18 s
3.74 s
0.09 s
2.31 s

If anyone wants to run a quick test on M1, let me know.

3 Likes