Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(81)

Unified Diff: experimental/tools/multipage_pdf_profiler.sh

Issue 769083003: multipage_pdf_profiler, gmtoskp (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « experimental/tools/multipage_pdf_profiler.cpp ('k') | gyp/experimental.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: experimental/tools/multipage_pdf_profiler.sh
diff --git a/experimental/tools/multipage_pdf_profiler.sh b/experimental/tools/multipage_pdf_profiler.sh
new file mode 100755
index 0000000000000000000000000000000000000000..d2cbdc5a3d096c002a39ec19af8071ab4ad7a3fc
--- /dev/null
+++ b/experimental/tools/multipage_pdf_profiler.sh
@@ -0,0 +1,18 @@
+#!/bin/sh
+
+if [ -z "$1" ] || [ -z "$2" ]; then
+ echo "usage: $0 SKP_DIRECTORY MULTIPAGE_PDF_PROFILER_EXE" >&2
+ exit 1
+fi
+
+SKP_DIRECTORY="$1"
+MULTIPAGE_PDF_PROFILER_EXE="$2"
+
+printf '"FILE","SKP SIZE (BYTES)","MEMORY USE (MB)"\n' >&2
+for skp in "$SKP_DIRECTORY"/*.skp; do
djsollen 2014/12/01 19:44:49 why not do this directory traversal in the C binar
+ r=$("$MULTIPAGE_PDF_PROFILER_EXE" 0 "$skp")
+ skp_size=$(echo $r | awk '{ print $1 }')
+ mem0=$(echo $r | awk '{ print $2 }')
+ mem1=$("$MULTIPAGE_PDF_PROFILER_EXE" 1 "$skp" | awk '{ print $2 }')
+ printf '"%s",%d,%d\n' $(basename "$skp") $skp_size $(($mem1 - $mem0))
+done
« no previous file with comments | « experimental/tools/multipage_pdf_profiler.cpp ('k') | gyp/experimental.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698