ruby-prof 0.17.0 → 0.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -5
 - data/CHANGES +500 -482
 - data/LICENSE +24 -24
 - data/README.rdoc +487 -485
 - data/Rakefile +113 -113
 - data/bin/ruby-prof +345 -345
 - data/bin/ruby-prof-check-trace +45 -45
 - data/examples/flat.txt +50 -50
 - data/examples/graph.dot +84 -84
 - data/examples/graph.html +823 -823
 - data/examples/graph.txt +139 -139
 - data/examples/multi.flat.txt +23 -23
 - data/examples/multi.graph.html +760 -760
 - data/examples/multi.grind.dat +114 -114
 - data/examples/multi.stack.html +547 -547
 - data/examples/stack.html +547 -547
 - data/ext/ruby_prof/extconf.rb +68 -68
 - data/ext/ruby_prof/rp_call_info.c +425 -425
 - data/ext/ruby_prof/rp_call_info.h +53 -53
 - data/ext/ruby_prof/rp_measure.c +40 -40
 - data/ext/ruby_prof/rp_measure.h +45 -45
 - data/ext/ruby_prof/rp_measure_allocations.c +76 -76
 - data/ext/ruby_prof/rp_measure_cpu_time.c +136 -136
 - data/ext/ruby_prof/rp_measure_gc_runs.c +73 -73
 - data/ext/ruby_prof/rp_measure_gc_time.c +60 -60
 - data/ext/ruby_prof/rp_measure_memory.c +77 -77
 - data/ext/ruby_prof/rp_measure_process_time.c +71 -71
 - data/ext/ruby_prof/rp_measure_wall_time.c +45 -45
 - data/ext/ruby_prof/rp_method.c +630 -636
 - data/ext/ruby_prof/rp_method.h +75 -75
 - data/ext/ruby_prof/rp_stack.c +173 -173
 - data/ext/ruby_prof/rp_stack.h +63 -63
 - data/ext/ruby_prof/rp_thread.c +277 -276
 - data/ext/ruby_prof/rp_thread.h +27 -27
 - data/ext/ruby_prof/ruby_prof.c +794 -774
 - data/ext/ruby_prof/ruby_prof.h +60 -59
 - data/ext/ruby_prof/vc/ruby_prof.sln +20 -21
 - data/ext/ruby_prof/vc/{ruby_prof_20.vcxproj → ruby_prof.vcxproj} +31 -0
 - data/lib/ruby-prof.rb +68 -68
 - data/lib/ruby-prof/aggregate_call_info.rb +76 -76
 - data/lib/ruby-prof/assets/call_stack_printer.css.html +116 -116
 - data/lib/ruby-prof/assets/call_stack_printer.js.html +384 -384
 - data/lib/ruby-prof/call_info.rb +115 -115
 - data/lib/ruby-prof/call_info_visitor.rb +40 -40
 - data/lib/ruby-prof/compatibility.rb +179 -178
 - data/lib/ruby-prof/method_info.rb +121 -121
 - data/lib/ruby-prof/printers/abstract_printer.rb +104 -103
 - data/lib/ruby-prof/printers/call_info_printer.rb +41 -41
 - data/lib/ruby-prof/printers/call_stack_printer.rb +265 -265
 - data/lib/ruby-prof/printers/call_tree_printer.rb +143 -143
 - data/lib/ruby-prof/printers/dot_printer.rb +132 -132
 - data/lib/ruby-prof/printers/flat_printer.rb +70 -70
 - data/lib/ruby-prof/printers/flat_printer_with_line_numbers.rb +83 -83
 - data/lib/ruby-prof/printers/graph_html_printer.rb +249 -249
 - data/lib/ruby-prof/printers/graph_printer.rb +116 -116
 - data/lib/ruby-prof/printers/multi_printer.rb +84 -84
 - data/lib/ruby-prof/profile.rb +26 -26
 - data/lib/ruby-prof/profile/exclude_common_methods.rb +207 -201
 - data/lib/ruby-prof/profile/legacy_method_elimination.rb +50 -49
 - data/lib/ruby-prof/rack.rb +174 -174
 - data/lib/ruby-prof/task.rb +147 -147
 - data/lib/ruby-prof/thread.rb +35 -35
 - data/lib/ruby-prof/version.rb +3 -3
 - data/lib/unprof.rb +10 -10
 - data/ruby-prof.gemspec +58 -58
 - data/test/abstract_printer_test.rb +53 -0
 - data/test/aggregate_test.rb +136 -136
 - data/test/basic_test.rb +128 -128
 - data/test/block_test.rb +74 -74
 - data/test/call_info_test.rb +78 -78
 - data/test/call_info_visitor_test.rb +31 -31
 - data/test/duplicate_names_test.rb +32 -32
 - data/test/dynamic_method_test.rb +55 -55
 - data/test/enumerable_test.rb +21 -21
 - data/test/exceptions_test.rb +24 -16
 - data/test/exclude_methods_test.rb +146 -146
 - data/test/exclude_threads_test.rb +53 -53
 - data/test/fiber_test.rb +79 -79
 - data/test/issue137_test.rb +63 -63
 - data/test/line_number_test.rb +80 -80
 - data/test/measure_allocations_test.rb +26 -26
 - data/test/measure_cpu_time_test.rb +212 -213
 - data/test/measure_gc_runs_test.rb +32 -32
 - data/test/measure_gc_time_test.rb +36 -36
 - data/test/measure_memory_test.rb +33 -33
 - data/test/measure_process_time_test.rb +61 -63
 - data/test/measure_wall_time_test.rb +255 -255
 - data/test/method_elimination_test.rb +84 -84
 - data/test/module_test.rb +45 -45
 - data/test/multi_printer_test.rb +104 -104
 - data/test/no_method_class_test.rb +15 -15
 - data/test/pause_resume_test.rb +166 -166
 - data/test/prime.rb +54 -54
 - data/test/printers_test.rb +275 -275
 - data/test/printing_recursive_graph_test.rb +127 -127
 - data/test/rack_test.rb +157 -157
 - data/test/recursive_test.rb +215 -215
 - data/test/singleton_test.rb +38 -38
 - data/test/stack_printer_test.rb +77 -78
 - data/test/stack_test.rb +138 -138
 - data/test/start_stop_test.rb +112 -112
 - data/test/test_helper.rb +267 -275
 - data/test/thread_test.rb +187 -187
 - data/test/unique_call_path_test.rb +202 -202
 - data/test/yarv_test.rb +55 -55
 - metadata +17 -96
 - data/doc/LICENSE.html +0 -115
 - data/doc/README_rdoc.html +0 -637
 - data/doc/Rack.html +0 -96
 - data/doc/Rack/RubyProf.html +0 -233
 - data/doc/Rack/RubyProf/RackProfiler.html +0 -343
 - data/doc/RubyProf.html +0 -974
 - data/doc/RubyProf/AbstractPrinter.html +0 -625
 - data/doc/RubyProf/AggregateCallInfo.html +0 -552
 - data/doc/RubyProf/CallInfo.html +0 -579
 - data/doc/RubyProf/CallInfoPrinter.html +0 -121
 - data/doc/RubyProf/CallInfoVisitor.html +0 -199
 - data/doc/RubyProf/CallStackPrinter.html +0 -1127
 - data/doc/RubyProf/CallTreePrinter.html +0 -725
 - data/doc/RubyProf/Cmd.html +0 -637
 - data/doc/RubyProf/DeprecationWarnings.html +0 -148
 - data/doc/RubyProf/DotPrinter.html +0 -258
 - data/doc/RubyProf/FlatPrinter.html +0 -164
 - data/doc/RubyProf/FlatPrinterWithLineNumbers.html +0 -210
 - data/doc/RubyProf/GraphHtmlPrinter.html +0 -558
 - data/doc/RubyProf/GraphPrinter.html +0 -140
 - data/doc/RubyProf/MethodInfo.html +0 -676
 - data/doc/RubyProf/MultiPrinter.html +0 -574
 - data/doc/RubyProf/Profile.html +0 -908
 - data/doc/RubyProf/Profile/ExcludeCommonMethods.html +0 -411
 - data/doc/RubyProf/Profile/LegacyMethodElimination.html +0 -158
 - data/doc/RubyProf/ProfileTask.html +0 -491
 - data/doc/RubyProf/Thread.html +0 -275
 - data/doc/created.rid +0 -33
 - data/doc/css/fonts.css +0 -167
 - data/doc/css/rdoc.css +0 -590
 - data/doc/examples/flat_txt.html +0 -139
 - data/doc/examples/graph_html.html +0 -910
 - data/doc/examples/graph_txt.html +0 -248
 - data/doc/fonts/Lato-Light.ttf +0 -0
 - data/doc/fonts/Lato-LightItalic.ttf +0 -0
 - data/doc/fonts/Lato-Regular.ttf +0 -0
 - data/doc/fonts/Lato-RegularItalic.ttf +0 -0
 - data/doc/fonts/SourceCodePro-Bold.ttf +0 -0
 - data/doc/fonts/SourceCodePro-Regular.ttf +0 -0
 - data/doc/images/add.png +0 -0
 - data/doc/images/arrow_up.png +0 -0
 - data/doc/images/brick.png +0 -0
 - data/doc/images/brick_link.png +0 -0
 - data/doc/images/bug.png +0 -0
 - data/doc/images/bullet_black.png +0 -0
 - data/doc/images/bullet_toggle_minus.png +0 -0
 - data/doc/images/bullet_toggle_plus.png +0 -0
 - data/doc/images/date.png +0 -0
 - data/doc/images/delete.png +0 -0
 - data/doc/images/find.png +0 -0
 - data/doc/images/loadingAnimation.gif +0 -0
 - data/doc/images/macFFBgHack.png +0 -0
 - data/doc/images/package.png +0 -0
 - data/doc/images/page_green.png +0 -0
 - data/doc/images/page_white_text.png +0 -0
 - data/doc/images/page_white_width.png +0 -0
 - data/doc/images/plugin.png +0 -0
 - data/doc/images/ruby.png +0 -0
 - data/doc/images/tag_blue.png +0 -0
 - data/doc/images/tag_green.png +0 -0
 - data/doc/images/transparent.png +0 -0
 - data/doc/images/wrench.png +0 -0
 - data/doc/images/wrench_orange.png +0 -0
 - data/doc/images/zoom.png +0 -0
 - data/doc/index.html +0 -666
 - data/doc/js/darkfish.js +0 -161
 - data/doc/js/jquery.js +0 -4
 - data/doc/js/navigation.js +0 -142
 - data/doc/js/navigation.js.gz +0 -0
 - data/doc/js/search.js +0 -109
 - data/doc/js/search_index.js +0 -1
 - data/doc/js/search_index.js.gz +0 -0
 - data/doc/js/searcher.js +0 -229
 - data/doc/js/searcher.js.gz +0 -0
 - data/doc/table_of_contents.html +0 -1052
 - data/examples/cachegrind.out.1 +0 -114
 - data/examples/cachegrind.out.1.32313213 +0 -114
 - data/ext/ruby_prof/vc/ruby_prof_18.vcxproj +0 -108
 - data/ext/ruby_prof/vc/ruby_prof_19.vcxproj +0 -110
 
