chromium/v8/test/unittests/heap/spaces-unittest.cc

// Copyright 2017 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "src/heap/spaces.h"

#include <memory>

#include "src/common/globals.h"
#include "src/execution/isolate.h"
#include "src/heap/heap-inl.h"
#include "src/heap/heap-write-barrier-inl.h"
#include "src/heap/heap.h"
#include "src/heap/large-spaces.h"
#include "src/heap/main-allocator.h"
#include "src/heap/mutable-page-metadata.h"
#include "src/heap/spaces-inl.h"
#include "test/unittests/test-utils.h"

namespace v8 {
namespace internal {

static Tagged<HeapObject> AllocateUnaligned(MainAllocator* allocator,
                                            SpaceWithLinearArea* space,
                                            int size) {}

static Tagged<HeapObject> AllocateUnaligned(OldLargeObjectSpace* allocator,
                                            OldLargeObjectSpace* space,
                                            int size) {}

using SpacesTest = TestWithIsolate;

TEST_F(SpacesTest, CompactionSpaceMerge) {}

TEST_F(SpacesTest, WriteBarrierIsMarking) {}

TEST_F(SpacesTest, WriteBarrierInYoungGenerationToSpace) {}

TEST_F(SpacesTest, WriteBarrierInYoungGenerationFromSpace) {}

TEST_F(SpacesTest, CodeRangeAddressReuse) {}

// Tests that FreeListMany::SelectFreeListCategoryType returns what it should.
TEST_F(SpacesTest, FreeListManySelectFreeListCategoryType) {}

// Tests that
// FreeListManyCachedFastPath::SelectFastAllocationFreeListCategoryType returns
// what it should.
TEST_F(SpacesTest,
       FreeListManyCachedFastPathSelectFastAllocationFreeListCategoryType) {}

class Observer : public AllocationObserver {};

template <typename T, typename A>
void testAllocationObserver(Isolate* i_isolate, T* space, A* allocator) {}

TEST_F(SpacesTest, AllocationObserver) {}

TEST_F(SpacesTest, InlineAllocationObserverCadence) {}

}  // namespace internal
}  // namespace v8