Generalize bugpoint's concept of a "safe" backend, and add options
[oota-llvm.git] / docs / CommandGuide / bugpoint.pod
index d97f51fd23bf340d9eeb86988e9fb4619461ab6a..4a16ffd510de857eece6b406555fbd7aa08eaa67 100644 (file)
@@ -57,6 +57,11 @@ The "--" right after the B<--tool-args> option tells B<bugpoint> to consider any
 options starting with C<-> to be part of the B<--tool-args> option, not as
 options to B<bugpoint> itself. (See B<--args>, above.)
 
+=item B<--safe-tool-args> I<tool args>
+
+Pass all arguments specified after --safe-tool-args to the "safe" execution
+tool.
+
 =item B<--disable-{dce,simplifycfg}>
 
 Do not run the specified passes to clean up and reduce the size of the test
@@ -103,18 +108,41 @@ to zero to disable the limit.
 Whenever the test program produces output on its standard output stream, it
 should match the contents of F<filename> (the "reference output"). If you
 do not use this option, B<bugpoint> will attempt to generate a reference output
-by compiling the program with the C backend and running it.
+by compiling the program with the "safe" backend and running it.
 
 =item B<--profile-info-file> F<filename>
 
 Profile file loaded by B<--profile-loader>.
 
-=item B<--run-{int,jit,llc,cbe}>
+=item B<--run-{int,jit,llc,cbe,custom}>
 
 Whenever the test program is compiled, B<bugpoint> should generate code for it
 using the specified code generator.  These options allow you to choose the
-interpreter, the JIT compiler, the static native code compiler, or the C
-backend, respectively.
+interpreter, the JIT compiler, the static native code compiler, the C
+backend, or a custom command (see B<--exec-command>) respectively.
+
+=item B<--safe-{llc,cbe,custom}>
+
+When debugging a code generator, B<bugpoint> should use the specified code
+generator as the "safe" code generator. This is a known-good code generator
+used to generate the "reference output" if it has not been provided, and to
+compile portions of the program that as they are excluded from the testcase.
+These options allow you to choose the
+static native code compiler, the C backend, or a custom command,
+(see B<--exec-command>) respectively. The interpreter and the JIT backends
+cannot currently be used as the "safe" backends.
+
+=item B<--exec-command> I<command>
+
+This option defines the command to use with the B<--run-custom> and
+B<--safe-custom> options to execute the bitcode testcase. This can
+be useful for cross-compilation.
+
+=item B<--safe-path> I<path>
+
+This option defines the path to the command to execute with the
+B<--safe-{int,jit,llc,cbe,custom}>
+option.
 
 =back