Mercurial > hg > graal-jvmci-8
comparison src/share/vm/gc_implementation/g1/g1MarkSweep.cpp @ 17764:595c0f60d50d
8029075: String deduplication in G1
Summary: Implementation of JEP 192, http://openjdk.java.net/jeps/192
Reviewed-by: brutisso, tschatzl, coleenp
author | pliden |
---|---|
date | Tue, 18 Mar 2014 19:07:22 +0100 |
parents | 58fc1b1523dc |
children | 52b4284cb496 0982ec23da03 |
comparison
equal
deleted
inserted
replaced
17763:6e7e363c5a8f | 17764:595c0f60d50d |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved. | 2 * Copyright (c) 2001, 2014, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. | 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * | 4 * |
5 * This code is free software; you can redistribute it and/or modify it | 5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as | 6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
29 #include "classfile/vmSymbols.hpp" | 29 #include "classfile/vmSymbols.hpp" |
30 #include "code/codeCache.hpp" | 30 #include "code/codeCache.hpp" |
31 #include "code/icBuffer.hpp" | 31 #include "code/icBuffer.hpp" |
32 #include "gc_implementation/g1/g1Log.hpp" | 32 #include "gc_implementation/g1/g1Log.hpp" |
33 #include "gc_implementation/g1/g1MarkSweep.hpp" | 33 #include "gc_implementation/g1/g1MarkSweep.hpp" |
34 #include "gc_implementation/g1/g1StringDedup.hpp" | |
34 #include "gc_implementation/shared/gcHeapSummary.hpp" | 35 #include "gc_implementation/shared/gcHeapSummary.hpp" |
35 #include "gc_implementation/shared/gcTimer.hpp" | 36 #include "gc_implementation/shared/gcTimer.hpp" |
36 #include "gc_implementation/shared/gcTrace.hpp" | 37 #include "gc_implementation/shared/gcTrace.hpp" |
37 #include "gc_implementation/shared/gcTraceTime.hpp" | 38 #include "gc_implementation/shared/gcTraceTime.hpp" |
38 #include "memory/gcLocker.hpp" | 39 #include "memory/gcLocker.hpp" |
318 | 319 |
319 // Now adjust pointers in remaining weak roots. (All of which should | 320 // Now adjust pointers in remaining weak roots. (All of which should |
320 // have been cleared if they pointed to non-surviving objects.) | 321 // have been cleared if they pointed to non-surviving objects.) |
321 g1h->g1_process_weak_roots(&GenMarkSweep::adjust_pointer_closure); | 322 g1h->g1_process_weak_roots(&GenMarkSweep::adjust_pointer_closure); |
322 | 323 |
324 if (G1StringDedup::is_enabled()) { | |
325 G1StringDedup::oops_do(&GenMarkSweep::adjust_pointer_closure); | |
326 } | |
327 | |
323 GenMarkSweep::adjust_marks(); | 328 GenMarkSweep::adjust_marks(); |
324 | 329 |
325 G1AdjustPointersClosure blk; | 330 G1AdjustPointersClosure blk; |
326 g1h->heap_region_iterate(&blk); | 331 g1h->heap_region_iterate(&blk); |
327 } | 332 } |