JVM dies on a geometry with Lighting material and mutating mesh VBO

So I have a mesh that I change each frame. When it has the Unshaded material applied, all is fine. When I apply a Lighting material to it, eventually I get this:

[java]

A fatal error has been detected by the Java Runtime Environment:

EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x087e6f9a, pid=10680, tid=9520

JRE version: 7.0_21-b11

Java VM: Java HotSpot™ Client VM (23.21-b01 mixed mode, sharing windows-x86 )

Problematic frame:

C [atioglxx.dll+0x8e6f9a] DrvPresentBuffers+0x8995ca

Failed to write core dump. Minidumps are not enabled by default on client versions of Windows

If you would like to submit a bug report, please visit:

http://bugreport.sun.com/bugreport/crash.jsp

The crash happened outside the Java Virtual Machine in native code.

See problematic frame for where to report the bug.

--------------- T H R E A D ---------------

Current thread (0x01039c00): JavaThread “LWJGL Renderer Thread” daemon [_thread_in_native, id=9520, stack(0x078e0000,0x07930000)]

siginfo: ExceptionCode=0xc0000005, reading address 0x00000018

Registers:
EAX=0x09db6418, EBX=0x09db3640, ECX=0xbaad0ff5, EDX=0x00000000
ESP=0x0792f1c8, EBP=0x0792f1f8, ESI=0x0000000c, EDI=0x00000000
EIP=0x087e6f9a, EFLAGS=0x00010206

Top of Stack: (sp=0x0792f1c8)
0x0792f1c8: 09db72a0 00000003 00000000 00000007
0x0792f1d8: 09db3640 00000003 0acdfd84 00000001
0x0792f1e8: 00000000 00000000 00000000 01026900
0x0792f1f8: 0792f24c 087f64e1 09db72a0 09d487a8
0x0792f208: 0792f21d 0792f240 09db72a0 09db72a0
0x0792f218: 0ae6f410 00920134 087e4845 09dc3aa0
0x0792f228: 00000003 0ae251f0 0afe10b8 0792f248
0x0792f238: 087e7f5b 09d487a8 09db72a0 09db72a0

Instructions: (pc=0x087e6f9a)
0x087e6f7a: dc 74 0c 8b 4d f0 8d 84 19 d8 2d 00 00 eb 02 33
0x087e6f8a: c0 8b 32 85 f6 0f 86 0e 01 00 00 8b 10 8b 48 08
0x087e6f9a: 8b 5a 18 8b c6 c1 e8 02 48 83 f8 0f 0f 87 bc 00
0x087e6faa: 00 00 ff 24 85 48 71 7e 08 c1 e9 02 8b d1 e9 b3

Register to memory mapping:

EAX=0x09db6418 is an unknown value
EBX=0x09db3640 is an unknown value
ECX=0xbaad0ff5 is an unknown value
EDX=0x00000000 is an unknown value
ESP=0x0792f1c8 is pointing into the stack for thread: 0x01039c00
EBP=0x0792f1f8 is pointing into the stack for thread: 0x01039c00
ESI=0x0000000c is an unknown value
EDI=0x00000000 is an unknown value

