Age | Commit message (Collapse) | Author |
|
The current documentation for `rb_postponed_job_register_one()` is
explaining the differences with itself, where it should be explaining
the differences with `rb_postponed_job_register()`.
|
|
* rb_warn() does not warn if $VERBOSE is nil, the "always" is wrong.
* Talk about $VERBOSE and not -W since $VERBOSE can be changed at runtime.
|
|
|
|
|
|
Bit field's memory layout is implementation-defined.
See also:
https://wiki.sei.cmu.edu/confluence/display/c/EXP11-C.+Do+not+make+assumptions+regarding+the+layout+of+structures+with+bit-fields
If memory layout is implementation-defined, it's difficult to use from
FFI library such as Ruby-FFI.
Notes:
Merged: https://github.com/ruby/ruby/pull/8380
|
|
Except for the `RESUMED` event.
Notes:
Merged: https://github.com/ruby/ruby/pull/8383
|
|
Notes:
Merged-By: ioquatix <samuel@codeotaku.com>
|
|
(#8286)
Notes:
Merged-By: nurse <naruse@airemix.jp>
|
|
cf: https://github.com/llvm/llvm-project/commit/874217f99b99ab3c9026dc3b7bd84cd2beebde6e
Notes:
Merged: https://github.com/ruby/ruby/pull/8274
|
|
Notes:
Merged-By: maximecb <maximecb@ruby-lang.org>
|
|
fix [Feature #19572]
Notes:
Merged: https://github.com/ruby/ruby/pull/8150
|
|
Existing strscan releases rely on this C API. It means that the current
Ruby master doesn't work if your Gemfile.lock has strscan unless it's
locked to 3.0.7, which is not released yet.
To fix it, let's not remove the C API we've exposed to users.
|
|
rb_reg_onig_match performs preparation, error handling, and cleanup for
matching a regex against a string. This reduces repetitive code and
removes the need for StringScanner to access internal data of regex.
Notes:
Merged: https://github.com/ruby/ruby/pull/8123
|
|
Assume macros with the same prefix would be defined together.
|
|
Since edf01d4e82d8e44ee30ec41fbcb7f802bc8b8c5d, fake string treats
NULL as an empty string.
|
|
|
|
|
|
RARRAY_CONST_PTR now does the same things as RARRAY_CONST_PTR_TRANSIENT.
Notes:
Merged: https://github.com/ruby/ruby/pull/8071
|
|
RARRAY_PTR_USE now does the same things as RARRAY_PTR_USE_TRANSIENT.
Notes:
Merged: https://github.com/ruby/ruby/pull/8071
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/8071
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/7942
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/8066
|
|
Closes [Feature #19729]
Previously 2 bits of the flags on each RVALUE are reserved to store the
number of GC cycles that each object has survived. This commit
introduces a new bit array on the heap page, called age_bits, to store
that information instead.
This patch still reserves one of the age bits in the flags (the old
FL_PROMOTED0 bit, now renamed FL_PROMOTED).
This is set to 0 for young objects and 1 for old objects, and is used as
a performance optimisation for the write barrier. Fetching the age_bits
from the heap page and doing the required math to calculate if the
object was old or not would slow down the write barrier. So we keep this
bit synced in the flags for fast access.
Notes:
Merged: https://github.com/ruby/ruby/pull/7938
|
|
This compile time flag was removed in https://github.com/ruby/ruby/pull/7313
This commit cleans up some related dead code.
Notes:
Merged: https://github.com/ruby/ruby/pull/7982
|
|
st_copy allocates a st_table, which is not needed for hashes since it is
allocated by VWA and embedded, so this causes a memory leak.
The following script demonstrates the issue:
```ruby
20.times do
100_000.times do
{a: 1, b: 2, c: 3, d: 4, e: 5, f: 6, g: 7, h: 8, i: 9}
end
puts `ps -o rss= -p #{$$}`
end
```
Notes:
Merged: https://github.com/ruby/ruby/pull/8000
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/7983
|
|
* Make TAINT and UNTRUSTED flags zero
These flags do nothing already, and should break nothing.
* Remove TAINT and UNTRUSTED macros same as functions
These macros had been defined to use with `#ifdef`, but should not be
used anymore.
Notes:
Merged-By: maximecb <maximecb@ruby-lang.org>
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/7945
|
|
Since no type information is available for variadic arguments, 0 is
passed as `int` without promoting to pointer. On platforms where
`sizeof(int) < sizeof(void*)`, the terminator argument may be read
together with an adjoining word, and may not be found.
|
|
When copying from another regexp, copy already built `regex_t` instead
of re-compiling its source.
Notes:
Merged: https://github.com/ruby/ruby/pull/7922
|
|
* Add deprecations for public struct rb_io members.
Notes:
Merged-By: ioquatix <samuel@codeotaku.com>
|
|
* Unify length field for embedded and heap strings
The length field is of the same type and position in RString for both
embedded and heap allocated strings, so we can unify it.
* Remove RSTRING_EMBED_LEN
Notes:
Merged-By: maximecb <maximecb@ruby-lang.org>
|
|
Notes:
Merged-By: ioquatix <samuel@codeotaku.com>
|
|
POSIX reserves `_t` suffix in types.
Notes:
Merged-By: ioquatix <samuel@codeotaku.com>
|
|
This retries the compatible parts of the previously reverted PR so we can continue to update related code without breaking backwards compatibility.
Notes:
Merged-By: ioquatix <samuel@codeotaku.com>
|
|
This reverts commit 18e55fc1e1ec20e8f3166e3059e76c885fc9f8f2.
fix [Bug #19704]
https://bugs.ruby-lang.org/issues/19704
This breaks compatibility for extension libraries. Such changes
need a discussion.
|
|
* Add rb_io_path and rb_io_open_descriptor.
* Use rb_io_open_descriptor to create PTY objects
* Rename FMODE_PREP -> FMODE_EXTERNAL and expose it
FMODE_PREP I believe refers to the concept of a "pre-prepared" file, but
FMODE_EXTERNAL is clearer about what the file descriptor represents and
aligns with language in the IO::Buffer module.
* Ensure that rb_io_open_descriptor closes the FD if it fails
If FMODE_EXTERNAL is not set, then it's guaranteed that Ruby will be
responsible for closing your file, eventually, if you pass it to
rb_io_open_descriptor, even if it raises an exception.
* Rename IS_EXTERNAL_FD -> RUBY_IO_EXTERNAL_P
* Expose `rb_io_closed_p`.
* Add `rb_io_mode` to get IO mode.
---------
Co-authored-by: KJ Tsanaktsidis <ktsanaktsidis@zendesk.com>
Notes:
Merged-By: ioquatix <samuel@codeotaku.com>
|
|
* Documentation consistency.
* Improve consistency of `pread`/`pwrite` implementation when given length.
* Remove HAVE_PREAD / HAVE_PWRITE - it is no longer optional.
Notes:
Merged-By: ioquatix <samuel@codeotaku.com>
|
|
On Win32, currently, rb_nativethread_cond_t is an incomplete type
because it's a typedef for `struct rb_thread_cond_struct`. That means
you can't actually allocate a rb_nativethread_cond_t unless you also
include THREAD_IMPL_H (since its defined in thread_win32.h)
(alternatively, including vm_core.h also works).
Move the definition of rb_thread_cond_struct into thread_native.h to
alleviate this.
Notes:
Merged: https://github.com/ruby/ruby/pull/7865
|
|
generic RUBY_UBF_IO" on Windows. (#7848)
* Enable borked spec.
* Ensure win32 wrappers are visible and used.
* Reorganise `read`/`write`/`pipe` in `thread_spec.c`.
Notes:
Merged-By: ioquatix <samuel@codeotaku.com>
|
|
Notes:
Merged-By: ioquatix <samuel@codeotaku.com>
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/7742
|
|
These must not be changed once initialized.
|
|
* Refactor Regexp#match cache implementation
Improved variable and function names
Fixed [Bug 19537] (Maybe fixed in https://github.com/ruby/ruby/pull/7694)
* Add a comment of the glossary for "match cache"
* Skip to reset match cache when no cache point on null check
Notes:
Merged-By: makenowjust <make.just.on@gmail.com>
|
|
Followup: ac123f167a364c3d7a43eca78d564e41f6dbb91e
RB_WARN_CATEGORY_ALL_BITS is exposed in a public header, so it
makes sense for it to be updated to contain all valid bits.
Instead we introduce RB_WARN_CATEGORY_DEFAULT_BITS to list the
categories that are enabled by default.
Notes:
Merged: https://github.com/ruby/ruby/pull/7710
|
|
[Feature #19538]
This new `peformance` warning category is disabled by default.
It needs to be specifically enabled via `-W:performance` or `Warning[:performance] = true`
Notes:
Merged: https://github.com/ruby/ruby/pull/7708
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/7706
|
|
|
|
Remove !USE_RVARGC code
[Feature #19579]
The Variable Width Allocation feature was turned on by default in Ruby
3.2. Since then, we haven't received bug reports or backports to the
non-Variable Width Allocation code paths, so we assume that nobody is
using it. We also don't plan on maintaining the non-Variable Width
Allocation code, so we are going to remove it.
Notes:
Merged-By: maximecb <maximecb@ruby-lang.org>
|
|
* Skip test if non-blocking file IO is not supported.
Notes:
Merged-By: ioquatix <samuel@codeotaku.com>
|