No description
- OCaml 89.9%
- Dune 10.1%
| bin | ||
| lib | ||
| test | ||
| .gitignore | ||
| .ocamlformat | ||
| bisect.opam | ||
| dune-project | ||
| LICENSE | ||
| readme.md | ||
bisect
A program for bisection of integer ranges
Description
bisect is a program for bisecting integer ranges. It takes a known good index
and a bad index and finds the first bad index, e.g. the commit that introduced a
bug or the optimization pass which causes a miscompile. Both positive (good <
bad) and negative (bad < good) ranges are supported.
bisect either works with a command to distinguish good or bad outcomes, or in
interactive mode.
Examples
A simple example, script.sh returns 0 on good outcomes and non-0 on bad ones.
bisect 0 10 bash script.sh {}
Use -- for negative values, otherwise the positional argument is interpreted
as an option.
bisect -- 123 -10 check.sh {}
git bisect (but I haven't had a chance to test this for real)
bisect 5 0 -- sh -c 'git checkout main~{} && dune test'
If the command is omitted, bisect in interactive mode
bisect 0 10