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_options.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'compiler/driver/compiler_options.h') diff --git a/compiler/driver/compiler_options.h b/compiler/driver/compiler_options.h index fecc600d64..5042c7594c 100644 --- a/compiler/driver/compiler_options.h +++ b/compiler/driver/compiler_options.h @@ -70,7 +70,8 @@ class CompilerOptions FINAL { bool compile_pic, const std::vector* verbose_methods, PassManagerOptions* pass_manager_options, - std::ostream* init_failure_output); + std::ostream* init_failure_output, + bool abort_on_hard_verifier_failure); CompilerFilter GetCompilerFilter() const { return compiler_filter_; @@ -183,6 +184,10 @@ class CompilerOptions FINAL { return pass_manager_options_.get(); } + bool AbortOnHardVerifierFailure() const { + return abort_on_hard_verifier_failure_; + } + private: CompilerFilter compiler_filter_; const size_t huge_method_threshold_; @@ -206,6 +211,10 @@ class CompilerOptions FINAL { std::unique_ptr pass_manager_options_; + // Abort compilation with an error if we find a class that fails verification with a hard + // failure. + const bool abort_on_hard_verifier_failure_; + // Log initialization of initialization failures to this stream if not null. std::ostream* const init_failure_output_; -- cgit v1.2.3-59-g8ed1b