1 [ 2 { 3 "cmd": [ 4 "python", 5 "-u", 6 "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", 7 "--json-output", 8 "/path/to/tmp/json", 9 "ensure-directory", 10 "--mode", 11 "0777", 12 "[START_DIR]/tmp" 13 ], 14 "infra_step": true, 15 "name": "makedirs tmp_dir" 16 }, 17 { 18 "cmd": [ 19 "/usr/bin/adb.1.0.35", 20 "shell", 21 "mkdir", 22 "-p", 23 "/sdcard/revenge_of_the_skiabot/resources" 24 ], 25 "cwd": "[START_DIR]/skia", 26 "env": { 27 "BUILDTYPE": "Release", 28 "CHROME_HEADLESS": "1", 29 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 30 "SKIA_OUT": "[START_DIR]/out" 31 }, 32 "infra_step": true, 33 "name": "mkdir /sdcard/revenge_of_the_skiabot/resources" 34 }, 35 { 36 "cmd": [ 37 "python", 38 "-u", 39 "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", 40 "--json-output", 41 "/path/to/tmp/json", 42 "copy", 43 "[START_DIR]/skia/infra/bots/assets/skp/VERSION", 44 "/path/to/tmp/" 45 ], 46 "infra_step": true, 47 "name": "Get downloaded SKP VERSION" 48 }, 49 { 50 "cmd": [ 51 "python", 52 "-u", 53 "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", 54 "--json-output", 55 "/path/to/tmp/json", 56 "copy", 57 "42", 58 "[START_DIR]/tmp/SKP_VERSION" 59 ], 60 "infra_step": true, 61 "name": "write SKP_VERSION" 62 }, 63 { 64 "cmd": [ 65 "/usr/bin/adb.1.0.35", 66 "shell", 67 "cat", 68 "/sdcard/revenge_of_the_skiabot/SKP_VERSION" 69 ], 70 "cwd": "[START_DIR]/skia", 71 "env": { 72 "BUILDTYPE": "Release", 73 "CHROME_HEADLESS": "1", 74 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 75 "SKIA_OUT": "[START_DIR]/out" 76 }, 77 "infra_step": true, 78 "name": "read /sdcard/revenge_of_the_skiabot/SKP_VERSION", 79 "stdout": "/path/to/tmp/" 80 }, 81 { 82 "cmd": [ 83 "/usr/bin/adb.1.0.35", 84 "shell", 85 "rm", 86 "-f", 87 "/sdcard/revenge_of_the_skiabot/SKP_VERSION" 88 ], 89 "cwd": "[START_DIR]/skia", 90 "env": { 91 "BUILDTYPE": "Release", 92 "CHROME_HEADLESS": "1", 93 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 94 "SKIA_OUT": "[START_DIR]/out" 95 }, 96 "infra_step": true, 97 "name": "rm /sdcard/revenge_of_the_skiabot/SKP_VERSION" 98 }, 99 { 100 "cmd": [ 101 "/usr/bin/adb.1.0.35", 102 "shell", 103 "rm", 104 "-rf", 105 "/sdcard/revenge_of_the_skiabot/skps" 106 ], 107 "cwd": "[START_DIR]/skia", 108 "env": { 109 "BUILDTYPE": "Release", 110 "CHROME_HEADLESS": "1", 111 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 112 "SKIA_OUT": "[START_DIR]/out" 113 }, 114 "infra_step": true, 115 "name": "rm /sdcard/revenge_of_the_skiabot/skps" 116 }, 117 { 118 "cmd": [ 119 "/usr/bin/adb.1.0.35", 120 "shell", 121 "mkdir", 122 "-p", 123 "/sdcard/revenge_of_the_skiabot/skps" 124 ], 125 "cwd": "[START_DIR]/skia", 126 "env": { 127 "BUILDTYPE": "Release", 128 "CHROME_HEADLESS": "1", 129 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 130 "SKIA_OUT": "[START_DIR]/out" 131 }, 132 "infra_step": true, 133 "name": "mkdir /sdcard/revenge_of_the_skiabot/skps" 134 }, 135 { 136 "cmd": [ 137 "python", 138 "-u", 139 "\nimport os\nimport subprocess\nimport sys\nhost = sys.argv[1]\ndevice = sys.argv[2]\nfor d, _, fs in os.walk(host):\n p = os.path.relpath(d, host)\n if p != '.' and p.startswith('.'):\n continue\n for f in fs:\n print os.path.join(p,f)\n subprocess.check_call(['/usr/bin/adb.1.0.35', 'push',\n os.path.realpath(os.path.join(host, p, f)),\n os.path.join(device, p, f)])\n", 140 "[START_DIR]/skp", 141 "/sdcard/revenge_of_the_skiabot/skps" 142 ], 143 "env": { 144 "BUILDTYPE": "Release", 145 "CHROME_HEADLESS": "1", 146 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 147 "SKIA_OUT": "[START_DIR]/out" 148 }, 149 "infra_step": true, 150 "name": "push [START_DIR]/skp/* /sdcard/revenge_of_the_skiabot/skps", 151 "~followup_annotations": [ 152 "@@@STEP_LOG_LINE (a] python.inline@@@@", 153 "@@@STEP_LOG_LINE (a] python.inline@import os@@@", 154 "@@@STEP_LOG_LINE (a] python.inline@import subprocess@@@", 155 "@@@STEP_LOG_LINE (a] python.inline@import sys@@@", 156 "@@@STEP_LOG_LINE (a] python.inline@host = sys.argv[1]@@@", 157 "@@@STEP_LOG_LINE (a] python.inline@device = sys.argv[2]@@@", 158 "@@@STEP_LOG_LINE (a] python.inline@for d, _, fs in os.walk(host):@@@", 159 "@@@STEP_LOG_LINE (a] python.inline@ p = os.path.relpath(d, host)@@@", 160 "@@@STEP_LOG_LINE (a] python.inline@ if p != '.' and p.startswith('.'):@@@", 161 "@@@STEP_LOG_LINE (a] python.inline@ continue@@@", 162 "@@@STEP_LOG_LINE (a] python.inline@ for f in fs:@@@", 163 "@@@STEP_LOG_LINE (a] python.inline@ print os.path.join(p,f)@@@", 164 "@@@STEP_LOG_LINE (a] python.inline@ subprocess.check_call(['/usr/bin/adb.1.0.35', 'push',@@@", 165 "@@@STEP_LOG_LINE (a] python.inline@ os.path.realpath(os.path.join(host, p, f)),@@@", 166 "@@@STEP_LOG_LINE (a] python.inline@ os.path.join(device, p, f)])@@@", 167 "@@@STEP_LOG_END (a] python.inline@@@" 168 ] 169 }, 170 { 171 "cmd": [ 172 "/usr/bin/adb.1.0.35", 173 "push", 174 "[START_DIR]/tmp/SKP_VERSION", 175 "/sdcard/revenge_of_the_skiabot/SKP_VERSION" 176 ], 177 "cwd": "[START_DIR]/skia", 178 "env": { 179 "BUILDTYPE": "Release", 180 "CHROME_HEADLESS": "1", 181 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 182 "SKIA_OUT": "[START_DIR]/out" 183 }, 184 "infra_step": true, 185 "name": "push [START_DIR]/tmp/SKP_VERSION /sdcard/revenge_of_the_skiabot/SKP_VERSION" 186 }, 187 { 188 "cmd": [ 189 "adb.1.0.35", 190 "push", 191 "[START_DIR]/out/Release/skpbench", 192 "/data/local/tmp/" 193 ], 194 "cwd": "[START_DIR]/skia", 195 "env": { 196 "BUILDTYPE": "Release", 197 "CHROME_HEADLESS": "1", 198 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 199 "SKIA_OUT": "[START_DIR]/out" 200 }, 201 "infra_step": true, 202 "name": "push skpbench" 203 }, 204 { 205 "cmd": [ 206 "python", 207 "-u", 208 "[START_DIR]/skia/tools/skpbench/skpbench.py", 209 "/data/local/tmp/skpbench", 210 "--adb", 211 "--adb_binary", 212 "adb.1.0.35", 213 "--resultsfile", 214 "[CUSTOM_[SWARM_OUT_DIR]]/table", 215 "--config", 216 "vk", 217 "-v5", 218 "/sdcard/revenge_of_the_skiabot/skps" 219 ], 220 "env": { 221 "BUILDTYPE": "Release", 222 "CHROME_HEADLESS": "1", 223 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 224 "SKIA_OUT": "[START_DIR]/out" 225 }, 226 "name": "skpbench" 227 }, 228 { 229 "cmd": [ 230 "python", 231 "-u", 232 "import os\nprint os.environ.get('SWARMING_BOT_ID', '')\n" 233 ], 234 "name": "get swarming bot id", 235 "stdout": "/path/to/tmp/", 236 "~followup_annotations": [ 237 "@@@STEP_LOG_LINE (a] python.inline@import os@@@", 238 "@@@STEP_LOG_LINE (a] python.inline@print os.environ.get('SWARMING_BOT_ID', '')@@@", 239 "@@@STEP_LOG_END (a] python.inline@@@" 240 ] 241 }, 242 { 243 "cmd": [ 244 "python", 245 "-u", 246 "import os\nprint os.environ.get('SWARMING_TASK_ID', '')\n" 247 ], 248 "name": "get swarming task id", 249 "stdout": "/path/to/tmp/", 250 "~followup_annotations": [ 251 "@@@STEP_LOG_LINE (a] python.inline@import os@@@", 252 "@@@STEP_LOG_LINE (a] python.inline@print os.environ.get('SWARMING_TASK_ID', '')@@@", 253 "@@@STEP_LOG_END (a] python.inline@@@" 254 ] 255 }, 256 { 257 "cmd": [ 258 "python", 259 "-u", 260 "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", 261 "--json-output", 262 "/path/to/tmp/json", 263 "ensure-directory", 264 "--mode", 265 "0777", 266 "[CUSTOM_[SWARM_OUT_DIR]]/perfdata/Perf-Android-Clang-PixelC-GPU-TegraX1-arm64-Release-All-Android_Vulkan_Skpbench/data" 267 ], 268 "infra_step": true, 269 "name": "makedirs perf_dir" 270 }, 271 { 272 "cmd": [ 273 "python", 274 "-u", 275 "[START_DIR]/skia/tools/skpbench/skiaperf.py", 276 "[CUSTOM_[SWARM_OUT_DIR]]/table", 277 "--properties", 278 "gitHash", 279 "abc123", 280 "swarming_bot_id", 281 "skia-bot-123", 282 "swarming_task_id", 283 "123456", 284 "--outfile", 285 "[CUSTOM_[SWARM_OUT_DIR]]/perfdata/Perf-Android-Clang-PixelC-GPU-TegraX1-arm64-Release-All-Android_Vulkan_Skpbench/data/skpbench_abc123_1337000001.json", 286 "--key", 287 "arch", 288 "arm64", 289 "compiler", 290 "Clang", 291 "cpu_or_gpu", 292 "GPU", 293 "cpu_or_gpu_value", 294 "TegraX1", 295 "extra_config", 296 "Android_Vulkan_Skpbench", 297 "model", 298 "PixelC", 299 "os", 300 "Android", 301 "test_filter", 302 "All" 303 ], 304 "env": { 305 "BUILDTYPE": "Release", 306 "CHROME_HEADLESS": "1", 307 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 308 "SKIA_OUT": "[START_DIR]/out" 309 }, 310 "name": "Parse skpbench output into Perf json" 311 }, 312 { 313 "cmd": [ 314 "python", 315 "-u", 316 "\nimport os\nimport subprocess\nimport sys\nout = sys.argv[1]\nlog = subprocess.check_output(['/usr/bin/adb.1.0.35', 'logcat', '-d'])\nfor line in log.split('\\n'):\n tokens = line.split()\n if len(tokens) == 11 and tokens[-7] == 'F' and tokens[-3] == 'pc':\n addr, path = tokens[-2:]\n local = os.path.join(out, os.path.basename(path))\n if os.path.exists(local):\n sym = subprocess.check_output(['addr2line', '-Cfpe', local, addr])\n line = line.replace(addr, addr + ' ' + sym.strip())\n print line\n", 317 "[START_DIR]/out/Release" 318 ], 319 "env": { 320 "BUILDTYPE": "Release", 321 "CHROME_HEADLESS": "1", 322 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 323 "SKIA_OUT": "[START_DIR]/out" 324 }, 325 "infra_step": true, 326 "name": "dump log", 327 "timeout": 300, 328 "~followup_annotations": [ 329 "@@@STEP_LOG_LINE (a] python.inline@@@@", 330 "@@@STEP_LOG_LINE (a] python.inline@import os@@@", 331 "@@@STEP_LOG_LINE (a] python.inline@import subprocess@@@", 332 "@@@STEP_LOG_LINE (a] python.inline@import sys@@@", 333 "@@@STEP_LOG_LINE (a] python.inline@out = sys.argv[1]@@@", 334 "@@@STEP_LOG_LINE (a] python.inline@log = subprocess.check_output(['/usr/bin/adb.1.0.35', 'logcat', '-d'])@@@", 335 "@@@STEP_LOG_LINE (a] python.inline@for line in log.split('\\n'):@@@", 336 "@@@STEP_LOG_LINE (a] python.inline@ tokens = line.split()@@@", 337 "@@@STEP_LOG_LINE (a] python.inline@ if len(tokens) == 11 and tokens[-7] == 'F' and tokens[-3] == 'pc':@@@", 338 "@@@STEP_LOG_LINE (a] python.inline@ addr, path = tokens[-2:]@@@", 339 "@@@STEP_LOG_LINE (a] python.inline@ local = os.path.join(out, os.path.basename(path))@@@", 340 "@@@STEP_LOG_LINE (a] python.inline@ if os.path.exists(local):@@@", 341 "@@@STEP_LOG_LINE (a] python.inline@ sym = subprocess.check_output(['addr2line', '-Cfpe', local, addr])@@@", 342 "@@@STEP_LOG_LINE (a] python.inline@ line = line.replace(addr, addr + ' ' + sym.strip())@@@", 343 "@@@STEP_LOG_LINE (a] python.inline@ print line@@@", 344 "@@@STEP_LOG_END (a] python.inline@@@" 345 ] 346 }, 347 { 348 "cmd": [ 349 "/usr/bin/adb.1.0.35", 350 "kill-server" 351 ], 352 "cwd": "[START_DIR]/skia", 353 "env": { 354 "BUILDTYPE": "Release", 355 "CHROME_HEADLESS": "1", 356 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 357 "SKIA_OUT": "[START_DIR]/out" 358 }, 359 "infra_step": true, 360 "name": "kill adb server" 361 }, 362 { 363 "name": "$result", 364 "recipe_result": null, 365 "status_code": 0 366 } 367 ]