Stack: [0x078e0000,0x07930000], sp=0x0792f1c8, free space=316k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C [atioglxx.dll+0x8e6f9a] DrvPresentBuffers+0x8995ca
C [atioglxx.dll+0x8f64e1] DrvPresentBuffers+0x8a8b11
C [atioglxx.dll+0x8f47ff] DrvPresentBuffers+0x8a6e2f
C [atioglxx.dll+0x8e7647] DrvPresentBuffers+0x899c77
C [atioglxx.dll+0x8daa0e] DrvPresentBuffers+0x88d03e
C [atioglxx.dll+0x8c39f0] DrvPresentBuffers+0x876020
C [atioglxx.dll+0x11c844] DrvPresentBuffers+0xcee74
C [atioglxx.dll+0x88a1c] DrvPresentBuffers+0x3b04c
C [atioglxx.dll+0x1a153b] DrvPresentBuffers+0x153b6b
C [atioglxx.dll+0x418550] DrvPresentBuffers+0x3cab80
C [lwjgl.dll+0x85bb] Java_org_lwjgl_opengl_NVVertexProgram_nglVertexAttrib4fNV+0x2b
J com.jme3.renderer.lwjgl.LwjglRenderer.updateUniform(Lcom/jme3/shader/Shader;Lcom/jme3/shader/Uniform;)V
J com.jme3.renderer.RenderManager.renderViewPort(Lcom/jme3/renderer/ViewPort;F)V
j com.jme3.app.SimpleApplication.update()V+102
j clj_jme.core.proxy$com.jme3.app.SimpleApplication$0.update()V+28
j com.jme3.system.lwjgl.LwjglAbstractDisplay.runLoop()V+22
j com.jme3.system.lwjgl.LwjglDisplay.runLoop()V+67
j com.jme3.system.lwjgl.LwjglAbstractDisplay.run()V+132
j java.lang.Thread.run()V+11
v ~StubRoutines::call_stub
V [jvm.dll+0x12b41a]
V [jvm.dll+0x1daa0e]
V [jvm.dll+0x12b603]
V [jvm.dll+0x12b667]
V [jvm.dll+0xd36bf]
V [jvm.dll+0x14b777]
V [jvm.dll+0x14b8e0]
V [jvm.dll+0x1802a9]
C [msvcr100.dll+0x5c6de] endthreadex+0x3a
C [msvcr100.dll+0x5c788] endthreadex+0xe4
C [kernel32.dll+0x133aa] BaseThreadInitThunk+0x12
C [ntdll.dll+0x39ef2] RtlInitializeExceptionChain+0x63
C [ntdll.dll+0x39ec5] RtlInitializeExceptionChain+0x36

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
J org.lwjgl.opengl.GL20.nglUniform4f(IFFFFJ)V
J com.jme3.renderer.lwjgl.LwjglRenderer.updateUniform(Lcom/jme3/shader/Shader;Lcom/jme3/shader/Uniform;)V
J com.jme3.renderer.lwjgl.LwjglRenderer.updateShaderUniforms(Lcom/jme3/shader/Shader;)V
J com.jme3.renderer.lwjgl.LwjglRenderer.setShader(Lcom/jme3/shader/Shader;)V
J com.jme3.material.Material.renderMultipassLighting(Lcom/jme3/shader/Shader;Lcom/jme3/scene/Geometry;Lcom/jme3/renderer/RenderManager;)V
J com.jme3.material.Material.render(Lcom/jme3/scene/Geometry;Lcom/jme3/renderer/RenderManager;)V
J com.jme3.renderer.RenderManager.renderGeometry(Lcom/jme3/scene/Geometry;)V
J com.jme3.renderer.queue.RenderQueue.renderGeometryList(Lcom/jme3/renderer/queue/GeometryList;Lcom/jme3/renderer/RenderManager;Lcom/jme3/renderer/Camera;Z)V
J com.jme3.renderer.queue.RenderQueue.renderQueue(Lcom/jme3/renderer/queue/RenderQueue$Bucket;Lcom/jme3/renderer/RenderManager;Lcom/jme3/renderer/Camera;Z)V
j com.jme3.renderer.RenderManager.renderViewPortQueues(Lcom/jme3/renderer/ViewPort;Z)V+22
J com.jme3.renderer.RenderManager.renderViewPort(Lcom/jme3/renderer/ViewPort;F)V
j com.jme3.renderer.RenderManager.render(FZ)V+123
j com.jme3.app.SimpleApplication.update()V+102
j clj_jme.core.proxy$com.jme3.app.SimpleApplication$0.update()V+28
j com.jme3.system.lwjgl.LwjglAbstractDisplay.runLoop()V+22
j com.jme3.system.lwjgl.LwjglDisplay.runLoop()V+67
j com.jme3.system.lwjgl.LwjglAbstractDisplay.run()V+132
j java.lang.Thread.run()V+11
v ~StubRoutines::call_stub

--------------- P R O C E S S ---------------

