diff options
| author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-05-08 06:59:03 +0000 |
|---|---|---|
| committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-05-08 06:59:03 +0000 |
| commit | aa94d2839d4784956d1291216c908b4d68cb4d0b (patch) | |
| tree | 54efe775a5a8c6fed0717e14510025a7198e8025 | |
| parent | c7bdda845ed703d4707a63cd853394fa86d41675 (diff) | |
| download | ruby-aa94d2839d4784956d1291216c908b4d68cb4d0b.tar.gz ruby-aa94d2839d4784956d1291216c908b4d68cb4d0b.tar.xz ruby-aa94d2839d4784956d1291216c908b4d68cb4d0b.zip | |
* thread.c (rb_gc_save_machine_context): call FLUSH_REGISTER_WINDOWS
to mark the register stack from GC on another thread.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@16328 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
| -rw-r--r-- | ChangeLog | 5 | ||||
| -rw-r--r-- | bootstraptest/test_thread.rb | 12 | ||||
| -rw-r--r-- | thread.c | 1 |
3 files changed, 18 insertions, 0 deletions
@@ -1,3 +1,8 @@ +Thu May 8 15:36:11 2008 Tanaka Akira <akr@fsij.org> + + * thread.c (rb_gc_save_machine_context): call FLUSH_REGISTER_WINDOWS + to mark the register stack from GC on another thread. + Thu May 8 15:14:34 2008 Nobuyoshi Nakada <nobu@ruby-lang.org> * array.c (rb_ary_sort_bang): freeze temporary array. diff --git a/bootstraptest/test_thread.rb b/bootstraptest/test_thread.rb index fde04a8d4..8d88a0f70 100644 --- a/bootstraptest/test_thread.rb +++ b/bootstraptest/test_thread.rb @@ -234,3 +234,15 @@ assert_normal_exit %q{ STDERR.reopen(STDOUT) exec "/" } + +assert_normal_exit %q{ + (0..10).map { + Thread.new { + 10000.times { + Object.new.to_s + } + } + }.each {|t| + t.join + } +} @@ -1966,6 +1966,7 @@ void rb_gc_save_machine_context(rb_thread_t *th) { SET_MACHINE_STACK_END(&th->machine_stack_end); + FLUSH_REGISTER_WINDOWS; #ifdef __ia64 th->machine_register_stack_end = rb_ia64_bsp(); #endif |
