Lines Matching defs:thread
13 #include <lib/zx/thread.h>
36 // This function starts a new thread to perform the read/write test, and catches any exceptions
37 // in this thread to see if it failed or not.
38 zx::thread thread;
39 zx_status_t status = zx::thread::create(*zx::process::self(), "memory_probe", 12u, 0u, &thread);
51 // Cause the port to be signaled with kThreadKey when the background thread crashes or teminates without crashing.
53 if (thread.wait_async(port, kThreadKey, ZX_THREAD_TERMINATED, ZX_WAIT_ASYNC_ONCE) != ZX_OK) {
56 if (zx_task_bind_exception_port(thread.get(), port.get(), kThreadKey, 0) != ZX_OK) {
60 thread.start(&except_thread_func, stack, static_cast<uintptr_t>(op), reinterpret_cast<uintptr_t>(addr));
62 // Wait for crash or thread completion.
66 // Thread crashed so the operation failed. The thread is now in a suspended state and
68 thread.kill();