Index: llvm/tools/bugpoint/CrashDebugger.cpp =================================================================== --- llvm/tools/bugpoint/CrashDebugger.cpp +++ llvm/tools/bugpoint/CrashDebugger.cpp @@ -54,6 +54,9 @@ cl::opt NoNamedMDRM("disable-namedmd-remove", cl::desc("Do not remove global named metadata"), cl::init(false)); + cl::opt VerboseErrors("verbose-errors", + cl::desc("Print the output of crashing program"), + cl::init(false)); } namespace llvm { @@ -905,7 +908,10 @@ std::string Error; BD.compileProgram(M, &Error); if (!Error.empty()) { - errs() << "\n"; + if (VerboseErrors) + errs() << Error << "\n"; + else + errs() << "\n"; return true; // Tool is still crashing. } errs() << '\n';