Home
last modified time | relevance | path

Searched refs:state (Results 1 – 25 of 43) sorted by relevance

12

/oneTBB/test/common/
H A Dstate_trackable.h45 assign_new_state(s.state); in State()
65 StateValue state; member
98 state = s; in assign_new_state()
107 … return state == DefaultInitialized || state == DirectInitialized || state == CopyInitialized || in is_valid()
108state == MoveInitialized || state == CopyAssigned || state == MoveAssigned || state == MovedFrom || in is_valid()
121 src.state = MovedFrom; in StateTrackable()
127 state = CopyAssigned;
134 state = MoveAssigned;
135 src.state = MovedFrom;
141 state = Destroyed; in ~StateTrackable()
[all …]
/oneTBB/examples/graph/logic_sim/
H A Dbasics.hpp333 signal_t state; member in toggle
358 state = low; in activate()
368 signal_t state; member in buffer::buffer_body
422 signal_t state; member in and_gate::and_body
466 signal_t state; member in or_gate::or_body
510 signal_t state; member in xor_gate::xor_body
561 signal_t state; member in nor_gate::nor_body
632 signal_t state; member in led
670 return state; in get_value()
732 state = 0; in operator =()
[all …]
/oneTBB/src/tbb/
H A Dtask_group_context.cpp81 ctx.my_state.store(d1::task_group_context::state::dead, std::memory_order_release); in destroy()
166 d1::task_group_context::state state = ctx.my_state.load(std::memory_order_acquire); in bind_to() local
167 if (state <= d1::task_group_context::state::locked) { in bind_to()
168 if (state == d1::task_group_context::state::created && in bind_to()
171 (typename std::underlying_type<d1::task_group_context::state>::type&)state, in bind_to()
172 …(typename std::underlying_type<d1::task_group_context::state>::type)d1::task_group_context::state:… in bind_to()
174 ctx.my_state.compare_exchange_strong(state, d1::task_group_context::state::locked) in bind_to()
181 d1::task_group_context::state release_state{}; in bind_to()
186 release_state = d1::task_group_context::state::isolated; in bind_to()
189 release_state = d1::task_group_context::state::bound; in bind_to()
[all …]
H A Darena.h145 std::uintptr_t state = my_state.load(std::memory_order_acquire); in test_and_set() local
146 switch (state) { in test_and_set()
150 if (my_state.compare_exchange_strong(state, SET)) { in test_and_set()
154 if (state != UNSET) { in test_and_set()
161 return my_state.compare_exchange_strong(state, SET); in test_and_set()
167 std::uintptr_t state = my_state.load(std::memory_order_acquire); in try_clear_if() local
168 if (state == SET && my_state.compare_exchange_strong(state, busy)) { in try_clear_if()
H A Dprivate_server.cpp285 state_t state = my_state.load(std::memory_order_relaxed); in wake_or_launch() local
287 switch (state) { in wake_or_launch()
295 if (my_state.compare_exchange_strong(state, st_starting)) { in wake_or_launch()
309 state = st_starting; in wake_or_launch()
310 if (!my_state.compare_exchange_strong(state, st_normal)) { in wake_or_launch()
314 __TBB_ASSERT(state == st_quit, nullptr); in wake_or_launch()
320 __TBB_ASSERT(state == st_quit, nullptr); in wake_or_launch()
H A Dtcm.h78 tcm_permit_state_t state; member
/oneTBB/examples/migration/recursive_fibonacci/
H A Dfibonacci_single_task.h34 enum class state { enum
39 single_fib_task(int n, int* x) : n(n), x(x), s(state::compute) in single_fib_task()
45 case state::compute : { in execute()
49 case state::sum : { in execute()
75 this->s = state::sum; in compute_impl()
84 state s;
/oneTBB/include/oneapi/tbb/
H A Dcollaborative_call_once.h132 enum state : std::uintptr_t { enum
139 std::atomic<std::uintptr_t> m_state{ state::uninitialized };
161 …if (expected == state::uninitialized && m_state.compare_exchange_strong(expected, runner.to_bits()… in do_collaborative_call_once()
168 set_completion_state(runner.to_bits(), state::uninitialized); in do_collaborative_call_once()
171 set_completion_state(runner.to_bits(), state::done); in do_collaborative_call_once()
182 … } while (expected > state::done && !m_state.compare_exchange_strong(expected, expected + 1)); in do_collaborative_call_once()
193 __TBB_ASSERT(m_state.load(std::memory_order_relaxed) != state::dead, in do_collaborative_call_once()
195 } while (expected != state::done); in do_collaborative_call_once()
201 m_state.store(state::dead, std::memory_order_relaxed); in ~collaborative_once_flag()
H A Dtask_scheduler_observer.h39 TBB_EXPORT void __TBB_EXPORTED_FUNC observe(d1::task_scheduler_observer&, bool state = true);
99 void observe(bool state = true) {
100 if( state && !my_proxy.load(std::memory_order_relaxed) ) {
103 r1::observe(*this, state);
H A Dtask_group.h208 enum class state : std::uint8_t { enum
218 std::atomic<state> my_state;
255 - sizeof(std::atomic<state>) // my_state
273 , my_state{state::proxy}
293 return my_state.load(std::memory_order_relaxed) == state::proxy; in is_proxy()
/oneTBB/test/conformance/
H A Dconformance_concurrent_queue.cpp282 state_type state; member in Bar
299 state = DEAD; in ~Bar()
361 state_type state; member in BarEx
390 state = DEAD; in ~BarEx()
792 state_type state; member in FooEx
812 state=DEAD; in ~FooEx()
1218 state = DEAD; in ~allocator()
1757 int state = 0; member
1780 alloc1.state = 0; in TestMoveQueueUnequal()
1781 alloc2.state = 1; in TestMoveQueueUnequal()
[all …]
H A Dconformance_combinable.cpp392 REQUIRE_MESSAGE(create1.local().state == StateTrackable<true>::DefaultInitialized, in RunMoveSemanticsForStateTrackableObjectTest()
397 REQUIRE_MESSAGE(copy1.local().state == StateTrackable<true>::CopyInitialized, in RunMoveSemanticsForStateTrackableObjectTest()
402 REQUIRE_MESSAGE(copy2.local().state == StateTrackable<true>::DefaultInitialized, in RunMoveSemanticsForStateTrackableObjectTest()
405 REQUIRE_MESSAGE(copy2.local().state == StateTrackable<true>::CopyInitialized, in RunMoveSemanticsForStateTrackableObjectTest()
409 create1.local().state = StateTrackableBase::Unspecified; in RunMoveSemanticsForStateTrackableObjectTest()
413 …REQUIRE_MESSAGE(move1.local().state == StateTrackableBase::Unspecified, "Unexpected value in move-… in RunMoveSemanticsForStateTrackableObjectTest()
417 …REQUIRE_MESSAGE(copy1.local().state == StateTrackableBase::Unspecified, "Unexpected value in move-… in RunMoveSemanticsForStateTrackableObjectTest()
420 copy1.local().state = StateTrackable<true>::MoveAssigned; in RunMoveSemanticsForStateTrackableObjectTest()
H A Dconformance_parallel_for.cpp93 FooBody( const FooBody& other ) : array(other.array), state(other.state) { in FooBody()
95 CHECK_FAST(state == LIVE); in FooBody()
106 int state; member in FooBody
109 FooBody( std::atomic<int>* array_ ) : array(array_), state(LIVE) {} in FooBody()
/oneTBB/include/oneapi/tbb/detail/
H A D_utils.h268 void atomic_do_once( const F& initializer, std::atomic<do_once_state>& state ) { in atomic_do_once() argument
275 while ( state.load( std::memory_order_acquire ) != do_once_state::executed ) { in atomic_do_once()
276 if( state.load( std::memory_order_relaxed ) == do_once_state::uninitialized ) { in atomic_do_once()
280 …if( ((std::atomic<enum_type>&)state).compare_exchange_strong( (enum_type&)expected_state, (enum_ty… in atomic_do_once()
282 if( state.compare_exchange_strong( expected_state, do_once_state::pending ) ) { in atomic_do_once()
284 run_initializer( initializer, state ); in atomic_do_once()
288 spin_wait_while_eq( state, do_once_state::pending ); in atomic_do_once()
294 void run_initializer(const Functor& f, std::atomic<do_once_state>& state ) { in atomic_do_once() argument
296 state.store(do_once_state::executed, std::memory_order_release); in atomic_do_once()
/oneTBB/examples/graph/fgbzip2/
H A Dbzlib.cpp224 s->state = BZ_S_INPUT; in BZ_API()
237 strm->state = s; in BZ_API()
440 s = (EState*)strm->state; in BZ_API()
500 s = (EState*)strm->state; in BZ_API()
512 BZFREE(strm->state); in BZ_API()
514 strm->state = nullptr; in BZ_API()
546 strm->state = s; in BZ_API()
547 s->state = BZ_X_MAGIC_1; in BZ_API()
924 s = (DState*)strm->state; in BZ_API()
996 BZFREE(strm->state); in BZ_API()
[all …]
H A Ddecompress.cpp91 s->state = lll; \
179 if (s->state == BZ_X_MAGIC_1) { in BZ2_decompress()
235 switch (s->state) { in BZ2_decompress()
599 s->state = BZ_X_OUTPUT; in BZ2_decompress()
692 s->state = BZ_X_IDLE; in BZ2_decompress()
H A Dbzlib_private.hpp245 Int32 state; member
379 Int32 state; member
/oneTBB/doc/main/tbb_userguide/
H A Duse_input_node.rst7 By default, an ``input_node`` is constructed in the inactive state:
28 All ``input_node`` objects are constructed in the inactive state and usually
33 the ``input_node`` is constructed in the inactive state and activated after
49 In this example, if the ``input_node`` was toggled to the active state at the beginning,
56 state and then activate them after the whole graph is constructed.
H A DFlow_Graph_Message_Passing_Protocol.rst10 if this occurs the state of the edge between the nodes can change its
11 state to pull so when the successor is able to handle a message it can
28 The state diagram of this Push-Pull protocol is:
H A DFlow_Graph_Reservation.rst23 - When a node connected to a reserving ``join_node`` in push state
27 state. This may fail; if so, the reserving input port switches that
28 edge to push state, and tries to reserve the next node connected by
29 an edge in pull state. While the input port's predecessor is in
30 reserved state, no other node can retrieve the reserved value.
31 - If each input port successfully reserves an edge in pull state, the
46 input port has at least one edge in a pull state, and will only attempt
237 to ``jn`` is in push state.
H A Duse_graph_reset.rst9 graph and its nodes may be left in an indeterminate state. For example,
13 can leave its nodes and edges in an indeterminate state. If you want to
/oneTBB/test/tbb/
H A Dtest_scheduler_mix.cpp109 return reinterpret_cast<T*>(state() & ~LOCKED_MASK); in pointer()
112 std::uintptr_t state() { in state() function in PtrRWMutex
182 if (!state()) { in trySet()
192 CHECK_FAST((state() & LOCKED_MASK) == LOCKED); in clear()
197 auto v = state(); in tryLock()
211 auto v = state(); in tryLockShared()
225 auto v = state(); in lock()
233 auto v = state(); in unlock()
239 auto v = state(); in unlockShared()
H A Dtest_mutex.h154 State& state; member
156 Work( State& st ) : state(st){ Order = 0; } in Work()
162 state.flog_once(step); in operator()
/oneTBB/python/rml/
H A Dipc_server.cpp565 state_t state = my_state.load(std::memory_order_acquire); in run() local
566 while( state!=st_quit && state!=st_stop ) { in run()
571 state = my_state.load(std::memory_order_seq_cst); in run()
572 if( state!=st_quit && state!=st_stop && my_server.try_insert_in_asleep_list(*this) ) { in run()
579 state = my_state.load(std::memory_order_seq_cst); in run()
/oneTBB/src/tbb/tools_api/
H A Dittnotify_config.h448 __itt_thread_state state; /*!< Thread state (paused or normal) */ member
520 __itt_collection_state state; member
535 h->state = s; \
554 h->state = s; \

12