| 
         @@ -1,140 +0,0 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            <!DOCTYPE html>
         
     | 
| 
       2 
     | 
    
         
            -
             
     | 
| 
       3 
     | 
    
         
            -
            <html>
         
     | 
| 
       4 
     | 
    
         
            -
            <head>
         
     | 
| 
       5 
     | 
    
         
            -
            <meta charset="UTF-8">
         
     | 
| 
       6 
     | 
    
         
            -
             
     | 
| 
       7 
     | 
    
         
            -
            <title>class RubyProf::GraphPrinter - ruby-prof</title>
         
     | 
| 
       8 
     | 
    
         
            -
             
     | 
| 
       9 
     | 
    
         
            -
            <script type="text/javascript">
         
     | 
| 
       10 
     | 
    
         
            -
              var rdoc_rel_prefix = "../";
         
     | 
| 
       11 
     | 
    
         
            -
              var index_rel_prefix = "../";
         
     | 
| 
       12 
     | 
    
         
            -
            </script>
         
     | 
| 
       13 
     | 
    
         
            -
             
     | 
| 
       14 
     | 
    
         
            -
            <script src="../js/jquery.js"></script>
         
     | 
| 
       15 
     | 
    
         
            -
            <script src="../js/darkfish.js"></script>
         
     | 
| 
       16 
     | 
    
         
            -
             
     | 
| 
       17 
     | 
    
         
            -
            <link href="../css/fonts.css" rel="stylesheet">
         
     | 
| 
       18 
     | 
    
         
            -
            <link href="../css/rdoc.css" rel="stylesheet">
         
     | 
| 
       19 
     | 
    
         
            -
             
     | 
| 
       20 
     | 
    
         
            -
             
     | 
| 
       21 
     | 
    
         
            -
             
     | 
| 
       22 
     | 
    
         
            -
            <body id="top" role="document" class="class">
         
     | 
| 
       23 
     | 
    
         
            -
            <nav role="navigation">
         
     | 
| 
       24 
     | 
    
         
            -
              <div id="project-navigation">
         
     | 
| 
       25 
     | 
    
         
            -
                <div id="home-section" role="region" title="Quick navigation" class="nav-section">
         
     | 
| 
       26 
     | 
    
         
            -
              <h2>
         
     | 
| 
       27 
     | 
    
         
            -
                <a href="../index.html" rel="home">Home</a>
         
     | 
| 
       28 
     | 
    
         
            -
              </h2>
         
     | 
| 
       29 
     | 
    
         
            -
             
     | 
| 
       30 
     | 
    
         
            -
              <div id="table-of-contents-navigation">
         
     | 
| 
       31 
     | 
    
         
            -
                <a href="../table_of_contents.html#pages">Pages</a>
         
     | 
| 
       32 
     | 
    
         
            -
                <a href="../table_of_contents.html#classes">Classes</a>
         
     | 
| 
       33 
     | 
    
         
            -
                <a href="../table_of_contents.html#methods">Methods</a>
         
     | 
| 
       34 
     | 
    
         
            -
              </div>
         
     | 
| 
       35 
     | 
    
         
            -
            </div>
         
     | 
| 
       36 
     | 
    
         
            -
             
     | 
| 
       37 
     | 
    
         
            -
                <div id="search-section" role="search" class="project-section initially-hidden">
         
     | 
| 
       38 
     | 
    
         
            -
              <form action="#" method="get" accept-charset="utf-8">
         
     | 
| 
       39 
     | 
    
         
            -
                <div id="search-field-wrapper">
         
     | 
| 
       40 
     | 
    
         
            -
                  <input id="search-field" role="combobox" aria-label="Search"
         
     | 
| 
       41 
     | 
    
         
            -
                         aria-autocomplete="list" aria-controls="search-results"
         
     | 
| 
       42 
     | 
    
         
            -
                         type="text" name="search" placeholder="Search" spellcheck="false"
         
     | 
| 
       43 
     | 
    
         
            -
                         title="Type to search, Up and Down to navigate, Enter to load">
         
     | 
| 
       44 
     | 
    
         
            -
                </div>
         
     | 
| 
       45 
     | 
    
         
            -
             
     | 
| 
       46 
     | 
    
         
            -
                <ul id="search-results" aria-label="Search Results"
         
     | 
| 
       47 
     | 
    
         
            -
                    aria-busy="false" aria-expanded="false"
         
     | 
| 
       48 
     | 
    
         
            -
                    aria-atomic="false" class="initially-hidden"></ul>
         
     | 
| 
       49 
     | 
    
         
            -
              </form>
         
     | 
| 
       50 
     | 
    
         
            -
            </div>
         
     | 
| 
       51 
     | 
    
         
            -
             
     | 
| 
       52 
     | 
    
         
            -
              </div>
         
     | 
| 
       53 
     | 
    
         
            -
             
     | 
| 
       54 
     | 
    
         
            -
              
         
     | 
| 
       55 
     | 
    
         
            -
             
     | 
| 
       56 
     | 
    
         
            -
              <div id="class-metadata">
         
     | 
| 
       57 
     | 
    
         
            -
                
         
     | 
| 
       58 
     | 
    
         
            -
                <div id="parent-class-section" class="nav-section">
         
     | 
| 
       59 
     | 
    
         
            -
              <h3>Parent</h3>
         
     | 
| 
       60 
     | 
    
         
            -
             
     | 
| 
       61 
     | 
    
         
            -
              
         
     | 
| 
       62 
     | 
    
         
            -
              <p class="link"><a href="AbstractPrinter.html">RubyProf::AbstractPrinter</a>
         
     | 
| 
       63 
     | 
    
         
            -
              
         
     | 
| 
       64 
     | 
    
         
            -
            </div>
         
     | 
| 
       65 
     | 
    
         
            -
             
     | 
| 
       66 
     | 
    
         
            -
                
         
     | 
| 
       67 
     | 
    
         
            -
                
         
     | 
| 
       68 
     | 
    
         
            -
                
         
     | 
| 
       69 
     | 
    
         
            -
              </div>
         
     | 
| 
       70 
     | 
    
         
            -
            </nav>
         
     | 
| 
       71 
     | 
    
         
            -
             
     | 
| 
       72 
     | 
    
         
            -
            <main role="main" aria-labelledby="class-RubyProf::GraphPrinter">
         
     | 
| 
       73 
     | 
    
         
            -
              <h1 id="class-RubyProf::GraphPrinter" class="class">
         
     | 
| 
       74 
     | 
    
         
            -
                class RubyProf::GraphPrinter
         
     | 
| 
       75 
     | 
    
         
            -
              </h1>
         
     | 
| 
       76 
     | 
    
         
            -
             
     | 
| 
       77 
     | 
    
         
            -
              <section class="description">
         
     | 
| 
       78 
     | 
    
         
            -
                
         
     | 
| 
       79 
     | 
    
         
            -
            <p>Generates <a href="../files/examples/graph_txt.html">graph</a> profile
         
     | 
| 
       80 
     | 
    
         
            -
            reports as text. To use the graph printer:</p>
         
     | 
| 
       81 
     | 
    
         
            -
             
     | 
| 
       82 
     | 
    
         
            -
            <pre>result = RubyProf.profile do
         
     | 
| 
       83 
     | 
    
         
            -
              [code to profile]
         
     | 
| 
       84 
     | 
    
         
            -
            end
         
     | 
| 
       85 
     | 
    
         
            -
             
     | 
| 
       86 
     | 
    
         
            -
            printer = RubyProf::GraphPrinter.new(result)
         
     | 
| 
       87 
     | 
    
         
            -
            printer.print(STDOUT, {})</pre>
         
     | 
