OLD | NEW |
1 # Copyright 2013 The Chromium Authors. All rights reserved. | 1 # Copyright 2013 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 import pipes | 5 import pipes |
6 | 6 |
7 from slave.recipe_config import config_item_context, ConfigGroup | 7 from slave.recipe_config import config_item_context, ConfigGroup |
8 from slave.recipe_config import Dict, List, Single, Static, Set, BadConf | 8 from slave.recipe_config import Dict, List, Single, Static, Set, BadConf |
9 from slave.recipe_config_types import Path | 9 from slave.recipe_config_types import Path |
10 | 10 |
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
333 if c.TARGET_PLATFORM == 'linux': | 333 if c.TARGET_PLATFORM == 'linux': |
334 c.gyp_env.GYP_DEFINES['use_allocator'] = 'none' | 334 c.gyp_env.GYP_DEFINES['use_allocator'] = 'none' |
335 | 335 |
336 c.gyp_env.GYP_DEFINES['asan'] = 1 | 336 c.gyp_env.GYP_DEFINES['asan'] = 1 |
337 c.gyp_env.GYP_DEFINES['lsan'] = 1 | 337 c.gyp_env.GYP_DEFINES['lsan'] = 1 |
338 | 338 |
339 @config_ctx() | 339 @config_ctx() |
340 def no_lsan(c): | 340 def no_lsan(c): |
341 c.gyp_env.GYP_DEFINES['lsan'] = 0 | 341 c.gyp_env.GYP_DEFINES['lsan'] = 0 |
342 | 342 |
| 343 @config_ctx(deps=['compiler']) |
| 344 def msan(c): |
| 345 if 'clang' not in c.compile_py.compiler: # pragma: no cover |
| 346 raise BadConf('msan requires clang') |
| 347 c.gyp_env.GYP_DEFINES['msan'] = 1 |
| 348 |
| 349 @config_ctx() |
| 350 def instrumented_libraries(c): |
| 351 c.gyp_env.GYP_DEFINES['use_instrumented_libraries'] = 1 |
| 352 c.gyp_env.GYP_DEFINES['instrumented_libraries_jobs'] = 10 |
| 353 |
343 @config_ctx(group='memory_tool') | 354 @config_ctx(group='memory_tool') |
344 def memcheck(c): | 355 def memcheck(c): |
345 _memory_tool(c, 'memcheck') | 356 _memory_tool(c, 'memcheck') |
346 c.gyp_env.GYP_DEFINES['build_for_tool'] = 'memcheck' | 357 c.gyp_env.GYP_DEFINES['build_for_tool'] = 'memcheck' |
347 | 358 |
348 @config_ctx(deps=['compiler'], group='memory_tool') | 359 @config_ctx(deps=['compiler'], group='memory_tool') |
349 def tsan2(c): | 360 def tsan2(c): |
350 if 'clang' not in c.compile_py.compiler: # pragma: no cover | 361 if 'clang' not in c.compile_py.compiler: # pragma: no cover |
351 raise BadConf('tsan2 requires clang') | 362 raise BadConf('tsan2 requires clang') |
352 gyp_defs = c.gyp_env.GYP_DEFINES | 363 gyp_defs = c.gyp_env.GYP_DEFINES |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
398 | 409 |
399 @config_ctx(includes=['ninja', 'default_compiler', 'goma']) | 410 @config_ctx(includes=['ninja', 'default_compiler', 'goma']) |
400 def chromium(c): | 411 def chromium(c): |
401 c.compile_py.default_targets = ['All', 'chromium_builder_tests'] | 412 c.compile_py.default_targets = ['All', 'chromium_builder_tests'] |
402 | 413 |
403 @config_ctx(includes=['ninja', 'clang', 'goma', 'asan']) | 414 @config_ctx(includes=['ninja', 'clang', 'goma', 'asan']) |
404 def chromium_asan(c): | 415 def chromium_asan(c): |
405 c.runtests.test_args.append('--test-launcher-batch-limit=1') | 416 c.runtests.test_args.append('--test-launcher-batch-limit=1') |
406 c.runtests.test_args.append('--test-launcher-print-test-stdio=always') | 417 c.runtests.test_args.append('--test-launcher-print-test-stdio=always') |
407 | 418 |
| 419 @config_ctx(includes=['ninja', 'clang', 'goma', 'msan']) |
| 420 def chromium_msan(c): |
| 421 c.compile_py.default_targets = ['All', 'chromium_builder_tests'] |
| 422 |
408 @config_ctx(includes=['ninja', 'clang', 'goma', 'syzyasan']) | 423 @config_ctx(includes=['ninja', 'clang', 'goma', 'syzyasan']) |
409 def chromium_syzyasan(c): | 424 def chromium_syzyasan(c): |
410 c.compile_py.default_targets = ['All', 'chromium_builder_tests'] | 425 c.compile_py.default_targets = ['All', 'chromium_builder_tests'] |
411 | 426 |
412 @config_ctx(includes=['ninja', 'clang', 'goma', 'tsan2']) | 427 @config_ctx(includes=['ninja', 'clang', 'goma', 'tsan2']) |
413 def chromium_tsan2(c): | 428 def chromium_tsan2(c): |
414 c.compile_py.default_targets = ['All', 'chromium_builder_tests'] | 429 c.compile_py.default_targets = ['All', 'chromium_builder_tests'] |
415 | 430 |
416 @config_ctx(includes=['ninja', 'default_compiler', 'goma', 'chromeos']) | 431 @config_ctx(includes=['ninja', 'default_compiler', 'goma', 'chromeos']) |
417 def chromium_chromeos(c): | 432 def chromium_chromeos(c): |
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
535 c.gyp_env.GYP_DEFINES['chrome_pgo_phase'] = 2 | 550 c.gyp_env.GYP_DEFINES['chrome_pgo_phase'] = 2 |
536 | 551 |
537 @config_ctx() | 552 @config_ctx() |
538 def v8_optimize_medium(c): | 553 def v8_optimize_medium(c): |
539 c.gyp_env.GYP_DEFINES['v8_optimized_debug'] = 1 | 554 c.gyp_env.GYP_DEFINES['v8_optimized_debug'] = 1 |
540 | 555 |
541 @config_ctx() | 556 @config_ctx() |
542 def chromium_perf(c): | 557 def chromium_perf(c): |
543 c.compile_py.clobber = False | 558 c.compile_py.clobber = False |
544 | 559 |
OLD | NEW |