зеркало из https://github.com/github/ruby.git
21 строка
288 B
YAML
21 строка
288 B
YAML
|
type: lib/benchmark_driver/runner/mjit
|
||
|
prelude: |
|
||
|
def mjit_class(obj)
|
||
|
obj.class
|
||
|
end
|
||
|
|
||
|
def mjit_frozen?(obj)
|
||
|
obj.frozen?
|
||
|
end
|
||
|
|
||
|
str = ""
|
||
|
fstr = "".freeze
|
||
|
|
||
|
benchmark:
|
||
|
- mjit_class(self)
|
||
|
- mjit_class(1)
|
||
|
- mjit_frozen?(str)
|
||
|
- mjit_frozen?(fstr)
|
||
|
|
||
|
loop_count: 40000000
|