| 
       88 
     | 
    
         
            -
             
     | 
| 
       89 
     | 
    
         
            -
            <p>The constructor takes two arguments. See the <a
         
     | 
| 
       90 
     | 
    
         
            -
            href="../README_rdoc.html">README</a></p>
         
     | 
| 
       91 
     | 
    
         
            -
             
     | 
| 
       92 
     | 
    
         
            -
              </section>
         
     | 
| 
       93 
     | 
    
         
            -
             
     | 
| 
       94 
     | 
    
         
            -
              
         
     | 
| 
       95 
     | 
    
         
            -
              
         
     | 
| 
       96 
     | 
    
         
            -
              
         
     | 
| 
       97 
     | 
    
         
            -
              <section id="5Buntitled-5D" class="documentation-section">
         
     | 
| 
       98 
     | 
    
         
            -
                
         
     | 
| 
       99 
     | 
    
         
            -
             
     | 
| 
       100 
     | 
    
         
            -
                
         
     | 
| 
       101 
     | 
    
         
            -
             
     | 
| 
       102 
     | 
    
         
            -
                
         
     | 
| 
       103 
     | 
    
         
            -
                <section class="constants-list">
         
     | 
| 
       104 
     | 
    
         
            -
                  <header>
         
     | 
| 
       105 
     | 
    
         
            -
                    <h3>Constants</h3>
         
     | 
| 
       106 
     | 
    
         
            -
                  </header>
         
     | 
| 
       107 
     | 
    
         
            -
                  <dl>
         
     | 
| 
       108 
     | 
    
         
            -
                  
         
     | 
| 
       109 
     | 
    
         
            -
                    <dt id="CALL_WIDTH">CALL_WIDTH
         
     | 
| 
       110 
     | 
    
         
            -
                    
         
     | 
| 
       111 
     | 
    
         
            -
                    <dd>
         
     | 
| 
       112 
     | 
    
         
            -
                    
         
     | 
| 
       113 
     | 
    
         
            -
                  
         
     | 
| 
       114 
     | 
    
         
            -
                    <dt id="PERCENTAGE_WIDTH">PERCENTAGE_WIDTH
         
     | 
| 
       115 
     | 
    
         
            -
                    
         
     | 
| 
       116 
     | 
    
         
            -
                    <dd>
         
     | 
| 
       117 
     | 
    
         
            -
                    
         
     | 
| 
       118 
     | 
    
         
            -
                  
         
     | 
| 
       119 
     | 
    
         
            -
                    <dt id="TIME_WIDTH">TIME_WIDTH
         
     | 
| 
       120 
     | 
    
         
            -
                    
         
     | 
| 
       121 
     | 
    
         
            -
                    <dd>
         
     | 
| 
       122 
     | 
    
         
            -
                    
         
     | 
| 
       123 
     | 
    
         
            -
                  
         
     | 
| 
       124 
     | 
    
         
            -
                  </dl>
         
     | 
| 
       125 
     | 
    
         
            -
                </section>
         
     | 
| 
       126 
     | 
    
         
            -
                
         
     | 
| 
       127 
     | 
    
         
            -
             
     | 
| 
       128 
     | 
    
         
            -
                
         
     | 
| 
       129 
     | 
    
         
            -
             
     | 
| 
       130 
     | 
    
         
            -
                
         
     | 
| 
       131 
     | 
    
         
            -
              </section>
         
     | 
| 
       132 
     | 
    
         
            -
            </main>
         
     | 
| 
       133 
     | 
    
         
            -
             
     | 
| 
       134 
     | 
    
         
            -
             
     | 
| 
       135 
     | 
    
         
            -
            <footer id="validator-badges" role="contentinfo">
         
     | 
| 
       136 
     | 
    
         
            -
              <p><a href="http://validator.w3.org/check/referer">Validate</a>
         
     | 
| 
       137 
     | 
    
         
            -
              <p>Generated by <a href="https://rdoc.github.io/rdoc">RDoc</a> 5.1.0.
         
     | 
| 
       138 
     | 
    
         
            -
              <p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
         
     | 
| 
       139 
     | 
    
         
            -
            </footer>
         
     | 
| 
       140 
     | 
    
         
            -
             
     | 
| 
         @@ -1,676 +0,0 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            <!DOCTYPE html>
         
     | 
| 
       2 
     | 
    
         
            -
             
     | 
| 
       3 
     | 
    
         
            -
            <html>
         
     | 
| 
       4 
     | 
    
         
            -
            <head>
         
     | 
| 
       5 
     | 
    
         
            -
            <meta charset="UTF-8">
         
     | 
| 
       6 
     | 
    
         
            -
             
     | 
| 
       7 
     | 
    
         
            -
            <title>class RubyProf::MethodInfo - ruby-prof</title>
         
     | 
| 
       8 
     | 
    
         
            -
             
     | 
| 
       9 
     | 
    
         
            -
            <script type="text/javascript">
         
     | 
| 
       10 
     | 
    
         
            -
              var rdoc_rel_prefix = "../";
         
     | 
| 
       11 
     | 
    
         
            -
              var index_rel_prefix = "../";
         
     | 
| 
       12 
     | 
    
         
            -
            </script>
         
     | 
| 
       13 
     | 
    
         
            -
             
     | 
| 
       14 
     | 
    
         
            -
            <script src="../js/jquery.js"></script>
         
     | 
| 
       15 
     | 
    
         
            -
            <script src="../js/darkfish.js"></script>
         
     | 
| 
       16 
     | 
    
         
            -
             
     | 
| 
       17 
     | 
    
         
            -
            <link href="../css/fonts.css" rel="stylesheet">
         
     | 
| 
       18 
     | 
    
         
            -
            <link href="../css/rdoc.css" rel="stylesheet">
         
     | 
| 
       19 
     | 
    
         
            -
             
     | 
| 
       20 
     | 
    
         
            -
             
     | 
| 
       21 
     | 
    
         
            -
             
     | 
| 
       22 
     | 
    
         
            -
            <body id="top" role="document" class="class">
         
     | 
| 
       23 
     | 
    
         
            -
            <nav role="navigation">
         
     | 
| 
       24 
     | 
    
         
            -
              <div id="project-navigation">
         
     | 
| 
       25 
     | 
    
         
            -
                <div id="home-section" role="region" title="Quick navigation" class="nav-section">
         
     | 
| 
       26 
     | 
    
         
            -
              <h2>
         
     | 
| 
       27 
     | 
    
         
            -
                <a href="../index.html" rel="home">Home</a>
         
     | 
| 
       28 
     | 
    
         
            -
              </h2>
         
     | 
| 
       29 
     | 
    
         
            -
             
     | 
| 
       30 
     | 
    
         
            -
              <div id="table-of-contents-navigation">
         
     | 
| 
       31 
     | 
    
         
            -
                <a href="../table_of_contents.html#pages">Pages</a>
         
     | 
| 
       32 
     | 
    
         
            -
                <a href="../table_of_contents.html#classes">Classes</a>
         
     | 
| 
       33 
     | 
    
         
            -
                <a href="../table_of_contents.html#methods">Methods</a>
         
     | 
| 
       34 
     | 
    
         
            -
              </div>
         
     | 
| 
       35 
     | 
    
         
            -
            </div>
         
     | 
| 
       36 
     | 
    
         
            -
             
     | 
| 
       37 
     | 
    
         
            -
                <div id="search-section" role="search" class="project-section initially-hidden">
         
     | 
| 
       38 
     | 
    
         
            -
              <form action="#" method="get" accept-charset="utf-8">
         
     | 
| 
       39 
     | 
    
         
            -
                <div id="search-field-wrapper">
         
     | 
| 
       40 
     | 
    
         
            -
                  <input id="search-field" role="combobox" aria-label="Search"
         
     | 
| 
       41 
     | 
    
         
            -
                         aria-autocomplete="list" aria-controls="search-results"
         
     | 
| 
       42 
     | 
    
         
            -
                         type="text" name="search" placeholder="Search" spellcheck="false"
         
     | 
| 
       43 
     | 
    
         
            -
                         title="Type to search, Up and Down to navigate, Enter to load">
         
     | 
| 
       44 
     | 
    
         
            -
                </div>
         
     | 
| 
       45 
     | 
    
         
            -
             
     | 
| 
       46 
     | 
    
         
            -
                <ul id="search-results" aria-label="Search Results"
         
     | 
| 
       47 
     | 
    
         
            -
                    aria-busy="false" aria-expanded="false"
         
     | 
| 
       48 
     | 
    
         
            -
                    aria-atomic="false" class="initially-hidden"></ul>
         
     | 
| 
       49 
     | 
    
         
            -
              </form>
         
     | 
| 
       50 
     | 
    
         
            -
            </div>
         
     | 
| 
       51 
     | 
    
         
            -
             
     | 
| 
       52 
     | 
    
         
            -
              </div>
         
     | 
| 
       53 
     | 
    
         
            -
             
     | 
| 
       54 
     | 
    
         
            -
              
         
     | 
| 
       55 
     | 
    
         
            -
             
     | 
| 
       56 
     | 
    
         
            -
              <div id="class-metadata">
         
     | 
| 
       57 
     | 
    
         
            -
                
         
     | 
| 
       58 
     | 
    
         
            -
                <div id="parent-class-section" class="nav-section">
         
     | 
| 
       59 
     | 
    
         
            -
              <h3>Parent</h3>
         
     | 
| 
       60 
     | 
    
         
            -
             
     | 
