aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* * 2021-06-17 [ci skip]git2021-06-171-1/+1
|
* * expand tabs. [ci skip]git2021-06-171-11/+11
| | | | | Tabs were expanded because the file did not have any tab indentation in unedited lines. Please update your editor config, and use misc/expand_tabs.rb in the pre-commit hook.
* Enable frozen_string_literal in builtin_iseq_loadJohn Hawthorn2021-06-161-1/+14
| | | | | | Currently this has a fairly minor effect as strings are not used heavily inside the builtins (outside of warnings, requires, and errors). Hopefully this allows us to use strings in the future where appropriate.
* [ruby/net-protocol] Get rid of `__send__`Nobuyoshi Nakada2021-06-161-6/+5
| | | | | | | Mitigate the security risk: https://devcraft.io/2021/01/07/universal-deserialisation-gadget-for-ruby-2-x-3-x.html https://github.com/ruby/net-protocol/commit/a9970437e8
* Fixed comments in cmd.exe script [ci skip]Nobuyoshi Nakada2021-06-161-2/+2
|
* Removed redundant NUM2IOCTLREQ definition [Bug #17759]Nobuyoshi Nakada2021-06-161-1/+0
| | | | Fix up c2d9967f78d2e6f93f8d9876c2b3ab25aa6b86e7.
* Configure ioctl request argument type [Bug #17759]Nobuyoshi Nakada2021-06-162-2/+32
|
* * 2021-06-16 [ci skip]git2021-06-161-1/+1
|
* Make ext directory before extinit.c when out-of-place buildNobuyoshi Nakada2021-06-161-0/+1
|
* Time#getlocal tests for [Feature #17544]Nobuyoshi Nakada2021-06-151-0/+10
|
* Convert initial contents before allocating queue bufferNobuyoshi Nakada2021-06-151-2/+4
|
* [ruby/ostruct] v0.4.0Marc-Andre Lafortune2021-06-151-1/+1
| | | | https://github.com/ruby/ostruct/commit/8534f69e4e
* [Bug #17880] Set leaf false on opt_setinlinecache (#4565)Eileen M. Uchitelle2021-06-142-0/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change fixes the bug described in https://bugs.ruby-lang.org/issues/17880. Checking `ractor_shareable_p` will cause the method to call back into Ruby. Anything calling this method can't be a leaf instruction, otherwise it could crash. By adding `attr bool leaf = false` we no longer crash because it marks the function as not a leaf. Here's a simplified reproduction script: ```ruby require "set" class Id attr_reader :db_id def initialize(db_id) @db_id = db_id end def ==(other) other.class == self.class && other.db_id == db_id end alias_method :eql?, :== def hash 10 end def <=>(other) db_id <=> other.db_id if other.is_a?(self.class) end end class Namespace IDS = Set[ Id.new(1).freeze, Id.new(2).freeze, Id.new(3).freeze, Id.new(4).freeze, ].freeze class << self def test?(id) IDS.include?(id) end end end p Namespace.test?(Id.new(1)) p Namespace.test?(Id.new(5)) ``` Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org> Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org>
* [lib/ostruct] Fix YAML testMarc-Andre Lafortune2021-06-141-3/+3
|
* [lib/ostruct] Allow overriding of `block_given?`Marc-Andre Lafortune2021-06-142-3/+7
|
* * 2021-06-15 [ci skip]git2021-06-151-1/+1
|
* Suppress exception report in inner threadNobuyoshi Nakada2021-06-151-1/+3
|
* Close leaked file descriptorsNobuyoshi Nakada2021-06-152-0/+5
|
* [ruby/ostruct] bump upNobuyoshi Nakada2021-06-141-3/+3
| | | | https://github.com/ruby/ostruct/commit/bb253be3e9
* Suppress gcc11 clobbered warningNobuyoshi Nakada2021-06-141-1/+5
|
* Add fallback block to `OpenStruct#delete_field` (#1409)jfrazx2021-06-142-3/+20
|
* prefer cc/gcc over clang on solaris卜部昌平2021-06-141-1/+8
| | | | requested by tankf33der at https://bugs.ruby-lang.org/issues/17949#change-92430
* Fixed method names in exception messagesNobuyoshi Nakada2021-06-141-4/+4
| | | | | These methods are not !-suffixed, and the messages were very confusing.
* Fix fiber scheduler address resolve solaris testsBruno Sutic2021-06-141-5/+2
|
* Revert "Suppress gcc11 clobbered warning"Samuel Williams2021-06-141-3/+1
| | | | This reverts commit f0f9e77b65990001bd2acb42e1c6b673f6324425.
* Wake up join list within thread EC context. (#4471)Samuel Williams2021-06-146-81/+167
| | | | | | | | | | | | | | | * Wake up join list within thread EC context. * Consume items from join list so that they are not re-executed. If `rb_fiber_scheduler_unblock` raises an exception, it can result in a segfault if `rb_threadptr_join_list_wakeup` is not within a valid EC. This change moves `rb_threadptr_join_list_wakeup` into the thread's top level EC which initially caused an infinite loop because on exception will retry. We explicitly remove items from the thread's join list to avoid this situation. * Verify the required scheduler interface. * Test several scheduler hooks methods with broken `unblock` implementation.
* Removed no longer used variablesNobuyoshi Nakada2021-06-141-1/+0
|
* Pack values to preserveNobuyoshi Nakada2021-06-141-6/+8
|
* Suppress gcc11 clobbered warningNobuyoshi Nakada2021-06-141-1/+3
|
* Add scheduler hook `Addrinfo.getaddrinfo`. (#4375)Samuel Williams2021-06-149-278/+626
| | | Co-authored-by: Bruno Sutic <code@brunosutic.com>
* time.c: Check if defined(RUBY_MSVCRT_VERSION) to build on SolarisYusuke Endoh2021-06-141-1/+1
| | | | Fixes [Bug #17947]
* * 2021-06-14 [ci skip]git2021-06-141-1/+1
|
* parse.y: Fix the location of a target constant of OP_CDECLYusuke Endoh2021-06-141-1/+2
| | | | | | | | ``` p RubyVM::AbstractSyntaxTree.parse("::Foo += 1").children #=> before: [[], nil, (OP_CDECL@1:0-1:10 (COLON3@1:0-1:10 :Foo) :+ (LIT@1:9-1:10 1))] #=> after: [[], nil, (OP_CDECL@1:0-1:10 (COLON3@1:0-1:5 :Foo) :+ (LIT@1:9-1:10 1))] ```
* Suppress array-parameter warnings by gcc 11Nobuyoshi Nakada2021-06-131-6/+6
|
* Added parentheses to silence sizeof-array-div warningsNobuyoshi Nakada2021-06-131-1/+1
| | | | As well as 2366c681166a1dab95de6b9ca8ffcaae18aadd39.
* Removed duplicate includeNobuyoshi Nakada2021-06-131-1/+1
|
* Check if alternative malloc header can work in C++Nobuyoshi Nakada2021-06-131-0/+4
| | | | | jemalloc (5.2.1 at least) cannot compile in C++ on macOS SDK, due to conflicts on exception specification.
* * 2021-06-13 [ci skip]git2021-06-131-1/+1
|
* Refactor rb_block_call functionS.H2021-06-131-8/+3
| | | | rb_block_call and rb_block_call_kw have similar code. So, using rb_block_kw function in rb_block_call function for refactoring.
* * 2021-06-12 [ci skip]git2021-06-121-1/+1
|
* cont.c: Replace "iff" with "if and only if"nagachika2021-06-121-1/+1
|
* * 2021-06-11 [ci skip]git2021-06-111-1/+1
|
* Crash more nicely when the VM isn't fully set upAaron Patterson2021-06-101-30/+32
| | | | If we crash but the VM isn't fully alive, we can get an infinite loop.
* Finish GC before calling gc_set_initial_pagesPeter Zhu2021-06-101-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we are during incremental sweeping when calling gc_set_initial_pages there is an assertion error. The following patch will artificially produce the bug: ``` diff --git a/gc.c b/gc.c index c3157dbe2c..d7282cf8f0 100644 --- a/gc.c +++ b/gc.c @@ -404,7 +404,7 @@ int ruby_rgengc_debug; * 5: show all references */ #ifndef RGENGC_CHECK_MODE -#define RGENGC_CHECK_MODE 0 +#define RGENGC_CHECK_MODE 1 #endif // Note: using RUBY_ASSERT_WHEN() extend a macro in expr (info by nobu). @@ -10821,6 +10821,10 @@ gc_set_initial_pages(void) void ruby_gc_set_params(void) { + for (int i = 0; i < 10000; i++) { + rb_ary_new(); + } + /* RUBY_GC_HEAP_FREE_SLOTS */ if (get_envparam_size("RUBY_GC_HEAP_FREE_SLOTS", &gc_params.heap_free_slots, 0)) { /* ok */ ``` The crash looks like: ``` Assertion Failed: ../gc.c:2038:heap_add_page:!(heap == heap_eden && heap->sweeping_page) ```
* Add missing dependenciesTakashi Kokubun2021-06-101-1/+2
| | | | https://github.com/ruby/ruby/runs/2791163586?check_suite_focus=true
* Cast jit_func for WindowsTakashi Kokubun2021-06-101-1/+1
| | | | https://ci.appveyor.com/project/ruby/ruby/builds/39542385/job/8b7aq951f9t01x4x
* Avoid enqueueing the same ISeq twiceTakashi Kokubun2021-06-104-12/+23
| | | | | | | | | | by a race condition by multiple Ractors. Atmically incrementing body->total_calls may have its own cost, so for now we intentionally leave the unreliable total_calls. So we allow an ISeq to be never pushed when you use multiple Ractors. However, if you enqueue a single ccan node twice, get_from_list loops infinitely. Thus this patch takes care of such a situation.
* Freeze command line scriptNobuyoshi Nakada2021-06-101-0/+1
|
* Refactor gc_marks_start_heap to only configure heapPeter Zhu2021-06-091-10/+13
| | | | Move the non-heap related configurations to gc_marks_start.
* * 2021-06-10 [ci skip]git2021-06-101-1/+1
|