diff options
author | 2015-08-31 13:17:42 -0700 | |
---|---|---|
committer | 2015-10-13 13:09:37 -0700 | |
commit | eb7c144a6aff7da673ba53d501c46f00311d4d7f (patch) | |
tree | feec33dd2e711800305477b092970500991a3993 /compiler/dex/quick/quick_compiler.cc | |
parent | 98ae42010a6e6a0e4c5bcc4d6a357805eef3f4ff (diff) |
Add initial default method support to Art
This commit starts the process of adding default methods and their
associated pieces to ART.
This adds full support for calling default methods using
invoke-interface and invoke-virtual on objects implementing the
interfaces. Verifier is changed to allow this when the runtime is
started with -Xexperimental:default-methods.
This also adds support for defining and calling static methods on
interface classes with invoke-static.
Directly calling overridden default methods using invoke-super is not
yet supported.
This adds 5 new run-tests for this functionality.
Bug: 24618811
Change-Id: I35ca800d99d3329348b277789b70ceeeba6e7f03
Diffstat (limited to 'compiler/dex/quick/quick_compiler.cc')
-rw-r--r-- | compiler/dex/quick/quick_compiler.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/dex/quick/quick_compiler.cc b/compiler/dex/quick/quick_compiler.cc index 1cd742abac..c2fe5538b7 100644 --- a/compiler/dex/quick/quick_compiler.cc +++ b/compiler/dex/quick/quick_compiler.cc @@ -37,6 +37,7 @@ #include "driver/compiler_driver.h" #include "driver/compiler_options.h" #include "elf_writer_quick.h" +#include "experimental_flags.h" #include "jni/quick/jni_compiler.h" #include "mir_to_lir.h" #include "mirror/object.h" @@ -523,7 +524,8 @@ static bool SkipScanningUnsupportedOpcodes(InstructionSet instruction_set) { // All opcodes are supported no matter what. Usually not the case // since experimental opcodes are not implemented in the quick compiler. return true; - } else if (LIKELY(!Runtime::Current()->AreExperimentalLambdasEnabled())) { + } else if (LIKELY(!Runtime::Current()-> + AreExperimentalFlagsEnabled(ExperimentalFlags::kLambdas))) { // Experimental opcodes are disabled. // // If all unsupported opcodes are experimental we don't need to do scanning. |