mirror of
https://github.com/zebrajr/node.git
synced 2025-12-06 00:20:08 +01:00
deps: V8: cherry-pick ff34ae20c8e3
Original commit message:
[objects] improve module linked status DCHECKs
Improve DCHECKs that requires a module to be linked. This includes
kLinked, kEvaluated, kEvaluatingAsync, kErrored and the missing
kEvaluating. kEvaluating can be found when a cyclic module is been
evaluated synchronously.
Refs: https://github.com/nodejs/node/pull/60111#issuecomment-3375399863
Change-Id: Ie0b9be22f2d3b8208571d8b419da3505b9f57b65
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/7031498
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Chengzhong Wu <cwu631@bloomberg.net>
Cr-Commit-Position: refs/heads/main@{#103203}
Refs: ff34ae20c8
PR-URL: https://github.com/nodejs/node/pull/60111
Reviewed-By: Richard Lau <richard.lau@ibm.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
This commit is contained in:
parent
1acd8df36f
commit
f819aec288
|
|
@ -38,7 +38,7 @@
|
|||
|
||||
# Reset this number to 0 on major V8 upgrades.
|
||||
# Increment by one for each non-official patch applied to deps/v8.
|
||||
'v8_embedder_string': '-node.8',
|
||||
'v8_embedder_string': '-node.9',
|
||||
|
||||
##### V8 defaults for Node.js #####
|
||||
|
||||
|
|
|
|||
6
deps/v8/src/objects/module.cc
vendored
6
deps/v8/src/objects/module.cc
vendored
|
|
@ -223,8 +223,7 @@ bool Module::Instantiate(Isolate* isolate, Handle<Module> module,
|
|||
DCHECK_EQ(module->status(), kUnlinked);
|
||||
return false;
|
||||
}
|
||||
DCHECK(module->status() == kLinked || module->status() == kEvaluated ||
|
||||
module->status() == kEvaluatingAsync || module->status() == kErrored);
|
||||
DCHECK_GE(module->status(), kLinked);
|
||||
DCHECK(stack.empty());
|
||||
return true;
|
||||
}
|
||||
|
|
@ -488,8 +487,7 @@ bool Module::IsGraphAsync(Isolate* isolate) const {
|
|||
// Only SourceTextModules may be async.
|
||||
if (!IsSourceTextModule(*this)) return false;
|
||||
Tagged<SourceTextModule> root = Cast<SourceTextModule>(*this);
|
||||
DCHECK(root->status() == kLinked || root->status() == kEvaluated ||
|
||||
root->status() == kEvaluatingAsync || root->status() == kErrored);
|
||||
DCHECK_GE(root->status(), kLinked);
|
||||
|
||||
Zone zone(isolate->allocator(), ZONE_NAME);
|
||||
const size_t bucket_count = 2;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user