summaryrefslogtreecommitdiff
path: root/thread_win32.c
diff options
context:
space:
mode:
authorkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-06-13 14:14:53 +0000
committerkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-06-13 14:14:53 +0000
commitbcfc22b10e30771e692f7716a1fec7577373963e (patch)
tree5e8442fc328f3e322069070a678141837e1e9c9b /thread_win32.c
parente504a81ff11c8611f06d54a23b355fed90b356ab (diff)
downloadruby-bcfc22b10e30771e692f7716a1fec7577373963e.tar.gz
* thread_pthread.c: rewrite GVL completely.
* thread_win32.c: ditto. * thread_pthread.h: ditto. * vm_core.h: ditto. * thread.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32064 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'thread_win32.c')
-rw-r--r--thread_win32.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/thread_win32.c b/thread_win32.c
index c0a026c7b6..da335e88ff 100644
--- a/thread_win32.c
+++ b/thread_win32.c
@@ -13,7 +13,7 @@
#include <process.h>
-#define WIN32_WAIT_TIMEOUT 10 /* 10 ms */
+#define TIME_QUANTUM_USEC (100 * 1000)
#define RB_CONDATTR_CLOCK_MONOTONIC 1 /* no effect */
#undef Sleep
@@ -680,7 +680,7 @@ static unsigned long _stdcall
timer_thread_func(void *dummy)
{
thread_debug("timer_thread\n");
- while (WaitForSingleObject(timer_thread_lock, WIN32_WAIT_TIMEOUT) ==
+ while (WaitForSingleObject(timer_thread_lock, TIME_QUANTUM_USEC/1000) ==
WAIT_TIMEOUT) {
timer_thread_function(dummy);
}