Mercurial > hg > graal-jvmci-8
annotate test/gc/g1/TestG1TraceEagerReclaimHumongousObjects.java @ 24234:ea6f94ab283b default tip
Added tag jvmci-0.36 for changeset 8128b98d4736
author | Gilles Duboscq <gilles.m.duboscq@oracle.com> |
---|---|
date | Mon, 18 Sep 2017 18:49:45 +0200 |
parents | cbc7c4c9e11c |
children |
rev | line source |
---|---|
23024
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
1 /* |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
2 * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
4 * |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
5 * This code is free software; you can redistribute it and/or modify it |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
6 * under the terms of the GNU General Public License version 2 only, as |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
7 * published by the Free Software Foundation. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
8 * |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
9 * This code is distributed in the hope that it will be useful, but WITHOUT |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
12 * version 2 for more details (a copy is included in the LICENSE file that |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
13 * accompanied this code). |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
14 * |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
15 * You should have received a copy of the GNU General Public License version |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
16 * 2 along with this work; if not, write to the Free Software Foundation, |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
18 * |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
20 * or visit www.oracle.com if you need additional information or have any |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
21 * questions. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
22 */ |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
23 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
24 /* |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
25 * @test TestG1TraceEagerReclaimHumongousObjects |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
26 * @bug 8058801 8048179 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
27 * @summary Ensure that the output for a G1TraceEagerReclaimHumongousObjects |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
28 * includes the expected necessary messages. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
29 * @key gc |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
30 * @library /testlibrary |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
31 */ |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
32 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
33 import com.oracle.java.testlibrary.ProcessTools; |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
34 import com.oracle.java.testlibrary.OutputAnalyzer; |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
35 import java.util.LinkedList; |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
36 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
37 public class TestG1TraceEagerReclaimHumongousObjects { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
38 public static void main(String[] args) throws Exception { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
39 testGCLogs(); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
40 testHumongousObjectGCLogs(); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
41 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
42 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
43 private static void testGCLogs() throws Exception { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
44 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
45 ProcessBuilder pb = ProcessTools.createJavaProcessBuilder("-XX:+UseG1GC", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
46 "-Xms128M", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
47 "-Xmx128M", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
48 "-Xmn16M", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
49 "-XX:G1HeapRegionSize=1M", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
50 "-XX:+PrintGC", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
51 "-XX:+UnlockExperimentalVMOptions", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
52 "-XX:G1LogLevel=finest", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
53 "-XX:+G1TraceEagerReclaimHumongousObjects", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
54 GCTest.class.getName()); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
55 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
56 OutputAnalyzer output = new OutputAnalyzer(pb.start()); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
57 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
58 // As G1EagerReclaimHumongousObjects is set(default), below logs should be displayed. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
59 // And GCTest doesn't have humongous objects, so values should be zero. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
60 output.shouldContain("[Humongous Reclaim"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
61 output.shouldContain("[Humongous Total: 0]"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
62 output.shouldContain("[Humongous Candidate: 0]"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
63 output.shouldContain("[Humongous Reclaimed: 0]"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
64 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
65 output.shouldHaveExitValue(0); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
66 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
67 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
68 private static void testHumongousObjectGCLogs() throws Exception { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
69 ProcessBuilder pb = ProcessTools.createJavaProcessBuilder("-XX:+UseG1GC", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
70 "-Xms128M", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
71 "-Xmx128M", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
72 "-Xmn16M", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
73 "-XX:G1HeapRegionSize=1M", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
74 "-XX:+PrintGC", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
75 "-XX:+UnlockExperimentalVMOptions", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
76 "-XX:G1LogLevel=finest", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
77 "-XX:+G1TraceEagerReclaimHumongousObjects", |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
78 GCWithHumongousObjectTest.class.getName()); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
79 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
80 OutputAnalyzer output = new OutputAnalyzer(pb.start()); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
81 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
82 // As G1ReclaimDeadHumongousObjectsAtYoungGC is set(default), below logs should be displayed. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
83 output.shouldContain("[Humongous Reclaim"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
84 output.shouldContain("[Humongous Total"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
85 output.shouldContain("[Humongous Candidate"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
86 output.shouldContain("[Humongous Reclaimed"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
87 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
88 // As G1TraceReclaimDeadHumongousObjectsAtYoungGC is set and GCWithHumongousObjectTest has humongous objects, |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
89 // these logs should be displayed. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
90 output.shouldContain("Live humongous"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
91 output.shouldContain("Dead humongous region"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
92 output.shouldHaveExitValue(0); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
93 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
94 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
95 static class GCTest { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
96 private static byte[] garbage; |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
97 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
98 public static void main(String [] args) { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
99 System.out.println("Creating garbage"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
100 // create 128MB of garbage. This should result in at least one GC |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
101 for (int i = 0; i < 1024; i++) { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
102 garbage = new byte[128 * 1024]; |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
103 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
104 System.out.println("Done"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
105 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
106 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
107 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
108 static class GCWithHumongousObjectTest { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
109 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
110 public static final int M = 1024*1024; |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
111 public static LinkedList<Object> garbageList = new LinkedList<Object>(); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
112 // A large object referenced by a static. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
113 static int[] filler = new int[10 * M]; |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
114 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
115 public static void genGarbage() { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
116 for (int i = 0; i < 32*1024; i++) { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
117 garbageList.add(new int[100]); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
118 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
119 garbageList.clear(); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
120 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
121 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
122 public static void main(String[] args) { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
123 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
124 int[] large = new int[M]; |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
125 Object ref = large; |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
126 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
127 System.out.println("Creating garbage"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
128 for (int i = 0; i < 100; i++) { |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
129 // A large object that will be reclaimed eagerly. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
130 large = new int[6*M]; |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
131 genGarbage(); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
132 // Make sure that the compiler cannot completely remove |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
133 // the allocation of the large object until here. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
134 System.out.println(large); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
135 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
136 |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
137 // Keep the reference to the first object alive. |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
138 System.out.println(ref); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
139 System.out.println("Done"); |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
140 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
141 } |
cbc7c4c9e11c
8048179: Early reclaim of large objects that are referenced by a few objects
tschatzl
parents:
diff
changeset
|
142 } |