v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
process-heap-statistics.h
Go to the documentation of this file.
1
// Copyright 2020 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_PROCESS_HEAP_STATISTICS_H_
6
#define INCLUDE_CPPGC_PROCESS_HEAP_STATISTICS_H_
7
8
#include <atomic>
9
#include <cstddef>
10
11
#include "
v8config.h
"
// NOLINT(build/include_directory)
12
13
namespace
cppgc
{
14
namespace
internal
{
15
class
ProcessHeapStatisticsUpdater;
16
}
// namespace internal
17
18
class
V8_EXPORT
ProcessHeapStatistics
final {
19
public
:
20
static
size_t
TotalAllocatedObjectSize
() {
21
return
total_allocated_object_size_.load(std::memory_order_relaxed);
22
}
23
static
size_t
TotalAllocatedSpace
() {
24
return
total_allocated_space_.load(std::memory_order_relaxed);
25
}
26
27
private
:
28
static
std::atomic_size_t
total_allocated_space_
;
29
static
std::atomic_size_t
total_allocated_object_size_
;
30
31
friend
class
internal::ProcessHeapStatisticsUpdater
;
32
};
33
34
}
// namespace cppgc
35
36
#endif
// INCLUDE_CPPGC_PROCESS_HEAP_STATISTICS_H_
cppgc::ProcessHeapStatistics
Definition
process-heap-statistics.h:18
cppgc::ProcessHeapStatistics::TotalAllocatedSpace
static size_t TotalAllocatedSpace()
Definition
process-heap-statistics.h:23
cppgc::ProcessHeapStatistics::total_allocated_object_size_
static std::atomic_size_t total_allocated_object_size_
Definition
process-heap-statistics.h:29
cppgc::ProcessHeapStatistics::TotalAllocatedObjectSize
static size_t TotalAllocatedObjectSize()
Definition
process-heap-statistics.h:20
cppgc::ProcessHeapStatistics::total_allocated_space_
static std::atomic_size_t total_allocated_space_
Definition
process-heap-statistics.h:28
cppgc::internal::ProcessHeapStatisticsUpdater
Definition
process-heap-statistics.h:14
cppgc
Definition
cross-heap-remembered-set.h:14
v8::internal::internal
internal
Definition
wasm-objects-inl.h:458
v8config.h
V8_EXPORT
#define V8_EXPORT
Definition
v8config.h:800
include
cppgc
process-heap-statistics.h
Generated on Sun Apr 6 2025 21:08:54 for v8 by
1.12.0