diff options
author | Ben Cheng <bccheng@android.com> | 2011-01-27 11:59:19 -0800 |
---|---|---|
committer | Ben Cheng <bccheng@android.com> | 2011-01-27 16:52:00 -0800 |
commit | 85fb8ea16262c7c2cc1348fa0e86d92fadf3fef9 (patch) | |
tree | f94dba52c6170af9b7dc255f20573990bd136733 /tests | |
parent | 85717094f78ffb0069af22b6c13ade9cf3445ed1 (diff) | |
download | android_dalvik-85fb8ea16262c7c2cc1348fa0e86d92fadf3fef9.tar.gz android_dalvik-85fb8ea16262c7c2cc1348fa0e86d92fadf3fef9.tar.bz2 android_dalvik-85fb8ea16262c7c2cc1348fa0e86d92fadf3fef9.zip |
Expand the "--dev" mode to cover VM development.
When specified, print the VM invocation command line too.
Also made minor cleanup on the class path to simply the invocation command.
Change-Id: I7af0a2c1df15c0e435d2e5c0b2aa0713455db0de
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/etc/push-and-run-test-jar | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/tests/etc/push-and-run-test-jar b/tests/etc/push-and-run-test-jar index df66a8eed..e2fde428e 100755 --- a/tests/etc/push-and-run-test-jar +++ b/tests/etc/push-and-run-test-jar @@ -10,7 +10,7 @@ # --portable -- use the portable interpreter # --debug -- wait for debugger to attach # --zygote -- use the zygote (if so, all other options are ignored) -# --dev -- development mode +# --dev -- development mode (print the vm invocation cmdline) # --no-verify -- turn off verification (on by default) # --no-optimize -- turn off optimization (on by default) # --no-precise -- turn off precise GC (on by default) @@ -28,6 +28,7 @@ OPTIMIZE="y" ZYGOTE="n" QUIET="n" PRECISE="y" +DEV_MODE="n" while true; do if [ "x$1" = "x--quiet" ]; then @@ -53,7 +54,7 @@ while true; do msg "Spawning from zygote" shift elif [ "x$1" = "x--dev" ]; then - # not used; ignore + DEV_MODE="y" shift elif [ "x$1" = "x--no-verify" ]; then VERIFY="n" @@ -125,6 +126,10 @@ fi if [ "$ZYGOTE" = "y" ]; then adb shell cd /data \; dvz -classpath test.jar Main "$@" else - adb shell cd /data \; dalvikvm $DEX_VERIFY $DEX_OPTIMIZE $DEX_DEBUG \ - $GC_OPTS -cp test.jar "-Xint:${INTERP}" -ea Main "$@" + cmdline="cd /data; dalvikvm $DEX_VERIFY $DEX_OPTIMIZE $DEX_DEBUG \ + $GC_OPTS -cp test.jar -Xint:${INTERP} -ea Main" + if [ "$DEV_MODE" = "y" ]; then + echo $cmdline "$@" + fi + adb shell $cmdline "$@" fi |