OLD | NEW |
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 """Utility class to build the v8 master BuildFactory's. | 5 """Utility class to build the v8 master BuildFactory's. |
6 | 6 |
7 Based on gclient_factory.py and adds v8-specific steps.""" | 7 Based on gclient_factory.py and adds v8-specific steps.""" |
8 | 8 |
9 from master.factory import v8_commands | 9 from master.factory import v8_commands |
10 from master.factory import gclient_factory | 10 from master.factory import gclient_factory |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 f.AddDeoptFuzzer(env=factory_properties.get('test_env', {}), | 71 f.AddDeoptFuzzer(env=factory_properties.get('test_env', {}), |
72 options=factory_properties.get('test_options', [])) | 72 options=factory_properties.get('test_options', [])) |
73 if R('webkit'): f.AddV8Webkit() | 73 if R('webkit'): f.AddV8Webkit() |
74 if R('test262'): | 74 if R('test262'): |
75 f.AddV8Test262(options=factory_properties.get('test_options', [])) | 75 f.AddV8Test262(options=factory_properties.get('test_options', [])) |
76 if R('mozilla'): f.AddV8Mozilla() | 76 if R('mozilla'): f.AddV8Mozilla() |
77 if R('gcmole'): f.AddV8GCMole() | 77 if R('gcmole'): f.AddV8GCMole() |
78 if R('simpleleak'): f.AddSimpleLeakTest() | 78 if R('simpleleak'): f.AddSimpleLeakTest() |
79 | 79 |
80 def V8Factory(self, target='Release', clobber=False, tests=None, mode=None, | 80 def V8Factory(self, target='Release', clobber=False, tests=None, mode=None, |
81 slave_type='BuilderTester', options=None, compile_timeout=1200, | 81 options=None, compile_timeout=1200, |
82 build_url=None, project=None, factory_properties=None, | 82 build_url=None, project=None, factory_properties=None, |
83 target_arch=None, shard_count=1, | 83 target_arch=None, shard_count=1, |
84 shard_run=1, shell_flags=None, isolates=False, | 84 shard_run=1, shell_flags=None, isolates=False, |
85 command_prefix=None): | 85 command_prefix=None): |
86 tests = tests or [] | 86 tests = tests or [] |
87 factory_properties = (factory_properties or {}).copy() | 87 factory_properties = (factory_properties or {}).copy() |
88 | 88 |
89 # Automatically set v8_target_arch in GYP_DEFINES to target_arch. | 89 # Automatically set v8_target_arch in GYP_DEFINES to target_arch. |
90 if not 'gclient_env' in factory_properties: | 90 if not 'gclient_env' in factory_properties: |
91 factory_properties['gclient_env'] = {} | 91 factory_properties['gclient_env'] = {} |
(...skipping 11 matching lines...) Expand all Loading... |
103 self._solutions[0].custom_deps_list.append(self.CUSTOM_DEPS_VALGRIND) | 103 self._solutions[0].custom_deps_list.append(self.CUSTOM_DEPS_VALGRIND) |
104 | 104 |
105 if (gclient_factory.ShouldRunTest(tests, 'mozilla')): | 105 if (gclient_factory.ShouldRunTest(tests, 'mozilla')): |
106 self._solutions[0].custom_deps_list.append(self.CUSTOM_DEPS_MOZILLA) | 106 self._solutions[0].custom_deps_list.append(self.CUSTOM_DEPS_MOZILLA) |
107 | 107 |
108 if (gclient_factory.ShouldRunTest(tests, 'arm')): | 108 if (gclient_factory.ShouldRunTest(tests, 'arm')): |
109 self._solutions[0].custom_deps_list.append(self.CUSTOM_DEPS_MOZILLA) | 109 self._solutions[0].custom_deps_list.append(self.CUSTOM_DEPS_MOZILLA) |
110 | 110 |
111 factory = self.BuildFactory(target=target, clobber=clobber, tests=tests, | 111 factory = self.BuildFactory(target=target, clobber=clobber, tests=tests, |
112 mode=mode, | 112 mode=mode, |
113 slave_type=slave_type, | 113 slave_type='BuilderTester', |
114 options=options, | 114 options=options, |
115 compile_timeout=compile_timeout, | 115 compile_timeout=compile_timeout, |
116 build_url=build_url, | 116 build_url=build_url, |
117 project=project, | 117 project=project, |
118 factory_properties=factory_properties, | 118 factory_properties=factory_properties, |
119 target_arch=target_arch) | 119 target_arch=target_arch) |
120 | 120 |
121 # Get the factory command object to create new steps to the factory. | 121 # Get the factory command object to create new steps to the factory. |
122 # Note - we give '' as build_dir as we use our own build in test tools | 122 # Note - we give '' as build_dir as we use our own build in test tools |
123 v8_cmd_obj = v8_commands.V8Commands(factory, | 123 v8_cmd_obj = v8_commands.V8Commands(factory, |
124 target, | 124 target, |
125 '', | 125 '', |
126 self._target_platform, | 126 self._target_platform, |
127 target_arch, | 127 target_arch, |
128 shard_count, | 128 shard_count, |
129 shard_run, | 129 shard_run, |
130 shell_flags, | 130 shell_flags, |
131 isolates, | 131 isolates, |
132 command_prefix) | 132 command_prefix) |
133 if factory_properties.get('archive_build'): | 133 if factory_properties.get('archive_build'): |
134 v8_cmd_obj.AddArchiveBuild( | 134 v8_cmd_obj.AddArchiveBuild( |
135 extra_archive_paths=factory_properties.get('extra_archive_paths')) | 135 extra_archive_paths=factory_properties.get('extra_archive_paths')) |
136 | 136 |
137 # This is for the arm tester board (we don't have other pure tester slaves). | |
138 if (slave_type == 'Tester'): | |
139 v8_cmd_obj.AddMoveExtracted() | |
140 | |
141 # Add all the tests. | 137 # Add all the tests. |
142 self._AddTests(v8_cmd_obj, tests, mode, factory_properties) | 138 self._AddTests(v8_cmd_obj, tests, mode, factory_properties) |
143 return factory | 139 return factory |
OLD | NEW |