Updating the compiler to use the new-world model
New compiler is integrated and passes first test (Fibonacci).
Change-Id: Ic5448ab89ebd22baa30fafc3d1300324687d1fc2
diff --git a/src/jni_compiler.cc b/src/jni_compiler.cc
index 077e7bb..4215031 100644
--- a/src/jni_compiler.cc
+++ b/src/jni_compiler.cc
@@ -292,7 +292,9 @@
size_t cs = jni_asm->CodeSize();
MemoryRegion code(AllocateCode(cs), cs);
jni_asm->FinalizeInstructions(code);
- native_method->SetCode(code.pointer());
+ // TODO: need to ask jni_asm what instruction set used
+ native_method->SetCode(reinterpret_cast<byte*>(code.pointer()), cs,
+ jni_asm->GetInstructionSet());
}
// Copy a single parameter from the managed to the JNI calling convention