tbb::interface5::internal::split_ordered_list< T, Allocator >::node Struct Reference

`#include <_concurrent_unordered_impl.h>`

Inheritance diagram for tbb::interface5::internal::split_ordered_list< T, Allocator >::node:
Collaboration diagram for tbb::interface5::internal::split_ordered_list< T, Allocator >::node:

## Public Member Functions

void | init (sokey_t order_key)
sokey_t | get_order_key () const
value_type * | storage ()
value_type & | value ()
nodeptr_t | atomic_set_next (nodeptr_t new_node, nodeptr_t current_node)
bool | is_dummy () const
Public Member Functions inherited from tbb::internal::no_assign
void | operator= (const no_assign &)=delete
| no_assign (const no_assign &)=default
| no_assign ()=default

## Public Attributes

nodeptr_t | my_next
value_type | my_element
sokey_t | my_order_key

## Private Member Functions

| node ()

## Detailed Description

### template<typename T, typename Allocator>
struct tbb::interface5::internal::split_ordered_list< T, Allocator >::node

Definition at line 228 of file _concurrent_unordered_impl.h.

## Constructor & Destructor Documentation

## node()

template<typename T, typename Allocator>

tbb::interface5::internal::split_ordered_list< T, Allocator >::node::node | ( |  | ) |

private

## Member Function Documentation

## atomic_set_next()

template<typename T, typename Allocator>

nodeptr_t tbb::interface5::internal::split_ordered_list< T, Allocator >::node::atomic_set_next | ( | nodeptr_t | new_node,
|  | nodeptr_t | current_node
| ) |  |

inline

Definition at line 255 of file _concurrent_unordered_impl.h.

{
// Try to change the next pointer on the current element to a new element, only if it still points to the cached next
nodeptr_t exchange_node = tbb::internal::as_atomic(my_next).compare_and_swap(new_node, current_node);
if (exchange_node == current_node) // TODO: why this branch?
{
// Operation succeeded, return the new node
return new_node;
}
else
{
// Operation failed, return the "interfering" node
return exchange_node;
}
}

References tbb::internal::as_atomic(), and tbb::interface5::internal::split_ordered_list< T, Allocator >::node::my_next.

Referenced by tbb::interface5::internal::split_ordered_list< value_type, typename Traits::allocator_type >::try_insert_atomic().

Here is the call graph for this function:
Here is the caller graph for this function:

## get_order_key()

template<typename T, typename Allocator>

sokey_t tbb::interface5::internal::split_ordered_list< T, Allocator >::node::get_order_key | ( |  | ) | const

inline

Definition at line 241 of file _concurrent_unordered_impl.h.

{ // TODO: remove
return my_order_key;
}

References tbb::interface5::internal::split_ordered_list< T, Allocator >::node::my_order_key.

Referenced by tbb::interface5::internal::split_ordered_list< value_type, typename Traits::allocator_type >::get_order_key(), and tbb::interface5::internal::split_ordered_list< value_type, typename Traits::allocator_type >::get_safe_order_key().

Here is the caller graph for this function:

## init()

template<typename T, typename Allocator>

void tbb::interface5::internal::split_ordered_list< T, Allocator >::node::init | ( | sokey_t | order_key | ) |

inline

Definition at line 235 of file _concurrent_unordered_impl.h.

{
my_order_key = order_key;
my_next = NULL;
}

References tbb::interface5::internal::split_ordered_list< T, Allocator >::node::my_next, and tbb::interface5::internal::split_ordered_list< T, Allocator >::node::my_order_key.

## is_dummy()

template<typename T, typename Allocator>

bool tbb::interface5::internal::split_ordered_list< T, Allocator >::node::is_dummy | ( |  | ) | const

inline

Definition at line 274 of file _concurrent_unordered_impl.h.

{
return (my_order_key & 0x1) == 0;
}

References tbb::interface5::internal::split_ordered_list< T, Allocator >::node::my_order_key.

Referenced by tbb::interface5::internal::split_ordered_list< value_type, typename Traits::allocator_type >::first_real_iterator(), and tbb::interface5::internal::split_ordered_list< value_type, typename Traits::allocator_type >::get_iterator().

Here is the caller graph for this function:

## storage()

template<typename T, typename Allocator>

value_type* tbb::interface5::internal::split_ordered_list< T, Allocator >::node::storage | ( |  | ) |

inline

Definition at line 246 of file _concurrent_unordered_impl.h.

{
return reinterpret_cast<value_type*>(&my_element);
}

References tbb::interface5::internal::split_ordered_list< T, Allocator >::node::my_element.

Referenced by tbb::interface5::internal::split_ordered_list< T, Allocator >::node::value().

Here is the caller graph for this function:

## value()

template<typename T, typename Allocator>

value_type& tbb::interface5::internal::split_ordered_list< T, Allocator >::node::value | ( |  | ) |

inline

Definition at line 250 of file _concurrent_unordered_impl.h.

{
return *storage();
}

References tbb::interface5::internal::split_ordered_list< T, Allocator >::node::storage().

Here is the call graph for this function:

## Member Data Documentation

## my_element

template<typename T, typename Allocator>

value_type tbb::interface5::internal::split_ordered_list< T, Allocator >::node::my_element

Definition at line 280 of file _concurrent_unordered_impl.h.

Referenced by tbb::interface5::internal::split_ordered_list< T, Allocator >::node::storage().

## my_next

template<typename T, typename Allocator>

nodeptr_t tbb::interface5::internal::split_ordered_list< T, Allocator >::node::my_next

Definition at line 279 of file _concurrent_unordered_impl.h.

Referenced by tbb::interface5::internal::split_ordered_list< T, Allocator >::node::atomic_set_next(), tbb::interface5::internal::split_ordered_list< T, Allocator >::node::init(), and tbb::interface5::internal::split_ordered_list< value_type, typename Traits::allocator_type >::try_insert_atomic().

## my_order_key

template<typename T, typename Allocator>

sokey_t tbb::interface5::internal::split_ordered_list< T, Allocator >::node::my_order_key

Definition at line 281 of file _concurrent_unordered_impl.h.

Referenced by tbb::interface5::internal::split_ordered_list< T, Allocator >::node::get_order_key(), tbb::interface5::internal::split_ordered_list< T, Allocator >::node::init(), and tbb::interface5::internal::split_ordered_list< T, Allocator >::node::is_dummy().

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

- _concurrent_unordered_impl.h

tbb::interface5::internal::split_ordered_list::node::my_element
value_type my_element
Definition: _concurrent_unordered_impl.h:280
tbb::interface5::internal::split_ordered_list::node::storage
value_type * storage()
Definition: _concurrent_unordered_impl.h:246
tbb::interface5::internal::split_ordered_list::node::my_next
nodeptr_t my_next
Definition: _concurrent_unordered_impl.h:279
tbb::interface5::internal::split_ordered_list::nodeptr_t
node * nodeptr_t
Definition: _concurrent_unordered_impl.h:210
tbb::internal::as_atomic
atomic< T > & as_atomic(T &t)
Definition: atomic.h:572
tbb::interface5::internal::split_ordered_list::node::my_order_key
sokey_t my_order_key
Definition: _concurrent_unordered_impl.h:281

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.