1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/ext/-test-
Ivo Anjo 649bfbe00d Fix rb_profile_frames output includes dummy main thread frame
The `rb_profile_frames` API did not skip the two dummy frames that
each thread has at its beginning. This was unlike `backtrace_each` and
`rb_ec_parcial_backtrace_object`, which do skip them.

This does not seem to be a problem for non-main thread frames,
because both `VM_FRAME_RUBYFRAME_P(cfp)` and
`rb_vm_frame_method_entry(cfp)` are NULL for them.

BUT, on the main thread `VM_FRAME_RUBYFRAME_P(cfp)` was true
and thus the dummy thread was still included in the output of
`rb_profile_frames`.

I've now made `rb_profile_frames` skip this extra frame (like
`backtrace_each` and friends), as well as add a test that asserts
the size and contents of `rb_profile_frames`.

Fixes [Bug #18907] (<https://bugs.ruby-lang.org/issues/18907>)
2022-07-26 10:43:44 +09:00
..
abi [Feature #18249] Implement ABI checking 2022-02-22 09:55:21 -05:00
arith_seq/extract [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
array [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
bignum [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
bug-3571 [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
bug-5832 [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
bug-14834 [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
bug_reporter [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
class [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
cxxanyargs Update dependencies 2021-11-21 16:21:18 +09:00
debug Fix rb_profile_frames output includes dummy main thread frame 2022-07-26 10:43:44 +09:00
dln/empty Update ext/-test-/dln/empty/depend 2022-02-22 16:49:20 -05:00
enumerator_kw [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
exception [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
fatal [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
file Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
float [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
funcall Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
gvl/call_without_gvl Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
hash [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
integer [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
iseq_load [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
iter [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
load [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
marshal [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
memory_status Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
memory_view [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
method [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
notimplement [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
num2int [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
path_to_class [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
popen_deadlock [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
postponed_job [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
printf Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
proc Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
random [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
rational [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
rb_call_super_kw [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
recursion Restore rb_exec_recursive_outer 2022-06-15 16:07:29 -07:00
regexp [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
RUBY_ALIGNOF [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
scan_args [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
st Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
string Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
struct Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
symbol Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
thread/instrumentation Make a local symbol static 2022-07-08 10:55:44 +09:00
thread_fd [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
time [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
tracepoint Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
typeddata Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
vm Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
wait [Feature #18249] Update dependencies 2022-02-22 09:55:21 -05:00
win32 Expand tabs [ci skip] 2022-07-21 09:42:04 -07:00
auto_ext.rb [ruby/fiddle] Create extconf header for MSVC 2021-09-05 17:31:46 +09:00