Update perf bounds for OS X x86
[ghc.git] / testsuite / tests / perf / compiler / all.T
1 test('T1969',
2      [if_wordsize(32,
3           compiler_stats_num_field('peak_megabytes_allocated', 13,
4                                                                19)),
5                              # expected value: 14 (x86/Windows 17/05/10)
6                              #                 15 (x86/OS X)
7                              #                 19 (x86/OS X)
8       if_wordsize(64,
9           compiler_stats_num_field('peak_megabytes_allocated', 24,
10                                                                32)),
11                                              # expected value: 28 (amd64/Linux)
12                                              # expected value: 32 (amd64/Linux)
13       if_wordsize(32,
14           compiler_stats_num_field('max_bytes_used', 5000000,
15                                                      7000000)),
16                              # expected value: 6707308 (x86/OS X)
17                              #                 5717704 (x86/Windows 17/05/10)
18                              #                 6149572 (x86/Linux, 31/12/09)
19       if_wordsize(64,
20           compiler_stats_num_field('max_bytes_used',  9000000,
21                                                      13000000)),
22                                    # expected value: 11404664 (amd64/Linux)
23       if_wordsize(32,
24           compiler_stats_num_field('bytes allocated', 210000000,
25                                                       270000000)),
26                                     # expected value: 215582916 (x86/Windows)
27                                     #                 221667908 (x86/OS X)
28       if_wordsize(64,
29           compiler_stats_num_field('bytes allocated', 420000000,
30                                                       580000000)),
31                                     # 17/11/2009:     434,845,560 (amd64/Linux)
32                                     # 08/12/2009:     459,776,680 (amd64/Linux)
33                                     # 17/05/2010:     519,377,728 (amd64/Linux)
34                                     # 05/08/2011:     561,382,568 (amd64/OS X)
35       only_ways(['normal'])
36       ],
37      compile,
38      [''])
39
40 # This one tests for the space leak in the native code generator,
41 # where it holds onto the entire asm output until the end.  The space
42 # leak reappears from time to time, so it's a good idea to have a test
43 # for it.  The residency of this test will jump by 10MB to 40MB or so
44 # on x86-64 if the space leak appears.
45
46 # Only run this one if we have an NCG:
47 if 'optasm' in config.compile_ways:
48    conf_3294 = only_ways(['normal'])
49 else:
50    conf_3294 = skip
51
52 test('T3294',
53      [if_wordsize(32,
54           compiler_stats_num_field('max_bytes_used', 15000000,
55                                                      20000000)),
56                                    # expected value: 17725476 (x86/OS X)
57       if_wordsize(64,
58           compiler_stats_num_field('max_bytes_used', 26000000,
59                                                      37000000)),
60                                    # expected value: 32 478 408 (amd64/Linux)
61                                    # (but varies a lot, depending on when
62                                    # we GC relative to the peak).
63                                    # (MCB: consistently reaching ~35 375 912 for
64                                    # me lately on amd64/Darwin)
65       if_wordsize(32,
66           compiler_stats_num_field('bytes allocated', 650000000,
67                                                       750000000)),
68                                     # expected value: 815479800  (x86/Linux)
69       if_wordsize(64,
70           compiler_stats_num_field('bytes allocated', 1200000000,
71                                                       1500000000)),
72                                     # expected value: 1357587088 (amd64/Linux)
73       conf_3294
74       ],
75      compile,
76      [''])
77
78 test('T4801',
79      [ # expect_broken(5224),
80        # temporarily unbroken (#5227)
81       # expected value: 11 (x86/OSX):
82       if_wordsize(32,
83           compiler_stats_num_field('peak_megabytes_allocated', 30, 40)),
84       # expected value: 52 (amd64/Linux):
85       if_wordsize(64,
86           compiler_stats_num_field('peak_megabytes_allocated', 50, 54)),
87       # expected value: 64 (amd64/OS X):
88       if_platform('x86_64-apple-darwin',
89           compiler_stats_num_field('peak_megabytes_allocated', 62, 66)),
90       # expected value: 228286660 (x86/OS X)
91       if_wordsize(32,
92           compiler_stats_num_field('bytes allocated', 200000000,
93                                                       240000000)),
94       # expected value: 458700632 (amd64/Linux):
95       if_wordsize(64,
96           compiler_stats_num_field('bytes allocated', 440000000,
97                                                       480000000)),
98       # expected value: 510938976 (amd64/OS X):
99       if_platform('x86_64-apple-darwin',
100           compiler_stats_num_field('bytes allocated', 490000000,
101                                                       530000000)),
102       # expected value: 14181360 (x86/Linux)
103       if_wordsize(32,
104           compiler_stats_num_field('max_bytes_used', 11000000,
105                                                      14000000)),
106       # expected value: 18188272 (amd64/Linux)
107       if_wordsize(64,
108           compiler_stats_num_field('max_bytes_used', 15000000,
109                                                      20000000)),
110       # expected value: 23097936 (amd64/OS X):
111       if_platform('x86_64-apple-darwin',
112           compiler_stats_num_field('max_bytes_used', 21000000,
113                                                      25000000)),
114        only_ways(['normal'])
115       ],
116      compile,
117      [''])
118
119 test('T3064',
120      [
121       # expected value: 9 (x86/Linux 30-03-2011):
122       if_wordsize(32,
123           compiler_stats_num_field('peak_megabytes_allocated', 8, 11)),
124       # expected value: 18 (amd64/Linux):
125       if_wordsize(64,
126           compiler_stats_num_field('peak_megabytes_allocated', 9, 16)),
127       # expected value: 56380288 (x86/Linux) (28/6/2011)
128       if_wordsize(32,
129           compiler_stats_num_field('bytes allocated', 50000000,
130                                                       70000000)),
131       # expected value: 108937496 (amd64/Linux) (28/6/2011):
132       if_wordsize(64,
133           compiler_stats_num_field('bytes allocated', 110000000,
134                                                       140000000)),
135       # expected value: 2247016 (x86/Linux) (28/6/2011):
136       if_wordsize(32,
137           compiler_stats_num_field('max_bytes_used', 2000000,
138                                                      3000000)),
139       # expected value: 4032024 (amd64/Linux, intree) (28/6/2011):
140       if_wordsize(64,
141           compiler_stats_num_field('max_bytes_used', 3000000,
142                                                      5000000)),
143        only_ways(['normal'])
144       ],
145      compile,
146      [''])
147
148 test('T4007',
149      normal,
150      run_command,
151      ['$MAKE -s --no-print-directory T4007'])
152
153 test('T5030',
154      [# expected value: 629864032 (x86/Darwin)
155       if_wordsize(32,
156           compiler_stats_num_field('bytes allocated', 600000000,
157                                                       650000000)),
158       # expected value: 1255998208 (amd64/Linux):
159       if_wordsize(64,
160           compiler_stats_num_field('bytes allocated', 1200000000,
161                                                       1300000000)),
162        only_ways(['normal'])
163       ],
164      compile,
165      ['-fcontext-stack=300'])
166
167 test('parsing001',
168      [# expected value: ?
169       if_wordsize(32,
170           compiler_stats_num_field('bytes allocated', 280000000,
171                                                       320000000)),
172       # expected value: 587079016 (amd64/Linux):
173       if_wordsize(64,
174           compiler_stats_num_field('bytes allocated', 540000000,
175                                                       600000000)),
176        only_ways(['normal']),
177       ],
178      compile_fail, [''])
179
180