diff options
author | normal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-08-13 21:34:20 +0000 |
---|---|---|
committer | normal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-08-13 21:34:20 +0000 |
commit | 48b6bd74e2febde095ac85d818e94c0e58677647 () | |
tree | 73348a2cf6a66b1f1d6620b93109b7f7dfb0ca03 /thread_pthread.h | |
parent | 4d2e0fffb08f0418fa6995be2e15aad7ee11b048 (diff) |
thread_pthread.c: eliminate timer thread by restructuring GVL
This reverts commit 194a6a2c68e9c8a3536b24db18ceac87535a6051 (r64203). Race conditions which caused the original reversion will be fixed in the subsequent commit. [ruby-core:88360] [Misc #14937] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64352 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | thread_pthread.h | 20 |
1 files changed, 16 insertions, 4 deletions
@@ -22,7 +22,19 @@ typedef pthread_cond_t rb_nativethread_cond_t; typedef struct native_thread_data_struct { struct list_node ubf_list; - rb_nativethread_cond_t sleep_cond; } native_thread_data_t; #undef except @@ -32,12 +44,12 @@ typedef struct native_thread_data_struct { typedef struct rb_global_vm_lock_struct { /* fast path */ - unsigned long acquired; rb_nativethread_lock_t lock; /* slow path */ - volatile unsigned long waiting; - rb_nativethread_cond_t cond; /* yield */ rb_nativethread_cond_t switch_cond; |