mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* thread_pthread.c (gvl_yield): fix live lock issue on 1-2 cpus
system. It's additional fix for r32021. * thread_pthread.c (gvl_init): add switch_wait_cond. * thread_pthread.h (typedef struct rb_global_vm_lock_struct): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32091 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
2e248ad5aa
commit
82e6d95edc
3 changed files with 27 additions and 7 deletions
|
@ -45,7 +45,9 @@ typedef struct rb_global_vm_lock_struct {
|
|||
|
||||
/* yield */
|
||||
rb_thread_cond_t switch_cond;
|
||||
unsigned long need_yield;
|
||||
rb_thread_cond_t switch_wait_cond;
|
||||
int need_yield;
|
||||
int wait_yield;
|
||||
} rb_global_vm_lock_t;
|
||||
|
||||
#endif /* RUBY_THREAD_PTHREAD_H */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue