Commit graph

63490 commits

Author SHA1 Message Date
Benoit Daloze
c19bcf38eb Fix Thread leak in Thread#join specs 2020-09-21 15:54:39 +02:00
Samuel Williams
10d795cfca Add NEWS about Fiber#backtrace and Fiber#backtrace_locations. 2020-09-21 17:04:49 +12:00
Samuel Williams
f7aa51b2b8 Update NEWS & documentation relating to scheduler. 2020-09-21 15:28:03 +12:00
Samuel Williams
70f08f1eed Make Thread#join non-blocking. 2020-09-21 11:48:44 +12:00
git
596173155a * 2020-09-21 [ci skip] 2020-09-21 06:51:54 +09:00
Samuel Williams
501fff14c7 When setting current thread scheduler to nil, invoke #close. 2020-09-21 09:51:33 +12:00
Peter Zhu
b6d599d76e Update heap_pages_himem after freeing pages 2020-09-20 23:13:47 +09:00
Quang-Minh Nguyen
be2efb118f Fulfill missing tests and stabilize tests 2020-09-20 23:10:44 +09:00
Quang-Minh Nguyen
398da71175 Validate name during initialization 2020-09-20 23:10:44 +09:00
Quang-Minh Nguyen
d5fa66156a Add status to Ractor#inspect 2020-09-20 23:10:44 +09:00
git
84c4c7bec8 * 2020-09-20 [ci skip] 2020-09-20 20:39:25 +09:00
Benoit Daloze
6987c8997e Remove from waiter in Mutex#lock with ensure when calling rb_scheduler_block()
* Previously this could lead to an invalid waiter entry and then trying
  to wake up that waiter would result in various issues in rb_mutex_unlock_th().
2020-09-20 13:35:39 +02:00
Nobuyoshi Nakada
73a626c078
[ruby/io-wait] update required_ruby_version
As d387029f39 made io/wait
unbuildable with older versions, drop older versions tentatively.
Also the change seems to instroduce behavioral incompatibilities,
may address them or bump up the version later.
2020-09-19 17:47:40 +09:00
Nobuyoshi Nakada
702cebf104
strip trailing spaces [ci skip] 2020-09-19 17:40:54 +09:00
Aaron Patterson
6cb6d5abc3
Add assertions when inline caches are copied to MJIT
This is a temporary commit to try to find a GC issue.  It seems like
mjit is pointing at a moved address in the call cache.  I want to assert
that they aren't TMOVED or garbage objects at the time they get copied
2020-09-18 17:07:08 -07:00
aycabta
e193dd1e3d [ruby/irb] Version 1.2.7
0eaa06838b
2020-09-19 05:13:08 +09:00
aycabta
555ea83344 [ruby/irb] Drop OMIT_ON_ASSIGNMENT and add :truncate option for ECHO_ON_ASSIGNMENT
4c89b0775b
2020-09-19 05:13:08 +09:00
git
7d9b4d3c61 * 2020-09-19 [ci skip] 2020-09-19 04:32:21 +09:00
Aaron Patterson
1a9dd31910 Pin values in the finalizer table
When finalizers run (in `rb_objspace_call_finalizer`) the table is
copied to a linked list that is not managed by the GC.  If compaction
runs, the references in the linked list can go bad.

Finalizer table shouldn't be used frequently, so lets pin references in
the table so that the linked list in `rb_objspace_call_finalizer` is
safe.
2020-09-18 12:31:54 -07:00
Hiroshi SHIBATA
6dd257ed1e
Added sync task for bigdecimal 2020-09-18 18:47:52 +09:00
Hiroshi SHIBATA
3d86f7a37c
The executable file of erb is under the libexec on ruby/erb repo 2020-09-18 18:44:46 +09:00
Benoit Daloze
af1926e859 Fix copy/paste error from 5bb5e706f1 2020-09-18 11:11:47 +02:00
Benoit Daloze
5bb5e706f1 Only interrupt when there is no scheduler in sync_wakeup()
* When there is a scheduler, the Fiber that would be blocked has already
  been rescheduled and there is no point to interrupt something else.
  That blocked Fiber will be rescheduled as the next call to the scheduler
  (e.g., IO, sleep, other blocking sync).