Java Threads: ( => current thread )
0x04aa2c00 JavaThread “clojure-agent-send-pool-9” [_thread_blocked, id=8812, stack(0x0cdf0000,0x0ce40000)]
0x04aa2800 JavaThread “clojure-agent-send-pool-8” [_thread_blocked, id=10820, stack(0x10430000,0x10480000)]
0x04aa2000 JavaThread “clojure-agent-send-pool-7” [_thread_blocked, id=8844, stack(0x10340000,0x10390000)]
0x05050400 JavaThread “clojure-agent-send-pool-6” [_thread_blocked, id=4504, stack(0x10100000,0x10150000)]
0x0504fc00 JavaThread “clojure-agent-send-pool-5” [_thread_blocked, id=8276, stack(0x0ff70000,0x0ffc0000)]
0x0504f800 JavaThread “clojure-agent-send-pool-4” [_thread_blocked, id=4500, stack(0x0fe30000,0x0fe80000)]
0x0504f000 JavaThread “clojure-agent-send-pool-3” [_thread_blocked, id=7964, stack(0x0fef0000,0x0ff40000)]
0x0504e800 JavaThread “clojure-agent-send-pool-2” [_thread_blocked, id=9860, stack(0x0c5a0000,0x0c5f0000)]
0x0504e400 JavaThread “clojure-agent-send-pool-1” [_thread_blocked, id=1488, stack(0x0c260000,0x0c2b0000)]
0x0504dc00 JavaThread “clojure-agent-send-pool-0” [_thread_blocked, id=2228, stack(0x0c2d0000,0x0c320000)]
0x0504d800 JavaThread “Thread-16” daemon [_thread_blocked, id=9764, stack(0x0c1b0000,0x0c200000)]
0x0504d000 JavaThread “Java2D Disposer” daemon [_thread_blocked, id=10572, stack(0x0b720000,0x0b770000)]
0x0504cc00 JavaThread “jME3 Audio Thread” daemon [_thread_blocked, id=3176, stack(0x0b790000,0x0b7e0000)]
=>0x01039c00 JavaThread “LWJGL Renderer Thread” daemon [_thread_in_native, id=9520, stack(0x078e0000,0x07930000)]
0x01039400 JavaThread “nREPL-worker-1” daemon [_thread_blocked, id=2004, stack(0x07d30000,0x07d80000)]
0x01039000 JavaThread “nREPL-worker-0” daemon [_thread_blocked, id=3108, stack(0x07d90000,0x07de0000)]
0x01038800 JavaThread “clojure-agent-send-off-pool-11” [_thread_blocked, id=8232, stack(0x07ba0000,0x07bf0000)]
0x01038400 JavaThread “clojure-agent-send-off-pool-10” [_thread_in_native, id=9408, stack(0x07c60000,0x07cb0000)]
0x01037c00 JavaThread “clojure-agent-send-off-pool-9” [_thread_in_native, id=8864, stack(0x07c10000,0x07c60000)]
0x01037400 JavaThread “clojure-agent-send-off-pool-8” [_thread_in_native, id=11216, stack(0x07890000,0x078e0000)]
0x01037000 JavaThread “clojure-agent-send-off-pool-7” [_thread_blocked, id=9104, stack(0x07710000,0x07760000)]
0x01036800 JavaThread “clojure-agent-send-off-pool-6” [_thread_blocked, id=6392, stack(0x077d0000,0x07820000)]
0x01036400 JavaThread “clojure-agent-send-off-pool-5” [_thread_blocked, id=9852, stack(0x07450000,0x074a0000)]
0x01035c00 JavaThread “clojure-agent-send-off-pool-4” [_thread_blocked, id=9920, stack(0x07780000,0x077d0000)]
0x01035800 JavaThread “clojure-agent-send-off-pool-3” [_thread_blocked, id=5272, stack(0x07690000,0x076e0000)]
0x01035000 JavaThread “clojure-agent-send-off-pool-2” [_thread_blocked, id=6036, stack(0x074a0000,0x074f0000)]
0x01034400 JavaThread “clojure-agent-send-off-pool-1” [_thread_blocked, id=9076, stack(0x06f80000,0x06fd0000)]
0x01034800 JavaThread “clojure-agent-send-off-pool-0” [_thread_blocked, id=3008, stack(0x073b0000,0x07400000)]
0x01033c00 JavaThread “Thread-2” [_thread_in_Java, id=9956, stack(0x06cf0000,0x06d40000)]
0x01033800 JavaThread “Java Sound Event Dispatcher” daemon [_thread_blocked, id=3984, stack(0x06170000,0x061c0000)]
0x01033000 JavaThread “Service Thread” daemon [_thread_blocked, id=8560, stack(0x01060000,0x010b0000)]
0x0103e400 JavaThread “C1 CompilerThread0” daemon [_thread_blocked, id=9176, stack(0x04820000,0x04870000)]
0x01032c00 JavaThread “Attach Listener” daemon [_thread_blocked, id=2556, stack(0x048c0000,0x04910000)]
0x01032400 JavaThread “Signal Dispatcher” daemon [_thread_blocked, id=11144, stack(0x010d0000,0x01120000)]
0x01023c00 JavaThread “Finalizer” daemon [_thread_blocked, id=6836, stack(0x04680000,0x046d0000)]
0x0101e400 JavaThread “Reference Handler” daemon [_thread_blocked, id=4040, stack(0x04730000,0x04780000)]
0x00bfd000 JavaThread “main” [_thread_blocked, id=10148, stack(0x00f00000,0x00f50000)]

Other Threads:
0x0101d000 VMThread [stack: 0x04610000,0x04660000] [id=8144]
0x04a38400 WatcherThread [stack: 0x04e00000,0x04e50000] [id=11004]

VM state:not at safepoint (normal execution)

VM Mutex/Monitor currently owned by a thread: None

Heap
def new generation total 30336K, used 7460K [0x244f0000, 0x265d0000, 0x29a40000)
eden space 27008K, 23% used [0x244f0000, 0x24b01cd0, 0x25f50000)
from space 3328K, 37% used [0x26290000, 0x263c7340, 0x265d0000)
to space 3328K, 0% used [0x25f50000, 0x25f50000, 0x26290000)
tenured generation total 67064K, used 41225K [0x29a40000, 0x2dbbe000, 0x344f0000)
the space 67064K, 61% used [0x29a40000, 0x2c282520, 0x2c282600, 0x2dbbe000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)

Card table byte_map: [0x00e50000,0x00f00000] byte_map_base: 0x00d2d880

Polling page: 0x00210000

Code Cache [0x025a0000, 0x029d8000, 0x045a0000)
total_blobs=2488 nmethods=2179 adapters=243 free_code_cache=28470Kb largest_free_block=29151232

Compilation events (10 events):
Event: 29.579 Thread 0x0103e400 nmethod 2206 0x029d13c8 code [0x029d14d0, 0x029d15ac]
Event: 29.587 Thread 0x0103e400 2207 com.jme3.math.Vector3f::distanceSquared (52 bytes)
Event: 29.588 Thread 0x0103e400 nmethod 2207 0x029d1648 code [0x029d1740, 0x029d1820]
Event: 29.609 Thread 0x0103e400 2208 java.math.BigInteger::getInt (63 bytes)
Event: 29.609 Thread 0x0103e400 nmethod 2208 0x029d1888 code [0x029d1990, 0x029d1acc]
Event: 29.615 Thread 0x0103e400 2209 java.nio.ByteBuffer::put (9 bytes)
Event: 29.615 Thread 0x0103e400 nmethod 2209 0x029d1b88 code [0x029d1c90, 0x029d1d3c]
Event: 29.623 Thread 0x0103e400 2210 clojure.lang.PersistentVector$TransientVector::editableRoot (28 bytes)
Event: 29.623 Thread 0x0103e400 nmethod 2210 0x029d1dc8 code [0x029d1ed0, 0x029d205c]
Event: 29.644 Thread 0x0103e400 2211 com.jme3.renderer.RenderManager::render (184 bytes)

