Fast Conservative Garbage Collection

被引:0
作者
Shahriyar, Rifat [1 ]
Blackburn, Stephen M. [1 ]
McKinley, Kathryn S. [2 ]
机构
[1] Australian Natl Univ, Canberra, ACT 0200, Australia
[2] Microsoft Res, Raleigh, NC USA
关键词
Conservative; Reference Counting; Immix; Mark-Region; PERFORMANCE; LIVENESS; !text type='JAVA']JAVA[!/text;
D O I
10.1145/2714064.2660198
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Garbage collectors are exact or conservative. An exact collector identifies all references precisely and may move referents and update references, whereas a conservative collector treats one or more of stack, register, and heap references as ambiguous. Ambiguous references constrain collectors in two ways. (1) Since they may be pointers, the collectors must retain referents. (2) Since they may be values, the collectors cannot modify them, pinning their referents. We explore conservative collectors for managed languages, with ambiguous stacks and registers. We show that for Java benchmarks they retain and pin remarkably few heap objects: <0.01% are falsely retained and 0.03% are pinned. The larger effect is collector design. Prior conservative collectors (1) use mark-sweep and unnecessarily forgo moving all objects, or (2) use mostly copying and pin entire pages. Compared to generational collection, overheads are substantial: 12% and 45% respectively. We introduce high performance conservative Immix and reference counting (RC). Immix is a mark-region collector with fine line-grain pinning and opportunistic copying of unambiguous referents. Deferred RC simply needs an object map to deliver the first conservative RC. We implement six exact collectors and their conservative counterparts. Conservative Immix and RC come within 2 to 3% of their exact counterparts. In particular, conservative RC Immix is slightly faster than a well-tuned exact generational collector. These findings show that for managed languages, conservative collection is compatible with high performance.
引用
收藏
页码:121 / 139
页数:19
相关论文
共 37 条
  • [1] Garbage collection and local variable type-precision and liveness in Java']Java™ virtual machines
    Agesen, O
    Detlefs, D
    Moss, JEB
    [J]. ACM SIGPLAN NOTICES, 1998, 33 (05) : 269 - 279
  • [2] The Jikes research virtual machine project: Building an open-source research community
    Alpern, B
    Augart, S
    Blackburn, SM
    Butrico, M
    Cocchi, A
    Cheng, P
    Dolby, J
    Fink, S
    Grove, D
    Hind, M
    McKinley, KS
    Mergen, M
    Moss, JEB
    Ngo, T
    Sarkar, V
    Trapp, M
    [J]. IBM SYSTEMS JOURNAL, 2005, 44 (02) : 399 - 417
  • [3] [Anonymous], 2004, P JOINT INT C MEAS M
  • [4] Apple Inc, 2013, TRANS ARC REL NOT
  • [5] Apple Inc, 2014, SWIFT PROGR SER
  • [6] Attardi G., 1994, P 6 C USENIX 6 C TEC, V6, P8
  • [7] Bacon D. F., 2001, ECOOP 2001 - Object-Oriented Programming. 15th European Conference. Proceedings (Lecture Notes in Computer Science Vol.2072), P207
  • [8] Accurate garbage collection in uncooperative environments revisited
    Baker, J.
    Cunei, A.
    Kalibera, T.
    Pizlo, F.
    Vitek, J.
    [J]. CONCURRENCY AND COMPUTATION-PRACTICE & EXPERIENCE, 2009, 21 (12) : 1572 - 1606
  • [9] Bartlett J. F., 1988, SIGPLAN LISP POINTER, V1, P3, DOI DOI 10.1145/1317224.1317225
  • [10] Blackburn S. M., 2005, PJBB 2005 PSEUDOJBB