<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/test/monitor, branch ruby_2_7</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>new_cond before mon_initialize</title>
<updated>2019-12-04T04:36:41+00:00</updated>
<author>
<name>Koichi Sasada</name>
<email>ko1@atdot.net</email>
</author>
<published>2019-12-04T04:36:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=c6e3db0c66312af1e932c21006437419efa9ac75'/>
<id>c6e3db0c66312af1e932c21006437419efa9ac75</id>
<content type='text'>
MonitorMixin#new_cond can be called before mon_initialize, so we
need to initialize `@monitor` before it.

https://bugs.ruby-lang.org/issues/16255#note-4
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
MonitorMixin#new_cond can be called before mon_initialize, so we
need to initialize `@monitor` before it.

https://bugs.ruby-lang.org/issues/16255#note-4
</pre>
</div>
</content>
</entry>
<entry>
<title>Monitor#exit: check monitor ownership.</title>
<updated>2019-11-12T01:07:45+00:00</updated>
<author>
<name>Koichi Sasada</name>
<email>ko1@atdot.net</email>
</author>
<published>2019-11-12T01:02:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=fd6445b7e8bab9d340be6f76688a8b96f1b52029'/>
<id>fd6445b7e8bab9d340be6f76688a8b96f1b52029</id>
<content type='text'>
Monitor#exit should be called by only onwer Thread. However, there
is not check for it.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Monitor#exit should be called by only onwer Thread. However, there
is not check for it.
</pre>
</div>
</content>
</entry>
<entry>
<title>make monitor.so for performance. (#2576)</title>
<updated>2019-10-19T19:52:20+00:00</updated>
<author>
<name>Koichi Sasada</name>
<email>ko1@atdot.net</email>
</author>
<published>2019-10-19T19:52:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=caac5f777ae288b5982708b8690e712e1cae0cf6'/>
<id>caac5f777ae288b5982708b8690e712e1cae0cf6</id>
<content type='text'>
Recent monitor.rb has performance problem because of interrupt
handlers. 'Monitor#synchronize' is frequently used primitive
so the performance of this method is important.

This patch rewrite 'monitor.rb' with 'monitor.so' (C-extension)
and make it faster. See [Feature #16255] for details.

Monitor class objects are normal object which include MonitorMixin.
This patch introduce a Monitor class which is implemented on C
and MonitorMixin uses Monitor object as re-entrant (recursive)
Mutex. This technique improve performance because we don't need
to care atomicity and we don't need accesses to instance variables
any more on Monitor class.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Recent monitor.rb has performance problem because of interrupt
handlers. 'Monitor#synchronize' is frequently used primitive
so the performance of this method is important.

This patch rewrite 'monitor.rb' with 'monitor.so' (C-extension)
and make it faster. See [Feature #16255] for details.

Monitor class objects are normal object which include MonitorMixin.
This patch introduce a Monitor class which is implemented on C
and MonitorMixin uses Monitor object as re-entrant (recursive)
Mutex. This technique improve performance because we don't need
to care atomicity and we don't need accesses to instance variables
any more on Monitor class.</pre>
</div>
</content>
</entry>
<entry>
<title>Wait for the helper thread to terminate</title>
<updated>2019-06-28T05:54:00+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2019-06-28T05:51:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=c52dad0ecf0b8d87afb570d7dde508fe78d145d4'/>
<id>c52dad0ecf0b8d87afb570d7dde508fe78d145d4</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>lib/monitor.rb: avoid race conditions by Thread.handle_interrupt</title>
<updated>2018-11-28T01:51:44+00:00</updated>
<author>
<name>shugo</name>
<email>shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2018-11-28T01:51:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=6ec1720aa38772ba4b7515790443cb578340518b'/>
<id>6ec1720aa38772ba4b7515790443cb578340518b</id>
<content type='text'>
Suggested by Benoit Daloze.  [ruby-core:88502] [Bug #14998]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Suggested by Benoit Daloze.  [ruby-core:88502] [Bug #14998]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>revert r65822</title>
<updated>2018-11-20T03:56:51+00:00</updated>
<author>
<name>shugo</name>
<email>shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2018-11-20T03:56:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=0dfc5918ec19cb67d8a49915ad8ab177f56e4e73'/>
<id>0dfc5918ec19cb67d8a49915ad8ab177f56e4e73</id>
<content type='text'>
Because mon_initialized may be used to re-initialize copied objects intentionally.

mon_initialize_spec.rb fails:

1)
MonitorMixin#mon_initialize can be called in initialize_copy to get a new Mutex and used with synchronize ERROR
ThreadError: already initialized
/home/shugo/src/ruby/lib/monitor.rb:255:in `mon_initialize'
/home/shugo/src/ruby/spec/ruby/library/monitor/mon_initialize_spec.rb:19:in `initialize_copy'
/home/shugo/src/ruby/spec/ruby/library/monitor/mon_initialize_spec.rb:28:in `initialize_dup'
/home/shugo/src/ruby/spec/ruby/library/monitor/mon_initialize_spec.rb:28:in `dup'
/home/shugo/src/ruby/spec/ruby/library/monitor/mon_initialize_spec.rb:28:in `block (2 levels) in &lt;top (required)&gt;'
/home/shugo/src/ruby/spec/ruby/library/monitor/mon_initialize_spec.rb:4:in `&lt;top (required)&gt;'

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65827 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Because mon_initialized may be used to re-initialize copied objects intentionally.

mon_initialize_spec.rb fails:

1)
MonitorMixin#mon_initialize can be called in initialize_copy to get a new Mutex and used with synchronize ERROR
ThreadError: already initialized
/home/shugo/src/ruby/lib/monitor.rb:255:in `mon_initialize'
/home/shugo/src/ruby/spec/ruby/library/monitor/mon_initialize_spec.rb:19:in `initialize_copy'
/home/shugo/src/ruby/spec/ruby/library/monitor/mon_initialize_spec.rb:28:in `initialize_dup'
/home/shugo/src/ruby/spec/ruby/library/monitor/mon_initialize_spec.rb:28:in `dup'
/home/shugo/src/ruby/spec/ruby/library/monitor/mon_initialize_spec.rb:28:in `block (2 levels) in &lt;top (required)&gt;'
/home/shugo/src/ruby/spec/ruby/library/monitor/mon_initialize_spec.rb:4:in `&lt;top (required)&gt;'

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65827 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>lib/monitor.rb: prevent to initialize MonitorMixin twice</title>
<updated>2018-11-20T03:01:55+00:00</updated>
<author>
<name>shugo</name>
<email>shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2018-11-20T03:01:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=8d68f422dc1a42453fabd697f004e35c618ce3ea'/>
<id>8d68f422dc1a42453fabd697f004e35c618ce3ea</id>
<content type='text'>
Suggested by Benoit Daloze.  [ruby-core:88504] [Feature #15000]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65822 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Suggested by Benoit Daloze.  [ruby-core:88504] [Feature #15000]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65822 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove unnecessary `require 'thread'`</title>
<updated>2017-10-08T07:00:01+00:00</updated>
<author>
<name>kazu</name>
<email>kazu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2017-10-08T07:00:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=6064132c42ffe99e9a0d3a6ba80a7932c6f7903d'/>
<id>6064132c42ffe99e9a0d3a6ba80a7932c6f7903d</id>
<content type='text'>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60139 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60139 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>Add MonitorMinx#mon_locked? and #mon_owned? to check states of objects</title>
<updated>2017-09-20T01:40:53+00:00</updated>
<author>
<name>shugo</name>
<email>shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2017-09-20T01:40:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=da1b14bcec60c607bd1a6a782b44573b1fa14b52'/>
<id>da1b14bcec60c607bd1a6a782b44573b1fa14b52</id>
<content type='text'>
Patched by Satoshi "Moris" Tagomori &lt;tagomoris@gmail.com&gt;.  [Fix GH-1699]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59971 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Patched by Satoshi "Moris" Tagomori &lt;tagomoris@gmail.com&gt;.  [Fix GH-1699]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59971 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>Use qualified names</title>
<updated>2016-08-30T06:22:30+00:00</updated>
<author>
<name>nobu</name>
<email>nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2016-08-30T06:22:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=4b298ad77a8388f0aae62daeca66659a8effeade'/>
<id>4b298ad77a8388f0aae62daeca66659a8effeade</id>
<content type='text'>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56037 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56037 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
</feed>
