/third_party/vk-gl-cts/framework/delibs/deutil/ |
H A D | deTimer.c | 277 /* Generic thread-based implementation for OSes that lack proper timers. */ 297 deThread thread; /*!< Thread. */ member 308 deTimerThread* curThread; /*!< Current timer thread. */ 313 deTimerThread* thread = (deTimerThread*)arg; in timerThread() local 322 deMutex_lock(thread->lock); in timerThread() 324 if (thread->state == TIMERSTATE_SINGLE && numCallbacks > 0) in timerThread() 327 thread->state = TIMERSTATE_DISABLED; in timerThread() 330 else if (thread->state == TIMERSTATE_DISABLED) in timerThread() 333 deMutex_unlock(thread->lock); in timerThread() 335 sleepTime = thread in timerThread() 357 deTimerThread* thread = (deTimerThread*)deCalloc(sizeof(deTimerThread)); deTimerThread_create() local [all...] |
/third_party/pulseaudio/src/pulsecore/ |
H A D | thread-win32.c | 31 #include "thread.h" 34 HANDLE thread; member 45 HANDLE thread; member 81 t->thread = CreateThread(NULL, 0, internal_thread_func, t, 0, &thread_id); in pa_thread_new() 83 if (!t->thread) { in pa_thread_new() 96 if (!GetExitCodeThread(t->thread, &code)) in pa_thread_is_running() 106 CloseHandle(t->thread); in pa_thread_free() 113 CloseHandle(t->thread); in pa_thread_free_nojoin() 120 if (WaitForSingleObject(t->thread, INFINITE) == WAIT_FAILED) in pa_thread_join() 160 WaitForSingleObject(m->thread, INFINIT in monitor_thread_func() 219 HANDLE thread; pa_tls_set() local [all...] |
/third_party/ffmpeg/compat/ |
H A D | os2threads.h | 75 pthread_t *thread = arg; in thread_entry() local 77 thread->result = thread->start_routine(thread->arg); in thread_entry() 80 static av_always_inline int pthread_create(pthread_t *thread, in pthread_create() argument 85 thread->start_routine = start_routine; in pthread_create() 86 thread->arg = arg; in pthread_create() 87 thread->result = NULL; in pthread_create() 89 thread->tid = _beginthread(thread_entry, NULL, 1024 * 1024, thread); in pthread_create() 94 pthread_join(pthread_t thread, void **value_ptr) pthread_join() argument [all...] |
H A D | w32pthreads.h | 76 static av_unused int pthread_create(pthread_t *thread, const void *unused_attr, in pthread_create() argument 79 thread->func = start_routine; in pthread_create() 80 thread->arg = arg; in pthread_create() 82 thread->handle = (void*)CreateThread(NULL, 0, win32thread_worker, thread, in pthread_create() 85 thread->handle = (void*)_beginthreadex(NULL, 0, win32thread_worker, thread, in pthread_create() 88 return !thread->handle; in pthread_create() 91 static av_unused int pthread_join(pthread_t thread, void **value_ptr) in pthread_join() argument 93 DWORD ret = WaitForSingleObject(thread in pthread_join() [all...] |
/third_party/vk-gl-cts/modules/egl/ |
H A D | teglGLES2SharingThreadedTests.cpp | 201 // EGL thread with thread specifig state 259 void init (EGLThread& thread, bool serverSync); 260 bool waitReady (EGLThread& thread); 291 void FenceSync::init (EGLThread& thread, bool serverSync) in init() argument 293 m_display = thread.runtimeContext->display; in init() 300 thread.newMessage() << "Begin -- eglCreateSyncKHR(" << ((size_t)m_display) << ", EGL_SYNC_FENCE_KHR, DE_NULL)" << tcu::ThreadUtil::Message::End; in init() 301 m_sync = thread.egl.createSyncKHR(m_display, EGL_SYNC_FENCE_KHR, DE_NULL); in init() 302 thread.newMessage() << "End -- " << ((size_t)m_sync) << " = eglCreateSyncKHR()" << tcu::ThreadUtil::Message::End; in init() 308 bool FenceSync::waitReady (EGLThread& thread) in waitReady() argument 448 EGLThread& thread = dynamic_cast<EGLThread&>(t); execute() local 599 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 652 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 674 MakeCurrent(EGLThread& thread, EGLDisplay display, SharedPtr<Surface> surface, SharedPtr<GLES2Context> context) MakeCurrent() argument 704 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 745 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 818 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 853 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 906 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 935 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 980 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1032 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1085 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1136 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1191 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1220 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1257 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1298 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1357 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1387 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1419 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1447 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1498 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1528 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1567 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1615 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1655 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1685 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1755 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1863 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1903 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1962 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local 1997 EGLThread& thread = dynamic_cast<EGLThread&>(t); exec() local [all...] |
H A D | teglMultiThreadTests.cpp | 147 virtual bool runThread (TestThread& thread) = 0; 149 void execTest (TestThread& thread); 214 void MultiThreadedTest::execTest (TestThread& thread) in execTest() argument 218 if (!runThread(thread)) in execTest() 223 // Thread exited due to error in other thread in execTest() 323 // Barrier was released due an error in other thread in barrier() 519 bool runThread (TestThread& thread); 535 bool MultiThreadedConfigTest::runThread (TestThread& thread) in runThread() argument 538 de::Random rnd (deInt32Hash(thread.getId() + 10435)); in runThread() 552 thread in runThread() 902 runThread(TestThread& thread) runThread() argument 983 createDestroyObjects(TestThread& thread, int count) createDestroyObjects() argument 1264 pushObjectsToShared(TestThread& thread) pushObjectsToShared() argument 1292 pullObjectsFromShared(TestThread& thread, int pbufferCount, int pixmapCount, int windowCount, int contextCount) pullObjectsFromShared() argument 1333 querySetSharedObjects(TestThread& thread, int count) querySetSharedObjects() argument 1421 destroyObjects(TestThread& thread) destroyObjects() argument [all...] |
/third_party/json/tests/thirdparty/Fuzzer/test/ |
H A D | SimpleThreadedTest.cpp | 10 #include <thread> 19 std::thread T[] = {std::thread(C), std::thread(C), std::thread(C), in LLVMFuzzerTestOneInput() 20 std::thread(C), std::thread(C), std::thread(C)}; in LLVMFuzzerTestOneInput()
|
H A D | ThreadedTest.cpp | 9 #include <thread> 20 std::thread T[] = {std::thread(C), std::thread(C), std::thread(C), in LLVMFuzzerTestOneInput() 21 std::thread(C), std::thread(C), std::thread(C)}; in LLVMFuzzerTestOneInput()
|
/third_party/alsa-utils/alsaloop/ |
H A D | test.sh | 25 -C hw:1,0,0 -P hw:0,0,0 --tlatency 50000 --thread 1 \ 30 -C hw:1,0,1 -P hw:0,1,0 --tlatency 50000 --thread 2 39 -C hw:1,0,0 -P plug:dmix:0 --tlatency $LATENCY --thread 0 \ 44 -C hw:1,0,1 -P plug:dmix:0 --tlatency $LATENCY --thread 1 45 -C hw:1,0,2 -P plug:dmix:0 --tlatency $LATENCY --thread 2 46 -C hw:1,0,3 -P plug:dmix:0 --tlatency $LATENCY --thread 3 47 -C hw:1,0,4 -P plug:dmix:0 --tlatency $LATENCY --thread 4 48 -C hw:1,0,5 -P plug:dmix:0 --tlatency $LATENCY --thread 5 49 -C hw:1,0,6 -P plug:dmix:0 --tlatency $LATENCY --thread 6 50 -C hw:1,0,7 -P plug:dmix:0 --tlatency $LATENCY --thread [all...] |
/third_party/skia/third_party/externals/angle2/src/libGL/ |
H A D | entry_points_wgl.cpp | 109 Thread *thread = egl::GetCurrentThread(); in wglSwapBuffers() local 112 ANGLE_EGL_TRY_RETURN(thread, display->getWGLSurface()->swap(thread->getContext()), in wglSwapBuffers() 125 Thread *thread = egl::GetCurrentThread(); in wglCreateContext() local 137 ANGLE_EGL_TRY_RETURN(thread, display->initialize(), "wglCreateContext", display, nullptr); in wglCreateContext() 139 thread->setAPI(EGL_OPENGL_API); in wglCreateContext() 161 thread, in wglCreateContext() 174 ANGLE_EGL_TRY_RETURN(thread, in wglCreateContext() 227 egl::Thread *thread = egl::GetCurrentThread(); in wglGetProcAddress() local 232 thread in wglGetProcAddress() 244 Thread *thread = egl::GetCurrentThread(); wglMakeCurrent() local [all...] |
/third_party/python/Lib/test/ |
H A D | test_threadsignals.py | 8 import _thread as thread namespace 15 signalled_all=thread.allocate_lock() 31 signal_blackboard[sig]['tripped_by'] = thread.get_ident() 33 # a function that will be spawned as a separate thread. 47 # We spawn a thread, have the thread send two signals, and 49 # and that they were run by the main thread. 56 # (it might even be after the thread exits 70 thread.get_ident()) 73 thread [all...] |
H A D | test_threading.py | 31 # #12316 and #11870), and fork() from a worker thread is known to trigger 104 thread = threading.Thread(name="myname1") 105 self.assertEqual(thread.name, "myname1") 108 thread = threading.Thread(name=123) 109 self.assertEqual(thread.name, "123") 112 thread = threading.Thread(target=func, name="myname2") 113 self.assertEqual(thread.name, "myname2") 116 thread = threading.Thread(name="") 117 self.assertEqual(thread.name, "Thread-2") 120 thread 1491 thread = ThreadExit() global() variable in ExceptHookTests.test_system_exit.ThreadExit [all...] |
/third_party/icu/ohos_icu4j/src/main/tests/ohos/global/icu/dev/test/lang/ |
H A D | UCharacterThreadTest.java | 52 GetNameThread thread = new GetNameThread(codePoint, correctName); in TestUCharactersGetName() 53 thread.start(); in TestUCharactersGetName() 54 threads.add(thread); in TestUCharactersGetName() 58 GetNameThread thread = (GetNameThread)i.next(); in TestUCharactersGetName() 59 thread.join(); in TestUCharactersGetName() 60 if (!thread.correctName.equals(thread.actualName)) { in TestUCharactersGetName() 61 errln("FAIL, expected \"" + thread.correctName + "\", got \"" + thread.actualName + "\""); in TestUCharactersGetName()
|
/third_party/icu/icu4j/main/tests/core/src/com/ibm/icu/dev/test/lang/ |
H A D | UCharacterThreadTest.java | 49 GetNameThread thread = new GetNameThread(codePoint, correctName); in TestUCharactersGetName() 50 thread.start(); in TestUCharactersGetName() 51 threads.add(thread); in TestUCharactersGetName() 55 GetNameThread thread = (GetNameThread)i.next(); in TestUCharactersGetName() 56 thread.join(); in TestUCharactersGetName() 57 if (!thread.correctName.equals(thread.actualName)) { in TestUCharactersGetName() 58 errln("FAIL, expected \"" + thread.correctName + "\", got \"" + thread.actualName + "\""); in TestUCharactersGetName()
|
/third_party/ltp/testcases/kernel/syscalls/tgkill/ |
H A D | tgkill01.c | 5 * tgkill() delivers a signal to a specific thread. Test this by installing 19 pthread_t thread; member 36 struct thread_state *thread = arg; in thread_func() local 43 thread->tid = sys_gettid(); in thread_func() 52 static void start_thread(struct thread_state *thread) in start_thread() argument 54 SAFE_PTHREAD_CREATE(&thread->thread, NULL, thread_func, thread); in start_thread() 69 SAFE_PTHREAD_JOIN(threads[i].thread, NULL); in stop_threads() 93 if (!pthread_equal(sigusr1_thread, threads[i].thread)) { in run() [all...] |
/third_party/libuv/test/ |
H A D | test-condvar.c | 126 /* uv_cond_wait: One thread signals, the other waits. */ 129 uv_thread_t thread; in TEST_IMPL() local 133 ASSERT_OK(uv_thread_create(&thread, worker, &wc)); in TEST_IMPL() 139 ASSERT_OK(uv_thread_join(&thread)); in TEST_IMPL() 145 /* uv_cond_wait: One thread broadcasts, the other waits. */ 148 uv_thread_t thread; in TEST_IMPL() local 152 ASSERT_OK(uv_thread_create(&thread, worker, &wc)); in TEST_IMPL() 158 ASSERT_OK(uv_thread_join(&thread)); in TEST_IMPL() 190 /* uv_cond_timedwait: One thread signals, the other timedwaits. */ 193 uv_thread_t thread; in TEST_IMPL() local 212 uv_thread_t thread; TEST_IMPL() local [all...] |
H A D | test-barrier.c | 50 uv_thread_t thread; in TEST_IMPL() local 57 ASSERT_OK(uv_thread_create(&thread, worker, &wc)); in TEST_IMPL() 62 ASSERT_OK(uv_thread_join(&thread)); in TEST_IMPL() 72 uv_thread_t thread; in TEST_IMPL() local 80 ASSERT_OK(uv_thread_create(&thread, worker, &wc)); in TEST_IMPL() 84 ASSERT_OK(uv_thread_join(&thread)); in TEST_IMPL() 94 uv_thread_t thread; in TEST_IMPL() local 102 ASSERT_OK(uv_thread_create(&thread, worker, &wc)); in TEST_IMPL() 107 ASSERT_OK(uv_thread_join(&thread)); in TEST_IMPL() 152 /* Single thread uv_barrier_wai [all...] |
/third_party/skia/third_party/externals/angle2/src/tests/gl_tests/ |
H A D | MultithreadingTest.cpp | 17 #include <thread> 69 std::vector<std::thread> threads(threadCount); in runMultithreadedGLTest() 72 threads[threadIdx] = std::thread([&, threadIdx]() { in runMultithreadedGLTest() 109 for (std::thread &thread : threads) in runMultithreadedGLTest() 111 thread.join(); in runMultithreadedGLTest() 182 std::array<std::thread, kThreadCount> threads; in TEST_P() 183 for (std::thread &thread : threads) in TEST_P() 185 thread in TEST_P() 768 std::thread thread = std::thread([&]() { global() local [all...] |
/third_party/skia/third_party/externals/sfntly/cpp/src/test/ |
H A D | lock_test.cc | 63 BasicLockTestThread thread(&lock); in BasicLockTest() 66 EXPECT_TRUE(PlatformThread::Create(&thread, &handle)); in BasicLockTest() 97 EXPECT_GE(thread.acquired(), 20); in BasicLockTest() 129 // This thread will not be able to get the lock. in TryLockTest() 131 TryLockTestThread thread(&lock); in TryLockTest() 134 EXPECT_TRUE(PlatformThread::Create(&thread, &handle)); in TryLockTest() 138 EXPECT_FALSE(thread.got_lock()); in TryLockTest() 143 // This thread will.... in TryLockTest() 145 TryLockTestThread thread(&lock); in TryLockTest() 148 EXPECT_TRUE(PlatformThread::Create(&thread, in TryLockTest() [all...] |
/third_party/musl/porting/liteos_a/user/src/thread/ |
H A D | pthread_clone.c | 13 int __thread_clone(int (*func)(void *), int flags, struct pthread *thread, unsigned char *sp) in __thread_clone() argument 19 if (thread->detach_state == DT_JOINABLE) { in __thread_clone() 23 param.user_area = TP_ADJ(thread); in __thread_clone() 25 param.map_base = thread->map_base; in __thread_clone() 26 param.map_size = thread->map_size; in __thread_clone() 32 thread->tid = (unsigned long)ret; in __thread_clone()
|
/third_party/musl/src/thread/liteos_a/ |
H A D | pthread_clone.c | 28 int __thread_clone(int (*func)(void *), int flags, struct pthread *thread, unsigned char *sp) in __thread_clone() argument 34 if (thread->detach_state == DT_JOINABLE) { in __thread_clone() 38 param.user_area = TP_ADJ(thread); in __thread_clone() 40 param.map_base = thread->map_base; in __thread_clone() 41 param.map_size = thread->map_size; in __thread_clone() 47 thread->tid = (unsigned long)ret; in __thread_clone()
|
/third_party/ltp/testcases/kernel/syscalls/nice/ |
H A D | nice05.c | 11 * 1. Create a high nice thread and a low nice thread, the main 12 * thread wake them at the same time 14 * 3. Verify that the low nice thread executes more time than 15 * the high nice thread 108 pthread_t thread[2]; in verify_nice() local 112 SAFE_PTHREAD_CREATE(&thread[0], NULL, thread_fn, in verify_nice() 114 SAFE_PTHREAD_CREATE(&thread[1], NULL, thread_fn, in verify_nice() 121 TEST(pthread_getcpuclockid(thread[1], &nice_low_clockid)); in verify_nice() 125 TEST(pthread_getcpuclockid(thread[ in verify_nice() [all...] |
/third_party/python/Lib/ |
H A D | _threading_local.py | 8 Thread-local objects support the management of thread-local data. 9 If you have data that you want to be local to a thread, simply create 10 a thread-local object and use its attributes: 26 What's important about thread-local objects is that their data are 27 local to a thread. If we access the data in a different thread: 37 >>> thread = threading.Thread(target=f) 38 >>> thread.start() 39 >>> thread.join() 43 we get different data. Furthermore, changes made in the other thread [all...] |
/third_party/skia/third_party/externals/swiftshader/third_party/marl/src/ |
H A D | non_marl_bench.cpp | 25 #include <thread> 53 // A simple multi-thread, single-queue task executor that shares a single mutex 98 std::vector<std::thread> threads; in SingleQueueTaskExecutor() 100 threads.emplace_back(std::thread(taskRunner)); in SingleQueueTaskExecutor() 108 for (auto& thread : threads) { in SingleQueueTaskExecutor() 109 thread.join(); in SingleQueueTaskExecutor() 119 // A simple multi-thread, multi-queue task executor that avoids lock contention. 142 std::vector<std::thread> threads; in MultiQueueTaskExecutor() 144 threads.emplace_back(std::thread([&, i] { in MultiQueueTaskExecutor() 156 for (auto& thread in MultiQueueTaskExecutor() [all...] |
/third_party/vk-gl-cts/framework/delibs/dethread/win32/ |
H A D | deThreadWin32.c | 21 * \brief Win32 implementation of thread management. 74 HANDLE thread = 0; in deThread_create() local 82 thread = CreateThread(DE_NULL, 0, startThread, entry, 0, DE_NULL); in deThread_create() 83 if (!thread) in deThread_create() 90 SetThreadPriority(thread, mapPriority(attributes->priority)); in deThread_create() 92 return (deThread)thread; in deThread_create() 95 deBool deThread_join (deThread thread) in deThread_join() argument 97 HANDLE handle = (HANDLE)thread; in deThread_join() 103 void deThread_destroy (deThread thread) in deThread_destroy() argument 105 HANDLE handle = (HANDLE)thread; in deThread_destroy() [all...] |