| 
       61 
     | 
    
         
            -
              
         
     | 
| 
       62 
     | 
    
         
            -
              <p class="link">Object
         
     | 
| 
       63 
     | 
    
         
            -
              
         
     | 
| 
       64 
     | 
    
         
            -
            </div>
         
     | 
| 
       65 
     | 
    
         
            -
             
     | 
| 
       66 
     | 
    
         
            -
                <div id="includes-section" class="nav-section">
         
     | 
| 
       67 
     | 
    
         
            -
              <h3>Included Modules</h3>
         
     | 
| 
       68 
     | 
    
         
            -
             
     | 
| 
       69 
     | 
    
         
            -
              <ul class="link-list">
         
     | 
| 
       70 
     | 
    
         
            -
              
         
     | 
| 
       71 
     | 
    
         
            -
              
         
     | 
| 
       72 
     | 
    
         
            -
                <li><span class="include">Comparable</span>
         
     | 
| 
       73 
     | 
    
         
            -
              
         
     | 
| 
       74 
     | 
    
         
            -
              
         
     | 
| 
       75 
     | 
    
         
            -
              </ul>
         
     | 
| 
       76 
     | 
    
         
            -
            </div>
         
     | 
| 
       77 
     | 
    
         
            -
             
     | 
| 
       78 
     | 
    
         
            -
                
         
     | 
| 
       79 
     | 
    
         
            -
                <!-- Method Quickref -->
         
     | 
| 
       80 
     | 
    
         
            -
            <div id="method-list-section" class="nav-section">
         
     | 
| 
       81 
     | 
    
         
            -
              <h3>Methods</h3>
         
     | 
| 
       82 
     | 
    
         
            -
             
     | 
| 
       83 
     | 
    
         
            -
              <ul class="link-list" role="directory">
         
     | 
| 
       84 
     | 
    
         
            -
                
         
     | 
| 
       85 
     | 
    
         
            -
                <li ><a href="#method-i-3C-3D-3E">#<=></a>
         
     | 
| 
       86 
     | 
    
         
            -
                
         
     | 
| 
       87 
     | 
    
         
            -
                <li ><a href="#method-i-aggregate_children">#aggregate_children</a>
         
     | 
| 
       88 
     | 
    
         
            -
                
         
     | 
| 
       89 
     | 
    
         
            -
                <li ><a href="#method-i-aggregate_parents">#aggregate_parents</a>
         
     | 
| 
       90 
     | 
    
         
            -
                
         
     | 
| 
       91 
     | 
    
         
            -
                <li ><a href="#method-i-called">#called</a>
         
     | 
| 
       92 
     | 
    
         
            -
                
         
     | 
| 
       93 
     | 
    
         
            -
                <li ><a href="#method-i-children">#children</a>
         
     | 
| 
       94 
     | 
    
         
            -
                
         
     | 
| 
       95 
     | 
    
         
            -
                <li ><a href="#method-i-children_time">#children_time</a>
         
     | 
| 
       96 
     | 
    
         
            -
                
         
     | 
| 
       97 
     | 
    
         
            -
                <li ><a href="#method-i-eliminate-21">#eliminate!</a>
         
     | 
| 
       98 
     | 
    
         
            -
                
         
     | 
| 
       99 
     | 
    
         
            -
                <li ><a href="#method-i-min_depth">#min_depth</a>
         
     | 
| 
       100 
     | 
    
         
            -
                
         
     | 
| 
       101 
     | 
    
         
            -
                <li ><a href="#method-i-parents">#parents</a>
         
     | 
| 
       102 
     | 
    
         
            -
                
         
     | 
| 
       103 
     | 
    
         
            -
                <li ><a href="#method-i-root-3F">#root?</a>
         
     | 
| 
       104 
     | 
    
         
            -
                
         
     | 
| 
       105 
     | 
    
         
            -
                <li ><a href="#method-i-self_time">#self_time</a>
         
     | 
| 
       106 
     | 
    
         
            -
                
         
     | 
| 
       107 
     | 
    
         
            -
                <li ><a href="#method-i-to_s">#to_s</a>
         
     | 
| 
       108 
     | 
    
         
            -
                
         
     | 
| 
       109 
     | 
    
         
            -
                <li ><a href="#method-i-total_time">#total_time</a>
         
     | 
| 
       110 
     | 
    
         
            -
                
         
     | 
| 
       111 
     | 
    
         
            -
                <li ><a href="#method-i-wait_time">#wait_time</a>
         
     | 
| 
       112 
     | 
    
         
            -
                
         
     | 
| 
       113 
     | 
    
         
            -
              </ul>
         
     | 
| 
       114 
     | 
    
         
            -
            </div>
         
     | 
| 
       115 
     | 
    
         
            -
             
     | 
| 
       116 
     | 
    
         
            -
              </div>
         
     | 
| 
       117 
     | 
    
         
            -
            </nav>
         
     | 
| 
       118 
     | 
    
         
            -
             
     | 
| 
       119 
     | 
    
         
            -
            <main role="main" aria-labelledby="class-RubyProf::MethodInfo">
         
     | 
| 
       120 
     | 
    
         
            -
              <h1 id="class-RubyProf::MethodInfo" class="class">
         
     | 
| 
       121 
     | 
    
         
            -
                class RubyProf::MethodInfo
         
     | 
| 
       122 
     | 
    
         
            -
              </h1>
         
     | 
| 
       123 
     | 
    
         
            -
             
     | 
| 
       124 
     | 
    
         
            -
              <section class="description">
         
     | 
| 
       125 
     | 
    
         
            -
                
         
     | 
| 
       126 
     | 
    
         
            -
              </section>
         
     | 
| 
       127 
     | 
    
         
            -
             
     | 
| 
       128 
     | 
    
         
            -
              
         
     | 
| 
       129 
     | 
    
         
            -
              
         
     | 
| 
       130 
     | 
    
         
            -
              
         
     | 
| 
       131 
     | 
    
         
            -
              <section id="5Buntitled-5D" class="documentation-section">
         
     | 
| 
       132 
     | 
    
         
            -
                
         
     | 
| 
       133 
     | 
    
         
            -
             
     | 
| 
       134 
     | 
    
         
            -
                
         
     | 
| 
       135 
     | 
    
         
            -
             
     | 
| 
       136 
     | 
    
         
            -
                
         
     | 
| 
       137 
     | 
    
         
            -
             
     | 
| 
       138 
     | 
    
         
            -
                
         
     | 
| 
       139 
     | 
    
         
            -
             
     | 
| 
       140 
     | 
    
         
            -
                
         
     | 
| 
       141 
     | 
    
         
            -
                 <section id="public-instance-5Buntitled-5D-method-details" class="method-section">
         
     | 
| 
       142 
     | 
    
         
            -
                   <header>
         
     | 
| 
       143 
     | 
    
         
            -
                     <h3>Public Instance Methods</h3>
         
     | 
| 
       144 
     | 
    
         
            -
                   </header>
         
     | 
| 
       145 
     | 
    
         
            -
             
     | 
| 
       146 
     | 
    
         
            -
                
         
     | 
| 
       147 
     | 
    
         
            -
                  <div id="method-i-3C-3D-3E" class="method-detail ">
         
     | 
| 
       148 
     | 
    
         
            -
                    
         
     | 
| 
       149 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       150 
     | 
    
         
            -
                      <span class="method-name"><=></span><span
         
     | 
| 
       151 
     | 
    
         
            -
                        class="method-args">(other)</span>
         
     | 
| 
       152 
     | 
    
         
            -
                      
         
     | 
| 
       153 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       154 
     | 
    
         
            -
                      
         
     | 
| 
       155 
     | 
    
         
            -
                    </div>
         
     | 
| 
       156 
     | 
    
         
            -
                    
         
     | 
| 
       157 
     | 
    
         
            -
             
     | 
| 
       158 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       159 
     | 
    
         
            -
                      
         
     | 
| 
       160 
     | 
    
         
            -
                      
         
     | 
| 
       161 
     | 
    
         
            -
                      
         
     | 
| 
       162 
     | 
    
         
            -
                      
         
     | 
| 
       163 
     | 
    
         
            -
             
     | 
| 
       164 
     | 
    
         
            -
                      
         
     | 
| 
       165 
     | 
    
         
            -
                      <div class="method-source-code" id="3C-3D-3E-source">
         
     | 
| 
       166 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 6</span>
         
     | 
| 
       167 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-operator"><=></span>(<span class="ruby-identifier">other</span>)
         
     | 
| 
       168 
     | 
    
         
            -
              <span class="ruby-keyword">if</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">total_time</span> <span class="ruby-operator"><</span> <span class="ruby-identifier">other</span>.<span class="ruby-identifier">total_time</span>
         
     | 
| 
       169 
     | 
    
         
            -
                <span class="ruby-value">-1</span>
         
     | 
| 
       170 
     | 
    
         
            -
              <span class="ruby-keyword">elsif</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">total_time</span> <span class="ruby-operator">></span> <span class="ruby-identifier">other</span>.<span class="ruby-identifier">total_time</span>
         
     | 
| 
       171 
     | 
    
         
            -
                <span class="ruby-value">1</span>
         
     | 
| 
       172 
     | 
    
         
            -
              <span class="ruby-keyword">elsif</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">min_depth</span> <span class="ruby-operator"><</span> <span class="ruby-identifier">other</span>.<span class="ruby-identifier">min_depth</span>
         
     | 
