Skip to content

Instantly share code, notes, and snippets.

@dcci
Created October 10, 2016 03:21
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save dcci/8bba38a2dd9e935db68a22c063c9dab6 to your computer and use it in GitHub Desktop.
Save dcci/8bba38a2dd9e935db68a22c063c9dab6 to your computer and use it in GitHub Desktop.
Delta:
$ cat check-2.sh
#!/bin/bash
ulimit -t 3; ~/work/llvm/build-release/bin/opt -S $1 | ~/work/llvm/build-release/bin/lli
if ! test "$?" = "0"; then
exit 1
fi
ulimit -t 3; ~/work/llvm/build-release/bin/opt -sccp -S $1 | ~/work/llvm/build-release/bin/lli
if test "$?" = "0"; then
exit 1
fi
exit 0
Bugpoint:
~/work/llvm/build-release/bin/bugpoint -compile-custom -compile-command=./check-bugpoint.sh -opt-command=/home/davide/work/llvm/build-release/bin/opt 2844.c
$ cat check-bugpoint.sh
#!/bin/bash
ulimit -t 3; ~/work/llvm/build-release/bin/opt -S $1 | ~/work/llvm/build-release/bin/lli
res_old=$?
ulimit -t 3; ~/work/llvm/build-release/bin/opt -sccp -S $1 | ~/work/llvm/build-release/bin/lli
res_new=$?
[[ $res_old == 0 && $res_new != 0 ]] && exit 1
exit 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment