RFR (XXS) JDK-8164124,The fix for JDK-8071770 incorrectly uses os::elapsed_counter()
Jon Masamitsu
jon.masamitsu at oracle.com
Tue Aug 16 18:35:43 UTC 2016
Joe,
"last" seems to get its value from elapsedTime() (through
last_known_gc_end_time_sec()
from _prev_collection_pause_end_ms in G1Analytics).
2479 double last = analytics->last_known_gc_end_time_sec();
for example
> void G1DefaultPolicy::record_full_collection_end() {
> // Consider this like a collection pause for the purposes of allocation
> // since last pause.
> double end_sec = os::elapsedTime();
> double full_gc_time_sec = end_sec - _full_collection_start_sec;
> double full_gc_time_ms = full_gc_time_sec * 1000.0;
>
> _analytics->update_recent_gc_times(end_sec, full_gc_time_ms);
Should "now" use elapsedTime()?
Jon
On 8/16/2016 11:20 AM, Joseph Provino wrote:
>
> Please review this one line change:
>
> jlong G1CollectedHeap::millis_since_last_gc() {
>
> This: jlong now = os::elapsed_counter() / NANOSECS_PER_MILLISEC;
>
> Should be: jlong now = os::javaTimeNanos() / NANOSECS_PER_MILLISEC;
>
> CR: JDK-8164124 <https://bugs.openjdk.java.net/browse/JDK-8164124> The
> fix for JDK-8071770 incorrectly uses os::elapsed_counter()
>
> Webrev: http://cr.openjdk.java.net/~jprovino/8164124/webrev.00
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/hotspot-gc-dev/attachments/20160816/a43e927c/attachment.htm>
More information about the hotspot-gc-dev
mailing list