Searched refs:thread (Results 1 - 14 of 14) sorted by relevance

/bionic/libc/bionic/
H A Dpthread_detach.cpp34 pthread_accessor thread(t);
35 if (thread.get() == NULL) {
39 if (thread->attr.flags & PTHREAD_ATTR_FLAG_DETACHED) {
43 if (thread->attr.flags & PTHREAD_ATTR_FLAG_JOINED) {
47 if (thread->tid == 0) {
49 _pthread_internal_remove_locked(thread.get());
53 thread->attr.flags |= PTHREAD_ATTR_FLAG_DETACHED;
H A Dpthread_join.cpp42 pthread_accessor thread(t);
43 if (thread.get() == NULL) {
47 if ((thread->attr.flags & PTHREAD_ATTR_FLAG_DETACHED) != 0) {
51 if ((thread->attr.flags & PTHREAD_ATTR_FLAG_JOINED) != 0) {
56 thread->attr.flags |= PTHREAD_ATTR_FLAG_JOINED;
57 tid = thread->tid;
58 tid_ptr = &thread->tid;
62 // so no one is going to remove this thread except us.
64 // Wait for the thread to actually exit, if it hasn't already.
69 // Take the lock again so we can pull the thread'
[all...]
H A Dpthread_create.cpp52 // This code is used both by each new pthread and the code that initializes the main thread.
53 void __init_tls(pthread_internal_t* thread) { argument
54 if (thread->user_allocated_stack()) {
56 memset(&thread->tls[0], 0, BIONIC_TLS_SLOTS * sizeof(void*));
60 thread->tls[TLS_SLOT_SELF] = thread->tls;
61 thread->tls[TLS_SLOT_THREAD_ID] = thread;
63 thread->tls[TLS_SLOT_STACK_GUARD] = (void*) __stack_chk_guard;
66 void __init_alternate_signal_stack(pthread_internal_t* thread) { argument
78 __init_thread(pthread_internal_t* thread, bool add_to_thread_list) argument
104 __create_thread_stack(pthread_internal_t* thread) argument
130 pthread_internal_t* thread = reinterpret_cast<pthread_internal_t*>(arg); local
161 pthread_internal_t* thread = reinterpret_cast<pthread_internal_t*>(calloc(sizeof(*thread), 1)); local
[all...]
H A Dpthread_internals.cpp38 void _pthread_internal_remove_locked(pthread_internal_t* thread) { argument
39 if (thread->next != NULL) {
40 thread->next->prev = thread->prev;
42 if (thread->prev != NULL) {
43 thread->prev->next = thread->next;
45 g_thread_list = thread->next;
48 // The main thread is not heap-allocated. See __libc_init_tls for the declaration,
49 // and __libc_init_common for the point where it's added to the thread lis
55 _pthread_internal_add(pthread_internal_t* thread) argument
[all...]
H A Dpthread_exit.cpp42 * and thread cancelation
46 pthread_internal_t* thread = __get_thread(); local
49 c->__cleanup_prev = thread->cleanup_stack;
50 thread->cleanup_stack = c;
54 pthread_internal_t* thread = __get_thread(); local
55 thread->cleanup_stack = c->__cleanup_prev;
62 pthread_internal_t* thread = __get_thread(); local
63 thread->return_value = return_value;
66 while (thread->cleanup_stack) {
67 __pthread_cleanup_t* c = thread
[all...]
H A Dpthread_getschedparam.cpp37 pthread_accessor thread(t);
38 if (thread.get() == NULL) {
42 int rc = sched_getparam(thread->tid, param);
46 *policy = sched_getscheduler(thread->tid);
H A Dpthread_kill.cpp40 pthread_accessor thread(t);
41 if (thread.get() == NULL) {
46 pid_t tid = thread->tid;
47 thread.Unlock();
H A Dpthread_getcpuclockid.cpp34 pthread_accessor thread(t);
35 if (thread.get() == NULL) {
40 clockid_t result = ~static_cast<clockid_t>(thread->tid) << 3;
43 // Bit 2: thread (set) or process (clear)?
H A Dpthread_setschedparam.cpp37 pthread_accessor thread(t);
38 if (thread.get() == NULL) {
42 int rc = sched_setscheduler(thread->tid, policy, param);
H A Dpthread_setname_np.cpp59 // We have to change another thread's name.
62 pthread_accessor thread(t);
63 if (thread.get() == NULL) {
66 tid = thread->tid;
H A Dpthread_internal.h33 /* Has the thread been detached by a pthread_join or pthread_detach call? */
36 /* Was the thread's stack allocated by the user rather than by us? */
39 /* Has the thread been joined by another thread? */
42 /* Is this the main thread? */
91 * per-thread buffer by simply using malloc(3) and free(3).
97 __LIBC_HIDDEN__ int __init_thread(pthread_internal_t* thread, bool add_to_thread_list);
98 __LIBC_HIDDEN__ void __init_tls(pthread_internal_t* thread);
100 __LIBC_HIDDEN__ void _pthread_internal_add(pthread_internal_t* thread);
106 __LIBC_HIDDEN__ void _pthread_internal_remove_locked(pthread_internal_t* thread);
[all...]
/bionic/libm/i387/
H A Dnpx.h151 void npxexit(struct thread *td);
153 int npxgetregs(struct thread *td, union savefpu *addr);
156 void npxsetregs(struct thread *td, union savefpu *addr);
/bionic/tests/
H A Dsys_socket_test.cpp89 pthread_t thread; local
90 ASSERT_EQ(0, pthread_create(&thread, NULL, ConnectFn, reinterpret_cast<void*>(callback_fn)));
103 ASSERT_EQ(0, pthread_join(thread, &ret_val));
/bionic/libc/upstream-dlmalloc/
H A Dmalloc.c112 Thread-safety: NOT thread-safe unless USE_LOCKS defined non-zero
202 You can similarly create thread-local allocators by storing
203 mspaces as thread-locals. For example:
1497 #include <thread.h>

Completed in 1454 milliseconds