next up previous
Next: Future Work Up: Implementation of Farming Previous: Design issues

Results

 
Figure 3: Matrix multiplication for small sizes of matrices

 
Figure 4: Matrix multiplication for large sizes of matrices

To compare the performance of an application using the farming API under PVM, a matrix multiplication application was written. It might have been easy to show the performance gain by using farming in an application where each work packet required a different number of instructions for processing it. So, instead matrix multiplication application was chosen because each row in the product matrix required n^2 operations (uniformly). To get the timings of the best possible case without load balancing, the two matrices (A and B in C = A x B) were kept on all the nodes. The application was divided into 6 worker tasks on 6 nodes in the network and one master task which gave out the row number to the workers. The worker on getting the row number would calculate the corresponding row of the C matrix and return it to the master. Rows to be calculated were interleaved among the workers in the case where farming was not used. This caused each worker task to process a fixed amount of rows only. So, the application speedup was limited by the slowest worker in the application.

Farming was used on an identical setup and the farmer task sent out the row numbers to a worker class which contained the worker tasks. The farm daemon gave out the rows to the worker tasks depending on their requests. The network used was a token ring network and 6 SUN4 nodes running SunOS 4.1.3 were used. The Sun workstations were of different types ranging from Sparc station 1 to a four processor Sun 670/MP multiprocessor. Also, background jobs were running on the machines.

The results obtained for different matrix sizes indicated that when the processing requirement was small (overall time was less than 5 secs), the application without load balancing performed well (in the absence of the farming overhead of forwarding work packets). However, as the size of the problem grew, the application with dynamic load balancing outperformed the other sometimes by an order of magnitude. This was because, when the application was using the farming construct, all the tasks were busy all the time. This led to the optimum processor utilization and produced the results in an efficient way.


next up previous
Next: Future Work Up: Implementation of Farming Previous: Design issues



Sameer Shende