GC Heap History (10 events):
Event: 29.155 GC heap before
{Heap before GC invocations=225 (full 5):
def new generation total 29760K, used 29760K [0x244f0000, 0x26530000, 0x29a40000)
eden space 26496K, 100% used [0x244f0000, 0x25ed0000, 0x25ed0000)
from space 3264K, 100% used [0x26200000, 0x26530000, 0x26530000)
to space 3264K, 0% used [0x25ed0000, 0x25ed0000, 0x26200000)
tenured generation total 65852K, used 63440K [0x29a40000, 0x2da8f000, 0x344f0000)
the space 65852K, 96% used [0x29a40000, 0x2d834208, 0x2d834400, 0x2da8f000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)
Event: 29.174 GC heap after
Heap after GC invocations=226 (full 5):
def new generation total 29760K, used 3264K [0x244f0000, 0x26530000, 0x29a40000)
eden space 26496K, 0% used [0x244f0000, 0x244f0000, 0x25ed0000)
from space 3264K, 100% used [0x25ed0000, 0x26200000, 0x26200000)
to space 3264K, 0% used [0x26200000, 0x26200000, 0x26530000)
tenured generation total 65852K, used 65600K [0x29a40000, 0x2da8f000, 0x344f0000)
the space 65852K, 99% used [0x29a40000, 0x2da50238, 0x2da50400, 0x2da8f000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)
}
Event: 29.262 GC heap before
{Heap before GC invocations=226 (full 5):
def new generation total 29760K, used 29760K [0x244f0000, 0x26530000, 0x29a40000)
eden space 26496K, 100% used [0x244f0000, 0x25ed0000, 0x25ed0000)
from space 3264K, 100% used [0x25ed0000, 0x26200000, 0x26200000)
to space 3264K, 0% used [0x26200000, 0x26200000, 0x26530000)
tenured generation total 65852K, used 65600K [0x29a40000, 0x2da8f000, 0x344f0000)
the space 65852K, 99% used [0x29a40000, 0x2da50238, 0x2da50400, 0x2da8f000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)
Event: 29.382 GC heap after
Heap after GC invocations=227 (full 6):
def new generation total 30336K, used 0K [0x244f0000, 0x265d0000, 0x29a40000)
eden space 27008K, 0% used [0x244f0000, 0x244f0000, 0x25f50000)
from space 3328K, 0% used [0x25f50000, 0x25f50000, 0x26290000)
to space 3328K, 0% used [0x26290000, 0x26290000, 0x265d0000)
tenured generation total 67064K, used 40237K [0x29a40000, 0x2dbbe000, 0x344f0000)
the space 67064K, 59% used [0x29a40000, 0x2c18b6c0, 0x2c18b800, 0x2dbbe000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)
}
Event: 29.465 GC heap before
{Heap before GC invocations=227 (full 6):
def new generation total 30336K, used 27008K [0x244f0000, 0x265d0000, 0x29a40000)
eden space 27008K, 100% used [0x244f0000, 0x25f50000, 0x25f50000)
from space 3328K, 0% used [0x25f50000, 0x25f50000, 0x26290000)
to space 3328K, 0% used [0x26290000, 0x26290000, 0x265d0000)
tenured generation total 67064K, used 40237K [0x29a40000, 0x2dbbe000, 0x344f0000)
the space 67064K, 59% used [0x29a40000, 0x2c18b6c0, 0x2c18b800, 0x2dbbe000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)
Event: 29.470 GC heap after
Heap after GC invocations=228 (full 6):
def new generation total 30336K, used 1205K [0x244f0000, 0x265d0000, 0x29a40000)
eden space 27008K, 0% used [0x244f0000, 0x244f0000, 0x25f50000)
from space 3328K, 36% used [0x26290000, 0x263bd720, 0x265d0000)
to space 3328K, 0% used [0x25f50000, 0x25f50000, 0x26290000)
tenured generation total 67064K, used 40237K [0x29a40000, 0x2dbbe000, 0x344f0000)
the space 67064K, 59% used [0x29a40000, 0x2c18b6c0, 0x2c18b800, 0x2dbbe000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)
}
Event: 29.541 GC heap before
{Heap before GC invocations=228 (full 6):
def new generation total 30336K, used 28213K [0x244f0000, 0x265d0000, 0x29a40000)
eden space 27008K, 100% used [0x244f0000, 0x25f50000, 0x25f50000)
from space 3328K, 36% used [0x26290000, 0x263bd720, 0x265d0000)
to space 3328K, 0% used [0x25f50000, 0x25f50000, 0x26290000)
tenured generation total 67064K, used 40237K [0x29a40000, 0x2dbbe000, 0x344f0000)
the space 67064K, 59% used [0x29a40000, 0x2c18b6c0, 0x2c18b800, 0x2dbbe000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)
Event: 29.547 GC heap after
Heap after GC invocations=229 (full 6):
def new generation total 30336K, used 2464K [0x244f0000, 0x265d0000, 0x29a40000)
eden space 27008K, 0% used [0x244f0000, 0x244f0000, 0x25f50000)
from space 3328K, 74% used [0x25f50000, 0x261b8100, 0x26290000)
to space 3328K, 0% used [0x26290000, 0x26290000, 0x265d0000)
tenured generation total 67064K, used 40237K [0x29a40000, 0x2dbbe000, 0x344f0000)
the space 67064K, 59% used [0x29a40000, 0x2c18b6c0, 0x2c18b800, 0x2dbbe000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)
}
Event: 29.625 GC heap before
{Heap before GC invocations=229 (full 6):
def new generation total 30336K, used 29472K [0x244f0000, 0x265d0000, 0x29a40000)
eden space 27008K, 100% used [0x244f0000, 0x25f50000, 0x25f50000)
from space 3328K, 74% used [0x25f50000, 0x261b8100, 0x26290000)
to space 3328K, 0% used [0x26290000, 0x26290000, 0x265d0000)
tenured generation total 67064K, used 40237K [0x29a40000, 0x2dbbe000, 0x344f0000)
the space 67064K, 59% used [0x29a40000, 0x2c18b6c0, 0x2c18b800, 0x2dbbe000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)
Event: 29.631 GC heap after
Heap after GC invocations=230 (full 6):
def new generation total 30336K, used 1244K [0x244f0000, 0x265d0000, 0x29a40000)
eden space 27008K, 0% used [0x244f0000, 0x244f0000, 0x25f50000)
from space 3328K, 37% used [0x26290000, 0x263c7340, 0x265d0000)
to space 3328K, 0% used [0x25f50000, 0x25f50000, 0x26290000)
tenured generation total 67064K, used 41225K [0x29a40000, 0x2dbbe000, 0x344f0000)
the space 67064K, 61% used [0x29a40000, 0x2c282520, 0x2c282600, 0x2dbbe000)
compacting perm gen total 12544K, used 12386K [0x344f0000, 0x35130000, 0x384f0000)
the space 12544K, 98% used [0x344f0000, 0x35108ba0, 0x35108c00, 0x35130000)
ro space 10240K, 42% used [0x384f0000, 0x389322a0, 0x38932400, 0x38ef0000)
rw space 12288K, 54% used [0x38ef0000, 0x39573250, 0x39573400, 0x39af0000)
}

