首页 > 编程语言 > 详细

转)Understanding Java Memory Management

时间:2019-09-08 15:11:42      阅读:103      评论:0      收藏:0      [点我收藏+]

Understanding Java Memory Management - IBM

技术分享图片

Java Native Interface (JNI) Objects and Code

Java Native Interface code can directly allocate native memory using system calls:

– malloc, calloc, realloc etc.

Uses memory from the memory from the process address space

– Just like the Java heap does

Some Java Class Library code uses JNI, and therefore allocates native memory

– java.lang.Class

– java.lang.Thread

– java.net.Socket

– java.util.ZipFile

– java.nio.ByteBuffer (if allocated as direct)

Objects that use small amount of Java heap, may use much larger quantities of native memory

– Classes, Threads and (direct) ByteBuffers are good examples

Example: java.lang.Class objects
技术分享图片

Example: java.lang.Class objects
技术分享图片

转)Understanding Java Memory Management

原文:https://www.cnblogs.com/eycuii/p/11486142.html

(3)
(3)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!