3件ヒット
[1-3件を表示]
(0.035秒)
検索結果
先頭3件
-
RubyVM
:: InstructionSequence . of(body) -> RubyVM :: InstructionSequence (54457.0) -
引数 body で指定した Proc、Method オブジェクトを元に RubyVM::InstructionSequence オブジェクトを作成して返します。
引数 body で指定した Proc、Method オブジェクトを元に
RubyVM::InstructionSequence オブジェクトを作成して返します。
@param body Proc、Method オブジェクトを指定します。
例1:irb で実行した場合
# proc
> p = proc { num = 1 + 2 }
> RubyVM::InstructionSequence.of(p)
> # => <RubyVM::InstructionSequence:block in irb_binding@(irb)>
# method
> def ... -
GC
:: Profiler . report(out = $ stdout) -> nil (18331.0) -
GC::Profiler.result の結果を out に出力します。
GC::Profiler.result の結果を out に出力します。
@param out 結果の出力先を指定します。デフォルトは $stdout です。
//emlist[例][ruby]{
GC::Profiler.enable
GC.start
GC::Profiler.report
# => GC 4 invokes.
# Index Invoke Time(sec) Use Size(byte) Total Size(byte) Total Object GC Time(ms)
# 1... -
GC
:: Profiler . result -> String (18028.0) -
GC のプロファイル情報をフォーマットし、文字列として返します。
GC のプロファイル情報をフォーマットし、文字列として返します。
プロファイル情報は、GC の発生ごとに集計します。
以下は、5 回 GC が発生した場合の実行例です。
$ ruby -e "GC::Profiler.enable; a = Array.new(100000){ 'aa' }; puts GC::Profiler.result"
GC 5 invokes.
Index Invoke Time(sec) Use Size(byte) Total Size(byte) Total Object ...