/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*
*/
#include "memory/allocation.hpp"
#include "gc_interface/gcCause.hpp"
template <class T>
T* _data;
const char* _print_format;
bool _print_sum;
NOT_PRODUCT(static const T _uninitialized;)
// We are caching the sum and average to only have to calculate them once.
// This is not done in an MT-safe way. It is intended to allow single
// threaded code to call sum() and average() multiple times in any order
// without having to worry about the cost.
bool _has_new_data;
T _sum;
double _average;
public:
}
~WorkerDataArray() {
}
_has_new_data = true;
}
}
_has_new_data = true;
}
double average(){
if (_has_new_data) {
}
return _average;
}
T sum() {
if (_has_new_data) {
}
return _sum;
}
void reset() PRODUCT_RETURN;
void verify() PRODUCT_RETURN;
private:
void calculate_totals(){
_sum = (T)0;
}
_has_new_data = false;
}
};
private:
double _cur_collection_par_time_ms;
double _cur_clear_ct_time_ms;
double _cur_ref_proc_time_ms;
double _cur_ref_enq_time_ms;
double _cur_collection_start_sec;
double _root_region_scan_wait_time_ms;
double _cur_verify_before_time_ms;
double _cur_verify_after_time_ms;
// Helper methods for detailed logging
public:
void note_gc_end();
void print(double pause_time_sec);
}
}
}
}
}
}
}
}
}
}
void record_clear_ct_time(double ms) {
}
void record_par_time(double ms) {
}
void record_code_root_fixup_time(double ms) {
}
void record_ref_proc_time(double ms) {
}
void record_ref_enq_time(double ms) {
}
void record_root_region_scan_wait_time(double time_ms) {
}
void record_young_free_cset_time_ms(double time_ms) {
}
void record_non_young_free_cset_time_ms(double time_ms) {
}
void record_young_cset_choice_time_ms(double time_ms) {
}
void record_non_young_cset_choice_time_ms(double time_ms) {
}
void record_cur_collection_start_sec(double time_ms) {
}
void record_verify_before_time_ms(double time_ms) {
}
void record_verify_after_time_ms(double time_ms) {
}
double accounted_time_ms();
double cur_collection_start_sec() {
return _cur_collection_start_sec;
}
double cur_collection_par_time_ms() {
return _cur_collection_par_time_ms;
}
double cur_clear_ct_time_ms() {
return _cur_clear_ct_time_ms;
}
double root_region_scan_wait_time_ms() {
return _root_region_scan_wait_time_ms;
}
double young_cset_choice_time_ms() {
}
double young_free_cset_time_ms() {
}
double non_young_cset_choice_time_ms() {
}
double non_young_free_cset_time_ms() {
}
double average_last_update_rs_time() {
return _last_update_rs_times_ms.average();
}
return _last_update_rs_processed_buffers.sum();
}
double average_last_scan_rs_time(){
return _last_scan_rs_times_ms.average();
}
double average_last_obj_copy_time() {
return _last_obj_copy_times_ms.average();
}
double average_last_termination_time() {
return _last_termination_times_ms.average();
}
double average_last_ext_root_scan_time() {
return _last_ext_root_scan_times_ms.average();
}
double average_last_satb_filtering_times_ms() {
return _last_satb_filtering_times_ms.average();
}
};
#endif // SHARE_VM_GC_IMPLEMENTATION_G1_G1GCPHASETIMESLOG_HPP