| 
       173 
     | 
    
         
            -
                <span class="ruby-value">1</span>
         
     | 
| 
       174 
     | 
    
         
            -
              <span class="ruby-keyword">elsif</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">min_depth</span> <span class="ruby-operator">></span> <span class="ruby-identifier">other</span>.<span class="ruby-identifier">min_depth</span>
         
     | 
| 
       175 
     | 
    
         
            -
                <span class="ruby-value">-1</span>
         
     | 
| 
       176 
     | 
    
         
            -
              <span class="ruby-keyword">else</span>
         
     | 
| 
       177 
     | 
    
         
            -
                <span class="ruby-keyword">self</span>.<span class="ruby-identifier">full_name</span> <span class="ruby-operator"><=></span> <span class="ruby-identifier">other</span>.<span class="ruby-identifier">full_name</span>
         
     | 
| 
       178 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       179 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       180 
     | 
    
         
            -
                      </div>
         
     | 
| 
       181 
     | 
    
         
            -
                      
         
     | 
| 
       182 
     | 
    
         
            -
                    </div>
         
     | 
| 
       183 
     | 
    
         
            -
             
     | 
| 
       184 
     | 
    
         
            -
                    
         
     | 
| 
       185 
     | 
    
         
            -
             
     | 
| 
       186 
     | 
    
         
            -
                    
         
     | 
| 
       187 
     | 
    
         
            -
                  </div>
         
     | 
| 
       188 
     | 
    
         
            -
             
     | 
| 
       189 
     | 
    
         
            -
                
         
     | 
| 
       190 
     | 
    
         
            -
                  <div id="method-i-aggregate_children" class="method-detail ">
         
     | 
| 
       191 
     | 
    
         
            -
                    
         
     | 
| 
       192 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       193 
     | 
    
         
            -
                      <span class="method-name">aggregate_children</span><span
         
     | 
| 
       194 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       195 
     | 
    
         
            -
                      
         
     | 
| 
       196 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       197 
     | 
    
         
            -
                      
         
     | 
| 
       198 
     | 
    
         
            -
                    </div>
         
     | 
| 
       199 
     | 
    
         
            -
                    
         
     | 
| 
       200 
     | 
    
         
            -
             
     | 
| 
       201 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       202 
     | 
    
         
            -
                      
         
     | 
| 
       203 
     | 
    
         
            -
                      
         
     | 
| 
       204 
     | 
    
         
            -
                      
         
     | 
| 
       205 
     | 
    
         
            -
                      
         
     | 
| 
       206 
     | 
    
         
            -
             
     | 
| 
       207 
     | 
    
         
            -
                      
         
     | 
| 
       208 
     | 
    
         
            -
                      <div class="method-source-code" id="aggregate_children-source">
         
     | 
| 
       209 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 96</span>
         
     | 
| 
       210 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">aggregate_children</span>
         
     | 
| 
       211 
     | 
    
         
            -
              <span class="ruby-comment"># group call infos based on their targets</span>
         
     | 
| 
       212 
     | 
    
         
            -
              <span class="ruby-identifier">groups</span> = <span class="ruby-keyword">self</span>.<span class="ruby-identifier">children</span>.<span class="ruby-identifier">each_with_object</span>({}) <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">call_info</span>, <span class="ruby-identifier">hash</span><span class="ruby-operator">|</span>
         
     | 
| 
       213 
     | 
    
         
            -
                <span class="ruby-identifier">key</span> = <span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">target</span>
         
     | 
| 
       214 
     | 
    
         
            -
                (<span class="ruby-identifier">hash</span>[<span class="ruby-identifier">key</span>] <span class="ruby-operator">||=</span> []) <span class="ruby-operator"><<</span> <span class="ruby-identifier">call_info</span>
         
     | 
| 
       215 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       216 
     | 
    
         
            -
             
     | 
| 
       217 
     | 
    
         
            -
              <span class="ruby-identifier">groups</span>.<span class="ruby-identifier">map</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">key</span>, <span class="ruby-identifier">value</span><span class="ruby-operator">|</span>
         
     | 
| 
       218 
     | 
    
         
            -
                <span class="ruby-constant">AggregateCallInfo</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">value</span>, <span class="ruby-keyword">self</span>)
         
     | 
| 
       219 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       220 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       221 
     | 
    
         
            -
                      </div>
         
     | 
| 
       222 
     | 
    
         
            -
                      
         
     | 
| 
       223 
     | 
    
         
            -
                    </div>
         
     | 
| 
       224 
     | 
    
         
            -
             
     | 
| 
       225 
     | 
    
         
            -
                    
         
     | 
| 
       226 
     | 
    
         
            -
             
     | 
| 
       227 
     | 
    
         
            -
                    
         
     | 
| 
       228 
     | 
    
         
            -
                  </div>
         
     | 
| 
       229 
     | 
    
         
            -
             
     | 
| 
       230 
     | 
    
         
            -
                
         
     | 
| 
       231 
     | 
    
         
            -
                  <div id="method-i-aggregate_parents" class="method-detail ">
         
     | 
| 
       232 
     | 
    
         
            -
                    
         
     | 
| 
       233 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       234 
     | 
    
         
            -
                      <span class="method-name">aggregate_parents</span><span
         
     | 
| 
       235 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       236 
     | 
    
         
            -
                      
         
     | 
| 
       237 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       238 
     | 
    
         
            -
                      
         
     | 
| 
       239 
     | 
    
         
            -
                    </div>
         
     | 
| 
       240 
     | 
    
         
            -
                    
         
     | 
| 
       241 
     | 
    
         
            -
             
     | 
| 
       242 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       243 
     | 
    
         
            -
                      
         
     | 
| 
       244 
     | 
    
         
            -
                      
         
     | 
| 
       245 
     | 
    
         
            -
                      
         
     | 
| 
       246 
     | 
    
         
            -
                      
         
     | 
| 
       247 
     | 
    
         
            -
             
     | 
| 
       248 
     | 
    
         
            -
                      
         
     | 
| 
       249 
     | 
    
         
            -
                      <div class="method-source-code" id="aggregate_parents-source">
         
     | 
| 
       250 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 84</span>
         
     | 
| 
       251 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">aggregate_parents</span>
         
     | 
| 
       252 
     | 
    
         
            -
              <span class="ruby-comment"># group call infos based on their parents</span>
         
     | 
| 
       253 
     | 
    
         
            -
              <span class="ruby-identifier">groups</span> = <span class="ruby-keyword">self</span>.<span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">each_with_object</span>({}) <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">call_info</span>, <span class="ruby-identifier">hash</span><span class="ruby-operator">|</span>
         
     | 
| 
       254 
     | 
    
         
            -
                <span class="ruby-identifier">key</span> = <span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">parent</span> <span class="ruby-operator">?</span> <span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">parent</span>.<span class="ruby-identifier">target</span> <span class="ruby-operator">:</span> <span class="ruby-keyword">self</span>
         
     | 
| 
       255 
     | 
    
         
            -
                (<span class="ruby-identifier">hash</span>[<span class="ruby-identifier">key</span>] <span class="ruby-operator">||=</span> []) <span class="ruby-operator"><<</span> <span class="ruby-identifier">call_info</span>
         
     | 
| 
       256 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       257 
     | 
    
         
            -
             
     | 
| 
       258 
     | 
    
         
            -
              <span class="ruby-identifier">groups</span>.<span class="ruby-identifier">map</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">key</span>, <span class="ruby-identifier">value</span><span class="ruby-operator">|</span>
         
     | 
| 
       259 
     | 
    
         
            -
                <span class="ruby-constant">AggregateCallInfo</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">value</span>, <span class="ruby-keyword">self</span>)
         
     | 
| 
       260 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       261 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       262 
     | 
    
         
            -
                      </div>
         
     | 
| 
       263 
     | 
    
         
            -
                      
         
     | 
| 
       264 
     | 
    
         
            -
                    </div>
         
     | 
| 
       265 
     | 
    
         
            -
             
     | 
| 
       266 
     | 
    
         
            -
                    
         
     | 
| 
       267 
     | 
    
         
            -
             
     | 
| 
       268 
     | 
    
         
            -
                    
         
     | 
| 
       269 
     | 
    
         
            -
                  </div>
         
     | 
| 
       270 
     | 
    
         
            -
             
     | 
| 
       271 
     | 
    
         
            -
                
         
     | 
| 
       272 
     | 
    
         
            -
                  <div id="method-i-called" class="method-detail ">
         
     | 
| 
       273 
     | 
    
         
            -
                    
         
     | 
| 
       274 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       275 
     | 
    
         
            -
                      <span class="method-name">called</span><span
         
     | 
| 
       276 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       277 
     | 
    
         
            -
                      
         
     | 
| 
       278 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       279 
     | 
    
         
            -
                      
         
     | 
| 
       280 
     | 
    
         
            -
                    </div>
         
     | 
| 
       281 
     | 
    
         
            -
                    
         
     | 
| 
       282 
     | 
    
         
            -
             
     | 
| 
       283 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       284 
     | 
    
         
            -
                      
         
     | 
| 
       285 
     | 
    
         
            -
                      
         
     | 
| 
       286 
     | 
    
         
            -
                      
         
     | 
| 
       287 
     | 
    
         
            -
                      
         
     | 
| 
       288 
     | 
    
         
            -
             
     | 
| 
       289 
     | 
    
         
            -
                      
         
     | 
