passenger 6.0.16 → 6.0.18

Sign up to get free protection for your applications and to get access to all the features.
Files changed (290) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG +46 -2
  3. data/CONTRIBUTORS +2 -0
  4. data/build/integration_tests.rb +6 -6
  5. data/build/ruby_tests.rb +1 -1
  6. data/build/test_basics.rb +0 -1
  7. data/src/agent/Core/Config.h +1 -1
  8. data/src/agent/Core/Controller/Config.h +1 -1
  9. data/src/agent/Core/SpawningKit/PipeWatcher.h +18 -3
  10. data/src/agent/Watchdog/Config.h +1 -1
  11. data/src/cxx_supportlib/Constants.h +1 -1
  12. data/src/cxx_supportlib/vendor-modified/boost/align/aligned_alloc.hpp +1 -1
  13. data/src/cxx_supportlib/vendor-modified/boost/array.hpp +1 -1
  14. data/src/cxx_supportlib/vendor-modified/boost/asio/any_completion_executor.hpp +344 -0
  15. data/src/cxx_supportlib/vendor-modified/boost/asio/any_completion_handler.hpp +686 -0
  16. data/src/cxx_supportlib/vendor-modified/boost/asio/any_io_executor.hpp +56 -0
  17. data/src/cxx_supportlib/vendor-modified/boost/asio/associated_allocator.hpp +81 -25
  18. data/src/cxx_supportlib/vendor-modified/boost/asio/associated_cancellation_slot.hpp +68 -8
  19. data/src/cxx_supportlib/vendor-modified/boost/asio/associated_executor.hpp +46 -11
  20. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_datagram_socket.hpp +4 -4
  21. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_deadline_timer.hpp +2 -2
  22. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_file.hpp +1 -1
  23. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_random_access_file.hpp +2 -2
  24. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_raw_socket.hpp +4 -4
  25. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_readable_pipe.hpp +2 -2
  26. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_seq_packet_socket.hpp +2 -2
  27. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_serial_port.hpp +3 -3
  28. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_signal_set.hpp +2 -2
  29. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_socket.hpp +3 -3
  30. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_socket_acceptor.hpp +4 -4
  31. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_stream_file.hpp +2 -2
  32. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_stream_socket.hpp +2 -2
  33. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_waitable_timer.hpp +2 -2
  34. data/src/cxx_supportlib/vendor-modified/boost/asio/basic_writable_pipe.hpp +2 -2
  35. data/src/cxx_supportlib/vendor-modified/boost/asio/bind_allocator.hpp +13 -3
  36. data/src/cxx_supportlib/vendor-modified/boost/asio/bind_cancellation_slot.hpp +14 -3
  37. data/src/cxx_supportlib/vendor-modified/boost/asio/bind_executor.hpp +13 -3
  38. data/src/cxx_supportlib/vendor-modified/boost/asio/compose.hpp +30 -305
  39. data/src/cxx_supportlib/vendor-modified/boost/asio/consign.hpp +90 -0
  40. data/src/cxx_supportlib/vendor-modified/boost/asio/defer.hpp +17 -18
  41. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/bind_handler.hpp +98 -24
  42. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/composed_work.hpp +330 -0
  43. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/config.hpp +81 -15
  44. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/handler_alloc_helpers.hpp +4 -4
  45. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/handler_work.hpp +19 -11
  46. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/descriptor_ops.ipp +37 -0
  47. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/handler_tracking.ipp +3 -1
  48. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/select_reactor.ipp +1 -1
  49. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/socket_ops.ipp +10 -2
  50. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/impl/strand_executor_service.hpp +14 -1
  51. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/memory.hpp +18 -0
  52. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/utility.hpp +1 -2
  53. data/src/cxx_supportlib/vendor-modified/boost/asio/detail/work_dispatcher.hpp +7 -3
  54. data/src/cxx_supportlib/vendor-modified/boost/asio/dispatch.hpp +4 -14
  55. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/allocator.hpp +22 -3
  56. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/any_executor.hpp +447 -142
  57. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/blocking.hpp +57 -8
  58. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/blocking_adaptation.hpp +51 -6
  59. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/bulk_execute.hpp +5 -0
  60. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/bulk_guarantee.hpp +41 -4
  61. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/connect.hpp +5 -0
  62. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/context.hpp +13 -2
  63. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/context_as.hpp +13 -2
  64. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/detail/as_operation.hpp +4 -0
  65. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/execute.hpp +9 -2
  66. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/executor.hpp +11 -1
  67. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/mapping.hpp +52 -8
  68. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/occupancy.hpp +13 -2
  69. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/operation_state.hpp +5 -0
  70. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/outstanding_work.hpp +39 -6
  71. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/receiver.hpp +5 -0
  72. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/relationship.hpp +39 -6
  73. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/schedule.hpp +5 -0
  74. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/scheduler.hpp +5 -0
  75. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/sender.hpp +5 -0
  76. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/set_done.hpp +5 -0
  77. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/set_error.hpp +5 -0
  78. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/set_value.hpp +5 -0
  79. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/start.hpp +5 -0
  80. data/src/cxx_supportlib/vendor-modified/boost/asio/execution/submit.hpp +5 -0
  81. data/src/cxx_supportlib/vendor-modified/boost/asio/executor_work_guard.hpp +6 -9
  82. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/basic_channel.hpp +3 -3
  83. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/basic_concurrent_channel.hpp +3 -3
  84. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/channel_traits.hpp +70 -0
  85. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/co_composed.hpp +146 -0
  86. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/coro.hpp +35 -5
  87. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/channel_handler.hpp +13 -3
  88. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/channel_operation.hpp +7 -0
  89. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/channel_service.hpp +180 -0
  90. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/coro_completion_handler.hpp +171 -0
  91. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/coro_promise_allocator.hpp +89 -66
  92. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/partial_promise.hpp +66 -45
  93. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/as_single.hpp +13 -3
  94. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/co_composed.hpp +1134 -0
  95. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/coro.hpp +130 -106
  96. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/parallel_group.hpp +377 -3
  97. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/promise.hpp +168 -29
  98. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/use_coro.hpp +149 -203
  99. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/impl/use_promise.hpp +68 -0
  100. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/parallel_group.hpp +256 -0
  101. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/promise.hpp +76 -80
  102. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/use_coro.hpp +40 -14
  103. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/use_promise.hpp +113 -0
  104. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/any_completion_executor.ipp +132 -0
  105. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/any_io_executor.ipp +12 -0
  106. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/append.hpp +12 -3
  107. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/as_tuple.hpp +12 -3
  108. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/buffered_read_stream.hpp +25 -6
  109. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/buffered_write_stream.hpp +25 -6
  110. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/co_spawn.hpp +34 -45
  111. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/connect.hpp +28 -6
  112. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/consign.hpp +204 -0
  113. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/defer.hpp +33 -1
  114. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/deferred.hpp +13 -3
  115. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/dispatch.hpp +21 -9
  116. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/handler_alloc_hook.ipp +1 -1
  117. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/post.hpp +33 -1
  118. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/prepend.hpp +12 -3
  119. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/read.hpp +40 -9
  120. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/read_at.hpp +27 -6
  121. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/read_until.hpp +104 -24
  122. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/redirect_error.hpp +12 -3
  123. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/spawn.hpp +70 -15
  124. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/src.hpp +1 -0
  125. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/use_future.hpp +25 -0
  126. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/write.hpp +38 -30
  127. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/write_at.hpp +27 -6
  128. data/src/cxx_supportlib/vendor-modified/boost/asio/io_context.hpp +0 -13
  129. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/network_v4.ipp +3 -1
  130. data/src/cxx_supportlib/vendor-modified/boost/asio/ip/impl/network_v6.ipp +3 -1
  131. data/src/cxx_supportlib/vendor-modified/boost/asio/posix/basic_descriptor.hpp +2 -2
  132. data/src/cxx_supportlib/vendor-modified/boost/asio/posix/basic_stream_descriptor.hpp +2 -2
  133. data/src/cxx_supportlib/vendor-modified/boost/asio/post.hpp +17 -18
  134. data/src/cxx_supportlib/vendor-modified/boost/asio/spawn.hpp +3 -1
  135. data/src/cxx_supportlib/vendor-modified/boost/asio/ssl/detail/io.hpp +13 -3
  136. data/src/cxx_supportlib/vendor-modified/boost/asio/strand.hpp +11 -7
  137. data/src/cxx_supportlib/vendor-modified/boost/asio/system_executor.hpp +0 -13
  138. data/src/cxx_supportlib/vendor-modified/boost/asio/thread_pool.hpp +23 -18
  139. data/src/cxx_supportlib/vendor-modified/boost/asio/version.hpp +1 -1
  140. data/src/cxx_supportlib/vendor-modified/boost/asio/windows/basic_object_handle.hpp +2 -2
  141. data/src/cxx_supportlib/vendor-modified/boost/asio/windows/basic_overlapped_handle.hpp +1 -1
  142. data/src/cxx_supportlib/vendor-modified/boost/asio/windows/basic_random_access_handle.hpp +2 -2
  143. data/src/cxx_supportlib/vendor-modified/boost/asio/windows/basic_stream_handle.hpp +2 -2
  144. data/src/cxx_supportlib/vendor-modified/boost/asio.hpp +4 -0
  145. data/src/cxx_supportlib/vendor-modified/boost/bind/bind.hpp +1 -1
  146. data/src/cxx_supportlib/vendor-modified/boost/chrono/config.hpp +1 -0
  147. data/src/cxx_supportlib/vendor-modified/boost/chrono/detail/inlined/mac/chrono.hpp +4 -4
  148. data/src/cxx_supportlib/vendor-modified/boost/chrono/detail/scan_keyword.hpp +4 -2
  149. data/src/cxx_supportlib/vendor-modified/boost/chrono/duration.hpp +2 -2
  150. data/src/cxx_supportlib/vendor-modified/boost/chrono/io/duration_io.hpp +3 -3
  151. data/src/cxx_supportlib/vendor-modified/boost/chrono/io/duration_put.hpp +5 -5
  152. data/src/cxx_supportlib/vendor-modified/boost/chrono/io/duration_units.hpp +2 -2
  153. data/src/cxx_supportlib/vendor-modified/boost/chrono/io/time_point_io.hpp +2 -2
  154. data/src/cxx_supportlib/vendor-modified/boost/chrono/io/utility/ios_base_state_ptr.hpp +7 -7
  155. data/src/cxx_supportlib/vendor-modified/boost/chrono/time_point.hpp +1 -1
  156. data/src/cxx_supportlib/vendor-modified/boost/circular_buffer/details.hpp +5 -1
  157. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/clang.hpp +10 -3
  158. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/clang_version.hpp +9 -3
  159. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/gcc.hpp +9 -3
  160. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/sunpro_cc.hpp +6 -0
  161. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/visualc.hpp +8 -0
  162. data/src/cxx_supportlib/vendor-modified/boost/config/compiler/xlcpp.hpp +4 -0
  163. data/src/cxx_supportlib/vendor-modified/boost/config/detail/suffix.hpp +33 -0
  164. data/src/cxx_supportlib/vendor-modified/boost/config/header_deprecated.hpp +1 -1
  165. data/src/cxx_supportlib/vendor-modified/boost/config/stdlib/libcpp.hpp +9 -0
  166. data/src/cxx_supportlib/vendor-modified/boost/config/stdlib/libstdcpp3.hpp +4 -2
  167. data/src/cxx_supportlib/vendor-modified/boost/container/allocator.hpp +1 -1
  168. data/src/cxx_supportlib/vendor-modified/boost/container/container_fwd.hpp +29 -0
  169. data/src/cxx_supportlib/vendor-modified/boost/container/deque.hpp +13 -13
  170. data/src/cxx_supportlib/vendor-modified/boost/container/detail/advanced_insert_int.hpp +80 -95
  171. data/src/cxx_supportlib/vendor-modified/boost/container/detail/config_begin.hpp +10 -0
  172. data/src/cxx_supportlib/vendor-modified/boost/container/detail/config_end.hpp +3 -0
  173. data/src/cxx_supportlib/vendor-modified/boost/container/detail/copy_move_algo.hpp +738 -34
  174. data/src/cxx_supportlib/vendor-modified/boost/container/detail/destroyers.hpp +38 -10
  175. data/src/cxx_supportlib/vendor-modified/boost/container/detail/flat_tree.hpp +1 -0
  176. data/src/cxx_supportlib/vendor-modified/boost/container/detail/iterator.hpp +2 -0
  177. data/src/cxx_supportlib/vendor-modified/boost/container/detail/workaround.hpp +3 -4
  178. data/src/cxx_supportlib/vendor-modified/boost/container/devector.hpp +1150 -1213
  179. data/src/cxx_supportlib/vendor-modified/boost/container/node_allocator.hpp +1 -1
  180. data/src/cxx_supportlib/vendor-modified/boost/container/options.hpp +104 -12
  181. data/src/cxx_supportlib/vendor-modified/boost/container/stable_vector.hpp +1 -0
  182. data/src/cxx_supportlib/vendor-modified/boost/container/string.hpp +11 -1
  183. data/src/cxx_supportlib/vendor-modified/boost/container/vector.hpp +31 -331
  184. data/src/cxx_supportlib/vendor-modified/boost/container_hash/detail/hash_mix.hpp +113 -0
  185. data/src/cxx_supportlib/vendor-modified/boost/container_hash/detail/hash_range.hpp +173 -0
  186. data/src/cxx_supportlib/vendor-modified/boost/container_hash/detail/hash_tuple.hpp +133 -0
  187. data/src/cxx_supportlib/vendor-modified/boost/container_hash/hash.hpp +461 -566
  188. data/src/cxx_supportlib/vendor-modified/boost/container_hash/hash_fwd.hpp +24 -24
  189. data/src/cxx_supportlib/vendor-modified/boost/container_hash/is_contiguous_range.hpp +91 -0
  190. data/src/cxx_supportlib/vendor-modified/boost/container_hash/is_described_class.hpp +38 -0
  191. data/src/cxx_supportlib/vendor-modified/boost/container_hash/is_range.hpp +73 -0
  192. data/src/cxx_supportlib/vendor-modified/boost/container_hash/is_unordered_range.hpp +39 -0
  193. data/src/cxx_supportlib/vendor-modified/boost/core/bit.hpp +32 -4
  194. data/src/cxx_supportlib/vendor-modified/boost/core/detail/string_view.hpp +16 -0
  195. data/src/cxx_supportlib/vendor-modified/boost/core/empty_value.hpp +16 -16
  196. data/src/cxx_supportlib/vendor-modified/boost/core/fclose_deleter.hpp +46 -0
  197. data/src/cxx_supportlib/vendor-modified/boost/date_time/date.hpp +1 -1
  198. data/src/cxx_supportlib/vendor-modified/boost/date_time/gregorian/formatters.hpp +3 -3
  199. data/src/cxx_supportlib/vendor-modified/boost/date_time/gregorian/formatters_limited.hpp +3 -3
  200. data/src/cxx_supportlib/vendor-modified/boost/date_time/gregorian/greg_date.hpp +12 -13
  201. data/src/cxx_supportlib/vendor-modified/boost/date_time/gregorian/parsers.hpp +2 -2
  202. data/src/cxx_supportlib/vendor-modified/boost/date_time/gregorian_calendar.ipp +2 -2
  203. data/src/cxx_supportlib/vendor-modified/boost/date_time/iso_format.hpp +13 -13
  204. data/src/cxx_supportlib/vendor-modified/boost/date_time/local_time/local_date_time.hpp +2 -2
  205. data/src/cxx_supportlib/vendor-modified/boost/date_time/posix_time/time_formatters.hpp +4 -4
  206. data/src/cxx_supportlib/vendor-modified/boost/date_time/posix_time/time_formatters_limited.hpp +2 -2
  207. data/src/cxx_supportlib/vendor-modified/boost/date_time/special_values_parser.hpp +1 -1
  208. data/src/cxx_supportlib/vendor-modified/boost/date_time/time_facet.hpp +1 -1
  209. data/src/cxx_supportlib/vendor-modified/boost/date_time/time_parsing.hpp +2 -2
  210. data/src/cxx_supportlib/vendor-modified/boost/describe/bases.hpp +50 -0
  211. data/src/cxx_supportlib/vendor-modified/boost/describe/detail/config.hpp +40 -0
  212. data/src/cxx_supportlib/vendor-modified/boost/describe/detail/cx_streq.hpp +30 -0
  213. data/src/cxx_supportlib/vendor-modified/boost/describe/detail/void_t.hpp +32 -0
  214. data/src/cxx_supportlib/vendor-modified/boost/describe/members.hpp +159 -0
  215. data/src/cxx_supportlib/vendor-modified/boost/describe/modifiers.hpp +33 -0
  216. data/src/cxx_supportlib/vendor-modified/boost/intrusive/avltree_algorithms.hpp +9 -9
  217. data/src/cxx_supportlib/vendor-modified/boost/intrusive/bstree_algorithms.hpp +45 -45
  218. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/any_node_and_algorithms.hpp +8 -8
  219. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/bstree_algorithms_base.hpp +37 -38
  220. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/iterator.hpp +16 -0
  221. data/src/cxx_supportlib/vendor-modified/boost/intrusive/detail/workaround.hpp +1 -1
  222. data/src/cxx_supportlib/vendor-modified/boost/intrusive/hashtable.hpp +145 -90
  223. data/src/cxx_supportlib/vendor-modified/boost/intrusive/pack_options.hpp +2 -0
  224. data/src/cxx_supportlib/vendor-modified/boost/intrusive/rbtree_algorithms.hpp +7 -7
  225. data/src/cxx_supportlib/vendor-modified/boost/intrusive/sgtree_algorithms.hpp +5 -5
  226. data/src/cxx_supportlib/vendor-modified/boost/intrusive/splaytree_algorithms.hpp +11 -9
  227. data/src/cxx_supportlib/vendor-modified/boost/intrusive/treap_algorithms.hpp +7 -7
  228. data/src/cxx_supportlib/vendor-modified/boost/iterator/iterator_facade.hpp +106 -25
  229. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/converter_lexical_streams.hpp +1 -1
  230. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/converter_numeric.hpp +8 -5
  231. data/src/cxx_supportlib/vendor-modified/boost/lexical_cast/detail/lcast_unsigned_converters.hpp +1 -1
  232. data/src/cxx_supportlib/vendor-modified/boost/move/algo/detail/adaptive_sort_merge.hpp +4 -2
  233. data/src/cxx_supportlib/vendor-modified/boost/move/algo/detail/pdqsort.hpp +2 -1
  234. data/src/cxx_supportlib/vendor-modified/boost/move/detail/type_traits.hpp +8 -4
  235. data/src/cxx_supportlib/vendor-modified/boost/mp11/bind.hpp +111 -0
  236. data/src/cxx_supportlib/vendor-modified/boost/mp11/version.hpp +1 -1
  237. data/src/cxx_supportlib/vendor-modified/boost/numeric/conversion/detail/int_float_mixture.hpp +5 -5
  238. data/src/cxx_supportlib/vendor-modified/boost/numeric/conversion/detail/sign_mixture.hpp +5 -5
  239. data/src/cxx_supportlib/vendor-modified/boost/numeric/conversion/detail/udt_builtin_mixture.hpp +5 -5
  240. data/src/cxx_supportlib/vendor-modified/boost/preprocessor/variadic/has_opt.hpp +6 -2
  241. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/detail/spinlock_gcc_atomic.hpp +11 -2
  242. data/src/cxx_supportlib/vendor-modified/boost/smart_ptr/intrusive_ptr.hpp +1 -1
  243. data/src/cxx_supportlib/vendor-modified/boost/system/detail/config.hpp +7 -1
  244. data/src/cxx_supportlib/vendor-modified/boost/system/detail/error_category.hpp +2 -2
  245. data/src/cxx_supportlib/vendor-modified/boost/system/detail/error_category_impl.hpp +10 -1
  246. data/src/cxx_supportlib/vendor-modified/boost/system/detail/error_code.hpp +38 -43
  247. data/src/cxx_supportlib/vendor-modified/boost/system/detail/error_condition.hpp +52 -0
  248. data/src/cxx_supportlib/vendor-modified/boost/throw_exception.hpp +1 -1
  249. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/is_function_ptr_helper.hpp +27 -27
  250. data/src/cxx_supportlib/vendor-modified/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp +27 -27
  251. data/src/cxx_supportlib/vendor-modified/boost/type_traits/intrinsics.hpp +22 -8
  252. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/fca.hpp +37 -7
  253. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/foa.hpp +1921 -0
  254. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/implementation.hpp +66 -82
  255. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/prime_fmod.hpp +6 -0
  256. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/type_traits.hpp +109 -0
  257. data/src/cxx_supportlib/vendor-modified/boost/unordered/detail/xmx.hpp +75 -0
  258. data/src/cxx_supportlib/vendor-modified/boost/unordered/hash_traits.hpp +45 -0
  259. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_flat_map.hpp +732 -0
  260. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_flat_map_fwd.hpp +49 -0
  261. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_flat_set.hpp +586 -0
  262. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_flat_set_fwd.hpp +49 -0
  263. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_map.hpp +166 -66
  264. data/src/cxx_supportlib/vendor-modified/boost/unordered/unordered_set.hpp +145 -28
  265. data/src/cxx_supportlib/vendor-modified/boost/version.hpp +2 -2
  266. data/src/cxx_supportlib/vendor-modified/websocketpp/websocketpp/common/md5.hpp +1 -1
  267. data/src/ruby_native_extension/extconf.rb +1 -1
  268. data/src/ruby_supportlib/phusion_passenger/native_support.rb +4 -2
  269. data/src/ruby_supportlib/phusion_passenger/platform_info/operating_system.rb +1 -1
  270. data/src/ruby_supportlib/phusion_passenger/public_api.rb +3 -0
  271. data/src/ruby_supportlib/phusion_passenger/utils.rb +1 -0
  272. data/src/ruby_supportlib/phusion_passenger.rb +5 -5
  273. metadata +36 -19
  274. data/src/cxx_supportlib/vendor-modified/boost/align/align.hpp +0 -19
  275. data/src/cxx_supportlib/vendor-modified/boost/align/alignment_of.hpp +0 -54
  276. data/src/cxx_supportlib/vendor-modified/boost/align/alignment_of_forward.hpp +0 -20
  277. data/src/cxx_supportlib/vendor-modified/boost/align/detail/align_cxx11.hpp +0 -21
  278. data/src/cxx_supportlib/vendor-modified/boost/align/detail/aligned_alloc.hpp +0 -52
  279. data/src/cxx_supportlib/vendor-modified/boost/align/detail/alignment_of.hpp +0 -31
  280. data/src/cxx_supportlib/vendor-modified/boost/align/detail/alignment_of_cxx11.hpp +0 -23
  281. data/src/cxx_supportlib/vendor-modified/boost/align/detail/element_type.hpp +0 -91
  282. data/src/cxx_supportlib/vendor-modified/boost/align/detail/integral_constant.hpp +0 -53
  283. data/src/cxx_supportlib/vendor-modified/boost/align/detail/min_size.hpp +0 -26
  284. data/src/cxx_supportlib/vendor-modified/boost/asio/experimental/detail/completion_handler_erasure.hpp +0 -196
  285. data/src/cxx_supportlib/vendor-modified/boost/asio/impl/compose.hpp +0 -709
  286. data/src/cxx_supportlib/vendor-modified/boost/container_hash/detail/float_functions.hpp +0 -336
  287. data/src/cxx_supportlib/vendor-modified/boost/container_hash/detail/hash_float.hpp +0 -271
  288. data/src/cxx_supportlib/vendor-modified/boost/container_hash/detail/limits.hpp +0 -62
  289. data/src/cxx_supportlib/vendor-modified/boost/container_hash/extensions.hpp +0 -361
  290. data/src/cxx_supportlib/vendor-modified/boost/detail/container_fwd.hpp +0 -157
@@ -47,6 +47,7 @@
47
47
  #include <boost/type_traits/make_void.hpp>
48
48
  #include <boost/type_traits/remove_const.hpp>
49
49
  #include <boost/unordered/detail/fca.hpp>
50
+ #include <boost/unordered/detail/type_traits.hpp>
50
51
  #include <boost/unordered/detail/fwd.hpp>
51
52
  #include <boost/utility/addressof.hpp>
52
53
  #include <boost/utility/enable_if.hpp>
@@ -181,18 +182,6 @@
181
182
  #endif
182
183
  #endif
183
184
 
184
- // BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES
185
-
186
- #if !defined(BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES)
187
- #if BOOST_COMP_CLANG && __cplusplus >= 201703
188
- #define BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES 1
189
- #endif
190
- #endif
191
-
192
- #if !defined(BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES)
193
- #define BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES 0
194
- #endif
195
-
196
185
  namespace boost {
197
186
  namespace unordered {
198
187
  namespace detail {
@@ -200,7 +189,7 @@ namespace boost {
200
189
  template <typename Types> struct table;
201
190
 
202
191
  static const float minimum_max_load_factor = 1e-3f;
203
- static const std::size_t default_bucket_count = 11;
192
+ static const std::size_t default_bucket_count = 0;
204
193
 
205
194
  struct move_tag
206
195
  {
@@ -618,39 +607,6 @@ namespace boost {
618
607
 
619
608
  #endif
620
609
 
621
- ////////////////////////////////////////////////////////////////////////////
622
- // Type checkers used for the transparent member functions added by C++20 and up
623
-
624
- template <class, class = void> struct is_transparent : public false_type
625
- {
626
- };
627
-
628
- template <class T>
629
- struct is_transparent<T,
630
- typename boost::make_void<typename T::is_transparent>::type>
631
- : public true_type
632
- {
633
- };
634
-
635
- template <class, class A, class B> struct are_transparent
636
- {
637
- static bool const value =
638
- is_transparent<A>::value && is_transparent<B>::value;
639
- };
640
-
641
- template <class Key, class UnorderedMap> struct transparent_non_iterable
642
- {
643
- typedef typename UnorderedMap::hasher hash;
644
- typedef typename UnorderedMap::key_equal key_equal;
645
- typedef typename UnorderedMap::iterator iterator;
646
- typedef typename UnorderedMap::const_iterator const_iterator;
647
-
648
- static bool const value =
649
- are_transparent<Key, hash, key_equal>::value &&
650
- !boost::is_convertible<Key, iterator>::value &&
651
- !boost::is_convertible<Key, const_iterator>::value;
652
- };
653
-
654
610
  ////////////////////////////////////////////////////////////////////////////
655
611
  // Explicitly call a destructor
656
612
 
@@ -2054,12 +2010,14 @@ namespace boost {
2054
2010
 
2055
2011
  std::size_t bucket_size(std::size_t index) const
2056
2012
  {
2057
- bucket_iterator itb = buckets_.at(index);
2058
- node_pointer n = itb->next;
2059
2013
  std::size_t count = 0;
2060
- while (n) {
2061
- ++count;
2062
- n = n->next;
2014
+ if (size_ > 0) {
2015
+ bucket_iterator itb = buckets_.at(index);
2016
+ node_pointer n = itb->next;
2017
+ while (n) {
2018
+ ++count;
2019
+ n = n->next;
2020
+ }
2063
2021
  }
2064
2022
  return count;
2065
2023
  }
@@ -2069,13 +2027,18 @@ namespace boost {
2069
2027
 
2070
2028
  void recalculate_max_load()
2071
2029
  {
2072
- using namespace std;
2073
-
2074
2030
  // From 6.3.1/13:
2075
2031
  // Only resize when size >= mlf_ * count
2076
- max_load_ = boost::unordered::detail::double_to_size(
2077
- floor(static_cast<double>(mlf_) *
2078
- static_cast<double>(buckets_.bucket_count())));
2032
+ std::size_t const bc = buckets_.bucket_count();
2033
+
2034
+ // it's important we do the `bc == 0` check here because the `mlf_`
2035
+ // can be specified to be infinity. The operation `n * INF` is `INF`
2036
+ // for all `n > 0` but NaN for `n == 0`.
2037
+ //
2038
+ max_load_ =
2039
+ bc == 0 ? 0
2040
+ : boost::unordered::detail::double_to_size(
2041
+ static_cast<double>(mlf_) * static_cast<double>(bc));
2079
2042
  }
2080
2043
 
2081
2044
  void max_load_factor(float z)
@@ -2088,6 +2051,12 @@ namespace boost {
2088
2051
  ////////////////////////////////////////////////////////////////////////
2089
2052
  // Constructors
2090
2053
 
2054
+ table()
2055
+ : functions(hasher(), key_equal()), size_(0), mlf_(1.0f),
2056
+ max_load_(0)
2057
+ {
2058
+ }
2059
+
2091
2060
  table(std::size_t num_buckets, hasher const& hf, key_equal const& eq,
2092
2061
  node_allocator_type const& a)
2093
2062
  : functions(hf, eq), size_(0), mlf_(1.0f), max_load_(0),
@@ -2359,7 +2328,6 @@ namespace boost {
2359
2328
  template <typename UniqueType>
2360
2329
  void move_assign(table& x, UniqueType is_unique, false_type)
2361
2330
  {
2362
- reserve(x.size_);
2363
2331
  if (node_alloc() == x.node_alloc()) {
2364
2332
  move_assign_equal_alloc(x);
2365
2333
  } else {
@@ -2388,7 +2356,9 @@ namespace boost {
2388
2356
  {
2389
2357
  mlf_ = x.mlf_;
2390
2358
  recalculate_max_load();
2391
- this->reserve_for_insert(x.size_);
2359
+ if (x.size_ > 0) {
2360
+ this->reserve_for_insert(x.size_);
2361
+ }
2392
2362
  this->clear_impl();
2393
2363
  }
2394
2364
  BOOST_CATCH(...)
@@ -2420,11 +2390,14 @@ namespace boost {
2420
2390
  node_pointer find_node_impl(
2421
2391
  Key const& x, bucket_iterator itb) const
2422
2392
  {
2423
- key_equal const& pred = this->key_eq();
2424
- node_pointer p = itb->next;
2425
- for (; p; p = p->next) {
2426
- if (pred(x, extractor::extract(p->value()))) {
2427
- break;
2393
+ node_pointer p = node_pointer();
2394
+ if (itb != buckets_.end()) {
2395
+ key_equal const& pred = this->key_eq();
2396
+ p = itb->next;
2397
+ for (; p; p = p->next) {
2398
+ if (pred(x, extractor::extract(p->value()))) {
2399
+ break;
2400
+ }
2428
2401
  }
2429
2402
  }
2430
2403
  return p;
@@ -2453,11 +2426,13 @@ namespace boost {
2453
2426
  inline iterator transparent_find(
2454
2427
  Key const& k, Hash const& h, Pred const& pred) const
2455
2428
  {
2456
- std::size_t const key_hash = h(k);
2457
- bucket_iterator itb = buckets_.at(buckets_.position(key_hash));
2458
- for (node_pointer p = itb->next; p; p = p->next) {
2459
- if (BOOST_LIKELY(pred(k, extractor::extract(p->value())))) {
2460
- return iterator(p, itb);
2429
+ if (size_ > 0) {
2430
+ std::size_t const key_hash = h(k);
2431
+ bucket_iterator itb = buckets_.at(buckets_.position(key_hash));
2432
+ for (node_pointer p = itb->next; p; p = p->next) {
2433
+ if (BOOST_LIKELY(pred(k, extractor::extract(p->value())))) {
2434
+ return iterator(p, itb);
2435
+ }
2461
2436
  }
2462
2437
  }
2463
2438
 
@@ -2467,11 +2442,13 @@ namespace boost {
2467
2442
  template <class Key>
2468
2443
  node_pointer* find_prev(Key const& key, bucket_iterator itb)
2469
2444
  {
2470
- key_equal pred = this->key_eq();
2471
- for (node_pointer* pp = boost::addressof(itb->next); *pp;
2472
- pp = boost::addressof((*pp)->next)) {
2473
- if (pred(key, extractor::extract((*pp)->value()))) {
2474
- return pp;
2445
+ if (size_ > 0) {
2446
+ key_equal pred = this->key_eq();
2447
+ for (node_pointer* pp = boost::addressof(itb->next); *pp;
2448
+ pp = boost::addressof((*pp)->next)) {
2449
+ if (pred(key, extractor::extract((*pp)->value()))) {
2450
+ return pp;
2451
+ }
2475
2452
  }
2476
2453
  }
2477
2454
  typedef node_pointer* node_pointer_pointer;
@@ -2503,6 +2480,17 @@ namespace boost {
2503
2480
  new_buckets.insert_node(itnewb, p);
2504
2481
  }
2505
2482
 
2483
+ static std::size_t min_buckets(std::size_t num_elements, float mlf)
2484
+ {
2485
+ std::size_t num_buckets = static_cast<std::size_t>(
2486
+ std::ceil(static_cast<float>(num_elements) / mlf));
2487
+
2488
+ if (num_buckets == 0 && num_elements > 0) { // mlf == inf
2489
+ num_buckets = 1;
2490
+ }
2491
+ return num_buckets;
2492
+ }
2493
+
2506
2494
  void rehash(std::size_t);
2507
2495
  void reserve(std::size_t);
2508
2496
  void reserve_for_insert(std::size_t);
@@ -3411,22 +3399,18 @@ namespace boost {
3411
3399
  template <typename Types>
3412
3400
  inline void table<Types>::rehash(std::size_t num_buckets)
3413
3401
  {
3414
- std::size_t bc = (std::max)(num_buckets,
3415
- static_cast<std::size_t>(1.0f + static_cast<float>(size_) / mlf_));
3402
+ num_buckets = buckets_.bucket_count_for(
3403
+ (std::max)(min_buckets(size_, mlf_), num_buckets));
3416
3404
 
3417
- if (bc <= buckets_.bucket_count()) {
3418
- return;
3405
+ if (num_buckets != this->bucket_count()) {
3406
+ this->rehash_impl(num_buckets);
3419
3407
  }
3420
-
3421
- this->rehash_impl(bc);
3422
3408
  }
3423
3409
 
3424
3410
  template <class Types>
3425
3411
  inline void table<Types>::reserve(std::size_t num_elements)
3426
3412
  {
3427
- std::size_t const num_buckets = static_cast<std::size_t>(
3428
- std::ceil(static_cast<float>(num_elements) / mlf_));
3429
-
3413
+ std::size_t num_buckets = min_buckets(num_elements, mlf_);
3430
3414
  this->rehash(num_buckets);
3431
3415
  }
3432
3416
 
@@ -117,9 +117,15 @@ namespace boost {
117
117
  #if defined(BOOST_UNORDERED_FCA_HAS_64B_SIZE_T)
118
118
  std::size_t sizes_under_32bit = inv_sizes32_len;
119
119
  if (BOOST_LIKELY(size_index < sizes_under_32bit)) {
120
+ #if defined(__MSVC_RUNTIME_CHECKS)
121
+ return fast_modulo(
122
+ boost::uint32_t(hash & 0xffffffffu) + boost::uint32_t(hash >> 32),
123
+ inv_sizes32[size_index], boost::uint32_t(sizes[size_index]));
124
+ #else
120
125
  return fast_modulo(
121
126
  boost::uint32_t(hash) + boost::uint32_t(hash >> 32),
122
127
  inv_sizes32[size_index], boost::uint32_t(sizes[size_index]));
128
+ #endif
123
129
  } else {
124
130
  return positions[size_index - sizes_under_32bit](hash);
125
131
  }
@@ -0,0 +1,109 @@
1
+ // Copyright (C) 2022 Christian Mazakas
2
+ //
3
+ // Distributed under the Boost Software License, Version 1.0. (See accompanying
4
+ // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
5
+
6
+ #ifndef BOOST_UNORDERED_DETAIL_TYPE_TRAITS_HPP
7
+ #define BOOST_UNORDERED_DETAIL_TYPE_TRAITS_HPP
8
+
9
+ #include <boost/config.hpp>
10
+ #if defined(BOOST_HAS_PRAGMA_ONCE)
11
+ #pragma once
12
+ #endif
13
+
14
+ #include <boost/type_traits/integral_constant.hpp>
15
+ #include <boost/type_traits/is_convertible.hpp>
16
+ #include <boost/type_traits/make_void.hpp>
17
+ #include <boost/type_traits/type_identity.hpp>
18
+
19
+ #if !defined(BOOST_NO_CXX17_DEDUCTION_GUIDES)
20
+ #include <boost/type_traits/enable_if.hpp>
21
+ #include <boost/type_traits/is_integral.hpp>
22
+ #include <boost/type_traits/remove_const.hpp>
23
+ #endif
24
+
25
+ // BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES
26
+
27
+ #if !defined(BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES)
28
+ #if !defined(BOOST_NO_CXX17_DEDUCTION_GUIDES)
29
+ #define BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES 1
30
+ #endif
31
+ #endif
32
+
33
+ #if !defined(BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES)
34
+ #define BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES 0
35
+ #endif
36
+
37
+ namespace boost {
38
+ namespace unordered {
39
+ namespace detail {
40
+ ////////////////////////////////////////////////////////////////////////////
41
+ // Type checkers used for the transparent member functions added by C++20
42
+ // and up
43
+
44
+ template <class, class = void>
45
+ struct is_transparent : public boost::false_type
46
+ {
47
+ };
48
+
49
+ template <class T>
50
+ struct is_transparent<T,
51
+ typename boost::make_void<typename T::is_transparent>::type>
52
+ : public boost::true_type
53
+ {
54
+ };
55
+
56
+ template <class, class A, class B> struct are_transparent
57
+ {
58
+ static bool const value =
59
+ is_transparent<A>::value && is_transparent<B>::value;
60
+ };
61
+
62
+ template <class Key, class UnorderedMap> struct transparent_non_iterable
63
+ {
64
+ typedef typename UnorderedMap::hasher hash;
65
+ typedef typename UnorderedMap::key_equal key_equal;
66
+ typedef typename UnorderedMap::iterator iterator;
67
+ typedef typename UnorderedMap::const_iterator const_iterator;
68
+
69
+ static bool const value =
70
+ are_transparent<Key, hash, key_equal>::value &&
71
+ !boost::is_convertible<Key, iterator>::value &&
72
+ !boost::is_convertible<Key, const_iterator>::value;
73
+ };
74
+
75
+ #if BOOST_UNORDERED_TEMPLATE_DEDUCTION_GUIDES
76
+ // https://eel.is/c++draft/container.requirements#container.alloc.reqmts-34
77
+ // https://eel.is/c++draft/container.requirements#unord.req.general-243
78
+
79
+ template <class InputIterator>
80
+ constexpr bool const is_input_iterator_v =
81
+ !boost::is_integral<InputIterator>::value;
82
+
83
+ template <class A, class = void> struct is_allocator
84
+ {
85
+ constexpr static bool const value = false;
86
+ };
87
+
88
+ template <class A>
89
+ struct is_allocator<A,
90
+ boost::void_t<typename A::value_type,
91
+ decltype(std::declval<A&>().allocate(std::size_t{}))> >
92
+ {
93
+ constexpr static bool const value = true;
94
+ };
95
+
96
+ template <class A>
97
+ constexpr bool const is_allocator_v = is_allocator<A>::value;
98
+
99
+ template <class H>
100
+ constexpr bool const is_hash_v =
101
+ !boost::is_integral<H>::value && !is_allocator_v<H>;
102
+
103
+ template <class P> constexpr bool const is_pred_v = !is_allocator_v<P>;
104
+ #endif
105
+ } // namespace detail
106
+ } // namespace unordered
107
+ } // namespace boost
108
+
109
+ #endif // BOOST_UNORDERED_DETAIL_TYPE_TRAITS_HPP
@@ -0,0 +1,75 @@
1
+ /* 32b/64b xmx mix function.
2
+ *
3
+ * Copyright 2022 Peter Dimov.
4
+ * Copyright 2022 Joaquin M Lopez Munoz.
5
+ * Distributed under the Boost Software License, Version 1.0.
6
+ * (See accompanying file LICENSE_1_0.txt or copy at
7
+ * http://www.boost.org/LICENSE_1_0.txt)
8
+ *
9
+ * See https://www.boost.org/libs/unordered for library home page.
10
+ */
11
+
12
+ #ifndef BOOST_UNORDERED_DETAIL_XMX_HPP
13
+ #define BOOST_UNORDERED_DETAIL_XMX_HPP
14
+
15
+ #include <boost/cstdint.hpp>
16
+ #include <climits>
17
+ #include <cstddef>
18
+
19
+ namespace boost{
20
+ namespace unordered{
21
+ namespace detail{
22
+
23
+ /* Bit mixer for improvement of statistical properties of hash functions.
24
+ * The implementation is different on 64bit and 32bit architectures:
25
+ *
26
+ * - 64bit: same as xmx function in
27
+ * http://jonkagstrom.com/bit-mixer-construction/index.html
28
+ * - 32bit: generated by Hash Function Prospector
29
+ * (https://github.com/skeeto/hash-prospector) and selected as the
30
+ * best overall performer in benchmarks of Boost.Unordered flat containers.
31
+ * Score assigned by Hash Prospector: 333.7934929677524
32
+ */
33
+
34
+ #if defined(SIZE_MAX)
35
+ #if ((((SIZE_MAX >> 16) >> 16) >> 16) >> 15) != 0
36
+ #define BOOST_UNORDERED_64B_ARCHITECTURE /* >64 bits assumed as 64 bits */
37
+ #endif
38
+ #elif defined(UINTPTR_MAX) /* used as proxy for std::size_t */
39
+ #if ((((UINTPTR_MAX >> 16) >> 16) >> 16) >> 15) != 0
40
+ #define BOOST_UNORDERED_64B_ARCHITECTURE
41
+ #endif
42
+ #endif
43
+
44
+ static inline std::size_t xmx(std::size_t x)noexcept
45
+ {
46
+ #if defined(BOOST_UNORDERED_64B_ARCHITECTURE)
47
+
48
+ boost::uint64_t z=(boost::uint64_t)x;
49
+
50
+ z^=z>>23;
51
+ z*=0xff51afd7ed558ccdull;
52
+ z^=z>>23;
53
+
54
+ return (std::size_t)z;
55
+
56
+ #else /* 32 bits assumed */
57
+
58
+ x^=x>>18;
59
+ x*=0x56b5aaadu;
60
+ x^=x>>16;
61
+
62
+ return x;
63
+
64
+ #endif
65
+ }
66
+
67
+ #ifdef BOOST_UNORDERED_64B_ARCHITECTURE
68
+ #undef BOOST_UNORDERED_64B_ARCHITECTURE
69
+ #endif
70
+
71
+ } /* namespace detail */
72
+ } /* namespace unordered */
73
+ } /* namespace boost */
74
+
75
+ #endif
@@ -0,0 +1,45 @@
1
+ /* Hash function characterization.
2
+ *
3
+ * Copyright 2022 Joaquin M Lopez Munoz.
4
+ * Distributed under the Boost Software License, Version 1.0.
5
+ * (See accompanying file LICENSE_1_0.txt or copy at
6
+ * http://www.boost.org/LICENSE_1_0.txt)
7
+ *
8
+ * See https://www.boost.org/libs/unordered for library home page.
9
+ */
10
+
11
+ #ifndef BOOST_UNORDERED_HASH_TRAITS_HPP
12
+ #define BOOST_UNORDERED_HASH_TRAITS_HPP
13
+
14
+ #include <boost/type_traits/make_void.hpp>
15
+ #include <boost/type_traits/integral_constant.hpp>
16
+
17
+ namespace boost{
18
+ namespace unordered{
19
+
20
+ namespace detail{
21
+
22
+ template<typename Hash,typename=void>
23
+ struct hash_is_avalanching_impl: boost::false_type{};
24
+
25
+ template<typename Hash>
26
+ struct hash_is_avalanching_impl<Hash,
27
+ typename boost::make_void<typename Hash::is_avalanching>::type>:
28
+ boost::true_type{};
29
+
30
+ } /* namespace detail */
31
+
32
+ /* Each trait can be partially specialized by users for concrete hash functions
33
+ * when actual characterization differs from default.
34
+ */
35
+
36
+ /* hash_is_avalanching<Hash>::value is true when the type Hash::is_avalanching
37
+ * is present, false otherwise.
38
+ */
39
+ template<typename Hash>
40
+ struct hash_is_avalanching: detail::hash_is_avalanching_impl<Hash>::type{};
41
+
42
+ } /* namespace unordered */
43
+ } /* namespace boost */
44
+
45
+ #endif