| OLD | NEW |
| 1 # Copyright 2017 The Chromium Authors. All rights reserved. | 1 # Copyright 2017 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 NDK_HOME ?= $(HOME)/tools/android-ndk-r13b | 5 NDK_HOME ?= $(HOME)/tools/android-ndk-r13b |
| 6 | 6 |
| 7 all: build | 7 all: build |
| 8 | 8 |
| 9 build: | 9 build: |
| 10 $(NDK_HOME)/ndk-build | 10 $(NDK_HOME)/ndk-build |
| 11 | 11 |
| 12 install: build | 12 install: build |
| 13 adb push libs/armeabi-v7a/atrace_helper /data/local/tmp/atrace_helper | 13 adb push libs/armeabi-v7a/atrace_helper /data/local/tmp/atrace_helper |
| 14 | 14 |
| 15 test: install | 15 test: install |
| 16 adb shell /data/local/tmp/atrace_helper -c 1 | 16 adb shell /data/local/tmp/atrace_helper -c 1 |
| 17 | 17 |
| 18 testf: install | 18 testf: install |
| 19 » adb shell /data/local/tmp/atrace_helper -c 1 -m -g -o /data/local/tmp/du
mp.json | 19 » adb shell /data/local/tmp/atrace_helper -c 1 -m system_server -g -s -o /
data/local/tmp/dump.json |
| 20 adb pull /data/local/tmp/dump.json /tmp/dump.json | 20 adb pull /data/local/tmp/dump.json /tmp/dump.json |
| 21 python -c 'import json; json.load(open("/tmp/dump.json"))' | 21 python -c 'import json; json.load(open("/tmp/dump.json"))' |
| 22 | 22 |
| 23 benchmark: install | 23 benchmark: install |
| 24 adb shell "time /data/local/tmp/atrace_helper -c 1 -m -o /dev/null" | 24 adb shell "time /data/local/tmp/atrace_helper -c 1 -m -o /dev/null" |
| OLD | NEW |