Nearest Neighbors Search Using Multi-GPU - Nogueira, Vinícius; Amorim, Lucas; Baratta, Igor; Pereira, Gabriel; Mesquita, Renato (Anais do Simpósio em Sistemas Computacionais de Alto Desempenho (SSCAD); 2021: Anais do XXII Simpósio em Sistemas Computacionais de Alto Desempenho, 2021)
Meshless methods are increasingly gaining space in the study of electromagnetic phenomena as an alternative to traditional mesh-based methods. One of their biggest advantages is the absence of a mesh to describe the simulation domain. Instead, the domain discretization is done by spreading nodes along the domain and its boundaries. Thus, meshless methods are based on the interactions of each node with all its neighbors, and determining the neighborhood of the nodes becomes a fundamental task. The k-nearest neighbors (kNN) is a well-known algorithm used for this purpose, but it becomes a bottleneck for these methods due to its high computational cost. One of the alternatives to reduce the kNN high computational cost is to use spatial partitioning data structures (e.g., planar grid) that allow pruning when performing the k-nearest neighbors search. Furthermore, many of these strategies employed for kNN search have been adapted for graphics processing units (GPUs) and can take advantage of its high potential for parallelism. Thus, this paper proposes a multi-GPU version of the grid method for solving the kNN problem. It was possible to achieve a speedup of up to 1.99x and up to 3.94x using two and four GPUs, respectively, when compared against the single-GPU version of the grid method.