Skip to content

Commit 7534985

Browse files
committed
8230024: Shenandoah: remove unnecessary ShenandoahTimingConverter
Reviewed-by: rkennke, zgu
1 parent 682c25b commit 7534985

File tree

2 files changed

+0
-55
lines changed

2 files changed

+0
-55
lines changed

src/hotspot/share/gc/shenandoah/shenandoahUtils.cpp

Lines changed: 0 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -184,47 +184,3 @@ ShenandoahWorkerSession::~ShenandoahWorkerSession() {
184184
ShenandoahThreadLocalData::set_worker_id(thr, ShenandoahThreadLocalData::INVALID_WORKER_ID);
185185
#endif
186186
}
187-
188-
struct PhaseMap {
189-
WeakProcessorPhases::Phase _weak_processor_phase;
190-
ShenandoahPhaseTimings::GCParPhases _shenandoah_phase;
191-
};
192-
193-
static const struct PhaseMap phase_mapping[] = {
194-
#if INCLUDE_JVMTI
195-
{WeakProcessorPhases::jvmti, ShenandoahPhaseTimings::JVMTIWeakRoots},
196-
#endif
197-
#if INCLUDE_JFR
198-
{WeakProcessorPhases::jfr, ShenandoahPhaseTimings::JFRWeakRoots},
199-
#endif
200-
{WeakProcessorPhases::jni, ShenandoahPhaseTimings::JNIWeakRoots},
201-
{WeakProcessorPhases::stringtable, ShenandoahPhaseTimings::StringTableRoots},
202-
{WeakProcessorPhases::resolved_method_table, ShenandoahPhaseTimings::ResolvedMethodTableRoots},
203-
{WeakProcessorPhases::vm, ShenandoahPhaseTimings::VMWeakRoots}
204-
};
205-
206-
STATIC_ASSERT(sizeof(phase_mapping) / sizeof(PhaseMap) == WeakProcessorPhases::phase_count);
207-
208-
void ShenandoahTimingConverter::weak_processing_timing_to_shenandoah_timing(WeakProcessorPhaseTimes* weak_processing_timings,
209-
ShenandoahWorkerTimings* sh_worker_times) {
210-
assert(weak_processing_timings->max_threads() == weak_processing_timings->max_threads(), "Must match");
211-
for (uint index = 0; index < WeakProcessorPhases::phase_count; index ++) {
212-
weak_processing_phase_to_shenandoah_phase(phase_mapping[index]._weak_processor_phase,
213-
weak_processing_timings,
214-
phase_mapping[index]._shenandoah_phase,
215-
sh_worker_times);
216-
}
217-
}
218-
219-
void ShenandoahTimingConverter::weak_processing_phase_to_shenandoah_phase(WeakProcessorPhases::Phase wpp,
220-
WeakProcessorPhaseTimes* weak_processing_timings,
221-
ShenandoahPhaseTimings::GCParPhases spp,
222-
ShenandoahWorkerTimings* sh_worker_times) {
223-
if (WeakProcessorPhases::is_serial(wpp)) {
224-
sh_worker_times->record_time_secs(spp, 0, weak_processing_timings->phase_time_sec(wpp));
225-
} else {
226-
for (uint index = 0; index < weak_processing_timings->max_threads(); index ++) {
227-
sh_worker_times->record_time_secs(spp, index, weak_processing_timings->worker_time_sec(index, wpp));
228-
}
229-
}
230-
}

src/hotspot/share/gc/shenandoah/shenandoahUtils.hpp

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -175,15 +175,4 @@ class ShenandoahSuspendibleThreadSetLeaver {
175175
}
176176
};
177177

178-
class ShenandoahTimingConverter : public AllStatic {
179-
public:
180-
static void weak_processing_timing_to_shenandoah_timing(WeakProcessorPhaseTimes* weak_processing_timings,
181-
ShenandoahWorkerTimings* sh_worker_times);
182-
private:
183-
static void weak_processing_phase_to_shenandoah_phase(WeakProcessorPhases::Phase wpp,
184-
WeakProcessorPhaseTimes* weak_processing_timings,
185-
ShenandoahPhaseTimings::GCParPhases spp,
186-
ShenandoahWorkerTimings* sh_worker_times);
187-
};
188-
189178
#endif // SHARE_GC_SHENANDOAH_SHENANDOAHUTILS_HPP

0 commit comments

Comments
 (0)