4 Matching Annotations
  1. Aug 2023
    1. G1's goals in the default configuration are neither maximum throughput nor lowest latency, but to provide relatively small, uniform pauses at high throughput.

      G1在默认配置下的目标既不是最大吞吐量,也不是最低延迟,而是在高吞吐量下提供相对较小且均匀的暂停时间。

    2. On a high level, the G1 collector alternates between two phases. The young-only phase contains garbage collections that fill up the currently available memory with objects in the old generation gradually. The space-reclamation phase is where G1 reclaims space in the old generation incrementally, in addition to handling the young generation. Then the cycle restarts with a young-only phase.

      在高级别上,G1收集器在两个阶段之间交替进行。仅年轻代阶段包含垃圾回收,逐渐将当前可用内存中的对象填满到老年代。空间回收阶段是G1增量式地回收老年代空间,并处理年轻代。然后循环重新开始,进入仅年轻代阶段。

    3. G1 garbage collection pauses can reclaim space in the young generation as a whole, and any additional set of old generation regions at any collection pause. During the pause G1 copies objects from this collection set to one or more different regions in the heap. The destination region for an object depends on the source region of that object: the entire young generation is copied into either survivor or old regions, and objects from old regions to other, different old regions using aging.

      G1垃圾收集暂停可以在整个年轻代中回收空间,并且在任何收集暂停时,还可以额外设置一组老年代区域。在暂停期间,G1将对象从此收集集合复制到堆中的一个或多个不同区域。对象的目标区域取决于该对象的源区域:整个年轻代被复制到幸存者或老年代区域中,而来自老年代的对象则使用老化机制被复制到其他不同的老年代区域。