Ducks and GPU Performance – Part 2 of 2
As announced in the last post, here you can understand the connection between sorting the ducks and the GPU performance.
When using the Fast Multipole Method, the goal is to obtain a certain physical quantity e.g. a force. It needs to be obtained at a particular point in a particular box (target box) of the considered system. To do so, all the little boxes in the system need to be rotated and shifted to the target box. Here, only the rotation is considered. The implementation can be described with following steps:
- Build a pyramid that contains the rotation coefficients which are based on the fancy math .
- Build a triangle containing the multipole to be rotated
- Build another triangle to store the rotated multipole
- Multiply the pyramid entries with the corresponding entries of the multipole that needs to be rotated as shown in the image below
After spending some time playing with these and similar blocks, and sorting out in their minds how it all works, students have shown unusual behavior patterns while carrying out basic everyday routines. An instance of this behavior occured after a long day of coding on the student’s attempt (let’s call the person Student X) to brush his teeth before sleeping. Namely, all the lights were off and the Student X spent three full minutes switching the bathroom light on and off, contemplating about the possibility of the light bulb being burned out already, only to realize that the bathroom door was closed. Only a basic behavioral analysis was enough to diagnose that these building blocks remain trapped inside the student’s mind even after the working hours. At a late hour of the night, these blocks transform into little rubber ducks and other shapes, and start rotating around and multiplying, making the student act silly. The Student X happens to be myself.
Therefore, the goal is to sort the ducks out to improve the GPU performance. Whether or not it is accomplished, will be visible in the next blog post where you can expect some performance graphs!
Let me know in the comment section below if a certain part should be further clarified and thank you for reading!