summaryrefslogtreecommitdiffstats
path: root/vm/test
diff options
context:
space:
mode:
authorAndy McFadden <fadden@android.com>2009-08-19 07:21:41 -0700
committerAndy McFadden <fadden@android.com>2009-08-20 17:30:56 -0700
commitab00d455ea67fbf4090567bb09ead8017896ea61 (patch)
tree2b2d66720683073fb4bab9739c7c49ec1594c4b4 /vm/test
parentfe79541b5cc5a490dd3a5b2e68f884fdfad4ca76 (diff)
downloadandroid_dalvik-ab00d455ea67fbf4090567bb09ead8017896ea61.tar.gz
android_dalvik-ab00d455ea67fbf4090567bb09ead8017896ea61.tar.bz2
android_dalvik-ab00d455ea67fbf4090567bb09ead8017896ea61.zip
Progress toward indirect JNI references.
Switch from simple typecasts to conversion functions for the objects passed in and out of JNI calls. No real change here; object references are still just pointers. Use explicit pin/unpin calls for primitive arrays. For GetStringChars we now pin the char[] rather than the String object. (Which doesn't make much difference in the grand scheme of things, since you need to keep the String to pass into the release function anyway.)
Diffstat (limited to 'vm/test')
-rw-r--r--vm/test/TestIndirectRefTable.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/vm/test/TestIndirectRefTable.c b/vm/test/TestIndirectRefTable.c
index 72f8f33b2..64d843c27 100644
--- a/vm/test/TestIndirectRefTable.c
+++ b/vm/test/TestIndirectRefTable.c
@@ -39,7 +39,7 @@ static bool basicTest(void)
Object* obj1 = dvmAllocObject(clazz, ALLOC_DONT_TRACK);
Object* obj2 = dvmAllocObject(clazz, ALLOC_DONT_TRACK);
Object* obj3 = dvmAllocObject(clazz, ALLOC_DONT_TRACK);
- const u4 cookie = IRT_SEGMENT_INIT;
+ const u4 cookie = IRT_FIRST_SEGMENT;
bool result = false;
if (!dvmInitIndirectRefTable(&irt, kTableMax/2, kTableMax,
@@ -329,7 +329,7 @@ static bool segmentTest(void)
{
return false;
}
- cookie = segmentState[0] = IRT_SEGMENT_INIT;
+ cookie = segmentState[0] = IRT_FIRST_SEGMENT;
DBUG_MSG("+++ objs %p %p %p %p\n", obj0, obj1, obj2, obj3);
/*