OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 2 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
3 # for details. All rights reserved. Use of this source code is governed by a | 3 # for details. All rights reserved. Use of this source code is governed by a |
4 # BSD-style license that can be found in the LICENSE file. | 4 # BSD-style license that can be found in the LICENSE file. |
5 | 5 |
6 import os | 6 import os |
7 import subprocess | 7 import subprocess |
8 import sys | 8 import sys |
9 import time | 9 import time |
10 | 10 |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 RunCommand('./frog.py', | 57 RunCommand('./frog.py', |
58 '--vm_flags=--compile_all --enable_type_checks --enable_asserts', | 58 '--vm_flags=--compile_all --enable_type_checks --enable_asserts', |
59 '--', '--compile_all', '--enable_type_checks', '--out=frogsh', | 59 '--', '--compile_all', '--enable_type_checks', '--out=frogsh', |
60 'frog.dart') | 60 'frog.dart') |
61 elapsed = time.time() - start | 61 elapsed = time.time() - start |
62 mode = 'in checked mode + compile all' | 62 mode = 'in checked mode + compile all' |
63 print 'Compiling on Dart VM took %s seconds %s' % (b(elapsed), b(mode)) | 63 print 'Compiling on Dart VM took %s seconds %s' % (b(elapsed), b(mode)) |
64 | 64 |
65 # Selfhost Checked | 65 # Selfhost Checked |
66 start = time.time() | 66 start = time.time() |
67 RunCommand('./frogsh', '--out=frogsh', '--enable_type_checks', 'frog.dart', | 67 RunCommand('./frogsh', '--out=frogsh', |
| 68 '--enable_type_checks', '--warnings_as_errors', 'frog.dart', |
68 '--enable_type_checks', 'tests/hello.dart', verbose=True) | 69 '--enable_type_checks', 'tests/hello.dart', verbose=True) |
69 elapsed = time.time() - start | 70 elapsed = time.time() - start |
70 size = os.path.getsize('./frogsh') / 1024 | 71 size = os.path.getsize('./frogsh') / 1024 |
71 print 'Bootstrapping took %s seconds %s' % (b(elapsed), b('in checked mode')) | 72 print 'Bootstrapping took %s seconds %s' % (b(elapsed), b('in checked mode')) |
72 print 'Generated %s frogsh is %s kB' % (b('checked'), b(size)) | 73 print 'Generated %s frogsh is %s kB' % (b('checked'), b(size)) |
73 | 74 |
74 RunCommand('../tools/build.py', '--mode=release') | 75 RunCommand('../tools/build.py', '--mode=release') |
75 test_cmd = ['../tools/test.py', '--report', '--timeout=10', | 76 test_cmd = ['../tools/test.py', '--report', '--timeout=10', |
76 '--progress=color', '--mode=release', '--checked'] | 77 '--progress=color', '--mode=release', '--checked'] |
77 if args[1:]: | 78 if args[1:]: |
(...skipping 16 matching lines...) Expand all Loading... |
94 cmd = test_cmd + ['--component=frogsh,leg', 'language', 'corelib', 'leg', | 95 cmd = test_cmd + ['--component=frogsh,leg', 'language', 'corelib', 'leg', |
95 'isolate', 'peg', 'leg_only', 'frog', 'css'] | 96 'isolate', 'peg', 'leg_only', 'frog', 'css'] |
96 RunCommand(*cmd, verbose=True) | 97 RunCommand(*cmd, verbose=True) |
97 | 98 |
98 if __name__ == '__main__': | 99 if __name__ == '__main__': |
99 try: | 100 try: |
100 sys.exit(main(sys.argv)) | 101 sys.exit(main(sys.argv)) |
101 except Error as e: | 102 except Error as e: |
102 sys.stderr.write('%s\n' % e) | 103 sys.stderr.write('%s\n' % e) |
103 sys.exit(1) | 104 sys.exit(1) |
OLD | NEW |