Print this page
rev 7125 : 7176220: 'Full GC' events miss date stamp information occasionally
Summary: Move date stamp logic into GCTraceTime
Reviewed-by: brutisso, tschatzl

Split Split Close
Expand all
Collapse all
          --- old/hotspot/src/share/vm/memory/genCollectedHeap.cpp
          +++ new/hotspot/src/share/vm/memory/genCollectedHeap.cpp
↓ open down ↓ 376 lines elided ↑ open up ↑
 377  377  
 378  378    const size_t metadata_prev_used = MetaspaceAux::used_bytes();
 379  379  
 380  380    print_heap_before_gc();
 381  381  
 382  382    {
 383  383      FlagSetting fl(_is_gc_active, true);
 384  384  
 385  385      bool complete = full && (max_level == (n_gens()-1));
 386  386      const char* gc_cause_prefix = complete ? "Full GC" : "GC";
 387      -    gclog_or_tty->date_stamp(PrintGC && PrintGCDateStamps);
 388  387      TraceCPUTime tcpu(PrintGCDetails, true, gclog_or_tty);
 389  388      // The PrintGCDetails logging starts before we have incremented the GC id. We will do that later
 390  389      // so we can assume here that the next GC id is what we want.
 391  390      GCTraceTime t(GCCauseString(gc_cause_prefix, gc_cause()), PrintGCDetails, false, NULL, GCId::peek());
 392  391  
 393  392      gc_prologue(complete);
 394  393      increment_total_collections(complete);
 395  394  
 396  395      size_t gch_prev_used = used();
 397  396  
↓ open down ↓ 925 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX