Граф коммитов

374 Коммитов

Автор SHA1 Сообщение Дата
ko1 fa4514e4fe * thread.c (rb_threadptr_check_signal): only wake up main thread.
* thread.c (rb_threadptr_execute_interrupts_common): check signal
  deliverly if it is main thread.
  fixes [ruby-dev:44005] [Ruby 1.9 - Bug #4950]
* bootstraptest/test_fork.rb: add a test for above.
* signal.c (rb_get_next_signal): skip if signal_buff is empty.
  (check signal_buff.size first)
* vm_core.h: remove unused variable rb_thread_t::exec_signal.
* thread.c (rb_thread_check_trap_pending): check
  rb_signal_buff_size() because rb_thread_t::exec_signal
  is no longer available.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32345 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-06-30 22:29:34 +00:00
naruse 021f166509 * compile.c (iseq_compile_each): fix return value of obj[a,*b]=c.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32146 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-06-17 10:18:39 +00:00
akr 7d6fe4e604 * bootstraptest/runner.rb (show_progress): refine verbose mode.
(exec_test): ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32088 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-06-14 14:17:42 +00:00
akr 92c0438049 * bootstraptest/runner.rb (show_progress): extracted from assert_check.
(assert_check): use show_progress.
  (assert_normal_exit): ditto.
  (assert_finish): ditto.
  (flunk): ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32087 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-06-14 14:07:02 +00:00
eban 10bf738bee * bootstraptest/runner.rb: should initilize $stress to avoid warnings.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32001 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-06-11 09:07:26 +00:00
nobu 3a47cf3395 * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31573 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-05-15 11:55:52 +00:00
shugo 4273aa8e72 * vm_insnhelper.c (vm_get_ev_const): search root cref properly.
[ruby-dev:43365]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31221 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-03-31 07:52:40 +00:00
ko1 f01fae2885 * bootstraptest/test_method.rb: fix last commit.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29314 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-09-21 16:56:59 +00:00
ko1 9831508ba3 bootstraptest/test_method.rb: add a test for [ruby-core:30534].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29313 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-09-21 16:53:06 +00:00
mame be1c68caeb * bootstraptest/test_class.rb: add a test for [ruby-core:30843].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28454 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-06-27 18:13:06 +00:00
mame 59af57e257 * iseq_compile_each (NODE_DEFINED): put nil first to fix stack
consistency.  [ruby-core:30293]
  Now, lfinish[0] of defined_expr seems not to be used.  Refactoring
  may be needed.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27892 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-05-19 10:48:17 +00:00
mame b8571b4285 * vm_eval.c (eval_string_with_cref): propagative filename and line_no
of binding.  [ruby-dev:38767] [ruby-core:28307]

* vm_core.h (rb_binding_t), proc.c: add filename and line_no fields to
  preserve them.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27716 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-05-09 18:41:51 +00:00
mame 80f7f8d07e * compile.c (iseq_compile_each), vm_insnhelper.c (vm_invoke_block,
vm_throw): allow "return" and "yield" even in singleton class
  definition.  based on a patch from wanabe <s.wanabe AT gmail.com>
  for "return".  [ruby-core:21379] [ruby-dev:40975]

* insns.def (defineclass): ditto (straightforwardly push block ptr,
  instead of dfp ptr with special flag).

* vm_core.h (RUBY_VM_CLASS_SPECIAL_P): ditto (no longer needed).

* proc.c (proc_new): ditto (remove handling for special flag).

* bootstraptest/test_jump.rb: add tests for above.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27714 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-05-09 18:21:39 +00:00
ko1 833cade2dc * vm_method.c (rb_unlink_method_entry, rb_sweep_method_entry):
added.  Unlinked method entries are collected to
  vm->unlinked_method_entry_list.  On the GC timing, mark all method
  entries which are on all living threads.  Only non-marked method
  entries are collected.  This hack prevents releasing living method
  entry.
  [Performance Consideration] Since this Method Entry GC (MEGC)
  doesn't occuer frequently, MEGC will not be a performance bottleneck.
  However, to traverse living method entries, every control frame push
  needs to clear cfp->me field.  This will be a performance issue
  (because pushing control frame is occurred frequently).
  Bug #2777 [ruby-dev:40457]
* cont.c (fiber_init): init cfp->me.
* gc.c (garbage_collect): kick rb_sweep_method_entry().
* method.h (rb_method_entry_t): add a mark field.
* vm.c (invoke_block_from_c): set passed me.
* vm.c (rb_thread_mark): mark cfp->me.
* vm_core.h (rb_thread_t): add a field passed_me.
* vm_core.h (rb_vm_t): add a field unlinked_method_entry_list.
* vm_insnhelper.c (vm_push_frame): clear cfp->me at all times.
* vm_insnhelper.c (vm_call_bmethod): pass me.
* bootstraptest/test_method.rb: add a test.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27634 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-05-05 17:51:21 +00:00
nobu a6242670f3 * bootstraptest/test_io.rb (megacontent-copy_stream): get rid of
deadlock.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27623 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-05-05 02:43:15 +00:00
mame e59b9d35fc * insns.def (onceinlinecache): add exclusion control for a region
between onceinlinecache and setinlinecache.  [ruby-dev:39768]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27515 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-27 14:06:16 +00:00
mame 0ffb18de45 * bootstraptest/test_thread.rb: fix test. [Bug #2342]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27445 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-22 14:02:09 +00:00
nobu 82ba40b434 * parse.y (parser_yylex): reverted r27388 due to backward
compatibility.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27430 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-21 04:36:05 +00:00
mame adfe4f3930 * compile.c (NODE_NEXT, NODE_REDO): add dummy putnil instruction to
fix stack consistency error.  [ruby-core:28172]

* bootstraptest/test_jump.rb: add a test for above.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27424 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-20 15:28:33 +00:00
mame ab10ac8f12 * bootstraptest/test_fork.rb: add a test for [ruby-core:28924].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27405 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-19 16:03:39 +00:00
nobu e70a308c75 * parse.y (parser_yylex): seems like a symbol-literal when spaces
are unbalanced.  [ruby-core:29578]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27388 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-18 03:48:54 +00:00
nobu cfab29b7db * parse.y (string_content): preserve cond_stack and cmdarg_stack.
[ruby-core:29579]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27387 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-18 03:32:06 +00:00
nobu 54985ad7dd * bootstraptest/test_io.rb: reduced megacontent test.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27385 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-18 03:26:56 +00:00
akr 24421c835d * bootstraptest/runner.rb (assert_normal_exit): add :timeout option.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26700 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-02-17 12:27:34 +00:00
nobu 09205cf2c3 * vm.c (vm_exec): reset thread state before starting vm loop.
[ruby-core:28129]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26628 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-02-09 19:06:39 +00:00
akr dd4537ad99 * bootstraptest/runner.rb: sort test files.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26614 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-02-07 14:09:43 +00:00
mame 3a9ce187de * vm_insnhelper.c (vm_throw): fixed infinite loop. [ruby-core:27969]
(re-commit of r26522 since forgot to add a change, sorry)

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26524 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-01-31 12:41:47 +00:00
usa 0676ac37be * bootstraptest/test_thread.rb: please please please remember that there are
platforms that do not support fork.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26066 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-12-11 07:47:29 +00:00
nobu 4ba0fe5fd3 * thread_pthread.c (native_mutex_reinitialize_atfork): release and
re-acquire the lock at re-initialization.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-12-10 06:49:15 +00:00
nobu 770b05dd9b * parse.y (dyna_pop_gen): pop dvars. [ruby-dev:39861]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26055 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-12-09 16:12:57 +00:00
shugo 4cec4edd0b fixed tests.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25990 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-12-04 07:09:21 +00:00
nobu 9b02e165d3 * parse.y (dyna_push_gen, dyna_pop_gen): adjust local vtable level
for the case of syntax errors in method name or argument inside
  do block.   [ruby-core:26961]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25967 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-11-30 21:16:31 +00:00
usa d3eb005737 * bootsraptest/test_io.rb: skip the test of io/nonblock on Windows.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25910 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-11-25 04:09:59 +00:00
usa f6fbdf261e * bootstraptest/test_thread.rb: propagate the exception within a thread to
outer.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25898 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-11-24 01:30:00 +00:00
usa 1968717136 * test_thread.rb: DO NOT USE FORK WITHOUT RESCUE.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25850 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-11-19 00:56:44 +00:00
nobu 748fe216c2 * thread.c (rb_thread_atfork_internal): reinitialize global lock
at fork to get rid of deadlock.  based on the patch from Hongli
  Lai in [ruby-core:26783].  [ruby-core:26361]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25842 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-11-18 09:25:11 +00:00
mame 31c0e3385f * thread.c (thread_cleanup_func): delete locking_mutex when thread
object become dummy because of fork.  [ruby-core:26744]
  [ruby-core:26745]

* bootstraptest/test_thread.rb: add a test for above.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25771 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-11-15 15:10:49 +00:00
nobu 9bcccca47a * bootstraptest/test_gc.rb: added tests based on [ruby-dev:39484]
from wanabe <s.wanabe AT gmail.com>.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25371 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-10-16 09:42:20 +00:00
nobu a97e80ba74 * tool/instruction.rb (make_header_prepare_stack): check stack
overflow.  [ruby-core:25714]

* tool/instruction.rb (make_footer_stack_val): ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25048 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-09-23 02:28:08 +00:00
nobu 2620a84070 * bootstraptest/test_thread.rb: just check for normal exit.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24850 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-09-11 12:06:34 +00:00
nobu fb03cb8275 * parse.y (literal_concat_gen): concat body from dstr instead of
nd_next.  [ruby-core:25284]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24741 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-09-03 08:57:28 +00:00
nobu b6cf785119 * vm.c (collect_local_variables_in_env): skips internal variables.
[ruby-core:25125]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24659 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-08-26 03:37:08 +00:00
akr 7c2d363bae * bootstraptest/runner.rb (main): "usage" description updated.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24631 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-08-23 06:24:33 +00:00
akr 0ebb7c1c9b * bootstraptest/runner.rb (Dir.mktmpdir): updated to latest.
(in_temporary_working_directory): temporary directory name changed.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24630 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-08-23 06:15:00 +00:00
nobu c82826ce5f * bootstraptest/test_exception.rb: test for [ruby-core:24767].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24404 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-08-05 04:01:08 +00:00
nobu 9997227af8 * bootstraptest/runner.rb: forgot shebang line.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24366 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-08-03 07:20:14 +00:00
nobu 8b0fef3747 * bootstraptest/runner.rb: got rid of using /bin/sh.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24363 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-08-03 06:35:38 +00:00
nobu 59e5d0f177 * bootstraptest/runner.rb: made executable.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24357 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-08-02 12:06:31 +00:00
nobu 6a26b59600 * parse.y (literal_concat0): tail can be nil. [ruby-dev:38980]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24356 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-08-02 12:04:43 +00:00
mame 3129ed327e * parse.y (literal_concat_gen): NODE_DSTR was incorrectly handled as
NODE_STR.  [ruby-dev:38968]

* bootstraptest/test_syntax.rb: add a test for above.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24332 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-07-30 18:02:37 +00:00