Deoptimization events (0 events):
No events

Internal exceptions (10 events):
Event: 21.923 Thread 0x01039c00 Threw 0x256e24a0 at C:\jdk7u2_32P\jdk7u21\hotspot\src\share\vm\prims\jvm.cpp:1166
Event: 21.923 Thread 0x01039c00 Threw 0x256ed180 at C:\jdk7u2_32P\jdk7u21\hotspot\src\share\vm\prims\jvm.cpp:1166
Event: 21.924 Thread 0x01039c00 Threw 0x256f25e0 at C:\jdk7u2_32P\jdk7u21\hotspot\src\share\vm\prims\jvm.cpp:1166
Event: 21.925 Thread 0x01039c00 Threw 0x256f7e88 at C:\jdk7u2_32P\jdk7u21\hotspot\src\share\vm\prims\jvm.cpp:1166
Event: 21.932 Thread 0x01039c00 Threw 0x25706018 at C:\jdk7u2_32P\jdk7u21\hotspot\src\share\vm\prims\jvm.cpp:1166
Event: 21.932 Thread 0x01039c00 Threw 0x2570a668 at C:\jdk7u2_32P\jdk7u21\hotspot\src\share\vm\prims\jvm.cpp:1166
Event: 22.199 Thread 0x01039c00 Threw 0x2573cb10 at C:\jdk7u2_32P\jdk7u21\hotspot\src\share\vm\prims\jvm.cpp:1166
Event: 22.199 Thread 0x01039c00 Threw 0x257415c8 at C:\jdk7u2_32P\jdk7u21\hotspot\src\share\vm\prims\jvm.cpp:1166
Event: 22.717 Thread 0x01039c00 Threw 0x2466d0d0 at C:\jdk7u2_32P\jdk7u21\hotspot\src\share\vm\prims\jvm.cpp:1166
Event: 22.718 Thread 0x01039c00 Threw 0x24672a48 at C:\jdk7u2_32P\jdk7u21\hotspot\src\share\vm\prims\jvm.cpp:1166

Events (10 events):
Event: 29.155 Executing VM operation: GenCollectForAllocation
Event: 29.174 Executing VM operation: GenCollectForAllocation done
Event: 29.262 Executing VM operation: GenCollectForAllocation
Event: 29.382 Executing VM operation: GenCollectForAllocation done
Event: 29.465 Executing VM operation: GenCollectForAllocation
Event: 29.470 Executing VM operation: GenCollectForAllocation done
Event: 29.541 Executing VM operation: GenCollectForAllocation
Event: 29.547 Executing VM operation: GenCollectForAllocation done
Event: 29.625 Executing VM operation: GenCollectForAllocation
Event: 29.631 Executing VM operation: GenCollectForAllocation done

