5#ifndef INCLUDE_V8_INITIALIZATION_H_
6#define INCLUDE_V8_INITIALIZATION_H_
27template <
class K,
class V,
class T>
28class PersistentValueMapBase;
50 uintptr_t (*)(uintptr_t return_addr_location);
100 const int kBuildConfiguration =
101 (internal::PointerCompressionIsEnabled() ? kPointerCompression : 0) |
102 (internal::SmiValuesAre31Bits() ? k31BitSmis : 0) |
103 (internal::SandboxedExternalPointersAreEnabled()
104 ? kSandboxedExternalPointers
106 (internal::SandboxIsEnabled() ? kSandbox : 0);
107 return Initialize(kBuildConfiguration);
156 const char* icu_data_file =
nullptr);
188 static
void ShutdownPlatform() { DisposePlatform(); }
208 static bool InitializeSandbox();
210 static
bool InitializeVirtualMemoryCage() {
return InitializeSandbox(); }
226 static VirtualAddressSpace* GetSandboxAddressSpace();
228 static PageAllocator* GetVirtualMemoryCagePageAllocator();
236 static
size_t GetSandboxSizeInBytes();
238 static
size_t GetVirtualMemoryCageSizeInBytes() {
239 return GetSandboxSizeInBytes();
250 static bool IsSandboxConfiguredSecurely();
252 static
bool IsUsingSecureVirtualMemoryCage() {
253 return IsSandboxConfiguredSecurely();
265#if defined(V8_OS_WIN)
275 static void SetUnhandledExceptionCallback(
276 UnhandledExceptionCallback unhandled_exception_callback);
295 enum BuildConfigurationFeatures {
296 kPointerCompression = 1 << 0,
298 kSandboxedExternalPointers = 1 << 2,
306 static bool Initialize(
int build_config);
309 template <
class K,
class V,
class T>
static void InitializeExternalStartupDataFromFile(const char *snapshot_blob)
static void SetReturnAddressLocationResolver(ReturnAddressLocationResolver return_address_resolver)
static const char * GetVersion()
static void InitializeExternalStartupData(const char *directory_path)
static V8_INLINE bool Initialize()
static void SetDcheckErrorHandler(DcheckErrorCallback that)
static void SetFatalMemoryErrorCallback(OOMErrorCallback oom_error_callback)
static void SetFlagsFromString(const char *str, size_t length)
static void GetSharedMemoryStatistics(SharedMemoryStatistics *statistics)
static bool InitializeICU(const char *icu_data_file=nullptr)
static bool InitializeICUDefaultLocation(const char *exec_path, const char *icu_data_file=nullptr)
static void SetFlagsFromCommandLine(int *argc, char **argv, bool remove_flags)
static void SetFlagsFromString(const char *str)
static void SetEntropySource(EntropySource source)
static void InitializePlatform(Platform *platform)
static bool EnableWebAssemblyTrapHandler(bool use_v8_signal_handler)
static void DisposePlatform()
static void SetSnapshotDataBlob(StartupData *startup_blob)
v8::PageAllocator PageAllocator
bool(*)(unsigned char *buffer, size_t length) EntropySource
uintptr_t(*)(uintptr_t return_addr_location) ReturnAddressLocationResolver
void(*)(const char *location, bool is_heap_oom) OOMErrorCallback
void(*)(const char *file, int line, const char *message) DcheckErrorCallback
#define V8_DEPRECATE_SOON(message)
#define V8_DEPRECATED(message)