v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
testing.h
Go to the documentation of this file.
1// Copyright 2021 the V8 project authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef INCLUDE_CPPGC_TESTING_H_
6#define INCLUDE_CPPGC_TESTING_H_
7
8#include "cppgc/common.h"
9#include "cppgc/macros.h"
10#include "v8config.h" // NOLINT(build/include_directory)
11
12namespace cppgc {
13
14class HeapHandle;
15
19namespace testing {
20
51
58 public:
60
64 void StartGarbageCollection();
65
72 bool PerformMarkingStep(EmbedderStackState stack_state);
73
81 void FinalizeGarbageCollection(EmbedderStackState stack_state);
82
90 void ToggleMainThreadMarking(bool should_mark);
91
95 void ForceCompactionForNextGarbageCollection();
96
97 private:
99};
100
101V8_EXPORT bool IsHeapObjectOld(void*);
102
103} // namespace testing
104} // namespace cppgc
105
106#endif // INCLUDE_CPPGC_TESTING_H_
OverrideEmbedderStackStateScope(const OverrideEmbedderStackStateScope &)=delete
OverrideEmbedderStackStateScope & operator=(const OverrideEmbedderStackStateScope &)=delete
bool IsHeapObjectOld(void *object)
Definition testing.cc:55
EmbedderStackState
Definition common.h:15
#define V8_EXPORT
Definition v8config.h:800
#define V8_NODISCARD
Definition v8config.h:693