From 6cf7a9b0ecce7057758a55d8a2a2a5f1ca4653dc Mon Sep 17 00:00:00 2001 From: Nicolas Geoffray Date: Thu, 27 Feb 2020 21:51:29 +0000 Subject: Revert "Revert "If generating an image, run initialization and other optimizations."" This reverts commit bbec8a6fc720ee5ce572d3fb63617fb0af6addc7. Reason for revert: Fix vdex compilation with app images. Test: 628-vdex Bug: 150193586 Change-Id: Ic4d0445f277caf9405c18938c1f39ee08b9bf2fd --- compiler/driver/compiler_options.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'compiler/driver/compiler_options.h') diff --git a/compiler/driver/compiler_options.h b/compiler/driver/compiler_options.h index 747205e4e5..79ba1c27c9 100644 --- a/compiler/driver/compiler_options.h +++ b/compiler/driver/compiler_options.h @@ -195,6 +195,10 @@ class CompilerOptions final { return implicit_suspend_checks_; } + bool IsGeneratingImage() const { + return IsBootImage() || IsBootImageExtension() || IsAppImage(); + } + // Are we compiling a boot image? bool IsBootImage() const { return image_type_ == ImageType::kBootImage; -- cgit v1.2.3-59-g8ed1b