Thanks for the patch Jochen. First round of comments.
https://codereview.chromium.org/75283002/diff/1/build/features.gypi
File build/features.gypi (right):
https://codereview.chromium.org/75283002/diff/1/build/features.gypi#newcode63
build/features.gypi:63: 'v8_use_default_platform%': 1,
Do we really need this option here? Couldn't we just always include our
default implementation, and in V8::Initialize just check whether
g_platform is NULL, and if so, automagically use the default
implementation?
https://codereview.chromium.org/75283002/diff/1/include/v8-platform.h
File include/v8-platform.h (right):
https://codereview.chromium.org/75283002/diff/1/include/v8-platform.h#newcode51
include/v8-platform.h:51: class Platform {
Add private copy constructor and assign operator, using V8_DELETE.
https://codereview.chromium.org/75283002/diff/1/include/v8-platform.h#newcode64
include/v8-platform.h:64: virtual void callOnBackgroundThread(Task*
task, bool task_is_slow) = 0;
Nit: First letter should be upper-case.
https://codereview.chromium.org/75283002/diff/1/include/v8-platform.h#newcode71
include/v8-platform.h:71: virtual void callOnForegroundThread(Isolate*
isolate, Task* task) = 0;
Nit: First letter should be upper-case.
https://codereview.chromium.org/75283002/diff/1/src/api.cc
File src/api.cc (right):
https://codereview.chromium.org/75283002/diff/1/src/api.cc#newcode5087
src/api.cc:5087: g_platform = new i::DefaultPlatform;
I think platform initialization should be first in V8::Initialize(). If
we really want to be able to move all the platform stuff to the Platform
class at some point, then we will need an initialized Platform to use
even basic stuff such as TLS. So, please do:
if (!g_platform) g_platform = new i::DefaultPlatform;
at the beginning.
https://codereview.chromium.org/75283002/
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.