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 "gles", 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_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 "issue", 281 "456789", 282 "patchset", 283 "12", 284 "patch_storage", 285 "gerrit", 286 "swarming_bot_id", 287 "skia-bot-123", 288 "swarming_task_id", 289 "123456", 290 "--outfile", 291 "[CUSTOM_[SWARM_OUT_DIR]]/perfdata/Perf-Android-Clang-PixelC-GPU-TegraX1-arm64-Release-All-Android_Skpbench/data/skpbench_abc123_1337000001.json", 292 "--key", 293 "arch", 294 "arm64", 295 "compiler", 296 "Clang", 297 "cpu_or_gpu", 298 "GPU", 299 "cpu_or_gpu_value", 300 "TegraX1", 301 "extra_config", 302 "Android_Skpbench", 303 "model", 304 "PixelC", 305 "os", 306 "Android", 307 "test_filter", 308 "All" 309 ], 310 "env": { 311 "BUILDTYPE": "Release", 312 "CHROME_HEADLESS": "1", 313 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 314 "SKIA_OUT": "[START_DIR]/out" 315 }, 316 "name": "Parse skpbench output into Perf json" 317 }, 318 { 319 "cmd": [ 320 "python", 321 "-u", 322 "\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", 323 "[START_DIR]/out/Release" 324 ], 325 "env": { 326 "BUILDTYPE": "Release", 327 "CHROME_HEADLESS": "1", 328 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 329 "SKIA_OUT": "[START_DIR]/out" 330 }, 331 "infra_step": true, 332 "name": "dump log", 333 "timeout": 300, 334 "~followup_annotations": [ 335 "@@@STEP_LOG_LINE (a] python.inline@@@@", 336 "@@@STEP_LOG_LINE (a] python.inline@import os@@@", 337 "@@@STEP_LOG_LINE (a] python.inline@import subprocess@@@", 338 "@@@STEP_LOG_LINE (a] python.inline@import sys@@@", 339 "@@@STEP_LOG_LINE (a] python.inline@out = sys.argv[1]@@@", 340 "@@@STEP_LOG_LINE (a] python.inline@log = subprocess.check_output(['/usr/bin/adb.1.0.35', 'logcat', '-d'])@@@", 341 "@@@STEP_LOG_LINE (a] python.inline@for line in log.split('\\n'):@@@", 342 "@@@STEP_LOG_LINE (a] python.inline@ tokens = line.split()@@@", 343 "@@@STEP_LOG_LINE (a] python.inline@ if len(tokens) == 11 and tokens[-7] == 'F' and tokens[-3] == 'pc':@@@", 344 "@@@STEP_LOG_LINE (a] python.inline@ addr, path = tokens[-2:]@@@", 345 "@@@STEP_LOG_LINE (a] python.inline@ local = os.path.join(out, os.path.basename(path))@@@", 346 "@@@STEP_LOG_LINE (a] python.inline@ if os.path.exists(local):@@@", 347 "@@@STEP_LOG_LINE (a] python.inline@ sym = subprocess.check_output(['addr2line', '-Cfpe', local, addr])@@@", 348 "@@@STEP_LOG_LINE (a] python.inline@ line = line.replace(addr, addr + ' ' + sym.strip())@@@", 349 "@@@STEP_LOG_LINE (a] python.inline@ print line@@@", 350 "@@@STEP_LOG_END (a] python.inline@@@" 351 ] 352 }, 353 { 354 "cmd": [ 355 "/usr/bin/adb.1.0.35", 356 "kill-server" 357 ], 358 "cwd": "[START_DIR]/skia", 359 "env": { 360 "BUILDTYPE": "Release", 361 "CHROME_HEADLESS": "1", 362 "PATH": "<PATH>:RECIPE_PACKAGE_REPO[depot_tools]", 363 "SKIA_OUT": "[START_DIR]/out" 364 }, 365 "infra_step": true, 366 "name": "kill adb server" 367 }, 368 { 369 "name": "$result", 370 "recipe_result": null, 371 "status_code": 0 372 } 373 ]