RFR: Use distinct "end of cycle" message for each Shenandoah pause [v2]
Y. Srinivas Ramakrishna
ysr at openjdk.org
Wed May 3 01:54:55 UTC 2023
On Tue, 2 May 2023 23:24:51 GMT, William Kemper <wkemper at openjdk.org> wrote:
>> This change allows the `GarbageCollectionNotificationInfo::gcAction` to be overridden. Shenandoah now uses this to distinguish the notification raised for each of the pauses during the concurrent cycle. This will make it easier for monitoring software to identify which phases may be having longer than expected pauses.
>
> William Kemper has updated the pull request incrementally with one additional commit since the last revision:
>
> Move region aging into op_final_roots
LGTM.
src/hotspot/share/gc/shenandoah/shenandoahVMOperations.cpp line 52:
> 50:
> 51: void VM_ShenandoahInitMark::doit() {
> 52: ShenandoahGCPauseMark mark(_gc_id, "Init Mark", SvcGCMarker::CONCURRENT);
Not your code, but I am curious how the 3rd argument "reason_type" `{MINOR, FULL, CONCURRENT}` is even ever used. I saw it dutifully passed around and eventually get used only to check whether it was `== FULL` or not, down in `VM_GC_Operation::notify_gc_begin`.
src/hotspot/share/services/memoryManager.cpp line 297:
> 295: if (is_notification_enabled()) {
> 296: const char* message = notificationMessage != nullptr ? notificationMessage : _gc_end_message;
> 297: GCNotifier::pushNotification(this, message, GCCause::to_string(cause));
This looks great to me. I am assuming all collectors that do their work in multiple pieces (at least ZGC and possibly G1 too) might want to make use of this functionality.
I am guessing this might benefit from an upstream review at some point.
-------------
Marked as reviewed by ysr (Author).
PR Review: https://git.openjdk.org/shenandoah/pull/270#pullrequestreview-1410061490
PR Review Comment: https://git.openjdk.org/shenandoah/pull/270#discussion_r1183169848
PR Review Comment: https://git.openjdk.org/shenandoah/pull/270#discussion_r1183179079
More information about the shenandoah-dev
mailing list