| 
       290 
     | 
    
         
            -
                      <div class="method-source-code" id="called-source">
         
     | 
| 
       291 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 20</span>
         
     | 
| 
       292 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">called</span>
         
     | 
| 
       293 
     | 
    
         
            -
              <span class="ruby-ivar">@called</span> <span class="ruby-operator">||=</span> <span class="ruby-keyword">begin</span>
         
     | 
| 
       294 
     | 
    
         
            -
                <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">inject</span>(<span class="ruby-value">0</span>) <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">sum</span>, <span class="ruby-identifier">call_info</span><span class="ruby-operator">|</span>
         
     | 
| 
       295 
     | 
    
         
            -
                  <span class="ruby-identifier">sum</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">called</span>
         
     | 
| 
       296 
     | 
    
         
            -
                <span class="ruby-keyword">end</span>
         
     | 
| 
       297 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       298 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       299 
     | 
    
         
            -
                      </div>
         
     | 
| 
       300 
     | 
    
         
            -
                      
         
     | 
| 
       301 
     | 
    
         
            -
                    </div>
         
     | 
| 
       302 
     | 
    
         
            -
             
     | 
| 
       303 
     | 
    
         
            -
                    
         
     | 
| 
       304 
     | 
    
         
            -
             
     | 
| 
       305 
     | 
    
         
            -
                    
         
     | 
| 
       306 
     | 
    
         
            -
                  </div>
         
     | 
| 
       307 
     | 
    
         
            -
             
     | 
| 
       308 
     | 
    
         
            -
                
         
     | 
| 
       309 
     | 
    
         
            -
                  <div id="method-i-children" class="method-detail ">
         
     | 
| 
       310 
     | 
    
         
            -
                    
         
     | 
| 
       311 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       312 
     | 
    
         
            -
                      <span class="method-name">children</span><span
         
     | 
| 
       313 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       314 
     | 
    
         
            -
                      
         
     | 
| 
       315 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       316 
     | 
    
         
            -
                      
         
     | 
| 
       317 
     | 
    
         
            -
                    </div>
         
     | 
| 
       318 
     | 
    
         
            -
                    
         
     | 
| 
       319 
     | 
    
         
            -
             
     | 
| 
       320 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       321 
     | 
    
         
            -
                      
         
     | 
| 
       322 
     | 
    
         
            -
                      
         
     | 
| 
       323 
     | 
    
         
            -
                      
         
     | 
| 
       324 
     | 
    
         
            -
                      
         
     | 
| 
       325 
     | 
    
         
            -
             
     | 
| 
       326 
     | 
    
         
            -
                      
         
     | 
| 
       327 
     | 
    
         
            -
                      <div class="method-source-code" id="children-source">
         
     | 
| 
       328 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 76</span>
         
     | 
| 
       329 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">children</span>
         
     | 
| 
       330 
     | 
    
         
            -
              <span class="ruby-ivar">@children</span> <span class="ruby-operator">||=</span> <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">map</span>(<span class="ruby-operator">&</span><span class="ruby-value">:children</span>).<span class="ruby-identifier">flatten</span>
         
     | 
| 
       331 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       332 
     | 
    
         
            -
                      </div>
         
     | 
| 
       333 
     | 
    
         
            -
                      
         
     | 
| 
       334 
     | 
    
         
            -
                    </div>
         
     | 
| 
       335 
     | 
    
         
            -
             
     | 
| 
       336 
     | 
    
         
            -
                    
         
     | 
| 
       337 
     | 
    
         
            -
             
     | 
| 
       338 
     | 
    
         
            -
                    
         
     | 
| 
       339 
     | 
    
         
            -
                  </div>
         
     | 
| 
       340 
     | 
    
         
            -
             
     | 
| 
       341 
     | 
    
         
            -
                
         
     | 
| 
       342 
     | 
    
         
            -
                  <div id="method-i-children_time" class="method-detail ">
         
     | 
| 
       343 
     | 
    
         
            -
                    
         
     | 
| 
       344 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       345 
     | 
    
         
            -
                      <span class="method-name">children_time</span><span
         
     | 
| 
       346 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       347 
     | 
    
         
            -
                      
         
     | 
| 
       348 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       349 
     | 
    
         
            -
                      
         
     | 
| 
       350 
     | 
    
         
            -
                    </div>
         
     | 
| 
       351 
     | 
    
         
            -
                    
         
     | 
| 
       352 
     | 
    
         
            -
             
     | 
| 
       353 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       354 
     | 
    
         
            -
                      
         
     | 
| 
       355 
     | 
    
         
            -
                      
         
     | 
| 
       356 
     | 
    
         
            -
                      
         
     | 
| 
       357 
     | 
    
         
            -
                      
         
     | 
| 
       358 
     | 
    
         
            -
             
     | 
| 
       359 
     | 
    
         
            -
                      
         
     | 
| 
       360 
     | 
    
         
            -
                      <div class="method-source-code" id="children_time-source">
         
     | 
| 
       361 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 55</span>
         
     | 
| 
       362 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">children_time</span>
         
     | 
| 
       363 
     | 
    
         
            -
              <span class="ruby-ivar">@children_time</span> <span class="ruby-operator">||=</span> <span class="ruby-keyword">begin</span>
         
     | 
| 
       364 
     | 
    
         
            -
                <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">inject</span>(<span class="ruby-value">0</span>) <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">sum</span>, <span class="ruby-identifier">call_info</span><span class="ruby-operator">|</span>
         
     | 
| 
       365 
     | 
    
         
            -
                  <span class="ruby-identifier">sum</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">children_time</span> <span class="ruby-keyword">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">recursive?</span>
         
     | 
| 
       366 
     | 
    
         
            -
                  <span class="ruby-identifier">sum</span>
         
     | 
| 
       367 
     | 
    
         
            -
                <span class="ruby-keyword">end</span>
         
     | 
| 
       368 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       369 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       370 
     | 
    
         
            -
                      </div>
         
     | 
| 
       371 
     | 
    
         
            -
                      
         
     | 
| 
       372 
     | 
    
         
            -
                    </div>
         
     | 
| 
       373 
     | 
    
         
            -
             
     | 
| 
       374 
     | 
    
         
            -
                    
         
     | 
| 
       375 
     | 
    
         
            -
             
     | 
| 
       376 
     | 
    
         
            -
                    
         
     | 
| 
       377 
     | 
    
         
            -
                  </div>
         
     | 
| 
       378 
     | 
    
         
            -
             
     | 
| 
       379 
     | 
    
         
            -
                
         
     | 
| 
       380 
     | 
    
         
            -
                  <div id="method-i-eliminate-21" class="method-detail ">
         
     | 
| 
       381 
     | 
    
         
            -
                    
         
     | 
| 
       382 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       383 
     | 
    
         
            -
                      <span class="method-name">eliminate!</span><span
         
     | 
| 
       384 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       385 
     | 
    
         
            -
                      
         
     | 
| 
       386 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       387 
     | 
    
         
            -
                      
         
     | 
| 
       388 
     | 
    
         
            -
                    </div>
         
     | 
| 
       389 
     | 
    
         
            -
                    
         
     | 
| 
       390 
     | 
    
         
            -
             
     | 
| 
       391 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       392 
     | 
    
         
            -
                      
         
     | 
| 
       393 
     | 
    
         
            -
                      <p>remove method from the call graph. should not be called directly.</p>
         
     | 
| 
       394 
     | 
    
         
            -
                      
         
     | 
| 
       395 
     | 
    
         
            -
                      
         
     | 
| 
       396 
     | 
    
         
            -
             
     | 
| 
       397 
     | 
    
         
            -
                      
         
     | 
| 
       398 
     | 
    
         
            -
                      <div class="method-source-code" id="eliminate-21-source">
         
     | 
| 
       399 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 113</span>
         
     | 
| 
       400 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">eliminate!</span>
         
     | 
| 
       401 
     | 
    
         
            -
              <span class="ruby-comment"># $stderr.puts "eliminating #{self}"</span>
         
     | 
| 
       402 
     | 
    
         
            -
              <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">each</span>{ <span class="ruby-operator">|</span><span class="ruby-identifier">call_info</span><span class="ruby-operator">|</span> <span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">eliminate!</span> }
         
     | 
| 
       403 
     | 
    
         
            -
              <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">clear</span>
         
     | 
| 
       404 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       405 
     | 
    
         
            -
                      </div>
         
     | 
| 
       406 
     | 
    
         
            -
                      
         
     | 
| 
       407 
     | 
    
         
            -
                    </div>
         
     | 
| 
       408 
     | 
    
         
            -
             
     | 
| 
       409 
     | 
    
         
            -
                    
         
     | 
| 
       410 
     | 
    
         
            -
             
     | 
| 
       411 
     | 
    
         
            -
                    
         
     | 
| 
       412 
     | 
    
         
            -
                  </div>
         
     | 
| 
       413 
     | 
    
         
            -
             
     | 
| 
       414 
     | 
    
         
            -
                
         
     | 
| 
       415 
     | 
    
         
            -
                  <div id="method-i-min_depth" class="method-detail ">
         
     | 
| 
       416 
     | 
    
         
            -
                    
         
     | 
| 
       417 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       418 
     | 
    
         
            -
                      <span class="method-name">min_depth</span><span
         
     | 
| 
       419 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       420 
     | 
    
         
            -
                      
         
     | 
| 
       421 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       422 
     | 
    
         
            -
                      
         
     | 
