22 return string->EnsureHash();
29 return lhs->Equals(*rhs);
34 :
public std::unordered_set<Handle<String>, StringHandleHash,
36 ZoneAllocator<Handle<String>>> {
46 :
public std::unordered_map<
47 Handle<String>, Handle<Object>, StringHandleHash, StringHandleEqual,
48 ZoneAllocator<std::pair<const Handle<String>, Handle<Object>>>> {
60 :
public std::unordered_map<
61 Handle<Module>, UnorderedStringSet*, ModuleHandleHash,
63 ZoneAllocator<std::pair<const Handle<Module>, UnorderedStringSet*>>> {
84 DCHECK(lhs->HasAsyncEvaluationOrdinal());
85 DCHECK(rhs->HasAsyncEvaluationOrdinal());
86 return lhs->async_evaluation_ordinal() < rhs->async_evaluation_ordinal();
100 case kEvaluatingAsync:
117 return cell_index - 1;
123 return -cell_index - 1;
130 DCHECK(IsTheHole(exports->Lookup(name), isolate));
131 exports = ObjectHashTable::Put(exports, name, entry);
132 module->set_exports(*exports);
141 module->regular_exports()->set(ExportIndex(cell_index), *cell);
144 for (
int i = 0, n = names->
length();
i < n; ++
i) {
146 DCHECK(IsTheHole(exports->Lookup(name), isolate));
147 exports = ObjectHashTable::Put(exports, name, cell);
149 module->set_exports(*exports);
157 cell = regular_imports()->get(
ImportIndex(cell_index));
160 cell = regular_exports()->get(
ExportIndex(cell_index));
170 return handle(module->GetCell(cell_index)->value(), isolate);
179 module->GetCell(cell_index)->set_value(*value);
186 Handle<Object> object(module->exports()->Lookup(export_name), isolate);
187 if (IsCell(*
object)) {
195 auto result = resolve_set->insert({module,
nullptr});
201 }
else if (name_set->count(export_name)) {
204 isolate->ThrowAt(isolate->factory()->NewSyntaxError(
205 MessageTemplate::kCyclicModuleDependency,
206 export_name, module_specifier),
212 name_set->insert(export_name);
215 if (IsSourceTextModuleInfoEntry(*
object)) {
223 if (!
ResolveImport(isolate, module, import_name, entry->module_request(),
224 new_loc,
true, resolve_set)
226 DCHECK(isolate->has_exception());
233 DCHECK(IsSourceTextModuleInfoEntry(exports->Lookup(export_name)));
235 exports = ObjectHashTable::Put(exports, export_name, cell);
236 module->set_exports(*exports);
240 DCHECK(IsTheHole(*
object, isolate));
242 isolate, module, module_specifier, export_name, loc, must_resolve,
252 module->info()->module_requests()->get(module_request_index)),
254 switch (module_request->phase()) {
266 cell->set_value(module->requested_modules()->get(module_request_index));
272 Cast<Module>(module->requested_modules()->get(module_request_index)),
278 name, loc, must_resolve, resolve_set);
291 if (!export_name->Equals(
ReadOnlyRoots(isolate).default_string())) {
297 for (
int i = 0, n = special_exports->length();
i < n; ++
i) {
301 if (!IsUndefined(entry->export_name(), isolate)) {
309 if (
ResolveImport(isolate, module, export_name, entry->module_request(),
310 new_loc,
false, resolve_set)
312 if (unique_cell.
is_null()) unique_cell = cell;
313 if (*unique_cell != *cell) {
314 isolate->ThrowAt(isolate->factory()->NewSyntaxError(
315 MessageTemplate::kAmbiguousExport,
316 module_specifier, export_name),
320 }
else if (isolate->has_exception()) {
328 DCHECK(IsTheHole(exports->Lookup(export_name), isolate));
329 exports = ObjectHashTable::Put(exports, export_name, unique_cell);
330 module->set_exports(*exports);
338 isolate->factory()->NewSyntaxError(MessageTemplate::kUnresolvableExport,
339 module_specifier, export_name),
358 for (
int i = 0, length = module_requests->length();
i < length; ++
i) {
363 module_request->import_attributes(), isolate);
364 switch (module_request->phase()) {
367 if (!module_callback(context, v8::Utils::ToLocal(specifier),
368 v8::Utils::FixedArrayToLocal(import_attributes),
370 .
ToLocal(&api_requested_module)) {
375 requested_modules->set(
i, *requested_module);
381 if (!source_callback(context, v8::Utils::ToLocal(specifier),
382 v8::Utils::FixedArrayToLocal(import_attributes),
384 .
ToLocal(&api_requested_module_source)) {
389 requested_modules->set(
i, *requested_module_source);
398 for (
int i = 0, length = requested_modules->length();
i < length; ++
i) {
407 module_callback, source_callback)) {
414 for (
int i = 0, n = module_info->RegularExportCount();
i < n; ++
i) {
415 int cell_index = module_info->RegularExportCellIndex(
i);
417 module_info->RegularExportExportNames(
i), isolate);
418 CreateExport(isolate, module, cell_index, export_names);
428 for (
int i = 0, n = special_exports->length();
i < n; ++
i) {
432 if (IsUndefined(*export_name, isolate))
continue;
436 DCHECK_EQ(module->status(), kPreLinking);
449 module, isolate->native_context(), scope_info);
450 function->set_context(*context);
455 if (!maybe_generator.
ToHandle(&generator)) {
456 DCHECK(isolate->has_exception());
460 module->set_code(Cast<JSGeneratorObject>(*generator));
468 DCHECK(new_status == kLinked || new_status == kEvaluated);
473 os <<
"Transitioning strongly connected module graph component to "
474 << Module::StatusString(new_status) <<
" {\n";
485 return *m == *module;
489 DCHECK_LE(module->dfs_ancestor_index(), module->dfs_index());
492 if (module->dfs_ancestor_index() == module->dfs_index()) {
524 ancestor = stack->front();
527 new_status == kLinked ? kLinking : kEvaluating);
528 if (new_status == kLinked) {
532 ancestor->SetStatus(kLinked);
534 DCHECK(IsTheHole(ancestor->cycle_root(), isolate));
535 ancestor->set_cycle_root(*cycle_root);
536 ancestor->SetStatus(ancestor->HasAsyncEvaluationOrdinal()
540 }
while (*ancestor != *module);
562 module->set_code(*function);
563 module->SetStatus(kLinking);
564 module->set_dfs_index(*dfs_index);
565 module->set_dfs_ancestor_index(*dfs_index);
566 stack->push_front(module);
574 for (
int i = 0, length = requested_modules->length();
i < length; ++
i) {
587 DCHECK_NE(requested_module->status(), kEvaluating);
588 DCHECK_GE(requested_module->status(), kLinking);
591 (requested_module->status() == kLinking) ==
593 stack->begin(), stack->end(),
596 if (requested_module->status() == kLinking) {
599 module->set_dfs_ancestor_index(std::min(
600 module->dfs_ancestor_index(),
601 Cast<SourceTextModule>(*requested_module)->dfs_ancestor_index()));
611 for (
int i = 0, n = regular_imports->length();
i < n; ++
i) {
616 ResolveSet resolve_set(zone);
618 if (!
ResolveImport(isolate, module, name, entry->module_request(), loc,
623 module->regular_imports()->set(ImportIndex(entry->cell_index()), *cell);
629 for (
int i = 0, n = special_exports->length();
i < n; ++
i) {
633 if (IsUndefined(*name, isolate))
continue;
635 ResolveSet resolve_set(zone);
652 if (IsJSModuleNamespace(module->module_namespace()))
return;
654 bool cycle = !visited->insert(module).second;
665 for (
int i = 0, n = special_exports->length();
i < n; ++
i) {
668 if (!IsUndefined(entry->export_name(), roots)) {
673 entry->module_request()))
677 Cast<Module>(module->requested_modules()->get(entry->module_request())),
681 if (IsSourceTextModule(*requested_module))
691 for (
InternalIndex index : requested_exports->IterateEntries()) {
693 if (!requested_exports->ToKey(roots, index, &
key))
continue;
696 if (name->Equals(roots.default_string()))
continue;
697 if (!IsTheHole(exports->Lookup(name), roots))
continue;
700 auto insert_result = more_exports.insert(std::make_pair(name, cell));
701 if (!insert_result.second) {
702 auto it = insert_result.first;
703 if (*it->second == *cell || IsUndefined(*it->second, roots)) {
707 DCHECK(IsCell(*it->second));
710 it->second = isolate->factory()->undefined_value();
717 for (
const auto& elem : more_exports) {
718 if (IsUndefined(*elem.second, isolate))
continue;
720 DCHECK(IsCell(*elem.second));
721 exports = ObjectHashTable::Put(exports, elem.first, elem.second);
723 module->set_exports(*exports);
732 worklist.push(
start);
734 while (!worklist.empty()) {
739 for (
int i = module->AsyncParentModuleCount();
i-- > 0;) {
744 if (
m->GetCycleRoot(isolate)->status() != kErrored &&
745 exec_list->find(
m) == exec_list->end()) {
751 DCHECK(
m->HasAsyncEvaluationOrdinal());
754 DCHECK(
m->HasPendingAsyncDependencies());
758 m->DecrementPendingAsyncDependencies();
761 if (!
m->HasPendingAsyncDependencies()) {
763 exec_list->insert(
m);
767 if (!
m->has_toplevel_await()) worklist.push(
m);
778 int module_request) {
780 module->info()->module_requests()->get(module_request))
784 Cast<Module>(module->requested_modules()->get(module_request)), isolate);
792 if (IsTheHole(*import_meta, isolate)) {
793 if (!isolate->RunHostInitializeImportMetaObjectCallback(module).ToHandle(
797 module->set_import_meta(*import_meta, kReleaseStore);
808 if (isolate->is_catchable_by_javascript(exception)) {
812 CHECK_EQ(descendant->status(), kEvaluating);
815 descendant->RecordError(isolate, exception);
823 RecordError(isolate, exception);
825 descendant->RecordError(isolate, exception);
828 CHECK_EQ(this->exception(), *isolate->factory()->null_value());
835 CHECK(module->status() == kLinked || module->status() == kEvaluatingAsync ||
836 module->status() == kEvaluated);
841 unsigned dfs_index = 0;
847 module->set_top_level_capability(*capability);
848 DCHECK(IsJSPromise(module->top_level_capability()));
857 if (!module->MaybeHandleEvaluationException(isolate, &stack))
return {};
864 CHECK_GE(module->status(), kEvaluatingAsync);
867 if (!module->HasAsyncEvaluationOrdinal()) {
889 if (module->status() == kErrored) {
891 DCHECK(!IsTheHole(module->exception(), isolate));
897 DCHECK_EQ(module->status(), kEvaluatingAsync);
900 DCHECK(module->HasAsyncEvaluationOrdinal());
906 module->set_async_evaluation_ordinal(kAsyncEvaluateDidFinish);
909 module->SetStatus(kEvaluated);
912 if (!IsUndefined(module->top_level_capability(), isolate)) {
914 DCHECK_EQ(*module->GetCycleRoot(isolate), *module);
943 DCHECK(
m->HasAsyncEvaluationOrdinal());
944 DCHECK(!
m->HasPendingAsyncDependencies());
951 if (
m->status() == kErrored) {
953 DCHECK(!IsTheHole(
m->exception(), isolate));
954 }
else if (
m->has_toplevel_await()) {
966 if (!
ExecuteModule(isolate,
m, &exception).ToHandle(&unused_result)) {
974 m->SetStatus(kEvaluated);
977 if (!IsUndefined(
m->top_level_capability(), isolate)) {
1001 if (module->status() == kErrored) {
1003 DCHECK(!IsTheHole(module->exception(), isolate));
1008 DCHECK(isolate->is_catchable_by_javascript(*exception));
1010 CHECK_EQ(module->status(), kEvaluatingAsync);
1012 DCHECK(module->HasAsyncEvaluationOrdinal());
1014 DCHECK(IsTheHole(module->exception(), isolate));
1017 module->RecordError(isolate, *exception);
1021 module->set_async_evaluation_ordinal(kAsyncEvaluateDidFinish);
1024 for (
int i = 0;
i < module->AsyncParentModuleCount();
i++) {
1031 if (!IsUndefined(module->top_level_capability(), isolate)) {
1033 DCHECK_EQ(*module->GetCycleRoot(isolate), *module);
1049 CHECK(module->status() == kEvaluating ||
1050 module->status() == kEvaluatingAsync);
1053 DCHECK(module->has_toplevel_await());
1059 isolate->factory()->NewBuiltinContext(
1060 isolate->native_context(),
1074 ->source_text_module_execute_async_module_fulfilled_sfi(),
1075 execute_async_module_context}
1087 ->source_text_module_execute_async_module_rejected_sfi(),
1088 execute_async_module_context}
1100 CHECK(isolate->is_execution_terminating());
1114 isolate->is_execution_terminating());
1130 async_function_object->set_promise(*capability);
1132 isolate->native_context()->async_module_evaluate_internal(), isolate);
1144 isolate->native_context()->generator_next_internal(), isolate);
1162 int module_status =
module->status();
1166 if (module_status == kEvaluatingAsync || module_status == kEvaluating ||
1167 module_status == kEvaluated) {
1173 return isolate->factory()->undefined_value();
1174 }
else if (module_status == kErrored) {
1177 isolate->Throw(module->exception());
1191 raw_module->SetStatus(kEvaluating);
1194 raw_module->set_dfs_index(*dfs_index);
1197 raw_module->set_dfs_ancestor_index(*dfs_index);
1200 DCHECK(!raw_module->HasPendingAsyncDependencies());
1206 stack->push_front(module);
1210 direct_handle(raw_module->info()->module_requests(), isolate);
1211 requested_modules =
direct_handle(raw_module->requested_modules(), isolate);
1215 for (
int i = 0, length = requested_modules->length();
i < length; ++
i) {
1225 if (IsSourceTextModule(*requested_module)) {
1233 int required_module_status = required_module->status();
1239 CHECK_GE(required_module_status, kEvaluating);
1240 CHECK_NE(required_module_status, kErrored);
1244 SLOW_DCHECK((requested_module->status() == kEvaluating) ==
1245 std::count_if(stack->begin(), stack->end(),
1247 return *m == *requested_module;
1251 if (required_module_status == kEvaluating) {
1255 module->set_dfs_ancestor_index(
1256 std::min(module->dfs_ancestor_index(),
1257 required_module->dfs_ancestor_index()));
1260 required_module = required_module->GetCycleRoot(isolate);
1261 required_module_status = required_module->status();
1265 CHECK_GE(required_module_status, kEvaluatingAsync);
1274 if (required_module_status == kErrored) {
1275 isolate->Throw(required_module->exception());
1280 if (required_module->HasAsyncEvaluationOrdinal()) {
1283 module->IncrementPendingAsyncDependencies();
1305 if (module->HasPendingAsyncDependencies() || module->has_toplevel_await()) {
1313 module->set_async_evaluation_ordinal(
1314 isolate->NextModuleAsyncEvaluationOrdinal());
1320 if (!module->HasPendingAsyncDependencies()) {
1328 if (!
ExecuteModule(isolate, module, &exception).ToHandle(&maybe_result)) {
1329 if (!isolate->is_execution_terminating()) {
1330 isolate->Throw(*exception.ToHandleChecked());
1332 return maybe_result;
1342 Factory* factory = isolate->factory();
1347 factory->
NewFixedArray(module->regular_exports()->length());
1349 factory->
NewFixedArray(module->regular_imports()->length());
1351 factory->
NewFixedArray(module->requested_modules()->length());
1355 if (raw_module->status() == kLinking) {
1358 raw_module->set_regular_exports(*regular_exports);
1359 raw_module->set_regular_imports(*regular_imports);
1360 raw_module->set_requested_modules(*requested_modules);
1361 raw_module->set_dfs_index(-1);
1362 raw_module->set_dfs_ancestor_index(-1);
1365std::pair<DirectHandleVector<SourceTextModule>,
1373 size_t stalled_modules_size = stalled_modules.
size();
1374 if (stalled_modules_size == 0)
return {stalled_modules, messages};
1376 messages.reserve(stalled_modules_size);
1378 CHECK(IsJSGeneratorObject(found->code()));
1386 isolate, MessageTemplate::kTopLevelAwaitStalled, &location,
1387 isolate->factory()->null_value());
1388 messages.push_back(message);
1390 return {stalled_modules, messages};
1407 int length = requested->length();
1414 if (IsSourceTextModule(requested_module) &&
1415 visited->insert(
handle(requested_module, isolate)).
second) {
1418 source_text_module->InnerGetStalledTopLevelAwaitModule(isolate, visited,
#define SLOW_DCHECK(condition)
Local< Value > GetModuleNamespace()
void SetVerbose(bool value)
void SetCaptureMessage(bool value)
static v8::internal::DirectHandle< To > OpenDirectHandle(v8::Local< From > handle)
size_t size() const noexcept
static V8_EXPORT_PRIVATE MaybeDirectHandle< Object > TryCall(Isolate *isolate, DirectHandle< Object > callable, DirectHandle< Object > receiver, base::Vector< const DirectHandle< Object > > args, MessageHandling message_handling, MaybeDirectHandle< Object > *exception_out)
V8_EXPORT_PRIVATE static V8_WARN_UNUSED_RESULT MaybeHandle< Object > Call(Isolate *isolate, DirectHandle< Object > callable, DirectHandle< Object > receiver, base::Vector< const DirectHandle< Object > > args)
static V8_WARN_UNUSED_RESULT MaybeHandle< Object > CallBuiltin(Isolate *isolate, DirectHandle< JSFunction > builtin, DirectHandle< Object > receiver, base::Vector< const DirectHandle< Object > > args)
Handle< FixedArray > NewFixedArray(int length, AllocationType allocation=AllocationType::kYoung)
V8_WARN_UNUSED_RESULT Handle< JSFunction > Build()
V8_INLINE bool is_null() const
static Handle< Object > Reject(DirectHandle< JSPromise > promise, DirectHandle< Object > reason, bool debug_event=true)
static V8_WARN_UNUSED_RESULT MaybeHandle< Object > Resolve(DirectHandle< JSPromise > promise, DirectHandle< Object > resolution)
V8_WARN_UNUSED_RESULT V8_INLINE bool ToHandle(DirectHandle< S > *out) const
V8_INLINE bool is_null() const
static V8_EXPORT_PRIVATE Handle< JSMessageObject > MakeMessageObject(Isolate *isolate, MessageTemplate type, const MessageLocation *location, DirectHandle< Object > argument, DirectHandle< StackTraceInfo > stack_trace=DirectHandle< StackTraceInfo >::null())
static V8_WARN_UNUSED_RESULT MaybeDirectHandle< Object > Evaluate(Isolate *isolate, Handle< Module > module)
static V8_WARN_UNUSED_RESULT bool FinishInstantiate(Isolate *isolate, Handle< Module > module, ZoneForwardList< Handle< SourceTextModule > > *stack, unsigned *dfs_index, Zone *zone)
static V8_WARN_UNUSED_RESULT MaybeHandle< Cell > ResolveExport(Isolate *isolate, Handle< Module > module, DirectHandle< String > module_specifier, Handle< String > export_name, MessageLocation loc, bool must_resolve, ResolveSet *resolve_set)
static V8_WARN_UNUSED_RESULT bool PrepareInstantiate(Isolate *isolate, DirectHandle< Module > module, v8::Local< v8::Context > context, v8::Module::ResolveModuleCallback module_callback, v8::Module::ResolveSourceCallback source_callback)
static V8_EXPORT_PRIVATE bool BooleanValue(Tagged< Object > obj, IsolateT *isolate)
static CellIndexKind GetCellIndexKind(int cell_index)
Tagged< Script > GetScript() const
static V8_WARN_UNUSED_RESULT MaybeDirectHandle< Object > InnerExecuteAsyncModule(Isolate *isolate, DirectHandle< SourceTextModule > module, DirectHandle< JSPromise > capability)
static void CreateExport(Isolate *isolate, DirectHandle< SourceTextModule > module, int cell_index, DirectHandle< FixedArray > names)
static V8_WARN_UNUSED_RESULT bool MaybeTransitionComponent(Isolate *isolate, DirectHandle< SourceTextModule > module, ZoneForwardList< Handle< SourceTextModule > > *stack, Status new_status)
static V8_WARN_UNUSED_RESULT MaybeDirectHandle< Object > Evaluate(Isolate *isolate, Handle< SourceTextModule > module)
static void CreateIndirectExport(Isolate *isolate, DirectHandle< SourceTextModule > module, DirectHandle< String > name, DirectHandle< SourceTextModuleInfoEntry > entry)
static void AddAsyncParentModule(Isolate *isolate, DirectHandle< SourceTextModule > module, DirectHandle< SourceTextModule > parent)
Tagged< Cell > GetCell(int cell_index)
static constexpr unsigned kAsyncEvaluateDidFinish
static V8_WARN_UNUSED_RESULT MaybeHandle< Cell > ResolveExportUsingStarExports(Isolate *isolate, DirectHandle< SourceTextModule > module, DirectHandle< String > module_specifier, Handle< String > export_name, MessageLocation loc, bool must_resolve, ResolveSet *resolve_set)
static V8_EXPORT_PRIVATE MaybeHandle< JSObject > GetImportMeta(Isolate *isolate, DirectHandle< SourceTextModule > module)
V8_EXPORT_PRIVATE std::pair< DirectHandleVector< SourceTextModule >, DirectHandleVector< JSMessageObject > > GetStalledTopLevelAwaitMessages(Isolate *isolate)
static DirectHandle< JSModuleNamespace > GetModuleNamespace(Isolate *isolate, DirectHandle< SourceTextModule > module, int module_request)
static V8_WARN_UNUSED_RESULT bool RunInitializationCode(Isolate *isolate, DirectHandle< SourceTextModule > module)
bool HasPendingAsyncDependencies()
static void FetchStarExports(Isolate *isolate, Handle< SourceTextModule > module, Zone *zone, UnorderedModuleSet *visited)
static V8_WARN_UNUSED_RESULT MaybeDirectHandle< Object > InnerModuleEvaluation(Isolate *isolate, Handle< SourceTextModule > module, ZoneForwardList< Handle< SourceTextModule > > *stack, unsigned *dfs_index)
static V8_WARN_UNUSED_RESULT Maybe< bool > ExecuteAsyncModule(Isolate *isolate, DirectHandle< SourceTextModule > module)
bool MaybeHandleEvaluationException(Isolate *isolate, ZoneForwardList< Handle< SourceTextModule > > *stack)
static V8_WARN_UNUSED_RESULT bool PrepareInstantiate(Isolate *isolate, DirectHandle< SourceTextModule > module, v8::Local< v8::Context > context, v8::Module::ResolveModuleCallback module_callback, v8::Module::ResolveSourceCallback source_callback)
bool HasAsyncEvaluationOrdinal() const
static void StoreVariable(DirectHandle< SourceTextModule > module, int cell_index, DirectHandle< Object > value)
static V8_WARN_UNUSED_RESULT MaybeHandle< Cell > ResolveExport(Isolate *isolate, Handle< SourceTextModule > module, DirectHandle< String > module_specifier, Handle< String > export_name, MessageLocation loc, bool must_resolve, ResolveSet *resolve_set)
static V8_WARN_UNUSED_RESULT bool FinishInstantiate(Isolate *isolate, Handle< SourceTextModule > module, ZoneForwardList< Handle< SourceTextModule > > *stack, unsigned *dfs_index, Zone *zone)
static V8_WARN_UNUSED_RESULT MaybeHandle< Cell > ResolveImport(Isolate *isolate, DirectHandle< SourceTextModule > module, Handle< String > name, int module_request_index, MessageLocation loc, bool must_resolve, ResolveSet *resolve_set)
V8_EXPORT_PRIVATE void InnerGetStalledTopLevelAwaitModule(Isolate *isolate, UnorderedModuleSet *visited, DirectHandleVector< SourceTextModule > *result)
static void Reset(Isolate *isolate, DirectHandle< SourceTextModule > module)
static void GatherAvailableAncestors(Isolate *isolate, Zone *zone, Handle< SourceTextModule > start, AvailableAncestorsSet *exec_list)
static V8_WARN_UNUSED_RESULT MaybeDirectHandle< Object > ExecuteModule(Isolate *isolate, DirectHandle< SourceTextModule > module, MaybeDirectHandle< Object > *exception_out)
static void AsyncModuleExecutionRejected(Isolate *isolate, DirectHandle< SourceTextModule > module, DirectHandle< Object > exception)
static Handle< Object > LoadVariable(Isolate *isolate, DirectHandle< SourceTextModule > module, int cell_index)
NEVER_READ_ONLY_SPACE Tagged< SharedFunctionInfo > GetSharedFunctionInfo() const
static int ImportIndex(int cell_index)
static Maybe< bool > AsyncModuleExecutionFulfilled(Isolate *isolate, Handle< SourceTextModule > module)
Tagged< SourceTextModuleInfo > info() const
static constexpr unsigned kNotAsyncEvaluated
static int ExportIndex(int cell_index)
UnorderedStringMap(Zone *zone)
UnorderedStringSet(Zone *zone)
#define RETURN_ON_EXCEPTION(isolate, call)
#define STACK_CHECK(isolate, result_value)
#define MAYBE_RETURN(call, value)
base::Vector< const DirectHandle< Object > > args
MaybeDirectHandle< Object > * exception_out
SharedFunctionInfoRef shared
ZoneVector< RpoNumber > & result
ZoneStack< RpoNumber > & stack
constexpr Vector< T > VectorOf(T *start, size_t size)
V8_INLINE IndirectHandle< T > handle(Tagged< T > object, Isolate *isolate)
V8_INLINE DirectHandle< T > direct_handle(Tagged< T > object, Isolate *isolate)
too high values may cause the compiler to set high thresholds for inlining to as much as possible avoid inlined allocation of objects that cannot escape trace load stores from virtual maglev objects use TurboFan fast string builder analyze liveness of environment slots and zap dead values trace TurboFan load elimination emit data about basic block usage in builtins to this enable builtin reordering when run mksnapshot flag for emit warnings when applying builtin profile data verify register allocation in TurboFan randomly schedule instructions to stress dependency tracking enable store store elimination in TurboFan rewrite far to near simulate GC compiler thread race related to allow float parameters to be passed in simulator mode JS Wasm Run additional turbo_optimize_inlined_js_wasm_wrappers enable experimental feedback collection in generic lowering enable Turboshaft s WasmLoadElimination enable Turboshaft s low level load elimination for JS enable Turboshaft s escape analysis for string concatenation use enable Turbolev features that we want to ship in the not too far future trace individual Turboshaft reduction steps trace intermediate Turboshaft reduction steps invocation count threshold for early optimization Enables optimizations which favor memory size over execution speed Enables sampling allocation profiler with X as a sample interval min size of a semi the new space consists of two semi spaces max size of the Collect garbage after Collect garbage after keeps maps alive for< n > old space garbage collections print one detailed trace line in name
V8_EXPORT_PRIVATE FlagValues v8_flags
kInterpreterTrampolineOffset script
Tagged< To > Cast(Tagged< From > value, const v8::SourceLocation &loc=INIT_SOURCE_LOCATION_IN_DEBUG)
bool ToLocal(v8::internal::MaybeDirectHandle< v8::internal::Object > maybe, Local< T > *local)
static constexpr AcquireLoadTag kAcquireLoad
Maybe< T > Just(const T &t)
#define DCHECK_LE(v1, v2)
#define CHECK_GE(lhs, rhs)
#define DCHECK_IMPLIES(v1, v2)
#define DCHECK_NE(v1, v2)
#define CHECK_NE(lhs, rhs)
#define DCHECK_GE(v1, v2)
#define CHECK_EQ(lhs, rhs)
#define DCHECK(condition)
#define DCHECK_LT(v1, v2)
#define DCHECK_EQ(v1, v2)
bool operator()(DirectHandle< SourceTextModule > lhs, DirectHandle< SourceTextModule > rhs) const
V8_INLINE bool operator()(DirectHandle< String > lhs, DirectHandle< String > rhs) const
V8_INLINE size_t operator()(DirectHandle< String > string) const
#define V8_UNLIKELY(condition)