summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorAdam Scarr <adam@vektah.net>2017-08-13 19:27:41 +1000
committerAdam Scarr <adam@vektah.net>2017-08-13 19:27:41 +1000
commita4677a5834210c85e050de6dad13911a85297499 (patch)
tree0e0802a75478a10b4765fced5eb8c5ddd92183cc /scripts
parent5716ddb5e7ca3cb4ee445bdd4958c37aeb033baa (diff)
Clean up autows
Diffstat (limited to 'scripts')
-rw-r--r--scripts/cpuprofile.sh7
-rw-r--r--scripts/memprofile.sh7
2 files changed, 14 insertions, 0 deletions
diff --git a/scripts/cpuprofile.sh b/scripts/cpuprofile.sh
new file mode 100644
index 0000000..2f6f18b
--- /dev/null
+++ b/scripts/cpuprofile.sh
@@ -0,0 +1,7 @@
+#!/bin/bash
+
+set -eu
+
+go build ./json/profile/json.go
+./json.exe -cpuprofile cpu.out
+go tool pprof json.exe cpu.out
diff --git a/scripts/memprofile.sh b/scripts/memprofile.sh
new file mode 100644
index 0000000..0fdc5ec
--- /dev/null
+++ b/scripts/memprofile.sh
@@ -0,0 +1,7 @@
+#!/bin/bash
+
+set -eu
+
+go build ./json/profile/json.go
+./json.exe -memprofile mem.out
+go tool pprof json.exe mem.out