JVM垃圾回收管理和JDK自带的Debug工具介绍.pptx

JVM垃圾回收管理和JDK自带的Debug工具介绍.pptx

  1. 1、本文档共101页,可阅读全部内容。
  2. 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
JVM Memory Management JDK Debug ToolsArthur DongAug. 2011AgendaJVM Memory ManagementMemory Management by GenerationsMemory AllocationGarbage CollectionCollector Automatic Selections and Behavior TuningJVM OptionsJDK Troubleshooting ToolsTroubleshooting Memory LeaksObject LifecycleThe blue area in the diagram below is a typical distribution for the lifetimes of objects. The X axis is object lifetimes measured in bytes allocated. The byte count on the Y axis is the total bytes in objects with the corresponding lifetime.JVM Memory ManagementMemory Management meansAllocating memory for objectsEnsuring that any live objects remain in memory and Recovering memory used by dead objectsLive ObjectsObjects that are referencedDead Objects (or Garbage)Objects that are no longer referenced.The precise algorithm used to organize memory and allocate and deallocate space is handled by the garbage collector and hidden from the programmer. Space is commonly allocated from a large pool of memory referred to as the heap.JVM Memory ManagementMemory is managed in generations, that is, separate pools holding objects of different agesyoung generationMost objects are allocated here and most objects die here. (Most objects don’t live for long and most objects die young.)tenured generation (or old generation)Objects that have survived some number of minor collections are moved to this generation from young generation. Some large objects may be allocated directly in old generation.permanent generationIt holds data needed by the virtual machine to describe objects that do not have an equivalence at the Java language level. For example objects describing classes and methods. It’s separate heap space that is not garbage collected (ergo the permanent). Whatever is allocated to perm is in addition to the heap set with -Xmx.Young GenerationConsists of an area called eden plus two smaller survivor spaces. Most objects are initially allocated in eden. The survivor spaces holds objects that have surv

文档评论(0)

白领文档(原创) + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档