Java 8 has a command line switch: -XX:NativeMemoryTracking=<value> , where the value can be off , summary or detail .
You can set this to detail , and then you can query it with jcmd .
There is official documentation on this here . However, this feature is quite limited, but can help find the cause.
Otherwise, a rough but effective way to identify the source of the problem is to replace the DLL with a dummy version (or even a non-native dummy) and see if you can reproduce the same problem.
source share