Intel(R) Threading Building Blocks Doxygen Documentation  version 4.2.3
concurrent_unordered_map.h
Go to the documentation of this file.
1 /*
2  Copyright (c) 2005-2020 Intel Corporation
3 
4  Licensed under the Apache License, Version 2.0 (the "License");
5  you may not use this file except in compliance with the License.
6  You may obtain a copy of the License at
7 
8  http://www.apache.org/licenses/LICENSE-2.0
9 
10  Unless required by applicable law or agreed to in writing, software
11  distributed under the License is distributed on an "AS IS" BASIS,
12  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  See the License for the specific language governing permissions and
14  limitations under the License.
15 */
16 
17 /* Container implementations in this header are based on PPL implementations
18  provided by Microsoft. */
19 
20 #ifndef __TBB_concurrent_unordered_map_H
21 #define __TBB_concurrent_unordered_map_H
22 
23 #define __TBB_concurrent_unordered_map_H_include_area
25 
27 
28 namespace tbb
29 {
30 
31 namespace interface5 {
32 
33 // Template class for hash map traits
34 template<typename Key, typename T, typename Hash_compare, typename Allocator, bool Allow_multimapping>
36 {
37 protected:
38  typedef std::pair<const Key, T> value_type;
39  typedef Key key_type;
40  typedef Hash_compare hash_compare;
42 #if __TBB_UNORDERED_NODE_HANDLE_PRESENT
46 #endif // __TBB_UNORDERED_NODE_HANDLE_PRESENT
47 
48  enum { allow_multimapping = Allow_multimapping };
49 
52 
53  template<class Type1, class Type2>
54  static const Key& get_key(const std::pair<Type1, Type2>& value) {
55  return (value.first);
56  }
57 
58  hash_compare my_hash_compare; // the comparator predicate for keys
59 };
60 
61 template<typename Key, typename T, typename Hasher, typename Key_equality, typename Allocator>
63 
64 template <typename Key, typename T, typename Hasher = tbb::tbb_hash<Key>, typename Key_equality = std::equal_to<Key>,
65  typename Allocator = tbb::tbb_allocator<std::pair<const Key, T> > >
67  public internal::concurrent_unordered_base< concurrent_unordered_map_traits<Key, T,
68  internal::hash_compare<Key, Hasher, Key_equality>, Allocator, false> >
69 {
70  // Base type definitions
74 #if __TBB_EXTRA_DEBUG
75 public:
76 #endif
78 public:
79  using base_type::end;
80  using base_type::find;
81  using base_type::insert;
82 
83  // Type definitions
84  typedef Key key_type;
86  typedef T mapped_type;
87  typedef Hasher hasher;
88  typedef Key_equality key_equal;
90 
92  typedef typename base_type::pointer pointer;
94  typedef typename base_type::reference reference;
96 
97  typedef typename base_type::size_type size_type;
99 
100  typedef typename base_type::iterator iterator;
104 #if __TBB_UNORDERED_NODE_HANDLE_PRESENT
105  typedef typename base_type::node_type node_type;
106 #endif // __TBB_UNORDERED_NODE_HANDLE_PRESENT
107 
108  // Construction/destruction/copying
110  const hasher& a_hasher = hasher(), const key_equal& a_keyeq = key_equal(),
111  const allocator_type& a = allocator_type())
112  : base_type(n_of_buckets, key_compare(a_hasher, a_keyeq), a)
113  {}
114 
116  : base_type(n_of_buckets, key_compare(hasher(), key_equal()), a)
117  {}
118 
119  concurrent_unordered_map(size_type n_of_buckets, const hasher& a_hasher, const allocator_type& a)
120  : base_type(n_of_buckets, key_compare(a_hasher, key_equal()), a)
121  {}
122 
124  {}
125 
126  template <typename Iterator>
128  const hasher& a_hasher = hasher(), const key_equal& a_keyeq = key_equal(),
129  const allocator_type& a = allocator_type())
130  : base_type(n_of_buckets, key_compare(a_hasher, a_keyeq), a)
131  {
132  insert(first, last);
133  }
134 
135  template <typename Iterator>
136  concurrent_unordered_map(Iterator first, Iterator last, size_type n_of_buckets, const allocator_type& a)
137  : base_type(n_of_buckets, key_compare(hasher(), key_equal()), a)
138  {
139  insert(first, last);
140  }
141 
142  template <typename Iterator>
143  concurrent_unordered_map(Iterator first, Iterator last, size_type n_of_buckets, const hasher& a_hasher,
144  const allocator_type& a)
145  : base_type(n_of_buckets, key_compare(a_hasher, key_equal()), a)
146  {
147  insert(first, last);
148  }
149 
150 #if __TBB_INITIALIZER_LISTS_PRESENT
151  concurrent_unordered_map(std::initializer_list<value_type> il, size_type n_of_buckets = base_type::initial_bucket_number,
153  const hasher& a_hasher = hasher(), const key_equal& a_keyeq = key_equal(),
154  const allocator_type& a = allocator_type())
155  : base_type(n_of_buckets, key_compare(a_hasher, a_keyeq), a)
156  {
157  insert(il.begin(),il.end());
158  }
159 
160  concurrent_unordered_map(std::initializer_list<value_type> il, size_type n_of_buckets, const allocator_type& a)
161  : base_type(n_of_buckets, key_compare(hasher(), key_equal()), a)
162  {
163  insert(il.begin(), il.end());
164  }
165 
166  concurrent_unordered_map(std::initializer_list<value_type> il, size_type n_of_buckets, const hasher& a_hasher,
167  const allocator_type& a)
168  : base_type(n_of_buckets, key_compare(a_hasher, key_equal()), a)
169  {
170  insert(il.begin(), il.end());
171  }
172 
173 #endif //# __TBB_INITIALIZER_LISTS_PRESENT
174 
175 
176 #if __TBB_CPP11_RVALUE_REF_PRESENT && !__TBB_IMPLICIT_MOVE_PRESENT
178  : base_type(table)
179  {}
180 
182  {
183  return static_cast<concurrent_unordered_map&>(base_type::operator=(table));
184  }
185 
187  : base_type(std::move(table))
188  {}
189 
191  {
192  return static_cast<concurrent_unordered_map&>(base_type::operator=(std::move(table)));
193  }
194 #endif //__TBB_CPP11_RVALUE_REF_PRESENT && !__TBB_IMPLICIT_MOVE_PRESENT
195 
196 #if __TBB_CPP11_RVALUE_REF_PRESENT
197  concurrent_unordered_map(concurrent_unordered_map&& table, const Allocator& a) : base_type(std::move(table), a)
198  {}
199 #endif /*__TBB_CPP11_RVALUE_REF_PRESENT*/
200 
201 #if __TBB_UNORDERED_NODE_HANDLE_PRESENT
202  template<typename Hash, typename Equality>
204  { this->internal_merge(source); }
205 
206  template<typename Hash, typename Equality>
208  { this->internal_merge(source); }
209 
210  template<typename Hash, typename Equality>
212  { this->internal_merge(source); }
213 
214  template<typename Hash, typename Equality>
216  { this->internal_merge(source); }
217 
218 #endif //__TBB_UNORDERED_NODE_HANDLE_PRESENT
219 
220  concurrent_unordered_map(const concurrent_unordered_map& table, const Allocator& a)
221  : base_type(table, a)
222  {}
223 
224  // Observers
226  {
227  iterator where = find(key);
228 
229  if (where == end())
230  {
231  where = insert(std::pair<key_type, mapped_type>(key, mapped_type())).first;
232  }
233 
234  return ((*where).second);
235  }
236 
238  {
239  iterator where = find(key);
240 
241  if (where == end())
242  {
244  }
245 
246  return ((*where).second);
247  }
248 
249  const mapped_type& at(const key_type& key) const
250  {
251  const_iterator where = find(key);
252 
253  if (where == end())
254  {
256  }
257 
258  return ((*where).second);
259  }
260 };
261 
262 #if __TBB_CPP17_DEDUCTION_GUIDES_PRESENT
263 
264 namespace internal {
265 using namespace tbb::internal;
266 
267 template<template<typename...> typename Map, typename Key, typename Element, typename... Args>
268 using cu_map_t = Map<
269  Key, Element,
270  std::conditional_t< (sizeof...(Args)>0) && !is_allocator_v< pack_element_t<0, Args...> >,
271  pack_element_t<0, Args...>, tbb_hash<Key> >,
272  std::conditional_t< (sizeof...(Args)>1) && !is_allocator_v< pack_element_t<1, Args...> >,
273  pack_element_t<1, Args...>, std::equal_to<Key> >,
274  std::conditional_t< (sizeof...(Args)>0) && is_allocator_v< pack_element_t<sizeof...(Args)-1, Args...> >,
275  pack_element_t<sizeof...(Args)-1, Args...>, tbb_allocator<std::pair<const Key, Element> > >
276 >;
277 }
278 
279 // Deduction guide for the constructor from two iterators
280 template<typename I>
281 concurrent_unordered_map (I, I)
282 -> internal::cu_map_t<concurrent_unordered_map, internal::iterator_key_t<I>, internal::iterator_mapped_t<I>>;
283 
284 // Deduction guide for the constructor from two iterators and hasher/equality/allocator
285 template<typename I, typename... Args>
286 concurrent_unordered_map(I, I, size_t, Args...)
287 -> internal::cu_map_t<concurrent_unordered_map, internal::iterator_key_t<I>, internal::iterator_mapped_t<I>, Args...>;
288 
289 // Deduction guide for the constructor from an initializer_list
290 template<typename Key, typename Element>
291 concurrent_unordered_map(std::initializer_list<std::pair<const Key, Element>>)
292 -> internal::cu_map_t<concurrent_unordered_map, Key, Element>;
293 
294 // Deduction guide for the constructor from an initializer_list and hasher/equality/allocator
295 template<typename Key, typename Element, typename... Args>
296 concurrent_unordered_map(std::initializer_list<std::pair<const Key, Element>>, size_t, Args...)
297 -> internal::cu_map_t<concurrent_unordered_map, Key, Element, Args...>;
298 
299 #endif /* __TBB_CPP17_DEDUCTION_GUIDES_PRESENT */
300 
301 template < typename Key, typename T, typename Hasher = tbb::tbb_hash<Key>, typename Key_equality = std::equal_to<Key>,
302  typename Allocator = tbb::tbb_allocator<std::pair<const Key, T> > >
303 class concurrent_unordered_multimap :
304  public internal::concurrent_unordered_base< concurrent_unordered_map_traits< Key, T,
305  internal::hash_compare<Key, Hasher, Key_equality>, Allocator, true> >
306 {
307  // Base type definitions
311 #if __TBB_EXTRA_DEBUG
312 public:
313 #endif
314  using traits_type::allow_multimapping;
315 public:
316  using base_type::insert;
317 
318  // Type definitions
319  typedef Key key_type;
321  typedef T mapped_type;
322  typedef Hasher hasher;
323  typedef Key_equality key_equal;
325 
327  typedef typename base_type::pointer pointer;
329  typedef typename base_type::reference reference;
330  typedef typename base_type::const_reference const_reference;
331 
332  typedef typename base_type::size_type size_type;
334 
335  typedef typename base_type::iterator iterator;
339 #if __TBB_UNORDERED_NODE_HANDLE_PRESENT
340  typedef typename base_type::node_type node_type;
341 #endif //__TBB_UNORDERED_NODE_HANDLE_PRESENT
342 
343  // Construction/destruction/copying
344  explicit concurrent_unordered_multimap(size_type n_of_buckets = base_type::initial_bucket_number,
345  const hasher& a_hasher = hasher(), const key_equal& a_keyeq = key_equal(),
346  const allocator_type& a = allocator_type())
347  : base_type(n_of_buckets, key_compare(a_hasher, a_keyeq), a)
348  {}
349 
351  : base_type(n_of_buckets, key_compare(hasher(), key_equal()), a)
352  {}
353 
354  concurrent_unordered_multimap(size_type n_of_buckets, const hasher& a_hasher, const allocator_type& a)
355  : base_type(n_of_buckets, key_compare(a_hasher, key_equal()), a)
356  {}
357 
358  explicit concurrent_unordered_multimap(const Allocator& a) : base_type(base_type::initial_bucket_number, key_compare(), a)
359  {}
360 
361  template <typename Iterator>
362  concurrent_unordered_multimap(Iterator first, Iterator last, size_type n_of_buckets = base_type::initial_bucket_number,
363  const hasher& a_hasher = hasher(), const key_equal& a_keyeq = key_equal(),
364  const allocator_type& a = allocator_type())
365  : base_type(n_of_buckets,key_compare(a_hasher,a_keyeq), a)
366  {
367  insert(first, last);
368  }
369 
370  template <typename Iterator>
371  concurrent_unordered_multimap(Iterator first, Iterator last, size_type n_of_buckets, const allocator_type& a)
372  : base_type(n_of_buckets, key_compare(hasher(), key_equal()), a)
373  {
374  insert(first, last);
375  }
376 
377  template <typename Iterator>
378  concurrent_unordered_multimap(Iterator first, Iterator last, size_type n_of_buckets, const hasher& a_hasher,
379  const allocator_type& a)
380  : base_type(n_of_buckets, key_compare(a_hasher, key_equal()), a)
381  {
382  insert(first, last);
383  }
384 
385 #if __TBB_INITIALIZER_LISTS_PRESENT
386  concurrent_unordered_multimap(std::initializer_list<value_type> il, size_type n_of_buckets = base_type::initial_bucket_number,
388  const hasher& a_hasher = hasher(), const key_equal& a_keyeq = key_equal(),
389  const allocator_type& a = allocator_type())
390  : base_type(n_of_buckets, key_compare(a_hasher, a_keyeq), a)
391  {
392  insert(il.begin(),il.end());
393  }
394 
395  concurrent_unordered_multimap(std::initializer_list<value_type> il, size_type n_of_buckets, const allocator_type& a)
396  : base_type(n_of_buckets, key_compare(hasher(), key_equal()), a)
397  {
398  insert(il.begin(), il.end());
399  }
400 
401  concurrent_unordered_multimap(std::initializer_list<value_type> il, size_type n_of_buckets, const hasher& a_hasher,
402  const allocator_type& a)
403  : base_type(n_of_buckets, key_compare(a_hasher, key_equal()), a)
404  {
405  insert(il.begin(), il.end());
406  }
407 
408 #endif //# __TBB_INITIALIZER_LISTS_PRESENT
409 
410 #if __TBB_CPP11_RVALUE_REF_PRESENT && !__TBB_IMPLICIT_MOVE_PRESENT
412  : base_type(table)
413  {}
414 
416  {
417  return static_cast<concurrent_unordered_multimap&>(base_type::operator=(table));
418  }
419 
421  : base_type(std::move(table))
422  {}
423 
425  {
426  return static_cast<concurrent_unordered_multimap&>(base_type::operator=(std::move(table)));
427  }
428 #endif //__TBB_CPP11_RVALUE_REF_PRESENT && !__TBB_IMPLICIT_MOVE_PRESENT
429 
430 #if __TBB_CPP11_RVALUE_REF_PRESENT
431  concurrent_unordered_multimap(concurrent_unordered_multimap&& table, const Allocator& a) : base_type(std::move(table), a)
432  {}
433 #endif /*__TBB_CPP11_RVALUE_REF_PRESENT*/
434 
435 #if __TBB_UNORDERED_NODE_HANDLE_PRESENT
436  template<typename Hash, typename Equality>
438  { this->internal_merge(source); }
439 
440  template<typename Hash, typename Equality>
442  { this->internal_merge(source); }
443 
444  template<typename Hash, typename Equality>
446  { this->internal_merge(source); }
447 
448  template<typename Hash, typename Equality>
450  { this->internal_merge(source); }
451 
452 #endif //__TBB_UNORDERED_NODE_HANDLE_PRESENT
453 
455  : base_type(table, a)
456  {}
457 };
458 
459 #if __TBB_CPP17_DEDUCTION_GUIDES_PRESENT
460 
461 // Deduction guide for the constructor from two iterators
462 template<typename I>
464 -> internal::cu_map_t<concurrent_unordered_multimap, internal::iterator_key_t<I>, internal::iterator_mapped_t<I>>;
465 
466 // Deduction guide for the constructor from two iterators and hasher/equality/allocator
467 template<typename I, typename... Args>
468 concurrent_unordered_multimap(I, I, size_t, Args...)
469 -> internal::cu_map_t<concurrent_unordered_multimap, internal::iterator_key_t<I>, internal::iterator_mapped_t<I>, Args...>;
470 
471 // Deduction guide for the constructor from an initializer_list
472 template<typename Key, typename Element>
473 concurrent_unordered_multimap(std::initializer_list<std::pair<const Key, Element>>)
474 -> internal::cu_map_t<concurrent_unordered_multimap, Key, Element>;
475 
476 // Deduction guide for the constructor from an initializer_list and hasher/equality/allocator
477 template<typename Key, typename Element, typename... Args>
478 concurrent_unordered_multimap(std::initializer_list<std::pair<const Key, Element>>, size_t, Args...)
479 -> internal::cu_map_t<concurrent_unordered_multimap, Key, Element, Args...>;
480 
481 #endif /* __TBB_CPP17_DEDUCTION_GUIDES_PRESENT */
482 } // namespace interface5
483 
484 using interface5::concurrent_unordered_map;
485 using interface5::concurrent_unordered_multimap;
486 
487 } // namespace tbb
488 
490 #undef __TBB_concurrent_unordered_map_H_include_area
491 
492 #endif// __TBB_concurrent_unordered_map_H
tbb::interface5::concurrent_unordered_map::operator[]
mapped_type & operator[](const key_type &key)
Definition: concurrent_unordered_map.h:225
tbb::interface5::concurrent_unordered_map::at
mapped_type & at(const key_type &key)
Definition: concurrent_unordered_map.h:237
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(size_type n_of_buckets, const allocator_type &a)
Definition: concurrent_unordered_map.h:350
tbb::interface5::concurrent_unordered_multimap::merge
void merge(concurrent_unordered_multimap< Key, T, Hash, Equality, Allocator > &source)
Definition: concurrent_unordered_map.h:445
internal
Definition: _flow_graph_async_msg_impl.h:24
tbb::interface5::concurrent_unordered_map_traits::hash_compare
Hash_compare hash_compare
Definition: concurrent_unordered_map.h:40
tbb::interface5::concurrent_unordered_multimap::mapped_type
T mapped_type
Definition: concurrent_unordered_map.h:321
tbb::interface5::internal::concurrent_unordered_base::size_type
tbb::internal::allocator_traits< allocator_type >::size_type size_type
Definition: _concurrent_unordered_impl.h:718
tbb::interface5::concurrent_unordered_multimap::merge
void merge(concurrent_unordered_map< Key, T, Hash, Equality, Allocator > &&source)
Definition: concurrent_unordered_map.h:441
tbb::interface5::concurrent_unordered_map::merge
void merge(concurrent_unordered_map< Key, T, Hash, Equality, Allocator > &&source)
Definition: concurrent_unordered_map.h:207
tbb::interface5::concurrent_unordered_map::merge
void merge(concurrent_unordered_multimap< Key, T, Hash, Equality, Allocator > &source)
Definition: concurrent_unordered_map.h:211
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(const concurrent_unordered_multimap &table, const Allocator &a)
Definition: concurrent_unordered_map.h:454
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(Iterator first, Iterator last, size_type n_of_buckets=base_type::initial_bucket_number, const hasher &a_hasher=hasher(), const key_equal &a_keyeq=key_equal(), const allocator_type &a=allocator_type())
Definition: concurrent_unordered_map.h:362
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(std::initializer_list< value_type > il, size_type n_of_buckets, const hasher &a_hasher, const allocator_type &a)
Definition: concurrent_unordered_map.h:401
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(concurrent_unordered_map &&table, const Allocator &a)
Definition: concurrent_unordered_map.h:197
tbb::interface5::concurrent_unordered_multimap::pointer
base_type::pointer pointer
Definition: concurrent_unordered_map.h:327
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(size_type n_of_buckets, const allocator_type &a)
Definition: concurrent_unordered_map.h:115
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(concurrent_unordered_multimap &&table)
Definition: concurrent_unordered_map.h:420
tbb::interface5::concurrent_unordered_multimap::local_iterator
base_type::iterator local_iterator
Definition: concurrent_unordered_map.h:337
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(size_type n_of_buckets=base_type::initial_bucket_number, const hasher &a_hasher=hasher(), const key_equal &a_keyeq=key_equal(), const allocator_type &a=allocator_type())
Definition: concurrent_unordered_map.h:109
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(std::initializer_list< value_type > il, size_type n_of_buckets, const allocator_type &a)
Definition: concurrent_unordered_map.h:395
tbb::internal::throw_exception
void throw_exception(exception_id eid)
Versionless convenience wrapper for throw_exception_v4()
Definition: tbb_exception.h:105
tbb::interface5::concurrent_unordered_map::const_local_iterator
base_type::const_iterator const_local_iterator
Definition: concurrent_unordered_map.h:103
tbb::interface5::internal::concurrent_unordered_base::value_type
Traits::value_type value_type
Definition: _concurrent_unordered_impl.h:711
tbb
The graph class.
Definition: serial/tbb/parallel_for.h:46
tbb::internal::first
Container::iterator first(Container &c)
Definition: _range_iterator.h:46
tbb::interface5::concurrent_unordered_map::size_type
base_type::size_type size_type
Definition: concurrent_unordered_map.h:97
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(Iterator first, Iterator last, size_type n_of_buckets=base_type::initial_bucket_number, const hasher &a_hasher=hasher(), const key_equal &a_keyeq=key_equal(), const allocator_type &a=allocator_type())
Definition: concurrent_unordered_map.h:127
tbb::interface5::concurrent_unordered_map::const_pointer
base_type::const_pointer const_pointer
Definition: concurrent_unordered_map.h:93
tbb::interface5::internal::solist_iterator
Definition: _concurrent_unordered_impl.h:129
tbb::internal::last
Container::iterator last(Container &c)
Definition: _range_iterator.h:52
tbb::interface5::concurrent_unordered_map::traits_type
concurrent_unordered_map_traits< Key, T, hash_compare, Allocator, false > traits_type
Definition: concurrent_unordered_map.h:72
tbb::interface5::concurrent_unordered_multimap::key_compare
hash_compare key_compare
Definition: concurrent_unordered_map.h:324
tbb::interface5::internal::concurrent_unordered_base::const_reference
const typedef allocator_type::value_type & const_reference
Definition: _concurrent_unordered_impl.h:724
tbb::interface5::concurrent_unordered_multimap::size_type
base_type::size_type size_type
Definition: concurrent_unordered_map.h:332
tbb::interface5::concurrent_unordered_multimap::operator=
concurrent_unordered_multimap & operator=(concurrent_unordered_multimap &&table)
Definition: concurrent_unordered_map.h:424
tbb::interface5::concurrent_unordered_multimap::merge
void merge(concurrent_unordered_multimap< Key, T, Hash, Equality, Allocator > &&source)
Definition: concurrent_unordered_map.h:449
tbb::internal::allocator_type
Class for determining type of std::allocator<T>::value_type.
Definition: tbb_stddef.h:471
tbb::interface5::concurrent_unordered_map_traits::concurrent_unordered_map_traits
concurrent_unordered_map_traits(const hash_compare &hc)
Definition: concurrent_unordered_map.h:51
tbb::interface5::concurrent_unordered_multimap
Definition: concurrent_unordered_map.h:62
tbb::interface5::concurrent_unordered_map::merge
void merge(concurrent_unordered_map< Key, T, Hash, Equality, Allocator > &source)
Definition: concurrent_unordered_map.h:203
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(std::initializer_list< value_type > il, size_type n_of_buckets, const hasher &a_hasher, const allocator_type &a)
Definition: concurrent_unordered_map.h:166
tbb::interface5::concurrent_unordered_map::hasher
Hasher hasher
Definition: concurrent_unordered_map.h:87
tbb::interface5::concurrent_unordered_multimap::traits_type
concurrent_unordered_map_traits< Key, T, hash_compare, Allocator, true > traits_type
Definition: concurrent_unordered_map.h:309
tbb::interface5::internal::concurrent_unordered_base
Definition: _concurrent_unordered_impl.h:63
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(Iterator first, Iterator last, size_type n_of_buckets, const allocator_type &a)
Definition: concurrent_unordered_map.h:371
tbb::interface5::internal::concurrent_unordered_base::reference
allocator_type::value_type & reference
Definition: _concurrent_unordered_impl.h:723
tbb::interface5::concurrent_unordered_multimap::const_pointer
base_type::const_pointer const_pointer
Definition: concurrent_unordered_map.h:328
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(size_type n_of_buckets, const hasher &a_hasher, const allocator_type &a)
Definition: concurrent_unordered_map.h:119
tbb::interface5::concurrent_unordered_multimap::reference
base_type::reference reference
Definition: concurrent_unordered_map.h:329
tbb::interface5::concurrent_unordered_map::base_type
internal::concurrent_unordered_base< traits_type > base_type
Definition: concurrent_unordered_map.h:73
tbb::interface5::internal::concurrent_unordered_base::insert
std::pair< iterator, bool > insert(const value_type &value)
Definition: _concurrent_unordered_impl.h:1068
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(const Allocator &a)
Definition: concurrent_unordered_map.h:123
tbb::interface5::concurrent_unordered_map::key_compare
hash_compare key_compare
Definition: concurrent_unordered_map.h:89
tbb::interface5::concurrent_unordered_map_traits::key_type
Key key_type
Definition: concurrent_unordered_map.h:39
tbb::internal::eid_invalid_key
@ eid_invalid_key
Definition: tbb_exception.h:84
tbb::interface5::concurrent_unordered_multimap::merge
void merge(concurrent_unordered_map< Key, T, Hash, Equality, Allocator > &source)
Definition: concurrent_unordered_map.h:437
tbb::interface5::concurrent_unordered_multimap::difference_type
base_type::difference_type difference_type
Definition: concurrent_unordered_map.h:333
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(const concurrent_unordered_map &table, const Allocator &a)
Definition: concurrent_unordered_map.h:220
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(Iterator first, Iterator last, size_type n_of_buckets, const allocator_type &a)
Definition: concurrent_unordered_map.h:136
tbb::interface5::concurrent_unordered_multimap::const_reference
base_type::const_reference const_reference
Definition: concurrent_unordered_map.h:330
tbb::interface5::concurrent_unordered_map::merge
void merge(concurrent_unordered_multimap< Key, T, Hash, Equality, Allocator > &&source)
Definition: concurrent_unordered_map.h:215
tbb::interface5::concurrent_unordered_map::at
const mapped_type & at(const key_type &key) const
Definition: concurrent_unordered_map.h:249
tbb::interface5::concurrent_unordered_multimap::const_local_iterator
base_type::const_iterator const_local_iterator
Definition: concurrent_unordered_map.h:338
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(size_type n_of_buckets, const hasher &a_hasher, const allocator_type &a)
Definition: concurrent_unordered_map.h:354
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(size_type n_of_buckets=base_type::initial_bucket_number, const hasher &a_hasher=hasher(), const key_equal &a_keyeq=key_equal(), const allocator_type &a=allocator_type())
Definition: concurrent_unordered_map.h:344
tbb::interface5::concurrent_unordered_multimap::node_type
base_type::node_type node_type
Definition: concurrent_unordered_map.h:340
tbb::interface5::concurrent_unordered_multimap::value_type
base_type::value_type value_type
Definition: concurrent_unordered_map.h:320
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(std::initializer_list< value_type > il, size_type n_of_buckets, const allocator_type &a)
Definition: concurrent_unordered_map.h:160
tbb::move
void move(tbb_thread &t1, tbb_thread &t2)
Definition: tbb_thread.h:319
key
void const char const char int ITT_FORMAT __itt_group_sync x void const char ITT_FORMAT __itt_group_sync s void ITT_FORMAT __itt_group_sync p void ITT_FORMAT p void ITT_FORMAT p no args __itt_suppress_mode_t unsigned int void size_t ITT_FORMAT d void ITT_FORMAT p void ITT_FORMAT p __itt_model_site __itt_model_site_instance ITT_FORMAT p __itt_model_task __itt_model_task_instance ITT_FORMAT p void ITT_FORMAT p void ITT_FORMAT p void size_t ITT_FORMAT d void ITT_FORMAT p const wchar_t ITT_FORMAT s const char ITT_FORMAT s const char ITT_FORMAT s const char ITT_FORMAT s no args void ITT_FORMAT p size_t ITT_FORMAT d no args const wchar_t const wchar_t ITT_FORMAT s __itt_heap_function void size_t int ITT_FORMAT d __itt_heap_function void ITT_FORMAT p __itt_heap_function void void size_t int ITT_FORMAT d no args no args unsigned int ITT_FORMAT u const __itt_domain __itt_id ITT_FORMAT lu const __itt_domain __itt_id __itt_id __itt_string_handle ITT_FORMAT p const __itt_domain __itt_id ITT_FORMAT p const __itt_domain __itt_id __itt_timestamp __itt_timestamp ITT_FORMAT lu const __itt_domain __itt_id __itt_id __itt_string_handle ITT_FORMAT p const __itt_domain ITT_FORMAT p const __itt_domain __itt_string_handle unsigned long long ITT_FORMAT lu const __itt_domain __itt_string_handle unsigned long long ITT_FORMAT lu const __itt_domain __itt_id __itt_string_handle * key
Definition: ittnotify_static.h:198
tbb::interface5::internal::concurrent_unordered_base::const_pointer
tbb::internal::allocator_traits< allocator_type >::const_pointer const_pointer
Definition: _concurrent_unordered_impl.h:721
tbb::interface5::concurrent_unordered_map::node_type
base_type::node_type node_type
Definition: concurrent_unordered_map.h:105
tbb::interface5::internal::concurrent_unordered_base::node_type
Traits::node_type node_type
Definition: _concurrent_unordered_impl.h:736
tbb::interface5::internal::concurrent_unordered_base::operator=
concurrent_unordered_base & operator=(const concurrent_unordered_base &right)
Definition: _concurrent_unordered_impl.h:844
tbb::tbb_allocator
Meets "allocator" requirements of ISO C++ Standard, Section 20.1.5.
Definition: tbb_allocator.h:58
tbb::interface5::concurrent_unordered_map::operator=
concurrent_unordered_map & operator=(const concurrent_unordered_map &table)
Definition: concurrent_unordered_map.h:181
tbb::interface5::concurrent_unordered_map_traits::allow_multimapping
@ allow_multimapping
Definition: concurrent_unordered_map.h:48
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(concurrent_unordered_multimap &&table, const Allocator &a)
Definition: concurrent_unordered_map.h:431
tbb::interface5::internal::concurrent_unordered_base::find
iterator find(const key_type &key)
Definition: _concurrent_unordered_impl.h:1202
tbb::interface5::internal::concurrent_unordered_base::pointer
tbb::internal::allocator_traits< allocator_type >::pointer pointer
Definition: _concurrent_unordered_impl.h:720
tbb::interface5::concurrent_unordered_multimap::base_type
internal::concurrent_unordered_base< traits_type > base_type
Definition: concurrent_unordered_map.h:310
tbb::interface5::concurrent_unordered_multimap::iterator
base_type::iterator iterator
Definition: concurrent_unordered_map.h:335
tbb::interface5::internal::split_ordered_list::node
Definition: _concurrent_unordered_impl.h:228
_warning_suppress_disable_notice.h
tbb::interface5::internal::concurrent_unordered_base::allocator_type
Traits::allocator_type allocator_type
Definition: _concurrent_unordered_impl.h:714
tbb::interface5::concurrent_unordered_map::const_iterator
base_type::const_iterator const_iterator
Definition: concurrent_unordered_map.h:101
tbb::interface5::concurrent_unordered_map_traits::concurrent_unordered_map_traits
concurrent_unordered_map_traits()
Definition: concurrent_unordered_map.h:50
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(const concurrent_unordered_multimap &table)
Definition: concurrent_unordered_map.h:411
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(const Allocator &a)
Definition: concurrent_unordered_map.h:358
tbb::interface5::concurrent_unordered_map::key_equal
Key_equality key_equal
Definition: concurrent_unordered_map.h:88
tbb::interface5::concurrent_unordered_multimap::hasher
Hasher hasher
Definition: concurrent_unordered_map.h:322
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(Iterator first, Iterator last, size_type n_of_buckets, const hasher &a_hasher, const allocator_type &a)
Definition: concurrent_unordered_map.h:143
tbb::interface5::concurrent_unordered_map::reference
base_type::reference reference
Definition: concurrent_unordered_map.h:94
tbb::interface5::concurrent_unordered_multimap::key_type
Key key_type
Definition: concurrent_unordered_map.h:319
tbb::internal::node_handle
Definition: _node_handle_impl.h:104
tbb::interface5::concurrent_unordered_multimap::const_iterator
base_type::const_iterator const_iterator
Definition: concurrent_unordered_map.h:336
tbb::interface5::concurrent_unordered_multimap::allocator_type
base_type::allocator_type allocator_type
Definition: concurrent_unordered_map.h:326
tbb::interface5::concurrent_unordered_map::operator=
concurrent_unordered_map & operator=(concurrent_unordered_map &&table)
Definition: concurrent_unordered_map.h:190
tbb::interface5::concurrent_unordered_map::difference_type
base_type::difference_type difference_type
Definition: concurrent_unordered_map.h:98
tbb::interface5::concurrent_unordered_map_traits::get_key
static const Key & get_key(const std::pair< Type1, Type2 > &value)
Definition: concurrent_unordered_map.h:54
tbb::interface5::concurrent_unordered_map_traits::value_type
std::pair< const Key, T > value_type
Definition: concurrent_unordered_map.h:38
tbb::interface5::concurrent_unordered_map::const_reference
base_type::const_reference const_reference
Definition: concurrent_unordered_map.h:95
tbb::interface5::concurrent_unordered_map::key_type
Key key_type
Definition: concurrent_unordered_map.h:84
tbb::interface5::concurrent_unordered_multimap::operator=
concurrent_unordered_multimap & operator=(const concurrent_unordered_multimap &table)
Definition: concurrent_unordered_map.h:415
tbb::interface5::internal::concurrent_unordered_base< concurrent_unordered_map_traits< Key, T, internal::hash_compare< Key, tbb::tbb_hash< Key >, std::equal_to< Key > >, tbb::tbb_allocator< std::pair< const Key, T > >, false > >::internal_merge
void internal_merge(SourceType &source)
Definition: _concurrent_unordered_impl.h:892
tbb::interface5::concurrent_unordered_map
Definition: concurrent_unordered_map.h:66
tbb::interface5::concurrent_unordered_map_traits::node_type
tbb::internal::node_handle< key_type, value_type, typename internal::split_ordered_list< value_type, allocator_type >::node, allocator_type > node_type
Definition: concurrent_unordered_map.h:45
value
void const char const char int ITT_FORMAT __itt_group_sync x void const char ITT_FORMAT __itt_group_sync s void ITT_FORMAT __itt_group_sync p void ITT_FORMAT p void ITT_FORMAT p no args __itt_suppress_mode_t unsigned int void size_t ITT_FORMAT d void ITT_FORMAT p void ITT_FORMAT p __itt_model_site __itt_model_site_instance ITT_FORMAT p __itt_model_task __itt_model_task_instance ITT_FORMAT p void ITT_FORMAT p void ITT_FORMAT p void size_t ITT_FORMAT d void ITT_FORMAT p const wchar_t ITT_FORMAT s const char ITT_FORMAT s const char ITT_FORMAT s const char ITT_FORMAT s no args void ITT_FORMAT p size_t ITT_FORMAT d no args const wchar_t const wchar_t ITT_FORMAT s __itt_heap_function void size_t int ITT_FORMAT d __itt_heap_function void ITT_FORMAT p __itt_heap_function void void size_t int ITT_FORMAT d no args no args unsigned int ITT_FORMAT u const __itt_domain __itt_id ITT_FORMAT lu const __itt_domain __itt_id __itt_id __itt_string_handle ITT_FORMAT p const __itt_domain __itt_id ITT_FORMAT p const __itt_domain __itt_id __itt_timestamp __itt_timestamp ITT_FORMAT lu const __itt_domain __itt_id __itt_id __itt_string_handle ITT_FORMAT p const __itt_domain ITT_FORMAT p const __itt_domain __itt_string_handle unsigned long long value
Definition: ittnotify_static.h:192
tbb::interface5::concurrent_unordered_multimap::concurrent_unordered_multimap
concurrent_unordered_multimap(Iterator first, Iterator last, size_type n_of_buckets, const hasher &a_hasher, const allocator_type &a)
Definition: concurrent_unordered_map.h:378
tbb::interface5::concurrent_unordered_map_traits::my_hash_compare
hash_compare my_hash_compare
Definition: concurrent_unordered_map.h:58
_concurrent_unordered_impl.h
tbb::interface5::concurrent_unordered_map_traits::allocator_type
tbb::internal::allocator_rebind< Allocator, value_type >::type allocator_type
Definition: concurrent_unordered_map.h:41
tbb::internal
Identifiers declared inside namespace internal should never be used directly by client code.
Definition: atomic.h:65
tbb::interface5::concurrent_unordered_map::pointer
base_type::pointer pointer
Definition: concurrent_unordered_map.h:92
tbb::interface5::concurrent_unordered_map::allocator_type
base_type::allocator_type allocator_type
Definition: concurrent_unordered_map.h:91
_warning_suppress_enable_notice.h
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(const concurrent_unordered_map &table)
Definition: concurrent_unordered_map.h:177
tbb::interface5::concurrent_unordered_map_traits
Definition: concurrent_unordered_map.h:35
tbb::interface5::concurrent_unordered_multimap::hash_compare
internal::hash_compare< Key, Hasher, Key_equality > hash_compare
Definition: concurrent_unordered_map.h:308
tbb::interface5::concurrent_unordered_map::concurrent_unordered_map
concurrent_unordered_map(concurrent_unordered_map &&table)
Definition: concurrent_unordered_map.h:186
tbb::interface5::concurrent_unordered_map::iterator
base_type::iterator iterator
Definition: concurrent_unordered_map.h:100
tbb::interface5::concurrent_unordered_map::value_type
base_type::value_type value_type
Definition: concurrent_unordered_map.h:85
tbb::interface5::concurrent_unordered_map::mapped_type
T mapped_type
Definition: concurrent_unordered_map.h:86
tbb::interface5::internal::concurrent_unordered_base::difference_type
tbb::internal::allocator_traits< allocator_type >::difference_type difference_type
Definition: _concurrent_unordered_impl.h:719
tbb::interface5::internal::concurrent_unordered_base::initial_bucket_number
static const size_type initial_bucket_number
Definition: _concurrent_unordered_impl.h:742
tbb::internal::allocator_rebind::type
allocator_traits< Alloc >::template rebind_alloc< T >::other type
Definition: _allocator_traits.h:149
tbb::interface5::internal::concurrent_unordered_base::end
iterator end()
Definition: _concurrent_unordered_impl.h:960
tbb::interface5::concurrent_unordered_multimap::key_equal
Key_equality key_equal
Definition: concurrent_unordered_map.h:323
tbb::interface5::concurrent_unordered_map::local_iterator
base_type::iterator local_iterator
Definition: concurrent_unordered_map.h:102
tbb::interface5::concurrent_unordered_map::hash_compare
internal::hash_compare< Key, Hasher, Key_equality > hash_compare
Definition: concurrent_unordered_map.h:71
tbb::interface5::internal::hash_compare
Definition: _tbb_hash_compare_impl.h:29

Copyright © 2005-2020 Intel Corporation. All Rights Reserved.

Intel, Pentium, Intel Xeon, Itanium, Intel XScale and VTune are registered trademarks or trademarks of Intel Corporation or its subsidiaries in the United States and other countries.

* Other names and brands may be claimed as the property of others.