summaryrefslogtreecommitdiffstats
path: root/compiler/driver/compiler_driver.cc
diff options
context:
space:
mode:
authorAndreas Gampe <agampe@google.com>2014-02-27 12:26:20 -0800
committerAndreas Gampe <agampe@google.com>2014-03-03 23:27:12 +0000
commit2da882315a61072664f7ce3c212307342e907207 (patch)
tree67d777be044f5b60e2f13ab7968b63c581904ea9 /compiler/driver/compiler_driver.cc
parent762d4e5b9e777ae64c4ba581af9c84b78a5e96a6 (diff)
downloadart-2da882315a61072664f7ce3c212307342e907207.zip
art-2da882315a61072664f7ce3c212307342e907207.tar.gz
art-2da882315a61072664f7ce3c212307342e907207.tar.bz2
Initial changes towards Generic JNI option
Some initial changes that lead to an UNIMPLEMENTED. Works by not compiling for JNI right now and tracking native methods which have neither quick nor portable code. Uses new trampoline. Change-Id: I5448654044eb2717752fd7359f4ef8bd5c17be6e
Diffstat (limited to 'compiler/driver/compiler_driver.cc')
-rw-r--r--compiler/driver/compiler_driver.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/compiler/driver/compiler_driver.cc b/compiler/driver/compiler_driver.cc
index 501ea7c..fc22add 100644
--- a/compiler/driver/compiler_driver.cc
+++ b/compiler/driver/compiler_driver.cc
@@ -440,6 +440,11 @@ const std::vector<uint8_t>* CompilerDriver::CreatePortableToInterpreterBridge()
PORTABLE_ENTRYPOINT_OFFSET(pPortableToInterpreterBridge));
}
+const std::vector<uint8_t>* CompilerDriver::CreateQuickGenericJniTrampoline() const {
+ return CreateTrampoline(instruction_set_, kQuickAbi,
+ QUICK_ENTRYPOINT_OFFSET(pQuickGenericJniTrampoline));
+}
+
const std::vector<uint8_t>* CompilerDriver::CreateQuickImtConflictTrampoline() const {
return CreateTrampoline(instruction_set_, kQuickAbi,
QUICK_ENTRYPOINT_OFFSET(pQuickImtConflictTrampoline));
@@ -1920,8 +1925,12 @@ void CompilerDriver::CompileMethod(const DexFile::CodeItem* code_item, uint32_t
uint64_t start_ns = NanoTime();
if ((access_flags & kAccNative) != 0) {
+#if defined(__x86_64__)
+ // leaving this empty will trigger the generic JNI version
+#else
compiled_method = compiler_backend_->JniCompile(*this, access_flags, method_idx, dex_file);
CHECK(compiled_method != NULL);
+#endif
} else if ((access_flags & kAccAbstract) != 0) {
} else {
MethodReference method_ref(&dex_file, method_idx);