aboutsummaryrefslogtreecommitdiffstats
path: root/rjit_c.rb
diff options
context:
space:
mode:
authorJean Boussier <byroot@ruby-lang.org>2023-10-10 13:12:17 +0200
committerJean Boussier <jean.boussier@gmail.com>2023-10-10 14:47:54 +0200
commit5cc44f48c51974a84a40480477a4afd8901ae7e4 (patch)
tree9c252adf59e2e0b932a74a7d0cf000969039e97d /rjit_c.rb
parentfd21460898d2d5044c1bcc140927142921424791 (diff)
downloadruby-5cc44f48c51974a84a40480477a4afd8901ae7e4.tar.gz
Refactor rb_shape_transition_shape_capa to not accept capacity
This way the groth factor is encapsulated, which allows rb_shape_transition_shape_capa to be smarter about ideal sizes.
Diffstat (limited to 'rjit_c.rb')
-rw-r--r--rjit_c.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/rjit_c.rb b/rjit_c.rb
index ef99df211a..72e8221cbc 100644
--- a/rjit_c.rb
+++ b/rjit_c.rb
@@ -171,9 +171,9 @@ module RubyVM::RJIT # :nodoc: all
me_addr == 0 ? nil : rb_method_entry_t.new(me_addr)
end
- def rb_shape_transition_shape_capa(shape, new_capacity)
+ def rb_shape_transition_shape_capa(shape)
_shape = shape.to_i
- shape_addr = Primitive.cexpr! 'SIZET2NUM((size_t)rb_shape_transition_shape_capa((rb_shape_t *)NUM2SIZET(_shape), NUM2UINT(new_capacity)))'
+ shape_addr = Primitive.cexpr! 'SIZET2NUM((size_t)rb_shape_transition_shape_capa((rb_shape_t *)NUM2SIZET(_shape)))'
rb_shape_t.new(shape_addr)
end