class com.sun.tools.hat.internal.server.InstancesCountQuery extends com.sun.tools.hat.internal.server.QueryHandler
minor version: 0
major version: 59
flags: flags: (0x0020) ACC_SUPER
this_class: com.sun.tools.hat.internal.server.InstancesCountQuery
super_class: com.sun.tools.hat.internal.server.QueryHandler
{
private boolean excludePlatform;
descriptor: Z
flags: (0x0002) ACC_PRIVATE
public void <init>(boolean);
descriptor: (Z)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 // com.sun.tools.hat.internal.server.InstancesCountQuery this
start local 1 // boolean excludePlatform
0: .line 51
aload 0 /* this */
invokespecial com.sun.tools.hat.internal.server.QueryHandler.<init>:()V
1: .line 52
aload 0 /* this */
iload 1 /* excludePlatform */
putfield com.sun.tools.hat.internal.server.InstancesCountQuery.excludePlatform:Z
2: .line 53
return
end local 1 // boolean excludePlatform
end local 0 // com.sun.tools.hat.internal.server.InstancesCountQuery this
LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lcom/sun/tools/hat/internal/server/InstancesCountQuery;
0 3 1 excludePlatform Z
MethodParameters:
Name Flags
excludePlatform
public void run();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=12, args_size=1
start local 0 // com.sun.tools.hat.internal.server.InstancesCountQuery this
0: .line 56
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.excludePlatform:Z
ifeq 3
1: .line 57
aload 0 /* this */
ldc "Instance Counts for All Classes (excluding platform)"
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.startHtml:(Ljava/lang/String;)V
2: .line 58
goto 4
3: .line 59
StackMap locals:
StackMap stack:
aload 0 /* this */
ldc "Instance Counts for All Classes (including platform)"
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.startHtml:(Ljava/lang/String;)V
4: .line 62
StackMap locals:
StackMap stack:
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.snapshot:Lcom/sun/tools/hat/internal/model/Snapshot;
invokevirtual com.sun.tools.hat.internal.model.Snapshot.getClassesArray:()[Lcom/sun/tools/hat/internal/model/JavaClass;
astore 1 /* classes */
start local 1 // com.sun.tools.hat.internal.model.JavaClass[] classes
5: .line 63
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.excludePlatform:Z
ifeq 16
6: .line 64
iconst_0
istore 2 /* num */
start local 2 // int num
7: .line 65
iconst_0
istore 3 /* i */
start local 3 // int i
8: goto 12
9: .line 66
StackMap locals: com.sun.tools.hat.internal.model.JavaClass[] int int
StackMap stack:
aload 1 /* classes */
iload 3 /* i */
aaload
invokestatic com.sun.tools.hat.internal.server.PlatformClasses.isPlatformClass:(Lcom/sun/tools/hat/internal/model/JavaClass;)Z
ifne 11
10: .line 67
aload 1 /* classes */
iload 2 /* num */
iinc 2 /* num */ 1
aload 1 /* classes */
iload 3 /* i */
aaload
aastore
11: .line 65
StackMap locals:
StackMap stack:
iinc 3 /* i */ 1
StackMap locals:
StackMap stack:
12: iload 3 /* i */
aload 1 /* classes */
arraylength
if_icmplt 9
end local 3 // int i
13: .line 70
iload 2 /* num */
anewarray com.sun.tools.hat.internal.model.JavaClass
astore 3 /* tmp */
start local 3 // com.sun.tools.hat.internal.model.JavaClass[] tmp
14: .line 71
aload 1 /* classes */
iconst_0
aload 3 /* tmp */
iconst_0
aload 3 /* tmp */
arraylength
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
15: .line 72
aload 3 /* tmp */
astore 1 /* classes */
end local 3 // com.sun.tools.hat.internal.model.JavaClass[] tmp
end local 2 // int num
16: .line 74
StackMap locals:
StackMap stack:
aload 1 /* classes */
new com.sun.tools.hat.internal.server.InstancesCountQuery$1
dup
aload 0 /* this */
invokespecial com.sun.tools.hat.internal.server.InstancesCountQuery$1.<init>:(Lcom/sun/tools/hat/internal/server/InstancesCountQuery;)V
invokestatic com.sun.tools.hat.internal.util.ArraySorter.sort:([Ljava/lang/Object;Lcom/sun/tools/hat/internal/util/Comparer;)V
17: .line 98
lconst_0
lstore 2 /* totalSize */
start local 2 // long totalSize
18: .line 99
lconst_0
lstore 4 /* instances */
start local 4 // long instances
19: .line 100
iconst_0
istore 6 /* i */
start local 6 // int i
20: goto 52
21: .line 101
StackMap locals: long long int
StackMap stack:
aload 1 /* classes */
iload 6 /* i */
aaload
astore 7 /* clazz */
start local 7 // com.sun.tools.hat.internal.model.JavaClass clazz
22: .line 102
aload 7 /* clazz */
iconst_0
invokevirtual com.sun.tools.hat.internal.model.JavaClass.getInstancesCount:(Z)I
istore 8 /* count */
start local 8 // int count
23: .line 103
aload 0 /* this */
new java.lang.StringBuilder
dup
invokespecial java.lang.StringBuilder.<init>:()V
iload 8 /* count */
invokevirtual java.lang.StringBuilder.append:(I)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
24: .line 104
aload 0 /* this */
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.printAnchorStart:()V
25: .line 105
aload 0 /* this */
new java.lang.StringBuilder
dup
ldc "instances/"
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 0 /* this */
aload 1 /* classes */
iload 6 /* i */
aaload
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.encodeForURL:(Lcom/sun/tools/hat/internal/model/JavaClass;)Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
26: .line 106
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "\"> "
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
27: .line 107
iload 8 /* count */
iconst_1
if_icmpne 30
28: .line 108
aload 0 /* this */
ldc "instance"
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
29: .line 109
goto 31
30: .line 110
StackMap locals: com.sun.tools.hat.internal.model.JavaClass int
StackMap stack:
aload 0 /* this */
ldc "instances"
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
31: .line 112
StackMap locals:
StackMap stack:
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "</a> "
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
32: .line 113
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.snapshot:Lcom/sun/tools/hat/internal/model/Snapshot;
invokevirtual com.sun.tools.hat.internal.model.Snapshot.getHasNewSet:()Z
ifeq 46
33: .line 114
aload 7 /* clazz */
iconst_0
invokevirtual com.sun.tools.hat.internal.model.JavaClass.getInstances:(Z)Ljava/util/Enumeration;
astore 9 /* objects */
start local 9 // java.util.Enumeration objects
34: .line 115
iconst_0
istore 10 /* newInst */
start local 10 // int newInst
35: .line 116
goto 39
36: .line 117
StackMap locals: java.util.Enumeration int
StackMap stack:
aload 9 /* objects */
invokeinterface java.util.Enumeration.nextElement:()Ljava/lang/Object;
checkcast com.sun.tools.hat.internal.model.JavaHeapObject
astore 11 /* obj */
start local 11 // com.sun.tools.hat.internal.model.JavaHeapObject obj
37: .line 118
aload 11 /* obj */
invokevirtual com.sun.tools.hat.internal.model.JavaHeapObject.isNew:()Z
ifeq 39
38: .line 119
iinc 10 /* newInst */ 1
end local 11 // com.sun.tools.hat.internal.model.JavaHeapObject obj
39: .line 116
StackMap locals:
StackMap stack:
aload 9 /* objects */
invokeinterface java.util.Enumeration.hasMoreElements:()Z
ifne 36
40: .line 122
aload 0 /* this */
ldc "("
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
41: .line 123
aload 0 /* this */
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.printAnchorStart:()V
42: .line 124
aload 0 /* this */
new java.lang.StringBuilder
dup
ldc "newInstances/"
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 0 /* this */
aload 1 /* classes */
iload 6 /* i */
aaload
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.encodeForURL:(Lcom/sun/tools/hat/internal/model/JavaClass;)Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
43: .line 125
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "\">"
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
44: .line 126
aload 0 /* this */
new java.lang.StringBuilder
dup
invokespecial java.lang.StringBuilder.<init>:()V
iload 10 /* newInst */
invokevirtual java.lang.StringBuilder.append:(I)Ljava/lang/StringBuilder;
ldc " new"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
45: .line 127
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "</a>) "
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
end local 10 // int newInst
end local 9 // java.util.Enumeration objects
46: .line 129
StackMap locals:
StackMap stack:
aload 0 /* this */
ldc "of "
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
47: .line 130
aload 0 /* this */
aload 1 /* classes */
iload 6 /* i */
aaload
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.printClass:(Lcom/sun/tools/hat/internal/model/JavaClass;)V
48: .line 131
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "<br>"
invokevirtual java.io.PrintWriter.println:(Ljava/lang/String;)V
49: .line 132
lload 4 /* instances */
iload 8 /* count */
i2l
ladd
lstore 4 /* instances */
50: .line 133
lload 2 /* totalSize */
aload 1 /* classes */
iload 6 /* i */
aaload
invokevirtual com.sun.tools.hat.internal.model.JavaClass.getTotalInstanceSize:()J
ladd
lstore 2 /* totalSize */
end local 8 // int count
end local 7 // com.sun.tools.hat.internal.model.JavaClass clazz
51: .line 100
iinc 6 /* i */ 1
StackMap locals:
StackMap stack:
52: iload 6 /* i */
aload 1 /* classes */
arraylength
if_icmplt 21
end local 6 // int i
53: .line 135
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
new java.lang.StringBuilder
dup
ldc "<h2>Total of "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
lload 4 /* instances */
invokevirtual java.lang.StringBuilder.append:(J)Ljava/lang/StringBuilder;
ldc " instances occupying "
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
lload 2 /* totalSize */
invokevirtual java.lang.StringBuilder.append:(J)Ljava/lang/StringBuilder;
ldc " bytes.</h2>"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokevirtual java.io.PrintWriter.println:(Ljava/lang/String;)V
54: .line 137
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "<h2>Other Queries</h2>"
invokevirtual java.io.PrintWriter.println:(Ljava/lang/String;)V
55: .line 138
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "<ul>"
invokevirtual java.io.PrintWriter.println:(Ljava/lang/String;)V
56: .line 140
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "<li>"
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
57: .line 141
aload 0 /* this */
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.printAnchorStart:()V
58: .line 142
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.excludePlatform:Z
ifne 62
59: .line 143
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "showInstanceCounts/\">"
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
60: .line 144
aload 0 /* this */
ldc "Show instance counts for all classes (excluding platform)"
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
61: .line 145
goto 64
62: .line 146
StackMap locals:
StackMap stack:
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "showInstanceCounts/includePlatform/\">"
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
63: .line 147
aload 0 /* this */
ldc "Show instance counts for all classes (including platform)"
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
64: .line 149
StackMap locals:
StackMap stack:
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "</a>"
invokevirtual java.io.PrintWriter.println:(Ljava/lang/String;)V
65: .line 151
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "<li>"
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
66: .line 152
aload 0 /* this */
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.printAnchorStart:()V
67: .line 153
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "allClassesWithPlatform/\">"
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
68: .line 154
aload 0 /* this */
ldc "Show All Classes (including platform)"
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
69: .line 155
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "</a>"
invokevirtual java.io.PrintWriter.println:(Ljava/lang/String;)V
70: .line 157
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "<li>"
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
71: .line 158
aload 0 /* this */
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.printAnchorStart:()V
72: .line 159
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "\">"
invokevirtual java.io.PrintWriter.print:(Ljava/lang/String;)V
73: .line 160
aload 0 /* this */
ldc "Show All Classes (excluding platform)"
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.print:(Ljava/lang/String;)V
74: .line 161
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "</a>"
invokevirtual java.io.PrintWriter.println:(Ljava/lang/String;)V
75: .line 163
aload 0 /* this */
getfield com.sun.tools.hat.internal.server.InstancesCountQuery.out:Ljava/io/PrintWriter;
ldc "</ul>"
invokevirtual java.io.PrintWriter.println:(Ljava/lang/String;)V
76: .line 165
aload 0 /* this */
invokevirtual com.sun.tools.hat.internal.server.InstancesCountQuery.endHtml:()V
77: .line 166
return
end local 4 // long instances
end local 2 // long totalSize
end local 1 // com.sun.tools.hat.internal.model.JavaClass[] classes
end local 0 // com.sun.tools.hat.internal.server.InstancesCountQuery this
LocalVariableTable:
Start End Slot Name Signature
0 78 0 this Lcom/sun/tools/hat/internal/server/InstancesCountQuery;
5 78 1 classes [Lcom/sun/tools/hat/internal/model/JavaClass;
7 16 2 num I
8 13 3 i I
14 16 3 tmp [Lcom/sun/tools/hat/internal/model/JavaClass;
18 78 2 totalSize J
19 78 4 instances J
20 53 6 i I
22 51 7 clazz Lcom/sun/tools/hat/internal/model/JavaClass;
23 51 8 count I
34 46 9 objects Ljava/util/Enumeration;
35 46 10 newInst I
37 39 11 obj Lcom/sun/tools/hat/internal/model/JavaHeapObject;
}
SourceFile: "InstancesCountQuery.java"
NestMembers:
com.sun.tools.hat.internal.server.InstancesCountQuery$1
InnerClasses:
com.sun.tools.hat.internal.server.InstancesCountQuery$1