From 6cf49e57ad7a61e1fffd5b1dfae9179c3ca5703d Mon Sep 17 00:00:00 2001 From: Andreas Gampe Date: Thu, 5 Mar 2015 13:08:45 -0800 Subject: ART: Add option to abort dex2oat on hard failure Add an option that aborts dex2oat when a hard verifier failure occurs. Bug: 19606409 Change-Id: I53195284e22fe6207274101e85745af763c06271 --- compiler/driver/compiler_driver.cc | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'compiler/driver/compiler_driver.cc') diff --git a/compiler/driver/compiler_driver.cc b/compiler/driver/compiler_driver.cc index a52a83a28a..df2b520b50 100644 --- a/compiler/driver/compiler_driver.cc +++ b/compiler/driver/compiler_driver.cc @@ -358,6 +358,7 @@ CompilerDriver::CompilerDriver(const CompilerOptions* compiler_options, image_(image), image_classes_(image_classes), classes_to_compile_(compiled_classes), + had_hard_verifier_failure_(false), thread_count_(thread_count), stats_(new AOTCompilationStats), dedupe_enabled_(true), @@ -616,6 +617,11 @@ void CompilerDriver::PreCompile(jobject class_loader, const std::vectorGetCompiler()->SetHadHardVerifierFailure(); } } else if (!SkipClass(jclass_loader, dex_file, klass.Get())) { CHECK(klass->IsResolved()) << PrettyClass(klass.Get()); @@ -1848,6 +1855,7 @@ static void VerifyClass(const ParallelCompilationManager* manager, size_t class_ // ClassLinker::VerifyClass throws, which isn't useful in the compiler. CHECK(soa.Self()->IsExceptionPending()); soa.Self()->ClearException(); + manager->GetCompiler()->SetHadHardVerifierFailure(); } CHECK(klass->IsCompileTimeVerified() || klass->IsErroneous()) -- cgit v1.2.3