mysql2xxxx 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
data/.gitignore CHANGED
@@ -2,4 +2,5 @@
2
2
  .bundle
3
3
  Gemfile.lock
4
4
  pkg/*
5
- rdoc/*
5
+ rdoc/*
6
+ .DS_Store
data/Rakefile CHANGED
@@ -9,6 +9,8 @@ Rake::TestTask.new(:test) do |test|
9
9
  test.verbose = true
10
10
  end
11
11
 
12
+ task :default => :test
13
+
12
14
  begin
13
15
  require 'rake/rdoctask'
14
16
  Rake::RDocTask.new do |rdoc|
@@ -0,0 +1,71 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ ENV['HERE'] = File.dirname(__FILE__)
4
+ ENV['DBUSER'] = 'root'
5
+ ENV['DBPASSWORD'] = 'password'
6
+ ENV['DBNAME'] = 'data1'
7
+ ENV['MEMPROF_REPORT_PATH'] = File.expand_path('memprof.txt')
8
+ ENV['DUMP_PATH'] = File.expand_path('a.dump')
9
+ ENV['EXECUTE'] = 'SELECT * FROM five_thousand_rows'
10
+ FORMATS = %w{ CSV JSON XML }
11
+ SAMPLE_RATE = 0.3
12
+ TOP_OBJECTS = 25
13
+
14
+ require 'fileutils'
15
+ unless RUBY_VERSION >= '1.9'
16
+ require 'rubygems'
17
+ end
18
+ require 'posix/spawn'
19
+ $LOAD_PATH.unshift File.join(ENV['HERE'], '..', 'lib')
20
+ require 'mysql2xxxx'
21
+ require 'mysql2xxxx/version'
22
+
23
+ $stderr.puts "Loading sample data..."
24
+ `bunzip2 #{ENV['HERE']}/five_thousand_rows.sql.bz2 -c | mysql -u #{ENV['DBUSER']} -p#{ENV['DBPASSWORD']} --database #{ENV['DBNAME']}`
25
+
26
+ now = Time.now
27
+ mem = {}
28
+ $mem2 = {}
29
+
30
+ begin
31
+ FORMATS.each do |format|
32
+ $stderr.puts "Benchmarking #{format}..."
33
+ pid = POSIX::Spawn.spawn('ruby', "#{ENV['HERE']}/target.rb", format)
34
+ watcher = Thread.new do
35
+ while true
36
+ sleep SAMPLE_RATE
37
+ $mem2[format] ||= []
38
+ $mem2[format] << `ps -o time= -o rss= -p #{pid}`
39
+ end
40
+ end
41
+ Process.waitpid(pid)
42
+ watcher.kill
43
+ raise "target failed on #{format}" unless $?.success?
44
+ mem[format] = IO.readlines(ENV['MEMPROF_REPORT_PATH'])[0..TOP_OBJECTS-1] unless RUBY_VERSION >= '1.9'
45
+ end
46
+ ensure
47
+ FileUtils.rm_f ENV['MEMPROF_REPORT_PATH']
48
+ FileUtils.rm_f ENV['DUMP_PATH']
49
+ end
50
+
51
+ $stderr.puts "Writing report..."
52
+ File.open File.expand_path(File.join(ENV['HERE'], 'results', "#{Mysql2xxxx::VERSION}-#{now.to_formatted_s(:number)}-#{RUBY_VERSION >= '1.9' ? 'ruby19' : 'ruby18'}.txt")), 'w' do |f|
53
+ f.puts %{mysql2xxxx}
54
+ f.puts %{Version: #{Mysql2xxxx::VERSION}}
55
+ f.puts %{Run: #{now}}
56
+ f.puts %{System: #{`uname -a`}}
57
+ FORMATS.each do |format|
58
+ f.puts
59
+ f.puts "#" * 50
60
+ f.puts "# #{format}"
61
+ f.puts "#" * 50
62
+ f.puts %{Real memory over time (sampled every #{SAMPLE_RATE} sec):}
63
+ f.puts $mem2[format]
64
+ if RUBY_VERSION >= '1.9'
65
+ f.puts %{Memprof object counts not available (ruby 1.9)}
66
+ else
67
+ f.puts %{Memprof object counts (top #{TOP_OBJECTS}):}
68
+ f.puts mem[format]
69
+ end
70
+ end
71
+ end
@@ -0,0 +1,46 @@
1
+ mysql2xxxx
2
+ Version: 0.0.3
3
+ Run: Mon Mar 14 15:33:20 -0500 2011
4
+ System: Darwin vidalia 10.6.0 Darwin Kernel Version 10.6.0: Wed Nov 10 18:13:17 PST 2010; root:xnu-1504.9.26~3/RELEASE_I386 i386
5
+
6
+ CSV
7
+ Time: 5.2898850440979
8
+ Memory:
9
+ 55050 ./benchmark/../lib/mysql2xxxx/csv.rb:25:String
10
+ 24858 ./benchmark/../lib/mysql2xxxx/csv.rb:25:Float
11
+ 10000 (eval):4:Array
12
+ 5423 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/rational.rb:94:Rational
13
+ 5052 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:437:Array
14
+ 5001 ./benchmark/../lib/mysql2xxxx/csv.rb:25:Hash
15
+ 5000 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:754:Date
16
+ 1320 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1798:String
17
+ 1301 ./benchmark/../lib/mysql2xxxx/csv.rb:14:Array
18
+ 1300 ./benchmark/../lib/mysql2xxxx/csv.rb:30:__varmap__
19
+
20
+ JSON
21
+ Time: 15.9774219989777
22
+ Memory:
23
+ 55050 ./benchmark/../lib/mysql2xxxx/json.rb:26:String
24
+ 24858 ./benchmark/../lib/mysql2xxxx/json.rb:26:Float
25
+ 10000 (eval):4:Array
26
+ 5025 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/rational.rb:94:Rational
27
+ 5003 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:437:Array
28
+ 5001 ./benchmark/../lib/mysql2xxxx/json.rb:26:Hash
29
+ 5000 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:754:Date
30
+ 280 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:69:__node__
31
+ 278 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:125:String
32
+ 271 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:73:__node__
33
+
34
+ XML
35
+ Time: 5.43590211868286
36
+ Memory:
37
+ 55050 ./benchmark/../lib/mysql2xxxx/xml.rb:23:String
38
+ 28467 ./benchmark/../lib/mysql2xxxx/xml.rb:26:String
39
+ 24858 ./benchmark/../lib/mysql2xxxx/xml.rb:23:Float
40
+ 12593 ./benchmark/../lib/mysql2xxxx/xml.rb:26:Array
41
+ 10000 (eval):4:Array
42
+ 7016 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/rational.rb:94:Rational
43
+ 6300 ./benchmark/../lib/mysql2xxxx/xml.rb:25:Array
44
+ 5251 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:437:Array
45
+ 5001 ./benchmark/../lib/mysql2xxxx/xml.rb:23:Hash
46
+ 5000 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:754:Date
@@ -0,0 +1,185 @@
1
+ mysql2xxxx
2
+ Version: 0.0.3
3
+ Run: Mon Mar 14 16:09:22 -0500 2011
4
+ System: Darwin vidalia 10.6.0 Darwin Kernel Version 10.6.0: Wed Nov 10 18:13:17 PST 2010; root:xnu-1504.9.26~3/RELEASE_I386 i386
5
+
6
+ ##################################################
7
+ # CSV
8
+ ##################################################
9
+ Real memory over time (sampled every 0.3 sec):
10
+ 0:00.30 11204
11
+ 0:00.56 20488
12
+ 0:00.86 20876
13
+ 0:01.17 30580
14
+ 0:01.48 32684
15
+ 0:01.79 33980
16
+ 0:02.09 35268
17
+ 0:02.39 36892
18
+ 0:02.70 38004
19
+ 0:03.01 39120
20
+ 0:03.31 40264
21
+ 0:03.62 41184
22
+ 0:03.93 41292
23
+ 0:04.24 41472
24
+ 0:04.55 41736
25
+ 0:04.85 49796
26
+ 0:05.16 53260
27
+ Memprof object counts (top 25):
28
+ 55050 ./benchmark/../lib/mysql2xxxx/csv.rb:25:String
29
+ 24858 ./benchmark/../lib/mysql2xxxx/csv.rb:25:Float
30
+ 10000 (eval):4:Array
31
+ 5423 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/rational.rb:94:Rational
32
+ 5052 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:437:Array
33
+ 5001 ./benchmark/../lib/mysql2xxxx/csv.rb:25:Hash
34
+ 5000 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:754:Date
35
+ 1320 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1798:String
36
+ 1301 ./benchmark/../lib/mysql2xxxx/csv.rb:14:Array
37
+ 1300 ./benchmark/../lib/mysql2xxxx/csv.rb:30:__varmap__
38
+ 682 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1795:String
39
+ 421 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1852:String
40
+ 372 (__FORWARDABLE__):5:__node__
41
+ 279 (__FORWARDABLE__):3:__node__
42
+ 217 (__FORWARDABLE__):1:__node__
43
+ 211 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1849:String
44
+ 210 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:428:Float
45
+ 210 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:426:Float
46
+ 210 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:423:Float
47
+ 210 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:422:Float
48
+ 155 (__FORWARDABLE__):6:__node__
49
+ 120 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/i686-darwin10.6.0/stringio.bundle:0:__node__
50
+ 108 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:1383:String
51
+ 108 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1849:Array
52
+ 106 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1852:Method
53
+
54
+ ##################################################
55
+ # JSON
56
+ ##################################################
57
+ Real memory over time (sampled every 0.3 sec):
58
+ 0:00.30 11560
59
+ 0:00.56 19068
60
+ 0:00.73 19508
61
+ 0:01.04 19508
62
+ 0:01.35 19508
63
+ 0:01.65 23616
64
+ 0:01.96 27984
65
+ 0:02.27 28868
66
+ 0:02.58 28896
67
+ 0:02.89 29900
68
+ 0:03.19 29904
69
+ 0:03.50 29904
70
+ 0:03.80 30352
71
+ 0:04.11 31188
72
+ 0:04.42 31264
73
+ 0:04.72 32216
74
+ 0:05.03 32216
75
+ 0:05.34 32492
76
+ 0:05.65 33240
77
+ 0:05.95 33240
78
+ 0:06.26 33996
79
+ 0:06.56 34268
80
+ 0:06.87 34268
81
+ 0:07.18 34508
82
+ 0:07.48 35292
83
+ 0:07.79 35328
84
+ 0:08.10 35328
85
+ 0:08.40 36320
86
+ 0:08.71 36320
87
+ 0:09.02 36548
88
+ 0:09.32 37348
89
+ 0:09.63 37368
90
+ 0:09.94 37652
91
+ 0:10.25 38372
92
+ 0:10.55 38372
93
+ 0:10.86 38376
94
+ 0:11.17 38376
95
+ 0:11.47 38516
96
+ 0:11.78 39400
97
+ 0:12.08 39400
98
+ 0:12.38 39404
99
+ 0:12.69 39404
100
+ 0:13.00 39404
101
+ 0:13.31 46788
102
+ 0:13.61 48948
103
+ 0:13.92 48948
104
+ 0:14.22 49860
105
+ 0:14.53 49860
106
+ 0:14.84 49860
107
+ 0:15.15 50176
108
+ 0:15.46 50828
109
+ 0:15.76 50828
110
+ 0:16.07 50996
111
+ 0:16.37 50996
112
+ Memprof object counts (top 25):
113
+ 55050 ./benchmark/../lib/mysql2xxxx/json.rb:26:String
114
+ 24858 ./benchmark/../lib/mysql2xxxx/json.rb:26:Float
115
+ 10000 (eval):4:Array
116
+ 5025 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/rational.rb:94:Rational
117
+ 5003 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:437:Array
118
+ 5001 ./benchmark/../lib/mysql2xxxx/json.rb:26:Hash
119
+ 5000 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:754:Date
120
+ 280 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:69:__node__
121
+ 278 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:125:String
122
+ 271 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:73:__node__
123
+ 260 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:70:__node__
124
+ 181 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:235:Array
125
+ 170 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/i686-darwin10.6.0/syck.bundle:0:__node__
126
+ 160 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:67:__node__
127
+ 160 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:65:__node__
128
+ 148 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:75:__node__
129
+ 140 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:132:String
130
+ 120 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/i686-darwin10.6.0/stringio.bundle:0:__node__
131
+ 117 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:247:String
132
+ 105 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:68:__node__
133
+ 96 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:247:Array
134
+ 79 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:236:Array
135
+ 64 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/deprecation/proxy_wrappers.rb:13:__node__
136
+ 60 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:72:__node__
137
+ 60 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:71:__node__
138
+
139
+ ##################################################
140
+ # XML
141
+ ##################################################
142
+ Real memory over time (sampled every 0.3 sec):
143
+ 0:00.30 11168
144
+ 0:00.55 20512
145
+ 0:00.83 20540
146
+ 0:01.14 24940
147
+ 0:01.45 31596
148
+ 0:01.75 33208
149
+ 0:02.06 34668
150
+ 0:02.36 35856
151
+ 0:02.66 36800
152
+ 0:02.97 37756
153
+ 0:03.28 39368
154
+ 0:03.58 40392
155
+ 0:03.89 41420
156
+ 0:04.19 41420
157
+ 0:04.50 41424
158
+ 0:04.79 48808
159
+ 0:05.01 51660
160
+ Memprof object counts (top 25):
161
+ 55050 ./benchmark/../lib/mysql2xxxx/xml.rb:23:String
162
+ 28467 ./benchmark/../lib/mysql2xxxx/xml.rb:26:String
163
+ 24858 ./benchmark/../lib/mysql2xxxx/xml.rb:23:Float
164
+ 12593 ./benchmark/../lib/mysql2xxxx/xml.rb:26:Array
165
+ 10000 (eval):4:Array
166
+ 7016 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/rational.rb:94:Rational
167
+ 6300 ./benchmark/../lib/mysql2xxxx/xml.rb:25:Array
168
+ 5251 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:437:Array
169
+ 5001 ./benchmark/../lib/mysql2xxxx/xml.rb:23:Hash
170
+ 5000 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:754:Date
171
+ 1007 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:423:Float
172
+ 1006 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:428:Float
173
+ 1006 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:426:Float
174
+ 1006 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:422:Float
175
+ 504 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:1383:String
176
+ 504 ./benchmark/../lib/mysql2xxxx/xml.rb:23:__varmap__
177
+ 503 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:429:Float
178
+ 503 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:428:Array
179
+ 503 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:427:Float
180
+ 503 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:423:Array
181
+ 502 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:402:Float
182
+ 502 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/date.rb:401:Float
183
+ 254 ./benchmark/../lib/mysql2xxxx/xml.rb:28:String
184
+ 253 ./benchmark/../lib/mysql2xxxx/xml.rb:24:String
185
+ 252 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/rational.rb:337:Array
@@ -0,0 +1,147 @@
1
+ mysql2xxxx
2
+ Version: 0.0.4
3
+ Run: Mon Mar 14 19:06:40 -0500 2011
4
+ System: Darwin vidalia 10.6.0 Darwin Kernel Version 10.6.0: Wed Nov 10 18:13:17 PST 2010; root:xnu-1504.9.26~3/RELEASE_I386 i386
5
+
6
+ ##################################################
7
+ # CSV
8
+ ##################################################
9
+ Real memory over time (sampled every 0.3 sec):
10
+ 0:00.30 13452
11
+ 0:00.61 20140
12
+ 0:00.91 19476
13
+ 0:01.22 20152
14
+ 0:01.53 18456
15
+ 0:01.84 19632
16
+ 0:02.14 20504
17
+ Memprof object counts (top 25):
18
+ 575 ./benchmark/../lib/mysql2xxxx/writer.rb:40:String
19
+ 527 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1798:String
20
+ 372 (__FORWARDABLE__):5:__node__
21
+ 279 (__FORWARDABLE__):3:__node__
22
+ 217 (__FORWARDABLE__):1:__node__
23
+ 169 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1852:String
24
+ 155 (__FORWARDABLE__):6:__node__
25
+ 120 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/i686-darwin10.6.0/stringio.bundle:0:__node__
26
+ 93 (__FORWARDABLE__):7:__node__
27
+ 84 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1849:String
28
+ 62 (__FORWARDABLE__):4:__node__
29
+ 46 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1849:Array
30
+ 44 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1091:Hash
31
+ 43 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1092:__scope__
32
+ 42 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1852:Method
33
+ 42 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1852:MatchData
34
+ 42 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1490:String
35
+ 41 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/forwardable.rb:148:__node__
36
+ 31 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:758:__node__
37
+ 31 (__FORWARDABLE__):8:__node__
38
+ 31 (__FORWARDABLE__):5:Regexp
39
+ 25 ./benchmark/../lib/mysql2xxxx/writer.rb:11:String
40
+ 24 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1831:Hash
41
+ 24 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1830:Regexp
42
+ 24 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/fastercsv-1.5.4/lib/faster_csv.rb:1826:String
43
+
44
+ ##################################################
45
+ # JSON
46
+ ##################################################
47
+ Real memory over time (sampled every 0.3 sec):
48
+ 0:00.31 13736
49
+ 0:00.61 17536
50
+ 0:00.91 17536
51
+ 0:01.19 17536
52
+ 0:01.41 17536
53
+ 0:01.71 17536
54
+ 0:02.02 17536
55
+ 0:02.32 17536
56
+ 0:02.63 17536
57
+ 0:02.93 17536
58
+ 0:03.24 17536
59
+ 0:03.55 17536
60
+ 0:03.85 17536
61
+ 0:04.16 17536
62
+ 0:04.47 17536
63
+ 0:04.79 17536
64
+ 0:05.09 17536
65
+ 0:05.40 17536
66
+ 0:05.71 17536
67
+ 0:06.01 17536
68
+ 0:06.32 17536
69
+ 0:06.62 17536
70
+ 0:06.93 17536
71
+ 0:07.24 17536
72
+ 0:07.55 17536
73
+ 0:07.85 17536
74
+ 0:08.16 17536
75
+ 0:08.46 17536
76
+ 0:08.77 17536
77
+ 0:09.08 17536
78
+ 0:09.38 17536
79
+ 0:09.69 17536
80
+ 0:10.00 17536
81
+ 0:10.30 17536
82
+ 0:10.61 17536
83
+ Memprof object counts (top 25):
84
+ 8360 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:125:String
85
+ 6361 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:73:__node__
86
+ 4261 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:235:Array
87
+ 4183 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:132:String
88
+ 2357 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:247:String
89
+ 2191 ./benchmark/../lib/mysql2xxxx/writer.rb:48:String
90
+ 2183 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:247:Array
91
+ 2080 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:236:Array
92
+ 280 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:69:__node__
93
+ 260 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:70:__node__
94
+ 249 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:61:Hash
95
+ 170 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/i686-darwin10.6.0/syck.bundle:0:__node__
96
+ 160 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:67:__node__
97
+ 160 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:65:__node__
98
+ 148 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:75:__node__
99
+ 120 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/i686-darwin10.6.0/stringio.bundle:0:__node__
100
+ 119 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:247:__node__
101
+ 117 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/i686-darwin10.6.0/bigdecimal.bundle:0:__node__
102
+ 109 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:237:__node__
103
+ 105 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/yaml/tag.rb:68:__node__
104
+ 103 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:235:__node__
105
+ 87 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:41:Array
106
+ 86 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:30:ActiveSupport::JSON::Encoding::Encoder
107
+ 86 /Users/seamus/.rvm/gems/ruby-1.8.7-p334/gems/activesupport-3.0.5/lib/active_support/json/encoding.rb:236:Hash
108
+ 86 ./benchmark/../lib/mysql2xxxx/writer.rb:48:Hash
109
+
110
+ ##################################################
111
+ # XML
112
+ ##################################################
113
+ Real memory over time (sampled every 0.3 sec):
114
+ 0:00.30 13668
115
+ 0:00.61 16952
116
+ 0:00.95 16952
117
+ 0:01.26 17916
118
+ 0:01.56 17532
119
+ 0:01.87 17532
120
+ 0:02.18 17976
121
+ 0:02.41 18556
122
+ Memprof object counts (top 25):
123
+ 16407 ./benchmark/../lib/mysql2xxxx/writer/xml.rb:16:String
124
+ 5455 ./benchmark/../lib/mysql2xxxx/writer.rb:7:Array
125
+ 5453 ./benchmark/../lib/mysql2xxxx/writer/xml.rb:16:Array
126
+ 5439 ./benchmark/../lib/mysql2xxxx/writer.rb:40:String
127
+ 226 ./benchmark/../lib/mysql2xxxx/writer/xml.rb:15:__node__
128
+ 220 ./benchmark/../lib/mysql2xxxx/writer/xml.rb:18:String
129
+ 220 ./benchmark/../lib/mysql2xxxx/writer/xml.rb:14:String
130
+ 219 ./benchmark/../lib/mysql2xxxx/writer.rb:40:Array
131
+ 120 /Users/seamus/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/i686-darwin10.6.0/stringio.bundle:0:__node__
132
+ 28 ./benchmark/../lib/mysql2xxxx/writer/xml.rb:16:__node__
133
+ 25 ./benchmark/../lib/mysql2xxxx/writer/xml.rb:4:String
134
+ 25 ./benchmark/../lib/mysql2xxxx/writer.rb:11:String
135
+ 20 ./benchmark/../lib/mysql2xxxx/writer.rb:16:__node__
136
+ 18 ./benchmark/../lib/mysql2xxxx/writer.rb:33:__node__
137
+ 14 ./benchmark/../lib/mysql2xxxx/writer/xml.rb:12:__node__
138
+ 12 ./benchmark/../lib/mysql2xxxx/writer.rb:11:__node__
139
+ 12 ./benchmark/../lib/mysql2xxxx/properties.rb:32:__node__
140
+ 12 ./benchmark/../lib/mysql2xxxx/properties.rb:28:__node__
141
+ 12 ./benchmark/../lib/mysql2xxxx/properties.rb:24:__node__
142
+ 12 ./benchmark/../lib/mysql2xxxx/properties.rb:20:__node__
143
+ 11 ./benchmark/../lib/mysql2xxxx/writer/xml.rb:4:__node__
144
+ 10 ./benchmark/../lib/mysql2xxxx/properties.rb:36:__node__
145
+ 9 ./benchmark/../lib/mysql2xxxx/writer.rb:26:__node__
146
+ 8 ./benchmark/../lib/mysql2xxxx/writer.rb:73:__node__
147
+ 8 ./benchmark/../lib/mysql2xxxx/writer.rb:32:__node__