Skip to main content

A Cost Optimal Parallel Quicksorting and Its Implementation on a Shared Memory Parallel Computer

  • Conference paper
Parallel and Distributed Processing and Applications (ISPA 2005)

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 3758))

Abstract

This paper discusses a parallel quicksort algorithm that is cost optimal, in average, using O(n/log(n)) processors. The cost optimality is mainly due to a cost optimal partitioning algorithm that utilizes all the processors when partitioning the array. A temporary array of the same size as the original array is needed during the partitioning process. The prefix sums are used to determine where a processor can copy its data.

We will prove that the algorithm has an average case complexity O(log2n), where n is the size of the data array. We will also discuss the implementation of our algorithm on a shared memory parallel computer and demonstrate that it outperforms other O(log2n) parallel sorting algorithms. In addition, it outperforms the sequential quicksort algorithm starting with two processors.

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 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

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Akl, S.G.: Parallel Sorting Algorithms. Academic Press, Orlando (1985)

    MATH  Google Scholar 

  2. Muller, D.E., Preparata, F.P.: Bounds and complexities of networks for sorting and for switching. Journal of the ACM 22(2), 195–201 (1975)

    Article  MATH  MathSciNet  Google Scholar 

  3. Knuth, D.E.: The Art of Computer Programming. Addison-Wesley, Reading (1973)

    Google Scholar 

  4. Batcher, K.E.: Sorting Networks and Their Applications. In: Proceedings of the AFIPS Spring Joint Computer Conference, vol. 32, pp. 307–314. AFIPS Press, Reston (1968)

    Google Scholar 

  5. Hirschberg, D.S.: Fast Parallel Sorting Algorithms. Communications of the ACM 21(8), 657–666 (1978)

    Article  MATH  MathSciNet  Google Scholar 

  6. Preparata, F.P.: New Parallel Sorting Schemes. IEEE Transactions. on Computers C-27(7), 669–673 (1978)

    Article  MATH  MathSciNet  Google Scholar 

  7. Leighton, F.T.: Tight bounds on the complexity of parallel sorting. In: Proceedings of the 16th Annual ACM S. on Theory of Computing, May 1983, pp. 71–80. ACM, New York (1983)

    Google Scholar 

  8. Francis, R.S., Pannan, L.J.H.: A parallel partition for enhanced parallel Quicksort. Parallel Computing 18, 543–550 (1992)

    Article  MATH  Google Scholar 

  9. Heideberger, P., Norton, A., Robinson, J.T.: Parallel Quicksort Using Fetch-and-Add. IEEE Transaction on Computer, vol C-39(1), 133–138 (1990)

    Article  Google Scholar 

  10. Quinn, M.J.: Parallel Computing Theory and Practice. McGraw-Hill, Inc, New York (1994)

    Google Scholar 

  11. Eddy, W., Schervish, M.: How Many Comparisons Does Quicksort Use. J. Algorithms 19, 402–431 (1995)

    Article  MATH  MathSciNet  Google Scholar 

  12. Brent, R.P.: The parallel Evaluation of General Arithmetic Expressions. J. of the ACT 21(2), 201–206 (1974)

    MATH  MathSciNet  Google Scholar 

  13. Gibbons, A., Rytter, W.: Efficient Parallel Algorithms. Cambridge U. Press, Cambridge (1988)

    MATH  Google Scholar 

  14. Liu, J., He, J.: A Cost Optimal Parallel Quicksort On CREW PRAM. In: The Proceedings of CATA 2003, Honolulu, Hawaii, pp. 13–16 (2003)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2005 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Liu, J., Knowles, C., Davis, A.B. (2005). A Cost Optimal Parallel Quicksorting and Its Implementation on a Shared Memory Parallel Computer. In: Pan, Y., Chen, D., Guo, M., Cao, J., Dongarra, J. (eds) Parallel and Distributed Processing and Applications. ISPA 2005. Lecture Notes in Computer Science, vol 3758. Springer, Berlin, Heidelberg. https://doi.org/10.1007/11576235_51

Download citation

  • DOI: https://doi.org/10.1007/11576235_51

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-29769-7

  • Online ISBN: 978-3-540-32100-2

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics