OLD | NEW |
1 # | 1 # |
2 # Copyright 2015 Google Inc. | 2 # Copyright 2015 Google Inc. |
3 # | 3 # |
4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
6 # | 6 # |
7 | 7 |
8 #!/usr/bin/env python | 8 #!/usr/bin/env python |
9 | 9 |
10 usage = ''' | 10 usage = ''' |
(...skipping 13 matching lines...) Expand all Loading... |
24 caller = inspect.stack()[1] # Up one level to our caller. | 24 caller = inspect.stack()[1] # Up one level to our caller. |
25 return inspect.getframeinfo(caller[0]).lineno | 25 return inspect.getframeinfo(caller[0]).lineno |
26 | 26 |
27 | 27 |
28 cov_start = lineno()+1 # We care about coverage starting just past this def. | 28 cov_start = lineno()+1 # We care about coverage starting just past this def. |
29 def get_args(bot): | 29 def get_args(bot): |
30 args = [] | 30 args = [] |
31 | 31 |
32 args.extend(['--scales', '1.0', '1.1']) | 32 args.extend(['--scales', '1.0', '1.1']) |
33 | 33 |
| 34 if 'iOS' in bot: |
| 35 args.extend(['--skps', 'ignore_skps']) |
| 36 |
34 config = ['565', '8888', 'gpu', 'nonrendering', 'angle', 'hwui'] | 37 config = ['565', '8888', 'gpu', 'nonrendering', 'angle', 'hwui'] |
35 # The S4 crashes and the NP produces a long error stream when we run with | 38 # The S4 crashes and the NP produces a long error stream when we run with |
36 # MSAA. | 39 # MSAA. |
37 if ('GalaxyS4' not in bot and | 40 if ('GalaxyS4' not in bot and |
38 'NexusPlayer' not in bot): | 41 'NexusPlayer' not in bot): |
39 if 'Android' in bot: | 42 if 'Android' in bot: |
40 config.extend(['msaa4', 'nvprmsaa4']) | 43 config.extend(['msaa4', 'nvprmsaa4']) |
41 else: | 44 else: |
42 config.extend(['msaa16', 'nvprmsaa16']) | 45 config.extend(['msaa16', 'nvprmsaa16']) |
43 args.append('--config') | 46 args.append('--config') |
(...skipping 14 matching lines...) Expand all Loading... |
58 match.append('~blurroundrect') | 61 match.append('~blurroundrect') |
59 match.append('~patch_grid') # skia:2847 | 62 match.append('~patch_grid') # skia:2847 |
60 match.append('~desk_carsvg') | 63 match.append('~desk_carsvg') |
61 if 'HD2000' in bot: | 64 if 'HD2000' in bot: |
62 match.extend(['~gradient', '~etc1bitmap']) # skia:2895 | 65 match.extend(['~gradient', '~etc1bitmap']) # skia:2895 |
63 if 'Nexus7' in bot: | 66 if 'Nexus7' in bot: |
64 match = ['skp'] # skia:2774 | 67 match = ['skp'] # skia:2774 |
65 if 'NexusPlayer' in bot: | 68 if 'NexusPlayer' in bot: |
66 match.append('~desk_unicodetable') | 69 match.append('~desk_unicodetable') |
67 | 70 |
| 71 if 'iOS' in bot: |
| 72 match.append('~blurroundrect') |
| 73 match.append('~patch_grid') # skia:2847 |
| 74 match.append('~desk_carsvg') |
| 75 match.append('~keymobi') |
| 76 |
68 if match: | 77 if match: |
69 args.append('--match') | 78 args.append('--match') |
70 args.extend(match) | 79 args.extend(match) |
71 | 80 |
72 return args | 81 return args |
73 cov_end = lineno() # Don't care about code coverage past here. | 82 cov_end = lineno() # Don't care about code coverage past here. |
74 | 83 |
75 | 84 |
76 def self_test(): | 85 def self_test(): |
77 import coverage # This way the bots don't need coverage.py to be installed. | 86 import coverage # This way the bots don't need coverage.py to be installed. |
78 args = {} | 87 args = {} |
79 cases = [ | 88 cases = [ |
80 'Perf-Android-Nexus7-Tegra3-Arm7-Release', | 89 'Perf-Android-Nexus7-Tegra3-Arm7-Release', |
81 'Perf-Android-GCC-NexusPlayer-GPU-PowerVR-x86-Release', | 90 'Perf-Android-GCC-NexusPlayer-GPU-PowerVR-x86-Release', |
82 'Test-Ubuntu-GCC-ShuttleA-GPU-GTX550Ti-x86_64-Release-Valgrind', | 91 'Test-Ubuntu-GCC-ShuttleA-GPU-GTX550Ti-x86_64-Release-Valgrind', |
83 'Test-Win7-MSVC-ShuttleA-GPU-HD2000-x86-Debug-ANGLE', | 92 'Test-Win7-MSVC-ShuttleA-GPU-HD2000-x86-Debug-ANGLE', |
| 93 'Test-iOS-Clang-iPad4-GPU-SGX554-Arm7-Debug', |
84 ] | 94 ] |
85 | 95 |
86 cov = coverage.coverage() | 96 cov = coverage.coverage() |
87 cov.start() | 97 cov.start() |
88 for case in cases: | 98 for case in cases: |
89 args[case] = get_args(case) | 99 args[case] = get_args(case) |
90 cov.stop() | 100 cov.stop() |
91 | 101 |
92 this_file = os.path.basename(__file__) | 102 this_file = os.path.basename(__file__) |
93 _, _, not_run, _ = cov.analysis(this_file) | 103 _, _, not_run, _ = cov.analysis(this_file) |
(...skipping 11 matching lines...) Expand all Loading... |
105 if len(sys.argv) == 2 and sys.argv[1] == 'test': | 115 if len(sys.argv) == 2 and sys.argv[1] == 'test': |
106 self_test() | 116 self_test() |
107 sys.exit(0) | 117 sys.exit(0) |
108 | 118 |
109 if len(sys.argv) != 3: | 119 if len(sys.argv) != 3: |
110 print usage | 120 print usage |
111 sys.exit(1) | 121 sys.exit(1) |
112 | 122 |
113 with open(sys.argv[1], 'w') as out: | 123 with open(sys.argv[1], 'w') as out: |
114 json.dump(get_args(sys.argv[2]), out) | 124 json.dump(get_args(sys.argv[2]), out) |
OLD | NEW |