Dynamic libraries:
0x01170000 - 0x0119f000 C:\Program Files (x86)\Java\jre7\bin\java.exe
0x773c0000 - 0x77540000 C:\Windows\SysWOW64\ntdll.dll
0x76d80000 - 0x76e90000 C:\Windows\syswow64\kernel32.dll
0x762b0000 - 0x762f7000 C:\Windows\syswow64\KERNELBASE.dll
0x76800000 - 0x768a0000 C:\Windows\syswow64\ADVAPI32.dll
0x75360000 - 0x7540c000 C:\Windows\syswow64\msvcrt.dll
0x76bc0000 - 0x76bd9000 C:\Windows\SysWOW64\sechost.dll
0x74fe0000 - 0x750d0000 C:\Windows\syswow64\RPCRT4.dll
0x74e20000 - 0x74e80000 C:\Windows\syswow64\SspiCli.dll
0x74e10000 - 0x74e1c000 C:\Windows\syswow64\CRYPTBASE.dll
0x76ec0000 - 0x76fc0000 C:\Windows\syswow64\USER32.dll
0x755c0000 - 0x75650000 C:\Windows\syswow64\GDI32.dll
0x76a60000 - 0x76a6a000 C:\Windows\syswow64\LPK.dll
0x752c0000 - 0x7535d000 C:\Windows\syswow64\USP10.dll
0x727e0000 - 0x7297e000 C:\Windows\WinSxS\x86_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_41e6975e2bd6f2b2\COMCTL32.dll
0x76340000 - 0x76397000 C:\Windows\syswow64\SHLWAPI.dll
0x75560000 - 0x755c0000 C:\Windows\system32\IMM32.DLL
0x74f10000 - 0x74fdc000 C:\Windows\syswow64\MSCTF.dll
0x5f120000 - 0x5f1de000 C:\Program Files (x86)\Java\jre7\bin\msvcr100.dll
0x5fdd0000 - 0x6011f000 C:\Program Files (x86)\Java\jre7\bin\client\jvm.dll
0x73a40000 - 0x73a47000 C:\Windows\system32\WSOCK32.dll
0x765a0000 - 0x765d5000 C:\Windows\syswow64\WS2_32.dll
0x76cc0000 - 0x76cc6000 C:\Windows\syswow64\NSI.dll
0x71280000 - 0x712b2000 C:\Windows\system32\WINMM.dll
0x767f0000 - 0x767f5000 C:\Windows\syswow64\PSAPI.DLL
0x74690000 - 0x7469c000 C:\Program Files (x86)\Java\jre7\bin\verify.dll
0x74670000 - 0x74690000 C:\Program Files (x86)\Java\jre7\bin\java.dll
0x74650000 - 0x74663000 C:\Program Files (x86)\Java\jre7\bin\zip.dll
0x74630000 - 0x74644000 C:\Program Files (x86)\Java\jre7\bin\net.dll
0x72740000 - 0x7277c000 C:\Windows\system32\mswsock.dll
0x74700000 - 0x74706000 C:\Windows\System32\wship6.dll
0x74620000 - 0x7462e000 C:\Program Files (x86)\Java\jre7\bin\nio.dll
0x74590000 - 0x7459a000 C:\Program Files (x86)\Java\jre7\bin\jsound.dll
0x74580000 - 0x74589000 C:\Program Files (x86)\Java\jre7\bin\jsoundds.dll
0x698c0000 - 0x69932000 C:\Windows\system32\DSOUND.dll
0x750e0000 - 0x7523c000 C:\Windows\syswow64\ole32.dll
0x6e030000 - 0x6e055000 C:\Windows\system32\POWRPROF.dll
0x76400000 - 0x7659d000 C:\Windows\syswow64\SETUPAPI.dll
0x76e90000 - 0x76eb7000 C:\Windows\syswow64\CFGMGR32.dll
0x76cd0000 - 0x76d5f000 C:\Windows\syswow64\OLEAUT32.dll
0x76d60000 - 0x76d72000 C:\Windows\syswow64\DEVOBJ.dll
0x71b00000 - 0x71b80000 C:\Windows\system32\uxtheme.dll
0x69d80000 - 0x69db9000 C:\Windows\system32\MMDevAPI.DLL
0x71510000 - 0x71605000 C:\Windows\system32\PROPSYS.dll
0x69d50000 - 0x69d80000 C:\Windows\system32\wdmaud.drv
0x69d40000 - 0x69d44000 C:\Windows\system32\ksuser.dll
0x69d30000 - 0x69d37000 C:\Windows\system32\AVRT.dll
0x6a5f0000 - 0x6a60a000 C:\Program Files (x86)\TeamViewer\Version8\tv_w32.dll
0x72c10000 - 0x72c19000 C:\Windows\system32\VERSION.dll
0x6c240000 - 0x6c267000 C:\Windows\system32\CRTDLL.dll
0x75650000 - 0x7629a000 C:\Windows\syswow64\SHELL32.dll
0x69cf0000 - 0x69d26000 C:\Windows\system32\AUDIOSES.DLL
0x69ce0000 - 0x69ce8000 C:\Windows\system32\msacm32.drv
0x73a20000 - 0x73a34000 C:\Windows\system32\MSACM32.dll
0x69cd0000 - 0x69cd7000 C:\Windows\system32\midimap.dll
0x76c30000 - 0x76cb3000 C:\Windows\syswow64\CLBCatQ.DLL
0x72720000 - 0x72733000 C:\Windows\system32\dwmapi.dll
0x73df0000 - 0x73dfa000 C:\Program Files (x86)\Yandex\Punto Switcher\pshook.dll
0x76a70000 - 0x76a9a000 C:\Windows\syswow64\imagehlp.dll
0x71410000 - 0x71415000 C:\Windows\System32\wshtcpip.dll
0x71480000 - 0x714c4000 C:\Windows\system32\DNSAPI.dll
0x746c0000 - 0x746e7000 C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live\WLIDNSP.DLL
0x73160000 - 0x7317c000 C:\Windows\system32\IPHLPAPI.DLL
0x73150000 - 0x73157000 C:\Windows\system32\WINNSI.DLL
0x71420000 - 0x71426000 C:\Windows\system32\rasadhlp.dll
0x71430000 - 0x71468000 C:\Windows\System32\fwpuclnt.dll
0x72cf0000 - 0x72d06000 C:\Windows\system32\CRYPTSP.dll
0x73220000 - 0x7325b000 C:\Windows\system32\rsaenh.dll
0x72980000 - 0x72997000 C:\Windows\system32\USERENV.dll
0x72c20000 - 0x72c2b000 C:\Windows\system32\profapi.dll
0x71500000 - 0x71510000 C:\Windows\system32\NLAapi.dll
0x714f0000 - 0x71500000 C:\Windows\system32\napinsp.dll
0x714d0000 - 0x714e2000 C:\Windows\system32\pnrpnsp.dll
0x71470000 - 0x71478000 C:\Windows\System32\winrnr.dll
0x744e0000 - 0x744ed000 C:\Windows\system32\wshbth.dll
0x10000000 - 0x1004c000 D:\programming\ws\juno-01\r-b_002__clj-jme\lwjgl.dll
0x5f050000 - 0x5f118000 C:\Windows\system32\OPENGL32.dll
0x60440000 - 0x60462000 C:\Windows\system32\GLU32.dll
0x71b80000 - 0x71c67000 C:\Windows\system32\DDRAW.dll
0x72400000 - 0x72406000 C:\Windows\system32\DCIMAN32.dll
0x6a4c0000 - 0x6a4c7000 C:\Windows\system32\atiglpxx.dll
0x603e0000 - 0x60440000 C:\Windows\system32\atiadlxy.dll
0x73190000 - 0x7319d000 C:\Windows\system32\WTSAPI32.dll
0x75410000 - 0x7543d000 C:\Windows\syswow64\WINTRUST.dll
0x75440000 - 0x7555e000 C:\Windows\syswow64\CRYPT32.dll
0x765e0000 - 0x765ec000 C:\Windows\syswow64\MSASN1.dll
0x07f00000 - 0x091bd000 C:\Windows\system32\atioglxx.dll
0x63cb0000 - 0x63d74000 C:\Windows\system32\aticfx32.dll
0x69fa0000 - 0x69fab000 C:\Windows\system32\atigktxx.dll
0x601a0000 - 0x60219000 C:\Windows\system32\mscms.dll
0x63b10000 - 0x63b48000 C:\Windows\system32\icm32.dll
0x5ef00000 - 0x5f042000 C:\Program Files (x86)\Java\jre7\bin\awt.dll
0x0b040000 - 0x0b0a5000 D:\programming\ws\juno-01\r-b_002__clj-jme\OpenAL32.dll
0x60140000 - 0x60165000 C:\Program Files (x86)\Java\jre7\bin\jpeg.dll
0x729f0000 - 0x72adb000 C:\Windows\system32\dbghelp.dll