| 
       423 
     | 
    
         
            -
                    </div>
         
     | 
| 
       424 
     | 
    
         
            -
                    
         
     | 
| 
       425 
     | 
    
         
            -
             
     | 
| 
       426 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       427 
     | 
    
         
            -
                      
         
     | 
| 
       428 
     | 
    
         
            -
                      
         
     | 
| 
       429 
     | 
    
         
            -
                      
         
     | 
| 
       430 
     | 
    
         
            -
                      
         
     | 
| 
       431 
     | 
    
         
            -
             
     | 
| 
       432 
     | 
    
         
            -
                      
         
     | 
| 
       433 
     | 
    
         
            -
                      <div class="method-source-code" id="min_depth-source">
         
     | 
| 
       434 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 64</span>
         
     | 
| 
       435 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">min_depth</span>
         
     | 
| 
       436 
     | 
    
         
            -
              <span class="ruby-ivar">@min_depth</span> <span class="ruby-operator">||=</span> <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">map</span>(<span class="ruby-operator">&</span><span class="ruby-value">:depth</span>).<span class="ruby-identifier">min</span>
         
     | 
| 
       437 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       438 
     | 
    
         
            -
                      </div>
         
     | 
| 
       439 
     | 
    
         
            -
                      
         
     | 
| 
       440 
     | 
    
         
            -
                    </div>
         
     | 
| 
       441 
     | 
    
         
            -
             
     | 
| 
       442 
     | 
    
         
            -
                    
         
     | 
| 
       443 
     | 
    
         
            -
             
     | 
| 
       444 
     | 
    
         
            -
                    
         
     | 
| 
       445 
     | 
    
         
            -
                  </div>
         
     | 
| 
       446 
     | 
    
         
            -
             
     | 
| 
       447 
     | 
    
         
            -
                
         
     | 
| 
       448 
     | 
    
         
            -
                  <div id="method-i-parents" class="method-detail ">
         
     | 
| 
       449 
     | 
    
         
            -
                    
         
     | 
| 
       450 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       451 
     | 
    
         
            -
                      <span class="method-name">parents</span><span
         
     | 
| 
       452 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       453 
     | 
    
         
            -
                      
         
     | 
| 
       454 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       455 
     | 
    
         
            -
                      
         
     | 
| 
       456 
     | 
    
         
            -
                    </div>
         
     | 
| 
       457 
     | 
    
         
            -
                    
         
     | 
| 
       458 
     | 
    
         
            -
             
     | 
| 
       459 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       460 
     | 
    
         
            -
                      
         
     | 
| 
       461 
     | 
    
         
            -
                      
         
     | 
| 
       462 
     | 
    
         
            -
                      
         
     | 
| 
       463 
     | 
    
         
            -
                      
         
     | 
| 
       464 
     | 
    
         
            -
             
     | 
| 
       465 
     | 
    
         
            -
                      
         
     | 
| 
       466 
     | 
    
         
            -
                      <div class="method-source-code" id="parents-source">
         
     | 
| 
       467 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 80</span>
         
     | 
| 
       468 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">parents</span>
         
     | 
| 
       469 
     | 
    
         
            -
              <span class="ruby-ivar">@parents</span> <span class="ruby-operator">||=</span> <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">map</span>(<span class="ruby-operator">&</span><span class="ruby-value">:parent</span>)
         
     | 
| 
       470 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       471 
     | 
    
         
            -
                      </div>
         
     | 
| 
       472 
     | 
    
         
            -
                      
         
     | 
| 
       473 
     | 
    
         
            -
                    </div>
         
     | 
| 
       474 
     | 
    
         
            -
             
     | 
| 
       475 
     | 
    
         
            -
                    
         
     | 
| 
       476 
     | 
    
         
            -
             
     | 
| 
       477 
     | 
    
         
            -
                    
         
     | 
| 
       478 
     | 
    
         
            -
                  </div>
         
     | 
| 
       479 
     | 
    
         
            -
             
     | 
| 
       480 
     | 
    
         
            -
                
         
     | 
| 
       481 
     | 
    
         
            -
                  <div id="method-i-root-3F" class="method-detail ">
         
     | 
| 
       482 
     | 
    
         
            -
                    
         
     | 
| 
       483 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       484 
     | 
    
         
            -
                      <span class="method-name">root?</span><span
         
     | 
| 
       485 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       486 
     | 
    
         
            -
                      
         
     | 
| 
       487 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       488 
     | 
    
         
            -
                      
         
     | 
| 
       489 
     | 
    
         
            -
                    </div>
         
     | 
| 
       490 
     | 
    
         
            -
                    
         
     | 
| 
       491 
     | 
    
         
            -
             
     | 
| 
       492 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       493 
     | 
    
         
            -
                      
         
     | 
| 
       494 
     | 
    
         
            -
                      
         
     | 
| 
       495 
     | 
    
         
            -
                      
         
     | 
| 
       496 
     | 
    
         
            -
                      
         
     | 
| 
       497 
     | 
    
         
            -
             
     | 
| 
       498 
     | 
    
         
            -
                      
         
     | 
| 
       499 
     | 
    
         
            -
                      <div class="method-source-code" id="root-3F-source">
         
     | 
| 
       500 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 68</span>
         
     | 
| 
       501 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">root?</span>
         
     | 
| 
       502 
     | 
    
         
            -
              <span class="ruby-ivar">@root</span> <span class="ruby-operator">||=</span> <span class="ruby-keyword">begin</span>
         
     | 
| 
       503 
     | 
    
         
            -
                <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">find</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">call_info</span><span class="ruby-operator">|</span>
         
     | 
| 
       504 
     | 
    
         
            -
                  <span class="ruby-keyword">not</span> <span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">root?</span>
         
     | 
| 
       505 
     | 
    
         
            -
                <span class="ruby-keyword">end</span>.<span class="ruby-identifier">nil?</span>
         
     | 
| 
       506 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       507 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       508 
     | 
    
         
            -
                      </div>
         
     | 
| 
       509 
     | 
    
         
            -
                      
         
     | 
| 
       510 
     | 
    
         
            -
                    </div>
         
     | 
| 
       511 
     | 
    
         
            -
             
     | 
| 
       512 
     | 
    
         
            -
                    
         
     | 
| 
       513 
     | 
    
         
            -
             
     | 
| 
       514 
     | 
    
         
            -
                    
         
     | 
| 
       515 
     | 
    
         
            -
                  </div>
         
     | 
| 
       516 
     | 
    
         
            -
             
     | 
| 
       517 
     | 
    
         
            -
                
         
     | 
| 
       518 
     | 
    
         
            -
                  <div id="method-i-self_time" class="method-detail ">
         
     | 
| 
       519 
     | 
    
         
            -
                    
         
     | 
| 
       520 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       521 
     | 
    
         
            -
                      <span class="method-name">self_time</span><span
         
     | 
| 
       522 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       523 
     | 
    
         
            -
                      
         
     | 
| 
       524 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       525 
     | 
    
         
            -
                      
         
     | 
| 
       526 
     | 
    
         
            -
                    </div>
         
     | 
| 
       527 
     | 
    
         
            -
                    
         
     | 
| 
       528 
     | 
    
         
            -
             
     | 
| 
       529 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       530 
     | 
    
         
            -
                      
         
     | 
| 
       531 
     | 
    
         
            -
                      
         
     | 
| 
       532 
     | 
    
         
            -
                      
         
     | 
| 
       533 
     | 
    
         
            -
                      
         
     | 
| 
       534 
     | 
    
         
            -
             
     | 
| 
       535 
     | 
    
         
            -
                      
         
     | 
| 
       536 
     | 
    
         
            -
                      <div class="method-source-code" id="self_time-source">
         
     | 
| 
       537 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 37</span>
         
     | 
| 
       538 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">self_time</span>
         
     | 
| 
       539 
     | 
    
         
            -
              <span class="ruby-ivar">@self_time</span> <span class="ruby-operator">||=</span> <span class="ruby-keyword">begin</span>
         
     | 
| 
       540 
     | 
    
         
            -
                <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">inject</span>(<span class="ruby-value">0</span>) <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">sum</span>, <span class="ruby-identifier">call_info</span><span class="ruby-operator">|</span>
         
     | 
| 
       541 
     | 
    
         
            -
                  <span class="ruby-identifier">sum</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">self_time</span> <span class="ruby-keyword">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">recursive?</span>
         
     | 
| 
       542 
     | 
    
         
            -
                  <span class="ruby-identifier">sum</span>
         
     | 
| 
       543 
     | 
    
         
            -
                <span class="ruby-keyword">end</span>
         
     | 
| 
       544 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       545 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       546 
     | 
    
         
            -
                      </div>
         
     | 
| 
       547 
     | 
    
         
            -
                      
         
     | 
| 
       548 
     | 
    
         
            -
                    </div>
         
     | 
| 
       549 
     | 
    
         
            -
             
     | 
| 
       550 
     | 
    
         
            -
                    
         
     | 
| 
       551 
     | 
    
         
            -
             
     | 
| 
       552 
     | 
    
         
            -
                    
         
     | 
| 
       553 
     | 
    
         
            -
                  </div>
         
     | 
| 
       554 
     | 
    
         
            -
             
     | 
| 
       555 
     | 
    
         
            -
                
         
     | 
| 
       556 
     | 
    
         
            -
                  <div id="method-i-to_s" class="method-detail ">
         
     | 
| 
       557 
     | 
    
         
            -
                    
         
     | 
