1440 Commits

Author SHA1 Message Date
NARUSE, Yui
4e31cbc070 update-deps
https://github.com/ruby/ruby/runs/1169621878
2020-09-26 18:55:00 +09:00
Kenta Murata
890bc2cdde
Buffer protocol proposal (#3261)
* Add buffer protocol

* Modify for some review comments

* Per-object buffer availability

* Rename to MemoryView from Buffer and make compilable

* Support integral repeat count in memory view format

* Support 'x' for padding bytes

* Add rb_memory_view_parse_item_format

* Check type in rb_memory_view_register

* Update dependencies in common.mk

* Add test of MemoryView

* Add test of rb_memory_view_init_as_byte_array

* Add native size format test

* Add MemoryView test utilities

* Add test of rb_memory_view_fill_contiguous_strides

* Skip spaces in format string

* Support endianness specifiers

* Update documentation

* Support alignment

* Use RUBY_ALIGNOF

* Fix format parser to follow the pack format

* Support the _ modifier

* Parse count specifiers in get_format_size function.

* Use STRUCT_ALIGNOF

* Fix test

* Fix test

* Fix total size for the case with tail padding

* Fix rb_memory_view_get_item_pointer

* Fix rb_memory_view_parse_item_format again
2020-09-25 20:32:02 +09:00
Kazuhiro NISHIYAMA
8705dba194 Update dependencies 2020-09-25 19:21:36 +09:00
Hiroshi SHIBATA
ba889100d8
Bundle rbs gem as bundled gems (#3496)
* Added rbs as bundled gems
* Added the missing dependencies for rbs gem
2020-09-23 10:59:49 +09:00
Samuel Williams
501fff14c7 When setting current thread scheduler to nil, invoke #close. 2020-09-21 09:51:33 +12: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
e81d7189a0 sync fstring pool
fstring pool should be sync with other Ractors.
2020-09-15 00:04:59 +09:00
Samuel Williams
3dc0fc11f0 Update dependencies 2020-09-14 16:44:09 +12:00
Samuel Williams
d387029f39 Standardised scheduler interface. 2020-09-14 16:44:09 +12:00
Nobuyoshi Nakada
af5e87ab21 separate rb_random_t
* random.c: separate abstract rb_random_t and rb_random_mt_t for
  Mersenne Twister implementation.

* include/ruby/random.h: the interface for extensions of Random
  class.

* DLL imported symbol reference is not constant on Windows.

* check if properly initialized.
2020-09-07 20:08:01 +09:00
Nobuyoshi Nakada
170c7528e6
common.mk: UNALIGNED_MEMBER_ACCESS needs internal/warnings.h on some platforms 2020-09-05 23:16:26 +09:00
Nobuyoshi Nakada
d7406ccc2c
Updated dependency 2020-09-04 16:28:40 +09:00
Koichi Sasada
79df14c04b Introduce Ractor mechanism for parallel execution
This commit introduces Ractor mechanism to run Ruby program in
parallel. See doc/ractor.md for more details about Ractor.
See ticket [Feature #17100] to see the implementation details
and discussions.

[Feature #17100]

This commit does not complete the implementation. You can find
many bugs on using Ractor. Also the specification will be changed
so that this feature is experimental. You will see a warning when
you make the first Ractor with `Ractor.new`.

I hope this feature can help programmers from thread-safety issues.
2020-09-03 21:11:06 +09:00
Hiroshi SHIBATA
377159370b Revert the workaround of minitest and hoe
86737c509cd49cfe4509a65d300d390da0f07be6
  3e1aea461320094e634ab32ca0b13dd43b69d8b0
2020-09-01 11:21:41 +09:00
Hiroshi SHIBATA
86737c509c Removed minitest and hoe because they didn't support Ruby 3 yet 2020-08-31 18:51:59 +09:00
卜部昌平
490010084e sed -i '/rmodule.h/d' 2020-08-27 16:42:06 +09:00
卜部昌平
756403d775 sed -i '/r_cast.h/d' 2020-08-27 15:03:36 +09:00
卜部昌平
0da2a3f1fc sed -i '\,2/extern.h,d' 2020-08-27 14:07:49 +09:00
卜部昌平
d2eeb83634 tool/update-deps -fix 2020-08-19 14:30:57 +09:00
卜部昌平
4d7818a299 tool/update-deps --fix 2020-08-15 12:09:26 +09:00
Nobuyoshi Nakada
c904844578
Skip already extracted gems 2020-07-29 20:52:47 +09:00
卜部昌平
2e5a711f47 common.mk: add missing dependency 2020-07-13 12:45:26 +09:00
Nobuyoshi Nakada
358f91bf6f
Skip comment and empty lines in gems/bundled_gems file 2020-07-05 18:59:06 +09:00
Takashi Kokubun
946e5cc668
Annotate Kernel#class as inline (#3250)
```
$ benchmark-driver -v --rbenv 'before;after;before --jit;after --jit' benchmark/mjit_class.yml --repeat-count=4
before: ruby 2.8.0dev (2020-06-23T07:09:54Z master 37a2e48d76) [x86_64-linux]
after: ruby 2.8.0dev (2020-06-23T17:29:56Z inline-class 0ff147c007) [x86_64-linux]
before --jit: ruby 2.8.0dev (2020-06-23T07:09:54Z master 37a2e48d76) +JIT [x86_64-linux]
after --jit: ruby 2.8.0dev (2020-06-23T17:29:56Z inline-class 0ff147c007) +JIT [x86_64-linux]
Calculating -------------------------------------
                         before       after  before --jit  after --jit
    mjit_class(self)    39.219M     40.060M       53.502M      69.202M i/s -     40.000M times in 1.019915s 0.998495s 0.747631s 0.578021s
       mjit_class(1)    39.567M     41.242M       52.100M      68.895M i/s -     40.000M times in 1.010935s 0.969885s 0.767749s 0.580591s

Comparison:
                 mjit_class(self)
         after --jit:  69201690.7 i/s
        before --jit:  53502336.4 i/s - 1.29x  slower
               after:  40060289.1 i/s - 1.73x  slower
              before:  39218939.2 i/s - 1.76x  slower

                    mjit_class(1)
         after --jit:  68895358.6 i/s
        before --jit:  52100353.0 i/s - 1.32x  slower
               after:  41241993.6 i/s - 1.67x  slower
              before:  39567314.0 i/s - 1.74x  slower
```
2020-06-23 23:49:03 -07:00
Takashi Kokubun
8838600c1e
Stop relying on make benchmark's -I$(srcdir)/benchmark/lib
These days I don't use `make benchmark`. The YAML files should be
executable with bare `benchmark-driver` CLI without passing
`RUBYOPT=-Ibenchmark/lib`.
2020-06-22 00:17:10 -07:00
Takashi Kokubun
95b0fed371
Make Integer#zero? a separated method and builtin (#3226)
A prerequisite to fix https://bugs.ruby-lang.org/issues/15589 with JIT.
This commit alone doesn't make a significant difference yet, but I thought
this commit should be committed independently.

This method override was discussed in [Misc #16961].
2020-06-20 14:55:09 -07:00
Nobuyoshi Nakada
f3e081c6b6
Build configured extension libraries only
Consider the libraries, which remain exts.mk but not listed in
ext/configure-ext.mk, removed.
2020-06-19 15:35:14 +09:00
Nobuyoshi Nakada
cc46d514dc
$(PREP) is needed to run $(MINIRUBY) 2020-06-18 01:42:12 +09:00
Nobuyoshi Nakada
ccb7a4b9f2
Replaced accessors of Struct with invokebuiltin 2020-06-17 08:18:46 +09:00
Nobuyoshi Nakada
318d52e820
Revert "Replaced accessors of Struct with invokebuiltin"
This reverts commit 19cabe8b09d92d033c244f32ff622b8e513375f1,
which didn't support tool/lib/iseq_loader_checker.rb.
2020-06-16 18:44:58 +09:00
Nobuyoshi Nakada
19cabe8b09
Replaced accessors of Struct with invokebuiltin 2020-06-16 18:24:02 +09:00
Nobuyoshi Nakada
1f1b62fb7b
Added install-dbg
Scripts to run the interpreter via debugger.
2020-06-13 08:22:06 +09:00
Nobuyoshi Nakada
5349506eb4
Updated autogenerated dependencies
Sorted the lines asnd added mjit_build_dir.o dependencies.
2020-06-11 18:06:29 +09:00
Nobuyoshi Nakada
21df4dce53
Skip updating exts in test-all to reduce the turnaround time 2020-06-10 19:42:27 +09:00
Nobuyoshi Nakada
465b5dc124
Fixed main dependency
`programs` has depended on the "fake" script, which is used by
`test-spec` and etc.
2020-06-08 13:15:05 +09:00
Nobuyoshi Nakada
a4f3e1762a
Fixed test dependencies
All tests of `test-all` or more require not only the `main` but
also extension libraries.
2020-06-08 12:38:58 +09:00
Nobuyoshi Nakada
b12197dbbb
Updated the benchmark-driver version 2020-06-08 09:25:53 +09:00
Nobuyoshi Nakada
d0b2332e93
Defaulted benchmark output to markdown with comarison 2020-06-08 09:25:22 +09:00
Nobuyoshi Nakada
e11ffe0aaf
Fixup test-bundler-parallel
* Do not chdir in the runner process, to access miniruby.  Chdir
  in worker processes instead.
* GNU make does not export newly added environment variables by
  default, set PARALLEL_TESTS_EXECUTABLE in the runner.
2020-06-05 21:34:26 +09:00
Hiroshi SHIBATA
0afbfddc0d
Fixup 347127794e8041a1257b7241bbbdd9d0db2921a5 2020-06-05 19:20:48 +09:00
Hiroshi SHIBATA
347127794e
spec/bundler/support/parallel.rb is no longer used parallel_rspec. 2020-06-05 19:01:39 +09:00
Nobuyoshi Nakada
2b7454eb92
Update leaked-globals [Bug #16934]
* match uppercase types which would be global, other than [BDT]
* ignore `RUBY_` prefixed symbols
2020-06-04 17:00:52 +09:00
Nobuyoshi Nakada
047471c529
No GITPULLOPTIONS by default
To honor the environment variable, keep GITPULLOPTIONS unset by
default, and appended the option to VCSUP.
2020-06-04 13:16:24 +09:00
Nobuyoshi Nakada
93ccb8e8a2
Remove platform directory when distclean or more [ci skip]
At the time of clean-platform, platform directory may not be empty
because of parallel build.
2020-05-28 00:13:11 +09:00
Hiroshi SHIBATA
777b5b4f39 Bump version to use RSpec 3.8+ 2020-05-13 07:54:37 +09:00
Hiroshi SHIBATA
cf9619084b Bump version to use Rake 13 in bundler examples 2020-05-13 07:54:37 +09:00
Nobuyoshi Nakada
1c4eb70654
Build auxiliary program files early 2020-05-12 23:19:20 +09:00
Nobuyoshi Nakada
2383cdabc1
builtin_binary.inc: should be updated even if no changes [ci skip]
As this rule does not use a separate timestamp file, the target
will be rebuilt every time once it is outdated.
2020-05-12 23:07:42 +09:00
卜部昌平
9e41a75255 sed -i 's|ruby/impl|ruby/internal|'
To fix build failures.
2020-05-11 09:24:08 +09:00
卜部昌平
d7f4d732c1 sed -i s|ruby/3|ruby/impl|g
This shall fix compile errors.
2020-05-11 09:24:08 +09:00