| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
https://github.com/rubygems/rubygems/commit/08a0a5b7d1
|
|
|
|
|
|
|
|
|
|
| |
Since 4d8f76286beefbb8f7fba2479f6d0a0b4a47304c, we need to dereference
the includer field on iclasses, so we need to mark it to make sure
it's alive.
Sometimes during compaction we crash because the field is dangling,
though I have a hard time constructing such a situation. See
http://ci.rvm.jp/results/trunk@ruby-iga/3947725
|
|
|
|
|
|
|
|
|
|
|
|
| |
While walking over the list of subclasses for `include` and friends, we
check whether the subclass is a garbage object. After the check, we
allocate objects which might trigger GC and make the subclass garbage,
even though before the allocation the subclass was not garbage. This is
a sort of time-of-check-time-of-use issue.
Fix this by saving the weak reference to a local variable, upgrading it
to a strong reference while we do the allocation. It makes the code look
slightly nicer even if it doesn't fix any runtime issues.
|
| |
|
|
|
|
|
|
|
|
|
| |
Treats:
::pipe?
::symlink?
::socket?
::blockdev?
::chardev?
|
| |
|
|
|
|
|
|
| |
[0..0] internally creates an extra Array object, and so is slower and much more memory consuming
https://github.com/ruby/logger/commit/20616ad34a
|
| |
|
|
|
|
|
|
| |
* Update doc/format_specifications.rdoc
Co-authored-by: Peter Zhu <peter@peterzhu.ca>
|
| |
|
| |
|
| |
|
|
|
|
| |
`start` is of type uintptr_t so it does not need to be casted to VALUE.
|
|
|
|
| |
https://github.com/rubygems/rubygems/commit/fa0ac74883
|
|
|
|
| |
https://github.com/rubygems/rubygems/commit/fabc357e70
|
|
|
|
| |
https://github.com/rubygems/rubygems/commit/c43d5f979a
|
|
|
|
| |
https://github.com/rubygems/rubygems/commit/ea09bc4680
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We didn't update the includer field during compaction so it could become
a dangling pointer after compaction. It's only recently that we started
to dereference the field, and we were only comparing the pointer before
then, so the omission only recently started to cause crashes.
By instrumenting object.c:833 with `rp(includer);`, you can see the
includer field become `T_NONE` with the following script:
```ruby
mod = Module.new do
protected def foo = 1
end
klass = Class.new do
include Module.new
def run
foo
end
end
klass.include(mod)
GC.verify_compaction_references(double_heap: true, toward: :empty)
klass.new.run
```
I found a crash in a private application that this patch fixes, but
wasn't able to develop a small reproducer. Hence the above demo that
requires instrumentation.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
darray was used in YJIT which required the functions to not trigger GC.
YJIT has now moved to Rust and does not use darray anymore, so we can
remove the functions that don't trigger GC and only keep the ones that
trigger GC.
|
|
|
| |
Turned out to be a one-character fix :)
|
|
|
|
|
| |
YJIT can't support these builds so it's better to reject with a message
than to crash at runtime.
|
|
|
|
|
|
|
| |
The `capstone` crate on crates.io does not need `libcapstone` on the system
because it builds from [source].
`gdbm` is now a separate gem (thanks for extracting it!).
[source]: https://github.com/capstone-rust/capstone-rs/blob/c31409905a9fc4581133de248fcd0a66b2c37e36/capstone-sys/build.rs#L143
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
(https://github.com/ruby/getoptlong/pull/4)
Detailed introductory material.
https://github.com/ruby/getoptlong/commit/1544f2fb7b
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Follow up https://github.com/ruby/ruby/commit/0514d81
Rust YJIT requires Rust 1.60.0 or later. So, `extern crate` looks unnecessary
because it can use the following Rust 2018 edition feature:
https://doc.rust-lang.org/stable/edition-guide/rust-2018/path-changes.html#no-more-extern-crate
It passes the following tests.
```console
% cd yjit
% cargo test --features asm_comments,disasm
(snip)
test result: ok. 56 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 1 to 2.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/v1...v2)
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
|
| |
|
| |
|
|
|
|
|
| |
* Repair internal links
* Minor changes to format spec
|
|
|
|
|
| |
* Discussion is as per https://bugs.ruby-lang.org/issues/18611.
Co-authored-by: Sam Bostock <sam.bostock@shopify.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
`rustc` performs in depth dead code analysis and issues warning
even for things like unused struct fields and unconstructed enum
variants. This was annoying for us during the port but hopefully
they are less of an issue now.
This patch enables all the unused warnings we disabled and address
all the warnings we previously ignored. Generally, the approach I've
taken is to use `cfg!` instead of using the `cfg` attribute and
to delete code where it makes sense. I've put `#[allow(unused)]`
on things we intentionally keep around for printf style debugging
and on items that are too annoying to keep warning-free in all
build configs.
|
|
|
| |
This new document would eventually replace the format spec discussion at Kernel#sprintf.
|
| |
|
|
|
|
|
|
|
|
|
| |
This adopts most suggestions that rust-clippy is confident enough to
auto apply. The manual changes mostly fix manual if-lets and take
opportunities to use the `Default` trait on standard collections.
Co-authored-by: Kevin Newton <kddnewton@gmail.com>
Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com>
|
|
|
|
| |
is disabled (#5863)
|
|
|
|
| |
https://github.com/rubygems/rubygems/commit/cbf13edd3a
|
|
|
|
| |
https://github.com/rubygems/rubygems/commit/28864b1057
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, we relied on shell word splitting, which leads
to passing the wrong arguments when there are white spaces
in the path.
Avoiding command substitution also makes this script more
likely to work under Solaris 10, where `/bin/sh` is not
POSIX compliant [1]. (Thanks you, `@znz` for fixing the syntax
error in 4210ae2158b545beda908fb29e03d23994f262e3 though!)
The hack from c466f270b891962518763ad299f907beac0ebf62
doesn't actually work so this commit reverts it. The shell
still needs to parse through all of the code, maybe because
make doesn't in fact send newlines to the shell.
By the way, we also use the `-exec` option in the `ext/distclean` task.
[1]: https://docs.oracle.com/cd/E26505_01/html/816-5165/sh-1.html
|
|
|
|
|
|
|
|
| |
This fixes a bug where Ruby on macOS running on ARM would try to look in
`/usr/local/lib` for things to link against, but the libraries in that
directory are from the x86 installation of Homebrew
[ruby-core:108424]
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* YJIT: replace BLOCKID_NULL with Option<BlockId>, more idiomatic
* Update yjit/src/core.rs
Co-authored-by: Alan Wu <XrXr@users.noreply.github.com>
* Update yjit/src/core.rs
Co-authored-by: Alan Wu <XrXr@users.noreply.github.com>
Co-authored-by: Alan Wu <XrXr@users.noreply.github.com>
|
| |
|
|
|
|
|
|
|
| |
Previously it made object references without using write barriers,
creating GC inconsistencies.
See: http://ci.rvm.jp/results/trunk-gc-asserts@phosphorus-docker/3925529
|
| |
|
| |
|
|
|
|
| |
https://github.com/rubygems/rubygems/commit/3f7d0352e84b29d4a2d4cd93b31e5ebdb5f79cc6
|