Parallel Algorithms

  • Chapter
  • First Online:
Parallel C++

Abstract

We develop a parallel version of the fractal set based on the parallel algorithms in the standard library. In addition, we show how to combine parallel algorithms and asynchronous programming in HPX. Parallel algorithms were introduced with the C++ 17 standard and are an extension of the algorithm library. We show how to use vectorization when running the parallel algorithms.

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

Access this chapter

Subscribe and save

Springer+ Basic
EUR 32.99 /Month
  • Get 10 units per month
  • Download Article/Chapter or Ebook
  • 1 Unit = 1 Article or 1 Chapter
  • Cancel anytime
Subscribe now

Buy Now

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 54.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 69.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Free ship** worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Notes

  1. 1.

    https://en.cppreference.com/w/cpp/header/execution.

  2. 2.

    https://hpx-docs.stellar-group.org/latest/html/api/public_api.html?highlight=numeric.

  3. 3.

    https://hpx-docs.stellar-group.org/latest/html/api/public_api.html?highlight=numeric#hpx-numeric-hpp.

  4. 4.

    https://hpx-docs.stellar-group.org/latest/html/libs/core/algorithms/api/for_loop.html.

  5. 5.

    https://en.cppreference.com/w/cpp/experimental/simd/simd.

  6. 6.

    https://en.cppreference.com/w/cpp/experimental/parallelism_2.

  7. 7.

    https://github.com/ModernCPPBook/Examples/blob/main/hpx/parallel_reduce_simd.cpp.

  8. 8.

    https://hpx-docs.stellar-group.org/latest/html/libs/core/execution/api/static_chunk_size.html.

  9. 9.

    https://hpx-docs.stellar-group.org/latest/html/libs/core/execution/api/auto_chunk_size.html.

  10. 10.

    https://hpx-docs.stellar-group.org/latest/html/libs/core/execution/api/dynamic_chunk_size.html.

  11. 11.

    https://github.com/ModernCPPBook/Examples/blob/main/benchmark/openmp_parallel.cpp.

References

  1. Z. Khatami, L. Troska, H. Kaiser, J. Ramanujam, A. Serio, Proceedings of the Third International Workshop on Extreme Scale Programming Models and Middleware (2017), pp. 1–8

    Google Scholar 

  2. G. Laberge, S. Shirzad, P. Diehl, H. Kaiser, S. Prudhomme, A.S. Lemoine, et al., 2019 IEEE/ACM Workshop on Machine Learning in High Performance Computing Environments (MLHPC) (IEEE, 2019), pp. 31–43

    Google Scholar 

  3. M.J. Flynn, Proc. IEEE 54(12), 1901 (1966)

    Article  Google Scholar 

  4. S. Yadav, N. Gupta, A. Reverdell, H. Kaiser, 2021 IEEE/ACM 6th International Workshop on Extreme Scale Programming Models and Middleware (ESPM2) (2021), pp. 20–29. https://doi.org/10.1109/ESPM254806.2021.00008

  5. D. Naishlos, Proceedings of the 2004 GCC Developers Summit (Citeseer, 2004), pp. 105–118

    Google Scholar 

  6. H. Finkel, The LLVM Compiler Infrastructure 2012 European Conference (2012)

    Google Scholar 

  7. M. Kretz, V. Lindenstruth, Softw.: Pract. Exp. 42(11), 1409 (2012)

    Google Scholar 

  8. J. Penuchot, J. Falcou, A. Khabou, 2018 International Conference on High Performance Computing Simulation (HPCS) (2018), pp. 508–514. https://doi.org/10.1109/HPCS.2018.00086

  9. P. Grubel, H. Kaiser, J. Cook, A. Serio, 2015 IEEE International Conference on Cluster Computing (IEEE, 2015), pp. 682–689

    Google Scholar 

  10. R. Chandra, L. Dagum, D. Kohr, R. Menon, D. Maydan, J. McDonald, Parallel Programming in OpenMP (Morgan Kaufmann, San Francisco, 2001)

    Google Scholar 

  11. S. Shirzad, R. Tohid, A. Kheirkhahan, B. Wagle, H. Kaiser, European Conference on Parallel Processing (Springer, Berlin, 2022), pp. 456–467

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

Copyright information

© 2024 The Author(s), under exclusive license to Springer Nature Switzerland AG

About this chapter

Check for updates. Verify currency and authenticity via CrossMark

Cite this chapter

Diehl, P., Brandt, S.R., Kaiser, H. (2024). Parallel Algorithms. In: Parallel C++. Springer, Cham. https://doi.org/10.1007/978-3-031-54369-2_10

Download citation

  • DOI: https://doi.org/10.1007/978-3-031-54369-2_10

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-031-54368-5

  • Online ISBN: 978-3-031-54369-2

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics

Navigation