--- a/src/hotspot/share/jfr/recorder/repository/jfrChunk.cpp Tue Sep 10 09:21:23 2019 -0700
+++ b/src/hotspot/share/jfr/recorder/repository/jfrChunk.cpp Wed Sep 11 13:31:52 2019 +0200
@@ -120,7 +120,7 @@
_start_nanos = _last_update_nanos = nanos_now();
}
-void JfrChunk::update_current_time() {
+void JfrChunk::update_current_nanos() {
_last_update_nanos = nanos_now();
}
--- a/src/hotspot/share/jfr/recorder/repository/jfrChunk.hpp Tue Sep 10 09:21:23 2019 -0700
+++ b/src/hotspot/share/jfr/recorder/repository/jfrChunk.hpp Wed Sep 11 13:31:52 2019 +0200
@@ -71,7 +71,7 @@
int64_t last_chunk_duration() const;
void set_time_stamp();
- void update_current_time();
+ void update_current_nanos();
void set_path(const char* path);
const char* path() const;
--- a/src/hotspot/share/jfr/recorder/repository/jfrChunkWriter.cpp Tue Sep 10 09:21:23 2019 -0700
+++ b/src/hotspot/share/jfr/recorder/repository/jfrChunkWriter.cpp Wed Sep 11 13:31:52 2019 +0200
@@ -164,6 +164,8 @@
_writer->seek(GENERATION_OFFSET);
write_guard();
_writer->seek(offset);
+ } else {
+ _chunk->update_current_nanos();
}
}
DEBUG_ONLY(assert_writer_position(_writer, offset);)
@@ -212,9 +214,6 @@
int64_t JfrChunkWriter::flush_chunk(bool flushpoint) {
assert(_chunk != NULL, "invariant");
- if (flushpoint) {
- _chunk->update_current_time();
- }
const int64_t sz_written = write_chunk_header_checkpoint(flushpoint);
assert(size_written() == sz_written, "invariant");
JfrChunkHeadWriter head(this, SIZE_OFFSET);