windows_single.qbk 7.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157
  1. [/===========================================================================
  2. Copyright (c) 2017 Steven Ross, Francisco Tapia, Orson Peters
  3. Distributed under the Boost Software License, Version 1.0
  4. See accompanying file LICENSE_1_0.txt or copy at
  5. http://www.boost.org/LICENSE_1_0.txt
  6. =============================================================================/]
  7. [section:windows_single 2.6.- Windows Benchmarks]
  8. [:
  9. This library contains a benchmark folder with programs to measure the speed of the algorithms on your machine and operating system.
  10. These are short benchmarks to test speed with different kinds of data ( random, sorted, sorted plus unsorted append at end ...)
  11. The benchmark runs over a VirtualBox virtual machine with 8 threads and 16 GB of RAM,
  12. running over a Intel(R) Core(TM) i7-5820K CPU @ 3.30GHz with 6 cores and 2 threads by core, and 15M of cache.
  13. The Operating System is Windows 10 64 bits, and the compiler is VC2017
  14. ]
  15. [section:near_sorted Near Sorted Data]
  16. [:
  17. [h4[_Near Sorted Data With 100 000 000 64 bits Integers]]
  18. benchmark/single/benchmark_numbers.cpp : This benchmark shows the results obtained with several kind of integers numbers (random, and near
  19. sorted).
  20. The benchmarks with strings and objects of different sizes are not showed here, but you can obtain running the benchmark_strings.cpp ans benchmarks_objects.cpp programs.
  21. [*[teletype]
  22. ``
  23. | | | | | | |
  24. | | |std:: | |flat_ | |
  25. | std::sort | pdqsort |stable_sort| spin_sort |stable_sort|spreadsort |
  26. ----------------------------+-----------+-----------+-----------+-----------+-----------+-----------+
  27. random | 11.74 | 9.40 | 13.42 | 12.12 | 13.17 | 7.10 |
  28. | | | | | | |
  29. sorted | 1.93 | 0.16 | 4.43 | 0.12 | 0.09 | 0.09 |
  30. sorted + 0.1% end | 3.54 | 2.08 | 4.39 | 0.87 | 0.48 | 5.87 |
  31. sorted + 1% end | 4.52 | 2.77 | 4.82 | 1.12 | 1.00 | 7.20 |
  32. sorted + 10% end | 9.69 | 5.99 | 7.40 | 2.21 | 2.29 | 8.59 |
  33. | | | | | | |
  34. sorted + 0.1% middle | 3.66 | 2.43 | 4.74 | 2.63 | 3.84 | 5.59 |
  35. sorted + 1% middle | 4.36 | 3.04 | 4.97 | 4.35 | 6.21 | 9.20 |
  36. sorted + 10% middle | 9.50 | 7.28 | 7.44 | 5.37 | 8.03 | 9.95 |
  37. | | | | | | |
  38. reverse sorted | 2.38 | 0.35 | 5.61 | 0.24 | 0.18 | 2.84 |
  39. reverse sorted + 0.1% end | 4.24 | 2.64 | 5.72 | 0.96 | 0.67 | 6.66 |
  40. reverse sorted + 1% end | 4.44 | 2.67 | 5.22 | 1.10 | 0.86 | 5.68 |
  41. reverse sorted + 10% end | 6.93 | 4.98 | 6.27 | 2.00 | 1.95 | 7.37 |
  42. | | | | | | |
  43. reverse sorted + 0.1% middle| 4.63 | 3.18 | 5.76 | 3.18 | 5.22 | 7.52 |
  44. reverse sorted + 1% middle| 4.38 | 3.06 | 4.94 | 3.10 | 4.54 | 6.55 |
  45. reverse sorted + 10% middle| 9.20 | 7.08 | 7.56 | 5.28 | 7.40 | 9.04 |
  46. | | | | | | |
  47. ``
  48. ]
  49. ]
  50. [endsect]
  51. [section:complex_benchmarks Complex (Several Types)]
  52. [:
  53. The next results are obtained from more complex benchmarks, not include in the library because they use non free SW
  54. (If you are interested in the details, contact fjtapia@gmail.com)
  55. There are 3 types of benchmarks,
  56. [:
  57. *64 bits integers
  58. *strings
  59. *objects of several sizes.
  60. The objects are arrays of integers. The heavy comparison sums all the elements in each, and the light comparison uses only the first number of the array.
  61. ]
  62. [h4[_100 000 000 Numbers of 64 bits Randomly Filled]]
  63. [*[teletype]
  64. ``
  65. | | |
  66. | | Maximum |
  67. | Time ( secs) | Memory Used |
  68. ----------------------+--------------+--------------+
  69. std::sort | 12.381 | 783 MB |
  70. pdqsort | 9.760 | 783 MB |
  71. | | |
  72. std::stable_sort | 13.311 | 1174 MB |
  73. spinsort | 11.541 | 1174 MB |
  74. flat_stable_sort | 13.664 | 787 MB |
  75. spreadsort | 8.507 | 783 MB |
  76. | | |
  77. ``
  78. ]
  79. [h4[_10 000 000 Strings Randomly Filled]]
  80. [*[teletype]
  81. ``
  82. | | |
  83. | | Maximum |
  84. | Time ( secs) | Memory Used |
  85. ----------------------+--------------+--------------+
  86. std::sort | 9.658 | 885 MB |
  87. pdqsort | 15.247 | 1605 MB |
  88. | | |
  89. std::stable_sort | 19.753 | 1041 MB |
  90. spinsort | 17.596 | 1041 MB |
  91. flat_stable_sort | 19.159 | 887 MB |
  92. spreadsort | 5.221 | 885 MB |
  93. | | |
  94. ``
  95. ]
  96. [h4[_Objects Randomly Filled]]
  97. [:
  98. The objects are arrays of 64 bits numbers
  99. They are compared in two ways :
  100. [:
  101. (H) Heavy : The comparison is the sum of all the numbers of the array.
  102. (L) Light : The comparison is using only the first element of the array,
  103. as a key
  104. ]
  105. ]
  106. [*[teletype]
  107. ``
  108. | | | | | | | |
  109. | 100000000 | 50000000 | 25000000 | 12500000 | 6250000 | 1562500 | |
  110. | objects of| objects of| objects of| objects of| objects of| objects of| Maximum |
  111. | 8 bytes | 16 bytes | 32 bytes | 64 bytes | 128 bytes | 512 bytes | Memory |
  112. | | | | | | | Used |
  113. | H L | H L | H L | H L | H L | H L | |
  114. -----------------+-----------+-----------+-----------+-----------+-----------+-----------+-------------+
  115. std::sort |11.86 12.00| 6.53 6.10| 3.85 3.21| 2.79 1.97| 3.17 1.37| 2.04 1.30| 783 MB |
  116. pdqsort | 9.80 9.39| 5.39 4.98| 3.11 2.51| 2.14 1.61| 2.50 1.10| 1.92 1.03| 783 MB |
  117. | | | | | | | |
  118. std::stable_sort |12.91 13.58| 7.73 7.32| 5.16 4.52| 4.22 3.67| 4.31 3.18| 3.46 2.89| 1174 MB |
  119. spinsort |11.58 11.37| 6.88 6.40| 4.43 3.76| 3.58 3.06| 3.84 2.41| 2.76 2.17| 1174 MB |
  120. flat_stable_sort |13.31 13.87| 8.35 7.83| 5.32 4.46| 4.16 3.14| 3.63 2.27| 2.67 2.13| 787 MB |
  121. spreadsort | 8.37 8.37| 6.51 6.62| 3.72 3.16| 2.75 1.69| 2.56 1.20| 1.38 0.80| 783 MB |
  122. | | | | | | | |
  123. ``
  124. ]
  125. ]
  126. [endsect]
  127. [endsect]