http://codereview.chromium.org/10795074/diff/4001/include/v8.h File include/v8.h (right):
http://codereview.chromium.org/10795074/diff/4001/include/v8.h#newcode3256 include/v8.h:3256: * notified each time code is added, moved or removed. On 2012/07/25 14:38:35, Sigurður Ásgeirsson wrote:
On 2012/07/25 14:22:12, Mikhail Naganov (Chromium) wrote: > There is a problem with code objects that were created before the
handler has
> been set. For V8's profiler we walk the heap in order to enumerate
them prior
to > hooking on events. Otherwise, the client will be receiving code move
events
for > objects he doesn't know anything about. > > Or you need to require that the client must set the handler in the
very
> beginning.
This is true - for the use case I have in mind, there's no problem
simply
requiring that the hook is instated before initializing V8. Do you have other use cases in mind here? Would you like me to change the API, the documentation or both, and if
so, how? For me, just stating this in the doc would be fine. If in the future this restriction will be removed by adding scanning of current code objects on handler installation, this wouldn't affect clients that install the handler from the beginning. http://codereview.chromium.org/10795074/ -- v8-dev mailing list [email protected] http://groups.google.com/group/v8-dev
