12 messages in net.java.dev.jna.usersRe: [jna-users] Getting pointers from...
FromSent OnAttachments
Douglas AdlerAug 20, 2008 12:03 pm 
Timothy WallAug 20, 2008 12:55 pm 
Wayne MeissnerAug 20, 2008 6:37 pm 
Douglas AdlerAug 21, 2008 11:56 am 
Timothy WallAug 21, 2008 12:18 pm 
Wayne MeissnerAug 21, 2008 3:47 pm 
Wayne MeissnerAug 21, 2008 3:55 pm 
Timothy WallAug 22, 2008 7:41 am 
Wayne MeissnerAug 22, 2008 3:57 pm 
Timothy WallAug 22, 2008 4:04 pm 
Wayne MeissnerAug 22, 2008 4:39 pm 
Scott PalmerAug 22, 2008 6:47 pm 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Re: [jna-users] Getting pointers from javaActions...
From:Scott Palmer (scot@2connected.org)
Date:Aug 22, 2008 6:47:31 pm
List:net.java.dev.jna.users

The GC compacts or copies live objects to promote them from one generation to the next or as part of the mark-sweep phase of the old gneration. It can't do that if the array is pinned.

http://java.sun.com/docs/hotspot/gc1.4.2/faq.html

Scott

On 22-Aug-08, at 7:40 PM, Wayne Meissner wrote:

2008/8/23 Timothy Wall <twal@dev.java.net>:

I understand that part. I was questioning the rationale for the VM suspending GC for the duration of the GetPrimitiveArrayCritical call... I don't imagine that sort of thing is embedded in the spec?

*shrug*

Its what the current implementations do, so we need to deal with it.

The existing restrictions on GetPrimitiveArrayCritical cover this case anyway (i.e. no blocking function calls, no calls to other JNI functions), so its not exactly an additional problem, just an implementation artifact.