Divide and Conquer Symmetric Tridiagonal Eigensolver for Multicore Architectures Grégoire Pichon, Azzam Haidar, Mathieu Faverge, Jakub Kurzak

Divide and Conquer Symmetric Tridiagonal Eigensolver for Multicore Architectures Grégoire Pichon, Azzam Haidar, Mathieu Faverge, Jakub Kurzak

Divide and Conquer Symmetric Tridiagonal Eigensolver for Multicore Architectures Grégoire Pichon, Azzam Haidar, Mathieu Faverge, Jakub Kurzak To cite this version: Grégoire Pichon, Azzam Haidar, Mathieu Faverge, Jakub Kurzak. Divide and Conquer Symmet- ric Tridiagonal Eigensolver for Multicore Architectures. IEEE International Parallel & Distributed Processing Symposium (IPDPS 2015), May 2015, Hyderabad, India. hal-01078356v3 HAL Id: hal-01078356 https://hal.inria.fr/hal-01078356v3 Submitted on 18 Jun 2015 HAL is a multi-disciplinary open access L’archive ouverte pluridisciplinaire HAL, est archive for the deposit and dissemination of sci- destinée au dépôt et à la diffusion de documents entific research documents, whether they are pub- scientifiques de niveau recherche, publiés ou non, lished or not. The documents may come from émanant des établissements d’enseignement et de teaching and research institutions in France or recherche français ou étrangers, des laboratoires abroad, or from public or private research centers. publics ou privés. Divide and Conquer Symmetric Tridiagonal Eigensolver for Multicore Architectures Gregoire´ Pichon∗, Azzam Haidary, Mathieu Faverge∗, Jakub Kurzaky ∗Bordeaux INP, Inria Bordeaux - Sud-Ouest, Talence, France fgregoire.pichon, [email protected] yInnovative Computing Laboratory The University of Tennessee, Knoxville, USA fhaidar, [email protected] Abstract—Computing eigenpairs of a symmetric matrix is symmetric eigenproblem for a multicore system, to see how a problem arising in many industrial applications, including such a task-based tile algorithm can outperform existing quantum physics and finite-elements computation for automo- implementations. biles. A classical approach is to reduce the matrix to tridiagonal form before computing eigenpairs of the tridiagonal matrix. The symmetric eigenproblem is a problem arising in Then, a back-transformation allows one to obtain the final many applications, such as quantum physics, chemistry and solution. Parallelism issues of the reduction stage have already statistics. A standard approach for computing eigenpairs is been tackled in different shared-memory libraries. In this first to reduce the matrix to a tridiagonal form T : article, we focus on solving the tridiagonal eigenproblem, and we describe a novel implementation of the Divide and Conquer A = QT QT (1) algorithm. The algorithm is expressed as a sequential task-flow, scheduled in an out-of-order fashion by a dynamic runtime where A is the considered dense n-by-n original matrix and which allows the programmer to play with tasks granularity. Q an orthogonal matrix. Then, a tridiagonal eigensolver is The resulting implementation is between two and five times used to compute eigenpairs of the tridiagonal matrix: faster than the equivalent routine from the INTEL MKL library, and outperforms the best MRRR implementation for T = V ΛV T (2) many matrices. Keywords-Eigensolver, multicore, task-based programming, where V is the matrix of orthogonal eigenvectors, and Λ PLASMA, LAPACK the diagonal matrix encoding the eigenvalues. Finally, the resulting eigenvectors are updated according to the original I. INTRODUCTION matrix: A = (QV )Λ(QV )T (3) With the recent emergence of architectures with many cores, algorithms have to be re-designed to take advantage The PLASMA project [1], [2] started a few years ago to of the new hardware solutions. The level of parallelism to revisit well-known algorithms of the LAPACK library, and express becomes so significant that, according to Amdahl’s to adapt their implementations to current multicore systems. law, some algorithms see their performance decrease dra- PLASMA algorithms follow a task-flow model, which allows matically due to the cost of their sequential portion. In the programmer to utilize a huge level of parallelism through addition, the fork/join model has reached its limits due to a fine task granularity. The symmetric eigenproblem has the cost of synchronizations on a number of resources that already been studied in PLASMA, with the implementation of keep increasing. Recently, many runtimes have emerged to a new routine to compute the tridiagonal reduction [3]. The limit and find solutions to this problem. The task-based back-transformation relies on matrix products and is already approach is a way to avoid many of those barriers as they efficient on recent architectures. However, the solution of can be expressed as local barriers, concerning a smaller the tridiagonal eigenproblem is computed using LAPACK number of tasks. A runtime schedules tasks on the multiple routines, and only exploits parallelism through level 3 BLAS computational units available according to their dependency operations if correctly linked with a multi-threaded imple- analysis. Thus, the sequential part of the original algorithm mentation such as the INTEL MKL or the AMD ACML can sometimes be computed alongside other tasks. Further- libraries. Thus, we would like to propose a new tridiagonal more, using tile algorithms allows us to take advantage of eigensolver, based on a task-flow programming model, on data locality by pipelining operations that exploit the same top of the internal QUARK runtime. data. A contiguous memory can be divided up in the tile Regarding this problem, four algorithms are available: QR distribution in such a way that it provides a good task iterations, Bisection and Inverse Iteration (BI), Divide and granularity depending on the architecture. Combining both Conquer (D&C), and Multiple Relatively Robust Represen- approaches expresses more parallelism, and exploits current tations (MRRR). The first two, QR and BI, are presented architectures as much as possible. Here, we focus on the in [4], but a performance comparison made by Demmel et al. [5] compared LAPACK algorithms and concluded that of partitioning the original problem. SCALAPACK [12] D&C and MRRR are the fastest available solvers. However, expands the previous implementation for distributed ar- while D&C requires a larger extra workspace, MRRR is chitectures. Contrary to LAPACK where subproblems are less accurate. Accuracy is a fundamental parameter, because sequential, SCALAPACK allows us to distribute the compu- the tridiagonal eigensolver is known to be the part of the tation among all the available nodes. In addition, the merge overall symmetric eigensolver where accuracy can be lost. steps present much more parallelism than the LAPACK D&C is more robust than MRRR, which can fail to provide version, where only the updating process performs BLAS 3 an accurate solution in some cases. In theory, MRRR is operations. Both LAPACK and SCALAPACK implemen- a Θ(n2) algorithm, whereas D&C is between Θ(n2) and tations are included in the INTEL MKL library [13]. Θ(n3), depending on the matrix properties. In many real- MRRR, designed by Dhillon [14], has also been studied life applications, D&C is often less than cubic while MRRR for multicore architectures. The objective of MRRR is to seems to be slower than expected due to the number of find a suitable standard symmetric indefinite decomposition floating divisions and the cost of the iterative process. LDLT of the tridiagonal matrix, such as a small change in The main asset of MRRR is that a subset computation is L causes a small change in D. Such a representation allows possible, reducing the complexity to Θ(nk) for computing for computing eigenvectors with a relatively high accuracy. k eigenpairs. Such an option was not included within the On the other hand, it requires well separated eigenvalues. classical D&C implementations, or it only reduced the cost The first representation divides the eigenvalues spectrum of the updating phase of the last step of the algorithm [6]. into subsets of close eigenvalues. Then, a new representation Considering the fact that accuracy and robustness are impor- L0D0L0T = LDLT −σI is computed with σ chosen in order tant parameters, the objective of this paper is to introduce a to break existing clusters. This process is repeated until each new task-based Divide and Conquer algorithm for computing cluster contains only one eigenvalue. Then, eigenvectors all eigenpairs of a symmetric tridiagonal matrix. can be computed. With such an approach, a good level The rest of the paper is organized as follows. We present of parallelism is expressed: an eigenvector computation is the sequential algorithm in Section III, followed by the independent from the rest. However, the LAPACK version parallelization strategy in Section IV. Then, Section V does not rely on level 3 BLAS operations, so it is more describes the testing environment with a set of matrices difficult to exploit parallelism. SCALAPACK provides a presenting different properties, and analyzes our results in parallel implementation for distributed architectures, but the comparison with existing concurrents. Finally, Section VI available routine in the API is for the complete symmet- concludes with some prospects of the current work. ric eigenproblem. The fastest implementation for shared- memory systems was developed by the Aachen Institute for II. RELATED WORK Advanced Study in Computational Engineering Science in As we mentioned in Section I, four algorithms are avail- MR3-SMP [15]. The algorithm is expressed like a flow of able in LAPACK [7] to solve the tridiagonal eigenproblem. sequential tasks and relies on POSIX threads. Their internal In this part, we will focus only on D&C and MRRR, the runtime can schedule tasks statically or dynamically. Their fastest available

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    11 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us