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

70776 Коммитов

Автор SHA1 Сообщение Дата
John Hawthorn 930ebdd7ca YJIT: Support kwargs for cfunc
This adds support for passing keyword arguments to cfuncs. This is done
by calling a helper method to create the hash from the top N values on
the stack (determined by the callinfo) and then moving that value onto
the stack.
2022-01-10 10:53:31 -08:00
Burdette Lamar a9dc0c59e3
[DOC] Enhanced RDoc for IO (#5422)
Revises much of the introductory material.

Also treats:

    #close_on_exec
    #close
    #closed?
    #close_read
    #close_write
2022-01-10 12:45:06 -06:00
Alan Wu 04d9b6d2f9 [DOC] Link to Ruby Spec and rephrase project goal
The word "specification" can be confusing as it might make readers
assume that the Ruby Spec Suite is a specification similar to an ISO
specification. Avoid the word and link to the project so curious parties
could read more about the project.
2022-01-10 18:02:00 +01:00
git c9325cb8cf * 2022-01-11 [ci skip] 2022-01-11 00:30:53 +09:00
Benoit Daloze 4053e8ba0d Update to ruby/spec@226cfdc 2022-01-10 16:29:54 +01:00
Benoit Daloze 8abfc10605 Update to ruby/mspec@3ea3d32 2022-01-10 16:29:53 +01:00
Benoit Daloze ca97001a94 Make the Ractor-safe section more fluent 2022-01-10 13:08:59 +01:00
Trey Evans b4d0d07e2c Clarify ractor documentation meaning and formatting. 2022-01-10 13:04:31 +01:00
git 7b5d49a082 * 2022-01-10 [ci skip] 2022-01-10 20:18:36 +09:00
Kazuhiro NISHIYAMA c764e368bd
Fix default --jit-max-cache in `ruby --help`
changed at 028f1887c2
2022-01-10 20:17:05 +09:00
Nobuyoshi Nakada 65a8d52212
Revert "[DOC] Mention RBOOL in extension.rdoc [Feature #13125]"
This reverts commit 9ad34da47f, as
`RBOOL` is not defined publicly yet.
2022-01-09 19:17:48 +09:00
Nobuyoshi Nakada b43ad6b802
[DOC] Fold too long lines 2022-01-09 13:21:52 +09:00
Nobuyoshi Nakada 83983bacbc
[DOC] Mention `make check` 2022-01-09 12:40:25 +09:00
Kazuhiro NISHIYAMA a7faca51ac
Add `=num` to yjit options
`--yjit-call-threshold` and `--yjit-max-versions` need an argument.
2022-01-09 12:39:34 +09:00
Nobuyoshi Nakada cc01ae591b
[DOC] test-spec would be preferable now 2022-01-09 12:34:11 +09:00
Samuel Williams 8648457541
Don't combine test-all and rubyspec. 2022-01-09 12:06:20 +13:00
Peter Zhu 33cc8816be Revert "Enable Variable Width Allocation by default"
This reverts commit c365c5921e.
2022-01-08 15:07:57 -05:00
git a5fffb314b * 2022-01-09 [ci skip] 2022-01-09 04:41:10 +09:00
John Hawthorn 18b97eee5a YJIT: Add support for ruby array cfuncs (argc=-2)
This adds support for cfuncs which take variable arguments using a Ruby
array. This is specified with the method entry's argc == -2.
2022-01-08 11:40:55 -08:00
John Hawthorn b5c039125f YJIT: Save SP later in cfunc call
Saving SP later allows us to avoid storing SP in an intermediate
register and allows using the ctx_stack_opnd helpers.
2022-01-08 11:40:55 -08:00
Peter Zhu 09cfc653b7 [ruby/reline] Fix reline on Solaris
Solaris requires that the pointer errret_int is alined to an integer,
however, with VWA, strings are no longer aligned to an integer, so use a
Fiddle::Pointer with a malloc'd region instead.

https://github.com/ruby/reline/commit/5fcd89ab0c
2022-01-08 20:32:06 +09:00
Samuel Williams 0ca00e2cb7
Move IO write buffer allocation into function. 2022-01-09 00:03:16 +13:00
Nobuyoshi Nakada 47a05f7c09
Do not run the same tests twice 2022-01-08 14:47:59 +09:00
Nobuyoshi Nakada fb532d801c
Run an old fixed bug in the same process 2022-01-08 14:47:49 +09:00
Nobuyoshi Nakada 64eccbf578
Run the tests on a subclass of String 2022-01-08 14:47:49 +09:00
Nobuyoshi Nakada 32a0d9dd4b
Prefer the dedecated conversion function 2022-01-08 12:49:39 +09:00
Alan Wu 54c91042ed YJIT: Discard local var type info on routine call
Routines that are called from YJIT's output code can call methods, and
calling methods mean they can capture and change the environment of the
calling frame.

Discard type info whenever we perform routine calls. This is more
conservative than strictly necessary as some routines need to perform GC
allocation but can never call methods and so should never be able to
change local variables. However, manually analyzing C functions for
whether they have code paths that call methods is error prone and can go
out of date as changes land in the codebase.

Closes: shopify/yjit#300
2022-01-07 19:29:03 -05:00
Peter Zhu bc643bbe2e Use unsigned short for length of embedded strings 2022-01-07 15:48:06 -05:00
Peter Zhu d9ef711f29 Improve string info in rb_raw_obj_info
Improve rb_raw_obj_info to output additional into about strings
including the length, capacity, and whether or not it is embedded.
2022-01-07 14:22:32 -05:00
Peter Zhu c365c5921e Enable Variable Width Allocation by default 2022-01-07 13:27:13 -05:00
git a1bef7c2ef * 2022-01-08 [ci skip] 2022-01-08 00:50:17 +09:00
Peter Zhu be68b3a490 Change termlen when changing encoding during concatenation
After changing the encoding, we should update the terminator length.
2022-01-07 10:50:03 -05:00
Nobuyoshi Nakada 3f9af8a9dc
[DOC] Fix typos in a doxygen comment [ci skip] 2022-01-07 23:55:59 +09:00
Kazuhiro NISHIYAMA 533bc77170
Fix typo [ci skip] 2022-01-07 09:44:33 +09:00
Jeremy Evans dd6a75195a [ruby/pathname] Make Pathname#each_entry return enumerator if called without block
Fixes [Bug #18158]

https://github.com/ruby/pathname/commit/914c726aa2
2022-01-07 09:42:09 +09:00
Nobuyoshi Nakada 6baa78bb78 Use chomp: option when chomp mode
Get rid of depending on using $/ internally in String#chomp!, and
chomp the separator at once.
2022-01-07 09:23:38 +09:00
Nobuyoshi Nakada 83b987054a Explicitly pass $/ when loop mode
Get rid of depending on using $/ internally in ARGF.gets.
2022-01-07 09:23:38 +09:00
Peter Zhu ae0d67d762 Revert "Set encoding before concatenating to string"
This reverts commit 44368b5f8b.
2022-01-06 17:23:05 -05:00
Peter Zhu aeb344e65c Revert "Enable Variable Width Allocation by default"
This reverts commit d4a95428bb.
2022-01-06 16:47:49 -05:00
Peter Zhu 5f55b03716 Set correct termlen for frozen strings
Frozen strings should have the same termlen as the original string when
copy_encoding is true.
2022-01-06 14:33:35 -05:00
Peter Zhu 44368b5f8b Set encoding before concatenating to string
If we set encoding after the call to rb_str_buf_cat, then rb_str_buf_cat
will not set the correct terminator length.
2022-01-06 14:33:35 -05:00
Peter Zhu ee4784c06e Update lldb_cruby.py for VWA strings 2022-01-06 14:33:35 -05:00
Peter Zhu 3818cfbd47 Compile with USE_RVARGC=0 on CI 2022-01-06 14:33:35 -05:00
Peter Zhu d4a95428bb Enable Variable Width Allocation by default 2022-01-06 14:33:35 -05:00
Yuta Saito ae51f304d2 io_buffer.c: use mremap based resizing only when mremap available
some libc implementations (e.g. wasi-libc) define MREMAP_MAYMOVE, but
don't have mremap itself, so guard the use of mremap by HAVE_MREMAP
2022-01-07 02:13:19 +09:00
Burdette Lamar 5ad507d751
Enhanced RDoc for IO (#5402)
Treats:

    #ungetc
    #isatty
    #close_on_exec?
2022-01-06 10:47:51 -06:00
manga_osyo 1bfccba775 Add bugs.ruby links. 2022-01-07 01:13:04 +09:00
git 818fc85347 * 2022-01-07 [ci skip] 2022-01-07 01:03:49 +09:00
Jeremy Evans 3f6bfe49db Update test/ruby/test_module.rb
Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
2022-01-06 08:03:33 -08:00
Jeremy Evans 24b53b1f3a Remove unneeded line 2022-01-06 08:03:33 -08:00