RFR: 8267133: jdk/jfr/event/gc/collection/TestG1ParallelPhases.java fails with Not expected phases: RestorePreservedMarks, RemoveSelfForwardingPtr: expected true, was false
Thomas Schatzl
tschatzl at openjdk.java.net
Mon May 17 12:45:37 UTC 2021
On Mon, 17 May 2021 11:57:06 GMT, Albert Mingkun Yang <ayang at openjdk.org> wrote:
> `RestorePreservedMarks`, and `RemoveSelfForwardingPtr` are conditionally emitted (only on evac failure). Updating the test to exclude these events in the assert.
>
>
> double G1GCPhaseTimes::print_post_evacuate_collection_set() const {
> ...
> debug_phase(_gc_par_phases[RecalculateUsed], 1);
> if (G1CollectedHeap::heap()->evacuation_failed()) {
> debug_phase(_gc_par_phases[RemoveSelfForwardingPtr], 1);
> }
>
> debug_time("Post Evacuate Cleanup 2", _cur_post_evacuate_cleanup_2_time_ms);
> if (G1CollectedHeap::heap()->evacuation_failed()) {
> debug_phase(_gc_par_phases[RecalculateUsed], 1);
> debug_phase(_gc_par_phases[RestorePreservedMarks], 1);
> }
> ...
> }
>
>
> Tested: manually set a smaller heap size to see the test fail, but pass with the PR.
Lgtm.
Fwiw (for other reviewers), the evacuation failure phase events only now give problems because JDK-8214237 added them (in case of evac failure) but they were never posted before. Evac failure in this test is unreliable, so they are put into the `optPhases` list.
-------------
Marked as reviewed by tschatzl (Reviewer).
PR: https://git.openjdk.java.net/jdk/pull/4056
More information about the hotspot-dev
mailing list