| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 | 2 |
| 3 usage = ''' | 3 usage = ''' |
| 4 Write extra flags to outfile for DM based on the bot name: | 4 Write extra flags to outfile for DM based on the bot name: |
| 5 $ python dm_flags.py outfile Test-Mac10.9-MacMini6.2-HD4000-x86_64-Release | 5 $ python dm_flags.py outfile Test-Mac10.9-MacMini6.2-HD4000-x86_64-Release |
| 6 Or run self-tests: | 6 Or run self-tests: |
| 7 $ python dm_flags.py test | 7 $ python dm_flags.py test |
| 8 ''' | 8 ''' |
| 9 | 9 |
| 10 import inspect | 10 import inspect |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 if 'Valgrind' in bot: # skia:3021 | 78 if 'Valgrind' in bot: # skia:3021 |
| 79 match.append('~Threaded') | 79 match.append('~Threaded') |
| 80 if 'Xoom' in bot: # skia:1699 | 80 if 'Xoom' in bot: # skia:1699 |
| 81 match.append('~WritePixels') | 81 match.append('~WritePixels') |
| 82 | 82 |
| 83 # skia:3249: these images flakily don't decode on Android. | 83 # skia:3249: these images flakily don't decode on Android. |
| 84 if 'Android' in bot: | 84 if 'Android' in bot: |
| 85 match.append('~tabl_mozilla_0') | 85 match.append('~tabl_mozilla_0') |
| 86 match.append('~desk_yahoonews_0') | 86 match.append('~desk_yahoonews_0') |
| 87 | 87 |
| 88 if 'NexusPlayer' in bot: |
| 89 match.append('~ResourceCache') |
| 90 |
| 88 if match: | 91 if match: |
| 89 args.append('--match') | 92 args.append('--match') |
| 90 args.extend(match) | 93 args.extend(match) |
| 91 | 94 |
| 92 # Though their GPUs are interesting, these don't test anything on | 95 # Though their GPUs are interesting, these don't test anything on |
| 93 # the CPU that other ARMv7+NEON bots don't test faster (N5). | 96 # the CPU that other ARMv7+NEON bots don't test faster (N5). |
| 94 if ('Nexus10' in bot or | 97 if ('Nexus10' in bot or |
| 95 'Nexus7' in bot or | 98 'Nexus7' in bot or |
| 96 'GalaxyS3' in bot or | 99 'GalaxyS3' in bot or |
| 97 'GalaxyS4' in bot): | 100 'GalaxyS4' in bot): |
| 98 args.append('--nocpu') | 101 args.append('--nocpu') |
| 99 return args | 102 return args |
| 100 cov_end = lineno() # Don't care about code coverage past here. | 103 cov_end = lineno() # Don't care about code coverage past here. |
| 101 | 104 |
| 102 | 105 |
| 103 def self_test(): | 106 def self_test(): |
| 104 import coverage # This way the bots don't need coverage.py to be installed. | 107 import coverage # This way the bots don't need coverage.py to be installed. |
| 105 args = {} | 108 args = {} |
| 106 cases = [ | 109 cases = [ |
| 107 'Test-Android-Nexus7-Tegra3-Arm7-Release', | 110 'Test-Android-Nexus7-Tegra3-Arm7-Release', |
| 111 'Test-Android-NexusPlayer-PowerVR-x86-Release', |
| 108 'Test-Android-Xoom-Tegra2-Arm7-Release', | 112 'Test-Android-Xoom-Tegra2-Arm7-Release', |
| 109 'Test-ChromeOS-Alex-GMA3150-x86-Debug', | 113 'Test-ChromeOS-Alex-GMA3150-x86-Debug', |
| 114 'Test-Ubuntu12-ShuttleA-GTX550Ti-x86_64-Release-Valgrind_GPU', |
| 110 'Test-Ubuntu14-GCE-NoGPU-x86_64-Release-Valgrind_CPU', | 115 'Test-Ubuntu14-GCE-NoGPU-x86_64-Release-Valgrind_CPU', |
| 111 'Test-Ubuntu12-ShuttleA-GTX550Ti-x86_64-Release-Valgrind_GPU', | |
| 112 'Test-Win7-ShuttleA-HD2000-x86-Debug-ANGLE', | 116 'Test-Win7-ShuttleA-HD2000-x86-Debug-ANGLE', |
| 113 ] | 117 ] |
| 114 | 118 |
| 115 cov = coverage.coverage() | 119 cov = coverage.coverage() |
| 116 cov.start() | 120 cov.start() |
| 117 for case in cases: | 121 for case in cases: |
| 118 args[case] = get_args(case) | 122 args[case] = get_args(case) |
| 119 cov.stop() | 123 cov.stop() |
| 120 | 124 |
| 121 this_file = os.path.basename(__file__) | 125 this_file = os.path.basename(__file__) |
| (...skipping 12 matching lines...) Expand all Loading... |
| 134 if len(sys.argv) == 2 and sys.argv[1] == 'test': | 138 if len(sys.argv) == 2 and sys.argv[1] == 'test': |
| 135 self_test() | 139 self_test() |
| 136 sys.exit(0) | 140 sys.exit(0) |
| 137 | 141 |
| 138 if len(sys.argv) != 3: | 142 if len(sys.argv) != 3: |
| 139 print usage | 143 print usage |
| 140 sys.exit(1) | 144 sys.exit(1) |
| 141 | 145 |
| 142 with open(sys.argv[1], 'w') as out: | 146 with open(sys.argv[1], 'w') as out: |
| 143 json.dump(get_args(sys.argv[2]), out) | 147 json.dump(get_args(sys.argv[2]), out) |
| OLD | NEW |