Update perf values for T5237
[ghc.git] / testsuite / tests / perf / should_run / all.T
1 # Tests that newArray/newArray_ is being optimised correctly
2
3 # fortunately the values here are mostly independent of the wordsize,
4 # because the test allocates an unboxed array of doubles.
5
6 test('T3586',
7      [stats_num_field('peak_megabytes_allocated', (17, 1)),
8                                  # expected value: 17 (amd64/Linux)
9       stats_num_field('bytes allocated', (16835544, 5)),
10                         # expected value: 16835544 (amd64/Linux)
11       only_ways(['normal'])
12       ],
13      compile_and_run,
14      ['-O'])
15
16 test('T4830',
17      [stats_num_field('bytes allocated',
18           [(wordsize(64), 99264, 1),
19            #             127000 (amd64/Linux)
20            # 2013-02-07:  99264 (amd64/Linux)
21            (wordsize(32), 70646, 2)]),
22            # 2013-02-10:  69744 (x86/Windows)
23            # 2013-02-10:  71548 (x86/OSX)
24       only_ways(['normal'])
25       ],
26      compile_and_run,
27      ['-O2'])
28
29 test('T3245', normal, compile_and_run, ['-O'])
30
31 # Test that bytestring reading/writing isn't over-allocating.  We had
32 # a bug in hGetBufNonBlocking in 6.13 that triggered this.
33 #
34 test('lazy-bs-alloc',
35      [stats_num_field('peak_megabytes_allocated', (2, 1)),
36                                  # expected value: 2 (amd64/Linux)
37       stats_num_field('bytes allocated',
38           [(wordsize(64), 425400, 1),
39             #             489776 (amd64/Linux)
40             # 2013-02-07: 429744 (amd64/Linux)
41             # 2013-12-12: 425400 (amd64/Linux)
42            (wordsize(32), 417738, 1)]),
43             # 2013-02-10: 421296 (x86/Windows)
44             # 2013-02-10: 414180 (x86/OSX)
45       only_ways(['normal']),
46       extra_run_opts('../../numeric/should_run/arith011.stdout'),
47       ignore_output
48       ],
49       # use a suitably big file, without bloating the repo with a new one:
50      compile_and_run,
51      ['-O'])
52
53 test('T876',
54      [stats_num_field('bytes allocated',
55           [(wordsize(64), 1263712 , 5),
56               # 2013-02-14: 1263712 (x86_64/Linux)
57            (wordsize(32), 663712, 5)]),
58       only_ways(['normal']),
59       extra_run_opts('10000')
60       ],
61      compile_and_run,
62      ['-O'])
63
64 # Get reproducible floating-point results on x86
65 if config.arch == 'i386':
66    sse2_opts = '-msse2'
67 else:
68    sse2_opts = ''
69
70 test('T4321',
71      omit_ways(['ghci']),
72      compile_and_run, ['-O ' + sse2_opts])
73
74 test('T3736',
75      extra_clean(['T3736.speed.f32']),
76      run_command,
77      ['$MAKE -s --no-print-directory T3736'])
78 test('T3738',
79      [extra_clean(['T3738a.hi', 'T3738a.o']),
80       stats_num_field('peak_megabytes_allocated', (1, 0)),
81                                  # expected value: 1 (amd64/Linux)
82       stats_num_field('bytes allocated',
83                       [(wordsize(32), 45648, 5),
84                     # expected value: 45648 (x86/Linux)
85                        (wordsize(64), 49400, 5)]),
86                     # expected value: 49400 (amd64/Linux)
87       only_ways(['normal'])
88       ],
89      compile_and_run,
90      ['-O'])
91
92 test('MethSharing',
93      [stats_num_field('peak_megabytes_allocated', (1, 0)),
94                                  # expected value: 1 (amd64/Linux)
95       stats_num_field('bytes allocated',
96                       [(wordsize(32), 360940756, 5),
97                     # expected value: 2685858140 (x86/OS X)
98                           # expected: 360940756 (x86/Linux)
99                        (wordsize(64), 640067672, 5)]),
100                           # expected: 640067672 (amd64/Linux)
101       only_ways(['normal'])
102       ],
103      compile_and_run,
104      ['-O'])
105 test('T2902',
106      extra_clean(['T2902_A',    'T2902_B',
107                   'T2902_A.hi', 'T2902_B.hi',
108                   'T2902_A.o',  'T2902_B.o',
109                   'T2902_A_PairingSum.hi', 'T2902_B_PairingSum.hi',
110                   'T2902_A_PairingSum.o',  'T2902_B_PairingSum.o',
111                   'T2902_Sum.hi',
112                   'T2902_Sum.o']),
113      run_command,
114      ['$MAKE -s --no-print-directory T2902'])
115 test('T149',
116      [ # expect_broken(149),
117        # working (2 Jul 2013, x86-64/Linux)
118       extra_clean(['T149_A',    'T149_B',
119                    'T149_A.hi', 'T149_B.hi',
120                    'T149_A.o',  'T149_B.o'])],
121      run_command,
122      ['$MAKE -s --no-print-directory T149'])
123
124 test('T5113',
125      [stats_num_field('bytes allocated',
126                       [(wordsize(32), 4000000, 5),
127                        (wordsize(64), 8000000, 5)]),
128       only_ways(['normal'])
129       ],
130      compile_and_run,
131      ['-O'])
132
133
134 test('T4978',
135      [stats_num_field('bytes allocated',
136                       [(wordsize(32), 10000000, 5),
137                        (wordsize(64), 10137680, 5)]),
138                     # expected value: 10137680 (amd64/Linux)
139       only_ways(['normal'])
140       ],
141      compile_and_run,
142      ['-O2'])
143
144 test('T5205',
145      [stats_num_field('bytes allocated',
146                       [(wordsize(32), 47088, 5),
147                     # expected value: 47088 (x86/Darwin)
148                        (wordsize(64), 51320, 5)]),
149                     # expected value: 51320 (amd64/Linux)
150       only_ways(['normal', 'optasm'])
151       ],
152      compile_and_run,
153      [''])
154
155 test('T5549',
156      [stats_num_field('bytes allocated',
157                       [(wordsize(32), 3362958676, 5),
158                     # expected value: 3362958676 (Windows)
159                        (wordsize(64), 6725846120, 5)]),
160                     # expected value: 6725846120 (amd64/Linux)
161       only_ways(['normal'])
162       ],
163      compile_and_run,
164      ['-O'])
165
166 test('T4474a',
167      [stats_num_field('bytes allocated',
168                       [(wordsize(32), 2405242767, 5),
169                        (wordsize(64), 4831890304, 5)]),
170                     # expected value: 4831890304 (amd64/OSX)
171       only_ways(['normal'])
172       ],
173      compile_and_run,
174      ['-O'])
175 test('T4474b',
176      [stats_num_field('bytes allocated',
177                       [(wordsize(32), 2405242767, 5),
178                        (wordsize(64), 4831890304, 5)]),
179                     # expected value: 4831890304 (amd64/OSX)
180       only_ways(['normal'])
181       ],
182      compile_and_run,
183      ['-O'])
184 test('T4474c',
185      [stats_num_field('bytes allocated',
186                       [(wordsize(32), 2405242767, 5),
187                        (wordsize(64), 4831890304, 5)]),
188                     # expected value: 4831890304 (amd64/OSX)
189       only_ways(['normal'])
190       ],
191      compile_and_run,
192      ['-O'])
193
194 test('T5237',
195      [stats_num_field('bytes allocated',
196                         [(wordsize(32), 78328, 5),
197                       # expected value: 78328 (i386/Linux)
198                          (wordsize(64), 104176, 5)]),
199                       # expected value: 110888 (amd64/Linux)
200                       # expected value: 104176 (amd64/Linux)
201      only_ways(['normal'])
202      ],
203     compile_and_run,
204     ['-O ' + sse2_opts])
205
206 test('T5536',
207      [stats_num_field('bytes allocated',
208                       [(wordsize(32), 446260520, 1),
209                                    # 1246287228 (i386/Linux)
210                                     # 446328556 (i386/Windows)
211                                     # 446192484 (i386/OSX)
212                        (wordsize(64), 892399040, 5)]),
213                    # expected value: 2492589480 (amd64/Linux)
214                    # 17/1/13:         892399040 (x86_64/Linux)
215                    #                  (new demand analyser)
216      extra_clean(['T5536.data']),
217      ignore_output,
218      only_ways(['normal'])
219      ],
220     compile_and_run,
221     ['-O'])
222
223 test('T7257',
224      [stats_num_field('bytes allocated',
225                       [(wordsize(32), 1150000000, 10),
226                     # expected value: 1246287228 (i386/Linux)
227                        (wordsize(64), 1774893760, 5)]),
228                         # 2012-09-21: 1774893760 (amd64/Linux)
229       stats_num_field('peak_megabytes_allocated',
230                       [(wordsize(32), 217, 5),
231                         # 2012-10-08: 217 (x86/Linux)
232                        (wordsize(64), 227, 5)]),
233                         # 2012-09-21: 227 (amd64/Linux)
234
235       only_ways(['normal'])
236      ],
237     compile_and_run, ['-O'])
238
239 test('Conversions',
240      [stats_num_field('bytes allocated',
241                       [(wordsize(32), 78374, 2),
242                         # 2012-12-18: 55316 Guessed 64-bit value / 2
243                         # 2013-02-10: 77472 (x86/OSX)
244                         # 2013-02-10: 79276 (x86/Windows)
245                        (wordsize(64), 110632, 5)]),
246                         # 2012-12-18: 109608 (amd64/OS X)
247
248       only_ways(['normal'])
249      ],
250     compile_and_run, ['-O -msse2'])
251
252 test('T7507', omit_ways(['ghci']), compile_and_run, ['-O'])
253 # For 7507, stack overflow is the bad case
254
255 test('T7436',
256      [stats_num_field('max_bytes_used',
257           [(wordsize(64), 60360, 1),
258            #             127000 (amd64/Linux)
259            # 2013-02-07:  60360 (amd64/Linux)
260            (wordsize(32), 58434, 1)]),
261             # 2013-02-10: 58032 (x86/Windows)
262             # 2013-02-10: 58836 (x86/OSX)
263       only_ways(['normal'])
264       ],
265      compile_and_run,
266      ['-O'])
267
268 test('T7797',
269       [stats_num_field('bytes allocated',
270                       [(wordsize(32), 240044984, 5),
271                           # expected value: 2685858140 (x86/OS X)
272                           # expected: 360940756 (x86/Linux)
273                           # expected: 240044984 (x86/Windows, 64bit machine)
274                        (wordsize(64), 480050944, 5)]),
275                           # expected: 480050944 (amd64/Linux)
276       extra_clean(['T7797a.hi', 'T7797a.o']),
277       only_ways(['normal'])
278       ],
279      compile_and_run,
280      ['-O'])
281
282 test('T7954',
283       [stats_num_field('bytes allocated',
284                       [(wordsize(32), 1380051408, 10),
285                        (wordsize(64), 2720051528, 10)]),
286       only_ways(['normal'])
287       ],
288      compile_and_run,
289      ['-O'])
290
291 test('T7850',
292      [stats_num_field('peak_megabytes_allocated', 
293                       [(wordsize(32), 2, 10),
294                        (wordsize(64), 4, 10)]),
295       only_ways(['normal'])],
296      compile_and_run,
297      ['-O'])
298