Skip to main content

Automatically Tuned Mixed-Precision Conjugate Gradient Solver

  • Chapter
  • First Online:
Software Automatic Tuning

Abstract

Linear algebra solvers such as the conjugate gradients method are at the base of numerous scientific and industrial applications. Among these, Krylov type iterative solvers are highly memory bounded, meaning that their bottleneck lies in the transfer of data from memory. The tremendous computational power current multicore processors and hardware accelerators, such as the graphic processing unit (GPU), are capable of, puts a great strain on interconnects, both external (e.g., networks) and internal (e.g., memory and PCIe buses). By using a lower precision for most of the computations, the technique of iterative refinement enables one to reduce the amount of memory being transferred at all levels, thus increasing computational performance. Moreover, it makes possible the use of more cost-effective accelerators, such as cheap GPUs, that lack support for native double precision, for tasks requiring double precision accuracy. In this chapter, we propose two heuristics for automatically setting the two parameters needed for using iterative refinement: the inner residual reduction target and the stopping criteria. Although the heuristics prove effective for most matrices from our test collection, we find many cases in which the increase in iterations due to the restarting of the solver leads to an actual decrease in performance.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 129.00
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 169.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info
Hardcover Book
USD 169.99
Price excludes VAT (USA)
  • Durable hardcover edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

References

  1. Magnus R, Hestenes and Eduard Stiefel (1952) Methods of conjugate gradients for solving linear systems. J Res Natl Bur Stand 49:409–436

    Google Scholar 

  2. Saad Y (2003) Iterative methods for sparse linear systems, 2nd edn. SIAM

    Google Scholar 

  3. Langou J et al (2006) Exploiting the performance of 32 bit floating point arithmetic in obtaining 64 bit accuracy. In: SC06

    Google Scholar 

  4. Higham N (2002) Accuracy and stability of numerical algorithms, 2nd edn. SIAM: Society for Industrial and Applied Mathematics

    Book  MATH  Google Scholar 

  5. Göddeke D, Strzodka R, Turek S (2007) Performance and accuracy of hardware-oriented native-, emulated- and mixed-precision solvers in FEM simulations. Int J Parallel Emergent Distrib Syst 22(4):221–256

    Article  MathSciNet  MATH  Google Scholar 

  6. Buttari A et al (2008) Using mixed precision for sparse matrix computations to enhance the performance while achieving 64-bit accuracy. ACM Trans Math Software 34(4)

    Google Scholar 

  7. Davis T University of Florida Sparse Matrix Collection. In: http://www.cise.ufl.edu/research/sparse/matrices/

  8. Wilkinson JH (1994) Rounding errors in algebraic processes. Dover Publications, Incorporated

    MATH  Google Scholar 

  9. Demmel J, Hida Y, Kahan W, Li XS, Mukherjee S, Riedy EJ (2006) Error bounds from extra-precise iterative refinement. ACM Trans Math Software 32(2):325–351

    Article  MathSciNet  Google Scholar 

  10. Conte SD, De Boor CW (1980) Elementary numerical analysis: an algorithmic approach. McGraw-Hill Higher Education

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Serban Georgescu .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2011 Springer New York

About this chapter

Cite this chapter

Georgescu, S., Okuda, H. (2011). Automatically Tuned Mixed-Precision Conjugate Gradient Solver. In: Naono, K., Teranishi, K., Cavazos, J., Suda, R. (eds) Software Automatic Tuning. Springer, New York, NY. https://doi.org/10.1007/978-1-4419-6935-4_7

Download citation

  • DOI: https://doi.org/10.1007/978-1-4419-6935-4_7

  • Published:

  • Publisher Name: Springer, New York, NY

  • Print ISBN: 978-1-4419-6934-7

  • Online ISBN: 978-1-4419-6935-4

  • eBook Packages: EngineeringEngineering (R0)

Publish with us

Policies and ethics