summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornormal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-01-09 23:47:19 +0000
committernormal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-01-09 23:47:19 +0000
commit0c60f22ec5e7a08939a8a5c23b5666e8f341b48e (patch)
treeb3036f1a1889346045132e7493654eea283baad3
parent3e8b9f85ff8f440b20c11db49bd13d8a71618881 (diff)
thread_pthread.c: remove dead code around "get_stack_of"
"get_stack_of" was only in a proposed patch for [Feature #8793] https://bugs.ruby-lang.org/issues/8793 and never applied. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61750 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--thread_pthread.c16
1 files changed, 0 insertions, 16 deletions
diff --git a/thread_pthread.c b/thread_pthread.c
index 0313ac8b00..f54e5f04d8 100644
--- a/thread_pthread.c
+++ b/thread_pthread.c
@@ -834,11 +834,6 @@ native_thread_init_stack(rb_thread_t *th)
th->ec->machine.stack_start = (VALUE *)&curr;
th->ec->machine.stack_maxsize = size - diff;
}
-#elif defined get_stack_of
- if (!th->ec->machine.stack_maxsize) {
- native_mutex_lock(&th->interrupt_lock);
- native_mutex_unlock(&th->interrupt_lock);
- }
#else
rb_raise(rb_eNotImpError, "ruby engine can initialize only in the main thread");
#endif
@@ -1010,18 +1005,7 @@ native_thread_create(rb_thread_t *th)
# endif
CHECK_ERR(pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED));
-#ifdef get_stack_of
- native_mutex_lock(&th->interrupt_lock);
-#endif
err = pthread_create(&th->thread_id, attrp, thread_start_func_1, th);
-#ifdef get_stack_of
- if (!err) {
- get_stack_of(th->thread_id,
- &th->ec->machine.stack_start,
- &th->ec->machine.stack_maxsize);
- }
- native_mutex_unlock(&th->interrupt_lock);
-#endif
thread_debug("create: %p (%d)\n", (void *)th, err);
/* should be done in the created thread */
fill_thread_id_str(th);