8325767: Serial: Move transform_stack_chunk out of TenuredGeneration::promote

Reviewed-by: stefank
This commit is contained in:
Albert Mingkun Yang 2024-02-14 13:17:10 +00:00
parent 8dc59763eb
commit 61f249335d
2 changed files with 3 additions and 5 deletions

@ -862,6 +862,9 @@ oop DefNewGeneration::copy_to_survivor_space(oop old) {
handle_promotion_failure(old);
return old;
}
ContinuationGCSupport::transform_stack_chunk(obj);
new_obj_is_tenured = true;
} else {
// Prefetch beyond obj

@ -29,7 +29,6 @@
#include "gc/serial/serialHeap.hpp"
#include "gc/serial/tenuredGeneration.inline.hpp"
#include "gc/shared/collectorCounters.hpp"
#include "gc/shared/continuationGCSupport.inline.hpp"
#include "gc/shared/gcLocker.hpp"
#include "gc/shared/gcTimer.hpp"
#include "gc/shared/gcTrace.hpp"
@ -436,10 +435,6 @@ oop TenuredGeneration::promote(oop obj, size_t obj_size) {
// Copy to new location.
Copy::aligned_disjoint_words(cast_from_oop<HeapWord*>(obj), result, obj_size);
oop new_obj = cast_to_oop<HeapWord*>(result);
// Transform object if it is a stack chunk.
ContinuationGCSupport::transform_stack_chunk(new_obj);
return new_obj;
}