| 
       558 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       559 
     | 
    
         
            -
                      <span class="method-name">to_s</span><span
         
     | 
| 
       560 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       561 
     | 
    
         
            -
                      
         
     | 
| 
       562 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       563 
     | 
    
         
            -
                      
         
     | 
| 
       564 
     | 
    
         
            -
                    </div>
         
     | 
| 
       565 
     | 
    
         
            -
                    
         
     | 
| 
       566 
     | 
    
         
            -
             
     | 
| 
       567 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       568 
     | 
    
         
            -
                      
         
     | 
| 
       569 
     | 
    
         
            -
                      
         
     | 
| 
       570 
     | 
    
         
            -
                      
         
     | 
| 
       571 
     | 
    
         
            -
                      
         
     | 
| 
       572 
     | 
    
         
            -
             
     | 
| 
       573 
     | 
    
         
            -
                      
         
     | 
| 
       574 
     | 
    
         
            -
                      <div class="method-source-code" id="to_s-source">
         
     | 
| 
       575 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 108</span>
         
     | 
| 
       576 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">to_s</span>
         
     | 
| 
       577 
     | 
    
         
            -
              <span class="ruby-node">"#{self.full_name} (c: #{self.called}, tt: #{self.total_time}, st: #{self.self_time}, wt: #{wait_time}, ct: #{self.children_time})"</span>
         
     | 
| 
       578 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       579 
     | 
    
         
            -
                      </div>
         
     | 
| 
       580 
     | 
    
         
            -
                      
         
     | 
| 
       581 
     | 
    
         
            -
                    </div>
         
     | 
| 
       582 
     | 
    
         
            -
             
     | 
| 
       583 
     | 
    
         
            -
                    
         
     | 
| 
       584 
     | 
    
         
            -
             
     | 
| 
       585 
     | 
    
         
            -
                    
         
     | 
| 
       586 
     | 
    
         
            -
                  </div>
         
     | 
| 
       587 
     | 
    
         
            -
             
     | 
| 
       588 
     | 
    
         
            -
                
         
     | 
| 
       589 
     | 
    
         
            -
                  <div id="method-i-total_time" class="method-detail ">
         
     | 
| 
       590 
     | 
    
         
            -
                    
         
     | 
| 
       591 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       592 
     | 
    
         
            -
                      <span class="method-name">total_time</span><span
         
     | 
| 
       593 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       594 
     | 
    
         
            -
                      
         
     | 
| 
       595 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       596 
     | 
    
         
            -
                      
         
     | 
| 
       597 
     | 
    
         
            -
                    </div>
         
     | 
| 
       598 
     | 
    
         
            -
                    
         
     | 
| 
       599 
     | 
    
         
            -
             
     | 
| 
       600 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       601 
     | 
    
         
            -
                      
         
     | 
| 
       602 
     | 
    
         
            -
                      
         
     | 
| 
       603 
     | 
    
         
            -
                      
         
     | 
| 
       604 
     | 
    
         
            -
                      
         
     | 
| 
       605 
     | 
    
         
            -
             
     | 
| 
       606 
     | 
    
         
            -
                      
         
     | 
| 
       607 
     | 
    
         
            -
                      <div class="method-source-code" id="total_time-source">
         
     | 
| 
       608 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 28</span>
         
     | 
| 
       609 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">total_time</span>
         
     | 
| 
       610 
     | 
    
         
            -
              <span class="ruby-ivar">@total_time</span> <span class="ruby-operator">||=</span> <span class="ruby-keyword">begin</span>
         
     | 
| 
       611 
     | 
    
         
            -
                <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">inject</span>(<span class="ruby-value">0</span>) <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">sum</span>, <span class="ruby-identifier">call_info</span><span class="ruby-operator">|</span>
         
     | 
| 
       612 
     | 
    
         
            -
                  <span class="ruby-identifier">sum</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">total_time</span> <span class="ruby-keyword">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">recursive?</span>
         
     | 
| 
       613 
     | 
    
         
            -
                  <span class="ruby-identifier">sum</span>
         
     | 
| 
       614 
     | 
    
         
            -
                <span class="ruby-keyword">end</span>
         
     | 
| 
       615 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       616 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       617 
     | 
    
         
            -
                      </div>
         
     | 
| 
       618 
     | 
    
         
            -
                      
         
     | 
| 
       619 
     | 
    
         
            -
                    </div>
         
     | 
| 
       620 
     | 
    
         
            -
             
     | 
| 
       621 
     | 
    
         
            -
                    
         
     | 
| 
       622 
     | 
    
         
            -
             
     | 
| 
       623 
     | 
    
         
            -
                    
         
     | 
| 
       624 
     | 
    
         
            -
                  </div>
         
     | 
| 
       625 
     | 
    
         
            -
             
     | 
| 
       626 
     | 
    
         
            -
                
         
     | 
| 
       627 
     | 
    
         
            -
                  <div id="method-i-wait_time" class="method-detail ">
         
     | 
| 
       628 
     | 
    
         
            -
                    
         
     | 
| 
       629 
     | 
    
         
            -
                    <div class="method-heading">
         
     | 
| 
       630 
     | 
    
         
            -
                      <span class="method-name">wait_time</span><span
         
     | 
| 
       631 
     | 
    
         
            -
                        class="method-args">()</span>
         
     | 
| 
       632 
     | 
    
         
            -
                      
         
     | 
| 
       633 
     | 
    
         
            -
                      <span class="method-click-advice">click to toggle source</span>
         
     | 
| 
       634 
     | 
    
         
            -
                      
         
     | 
| 
       635 
     | 
    
         
            -
                    </div>
         
     | 
| 
       636 
     | 
    
         
            -
                    
         
     | 
| 
       637 
     | 
    
         
            -
             
     | 
| 
       638 
     | 
    
         
            -
                    <div class="method-description">
         
     | 
| 
       639 
     | 
    
         
            -
                      
         
     | 
| 
       640 
     | 
    
         
            -
                      
         
     | 
| 
       641 
     | 
    
         
            -
                      
         
     | 
| 
       642 
     | 
    
         
            -
                      
         
     | 
| 
       643 
     | 
    
         
            -
             
     | 
| 
       644 
     | 
    
         
            -
                      
         
     | 
| 
       645 
     | 
    
         
            -
                      <div class="method-source-code" id="wait_time-source">
         
     | 
| 
       646 
     | 
    
         
            -
                        <pre><span class="ruby-comment"># File lib/ruby-prof/method_info.rb, line 46</span>
         
     | 
| 
       647 
     | 
    
         
            -
            <span class="ruby-keyword">def</span> <span class="ruby-identifier">wait_time</span>
         
     | 
| 
       648 
     | 
    
         
            -
              <span class="ruby-ivar">@wait_time</span> <span class="ruby-operator">||=</span> <span class="ruby-keyword">begin</span>
         
     | 
| 
       649 
     | 
    
         
            -
                <span class="ruby-identifier">call_infos</span>.<span class="ruby-identifier">inject</span>(<span class="ruby-value">0</span>) <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">sum</span>, <span class="ruby-identifier">call_info</span><span class="ruby-operator">|</span>
         
     | 
| 
       650 
     | 
    
         
            -
                  <span class="ruby-identifier">sum</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">wait_time</span> <span class="ruby-keyword">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">call_info</span>.<span class="ruby-identifier">recursive?</span>
         
     | 
| 
       651 
     | 
    
         
            -
                  <span class="ruby-identifier">sum</span>
         
     | 
| 
       652 
     | 
    
         
            -
                <span class="ruby-keyword">end</span>
         
     | 
| 
       653 
     | 
    
         
            -
              <span class="ruby-keyword">end</span>
         
     | 
| 
       654 
     | 
    
         
            -
            <span class="ruby-keyword">end</span></pre>
         
     | 
| 
       655 
     | 
    
         
            -
                      </div>
         
     | 
| 
       656 
     | 
    
         
            -
                      
         
     | 
| 
       657 
     | 
    
         
            -
                    </div>
         
     | 
| 
       658 
     | 
    
         
            -
             
     | 
| 
       659 
     | 
    
         
            -
                    
         
     | 
| 
       660 
     | 
    
         
            -
             
     | 
| 
       661 
     | 
    
         
            -
                    
         
     | 
| 
       662 
     | 
    
         
            -
                  </div>
         
     | 
| 
       663 
     | 
    
         
            -
             
     | 
| 
       664 
     | 
    
         
            -
                
         
     | 
| 
       665 
     | 
    
         
            -
                </section>
         
     | 
| 
       666 
     | 
    
         
            -
              
         
     | 
| 
       667 
     | 
    
         
            -
              </section>
         
     | 
| 
       668 
     | 
    
         
            -
            </main>
         
     | 
| 
       669 
     | 
    
         
            -
             
     | 
| 
       670 
     | 
    
         
            -
             
     | 
| 
       671 
     | 
    
         
            -
            <footer id="validator-badges" role="contentinfo">
         
     | 
| 
       672 
     | 
    
         
            -
              <p><a href="http://validator.w3.org/check/referer">Validate</a>
         
     | 
| 
       673 
     | 
    
         
            -
              <p>Generated by <a href="https://rdoc.github.io/rdoc">RDoc</a> 5.1.0.
         
     | 
| 
       674 
     | 
    
         
            -
              <p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
         
     | 
| 
       675 
     | 
    
         
            -
            </footer>
         
     | 
| 
       676 
     | 
    
         
            -
             
     |