| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
This reverts commit 69ec3f70fab0c1c537c68fb135cc315181b1d750.
|
|
|
|
| |
This reverts commit 6eaac7cfac668d6669be694fd7b723c4982ed218.
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
[Feature #16182]
|
| |
|
| |
|
|
|
|
| |
ISeq#to_a is commented out because it's broken now
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Previously we were passing the memory_id. This was broken previously if
compaction was run (which changes the memory_id) and now that object_id
is a monotonically increasing number it was always broken.
This commit fixes this by defering removal from the object_id table
until finalizers have run (for objects with finalizers) and also copying
the SEEN_OBJ_ID flag onto the zombie objects.
|
| |
|
| |
|
|
|
|
| |
Define TracePoint in trace_point.rb and use __builtin_ syntax.
|
|
|
|
|
| |
Keep track of the number of times the compactor ran. I would like to
use this as a way to keep track of inline cache reference updates.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes object_id from being based on the objects location in
memory (or a nearby memory location in the case of a conflict) to be
based on an always increasing number.
This number is a Ruby Integer which allows it to overflow the size of a
pointer without issue (very unlikely to happen in real programs
especially on 64-bit, but a nice guarantee).
This changes obj_to_id_tbl and id_to_obj_tbl to both be maps of Ruby
objects to Ruby objects (previously they were Ruby object to C integer)
which simplifies updating them after compaction as we can run them
through gc_update_table_refs.
Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org>
|
| |
|
|
|
|
| |
This reverts commit bd2b314a05ae9192b3143e1e678a37c370d8a9ce.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes object_id from being based on the objects location in
memory (or a nearby memory location in the case of a conflict) to be
based on an always increasing number.
This number is a Ruby Integer which allows it to overflow the size of a
pointer without issue (very unlikely to happen in real programs
especially on 64-bit, but a nice guarantee).
This changes obj_to_id_tbl and id_to_obj_tbl to both be maps of Ruby
objects to Ruby objects (previously they were Ruby object to C integer)
which simplifies updating them after compaction as we can run them
through gc_update_table_refs.
Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org>
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
```
irb(main):001:0> RUBY_VERSION
=> "2.6.5"
irb(main):002:0> S = Struct.new(:foo, keyword_init: true)
=> S(keyword_init: true)
irb(main):003:0> S.new({foo: 23424}, 234) # I don't think this is intentional
=> #<struct S foo=23424>
irb(main):004:0>
```
Tightening this up should inform users when they are confused about
whether a struct is `keyword_init`.
|
| |
|
|
|
|
| |
Test included for the situation formerly was not working.
|
|
|
|
|
| |
Raises an error on end-exclusive ranges unless endless, regardless
the receiver.
|
|
|
|
|
| |
Allows a beginless/endless range, and an end-exclusive range
unless the receiver is smaller than its end.
|
|
|
|
|
| |
These tests rely on GC.stat and GC.last_gc_info, which are not
stable when GC.stress is true. Skip them for that case.
|
|
|
|
|
|
| |
Previously, the keyword hash was duped (which results in a regular
hash), but the dup was not marked as a keyword hash, causing the
hash not to be marked as keyword hash even though it should be.
|
|
|
| |
Sorry, f62f90367fc3bce6714e7c34cbd040e14e43fe07 is push miss.
|
|
|
|
|
|
|
| |
This mirrors the behavior when manually splatting a hash. This
mirrors the changes made in setup_parameters_complex in
6081ddd6e6f2297862b3c7e898d28a76b8f9240b, so that splatting to a
non-iseq method works the same as splatting to an iseq method.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Get rid of these redundant and useless warnings.
```
$ ruby -e 'def bar(a) a; end; def foo(...) bar(...) end; foo({})'
-e:1: warning: The last argument is used as the keyword parameter
-e:1: warning: for `foo' defined here
-e:1: warning: The keyword argument is passed as the last hash parameter
-e:1: warning: for `bar' defined here
```
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
This reverts commit fa8ac91e957a076f6df1adaecad7896817138009.
Previous behavior is intentional.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fiber#transfer previously made it impossible to resume the fiber
if it was transferred to (no resuming the target of Fiber#transfer).
However, the documentation specifies that you cannot resume a fiber
that has transferred to another fiber (no resuming the source of
Fiber#transfer), unless control is transferred back.
Fix the code by setting the transferred flag on the current/source
fiber, and unsetting the transferred flag on the target fiber.
Fixes [Bug #9664]
Fixes [Bug #12555]
|
| |
|
|
|
|
|
| |
`Integer.sqrt(0xffff_ffff_ffff_ffff ** 2)` caused assertion failure
because of integer overflow. [ruby-core:95453] [Bug #16269]
|
| |
|
| |
|