Support for exception throwing from JNI.
This change modifies the exception throwing JNI unit test to be
realistic and implements the missing exception throwing pieces on X86.
It also corrects some issues on ARM including methods with arguments
LJII (such as compareAndSwapInt).
Change-Id: I375f6efe2edeebb8007d7aa12c10b49742a8f119
diff --git a/src/object.cc b/src/object.cc
index 157bfc9..7f247c7 100644
--- a/src/object.cc
+++ b/src/object.cc
@@ -488,8 +488,8 @@
uint32_t Method::ToDexPC(const uintptr_t pc) const {
IntArray* mapping_table = GetMappingTable();
if (mapping_table == NULL) {
- DCHECK(pc == 0);
- return DexFile::kDexNoIndex; // Special no mapping/pc == -1 case
+ DCHECK(IsNative());
+ return DexFile::kDexNoIndex; // Special no mapping case
}
size_t mapping_table_length = mapping_table->GetLength();
uint32_t sought_offset = pc - reinterpret_cast<uintptr_t>(GetCode());