aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/sparse-llvm-dis
diff options
Diffstat (limited to 'sparse-llvm-dis')
-rwxr-xr-xsparse-llvm-dis15
1 files changed, 15 insertions, 0 deletions
diff --git a/sparse-llvm-dis b/sparse-llvm-dis
new file mode 100755
index 00000000..2bd84080
--- /dev/null
+++ b/sparse-llvm-dis
@@ -0,0 +1,15 @@
+#!/bin/sh
+#
+# For testing sparse-llvm emitted bytecode
+
+set +e
+
+DIS=$("${LLVM_CONFIG:-llvm-config}" --bindir)/llvm-dis
+
+if [ $# -eq 0 ]; then
+ echo "$(basename $0): no input files"
+ exit 1
+fi
+
+DIRNAME=$(dirname $0)
+$DIRNAME/sparse-llvm "$@" | "$DIS"