1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-02-01 05:01:59 +01:00

[llc] Remove exit-on-error flag (PR27759)

This flag was introduced in r269655 with the new diagnostic handler for llc. Its
purpose was to keep the old behavior for some of the tests that didn't recover
well after an error. Those tests have been fixed, so now it's safe to remove the
flag entirely.

Fixes PR27759.

Differential Revision: http://reviews.llvm.org/D21368

llvm-svn: 273554
This commit is contained in:
Diana Picus 2016-06-23 09:49:56 +00:00
parent 1647555c0b
commit 91b64d2b23

View File

@ -113,11 +113,6 @@ static cl::opt<bool> DiscardValueNames(
cl::desc("Discard names from Value (other than GlobalValue)."),
cl::init(false), cl::Hidden);
static cl::opt<bool> ExitOnError(
"exit-on-error",
cl::desc("Exit as soon as an error is encountered."),
cl::init(false), cl::Hidden);
namespace {
static ManagedStatic<std::vector<std::string>> RunPassNames;
@ -257,8 +252,7 @@ int main(int argc, char **argv) {
// Set a diagnostic handler that doesn't exit on the first error
bool HasError = false;
if (!ExitOnError)
Context.setDiagnosticHandler(DiagnosticHandler, &HasError);
Context.setDiagnosticHandler(DiagnosticHandler, &HasError);
// Compile the module TimeCompilations times to give better compile time
// metrics.
@ -486,11 +480,9 @@ static int compileModule(char **argv, LLVMContext &Context) {
PM.run(*M);
if (!ExitOnError) {
auto HasError = *static_cast<bool *>(Context.getDiagnosticContext());
if (HasError)
return 1;
}
auto HasError = *static_cast<bool *>(Context.getDiagnosticContext());
if (HasError)
return 1;
// Compare the two outputs and make sure they're the same
if (CompileTwice) {