-
Notifications
You must be signed in to change notification settings - Fork 30k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
src: add API to get MultiIsolatePlatform used in node main thread #20447
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -251,6 +251,10 @@ NODE_EXTERN Environment* CreateEnvironment(IsolateData* isolate_data, | |
NODE_EXTERN void LoadEnvironment(Environment* env); | ||
NODE_EXTERN void FreeEnvironment(Environment* env); | ||
|
||
// This returns the MultiIsolatePlatform used by node main. | ||
// If NODE_USE_V8_PLATFORM is not defined, it will return nullptr. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe specific that the macro needs to have been defined when Node.js was built, not when the addon is being built? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Also, what's "node main"? This comment could be expanded a little. |
||
NODE_EXTERN MultiIsolatePlatform* GetNodeMultiIsolatePlatform(); | ||
|
||
NODE_EXTERN MultiIsolatePlatform* CreatePlatform( | ||
int thread_pool_size, | ||
v8::TracingController* tracing_controller); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Redundant name, it's already in the
node::
namespace. JustGetMultiIsolatePlatform()
orGetMainThreadMultiIsolatePlatform()
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
change it to GetMainThreadMultiIsolatePlatform as a more accurate name.