|
| 1 | + |
| 2 | +=pod |
| 3 | + |
| 4 | +=head1 NAME |
| 5 | + |
| 6 | +extract - extract a function from an LLVM module |
| 7 | + |
| 8 | +=head1 SYNOPSIS |
| 9 | + |
| 10 | +extract [options] --func function-name [filename] |
| 11 | + |
| 12 | +=head1 DESCRIPTION |
| 13 | + |
| 14 | +The B<extract> command takes the name of a function and extracts it from |
| 15 | +the specified LLVM bytecode file. It is primarily used as a debugging tool to |
| 16 | +reduce test cases from larger programs that are triggering a bug. |
| 17 | + |
| 18 | +In addition to extracting the bytecode of the specified function, |
| 19 | +B<extract> will also remove unreachable global variables, prototypes, and |
| 20 | +unused types. |
| 21 | + |
| 22 | +The B<extract> command reads its input from standard input if filename is |
| 23 | +omitted or if filename is -. The output is always written to standard output, |
| 24 | +unless the B<-o> option is specified (see below). |
| 25 | + |
| 26 | +=head1 OPTIONS |
| 27 | + |
| 28 | +=over |
| 29 | + |
| 30 | +=item B<-f> |
| 31 | + |
| 32 | +Force overwrite. Normally, B<extract> will refuse to overwrite an |
| 33 | +output file that already exists. With this option, B<extract> |
| 34 | +will overwrite the output file and replace it with new bytecode. |
| 35 | + |
| 36 | +=item B<--func> I<function-name> |
| 37 | + |
| 38 | +Extract the function named I<function-name> from the LLVM bytecode. |
| 39 | + |
| 40 | +=item B<--help> |
| 41 | + |
| 42 | +Print a summary of command line options. |
| 43 | + |
| 44 | +=item B<-o> I<filename> |
| 45 | + |
| 46 | +Specify the output filename. If filename is "-" (the default), then |
| 47 | +B<extract> sends its output to standard output. |
| 48 | + |
| 49 | +=item B<--stats> |
| 50 | + |
| 51 | +Print statistics. |
| 52 | + |
| 53 | +=item B<--time-passes> |
| 54 | + |
| 55 | +Record the amount of time needed for each pass and print it to standard |
| 56 | +error. |
| 57 | + |
| 58 | +=back |
| 59 | + |
| 60 | +=head1 EXIT STATUS |
| 61 | + |
| 62 | +If B<extract> succeeds, it will exit with 0. Otherwise, if an error |
| 63 | +occurs, it will exit with a non-zero value. |
| 64 | + |
| 65 | +=head1 SEE ALSO |
| 66 | + |
| 67 | +L<bugpoint> |
| 68 | + |
| 69 | +=head1 AUTHORS |
| 70 | + |
| 71 | +Maintained by the LLVM Team (L<http://llvm.cs.uiuc.edu>). |
| 72 | + |
| 73 | +=cut |
| 74 | + |
0 commit comments