#!/bin/bash set -ex cd $(dirname $0)/../../.. BINS="sync_unary_ping_pong_test sync_streaming_ping_pong_test" CPUS=`python -c 'import multiprocessing; print multiprocessing.cpu_count()'` make CONFIG=basicprof -j$CPUS $BINS mkdir -p reports # try to use pypy for generating reports # each trace dumps 7-8gig of text to disk, and processing this into a report is # heavyweight - so any speed boost is worthwhile # TODO(ctiller): consider rewriting report generation in C++ for performance if which pypy >/dev/null; then PYTHON=pypy else PYTHON=python2.7 fi # start processes, interleaving report index generation echo '
' > reports/index.html for bin in $BINS do bins/basicprof/$bin mv latency_trace.txt $bin.trace echo "$bin