Salta la navigazione

when calling java from a native thread via jni you may run into a synthetic stack overflow exception thrown by the jvm leading to a jvm crash. This may happen if the native’s thread remaining stack size is lower (stack grows downwards) than the reserved stack size defined by the jvm’s options -XXStackYellowPages -XXStackRedPages -XXStackShadowPages. Obviously the native thread doesn’t know of this constraint so it grows its stack until the limit and you may run into troubles if you’re allocating big arrays on the stack.
To solve this issue you may either increase the native thread stack size or decrease the amount of pages reserved by the jvm by tweaking those parameters above.

Lascia un Commento

Fill in your details below or click an icon to log in:

Logo WordPress.com

You are commenting using your WordPress.com account. Log Out / Modifica )

Foto Twitter

You are commenting using your Twitter account. Log Out / Modifica )

Foto di Facebook

You are commenting using your Facebook account. Log Out / Modifica )

Connecting to %s

Follow

Get every new post delivered to your Inbox.