void execute_on_thread( HostThread & this_thread ) const { std::pair<Host::size_type,Host::size_type> range = this_thread.work_range( output.dimension_0() ); for ( Host::size_type i0 = range.first ; i0 < range.second ; ++i0 ) { output(i0) = input(i0); } this_thread.barrier(); }
void execute_on_thread( HostThread & this_thread ) const { std::pair<Host::size_type,Host::size_type> range = this_thread.work_range( output.dimension_0() ); for ( Host::size_type i0 = range.first ; i0 < range.second ; ++i0 ) { for ( Host::size_type i1 = 0 ; i1 < output.dimension_1() ; ++i1 ) { for ( Host::size_type i2 = 0 ; i2 < output.dimension_2() ; ++i2 ) { output(i0,i1,i2) = input(i0,i1,i2); }}} this_thread.barrier(); }
void ProcessWindows::OnCreateThread(const HostThread &new_thread) { llvm::sys::ScopedLock lock(m_mutex); const HostThreadWindows &wnew_thread = new_thread.GetNativeThread(); m_session_data->m_new_threads[wnew_thread.GetThreadId()] = new_thread; }
void execute_on_thread( HostThread & this_thread ) const { std::pair<Host::size_type,Host::size_type> range = this_thread.work_range( output.dimension_0() ); for ( Host::size_type i0 = range.first ; i0 < range.second ; ++i0 ) { for ( Host::size_type i1 = 0 ; i1 < output.dimension_1() ; ++i1 ) { for ( Host::size_type i2 = 0 ; i2 < output.dimension_2() ; ++i2 ) { for ( Host::size_type i3 = 0 ; i3 < output.dimension_3() ; ++i3 ) { for ( Host::size_type i4 = 0 ; i4 < output.dimension_4() ; ++i4 ) { for ( Host::size_type i5 = 0 ; i5 < output.dimension_5() ; ++i5 ) { for ( Host::size_type i6 = 0 ; i6 < output.dimension_6() ; ++i6 ) { output(i0,i1,i2,i3,i4,i5,i6) = input(i0,i1,i2,i3,i4,i5,i6); }}}}}}} this_thread.barrier(); }
void ProcessWindows::OnExitThread(const HostThread &exited_thread) { llvm::sys::ScopedLock lock(m_mutex); // A thread may have started and exited before the debugger stopped allowing a refresh. // Just remove it from the new threads list in that case. const HostThreadWindows &wexited_thread = exited_thread.GetNativeThread(); auto iter = m_session_data->m_new_threads.find(wexited_thread.GetThreadId()); if (iter != m_session_data->m_new_threads.end()) m_session_data->m_new_threads.erase(iter); else m_session_data->m_exited_threads[wexited_thread.GetThreadId()] = exited_thread; }