summaryrefslogtreecommitdiff
path: root/benchmark
diff options
context:
space:
mode:
authorKoichi Sasada <ko1@atdot.net>2021-10-22 18:06:36 +0900
committerKoichi Sasada <ko1@atdot.net>2021-10-23 01:32:55 +0900
commita7776077be7b1754b4306f00694a8f4d42009159 (patch)
tree8942a29b772f3d58f7af5bf5ce29ecf04db104b9 /benchmark
parentacb23454e57e1bbe828e7f3114430cab2d5db44c (diff)
add vm_ivar_of_class_set
benchmark for a class's ivar setter
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/5006
Diffstat (limited to 'benchmark')
-rw-r--r--benchmark/vm_ivar_of_class_set.yml11
1 files changed, 11 insertions, 0 deletions
diff --git a/benchmark/vm_ivar_of_class_set.yml b/benchmark/vm_ivar_of_class_set.yml
new file mode 100644
index 0000000000..2ea5199423
--- /dev/null
+++ b/benchmark/vm_ivar_of_class_set.yml
@@ -0,0 +1,11 @@
+prelude: |
+ class C
+ @a = 1
+ def self.a o
+ @a = o; @a = o; @a = o; @a = o; @a = o; @a = o;
+ end
+ end
+benchmark:
+ vm_ivar_of_class_set: |
+ a = C.a(nil)
+loop_count: 30000000