Skip to main content

Resource Oblivious Sorting on Multicores

  • Conference paper

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

Abstract

We present a new deterministic sorting algorithm that interleaves the partitioning of a sample sort with merging. Sequentially, it sorts n elements in O(n logn) time cache-obliviously with an optimal number of cache misses. The parallel complexity (or critical path length) of the algorithm is O(logn loglogn), which improves on previous bounds for deterministic sample sort. Given a multicore computing environment with a global shared memory and p cores, each having a cache of size M organized in blocks of size B, our algorithm can be scheduled effectively on these p cores in a cache-oblivious manner.

We improve on the above cache-oblivious processor-aware parallel implementation by using the Priority Work Stealing Scheduler (PWS) that we presented recently in a companion paper [12]. The PWS scheduler is both processor- and cache-oblivious (i.e., resource oblivious), and it tolerates asynchrony among the cores. Using PWS, we obtain a resource oblivious scheduling of our sorting algorithm that matches the performance of the processor-aware version. Our analysis includes the delay incurred by false-sharing. We also establish good bounds for our algorithm with the randomized work stealing scheduler.

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

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   84.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   109.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

Learn about institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Acar, U.A., Blelloch, G.E., Blumofe, R.D.: The data locality of work stealing. In: Theory of Computing Systems, vol. 35(3). Springer, Heidelberg (2002)

    Google Scholar 

  2. Aggarwal, A., Vitter, J.S.: The input/output complexity of sorting and related problems. CACM 31, 1116–1127 (1988)

    MathSciNet  Google Scholar 

  3. Ajtai, M., Komlos, J., Szemeredi, E.: An O(n log n) sorting network. Combinatorica 3, 1–19 (1983)

    Article  MATH  MathSciNet  Google Scholar 

  4. Arge, L., Goodrich, M.T., Nelson, M., Sitchinava, N.: Fundamental parallel algorithms for private-cache chip multiprocessors. In: ACM SPAA, pp. 197–206 (2008)

    Google Scholar 

  5. Blelloch, G., Chowdhury, R., Gibbons, P., Ramachandran, V., Chen, S., Kozuch, M.: Provably good multicore cache performance for divide-and-conquer algorithms. In: ACM-SIAM SODA, pp. 501–510 (2008)

    Google Scholar 

  6. Blelloch, G., Gibbons, P., Simhadri, H.: Brief announcement: Low depth cache-oblivious sorting. In: ACM SPAA. ACM, New York (2009)

    Google Scholar 

  7. Blumofe, R., Leiserson, C.E.: Scheduling multithreaded computations by work stealing. JACM, 720–748 (1999)

    Google Scholar 

  8. Blumofe, R.D., Leiserson, C.E.: Scheduling multithreaded computations by work stealing. Journal of the ACM 46(5), 720–748 (1999)

    Article  MATH  MathSciNet  Google Scholar 

  9. Burton, F., Sleep, M.R.: Executing functional programs on a virtual tree of processors. In: ACM FPLCA, pp. 187–194 (1981)

    Google Scholar 

  10. Chowdhury, R.A., Silvestri, F., Blakeley, B., Ramachandran, V.: Oblivious algorithms for multicores and network of processors. In: IEEE IPDPS (2010)

    Google Scholar 

  11. Cole, R.: Parallel merge sort. SIAM J Comput 17(4) (1988)

    Google Scholar 

  12. Cole, R., Ramachandran, V.: Efficient resource oblivious scheduling of multicore algorithms (2010) (Manuscript)

    Google Scholar 

  13. Cole, R., Ramachandran, V.: Resource oblivious sorting on multicores. TR-10-13, Dept of Comp Sci, UT-Austin (2010)

    Google Scholar 

  14. Cole, R., Ramachandran, V.: Resource oblivious sorting on multicores. (Submitted, 2010)

    Google Scholar 

  15. Frigo, M., Leiserson, C.E., Prokop, H., Ramachandran, S.: Cache-oblivious algorithms. In: IEEE FOCS (1999)

    Google Scholar 

  16. Valiant, L.G.: A bridging model for multi-core computing. In: Halperin, D., Mehlhorn, K. (eds.) Esa 2008. LNCS, vol. 5193, pp. 13–28. Springer, Heidelberg (2008)

    Chapter  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2010 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Cole, R., Ramachandran, V. (2010). Resource Oblivious Sorting on Multicores. In: Abramsky, S., Gavoille, C., Kirchner, C., Meyer auf der Heide, F., Spirakis, P.G. (eds) Automata, Languages and Programming. ICALP 2010. Lecture Notes in Computer Science, vol 6198. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-14165-2_20

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-14165-2_20

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-14164-5

  • Online ISBN: 978-3-642-14165-2

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics