[llvm] r344903 - Document bisect-skip-count

David Greene via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 22 07:04:14 PDT 2018


Author: greened
Date: Mon Oct 22 07:04:13 2018
New Revision: 344903

URL: http://llvm.org/viewvc/llvm-project?rev=344903&view=rev
Log:
Document bisect-skip-count

Provide an example of how to use bisect-skip count to find bugs.

Differential revision: https://reviews.llvm.org/D52314


Modified:
    llvm/trunk/utils/bisect-skip-count

Modified: llvm/trunk/utils/bisect-skip-count
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/utils/bisect-skip-count?rev=344903&r1=344902&r2=344903&view=diff
==============================================================================
--- llvm/trunk/utils/bisect-skip-count (original)
+++ llvm/trunk/utils/bisect-skip-count Mon Oct 22 07:04:13 2018
@@ -1,6 +1,25 @@
 #!/usr/bin/env python
 # This script is used to bisect skip and count arguments for --debug-counter.
 # It is similar to bisect, except it understands how to increase skip and decrease count
+#
+# Typical usage:
+#
+# bisect-skip-count bisect-command.sh "%(skip)d" "%(count)d" 2>&1 | tee bisect.out
+#
+# bisect-command.sh is something like this:
+# #! /bin/bash
+#
+# skip=$1
+# count=$2
+#
+# opt -debug-counter=my-counter-skip=${skip},my-counter-count=${count}
+# ... Test output of opt and exit zero for pass, non-zero for fail
+#
+# Examine bisect.out to look for "Last good skip" and "Last good
+# count" to find the values of the counter that produce a passing
+# result.  Incrementing the last good count by one or decrementing the
+# last good skip by one should produce a failure.
+#
 import os
 import sys
 import argparse




More information about the llvm-commits mailing list