| 147 | template<std::size_t size> struct hash_32_or_64 : public _hash_32_or_64<(size > 4)> { }; |
| 148 | |
| 149 | static inline std::size_t hash_thread_id(thread_id_t id) |
| 150 | { |
| 151 | static_assert(sizeof(thread_id_t) <= 8, "Expected a platform where thread IDs are at most 64-bit values"); |
| 152 | return hash_32_or_64<sizeof(thread_id_t)>::hash(id); |
| 153 | } |
| 154 | |
| 155 | template<typename U> |
| 156 | static inline char* align_for(char* ptr) |