Avoiding fragmentation for ibm jvm


For a large Java? application, such as WebSphere? Application Server, the default kCluster space (for an introduction to kCluster, see Pinned clusters) might not be sufficient to allocate all classblocks. Use the -Xk and -Xp command-line options to specify kCluster and pCluster sizes. For example:

-Xknnnnwhere nnnn specifies the maximum number of classes the kCluster will contain. -Xkinstructs the JVM to allocate space for nnnn class blocks in kCluster. If nnnn is less than 1280, the JVM ignores -Xk and allocates space for 1280 class blocks in kCluster.

GC trace data obtained by setting -Dibm.dg.trc.print=st_verify (for more information about GC tracing, see Tracing) provides a guide for the optimum value of the nnnn parameter. For example::

dosed=10388 movable=1233792 free=5658>The 'pinned/classes' size is about the correct size needed for the -Xk parameter. You are recommended to add 10% to the reported value (3955). So, in this example, -Xk4200 would be a good setting.

The difference between pinned (=4265) and classes (=3955) provides a guide for the initial size of pCluster, although because each object might be different in size it is hard to predict the requirements for the pCluster and pCluster overflow options.

You can specify the pCluster and pCluster overflow sizes by the -Xp command-line option:

-Xp[,]where specifies the size of the initial pCluster in bytes and optionally specifies the size of overflow (subsequent) pClusters in bytes. You can use the K and M suffixes to set the -Xp arguments in Kilobytes and Megabytes, for example:

-Xp16K,2K sets an initial pCluster of 16 Kilobytes and an overflow of 2 kilobytes, which are the default pCluster sizes.
-Xp1M sets an initial pCluster of 1 Megabyte, with the default overflow of 2 Kilobytes.
-Xp1024K sets an initial pCluster of 1024Kilobytes, with the default overflow of 2 Kilobytes.
Where your application suffers from heap fragmentation, use GC trace and specify the -Xk option. If the problem persists, experiment with higher initial pCluster settings and overflow pCluster sizes.

Note that the -Xp command-line option is available only on the AIX? platform. with the subpool GC policy enabled. On other platforms and with other GC policies, this option is ignored.

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/27378/viewspace-582500/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/27378/viewspace-582500/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值