More 32bit perf test bound updates
[ghc.git] / testsuite / tests / perf / compiler / all.T
1 def no_lint(name, opts):
2    opts.compiler_always_flags = \
3        filter(lambda opt: opt != '-dcore-lint' and opt != '-dcmm-lint', opts.compiler_always_flags)
4
5 setTestOpts(no_lint)
6
7
8 test('T1969',
9      [compiler_stats_num_field('peak_megabytes_allocated',
10           [(wordsize(32), 14, 1),
11              # 2010-05-17 14 (x86/Windows)
12              #            15 (x86/OS X)
13              #            19 (x86/OS X)
14              # 2013-02-10 13 (x86/Windows)
15              # 2013-02-10 14 (x86/OSX)
16            (wordsize(64), 25, 1)]),
17              #            28 (amd64/Linux)
18              #            34 (amd64/Linux)
19              # 2012-09-20 23 (amd64/Linux)
20              # 2012-10-03 25 (amd64/Linux if .hi exists)
21       compiler_stats_num_field('max_bytes_used',
22           [(platform('i386-unknown-mingw32'), 5159748, 1),
23                                  # 2010-05-17 5717704 (x86/Windows)
24                                  # 2013-02-10 5159748 (x86/Windows)
25            (wordsize(32), 6149572, 1),
26              #            6707308 (x86/OS X)
27              # 2009-12-31 6149572 (x86/Linux)
28            (wordsize(64), 9000000, 20)]),
29                # looks like the peak is around 10M, but we're
30                # unlikely to GC exactly on the peak.
31                # varies quite a lot with CLEANUP and BINDIST,
32                # hence 10% range.
33       compiler_stats_num_field('bytes allocated',
34           [(platform('i386-unknown-mingw32'), 303930948, 1),
35                                  #            215582916 (x86/Windows)
36                                  # 2012-10-29 298921816 (x86/Windows)
37            (wordsize(32), 322937684, 1),
38              #            221667908 (x86/OS X)
39              #            274932264 (x86/Linux)
40              # 2012-10-08 303930948 (x86/Linux, new codegen)
41              # 2013-02-10 322937684 (x86/OSX)
42            (wordsize(64), 658786936, 5)]),
43              # 17/11/2009 434845560 (amd64/Linux)
44              # 08/12/2009 459776680 (amd64/Linux)
45              # 17/05/2010 519377728 (amd64/Linux)
46              # 05/08/2011 561382568 (amd64/OS X)
47              # 16/07/2012 589168872 (amd64/Linux)
48              # 20/07/2012 595936240 (amd64/Linux)
49              # 23/08/2012 606230880 (amd64/Linux)
50              # 29/08/2012 633334184 (amd64/Linux)
51              #            (^ new codegen)
52              # 18/09/2012 641959976 (amd64/Linux)
53              # 19/10/2012 661832592 (amd64/Linux)
54              #            (^ -fPIC turned on)
55              # 23/10/2012 642594312 (amd64/Linux)
56              #            (^ -fPIC turned off again)
57              # 12/11/2012 658786936 (amd64/Linux)
58              #            (^ UNKNOWN REASON )
59              # 17/1/13:   667160192 (x86_64/Linux)
60              #            (^ new demand analyser)
61       only_ways(['normal']),
62
63       extra_hc_opts('-dcore-lint -static')
64           # Leave -dcore-lint on for this one test, so that we have something
65           # that will catch a regression in -dcore-lint performance.
66       ],
67      compile,
68      [''])
69
70 # This one tests for the space leak in the native code generator,
71 # where it holds onto the entire asm output until the end.  The space
72 # leak reappears from time to time, so it's a good idea to have a test
73 # for it.  The residency of this test will jump by 10MB to 40MB or so
74 # on x86-64 if the space leak appears.
75
76 # Only run this one if we have an NCG:
77 if 'optasm' in config.compile_ways:
78    conf_3294 = only_ways(['normal'])
79 else:
80    conf_3294 = skip
81
82 test('T3294',
83      [
84       compiler_stats_num_field('max_bytes_used',
85           [(wordsize(32), 20712280, 1),
86              #            17725476 (x86/OS X)
87              #            14593500 (Windows)
88              # 2013-02-10 20651576 (x86/Windows)
89              # 2013-02-10 20772984 (x86/OSX)
90            (wordsize(64), 44894544, 15)]),
91         # prev:           25753192 (amd64/Linux)
92         # 29/08/2012:     37724352 (amd64/Linux)
93         #  (increase due to new codegen, see #7198)
94         # 13/13/2012:     44894544 (amd64/Linux)
95         #  (reason for increase unknown)
96       compiler_stats_num_field('bytes allocated',
97           [(wordsize(32), 1373514844, 5),
98            # previous:     815479800  (x86/Linux)
99            # (^ increase due to new codegen, see #7198)
100            # 2012-10-08:  1373514844 (x86/Linux)
101            (wordsize(64), 2717327208, 5)]),
102             # old:        1357587088 (amd64/Linux)
103             # 29/08/2012: 2961778696 (amd64/Linux)
104             # (^ increase due to new codegen, see #7198)
105             # 18/09/2012: 2717327208 (amd64/Linux)
106       conf_3294
107       ],
108      compile,
109      [''])
110
111 test('T4801',
112      [ # expect_broken(5224),
113        # temporarily unbroken (#5227)
114       compiler_stats_num_field('peak_megabytes_allocated',
115           [(platform('x86_64-apple-darwin'), 58, 1),
116                            # expected value: 58 (amd64/OS X)
117            (wordsize(32), 30, 20),
118            (wordsize(64), 49, 20)]),
119             # prev:       50 (amd64/Linux)
120             # 19/10/2012: 64 (amd64/Linux)
121             #                (^ REASON UNKNOWN!)
122             # 12/11/2012: 49 (amd64/Linux)
123             #                (^ REASON UNKNOWN!)
124
125       compiler_stats_num_field('bytes allocated',
126           [(platform('x86_64-apple-darwin'), 510938976, 5),
127                            # expected value: 510938976 (amd64/OS X):
128
129            (wordsize(32), 185669232, 10),
130         # expected value: 228286660 (x86/OS X)
131
132            (wordsize(64), 392409984, 10)]),
133             # prev:       360243576 (amd64/Linux)
134             # 19/10/2012: 447190832 (amd64/Linux) (-fPIC turned on)
135             # 19/10/2012: 392409984 (amd64/Linux) (-fPIC turned off)
136
137       compiler_stats_num_field('max_bytes_used',
138           [(platform('x86_64-apple-darwin'), 21657520, 5),
139            (wordsize(32), 11139444, 1),
140              #             9651948 (x86/OSX)
141              #            10290952 (windows)
142              # 2013-02-10 11071060 (x86/Windows)
143              # 2013-02-10 11207828 (x86/OSX)
144            (wordsize(64), 21657520, 15)]),
145                 # prev:       20486256 (amd64/OS X)
146                 # 30/08/2012: 17305600--20391920 (varies a lot)
147                 # 19/10/2012: 26882576 (-fPIC turned on)
148                 # 19/10/2012: 18619912 (-fPIC turned off)
149                 # 24/12/2012: 21657520 (perhaps gc sampling time wibbles?)
150        only_ways(['normal']),
151        extra_hc_opts('-static')
152       ],
153      compile,
154      [''])
155
156 test('T3064',
157      [# expect_broken( 3064 ),
158       compiler_stats_num_field('peak_megabytes_allocated',
159           [(wordsize(32), 14, 1),
160         # expected value: 14 (x86/Linux 28-06-2012):
161            (wordsize(64), 26, 1)]),
162             # (amd64/Linux):            18
163             # (amd64/Linux) 2012-02-07: 26
164
165       compiler_stats_num_field('bytes allocated',
166           [(wordsize(32), 111189536, 10),
167          # expected value: 56380288 (x86/Linux) (28/6/2011)
168          #                111189536 (x86/Windows) (30/10/12)
169            (wordsize(64), 224798696, 5)]),
170             # (amd64/Linux) (28/06/2011):  73259544
171             # (amd64/Linux) (07/02/2013): 224798696
172
173       compiler_stats_num_field('max_bytes_used',
174           [(wordsize(32), 5511604, 20),
175         # expected value: 2247016 (x86/Linux) (28/6/2011):
176            (wordsize(64), 9819288, 5)]),
177             # (amd64/Linux, intree) (28/06/2011):  4032024
178             # (amd64/Linux, intree) (07/02/2013):  9819288
179        only_ways(['normal'])
180       ],
181      compile,
182      [''])
183
184 test('T4007',
185      normal,
186      run_command,
187      ['$MAKE -s --no-print-directory T4007'])
188
189 test('T5030',
190      [compiler_stats_num_field('bytes allocated',
191           [(wordsize(32), 259547660, 10),
192            # previous:    196457520
193            # 2012-10-08:  259547660 (x86/Linux, new codegen)
194            (wordsize(64), 602993184, 10)]),
195              # Previously 530000000 (+/- 10%)
196              # 17/1/13:   602993184  (x86_64/Linux)
197              #            (new demand analyser)
198    
199        only_ways(['normal'])
200       ],
201      compile,
202      ['-fcontext-stack=300'])
203
204 test('T5631',
205      [compiler_stats_num_field('bytes allocated',
206           [(wordsize(32), 392904228, 10),
207         # expected value: 392904228 (x86/Linux)
208            (wordsize(64), 774595008, 5)]),
209         # expected value: 774595008 (amd64/Linux):
210        only_ways(['normal'])
211       ],
212      compile,
213      [''])
214
215 test('parsing001',
216      [compiler_stats_num_field('bytes allocated',
217           [(wordsize(32), 274000576, 10),
218            (wordsize(64), 587079016, 5)]),
219         # expected value: 587079016 (amd64/Linux)
220        only_ways(['normal']),
221       ],
222      compile_fail, [''])
223
224
225 test('T783',
226      [ only_ways(['normal']),  # no optimisation for this one
227       # expected value: 175,569,928 (x86/Linux)
228       compiler_stats_num_field('bytes allocated',
229           [(wordsize(32), 333833658, 2),
230             # 2012-10-08: 226907420 (x86/Linux)
231             # 2013-02-10: 329202116 (x86/Windows)
232             # 2013-02-10: 338465200 (x86/OSX)
233            (wordsize(64), 640324528, 10)]),
234             # prev:       349263216 (amd64/Linux)
235             # 07/08/2012: 384479856 (amd64/Linux)
236             # 29/08/2012: 436927840 (amd64/Linux)
237             # 12/11/2012: 640324528 (amd64/Linux)
238             #   (OldCmm removed: not sure why this got worse, the
239             #    other perf tests remained about the same)
240       extra_hc_opts('-static')
241       ],
242       compile,[''])
243
244 test('T5321Fun',
245      [ only_ways(['normal']),  # no optimisation for this one
246        compiler_stats_num_field('bytes allocated',
247            [(wordsize(32), 344416344, 10),
248              # prev:       300000000
249              # 2012-10-08: 344416344 x86/Linux
250              #  (increase due to new codegen)
251             (wordsize(64), 713385808, 10)])
252              # prev:       585521080
253              # 29/08/2012: 713385808
254              #  (increase due to new codegen)
255       ],
256       compile,[''])
257
258 test('T5321FD',
259      [ only_ways(['normal']),  # no optimisation for this one
260       compiler_stats_num_field('bytes allocated',
261           [(wordsize(32), 240302920, 10),
262             # prev:       213380256
263             # 2012-10-08: 240302920 (x86/Linux)
264             #  (increase due to new codegen)
265            (wordsize(64), 492905640, 10)])
266             # prev:       418306336
267             # 29/08/2012: 492905640
268             #  (increase due to new codegen)
269       ],
270       compile,[''])
271
272 test('T5642',
273      [ only_ways(['normal']),
274        compiler_stats_num_field('bytes allocated',
275            [(wordsize(32), 650000000, 10),
276                      # sample from x86/Linux
277             (wordsize(64), 1300000000, 10)])
278       ],
279       compile,['-O'])
280
281 test('T5837',
282      [ only_ways(['normal']),
283       compiler_stats_num_field('bytes allocated',
284           [(wordsize(32), 40000000, 10),
285           # sample from x86/Linux
286            (wordsize(64), 81879216, 10)])
287               # sample: 3926235424 (amd64/Linux, 15/2/2012)
288              # 2012-10-02 81879216
289              # 2012-09-20 87254264 amd64/Linux
290       ],
291       compile_fail,['-fcontext-stack=50'])
292
293 test('T6048',
294      [ only_ways(['optasm']),
295       compiler_stats_num_field('bytes allocated',
296           [(wordsize(32), 48887164, 10),
297             # prev:       38000000 (x86/Linux)
298             # 2012-10-08: 48887164 (x86/Linux)
299            (wordsize(64), 97247032, 10)])
300              # 18/09/2012 97247032 amd64/Linux
301       ],
302       compile,[''])