aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/bin/export-to-postgresql-report
diff options
context:
space:
mode:
authorAdrian Hunter <[email protected]>2014-10-30 16:09:47 +0200
committerArnaldo Carvalho de Melo <[email protected]>2014-11-03 18:10:06 -0300
commit6a70307ddcd9999598c399d55dc44c07816a575f (patch)
tree210143ded656ebf0ebc3f828caa0ddf7c080a599 /tools/perf/scripts/python/bin/export-to-postgresql-report
parent88f50d602f500d206f2f5a9a9751dd45f2d97739 (diff)
perf tools: Add call information to Python export
Add the ability to export detailed information about paired calls and returns to Python db export and the export-to-postgresql.py script. Signed-off-by: Adrian Hunter <[email protected]> Cc: David Ahern <[email protected]> Cc: Frederic Weisbecker <[email protected]> Cc: Jiri Olsa <[email protected]> Cc: Namhyung Kim <[email protected]> Cc: Paul Mackerras <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Stephane Eranian <[email protected]> Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/bin/export-to-postgresql-report')
-rw-r--r--tools/perf/scripts/python/bin/export-to-postgresql-report15
1 files changed, 10 insertions, 5 deletions
diff --git a/tools/perf/scripts/python/bin/export-to-postgresql-report b/tools/perf/scripts/python/bin/export-to-postgresql-report
index a8fdd15f85bf..cd335b6e2a01 100644
--- a/tools/perf/scripts/python/bin/export-to-postgresql-report
+++ b/tools/perf/scripts/python/bin/export-to-postgresql-report
@@ -1,6 +1,6 @@
#!/bin/bash
# description: export perf data to a postgresql database
-# args: [database name] [columns]
+# args: [database name] [columns] [calls]
n_args=0
for i in "$@"
do
@@ -9,11 +9,16 @@ do
fi
n_args=$(( $n_args + 1 ))
done
-if [ "$n_args" -gt 2 ] ; then
- echo "usage: export-to-postgresql-report [database name] [columns]"
+if [ "$n_args" -gt 3 ] ; then
+ echo "usage: export-to-postgresql-report [database name] [columns] [calls]"
exit
fi
-if [ "$n_args" -gt 1 ] ; then
+if [ "$n_args" -gt 2 ] ; then
+ dbname=$1
+ columns=$2
+ calls=$3
+ shift 3
+elif [ "$n_args" -gt 1 ] ; then
dbname=$1
columns=$2
shift 2
@@ -21,4 +26,4 @@ elif [ "$n_args" -gt 0 ] ; then
dbname=$1
shift
fi
-perf script $@ -s "$PERF_EXEC_PATH"/scripts/python/export-to-postgresql.py $dbname $columns
+perf script $@ -s "$PERF_EXEC_PATH"/scripts/python/export-to-postgresql.py $dbname $columns $calls