Home ⌂Doc Index ◂Up ▴
Intel(R) Threading Building Blocks Doxygen Documentation  version 4.2.3
tbb::internal::hash_map_segment_base Struct Reference
Collaboration diagram for tbb::internal::hash_map_segment_base:

Public Types

typedef spin_rw_mutex segment_mutex_t
 
typedef size_t hashcode_t
 Type of a hash code. More...
 

Public Member Functions

bool __TBB_EXPORTED_METHOD internal_grow_predicate () const
 True if my_logical_size>=my_physical_size. More...
 

Public Attributes

segment_mutex_t my_mutex
 Mutex that protects this segment. More...
 
atomic< size_t > my_logical_size
 
size_t my_physical_size
 

Static Public Attributes

static const size_t n_segment_bits = 6
 Log2 of n_segment. More...
 
static const size_t max_physical_size = size_t(1)<<(8*sizeof(hashcode_t)-n_segment_bits)
 Maximum size of array of chains. More...
 

Detailed Description

Definition at line 23 of file concurrent_hash_map.cpp.

Member Typedef Documentation

◆ hashcode_t

Type of a hash code.

Definition at line 26 of file concurrent_hash_map.cpp.

◆ segment_mutex_t

Member Function Documentation

◆ internal_grow_predicate()

bool tbb::internal::hash_map_segment_base::internal_grow_predicate ( ) const

True if my_logical_size>=my_physical_size.

Used to support Intel(R) Thread Checker.

Definition at line 43 of file concurrent_hash_map.cpp.

43  {
44  // Intel(R) Thread Checker considers the following reads to be races, so we hide them in the
45  // library so that Intel(R) Thread Checker will ignore them. The reads are used in a double-check
46  // context, so the program is nonetheless correct despite the race.
48 }
static const size_t max_physical_size
Maximum size of array of chains.

References max_physical_size, my_logical_size, and my_physical_size.

Member Data Documentation

◆ max_physical_size

const size_t tbb::internal::hash_map_segment_base::max_physical_size = size_t(1)<<(8*sizeof(hashcode_t)-n_segment_bits)
static

Maximum size of array of chains.

Definition at line 30 of file concurrent_hash_map.cpp.

Referenced by internal_grow_predicate().

◆ my_logical_size

atomic<size_t> tbb::internal::hash_map_segment_base::my_logical_size

Definition at line 34 of file concurrent_hash_map.cpp.

Referenced by internal_grow_predicate().

◆ my_mutex

segment_mutex_t tbb::internal::hash_map_segment_base::my_mutex

Mutex that protects this segment.

Definition at line 32 of file concurrent_hash_map.cpp.

◆ my_physical_size

size_t tbb::internal::hash_map_segment_base::my_physical_size

Always zero or a power of two

Definition at line 37 of file concurrent_hash_map.cpp.

Referenced by internal_grow_predicate().

◆ n_segment_bits

const size_t tbb::internal::hash_map_segment_base::n_segment_bits = 6
static

Log2 of n_segment.

Definition at line 28 of file concurrent_hash_map.cpp.


The documentation for this struct was generated from the following file:

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.