Reland^2 "[heap] Move start of incremental marking in allocation"
This is a reland offc48a2283c
Original change's description: > Reland "[heap] Move start of incremental marking in allocation" > > This is a reland ofd6a14abe05
> > Test wasn't written with incremental/concurrent marking in mind, so > simply disabling it for this particular unittest. > > Original change's description: > > [heap] Move start of incremental marking in allocation > > > > Move start of incremental marking out of > > RefillLinearAllocationAreaFromFreeList. This avoids a potential > > safepoint while holding allocation_mutex_. > > > > Bug: v8:10315 > > Change-Id: Ieb60ac68f26199eea7b6b7ad6d874851382f3d69 > > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2287496 > > Commit-Queue: Dominik Inführ <dinfuehr@chromium.org> > > Reviewed-by: Ulan Degenbaev <ulan@chromium.org> > > Cr-Commit-Position: refs/heads/master@{#68751} > > Bug: v8:10315 > Change-Id: I2a665400d9a784b1557474a051839d5c8b45e9e2 > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2292241 > Reviewed-by: Ulan Degenbaev <ulan@chromium.org> > Commit-Queue: Dominik Inführ <dinfuehr@chromium.org> > Cr-Commit-Position: refs/heads/master@{#68818} Bug: v8:10315 Change-Id: I7873c6c20e39d6636bd95a26d0c1cfc8f89366bd Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2295363 Reviewed-by: Ulan Degenbaev <ulan@chromium.org> Commit-Queue: Dominik Inführ <dinfuehr@chromium.org> Cr-Commit-Position: refs/heads/master@{#68839}
This commit is contained in:
parent
b9c3e8c7fd
commit
b863810b45
@ -529,12 +529,6 @@ bool PagedSpace::RefillLabFromFreeListMain(size_t size_in_bytes,
|
||||
// if it is big enough.
|
||||
FreeLinearAllocationArea();
|
||||
|
||||
if (!is_local_space()) {
|
||||
heap()->StartIncrementalMarkingIfAllocationLimitIsReached(
|
||||
heap()->GCFlagsForIncrementalMarking(),
|
||||
kGCCallbackScheduleIdleGarbageCollection);
|
||||
}
|
||||
|
||||
size_t new_node_size = 0;
|
||||
FreeSpace new_node =
|
||||
free_list_->Allocate(size_in_bytes, &new_node_size, origin);
|
||||
@ -1003,6 +997,15 @@ AllocationResult PagedSpace::AllocateRawSlow(int size_in_bytes,
|
||||
top_on_previous_step_ ? top() - top_on_previous_step_ : 0;
|
||||
DCHECK_IMPLIES(!SupportsInlineAllocation(), bytes_since_last == 0);
|
||||
|
||||
if (!is_local_space()) {
|
||||
// Start incremental marking before the actual allocation, this allows the
|
||||
// allocation function to mark the object black when incremental marking is
|
||||
// running.
|
||||
heap()->StartIncrementalMarkingIfAllocationLimitIsReached(
|
||||
heap()->GCFlagsForIncrementalMarking(),
|
||||
kGCCallbackScheduleIdleGarbageCollection);
|
||||
}
|
||||
|
||||
#ifdef V8_HOST_ARCH_32_BIT
|
||||
AllocationResult result =
|
||||
alignment != kWordAligned
|
||||
|
@ -130,6 +130,7 @@ TEST(ExternalString_ExternalBackingStoreSizeIncreasesMarkCompact) {
|
||||
}
|
||||
|
||||
TEST(ExternalString_ExternalBackingStoreSizeIncreasesAfterExternalization) {
|
||||
ManualGCScope manual_gc_scope;
|
||||
CcTest::InitializeVM();
|
||||
LocalContext env;
|
||||
v8::Isolate* isolate = env->GetIsolate();
|
||||
|
@ -648,6 +648,7 @@ static void CustomCallback(const v8::FunctionCallbackInfo<v8::Value>& info) {
|
||||
|
||||
TEST_F(RuntimeCallStatsTest, CallbackFunction) {
|
||||
FLAG_allow_natives_syntax = true;
|
||||
FLAG_incremental_marking = false;
|
||||
|
||||
RuntimeCallCounter* callback_counter =
|
||||
stats()->GetCounter(RuntimeCallCounterId::kFunctionCallback);
|
||||
@ -726,6 +727,7 @@ TEST_F(RuntimeCallStatsTest, CallbackFunction) {
|
||||
|
||||
TEST_F(RuntimeCallStatsTest, ApiGetter) {
|
||||
FLAG_allow_natives_syntax = true;
|
||||
FLAG_incremental_marking = false;
|
||||
|
||||
RuntimeCallCounter* callback_counter =
|
||||
stats()->GetCounter(RuntimeCallCounterId::kFunctionCallback);
|
||||
|
Loading…
Reference in New Issue
Block a user