< prev index next >

src/hotspot/share/gc/z/zStat.cpp

Print this page

        

*** 759,770 **** // // Stat sample/inc // void ZStatSample(const ZStatSampler& sampler, uint64_t value) { ZStatSamplerData* const cpu_data = sampler.get(); ! Atomic::add(1u, &cpu_data->_nsamples); ! Atomic::add(value, &cpu_data->_sum); uint64_t max = cpu_data->_max; for (;;) { if (max >= value) { // Not max --- 759,770 ---- // // Stat sample/inc // void ZStatSample(const ZStatSampler& sampler, uint64_t value) { ZStatSamplerData* const cpu_data = sampler.get(); ! Atomic::add(&cpu_data->_nsamples, 1u); ! Atomic::add(&cpu_data->_sum, value); uint64_t max = cpu_data->_max; for (;;) { if (max >= value) { // Not max
*** 785,802 **** ZTracer::tracer()->report_stat_sampler(sampler, value); } void ZStatInc(const ZStatCounter& counter, uint64_t increment) { ZStatCounterData* const cpu_data = counter.get(); ! const uint64_t value = Atomic::add(increment, &cpu_data->_counter); ZTracer::tracer()->report_stat_counter(counter, increment, value); } void ZStatInc(const ZStatUnsampledCounter& counter, uint64_t increment) { ZStatCounterData* const cpu_data = counter.get(); ! Atomic::add(increment, &cpu_data->_counter); } // // Stat allocation rate // --- 785,802 ---- ZTracer::tracer()->report_stat_sampler(sampler, value); } void ZStatInc(const ZStatCounter& counter, uint64_t increment) { ZStatCounterData* const cpu_data = counter.get(); ! const uint64_t value = Atomic::add(&cpu_data->_counter, increment); ZTracer::tracer()->report_stat_counter(counter, increment, value); } void ZStatInc(const ZStatUnsampledCounter& counter, uint64_t increment) { ZStatCounterData* const cpu_data = counter.get(); ! Atomic::add(&cpu_data->_counter, increment); } // // Stat allocation rate //
< prev index next >