Duplicate :
|
|
Duplicate :
|
|
Duplicate :
|
|
Duplicate :
|
RMI gc is supported by the CollectedHeap::millis_since_last_gc method. It should return the following: // Returns the longest time (in ms) that has elapsed since the last // time that any part of the heap was examined by a garbage collection. which means that the current method name for millis_since_last_gc() is misleading at least for generational collectors as it must not be updated for all "last" gcs, but only for ones matching the description. Looking at the implementations across collectors, there is also lots of code duplication going on. In principle it would be sufficient to implement most of it in CollectedHeap: it could keep track of the last time the above condition held true, and the collectors only notify if/when a newer point in time the millis_since_last_gc condition occurs. Suggested by [~kbarrett] in the review chain leading to JDK-8248221.
|