JDK-6539434 : jmap -histo overflows int values for large heaps
  • Type: Bug
  • Component: core-svc
  • Sub-Component: java.lang.management
  • Affected Version: 7
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • OS: generic
  • CPU: generic
  • Submitted: 2007-03-27
  • Updated: 2010-08-19
  • Resolved: 2007-03-27
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 7
7Resolved
Related Reports
Duplicate :  
Relates :  
Description
When I run 32-bits VM with big heap:

% gamma -XX:+PrintClassHistogram -XX:+PrintGCDetails -Xmx2560m -Xmn2200m -Xss96k -XX:+UseParallelOldGC -cp jbb.jar:check.jar spec.jbb.JBBmain

(8 wh)
...
[GC [PSYoungGen: 2204336K->18528K(2221888K)] 2418083K->232275K(2484032K), 0.0577017 secs] [Times: user=0.19 sys=0.01, real=0.06 secs] 

jmap prints negative 'total' value when it prints all allocated objects:

% jdk7_b10/bin/jmap -histo 2343

num   #instances    #bytes  class name
--------------------------------------
  1:  13644309   1207024336  [C
  2:  12320807   295699368  java.lang.String
  3:  10506719   168107504  java.lang.Integer
  4:   4730636   151380352  java.math.BigDecimal
  5:     33085    79933360  [Lspec.jbb.History;
  6:   1035466    66269824  spec.jbb.Orderline
  7:   1431747    34363880  [Ljava.math.BigDecimal;
  8:     33500    30739640  [I
  9:   1795961    28735376  java.lang.StringBuilder
 10:     10989    10319960  [Ljava.lang.Object;
...
556:         1           8  java.lang.reflect.ReflectAccess
557:         1           8  sun.util.resources.LocaleData$LocaleDataResourceBundleControl
Total 48021840   -2126283712