[tools] Default to stdin for processing in eval_gc_time.sh

NOTRY=true
BUG=

Review URL: https://codereview.chromium.org/1817063002

Cr-Commit-Position: refs/heads/master@{#34949}
This commit is contained in:
mlippautz 2016-03-21 08:07:58 -07:00 committed by Commit bot
parent 6703cce1b7
commit 731ebc0e99

View File

@ -7,11 +7,16 @@
# Convenience Script used to rank GC NVP output.
print_usage_and_die() {
echo "Usage: $0 new-gen-rank|old-gen-rank max|avg logfile"
echo "Usage: $0 RANK SORT [LOGFILE]"
echo ""
echo "Arguments:"
echo " RANK: old-gen-rank | new-gen-rank"
echo " SORT: max | avg"
echo " LOGFILE: the file to process. will default to /dev/stdin"
exit 1
}
if [ $# -ne 3 ]; then
if [[ $# -lt 2 || $# -gt 3 ]]; then
print_usage_and_die
fi
@ -31,7 +36,11 @@ case $2 in
print_usage_and_die
esac
LOGFILE=$3
if [ $# -eq 3 ]; then
LOGFILE=$3
else
LOGFILE=/dev/stdin
fi
GENERAL_INTERESTING_KEYS="\
pause \
@ -95,7 +104,7 @@ case $OP in
${INTERESTING_NEW_GEN_KEYS}
;;
old-gen-rank)
cat $LOGFILE | grep "gc=ms" | grep "reduce_memory=0" | grep -v "steps=0" \
cat $LOGFILE | grep "gc=ms" \
| $BASE_DIR/eval_gc_nvp.py \
--no-histogram \
--rank $RANK_MODE \