<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/test/-ext-/debug, branch ruby_3_2</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>Fix `rb_profile_frames` output includes dummy main thread frame</title>
<updated>2022-07-26T01:43:44+00:00</updated>
<author>
<name>Ivo Anjo</name>
<email>ivo.anjo@datadoghq.com</email>
</author>
<published>2022-07-11T13:51:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=649bfbe00d8032fa2c0536e596a284f69926e87f'/>
<id>649bfbe00d8032fa2c0536e596a284f69926e87f</id>
<content type='text'>
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] (&lt;https://bugs.ruby-lang.org/issues/18907&gt;)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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] (&lt;https://bugs.ruby-lang.org/issues/18907&gt;)
</pre>
</div>
</content>
</entry>
<entry>
<title>vm_backtrace.c: let rb_profile_frames show cfunc frames</title>
<updated>2020-07-28T04:18:08+00:00</updated>
<author>
<name>Yusuke Endoh</name>
<email>mame@ruby-lang.org</email>
</author>
<published>2020-07-08T08:32:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=da31900d9d9e4e9dcd6381a23dd863b18fe65e3d'/>
<id>da31900d9d9e4e9dcd6381a23dd863b18fe65e3d</id>
<content type='text'>
... in addition to normal iseq frames.
It is sometimes useful to point the bottleneck more precisely.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
... in addition to normal iseq frames.
It is sometimes useful to point the bottleneck more precisely.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix rb_profile_frame_classpath to handle module singletons</title>
<updated>2020-05-07T15:46:36+00:00</updated>
<author>
<name>Jean Boussier</name>
<email>jean.boussier@gmail.com</email>
</author>
<published>2020-05-06T16:49:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=cbe4f75ef802f13d05f94e42274b65a062bd3666'/>
<id>cbe4f75ef802f13d05f94e42274b65a062bd3666</id>
<content type='text'>
Right now `SomeClass.method` is properly named, but `SomeModule.method`
is displayed as `#&lt;Module:0x000055eb5d95adc8&gt;.method` which makes
profiling annoying.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Right now `SomeClass.method` is properly named, but `SomeModule.method`
is displayed as `#&lt;Module:0x000055eb5d95adc8&gt;.method` which makes
profiling annoying.
</pre>
</div>
</content>
</entry>
<entry>
<title>Adjust indent</title>
<updated>2019-05-10T13:00:22+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2019-05-10T08:28:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=dc65e75101de94c0f88851d7d3eab56cb7232c7a'/>
<id>dc65e75101de94c0f88851d7d3eab56cb7232c7a</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>* remove trailing spaces.</title>
<updated>2018-09-21T06:41:09+00:00</updated>
<author>
<name>svn</name>
<email>svn@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2018-09-21T06:41:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=02cb9c932a6e1a25b5e04c77053face048a11eff'/>
<id>02cb9c932a6e1a25b5e04c77053face048a11eff</id>
<content type='text'>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64801 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64801 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>escape all env properly.</title>
<updated>2018-09-21T06:41:07+00:00</updated>
<author>
<name>ko1</name>
<email>ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2018-09-21T06:41:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=ac4b2d990c8484af7a214381e61d3494b6b858b1'/>
<id>ac4b2d990c8484af7a214381e61d3494b6b858b1</id>
<content type='text'>
* vm_backtrace.c (rb_debug_inspector_open): escape all env using
  `rb_vm_stack_to_heap()` before making bindings.
  [Bug #15105]

  There is a complicated story of this issue:
  Without this patch, IFUNC frame does not escaped. A IFUNC frame
  points to CFUNC ep as previous ep. However, CFUNC ep can be escaped
  because of making bindings of Ruby level frames.
  IFUNC's ep can points to invalidated ep and `rb_iter_break()` will
  fail. This is why `any?` fails.

* test/-ext-/debug/test_debug.rb: add a test.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64800 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* vm_backtrace.c (rb_debug_inspector_open): escape all env using
  `rb_vm_stack_to_heap()` before making bindings.
  [Bug #15105]

  There is a complicated story of this issue:
  Without this patch, IFUNC frame does not escaped. A IFUNC frame
  points to CFUNC ep as previous ep. However, CFUNC ep can be escaped
  because of making bindings of Ruby level frames.
  IFUNC's ep can points to invalidated ep and `rb_iter_break()` will
  fail. This is why `any?` fails.

* test/-ext-/debug/test_debug.rb: add a test.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64800 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "Fix use of `rb_profile_frames` start parameter"</title>
<updated>2018-04-27T00:13:51+00:00</updated>
<author>
<name>tenderlove</name>
<email>tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2018-04-27T00:13:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=c03f86b389d00cf45edf133c9aa23479e6efc06e'/>
<id>c03f86b389d00cf45edf133c9aa23479e6efc06e</id>
<content type='text'>
This reverts commit r63265.

ko1 said I should not have committed this! I'm sorry!

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63267 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit r63265.

ko1 said I should not have committed this! I'm sorry!

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63267 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix use of `rb_profile_frames` start parameter</title>
<updated>2018-04-26T22:49:00+00:00</updated>
<author>
<name>tenderlove</name>
<email>tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2018-04-26T22:49:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=d676ad1050c0f570d6a2d1f983c1223611d45570'/>
<id>d676ad1050c0f570d6a2d1f983c1223611d45570</id>
<content type='text'>
rb_profile_frames was always behaving as if the value given for the
start parameter was 0.

The reason for this was that it would check if (start &gt; 0) { then
continue without updating the control frame pointer or anything other
than decrementing start.

[ruby-core:86147] [Bug #14607]

Co-authored-by: Dylan Thacker-Smith &lt;Dylan.Smith@shopify.com&gt;

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63265 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
rb_profile_frames was always behaving as if the value given for the
start parameter was 0.

The reason for this was that it would check if (start &gt; 0) { then
continue without updating the control frame pointer or anything other
than decrementing start.

[ruby-core:86147] [Bug #14607]

Co-authored-by: Dylan Thacker-Smith &lt;Dylan.Smith@shopify.com&gt;

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63265 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>vm_backtrace.c: ignore ifunc frames</title>
<updated>2015-12-21T01:18:48+00:00</updated>
<author>
<name>nobu</name>
<email>nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2015-12-21T01:18:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=cc52f511b1d942f8542a4d909ce0a1375ea07738'/>
<id>cc52f511b1d942f8542a4d909ce0a1375ea07738</id>
<content type='text'>
* vm_backtrace.c (rb_profile_frames): ignore ifunc frames as it
  did before.  [ruby-core:72409] [Bug #11851]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53225 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* vm_backtrace.c (rb_profile_frames): ignore ifunc frames as it
  did before.  [ruby-core:72409] [Bug #11851]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53225 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
<entry>
<title>Add frozen_string_literal: false for all files</title>
<updated>2015-12-16T05:07:31+00:00</updated>
<author>
<name>naruse</name>
<email>naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e</email>
</author>
<published>2015-12-16T05:07:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=3e92b635fb5422207b7bbdc924e292e51e21f040'/>
<id>3e92b635fb5422207b7bbdc924e292e51e21f040</id>
<content type='text'>
When you change this to true, you may need to add more tests.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53141 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When you change this to true, you may need to add more tests.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53141 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
</pre>
</div>
</content>
</entry>
</feed>