VM Arguments:
jvm_args: -Dclojure.compile.path=D:\programming\ws\juno-01\r-b_002__clj-jme\target\classes -Dr-b_002__clj-jme.version=0.1.0-SNAPSHOT -Dfile.encoding=UTF-8 -Dclojure.debug=false
java_command: clojure.main -e (do (set! warn-on-reflection nil) (do (try (clojure.core/require (quote clj-jme.core)) (catch java.lang.Exception e__5516__auto__ (clojure.core/println e__5516__auto__) (clojure.core/ns clj-jme.core))) (try (clojure.core/require (quote clojure.tools.nrepl.server)) (catch java.lang.Throwable t__5517__auto__ (clojure.core/println “Error loading” (clojure.core/str (quote clojure.tools.nrepl.server) “:”) (clojure.core/or (.getMessage t__5517__auto__) (clojure.core/type t__5517__auto__))))) (try (clojure.core/require (quote complete.core)) (catch java.lang.Throwable t__5517__auto__ (clojure.core/println “Error loading” (clojure.core/str (quote complete.core) “:”) (clojure.core/or (.getMessage t__5517__auto__) (clojure.core/type t__5517__auto__)))))) (require (quote ccw.debug.serverrepl)) (do nil (clojure.core/let [server__5514__auto__ (clojure.tools.nrepl.server/start-server :bind “127.0.0.1” :port 0 :ack-port 53087 :handler (clojure.tools.nrepl.server/default-handler (clojure.core/with-local-vars [wrap-init-ns__5473__auto__ (clojure.core/fn [h__5474__auto__] (clojure.core/with-local-vars [init-ns-sentinel__5475__auto__ nil] (clojure.core/fn [{:as msg__5476__auto__, :keys [session]}] (clojure.core/when-not ((clojure.core/deref session) init-ns-sentinel__5475__auto__) (clojure.core/swap! session clojure.core/assoc (var clojure.core/ns) (try (clojure.core/require (quote clj-jme.core)) (clojure.core/create-ns (quote clj-jme.core)) (catch java.lang.Throwable t__5477__auto__ (clojure.core/create-ns (quote user)))) init-ns-sentinel__5475__auto__ true)) (h__5474__auto__ msg__5476__auto__))))] (clojure.core/doto wrap-init-ns__5473__auto__ (clojure.tools.nrepl.middleware/set-descriptor! {:requires #{(var clojure.tools.nrepl.middleware.session/session)}, :expects #{“eval”}}) (clojure.core/alter-var-root (clojure.core/constantly (clojure.core/deref wrap-init-ns__5473__auto__))))))) port__5515__auto__ (clojure.core/-> server__5514__auto__ clojure.
Launcher Type: SUN_STANDARD

Environment Variables:

--------------- S Y S T E M ---------------

OS: Windows 7 , 64 bit Build 7601 Service Pack 1

CPU:total 8 (4 cores per cpu, 2 threads per core) family 6 model 58 stepping 9, cmov, cx8, fxsr, mmx, sse, sse2, sse3, ssse3, sse4.1, sse4.2, popcnt, avx, ht, tsc, tscinvbit, tscinv

Memory: 4k page, physical 4052840k(1005992k free), swap 8103820k(2009752k free)

vm_info: Java HotSpot™ Client VM (23.21-b01) for windows-x86 JRE (1.7.0_21-b11), built on Apr 4 2013 04:43:10 by “java_re” with unknown MS VC++:1600

time: Wed Jun 05 01:25:15 2013
elapsed time: 29 seconds

[/java]

As my program is written in Clojure and uses a load of 3rd party libs, I struggle to provide an easy runnable example of my code. But I think this is not necessary since the problem is clearly indicated to be insie LWJGL and not my code. Also: this fail happens on Radeon 7600M after several seconds of running. And it works perfectly on NVidia 520 GT desktop card. BTW I have the latest Radeon driver.

The exception clearly happens in the driver. What happens when you run similar shader code in another way? :slight_smile:

Ehh… if no insight happens, I’ll have to create a similar code in pure Java… that will take time…

BTW, I’ve tried to disable updating normals buffer and for now I can say that if I disable updating the Normals VertexBuffer of the mesh, that crash does not happen. I think that there might be a trouble with the data in the buffer. The data is generated by a java library and it’s an array of floats, where every three elements represent a vertex normal. Just as the tutorial on custom meshes says. To me there’s all fine since this technique works perferctly for vertex positioning. Maybe I misunderstand what should there be in the normals buffer… but looking at the trouble caused by uniform in a shader, I have some vague presumptions on that there is something with the shader like I remember they’ve forbidden writing uniforms that don’t get passed or something like that. I remember I had my shader suddenly broken on another videocard because of declared unused uniforms, but I do not remember exactly what it was about.

BTW-2: all JMonkeyEngine SDK ligthting examples work perfectly but they do not feature a morphing mesh.

Works fine on one card, crashes hard on another. I don’t think your normals are the problem.

One question, do you modify the existing buffer or create a new one? If you are creating a new one are you manually deleting it or something like that?

Trying to rule out bad programming.

Alright, I have conducted endlessly more experiments and now I think I got it. Looks like it did not depend on anything with shaders, it was the vertex buffer what caused errors. The geometric library sometimes outputs data arrays of zero length (when geometry generation is impossible with current parameters). Sometimes it went through ok and visually the mesh wasn’t changed, but eventually, passing a zero-length arrays did the crash. As of the question of pspeed, looks like there is no difference in behavior depending on do I modify it or create a new buffer except for that modifying it seems to be faster than creating a new one. What is strange - the crash did not happen on the first time passed zero-length data array. It happened on some subsequent occasion. NVidia desktop card managed that ok. What do you think?

Also: my strategy on handling vertex buffer updates is this: if the existing buffer capacity is <= than the new buffer capacity, I update it with the .updateData(data) method. Otherwise, I .setBuffer(data) - is this an idiomatic approach? My mesh vertices amount can vary greatly over subsequent frames, it can oscillate between say 500 and 500000 vertices.

Why is capacity changed to a lesser capacity if I update a bigger buffer with a lesser buffer? Shouldn’t it only change the limit, not capacity? Or is it somehow automatically compacted?

It looks like the stack got corrupted because the Java side calls native method glUniform4f() yet the C++ stack says glVertexAttrib4fNV(). We never even use the latter function in jME3.

@Momoko_Fan ummm… but what does it mean that what you say? Should I continue watching for zero-length arrays manually? (makes sense right) or will you maybe consider this point somewhere in jME3? (looks like that makes more sense, but idk, I’m too far away).

Well yes i can relate, i had when i was doing that ray stuff for bullet, also always an exception in that method (at least under windows that is).