* See discussion on d01954632d
2020-09-18 10:39:27 +02:00
aycabta
305c430603 [ruby/rdoc] Add man/ri.1 for distribution files
7cb5c3611f
2020-09-18 14:57:58 +09:00
Dorian Marié
0d56aec1dd [ruby/rdoc] Fix spelling error in parser comment
f237c9e223
2020-09-18 14:57:58 +09:00
Nobuyoshi Nakada
e23f0f29da [ruby/rdoc] update all files if any file is newer
Cross references need parse all files which define the subject
names.  This commit makes `--force-update` option enforce to parse
all files if any file is newer than the previous parse, not only
updated files.

13e9a44896
2020-09-18 14:57:58 +09:00
aycabta
b5db9b8a31 [ruby/rdoc] Support full filename to make a link for a text file
41db49c485
2020-09-18 14:57:57 +09:00
Koichi Sasada
3b159374a2 sync ruby_global_symbols
ruby_global_symbols can be accessed with multiple ractors so that
the accesses should be synchronized.
2020-09-18 14:17:49 +09:00
Koichi Sasada
06e9b94d40 show object info to debug purpose. 2020-09-18 14:17:49 +09:00
Koichi Sasada
b416a76402 add debug log on enabling multi-ractor mode 2020-09-18 14:17:49 +09:00
Koichi Sasada
b189dc6926 rb_obj_info() shows more info for T_SYMBOL 2020-09-18 14:17:49 +09:00
Koichi Sasada
dd5db6f5fe sync fstring_table for deletion
Ractors can access this table simultaneously so we need to sync
accesses.
2020-09-18 14:17:49 +09:00
git
609e6ac0ca * 2020-09-18 [ci skip] 2020-09-18 00:30:47 +09:00
Benoit Daloze
d9b943b8e5 Cleanup commented code
* Mutex operations no longer disable the Fiber scheduler.
2020-09-17 17:29:43 +02:00
Benoit Daloze
d01954632d Add missing goto found;
* To still remove the lock from the Thread's list of acquired locks.
* Also to not wake up other waiters and preserve blocking behavior.
2020-09-17 17:26:52 +02:00
Benoit Daloze
264889ec3d Fix Mutex#unlock with a scheduler and thread contention
* It would hit "[BUG] unexpected THREAD_STOPPED" before.
2020-09-17 15:15:43 +02:00
Benoit Daloze
deffb63021 Document the various scheduler hooks 2020-09-17 14:59:38 +02:00
Benoit Daloze
9472d16061 Call scheduler.block instead of scheduler.kernel_sleep for blocking Queue/SizedQueue operations
* scheduler.unblock was already already called before but with no corresponding scheduler.block
* add test that Queue#pop makes the scheduler wait until it gets an element.
2020-09-17 14:59:38 +02:00
Benoit Daloze
738a089b3a Rename scheduler.{mutex_lock,mutex_unlock} to {block,unblock}
* Move #kernel_sleep next to #block as it is similar
2020-09-17 14:30:40 +02:00
Benoit Daloze
c3acfcc78d Use a similar pattern for waiting and ready 2020-09-17 14:14:49 +02:00
Kazuhiro NISHIYAMA
e4dbb91f4c
Fix typos [ci skip]
s/overriden/overridden/
2020-09-17 20:34:59 +09:00
Kazuhiro NISHIYAMA
63a4f2f93f
Sort links in NEWS.md by URI [ci skip] 2020-09-17 20:30:59 +09:00
Benoit Daloze
3f6c0a6d74 Update to ruby/spec@e829fb0 2020-09-17 11:42:26 +02:00
Benoit Daloze
ce888bfa23 Add NEWS entry for [Feature #16792] 2020-09-17 11:17:07 +02:00
git
2e6c484040 * 2020-09-17 [ci skip] 2020-09-17 05:52:45 +09:00
Chris Seaton
8e173d8b27 Warn on a finalizer that captures the object to be finalized
Also improve specs and documentation for finalizers and more clearly
recommend a safe code pattern to use them.
2020-09-16 13:52:24 -07:00
Samuel Williams
f75009c122 Prefer to use prep_io for temporary IO instances. 2020-09-17 00:31:04 +12:00
Kenta Murata
68b5f14d53
Fix assertion failed in Complex.polar without NDEBUG (#3551)
Fixes [Bug #17172].
2020-09-16 19:27:16 +09:00
Benoit Daloze
10290da54d Add a note at the top of the test scheduler 2020-09-16 11:37:06 +02:00
Benoit Daloze
9e813c1fc4 RUBY_ISEQ_DUMP_DEBUG=to_binary never kept the debug information for String literals
* That is, for plain string literals, not interpolated.
* The test below is very similar and uses the same check.
2020-09-16 11:17:23 +02:00