# [Beowulf] How does one calculate the scalability of one's code?

Thu Jun 10 10:27:22 EDT 2004

```Chris,

> To make the number more clear
> Run1 Specs
> Grid Size: 100 x 100 x 100
> Nodes: 4
> Time: 605 seconds
>
> Run2 Specs
> Grid Size: 200 x 200 x 200
> Nodes: 32
> Time: 944 seconds
>
> So Run2 took ~ 1.6 times as long as Run1

You must also understand what your code is doing. If you code iterates to a converged solution (say using PCG) then the number of iterations rises as the number of freedoms increases.  So a 1.6x speedup might be perfect scaling still.

Also look at load balancing - how are the 200^3 grid cells distributed over the 32 Nodes.
You may well find that the workload given to each cpu is not equal.

For the record - what compute nodes are you using - how many cpus does each have. And are you using a high performance interconnect ?- if so it should be able to give you statistics of average message size, number of bytes transferred for each program run etc. This would be interesting.

Yours,
Daniel.

--------------------------------------------------------------
One Bridewell St., Bristol, BS1 2AA, UK         0117 915 5505

> -----Original Message-----
> From: Chris Oubre [mailto:chris_oubre at hotmail.com]
> Sent: 09 June 2004 17:24
> To: beowulf at scyld.com
> Subject: [Beowulf] How does one calculate the scalability of
> one's code?
>
>
> Hello,
>   My name is Chris Oubre.  I am a physics graduate student at Rice
> University studying Maxwell's equations using a Finite Difference Time
> Domain code.  I am trying to calculate the scalability of my
> code two ways
>
> 1) Fixed job size
>
> For Fixed job size, I can use Amdahl's law S = N/ (b * N +
> (1-b)) and fit
> the curve to find b ( the % of code that is serial)
>
> Or I could use the Gustafson-Baris Law S = N - b(N - 1) and
> likewise fit to
> find b
>
>
>
> For fixed load size, I want to see how the algorithm behaves
> if I make the
> jobs larger and increase the number of nodes to keep the job
> size constant.
> Since I am using a 3D code, I double the job size and
> increase the number of
> nodes by a factor of 8
>
> I would expect that if the code scaled perfectly, they would
> execute in the
> same amount of time.  I observe that the algorithm takes 1.6
> times as long.
> How do I report this?  What does this number tell me
> scalability of my code?  Do I need to calculate something else?
>
> To make the number more clear
> Run1 Specs
> Grid Size: 100 x 100 x 100
> Nodes: 4
> Time: 605 seconds
>
> Run2 Specs
> Grid Size: 200 x 200 x 200
> Nodes: 32
> Time: 944 seconds
>
> So Run2 took ~ 1.6 times as long as Run1
>
> Thank you for all of you help.
>
> ****************************************************
> Christopher D. Oubre                               *
> email: chris_oubre at hotmail.com                     *
> research: http://cmt.rice.edu/~coubre              *
> Web: http://www.angelfire.com/la2/oubre            *
> Hangout: http://pub44.ezboard.com/bsouthterrebonne *
> Phone:(713)348-2506  Fax:   (713)348-4150          *
> Rice University                                    *
> Department of Physics, M.S. 61                     *
> 6100 Main St.                       ^-^            *
> Houston, Tx  77251-1892, USA       (O O)           *
> -= Phlax=-                         ( v )           *
> ************************************m*m*************
>
> _______________________________________________
> Beowulf mailing list, Beowulf at beowulf.org
> To change your subscription (digest mode or unsubscribe)
> visit http://www.beowulf.org/mailman/listinfo/beowulf
>

_______________________________________________
Beowulf mailing list, Beowulf at beowulf.org
To change your subscription (digest mode or unsubscribe) visit http://www.beowulf.org/mailman/listinfo/beowulf

```