1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 19:12:56 +02:00
Commit Graph

3 Commits

Author SHA1 Message Date
Mikhail Maltsev
665a7a9f4f [utils] Fix incompatibility of bisect[-skip-count] with Python 3
Summary:
This change replaces the print statements with print function calls
and also replaces the '/' operator (which is integer division in Py2,
but becomes floating point division in Py3) with the '//' operator
which has the same semantics in Py2 and Py3.

Reviewers: greened, michaelplatings, gottesmm

Reviewed By: greened

Subscribers: llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D68138

llvm-svn: 373759
2019-10-04 16:44:18 +00:00
Jinsong Ji
1bcb6d2dd5 [Utils][NFC] Copy bisect usage documents from commit msg into script.
Copy the message into script, so that new users won't need to dig into
commit messages to figure out how to use.

The message are copied directly from Michael's commit message in
https://reviews.llvm.org/rL214610.

llvm-svn: 369054
2019-08-15 22:07:59 +00:00
Michael Gottesman
ebdb0cf646 Add a small utility called bisect that enables commandline bisecting on a counter.
This is something that I have found to be very useful in my work and I
wanted to contribute it back to the community since several people in
the past have asked me for something along these lines. (Jakob, I know
this has been a while coming ; )]

The way you use this is you create a script that takes in as its first
argument a count. The script passes into LLVM the count via a command
line flag that disables a pass after LLVM has run after the pass has
run for count number of times. Then the script invokes a test of some
sort and indicates whether LLVM successfully compiled the test via the
scripts exit status. Then you invoke bisect as follows:

bisect --start=<start_num> --end=<end_num> ./script.sh "%(count)s"

And bisect will continually call ./script.sh with various counts using
the exit status to determine success and failure.

llvm-svn: 214610
2014-08-02 01:39:08 +00:00